:root {
  --bg: #0b0d12; --panel: #141821; --panel2: #1b2030; --line: #262c3d;
  --text: #e9ecf3; --muted: #8d95a8; --accent: #ff4d2e; --accent2: #ffb020; --ok: #2ecc71;
  --radius: 14px;
}
* { box-sizing: border-box; }
body { margin: 0; background: var(--bg); color: var(--text); font: 16px/1.55 system-ui, -apple-system, "Segoe UI", Roboto, sans-serif; }
a { color: inherit; }
.wrap { max-width: 1120px; margin: 0 auto; padding: 0 16px; }

/* header */
header.top { position: sticky; top: 0; z-index: 10; background: rgba(11,13,18,.85); backdrop-filter: blur(10px); border-bottom: 1px solid var(--line); }
header.top .wrap { display: flex; align-items: center; gap: 24px; height: 64px; }
.logo { font-weight: 800; font-size: 20px; text-decoration: none; display: flex; align-items: center; gap: 8px; }
.logo i { width: 26px; height: 26px; border-radius: 50%; background: conic-gradient(var(--accent), var(--accent2), var(--accent)); display: inline-block; box-shadow: 0 0 18px rgba(255,77,46,.5); }
nav.links { display: flex; gap: 20px; margin-left: auto; align-items: center; }
nav.links a { text-decoration: none; color: var(--muted); }
nav.links a:hover { color: var(--text); }

/* buttons & forms */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 8px; border: 0; cursor: pointer;
  padding: 12px 22px; border-radius: 10px; font-weight: 700; font-size: 15px; text-decoration: none;
  background: var(--accent); color: #fff; transition: transform .1s, filter .15s; }
