/* Shared by every page: the top menu (Home · Privacy · Support · Delete account), one header
   width for all pages, and the 3D banner of the inner pages (assets/hero3d.js).
   The menu of the language on screen is shown with the same :target rule as the content;
   browsers without :has() show the English menu. */

/* Same header on every page (the legal pages keep their narrower text column). */
.nav-inner { max-width: 64rem; flex-wrap: nowrap; }

.menu { display: none; margin: 0 auto; }
.menu ul { list-style: none; margin: 0; padding: .2rem; display: flex; gap: .2rem; border: 1px solid #2a2a44; border-radius: 999px; background: rgba(27, 27, 48, .6); }
.menu a {
  display: inline-flex; align-items: center; gap: .4rem;
  min-height: 2.4rem; padding: .3rem .85rem; border-radius: 999px;
  color: #c4c2dd; text-decoration: none; font-weight: 700; font-size: .92rem; white-space: nowrap;
  transition: background-color .15s, color .15s;
}
.menu a:hover { color: #f4f3ff; background: rgba(139, 92, 246, .16); }
.menu a[aria-current="page"] { color: #fff; background: linear-gradient(135deg, #7C3AED, #a855f7); box-shadow: 0 4px 14px rgba(124, 58, 237, .45); }
.menu svg { width: 1.05rem; height: 1.05rem; flex: none; }

@supports selector(:has(*)) {
  body:not(:has(.lang:target, .lang :target)) .menu[data-l="en"],
  body:has(#en:target, #en :target) .menu[data-l="en"],
  body:has(#es:target, #es :target) .menu[data-l="es"],
  body:has(#fr:target, #fr :target) .menu[data-l="fr"] { display: block; }
}
@supports not selector(:has(*)) {
  .menu[data-l="en"] { display: block; }
}

/* ── 3D banner of the inner pages (Support, Privacy, Delete account) ── */
.page-visual { display: none; }
.has-3d .page-visual {
  display: block; position: relative; overflow: hidden;
  height: clamp(170px, 24vw, 230px); margin: 0 0 1.6rem;
  border: 1px solid #2a2a44; border-radius: 1.4rem;
  background:
    radial-gradient(60% 120% at 50% 50%, rgba(139, 92, 246, .28), transparent 70%),
    linear-gradient(160deg, #1b1735, #0f0f1a);
  box-shadow: 0 20px 50px rgba(0, 0, 0, .35), inset 0 1px 0 rgba(255, 255, 255, .05);
}
.page-visual .hero3d { display: block; width: 100%; height: 100%; }
.page-visual::after { display: none; }

/* ── Tablets and phones: the menu becomes a tab bar under the brand row ── */
@media (max-width: 900px) {
  .nav-inner { flex-wrap: wrap; }
  .menu { order: 3; flex-basis: 100%; }
  .menu ul { justify-content: space-between; }
}
@media (max-width: 640px) {
  [id] { scroll-margin-top: 9rem; }
  .menu ul { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); border-radius: 1rem; }
  .menu li { display: flex; }
  .menu a {
    flex: 1; flex-direction: column; justify-content: center; gap: .15rem;
    min-height: 3.1rem; padding: .3rem .2rem; border-radius: .8rem;
    font-size: .72rem; line-height: 1.15; text-align: center; white-space: normal;
  }
  .menu svg { width: 1.15rem; height: 1.15rem; }
}
@media (forced-colors: active) {
  .menu a[aria-current="page"] { border: 2px solid CanvasText; }
}
