/* ============================================================
   DMD Rewards — design tokens
   A raffle-ticket / high-stakes-VIP system: warm burgundy-black
   base, aged gold foil, ticket-stub red, parchment text.
   ============================================================ */
:root {
  --ink: #1a1014;
  --surface: #241820;
  --surface-raised: #2e1e28;
  --gold: #d4a548;
  --gold-bright: #e8c775;
  --ticket-red: #8c2f39;
  --ticket-red-bright: #a83c47;
  --paper: #f2e9dc;
  --paper-dim: #c9bfae;
  --mauve: #8a7280;
  --line: rgba(212, 165, 72, 0.22);

  --font-display: "Fraunces", "Georgia", serif;
  --font-body: "Inter", -apple-system, BlinkMacSystemFont, sans-serif;
  --font-mono: "IBM Plex Mono", monospace;
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  margin: 0;
  background: var(--ink);
  background-image:
    radial-gradient(ellipse 900px 500px at 15% 0%, rgba(212, 165, 72, 0.08), transparent 60%),
    radial-gradient(ellipse 900px 500px at 85% 30%, rgba(140, 47, 57, 0.09), transparent 60%);
  background-attachment: fixed;
  color: var(--paper);
  font-family: var(--font-body);
  line-height: 1.55;
  -webkit-font-smoothing: antialiased;
}

a { color: inherit; }

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

h1, h2, h3 {
  font-family: var(--font-display);
  font-weight: 600;
  line-height: 1.08;
  margin: 0 0 0.4em;
  color: var(--paper);
  font-variant-ligatures: none;
  font-feature-settings: "liga" 0, "clig" 0;
}

p { margin: 0 0 1em; color: var(--paper-dim); max-width: 62ch; }

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

/* ---------- perforated ticket divider ----------
   A recurring structural device tying every section back to the
   raffle-ticket idea — used only between real section breaks. */
.perf {
  position: relative;
  height: 1px;
  background: repeating-linear-gradient(
    to right,
    var(--line) 0 10px,
    transparent 10px 20px
  );
  margin: 0;
}
.perf::before,
.perf::after {
  content: "";
  position: absolute;
  top: -9px;
  width: 18px;
  height: 18px;
  border-radius: 50%;
  background: var(--ink);
  border: 1px solid var(--line);
}
.perf::before { left: -9px; }
.perf::after { right: -9px; }

/* ---------- nav ---------- */
.nav {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 22px 0;
}
.nav__brand {
  font-family: var(--font-display);
  font-size: 1.3rem;
  font-weight: 700;
  letter-spacing: 0.01em;
  text-decoration: none;
  color: var(--paper);
  display: flex;
  align-items: center;
  gap: 8px;
}
.nav__brand .stub {
  color: var(--gold);
}
.stub { color: var(--gold); }

.dabloon-icon {
  width: 1em;
  height: 1em;
  vertical-align: -0.15em;
  flex-shrink: 0;
}

/* ---------- page header banner (full-bleed title bar) ---------- */
.page-header {
  margin: 0 -24px 40px;
  padding: 48px 24px 40px;
  background: linear-gradient(180deg, rgba(212, 165, 72, 0.09), transparent);
  border-top: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
}
.page-header h1 { margin-bottom: 12px; }
.page-header .hero__eyebrow { margin-bottom: 14px; }
.page-header--center {
  text-align: center;
}
.page-header--center .hero__eyebrow { justify-content: center; }
.page-header--center .mini-steps { margin-left: auto; margin-right: auto; }
.page-header--center .mini-step { justify-content: center; }

/* ---------- compact numbered steps (used on raffles page) ---------- */
.mini-steps {
  display: flex;
  flex-direction: column;
  gap: 14px;
  margin-top: 24px;
  max-width: 520px;
}
.mini-step {
  display: flex;
  align-items: baseline;
  gap: 14px;
}
.mini-step__num {
  font-family: var(--font-mono);
  color: var(--gold);
  font-size: 0.82rem;
  flex-shrink: 0;
  width: 24px;
}
.mini-step__text { color: var(--paper-dim); }
.nav__links {
  display: flex;
  align-items: center;
  gap: 28px;
  list-style: none;
  margin: 0;
  padding: 0;
}
.nav__links a {
  text-decoration: none;
  color: var(--paper-dim);
  font-size: 0.95rem;
  transition: color 0.15s ease;
}
.nav__links a:hover { color: var(--gold-bright); }

