/* ==========================================================================
   Lexiclix — Official Website Stylesheet
   Warm tactile tabletop puzzle aesthetic tailored to Lexiclix's letter tiles
   ========================================================================== */

:root {
  /* Curated HSL Palette — Alabaster Parchment, Forest Emerald, Crimson Ink & Brass */
  --bg-canvas: hsl(42, 33%, 94%);
  --bg-canvas-deep: hsl(40, 26%, 89%);
  --surface-paper: hsl(44, 50%, 98%);
  --surface-tile: hsl(46, 56%, 96%);
  --surface-stage: hsl(152, 16%, 10%);
  --surface-stage-elevated: hsl(152, 14%, 15%);

  --ink-primary: hsl(148, 18%, 12%);
  --ink-secondary: hsl(148, 10%, 33%);
  --ink-muted: hsl(148, 8%, 48%);
  --ink-on-dark: hsl(42, 30%, 95%);
  --ink-on-dark-muted: hsl(148, 12%, 72%);

  --accent-emerald: hsl(150, 56%, 27%);
  --accent-emerald-hover: hsl(150, 58%, 21%);
  --accent-emerald-soft: hsla(150, 52%, 27%, 0.1);
  --accent-crimson: hsl(5, 65%, 44%);
  --accent-brass: hsl(38, 76%, 44%);
  --accent-brass-soft: hsla(38, 76%, 44%, 0.14);

  --border-subtle: hsla(148, 20%, 15%, 0.11);
  --border-strong: hsla(148, 20%, 15%, 0.2);
  --border-dark: hsla(42, 30%, 95%, 0.14);

  /* Tactile Depth & Shadows */
  --shadow-tile:
    0 1px 0 hsla(0, 0%, 100%, 0.85) inset,
    0 3px 0 hsl(150, 40%, 24%),
    0 6px 14px hsla(148, 24%, 12%, 0.14);
  --shadow-card:
    0 1px 0 hsla(0, 0%, 100%, 0.9) inset,
    0 1px 2px hsla(148, 20%, 12%, 0.06),
    0 10px 28px hsla(148, 20%, 12%, 0.07);
  --shadow-card-hover:
    0 1px 0 hsla(0, 0%, 100%, 0.95) inset,
    0 4px 10px hsla(148, 20%, 12%, 0.08),
    0 18px 40px hsla(148, 20%, 12%, 0.12);
  --shadow-stage:
    0 24px 64px hsla(150, 30%, 8%, 0.28),
    0 4px 14px hsla(150, 30%, 8%, 0.16);

  /* Typography */
  --font-display: "Fraunces", Georgia, "Times New Roman", serif;
  --font-sans: "Plus Jakarta Sans", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
  --font-tile: "Space Grotesk", "Plus Jakarta Sans", sans-serif;

  /* Spacing & Radii */
  --radius-sm: 8px;
  --radius-md: 14px;
  --radius-lg: 20px;
  --radius-xl: 26px;
  --container-max: 1140px;

  --ease-out: cubic-bezier(0.22, 1, 0.36, 1);
}

/* Reset & Base */
*,
*::before,
*::after {
  box-sizing: border-box;
}

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

body {
  margin: 0;
  font-family: var(--font-sans);
  font-size: 16px;
  line-height: 1.6;
  color: var(--ink-primary);
  background-color: var(--bg-canvas);
  background-image:
    radial-gradient(ellipse 90% 55% at 12% 0%, hsla(44, 65%, 99%, 0.85) 0%, transparent 65%),
    radial-gradient(ellipse 70% 45% at 92% 16%, hsla(150, 28%, 85%, 0.34) 0%, transparent 60%),
    linear-gradient(180deg, hsl(42, 34%, 95%) 0%, hsl(41, 30%, 92%) 100%);
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
}

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

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

button {
  font-family: inherit;
}

:focus-visible {
  outline: 2px solid var(--accent-emerald);
  outline-offset: 3px;
}

[hidden] {
  display: none !important;
}

section[id] {
  scroll-margin-top: 84px;
}

.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

.container {
  width: min(100% - 2.5rem, var(--container-max));
  margin-inline: auto;
}

/* ==========================================================================
   Header / Navigation
   ========================================================================== */

