/* Hallmark · shape: poster hero, then a working tour · genre: playful · theme: custom (brand pack 1.3) · job: try · idea: "a money app for ordinary pay, shown doing its job" · vibe: "bold, friendly, sky blue, gold, plain-spoken"
 * paper: oklch(100% 0 0) with sky wash oklch(93.5% 0.03 245) · accent: oklch(70% 0.15 252) · display: Arial Black · body: Arial · hero: the full logo with its tagline set big beside a phone, with three app moments pinned around it · nav: wordmark left, two links and one pill · footer: tagline lockup over three links · imagery: the product, drawn from the app's own screens with made-up figures · signature: Left to spend, the app's one number, set big on a phone screen in the hero
 * surface: absolute · axes: white/heavy-sans/electric-blue · posture: poster · contrast: pass · fold: pass · v2.0.0 */
/* Hallmark · pre-emit critique: P4 H4 E4 S4 R4 V4 · weakest: E, no photographs or real testers yet; the app's own screens carry the page and the reviews band is left out until real quotes exist */
/* Hallmark · waive 7b · --color-ink #000000 and --color-paper #FFFFFF are Brand Guidelines 1.3 § 4 Ink and White · the brand asks for black text and outlines on light surfaces; tinting them would break the brand */
/* Hallmark · waive 12 · overshoot easing only on presses of buttons, keypad keys, guide cards and the chart bars · Felix asked for bouncy buttons and cards to make the landing page more fun, so the spring is the point here */
@import url("./tokens.css");
@import url("./base.css");

/* Scroll-in: hidden only once reveal.js has run (it skips Reduce Motion), so the page reads without scripts */
.js [data-reveal] { opacity: 0; transform: translateY(28px); transition: opacity var(--dur-reveal) var(--ease-out), transform var(--dur-reveal) var(--ease-out); }
.js [data-reveal].is-in { opacity: 1; transform: none; }
.js [data-delay="1"] { transition-delay: 90ms; }
.js [data-delay="2"] { transition-delay: 180ms; }
.js [data-delay="3"] { transition-delay: 270ms; }

/* Charts grow when they scroll in (only with the script; Reduce Motion skips the script) */
.js .months span { transform: scaleY(0); transform-origin: bottom; transition: transform 700ms var(--ease-spring); }
.js .why-row.is-in .months span { transform: none; }
.js .why-row.is-in .months .m2 { transition-delay: 80ms; } .js .why-row.is-in .months .m3 { transition-delay: 160ms; } .js .why-row.is-in .months .m4 { transition-delay: 240ms; } .js .why-row.is-in .months .m5 { transition-delay: 320ms; } .js .why-row.is-in .months .m6 { transition-delay: 400ms; }
.js .stage .bar span { transform: scaleX(0); transform-origin: left; transition: transform 600ms var(--ease-out) 500ms; }
.js .stage.is-in .bar span { transform: none; }

/* Nav */
.nav { position: sticky; top: 0; z-index: var(--z-sticky-nav); background: color-mix(in oklab, var(--color-paper-2) 92%, transparent); backdrop-filter: blur(8px); }
.nav .container { display: flex; align-items: center; gap: var(--space-lg); min-height: 72px; }
.nav-logo { display: flex; align-items: center; margin-right: auto; }
.nav-logo img { height: 44px; width: auto; }
.nav-links { display: flex; gap: var(--space-lg); }
.nav-links a { font-size: var(--text-sm); font-weight: 700; text-decoration: none; padding: var(--space-xs) 0; }
.nav-links a:hover { text-decoration: underline; }

