/* Game UI kit on cream paper (docs/redesign/ART_DIRECTION.md §4): cards are a 1 px hairline
   plus one soft shadow; only pressables get the 4 px darker bottom edge. Text stays live.
   Lilita One is titles, XP, levels and rewards only.
   (The old SVG-slice frames stretched a 64px rect and rendered every panel as
   a lumpy pillow; see docs/AUDIT_CLAUDE.md A-1.) */

:root {
  --kit-border: 1px;
  --kit-depth: 4px;
  --kit-press: 4px;
}

.game-stage,
.game-column {
  background-color: var(--night-sky);
  background-image: url("/static/art/ui/grain.png"), var(--night-gradient);
  background-repeat: repeat, no-repeat;
  background-size: 128px 128px, cover;
}

/* One panel. */
.today-card,
.quest-row,
.concept-cell,
.story-panel,
.predict-reveal,
.boss-meter,
.boss-result,
.sheet,
.map-sheet-card,
.level-sheet-card,
.chat-game,
.map-choice {
  border: 1px solid var(--line);
  border-radius: var(--r-card);
  background: var(--card);
  box-shadow: var(--shadow-card);
}

/* Pressable panels keep the toy depth: a darker bottom edge that collapses when pressed. */
.quest-row,
.map-choice {
  box-shadow: 0 var(--kit-depth) 0 var(--edge);
}

/* Collectible frames: same panel, rarity on the border colour. */
.cards-bias,
.rule-card,
.cards-badge,
.cards-bias.is-locked,
.cards-badge.is-locked,
.rule-card.is-locked {
  border: 2px solid var(--line);
  border-radius: var(--r-card);
  background: var(--card);
  box-shadow: var(--shadow-card);
}

.cards-bias.rarity-rare {
  border-color: var(--info);
}

.cards-bias.rarity-epic,
.cards-badge.is-earned {
  border-color: var(--rare);
  box-shadow: var(--shadow-card), 0 0 16px color-mix(in srgb, var(--rare) 60%, transparent);
}

.story-panel h3,
.map-sheet-card h2,
.today-title {
  border: 0;
  background: none;
  box-shadow: none;
  color: var(--ink);
  font-family: var(--font-display);
  font-weight: 800;
  letter-spacing: var(--tracking-head);
  line-height: 1.15;
}

/* Reward ribbon: a coin-gold pill. */
.level-sheet-card h2,
.boss-badge {
  display: block;
  width: fit-content;
  max-width: 100%;
  padding: 4px 16px;
  border: 0;
  border-radius: var(--radius-pill);
  background: var(--coin);
  box-shadow: 0 var(--kit-depth) 0 var(--coin-dark);
  color: var(--on-color);
  font-family: var(--font-display);
  font-weight: 800;
  letter-spacing: var(--tracking-head);
  font-size: 22px;
  line-height: 1.15;
  letter-spacing: 0.01em;
  overflow-wrap: normal;
}

.level-ring span,
.level-sheet-card .map-kicker,
.level-sheet-card p:not(.level-sheet-line),
.pill-xp,
.stage-xp,
.xp-toast,
.map-score {
  font-family: var(--font-display);
  font-weight: 800;
  letter-spacing: var(--tracking-head);
  letter-spacing: 0.01em;
}

/* One press-able button. Primary is coral; secondary is raised; win is mint. */
.btn-game:not(.map-node-btn):not(.map-boss-btn):not(.chip),
.stage-primary,
.cards-primary,
.today-retry {
  min-height: 48px;
  padding: 10px 18px;
  border: var(--kit-border) solid var(--outline);
  border-radius: var(--radius-md);
  background: var(--action);
  color: var(--on-action);
  box-shadow: 0 var(--kit-press) 0 var(--action-shadow);
  font-family: var(--font-ui);
  font-weight: 700;
  text-align: center;
  cursor: pointer;
  transition: transform var(--motion-tap) ease-out, box-shadow var(--motion-tap) ease-out;
}

.btn-game.btn-game-secondary:not(.map-node-btn):not(.map-boss-btn):not(.chip),
.stage-back {
  background: var(--raised);
  color: var(--ink);
  box-shadow: 0 var(--kit-press) 0 var(--outline);
}

.btn-game:not(.map-node-btn):not(.map-boss-btn):not(.chip):active:not(:disabled),
.stage-primary:active:not(:disabled),
.cards-primary:active:not(:disabled),
.today-retry:active:not(:disabled),
.stage-back:active:not(:disabled) {
  transform: translateY(var(--kit-press));
  box-shadow: 0 0 0 transparent;
}

