:root {
  --bg: #f4efe3;
  --bg-strong: #efe3cb;
  --surface: rgba(255, 250, 239, 0.9);
  --surface-strong: rgba(255, 248, 233, 0.96);
  --ink: #15202a;
  --ink-soft: #4e5d68;
  --line: rgba(21, 32, 42, 0.12);
  --brand: #ff6f3c;
  --brand-deep: #c84e23;
  --teal: #12687b;
  --lime: #a8d66f;
  --gold: #d59d34;
  --major: #12455f;
  --minor: #5f7f3b;
  --active: #b44f2d;
  --next: #c38818;
  --later: #5d6f7c;
  --shadow: 0 22px 60px rgba(41, 51, 62, 0.14);
  --radius-xl: 30px;
  --radius-lg: 22px;
  --radius-md: 16px;
  --radius-sm: 12px;
  --content-width: min(1180px, calc(100vw - 32px));
}

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

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  font-family: "IBM Plex Sans", sans-serif;
  color: var(--ink);
  background:
    radial-gradient(circle at top left, rgba(255, 111, 60, 0.22), transparent 28%),
    radial-gradient(circle at top right, rgba(18, 104, 123, 0.18), transparent 24%),
    linear-gradient(180deg, #faf5e9 0%, var(--bg) 56%, #f9f2e2 100%);
  min-height: 100vh;
}

body::before {
  content: "";
  position: fixed;
  inset: 0;
  background-image:
    linear-gradient(rgba(21, 32, 42, 0.035) 1px, transparent 1px),
    linear-gradient(90deg, rgba(21, 32, 42, 0.035) 1px, transparent 1px);
  background-size: 34px 34px;
  mask-image: linear-gradient(180deg, rgba(0, 0, 0, 0.9), transparent 92%);
  pointer-events: none;
  z-index: -1;
}

a {
  color: inherit;
  text-decoration: none;
}

button,
select {
  font: inherit;
}

.site-shell {
  width: var(--content-width);
  margin: 0 auto;
  padding: 18px 0 44px;
}

.topbar {
  position: sticky;
  top: 14px;
  z-index: 10;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  padding: 16px 18px;
  background: rgba(252, 246, 233, 0.88);
  border: 1px solid rgba(21, 32, 42, 0.1);
  border-radius: 999px;
  backdrop-filter: blur(16px);
  box-shadow: 0 14px 40px rgba(44, 44, 44, 0.08);
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  font-family: "Space Grotesk", sans-serif;
  font-weight: 700;
  letter-spacing: -0.03em;
}

.brand__mark {
  display: inline-grid;
  place-items: center;
  width: 42px;
  height: 42px;
  border-radius: 14px;
  background: linear-gradient(135deg, var(--brand), #ffaf52);
  color: white;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.3);
}

.nav {
  display: flex;
  flex-wrap: wrap;
  gap: 18px;
  color: var(--ink-soft);
}

.nav a {
  transition: color 160ms ease;
}

.nav a:hover,
.nav a:focus-visible,
.text-link:hover,
.text-link:focus-visible {
  color: var(--brand-deep);
}

.hero {
  display: grid;
  gap: 24px;
  margin-top: 26px;
}

.hero--home,
.hero--game {
  grid-template-columns: minmax(0, 1.2fr) minmax(320px, 0.8fr);
  align-items: stretch;
}

.hero__copy,
.hero-panel,
.panel,
.feature-card,
.game-card,
.stat-card,
.filters-panel,
.note-band,
.sync-band {
  border: 1px solid rgba(21, 32, 42, 0.1);
  background: var(--surface);
  border-radius: var(--radius-xl);
  box-shadow: var(--shadow);
}

.hero__copy {
  padding: clamp(26px, 4vw, 48px);
  background:
    linear-gradient(145deg, rgba(255, 255, 255, 0.62), rgba(255, 247, 227, 0.84)),
    linear-gradient(120deg, rgba(18, 104, 123, 0.07), rgba(255, 111, 60, 0.08));
}

.hero-panel {
  padding: 28px;
  background:
    radial-gradient(circle at top right, rgba(168, 214, 111, 0.24), transparent 32%),
    var(--surface-strong);
}

