/* Aldward Metals — Playground page styles.
   Reuses the site-wide tokens (--bg-deep, --bg-subtle, --cu-1/2/4,
   --accent, --radius-*, --shadow-copper, --font-sans/--font-display/--font-mono).
   Reduced-motion gate at the bottom matches the one in theme.css. */

/* ── Page hero (matches /calculator/landed-cost — dark) ─────────── */
.page-hero {
  background: var(--bg-deep);
  color: var(--color-neutral-solid-024);
  position: relative; overflow: hidden;
  padding: calc(var(--nav-h) + calc(var(--sp-1) * 19)) 0 var(--sp-8);
  border-bottom: 1px solid var(--border-dark);
}
.page-hero::before {
  content: ""; position: absolute; inset: 0; pointer-events: none;
  background:
    radial-gradient(760px 420px at 82% 20%, var(--cu-glow), transparent 65%),
    radial-gradient(540px 320px at 8% 90%, var(--cu-tint-1), transparent 60%);
}
.page-hero::after {
  content: ""; position: absolute; inset: 0; pointer-events: none; opacity: 0.35;
  background-image:
    linear-gradient(var(--color-neutral-alpha-022) 1px, transparent 1px),
    linear-gradient(90deg, var(--color-neutral-alpha-022) 1px, transparent 1px);
  background-size: 32px 32px;
  mask-image: linear-gradient(180deg, var(--color-neutral-solid-001) 0%, transparent 100%);
}
.page-hero .container { position: relative; z-index: var(--z-1); }
.page-hero h1 {
  font-family: var(--font-display); font-weight: 600;
  font-size: clamp(2rem, 4.4vw, 3rem); line-height: var(--leading-tight);
  letter-spacing: -0.025em; max-width: 720px;
}
.page-hero h1 em {
  font-style: normal;
  background: linear-gradient(100deg, var(--cu-1), var(--color-amber-solid-016));
  -webkit-background-clip: text; background-clip: text; color: transparent;
}
.page-hero-sub {
  margin-top: calc(var(--sp-1) * 4.5); font-size: 1rem; line-height: var(--leading-ratio-1_7);
  color: var(--color-neutral-alpha-049); max-width: 640px;
}
.page-hero-sub kbd {
  font-family: var(--font-mono); font-size: 0.78rem; padding: calc(var(--sp-1) * 0.5) calc(var(--sp-1) * 1.5); border-radius: 4px;
  background: var(--color-neutral-alpha-027); border: 1px solid var(--color-neutral-alpha-035);
  color: var(--color-neutral-solid-024);
}

.hero-badge {
  display: inline-flex; align-items: center; gap: 8px;
  background: var(--cu-line); border: 1px solid var(--cu-line-strong);
  color: var(--cu-1); font-size: 0.7rem; font-weight: 600;
  letter-spacing: 0.12em; text-transform: uppercase;
  padding: calc(var(--sp-1) * 1.5) calc(var(--sp-1) * 3.5); border-radius: var(--radius-pill);
  margin-bottom: 1.2rem;
}
.hero-badge-dot {
  width: 6px; height: 6px; border-radius: 50%; background: var(--cu-1);
  box-shadow: 0 0 8px var(--cu-1);
}

.section-header { margin-bottom: 1.4rem; }
.section-header p { color: var(--text-muted); font-size: 0.94rem; line-height: var(--leading-ratio-1_65); }
.section-header p kbd {
  font-family: var(--font-mono); font-size: 0.78rem; padding: calc(var(--sp-1) * 0.5) calc(var(--sp-1) * 1.5); border-radius: 4px;
  background: var(--surface-sunken); border: 1px solid var(--border-subtle);
}
.overline {
  font-size: 0.7rem; font-weight: 600; letter-spacing: 0.16em;
  text-transform: uppercase; color: var(--brand-text);
  display: inline-flex; align-items: center; gap: 10px;
  margin-bottom: var(--sp-2);
}
.overline::before {
  content: ""; width: 22px; height: 1.5px;
  background: linear-gradient(90deg, var(--brand-text), transparent);
}

