/* Values follow design/system/tokens.json. Liquid Glass: the brief asks for glass, so glass it is. */
:root {
  color-scheme: light dark;
  --bg: #e9f0f8;
  --wash-a: #7db9ff;
  --wash-b: #8febd8;
  --wash-c: #ffc9b0;
  --glass: rgba(255, 255, 255, 0.5);
  --glass-strong: rgba(255, 255, 255, 0.72);
  --rim: rgba(255, 255, 255, 0.9);
  --rim-low: rgba(255, 255, 255, 0.25);
  --thin: rgba(255, 255, 255, 0.62);
  --line: rgba(17, 24, 39, 0.1);
  --control: #7f8a99;
  --ink: #0b0f17;
  --muted: #454c58;
  --primary: #0071e3;
  --primary-hover: #0062c4;
  --primary-ink: #0058b3;
  --primary-soft: rgba(0, 113, 227, 0.14);
  --danger: #991b1b;
  --danger-soft: #fee2e2;
  --success: #166534;
  --success-soft: #dcfce7;
  --warning: #92400e;
  --warning-soft: #fef3c7;
  --shadow: 0 8px 32px rgba(15, 30, 60, 0.12);
  --r-md: 14px;
  --r-lg: 22px;
  --r-xl: 28px;
  --out: cubic-bezier(0.22, 1, 0.36, 1);
  --spring: linear(0, 0.05, 0.18 6%, 0.48 14%, 0.78 24%, 0.95 34%, 1.02 44%, 1.03 52%, 1.01 68%, 1);
  --fs-display: clamp(44px, 5.4vw, 84px);
  --fs-head: clamp(32px, 3.8vw, 56px);
  --fs-title: clamp(20px, 1.7vw, 24px);
}
@media (prefers-color-scheme: dark) {
  :root {
    --bg: #0b0d12;
    --wash-a: #103a86;
    --wash-b: #0c5e5a;
    --wash-c: #4a1e55;
    --glass: rgba(30, 34, 42, 0.5);
    --glass-strong: rgba(24, 27, 34, 0.74);
    --rim: rgba(255, 255, 255, 0.3);
    --rim-low: rgba(255, 255, 255, 0.06);
    --thin: rgba(255, 255, 255, 0.08);
    --line: rgba(255, 255, 255, 0.12);
    --control: #7b8492;
    --ink: #f5f7fa;
    --muted: #b4bbc6;
    --primary-ink: #7cbbff;
    --primary-soft: rgba(10, 132, 255, 0.26);
    --danger: #fca5a5;
    --danger-soft: rgba(239, 68, 68, 0.2);
    --success: #86efac;
    --success-soft: rgba(34, 197, 94, 0.18);
    --warning: #fcd34d;
    --warning-soft: rgba(245, 158, 11, 0.2);
    --shadow: 0 8px 32px rgba(0, 0, 0, 0.4);
  }
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; scroll-padding-top: 96px; }
body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font: 400 16px/1.5 -apple-system, BlinkMacSystemFont, 'SF Pro Text', 'Segoe UI', Roboto, 'Helvetica Neue', sans-serif;
  font-variant-numeric: tabular-nums;
  -webkit-font-smoothing: antialiased;
}
/* The wallpaper the glass bends. It drifts, slowly, so the glass stays alive. */
.wall { position: fixed; inset: -10%; z-index: -1; overflow: hidden; background: var(--bg); }
.wall i { position: absolute; width: 70vmax; height: 70vmax; border-radius: 50%; }
.wall i:nth-child(1) { left: -18%; top: -28%; background: radial-gradient(closest-side, var(--wash-a), transparent); }
.wall i:nth-child(2) { right: -20%; top: 0; background: radial-gradient(closest-side, var(--wash-b), transparent); }
.wall i:nth-child(3) { left: 16%; bottom: -36%; background: radial-gradient(closest-side, var(--wash-c), transparent); }

