/* ── Reset & base ──────────────────────────────────────────────────────── */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

:root {
  --bg:         #05050f;
  --bg-card:    #0e0e20;
  --bg-card2:   #131328;
  --gold:       #ffd700;
  --gold-dim:   #cc9900;
  --purple:     #7700dd;
  --green:      #00cc88;
  --text:       #e8e0f0;
  --text-dim:   #8888aa;
  --border:     rgba(255,255,255,0.08);
  --font:       system-ui, 'Segoe UI', sans-serif;
}

html { scroll-behavior: smooth; }

body {
  font-family: var(--font);
  background: var(--bg);
  color: var(--text);
  min-height: 100vh;
  overflow-x: hidden;
}

/* ── Star field ──────────────────────────────────────────────────────────── */
.stars {
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: 0;
  overflow: hidden;
}

.star {
  position: absolute;
  width: 2px;
  height: 2px;
  border-radius: 50%;
  background: #fff;
  animation: twinkle var(--dur, 3s) ease-in-out infinite;
  animation-delay: var(--del, 0s);
  opacity: 0.4;
}

@keyframes twinkle {
  0%, 100% { opacity: 0.15; transform: scale(1); }
  50%       { opacity: 0.9;  transform: scale(1.5); }
}

/* ── Header ──────────────────────────────────────────────────────────────── */
.site-header {
  position: relative;
  z-index: 1;
  text-align: center;
  padding: 48px 24px 24px;
}

.logo {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 12px;
  margin-bottom: 8px;
}

.logo-icon { font-size: 40px; }

.logo-text {
  font-size: 38px;
  font-weight: 900;
  letter-spacing: 4px;
  color: #fff;
}

.logo-accent {
  color: var(--gold);
  text-shadow: 0 0 24px rgba(255,215,0,0.5);
}

.tagline {
  font-size: 16px;
  color: var(--text-dim);
  letter-spacing: 2px;
  text-transform: uppercase;
}

/* ── Hero ────────────────────────────────────────────────────────────────── */
.hero {
  position: relative;
  z-index: 1;
  text-align: center;
  padding: 60px 24px 80px;
  max-width: 760px;
  margin: 0 auto;
}

.hero-title {
  font-size: clamp(36px, 6vw, 64px);
  font-weight: 900;
  line-height: 1.15;
  color: #fff;
  margin-bottom: 20px;
  letter-spacing: -1px;
}

.gradient-text {
  background: linear-gradient(135deg, var(--gold), #ff8800, var(--purple));
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  animation: shiftGrad 4s ease infinite alternate;
  background-size: 200%;
}

@keyframes shiftGrad {
  from { background-position: 0%; }
  to   { background-position: 100%; }
}

.hero-sub {
  font-size: clamp(15px, 2vw, 18px);
  color: var(--text-dim);
  line-height: 1.65;
  margin-bottom: 36px;
}

.hero-cta {
  display: inline-block;
  padding: 14px 36px;
  background: rgba(255,215,0,0.1);
  border: 1px solid rgba(255,215,0,0.4);
  border-radius: 100px;
  color: var(--gold);
  font-size: 16px;
  font-weight: 700;
  letter-spacing: 1px;
  text-decoration: none;
  transition: background 0.2s, transform 0.2s;
}

.hero-cta:hover {
  background: rgba(255,215,0,0.18);
  transform: translateY(-2px);
}

/* ── Games section ───────────────────────────────────────────────────────── */
.games-section {
  position: relative;
  z-index: 1;
  max-width: 1100px;
  margin: 0 auto;
  padding: 0 24px 80px;
}

.section-title {
  text-align: center;
  font-size: 28px;
  font-weight: 800;
  letter-spacing: 3px;
  text-transform: uppercase;
  color: var(--text-dim);
  margin-bottom: 40px;
}

.games-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 28px;
  align-items: start;
}

/* ── Game card ───────────────────────────────────────────────────────────── */
.game-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: 20px;
  padding: 32px 28px;
  transition: transform 0.25s, box-shadow 0.25s, border-color 0.25s;
  position: relative;
  overflow: hidden;
}

.game-card::before {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(135deg, rgba(255,215,0,0.04), transparent 60%);
  pointer-events: none;
}

.game-card:not(.card-coming-soon):hover {
  transform: translateY(-6px);
  box-shadow: 0 20px 60px rgba(119,0,221,0.25), 0 0 0 1px rgba(255,215,0,0.2);
  border-color: rgba(255,215,0,0.25);
}

/* ── Worlds row ─────────────────────────────────────────────────────────── */
.card-worlds {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
  margin-bottom: 20px;
}

.world-badge {
  font-size: 12px;
  font-weight: 700;
  padding: 4px 10px;
  border-radius: 20px;
  letter-spacing: 0.5px;
}

