@import url('https://fonts.googleapis.com/css2?family=DM+Mono:ital,wght@0,400;0,500;1,400&family=Newsreader:ital,opsz,wght@0,6..72,400;0,6..72,500;0,6..72,600;1,6..72,400&family=Plus+Jakarta+Sans:wght@400;500;600;700;800&display=swap');

:root {
  --font-sans: 'Plus Jakarta Sans', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  --font-serif: 'Newsreader', Georgia, serif;
  --font-mono: 'DM Mono', monospace;

  --bg-main: #f5f3eb;
  --bg-card: #ffffff;
  --bg-turf: #103320;
  --bg-turf-light: #184c30;
  --bg-turf-lane: rgba(255, 255, 255, 0.08);

  --text-main: #141c16;
  --text-muted: #566059;
  --text-light: #8a948c;

  --border-light: #dedad0;
  --border-dark: #141c16;

  --color-red: #d9252c;
  --color-red-soft: #fde8e8;
  --color-green: #1e8e3e;
  --color-green-soft: #e6f4ea;
  --color-yellow: #d09b18;
  --color-yellow-soft: #fef7e0;
  --color-blue: #2a72a4;
  --color-blue-soft: #e8f3fb;
  --color-pix: #009ee3;

  --shadow-sm: 0 1px 3px rgba(0,0,0,0.06), 0 1px 2px rgba(0,0,0,0.04);
  --shadow-md: 0 6px 20px rgba(0,0,0,0.08), 0 2px 6px rgba(0,0,0,0.04);
  --shadow-lg: 0 16px 44px rgba(0,0,0,0.12), 0 4px 14px rgba(0,0,0,0.06);

  --radius-sm: 6px;
  --radius-md: 12px;
  --radius-lg: 18px;
  --radius-xl: 24px;
}

.payment-confirmation-overlay {
  position: fixed;
  inset: 0;
  z-index: 1000;
  display: grid;
  place-items: center;
  background: rgb(17 24 39 / 72%);
  padding: 24px;
}

.payment-confirmation-modal {
  width: min(100%, 460px);
  padding: 42px 30px 30px;
  border: 1px solid #bbf7d0;
  border-radius: 24px;
  background: #fffdf8;
  box-shadow: 0 24px 80px rgb(17 24 39 / 28%);
  text-align: center;
}

.payment-confirmation-icon {
  display: grid;
  width: 72px;
  height: 72px;
  margin: 0 auto 18px;
  place-items: center;
  border-radius: 50%;
  background: #15803d;
  color: white;
  font-size: 42px;
  font-weight: 800;
}

.payment-confirmation-modal h2 {
  margin: 0 0 10px;
  color: #14532d;
}

.payment-confirmation-modal p {
  margin: 0 0 24px;
}

.confetti-piece {
  position: fixed;
  top: -16px;
  z-index: 1100;
  width: 9px;
  height: 16px;
  border-radius: 2px;
  animation: confetti-fall 3.2s linear forwards;
  pointer-events: none;
}

@keyframes confetti-fall {
  to { transform: translateY(110vh) rotate(720deg); }
}

.cookie-banner { position: fixed; right: 22px; bottom: 22px; z-index: 20; max-width: 430px; display: flex; gap: 22px; align-items: end; border: 1px solid #deddd7; background: #fff; padding: 18px; box-shadow: 0 8px 24px rgba(32,35,33,.08); }
.cookie-banner strong { font-size: 14px; }.cookie-banner p { margin: 5px 0 0; color: #666a63; font-size: 12px; line-height: 1.45; }.cookie-actions { display: flex; align-items: center; gap: 12px; white-space: nowrap; }.cookie-actions a { color: #666a63; font-size: 12px; }.cookie-actions button { border: 0; background: #202321; color: white; padding: 9px 12px; font-size: 12px; }
.legal-page { max-width: 760px; margin: auto; padding: 56px 24px 96px; }.legal-page h1 { margin: 42px 0 26px; font-size: clamp(54px, 8vw, 92px); }.legal-page h2 { margin: 40px 0 10px; font-size: 32px; }.legal-page p { max-width: 68ch; color: #666a63; font-size: 16px; line-height: 1.65; }.legal-page a:not(.brand) { color: #8e292d; }
@media (max-width: 620px) { .cookie-banner { right: 12px; bottom: 12px; left: 12px; display: block; }.cookie-actions { justify-content: space-between; margin-top: 14px; } }

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
  font-size: 16px;
  overflow-x: hidden;
  max-width: 100vw;
  width: 100%;
}

body {
  margin: 0;
  font-family: var(--font-sans);
  background-color: var(--bg-main);
  color: var(--text-main);
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  text-rendering: optimizeLegibility;
  overflow-x: hidden;
  max-width: 100vw;
  width: 100%;
}

/* TYPOGRAPHY STANDARDS (BETTER-TYPOGRAPHY SKILL) */
h1, h2, h3, h4, h5, h6 {
  text-wrap: balance;
  font-feature-settings: "cv02", "cv03", "cv04", "cv11";
}

p, .hero-desc, .section-subtitle, .pix-modal-sub, .share-modal-sub, .legal-section p {
  text-wrap: pretty;
  max-width: 68ch;
}

/* TABULAR NUMBERS ON CHANGING COUNTERS & METRICS */
.score-number,
.score-num,
.td-votes strong,
.td-votes small,
.rank-number,
.step-number-emboss,
.lane-pos,
.runner-tag,
.marker,
.snapshot-diff strong,
.duel-track-labels span,
.table-progress-text,
.step-pace-text {
  font-variant-numeric: tabular-nums;
  font-feature-settings: "tnum" 1;
}

/* UNDERLINE POSITIONING FROM FONT METRICS */
a, .legal-link-btn, .footer-legal-btn {
  text-underline-position: from-font;
  text-decoration-thickness: from-font;
  text-underline-offset: 3px;
  text-decoration-skip-ink: auto;
}

button, a {
  font-family: inherit;
}

/* SHELL */
.derby-shell {
  max-width: 1240px;
  width: 100%;
  margin: 0 auto;
  padding: 0 24px 80px;
  box-sizing: border-box;
  overflow-x: clip;
}

/* TOPBAR */
.derby-topbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 20px 0;
  border-bottom: 1px solid var(--border-light);
  gap: 16px;
  flex-wrap: wrap;
}

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

.brand-horseshoe {
  font-size: 26px;
  line-height: 1;
  padding: 6px;
  background: #141c16;
  border-radius: var(--radius-sm);
}

.brand-title {
  display: block;
  font-size: 15px;
  font-weight: 800;
  letter-spacing: 0.05em;
  color: var(--text-main);
}

.brand-sub {
  display: block;
  font-size: 11px;
  font-family: var(--font-mono);
  color: var(--text-muted);
}

.topbar-pills {
  display: flex;
  align-items: center;
  gap: 10px;
}

.live-badge {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  background: #eaf5eb;
  color: #1a7f37;
  font-family: var(--font-mono);
  font-size: 11px;
  font-weight: 600;
  padding: 4px 10px;
  border-radius: 999px;
  border: 1px solid #bfe3c6;
}

.pulse-dot {
  width: 7px;
  height: 7px;
  background: #1a7f37;
  border-radius: 50%;
  animation: pulse 1.6s infinite;
}

.curva-pill {
  font-family: var(--font-mono);
  font-size: 11px;
  background: #faeac9;
  border: 1px solid #ebd29f;
  padding: 4px 10px;
  border-radius: 999px;
  color: #795209;
}

.topbar-nav {
  display: flex;
  align-items: center;
  gap: 18px;
}

.nav-link {
  font-size: 13px;
  font-weight: 600;
  color: var(--text-muted);
  text-decoration: none;
  transition: color 0.15s ease;
}

.nav-link:hover {
  color: var(--text-main);
}

.sound-btn {
  background: #ece8dc;
  border: 1px solid var(--border-light);
  font-size: 12px;
  font-weight: 600;
  padding: 6px 12px;
  border-radius: 999px;
  cursor: pointer;
  color: var(--text-main);
  transition: background 0.15s ease;
}

.sound-btn:hover {
  background: #e0dbce;
}

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

.hero-slogan-badge {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: #141c16;
  color: #ffffff;
  padding: 6px 14px;
  border-radius: 999px;
  font-family: var(--font-mono);
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  margin-bottom: 18px;
  box-shadow: var(--shadow-sm);
}

.slogan-badge-icon {
  color: #e5a823;
}

.hero-headline {
  margin: 0 0 16px;
  font-size: clamp(32px, 4.2vw, 52px);
  line-height: 1.06;
  font-weight: 800;
  letter-spacing: -0.035em;
  color: var(--text-main);
}

.headline-serif {
  font-family: var(--font-serif);
  font-style: italic;
  font-weight: 400;
  color: #932227;
  letter-spacing: -0.01em;
}

.hero-desc {
  font-size: 16px;
  color: var(--text-muted);
  line-height: 1.6;
  max-width: 480px;
  margin: 0 0 28px;
}

.hero-actions {
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
}

.btn-primary {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: #141c16;
  color: #ffffff;
  padding: 13px 22px;
  font-size: 14px;
  font-weight: 700;
  text-decoration: none;
  border-radius: var(--radius-md);
  box-shadow: var(--shadow-sm);
  transition: transform 0.15s ease, background 0.15s ease;
}

.btn-primary:hover {
  background: #2e3831;
  transform: translateY(-1px);
}

.btn-secondary {
  display: inline-flex;
  align-items: center;
  background: #ece8dc;
  color: var(--text-main);
  padding: 13px 20px;
  font-size: 14px;
  font-weight: 600;
  text-decoration: none;
  border-radius: var(--radius-md);
  transition: background 0.15s ease;
}

.btn-secondary:hover {
  background: #e0dacb;
}

/* SNAPSHOT CARD */
.derby-snapshot-card {
  background: var(--bg-card);
  border: 1px solid var(--border-light);
  border-radius: var(--radius-xl);
  padding: 24px;
  box-shadow: var(--shadow-md);
}

.snapshot-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 18px;
  padding-bottom: 12px;
  border-bottom: 1px solid var(--border-light);
}