::selection { background: var(--primary); color: #fff; }
a { color: var(--primary-ink); text-underline-offset: 3px; }
h1, h2, h3, p { margin: 0; }
h1, h2 { font-weight: 700; letter-spacing: -0.025em; line-height: 1.08; text-wrap: balance; }
h3 { font-size: 17px; font-weight: 600; letter-spacing: -0.01em; }
[hidden] { display: none !important; }
:focus-visible { outline: 2px solid var(--primary); outline-offset: 2px; }

/* A pane of glass */
.glass {
  position: relative;
  background: var(--glass);
  -webkit-backdrop-filter: blur(28px) saturate(180%);
  backdrop-filter: blur(28px) saturate(180%);
  box-shadow: var(--shadow), inset 0 1px 0 var(--rim), inset 0 0 0 1px var(--rim-low);
  border-radius: var(--r-xl);
}
.glass.strong { background: var(--glass-strong); }
@media (prefers-contrast: more) {
  .glass, .glass.strong, .card, .thin { background: var(--bg); -webkit-backdrop-filter: none; backdrop-filter: none; }
}
@supports not ((backdrop-filter: blur(1px)) or (-webkit-backdrop-filter: blur(1px))) {
  .glass, .card { background: var(--bg); }
}
.thin { background: var(--thin); box-shadow: inset 0 0 0 1px var(--rim-low); border-radius: var(--r-md); }

/* Shared controls */
.btn {
  display: inline-flex; align-items: center; justify-content: center;
  min-height: 48px; padding: 0 22px; border-radius: 999px;
  border: 0; background: var(--thin); color: var(--ink);
  box-shadow: inset 0 0 0 1px var(--line);
  font: inherit; font-weight: 600; text-decoration: none; cursor: pointer;
  transition: transform 420ms var(--spring), background-color 160ms ease;
}
.btn:hover { background: var(--glass-strong); }
.btn:active:not(:disabled) { transform: scale(0.96); transition-duration: 120ms; }
.btn.primary, .btn.accent { background: var(--primary); color: #fff; box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.35); }
.btn.primary:hover, .btn.accent:hover { background: var(--primary-hover); }
.btn:disabled { background: var(--thin); color: var(--muted); cursor: not-allowed; }

label { display: block; font-weight: 500; font-size: 14px; margin: 16px 0 8px; }
input, select {
  width: 100%; min-height: 48px; padding: 8px 14px; font: inherit; color: var(--ink);
  border: 1px solid color-mix(in srgb, var(--control) 55%, transparent); border-radius: var(--r-md); background: var(--thin);
}
.message { margin-top: 12px; padding: 10px 14px; border-radius: var(--r-md); font-size: 14px; }
.message.error, .message.warn { background: var(--danger-soft); color: var(--danger); }
.message.ok { background: var(--success-soft); color: var(--success); }

.period-switch { position: relative; display: inline-grid; grid-auto-flow: column; grid-auto-columns: 1fr; padding: 4px; border-radius: 999px; background: var(--thin); box-shadow: inset 0 0 0 1px var(--line); }
.period-switch button { position: relative; z-index: 1; border: 0; background: none; font: inherit; font-weight: 600; min-height: 40px; padding: 0 20px; cursor: pointer; color: var(--muted); border-radius: 999px; transition: color 200ms ease; }
.period-switch button[aria-pressed='true'] { color: var(--ink); }
.period-switch::before { content: ''; position: absolute; top: 4px; bottom: 4px; left: 4px; width: calc(50% - 4px); border-radius: 999px; background: var(--glass-strong); box-shadow: 0 2px 8px rgba(15, 30, 60, 0.14), inset 0 0 0 1px var(--rim); transition: transform 460ms var(--spring); }
.period-switch:has(#yearly[aria-pressed='true'])::before { transform: translateX(100%); }

/* Account and admin */
.muted { color: var(--muted); }
.small { font-size: 14px; }
.wrap { max-width: 1040px; margin: 0 auto; padding: 0 16px; }
.narrow { max-width: 460px; }
.row { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; }
.row.between { justify-content: space-between; }
.actions { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 24px; }
header.top { position: sticky; top: 12px; z-index: 5; padding: 12px 12px 0; }
header.top .wrap { display: flex; align-items: center; justify-content: space-between; min-height: 56px; gap: 12px; max-width: 1016px; padding: 0 8px 0 16px; border-radius: 999px; background: var(--glass); -webkit-backdrop-filter: blur(28px) saturate(180%); backdrop-filter: blur(28px) saturate(180%); box-shadow: var(--shadow), inset 0 1px 0 var(--rim), inset 0 0 0 1px var(--rim-low); }
.brand { display: inline-flex; align-items: center; gap: 8px; font-weight: 600; color: var(--ink); text-decoration: none; }
.brand img { width: 26px; height: 26px; display: block; }
.grid { display: grid; gap: 16px; }
.cols-3 { grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); }
.card { position: relative; background: var(--glass-strong); -webkit-backdrop-filter: blur(28px) saturate(180%); backdrop-filter: blur(28px) saturate(180%); box-shadow: var(--shadow), inset 0 1px 0 var(--rim), inset 0 0 0 1px var(--rim-low); border-radius: var(--r-xl); padding: 28px; }
main > .card { animation: sheet-in 560ms var(--spring) backwards; }
.card h2 { margin-bottom: 8px; font-size: 28px; }
#account-view > h1 { font-size: 32px; }
#account-view .card h2 { font-size: 17px; letter-spacing: -0.01em; }
.card > h3 { margin-bottom: 8px; }
.card.featured { box-shadow: var(--shadow), inset 0 0 0 2px var(--primary); }
.card .btn { margin-top: 12px; }
.card p.small { margin-top: 16px; }
.price { font-size: 28px; font-weight: 700; letter-spacing: -0.02em; margin: 8px 0 0; }
.price .small { font-weight: 400; letter-spacing: 0; }
ul.ticks { padding-left: 20px; margin: 16px 0; }
ul.ticks li { margin-bottom: 6px; }
.table-scroll { overflow-x: auto; }
table { width: 100%; border-collapse: collapse; font-size: 14px; }
th, td { text-align: left; padding: 12px 8px; border-bottom: 1px solid var(--line); white-space: nowrap; } /* taste-skill-ignore: real tables */
th { color: var(--muted); font-weight: 500; font-size: 13px; }
.tabs { display: flex; flex-wrap: wrap; gap: 8px; margin: 0 0 16px; }
section.plain { padding: 32px 0; }
section.plain h2 { font-size: 22px; margin-bottom: 12px; }
section.plain .period-switch { margin-bottom: 16px; }

/* Page */
.page { max-width: 1320px; margin: 0 auto; padding: 0 20px; }
.nav { position: fixed; z-index: 10; top: 12px; left: 50%; translate: -50% 0; display: flex; align-items: center; gap: 4px; padding: 6px; border-radius: 999px; }
.nav.lens { -webkit-backdrop-filter: url(#liquid) blur(14px) saturate(180%); backdrop-filter: url(#liquid) blur(14px) saturate(180%); }
.nav .mark { display: flex; padding: 0 10px 0 6px; }
.nav .mark img { width: 30px; height: 30px; display: block; }
.nav a:not(.mark) { display: flex; align-items: center; min-height: 40px; padding: 0 14px; border-radius: 999px; color: var(--ink); font-size: 15px; font-weight: 500; text-decoration: none; transition: background-color 160ms ease, transform 420ms var(--spring); }
.nav a:not(.mark):hover { background: var(--thin); }
.nav a:not(.mark):active { transform: scale(0.95); }
.nav a.go { background: var(--primary); color: #fff; font-weight: 600; margin-left: 4px; }
.nav a.go:hover { background: var(--primary-hover); }

/* First screen: the cashier, working */
.hero { padding-top: 112px; padding-bottom: 28px; display: grid; gap: 36px; justify-items: center; text-align: center; }
.hero > div:first-child { display: grid; justify-items: center; }
.hero h1 { font-size: var(--fs-display); }
.hero .lede { margin: 18px 0 24px; font-size: clamp(17px, 1.4vw, 20px); max-width: 58ch; color: var(--muted); }
.hero .note { margin-top: 12px; font-size: 14px; color: var(--muted); }
.stage { width: 100%; max-width: 1120px; text-align: left; display: grid; grid-template-columns: 1.45fr 1fr; gap: 12px; padding: 12px; min-height: 520px; border-radius: 34px; }
.till { display: flex; flex-direction: column; gap: 10px; padding: 8px; min-width: 0; }
.caption { font-size: 13px; color: var(--muted); }
.items { flex: 1; display: grid; gap: 8px; grid-template-columns: repeat(3, 1fr); grid-auto-rows: 1fr; }
.items button {
  display: flex; flex-direction: column; justify-content: space-between; gap: 8px; text-align: left;
  border: 0; border-radius: var(--r-lg); background: var(--thin); color: var(--ink);
  box-shadow: inset 0 0 0 1px var(--rim);
  padding: 14px; font: inherit; font-weight: 600; font-size: 15px; cursor: pointer; min-height: 88px;
  transition: transform 420ms var(--spring), background-color 240ms ease, box-shadow 240ms ease;
}
.items button:hover { background: var(--glass-strong); }
.items button:active, .items button[data-auto] { transform: scale(0.96); transition-duration: 120ms; }
.items button[data-count] { background: var(--primary-soft); box-shadow: inset 0 0 0 1px var(--primary); }
.items .foot { display: flex; align-items: center; justify-content: space-between; white-space: nowrap; font-weight: 500; font-size: 14px; }
.items .count { min-width: 24px; height: 24px; padding: 0 5px; border-radius: 12px; background: var(--primary); color: #fff; font-size: 13px; font-weight: 700; text-align: center; line-height: 24px; }
.slip { display: flex; flex-direction: column; gap: 10px; padding: 18px; border-radius: var(--r-xl); min-width: 0; }
.slip .head { display: flex; align-items: center; justify-content: space-between; gap: 8px; flex-wrap: wrap; }
.slip h2 { font-size: 17px; font-weight: 600; letter-spacing: -0.01em; }
.lines { flex: 1; min-height: 0; overflow: auto; list-style: none; margin: 0; padding: 0; font-size: 15px; }
.lines li { display: flex; justify-content: space-between; gap: 12px; padding: 8px 0; border-bottom: 1px solid var(--line); } /* taste-skill-ignore: receipt lines inside an interface fragment */
.lines li.empty { color: var(--muted); border: 0; }
.sum { display: flex; align-items: baseline; justify-content: space-between; font-weight: 600; }
.sum b { font-size: 30px; font-weight: 700; letter-spacing: -0.02em; }
.state { font-size: 14px; display: flex; align-items: center; gap: 8px; min-height: 22px; }
.state i { width: 8px; height: 8px; border-radius: 50%; background: #1e8e3e; flex: none; transition: background-color 300ms ease; }
.state.off i { background: #d97706; }
.net { border: 0; background: var(--thin); box-shadow: inset 0 0 0 1px var(--line); border-radius: 999px; font: inherit; font-size: 13px; font-weight: 600; color: var(--ink); min-height: 36px; padding: 0 12px; cursor: pointer; transition: transform 420ms var(--spring), background-color 200ms ease; }
.net:active { transform: scale(0.96); }
.net[aria-pressed='true'] { background: var(--warning-soft); color: var(--warning); }

/* Sections */
section.block { padding: 72px 0; }
section.block > h2 { font-size: var(--fs-head); margin-bottom: 28px; max-width: 20ch; }
.cells { display: grid; grid-template-columns: repeat(3, 1fr); gap: 12px; }
.cell { display: flex; flex-direction: column; justify-content: space-between; gap: 20px; padding: 24px; min-height: 380px; overflow: hidden; transition: transform 460ms var(--spring); }
.cell:nth-child(even) { flex-direction: column-reverse; }
.cell:hover { transform: translateY(-4px); }
.cell p { margin-top: 6px; color: var(--muted); font-size: 15px; }
.frag { padding: 14px; font-size: 14px; }
.frag .r { display: flex; justify-content: space-between; gap: 12px; padding: 6px 0; }
.frag .r + .r { box-shadow: inset 0 1px 0 var(--line); }
.frag b { font-weight: 600; }
.chips { display: flex; flex-wrap: wrap; gap: 6px; }
.chip { padding: 6px 12px; border-radius: 999px; font-size: 14px; font-weight: 500; box-shadow: inset 0 0 0 1px var(--line); }
.chip.on { background: var(--primary-soft); color: var(--primary-ink); box-shadow: none; }
.keys { display: grid; grid-template-columns: repeat(3, 1fr); gap: 6px; }
.keys span { display: grid; place-items: center; height: 42px; border-radius: 999px; background: var(--thin); box-shadow: inset 0 0 0 1px var(--line); font-weight: 500; }
.dots { display: flex; justify-content: center; gap: 10px; margin-bottom: 12px; }
.dots i { width: 10px; height: 10px; border-radius: 50%; background: var(--ink); }
.dots i.o { background: var(--line); }
.pill { padding: 2px 10px; border-radius: 999px; font-size: 13px; font-weight: 600; }
.pill.sent { background: var(--success-soft); color: var(--success); }
.pill.wait { background: var(--warning-soft); color: var(--warning); }
.pill.back { background: var(--danger-soft); color: var(--danger); }

/* Output index, live sheet */
.outputs { display: grid; grid-template-columns: 5fr 7fr; gap: 28px; align-items: center; }
.outputs nav { display: grid; gap: 4px; justify-items: start; }
.outputs nav button { border: 0; background: none; font: inherit; font-size: var(--fs-head); font-weight: 700; letter-spacing: -0.025em; line-height: 1.15; color: var(--muted); opacity: 0.55; cursor: pointer; padding: 2px 0; text-align: left; transition: opacity 260ms ease, transform 460ms var(--spring); }
.outputs nav button:hover { opacity: 0.8; }
.outputs nav button[aria-selected='true'] { color: var(--ink); opacity: 1; transform: translateX(8px); }
.outputs .sub { margin-top: 16px; color: var(--muted); max-width: 38ch; }
.sheetbay { position: relative; min-height: 500px; padding: 24px; display: grid; }
.sheet { grid-area: 1 / 1; opacity: 0; visibility: hidden; transform: scale(0.96) translateY(12px); transition: opacity 240ms ease, transform 520ms var(--spring), visibility 0s linear 240ms; }
.sheet.on { opacity: 1; visibility: visible; transform: none; transition-delay: 0s; }
.sheet h3 { margin-bottom: 12px; }
.sheet .big { font-size: 40px; font-weight: 700; letter-spacing: -0.03em; margin: 4px 0 16px; }
.sheet .r { display: flex; justify-content: space-between; gap: 12px; padding: 10px 0; box-shadow: inset 0 -1px 0 var(--line); }
.sheet .r.strong { font-weight: 600; }
.sheet .demo { margin-top: 14px; font-size: 13px; color: var(--muted); }

/* Plans */
.plans-top { display: flex; flex-wrap: wrap; align-items: flex-end; justify-content: space-between; gap: 16px; margin-bottom: 28px; }
.plans-top h2 { font-size: var(--fs-head); }
.plans-top p { margin-top: 8px; color: var(--muted); }
.plans { display: grid; grid-template-columns: repeat(3, 1fr); gap: 12px; align-items: stretch; }
.plan { display: flex; flex-direction: column; gap: 8px; padding: 28px; transition: transform 460ms var(--spring); }
.plan:hover { transform: translateY(-4px); }
.plan h3 { font-size: 20px; }
.plan .price { font-size: clamp(32px, 3.2vw, 46px); margin: 0; line-height: 1.1; }
.plan ul { list-style: none; margin: 12px 0 20px; padding: 0; }
.plan li { padding: 4px 0; }
.plan .btn { margin-top: auto; }
.plan.top { box-shadow: var(--shadow), inset 0 0 0 2px var(--primary); }

/* Install */
.get { display: grid; grid-template-columns: repeat(3, 1fr); gap: 12px; }
.get > div { display: flex; flex-direction: column; gap: 10px; align-items: flex-start; padding: 24px; min-height: 200px; }
.get p { color: var(--muted); }
.get .btn { margin-top: auto; }

/* Questions */
.asks { display: grid; grid-template-columns: 4fr 8fr; gap: 28px; align-items: start; }
.asks > h2 { position: sticky; top: 96px; font-size: var(--fs-head); }
.asks .list { display: grid; gap: 8px; }
.ask { border-radius: var(--r-lg); overflow: hidden; }
.ask button { width: 100%; display: flex; align-items: center; justify-content: space-between; gap: 16px; min-height: 68px; padding: 16px 22px; border: 0; background: none; color: inherit; font: inherit; font-size: 18px; font-weight: 600; text-align: left; cursor: pointer; }
.ask .plus { position: relative; flex: none; width: 16px; height: 16px; transition: transform 460ms var(--spring); }
.ask .plus::before, .ask .plus::after { content: ''; position: absolute; left: 0; top: 7px; width: 16px; height: 2px; border-radius: 2px; background: currentColor; }
.ask .plus::after { transform: rotate(90deg); }
.ask.open .plus { transform: rotate(45deg); }
.ask .more { display: grid; grid-template-rows: 0fr; transition: grid-template-rows 460ms var(--spring); }
.ask.open .more { grid-template-rows: 1fr; }
.ask .more > div { overflow: hidden; min-height: 0; }
.ask .more p { padding: 0 22px 20px; color: var(--muted); max-width: 64ch; }

/* The close */
.close { display: grid; grid-template-columns: 7fr 5fr; gap: 28px; align-items: center; padding: 48px; border-radius: 34px; }
.close h2 { font-size: var(--fs-head); margin-bottom: 12px; }
.close p { color: var(--muted); max-width: 40ch; }
.signup { padding: 24px; }
.signup h3 { margin-bottom: 12px; }
.signup .fake { padding: 13px 14px; border-radius: var(--r-md); background: var(--thin); box-shadow: inset 0 0 0 1px var(--line); margin-bottom: 8px; font-size: 15px; }
.signup small { display: block; font-size: 13px; color: var(--muted); margin-bottom: 4px; }
.signup .btn { width: 100%; margin-top: 8px; }

footer.quiet { display: grid; grid-template-columns: 1fr auto 1fr; gap: 16px; padding: 88px 0 28px; font-size: 14px; }
footer.quiet nav { display: flex; flex-wrap: wrap; gap: 8px 24px; }
footer.quiet a { color: var(--ink); }
footer.quiet span:last-child { text-align: right; }

/* Motion: everything is in place without it, and only hides under .js with motion allowed. */
@media (prefers-reduced-motion: no-preference) {
  .wall i { animation: drift 26s ease-in-out infinite alternate; }
  .wall i:nth-child(2) { animation-duration: 32s; animation-direction: alternate-reverse; }
  .wall i:nth-child(3) { animation-duration: 38s; }

  .js .hero h1 .w { display: inline-block; animation: word-in 900ms var(--spring) backwards; animation-delay: calc(var(--i) * 55ms + 80ms); }
  .js .hero .lede { animation: rise 800ms var(--out) 340ms backwards; }
  .js .hero .btn { animation: rise 800ms var(--spring) 420ms backwards; }
  .js .hero .note { animation: rise 800ms var(--out) 480ms backwards; }
  .js .stage { animation: stage-in 1100ms var(--spring) 160ms backwards; }
  .js .nav { animation: nav-in 900ms var(--spring) backwards; }

  /* The panel settles back as the page scrolls away, locked to the scrollbar. */
  @supports (animation-timeline: scroll()) {
    .js .stage { animation: stage-in 1100ms var(--spring) 160ms backwards, stage-away linear both; animation-timeline: auto, scroll(root); animation-range: normal, 0 90vh; }
  }

  .js .in { opacity: 0; transform: translateY(28px) scale(0.98); transition: opacity 700ms var(--out), transform 900ms var(--spring); transition-delay: calc(var(--i, 0) * 70ms); }
  .js .in.seen { opacity: 1; transform: none; }
  .js .in.seen.cell, .js .in.seen.plan { transition-delay: 0s; }

  .lines li.new { animation: line-in 420ms var(--spring); }
  .state.off i { animation: pulse 1.4s ease-in-out infinite; }
}
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  * { transition-duration: 0ms !important; }
}
@keyframes drift { from { transform: translate3d(-4%, -3%, 0) scale(1); } to { transform: translate3d(7%, 6%, 0) scale(1.12); } }
@keyframes word-in { from { opacity: 0; transform: translateY(0.5em); filter: blur(8px); } to { opacity: 1; transform: none; filter: none; } }
@keyframes rise { from { opacity: 0; transform: translateY(14px); } to { opacity: 1; transform: none; } }
@keyframes stage-in { from { opacity: 0; transform: translateY(32px) scale(0.94); } to { opacity: 1; transform: none; } }
@keyframes stage-away { to { transform: scale(0.95) translateY(-12px); } }
@keyframes nav-in { from { opacity: 0; transform: translateY(-16px) scale(0.92); } to { opacity: 1; transform: none; } }
@keyframes sheet-in { from { opacity: 0; transform: scale(0.95) translateY(16px); } to { opacity: 1; transform: none; } }
@keyframes line-in { from { opacity: 0; transform: translateY(-8px); } to { opacity: 1; transform: none; } }
@keyframes pulse { 50% { opacity: 0.3; } }

/* Tablet */
@media (max-width: 1080px) {
  .hero { padding-top: 96px; }
  .items { grid-template-columns: 1fr 1fr; }
  .stage { min-height: 520px; }
  .cells, .plans, .get { grid-template-columns: 1fr 1fr; }
  .outputs { grid-template-columns: 1fr; }
  .asks { grid-template-columns: 1fr; }
  .asks > h2 { position: static; }
  .close { grid-template-columns: 1fr; padding: 32px; }
}

/* Phone */
@media (max-width: 640px) {
  .page { padding: 0 8px; }
  .nav { width: calc(100% - 16px); justify-content: space-between; }
  .nav a.link { display: none; }
  .hero { padding: 84px 8px 12px; }
  .hero > div:first-child { padding: 0 8px; }
  .hero h1 { font-size: 8.4vw; }
  .stage { grid-template-columns: 1fr; min-height: 0; padding: 8px; border-radius: var(--r-xl); }
  .items button { min-height: 80px; }
  .lines { max-height: 180px; }
  section.block { padding: 48px 8px; }
  .cells, .plans, .get { grid-template-columns: 1fr; }
  .cell { min-height: 0; }
  .cell:nth-child(even) { flex-direction: column; }
  .outputs nav { grid-auto-flow: column; grid-auto-columns: max-content; gap: 16px; overflow-x: auto; scroll-snap-type: x proximity; padding-bottom: 8px; justify-items: start; }
  .outputs nav button { font-size: 24px; scroll-snap-align: start; }
  .outputs nav button[aria-selected='true'] { transform: none; }
  .sheetbay { min-height: 460px; padding: 18px; }
  .ask button { font-size: 17px; min-height: 64px; }
  .close { padding: 24px 18px; }
  footer.quiet { grid-template-columns: 1fr; padding: 48px 16px 24px; }
  footer.quiet span:last-child { text-align: left; }
}
