/* ============ HavFun promo site design system ============ */
:root {
  --bg: #050a26;
  --bg-2: #081033;
  --surface: #0d1746;
  --surface-2: #121d55;
  --surface-3: #182463;
  --line: rgba(120, 145, 255, 0.18);
  --line-strong: rgba(120, 145, 255, 0.35);

  --primary: #2f7dff;
  --primary-2: #5c9dff;
  --cyan: #41d8ff;
  --purple: #8b5cf6;
  --pink: #ff5fa2;
  --gold: #ffc531;
  --green: #2fd67b;
  --red: #ff5a5a;

  --text: #eaf0ff;
  --muted: #93a5d9;
  --dim: #5f6f9f;

  --radius: 14px;
  --radius-sm: 10px;
  --shadow: 0 10px 30px rgba(2, 6, 30, 0.55);
  --font: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Apple SD Gothic Neo',
    'Noto Sans KR', 'Malgun Gothic', sans-serif;
}

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

html {
  scroll-behavior: smooth;
}

body {
  font-family: var(--font);
  background:
    radial-gradient(900px 480px at 85% -5%, rgba(124, 77, 255, 0.22), transparent 60%),
    radial-gradient(800px 420px at 5% 10%, rgba(47, 125, 255, 0.16), transparent 55%),
    var(--bg);
  color: var(--text);
  line-height: 1.6;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

main {
  flex: 1;
}

img {
  max-width: 100%;
}

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

button {
  font-family: inherit;
  cursor: pointer;
}

input {
  font-family: inherit;
}

::-webkit-scrollbar {
  width: 10px;
  height: 10px;
}
::-webkit-scrollbar-thumb {
  background: var(--surface-3);
  border-radius: 8px;
}
::-webkit-scrollbar-track {
  background: transparent;
}

.container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 24px;
}

/* ============ header ============ */
.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: rgba(4, 8, 30, 0.86);
  backdrop-filter: blur(14px);
  border-bottom: 1px solid var(--line);
}

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

.brand {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  font-weight: 800;
  font-size: 22px;
  font-style: italic;
  letter-spacing: -0.5px;
  white-space: nowrap;
}

.brand-steam {
  font-size: 12px;
  font-style: normal;
  background: linear-gradient(135deg, var(--primary), var(--cyan));
  padding: 2px 8px;
  border-radius: 6px;
  letter-spacing: 0.5px;
}

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

.nav-link {
  padding: 8px 12px;
  border-radius: 8px;
  font-size: 14.5px;
  font-weight: 600;
  color: var(--muted);
  white-space: nowrap;
  transition: color 0.15s, background 0.15s;
}

.nav-link:hover {
  color: var(--text);
  background: rgba(120, 145, 255, 0.1);
}

.nav-link.active {
  color: var(--cyan);
  position: relative;
}

.nav-link.active::after {
  content: '';
  position: absolute;
  left: 12px;
  right: 12px;
  bottom: 2px;
  height: 2px;
  border-radius: 2px;
  background: var(--cyan);
}

.header-actions {
  display: flex;
  align-items: center;
  gap: 10px;
  white-space: nowrap;
}

.nav-toggle {
  display: none;
  background: none;
  border: 1px solid var(--line);
  color: var(--text);
  border-radius: 8px;
  padding: 6px 10px;
  font-size: 16px;
}

/* ============ buttons ============ */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 7px;
  border: none;
  border-radius: 10px;
  font-weight: 700;
  font-size: 15px;
  line-height: 1.2;
  padding: 12px 22px;
  transition: transform 0.12s, box-shadow 0.12s, background 0.15s, border-color 0.15s;
}

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

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