.snapshot-label {
  font-family: var(--font-mono);
  font-size: 11px;
  font-weight: 600;
  color: var(--text-light);
  letter-spacing: 0.05em;
}

.snapshot-diff {
  font-size: 12px;
  color: var(--text-main);
  background: #fef4dc;
  border: 1px solid #fae29f;
  padding: 3px 8px;
  border-radius: var(--radius-sm);
}

.snapshot-duelists {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.mini-duelist {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 10px;
  border-radius: var(--radius-md);
  background: #fbf9f4;
  border: 1px solid var(--border-light);
  flex: 1;
}

.mini-duelist.is-leading {
  background: #fdfbee;
  border-color: #d6af36;
  box-shadow: 0 0 0 1px #d6af36;
}

.mini-avatar-wrap {
  width: 44px;
  height: 44px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: #ece8dc;
  border-radius: 50%;
  overflow: hidden;
}

.mini-avatar {
  width: 42px;
  height: 42px;
  object-fit: contain;
}

.gallop-mini {
  animation: gallop-mini 1.2s infinite ease-in-out;
}

.mini-info strong {
  display: block;
  font-size: 13px;
  line-height: 1.2;
}

.mini-horse {
  display: block;
  font-size: 11px;
  color: var(--text-muted);
}

.mini-score {
  margin-left: auto;
  text-align: right;
}

.score-num {
  display: block;
  font-family: var(--font-mono);
  font-size: 18px;
  font-weight: 700;
  line-height: 1;
}

.score-unit {
  font-size: 10px;
  color: var(--text-light);
  font-family: var(--font-mono);
}

.versus-divider {
  font-family: var(--font-mono);
  font-weight: 800;
  font-size: 13px;
  color: var(--text-light);
}

.snapshot-progress {
  margin-top: 20px;
}

.duel-track-bar {
  display: flex;
  height: 10px;
  border-radius: 999px;
  overflow: hidden;
  background: #eae6d8;
}

.duel-bar-fill {
  height: 100%;
  transition: width 0.4s ease;
}

.lula-fill {
  background: var(--color-red);
}

.flavio-fill {
  background: var(--color-green);
}

.duel-track-labels {
  display: flex;
  justify-content: space-between;
  font-family: var(--font-mono);
  font-size: 11px;
  color: var(--text-muted);
  margin-top: 6px;
}

/* SECTION HEADERS */
.podium-section, .racetrack-section, .leaderboard-section {
  margin-top: 48px;
  padding-top: 36px;
  border-top: 1px solid var(--border-light);
}

.section-title-wrap {
  margin-bottom: 28px;
}

.section-tag {
  font-family: var(--font-mono);
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.08em;
  color: #79827a;
  text-transform: uppercase;
  margin-bottom: 6px;
}

.section-title {
  margin: 0 0 6px;
  font-size: clamp(24px, 3.2vw, 36px);
  font-weight: 800;
  letter-spacing: -0.03em;
  color: var(--text-main);
}

.section-subtitle {
  margin: 0;
  font-size: 15px;
  color: var(--text-muted);
}

/* PHYSICAL STEPPED PODIUM ARENA */
.physical-podium-arena {
  background: #fbf9f4;
  border: 1px solid var(--border-light);
  border-radius: var(--radius-xl);
  padding: 40px 20px 24px;
  box-shadow: var(--shadow-md);
}

.physical-podium-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 16px;
  align-items: flex-end;
}

.podium-station {
  display: flex;
  flex-direction: column;
  align-items: center;
  transition: transform 0.25s ease;
}

.podium-station:hover {
  transform: translateY(-4px);
}

/* GALLOPING JOCKEY STAGE (ON TOP OF STEP) */
.podium-jockey-stage {
  position: relative;
  width: 100%;
  height: 200px;
  display: flex;
  align-items: flex-end;
  justify-content: center;
  z-index: 2;
  margin-bottom: -6px;
}

