/* ==========================================================================
   GoRifa — sitio público (landing, páginas de rifa, ganador)
   ========================================================================== */

body.site { background: var(--bg); overflow-x: hidden; }
section { position: relative; }

/* ---------- Navbar ---------- */
.nav {
  position: sticky; top: 0; z-index: 100;
  background: var(--glass);
  backdrop-filter: saturate(180%) blur(20px); -webkit-backdrop-filter: saturate(180%) blur(20px);
  border-bottom: 1px solid transparent;
  transition: border-color .3s, background .3s;
}
.nav.scrolled { border-bottom-color: var(--line); background: var(--glass); }
.nav-inner { height: 60px; display: grid; grid-template-columns: 1fr auto 1fr; align-items: center; gap: 16px; }
.nav-links { display: flex; gap: 4px; }
.nav-links a { font-size: 13.5px; color: var(--ink-2); padding: 7px 13px; border-radius: 99px; transition: color .2s, background .2s; }
.nav-links a:hover { color: var(--ink); background: var(--fill); }
.nav-actions { display: flex; justify-content: flex-end; align-items: center; gap: 6px; }
.nav-toggle { display: none; width: 40px; height: 40px; border-radius: 12px; place-items: center; justify-self: end; }
.nav-toggle:hover { background: var(--fill); }
.nav-mobile { display: none; }

@media (max-width: 860px) {
  .nav-inner { grid-template-columns: 1fr auto; }
  .nav-links, .nav-actions { display: none; }
  .nav-toggle { display: grid; }
  .nav-mobile {
    display: block; overflow: hidden; max-height: 0; transition: max-height .5s var(--ease-out);
    background: var(--glass-strong);
  }
  .nav.open .nav-mobile { max-height: 520px; border-bottom: 1px solid var(--line); }
  .nav-mobile .container { padding-top: 8px; padding-bottom: 24px; }
  .nav-mobile a.m-link { display: block; font-size: 22px; font-weight: 600; letter-spacing: -.02em; padding: 12px 0; border-bottom: 1px solid var(--line); opacity: 0; transform: translateY(-6px); transition: opacity .4s, transform .4s var(--ease-out); }
  .nav.open .nav-mobile a.m-link { opacity: 1; transform: none; }
  .nav.open .nav-mobile a.m-link:nth-child(2) { transition-delay: .04s; }
  .nav.open .nav-mobile a.m-link:nth-child(3) { transition-delay: .08s; }
  .nav.open .nav-mobile a.m-link:nth-child(4) { transition-delay: .12s; }
  .nav-mobile .m-actions { display: grid; gap: 10px; margin-top: 20px; }
}