/* Buttons: brand roles (primary blue with black text, secondary thin edge) */
.btn { will-change: transform; display: inline-flex; align-items: center; justify-content: center; min-height: 48px; padding: 0 var(--space-lg); border-radius: var(--radius-pill); font-weight: 700; font-size: var(--text-md); text-decoration: none; cursor: pointer; transition: transform var(--dur-short) var(--ease-spring), background-color var(--dur-micro) var(--ease-out); }
.btn:hover { transform: translateY(-2px); }
.btn:disabled, .keypad button:disabled { opacity: 0.5; cursor: not-allowed; transform: none; }
.btn-primary { background: var(--color-accent); color: var(--color-accent-ink); border: 0; }
.btn-primary:hover { background: var(--color-accent-pressed); }
.btn-secondary { background: var(--color-paper); color: var(--color-ink); border: 1px solid var(--color-rule); }
.btn-secondary:hover { border-color: var(--color-ink); }
.btn:active { transform: scale(0.94); transition-duration: var(--dur-micro); }
.btn:focus-visible, .nav-links a:focus-visible, .guide-link:focus-visible, .footer a:focus-visible { outline: 3px solid var(--color-focus); outline-offset: 3px; transition: none; }
.btn-small { min-height: 44px; font-size: var(--text-sm); padding: 0 var(--space-md); }

/* Hero */
.hero { background: var(--color-paper-2); padding-block: var(--space-xl) var(--space-2xl); }
.hero .container { display: grid; grid-template-columns: minmax(0, 7fr) minmax(0, 5fr); gap: var(--gap-columns); align-items: center; }
.hero-logo img { width: min(560px, 88%); height: auto; }
.hero p { font-size: var(--text-lead); margin-top: var(--space-lg); max-width: 30ch; }
.actions { display: flex; flex-wrap: wrap; gap: var(--space-sm); margin-top: var(--space-xl); }
.stage { position: relative; min-height: 520px; display: grid; place-items: center; }
.phone { position: relative; z-index: var(--z-raised); width: min(280px, 100%); background: var(--color-paper); border: var(--rule-outline) solid var(--color-ink); border-radius: 36px; padding: var(--space-2xl) var(--space-md) var(--space-lg); display: grid; gap: var(--space-sm); }
.phone .small { font-size: var(--text-xs); color: var(--color-muted); }
.phone .big { font-family: var(--font-display); font-size: 2.4rem; line-height: 1; letter-spacing: var(--tracking-display); }
.bar { display: flex; height: 14px; border-radius: var(--radius-pill); overflow: hidden; border: 1px solid var(--color-ink); }
.bar span:nth-child(1) { flex: 1390; background: var(--color-bills); }
.bar span:nth-child(2) { flex: 300; background: var(--color-accent); }
.bar span:nth-child(3) { flex: 287.5; background: var(--color-spent); }
.bar span:nth-child(4) { flex: 1222.5; background: color-mix(in oklab, var(--color-spent) 30%, var(--color-paper)); }
.rows { display: grid; gap: var(--space-2xs); font-size: var(--text-sm); }
.rows div { display: flex; justify-content: space-between; gap: var(--space-sm); }
.chip { position: absolute; z-index: var(--z-raised); background: var(--color-paper); border: var(--rule-outline) solid var(--color-ink); border-radius: var(--radius-pill); padding: var(--space-xs) var(--space-md); font-size: var(--text-sm); font-weight: 700; white-space: nowrap; }
.chip { --tilt: 0deg; transform: rotate(var(--tilt)); animation: float 6s var(--ease-in-out) infinite; }
@keyframes float { 50% { transform: translateY(-8px) rotate(var(--tilt)); } }
.chip-a { --tilt: -5deg; top: 6%; left: -4%; background: var(--color-gold); }
.chip-b { --tilt: 4deg; animation-delay: -2s; top: 13%; right: -12%; background: var(--color-mint); }
.chip-c { --tilt: -3deg; animation-delay: -4s; bottom: 10%; left: -8%; background: var(--color-paper-3); }

/* Ticker */
.ticker { background: var(--color-ink); color: var(--color-on-ink); overflow: hidden; padding-block: var(--space-md); }
.ticker-track { display: flex; width: max-content; animation: slide 38s linear infinite; }
.ticker-track span { font-family: var(--font-display); font-size: var(--text-xl); padding-inline: var(--space-lg); display: flex; align-items: center; gap: var(--space-lg); white-space: nowrap; }
.ticker-track span::after { content: ""; width: 18px; height: 10px; background: var(--color-gold); border: 2px solid var(--color-gold-shade); border-radius: 2px; }
.ticker:hover .ticker-track, .ticker:focus-within .ticker-track { animation-play-state: paused; }
@keyframes slide { to { transform: translateX(-50%); } }
@media (prefers-reduced-motion: reduce) { .ticker-track, .chip, .pop { animation: none; } }