.jockey-gallop-actor {
  position: relative;
  width: 190px;
  height: 190px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.jockey-actor-img {
  max-width: 100%;
  max-height: 100%;
  width: auto;
  height: auto;
  object-fit: contain;
  filter: drop-shadow(0 10px 18px rgba(0, 30, 10, 0.25));
}

.actor-ground-shadow {
  position: absolute;
  bottom: 6px;
  left: 50%;
  transform: translateX(-50%);
  width: 120px;
  height: 14px;
  background: radial-gradient(ellipse at center, rgba(16, 56, 24, 0.5) 0%, transparent 70%);
  border-radius: 50%;
  z-index: 1;
  animation: turf-shadow-pulse 1.1s infinite ease-in-out;
}

/* PHYSICAL STEP BLOCK */
.physical-step-block {
  width: 100%;
  background: #ffffff;
  border: 1px solid var(--border-light);
  border-radius: var(--radius-lg);
  padding: 16px 14px;
  box-shadow: var(--shadow-sm);
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  position: relative;
  overflow: hidden;
}

/* STEP HEIGHTS & ACCENTS */
.podium-step-1 .physical-step-block {
  border-color: #d6af36;
  background: linear-gradient(180deg, #ffffff 0%, #fdf9ec 100%);
  box-shadow: 0 8px 28px rgba(214, 175, 54, 0.2);
  min-height: 380px;
}

.podium-step-2 .physical-step-block {
  border-color: #9cb2a4;
  background: linear-gradient(180deg, #ffffff 0%, #f4f8f5 100%);
  min-height: 350px;
}

.podium-step-3 .physical-step-block {
  border-color: #d5a278;
  background: linear-gradient(180deg, #ffffff 0%, #fdf6f0 100%);
  min-height: 330px;
}

.podium-step-4 .physical-step-block {
  border-color: #96b8cf;
  background: linear-gradient(180deg, #ffffff 0%, #f2f7fc 100%);
  min-height: 310px;
}

/* STEP HEADER */
.step-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  width: 100%;
  margin-bottom: 6px;
}

.step-medal {
  font-size: 16px;
}

.step-rank-badge {
  font-family: var(--font-mono);
  font-size: 11px;
  font-weight: 800;
  letter-spacing: 0.05em;
  color: var(--text-main);
}

.step-party-tag {
  font-family: var(--font-mono);
  font-size: 10px;
  font-weight: 800;
  padding: 2px 7px;
  border-radius: 999px;
  color: #ffffff;
  text-shadow: 0 1px 2px rgba(0, 0, 0, 0.45);
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.15);
}

/* EMBOSSED NUMBER */
.step-number-emboss {
  font-family: var(--font-mono);
  font-size: 52px;
  font-weight: 900;
  line-height: 1;
  color: rgba(20, 28, 22, 0.08);
  margin: 2px 0 -18px;
  user-select: none;
}

.podium-step-1 .step-number-emboss { color: rgba(214, 175, 54, 0.18); }
.podium-step-2 .step-number-emboss { color: rgba(126, 145, 133, 0.16); }
.podium-step-3 .step-number-emboss { color: rgba(184, 122, 76, 0.16); }
.podium-step-4 .step-number-emboss { color: rgba(77, 122, 153, 0.16); }

/* STEP INFO */
.step-info {
  margin-bottom: 8px;
  position: relative;
  z-index: 2;
}

.step-name {
  margin: 0;
  font-size: 15px;
  font-weight: 800;
  letter-spacing: -0.02em;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  color: var(--text-main);
}

.step-horse {
  margin: 2px 0 0;
  font-size: 11px;
  color: var(--text-muted);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

/* SCORE CARD */
.step-score-card {
  width: 100%;
  margin-bottom: 12px;
}

.score-main {
  display: flex;
  align-items: baseline;
  justify-content: center;
  gap: 5px;
}

.score-number {
  font-family: var(--font-mono);
  font-size: 26px;
  font-weight: 900;
  line-height: 1;
}

.score-label {
  font-family: var(--font-mono);
  font-size: 10px;
  font-weight: 700;
  color: var(--text-light);
}

.step-track-meter {
  width: 100%;
  height: 6px;
  background: #e8e4d8;
  border-radius: 999px;
  overflow: hidden;
  margin: 6px 0 4px;
}

.meter-bar {
  height: 100%;
  transition: width 0.3s ease;
}

.step-pace-text {
  font-family: var(--font-mono);
  font-size: 10px;
  color: var(--text-muted);
}

/* STEP ACTIONS (PIX & TURBO) */
.step-actions {
  width: 100%;
  display: flex;
  flex-direction: column;
  gap: 6px;
  margin-top: auto;
}

.step-pix-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  background: var(--btn-bg, #141c16);
  color: #ffffff;
  padding: 9px 8px;
  border-radius: var(--radius-sm);
  border: none;
  font-size: 12px;
  font-weight: 800;
  cursor: pointer;
  text-shadow: 0 1px 2px rgba(0, 0, 0, 0.4);
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.15);
  transition: transform 0.12s ease, filter 0.15s ease;
}

.step-pix-btn:hover {
  filter: brightness(1.1);
  transform: translateY(-1px);
}

.step-pix-btn:active {
  transform: scale(0.98);
}

.pix-badge {
  font-family: var(--font-mono);
  font-size: 9px;
  font-weight: 800;
  background: rgba(0, 0, 0, 0.38);
  color: #ffffff;
  padding: 2px 5px;
  border-radius: 3px;
  text-shadow: none;
}

.step-turbo-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background: #f2ede2;
  color: var(--text-main);
  padding: 7px 8px;
  border-radius: var(--radius-sm);
  border: 1px solid var(--border-light);
  font-size: 11px;
  font-weight: 600;
  cursor: pointer;
  transition: background 0.15s ease;
}

.step-turbo-btn:hover {
  background: #e4ddd0;
}

/* GALLOP KEYFRAMES */
.gallop-anim-1 {
  animation: gallop-wave 1.15s infinite ease-in-out;
}

.gallop-anim-2 {
  animation: gallop-wave 1.25s infinite ease-in-out 0.15s;
}

.gallop-anim-3 {
  animation: gallop-wave 1.18s infinite ease-in-out 0.3s;
}

.gallop-anim-4 {
  animation: gallop-wave 1.22s infinite ease-in-out 0.45s;
}

@keyframes gallop-wave {
  0% { transform: translateY(0px) rotate(0deg) scale(1); }
  25% { transform: translateY(-7px) rotate(-1.5deg) scale(1.02); }
  50% { transform: translateY(-1px) rotate(0.8deg) scale(0.99); }
  75% { transform: translateY(-9px) rotate(-1deg) scale(1.025); }
  100% { transform: translateY(0px) rotate(0deg) scale(1); }
}

@keyframes gallop-mini {
  0%, 100% { transform: translateY(0) rotate(0); }
  50% { transform: translateY(-4px) rotate(-2deg); }
}

@keyframes turf-shadow-pulse {
  0%, 100% {
    transform: translateX(-50%) scale(1);
    opacity: 0.55;
  }
  50% {
    transform: translateX(-50%) scale(0.75);
    opacity: 0.28;
  }
}

/* RACETRACK SECTION */
.turf-grandstand {
  background: var(--bg-turf);
  border-radius: var(--radius-xl);
  padding: 30px 24px;
  color: #ffffff;
  box-shadow: var(--shadow-lg);
  position: relative;
  overflow: hidden;
}

.turf-track-field {
  position: relative;
  padding-top: 36px;
}

.track-markers {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 30px;
}

.marker {
  position: absolute;
  transform: translateX(-50%);
  display: flex;
  flex-direction: column;
  align-items: center;
  font-family: var(--font-mono);
}

.marker i {
  font-style: normal;
  font-size: 10px;
  color: #9cd5b4;
}

.marker b {
  font-size: 9px;
  letter-spacing: 0.05em;
  color: #e5ffef;
}

.current-bend-marker b {
  color: #ffde6b;
  font-weight: 800;
}

.finish-marker b {
  color: #ffdf78;
}

.turf-lanes {
  display: flex;
  flex-direction: column;
  gap: 12px;
  margin-top: 10px;
}

.turf-lane {
  display: grid;
  grid-template-columns: 110px 1fr 64px;
  align-items: center;
  gap: 14px;
  background: var(--bg-turf-lane);
  border: 1px solid rgba(255, 255, 255, 0.08);
  padding: 8px 12px;
  border-radius: var(--radius-md);
  position: relative;
}

.turf-lane.leader-lane {
  background: rgba(229, 168, 35, 0.15);
  border-color: rgba(229, 168, 35, 0.4);
}

.lane-header-badge {
  display: flex;
  align-items: center;
  gap: 8px;
  min-width: 0;
}

.lane-pos {
  font-family: var(--font-mono);
  font-size: 11px;
  font-weight: 700;
  color: #9cd5b4;
}

.lane-candidate-name {
  font-size: 13px;
  font-weight: 700;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.lane-surface {
  position: relative;
  height: 38px;
  background: rgba(0, 0, 0, 0.22);
  border-radius: var(--radius-sm);
  overflow: visible;
}

.lane-surface::before {
  content: '';
  position: absolute;
  top: 0; bottom: 0; left: 0; right: 0;
  background: repeating-linear-gradient(
    90deg,
    transparent,
    transparent 24.8%,
    rgba(255, 255, 255, 0.08) 25%,
    rgba(255, 255, 255, 0.08) 25.2%
  );
  pointer-events: none;
}

.lane-gallop-runner {
  position: absolute;
  top: 50%;
  transform: translate(-50%, -50%);
  transition: left 0.45s cubic-bezier(0.34, 1.56, 0.64, 1);
  z-index: 2;
}

.runner-avatar-bubble {
  display: flex;
  align-items: center;
  gap: 4px;
  background: #ffffff;
  padding: 2px 6px 2px 2px;
  border-radius: 999px;
  border: 2px solid #ffffff;
  box-shadow: 0 3px 10px rgba(0,0,0,0.35);
}

.gallop-bubble {
  animation: gallop-mini 1.1s infinite ease-in-out;
}

.bubble-img {
  width: 26px;
  height: 26px;
  object-fit: contain;
}

.bubble-silk {
  font-size: 14px;
  line-height: 1;
  padding: 2px;
  border-radius: 50%;
}

.runner-tag {
  font-family: var(--font-mono);
  font-size: 10px;
  font-weight: 700;
  color: #ffffff;
  padding: 1px 6px;
  border-radius: 999px;
}

.lane-boost-btn {
  background: rgba(0, 158, 227, 0.25);
  border: 1px solid rgba(0, 158, 227, 0.5);
  color: #ffffff;
  font-family: var(--font-mono);
  font-size: 11px;
  font-weight: 700;
  padding: 7px 0;
  border-radius: var(--radius-sm);
  cursor: pointer;
  transition: background 0.15s ease, transform 0.1s ease;
}

.lane-boost-btn:hover {
  background: rgba(0, 158, 227, 0.5);
  transform: scale(1.05);
}

/* LEADERBOARD TABLE & MOBILE CARDS */
.desktop-table-view {
  display: block;
}

.mobile-cards-view {
  display: none;
}

.table-container {
  background: var(--bg-card);
  border: 1px solid var(--border-light);
  border-radius: var(--radius-xl);
  overflow-x: auto;
  box-shadow: var(--shadow-sm);
}

.derby-table {
  width: 100%;
  border-collapse: collapse;
  text-align: left;
}

.derby-table thead {
  background: #fbf9f4;
  border-bottom: 1px solid var(--border-light);
}

.derby-table th {
  padding: 14px 18px;
  font-family: var(--font-mono);
  font-size: 11px;
  font-weight: 600;
  color: var(--text-light);
  letter-spacing: 0.05em;
  text-transform: uppercase;
}

.derby-table td {
  padding: 14px 18px;
  border-bottom: 1px solid var(--border-light);
  vertical-align: middle;
}

.table-row:last-child td {
  border-bottom: none;
}

.table-row.top-tier {
  background: #fdfcf9;
}

.td-rank {
  width: 50px;
}

.rank-number {
  font-family: var(--font-mono);
  font-size: 13px;
  font-weight: 700;
  color: var(--text-light);
}

.candidate-cell {
  display: flex;
  align-items: center;
  gap: 12px;
}

.cell-avatar {
  width: 38px;
  height: 38px;
  object-fit: contain;
  background: #ece8dc;
  border-radius: 50%;
  padding: 2px;
}

.cell-emoji-avatar {
  width: 38px;
  height: 38px;
  border-radius: 50%;
  background: #ece8dc;
  border: 2px solid var(--border-light);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 18px;
  line-height: 1;
}

.cell-dot {
  width: 14px;
  height: 14px;
  border-radius: 50%;
}

.cell-name {
  display: block;
  font-size: 14px;
  font-weight: 700;
  color: var(--text-main);
}

.cell-horse {
  display: block;
  font-size: 11px;
  color: var(--text-muted);
}

.cell-name-row {
  display: flex;
  align-items: center;
  gap: 8px;
}

.mobile-party-badge {
  display: none;
}

.desktop-party-badge {
  display: inline-block;
}

.rank-medal {
  font-size: 16px;
  line-height: 1;
}

.rank-num {
  font-family: var(--font-mono);
  font-size: 12px;
  font-weight: 700;
  color: var(--text-light);
}

.party-badge {
  font-family: var(--font-mono);
  font-size: 11px;
  font-weight: 600;
  background: #efece4;
  padding: 3px 8px;
  border-radius: var(--radius-sm);
  color: var(--text-main);
}

.table-progress-bar {
  height: 6px;
  background: #ebe7db;
  border-radius: 999px;
  overflow: hidden;
  margin-bottom: 4px;
}

.table-progress-fill {
  height: 100%;
  transition: width 0.3s ease;
}

.table-progress-text {
  font-family: var(--font-mono);
  font-size: 10px;
  color: var(--text-light);
}

.td-votes {
  font-family: var(--font-mono);
}

.td-votes strong {
  font-size: 16px;
  font-weight: 700;
  color: var(--text-main);
}

.td-votes small {
  font-size: 11px;
  color: var(--text-light);
}

.table-vote-btn {
  background: #f0f7f3;
  border: 1px solid #c2e2cc;
  color: #1a7f37;
  padding: 6px 12px;
  border-radius: var(--radius-sm);
  font-size: 12px;
  font-weight: 700;
  cursor: pointer;
  transition: all 0.15s ease;
  white-space: nowrap;
}

.table-vote-btn:hover {
  background: #1a7f37;
  color: #ffffff;
  border-color: #1a7f37;
}

/* PIX MODAL */
.pix-modal-overlay {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: rgba(18, 24, 20, 0.65);
  backdrop-filter: blur(8px);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 20px;
  z-index: 1000;
  animation: fadeIn 0.2s ease-out;
}

.pix-modal-card {
  background: #ffffff;
  border-radius: var(--radius-xl);
  max-width: 440px;
  width: 100%;
  padding: 28px;
  box-shadow: var(--shadow-lg);
  position: relative;
  text-align: center;
  animation: modalPop 0.25s cubic-bezier(0.34, 1.56, 0.64, 1);
}

.pix-modal-close {
  position: absolute;
  top: 16px;
  right: 16px;
  background: #f0ede4;
  border: none;
  width: 32px;
  height: 32px;
  border-radius: 50%;
  font-size: 14px;
  color: var(--text-muted);
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: background 0.15s ease;
}

.pix-modal-close:hover {
  background: #e2ded0;
  color: var(--text-main);
}

.pix-mp-badge {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  background: #e5f6fd;
  color: #007bb3;
  padding: 4px 10px;
  border-radius: 999px;
  font-family: var(--font-mono);
  font-size: 11px;
  font-weight: 700;
  margin-bottom: 8px;
}

.pix-modal-title {
  margin: 0 0 4px;
  font-size: 20px;
  font-weight: 800;
}

.pix-modal-sub {
  margin: 0 0 16px;
  font-size: 13px;
  color: var(--text-muted);
}

.pix-amount-pill {
  display: flex;
  justify-content: space-between;
  align-items: center;
  background: #f7f5ee;
  border: 1px solid var(--border-light);
  padding: 10px 16px;
  border-radius: var(--radius-md);
  margin-bottom: 16px;
  font-size: 14px;
}

.pix-amount-pill strong {
  font-family: var(--font-mono);
  font-size: 18px;
  color: #1a7f37;
}

.pix-qr-container {
  display: flex;
  flex-direction: column;
  align-items: center;
  margin: 16px 0;
}

.pix-qr-img {
  width: 200px;
  height: 200px;
  border-radius: var(--radius-md);
  border: 2px solid var(--border-light);
  padding: 6px;
  background: #ffffff;
  box-shadow: var(--shadow-sm);
}

.qr-scan-hint {
  margin-top: 8px;
  font-size: 12px;
  color: var(--text-muted);
}

.pix-copia-cola-box {
  text-align: left;
  margin: 14px 0;
}

.pix-label {
  display: block;
  font-size: 11px;
  font-family: var(--font-mono);
  color: var(--text-muted);
  margin-bottom: 6px;
}

.pix-input-group {
  display: flex;
  gap: 8px;
}

.pix-input {
  flex: 1;
  padding: 9px 12px;
  border: 1px solid var(--border-light);
  border-radius: var(--radius-sm);
  background: #faf8f2;
  font-family: var(--font-mono);
  font-size: 11px;
  color: var(--text-muted);
  outline: none;
}

.btn-copy-pix {
  background: #141c16;
  color: #ffffff;
  border: none;
  padding: 0 16px;
  border-radius: var(--radius-sm);
  font-size: 12px;
  font-weight: 700;
  cursor: pointer;
  transition: background 0.15s ease;
}

.btn-copy-pix.copied {
  background: #1a7f37;
}

.pix-status-indicator {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  font-size: 12px;
  color: var(--text-muted);
  margin: 14px 0 10px;
}

.pix-dev-helper {
  margin-top: 14px;
  padding-top: 12px;
  border-top: 1px dashed var(--border-light);
}

.btn-simulate-pix {
  background: #f0fdf4;
  border: 1px solid #86efac;
  color: #166534;
  font-size: 11px;
  font-weight: 700;
  padding: 8px 12px;
  border-radius: var(--radius-sm);
  cursor: pointer;
  width: 100%;
  transition: background 0.15s ease;
}

.btn-simulate-pix:hover {
  background: #dcfce7;
}

.pix-modal-footer-actions {
  margin-top: 14px;
  display: flex;
  justify-content: center;
}

.btn-cancel-modal {
  background: transparent;
  border: 1px solid var(--border-light);
  color: var(--text-muted);
  padding: 8px 20px;
  border-radius: var(--radius-sm);
  font-size: 12px;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.15s ease;
}

.btn-cancel-modal:hover {
  background: #ece8dc;
  color: var(--text-main);
}

.pix-loading-state, .pix-approved-state {
  padding: 32px 16px;
}

.pix-spinner {
  width: 36px;
  height: 36px;
  border: 3px solid #e0dbce;
  border-top-color: #141c16;
  border-radius: 50%;
  margin: 0 auto 16px;
  animation: spin 0.8s linear infinite;
}

.approved-badge-icon {
  font-size: 48px;
  line-height: 1;
  margin-bottom: 12px;
}

/* FOOTER */
.derby-footer {
  margin-top: 60px;
  padding-top: 24px;
  border-top: 1px solid var(--border-light);
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 16px;
  font-family: var(--font-mono);
  font-size: 11px;
  color: var(--text-light);
}

.footer-left strong {
  display: block;
  color: var(--text-main);
}

.footer-right a {
  color: var(--text-muted);
  text-decoration: none;
}

.footer-right a:hover {
  color: var(--text-main);
}

/* TOAST */
.toast {
  position: fixed;
  bottom: 24px;
  right: 24px;
  background: #141c16;
  color: #ffffff;
  padding: 12px 18px;
  border-radius: var(--radius-md);
  font-size: 13px;
  box-shadow: var(--shadow-lg);
  opacity: 0;
  transform: translateY(12px);
  pointer-events: none;
  transition: opacity 0.25s ease, transform 0.25s ease;
  z-index: 1001;
}

.toast.show {
  opacity: 1;
  transform: translateY(0);
}

/* KEYFRAMES */
@keyframes fadeIn { from { opacity: 0; } to { opacity: 1; } }
@keyframes modalPop { from { transform: scale(0.92); opacity: 0; } to { transform: scale(1); opacity: 1; } }
@keyframes spin { to { transform: rotate(360deg); } }
@keyframes pulse {
  0% { transform: scale(1); opacity: 1; }
  50% { transform: scale(1.4); opacity: 0.5; }
  100% { transform: scale(1); opacity: 1; }
}

/* LEGAL TOP ALERT */
.legal-top-alert {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  background: #fdf6e6;
  border: 1px solid #f8e1b0;
  border-radius: var(--radius-md);
  padding: 10px 16px;
  margin-top: 16px;
  font-size: 12px;
  color: #704f08;
  line-height: 1.4;
}

.legal-top-alert strong {
  color: #4a3300;
}

.legal-link-btn {
  background: none;
  border: none;
  color: #8f650a;
  text-decoration: underline;
  font-weight: 700;
  cursor: pointer;
  white-space: nowrap;
  font-size: 12px;
  padding: 0;
}

.legal-link-btn:hover {
  color: #4a3300;
}

/* FOOTER LEGAL LINKS */
.footer-legal-links {
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
}

.footer-legal-btn {
  background: none;
  border: none;
  color: var(--text-muted);
  font-family: var(--font-mono);
  font-size: 11px;
  cursor: pointer;
  padding: 0;
  text-decoration: underline;
  transition: color 0.15s ease;
}

.footer-legal-btn:hover {
  color: var(--text-main);
}

/* LEGAL MODAL */
.legal-modal-overlay {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: rgba(16, 22, 18, 0.7);
  backdrop-filter: blur(8px);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 20px;
  z-index: 1002;
  animation: fadeIn 0.2s ease-out;
}

.legal-modal-card {
  background: #ffffff;
  border-radius: var(--radius-xl);
  max-width: 580px;
  width: 100%;
  max-height: 85vh;
  display: flex;
  flex-direction: column;
  box-shadow: var(--shadow-lg);
  overflow: hidden;
  animation: modalPop 0.25s cubic-bezier(0.34, 1.56, 0.64, 1);
}

.legal-modal-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 20px 24px;
  border-bottom: 1px solid var(--border-light);
  background: #fbf9f4;
}

.legal-modal-header h3 {
  margin: 0;
  font-size: 18px;
  font-weight: 800;
  letter-spacing: -0.01em;
}

.legal-close-btn {
  background: #ede8dc;
  border: none;
  width: 32px;
  height: 32px;
  border-radius: 50%;
  font-size: 14px;
  color: var(--text-muted);
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: background 0.15s ease;
}

.legal-close-btn:hover {
  background: #ded7c6;
  color: var(--text-main);
}

.legal-modal-body {
  padding: 24px;
  overflow-y: auto;
  font-size: 14px;
  color: var(--text-main);
  line-height: 1.6;
}

.legal-section {
  margin-bottom: 20px;
}

.legal-section:last-child {
  margin-bottom: 0;
}

.legal-section h4 {
  margin: 0 0 6px;
  font-size: 14px;
  font-weight: 700;
  color: #103320;
}

.legal-section p {
  margin: 0;
  color: var(--text-muted);
}

.legal-modal-footer {
  padding: 16px 24px;
  border-top: 1px solid var(--border-light);
  background: #fbf9f4;
  display: flex;
  justify-content: flex-end;
}

.legal-btn-agree {
  background: #141c16;
  color: #ffffff;
  border: none;
  padding: 10px 20px;
  border-radius: var(--radius-sm);
  font-size: 13px;
  font-weight: 700;
  cursor: pointer;
  transition: background 0.15s ease;
}

/* FREE VOTE BUTTON GLOW */
.free-vote-btn {
  background: linear-gradient(135deg, #107c41 0%, #1e8e3e 100%) !important;
  box-shadow: 0 0 14px rgba(30, 142, 62, 0.35);
  animation: freeVotePulse 2s infinite ease-in-out;
}

@keyframes freeVotePulse {
  0% { transform: scale(1); box-shadow: 0 0 10px rgba(30, 142, 62, 0.25); }
  50% { transform: scale(1.02); box-shadow: 0 0 20px rgba(30, 142, 62, 0.5); }
  100% { transform: scale(1); box-shadow: 0 0 10px rgba(30, 142, 62, 0.25); }
}

.free-badge {
  background: #ffeb3b !important;
  color: #141c16 !important;
  font-weight: 800 !important;
}

/* TOPBAR & PODIUM SHARE BUTTONS */
.topbar-share-btn {
  background: #25d366;
  color: #ffffff;
  border: none;
  font-size: 12px;
  font-weight: 700;
  padding: 6px 14px;
  border-radius: 999px;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 5px;
  transition: transform 0.15s ease, filter 0.15s ease;
}

.topbar-share-btn:hover {
  filter: brightness(1.08);
  transform: translateY(-1px);
}

.step-share-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 4px;
  background: #f0ece3;
  color: var(--text-main);
  border: 1px solid var(--border-light);
  padding: 7px 8px;
  border-radius: var(--radius-sm);
  font-size: 11px;
  font-weight: 700;
  cursor: pointer;
  transition: all 0.15s ease;
  width: 100%;
}

.step-share-btn:hover {
  background: #25d366;
  color: #ffffff;
  border-color: #25d366;
}

.step-share-btn.mini-share {
  padding: 4px 6px;
  font-size: 10px;
}

/* SHARE MODAL */
.share-modal-overlay {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: rgba(14, 20, 16, 0.68);
  backdrop-filter: blur(8px);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 20px;
  z-index: 1003;
  animation: fadeIn 0.2s ease-out;
}

.share-modal-card {
  background: #ffffff;
  border-radius: var(--radius-xl);
  max-width: 480px;
  width: 100%;
  padding: 28px;
  box-shadow: var(--shadow-lg);
  position: relative;
  text-align: center;
  animation: modalPop 0.25s cubic-bezier(0.34, 1.56, 0.64, 1);
}

.share-modal-close {
  position: absolute;
  top: 16px;
  right: 16px;
  background: #f0ede4;
  border: none;
  width: 32px;
  height: 32px;
  border-radius: 50%;
  font-size: 14px;
  color: var(--text-muted);
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: background 0.15s ease;
}

.share-modal-close:hover {
  background: #e2ded0;
  color: var(--text-main);
}

.share-badge {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  background: #e8f8ee;
  color: #166534;
  padding: 4px 10px;
  border-radius: 999px;
  font-family: var(--font-mono);
  font-size: 11px;
  font-weight: 700;
  margin-bottom: 8px;
}

.share-modal-title {
  margin: 0 0 6px;
  font-size: 20px;
  font-weight: 800;
  color: var(--text-main);
}

.share-modal-sub {
  margin: 0 0 20px;
  font-size: 13px;
  color: var(--text-muted);
  line-height: 1.5;
}

.share-social-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 10px;
  margin-bottom: 20px;
}

.btn-share-social {
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: 14px 8px;
  border-radius: var(--radius-md);
  text-decoration: none;
  transition: transform 0.15s ease, box-shadow 0.15s ease;
}

.btn-share-social:hover {
  transform: translateY(-2px);
  box-shadow: var(--shadow-md);
}

.share-whatsapp {
  background: #e8f8ee;
  border: 1px solid #86efac;
  color: #14532d;
}

.share-twitter {
  background: #f3f4f6;
  border: 1px solid #d1d5db;
  color: #111827;
}

.share-telegram {
  background: #e0f2fe;
  border: 1px solid #7dd3fc;
  color: #0369a1;
}

.social-icon {
  font-size: 24px;
  margin-bottom: 6px;
  line-height: 1;
}

.social-text strong {
  display: block;
  font-size: 12px;
  font-weight: 800;
}

.social-text small {
  font-size: 10px;
  opacity: 0.8;
  display: block;
}

.share-copy-box {
  text-align: left;
  margin: 16px 0 20px;
}

.share-label {
  display: block;
  font-family: var(--font-mono);
  font-size: 11px;
  color: var(--text-muted);
  margin-bottom: 6px;
}

.share-input-group {
  display: flex;
  gap: 8px;
}

.share-input {
  flex: 1;
  padding: 9px 12px;
  border: 1px solid var(--border-light);
  border-radius: var(--radius-sm);
  background: #faf8f2;
  font-family: var(--font-mono);
  font-size: 11px;
  color: var(--text-muted);
  outline: none;
}

.btn-copy-share {
  background: #141c16;
  color: #ffffff;
  border: none;
  padding: 0 16px;
  border-radius: var(--radius-sm);
  font-size: 12px;
  font-weight: 700;
  cursor: pointer;
  transition: background 0.15s ease;
  white-space: nowrap;
}

.btn-copy-share:hover {
  background: #25d366;
}

.share-modal-footer {
  display: flex;
  justify-content: center;
}

/* RESPONSIVE */
@media (max-width: 1050px) {
  .physical-podium-arena {
    padding: 28px 14px 20px;
  }

  .physical-podium-grid {
    grid-template-columns: repeat(4, 1fr);
    gap: 10px;
  }

  .podium-jockey-stage {
    height: 150px;
  }

  .jockey-gallop-actor {
    width: 140px;
    height: 140px;
  }

  .podium-step-1 .physical-step-block { min-height: 330px; }
  .podium-step-2 .physical-step-block { min-height: 300px; }
  .podium-step-3 .physical-step-block { min-height: 280px; }
  .podium-step-4 .physical-step-block { min-height: 260px; }
}

@media (max-width: 900px) {
  .derby-hero {
    grid-template-columns: 1fr;
    gap: 32px;
    padding: 36px 0;
  }

  .turf-lane {
    grid-template-columns: 90px 1fr 50px;
  }
}

@media (max-width: 650px) {
  .derby-shell {
    padding: 0 10px 50px;
  }

  .legal-top-alert {
    flex-direction: column;
    align-items: flex-start;
  }

  /* 4-PLACE STEPPED PODIUM FITS FULLY ON MOBILE */
  .physical-podium-arena {
    padding: 16px 4px 12px;
    border-radius: var(--radius-lg);
  }

  .physical-podium-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 4px;
    align-items: flex-end;
    min-width: 0;
    width: 100%;
  }

  .podium-station {
    width: 100%;
    min-width: 0;
  }

  .podium-jockey-stage {
    height: 85px;
    margin-bottom: -4px;
  }

  .jockey-gallop-actor {
    width: 76px;
    height: 76px;
  }

  .actor-ground-shadow {
    width: 48px;
    height: 6px;
    bottom: 2px;
  }

  .physical-step-block {
    padding: 8px 3px 8px;
    border-radius: 8px;
    width: 100%;
    min-width: 0;
  }

  .podium-step-1 .physical-step-block { min-height: 245px; }
  .podium-step-2 .physical-step-block { min-height: 220px; }
  .podium-step-3 .physical-step-block { min-height: 198px; }
  .podium-step-4 .physical-step-block { min-height: 178px; }

  .step-header {
    justify-content: center;
    gap: 2px;
    margin-bottom: 2px;
  }

  .step-medal {
    font-size: 13px;
  }

  .step-rank-badge {
    display: none;
  }

  .step-party-tag {
    font-size: 8px;
    padding: 1px 3px;
    font-weight: 800;
  }

  .step-number-emboss {
    font-size: 28px;
    margin: 0 0 -10px;
  }

  .step-name {
    font-size: 10px;
    font-weight: 800;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    max-width: 100%;
    margin: 0;
  }

  .step-horse {
    display: none;
  }

  .step-score-card {
    margin-bottom: 6px;
  }

  .score-number {
    font-size: 16px;
  }

  .score-label {
    font-size: 7px;
  }

  .step-track-meter {
    height: 3px;
    margin: 3px 0 2px;
  }

  .step-pace-text {
    font-size: 7px;
    white-space: nowrap;
  }

  .step-actions {
    gap: 3px;
    width: 100%;
  }

  .step-pix-btn {
    padding: 5px 2px;
    font-size: 9px;
    gap: 2px;
    border-radius: 4px;
  }

  .pix-badge {
    font-size: 7px;
    padding: 1px 2px;
  }

  .btn-price-label {
    display: none;
  }

  .btn-main-label {
    font-size: 9px;
    font-weight: 800;
  }

  .step-turbo-btn {
    padding: 4px 2px;
    font-size: 8px;
    border-radius: 4px;
  }

  .topbar-nav {
    display: none;
  }

  .snapshot-duelists {
    flex-direction: column;
  }

  .versus-divider {
    transform: rotate(90deg);
  }

  .footer-legal-links {
    flex-direction: column;
    gap: 6px;
  }

  .share-input, .pix-input, input[type="text"] {
    font-size: 16px;
  }
}