.site-header {
  position: sticky;
  top: 0;
  z-index: 40;
  background: hsla(42, 33%, 94%, 0.86);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--border-subtle);
}

.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 68px;
  gap: 1.25rem;
}

.brand-link {
  display: inline-flex;
  align-items: center;
  gap: 0.7rem;
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 1.3rem;
  letter-spacing: -0.02em;
  color: var(--ink-primary);
}

.brand-icon {
  width: 34px;
  height: 34px;
  border-radius: 9px;
  object-fit: cover;
  box-shadow: 0 2px 6px hsla(148, 25%, 10%, 0.18);
  border: 1px solid hsla(148, 20%, 15%, 0.15);
}

.nav-links {
  display: flex;
  align-items: center;
  gap: 1.75rem;
}

.nav-link {
  font-size: 0.9375rem;
  font-weight: 500;
  color: var(--ink-secondary);
  transition: color 0.18s ease;
  position: relative;
}

.nav-link:hover {
  color: var(--ink-primary);
}

.nav-link::after {
  content: "";
  position: absolute;
  left: 0;
  right: 0;
  bottom: -4px;
  height: 2px;
  background: var(--accent-emerald);
  transform: scaleX(0);
  transform-origin: center;
  transition: transform 0.22s var(--ease-out);
  border-radius: 2px;
}

.nav-link:hover::after {
  transform: scaleX(1);
}

.header-actions {
  display: flex;
  align-items: center;
  gap: 0.75rem;
}

.mobile-menu-btn {
  display: none;
  appearance: none;
  border: 1px solid var(--border-strong);
  background: var(--surface-paper);
  color: var(--ink-primary);
  width: 40px;
  height: 40px;
  border-radius: 10px;
  align-items: center;
  justify-content: center;
  cursor: pointer;
}

/* ==========================================================================
   Buttons
   ========================================================================== */

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.55rem;
  padding: 0.78rem 1.35rem;
  border-radius: 11px;
  font-size: 0.95rem;
  font-weight: 600;
  line-height: 1.2;
  cursor: pointer;
  border: 1px solid transparent;
  transition:
    transform 0.16s var(--ease-out),
    background-color 0.18s ease,
    box-shadow 0.18s ease,
    border-color 0.18s ease;
  white-space: nowrap;
}

.btn svg {
  width: 18px;
  height: 18px;
  flex-shrink: 0;
}

.btn-primary {
  background-color: var(--accent-emerald);
  color: #fff;
  box-shadow:
    0 1px 0 hsla(0, 0%, 100%, 0.18) inset,
    0 3px 0 hsl(150, 62%, 17%),
    0 8px 20px hsla(150, 56%, 22%, 0.25);
}

.btn-primary:hover {
  background-color: var(--accent-emerald-hover);
  transform: translateY(-1px);
  box-shadow:
    0 1px 0 hsla(0, 0%, 100%, 0.22) inset,
    0 4px 0 hsl(150, 62%, 15%),
    0 12px 26px hsla(150, 56%, 22%, 0.3);
}

.btn-primary:active {
  transform: translateY(2px);
  box-shadow:
    0 1px 0 hsl(150, 62%, 17%),
    0 4px 10px hsla(150, 56%, 22%, 0.2);
}

.btn-secondary {
  background-color: var(--surface-paper);
  color: var(--ink-primary);
  border-color: var(--border-strong);
  box-shadow:
    0 1px 0 hsla(0, 0%, 100%, 0.9) inset,
    0 2px 0 hsla(148, 20%, 15%, 0.12),
    0 4px 12px hsla(148, 20%, 15%, 0.06);
}

.btn-secondary:hover {
  background-color: #fff;
  border-color: hsla(148, 20%, 15%, 0.32);
  transform: translateY(-1px);
}

.btn-secondary:active {
  transform: translateY(1px);
}

.btn-sm {
  padding: 0.52rem 0.95rem;
  font-size: 0.875rem;
  border-radius: 9px;
}

.btn-dark {
  background-color: hsla(42, 30%, 95%, 0.1);
  color: var(--ink-on-dark);
  border-color: var(--border-dark);
}