/* Sections */
.section { padding-block: var(--space-section); }
.section h2 { font-size: var(--text-section); line-height: 1; letter-spacing: var(--tracking-display); max-width: 16ch; }
.section-lead { font-size: var(--text-lead); margin-top: var(--space-md); max-width: 44ch; }

.keypad { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: var(--space-2xs); }
.keypad button { min-height: 44px; background: var(--color-paper); color: var(--color-ink); border: 1px solid var(--color-rule); border-radius: 10px; font-weight: 700; cursor: pointer; touch-action: manipulation; transition: transform var(--dur-micro) var(--ease-spring), background-color var(--dur-micro) var(--ease-out); }
.keypad button:hover { background: var(--color-paper-2); }
.keypad button:active { transform: scale(0.9); }
.keypad button:focus-visible, .try-reset:focus-visible { outline: 3px solid var(--color-focus); outline-offset: 2px; transition: none; }
.try-row { display: flex; align-items: center; justify-content: center; gap: var(--space-md); }
.try-row .btn { min-width: 120px; }
.try-reset { min-height: 44px; background: none; border: 0; padding: 0 var(--space-xs); color: var(--color-ink); font-weight: 700; text-decoration: underline; cursor: pointer; }
.try-left { text-align: center; font-size: var(--text-sm); min-height: 1.6em; }
.pop { animation: pop 420ms var(--ease-spring); }
@keyframes pop { 40% { transform: scale(1.08); } }
.amount { font-family: var(--font-display); font-size: var(--text-2xl); text-align: center; }
.months { display: flex; align-items: flex-end; gap: var(--space-xs); height: 150px; border-bottom: 2px solid var(--color-ink); padding-inline: var(--space-2xs); }
.months span { flex: 1; background: var(--color-mint); border: 1px solid var(--color-ink); border-bottom: 0; border-radius: 8px 8px 0 0; }
.months .m1 { height: 40%; } .months .m2 { height: 55%; } .months .m3 { height: 20%; } .months .m4 { height: 62%; } .months .m5 { height: 70%; } .months .m6 { height: 84%; }
.months span.down { background: var(--color-down); }
.months-labels { display: flex; gap: var(--space-xs); font-size: var(--text-xs); color: var(--color-muted); padding-inline: var(--space-2xs); }
.months-labels span { flex: 1; text-align: center; }

