/* ==========================================================================
   Valure Support — styles
   Light mode only. Brand colour is used for links, buttons and highlights;
   everything else is white and soft greys.
   ========================================================================== */

/* ---------- Fonts: Rethink Sans, bundled. Not used now: the site uses the system font (--font-body) ---------- */
@font-face { font-family: "Rethink Sans"; src: url("../assets/fonts/RethinkSans-Regular.woff2") format("woff2"); font-weight: 400; font-style: normal; font-display: swap; }
@font-face { font-family: "Rethink Sans"; src: url("../assets/fonts/RethinkSans-Medium.woff2") format("woff2"); font-weight: 500; font-style: normal; font-display: swap; }
@font-face { font-family: "Rethink Sans"; src: url("../assets/fonts/RethinkSans-SemiBold.woff2") format("woff2"); font-weight: 600; font-style: normal; font-display: swap; }
@font-face { font-family: "Rethink Sans"; src: url("../assets/fonts/RethinkSans-Bold.woff2") format("woff2"); font-weight: 700; font-style: normal; font-display: swap; }
@font-face { font-family: "Rethink Sans"; src: url("../assets/fonts/RethinkSans-ExtraBold.woff2") format("woff2"); font-weight: 800; font-style: normal; font-display: swap; }

/* ---------- Design tokens ---------- */
:root {
  --brand: #0207ff;
  --brand-hover: #0005d1;
  --brand-soft: #eef0ff;           /* tinted backgrounds (icons, <mark>) */
  --brand-ring: rgba(2, 7, 255, 0.16);

  --ink: #0a0b12;                  /* headings, primary text */
  --ink-2: #2f3340;                /* body copy */
  --muted: #646a78;                /* secondary text */
  --line: #e6e8ee;                 /* hairlines */
  --line-strong: #d3d6de;          /* decorative dividers */
  --control-border: #8a8f9c;       /* input and button edges, 3.2:1 on white */
  --surface: #f6f7f9;              /* soft grey panels */
  --page-grey: #f4f4f5;            /* homepage background below the hero */
  --card-border: #e6e6e6;
  --card-shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
  --white: #fff;

  --radius: 14px;
  --radius-sm: 10px;

  /* Apple's own font (San Francisco) on Apple devices, the closest system font elsewhere */
  --font-body: -apple-system, BlinkMacSystemFont, "SF Pro Text", "SF Pro Display", "Helvetica Neue", Helvetica, "Segoe UI", Roboto, Arial, sans-serif;
  --font-display: var(--font-body);

  --container: 1120px;
  --header-height: 72px;           /* it stays this height */
  --gutter: clamp(16px, 4vw, 32px);
}

/* ---------- Base ---------- */
*,
*::before,
*::after { box-sizing: border-box; }

html { -webkit-text-size-adjust: 100%; background: var(--white); }

body {
  margin: 0;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  background: var(--white);
  color: var(--ink);
  font-family: var(--font-body);
  font-size: 1rem;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

main { flex: 1; outline: none; }

img, svg { display: block; }

a { color: var(--brand); text-decoration: none; }
a:hover { text-decoration: underline; text-underline-offset: 3px; }

/* Visible focus for keyboard users everywhere */
:focus-visible {
  outline: 2px solid var(--brand);
  outline-offset: 3px;
  border-radius: 4px;
}

/* Headings receive focus after navigation (for screen readers); no ring needed */
h1:focus { outline: none; }

kbd {
  font-family: var(--font-body);
  font-size: 0.8125rem;
  font-weight: 500;
  line-height: 1.5;
  color: var(--muted);
  background: var(--surface);
  border: 1px solid var(--line-strong);
  border-radius: 6px;
  padding: 0 8px;
}

mark {
  background: var(--brand-soft);
  color: inherit;
  border-radius: 3px;
  padding: 0 1px;
}

.visually-hidden {
  position: absolute !important;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0 0 0 0);
  white-space: nowrap;
  border: 0;
}

.skip-link {
  position: absolute;
  left: 16px;
  top: -60px;
  z-index: 100;
  padding: 10px 16px;
  background: var(--brand);
  color: var(--white);
  border-radius: var(--radius-sm);
  font-weight: 600;
}
.skip-link:focus { top: 12px; }

.container {
  max-width: var(--container);
  margin: 0 auto;
  padding-inline: var(--gutter);
}

/* Line icons (inline SVG) */
.icon {
  width: 20px;
  height: 20px;
  flex: none;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.75;
  stroke-linecap: round;
  stroke-linejoin: round;
}

/* ---------- Buttons ---------- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  height: 48px;
  padding: 0 22px;
  border: 1px solid var(--brand);
  border-radius: 999px;
  background: var(--brand);
  color: var(--white);
  font: inherit;
  font-size: 0.9375rem;
  font-weight: 600;
  cursor: pointer;
  transition: background-color 0.15s, border-color 0.15s, color 0.15s;
}
.btn:hover { background: var(--brand-hover); border-color: var(--brand-hover); text-decoration: none; }

.btn--ghost {
  background: var(--white);
  border-color: var(--line-strong);
  color: var(--ink);
}
.btn--ghost:hover { background: var(--white); border-color: var(--brand); color: var(--brand); }

/* ---------- Header ---------- */
/* Exactly the status page's header (status/public/status.css): part of the page and clear at
   the top, frosted white with a hairline when it slides back down (header.js) */
.site-header {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  z-index: 50;
  background: transparent;
  border-bottom: 1px solid transparent;
  -webkit-backdrop-filter: blur(0);
  backdrop-filter: blur(0);
  will-change: transform;
  transition: background-color 0.6s ease, border-color 0.6s ease, backdrop-filter 0.6s ease, -webkit-backdrop-filter 0.6s ease;
  font-family: "Rethink Sans", system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
}
/* Part of the page at the top (header.js): the page starts below it */
html:not([data-header="static"]) body { padding-top: calc(var(--header-height) + 1px); }
/* Out of sight, it floats: above the screen when hidden, sliding down when shown */
.header-floating .site-header { position: fixed; }
.header-floating.header-hidden .site-header { transform: translateY(-100%); }

.header-scrolled .site-header {
  background: rgba(255, 255, 255, 0.8);
  -webkit-backdrop-filter: blur(12px);
  backdrop-filter: blur(12px);
  border-bottom-color: #e6e8ee;
}
.header-animate .site-header { transition: transform var(--header-motion), background-color 0.6s ease, border-color 0.6s ease, backdrop-filter 0.6s ease, -webkit-backdrop-filter 0.6s ease; }

/* The same header as the status page (status/public): full width, the logo on the left,
   quiet links on the right, then Sign in */
