/* ------------------------------------------------------------------ tokens
   All values from design/DESIGN.md. Accent shifted one notch off Teak's
   #FAE261 → #FFD75E (the recommended option: keep the structure, not the hue). */

:root {
  --bg: #f8faf7;
  --surface: #ffffff;
  --ink-block: #2a0f14;

  --ink: #2a0f14;
  --ink-body: #544145;
  --ink-muted: #766e70;

  --hairline: #e8e6e1;
  --grid: #f0f2ef;

  --marker: #ffd75e;
  --marker-hover: #f2c94c;
  --marker-soft: #fdf1b0;
  --marker-text: #4e340c;
  --violet: #5f44e6;

  --font-display: 'Outfit', system-ui, sans-serif;
  --font-marker: 'Space Grotesk', sans-serif;
  --font-body: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Helvetica, Arial, sans-serif;
  --font-mono: 'JetBrains Mono', 'IBM Plex Mono', ui-monospace, monospace;

  /* 42px grid cells; content column = 26 cells */
  --cell: 42px;
  --col: 1092px;
}

/* ------------------------------------------------------------------ base */

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  min-height: 100vh;
  color: var(--ink-body);
  font-family: var(--font-body);
  font-size: 17px;
  line-height: 1.55;
  background-color: var(--bg);
  background-image: linear-gradient(to right, var(--grid) 1px, transparent 1px),
    linear-gradient(to bottom, var(--grid) 1px, transparent 1px);
  background-size: var(--cell) var(--cell);
  display: flex;
  flex-direction: column;
}

h1,
h2,
h3 {
  font-family: var(--font-display);
  font-weight: 500;
  color: var(--ink);
  margin: 0;
}

h1 {
  font-size: 60px;
  line-height: 1.02;
}

h2 {
  font-size: 42px;
  line-height: 1.08;
  letter-spacing: -1px;
}

h3 {
  font-size: 24px;
  line-height: 1.2;
}

p {
  margin: 0;
}

button {
  font: inherit;
  cursor: pointer;
}

.col {
  width: 100%;
  max-width: var(--col);
  margin: 0 auto;
  padding: 0 var(--cell);
}

.fade-strip-top {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 88px;
  background: linear-gradient(to bottom, var(--bg), rgba(248, 250, 247, 0));
  pointer-events: none;
}

/* ------------------------------------------------------------------ type roles */

.mono-label {
  font-family: var(--font-mono);
  font-size: 13px;
  font-weight: 500;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: var(--ink-muted);
}

.muted {
  color: var(--ink-muted);
}

.body-lg {
  font-size: 18px;
  line-height: 1.6;
}

/* Marker band: sharp corners, contrasting squarish face, one step larger. */
.marker {
  font-family: var(--font-marker);
  font-weight: 700;
  font-size: 1.05em;
  display: inline-block;
  padding: 0 0.14em;
  border-radius: 0;
  background: var(--marker);
  color: var(--marker-text);
}

/* ------------------------------------------------------------------ header / footer */

.site-header {
  position: relative;
  z-index: 2;
  padding: 26px 0;
}

.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.wordmark {
  display: flex;
  align-items: center;
  gap: 10px;
}

.wordmark .mono-label {
  color: var(--ink);
}

.sq {
  width: 11px;
  height: 11px;
  background: var(--marker);
  border-radius: 0;
  display: inline-block;
}

.header-links {
  display: flex;
  gap: 28px;
}

.header-links a {
  font-family: var(--font-mono);
  font-size: 13px;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: var(--ink-muted);
  text-decoration: none;
}

.header-links a:hover {
  color: var(--ink);
}

.site-footer {
  margin-top: auto;
  padding: 42px 0;
  text-align: center;
}

/* ------------------------------------------------------------------ views */

main {
  flex: 1;
  padding-top: var(--cell);
  padding-bottom: calc(var(--cell) * 2);
}

.view {
  animation: fade-up 0.2s ease-out both;
}

@keyframes fade-up {
  from {
    opacity: 0;
    transform: translateY(8px);
  }
  to {
    opacity: 1;
    transform: none;
  }
}

/* ------------------------------------------------------------------ cards */

.card {
  position: relative;
  background: var(--surface);
  border: 1px solid var(--hairline);
  border-radius: 16px;
  padding: calc(var(--cell) - 6px) var(--cell);
}

