/*
 * Components (DESIGN-SYSTEM.md §4 and §5).
 *
 * Every value here comes from tokens.css: no raw colour, no magic numbers that
 * are really tokens. Mobile first, 960px is the layout breakpoint.
 */

/* ------------------------------------------------------------------- base */

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

html {
  -webkit-text-size-adjust: 100%;
  scroll-behavior: smooth;
}

body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font-family: var(--font-body);
  font-size: var(--fs-body);
  line-height: var(--lh-body);
  -webkit-font-smoothing: antialiased;
}

h1,
h2,
h3 {
  margin: 0 0 var(--s-3);
  font-family: var(--font-display);
  font-weight: 600;
  color: var(--brand);
  line-height: var(--lh-h);
  letter-spacing: -0.01em;
}

h1 {
  font-size: var(--fs-h1);
  line-height: var(--lh-h1);
}

h2 {
  font-size: var(--fs-h2);
}

h3 {
  font-size: var(--fs-h3);
  line-height: 1.3;
}

p {
  margin: 0 0 var(--s-4);
  max-width: var(--measure);
}

ul,
ol {
  max-width: var(--measure);
}

img,
svg {
  max-width: 100%;
}

a {
  color: var(--link);
  text-underline-offset: 2px;
}

strong {
  font-weight: 600;
}

/* The GOV.UK focus pattern, in our tokens: a --focus halo, an --ink outline. */
a:focus-visible,
button:focus-visible,
input:focus-visible,
select:focus-visible,
summary:focus-visible,
[tabindex]:focus-visible {
  outline: 3px solid var(--ink);
  outline-offset: 2px;
  box-shadow: 0 0 0 7px var(--focus);
  border-radius: var(--radius-input);
}

[hidden] {
  display: none !important;
}

/* GOV.UK's one-thing-per-page questions are wrapped in fieldsets; the browser
   default border would draw a box around every question. */
fieldset {
  min-width: 0;
  margin: 0;
  padding: 0;
  border: 0;
}

legend {
  padding: 0;
}

.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
  font-size: var(--fs-small);
}

.wrap {
  max-width: var(--container);
  margin: 0 auto;
  padding: 0 var(--s-4);
}

main {
  padding-bottom: var(--s-6);
}

/* Each section takes half of --section-y top and bottom, so the gap between two
   sections is the token itself, not twice it. */
section {
  padding: calc(var(--section-y) / 2) 0;
}

/* Paper grain (DESIGN-SYSTEM.md section 9.4): one fixed overlay at under 5%
   opacity, pointer-events none, never on a scrolling container. */
body::after {
  content: "";
  position: fixed;
  inset: 0;
  z-index: 0;
  pointer-events: none;
  opacity: 0.045;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='220' height='220'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='.85' numOctaves='2' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
}

/* Entry reveal: hidden only after the page script has set class "js" on <html>
   and the element is marked .reveal. Content is visible without JavaScript. */
.js .reveal {
  opacity: 0;
  transform: translateY(var(--reveal-distance));
  transition: opacity var(--dur-3) var(--ease-out), transform var(--dur-3) var(--ease-out);
}

.js .reveal.is-in {
  opacity: 1;
  transform: none;
}

/* ----------------------------------------------------------------- chrome */

.site-head {
  background: var(--surface);
  border-bottom: 1px solid var(--hairline);
}

.site-head .wrap {
  display: flex;
  align-items: center;
  min-height: 64px;
}

/* The header: the mark, then the wordmark, 8px apart and centred on each
   other. The mark is decorative ([alt=""]) — the wordmark carries the name. */
.brand {
  display: inline-flex;
  align-items: center;
  gap: var(--s-2);
  text-decoration: none;
}

.brand-mark {
  display: block;
  flex: 0 0 auto;
  width: 32px;
  height: 32px;
}

.wordmark {
  font-family: var(--font-display);
  font-size: var(--fs-h3);
  font-weight: 600;
  letter-spacing: -0.02em;
  color: var(--brand);
  text-decoration: none;
}

