:root {
  --bg: #0e0a1b;
  --bg-alt: #15102a;
  --surface: #1e1838;
  --surface-2: #2a2150;
  --border: rgba(255, 255, 255, .07);
  --border-strong: rgba(255, 255, 255, .14);
  --primary: #7c3aed;
  --primary-hover: #6d28d9;
  --accent: #c026d3;
  --gold: #ffc93c;
  --success: #1fbf75;
  --text: #ffffff;
  --text-muted: #9a93b5;
  --radius: 14px;
  --radius-sm: 10px;
  --container: 1240px;
  --shadow: 0 18px 40px -18px rgba(0, 0, 0, .8);
  --font: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Arial, sans-serif;
}

* { margin: 0; padding: 0; box-sizing: border-box; }

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

body {
  font-family: var(--font);
  background: var(--bg);
  color: var(--text);
  font-size: 16px;
  line-height: 1.6;
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
}

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

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

ul, ol { list-style: none; }

.container {
  width: 100%;
  max-width: var(--container);
  margin: 0 auto;
  padding: 0 16px;
}

.gold { color: var(--gold); }

.btn-primary,
.btn-ghost {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  font-family: var(--font);
  font-weight: 700;
  font-size: 14px;
  line-height: 1;
  padding: 12px 22px;
  border-radius: var(--radius-sm);
  cursor: pointer;
  border: 1px solid transparent;
  transition: transform .15s ease, background .15s ease, box-shadow .15s ease;
  white-space: nowrap;
}

.btn-primary {
  background: linear-gradient(120deg, var(--primary), var(--accent));
  color: #fff;
  box-shadow: 0 10px 24px -10px rgba(124, 58, 237, .9);
}

.btn-primary:hover { transform: translateY(-2px); box-shadow: 0 14px 30px -10px rgba(192, 38, 211, .9); }

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

.btn-ghost:hover { background: var(--surface-2); }

.btn-lg { padding: 16px 34px; font-size: 16px; }

/* ---------- Header ---------- */
.site-header {
  position: sticky;
  top: 0;
  z-index: 60;
  background: rgba(14, 10, 27, .92);
  backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--border);
  transition: box-shadow .2s ease;
}

.site-header.scrolled { box-shadow: 0 10px 30px -16px rgba(0, 0, 0, .9); }

.header-inner {
  display: flex;
  align-items: center;
  gap: 18px;
  height: 70px;
}

.logo { display: flex; align-items: center; flex-shrink: 0; }
.logo img { height: 38px; width: auto; }

.main-nav { margin-left: 8px; }

.main-nav ul { display: flex; align-items: center; gap: 4px; }

.main-nav a {
  display: block;
  padding: 9px 14px;
  font-size: 14px;
  font-weight: 600;
  color: var(--text-muted);
  border-radius: 8px;
  transition: color .15s ease, background .15s ease;
}

.main-nav a:hover,
.main-nav a.is-active { color: #fff; background: var(--surface); }

.header-actions {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-left: auto;
}

.header-join-mobile { display: none; }

.burger {
  display: none;
  flex-direction: column;
  justify-content: center;
  gap: 5px;
  width: 44px;
  height: 44px;
  background: var(--surface);
  border: 1px solid var(--border-strong);
  border-radius: 10px;
  cursor: pointer;
  flex-shrink: 0;
}

.burger span {
  display: block;
  width: 20px;
  height: 2px;
  margin: 0 auto;
  background: #fff;
  border-radius: 2px;
  transition: transform .2s ease, opacity .2s ease;
}

.burger.is-open span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
.burger.is-open span:nth-child(2) { opacity: 0; }
.burger.is-open span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

/* ---------- Mobile menu ---------- */
.mobile-menu {
  position: fixed;
  top: 0;
  right: 0;
  width: min(320px, 86vw);
  height: 100%;
  background: var(--bg-alt);
  border-left: 1px solid var(--border);
  z-index: 80;
  transform: translateX(100%);
  transition: transform .26s ease;
  padding: 88px 20px 32px;
  overflow-y: auto;
}

.mobile-menu.is-open { transform: translateX(0); }

.mobile-menu a {
  display: block;
  padding: 14px 14px;
  font-size: 16px;
  font-weight: 600;
  color: var(--text);
  border-radius: 10px;
  border: 1px solid var(--border);
  margin-bottom: 8px;
  background: var(--surface);
}

.mobile-menu a:hover { background: var(--surface-2); }

.mobile-menu .btn-primary { width: 100%; margin-top: 10px; padding: 15px; }

.menu-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, .6);
  z-index: 70;
  opacity: 0;
  visibility: hidden;
  transition: opacity .2s ease, visibility .2s ease;
}