/* Eyebrow label notched into the card border (Teak signature). */
.notch {
  position: absolute;
  top: 0;
  left: 28px;
  transform: translateY(-50%);
  background: var(--surface);
  border: 1px solid var(--hairline);
  padding: 5px 14px;
  font-family: var(--font-mono);
  font-size: 12px;
  font-weight: 500;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: var(--ink-muted);
  white-space: nowrap;
}

/* ------------------------------------------------------------------ buttons */

.btn {
  position: relative;
  display: inline-flex;
  align-items: center;
  gap: 10px;
  border: none;
  border-radius: 20px;
  padding: 11px 24px;
  background: var(--marker);
  color: var(--ink);
  font-family: var(--font-mono);
  font-size: 14px;
  font-weight: 500;
  letter-spacing: 0.02em;
  text-decoration: none;
  overflow: hidden;
  isolation: isolate;
}

/* Hover = scale a coloured layer behind the label (Teak's technique). */
.btn::before {
  content: '';
  position: absolute;
  inset: 0;
  border-radius: inherit;
  background: var(--marker-hover);
  transform: scale(0);
  transition: transform 0.22s ease-out;
  z-index: -1;
}

.btn:hover::before {
  transform: scale(1);
}

.btn .glyph {
  font-size: 11px;
  translate: 0 0.5px;
}

.btn-dark {
  background: var(--ink-block);
  color: var(--bg);
}

.btn-dark::before {
  background: #43242b;
}

.btn-ghost {
  background: transparent;
  border: 1px solid var(--hairline);
  color: var(--ink-body);
}

.btn-ghost::before {
  background: var(--marker-soft);
}

.text-link {
  background: none;
  border: none;
  padding: 0;
  font-family: var(--font-mono);
  font-size: 13px;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: var(--ink-muted);
  text-decoration: underline;
  text-underline-offset: 3px;
}

.text-link:hover {
  color: var(--ink);
}

/* ------------------------------------------------------------------ diamonds */

.diamond-field {
  position: relative;
}

.diamond {
  position: absolute;
  background: var(--marker);
  transform: rotate(45deg);
  border-radius: 0;
  pointer-events: none;
}

/* ------------------------------------------------------------------ gate */

.gate-view {
  display: flex;
  justify-content: center;
  padding-top: calc(var(--cell) * 2);
}

.gate-card {
  width: calc(var(--cell) * 11);
  margin-top: var(--cell);
}

.gate-card h2 {
  font-size: 32px;
  letter-spacing: -0.5px;
  margin-bottom: 12px;
}

.gate-card p {
  margin-bottom: 24px;
}

.gate-form {
  display: flex;
  gap: 12px;
}

.gate-form input {
  flex: 1;
  font-family: var(--font-mono);
  font-size: 15px;
  padding: 10px 16px;
  border: 1px solid var(--hairline);
  border-radius: 12px;
  background: var(--surface);
  color: var(--ink);
  outline: none;
}

.gate-form input:focus {
  border-color: var(--ink-muted);
}

.gate-error {
  margin-top: 14px;
  font-family: var(--font-mono);
  font-size: 13px;
  color: var(--ink-body);
}

/* ------------------------------------------------------------------ intro */

.intro-view {
  padding-top: calc(var(--cell) * 1.5);
  text-align: center;
}

.intro-view .eyebrow-tag {
  margin-bottom: 30px;
}

.eyebrow-tag {
  display: inline-block;
  background: var(--surface);
  border: 1px solid var(--hairline);
  padding: 6px 16px;
  font-family: var(--font-mono);
  font-size: 12px;
  font-weight: 500;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: var(--ink-muted);
}

.intro-view h1 {
  margin-bottom: 28px;
}

.intro-view .lede {
  max-width: 620px;
  margin: 0 auto 30px;
  font-size: 18px;
  line-height: 1.6;
}

.intro-meta {
  margin-bottom: 36px;
  font-family: var(--font-mono);
  font-size: 13px;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: var(--ink-muted);
}

.intro-meta span {
  margin: 0 10px;
}

/* ------------------------------------------------------------------ quiz */

.quiz-view {
  max-width: calc(var(--cell) * 17);
  margin: 0 auto;
}

.progress-row {
  display: flex;
  align-items: center;
  gap: 20px;
  margin-bottom: 34px;
}

