/* ============================================================
   Contest Hub (app/contest.html)
   Hierarchy: hero (title + status + ONE facts card) → 5-step
   process → entries → leaderboard preview → rules → quiet
   trust section → winners teaser. Whitespace over cards.
   ============================================================ */

.contest-hero {
  display: grid;
  gap: 24px;
  padding-top: 8px;
}
.contest-hero-main .h-display { margin: 14px 0 10px; }
.contest-hero-main .lead { color: var(--muted); font-size: 15.5px; max-width: 520px; }
.hero-actions { display: flex; gap: 10px; margin-top: 22px; flex-wrap: wrap; }
.hero-trust { display: flex; gap: 16px; flex-wrap: wrap; margin-top: 18px; }
.hero-trust span { display: inline-flex; align-items: center; gap: 7px; font-size: 12.5px; color: var(--muted); font-weight: 600; }
.hero-trust svg { width: 15px; height: 15px; color: var(--gold); }
.hero-shortcuts { display: flex; gap: 18px; flex-wrap: wrap; margin-top: 18px; }
.hero-shortcuts a {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  font-size: 13px;
  font-weight: 700;
  color: var(--muted);
  transition: color 0.2s;
}
.hero-shortcuts a:hover { color: var(--gold); }
.hero-shortcuts svg { width: 15px; height: 15px; color: var(--gold); }

/* ---------- the ONE facts card: prize, fee, deadline, participants ---------- */
.facts-card { padding: 22px 18px 18px; text-align: center; }
.facts-prize { display: flex; flex-direction: column; align-items: center; }
.facts-label { font-size: 12px; font-weight: 700; letter-spacing: 0.14em; color: var(--muted); text-transform: uppercase; }
.prize-amount {
  font-size: clamp(38px, 8vw, 52px);
  font-weight: 900;
  letter-spacing: -0.02em;
  color: var(--gold);
  line-height: 1.1;
  margin: 8px 0 4px;
  text-shadow: 0 0 24px rgba(244, 176, 33, 0.16);
}
.facts-sub { font-size: 12.5px; color: var(--muted); font-weight: 600; }
.facts-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 8px;
  margin: 18px 0 4px;
}
.fact { display: flex; flex-direction: column; gap: 3px; }
.fact b { font-size: 17px; font-weight: 800; letter-spacing: -0.01em; }
.fact span { font-size: 11px; color: var(--muted); font-weight: 600; letter-spacing: 0.03em; text-transform: uppercase; }
.facts-date { font-size: 12px; color: var(--muted); margin: 8px 0 14px; }
.facts-list { display: flex; flex-direction: column; margin: 0 0 14px; text-align: left; }
.facts-list li {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 12px;
  padding: 7px 0;
  font-size: 12.5px;
  border-top: 1px solid var(--line);
}
.facts-list span { color: var(--muted); font-weight: 600; flex: none; }
.facts-list b { font-weight: 700; text-align: right; }
.facts-list a { color: var(--gold); font-weight: 700; }
.facts-list a:hover { text-decoration: underline; text-underline-offset: 3px; }
.facts-card .btn { margin-top: 4px; }

/* ---------- how it works — flat, numbered, no boxes ---------- */
.steps { display: flex; flex-direction: column; gap: 18px; }
.step { display: flex; gap: 14px; align-items: flex-start; }
.step-num {
  width: 34px; height: 34px;
  flex: none;
  border-radius: 50%;
  background: var(--gold-faint);
  border: 1px solid rgba(244, 176, 33, 0.45);
  color: var(--gold);
  display: flex; align-items: center; justify-content: center;
  font-weight: 800; font-size: 13.5px;
}
.step b { font-size: 15px; font-weight: 700; display: block; }
.step p { font-size: 13px; color: var(--muted); margin-top: 2px; max-width: 460px; }

/* ---------- entries strip ---------- */
.entries-strip {
  display: grid;
  grid-auto-flow: column;
  grid-auto-columns: 140px;
  gap: 12px;
  overflow-x: auto;
  padding-bottom: 6px;
  scrollbar-width: none;
}
.entries-strip::-webkit-scrollbar { display: none; }

