/* PixelGremlin — cream paper + coral + moss */
:root {
  --bg: #F3EFE6;
  --surface: #FFFDF8;
  --accent: #E23D28;
  --accent-deep: #C2311F;
  --secondary: #1F6B4F;
  --secondary-deep: #16533C;
  --text: #1C2430;
  --muted: #5C6670;
  --btn-on-secondary: #F7FFF9;
  --line: rgba(28, 36, 48, 0.12);
  --shadow: 0 18px 40px rgba(28, 36, 48, 0.1);
  --radius: 18px;
  --radius-sm: 12px;
  --container: 1140px;
  --font-display: "Rubik", sans-serif;
  --font-body: "DM Sans", sans-serif;
  --ease: cubic-bezier(0.22, 1, 0.36, 1);
}

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

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  font-family: var(--font-body);
  color: var(--text);
  background:
    radial-gradient(ellipse 70% 50% at 0% 0%, rgba(226, 61, 40, 0.08), transparent 55%),
    radial-gradient(ellipse 60% 45% at 100% 10%, rgba(31, 107, 79, 0.1), transparent 50%),
    linear-gradient(180deg, #F7F3EA 0%, var(--bg) 40%, #EDE7DB 100%);
  line-height: 1.6;
  min-height: 100vh;
}

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

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

button,
input {
  font: inherit;
}

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

.section {
  padding: 4.5rem 0;
}

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

.section-head h2 {
  font-family: var(--font-display);
  font-weight: 700;
  font-size: clamp(1.75rem, 3vw, 2.4rem);
  line-height: 1.15;
  margin: 0 0 0.75rem;
  letter-spacing: -0.02em;
}

.section-head p {
  margin: 0;
  color: var(--muted);
  font-size: 1.05rem;
}

.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  font-family: var(--font-display);
  font-size: 0.78rem;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--secondary);
  margin-bottom: 0.75rem;
}

.eyebrow::before {
  content: "";
  width: 8px;
  height: 8px;
  background: var(--accent);
  box-shadow: 2px 2px 0 var(--secondary);
}

/* Header */
.site-header {
  position: sticky;
  top: 0;
  z-index: 40;
  backdrop-filter: blur(12px);
  background: rgba(243, 239, 230, 0.86);
  border-bottom: 1px solid var(--line);
}

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

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

.brand img {
  width: 42px;
  height: 42px;
  border-radius: 12px;
  box-shadow: 0 4px 0 rgba(31, 107, 79, 0.25);
}

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

.nav a {
  color: var(--muted);
  font-weight: 500;
  font-size: 0.95rem;
  transition: color 0.2s var(--ease);
}

.nav a:hover,
.nav a.is-active {
  color: var(--text);
}

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

.player-chip {
  display: none;
  align-items: center;
  gap: 0.5rem;
  padding: 0.45rem 0.85rem;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: 999px;
  font-weight: 600;
  font-size: 0.92rem;
  box-shadow: 0 2px 0 rgba(28, 36, 48, 0.06);
}

.player-chip.is-visible {
  display: inline-flex;
}

.player-chip::before {
  content: "";
  width: 10px;
  height: 10px;
  background: var(--secondary);
  border-radius: 2px;
  box-shadow: 2px 2px 0 var(--accent);
}

.nav-toggle {
  display: none;
  width: 44px;
  height: 44px;
  border: 1px solid var(--line);
  border-radius: 12px;
  background: var(--surface);
  cursor: pointer;
  padding: 0;
  align-items: center;
  justify-content: center;
  flex-direction: column;
  gap: 5px;
}

.nav-toggle span {
  display: block;
  width: 18px;
  height: 2px;
  background: var(--text);
  border-radius: 2px;
}

/* Buttons */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.45rem;
  min-height: 46px;
  padding: 0.7rem 1.25rem;
  border-radius: 14px;
  border: 2px solid transparent;
  font-family: var(--font-display);
  font-weight: 600;
  font-size: 0.95rem;
  cursor: pointer;
  transition: transform 0.2s var(--ease), box-shadow 0.2s var(--ease), background 0.2s var(--ease);
}

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

.btn:active {
  transform: translateY(0);
}