.btn-dark:hover {
  background-color: hsla(42, 30%, 95%, 0.18);
  border-color: hsla(42, 30%, 95%, 0.28);
}

/* ==========================================================================
   Hero & Live Playable Browser Stage
   ========================================================================== */

.hero-section {
  padding: clamp(2.5rem, 5vw, 4.25rem) 0 clamp(3rem, 6vw, 5rem);
}

.hero-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.08fr) minmax(300px, 412px);
  gap: clamp(2rem, 4.5vw, 4rem);
  align-items: center;
}

/* Interactive tactile Lexiclix letter tiles */
.tile-rack {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  margin-bottom: 1.5rem;
  padding: 7px 9px;
  border-radius: 13px;
  background: hsla(148, 18%, 12%, 0.055);
  border: 1px solid var(--border-subtle);
  box-shadow: 0 1px 0 hsla(0, 0%, 100%, 0.7) inset;
}

.letter-tile {
  position: relative;
  width: 36px;
  height: 38px;
  border-radius: 7px;
  background: var(--surface-tile);
  border: 1.5px solid var(--accent-emerald);
  box-shadow: var(--shadow-tile);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-family: var(--font-tile);
  font-weight: 700;
  font-size: 1.15rem;
  color: var(--accent-crimson);
  user-select: none;
  cursor: pointer;
  transition: transform 0.2s var(--ease-out), box-shadow 0.2s var(--ease-out);
}

.letter-tile:hover {
  transform: translateY(-4px) rotate(-2deg);
}

.letter-tile.is-multiplier {
  background: hsl(44, 92%, 90%);
  border-color: var(--accent-brass);
  box-shadow:
    0 1px 0 hsla(0, 0%, 100%, 0.9) inset,
    0 3px 0 hsl(35, 70%, 34%),
    0 6px 14px hsla(38, 70%, 28%, 0.2);
}

.letter-tile.is-multiplier::after {
  content: "×2";
  position: absolute;
  right: 2px;
  bottom: 1px;
  font-size: 0.52rem;
  font-weight: 800;
  line-height: 1;
  color: hsl(26, 75%, 30%);
}

.letter-tile.pop {
  animation: tile-hop 0.36s var(--ease-out);
}

@keyframes tile-hop {
  0% { transform: translateY(0) scale(1); }
  40% { transform: translateY(-8px) scale(1.06) rotate(-3deg); }
  100% { transform: translateY(0) scale(1); }
}

.hero-title {
  margin: 0 0 1.1rem;
  font-family: var(--font-display);
  font-weight: 700;
  font-size: clamp(2.35rem, 4.4vw, 3.55rem);
  line-height: 1.07;
  letter-spacing: -0.03em;
  color: var(--ink-primary);
}

.hero-lead {
  margin: 0 0 1.85rem;
  font-size: clamp(1.02rem, 1.4vw, 1.14rem);
  line-height: 1.65;
  color: var(--ink-secondary);
  max-width: 52ch;
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.85rem;
  margin-bottom: 2.15rem;
}

.hero-facts {
  list-style: none;
  padding: 1.25rem 0 0;
  margin: 0;
  border-top: 1px solid var(--border-subtle);
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 1.15rem;
}

.hero-fact-label {
  display: block;
  font-family: var(--font-tile);
  font-size: 0.78rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--accent-emerald);
  margin-bottom: 0.2rem;
}

.hero-fact-text {
  display: block;
  font-size: 0.875rem;
  line-height: 1.45;
  color: var(--ink-secondary);
}

/* ==========================================================================
   Playable Browser Frame (Right Column, 3:5 Portrait Game Stage)
   ========================================================================== */

.play-stage-wrap {
  display: flex;
  flex-direction: column;
  width: 100%;
  max-width: min(412px, max(280px, calc((100dvh - 180px) * 0.6)));
  margin-inline: auto;
  border-radius: var(--radius-xl);
  background: var(--surface-stage);
  border: 1px solid hsla(148, 22%, 12%, 0.45);
  box-shadow: var(--shadow-stage);
  overflow: hidden;
}

.stage-toolbar {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 0.45rem 0.5rem;
  padding: 0.62rem 0.85rem;
  background: var(--surface-stage-elevated);
  border-bottom: 1px solid var(--border-dark);
  color: var(--ink-on-dark);
}