/* ---------- Hero ---------- */
.hero { padding: 88px 0 0; text-align: center; overflow: hidden; }
.hero::before {
  content: ""; position: absolute; inset: -20% -10% auto; height: 900px; z-index: -1; pointer-events: none;
  background:
    radial-gradient(600px 300px at 50% 12%, color-mix(in srgb, var(--accent) 9%, transparent), transparent 70%),
    radial-gradient(500px 260px at 20% 40%, rgba(255, 186, 120, .10), transparent 70%),
    radial-gradient(500px 260px at 80% 40%, rgba(175, 140, 255, .10), transparent 70%);
}
.pill-link {
  display: inline-flex; align-items: center; gap: 8px; height: 34px; padding: 0 8px 0 14px; border-radius: 99px;
  background: var(--bg-elev); border: 1px solid var(--line); box-shadow: var(--shadow-sm);
  font-size: 13px; color: var(--ink-2); transition: border-color .2s, box-shadow .2s;
}
.pill-link:hover { border-color: var(--line-2); box-shadow: var(--shadow); }
.pill-link b { font-weight: 600; color: var(--accent); }
.pill-link .arrow { width: 22px; height: 22px; border-radius: 50%; background: var(--fill); display: grid; place-items: center; }
.hero h1 { margin: 26px auto 22px; max-width: 980px; }
.hero h1 .soft { color: #a1a1a6; background: linear-gradient(180deg, #86868b, #b8b8bd); -webkit-background-clip: text; background-clip: text; -webkit-text-fill-color: transparent; }
.hero .lead { max-width: 620px; margin: 0 auto; }
:root[data-theme="dark"] .hero .display .soft { background: linear-gradient(180deg, #8e8e93, #5a5a5f); -webkit-background-clip: text; background-clip: text; }
.hero-cta { display: flex; gap: 12px; justify-content: center; align-items: center; margin-top: 34px; flex-wrap: wrap; }
.hero-note { margin-top: 16px; font-size: 13px; color: var(--muted-2); }
.hero-visual { margin-top: 72px; perspective: 2000px; padding-bottom: 40px; }
.hero-stage { position: relative; max-width: 1080px; margin: 0 auto; }

/* Ventana de la app (mockup) */
.mock-window {
  position: relative; border-radius: 18px; background: var(--bg-elev); overflow: hidden; text-align: left;
  box-shadow: 0 0 0 1px var(--line), 0 30px 80px -20px rgba(0, 0, 0, .18), 0 60px 120px -40px rgba(0, 0, 0, .14);
  transform-origin: 50% 0; will-change: transform;
}
.mock-bar { height: 40px; display: flex; align-items: center; gap: 8px; padding: 0 16px; background: var(--surface-2); border-bottom: 1px solid var(--line); }
.mock-bar i { width: 11px; height: 11px; border-radius: 50%; background: #e0e0e4; }
.mock-bar i:nth-child(1) { background: #ff5f57; } .mock-bar i:nth-child(2) { background: #febc2e; } .mock-bar i:nth-child(3) { background: #28c840; }
.mock-url { margin: 0 auto; height: 24px; padding: 0 14px; border-radius: 7px; background: var(--bg-elev); border: 1px solid var(--line); font-size: 11.5px; color: var(--muted); display: flex; align-items: center; gap: 6px; }
.mock-app { display: grid; grid-template-columns: 196px minmax(0, 1fr); min-height: 520px; font-size: 12px; }
.mock-side { border-right: 1px solid var(--line); background: var(--sidebar-solid); padding: 18px 12px; }
.mock-side .logo { font-size: 15px; margin: 0 6px 18px; }
.mock-side .logo-mark { width: 22px; height: 22px; border-radius: 6px; }
.mock-side .logo-mark svg { width: 12px; height: 12px; }
.mock-nav { display: flex; flex-direction: column; gap: 2px; }
.mock-nav span { display: flex; align-items: center; gap: 9px; padding: 7px 9px; border-radius: 8px; color: var(--ink-2); font-size: 12.5px; }
.mock-nav span .icon { width: 15px; height: 15px; color: var(--muted); }
.mock-nav span.on { background: var(--fill-2); color: var(--ink); font-weight: 600; }
.mock-nav span.on .icon { color: var(--ink); }
.mock-main { padding: 26px 28px; background: var(--bg-elev); }
.mock-greet { font-size: 22px; font-weight: 650; letter-spacing: -.03em; }
.mock-sub { color: var(--muted); font-size: 12.5px; margin-top: 3px; }
.mock-stats { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 12px; margin-top: 20px; }
.mock-stat { border: 1px solid var(--line); border-radius: 14px; padding: 14px; }
.mock-stat small { display: block; color: var(--muted); font-size: 11px; }
.mock-stat strong { display: block; font-size: clamp(14px, 1.5vw, 19px); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; font-weight: 650; letter-spacing: -.03em; margin-top: 6px; font-variant-numeric: tabular-nums; }
.mock-stat em { font-style: normal; font-size: 10.5px; color: var(--green); font-weight: 600; }
.mock-row { display: grid; grid-template-columns: minmax(0, 1.55fr) minmax(0, 1fr); gap: 12px; margin-top: 12px; }
.mock-card { border: 1px solid var(--line); border-radius: 14px; padding: 16px; }
.mock-card h5 { font-size: 12.5px; font-weight: 600; margin: 0 0 10px; display: flex; justify-content: space-between; }
.mock-card h5 span { color: var(--muted-2); font-weight: 500; }
.mock-chart { width: 100%; height: 150px; }
.mock-chart .area { fill: url(#gArea); }
.mock-chart .line { fill: none; stroke: var(--ink); stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; stroke-dasharray: 1200; stroke-dashoffset: 1200; }
.in .mock-chart .line, .mock-chart.in .line { animation: draw 2.2s var(--ease-out) .3s forwards; }
@keyframes draw { to { stroke-dashoffset: 0; } }
.mock-rifa { display: flex; align-items: center; gap: 10px; padding: 8px 0; border-bottom: 1px solid var(--line); }
.mock-rifa:last-child { border-bottom: 0; }
.mock-thumb { width: 32px; height: 32px; border-radius: 9px; background: var(--bg-soft); display: grid; place-items: center; font-size: 15px; flex-shrink: 0; }
.mock-rifa .grow b { display: block; font-size: 12px; font-weight: 600; }
.mock-rifa .progress { height: 4px; margin-top: 5px; }
.mock-rifa .pct { font-size: 11px; font-weight: 600; color: var(--muted); font-variant-numeric: tabular-nums; }

/* Tarjetas flotantes alrededor del mock */
.float-card {
  position: absolute; z-index: 3; display: flex; align-items: center; gap: 12px; padding: 12px 16px 12px 12px;
  border-radius: 18px; background: var(--glass-strong); text-align: left;
  backdrop-filter: blur(20px) saturate(180%); -webkit-backdrop-filter: blur(20px) saturate(180%);
  box-shadow: 0 0 0 1px var(--line), 0 18px 40px -8px rgba(0, 0, 0, .16);
  animation: float 6s ease-in-out infinite;
}
.float-card .fi { width: 38px; height: 38px; border-radius: 11px; display: grid; place-items: center; background: var(--ink); color: var(--on-ink); flex-shrink: 0; }
.float-card small { display: block; font-size: 11.5px; color: var(--muted); }
.float-card strong { font-size: 14px; font-weight: 600; letter-spacing: -.01em; }
.float-a { left: -48px; top: 38%; }
.float-b { right: -40px; top: 16%; animation-delay: -3s; }
.float-b .fi { background: linear-gradient(135deg, #f5d77a, #e0a82e); color: #5a3d00; }
@keyframes float { 50% { transform: translateY(-10px); } }

@media (max-width: 1180px) { .float-a { left: 8px; top: auto; bottom: -8px; } .float-b { right: 8px; top: -24px; } }
@media (max-width: 860px) {
  .hero { padding-top: 56px; }
  .hero-visual { margin-top: 52px; }
  .mock-app { grid-template-columns: minmax(0, 1fr); min-height: 0; }
  .mock-side { display: none; }
  .mock-main { padding: 18px; }
  .mock-stats { grid-template-columns: repeat(2, 1fr); }
  .mock-row { grid-template-columns: minmax(0, 1fr); }
  .float-card { display: none; }
}

/* ---------- Secciones ---------- */
.section { padding: 140px 0; }
.section-sm { padding: 96px 0; }
.section-head { text-align: center; max-width: 760px; margin: 0 auto 64px; }
.section-head .eyebrow { display: block; margin-bottom: 14px; }
.section-head p.lead { margin-top: 18px; }
.bg-soft { background: var(--bg-soft); }
@media (max-width: 860px) { .section { padding: 96px 0; } .section-head { margin-bottom: 44px; } }

/* Features */
.features { display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; }
.feature {
  padding: 30px; border-radius: 24px; background: var(--bg-elev); border: 1px solid var(--line);
  transition: transform .5s var(--ease-out), box-shadow .5s var(--ease-out), border-color .3s;
}
.feature:hover { transform: translateY(-4px); box-shadow: var(--shadow-lg); border-color: transparent; }
.feature-icon {
  width: 48px; height: 48px; border-radius: 14px; display: grid; place-items: center; margin-bottom: 22px;
  background: var(--bg-soft); color: var(--ink);
}
.feature h3 { font-size: 19px; margin-bottom: 8px; }
.feature p { color: var(--muted); font-size: 15px; line-height: 1.55; }
@media (max-width: 860px) { .features { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 560px) { .features { grid-template-columns: minmax(0, 1fr); } .feature { padding: 24px; } }

/* Flujo de la rifa */
.flow { position: relative; display: grid; grid-template-columns: repeat(6, 1fr); gap: 12px; }
.flow::before, .flow-line {
  content: ""; position: absolute; top: 31px; left: 8%; right: 8%; height: 2px; background: var(--line);
}
.flow-line { background: var(--ink); transform: scaleX(0); transform-origin: left; transition: transform 2.4s var(--ease-out) .2s; }
.flow.in .flow-line { transform: scaleX(1); }
.flow-step { position: relative; text-align: center; }
.flow-dot {
  width: 64px; height: 64px; border-radius: 20px; margin: 0 auto 18px; display: grid; place-items: center;
  background: var(--bg-elev); border: 1px solid var(--line-2); color: var(--ink); position: relative; z-index: 1;
  transition: background .5s var(--ease), color .5s var(--ease), border-color .5s, transform .6s var(--spring);
}
.flow.in .flow-step .flow-dot { background: var(--ink); color: var(--on-ink); border-color: var(--ink); transform: scale(1.02); transition-delay: calc(var(--i) * .35s + .2s); }
.flow-step small { display: block; font-size: 12px; color: var(--muted-2); font-weight: 600; margin-bottom: 4px; }
.flow-step h4 { font-size: 16px; margin-bottom: 6px; }
.flow-step p { font-size: 13.5px; color: var(--muted); line-height: 1.45; padding: 0 4px; }
@media (max-width: 960px) {
  .flow { grid-template-columns: minmax(0, 1fr); gap: 0; max-width: 420px; margin: 0 auto; }
  .flow::before, .flow-line { left: 31px; right: auto; top: 32px; bottom: 32px; width: 2px; height: auto; }
  .flow-line { transform: scaleY(0); transform-origin: top; }
  .flow.in .flow-line { transform: scaleY(1); }
  .flow-step { display: grid; grid-template-columns: 64px 1fr; gap: 18px; text-align: left; padding-bottom: 28px; }
  .flow-dot { margin: 0; }
  .flow-step p { padding: 0; }
  .flow-step > div { padding-top: 10px; }
}

/* Split (texto + visual) */
.split { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 80px; align-items: center; }
.split h2 { font-size: clamp(32px, 4.4vw, 52px); letter-spacing: -.038em; line-height: 1.06; margin: 14px 0 20px; }
.checks { list-style: none; padding: 0; margin: 28px 0 32px; display: grid; gap: 14px; }
.checks li { display: flex; gap: 12px; align-items: flex-start; font-size: 15.5px; color: var(--ink-2); }
.checks li .ck { width: 22px; height: 22px; border-radius: 50%; background: var(--ink); color: var(--on-ink); display: grid; place-items: center; flex-shrink: 0; margin-top: 1px; }
.checks li .ck svg { width: 12px; height: 12px; stroke-width: 3; }
@media (max-width: 960px) { .split { grid-template-columns: minmax(0, 1fr); gap: 56px; } }

/* Teléfono */
.phone {
  position: relative; width: 320px; max-width: 100%; margin: 0 auto; aspect-ratio: 320 / 650;
  border-radius: 52px; padding: 12px; background: #1d1d1f;
  box-shadow: 0 0 0 2px #3a3a3c, 0 50px 100px -20px rgba(0, 0, 0, .35), inset 0 0 0 1px rgba(255, 255, 255, .06);
}
.phone::before { content: ""; position: absolute; top: 24px; left: 50%; transform: translateX(-50%); width: 96px; height: 28px; border-radius: 20px; background: #000; z-index: 3; }
.phone-screen { width: 100%; height: 100%; border-radius: 41px; background: var(--bg-elev); overflow: hidden; display: flex; flex-direction: column; }
.ps-top { padding: 58px 20px 0; text-align: center; }
.ps-top small { font-size: 10.5px; font-weight: 700; letter-spacing: .14em; color: var(--muted-2); }
.ps-top h4 { font-size: 22px; letter-spacing: -.03em; margin: 4px 0 2px; }
.ps-top p { font-size: 12.5px; color: var(--muted); }
.ps-img { margin: 16px 20px 0; height: 118px; border-radius: 20px; background: var(--placeholder); display: grid; place-items: center; position: relative; overflow: hidden; }
.ps-img .ph { width: 58px; height: 100px; border-radius: 14px; background: linear-gradient(145deg, #45464b, #1d1d1f); box-shadow: 0 10px 24px rgba(0, 0, 0, .25), inset 0 0 0 2px #5a5b60; transform: rotate(-8deg); }
.ps-img .ph + .ph { position: absolute; transform: translateX(30px) rotate(8deg); background: linear-gradient(145deg, #d8d4cc, #b9b4aa); box-shadow: 0 10px 24px rgba(0, 0, 0, .18), inset 0 0 0 2px #cfcac1; }
.ps-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; padding: 18px 20px 0; }
.ps-grid .num-cell { height: 42px; font-size: 14px; cursor: pointer; }
.ps-foot { margin-top: auto; padding: 14px 20px 26px; }
.ps-total { display: flex; justify-content: space-between; align-items: baseline; font-size: 12.5px; color: var(--muted); margin-bottom: 10px; }
.ps-total strong { font-size: 18px; color: var(--ink); letter-spacing: -.02em; font-variant-numeric: tabular-nums; transition: transform .3s var(--spring); display: inline-block; }
.ps-total strong.bump { transform: scale(1.12); }

/* Sorteos (sección oscura) */
.dark { background: var(--dark-section); color: #f5f5f7; }
.dark .lead, .dark .muted { color: #a1a1a6; }
.dark .eyebrow { color: #bf9cff; }
.draw-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 20px; }
.draw-card { border-radius: 28px; background: #1c1c1e; padding: 40px; overflow: hidden; position: relative; }
.draw-card h3 { font-size: 26px; letter-spacing: -.03em; margin: 18px 0 10px; color: #fff; }
.draw-card p { color: #a1a1a6; font-size: 15.5px; line-height: 1.55; }
.draw-tag { display: inline-flex; align-items: center; gap: 8px; font-size: 12px; font-weight: 600; color: #d1d1d6; padding: 6px 12px; border-radius: 99px; background: rgba(255, 255, 255, .08); }
.draw-ui { margin-top: 32px; border-radius: 20px; background: #2c2c2e; padding: 22px; }
.draw-ui .r { display: flex; justify-content: space-between; align-items: center; padding: 10px 0; border-bottom: 1px solid rgba(255, 255, 255, .08); font-size: 13.5px; color: #a1a1a6; }
.draw-ui .r:last-child { border-bottom: 0; }
.draw-ui .r b { color: #f5f5f7; font-weight: 600; }
.digits { display: flex; gap: 6px; }
.digits span { width: 30px; height: 38px; border-radius: 9px; background: #3a3a3c; color: #fff; display: grid; place-items: center; font-weight: 700; font-size: 17px; font-variant-numeric: tabular-nums; }
.digits span.hl { background: #fff; color: #000; }
.draw-note { margin-top: 18px; font-size: 12.5px !important; color: #86868b !important; display: flex; gap: 8px; }
.draw-note .icon { flex-shrink: 0; margin-top: 2px; }

.reels { display: flex; justify-content: center; gap: 10px; margin: 36px 0 8px; }
.reel { width: 76px; height: 100px; border-radius: 18px; background: #2c2c2e; overflow: hidden; position: relative; box-shadow: inset 0 0 0 1px rgba(255, 255, 255, .06); }
.reel::before, .reel::after { content: ""; position: absolute; left: 0; right: 0; height: 26px; z-index: 1; pointer-events: none; }
.reel::before { top: 0; background: linear-gradient(#2c2c2e, transparent); }
.reel::after { bottom: 0; background: linear-gradient(transparent, #2c2c2e); }
.reel-strip { display: flex; flex-direction: column; transition: transform 2.6s cubic-bezier(.12, .8, .2, 1); }
.reel-strip span { height: 100px; display: grid; place-items: center; font-size: 52px; font-weight: 700; color: #fff; font-variant-numeric: tabular-nums; letter-spacing: -.03em; }
.reel-caption { text-align: center; font-size: 13px; color: #86868b; }
.reel-caption b { color: #f5d77a; font-weight: 600; }
@media (max-width: 860px) { .draw-grid { grid-template-columns: minmax(0, 1fr); } .draw-card { padding: 28px; } .reel { width: 64px; height: 88px; } .reel-strip span { height: 88px; font-size: 44px; } }

/* Dashboard bento */
.bento { display: grid; grid-template-columns: repeat(12, 1fr); gap: 16px; }
.bento > * { border-radius: 24px; background: var(--bg-elev); border: 1px solid var(--line); padding: 26px; }
.b-greet { grid-column: span 5; display: flex; flex-direction: column; justify-content: space-between; min-height: 240px; }
.b-greet .hello { font-size: 30px; font-weight: 650; letter-spacing: -.035em; line-height: 1.1; }
.b-kpis { grid-column: span 7; display: grid; grid-template-columns: 1fr 1fr 1fr; gap: 0; padding: 0; overflow: hidden; }
.b-kpi { padding: 26px; border-right: 1px solid var(--line); display: flex; flex-direction: column; justify-content: space-between; }
.b-kpi:last-child { border-right: 0; }
.b-kpi small { font-size: 13px; color: var(--muted); }
.b-kpi strong { font-size: clamp(26px, 3vw, 36px); font-weight: 650; letter-spacing: -.04em; font-variant-numeric: tabular-nums; margin-top: 40px; display: block; }
.b-kpi em { font-style: normal; font-size: 12.5px; color: var(--green); font-weight: 600; }
.b-chart { grid-column: span 8; }
.b-list { grid-column: span 4; }
.b-head { display: flex; justify-content: space-between; align-items: baseline; margin-bottom: 18px; }
.b-head h4 { font-size: 16px; }
.b-head span { font-size: 12.5px; color: var(--muted-2); }
.bars { display: flex; align-items: flex-end; gap: 8px; height: 190px; }
.bars span { flex: 1; border-radius: 8px 8px 4px 4px; background: var(--track); transform-origin: bottom; transform: scaleY(0); transition: transform 1.1s var(--ease-out); transition-delay: calc(var(--i) * 45ms); position: relative; }
.bars span.hi { background: var(--ink); }
.in .bars span { transform: scaleY(1); }
.bars-x { display: flex; gap: 8px; margin-top: 10px; }
.bars-x span { flex: 1; text-align: center; font-size: 11px; color: var(--muted-2); }
@media (max-width: 960px) {
  .b-greet, .b-kpis, .b-chart, .b-list { grid-column: span 12; }
  .b-greet { min-height: 0; gap: 20px; }
}
@media (max-width: 560px) {
  .b-kpis { grid-template-columns: minmax(0, 1fr); }
  .b-kpi { border-right: 0; border-bottom: 1px solid var(--line); display: grid; grid-template-columns: minmax(0, 1fr) auto; align-items: center; column-gap: 12px; }
  .b-kpi small { grid-column: 1; grid-row: 1; }
  .b-kpi em { grid-column: 1; grid-row: 2; }
  .b-kpi strong { grid-column: 2; grid-row: 1 / span 2; }
  .b-kpi:last-child { border-bottom: 0; }
  .b-kpi strong { margin-top: 0; font-size: 24px; }
  .bento > * { padding: 20px; }
  .b-kpi { padding: 18px 20px; }
}

/* Planes */
.plans { display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; align-items: stretch; max-width: 1080px; margin: 0 auto; }
.plan { position: relative; border-radius: 28px; padding: 34px; background: var(--bg-elev); border: 1px solid var(--line); display: flex; flex-direction: column; transition: transform .5s var(--ease-out), box-shadow .5s var(--ease-out); }
.plan:hover { transform: translateY(-4px); box-shadow: var(--shadow-lg); }
.plan.featured { background: var(--ink); color: var(--on-ink); border-color: var(--ink); }
.plan.featured .plan-flag { background: color-mix(in srgb, var(--on-ink) 14%, transparent); color: var(--on-ink); }
.plan.featured .muted, .plan.featured .plan-desc { color: color-mix(in srgb, var(--on-ink) 62%, var(--ink)); }
.plan-flag { position: absolute; top: 22px; right: 22px; font-size: 11.5px; font-weight: 600; padding: 5px 11px; border-radius: 99px; background: rgba(255, 255, 255, .14); color: #fff; }
.plan-name { font-size: 13px; font-weight: 700; letter-spacing: .12em; text-transform: uppercase; }
.plan-desc { margin-top: 8px; color: var(--muted); font-size: 15px; }
.plan-price { margin: 30px 0 4px; font-size: 44px; font-weight: 700; letter-spacing: -.045em; line-height: 1; font-variant-numeric: tabular-nums; }
.plan-price small { font-size: 15px; font-weight: 500; letter-spacing: -.01em; color: var(--muted); }
.plan.featured .plan-price small { color: color-mix(in srgb, var(--on-ink) 62%, var(--ink)); }
.plan-price.soon { font-size: 26px; letter-spacing: -.03em; }
.plan ul { list-style: none; padding: 0; margin: 28px 0 32px; display: grid; gap: 13px; font-size: 14.5px; }
.plan li { display: flex; gap: 10px; align-items: flex-start; }
.plan li .icon { margin-top: 2px; color: var(--green); }
.plan.featured li .icon { color: #30d158; }
.plan .btn { margin-top: auto; }
.plan.featured .btn-primary { background: var(--on-ink); color: var(--ink); }
.plan.featured .btn-primary:hover { background: color-mix(in srgb, var(--on-ink) 88%, var(--ink)); }
@media (max-width: 960px) { .plans { grid-template-columns: minmax(0, 1fr); max-width: 460px; } }

/* FAQ */
.faq-wrap { display: grid; grid-template-columns: 1fr 1.6fr; gap: 80px; }
.faq details { border-bottom: 1px solid var(--line); }
.faq summary {
  list-style: none; cursor: pointer; display: flex; justify-content: space-between; align-items: center; gap: 16px;
  padding: 24px 0; font-size: 18px; font-weight: 550; letter-spacing: -.02em;
}
.faq summary::-webkit-details-marker { display: none; }
.faq summary .pm { width: 28px; height: 28px; border-radius: 50%; background: var(--fill); display: grid; place-items: center; flex-shrink: 0; transition: transform .4s var(--spring), background .2s; }
.faq details[open] summary .pm { transform: rotate(45deg); background: var(--ink); color: var(--on-ink); }
.faq .answer { overflow: hidden; }
.faq .answer p { padding: 0 48px 24px 0; color: var(--muted); font-size: 16px; line-height: 1.6; }
@media (max-width: 860px) { .faq-wrap { grid-template-columns: minmax(0, 1fr); gap: 24px; } .faq summary { font-size: 16.5px; padding: 20px 0; } .faq .answer p { padding-right: 0; } }

/* CTA final */
.cta-final { text-align: center; padding: 150px 0; }
.cta-final h2 { font-size: clamp(38px, 6.4vw, 76px); letter-spacing: -.045em; line-height: 1.02; font-weight: 700; }
.cta-final p { margin: 22px auto 36px; max-width: 520px; }

/* Footer */
.footer { background: var(--bg-soft); padding: 72px 0 36px; font-size: 13.5px; color: var(--muted); }
.footer-grid { display: grid; grid-template-columns: 1.6fr 1fr 1fr 1fr; gap: 40px; }
.footer h5 { font-size: 12.5px; font-weight: 600; color: var(--ink); margin-bottom: 14px; letter-spacing: 0; }
.footer ul { list-style: none; padding: 0; margin: 0; display: grid; gap: 10px; }
.footer a { transition: color .2s; }
.footer a:hover { color: var(--ink); }
.footer-desc { margin-top: 14px; max-width: 300px; line-height: 1.6; }
.footer-bottom { margin-top: 56px; padding-top: 24px; border-top: 1px solid var(--line); display: flex; justify-content: space-between; align-items: center; gap: 16px; flex-wrap: wrap; }
.socials { display: flex; gap: 8px; }
.socials a { width: 36px; height: 36px; border-radius: 50%; display: grid; place-items: center; background: var(--bg-elev); border: 1px solid var(--line); color: var(--ink-2); transition: background .2s, color .2s; }
.socials a:hover { background: var(--ink); color: var(--on-ink); border-color: var(--ink); }
@media (max-width: 860px) { .footer-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); } .footer-grid > :first-child { grid-column: span 2; } }

/* ==========================================================================
   Página pública de rifa
   ========================================================================== */
.rp { background: var(--bg); padding-bottom: 120px; }
.rp-top { position: sticky; top: 0; z-index: 50; background: var(--glass); backdrop-filter: saturate(180%) blur(20px); -webkit-backdrop-filter: saturate(180%) blur(20px); border-bottom: 1px solid var(--line); }
.rp-top .container { height: 60px; display: flex; align-items: center; justify-content: space-between; gap: 12px; }
.brand-chip { display: flex; align-items: center; gap: 10px; min-width: 0; }
.brand-chip .bl { width: 34px; height: 34px; border-radius: 10px; background: var(--accent); color: #fff; display: grid; place-items: center; font-weight: 700; font-size: 14px; overflow: hidden; flex-shrink: 0; }
.brand-chip .bl img { width: 100%; height: 100%; object-fit: cover; }
.brand-chip strong { font-size: 15px; font-weight: 600; letter-spacing: -.015em; }

.rp-hero { display: grid; grid-template-columns: 1.05fr 1fr; gap: 56px; padding-top: 40px; padding-bottom: 40px; align-items: center; }
.rp-media { position: relative; border-radius: 32px; overflow: hidden; aspect-ratio: 1 / 1; background: var(--placeholder); box-shadow: var(--shadow); }
.rp-media img { width: 100%; height: 100%; object-fit: cover; }
.rp-media .placeholder { position: absolute; inset: 0; display: grid; place-items: center; color: var(--muted-2); }
.rp-media .placeholder .icon { width: 72px; height: 72px; stroke-width: 1.2; }
.rp-media .tag { position: absolute; left: 18px; top: 18px; }
.rp-info h1 { font-size: clamp(34px, 5vw, 56px); letter-spacing: -.04em; margin: 16px 0 12px; line-height: 1.04; }
.rp-prize { font-size: 17px; color: var(--muted); }
.rp-price { display: flex; align-items: baseline; gap: 8px; margin: 28px 0 22px; }
.rp-price strong { font-size: 44px; font-weight: 700; letter-spacing: -.045em; font-variant-numeric: tabular-nums; }
.rp-price span { color: var(--muted); font-size: 15px; }
.rp-meta { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; margin-bottom: 22px; }
.rp-meta > div { padding: 14px 16px; border-radius: 16px; background: var(--bg-soft); }
.rp-meta small { display: block; font-size: 12px; color: var(--muted); }
.rp-meta b { font-size: 15px; font-weight: 600; letter-spacing: -.01em; }
.rp-progress { margin-bottom: 26px; }
.rp-progress .row { font-size: 13px; color: var(--muted); margin-bottom: 8px; }
.rp-progress .row b { color: var(--ink); }
.countdown { display: flex; gap: 8px; margin-bottom: 26px; }
.countdown div { flex: 1; text-align: center; padding: 12px 0; border-radius: 14px; border: 1px solid var(--line); }
.countdown b { display: block; font-size: 24px; font-weight: 650; letter-spacing: -.03em; font-variant-numeric: tabular-nums; }
.countdown small { font-size: 11px; color: var(--muted-2); }
.winner-banner { display: flex; align-items: center; gap: 14px; padding: 16px 18px; border-radius: 18px; background: var(--gold-soft); color: var(--gold-ink); margin-bottom: 22px; }
.winner-banner .icon { flex-shrink: 0; }
@media (max-width: 860px) {
  .rp-hero { grid-template-columns: minmax(0, 1fr); gap: 26px; padding-top: 18px; }
  .rp-media { aspect-ratio: 4 / 3; border-radius: 26px; }
  .rp-price strong { font-size: 38px; }
}

.rp-picker { padding-top: 40px; scroll-margin-top: 70px; }
.rp-picker-head { display: flex; justify-content: space-between; align-items: flex-end; gap: 16px; flex-wrap: wrap; margin-bottom: 20px; }
.rp-picker-head h2 { font-size: clamp(26px, 3.4vw, 36px); letter-spacing: -.035em; }
.picker-tools { display: flex; gap: 10px; align-items: center; flex-wrap: wrap; margin-bottom: 18px; }
.picker-tools .input-group { flex: 1; min-width: 180px; max-width: 280px; }
.picker-ranges { margin-bottom: 18px; }
.picker-panel { border: 1px solid var(--line); border-radius: 26px; padding: 22px; background: var(--bg); }
@media (max-width: 640px) { .picker-panel { padding: 14px; border-radius: 22px; } .picker-tools .input-group { max-width: none; } }

.rp-details { display: grid; grid-template-columns: 1.4fr 1fr; gap: 16px; margin-top: 48px; }
.rp-details .card { border-radius: 24px; }
.info-rows { display: grid; gap: 0; }
.info-rows > div { display: flex; justify-content: space-between; gap: 16px; padding: 13px 0; border-bottom: 1px solid var(--line); font-size: 14.5px; }
.info-rows > div:last-child { border-bottom: 0; }
.info-rows span { color: var(--muted); }
.info-rows b { font-weight: 550; text-align: right; }
.org { display: flex; align-items: center; gap: 14px; margin-bottom: 16px; }
.org .bl { width: 52px; height: 52px; border-radius: 15px; font-size: 19px; }
@media (max-width: 860px) { .rp-details { grid-template-columns: minmax(0, 1fr); } }

/* Barra de selección (sticky abajo) */
.select-bar {
  position: fixed; left: 50%; bottom: 16px; z-index: 80; width: calc(100% - 24px); max-width: 720px;
  transform: translate(-50%, 150%); transition: transform .5s var(--ease-out);
  background: var(--glass-strong); backdrop-filter: saturate(180%) blur(24px); -webkit-backdrop-filter: saturate(180%) blur(24px);
  border-radius: 24px; box-shadow: 0 0 0 1px var(--line), 0 20px 50px rgba(0, 0, 0, .16);
  padding: 12px 12px 12px 18px; display: flex; align-items: center; gap: 14px;
  margin-bottom: env(safe-area-inset-bottom);
}
.select-bar.show { transform: translate(-50%, 0); }
.select-bar .sb-nums { flex: 1; min-width: 0; }
.select-bar .sb-nums small { font-size: 12px; color: var(--muted); display: block; margin-bottom: 4px; }
.select-bar .chip-list { flex-wrap: nowrap; overflow-x: auto; scrollbar-width: none; }
.select-bar .chip-list::-webkit-scrollbar { display: none; }
.select-bar .chip { height: 26px; min-width: 40px; font-size: 12.5px; background: var(--ink); color: var(--on-ink); }
.select-bar .sb-total { text-align: right; }
.select-bar .sb-total small { font-size: 12px; color: var(--muted); display: block; }
.select-bar .sb-total strong { font-size: 19px; letter-spacing: -.02em; font-variant-numeric: tabular-nums; }
@media (max-width: 560px) {
  .select-bar { flex-wrap: wrap; bottom: 10px; padding: 14px; gap: 12px; }
  .select-bar .sb-nums { flex-basis: 100%; }
  .select-bar .sb-total { text-align: left; flex: 1; }
}

.success-state { text-align: center; padding: 8px 0 4px; }
.success-check { width: 72px; height: 72px; border-radius: 50%; background: #34c759; color: #fff; display: grid; place-items: center; margin: 0 auto 18px; animation: pop-in .6s var(--spring) both; }
.success-check svg { width: 36px; height: 36px; stroke-width: 2.6; }
.success-check path { stroke-dasharray: 30; stroke-dashoffset: 30; animation: check-draw .5s var(--ease-out) .3s forwards; }
@keyframes check-draw { to { stroke-dashoffset: 0; } }
@keyframes pop-in { from { transform: scale(.4); opacity: 0; } }
.code-box { display: inline-block; font-family: var(--mono); font-size: 18px; font-weight: 600; letter-spacing: .06em; padding: 8px 16px; border-radius: 12px; background: var(--bg-soft); margin: 14px 0 6px; }

.powered { text-align: center; margin-top: 64px; font-size: 12.5px; color: var(--muted-2); }
.powered a { display: inline-flex; align-items: center; gap: 6px; font-weight: 600; color: var(--ink-2); }
.powered .logo-mark { width: 18px; height: 18px; border-radius: 5px; }
.powered .logo-mark svg { width: 10px; height: 10px; }

/* Página de ganador */
.winner-page { min-height: 100vh; display: flex; flex-direction: column; background: radial-gradient(900px 500px at 50% 0%, color-mix(in srgb, #f5d77a 22%, var(--bg)), var(--bg) 60%); overflow: hidden; }
.winner-card { max-width: 560px; margin: 40px auto; text-align: center; padding: 0 22px; position: relative; z-index: 2; }
.trophy { width: 96px; height: 96px; border-radius: 30px; margin: 0 auto 26px; display: grid; place-items: center; background: linear-gradient(145deg, #f7dc8c, #e0a82e); color: #5a3d00; box-shadow: 0 20px 50px -10px rgba(224, 168, 46, .55); animation: pop-in .8s var(--spring) both; }
.trophy svg { width: 46px; height: 46px; }
.winner-label { font-size: 13px; font-weight: 700; letter-spacing: .2em; color: #a0740a; }
.winner-number { font-size: clamp(88px, 22vw, 150px); font-weight: 750; letter-spacing: -.06em; line-height: 1; margin: 14px 0 6px; font-variant-numeric: tabular-nums; animation: rise 1s var(--ease-out) .2s both; }
.winner-name { font-size: 26px; font-weight: 650; letter-spacing: -.03em; animation: rise 1s var(--ease-out) .35s both; }
@keyframes rise { from { opacity: 0; transform: translateY(20px); } }
.winner-facts { margin-top: 36px; text-align: left; border-radius: 24px; background: var(--glass-strong); border: 1px solid var(--line); padding: 8px 22px; animation: rise 1s var(--ease-out) .5s both; }
.confetti { position: fixed; inset: 0; pointer-events: none; z-index: 1; overflow: hidden; }
.confetti i { position: absolute; top: -20px; width: 8px; height: 14px; border-radius: 2px; opacity: .9; animation: fall linear forwards; }
@keyframes fall { to { transform: translate3d(var(--x, 0), 110vh, 0) rotate(var(--r, 540deg)); opacity: .9; } }

/* Páginas legales / simples */
.page-simple { padding: 80px 0 120px; }
.page-simple h1 { margin-bottom: 12px; }
.prose { font-size: 16px; line-height: 1.7; color: var(--ink-2); }
.prose h2 { font-size: 22px; margin: 40px 0 12px; }
.prose p, .prose ul { margin: 0 0 16px; }

/* Página de error */
.error-page { min-height: 100vh; display: grid; place-items: center; text-align: center; padding: 24px; background: var(--bg-soft); }
.error-page .code { font-size: 96px; font-weight: 750; letter-spacing: -.06em; line-height: 1; color: var(--line-2); }
.error-page h1 { font-size: 28px; margin: 12px 0 10px; }
.error-page pre { text-align: left; max-width: 900px; overflow: auto; font-size: 12px; background: var(--bg-elev); padding: 16px; border-radius: 12px; margin-top: 24px; border: 1px solid var(--line); }

/* Empresa pública */
.emp-hero { padding: 64px 0 40px; text-align: center; }
.emp-hero .bl { width: 76px; height: 76px; border-radius: 22px; margin: 0 auto 18px; font-size: 28px; }
.rifa-cards { display: grid; grid-template-columns: repeat(auto-fill, minmax(280px, 1fr)); gap: 18px; }
.rifa-card { border-radius: 24px; overflow: hidden; border: 1px solid var(--line); background: var(--bg-elev); transition: transform .4s var(--ease-out), box-shadow .4s; }
.rifa-card:hover { transform: translateY(-4px); box-shadow: var(--shadow-lg); }
.rifa-card .img { aspect-ratio: 4 / 3; background: var(--placeholder); display: grid; place-items: center; color: var(--muted-2); }
.rifa-card .img img { width: 100%; height: 100%; object-fit: cover; }
.rifa-card .body { padding: 20px; }

/* Promociones en la página pública */
.promo-list { display: grid; gap: 8px; margin: -8px 0 22px; }
.promo-pill { display: flex; align-items: center; gap: 12px; padding: 12px 16px; border-radius: 16px; background: color-mix(in srgb, var(--accent) 10%, var(--bg)); border: 1px solid color-mix(in srgb, var(--accent) 26%, var(--bg)); color: var(--ink); }
.promo-pill .icon { color: var(--accent); flex-shrink: 0; }
.promo-pill strong { display: block; font-size: 15px; font-weight: 600; letter-spacing: -.01em; }
.promo-pill small { font-size: 12.5px; color: var(--green); font-weight: 500; }
.select-bar .sb-total small { white-space: nowrap; }