.site-foot {
  margin-top: var(--s-7);
  padding: var(--s-5) 0 var(--s-7);
  border-top: 1px solid var(--hairline);
  color: var(--muted);
  font-size: var(--fs-small);
  line-height: var(--lh-small);
}

/* A full-bleed band already ends the page with its own padding. */
main:has(> .band-brand:last-child) + .site-foot {
  margin-top: 0;
}

.site-foot nav {
  display: flex;
  flex-wrap: wrap;
  gap: var(--s-2) var(--s-5);
  margin: 0 0 var(--s-3);
  max-width: none;
}

.site-foot a {
  color: var(--link);
}

/* The legal links are tap targets for thumbs: 44px tall, with the gap between
   them kept small because the padding is now inside each link. */
.site-foot nav a {
  display: inline-flex;
  align-items: center;
  min-height: 44px;
}

/* ------------------------------------------------------------------ prose */

.lead {
  font-size: var(--fs-lead);
  line-height: var(--lh-lead);
  color: var(--ink-2);
}

.helper,
.note,
.chart-caption {
  color: var(--muted);
  font-size: var(--fs-small);
  line-height: var(--lh-small);
}

.note {
  margin-top: var(--s-3);
}

.hero {
  padding: var(--s-6) 0 var(--s-4);
}

.hero h1 {
  max-width: 20ch;
}

/* --------------------------------------------------------------- controls */

/*
 * The primary button (DESIGN-SYSTEM.md section 9.1): a forest pill with a
 * "button-in-button" arrow, a 32px circle flush right inside the pill. Press
 * scales to .98, the arrow nudges 2px on hover. One per page.
 */
.btn,
.btn-secondary {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: var(--s-3);
  width: 100%;
  min-height: 56px;
  padding: var(--s-2) var(--s-2) var(--s-2) var(--s-5);
  border: 0;
  border-radius: var(--r-pill);
  background: var(--action);
  color: var(--action-ink);
  font-family: var(--font-body);
  font-size: 18px;
  font-weight: 600;
  line-height: 1.2;
  text-align: center;
  text-decoration: none;
  cursor: pointer;
  transition: transform var(--dur-2) var(--ease-out),
    background-color var(--dur-2) var(--ease-out);
}

.btn:hover {
  background: var(--action-hover);
}

.btn:active {
  transform: scale(0.98);
}

.btn:focus-visible {
  outline: 3px solid var(--ink);
  outline-offset: 3px;
  box-shadow: 0 0 0 7px var(--focus);
}

/* The trailing arrow: its own 32px circle, cream at 15% on the forest pill. */
.btn-arrow {
  display: grid;
  flex: 0 0 auto;
  place-items: center;
  width: var(--icon-circle);
  height: var(--icon-circle);
  border-radius: var(--r-pill);
  background: var(--action-ink-soft);
  transition: transform var(--dur-2) var(--ease-spring);
}

.btn-arrow .icon {
  width: 18px;
  height: 18px;
  color: var(--action-ink);
}

.btn:hover .btn-arrow {
  transform: translateX(2px);
}

/* A loading button keeps its label and swaps the arrow for a spinner. */
.btn[aria-busy="true"] {
  cursor: progress;
}

.btn[aria-busy="true"] .btn-arrow {
  animation: spin 900ms linear infinite;
}

@keyframes spin {
  to {
    transform: rotate(360deg);
  }
}

.btn-secondary {
  padding: var(--s-2) var(--s-5);
  border: 2px solid var(--input-border);
  background: var(--surface);
  color: var(--ink);
}

.btn-secondary:hover {
  background: var(--brand-tint);
  border-color: var(--brand);
}

.btn:disabled,
.btn-secondary:disabled {
  background: var(--disabled-bg);
  color: var(--disabled-ink);
  border-color: transparent;
  cursor: not-allowed;
  transform: none;
}

/* A secondary action is a text link with an arrow, never a second button. */
.text-link {
  color: var(--link);
  font-weight: 600;
  text-decoration: underline;
}

.text-link::after {
  content: " \2192";
}

