/* glovemode.com: motion. Loaded after style.css on every page.

   Three kinds of rules:
   - plain CSS that runs without scripts (the hero's entrance, page-to-page transitions, combo
     steps lighting up on hover, the timer's glow);
   - html.fx rules, for what fx.js drives (things arriving on scroll, the cursor, the ticker);
   - the heavy bag (fx-bag.js) and the voice demo (fx-voice.js) on the home page.
   Everything that moves by itself sits behind prefers-reduced-motion: no-preference. */

/* ---------- hero stage: where the heavy bag hangs ---------- */
.hero-stage { position: relative; isolation: isolate; }
.hero-copy { position: relative; z-index: 1; }
.bag-zone { display: none; }
.has-bag .bag-zone { display: block; position: relative; margin: 18px -16px 0; padding: 0 16px 6px; }
.bag-area { position: relative; z-index: 1; height: 400px; touch-action: manipulation; -webkit-user-select: none; user-select: none; -webkit-tap-highlight-color: transparent; }
.bag-gl, .bag-fx { position: absolute; inset: 0; z-index: 0; width: 100%; height: 100%; pointer-events: none; }
.bag-gl {
  opacity: 0;
  transition: opacity 0.35s linear;
  -webkit-mask-image: linear-gradient(to bottom, transparent 0, #000 15%, #000 82%, transparent 100%);
  mask-image: linear-gradient(to bottom, transparent 0, #000 15%, #000 82%, transparent 100%);
}
.is-lit .bag-gl { opacity: 1; }
.bag-fx { z-index: 2; }
.can-hit .bag-area { cursor: crosshair; }
.has-cur .can-hit .bag-area, .has-cur .can-hit .hero-copy { cursor: none; }

.bag-hint {
  position: absolute;
  left: calc(50% + 74px);
  top: 47%;
  display: flex;
  align-items: center;
  gap: 8px;
  margin: 0;
  color: var(--title);
  font-size: 14px;
  font-weight: 600;
  white-space: nowrap;
  pointer-events: none;
  opacity: 0;
  animation: hint-in 0.6s ease 2.4s forwards;
  transition: opacity 0.3s;
}
.bag-hint::before {
  content: "";
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: var(--accent);
  animation: hint-dot 1.4s ease-out infinite;
}
.is-played .bag-hint { animation: none; opacity: 0; }
@keyframes hint-in { to { opacity: 1; } }
@keyframes hint-dot {
  0% { box-shadow: 0 0 0 0 rgba(232, 108, 58, 0.7); }
  100% { box-shadow: 0 0 0 14px rgba(232, 108, 58, 0); }
}

.bag-card {
  position: relative;
  z-index: 1;
  max-width: 440px;
  margin: 0 auto;
  padding: 14px 16px 12px;
  border: 1px solid var(--border);
  border-radius: 16px;
  background: rgba(22, 22, 22, 0.78);
  -webkit-backdrop-filter: blur(10px);
  backdrop-filter: blur(10px);
  opacity: 0;
  transform: translateY(14px);
  transition: opacity 0.6s ease 0.9s, transform 0.8s cubic-bezier(0.16, 1, 0.3, 1) 0.9s, border-color 0.4s;
}
.is-lit .bag-card { opacity: 1; transform: none; }
.bag-card.is-done { border-color: var(--accent); }
.bag-card .bag-label { margin: 0; color: var(--muted); font-size: 13px; font-weight: 600; }
.bag-card.is-done .bag-label { color: var(--accent); }
.bag-seq { display: flex; flex-wrap: wrap; gap: 6px; margin: 8px 0 10px; padding: 0; list-style: none; }
.bag-seq li {
  padding: 5px 12px;
  border: 1px solid var(--border-2);
  border-radius: 999px;
  color: var(--text-2);
  font-size: 15px;
  font-weight: 600;
  white-space: nowrap;
  transition: background-color 0.2s, border-color 0.2s, color 0.2s, box-shadow 0.3s;
}
.bag-seq li.is-next { border-color: var(--accent); color: var(--title); box-shadow: 0 0 0 3px rgba(232, 108, 58, 0.18); }
.bag-seq li.is-done { border-color: var(--accent); background: var(--accent); color: #1a0d07; }
.bag-card .bag-cue { min-height: 3em; margin: 0; color: var(--text-2); font-size: 14px; line-height: 1.5; }
.bag-more { font-weight: 600; white-space: nowrap; }
.bag-row { display: flex; flex-wrap: wrap; align-items: center; gap: 8px 14px; margin-top: 10px; }
.bag-stat { color: var(--muted); font-size: 13px; font-variant-numeric: tabular-nums; white-space: nowrap; }
.bag-stat b { color: var(--title); font-size: 15px; font-weight: 700; }
/* hits and power share the first line, the buttons the second */
.bag-power { flex: 1 0 55%; }
.bag-meter { display: inline-block; width: 52px; height: 4px; margin-left: 8px; border-radius: 2px; background: #2c2c2c; overflow: hidden; vertical-align: middle; }
.bag-meter i { display: block; height: 100%; background: linear-gradient(90deg, #b9502a, var(--accent) 60%, #ffb58f); transform: scaleX(0); transform-origin: left; transition: transform 0.25s cubic-bezier(0.2, 0.9, 0.2, 1); }
.bag-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 34px;
  padding: 0 12px;
  border: 1px solid var(--border-2);
  border-radius: 999px;
  background: transparent;
  color: var(--text);
  font: inherit;
  font-size: 13px;
  font-weight: 600;
  white-space: nowrap;
  cursor: pointer;
}
.bag-btn:hover { border-color: var(--text-2); }
.bag-btn[hidden] { display: none; }
.bag-kbd { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); }
.bag-kbd:focus-visible { position: static; width: auto; height: auto; overflow: visible; clip: auto; }
.bag-card .bag-label { padding-right: 40px; }
.bag-sound { position: absolute; top: 8px; right: 8px; width: 34px; padding: 0; border-color: transparent; color: var(--text-2); }
.bag-sound svg { width: 16px; height: 16px; }
.bag-sound .on, .bag-sound[aria-pressed="true"] .off { display: none; }
.bag-sound[aria-pressed="true"] .on { display: block; }
.bag-pop {
  position: absolute;
  z-index: 3;
  color: #ffffff;
  font-size: clamp(22px, 3.2vw, 32px);
  font-weight: 800;
  letter-spacing: -0.015em;
  white-space: nowrap;
  text-shadow: 0 2px 22px rgba(232, 108, 58, 0.95), 0 0 2px rgba(0, 0, 0, 0.6);
  pointer-events: none;
}

@media (min-width: 820px) {
  .has-bag.hero-stage { padding-top: 0; }
  .has-bag .hero-top {
    display: grid;
    grid-template-columns: minmax(0, 1.06fr) minmax(0, 0.94fr);
    gap: 24px;
    min-height: clamp(620px, calc(100vh - 130px), 780px);
  }
  .has-bag .hero-copy { align-self: center; padding: 40px 0 56px; }
  .has-bag .bag-zone { position: static; display: flex; flex-direction: column; margin: 0; padding: 0 0 26px; }
  .bag-area { flex: 1; height: auto; min-height: 400px; }
  .bag-gl {
    -webkit-mask-image: linear-gradient(to bottom, #000 0, #000 80%, transparent 100%);
    mask-image: linear-gradient(to bottom, #000 0, #000 80%, transparent 100%);
  }
  .bag-card { width: 100%; }
  .bag-hint { left: calc(50% + 96px); }
  .has-bag + .wrap .reel-wide { margin-top: 12px; }
}

/* ---------- the hero's entrance: plain CSS, so it starts with the first paint ---------- */
.hh .hl { display: inline-block; }
@media (prefers-reduced-motion: no-preference) {
  .hh .eyebrow { animation: rise 0.7s cubic-bezier(0.16, 1, 0.3, 1) both; }
  .hh .hl { animation: slam 0.75s cubic-bezier(0.16, 1, 0.3, 1) 0.12s both; transform-origin: 0 100%; }
  .hh .hl + br + .hl { animation-delay: 0.3s; }
  .hh em { display: inline-block; animation: say-it 0.6s cubic-bezier(0.2, 1.5, 0.3, 1) 1.25s both; transform-origin: 30% 80%; }
  .hero .lede { animation: rise 0.8s cubic-bezier(0.16, 1, 0.3, 1) 0.55s both; }
  .hero .store { animation: rise 0.8s cubic-bezier(0.16, 1, 0.3, 1) 0.68s both; }
  .hero .trust { animation: rise 0.8s cubic-bezier(0.16, 1, 0.3, 1) 0.8s both; }
  .hero .reel { animation: rise 1s cubic-bezier(0.16, 1, 0.3, 1) 0.9s both; }
  .page-head .crumbs { animation: rise 0.6s cubic-bezier(0.16, 1, 0.3, 1) both; }
  .page-head .h1 { animation: slam 0.75s cubic-bezier(0.16, 1, 0.3, 1) 0.06s both; transform-origin: 0 100%; }
  .page-head .lede, .page-head .legend, .page-head .jump { animation: rise 0.8s cubic-bezier(0.16, 1, 0.3, 1) 0.24s both; }
  .doc > h1 { animation: slam 0.75s cubic-bezier(0.16, 1, 0.3, 1) both; transform-origin: 0 100%; }
}
@keyframes rise {
  from { opacity: 0; transform: translateY(18px); }
}
/* The reel tips up into place as it scrolls in (where the browser can tie animation to scroll). */
@supports (animation-timeline: view()) {
  @media (prefers-reduced-motion: no-preference) {
    .hero .reel {
      animation: reel-up linear both;
      animation-timeline: view();
      animation-range: entry 0% cover 42%;
      transform-origin: 50% 100%;
    }
  }
}
@keyframes reel-up {
  from { opacity: 0.35; transform: perspective(1400px) rotateX(18deg) scale(0.88); }
}
@keyframes slam {
  from { opacity: 0; transform: translateY(0.45em) rotate(2.5deg) scale(1.04); filter: blur(10px); }
}
@keyframes say-it {
  0% { transform: none; text-shadow: none; }
  35% { transform: scale(1.1) rotate(-2.5deg); text-shadow: 0 0 44px rgba(232, 108, 58, 0.95); }
  100% { transform: none; text-shadow: 0 0 0 rgba(232, 108, 58, 0); }
}
.page-head { background: radial-gradient(ellipse 70% 120% at 78% -40%, rgba(232, 108, 58, 0.10), transparent 70%); }

/* ---------- page to page: the old page ducks out, the new one steps in, the top bar stays ---------- */
@media (prefers-reduced-motion: no-preference) {
  @view-transition { navigation: auto; }
  .top { view-transition-name: top-bar; }
  ::view-transition-old(root) { animation: vt-out 0.2s ease-in both; }
  ::view-transition-new(root) { animation: vt-in 0.42s cubic-bezier(0.16, 1, 0.3, 1) both; }
}
@keyframes vt-out { to { opacity: 0; transform: translateY(-12px); } }
@keyframes vt-in { from { opacity: 0; transform: translateY(22px); } }

/* ---------- the round bar under the top bar ---------- */
.rbar { position: absolute; right: 0; bottom: -1px; left: 0; height: 2px; overflow: hidden; pointer-events: none; }
.rbar i { display: block; height: 100%; background: linear-gradient(90deg, rgba(232, 108, 58, 0.25), var(--accent)); transform: scaleX(0); transform-origin: left; }

/* ---------- arriving on scroll (fx.js sets data-rv, then .in, then removes both) ---------- */
.fx [data-rv="fade"] { opacity: 0; }
.fx [data-rv="fade"].in { opacity: 1; transition: opacity 0.9s ease 0.15s; }
.fx [data-rv="card"] { opacity: 0; transform: translateY(34px) scale(0.965); }
.fx [data-rv="card"].in {
  opacity: 1;
  transform: none;
  transition: opacity 0.6s ease calc(var(--d, 0) * 80ms), transform 0.9s cubic-bezier(0.16, 1, 0.3, 1) calc(var(--d, 0) * 80ms);
}
.fx [data-rv="chip"] { opacity: 0; transform: scale(0.7); }
.fx [data-rv="chip"].in {
  opacity: 1;
  transform: none;
  transition: opacity 0.35s ease calc(var(--d, 0) * 55ms), transform 0.55s cubic-bezier(0.2, 1.4, 0.3, 1) calc(var(--d, 0) * 55ms);
}
/* headings: every word comes up from behind its own line */
.w { display: inline-block; overflow: hidden; vertical-align: bottom; padding-bottom: 0.14em; margin-bottom: -0.14em; }
.w > span { display: inline-block; }
.fx [data-rv="words"] .w > span { transform: translateY(112%) rotate(4deg); transform-origin: 0 100%; }
.fx [data-rv="words"].in .w > span { transform: none; transition: transform 0.85s cubic-bezier(0.16, 1, 0.3, 1) calc(var(--i, 0) * 55ms); }

/* ---------- light under the pointer, on mice ---------- */
@media (hover: hover) and (pointer: fine) {
  .fx :is(.card, .combo, .feat, .preset, .band, .cta, .bag-card, .gen-form, .vd, .score-card) { position: relative; }
  .fx :is(.card, .combo, .feat, .preset, .band, .cta, .bag-card, .gen-form, .vd, .score-card)::before {
    content: "";
    position: absolute;
    inset: -1px;
    padding: 1px;
    border-radius: inherit;
    background: radial-gradient(240px circle at var(--mx, 50%) var(--my, 0%), rgba(255, 150, 100, 0.95), rgba(232, 108, 58, 0) 70%);
    -webkit-mask: linear-gradient(#000 0 0) content-box, linear-gradient(#000 0 0);
    -webkit-mask-composite: xor;
    mask: linear-gradient(#000 0 0) content-box exclude, linear-gradient(#000 0 0);
    opacity: 0;
    transition: opacity 0.35s;
    pointer-events: none;
  }
  .fx :is(.card, .combo, .feat, .preset, .band, .cta, .bag-card, .gen-form, .vd, .score-card):hover::before { opacity: 1; }
  .fx :is(.button, .soon, .pill, .badge) { transition: translate 0.35s cubic-bezier(0.2, 0.9, 0.2, 1); }
}

/* feature cards lean toward the pointer, and the screenshot scrolls to its bottom */
@media (hover: hover) and (pointer: fine) and (min-width: 820px) {
  .fx .feat:not([data-rv]) {
    transform: perspective(1100px) rotateX(var(--rx, 0deg)) rotateY(var(--ry, 0deg));
    transition: transform 0.45s cubic-bezier(0.2, 0.8, 0.2, 1), border-color 0.3s;
  }
  .fx .feat .shot { transition: object-position 2.8s cubic-bezier(0.45, 0, 0.2, 1); }
  .fx .feat:hover .shot { object-position: bottom; }
}

/* ---------- the game layer (fx-game.js): glove cursor, sparks, score, toasts ---------- */
/* On a mouse the glove is the cursor. Text fields, menus and the video keep the system one. */
html.has-cur, html.has-cur * { cursor: none !important; }
html.has-cur :is(input:not([type="checkbox"]):not([type="radio"]), textarea, select, video) { cursor: auto !important; }
.glove { position: fixed; top: 0; left: 0; z-index: 120; opacity: 0; pointer-events: none; transition: opacity 0.15s; will-change: transform; }
.glove.on { opacity: 1; }
.glove.is-text { opacity: 0; }
.glove-in { transform-origin: 18px 18px; transition: rotate 0.22s cubic-bezier(0.2, 0.8, 0.2, 1), scale 0.2s cubic-bezier(0.2, 0.8, 0.2, 1); }
.glove svg { display: block; width: 52px; height: 52px; overflow: visible; filter: drop-shadow(0 4px 6px rgba(0, 0, 0, 0.6)); transition: filter 0.2s; }
.glove.is-link .glove-in { scale: 1.14; }
.glove.is-link svg { filter: drop-shadow(0 0 8px rgba(255, 170, 120, 0.95)); }
[data-cur="bag"] .glove-in { scale: 1.35; }
.glove-edge * { fill: #1a0d07; stroke: #1a0d07; stroke-width: 3.4; stroke-linejoin: round; }
.glove-body * { fill: var(--accent); }
.glove-body .glove-cuff { fill: #c9562b; }
.glove-marks path { fill: none; stroke: #1a0d07; stroke-width: 1.7; stroke-linecap: round; }
.glove-shine { fill: #ffffff; opacity: 0.28; }

.fxc { position: fixed; inset: 0; z-index: 110; width: 100%; height: 100%; pointer-events: none; }
.pts { position: fixed; z-index: 111; color: #ffffff; font-size: 15px; font-weight: 800; white-space: nowrap; text-shadow: 0 1px 10px rgba(0, 0, 0, 0.85); pointer-events: none; }
.pts.is-hot { color: #ffb58f; font-size: 18px; }
.ch { display: inline-block; }
[data-loose] .w { overflow: visible; }

.hud { display: inline-flex; align-items: center; gap: 4px; }
.hud[hidden] { display: none; }
.hud-score {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 3px 11px 3px 7px;
  border: 1px solid #4a3327;
  border-radius: 999px;
  background: rgba(232, 108, 58, 0.10);
  color: var(--title);
  font-size: 14px;
  font-variant-numeric: tabular-nums;
}
.hud-score svg { width: 20px; height: 20px; overflow: visible; }
.hud-score b { display: inline-block; font-weight: 700; }
.hud-x { display: inline-block; color: var(--accent); font-style: normal; font-weight: 800; }
.hud-x:empty { display: none; }
.hud-sound { display: inline-flex; align-items: center; justify-content: center; width: 30px; height: 30px; padding: 0; border: 0; border-radius: 50%; background: none; color: var(--text-2); }
.hud-sound:hover { color: var(--title); }
.hud-sound svg { width: 16px; height: 16px; fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }
.hud-sound .on, .hud-sound[aria-pressed="true"] .off { display: none; }
.hud-sound[aria-pressed="true"] .on { display: block; }
@media (max-width: 479px) {
  .top .wrap.has-hud { gap: 12px; }
  .hud-sound { display: none; }
}

.toasts { position: fixed; top: 68px; right: 12px; z-index: 105; display: grid; gap: 8px; justify-items: end; pointer-events: none; }
.toast {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 9px 14px 9px 10px;
  border: 1px solid var(--accent);
  border-radius: 14px;
  background: rgba(28, 21, 17, 0.95);
  box-shadow: 0 12px 40px rgba(0, 0, 0, 0.55), 0 0 34px rgba(232, 108, 58, 0.28);
}
.toast svg { flex: none; width: 30px; height: 30px; overflow: visible; }
.toast p { display: grid; margin: 0; line-height: 1.25; }
.toast p span { color: var(--muted); font-size: 12px; }
.toast p strong { color: var(--title); font-size: 15px; }
.toast b { margin-left: 6px; color: var(--accent); font-size: 15px; font-variant-numeric: tabular-nums; }

/* ---------- the bag's 90-second round, and the keys ---------- */
.bag-clock { display: flex; align-items: baseline; gap: 12px; margin: 2px 0 0; }
.bag-clock[hidden] { display: none; }
.bag-clock b { color: var(--title); font-size: 34px; font-weight: 750; font-variant-numeric: tabular-nums; line-height: 1.1; }
.bag-clock span { color: var(--accent); font-size: 15px; font-weight: 700; font-variant-numeric: tabular-nums; }
.bag-card.is-round { border-color: var(--accent); }
.bag-card.is-warn { border-color: var(--warn); }
.bag-card.is-warn .bag-clock b { color: var(--warn); }
.bag-card.is-over { border-color: var(--done); }
.bag-card.is-over .bag-label { color: var(--done); }
.bag-round { border-color: var(--accent); background: rgba(232, 108, 58, 0.14); color: var(--title); }
.bag-round:hover { border-color: var(--accent); background: rgba(232, 108, 58, 0.26); }
.has-cur .bag-seq li[data-key]:not([data-key=""])::after {
  content: attr(data-key);
  display: inline-block;
  margin-left: 7px;
  padding: 0 5px;
  border: 1px solid currentColor;
  border-radius: 5px;
  font-size: 11px;
  line-height: 16px;
  opacity: 0.6;
  vertical-align: 1px;
}

/* ---------- home: feature cards you can play (fx-cards.js) ---------- */
.features .feat { position: relative; transition: min-height 0.45s cubic-bezier(0.2, 0.8, 0.2, 1), border-color 0.3s; }
.feat.is-live { min-height: 420px; border-color: #4a3327; }
.feat-play {
  display: inline-flex;
  align-items: center;
  gap: 9px;
  min-height: 40px;
  margin-top: 12px;
  padding: 0 16px 0 13px;
  border: 1px solid var(--accent);
  border-radius: 999px;
  background: rgba(232, 108, 58, 0.12);
  color: var(--title);
  font: inherit;
  font-size: 14px;
  font-weight: 700;
}
.feat-play::before { content: ""; width: 8px; height: 8px; border-radius: 50%; background: var(--accent); animation: hint-dot 1.6s ease-out infinite; }
.feat-play:hover { background: rgba(232, 108, 58, 0.24); }
.feat-back {
  position: absolute;
  inset: 0;
  z-index: 2;
  display: flex;
  flex-direction: column;
  gap: 12px;
  padding: 18px;
  border-radius: inherit;
  background: radial-gradient(120% 80% at 50% 0%, #2c1d15, #171514 72%);
  overflow: auto;
  clip-path: circle(0px at var(--cx, 50%) var(--cy, 100%));
  transition: clip-path 0.75s cubic-bezier(0.2, 0.8, 0.2, 1);
}
.feat.is-live .feat-back { clip-path: circle(160% at var(--cx, 50%) var(--cy, 100%)); }
.feat-demo { display: flex; flex: 1; flex-direction: column; justify-content: center; gap: 12px; min-height: 0; }
.feat-close { align-self: flex-start; min-height: 34px; padding: 0 14px; border: 1px solid var(--border-2); border-radius: 999px; background: transparent; color: var(--text-2); font: inherit; font-size: 13px; font-weight: 600; }
.feat-close:hover { border-color: var(--text-2); color: var(--title); }
.feat .demo-kick { margin: 0; color: var(--muted); font-size: 13px; font-weight: 600; }
.feat .deal-name { min-height: 2.4em; margin: 0; color: var(--title); font-size: clamp(20px, 2.3vw, 27px); font-weight: 800; line-height: 1.2; letter-spacing: -0.01em; overflow-wrap: anywhere; }
.feat .deal-level { margin: 0; }
.deal-steps { display: flex; flex-wrap: wrap; gap: 6px; margin: 0; padding: 0; list-style: none; }
.deal-steps li { padding: 4px 11px; border: 1px solid var(--accent); border-radius: 999px; background: rgba(232, 108, 58, 0.12); color: var(--title); font-size: 14px; font-weight: 600; }
.demo-row { display: flex; flex-wrap: wrap; align-items: center; gap: 10px 16px; margin-top: 4px; }
.demo-row .more-link { margin-top: 0; }
.demo-go { align-self: flex-start; min-height: 42px; padding: 0 18px; }
.feat .demo-note { margin: 0; color: var(--text-2); font-size: 13px; line-height: 1.5; }
.mini-timer { position: relative; width: min(62%, 200px); aspect-ratio: 1; margin: 0 auto; }
.mini-timer svg { width: 100%; height: 100%; }
.mini-track { fill: none; stroke: #2c2c2c; stroke-width: 5; }
.mini-arc { fill: none; stroke: var(--muted); stroke-width: 5; stroke-linecap: round; transition: stroke 0.3s; }
.mini-timer.is-on .mini-arc { stroke: var(--accent); filter: drop-shadow(0 0 4px rgba(232, 108, 58, 0.8)); }
.mini-timer.is-warn .mini-arc { stroke: var(--warn); }
.mini-face { position: absolute; inset: 0; display: grid; place-content: center; text-align: center; }
.mini-phase { color: var(--muted); font-size: 12px; font-weight: 700; letter-spacing: 0.05em; text-transform: uppercase; }
.mini-timer.is-on .mini-phase { color: var(--accent); }
.mini-timer.is-warn .mini-phase { color: var(--warn); }
.mini-clock { color: var(--title); font-size: clamp(30px, 4vw, 44px); font-weight: 750; font-variant-numeric: tabular-nums; line-height: 1.1; }
.mini-timer + .demo-go { align-self: center; }
.mix { display: grid; gap: 12px; margin: 0; padding: 0; list-style: none; }
.mix li { display: grid; grid-template-columns: 70px 1fr 28px; align-items: center; gap: 10px; color: var(--text-2); font-size: 14px; }
.mix i { height: 10px; border-radius: 5px; background: #2a2a2a; overflow: hidden; }
.mix b { display: block; height: 100%; background: linear-gradient(90deg, #b9502a, var(--accent)); transform: scaleX(0); transform-origin: left; transition: transform 0.5s cubic-bezier(0.2, 0.9, 0.2, 1); }
.mix-n { color: var(--title); font-weight: 700; font-variant-numeric: tabular-nums; text-align: right; }

/* ---------- home: the scorecard ---------- */
.score-card { position: relative; max-width: 780px; margin: 150px auto 0; padding: 20px; border: 1px solid var(--border); border-radius: 18px; background: rgba(22, 22, 22, 0.82); text-align: left; }
.end .score-title { margin: 0 0 12px; color: var(--title); font-size: 17px; font-weight: 700; }
.score-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(118px, 1fr)); gap: 10px; margin: 0; }
.score-grid div { padding: 10px 12px; border: 1px solid var(--border); border-radius: 12px; background: var(--bg); }
.score-grid dt { color: var(--muted); font-size: 12px; }
.score-grid dd { display: inline-block; margin: 2px 0 0; color: var(--title); font-size: 24px; font-weight: 750; font-variant-numeric: tabular-nums; }
.end .score-nudge { margin: 12px 0 0; color: var(--text-2); font-size: 14px; }
.score-nudge[hidden] { display: none; }
.badges { display: grid; grid-template-columns: repeat(auto-fill, minmax(200px, 1fr)); gap: 8px; margin: 14px 0 0; padding: 0; list-style: none; }
.badges li { display: grid; gap: 2px; padding: 10px 12px; border: 1px dashed var(--border-2); border-radius: 12px; opacity: 0.6; transition: opacity 0.3s, border-color 0.3s, background-color 0.3s; }
.badges strong { color: var(--text); font-size: 14px; }
.badges span { color: var(--muted); font-size: 12px; line-height: 1.4; }
.badges li.is-on { border: 1px solid var(--accent); background: rgba(232, 108, 58, 0.10); opacity: 1; }
.badges li.is-on strong { color: var(--title); }
.badges li.is-on strong::before { content: "✓ "; color: var(--accent); }

/* ---------- home: the strike ticker ---------- */
.mq {
  padding: 34px 0 18px;
  overflow: hidden;
  pointer-events: none;
  -webkit-user-select: none;
  user-select: none;
  -webkit-mask-image: linear-gradient(90deg, transparent, #000 10%, #000 90%, transparent);
  mask-image: linear-gradient(90deg, transparent, #000 10%, #000 90%, transparent);
}
.mq-track { display: flex; align-items: center; width: max-content; will-change: transform; }
.mq-track span {
  padding: 0 0.06em;
  /* Outlined letters: the stroke is painted first and the page color over it, so the heavy
     system fonts' overlapping shapes don't show lines inside the letters. */
  color: var(--bg);
  font-size: clamp(46px, 9.5vw, 120px);
  font-weight: 800;
  line-height: 1.04;
  letter-spacing: -0.03em;
  text-transform: uppercase;
  white-space: nowrap;
  -webkit-text-stroke: 2px rgba(255, 255, 255, 0.26);
  paint-order: stroke fill;
}
.mq-track span:nth-child(8n + 3) { color: var(--accent); -webkit-text-stroke: 0; }
.mq-track i { flex: none; width: clamp(8px, 1.1vw, 14px); height: clamp(8px, 1.1vw, 14px); margin: 0 clamp(16px, 2.6vw, 38px); border-radius: 50%; background: var(--accent); }
.mq-row + .mq-row { margin-top: 6px; }
.mq-row + .mq-row .mq-track span { color: #2b2b2b; font-size: clamp(22px, 4vw, 46px); -webkit-text-stroke: 0; }
.mq-row + .mq-row .mq-track i { width: 6px; height: 6px; background: #3a3a3a; }
.mq + .sec { border-top: 0; }
/* Ticker words take a punch (fx-game.js). */
.fx .mq-track span { pointer-events: auto; transition: color 0.3s, -webkit-text-stroke-color 0.3s; }
.fx .mq-track span:hover { -webkit-text-stroke-color: rgba(255, 255, 255, 0.75); }
.fx .mq-track span.is-hit { color: var(--accent); -webkit-text-stroke-color: var(--accent); }

/* ---------- home: voice commands and the demo phone ---------- */
.voice-demo[hidden] { display: none; }
.voice-demo { margin-top: 30px; }
.say.is-live li { padding: 0; border: 0; background: none; }
.say-btn {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 7px 14px 7px 11px;
  border: 1px solid var(--voice-border);
  border-radius: 999px;
  background: var(--voice-bg);
  color: var(--voice);
  font: inherit;
  font-size: 15px;
  font-weight: 500;
  white-space: nowrap;
  cursor: pointer;
  transition: background-color 0.2s, border-color 0.2s, color 0.2s, box-shadow 0.3s, transform 0.2s;
}
.say-btn:hover { border-color: var(--voice); }
.say-btn:active { transform: scale(0.96); }
.say li.is-on .say-btn { border-color: var(--voice); background: var(--voice); color: #0c1420; box-shadow: 0 0 0 4px rgba(133, 183, 235, 0.18), 0 10px 34px rgba(24, 95, 165, 0.55); }

.vd {
  position: relative;
  width: min(100%, 384px);
  margin: 0 auto;
  padding: 14px;
  border: 1px solid #2a3344;
  border-radius: 30px;
  background: linear-gradient(180deg, #16171d, #121212 40%);
  box-shadow: 0 0 0 6px #0b0b0b, 0 0 0 7px #232323, 0 50px 130px -30px rgba(24, 95, 165, 0.6);
}
.vd::after { content: ""; position: absolute; inset: -7px; border: 2px solid var(--accent); border-radius: 36px; opacity: 0; pointer-events: none; }
.vd.is-bell::after { animation: vd-bell 0.9s ease-out; }
@keyframes vd-bell {
  0% { opacity: 0.95; transform: scale(1); }
  100% { opacity: 0; transform: scale(1.07); }
}
.vd-bar {
  display: flex;
  align-items: center;
  gap: 10px;
  min-height: 52px;
  padding: 0 14px;
  border: 1px solid var(--voice-border);
  border-radius: 16px;
  background: var(--voice-bg);
  color: var(--voice);
  transition: background-color 0.25s, border-color 0.25s, color 0.25s, box-shadow 0.3s;
}
.vd-bar.is-hearing { box-shadow: 0 0 0 4px rgba(133, 183, 235, 0.14); }
.vd-bar.is-ok { border-color: var(--done-border); background: rgba(151, 196, 89, 0.10); color: var(--done); }
.vd-mic { flex: none; width: 18px; height: 18px; }
.vd-wave { flex: none; width: 88px; height: 28px; }
.vd-heard { min-width: 0; overflow: hidden; font-size: 15px; font-weight: 600; text-overflow: ellipsis; white-space: nowrap; }
.vd-head { display: flex; align-items: center; justify-content: space-between; gap: 10px; padding: 14px 4px 10px; }
.vd-head strong { color: var(--title); font-size: 17px; }
.vd-clock {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 4px 10px 4px 6px;
  border: 1px solid var(--accent);
  border-radius: 999px;
  color: var(--accent);
  font-size: 13px;
  font-weight: 600;
  font-variant-numeric: tabular-nums;
  white-space: nowrap;
  transition: background-color 0.3s, border-color 0.3s, color 0.3s;
}
.vd-clock svg { width: 18px; height: 18px; }
.vd-clock circle { fill: none; stroke: rgba(232, 108, 58, 0.28); stroke-width: 2; }
.vd-clock .arc { stroke: var(--accent); stroke-linecap: round; transition: stroke-dashoffset 0.9s linear; }
.vd-clock.is-running { background: rgba(232, 108, 58, 0.16); }
.vd-clock.is-paused { border-color: var(--border-2); color: var(--text-2); }
.vd-list { display: grid; grid-template-columns: minmax(0, 1fr); gap: 6px; margin: 0; padding: 0; list-style: none; }
.vd-item { border: 1px solid var(--border); border-radius: 12px; background: var(--surface); transition: background-color 0.3s, border-color 0.3s; }
.vd-top { display: flex; align-items: center; gap: 10px; padding: 9px 12px; }
.vd-n { flex: none; width: 14px; color: var(--muted); font-size: 13px; text-align: right; }
.vd-name { flex: 1; min-width: 0; overflow: hidden; color: var(--text); font-size: 14px; text-overflow: ellipsis; white-space: nowrap; }
.vd-heart { flex: none; width: 18px; height: 18px; }
.vd-heart path { fill: transparent; stroke: #5a5a5a; stroke-width: 1.6; transition: fill 0.2s, stroke 0.2s; }
.vd-item.is-fav .vd-heart path { fill: var(--accent); stroke: var(--accent); }
.vd-fold { display: grid; grid-template-rows: 0fr; transition: grid-template-rows 0.5s cubic-bezier(0.2, 0.8, 0.2, 1); }
.vd-steps { min-height: 0; margin: 0; padding: 0 12px 0 40px; overflow: hidden; color: var(--text-2); font-size: 13px; }
.vd-steps li { padding: 2px 0; }
.vd-steps li:last-child { padding-bottom: 12px; }
.vd-steps li::marker { color: var(--muted); }
.vd-steps b { color: var(--text); font-weight: 600; }
.vd-item.is-open { border-color: #4a3327; background: #1e1b19; }
.vd-item.is-open .vd-name { color: var(--title); font-weight: 600; }
.vd-item.is-open .vd-fold { grid-template-rows: 1fr; }
@media (min-width: 820px) {
  .voice.has-demo .voice-grid { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 400px); gap: 64px; align-items: center; }
  .voice-demo { margin-top: 0; }
}

/* ---------- home: the closing section is the end of the round ---------- */
.end.has-ring { position: relative; padding-top: 132px; padding-bottom: 132px; overflow: hidden; }
.end.has-ring::before {
  content: "";
  position: absolute;
  inset: 0;
  background: radial-gradient(circle at 50% 50%, rgba(232, 108, 58, 0.16), transparent 55%);
  opacity: 0.35;
  transition: opacity 1.2s;
  pointer-events: none;
}
.end.is-rung::before { opacity: 1; }
.end-ring { position: absolute; top: 244px; left: 50%; width: min(88vw, 410px); height: min(88vw, 410px); transform: translate(-50%, -50%); pointer-events: none; }
.end-ring circle { fill: none; }
.end-ring-track { stroke: #262626; stroke-width: 0.6; }
.end-ring-arc { stroke: var(--accent); stroke-width: 1.3; stroke-linecap: round; filter: drop-shadow(0 0 3px rgba(232, 108, 58, 0.8)); }
.end.has-ring .wrap { position: relative; }
.end .end-clock { margin: 0 0 4px; color: var(--accent); font-size: 15px; font-weight: 700; font-variant-numeric: tabular-nums; letter-spacing: 0.04em; }
.end.is-rung .end-ring { animation: rung 1.1s cubic-bezier(0.2, 0.8, 0.2, 1); }
@keyframes rung {
  0% { transform: translate(-50%, -50%) scale(1); filter: brightness(1); }
  18% { transform: translate(-50%, -50%) scale(1.06); filter: brightness(2.4); }
  100% { transform: translate(-50%, -50%) scale(1); filter: brightness(1); }
}

/* ---------- combos: hover a card and its steps light up in order, like the app reading it ---------- */
@media (hover: hover) and (prefers-reduced-motion: no-preference) {
  .combo { transition: border-color 0.3s, background-color 0.3s; }
  .combo:hover { border-color: var(--border-2); background: #1d1c1b; }
  .combo:hover .steps li b { animation: step-on 0.9s ease both; }
  .combo:hover .steps li:nth-child(2) b { animation-delay: 0.28s; }
  .combo:hover .steps li:nth-child(3) b { animation-delay: 0.56s; }
  .combo:hover .steps li:nth-child(4) b { animation-delay: 0.84s; }
  .combo:hover .steps li:nth-child(5) b { animation-delay: 1.12s; }
  .combo:hover .steps li:nth-child(6) b { animation-delay: 1.4s; }
  .combo:hover .steps li:nth-child(n + 7) b { animation-delay: 1.68s; }
  .combo:hover .lvl i:not(.off) { animation: lvl-on 0.5s ease both; }
  .combo:hover .lvl i:nth-child(2) { animation-delay: 0.08s; }
  .combo:hover .lvl i:nth-child(3) { animation-delay: 0.16s; }
}
@keyframes step-on {
  0% { color: var(--text); text-shadow: none; }
  30% { color: var(--accent); text-shadow: 0 0 18px rgba(232, 108, 58, 0.8); }
  100% { color: var(--accent); text-shadow: 0 0 0 rgba(232, 108, 58, 0); }
}
@keyframes lvl-on {
  40% { transform: scaleY(1.7); }
}
/* a generated session deals itself out */
@media (prefers-reduced-motion: no-preference) {
  .gen-out > .combo { animation: rise 0.6s cubic-bezier(0.16, 1, 0.3, 1) both; }
  .gen-out > .combo:nth-child(2) { animation-delay: 0.05s; }
  .gen-out > .combo:nth-child(3) { animation-delay: 0.1s; }
  .gen-out > .combo:nth-child(4) { animation-delay: 0.15s; }
  .gen-out > .combo:nth-child(5) { animation-delay: 0.2s; }
  .gen-out > .combo:nth-child(6) { animation-delay: 0.25s; }
  .gen-out > .combo:nth-child(7) { animation-delay: 0.3s; }
  .gen-out > .combo:nth-child(8) { animation-delay: 0.35s; }
  .gen-out > .combo:nth-child(n + 9) { animation-delay: 0.4s; }
}

/* ---------- timer: the box glows in the color of the phase ---------- */
.timer { transition: border-color 0.5s, box-shadow 0.8s; }
.timer[data-phase="prep"] { border-color: rgba(239, 159, 39, 0.5); box-shadow: 0 30px 120px -40px rgba(239, 159, 39, 0.55); }
.timer[data-phase="work"] { border-color: rgba(232, 108, 58, 0.55); box-shadow: 0 30px 130px -36px rgba(232, 108, 58, 0.7); }
.timer[data-phase="warn"] { border-color: rgba(240, 84, 79, 0.7); box-shadow: 0 30px 130px -30px rgba(240, 84, 79, 0.8); }
.timer[data-phase="rest"] { border-color: rgba(133, 183, 235, 0.5); box-shadow: 0 30px 120px -40px rgba(133, 183, 235, 0.55); }
.timer[data-phase="done"] { border-color: rgba(151, 196, 89, 0.55); box-shadow: 0 30px 120px -40px rgba(151, 196, 89, 0.6); }
.t-bar span { transition: background-color 0.4s; }
@media (prefers-reduced-motion: no-preference) {
  .timer[data-phase="warn"] .t-clock { animation: warn-beat 1s ease-in-out infinite; }
  .timer[data-phase="work"] .t-phase, .timer[data-phase="rest"] .t-phase, .timer[data-phase="prep"] .t-phase { animation: phase-in 0.5s cubic-bezier(0.2, 1.4, 0.3, 1); }
}
@keyframes warn-beat {
  50% { transform: scale(1.025); color: #ffd9d6; }
}
@keyframes phase-in {
  from { transform: scale(1.5); opacity: 0; }
}
