/* ==========================================================
   Navbar — logo, links, CTA
========================================================== */

header {
  position: fixed;
  top: 0; left: 0; right: 0;
  z-index: 100;
  padding: 20px 0;
  backdrop-filter: blur(10px);
  background: linear-gradient(to bottom, color-mix(in srgb, var(--ink) 80%, transparent), transparent);
  transition: background .35s ease;
}

nav {
  display: flex; align-items: center; justify-content: space-between;
  max-width: var(--container); margin: 0 auto; padding: 0 32px;
}

.logo {
  font-family: var(--font-display); font-weight: 700; font-size: 17px;
  letter-spacing: 0.02em; display: flex; align-items: center; gap: 10px;
}

.logo-mark {
  width: 10px; height: 10px; background: var(--signal); border-radius: 2px;
  box-shadow: 0 0 12px 2px var(--signal); transform: rotate(45deg); flex-shrink: 0;
}

.nav-links { display: flex; gap: 30px; font-size: 13.5px; color: var(--fog); }
.nav-links a { transition: color .2s ease; }
.nav-links a:hover { color: var(--paper); }

.nav-right { display: flex; align-items: center; gap: 14px; }

/* ==========================================================
   PC VIEW ONLY: Navbar CTA Button (Pill Shape)
========================================================== */
@media (min-width: 861px) {
  .nav-right .nav-cta {
    display: inline-flex !important;
    align-items: center;
    justify-content: center;
    background-color: #d1f4fa; /* Light icy blue */
    color: #0b1120 !important; /* Dark text for contrast */
    padding: 12px 28px !important;
    border-radius: 999px !important; /* Perfect pill shape */
    font-family: inherit;
    font-weight: 600;
    font-size: 15px !important;
    text-decoration: none;
    white-space: nowrap;
    transition: all 0.3s ease;
    border: none !important;
  }

  .nav-right .nav-cta:hover {
    background-color: #ffffff;
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(209, 244, 250, 0.2);
  }
}

/* ---------------- Hamburger toggle ---------------- */
.menu-toggle {
  display: none;
  width: 38px; height: 38px; border-radius: 50%;
  border: 1px solid var(--line); background: transparent;
  align-items: center; justify-content: center;
  flex-direction: column; gap: 4px; flex-shrink: 0;
}
.menu-toggle span {
  width: 16px; height: 2px; background: var(--paper); border-radius: 2px;
  transition: transform .25s ease, opacity .2s ease;
}
.menu-toggle.open span:nth-child(1) { transform: translateY(6px) rotate(45deg); }
.menu-toggle.open span:nth-child(2) { opacity: 0; }
.menu-toggle.open span:nth-child(3) { transform: translateY(-6px) rotate(-45deg); }

/* ---------------- Mobile drawer menu ---------------- */
.menu-backdrop {
  position: fixed; inset: 0; z-index: 98;
  background: rgba(0,0,0,0.5);
  opacity: 0; pointer-events: none;
  transition: opacity .3s ease;
}
.menu-backdrop.open { opacity: 1; pointer-events: auto; }

.mobile-menu {
  position: fixed; top: 0; right: 0; bottom: 0;
  width: 78%; max-width: 320px;
  background: var(--charcoal);
  border-left: 1px solid var(--line);
  z-index: 99;
  padding: 100px 30px 40px;
  display: flex; flex-direction: column;
  overflow-y: auto;
  transform: translateX(100%);
  transition: transform .35s ease;
}
.mobile-menu.open { transform: translateX(0); }
.mobile-menu ul { display: flex; flex-direction: column; }
.mobile-menu a {
  font-family: var(--font-display); font-weight: 600; font-size: 19px;
  color: var(--paper); padding: 15px 0;
  border-bottom: 1px solid var(--line-soft);
  display: block;
}
.mobile-menu-cta { margin-top: 26px; text-align: center; width: 100%; }

@media (max-width: 860px) {
  .nav-links { display: none; }
  .nav-cta { display: none; }
  .menu-toggle { display: flex; }
}

/* Small phones — shrink logo/toggle so the row fits without wrapping */
@media (max-width: 480px) {
  header { padding: 14px 0; }
  nav { padding: 0 18px; flex-wrap: nowrap; }
  .logo { font-size: 13.5px; gap: 7px; white-space: nowrap; }
  .logo-mark { width: 8px; height: 8px; }
  .nav-right { gap: 8px; }
  .menu-toggle { width: 32px; height: 32px; flex-shrink: 0; }
  .mobile-menu { width: 82%; padding: 90px 24px 30px; }
}

@media (max-width: 360px) {
  .logo { font-size: 12px; }
}

/* ==========================================================
   Foolproof Mobile Menu CTA Styles
========================================================== */
.mobile-menu .mobile-menu-cta {
  display: flex !important;
  justify-content: center;
  align-items: center;
  background-color: #4f8bc9 !important; /* Forces the blue background */
  color: #ffffff !important; /* Forces white text */
  padding: 15px 20px;
  border-radius: 8px;
  font-weight: 600;
  text-decoration: none;
  font-size: 16px;
  margin: 20px;
  visibility: visible !important;
  opacity: 1 !important;
}