.stage-status {
  display: inline-flex;
  align-items: center;
  gap: 0.45rem;
  font-size: 0.8rem;
  font-weight: 600;
  letter-spacing: 0.01em;
  color: var(--ink-on-dark);
  white-space: nowrap;
}

.stage-indicator {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: hsl(148, 55%, 52%);
  flex-shrink: 0;
}

.stage-controls {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  flex-shrink: 0;
}

.stage-tool-btn {
  appearance: none;
  border: 1px solid var(--border-dark);
  background: hsla(42, 30%, 95%, 0.07);
  color: var(--ink-on-dark);
  font-size: 0.74rem;
  font-weight: 600;
  padding: 0.32rem 0.56rem;
  border-radius: 7px;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 0.3rem;
  white-space: nowrap;
  transition: background-color 0.16s ease, border-color 0.16s ease;
}

.stage-tool-btn:hover {
  background: hsla(42, 30%, 95%, 0.15);
  border-color: hsla(42, 30%, 95%, 0.3);
}

.stage-tool-btn svg {
  width: 14px;
  height: 14px;
}

.stage-viewport {
  position: relative;
  width: 100%;
  aspect-ratio: 3 / 5;
  background: #0d1210;
  overflow: hidden;
}

.stage-poster {
  position: absolute;
  inset: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: flex-end;
  padding: 1.75rem 1.4rem;
  text-align: center;
  background: #141920;
  transition: opacity 0.25s ease;
}

.stage-poster.is-hidden {
  opacity: 0;
  pointer-events: none;
}

.stage-poster-img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  filter: brightness(0.76) saturate(1.04);
  transition: transform 0.5s var(--ease-out);
}

.stage-poster:hover .stage-poster-img {
  transform: scale(1.025);
}

.stage-poster-scrim {
  position: absolute;
  inset: 0;
  background: linear-gradient(
    to bottom,
    hsla(152, 22%, 7%, 0.2) 0%,
    hsla(152, 22%, 7%, 0.45) 48%,
    hsla(152, 22%, 7%, 0.93) 100%
  );
}

.stage-poster-content {
  position: relative;
  z-index: 2;
  width: 100%;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.75rem;
}

.stage-poster-title {
  margin: 0;
  font-family: var(--font-display);
  font-size: 1.55rem;
  font-weight: 700;
  color: var(--ink-on-dark);
  letter-spacing: -0.02em;
}

.stage-poster-sub {
  margin: 0 0 0.25rem;
  font-size: 0.875rem;
  line-height: 1.45;
  color: var(--ink-on-dark-muted);
  max-width: 30ch;
}

.stage-launch-btn {
  width: 100%;
  padding: 0.9rem 1.25rem;
  font-size: 1rem;
}

.stage-iframe {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  border: 0;
  background: #000;
  display: block;
}

.stage-footnote {
  padding: 0.65rem 0.95rem;
  background: var(--surface-stage-elevated);
  border-top: 1px solid var(--border-dark);
  font-size: 0.78rem;
  color: var(--ink-on-dark-muted);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.5rem;
}

.stage-footnote a {
  color: hsl(42, 70%, 72%);
  font-weight: 600;
  text-decoration: underline;
  text-underline-offset: 3px;
}

.stage-footnote a:hover {
  color: #fff;
}

/* ==========================================================================
   Shared Section Layout
   ========================================================================== */

.section {
  padding: clamp(3.25rem, 6.5vw, 5.25rem) 0;
  border-top: 1px solid var(--border-subtle);
}

.section-tinted {
  background: linear-gradient(
    to bottom,
    hsla(40, 26%, 89%, 0.55) 0%,
    hsla(42, 33%, 94%, 0.35) 100%
  );
}

.section-header {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-end;
  justify-content: space-between;
  gap: 1rem 2rem;
  margin-bottom: clamp(1.75rem, 3.5vw, 2.5rem);
}

.section-eyebrow {
  display: block;
  font-family: var(--font-tile);
  font-size: 0.78rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: var(--accent-emerald);
  margin-bottom: 0.45rem;
}

