/* HonestSums Bank Switch Planner: app styles (brand v3 "Smiley sum", build/DESIGN.md; same family as the Savings
   Tracker). Phone first: one column, big tap targets, a tab bar at the bottom. No inline styles anywhere (the site's
   Content-Security-Policy allows style-src 'self' only); the only styles set from JavaScript go through the CSSOM
   (the bar widths), which the policy allows. */

@font-face {
  font-family: "Fredoka";
  src: url("/assets/fonts/fredoka-latin.woff2") format("woff2");
  font-weight: 300 700;
  font-display: swap;
}
@font-face {
  font-family: "Nunito";
  src: url("/assets/fonts/nunito-latin.woff2") format("woff2");
  font-weight: 200 1000;
  font-display: swap;
}

:root {
  --sun: #FFC845;
  --sun-deep: #F5B417;
  --navy: #1E2A4A;
  --navy-soft: #2D3C63;
  --navy-deep: #151E36;
  --tomato: #F2603F;
  --tomato-text: #B5381B;
  --candy: #F9C4CF;
  --mint: #BFE6D3;
  --mint-deep: #276A4C;
  --paper: #FFFCF4;
  --butter: #FFF1C9;
  --white: #FFFFFF;
  --mute: #5B6478;
  --mute-on-navy: #C9D0E2;
  --line: #E8E2D3;
  --line-strong: #CFC6B0;
  --radius: 18px;
  --display: "Fredoka", "Nunito", "Segoe UI", system-ui, sans-serif;
  --body: "Nunito", "Segoe UI", system-ui, -apple-system, Roboto, Arial, sans-serif;
  color-scheme: light;
}

*, *::before, *::after { box-sizing: border-box; }
[hidden] { display: none !important; }
html { -webkit-text-size-adjust: 100%; text-size-adjust: 100%; }
body {
  margin: 0;
  background: var(--paper);
  color: var(--navy);
  font-family: var(--body);
  font-weight: 600;
  font-size: 1rem;
  line-height: 1.45;
  overflow-x: hidden;
}
h1, h2, h3 { font-family: var(--display); font-weight: 600; line-height: 1.2; margin: 0; }
p { margin: 0 0 10px; }
a { color: var(--navy); text-decoration-thickness: 2px; text-underline-offset: 2px; }
button, input, select, textarea { font: inherit; color: inherit; }
:focus-visible { outline: 3px solid var(--tomato-text); outline-offset: 2px; }
h1:focus, h2:focus { outline: none; }
.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;
}
.center { text-align: center; }
.file-btn { cursor: pointer; }
#import-file:focus-visible + .file-btn { outline: 3px solid var(--tomato-text); outline-offset: 2px; }

.app { max-width: 560px; margin: 0 auto; min-height: 100vh; min-height: 100dvh; }

/* ------------------------------------------------------------------ top bar */
.topbar {
  display: flex; align-items: center; gap: 12px;
  background: var(--paper);
  border-bottom: 1px solid var(--line);
  padding: calc(12px + env(safe-area-inset-top)) 16px 12px;
}
.topbar-mark { width: 40px; height: 40px; flex: none; }
.topbar-text p { margin: 0; }
.topbar-title { font-family: var(--display); font-size: 1.12rem; line-height: 1.15; }
.topbar-by { font-family: var(--display); font-size: 0.95rem; line-height: 1.1; }
.topbar-checked {
  margin: 0 0 0 auto; text-align: right; font-size: 0.75rem; line-height: 1.2; color: var(--mute); font-weight: 800;
  max-width: 96px;
}
.topbar-checked b { display: block; color: var(--mint-deep); }
.w-honest { color: var(--navy); }
.w-sums { color: var(--tomato); }

/* ------------------------------------------------------------------ layout */
.main { padding: 16px 16px calc(96px + env(safe-area-inset-bottom)); }
.panel-title { font-size: 1.75rem; margin: 4px 0 4px; }
.panel-sub { color: var(--mute); margin-bottom: 14px; }
.eyebrow { font-weight: 800; font-size: 0.8rem; letter-spacing: 0.06em; text-transform: uppercase; margin: 0 0 6px; color: var(--tomato-text); }
.hint { display: block; color: var(--mute); font-size: 0.92rem; margin: 6px 0 0; }
.small { color: var(--mute); font-size: 0.9rem; }
.fine { color: var(--mute); font-size: 0.82rem; text-align: center; margin-top: 18px; }

