/* ═══════════════════════════════════════════════════════════════
   NAVIGATION — nav.css
   ═══════════════════════════════════════════════════════════════ */

/* ── Topbar ─────────────────────────────────────────────────── */
.topbar {
  background: var(--steel-800);
  border-bottom: 1px solid var(--steel-600);
  padding: 7px var(--space-md);
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 0.75rem;
  font-family: var(--font-mono);
  color: var(--steel-300);
  gap: 12px;
}
.topbar a { color: var(--amber); transition: color var(--transition); }
.topbar a:hover { color: var(--amber-glow); }
.topbar-right { display: flex; gap: 20px; align-items: center; }

/* ── Main nav ───────────────────────────────────────────────── */
.nav {
  position: sticky;
  top: 0;
  z-index: 1000;
  height: var(--nav-h);
  background: rgba(13,15,18,0.97);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  border-bottom: 1px solid var(--steel-600);
}
.nav-inner {
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 0 var(--space-md);
  width: 100%;
  height: 100%;
  display: flex;
  align-items: center;
}

/* ── Logo ───────────────────────────────────────────────────── */
.nav-logo {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-right: clamp(12px, 2.5vw, 32px);
  flex-shrink: 1;
  min-width: 0;
  text-decoration: none;
}
.nav-logo-img-wrap {
  flex-shrink: 1;
  min-width: 0;
  line-height: 0;
}
.nav-logo-img-wrap img {
  display: block;
  width: auto;
  height: clamp(30px, 4.2vw, 46px);
  filter: drop-shadow(0 2px 10px rgba(245,166,35,0.35)) drop-shadow(0 1px 4px rgba(0,0,0,0.6));
  transition: filter var(--transition);
}
.nav-logo:hover .nav-logo-img-wrap img {
  filter: drop-shadow(0 3px 14px rgba(245,166,35,0.55)) drop-shadow(0 2px 4px rgba(0,0,0,0.7));
}
.nav-logo-text { line-height: 1.15; min-width: 0; }
.nav-logo-text strong {
  display: block;
  font-family: var(--font-head);
  font-weight: 800;
  font-size: clamp(0.7rem, 1.1vw, 1.02rem);
  letter-spacing: 0.02em;
  color: var(--white);
  white-space: nowrap;
}
.nav-logo-text span {
  display: block;
  font-family: var(--font-mono);
  font-size: clamp(0.5rem, 0.65vw, 0.58rem);
  letter-spacing: 0.18em;
  color: var(--amber);
  text-transform: uppercase;
}

/* ── Nav menu ───────────────────────────────────────────────── */
.nav-menu {
  display: flex;
  align-items: center;
  height: var(--nav-h);
  flex: 1;
}
.nav-item {
  position: relative;
  height: 100%;
  display: flex;
  align-items: center;
}
.nav-link {
  display: flex;
  align-items: center;
  gap: 4px;
  height: 100%;
  padding: 0 clamp(8px, 1.1vw, 16px);
  font-family: var(--font-head);
  font-weight: 600;
  font-size: clamp(0.76rem, 0.88vw, 0.92rem);
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: var(--steel-200);
  transition: color var(--transition);
  cursor: pointer;
  white-space: nowrap;
  border-bottom: 3px solid transparent;
  text-decoration: none;
}
.nav-link:hover,
.nav-item:hover > .nav-link { color: var(--white); border-bottom-color: var(--amber); }
.nav-link .chevron { width: 10px; height: 6px; transition: transform var(--transition); }
.nav-item:hover .chevron { transform: rotate(180deg); }

/* ── Mega menu ──────────────────────────────────────────────── */
.mega-menu {
  position: absolute;
  top: calc(var(--nav-h) - 1px);
  left: 50%;
  transform: translateX(-50%) translateY(-8px);
  background: var(--steel-800);
  border: 1px solid var(--steel-600);
  border-top: 2px solid var(--amber);
  padding: 24px;
  display: grid;
  gap: 4px;
  opacity: 0;
  pointer-events: none;
  transition: opacity var(--transition), transform var(--transition);
  box-shadow: 0 24px 48px rgba(0,0,0,0.55);
  min-width: 520px;
}
.mega-menu.cols-3 { grid-template-columns: repeat(3,1fr); min-width: 700px; }
.mega-menu.cols-2 { grid-template-columns: repeat(2,1fr); min-width: 480px; }
.mega-menu.cols-1 { grid-template-columns: 1fr; min-width: 240px; }
.nav-item:hover .mega-menu {
  opacity: 1;
  pointer-events: auto;
  transform: translateX(-50%) translateY(0);
}
.mega-section-title {
  grid-column: 1 / -1;
  font-family: var(--font-mono);
  font-size: 0.62rem;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--steel-400);
  padding-bottom: 8px;
  border-bottom: 1px solid var(--steel-600);
  margin-bottom: 4px;
}
.mega-card {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  padding: 12px;
  border-radius: var(--radius);
  border: 1px solid transparent;
  transition: background var(--transition), border-color var(--transition);
  cursor: pointer;
  text-decoration: none;
  color: inherit;
}
.mega-card:hover { background: var(--steel-700); border-color: var(--steel-500); }
.mega-card:hover .mega-card-icon { background: var(--amber); color: var(--steel-900); }
.mega-card-icon {
  width: 36px;
  height: 36px;
  flex-shrink: 0;
  background: var(--steel-600);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.1rem;
  border-radius: 2px;
  transition: background var(--transition), color var(--transition);
}
.mega-card-text strong {
  display: block;
  font-family: var(--font-head);
  font-weight: 700;
  font-size: 0.9rem;
  color: var(--white);
  margin-bottom: 2px;
}
.mega-card-text p { font-size: 0.72rem; color: var(--steel-300); line-height: 1.4; }