/* ---------- leaderboard preview ---------- */
.lb-preview { display: flex; flex-direction: column; gap: 2px; }
.lb-preview-row { display: flex; align-items: center; gap: 12px; padding: 9px 12px; border-radius: var(--r-sm); transition: background 0.2s; }
.lb-preview-row:hover { background: rgba(255, 255, 255, 0.04); }
.lb-preview-row img { width: 34px; height: 34px; border-radius: 50%; }
.lb-preview-rank { width: 24px; text-align: center; font-weight: 800; font-size: 13px; color: var(--muted); flex: none; }
.lb-preview-rank.top { color: var(--gold); }
.lb-preview-row .grow { flex: 1; min-width: 0; }
.lb-preview-name { font-size: 13.5px; font-weight: 700; }
.lb-preview-city { font-size: 12px; color: var(--muted); }
.lb-preview-votes { display: inline-flex; align-items: center; gap: 5px; font-size: 12.5px; font-weight: 700; color: var(--muted); }
.lb-preview-votes svg { width: 12px; height: 12px; color: var(--gold); }

/* ---------- rules ---------- */
.rules-card li { display: flex; gap: 10px; padding: 8px 0; font-size: 14px; }
.rules-card li + li { border-top: 1px solid var(--line); }
.rules-card li svg { width: 16px; height: 16px; color: var(--gold); flex: none; margin-top: 3px; }

/* ---------- trust — quiet rows, language over badges ---------- */
.trust-grid { display: flex; flex-direction: column; gap: 16px; }
.trust-item { display: flex; gap: 12px; align-items: flex-start; }
.trust-item svg { width: 19px; height: 19px; color: var(--gold); flex: none; margin-top: 2px; }
.trust-item b { display: block; font-size: 13.5px; font-weight: 700; }
.trust-item p { font-size: 12.5px; color: var(--muted); margin-top: 2px; }

/* ---------- winners teaser ---------- */
.winners-teaser {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
  margin-top: 22px;
  padding: 13px 16px;
  border: 1px solid var(--line);
  border-radius: var(--r-md);
  background: rgba(255, 255, 255, 0.02);
}
.winners-teaser svg { width: 17px; height: 17px; color: var(--gold); flex: none; }
.winners-teaser p { flex: 1; min-width: 200px; font-size: 13px; color: var(--muted); }
.winners-teaser .more { font-size: 13px; font-weight: 700; color: var(--gold); }

/* ---------- CTA dock ---------- */

/* CTA policy: the dock is a FALLBACK purchase action. It stays
   hidden while the hero CTA is on screen (IntersectionObserver adds
   .show) so two dominant purchase buttons never compete. */
.cta-dock {
  position: fixed;
  left: 0; right: 0;
  bottom: calc(var(--nav-h) + env(safe-area-inset-bottom));
  z-index: 30;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 10px 16px;
  background: rgba(12, 8, 5, 0.92);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border-top: 1px solid var(--line);
  transform: translateY(105%);
  opacity: 0;
  pointer-events: none;
  transition: transform 0.3s cubic-bezier(0.2, 0.9, 0.3, 1), opacity 0.3s ease;
}
.cta-dock.show { transform: none; opacity: 1; pointer-events: auto; }
.cta-dock .dock-price b { font-size: 17px; font-weight: 800; display: block; line-height: 1.2; }
.cta-dock .dock-price span { font-size: 12px; color: var(--muted); font-weight: 600; }
.cta-dock .btn { flex: none; }
@media (max-width: 1023.98px) {
  /* room for the dock when it appears above the bottom nav */
  .page.has-dock { padding-bottom: calc(var(--nav-h) + env(safe-area-inset-bottom) + 96px); }
}

/* ---------- responsive ---------- */
@media (min-width: 640px) {
  .trust-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 18px 24px; }
}
@media (min-width: 1024px) {
  .contest-hero { grid-template-columns: 1.05fr 0.95fr; gap: 36px; align-items: start; padding-top: 16px; }
  .steps { display: grid; grid-template-columns: repeat(5, 1fr); gap: 20px; }
  .step { flex-direction: column; gap: 12px; }
  .entries-strip { grid-auto-columns: 170px; }
  .trust-grid { grid-template-columns: repeat(5, 1fr); gap: 24px; }
  .trust-item { flex-direction: column; gap: 10px; }
  .cta-dock { display: none; }
  .facts-card { position: sticky; top: calc(var(--topbar-h) + 16px); }
}
