:root {
  --bg: #07060d;
  --bg-2: #0e0b18;
  --card: rgba(18, 14, 32, 0.72);
  --card-solid: #141022;
  --purple: #9146ff;
  --purple-2: #bf7aff;
  --pink: #ff4d9a;
  --cyan: #4de2ff;
  --text: #f4f0ff;
  --muted: #a79bc4;
  --line: rgba(145, 70, 255, 0.28);
  --glow: 0 0 40px rgba(145, 70, 255, 0.35);
  --radius: 22px;
}

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

html { scroll-behavior: smooth; }

body {
  font-family: "Manrope", system-ui, sans-serif;
  background: var(--bg);
  color: var(--text);
  min-height: 100vh;
  overflow-x: hidden;
}

body::before {
  content: "";
  position: fixed;
  inset: 0;
  pointer-events: none;
  background:
    radial-gradient(900px 500px at 10% -10%, rgba(145, 70, 255, 0.28), transparent 55%),
    radial-gradient(700px 420px at 90% 10%, rgba(255, 77, 154, 0.16), transparent 50%),
    radial-gradient(600px 400px at 50% 100%, rgba(77, 226, 255, 0.08), transparent 50%);
  z-index: -2;
}

.noise {
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: -1;
  opacity: 0.04;
  background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 200 200' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='.8' numOctaves='4'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
}

.wrap {
  width: min(1180px, calc(100% - 32px));
  margin: 0 auto;
}

h1, h2, h3, .logo-text, .display {
  font-family: "Unbounded", sans-serif;
}

/* NAV */
.nav {
  position: sticky;
  top: 0;
  z-index: 50;
  backdrop-filter: blur(18px);
  background: rgba(7, 6, 13, 0.62);
  border-bottom: 1px solid var(--line);
}

.nav-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 74px;
  gap: 16px;
}

.brand {
  display: flex;
  align-items: center;
  gap: 12px;
  text-decoration: none;
  color: var(--text);
}

.brand img {
  width: 44px;
  height: 44px;
  border-radius: 14px;
  object-fit: cover;
  box-shadow: var(--glow);
}

.logo-text { font-size: 18px; letter-spacing: 0.4px; }
.logo-text span { color: var(--purple-2); }

.nav-links {
  display: flex;
  gap: 6px;
  list-style: none;
}

.nav-links a {
  color: var(--muted);
  text-decoration: none;
  font-weight: 600;
  padding: 8px 14px;
  border-radius: 999px;
  transition: 0.2s;
}

.nav-links a:hover,
.nav-links a.active {
  color: white;
  background: rgba(145, 70, 255, 0.18);
}

.live-pill {
  display: flex;
  align-items: center;
  gap: 8px;
  background: rgba(255, 77, 154, 0.12);
  border: 1px solid rgba(255, 77, 154, 0.35);
  color: #ffd0e6;
  padding: 8px 14px;
  border-radius: 999px;
  font-weight: 700;
  font-size: 13px;
  text-decoration: none;
}

.dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: #ff3b6b;
  box-shadow: 0 0 10px #ff3b6b;
  animation: pulse 1.4s infinite;
}

@keyframes pulse {
  0%, 100% { transform: scale(1); opacity: 1; }
  50% { transform: scale(1.35); opacity: 0.6; }
}

.burger {
  display: none;
  background: none;
  border: 1px solid var(--line);
  color: white;
  width: 42px;
  height: 42px;
  border-radius: 12px;
  cursor: pointer;
}

/* HERO */
.hero {
  padding: 48px 0 28px;
  display: grid;
  grid-template-columns: 1.15fr 0.85fr;
  gap: 36px;
  align-items: center;
}

.kicker {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  color: var(--purple-2);
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  font-size: 12px;
  margin-bottom: 14px;
}

.display {
  font-size: clamp(36px, 5vw, 64px);
  line-height: 1.05;
  margin-bottom: 16px;
}