/* ── Workbench card ────────────────────────────────────────────── */
.workbench {
  background: var(--surface-raised); border: 1px solid var(--border-subtle);
  border-radius: var(--radius-lg);
  padding: var(--sp-6);
  display: grid; gap: 22px;
  box-shadow: var(--shadow-sm);
  position: relative;
}
@media (max-width: 600px) {
  .workbench { padding: calc(var(--sp-1) * 5.5) calc(var(--sp-1) * 4.5); gap: 18px; }
}

/* ── Element tiles ─────────────────────────────────────────────── */
.element-row {
  display: grid; grid-template-columns: repeat(4, 1fr);
  gap: 14px;
}
@media (max-width: 600px) {
  .element-row { grid-template-columns: repeat(2, 1fr); }
}
.element-tile {
  appearance: none; cursor: grab; user-select: none;
  /* Without this, mobile browsers claim the pointer sequence for scrolling
     and the drag dies in pointercancel — tiles must own their gestures. */
  touch-action: none;
  -webkit-tap-highlight-color: transparent;
  background: var(--surface-raised); border: 1.5px solid var(--border-strong);
  border-radius: var(--radius-lg);
  padding: calc(var(--sp-1) * 4.5) calc(var(--sp-1) * 3.5) calc(var(--sp-1) * 3.5);
  display: flex; flex-direction: column; align-items: center; gap: 6px;
  font-family: var(--font-sans); color: var(--text-primary);
  transition: transform var(--dur-base) var(--ease-standard), border-color var(--dur-base) var(--ease-standard),
              box-shadow var(--dur-base) var(--ease-standard), background var(--dur-base) var(--ease-standard),
              opacity var(--dur-base) var(--ease-standard);
  position: relative;
  min-height: 96px;
  text-align: center;
}
.element-tile:hover, .element-tile:focus-visible {
  border-color: var(--cu-1);
  background: var(--cu-tint-1);
  transform: translateY(-2px);
  box-shadow: var(--shadow-copper);
  outline: none;
}
.element-tile:focus-visible {
  outline: 2px solid var(--cu-1); outline-offset: 3px;
}
.element-tile:active { cursor: grabbing; }
.element-tile[data-dragging="true"] {
  transform: scale(0.94);
  border-style: dashed;
  opacity: 0.5;
}
.element-tile[data-locked="true"] {
  opacity: 0.4; cursor: not-allowed;
  filter: grayscale(0.4);
}
.element-tile[data-locked="true"]:hover { transform: none; box-shadow: none; border-color: var(--border-strong); }

.element-symbol {
  font-family: var(--font-display); font-size: 1.6rem; font-weight: 700;
  color: var(--cu-2); letter-spacing: -0.02em; line-height: var(--leading-ratio-1);
}
.element-name {
  font-size: 0.78rem; font-weight: 600; color: var(--text-primary);
  letter-spacing: 0.02em;
}
.element-zh {
  font-size: 0.7rem; color: var(--text-faint);
  letter-spacing: 0.02em;
}

/* ghost that follows the pointer while dragging */
#playground-ghost {
  position: fixed; z-index: var(--z-9999);
  pointer-events: none;
  background: var(--surface-raised); border: 1.5px dashed var(--cu-1);
  border-radius: var(--radius-lg);
  padding: calc(var(--sp-1) * 3.5) var(--sp-3);
  display: flex; flex-direction: column; align-items: center; gap: 4px;
  width: 100px; min-height: 90px;
  box-shadow: var(--shadow-copper);
  transform: translate3d(-50%, -50%, 0);
  transition: none;
}
#playground-ghost .ghost-symbol { font-family: var(--font-display); font-size: 1.4rem; color: var(--cu-2); font-weight: 700; }
#playground-ghost .ghost-name { font-size: 0.7rem; color: var(--text-muted); }

