/* Mi IPTV — diseño 10-foot para LG webOS (1920x1080)
   Reglas: el foco se mueve al instante (acciones de teclado = sin animación),
   solo se animan transform/opacity, y solo en overlays y toasts. */
:root {
  --bg: #07090d;
  --s1: #0f131b;
  --s2: #181d29;
  --s3: #262d3d;
  --tx: #f4f6fa;
  --tx2: #a7b0c0;
  --tx3: #687186;
  --ac: #ff5c39;
  --gold: #ffc94d;
  --ease: cubic-bezier(.23, 1, .32, 1);
}
* { box-sizing: border-box; margin: 0; padding: 0; }
html { background: var(--bg); overflow: hidden; }
html, body {
  width: var(--W, 1920px); height: var(--H, 1080px); overflow: hidden;
  background: var(--bg); color: var(--tx);
  font-family: "LG Smart UI", "Museo Sans", Roboto, "Segoe UI", system-ui, sans-serif;
  font-size: 28px; line-height: 1.3;
  -webkit-font-smoothing: antialiased; user-select: none;
}
#app { position: absolute; inset: 0; }
.screen {
  position: absolute; inset: 0; z-index: 1;
  background: radial-gradient(1400px 700px at 92% -20%, rgba(255, 92, 57, .10), transparent 60%), var(--bg);
}
.screen.hidden { display: none; }
.screen.player { z-index: 60; background: none; }

/* ---------- Video global ---------- */
#video { position: fixed; display: none; background: #000; object-fit: contain; }
body[data-player=preview] #video { display: block; left: calc(var(--cw, 1688px) - 468px); top: 160px; width: 636px; height: 358px; border-radius: 20px; z-index: 5; }
body[data-player=full] #video { display: block; left: 0; top: 0; width: var(--W, 1920px); height: var(--H, 1080px); z-index: 50; }

/* ---------- Splash / toast ---------- */
#splash { position: fixed; inset: 0; z-index: 200; background: var(--bg); display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 28px; transition: opacity 300ms ease; }
#splash.out { opacity: 0; pointer-events: none; }
.splash-t { font-size: 48px; font-weight: 800; letter-spacing: -1px; }
#toast {
  position: fixed; left: 50%; bottom: 72px; z-index: 300;
  background: var(--tx); color: var(--bg); font-weight: 600;
  padding: 18px 40px; border-radius: 999px; white-space: nowrap;
  opacity: 0; transform: translate(-50%, 16px);
  transition: opacity 200ms var(--ease), transform 200ms var(--ease);
}
#toast.show { opacity: 1; transform: translate(-50%, 0); }