.linkish {
  display: inline-flex;
  align-items: center;
  min-height: var(--tap);
  padding: 0 var(--s-1);
  border: 0;
  background: none;
  color: var(--link);
  font-family: var(--font-body);
  font-size: var(--fs-body);
  font-weight: 600;
  text-decoration: underline;
  cursor: pointer;
}

.back-link {
  justify-self: start;
  margin-bottom: var(--s-2);
}

.linkish:disabled {
  opacity: 0.5;
  cursor: default;
}

/* ------------------------------------------------------------------- card */

.card {
  background: var(--surface);
  border: 1px solid var(--hairline);
  border-radius: var(--radius-card);
  padding: var(--s-4);
}

/* One thing per page: the quiz, verify, results and confirmed screens read
   better as a single column than as a 1120px-wide card. */
.page-card {
  max-width: var(--reading);
  margin: var(--s-5) auto 0;
}

/* Headings break evenly: no lone word left on the last line. */
.page-card h1,
.page-card h2 {
  text-wrap: balance;
}

.notice,
.banner {
  padding: var(--s-3) var(--s-4);
  border: 1px solid var(--warn-bg);
  border-left: 4px solid var(--warn-ink);
  border-radius: var(--radius-input);
  background: var(--warn-bg);
  color: var(--warn-ink);
  font-size: var(--fs-small);
  line-height: var(--lh-small);
  max-width: var(--measure);
}

.banner {
  margin: 0 0 var(--s-5);
}

.steps {
  display: grid;
  gap: var(--s-5);
  margin: 0;
  padding: 0;
  list-style: none;
}

/* The 48px tint badge is what marks a step now, so the list needs no rule of
   its own: every step starts on the same edge as the heading above it. */
.steps strong {
  display: block;
  font-size: var(--fs-body);
}

.step-icon {
  display: block;
  width: 28px;
  height: 28px;
  margin-bottom: var(--s-2);
  fill: none;
  stroke: var(--brand);
  stroke-width: 1.7;
  stroke-linecap: round;
  stroke-linejoin: round;
}

/* ----------------------------------------------------------------- icons */

/*
 * One outline set, public/img/icons.svg (DESIGN-SYSTEM.md §8.2): 24px, 1.75px
 * stroke, round caps and joins, --brand. The sprite paints with currentColor,
 * so the colour lives here and nowhere else:
 *
 *   <svg class="icon" aria-hidden="true"><use href="/img/icons.svg#lock"/></svg>
 *
 * inline-block, not block: the same icon works in a badge, in a flex row and
 * inside a sentence.
 */
.icon {
  display: inline-block;
  flex: 0 0 auto;
  width: 24px;
  height: 24px;
  vertical-align: middle;
  color: var(--brand);
}

/* A 48px tint circle holding one 24px icon: the "How it works" steps now, the
   icon rows on the results and booking pages next. */
.icon-badge {
  display: grid;
  place-items: center;
  width: 48px;
  height: 48px;
  margin: 0 0 var(--s-3);
  border-radius: 50%;
  background: var(--brand-tint);
}

.grid-2 {
  display: grid;
  gap: var(--s-4);
}

/* Confirmed page: a real gutter between the two columns, and if one column is
   hidden the other takes the whole row. */
@media (min-width: 700px) {
  .grid-2.confirmed-cols {
    grid-template-columns: repeat(auto-fit, minmax(14rem, 1fr));
    column-gap: var(--s-7);
  }
}

details summary {
  display: flex;
  align-items: center;
  min-height: var(--tap);
  color: var(--link);
  font-weight: 600;
  cursor: pointer;
}

/* display: flex removes the native marker, so draw our own. */
details summary::after {
  content: "+";
  margin-left: var(--s-2);
  color: var(--link);
  font-weight: 700;
}

details[open] summary::after {
  content: "\2212";
}

/* "How we calculate" is a link that opens this disclosure, so it reads like
   one: an arrow in, an up arrow once it is open. */
.assumptions summary::after {
  content: " \2192";
}

.assumptions[open] summary::after {
  content: " \2191";
}

.assumptions ul {
  margin: 0 0 var(--s-3);
  padding-left: var(--s-5);
  color: var(--ink-2);
  font-size: var(--fs-small);
  line-height: var(--lh-small);
}

