/* ================================================================
   FRONT STREET — NAV.CSS  v7
   Strategy: html.nav-open class + right-position drawer
   (avoids iOS Safari transform/will-change fixed bug)
================================================================ */

/* ── HEADER ──────────────────────────────────────────────────── */
.site-header {
  position: fixed;
  top: 0; left: 0; right: 0;
  z-index: 500;
  height: 68px;
  padding: 0 18px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  background: transparent;
  transition: background 0.4s ease, box-shadow 0.4s ease, height 0.3s ease;
}
.site-header.scrolled {
  background: rgba(7, 22, 18, 0.97);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  box-shadow: 0 2px 24px rgba(0,0,0,0.4);
  height: 62px;
}

/* ── LOGO ─────────────────────────────────────────────────────── */
.nav-logo { display: flex; align-items: center; flex-shrink: 0; }
.nav-logo a { display: flex; align-items: center; line-height: 0; }
.nav-logo img {
  height: 48px;
  width: auto;
  display: block;
  filter: drop-shadow(0 2px 10px rgba(0,0,0,0.5));
  /* Kill any shimmer animation on logo */
  background: none !important;
  animation: none !important;
}

/* ── DESKTOP NAV — hidden by default ─────────────────────────── */
.nav-links { display: none; }

/* ── HAMBURGER ────────────────────────────────────────────────── */
.nav-hamburger {
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  gap: 5px;
  width: 44px;
  height: 44px;
  padding: 0;
  border: 1.5px solid rgba(255,255,255,0.22);
  border-radius: 10px;
  background: rgba(255,255,255,0.08);
  cursor: pointer;
  flex-shrink: 0;
  -webkit-tap-highlight-color: transparent;
  touch-action: manipulation;
  transition: background 0.2s, border-color 0.2s;
}
.nav-hamburger:hover,
.nav-hamburger:active {
  background: rgba(201,168,76,0.18);
  border-color: rgba(201,168,76,0.5);
}
.nav-hamburger span {
  display: block;
  width: 20px;
  height: 2px;
  background: #fff;
  border-radius: 2px;
  pointer-events: none;
  transition: transform 0.3s ease, opacity 0.25s ease;
}
.nav-hamburger.active span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
.nav-hamburger.active span:nth-child(2) { opacity: 0; transform: scaleX(0); }
.nav-hamburger.active span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

/* ── BACKDROP ─────────────────────────────────────────────────── */
.mnav-backdrop {
  position: fixed;
  inset: 0;
  z-index: 810;
  background: rgba(0,0,0,0.72);
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.32s ease;
  /* No transform, no will-change — keep it simple */
}
html.nav-open .mnav-backdrop {
  opacity: 1;
  pointer-events: auto;
}

