:root{
  --bg:#0A0D12; --surface:#11161D; --surface2:#171D26; --border:#212935; --border2:#2C3644;
  --text:#E8ECF2; --muted:#8B95A5; --faint:#5C6676;
  --real:#2DD4BF; --real-dim:rgba(45,212,191,.12); --heat:#F5A524; --up:#3FB68B; --down:#E5534B; --r:12px;
  /* назви для tvchart.js */
  --card:#07090D; --mut:#5C6676; --line:#161C25;
}
*{box-sizing:border-box}
html{-webkit-text-size-adjust:100%}
body{margin:0;background:var(--bg);color:var(--text);font:14px/1.5 Inter,system-ui,-apple-system,"Segoe UI",Roboto,sans-serif;font-feature-settings:"tnum" 1}
a{color:inherit;text-decoration:none}
button{font:inherit;color:inherit;background:none;border:0;cursor:pointer}
.dot{width:8px;height:8px;border-radius:2px;display:inline-block;margin-right:6px;vertical-align:0}
.dot.h{background:var(--heat)} .dot.r{background:var(--real)}
.dot.h + .dot.r{margin-left:-3px}
.up{color:var(--up)} .dn{color:var(--down)}

/* шапка */
.top{height:60px;border-bottom:1px solid var(--border);display:flex;align-items:center;gap:28px;padding:0 24px}
.logo{display:flex;align-items:center;gap:10px;font-weight:700;font-size:19px;letter-spacing:-.01em}
.logo .z{color:var(--muted)}
.nav{display:flex;gap:22px;color:var(--muted)}
.nav a:hover,.nav a.on{color:var(--text)}
.top .sp{flex:1}
.langs{position:relative}
.langs summary{list-style:none;cursor:pointer;height:34px;padding:0 12px;border:1px solid var(--border);border-radius:9px;display:flex;align-items:center;color:var(--muted);font-size:13px}
.langs summary::-webkit-details-marker{display:none}
.langs div{position:absolute;right:0;top:40px;background:var(--surface);border:1px solid var(--border2);border-radius:10px;padding:6px;z-index:20;min-width:150px}
.langs a{display:block;padding:7px 10px;border-radius:7px;color:var(--muted)}
.langs a:hover,.langs a.on{background:var(--surface2);color:var(--text)}