.card {
  background: var(--white);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 16px;
  margin: 0 0 14px;
}
.card-mint { background: #E6F5EE; border-color: var(--mint); }
.card-butter { background: var(--butter); border-color: #F6DE9A; }
.card-title { font-size: 1.2rem; margin-bottom: 10px; }
.card p:last-child { margin-bottom: 0; }
.section-title { font-size: 1.2rem; margin: 22px 0 10px; display: flex; align-items: baseline; justify-content: space-between; gap: 10px; }
.section-title a, .section-title .link-btn { font-family: var(--body); font-size: 0.92rem; font-weight: 800; }

.notice { background: var(--candy); border-radius: 14px; padding: 12px 14px; margin: 0 0 14px; font-weight: 700; }
.warn { background: var(--butter); border: 1px solid #F6DE9A; border-radius: 12px; padding: 10px 12px; font-size: 0.95rem; }
.changes {
  background: #E6F5EE; border: 1px solid var(--mint); border-radius: 14px; padding: 12px 14px; margin: 0 0 14px;
  font-weight: 700;
}
.changes ul { margin: 6px 0 0; padding-left: 1.2em; }
.changes .link-btn { margin-top: 6px; }

.back {
  display: inline-flex; align-items: center; gap: 4px;
  min-height: 44px; padding: 0 12px 0 4px; margin: -6px 0 2px -4px;
  background: none; border: 0; cursor: pointer; color: var(--navy);
  font-weight: 800; font-size: 1rem;
  -webkit-tap-highlight-color: transparent;
}
.back span { font-size: 1.7rem; line-height: 1; margin-top: -3px; }
.link-btn {
  background: none; border: 0; padding: 6px 0; min-height: 44px; cursor: pointer; color: var(--navy);
  font-weight: 800; text-decoration: underline; text-decoration-thickness: 2px; text-underline-offset: 3px;
}

/* ------------------------------------------------------------------ buttons */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  min-height: 48px; padding: 0 20px;
  border-radius: 999px; border: 2px solid transparent;
  font-weight: 800; font-size: 1rem; line-height: 1.15; text-align: center;
  cursor: pointer; text-decoration: none;
  -webkit-tap-highlight-color: transparent;
}
.btn-primary { background: var(--navy); color: var(--sun); }
.btn-primary:hover { background: var(--navy-soft); }
.btn-sun { background: var(--sun); color: var(--navy); box-shadow: 0 4px 0 var(--sun-deep); }
.btn-sun:hover { background: #FFD15F; }
.btn-ghost { background: transparent; border-color: var(--navy); color: var(--navy); }
.btn-ghost:hover { background: rgba(30, 42, 74, 0.06); }
.btn-on-navy { background: transparent; border-color: var(--paper); color: var(--paper); }
.btn-danger { background: var(--tomato-text); color: var(--white); }
.btn-danger:hover { background: #9C2E14; }
.btn-small { min-height: 44px; padding: 0 16px; font-size: 0.95rem; }
.btn-big { min-height: 58px; font-size: 1.15rem; }
.btn-wide { width: 100%; }
.btn-note { font-size: 0.85rem; font-weight: 800; opacity: 0.8; background: rgba(30, 42, 74, 0.1); padding: 3px 8px; border-radius: 999px; }
.btn-primary .btn-note { background: rgba(255, 200, 69, 0.18); }
.btn svg { width: 20px; height: 20px; flex: none; fill: none; stroke: currentColor; stroke-width: 3.2; stroke-linecap: round; stroke-linejoin: round; }
.btn-row { display: flex; flex-wrap: wrap; gap: 10px; align-items: center; margin-top: 12px; }
.btn-row > .btn { flex: 1 1 auto; }

/* ------------------------------------------------------------------ forms */
.field { margin: 0 0 16px; }
.label { display: block; font-weight: 800; margin-bottom: 6px; }
.label-hint { font-weight: 600; color: var(--mute); }
.input {
  display: block; width: 100%; min-height: 50px;
  padding: 10px 14px;
  font-size: 1.06rem;
  background: var(--white);
  border: 2px solid var(--line-strong);
  border-radius: 12px;
}
.textarea { min-height: 84px; font-size: 0.9rem; word-break: break-all; }
.input:focus { border-color: var(--navy); outline: none; box-shadow: 0 0 0 3px var(--sun); }
.input[aria-invalid="true"] { border-color: var(--tomato-text); }
.input-code { text-transform: uppercase; letter-spacing: 0.06em; font-weight: 800; text-align: center; font-size: 1.25rem; }
.input-order { text-transform: none; letter-spacing: 0.04em; }
.money-input { position: relative; }
.money-input span { position: absolute; left: 14px; top: 50%; transform: translateY(-50%); font-weight: 800; font-size: 1.1rem; }
.money-input .input { padding-left: 32px; font-weight: 800; font-size: 1.2rem; }
.error { color: var(--tomato-text); font-weight: 800; margin: 8px 0 0; }
.confirm { background: #FDE8EC; border: 1px solid var(--candy); border-radius: 14px; padding: 12px 14px; margin-top: 12px; }
.backup-label { margin-top: 16px; }
.code-form { margin-top: 18px; padding-top: 16px; border-top: 1px solid var(--line); text-align: left; }
.code-row { display: flex; gap: 8px; }
.code-row .input { flex: 1; min-width: 0; }

/* ------------------------------------------------------------------ welcome */
.welcome-hero {
  background: var(--navy); color: var(--paper); border-radius: 24px; padding: 24px 20px 22px; text-align: center;
  margin-bottom: 16px; position: relative; overflow: hidden;
}
.welcome-hero::before {
  content: ""; position: absolute; width: 260px; height: 260px; border-radius: 50%; right: -90px; top: -110px;
  background: rgba(255, 200, 69, 0.12);
}
.welcome-hero .eyebrow { color: var(--sun); }
.welcome-total { font-family: var(--display); font-size: 4rem; line-height: 1; color: var(--sun); margin: 4px 0 2px; position: relative; }
.welcome-total-sub { color: var(--mute-on-navy); margin-bottom: 18px; }
.welcome-title { font-size: 1.8rem; margin-bottom: 8px; position: relative; }
.welcome-sub { color: var(--mute-on-navy); margin-bottom: 18px; }
/* Short screens (TikTok's in-app browser on a small iPhone is about 560px tall): keep the start button well in view. */
@media (max-height: 720px) {
  .welcome-hero { padding: 16px 18px 18px; margin-bottom: 12px; }
  .welcome-total { font-size: 3.1rem; }
  .welcome-total-sub { margin-bottom: 10px; font-size: 0.95rem; }
  .welcome-hero .xmas-flag { margin-bottom: 8px; font-size: 0.85rem; padding: 4px 12px; }
  .welcome-title { font-size: 1.5rem; margin-bottom: 6px; }
  .welcome-sub { margin-bottom: 12px; font-size: 0.95rem; }
  .quiz-bar { margin-bottom: 12px; }
  .quiz-sofar { margin: -4px 0 10px; }
  .quiz-title { font-size: 1.35rem; margin-bottom: 4px; }
  .year-rows { margin-top: 10px; gap: 8px; }
  .year-row { padding: 10px 12px; }
  .year-row p { margin-bottom: 6px; font-size: 0.95rem; }
}
.trust { list-style: none; padding: 0; margin: 0 0 14px; display: grid; gap: 10px; }
.trust li {
  background: var(--white); border: 1px solid var(--line); border-radius: 14px; padding: 12px 14px 12px 48px;
  position: relative;
}
.trust li::before {
  content: ""; position: absolute; left: 14px; top: 14px; width: 22px; height: 22px; border-radius: 50%;
  background: var(--mint); box-shadow: inset 0 0 0 6px var(--mint-deep);
}

/* ------------------------------------------------------------------ quick start */
.quiz-top { display: flex; align-items: center; justify-content: space-between; }
.quiz-count { margin: 0; color: var(--mute); font-weight: 800; font-size: 0.9rem; }
.quiz-bar { height: 8px; background: var(--line); border-radius: 999px; overflow: hidden; margin: 4px 0 18px; }
.quiz-bar span { display: block; height: 100%; width: 0; background: var(--sun-deep); border-radius: 999px; }
.quiz-title { font-size: 1.6rem; margin-bottom: 6px; }
.quiz-hint { color: var(--mute); margin-bottom: 16px; }
.quiz-next { margin-top: 18px; }
.opts { display: grid; gap: 10px; }
.opt {
  display: flex; align-items: center; gap: 12px; width: 100%; text-align: left; min-height: 60px; padding: 12px 16px;
  border: 2px solid var(--line-strong); border-radius: 16px; background: var(--white); cursor: pointer;
  -webkit-tap-highlight-color: transparent;
}
.opt-text { display: block; min-width: 0; }
.opt-name { display: block; font-weight: 800; font-size: 1.05rem; }
.opt-blurb { display: block; color: var(--mute); font-size: 0.9rem; line-height: 1.35; margin-top: 2px; }
.opt-dot { flex: none; width: 24px; height: 24px; border-radius: 50%; border: 2px solid var(--line-strong); background: var(--white); }
.opt[aria-pressed="true"], .opt[aria-checked="true"] { border-color: var(--navy); background: var(--butter); }
.opt[aria-pressed="true"] .opt-dot, .opt[aria-checked="true"] .opt-dot { border-color: var(--navy); background: var(--navy); box-shadow: inset 0 0 0 4px var(--butter); }
.opt-tag { margin-left: auto; flex: none; font-size: 0.75rem; font-weight: 800; background: var(--mint); color: var(--navy); padding: 4px 8px; border-radius: 999px; }
.chips { display: flex; flex-wrap: wrap; gap: 8px; }
.chip {
  min-height: 46px; padding: 8px 16px;
  border-radius: 999px; border: 2px solid var(--line-strong);
  background: var(--white); color: var(--navy);
  font-weight: 800; font-size: 0.98rem; cursor: pointer;
  -webkit-tap-highlight-color: transparent;
}
.chip[aria-pressed="true"] { border-color: var(--navy); background: var(--navy); color: var(--sun); }
.chip-none { border-style: dashed; }
.year-rows { margin-top: 16px; display: grid; gap: 12px; }
.year-row { background: var(--white); border: 1px solid var(--line); border-radius: 14px; padding: 12px; }
.year-row p { margin: 0 0 8px; font-weight: 800; }
.seg { display: grid; grid-template-columns: repeat(3, 1fr); gap: 6px; }
.seg button {
  min-height: 44px; border-radius: 999px; border: 2px solid var(--line-strong); background: var(--white); cursor: pointer;
  font-weight: 800; font-size: 0.9rem; padding: 4px 6px; line-height: 1.1;
}
.seg button[aria-pressed="true"] { border-color: var(--navy); background: var(--butter); }
.pace-compare { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; margin-top: 4px; }
.pace-compare div { background: var(--white); border: 1px solid var(--line); border-radius: 12px; padding: 10px; text-align: center; font-size: 0.88rem; color: var(--mute); }
.pace-compare b { display: block; font-family: var(--display); font-weight: 600; font-size: 1.3rem; color: var(--navy); }
.name-field { margin-top: 14px; }
.quiz-sub-label { margin: 18px 0 8px; }
.seg-2 { grid-template-columns: 1fr 1fr; }

/* ------------------------------------------------------------------ plan reveal */
.reveal-hero { text-align: center; padding: 8px 0 6px; }
.reveal-title { font-size: 1.5rem; }
.reveal-total { font-family: var(--display); font-size: 4.4rem; line-height: 1; color: var(--tomato); margin: 6px 0 6px; }
.reveal-sub { color: var(--mute); }
.reveal-buy { margin: 12px 0 4px; min-height: 64px; line-height: 1.25; padding: 10px 18px; white-space: normal; }
.credit-warn { margin-top: 14px; }
.welcome-free { color: var(--mute-on-navy); font-size: 0.92rem; margin: 10px 0 0; position: relative; }
.welcome-shop-row { margin: 12px 0 0; position: relative; }
.review-steps { margin: 6px 0 10px; padding-left: 22px; display: grid; gap: 8px; }
/* shop reviews on the welcome screen (assets/reviews.js) */
.welcome-reviews { margin: 4px 0 16px; }
.welcome-reviews-title { font-size: 1.1rem; text-align: center; margin: 0 0 10px; }
.welcome-reviews .review-cards { display: grid; gap: 10px; margin-bottom: 6px; }
.welcome-reviews .review-card { margin: 0; background: var(--white); border: 1px solid var(--line); border-radius: 14px; padding: 12px 14px; }
.welcome-reviews .review-stars { margin: 0 0 4px; color: var(--sun-deep); letter-spacing: 2px; }
.welcome-reviews blockquote { margin: 0 0 6px; font-weight: 800; color: var(--navy); }
.welcome-reviews figcaption { color: var(--mute); font-size: 0.85rem; }
.welcome-shop { color: var(--sun); font-weight: 800; font-size: 0.95rem; text-underline-offset: 3px; }
/* the running total in the free check */
.quiz-sofar { margin: -8px 0 14px; display: inline-block; background: var(--navy); color: var(--paper); border-radius: 999px;
  padding: 5px 14px; font-weight: 800; font-size: 0.95rem; }
.quiz-sofar b { color: var(--sun); font-family: var(--display); font-weight: 400; font-size: 1.1rem; }
.reveal-quick { color: var(--mute); font-size: 0.88rem; margin: 4px 0 0; }
/* the buy bar on the plan-is-ready page (shown while neither buy button is on screen) */
.buy-bar { position: fixed; left: 50%; transform: translateX(-50%); bottom: 0; z-index: 30; width: 100%; max-width: 560px;
  background: var(--white); border-top: 1px solid var(--line); padding: 8px 14px calc(8px + env(safe-area-inset-bottom));
  box-shadow: 0 -6px 20px rgba(30, 42, 74, 0.12); }
.buy-bar .btn { min-height: 52px; }
body.has-buy-bar #panel-reveal { padding-bottom: 84px; }
.trust-mini { list-style: none; padding: 0; margin: 6px 0 14px; display: flex; flex-wrap: wrap; justify-content: center; gap: 4px 14px; font-size: 0.85rem; font-weight: 800; color: var(--mint-deep); }
.trust-mini li::before { content: "\2713 "; }
.reveal-little { text-align: left; border-left: 8px solid var(--sun-deep); margin-top: 12px; }
.reveal-list { list-style: none; padding: 0; margin: 14px 0 6px; display: grid; gap: 8px; }
.reveal-list li {
  display: flex; align-items: center; gap: 12px; background: var(--white); border: 1px solid var(--line);
  border-radius: 14px; padding: 10px 14px;
}
.reveal-list .num {
  flex: none; width: 32px; height: 32px; border-radius: 50%; background: var(--navy); color: var(--sun);
  display: flex; align-items: center; justify-content: center; font-family: var(--display); font-size: 1rem;
}
.reveal-list .who { display: block; color: var(--mute); font-size: 0.82rem; font-weight: 800; }
.reveal-list .amt { margin-left: auto; font-family: var(--display); font-size: 1.25rem; }
/* CR-058: the bank they came from (/switch?bank=...) */
.reveal-list li.picked { border: 2px solid var(--sun-deep); background: var(--butter); }
.reveal-list .picked-who { color: var(--navy); }
.quiz-intro { font-weight: 800; color: var(--mint-deep); margin: 0 0 6px; }
#sheet-buy .consent { margin: 14px 0; }
.welcome-bank { background: var(--navy-soft); color: var(--white); border-radius: 14px; padding: 10px 14px; margin: 0 0 14px; font-weight: 700; }
.lock-card { text-align: left; border-top: 8px solid var(--sun); margin-top: 14px; }
.lock-card .btn-sun { margin-top: 6px; }
.ticks { list-style: none; padding: 0; margin: 0 0 14px; }
.ticks li { position: relative; padding-left: 30px; margin-bottom: 8px; }
.ticks li::before {
  content: ""; position: absolute; left: 4px; top: 5px; width: 8px; height: 13px;
  border: solid var(--mint-deep); border-width: 0 3px 3px 0; transform: rotate(45deg);
}

/* ------------------------------------------------------------------ dashboard */
.dash {
  background: var(--navy); color: var(--paper); border-radius: 24px; padding: 18px 18px 16px; margin-bottom: 14px;
  position: relative; overflow: hidden;
}
.dash::after {
  content: ""; position: absolute; width: 220px; height: 220px; border-radius: 50%; right: -80px; bottom: -120px;
  background: rgba(255, 200, 69, 0.1); pointer-events: none;
}
.dash-top { display: flex; align-items: center; gap: 16px; position: relative; z-index: 1; }
.dash-figs { min-width: 0; flex: 1; }
.dash-label { margin: 0; color: var(--mute-on-navy); font-weight: 800; font-size: 0.85rem; text-transform: uppercase; letter-spacing: 0.05em; }
.dash-big { font-family: var(--display); font-size: 3.2rem; line-height: 1; color: var(--sun); margin: 2px 0 4px; }
.dash-of { margin: 0; color: var(--mute-on-navy); }
.dash-of b { color: var(--paper); }
.dash-bar { height: 12px; background: rgba(255, 255, 255, 0.14); border-radius: 999px; overflow: hidden; margin: 14px 0 8px; position: relative; z-index: 1; }
.dash-bar span { display: block; height: 100%; width: 0; background: var(--sun); border-radius: 999px; }
.dash-stats { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; position: relative; z-index: 1; }
.dash-stat { background: rgba(255, 255, 255, 0.07); border-radius: 12px; padding: 8px; text-align: center; }
.dash-stat b { display: block; font-family: var(--display); font-weight: 600; font-size: 1.25rem; color: var(--paper); }
.dash-stat span { font-size: 0.75rem; color: var(--mute-on-navy); font-weight: 800; }
.dash-banner { margin: 12px 0 0; font-weight: 800; color: var(--sun); text-align: center; position: relative; z-index: 1; }

.next {
  background: var(--sun); border-radius: 24px; padding: 18px; margin-bottom: 14px;
  box-shadow: 0 6px 0 var(--sun-deep);
}
.next .eyebrow { color: var(--navy); opacity: 0.8; }
.next-title { font-size: 1.45rem; margin-bottom: 6px; }
.next-desc { margin-bottom: 10px; }
.next .btn-primary { min-width: 140px; }
.next .btn-ghost { border-color: var(--navy); }
.next-done { background: #E6F5EE; box-shadow: 0 6px 0 var(--mint); }
.due {
  display: inline-flex; align-items: center; gap: 6px; font-weight: 800; font-size: 0.9rem; padding: 5px 10px;
  border-radius: 999px; background: rgba(30, 42, 74, 0.1); margin: 0 0 10px;
}
.due-soon { background: var(--tomato-text); color: var(--white); }
.due-ok { background: var(--white); }
.due svg { width: 16px; height: 16px; fill: none; stroke: currentColor; stroke-width: 2.4; stroke-linecap: round; }
.next-prep { background: rgba(255, 255, 255, 0.55); border-radius: 12px; padding: 8px 12px; font-size: 0.92rem; margin: 0 0 10px; }

.soon-list { list-style: none; margin: 0; padding: 0; background: var(--white); border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden; }
.soon-list li { display: flex; align-items: center; gap: 12px; padding: 12px 14px; border-top: 1px solid var(--line); }
.soon-list li:first-child { border-top: 0; }
.soon-day {
  flex: none; width: 52px; text-align: center; border-radius: 12px; background: var(--paper); border: 1px solid var(--line);
  padding: 4px 0; line-height: 1.05;
}
.soon-day b { display: block; font-family: var(--display); font-weight: 600; font-size: 1.35rem; }
.soon-day span { font-size: 0.72rem; font-weight: 800; color: var(--mute); text-transform: uppercase; }
.soon-text { min-width: 0; flex: 1; }
.soon-text b { display: block; }
.soon-text span { color: var(--mute); font-size: 0.88rem; }
.soon-bonus .soon-day { background: var(--butter); border-color: #F6DE9A; }
.soon-ends .soon-day { background: #FDE8EC; border-color: var(--candy); }

.journey {
  display: flex; gap: 0; overflow-x: auto; padding: 6px 2px 10px; margin: 0 -2px; scroll-snap-type: x proximity;
  -webkit-overflow-scrolling: touch;
}
.stop {
  flex: none; width: 84px; text-align: center; position: relative; scroll-snap-align: start; background: none; border: 0;
  padding: 0; cursor: pointer; color: var(--navy); text-decoration: none;
}
.stop::before {
  content: ""; position: absolute; top: 26px; left: -50%; width: 100%; height: 4px; background: var(--line-strong); z-index: 0;
}
.stop:first-child::before { display: none; }
.stop.is-paid::before, .stop.is-active::before { background: var(--sun-deep); }
.stop-dot {
  position: relative; z-index: 1; width: 56px; height: 56px; margin: 0 auto 6px; border-radius: 50%;
  background: var(--white); border: 3px solid var(--line-strong); display: flex; align-items: center; justify-content: center;
  font-family: var(--display); font-size: 1rem;
}
.stop.is-paid .stop-dot { background: var(--mint); border-color: var(--mint-deep); }
.stop.is-active .stop-dot { background: var(--sun); border-color: var(--navy); }
.stop.is-next .stop-dot { border-color: var(--navy); border-style: dashed; }
.stop-name { display: block; font-weight: 800; font-size: 0.8rem; line-height: 1.15; }
.stop-amt { display: block; font-size: 0.8rem; color: var(--mute); font-weight: 800; }
.stop svg { width: 26px; height: 26px; fill: none; stroke: var(--mint-deep); stroke-width: 3.5; stroke-linecap: round; stroke-linejoin: round; }

.update-item { padding: 8px 0 0; margin: 8px 0 0; border-top: 1px solid var(--line); }
.update-item:first-of-type { border-top: 0; padding-top: 0; margin-top: 0; }
.update-date { display: block; font-size: 0.8rem; font-weight: 800; color: var(--mute); }
.checked-pill {
  display: inline-flex; align-items: center; gap: 6px; background: #E6F5EE; border: 1px solid var(--mint);
  color: var(--mint-deep); font-weight: 800; font-size: 0.85rem; padding: 4px 10px; border-radius: 999px; margin-bottom: 8px;
}
.checked-pill::before { content: ""; width: 8px; height: 8px; border-radius: 50%; background: var(--mint-deep); }

/* ------------------------------------------------------------------ the plan */
.timeline { list-style: none; margin: 0 0 8px; padding: 0; position: relative; }
.timeline::before { content: ""; position: absolute; left: 19px; top: 20px; bottom: 20px; width: 4px; background: var(--line); border-radius: 2px; }
.tl { position: relative; padding-left: 52px; margin-bottom: 12px; }
.tl-num {
  position: absolute; left: 0; top: 14px; width: 42px; height: 42px; border-radius: 50%; background: var(--white);
  border: 3px solid var(--line-strong); display: flex; align-items: center; justify-content: center;
  font-family: var(--display); font-size: 1.05rem; z-index: 1;
}
.tl.is-paid .tl-num { background: var(--mint); border-color: var(--mint-deep); }
.tl.is-active .tl-num { background: var(--sun); border-color: var(--navy); }
.tl-num svg { width: 22px; height: 22px; fill: none; stroke: var(--mint-deep); stroke-width: 3.5; stroke-linecap: round; stroke-linejoin: round; }
.tl-card {
  display: block; width: 100%; text-align: left; background: var(--white); border: 1px solid var(--line);
  border-radius: var(--radius); padding: 14px 16px; cursor: pointer; color: var(--navy); text-decoration: none;
}
.tl.is-active .tl-card { border: 2px solid var(--navy); }
.tl.is-paid .tl-card { background: #F4FBF7; }
.tl-head { display: flex; align-items: baseline; gap: 10px; }
.tl-bank { font-family: var(--display); font-size: 1.2rem; }
.tl-amt { margin-left: auto; font-family: var(--display); font-size: 1.3rem; }
.tl-meta { display: block; color: var(--mute); font-size: 0.9rem; margin-top: 2px; }
.tl-who { font-size: 0.78rem; font-weight: 800; color: var(--mute); text-transform: uppercase; letter-spacing: 0.04em; }
.pill {
  display: inline-block; font-size: 0.75rem; font-weight: 800; line-height: 1; padding: 5px 9px; border-radius: 999px;
  background: var(--paper); border: 1px solid var(--line); margin-top: 8px;
}
.pill-active { background: var(--sun); border-color: var(--sun-deep); }
.pill-paid { background: var(--mint); border-color: var(--mint-deep); }
.pill-next { background: var(--navy); color: var(--sun); border-color: var(--navy); }
.pill-check { background: var(--butter); border-color: #F6DE9A; }
.pill-xmas { background: #FDE8EC; border-color: var(--tomato); color: var(--tomato-text); }
.pill-jan { background: #E6F5EE; border-color: var(--mint); color: var(--mint-deep); }
.xmas-who { color: var(--tomato-text); }
.xmas-flag {
  display: inline-block; position: relative; background: var(--tomato-text); color: var(--white); font-weight: 800;
  font-size: 0.9rem; padding: 6px 14px; border-radius: 999px; margin: 0 0 12px; transform: rotate(-2deg);
}
.reveal-xmas { background: #FDE8EC; border: 1px solid var(--candy); border-radius: 14px; padding: 10px 14px; font-weight: 800; color: var(--tomato-text); }
.dash-xmas {
  background: var(--tomato-text); color: var(--white); border-radius: 14px; padding: 10px 14px; margin: -4px 0 14px;
  font-weight: 800; text-align: center;
}
.dash-share { margin: 12px 0 0; position: relative; z-index: 1; }
.dash-banner + .dash-xmas { margin-top: 12px; }   /* day one: no share button between them, so give the banner room */
.notes-title { display: block; }
.mini-bar { display: block; height: 8px; background: var(--paper); border: 1px solid var(--line); border-radius: 999px; overflow: hidden; margin-top: 10px; }
.mini-bar span { display: block; height: 100%; width: 0; background: var(--sun-deep); }
.tl-note { display: block; font-size: 0.88rem; margin-top: 8px; background: var(--butter); border-radius: 10px; padding: 6px 10px; }
.person-head { font-size: 1.3rem; margin: 20px 0 10px; }
.person-head:first-child { margin-top: 4px; }
.not-list { list-style: none; padding: 0; margin: 0; }
.not-list li { background: var(--white); border: 1px solid var(--line); border-radius: 14px; padding: 10px 14px; margin-bottom: 8px; }
.not-list b { display: block; }
.not-list span { color: var(--mute); font-size: 0.9rem; }
.not-list .kind { font-size: 0.72rem; font-weight: 800; text-transform: uppercase; letter-spacing: 0.04em; color: var(--tomato-text); }
.faster { border-left: 8px solid var(--mint-deep); }

/* ------------------------------------------------------------------ can I get it? */
.check-link { display: block; text-decoration: none; color: var(--navy); border-left: 8px solid var(--sun-deep); }
.check-link strong { display: block; font-family: var(--display); font-weight: 600; font-size: 1.1rem; }
.check-link span { display: block; color: var(--mute); font-size: 0.92rem; margin-top: 2px; }
.check-link::after { content: "Check now \203A"; display: inline-block; margin-top: 8px; font-weight: 800; text-decoration: underline; text-underline-offset: 3px; }
.elig-verdict { border-radius: 14px; padding: 10px 14px; margin: 0 0 12px; }
.elig-verdict strong { display: block; font-family: var(--display); font-weight: 600; font-size: 1.15rem; }
.elig-verdict span { display: block; font-size: 0.92rem; }
.elig-verdict.is-yes { background: #E6F5EE; border: 1px solid var(--mint); }
.elig-verdict.is-no { background: #FDE8EC; border: 1px solid var(--candy); }
.elig-verdict.is-maybe { background: var(--butter); border: 1px solid #F6DE9A; }
.elig-list { list-style: none; margin: 0 0 12px; padding: 0; }
.elig-row { display: flex; gap: 10px; align-items: flex-start; padding: 12px 0; border-top: 1px solid var(--line); }
.elig-row:first-child { border-top: 0; padding-top: 0; }
.elig-qs .elig-row { background: var(--white); border: 1px solid var(--line); border-radius: 16px; padding: 12px 14px; margin-bottom: 8px; }
.elig-ico {
  flex: none; width: 26px; height: 26px; border-radius: 50%; margin-top: 2px; display: flex; align-items: center; justify-content: center;
  font-weight: 800; font-size: 0.95rem; background: var(--paper); border: 2px solid var(--line-strong); color: var(--mute);
}
.elig-ico::before { content: "?"; }
.is-pass .elig-ico { background: var(--mint); border-color: var(--mint-deep); color: var(--mint-deep); }
.is-pass .elig-ico::before { content: "\2713"; }
.is-fail .elig-ico { background: #FDE8EC; border-color: var(--tomato-text); color: var(--tomato-text); }
.is-fail .elig-ico::before { content: "\2715"; }
.is-check .elig-ico, .is-ask .elig-ico { background: var(--butter); border-color: var(--sun-deep); color: var(--navy); }
.is-later .elig-ico::before { content: "\2192"; }
.is-auto .elig-ico::before { content: "\2026"; }
.elig-body { min-width: 0; flex: 1; }
.elig-q { display: block; font-weight: 800; }
.elig-line { display: block; color: var(--mute); font-size: 0.9rem; margin: 2px 0 8px; }
.seg-3 { grid-template-columns: repeat(3, 1fr); }
.elig-results .kind { margin-left: 6px; }
.elig-result.is-yes .kind { color: var(--mint-deep); }
.elig-result.is-maybe .kind { color: var(--navy); }

/* ------------------------------------------------------------------ one switch */
.sw-head { margin-bottom: 12px; }
.sw-title { font-size: 1.8rem; }
.sw-account { color: var(--mute); margin: 2px 0 0; }
.sw-prize {
  display: flex; align-items: center; gap: 14px; background: var(--navy); color: var(--paper); border-radius: 20px;
  padding: 14px 16px; margin: 12px 0 14px;
}
.sw-prize-amt { font-family: var(--display); font-size: 2.6rem; line-height: 1; color: var(--sun); }
.sw-prize-text { font-size: 0.92rem; color: var(--mute-on-navy); }
.sw-prize-text b { color: var(--paper); display: block; font-size: 1rem; }
.needs { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; margin: 0 0 14px; padding: 0; list-style: none; }
.needs li { background: var(--white); border: 1px solid var(--line); border-radius: 12px; padding: 10px 12px; font-size: 0.9rem; line-height: 1.3; }
.needs b { display: block; font-family: var(--display); font-weight: 600; font-size: 1.15rem; }
.checklist { list-style: none; margin: 0 0 14px; padding: 0; }
.check {
  display: flex; gap: 12px; align-items: flex-start; background: var(--white); border: 1px solid var(--line);
  border-radius: 16px; padding: 12px 14px; margin-bottom: 8px;
}
.check.is-done { background: #F4FBF7; border-color: var(--mint); }
.check.is-over { border-color: var(--tomato-text); }
.tick {
  flex: none; width: 44px; height: 44px; border-radius: 50%; border: 3px solid var(--navy); background: var(--white);
  cursor: pointer; display: flex; align-items: center; justify-content: center; padding: 0;
  -webkit-tap-highlight-color: transparent;
}
.tick svg { width: 24px; height: 24px; fill: none; stroke: transparent; stroke-width: 3.5; stroke-linecap: round; stroke-linejoin: round; }
.tick[aria-pressed="true"] { background: var(--mint-deep); border-color: var(--mint-deep); }
.tick[aria-pressed="true"] svg { stroke: var(--white); }
.tick-static { cursor: default; border-style: dashed; border-color: var(--line-strong); }
.check-body { min-width: 0; flex: 1; }
.check-title { display: block; font-weight: 800; }
.check.is-done .check-title { text-decoration: line-through; text-decoration-thickness: 2px; color: var(--mute); }
.check-desc { display: block; color: var(--mute); font-size: 0.9rem; margin-top: 2px; }
.check-due { display: inline-block; font-size: 0.8rem; font-weight: 800; margin-top: 6px; padding: 3px 8px; border-radius: 999px; background: var(--paper); border: 1px solid var(--line); }
.check.is-over .check-due { background: var(--tomato-text); border-color: var(--tomato-text); color: var(--white); }
.check-actions { display: flex; flex-wrap: wrap; gap: 4px 14px; margin-top: 4px; }
.check-actions .link-btn { min-height: 36px; padding: 2px 0; font-size: 0.9rem; }
.months { display: grid; grid-template-columns: repeat(5, 1fr); gap: 6px; margin-top: 8px; }
.months button { min-height: 44px; border-radius: 12px; border: 2px solid var(--line-strong); background: var(--white); font-weight: 800; cursor: pointer; }
.months button[aria-pressed="true"] { background: var(--mint); border-color: var(--mint-deep); }
.links { display: grid; gap: 8px; margin: 0 0 14px; }
.ext::after { content: " \2197"; }

/* ------------------------------------------------------------------ offers */
.offer { padding: 14px 16px; }
.offer-head { display: flex; align-items: baseline; gap: 10px; }
.offer-bank { font-family: var(--display); font-size: 1.25rem; }
.offer-amt { margin-left: auto; font-family: var(--display); font-size: 1.6rem; color: var(--tomato-text); }
.offer-extra { font-size: 0.9rem; font-weight: 800; color: var(--mint-deep); margin: 2px 0 6px; }
.offer-do { margin: 6px 0; }
.offer-meta { color: var(--mute); font-size: 0.88rem; margin: 2px 0; }
.offer-you { display: inline-block; font-size: 0.8rem; font-weight: 800; padding: 4px 9px; border-radius: 999px; margin: 6px 0 4px; background: var(--paper); border: 1px solid var(--line); }
.offer-you.in { background: var(--mint); border-color: var(--mint-deep); }
.offer-you.out { background: #FDE8EC; border-color: var(--candy); }
.offer-links { display: flex; flex-wrap: wrap; gap: 4px 16px; margin-top: 4px; }
.offer-links a { font-weight: 800; font-size: 0.92rem; min-height: 36px; display: inline-flex; align-items: center; }

/* ------------------------------------------------------------------ help */
.how summary { cursor: pointer; list-style: none; display: flex; justify-content: space-between; align-items: center; margin: 0; min-height: 28px; gap: 10px; }
.how summary::-webkit-details-marker { display: none; }
.how summary::after { content: "+"; font-size: 1.5rem; line-height: 1; flex: none; }
.how[open] summary::after { content: "\2212"; }
.how[open] summary { margin-bottom: 10px; }
.how summary.card-title { margin-bottom: 0; }
.qa { border-top: 1px solid var(--line); padding: 10px 0 0; margin-top: 10px; }
.qa:first-child { border-top: 0; margin-top: 0; padding-top: 0; }
.qa summary { cursor: pointer; font-weight: 800; list-style: none; min-height: 32px; display: flex; gap: 8px; }
.qa summary::-webkit-details-marker { display: none; }
.how .qa summary::after { content: none; }
.qa summary::before { content: "\203A"; font-size: 1.3rem; line-height: 1; transition: transform 0.15s; }
.qa[open] summary::before { transform: rotate(90deg); }
.qa p { margin: 6px 0 0 18px; }
.still-stuck { background: var(--butter); border-radius: 14px; padding: 12px 14px; margin-top: 14px; }
.still-stuck h3 { font-size: 1.05rem; margin-bottom: 4px; }
.privacy-line { text-align: center; color: var(--mute); font-size: 0.9rem; margin-top: 4px; }
.made-by { text-align: center; color: var(--mute); font-size: 0.85rem; margin: 18px 0 6px; }
.a2hs-steps h3 { font-family: var(--body); font-weight: 800; font-size: 1rem; margin: 10px 0 4px; }
.a2hs-steps ol { margin: 0 0 8px; padding-left: 1.3em; }
.review p { margin: 0; font-weight: 700; }

/* ------------------------------------------------------------------ tab bar */
.tabbar {
  position: fixed; left: 50%; transform: translateX(-50%); bottom: 0; z-index: 30;
  width: 100%; max-width: 560px; display: grid; grid-template-columns: repeat(4, 1fr);
  background: var(--white); border-top: 1px solid var(--line);
  padding: 6px 8px calc(6px + env(safe-area-inset-bottom));
  box-shadow: 0 -6px 20px rgba(30, 42, 74, 0.06);
}
.tab {
  display: flex; flex-direction: column; align-items: center; gap: 2px; min-height: 52px; justify-content: center;
  text-decoration: none; color: var(--mute); font-weight: 800; font-size: 0.78rem; border-radius: 14px;
  -webkit-tap-highlight-color: transparent;
}
.tab svg { width: 26px; height: 26px; fill: none; stroke: currentColor; stroke-width: 2.2; stroke-linecap: round; stroke-linejoin: round; }
.tab[aria-current="page"] { color: var(--navy); background: var(--butter); }

/* ------------------------------------------------------------------ sheets */
.sheet {
  width: calc(100% - 24px); max-width: 520px; border: 0; border-radius: 24px; padding: 22px 18px 18px;
  color: var(--navy); background: var(--white); box-shadow: 0 20px 60px rgba(30, 42, 74, 0.35);
  max-height: calc(100vh - 40px); max-height: calc(100dvh - 24px); overflow-y: auto;   /* dvh: the visible screen on iPhone */
}
.sheet::backdrop { background: rgba(30, 42, 74, 0.5); }
.sheet[open]:not([data-modal]) { position: fixed; top: 50%; left: 50%; transform: translate(-50%, -50%); z-index: 45; }
.sheet-title { font-size: 1.4rem; margin-bottom: 10px; }
/* iPhone Home Screen guide (Safari's own buttons, drawn here: no screenshots of other apps). Compact, so it fits a
   small iPhone without scrolling. */
.sheet-ios { padding: 18px 16px 0; }
/* ways to close: a close button that stays at the top right while you scroll, "Got it" pinned to the bottom, and a tap
   on the dimmed area outside (app.js) */
.sheet-x { position: sticky; top: 0; float: right; margin: -8px -6px 0 8px; width: 44px; height: 44px; border: 0; border-radius: 50%;
  background: var(--paper); color: var(--navy); font-size: 1.7rem; line-height: 1; cursor: pointer; z-index: 2;
  box-shadow: 0 1px 4px rgba(30, 42, 74, 0.18); }
.sheet-foot { position: sticky; bottom: 0; background: var(--white); margin: 0 -16px; padding: 10px 16px 14px;
  box-shadow: 0 -8px 16px -8px rgba(30, 42, 74, 0.18); }
.sheet-ios .sheet-title { font-size: 1.2rem; margin-bottom: 4px; }
.ios-why { margin: 0 0 4px; font-size: 0.95rem; }
.ios-steps { list-style: none; margin: 10px 0 4px; padding: 0; display: grid; gap: 12px; }
.ios-steps > li { display: grid; grid-template-columns: 28px 1fr; gap: 8px; align-items: start; }
.ios-n { width: 26px; height: 26px; border-radius: 50%; background: var(--navy); color: var(--sun); font: 700 0.9rem var(--display);
  display: grid; place-items: center; }
.ios-say { font-weight: 800; margin: 2px 0 6px; font-size: 0.98rem; line-height: 1.3; }
.ios-step .small { margin: 4px 0 0; }
.ios-bar { display: flex; align-items: center; gap: 8px; background: #F2F2F7; border-radius: 14px; padding: 7px 8px;
  border: 1px solid var(--line); }
.ios-pill { display: grid; place-items: center; background: var(--white); border-radius: 999px; height: 34px;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.12); }
.ios-round { width: 34px; flex: none; }
.ios-addr { flex: 1; min-width: 0; color: #1C1C1E; font-size: 0.85rem; overflow: hidden; white-space: nowrap; text-overflow: ellipsis;
  padding: 0 10px; }
.ios-ico { width: 22px; height: 22px; fill: none; stroke: #0A6CFF; stroke-width: 1.9; stroke-linecap: round; stroke-linejoin: round; }
.ios-dark { stroke: #1C1C1E; fill: #1C1C1E; }
.ios-inline { width: 18px; height: 18px; vertical-align: -3px; }
.ios-ring { display: grid; place-items: center; width: 40px; height: 40px; flex: none; border-radius: 50%; background: var(--white);
  border: 3px solid var(--tomato); }
.ios-menu { background: #F2F2F7; border-radius: 12px; overflow: hidden; border: 1px solid var(--line); }
.ios-row { display: flex; justify-content: space-between; align-items: center; padding: 7px 12px; background: var(--white);
  color: #1C1C1E; font-size: 0.92rem; border-bottom: 1px solid #E5E5EA; }
.ios-row:last-child { border-bottom: 0; }
.ios-row .ios-ico { width: 19px; height: 19px; }
.ios-row .ios-dark { fill: none; }
.ios-hit { outline: 3px solid var(--tomato); outline-offset: -3px; border-radius: 10px; font-weight: 700; }
.ios-home { display: inline-flex; align-items: center; gap: 10px; background: linear-gradient(160deg, #2D3C63, #151E36);
  padding: 8px 14px 8px 8px; border-radius: 14px; }
.ios-home img { width: 44px; height: 44px; border-radius: 11px; }
.ios-home span { color: var(--white); font-size: 0.85rem; font-weight: 700; }

/* ------------------------------------------------------------------ the cheer */
.party {
  position: fixed; inset: 0; z-index: 50;
  display: flex; align-items: center; justify-content: center; padding: 24px;
  background: rgba(30, 42, 74, 0.55);
}
.party-card {
  position: relative; z-index: 2; width: 100%; max-width: 360px;
  background: var(--white); border-radius: 24px; padding: 26px 22px 20px; text-align: center;
  border-top: 10px solid var(--sun);
  box-shadow: 0 20px 50px rgba(30, 42, 74, 0.35);
}
.party-big { font-family: var(--display); font-size: 3.2rem; line-height: 1; color: var(--tomato); margin: 0 0 8px; }
.party-title { font-size: 1.5rem; margin-bottom: 8px; }
.party-card .btn { margin-top: 8px; }
.confetti { position: absolute; inset: 0; overflow: hidden; pointer-events: none; z-index: 1; }
.confetti i { position: absolute; top: -20px; width: 10px; height: 16px; border-radius: 3px; background: var(--sun); opacity: 0; }
.confetti i:nth-child(3n) { background: var(--tomato); }
.confetti i:nth-child(3n+1) { background: var(--mint); width: 12px; height: 12px; border-radius: 50%; }
.confetti i:nth-child(4n) { background: var(--candy); }
.confetti i:nth-child(1) { left: 4%; }  .confetti i:nth-child(2) { left: 9%; }  .confetti i:nth-child(3) { left: 15%; }
.confetti i:nth-child(4) { left: 21%; } .confetti i:nth-child(5) { left: 26%; } .confetti i:nth-child(6) { left: 31%; }
.confetti i:nth-child(7) { left: 37%; } .confetti i:nth-child(8) { left: 42%; } .confetti i:nth-child(9) { left: 47%; }
.confetti i:nth-child(10) { left: 52%; } .confetti i:nth-child(11) { left: 57%; } .confetti i:nth-child(12) { left: 62%; }
.confetti i:nth-child(13) { left: 67%; } .confetti i:nth-child(14) { left: 72%; } .confetti i:nth-child(15) { left: 77%; }
.confetti i:nth-child(16) { left: 82%; } .confetti i:nth-child(17) { left: 87%; } .confetti i:nth-child(18) { left: 91%; }
.confetti i:nth-child(19) { left: 95%; } .confetti i:nth-child(20) { left: 98%; }

/* ------------------------------------------------------------------ toast */
.toast {
  position: fixed; left: 50%; transform: translateX(-50%); z-index: 40;
  bottom: calc(80px + env(safe-area-inset-bottom));
  width: calc(100% - 32px); max-width: 528px;
  display: flex; align-items: center; gap: 12px; justify-content: space-between;
  background: var(--navy); color: var(--paper);
  border-radius: 14px; padding: 12px 14px; font-weight: 700;
  box-shadow: 0 10px 30px rgba(30, 42, 74, 0.3);
}
.toast.toast-top { bottom: auto; top: calc(64px + env(safe-area-inset-top)); }
.toast-btn { flex: none; background: var(--sun); color: var(--navy); border: 0; border-radius: 999px; min-height: 40px; padding: 0 14px; font-weight: 800; cursor: pointer; }

@media (max-width: 360px) {
  .welcome-total, .reveal-total { font-size: 3.3rem; }
  .dash-big { font-size: 2.6rem; }
}
@media (min-width: 600px) {
  .main { padding-left: 20px; padding-right: 20px; }
}

/* ------------------------------------------------------------------ motion (only for people who haven't asked for less) */
@media (prefers-reduced-motion: no-preference) {
  .btn, .chip, .opt, .tick, .seg button, .months button { transition: background-color 0.15s ease, border-color 0.15s ease, transform 0.1s ease; }
  .btn:active, .tick:active, .opt:active { transform: scale(0.97); }
  .dash-bar span, .quiz-bar span, .mini-bar span { transition: width 0.6s ease; }
  .tick.pop { animation: pop 0.35s ease; }
  .party-card { animation: rise 0.4s cubic-bezier(0.3, 1.5, 0.5, 1); }
  .reveal-list li { animation: rise 0.45s ease both; }
  .reveal-list li:nth-child(2) { animation-delay: 0.08s; } .reveal-list li:nth-child(3) { animation-delay: 0.16s; }
  .reveal-list li:nth-child(4) { animation-delay: 0.24s; } .reveal-list li:nth-child(5) { animation-delay: 0.32s; }
  .reveal-list li:nth-child(6) { animation-delay: 0.4s; } .reveal-list li:nth-child(7) { animation-delay: 0.48s; }
  .reveal-list li:nth-child(n+8) { animation-delay: 0.56s; }
  .confetti i { animation: fall 2.6s ease-in forwards; }
  .confetti i:nth-child(2n) { animation-duration: 3.1s; animation-delay: 0.15s; }
  .confetti i:nth-child(3n) { animation-duration: 2.3s; animation-delay: 0.3s; }
  .confetti i:nth-child(5n) { animation-delay: 0.45s; }
  .confetti i:nth-child(7n) { animation-duration: 3.4s; }
  .is-big .confetti i { animation-iteration-count: 2; }
}
@keyframes pop {
  0% { transform: scale(1); }
  40% { transform: scale(1.2) rotate(-6deg); }
  100% { transform: scale(1); }
}
@keyframes rise {
  0% { transform: translateY(24px) scale(0.96); opacity: 0; }
  100% { transform: none; opacity: 1; }
}
@keyframes fall {
  0% { transform: translateY(0) rotate(0); opacity: 1; }
  100% { transform: translateY(105vh) rotate(540deg); opacity: 1; }
}
@media (prefers-reduced-motion: reduce) {
  .confetti { display: none; }
}
@media print {
  .toast, .topbar, .tabbar, .btn, .btn-row, .back, .party, .review { display: none !important; }
  .main { padding: 0; }
  /* CR-053: when the plan to print exists, print only it, on one A4 page */
  body:has(#print-plan) > *:not(#print-plan) { display: none !important; }
  #print-plan { display: block !important; }
}
@page { size: A4; margin: 12mm; }
#print-plan { display: none; font: 9.5pt/1.35 system-ui, -apple-system, "Segoe UI", Arial, sans-serif; color: #000; background: #fff; }
#print-plan h1 { font-size: 16pt; margin: 0 0 2mm; }
#print-plan h2 { font-size: 11pt; margin: 4mm 0 1mm; }
#print-plan .pp-sub, #print-plan .pp-foot { margin: 0 0 3mm; font-size: 8.5pt; }
#print-plan .pp-foot { margin-top: 4mm; }
#print-plan table { width: 100%; border-collapse: collapse; }
#print-plan th, #print-plan td { border-bottom: 0.3mm solid #999; padding: 1.2mm 1.5mm; text-align: left; vertical-align: top; }
#print-plan th { font-size: 8.5pt; }
#print-plan td:last-child, #print-plan th:last-child { text-align: right; white-space: nowrap; }
#print-plan .pp-done td { color: #555; }

/* 15 Nov: reviews in the unlock card, and "Share my number" under the plan-is-ready total */
.lock-reviews { margin: 12px 0 4px; }
.reveal-share { display: block; margin: 8px auto 0; font-weight: 800; }
/* CR-053: the switch-completed date on a started switch */
.switch-date { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; margin-top: 8px; }
.switch-date label { flex: 1 1 100%; font-size: .95rem; }
.switch-date .input { flex: 1 1 160px; min-height: 44px; }
.dash-people { list-style: none; margin: 10px 0 0; padding: 0; display: grid; gap: 4px; font-size: .95rem; }
.plan-takeaways { margin: 4px 0 14px; }
/* CR-053: the cancel-rights tick box before paying */
.consent { display: flex; gap: 10px; align-items: flex-start; margin: 12px 0; font-weight: 700; line-height: 1.35; cursor: pointer; }
.consent input { width: 24px; height: 24px; flex: 0 0 24px; margin: 2px 0 0; accent-color: var(--ink, #1d1d1b); }
#stripe-pay[disabled] { opacity: .55; cursor: not-allowed; }

/* CR-053 Phase 2: where the money needs to be, and email reminders */
.flow-row { display: flex; flex-wrap: wrap; align-items: end; gap: 8px 14px; margin-bottom: 10px; }
.flow-row .label { flex: 1 1 100%; margin: 0; }
.flow-money { display: flex; align-items: center; gap: 6px; font-weight: 800; font-size: 1.15rem; }
.flow-input { width: 9rem; }
.flow-sum { font-weight: 700; margin: 8px 0; }
.flow-sum.is-over { color: var(--tomato-text); }
.flow .warn { margin: 8px 0; }
.flow-details { margin-top: 10px; }
.flow-details summary { cursor: pointer; font-weight: 800; min-height: 44px; display: flex; align-items: center; }
.flow-weeks { list-style: none; padding: 0; margin: 6px 0 0; }
.flow-week { border-top: 1px solid var(--line); padding: 10px 0; }
.flow-week.is-over .flow-week-head { color: var(--tomato-text); }
.flow-week-head { display: block; font-weight: 800; margin-bottom: 4px; }
.flow-lines { margin: 0; padding-left: 18px; }
.flow-lines li { margin: 4px 0; }
.flow-lines li.is-salary { color: var(--mute); }
.flow-lines li.is-late strong { color: var(--tomato-text); }
.alerts-form .label { margin-top: 10px; }
.alerts-form .btn { margin-top: 12px; width: 100%; }
.alerts .fine { text-align: left; }
