:root{
  --bg:#02040a;
  --bg2:#06101d;
  --panel:rgba(7,15,29,.82);
  --panel2:rgba(4,10,21,.94);
  --line:rgba(120,175,255,.22);
  --line2:rgba(255,255,255,.08);
  --text:#f8fbff;
  --muted:#9eb0c9;
  --blue:#168cff;
  --cyan:#58d9ff;
  --violet:#765bff;
  --red:#ff365d;
  --green:#36e6a5;
  --yellow:#ffc94a;
  --shadow:0 28px 90px rgba(0,0,0,.55);
  --glow:0 0 0 1px rgba(91,154,255,.16),0 0 42px rgba(32,115,255,.10);
  --max:1440px;
  --radius:24px;
}
*{box-sizing:border-box}
html{scroll-behavior:smooth;background:var(--bg)}
body{
  margin:0;color:var(--text);
  font-family:Inter,ui-sans-serif,system-ui,-apple-system,BlinkMacSystemFont,"Segoe UI",sans-serif;
  background:
    radial-gradient(circle at 8% 4%,rgba(25,117,255,.15),transparent 27rem),
    radial-gradient(circle at 92% 7%,rgba(102,67,255,.16),transparent 28rem),
    linear-gradient(180deg,#02050b 0%,#06101d 42%,#02050b 100%);
  -webkit-font-smoothing:antialiased;overflow-x:hidden;
}
body:before{content:"";position:fixed;inset:0;pointer-events:none;z-index:-1;background-image:linear-gradient(rgba(255,255,255,.015) 1px,transparent 1px),linear-gradient(90deg,rgba(255,255,255,.015) 1px,transparent 1px);background-size:48px 48px;mask-image:linear-gradient(to bottom,black,transparent 75%)}
img,video{display:block;max-width:100%}
button,input{font:inherit}
button,a{touch-action:manipulation}
a{color:inherit;text-decoration:none}
button{color:inherit}
.wrap{width:min(var(--max),calc(100% - 36px));margin:auto}
.section{padding:72px 0;scroll-margin-top:86px}
.kicker{font-size:12px;letter-spacing:.18em;text-transform:uppercase;color:#83ccff}
.section-title{font-size:clamp(32px,4vw,58px);line-height:1;letter-spacing:-.045em;margin:10px 0 12px}
.section-copy{max-width:760px;color:var(--muted);font-size:16px;line-height:1.65}
.section-head{display:flex;justify-content:space-between;align-items:end;gap:28px;margin-bottom:24px}
.section-head .side{max-width:560px;color:var(--muted)}
.neon-line{height:1px;background:linear-gradient(90deg,transparent,var(--blue),var(--violet),transparent);opacity:.7}

/* Header */
.topbar{
  position:sticky;top:0;z-index:100;
  background:rgba(2,5,12,.82);backdrop-filter:blur(20px) saturate(130%);
  border-bottom:1px solid var(--line2)
}
.nav-shell{width:min(1540px,calc(100% - 28px));margin:auto;display:grid;grid-template-columns:auto 1fr auto;align-items:center;gap:24px;min-height:74px}
.brand{display:flex;align-items:center;gap:12px;min-width:max-content}
.brand-mark{
  width:45px;height:45px;border-radius:13px;display:grid;place-items:center;
  font-weight:950;font-size:26px;letter-spacing:-.12em;
  color:white;background:linear-gradient(140deg,#9cecff,#147cff 47%,#8c64ff);
  box-shadow:inset 0 1px 1px rgba(255,255,255,.6),0 0 28px rgba(52,112,255,.36);
  transform:perspective(80px) rotateY(-8deg)
}
.brand strong{display:block;font-size:14px;letter-spacing:.2em}
.brand small{display:block;font-size:9px;letter-spacing:.18em;color:#91a5c3;margin-top:6px}
.main-nav{display:flex;align-items:center;justify-content:center;gap:4px}
.main-nav a{padding:11px 12px;border-radius:12px;font-size:13px;color:#c7d2e3;position:relative}
.main-nav a:hover,.main-nav a.active{color:#fff;background:rgba(255,255,255,.035)}
.main-nav a.active:after{content:"";height:2px;border-radius:2px;position:absolute;left:16px;right:16px;bottom:4px;background:linear-gradient(90deg,var(--cyan),var(--violet));box-shadow:0 0 12px rgba(53,139,255,.7)}
.header-actions{display:flex;gap:8px;align-items:center}
.icon-btn,.ghost-btn,.primary-btn{
  min-height:42px;border-radius:13px;border:1px solid var(--line);background:rgba(255,255,255,.035);
  display:inline-flex;align-items:center;justify-content:center;gap:9px;padding:0 14px;cursor:pointer;transition:.2s ease
}
.icon-btn{width:42px;padding:0}
.primary-btn{border-color:rgba(70,143,255,.45);background:linear-gradient(135deg,rgba(25,126,255,.9),rgba(105,67,255,.9));box-shadow:0 12px 34px rgba(43,93,255,.2);font-weight:750}
.ghost-btn:hover,.icon-btn:hover,.primary-btn:hover{transform:translateY(-1px);filter:brightness(1.08)}
.menu-btn{display:none}

/* Hero */
.hero{padding:44px 0 46px}
.hero-grid{display:grid;grid-template-columns:.78fr 1.22fr;align-items:center;gap:34px}
.hero h1{font-size:clamp(48px,6.2vw,92px);letter-spacing:-.06em;line-height:.9;margin:15px 0 22px}
.hero h1 span{background:linear-gradient(90deg,#fff 0%,#8addff 50%,#aa91ff 100%);-webkit-background-clip:text;background-clip:text;color:transparent}
.hero p{font-size:clamp(17px,1.65vw,21px);line-height:1.6;color:#b2c0d4;max-width:720px}
.actions{display:flex;flex-wrap:wrap;gap:10px;margin-top:28px}
.hero-meta{display:flex;flex-wrap:wrap;gap:16px;margin-top:24px;color:#8799b5;font-size:12px}
.hero-meta b{color:#fff}
.preview-frame{
  position:relative;border:1px solid rgba(85,148,255,.32);border-radius:30px;padding:7px;
  background:linear-gradient(145deg,rgba(35,103,255,.14),rgba(101,59,255,.08),rgba(0,0,0,.55));
  box-shadow:var(--shadow),0 0 80px rgba(28,89,255,.12);overflow:hidden
}
.preview-frame:after{content:"";position:absolute;inset:0;pointer-events:none;border-radius:inherit;background:linear-gradient(120deg,rgba(255,255,255,.13),transparent 22%,transparent 74%,rgba(90,100,255,.08))}
.preview-frame picture,.preview-frame img{width:100%}
.preview-frame img{border-radius:23px;aspect-ratio:16/9;object-fit:cover;object-position:center}
.preview-badge{position:absolute;z-index:3;top:20px;left:20px;border:1px solid rgba(95,175,255,.45);background:rgba(2,7,17,.78);backdrop-filter:blur(14px);border-radius:999px;padding:9px 12px;font-size:10px;letter-spacing:.14em}

/* Shared skin panel */
.skin-panel{position:relative;border:1px solid var(--line);border-radius:28px;padding:7px;background:rgba(0,0,0,.36);box-shadow:var(--shadow),var(--glow);overflow:hidden}
.skin-panel img{width:100%;height:auto;aspect-ratio:16/9;object-fit:contain;background:#010207;border-radius:21px}
.skin-toolbar{display:flex;justify-content:space-between;gap:12px;align-items:center;padding:12px 4px 2px}
.skin-toolbar span{color:var(--muted);font-size:12px}
.skin-open{border:0;background:transparent;color:#88cfff;cursor:pointer;font-size:12px}

/* Live */
.live-layout{display:grid;grid-template-columns:minmax(0,1.65fr) minmax(330px,.65fr);gap:18px}
.player{
  border:1px solid rgba(92,164,255,.35);border-radius:26px;overflow:hidden;background:#000;box-shadow:var(--shadow),0 0 70px rgba(22,87,255,.14)
}
.player-head{height:52px;padding:0 16px;display:flex;align-items:center;justify-content:space-between;background:linear-gradient(180deg,rgba(11,23,43,.97),rgba(4,9,19,.93));border-bottom:1px solid var(--line)}
.player-badge{font-size:12px;letter-spacing:.11em;color:#ffd27c}.player-badge.is-live{color:#ff7892}
.player-status{font-size:11px;letter-spacing:.13em;color:#89a1c0}
.player-stage{position:relative;aspect-ratio:16/9;background:#000}
.player-stage video{width:100%;height:100%;object-fit:contain;background:#000;display:none}
.player-stage video.show{display:block}
.offline-layer{position:absolute;inset:0;background:#000}
.offline-layer.hidden{display:none}
.offline-layer img{width:100%;height:100%;object-fit:contain}
.player-controls{display:flex;flex-wrap:wrap;gap:8px;padding:12px;background:#030710;border-top:1px solid var(--line2)}
.player-controls button{min-height:40px;padding:0 13px;border-radius:12px;border:1px solid var(--line);background:rgba(255,255,255,.035);cursor:pointer}
.player-controls button:disabled{opacity:.35;cursor:not-allowed}
.player-controls .main{background:linear-gradient(135deg,#147fff,#775dff);border-color:transparent}
.sidebar{display:grid;gap:14px;align-content:start}
.glass{border:1px solid var(--line);border-radius:22px;background:linear-gradient(180deg,rgba(10,22,40,.83),rgba(3,8,17,.9));box-shadow:var(--glow);backdrop-filter:blur(16px)}
.schedule{padding:18px}
.schedule h3,.quick h3{margin:0 0 14px;font-size:15px;letter-spacing:.09em}
.schedule ul{list-style:none;padding:0;margin:0}
.schedule li{display:grid;grid-template-columns:58px 1fr;gap:12px;padding:10px 0;border-top:1px solid rgba(255,255,255,.07)}
.schedule li:first-child{border-top:0}
.schedule time{font-weight:800;color:#55b8ff}
.schedule b{display:block;font-size:13px}.schedule span{display:block;color:#8598b5;font-size:11px;margin-top:4px}
.quick{padding:18px}
.quick-grid{display:grid;grid-template-columns:1fr 1fr;gap:8px}
.quick .ghost-btn{font-size:12px;min-height:45px}

/* Programs & section tiles */
.program-grid{display:grid;grid-template-columns:1.3fr .7fr;gap:18px;align-items:start}
.program-cards{display:grid;gap:12px}
.program-mini{padding:18px;min-height:118px;display:flex;flex-direction:column;justify-content:space-between}
.program-mini .time{font-size:11px;color:#7acfff;text-transform:uppercase;letter-spacing:.12em}
.program-mini h3{margin:8px 0 6px}.program-mini p{margin:0;color:var(--muted);font-size:13px}
.section-links{display:grid;grid-template-columns:repeat(4,1fr);gap:10px;margin-top:16px}
.section-link{padding:15px;border:1px solid var(--line);border-radius:17px;background:rgba(255,255,255,.025);cursor:pointer;transition:.2s}
.section-link:hover{transform:translateY(-2px);border-color:rgba(89,160,255,.52);background:rgba(44,102,255,.07)}
.section-link strong{display:block}.section-link span{font-size:11px;color:var(--muted)}

/* News */
.news-layout{display:grid;grid-template-columns:1.25fr .75fr;gap:18px}
.news-side{display:grid;gap:12px}
.news-chip{padding:18px}
.news-chip b{display:block;font-size:18px}.news-chip span{display:block;color:var(--muted);font-size:12px;margin-top:6px}
.news-ticker{margin-top:14px;border:1px solid var(--line);border-radius:15px;overflow:hidden;display:grid;grid-template-columns:auto 1fr;background:rgba(4,10,20,.9)}
.news-ticker b{padding:12px 14px;background:linear-gradient(135deg,#157fff,#654cff);font-size:12px}
.ticker-track{display:flex;align-items:center;white-space:nowrap;overflow:hidden;color:#a7b7cb;font-size:12px}
.ticker-track span{padding:0 22px;border-right:1px solid rgba(255,255,255,.08)}

/* Archive */
.archive-shell{padding:20px;border:1px solid var(--line);border-radius:26px;background:rgba(3,8,17,.86);box-shadow:var(--shadow)}
.archive-tools{display:grid;grid-template-columns:minmax(260px,1fr) auto;gap:12px;align-items:center}
.search-box{position:relative}
.search-box input{width:100%;height:50px;border-radius:14px;border:1px solid rgba(86,160,255,.34);background:#020713;color:#fff;padding:0 16px 0 46px;outline:none;box-shadow:inset 0 0 30px rgba(32,107,255,.04)}
.search-box:before{content:"⌕";position:absolute;left:17px;top:11px;font-size:23px;color:#74caff}
.filters{display:flex;gap:7px;flex-wrap:wrap}
.filter-btn{height:40px;padding:0 13px;border-radius:12px;border:1px solid var(--line);background:rgba(255,255,255,.025);cursor:pointer}
.filter-btn.active{background:linear-gradient(135deg,#167fff,#6a54ff);border-color:transparent}
.archive-grid{display:grid;grid-template-columns:repeat(4,1fr);gap:10px;margin-top:16px}
.content-card{padding:16px;min-height:180px;border:1px solid var(--line);border-radius:18px;background:linear-gradient(180deg,rgba(15,31,56,.65),rgba(3,9,18,.9));position:relative}
.content-icon{font-size:25px;color:#7bd8ff}.content-cat{position:absolute;right:13px;top:13px;font-size:10px;text-transform:uppercase;letter-spacing:.11em;color:#8eacd0}
.content-card h3{margin:24px 0 8px;font-size:18px}.content-card p{color:var(--muted);font-size:12px;margin:0}
.content-card footer{display:flex;justify-content:space-between;align-items:end;gap:8px;position:absolute;bottom:14px;left:16px;right:16px;color:#7391b4;font-size:10px}
.content-card footer button{width:34px;height:34px;border-radius:50%;border:1px solid rgba(95,169,255,.5);background:rgba(41,103,255,.14);cursor:pointer}
.empty-state{grid-column:1/-1;padding:30px;text-align:center;color:var(--muted)}
.interview-strip{display:grid;grid-template-columns:1.1fr .9fr;gap:18px;margin-top:18px;align-items:center}
.interview-strip img{border-radius:22px;aspect-ratio:16/9;object-fit:contain;background:#02040a;border:1px solid var(--line)}
.interview-copy{padding:24px}.interview-copy h3{font-size:34px;margin:8px 0 10px}.interview-copy p{color:var(--muted);line-height:1.6}

/* Devices */
.device-layout{display:grid;grid-template-columns:1.2fr .8fr;gap:18px;align-items:start}
.device-cards{display:grid;grid-template-columns:1fr 1fr;gap:10px}
.device-card{padding:18px;min-height:138px}
.device-card .icon{font-size:28px}.device-card strong{display:block;margin-top:12px}.device-card small{display:block;color:var(--muted);margin-top:5px}
.codebox{padding:18px;margin-top:10px}
.codebox code{display:block;padding:12px;background:#02050c;border-radius:12px;color:#83d5ff;overflow:auto;border:1px solid rgba(255,255,255,.06)}

/* Participation */
.participation{display:grid;grid-template-columns:1.25fr .75fr;gap:18px;align-items:center}
.participation-copy{padding:28px}.participation-copy h2{font-size:clamp(34px,4vw,60px);margin:8px 0 14px;line-height:1}
.participation-copy p{color:var(--muted);line-height:1.7}
.participation .skin-panel{margin:0}

/* Footer */
footer{padding:30px 0 88px;border-top:1px solid var(--line2);color:#7890ad}
.footer-row{display:flex;justify-content:space-between;gap:24px;align-items:center}
.footer-row b{color:#fff;letter-spacing:.14em}.footer-row small{display:block;margin-top:5px}

/* Mobile bottom nav */
.mobile-bottom{display:none}

/* Dialog */
dialog{border:1px solid var(--line);border-radius:22px;padding:8px;background:#01040b;box-shadow:0 35px 120px #000;color:#fff;max-width:min(1500px,96vw)}
dialog::backdrop{background:rgba(0,0,0,.86);backdrop-filter:blur(8px)}
dialog img{max-height:86vh;border-radius:16px}
.dialog-head{display:flex;justify-content:flex-end;padding:2px 2px 8px}
.dialog-head button{border:1px solid var(--line);background:#07101e;border-radius:10px;padding:8px 12px;cursor:pointer}

/* Fine details */
body[data-channel-mode="live"] .live-dot{background:var(--red)}
.live-dot{display:inline-block;width:8px;height:8px;border-radius:50%;background:var(--yellow);box-shadow:0 0 16px currentColor;margin-right:7px}
a:focus-visible,button:focus-visible,input:focus-visible{outline:2px solid var(--cyan);outline-offset:3px}
@media (prefers-reduced-motion:no-preference){
  .preview-frame{animation:floaty 8s ease-in-out infinite}
  @keyframes floaty{50%{transform:translateY(-5px)}}
}
@media (max-width:1120px){
  .main-nav a{padding:10px 8px;font-size:12px}
  .hero-grid,.live-layout,.program-grid,.news-layout,.device-layout,.participation,.interview-strip{grid-template-columns:1fr}
  .archive-grid{grid-template-columns:repeat(2,1fr)}
  .hero{padding-top:32px}
}
@media (max-width:820px){
  .wrap{width:min(var(--max),calc(100% - 22px))}
  .nav-shell{grid-template-columns:1fr auto;min-height:66px}
  .main-nav{position:absolute;top:66px;left:11px;right:11px;display:none;flex-direction:column;align-items:stretch;background:rgba(2,6,14,.98);border:1px solid var(--line);border-radius:18px;padding:8px;box-shadow:var(--shadow)}
  .main-nav.open{display:flex}
  .main-nav a{padding:13px}.main-nav a.active:after{display:none}
  .menu-btn{display:inline-flex}
  .header-actions .hide-mobile{display:none}
  .brand small{display:none}
  .hero-grid{gap:22px}.hero h1{font-size:52px}
  .section{padding:54px 0}
  .section-head{display:block}.section-head .side{margin-top:10px}
  .section-links{grid-template-columns:1fr 1fr}
  .archive-tools{grid-template-columns:1fr}
  .device-cards{grid-template-columns:1fr 1fr}
  .mobile-bottom{display:grid;position:fixed;z-index:80;left:10px;right:10px;bottom:10px;grid-template-columns:repeat(5,1fr);border:1px solid var(--line);border-radius:18px;background:rgba(2,7,16,.9);backdrop-filter:blur(18px);padding:7px;box-shadow:0 22px 60px #000}
  .mobile-bottom a{text-align:center;padding:7px 2px;border-radius:12px;font-size:9px;color:#92a5be}
  .mobile-bottom a span{display:block;font-size:20px;margin-bottom:3px;color:#cdeaff}
  footer{padding-bottom:100px}
}
@media (max-width:560px){
  .hero h1{font-size:45px}.hero p{font-size:16px}
  .preview-frame{border-radius:22px}
  .preview-frame picture img{aspect-ratio:9/16;object-fit:contain;max-height:75vh}
  .section-links,.device-cards,.archive-grid{grid-template-columns:1fr}
  .quick-grid{grid-template-columns:1fr}
  .player-controls button{flex:1 1 46%}
  .skin-panel{border-radius:20px;padding:5px}.skin-panel img{border-radius:15px}
  .skin-toolbar{display:none}
  .archive-shell{padding:14px}
  .filters{display:grid;grid-template-columns:1fr 1fr}
  .filter-btn{width:100%}
  .footer-row{align-items:flex-start;flex-direction:column}
}

/* V3 audit improvements */
.skip-link{position:fixed;left:12px;top:10px;z-index:999;transform:translateY(-150%);padding:10px 14px;border-radius:10px;background:#fff;color:#06101d;font-weight:800;transition:transform .18s ease}
.skip-link:focus{transform:translateY(0)}
.player-notice{min-height:0;padding:0 16px;background:#030710;color:#9fb4d0;font-size:11px;line-height:1.45;transition:.2s}
.player-notice:not(:empty){min-height:34px;padding-top:9px;padding-bottom:9px;border-bottom:1px solid rgba(255,255,255,.06)}
.player-badge.is-loading{color:#79d8ff}
body[data-channel-mode="error"] .player-badge{color:#ff7892}
.schedule-date{margin:-7px 0 8px;color:#7792b5;font-size:11px;text-transform:capitalize}
.schedule li.current-program{background:linear-gradient(90deg,rgba(25,122,255,.11),transparent);margin-inline:-9px;padding-inline:9px;border-radius:10px}
.schedule li em{display:inline-flex;margin-top:6px;padding:3px 7px;border:1px solid rgba(54,230,165,.3);border-radius:999px;color:#58e8b3;font-size:9px;font-style:normal;text-transform:uppercase;letter-spacing:.09em}
.platform-status{padding:18px}
.platform-status h3{margin:0 0 12px;font-size:13px;letter-spacing:.09em}
.platform-status>div{display:flex;justify-content:space-between;gap:12px;padding:9px 0;border-top:1px solid rgba(255,255,255,.065);font-size:11px}
.platform-status>div:first-of-type{border-top:0}
.platform-status span{color:#8ea5c1}.platform-status b{color:#82cfff;text-align:right}
.platform-status b[data-state="ok"]{color:#57e5aa}.platform-status b[data-state="error"]{color:#ff718d}
.news-chip{width:100%;text-align:left;cursor:pointer;transition:transform .18s,border-color .18s,background .18s;color:inherit}
.news-chip:hover,.news-chip.active{transform:translateX(2px);border-color:rgba(95,171,255,.58);background:linear-gradient(90deg,rgba(26,116,255,.12),rgba(92,63,255,.05))}
.news-focus{margin-top:14px;padding:18px 20px;display:grid;grid-template-columns:auto 1fr;grid-template-areas:"k t" "k p";column-gap:22px;align-items:center}
.news-focus .kicker{grid-area:k;writing-mode:vertical-rl;transform:rotate(180deg);font-size:9px}
.news-focus h3{grid-area:t;margin:0 0 4px;font-size:20px}.news-focus p{grid-area:p;margin:0;color:var(--muted);font-size:12px;line-height:1.55}
.brand-mark{position:relative}
.brand-mark:after{content:"fallback";position:absolute;right:-6px;bottom:-5px;font-size:6px;letter-spacing:.08em;color:#6f88a8;background:#02050b;border:1px solid rgba(255,255,255,.1);border-radius:4px;padding:1px 3px;font-weight:600}
.content-card footer button:hover{background:rgba(41,103,255,.28);transform:scale(1.04)}
.skin-open:hover{text-decoration:underline;text-underline-offset:3px}
dialog[open]{animation:modalIn .18s ease-out}
@keyframes modalIn{from{opacity:0;transform:scale(.985)}to{opacity:1;transform:scale(1)}}
@media (prefers-reduced-motion:reduce){html{scroll-behavior:auto}.preview-frame,dialog[open]{animation:none!important}.ghost-btn,.icon-btn,.primary-btn,.news-chip,.section-link{transition:none!important}}
@media (max-width:560px){.news-focus{grid-template-columns:1fr;grid-template-areas:"k" "t" "p"}.news-focus .kicker{writing-mode:horizontal-tb;transform:none;margin-bottom:8px}.brand-mark:after{display:none}}


/* Visual gallery additions */
.visual-grid{display:grid;gap:16px}
.visual-grid-main{margin-top:8px}
.visual-grid-3{grid-template-columns:repeat(3,1fr);margin-top:16px}
.visual-card{overflow:hidden;border:1px solid var(--line);border-radius:24px;background:linear-gradient(180deg,rgba(10,21,39,.88),rgba(4,9,17,.96));box-shadow:var(--glow)}
.visual-card-wide{display:grid;grid-template-columns:1.15fr .85fr;align-items:stretch}
.visual-media{position:relative;background:#02040a}
.visual-media img{width:100%;height:100%;display:block;aspect-ratio:16/9;object-fit:cover}
.visual-card-wide .visual-media img{min-height:100%}
.visual-copy{padding:22px;display:flex;flex-direction:column;justify-content:space-between;gap:12px}
.visual-copy h3{margin:0;font-size:28px;letter-spacing:-.03em}
.visual-copy p{margin:0;color:var(--muted);line-height:1.65}
.visual-copy .ghost-btn{align-self:flex-start}
@media (max-width:1120px){
  .visual-grid-3{grid-template-columns:1fr 1fr}
  .visual-card-wide{grid-template-columns:1fr}
}
@media (max-width:680px){
  .visual-grid-3{grid-template-columns:1fr}
  .visual-copy h3{font-size:24px}
}


/* ===== CANAL NUBRA V3.3 · 3D CINEMATIC IDENTITY ===== */
.sr-only{position:absolute!important;width:1px!important;height:1px!important;padding:0!important;margin:-1px!important;overflow:hidden!important;clip:rect(0,0,0,0)!important;white-space:nowrap!important;border:0!important}
.brand-3d{gap:8px;min-height:64px}
.brand-logo-3d{width:58px;height:58px;object-fit:contain;filter:drop-shadow(0 0 12px rgba(41,155,255,.48)) drop-shadow(0 0 24px rgba(132,72,255,.20));transition:transform .28s ease,filter .28s ease}
.brand-3d:hover .brand-logo-3d{transform:translateY(-1px) scale(1.04) rotateY(-4deg);filter:drop-shadow(0 0 16px rgba(62,188,255,.68)) drop-shadow(0 0 30px rgba(140,70,255,.34))}
.brand-copy-3d strong,.footer-brand b{
  color:#e8f4ff;
  background:linear-gradient(180deg,#ffffff 0%,#c9ebff 25%,#5ab9ff 52%,#a88cff 76%,#ffffff 100%);
  -webkit-background-clip:text;background-clip:text;-webkit-text-fill-color:transparent;
  text-shadow:0 1px 0 rgba(255,255,255,.18),0 4px 12px rgba(28,104,255,.18);
  filter:drop-shadow(0 0 7px rgba(76,154,255,.20));
}
.brand-copy-3d small{color:#9ab7d7;text-shadow:0 0 8px rgba(74,145,255,.24)}

/* Cinematic 3D navigation typography */
.main-nav a,.mobile-bottom a{
  font-weight:800;letter-spacing:.035em;
  color:#dcecff;
  background-image:linear-gradient(180deg,#ffffff 0%,#bfeaff 30%,#5baeff 58%,#9d7bff 84%,#f4edff 100%);
  -webkit-background-clip:text;background-clip:text;-webkit-text-fill-color:transparent;
  text-shadow:0 1px 0 rgba(255,255,255,.12),0 2px 0 rgba(50,74,145,.24),0 0 10px rgba(61,139,255,.24);
}
.main-nav a:hover,.main-nav a.active{filter:drop-shadow(0 0 9px rgba(53,149,255,.55));background-color:rgba(24,72,170,.08)}
.main-nav a.active:after{height:3px;box-shadow:0 0 16px rgba(60,160,255,.85),0 0 24px rgba(124,77,255,.5)}

.section-title-skin{display:flex;align-items:center;min-height:58px;margin:5px 0 2px;max-width:420px;filter:drop-shadow(0 0 10px rgba(37,134,255,.22)) drop-shadow(0 0 18px rgba(123,74,255,.12))}
.section-title-skin.wide{max-width:560px}
.section-title-skin img{display:block;width:100%;height:auto;max-height:92px;object-fit:contain;object-position:left center}
.hero-title-skin{max-width:210px;min-height:34px;margin:0 0 5px}
.hero-title-skin img{max-height:52px}
.participate-title{max-width:460px;margin:4px 0 8px}
.participation-tagline{font-size:clamp(28px,3vw,46px);margin:0 0 12px;letter-spacing:-.035em}

/* Main hero and key typography get metallic depth without sacrificing readability */
.hero h1,.participation-tagline,.program-mini h3,.news-chip b,.content-card h3,.device-card strong,.visual-copy h3,.schedule b,.quick h3,.schedule h3,.platform-status h3{
  background:linear-gradient(180deg,#ffffff 0%,#dff3ff 22%,#73c4ff 48%,#a68cff 75%,#ffffff 100%);
  -webkit-background-clip:text;background-clip:text;-webkit-text-fill-color:transparent;
  text-shadow:0 1px 0 rgba(255,255,255,.10),0 2px 0 rgba(42,63,122,.24),0 0 12px rgba(47,131,255,.13);
}
.hero h1 span{background:linear-gradient(100deg,#f8fdff,#66c7ff 42%,#8a72ff 72%,#d5c9ff);-webkit-background-clip:text;background-clip:text;-webkit-text-fill-color:transparent;filter:drop-shadow(0 0 12px rgba(53,120,255,.22))}
.kicker{font-weight:800;color:#8ed8ff;text-shadow:0 0 10px rgba(50,145,255,.32);letter-spacing:.2em}
.primary-btn,.ghost-btn,.player-controls button,.filter-btn,.section-link{
  position:relative;overflow:hidden;box-shadow:inset 0 1px 0 rgba(255,255,255,.10),0 7px 24px rgba(0,0,0,.18);
}
.primary-btn:before,.ghost-btn:before,.player-controls button:before,.filter-btn:before,.section-link:before{
  content:"";position:absolute;inset:0;pointer-events:none;background:linear-gradient(120deg,rgba(255,255,255,.10),transparent 22%,transparent 70%,rgba(108,94,255,.09));opacity:.75
}
.glass,.skin-panel,.player,.archive-shell,.visual-card{box-shadow:inset 0 1px 0 rgba(255,255,255,.06),0 22px 65px rgba(0,0,0,.30),0 0 0 1px rgba(49,127,255,.08),0 0 34px rgba(35,105,255,.06)}
.skin-panel{background:linear-gradient(145deg,rgba(11,29,54,.72),rgba(3,8,19,.92));}

.footer-brand{display:flex;align-items:center;gap:10px}.footer-brand img{width:48px;height:48px;object-fit:contain;filter:drop-shadow(0 0 10px rgba(49,148,255,.35))}.footer-brand span{display:block}

@media (max-width:1000px){.section-title-skin{max-width:370px}.section-title-skin.wide{max-width:470px}}
@media (max-width:820px){
  .brand-logo-3d{width:52px;height:52px}.brand-copy-3d strong{font-size:12px}
  .main-nav a{font-size:13px}
  .section-title-skin{max-width:320px}.section-title-skin.wide{max-width:410px}
}
@media (max-width:560px){
  .brand-logo-3d{width:46px;height:46px}.brand-copy-3d strong{font-size:11px;letter-spacing:.13em}.brand-copy-3d small{display:none}
  .section-title-skin{max-width:270px;min-height:48px}.section-title-skin.wide{max-width:310px}.section-title-skin img{max-height:72px}
  .hero-title-skin{max-width:145px;min-height:25px}.hero-title-skin img{max-height:38px}
  .participate-title{max-width:300px}
}


/* ===== CANAL NUBRA V3.4 · FUNCTIONAL + VISUAL POLISH ===== */
/* Secondary information is intentionally cleaner so the 3D identity keeps hierarchy. */
.program-mini h3,.news-chip b,.content-card h3,.device-card strong,.visual-copy h3,.schedule b,.quick h3,.schedule h3,.platform-status h3{
  background:none!important;
  -webkit-background-clip:initial!important;background-clip:initial!important;
  -webkit-text-fill-color:currentColor!important;
  color:#f3f8ff!important;
  text-shadow:none!important;
  filter:none!important;
}
.program-mini h3,.content-card h3,.visual-copy h3{letter-spacing:-.02em}
.schedule b,.news-chip b,.device-card strong{color:#eaf4ff!important}
.section-copy,.side,.program-mini p,.content-card p,.news-chip span,.schedule span,.device-card small{color:#9fb1c8}

/* Refined navigation: 3D but less noisy. */
.main-nav a{
  text-shadow:0 1px 0 rgba(255,255,255,.12),0 0 7px rgba(59,143,255,.18);
  filter:none;
}
.main-nav a:hover,.main-nav a.active{filter:drop-shadow(0 0 6px rgba(64,153,255,.35))}

/* Cinematic NUBRA signal CTA, kept as a real accessible HTML control. */
.signal-btn-3d{
  --btn-cyan:#66ddff;--btn-blue:#197dff;--btn-violet:#8158ff;
  position:relative;isolation:isolate;overflow:hidden;
  min-height:48px;padding:0 20px;border-radius:15px;
  border:1px solid rgba(144,204,255,.72);
  display:inline-flex;align-items:center;justify-content:center;gap:10px;
  color:#fff!important;-webkit-text-fill-color:#fff!important;text-decoration:none;
  font-weight:900;letter-spacing:.025em;cursor:pointer;
  background:
    linear-gradient(180deg,rgba(255,255,255,.30) 0%,rgba(255,255,255,.05) 18%,transparent 38%),
    linear-gradient(135deg,#0879ef 0%,#135ee9 38%,#623ff0 72%,#932fff 100%);
  box-shadow:
    inset 0 1px 0 rgba(255,255,255,.7),
    inset 0 -2px 8px rgba(8,16,72,.48),
    0 3px 0 #132f91,
    0 9px 22px rgba(20,74,255,.34),
    0 0 24px rgba(88,78,255,.25);
  text-shadow:0 1px 0 rgba(0,0,0,.35),0 0 8px rgba(191,232,255,.28);
  transform:translateY(0) perspective(280px) rotateX(0deg);
  transition:transform .18s ease,box-shadow .18s ease,filter .18s ease,border-color .18s ease;
}
.signal-btn-3d::before{
  content:"";position:absolute;z-index:-1;inset:1px;border-radius:13px;
  background:linear-gradient(115deg,rgba(255,255,255,.24),transparent 28%,transparent 62%,rgba(192,116,255,.20));
  pointer-events:none;
}
.signal-btn-3d::after{
  content:"";position:absolute;top:-60%;left:-28%;width:30%;height:220%;
  transform:rotate(22deg);background:linear-gradient(90deg,transparent,rgba(255,255,255,.48),transparent);
  opacity:.38;transition:left .5s ease;pointer-events:none;
}
.signal-btn-3d:hover::after{left:110%}
.signal-btn-3d:hover{
  transform:translateY(-2px) perspective(280px) rotateX(2deg);
  border-color:rgba(180,228,255,.95);filter:brightness(1.08) saturate(1.08);
  box-shadow:inset 0 1px 0 rgba(255,255,255,.82),inset 0 -2px 8px rgba(8,16,72,.46),0 4px 0 #1735a0,0 13px 30px rgba(28,80,255,.42),0 0 32px rgba(104,76,255,.38);
}
.signal-btn-3d:active{transform:translateY(2px);box-shadow:inset 0 2px 8px rgba(0,0,0,.28),0 1px 0 #10276f,0 5px 14px rgba(28,80,255,.28)}
.signal-btn-3d:focus-visible{outline:2px solid #b9efff;outline-offset:4px}
.signal-btn-3d[disabled],.signal-btn-3d[aria-disabled="true"]{opacity:.48;filter:saturate(.55);cursor:not-allowed;transform:none;box-shadow:inset 0 1px 0 rgba(255,255,255,.25),0 4px 12px rgba(0,0,0,.24)}
.signal-btn-icon{
  width:28px;height:28px;border-radius:9px;display:inline-grid;place-items:center;
  background:linear-gradient(145deg,rgba(255,255,255,.30),rgba(90,174,255,.12));
  border:1px solid rgba(210,242,255,.50);box-shadow:inset 0 1px 0 rgba(255,255,255,.48),0 0 13px rgba(98,205,255,.24);
  font-size:12px;line-height:1;
}
.hero-signal-btn{min-height:52px;padding-inline:22px}
.player-signal-btn{min-height:42px;padding-inline:16px}
.header-actions .signal-btn-3d{min-height:42px;padding-inline:15px;border-radius:13px}

/* Player state is factual: ready is not live. */
.player-badge.is-ready{color:#87dfff}
body[data-channel-mode="ready"] .live-dot{background:#55caff;box-shadow:0 0 16px rgba(85,202,255,.8)}
body[data-channel-mode="live"] .live-dot{background:#ff365d;box-shadow:0 0 16px rgba(255,54,93,.75)}
body[data-channel-mode="loading"] .live-dot{background:#ffc94a;box-shadow:0 0 16px rgba(255,201,74,.7)}

/* Keep the cinematic offline skin visible while connecting, avoiding an empty black player. */
.player-stage{background:#01030a}
.offline-layer{transition:opacity .2s ease}
.player-stage video{opacity:0;transition:opacity .2s ease}
.player-stage video.show{opacity:1}

/* Toast for previously dead archive actions. */
.site-toast{
  position:fixed;z-index:180;left:50%;bottom:28px;transform:translate(-50%,24px);
  max-width:min(520px,calc(100% - 28px));padding:12px 17px;border-radius:14px;
  border:1px solid rgba(102,184,255,.42);background:rgba(3,10,22,.94);color:#eaf6ff;
  box-shadow:0 18px 55px rgba(0,0,0,.5),0 0 25px rgba(41,113,255,.16);backdrop-filter:blur(15px);
  font-size:13px;opacity:0;visibility:hidden;transition:.22s ease;pointer-events:none;
}
.site-toast.show{opacity:1;visibility:visible;transform:translate(-50%,0)}

/* Small visual cleanup */
.section-title-skin{margin-bottom:7px}
.glass,.archive-shell,.visual-card{border-color:rgba(104,158,226,.18)}
.skin-panel{border-color:rgba(103,163,245,.20)}
.player{border-color:rgba(89,157,255,.36)}
.content-card footer button,.news-chip,.section-link{transition:transform .18s ease,border-color .18s ease,background .18s ease}
.content-card footer button:focus-visible{outline:2px solid var(--cyan);outline-offset:2px}

@media (max-width:820px){
  .signal-btn-3d{min-height:46px;padding-inline:16px}
  .hero-signal-btn{width:100%;max-width:310px}
}
@media (max-width:560px){
  .hero .actions{display:grid;grid-template-columns:1fr;max-width:340px}
  .hero-signal-btn,.hero .ghost-btn{width:100%;max-width:none}
  .player-controls .signal-btn-3d{flex:1 1 100%}
  .site-toast{bottom:88px;font-size:12px}
}


/* V3.5 Resolution fidelity fixes */
:root{--skin-native-width:1672px;--skin-native-ratio:1672/941}
.preview-frame,.skin-panel,.player,.visual-card{contain:layout paint;}
.preview-frame img,
.skin-panel img,
.offline-layer img,
.visual-media img,
.interview-strip img{
  image-rendering:auto;
  -ms-interpolation-mode:bicubic;
  backface-visibility:hidden;
  transform:translateZ(0);
}
.preview-frame img,.skin-panel img,.offline-layer img{aspect-ratio:1672/941;}
.preview-frame img,.skin-panel img{
  object-fit:contain;
  object-position:center center;
}
/* Never upscale skin imagery beyond its native CSS pixel width on desktop */
.skin-panel,.preview-frame{max-width:var(--skin-native-width);margin-inline:auto;}
.skin-panel img,.preview-frame img{max-width:100%;height:auto;}
/* The player itself remains responsive, but the offline skin is contained rather than cropped */
.player-stage{background:#010207;overflow:hidden;}
.offline-layer{display:grid;place-items:center;}
.offline-layer img{width:100%;height:100%;object-fit:contain;object-position:center;}
/* Prevent glow filters from softening text inside screenshot skins */
.skin-panel img,.preview-frame img,.offline-layer img{filter:none!important;}
/* Modal shows master artwork without forced scaling */
dialog#skinModal img{width:auto;max-width:min(96vw,1672px);height:auto;max-height:88vh;object-fit:contain;}
@media (max-width:560px){
  .preview-frame picture img{aspect-ratio:auto;max-height:78vh;object-fit:contain;}
  .skin-panel img,.offline-layer img{aspect-ratio:1672/941;object-fit:contain;}
}


/* Fullscreen signal mode */
.player:fullscreen,
.player:-webkit-full-screen {
  width: 100vw !important;
  height: 100vh !important;
  max-width: none !important;
  border-radius: 0 !important;
  border: 0 !important;
  background: #000 !important;
  display: grid !important;
  grid-template-rows: auto auto minmax(0, 1fr) auto !important;
}
.player:fullscreen .player-stage,
.player:-webkit-full-screen .player-stage {
  width: 100vw !important;
  height: 100% !important;
  aspect-ratio: auto !important;
  min-height: 0 !important;
  background: #000 !important;
}
.player:fullscreen .player-stage video,
.player:-webkit-full-screen .player-stage video,
.player:fullscreen .offline-layer img,
.player:-webkit-full-screen .offline-layer img {
  width: 100% !important;
  height: 100% !important;
  object-fit: contain !important;
  background: #000 !important;
}
.player:fullscreen .player-head,
.player:-webkit-full-screen .player-head,
.player:fullscreen .player-controls,
.player:-webkit-full-screen .player-controls {
  background: rgba(0, 4, 12, .94) !important;
}
@media (max-width: 820px) {
  .player:fullscreen .player-controls,
  .player:-webkit-full-screen .player-controls {
    padding-bottom: max(12px, env(safe-area-inset-bottom)) !important;
  }
}


/* ===== CANAL NUBRA V3.7 · ADAPTIVE DEVICE UI ===== */
.device-pill{
  min-height:32px;padding:0 10px;border-radius:999px;display:inline-flex;align-items:center;
  border:1px solid rgba(104,171,255,.25);background:rgba(16,39,74,.45);color:#9fd6ff;
  font-size:10px;font-weight:800;letter-spacing:.08em;text-transform:uppercase;white-space:nowrap;
}
.device-card.detected-device{border-color:rgba(91,187,255,.82);box-shadow:inset 0 0 0 1px rgba(121,208,255,.18),0 0 30px rgba(39,119,255,.20);background:linear-gradient(145deg,rgba(22,79,151,.22),rgba(70,45,160,.12))}
.device-card.detected-device::after{content:"ESTE DISPOSITIVO";display:inline-flex;margin-top:12px;padding:4px 8px;border-radius:999px;background:rgba(70,160,255,.13);border:1px solid rgba(96,187,255,.28);color:#8fddff;font-size:8px;font-weight:900;letter-spacing:.1em}

/* Celular: señal y controles táctiles primero. */
body[data-device="mobile"]{--max:760px}
body[data-device="mobile"] .topbar{backdrop-filter:blur(14px)}
body[data-device="mobile"] .nav-shell{min-height:62px}
body[data-device="mobile"] .brand-copy-3d strong{font-size:10px}
body[data-device="mobile"] .hero{padding-top:24px}
body[data-device="mobile"] .hero-grid{grid-template-columns:1fr;gap:18px}
body[data-device="mobile"] .hero h1{font-size:clamp(38px,12vw,54px)}
body[data-device="mobile"] .hero p{font-size:15px;line-height:1.55}
body[data-device="mobile"] .hero-meta{gap:8px 14px}
body[data-device="mobile"] .preview-frame{max-width:480px;margin-inline:auto}
body[data-device="mobile"] .preview-frame picture img{width:100%;max-height:min(68dvh,720px);object-fit:contain}
body[data-device="mobile"] .live-layout,body[data-device="mobile"] .program-grid,body[data-device="mobile"] .news-layout,body[data-device="mobile"] .device-layout,body[data-device="mobile"] .participation,body[data-device="mobile"] .interview-strip{grid-template-columns:1fr}
body[data-device="mobile"] .player{border-radius:18px}
body[data-device="mobile"] .player-head{height:48px}
body[data-device="mobile"] .player-controls{display:grid;grid-template-columns:1fr 1fr;gap:8px;padding:10px}
body[data-device="mobile"] .player-controls button{min-height:52px;width:100%;font-size:12px}
body[data-device="mobile"] .player-controls .signal-btn-3d{grid-column:1/-1;min-height:56px;font-size:15px}
body[data-device="mobile"] .quick-grid{grid-template-columns:1fr 1fr}
body[data-device="mobile"] .quick-grid button{min-height:52px}
body[data-device="mobile"] .section{padding:48px 0;scroll-margin-top:68px}
body[data-device="mobile"] .section-title-skin{max-width:min(82vw,310px)}
body[data-device="mobile"] .archive-grid,body[data-device="mobile"] .section-links,body[data-device="mobile"] .device-cards,body[data-device="mobile"] .visual-grid-3{grid-template-columns:1fr}
body[data-device="mobile"] .mobile-bottom{display:grid}
body[data-device="mobile"] .skin-panel img{max-height:none}

/* Tablet: dos columnas donde aportan contexto, controles táctiles cómodos. */
body[data-device="tablet"]{--max:1180px}
body[data-device="tablet"] .hero-grid{grid-template-columns:1fr;gap:26px}
body[data-device="tablet"] .live-layout{grid-template-columns:1fr}
body[data-device="tablet"] .program-grid,body[data-device="tablet"] .device-layout,body[data-device="tablet"] .participation{grid-template-columns:1fr}
body[data-device="tablet"] .program-cards,body[data-device="tablet"] .device-cards{grid-template-columns:repeat(2,1fr)}
body[data-device="tablet"] .archive-grid{grid-template-columns:repeat(2,1fr)}
body[data-device="tablet"] button,body[data-device="tablet"] .ghost-btn,body[data-device="tablet"] .primary-btn{min-height:48px}
body[data-device="tablet"] .section{padding:62px 0}
body[data-device="tablet"] .mobile-bottom{display:none}

/* PC / Notebook: dashboard completo, densidad informativa normal. */
body[data-device="desktop"] .wrap{width:min(var(--max),calc(100% - 36px))}
body[data-device="desktop"] .mobile-bottom{display:none}

/* Smart TV: interfaz 10-foot, controles grandes y foco muy visible. */
body[data-device="tv"]{--max:1760px;font-size:18px;overflow-x:hidden}
body[data-device="tv"] .wrap{width:min(var(--max),94vw)}
body[data-device="tv"] .topbar{position:sticky;background:rgba(2,5,12,.96)}
body[data-device="tv"] .nav-shell{width:94vw;min-height:96px;gap:32px}
body[data-device="tv"] .brand-logo-3d{width:76px;height:76px}
body[data-device="tv"] .brand-copy-3d strong{font-size:19px}
body[data-device="tv"] .brand-copy-3d small{font-size:11px}
body[data-device="tv"] .main-nav{gap:10px}
body[data-device="tv"] .main-nav a{font-size:17px;padding:16px 13px}
body[data-device="tv"] .header-actions .device-pill{font-size:12px;min-height:40px}
body[data-device="tv"] .header-actions .signal-btn-3d{min-height:58px;padding-inline:24px;font-size:16px}
body[data-device="tv"] .menu-btn,body[data-device="tv"] .mobile-bottom{display:none!important}
body[data-device="tv"] .hero{padding:58px 0}
body[data-device="tv"] .hero h1{font-size:clamp(62px,5.8vw,104px)}
body[data-device="tv"] .hero p{font-size:22px;max-width:800px}
body[data-device="tv"] .hero .actions a{min-height:64px;font-size:18px;padding-inline:28px}
body[data-device="tv"] .section{padding:92px 0;scroll-margin-top:110px}
body[data-device="tv"] .section-head .side,body[data-device="tv"] .section-copy{font-size:19px}
body[data-device="tv"] .section-title-skin{max-width:560px;min-height:80px}
body[data-device="tv"] .section-title-skin.wide{max-width:720px}
body[data-device="tv"] .player-controls button,body[data-device="tv"] .quick-grid button{min-height:64px;font-size:17px}
body[data-device="tv"] .player-controls{gap:12px;padding:16px}
body[data-device="tv"] .schedule h3,body[data-device="tv"] .quick h3,body[data-device="tv"] .platform-status h3{font-size:18px}
body[data-device="tv"] .schedule li{grid-template-columns:82px 1fr;padding:14px 0}
body[data-device="tv"] .schedule time,body[data-device="tv"] .schedule b{font-size:17px}
body[data-device="tv"] .schedule span,body[data-device="tv"] .platform-status>div{font-size:14px}
body[data-device="tv"] .program-mini{min-height:150px}
body[data-device="tv"] .program-mini h3,body[data-device="tv"] .news-chip b,body[data-device="tv"] .content-card h3,body[data-device="tv"] .device-card strong{font-size:22px!important}
body[data-device="tv"] .program-mini p,body[data-device="tv"] .news-chip span,body[data-device="tv"] .content-card p,body[data-device="tv"] .device-card small{font-size:16px}
body[data-device="tv"] a:focus-visible,body[data-device="tv"] button:focus-visible,body[data-device="tv"] input:focus-visible{outline:4px solid #7fe4ff;outline-offset:6px;box-shadow:0 0 0 8px rgba(79,134,255,.22),0 0 34px rgba(78,170,255,.55)}
body[data-device="tv"] .archive-tools input{height:64px;font-size:18px}
body[data-device="tv"] .filter-btn{height:58px;font-size:16px}
body[data-device="tv"] .content-card{min-height:230px}
body[data-device="tv"] footer{padding-bottom:54px}

/* Landscape móvil/tablet: aprovecha la pantalla durante navegación previa al fullscreen. */
body[data-device="mobile"][data-orientation="landscape"] .hero{padding-top:18px}
body[data-device="mobile"][data-orientation="landscape"] .hero-grid{grid-template-columns:.8fr 1.2fr;align-items:center}
body[data-device="mobile"][data-orientation="landscape"] .hero h1{font-size:42px}
body[data-device="mobile"][data-orientation="landscape"] .preview-frame picture img{max-height:72dvh}
body[data-device="tablet"][data-orientation="landscape"] .hero-grid{grid-template-columns:.8fr 1.2fr}

@media (max-width:820px){
  body[data-device="tablet"] .main-nav{position:absolute;top:66px;left:11px;right:11px}
}

/* ===== CANAL NUBRA V3.8 · PREPRODUCCIÓN HARDENING ===== */
.fullscreen-exit{
  display:none;align-items:center;justify-content:center;gap:7px;min-height:36px;padding:0 12px;
  border-radius:11px;border:1px solid rgba(125,190,255,.30);background:rgba(2,8,20,.72);color:#dff5ff;
  font-size:11px;font-weight:800;letter-spacing:.05em;cursor:pointer;
}
.player:fullscreen .fullscreen-exit,
.player:-webkit-full-screen .fullscreen-exit,
.player.pseudo-fullscreen .fullscreen-exit{display:inline-flex}

.player.pseudo-fullscreen{
  position:fixed!important;z-index:1000!important;inset:0!important;width:100vw!important;height:100dvh!important;
  max-width:none!important;margin:0!important;border:0!important;border-radius:0!important;background:#000!important;
  display:grid!important;grid-template-rows:auto auto minmax(0,1fr) auto!important;
}
.player.pseudo-fullscreen .player-stage{width:100vw!important;height:100%!important;min-height:0!important;aspect-ratio:auto!important;background:#000!important}
.player.pseudo-fullscreen .player-stage video,
.player.pseudo-fullscreen .offline-layer img{width:100%!important;height:100%!important;object-fit:contain!important;background:#000!important}
.player.pseudo-fullscreen .player-head,
.player.pseudo-fullscreen .player-controls{background:rgba(0,4,12,.96)!important}
body.player-pseudo-fullscreen{overflow:hidden!important;overscroll-behavior:none}

/* Dialog fallback for older TV browsers without HTMLDialogElement.showModal(). */
dialog.fallback-open{
  display:block;position:fixed;z-index:1200;inset:3vh 2vw auto 2vw;margin:auto;max-height:94vh;overflow:auto;
  background:#01040b;border:1px solid var(--line);border-radius:22px;box-shadow:0 35px 120px #000;
}
dialog.fallback-open::before{content:"";position:fixed;z-index:-1;inset:0;background:rgba(0,0,0,.86)}

/* Five device choices remain balanced after adding Tablet. */
.device-cards{grid-template-columns:repeat(2,minmax(0,1fr))}
.device-card{min-width:0}
@media (min-width:1500px){
  body[data-device="tv"] .device-cards{grid-template-columns:repeat(2,minmax(0,1fr))}
}

/* Responsive 3D art remains crisp without forcing full-size downloads on every screen. */
.section-title-skin img,.brand-logo-3d,.footer-brand img{image-rendering:auto;transform:none;backface-visibility:visible}
.section-title-skin img{height:auto;max-width:100%}

/* Better touch/remote targets and safe areas. */
@media (max-width:820px){
  .fullscreen-exit{min-height:42px;padding-inline:14px}
  .player.pseudo-fullscreen .player-controls{padding-bottom:max(12px,env(safe-area-inset-bottom))!important}
  .player.pseudo-fullscreen .player-head{padding-top:max(8px,env(safe-area-inset-top))!important}
}

@media (prefers-reduced-motion:reduce){
  .signal-btn-3d::after{display:none!important}
  .player-stage video,.offline-layer,.site-toast{transition:none!important}
}


/* =========================================================
   CANAL NUBRA V3.9 · Production polish
   ========================================================= */
html{scroll-padding-top:88px}
body{min-height:100dvh}
.topbar{background:rgba(2,5,12,.9);box-shadow:0 10px 34px rgba(0,0,0,.16)}
.main-nav a{font-weight:720;letter-spacing:.01em}
.main-nav a.active{background-color:rgba(37,103,225,.13);text-shadow:0 0 18px rgba(92,190,255,.34)}
.preview-frame,.skin-panel{isolation:isolate}
.preview-frame img,.skin-panel img,.visual-media img,.interview-strip img{image-rendering:auto;-webkit-transform:translateZ(0);transform:translateZ(0)}
.preview-frame{transition:border-color .25s ease,box-shadow .25s ease,transform .25s ease}
.preview-frame:hover{border-color:rgba(111,188,255,.48);box-shadow:var(--shadow),0 0 92px rgba(39,101,255,.18)}
.signal-btn-3d{position:relative;overflow:hidden}
.signal-btn-3d:after{content:"";position:absolute;inset:-45% auto -45% -45%;width:38%;transform:skewX(-18deg);background:linear-gradient(90deg,transparent,rgba(255,255,255,.42),transparent);opacity:.0}
@media (prefers-reduced-motion:no-preference){
  .signal-btn-3d:hover:after{animation:nubraShine .85s ease}
  @keyframes nubraShine{0%{left:-45%;opacity:0}20%{opacity:.78}100%{left:120%;opacity:0}}
}

/* El primer pantallazo debe funcionar también en notebooks 1366x768. */
@media (min-width:1121px) and (max-height:850px){
  .nav-shell{min-height:68px}
  .hero{padding:26px 0 32px}
  .hero-grid{gap:26px;grid-template-columns:.74fr 1.26fr}
  .hero-title-skin{max-width:190px!important;min-height:48px!important;margin-bottom:4px!important}
  .hero h1{font-size:clamp(54px,5.25vw,74px);margin:10px 0 15px;line-height:.91}
  .hero p{font-size:16px;line-height:1.5;margin:0;max-width:620px}
  .actions{margin-top:18px}
  .hero-meta{margin-top:14px}
  .preview-badge{top:14px;left:14px;padding:7px 10px;font-size:9px}
  .section{scroll-margin-top:74px}
}

/* Mobile: respeta notch/home indicator y evita que la barra inferior tape contenido. */
@media (max-width:820px){
  body{padding-bottom:calc(82px + env(safe-area-inset-bottom,0px))}
  .mobile-bottom{bottom:max(8px,env(safe-area-inset-bottom,0px));left:max(8px,env(safe-area-inset-left,0px));right:max(8px,env(safe-area-inset-right,0px))}
  .mobile-bottom a.active,.mobile-bottom a[aria-current="page"]{color:#fff;background:linear-gradient(180deg,rgba(46,110,255,.18),rgba(97,62,219,.12));box-shadow:inset 0 0 0 1px rgba(106,185,255,.13)}
  .hero-title-skin{margin-bottom:2px!important}
}
@media (max-width:560px){
  .hero{padding-top:22px}
  .hero-grid{gap:18px}
  .hero h1{font-size:clamp(39px,11.8vw,48px);line-height:.94;margin:10px 0 16px}
  .hero p{line-height:1.52;margin:0}
  .actions{margin-top:22px}
  .hero-meta{margin-top:18px;gap:7px 12px}
  .preview-frame{margin-top:2px}
  .preview-badge{top:10px;left:10px;padding:7px 9px;font-size:8px;max-width:calc(100% - 20px);white-space:nowrap;overflow:hidden;text-overflow:ellipsis}
}

/* TV / 10-foot UI: foco visible y densidad moderada. */
body[data-device="tv"] .main-nav a.active{background-color:rgba(44,112,255,.20);box-shadow:inset 0 0 0 1px rgba(109,190,255,.18)}
body[data-device="tv"] .preview-frame{max-width:100%}
body[data-device="tv"] .hero-meta{font-size:14px}

/* Fullscreen propio, incluyendo safe areas. */
.player.pseudo-fullscreen{padding-top:env(safe-area-inset-top,0px);padding-right:env(safe-area-inset-right,0px);padding-bottom:env(safe-area-inset-bottom,0px);padding-left:env(safe-area-inset-left,0px)}

/* Mejora de contraste en información secundaria. */
.hero-meta,.skin-toolbar span,.schedule span,.content-card p,.device-card small{color:#a9bad0}

/* V3.9 final active-state legibility */
.main-nav a:hover,.main-nav a.active{background-image:none!important;-webkit-text-fill-color:#eaf6ff!important;color:#eaf6ff!important}
.mobile-bottom a.active,.mobile-bottom a[aria-current="page"]{background-image:none!important;-webkit-text-fill-color:#f5fbff!important;color:#f5fbff!important;background-color:rgba(46,110,255,.16)!important}


/* ===== V3.9.1 · ESTADO OFFLINE DE PRODUCCIÓN ===== */
.offline-layer{background:#020611!important;overflow:hidden;}
.offline-production{position:relative;width:100%;height:100%;min-height:100%;display:flex;flex-direction:column;align-items:center;justify-content:center;text-align:center;padding:clamp(22px,4vw,60px);isolation:isolate;color:#f4f8ff;}
.offline-production-bg{position:absolute;inset:0;z-index:-2;background:
 radial-gradient(circle at 50% 38%,rgba(63,118,255,.25),transparent 30%),
 radial-gradient(circle at 22% 70%,rgba(104,46,255,.16),transparent 32%),
 radial-gradient(circle at 82% 72%,rgba(0,181,255,.12),transparent 30%),
 linear-gradient(180deg,#030817 0%,#020611 58%,#01030a 100%);}
.offline-production::before{content:"";position:absolute;inset:0;z-index:-1;opacity:.28;background-image:linear-gradient(rgba(103,170,255,.08) 1px,transparent 1px),linear-gradient(90deg,rgba(103,170,255,.08) 1px,transparent 1px);background-size:48px 48px;mask-image:linear-gradient(to bottom,rgba(0,0,0,.45),rgba(0,0,0,.08));}
.offline-production::after{content:"";position:absolute;left:8%;right:8%;bottom:9%;height:1px;background:linear-gradient(90deg,transparent,rgba(79,176,255,.8),rgba(159,93,255,.8),transparent);box-shadow:0 0 22px rgba(73,143,255,.45);}
.offline-logo{width:clamp(90px,12vw,180px);height:auto;object-fit:contain;filter:drop-shadow(0 12px 30px rgba(39,95,255,.35)) drop-shadow(0 0 18px rgba(111,72,255,.2));margin-bottom:14px;}
.offline-kicker{font-size:clamp(10px,1.2vw,14px);font-weight:800;letter-spacing:.32em;text-transform:uppercase;color:#8edaff;margin-bottom:12px;}
.offline-production h3{margin:0;font-size:clamp(28px,4.6vw,64px);line-height:.98;letter-spacing:.05em;font-weight:900;background:linear-gradient(180deg,#fff 8%,#c8ddff 45%,#79aaff 72%,#9c74ff 100%);-webkit-background-clip:text;background-clip:text;color:transparent;text-shadow:0 0 32px rgba(89,137,255,.16);}
.offline-production p{margin:16px 0 0;max-width:740px;font-size:clamp(13px,1.5vw,20px);line-height:1.45;color:#c6d3e7;}
.offline-meta{margin-top:24px;display:flex;flex-wrap:wrap;justify-content:center;gap:10px 24px;font-size:clamp(9px,1vw,12px);letter-spacing:.12em;text-transform:uppercase;color:#7f9fca;}
body[data-channel-mode="offline"] .live-dot{background:#5c83b9;box-shadow:0 0 14px rgba(92,131,185,.45)}
@media (max-width:560px){
  .offline-production{padding:18px 16px 30px;}
  .offline-logo{width:92px;}
  .offline-production h3{font-size:clamp(27px,9vw,38px);}
  .offline-production p{font-size:13px;margin-top:11px;}
  .offline-meta{margin-top:16px;gap:8px;flex-direction:column;}
}