.btn-game:disabled:not(.map-node-btn):not(.map-boss-btn),
.stage-primary:disabled,
.cards-primary:disabled,
.today-retry:disabled {
  background: var(--line);
  color: var(--muted);
  box-shadow: none;
  cursor: default;
  transform: none;
}

/* Answer choices are panels: picked gets an info ring, reveal lights them up. */
.map-choice.is-picked {
  border-color: var(--sea);
  background: var(--info);
  box-shadow: 0 var(--kit-depth) 0 var(--sea);
}

.map-choice.is-right {
  border-color: var(--outline);
  background: var(--win);
  color: var(--on-color);
}

.map-choice.is-wrong {
  border-color: var(--outline);
  background: var(--action);
  color: var(--on-action);
}

/* The one icon family (Deep Blue item 1): Lucide outline icons, 1.8 px stroke, colour from the text. */
.icon,
.kit-icon {
  display: inline-block;
  flex: none;
  vertical-align: -0.15em;
  fill: none;
  stroke: currentColor;
}

.chat-game .call-track span,
.chat-game .board-slot-no {
  color: var(--muted);
}

@media (prefers-reduced-motion: reduce) {
  .btn-game,
  .stage-primary,
  .stage-back,
  .cards-primary,
  .today-retry {
    transition: none;
  }

  .btn-game:active,
  .stage-primary:active,
  .stage-back:active,
  .cards-primary:active,
  .today-retry:active {
    transform: none;
  }
}

/* ---------------------------------------------------------------------------
   Ask on the kit (docs/art/STYLE_GUIDE.md, roadmap 1.3). Same panel, button,
   chip and bubble as the game; no glass, no old blue/orange theme.
   --------------------------------------------------------------------------- */

.welcome-card,
.bubble.assistant {
  border: 1px solid var(--line);
  border-radius: var(--r-card);
  background: var(--card);
  box-shadow: var(--shadow-card);
  color: var(--ink);
  font-size: 16px;
  line-height: 1.5;
}
.bubble.assistant .welcome-card {
  border: 0;
  box-shadow: none;
  background: transparent;
  padding: 4px;
}
.bubble.user {
  border: 0;
  border-radius: var(--r-card) var(--r-card) 6px var(--r-card);
  background: var(--sea);
  box-shadow: none;
  color: var(--on-action);
  font-size: 16px;
}

.composer-wrap {
  border: 1px solid var(--line);
  border-radius: var(--r-card);
  background: var(--card);
  box-shadow: var(--shadow-card);
}
.composer .input {
  min-height: 48px;
  border: 1px solid var(--edge);
  border-radius: var(--r-control);
  background: var(--paper);
  color: var(--ink);
  font-size: 16px;
}
.composer .input:focus-visible {
  outline: 2px solid var(--link);
  outline-offset: 2px;
}
.composer .btn-send {
  width: 48px;
  min-height: 48px;
  border: var(--kit-border) solid var(--outline);
  border-radius: var(--radius-md);
  background: var(--action);
  color: var(--on-action);
  box-shadow: 0 var(--kit-press) 0 var(--action-shadow);
}
.composer .btn-send:active:not(:disabled) {
  transform: translateY(var(--kit-press));
  box-shadow: none;
}
.composer .btn-voice,
.composer .btn-stop {
  min-width: 48px;
  min-height: 48px;
  border: var(--kit-border) solid var(--outline);
  border-radius: var(--radius-md);
  background: var(--raised);
  color: var(--ink);
  box-shadow: 0 var(--kit-depth) 0 var(--outline);
}

.quick-chips .chip.btn-game {
  min-height: 44px;
  padding: 8px 14px;
  border: var(--kit-border) solid var(--outline);
  border-radius: var(--radius-pill);
  background: var(--raised);
  color: var(--ink);
  box-shadow: 0 3px 0 var(--outline);
  font: 600 14px/1.2 var(--font-ui);
}
.quick-chips .chip.btn-game.chip-play {
  background: var(--win);
  color: var(--on-color);
  box-shadow: 0 3px 0 var(--leaf);
}
.quick-chips .chip.btn-game:active {
  transform: translateY(3px);
  box-shadow: none;
}

@media (prefers-reduced-motion: reduce) {
  .quick-chips .chip,
  .composer .btn-send { transition: none; transform: none !important; }
}