/* ── Recipe panel ──────────────────────────────────────────────── */
.recipe-panel {
  border-top: 1px dashed var(--border-subtle);
  padding-top: calc(var(--sp-1) * 5);
  display: grid; gap: 14px;
}
.recipe-panel[data-active="true"] { border-top-color: var(--cu-1); }
.recipe-slots {
  display: flex; align-items: center; gap: 10px; flex-wrap: wrap;
  font-family: var(--font-mono); font-size: 0.84rem; color: var(--text-muted);
}
.recipe-slot-label {
  font-family: var(--font-sans); font-size: 0.7rem; font-weight: 600;
  letter-spacing: 0.1em; text-transform: uppercase; color: var(--text-faint);
  margin-right: var(--sp-1);
}
.slot {
  display: inline-flex; align-items: center; justify-content: center;
  width: 38px; height: 38px;
  border: 1.5px dashed var(--border-strong);
  border-radius: var(--radius-md);
  font-family: var(--font-mono); font-size: 0.86rem; font-weight: 600;
  color: var(--text-faint);
  background: var(--surface-page);
  transition: border-color var(--dur-base), background var(--dur-base), color var(--dur-base);
}
.slot[data-filled="true"] {
  border-style: solid;
  border-color: var(--cu-1);
  background: var(--cu-tint-1);
  color: var(--cu-4);
}

.recipe-toggles {
  display: flex; align-items: center; flex-wrap: wrap; gap: 16px;
}
.toggle-row {
  display: flex; align-items: center; gap: 10px; flex-wrap: wrap;
}
.toggle-row label, .toggle-row > label:first-child {
  font-size: 0.76rem; font-weight: 600; color: var(--text-muted);
  letter-spacing: 0.02em;
}
.segmented {
  display: inline-flex;
  background: var(--surface-page);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-md);
  padding: calc(var(--sp-1) * 0.75);
  gap: 2px;
}
.seg {
  appearance: none; cursor: pointer;
  background: transparent; border: none;
  padding: calc(var(--sp-1) * 1.5) var(--sp-3);
  font-size: 0.78rem; font-weight: 500; color: var(--text-muted);
  border-radius: 5px;
  transition: background var(--dur-160ms), color var(--dur-160ms);
  font-family: var(--font-sans);
}
.seg:hover { color: var(--text-primary); }
.seg[aria-checked="true"] {
  background: var(--surface-raised);
  color: var(--cu-4);
  font-weight: 600;
  box-shadow: var(--shadow-xs);
}

.toggle-pill { display: inline-flex; align-items: center; gap: 10px; cursor: pointer; }
.toggle-pill input { position: absolute; opacity: 0; pointer-events: none; }
.toggle-pill-track {
  display: inline-block;
  width: 36px; height: 20px;
  border-radius: 999px;
  background: var(--border-subtle);
  position: relative;
  transition: background var(--dur-base);
}
.toggle-pill-thumb {
  position: absolute; top: 2px; left: 2px;
  width: 16px; height: 16px;
  border-radius: 50%;
  background: var(--color-neutral-solid-024);
  transition: transform var(--dur-base) var(--ease-standard);
  box-shadow: 0 1px 3px var(--color-neutral-alpha-009);
}
.toggle-pill input:checked + .toggle-pill-track { background: var(--cu-2); }
.toggle-pill input:checked + .toggle-pill-track .toggle-pill-thumb { transform: translateX(16px); }
.toggle-pill input:focus-visible + .toggle-pill-track {
  outline: 2px solid var(--cu-1); outline-offset: 3px;
}
.toggle-pill-text { display: flex; flex-direction: column; gap: 2px; }
.toggle-pill-text strong { font-size: 0.82rem; font-weight: 600; color: var(--text-primary); }
.toggle-pill-text .hint { font-size: 0.72rem; color: var(--text-faint); }