.btn-primary {
  background: var(--accent);
  color: #fff;
  box-shadow: 0 4px 0 var(--accent-deep);
}

.btn-primary:hover {
  background: #EB4A34;
}

.btn-secondary {
  background: var(--secondary);
  color: var(--btn-on-secondary);
  box-shadow: 0 4px 0 var(--secondary-deep);
}

.btn-secondary:hover {
  background: #26805E;
}

.btn-ghost {
  background: transparent;
  color: var(--text);
  border-color: var(--line);
}

.btn-ghost:hover {
  background: var(--surface);
  box-shadow: 0 4px 0 rgba(28, 36, 48, 0.08);
}

.btn-sm {
  min-height: 40px;
  padding: 0.5rem 1rem;
  font-size: 0.88rem;
}

/* Hero */
.hero {
  position: relative;
  padding: 3.5rem 0 4rem;
  overflow: hidden;
}

.hero-grid {
  display: grid;
  grid-template-columns: 1.05fr 0.95fr;
  gap: 2.5rem;
  align-items: center;
}

.hero h1 {
  font-family: var(--font-display);
  font-size: clamp(2.4rem, 5vw, 3.6rem);
  line-height: 1.05;
  letter-spacing: -0.03em;
  margin: 0 0 1rem;
}

.hero h1 span {
  color: var(--accent);
}

.hero-lead {
  color: var(--muted);
  font-size: 1.1rem;
  max-width: 34rem;
  margin: 0 0 1.5rem;
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
  margin-bottom: 2rem;
}

.hero-stats {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 0.75rem;
  max-width: 28rem;
}

.stat {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius-sm);
  padding: 0.9rem 0.85rem;
  box-shadow: 0 3px 0 rgba(28, 36, 48, 0.05);
}

.stat strong {
  display: block;
  font-family: var(--font-display);
  font-size: 1.35rem;
  line-height: 1.1;
  margin-bottom: 0.2rem;
}

.stat span {
  color: var(--muted);
  font-size: 0.82rem;
}

.hero-visual {
  position: relative;
  border-radius: calc(var(--radius) + 6px);
  overflow: hidden;
  border: 2px solid rgba(28, 36, 48, 0.08);
  box-shadow: var(--shadow);
  background: var(--surface);
  aspect-ratio: 4 / 3;
  animation: floaty 5.5s ease-in-out infinite;
}

.hero-visual img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.hero-visual::after {
  content: "";
  position: absolute;
  inset: 0;
  background:
    linear-gradient(135deg, rgba(243, 239, 230, 0.15), transparent 40%),
    repeating-linear-gradient(
      0deg,
      transparent,
      transparent 3px,
      rgba(28, 36, 48, 0.03) 3px,
      rgba(28, 36, 48, 0.03) 4px
    );
  pointer-events: none;
}

.pixel-dust {
  position: absolute;
  inset: auto auto 12% 8%;
  width: 90px;
  height: 90px;
  background:
    radial-gradient(circle at 20% 30%, var(--accent) 0 4px, transparent 5px),
    radial-gradient(circle at 70% 40%, var(--secondary) 0 3px, transparent 4px),
    radial-gradient(circle at 40% 75%, #E8B84A 0 3px, transparent 4px);
  opacity: 0.7;
  animation: sparkle 2.8s ease-in-out infinite;
  pointer-events: none;
}

@keyframes floaty {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(-10px); }
}

@keyframes sparkle {
  0%, 100% { opacity: 0.45; transform: scale(1); }
  50% { opacity: 0.9; transform: scale(1.08); }
}

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

.reveal {
  animation: rise-in 0.7s var(--ease) both;
}

/* Games */
.games-section {
  background:
    linear-gradient(180deg, transparent, rgba(255, 253, 248, 0.7) 20%, rgba(255, 253, 248, 0.7) 80%, transparent);
}

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

.game-card {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  overflow: hidden;
  box-shadow: 0 8px 0 rgba(28, 36, 48, 0.04);
  display: flex;
  flex-direction: column;
  transition: transform 0.25s var(--ease), box-shadow 0.25s var(--ease);
}

.game-card:hover {
  transform: translateY(-6px);
  box-shadow: 0 16px 0 rgba(28, 36, 48, 0.05);
}