.menu-overlay.is-open { opacity: 1; visibility: visible; }

/* ---------- Hero ---------- */
.hero {
  position: relative;
  display: flex;
  align-items: center;
  min-height: 560px;
  padding: 60px 0;
  overflow: hidden;
  background: var(--bg-alt);
  border-bottom: 1px solid var(--border);
}

.hero-img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: 78% center;
  z-index: 0;
}

.hero::before {
  content: "";
  position: absolute;
  inset: 0;
  z-index: 1;
  background:
    linear-gradient(90deg, rgba(14, 10, 27, .97) 0%, rgba(14, 10, 27, .82) 32%, rgba(14, 10, 27, .36) 62%, rgba(14, 10, 27, .22) 100%),
    linear-gradient(0deg, rgba(14, 10, 27, .55), rgba(14, 10, 27, 0) 42%);
  pointer-events: none;
}

.hero .container { position: relative; z-index: 2; }

.hero-text { max-width: 620px; }

.hero-eyebrow {
  display: inline-block;
  font-size: 12px;
  font-weight: 700;
  letter-spacing: .14em;
  text-transform: uppercase;
  color: var(--gold);
  background: rgba(255, 201, 60, .12);
  border: 1px solid rgba(255, 201, 60, .3);
  padding: 6px 12px;
  border-radius: 999px;
  margin-bottom: 16px;
}

.hero-title {
  font-size: clamp(32px, 5.6vw, 60px);
  font-weight: 800;
  line-height: 1.04;
  letter-spacing: -.02em;
  text-shadow: 0 6px 28px rgba(0, 0, 0, .55);
}