.btn-primary {
  background: linear-gradient(135deg, #2f7dff, #2b5cff);
  color: #fff;
  box-shadow: 0 6px 18px rgba(47, 125, 255, 0.35);
}

.btn-cyan {
  background: linear-gradient(135deg, #41d8ff, #2fa8ff);
  color: #04122e;
  box-shadow: 0 6px 18px rgba(65, 216, 255, 0.3);
}

.btn-purple {
  background: linear-gradient(135deg, #8b5cf6, #6d3df0);
  color: #fff;
  box-shadow: 0 6px 18px rgba(139, 92, 246, 0.35);
}

.btn-outline {
  background: rgba(120, 145, 255, 0.07);
  border: 1px solid var(--line-strong);
  color: var(--text);
}

.btn-outline:hover {
  background: rgba(120, 145, 255, 0.14);
}

.btn-sm {
  padding: 8px 14px;
  font-size: 13px;
  border-radius: 8px;
}

.btn-lg {
  padding: 15px 30px;
  font-size: 16.5px;
}

.btn-block {
  width: 100%;
}

/* ============ sections / cards ============ */
.section {
  padding: 46px 0 8px;
}

.section-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 20px;
}

.section-title {
  font-size: 23px;
  font-weight: 800;
  padding-left: 14px;
  position: relative;
}

.section-title::before {
  content: '';
  position: absolute;
  left: 0;
  top: 6px;
  bottom: 6px;
  width: 4px;
  border-radius: 4px;
  background: linear-gradient(180deg, var(--cyan), var(--purple));
}

.section-link {
  color: var(--cyan);
  font-size: 14px;
  font-weight: 600;
}

.section-link:hover {
  text-decoration: underline;
}

.card {
  background: linear-gradient(180deg, var(--surface), var(--bg-2));
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 22px;
}

.card-hover {
  transition: transform 0.15s, border-color 0.15s, box-shadow 0.15s;
}

.card-hover:hover {
  transform: translateY(-3px);
  border-color: var(--line-strong);
  box-shadow: var(--shadow);
}

.grid-2,
.grid-3,
.grid-4 {
  display: grid;
  gap: 16px;
}
.grid-2 {
  grid-template-columns: repeat(2, 1fr);
}
.grid-3 {
  grid-template-columns: repeat(3, 1fr);
}
.grid-4 {
  grid-template-columns: repeat(4, 1fr);
}

/* ============ badges / stars ============ */
.badge {
  display: inline-flex;
  align-items: center;
  padding: 3px 10px;
  border-radius: 999px;
  font-size: 11.5px;
  font-weight: 700;
  letter-spacing: 0.2px;
}

.badge-purple {
  background: rgba(139, 92, 246, 0.2);
  color: #c0a4ff;
}

.badge-gold {
  background: rgba(255, 197, 49, 0.16);
  color: #ffd76b;
}

.stars .star {
  color: var(--dim);
  font-size: 14px;
}
.stars .star.on {
  color: var(--gold);
}

/* ============ game card ============ */
.game-card {
  background: linear-gradient(180deg, var(--surface), var(--bg-2));
  border: 1px solid var(--line);
  border-radius: var(--radius);
  overflow: hidden;
  display: flex;
  flex-direction: column;
  cursor: pointer;
  transition: transform 0.15s, border-color 0.15s, box-shadow 0.15s;
}

.game-card:hover,
.game-card:focus-visible {
  transform: translateY(-4px);
  border-color: var(--line-strong);
  box-shadow: var(--shadow);
}

.game-thumb {
  position: relative;
  aspect-ratio: 640 / 548;
  overflow: hidden;
  display: flex;
  align-items: center;
  justify-content: center;
}

.game-emoji {
  font-size: 52px;
  filter: drop-shadow(0 6px 12px rgba(0, 0, 0, 0.35));
}

.game-thumb-img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.game-new {
  position: absolute;
  top: 10px;
  left: 10px;
  background: var(--pink);
  color: #fff;
  font-size: 10.5px;
  font-weight: 800;
  padding: 2px 8px;
  border-radius: 6px;
  z-index: 1;
}

.game-body {
  padding: 14px 14px 16px;
  display: flex;
  flex-direction: column;
  gap: 8px;
  flex: 1;
}

.game-title {
  font-size: 16.5px;
  font-weight: 800;
}

.game-body .badge {
  align-self: flex-start;
}

.game-tagline {
  font-size: 12.5px;
  color: var(--muted);
  flex: 1;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.game-meta {
  font-size: 11.5px;
  color: var(--dim);
}

/* ============ FAQ ============ */
.faq-list {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.faq-item {
  background: linear-gradient(180deg, var(--surface), var(--bg-2));
  border: 1px solid var(--line);
  border-radius: var(--radius-sm);
  overflow: hidden;
}

.faq-item.open {
  border-color: var(--line-strong);
}

.faq-q {
  width: 100%;
  display: flex;
  align-items: center;
  gap: 12px;
  background: none;
  border: none;
  color: var(--text);
  padding: 15px 18px;
  font-size: 14.5px;
  font-weight: 600;
  text-align: left;
}

.faq-icon {
  flex-shrink: 0;
  width: 24px;
  height: 24px;
  border-radius: 50%;
  background: rgba(65, 216, 255, 0.14);
  color: var(--cyan);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 13px;
  font-weight: 800;
}

.faq-question {
  flex: 1;
}

.faq-chevron {
  color: var(--dim);
  transition: transform 0.15s;
}

.faq-item.open .faq-chevron {
  transform: rotate(180deg);
}

.faq-a {
  display: none;
  padding: 0 18px 16px 54px;
  color: var(--muted);
  font-size: 13.5px;
}

.faq-item.open .faq-a {
  display: block;
}

/* ============ modal ============ */
.modal-overlay {
  position: fixed;
  inset: 0;
  background: rgba(2, 5, 20, 0.75);
  backdrop-filter: blur(4px);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 100;
  padding: 20px;
}

.modal-box {
  position: relative;
  width: 100%;
  max-width: 620px;
  background: linear-gradient(180deg, var(--surface-2), var(--bg-2));
  border: 1px solid var(--line-strong);
  border-radius: 16px;
  padding: 28px;
  max-height: 86vh;
  overflow-y: auto;
  box-shadow: var(--shadow);
}

.modal-close {
  position: absolute;
  top: 14px;
  right: 14px;
  background: rgba(120, 145, 255, 0.1);
  border: none;
  color: var(--muted);
  width: 32px;
  height: 32px;
  border-radius: 50%;
  font-size: 14px;
  z-index: 1;
}

.modal-close:hover {
  color: var(--text);
}

.modal-box .modal-thumb {
  aspect-ratio: 640 / 320;
  border-radius: var(--radius-sm);
  margin-bottom: 18px;
}

.modal-head {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 10px;
}

.modal-title {
  font-size: 22px;
  font-weight: 800;
}

.modal-desc {
  color: var(--muted);
  font-size: 14px;
  margin-bottom: 16px;
}

.modal-meta {
  display: flex;
  flex-direction: column;
  gap: 8px;
  margin-bottom: 20px;
}

.modal-row {
  display: flex;
  align-items: center;
  gap: 14px;
  font-size: 13.5px;
}

.modal-row dt {
  width: 90px;
  color: var(--dim);
  font-weight: 700;
  flex-shrink: 0;
}

.modal-row dd {
  display: flex;
  align-items: center;
  gap: 8px;
}

.modal-diff {
  color: var(--muted);
  font-size: 12.5px;
}

/* ============ page hero ============ */
.page-hero {
  position: relative;
  padding: 56px 0 40px;
  background:
    radial-gradient(700px 320px at 80% 0%, rgba(124, 77, 255, 0.28), transparent 60%),
    radial-gradient(500px 260px at 15% 20%, rgba(47, 125, 255, 0.22), transparent 55%);
  border-bottom: 1px solid var(--line);
  overflow: hidden;
}

.page-hero h1 {
  font-size: 38px;
  font-weight: 900;
  letter-spacing: -0.5px;
  line-height: 1.25;
}

.page-hero .hero-accent {
  background: linear-gradient(135deg, #5c9dff, #41d8ff);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

.page-hero .hero-sub {
  margin-top: 14px;
  color: var(--muted);
  font-size: 15px;
  max-width: 560px;
}

.hero-inner {
  display: grid;
  grid-template-columns: 1.1fr 0.9fr;
  gap: 40px;
  align-items: center;
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-top: 26px;
}

/* hero: required social casino notices (age / no real money, in-game purchases) */
.hero-notice {
  display: inline-block;
  margin-top: 18px;
  padding: 8px 12px;
  border: 1px solid rgba(255, 197, 49, 0.35);
  border-radius: var(--radius-sm);
  background: rgba(255, 197, 49, 0.08);
  color: var(--text);
  font-size: 13px;
}

.hero-notice-iap {
  display: block;
  width: fit-content;
  margin-top: 14px;
  border-color: var(--line-strong);
  background: var(--surface);
  color: var(--muted);
  font-size: 12.5px;
}

.hero-art {
  position: relative;
  display: flex;
  justify-content: center;
}

.hero-art-main {
  max-height: 340px;
  object-fit: contain;
  filter: drop-shadow(0 20px 40px rgba(2, 6, 30, 0.6));
}

.hero-gems {
  position: absolute;
  top: -18px;
  right: 6%;
  width: 120px;
  animation: float 4s ease-in-out infinite;
}

.hero-star {
  width: 34px;
  vertical-align: middle;
  margin-left: 8px;
}

.hero-line {
  display: block;
}

.hero-line-pink {
  background: linear-gradient(135deg, #ff5fa2, #ffc531);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

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

/* ============ home: features ============ */
.home-features-section {
  padding-top: 34px;
}

.home-feature {
  display: flex;
  align-items: center;
  gap: 16px;
}

.home-feature-icon {
  flex-shrink: 0;
  width: 58px;
  height: 58px;
  border-radius: 14px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 26px;
  overflow: hidden;
}

.home-feature-icon img {
  width: 100%;
  height: 100%;
  object-fit: contain;
}

.home-feature h3 {
  font-size: 16px;
}

.home-feature p {
  color: var(--muted);
  font-size: 13px;
}

/* ============ home: arcade banner ============ */
.home-arcade {
  position: relative;
  display: grid;
  grid-template-columns: 1fr auto;
  align-items: center;
  gap: 24px;
  overflow: hidden;
  padding: 34px;
  min-height: 220px;
}

.home-arcade-banner {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  opacity: 0.55;
}

.home-arcade-info {
  position: relative;
  max-width: 480px;
}

.home-arcade-neon {
  color: var(--cyan);
  font-size: 12px;
  font-weight: 800;
  letter-spacing: 3px;
}

.home-arcade-info h2 {
  font-size: 28px;
  font-weight: 900;
  margin: 6px 0 10px;
}

.home-arcade-info p {
  color: var(--text);
  font-size: 14px;
  margin-bottom: 18px;
  text-shadow: 0 2px 8px rgba(2, 6, 30, 0.8);
}

.home-arcade-info .home-arcade-note {
  display: inline-block;
  margin-top: -6px;
  padding: 6px 10px;
  border-radius: var(--radius-sm);
  background: rgba(4, 8, 28, 0.72);
  font-size: 12.5px;
}

/* ============ home: steps ============ */
.home-step {
  text-align: center;
}

.home-step-icon {
  width: 74px;
  height: 74px;
  margin: 0 auto 14px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(120, 145, 255, 0.1);
  overflow: hidden;
}

.home-step-icon img {
  width: 70%;
  height: 70%;
  object-fit: contain;
}

.home-step h3 {
  font-size: 15.5px;
  margin-bottom: 6px;
}

.home-step p {
  color: var(--muted);
  font-size: 12.5px;
}

/* ============ games: filter bar ============ */
.games-filterbar {
  display: flex;
  flex-direction: column;
  gap: 14px;
}

.games-filter-top {
  display: flex;
  align-items: center;
  gap: 16px;
  flex-wrap: wrap;
}

.games-cats {
  display: flex;
  gap: 6px;
  flex-wrap: wrap;
  flex: 1;
}

.games-cat {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  background: rgba(120, 145, 255, 0.06);
  border: 1px solid transparent;
  border-radius: 999px;
  color: var(--muted);
  font-size: 13px;
  font-weight: 700;
  padding: 7px 14px;
  transition: color 0.15s, background 0.15s, border-color 0.15s;
}

.games-cat:hover {
  color: var(--text);
  background: rgba(120, 145, 255, 0.12);
}

.games-cat.active {
  color: var(--cyan);
  border-color: rgba(65, 216, 255, 0.5);
  background: rgba(65, 216, 255, 0.1);
}

.games-cat-icon {
  width: 20px;
  height: 20px;
  object-fit: contain;
}

.games-search {
  position: relative;
  width: 220px;
}

.games-search input {
  width: 100%;
  background: rgba(6, 12, 40, 0.7);
  border: 1px solid var(--line);
  border-radius: 999px;
  color: var(--text);
  padding: 9px 38px 9px 16px;
  font-size: 13.5px;
  outline: none;
}

.games-search input:focus {
  border-color: var(--primary-2);
}

.games-search input::placeholder {
  color: var(--dim);
}

.games-search-icon {
  position: absolute;
  right: 14px;
  top: 50%;
  transform: translateY(-50%);
  color: var(--dim);
}

.games-sorts {
  display: flex;
  gap: 6px;
}

.games-sort {
  background: none;
  border: none;
  color: var(--dim);
  font-size: 13px;
  font-weight: 700;
  padding: 4px 10px;
  border-radius: 8px;
}

.games-sort:hover {
  color: var(--text);
}

.games-sort.active {
  color: var(--cyan);
  background: rgba(65, 216, 255, 0.1);
}

/* ============ games: featured ============ */
.games-featured {
  position: relative;
  display: grid;
  grid-template-columns: 340px 1fr;
  gap: 26px;
  padding: 26px;
}

.games-featured-ribbon {
  position: absolute;
  top: -12px;
  left: 24px;
  background: linear-gradient(135deg, var(--pink), var(--purple));
  color: #fff;
  font-size: 12px;
  font-weight: 800;
  padding: 4px 14px;
  border-radius: 999px;
  box-shadow: 0 4px 14px rgba(255, 95, 162, 0.4);
}

.games-featured .game-thumb {
  border-radius: var(--radius-sm);
  aspect-ratio: 640 / 548;
}

.games-featured-label {
  color: var(--cyan);
  font-size: 12.5px;
  font-weight: 700;
}

.games-featured-titlerow {
  display: flex;
  align-items: center;
  gap: 12px;
  margin: 4px 0 10px;
}

.games-featured-title {
  font-size: 26px;
  font-weight: 900;
}

.games-featured-desc {
  color: var(--muted);
  font-size: 14px;
  margin-bottom: 16px;
}

.games-featured-metas {
  display: flex;
  flex-wrap: wrap;
  gap: 10px 28px;
  margin-bottom: 20px;
  font-size: 13.5px;
}

.games-featured-meta {
  display: flex;
  align-items: center;
  gap: 8px;
}

.games-meta-label {
  color: var(--dim);
  font-weight: 700;
  font-size: 12.5px;
}

.games-featured-actions {
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
}

/* ============ games: usage cards ============ */
.games-usage {
  display: flex;
  align-items: flex-start;
  gap: 14px;
}

.games-usage-icon {
  flex-shrink: 0;
  width: 52px;
  height: 52px;
  border-radius: 13px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
}

.games-usage-icon img {
  width: 72%;
  height: 72%;
  object-fit: contain;
}

.games-usage h3 {
  font-size: 14.5px;
  margin-bottom: 5px;
}

.games-usage p {
  color: var(--muted);
  font-size: 12.5px;
}

/* ============ guide layout ============ */
.guide-layout {
  display: grid;
  grid-template-columns: 220px 1fr 250px;
  gap: 24px;
  padding-top: 34px;
  align-items: start;
}

.guide-sidebar,
.guide-rail {
  position: sticky;
  top: 84px;
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.guide-menu {
  display: flex;
  flex-direction: column;
  gap: 4px;
  background: linear-gradient(180deg, var(--surface), var(--bg-2));
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 12px;
}

.guide-menu-item {
  display: flex;
  align-items: center;
  gap: 10px;
  background: none;
  border: none;
  color: var(--muted);
  font-size: 13.5px;
  font-weight: 600;
  text-align: left;
  padding: 9px 12px;
  border-radius: 9px;
  transition: color 0.15s, background 0.15s;
}

.guide-menu-item:hover {
  color: var(--text);
  background: rgba(120, 145, 255, 0.1);
}

.guide-promo {
  background: linear-gradient(180deg, var(--surface), var(--bg-2));
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 18px;
  text-align: center;
}

.guide-promo h3 {
  font-size: 14.5px;
  margin-bottom: 6px;
}

.guide-promo p {
  color: var(--muted);
  font-size: 12.5px;
  margin-bottom: 12px;
}

.guide-promo img {
  max-height: 110px;
  margin-bottom: 12px;
}

.guide-hero {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 20px;
  align-items: center;
  background:
    radial-gradient(400px 200px at 85% 20%, rgba(124, 77, 255, 0.3), transparent 60%),
    linear-gradient(180deg, var(--surface-2), var(--bg-2));
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 28px;
  margin-bottom: 30px;
}

.guide-hero h1 {
  font-size: 34px;
  font-weight: 900;
  letter-spacing: 2px;
  background: linear-gradient(135deg, #5c9dff, #41d8ff);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

.guide-hero-sub {
  color: var(--muted);
  font-size: 14px;
  max-width: 420px;
  margin-top: 8px;
}

.guide-bubble-wrap {
  display: flex;
  align-items: flex-end;
  gap: 12px;
}

.guide-bubble {
  background: rgba(65, 216, 255, 0.1);
  border: 1px solid rgba(65, 216, 255, 0.35);
  border-radius: 14px;
  padding: 12px 16px;
  font-size: 12.5px;
  color: var(--muted);
  max-width: 220px;
}

.guide-bubble strong {
  display: block;
  color: var(--text);
  margin-bottom: 4px;
}

.guide-bubble-bot {
  width: 84px;
  flex-shrink: 0;
}

.guide-section {
  margin-bottom: 40px;
  scroll-margin-top: 84px;
}

.guide-h2 {
  font-size: 20px;
  font-weight: 800;
  margin-bottom: 18px;
  padding-left: 12px;
  position: relative;
}

.guide-h2::before {
  content: '';
  position: absolute;
  left: 0;
  top: 5px;
  bottom: 5px;
  width: 4px;
  border-radius: 4px;
  background: linear-gradient(180deg, var(--cyan), var(--purple));
}

.guide-steps {
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  gap: 12px;
}

.guide-step {
  background: linear-gradient(180deg, var(--surface), var(--bg-2));
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 16px 14px;
  text-align: center;
}

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

.guide-step-num {
  color: var(--cyan);
  font-size: 13px;
  font-weight: 900;
}

.guide-step-title {
  font-size: 13.5px;
  font-weight: 800;
}

.guide-step-ico {
  display: block;
  height: 64px;
  margin-bottom: 10px;
}

.guide-step-ico img {
  height: 100%;
  object-fit: contain;
}

.guide-step p {
  color: var(--muted);
  font-size: 12px;
}

/* guide: play tabs */
.guide-play-card {
  background: linear-gradient(180deg, var(--surface), var(--bg-2));
  border: 1px solid var(--line);
  border-radius: var(--radius);
  overflow: hidden;
}

.guide-tabs {
  display: flex;
  border-bottom: 1px solid var(--line);
}

.guide-tab {
  flex: 1;
  background: none;
  border: none;
  color: var(--muted);
  font-size: 13.5px;
  font-weight: 700;
  padding: 14px 8px;
  border-bottom: 2px solid transparent;
  transition: color 0.15s, border-color 0.15s;
}

.guide-tab:hover {
  color: var(--text);
}

.guide-tab.active {
  color: var(--cyan);
  border-bottom-color: var(--cyan);
}

.guide-play-body {
  display: grid;
  grid-template-columns: 1fr 300px;
  gap: 22px;
  padding: 22px;
}

/* display: grid overrides the UA [hidden] rule, so hide explicitly */
.guide-tabpanel[hidden] {
  display: none;
}

.guide-play-steps {
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.guide-play-step {
  display: flex;
  align-items: flex-start;
  gap: 14px;
}

.guide-play-ico {
  flex-shrink: 0;
  width: 44px;
  height: 44px;
  border-radius: 12px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 20px;
  overflow: hidden;
}

.guide-play-ico img {
  width: 70%;
  height: 70%;
  object-fit: contain;
}

.guide-ic-gold { background: rgba(255, 197, 49, 0.14); }
.guide-ic-purple { background: rgba(139, 92, 246, 0.18); }
.guide-ic-green { background: rgba(47, 214, 123, 0.14); }
.guide-ic-pink { background: rgba(255, 95, 162, 0.16); }
.guide-ic-cyan { background: rgba(65, 216, 255, 0.14); }
.guide-ic-blue { background: rgba(47, 125, 255, 0.16); }

.guide-play-step h4 {
  font-size: 14px;
  margin-bottom: 3px;
}

.guide-play-step p {
  color: var(--muted);
  font-size: 12.5px;
}

.guide-play-visual {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.guide-play-art,
.guide-play-art-img {
  width: 100%;
  aspect-ratio: 4 / 3;
  border-radius: var(--radius-sm);
  object-fit: cover;
}

.guide-play-art {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 14px;
  font-size: 42px;
  position: relative;
}

.guide-art-spark {
  position: absolute;
  color: rgba(255, 255, 255, 0.7);
  font-size: 18px;
}

.guide-art-spark.s1 { top: 14%; left: 12%; }
.guide-art-spark.s2 { bottom: 16%; right: 12%; }

.guide-play-caption {
  color: var(--muted);
  font-size: 12px;
  text-align: center;
}

.guide-play-notice {
  margin-top: 14px;
  padding: 12px 16px;
  border: 1px solid rgba(255, 197, 49, 0.3);
  border-radius: var(--radius-sm);
  background: rgba(255, 197, 49, 0.06);
  color: var(--muted);
  font-size: 12.5px;
  line-height: 1.6;
}

/* guide: right rail */
.guide-rail-card {
  background: linear-gradient(180deg, var(--surface), var(--bg-2));
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 18px;
}

.guide-rail-title {
  font-size: 14.5px;
  margin-bottom: 12px;
}

.guide-help-list {
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.guide-help-row {
  display: flex;
  align-items: center;
  gap: 10px;
  color: var(--muted);
  font-size: 13px;
  font-weight: 600;
  padding: 8px 10px;
  border-radius: 9px;
  transition: color 0.15s, background 0.15s;
}

.guide-help-row:hover {
  color: var(--text);
  background: rgba(120, 145, 255, 0.1);
}

.guide-help-arrow {
  margin-left: auto;
  color: var(--dim);
}

.guide-spec-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 12.5px;
}

.guide-spec-table th {
  text-align: left;
  color: var(--dim);
  font-weight: 700;
  padding: 7px 8px 7px 0;
  white-space: nowrap;
  vertical-align: top;
  width: 74px;
}

.guide-spec-table td {
  padding: 7px 0;
  color: var(--muted);
}

.guide-spec-table tr + tr th,
.guide-spec-table tr + tr td {
  border-top: 1px solid var(--line);
}

.guide-contact {
  text-align: center;
}

.guide-contact p {
  color: var(--muted);
  font-size: 12.5px;
  margin-bottom: 12px;
}

.guide-contact img {
  max-height: 90px;
  margin-bottom: 12px;
}

/* ============ footer ============ */
.site-footer {
  margin-top: 70px;
  border-top: 1px solid var(--line);
  background: rgba(4, 8, 28, 0.7);
}

.footer-inner {
  display: grid;
  grid-template-columns: 1.4fr 0.8fr 0.8fr 1fr;
  gap: 28px;
  padding: 44px 24px 30px;
}

.footer-tagline {
  color: var(--muted);
  font-size: 13px;
  margin-top: 10px;
}

.footer-social {
  display: flex;
  gap: 10px;
  margin-top: 16px;
  font-size: 18px;
}

.footer-social span {
  width: 36px;
  height: 36px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: 10px;
}

.footer-col {
  display: flex;
  flex-direction: column;
  gap: 9px;
}

.footer-col h4 {
  font-size: 14px;
  margin-bottom: 4px;
}

.footer-col a {
  color: var(--muted);
  font-size: 13px;
}

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

/* footer: required disclosures (age, helpline, terms, privacy, operator) */
.footer-legal {
  display: flex;
  flex-direction: column;
  gap: 10px;
  padding-bottom: 24px;
  color: var(--muted);
  font-size: 12.5px;
  line-height: 1.6;
}

.footer-notice strong {
  color: var(--text);
}

.footer-legal a {
  color: var(--cyan);
}

.footer-legal-links {
  display: flex;
  flex-wrap: wrap;
  gap: 18px;
  font-weight: 600;
}

.footer-company {
  color: var(--dim);
}

.footer-copy {
  text-align: center;
  color: var(--dim);
  font-size: 12.5px;
  padding: 18px 0 26px;
  border-top: 1px solid var(--line);
}

/* ============ legal pages (terms / privacy) ============ */
.legal-doc {
  max-width: 860px;
  margin: 0 auto;
  padding: 40px 44px;
  background: linear-gradient(180deg, var(--surface), var(--bg-2));
  border: 1px solid var(--line);
  border-radius: var(--radius);
  color: var(--muted);
  font-size: 14.5px;
  line-height: 1.75;
}

.legal-doc h1 {
  color: var(--text);
  font-size: 32px;
}

.legal-doc h1 + p {
  color: var(--cyan);
  font-weight: 700;
  letter-spacing: 0.04em;
  margin-top: 4px;
}

.legal-doc > div {
  padding: 26px 0;
  border-top: 1px solid var(--line);
}

.legal-doc > div:first-child {
  padding-top: 0;
  border-top: 0;
  padding-bottom: 22px;
}

.legal-doc h2 {
  color: var(--text);
  font-size: 19px;
  margin-bottom: 12px;
}

.legal-doc h3 {
  color: var(--text);
  font-size: 15px;
  margin: 16px 0 6px;
}

.legal-doc p + p,
.legal-doc ul + p {
  margin-top: 10px;
}

.legal-doc ul {
  margin: 8px 0 0 20px;
}

.legal-doc li + li {
  margin-top: 4px;
}

.legal-doc strong {
  color: var(--text);
  font-weight: 700;
}

/* ============ responsive ============ */
@media (max-width: 1024px) {
  .grid-4 {
    grid-template-columns: repeat(3, 1fr);
  }
  .grid-3 {
    grid-template-columns: repeat(2, 1fr);
  }
  .footer-inner {
    grid-template-columns: 1fr 1fr;
  }
  .main-nav {
    display: none;
  }
  .main-nav.open {
    display: flex;
    position: absolute;
    top: 64px;
    left: 0;
    right: 0;
    flex-direction: column;
    align-items: stretch;
    background: rgba(4, 8, 30, 0.98);
    border-bottom: 1px solid var(--line);
    padding: 12px 20px;
  }
  .nav-toggle {
    display: inline-flex;
  }
  .hero-inner,
  .games-featured,
  .guide-play-body {
    grid-template-columns: 1fr;
  }
  .guide-layout {
    grid-template-columns: 1fr;
  }
  .guide-sidebar,
  .guide-rail {
    position: static;
  }
  .guide-steps {
    grid-template-columns: repeat(2, 1fr);
  }
  .home-arcade {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 680px) {
  .legal-doc {
    padding: 26px 20px;
  }
  .legal-doc h1 {
    font-size: 26px;
  }
  .grid-2,
  .grid-3,
  .grid-4 {
    grid-template-columns: 1fr;
  }
  .page-hero h1 {
    font-size: 28px;
  }
  .footer-inner {
    grid-template-columns: 1fr;
  }
  .header-actions .btn-cyan {
    display: none;
  }
  .guide-steps {
    grid-template-columns: 1fr;
  }
  .guide-hero {
    grid-template-columns: 1fr;
  }
}