.section-title {
  margin: 0;
  font-family: var(--font-display);
  font-weight: 700;
  font-size: clamp(1.8rem, 3.2vw, 2.5rem);
  line-height: 1.12;
  letter-spacing: -0.025em;
  color: var(--ink-primary);
}

.section-desc {
  margin: 0;
  font-size: 1rem;
  color: var(--ink-secondary);
  max-width: 48ch;
}

/* ==========================================================================
   Trailer Section
   ========================================================================== */

.trailer-frame {
  position: relative;
  width: 100%;
  aspect-ratio: 16 / 9;
  border-radius: var(--radius-xl);
  overflow: hidden;
  background: var(--surface-stage);
  border: 1px solid hsla(148, 22%, 12%, 0.35);
  box-shadow: var(--shadow-stage);
}

.trailer-poster-btn {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  padding: 0;
  border: 0;
  background: transparent;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
}

.trailer-poster-btn img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.55s var(--ease-out), filter 0.3s ease;
}

.trailer-poster-btn:hover img {
  transform: scale(1.03);
  filter: brightness(0.92);
}

.trailer-scrim {
  position: absolute;
  inset: 0;
  background: radial-gradient(
    circle at center,
    hsla(150, 20%, 8%, 0.18) 0%,
    hsla(150, 20%, 8%, 0.55) 100%
  );
}

.trailer-play-disc {
  position: relative;
  z-index: 2;
  width: 82px;
  height: 82px;
  border-radius: 50%;
  background: var(--surface-paper);
  color: var(--accent-emerald);
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow:
    0 12px 32px hsla(150, 35%, 6%, 0.45),
    0 0 0 8px hsla(44, 50%, 98%, 0.24);
  transition: transform 0.22s var(--ease-out), background-color 0.2s ease, color 0.2s ease;
}

.trailer-play-disc svg {
  width: 32px;
  height: 32px;
  margin-left: 4px;
}

.trailer-poster-btn:hover .trailer-play-disc {
  transform: scale(1.08);
  background: var(--accent-emerald);
  color: #fff;
}

.trailer-iframe {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  border: 0;
}

.trailer-meta {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 0.75rem;
  margin-top: 1rem;
  font-size: 0.9rem;
  color: var(--ink-secondary);
}

.text-link {
  color: var(--accent-emerald);
  font-weight: 600;
  text-decoration: underline;
  text-decoration-color: hsla(150, 56%, 27%, 0.35);
  text-underline-offset: 4px;
  transition: color 0.16s ease, text-decoration-color 0.16s ease;
}

.text-link:hover {
  color: var(--accent-emerald-hover);
  text-decoration-color: var(--accent-emerald-hover);
}

/* ==========================================================================
   Screenshots & Visual Themes Gallery
   ========================================================================== */

.gallery-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: clamp(1.25rem, 2.5vw, 2rem);
}

.theme-card {
  display: flex;
  flex-direction: column;
  background: var(--surface-paper);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-lg);
  overflow: hidden;
  box-shadow: var(--shadow-card);
  transition: transform 0.24s var(--ease-out), box-shadow 0.24s var(--ease-out);
}

.theme-card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-card-hover);
}

.theme-shot-btn {
  position: relative;
  display: block;
  width: 100%;
  padding: 0;
  border: 0;
  background: #141918;
  aspect-ratio: 3 / 5;
  overflow: hidden;
  cursor: zoom-in;
}

.theme-shot-btn img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.45s var(--ease-out);
}

.theme-card:hover .theme-shot-btn img {
  transform: scale(1.03);
}

.theme-zoom-hint {
  position: absolute;
  right: 12px;
  bottom: 12px;
  padding: 0.32rem 0.65rem;
  border-radius: 999px;
  background: hsla(152, 18%, 10%, 0.8);
  color: var(--ink-on-dark);
  font-size: 0.75rem;
  font-weight: 600;
  backdrop-filter: blur(6px);
  opacity: 0;
  transform: translateY(4px);
  transition: opacity 0.2s ease, transform 0.2s var(--ease-out);
}

.theme-card:hover .theme-zoom-hint,
.theme-shot-btn:focus-visible .theme-zoom-hint {
  opacity: 1;
  transform: translateY(0);
}

.theme-card-body {
  padding: 1.25rem 1.35rem 1.4rem;
}

