@font-face {
  font-family: "Hanken Grotesk";
  src: url("assets/fonts/HankenGrotesk-VariableFont_wght.ttf") format("truetype");
  font-weight: 100 900;
  font-display: swap;
}
@font-face {
  font-family: "IBM Plex Mono";
  src: url("assets/fonts/IBMPlexMono-Regular.ttf") format("truetype");
  font-weight: 400;
  font-display: swap;
}
@font-face {
  font-family: "IBM Plex Mono";
  src: url("assets/fonts/IBMPlexMono-Medium.ttf") format("truetype");
  font-weight: 500;
  font-display: swap;
}

:root {
  --ink: #172620;
  --ink-soft: #3d4a44;
  --paper: #f9f7f4;
  --paper-deep: #f1ede6;
  --gold: #8a671c;
  --gold-on-ink: #c4a25a;
  --line: rgba(23, 38, 32, 0.14);
  --line-gold: rgba(138, 103, 28, 0.45);
  --sans: "Hanken Grotesk", system-ui, -apple-system, "Segoe UI", sans-serif;
  --mono: "IBM Plex Mono", ui-monospace, "SFMono-Regular", Menlo, monospace;
  --radius: 16px;
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font-family: var(--sans);
  font-size: 16px;
  line-height: 1.55;
  font-weight: 400;
}
img { max-width: 100%; display: block; }
[hidden] { display: none !important; }

.wrap { width: 100%; max-width: 1160px; margin: 0 auto; padding: 0 20px; position: relative; }

h1, h2, h3 { font-weight: 300; letter-spacing: -0.01em; line-height: 1.1; margin: 0; }
h1 { font-size: clamp(40px, 9vw, 72px); }
h2 { font-size: clamp(30px, 6vw, 44px); }
h3 { font-size: 21px; font-weight: 400; line-height: 1.25; }

.eyebrow, .mono-label {
  font-family: var(--mono);
  font-size: 12px;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--gold);
  margin: 0 0 12px;
  font-weight: 500;
}
.mono-label { letter-spacing: 0.1em; }
.small { font-size: 14px; color: var(--ink-soft); margin: 0; }
.lede { font-size: 19px; max-width: 34ch; color: var(--ink-soft); margin: 18px 0 0; }

/* Masthead */
.masthead { border-bottom: 1px solid var(--line-gold); }
.masthead__row { display: flex; align-items: center; justify-content: space-between; gap: 12px; min-height: 80px; padding: 12px 0; }
.masthead__brand { display: flex; flex-direction: column; align-items: flex-start; gap: 2px; min-width: 0; }
.masthead__home {
  appearance: none; background: none; border: 0; padding: 4px 0; cursor: pointer;
  font-family: var(--mono); font-size: 12px; letter-spacing: 0.12em; text-transform: uppercase;
  color: var(--gold); border-bottom: 1px solid var(--line-gold);
}
.masthead__home:focus-visible { outline: 2px solid var(--gold); outline-offset: 2px; }
.brand { text-decoration: none; min-width: 0; }
/* PLSM Club wordmark: larger than the site-wide 12px eyebrow, but still balanced with the SABAS logo. */
.brand .eyebrow {
  margin: 0; color: var(--ink); font-size: 18px; font-weight: 500; letter-spacing: 0.16em; line-height: 1.1;
  white-space: nowrap;
}
.logo { width: 120px; height: auto; aspect-ratio: 600 / 223; flex: none; }

/* Views */
.view { padding: 48px 0 72px; }
.landing { position: relative; overflow: hidden; min-height: 70vh; padding-top: 56px; }
.welcome { position: relative; overflow: hidden; min-height: 100dvh; padding: 56px 0 72px; display: flex; }
.welcome__cover {
  display: grid; align-content: center; justify-items: start;
  min-height: calc(100dvh - 128px); max-width: 760px;
}
.welcome__mark {
  font-family: var(--mono); font-size: 18px; font-weight: 500;
  letter-spacing: 0.16em; text-transform: uppercase; color: var(--ink);
  margin: 0 0 18px; line-height: 1.1;
}
.welcome h1 {
  font-size: clamp(32px, 7.2vw, 68px); font-weight: 300; letter-spacing: -0.02em;
  line-height: 1.05; margin: 0;
}
.welcome__title-rest { display: block; }
.welcome__logo {
  width: 132px; height: auto; aspect-ratio: 600 / 223;
  margin: 28px 0 44px;
}
.welcome__form { margin: 0; max-width: 28rem; width: 100%; display: grid; gap: 24px; }
.welcome__form .field > span { font-size: 16px; color: var(--ink); }
.welcome__actions { display: flex; align-items: center; gap: 22px; flex-wrap: wrap; }
.welcome__skip { margin: 0; }
.welcome__privacy { margin: 0; }
.hello {
  font-size: clamp(32px, 7vw, 56px); font-weight: 300; letter-spacing: -0.01em;
  line-height: 1.1; margin: 0 0 14px;
}
.hello--team { font-size: clamp(22px, 4vw, 32px); margin: 0 0 8px; }

.botanical { position: absolute; pointer-events: none; mix-blend-mode: multiply; opacity: 0.16; }
/* Kept inside its section (no negative offset), so it can never push the page wider than the window. */
.botanical--lily { right: 0; top: 10px; width: 220px; }
.botanical--grass { left: 0; right: 0; bottom: 0; width: 100%; height: 70px; object-fit: cover; object-position: bottom; opacity: 0.09; }