.display em {
  font-style: normal;
  background: linear-gradient(90deg, #bf7aff, #ff4d9a 60%, #4de2ff);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

.lead {
  color: var(--muted);
  font-size: 18px;
  line-height: 1.6;
  max-width: 540px;
  margin-bottom: 26px;
}

.cta-row { display: flex; gap: 12px; flex-wrap: wrap; }

.btn {
  border: 0;
  cursor: pointer;
  text-decoration: none;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 13px 20px;
  border-radius: 14px;
  font-weight: 700;
  font-family: inherit;
  transition: 0.2s transform, 0.2s box-shadow, 0.2s background;
}

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

.btn-primary {
  background: linear-gradient(135deg, #9146ff, #c44dff);
  color: white;
  box-shadow: var(--glow);
}

.btn-ghost {
  background: transparent;
  color: white;
  border: 1px solid var(--line);
}

.stats {
  display: flex;
  gap: 22px;
  margin-top: 28px;
}

.stat b {
  display: block;
  font-family: "Unbounded", sans-serif;
  font-size: 22px;
}

.stat span { color: var(--muted); font-size: 13px; }

.hero-card {
  position: relative;
  border-radius: 28px;
  overflow: hidden;
  border: 1px solid var(--line);
  box-shadow: var(--glow);
  min-height: 420px;
}

.hero-card img.cover {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  min-height: 420px;
}

.hero-overlay {
  position: absolute;
  inset: auto 0 0 0;
  padding: 22px;
  background: linear-gradient(transparent, rgba(7,6,13,0.92));
}

.avatar-row {
  display: flex;
  align-items: center;
  gap: 12px;
}

.avatar-row img {
  width: 56px;
  height: 56px;
  border-radius: 18px;
  object-fit: cover;
  border: 2px solid #c9a6ff;
}

/* SECTIONS */
section { padding: 56px 0; }

.sec-head {
  display: flex;
  justify-content: space-between;
  align-items: end;
  gap: 16px;
  margin-bottom: 24px;
}

.sec-head h2 { font-size: clamp(24px, 3vw, 36px); }
.sec-head p { color: var(--muted); }

.grid-2 { display: grid; grid-template-columns: 1.2fr 0.8fr; gap: 20px; }
.grid-3 { display: grid; grid-template-columns: repeat(3, 1fr); gap: 18px; }

.card {
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 22px;
  backdrop-filter: blur(16px);
  transition: transform .22s ease, border-color .22s ease, box-shadow .22s ease, background .22s ease;
}
.card:hover {
  transform: translateY(-6px);
  border-color: rgba(168, 85, 247, .7);
  box-shadow: 0 18px 40px rgba(145, 70, 255, .28), 0 0 0 1px rgba(168, 85, 247, .2);
  background: linear-gradient(180deg, rgba(145,70,255,.14), rgba(12,8,20,.92));
}

.card h3 { margin-bottom: 8px; font-size: 20px; color: #fff; }

/* POLLS */
.poll-option {
  width: 100%;
  text-align: left;
  margin: 8px 0;
  padding: 12px 14px;
  border-radius: 14px;
  border: 1px solid var(--line);
  background: rgba(255,255,255,0.03);
  color: white;
  cursor: pointer;
  position: relative;
  overflow: hidden;
  font-family: inherit;
  font-weight: 600;
}

.poll-option .bar {
  position: absolute;
  inset: 0 auto 0 0;
  width: 0;
  background: linear-gradient(90deg, rgba(145,70,255,0.35), rgba(255,77,154,0.22));
  transition: width 0.6s ease;
}

.poll-option .row {
  position: relative;
  z-index: 1;
  display: flex;
  justify-content: space-between;
}

.poll-option.selected { border-color: var(--purple-2); box-shadow: 0 0 0 1px var(--purple); }
.poll-option:disabled { cursor: default; }

.poll-meta {
  display: flex;
  justify-content: space-between;
  color: var(--muted);
  font-size: 13px;
  margin-top: 10px;
}

/* CONTESTS */
.contest {
  display: flex;
  flex-direction: column;
  min-height: 280px;
}

.badge {
  align-self: flex-start;
  font-size: 12px;
  font-weight: 800;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  padding: 5px 10px;
  border-radius: 999px;
  margin-bottom: 12px;
}

.badge-hot { background: rgba(255,77,154,0.16); color: #ff9cc8; }
.badge-game { background: rgba(77,226,255,0.12); color: #8aefff; }
.badge-art { background: rgba(145,70,255,0.16); color: #d0b3ff; }

.contest p { color: var(--muted); flex: 1; line-height: 1.55; margin: 8px 0 16px; }

/* WHEEL */
.wheel-box {
  display: grid;
  grid-template-columns: 280px 1fr;
  gap: 24px;
  align-items: center;
}

.wheel-wrap {
  width: 280px;
  height: 280px;
  position: relative;
}

.wheel {
  width: 280px;
  height: 280px;
  border-radius: 50%;
  border: 8px solid #2a2044;
  position: relative;
  overflow: hidden;
  transition: transform 4.5s cubic-bezier(0.12, 0.7, 0.15, 1);
  background: conic-gradient(
    #9146ff 0 45deg,
    #5b2bb3 45deg 90deg,
    #ff4d9a 90deg 135deg,
    #9146ff 135deg 180deg,
    #4de2ff 180deg 225deg,
    #9146ff 225deg 270deg,
    #ffb347 270deg 315deg,
    #5b2bb3 315deg 360deg
  );
  box-shadow: var(--glow);
}

.wheel span {
  position: absolute;
  width: 50%;
  left: 50%;
  top: 50%;
  transform-origin: 0 0;
  font-size: 12px;
  font-weight: 800;
  color: white;
  text-shadow: 0 1px 4px #000;
}

.pointer {
  position: absolute;
  top: -8px;
  left: 50%;
  transform: translateX(-50%);
  width: 0;
  height: 0;
  border-left: 12px solid transparent;
  border-right: 12px solid transparent;
  border-top: 22px solid #fff;
  z-index: 2;
  filter: drop-shadow(0 4px 8px rgba(0,0,0,.5));
}

/* GUESS GAME */
.guess-row { display: flex; gap: 10px; margin-top: 12px; }
.guess-row input, .form input, .form textarea, select {
  flex: 1;
  background: #0c0916;
  border: 1px solid var(--line);
  color: white;
  border-radius: 12px;
  padding: 12px 14px;
  font-family: inherit;
  font-size: 15px;
}
.form { display: grid; gap: 10px; }
.form textarea { min-height: 90px; resize: vertical; }

/* CHAT FAKE */
.chat {
  max-height: 360px;
  overflow: auto;
  display: flex;
  flex-direction: column;
  gap: 10px;
}
.msg {
  background: rgba(255,255,255,0.03);
  border-radius: 14px;
  padding: 10px 12px;
  font-size: 14px;
}
.msg b { color: var(--purple-2); }
.msg.mod b { color: #4de2ff; }

/* FOOTER */
footer {
  border-top: 1px solid var(--line);
  padding: 28px 0 40px;
  color: var(--muted);
}
.foot {
  display: flex;
  justify-content: space-between;
  gap: 16px;
  flex-wrap: wrap;
  align-items: center;
}

.toast {
  position: fixed;
  bottom: 22px;
  right: 22px;
  background: #1a1430;
  border: 1px solid var(--purple);
  color: white;
  padding: 14px 18px;
  border-radius: 14px;
  box-shadow: var(--glow);
  transform: translateY(120%);
  opacity: 0;
  transition: 0.35s;
  z-index: 80;
}
.toast.show { transform: translateY(0); opacity: 1; }

@media (max-width: 900px) {
  .hero, .grid-2, .wheel-box, .grid-3 { grid-template-columns: 1fr; }
  .nav-links { display: none; }
  .nav-links.open {
    display: flex;
    flex-direction: column;
    position: absolute;
    top: 74px;
    left: 0; right: 0;
    background: #0c0916;
    padding: 12px;
    border-bottom: 1px solid var(--line);
  }
  .burger { display: grid; place-items: center; }
  .hero-card, .hero-card img.cover { min-height: 280px; }
}