/* ── Simple dropdown ────────────────────────────────────────── */
.dropdown {
  position: absolute;
  top: calc(var(--nav-h) - 1px);
  left: 0;
  background: var(--steel-800);
  border: 1px solid var(--steel-600);
  border-top: 2px solid var(--amber);
  min-width: 220px;
  padding: 6px 0;
  opacity: 0;
  pointer-events: none;
  transition: opacity var(--transition), transform var(--transition);
  transform: translateY(-8px);
  box-shadow: 0 24px 48px rgba(0,0,0,0.5);
}
.nav-item:hover .dropdown {
  opacity: 1;
  pointer-events: auto;
  transform: translateY(0);
}
.dropdown a {
  display: block;
  padding: 9px 18px;
  font-size: 0.86rem;
  color: var(--steel-200);
  transition: background var(--transition), color var(--transition), padding var(--transition);
  text-decoration: none;
}
.dropdown a:hover { background: var(--steel-700); color: var(--white); padding-left: 24px; }

/* ── Nav CTA ────────────────────────────────────────────────── */
.nav-cta {
  margin-left: auto;
  display: flex;
  align-items: center;
  gap: clamp(6px, 1vw, 12px);
  flex-shrink: 0;
}
.nav-phone {
  font-family: var(--font-mono);
  font-size: clamp(0.68rem, 0.82vw, 0.8rem);
  color: var(--steel-300);
  white-space: nowrap;
}
.nav-phone strong { color: var(--amber); }

/* ── Hamburger ──────────────────────────────────────────────── */
.hamburger {
  display: none;
  flex-direction: column;
  gap: 5px;
  cursor: pointer;
  padding: 8px;
  margin-left: auto;
}
.hamburger span {
  display: block;
  width: 24px;
  height: 2px;
  background: var(--steel-200);
  transition: all var(--transition);
  border-radius: 1px;
}
.hamburger.open span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
.hamburger.open span:nth-child(2) { opacity: 0; }
.hamburger.open span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

/* ── Mobile drawer ──────────────────────────────────────────── */
.mobile-drawer {
  display: none;
  position: fixed;
  inset: 0;
  z-index: 2000;
  background: rgba(0,0,0,0.72);
}
.mobile-drawer.open { display: block; }
.mobile-drawer-panel {
  position: absolute;
  right: 0; top: 0; bottom: 0;
  width: min(360px,100vw);
  background: var(--steel-800);
  border-left: 1px solid var(--steel-600);
  padding: 20px;
  overflow-y: auto;
  animation: slideIn 0.28s ease;
}
@keyframes slideIn { from { transform: translateX(100%); } to { transform: none; } }
.mobile-close {
  display: flex;
  justify-content: flex-end;
  margin-bottom: 20px;
}
.mobile-close button {
  background: none;
  border: none;
  color: var(--steel-300);
  font-size: 1.4rem;
  cursor: pointer;
  padding: 4px 8px;
}
.mobile-nav-group { margin-bottom: 4px; }
.mobile-nav-link {
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-family: var(--font-head);
  font-weight: 700;
  font-size: 1.1rem;
  text-transform: uppercase;
  padding: 12px 0;
  border-bottom: 1px solid var(--steel-700);
  color: var(--steel-100);
  letter-spacing: 0.04em;
  cursor: pointer;
  text-decoration: none;
}
.mobile-nav-sub { padding-left: 14px; margin-bottom: 4px; display: none; }
.mobile-nav-sub.open { display: block; }
.mobile-nav-sub a {
  display: block;
  font-size: 0.88rem;
  color: var(--steel-300);
  padding: 8px 0;
  border-bottom: 1px solid var(--steel-700);
  text-decoration: none;
  transition: color var(--transition);
}
.mobile-nav-sub a:hover { color: var(--amber); }
.mobile-cta-strip { margin-top: 24px; display: flex; flex-direction: column; gap: 10px; }
.mobile-cta-strip .btn { justify-content: center; }

/* ── Breakpoints ────────────────────────────────────────────── */
@media (max-width: 1040px) {
  .nav-phone { display: none; }
  .nav-logo-text strong { display: none; }
}
@media (max-width: 880px) {
  .nav-logo-text { display: none; }
}
@media (max-width: 768px) {
  .nav-menu, .nav-cta { display: none; }
  .hamburger { display: flex; }
}
@media (max-width: 900px) {
  .btn { padding: 8px 14px; font-size: 0.8rem; }
}
@media (max-width: 600px) {
  .topbar-right { display: none; }
}