.choices { display: grid; gap: 16px; margin-top: 40px; position: relative; }
.choice {
  appearance: none; border: 1px solid var(--line-gold); border-radius: 20px;
  background: var(--paper); color: var(--ink); text-align: left; cursor: pointer;
  padding: 28px 24px 30px; display: grid; gap: 8px; font: inherit;
  transition: transform .18s ease, border-color .18s ease, background .18s ease;
}
.choice:hover, .choice:focus-visible { border-color: var(--gold); outline: none; }
.choice:focus-visible { box-shadow: 0 0 0 3px rgba(138,103,28,.25); }
.choice__num { font-family: var(--mono); font-size: 12px; letter-spacing: .14em; color: var(--gold); }
.choice__title { font-size: 34px; font-weight: 300; line-height: 1.1; }
.choice__sub { font-size: 15px; color: var(--ink-soft); }
.choice--ink { background: var(--ink); color: var(--paper); border-color: var(--ink); }
.choice--ink .choice__num { color: var(--gold-on-ink); }
.choice--ink .choice__sub { color: rgba(249,247,244,.78); }
.choice--ink:hover, .choice--ink:focus-visible { background: #1e3029; border-color: var(--gold-on-ink); }

/* Team head */
.team-head { display: flex; justify-content: space-between; align-items: flex-end; gap: 16px; flex-wrap: wrap; }
.link-btn {
  appearance: none; background: none; border: 0; padding: 6px 0; cursor: pointer;
  font-family: var(--mono); font-size: 12px; letter-spacing: .12em; text-transform: uppercase;
  color: var(--gold); border-bottom: 1px solid var(--line-gold);
}

/* Tier control */
.tier-bar { margin: 32px 0 8px; padding: 20px 0; border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); }
/* Three income ranges: equal columns at every width. On phones the labels use the sans face so "$500k and above" fits one line. */
.segmented { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); border: 1px solid var(--ink); border-radius: 999px; padding: 3px; max-width: 480px; gap: 0; }
.segmented button {
  appearance: none; border: 0; background: transparent; color: var(--ink); cursor: pointer; min-width: 0;
  font-family: var(--sans); font-size: 13px; font-weight: 500; letter-spacing: -0.01em; padding: 11px 2px; border-radius: 999px; white-space: nowrap;
}
@media (max-width: 374px) { .segmented button { font-size: 12px; letter-spacing: 0; } }
.segmented button[aria-checked="true"] { background: var(--ink); color: var(--paper); }
.segmented button:focus-visible { outline: 2px solid var(--gold); outline-offset: 2px; }
.tier-rule { font-size: 14px; color: var(--ink-soft); margin: 12px 0 0; }
.note { font-size: 14px; border-left: 2px solid var(--gold); padding: 6px 0 6px 14px; margin: 16px 0 0; color: var(--ink-soft); }

/* Search and bank chips: under the income selector, on both teams. */
.visually-hidden {
  position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px;
  overflow: hidden; clip: rect(0, 0, 0, 0); white-space: nowrap; border: 0;
}
.card-filter { margin: 18px 0 8px; min-width: 0; max-width: 100%; }
.card-filter__row { display: flex; align-items: flex-end; gap: 12px; min-width: 0; }
.card-filter__search { flex: 1 1 auto; min-width: 0; display: grid; }
.card-filter__search input {
  font: inherit; font-size: 16px; color: var(--ink); background: transparent;
  border: 0; border-bottom: 1px solid var(--ink); border-radius: 0; padding: 8px 2px; width: 100%;
}
.card-filter__search input:focus { outline: none; border-bottom-color: var(--gold); box-shadow: 0 1px 0 var(--gold); }
.card-filter__search input::placeholder { color: var(--ink-soft); opacity: 1; }
.card-filter__clear {
  appearance: none; flex: none; background: transparent; color: var(--ink);
  border: 1px solid var(--line-gold); border-radius: 999px; cursor: pointer;
  font-family: var(--mono); font-size: 12px; font-weight: 500; letter-spacing: 0.06em;
  text-transform: uppercase; padding: 8px 14px;
}
.card-filter__clear:focus-visible { outline: 2px solid var(--gold); outline-offset: 2px; }
/* Chips scroll inside this row only, so a long bank list cannot widen the page at 390. */
.card-filter__banks {
  display: flex; flex-wrap: nowrap; gap: 8px; align-items: center;
  margin: 14px 0 0; padding: 2px 0 8px; min-width: 0; max-width: 100%;
  overflow-x: auto; overflow-y: hidden;
  -webkit-overflow-scrolling: touch; overscroll-behavior-x: contain;
  scrollbar-width: thin;
}
.card-filter__chip {
  appearance: none; flex: none; background: transparent; color: var(--ink);
  border: 1px solid var(--line-gold); border-radius: 999px; cursor: pointer; white-space: nowrap;
  font-family: var(--mono); font-size: 12px; font-weight: 500; letter-spacing: 0.04em;
  text-transform: uppercase; padding: 8px 14px;
}
.card-filter__chip[aria-checked="true"] { background: var(--ink); color: var(--paper); border-color: var(--ink); }
.card-filter__chip:focus-visible { outline: 2px solid var(--gold); outline-offset: 2px; }
.card-filter__empty { margin: 24px 0 8px; }
html.js-motion .card-filter__chip,
html.js-motion .card-filter__clear {
  transition: background-color var(--dur-hover) var(--ease-enter), color var(--dur-hover) var(--ease-enter), border-color var(--dur-hover) var(--ease-enter);
}

/* Card groups */
.group { margin-top: 44px; }
.group__head { display: flex; flex-wrap: wrap; align-items: baseline; gap: 4px 14px; margin-bottom: 18px; }
.group__head h2 { font-size: 26px; font-weight: 300; }
.group__head .mono-label { margin: 0; }
.group__note { font-size: 14px; color: var(--ink-soft); margin: -8px 0 18px; }
.grid { display: grid; gap: 18px; grid-template-columns: minmax(0, 1fr); }