.nav--sticky {
  position: sticky;
  top: 0;
  z-index: 20;
  background: rgba(26, 16, 20, 0.92);
  backdrop-filter: blur(8px);
  margin: 0 -24px;
  padding-left: 24px;
  padding-right: 24px;
  border-bottom: 1px solid transparent;
}
.nav__balance {
  display: flex;
  align-items: center;
  gap: 8px;
  text-decoration: none;
  border: 1px solid var(--line);
  border-radius: 999px;
  padding: 5px 16px 5px 5px;
  color: var(--paper);
  transition: border-color 0.15s ease;
}
.nav__balance:hover { border-color: var(--gold); }
.nav__avatar {
  width: 22px;
  height: 22px;
  border-radius: 50%;
  object-fit: cover;
  flex-shrink: 0;
}
.nav__balance span:first-of-type {
  font-family: var(--font-mono);
  font-weight: 600;
  color: var(--gold-bright);
  font-size: 0.9rem;
}
.nav__balance-label {
  font-family: var(--font-mono);
  font-size: 0.7rem;
  color: var(--mauve);
  letter-spacing: 0.04em;
}

/* ---------- buttons ---------- */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 14px 26px;
  border-radius: 999px;
  font-family: var(--font-body);
  font-weight: 600;
  font-size: 0.95rem;
  text-decoration: none;
  border: 1px solid transparent;
  cursor: pointer;
  transition: transform 0.12s ease, box-shadow 0.12s ease;
}
.btn:active { transform: translateY(1px); }

.btn--gold {
  background: linear-gradient(180deg, var(--gold-bright), var(--gold));
  color: var(--ink);
  box-shadow: 0 6px 20px rgba(212, 165, 72, 0.25);
}
.btn--gold:hover { box-shadow: 0 8px 26px rgba(212, 165, 72, 0.35); }

.btn--outline {
  background: transparent;
  border-color: var(--line);
  color: var(--paper);
}
.btn--outline:hover { border-color: var(--gold); color: var(--gold-bright); }

.btn--red {
  background: linear-gradient(180deg, var(--ticket-red-bright), var(--ticket-red));
  color: var(--paper);
}
.btn--red:hover { box-shadow: 0 8px 22px rgba(140, 47, 57, 0.4); }

.btn:disabled {
  opacity: 0.45;
  cursor: not-allowed;
  box-shadow: none;
}

/* ---------- hero ---------- */
.hero {
  padding: 88px 0 96px;
  position: relative;
}
.hero__eyebrow {
  font-family: var(--font-mono);
  font-size: 0.8rem;
  color: var(--gold);
  letter-spacing: 0.06em;
  margin-bottom: 18px;
}
.hero h1 {
  font-size: clamp(2.6rem, 5.4vw, 4.4rem);
  max-width: 15ch;
}
.hero__lede {
  font-size: 1.15rem;
  max-width: 46ch;
  margin-top: 18px;
}
.hero__actions {
  display: flex;
  gap: 16px;
  margin-top: 34px;
  flex-wrap: wrap;
}

/* ---------- stream embed hero ---------- */
.hero--stream { padding-top: 40px; padding-bottom: 56px; }
.stream-embed {
  position: relative;
  width: 100%;
  aspect-ratio: 16 / 9;
  border-radius: 14px;
  overflow: hidden;
  border: 1px solid var(--line);
  background: var(--surface);
}
.stream-embed iframe {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  border: 0;
}

/* ---------- CTA cards (VIP transfer / create account) ---------- */
.cta-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 20px;
  padding: 48px 0;
}
.cta-box {
  display: block;
  text-decoration: none;
  border-radius: 14px;
  padding: 28px 30px;
  border: 1px solid var(--line);
  transition: transform 0.12s ease;
}
.cta-box:hover { transform: translateY(-2px); }
.cta-box__label {
  font-family: var(--font-mono);
  font-size: 0.75rem;
  letter-spacing: 0.06em;
  margin-bottom: 10px;
}
.cta-box__title {
  font-family: var(--font-display);
  font-size: 1.7rem;
  color: var(--paper);
  margin-bottom: 6px;
  font-variant-ligatures: none;
  font-feature-settings: "liga" 0, "clig" 0;
}
.cta-box--gold {
  background: linear-gradient(160deg, rgba(212, 165, 72, 0.16), var(--surface));
}
.cta-box--gold .cta-box__label { color: var(--gold); }
.cta-box--red {
  background: linear-gradient(160deg, rgba(140, 47, 57, 0.22), var(--surface));
}
.cta-box--red .cta-box__label { color: var(--ticket-red-bright); }
.cta-box p { margin: 0; font-size: 0.9rem; }

/* ---------- CTA buttons (kept as a utility, unused on the landing page
   right now — the boxed cta-grid above is what's live) ---------- */
.cta-actions {
  display: flex;
  gap: 16px;
  flex-wrap: wrap;
  margin-top: 24px;
}