.assumptions li {
  margin-bottom: var(--s-2);
}

.assumptions a {
  overflow-wrap: anywhere;
}

/* --------------------------------------------------- FAQ and disclosure rows */

/* A row, not a bare line: a hairline under each one, a 56px tap height, and a
   drawn caret that turns when it opens. The caret is two strokes, so it needs
   no sprite symbol and no text glyph. The rules are more specific than the
   "+" and minus marks above, which they replace. */
.faq-row {
  border-bottom: 1px solid var(--hairline);
}

.faq-row > summary {
  min-height: 56px;
  padding: var(--s-4) 0;
  color: var(--ink);
  font-size: 18px;
  font-weight: 600;
  line-height: 1.4;
}

.faq-row > p {
  margin: 0 0 var(--s-5);
  padding-right: var(--s-6);
  color: var(--ink-2);
  font-size: var(--fs-small);
  line-height: var(--lh-body);
}

.faq-row > summary::after,
.more-assumptions > summary::after {
  content: "";
  flex: 0 0 auto;
  width: 9px;
  height: 9px;
  margin: 0 0 0 auto;
  border-right: 2px solid currentColor;
  border-bottom: 2px solid currentColor;
  color: var(--ink-2);
  transform: rotate(45deg);
  transition: transform var(--dur-2) var(--ease-out);
}

.faq-row[open] > summary::after,
.more-assumptions[open] > summary::after {
  content: "";
  transform: rotate(-135deg);
}

/* -------------------------------------------------------------- calculator */

.fields {
  display: grid;
  gap: var(--s-4);
  grid-template-columns: 1fr;
  margin: 0 0 var(--s-4);
}

.field {
  margin: 0 0 var(--s-3);
}

/*
 * Double-bezel card (DESIGN-SYSTEM.md section 9.1): the outer shell is
 * --surface-2 with a hairline and an --bezel of padding, and the inner core is
 * a --surface panel with concentric radii (--r-inner = --r-outer - --bezel). The
 * core is drawn by ::before, so no markup changes. The 1px top highlight sits on
 * the core, and the brass hairline on the shell marks the result as the fee view.
 */
.bezel {
  position: relative;
  isolation: isolate;
  padding: calc(var(--bezel) + var(--s-4));
  border: 1px solid var(--hairline);
  border-radius: var(--r-outer);
  background: var(--surface-2);
  box-shadow: var(--elev-2);
}

.bezel::before {
  content: "";
  position: absolute;
  inset: var(--bezel);
  z-index: -1;
  border-radius: var(--r-inner);
  background: var(--surface);
  box-shadow: inset 0 1px 0 var(--inner-highlight);
}


.tabs {
  display: flex;
  gap: var(--s-1);
  padding: var(--s-1);
  margin-bottom: var(--s-4);
  border-radius: var(--r-pill);
  background: var(--brand-tint);
}

.tabs button {
  flex: 1;
  min-height: var(--tap);
  border: 0;
  border-radius: var(--r-pill);
  background: transparent;
  color: var(--brand);
  font-family: var(--font-body);
  font-size: var(--fs-small);
  font-weight: 600;
  cursor: pointer;
  transition: background-color var(--dur-1) var(--ease-out);
}

.tabs button[aria-selected="true"] {
  background: var(--surface);
  color: var(--ink);
}

.step {
  display: none;
}

.step[data-active="true"] {
  display: block;
}

.result-sentence {
  margin: 0 0 var(--s-2);
  color: var(--ink-2);
  font-size: var(--fs-small);
  line-height: var(--lh-small);
}

/* The figure is sized to its card, not the page. "$9,999,999" is about 4.8em
   wide, so at 17cqi it takes about 82% of the card's width and stays on one
   line at every card width. The display token caps it on wide layouts. */
.result-card {
  container-type: inline-size;
}