/* Never upscale: images show at native size at most, so small card faces stay sharp. Every face is a landscape card in the same media slot. */
/* Card tiles: every tile has the same fixed width and height. Long content lives in the in-tile details layer.
   Phone: compact horizontal head (small image left, name right), then rates, facts, best for and actions. */
.card {
  --tile-h: 560px;
  position: relative; overflow: hidden; height: var(--tile-h); min-width: 0;
  border: 1px solid var(--line); border-radius: var(--radius); background: #fbfaf7; padding: 16px;
  display: grid; grid-template-columns: 120px minmax(0, 1fr); grid-template-rows: auto minmax(0, 1fr) auto auto;
  column-gap: 14px; row-gap: 12px;
}
.card__body { display: contents; }
.card__media {
  grid-column: 1; grid-row: 1; align-self: start;
  width: 120px; height: 80px; overflow: hidden; display: grid; grid-template: minmax(0, 100%) / minmax(0, 100%); place-items: center;
  background: var(--paper-deep); border-radius: 10px; padding: 6px;
}
.card__media img { width: auto; height: auto; max-width: 100%; max-height: 100%; min-width: 0; min-height: 0; object-fit: contain; mix-blend-mode: multiply; }
/* Kept for a future portrait asset; no current face uses this class. Landscape faces share the slot below. */
.card__media--portrait { place-items: center; }
.card__media--portrait img { width: auto; height: auto; max-width: 100%; max-height: 100%; object-fit: contain; transform: none; }
.variants { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 8px; }
.variants li { display: grid; gap: 4px; justify-items: center; text-align: center; font-family: var(--mono); font-size: 12px; color: var(--ink-soft); line-height: 1.3; }
.variants img { width: auto; height: auto; max-width: 100%; max-height: 64px; object-fit: contain; mix-blend-mode: multiply; }
.status { margin: 0; font-family: var(--mono); font-size: 12px; letter-spacing: .08em; text-transform: uppercase; padding: 4px 10px; border-radius: 6px; }
.status--invite_only { background: var(--ink); color: var(--paper); }
.status--paused { background: #f3e3bd; color: var(--ink); border: 1px solid var(--gold); }
.rate--text { font-size: 14px; white-space: normal; }
.offer, .pairing { border: 1px solid var(--line-gold); border-radius: 10px; padding: 10px 12px; font-size: 14px; color: var(--ink-soft); display: grid; gap: 4px; }
.offer p, .pairing p { margin: 0; line-height: 1.4; }
.offer__label, .pairing__label { font-family: var(--mono); font-size: 12px; letter-spacing: .08em; text-transform: uppercase; color: var(--gold); }
.pairing { background: var(--paper); }
.pairing__caveat { font-size: 13px; }
.more { font-size: 13px; color: var(--ink-soft); }
.more summary { cursor: pointer; font-family: var(--mono); font-size: 12px; letter-spacing: .06em; text-transform: uppercase; color: var(--ink-soft); list-style: none; }
.more summary::-webkit-details-marker { display: none; }
.more summary::after { content: " +"; color: var(--gold); }
.more[open] summary::after { content: " \2212"; }
.more ul { margin: 6px 0 0; padding-left: 16px; display: grid; gap: 4px; }
.more p { margin: 6px 0 0; }
.placeholder {
  width: 86%; aspect-ratio: 1.586; max-height: 100%; border: 1px solid var(--gold); border-radius: 12px;
  background: var(--paper); display: flex; flex-direction: column; justify-content: space-between; padding: 14px 16px;
}
.placeholder__bank { font-family: var(--mono); font-size: 12px; letter-spacing: .14em; text-transform: uppercase; color: var(--gold); }
.placeholder__name { font-size: 16px; font-weight: 400; line-height: 1.25; }
.placeholder__tag { font-family: var(--mono); font-size: 12px; color: var(--ink-soft); }

.card__top { grid-column: 2; grid-row: 1; display: grid; gap: 6px; align-content: start; min-width: 0; }
.card__mid { grid-column: 1 / -1; grid-row: 2; min-height: 0; overflow: hidden; display: grid; gap: 12px; align-content: start; }
.card__mid .rates, .card__mid .facts { align-content: start; }
.card .best { grid-column: 1 / -1; grid-row: 3; }
.card__actions { grid-column: 1 / -1; grid-row: 4; }
.card__title { min-width: 0; }
.card__title h3 { font-size: 18px; display: -webkit-box; -webkit-box-orient: vertical; -webkit-line-clamp: 2; overflow: hidden; }
.card__bank { font-family: var(--mono); font-size: 12px; letter-spacing: .12em; text-transform: uppercase; color: var(--gold); margin: 0 0 2px; }
.card__tags { display: flex; flex-wrap: wrap; gap: 6px; align-items: center; }
.tag { font-family: var(--mono); font-size: 12px; border: 1px solid var(--line-gold); border-radius: 999px; padding: 2px 10px; white-space: nowrap; color: var(--gold); }

.rates { list-style: none; margin: 0; padding: 0; display: grid; gap: 8px; }
.rates li { display: grid; grid-template-columns: auto minmax(0, 1fr); gap: 12px; align-items: baseline; }
.rate-text { min-width: 0; }
.rate { font-family: var(--mono); font-size: 15px; font-weight: 500; white-space: nowrap; }
.rate small { font-size: 12px; font-weight: 400; }
.rate--null { font-size: 12px; color: var(--gold); white-space: normal; }
.rate-sub { display: block; font-size: 12px; font-weight: 400; color: var(--ink-soft); white-space: nowrap; }
.conv__caveat { margin: 0; font-family: var(--mono); font-size: 12px; color: var(--gold); }
.conv__rate, .conv__note { margin: 0; font-size: 14px; color: var(--ink-soft); line-height: 1.4; }
.conv__rate { color: var(--ink); }
.conv__note { font-size: 13px; }
.rate-desc { font-size: 14px; color: var(--ink-soft); line-height: 1.4; min-width: 0; }
.card__mid .rate-desc { display: -webkit-box; -webkit-box-orient: vertical; -webkit-line-clamp: 2; overflow: hidden; }
.promo { font-family: var(--mono); font-size: 12px; color: var(--gold); display: block; }

.facts { margin: 0; display: grid; grid-template-columns: 1fr 1fr; gap: 8px 14px; padding: 10px 0; border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); }
.facts div { min-width: 0; }
.facts dt { font-family: var(--mono); font-size: 12px; letter-spacing: .06em; color: var(--ink-soft); text-transform: uppercase; }
.facts dd { margin: 2px 0 0; font-size: 14px; line-height: 1.35; overflow-wrap: anywhere; display: -webkit-box; -webkit-box-orient: vertical; -webkit-line-clamp: 2; overflow: hidden; }