.eyebrow,
.panel-kicker {
  margin: 0 0 14px;
  text-transform: uppercase;
  letter-spacing: 0.16em;
  font-size: 0.75rem;
  font-weight: 600;
  color: var(--teal);
}

h1,
h2,
h3 {
  margin: 0;
  font-family: "Space Grotesk", sans-serif;
  letter-spacing: -0.04em;
  line-height: 0.98;
}

h1 {
  font-size: clamp(3rem, 8vw, 6.2rem);
  max-width: 11ch;
}

h2 {
  font-size: clamp(2rem, 4vw, 3.2rem);
}

h3 {
  font-size: 1.55rem;
}

.lede,
.panel-copy,
.feature-card p,
.game-card p,
.sync-band p,
.note-band p,
.not-found p {
  margin: 18px 0 0;
  font-size: 1.08rem;
  line-height: 1.72;
  color: var(--ink-soft);
}

.cta-row {
  display: flex;
  flex-wrap: wrap;
  gap: 14px;
  margin-top: 28px;
}

.button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 52px;
  padding: 0 20px;
  border-radius: 999px;
  border: 1px solid transparent;
  cursor: pointer;
  transition:
    transform 160ms ease,
    border-color 160ms ease,
    background-color 160ms ease,
    color 160ms ease;
}

.button:hover,
.button:focus-visible {
  transform: translateY(-1px);
}

