:root {
  --bg-deep: #14081a;
  --bg-mid: #2a1030;
  --ink: #fff8f2;
  --ink-soft: rgba(255, 248, 242, 0.78);
  --ink-mute: rgba(255, 248, 242, 0.55);
  --candy: #ff4d7a;
  --candy-hot: #ff2d6a;
  --lemon: #ffd84d;
  --mint: #3dffc0;
  --sky: #5ec8ff;
  --panel: rgba(255, 248, 242, 0.06);
  --panel-border: rgba(255, 248, 242, 0.12);
  --radius: 18px;
  --shadow: 0 24px 60px rgba(0, 0, 0, 0.45);
  --font-display: "Lilita One", "Fredoka", system-ui, sans-serif;
  --font-body: "Manrope", "Nunito", system-ui, sans-serif;
  --max: 1120px;
}

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

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  min-height: 100vh;
  font-family: var(--font-body);
  font-weight: 500;
  color: var(--ink);
  background: var(--bg-deep);
  line-height: 1.55;
  -webkit-font-smoothing: antialiased;
}

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

a {
  color: var(--lemon);
  text-decoration: none;
}

a:hover {
  color: #ffe98a;
}

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

/* Header */
.site-header {
  position: fixed;
  inset: 0 0 auto;
  z-index: 40;
  padding: 0.85rem 0;
  transition: background 0.3s ease, backdrop-filter 0.3s ease, border-color 0.3s ease;
  border-bottom: 1px solid transparent;
}

.site-header.is-scrolled {
  background: rgba(20, 8, 26, 0.82);
  backdrop-filter: blur(14px);
  border-bottom-color: var(--panel-border);
}

.nav {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
}

.brand img {
  height: 42px;
  width: auto;
  filter: drop-shadow(0 4px 10px rgba(0, 0, 0, 0.35));
}

.nav-links {
  display: flex;
  align-items: center;
  gap: 1.25rem;
  font-size: 0.95rem;
  font-weight: 700;
}

.nav-links a {
  color: var(--ink-soft);
}

.nav-links a:hover {
  color: var(--ink);
}

.nav-toggle {
  display: none;
  width: 44px;
  height: 44px;
  border: 1px solid var(--panel-border);
  border-radius: 12px;
  background: var(--panel);
  color: var(--ink);
  cursor: pointer;
}

.nav-toggle span {
  display: block;
  width: 18px;
  height: 2px;
  margin: 4px auto;
  background: currentColor;
  border-radius: 2px;
}

/* Buttons */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  padding: 0.85rem 1.35rem;
  border-radius: 999px;
  font-family: var(--font-body);
  font-weight: 800;
  font-size: 0.95rem;
  border: 2px solid transparent;
  cursor: pointer;
  transition: transform 0.18s ease, box-shadow 0.18s ease, background 0.18s ease;
}

.btn:hover {
  transform: translateY(-2px);
}