.progress-row .mono-label {
  flex-shrink: 0;
}

.progress-track {
  flex: 1;
  height: 6px;
  background: var(--marker-soft);
  border-radius: 0;
  overflow: hidden;
}

.progress-fill {
  height: 100%;
  background: var(--marker);
  border-radius: 0;
  transition: width 0.25s ease-out;
}

.scenario-card {
  padding-top: calc(var(--cell) + 4px);
}

.scenario-text {
  font-size: 29px;
  line-height: 1.28;
  letter-spacing: -0.3px;
  margin-bottom: 34px;
}

.options {
  display: flex;
  flex-direction: column;
  gap: 14px;
}

.option {
  position: relative;
  display: block;
  width: 100%;
  text-align: left;
  background: var(--surface);
  border: 1px solid var(--hairline);
  border-radius: 12px;
  padding: 16px 22px;
  font-size: 16.5px;
  line-height: 1.5;
  color: var(--ink-body);
  overflow: hidden;
  isolation: isolate;
  transition: border-color 0.15s ease;
}

.option::before {
  content: '';
  position: absolute;
  inset: 0;
  background: var(--marker-soft);
  transform: scaleX(0);
  transform-origin: left;
  transition: transform 0.2s ease-out;
  z-index: -1;
}

.option:hover {
  border-color: var(--ink-muted);
}

.option:hover::before,
.option.selected::before {
  transform: scaleX(1);
}

.option.selected {
  border-color: var(--ink);
  color: var(--ink);
}

/* ------------------------------------------------------------------ result / reveal */

.reveal {
  display: flex;
  align-items: center;
  gap: 48px;
  margin-bottom: 46px;
}

.reveal-figure {
  flex-shrink: 0;
  perspective: 600px;
  animation: figure-pop 0.45s ease-out both;
}

.reveal-figure .figure {
  transition: transform 0.15s ease-out;
  transform-style: preserve-3d;
}

@keyframes figure-pop {
  from {
    opacity: 0;
    transform: scale(0.7) translateY(12px);
  }
  to {
    opacity: 1;
    transform: none;
  }
}

.reveal-text .eyebrow-tag {
  margin-bottom: 22px;
}

.reveal-name {
  font-family: var(--font-marker);
  font-weight: 700;
  font-size: 64px;
  line-height: 1;
  letter-spacing: -1px;
  color: var(--ink);
}

/* The marker sweep — the one showpiece (~400ms, ease-out). */
.sweep {
  position: relative;
  display: inline-block;
  padding: 0 0.12em;
  z-index: 0;
  color: var(--ink);
  animation:
    name-in 0.3s ease-out 0.2s both,
    sweep-text 0.2s ease-out 0.65s forwards;
}

@keyframes sweep-text {
  to {
    color: var(--sweep-text, var(--ink));
  }
}

.sweep::before {
  content: '';
  position: absolute;
  left: 0;
  right: 0;
  top: 13%;
  height: 74%;
  background: var(--sweep, var(--marker));
  border-radius: 0;
  z-index: -1;
  transform: scaleX(0);
  transform-origin: left;
  animation: sweep-in 0.4s ease-out 0.55s both;
}

@keyframes name-in {
  from {
    opacity: 0;
  }
  to {
    opacity: 1;
  }
}

@keyframes sweep-in {
  from {
    transform: scaleX(0);
  }
  to {
    transform: scaleX(1);
  }
}

.reveal-tagline {
  font-size: 19px;
  color: var(--ink-muted);
}

.after-reveal {
  animation: fade-up 0.35s ease-out 0.95s both;
}

.trait-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: calc(var(--cell) / 2);
  margin-bottom: calc(var(--cell) * 1.5);
}

.trait-card {
  padding-top: 44px;
}

.trait-card .notch {
  display: inline-flex;
  align-items: center;
  gap: 8px;
}

.trait-card .dot {
  width: 9px;
  height: 9px;
  border-radius: 0;
  display: inline-block;
}

.trait-card p {
  font-size: 16.5px;
}

.stage-section h2 {
  margin-bottom: 20px;
}

.stage-section .stage-desc {
  max-width: 680px;
  font-size: 17.5px;
  margin-bottom: 30px;
}

.stage-next {
  border-radius: 12px;
  padding: 26px 30px 26px;
  margin-bottom: calc(var(--cell) * 1.5);
  padding-top: 36px;
}