/* buttons */
.playground-btn {
  display: inline-flex; align-items: center; gap: 8px;
  padding: calc(var(--sp-1) * 2.75) calc(var(--sp-1) * 4.5); border-radius: var(--radius-md);
  font-size: 0.86rem; font-weight: 600; text-decoration: none;
  cursor: pointer; border: none; font-family: var(--font-sans);
  transition: transform var(--dur-base) var(--ease-standard), box-shadow var(--dur-base) var(--ease-standard),
              background var(--dur-base), opacity var(--dur-base), color var(--dur-base), border-color var(--dur-base);
}
.playground-btn:disabled, .playground-btn[disabled], .playground-btn[aria-disabled="true"] {
  opacity: 0.45; cursor: not-allowed; pointer-events: none;
}
.btn-primary {
  background: linear-gradient(135deg, var(--cu-1), var(--cu-2));
  color: var(--color-neutral-solid-024); box-shadow: var(--shadow-copper);
}
.btn-primary:hover:not(:disabled) {
  transform: translateY(-1px);
  box-shadow: 0 12px 30px var(--focus-ring);
}
.btn-outline {
  background: var(--color-blue-alpha-006); color: var(--text-primary);
  border: 1px solid var(--border-strong);
}
.btn-outline:hover { background: var(--surface-sunken); border-color: var(--cu-1); color: var(--cu-4); }
.btn-ghost {
  background: transparent; color: var(--text-muted);
  padding: var(--sp-2) var(--sp-3);
}
.btn-ghost:hover { color: var(--cu-4); }

.forge-btn { margin-left: auto; }
.clear-btn { margin-left: var(--sp-2); }

/* ── Crucible (drop target) ─────────────────────────────────────── */
.crucible {
  appearance: none;
  background: var(--surface-page);
  border: 2px dashed var(--border-strong);
  border-radius: var(--radius-lg);
  width: 100%;
  min-height: 168px;
  padding: var(--sp-5) calc(var(--sp-1) * 4.5);
  display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 12px;
  cursor: copy;
  color: var(--text-muted);
  font-family: var(--font-sans);
  transition: border-color var(--dur-base) var(--ease-standard), background var(--dur-base) var(--ease-standard),
              transform var(--dur-base) var(--ease-standard), box-shadow var(--dur-base) var(--ease-standard);
  position: relative;
}
.crucible:hover, .crucible:focus-visible {
  border-color: var(--cu-1);
  background: var(--cu-tint-1);
  outline: none;
}
.crucible:focus-visible {
  outline: 2px solid var(--cu-1); outline-offset: 3px;
}
.crucible[data-state="hover"] {
  border-style: solid;
  border-color: var(--cu-1);
  background: var(--cu-tint-1);
  transform: scale(1.01);
  box-shadow: var(--shadow-md);
}
.crucible[data-state="wrong"] {
  animation: crucibleshake var(--dur-320ms) var(--ease-standard);
  border-color: var(--cu-2);
  background: var(--cu-tint-1);
}
.crucible[data-state="pending"] {
  border-style: solid;
  border-color: var(--cu-1);
}
.crucible[data-state="pouring"]::before {
  content: ""; position: absolute; top: -6px; left: 50%; width: 24px; height: 24px;
  background: var(--cu-1); border-radius: 50%;
  transform: translate(-50%, -50%);
  animation: cruciblespark var(--dur-800ms) var(--ease-ease-out);
  pointer-events: none;
}
.crucible-glyph {
  display: block; transition: transform var(--dur-300ms) var(--ease-standard);
}
.crucible[data-state="hover"] .crucible-glyph { transform: translateY(-3px); }
.crucible-label {
  font-size: 0.84rem; font-weight: 600; color: var(--text-muted);
  letter-spacing: 0.02em;
}
.crucible[data-state="hover"] .crucible-label { color: var(--cu-4); }

@keyframes crucibleshake {
  0%, 100% { transform: translateX(0); }
  20% { transform: translateX(-8px) rotate(-0.4deg); }
  40% { transform: translateX(7px) rotate(0.4deg); }
  60% { transform: translateX(-5px); }
  80% { transform: translateX(4px); }
}
@keyframes cruciblespark {
  0% { opacity: 0; transform: translate(-50%, 0) scale(0.4); }
  30% { opacity: 1; transform: translate(-50%, -20px) scale(1.2); }
  100% { opacity: 0; transform: translate(-50%, -60px) scale(1.6); }
}

/* ── Status line ───────────────────────────────────────────────── */
.status-line {
  min-height: 22px;
  font-size: 0.84rem; color: var(--text-muted);
  font-style: italic;
  letter-spacing: 0.01em;
  padding: var(--sp-1) var(--sp-1) 0;
}
.status-line[data-tone="success"] { color: var(--state-success-text); }
.status-line[data-tone="hint"] { color: var(--cu-4); }
.status-line[data-tone="info"] { color: var(--text-muted); }

