/* =====================================
   DESIGN TOKENS
===================================== */

:root {
  --bg-main: #0f172a;
  --bg-main-deep: #020617;
  --bg-section: #1e293b;
  --bg-card: #111827;
  --bg-card-soft: #172033;

  --text-main: #f8fafc;
  --text-secondary: #cbd5e1;
  --text-muted: #94a3b8;

  --accent: #3b82f6;
  --accent-hover: #2563eb;

  --border-soft: rgba(148, 163, 184, 0.18);
  --shadow-soft: 0 24px 60px rgba(0, 0, 0, 0.35);
}

/* =====================================
   BASE
===================================== */

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  font-family: 'Inter', sans-serif;
  background-color: var(--bg-main);
  color: var(--text-secondary);
}

img {
  max-width: 100%;
  display: block;
}

a {
  color: var(--accent);
  text-decoration: none;
}

a:hover {
  color: #60a5fa;
}

h1,
h2,
h3,
h4,
h5,
h6 {
  color: var(--text-main);
}

/* =====================================
   SECTION HELPERS
===================================== */

.section-padding {
  padding: 6rem 0;
}

.section-dark {
  background-color: var(--bg-main);
}

.section-alt {
  background-color: var(--bg-section);
}

.section-label {
  margin-bottom: 0.75rem;
  color: var(--accent);
  font-size: 0.8rem;
  font-weight: 700;
  letter-spacing: 0.14em;
  text-transform: uppercase;
}

.section-title {
  margin-bottom: 1rem;
  font-weight: 800;
  line-height: 1.12;
}

.section-description {
  color: var(--text-secondary);
  font-size: 1.05rem;
  line-height: 1.8;
}

.section-divider {
  width: 80%;
  max-width: 500px;
  height: 1px;
  margin: 4rem auto;
  background: linear-gradient(
    to right,
    transparent,
    var(--accent),
    transparent
  );
  opacity: 0.5;
}

.text-muted-custom {
  color: var(--text-muted);
}

/* =====================================
   NAVBAR
===================================== */

.navbar {
  padding: 1rem 0;
  background: rgba(15, 23, 42, 0.78);
  border-bottom: 1px solid transparent;
  backdrop-filter: blur(14px);
  transition: all 0.3s ease;
}

.navbar.navbar-scrolled {
  padding: 0.7rem 0;
  border-bottom-color: var(--border-soft);
  box-shadow: 0 14px 40px rgba(0, 0, 0, 0.2);
}

.navbar-brand span {
  color: var(--accent);
}

.navbar .nav-link {
  color: var(--text-secondary);
  font-weight: 500;
}

.navbar .nav-link:hover,
.navbar .nav-link.active {
  color: var(--text-main);
}

/* =====================================
   BUTTONS
===================================== */

.btn {
  transition: all 0.25s ease;
}

.btn-custom {
  background-color: var(--accent);
  color: #fff;
  border: 1px solid var(--accent);
  box-shadow: 0 12px 28px rgba(59, 130, 246, 0.28);
}

.btn-custom:hover {
  background-color: var(--accent-hover);
  border-color: var(--accent-hover);
  color: #fff;
  transform: translateY(-2px);
  box-shadow: 0 8px 20px rgba(59, 130, 246, 0.4);
}

.btn-outline-light {
  border-color: rgba(248, 250, 252, 0.35);
  color: var(--text-main);
}

.btn-outline-light:hover {
  background-color: var(--text-main);
  color: var(--bg-main);
  transform: translateY(-2px);
}

/* =====================================
   HERO
===================================== */

.hero-section {
  min-height: 100vh;
  padding: 8rem 0 5rem;
  background:
    radial-gradient(circle at top left, rgba(59, 130, 246, 0.22), transparent 34rem),
    linear-gradient(135deg, var(--bg-main), var(--bg-main-deep));
}

.eyebrow {
  color: var(--accent);
  font-weight: 700;
  letter-spacing: 0.16em;
  text-transform: uppercase;
}

.hero-text {
  max-width: 680px;
  color: var(--text-secondary);
}

.hero-card {
  max-width: 320px;
  padding: 2rem;
  background: linear-gradient(180deg, rgba(30, 41, 59, 0.94), rgba(17, 24, 39, 0.94));
  border: 1px solid var(--border-soft);
  border-radius: 28px;
  box-shadow: var(--shadow-soft);
  text-align: center;
}

.profile-img {
  display: block;
  margin-right: auto;
  margin-left: auto;
}