/* ==========================================================================
   LEADERBOARD RESPONSIVE CARDS (MOBILE & TABLETS <= 960px)
   ========================================================================== */
@media (max-width: 960px) {
  .desktop-table-view {
    display: none !important;
  }

  .mobile-cards-view {
    display: flex !important;
    flex-direction: column;
    gap: 14px;
    width: 100%;
    box-sizing: border-box;
    overflow-x: hidden;
  }

  .leaderboard-section {
    padding: 24px 0 36px;
  }

  .leaderboard-mobile-card {
    display: flex;
    flex-direction: column;
    background: #ffffff;
    border: 1px solid var(--border-light);
    border-radius: 16px;
    padding: 16px 14px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.04);
    box-sizing: border-box;
    width: 100%;
    max-width: 100%;
    position: relative;
    overflow: hidden;
  }

  .leaderboard-mobile-card.top-tier {
    background: linear-gradient(180deg, #fffdf8 0%, #ffffff 100%);
    border-color: #ebd29f;
    box-shadow: 0 4px 16px rgba(208, 155, 24, 0.1);
  }

  .card-top-row {
    display: grid;
    grid-template-columns: 32px 42px 1fr auto;
    align-items: center;
    gap: 10px;
    width: 100%;
    min-width: 0;
    box-sizing: border-box;
  }

  .card-rank-badge {
    width: 32px;
    text-align: center;
    font-size: 22px;
    line-height: 1;
  }

  .card-rank-num {
    font-family: var(--font-mono);
    font-size: 13px;
    font-weight: 800;
    color: var(--text-light);
    background: #f0eee6;
    padding: 3px 5px;
    border-radius: 6px;
    display: inline-block;
  }

  .card-avatar-wrap {
    width: 42px;
    height: 42px;
    flex-shrink: 0;
  }

  .card-avatar {
    width: 100%;
    height: 100%;
    object-fit: contain;
    background: #ece8dc;
    border-radius: 50%;
    padding: 2px;
    display: block;
    box-sizing: border-box;
  }

  .card-emoji-avatar {
    width: 100%;
    height: 100%;
    border-radius: 50%;
    background: #ece8dc;
    border: 2px solid var(--border-light);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 18px;
    line-height: 1;
    box-sizing: border-box;
  }

  .card-info-wrap {
    min-width: 0;
    display: flex;
    flex-direction: column;
    gap: 2px;
    overflow: hidden;
  }

  .card-title-line {
    display: flex;
    align-items: center;
    gap: 6px;
    min-width: 0;
    overflow: hidden;
  }

  .card-name {
    font-size: 14px;
    font-weight: 800;
    color: var(--text-main);
    line-height: 1.2;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
  }

  .card-party {
    font-size: 10px;
    padding: 1px 5px;
    border-radius: 4px;
    font-weight: 700;
    flex-shrink: 0;
  }

  .card-horse {
    font-size: 11px;
    color: var(--text-muted);
    line-height: 1.2;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
  }

  .card-score-wrap {
    flex-shrink: 0;
    display: flex;
    flex-direction: column;
    align-items: flex-end;
    justify-content: center;
    text-align: right;
  }

  .card-score-number {
    font-family: var(--font-mono);
    font-size: 20px;
    font-weight: 800;
    color: var(--text-main);
    line-height: 1;
  }

  .card-score-label {
    font-family: var(--font-mono);
    font-size: 10px;
    color: var(--text-light);
    text-transform: uppercase;
    letter-spacing: 0.04em;
    margin-top: 2px;
  }

  .card-progress-section {
    margin-top: 12px;
    padding-top: 8px;
    border-top: 1px dashed #ece8dc;
    width: 100%;
  }

  .card-progress-bar {
    height: 6px;
    background: #ebe7db;
    border-radius: 999px;
    overflow: hidden;
    margin-bottom: 4px;
    width: 100%;
  }

  .card-progress-fill {
    height: 100%;
    border-radius: 999px;
    transition: width 0.3s ease;
  }

  .card-progress-meta {
    font-family: var(--font-mono);
    font-size: 11px;
    display: flex;
    justify-content: space-between;
    color: var(--text-muted);
    font-weight: 600;
  }

  .card-action-section {
    margin-top: 12px;
    width: 100%;
  }

  .mobile-vote-btn {
    width: 100%;
    min-height: 46px;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    font-size: 14px;
    font-weight: 800;
    border-radius: 12px;
    cursor: pointer;
    box-sizing: border-box;
    transition: all 0.15s ease;
    text-align: center;
    text-decoration: none;
    padding: 0 16px;
  }

  .mobile-vote-btn.free-vote-btn {
    background: #15803d;
    color: #ffffff;
    border: none;
    box-shadow: 0 2px 6px rgba(21, 128, 61, 0.25);
  }

  .mobile-vote-btn.free-vote-btn:active {
    background: #166534;
    transform: scale(0.98);
  }

  .mobile-vote-btn.pix-trigger-btn {
    background: var(--candidate-theme, #0284c7);
    color: #ffffff;
    border: none;
    box-shadow: 0 2px 6px rgba(0, 0, 0, 0.15);
  }

  .mobile-vote-btn.pix-trigger-btn:active {
    filter: brightness(0.9);
    transform: scale(0.98);
  }

  .btn-subtext {
    font-size: 11px;
    font-weight: 600;
    opacity: 0.9;
  }
}

/* ==========================================================================
   MODAL SYSTEMS: CONSENT GATE, LEGAL READER, PIX & SHARE
   ========================================================================== */

@keyframes modal-fade-in {
  from {
    opacity: 0;
    transform: scale(0.96) translateY(8px);
  }
  to {
    opacity: 1;
    transform: scale(1) translateY(0);
  }
}

/* 1. MANDATORY CONSENT GATE */
.consent-gate-overlay {
  position: fixed;
  inset: 0;
  background: rgba(12, 20, 15, 0.45);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  z-index: 99990;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 16px;
  overflow-y: auto;
}

.consent-gate-card {
  background: #ffffff;
  border-radius: 20px;
  max-width: 520px;
  width: 100%;
  box-shadow: 
    0 24px 48px -12px rgba(0, 0, 0, 0.22),
    0 0 0 1px rgba(0, 0, 0, 0.06);
  padding: 26px 24px 20px;
  animation: modal-fade-in 0.22s ease-out;
  position: relative;
  text-align: left;
}

.consent-gate-header {
  margin-bottom: 14px;
}

.consent-gate-title {
  font-size: 20px;
  font-weight: 800;
  color: #111827;
  letter-spacing: -0.02em;
  line-height: 1.25;
  margin: 0;
}

.consent-intro {
  font-size: 13px;
  color: #4b5563;
  line-height: 1.45;
  margin: 6px 0 0;
}

.consent-cards-stack {
  display: flex;
  flex-direction: column;
  gap: 8px;
  margin-bottom: 12px;
}

.consent-gate-box {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  padding: 11px 14px;
  background: #fafafa;
  border: 1.5px solid #e5e7eb;
  border-radius: 12px;
  cursor: pointer;
  transition: border-color 0.15s ease, background 0.15s ease;
  user-select: none;
}

.consent-gate-box:hover {
  background: #ffffff;
  border-color: #15803d;
}

.consent-gate-box.is-selected {
  background: #f0fdf4;
  border-color: #86efac;
}

.consent-box-label {
  display: flex;
  align-items: center;
  cursor: pointer;
  margin-top: 1px;
  flex-shrink: 0;
}

.consent-native-chk {
  position: absolute;
  opacity: 0;
  width: 0;
  height: 0;
  pointer-events: none;
}

.custom-chk-box {
  width: 18px;
  height: 18px;
  border-radius: 5px;
  border: 1.5px solid #d1d5db;
  background: #ffffff;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.15s ease;
}

.consent-gate-box.is-selected .custom-chk-box {
  background: #15803d;
  border-color: #15803d;
}

.consent-gate-box.is-selected .custom-chk-box::after {
  content: '✓';
  color: #ffffff;
  font-size: 11px;
  font-weight: 800;
  line-height: 1;
}

.consent-box-content {
  flex: 1;
  min-width: 0;
}

.consent-box-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  margin-bottom: 2px;
}