.button--primary {
  background: linear-gradient(135deg, var(--brand), #ff9654);
  color: white;
}

.button--ghost {
  background: rgba(255, 255, 255, 0.48);
  border-color: rgba(21, 32, 42, 0.14);
  color: var(--ink);
}

.signal-row,
.tag-row,
.chip-row {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.signal-row {
  margin-top: 24px;
}

.signal-row span,
.tag,
.status-chip {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  min-height: 34px;
  padding: 0 12px;
  border-radius: 999px;
  border: 1px solid rgba(21, 32, 42, 0.1);
  background: rgba(255, 255, 255, 0.5);
  color: var(--ink-soft);
  font-size: 0.92rem;
}

.metric-strip,
.stats-grid,
.filter-grid,
.dual-panel,
.feature-grid,
.launch-grid {
  display: grid;
  gap: 18px;
}

.metric-strip {
  grid-template-columns: repeat(3, minmax(0, 1fr));
  margin-top: 24px;
}

.metric-strip strong,
.stat-card strong {
  display: block;
  margin-top: 8px;
  font-size: clamp(1.75rem, 4vw, 2.5rem);
  font-family: "Space Grotesk", sans-serif;
}

.metric-label {
  color: var(--ink-soft);
  font-size: 0.92rem;
}

.preview-stack {
  display: grid;
  gap: 12px;
  margin-top: 24px;
}

.preview-card,
.schedule-card,
.stack-card {
  padding: 16px 18px;
  border-radius: var(--radius-md);
  background: rgba(255, 255, 255, 0.66);
  border: 1px solid rgba(21, 32, 42, 0.08);
}

.preview-card__top,
.schedule-card__top,
.stack-card__top,
.panel-header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
}

.preview-card__title,
.event-title,
.stack-card__title {
  margin: 0;
  font-size: 1.08rem;
  font-weight: 600;
}

.preview-card__meta,
.event-meta,
.stack-card__meta,
.results-copy,
.snapshot-note,
.feed-url {
  margin: 6px 0 0;
  color: var(--ink-soft);
  line-height: 1.58;
}

.preview-placeholder,
.empty-state {
  padding: 18px;
  border-radius: var(--radius-md);
  background: rgba(255, 255, 255, 0.56);
  color: var(--ink-soft);
  border: 1px dashed rgba(21, 32, 42, 0.16);
}

.text-link {
  display: inline-flex;
  margin-top: 22px;
  color: var(--brand-deep);
  font-weight: 600;
}

.section {
  margin-top: 26px;
}

.section-heading {
  max-width: 760px;
  margin-bottom: 18px;
}

.section-heading--tight {
  margin-bottom: 16px;
}

.feature-grid {
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

.feature-card,
.game-card,
.note-band,
.sync-band,
.filters-panel,
.panel,
.stat-card {
  padding: 24px;
}

.launch-grid {
  grid-template-columns: 1.25fr 1fr 1fr;
}

.game-card--featured {
  background:
    linear-gradient(150deg, rgba(255, 255, 255, 0.64), rgba(255, 239, 222, 0.9)),
    linear-gradient(120deg, rgba(255, 111, 60, 0.08), rgba(18, 104, 123, 0.1));
}

.spotlight .game-card__header,
.game-card__header {
  display: grid;
  gap: 8px;
}

.note-band,
.sync-band {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  background:
    linear-gradient(115deg, rgba(255, 255, 255, 0.66), rgba(255, 243, 224, 0.92)),
    linear-gradient(140deg, rgba(168, 214, 111, 0.18), rgba(255, 111, 60, 0.12));
}

.note-band__copy,
.sync-band__copy {
  max-width: 760px;
}

.stats-grid {
  grid-template-columns: repeat(4, minmax(0, 1fr));
  margin-top: 26px;
}

.stat-card {
  background: rgba(255, 255, 255, 0.58);
}

.filters-panel {
  background: rgba(255, 250, 238, 0.78);
}

.filter-grid {
  grid-template-columns: repeat(4, minmax(0, 1fr));
}

.field {
  display: grid;
  gap: 10px;
  color: var(--ink-soft);
  font-size: 0.94rem;
}

.field select {
  width: 100%;
  min-height: 50px;
  padding: 0 14px;
  border-radius: 14px;
  border: 1px solid rgba(21, 32, 42, 0.12);
  background: rgba(255, 255, 255, 0.76);
  color: var(--ink);
}

.dual-panel {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.panel--wide {
  width: 100%;
}

.stack-list,
.schedule-grid {
  display: grid;
  gap: 14px;
  margin-top: 18px;
}

.schedule-grid {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.pill {
  display: inline-flex;
  align-items: center;
  min-height: 32px;
  padding: 0 11px;
  border-radius: 999px;
  font-size: 0.83rem;
  text-transform: uppercase;
  letter-spacing: 0.12em;
  font-weight: 600;
}

.pill--major {
  background: rgba(18, 69, 95, 0.1);
  color: var(--major);
}

.pill--minor {
  background: rgba(95, 127, 59, 0.13);
  color: var(--minor);
}

.pill--active {
  background: rgba(180, 79, 45, 0.12);
  color: var(--active);
}

.pill--next {
  background: rgba(213, 157, 52, 0.14);
  color: var(--next);
}

.pill--later {
  background: rgba(93, 111, 124, 0.11);
  color: var(--later);
}

.meta-row {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 10px;
}

.meta-row span {
  color: var(--ink-soft);
  font-size: 0.93rem;
}

.sync-band__actions {
  min-width: min(100%, 360px);
}

.feed-url {
  font-family: ui-monospace, "SFMono-Regular", Consolas, monospace;
  word-break: break-word;
}

.footer {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 14px;
  margin-top: 28px;
  padding: 12px 4px 0;
  color: var(--ink-soft);
}

.not-found {
  display: grid;
  place-items: center;
  min-height: calc(100vh - 120px);
  text-align: center;
}

[data-reveal] {
  opacity: 0;
  transform: translateY(22px);
  transition:
    opacity 520ms ease,
    transform 520ms ease;
}

[data-reveal].is-visible {
  opacity: 1;
  transform: translateY(0);
}

@media (max-width: 1080px) {
  .hero--home,
  .hero--game,
  .launch-grid,
  .stats-grid,
  .feature-grid,
  .filter-grid,
  .dual-panel,
  .schedule-grid {
    grid-template-columns: 1fr;
  }

  .note-band,
  .sync-band {
    flex-direction: column;
    align-items: flex-start;
  }
}

@media (max-width: 760px) {
  .site-shell {
    width: min(100vw - 20px, 100%);
    padding-top: 12px;
  }

  .topbar {
    position: static;
    border-radius: 22px;
    align-items: flex-start;
    flex-direction: column;
  }

  h1 {
    font-size: clamp(2.8rem, 16vw, 4.5rem);
  }

  h2 {
    font-size: clamp(1.9rem, 8vw, 2.6rem);
  }

  .hero__copy,
  .hero-panel,
  .feature-card,
  .game-card,
  .note-band,
  .sync-band,
  .filters-panel,
  .panel,
  .stat-card {
    padding: 20px;
  }

  .metric-strip {
    grid-template-columns: 1fr;
  }
}
