:root {
  --bg: #0f0f1a;
  --panel: #161628;
  --panel-alt: #1a1a2e;
  --text: #e0e0e0;
  --muted: #b8bdd3;
  --accent: #e94560;
  --link: #4fc3f7;
  --border: #2a2d46;
  --success: #67d4a3;
  --shadow: 0 14px 40px rgba(0, 0, 0, 0.28);
  --shadow-soft: 0 24px 55px rgba(3, 5, 17, 0.38);
  --surface-outline: rgba(255, 255, 255, 0.08);
  --radius: 18px;
  --container: 1280px;
  --reading: 860px;
  --header-height: 72px;
  --sticky-height: 78px;
  font-synthesis-weight: none;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  min-width: 320px;
  background:
    radial-gradient(circle at top, rgba(50, 58, 110, 0.34) 0%, rgba(17, 20, 39, 0) 32%),
    linear-gradient(180deg, #121428 0%, var(--bg) 38%, #0c0d17 100%);
  color: var(--text);
  font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
  line-height: 1.65;
}

a {
  color: var(--link);
}

a:hover,
a:focus-visible {
  color: #8ddbff;
}

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

button,
.button {
  border: 0;
  border-radius: 999px;
  background: linear-gradient(135deg, var(--accent), #ff6f61);
  color: #fff;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font: inherit;
  font-weight: 700;
  min-height: 44px;
  padding: 0.8rem 1.4rem;
  text-decoration: none;
  transition: transform 0.18s ease, filter 0.18s ease;
}

button:hover,
button:focus-visible,
.button:hover,
.button:focus-visible {
  filter: brightness(1.06);
  transform: translateY(-1px);
}

.container {
  margin: 0 auto;
  max-width: var(--container);
  padding: 0 1rem;
}

.reading-width {
  max-width: var(--reading);
}

.site-header,
.site-footer {
  background: rgba(19, 22, 39, 0.82);
  backdrop-filter: blur(14px);
}

.site-header {
  border-bottom: 1px solid rgba(255, 255, 255, 0.06);
  position: sticky;
  top: 0;
  z-index: 40;
}

.header-inner,
.footer-inner {
  align-items: center;
  display: flex;
  gap: 1rem;
  justify-content: space-between;
  min-height: var(--header-height);
  padding-bottom: 0.75rem;
  padding-top: 0.75rem;
}

.brand {
  align-items: center;
  color: var(--text);
  display: inline-flex;
  font-size: 1.1rem;
  font-weight: 800;
  gap: 0.75rem;
  letter-spacing: 0.02em;
  text-decoration: none;
}

.main-nav {
  display: flex;
  flex-wrap: wrap;
  gap: 1rem;
}

.main-nav a {
  font-weight: 600;
  text-decoration: none;
}

.hero-section {
  padding: 2.5rem 0 1.5rem;
}

.section-intro {
  margin: 0 auto 2rem;
  max-width: 920px;
  text-align: center;
}

.eyebrow {
  color: var(--success);
  font-size: 0.9rem;
  font-weight: 700;
  letter-spacing: 0.12em;
  margin-bottom: 0.8rem;
  text-transform: uppercase;
}

h1,
h2,
h3 {
  line-height: 1.2;
  margin-top: 0;
}

h1 {
  font-size: clamp(2rem, 4vw, 3.2rem);
  letter-spacing: -0.03em;
  margin-bottom: 0.9rem;
}

h2 {
  font-size: clamp(1.5rem, 2.4vw, 2rem);
  margin-bottom: 0.85rem;
  margin-top: 2.5rem;
}

h3 {
  font-size: 1.1rem;
  margin-bottom: 0.35rem;
}

.lede,
.helper-text,
.loading-text,
small,
.cookie-banner p,
.site-footer p {
  color: var(--muted);
}

.lede {
  font-size: 1.08rem;
  margin: 0 auto;
  max-width: 760px;
}

.hero-note {
  color: rgba(224, 228, 245, 0.72);
  font-size: 0.96rem;
  margin: 0.9rem auto 0;
  max-width: 720px;
}

.hero-meta {
  color: rgba(184, 189, 211, 0.9);
  font-size: 0.92rem;
  margin: 0.85rem auto 0;
  max-width: 720px;
}

.hero-meta time {
  color: var(--text);
  font-weight: 700;
}

.game-layout {
  align-items: start;
  display: grid;
  gap: 1rem;
  grid-template-columns: 160px minmax(0, 1fr) 160px;
}

.rail,
.game-column,
.game-panel,
.legal-page,
article,
.faq-item {
  min-width: 0;
}

.game-column {
  display: grid;
  gap: 1rem;
}

.game-panel,
article,
.legal-page {
  background: linear-gradient(180deg, rgba(24, 28, 49, 0.98) 0%, rgba(17, 19, 35, 0.98) 100%);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  padding: 1.25rem;
}

.game-panel {
  border-color: rgba(100, 115, 182, 0.26);
  box-shadow: var(--shadow-soft);
  padding: 1.4rem;
}

.panel-kicker {
  color: #aeb9f6;
  font-size: 0.78rem;
  font-weight: 800;
  letter-spacing: 0.16em;
  margin-bottom: 0.7rem;
  text-transform: uppercase;
}

.game-label {
  font-size: clamp(1.25rem, 2vw, 1.6rem);
  font-weight: 800;
  margin: 0;
}

.panel-copy {
  color: rgba(225, 229, 244, 0.78);
  margin: 0.65rem 0 1rem;
  max-width: 72ch;
}

.iframe-shell {
  align-items: center;
  background:
    radial-gradient(circle at top, rgba(66, 85, 180, 0.12), transparent 40%),
    linear-gradient(180deg, #0e1020 0%, #090b13 100%);
  border: 1px solid var(--surface-outline);
  border-radius: 20px;
  display: grid;
  justify-items: center;
  min-height: 600px;
  overflow: hidden;
  padding: 0;
  position: relative;
}

.iframe-shell::after {
  border: 1px solid rgba(255, 255, 255, 0.04);
  border-radius: inherit;
  content: '';
  inset: 10px;
  pointer-events: none;
  position: absolute;
}

.iframe-shell iframe {
  background: #05050a;
  border: 0;
  display: block;
  min-height: 600px;
  width: 100%;
}

.spinner {
  animation: spin 0.9s linear infinite;
  border: 4px solid rgba(255, 255, 255, 0.12);
  border-top-color: var(--accent);
  border-radius: 50%;
  height: 48px;
  left: calc(50% - 24px);
  position: absolute;
  top: calc(50% - 40px);
  width: 48px;
  z-index: 2;
}

.loading-text {
  left: 50%;
  margin: 0;
  max-width: min(90%, 460px);
  position: absolute;
  text-align: center;
  top: calc(50% + 18px);
  transform: translateX(-50%);
  z-index: 2;
}

.iframe-shell:not(.loading) .spinner {
  display: none;
}

.iframe-shell:not(.loading) .loading-text {
  background: rgba(10, 10, 18, 0.78);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 999px;
  bottom: 1rem;
  left: auto;
  padding: 0.45rem 0.85rem;
  right: 1rem;
  top: auto;
  transform: none;
}

.game-actions {
  align-items: center;
  display: flex;
  flex-wrap: wrap;
  gap: 1rem;
  justify-content: space-between;
  margin-top: 1rem;
}

.helper-text {
  margin: 0;
  max-width: 52ch;
}

.button-secondary {
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid rgba(255, 255, 255, 0.12);
  color: var(--text);
}

.button-secondary:hover,
.button-secondary:focus-visible {
  background: rgba(255, 255, 255, 0.09);
  color: #fff;
}

.embed-fallback {
  align-items: flex-start;
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 16px;
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
  margin-top: 1rem;
  padding: 1rem;
}

.embed-fallback__title {
  font-weight: 700;
  margin: 0;
}

.embed-fallback__text {
  color: var(--muted);
  margin: 0;
}

.ad-slot {
  align-items: center;
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.035) 0%, rgba(255, 255, 255, 0.02) 100%);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 16px;
  color: rgba(224, 228, 242, 0.82);
  display: flex;
  flex-direction: column;
  gap: 0.3rem;
  justify-content: center;
  padding: 0.9rem;
  text-align: center;
}

.ad-slot__eyebrow {
  color: rgba(184, 189, 211, 0.7);
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.14em;
  text-transform: uppercase;
}

.ad-slot__name {
  font-size: 0.95rem;
  font-weight: 700;
}

.ad-slot__size {
  color: rgba(184, 189, 211, 0.82);
  font-size: 0.9rem;
}

.ad-slot small {
  font-weight: 500;
}

.ad-banner {
  min-height: 90px;
  width: 100%;
}

.ad-skyscraper {
  min-height: 600px;
  width: 160px;
}

.ad-rectangle {
  margin: 2rem auto;
  max-width: 336px;
  min-height: 280px;
}

.ad-sticky {
  bottom: 0;
  display: none;
  left: 50%;
  min-height: 50px;
  position: fixed;
  transform: translateX(-50%);
  width: min(100%, 360px);
  z-index: 45;
}

.ad-sticky .ad-slot__eyebrow {
  display: none;
}

.content-section {
  padding: 1rem 0 6rem;
}

article + article {
  margin-top: 1.5rem;
}

ol,
ul {
  padding-left: 1.2rem;
}

.faq-list {
  display: grid;
  gap: 1rem;
}

.faq-item {
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 16px;
  padding: 1rem;
}

.troubleshooting-list {
  margin-bottom: 1rem;
}

.embed-fallback__list {
  color: var(--muted);
  margin: 0;
  padding-left: 1.15rem;
}

.embed-fallback__list li + li {
  margin-top: 0.45rem;
}

.cookie-banner {
  align-items: center;
  background: rgba(15, 15, 26, 0.96);
  border-top: 1px solid rgba(255, 255, 255, 0.08);
  bottom: 0;
  box-shadow: 0 -12px 30px rgba(0, 0, 0, 0.28);
  display: flex;
  gap: 1rem;
  justify-content: center;
  left: 0;
  padding: 1rem;
  position: fixed;
  right: 0;
  z-index: 50;
}

.cookie-banner.is-hidden {
  display: none;
}

.inline-button {
  margin-top: 0.75rem;
}

.disclaimer {
  font-size: 0.92rem;
}

.site-footer {
  border-top: 1px solid rgba(255, 255, 255, 0.06);
  padding-bottom: 1rem;
  padding-top: 1rem;
}

.footer-inner {
  align-items: flex-start;
  flex-direction: column;
  min-height: auto;
}

@keyframes spin {
  to {
    transform: rotate(360deg);
  }
}

@media (max-width: 1024px) {
  .game-layout {
    grid-template-columns: minmax(0, 1fr) 160px;
    grid-template-areas:
      'main right'
      'main left';
  }

  .game-column {
    grid-area: main;
  }

  .rail-right {
    grid-area: right;
  }

  .rail-left {
    grid-area: left;
  }

  .ad-banner {
    min-height: 90px;
  }
}

@media (max-width: 767px) {
  :root {
    --header-height: 64px;
  }

  .header-inner {
    align-items: flex-start;
    flex-direction: column;
  }

  .main-nav {
    gap: 0.75rem;
  }

  .game-layout {
    grid-template-columns: 1fr;
    grid-template-areas:
      'main'
      'left'
      'right';
  }

  .rail {
    width: 100%;
  }

  .ad-skyscraper {
    min-height: 250px;
    width: 100%;
  }

  .iframe-shell,
  .iframe-shell iframe {
    min-height: 400px;
  }

  .embed-fallback,
  .game-panel,
  article,
  .legal-page {
    padding: 1rem;
  }

  .cookie-banner {
    align-items: stretch;
    flex-direction: column;
  }
}

@media (max-width: 479px) {
  body {
    padding-bottom: var(--sticky-height);
  }

  .hero-section {
    padding-top: 1rem;
  }

  .iframe-shell,
  .iframe-shell iframe {
    min-height: 300px;
  }

  .loading-text {
    font-size: 0.92rem;
  }

  .rail {
    display: none;
  }

  .ad-sticky {
    display: flex;
  }

  .game-actions {
    align-items: stretch;
    flex-direction: column;
  }
}