.dd-note { display: block; font-size: 13px; color: var(--ink-soft); margin-top: 2px; }
.conds { margin: 0; padding: 0; list-style: none; display: grid; gap: 6px; }
.conds li { font-size: 14px; color: var(--ink-soft); padding-left: 16px; position: relative; line-height: 1.4; }
.conds li::before { content: ""; position: absolute; left: 0; top: .6em; width: 7px; height: 1px; background: var(--gold); }
.best { font-size: 14px; margin: 0; line-height: 1.4; display: -webkit-box; -webkit-box-orient: vertical; -webkit-line-clamp: 2; overflow: hidden; }
.best b { font-family: var(--mono); font-size: 12px; letter-spacing: .1em; text-transform: uppercase; color: var(--gold); font-weight: 500; }
.card__actions { display: flex; flex-wrap: wrap; gap: 8px 10px; align-items: center; }
.card__open, .card__close {
  appearance: none; background: none; cursor: pointer; font-family: var(--mono); font-size: 12px; letter-spacing: .06em; text-transform: uppercase;
  color: var(--ink); border: 1px solid var(--line-gold); border-radius: 999px; padding: 9px 14px; line-height: 1.2;
}
.card__open::after { content: " +"; color: var(--gold); }
.card__open:hover, .card__close:hover, .card__open:focus-visible, .card__close:focus-visible { border-color: var(--gold); outline: none; box-shadow: 0 0 0 3px rgba(138,103,28,.22); }
/* Details layer: opens over the tile, scrolls inside it, never changes the tile's outer size. */
.card__more {
  position: absolute; inset: 0; z-index: 2; overflow-y: auto; overscroll-behavior: contain;
  background: #fbfaf7; padding: 16px 18px 20px; display: grid; gap: 14px; align-content: start;
}
.card__more-head { position: sticky; top: -16px; margin: -16px -18px 0; padding: 14px 18px 10px; background: #fbfaf7; border-bottom: 1px solid var(--line); display: flex; justify-content: space-between; align-items: flex-start; gap: 12px; z-index: 1; }
.card__more-title { margin: 0; font-size: 18px; line-height: 1.25; }
.card__sec { display: grid; gap: 6px; }
.card__sec-label { margin: 0; font-family: var(--mono); font-size: 12px; letter-spacing: .08em; text-transform: uppercase; color: var(--gold); }
.card__sec .conds li b { font-weight: 500; color: var(--ink); }
.lounge__src { margin: 0; font-size: 12px; }
.lounge__src a { color: var(--ink-soft); }
.card__full-best { margin: 0; font-size: 14px; }
.card__more .variants img { max-height: 72px; }
.other-income { font-size: 13px; color: var(--ink-soft); }
.other-income summary { cursor: pointer; font-family: var(--mono); font-size: 12px; letter-spacing: .06em; text-transform: uppercase; color: var(--ink-soft); list-style: none; }
.other-income summary::-webkit-details-marker { display: none; }
.other-income summary::after { content: " +"; color: var(--gold); }
.other-income[open] summary::after { content: " \2212"; }
.other-income p { margin: 6px 0 0; }
.apply {
  text-decoration: none; color: var(--ink); white-space: nowrap;
  font-size: 15px; border: 1px solid var(--ink); border-radius: 999px; padding: 8px 18px;
}
.apply:hover, .apply:focus-visible { background: var(--ink); color: var(--paper); }

/* Side tabs (Your card strategy + CardUp): a fixed column on the right, no transformed ancestor, so they stay
   on the viewport. Stacked with a short gap so they never overlap. Never wider than 44px, so they cannot widen
   the page; max-height keeps the stack inside short (zoomed) windows. */
.side-tabs {
  position: fixed; right: max(4px, env(safe-area-inset-right)); top: 0; bottom: 0; z-index: 30;
  width: 26px; max-height: 100vh; display: flex; flex-direction: column; justify-content: flex-end; gap: 8px;
  pointer-events: none; padding: 8px 0 max(24px, env(safe-area-inset-bottom));
}
.side-tab, .cu-tab {
  pointer-events: auto; appearance: none; cursor: pointer; flex: 0 1 auto; min-height: 0;
  width: 26px; max-height: calc((100vh - 24px) / 2); overflow: hidden; padding: 14px 0;
  border: 1px solid var(--gold-on-ink); border-radius: 10px;
  background: var(--ink); color: var(--paper); box-shadow: -2px 2px 10px rgba(23,38,32,.22);
}
.side-tab__text, .cu-tab__text {
  display: block; writing-mode: vertical-rl; transform: rotate(180deg);
  font-family: var(--mono); font-size: 12px; letter-spacing: .08em; text-transform: uppercase;
  white-space: nowrap; margin: 0 auto;
}
.side-tab:hover, .side-tab:focus-visible, .cu-tab:hover, .cu-tab:focus-visible {
  background: #24372f; outline: 2px solid var(--gold); outline-offset: 2px;
}
.cu-locked, .cu-locked body { overflow: hidden; }
.cu-backdrop { position: fixed; inset: 0; z-index: 40; background: rgba(23,38,32,.42); }
.cu-panel {
  position: fixed; top: 0; right: 0; bottom: 0; z-index: 50; width: calc(100% - 12px); max-width: 640px;
  background: var(--paper); border-left: 1px solid var(--line-gold); box-shadow: -8px 0 30px rgba(23,38,32,.2);
  display: flex; flex-direction: column;
}
.cu-panel__head { flex: none; display: flex; justify-content: space-between; align-items: flex-start; gap: 12px; padding: 16px 16px 12px 18px; border-bottom: 1px solid var(--line-gold); }
.cu-panel__head .eyebrow { margin-bottom: 6px; }
.cu-panel__head > div { min-width: 0; }
.cu-panel__head h2 { font-size: 26px; overflow-wrap: break-word; }
.cu-panel__head h2:focus { outline: none; }
.cu-panel__close {
  flex: none; appearance: none; cursor: pointer; font-family: var(--mono); font-size: 12px; letter-spacing: .08em; text-transform: uppercase;
  background: var(--ink); color: var(--paper); border: 0; border-radius: 999px; padding: 11px 16px; min-height: 40px;
}
.cu-panel__close:focus-visible { outline: 2px solid var(--gold); outline-offset: 2px; }
.cu-panel__body { flex: 1; overflow-y: auto; overscroll-behavior: contain; padding: 16px 18px 40px; }
.cu-panel__intro, .plan-panel__intro { max-width: 62ch; }
/* Personalised strategy: desktop side panel (same width as CardUp); phone is a full-height bottom sheet. */
.plan-panel {
  position: fixed; top: 0; right: 0; bottom: 0; z-index: 50; width: calc(100% - 12px); max-width: 640px;
  background: var(--paper); border-left: 1px solid var(--line-gold); box-shadow: -8px 0 30px rgba(23,38,32,.2);
  display: flex; flex-direction: column;
}
.plan-panel__head { flex: none; display: flex; justify-content: space-between; align-items: flex-start; gap: 12px; padding: 16px 16px 12px 18px; border-bottom: 1px solid var(--line-gold); }
.plan-panel__head .eyebrow { margin-bottom: 6px; }
.plan-panel__head > div { min-width: 0; }
.plan-panel__head h2 { font-size: 26px; overflow-wrap: break-word; }
.plan-panel__head h2:focus { outline: none; }
.plan-panel__close {
  flex: none; appearance: none; cursor: pointer; font-family: var(--mono); font-size: 12px; letter-spacing: .08em; text-transform: uppercase;
  background: var(--ink); color: var(--paper); border: 0; border-radius: 999px; padding: 11px 16px; min-height: 40px;
}
.plan-panel__close:focus-visible { outline: 2px solid var(--gold); outline-offset: 2px; }
.plan-panel__body { flex: 1; overflow-y: auto; overscroll-behavior: contain; padding: 16px 18px 40px; }
.plan-panel .form { margin-top: 18px; }
.plan-panel .result { margin-top: 28px; }
.plan-panel .note { margin-top: 0; }
.cardup__grid { display: grid; gap: 16px; margin-top: 16px; }
.cu-steps__title { font-size: 19px; margin-top: 4px; }
.cu-steps { list-style: none; margin: 0; padding: 0; display: grid; gap: 8px; }
.cu-steps li { display: grid; grid-template-columns: 28px minmax(0, 1fr); gap: 8px; font-size: 14px; line-height: 1.45; }
.cu-steps__num { font-family: var(--mono); font-size: 12px; color: var(--gold); padding-top: 2px; }
.cu-src a { color: var(--ink); }
.cardup__block { border: 1px solid var(--line); border-radius: var(--radius); background: #fbfaf7; padding: 20px; display: grid; gap: 12px; align-content: start; min-width: 0; }
.cardup__block .mono-label { margin: 0; }
.cardup__sub { font-family: var(--mono); font-size: 12px; letter-spacing: .06em; text-transform: uppercase; color: var(--ink-soft); margin: 6px 0 0; }
.code { font-family: var(--mono); font-weight: 500; color: var(--ink); }
.formula { font-family: var(--mono); font-size: 14px; margin: 0; padding: 10px 12px; background: var(--paper-deep); border-radius: 8px; }
.worked { border-left: 2px solid var(--gold); padding: 2px 0 2px 12px; display: grid; gap: 2px; }
.worked p { margin: 0; }
.worked__label { font-size: 14px; color: var(--ink); }
.worked .calc { font-family: var(--mono); font-size: 12px; color: var(--ink-soft); line-height: 1.5; overflow-wrap: anywhere; }
.cu-table { width: 100%; border-collapse: collapse; font-size: 14px; }
.cu-table th { text-align: left; font-family: var(--mono); font-size: 12px; letter-spacing: .06em; text-transform: uppercase; color: var(--ink-soft); font-weight: 400; padding: 0 8px 6px 0; border-bottom: 1px solid var(--line); }
.cu-table td { padding: 7px 8px 7px 0; border-bottom: 1px solid var(--line); vertical-align: top; line-height: 1.35; }
.cu-table td:last-child { font-family: var(--mono); font-size: 13px; white-space: nowrap; }
.cu-no { color: var(--ink-soft); }
/* Recommended CardUp cards: one row per card, rate on the right; wraps on phones, never wider than the block. */
.cu-recs { list-style: none; margin: 0; padding: 0; display: grid; gap: 0; }
.cu-rec { display: grid; gap: 4px; padding: 10px 0; border-bottom: 1px solid var(--line); min-width: 0; }
.cu-rec:first-child { border-top: 1px solid var(--line); }
.cu-rec__head { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: baseline; gap: 4px 12px; min-width: 0; }
.cu-rec__name { margin: 0; font-size: 15px; line-height: 1.35; color: var(--ink); min-width: 0; overflow-wrap: break-word; }
.cu-rec__who { display: block; font-family: var(--mono); font-size: 12px; letter-spacing: .04em; color: var(--ink-soft); margin-top: 2px; }
.cu-rec__rate { margin: 0; font-family: var(--mono); font-size: 14px; color: var(--gold); white-space: nowrap; }
.cu-rec__note, .cu-rec__src { margin: 0; font-size: 13px; line-height: 1.45; color: var(--ink-soft); overflow-wrap: break-word; }
.cu-rec__src a { color: var(--ink); }
.cardup__foot { margin-top: 18px; display: grid; gap: 8px; }
.cardup__foot a, .cardup__foot b { color: var(--ink); }
.cardup__foot b { font-weight: 500; }
.cu-result { margin-top: 26px; padding-top: 20px; border-top: 1px solid rgba(196,162,90,.5); }
.cu-result .eyebrow { margin-bottom: 4px; }

/* In-flow CardUp button: a banner under the income range selector, opening the same side panel as the tab. */
.cu-cta {
  appearance: none; cursor: pointer; font: inherit; text-align: left; width: 100%; min-width: 0; margin: 20px 0 0;
  display: flex; align-items: center; justify-content: space-between; gap: 14px;
  background: var(--ink); color: var(--paper); border: 1px solid var(--ink); border-radius: var(--radius);
  padding: 16px 40px 16px 18px; box-shadow: inset 0 0 0 1px rgba(196,162,90,.35);   /* right padding keeps Open clear of the phone tab */
  transition: background .18s ease, box-shadow .18s ease;
}
.cu-cta:hover, .cu-cta:focus-visible { background: #1e3029; outline: none; box-shadow: inset 0 0 0 1px var(--gold-on-ink), 0 0 0 3px rgba(138,103,28,.3); }
.cu-cta__text { display: grid; gap: 4px; min-width: 0; }
.cu-cta__eyebrow { font-family: var(--mono); font-size: 12px; letter-spacing: .14em; text-transform: uppercase; color: var(--gold-on-ink); }
.cu-cta__title { font-size: 22px; font-weight: 300; line-height: 1.2; overflow-wrap: anywhere; }
.cu-cta__sub { font-size: 14px; line-height: 1.4; color: rgba(249,247,244,.8); }
.cu-cta__go {
  flex: none; font-family: var(--mono); font-size: 12px; letter-spacing: .1em; text-transform: uppercase;
  border: 1px solid var(--gold-on-ink); color: var(--gold-on-ink); border-radius: 999px; padding: 9px 14px; line-height: 1.2;
}
.cu-cta:hover .cu-cta__go, .cu-cta:focus-visible .cu-cta__go { background: var(--gold-on-ink); color: var(--ink); }

/* Plan / form */
.plan { margin-top: 72px; padding-top: 40px; border-top: 1px solid var(--line-gold); display: grid; gap: 28px; }
.plan__intro h2 { margin-bottom: 10px; }
.form { display: grid; gap: 18px; }
.field { display: grid; gap: 6px; }
.field > span, .field-group legend { font-size: 14px; color: var(--ink-soft); }
.field-group { border: 0; padding: 0; margin: 0; display: grid; gap: 14px; }
.field-group legend { font-family: var(--mono); font-size: 12px; letter-spacing: .1em; text-transform: uppercase; color: var(--gold); margin-bottom: 12px; padding: 0; }
.optional { color: var(--ink-soft); text-transform: none; letter-spacing: 0; }
.field input {
  font: inherit; font-size: 16px; color: var(--ink); background: var(--paper);
  border: 0; border-bottom: 1px solid var(--ink); border-radius: 0; padding: 10px 2px; width: 100%;
}
.field input:focus { outline: none; border-bottom-color: var(--gold); box-shadow: 0 1px 0 var(--gold); }
.check { display: flex; gap: 10px; align-items: center; font-size: 14px; color: var(--ink-soft); }
.check input { width: 18px; height: 18px; accent-color: var(--ink); }
.btn {
  appearance: none; border: 0; border-radius: 999px; background: var(--ink); color: var(--paper);
  font: inherit; font-size: 16px; padding: 15px 26px; cursor: pointer; justify-self: start;
}
.btn:hover, .btn:focus-visible { background: #24372f; outline: none; box-shadow: 0 0 0 3px rgba(138,103,28,.3); }

/* Result */
.result { background: var(--ink); color: var(--paper); border-radius: 20px; padding: 28px 22px; min-width: 0; }
.result h2 { color: var(--paper); font-size: clamp(30px, 6vw, 40px); }
.result .eyebrow { color: var(--gold-on-ink); }
.result p { margin: 0; }
.result__lead { color: rgba(249,247,244,.82); font-size: 15px; margin-top: 10px !important; }
.steps { list-style: none; margin: 24px 0 0; padding: 0; display: grid; }
.step { display: grid; grid-template-columns: 34px 1fr; gap: 10px; padding: 16px 0; border-top: 1px solid rgba(196,162,90,.35); }
.step__num { font-family: var(--mono); font-size: 12px; color: var(--gold-on-ink); padding-top: 4px; }
.step__label { font-family: var(--mono); font-size: 12px; letter-spacing: .1em; text-transform: uppercase; color: var(--gold-on-ink); }
.step__card { font-size: 19px; font-weight: 400; margin: 2px 0 4px !important; line-height: 1.3; }
.step__why { font-size: 14px; color: rgba(249,247,244,.8); }
.calc { font-family: var(--mono); font-size: 12px; color: rgba(249,247,244,.85); margin-top: 6px !important; line-height: 1.5; overflow-wrap: anywhere; }
.total { margin-top: 18px; padding: 18px; border: 1px solid rgba(196,162,90,.5); border-radius: 14px; }
.total__num { font-size: 36px; font-weight: 300; line-height: 1.1; margin: 4px 0 !important; }
.total__sub { font-size: 13px; color: rgba(249,247,244,.78); }
.extras { margin-top: 20px; display: grid; gap: 10px; }
.extras p { font-size: 14px; color: rgba(249,247,244,.85); padding-left: 14px; border-left: 1px solid var(--gold-on-ink); }
.result__disc { margin-top: 22px !important; font-size: 13px; color: rgba(249,247,244,.72); }

/* Footer */
.footer { position: relative; border-top: 1px solid var(--line-gold); padding: 28px 0 84px; overflow: hidden; }
.footer .small { max-width: 70ch; }

/* Phone: keep the income pills clear of the stacked side tabs on the right. */
@media (max-width: 719.98px) {
  .tier-bar { padding-right: 32px; }
}
/* Phone: strategy opens as a full-height bottom sheet, distinct from the CardUp side panel. */
@media (max-width: 719.98px) {
  .plan-panel {
    top: 16px; left: 0; right: 0; bottom: 0; width: 100%; max-width: none;
    border-left: 0; border-top: 1px solid var(--line-gold); border-radius: 16px 16px 0 0;
    box-shadow: 0 -8px 30px rgba(23,38,32,.2);
    height: auto; max-height: calc(100dvh - 16px); padding-bottom: env(safe-area-inset-bottom);
  }
  .plan-panel.is-zoom-in { animation: sheet-in var(--dur-in) var(--ease-enter) both; transform-origin: bottom center; }
  .plan-panel.is-zoom-out { animation: sheet-out var(--dur-in) var(--ease-exit) both; transform-origin: bottom center; }
}
@media (min-width: 720px) {
  .wrap { padding: 0 40px; }
  .choices { grid-template-columns: 1fr 1fr; max-width: 860px; }
  .choice { padding: 40px 32px 44px; min-height: 220px; align-content: end; }
  .choice__title { font-size: 42px; }
  /* Horizontal tiles: image slot left, details right, one full-width column, all the same fixed height. */
  .card { --tile-h: 332px; padding: 20px; grid-template-columns: 220px minmax(0, 1fr); grid-template-rows: minmax(0, 1fr); column-gap: 24px; }
  .card__media { grid-row: 1; align-self: start; width: 220px; height: calc(var(--tile-h) - 42px); padding: 14px; border-radius: 12px; }
  .card__body { display: grid; grid-column: 2; grid-row: 1; min-width: 0; min-height: 0; grid-template-rows: auto minmax(0, 1fr) auto auto; row-gap: 12px; }
  .card__top { grid-column: auto; grid-row: auto; grid-template-columns: minmax(0, 1fr) auto; align-items: start; gap: 12px; }
  .card__tags { justify-content: flex-end; }
  .card__title h3 { font-size: 21px; -webkit-line-clamp: 1; }
  .card__mid { grid-column: auto; grid-row: auto; grid-template-columns: minmax(0, 1.3fr) minmax(0, 1fr); gap: 24px; }
  .card .best, .card__actions { grid-column: auto; grid-row: auto; }
  .card .facts { align-self: start; padding: 0 0 0 18px; border: 0; border-left: 1px solid var(--line); }
  .best { -webkit-line-clamp: 1; }
  .side-tabs { width: 40px; right: max(8px, env(safe-area-inset-right)); justify-content: center; padding: 8px 0; }
  .side-tab, .cu-tab { width: 40px; padding: 18px 0; }
  .cu-cta { padding: 18px 24px; margin-top: 24px; }
  .cu-cta__title { font-size: 26px; }
  .side-tab__text, .cu-tab__text { font-size: 13px; }
  .cu-panel, .plan-panel { width: min(640px, 92vw); }
  .cu-panel__head, .plan-panel__head { padding: 22px 24px 16px 28px; }
  .cu-panel__head h2, .plan-panel__head h2 { font-size: 32px; }
  .cu-panel__body, .plan-panel__body { padding: 20px 28px 48px; }
  .segmented { max-width: 640px; gap: 0; }
  .segmented button { font-family: var(--mono); font-weight: 400; font-size: 14px; letter-spacing: 0; padding: 12px 10px; }
  .botanical--lily { width: 340px; right: 0; top: 0; }
  .logo { width: 148px; }
  .brand .eyebrow { font-size: 22px; letter-spacing: 0.18em; }
  .masthead__row { min-height: 88px; }
  .masthead__brand { flex-direction: row; align-items: baseline; gap: 20px; }
  .masthead__home { padding: 6px 0; }
  .welcome__mark { font-size: 22px; letter-spacing: 0.18em; margin-bottom: 22px; }
  .welcome__logo { width: 160px; margin: 32px 0 48px; }
}
/* Narrow desktop and zoomed windows (720 to 899px): the two text columns are narrower, so every tile is a little taller.
   One height for all tiles, so they stay equal; nothing on the face is clipped. */
@media (min-width: 720px) and (max-width: 899.98px) {
  .card { --tile-h: 376px; }
}
@media (min-width: 1100px) {
  .plan-panel .result { padding: 36px 32px; }
}
/* Motion: zoom traits taken from Darren's saved references (see REPORT.md).
   Transforms and opacity only, so nothing changes the layout or page width. */
:root {
  --ease-enter: cubic-bezier(.43, .195, .02, 1);
  --ease-exit: cubic-bezier(.5, 0, 0, 1);
  --dur-in: .3s;
  --dur-hover: .15s;
}
/* Reveals stay visible at full size so below-fold tiles are never empty gaps.
   The 0.96 zoom from the centre runs once, as they first enter the viewport. */
html.js-motion .reveal.is-entering {
  transform-origin: center center;
  animation: zoom-in-centre var(--dur-in) var(--ease-enter) both;
}
html.js-motion .reveal.is-in { opacity: 1; transform: none; }

html.js-motion .card.is-in,
html.js-motion .choice,
html.js-motion .btn,
html.js-motion .apply,
html.js-motion .card__open,
html.js-motion .card__close,
html.js-motion .cu-cta,
html.js-motion .cu-panel__close,
html.js-motion .plan-panel__close,
html.js-motion .link-btn,
html.js-motion .masthead__home,
html.js-motion .welcome__skip,
html.js-motion .segmented button {
  transition: transform var(--dur-hover) var(--ease-enter), border-color var(--dur-hover) ease, background var(--dur-hover) ease, box-shadow var(--dur-hover) ease;
  transform-origin: center center;
}
html.js-motion .card.is-in:hover,
html.js-motion .card.is-in:focus-visible {
  transform: scale(1.025);
}
html.js-motion .card.is-open.is-in:hover,
html.js-motion .card.is-open.is-in:focus-visible { transform: none; }
html.js-motion .choice:hover, html.js-motion .choice:focus-visible,
html.js-motion .btn:hover, html.js-motion .btn:focus-visible,
html.js-motion .apply:hover, html.js-motion .apply:focus-visible,
html.js-motion .card__open:hover, html.js-motion .card__open:focus-visible,
html.js-motion .card__close:hover, html.js-motion .card__close:focus-visible,
html.js-motion .cu-cta:hover, html.js-motion .cu-cta:focus-visible,
html.js-motion .cu-panel__close:hover, html.js-motion .cu-panel__close:focus-visible,
html.js-motion .plan-panel__close:hover, html.js-motion .plan-panel__close:focus-visible,
html.js-motion .link-btn:hover, html.js-motion .link-btn:focus-visible,
html.js-motion .masthead__home:hover, html.js-motion .masthead__home:focus-visible,
html.js-motion .welcome__skip:hover, html.js-motion .welcome__skip:focus-visible,
html.js-motion .segmented button:hover, html.js-motion .segmented button:focus-visible,
html.js-motion .choice:active, html.js-motion .btn:active, html.js-motion .apply:active,
html.js-motion .card__open:active, html.js-motion .cu-cta:active {
  transform: scale(1.025);
}
/* Side tab already uses transform to sit mid-viewport; do not add a hover scale on it. */

/* Panel grows from the tab's corner; details grow from the centre of the tile. */
.cu-panel.is-zoom-in, .plan-panel.is-zoom-in { animation: zoom-in-origin var(--dur-in) var(--ease-enter) both; transform-origin: top right; }
.cu-panel.is-zoom-out, .plan-panel.is-zoom-out { animation: zoom-out-origin var(--dur-in) var(--ease-exit) both; transform-origin: top right; }
@media (max-width: 719.98px) {
  .plan-panel.is-zoom-in { animation: sheet-in var(--dur-in) var(--ease-enter) both; transform-origin: bottom center; }
  .plan-panel.is-zoom-out { animation: sheet-out var(--dur-in) var(--ease-exit) both; transform-origin: bottom center; }
}
.card__more.is-zoom-in { animation: zoom-in-centre var(--dur-in) var(--ease-enter) both; transform-origin: center center; }
.card__more.is-zoom-out { animation: zoom-out-centre var(--dur-in) var(--ease-exit) both; transform-origin: center center; }
@keyframes zoom-in-centre {
  from { opacity: 0; transform: scale(0.96); }
  to { opacity: 1; transform: scale(1); }
}
@keyframes zoom-out-centre {
  from { opacity: 1; transform: scale(1); }
  to { opacity: 0; transform: scale(0.96); }
}
@keyframes zoom-in-origin {
  from { opacity: 0; transform: scale(0.96); }
  to { opacity: 1; transform: scale(1); }
}
@keyframes zoom-out-origin {
  from { opacity: 1; transform: scale(1); }
  to { opacity: 0; transform: scale(0.96); }
}
@keyframes sheet-in {
  from { opacity: 0; transform: translateY(24px); }
  to { opacity: 1; transform: translateY(0); }
}
@keyframes sheet-out {
  from { opacity: 1; transform: translateY(0); }
  to { opacity: 0; transform: translateY(24px); }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    transition: none !important;
    animation: none !important;
    scroll-behavior: auto !important;
  }
  html.js-motion .reveal:not(.is-in),
  html.js-motion .reveal.is-in,
  html.js-motion .card.is-in:hover,
  html.js-motion .choice:hover {
    opacity: 1 !important;
    transform: none !important;
  }
}
