:root {
  --bg: #0b0b1a;
  --bg2: #141432;
  --card: rgba(255, 255, 255, 0.05);
  --line: rgba(255, 255, 255, 0.12);
  --text: #f3f1ff;
  --muted: #b3b0cf;
  --accent: #7df9ff;
  --pink: #ff5d8f;
  --gold: #ffd24d;
  --radius: 22px;
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  margin: 0;
  font-family: "Nunito", system-ui, -apple-system, "Segoe UI", sans-serif;
  color: var(--text);
  background:
    radial-gradient(900px 600px at 10% -10%, rgba(138, 92, 255, 0.28), transparent 60%),
    radial-gradient(800px 600px at 100% 10%, rgba(31, 211, 176, 0.18), transparent 60%),
    var(--bg);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

/* lingua: si vede solo il testo della lingua scelta */
html:not([data-lang="en"]) body [lang="en"],
html:not([data-lang="it"]) body [lang="it"],
html:not([data-lang="es"]) body [lang="es"],
html:not([data-lang="fr"]) body [lang="fr"],
html:not([data-lang="de"]) body [lang="de"],
html:not([data-lang="pt"]) body [lang="pt"],
html:not([data-lang="ru"]) body [lang="ru"],
html:not([data-lang="tr"]) body [lang="tr"],
html:not([data-lang="ja"]) body [lang="ja"],
html:not([data-lang="ko"]) body [lang="ko"] { display: none !important; }

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

.wrap { max-width: 1080px; margin: 0 auto; padding: 0 20px; }

/* barra in alto */
.top {
  position: sticky; top: 0; z-index: 10;
  background: rgba(11, 11, 26, 0.75);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--line);
}
.top .wrap { display: flex; align-items: center; justify-content: space-between; height: 64px; gap: 12px; }
.brand { display: flex; align-items: center; gap: 10px; font-weight: 900; color: var(--text); text-decoration: none; letter-spacing: .3px; }
.brand-mark {
  width: 34px; height: 34px; border-radius: 10px;
  background: conic-gradient(from 200deg, #ff5d8f, #ffd93d, #3ddc97, #38bdf8, #a78bfa, #ff5d8f);
  display: grid; place-items: center; font-size: 16px; color: #120a2a;
}
.nav { display: flex; align-items: center; gap: 18px; }
.nav a { color: var(--muted); text-decoration: none; font-weight: 700; font-size: 15px; }
.nav a:hover { color: var(--text); }
.lang {
  border: 1px solid var(--line); background: transparent; color: var(--text);
  border-radius: 999px; padding: 6px 12px; font-weight: 800; cursor: pointer; font-family: inherit;
}

/* intestazione */
.hero { padding-top: 84px; padding-bottom: 56px; text-align: center; }
.hero h1 {
  font-size: clamp(40px, 7vw, 76px); line-height: 1.02; margin: 0 0 18px; font-weight: 900; letter-spacing: -1px;
}
.hero h1 .grad {
  background: linear-gradient(90deg, #ff5d8f, #ffd93d, #3ddc97, #38bdf8, #a78bfa);
  -webkit-background-clip: text; background-clip: text; color: transparent;
}
.hero p { color: var(--muted); font-size: 19px; max-width: 640px; margin: 0 auto; }
.pills { display: flex; flex-wrap: wrap; justify-content: center; gap: 10px; margin-top: 28px; }
.pill {
  border: 1px solid var(--line); border-radius: 999px; padding: 7px 14px;
  font-weight: 700; font-size: 14px; color: var(--muted); background: var(--card);
}

/* giochi */
.games { display: grid; gap: 28px; padding-bottom: 40px; }
.game {
  display: grid; grid-template-columns: 1.05fr 1fr; gap: 0;
  border: 1px solid var(--line); border-radius: var(--radius);
  background: linear-gradient(160deg, rgba(255,255,255,.06), rgba(255,255,255,.02));
  overflow: hidden;
}
.game:nth-child(even) .game-media { order: 2; }
.game-media { position: relative; min-height: 300px; background: var(--bg2); display: flex; align-items: center; justify-content: center; gap: 14px; padding: 22px; }
.game-media img.banner { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.game-media img.shot { width: 44%; max-width: 210px; border-radius: 18px; box-shadow: 0 18px 40px rgba(0,0,0,.45); border: 1px solid var(--line); }
.game-media img.shot:nth-child(2) { transform: translateY(18px); }
.game-body { padding: 30px 30px 32px; display: flex; flex-direction: column; gap: 14px; }
.game-head { display: flex; align-items: center; gap: 16px; }
.game-icon { width: 72px; height: 72px; border-radius: 18px; flex: none; box-shadow: 0 8px 20px rgba(0,0,0,.4); }
.game h2 { margin: 0; font-size: 28px; line-height: 1.15; font-weight: 900; }
.genre { color: var(--accent); font-weight: 800; font-size: 14px; text-transform: uppercase; letter-spacing: 1px; }
.game p { margin: 0; color: var(--muted); }
.game ul { margin: 0; padding-left: 18px; color: var(--muted); }
.game li { margin: 3px 0; }
.status {
  align-self: flex-start; margin-top: auto;
  display: inline-flex; align-items: center; gap: 8px;
  background: rgba(255, 210, 77, .12); color: var(--gold);
  border: 1px solid rgba(255, 210, 77, .45);
  border-radius: 999px; padding: 8px 16px; font-weight: 800; font-size: 14px;
}
.status::before { content: ""; width: 8px; height: 8px; border-radius: 50%; background: var(--gold); box-shadow: 0 0 10px var(--gold); }

a.status { text-decoration: none; }
.status-live { background: rgba(61, 220, 151, .14); color: #3ddc97; border-color: rgba(61, 220, 151, .55); }
.status-live::before { background: #3ddc97; box-shadow: 0 0 10px #3ddc97; }
.status-live:hover { background: rgba(61, 220, 151, .26); }

/* temi dei singoli giochi */
.g-prisma .genre { color: #7df9ff; }
.g-prisma .game-media { background: radial-gradient(circle at 30% 20%, #3a1d6e, #0d3b4f); }
.g-mahjong .genre { color: #7dffd2; }
.g-fbws .genre { color: #fbbf24; }
.g-fbws .game-media { background: radial-gradient(circle at 30% 20%, #1e3a7a, #070f24); }
.g-mahjong .game-media { background: radial-gradient(circle at 30% 20%, #0f5c4a, #06201f); }
.g-roulette .genre { color: #ff6b6b; }
.g-roulette .game-media img.banner { object-position: 85% center; }
.g-galactic .game-media { background: #120b2a; }
.g-galactic .game-media img.banner { object-fit: contain; }
.g-galactic .genre { color: #9dff6b; }

/* pagine di testo (privacy) */
.doc { max-width: 760px; margin: 0 auto; padding: 56px 20px 40px; }
.doc h1 { font-size: 40px; line-height: 1.1; margin: 0 0 8px; }
.doc h2 { margin-top: 34px; font-size: 22px; }
.doc p, .doc li { color: var(--muted); }
.doc .updated { color: var(--muted); font-size: 14px; }

footer { border-top: 1px solid var(--line); margin-top: 40px; }
footer .wrap { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 12px; padding: 26px 20px 40px; color: var(--muted); font-size: 14px; }
footer a { color: var(--muted); }

@media (max-width: 820px) {
  .game { grid-template-columns: 1fr; }
  .game:nth-child(even) .game-media { order: 0; }
  .game-media { min-height: 240px; }
  .game-body { padding: 24px 20px 26px; }
  .nav a.hide-sm { display: none; }
  .hero { padding-top: 56px; padding-bottom: 40px; }
}

select.lang { appearance: none; -webkit-appearance: none; cursor: pointer; padding-right: 14px; }
select.lang option { color: #111; }
.g-pants .genre { color: #ff7ac0; }
.g-pants .game-media { background: radial-gradient(circle at 70% 30%, #ff9ac8, #5a1f4a); }
.g-fbws .game-media img.banner { object-position: left center; }

/* Word Blade */
.g-wordblade .genre { color: #ffc46b; }
.g-wordblade .game-media { background: radial-gradient(circle at 30% 30%, #5a1446, #1a0830); }

/* Lumi, la mascotte */
.brand-lumi { width: 38px; height: 38px; filter: drop-shadow(0 0 8px rgba(125, 249, 255, .55)); animation: lumi-bob 3s ease-in-out infinite; }
.lumi-hero { position: relative; display: flex; flex-direction: column; align-items: center; margin: -20px auto 6px; }
.lumi-float { width: 140px; height: 140px; animation: lumi-bob 3s ease-in-out infinite; filter: drop-shadow(0 0 22px rgba(125, 249, 255, .45)); }
.lumi-bubble {
  position: relative; background: #fff; color: #1d1240; font-weight: 800; font-size: 16px;
  border-radius: 999px; padding: 10px 20px; margin-bottom: 4px; box-shadow: 0 10px 30px rgba(0,0,0,.35);
  animation: lumi-pop .6s ease-out both .3s;
}
.lumi-bubble::after { content: ""; position: absolute; left: 50%; bottom: -9px; margin-left: -9px; border: 9px solid transparent; border-bottom: 0; border-top-color: #fff; }
@keyframes lumi-bob { 0%, 100% { transform: translateY(0); } 50% { transform: translateY(-10px); } }
@keyframes lumi-pop { from { opacity: 0; transform: scale(.6) translateY(10px); } to { opacity: 1; transform: none; } }
@media (prefers-reduced-motion: reduce) { .brand-lumi, .lumi-float, .lumi-bubble { animation: none; } }
.g-wordblade .game-media img.banner { object-fit: contain; }
.g-napoli .genre { color: #ffb347; }
.g-napoli .game-media img.banner { object-fit: contain; }
.g-napoli .game-media { background: radial-gradient(circle at 30% 30%, #8a1c12, #2a0806); }
.g-woof .genre { color: #3ddc97; }
.g-woof .game-media { background: radial-gradient(circle at 30% 30%, #0a4a59, #0a0f30); }
.g-woof .game-media img.banner { object-fit: contain; }
.g-rings .genre { color: #ffd93d; }
.g-rings .game-media { background: radial-gradient(circle at 30% 30%, #1d1a5c, #0b0b24); }
.g-rings .game-media img.banner { object-fit: contain; }
