:root {
  color-scheme: dark;
  font-family: "Avenir Next", "Segoe UI", sans-serif;
  --bg-0: #09111b;
  --bg-1: #102036;
  --bg-2: #201339;
  --panel: rgba(10, 20, 36, 0.78);
  --border: rgba(160, 223, 255, 0.14);
  --text: #eef7ff;
  --muted: #9eb7d2;
  --accent: #85ffd2;
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  min-height: 100vh;
  color: var(--text);
  background:
    radial-gradient(circle at top left, rgba(91, 233, 255, 0.18), transparent 28%),
    radial-gradient(circle at right, rgba(255, 142, 210, 0.16), transparent 24%),
    linear-gradient(140deg, var(--bg-0), var(--bg-1) 46%, var(--bg-2));
}

.app {
  min-height: 100vh;
  display: grid;
  place-items: center;
  padding: 28px 18px;
}

.shell {
  width: min(1080px, 100%);
  display: grid;
  gap: 24px;
}

.hero {
  display: grid;
  gap: 10px;
}

.eyebrow {
  margin: 0;
  color: var(--accent);
  text-transform: uppercase;
  letter-spacing: 0.18em;
  font-size: 0.78rem;
}

.hero h1 {
  margin: 0;
  font-family: "Avenir Next Condensed", "Arial Narrow", sans-serif;
  font-size: clamp(3rem, 6vw, 5.2rem);
  letter-spacing: 0.06em;
  line-height: 0.92;
  text-transform: uppercase;
}

.hero p:last-child {
  margin: 0;
  color: var(--muted);
  max-width: 62ch;
  line-height: 1.6;
}

.grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 22px;
}

.card {
  display: grid;
  gap: 16px;
  padding: 24px;
  border-radius: 28px;
  background: var(--panel);
  border: 1px solid var(--border);
  box-shadow:
    0 24px 60px rgba(0, 0, 0, 0.24),
    inset 0 1px 0 rgba(255, 255, 255, 0.06);
  backdrop-filter: blur(16px);
}

.card h2,
.card p {
  margin: 0;
}

.card p {
  color: var(--muted);
  line-height: 1.6;
}

.preview {
  min-height: 180px;
  border-radius: 22px;
  position: relative;
  overflow: hidden;
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.06), transparent 24%),
    linear-gradient(135deg, rgba(74, 214, 255, 0.14), rgba(255, 122, 214, 0.12));
}

.preview::before,
.preview::after {
  content: "";
  position: absolute;
  inset: 20px;
  border-radius: 18px;
}

.preview--tetris::before {
  background:
    linear-gradient(180deg, rgba(8, 18, 33, 0.95), rgba(8, 18, 33, 0.8)),
    repeating-linear-gradient(
      90deg,
      transparent 0 26px,
      rgba(255, 255, 255, 0.03) 26px 28px
    );
}

.preview--tetris::after {
  inset: auto 34px 28px 34px;
  height: 70px;
  border-radius: 16px;
  background:
    linear-gradient(90deg, #4de3ff 0 25%, #ff74da 25% 50%, #ffca65 50% 75%, #6d8fff 75% 100%);
  box-shadow: 0 0 24px rgba(123, 210, 255, 0.3);
}

.preview--snake::before {
  background:
    radial-gradient(circle at 25% 30%, rgba(120, 255, 187, 0.42), transparent 12%),
    linear-gradient(180deg, rgba(255, 255, 255, 0.04), transparent 22%),
    #0f1d17;
}

.preview--snake::after {
  inset: auto 26px 30px 26px;
  height: 48px;
  border-radius: 999px;
  background: linear-gradient(90deg, #4cd080 0 70%, #8ff5ad 70% 100%);
  box-shadow: 0 0 18px rgba(111, 255, 170, 0.22);
}

.preview--2048::before {
  background:
    linear-gradient(180deg, rgba(8, 18, 33, 0.92), rgba(8, 18, 33, 0.78)),
    #101a2d;
}

.preview--2048::after {
  inset: 28px;
  background:
    linear-gradient(135deg, #9fdfff 0 33%, transparent 33%),
    linear-gradient(225deg, #ffca65 0 33%, transparent 33%),
    linear-gradient(315deg, #ff74da 0 33%, transparent 33%),
    linear-gradient(45deg, #8ea0ff 0 33%, transparent 33%);
  opacity: 0.9;
}

.preview--brick::before {
  background:
    linear-gradient(180deg, rgba(8, 18, 33, 0.94), rgba(8, 18, 33, 0.8)),
    #0f1c32;
}

.preview--brick::after {
  inset: 32px 28px 30px;
  background:
    linear-gradient(90deg, #7ceaff 0 20%, #89ffb3 20% 40%, #ffc977 40% 60%, #ff8aa4 60% 80%, #8ea0ff 80% 100%);
  height: 38px;
  top: 28px;
  bottom: auto;
  box-shadow:
    0 62px 0 -12px #7eeed5,
    140px 104px 0 -18px #ffd27f;
}

.preview--mine::before {
  background:
    linear-gradient(180deg, rgba(8, 18, 33, 0.94), rgba(8, 18, 33, 0.8)),
    #121a2e;
}

.preview--mine::after {
  inset: 30px;
  background:
    radial-gradient(circle at 24% 28%, #ff7b7b 0 8px, transparent 9px),
    linear-gradient(90deg, rgba(255,255,255,0.08) 0 100%),
    linear-gradient(rgba(255,255,255,0.08) 0 100%);
  background-size:
    auto,
    30px 2px,
    2px 30px;
  background-position:
    0 0,
    0 0,
    0 0;
}

.actions {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
}

.button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 13px 18px;
  border-radius: 16px;
  text-decoration: none;
  color: var(--text);
  background:
    linear-gradient(180deg, rgba(126, 235, 216, 0.18), rgba(38, 90, 109, 0.22)),
    rgba(255, 255, 255, 0.05);
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.12),
    0 10px 24px rgba(0, 0, 0, 0.2);
}

.button--ghost {
  background: rgba(255, 255, 255, 0.05);
}

.meta {
  color: var(--muted);
  font-size: 0.95rem;
}

@media (max-width: 800px) {
  .grid {
    grid-template-columns: 1fr;
  }
}
