/* ============================================================
   HERO SECTION — Navbar + Hero
   ============================================================ */

/* ─── NAVBAR — dark text when over light hero ─────── */
.page-home .navbar {
  --color-text-primary: #272932;
}
.page-home .navbar .nav-links li a {
  font-family: var(--font-cs-mono) !important;
  font-size: 15px !important;
  font-weight: 400 !important;
  line-height: 1 !important;
  letter-spacing: 0.07em !important;
  text-transform: uppercase !important;
  color: var(--color-cs-ink-muted) !important;
}
.page-home .nav-logo:hover,
.page-home .navbar .nav-links li a:hover {
  color: var(--color-accent-secondary);
}

/* ─── NAVBAR ─────────────────────────────────────── */
.navbar {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  z-index: var(--z-nav);
  background: transparent;
  padding: var(--space-6) 0;
}

.navbar .container {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--space-8);
}

/* Logo */
.nav-logo {
  color: var(--color-text-primary);
  text-decoration: none;
  letter-spacing: 0.02em;
  flex-shrink: 0;
  transition: color var(--transition-base);
}

.nav-logo-handlee {
  font-family: Handlee, cursive;
  font-size: var(--text-2xl);
}

.nav-logo:hover {
  color: var(--color-accent-primary);
}

/* Desktop Nav Links */
.nav-links {
  display: flex;
  align-items: center;
  gap: var(--space-10);
  list-style: none;
}

.nav-links li a {
  font-family: "Geist Mono", monospace;
  font-size: 15px;
  font-weight: 400;
  letter-spacing: 0.07em;
  text-transform: uppercase;
  color: var(--color-text-primary);
  text-decoration: none;
  position: relative;
  padding-bottom: 3px;
  transition: color var(--transition-base);
  line-height: 15px;
}

.nav-links li a::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 0;
  width: 0%;
  height: 1.5px;
  background-color: var(--color-accent-primary);
  transition: width var(--transition-base);
  border-radius: var(--radius-full);
}

.nav-links li a:hover {
  color: var(--color-accent-primary);
}

.nav-links li a:hover::after {
  width: 100%;
}

/* Download Resume — bold weight */
.nav-links .nav-download {
  font-weight: var(--font-bold);
}

/* ─── MOBILE NAV OVERLAY ─────────────────────────── */
.nav-mobile {
  display: none;
  position: fixed;
  inset: 0;
  background: var(--color-bg-primary);
  z-index: calc(var(--z-nav) - 1);
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: var(--space-10);
  opacity: 0;
  pointer-events: none;
  transition: opacity var(--transition-slow);
}

.nav-mobile.is-open {
  opacity: 1;
  pointer-events: all;
}

.nav-mobile-links {
  list-style: none;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: var(--space-8);
}

.nav-mobile-links li a {
  font-size: var(--text-2xl);
  font-weight: var(--font-semibold);
  color: var(--color-text-primary);
  text-decoration: none;
  transition: color var(--transition-base);
}

.nav-mobile-links li a:hover {
  color: var(--color-accent-primary);
}

@media (max-width: 768px) {
  .nav-links {
    display: none;
  }
  .nav-mobile {
    display: flex;
  }
}

/* ─── HERO SECTION ───────────────────────────────── */
.hero {
  position: relative;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  overflow: hidden;
  background-color: #f5f3ee;
}

/* Grid background pattern — dark lines on off-white */
.hero::before {
  content: '';
  position: absolute;
  inset: 0;
  background-image:
    linear-gradient(rgba(39,41,50,0.08) 1px, transparent 1px),
    linear-gradient(90deg, rgba(39,41,50,0.08) 1px, transparent 1px);
  background-size: 48px 48px;
  pointer-events: none;
  z-index: 0;
}

.hero-inner {
  position: relative;
  z-index: 1;
  flex: 1;
  display: flex;
  align-items: center;
  padding-top: calc(var(--nav-height) + var(--space-8));
  padding-bottom: var(--space-16);
}

.hero-inner .container {
  display: grid;
  grid-template-columns: 1fr 1fr;
  align-items: center;
  gap: var(--space-12);
  width: 100%;
}

/* ─── HERO LEFT — Content ────────────────────────── */
.hero-content {
  display: flex;
  flex-direction: column;
  gap: var(--space-6);
  max-width: 560px;
}

.hero-heading {
  font-family: tiemposText, serif;
  font-size: clamp(4rem, 8vw, 8rem);
  font-weight: var(--font-regular);
  color: var(--color-bg-primary);
  line-height: 1.0;
  letter-spacing: -0.02em;
}

.hero-subheading {
  font-family: var(--font-cs-mono);
  font-size: clamp(1.5rem, 3vw, 2.75rem);
  font-weight: var(--font-regular);
  font-style: normal;
  color: var(--color-bg-primary);
  line-height: var(--leading-snug);
  margin-top: 0;
  opacity: 0.7;
}

.hero-body {
  font-family: var(--font-cs-mono);
  font-size: var(--text-md);
  color: var(--color-bg-primary);
  line-height: var(--leading-loose);
  max-width: 460px;
  opacity: 0.5;
}

.hero-cta {
  margin-top: var(--space-4);
}

/* ─── HERO RIGHT — Lottie Visual ─────────────────── */
.hero-visual {
  position: relative;
  width: 100%;
  align-self: stretch;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: visible;
}

#hero-lottie {
  width: 115%;
  aspect-ratio: 4 / 3;
  flex-shrink: 0;
}

/* Loading skeleton shown while iframe loads */
.hero-visual-loader {
  position: absolute;
  inset: 0;
  background: linear-gradient(
    135deg,
    var(--color-bg-secondary) 0%,
    var(--color-bg-card) 50%,
    var(--color-bg-secondary) 100%
  );
  border-radius: var(--radius-2xl);
  display: flex;
  align-items: center;
  justify-content: center;
  transition: opacity var(--transition-slow);
  z-index: 2;
}

.hero-visual-loader.hidden {
  opacity: 0;
  pointer-events: none;
}

.loader-dots {
  display: flex;
  gap: var(--space-2);
}

.loader-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--color-accent-primary);
  animation: loader-bounce 1.2s ease-in-out infinite;
}

.loader-dot:nth-child(2) { animation-delay: 0.2s; }
.loader-dot:nth-child(3) { animation-delay: 0.4s; }

/* ─── RESPONSIVE ─────────────────────────────────── */
@media (max-width: 1024px) {
  .hero-inner .container {
    grid-template-columns: 1fr;
    gap: var(--space-12);
  }

  .hero-content {
    max-width: 100%;
    text-align: center;
    align-items: center;
  }

  .hero-body {
    max-width: 100%;
  }

  .hero-visual {
    align-self: auto;
    max-width: 680px;
    margin: 0 auto;
    width: 100%;
    min-height: 400px;
  }

  #hero-lottie {
    width: 100%;
  }
}

@media (max-width: 768px) {
  .hero-heading {
    font-size: var(--text-5xl);
  }

  .hero-subheading {
    font-size: var(--text-2xl);
  }

  .hero-visual {
    min-height: 320px;
  }
}

@media (max-width: 480px) {
  .hero-heading {
    font-size: var(--text-4xl);
  }

  .hero-subheading {
    font-size: var(--text-xl);
  }

  .hero-visual {
    min-height: 260px;
  }
}
