/* Marcos Fortuna · Sorteo de Navidad — negro y dorado */
:root {
  --bg: #050505;
  --bg2: #0b0b0c;
  --card: #111112;
  --card2: #161617;
  --line: #242426;
  --line2: #333336;
  --text: #f5f4f0;
  --muted: #a8a8ad;
  --dim: #7a7a80;
  --gold: #d8b25a;
  --gold-hi: #f2d993;
  --gold-lo: #9c7329;
  --gold-ink: #1d1505;
  --red: #a3322b;
  --pend: #e0a43a;
  --wa: #25d366;
  --r: 16px;
  --ease: cubic-bezier(.2, .8, .2, 1);
  --safe-b: env(safe-area-inset-bottom, 0px);
  --serif: Cinzel, "Trajan Pro", Georgia, serif;
  --sans: Manrope, system-ui, -apple-system, sans-serif;
}
* { box-sizing: border-box; -webkit-tap-highlight-color: transparent; }
[hidden] { display: none !important; }
html { scroll-behavior: smooth; scroll-padding-top: 76px; }
body {
  margin: 0; min-height: 100dvh;
  background:
    radial-gradient(90% 50% at 50% -10%, rgba(216, 178, 90, .07) 0%, transparent 60%),
    var(--bg);
  color: var(--text);
  font: 15px/1.55 var(--sans);
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}
body.lock { overflow: hidden; }
h1, h2, h3 { margin: 0; font-family: var(--serif); font-weight: 700; letter-spacing: .02em; }
button { font: inherit; color: inherit; }
.muted { color: var(--muted); }
.small { font-size: 12.5px; text-align: center; margin: 10px 0 0; }
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.skip { position: fixed; left: 12px; top: -60px; z-index: 100; padding: 10px 14px; border-radius: 10px; background: var(--gold); color: var(--gold-ink); font-weight: 700; text-decoration: none; }
.skip:focus { top: 12px; }
:focus-visible { outline: 2px solid var(--gold-hi); outline-offset: 3px; }
main { position: relative; z-index: 1; max-width: 1180px; margin: 0 auto; padding: 0 16px 120px; }

/* Nieve dorada */
#snow { position: fixed; inset: 0; z-index: 0; pointer-events: none; width: 100%; height: 100%; }