.consent-box-title {
  font-size: 13px;
  font-weight: 700;
  color: #111827;
}

.inline-legal-link {
  font-size: 11px;
  font-weight: 600;
  color: #15803d;
  background: transparent;
  border: none;
  padding: 0;
  text-decoration: underline;
  cursor: pointer;
  transition: color 0.15s;
}

.inline-legal-link:hover {
  color: #0f4a24;
}

.consent-box-desc {
  font-size: 11.5px;
  color: #4b5563;
  line-height: 1.35;
  margin: 0;
}

.consent-box-desc code {
  background: #f3f4f6;
  padding: 1px 4px;
  border-radius: 3px;
  font-family: var(--font-mono);
  font-size: 11px;
}

.consent-master-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 10px 2px;
  margin-bottom: 14px;
  border-top: 1px solid #f3f4f6;
}

.consent-master-label {
  display: flex;
  align-items: center;
  gap: 8px;
  cursor: pointer;
  user-select: none;
  font-size: 12.5px;
  font-weight: 600;
  color: #374151;
}

.consent-master-label input {
  position: absolute;
  opacity: 0;
  width: 0;
  height: 0;
}

.custom-master-box {
  width: 16px;
  height: 16px;
  border-radius: 4px;
  border: 1.5px solid #d1d5db;
  background: #ffffff;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.15s ease;
}

