@charset "UTF-8";

:root {
  color-scheme: dark;
  font-family: Inter, "Segoe UI", system-ui, sans-serif;
  color: #fff;
  background: #0b1422;
  --muted: #b3c3d4;
  --line: #ffffff24;
  --accent: #b4dfeb;
  --edge: max(5vw, 1.25rem);
}

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

html { scroll-behavior: smooth; }

body {
  min-width: 0;
  min-height: 100vh;
  min-height: 100svh;
  margin: 0;
  background:
    radial-gradient(ellipse at 88% 24%, #214758 0, transparent 49%),
    radial-gradient(ellipse at 16% 60%, #172137 0, transparent 62%),
    linear-gradient(155deg, #0d1422, #0b1827 65%, #101a29);
}

a { color: inherit; text-decoration: none; }
button { font: inherit; }
:focus-visible { outline: 2px solid var(--accent); outline-offset: 4px; }
[hidden] { display: none !important; }

.wrap {
  width: min(100%, 82rem);
  margin-inline: auto;
  padding-inline-start: max(var(--edge), env(safe-area-inset-left));
  padding-inline-end: max(var(--edge), env(safe-area-inset-right));
}

.site-header { border-bottom: 1px solid var(--line); }

.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: .25rem 1.5rem;
  padding-block: .875rem;
  padding-block-start: max(.875rem, env(safe-area-inset-top));
}

.wordmark {
  display: inline-flex;
  align-items: center;
  min-height: 2.75rem;
  font-size: 1.125rem;
  font-weight: 700;
  letter-spacing: -.035em;
  white-space: nowrap;
}

.navigation, .languages, .scroll-controls {
  display: flex;
  align-items: center;
}

.navigation { gap: clamp(.75rem, 3vw, 2.5rem); }
.languages { gap: .125rem; }

.text-button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 2.75rem;
  padding: 0;
  border: 0;
  background: transparent;
  color: #fff;
  font-size: .875rem;
  font-weight: 600;
  text-underline-offset: .42em;
  cursor: pointer;
}

.text-button:hover, .text-button[aria-current] { text-decoration: underline; }
.text-button[aria-current] { text-decoration-color: var(--accent); }
.languages .text-button { min-width: 2.75rem; }

.intro {
  display: grid;
  align-content: center;
  min-height: clamp(14rem, 43svh, 29rem);
  padding-block: clamp(2.625rem, 8vw, 6.5rem);
}

.intro h1 {
  margin: 0;
  font-size: clamp(3.25rem, 8.6vw, 7.25rem);
  font-weight: 680;
  letter-spacing: -.075em;
  line-height: .99;
  overflow-wrap: anywhere;
}

.intro p, .game-copy p {
  margin: 1rem 0 0;
  color: var(--muted);
  font-size: clamp(1rem, 1.5vw, 1.125rem);
  line-height: 1.5;
}

.games {
  border-top: 1px solid var(--line);
  padding-block: 1.5rem max(2.75rem, env(safe-area-inset-bottom));
  scroll-margin-top: 1rem;
}

.section-heading {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: .375rem 1rem;
  margin-bottom: 1.125rem;
}

.section-heading h2 {
  margin: 0;
  font-size: clamp(1.375rem, 3vw, 2rem);
  font-weight: 660;
  letter-spacing: -.045em;
}

.scroll-controls { gap: 1rem; }
.scroll-controls :disabled { color: var(--muted); opacity: .65; cursor: default; text-decoration: none; }

.games-list {
  display: grid;
  grid-auto-flow: column;
  grid-auto-columns: clamp(15rem, 68%, 29rem);
  gap: .875rem;
  margin: 0;
  padding: 0 0 .625rem;
  overflow-x: auto;
  scrollbar-color: #6a929e transparent;
  scroll-snap-type: x proximity;
  list-style: none;
}

.games-list > li { min-width: 0; scroll-snap-align: start; }

.game-card, .game-feature-panel {
  background:
    radial-gradient(ellipse at 85% 18%, #457885 0, transparent 54%),
    radial-gradient(ellipse at 82% 47%, #254755 0, transparent 71%),
    linear-gradient(158deg, #233a4a, #101926 70%);
  border: 1px solid var(--line);
  border-radius: .875rem;
}

.game-card {
  display: flex;
  align-items: flex-end;
  min-height: clamp(9.5rem, 18vw, 13.5rem);
  padding: clamp(1rem, 3vw, 1.75rem);
  transition: border-color .16s ease;
}

.game-card:hover { border-color: #b4dfeb99; }
.game-card:focus-visible { outline-offset: -4px; }
.game-copy h3 { margin: 0; font-size: clamp(1.5rem, 3vw, 2rem); letter-spacing: -.045em; }
.game-copy p { margin-top: .25rem; }

.game-page { padding-block: clamp(1.5rem, 6vw, 4.5rem); }
.game-feature-panel { padding-inline: clamp(1.25rem, 6vw, 4.5rem); }
.game-feature-panel h1 { font-size: clamp(2.75rem, 8.6vw, 7.25rem); }

@media (max-width: 34rem) {
  .games-list { grid-auto-columns: min(100%, 29rem); }
  .games-list:has(> li:nth-child(2)) { grid-auto-columns: 87%; }
}

@media (max-width: 24rem) {
  .header-inner { gap: 0 .75rem; }
  .wordmark { font-size: 1rem; }
  .navigation { gap: .375rem; }
  .languages { gap: 0; }
  .languages .text-button { min-width: 2.25rem; }
}

@media (orientation: landscape) and (max-height: 32rem) {
  .header-inner { padding-block-end: .375rem; padding-block-start: max(.375rem, env(safe-area-inset-top)); }
  .intro { min-height: 0; padding-block: clamp(2rem, 9svh, 3.5rem); }
  .intro h1 { font-size: clamp(2.75rem, 9svh, 4.5rem); }
  .games { padding-top: 1rem; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .game-card { transition: none; }
}