.result-figure {
  margin: 0 0 var(--s-2);
  color: var(--brand);
  font-family: var(--font-display);
  font-size: var(--fs-display);
  font-size: min(var(--fs-display), 17cqi);
  font-weight: 600;
  line-height: var(--lh-display);
  letter-spacing: var(--tracking-display);
  font-variant-numeric: tabular-nums;
  white-space: nowrap;
}

.result-support {
  margin: 0 0 var(--s-3);
  color: var(--muted);
  font-size: var(--fs-small);
  line-height: var(--lh-small);
}

.chart-verdict {
  margin: 0 0 var(--s-2);
  color: var(--ink);
  font-size: var(--fs-body);
  font-weight: 600;
  font-variant-numeric: tabular-nums;
}

.band {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: var(--s-2);
  margin: var(--s-3) 0;
}

/* A column, so the label sits at the top and the number at the bottom: the
   three figures line up even when one label wraps ("Worst case"). */
.band div {
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  gap: var(--s-1);
  padding: var(--s-3);
  border-radius: var(--radius-input);
  background: var(--brand-tint);
  text-align: center;
}

.band-label {
  display: block;
  color: var(--ink-2);
  font-size: var(--fs-small);
  font-weight: 600;
}

.band strong {
  display: block;
  overflow-wrap: anywhere;
  color: var(--brand);
  font-size: var(--fs-small);
  font-variant-numeric: tabular-nums;
}

.chart-wrap {
  margin: var(--s-3) 0;
}

.chart-wrap svg {
  display: block;
  width: 100%;
  height: auto;
}

table {
  border-collapse: collapse;
  font-size: var(--fs-small);
  font-variant-numeric: tabular-nums;
}

caption {
  text-align: left;
}

th,
td {
  padding: var(--s-2);
  border-bottom: 1px solid var(--hairline);
  text-align: left;
}

/* -------------------------------------------------------------------- quiz */

.quiz-head {
  display: grid;
  gap: var(--s-2);
  margin-bottom: var(--s-3);
}

.progress-text {
  margin: 0;
  color: var(--ink-2);
  font-size: var(--fs-small);
  font-weight: 600;
  font-variant-numeric: tabular-nums;
}

.progress {
  height: 4px;
  margin: 0 0 var(--s-5);
  overflow: hidden;
  border-radius: 2px;
  background: var(--brand-tint);
}

.progress span {
  display: block;
  width: 0;
  height: 100%;
  background: var(--brand);
  transition: width var(--dur-2) var(--ease-out);
}

.choices {
  display: grid;
  gap: var(--s-3);
  grid-template-columns: 1fr;
  margin: var(--s-4) 0;
  max-width: var(--reading);
}

.choice {
  position: relative;
  display: flex;
  align-items: center;
  min-height: 56px;
  padding: var(--s-3) var(--s-5) var(--s-3) var(--s-4);
  border: 2px solid var(--ink-2);
  border-radius: var(--radius-card);
  background: var(--surface);
  color: var(--ink);
  font-size: var(--fs-body);
  cursor: pointer;
  transition: background-color var(--dur-1) var(--ease-out),
    border-color var(--dur-1) var(--ease-out);
}

/* The radio fills the card: the whole card is the tap target and the control,
   and the radio itself is never smaller than a tap target. */
.choice input {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  margin: 0;
  opacity: 0;
  cursor: pointer;
}

.choice:hover {
  border-color: var(--brand);
}

.choice:has(input:checked) {
  background: var(--brand-tint);
  border-color: var(--brand);
}

/* The selected check, drawn from currentColor so no colour is hardcoded. */
.choice:has(input:checked)::after {
  content: "";
  width: 14px;
  height: 8px;
  margin-left: auto;
  border-bottom: 3px solid var(--brand);
  border-left: 3px solid var(--brand);
  transform: rotate(-45deg) translateY(-2px);
}

.step-actions {
  display: grid;
  gap: var(--s-3);
  margin-top: var(--s-5);
  max-width: var(--reading);
}

.lock-line {
  margin: 0;
  color: var(--ink-2);
  font-size: var(--fs-small);
  line-height: var(--lh-small);
  text-align: center;
}