/* Why it helps: three rows that swap sides, each with a tilted app moment on a colour block */
.why h2 { max-width: 18ch; }
.why-row { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: var(--gap-columns); align-items: center; margin-top: var(--space-2xl); }
.why-row-flip .why-text { order: 2; }
.why-text h3 { font-size: var(--text-2xl); line-height: 1.05; letter-spacing: var(--tracking-display); }
.why-text p { font-size: var(--text-lead); margin-top: var(--space-sm); max-width: 45ch; }
.why-art { display: grid; place-items: center; min-height: 260px; border: var(--rule-outline) solid var(--color-ink); border-radius: var(--radius-card); padding: var(--space-xl) var(--space-lg); }
.why-art-a { background: var(--color-paper-3); }
.why-art-b { background: var(--color-gold); }
.why-art-c, .art-mint { background: color-mix(in oklab, var(--color-mint) 55%, var(--color-paper)); }
.art-gold { background: var(--color-gold); }
.art-sky { background: var(--color-paper-2); }
.art-lavender { background: var(--color-paper-3); }
.habits { padding-top: 0; }
.todo-save .todo-head { border-bottom-color: var(--color-accent); }
.todo-save .tick { border-color: var(--color-accent); }
.todo-save .todo-item[aria-pressed="true"] .tick { background: var(--color-accent); }
.todo-save .goal-pill { margin-top: var(--space-sm); }
.safe { justify-items: start; }
.safe .small { color: var(--color-muted); }
.safe .big { font-family: var(--font-display); font-size: 2.6rem; line-height: 1; letter-spacing: var(--tracking-display); }
.try { gap: var(--space-sm); }
.chart { padding-block: var(--space-lg); }
.mini { text-align: left; width: min(100%, 380px); background: var(--color-paper); border: var(--rule-outline) solid var(--color-ink); border-radius: 20px; padding: var(--space-md) var(--space-lg); display: grid; gap: var(--space-xs); font-size: var(--text-sm); }
.todo { gap: 0; padding-block: var(--space-sm); }
.todo-head { display: flex; justify-content: space-between; align-items: baseline; gap: var(--space-md); padding-bottom: var(--space-xs); border-bottom: 2px solid var(--color-bills); }
.todo-head span { color: var(--color-muted); font-size: var(--text-xs); }
.todo-item { display: grid; grid-template-columns: auto minmax(0, 1fr) auto; align-items: center; gap: var(--space-sm); width: 100%; min-height: 44px; padding: 0; background: none; border: 0; border-bottom: 1px solid var(--color-rule); color: var(--color-ink); font-size: var(--text-sm); text-align: left; cursor: pointer; touch-action: manipulation; }
.todo-item:last-child { border-bottom: 0; }
.todo-item:focus-visible { outline: 3px solid var(--color-focus); outline-offset: 2px; transition: none; }
.tick { position: relative; width: 22px; height: 22px; border: 2px solid var(--color-bills); border-radius: 6px; transition: transform var(--dur-short) var(--ease-spring), background-color var(--dur-micro) var(--ease-out); }
.tick::after { content: ""; position: absolute; left: 6px; top: 2px; width: 6px; height: 11px; border: solid var(--color-paper); border-width: 0 2px 2px 0; transform: rotate(45deg) scale(0); transition: transform var(--dur-short) var(--ease-spring); }
.todo-item[aria-pressed="true"] .tick { background: var(--color-bills); }
.todo-item[aria-pressed="true"] .tick::after { transform: rotate(45deg) scale(1); }
.todo-item[aria-pressed="true"] span:not(.tick) { color: var(--color-muted); text-decoration: line-through; }
.todo-item:active .tick { transform: scale(0.85); }
.leaks { gap: 0; padding-block: var(--space-xs); }
.leaks div { display: flex; justify-content: space-between; gap: var(--space-md); padding-block: var(--space-sm); }
.leaks div + div { border-top: 1px solid var(--color-rule); }
.leaks b { text-align: right; white-space: nowrap; }
.goal { }
.goal { gap: var(--space-sm); padding-block: var(--space-md); }
.goal .todo-head { border-bottom-color: var(--color-mint); }
.aside { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: var(--space-2xs) var(--space-sm); align-items: center; }
.aside-name { font-weight: 700; }
.aside .goal-bar { grid-column: 1 / -1; }
.aside small { grid-column: 1 / -1; color: var(--color-muted); font-size: var(--text-xs); }
.g1 { --fill: 33.3%; } .g2 { --fill: 75%; } .g3 { --fill: 33.3%; }
.goal-bar { display: block; height: 12px; border: 1px solid var(--color-ink); border-radius: var(--radius-pill); overflow: hidden; background: var(--color-paper); }
.goal-bar span { display: block; height: 100%; width: var(--fill, 33.3%); background: var(--color-accent); border-right: 1px solid var(--color-ink); transform-origin: left; }
.goal-pill { justify-self: start; background: var(--color-gold); border: 1px solid var(--color-ink); border-radius: var(--radius-pill); padding: var(--space-2xs) var(--space-sm); font-weight: 700; }
.js .why-row .goal-bar span { transform: scaleX(0); transition: transform 800ms var(--ease-out) 300ms; }
.js .why-row.is-in .goal-bar span { transform: none; }

/* Card tilts: each card its own angle, alternating down the page, so no two in view lean the same way */
.mini.todo { transform: rotate(-3deg); }
.mini.leaks { transform: rotate(2.5deg); }
.mini.goal { transform: rotate(-1.5deg); }
.mini.todo-save { transform: rotate(3deg); }
.mini.safe { transform: rotate(-2deg); }
.mini.try { transform: rotate(1.5deg); }
.mini.chart { transform: rotate(-2.5deg); }