.theme-pack-tag {
  display: inline-block;
  font-family: var(--font-tile);
  font-size: 0.72rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--ink-muted);
  margin-bottom: 0.35rem;
}

.theme-card-title {
  margin: 0 0 0.4rem;
  font-family: var(--font-display);
  font-size: 1.28rem;
  font-weight: 700;
  letter-spacing: -0.015em;
  color: var(--ink-primary);
}

.theme-card-desc {
  margin: 0;
  font-size: 0.92rem;
  line-height: 1.55;
  color: var(--ink-secondary);
}

/* ==========================================================================
   How to Play Strip (Compact Editorial Rules)
   ========================================================================== */

.rules-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 1.5rem;
}

.rule-item {
  padding: 1.5rem 1.55rem;
  border-radius: var(--radius-md);
  background: var(--surface-paper);
  border: 1px solid var(--border-subtle);
  box-shadow: var(--shadow-card);
}

.rule-num {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 32px;
  height: 32px;
  border-radius: 8px;
  background: var(--surface-tile);
  border: 1.5px solid var(--accent-emerald);
  box-shadow: 0 2px 0 hsl(150, 40%, 24%);
  font-family: var(--font-tile);
  font-weight: 700;
  font-size: 0.95rem;
  color: var(--accent-crimson);
  margin-bottom: 0.9rem;
}

.rule-title {
  margin: 0 0 0.45rem;
  font-family: var(--font-display);
  font-size: 1.18rem;
  font-weight: 700;
  color: var(--ink-primary);
}

.rule-text {
  margin: 0;
  font-size: 0.93rem;
  line-height: 1.58;
  color: var(--ink-secondary);
}

/* ==========================================================================
   Downloads Section (Windows, Steam, Android -> itch.io)
   ========================================================================== */

.external-notice {
  display: flex;
  align-items: flex-start;
  gap: 0.85rem;
  padding: 1rem 1.25rem;
  margin-bottom: 1.75rem;
  border-radius: var(--radius-md);
  background: var(--surface-paper);
  border: 1px solid var(--border-strong);
  box-shadow: 0 2px 10px hsla(148, 20%, 12%, 0.04);
  font-size: 0.94rem;
  color: var(--ink-secondary);
}

.external-notice svg {
  width: 20px;
  height: 20px;
  color: var(--accent-emerald);
  flex-shrink: 0;
  margin-top: 2px;
}

.external-notice strong {
  color: var(--ink-primary);
}

.download-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 1.5rem;
}

.download-card {
  display: flex;
  flex-direction: column;
  padding: 1.65rem 1.55rem 1.5rem;
  border-radius: var(--radius-lg);
  background: var(--surface-paper);
  border: 1px solid var(--border-subtle);
  box-shadow: var(--shadow-card);
  transition: transform 0.22s var(--ease-out), box-shadow 0.22s var(--ease-out), border-color 0.2s ease;
}

.download-card:hover {
  transform: translateY(-3px);
  box-shadow: var(--shadow-card-hover);
  border-color: var(--border-strong);
}

.platform-head {
  display: flex;
  align-items: center;
  gap: 0.85rem;
  margin-bottom: 0.95rem;
}