.consent {
  display: flex;
  gap: var(--s-3);
  align-items: flex-start;
  margin: var(--s-3) 0;
  max-width: var(--reading);
  color: var(--ink);
  font-size: var(--fs-small);
  line-height: var(--lh-small);
}

.consent input {
  flex: 0 0 auto;
  width: var(--tap);
  height: var(--tap);
  margin: 0;
  accent-color: var(--brand);
}

.error {
  margin: var(--s-2) 0 var(--s-3);
  padding: var(--s-2) var(--s-3);
  border-left: 4px solid var(--error);
  background: var(--surface);
  color: var(--error);
  font-size: var(--fs-small);
  font-weight: 600;
  line-height: var(--lh-small);
  max-width: var(--measure);
}

.error:empty {
  display: none;
}

.honeypot {
  position: absolute;
  left: -9999px;
  width: 1px;
  height: 1px;
  overflow: hidden;
}

/* "We texted (415) •••-1234. Wrong number?": the link is a 44px tap target. */
.verify-sent[hidden] {
  display: none;
}

.verify-sent a {
  display: inline-flex;
  align-items: center;
  min-height: 44px;
  color: var(--link);
  font-weight: 600;
}

/* The six-digit code gets a narrow field, so it reads as one code. */
.field-code {
  max-width: 16rem;
}

.code-input {
  width: 100%;
  min-height: 64px;
  padding: var(--s-2);
  border: 2px solid var(--ink-2);
  border-radius: var(--radius-input);
  background: var(--surface);
  color: var(--ink);
  font-size: var(--fs-h2);
  letter-spacing: 0.4rem;
  text-align: center;
  font-variant-numeric: tabular-nums;
}

/* -------------------------------------------------------------- book page */

.book {
  display: grid;
  gap: var(--s-5);
  align-items: start;
}

/* The advisor card is a .bezel (double-bezel) card: its shell and core come
   from the shared rule above, so this rule only sets its inner spacing. */
.advisor-card {
  margin: 0;
}

.advisor-head {
  display: flex;
  gap: var(--s-4);
  align-items: center;
  margin-bottom: var(--s-3);
}

.advisor-photo,
.advisor-initials {
  flex: 0 0 auto;
  width: 72px;
  height: 72px;
  border-radius: 50%;
  background: var(--brand-tint);
}

.advisor-photo {
  object-fit: cover;
}

.advisor-initials {
  display: grid;
  place-items: center;
  color: var(--brand);
  font-family: var(--font-display);
  font-size: var(--fs-h3);
  font-weight: 600;
}

.advisor-name {
  margin: 0;
  font-family: var(--font-display);
  font-size: var(--fs-h3);
  font-weight: 600;
  color: var(--brand);
}

.advisor-line {
  margin: 0;
  color: var(--ink-2);
  font-size: var(--fs-small);
  line-height: var(--lh-small);
}

/* The SEC proof under the firm: shown only when the advisor has a CRD. */
.advisor-sec {
  color: var(--ink);
  font-weight: 600;
}

.advisor-sec-link {
  display: inline-flex;
  align-items: center;
  min-height: 44px;
  color: var(--link);
  font-size: var(--fs-small);
  font-weight: 600;
  line-height: var(--lh-small);
  text-decoration: underline;
}

.advisor-disclosure {
  margin: var(--s-3) 0 0;
  padding-top: var(--s-3);
  border-top: 1px solid var(--hairline);
  color: var(--muted);
  font-size: var(--fs-small);
  line-height: var(--lh-small);
}

#cal-embed {
  min-height: 320px;
  padding: var(--s-3);
  border: 1px solid var(--hairline);
  border-radius: var(--radius-card);
  background: var(--surface);
}

.ready-list {
  padding-left: var(--s-5);
  color: var(--ink-2);
}

.slot-day {
  margin: var(--s-4) 0 var(--s-2);
  color: var(--ink-2);
  font-size: var(--fs-small);
}

.slot-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: var(--s-2);
  min-height: var(--s-5);
}

.status-dot {
  display: inline-block;
  width: 10px;
  height: 10px;
  margin-right: var(--s-2);
  border-radius: 50%;
  background: var(--success);
}

/* --------------------------------------------------------------- brand band */