/* монети */
.coins-bar{display:flex;align-items:center;gap:16px;padding:14px 24px 0}
.coins{display:flex;gap:6px;overflow-x:auto;scrollbar-width:none}
.coins::-webkit-scrollbar{display:none}
.coin{flex:none;white-space:nowrap;height:38px;padding:0 14px;border-radius:10px;border:1px solid var(--border);background:var(--surface);display:flex;align-items:center;gap:8px;font-weight:500}
.coin small{color:var(--faint);font-weight:400}
.coin.on{background:var(--text);color:var(--bg);border-color:var(--text)} .coin.on small{color:#56606E}
.coins-bar .live{margin-left:auto}
.live{display:flex;align-items:center;gap:6px;color:var(--faint);font-size:12px;white-space:nowrap}
.live:before{content:"";width:6px;height:6px;border-radius:50%;background:var(--up)}
.live.stale:before{background:var(--down)}

/* основна сітка */
.layout{display:grid;grid-template-columns:minmax(0,1fr) 340px;gap:20px;padding:10px 24px 24px;align-items:start}
.h1{font-size:20px;font-weight:600;margin:4px 0 10px;letter-spacing:-.01em}
.tools{display:flex;align-items:center;gap:10px;flex-wrap:wrap;margin-bottom:10px}
.tools .hint{margin-left:auto;font-size:12px;color:var(--faint)}
.seg{display:flex;background:var(--surface);border:1px solid var(--border);border-radius:10px;padding:3px;gap:2px}
.seg button{padding:0 13px;height:30px;border-radius:7px;color:var(--muted);font-size:13px;font-weight:500;white-space:nowrap;display:flex;align-items:center}
.seg button:hover{color:var(--text)}
.seg button.on{background:var(--surface2);color:var(--text);box-shadow:inset 0 0 0 1px var(--border2)}

.cards.near{display:grid;grid-template-columns:1fr 1fr;gap:10px;margin-bottom:10px}
.card{background:var(--surface);border:1px solid var(--border);border-radius:var(--r);padding:12px 14px}
.near .lbl{font-size:12px;color:var(--muted)}
.near .px{font-size:21px;font-weight:600;margin:2px 0 4px;letter-spacing:-.01em}
.near .px b{font-size:13px;font-weight:500;margin-left:6px}
.near .row{display:flex;justify-content:space-between;font-size:12px;color:var(--muted)} .near .row em{font-style:normal;color:var(--text)}

.chart{position:relative;height:clamp(420px,calc(100vh - 330px),760px);border:1px solid var(--border);border-radius:var(--r);overflow:hidden;background:var(--card)}
.loading{position:absolute;inset:0;display:grid;place-items:center;color:var(--faint)}
.legend{display:flex;gap:18px;flex-wrap:wrap;padding:8px 2px 0;font-size:12px;color:var(--faint)}
.tip{position:absolute;z-index:5;width:260px;background:rgba(17,22,29,.97);border:1px solid var(--border2);border-radius:12px;padding:11px 13px;font-size:12px;color:var(--muted);pointer-events:none}
.tip h5{margin:0 0 2px;font-size:12px;font-weight:500;color:var(--muted)}
.tip .p{font-size:19px;font-weight:600;color:var(--text)} .tip .p b{font-size:12px;font-weight:500;margin-left:6px}
.tip .kv{display:flex;justify-content:space-between;margin-top:5px}.tip .kv em{font-style:normal;color:var(--text);font-weight:500}
.tip p{margin:7px 0 0;line-height:1.5}

/* бічна панель */
.side{display:flex;flex-direction:column;gap:12px;padding-top:42px}
.side h4{margin:0 0 10px;font-size:13px;font-weight:600;color:var(--muted);display:flex;justify-content:space-between}
.side h4 span{font-weight:400;color:var(--faint)}
.levels div{display:grid;grid-template-columns:76px 1fr 60px;gap:10px;align-items:center;font-size:13px;padding:4px 0}
.levels .bars{display:flex;flex-direction:column;gap:2px}
.levels .bars i{display:block;height:5px;border-radius:3px}
.levels .v{text-align:right;color:var(--muted);font-size:12px}
.levels .now{border-top:1px dashed var(--border2);margin:4px 0;padding:0;height:0}
.day{display:grid;grid-template-columns:1fr 1fr;gap:10px}
.day div{background:var(--surface2);border-radius:10px;padding:9px 12px;font-size:12px;color:var(--muted)}
.day strong{display:block;color:var(--text);font-size:17px;font-weight:600;margin-top:2px}
.feed div{display:grid;grid-template-columns:52px 1fr auto;gap:8px;padding:7px 0;border-top:1px solid var(--border);font-size:13px;align-items:center}
.feed div:first-child{border-top:0}
.tag{font-size:11px;font-weight:600;padding:2px 6px;border-radius:5px;text-align:center}
.tag.l{background:rgba(229,83,75,.14);color:#F08A84} .tag.s{background:rgba(63,182,139,.14);color:#6FD0AA}
.feed .ex{color:var(--muted);font-size:12px}
.ref{display:flex;justify-content:space-between;align-items:center;font-size:13px;color:var(--muted)}
.ref a{border:1px solid var(--border2);border-radius:8px;padding:5px 10px;font-size:12px;color:var(--text);font-weight:500}

/* під картою */
.below{padding:8px 24px 40px;display:grid;grid-template-columns:minmax(0,1fr) 340px;gap:20px}
.below h2{font-size:18px;font-weight:600;margin:20px 0 12px}
.intro{color:var(--muted);font-size:15px;line-height:1.7;max-width:820px;margin:8px 0 0}
.steps{display:grid;grid-template-columns:repeat(3,1fr);gap:12px}
.step{background:var(--surface);border:1px solid var(--border);border-radius:var(--r);padding:14px 16px}
.step b{display:inline-grid;place-items:center;width:24px;height:24px;border-radius:7px;background:var(--surface2);font-size:12px;color:var(--muted);margin-bottom:8px}
.step strong{display:block;font-weight:500;margin-bottom:4px} .step p{margin:0;font-size:13px;color:var(--muted)}
.more a{color:var(--real)}
.note{margin-top:12px;padding:12px 16px;border-radius:var(--r);background:var(--real-dim);color:#9BE7DA;font-size:13px;line-height:1.6}
.note b{color:#CFF5EE}
.faq details{border-bottom:1px solid var(--border);padding:12px 0}
.faq summary{cursor:pointer;list-style:none;display:flex;justify-content:space-between;gap:10px}
.faq summary::-webkit-details-marker{display:none}
.faq summary:after{content:"+";color:var(--faint)}
.faq details[open] summary:after{content:"−"}
.faq p{margin:8px 0 0;color:var(--muted);font-size:13px;line-height:1.6}
.other{display:flex;flex-wrap:wrap;gap:8px}
.other a{padding:6px 12px;border:1px solid var(--border);border-radius:9px;color:var(--muted);font-size:13px}
.other a:hover{color:var(--text)}

/* гайд */
.article{max-width:760px;margin:0 auto;padding:28px 24px 48px}
.article h1{font-size:28px;font-weight:600;letter-spacing:-.02em;margin:0 0 8px}
.article h2{font-size:19px;font-weight:600;margin:28px 0 8px}
.article p{color:var(--muted);font-size:15px;line-height:1.75;margin:0}
.article .more{margin:28px 0 14px}

.foot{border-top:1px solid var(--border);padding:18px 24px;color:var(--faint);font-size:12px;display:flex;justify-content:space-between;gap:12px;flex-wrap:wrap}

/* планшет і телефон */
@media (max-width:1000px){
  .layout,.below{grid-template-columns:minmax(0,1fr)}
  .side{padding-top:0}
}
@media (max-width:640px){
  .top{padding:0 14px;gap:14px}
  .nav{display:none}
  .coins-bar{padding:10px 14px 0}
  .coins-bar .live{display:none}
  .layout{padding:8px 14px 18px}
  .below{padding:0 14px 32px}
  .h1{font-size:17px}
  .tools .hint{display:none}
  .seg{width:100%}
  .seg button{flex:1;justify-content:center;padding:0 6px;font-size:12px}
  .chart{height:400px}
  .near .px{font-size:18px}
  .steps{grid-template-columns:1fr}
  .tip{width:calc(100% - 20px);left:10px!important}
}