/* ── Progress meter ────────────────────────────────────────────── */
.progress-meter {
  margin-top: var(--sp-6);
  padding: calc(var(--sp-1) * 5.5) var(--sp-5);
  background: var(--surface-page); border: 1px solid var(--border-subtle);
  border-radius: var(--radius-lg);
}
.progress-title {
  font-family: var(--font-display); font-size: 0.86rem; font-weight: 600;
  color: var(--text-primary); margin-bottom: calc(var(--sp-1) * 3.5);
  letter-spacing: 0.04em;
}
.family-chips {
  display: flex; gap: 10px; flex-wrap: wrap;
}
.family-chip {
  display: inline-flex; align-items: center; gap: 8px;
  padding: calc(var(--sp-1) * 1.75) calc(var(--sp-1) * 3.5);
  background: var(--surface-raised);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-pill);
  font-size: 0.78rem; font-weight: 500; color: var(--text-muted);
  transition: background var(--dur-base), border-color var(--dur-base), color var(--dur-base);
}
.chip-dot {
  width: 8px; height: 8px; border-radius: 50%;
  background: var(--border-strong);
  transition: background var(--dur-base), box-shadow var(--dur-base);
}
.family-chip[data-lit="true"] {
  background: var(--cu-tint-1);
  border-color: var(--cu-1);
  color: var(--cu-4);
}
.family-chip[data-lit="true"] .chip-dot {
  background: var(--cu-1);
  box-shadow: 0 0 0 3px var(--cu-tint-3);
}
.progress-count {
  margin-top: var(--sp-3);
  font-size: 0.76rem; color: var(--text-faint);
  letter-spacing: 0.02em;
  font-family: var(--font-mono);
}

/* ── Alloy card (reveal) ───────────────────────────────────────── */
.card-section { padding: var(--section-py) 0 var(--section-py); }
.alloy-card {
  perspective: 1200px;
  width: 100%;
}
.alloy-card__inner {
  position: relative;
  display: grid;
  grid-template-columns: 1fr;
  width: 100%;
  min-height: 380px;
  transform-style: preserve-3d;
  transition: transform var(--dur-600ms) var(--ease-standard);
}
.alloy-card[data-state="flipped"] .alloy-card__inner {
  transform: rotateY(180deg);
}
.alloy-card__back, .alloy-card__front {
  grid-column: 1; grid-row: 1;
  backface-visibility: hidden;
  -webkit-backface-visibility: hidden;
  background: var(--surface-raised);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-lg);
  overflow: hidden;
  box-shadow: var(--shadow-md);
}
.alloy-card__back {
  transform: rotateY(180deg);
  display: flex; align-items: center; justify-content: center;
  padding: var(--sp-6);
  background: var(--bg-deep);
  color: var(--color-neutral-alpha-046);
}
.back-inner { text-align: center; }
.back-label {
  display: inline-block;
  font-size: 0.7rem; letter-spacing: 0.18em; text-transform: uppercase;
  color: var(--cu-1); margin-bottom: var(--sp-3);
}
.back-recipe {
  display: block;
  font-family: var(--font-mono); font-size: 1.4rem;
  color: var(--color-neutral-solid-024); font-weight: 600; letter-spacing: 0.02em;
}

.card-band {
  height: 84px;
  background: linear-gradient(135deg, var(--cu-1), var(--cu-2) 55%, var(--cu-4));
  position: relative;
}
.card-band[data-band="copper"]   { background: linear-gradient(135deg, var(--cu-0), var(--cu-2) 55%, var(--cu-4)); }
.card-band[data-band="brass"]    { background: linear-gradient(135deg, var(--color-amber-solid-015), var(--color-amber-solid-012) 55%, var(--color-amber-solid-005)); }
.card-band[data-band="bronze"]   { background: linear-gradient(135deg, var(--color-amber-solid-014), var(--color-amber-solid-010) 55%, var(--color-amber-solid-004)); }
.card-band[data-band="nickel"]   { background: linear-gradient(135deg, var(--color-neutral-solid-012), var(--color-neutral-solid-005) 55%, var(--color-blue-solid-014)); }
.card-band[data-band="phosphor"] { background: linear-gradient(135deg, var(--color-copper-solid-020), var(--color-copper-solid-016) 55%, var(--color-copper-solid-005)); }
.card-band[data-band="special"]  { background: linear-gradient(135deg, var(--color-amber-solid-011), var(--color-amber-solid-003) 55%, var(--color-amber-solid-001)); }