/* Privacy band */
.privacy { background: var(--color-gold); }
.privacy .container { display: grid; grid-template-columns: minmax(0, 7fr) minmax(0, 5fr); gap: var(--gap-columns); align-items: center; }
.stickers { list-style: none; margin: var(--space-xl) 0 0; padding: 0; display: flex; flex-direction: column; align-items: flex-start; gap: var(--space-md); }
.stickers li { background: var(--color-paper); border: var(--rule-outline) solid var(--color-ink); border-radius: var(--radius-pill); padding: var(--space-sm) var(--space-lg); font-size: var(--text-lead); font-weight: 700; }
.stickers li:nth-child(1) { transform: rotate(-2deg); }
.stickers li:nth-child(2) { transform: rotate(1.5deg); margin-left: var(--space-xl); }
.stickers li:nth-child(3) { transform: rotate(-1deg); margin-left: var(--space-md); }
.pin { justify-self: center; width: min(100%, 320px); justify-items: center; gap: var(--space-md); padding: var(--space-xl) var(--space-lg); rotate: 3deg; }
.pin img { width: 72px; height: auto; }
.pin-title { font-weight: 700; font-size: var(--text-md); }
.pin-dots { display: flex; gap: var(--space-sm); }
.pin-dots span { width: 16px; height: 16px; border: 2px solid var(--color-ink); border-radius: 50%; transition: transform var(--dur-short) var(--ease-spring), background-color var(--dur-micro) var(--ease-out); }
.pin-dots span.on { background: var(--color-ink); transform: scale(1.1); }
.pin-status { border: 1px solid var(--color-rule); border-radius: var(--radius-pill); padding: var(--space-2xs) var(--space-md); font-size: var(--text-sm); font-weight: 700; color: var(--color-muted); }
.pin-status.is-open { background: var(--color-mint); border-color: var(--color-ink); color: var(--color-ink); }

/* Guides */
.guides .container { display: grid; grid-template-columns: minmax(0, 5fr) minmax(0, 7fr); gap: var(--gap-columns); align-items: start; }
.guide-list { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: var(--space-sm); }
.guide-link { display: grid; gap: var(--space-2xs); text-decoration: none; border: 1px solid var(--color-rule); border-radius: 18px; padding: var(--space-md); min-height: 100%; transition: transform var(--dur-short) var(--ease-spring), border-color var(--dur-micro) var(--ease-out), background-color var(--dur-micro) var(--ease-out); }
.guide-list li:nth-child(odd) .guide-link:hover { transform: translateY(-4px) rotate(-1deg); }
.guide-list li:nth-child(even) .guide-link:hover { transform: translateY(-4px) rotate(1deg); }
.guide-link:hover { border-color: var(--color-ink); background: var(--color-paper-2); }
.guide-link:active { transform: scale(0.97); }
.guide-link b { font-size: var(--text-md); }
.guide-link span { font-size: var(--text-sm); color: var(--color-muted); }
.guides .btn { margin-top: var(--space-lg); }

/* Closing */
.closing { background: var(--color-paper-3); text-align: center; overflow: clip; }
.closing .container { position: relative; }
.closing h2 { font-size: clamp(2.75rem, 6vw + 0.5rem, 6rem); max-width: 12ch; margin-inline: auto; }
.closing .actions { justify-content: center; }
.closing-note { margin-top: var(--space-sm); color: var(--color-ink-2); }
.cb1 { --tilt: -4deg; top: 4%; left: 4%; background: var(--color-gold); }
.cb2 { --tilt: 5deg; animation-delay: -1.5s; top: 10%; right: 6%; background: var(--color-mint); }
.cb3 { --tilt: 3deg; animation-delay: -3s; bottom: 34%; left: 2%; background: var(--color-paper-2); }
.cb4 { --tilt: -3deg; animation-delay: -4.5s; bottom: 26%; right: 2%; background: var(--color-paper); }
.closing-logo { display: grid; justify-items: center; margin-bottom: var(--space-xl); }
.logo-anim { width: min(380px, 72%); height: auto; overflow: visible; }
.lg-empty { fill: var(--color-paper); stroke: var(--color-ink); stroke-width: 12; stroke-linejoin: round; }
.lg-fill { fill: var(--color-accent); }
.lg-line { fill: none; stroke: var(--color-ink); stroke-width: 12; stroke-linejoin: round; }
.lg-gold-bar { fill: var(--color-gold); stroke: var(--color-ink); stroke-width: 12; stroke-linejoin: round; }
.lg-gold-shade { fill: var(--color-gold-shade); }
/* Entry animation (Felix, 22 Nov 2026): the blue steps fill from the bottom step up, then the gold bar drops on.
   It ends on the exact logo; without the script or with Reduce Motion the logo simply shows. */