.consent-master-label input:checked + .custom-master-box {
  background: #15803d;
  border-color: #15803d;
}

.consent-master-label input:checked + .custom-master-box::after {
  content: '✓';
  color: #ffffff;
  font-size: 10px;
  font-weight: 800;
  line-height: 1;
}

.master-text {
  font-size: 12.5px;
}

.consent-counter-pill {
  font-size: 11px;
  font-weight: 700;
  color: #15803d;
  background: #dcfce7;
  padding: 2px 8px;
  border-radius: 999px;
}

.consent-gate-footer {
  display: flex;
  flex-direction: column;
  align-items: center;
}

.btn-royal-accept {
  width: 100%;
  padding: 13px 20px;
  background: #143d23;
  color: #ffffff;
  border: none;
  border-radius: 12px;
  font-size: 14px;
  font-weight: 700;
  cursor: pointer;
  transition: background 0.15s ease, transform 0.1s ease;
  display: flex;
  align-items: center;
  justify-content: center;
}

.btn-royal-accept:hover {
  background: #1a522f;
  transform: translateY(-1px);
}

.btn-royal-accept:active {
  transform: translateY(0);
}

/* 2. LEGAL MODAL READER */
.legal-modal-overlay {
  position: fixed;
  inset: 0;
  background: rgba(12, 20, 15, 0.45);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  z-index: 100000;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 16px;
  overflow-y: auto;
}

