/* Theme «Прямой эфир»: the site as a TV studio — black, signal red, timecode. */
:root { --bg: #0B0B0D; --panel: #141417; --panel2: #0B0B0D; --line: #26262B; --line2: #3A3A40; --fg: #F4F1EA; --muted: #B9B6AE; --dim: #8D8A83; --red: #FF3B2F; --ok: #3CCF6E; --gold: #FFC24A; color-scheme: dark; }
* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body { margin: 0; background: var(--bg); color: var(--fg); font: 17px/1.55 "Manrope", system-ui, sans-serif; }
a { color: var(--fg); }
.mono { font-family: "JetBrains Mono", ui-monospace, monospace; }
.wrap { max-width: 1280px; margin: 0 auto; padding: 0 32px; }
.head { display: flex; justify-content: space-between; align-items: center; gap: 16px; padding: 22px 32px; max-width: 1280px; margin: 0 auto; }
.bar { border-bottom: 1px solid var(--line); }
.logo { display: flex; align-items: center; gap: 12px; text-decoration: none; }
.logo i { width: 40px; height: 40px; border-radius: 10px; background: var(--red); color: #fff; display: grid; place-items: center; font: 800 18px "Unbounded", sans-serif; font-style: normal; }
.logo span { font: 800 14px/1.1 "Unbounded", sans-serif; text-transform: uppercase; letter-spacing: .02em; }
.nav { display: flex; gap: 28px; align-items: center; font-weight: 600; font-size: 15px; }
.nav a { text-decoration: none; color: var(--muted); }
.nav a:hover { color: var(--fg); }
.pill { display: inline-flex; align-items: center; gap: 8px; padding: 11px 18px; border-radius: 999px; border: 2px solid var(--line2); font-weight: 800; color: var(--fg) !important; text-decoration: none; }
.pill::before { content: ""; width: 8px; height: 8px; border-radius: 50%; background: var(--red); }
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 10px; padding: 17px 26px; border-radius: 999px; background: var(--red); color: #fff; font: 800 17px "Manrope", sans-serif; text-decoration: none; border: 0; cursor: pointer; }
.btn.ghost { background: transparent; border: 2px solid var(--line2); color: var(--fg); }
.btn.light { background: var(--fg); color: var(--bg); }
.onair { display: inline-flex; align-self: flex-start; align-items: center; gap: 12px; padding: 10px 18px; border-radius: 8px; border: 2px solid var(--red); color: var(--red); font: 700 15px "JetBrains Mono", monospace; letter-spacing: .24em; box-shadow: 0 0 24px rgba(255, 59, 47, .35); }
.onair::before { content: ""; width: 10px; height: 10px; border-radius: 50%; background: var(--red); animation: blink 1.4s steps(2, start) infinite; }
@keyframes blink { to { visibility: hidden; } }
@media (prefers-reduced-motion: reduce) { .onair::before { animation: none; } }
h1.big { margin: 0; font: 800 clamp(44px, 6.4vw, 92px)/.96 "Unbounded", sans-serif; letter-spacing: -.02em; text-transform: uppercase; }
h2.sec { margin: 0; font: 800 clamp(30px, 4vw, 48px)/1.1 "Unbounded", sans-serif; text-transform: uppercase; }
.red { color: var(--red); }
.lead { margin: 0; max-width: 46ch; font-size: 20px; color: var(--muted); }

/* the camera viewfinder */
.finder { position: relative; border-radius: 6px; overflow: hidden; background: #121215; }
.finder > img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.finder .c { position: absolute; width: 44px; height: 44px; border: 0 solid #fff; }
.finder .tl { left: 20px; top: 20px; border-left-width: 3px; border-top-width: 3px; }
.finder .tr { right: 20px; top: 20px; border-right-width: 3px; border-top-width: 3px; }
.finder .bl { left: 20px; bottom: 20px; border-left-width: 3px; border-bottom-width: 3px; }
.finder .br { right: 20px; bottom: 20px; border-right-width: 3px; border-bottom-width: 3px; }
.finder .tag { position: absolute; top: 34px; display: flex; align-items: center; gap: 8px; font: 700 15px "JetBrains Mono", monospace; color: #fff; background: rgba(0, 0, 0, .6); padding: 4px 10px; border-radius: 4px; }
.finder .tag.l { left: 36px; } .finder .tag.r { right: 36px; }
.finder .dot { width: 10px; height: 10px; border-radius: 50%; background: var(--red); }
.lower { position: absolute; left: 0; right: 0; bottom: 0; display: flex; }
.lower b { background: var(--red); color: #fff; font: 800 14px "Unbounded", sans-serif; padding: 12px 16px; text-transform: uppercase; }
.lower span { flex: 1; background: rgba(11, 11, 13, .92); font-weight: 600; font-size: 15px; padding: 12px 16px; }

/* home */
.hero { display: grid; grid-template-columns: minmax(0, 1.05fr) minmax(0, 1fr); gap: 48px; align-items: center; padding: 72px 0 80px; }
.hero .finder { aspect-ratio: 4 / 3; }
.hero .finder > img { opacity: .88; }
.program { border-top: 2px solid var(--fg); }
.show { display: grid; grid-template-columns: 150px minmax(0, 1fr) auto; gap: 28px; align-items: center; padding: 28px 0; border-bottom: 1px solid var(--line); }
.show .time { font: 700 34px "JetBrains Mono", monospace; color: var(--red); }
.show h3 { margin: 0 0 8px; font: 800 30px "Unbounded", sans-serif; text-transform: uppercase; }
.show p { margin: 0 0 10px; color: var(--muted); max-width: 60ch; }
.chips { display: flex; gap: 8px; flex-wrap: wrap; font: 13px "JetBrains Mono", monospace; }
.chips span { padding: 4px 10px; border: 1px solid var(--line2); border-radius: 4px; }
.show .go { text-decoration: none; padding: 14px 22px; border-radius: 999px; background: var(--fg); color: var(--bg); font-weight: 800; white-space: nowrap; }
.show.soon { color: var(--dim); }
.show.soon .time, .show.soon p { color: var(--dim); }
.channels { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 20px; }
.channel { background: var(--panel); border: 1px solid var(--line); border-radius: 14px; padding: 26px; }
.channel .mono { color: var(--red); font-weight: 700; }
.channel h3 { margin: 12px 0 10px; font: 600 22px "Unbounded", sans-serif; }
.channel p { margin: 0; color: var(--muted); }
.yt { border: 2px solid var(--fg); border-radius: 18px; padding: 40px; display: flex; justify-content: space-between; align-items: center; gap: 28px; flex-wrap: wrap; }
.play { width: 96px; height: 96px; border-radius: 50%; background: var(--red); color: #fff; display: grid; place-items: center; }
.foot { display: flex; justify-content: space-between; gap: 16px; flex-wrap: wrap; color: var(--muted); font-size: 14px; padding: 24px 32px 40px; max-width: 1280px; margin: 0 auto; border-top: 1px solid var(--line); }

/* sign-in: the viewfinder and the control desk (markup by /login/login.js) */
.login-grid { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 460px); gap: 56px; align-items: center; max-width: 1280px; margin: 0 auto; padding: 24px 32px 56px; }
.login-grid .finder { align-self: stretch; min-height: 560px; display: flex; flex-direction: column; justify-content: center; padding: 56px; }
.login-grid .finder > img { opacity: .28; }
.login-grid .finder > div { position: relative; display: flex; flex-direction: column; gap: 22px; max-width: 560px; }
.desk { background: var(--panel); border: 1px solid var(--line); border-radius: 18px; padding: 28px; }
.desk-top { display: flex; justify-content: space-between; font: 13px "JetBrains Mono", monospace; color: var(--muted); margin-bottom: 14px; }
#app h1 { margin: 0 0 6px; font: 800 30px "Unbounded", sans-serif; text-transform: uppercase; }
#app h2 { margin: 0 0 12px; font: 800 17px "Unbounded", sans-serif; }
#app .muted { color: var(--muted); }
#app .small { font-size: 14px; }
#app .card { background: transparent; border-top: 1px solid var(--line); padding: 18px 0 4px; margin: 14px 0 0; }
#app .tabs { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 6px; background: var(--panel2); padding: 6px; border-radius: 12px; margin: 16px 0 0; }
#app .tabs button { border: 0; border-radius: 9px; padding: 12px 6px; background: transparent; color: var(--muted); font: 800 15px "Manrope", sans-serif; cursor: pointer; }
#app .tabs button.on { background: var(--fg); color: var(--bg); }
#app label { display: block; font-size: 14px; color: var(--muted); margin: 12px 0 6px; }
#app input { width: 100%; padding: 14px 16px; border-radius: 10px; border: 1px solid #33333A; background: var(--panel2); color: var(--fg); font: 16px "Manrope", sans-serif; }
#app input:focus { outline: 2px solid var(--fg); outline-offset: 1px; }
#app .btn { width: 100%; margin-top: 16px; padding: 16px; }
#app .btn:disabled { opacity: .5; cursor: wait; }
#app .link { background: none; border: 0; color: var(--muted); text-decoration: underline; cursor: pointer; font: inherit; padding: 0; }
#app .notice { padding: 12px 14px; border-radius: 10px; margin: 14px 0 0; font-size: 15px; }
#app .notice.ok { background: #16301f; color: #b7f5c9; }
#app .notice.bad { background: #3a1513; color: #ffc4bd; }
#app .notice:empty { display: none; }
#app .or { display: flex; align-items: center; gap: 12px; color: var(--dim); font-size: 13px; margin: 18px 0 0; }
#app .or::before, #app .or::after { content: ""; flex: 1; height: 1px; background: var(--line); }
#app .tg { display: flex; justify-content: center; margin-top: 14px; min-height: 40px; }
#app .row { display: flex; justify-content: space-between; align-items: center; gap: 12px; padding: 10px 0; border-top: 1px solid var(--line); }
#app .row:first-of-type { border-top: 0; }
#app .badge { display: inline-block; font: 700 12px "JetBrains Mono", monospace; padding: 3px 9px; border-radius: 4px; border: 1px solid var(--line2); color: var(--muted); }
#app .badge.ok { color: var(--ok); border-color: #2a5a3a; }
#app .badge.warn { color: var(--gold); border-color: #5a4a20; }
#app .games a { text-decoration: none; font-weight: 800; }

/* 404: no signal */
.nosignal { min-height: calc(100vh - 85px); display: grid; place-items: center; padding: 40px 16px; text-align: center; }
.bars { display: grid; grid-template-columns: repeat(7, minmax(0, 1fr)); width: min(720px, 100%); height: 220px; border-radius: 8px; overflow: hidden; margin: 0 auto 32px; }
.bars span:nth-child(1) { background: #C0C0C0; } .bars span:nth-child(2) { background: #C0C000; } .bars span:nth-child(3) { background: #00C0C0; } .bars span:nth-child(4) { background: #00C000; }
.bars span:nth-child(5) { background: #C000C0; } .bars span:nth-child(6) { background: #C00000; } .bars span:nth-child(7) { background: #0000C0; }

@media (max-width: 900px) {
  .wrap { padding: 0 16px; } .head { padding: 16px; }
  .hero, .channels, .show, .login-grid { grid-template-columns: minmax(0, 1fr); }
  .hero { padding: 36px 0 56px; gap: 28px; }
  .nav .hide { display: none; }
  .login-grid { padding: 8px 16px 40px; gap: 24px; }
  .login-grid .finder { min-height: 260px; padding: 84px 24px 48px; }
  .yt { padding: 26px; }
}
