/* Direction: neon arcade — deep indigo night, hot pink accent, geometric display */
/* Completed by the platform from the short form: both modes, every
   palette token, each text-on-ground pair at its floor. To restyle, write the
   short form again (the decisions in one :root) and it is completed again. */

:root {
  color-scheme: dark;
  --canvas: #130f26;
  --surface: #2b273c;
  --surface-2: #1f1b31;
  --border: #343144;
  --border-strong: #5a5767;
  --ink: #f1ecff;
  --muted: #9894a8;
  --accent: #ff4f8b;
  --accent-hover: #ff699c;
  --accent-ink: #130f26;
  --accent-text: #ff7aa8;
  --accent-strong: #ff5d94;
  --accent-soft: #471d3c;
  --accent-border: #7d2c53;
  --success: #15803d;
  --success-ink: #ffffff;
  --success-soft: #13282b;
  --success-strong: #499c68;
  --warning: #b45309;
  --warning-ink: #ffffff;
  --warning-soft: #361e20;
  --warning-strong: #c57a40;
  --danger: #b91c1c;
  --danger-ink: #ffffff;
  --danger-soft: #381224;
  --danger-strong: #d16969;
  --chart-1: #ff4f8b;
  --chart-2: #ff9c21;
  --chart-3: #71901a;
  --chart-4: #1bcbba;
  --chart-5: #1687ce;
  --chart-6: #c79bfc;

  --font-display: "Space Grotesk", system-ui, sans-serif;
  --font-body: "Inter", system-ui, sans-serif;
  --font-mono: "JetBrains Mono", ui-monospace, monospace;
  --display-weight: 700;
  --display-tracking: -0.03em;
  --radius-card: 18px;
  --radius-btn: 12px;
  --font-sans: "Inter", system-ui, sans-serif;
  --eyebrow-tracking: 0.08em;
}

html[data-theme="light"] {
  color-scheme: light;
  --canvas: #ffffff;
  --surface: #ffffff;
  --surface-2: #f3f3f4;
  --border: #dedde1;
  --border-strong: #b8b7be;
  --ink: #130f26;
  --muted: #686673;
  --accent: #ff4f8b;
  --accent-hover: #d94376;
  --accent-ink: #130f26;
  --accent-text: #b73964;
  --accent-strong: #b73964;
  --accent-soft: #ffe6ef;
  --accent-border: #ffb0cb;
  --success: #15803d;
  --success-ink: #ffffff;
  --success-soft: #e3f0e8;
  --success-strong: #137638;
  --warning: #b45309;
  --warning-ink: #ffffff;
  --warning-soft: #f6eae1;
  --warning-strong: #a64c08;
  --danger: #b91c1c;
  --danger-ink: #ffffff;
  --danger-soft: #f7e4e4;
  --danger-strong: #b91c1c;
  --chart-1: #ff4f8b;
  --chart-2: #cd7d1a;
  --chart-3: #71901a;
  --chart-4: #13a294;
  --chart-5: #1486cd;
  --chart-6: #b472f9;
}

.stat { display: flex; flex-direction: column; gap: 2px; padding: 12px 14px; border: 1px solid var(--border); border-radius: 14px; background: var(--surface); }
.stat-label { font-size: 12px; text-transform: uppercase; letter-spacing: 0.08em; color: var(--muted); }
.stat-value { font-family: var(--font-mono); font-size: 1.5rem; font-weight: 600; }

.tile { aspect-ratio: 1 / 1; perspective: 700px; border: 0; padding: 0; background: none; cursor: pointer; border-radius: 16px; }
.tile:focus-visible { outline: 3px solid var(--accent-text); outline-offset: 2px; }
.tile-inner { position: relative; display: block; width: 100%; height: 100%; transform-style: preserve-3d; transition: transform 0.35s ease; }
.tile-face { position: absolute; inset: 0; display: flex; align-items: center; justify-content: center; border-radius: 16px; backface-visibility: hidden; -webkit-backface-visibility: hidden; border: 1px solid var(--border); }
.tile-front { background: var(--surface-2); color: var(--muted); transition: background 0.2s; }
.tile:hover .tile-front { background: var(--accent-soft); color: var(--accent-text); }
.tile-back { transform: rotateY(180deg); background: var(--surface); color: var(--accent-text); }
.tile.is-flipped .tile-inner { transform: rotateY(180deg); }
.tile.is-matched .tile-back { background: var(--accent); color: var(--accent-ink); border-color: var(--accent); }
.tile.is-matched { cursor: default; animation: pop 0.4s ease; }
@keyframes pop { 0% { scale: 1; } 50% { scale: 1.08; } 100% { scale: 1; } }
html.reduced-motion .tile-inner, html.reduced-motion .tile { transition: none; animation: none; }