.hero-title span { display: block; color: #fff; }

.hero-sub {
  font-size: clamp(21px, 3.6vw, 36px);
  font-weight: 800;
  margin-top: 8px;
  letter-spacing: -.01em;
  text-shadow: 0 6px 28px rgba(0, 0, 0, .55);
}

.hero-actions { margin-top: 28px; display: flex; align-items: center; gap: 16px; flex-wrap: wrap; }

.hero-note { font-size: 12px; color: rgba(255, 255, 255, .75); }

/* ---------- Categories ---------- */
.section { padding: 30px 0; }

.cat-row {
  display: flex;
  gap: 10px;
  overflow-x: auto;
  padding: 6px 2px 12px;
  scrollbar-width: thin;
}

.cat-pill {
  display: inline-flex;
  align-items: center;
  gap: 9px;
  flex-shrink: 0;
  padding: 11px 18px;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 999px;
  font-size: 13px;
  font-weight: 600;
  color: var(--text-muted);
  transition: background .15s ease, color .15s ease, border-color .15s ease;
}

.cat-pill:hover { background: var(--surface-2); color: #fff; border-color: var(--border-strong); }

.cat-pill::before {
  content: "";
  width: 16px;
  height: 16px;
  border-radius: 5px;
  background: linear-gradient(135deg, var(--primary), var(--accent));
  flex-shrink: 0;
}

.cat-pill.is-hot::before { background: linear-gradient(135deg, var(--gold), #ff7a3c); }
.cat-pill.is-live::before { background: linear-gradient(135deg, var(--success), #15a4d6); }

.collections-grid {
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  gap: 14px;
  margin-top: 14px;
}

.collection-card {
  position: relative;
  border-radius: var(--radius);
  overflow: hidden;
  border: 1px solid var(--border);
  background: var(--surface);
  transition: transform .18s ease, border-color .18s ease;
}

.collection-card:hover { transform: translateY(-4px); border-color: var(--primary); }

.collection-card img { width: 100%; aspect-ratio: 5 / 4; object-fit: cover; }

.collection-card span {
  position: absolute;
  left: 12px;
  bottom: 10px;
  font-size: 14px;
  font-weight: 700;
  text-shadow: 0 2px 8px rgba(0, 0, 0, .8);
}

/* ---------- Game grids ---------- */
.section-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 16px;
  gap: 12px;
}

.section-title {
  font-size: clamp(18px, 2.6vw, 24px);
  font-weight: 800;
  letter-spacing: -.01em;
  display: flex;
  align-items: center;
  gap: 10px;
}

.section-title::before {
  content: "";
  width: 6px;
  height: 22px;
  border-radius: 4px;
  background: linear-gradient(var(--primary), var(--accent));
}

.section-all {
  font-size: 13px;
  font-weight: 700;
  color: var(--text-muted);
  padding: 8px 16px;
  border: 1px solid var(--border-strong);
  border-radius: 999px;
  transition: color .15s ease, background .15s ease;
}

.section-all:hover { color: #fff; background: var(--surface-2); }

.games-grid {
  display: grid;
  grid-template-columns: repeat(6, 1fr);
  gap: 14px;
}

.game-card {
  position: relative;
  border-radius: var(--radius);
  overflow: hidden;
  background: var(--surface);
  border: 1px solid var(--border);
  transition: transform .18s ease, border-color .18s ease;
}

.game-card:hover { transform: translateY(-5px); border-color: var(--primary); }

.game-thumb { position: relative; }

.game-thumb img { width: 100%; aspect-ratio: 5 / 7; object-fit: cover; }

.game-overlay {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  background: linear-gradient(180deg, rgba(14, 10, 27, .1), rgba(14, 10, 27, .82));
  opacity: 0;
  transition: opacity .18s ease;
}

.game-card:hover .game-overlay { opacity: 1; }

.play-btn {
  font-size: 13px;
  font-weight: 800;
  padding: 11px 24px;
  border-radius: 999px;
  background: linear-gradient(120deg, var(--primary), var(--accent));
  box-shadow: 0 10px 22px -10px rgba(124, 58, 237, .9);
}

.game-caption {
  padding: 10px 12px;
  font-size: 12px;
  font-weight: 600;
}

.game-caption b { display: block; font-weight: 700; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.game-caption span { color: var(--text-muted); font-size: 11px; }

/* ---------- Promo strip ---------- */
.promo-strip {
  display: flex;
  align-items: center;
  gap: 22px;
  background: linear-gradient(120deg, var(--surface), var(--surface-2));
  border: 1px solid var(--border-strong);
  border-radius: var(--radius);
  padding: 22px 26px;
  flex-wrap: wrap;
}

.promo-strip .promo-txt { flex: 1; min-width: 220px; }
.promo-strip .promo-txt b { font-size: 18px; font-weight: 800; }
.promo-strip .promo-txt p { color: var(--text-muted); font-size: 14px; margin-top: 4px; }

/* ---------- SEO content ---------- */
.seo-section { background: var(--bg-alt); padding: 44px 0 56px; margin-top: 20px; border-top: 1px solid var(--border); }

.seo-content {
  max-width: 920px;
  margin: 0 auto;
}

.seo-content h1 {
  font-size: clamp(26px, 4vw, 38px);
  font-weight: 800;
  line-height: 1.18;
  letter-spacing: -.02em;
  margin-bottom: 18px;
}

.seo-content h2 {
  font-size: clamp(21px, 3vw, 28px);
  font-weight: 800;
  letter-spacing: -.01em;
  margin: 38px 0 14px;
  padding-top: 10px;
}

.seo-content h3 {
  font-size: clamp(17px, 2.2vw, 21px);
  font-weight: 700;
  margin: 26px 0 10px;
  color: #fff;
}

.seo-content p { color: #cdc8de; margin-bottom: 14px; }

.seo-content strong { color: #fff; font-weight: 700; }

.seo-content ul,
.seo-content ol { margin: 0 0 16px; padding-left: 0; }

.seo-content li {
  position: relative;
  color: #cdc8de;
  padding-left: 26px;
  margin-bottom: 8px;
}

.seo-content ul > li::before {
  content: "";
  position: absolute;
  left: 4px;
  top: 9px;
  width: 9px;
  height: 9px;
  border-radius: 3px;
  background: linear-gradient(135deg, var(--primary), var(--accent));
}

.seo-content ol { counter-reset: seo-ol; }

.seo-content ol > li { counter-increment: seo-ol; }

.seo-content ol > li::before {
  content: counter(seo-ol);
  position: absolute;
  left: 0;
  top: 1px;
  width: 20px;
  height: 20px;
  font-size: 11px;
  font-weight: 800;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 6px;
  background: linear-gradient(135deg, var(--primary), var(--accent));
  color: #fff;
}

.seo-content li ul,
.seo-content li ol { margin: 8px 0 6px; }

.table-scroll {
  overflow-x: auto;
  margin: 0 0 20px;
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  -webkit-overflow-scrolling: touch;
}

.seo-content table {
  width: 100%;
  border-collapse: collapse;
  min-width: 520px;
  font-size: 14px;
}

.seo-content th,
.seo-content td {
  padding: 12px 16px;
  text-align: left;
  border-bottom: 1px solid var(--border);
}

.seo-content thead th {
  background: var(--surface-2);
  color: #fff;
  font-weight: 700;
  white-space: nowrap;
}

.seo-content tbody tr:nth-child(even) { background: rgba(255, 255, 255, .02); }
.seo-content tbody td { color: #cdc8de; }

.seo-content details {
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  background: var(--surface);
  margin-bottom: 10px;
  overflow: hidden;
}

.seo-content details[open] { border-color: var(--border-strong); }

.seo-content summary {
  list-style: none;
  cursor: pointer;
  padding: 16px 48px 16px 18px;
  position: relative;
}

.seo-content summary::-webkit-details-marker { display: none; }

.seo-content summary h3 { margin: 0; font-size: 16px; }

.seo-content summary::after {
  content: "+";
  position: absolute;
  right: 18px;
  top: 50%;
  transform: translateY(-50%);
  font-size: 22px;
  font-weight: 700;
  color: var(--primary);
}

.seo-content details[open] summary::after { content: "\2013"; }

.seo-content details > p,
.seo-content details > ul,
.seo-content details > ol { padding: 0 18px; }

.seo-content details > p:first-of-type { padding-top: 4px; }
.seo-content details > *:last-child { margin-bottom: 16px; }

.seo-content .lead {
  font-size: 18px;
  color: #e6e3f0;
}

/* ---------- Footer ---------- */
.site-footer {
  background: #0a0715;
  border-top: 1px solid var(--border);
  padding: 44px 0 26px;
  margin-top: 10px;
}

.footer-cta {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  background: linear-gradient(120deg, #2a1156, #5b1ec0);
  border: 1px solid var(--border-strong);
  border-radius: var(--radius);
  padding: 24px 30px;
  margin-bottom: 38px;
  flex-wrap: wrap;
}

.footer-cta b { font-size: 20px; font-weight: 800; }
.footer-cta p { color: rgba(255, 255, 255, .78); font-size: 14px; }

.footer-grid {
  display: grid;
  grid-template-columns: 1.6fr repeat(4, 1fr);
  gap: 30px;
  margin-bottom: 34px;
}

.footer-brand img { height: 36px; margin-bottom: 14px; }
.footer-brand p { color: var(--text-muted); font-size: 13px; max-width: 260px; }

.footer-col h4 {
  font-size: 13px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: .1em;
  margin-bottom: 14px;
  color: #fff;
}

.footer-col a {
  display: block;
  color: var(--text-muted);
  font-size: 14px;
  padding: 5px 0;
  transition: color .15s ease;
}

.footer-col a:hover { color: #fff; }

.footer-pay {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  padding: 24px 0;
  border-top: 1px solid var(--border);
  border-bottom: 1px solid var(--border);
}

.pay-badge {
  font-size: 12px;
  font-weight: 700;
  letter-spacing: .03em;
  color: #cdc8de;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 8px;
  padding: 8px 14px;
}

.footer-providers {
  display: flex;
  flex-wrap: wrap;
  gap: 18px 26px;
  padding: 22px 0;
  border-bottom: 1px solid var(--border);
}

.footer-providers span {
  font-size: 13px;
  font-weight: 700;
  color: var(--text-muted);
  letter-spacing: .04em;
}

.footer-bottom {
  display: flex;
  align-items: flex-start;
  gap: 18px;
  padding-top: 24px;
  flex-wrap: wrap;
}

.footer-18 {
  flex-shrink: 0;
  width: 52px;
  height: 52px;
  border-radius: 50%;
  border: 2px solid var(--gold);
  color: var(--gold);
  font-weight: 800;
  font-size: 17px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.footer-disclaimer { flex: 1; min-width: 240px; }
.footer-disclaimer p { color: var(--text-muted); font-size: 12px; margin-bottom: 8px; }
.footer-disclaimer a { color: #b9b2d4; text-decoration: underline; }

/* ---------- Back to top ---------- */
.to-top {
  position: fixed;
  right: 18px;
  bottom: 18px;
  width: 46px;
  height: 46px;
  border-radius: 12px;
  background: linear-gradient(120deg, var(--primary), var(--accent));
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 20px;
  font-weight: 800;
  z-index: 50;
  opacity: 0;
  visibility: hidden;
  transform: translateY(10px);
  transition: opacity .2s ease, visibility .2s ease, transform .2s ease;
  box-shadow: var(--shadow);
}

.to-top.show { opacity: 1; visibility: visible; transform: translateY(0); }

/* ---------- 404 ---------- */
.error-page {
  min-height: 70vh;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  padding: 60px 16px;
}

.error-page .code {
  font-size: clamp(80px, 18vw, 160px);
  font-weight: 800;
  line-height: 1;
  background: linear-gradient(120deg, var(--primary), var(--accent), var(--gold));
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

.error-page h1 { font-size: clamp(22px, 4vw, 32px); margin: 10px 0 12px; }
.error-page p { color: var(--text-muted); max-width: 460px; margin-bottom: 26px; }
.error-page .err-links { display: flex; gap: 12px; flex-wrap: wrap; justify-content: center; }

/* ---------- Responsive ---------- */
@media (max-width: 1100px) {
  .games-grid { grid-template-columns: repeat(4, 1fr); }
  .footer-grid { grid-template-columns: 1fr 1fr 1fr; }
  .footer-brand { grid-column: 1 / -1; }
}

@media (max-width: 900px) {
  .main-nav,
  .header-actions { display: none; }
  .burger { display: flex; }
  .header-join-mobile { display: inline-flex; margin-left: auto; }
  .header-inner { gap: 12px; }
  .hero { min-height: 470px; padding: 48px 0; }
  .hero::before { background: linear-gradient(180deg, rgba(14, 10, 27, .58), rgba(14, 10, 27, .9)); }
  .hero-img { object-position: 66% 50%; transform: scale(1.32); transform-origin: 66% 50%; }
  .collections-grid { grid-template-columns: repeat(3, 1fr); }
  .games-grid { grid-template-columns: repeat(3, 1fr); }
}

@media (max-width: 600px) {
  .container { padding: 0 14px; }
  .hero { min-height: 430px; padding: 40px 0; }
  .hero-img { object-position: 64% 50%; transform: scale(1.7); transform-origin: 64% 50%; }
  .collections-grid { grid-template-columns: repeat(2, 1fr); }
  .games-grid { grid-template-columns: repeat(2, 1fr); gap: 10px; }
  .footer-grid { grid-template-columns: 1fr 1fr; }
  .footer-cta { padding: 20px; }
  .seo-section { padding: 34px 0 44px; }
  .seo-content summary { padding-right: 44px; }
}

@media (max-width: 380px) {
  .games-grid { grid-template-columns: repeat(1, 1fr); }
}