.game-card__media {
  aspect-ratio: 16 / 11;
  background: #E8E2D6;
  overflow: hidden;
}

.game-card__media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.4s var(--ease);
}

.game-card:hover .game-card__media img {
  transform: scale(1.05);
}

.game-card__body {
  padding: 1.15rem 1.2rem 1.3rem;
  display: flex;
  flex-direction: column;
  gap: 0.65rem;
  flex: 1;
}

.game-card h3 {
  margin: 0;
  font-family: var(--font-display);
  font-size: 1.2rem;
  letter-spacing: -0.02em;
}

.game-card p {
  margin: 0;
  color: var(--muted);
  font-size: 0.94rem;
  flex: 1;
}

.game-card .btn {
  width: 100%;
}

/* Feature */
.feature {
  display: grid;
  grid-template-columns: 0.95fr 1.05fr;
  gap: 2.5rem;
  align-items: center;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: calc(var(--radius) + 8px);
  padding: 1.5rem;
  box-shadow: var(--shadow);
}

.feature-media {
  border-radius: var(--radius);
  overflow: hidden;
  aspect-ratio: 1;
  background: #EDE7DB;
}

.feature-media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.feature-copy h2 {
  font-family: var(--font-display);
  font-size: clamp(1.7rem, 3vw, 2.2rem);
  margin: 0 0 0.85rem;
  letter-spacing: -0.02em;
}

.feature-copy > p {
  color: var(--muted);
  margin: 0 0 1.25rem;
}

.check-list {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  gap: 0.75rem;
}

.check-list li {
  display: grid;
  grid-template-columns: auto 1fr;
  gap: 0.75rem;
  align-items: start;
  padding: 0.85rem 1rem;
  border-radius: var(--radius-sm);
  background: rgba(243, 239, 230, 0.8);
  border: 1px solid var(--line);
}

.check-list li::before {
  content: "";
  width: 18px;
  height: 18px;
  margin-top: 2px;
  background:
    linear-gradient(135deg, var(--secondary), var(--secondary-deep));
  clip-path: polygon(14% 44%, 0 60%, 40% 100%, 100% 18%, 84% 0, 40% 70%);
}

.check-list strong {
  display: block;
  font-family: var(--font-display);
  margin-bottom: 0.15rem;
}

.check-list span {
  color: var(--muted);
  font-size: 0.92rem;
}

/* Steps */
.steps {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 1.15rem;
}

.step {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 1.4rem 1.3rem;
  position: relative;
  overflow: hidden;
}

.step::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 4px;
  background: linear-gradient(90deg, var(--accent), var(--secondary));
}

.step-num {
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 0.85rem;
  color: var(--accent);
  letter-spacing: 0.06em;
  margin-bottom: 0.7rem;
}

.step h3 {
  margin: 0 0 0.5rem;
  font-family: var(--font-display);
  font-size: 1.15rem;
}

.step p {
  margin: 0;
  color: var(--muted);
  font-size: 0.95rem;
}

/* Benefits */
.benefits {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 1.15rem;
}

.benefit {
  background: var(--surface);
  border: 1px dashed rgba(31, 107, 79, 0.35);
  border-radius: var(--radius);
  padding: 1.4rem 1.35rem;
  transition: border-color 0.2s var(--ease), transform 0.2s var(--ease);
}

.benefit:hover {
  border-style: solid;
  border-color: var(--secondary);
  transform: translateY(-3px);
}

.benefit-icon {
  width: 42px;
  height: 42px;
  border-radius: 12px;
  background: rgba(226, 61, 40, 0.1);
  color: var(--accent);
  display: grid;
  place-items: center;
  font-family: var(--font-display);
  font-weight: 700;
  margin-bottom: 0.85rem;
  box-shadow: inset 0 0 0 2px rgba(226, 61, 40, 0.15);
}

.benefit h3 {
  margin: 0 0 0.45rem;
  font-family: var(--font-display);
  font-size: 1.15rem;
}

.benefit p {
  margin: 0;
  color: var(--muted);
}

/* CTA */
.cta {
  position: relative;
  border-radius: calc(var(--radius) + 10px);
  overflow: hidden;
  border: 2px solid rgba(28, 36, 48, 0.08);
  min-height: 280px;
  display: grid;
  align-items: center;
  box-shadow: var(--shadow);
}