.legal-modal-card {
  background: #ffffff;
  border-radius: 20px;
  max-width: 580px;
  width: 100%;
  max-height: 85vh;
  display: flex;
  flex-direction: column;
  box-shadow: 0 24px 48px -12px rgba(0, 0, 0, 0.25);
  animation: modal-fade-in 0.2s ease;
  overflow: hidden;
}

.legal-modal-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 18px 22px 14px;
  border-bottom: 1px solid #f3f4f6;
}

.legal-modal-header h3 {
  margin: 0;
  font-size: 17px;
  font-weight: 800;
  color: #111827;
}

.legal-close-btn {
  background: #f3f4f6;
  border: none;
  border-radius: 50%;
  width: 30px;
  height: 30px;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  color: #4b5563;
  font-weight: 700;
  font-size: 13px;
  transition: all 0.15s ease;
}

.legal-close-btn:hover {
  background: #e5e7eb;
  color: #111827;
}

.legal-tabs-bar {
  display: flex;
  background: #f9fafb;
  border-bottom: 1px solid #e5e7eb;
  padding: 4px 12px 0;
  gap: 4px;
  overflow-x: auto;
}

.legal-tab-btn {
  background: transparent;
  border: none;
  padding: 7px 12px;
  font-size: 12px;
  font-weight: 600;
  color: #6b7280;
  border-radius: 6px 6px 0 0;
  cursor: pointer;
  white-space: nowrap;
  transition: all 0.15s ease;
}

.legal-tab-btn:hover {
  color: #111827;
}

.legal-tab-btn.is-active {
  background: #ffffff;
  color: #15803d;
  font-weight: 700;
}

.legal-modal-body {
  padding: 20px 22px;
  overflow-y: auto;
  color: #374151;
  font-size: 13px;
  line-height: 1.55;
}

.legal-summary-callout {
  background: #f0fdf4;
  border: 1px solid #bbf7d0;
  border-radius: 10px;
  padding: 10px 14px;
  margin-bottom: 16px;
  color: #166534;
  font-size: 12.5px;
}

.legal-summary-callout p {
  margin: 0;
}

.legal-section {
  margin-bottom: 16px;
}

.legal-section:last-child {
  margin-bottom: 0;
}

.legal-section h4 {
  margin: 0 0 4px;
  font-size: 13.5px;
  font-weight: 700;
  color: #111827;
}

.legal-section p {
  margin: 0;
}

.legal-bullet-list {
  margin: 6px 0 0;
  padding-left: 18px;
}

.legal-bullet-list li {
  margin-bottom: 3px;
}

.legal-section code {
  background: #f3f4f6;
  padding: 1px 4px;
  border-radius: 3px;
  font-family: var(--font-mono);
  font-size: 11px;
}

.legal-modal-footer {
  padding: 12px 22px;
  border-top: 1px solid #f3f4f6;
  display: flex;
  justify-content: flex-end;
  background: #fafafa;
}

.legal-btn-agree {
  background: #111827;
  color: #ffffff;
  border: none;
  padding: 9px 18px;
  border-radius: 8px;
  font-weight: 600;
  font-size: 13px;
  cursor: pointer;
  transition: all 0.15s ease;
}

.legal-btn-agree:hover {
  background: #1f2937;
}

/* 3. PIX MODAL OVERLAY */
.pix-modal-overlay {
  position: fixed;
  inset: 0;
  background: rgba(12, 20, 15, 0.45);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  z-index: 99980;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 16px;
  overflow-y: auto;
}

.pix-modal-card {
  background: #ffffff;
  border-radius: 22px;
  max-width: 430px;
  width: 100%;
  box-shadow: 0 25px 60px -15px rgba(0, 0, 0, 0.3), 0 0 0 1px rgba(0, 0, 0, 0.06);
  padding: 26px 24px;
  animation: modal-fade-in 0.2s ease;
  position: relative;
  text-align: center;
}

.pix-modal-close {
  position: absolute;
  top: 16px;
  right: 16px;
  background: #f1f5f9;
  border: none;
  border-radius: 50%;
  width: 30px;
  height: 30px;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  color: #64748b;
  font-size: 13px;
  font-weight: 700;
  transition: all 0.15s ease;
}

.pix-modal-close:hover {
  background: #e2e8f0;
  color: #0f172a;
}

.pix-mp-badge {
  background: #e0f2fe;
  color: #0369a1;
  border: 1px solid #bae6fd;
  border-radius: 999px;
  font-weight: 700;
  font-size: 11px;
  padding: 3px 10px;
  font-family: var(--font-sans);
  display: inline-block;
  margin-bottom: 6px;
}

.pix-modal-title {
  margin: 0 0 4px;
  font-size: 20px;
  font-weight: 800;
  color: #0f172a;
  letter-spacing: -0.02em;
}

.pix-modal-sub {
  margin: 0 0 14px;
  font-size: 13px;
  color: #64748b;
  line-height: 1.4;
}

/* STRICT LEGAL DISCLAIMER BOX IN CHECKOUT */
.pix-legal-disclaimer-box {
  background: #fffbeb;
  border: 1px solid #fef3c7;
  border-radius: 12px;
  padding: 11px 14px;
  margin-bottom: 14px;
  text-align: left;
}

.disclaimer-header {
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: 11px;
  font-weight: 800;
  color: #92400e;
  margin-bottom: 4px;
  letter-spacing: -0.01em;
}

.disclaimer-icon {
  font-size: 13px;
}

.disclaimer-body p {
  margin: 0 0 4px;
  font-size: 11px;
  color: #b45309;
  line-height: 1.4;
}

.disclaimer-body p:last-child {
  margin-bottom: 0;
}

.disclaimer-body strong {
  color: #78350f;
}

/* PIX CHECKOUT STEPPER & PRICING */
.pix-checkout-form {
  display: flex;
  flex-direction: column;
  gap: 14px;
}

.pix-stepper-section {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
}

.pix-stepper-title {
  font-size: 11.5px;
  font-weight: 700;
  color: #64748b;
  text-transform: uppercase;
  letter-spacing: 0.04em;
}

.pix-stepper-wrapper {
  display: inline-flex;
  align-items: center;
  background: #f8fafc;
  border: 1px solid #e2e8f0;
  border-radius: 16px;
  padding: 5px;
  gap: 14px;
}

.btn-stepper {
  width: 42px;
  height: 42px;
  border-radius: 11px;
  border: 1px solid #e2e8f0;
  background: #ffffff;
  color: #0f172a;
  font-size: 22px;
  font-weight: 800;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.05);
  transition: all 0.15s ease;
  user-select: none;
}

.btn-stepper:hover:not(:disabled) {
  background: #ffffff;
  border-color: #cbd5e1;
  transform: translateY(-1px);
  box-shadow: 0 4px 8px rgba(0, 0, 0, 0.08);
}

.btn-stepper:active:not(:disabled) {
  transform: translateY(0);
}

.btn-stepper:disabled {
  opacity: 0.35;
  cursor: not-allowed;
  box-shadow: none;
  background: #f1f5f9;
}

.stepper-center-display {
  display: flex;
  flex-direction: column;
  align-items: center;
  min-width: 95px;
}

.stepper-count-num {
  font-size: 26px;
  font-weight: 900;
  color: #0f172a;
  font-family: var(--font-sans);
  font-variant-numeric: tabular-nums;
  font-feature-settings: "tnum" 1;
  line-height: 1;
}

.stepper-count-label {
  font-size: 11px;
  font-weight: 600;
  color: #64748b;
  margin-top: 2px;
}

/* PRESET PILLS */
.pix-presets-row {
  display: flex;
  gap: 6px;
  justify-content: center;
  flex-wrap: wrap;
  margin-top: 4px;
}

.preset-pill {
  background: #f8fafc;
  border: 1px solid #e2e8f0;
  border-radius: 999px;
  padding: 5px 12px;
  font-size: 11.5px;
  font-weight: 700;
  color: #475569;
  cursor: pointer;
  transition: all 0.15s ease;
  user-select: none;
}

.preset-pill:hover {
  background: #f1f5f9;
  border-color: #cbd5e1;
  transform: translateY(-1px);
}

.preset-pill.active {
  background: #0f172a;
  color: #ffffff;
  border-color: #0f172a;
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.15);
}