.site-header__inner {
  height: var(--header-height);
  display: flex;
  align-items: center;
  gap: 16px;
  padding-inline: 40px;
}
/* Solid when the browser can't blur, or the visitor asked for less transparency */
@supports not ((backdrop-filter: blur(1px)) or (-webkit-backdrop-filter: blur(1px))) {
  .header-scrolled .site-header { background: #fff; }
}
@media (prefers-reduced-transparency: reduce) {
  .header-scrolled .site-header { background: #fff; -webkit-backdrop-filter: none; backdrop-filter: none; }
}
@media (prefers-reduced-motion: reduce) {
  .site-header, .header-animate .site-header { transition: none; }
}

/* --header-shown is how much of the header is on screen (header.js); sticky bars use it */
:root {
  --header-shown: calc(var(--header-height) + 1px);
  --header-motion: 0.5s cubic-bezier(0.4, 0, 0.2, 1);
}

.brand { display: inline-flex; align-items: center; gap: 12px; min-height: 44px; color: var(--ink); text-decoration: none; }
.brand:hover { opacity: 0.8; text-decoration: none; }
.brand__logo { display: block; height: 24px; width: auto; }
.brand__label { color: #6e6e73; font-size: 1.375rem; font-weight: 400; line-height: 1; letter-spacing: -0.01em; transform: translateY(1px); }

.site-nav { display: flex; align-items: center; gap: 32px; margin-left: auto; }
.site-nav a {
  display: inline-flex;
  align-items: center;
  min-height: 44px;
  color: var(--muted);
  font-size: 0.875rem;
  white-space: nowrap;
  text-decoration: none;
  transition: color 0.15s;
}
.site-nav a:hover { color: var(--ink); text-decoration: none; }

@media (max-width: 600px) {
  .site-header__inner { padding-inline: 20px; }
  .site-nav { gap: 24px; }
  .brand__label { font-size: 1.125rem; }
}
@media (max-width: 480px) {
  .brand__label { display: none; }
  .site-nav { gap: 16px; }
  .site-nav a:nth-child(n + 3) { display: none; }
}


/* ---------- Hero (homepage), like Apple Support: big V circle, big title, short line ---------- */
.hero {
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: 72px var(--gutter) 72px;
  background: transparent;
  text-align: center;
}

.hero__logo { width: 112px; height: auto; aspect-ratio: 129 / 108; }

.hero__title {
  margin: 48px 0 0;
  font-size: 4rem;
  font-weight: 600;
  line-height: 1.05;
  letter-spacing: -0.015em;
}

.hero__lead {
  margin: 28px 0 0;
  font-size: 1.75rem;
  line-height: 1.15;
}

@media (max-width: 720px) {
  .hero { padding: 48px var(--gutter) 44px; }
  .hero__logo { width: 80px; }
  .hero__title { margin-top: 32px; font-size: 2.75rem; }
  .hero__lead { margin-top: 16px; font-size: 1.3125rem; }
}

/* ---------- Homepage body ---------- */
/* The search stays on white with the hero; the grey starts at the topics */
.home-body { background: transparent; }

.home-section { padding-top: 56px; }
.home-section:last-child { padding-bottom: 56px; }
.home-section--topics { background: transparent; }

.home-title {
  margin: 0 0 8px;
  font-size: clamp(1.5rem, 2.4vw, 1.75rem);
  font-weight: 700;
  line-height: 1.43;
}
.home-lead { margin: 0 0 24px; font-size: 1.125rem; line-height: 1.45; }
.home-lead--narrow { max-width: 600px; }

.ask__card {
  scroll-margin-top: calc(var(--header-height) + 24px);   /* asking a question scrolls the card here */
  padding: 32px 32px 24px;
  background: var(--white);
  border: 1px solid var(--card-border);
  border-radius: 24px;
  box-shadow: var(--card-shadow);
}
@media (max-width: 560px) { .ask__card { padding: 20px 16px 16px; } }

.home-section--ask { padding-top: 0; padding-bottom: 64px; }

/* ---------- Feature cards, like Apple's support page ----------
   Half picture, half text. The picture is a grid of line icons with frosted glass bubbles
   (featureArt in js/app.js). Every other card has the picture on the right */
.home-section--features { padding-top: 64px; }
.feature {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  min-height: 460px;
  overflow: hidden;
  border-radius: 28px;
  background: var(--white);
  box-shadow: 0 2px 12px rgba(0, 0, 0, 0.05);
}
.feature + .feature { margin-top: 24px; }
.feature--reverse .feature__art { order: 2; }

.feature__text {
  display: flex;
  flex-direction: column;
  justify-content: center;
  padding: clamp(32px, 7vw, 96px);
}
.feature__title {
  margin: 0;
  font-size: clamp(2rem, 3.6vw, 3rem);
  font-weight: 600;
  line-height: 1.08;
  letter-spacing: -0.02em;
  color: #1d1d1f;
}
.feature__body { margin: 20px 0 0; color: #1d1d1f; font-size: 1.1875rem; line-height: 1.5; }
.feature__link { align-self: flex-start; margin-top: 24px; color: var(--brand); font-size: 1.1875rem; text-decoration: none; }
.feature__link:hover { text-decoration: underline; }

.feature__art { position: relative; min-height: 320px; overflow: hidden; }
.feature__art--light { background: #f5f5f7; color: #c7c7cc; }
.feature__art--blue { background: linear-gradient(180deg, #8c9bff 0%, #4a5cff 100%); color: rgba(255, 255, 255, 0.55); }

.feature__grid {
  position: absolute;
  inset: -12px;
  display: grid;
  grid-template-columns: repeat(8, 104px);
  grid-auto-rows: 100px;
  place-items: center;
}
.feature__grid svg, .feature__bubble svg {
  width: 40px; height: 40px;
  fill: none; stroke: currentColor; stroke-width: 1.5; stroke-linecap: round; stroke-linejoin: round;
}

/* Frosted glass bubbles over the grid */
.feature__bubble {
  position: absolute;
  display: grid;
  place-items: center;
  width: 190px;
  height: 190px;
  border-radius: 50%;
  border: 1px solid rgba(255, 255, 255, 0.7);
  background: rgba(255, 255, 255, 0.35);
  -webkit-backdrop-filter: blur(10px) saturate(1.6);
  backdrop-filter: blur(10px) saturate(1.6);
  box-shadow: inset 0 2px 6px rgba(255, 255, 255, 0.8), inset 0 -10px 30px rgba(255, 255, 255, 0.25), 0 20px 40px rgba(10, 11, 18, 0.12);
}
.feature__bubble > span {
  display: grid;
  place-items: center;
  width: 96px;
  height: 96px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.55);
  box-shadow: inset 0 1px 3px rgba(255, 255, 255, 0.9), 0 6px 16px rgba(10, 11, 18, 0.08);
}
.feature__bubble svg { width: 48px; height: 48px; stroke-width: 1.8; }
.feature__art--light .feature__bubble { background: rgba(255, 255, 255, 0.6); }
.feature__art--light .feature__bubble svg { color: var(--brand); }
.feature__art--blue .feature__bubble svg { color: #fff; }
.feature__bubble--1 { left: calc(50% - 150px); top: calc(50% - 130px); }
.feature__bubble--2 { left: calc(50% - 10px); top: calc(50% - 30px); }

@supports not ((backdrop-filter: blur(1px)) or (-webkit-backdrop-filter: blur(1px))) {
  .feature__bubble { background: rgba(255, 255, 255, 0.75); }
}

@media (max-width: 820px) {
  .feature { grid-template-columns: 1fr; min-height: 0; }
  .feature--reverse .feature__art { order: 0; }
  .feature__art { min-height: 300px; }
  .feature__bubble { width: 150px; height: 150px; }
  .feature__bubble > span { width: 76px; height: 76px; }
  .feature__bubble svg { width: 38px; height: 38px; }
  .feature__bubble--1 { left: calc(50% - 125px); top: calc(50% - 105px); }
  .feature__bubble--2 { left: calc(50% - 15px); top: calc(50% - 30px); }
}

.ask__subtitle { margin: 28px 0 12px; font-size: 1.125rem; font-weight: 700; }

/* With an answer showing, the card is only the search bar and the answer */
.ask__card.is-answering .ask__extras { display: none; }


/* Popular questions as chips */
.question-chips { list-style: none; margin: 0; padding: 0; display: flex; flex-wrap: wrap; gap: 12px; }
.question-chip {
  display: inline-flex;
  align-items: center;
  min-height: 44px;
  padding: 8px 12px;
  color: var(--ink);
  font: inherit;
  font-size: 0.875rem;
  text-align: left;
  background: var(--white);
  border: 1px solid var(--card-border);
  border-radius: 8px;
  cursor: pointer;
  transition: border-color 0.15s, color 0.15s;
}
.question-chip:hover { color: var(--brand); border-color: var(--brand); text-decoration: none; }

/* Cards: topics and "More ways to get help" */
.service-grid {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 16px;
}
@media (max-width: 900px) { .service-grid { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 560px) { .service-grid { grid-template-columns: 1fr; } }

.service-card {
  position: relative;
  display: flex;
  flex-direction: column;
  gap: 20px;
  padding: 24px;
  color: var(--ink);
  background: var(--white);
  border: 1px solid var(--card-border);
  border-radius: 24px;
  box-shadow: var(--card-shadow);
  transition: border-color 0.15s;
}
.service-card:hover { border-color: var(--brand); }

.service-card__icon {
  display: grid;
  place-items: center;
  width: 48px;
  height: 48px;
  color: var(--ink);
  background: var(--page-grey);
  border-radius: 50%;
}
.service-card__icon .icon { width: 22px; height: 22px; }

.service-card__title { margin: 0 0 8px; font-size: 1.125rem; font-weight: 700; line-height: 1.45; }
/* The whole card is clickable through the title link */
.service-card__title a { display: inline-flex; align-items: center; gap: 4px; color: inherit; }
.service-card__title a::after { content: ""; position: absolute; inset: 0; border-radius: inherit; }
.service-card__title a:hover { text-decoration: none; }
.service-card__title .icon { width: 18px; height: 18px; stroke-width: 2; transition: transform 0.15s; }
.service-card:hover .service-card__title .icon { transform: translateX(3px); }
.service-card__text { margin: 0; color: var(--ink-2); font-size: 0.9375rem; line-height: 1.5; }

/* ---------- Answers under the homepage search ---------- */
.ask__note { margin: 20px 0 0; color: var(--muted); font-size: 0.875rem; }

/* Short answer, inside the search card under a divider */
.answer { margin-top: 24px; padding-top: 28px; border-top: 1px solid var(--card-border); }

/* Whole answer, in its own card below */
.answer-card {
  margin-top: 24px;
  padding: 28px 32px 32px;
  background: var(--white);
  border: 1px solid var(--card-border);
  border-radius: 24px;
  box-shadow: var(--card-shadow);
  scroll-margin-top: calc(var(--header-height) + 16px);
}
@media (max-width: 560px) { .answer-card { padding: 24px 16px; } }

.answer__title {
  max-width: 760px;
  margin: 0 0 10px;
  font-size: clamp(1.375rem, 2.4vw, 1.75rem);
  font-weight: 700;
  line-height: 1.3;
}
.answer__title:focus { outline: none; }

.answer__text { max-width: 760px; margin: 0 0 20px; font-size: 1.0625rem; line-height: 1.6; }

/* "Show full answer" and "Need more help?" side by side, so help is always in view */
.answer__actions { display: flex; flex-wrap: wrap; align-items: center; gap: 8px 24px; }
.answer__actions .answer__more-help { margin-top: 0; }

.answer__expand { height: 44px; padding: 0 20px; border-radius: 999px; }
.answer__expand .icon { width: 18px; height: 18px; stroke-width: 2; }

.answer__body { max-width: 760px; }
.answer__body > :first-child { margin-top: 0; }
.answer__body > :last-child { margin-bottom: 0; }

.answer__subtitle { margin: 28px 0 10px; font-size: 1.125rem; font-weight: 700; }

/* Full answer: one line of links to the articles it came from */
.answer__learn { max-width: 760px; margin: 16px 0 0; color: var(--muted); font-size: 0.9375rem; }

/* Full answer footer: "Was this answer helpful?" and "Need more help?" in one row.
   Sticks to the bottom of the window if the card is ever taller than the screen. */
.answer__footer {
  position: sticky;
  bottom: 0;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 8px 24px;
  margin: 20px -32px -32px;
  padding: 10px 32px;
  background: var(--white);
  border-top: 1px solid var(--card-border);
  border-radius: 0 0 24px 24px;
}
@media (max-width: 560px) {
  .answer__footer { margin: 16px -16px -24px; padding: 8px 16px; }
}
/* The full answer sits in the search card, so the footer runs to its edges */
.ask__card .answer__footer { margin: 24px -32px -24px; }
@media (max-width: 560px) {
  .ask__card .answer__footer { margin: 20px -16px -16px; }
}
.answer__feedback { display: flex; flex-wrap: wrap; align-items: center; gap: 8px 14px; }
.answer__question { font-weight: 600; }
.answer__footer .answer__thanks { margin: 0; }
.answer__footer .answer__more-help { margin-top: 0; }
.answer__votes { display: flex; flex-wrap: wrap; gap: 12px; }
.vote {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  min-height: 44px;
  padding: 0 14px;
  color: var(--ink);
  font: inherit;
  background: var(--white);
  border: 1px solid var(--control-border);
  border-radius: 8px;
  cursor: pointer;
  transition: border-color 0.15s, color 0.15s, background-color 0.15s;
}
.vote:hover { color: var(--brand); border-color: var(--brand); }
.vote[aria-pressed="true"] { color: var(--white); background: var(--brand); border-color: var(--brand); }
.answer__thanks { margin: 10px 0 0; color: var(--muted); font-size: 0.9375rem; }
.answer__thanks:empty { display: none; }

.answer__more-help {
  display: inline-flex;
  align-items: center;
  min-height: 44px;
  margin-top: 12px;
  padding: 0;
  color: var(--brand);
  font: inherit;
  font-size: 1.0625rem;
  font-weight: 700;
  background: none;
  border: 0;
  cursor: pointer;
}
.answer__more-help:hover { text-decoration: underline; text-underline-offset: 3px; }

/* Skeleton while the answer loads */
.answer__skeleton { display: grid; gap: 14px; justify-items: start; }
.skel {
  display: block;
  height: 16px;
  width: 100%;
  max-width: 760px;
  border-radius: 6px;
  background: #e2e3e8;
  animation: skeleton 1.2s ease-in-out infinite alternate;
}
.skel--title { width: 55%; height: 30px; margin-bottom: 4px; }
.skel--short { width: 70%; }
.skel--button { width: 190px; height: 44px; margin-top: 8px; border-radius: 999px; }
@keyframes skeleton { from { opacity: 1; } to { opacity: 0.55; } }

/* ---------- "Need more help?" pop-up ---------- */
html.modal-open { overflow: hidden; }

/* The dialog fills the window as the dimmed backdrop; the panel sits inside */
.modal {
  position: fixed;
  inset: 0;
  width: 100%;
  max-width: none;
  height: 100%;
  max-height: none;
  margin: 0;
  padding: 24px 16px;
  display: grid;
  place-items: center;
  overflow-y: auto;
  border: 0;
  background: rgba(10, 11, 18, 0.5);
  opacity: 0;
  transition: opacity 0.2s ease;
}
.modal:not([open]) { display: none; }
.modal::backdrop { background: transparent; }
.modal.is-open { opacity: 1; }

/* The "Need more help?" pop-up: a short title, one line of advice and the options as
   one grouped list, like the iPhone's Settings */
.modal__panel {
  width: min(100%, 520px);
  padding: 28px 28px 32px;
  background: var(--white);
  border-radius: 24px;
  box-shadow: 0 24px 64px rgba(10, 11, 18, 0.22);
  transform: translateY(12px) scale(0.98);
  transition: transform 0.25s cubic-bezier(0.2, 0.8, 0.2, 1);
}
.modal.is-open .modal__panel { transform: none; }
@media (max-width: 560px) { .modal__panel { padding: 24px 20px 24px; } }

.modal__head { display: flex; align-items: center; justify-content: space-between; gap: 16px; }
.modal__title { margin: 0; font-size: 1.75rem; font-weight: 700; line-height: 1.2; letter-spacing: -0.01em; }
.modal__close {
  display: grid;
  place-items: center;
  flex: none;
  width: 32px;
  height: 32px;
  margin-right: -4px;
  padding: 0;
  color: var(--muted);
  background: var(--page-grey);
  border: 0;
  border-radius: 50%;
  cursor: pointer;
  transition: background-color 0.15s, color 0.15s;
}
.modal__close:hover { color: var(--ink); background: #e8e8ed; }
.modal__close:focus-visible { outline: 2px solid var(--brand); outline-offset: 2px; }
.modal__close .icon { width: 16px; height: 16px; stroke-width: 2.4; }

.modal__lead { margin: 10px 0 24px; font-size: 1.0625rem; line-height: 1.5; color: var(--ink-2); }
.modal__options[hidden], .modal__signin[hidden] { display: none; }
/* Signed out: one Sign in button instead of the options */
.modal__signin { display: flex; flex-direction: column; align-items: stretch; gap: 14px; }
.modal__signin-button { height: 50px; font-size: 1rem; color: var(--white); }
.modal__signin-button:hover { color: var(--white); }
.modal__signin-note { margin: 0; color: var(--muted); font-size: 0.875rem; line-height: 1.5; text-align: center; }

.modal__options {
  list-style: none;
  margin: 0;
  padding: 0;
  overflow: hidden;
  border: 1px solid var(--card-border);
  border-radius: 16px;
}
.modal__options li + li { border-top: 1px solid var(--card-border); }

.option {
  display: flex;
  align-items: center;
  gap: 16px;
  width: 100%;
  padding: 16px 16px 16px 18px;
  color: var(--ink);
  font: inherit;
  text-align: left;
  text-decoration: none;
  background: var(--white);
  border: 0;
  cursor: pointer;
  transition: background-color 0.15s;
}
.option:hover { background: var(--page-grey); text-decoration: none; }
.option:focus-visible { outline: 2px solid var(--brand); outline-offset: -2px; }

.option__icon { display: grid; place-items: center; flex: none; width: 28px; color: var(--brand); }
.option__icon .icon { width: 24px; height: 24px; stroke-width: 1.8; }
.option__body { display: flex; flex-direction: column; gap: 2px; flex: 1; min-width: 0; }
.option__title { font-size: 1.0625rem; font-weight: 600; line-height: 1.35; }
.option__text { font-size: 0.9375rem; line-height: 1.45; color: var(--muted); }
.option__chevron { flex: none; color: #c7c7cc; }
.option__chevron .icon { width: 18px; height: 18px; stroke-width: 2.2; }
.option:hover .option__chevron { color: var(--muted); }

/* ---------- Search: a pill field with the Search button inside ---------- */
.search { position: relative; width: 100%; }
.search--sm { max-width: 560px; }

.search__field { position: relative; display: flex; align-items: center; }

.search__input {
  width: 100%;
  height: 68px;
  padding: 0 156px 0 24px;
  font: inherit;
  font-size: 1rem;
  color: var(--ink);
  background: var(--white);
  border: 1px solid #666a73;
  border-radius: 999px;
  outline: none;
  -webkit-appearance: none;
  appearance: none;
  transition: border-color 0.15s, box-shadow 0.15s;
}
.search__input::placeholder { color: #6b7180; }  /* 4.9:1 on white */
.search__input:hover { border-color: var(--ink-2); }
.search__input:focus { border-color: var(--brand); box-shadow: 0 0 0 4px var(--brand-ring); }
.search__input::-webkit-search-cancel-button { -webkit-appearance: none; }

.search__submit {
  position: absolute;
  right: 6px;
  top: 6px;
  bottom: 6px;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 0 32px;
  color: var(--white);
  font: inherit;
  font-size: 1.125rem;
  font-weight: 600;
  background: var(--brand);
  border: 0;
  border-radius: 999px;
  cursor: pointer;
  transition: background-color 0.15s;
}
.search__submit:hover { background: var(--brand-hover); }
.search__submit:focus-visible { outline-offset: 2px; }
.search__submit .icon { width: 20px; height: 20px; stroke-width: 2; }

/* The thin version in the band on inner pages */
.search--sm .search__input {
  height: 40px;
  padding: 0 104px 0 18px;
  font-size: 0.9375rem;
}
.search--sm .search__submit {
  right: 4px;
  top: 4px;
  bottom: 4px;
  gap: 6px;
  padding: 0 14px;
  font-size: 0.875rem;
}
.search--sm .search__submit .icon { width: 16px; height: 16px; }

/* Phones: the button shows only its icon (the label stays for screen readers) */
@media (max-width: 560px) {
  .search__input { padding-right: 72px; }
  .search--sm .search__input { padding-right: 52px; }
  .search__submit { padding: 0 18px; }
  .search--sm .search__submit { padding: 0 12px; }
  .search__submit-label {
    position: absolute; width: 1px; height: 1px; overflow: hidden;
    clip: rect(0 0 0 0); white-space: nowrap;
  }
}

/* ---------- Homepage sections ---------- */
.section { padding: clamp(40px, 6vw, 72px) 0; }

.section__title {
  margin: 0 0 28px;
  font-family: var(--font-display);
  font-size: clamp(1.5rem, 2.6vw, 1.875rem);
  font-weight: 700;
  letter-spacing: -0.02em;
  line-height: 1.2;
}

/* ---------- Inner pages ---------- */
/* Search band on inner pages: sticks right under the header */
.page-search {
  position: sticky;
  top: var(--header-shown);   /* follows the header as it slides */
  z-index: 40;
  padding: 10px 0;
  background: var(--white);
  border-bottom: 1px solid var(--line);
  will-change: transform;
}
/* The band slides away with the header, and back with it */
.header-hidden .page-search { transform: translateY(-100%); }
.header-animate .page-search { transition: top var(--header-motion), transform var(--header-motion); }
@media (prefers-reduced-motion: reduce) {
  .header-animate .page-search { transition: none; }
}

.page { padding-block: clamp(32px, 5vw, 56px) clamp(56px, 8vw, 96px); }
.page--narrow { max-width: calc(760px + 2 * var(--gutter)); }

.breadcrumb {
  list-style: none;
  margin: 0 0 28px;
  padding: 0;
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  color: var(--muted);
  font-size: 0.875rem;
}
.breadcrumb li + li::before { content: "/"; margin-right: 6px; color: var(--line-strong); }
.breadcrumb a { color: var(--muted); }
.breadcrumb a:hover { color: var(--brand); }
.breadcrumb [aria-current] { color: var(--ink-2); }

.page-title {
  margin: 0 0 12px;
  font-family: var(--font-display);
  font-size: clamp(1.75rem, 3.6vw, 2.25rem);
  font-weight: 700;
  line-height: 1.25;
}

.page-lead { margin: 0; color: var(--muted); font-size: 1.125rem; }
.meta { margin: 0; color: var(--muted); font-size: 0.875rem; }

/* ---------- Topic pages (like SAS's travel info centre) ---------- */
.topics-intro { padding-block: 24px 48px; }
.topics-intro .breadcrumb { margin-bottom: 20px; }

.topics-intro__title {
  margin: 0 0 12px;
  font-size: clamp(1.875rem, 3.6vw, 2.5rem);
  font-weight: 700;
  line-height: 1.25;
}
.topics-intro__lead { margin: 0 0 40px; font-size: 1rem; }

/* Stage cards: filter the topics below */
.stage-cards {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 24px;
}
@media (max-width: 900px) { .stage-cards { grid-template-columns: repeat(2, 1fr); gap: 16px; } }

.stage-card {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 24px;
  width: 100%;
  height: 100%;
  padding: 24px;
  color: var(--ink);
  font: inherit;
  text-align: left;
  background: var(--white);
  border: 1px solid var(--card-border);
  border-radius: 16px;
  box-shadow: var(--card-shadow);
  cursor: pointer;
  transition: border-color 0.15s, background-color 0.15s, color 0.15s;
}
.stage-card:hover { border-color: var(--brand); }
.stage-card[aria-pressed="true"] { color: var(--white); background: var(--brand); border-color: var(--brand); }
.stage-card[aria-pressed="true"]:focus-visible { outline-color: var(--ink); }

.stage-card__icon {
  display: grid;
  place-items: center;
  width: 64px;
  height: 64px;
  color: var(--white);
  background: var(--brand);
  border-radius: 50%;
}
.stage-card[aria-pressed="true"] .stage-card__icon { color: var(--brand); background: var(--white); }
.stage-card__icon .icon { width: 28px; height: 28px; stroke-width: 2; }

.stage-card__label { display: inline-flex; align-items: center; gap: 4px; font-size: 1.125rem; font-weight: 700; line-height: 1.4; }
.stage-card__label .icon { width: 18px; height: 18px; stroke-width: 2; }

@media (max-width: 560px) {
  .stage-card { gap: 16px; padding: 16px; }
  .stage-card__icon { width: 48px; height: 48px; }
  .stage-card__icon .icon { width: 22px; height: 22px; }
  .stage-card__label { font-size: 1rem; }
}

/* Grey part: the topic grid, then the chosen topic and its articles */
.topics-body { padding-block: 48px 64px; background: transparent; }

.topic-buttons {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 24px;
}
@media (max-width: 900px) { .topic-buttons { grid-template-columns: repeat(2, 1fr); gap: 16px; } }
@media (max-width: 560px) { .topic-buttons { grid-template-columns: 1fr; gap: 12px; } }

.topic-button {
  display: flex;
  align-items: center;
  height: 100%;
  min-height: 68px;
  padding: 12px 24px;
  color: var(--ink);
  font-weight: 700;
  line-height: 1.35;
  background: var(--white);
  border: 1px solid var(--card-border);
  border-radius: 12px;
  box-shadow: var(--card-shadow);
  transition: border-color 0.15s, background-color 0.15s, color 0.15s;
}
.topic-button:hover { border-color: var(--brand); text-decoration: none; }
.topic-button[aria-current="page"] { color: var(--white); background: var(--brand); border-color: var(--brand); }
.topic-button[aria-current="page"]:focus-visible { outline-color: var(--ink); }

.topic-detail { margin-top: 56px; scroll-margin-top: calc(var(--header-height) + 24px); transition: opacity 0.15s ease-in; }
.topic-detail.is-switching { opacity: 0; }
.topic-detail__title { margin: 0 0 12px; font-size: clamp(1.5rem, 2.4vw, 1.75rem); font-weight: 700; line-height: 1.43; }
.topic-detail__lead { max-width: 560px; margin: 0 0 24px; }

/* ---------- Article, opened on its topic's page (white, under the grey part) ---------- */
.topic-article { padding-block: 48px 64px; background: transparent; scroll-margin-top: var(--header-height); transition: opacity 0.15s ease-in; }
.topic-article.is-switching { opacity: 0; }
.topic-article__inner { max-width: 760px; }
.topic-article__title {
  margin: 0 0 16px;
  font-size: clamp(1.5rem, 2.4vw, 1.75rem);
  font-weight: 700;
  line-height: 1.43;
}
.topic-article__title:focus { outline: none; }
.topic-article__feedback { margin-top: 40px; padding-top: 8px; border-top: 1px solid var(--card-border); }

/* Readable body: ~70 characters per line */
.prose {
  max-width: 68ch;
  color: var(--ink-2);
  font-size: 1.0625rem;
  line-height: 1.75;
}
.prose > :first-child { margin-top: 0; }
.prose p { margin: 0 0 1.15em; }

.prose h2 {
  margin: 2.2em 0 0.6em;
  color: var(--ink);
  font-family: var(--font-display);
  font-size: 1.375rem;
  font-weight: 700;
  letter-spacing: -0.015em;
  line-height: 1.3;
}
.prose h3 { margin: 1.8em 0 0.5em; color: var(--ink); font-size: 1.125rem; font-weight: 600; }

.prose ul,
.prose ol { margin: 0 0 1.15em; padding-left: 1.4em; }
.prose li { margin: 0.35em 0; padding-left: 0.2em; }
.prose li::marker { color: var(--muted); }

.prose strong { color: var(--ink); font-weight: 600; }

.prose a {
  text-decoration: underline;
  text-decoration-color: rgba(2, 7, 255, 0.35);
  text-underline-offset: 3px;
}
.prose a:hover { text-decoration-color: var(--brand); }

.prose code {
  padding: 0.1em 0.4em;
  color: var(--ink);
  font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  font-size: 0.88em;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: 6px;
}

/* ---------- Search results page ---------- */
.results { list-style: none; margin: 32px 0 0; padding: 0; border-top: 1px solid var(--line); }
.result { padding: 24px 0; border-bottom: 1px solid var(--line); }
.result__title { font-size: 1.125rem; font-weight: 600; }
.result__meta { margin: 2px 0 8px; color: var(--muted); font-size: 0.8125rem; }
.result__snippet { margin: 0; color: var(--ink-2); font-size: 0.9375rem; }

/* Friendly empty / not-found states */
.empty {
  margin-top: 32px;
  padding: clamp(24px, 4vw, 40px);
  background: var(--surface);
  border-radius: var(--radius);
}
.empty__title { margin: 0 0 6px; font-size: 1.125rem; font-weight: 600; }
.empty p { margin: 0 0 20px; color: var(--muted); }
.empty .btn { margin-top: 4px; }

/* ---------- Footer ---------- */
/* A white sheet across the whole width at the very bottom of the page, with rounded top
   corners: the Valure logo and a line about Valure on the left, link columns on the right,
   the copyright under a hairline. The content lines up with the rest of the page */
.site-footer { margin-top: auto; padding-top: 56px; }
.footer-card {
  padding: 56px max(var(--gutter), calc((100% - 1240px) / 2)) 28px;
  background: var(--white);
  border-top: 1px solid #e3e3e8;
  border-radius: 40px 40px 0 0;
  color: var(--apple-muted, #6e6e73);
  font-size: 0.9375rem;
  line-height: 1.5;
}
/* When the page ends on the grey band, the footer starts right where the band ends:
   the white sheet with its rounded corners is all that's left, no gap, no line */
body:has(#app > :last-child .home-section--features:last-child) .site-footer { padding-top: 0; background: var(--apple-grey); }
body:has(#app > :last-child .home-section--features:last-child) .footer-card { border-top: 0; }
.site-footer a { color: var(--apple-ink-2, #424245); text-decoration: none; }
.site-footer a:hover { color: var(--brand); }
.site-footer a:focus-visible { outline: 2px solid var(--brand); outline-offset: 3px; border-radius: 4px; }

.footer-cols {
  display: grid;
  grid-template-columns: minmax(0, 2fr) repeat(3, minmax(0, 1fr));
  gap: 40px;
  padding-bottom: 40px;
  border-bottom: 1px solid #e3e3e8;
}
.footer-brand__link { display: inline-flex; align-items: center; min-height: 44px; }
.footer-brand__link:hover { opacity: 0.8; }
.footer-brand__logo { display: block; height: 28px; width: auto; }
.footer-brand__text { max-width: 300px; margin: 14px 0 0; }

.footer-col__title {
  margin: 10px 0 14px;
  color: var(--apple-muted, #6e6e73);
  font-size: 0.75rem;
  font-weight: 600;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}
.footer-col ul { list-style: none; margin: 0; padding: 0; display: grid; gap: 2px; }
.footer-col a { display: inline-block; padding-block: 8px; line-height: 1.35; }

.footer-legal { margin: 0; padding-top: 24px; font-size: 0.8125rem; }

@media (max-width: 900px) {
  .footer-cols { grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 32px 24px; }
  .footer-brand { grid-column: 1 / -1; }
}
@media (max-width: 560px) {
  .footer-card { padding: 36px 24px 20px; border-radius: 28px 28px 0 0; }
  .footer-cols { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}

/* ---------- Legal pages (terms.html, privacy.html) ----------
   Big title, a sticky list of sections on the left that follows your
   reading (js/legal.js), and lists shown as grouped cards. */
.legal-hero { padding-block: clamp(48px, 9vw, 104px) clamp(32px, 5vw, 56px); }
.legal-hero__title {
  margin: 0 0 14px;
  font-size: clamp(2.75rem, 7vw, 4.5rem);
  font-weight: 700;
  line-height: 1.05;
  letter-spacing: -0.015em;
}
.legal-hero__lead { max-width: 640px; margin: 0 0 14px; color: var(--ink-2); font-size: clamp(1.125rem, 2.2vw, 1.3125rem); line-height: 1.5; }
.legal-hero__date { margin: 0; color: var(--muted); font-size: 0.9375rem; }

.legal-layout {
  display: grid;
  grid-template-columns: 220px minmax(0, 720px);
  gap: clamp(32px, 5vw, 56px);
  padding-bottom: clamp(64px, 9vw, 112px);
}

.legal-nav { position: sticky; top: calc(var(--header-shown) + 24px); align-self: start; }
.header-animate .legal-nav { transition: top var(--header-motion); }
@media (prefers-reduced-motion: reduce) {
  .header-animate .legal-nav { transition: none; }
}
.legal-nav ol { list-style: none; margin: 0; padding: 0; display: grid; gap: 2px; }
.legal-nav a {
  display: flex;
  align-items: center;
  min-height: 36px;
  padding: 6px 12px;
  border-radius: var(--radius-sm);
  color: var(--muted);
  font-size: 0.875rem;
  line-height: 1.35;
  transition: background-color 0.15s, color 0.15s;
}
.legal-nav a:hover { color: var(--ink); background: var(--surface); text-decoration: none; }
.legal-nav a[aria-current="true"] { color: var(--brand); background: var(--brand-soft); font-weight: 600; }

.legal-section { scroll-margin-top: calc(var(--header-height) + 24px); }
.legal-section + .legal-section { margin-top: clamp(40px, 6vw, 56px); }
.legal-section h2 { margin: 0 0 14px; font-size: clamp(1.5rem, 3vw, 1.75rem); font-weight: 700; line-height: 1.25; }
.legal-section p { margin: 0 0 1em; color: var(--ink-2); font-size: 1.0625rem; line-height: 1.65; }
.legal-section p strong, .legal-list strong { color: var(--ink); font-weight: 600; }
.legal-section a { text-decoration: underline; text-decoration-color: rgba(2, 7, 255, 0.35); text-underline-offset: 3px; }
.legal-section a:hover { text-decoration-color: var(--brand); }

.legal-list {
  list-style: none;
  margin: 0 0 1.25em;
  padding: 4px 24px;
  background: var(--surface);
  border-radius: 18px;
}
.legal-list li { position: relative; padding: 14px 0 14px 20px; color: var(--ink-2); line-height: 1.55; }
.legal-list li + li { border-top: 1px solid var(--line); }
.legal-list li::before {
  content: "";
  position: absolute;
  left: 2px;
  top: calc(14px + 0.78em - 3px);
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--brand);
}

/* Phones and small tablets: the sections become a row of chips under the header */
@media (max-width: 900px) {
  .legal-layout { grid-template-columns: minmax(0, 1fr); gap: 24px; }
  .legal-nav {
    top: var(--header-shown);
    z-index: 5;
    margin-inline: calc(-1 * var(--gutter));
    padding: 10px var(--gutter);
    background: var(--white);
    border-bottom: 1px solid var(--line);
  }
  .legal-nav ol { display: flex; gap: 8px; overflow-x: auto; scrollbar-width: none; }
  .legal-nav ol::-webkit-scrollbar { display: none; }
  .legal-nav a { white-space: nowrap; min-height: 40px; padding: 8px 14px; border: 1px solid var(--line); border-radius: 999px; }
  .legal-nav a[aria-current="true"] { border-color: transparent; }
  .legal-section { scroll-margin-top: calc(var(--header-height) + 80px); }
  .legal-list { padding-inline: 18px; }
}
@media (prefers-reduced-motion: reduce) { .legal-nav a { transition: none; } }

/* ---------- Tap targets ----------
   Small text links get a 44px-tall hit area; the negative margin keeps
   the visual layout unchanged. */
.breadcrumb a {
  display: inline-flex;
  align-items: center;
  min-height: 44px;
  margin-block: -12px;
}
.breadcrumb { row-gap: 14px; }


/* ---------- Motion: page changes and reveals ---------- */
/* The old page fades out quickly while the loading bar runs */
#app { transition: opacity 0.2s ease-in, transform 0.2s ease-in; }
#app.is-leaving { opacity: 0; transform: translateY(6px); }

/* New content fades and rises in */
.reveal { animation: reveal 0.45s cubic-bezier(0.22, 1, 0.36, 1) both; }
@keyframes reveal { from { opacity: 0; transform: translateY(14px); } }

/* Thin loading bar at the very top while a page loads */
.route-progress {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 100;
  height: 3px;
  background: var(--brand);
  transform: scaleX(0);
  transform-origin: 0 50%;
  opacity: 0;
  pointer-events: none;
}
.route-progress.is-loading {
  opacity: 1;
  animation: progress-load 0.55s cubic-bezier(0.3, 0.7, 0.4, 1) forwards;
}
.route-progress.is-done {
  opacity: 0;
  transform: scaleX(1);
  transition: transform 0.2s ease-out, opacity 0.3s ease 0.2s;
}
@keyframes progress-load { from { transform: scaleX(0); } to { transform: scaleX(0.8); } }

/* ---------- Motion preferences ---------- */
@media (prefers-reduced-motion: reduce) {
  * { transition: none !important; }
  .skel,
  .reveal { animation: none; }
  .route-progress { display: none; }
}

/* ---------- Sign in with Roblox, on the right of the header (js/header.js) ---------- */
/* White pills with a hairline, like the rest of the site. Signed in: avatar and username */
.account { position: relative; display: flex; align-items: center; min-height: 44px; margin-left: 28px; }

.account__signin, .account__button {
  display: inline-flex; align-items: center; height: 40px;
  border: 1px solid var(--line); border-radius: 999px; background: var(--white);
  box-shadow: 0 1px 2px rgba(10, 11, 18, 0.04);
  color: var(--ink); font: inherit; font-size: 0.9375rem; font-weight: 500; white-space: nowrap;
  text-decoration: none; cursor: pointer; transition: border-color 0.15s, box-shadow 0.15s;
}
.account__signin { padding: 0 18px; }
.account__button { gap: 10px; max-width: 220px; padding: 0 16px 0 4px; }
.account__signin:hover, .account__button:hover, .account__button[aria-expanded="true"] {
  border-color: var(--line-strong); box-shadow: 0 2px 8px rgba(10, 11, 18, 0.08); color: var(--ink); text-decoration: none;
}
.account__signin:focus-visible, .account__button:focus-visible, .account__item:focus-visible {
  outline: 2px solid var(--brand); outline-offset: 2px;
}
.account__label { overflow: hidden; text-overflow: ellipsis; }

.account__avatar {
  display: inline-flex; align-items: center; justify-content: center; flex: none;
  width: 32px; height: 32px; border-radius: 999px; background: var(--surface); object-fit: cover;
  color: var(--muted); font-size: 0.875rem; font-weight: 600;
}

.account__menu {
  position: absolute; top: calc(100% + 8px); right: 0; min-width: 180px; padding: 6px;
  border: 1px solid var(--line); border-radius: var(--radius); background: var(--white);
  box-shadow: 0 12px 32px rgba(10, 11, 18, 0.12);
}
.account__menu[hidden] { display: none; }
.account__item {
  display: flex; align-items: center; min-height: 40px; padding: 0 12px;
  border-radius: var(--radius-sm); color: var(--ink); font-size: 0.9375rem; text-decoration: none;
}
.account__item:hover { background: var(--surface); color: var(--ink); text-decoration: none; }

@media (max-width: 600px) {
  .account { margin-left: 16px; }
  .account__signin { padding: 0 14px; font-size: 0.875rem; }
  .account__button { padding: 0 4px; }
  .account__label { display: none; }
}


/* =====================================================================
   Clean, Apple-style pass (Human Interface Guidelines)
   - Content first: plain white page, light grey (#f5f5f7) for sections and tiles.
   - One surface treatment: tiles are a soft grey fill, no border and no shadow.
   - Quiet selection: blue text and a thin blue ring, never a solid blue block.
   - Blue is for links and the main button only. High-contrast text, 44px targets.
   ===================================================================== */
:root {
  --apple-grey: #f5f5f7;
  --apple-grey-hover: #ececf0;
  --apple-ink: #1d1d1f;
  --apple-ink-2: #424245;
  --apple-muted: #6e6e73;
}
body { color: var(--apple-ink); }

/* Homepage: the logo, the title and the search, nothing else above the fold */
.hero { padding: 64px var(--gutter) 40px; }
.hero__logo { width: 88px; }
.hero__title { margin-top: 32px; font-size: clamp(2.75rem, 5vw, 3.5rem); letter-spacing: -0.02em; }
.hero__lead { margin-top: 16px; color: var(--apple-ink-2); font-size: clamp(1.3125rem, 2.2vw, 1.75rem); }

/* The search card: the search bar, popular questions as outlined pills, and the answer under it */
.ask__card {
  padding: 40px;
  background: var(--white);
  border: 1px solid #e3e3e8;
  border-radius: 32px;
  box-shadow: 0 4px 24px rgba(10, 11, 18, 0.05);
}
@media (max-width: 560px) { .ask__card { padding: 20px 16px; border-radius: 24px; } }
.home-section--ask { padding-bottom: 72px; }
.ask__subtitle { margin: 32px 0 16px; color: var(--apple-ink); font-size: 1.125rem; font-weight: 600; }
.question-chips { gap: 12px; }
.question-chip {
  min-height: 48px;
  padding: 10px 22px;
  color: var(--apple-ink);
  font-size: 0.9375rem;
  background: var(--white);
  border: 1px solid #d2d2d7;
  border-radius: 999px;
}
.question-chip:hover { color: var(--apple-ink); background: var(--apple-grey); border-color: #c7c7cc; }
.ask__note { margin-top: 24px; color: var(--apple-muted); font-size: 0.875rem; }

/* Signed out: asking shows a sign-in instead of an answer */
.answer__signin { padding-top: 8px; }
.answer__signin-title { margin: 0 0 12px; color: var(--apple-ink); font-size: clamp(1.5rem, 2.6vw, 2rem); font-weight: 500; letter-spacing: -0.01em; }
.answer__signin-text { max-width: 640px; margin: 0 0 24px; color: var(--apple-ink-2); font-size: 1.125rem; line-height: 1.5; }
.answer__signin-button { height: 52px; padding: 0 28px; font-size: 1rem; color: var(--white); }
.answer__signin-button:hover { color: var(--white); }
.search__input { border-color: #d2d2d7; }
.search__input:hover { border-color: #86868b; }
.answer { border-top-color: #d2d2d7; }

/* Topics: one row of five grey tiles */
.home-title { color: var(--apple-ink); font-weight: 600; letter-spacing: -0.01em; }
.home-lead { color: var(--apple-ink-2); }
.service-grid { grid-template-columns: repeat(5, minmax(0, 1fr)); gap: 16px; }
@media (max-width: 1000px) { .service-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 560px) { .service-grid { grid-template-columns: 1fr; } }
.service-card {
  gap: 16px;
  padding: 24px 20px;
  background: var(--apple-grey);
  border: 0;
  border-radius: 18px;
  box-shadow: none;
  transition: background-color 0.2s;
}
.service-card:hover { background: var(--apple-grey-hover); border: 0; }
.service-card__icon { width: 44px; height: 44px; color: var(--brand); background: var(--white); }
.service-card__title { font-size: 1.0625rem; font-weight: 600; }
.service-card__text { color: var(--apple-ink-2); }
/* Centred, like Apple's product tiles; the whole tile is the link, so no arrow */
.service-card { align-items: center; text-align: center; }
.service-card__title a { display: inline; }
.service-card__title .icon { display: none; }

/* Feature cards on a full-width grey band, white and flat */
.home-section--features { margin-top: 72px; padding-block: 72px; background: var(--apple-grey); }
.feature { box-shadow: none; border-radius: 24px; }
.feature__art--light { background: #fbfbfd; }
.feature__title { color: var(--apple-ink); }
.feature__body { color: var(--apple-ink-2); }
.home-section--features + * { margin-top: 0; }
.home-body .home-section:last-child { padding-bottom: 72px; }

.home-section--features { margin-bottom: 0; }

/* Topic pages: flat tiles and quiet selection */
.topics-intro__title { font-weight: 600; letter-spacing: -0.015em; }
.stage-card {
  gap: 16px;
  background: var(--apple-grey);
  border: 0;
  border-radius: 18px;
  box-shadow: none;
  transition: background-color 0.2s, box-shadow 0.2s, color 0.2s;
}
.stage-card:hover { background: var(--apple-grey-hover); border: 0; }
.stage-card__icon { width: 48px; height: 48px; color: var(--apple-ink); background: var(--white); }
.stage-card__icon .icon { width: 22px; height: 22px; }
.stage-card__label { font-weight: 600; }
.stage-card[aria-pressed="true"] { color: var(--brand); background: var(--white); box-shadow: inset 0 0 0 2px var(--brand); }
.stage-card[aria-pressed="true"] .stage-card__icon { color: var(--brand); background: var(--apple-grey); }

.topic-button {
  min-height: 56px;
  padding: 12px 20px;
  font-weight: 600;
  background: var(--apple-grey);
  border: 0;
  border-radius: 14px;
  box-shadow: none;
}
.topic-button:hover { background: var(--apple-grey-hover); border: 0; }
.topic-button[aria-current="page"] { color: var(--brand); background: var(--white); box-shadow: inset 0 0 0 2px var(--brand); }
.topic-button[aria-current="page"]:focus-visible { outline-color: var(--brand); }
.topic-buttons { gap: 12px; }

/* An open article comes first: just the breadcrumb, then the answer,
   then the other articles in its topic. The browsing tiles step aside */
#app:has(.topic-article:not([hidden])) { display: flex; flex-direction: column; }
#app:has(.topic-article:not([hidden])) .topics-intro { order: 0; }
#app:has(.topic-article:not([hidden])) .topic-article { order: 1; padding-top: 8px; }
#app:has(.topic-article:not([hidden])) .topics-body { order: 2; padding-top: 0; }
#app:has(.topic-article:not([hidden])) .topics-intro__title,
#app:has(.topic-article:not([hidden])) .topics-intro__lead,
#app:has(.topic-article:not([hidden])) .stage-cards,
#app:has(.topic-article:not([hidden])) .topics-body > .container > .topic-buttons { display: none; }
#app:has(.topic-article:not([hidden])) .topic-detail { margin-top: 0; padding-top: 40px; border-top: 1px solid #d2d2d7; }
.topic-article__title { font-size: clamp(1.75rem, 3vw, 2.25rem); font-weight: 600; letter-spacing: -0.015em; color: var(--apple-ink); }
.prose { color: var(--apple-ink-2); }

/* Search band on inner pages: frosted, like the header */
.page-search { background: rgba(255, 255, 255, 0.85); -webkit-backdrop-filter: blur(20px) saturate(1.8); backdrop-filter: blur(20px) saturate(1.8); border-bottom-color: #d2d2d7; }

/* Legal pages */
.legal-list { background: var(--apple-grey); }