.platform-icon {
  width: 46px;
  height: 46px;
  border-radius: 12px;
  background: var(--accent-emerald-soft);
  color: var(--accent-emerald);
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.platform-icon svg {
  width: 24px;
  height: 24px;
}

.platform-name {
  margin: 0;
  font-family: var(--font-display);
  font-size: 1.32rem;
  font-weight: 700;
  color: var(--ink-primary);
  line-height: 1.2;
}

.platform-sub {
  display: block;
  font-size: 0.82rem;
  color: var(--ink-muted);
  font-weight: 500;
}

.download-desc {
  margin: 0 0 1.4rem;
  font-size: 0.93rem;
  line-height: 1.58;
  color: var(--ink-secondary);
  flex-grow: 1;
}

.download-btn {
  width: 100%;
}

.download-note {
  margin: 0.65rem 0 0;
  font-size: 0.78rem;
  line-height: 1.4;
  color: var(--ink-muted);
  text-align: center;
}

/* ==========================================================================
   Footer
   ========================================================================== */

.site-footer {
  border-top: 1px solid var(--border-subtle);
  padding: 2.25rem 0 2.75rem;
  background: hsla(40, 26%, 89%, 0.45);
}

.footer-inner {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 1rem 2rem;
}

.footer-brand {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  font-size: 0.9rem;
  color: var(--ink-secondary);
}

.footer-brand strong {
  font-family: var(--font-display);
  color: var(--ink-primary);
  font-size: 1.05rem;
}

.footer-links {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 1.35rem;
  font-size: 0.9rem;
  color: var(--ink-secondary);
}

.footer-links a:hover {
  color: var(--accent-emerald);
}

/* ==========================================================================
   Screenshot Lightbox Modal
   ========================================================================== */

.lightbox {
  position: fixed;
  inset: 0;
  z-index: 100;
  background: hsla(152, 22%, 6%, 0.9);
  backdrop-filter: blur(8px);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 1.5rem;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.2s ease;
}

.lightbox[hidden] {
  display: none;
}

.lightbox.is-open {
  opacity: 1;
  pointer-events: auto;
}

.lightbox-dialog {
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: center;
  max-width: min(92vw, 560px);
  max-height: 92vh;
  gap: 0.9rem;
}

.lightbox-img {
  max-height: calc(92vh - 90px);
  width: auto;
  border-radius: var(--radius-md);
  box-shadow: 0 24px 60px hsla(0, 0%, 0%, 0.6);
  border: 1px solid var(--border-dark);
}

.lightbox-caption {
  margin: 0;
  text-align: center;
  color: var(--ink-on-dark);
  font-size: 0.95rem;
}

.lightbox-close,
.lightbox-nav {
  position: fixed;
  appearance: none;
  border: 1px solid var(--border-dark);
  background: hsla(152, 16%, 12%, 0.85);
  color: var(--ink-on-dark);
  width: 44px;
  height: 44px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: background-color 0.16s ease, transform 0.16s ease;
}

.lightbox-close:hover,
.lightbox-nav:hover {
  background: var(--accent-emerald);
}

.lightbox-close {
  top: 1.25rem;
  right: 1.25rem;
}

.lightbox-prev {
  left: 1.25rem;
  top: 50%;
  transform: translateY(-50%);
}

.lightbox-next {
  right: 1.25rem;
  top: 50%;
  transform: translateY(-50%);
}

/* ==========================================================================
   Responsive Breakpoints
   ========================================================================== */

@media (max-width: 960px) {
  .hero-grid {
    grid-template-columns: 1fr;
    gap: 2.5rem;
  }

  .hero-copy {
    text-align: left;
  }

  .play-stage-wrap {
    max-width: min(420px, max(280px, calc((100dvh - 180px) * 0.6)));
  }

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

@media (max-width: 720px) {
  .nav-links {
    display: none;
    position: absolute;
    top: 68px;
    left: 0;
    right: 0;
    flex-direction: column;
    align-items: stretch;
    gap: 0;
    padding: 0.75rem 1.25rem 1rem;
    background: var(--surface-paper);
    border-bottom: 1px solid var(--border-strong);
    box-shadow: 0 12px 28px hsla(148, 20%, 12%, 0.12);
  }

  .nav-links.is-open {
    display: flex;
  }

  .nav-link {
    padding: 0.7rem 0.25rem;
    border-bottom: 1px solid var(--border-subtle);
  }

  .nav-link:last-child {
    border-bottom: 0;
  }

  .nav-link::after {
    display: none;
  }

  .mobile-menu-btn {
    display: inline-flex;
  }

  .header-play-btn {
    display: none;
  }

  .hero-facts {
    grid-template-columns: 1fr;
    gap: 0.85rem;
  }

  .gallery-grid,
  .download-grid,
  .rules-grid {
    grid-template-columns: 1fr;
  }

  .tile-rack {
    gap: 4px;
    padding: 5px 7px;
  }

  .letter-tile {
    width: 31px;
    height: 33px;
    font-size: 1rem;
  }

  .lightbox-prev {
    left: 0.5rem;
  }

  .lightbox-next {
    right: 0.5rem;
  }
}

@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }

  *,
  *::before,
  *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }
}