.preset-pill.preset-turbo {
  color: #dc2626;
  border-color: #fecaca;
  background: #fef2f2;
}

.preset-pill.preset-turbo:hover {
  background: #fee2e2;
}

.preset-pill.preset-turbo.active {
  background: #dc2626;
  color: #ffffff;
  border-color: #dc2626;
  box-shadow: 0 2px 8px rgba(220, 38, 38, 0.25);
}

/* PIX PRICING CARD & RED DISCOUNT */
.pix-pricing-card {
  background: #f8fafc;
  border: 1px solid #e2e8f0;
  border-radius: 14px;
  padding: 14px 16px;
  text-align: left;
}

.pricing-card-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.pricing-label {
  font-size: 13px;
  font-weight: 600;
  color: #64748b;
}

.pricing-subtotal-val {
  font-size: 13.5px;
  font-weight: 600;
  color: #475569;
  font-variant-numeric: tabular-nums;
  font-feature-settings: "tnum" 1;
}

.pricing-subtotal-val.has-strike {
  text-decoration: line-through;
  color: #94a3b8;
}

.discount-row {
  margin-top: 6px;
}

.discount-row-label {
  font-size: 12.5px;
  font-weight: 700;
  color: #dc2626;
  display: flex;
  align-items: center;
  gap: 4px;
}

.discount-badge-red {
  background: #fef2f2;
  color: #dc2626;
  border: 1px solid #fecaca;
  font-size: 11.5px;
  font-weight: 800;
  padding: 3px 9px;
  border-radius: 999px;
  letter-spacing: -0.01em;
  font-variant-numeric: tabular-nums;
  display: inline-flex;
  align-items: center;
}

.pricing-card-divider {
  height: 1px;
  background: #e2e8f0;
  margin: 10px 0 8px;
}

.total-row {
  align-items: baseline;
}

.total-row-label {
  font-size: 14px;
  font-weight: 800;
  color: #0f172a;
}

.final-price-text {
  font-size: 22px;
  font-weight: 900;
  color: #15803d;
  font-family: var(--font-sans);
  font-variant-numeric: tabular-nums;
  font-feature-settings: "tnum" 1;
  letter-spacing: -0.02em;
}

.turbo-discount-alert {
  margin-top: 10px;
  padding: 8px 12px;
  background: #fef2f2;
  border: 1px solid #fee2e2;
  border-radius: 10px;
  font-size: 12px;
  color: #991b1b;
  line-height: 1.35;
}

.turbo-discount-hint {
  margin-top: 10px;
  padding: 8px 12px;
  background: #eff6ff;
  border: 1px solid #dbeafe;
  border-radius: 10px;
  font-size: 12px;
  color: #1e40af;
  cursor: pointer;
  transition: all 0.15s ease;
  line-height: 1.35;
}

.turbo-discount-hint:hover {
  background: #dbeafe;
}

.pix-email-group {
  text-align: left;
}

.pix-email-group .pix-label {
  display: block;
  font-size: 12.5px;
  font-weight: 700;
  color: #334155;
  margin-bottom: 6px;
}

.pix-input-large {
  width: 100%;
  box-sizing: border-box;
  padding: 13px 16px;
  font-size: 15px;
  font-family: var(--font-sans);
  border-radius: 12px;
  border: 1.5px solid #cbd5e1;
  background: #ffffff;
  color: #0f172a;
  transition: all 0.15s ease;
}

.pix-input-large:focus {
  border-color: #2563eb;
  outline: none;
  box-shadow: 0 0 0 4px rgba(37, 99, 235, 0.12);
}

.pix-error-message {
  margin: 10px 0;
  padding: 10px 12px;
  border-radius: 10px;
  background: #fef2f2;
  border: 1px solid #fee2e2;
  color: #991b1b;
  font-size: 13px;
  line-height: 1.4;
  overflow-wrap: anywhere;
}

.btn-generate-pix {
  width: 100%;
  padding: 15px 22px;
  font-size: 15px;
  font-weight: 800;
  border-radius: 12px;
  border: none;
  cursor: pointer;
  color: #ffffff;
  background: var(--candidate-btn-color, #15803d);
  background-image: linear-gradient(180deg, rgba(255, 255, 255, 0.22) 0%, rgba(0, 0, 0, 0.14) 100%);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.38), 0 6px 20px rgba(0, 0, 0, 0.2);
  transition: all 0.18s cubic-bezier(0.16, 1, 0.3, 1);
  font-family: var(--font-sans);
  letter-spacing: -0.01em;
}

.btn-generate-pix:hover {
  transform: translateY(-1.5px);
  filter: brightness(1.08);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.5), 0 8px 26px rgba(0, 0, 0, 0.26);
}

.btn-generate-pix:active {
  transform: translateY(0);
  filter: brightness(0.96);
  box-shadow: inset 0 2px 4px rgba(0, 0, 0, 0.25);
}

.pix-loading-state {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 24px 0;
  gap: 12px;
  color: #4b5563;
  font-size: 13px;
  font-weight: 600;
}

.pix-spinner {
  width: 36px;
  height: 36px;
  border: 3.5px solid #e5e7eb;
  border-top-color: #15803d;
  border-radius: 50%;
  animation: spin 0.8s linear infinite;
}

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

/* CHECKOUT SUMMARY */
.pix-checkout-summary {
  background: #f9fafb;
  border: 1px solid #e5e7eb;
  border-radius: 10px;
  padding: 10px 14px;
  margin-bottom: 12px;
  text-align: left;
}

.summary-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 12px;
  color: #4b5563;
  margin-bottom: 4px;
}

.summary-row:last-child {
  margin-bottom: 0;
}

.summary-row strong {
  color: #111827;
}

.summary-row.highlight-total {
  border-top: 1px solid #e5e7eb;
  padding-top: 6px;
  margin-top: 6px;
  font-size: 13px;
}

.summary-row.highlight-total strong {
  color: #15803d;
  font-size: 14px;
  font-weight: 800;
}

.pix-qr-container {
  display: flex;
  flex-direction: column;
  align-items: center;
  margin-bottom: 12px;
}

.pix-qr-box {
  width: 140px;
  height: 140px;
  border-radius: 12px;
  border: 1.5px solid #e5e7eb;
  padding: 6px;
  background: #ffffff;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.05);
  display: flex;
  align-items: center;
  justify-content: center;
}

.pix-qr-svg {
  width: 100%;
  height: 100%;
}

.pix-qr-img {
  width: 140px;
  height: 140px;
  border-radius: 12px;
  border: 1.5px solid #e5e7eb;
  padding: 6px;
  background: #ffffff;
}

.qr-scan-hint {
  font-size: 11px;
  color: #6b7280;
  margin-top: 5px;
}

.pix-copia-cola-box {
  text-align: left;
  margin-bottom: 12px;
}

.pix-label {
  display: block;
  font-size: 11px;
  font-weight: 700;
  color: #4b5563;
  margin-bottom: 4px;
}

.pix-input-group {
  display: flex;
  gap: 6px;
}

.pix-input {
  flex: 1;
  padding: 8px 10px;
  border: 1px solid #d1d5db;
  border-radius: 8px;
  background: #f9fafb;
  font-family: var(--font-mono);
  font-size: 11px;
  color: #374151;
  outline: none;
}

.btn-copy-pix {
  background: #15803d;
  color: #ffffff;
  border: none;
  padding: 0 14px;
  border-radius: 8px;
  font-size: 12px;
  font-weight: 700;
  cursor: pointer;
  transition: background 0.15s ease, transform 0.1s ease;
  white-space: nowrap;
}

.btn-copy-pix:hover {
  background: #166534;
  transform: translateY(-1px);
}

.btn-copy-pix:active {
  transform: translateY(0);
}

.pix-status-indicator {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  font-size: 11px;
  color: #4b5563;
  margin-bottom: 12px;
}

.btn-cancel-modal {
  background: transparent;
  border: 1px solid #d1d5db;
  color: #6b7280;
  padding: 7px 16px;
  border-radius: 8px;
  font-size: 12px;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.15s;
}

.btn-cancel-modal:hover {
  background: #f3f4f6;
  color: #111827;
}

/* 4. SHARE MODAL OVERLAY */
.share-modal-overlay {
  position: fixed;
  inset: 0;
  background: rgba(12, 20, 15, 0.45);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  z-index: 99980;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 16px;
  overflow-y: auto;
}

.share-modal-card {
  background: #ffffff;
  border-radius: 20px;
  max-width: 420px;
  width: 100%;
  box-shadow: 0 24px 48px -12px rgba(0, 0, 0, 0.25);
  padding: 24px;
  animation: modal-fade-in 0.2s ease;
  position: relative;
  text-align: center;
}

.share-modal-close {
  position: absolute;
  top: 16px;
  right: 16px;
  background: #f3f4f6;
  border: none;
  border-radius: 50%;
  width: 28px;
  height: 28px;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  color: #4b5563;
  font-size: 13px;
  font-weight: 700;
  transition: all 0.15s;
}

.share-modal-close:hover {
  background: #e5e7eb;
}

@media (max-width: 650px) {
  .consent-gate-card {
    padding: 20px 16px 16px;
    border-radius: 16px;
  }

  .consent-gate-title {
    font-size: 18px;
  }

  .consent-gate-box {
    padding: 9px 12px;
  }

  .consent-box-title {
    font-size: 12px;
  }

  .consent-box-desc {
    font-size: 10.5px;
  }

  .btn-royal-accept {
    padding: 12px 16px;
    font-size: 13.5px;
  }
}
