/* Stands carried over from the redesign: Quick Edit, key editor, Time Saver keyboard, time figure.
   Generated from main.css; the tokens live on .ft so they never touch the base styles. */
.ft {
  --bg: #ffffff;
  --surface: #f1f2f4;
  --surface-2: #e6e8eb;
  --ink: #141619;
  --muted: #59606b;
  --accent: #0a6cdf;
  --accent-hover: #0757b8;
  --accent-ink: #ffffff;
  --dark: #1b1c1f;
  --dark-2: #26282c;
  --dark-3: #34373c;
  --dark-ink: #f3f4f6;
  --dark-muted: #a9aeb6;

  --font: -apple-system, BlinkMacSystemFont, "SF Pro Display", "SF Pro Text", "Helvetica Neue", "Segoe UI", Roboto, Arial, sans-serif;
  --step-small: clamp(0.8125rem, 0.79rem + 0.1vw, 0.875rem);
  --step-body: clamp(1.0625rem, 1rem + 0.25vw, 1.1875rem);
  --step-lead: clamp(1.25rem, 1.1rem + 0.7vw, 1.625rem);
  --step-statement: clamp(1.5rem, 1.05rem + 1.45vw, 2.25rem);
  --step-head: clamp(2.125rem, 1.4rem + 3vw, 4.25rem);
  --step-display: clamp(2.75rem, 1.6rem + 4.4vw, 5.75rem);

  --margin: clamp(20px, 2.8vw, 40px);
  --gap: clamp(12px, 1.6vw, 24px);
  --section: clamp(104px, 11vw, 200px);
  
  --radius-sm: 10px;
  --radius: 14px;
  --radius-md: 20px;
  --radius-lg: 28px;
  --radius-pill: 999px;

  --ease-out: cubic-bezier(0.22, 1, 0.36, 1);
  --ease-expo: cubic-bezier(0.16, 1, 0.3, 1);
  --ease-in-out: cubic-bezier(0.76, 0, 0.24, 1);
  --t-press: 140ms;
  --t-hover: 180ms;
  --t-ui: 240ms;
}
/* inside the base page: its container sets the width, its own spacing rhythm, and the base's global
   h2 / p / input rules do not reach into the stands */