.world-badge.dungeon { background: rgba(119,0,221,0.2); border: 1px solid rgba(119,0,221,0.5); color: #cc88ff; }
.world-badge.space   { background: rgba(0,136,255,0.15); border: 1px solid rgba(0,136,255,0.4); color: #66ccff; }
.world-badge.jungle  { background: rgba(0,204,100,0.15); border: 1px solid rgba(0,204,100,0.4); color: #44ee88; }

.world-arrow { color: var(--text-dim); font-size: 12px; }

/* ── Maze preview ────────────────────────────────────────────────────────── */
.card-icon { margin-bottom: 20px; }

.maze-preview {
  font-family: 'Courier New', monospace;
  font-size: 14px;
  line-height: 1.4;
  color: rgba(255,215,0,0.6);
  letter-spacing: 3px;
  display: inline-block;
  padding: 12px 16px;
  background: rgba(0,0,0,0.3);
  border-radius: 10px;
  border: 1px solid rgba(255,215,0,0.1);
}

.soon-icon {
  font-size: 56px;
  display: block;
  margin-bottom: 4px;
}

/* ── Card content ────────────────────────────────────────────────────────── */
.card-title {
  font-size: 24px;
  font-weight: 800;
  color: #fff;
  margin-bottom: 10px;
}

.card-desc {
  font-size: 14px;
  color: var(--text-dim);
  line-height: 1.65;
  margin-bottom: 20px;
}

.card-features {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 24px;
}

.feature-pill {
  font-size: 12px;
  font-weight: 600;
  padding: 4px 10px;
  border-radius: 20px;
  background: rgba(255,255,255,0.07);
  border: 1px solid rgba(255,255,255,0.12);
  color: var(--text-dim);
}

.feature-pill.muted { opacity: 0.5; }

/* ── Play button ─────────────────────────────────────────────────────────── */
.play-btn {
  display: block;
  width: 100%;
  padding: 14px;
  background: linear-gradient(135deg, var(--gold-dim), var(--gold));
  color: #1a0f00;
  border: none;
  border-radius: 12px;
  font-size: 16px;
  font-weight: 800;
  letter-spacing: 1px;
  cursor: pointer;
  text-align: center;
  text-decoration: none;
  transition: transform 0.15s, box-shadow 0.15s;
  box-shadow: 0 4px 20px rgba(255,215,0,0.25);
  font-family: var(--font);
}

.play-btn:hover { transform: translateY(-2px); box-shadow: 0 8px 28px rgba(255,215,0,0.38); }
.play-btn:active { transform: translateY(0); }

.btn-disabled {
  background: rgba(255,255,255,0.06);
  color: var(--text-dim);
  cursor: not-allowed;
  box-shadow: none;
}

.btn-disabled:hover { transform: none; box-shadow: none; }

.coming-note {
  text-align: center;
  margin-top: 10px;
  font-size: 13px;
  color: var(--text-dim);
}

/* Coming soon card style */
.card-coming-soon { opacity: 0.55; }
.card-coming-soon:hover { transform: none !important; box-shadow: none !important; }

/* ── About strip ─────────────────────────────────────────────────────────── */
.about-strip {
  position: relative;
  z-index: 1;
  border-top: 1px solid var(--border);
  border-bottom: 1px solid var(--border);
  background: rgba(255,255,255,0.02);
  padding: 48px 24px;
}

.about-items {
  display: flex;
  justify-content: center;
  gap: 48px;
  flex-wrap: wrap;
  max-width: 900px;
  margin: 0 auto;
}

.about-item {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 6px;
  text-align: center;
  min-width: 140px;
}

.about-icon { font-size: 32px; margin-bottom: 4px; }
.about-item strong { font-size: 15px; color: #fff; font-weight: 700; }
.about-item span   { font-size: 13px; color: var(--text-dim); }

/* ── Footer ──────────────────────────────────────────────────────────────── */
.site-footer {
  position: relative;
  z-index: 1;
  text-align: center;
  padding: 48px 24px;
}

.footer-main {
  font-size: 20px;
  font-weight: 800;
  color: var(--gold);
  margin-bottom: 8px;
  letter-spacing: 2px;
}

.footer-sub   { font-size: 14px; color: var(--text-dim); margin-bottom: 16px; }

.footer-legal {
  font-size: 12px;
  color: rgba(255,255,255,0.25);
  border-top: 1px solid var(--border);
  padding-top: 16px;
  margin-top: 4px;
  letter-spacing: 0.5px;
}

.footer-legal strong { color: rgba(255,255,255,0.45); font-weight: 600; }

/* ── Responsive ──────────────────────────────────────────────────────────── */
@media (max-width: 600px) {
  .logo-text  { font-size: 28px; }
  .hero       { padding: 40px 20px 60px; }
  .hero-sub br { display: none; }
  .about-items { gap: 28px; }
  .games-grid  { grid-template-columns: 1fr; }
}