.stage-next p {
  font-size: 16.5px;
  max-width: 720px;
}

.result-actions {
  display: flex;
  align-items: center;
  gap: 18px;
  flex-wrap: wrap;
}

.result-actions .spacer {
  flex: 1;
}

/* ------------------------------------------------------------------ map */

.map-view .eyebrow-tag {
  margin-bottom: 30px;
}

.map-view h1 {
  font-size: 52px;
  margin-bottom: 26px;
}

.persona-card {
  margin-bottom: var(--cell);
  padding-top: 40px;
}

.persona-card p {
  max-width: 800px;
  font-size: 16.5px;
}

.persona-card .demo-note {
  margin-top: 16px;
  font-family: var(--font-mono);
  font-size: 12.5px;
  letter-spacing: 0.02em;
  color: var(--ink-muted);
  max-width: 800px;
}

.board {
  position: relative;
  background-color: var(--surface);
  background-image: linear-gradient(to right, var(--grid) 1px, transparent 1px),
    linear-gradient(to bottom, var(--grid) 1px, transparent 1px);
  background-size: var(--cell) var(--cell);
  border: 1px solid var(--hairline);
  border-radius: 16px;
  overflow: hidden;
  margin-bottom: calc(var(--cell) / 2);
}

.board-path {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  pointer-events: none;
}

.region {
  position: absolute;
  border: 1px solid;
  border-radius: 12px;
  padding: 16px 18px;
  display: flex;
  flex-direction: column;
  text-align: left;
  transition: outline-color 0.15s ease;
  outline: 2px solid transparent;
  outline-offset: 2px;
}

.region:hover,
.region.selected {
  outline-color: var(--outline, var(--ink-muted));
}

.region .r-name {
  font-family: var(--font-marker);
  font-weight: 700;
  font-size: 19px;
  line-height: 1.1;
  margin-bottom: 6px;
}

.region .r-blurb {
  font-size: 13.5px;
  line-height: 1.4;
  opacity: 0.85;
}

.region .r-go {
  margin-top: auto;
  font-family: var(--font-mono);
  font-size: 11px;
  font-weight: 500;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  opacity: 0.7;
}

.region.distant {
  border-style: dashed;
  background: var(--surface);
}

.start-badge {
  position: absolute;
  top: -11px;
  left: 14px;
  background: var(--marker);
  color: var(--marker-text);
  font-family: var(--font-mono);
  font-size: 11px;
  font-weight: 500;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  padding: 3px 9px;
  border-radius: 0;
}

.board-hint {
  text-align: center;
  margin-bottom: var(--cell);
}

.detail-card {
  padding-top: 46px;
  margin-bottom: var(--cell);
}

.detail-card .detail-head {
  display: flex;
  align-items: baseline;
  gap: 18px;
  margin-bottom: 8px;
}

.detail-card h2 {
  font-size: 34px;
}

.detail-card .detail-blurb {
  color: var(--ink-muted);
  margin-bottom: 8px;
}

.start-reason {
  display: inline-block;
  font-family: var(--font-mono);
  font-size: 12.5px;
  letter-spacing: 0.02em;
  color: var(--marker-text);
  background: var(--marker-soft);
  padding: 4px 10px;
  margin-bottom: 10px;
}

.idea-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 20px;
  margin-top: 24px;
}