/* ---------- Marca ---------- */
.brand { width: 56px; height: 56px; border-radius: 50%; background: var(--ac); display: grid; place-items: center; font-weight: 800; font-size: 22px; color: #fff; flex: none; }
.brand.big { width: 120px; height: 120px; font-size: 44px; }
.wordmark { font-size: 56px; font-weight: 800; letter-spacing: -1.5px; }
.wordmark span { color: var(--ac); }

/* ---------- Iconos ---------- */
.ico { display: inline-block; flex: none; }
.ico svg { width: 34px; height: 34px; display: block; fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }

/* ---------- Shell ---------- */
.side { position: absolute; left: 0; top: 0; bottom: 0; width: 112px; z-index: 20; padding-top: 48px; }
.side::before { content: ""; position: absolute; top: 0; bottom: 0; left: 0; width: 460px; background: linear-gradient(90deg, rgba(7, 9, 13, .98) 62%, rgba(7, 9, 13, 0)); opacity: 0; transition: opacity 180ms var(--ease); pointer-events: none; }
.side.open::before { opacity: 1; }
.side .brand { position: relative; margin: 0 0 56px 28px; }
.mi { position: relative; display: flex; align-items: center; gap: 26px; width: 80px; height: 76px; margin: 6px 16px; padding: 0 23px; border-radius: 18px; color: var(--tx3); white-space: nowrap; overflow: hidden; }
.mi.cur { color: var(--tx); }
.mi.cur::before { content: ""; position: absolute; left: 4px; top: 24px; bottom: 24px; width: 5px; border-radius: 3px; background: var(--ac); }
.side.open .mi { width: 350px; }
.mi .lbl { font-size: 30px; font-weight: 600; opacity: 0; transition: opacity 150ms var(--ease); }
.side.open .mi .lbl { opacity: 1; }
.side.open .mi.sel { background: var(--tx); color: var(--bg); }
.side.open .mi.sel::before { display: none; }
.hdr { position: absolute; left: 168px; right: 64px; top: 46px; height: 76px; display: flex; align-items: center; justify-content: space-between; }
.hdr h1 { font-size: 52px; font-weight: 800; letter-spacing: -1.5px; }
.clock { font-size: 34px; color: var(--tx2); font-variant-numeric: tabular-nums; }
.content { position: absolute; left: 168px; top: 160px; width: var(--cw, 1688px); height: var(--ch, 880px); }
.sec { position: absolute; inset: 0; }

/* ---------- Paneles virtualizados ---------- */
.pane { position: absolute; top: 0; overflow: hidden; }
.track { position: absolute; left: 0; top: 0; width: 100%; will-change: transform; }
.item { position: absolute; left: 0; top: 0; }
.item.sel { z-index: 2; }
.msg { position: absolute; inset: 0; display: grid; place-items: center; padding: 40px; text-align: center; color: var(--tx3); font-size: 30px; }

/* Filas */
.row { display: flex; align-items: center; gap: 22px; height: calc(100% - 8px); padding: 0 24px; border-radius: 16px; color: var(--tx2); font-size: 30px; }
.row .name { flex: 1; min-width: 0; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.item.sel > .row { background: var(--s2); color: var(--tx); }
.pane.active .item.sel > .row { background: var(--tx); color: var(--bg); }
.chan .num { width: 70px; flex: none; color: var(--tx3); font-size: 26px; font-variant-numeric: tabular-nums; }
.pane.active .item.sel .chan .num { color: rgba(7, 9, 13, .55); }
.star { color: var(--gold); font-size: 28px; }
.pane.active .item.sel .star { color: #c98a00; }

/* Logos */
/* Logos de canal: chicos y sobrios, el logo del proveedor contenido sin deformar */
.logo { position: relative; width: 64px; height: 40px; flex: none; border-radius: 8px; background: rgba(255, 255, 255, .045); overflow: hidden; display: grid; place-items: center; }
.logo img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: contain; padding: 4px; }
.logo.has-img { background: transparent; }
.pane.active .item.sel .logo { background: rgba(7, 9, 13, .9); }
.logo.tall { width: 62px; height: 92px; }
.logo.tall img, .logo.thumb img { object-fit: cover; padding: 0; }
.logo.lg { width: 112px; height: 70px; border-radius: 12px; }
.logo.lg img { padding: 8px; }
.logo.xl { width: 136px; height: 84px; border-radius: 14px; }
.logo.xl img { padding: 8px; }
.logo.thumb { width: 192px; height: 108px; }
.ph { font-weight: 800; color: var(--tx3); font-size: 20px; letter-spacing: 1px; }
.logo.lg .ph, .logo.xl .ph { font-size: 26px; }
.has-img > .ph { display: none; }

/* Tarjetas (pósters) */
.card { width: 100%; height: 100%; }
.poster { position: relative; width: 186px; height: 279px; border-radius: 14px; background: var(--s2); overflow: hidden; display: grid; place-items: center; }
.poster img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.poster .ph { font-size: 56px; }
.pane.active .item.sel .poster { transform: scale(1.07); box-shadow: 0 0 0 5px var(--tx), 0 20px 40px rgba(0, 0, 0, .55); }
.card .ttl { margin-top: 14px; font-size: 23px; line-height: 1.25; color: var(--tx2); max-height: 58px; overflow: hidden; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; }
.pane.active .item.sel .ttl { color: var(--tx); }
.badge { position: absolute; top: 10px; right: 10px; padding: 2px 9px; border-radius: 8px; background: rgba(0, 0, 0, .72); color: var(--gold); font-size: 20px; font-weight: 700; }
.fav-dot { position: absolute; top: 8px; left: 10px; color: var(--gold); font-size: 26px; text-shadow: 0 1px 6px rgba(0, 0, 0, .8); }
.bar { height: 6px; border-radius: 3px; background: var(--s3); overflow: hidden; }
.bar i { display: block; width: 0; height: 100%; background: var(--ac); }
.bar.mini { position: absolute; left: 10px; right: 10px; bottom: 10px; height: 5px; background: rgba(255, 255, 255, .25); }

/* ---------- TV en vivo ---------- */
.p-cats { left: 0; width: 380px; height: 880px; }
.live .p-chans { left: 412px; width: calc(var(--cw, 1688px) - 1088px); height: 880px; }
.preview { position: absolute; left: calc(var(--cw, 1688px) - 636px); top: 0; width: 636px; height: 880px; }
.pv-box { width: 636px; height: 358px; border-radius: 20px; background: var(--s1); display: grid; place-items: center; color: var(--tx3); }
.pv-meta { margin-top: 32px; }
.pv-head { display: flex; align-items: center; gap: 24px; }
.pv-t { min-width: 0; }
.pv-num { color: var(--ac); font-size: 24px; font-weight: 700; }
.pv-name { font-size: 38px; font-weight: 800; line-height: 1.12; letter-spacing: -.5px; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.preview .hints { position: absolute; left: 0; bottom: 0; }
.epg { margin-top: 28px; }
.epg-lbl { font-size: 20px; font-weight: 800; letter-spacing: 2px; color: var(--ac); }
.epg-title { font-size: 32px; font-weight: 700; margin-top: 6px; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.epg-time { font-size: 24px; color: var(--tx2); margin-top: 4px; font-variant-numeric: tabular-nums; }
.epg .bar { margin-top: 14px; }
.epg-desc { margin-top: 16px; font-size: 24px; line-height: 1.45; color: var(--tx2); display: -webkit-box; -webkit-line-clamp: 4; -webkit-box-orient: vertical; overflow: hidden; }
.epg-next { margin-top: 24px; display: flex; gap: 16px; align-items: baseline; font-size: 26px; color: var(--tx2); white-space: nowrap; overflow: hidden; }
.epg-next .epg-lbl { color: var(--tx3); }
.epg-ntitle { overflow: hidden; text-overflow: ellipsis; }
.epg-none { color: var(--tx3); font-size: 26px; }

/* ---------- Catálogo (películas / series) ---------- */
.p-grid { left: 396px; width: calc(var(--cw, 1688px) - 396px); height: 880px; }

/* ---------- Mis listas / búsqueda / cuenta ---------- */
.p-items { left: 412px; width: calc(var(--cw, 1688px) - 412px); height: 880px; }
.lr-main { flex: 1; min-width: 0; }
.lr-main .name { display: block; }
.lr-sub { font-size: 22px; color: var(--tx3); margin-top: 2px; }
.pane.active .item.sel .lr-sub { color: rgba(7, 9, 13, .6); }
.lr-main .bar { margin-top: 10px; width: 420px; }
.tag { font-size: 20px; font-weight: 700; padding: 4px 14px; border-radius: 999px; background: var(--s3); color: var(--tx2); }
.pane.active .item.sel .tag { background: rgba(7, 9, 13, .12); color: var(--bg); }
.sbox { position: absolute; left: 0; top: 0; width: 1260px; height: 104px; display: flex; align-items: center; gap: 22px; padding: 0 32px; border-radius: 20px; background: var(--s1); border: 4px solid transparent; color: var(--tx3); }
.sbox.sel { border-color: var(--tx); color: var(--tx); }
.sbox input { flex: 1; height: 100%; background: none; border: 0; outline: 0; color: var(--tx); font: inherit; font-size: 36px; }
.sbox input::placeholder { color: var(--tx3); }
.p-res { left: 0; top: 236px; width: 1260px; height: 644px; }
.p-chips { left: -8px; top: 120px; width: 1000px; height: 92px; }
.chip { height: 100%; border-radius: 999px; background: var(--s1); color: var(--tx2); display: grid; place-items: center; font-size: 26px; font-weight: 700; border: 3px solid transparent; }
.chip.on { border-color: var(--ac); color: var(--tx); }
.pane.active .item.sel .chip { background: var(--tx); color: var(--bg); border-color: var(--tx); }
.acc-card { position: absolute; left: 0; top: 0; width: 800px; padding: 40px 48px; border-radius: 24px; background: var(--s1); }
.acc-row { display: flex; justify-content: space-between; gap: 32px; padding: 18px 0; border-bottom: 2px solid var(--s2); }
.acc-row:last-child { border-bottom: 0; }
.acc-row .k { color: var(--tx3); }
.acc-row .v { font-weight: 600; text-align: right; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.p-acts { left: 860px; width: 720px; height: 660px; }
.account .acc-del { position: absolute; left: 860px; top: 720px; width: 720px; height: 84px; background: transparent; border: 3px solid rgba(255, 92, 57, .5); color: #ff7b61; font-size: 28px; }
.account .acc-del.sel { background: #ff5c39; border-color: #ff5c39; color: #fff; }
.act .val { color: var(--ac); font-weight: 700; }
.pane.active .item.sel .act .val { color: #c2391b; }
.ver { position: absolute; left: 0; bottom: 0; color: var(--tx3); font-size: 22px; }

/* ---------- Ayudas de teclas ---------- */
.hints { display: flex; gap: 36px; margin-top: 36px; font-size: 23px; color: var(--tx2); }
.hint { display: flex; align-items: center; gap: 12px; white-space: nowrap; }
.kb { min-width: 46px; height: 36px; padding: 0 10px; border-radius: 8px; background: rgba(255, 255, 255, .14); display: inline-grid; place-items: center; font-size: 20px; font-weight: 800; color: var(--tx); }
.kb.y { min-width: 34px; width: 34px; height: 34px; padding: 0; border-radius: 50%; background: var(--gold); }

/* ---------- Detalle ---------- */
.detail .bg { position: absolute; inset: 0; background-size: cover; background-position: center top; opacity: .38; }
.detail .shade { position: absolute; inset: 0; background: linear-gradient(90deg, var(--bg) 28%, rgba(7, 9, 13, .7) 62%, rgba(7, 9, 13, .25)), linear-gradient(0deg, var(--bg) 4%, transparent 55%); }
.d-poster { position: absolute; left: 120px; top: 150px; width: 400px; height: 600px; border-radius: 22px; overflow: hidden; background: var(--s2); display: grid; place-items: center; box-shadow: 0 30px 60px rgba(0, 0, 0, .6); }
.d-poster img, .s-cover img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.d-poster .ph { font-size: 96px; }
.d-info { position: absolute; left: 600px; top: 160px; width: 1180px; }
.d-title { font-size: 72px; font-weight: 800; letter-spacing: -2px; line-height: 1.05; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.d-meta { margin-top: 22px; font-size: 28px; color: var(--tx2); font-variant-numeric: tabular-nums; }
.d-genre { margin-top: 10px; font-size: 26px; color: var(--tx3); }
.d-plot { margin-top: 28px; font-size: 30px; line-height: 1.5; color: var(--tx2); display: -webkit-box; -webkit-line-clamp: 6; -webkit-box-orient: vertical; overflow: hidden; }
.p-btns { left: 592px; top: 812px; width: 1240px; height: 108px; }
.btn { height: 100%; border-radius: 999px; background: var(--s2); color: var(--tx); display: flex; align-items: center; justify-content: center; font-size: 30px; font-weight: 700; white-space: nowrap; padding: 0 24px; }
.pane.active .item.sel .btn, .btn.sel { background: var(--tx); color: var(--bg); }
.s-cover { position: absolute; left: 120px; top: 80px; width: 220px; height: 330px; border-radius: 18px; overflow: hidden; background: var(--s2); display: grid; place-items: center; box-shadow: 0 24px 48px rgba(0, 0, 0, .55); }
.s-info { position: absolute; left: 392px; top: 92px; width: 1400px; }
.s-info .d-title { font-size: 64px; -webkit-line-clamp: 1; }
.s-plot { -webkit-line-clamp: 3; font-size: 28px; margin-top: 20px; }
.p-seasons { left: 112px; top: 462px; width: 336px; height: 576px; }
.p-eps { left: 464px; top: 462px; width: calc(var(--W, 1920px) - 576px); height: 576px; }
.ep { gap: 28px; }
.ep-main { flex: 1; min-width: 0; }
.ep-main .name { display: block; }
.ep-main .bar { margin-top: 10px; width: 360px; }
.series .hints { margin-top: 24px; }

/* ---------- Login ---------- */
.login { display: grid; place-items: center; }
.lg-card { width: 820px; display: flex; flex-direction: column; align-items: center; }
.lg-card h1 { margin-top: 28px; font-size: 60px; font-weight: 800; letter-spacing: -1.5px; }
.lg-sub { margin: 8px 0 40px; color: var(--tx2); font-size: 30px; }
.fld { width: 100%; display: block; margin-bottom: 16px; }
.login .fld input { height: 76px; }
.fl { display: block; font-size: 22px; font-weight: 700; letter-spacing: 1px; color: var(--tx3); margin: 0 0 8px 8px; text-transform: uppercase; }
.fld input { width: 100%; height: 88px; padding: 0 28px; border-radius: 18px; background: var(--s1); border: 4px solid transparent; outline: 0; color: var(--tx); font: inherit; font-size: 34px; }
.fld input::placeholder { color: var(--tx3); }
.fld.sel input { border-color: var(--tx); }
.fld input:focus { border-color: var(--ac); }
.login .btn { width: 100%; height: 92px; margin-top: 18px; background: var(--ac); color: #fff; }
.login .btn.sel { background: var(--tx); color: var(--bg); }
.login .btn.busy { opacity: .6; }
.lg-status { min-height: 40px; margin-top: 22px; color: var(--ac); font-size: 28px; font-weight: 600; text-align: center; }
.lg-tip { white-space: pre-line; margin-top: 18px; color: var(--tx3); font-size: 23px; text-align: center; line-height: 1.5; }

/* ---------- Reproductor ---------- */
.ov { position: absolute; left: 0; right: 0; bottom: 0; padding: 200px 96px 64px; background: linear-gradient(0deg, rgba(0, 0, 0, .92), rgba(0, 0, 0, .72) 55%, transparent); opacity: 0; transform: translateY(12px); transition: opacity 400ms ease, transform 400ms ease; }
.ov.show { opacity: 1; transform: none; transition-duration: 160ms; transition-timing-function: var(--ease); }
.ov-top { position: absolute; left: 0; right: 0; top: 0; height: 200px; padding: 56px 96px; display: flex; justify-content: flex-end; background: linear-gradient(180deg, rgba(0, 0, 0, .7), transparent); opacity: 0; transition: opacity 400ms ease; }
.ov-top.show { opacity: 1; transition-duration: 160ms; }
.ov-top .clock { color: var(--tx); font-size: 40px; font-weight: 700; }
.lv-row { display: flex; align-items: center; gap: 36px; }
.lv-t { min-width: 0; }
.lv-num { font-size: 40px; font-weight: 800; color: var(--ac); font-variant-numeric: tabular-nums; }
.lv-name { max-width: 1300px; font-size: 60px; font-weight: 800; letter-spacing: -1px; line-height: 1.1; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.lv-fav { margin-left: auto; font-size: 52px; color: var(--gold); }
.epg.wide { max-width: 1400px; margin-top: 36px; }
.epg.wide .epg-title { font-size: 38px; -webkit-line-clamp: 1; }
.epg.wide .epg-desc { -webkit-line-clamp: 2; }
.epg.wide .bar { width: 720px; }
.digits { position: absolute; top: 56px; left: 96px; font-size: 140px; font-weight: 800; font-variant-numeric: tabular-nums; text-shadow: 0 4px 30px rgba(0, 0, 0, .7); opacity: 0; }
.digits.show { opacity: 1; }
.spin { position: absolute; left: 50%; top: 50%; width: 96px; height: 96px; margin: -48px 0 0 -48px; border-radius: 50%; border: 8px solid rgba(255, 255, 255, .18); border-top-color: #fff; display: none; animation: spin 700ms linear infinite; }
.player.loading .spin { display: block; }
@keyframes spin { to { transform: rotate(360deg); } }
.perr { position: absolute; left: 0; right: 0; top: 44%; text-align: center; font-size: 40px; font-weight: 700; text-shadow: 0 2px 20px #000; }
.pause-ico { position: absolute; left: 50%; top: 50%; width: 168px; height: 168px; margin: -84px 0 0 -84px; border-radius: 50%; background: rgba(0, 0, 0, .55); display: none; }
.pause-ico::before, .pause-ico::after { content: ""; position: absolute; top: 52px; width: 18px; height: 64px; border-radius: 4px; background: #fff; }
.pause-ico::before { left: 60px; }
.pause-ico::after { right: 60px; }
.player.paused .pause-ico { display: block; }
.vd-title { font-size: 60px; font-weight: 800; letter-spacing: -1px; }
.vd-sub { margin-top: 8px; font-size: 32px; color: var(--tx2); }
.bar.big { height: 10px; border-radius: 5px; margin-top: 40px; background: rgba(255, 255, 255, .22); }
.vd-times { display: flex; justify-content: space-between; margin-top: 16px; font-size: 28px; color: var(--tx2); font-variant-numeric: tabular-nums; }

/* ---------- v0.3: barra superior (buscar + vistas) ---------- */
.hdr-r { display: flex; align-items: center; gap: 40px; }
.tools { display: flex; align-items: center; gap: 16px; }
.seg { display: flex; border-radius: 999px; background: var(--s1); }
.tb { display: flex; align-items: center; gap: 12px; height: 76px; min-width: 76px; padding: 0 26px; border-radius: 999px; color: var(--tx3); font-size: 24px; font-weight: 700; }
.tb .ico svg { width: 28px; height: 28px; }
.tb.pill { background: var(--s1); color: var(--tx2); }
.seg .tb { height: 76px; padding: 0 24px; }
.hdr { top: 40px; height: 84px; }
.tb.on { background: var(--s3); color: var(--tx); }
.tools.active .tb.sel { background: var(--tx); color: var(--bg); }

/* Cuenta activa en la barra lateral */
.side-acc { position: absolute; left: 30px; bottom: 44px; display: flex; align-items: center; gap: 22px; white-space: nowrap; }
.side-acc .lbl { font-size: 24px; color: var(--tx2); opacity: 0; transition: opacity 150ms var(--ease); }
.side.open .side-acc .lbl { opacity: 1; }
.av { width: 52px; height: 52px; border-radius: 50%; background: var(--s3); display: grid; place-items: center; font-weight: 800; color: #fff; font-size: 20px; flex: none; }
.av.lg { width: 88px; height: 88px; font-size: 32px; }

/* ---------- Filas por categoría (modo grilla) ---------- */
.p-rows { left: 0; width: var(--cw, 1688px); height: 880px; }
.rrow { position: absolute; left: 0; top: 0; width: 100%; }
.rtitle { height: 56px; padding: 6px 0 0 24px; font-size: 30px; font-weight: 700; color: var(--tx3); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; max-width: 1500px; }
.pane.active .rrow.cur .rtitle { color: var(--tx); }
.rtrack { position: absolute; left: 0; will-change: transform; }
.rmsg { position: absolute; left: 24px; padding-top: 40px; color: var(--tx3); font-size: 26px; }
.tile { width: 100%; height: 100%; }
.tile-box { position: relative; width: 236px; height: 140px; border-radius: 16px; background: var(--s1); display: grid; place-items: center; border: 2px solid rgba(255, 255, 255, .04); }
.tile-logo { position: relative; width: 120px; height: 72px; display: grid; place-items: center; }
.tile-logo img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: contain; }
.tile-logo .ph { font-size: 28px; }
.tile-num { position: absolute; left: 14px; top: 10px; font-size: 20px; color: var(--tx3); font-variant-numeric: tabular-nums; }
.tile .ttl { margin-top: 12px; font-size: 23px; line-height: 1.25; color: var(--tx2); max-height: 58px; overflow: hidden; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; }
.pane.active .item.sel .tile-box { transform: scale(1.06); box-shadow: 0 0 0 5px var(--tx), 0 18px 36px rgba(0, 0, 0, .5); background: var(--s2); }
.pane.active .item.sel .tile .ttl { color: var(--tx); }

/* ---------- Selector de cuentas ---------- */
.picker .pk-head { position: absolute; left: 0; right: 0; top: 150px; text-align: center; }
.picker .pk-head h1 { margin-top: 18px; font-size: 44px; font-weight: 700; color: var(--tx2); letter-spacing: -.5px; }
.p-pick { top: 360px; height: 380px; }
.pk-card { height: 100%; border-radius: 26px; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 14px; padding: 0 20px; text-align: center; }
.pk-av { width: 150px; height: 150px; border-radius: 50%; background: var(--s2); color: #fff; display: grid; place-items: center; font-size: 56px; font-weight: 800; margin-bottom: 10px; border: 4px dashed transparent; }
.pk-av:not([style]) { background: transparent; border-color: var(--s3); color: var(--tx3); }
.pk-name { font-size: 32px; font-weight: 700; color: var(--tx2); max-width: 100%; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.pk-sub { font-size: 21px; color: var(--tx3); max-width: 100%; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.pane.active .item.sel .pk-card { background: var(--s2); }
.pane.active .item.sel .pk-av { box-shadow: 0 0 0 6px var(--tx); }
.pane.active .item.sel .pk-name { color: var(--tx); }
.pk-status { position: absolute; left: 0; right: 0; top: 790px; text-align: center; font-size: 28px; color: var(--ac); font-weight: 600; }
.picker > .hints { position: absolute; left: 0; right: 0; bottom: 64px; justify-content: center; }
.login .wordmark { margin-top: 24px; }

/* Cuenta */
.acc-head { display: flex; align-items: center; gap: 28px; padding-bottom: 24px; margin-bottom: 8px; border-bottom: 2px solid var(--s2); }
.acc-name { font-size: 40px; font-weight: 800; }
.act.danger .name { color: #ff7b61; }
.pane.active .item.sel .act.danger { background: #ff5c39; color: #fff; }
.pane.active .item.sel .act.danger .name { color: #fff; }

/* ---------- Ajustes de reproducción ---------- */
.pset { position: absolute; top: 0; right: 0; bottom: 0; width: 720px; padding: 110px 64px; background: linear-gradient(270deg, rgba(7, 9, 13, .97) 72%, rgba(7, 9, 13, 0)); opacity: 0; transform: translateX(24px); transition: opacity 200ms var(--ease), transform 200ms var(--ease); pointer-events: none; }
.pset.show { opacity: 1; transform: none; pointer-events: auto; }
.pset h2 { font-size: 48px; font-weight: 800; letter-spacing: -1px; padding-left: 92px; }
.p-set { left: 152px; top: 210px; width: 568px; height: 400px; }
.setr .name { font-size: 24px; color: var(--tx3); }
.set-val { font-size: 30px; font-weight: 700; margin-top: 4px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.pane.active .item.sel .setr .name { color: rgba(7, 9, 13, .6); }
.pset .hints { position: absolute; left: 152px; top: 770px; }

/* ---------- v0.4 ---------- */
.msg { white-space: pre-line; line-height: 1.5; }
.row .ico svg { width: 26px; height: 26px; }
.row.cat .ico { color: var(--tx3); }
.tag.dead { background: rgba(255, 92, 57, .16); color: #ff8a6b; font-size: 20px; padding: 3px 12px; }
.pane.active .item.sel .tag.dead { background: rgba(255, 92, 57, .22); color: #c2391b; }
.tile-dead { position: absolute; right: 10px; bottom: 10px; }

/* Guía EPG */
.guide .p-gcats { left: 0; width: 300px; height: 880px; }
.g-info { position: absolute; left: 332px; top: 0; width: calc(var(--cw, 1688px) - 332px); height: 150px; padding: 6px 24px; }
.g-ich { font-size: 22px; font-weight: 700; color: var(--ac); }
.g-ititle { font-size: 40px; font-weight: 800; letter-spacing: -.5px; margin-top: 4px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.g-itime { font-size: 24px; color: var(--tx2); margin-top: 4px; font-variant-numeric: tabular-nums; }
.g-idesc { font-size: 22px; color: var(--tx3); margin-top: 6px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.g-wrap { position: absolute; left: 332px; top: 170px; width: calc(var(--cw, 1688px) - 332px); height: 710px; }
.g-head { position: relative; height: 50px; }
.g-hl { position: absolute; top: 10px; padding-left: 10px; font-size: 22px; color: var(--tx3); font-variant-numeric: tabular-nums; border-left: 2px solid var(--s2); }
.p-grows { left: 0; top: 52px; width: 100%; height: 656px; }
.g-now { position: absolute; top: 44px; bottom: 0; width: 3px; margin-left: -1px; background: var(--ac); border-radius: 2px; z-index: 3; pointer-events: none; }
.g-row { display: flex; height: calc(100% - 8px); }
.g-ch { width: 256px; flex: none; display: flex; align-items: center; gap: 12px; padding: 0 14px; border-radius: 12px; background: var(--s1); font-size: 22px; color: var(--tx2); }
.g-ch .num { width: 40px; flex: none; color: var(--tx3); font-size: 20px; font-variant-numeric: tabular-nums; }
.g-ch .logo { width: 52px; height: 34px; }
.g-ch .name { flex: 1; min-width: 0; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.item.sel .g-ch { background: var(--s2); color: var(--tx); }
.g-track { position: relative; flex: 1; }
.g-prog { position: absolute; top: 0; bottom: 0; margin-left: 6px; padding: 8px 14px; border-radius: 10px; background: var(--s1); color: var(--tx2); overflow: hidden; display: flex; flex-direction: column; justify-content: center; }
.g-prog.now { background: #1a2131; color: var(--tx); }
.g-prog.filler { background: transparent; border: 2px dashed var(--s2); color: var(--tx3); }
.g-t { font-size: 23px; font-weight: 600; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.g-time { font-size: 20px; color: var(--tx3); font-variant-numeric: tabular-nums; }
.g-prog.psel { box-shadow: inset 0 0 0 3px var(--s3); }
.pane.active .g-prog.psel { background: var(--tx); color: var(--bg); box-shadow: none; }
.pane.active .g-prog.psel .g-time { color: rgba(7, 9, 13, .6); }

/* PIN */
.pin { display: grid; place-items: center; }
.pin-box { width: 560px; display: flex; flex-direction: column; align-items: center; text-align: center; }
.pin-box > .ico svg { width: 56px; height: 56px; color: var(--ac); }
.pin-box h1 { margin-top: 14px; font-size: 48px; font-weight: 800; letter-spacing: -1px; }
.pin-sub { margin-top: 8px; min-height: 34px; font-size: 26px; color: var(--tx2); }
.pin-dots { display: flex; gap: 22px; margin: 30px 0 10px; }
.pin-dots span { width: 26px; height: 26px; border-radius: 50%; border: 3px solid var(--tx3); }
.pin-dots span.on { background: var(--tx); border-color: var(--tx); }
.pin-err { min-height: 36px; font-size: 24px; font-weight: 600; color: var(--ac); }
.p-pin { position: relative; width: 510px; height: 480px; }
.pin-key { height: 100%; border-radius: 20px; background: var(--s1); display: grid; place-items: center; font-size: 40px; font-weight: 700; }
.pin-key.ok { background: var(--ac); color: #fff; }
.pane.active .item.sel .pin-key { background: var(--tx); color: var(--bg); }
.pin > .hints { position: absolute; left: 0; right: 0; bottom: 56px; justify-content: center; }

/* Control parental */
.par-note { position: absolute; left: 0; top: 0; width: 1100px; font-size: 26px; line-height: 1.5; color: var(--tx2); }
.p-par { left: 0; top: 110px; width: 1000px; height: 760px; }

/* Auto-zapping */
.skipbox { position: absolute; left: 50%; top: 50%; min-width: 780px; padding: 44px 60px; border-radius: 28px; background: rgba(7, 9, 13, .92); text-align: center; opacity: 0; transform: translate(-50%, -50%) scale(.96); transition: opacity 200ms var(--ease), transform 200ms var(--ease); pointer-events: none; }
.skipbox.show { opacity: 1; transform: translate(-50%, -50%); }
.sk-t { font-size: 40px; font-weight: 800; letter-spacing: -.5px; }
.sk-s { margin-top: 10px; font-size: 28px; color: var(--tx2); font-variant-numeric: tabular-nums; }
.skipbox .hints { justify-content: center; }

/* ---------- v0.5: controles en pantalla del reproductor ---------- */
.ov:not(.show) { pointer-events: none; }
.pctrl { display: flex; flex-wrap: wrap; gap: 16px; margin-top: 32px; }
.pbtn { display: flex; align-items: center; gap: 12px; height: 76px; padding: 0 26px; border-radius: 999px; background: rgba(255, 255, 255, .12); font-size: 24px; font-weight: 600; color: var(--tx); cursor: pointer; }
.pbtn:hover { background: var(--tx); color: var(--bg); }
.pbtn:hover .kb { background: rgba(7, 9, 13, .14); color: var(--bg); }
.skipbox.show { pointer-events: auto; }
.skipbox .pctrl { justify-content: center; }
.ov .hints { margin-top: 20px; }

/* ---------- Vincular celular ↔ TV ---------- */
.pair { display: grid; place-items: center; }
.pair-box { width: 1100px; display: flex; flex-direction: column; align-items: center; text-align: center; }
.pair-box > .ico svg { width: 64px; height: 64px; color: var(--ac); }
.pair-box h1 { margin-top: 16px; font-size: 52px; font-weight: 800; letter-spacing: -1px; }
.pair-sub { margin-top: 16px; font-size: 28px; line-height: 1.5; color: var(--tx2); }
.pair-code { margin: 40px 0 8px; font-size: 140px; font-weight: 800; letter-spacing: 12px; font-variant-numeric: tabular-nums; color: var(--tx); }
.pair > .hints { position: absolute; left: 0; right: 0; bottom: 56px; justify-content: center; }
.p-set { height: 520px; }

/* ---------- Android: reproductor nativo detrás de la app transparente ---------- */
body.native #video { display: none !important; }
html:has(body.native), body.native, body.native .screen.shell, body.native .screen.player { background: transparent; }
body.native[data-player=preview] .pv-box { background: transparent; }

/* =====================================================================
   CELULAR / TABLET VERTICAL (body.m): lienzo de 720 de ancho, alto variable.
   Menú abajo como barra de pestañas, categorías en fila deslizable, todo apilado.
   ===================================================================== */
body.m { width: 720px; }
body.m .side { top: auto; bottom: 0; left: 0; right: 0; width: auto; height: 140px; padding: 0 6px 18px; display: flex; justify-content: space-around; align-items: center; background: rgba(7, 9, 13, .97); border-top: 2px solid var(--s2); z-index: 30; }
body.m .side::before, body.m .side .brand, body.m .side-acc { display: none; }
body.m .mi, body.m .side.open .mi { width: auto; min-width: 84px; height: 104px; margin: 0; padding: 0 6px; flex-direction: column; justify-content: center; gap: 8px; border-radius: 18px; }
body.m .mi .lbl { opacity: 1; font-size: 20px; font-weight: 600; }
body.m .mi.cur::before { left: 30%; right: 30%; top: auto; bottom: 2px; width: auto; height: 5px; }
body.m .side.open .mi.sel { background: var(--s2); color: var(--tx); }
body.m .hdr { left: 32px; right: 32px; top: 18px; height: 88px; }
body.m .hdr h1 { font-size: 46px; }
body.m .clock { display: none; }
body.m .tb { height: 76px; padding: 0 22px; }
body.m .tb .tl { display: none; }
body.m .content { left: 16px; top: 120px; }

/* categorías como fichas deslizables */
body.m .m-chips { left: 0; top: 0; width: var(--cw); height: 92px; }
body.m .m-chips .row { justify-content: center; height: 100%; padding: 0 18px; border-radius: 999px; background: var(--s1); font-size: 24px; }
body.m .m-chips .row .name { flex: none; max-width: 100%; }
body.m .m-chips .item.sel > .row { background: var(--s3); color: var(--tx); }
body.m .pane.active.m-chips .item.sel > .row { background: var(--tx); color: var(--bg); }

/* secciones */
body.m .preview { display: none; }
body.m .live .p-chans, body.m .cat-sec .p-grid, body.m .lists .p-items { left: 0; top: 108px; width: var(--cw); height: calc(var(--ch) - 108px); }
body.m .p-rows { width: var(--cw); height: var(--ch); }
body.m .rtitle { font-size: 28px; padding-left: 22px; }
body.m .sbox { width: var(--cw); }
body.m .p-chips { width: calc(var(--cw) + 16px); }
body.m .p-res { width: var(--cw); height: calc(var(--ch) - 236px); }
body.m .acc-card { width: var(--cw); padding: 24px 32px; }
body.m .acc-head { padding-bottom: 14px; }
body.m .acc-name { font-size: 34px; }
body.m .acc-row { padding: 9px 0; font-size: 24px; }
body.m .p-acts { left: 0; top: 500px; width: var(--cw); height: calc(var(--ch) - 610px); }
body.m .account .acc-del { left: 0; top: auto; bottom: 0; width: var(--cw); }
body.m .ver { display: none; }
body.m .par-note { width: var(--cw); font-size: 24px; }
body.m .p-par { width: var(--cw); height: calc(var(--ch) - 120px); }

/* fichas de película y serie */
body.m .d-poster { left: 230px; top: 100px; width: 260px; height: 390px; }
body.m .d-info { left: 32px; top: 520px; width: 656px; }
body.m .d-title { font-size: 48px; }
body.m .d-plot { font-size: 26px; -webkit-line-clamp: 5; }
body.m .p-btns { left: 32px; top: calc(var(--H) - 380px); width: 656px; height: 340px; }
body.m .s-cover { left: 32px; top: 40px; width: 180px; height: 270px; }
body.m .s-info { left: 236px; top: 40px; width: 452px; }
body.m .s-info .d-title { font-size: 40px; -webkit-line-clamp: 2; }
body.m .s-plot { font-size: 24px; -webkit-line-clamp: 4; }
body.m .series .hints { display: none; }
body.m .p-seasons { left: 16px; top: 420px; width: var(--cw); height: 92px; }
body.m .p-eps { left: 16px; top: 528px; width: var(--cw); height: calc(var(--H) - 620px); }
body.m .logo.thumb { width: 160px; height: 90px; }

/* reproductor */
body.m .ov { padding: 140px 32px 48px; }
body.m .lv-name { max-width: 470px; font-size: 40px; white-space: normal; }
body.m .lv-num { font-size: 30px; }
body.m .logo.xl { width: 112px; height: 70px; }
body.m .epg.wide .bar { width: 100%; }
body.m .vd-title { font-size: 40px; }
body.m .pctrl { gap: 12px; }
body.m .pbtn { height: 84px; padding: 0 24px; }
body.m .pbtn .kb, body.m .ov .hints, body.m .pset .hints { display: none; }
body.m .pset { width: 100%; padding: 80px 40px; background: rgba(7, 9, 13, .97); }
body.m .pset h2 { padding-left: 0; }
body.m .p-set { left: 40px; top: 180px; width: 640px; height: calc(var(--H) - 420px); }
body.m .skipbox { min-width: 0; width: 640px; padding: 36px; }
body.m .digits { font-size: 100px; left: 32px; }

/* entrada, cuentas, PIN, vincular */
body.m .lg-card { width: 640px; }
body.m .picker .pk-head { top: 120px; }
body.m .pair-box { width: 640px; }
body.m .pair-code { font-size: 100px; letter-spacing: 6px; }
body.m .pin > .hints, body.m .pair > .hints, body.m .picker > .hints { display: none; }
body.m #toast { bottom: 180px; max-width: 660px; white-space: normal; text-align: center; }

/* ---------- Botón ← Volver (web y celular) ---------- */
.backbtn { position: absolute; left: 32px; top: 30px; z-index: 80; width: 84px; height: 84px; border-radius: 50%; display: grid; place-items: center; background: rgba(15, 19, 27, .82); color: var(--tx); cursor: pointer; box-shadow: 0 6px 20px rgba(0, 0, 0, .35); }
.backbtn .ico svg { width: 40px; height: 40px; stroke-width: 2.4; }
.backbtn:hover, .backbtn:active { background: var(--tx); color: var(--bg); }
.has-back .hdr { left: 140px; }
.screen.player .backbtn { top: 40px; left: 40px; }
body.m .s-cover { top: 130px; }
body.m .s-info { top: 130px; }
body.m .p-seasons { top: 430px; }
body.m .p-eps { top: 538px; height: calc(var(--H) - 630px); }
body.m .d-poster { top: 130px; }
body.m .d-info { top: 545px; }

@media (prefers-reduced-motion: reduce) {
  .ov, .ov.show, #toast { transform: none !important; }
}