/*
 * The one brand moment per page (DESIGN-SYSTEM.md §8.2): a full-bleed --brand
 * band with white text and generous air above and below. Nothing uses it yet;
 * the closing CTA on home and the results header are the first consumers.
 *
 * Put it straight in <main>, never inside a .wrap — that is what makes it
 * full-bleed. The content it holds goes in a .wrap, which is what lines the
 * band's edges up with the 1120px container the rest of the page uses.
 */
.band-brand {
  padding: var(--s-7) 0;
  background: var(--brand);
  color: var(--action-ink);
}

.band-brand h1,
.band-brand h2,
.band-brand h3 {
  color: var(--action-ink);
}

.band-brand .note,
.band-brand .helper,
.band-brand .chart-caption {
  color: var(--action-ink);
}

.band-brand a:not(.btn) {
  color: var(--action-ink);
  text-decoration: underline;
}

/*
 * On a forest band the primary button cannot be forest too, so it inverts:
 * a cream pill with forest text. Still the one primary on the band.
 */
.band-brand .btn,
.band-brand .btn:hover {
  background: var(--action-ink);
  border-color: var(--action-ink);
  color: var(--brand);
}

/* Icons on a band are white too, except inside an .icon-badge, where the tint
   fill keeps the --brand icon readable. */
.band-brand .icon {
  color: var(--action-ink);
}

.band-brand .icon-badge .icon {
  color: var(--brand);
}

/* ----------------------------------------------------------------- photos */

/*
 * A warm scene from /img/photos/, set below the fold and lazy-loaded. The frame
 * is a rounded card: --r-outer corners, a hairline and --elev-2, the same shape
 * the .bezel cards use. The hairline is a 1px shadow ring, not a border, so it
 * adds nothing to the layout height. The <img> carries width and height, so its box is
 * reserved before it loads. On a phone the whole 3:2 picture shows; from 700px
 * up .photo-band crops it to a wide strip, and .photo-y-* picks which part of
 * the picture stays in view.
 */
.photo {
  margin: var(--s-6) 0;
  overflow: hidden;
  border-radius: var(--r-outer);
  background: var(--surface-2);
  box-shadow: 0 0 0 1px var(--hairline), var(--elev-2);
}

.photo img {
  display: block;
  width: 100%;
  height: auto;
}

.photo-y-15 {
  --photo-y: 15%;
}

.photo-y-30 {
  --photo-y: 30%;
}

.photo-y-50 {
  --photo-y: 50%;
}

@media (min-width: 700px) {
  .photo-band img {
    aspect-ratio: 12 / 5;
    object-fit: cover;
    object-position: 50% var(--photo-y, 30%);
  }
}

/* ------------------------------------------------------------ breakpoints */

@media (min-width: 700px) {
  .btn,
  .btn-secondary {
    width: auto;
  }

  .fields {
    grid-template-columns: repeat(2, 1fr);
  }

  .grid-2,
  .choices {
    grid-template-columns: repeat(2, 1fr);
  }

  .steps {
    grid-template-columns: repeat(3, 1fr);
  }

  .band strong {
    font-size: var(--fs-body);
  }

  .card,
  .result-card {
    padding: var(--s-5);
  }
}

@media (min-width: 960px) {
  /* The band gets the desktop's generous vertical air. */
  .band-brand {
    padding: var(--s-8) 0;
  }

  .book {
    grid-template-columns: 21rem minmax(0, 1fr);
    gap: var(--s-6);
  }

  .slot-grid {
    grid-template-columns: repeat(3, 1fr);
  }

  .book-intro {
    max-width: var(--reading);
  }
}

@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }

  *,
  *::before,
  *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }
}

@media print {
  body::after {
    display: none;
  }

  .site-head,
  .site-foot,
  .tabs,
  .photo {
    display: none;
  }

  /* The mark is 32px next to the header wordmark on screen. In print it matches
     the small wordmark it stands beside, so the advisor one-pager's header
     keeps the height it had and the sheet stays one page. */
  .brand-mark {
    width: 20px;
    height: 20px;
  }
}
