/* Standalone stylesheet for maxlearns.com games.
   The palette below is duplicated from src/styles/tokens.css by design — this file
   must work when a game is opened directly from the filesystem, so it cannot import
   anything outside public/. Keep both files in sync by hand.
   If this file fails to load, games must still be fully functional, just unstyled. */

:root {
  /* Base palette */
  --bg: #0A0E17;
  --card: #111826;
  --border: #232E45;
  --text: #DCE4F0;
  --muted: #6B7A99;

  /* Subject accents */
  --accent-math: #3B82F6;
  --accent-physics: #F59E0B;
  --accent-chem: #10B981;
  --accent-space: #8B5CF6;
  --accent-sound: #EC4899;
  --accent-bio: #84CC16;
  --accent-spelling: #06B6D4;

  /* Difficulty dots */
  --difficulty-explore: #10B981;
  --difficulty-learn: #3B82F6;
  --difficulty-challenge: #8B5CF6;

  /* Type */
  --sans: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
  --mono: ui-monospace, SFMono-Regular, Menlo, monospace;

  /* Spacing scale */
  --space-1: 4px;
  --space-2: 8px;
  --space-3: 12px;
  --space-4: 16px;
  --space-5: 24px;
  --space-6: 32px;
  --space-7: 48px;
  --space-8: 64px;

  /* Radii */
  --radius-control: 12px;
  --radius-card: 20px;

  /* Shadows */
  --shadow-card-hover: 0 12px 32px rgba(0, 0, 0, 0.4);
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

html,
body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font-family: var(--sans);
}

:focus-visible {
  outline: 2px solid var(--accent-math);
  outline-offset: 2px;
}

/* Shared game chrome */

.card {
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: var(--radius-card);
  padding: var(--space-5);
  transition: transform 0.15s ease, box-shadow 0.15s ease;
}

.card:hover {
  transform: translateY(-4px) scale(1.02);
  box-shadow: var(--shadow-card-hover);
}

.panel {
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: var(--radius-card);
  padding: var(--space-5);
}

.btn {
  font-family: var(--sans);
  font-size: 0.95rem;
  font-weight: 600;
  color: var(--text);
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: var(--radius-control);
  padding: var(--space-2) var(--space-4);
  cursor: pointer;
  transition: border-color 0.15s ease, transform 0.15s ease;
}

.btn:hover {
  border-color: var(--accent-math);
}

.btn:active {
  transform: translateY(1px);
}

.btn-primary {
  background: var(--accent-math);
  border-color: var(--accent-math);
  color: #fff;
}

.slider {
  width: 100%;
  accent-color: var(--accent-math);
}

.badge {
  display: inline-flex;
  align-items: center;
  gap: var(--space-1);
  font-size: 0.75rem;
  font-weight: 600;
  color: var(--muted);
  background: var(--bg);
  border: 1px solid var(--border);
  border-radius: 999px;
  padding: var(--space-1) var(--space-3);
}

.dot {
  display: inline-block;
  width: 8px;
  height: 8px;
  border-radius: 50%;
}

.dot-explore { background: var(--difficulty-explore); }
.dot-learn { background: var(--difficulty-learn); }
.dot-challenge { background: var(--difficulty-challenge); }

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    transition: none !important;
    animation: none !important;
  }
}