/* ---------- social row ---------- */
.social-section {
  padding: 8px 0 56px;
  text-align: center;
}
.social-section .hero__eyebrow { justify-content: center; }
.social-row {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 20px;
  margin-top: 20px;
}
.social-pill {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 10px 18px;
  border-radius: 999px;
  border: 1px solid var(--line);
  text-decoration: none;
  color: var(--paper);
  font-size: 0.9rem;
  font-weight: 600;
  transition: border-color 0.15s ease, color 0.15s ease;
}
.social-pill:hover { border-color: var(--gold); color: var(--gold-bright); }
.social-pill--kick:hover { border-color: #53fc18; color: #53fc18; }
.social-pill--youtube:hover { border-color: #ff0000; color: #ff5c5c; }
.social-pill--instagram:hover { border-color: #e1306c; color: #f377a4; }
.social-pill--discord:hover { border-color: #5865f2; color: #8992ff; }

/* ---------- how it works ---------- */
.steps {
  padding: 88px 0;
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 40px;
}
.step__num {
  font-family: var(--font-mono);
  color: var(--gold);
  font-size: 0.85rem;
  margin-bottom: 10px;
}
.step h3 { font-size: 1.3rem; }

/* ---------- ticket card (raffle) ---------- */
.ticket {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: 14px;
  padding: 26px;
  position: relative;
  overflow: hidden;
}
.ticket::before {
  content: "";
  position: absolute;
  top: 0; bottom: 0; left: 78%;
  width: 0;
  border-left: 1px dashed var(--line);
}
.ticket__prize {
  font-family: var(--font-display);
  font-size: 1.5rem;
  margin-bottom: 4px;
}
.ticket__cost {
  font-family: var(--font-mono);
  color: var(--gold);
  font-size: 0.9rem;
}
.ticket-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 22px;
  padding: 40px 0 80px;
}
.ticket-grid--center {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
}
.ticket-grid--center .ticket { width: 320px; max-width: 100%; }

/* ---------- leaderboard ---------- */
.board {
  width: 100%;
  border-collapse: collapse;
  margin: 32px 0 80px;
}
.board th {
  text-align: left;
  font-family: var(--font-mono);
  font-size: 0.78rem;
  color: var(--mauve);
  font-weight: 500;
  padding: 10px 16px;
  border-bottom: 1px solid var(--line);
}
.board td {
  padding: 16px;
  border-bottom: 1px solid rgba(212, 165, 72, 0.1);
  font-size: 1rem;
}
.board tr:first-child td { color: var(--gold-bright); font-weight: 700; }
.board td.num { font-family: var(--font-mono); text-align: right; }

/* ---------- dashboard ---------- */
.stat-row {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 20px;
  margin: 36px 0;
}
.stat {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: 14px;
  padding: 22px 24px;
}
.stat__label {
  font-family: var(--font-mono);
  font-size: 0.78rem;
  color: var(--mauve);
  margin-bottom: 8px;
}
.stat__value {
  font-family: var(--font-display);
  font-size: 2.1rem;
  color: var(--paper);
}
.stat__value.live { color: var(--gold-bright); }
.pulse-dot {
  display: inline-block;
  width: 9px; height: 9px;
  border-radius: 50%;
  background: var(--ticket-red-bright);
  margin-right: 8px;
  animation: pulse 1.6s ease-in-out infinite;
}
@keyframes pulse {
  0%, 100% { opacity: 1; }
  50% { opacity: 0.35; }
}
@media (prefers-reduced-motion: reduce) {
  .pulse-dot { animation: none; }
}

/* ---------- footer ---------- */
.footer {
  padding: 48px 0 60px;
  border-top: 1px solid var(--line);
  margin-top: 60px;
}
.footer p {
  font-size: 0.85rem;
  color: var(--mauve);
  max-width: 72ch;
}
.footer__age {
  display: inline-block;
  border: 1px solid var(--line);
  border-radius: 6px;
  padding: 3px 8px;
  font-family: var(--font-mono);
  font-size: 0.75rem;
  color: var(--gold);
  margin-bottom: 14px;
}

/* ---------- misc ---------- */
.badge {
  font-family: var(--font-mono);
  font-size: 0.78rem;
  color: var(--gold);
  border: 1px solid var(--line);
  border-radius: 999px;
  padding: 4px 12px;
  display: inline-block;
}
.error-banner {
  background: rgba(140, 47, 57, 0.18);
  border: 1px solid var(--ticket-red);
  color: var(--paper);
  padding: 12px 18px;
  border-radius: 10px;
  margin-bottom: 24px;
  font-size: 0.9rem;
}

:focus-visible {
  outline: 2px solid var(--gold-bright);
  outline-offset: 3px;
}

@media (max-width: 860px) {
  .steps { grid-template-columns: 1fr; }
  .nav__links { display: none; }
}
