/* App del pasajero — tema oscuro, marco de teléfono en escritorio, pantalla completa en celular */
body { min-height: 100vh; background: #050913; color: #eef2fa; overflow-x: hidden; }
body::before { content: ''; position: fixed; inset: 0; z-index: -1; background: radial-gradient(900px 600px at 70% 20%, color-mix(in srgb, var(--brand) 20%, transparent), transparent 60%), radial-gradient(700px 500px at 10% 90%, color-mix(in srgb, var(--brand2) 10%, transparent), transparent 60%); }
.stage { min-height: 100vh; display: grid; grid-template-columns: minmax(280px, 380px) auto minmax(0, 300px); justify-content: center; align-items: center; gap: 48px; padding: 70px 32px 30px; }

/* Panel lateral de demostración */
.side h1 { font-size: 30px; font-weight: 800; letter-spacing: -.02em; line-height: 1.1; }
.side > p { margin: 10px 0 18px; color: #93a0b8; font-size: 14.5px; }
.who { display: flex; align-items: center; gap: 12px; padding: 12px 14px; border-radius: 18px; background: rgba(255,255,255,.04); border: 1px solid rgba(255,255,255,.08); }
.who .av { width: 42px; height: 42px; border-radius: 50%; display: grid; place-items: center; font-weight: 800; background: linear-gradient(135deg, #ff8a5b, #e84393); }
.who b { display: block; } .who span { font-size: 13px; color: #93a0b8; }
.who em { margin-left: auto; font-style: normal; font-weight: 800; font-size: 18px; font-variant-numeric: tabular-nums; }
.ctl { margin-top: 16px; display: flex; flex-direction: column; gap: 10px; }
.ctl h4 { font-size: 12px; text-transform: uppercase; letter-spacing: .08em; color: #6b778d; margin-top: 6px; }
.ctl-row { display: flex; align-items: center; justify-content: space-between; gap: 10px; padding: 10px 14px; border-radius: 14px; background: rgba(255,255,255,.04); border: 1px solid rgba(255,255,255,.07); font-size: 14px; font-weight: 600; }
.ctl-row small { display: block; font-weight: 500; color: #93a0b8; font-size: 12px; }
.seg { display: flex; padding: 3px; border-radius: 12px; background: rgba(255,255,255,.06); gap: 2px; }
.seg button { flex: 1; height: 32px; padding: 0 10px; border-radius: 9px; font-size: 12.5px; font-weight: 700; color: #a7b3c9; white-space: nowrap; }
.seg button.on { background: #fff; color: #0b1222; }
.ctl-btn { display: flex; align-items: center; gap: 10px; height: 44px; padding: 0 14px; border-radius: 14px; font-size: 14px; font-weight: 700; background: rgba(255,255,255,.06); border: 1px solid rgba(255,255,255,.08); transition: background .2s; }
.ctl-btn:hover { background: rgba(255,255,255,.12); }
.ctl-btn.primary { background: var(--brand); border-color: transparent; }
.jump { max-height: calc(100vh - 140px); overflow: auto; padding-right: 6px; scrollbar-width: thin; scrollbar-color: rgba(255,255,255,.15) transparent; }
.jump h4 { font-size: 12px; text-transform: uppercase; letter-spacing: .08em; color: #6b778d; margin: 14px 0 6px; }
.jump h4:first-child { margin-top: 0; }
.jump button { display: flex; width: 100%; align-items: center; gap: 9px; padding: 7px 10px; border-radius: 10px; font-size: 13.5px; color: #b5c0d4; text-align: left; }
.jump button:hover { background: rgba(255,255,255,.07); color: #fff; }
.jump button.on { background: color-mix(in srgb, var(--brand) 22%, transparent); color: #fff; }
.jump .ic-i { color: #6b778d; }

/* Interruptor */
.sw { position: relative; width: 44px; height: 26px; border-radius: 99px; background: rgba(255,255,255,.18); flex: none; transition: background .25s; }
.sw::after { content: ''; position: absolute; left: 3px; top: 3px; width: 20px; height: 20px; border-radius: 50%; background: #fff; transition: transform .3s var(--spring); box-shadow: 0 2px 6px rgba(0,0,0,.3); }
.sw.on { background: var(--brand2); } .sw.on::after { transform: translateX(18px); }

/* ============ TELÉFONO ============ */
.phone { position: relative; width: 390px; height: min(844px, calc(100vh - 100px)); min-height: 640px; border-radius: 58px; padding: 12px; background: linear-gradient(145deg, #3a3f4a, #12151b 40%, #2a2e36); box-shadow: 0 0 0 1.5px #4a505c inset, 0 50px 100px rgba(0,0,0,.6), 0 12px 30px rgba(0,0,0,.4); }
.phone.buzz { animation: buzz .5s linear 2; }
@keyframes buzz { 10%, 30% { transform: translateX(-4px) rotate(-1deg); } 20%, 40% { transform: translateX(4px) rotate(1deg); } 50% { transform: none; } }
.screen { --bg: #07090d; --s1: #10151d; --s2: #171e29; --s3: #212a38; --tx: #eef2fa; --mu: #8c98ae; --ln: rgba(255,255,255,.08);
  position: relative; width: 100%; height: 100%; border-radius: 46px; overflow: hidden; background: var(--bg); color: var(--tx); display: flex; flex-direction: column; font-size: 15px; }
.screen.contrast { --mu: #c9d3e3; --ln: rgba(255,255,255,.28); --s1: #0b0f15; --s2: #121822; }
.screen.big .sc-in { zoom: 1.14; }
.island { position: absolute; top: 11px; left: 50%; width: 110px; height: 32px; margin-left: -55px; border-radius: 20px; background: #000; z-index: 60; }
.sbar { flex: none; height: 52px; padding: 18px 30px 0 34px; display: flex; justify-content: space-between; font-size: 15px; font-weight: 700; z-index: 50; }
.sbar .sys { display: flex; gap: 6px; align-items: center; }
.sbar .sys .ic-i { width: 17px; height: 17px; }
.sbar .off { color: #fbbf24; }

.hdr { flex: none; display: flex; align-items: center; gap: 8px; height: 52px; padding: 0 14px; z-index: 5; }
.hdr h2 { font-size: 17px; font-weight: 800; flex: 1; text-align: center; margin-right: 40px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.hdr.noback h2 { margin: 0; text-align: left; padding-left: 6px; font-size: 24px; letter-spacing: -.02em; }
.hdr .hb { width: 40px; height: 40px; border-radius: 50%; display: grid; place-items: center; background: var(--s2); flex: none; }
.hdr .hb .ic-i { width: 20px; height: 20px; }
.hdr .hb-r { margin-left: auto; }
.hdr.noback .hb-r + h2 { order: -1; }

.sc { flex: 1; overflow-y: auto; overflow-x: hidden; scrollbar-width: none; overscroll-behavior: contain; position: relative; }
.sc::-webkit-scrollbar { display: none; }
.sc-in { padding: 4px 18px 110px; }
.screen.nonav .sc-in { padding-bottom: 36px; }
.fade-in { animation: fin .35s var(--ease); }
@keyframes fin { from { opacity: 0; transform: translateY(8px); } }
.screen.motion .fade-in { animation: none; }

/* Navegación inferior */
.nav { position: absolute; left: 14px; right: 14px; bottom: 16px; height: 66px; border-radius: 33px; background: rgba(23,30,41,.92); backdrop-filter: blur(18px); border: 1px solid var(--ln); display: flex; align-items: center; justify-content: space-around; z-index: 40; box-shadow: 0 16px 40px rgba(0,0,0,.5); }
.nav button { position: relative; display: flex; flex-direction: column; align-items: center; gap: 3px; font-size: 10.5px; font-weight: 700; color: #7c879b; width: 58px; }
.nav button .ic-i { width: 22px; height: 22px; }
.nav button.on { color: #fff; }
.nav button.on::before { content: ''; position: absolute; top: -9px; width: 18px; height: 3px; border-radius: 3px; background: var(--brand); }
.nav .qrb { width: 54px; height: 54px; border-radius: 50%; background: var(--brand); color: #fff; justify-content: center; margin-top: -26px; box-shadow: 0 10px 26px color-mix(in srgb, var(--brand) 55%, transparent), 0 0 0 5px var(--bg); }
.nav .qrb .ic-i { width: 25px; height: 25px; }
.nav .badge { position: absolute; top: -4px; right: 12px; min-width: 17px; height: 17px; padding: 0 4px; border-radius: 9px; background: var(--bad); color: #fff; font-size: 10px; display: grid; place-items: center; box-shadow: 0 0 0 2px #171e29; }

/* Banner sin conexión y push */
.offbar { margin: 0 0 10px; padding: 10px 12px; border-radius: 14px; background: rgba(251,191,36,.12); border: 1px solid rgba(251,191,36,.3); color: #fde68a; font-size: 13px; display: flex; gap: 9px; align-items: flex-start; }
.offbar .ic-i { margin-top: 1px; }
.push { position: absolute; left: 10px; right: 10px; top: 50px; z-index: 70; padding: 12px 14px; border-radius: 22px; background: rgba(30,38,52,.92); backdrop-filter: blur(20px); border: 1px solid rgba(255,255,255,.12); box-shadow: 0 20px 40px rgba(0,0,0,.5); display: flex; gap: 11px; align-items: center; transform: translateY(calc(-100% - 80px)); opacity: 0; visibility: hidden; transition: transform .5s var(--spring), opacity .3s, visibility 0s .5s; cursor: pointer; text-align: left; width: auto; }
.push.show { transform: none; opacity: 1; visibility: visible; transition: transform .5s var(--spring), opacity .2s; }
.push img, .push .logo-fallback { width: 38px; height: 38px; border-radius: 10px; background: #fff; object-fit: contain; padding: 3px; flex: none; }
.push b { display: block; font-size: 14px; } .push span { display: block; font-size: 12.5px; color: #c4cede; }
.push em { margin-left: auto; align-self: flex-start; font-style: normal; font-size: 11px; color: #8c98ae; }

/* Componentes */
.hello { display: flex; align-items: center; gap: 11px; height: 54px; }
.av { width: 42px; height: 42px; border-radius: 50%; display: grid; place-items: center; font-weight: 800; font-size: 15px; background: linear-gradient(135deg, #ff8a5b, #e84393); color: #fff; flex: none; }
.hello span { display: block; font-size: 12.5px; color: var(--mu); } .hello strong { font-size: 17px; }
.bell { margin-left: auto; position: relative; width: 42px; height: 42px; border-radius: 50%; display: grid; place-items: center; background: var(--s2); }
.bell .ic-i { width: 20px; height: 20px; }
.bell b { position: absolute; top: 6px; right: 6px; min-width: 16px; height: 16px; border-radius: 8px; font-size: 10px; background: var(--bad); display: grid; place-items: center; padding: 0 3px; box-shadow: 0 0 0 2px var(--bg); }
.bal { position: relative; margin-top: 10px; padding: 18px 20px 16px; border-radius: 28px; overflow: hidden; color: #fff;
  background: radial-gradient(180px 140px at 100% 0%, color-mix(in srgb, var(--brand2) 55%, transparent), transparent 70%), linear-gradient(135deg, var(--brand), color-mix(in srgb, var(--brand) 50%, #0a0f1f)); box-shadow: 0 18px 44px color-mix(in srgb, var(--brand) 32%, transparent); }
.bal::after { content: ''; position: absolute; inset: 0; background: repeating-linear-gradient(115deg, transparent 0 22px, rgba(255,255,255,.04) 22px 23px); pointer-events: none; }
.bal-top { display: flex; justify-content: space-between; align-items: center; font-size: 13.5px; font-weight: 600; opacity: .92; }
.bal-top img, .bal-top .logo-fallback { width: 34px; height: 34px; object-fit: contain; }
.bal-amt { font-size: 48px; font-weight: 800; letter-spacing: -.03em; margin: 2px 0 10px; font-variant-numeric: tabular-nums; }
.bal-amt small { font-size: 28px; opacity: .65; }
.bal-foot { display: flex; justify-content: space-between; align-items: center; font-size: 12px; position: relative; z-index: 1; }
.chip { display: inline-flex; align-items: center; gap: 5px; padding: 5px 10px; border-radius: 99px; background: rgba(255,255,255,.18); font-weight: 700; font-size: 12px; }
.chip .ic-i { width: 14px; height: 14px; }
.acts { display: grid; grid-template-columns: repeat(3, 1fr); gap: 10px; margin-top: 14px; }
.act { display: flex; flex-direction: column; align-items: center; gap: 7px; padding: 12px 6px; border-radius: 20px; background: var(--s2); font-size: 12.5px; font-weight: 700; }
.act .ic-i { width: 40px; height: 40px; padding: 10px; border-radius: 50%; background: var(--s3); }
.act.pri .ic-i { background: var(--brand); color: #fff; }
.act:disabled { opacity: .45; cursor: not-allowed; }
.sec { margin-top: 22px; }
.sec-h { display: flex; align-items: baseline; justify-content: space-between; margin-bottom: 10px; }
.sec-h h3 { font-size: 13px; font-weight: 800; color: var(--mu); text-transform: uppercase; letter-spacing: .07em; }
.sec-h button { font-size: 13px; font-weight: 700; color: color-mix(in srgb, var(--brand) 70%, #fff); }
.card { background: var(--s1); border: 1px solid var(--ln); border-radius: 22px; padding: 14px; }
.pending-r { margin-top: 10px; display: flex; align-items: center; gap: 10px; padding: 10px 12px; border-radius: 16px; background: rgba(251,191,36,.1); color: #fde68a; font-size: 13px; font-weight: 600; width: 100%; text-align: left; }

/* Próximo viaje (tarjeta clara) */
.trip { display: block; width: 100%; text-align: left; border-radius: 26px; background: #f6f8fc; color: #0f172a; padding: 16px; position: relative; overflow: hidden; }
.trip::before { content: ''; position: absolute; left: 0; right: 0; top: 0; height: 4px; background: linear-gradient(90deg, #fcd116 0 33%, #034ea2 33% 66%, #ed1c24 66%); }
.trip-top { display: flex; justify-content: space-between; align-items: center; font-size: 12px; font-weight: 700; color: #64748b; }
.trip-route { display: flex; align-items: center; gap: 10px; margin: 10px 0 2px; }
.trip-route b { font-size: 22px; font-weight: 800; letter-spacing: -.02em; }
.trip-route .ic-i { color: var(--brand); width: 18px; height: 18px; }
.trip-via { font-size: 12.5px; color: #64748b; }
.trip-row { display: flex; gap: 8px; margin-top: 12px; align-items: flex-end; }
.trip-row > div { flex: 1; display: grid; grid-template-columns: repeat(3, auto); gap: 4px 14px; justify-content: start; }
.trip-row span { font-size: 11px; color: #64748b; font-weight: 600; }
.trip-row strong { font-size: 15px; font-weight: 800; }
.trip-qr { width: 64px; height: 64px; padding: 5px; border-radius: 12px; background: #fff; box-shadow: 0 0 0 1px #e2e8f0; flex: none; }
.trip-qr svg { width: 100%; height: 100%; }

/* Listas */
.list { display: flex; flex-direction: column; gap: 8px; }
.row { display: flex; align-items: center; gap: 12px; width: 100%; padding: 12px; border-radius: 18px; background: var(--s1); border: 1px solid var(--ln); text-align: left; }
.row > .ic-i { width: 40px; height: 40px; padding: 10px; border-radius: 13px; background: var(--s3); flex: none; color: #c7d2fe; }
.row .tx { flex: 1; min-width: 0; }
.row .tx b { display: block; font-size: 14.5px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.row .tx span { display: block; font-size: 12.5px; color: var(--mu); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.row .amt { font-weight: 800; font-variant-numeric: tabular-nums; font-size: 14.5px; white-space: nowrap; }
.row .amt.pos { color: #4ade80; } .row .amt.muted { color: var(--mu); text-decoration: line-through; }
.row .chev { color: var(--mu); width: 18px; height: 18px; }
.row.unread { border-color: color-mix(in srgb, var(--brand) 45%, transparent); background: color-mix(in srgb, var(--brand) 9%, var(--s1)); }
.row.unread .tx b::after { content: ''; display: inline-block; width: 7px; height: 7px; border-radius: 50%; background: var(--brand); margin-left: 7px; vertical-align: middle; }
.ic-ok { color: #4ade80 !important; background: rgba(34,197,94,.14) !important; }
.ic-bad { color: #fb7185 !important; background: rgba(244,63,94,.14) !important; }
.ic-warn { color: #fbbf24 !important; background: rgba(251,191,36,.14) !important; }
.ic-blue { color: #93c5fd !important; background: rgba(59,130,246,.16) !important; }
.day { font-size: 12px; font-weight: 800; color: var(--mu); text-transform: uppercase; letter-spacing: .07em; margin: 16px 2px 8px; }
.day:first-child { margin-top: 4px; }

.pill { display: inline-flex; align-items: center; gap: 5px; padding: 4px 9px; border-radius: 99px; font-size: 11.5px; font-weight: 800; white-space: nowrap; }
.pill.pagado, .pill.aprobada, .pill.activa, .pill.ok { background: rgba(34,197,94,.15); color: #86efac; }
.pill.usado { background: rgba(148,163,184,.16); color: #cbd5e1; }
.pill.vencido, .pill.pendiente, .pill.por.retirar, .pill.warn { background: rgba(251,191,36,.15); color: #fcd34d; }
.pill.anulado, .pill.rechazada, .pill.bloqueada, .pill.perdida, .pill.bad { background: rgba(244,63,94,.15); color: #fda4af; }
.pill.reemplazada { background: rgba(148,163,184,.12); color: #94a3b8; }
.trip .pill.pagado { background: #dcfce7; color: #166534; }

/* Pestañas y filtros */
.tabs { display: flex; padding: 4px; border-radius: 16px; background: var(--s1); border: 1px solid var(--ln); gap: 2px; margin-bottom: 14px; }
.tabs button { flex: 1; height: 36px; border-radius: 12px; font-size: 13px; font-weight: 700; color: var(--mu); white-space: nowrap; }
.tabs button.on { background: var(--s3); color: #fff; }
.tabs button em { font-style: normal; opacity: .6; margin-left: 3px; }
.chips { display: flex; gap: 6px; overflow-x: auto; scrollbar-width: none; margin: 0 -18px 10px; padding: 0 18px; }
.chips::-webkit-scrollbar { display: none; }
.chips button { flex: none; height: 34px; padding: 0 14px; border-radius: 99px; background: var(--s2); font-size: 13px; font-weight: 700; color: var(--mu); }
.chips button.on { background: #fff; color: #0b1222; }
.search { display: flex; align-items: center; gap: 9px; height: 44px; padding: 0 14px; border-radius: 15px; background: var(--s2); margin-bottom: 10px; color: var(--mu); }
.search input { flex: 1; background: none; border: 0; outline: 0; color: var(--tx); font-size: 14.5px; min-width: 0; }

.note { display: flex; gap: 10px; padding: 12px 14px; border-radius: 18px; background: color-mix(in srgb, var(--brand) 12%, transparent); border: 1px solid color-mix(in srgb, var(--brand) 26%, transparent); font-size: 13px; color: #c7d2fe; margin: 12px 0; }
.note .ic-i { margin-top: 1px; color: color-mix(in srgb, var(--brand) 60%, #fff); }
.note.warn { background: rgba(251,191,36,.08); border-color: rgba(251,191,36,.25); color: #fde68a; } .note.warn .ic-i { color: #fbbf24; }
.note.ok { background: rgba(34,197,94,.08); border-color: rgba(34,197,94,.25); color: #bbf7d0; } .note.ok .ic-i { color: #4ade80; }
.note b { color: #fff; }

/* Botones */
.btn { display: flex; align-items: center; justify-content: center; gap: 9px; width: 100%; height: 54px; border-radius: 18px; font-size: 15.5px; font-weight: 800; background: var(--brand); color: #fff; transition: transform .15s, opacity .2s; box-shadow: 0 10px 24px color-mix(in srgb, var(--brand) 30%, transparent); }
.btn:active { transform: scale(.98); }
.btn:disabled { opacity: .4; box-shadow: none; cursor: not-allowed; }
.btn.ghost { background: var(--s2); box-shadow: none; }
.btn.light { background: #fff; color: #0b1222; box-shadow: none; }
.btn.danger { background: #e11d48; box-shadow: 0 10px 24px rgba(225,29,72,.25); }
.btn.sm { height: 44px; font-size: 14px; border-radius: 14px; }
.btns { display: flex; flex-direction: column; gap: 10px; margin-top: 16px; }
.btns.two { flex-direction: row; }

/* Accesos rápidos */
.quick { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; }
.quick button { display: flex; flex-direction: column; align-items: flex-start; gap: 8px; padding: 13px 12px; border-radius: 18px; background: var(--s1); border: 1px solid var(--ln); font-size: 12.5px; font-weight: 700; text-align: left; line-height: 1.2; }
.quick .ic-i { width: 22px; height: 22px; color: color-mix(in srgb, var(--brand) 65%, #fff); }
.how3 { display: flex; flex-direction: column; gap: 10px; }
.how3 div { display: flex; gap: 12px; align-items: flex-start; font-size: 13px; color: var(--mu); }
.how3 b { flex: none; width: 26px; height: 26px; border-radius: 50%; display: grid; place-items: center; background: var(--s3); color: #fff; font-size: 12px; }
.how3 strong { color: var(--tx); display: block; font-size: 14px; }

/* Estado vacío / error */
.empty { text-align: center; padding: 34px 14px 20px; }
.empty .art { width: 96px; height: 96px; margin: 0 auto 16px; border-radius: 32px; display: grid; place-items: center; background: var(--s2); color: color-mix(in srgb, var(--brand) 65%, #fff); position: relative; }
.empty .art .ic-i { width: 42px; height: 42px; }
.empty .art.bad { color: #fb7185; background: rgba(244,63,94,.12); } .empty .art.warn { color: #fbbf24; background: rgba(251,191,36,.12); } .empty .art.ok { color: #4ade80; background: rgba(34,197,94,.12); }
.empty h3 { font-size: 19px; font-weight: 800; margin-bottom: 6px; }
.empty p { font-size: 14px; color: var(--mu); max-width: 290px; margin: 0 auto; }

/* Detalle de boleto */
.tk-head { text-align: center; padding: 6px 0 14px; }
.tk-head .route { font-size: 26px; font-weight: 800; letter-spacing: -.02em; margin: 10px 0 2px; display: flex; align-items: center; justify-content: center; gap: 10px; }
.tk-head .route .ic-i { width: 20px; height: 20px; color: var(--brand); }
.tk-head span { font-size: 13.5px; color: var(--mu); }
.qrcard { position: relative; background: #fff; color: #0f172a; border-radius: 28px; padding: 22px 22px 16px; text-align: center; }
.qrcard .qr { width: 210px; height: 210px; margin: 0 auto; }
.qrcard .qr svg { width: 100%; height: 100%; }
.qrcard .id { margin-top: 10px; font-family: var(--mono); font-weight: 700; font-size: 15px; letter-spacing: .04em; }
.qrcard small { display: block; font-size: 12px; color: #64748b; margin-top: 2px; }
.qrcard.dim .qr { opacity: .16; filter: grayscale(1); }
.stamp { position: absolute; left: 50%; top: 42%; transform: translate(-50%, -50%) rotate(-12deg); padding: 8px 16px; border: 3px solid currentColor; border-radius: 12px; font-weight: 800; font-size: 18px; letter-spacing: .08em; text-transform: uppercase; background: rgba(255,255,255,.85); white-space: nowrap; text-align: center; line-height: 1.2; }
.stamp small { display: block; font-size: 11px; letter-spacing: .02em; color: inherit !important; margin: 0 !important; }
.stamp.usado { color: #334155; } .stamp.vencido { color: #b45309; } .stamp.anulado { color: #be123c; }
.qrcard .live-bar { height: 4px; border-radius: 4px; margin: 12px auto 0; width: 60%; background: linear-gradient(90deg, var(--brand), var(--brand2), var(--brand)); background-size: 200% 100%; animation: slide 2s linear infinite; }
@keyframes slide { to { background-position: -200% 0; } }
.kv { margin-top: 14px; background: var(--s1); border: 1px solid var(--ln); border-radius: 22px; padding: 4px 16px; }
.kv div { display: flex; justify-content: space-between; gap: 12px; padding: 11px 0; border-bottom: 1px solid var(--ln); font-size: 14px; }
.kv div:last-child { border-bottom: 0; }
.kv span { color: var(--mu); } .kv b { text-align: right; font-weight: 700; }
.grid2 { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; margin-top: 14px; }
.tile { display: flex; flex-direction: column; gap: 8px; align-items: flex-start; padding: 14px; border-radius: 18px; background: var(--s1); border: 1px solid var(--ln); font-size: 13.5px; font-weight: 700; text-align: left; }
.tile .ic-i { width: 22px; height: 22px; color: color-mix(in srgb, var(--brand) 65%, #fff); }
.tile.warn .ic-i { color: #fbbf24; }
.tile small { font-weight: 500; color: var(--mu); font-size: 12px; }

/* Ticket impreso (papel térmico) */
.paper { position: relative; margin: 6px auto 0; width: 290px; background: #fdfdfb; color: #111; font-family: var(--mono); font-size: 12.5px; padding: 20px 20px 26px; box-shadow: 0 20px 40px rgba(0,0,0,.45); --tooth: radial-gradient(circle at 6px 0, transparent 6px, #fdfdfb 6.5px); }
.paper::after { content: ''; position: absolute; left: 0; right: 0; bottom: -10px; height: 10px; background: var(--tooth); background-size: 12px 10px; }
.paper .p-logo { display: flex; flex-direction: column; align-items: center; gap: 6px; font-family: var(--font); }
.paper .p-logo img, .paper .p-logo .logo-fallback { width: 54px; height: 54px; object-fit: contain; filter: grayscale(1) contrast(1.2); }
.paper .p-logo b { font-size: 14px; letter-spacing: .06em; }
.paper hr { border: 0; border-top: 1.5px dashed #999; margin: 12px 0; }
.paper .pl { display: flex; justify-content: space-between; gap: 8px; line-height: 1.7; }
.paper .big { font-size: 17px; font-weight: 800; text-align: center; margin: 4px 0; font-family: var(--font); }
.paper .pq { width: 150px; height: 150px; margin: 10px auto 6px; }
.paper .pq svg { width: 100%; height: 100%; }
.paper .ctr { text-align: center; font-size: 11px; color: #444; }
.paper .void { position: absolute; inset: 0; display: grid; place-items: center; background: rgba(253,253,251,.6); }
.paper .void span { transform: rotate(-18deg); border: 3px solid #be123c; color: #be123c; padding: 8px 14px; font-weight: 800; font-family: var(--font); text-align: center; border-radius: 10px; background: rgba(255,255,255,.9); }

/* Pase de billetera */
.pass { border-radius: 24px; overflow: hidden; background: linear-gradient(160deg, var(--brand), color-mix(in srgb, var(--brand) 45%, #050913)); box-shadow: 0 24px 50px rgba(0,0,0,.5); }
.pass-top { display: flex; align-items: center; gap: 10px; padding: 16px 18px; }
.pass-top img, .pass-top .logo-fallback { width: 38px; height: 38px; object-fit: contain; background: rgba(255,255,255,.95); border-radius: 10px; padding: 3px; }
.pass-top b { font-size: 15px; } .pass-top span { margin-left: auto; text-align: right; font-size: 11px; opacity: .8; }
.pass-top span strong { display: block; font-size: 16px; opacity: 1; }
.pass-mid { display: flex; justify-content: space-between; align-items: flex-end; padding: 6px 18px 14px; }
.pass-mid em { display: block; font-style: normal; font-size: 11px; opacity: .75; text-transform: uppercase; letter-spacing: .06em; }
.pass-mid strong { font-size: 30px; font-weight: 800; letter-spacing: -.02em; }
.pass-mid .ic-i { width: 24px; height: 24px; margin-bottom: 8px; opacity: .8; }
.pass-f { display: grid; grid-template-columns: repeat(3, 1fr); gap: 10px; padding: 0 18px 16px; }
.pass-f em { display: block; font-style: normal; font-size: 10.5px; opacity: .75; text-transform: uppercase; letter-spacing: .05em; }
.pass-f b { font-size: 14.5px; }
.pass-qr { background: #fff; padding: 18px; display: grid; place-items: center; }
.pass-qr .qr { width: 150px; height: 150px; } .pass-qr .qr svg { width: 100%; height: 100%; }
.pass-qr small { color: #475569; font-family: var(--mono); margin-top: 6px; font-size: 12px; }

/* Tarjeta CTM */
.ctm-card { position: relative; width: 100%; aspect-ratio: 1.586; border-radius: 22px; padding: 18px 20px; color: #fff; overflow: hidden; text-align: left; display: flex; flex-direction: column; background: radial-gradient(200px 160px at 100% 100%, color-mix(in srgb, var(--brand2) 45%, transparent), transparent 70%), linear-gradient(135deg, #0c2a6b, var(--brand)); box-shadow: 0 16px 36px rgba(0,0,0,.4); }
.ctm-card::before { content: ''; position: absolute; left: 0; right: 0; bottom: 0; height: 5px; background: linear-gradient(90deg, #fcd116 0 33%, #034ea2 33% 66%, #ed1c24 66%); }
.ctm-card .cc-top { display: flex; justify-content: space-between; align-items: center; }
.ctm-card .cc-top img, .ctm-card .cc-top .logo-fallback { width: 44px; height: 44px; object-fit: contain; }
.ctm-card .cc-top .ic-i { width: 26px; height: 26px; opacity: .85; }
.ctm-card .cc-num { margin-top: auto; font-family: var(--mono); font-size: 19px; letter-spacing: .14em; }
.ctm-card .cc-foot { display: flex; justify-content: space-between; align-items: flex-end; margin-top: 6px; font-size: 12px; }
.ctm-card .cc-foot b { display: block; font-size: 14px; }
.ctm-card.off { filter: grayscale(.85) brightness(.7); }
.ctm-card .cc-st { position: absolute; right: 16px; top: 64px; }
.cards-list { display: flex; flex-direction: column; gap: 14px; }

/* Formularios */
.field { display: block; margin-bottom: 12px; }
.field span { display: block; font-size: 12.5px; font-weight: 700; color: var(--mu); margin-bottom: 6px; }
.field input, .field select, .field textarea { width: 100%; height: 50px; padding: 0 14px; border-radius: 15px; background: var(--s2); border: 1.5px solid transparent; color: var(--tx); outline: 0; font-size: 15px; transition: border-color .2s; }
.field textarea { height: 96px; padding: 12px 14px; resize: none; }
.field input:focus, .field select:focus, .field textarea:focus { border-color: var(--brand); }
.field.err input { border-color: #fb7185; }
.field small { display: block; margin-top: 5px; font-size: 12px; color: #fb7185; }
.check { display: flex; gap: 11px; align-items: flex-start; padding: 10px 0; font-size: 13.5px; color: var(--mu); cursor: pointer; }
.check input { width: 20px; height: 20px; accent-color: var(--brand); flex: none; margin-top: 1px; }
.check b { color: var(--tx); }
.otp { display: flex; gap: 8px; justify-content: center; margin: 18px 0 10px; }
.otp input { width: 46px; height: 58px; border-radius: 15px; background: var(--s2); border: 1.5px solid transparent; text-align: center; font-size: 24px; font-weight: 800; color: var(--tx); outline: 0; }
.otp input:focus { border-color: var(--brand); }

/* Recargar */
.amounts { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; }
.amounts button { height: 58px; border-radius: 18px; background: var(--s2); font-size: 19px; font-weight: 800; border: 1.5px solid transparent; }
.amounts button.on { border-color: var(--brand); background: color-mix(in srgb, var(--brand) 18%, var(--s2)); }
.amt-big { text-align: center; margin: 8px 0 18px; }
.amt-big span { font-size: 13px; color: var(--mu); }
.amt-big div { display: flex; align-items: center; justify-content: center; gap: 16px; margin-top: 4px; }
.amt-big b { font-size: 54px; font-weight: 800; letter-spacing: -.03em; font-variant-numeric: tabular-nums; min-width: 170px; }
.amt-big b small { font-size: 30px; opacity: .6; }
.amt-big button { width: 44px; height: 44px; border-radius: 50%; background: var(--s2); display: grid; place-items: center; }
.opt { display: flex; align-items: center; gap: 12px; width: 100%; padding: 13px; border-radius: 18px; background: var(--s1); border: 1.5px solid var(--ln); text-align: left; }
.opt > .ic-i { width: 42px; height: 42px; padding: 10px; border-radius: 14px; background: var(--s3); flex: none; }
.opt .tx { flex: 1; } .opt .tx b { display: block; font-size: 14.5px; } .opt .tx span { font-size: 12.5px; color: var(--mu); }
.opt .radio { width: 22px; height: 22px; border-radius: 50%; border: 2px solid var(--mu); flex: none; }
.opt.on { border-color: var(--brand); background: color-mix(in srgb, var(--brand) 10%, var(--s1)); }
.opt.on .radio { border: 7px solid var(--brand); }
.steps { display: flex; gap: 6px; margin: 2px 0 16px; }
.steps i { flex: 1; height: 4px; border-radius: 4px; background: var(--s3); }
.steps i.on { background: var(--brand); }
.spinner { width: 74px; height: 74px; margin: 70px auto 20px; border-radius: 50%; border: 6px solid var(--s3); border-top-color: var(--brand); animation: spin .8s linear infinite; }
@keyframes spin { to { transform: rotate(360deg); } }
.result { text-align: center; padding: 30px 6px 0; }
.result .big-ic { width: 104px; height: 104px; margin: 0 auto 18px; border-radius: 50%; display: grid; place-items: center; }
.result .big-ic .ic-i { width: 50px; height: 50px; }
.result .big-ic.ok { background: rgba(34,197,94,.15); color: #4ade80; box-shadow: 0 0 0 12px rgba(34,197,94,.06); }
.result .big-ic.bad { background: rgba(244,63,94,.15); color: #fb7185; box-shadow: 0 0 0 12px rgba(244,63,94,.06); }
.result .big-ic.warn { background: rgba(251,191,36,.15); color: #fbbf24; box-shadow: 0 0 0 12px rgba(251,191,36,.06); }
.result h3 { font-size: 24px; font-weight: 800; letter-spacing: -.02em; }
.result p { color: var(--mu); margin: 8px auto 0; max-width: 300px; font-size: 14.5px; }
.code-box { margin: 18px auto 0; padding: 16px; border-radius: 20px; background: #fff; color: #0b1222; max-width: 260px; }
.code-box b { display: block; font-family: var(--mono); font-size: 28px; letter-spacing: .12em; }
.code-box span { font-size: 12px; color: #64748b; }

/* Perfil y ajustes */
.prof { display: flex; align-items: center; gap: 14px; padding: 16px; border-radius: 24px; background: var(--s1); border: 1px solid var(--ln); }
.prof .av { width: 58px; height: 58px; font-size: 20px; }
.prof b { display: block; font-size: 18px; } .prof span { font-size: 12.5px; color: var(--mu); display: block; }
.prof .tags { display: flex; gap: 6px; margin-top: 6px; flex-wrap: wrap; }
.menu { background: var(--s1); border: 1px solid var(--ln); border-radius: 22px; overflow: hidden; }
.menu > button, .menu > div, .menu > label { display: flex; align-items: center; gap: 12px; width: 100%; padding: 13px 14px; text-align: left; border-bottom: 1px solid var(--ln); font-size: 14.5px; font-weight: 600; cursor: pointer; }
.menu > :last-child { border-bottom: 0; }
.menu .ic-i:first-child { width: 36px; height: 36px; padding: 8px; border-radius: 11px; background: var(--s3); color: #c7d2fe; }
.menu .tx { flex: 1; min-width: 0; } .menu .tx small { display: block; font-size: 12px; color: var(--mu); font-weight: 500; }
.menu .chev { color: var(--mu); width: 18px; height: 18px; }
.menu .danger { color: #fb7185; } .menu .danger .ic-i:first-child { color: #fb7185; background: rgba(244,63,94,.12); }
.timeline { position: relative; padding-left: 30px; margin: 8px 0; }
.timeline::before { content: ''; position: absolute; left: 11px; top: 8px; bottom: 8px; width: 2px; background: var(--s3); }
.timeline div { position: relative; padding: 4px 0 16px; }
.timeline div::before { content: ''; position: absolute; left: -26px; top: 6px; width: 16px; height: 16px; border-radius: 50%; background: var(--s3); box-shadow: 0 0 0 4px var(--bg); }
.timeline div.done::before { background: #22c55e; } .timeline div.cur::before { background: #fbbf24; animation: pulse 1.6s infinite; }
@keyframes pulse { 50% { box-shadow: 0 0 0 4px var(--bg), 0 0 0 9px rgba(251,191,36,.25); } }
.timeline b { display: block; font-size: 14.5px; } .timeline span { font-size: 12.5px; color: var(--mu); }
.faq { background: var(--s1); border: 1px solid var(--ln); border-radius: 18px; margin-bottom: 8px; overflow: hidden; }
.faq summary { list-style: none; padding: 14px 16px; font-weight: 700; font-size: 14.5px; cursor: pointer; display: flex; justify-content: space-between; gap: 10px; }
.faq summary::-webkit-details-marker { display: none; }
.faq summary .ic-i { transition: transform .25s; color: var(--mu); }
.faq[open] summary .ic-i { transform: rotate(180deg); }
.faq p { padding: 0 16px 14px; font-size: 13.5px; color: var(--mu); }
.method { display: flex; gap: 12px; align-items: center; padding: 14px; border-radius: 20px; background: var(--s1); border: 1px solid var(--ln); margin-bottom: 8px; }
.method > .ic-i { width: 46px; height: 46px; padding: 11px; border-radius: 15px; background: var(--s3); flex: none; color: #c7d2fe; }
.method .tx { flex: 1; } .method .tx b { display: block; } .method .tx span { font-size: 12.5px; color: var(--mu); }
.consent-doc { font-size: 13.5px; color: var(--mu); }
.consent-doc h4 { color: var(--tx); font-size: 14.5px; margin: 14px 0 4px; }
.consent-doc ul { padding-left: 18px; } .consent-doc li { margin: 3px 0; }
.myqr { background: #fff; border-radius: 30px; padding: 26px; text-align: center; color: #0f172a; }
.myqr .qr { width: 220px; height: 220px; margin: 0 auto; } .myqr .qr svg { width: 100%; height: 100%; }
.myqr .ring { width: 100%; height: 5px; border-radius: 5px; background: #e2e8f0; margin-top: 14px; overflow: hidden; }
.myqr .ring i { display: block; height: 100%; background: var(--brand); transition: width 1s linear; }
.myqr small { display: block; margin-top: 8px; color: #64748b; font-size: 12.5px; }
.chat { display: flex; flex-direction: column; gap: 8px; }
.chat p { max-width: 82%; padding: 10px 13px; border-radius: 18px; font-size: 13.5px; background: var(--s2); }
.chat p.me { align-self: flex-end; background: var(--brand); }

/* Onboarding */
.onb { min-height: 100%; display: flex; flex-direction: column; padding: 0 22px 30px; }
.onb-art { height: 330px; margin: 0 -22px; position: relative; display: grid; place-items: center; overflow: hidden; }
.onb-art .orb { position: absolute; width: 300px; height: 300px; border-radius: 50%; background: radial-gradient(closest-side, color-mix(in srgb, var(--brand) 45%, transparent), transparent); }
.onb-art .big { position: relative; width: 150px; height: 150px; border-radius: 44px; display: grid; place-items: center; background: linear-gradient(135deg, var(--brand), color-mix(in srgb, var(--brand) 40%, #0a0f1f)); box-shadow: 0 30px 60px color-mix(in srgb, var(--brand) 40%, transparent); }
.onb-art .big .ic-i { width: 70px; height: 70px; }
.onb-art .big img, .onb-art .big .logo-fallback { width: 110px; height: 110px; object-fit: contain; }
.onb-art .sat { position: absolute; width: 54px; height: 54px; border-radius: 18px; display: grid; place-items: center; background: var(--s2); border: 1px solid var(--ln); animation: float 4s ease-in-out infinite; }
.onb-art .sat .ic-i { width: 24px; height: 24px; color: #c7d2fe; }
@keyframes float { 50% { transform: translateY(-10px); } }
.onb h2 { font-size: 28px; font-weight: 800; letter-spacing: -.025em; line-height: 1.12; }
.onb p { color: var(--mu); margin-top: 10px; font-size: 15px; }
.dots { display: flex; gap: 6px; margin: 22px 0; }
.dots i { width: 8px; height: 8px; border-radius: 4px; background: var(--s3); transition: width .3s; }
.dots i.on { width: 26px; background: var(--brand); }
.onb .btns { margin-top: auto; }
.link { color: color-mix(in srgb, var(--brand) 70%, #fff); font-weight: 700; font-size: 14px; text-align: center; padding: 8px; }

/* Hoja inferior */
.sheet-bg { position: absolute; inset: 0; z-index: 80; background: rgba(0,0,0,.55); opacity: 0; pointer-events: none; transition: opacity .3s; }
.sheet-bg.show { opacity: 1; pointer-events: auto; }
.sheet { position: absolute; left: 0; right: 0; bottom: 0; z-index: 81; background: #121822; border-radius: 30px 30px 0 0; padding: 10px 20px 30px; transform: translateY(105%); transition: transform .4s var(--ease); max-height: 86%; overflow-y: auto; scrollbar-width: none; }
.sheet.show { transform: none; }
.sheet::before { content: ''; display: block; width: 40px; height: 5px; border-radius: 3px; background: var(--s3); margin: 0 auto 14px; }
.sheet h3 { font-size: 20px; font-weight: 800; margin-bottom: 6px; }
.sheet > p { color: var(--mu); font-size: 14px; }
.sheet .big-ic { width: 64px; height: 64px; border-radius: 22px; display: grid; place-items: center; margin-bottom: 12px; }
.sheet .big-ic .ic-i { width: 30px; height: 30px; }

/* Botón demo en móvil */
.demo-fab { display: none; }
.demo-sheet { display: none; }

@media (max-width: 1180px) { .stage { grid-template-columns: minmax(260px, 340px) auto; } .jump-col { display: none; } }
@media (max-width: 820px) {
  .stage { display: block; padding: 0; }
  .side { display: none; }
  .phone { width: 100%; height: 100vh; height: 100dvh; min-height: 0; border-radius: 0; padding: 0; background: none; box-shadow: none; }
  .screen { border-radius: 0; }
  .island { display: none; }
  .sbar { height: max(env(safe-area-inset-top), 10px); padding: 0; overflow: hidden; opacity: 0; }
  .nav { bottom: max(12px, env(safe-area-inset-bottom)); }
  body[data-view="app"] .demo-bar { display: none; }
  .demo-fab { display: grid; place-items: center; position: fixed; z-index: 200; right: 12px; top: max(10px, env(safe-area-inset-top)); width: 40px; height: 40px; border-radius: 50%; background: rgba(23,30,41,.9); border: 1px solid rgba(255,255,255,.12); color: #fff; backdrop-filter: blur(10px); }
  .demo-sheet.show { display: block; position: fixed; inset: 0; z-index: 300; background: rgba(5,9,19,.97); overflow-y: auto; padding: 20px 18px 40px; }
  .demo-sheet .side { display: block; }
  .demo-sheet .jump { max-height: none; }
  .hdr { padding-right: 60px; }
  .hdr h2 { margin-right: 0; }
}