.cta img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.cta-overlay {
  position: relative;
  z-index: 1;
  padding: 2.5rem;
  background: linear-gradient(90deg, rgba(243, 239, 230, 0.94) 0%, rgba(243, 239, 230, 0.82) 48%, rgba(243, 239, 230, 0.35) 100%);
  max-width: 34rem;
}

.cta h2 {
  font-family: var(--font-display);
  font-size: clamp(1.8rem, 3vw, 2.4rem);
  margin: 0 0 0.75rem;
  letter-spacing: -0.02em;
}

.cta p {
  margin: 0 0 1.25rem;
  color: var(--muted);
}

.cta-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.7rem;
}

/* Page hero (inner) */
.page-hero {
  padding: 3rem 0 1.5rem;
}

.page-hero h1 {
  font-family: var(--font-display);
  font-size: clamp(2rem, 4vw, 2.8rem);
  margin: 0 0 0.75rem;
  letter-spacing: -0.03em;
}

.page-hero p {
  margin: 0;
  color: var(--muted);
  max-width: 40rem;
  font-size: 1.05rem;
}

.content-card {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 1.75rem;
  box-shadow: 0 10px 0 rgba(28, 36, 48, 0.04);
  margin-bottom: 4rem;
}

.content-card h2 {
  font-family: var(--font-display);
  font-size: 1.35rem;
  margin: 1.75rem 0 0.65rem;
}

.content-card h2:first-child {
  margin-top: 0;
}

.content-card p,
.content-card li {
  color: var(--muted);
}

.content-card ul {
  padding-left: 1.2rem;
}

.content-card a {
  color: var(--secondary);
  text-decoration: underline;
  text-underline-offset: 3px;
}

/* Contact */
.contact-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1.25rem;
  margin-bottom: 4rem;
}

.contact-panel,
.contact-form {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 1.5rem;
  box-shadow: 0 10px 0 rgba(28, 36, 48, 0.04);
}

.form-row {
  display: grid;
  gap: 0.4rem;
  margin-bottom: 0.95rem;
}

.form-row label {
  font-weight: 600;
  font-size: 0.9rem;
}

.form-row input,
.form-row textarea {
  width: 100%;
  border: 1px solid var(--line);
  border-radius: 12px;
  background: #FBF8F1;
  padding: 0.8rem 0.95rem;
  color: var(--text);
  outline: none;
  transition: border-color 0.2s var(--ease), box-shadow 0.2s var(--ease);
}

.form-row input:focus,
.form-row textarea:focus {
  border-color: var(--secondary);
  box-shadow: 0 0 0 3px rgba(31, 107, 79, 0.12);
}

.form-note {
  display: none;
  margin-top: 0.85rem;
  padding: 0.8rem 1rem;
  border-radius: 12px;
  background: rgba(31, 107, 79, 0.1);
  color: var(--secondary-deep);
  font-weight: 600;
}

.form-note.is-visible {
  display: block;
}

/* Footer */
.site-footer {
  border-top: 1px solid var(--line);
  background: rgba(255, 253, 248, 0.7);
  padding: 3rem 0 1.5rem;
  margin-top: 2rem;
}

.footer-grid {
  display: grid;
  grid-template-columns: 1.3fr 1fr 1fr 1fr;
  gap: 1.5rem;
  margin-bottom: 2rem;
}

.footer-brand p {
  color: var(--muted);
  margin: 0.85rem 0 0;
  max-width: 22rem;
  font-size: 0.95rem;
}

.footer-col h4 {
  margin: 0 0 0.85rem;
  font-family: var(--font-display);
  font-size: 0.95rem;
}

.footer-col a {
  display: block;
  color: var(--muted);
  margin-bottom: 0.5rem;
  font-size: 0.92rem;
  transition: color 0.2s var(--ease);
}

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

.footer-bottom {
  border-top: 1px solid var(--line);
  padding-top: 1.1rem;
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem 1.25rem;
  justify-content: space-between;
  color: var(--muted);
  font-size: 0.86rem;
}

.disclaimer {
  font-weight: 600;
  color: var(--text);
}