.idea-card {
  border: 1px solid var(--hairline);
  border-radius: 12px;
  padding: 22px 24px;
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.idea-card .effort {
  font-family: var(--font-mono);
  font-size: 11.5px;
  font-weight: 500;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: var(--ink-muted);
}

.idea-card h3 {
  font-size: 20px;
}

.idea-card .action {
  font-size: 15.5px;
  line-height: 1.55;
}

.idea-card .learn {
  margin-top: auto;
  padding-top: 10px;
  border-top: 1px solid var(--hairline);
  font-size: 14px;
  color: var(--ink-muted);
}

.idea-card .learn strong {
  font-family: var(--font-mono);
  font-size: 11px;
  font-weight: 500;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  display: block;
  margin-bottom: 4px;
  color: var(--ink-muted);
}

.map-actions {
  display: flex;
  gap: 18px;
  align-items: center;
}

/* ------------------------------------------------------------------ figures
   The five characters as living vector figures: gentle idle bob, blinking eyes,
   a swaying prop. Deliberate exception to "nothing loops" — the characters are
   the life of the page; everything else stays still (design/DESIGN.md §5). */

.figure {
  width: 96px;
}

.figure-lg {
  width: 200px;
}

.figure-svg {
  display: block;
  width: 100%;
  height: auto;
  overflow: visible;
}

.fig-bob {
  animation: fig-bob 3.4s ease-in-out infinite;
}

@keyframes fig-bob {
  0%,
  100% {
    transform: translateY(0);
  }
  50% {
    transform: translateY(-6px);
  }
}

.fig-eyes {
  animation: fig-blink 4.6s infinite;
  transform-origin: center;
  transform-box: fill-box;
}

@keyframes fig-blink {
  0%,
  93%,
  100% {
    transform: scaleY(1);
  }
  96% {
    transform: scaleY(0.12);
  }
}

.fig-prop {
  animation: fig-sway 5.2s ease-in-out infinite;
  transform-origin: center bottom;
  transform-box: fill-box;
}

@keyframes fig-sway {
  0%,
  100% {
    transform: rotate(0deg);
  }
  50% {
    transform: rotate(4deg);
  }
}

/* intro line-up */
.char-row {
  display: flex;
  justify-content: center;
  align-items: flex-end;
  gap: 40px;
  margin-bottom: 34px;
  padding-bottom: 14px;
  border-bottom: 1px solid var(--hairline);
  width: fit-content;
  margin-left: auto;
  margin-right: auto;
  padding-left: 28px;
  padding-right: 28px;
}

.char-chip {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 10px;
}

.char-chip .figure {
  width: 86px;
  transition: transform 0.2s ease-out;
}

.char-chip:hover .figure {
  transform: rotate(-4deg) scale(1.08);
}

.char-name {
  font-size: 11.5px;
}

/* gate sidekick */
.gate-wrap {
  display: flex;
  align-items: flex-end;
  gap: 30px;
  margin-top: var(--cell);
}

.gate-figure {
  width: 104px;
  margin-bottom: 8px;
}

/* ------------------------------------------------------------------ base camp & loading */

.basecamp-wrap {
  display: flex;
  align-items: flex-end;
  gap: 30px;
  max-width: calc(var(--cell) * 18);
  margin: var(--cell) auto 0;
}

.basecamp-figure {
  width: 110px;
  margin-bottom: 8px;
  flex-shrink: 0;
}

.basecamp-card {
  flex: 1;
}

.basecamp-card h2 {
  font-size: 32px;
  letter-spacing: -0.5px;
  margin-bottom: 12px;
}

.basecamp-lede {
  margin-bottom: 22px;
}

.basecamp-card textarea {
  width: 100%;
  resize: none;
  font-family: var(--font-body);
  font-size: 16.5px;
  line-height: 1.5;
  padding: 14px 18px;
  border: 1px solid var(--hairline);
  border-radius: 12px;
  background: var(--surface);
  color: var(--ink);
  outline: none;
}

.basecamp-card textarea:focus {
  border-color: var(--ink-muted);
}

.privacy-note {
  display: block;
  margin-top: 10px;
  font-size: 11.5px;
  text-transform: none;
  letter-spacing: 0.02em;
}

.key-input {
  width: 100%;
  margin-top: 14px;
  font-family: var(--font-mono);
  font-size: 12.5px;
  padding: 9px 14px;
  border: 1px dashed var(--hairline);
  border-radius: 12px;
  background: var(--surface);
  color: var(--ink);
  outline: none;
}

.key-input:focus {
  border-color: var(--ink-muted);
}

/* step 2: rank the guessed week */
.taskrank-card {
  max-width: calc(var(--cell) * 16);
  margin: var(--cell) auto 0;
}

.taskrank-card h2 {
  font-size: 32px;
  letter-spacing: -0.5px;
  margin-bottom: 10px;
}

.taskrank-lede {
  margin-bottom: 24px;
}

.rank-cap {
  font-size: 11px;
  margin: 8px 2px;
}

.rank-list {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.rank-item {
  display: flex;
  align-items: center;
  gap: 14px;
  background: var(--surface);
  border: 1px solid var(--hairline);
  border-radius: 12px;
  padding: 13px 16px;
  cursor: grab;
  transition: border-color 0.15s ease, opacity 0.15s ease;
}

.rank-item:hover {
  border-color: var(--ink-muted);
}

.rank-item.dragging {
  opacity: 0.45;
  border-style: dashed;
  cursor: grabbing;
}

.rank-num {
  width: 18px;
  text-align: center;
  color: var(--ink);
  flex-shrink: 0;
}

.rank-handle {
  color: var(--ink-muted);
  font-size: 15px;
  flex-shrink: 0;
  letter-spacing: -1px;
}

.rank-text {
  flex: 1;
  font-size: 16px;
  color: var(--ink-body);
}

.rank-kick {
  border: none;
  background: none;
  color: var(--ink-muted);
  font-size: 13px;
  padding: 4px 8px;
  border-radius: 8px;
  flex-shrink: 0;
}

.rank-kick:hover {
  background: #ffdcef;
  color: #4e2134;
}

.rank-item.excluded {
  opacity: 0.45;
  cursor: default;
  border-style: dashed;
}

.rank-item.excluded .rank-text {
  text-decoration: line-through;
}

.loading-view {
  text-align: center;
  padding-top: calc(var(--cell) * 3);
}

.loading-row {
  border-bottom: none;
  margin-bottom: 10px;
}

.loading-row .figure {
  width: 72px;
}

.loading-label {
  font-size: 13px;
}

.loading-dots::after {
  content: '';
  animation: loading-dots 1.4s steps(4, end) infinite;
}

@keyframes loading-dots {
  0% {
    content: '';
  }
  25% {
    content: '.';
  }
  50% {
    content: '..';
  }
  75% {
    content: '...';
  }
}

.deck-greeting {
  text-align: center;
  font-size: 16px;
  font-style: italic;
  color: var(--ink-muted);
  margin-bottom: 4px;
}

/* ------------------------------------------------------------------ stations */

.station-hint {
  margin-bottom: 26px;
}

.station-actions {
  display: flex;
  align-items: center;
  gap: 20px;
  margin-top: 30px;
}

.btn:disabled {
  opacity: 0.45;
  cursor: not-allowed;
}

.btn:disabled::before {
  display: none;
}

/* station 1 · deck */
.deck-stack {
  position: relative;
  height: 250px;
  margin: 6px auto 26px;
  max-width: 460px;
}

.deck-card {
  position: absolute;
  inset: 0;
  background: var(--surface);
  border: 1px solid var(--hairline);
  border-radius: 16px;
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  padding: 30px 38px;
  transform: translateY(calc(var(--i) * 7px)) scale(calc(1 - var(--i) * 0.025));
  z-index: calc(20 - var(--i));
  transition: transform 0.28s ease-out, opacity 0.28s ease-out;
}

.deck-card p {
  font-family: var(--font-display);
  font-weight: 500;
  font-size: 23px;
  line-height: 1.3;
  color: var(--ink);
}

.deck-diamond {
  position: absolute;
  top: 16px;
  left: 50%;
  width: 8px;
  height: 8px;
  margin-left: -4px;
  background: var(--marker);
  transform: rotate(45deg);
}

.deck-card.fly-right {
  transform: translateX(440px) rotate(10deg);
  opacity: 0;
}

.deck-card.fly-left {
  transform: translateX(-440px) rotate(-10deg);
  opacity: 0;
}

.deck-actions {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 30px;
}

.deck-btn {
  position: relative;
  border: 1px solid var(--hairline);
  border-radius: 20px;
  padding: 11px 26px;
  background: var(--surface);
  font-family: var(--font-mono);
  font-size: 14px;
  font-weight: 500;
  color: var(--ink);
  overflow: hidden;
  isolation: isolate;
}

.deck-btn::before {
  content: '';
  position: absolute;
  inset: 0;
  border-radius: inherit;
  transform: scale(0);
  transition: transform 0.2s ease-out;
  z-index: -1;
}

.deck-btn:hover::before {
  transform: scale(1);
}

.deck-yes::before {
  background: #d7f8e6;
}

.deck-no::before {
  background: #ffdcef;
}

.deck-btn .glyph {
  font-size: 11px;
}

/* station 2 · bag */
.bag-layout {
  display: grid;
  grid-template-columns: 1.5fr 1fr;
  gap: 30px;
  align-items: start;
}

.bag-moves {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
}

.move {
  position: relative;
  text-align: left;
  background: var(--surface);
  border: 1px solid var(--hairline);
  border-radius: 12px;
  padding: 15px 18px;
  font-size: 15.5px;
  line-height: 1.4;
  color: var(--ink-body);
  overflow: hidden;
  isolation: isolate;
  transition: border-color 0.15s ease, opacity 0.15s ease;
}

.move::before {
  content: '';
  position: absolute;
  inset: 0;
  background: var(--marker-soft);
  transform: scaleX(0);
  transform-origin: left;
  transition: transform 0.2s ease-out;
  z-index: -1;
}

.move:hover:not(:disabled) {
  border-color: var(--ink-muted);
}

.move:hover:not(:disabled)::before,
.move.packed::before {
  transform: scaleX(1);
}

.move.packed {
  border-color: var(--ink);
  color: var(--ink);
}

.move:disabled:not(.packed) {
  opacity: 0.4;
  cursor: not-allowed;
}

.bag-panel {
  border: 1px dashed var(--ink-muted);
  border-radius: 12px;
  padding: 18px 20px;
}

.bag-slots {
  display: flex;
  flex-direction: column;
  gap: 10px;
  margin-top: 12px;
}

.bag-slot {
  min-height: 44px;
  border: 1px dashed var(--hairline);
  border-radius: 8px;
  padding: 10px 14px;
  font-size: 14px;
  color: var(--ink);
  display: flex;
  align-items: center;
}

.bag-slot.filled {
  border-style: solid;
  border-color: var(--marker);
  background: var(--marker-soft);
}

/* station 3 · dial */
.dial {
  max-width: 560px;
  margin: 10px auto 0;
  text-align: center;
}

.dial-zone {
  min-height: 44px;
  margin-bottom: 22px;
  font-family: var(--font-display);
  font-size: 24px;
}

.dial-zone .marker {
  font-size: 24px;
}

#dial-range {
  -webkit-appearance: none;
  appearance: none;
  width: 100%;
  height: 6px;
  background: var(--marker-soft);
  border-radius: 0;
  outline: none;
  cursor: pointer;
}

#dial-range::-webkit-slider-thumb {
  -webkit-appearance: none;
  appearance: none;
  width: 22px;
  height: 22px;
  border-radius: 0;
  background: var(--marker);
  border: 2px solid var(--ink);
  transform: rotate(45deg);
  cursor: grab;
}

