:root {
  --bg: #f4f1ea;
  --surface: #fffdf8;
  --ink: #1f2a44;
  --muted: #6b7280;
  --line: #d9d3c4;
  --accent: #e0662f;
  --accent-ink: #fff;
  color-scheme: light;
}

@media (prefers-color-scheme: dark) {
  :root {
    --bg: #141a2a;
    --surface: #1d2539;
    --ink: #eef1f8;
    --muted: #97a0b5;
    --line: #2f3a55;
    --accent: #f08a4b;
    --accent-ink: #1a1206;
    color-scheme: dark;
  }
}

* { box-sizing: border-box; }

body {
  margin: 0 auto;
  max-width: 720px;
  min-height: 100vh;
  padding: max(24px, env(safe-area-inset-top)) 16px max(24px, env(safe-area-inset-bottom));
  display: flex;
  flex-direction: column;
  background: var(--bg);
  color: var(--ink);
  font-family: system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  line-height: 1.5;
}

a { color: inherit; }

.top { margin-bottom: 24px; }

.brand {
  display: inline-block;
  padding: 2px 10px;
  border-radius: 8px;
  background: var(--ink);
  color: var(--bg);
  font-weight: 800;
  letter-spacing: 0.04em;
  text-decoration: none;
}

h1 {
  margin: 12px 0 4px;
  font-size: clamp(2rem, 7vw, 2.75rem);
  line-height: 1.1;
}

.lead { margin: 0; color: var(--muted); }

main { flex: 1; }

.games {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  gap: 12px;
}

.card {
  display: flex;
  align-items: center;
  gap: 16px;
  padding: 16px;
  border: 1px solid var(--line);
  border-radius: 16px;
  background: var(--surface);
  text-decoration: none;
  transition: transform 0.12s ease, border-color 0.12s ease;
}

.card:hover, .card:focus-visible { border-color: var(--accent); }
.card:active { transform: scale(0.98); }
.card:focus-visible { outline: 3px solid var(--accent); outline-offset: 2px; }

.card img { flex: none; border-radius: 14px; }

.text { flex: 1; min-width: 0; display: flex; flex-direction: column; }
.name { font-size: 1.25rem; font-weight: 700; }
.desc { color: var(--muted); font-size: 0.95rem; }

.play {
  flex: none;
  padding: 8px 14px;
  border-radius: 999px;
  background: var(--accent);
  color: var(--accent-ink);
  font-weight: 700;
}

@media (max-width: 420px) {
  .card { flex-wrap: wrap; }
  .card img { width: 56px; height: 56px; }
  .text { flex-basis: calc(100% - 72px); }
  .play { width: 100%; text-align: center; }
}

.bottom {
  margin-top: 32px;
  color: var(--muted);
  font-size: 0.9rem;
  text-align: center;
}