.btn-primary {
  background: linear-gradient(180deg, #ff6b93 0%, var(--candy-hot) 100%);
  color: #fff;
  box-shadow: 0 10px 28px rgba(255, 45, 106, 0.38);
}

.btn-primary:hover {
  color: #fff;
  box-shadow: 0 14px 34px rgba(255, 45, 106, 0.5);
}

.btn-secondary {
  background: rgba(255, 248, 242, 0.08);
  border-color: rgba(255, 248, 242, 0.22);
  color: var(--ink);
}

.btn-secondary:hover {
  color: var(--ink);
  background: rgba(255, 248, 242, 0.14);
}

.btn-lemon {
  background: linear-gradient(180deg, #ffe56a 0%, var(--lemon) 100%);
  color: #2a1030;
  box-shadow: 0 10px 28px rgba(255, 216, 77, 0.28);
}

.btn-lemon:hover {
  color: #2a1030;
}

/* Hero */
.hero {
  position: relative;
  min-height: 100svh;
  display: grid;
  align-items: end;
  overflow: hidden;
  isolation: isolate;
}

.hero-bg {
  position: absolute;
  inset: 0;
  z-index: -2;
  background:
    linear-gradient(180deg, rgba(20, 8, 26, 0.35) 0%, rgba(20, 8, 26, 0.55) 45%, rgba(20, 8, 26, 0.96) 100%),
    url("../assets/screens/shot-1-board-match.jpg") center / cover no-repeat;
  transform: scale(1.04);
  animation: hero-drift 18s ease-in-out infinite alternate;
}

.hero-bg::after {
  content: "";
  position: absolute;
  inset: 0;
  background:
    radial-gradient(ellipse 80% 50% at 70% 20%, rgba(255, 77, 122, 0.28), transparent 55%),
    radial-gradient(ellipse 60% 40% at 15% 70%, rgba(62, 255, 192, 0.12), transparent 50%);
}

@keyframes hero-drift {
  from { transform: scale(1.04) translate3d(0, 0, 0); }
  to { transform: scale(1.08) translate3d(-1.5%, -1%, 0); }
}

.hero-content {
  padding: 7.5rem 0 4.5rem;
  max-width: 38rem;
}

.hero-logo {
  width: min(320px, 78vw);
  margin-bottom: 1.25rem;
  filter: drop-shadow(0 16px 40px rgba(0, 0, 0, 0.55));
  animation: rise 0.9s cubic-bezier(0.22, 1, 0.36, 1) both;
}

.hero h1 {
  margin: 0 0 0.75rem;
  font-family: var(--font-display);
  font-size: clamp(2.4rem, 6vw, 3.6rem);
  letter-spacing: 0.02em;
  line-height: 1.05;
  text-shadow: 0 8px 28px rgba(0, 0, 0, 0.45);
  animation: rise 0.9s 0.08s cubic-bezier(0.22, 1, 0.36, 1) both;
}

.hero-lead {
  margin: 0 0 1.75rem;
  font-size: clamp(1.05rem, 2.2vw, 1.2rem);
  color: var(--ink-soft);
  max-width: 34ch;
  animation: rise 0.9s 0.16s cubic-bezier(0.22, 1, 0.36, 1) both;
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
  animation: rise 0.9s 0.24s cubic-bezier(0.22, 1, 0.36, 1) both;
}

.hero-note {
  margin: 1rem 0 0;
  font-size: 0.9rem;
  color: var(--ink-mute);
  animation: rise 0.9s 0.3s cubic-bezier(0.22, 1, 0.36, 1) both;
}

.pawn-float {
  position: absolute;
  right: max(6vw, 2rem);
  bottom: 18%;
  width: clamp(72px, 12vw, 120px);
  filter: drop-shadow(0 18px 24px rgba(0, 0, 0, 0.45));
  animation: float-pawn 3.6s ease-in-out infinite;
  pointer-events: none;
}

@keyframes float-pawn {
  0%, 100% { transform: translateY(0) rotate(-6deg); }
  50% { transform: translateY(-14px) rotate(4deg); }
}

@keyframes rise {
  from {
    opacity: 0;
    transform: translateY(22px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

/* Sections */
.section {
  padding: 5rem 0;
}

.section-head {
  max-width: 36rem;
  margin-bottom: 2.25rem;
}

.section h2,
.legal-page h1 {
  margin: 0 0 0.65rem;
  font-family: var(--font-display);
  font-size: clamp(1.9rem, 4vw, 2.6rem);
  letter-spacing: 0.02em;
  line-height: 1.1;
}

.section-intro {
  margin: 0;
  color: var(--ink-soft);
  font-size: 1.05rem;
}

/* Screenshots */
.screens {
  padding-top: 4rem;
}

.shot-rail {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 1rem;
}

.shot {
  margin: 0;
  border-radius: 22px;
  overflow: hidden;
  border: 1px solid var(--panel-border);
  background: #1a0c20;
  box-shadow: var(--shadow);
}

.shot-open {
  display: block;
  width: 100%;
  padding: 0;
  margin: 0;
  border: 0;
  background: transparent;
  cursor: zoom-in;
}

.shot img,
.story-panel .shot-open img {
  width: 100%;
  aspect-ratio: 16 / 9;
  object-fit: cover;
  object-position: center;
}

.story-panel .shot-open {
  display: block;
  width: 100%;
  height: 100%;
  padding: 0;
  margin: 0;
  border: 0;
  background: transparent;
  cursor: zoom-in;
}

.story-panel .shot-open img {
  height: 100%;
  aspect-ratio: auto;
}

.shot figcaption {
  padding: 0.75rem 1rem 1rem;
  font-size: 0.92rem;
  font-weight: 700;
  color: var(--ink-soft);
}

.lightbox {
  position: fixed;
  inset: 0;
  z-index: 80;
  display: grid;
  place-items: center;
  padding: 1.25rem;
  background: rgba(8, 2, 12, 0.9);
  backdrop-filter: blur(6px);
}

.lightbox[hidden] {
  display: none;
}

.lightbox-img {
  max-width: min(96vw, 1400px);
  max-height: 90vh;
  width: auto;
  height: auto;
  object-fit: contain;
  border-radius: 12px;
  box-shadow: var(--shadow);
}

.lightbox-close {
  position: absolute;
  top: 1rem;
  right: 1rem;
  width: 44px;
  height: 44px;
  border: 1px solid var(--panel-border);
  border-radius: 12px;
  background: rgba(255, 248, 242, 0.1);
  color: var(--ink);
  font-size: 1.6rem;
  line-height: 1;
  cursor: pointer;
}

.lightbox-close:hover {
  background: rgba(255, 248, 242, 0.2);
}

body.lightbox-open {
  overflow: hidden;
}

/* Shop */
.shop {
  background:
    radial-gradient(ellipse 60% 50% at 0% 0%, rgba(255, 216, 77, 0.1), transparent 50%),
    radial-gradient(ellipse 50% 40% at 100% 80%, rgba(94, 200, 255, 0.08), transparent 45%);
}

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

.shop-card {
  padding: 1.45rem 1.3rem;
  border-radius: var(--radius);
  background: var(--panel);
  border: 1px solid var(--panel-border);
}

.shop-card h3 {
  margin: 0 0 0.45rem;
  font-family: var(--font-display);
  font-size: 1.3rem;
  letter-spacing: 0.02em;
  color: var(--lemon);
}

.shop-card p {
  margin: 0;
  color: var(--ink-soft);
  font-size: 0.98rem;
}

.shop-card-accent {
  background:
    linear-gradient(160deg, rgba(255, 77, 122, 0.18), rgba(255, 248, 242, 0.04) 55%),
    var(--panel);
  border-color: rgba(255, 77, 122, 0.35);
}

.shop-card-accent h3 {
  color: var(--mint);
}

.feature-strip {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1rem;
}

.feature {
  padding: 1.5rem 1.35rem;
  border-radius: var(--radius);
  background: var(--panel);
  border: 1px solid var(--panel-border);
}

.feature h3 {
  margin: 0 0 0.45rem;
  font-family: var(--font-display);
  font-size: 1.35rem;
  letter-spacing: 0.02em;
  color: var(--lemon);
}

.feature p {
  margin: 0;
  color: var(--ink-soft);
  font-size: 0.98rem;
}

.story {
  background:
    radial-gradient(ellipse 70% 80% at 100% 0%, rgba(94, 200, 255, 0.12), transparent 50%),
    linear-gradient(180deg, #1c0c22 0%, var(--bg-deep) 100%);
  border-block: 1px solid var(--panel-border);
}

.story-grid {
  display: grid;
  grid-template-columns: 1.1fr 0.9fr;
  gap: 2.5rem;
  align-items: center;
}

.story-copy p {
  color: var(--ink-soft);
}

.story-copy p + p {
  margin-top: 1rem;
}

.story-panel {
  position: relative;
  border-radius: 28px;
  overflow: hidden;
  box-shadow: var(--shadow);
  border: 1px solid var(--panel-border);
  aspect-ratio: 1;
  background: #1a0c20;
}

.story-panel img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.meta-row {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem 1.5rem;
  margin-top: 1.5rem;
  color: var(--ink-mute);
  font-size: 0.9rem;
}

.meta-row strong {
  color: var(--ink);
  font-weight: 800;
}

.cta {
  padding: 4.5rem 0 5.5rem;
}

.cta-inner {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 1.5rem;
  padding: 2rem 2.25rem;
  border-radius: 28px;
  background:
    linear-gradient(135deg, rgba(255, 77, 122, 0.22), rgba(255, 216, 77, 0.1) 55%, rgba(62, 255, 192, 0.08)),
    var(--bg-mid);
  border: 1px solid var(--panel-border);
  box-shadow: var(--shadow);
}

.cta-inner h2 {
  margin: 0 0 0.4rem;
}

.cta-inner p {
  margin: 0;
  color: var(--ink-soft);
  max-width: 38ch;
}

/* Footer */
.site-footer {
  padding: 1.75rem 0 2.25rem;
  border-top: 1px solid var(--panel-border);
  color: var(--ink-mute);
  font-size: 0.92rem;
}

.footer-grid {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 0.75rem 1.5rem;
}

.site-footer a {
  color: var(--ink-soft);
}

.site-footer a:hover {
  color: var(--lemon);
}

/* Legal / privacy */
.legal-page {
  padding: 7rem 0 4rem;
}

.legal-shell {
  max-width: 720px;
}

.legal-meta {
  margin: 0 0 2rem;
  color: var(--ink-mute);
  font-size: 0.95rem;
}

.legal-shell h2 {
  margin: 2.25rem 0 0.75rem;
  font-family: var(--font-display);
  font-size: 1.45rem;
  letter-spacing: 0.02em;
  color: var(--lemon);
}

.legal-shell p,
.legal-shell li {
  color: var(--ink-soft);
}

.legal-shell ul {
  padding-left: 1.2rem;
}

.legal-shell li + li {
  margin-top: 0.4rem;
}

.legal-shell code {
  font-size: 0.9em;
  padding: 0.1em 0.35em;
  border-radius: 6px;
  background: rgba(255, 248, 242, 0.08);
  color: var(--mint);
}

.reveal {
  opacity: 0;
  transform: translateY(18px);
  transition: opacity 0.7s ease, transform 0.7s ease;
}

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

@media (max-width: 960px) {
  .shop-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 860px) {
  .feature-strip,
  .story-grid,
  .shot-rail,
  .shop-grid {
    grid-template-columns: 1fr;
  }

  .pawn-float {
    right: 1rem;
    bottom: 12%;
    width: 68px;
    opacity: 0.9;
  }

  .nav-toggle {
    display: inline-flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
  }

  .nav-links {
    position: absolute;
    top: calc(100% + 0.35rem);
    right: 1.25rem;
    left: 1.25rem;
    display: none;
    flex-direction: column;
    align-items: stretch;
    padding: 1rem;
    border-radius: 16px;
    background: rgba(20, 8, 26, 0.96);
    border: 1px solid var(--panel-border);
    box-shadow: var(--shadow);
  }

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

  .nav-links .btn {
    width: 100%;
  }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .hero-bg,
  .pawn-float,
  .hero-logo,
  .hero h1,
  .hero-lead,
  .hero-actions,
  .hero-note {
    animation: none;
  }
  .reveal {
    opacity: 1;
    transform: none;
    transition: none;
  }
}