.btn:hover { filter: brightness(1.1); }
.btn:active { transform: scale(.98); }
.btn.ghost { background: transparent; border: 1px solid var(--line); color: var(--text); }
.btn.small { padding: 8px 14px; font-size: 14px; }
.btn.sbp { background: linear-gradient(90deg, #5b2bd9, #1d9bf0); }
.btn.green { background: var(--ok); }
input, select { width: 100%; padding: 12px 14px; border-radius: 10px; border: 1px solid var(--line); background: var(--panel2); color: var(--text); font-size: 15px; }
label { display: block; font-size: 14px; color: var(--muted); margin: 12px 0 6px; }
.error { color: #ff7a6b; min-height: 22px; font-size: 14px; margin-top: 8px; }

/* hero */
.hero { padding: 90px 0 60px; text-align: center; }
.badge { display: inline-flex; gap: 8px; align-items: center; padding: 6px 14px; border: 1px solid var(--line); border-radius: 99px; color: var(--muted); font-size: 14px; }
.dot { width: 8px; height: 8px; border-radius: 50%; background: var(--ok); box-shadow: 0 0 0 0 rgba(46,204,113,.7); animation: pulse 1.6s infinite; }
@keyframes pulse { 70% { box-shadow: 0 0 0 10px rgba(46,204,113,0); } 100% { box-shadow: 0 0 0 0 rgba(46,204,113,0); } }
.hero h1 { font-size: clamp(34px, 6vw, 62px); line-height: 1.08; margin: 22px auto 18px; max-width: 900px; letter-spacing: -.02em; }
.hero h1 span { background: linear-gradient(90deg, var(--accent), var(--accent2)); -webkit-background-clip: text; background-clip: text; color: transparent; }
.hero p { color: var(--muted); font-size: 19px; max-width: 680px; margin: 0 auto 30px; }
.hero .cta { display: flex; gap: 12px; justify-content: center; flex-wrap: wrap; }

section { padding: 60px 0; }
section h2 { font-size: clamp(26px, 4vw, 38px); margin: 0 0 10px; text-align: center; }
section .sub { color: var(--muted); text-align: center; margin: 0 auto 40px; max-width: 640px; }

.grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(250px, 1fr)); gap: 16px; }
.card { background: var(--panel); border: 1px solid var(--line); border-radius: var(--radius); padding: 24px; }
.card .ico { font-size: 28px; }
.card h3 { margin: 10px 0 6px; font-size: 19px; }
.card p { margin: 0; color: var(--muted); }

.steps { counter-reset: s; }
.steps .card::before { counter-increment: s; content: counter(s); display: inline-grid; place-items: center; width: 34px; height: 34px; border-radius: 50%; background: var(--panel2); color: var(--accent2); font-weight: 800; }

/* pricing */
.prices { display: grid; grid-template-columns: repeat(auto-fit, minmax(280px, 1fr)); gap: 20px; max-width: 760px; margin: 0 auto; }
.price { position: relative; }
.price.best { border-color: var(--accent); box-shadow: 0 0 40px rgba(255,77,46,.15); }
.price .tag { position: absolute; top: -12px; right: 20px; background: var(--accent); color: #fff; font-size: 13px; font-weight: 700; padding: 3px 12px; border-radius: 99px; }
.price .amount { font-size: 44px; font-weight: 800; margin: 8px 0 0; }
.price .amount small { font-size: 16px; color: var(--muted); font-weight: 500; }
.price .rub { color: var(--muted); margin-bottom: 16px; }
.price ul { padding: 0; list-style: none; margin: 0 0 22px; }
.price li { padding: 5px 0 5px 26px; position: relative; color: #cfd4e0; }
.price li::before { content: "✓"; position: absolute; left: 0; color: var(--ok); font-weight: 800; }
.price .btn { width: 100%; margin-top: 8px; }

/* faq */
details { background: var(--panel); border: 1px solid var(--line); border-radius: 12px; padding: 16px 20px; margin-bottom: 10px; }
summary { cursor: pointer; font-weight: 600; }
details p { color: var(--muted); margin: 10px 0 0; }

footer { border-top: 1px solid var(--line); padding: 30px 0; color: var(--muted); font-size: 14px; margin-top: 40px; }
footer .wrap { display: flex; gap: 20px; flex-wrap: wrap; justify-content: space-between; }

/* modal */
.modal { position: fixed; inset: 0; background: rgba(0,0,0,.65); display: none; place-items: center; z-index: 50; padding: 16px; }
.modal.open { display: grid; }
.modal .box { background: var(--panel); border: 1px solid var(--line); border-radius: 18px; padding: 28px; width: 100%; max-width: 440px; max-height: 92vh; overflow: auto; position: relative; }
.modal .close { position: absolute; top: 12px; right: 14px; background: none; border: 0; color: var(--muted); font-size: 26px; cursor: pointer; }
.req { background: var(--panel2); border-radius: 12px; padding: 14px 16px; margin: 14px 0; }
.req div { display: flex; justify-content: space-between; gap: 10px; padding: 4px 0; }
.req b { cursor: pointer; }
.req b:hover { color: var(--accent2); }

/* app feed */
.toolbar { display: flex; gap: 10px; flex-wrap: wrap; align-items: center; margin: 24px 0 16px; }
.seg { display: inline-flex; background: var(--panel); border: 1px solid var(--line); border-radius: 10px; overflow: hidden; }
.seg button { background: none; border: 0; color: var(--muted); padding: 9px 16px; cursor: pointer; font-weight: 600; }
.seg button.on { background: var(--panel2); color: var(--text); }
.status { color: var(--muted); font-size: 14px; margin-left: auto; display: flex; align-items: center; gap: 8px; }
.feed { display: grid; grid-template-columns: repeat(auto-fill, minmax(280px, 1fr)); gap: 16px; }
.vid { background: var(--panel); border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden; text-decoration: none; display: flex; flex-direction: column; }
.vid:hover { border-color: #3a4260; }
.vid .thumb { position: relative; aspect-ratio: 16/9; background: #000 center/cover; }
.vid .thumb .fire { position: absolute; top: 8px; left: 8px; background: var(--accent); color: #fff; font-weight: 800; font-size: 13px; padding: 3px 9px; border-radius: 6px; }
.vid .thumb .kind { position: absolute; top: 8px; right: 8px; background: rgba(0,0,0,.75); font-size: 12px; padding: 3px 8px; border-radius: 6px; }
.vid .body { padding: 12px 14px 14px; }
.vid .t { font-weight: 600; line-height: 1.35; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.vid .ch { color: var(--muted); font-size: 14px; margin: 4px 0 10px; }
.stats { display: grid; grid-template-columns: repeat(3, 1fr); gap: 6px; font-size: 13px; }
.stats div { background: var(--panel2); border-radius: 8px; padding: 6px 8px; }
.stats span { display: block; color: var(--muted); font-size: 11px; }
.locked { text-align: center; padding: 40px 20px; margin-top: 16px; background: linear-gradient(180deg, transparent, var(--panel)); border: 1px dashed var(--line); border-radius: var(--radius); }
.empty { color: var(--muted); text-align: center; padding: 60px 0; }

table { width: 100%; border-collapse: collapse; font-size: 14px; }
th, td { text-align: left; padding: 10px; border-bottom: 1px solid var(--line); }
th { color: var(--muted); font-weight: 600; }
.pill { padding: 2px 10px; border-radius: 99px; font-size: 12px; font-weight: 700; }
.pill.pending { background: #3b2f10; color: var(--accent2); }
.pill.paid { background: #10301f; color: var(--ok); }
.pill.rejected { background: #3a1616; color: #ff7a6b; }

@media (max-width: 640px) {
  nav.links .hide-m { display: none; }
  .hero { padding: 56px 0 40px; }
  .status { margin-left: 0; width: 100%; }
}

/* nav inside app */
.appnav { display: flex; gap: 6px; }
.appnav a { white-space: nowrap; padding: 7px 12px; border-radius: 8px; text-decoration: none; color: var(--muted); font-weight: 600; }
.appnav a.on, .appnav a:hover { color: var(--text); background: var(--panel2); }

/* score badge: number always shown, colour only reinforces it */
.score { display: inline-flex; align-items: center; gap: 3px; font-weight: 800; font-size: 12px; padding: 2px 8px; border-radius: 6px; background: #2a2f3d; color: #b8bfcf; }
.score.mid { background: #133a26; color: #4fdc8f; }
.score.high { background: #47240c; color: #ff9a4a; }
.pill-v { display: inline-flex; align-items: center; gap: 4px; font-size: 12px; font-weight: 700; padding: 2px 8px; border-radius: 6px; background: #252a52; color: #aab4ff; }

/* search */
.searchbar { display: flex; gap: 10px; margin: 24px 0 14px; }
.searchbar input { font-size: 16px; padding: 14px 16px; }
.filters { display: flex; gap: 10px; flex-wrap: wrap; margin-bottom: 14px; }
.filters select { width: auto; padding: 9px 12px; font-size: 14px; }
.tabs { display: flex; gap: 6px; border-bottom: 1px solid var(--line); margin-bottom: 16px; flex-wrap: wrap; }
.tabs button { background: none; border: 0; border-bottom: 2px solid transparent; color: var(--muted); padding: 10px 14px; font-weight: 700; cursor: pointer; font-size: 15px; }
.tabs button.on { color: var(--text); border-color: #5b8cff; }
.tabs b { background: var(--panel2); border-radius: 6px; padding: 1px 7px; margin-left: 6px; font-size: 12px; }
.rows { display: grid; gap: 12px; }
.row { display: grid; grid-template-columns: 240px 1fr; gap: 16px; background: var(--panel); border: 1px solid var(--line); border-radius: var(--radius); padding: 12px; }
.row .thumb { position: relative; aspect-ratio: 16/9; border-radius: 10px; background: #000 center/cover; display: block; }
.dur { position: absolute; right: 6px; bottom: 6px; background: rgba(0,0,0,.8); font-size: 12px; padding: 1px 6px; border-radius: 4px; }
.row .t { font-weight: 700; font-size: 16px; line-height: 1.35; margin-bottom: 6px; text-decoration: none; display: block; }
.row .meta { display: flex; gap: 8px; align-items: center; flex-wrap: wrap; font-size: 13px; color: var(--muted); }
.chbox { display: flex; gap: 10px; align-items: center; margin-top: 10px; flex-wrap: wrap; }
.chbox .name { font-weight: 700; text-decoration: none; display: flex; align-items: center; gap: 8px; }
.chbox .name:hover { color: #8fb0ff; }
.chbox .name img { width: 26px; height: 26px; border-radius: 50%; }
.mini { display: inline-flex; flex-direction: column; background: var(--panel2); border-radius: 8px; padding: 4px 10px; font-size: 13px; font-weight: 700; }
.mini span { font-size: 10px; color: var(--muted); font-weight: 500; }
.linkbtn { background: none; border: 0; color: var(--muted); cursor: pointer; font-size: 13px; padding: 4px; }
.linkbtn:hover { color: var(--text); }

/* channel page */
.chlayout { display: grid; grid-template-columns: 290px 1fr; gap: 20px; margin-top: 24px; align-items: start; }
.chcard { text-align: center; position: sticky; top: 80px; }
.chcard img { width: 96px; height: 96px; border-radius: 50%; background: var(--panel2); }
.chcard h2 { font-size: 20px; margin: 10px 0 14px; text-align: center; }
.tiles { display: grid; grid-template-columns: repeat(3, 1fr); gap: 6px; }
.tiles.two { grid-template-columns: 1fr 1fr; margin-top: 6px; }
.tile { background: var(--panel2); border-radius: 10px; padding: 10px 4px; }
.tile b { display: block; font-size: 17px; }
.tile span { font-size: 12px; color: var(--muted); }
.chips { display: flex; gap: 8px; flex-wrap: wrap; margin: 8px 0 16px; }
.chip { background: #10301f; color: #4fdc8f; border: 1px solid #1b4d33; border-radius: 9px; padding: 6px 12px; font-weight: 700; font-size: 14px; }
.chip span { color: var(--muted); font-weight: 600; margin-right: 6px; }
.chip.na { background: var(--panel2); border-color: var(--line); color: var(--muted); }
.chart { position: relative; }
.chart svg { display: block; width: 100%; height: 260px; overflow: visible; }
.chart .tip { position: absolute; pointer-events: none; background: #0e1118; border: 1px solid var(--line); border-radius: 10px; padding: 8px 12px; font-size: 13px; white-space: nowrap; display: none; z-index: 5; box-shadow: 0 8px 24px rgba(0,0,0,.4); }
.chart .tip b { font-size: 16px; }
.legend { display: flex; gap: 16px; font-size: 13px; color: var(--muted); margin-top: 8px; flex-wrap: wrap; }
.legend i { display: inline-block; width: 18px; height: 0; border-top: 2px solid; vertical-align: middle; margin-right: 6px; }
.sum { display: grid; grid-template-columns: repeat(auto-fit, minmax(150px, 1fr)); gap: 10px; margin: 16px 0; }
.vgrid { display: grid; grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); gap: 12px; }
.vcard { background: var(--panel); border: 1px solid var(--line); border-radius: 12px; overflow: hidden; }
.vcard .thumb { position: relative; aspect-ratio: 16/9; background: #000 center/cover; display: block; }
.vcard .acts { position: absolute; inset: 0; display: none; align-items: center; justify-content: center; gap: 8px; background: rgba(0,0,0,.45); }
.vcard:hover .acts { display: flex; }
.vcard .acts a { background: rgba(20,24,33,.92); border-radius: 8px; padding: 7px 10px; font-size: 13px; text-decoration: none; font-weight: 600; }
.vcard .b { padding: 10px 12px; }
.vcard .t { font-size: 14px; font-weight: 600; line-height: 1.35; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; min-height: 38px; }
.vcard .meta { display: flex; gap: 6px; align-items: center; flex-wrap: wrap; margin-top: 8px; font-size: 12px; color: var(--muted); }
.note { color: var(--muted); font-size: 14px; background: var(--panel2); border-radius: 10px; padding: 12px 14px; }

@media (max-width: 860px) {
  .chlayout { grid-template-columns: 1fr; }
  .chcard { position: static; }
  .row { grid-template-columns: 1fr; }
  .appnav a { padding: 7px 10px; font-size: 18px; }
  .appnav .lbl { display: none; }
  header.top .wrap { gap: 12px; }
}

/* video spotlight */
.vspot { display: grid; grid-template-columns: minmax(0, 1.25fr) minmax(0, 1fr); gap: 22px; margin-top: 24px; }
.vplayer { position: relative; aspect-ratio: 16/9; border-radius: 12px; overflow: hidden; background: #000; }
.vplayer.short { aspect-ratio: 9/16; max-height: 560px; margin: 0 auto; width: auto; height: 560px; }
.vplayer iframe { position: absolute; inset: 0; width: 100%; height: 100%; border: 0; }
.vinfo h1 { font-size: 22px; line-height: 1.3; margin: 0; }
.vinfo .sum { grid-template-columns: repeat(auto-fit, minmax(140px, 1fr)); }
.mini.big { padding: 8px 12px; font-size: 16px; }
.mini.big small { color: var(--muted); font-weight: 500; }
.kw { display: flex; flex-wrap: wrap; gap: 6px; }
.kw a { background: var(--panel2); border-radius: 8px; padding: 5px 10px; font-size: 13px; text-decoration: none; }
.kw a:hover { background: #252a52; }
.kw b { color: var(--muted); font-weight: 600; margin-left: 4px; }

/* publishing heatmap: number of uploads, darker = fewer */
.schedsum { display: grid; gap: 6px; margin-bottom: 14px; font-size: 15px; }
.heat { display: grid; grid-template-columns: 30px repeat(24, minmax(0, 1fr)); gap: 3px; }
.heat .hh { font-size: 10px; color: var(--muted); text-align: center; }
.heat .hd { font-size: 12px; color: var(--muted); display: flex; align-items: center; }
.hc { aspect-ratio: 1; border-radius: 3px; background: #1d2230; display: inline-block; }
.hc.l1 { background: #1d4733; } .hc.l2 { background: #23744a; } .hc.l3 { background: #2ea463; } .hc.l4 { background: #4fdc8f; }
.htip { min-height: 22px; margin-top: 8px; font-size: 13px; color: var(--text); visibility: hidden; }
.legend .hc { vertical-align: middle; }

@media (max-width: 860px) {
  .vspot { grid-template-columns: 1fr; }
  .vplayer.short { height: 480px; }
  .heat { grid-template-columns: 24px repeat(24, minmax(0, 1fr)); gap: 2px; }
}

/* library bookmark + toast */
.bm { background: var(--panel2); border: 1px solid var(--line); color: var(--muted); border-radius: 8px; padding: 4px 9px; cursor: pointer; font-size: 13px; filter: grayscale(1); opacity: .8; }
.bm:hover { opacity: 1; filter: none; }
.bm.on { filter: none; opacity: 1; background: #252a52; border-color: #5b8cff; color: var(--text); }
#toast { position: fixed; left: 50%; bottom: 24px; transform: translate(-50%, 20px); background: #0e1118; border: 1px solid var(--line); border-radius: 10px;
  padding: 10px 18px; opacity: 0; transition: .2s; z-index: 100; pointer-events: none; box-shadow: 0 8px 24px rgba(0,0,0,.4); }
#toast.show { opacity: 1; transform: translate(-50%, 0); }
@media (max-width: 1180px) { .appnav .lbl { display: none; } .appnav a { font-size: 18px; padding: 7px 10px; } }

/* analysis panel (search + mass analysis) */
:root { --series: #5b8cff; --median: #8d95a8; --trend: #c97a26; }
.an { margin-bottom: 16px; }
.insights { display: grid; gap: 8px; margin-bottom: 16px; }
.insights div { background: #13261c; border: 1px solid #1b4d33; border-radius: 10px; padding: 10px 14px; }
.an-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(420px, 1fr)); gap: 12px; }
.card.sub { background: var(--panel2); padding: 16px; text-align: left; max-width: none; margin: 0; color: var(--text); }
.card.sub h4 { margin: 0 0 10px; }
.muted { color: var(--muted); font-weight: 400; font-size: 13px; }
.minis { display: flex; gap: 8px; flex-wrap: wrap; margin-top: 10px; }
.minis .mini { background: var(--panel); }
.hbar { display: grid; grid-template-columns: 140px 1fr 110px; gap: 10px; align-items: center; font-size: 13px; margin: 6px 0; }
.hbar .hl { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.hbar .hl a { text-decoration: none; } .hbar .hl a:hover { color: #8fb0ff; }
.hbar .ht { background: var(--panel); border-radius: 4px; height: 10px; overflow: hidden; }
.hbar .ht i { display: block; height: 100%; background: var(--series); border-radius: 4px; }
.hbar .hv { color: var(--muted); text-align: right; }
.corr { display: flex; justify-content: space-between; align-items: center; gap: 10px; padding: 8px 0; border-bottom: 1px solid var(--line); font-size: 14px; }
.tag { font-size: 12px; font-weight: 700; padding: 3px 9px; border-radius: 6px; background: var(--panel); color: #cfd4e0; white-space: nowrap; }
.tag.up { background: #10301f; color: #4fdc8f; }
.kw { display: flex; flex-wrap: wrap; gap: 6px; }
.kw a { background: var(--panel); border-radius: 8px; padding: 5px 10px; font-size: 13px; text-decoration: none; }
.kw a:hover { background: #252a52; }
.kw b { color: var(--muted); font-weight: 600; margin-left: 4px; }
@media (max-width: 560px) { .an-grid { grid-template-columns: 1fr; } .hbar { grid-template-columns: 100px 1fr 80px; } }
.appnav .sig { position: relative; }
.badge { position: absolute; top: 0; right: 0; background: var(--accent); color: #fff; font-size: 10px; border-radius: 8px; padding: 0 5px; line-height: 16px; }
.steps-pay { color: var(--muted); padding-left: 20px; margin: 0 0 6px; font-size: 14px; }
.steps-pay li { margin: 4px 0; }
/* long values (wallet addresses) wrap instead of overflowing the payment box */
.req div { align-items: flex-start; }
.req span { flex: none; }
.req b { text-align: right; word-break: break-all; min-width: 0; }
.req .addr { display: block; text-align: left; }
/* deep channel analysis */
.weeks { display: grid; grid-template-columns: repeat(12, 1fr); gap: 6px; height: 110px; align-items: end; }
.weeks div { display: flex; flex-direction: column-reverse; height: 100%; position: relative; padding-bottom: 16px; }
.weeks i { display: block; border-radius: 3px 3px 0 0; min-height: 0; }
.weeks i + i { border-radius: 0; }
.weeks span { position: absolute; bottom: 0; left: 0; right: 0; text-align: center; font-size: 10px; color: var(--muted); }
.hit { display: grid; grid-template-columns: 64px 1fr auto; gap: 8px; align-items: center; padding: 5px 0; text-decoration: none; font-size: 13px; border-bottom: 1px solid var(--line); }
.hit img { width: 64px; border-radius: 4px; }
.hit span { overflow: hidden; text-overflow: ellipsis; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; }
.hit:hover span { color: #8fb0ff; }
.simgrid { display: grid; grid-template-columns: repeat(auto-fill, minmax(180px, 1fr)); gap: 10px; }
.simgrid a { display: grid; grid-template-columns: 36px 1fr; gap: 2px 10px; align-items: center; background: var(--panel2); border-radius: 10px; padding: 10px; text-decoration: none; }
.simgrid img { width: 36px; height: 36px; border-radius: 50%; grid-row: span 2; background: var(--panel); }
.simgrid b { font-size: 14px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.simgrid small { color: var(--muted); font-size: 12px; }
.simgrid a:hover b { color: #8fb0ff; }
.freshrow { display: grid; grid-template-columns: 96px 1fr; gap: 12px; align-items: center; padding: 8px 0; border-bottom: 1px solid var(--line); text-decoration: none; }
.freshrow img { width: 96px; border-radius: 6px; }
.freshrow .ft { font-weight: 600; font-size: 14px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.freshrow .fm { font-size: 12px; color: var(--muted); }
.freshrow:hover .ft { color: #8fb0ff; }