/* Barra superior */
.topbar {
  position: sticky; top: 0; z-index: 30;
  display: flex; align-items: center; justify-content: space-between; gap: 12px;
  padding: 10px 16px;
  background: rgba(5, 5, 5, .8);
  backdrop-filter: blur(14px) saturate(140%); -webkit-backdrop-filter: blur(14px) saturate(140%);
  border-bottom: 1px solid #1c1c1e;
}
.brand { display: flex; align-items: center; gap: 10px; color: var(--text); text-decoration: none; min-height: 44px; }
.brand img { width: 36px; height: 36px; border-radius: 50%; border: 1px solid var(--line2); }
.brand-name { font-family: var(--serif); font-size: 15px; letter-spacing: .08em; text-transform: uppercase; }
.brand-name b { color: var(--gold); font-weight: 700; }
.ig { display: inline-flex; align-items: center; gap: 6px; min-height: 44px; padding: 0 4px; color: var(--muted); text-decoration: none; font-size: 13px; transition: color .2s; }
.ig svg { width: 18px; height: 18px; }
.ig:hover { color: var(--gold-hi); }
@media (max-width: 420px) { #igHandle { display: none; } }

/* Hero */
.hero { position: relative; padding: 104px 0 40px; text-align: center; }
@media (min-width: 768px) { .hero { padding-top: 120px; } }
.hero-in { position: relative; z-index: 1; max-width: 640px; margin: 0 auto; }
.eyebrow {
  display: inline-flex; margin: 0 0 22px; padding: 7px 14px; border-radius: 999px;
  border: 1px solid var(--line2); background: rgba(17, 17, 18, .75);
  color: var(--gold-hi); font-size: 12.5px; letter-spacing: .04em;
}
.logo-type { display: flex; flex-direction: column; align-items: center; line-height: .92; margin-bottom: 26px; }
.lt-1, .lt-2 {
  font-family: var(--serif); font-weight: 800; text-transform: uppercase;
  font-size: clamp(44px, 13.5vw, 92px); letter-spacing: .02em;
  /* Metálico dorado igual al logo */
  background: linear-gradient(176deg, #fff0bf 0%, #f0d58c 28%, #c9a046 55%, #8f6824 72%, #e8c877 100%);
  background-size: 100% 100%;
  -webkit-background-clip: text; background-clip: text; color: transparent;
}
.lt-3 {
  display: flex; align-items: center; gap: 10px; margin-top: 10px;
  font-family: var(--serif); font-size: clamp(10px, 2.6vw, 13px); letter-spacing: .32em; text-transform: uppercase; color: var(--gold);
}
.lt-3 i { width: 34px; height: 1px; background: linear-gradient(90deg, transparent, var(--gold)); }
.lt-3 i:last-child { transform: scaleX(-1); }

.prize-block { display: flex; flex-direction: column; align-items: center; font-weight: 400; }
.prize-label { font-family: var(--sans); font-size: 13px; letter-spacing: .18em; text-transform: uppercase; color: var(--muted); }
.prize {
  position: relative; z-index: 1; display: inline-block; margin: 6px 0 0; padding: 0 .06em;
  font-family: var(--serif); font-weight: 800; line-height: 1;
  font-size: clamp(88px, 27vw, 176px);
  /* Oro pulido con un reflejo que recorre las letras y un brillo que respira */
  background: linear-gradient(100deg, #b8862f 0%, #f7e3a3 18%, #fffbe8 26%, #f0cf74 36%, #a8782a 55%, #f3d68b 75%, #fff4cf 84%, #c9993f 100%);
  background-size: 260% 100%;
  -webkit-background-clip: text; background-clip: text; color: transparent;
  filter: drop-shadow(0 3px 0 #4a3209) drop-shadow(0 0 18px rgba(255, 205, 96, .45));
  animation: shine 5s linear infinite, glow 3.2s ease-in-out infinite;
}
@keyframes shine { from { background-position: 0 0; } to { background-position: -260% 0; } }
@keyframes glow {
  50% { filter: drop-shadow(0 3px 0 #4a3209) drop-shadow(0 0 34px rgba(255, 214, 110, .75)); }
}

/* Caja de regalo de donde sale el premio */
.gift-stage {
  --gw: clamp(150px, 42vw, 210px); --gh: calc(var(--gw) * .55);
  position: relative; display: flex; flex-direction: column; align-items: center; cursor: pointer;
}
.prize-window { position: relative; z-index: 1; display: block; overflow: hidden; padding: 34px 44px 0; margin: -34px -44px 0; }
.anim .prize { transform: translateY(115%); }
.anim .gift { opacity: 0; }
.gift-rays {
  position: absolute; z-index: 0; left: 50%; bottom: calc(var(--gh) * .7); width: 380px; height: 320px; margin-left: -190px; opacity: 0; pointer-events: none;
  background: repeating-conic-gradient(from -90deg at 50% 100%, rgba(255, 214, 120, .32) 0 5deg, transparent 5deg 14deg);
  -webkit-mask: radial-gradient(circle at 50% 100%, #000 18%, transparent 68%); mask: radial-gradient(circle at 50% 100%, #000 18%, transparent 68%);
  transform-origin: 50% 100%;
}
.gift { position: relative; z-index: 2; display: block; width: var(--gw); height: var(--gh); margin-top: calc(var(--gh) * -.3); }
.gift-box {
  position: absolute; left: 7%; right: 7%; top: 30%; bottom: 0; border-radius: 6px;
  background:
    linear-gradient(90deg, transparent 44%, #e3bf66 44%, #f6df9c 50%, #c99a3f 56%, transparent 56%),
    linear-gradient(180deg, #1d1d20, #0c0c0d);
  border: 1px solid #3a3a3e;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, .06), 0 20px 34px rgba(0, 0, 0, .65);
}
.gift-lid {
  position: absolute; left: 0; right: 0; top: 12%; height: 22%; border-radius: 6px; transform-origin: 88% 100%;
  background:
    linear-gradient(90deg, transparent 43%, #e3bf66 43%, #fbe7ad 50%, #c99a3f 57%, transparent 57%),
    linear-gradient(180deg, #26262a, #121214);
  border: 1px solid #44444a;
  box-shadow: 0 6px 12px rgba(0, 0, 0, .5);
}
.bow { position: absolute; left: 50%; bottom: 100%; width: 0; height: 0; }
.bow::before, .bow::after {
  content: ""; position: absolute; bottom: -4px; width: 30px; height: 20px; border-radius: 50% 50% 40% 40%;
  border: 5px solid #e9c873; background: transparent;
}
.bow::before { right: -2px; transform: rotate(28deg); transform-origin: 100% 100%; }
.bow::after { left: -2px; transform: rotate(-28deg); transform-origin: 0 100%; }
.sparks { position: absolute; left: 50%; top: 30%; width: 0; height: 0; z-index: 3; pointer-events: none; }
.sparks i { position: absolute; width: 6px; height: 6px; margin: -3px; border-radius: 50%; background: #ffe7a3; opacity: 0; }

/* Luces de Navidad colgando de la barra */
.lights { position: absolute; left: 0; right: 0; top: 100%; height: 44px; pointer-events: none; overflow: hidden; }
.lights svg { position: absolute; inset: 0; width: 100%; height: 100%; overflow: visible; }
.bulb {
  position: absolute; width: 9px; height: 14px; margin-left: -4.5px; border-radius: 50% 50% 50% 50% / 40% 40% 60% 60%;
  background: var(--c); transform-origin: 50% 0; transform: rotate(var(--r, 0deg));
  box-shadow: 0 0 10px 2px var(--c), 0 0 22px 4px color-mix(in srgb, var(--c) 45%, transparent);
  animation: twinkle 2.4s ease-in-out infinite; animation-delay: var(--d, 0s);
}
.bulb::before { content: ""; position: absolute; left: 1.5px; top: -4px; width: 6px; height: 5px; border-radius: 1px; background: #3b3b3f; }
@keyframes twinkle {
  0%, 100% { opacity: 1; filter: brightness(1.1); }
  50% { opacity: .35; filter: brightness(.6); box-shadow: 0 0 3px 0 var(--c); }
}

/* Gorro de Navidad sobre el logo */
.logo-wrap { position: relative; display: inline-block; flex: none; line-height: 0; }
.logo-wrap .hat { position: absolute; width: 30px; left: -7px; top: -15px; transform: rotate(-20deg); filter: drop-shadow(0 2px 2px rgba(0, 0, 0, .5)); }
.logo-wrap.big .hat { width: 58px; left: -14px; top: -28px; }

/* Top compradores */
.top { margin-top: 80px; max-width: 680px; }
.top h2 { font-size: clamp(26px, 6vw, 38px); margin-bottom: 18px; }
.top-list { list-style: none; margin: 0; padding: 0; display: grid; gap: 8px; }
.top-row {
  display: grid; grid-template-columns: 44px 1fr auto; align-items: center; gap: 12px;
  padding: 12px 14px; border-radius: 16px; background: var(--card); border: 1px solid var(--line);
}
.top-row.first { border-color: rgba(216, 178, 90, .55); background: linear-gradient(180deg, #19181a, var(--card)); }
.rank {
  display: grid; place-items: center; width: 40px; height: 40px; border-radius: 50%;
  font-family: var(--serif); font-weight: 800; font-size: 16px; color: var(--muted); border: 1px solid var(--line2);
}
.r1 .rank { color: #1d1505; border: 0; background: linear-gradient(160deg, #fff0bf, var(--gold) 55%, var(--gold-lo)); }
.r2 .rank { color: #17171a; border: 0; background: linear-gradient(160deg, #ffffff, #c9c9cf 55%, #8d8d94); }
.r3 .rank { color: #1c0f05; border: 0; background: linear-gradient(160deg, #f6c79a, #c47f43 55%, #7f4b22); }
.top-name { min-width: 0; }
.top-name b { display: block; font-size: 16px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.top-bar { display: block; height: 4px; margin-top: 6px; border-radius: 9px; background: var(--line); overflow: hidden; }
.top-bar i { display: block; height: 100%; border-radius: inherit; background: linear-gradient(90deg, var(--gold-lo), var(--gold-hi)); }
.top-count { text-align: right; font-variant-numeric: tabular-nums; }
.top-count b { display: block; font-family: var(--serif); font-size: 22px; color: var(--gold-hi); line-height: 1; }
.top-count span { font-size: 11.5px; color: var(--muted); }
.top-empty { padding: 26px 18px; border-radius: 16px; border: 1px dashed var(--line2); text-align: center; color: var(--muted); }
.top-empty p { margin: 0; }
.prize-sub { margin-top: 6px; font-family: var(--sans); font-size: 15px; color: var(--muted); }

.hero-facts { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; margin: 28px auto 0; max-width: 460px; }
.fact { padding: 12px 14px; border-radius: 14px; background: var(--card); border: 1px solid var(--line); text-align: left; }
.fact > span { display: block; font-size: 12px; letter-spacing: .08em; text-transform: uppercase; color: var(--muted); }
.fact b { font-size: 18px; font-variant-numeric: tabular-nums; color: var(--text); }
.fact:first-child b { color: var(--gold-hi); }

.progress { max-width: 460px; margin: 12px auto 0; text-align: left; }
.bar { height: 8px; border-radius: 99px; background: var(--card2); border: 1px solid var(--line); overflow: hidden; }
.bar-fill {
  height: 100%; width: 0; border-radius: inherit;
  background: linear-gradient(90deg, var(--gold-lo), var(--gold), var(--gold-hi));
  transition: width 1.2s var(--ease);
}
.progress-foot { display: flex; justify-content: space-between; gap: 10px; flex-wrap: wrap; margin-top: 8px; font-size: 12.5px; color: var(--muted); }
.progress-foot b { color: var(--text); }

.countdown { max-width: 460px; margin: 18px auto 0; }
.countdown p { margin: 0 0 8px; font-size: 12px; letter-spacing: .16em; text-transform: uppercase; color: var(--muted); }
.cd-row { display: grid; grid-template-columns: repeat(4, 1fr); gap: 8px; }
.cd-row div { padding: 10px 4px; border-radius: 12px; background: var(--card); border: 1px solid var(--line); }
.cd-row b { display: block; font-family: var(--serif); font-size: 26px; color: var(--gold-hi); font-variant-numeric: tabular-nums; }
.cd-row span { font-size: 11px; color: var(--muted); text-transform: uppercase; letter-spacing: .1em; }

.hero-cta { display: grid; gap: 10px; max-width: 460px; margin: 22px auto 0; }
@media (min-width: 520px) { .hero-cta { grid-template-columns: 1fr 1fr; } }

/* Adornos colgantes */
.ornaments { position: absolute; inset: 28px -16px auto; height: 260px; pointer-events: none; overflow: hidden; }
.orn { position: absolute; top: 0; width: 1px; background: linear-gradient(var(--gold-lo), var(--gold)); transform-origin: top center; animation: sway 6s ease-in-out infinite; }
.orn i {
  position: absolute; left: 50%; bottom: -26px; width: 26px; height: 26px; margin-left: -13px; border-radius: 50%;
  background: radial-gradient(circle at 34% 30%, #fff3c8 0 8%, var(--gold) 30%, var(--gold-lo) 72%, #4d3610 100%);
  box-shadow: inset -3px -4px 8px rgba(0, 0, 0, .35);
}
.orn i::before { content: ""; position: absolute; left: 50%; top: -5px; width: 8px; height: 6px; margin-left: -4px; border-radius: 2px; background: var(--gold-lo); }
.o1 { left: 8%; height: 70px; animation-duration: 6.5s; }
.o2 { left: 22%; height: 128px; animation-delay: -2s; }
.o2 i { width: 20px; height: 20px; margin-left: -10px; bottom: -20px; background: radial-gradient(circle at 34% 30%, #ffd6cf 0 8%, #c7473d 32%, var(--red) 60%, #4a120f 100%); }
.o3 { right: 9%; height: 96px; animation-delay: -3.4s; animation-duration: 7s; }
.o4 { right: 23%; height: 54px; animation-delay: -1s; }
.o4 i { width: 18px; height: 18px; margin-left: -9px; bottom: -18px; }
.o5 { left: 50%; height: 30px; display: none; }
.star i {
  width: 30px; height: 30px; margin-left: -15px; bottom: -28px; border-radius: 0; box-shadow: none;
  clip-path: polygon(50% 0, 61% 35%, 98% 35%, 68% 57%, 79% 91%, 50% 70%, 21% 91%, 32% 57%, 2% 35%, 39% 35%);
  background: linear-gradient(160deg, #fff0bf, var(--gold) 50%, var(--gold-lo));
}
.star i::before { display: none; }
@keyframes sway { 0%, 100% { transform: rotate(3deg); } 50% { transform: rotate(-3deg); } }
@media (max-width: 520px) { .o2 { left: 4%; height: 150px; } .o4 { right: 4%; height: 160px; } .o1 { left: 15%; height: 40px; } .o3 { right: 14%; height: 52px; } }

/* Botones */
.btn {
  position: relative; display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  min-height: 52px; padding: 0 22px; border-radius: 14px; border: 0;
  font: 700 15px/1 var(--sans); letter-spacing: .01em; text-decoration: none; cursor: pointer;
  transition: transform .16s var(--ease), background-color .2s, border-color .2s, color .2s, box-shadow .2s;
  touch-action: manipulation; user-select: none; -webkit-user-select: none;
}
.btn:active { transform: scale(.97); }
.btn:disabled { opacity: .55; cursor: wait; }
.btn-gold {
  color: var(--gold-ink);
  background: linear-gradient(180deg, #f6dd98 0%, var(--gold) 52%, #b98c3c 100%);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, .45), 0 6px 18px rgba(0, 0, 0, .45);
}
.btn-line { color: var(--gold-hi); background: rgba(17, 17, 18, .85); border: 1px solid var(--line2); }
.btn-wa { background: var(--wa); color: #05290f; }
.btn-block { width: 100%; }
.btn-text { margin-top: 6px; min-height: 44px; width: 100%; background: none; border: 0; color: var(--muted); font-size: 13px; cursor: pointer; text-decoration: underline; text-underline-offset: 3px; }
@media (hover: hover) {
  .btn-gold:hover { transform: translateY(-2px); box-shadow: inset 0 1px 0 rgba(255, 255, 255, .5), 0 10px 24px rgba(0, 0, 0, .5); }
  .btn-line:hover { border-color: var(--gold); transform: translateY(-2px); }
  .btn-gold:active, .btn-line:active { transform: scale(.97); }
  .btn-text:hover { color: var(--gold-hi); }
}
.dice { display: inline-block; transition: transform .5s var(--ease); }
@media (hover: hover) { .btn-line:hover .dice { transform: rotate(180deg); } }

/* Pasos */
.steps ol { list-style: none; margin: 24px 0 64px; padding: 0; display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; }
.steps li { padding: 16px 10px; border-radius: 16px; background: var(--card); border: 1px solid var(--line); text-align: center; }
.step-n { display: block; font-family: var(--serif); font-size: 14px; color: var(--gold); letter-spacing: .1em; }
.steps b { display: block; margin-top: 4px; font-family: var(--serif); font-size: 16px; }
.steps p { margin: 4px 0 0; font-size: 12.5px; line-height: 1.4; color: var(--muted); }
@media (min-width: 760px) { .steps li { padding: 22px 18px; } .steps p { font-size: 14px; } }

/* Números */
.kicker { margin: 0 0 6px; font-size: 12px; letter-spacing: .2em; text-transform: uppercase; color: var(--gold); }
.section-head { margin-bottom: 16px; }
.section-head h2, .lookup h2 { font-size: clamp(26px, 6vw, 38px); }
.legend { display: flex; flex-wrap: wrap; gap: 14px; margin-top: 12px; font-size: 12.5px; color: var(--muted); }
.legend span { display: inline-flex; align-items: center; gap: 6px; }
.lg { width: 14px; height: 10px; border-radius: 3px; display: inline-block; }
.lg-free { background: var(--card2); border: 1px solid var(--line2); }
.lg-sel { background: linear-gradient(180deg, var(--gold-hi), var(--gold)); }
.lg-pend { border: 1px dashed var(--pend); }
.lg-sold { background: #0e0e0f; border: 1px solid #2a2a2c; }

.numbers { display: grid; gap: 28px; align-items: start; }
.numbers > * { min-width: 0; }
@media (min-width: 1024px) { .numbers { grid-template-columns: minmax(0, 1fr) 320px; gap: 36px; } }

.tools { display: flex; gap: 8px; margin-bottom: 12px; }
.search {
  flex: 1; display: flex; align-items: center; gap: 8px; padding: 0 14px; height: 48px; min-width: 0;
  background: var(--bg2); border: 1px solid var(--line); border-radius: 12px; color: var(--muted);
  transition: border-color .2s;
}
.search:focus-within { border-color: var(--gold); }
.search svg { width: 18px; height: 18px; flex: none; }
.search input { flex: 1; min-width: 0; height: 100%; background: none; border: 0; outline: 0; color: var(--text); font: 500 16px var(--sans); }
.toggle {
  display: inline-flex; align-items: center; gap: 10px; padding: 0 14px; height: 48px;
  background: var(--bg2); border: 1px solid var(--line); border-radius: 12px; font-size: 13.5px; white-space: nowrap; cursor: pointer;
}
.toggle input { position: absolute; opacity: 0; width: 1px; height: 1px; }
.switch { position: relative; width: 34px; height: 20px; border-radius: 99px; background: var(--line2); transition: background .2s; }
.switch::after { content: ""; position: absolute; top: 3px; left: 3px; width: 14px; height: 14px; border-radius: 50%; background: var(--text); transition: transform .25s var(--ease); }
.toggle input:checked + .switch { background: var(--gold); }
.toggle input:checked + .switch::after { transform: translateX(14px); background: var(--gold-ink); }
.toggle input:focus-visible + .switch { outline: 2px solid var(--gold-hi); outline-offset: 2px; }

.ranges {
  display: flex; gap: 6px; overflow-x: auto; margin: 0 -16px 10px; padding: 2px 16px 8px;
  scrollbar-width: none; scroll-snap-type: x proximity; scroll-padding-inline: 16px;
}
.ranges::-webkit-scrollbar { display: none; }
@media (min-width: 1024px) { .ranges { flex-wrap: wrap; margin: 0 0 10px; padding: 2px 0 8px; } }
.range {
  flex: none; scroll-snap-align: start; min-height: 46px; padding: 7px 12px; border-radius: 12px;
  background: var(--bg2); border: 1px solid var(--line); color: var(--muted);
  font: 600 13px var(--sans); cursor: pointer; text-align: center; line-height: 1.2; font-variant-numeric: tabular-nums;
  transition: border-color .2s, color .2s, background-color .2s;
}
.range small { display: block; font-weight: 500; font-size: 10.5px; color: var(--dim); }
.range.active { background: var(--gold); color: var(--gold-ink); border-color: var(--gold); }
.range.active small { color: #4d3a14; }
@media (hover: hover) { .range:not(.active):hover { border-color: var(--line2); color: var(--text); } }

/* Boletos */
.grid { display: grid; grid-template-columns: repeat(5, 1fr); gap: 8px; }
@media (min-width: 430px) { .grid { grid-template-columns: repeat(6, 1fr); } }
@media (min-width: 640px) { .grid { grid-template-columns: repeat(10, 1fr); } }
.num {
  --notch: radial-gradient(circle 5px at 0 50%, #0000 96%, #000) left / 51% 100% no-repeat,
           radial-gradient(circle 5px at 100% 50%, #0000 96%, #000) right / 51% 100% no-repeat;
  position: relative; aspect-ratio: 1.25; min-height: 46px; display: grid; place-items: center; padding: 0;
  border-radius: 10px; border: 1px solid var(--line2); background: var(--card2); color: var(--text);
  font: 700 16px var(--sans); font-variant-numeric: tabular-nums; letter-spacing: .02em; cursor: pointer;
  -webkit-mask: var(--notch); mask: var(--notch);
  transition: transform .16s var(--ease), background-color .2s, border-color .2s, color .2s;
  touch-action: manipulation;
}
.num::after { content: ""; position: absolute; left: 12%; right: 12%; bottom: 22%; border-top: 1px dashed rgba(216, 178, 90, .18); }
@media (hover: hover) { .num:not(.sold):not(.pend):hover { border-color: var(--gold); color: var(--gold-hi); transform: translateY(-2px); } }
.num:active { transform: scale(.93); }
.num.sel {
  color: var(--gold-ink); border-color: var(--gold-hi);
  background: linear-gradient(170deg, #fbe7ad 0%, var(--gold) 55%, #b4883a 100%);
}
.num.sel::after { border-color: rgba(29, 21, 5, .3); }
.num.pend, .num.sold { cursor: not-allowed; }
.num.pend { background: transparent; border: 1px dashed rgba(224, 164, 58, .6); color: rgba(240, 210, 150, .7); font-size: 14px; }
.num.sold { background: #0d0d0e; border-color: #1f1f21; color: #5c5c62; font-size: 14px; }
.num.sold::after { border: 0; left: 18%; right: 18%; top: 50%; bottom: auto; height: 1px; background: #7a2a25; transform: rotate(-14deg); }
.num.pend::after, .num.sold:hover::after { border-color: transparent; }
.num.flash { animation: flash .8s ease 2; }
@keyframes flash { 50% { border-color: var(--gold-hi); transform: scale(1.08); } }
.grid-empty { text-align: center; color: var(--muted); padding: 30px 0; }

/* Resumen lateral (computadora) */
.side-cart { display: none; }
@media (min-width: 1024px) {
  .side-cart {
    display: block; position: sticky; top: 88px;
    padding: 22px; border-radius: 20px; background: var(--card); border: 1px solid var(--line);
  }
  .cart, .cart[hidden] { display: none !important; }
}
.side-empty { text-align: center; padding: 18px 0 8px; color: var(--muted); }
.side-empty p { margin: 12px 0 0; font-size: 14px; }
.side-ticket { width: 88px; height: 56px; margin: 0 auto; display: grid; place-items: center; border-radius: 10px; border: 1px dashed var(--line2); color: var(--gold); font-size: 22px; }
.side-chips { display: flex; flex-wrap: wrap; gap: 6px; max-height: 220px; overflow: auto; margin: 6px 0 14px; }
.side-total { display: flex; justify-content: space-between; align-items: baseline; padding: 14px 0; border-top: 1px solid var(--line); margin-bottom: 12px; color: var(--muted); font-size: 14px; }
.side-total strong { font-family: var(--serif); font-size: 24px; color: var(--gold-hi); }

.chip {
  flex: none; display: inline-flex; align-items: center; gap: 4px; min-height: 30px; padding: 4px 10px; border-radius: 8px;
  background: transparent; color: var(--gold-hi); border: 1px solid rgba(216, 178, 90, .45);
  font: 700 13px var(--sans); font-variant-numeric: tabular-nums; cursor: pointer;
}
button.chip:hover { border-color: var(--gold); }

/* Consultar */
.lookup { margin-top: 56px; padding: 26px 20px; border-radius: 22px; background: var(--card); border: 1px solid var(--line); max-width: 680px; }
.lookup > .muted { margin: 6px 0 16px; }
.lookup-form { display: flex; gap: 8px; }
.lookup-form input { flex: 1; min-width: 0; }
.order-chip { margin-top: 12px; padding: 14px; border-radius: 14px; background: var(--bg2); border: 1px solid var(--line); font-size: 14px; }
.order-chip .st { font-weight: 700; }
.st-approved { color: #7fd49c; }
.st-pending { color: var(--pend); }

input {
  width: 100%; height: 52px; padding: 0 14px; border-radius: 12px;
  background: var(--bg2); border: 1px solid var(--line2); color: var(--text);
  font: 500 16px var(--sans); outline: 0; transition: border-color .2s;
}
input:focus { border-color: var(--gold); }
input::placeholder { color: var(--dim); }

/* Pie */
.footer { display: flex; flex-direction: column; align-items: center; gap: 6px; padding: 72px 0 12px; text-align: center; }
.footer img { width: 72px; height: 72px; border-radius: 50%; border: 1px solid var(--line2); }
.slogan { margin: 10px 0 0; font-family: var(--serif); font-size: clamp(18px, 4.6vw, 24px); color: var(--gold-hi); }
.footer .muted { margin: 0 0 12px; font-size: 13.5px; }
.fine { margin: 18px 0 0; font-size: 12px; color: var(--dim); }

/* Barra de selección (teléfono) */
.cart {
  position: fixed; left: 10px; right: 10px; bottom: calc(10px + var(--safe-b)); z-index: 35;
  max-width: 640px; margin: 0 auto;
  display: flex; align-items: center; gap: 10px; padding: 10px 10px 10px 14px;
  background: rgba(17, 17, 18, .94); backdrop-filter: blur(16px); -webkit-backdrop-filter: blur(16px);
  border: 1px solid var(--line2); border-radius: 18px; box-shadow: 0 16px 40px rgba(0, 0, 0, .6);
}
.cart-info { flex: 1; min-width: 0; }
.cart-chips { display: flex; gap: 4px; overflow-x: auto; scrollbar-width: none; }
.cart-chips::-webkit-scrollbar { display: none; }
.cart-total { font-size: 13px; color: var(--muted); margin-top: 4px; white-space: nowrap; }
.cart-total strong { color: var(--gold-hi); }
.cart .btn { min-height: 48px; padding: 0 20px; }

/* Máquina de la suerte */
.slot-backdrop, .sheet-backdrop { position: fixed; inset: 0; z-index: 40; background: rgba(0, 0, 0, .72); backdrop-filter: blur(3px); -webkit-backdrop-filter: blur(3px); }
.slot {
  position: fixed; left: 50%; top: 50%; z-index: 50; width: min(92vw, 400px); transform: translate(-50%, -50%);
  padding: 26px 20px 20px; border-radius: 24px; text-align: center;
  background: linear-gradient(180deg, #19191b, #0e0e0f); border: 1px solid var(--line2);
  box-shadow: 0 30px 80px rgba(0, 0, 0, .7);
}
.slot h3 { font-size: 22px; margin-bottom: 18px; }
.reels { display: grid; grid-template-columns: repeat(3, 1fr); gap: 10px; margin-bottom: 18px; }
.reel {
  position: relative; height: 104px; overflow: hidden; border-radius: 14px;
  background: linear-gradient(180deg, #000, #141415 50%, #000); border: 1px solid var(--gold-lo);
}
.reel::before, .reel::after { content: ""; position: absolute; left: 0; right: 0; height: 30px; z-index: 1; pointer-events: none; }
.reel::before { top: 0; background: linear-gradient(#000, transparent); }
.reel::after { bottom: 0; background: linear-gradient(transparent, #000); }
.reel-strip { will-change: transform; }
.reel-strip span { display: grid; place-items: center; height: 104px; font-family: var(--serif); font-weight: 800; font-size: 60px; color: var(--gold-hi); }
.slot-actions { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }

/* Hoja de pago */
.sheet {
  position: fixed; left: 0; right: 0; bottom: 0; z-index: 50;
  max-width: 560px; margin: 0 auto; max-height: 92dvh; overflow-y: auto; overscroll-behavior: contain;
  padding: 0 18px calc(22px + var(--safe-b));
  background: var(--bg2); border: 1px solid var(--line2); border-bottom: 0; border-radius: 24px 24px 0 0;
  box-shadow: 0 -20px 60px rgba(0, 0, 0, .6);
}
.sheet-grab { position: sticky; top: 0; z-index: 2; margin: 0 -18px; padding: 12px 0 14px; background: var(--bg2); cursor: grab; touch-action: none; }
.sheet-handle { width: 44px; height: 5px; border-radius: 9px; background: var(--line2); margin: 0 auto; }
@media (min-width: 600px) {
  .sheet { bottom: 50%; transform: translateY(50%); border-radius: 24px; border-bottom: 1px solid var(--line2); }
  .sheet-grab { cursor: default; }
  .sheet-handle { display: none; }
}
.sheet-close {
  position: absolute; top: 10px; right: 12px; z-index: 3; width: 44px; height: 44px; border-radius: 50%;
  background: var(--card); border: 1px solid var(--line); color: var(--muted); font-size: 14px; cursor: pointer;
}
.sheet h3 { font-size: 22px; margin-bottom: 14px; padding-right: 48px; }
.summary { padding: 14px; border-radius: 14px; background: var(--card); border: 1px solid var(--line); }
.summary-nums { display: flex; flex-wrap: wrap; gap: 6px; }
.summary-nums .chip { cursor: default; font-size: 14px; }
.summary-total { display: flex; justify-content: space-between; align-items: baseline; margin-top: 12px; color: var(--muted); font-size: 14px; }
.summary-total strong { font-family: var(--serif); color: var(--gold-hi); font-size: 24px; }
.label { margin: 18px 0 8px; font-size: 12px; font-weight: 700; text-transform: uppercase; letter-spacing: .1em; color: var(--muted); }
.paybox { border-radius: 14px; border: 1px solid var(--line); overflow: hidden; margin-bottom: 10px; }
.payrow { display: grid; grid-template-columns: 74px 1fr auto; align-items: center; gap: 8px; padding: 8px 8px 8px 14px; background: var(--card); }
.payrow + .payrow { border-top: 1px solid var(--line); }
.payrow span { color: var(--muted); font-size: 13px; }
.payrow b { font-size: 15px; font-variant-numeric: tabular-nums; overflow-wrap: anywhere; }
.copy {
  min-width: 80px; height: 44px; padding: 0 12px; border-radius: 10px; border: 1px solid var(--line2);
  background: var(--bg2); color: var(--gold-hi); font: 700 13px var(--sans); cursor: pointer; transition: color .2s, border-color .2s;
}
.copy.ok { color: #7fd49c; border-color: #3f8a5a; }
.order-form { display: grid; gap: 10px; }
.order-form .label { margin-bottom: -2px; }
.row2 { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.form-error { margin: 0; padding: 10px 12px; border-radius: 10px; background: rgba(163, 50, 43, .18); color: #f3b1a9; font-size: 13.5px; }
.upload {
  position: relative; display: flex; align-items: center; gap: 12px; min-height: 64px; padding: 10px 14px;
  border: 1.5px dashed var(--line2); border-radius: 12px; background: var(--card); cursor: pointer; transition: border-color .2s;
}
.upload:hover, .upload.has { border-color: var(--gold); }
.upload input { position: absolute; inset: 0; opacity: 0; cursor: pointer; height: 100%; }
.upload img { width: 52px; height: 52px; object-fit: cover; border-radius: 8px; flex: none; }
.upload-text b { display: block; font-size: 14.5px; color: var(--gold-hi); }
.upload-text small { display: block; color: var(--muted); font-size: 12.5px; }

#stepDone { text-align: center; padding-bottom: 6px; }
#stepDone h3 { padding-right: 0; }
#stepDone .summary-nums { justify-content: center; margin: 10px 0 14px; }
#stepDone .btn { margin-top: 10px; }
.done-icon {
  width: 72px; height: 72px; margin: 6px auto 12px; display: grid; place-items: center; border-radius: 50%;
  border: 1px solid var(--gold); color: var(--gold-hi); font-size: 32px;
}

/* WhatsApp flotante */
.wa-fab {
  position: fixed; right: 14px; bottom: calc(16px + var(--safe-b)); z-index: 25;
  display: inline-flex; align-items: center; gap: 8px; height: 52px; padding: 0 18px 0 14px;
  border-radius: 999px; background: var(--wa); color: #05290f; text-decoration: none;
  font: 700 14px var(--sans); box-shadow: 0 10px 26px rgba(0, 0, 0, .5);
  transition: bottom .25s var(--ease), transform .16s var(--ease);
}
.wa-fab svg { width: 26px; height: 26px; }
.wa-fab:active { transform: scale(.95); }
@media (hover: hover) { .wa-fab:hover { transform: translateY(-2px); } }
body.has-cart .wa-fab { bottom: calc(96px + var(--safe-b)); padding: 0; width: 52px; justify-content: center; }
body.has-cart .wa-fab span { display: none; }
@media (min-width: 1024px) { body.has-cart .wa-fab { bottom: calc(16px + var(--safe-b)); padding: 0 18px 0 14px; width: auto; } body.has-cart .wa-fab span { display: inline; } }

/* Toast */
.toast {
  position: fixed; left: 50%; top: 72px; z-index: 60; transform: translate(-50%, -16px);
  padding: 10px 16px; border-radius: 12px; background: var(--text); color: var(--bg);
  font-weight: 600; font-size: 14px; opacity: 0; pointer-events: none; transition: opacity .25s, transform .25s var(--ease);
  max-width: calc(100% - 32px); text-align: center;
}
.toast.show { opacity: 1; transform: translate(-50%, 0); }

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation: none !important; transition: none !important; }
  html { scroll-behavior: auto; }
  #snow { display: none; }
}
