/* Site-wide 3D header: brand name + logo, nav, call and Get Quote.
   Loaded on every page from partials/head-meta.php, after components.css. */

.topbar {
  background:
    linear-gradient(90deg, rgba(47, 92, 134, 0.35), transparent 40%, transparent 60%, rgba(47, 92, 134, 0.35)),
    var(--color-primary-dark);
  box-shadow: inset 0 -2px 0 var(--color-orange);
}

.site-header {
  background: linear-gradient(180deg, #ffffff, #f6f8fa);
  border-bottom: 0;
  box-shadow:
    0 1px 0 #dfe5ec, 0 2px 0 #d5dce4, 0 3px 0 #cbd2db, 0 4px 0 #c2cad4,
    0 12px 24px rgba(2, 28, 51, 0.10);
}

/* ---------- Brand: 3D coin logo + extruded name ---------- */
.brand { perspective: 600px; }
.brand-mark {
  border-radius: 50%;
  box-shadow:
    0 0 0 3px #fff,
    0 3px 0 3px #c2cad4, 0 5px 0 3px #aeb8c4,
    0 12px 18px rgba(2, 28, 51, 0.25);
  transition: transform 700ms cubic-bezier(.2, .8, .2, 1);
}
.brand-mark-icon { box-shadow: none; }
.brand:hover .brand-mark { transform: rotateY(360deg); }

.brand > span:last-child {
  color: var(--color-navy);
  text-shadow:
    0 1px 0 #c9d3de, 0 2px 0 #b8c4d2, 0 3px 0 #f06203,
    0 6px 10px rgba(2, 28, 51, 0.2);
}
.brand-badge {
  text-shadow: none;
  background: linear-gradient(180deg, #fff3ea, var(--color-orange-soft));
  box-shadow: 0 2px 0 #f2bd96, 0 4px 8px rgba(240, 98, 3, 0.15);
}

/* ---------- Nav links as raised pills ---------- */
.nav-links { gap: var(--space-2); }
.nav-links a {
  padding: 8px 14px;
  border-radius: 999px;
  transition: translate 150ms ease, box-shadow 150ms ease, background 150ms ease, color 150ms ease;
}
.nav-links a:hover {
  translate: 0 -2px;
  background: #fff;
  box-shadow: 0 3px 0 #d5dce4, 0 8px 14px rgba(2, 28, 51, 0.08);
}
.nav-links a.active {
  color: var(--color-navy-mid);
  font-weight: 700;
  background: var(--color-navy-soft);
  box-shadow: 0 3px 0 #c3ced9, 0 8px 14px rgba(2, 28, 51, 0.08);
}

/* ---------- Call chip + Get Quote ---------- */
.nav-call {
  padding: 8px 14px;
  border-radius: 999px;
  background: #fff;
  border: 1px solid #e2e6eb;
  box-shadow: 0 3px 0 #d5dce4;
  transition: translate 150ms ease, box-shadow 150ms ease;
}
.nav-call:hover { translate: 0 -2px; box-shadow: 0 5px 0 #c2cad4; }
.nav-cta .btn-accent {
  box-shadow: 0 4px 0 #a84302, 0 10px 18px rgba(240, 98, 3, 0.3);
  transition: translate 120ms ease, box-shadow 120ms ease, background var(--transition-base);
}
.nav-cta .btn-accent:hover { translate: 0 -2px; box-shadow: 0 6px 0 #a84302, 0 14px 22px rgba(240, 98, 3, 0.35); }
.nav-cta .btn-accent:active { translate: 0 3px; box-shadow: 0 1px 0 #a84302, 0 4px 8px rgba(240, 98, 3, 0.25); }

/* ---------- Mobile menu ---------- */
@media (max-width: 900px) {
  .nav-toggle {
    border-radius: 12px;
    background: #fff;
    border: 1px solid #e2e6eb;
    box-shadow: 0 3px 0 #d5dce4;
  }
  .nav-toggle:active { translate: 0 2px; box-shadow: 0 1px 0 #d5dce4; }
  .nav-links {
    gap: 6px;
    border-top: 3px solid var(--color-orange);
    box-shadow:
      0 2px 0 #dfe5ec, 0 4px 0 #d5dce4, 0 6px 0 #c2cad4,
      0 20px 30px rgba(2, 28, 51, 0.15);
  }
  .nav-links a { width: 100%; }
}

/* Mid-size screens: tighten pills so the full menu fits on one line */
.nav-links a, .nav-call { white-space: nowrap; }
@media (max-width: 1200px) and (min-width: 901px) {
  .brand-badge { white-space: nowrap; }
  .nav-links { gap: 2px; }
  .nav-links a { padding: 7px 8px; font-size: 0.84rem; }
  .nav-call { padding: 7px 10px; font-size: 0.85rem; }
  .nav-cta .btn-accent { padding: 11px 16px; }
}
@media (max-width: 1060px) and (min-width: 901px) {
  /* not enough room for the number as well; the call button stays in the floating bar */
  .nav-call { display: none; }
}

/* components.css sets .nav-row side padding to 0, which put the logo and
   menu button flush against the screen edges below the container width */
@media (max-width: 1228px) {
  .site-header .nav-row { padding-left: var(--space-4); padding-right: var(--space-4); }
}

/* Small phones: keep logo, name, Get Quote and menu button inside the screen */
@media (max-width: 480px) {
  .nav-row { gap: 8px; }
  .brand { font-size: 1.05rem; gap: 7px; min-width: 0; }
  .brand > span:last-child { text-shadow: 0 1px 0 #c9d3de, 0 2px 0 #f06203, 0 4px 6px rgba(2, 28, 51, 0.18); }
  .brand-mark { width: 38px; height: 38px; }
  .brand-badge { font-size: 0.58rem; padding: 2px 7px; white-space: nowrap; }
  .nav-cta { gap: 8px; }
  .nav-cta .btn-accent { padding: 10px 12px; font-size: 0.8rem; }
  .nav-toggle { width: 38px; height: 38px; }
  .nav-toggle span { top: 18px; }
}

@media (prefers-reduced-motion: reduce) {
  .brand-mark { transition: none; }
  .brand:hover .brand-mark { transform: none; }
}
