/* =============================================================
   GATE & GUIDE — NAVIGATION HEADER STYLE
   ============================================================= */

.site-header {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 80px;
  z-index: 1000;
  background-color: transparent;
  color: var(--color-text-light);
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
  transition: background-color 0.4s ease, border-color 0.4s ease, color 0.4s ease, box-shadow 0.4s ease;
}

/* Header container alignment */
.site-header .container {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 100%;
}

/* Logo & Brand block */
.brand-link {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  color: inherit;
  transition: transform 0.3s ease;
}
.brand-link:hover {
  transform: translateY(-1px);
}
.brand-logo-img {
  height: 40px;
  width: auto;
  object-fit: contain;
}
.brand-name {
  font-family: var(--font-display);
  font-size: 1.25rem;
  font-weight: 600;
  letter-spacing: -0.01em;
}
.brand-name span {
  color: var(--color-orange);
}

/* Desktop Navigation Menu */
.desktop-nav {
  display: flex;
  align-items: center;
  gap: 2.25rem;
}
.nav-link {
  font-family: var(--font-body);
  font-size: 0.8rem;
  font-weight: 500;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: inherit;
  position: relative;
  padding: 0.5rem 0;
  opacity: 0.85;
  transition: opacity 0.3s ease, color 0.3s ease;
}
.nav-link:hover {
  opacity: 1;
  color: var(--color-orange);
}
.nav-link.active {
  opacity: 1;
  color: var(--color-orange);
}
.nav-link.active::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 0;
  width: 100%;
  height: 2px;
  background-color: var(--color-orange);
  transform: scaleX(1);
}

/* Header Action Button (Desktop Only) */
.header-action {
  display: flex;
  align-items: center;
}
.header-action .btn-primary {
  padding: 0.65rem 1.5rem;
  font-size: var(--text-xs);
}

/* -------------------------------------------------------------
   SCROLLED & STATIC STATE (.nav-scrolled, .nav-static)
   .nav-scrolled is added dynamically via JS on scroll.
   .nav-static can be added manually to pages starting with a light bg.
   ------------------------------------------------------------- */
.nav-scrolled,
.nav-static {
  background-color: rgba(250, 250, 248, 0.96);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--color-border);
  color: var(--color-text-primary);
  box-shadow: 0 4px 30px rgba(0, 0, 0, 0.02);
}
.nav-scrolled .brand-logo-img,
.nav-static .brand-logo-img {
  /* Remove white filter, show normal brand colors */
  filter: none;
}
.nav-scrolled .nav-link,
.nav-static .nav-link {
  color: var(--color-text-primary);
}
.nav-scrolled .nav-link:hover,
.nav-scrolled .nav-link.active,
.nav-static .nav-link:hover,
.nav-static .nav-link.active {
  color: var(--color-orange);
}

/* -------------------------------------------------------------
   HAMBURGER BUTTON
   ------------------------------------------------------------- */
.hamburger-btn {
  display: none; /* Hidden on desktop */
  flex-direction: column;
  justify-content: space-between;
  width: 26px;
  height: 18px;
  background: transparent;
  border: none;
  cursor: pointer;
  z-index: 1001; /* Above mobile overlay */
}
.hamburger-line {
  display: block;
  width: 100%;
  height: 2px;
  background-color: currentColor; /* Matches active text color */
  transition: transform 0.3s cubic-bezier(0.76, 0, 0.24, 1), 
              opacity 0.3s cubic-bezier(0.76, 0, 0.24, 1),
              background-color 0.4s ease;
}

/* -------------------------------------------------------------
   MOBILE MENU OVERLAY
   ------------------------------------------------------------- */
.mobile-menu-overlay {
  position: fixed;
  inset: 0;
  width: 100vw;
  height: 100vh;
  background-color: var(--color-bg-dark);
  z-index: 999;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  padding: 4rem var(--container-padding);
  
  /* Initial state: Hidden */
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
  transition: opacity 0.5s cubic-bezier(0.76, 0, 0.24, 1), 
              visibility 0.5s cubic-bezier(0.76, 0, 0.24, 1);
}

.mobile-nav-list {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 2rem;
  margin-bottom: 4rem;
}

.mobile-nav-item {
  overflow: hidden; /* For clipping enter animation */
}

.mobile-nav-link {
  font-family: var(--font-display);
  font-size: 2.5rem;
  font-weight: 500;
  color: var(--color-text-light);
  display: block;
  transform: translateY(100%); /* Start state for GSAP */
  transition: color 0.3s ease;
}
.mobile-nav-link:hover,
.mobile-nav-link.active {
  color: var(--color-orange);
}

.mobile-menu-footer {
  text-align: center;
  opacity: 0; /* Animated with GSAP */
  transform: translateY(20px);
}
.mobile-menu-footer .btn-primary {
  margin-bottom: 2rem;
}
.mobile-menu-info {
  font-family: var(--font-body);
  font-size: var(--text-sm);
  color: var(--color-text-muted);
}

/* -------------------------------------------------------------
   MENU OPEN STATE
   ------------------------------------------------------------- */
body.menu-open {
  overflow: hidden; /* Disable background scroll */
}

body.menu-open .site-header {
  color: var(--color-text-light) !important;
  border-bottom-color: rgba(255, 255, 255, 0.05) !important;
}

/* Keep logo in original colors inside open menu */
body.menu-open .brand-logo-img {
  filter: none !important;
}

/* Transform Hamburger to X */
body.menu-open .hamburger-line:nth-child(1) {
  transform: translateY(8px) rotate(45deg);
}
body.menu-open .hamburger-line:nth-child(2) {
  opacity: 0;
}
body.menu-open .hamburger-line:nth-child(3) {
  transform: translateY(-8px) rotate(-45deg);
}

/* Show Mobile Overlay */
body.menu-open .mobile-menu-overlay {
  opacity: 1;
  visibility: visible;
  pointer-events: all;
}

/* -------------------------------------------------------------
   RESPONSIVE BREKPOINTS (Max 768px for Mobile menu trigger)
   ------------------------------------------------------------- */
@media (max-width: 768px) {
  .desktop-nav,
  .header-action {
    display: none;
  }
  
  .hamburger-btn {
    display: flex;
  }
}
