/* Hushful Volcano — one stylesheet for the whole site. Colours are tokens. The theme follows
   the visitor's system setting until they pick one with the button in the header, which sets
   data-theme="light" or "dark" on <html> (and remembers it). No web fonts: the system font is
   fast and private. */

:root {
  --bg: #faf3e0;
  --surface: #fffaf0;
  --ink: #2f3150;
  --ink-soft: #5d5f7a;
  --line: #e6dcc6;
  --accent: #c9962b;
  --accent-ink: #3d405b;
  --accent-bg: #f2c14e;
  --ember: #d9576b;
  --radius: 18px;
  --max: 1040px;
  color-scheme: light;
}

@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --bg: #1b1d2b;
    --surface: #24263a;
    --ink: #f1ead8;
    --ink-soft: #b9b4c8;
    --line: #34374f;
    --accent: #f2c14e;
    --accent-ink: #1b1d2b;
    --accent-bg: #f2c14e;
    --ember: #ee7a8b;
    color-scheme: dark;
  }
}

:root[data-theme="dark"] {
  --bg: #1b1d2b;
  --surface: #24263a;
  --ink: #f1ead8;
  --ink-soft: #b9b4c8;
  --line: #34374f;
  --accent: #f2c14e;
  --accent-ink: #1b1d2b;
  --accent-bg: #f2c14e;
  --ember: #ee7a8b;
  color-scheme: dark;
}

* { box-sizing: border-box; }

html { -webkit-text-size-adjust: 100%; }

body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font: 17px/1.6 system-ui, -apple-system, "Segoe UI", Roboto, "Noto Sans", Ubuntu, sans-serif;
}

a { color: var(--accent); text-underline-offset: 3px; }
a:hover { text-decoration-thickness: 2px; }

img { max-width: 100%; height: auto; display: block; }

.wrap { max-width: var(--max); margin: 0 auto; padding: 0 20px; }

/* Header and footer */

.site-header { border-bottom: 1px solid var(--line); }
.site-header .wrap { display: flex; align-items: center; justify-content: space-between; gap: 16px; min-height: 72px; }
.brand { display: flex; align-items: center; gap: 12px; color: var(--ink); text-decoration: none; font-weight: 700; letter-spacing: 0.02em; }
.brand svg { width: 48px; height: 48px; flex: none; }
.site-nav { display: flex; gap: 20px; font-size: 15px; }
.site-nav a { color: var(--ink-soft); text-decoration: none; }
.site-nav a:hover, .site-nav a[aria-current="page"] { color: var(--ink); }
.site-nav { align-items: center; }

/* The light/dark switch: shows the moon in light mode and the sun in dark mode. */
.theme-toggle {
  display: inline-flex; align-items: center; justify-content: center; width: 38px; height: 38px;
  border: 1px solid var(--line); border-radius: 999px; background: var(--surface); color: var(--ink);
  cursor: pointer; padding: 0;
}
.theme-toggle:hover { border-color: var(--accent); }
.theme-toggle svg { width: 20px; height: 20px; }
.theme-toggle .sun { display: none; }
:root[data-theme="dark"] .theme-toggle .sun { display: block; }
:root[data-theme="dark"] .theme-toggle .moon { display: none; }
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) .theme-toggle .sun { display: block; }
  :root:not([data-theme="light"]) .theme-toggle .moon { display: none; }
}

.site-footer { border-top: 1px solid var(--line); margin-top: 72px; padding: 28px 0 40px; color: var(--ink-soft); font-size: 14px; }
.site-footer .wrap { display: flex; flex-wrap: wrap; gap: 8px 24px; justify-content: space-between; }
.site-footer a { color: var(--ink-soft); }

/* Studio home */

.hero { padding: 72px 0 40px; }
.hero h1 { font-size: clamp(34px, 6vw, 56px); line-height: 1.1; margin: 0 0 16px; letter-spacing: -0.01em; }
.hero p { font-size: clamp(17px, 2.2vw, 20px); color: var(--ink-soft); margin: 0; }

.section-title { font-size: 14px; letter-spacing: 0.12em; text-transform: uppercase; color: var(--ink-soft); margin: 48px 0 16px; }

.games { display: grid; grid-template-columns: repeat(auto-fill, minmax(280px, 1fr)); gap: 20px; }
.game-card {
  display: flex; gap: 18px; align-items: center; padding: 20px;
  background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius);
  color: var(--ink); text-decoration: none; transition: transform 0.15s ease, border-color 0.15s ease;
}
.game-card:hover { transform: translateY(-2px); border-color: var(--accent); }
.game-card img { width: 88px; height: 88px; border-radius: 20px; flex: none; }
.game-card h3 { margin: 0 0 4px; font-size: 20px; }
.game-card p { margin: 0; color: var(--ink-soft); font-size: 15px; line-height: 1.45; }

/* A game card says what kind of game it is (tag) and where it stands (badge). */
.tags { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 8px; }
.badge, .tag { display: inline-block; font-size: 12px; font-weight: 600; padding: 2px 10px; border-radius: 999px; }
.badge { background: var(--accent-bg); color: var(--accent-ink); }
.tag { border: 1px solid var(--line); color: var(--ink-soft); }

/* Game page */

.game-hero { display: grid; grid-template-columns: 140px 1fr; gap: 28px; align-items: center; padding: 56px 0 24px; }
.game-hero img { width: 140px; height: 140px; border-radius: 32px; box-shadow: 0 8px 28px rgb(0 0 0 / 0.18); }
.game-hero h1 { margin: 0 0 6px; font-size: clamp(32px, 5vw, 48px); line-height: 1.1; }
.game-hero .tagline { margin: 0; font-size: 19px; color: var(--ink-soft); }

.store-row { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 18px; }
.button {
  display: inline-flex; align-items: center; gap: 8px; padding: 12px 20px; border-radius: 12px;
  background: var(--accent-bg); color: var(--accent-ink); font-weight: 650; text-decoration: none;
}
.button[aria-disabled="true"] { opacity: 0.6; cursor: default; }

.prose { max-width: none; }
.prose h2 { font-size: 24px; margin: 40px 0 10px; }
.prose h3 { font-size: 19px; margin: 28px 0 6px; }
.prose ul { padding-left: 1.2em; }
.prose li { margin: 4px 0; }

.shots { display: flex; gap: 16px; overflow-x: auto; padding: 8px 2px 16px; scroll-snap-type: x mandatory; }
.shots img { width: 220px; flex: none; border-radius: 16px; border: 1px solid var(--line); scroll-snap-align: start; }

.features { display: grid; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); gap: 16px; margin: 8px 0 0; padding: 0; list-style: none; }
.features li { background: var(--surface); border: 1px solid var(--line); border-radius: 14px; padding: 14px 16px; }
.features strong { display: block; margin-bottom: 2px; }

/* Legal pages */

.legal { padding-top: 40px; }
.legal h1 { font-size: clamp(30px, 5vw, 40px); margin: 0 0 6px; }
.legal .meta { color: var(--ink-soft); margin: 0 0 24px; }
.summary { background: var(--surface); border: 1px solid var(--line); border-left: 4px solid var(--accent); border-radius: 12px; padding: 14px 18px; }

@media (max-width: 560px) {
  .site-nav { gap: 14px; }
  .game-hero { grid-template-columns: 1fr; gap: 18px; padding-top: 36px; }
  .game-hero img { width: 112px; height: 112px; border-radius: 26px; }
  .shots img { width: 180px; }
}

@media (prefers-reduced-motion: reduce) {
  .game-card { transition: none; }
  .game-card:hover { transform: none; }
}