.card-body { padding: calc(var(--sp-1) * 7) calc(var(--sp-1) * 7.5) calc(var(--sp-1) * 6.5); }
.card-kicker {
  font-family: var(--font-mono); font-size: 0.78rem; font-weight: 500;
  color: var(--brand-text); letter-spacing: 0.04em; margin-bottom: calc(var(--sp-1) * 1.5);
}
.card-name {
  font-family: var(--font-display); font-size: clamp(1.6rem, 3vw, 2rem);
  font-weight: 600; letter-spacing: -0.025em; color: var(--text-primary);
  margin-bottom: var(--sp-2);
}
.card-desc {
  font-size: 0.96rem; color: var(--text-muted); line-height: var(--leading-normal);
  margin-bottom: calc(var(--sp-1) * 5.5); max-width: 560px;
}

/* Tablist */
.tablist-wrap { margin-top: var(--sp-2); }
.tablist {
  display: flex; gap: 4px; flex-wrap: wrap;
  border-bottom: 1px solid var(--border-subtle);
  margin-bottom: calc(var(--sp-1) * 4.5);
}
.tablist button {
  appearance: none; background: transparent; border: none;
  padding: calc(var(--sp-1) * 2.25) calc(var(--sp-1) * 3.5);
  font-family: var(--font-sans); font-size: 0.82rem; font-weight: 500;
  color: var(--text-muted); cursor: pointer;
  border-bottom: 2px solid transparent; margin-bottom: calc(var(--sp-1) * -0.25);
  border-radius: 0;
  transition: color var(--dur-160ms), border-color var(--dur-160ms), background var(--dur-160ms);
}
.tablist button:hover { color: var(--text-primary); background: var(--surface-page); }
.tablist button[aria-selected="true"] {
  color: var(--cu-4); border-bottom-color: var(--cu-1); font-weight: 600;
}
.tablist button:focus-visible {
  outline: 2px solid var(--cu-1); outline-offset: -3px;
}

.tab-panels { min-height: 64px; }
.tab-panels [role="tabpanel"] { animation: fadein var(--dur-base) var(--ease-ease); }
@keyframes fadein { from { opacity: 0; transform: translateY(4px); } to { opacity: 1; transform: none; } }

.bar-row {
  display: grid; grid-template-columns: 110px 1fr 110px; gap: 14px; align-items: center;
}
.bar-label { font-size: 0.84rem; color: var(--text-primary); font-weight: 500; }
.bar-track {
  display: block; height: 8px; background: var(--surface-page);
  border-radius: var(--radius-pill); overflow: hidden;
  border: 1px solid var(--border-subtle);
}
.bar-fill {
  display: block; height: 100%;
  background: linear-gradient(90deg, var(--cu-1), var(--cu-2));
  transition: width var(--dur-450ms) var(--ease-standard);
}
.bar-value {
  font-family: var(--font-mono); font-size: 0.84rem; font-weight: 600;
  color: var(--cu-4); text-align: right;
}
.uses-list {
  list-style: none; padding: 0; margin: 0;
  display: grid; gap: 8px;
}
.uses-list li {
  padding-left: calc(var(--sp-1) * 5.5); position: relative;
  font-size: 0.92rem; color: var(--text-primary); line-height: var(--leading-ratio-1_5);
}
.uses-list li::before {
  content: ""; position: absolute; left: 0; top: 8px;
  width: 12px; height: 2px;
  background: linear-gradient(90deg, var(--cu-1), transparent);
  border-radius: 2px;
}