.js .closing-logo .lg-fill { clip-path: inset(0 100% 0 0); transition: clip-path 1200ms var(--ease-in-out) 300ms; }
.js .closing-logo.is-in .lg-fill { clip-path: inset(0 0 0 0); }
.js .closing-logo .lg-gold { opacity: 0; transform: translateY(-320px); transition: transform 700ms var(--ease-spring) 1500ms, opacity 150ms var(--ease-out) 1500ms; }
.js .closing-logo.is-in .lg-gold { opacity: 1; transform: none; }

/* Footer */
.footer { background: var(--color-ink); color: var(--color-on-ink); padding-block: var(--space-xl); }
.footer .container { display: flex; flex-wrap: wrap; gap: var(--space-xl); align-items: end; justify-content: space-between; }
.footer img { width: 240px; height: auto; }
.footer nav { display: flex; flex-wrap: wrap; gap: var(--space-lg); }
.footer a { font-size: var(--text-sm); }
.footer .fine { flex-basis: 100%; font-size: var(--text-xs); color: color-mix(in oklab, var(--color-on-ink) 70%, var(--color-ink)); }

@media (max-width: 60rem) {
  .why-row { grid-template-columns: minmax(0, 1fr); text-align: center; margin-top: var(--space-xl); }
  .why-row-flip .why-text { order: 0; }
  .why-text p { margin-inline: auto; }
  .why-art { width: min(100%, 420px); margin-inline: auto; min-height: 220px; padding: var(--space-lg) var(--space-md); }
  .goal-pill { justify-self: center; }
  .hero .container, .privacy .container, .guides .container { grid-template-columns: minmax(0, 1fr); }
  /* Stacked layouts centre (Felix, 22 Nov 2026): the hero, section heads, the closing and the footer */
  .hero .container > div:first-child, .guides .container > div:first-child, .section h2, .section-lead, .closing .container, .footer .container { text-align: center; }
  .hero-logo img, .hero p, .section h2, .section-lead { margin-inline: auto; }
  .actions { justify-content: center; }
  .privacy .container { justify-items: center; }
  .privacy-text { text-align: center; }
  .stickers { align-items: center; }
  .stickers li:nth-child(n) { margin-left: 0; }
  .callbacks { display: flex; flex-wrap: wrap; justify-content: center; gap: var(--space-sm); margin-bottom: var(--space-lg); }
  .callbacks .chip { position: static; }
  .guide-list { width: min(100%, 40rem); margin-inline: auto; }
  .footer .container { flex-direction: column; align-items: center; }
  .footer nav { justify-content: center; }
  .chip-c { bottom: 0; }
  .stage { min-height: 0; padding-block: var(--space-xl) var(--space-xl); width: min(100%, 420px); margin-inline: auto; }
  .nav-links { display: none; }
}
@media (max-width: 40rem) {
  .guide-list { grid-template-columns: minmax(0, 1fr); }
  .chip-b { right: 0; }
  .chip-c { display: none; }
  .cb3, .cb4 { display: none; }
  .stickers li { font-size: var(--text-sm); padding: var(--space-xs) var(--space-md); }
  .pin { width: min(100%, 260px); padding: var(--space-lg) var(--space-md); }
  .stage { min-height: 0; padding-bottom: 0; }
  .hero { padding-block: var(--space-lg) var(--space-xl); }
  .nav-logo img { height: 36px; }
}

/* Not-found page (404.html): Cloudflare Pages serves it for any missing path, instead of the home page */
.notfound { min-height: 100vh; min-height: 100svh; display: grid; place-items: center; text-align: center; background: var(--color-paper-2); }
.notfound img { margin-inline: auto; }
.notfound h1 { font-size: var(--text-section); line-height: 1; letter-spacing: var(--tracking-display); margin-top: var(--space-lg); }
.notfound p { margin: var(--space-md) auto 0; }
.notfound .actions { justify-content: center; }