/* ── MOBILE DRAWER ────────────────────────────────────────────── */
/*
   KEY FIX: use right:-105% → right:0 instead of transform.
   iOS Safari sometimes ignores transform updates on position:fixed
   when will-change is active. right/left positioning always works.
*/
.mnav {
  position: fixed;
  top: 0;
  right: -105%;          /* off-screen to the right */
  bottom: 0;
  left: auto;
  width: min(300px, 86vw);
  z-index: 820;
  display: flex;
  flex-direction: column;
  overflow: hidden;
  background: linear-gradient(175deg, #081f1a 0%, #0a3229 55%, #0d3d32 100%);
  border-left: 1px solid rgba(201,168,76,0.14);
  box-shadow: -8px 0 40px rgba(0,0,0,0.5);
  transition: right 0.38s cubic-bezier(0.77, 0, 0.175, 1);
  /* CRITICAL: override style.css transform:translateX(110%) */
  transform: none !important;
}
html.nav-open .mnav {
  right: 0;
  transform: none !important;
}
/* Gold top accent */
.mnav::before {
  content: '';
  position: absolute;
  top: 0; left: 0; right: 0;
  height: 2px;
  background: linear-gradient(to right, transparent, #c9a84c, transparent);
  z-index: 1;
  pointer-events: none;
}

/* ── DRAWER TOP BAR ───────────────────────────────────────────── */
.mnav-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 18px 18px 16px;
  border-bottom: 1px solid rgba(201,168,76,0.12);
  flex-shrink: 0;
}
.mnav-logo {
  height: 36px;
  width: auto;
  display: block;
  background: none !important;
  animation: none !important;
}

/* ── CLOSE BUTTON ─────────────────────────────────────────────── */
.mnav-close {
  width: 40px;
  height: 40px;
  min-width: 40px;
  border-radius: 50%;
  border: 1.5px solid rgba(201,168,76,0.3);
  background: rgba(255,255,255,0.06);
  color: rgba(255,255,255,0.85);
  font-size: 0.88rem;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  flex-shrink: 0;
  padding: 0;
  -webkit-tap-highlight-color: transparent;
  touch-action: manipulation;
  transition: background 0.2s, border-color 0.2s, color 0.2s;
}
.mnav-close:hover,
.mnav-close:active {
  background: #c9a84c;
  border-color: #c9a84c;
  color: #081f1a;
}
.mnav-close i { pointer-events: none; }

/* ── NAV LINKS ────────────────────────────────────────────────── */
.mnav-links {
  flex: 1;
  overflow-y: auto;
  -webkit-overflow-scrolling: touch;
  display: flex;
  flex-direction: column;
  padding: 6px 0;
}
.mnav-links a {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 18px 22px;
  font-family: 'Jost', system-ui, sans-serif;
  font-size: 0.73rem;
  font-weight: 700;
  letter-spacing: 3px;
  text-transform: uppercase;
  color: rgba(255,255,255,0.52);
  text-decoration: none;
  border-bottom: 1px solid rgba(255,255,255,0.04);
  -webkit-tap-highlight-color: transparent;
  touch-action: manipulation;
  transition: color 0.2s, background 0.2s, padding-left 0.2s;
}
.mnav-links a:last-child { border-bottom: none; }
.mnav-links a span { pointer-events: none; }
.mnav-links a i {
  font-size: 0.54rem;
  color: rgba(201,168,76,0.22);
  pointer-events: none;
  flex-shrink: 0;
  transition: color 0.2s, transform 0.2s;
}
.mnav-links a:hover,
.mnav-links a:active,
.mnav-links a.active {
  color: #e2c97e;
  background: rgba(201,168,76,0.06);
  padding-left: 28px;
}
.mnav-links a:hover i,
.mnav-links a.active i { color: #c9a84c; transform: translateX(3px); }

/* ── BOTTOM CTA ───────────────────────────────────────────────── */
.mnav-bottom {
  flex-shrink: 0;
  padding: 16px 18px 26px;
  border-top: 1px solid rgba(201,168,76,0.12);
  display: flex;
  flex-direction: column;
  gap: 10px;
}
.mnav-call {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 14px 20px;
  background: linear-gradient(135deg, #e2c97e, #c9a84c);
  color: #081f1a;
  border-radius: 50px;
  font-family: 'Jost', sans-serif;
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 1.5px;
  text-transform: uppercase;
  text-decoration: none;
  border: none;
  box-shadow: 0 4px 20px rgba(201,168,76,0.3);
  -webkit-tap-highlight-color: transparent;
  touch-action: manipulation;
  transition: box-shadow 0.2s, opacity 0.2s;
}
.mnav-call:active { opacity: 0.85; }
.mnav-call i { pointer-events: none; }

.mnav-wa {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 12px 20px;
  background: transparent;
  border: 1.5px solid rgba(255,255,255,0.12);
  border-radius: 50px;
  color: rgba(255,255,255,0.48);
  font-family: 'Jost', sans-serif;
  font-size: 0.7rem;
  font-weight: 600;
  letter-spacing: 1.5px;
  text-transform: uppercase;
  text-decoration: none;
  -webkit-tap-highlight-color: transparent;
  touch-action: manipulation;
  transition: border-color 0.2s, color 0.2s;
}
.mnav-wa:hover,
.mnav-wa:active { border-color: rgba(201,168,76,0.4); color: #c9a84c; }
.mnav-wa i { pointer-events: none; }

/* ── DESKTOP 900px+ ───────────────────────────────────────────── */
@media (min-width: 900px) {
  .site-header { height: 78px; padding: 0 40px; }
  .site-header.scrolled { height: 66px; }

  .nav-links {
    display: flex;
    align-items: center;
    gap: 28px;
  }
  .nav-links a {
    font-family: 'Jost', sans-serif;
    font-size: 0.78rem;
    font-weight: 500;
    letter-spacing: 2px;
    text-transform: uppercase;
    color: rgba(255,255,255,0.82);
    text-decoration: none;
    position: relative;
    padding-bottom: 4px;
    transition: color 0.25s ease;
    white-space: nowrap;
  }
  .nav-links a::after {
    content: '';
    position: absolute;
    bottom: 0; left: 0; right: 0;
    height: 1px;
    background: #c9a84c;
    transform: scaleX(0);
    transform-origin: center;
    transition: transform 0.28s ease;
  }
  .nav-links a:hover,
  .nav-links a.active { color: #c9a84c; }
  .nav-links a:hover::after,
  .nav-links a.active::after { transform: scaleX(1); }

  .nav-links .nav-cta {
    background: linear-gradient(135deg, #e2c97e, #c9a84c);
    color: #081f1a !important;
    padding: 10px 22px;
    border-radius: 50px;
    font-weight: 700;
    letter-spacing: 1px;
    box-shadow: 0 4px 18px rgba(201,168,76,0.3);
    transition: box-shadow 0.25s, transform 0.25s;
  }
  .nav-links .nav-cta:hover {
    box-shadow: 0 6px 26px rgba(201,168,76,0.5);
    transform: translateY(-1px);
  }
  .nav-links .nav-cta::after { display: none; }

  .nav-hamburger { display: none; }
  .mnav          { display: none; }
  .mnav-backdrop { display: none; }
}

/* ── NAV OPEN: lock body scroll ───────────────────────────────── */
html.nav-open body {
  overflow: hidden;
  /* iOS Safari touch scroll lock */
  -webkit-overflow-scrolling: auto;
}