.ft { --margin: 0px; --section: 120px; --bg: #f6f7f9; color: var(--ink); line-height: 1.5; }
.ft :where(h1, h2, h3, p, ol, ul, figure, dl, dd) { margin: 0; }
.ft :where(h2) { font-size: inherit; line-height: inherit; letter-spacing: inherit; font-weight: inherit; }
.ft input { min-width: 0; border: 0; border-radius: 0; padding: 0; background: none; }
/* headings and leads speak in the base page's voice */
.ft .head { font-size: clamp(32px, 3.6vw, 48px); line-height: 1.12; letter-spacing: -0.035em; font-weight: 620; }
.ft .lead { font-size: 20px; line-height: 1.6; letter-spacing: 0; max-width: none; margin: 0; color: #4a5664; }
@media (max-width: 760px) { .ft .lead { font-size: 18px; } }
.ft .small { font-size: var(--step-small); line-height: 1.45; }
@media (max-width: 760px) { .ft { --section: 75px; } }

.pg { fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; overflow: visible; }
.pg-ptr { fill: var(--pg-bg, var(--surface)); stroke-width: 1.6; transform-box: fill-box; transform-origin: 20% 10%; }
.pg-glyph { stroke-width: 1.8; }
.pg-cap, .pg-glyph { transform-box: view-box; }
.pg-front { fill: var(--pg-bg, var(--surface)); transform-box: fill-box; }
.pg-rays, .pg-horizon, .pg-outer, .pg-merc, .pg-bars { transform-box: fill-box; transform-origin: center; }
.pg-merc { stroke-width: 3; }
.pg-inner { stroke-dasharray: 2.2 2.8; }
.pg-dot { fill: currentColor; stroke: none; }
.pg-horizon { transform: rotate(-16deg); }
.pg-lock { fill: currentColor; stroke: none; opacity: 0; }
.dock-item .pg { flex: none; width: 32px; height: 32px; color: var(--ink); transition: color var(--t-hover) ease; }
.dock-item[aria-pressed="true"] strong, .dock-item.is-held strong, .dock-item[aria-pressed="true"] .pg, .dock-item.is-held .pg { color: #fff; }
.qe {
  --qe-pad: clamp(20px, 2.4vw, 40px);
  
  --qe-fade: 450ms;
  --qe-title: clamp(1.0625rem, 0.95rem + 0.35vw, 1.3125rem);
  --qe-top: calc(var(--qe-pad) + var(--qe-title) + clamp(14px, 1.4vw, 22px));
  position: relative; display: grid; grid-template-columns: minmax(min(440px, 46%), 5fr) minmax(0, 7fr);
  height: clamp(560px, calc(100svh - 64px - 2 * var(--gap)), 960px);
  margin: var(--section) var(--margin) 0; border-radius: var(--radius-lg); overflow: clip; scroll-margin-top: calc(64px + var(--gap));
}
.qe-in { position: relative; display: flex; flex-direction: column; gap: 10px; min-height: 0; padding: var(--qe-top) var(--qe-pad) var(--qe-pad); background: var(--dark); color: var(--dark-ink); }
.qe-out { min-height: 0; padding: clamp(14px, 1.4vw, 22px); background: var(--surface); container-type: size; display: grid; place-items: center; }
.qe-in { grid-area: 1 / 1; }
.qe-out { grid-area: 1 / 2; }
.qe-title { grid-area: 1 / 1; align-self: start; position: relative; z-index: 8; display: flex; align-items: center; gap: 10px; height: var(--qe-title); margin: var(--qe-pad) var(--qe-pad) 0; font-size: var(--qe-title); line-height: 1; letter-spacing: -0.012em; font-weight: 600; color: #fff; pointer-events: none; }
.qe-tag { display: block; width: 14px; height: 14px; margin-left: 2px; color: var(--dark-muted); pointer-events: auto; cursor: pointer; transition: opacity var(--qe-fade) ease, color var(--t-hover) ease; }
.qe:has(.qe-play:not([data-state="playing"])) .qe-tag { pointer-events: none; }
@media (hover: hover) and (pointer: fine) {
  .qe-tag:hover { color: #fff; }
}
.qe-tag svg { display: block; width: 100%; height: 100%; fill: currentColor; }
@media (prefers-reduced-motion: no-preference) {
  .qe-tag svg { animation: qe-playing 1.8s ease-in-out infinite; }
}
.qe-play[data-state] { margin-left: auto; pointer-events: auto; display: flex; align-items: center; gap: 6px; height: 32px; padding: 0 14px; border: 0; border-radius: var(--radius-pill); background: #fff; color: var(--ink); font: 600 13px/1 var(--font); letter-spacing: 0; white-space: nowrap; cursor: pointer; transition: background-color var(--t-hover) ease, color var(--t-hover) ease; }
.qe-play svg { display: none; width: 12px; height: 12px; flex: none; fill: currentColor; }
.qe-play:not([data-state="playing"]) { padding-left: 12px; background: var(--dark-2); color: #fff; }
.qe-play:not([data-state="playing"]) svg { display: block; }
.qe:has(.qe-play:not([data-state="playing"])) .qe-tag { opacity: 0; }
@media (hover: hover) and (pointer: fine) {
  .qe-play[data-state="playing"]:hover { background: #e9e9ec; }
  .qe-play:not([data-state="playing"]):hover { background: var(--dark-3); }
}
.qe-modes { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 6px; }
.qe-modes button {
  --pg-bg: var(--dark-2);
  position: relative; overflow: hidden; display: flex; align-items: center; gap: 10px; min-width: 0; min-height: 50px; padding: 8px 10px 8px 12px; border: 0; border-radius: 12px;
  background: var(--dark-2); color: var(--dark-ink); font-size: var(--step-small); font-weight: 600; text-align: left; cursor: pointer;
  transition: background-color var(--t-hover) ease, color var(--t-hover) ease;
}
.qe-modes .pg { width: 26px; height: 26px; flex: none; }
.qe-modes span { min-width: 0; }
.qe-modes button[aria-checked="true"] { --pg-bg: #fff; background: #fff; color: var(--ink); }
@media (hover: hover) and (pointer: fine) {
  .qe-modes button[aria-checked="false"]:hover { background: var(--dark-3); }
}
.qe-pad {
  position: relative; flex: 1; min-height: 200px; display: grid; place-items: center; gap: 10px; align-content: center;
  border-radius: 20px; background: var(--dark-2); color: var(--dark-ink); cursor: default; touch-action: none; overflow: hidden;
}
.qe-key kbd {
  display: grid; place-items: center; width: 92px; height: 86px; border-radius: 14px;
  background: var(--dark-3); color: #fff; font-size: 40px; font-weight: 600;
  box-shadow: inset 0 -5px 0 rgba(0, 0, 0, 0.35); 
  transition: transform 120ms var(--ease-out), background-color 160ms ease, box-shadow 120ms ease;
}
.qe.is-held .qe-key kbd { background: var(--accent); transform: translateY(3px); box-shadow: inset 0 -2px 0 rgba(0, 0, 0, 0.3); }
.qe-ghost { position: absolute; left: 50%; top: 62%; width: 22px; height: 22px; opacity: 0; pointer-events: none; --x: 0; --y: 0;
  transform: translate(calc(-50% + var(--x) * 120px), calc(var(--y) * 80px)); transition: opacity 300ms ease; }
.qe-ghost svg { width: 22px; height: 22px; fill: #111; stroke: #fff; stroke-width: 2; stroke-linejoin: round; paint-order: stroke; filter: drop-shadow(0 1px 1.5px rgba(0, 0, 0, 0.35)); }
.qe-note { max-width: 56ch; margin: 4px 0 0; color: var(--dark-muted); font-size: var(--step-small); line-height: 1.45; min-height: 3em; flex: none; }
.qe-note b { color: #fff; font-weight: 600; }
.qe-intro { margin: var(--section) var(--margin) 0; text-align: center; scroll-margin-top: calc(64px + var(--gap)); }
.qe-intro h2 { margin: 0; font-size: clamp(2rem, 1.3rem + 1.9vw, 3rem); line-height: 1.08; letter-spacing: -0.03em; font-weight: 700; text-wrap: balance; }
.qe-intro p { max-width: 58ch; margin: 14px auto 0; color: var(--muted); font-size: var(--step-body); line-height: 1.45; text-wrap: balance; }
.qe-intro strong { color: var(--ink); font-weight: 600; }
.qe-intro + .qe { margin-top: clamp(24px, 2.6vw, 36px); }
.qe-photo { position: relative; width: min(100cqw, 75cqh); margin: 0; }
.qe-frame { position: relative; aspect-ratio: 3 / 4; overflow: hidden; border-radius: 16px; background: #d9dbdf; }
.qe-frame canvas { width: 100%; height: 100%; object-fit: cover; transform-origin: center; }
.qe-frame { background: #262628; }
.qe-crop { --line: rgba(255, 255, 255, 0.55); position: absolute; left: 50%; top: 50%; width: calc(var(--crop, 1) * 100%); height: calc(var(--crop, 1) * 100%); transform: translate(-50%, -50%); pointer-events: none; opacity: 0; transition: opacity 200ms ease; }
.qe-crop { box-shadow: 0 0 0 1px rgba(255, 255, 255, 0.95), 0 0 0 9999px rgba(12, 12, 14, 0.6); }
.qe-crop { background-image: linear-gradient(to right, transparent calc(33.33% - 0.5px), var(--line) calc(33.33% - 0.5px), var(--line) calc(33.33% + 0.5px), transparent calc(33.33% + 0.5px), transparent calc(66.67% - 0.5px), var(--line) calc(66.67% - 0.5px), var(--line) calc(66.67% + 0.5px), transparent calc(66.67% + 0.5px)), linear-gradient(to bottom, transparent calc(33.33% - 0.5px), var(--line) calc(33.33% - 0.5px), var(--line) calc(33.33% + 0.5px), transparent calc(33.33% + 0.5px), transparent calc(66.67% - 0.5px), var(--line) calc(66.67% - 0.5px), var(--line) calc(66.67% + 0.5px), transparent calc(66.67% + 0.5px)); }
.qe.is-held[data-mode="straighten"] .qe-crop { background-image: repeating-linear-gradient(to right, rgba(255, 255, 255, 0.3) 0 1px, transparent 1px calc(100% / 12)), repeating-linear-gradient(to bottom, rgba(255, 255, 255, 0.3) 0 1px, transparent 1px calc(100% / 16)); }
.qe[data-mode="straighten"] .qe-crop { opacity: 1; }
.qe-crop b { position: absolute; display: block; }
.qe-crop .c { width: 16px; height: 16px; border: 3px solid #fff; }
.qe-crop .tl { left: -3px; top: -3px; border-right: 0; border-bottom: 0; }
.qe-crop .tr { right: -3px; top: -3px; border-left: 0; border-bottom: 0; }
.qe-crop .bl { left: -3px; bottom: -3px; border-right: 0; border-top: 0; }
.qe-crop .br { right: -3px; bottom: -3px; border-left: 0; border-top: 0; }
.qe-crop .e { background: #fff; }
.qe-crop .t, .qe-crop .b { left: 50%; width: 18px; height: 3px; transform: translateX(-50%); }
.qe-crop .t { top: -3px; }
.qe-crop .b { bottom: -3px; }
.qe-crop .l, .qe-crop .r { top: 50%; width: 3px; height: 18px; transform: translateY(-50%); }
.qe-crop .l { left: -3px; }
.qe-crop .r { right: -3px; }
.qe-brush { --size: 38%; position: absolute; left: 50%; top: 46%; width: var(--size); aspect-ratio: 1; transform: translate(-50%, -50%); opacity: 0; transition: opacity 240ms ease; pointer-events: none; }
.qe-brush i { position: absolute; inset: 0; border-radius: 50%; border: 1.5px solid rgba(255, 255, 255, 0.95); box-shadow: 0 0 0 1px rgba(0, 0, 0, 0.35); }
.qe-brush i + i { inset: 22%; border-style: dashed; border-color: rgba(255, 255, 255, 0.8); box-shadow: none; }
.qe-brush::before, .qe-brush::after { content: ""; position: absolute; left: 50%; top: 50%; background: #fff; box-shadow: 0 0 0 1px rgba(0, 0, 0, 0.35); }
.qe-brush::before { width: 12px; height: 1.5px; transform: translate(-50%, -50%); }
.qe-brush::after { width: 1.5px; height: 12px; transform: translate(-50%, -50%); }
.qe[data-mode="brush"] .qe-brush { opacity: 1; }
.qe-hud {
  
  position: absolute; left: 50%; top: calc(5% + 12px); transform: translateX(-50%); display: flex; gap: 10px; align-items: baseline;
  padding: 8px 14px; border-radius: 8px; background: rgba(18, 18, 20, 0.9); color: #c9ccd2; font-size: 13px; white-space: nowrap;
  box-shadow: 0 10px 24px rgba(0, 0, 0, 0.25); 
}
.qe-hud-val { display: inline-block; text-align: right; color: #fff; font-weight: 600; font-variant-numeric: tabular-nums; }
.qe-axis { position: absolute; inset: 0; pointer-events: none; opacity: 0.4; transition: opacity var(--qe-fade) ease; }
.qe-axis i { position: absolute; display: none; border-radius: 3px; background: rgba(255, 255, 255, 0.14); }
.qe-axis-h { left: 28px; right: 28px; bottom: 76px; height: 6px; }
.qe-axis-v { right: 28px; top: 28px; bottom: 28px; width: 6px; }
.qe[data-axis="x"] .qe-axis-h, .qe[data-axis="y"] .qe-axis-v, .qe[data-axis="xy"] .qe-axis i { display: block; }
.qe-pad[data-mouse]:focus-visible { outline: none; }
.qe-fake { position: absolute; left: 0; top: 0; z-index: 6; width: 22px; height: 22px; margin: -2px 0 0 -4px; pointer-events: none; opacity: 0.45; transition: opacity var(--qe-fade) ease; }
.qe-fake svg { position: relative; width: 22px; height: 22px; fill: #111; stroke: #fff; stroke-width: 2; stroke-linejoin: round; paint-order: stroke; filter: drop-shadow(0 1px 1.5px rgba(0, 0, 0, 0.35)); }
.qe-fake::before { content: ""; position: absolute; left: -7px; top: -9px; width: 23px; height: 23px; border-radius: 50%; background: radial-gradient(closest-side, rgba(90, 162, 255, 0.45), rgba(90, 162, 255, 0.12) 55%, rgba(90, 162, 255, 0) 100%); }
.qe.is-hands .qe-axis, .qe.is-hands .qe-fake { opacity: 1; }
.qe-pad::after { content: ""; position: absolute; inset: 0; z-index: 4; background: rgba(6, 6, 8, 0.58); pointer-events: none; transition: opacity var(--qe-fade) ease; }
.qe-coach { position: absolute; inset: 0; z-index: 5; pointer-events: none; }
.qe-coach-do { position: absolute; left: 44px; right: 44px; top: calc((100% - 112px) / 2 - 0.675em); text-align: center; color: #fff; font-size: clamp(1.0625rem, 0.98rem + 0.3vw, 1.25rem); font-weight: 600; line-height: 1.35; letter-spacing: -0.01em; text-wrap: balance; }
.qe-coach-do kbd { display: inline-grid; place-items: center; min-width: 1.6em; height: 1.5em; margin: 0 0.12em; padding: 0 0.35em; border-radius: 6px; background: #fff; color: var(--ink); font: inherit; font-size: 0.9em; vertical-align: 0.05em; }
.qe-coach-lo, .qe-coach-hi { position: absolute; bottom: 92px; color: rgba(255, 255, 255, 0.82); font-size: 13px; font-weight: 500; }
.qe-coach-lo, .qe-coach-hi { opacity: 0.4; transition: opacity var(--qe-fade) ease; }
.qe.is-hands .qe-coach-lo, .qe.is-hands .qe-coach-hi { opacity: 1; }
.qe-coach-lo { left: 28px; }
.qe-coach-hi { right: 28px; }
.qe[data-axis="y"] .qe-coach-lo, .qe[data-axis="y"] .qe-coach-hi { left: auto; right: 46px; }
.qe[data-axis="y"] .qe-coach-lo { top: 26px; bottom: auto; }
.qe[data-axis="y"] .qe-coach-hi { bottom: 26px; }
.qe-key { display: none; }
.qe-coach-do kbd { box-shadow: inset 0 -3px 0 rgba(0, 0, 0, 0.18); transition: background-color var(--qe-fade) ease, color var(--qe-fade) ease, transform var(--qe-fade) var(--ease-out), box-shadow var(--qe-fade) ease; }
.qe.is-hands .qe-coach-do kbd { background: var(--accent); color: #fff; transform: translateY(2px); box-shadow: inset 0 -1px 0 rgba(0, 0, 0, 0.25); transition-duration: 110ms; }
.qe-coach-do kbd { position: relative; }
.qe-coach-do kbd::after { content: ""; position: absolute; inset: 0; z-index: -1; border-radius: inherit; box-shadow: 0 0 16px 4px rgba(90, 162, 255, 0.6); transition: opacity var(--qe-fade) ease; }
.qe.is-hands .qe-coach-do kbd::after, .qe.is-open .qe-coach-do kbd::after { opacity: 0; }
@media (prefers-reduced-motion: no-preference) {
  .qe-coach-do kbd::after { animation: qe-breathe 2.2s ease-in-out infinite; }
  .qe.is-hands .qe-coach-do kbd::after { animation-play-state: paused; }
}
@media (prefers-reduced-motion: no-preference) {
  .qe-fake.is-coax { animation: qe-coax-x 900ms ease-in-out; }
  .qe[data-mode="straighten"] .qe-fake.is-coax { animation-name: qe-coax-y; }
}
.qe-coach-do > span { transition: opacity 160ms ease; }
.qe-coach-do > .is-swap { opacity: 0; }
@media (prefers-reduced-motion: no-preference) {
  .qe-coach-do > .is-shake kbd { animation: qe-shake 620ms cubic-bezier(0.36, 0.07, 0.19, 0.97); }
}
.qe.is-hands .qe-pad::after, .qe.is-open .qe-pad::after { opacity: 0; }
.qe.is-locked .qe-modes { pointer-events: none; }
html.qe-hold-x, html.qe-hold-x *, html.qe-hold-y, html.qe-hold-y * { cursor: none !important; }
html.qe-hold-x body, html.qe-hold-y body { user-select: none; -webkit-user-select: none; }
.slot .pg { width: 0.82em; height: 0.82em; }
.keys { display: grid; grid-template-columns: repeat(12, minmax(0, 1fr)); column-gap: var(--gap); padding: var(--section) var(--margin) 0; }
.keys-copy { grid-column: 1 / span 5; }
.keys-intro { margin-top: 24px; max-width: 30ch; }
.keys-step { min-height: 56vh; display: flex; flex-direction: column; justify-content: center; gap: 12px; max-width: 34ch; opacity: 0.32; transition: opacity 500ms ease; }
.keys-step:last-child { min-height: 64vh; }
.keys-step.is-current { opacity: 1; }
.keys-step-title { font-size: var(--step-lead); line-height: 1.2; font-weight: 700; letter-spacing: -0.015em; }
.keys-stage { grid-column: 6 / span 7; }
.kb {
  --u: clamp(36px, 5vw, 78px); --kg: clamp(4px, 0.55vw, 8px);
  position: sticky; top: calc(50vh - 220px); margin-top: 24px; padding: clamp(16px, 2.2vw, 32px);
  border-radius: var(--radius-md); background: var(--dark); color: var(--dark-ink);
}
.kb-row { display: flex; gap: var(--kg); margin-bottom: var(--kg); }
.k {
  --w: 1; position: relative; flex: 0 0 auto; width: calc(var(--u) * var(--w) + var(--kg) * (var(--w) - 1)); height: var(--u);
  display: flex; flex-direction: column; justify-content: space-between; padding: 6px 6px 7px 7px; border-radius: 7px;
  background: #2a2c31; box-shadow: inset 0 -3px 0 rgba(0, 0, 0, 0.35); color: #8e939b; 
  transition: background-color 450ms ease, color 450ms ease, opacity 450ms ease;
}
.k b { font-size: 16px; font-weight: 600; line-height: 1; }
.k i { font-style: normal; font-size: var(--kl, 13px); line-height: 1.1; opacity: 0; transition: opacity 450ms ease; }
.k[data-k] { color: #d5d8dd; }
.kb.is-bare .k i { display: none; }
.k-space { opacity: 0.6; }
.kb[data-step="1"] [data-g="0"],
.kb[data-step="2"] [data-g="1"],
.kb[data-step="3"] [data-g="2"],
.kb[data-step="4"] [data-g="3"] { background: var(--accent); color: #fff; }
.kb[data-step="5"] [data-k] { background: #3d4047; color: #fff; }
.kb[data-step="5"] [data-g="0"], .kb[data-step="5"] [data-g="1"] { background: var(--accent); }
.kb[data-step="1"] [data-g="0"] i, .kb[data-step="2"] [data-g="1"] i, .kb[data-step="3"] [data-g="2"] i, .kb[data-step="4"] [data-g="3"] i, .kb[data-step="5"] [data-k] i { opacity: 1; }
.kb-caption { margin-top: 10px; color: var(--dark-muted); font-size: var(--step-small); }
.ed { position: relative; aspect-ratio: 16 / 10; border-radius: var(--radius-md); }
.sc { position: absolute; inset: 0; border-radius: inherit; overflow: hidden; container-type: size; pointer-events: none; opacity: 0; transition: opacity 450ms ease;
  transform: scale(var(--zoom, 1)); transform-origin: 50% 50%; box-shadow: 0 0 0 0.5px rgba(0, 0, 0, 0.12), 0 24px 60px rgba(0, 0, 0, calc(0.16 * (1 - var(--zoom, 1)) + 0.06)); }
.ed .sc { opacity: 1; }
.sc-win {
  --sc-ink: #1d1d1f; --sc-muted: #86868b; --sc-field: rgba(0, 0, 0, 0.05);
  height: 100%; display: flex; flex-direction: column; gap: clamp(8px, 2.4cqh, 14px);
  padding: clamp(12px, 3.4cqh, 22px) clamp(12px, 3cqw, 22px); background: #ececec; color: var(--sc-ink);
  font: 400 clamp(11px, 1.9cqw, 14px)/1.2 -apple-system, BlinkMacSystemFont, "SF Pro Text", sans-serif; letter-spacing: 0; text-align: left;
}
.sc-preset { flex: none; display: flex; align-items: center; gap: 10px; color: #3a3a3c; white-space: nowrap; }
.sc-pop { display: inline-flex; align-items: center; gap: 8px; padding: 0.4em 0.7em 0.4em 0.85em; border-radius: 7px; background: rgba(0, 0, 0, 0.06); color: var(--sc-ink); font-weight: 600; }
.sc-pop svg { width: 0.55em; height: 0.85em; fill: none; stroke: currentColor; stroke-width: 1.4; }
.sc-search { flex: 1; min-width: 0; display: flex; align-items: center; gap: 0.5em; height: 2em; margin-left: auto; padding: 0 0.7em; border-radius: 7px; background: rgba(0, 0, 0, 0.05); color: var(--sc-ink); overflow: hidden; }
.sc-search svg { flex: none; width: 0.95em; height: 0.95em; fill: none; stroke: var(--sc-muted); stroke-width: 1.5; }
.sc-q { white-space: nowrap; }
.sc-q:empty::before { content: "Search by key or command…"; color: #b4b4b9; }
.sc-q.is-typing::after { content: ""; display: inline-block; width: 1.5px; height: 1em; margin-left: 1px; vertical-align: -0.15em; background: var(--accent); }
.sc-row, .sc-sec { transition: max-height 320ms var(--ease-out), opacity 220ms ease, flex-grow 320ms var(--ease-out); }
.sc-row.is-out, .sc-sec.is-out { flex-grow: 0; max-height: 0; opacity: 0; overflow: hidden; }
.sc-desc mark { background: rgba(255, 204, 0, 0.45); color: inherit; border-radius: 2px; }
.sc-table { flex: 1; min-height: 0; display: flex; flex-direction: column; padding: 0.3em clamp(8px, 1.6cqw, 14px) 0.6em; border-radius: 10px; background: #fff; }
.sc-head, .sc-row { display: grid; grid-template-columns: 15% 15% minmax(0, 1fr) 11%; column-gap: 2.6%; align-items: center; }
.sc-head { flex: 1; max-height: 3em; color: #3a3a3c; text-align: center; }
.sc-head span:nth-child(3) { text-align: left; }
.sc-sec { flex: 1; max-height: 2.6em; display: flex; align-items: flex-end; padding-bottom: 0.35em; color: #6e6e73; font-size: 0.9em; font-weight: 600; }
.sc-row { flex: 1; min-height: 0; max-height: 3.4em; }
.sc-key, .sc-lr { position: relative; display: flex; align-items: center; justify-content: center; height: min(1.9em, 86%); border-radius: 6px; background: var(--sc-field); }
.sc-lr { color: #6e6e73; }
.sc-lr:empty { background: rgba(0, 0, 0, 0.032); }
.sc-key b { font-weight: 500; transition: opacity 160ms ease; }
.sc-x { position: absolute; right: 0.55em; top: 50%; width: 0.95em; height: 0.95em; translate: 0 -50%; border-radius: 50%; background: #8e8e93; }
.sc-x::before, .sc-x::after { content: ""; position: absolute; left: 25%; top: 46%; width: 50%; height: 1.2px; background: #fff; rotate: 45deg; }
.sc-x::after { rotate: -45deg; }
.sc-key { transition: box-shadow 140ms ease, background-color 320ms ease, color 320ms ease; }
.sc-x { transition: opacity 200ms ease; }
.sc-key b:empty + .sc-x { opacity: 0; }
.sc-key b:empty::before { content: "Set key"; color: #b4b4b9; font-size: 0.86em; font-weight: 400; white-space: nowrap; }
.sc-key.is-wait { background: #fff; box-shadow: 0 0 0 2px var(--accent), 0 0 0 5px rgba(10, 108, 223, 0.22); }
.sc-key.is-wait .sc-x { opacity: 0; }
.sc-key.is-wait b:empty::before { content: "Press a key"; color: var(--sc-muted); font-size: 0.86em; font-weight: 400; white-space: nowrap; }
@media (prefers-reduced-motion: no-preference) {
  .sc-key.is-wait { animation: sc-wait 0.9s ease-in-out infinite; }
}
.sc-key.is-hit { background: var(--accent); color: #fff; transition-duration: 0ms; }
.sc-key.is-hit .sc-x { opacity: 0; }
.sc-key.is-new { background: rgba(10, 108, 223, 0.14); }
.sc-cap { position: absolute; left: 0; top: 0; display: grid; place-items: center; border-radius: 10px; background: #fff; color: #1d1d1f; font: 600 1.35em/1 -apple-system, BlinkMacSystemFont, sans-serif; opacity: 0;
  box-shadow: 0 0 0 0.5px rgba(0, 0, 0, 0.2), inset 0 -3px 0 rgba(0, 0, 0, 0.1), 0 10px 24px rgba(0, 0, 0, 0.18); }
.sc-desc { min-width: 0; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.sc-tag { margin-left: 0.5em; padding: 0.1em 0.5em; border-radius: 4px; background: rgba(0, 0, 0, 0.06); color: #6e6e73; font-size: 0.88em; font-style: normal; }
.sc-act { display: flex; align-items: center; justify-content: center; gap: 0.7em; }
.sc-sw { position: relative; flex: none; width: 2.3em; height: 1.3em; border-radius: 0.65em; background: var(--accent); }
.sc-sw::after { content: ""; position: absolute; right: 0.15em; top: 0.15em; width: 1em; height: 1em; border-radius: 50%; background: #fff; }
.sc-bin { flex: none; width: 1.1em; height: 1.1em; fill: none; stroke: #8e8e93; stroke-width: 1.2; stroke-linecap: round; stroke-linejoin: round; }
@container (max-width: 560px) {
  .sc-head, .sc-row { grid-template-columns: 22% minmax(0, 1fr) 15%; }
  .sc-lr, .sc-head span:nth-child(2) { display: none; }
}
@container (max-width: 380px) {
  .sc-head, .sc-row { grid-template-columns: 24% minmax(0, 1fr); }
  .sc-act, .sc-head span:nth-child(4) { display: none; }
}
.figure {
  display: grid; grid-template-columns: repeat(12, minmax(0, 1fr)); grid-template-rows: auto auto 1fr auto; column-gap: var(--gap);
  min-height: min(84svh, 860px); margin: var(--section) var(--margin) 0; padding: clamp(36px, 4.4vw, 72px) clamp(24px, 3.4vw, 56px) clamp(28px, 3.6vw, 52px);
  border-radius: var(--radius-lg); background: var(--accent); color: #fff;
}
.figure-q { grid-column: 1 / -1; font-size: var(--step-statement); line-height: 1.15; letter-spacing: -0.02em; font-weight: 700; }
.figure-control { grid-column: 1 / span 5; width: min(100%, 420px); margin-top: 28px; }
.figure-control label { display: flex; justify-content: space-between; align-items: baseline; margin-bottom: 10px; color: #fff; font-size: var(--step-small); }
.figure-control output { color: #fff; font-size: var(--step-body); font-weight: 600; font-variant-numeric: tabular-nums; }
.figure-control input { -webkit-appearance: none; appearance: none; width: 100%; height: 32px; margin: 0; background: transparent; cursor: pointer; --fill: 18%; }
.figure-control input::-webkit-slider-runnable-track { height: 6px; border-radius: 3px; background: linear-gradient(90deg, #fff var(--fill), rgba(255, 255, 255, 0.28) var(--fill)); }
.figure-control input::-moz-range-track { height: 6px; border-radius: 3px; background: rgba(255, 255, 255, 0.28); }
.figure-control input::-moz-range-progress { height: 6px; border-radius: 3px; background: #fff; }
.figure-control input::-webkit-slider-thumb { -webkit-appearance: none; width: 28px; height: 28px; margin-top: -11px; border-radius: 50%; background: #fff; border: 0; transition: transform var(--t-press) var(--ease-out); }
.figure-control input::-moz-range-thumb { width: 28px; height: 28px; border-radius: 50%; background: #fff; border: 0; }
.figure-control input:active::-webkit-slider-thumb { transform: scale(1.12); }
.figure-control input:focus-visible { outline: 2px solid #fff; outline-offset: 4px; }
.figure-out { grid-column: 1 / span 8; grid-row: 4; align-self: end; font-size: clamp(7.5rem, 19vw, 19rem); line-height: 0.8; letter-spacing: -0.055em; font-weight: 700; font-variant-numeric: tabular-nums; white-space: nowrap; }
.figure-unit { font-size: 0.22em; letter-spacing: -0.01em; margin-left: 0.12em; }
.figure-how { grid-column: 9 / span 4; grid-row: 4; align-self: end; max-width: 32ch; color: #fff; }
@media (prefers-reduced-motion: no-preference) {
  .pg-widget .pg-front { animation: pg-copy 2.8s var(--ease-in-out) infinite; }
  .dock-item .pg-shift .pg-cap, .dock-item .pg-shift .pg-glyph, .slot .pg-shift .pg-cap, .slot .pg-shift .pg-glyph,
  .dock-item .pg-option .pg-cap, .dock-item .pg-option .pg-glyph { animation: pg-key 2.8s var(--ease-out) infinite; }
  .pg-ptr { animation: pg-click 2.8s var(--ease-out) infinite; }
  .slot-crop .pg-lock { animation: pg-lock 3.2s var(--ease-out) infinite; }
}
.pg-lock { transform-box: fill-box; transform-origin: center; }
@media (max-width: 1024px) {
  .keys-copy { grid-column: 1 / span 6; }
  .keys-stage { grid-column: 7 / span 6; }
  .kb .k i { display: none; }
  .figure-control { grid-column: 1 / -1; width: 100%; }
  .figure-out { grid-column: 1 / -1; grid-row: 4; }
  .figure-how { grid-column: 1 / span 9; grid-row: 5; margin-top: 18px; }
}
@media (max-width: 760px) {
  .qe { display: flex; flex-direction: column; height: auto; border-radius: var(--radius-md); }
  .qe-title { order: 0; align-self: stretch; height: auto; margin: 0 0 -1px; padding: calc(var(--qe-pad) + 4px) var(--qe-pad) 0; background: var(--dark); }
  .qe-in { order: 1; padding-top: 18px; }
  .qe-out { order: 2; padding-top: var(--qe-pad); container-type: normal; }
  .qe-title { line-height: 1.2; }
  .qe-play[data-state] { height: 36px; }
  .qe-photo { width: min(100%, 470px); }
  .qe-modes button { gap: 8px; padding: 8px 8px 8px 10px; }
  .qe-modes .pg { width: 22px; height: 22px; }
  .qe-pad { min-height: 220px; }
  .keys { display: flex; flex-direction: column; }
  .keys-copy { display: contents; }
  .keys-stage { position: sticky; top: 58px; z-index: 2; order: 1; margin-top: 24px; padding: 10px 0; background: var(--bg); }
  .keys-step { order: 2; }
  .kb { position: relative; margin-top: 0; padding: 12px; }
  .kb-caption { display: none; }
  .k { padding: 4px 5px; border-radius: 5px; }
  .k b { font-size: 13px; }
  .keys-step { min-height: 46vh; max-width: none; }
  .keys-step:last-child { min-height: 50vh; }
  .figure { min-height: 84svh; }
  .figure-q { font-size: 26px; }
  .figure-control { grid-column: 1 / -1; }
  .figure-control input { height: 44px; }
  .figure-control input::-webkit-slider-thumb { width: 36px; height: 36px; margin-top: -15px; }
  .figure-out { font-size: 30vw; }
  .figure-how { grid-column: 1 / -1; font-size: var(--step-small); }
}
.ed-show { padding: var(--section) var(--margin) 0; }
.ed-head { max-width: 760px; margin: 0 auto; text-align: center; }
.ed-head .lead { margin: 20px auto 0; max-width: 46ch; color: var(--muted); }
.ed-stage { max-width: 1040px; margin: clamp(32px, 5vw, 56px) auto 0; }
.ed-show .ed { aspect-ratio: 21 / 10; }
@media (max-width: 1024px) {
  .ed-show .ed { aspect-ratio: 16 / 9; }
}
.ed-points { list-style: none; max-width: 1040px; margin: clamp(24px, 3vw, 36px) auto 0; padding: 0; display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: var(--gap); }
.ed-points li { padding-top: 16px; border-top: 2px solid var(--surface-2); color: var(--muted); transition: border-color 400ms ease, color 400ms ease; }
.ed-point-title { margin-bottom: 6px; color: var(--ink); font-weight: 700; font-size: var(--step-body); }
.ed-points li > p:not(.ed-point-title) { font-size: var(--step-small); line-height: 1.45; }
.js .ed-points li { opacity: 0.5; transition: opacity 400ms ease, border-color 400ms ease; }
.js .ed-points li.is-current { opacity: 1; border-top-color: var(--accent); }
.sc-pop { transition: box-shadow 300ms ease, background-color 300ms ease; }
.sc-pop.is-lit { background: #fff; box-shadow: 0 0 0 2px var(--accent), 0 0 0 6px rgba(10, 108, 223, 0.2); }
@media (max-width: 760px) {
  .ed-show .ed { aspect-ratio: 4 / 3; }
  .ed-points { grid-template-columns: 1fr; gap: 14px; }
}
.js .keys { display: block; height: calc(100svh + var(--n, 4) * 62svh); padding-bottom: 0; }
.js .keys-pin {
  position: sticky; top: 64px; height: calc(100svh - 64px);
  display: grid; grid-template-columns: repeat(12, minmax(0, 1fr)); column-gap: var(--gap); align-items: center;
}
.js .keys-copy { grid-column: 1 / span 5; }
.js .keys-stage { grid-column: 6 / span 7; }
.js .kb { position: relative; top: auto; margin-top: 0; }
.js .keys-steps { display: grid; margin-top: clamp(36px, 7vh, 72px); }
.js .keys-step { grid-area: 1 / 1; min-height: 0; max-width: 34ch; justify-content: flex-start; opacity: 0; visibility: hidden;
  transition: opacity 380ms ease, visibility 0s linear 450ms; }
.js .keys-step.is-current { opacity: 1; visibility: visible; transition: opacity 380ms ease 80ms, visibility 0s; }
.js .keys-step > * { transform: translateY(26px); transition: transform 650ms var(--ease-expo); }
.js .keys-step.is-past > * { transform: translateY(-26px); }
.js .keys-step.is-current > * { transform: none; }
.js .keys-step.is-current > p:not(.keys-step-title) { transition-delay: 70ms; }
.js .keys-step-title { clip-path: inset(0 0 100% 0); transition: transform 650ms var(--ease-expo), clip-path 650ms var(--ease-expo); }
.js .keys-step.is-current .keys-step-title { clip-path: inset(-20% 0 -30% 0); }
.keys-progress { display: none; }
.js .keys-progress { display: flex; gap: 6px; margin-top: clamp(28px, 5vh, 48px); }
.js .keys-progress i { position: relative; width: 32px; height: 3px; border-radius: 2px; overflow: hidden; background: var(--surface-2); }
.js .keys-progress i::after { content: ""; position: absolute; inset: 0; border-radius: inherit; background: var(--ink); transform-origin: left; transform: scaleX(var(--fill, 0)); }
@media (prefers-reduced-motion: no-preference) {
  .k.is-tap { animation: kb-tap 300ms ease-out calc(var(--i, 0) * 70ms) both; }
}
@media (max-width: 1024px) {
  .js .keys-copy { grid-column: 1 / span 6; }
  .js .keys-stage { grid-column: 7 / span 6; }
}
@media (max-width: 760px) {
  .js .keys { height: calc(100svh + var(--n, 4) * 55svh); }
  .ed { aspect-ratio: 3 / 2; }
  .js .keys-pin { top: 58px; height: calc(100svh - 58px); display: flex; flex-direction: column; justify-content: flex-start; align-items: stretch; gap: 0; padding-top: 16px; }
  .js .keys-copy { display: contents; }
  .js .keys-pin > .keys-stage { position: static; order: 1; margin-top: 20px; padding: 0; background: none; }
  .js .keys-steps { order: 2; margin-top: 22px; }
  .js .keys-progress { order: 3; margin-top: 18px; }
  .js .keys-step { min-height: 0; }
}
@media (prefers-reduced-motion: reduce) {
  .js .keys-step > *, .js .keys-step-title { transform: none !important; clip-path: none !important; transition: none; }
  .lr-main, .lr-thumb-top, .k, .k i, .keys-step { transition: none; }
}
@keyframes qe-playing { 0%, 100% { opacity: 1; } 50% { opacity: 0.35; } }
@keyframes qe-coax-x { 0%, 100% { translate: 0 0; } 30% { translate: 18px 0; } 70% { translate: -18px 0; } }
@keyframes qe-coax-y { 0%, 100% { translate: 0 0; } 30% { translate: 0 18px; } 70% { translate: 0 -18px; } }
@keyframes qe-shake {
  0%, 100% { transform: none; }
  15% { transform: translateX(-3px) rotate(-6deg); }
  30% { transform: translateX(3px) rotate(6deg); }
  45% { transform: translateX(-3px) rotate(-5deg); }
  60% { transform: translateX(2px) rotate(4deg); }
  75% { transform: translateX(-1px) rotate(-2deg); }
}
@keyframes qe-breathe { 0%, 100% { box-shadow: 0 0 10px 1px rgba(90, 162, 255, 0.35); } 50% { box-shadow: 0 0 26px 9px rgba(90, 162, 255, 0.8); } }
@keyframes sc-wait { 50% { box-shadow: 0 0 0 2px var(--accent), 0 0 0 8px rgba(10, 108, 223, 0.1); } }
@keyframes pg-copy { 0%, 18% { transform: translate(3px, -3.5px); } 42%, 82% { transform: none; } 100% { transform: translate(3px, -3.5px); } }
@keyframes pg-key { 0%, 30% { transform: none; } 36% { transform: translateY(1.2px); } 50%, 100% { transform: none; } }
@keyframes pg-click { 0%, 30% { transform: none; } 36% { transform: scale(0.82); } 46%, 100% { transform: none; } }
@keyframes pg-lock { 0%, 35% { opacity: 0; transform: scale(0.6); } 50%, 85% { opacity: 1; transform: none; } 100% { opacity: 0; } }
@keyframes kb-tap { 40% { transform: translateY(3px); box-shadow: inset 0 -1px 0 rgba(0, 0, 0, 0.35); } }

/* the base header does not stay on screen, so the pinned scene holds the whole viewport */
.js .ft .keys-pin { top: 0; height: 100svh; }
@media (max-width: 760px) { .js .ft .keys-pin { top: 0; height: 100svh; } }
/* the base container is narrower than the redesign's page, so the keys are a little smaller */
.ft .kb { --u: clamp(34px, 4.9vw, 72px); --kg: clamp(4px, 0.5vw, 7px); }
.js .ft .keys:not(.ed-show) .keys-copy { grid-column: 1 / span 4; }
.js .ft .keys:not(.ed-show) .keys-stage { grid-column: 5 / span 8; }
@media (max-width: 1024px) {
  .js .ft .keys:not(.ed-show) .keys-copy { grid-column: 1 / span 5; }
  .js .ft .keys:not(.ed-show) .keys-stage { grid-column: 6 / span 7; }
}

/* ---------- time back: a one-line card before the prices ---------- */
.savings { margin-top: 90px; padding: 28px 32px 22px; border-radius: 16px; background: #edf0f4; }
.savings-line { margin: 0; font-size: clamp(22px, 2.2vw, 28px); line-height: 1.35; letter-spacing: -0.02em; font-weight: 600; }
.savings-line output { font-variant-numeric: tabular-nums; }
.savings-total { color: #086ed8; white-space: nowrap; }
.savings-range { display: block; width: 100%; min-width: 0; margin: 16px 0 6px; padding: 0; border: 0; background: none; accent-color: #086ed8; cursor: ew-resize; }
.savings-how { border: 0; padding: 0; }
.savings-how summary { display: inline-block; padding: 6px 0; font-size: 14px; font-weight: 500; color: #076bd0; }
.savings-how summary::after { content: " ▾"; position: static; }
.savings-how[open] summary::after { content: " ▴"; }
.savings-how ul { list-style: none; margin: 10px 0 0; padding: 0; }
.savings-how li { display: flex; justify-content: space-between; gap: 24px; padding: 10px 0; border-top: 1px solid #d8dee6; font-size: 15px; color: #4a5664; }
.savings-how li b { margin-right: 6px; color: #17212e; font-weight: 600; }
.savings-how li output { flex: none; color: #17212e; font-weight: 600; font-variant-numeric: tabular-nums; }
.savings-how p { margin: 10px 0 0; font-size: 13px; color: #586473; }
@media (max-width: 760px) {
  .savings { margin-top: 60px; padding: 22px 20px 16px; }
  .savings-how li { font-size: 14px; gap: 14px; }
}

/* the keyboard plays by itself: one screen, no pinning; the statements take turns on a timer, the bars fill with time
   and a click on a bar shows its statement */
.js .ft .keys { height: auto; padding-bottom: 0; }
.js .ft .keys-pin { position: static; height: auto; padding: 0; }
.ft .keys .keys-intro { margin-top: 18px; }
.keys-progress button { display: flex; align-items: center; height: 24px; padding: 0; border: 0; background: none; cursor: pointer; }
.keys-progress button:hover i { background: #c9d1da; }
@media (max-width: 760px) { .js .ft .keys-pin { display: flex; flex-direction: column; } }
