:root {
  --bg: #070914;
  --bg-2: #11162a;
  --panel: rgba(255, 255, 255, 0.08);
  --panel-strong: rgba(255, 255, 255, 0.14);
  --text: #f7f2ff;
  --muted: #b8bfd6;
  --gold: #ffd166;
  --gold-2: #ffb703;
  --accent: #7c3cff;
  --accent-2: #00e5ff;
  --danger: #ff4d6d;
  --radius-xl: 34px;
  --radius-lg: 22px;
  --shadow-strong: 0 26px 80px rgba(0, 0, 0, 0.48);
  --wheel-size: clamp(290px, 44vw, 540px);
  color-scheme: dark;
}

* {
  box-sizing: border-box;
}

html {
  min-height: 100%;
  background: var(--bg);
}

body {
  min-height: 100vh;
  margin: 0;
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", "PingFang SC", "Microsoft YaHei", sans-serif;
  color: var(--text);
  background:
    radial-gradient(circle at 20% 10%, rgba(124, 60, 255, 0.42), transparent 34%),
    radial-gradient(circle at 80% 20%, rgba(0, 229, 255, 0.26), transparent 30%),
    radial-gradient(circle at 50% 90%, rgba(255, 183, 3, 0.18), transparent 34%),
    linear-gradient(135deg, #050611 0%, #10142a 48%, #070914 100%);
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
  text-rendering: geometricPrecision;
}


button {
  font: inherit;
  touch-action: manipulation;
}

.page-shell {
  width: min(1180px, calc(100% - 32px));
  margin: 0 auto;
  padding: clamp(22px, 5vw, 54px) 0;
}

.hero-card {
  position: relative;
  display: grid;
  grid-template-columns: minmax(0, 0.92fr) minmax(320px, 1.08fr);
  align-items: center;
  gap: clamp(20px, 4vw, 54px);
  min-height: min(720px, calc(100vh - 90px));
  padding: clamp(22px, 4vw, 56px);
  border: 1px solid rgba(255, 255, 255, 0.16);
  border-radius: var(--radius-xl);
  background:
    linear-gradient(145deg, rgba(255, 255, 255, 0.11), rgba(255, 255, 255, 0.035)),
    rgba(8, 11, 25, 0.74);
  box-shadow: var(--shadow-strong);
  isolation: isolate;
  overflow: hidden;
  contain: layout paint style;
}

.hero-card::before,
.hero-card::after {
  content: "";
  position: absolute;
  z-index: -1;
  border-radius: 999px;
  filter: blur(6px);
  opacity: 0.72;
}

.hero-card::before {
  width: 320px;
  height: 320px;
  left: -120px;
  top: -130px;
  background: radial-gradient(circle, rgba(124, 60, 255, 0.55), transparent 68%);
}

.hero-card::after {
  width: 360px;
  height: 360px;
  right: -130px;
  bottom: -140px;
  background: radial-gradient(circle, rgba(0, 229, 255, 0.32), transparent 70%);
}

.hero-copy {
  max-width: 560px;
}

.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 18px;
  padding: 8px 12px;
  border: 1px solid rgba(255, 209, 102, 0.35);
  border-radius: 999px;
  background: rgba(255, 209, 102, 0.1);
  color: var(--gold);
  font-size: 12px;
  font-weight: 800;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

h1 {
  margin: 0;
  font-size: clamp(38px, 6vw, 78px);
  line-height: 0.94;
  letter-spacing: -0.06em;
}

.subtitle {
  width: min(100%, 540px);
  margin: 22px 0 0;
  color: var(--muted);
  font-size: clamp(15px, 1.55vw, 18px);
  line-height: 1.7;
}

.action-row {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 14px;
  margin-top: 24px;
}

.primary-btn,
.claim-btn {
  border: 0;
  cursor: pointer;
  color: #1d1400;
  font-weight: 900;
  letter-spacing: -0.02em;
  background: linear-gradient(135deg, #fff2a8, var(--gold), var(--gold-2));
  box-shadow: 0 16px 34px rgba(255, 183, 3, 0.22);
  transition: transform 180ms ease, box-shadow 180ms ease, filter 180ms ease;
  transform: translateZ(0);
}

.primary-btn {
  min-width: 148px;
  padding: 14px 22px;
  border-radius: 999px;
}

.primary-btn:hover,
.claim-btn:hover {
  transform: translateY(-2px);
  filter: saturate(1.1);
  box-shadow: 0 20px 40px rgba(255, 183, 3, 0.28);
}

.primary-btn:disabled {
  cursor: not-allowed;
  opacity: 0.58;
  transform: none;
  filter: grayscale(0.2);
}

.safe-note {
  max-width: 300px;
  color: rgba(247, 242, 255, 0.68);
  font-size: 13px;
  line-height: 1.5;
}

.wheel-stage {
  position: relative;
  display: grid;
  place-items: center;
  min-height: calc(var(--wheel-size) + 80px);
}

.ambient-ring {
  position: absolute;
  width: calc(var(--wheel-size) + 58px);
  height: calc(var(--wheel-size) + 58px);
  border-radius: 50%;
  pointer-events: none;
}

.ring-one {
  border: 1px solid rgba(255, 255, 255, 0.15);
  box-shadow: inset 0 0 40px rgba(124, 60, 255, 0.16), 0 0 70px rgba(124, 60, 255, 0.18);
}

.ring-two {
  width: calc(var(--wheel-size) + 16px);
  height: calc(var(--wheel-size) + 16px);
  border: 1px dashed rgba(255, 209, 102, 0.28);
  animation: orbit 22s linear infinite;
  will-change: transform;
  backface-visibility: hidden;
}

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

.pointer {
  position: absolute;
  top: calc(50% - (var(--wheel-size) / 2) - 18px);
  z-index: 4;
  width: 0;
  height: 0;
  border-left: 22px solid transparent;
  border-right: 22px solid transparent;
  border-top: 42px solid var(--gold);
  filter: drop-shadow(0 10px 14px rgba(0, 0, 0, 0.38));
}

.wheel-wrap {
  position: relative;
  cursor: pointer;
  touch-action: manipulation;
  transform: translate3d(0, 0, 0);
  will-change: transform;
  display: grid;
  place-items: center;
  width: var(--wheel-size);
  height: var(--wheel-size);
  border-radius: 50%;
  padding: clamp(8px, 1.2vw, 14px);
  background:
    linear-gradient(135deg, rgba(255, 255, 255, 0.96), rgba(255, 209, 102, 0.75) 24%, rgba(124, 60, 255, 0.62) 55%, rgba(0, 229, 255, 0.82));
  box-shadow:
    0 0 0 1px rgba(255, 255, 255, 0.2),
    0 34px 80px rgba(0, 0, 0, 0.52),
    0 0 90px rgba(124, 60, 255, 0.18);
}

.wheel-wrap:focus-visible {
  outline: 3px solid rgba(255, 209, 102, 0.85);
  outline-offset: 6px;
}

.wheel {
  position: relative;
  width: 100%;
  height: 100%;
  border-radius: 50%;
  background: conic-gradient(from 90deg, #4f46e5 0deg 45deg, #00c2ff 45deg 90deg, #ffbe0b 90deg 135deg, #ff006e 135deg 180deg, #8338ec 180deg 225deg, #06d6a0 225deg 270deg, #fb5607 270deg 315deg, #3a86ff 315deg 360deg);
  overflow: hidden;
  transform: translate3d(0, 0, 0) rotate(0deg);
  transition: none;
  will-change: transform;
  backface-visibility: hidden;
  -webkit-backface-visibility: hidden;
  transform-style: preserve-3d;
  contain: layout paint style;
}

.wheel.is-spinning {
  pointer-events: none;
}

.wheel-wrap.is-spinning {
  pointer-events: none;
  cursor: wait;
}

.wheel::before {
  content: "";
  position: absolute;
  inset: 0;
  border-radius: inherit;
  background:
    repeating-conic-gradient(from 90deg, rgba(255, 255, 255, 0.42) 0deg 1deg, transparent 1deg 45deg),
    radial-gradient(circle, transparent 0 55%, rgba(0, 0, 0, 0.16) 56% 100%);
  pointer-events: none;
}

.wheel::after {
  content: "";
  position: absolute;
  inset: clamp(7px, 1.1vw, 12px);
  border: 2px solid rgba(255, 255, 255, 0.18);
  border-radius: 50%;
  pointer-events: none;
}

.wheel-gloss {
  position: absolute;
  z-index: 2;
  inset: 0;
  border-radius: 50%;
  background:
    radial-gradient(circle at 35% 25%, rgba(255, 255, 255, 0.42), transparent 28%),
    linear-gradient(140deg, rgba(255, 255, 255, 0.2), transparent 40%, rgba(0, 0, 0, 0.18) 76%);
  opacity: 0.82;
  pointer-events: none;
}

.wheel-labels {
  position: absolute;
  z-index: 3;
  inset: 0;
  border-radius: 50%;
}

.wheel-label {
  position: absolute;
  left: 50%;
  top: 50%;
  width: 42%;
  transform-origin: 0 0;
  color: #fff;
  font-size: clamp(10px, 1.35vw, 15px);
  font-weight: 900;
  line-height: 1.12;
  text-align: center;
  text-shadow: 0 2px 8px rgba(0, 0, 0, 0.42);
  user-select: none;
  backface-visibility: hidden;
  -webkit-backface-visibility: hidden;
}

.wheel-label span {
  display: inline-block;
  max-width: 100%;
  padding: 4px 8px;
  border-radius: 999px;
  background: rgba(0, 0, 0, 0.24);
}


.special-red-label {
  width: 50%;
}

.special-red-label span {
  padding: 6px 10px;
  font-size: clamp(12px, 1.75vw, 20px);
  font-weight: 1000;
  line-height: 1.04;
  letter-spacing: -0.03em;
  background: rgba(0, 0, 0, 0.28);
}

.slice-glow {
  position: absolute;
  inset: 0;
  z-index: 1;
  border-radius: 50%;
  pointer-events: none;
}

.red-slice-glow {
  background: conic-gradient(
    from 90deg,
    transparent 0deg 135deg,
    rgba(0, 255, 136, 0.98) 135deg 180deg,
    transparent 180deg 360deg
  );
  -webkit-mask: radial-gradient(farthest-side, transparent calc(100% - 12px), #000 calc(100% - 10px), #000 100%);
  mask: radial-gradient(farthest-side, transparent calc(100% - 12px), #000 calc(100% - 10px), #000 100%);
  opacity: 0.5;
  animation: greenPulse 3.2s ease-in-out infinite;
}

.wheel.is-spinning .red-slice-glow {
  opacity: 0.25;
  animation-play-state: paused;
}

@keyframes greenPulse {
  0%, 100% {
    opacity: 0.35;
    box-shadow: 0 0 10px rgba(0, 255, 136, 0.28);
  }
  50% {
    opacity: 0.95;
    box-shadow: 0 0 22px rgba(0, 255, 136, 0.62);
  }
}

.hub {
  position: absolute;
  inset: 50%;
  z-index: 4;
  display: grid;
  place-items: center;
  width: clamp(96px, 13vw, 160px);
  height: clamp(96px, 13vw, 160px);
  padding: clamp(10px, 1.4vw, 16px);
  transform: translate(-50%, -50%);
  border-radius: 50%;
  border: 2px solid rgba(255, 255, 255, 0.22);
  background: radial-gradient(circle at 35% 25%, rgba(255, 255, 255, 0.08), transparent 28%), #000;
  box-shadow: 0 12px 28px rgba(0, 0, 0, 0.48), inset 0 0 20px rgba(255, 255, 255, 0.05);
  pointer-events: none;
}

.hub-logo {
  width: 84%;
  height: auto;
  object-fit: contain;
  transform: translateZ(0);
  user-select: none;
  pointer-events: none;
}

.wheel-shadow {
  position: absolute;
  bottom: 10px;
  width: calc(var(--wheel-size) * 0.68);
  height: 34px;
  border-radius: 50%;
  background: rgba(0, 0, 0, 0.5);
  filter: blur(14px);
  transform: translateY(50%);
  z-index: -1;
}

.modal {
  position: fixed;
  inset: 0;
  z-index: 20;
  display: none;
  place-items: center;
  padding: 20px;
}

.modal.is-open {
  display: grid;
}

.modal-backdrop {
  position: absolute;
  inset: 0;
  background: rgba(1, 3, 12, 0.72);
  backdrop-filter: blur(12px);
}

.modal-card {
  position: relative;
  width: min(440px, 100%);
  padding: 34px 24px 26px;
  border: 1px solid rgba(255, 255, 255, 0.22);
  border-radius: 30px;
  background:
    radial-gradient(circle at 50% 0%, rgba(255, 209, 102, 0.28), transparent 36%),
    linear-gradient(145deg, rgba(26, 31, 62, 0.98), rgba(8, 10, 24, 0.98));
  box-shadow: 0 30px 90px rgba(0, 0, 0, 0.58);
  text-align: center;
  transform: translateY(16px) scale(0.96);
  opacity: 0;
  animation: modalIn 320ms ease forwards;
}

@keyframes modalIn {
  to {
    transform: translateY(0) scale(1);
    opacity: 1;
  }
}

.modal-close {
  position: absolute;
  top: 14px;
  right: 14px;
  display: grid;
  place-items: center;
  width: 36px;
  height: 36px;
  border: 0;
  border-radius: 50%;
  color: #fff;
  background: rgba(255, 255, 255, 0.1);
  cursor: pointer;
  font-size: 24px;
}

.reward-badge {
  display: inline-grid;
  place-items: center;
  width: 72px;
  height: 72px;
  margin-bottom: 18px;
  border-radius: 24px;
  color: #1d1400;
  background: linear-gradient(135deg, #fff2a8, var(--gold), var(--gold-2));
  box-shadow: 0 18px 44px rgba(255, 183, 3, 0.28);
  font-weight: 1000;
  letter-spacing: -0.06em;
}

.modal-card h2 {
  margin: 0;
  font-size: clamp(28px, 7vw, 42px);
  letter-spacing: -0.06em;
}

.modal-text {
  margin: 14px 0 8px;
  color: var(--muted);
}

.reward-value {
  margin: 0 auto;
  padding: 16px;
  border-radius: 20px;
  color: var(--gold);
  background: rgba(255, 209, 102, 0.1);
  border: 1px solid rgba(255, 209, 102, 0.22);
  font-size: clamp(24px, 7vw, 36px);
  font-weight: 1000;
  line-height: 1.08;
  letter-spacing: -0.04em;
}

.modal-disclaimer {
  margin: 16px auto 20px;
  max-width: 340px;
  color: rgba(247, 242, 255, 0.66);
  font-size: 12px;
  line-height: 1.55;
}

.claim-btn {
  width: 100%;
  padding: 15px 18px;
  border-radius: 18px;
}

@media (max-width: 920px) {
  .hero-card {
    grid-template-columns: 1fr;
    min-height: auto;
  }

  .hero-copy {
    max-width: none;
    text-align: center;
  }

  .subtitle {
    margin-left: auto;
    margin-right: auto;
  }

  .action-row {
    justify-content: center;
  }

  .wheel-stage {
    order: -1;
    min-height: calc(var(--wheel-size) + 52px);
  }

}

@media (max-width: 560px) {
  .special-red-label span {
    font-size: clamp(11px, 3.2vw, 15px);
    padding: 5px 8px;
  }

  :root {
    --wheel-size: min(82vw, 360px);
  }

  .page-shell {
    width: min(100% - 20px, 1180px);
    padding: 10px 0 16px;
  }

  .hero-card::before,
  .hero-card::after {
    filter: blur(3px);
  }

  .hero-card {
    padding: 18px;
    border-radius: 26px;
    gap: 16px;
  }

  .eyebrow {
    margin-bottom: 12px;
    font-size: 10px;
  }

  .subtitle {
    margin-top: 14px;
  }

  .primary-btn {
    width: 100%;
  }

  .safe-note {
    max-width: none;
  }

  .pointer {
    top: calc(50% - (var(--wheel-size) / 2) - 12px);
    border-left-width: 16px;
    border-right-width: 16px;
    border-top-width: 32px;
  }
}

@media (max-height: 560px) and (orientation: landscape) {
  :root {
    --wheel-size: min(52vh, 330px);
  }

  .page-shell {
    padding: 10px 0;
  }

  .hero-card {
    grid-template-columns: 0.96fr 1.04fr;
    min-height: calc(100vh - 20px);
    padding: 18px 22px;
  }

  h1 {
    font-size: clamp(30px, 5vw, 52px);
  }

  .subtitle {
    display: none;
  }

}

@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto !important;
  }

  .ambient-ring,
  .red-slice-glow,
  .modal-card {
    animation-duration: 1ms !important;
    animation-iteration-count: 1 !important;
  }
}


.modal-logo {
  display: block;
  width: min(230px, 72%);
  height: auto;
  margin: 0 auto 14px;
  object-fit: contain;
  filter: drop-shadow(0 8px 18px rgba(0, 0, 0, 0.32));
}