.hero-card-tags,
.project-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 0.6rem;
}

.hero-card-tags {
  justify-content: center;
}

.hero-card-tags span,
.project-tags span {
  padding: 0.42rem 0.75rem;
  background-color: rgba(59, 130, 246, 0.12);
  border: 1px solid rgba(59, 130, 246, 0.22);
  border-radius: 999px;
  color: #bfdbfe;
  font-size: 0.82rem;
  font-weight: 600;
}

/* =====================================
   SKILLS
===================================== */

.skill-card {
  padding: 2rem;
  background: var(--bg-card);
  border: 1px solid var(--border-soft);
  border-radius: 24px;
  transition: transform 0.3s ease, border-color 0.3s ease, box-shadow 0.3s ease;
}

.skill-card:hover {
  transform: translateY(-8px);
  border-color: rgba(59, 130, 246, 0.45);
  box-shadow: var(--shadow-soft);
}

.skill-card i {
  display: inline-block;
  margin-bottom: 1.2rem;
  color: var(--accent);
  font-size: 2.4rem;
}

.skill-card h3 {
  font-size: 1.15rem;
  font-weight: 700;
}

.skill-card p {
  margin-bottom: 0;
  color: var(--text-muted);
  line-height: 1.7;
}

/* =====================================
   PROJECTS
===================================== */

.project-card {
  overflow: hidden;
  background-color: var(--bg-card);
  border: 1px solid var(--border-soft);
  border-radius: 24px;
  color: var(--text-secondary);
  transition: transform 0.3s ease, border-color 0.3s ease, box-shadow 0.3s ease;
}

.project-card:hover {
  transform: translateY(-10px);
  border-color: rgba(59, 130, 246, 0.45);
  box-shadow: var(--shadow-soft);
}

.project-card .card-img-top {
  background-color: var(--bg-card-soft);
  border-bottom: 1px solid var(--border-soft);
}

.project-card .card-body {
  padding: 1.5rem;
}

.project-card .card-text {
  color: var(--text-muted);
  line-height: 1.7;
}

.project-tags {
  gap: 0.5rem;
}

.project-img {
  width: 100%;
  aspect-ratio: 16 / 9;
  object-fit: cover;
}

/* =====================================
   CONTACT
===================================== */

.contact-box {
  max-width: 860px;
  margin: 0 auto;
  padding: 3rem 2rem;
  background: linear-gradient(180deg, rgba(17, 24, 39, 0.9), rgba(15, 23, 42, 0.9));
  border: 1px solid var(--border-soft);
  border-radius: 28px;
  box-shadow: var(--shadow-soft);
}

.contact-box .section-description {
  max-width: 620px;
}

/* =====================================
   FOOTER
===================================== */

.footer {
  background-color: var(--bg-main-deep);
  color: var(--text-muted);
  border-top: 1px solid var(--border-soft);
}

/* =====================================
   BACK TO TOP
===================================== */

.back-to-top {
  position: fixed;
  right: 1.25rem;
  bottom: 1.25rem;
  z-index: 999;
  display: grid;
  width: 44px;
  height: 44px;
  place-items: center;
  background-color: var(--accent);
  color: #fff;
  border: 1px solid var(--border-soft);
  border-radius: 50%;
  opacity: 0;
  pointer-events: none;
  transform: translateY(12px);
  transition: all 0.25s ease;
}

.back-to-top.show {
  opacity: 1;
  pointer-events: auto;
  transform: translateY(0);
}

.back-to-top:hover {
  background-color: var(--accent-hover);
}

/* =====================================
   SCROLL REVEAL
===================================== */

.fade-in {
  opacity: 0;
  transform: translateY(28px);
  transition: opacity 0.7s ease, transform 0.7s ease;
}

.fade-in.show {
  opacity: 1;
  transform: translateY(0);
}

/* =====================================
   RESPONSIVE
===================================== */

@media (max-width: 991px) {
  .navbar-collapse {
    padding: 1rem 0;
  }

  .hero-section {
    text-align: center;
  }

  .hero-text {
    margin-right: auto;
    margin-left: auto;
  }

  .hero-section .d-flex {
    justify-content: center;
  }
}

@media (max-width: 575px) {
  .section-padding {
    padding: 4.5rem 0;
  }

  .hero-section {
    padding-top: 7rem;
  }

  .display-3 {
    font-size: 2.55rem;
  }

  .contact-box {
    padding: 2.25rem 1.25rem;
  }
}
