:root {
  --bg: #06140d; --bg2: #0b2016; --card: rgba(14, 40, 27, .82); --line: rgba(231, 194, 90, .22);
  --text: #f4f1e3; --muted: #b8c7b0; --gold: #e7c25a; --gold2: #f6dc8a; --emerald: #19a874; --jade: #0f6b4a;
  --red: #ff5a4f; --ok: #3fe39a; --warn: #ffc24a; --r: 18px;
}
* { box-sizing: border-box; }
[hidden] { display: none !important; }
html, body { margin: 0; overflow-x: hidden; }
body { background: radial-gradient(1200px 700px at 50% -10%, #134b31 0%, transparent 60%), radial-gradient(900px 600px at 100% 30%, rgba(25, 168, 116, .18), transparent 60%), var(--bg);
  color: var(--text); font: 15px/1.55 Inter, system-ui, sans-serif; min-height: 100vh; -webkit-tap-highlight-color: transparent; }
a { color: var(--gold2); }
button { font: inherit; color: inherit; cursor: pointer; }
h1, h2, h3 { font-family: Oswald, sans-serif; letter-spacing: .02em; }

/* fondo de jungla animado */
.jungle { position: fixed; inset: 0; pointer-events: none; z-index: 0; overflow: hidden; }
.leaf { position: absolute; width: 340px; height: 340px; opacity: .22; filter: blur(.3px); background: no-repeat center/contain;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 200 200'%3E%3Cpath fill='%2319a874' d='M100 10c40 30 70 70 60 120-30-10-50-35-60-70-10 35-30 60-60 70-10-50 20-90 60-120z'/%3E%3Cpath stroke='%230b2016' stroke-width='3' d='M100 20v170'/%3E%3C/svg%3E"); animation: sway 9s ease-in-out infinite alternate; }
.l1 { top: -80px; left: -110px; transform: rotate(35deg); }
.l2 { top: 10%; right: -140px; transform: rotate(-40deg) scale(1.3); animation-duration: 11s; }
.l3 { bottom: -120px; left: -60px; transform: rotate(160deg) scale(1.1); animation-duration: 13s; }
.l4 { bottom: 15%; right: -90px; transform: rotate(-150deg); animation-duration: 10s; }
@keyframes sway { from { margin-top: 0; rotate: -3deg; } to { margin-top: 18px; rotate: 4deg; } }
.flies { position: absolute; inset: 0; background-image: radial-gradient(2px 2px at 10% 20%, #f6dc8a, transparent), radial-gradient(2px 2px at 80% 30%, #f6dc8a, transparent),
  radial-gradient(1.5px 1.5px at 40% 70%, #bff7d8, transparent), radial-gradient(2px 2px at 65% 85%, #f6dc8a, transparent), radial-gradient(1.5px 1.5px at 25% 55%, #bff7d8, transparent),
  radial-gradient(2px 2px at 90% 65%, #f6dc8a, transparent); animation: fly 14s linear infinite alternate; opacity: .8; }
@keyframes fly { to { transform: translate(-30px, -40px); opacity: .4; } }
@media (prefers-reduced-motion: reduce) { .leaf, .flies { animation: none; } }

.ph { position: sticky; top: 0; z-index: 20; background: rgba(6, 20, 13, .82); backdrop-filter: blur(10px); border-bottom: 1px solid var(--line); padding-top: env(safe-area-inset-top); }
.ph-in { max-width: 980px; margin: 0 auto; padding: 8px 14px; display: flex; align-items: center; justify-content: space-between; gap: 10px; }
.brand { display: flex; align-items: center; gap: 8px; text-decoration: none; color: var(--text); min-width: 0; }
.ph-logo { height: 40px; width: auto; }
.brand span { font-family: Oswald, sans-serif; font-size: 18px; letter-spacing: .08em; line-height: 1; display: flex; flex-direction: column; }
.brand b { font-size: 10px; color: var(--gold); letter-spacing: .3em; }
.ph-nav { display: flex; gap: 6px; align-items: center; }
.navbtn { position: relative; text-decoration: none; color: var(--text); border: 1px solid var(--line); border-radius: 999px; padding: 7px 12px; font-size: 14px; white-space: nowrap; background: rgba(255, 255, 255, .03); }
.navbtn.gold { background: linear-gradient(135deg, var(--gold2), var(--gold)); color: #1b1505; font-weight: 700; border: 0; }
.dot { position: absolute; top: -4px; right: -4px; width: 12px; height: 12px; border-radius: 50%; background: var(--red); }

main { position: relative; z-index: 1; max-width: 980px; margin: 0 auto; padding: 14px 14px 60px; }
.pf { position: relative; z-index: 1; text-align: center; color: var(--muted); font-size: 13px; padding: 20px 14px 40px; }
.pf .ver { opacity: .6; font-size: 11px; }

/* tarjetas y botones */
.card { background: var(--card); border: 1px solid var(--line); border-radius: var(--r); padding: 18px; backdrop-filter: blur(6px); margin-bottom: 14px; }
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 8px; border: 1px solid var(--line); background: rgba(255, 255, 255, .05); color: var(--text); border-radius: 999px; padding: 10px 18px; font-weight: 600; text-decoration: none; }
.btn.gold { background: linear-gradient(135deg, var(--gold2), var(--gold)); color: #1b1505; border: 0; box-shadow: 0 10px 30px -10px rgba(231, 194, 90, .7); }
.btn.big { font-size: 18px; padding: 16px 26px; font-family: Oswald, sans-serif; letter-spacing: .04em; }
.btn.small { padding: 6px 12px; font-size: 13px; }
.btn.danger { border-color: rgba(255, 90, 79, .5); color: #ffb3ad; }
.btn[disabled] { opacity: .45; pointer-events: none; }
.muted { color: var(--muted); }
.err { color: #ff9a92; min-height: 1.3em; }
.okmsg { color: var(--ok); }
input, select, textarea { width: 100%; background: rgba(0, 0, 0, .35); border: 1px solid var(--line); color: var(--text); border-radius: 12px; padding: 11px 13px; font: inherit; outline: none; }
input:focus, select:focus, textarea:focus { border-color: var(--gold); box-shadow: 0 0 0 3px rgba(231, 194, 90, .18); }
label.f { display: grid; gap: 5px; font-size: 13px; color: var(--muted); margin-bottom: 10px; }
.row2 { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.chk { display: flex; gap: 10px; align-items: flex-start; font-size: 14px; margin: 10px 0; }
.chk input { width: 20px; height: 20px; flex: none; accent-color: var(--gold); padding: 0; margin-top: 2px; }

/* portada */
.hero { text-align: center; padding: 30px 6px 10px; }
.hero .kicker { color: var(--gold); letter-spacing: .3em; font-size: 12px; text-transform: uppercase; margin: 0; }
.hero h1 { font-family: 'Cinzel Decorative', Oswald, serif; font-size: clamp(38px, 10vw, 84px); margin: 6px 0 0; line-height: 1;
  background: linear-gradient(180deg, #fff6c9, var(--gold) 55%, #9c7a1f); -webkit-background-clip: text; background-clip: text; color: transparent;
  text-shadow: 0 0 40px rgba(231, 194, 90, .25); }
.hero .game { font-family: Oswald, sans-serif; letter-spacing: .5em; color: var(--emerald); font-size: clamp(14px, 3.6vw, 22px); margin: 4px 0 0; }
.hero .emoji { font-size: 30px; margin: 4px 0; }
.hero .meta { display: flex; justify-content: center; gap: 10px; flex-wrap: wrap; margin: 16px 0; }
.pill { background: rgba(0, 0, 0, .35); border: 1px solid var(--line); border-radius: 999px; padding: 6px 14px; font-size: 14px; }
.hero p.lead { max-width: 640px; margin: 10px auto; color: #dfe9d6; }
.cta { margin: 18px 0 6px; display: flex; flex-direction: column; align-items: center; gap: 8px; }
.cta small { color: var(--gold2); font-weight: 600; }
.prod { display: grid; grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); gap: 8px; margin-top: 10px; }
.prod div { background: rgba(0, 0, 0, .3); border: 1px solid var(--line); border-radius: 12px; padding: 10px; font-size: 14px; }
.tag { text-align: center; font-family: Oswald, sans-serif; font-size: 22px; color: var(--gold2); letter-spacing: .04em; margin: 16px 0 4px; }
.sec-title { font-family: Oswald, sans-serif; font-size: 24px; margin: 26px 0 10px; display: flex; align-items: center; gap: 10px; }
.sec-title::before { content: ''; width: 22px; height: 3px; background: var(--gold); border-radius: 2px; }

.priceline { text-align: center; margin: 8px 0 2px; }
.priceline b { color: var(--gold2); }
.countdown { display: flex; justify-content: center; gap: 8px; margin: 10px 0 4px; }
.countdown div { background: rgba(0, 0, 0, .45); border: 1px solid var(--line); border-radius: 14px; padding: 8px 6px; min-width: 66px; text-align: center; }
.countdown b { display: block; font-family: Oswald, sans-serif; font-size: 30px; color: var(--gold2); line-height: 1.1; font-variant-numeric: tabular-nums; }
.countdown span { font-size: 11px; color: var(--muted); text-transform: uppercase; letter-spacing: .1em; }
.warnline { text-align: center; color: var(--warn); font-size: 14px; margin: 6px 0 14px; }
.promos { display: grid; grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); gap: 10px; }
.promo { position: relative; background: var(--card); border: 1px solid var(--line); border-radius: var(--r); padding: 16px; text-align: center; }
.promo.best { border-color: var(--gold); box-shadow: 0 0 0 1px var(--gold), 0 16px 40px -18px rgba(231, 194, 90, .8); background: linear-gradient(160deg, rgba(231, 194, 90, .15), var(--card) 55%); }
.promo .badge { position: absolute; top: -10px; left: 50%; transform: translateX(-50%); background: var(--gold); color: #1b1505; font-size: 11px; font-weight: 700; padding: 3px 10px; border-radius: 999px; white-space: nowrap; }
.promo h3 { margin: 4px 0; font-size: 18px; }
.promo s { color: var(--muted); }
.promo .p { font-family: Oswald, sans-serif; font-size: 34px; color: var(--gold2); line-height: 1.1; }
.promo .each { font-size: 13px; color: #dfe9d6; }
.fee { text-align: center; font-size: 13px; color: var(--muted); margin-top: 8px; }

details.faq { background: var(--card); border: 1px solid var(--line); border-radius: 14px; margin-bottom: 8px; }
details.faq summary { cursor: pointer; padding: 14px 16px; font-weight: 600; list-style: none; display: flex; justify-content: space-between; gap: 10px; }
details.faq summary::-webkit-details-marker { display: none; }
details.faq summary::after { content: '+'; color: var(--gold); font-size: 20px; line-height: 1; }
details.faq[open] summary::after { content: '–'; }
details.faq .a { padding: 0 16px 14px; color: #dfe9d6; }
details.faq ul { margin: 6px 0; padding-left: 20px; }

.news { display: grid; gap: 10px; margin-bottom: 14px; }
.newsitem { background: linear-gradient(135deg, rgba(25, 168, 116, .22), var(--card) 70%); border: 1px solid rgba(25, 168, 116, .5); border-radius: var(--r); padding: 14px 16px; }
.newsitem h3 { margin: 0 0 4px; font-size: 18px; }
.newsitem p { margin: 0 0 8px; white-space: pre-wrap; }

/* compra */
.steps { display: flex; gap: 6px; margin-bottom: 12px; }
.steps span { flex: 1; height: 5px; border-radius: 3px; background: rgba(255, 255, 255, .12); }
.steps span.on { background: var(--gold); }
.fcard { display: flex; align-items: center; gap: 12px; padding: 12px; border: 1px solid var(--line); border-radius: 14px; margin-bottom: 8px; background: rgba(0, 0, 0, .25); }
.fcard .fi { flex: 1; min-width: 0; }
.fcard .fi b { display: block; }
.fcard .fi small { color: var(--muted); }
.qty { display: flex; align-items: center; gap: 6px; }
.qty button { width: 38px; height: 38px; border-radius: 50%; border: 1px solid var(--line); background: rgba(255, 255, 255, .06); font-size: 20px; }
.qty b { min-width: 28px; text-align: center; font-family: Oswald, sans-serif; font-size: 22px; }
.sum { display: grid; gap: 6px; }
.sum div { display: flex; justify-content: space-between; gap: 10px; }
.sum .tot { border-top: 1px solid var(--line); padding-top: 8px; font-family: Oswald, sans-serif; font-size: 22px; color: var(--gold2); }
.free { color: var(--ok); }
.alumno { display: flex; justify-content: space-between; align-items: center; gap: 10px; padding: 12px; border: 1px solid var(--line); border-radius: 14px; margin-bottom: 8px; background: rgba(0, 0, 0, .25); }
.tabs2 { display: flex; gap: 6px; margin-bottom: 12px; flex-wrap: wrap; }
.tabs2 button { border: 1px solid var(--line); background: rgba(0, 0, 0, .3); border-radius: 999px; padding: 8px 14px; color: var(--muted); }
.tabs2 button.on { background: var(--gold); color: #1b1505; border-color: var(--gold); font-weight: 700; }
table.t { width: 100%; border-collapse: collapse; font-size: 13px; }
table.t th, table.t td { text-align: left; padding: 7px 6px; border-bottom: 1px solid var(--line); vertical-align: top; }
.scroll { overflow-x: auto; }
.chipst { display: inline-block; padding: 2px 8px; border-radius: 999px; font-size: 12px; border: 1px solid var(--line); }
.chipst.aprobada, .chipst.valida { color: var(--ok); border-color: rgba(63, 227, 154, .5); }
.chipst.pendiente { color: var(--warn); }
.chipst.anulada, .chipst.vencida, .chipst.rechazada, .chipst.cancelada, .chipst.usada { color: #ff9a92; }
.bar { height: 8px; border-radius: 4px; background: rgba(255, 255, 255, .1); overflow: hidden; }
.bar i { display: block; height: 100%; background: linear-gradient(90deg, var(--emerald), var(--gold)); }
.grid2 { display: grid; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); gap: 10px; }
.kpi b { display: block; font-family: Oswald, sans-serif; font-size: 26px; color: var(--gold2); }

/* escáner */
.scanbox { position: relative; border-radius: 16px; overflow: hidden; background: #000; aspect-ratio: 3/4; max-height: 60vh; }
.scanbox video { width: 100%; height: 100%; object-fit: cover; }
.result { margin-top: 12px; border-radius: 16px; padding: 18px; text-align: center; font-family: Oswald, sans-serif; }
.result.verde { background: #0f8f55; } .result.rojo { background: #b3261e; } .result.amarillo { background: #c99400; color: #1b1505; }
.result h2 { margin: 0; font-size: 36px; }
.result p { margin: 4px 0 0; font-family: Inter, sans-serif; }

.toast { position: fixed; left: 50%; bottom: calc(20px + env(safe-area-inset-bottom)); transform: translate(-50%, 30px); opacity: 0; background: #fff; color: #111; padding: 11px 18px; border-radius: 999px; font-weight: 600; transition: .25s; pointer-events: none; max-width: calc(100% - 32px); text-align: center; z-index: 60; }
.toast.on { opacity: 1; transform: translate(-50%, 0); }
.toast.bad { background: #ff5a4f; color: #fff; }
@media (max-width: 560px) { .brand span { font-size: 15px; } .ph-logo { height: 32px; } .row2 { grid-template-columns: 1fr; } .navbtn { padding: 6px 10px; font-size: 13px; } .countdown div { min-width: 58px; } }

@media (max-width: 430px) { .brand span { display: none; } .ph-nav { gap: 5px; } }