.card-actions {
  display: flex; gap: 10px; flex-wrap: wrap;
  margin-top: calc(var(--sp-1) * 6.5); padding-top: calc(var(--sp-1) * 5.5);
  border-top: 1px solid var(--border-subtle);
}

/* ── Finish / completion card ──────────────────────────────────── */
.finish-section { padding-bottom: var(--sp-9); }
.finish-card {
  background: linear-gradient(135deg, var(--cu-tint-1), var(--color-blue-alpha-006));
  border: 1px solid var(--cu-1);
  border-radius: var(--radius-lg);
  padding: calc(var(--sp-1) * 11) calc(var(--sp-1) * 9);
  text-align: center;
  max-width: 720px; margin: 0 auto;
  box-shadow: var(--shadow-copper);
}
.finish-glyph {
  width: 64px; height: 64px; border-radius: 50%;
  background: var(--surface-raised); border: 2px solid var(--cu-1);
  display: inline-flex; align-items: center; justify-content: center;
  color: var(--cu-4);
  margin-bottom: var(--sp-4);
}
.finish-card h2 {
  font-family: var(--font-display); font-size: clamp(1.4rem, 3vw, 1.8rem);
  font-weight: 600; color: var(--text-primary); margin-bottom: calc(var(--sp-1) * 2.5);
}
.finish-card p {
  color: var(--text-muted); font-size: 0.96rem; max-width: 520px;
  margin: 0 auto calc(var(--sp-1) * 5.5); line-height: var(--leading-normal);
}
.finish-actions { display: flex; gap: 12px; justify-content: center; flex-wrap: wrap; }

/* ── Footer ────────────────────────────────────────────────────── */
.playground-footer {
  background: var(--bg-deep); color: var(--color-neutral-alpha-041);
  padding: var(--sp-6) 0; font-size: 0.8rem;
  border-top: 1px solid var(--border-dark);
}
.playground-footer-row {
  display: flex; justify-content: space-between; align-items: center;
  flex-wrap: wrap; gap: 16px;
}
.footer-logo {
  display: inline-flex; align-items: center; vertical-align: middle;
  margin-right: var(--sp-3);
}
.footer-logo img { display: block; height: 28px; width: auto; }
.completed-pill {
  display: inline-block;
  padding: var(--sp-1) var(--sp-3); border-radius: var(--radius-pill);
  background: var(--cu-tint-2); color: var(--cu-1);
  border: 1px solid var(--cu-line-strong);
  font-size: 0.72rem; font-weight: 600;
  letter-spacing: 0.04em;
}
.footer-links { display: flex; gap: 18px; }
.footer-links a { color: var(--color-neutral-alpha-043); text-decoration: none; }
.footer-links a:hover { color: var(--cu-1); }

/* ── Reveal (playground-only — uses IntersectionObserver fallback) ── */
.reveal { opacity: 0; transform: translateY(16px); transition: opacity var(--dur-700ms) var(--ease-standard), transform var(--dur-700ms) var(--ease-standard); }
.reveal.visible { opacity: 1; transform: none; }

/* ── Reduced motion gate ───────────────────────────────────────── */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation: none !important; transition: none !important; }
  .reveal { opacity: 1; transform: none; }
  .alloy-card[data-state="flipped"] .alloy-card__inner { transform: none; }
  .alloy-card__back { display: none; }
  .tab-panels [role="tabpanel"] { animation: none; }
  .crucible-glyph { transform: none !important; }
  #playground-ghost { display: none; }
}

/* ── Mobile 600px collapse ─────────────────────────────────────── */
@media (max-width: 600px) {
  .card-body { padding: calc(var(--sp-1) * 5.5) calc(var(--sp-1) * 4.5) calc(var(--sp-1) * 5); }
  .card-actions { flex-direction: column; align-items: stretch; }
  .bar-row { grid-template-columns: 1fr; gap: 6px; }
  .bar-value { text-align: left; }
  .recipe-toggles { flex-direction: column; align-items: flex-start; }
  .forge-btn { margin-left: 0; width: 100%; justify-content: center; }
  .clear-btn { margin-left: 0; }
}
