* { box-sizing: border-box; }
body { margin: 0; background: #0b0e11; color: #eaecef;
  font-family: -apple-system, "Segoe UI", Roboto, sans-serif; }
.dash { max-width: 1180px; margin: 0 auto; min-height: 100vh; }
.ticker { display: flex; flex-wrap: wrap; background: #12161c; border-bottom: 1px solid #1f2630; font-size: 13px; position: sticky; top: 0; z-index: 5; }
.ticker .t { padding: 9px 15px; border-right: 1px solid #1f2630; white-space: nowrap; }
.ticker .sym { color: #9aa4b2; margin-right: 7px; }
.ticker .live { color: #9aa4b2; margin-left: auto; border: none; }
#livedot { color: #0ecb81; }
.up { color: #0ecb81; } .dn { color: #f6465d; }
.body { display: flex; min-height: calc(100vh - 38px); }
.side { width: 168px; background: #12161c; border-right: 1px solid #1f2630; padding: 14px 0; font-size: 14px; flex-shrink: 0; }
.side .brand { font-weight: 700; letter-spacing: 1px; padding: 6px 18px 16px; color: #f0b90b; }
.side .nav { padding: 11px 18px; color: #b7bfca; border-left: 3px solid transparent; display: flex; justify-content: space-between; align-items: center; }
.side .nav.active { background: #0b0e11; color: #fff; border-left: 3px solid #f0b90b; }
.side .nav.soon { color: #5b6573; }
.side .nav.soon span { font-size: 9px; text-transform: uppercase; background: #1f2630; color: #7a8595; padding: 2px 6px; border-radius: 8px; }
.main { flex: 1; padding: 16px; min-width: 0; }
.brief { background: linear-gradient(90deg, #11202a, #12161c); border: 1px solid #1f3340; border-radius: 9px; padding: 12px 15px; font-size: 13.5px; color: #dfe6ee; margin-bottom: 14px; line-height: 1.5; }
.grid { display: grid; grid-template-columns: 1fr 1fr 1fr; gap: 12px; }
.card { background: #12161c; border: 1px solid #1f2630; border-radius: 9px; padding: 13px; }
.card.span2 { grid-column: span 2; }
.card.warn { border-color: #3a2630; } .card.amber { border-color: #3a3326; }
.card h4 { margin: 0 0 8px; font-size: 11px; text-transform: uppercase; letter-spacing: .5px; color: #9aa4b2; font-weight: 600; }
.big { font-size: 25px; font-weight: 700; }
.big.small { font-size: 19px; } .big.gold { color: #f0b90b; } .big.hl { color: #f6465d; }
.stancetag { font-size: 13px; color: #0ecb81; font-weight: 600; }
.sub { font-size: 12px; color: #9aa4b2; margin-top: 4px; }
.gauge { height: 8px; background: #1f2630; border-radius: 4px; margin: 9px 0 4px; overflow: hidden; }
.gauge > span { display: block; height: 100%; background: linear-gradient(90deg, #0ecb81, #f0b90b, #f6465d); transition: width .4s; }
.riskrow { display: flex; gap: 22px; margin-top: 8px; flex-wrap: wrap; }
.riskrow .stat { font-size: 12px; color: #9aa4b2; }
.riskrow .stat b { display: block; font-size: 16px; color: #eaecef; margin-top: 2px; }
.row { display: flex; justify-content: space-between; font-size: 13px; padding: 4px 0; border-bottom: 1px solid #19202a; }
.feed { font-size: 12px; color: #cfd6df; line-height: 1.6; }
.feed div { margin-bottom: 3px; }
.feed .a { color: #f6465d; } .feed .g { color: #0ecb81; }
.foot { margin-top: 16px; font-size: 11px; color: #5b6573; text-align: center; }
body.stale #livedot { color: #f6465d; }
body.stale #livetxt::after { content: " (delayed)"; }
@media (max-width: 760px) {
  .body { flex-direction: column; }
  .side { width: 100%; display: flex; flex-wrap: wrap; gap: 4px; }
  .grid { grid-template-columns: 1fr; }
  .card.span2 { grid-column: span 1; }
}

/* ---- multi-section ---- */
.sectitle { margin: 2px 0 14px; font-size: 17px; color: #eaecef; }
.muted { color: #5b6573; font-size: 13px; }
.grid3 { display: grid; grid-template-columns: 1fr 1fr 1fr; gap: 12px; margin-bottom: 14px; }
.grid4 { display: grid; grid-template-columns: repeat(4, 1fr); gap: 10px; margin-bottom: 16px; }
.panel { background: #12161c; border: 1px solid #1f2630; border-radius: 9px; padding: 13px 15px; margin-bottom: 14px; }
.panel h4 { margin: 0 0 10px; font-size: 11px; text-transform: uppercase; letter-spacing: .5px; color: #9aa4b2; }
.panel table { width: 100%; border-collapse: collapse; font-size: 13px; }
.panel th { text-align: left; color: #7a8595; font-weight: 600; font-size: 11px; text-transform: uppercase; padding: 4px 0; border-bottom: 1px solid #1f2630; }
.panel td { padding: 6px 0; border-bottom: 1px solid #19202a; }
.panel td:last-child, .panel th:last-child { text-align: right; }
.panel tr:last-child td { border-bottom: none; }
.minibar { display: inline-block; width: 70px; height: 6px; background: #1f2630; border-radius: 3px; overflow: hidden; vertical-align: middle; margin-right: 6px; }
.minibar > span { display: block; height: 100%; background: linear-gradient(90deg, #0ecb81, #f0b90b, #f6465d); }
.mini { color: #5b6573; }
/* coins */
.coingrid { display: grid; grid-template-columns: 1fr 1fr 1fr; gap: 12px; }
.coincard { background: #12161c; border: 1px solid #1f2630; border-radius: 9px; padding: 13px; }
.coinhd { display: flex; justify-content: space-between; align-items: baseline; margin-bottom: 8px; border-bottom: 1px solid #1f2630; padding-bottom: 8px; }
.coinhd .cs { font-size: 18px; font-weight: 700; color: #f0b90b; }
.coinhd .cp { font-size: 16px; font-weight: 600; }
.coincard .row { font-size: 12.5px; }
.coincard .tgt { font-size: 11.5px; color: #9aa4b2; margin-top: 8px; line-height: 1.5; }
.coincard .tgt .g { color: #0ecb81; } .coincard .tgt .a { color: #f6465d; }
/* macro */
.mtile { background: #12161c; border: 1px solid #1f2630; border-radius: 8px; padding: 11px 12px; }
.mtile .ml { font-size: 10.5px; text-transform: uppercase; letter-spacing: .4px; color: #9aa4b2; }
.mtile .mv { font-size: 19px; font-weight: 700; margin-top: 4px; }
.mline { font-size: 12.5px; color: #cfd6df; padding: 5px 0; border-bottom: 1px solid #19202a; line-height: 1.45; }
.mline b { color: #f0b90b; text-transform: capitalize; }
/* charts */
.chartbtns { display: flex; flex-wrap: wrap; gap: 6px; margin-bottom: 12px; }
.cbtn { background: #12161c; border: 1px solid #1f2630; color: #b7bfca; padding: 6px 13px; border-radius: 7px; font-size: 13px; cursor: pointer; }
.cbtn.active { background: #f0b90b; color: #0b0e11; border-color: #f0b90b; font-weight: 600; }
.tvchart { height: 560px; background: #12161c; border: 1px solid #1f2630; border-radius: 9px; overflow: hidden; }
@media (max-width: 760px) {
  .grid3, .grid4, .coingrid { grid-template-columns: 1fr 1fr; }
  .tvchart { height: 420px; }
}

.ticker .chg { font-size: 11px; margin-left: 4px; }

/* ---- language toggle + RTL ---- */
.langtoggle { margin-inline-start: 8px; align-self: center; background: #1f2630; color: #f0b90b; border: 1px solid #2a3340; border-radius: 7px; padding: 5px 13px; font-size: 12px; font-weight: 700; cursor: pointer; }
.langtoggle:hover { background: #28303c; }
.ticker { direction: ltr; }                       /* prices always read L→R */
[dir=rtl] body, [dir=rtl] .brief, [dir=rtl] .sectitle, [dir=rtl] .mline, [dir=rtl] .coincard .tgt, [dir=rtl] .sub { text-align: right; }
[dir=rtl] .side { border-right: none; border-left: 1px solid #1f2630; }
[dir=rtl] .side .nav { border-left: none; border-right: 3px solid transparent; }
[dir=rtl] .side .nav.active { border-left: none; border-right: 3px solid #f0b90b; }
[dir=rtl] .side .nav.soon { flex-direction: row-reverse; }
[dir=rtl] .panel th, [dir=rtl] .panel td { text-align: right; }
[dir=rtl] .panel td:last-child, [dir=rtl] .panel th:last-child { text-align: left; }
[dir=rtl] .minibar { margin-right: 0; margin-left: 6px; }