#dial-range::-moz-range-thumb {
  width: 22px;
  height: 22px;
  border-radius: 0;
  background: var(--marker);
  border: 2px solid var(--ink);
  transform: rotate(45deg);
  cursor: grab;
}

.dial-caps {
  display: flex;
  justify-content: space-between;
  margin-top: 14px;
}

.dial + .station-actions,
.dial ~ .station-actions {
  justify-content: center;
}

/* station 5 · wish */
.wish-input {
  width: 100%;
  font-family: var(--font-display);
  font-weight: 500;
  font-size: 21px;
  padding: 16px 20px;
  border: 1px solid var(--hairline);
  border-radius: 12px;
  background: var(--surface);
  color: var(--ink);
  outline: none;
}

.wish-input:focus {
  border-color: var(--ink-muted);
}

.wish-sparks {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 16px;
}

.wish-spark {
  border: 1px solid var(--hairline);
  border-radius: 20px;
  background: var(--surface);
  padding: 6px 14px;
  font-family: var(--font-mono);
  font-size: 12.5px;
  color: var(--ink-body);
}

.wish-spark:hover {
  border-color: var(--ink-muted);
  background: var(--marker-soft);
}

/* ------------------------------------------------------------------ result extras */

.experiment-card {
  border-color: transparent;
  margin-bottom: calc(var(--cell) * 1.5);
  padding-top: 42px;
}

.experiment-card .notch {
  color: inherit;
  background: var(--surface);
}

.experiment-spark {
  font-family: var(--font-display);
  font-weight: 500;
  font-size: 21px;
  line-height: 1.4;
  max-width: 760px;
}

.experiment-wish {
  margin-top: 14px;
  font-size: 16px;
  opacity: 0.9;
  max-width: 760px;
}

/* ------------------------------------------------------------------ motion */

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    animation-duration: 0.001s !important;
    animation-delay: 0s !important;
    transition-duration: 0.001s !important;
  }

  .fig-bob,
  .fig-eyes,
  .fig-prop {
    animation: none !important;
  }
}