/* Modals / overlays */
.overlay {
  position: fixed;
  inset: 0;
  background: rgba(28, 36, 48, 0.45);
  backdrop-filter: blur(4px);
  z-index: 80;
  display: none;
  align-items: center;
  justify-content: center;
  padding: 1rem;
}

.overlay.is-open {
  display: flex;
}

.modal {
  width: min(100%, 440px);
  background: var(--surface);
  border-radius: calc(var(--radius) + 4px);
  border: 1px solid var(--line);
  box-shadow: var(--shadow);
  padding: 1.5rem;
  position: relative;
  animation: rise-in 0.35s var(--ease);
}

.modal h2 {
  font-family: var(--font-display);
  margin: 0 0 0.5rem;
  font-size: 1.45rem;
}

.modal > p {
  margin: 0 0 1.1rem;
  color: var(--muted);
  font-size: 0.95rem;
}

.modal-close {
  position: absolute;
  top: 0.85rem;
  right: 0.85rem;
  width: 36px;
  height: 36px;
  border: none;
  border-radius: 10px;
  background: #F3EFE6;
  cursor: pointer;
  font-size: 1.2rem;
  line-height: 1;
  color: var(--text);
}

.auth-tabs {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0.4rem;
  background: #F3EFE6;
  padding: 0.3rem;
  border-radius: 12px;
  margin-bottom: 1.1rem;
}

.auth-tab {
  border: none;
  background: transparent;
  min-height: 40px;
  border-radius: 10px;
  font-family: var(--font-display);
  font-weight: 600;
  cursor: pointer;
  color: var(--muted);
}

.auth-tab.is-active {
  background: var(--surface);
  color: var(--text);
  box-shadow: 0 2px 0 rgba(28, 36, 48, 0.06);
}

.auth-panel {
  display: none;
}

.auth-panel.is-active {
  display: block;
}

.auth-disclaimer {
  margin-top: 0.85rem;
  font-size: 0.82rem;
  color: var(--muted);
}

.age-modal {
  text-align: center;
}

.age-modal .brand {
  justify-content: center;
  margin-bottom: 1rem;
}

.age-actions {
  display: flex;
  gap: 0.7rem;
  justify-content: center;
  flex-wrap: wrap;
  margin-top: 1.25rem;
}

/* Cookie banner */
.cookie-banner {
  position: fixed;
  left: 1rem;
  right: 1rem;
  bottom: 1rem;
  z-index: 70;
  display: none;
  width: min(100% - 0rem, 720px);
  margin-inline: auto;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  padding: 1.1rem 1.2rem;
  animation: rise-in 0.4s var(--ease);
}

.cookie-banner.is-visible {
  display: block;
}

.cookie-banner p {
  margin: 0 0 0.9rem;
  color: var(--muted);
  font-size: 0.92rem;
}

.cookie-banner a {
  color: var(--secondary);
  text-decoration: underline;
  text-underline-offset: 2px;
}

.cookie-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.55rem;
}

body.is-locked {
  overflow: hidden;
}

/* Responsive */
@media (max-width: 980px) {
  .hero-grid,
  .feature,
  .footer-grid,
  .contact-grid {
    grid-template-columns: 1fr;
  }

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

  .steps {
    grid-template-columns: 1fr;
  }

  .cta-overlay {
    background: linear-gradient(180deg, rgba(243, 239, 230, 0.94), rgba(243, 239, 230, 0.78));
    max-width: none;
  }
}

@media (max-width: 760px) {
  .nav-toggle {
    display: inline-flex;
  }

  .nav {
    position: absolute;
    top: 72px;
    left: 0;
    right: 0;
    background: rgba(255, 253, 248, 0.98);
    border-bottom: 1px solid var(--line);
    flex-direction: column;
    align-items: stretch;
    padding: 1rem;
    gap: 0.25rem;
    display: none;
  }

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

  .nav a {
    padding: 0.75rem 0.85rem;
    border-radius: 10px;
  }

  .nav a:hover {
    background: #F3EFE6;
  }

  .header-actions .btn-ghost {
    display: none;
  }

  .games-grid,
  .benefits,
  .hero-stats {
    grid-template-columns: 1fr;
  }

  .hero-visual {
    animation: none;
  }
}
