/* Tamni režim – generisano iz style.css (svetle pozadine/okviri/tamni tekstovi se preslikavaju), plus ručne dopune ispod. */
html[data-theme="dark"]{--bg:#0a0f22;--card:#141c3b;--ink:#e8ecfa;--muted:#9aa6c9;--line:#26305c;--shadow:0 1px 2px rgba(0,0,0,.3),0 6px 20px rgba(0,0,0,.35);--shadow-lg:0 2px 4px rgba(0,0,0,.35),0 14px 34px rgba(0,0,0,.5);color-scheme:dark}
html[data-theme="dark"] body{background:radial-gradient(900px 380px at 50% -120px,#18224a,transparent) no-repeat,var(--bg)}
html[data-theme="dark"] header img{background:#151c2e}
html[data-theme="dark"] .game-section{background:#1c253f}
html[data-theme="dark"] label{color:#aeb7d8}
html[data-theme="dark"] input[type=text],html[data-theme="dark"] input[type=password],html[data-theme="dark"] input[type=datetime-local],html[data-theme="dark"] input[type=email]{background:#182035}
html[data-theme="dark"] input:focus{background:#151c2e}
html[data-theme="dark"] .banner{background:linear-gradient(135deg,#462c14,#543418);border:1px solid #633e21;color:#edb899}
html[data-theme="dark"] .banner.closed{background:#24293c}
html[data-theme="dark"] .msg.ok{background:#234130;border:1px solid #31543f;color:#a7ebc5}
html[data-theme="dark"] .msg.bad{background:#461414;border:1px solid #602525;color:#e48888}
html[data-theme="dark"] .pbtn{background:#192137}
html[data-theme="dark"] .pbtn:hover{background:#151c2e}
html[data-theme="dark"] .pbtn.danger:hover{background:#182036}
html[data-theme="dark"] .avatar{border:2px dashed #2e3a56;background:#1a2239 center/cover no-repeat}
html[data-theme="dark"] .avatar.has{border:3px solid #2e3a56}
html[data-theme="dark"] .mail-state .ok{color:#a7ebc5}
html[data-theme="dark"] .rename{background:#182035;border:1px dashed #363c4f}
html[data-theme="dark"] .sortable-ghost{background:#462a14}
html[data-theme="dark"] .team img{background:#1a2239}
html[data-theme="dark"] .arrows button{background:#182035}
html[data-theme="dark"] .arrows button:hover{background:#151c2e;border-color:#633b21}
html[data-theme="dark"] button.btn,html[data-theme="dark"] a.btn{border:1.5px solid #363c4f;background:#151c2e}
html[data-theme="dark"] button.btn:hover,html[data-theme="dark"] a.btn:hover{background:#1a2239}
html[data-theme="dark"] button.btn.danger{border-color:#5d2828}
html[data-theme="dark"] .pl-head.click:hover{background:#171e33}
html[data-theme="dark"] .rank{background:#202639}
html[data-theme="dark"] .pl.r2 .rank{background:linear-gradient(135deg,#343b4c,#a5adc0)}
html[data-theme="dark"] .av{background:#232b46 center/cover no-repeat}
html[data-theme="dark"] .pl-share:hover{background:#492c15}
html[data-theme="dark"] .pl.r1 .stat b{color:#e8c67d}
html[data-theme="dark"] .pl-detail{background:#161e32}
html[data-theme="dark"] table.cmp td{border-top:1px solid #363c4f}
html[data-theme="dark"] .winner{background:linear-gradient(135deg,#4c4016,#6f5920)}
html[data-theme="dark"] .winner small{color:#eed99d}
html[data-theme="dark"] .embed{background:#151c2e}
html[data-theme="dark"] tr.pdet td{background:#161e32}
html[data-theme="dark"] .warn{background:#4c4016;color:#eed99d}
html[data-theme="dark"] .site-foot img{background:#151c2e}
html[data-theme="dark"] .dlg-h{border-top:1px solid var(--line,#343b51)}
html[data-theme="dark"] .livegame{background:#1c233a}
html[data-theme="dark"] .livegame.on{background:#471715}
html[data-theme="dark"] table.standtbl tr.playing{background:#471715}
html[data-theme="dark"] table.standtbl td{border-top:1px solid #363c4f}
html[data-theme="dark"] table.standtbl tr.cut td{border-bottom:2px dashed #363c4f}
html[data-theme="dark"] .plus{color:#92ecbc}
html[data-theme="dark"] .roundpick select{background:#151c2e}
html[data-theme="dark"] .live{background:#461414}
html[data-theme="dark"] .mv{background:#202639}
html[data-theme="dark"] .mv.up{background:#234130;color:#92ecbc}
html[data-theme="dark"] .mv.down{background:#461414}
html[data-theme="dark"] .gauge{background:#24293c}
html[data-theme="dark"] .pbar{background:#2a3147}
html[data-theme="dark"] .chip{background:#252a3a}
html[data-theme="dark"] .chip.gold{background:#60501c;color:#ecd394}
html[data-theme="dark"] .chip.bold{background:#563319;color:#eab087}
html[data-theme="dark"] .rn-btn{background:#192137}
html[data-theme="dark"] .tgame.picked{border-color:#633e21}
html[data-theme="dark"] .tside{background:#171e33}
html[data-theme="dark"] .tside:hover:not(:disabled){border-color:#633c21;background:#192238}
html[data-theme="dark"] .tside.sel{background:#472b15}
html[data-theme="dark"] .tside.won{background:#21412f}
html[data-theme="dark"] .tside.lost{background:#451414}
html[data-theme="dark"] .tdist .bar{background:#2a3042}
html[data-theme="dark"] .tres.ok{color:#a7ebc5}
html[data-theme="dark"] .tres.bad{color:#e48888}
html[data-theme="dark"] .segtabs button{background:#192137}
html[data-theme="dark"] .ttable td{border-bottom:1px solid #343b51}
html[data-theme="dark"] .reset-link input{border:1.5px solid #343b51;background:#182035}
html[data-theme="dark"] .stile{background:#182035}
html[data-theme="dark"] .scard{background:#151c2e}
html[data-theme="dark"] .srow{border-bottom:1px solid #313954}
html[data-theme="dark"] .ttable .you-row{background:#432a14}
html[data-theme="dark"] .trank.s{background:#2f406a}
html[data-theme="dark"] .mini-av{background:#2a3042 center/cover no-repeat}
html[data-theme="dark"] .bonus-badge{color:#eac088;background:#544018;border:1px solid #614c24}
html[data-theme="dark"] .bbadge.g{color:#efd4a6}
html[data-theme="dark"] .bbadge.s{background:linear-gradient(145deg,#232a36,#2f406a);color:#aab0c0;border-color:#2e3a56}
html[data-theme="dark"] .bbadge.b{color:#eac2a8}
html[data-theme="dark"] .bbadge.more{background:#252a3a;border-color:#363d4e}
html[data-theme="dark"] .formpill.good{background:#19452b;border-color:#2f563e;color:#88e4af}
html[data-theme="dark"] .formpill.bad{background:#461414;border-color:#5c2828}
html[data-theme="dark"] .achbadge{background:#492c15;border:1px solid #634021;color:#eac088}
html[data-theme="dark"] .achbadge.expert{background:#211445;border-color:#332163}
html[data-theme="dark"] .achbadge.bad{background:#471a15;border-color:#602c25;color:#e08178}
html[data-theme="dark"] .psum-ic{background:#1d2740}
html[data-theme="dark"] .psum-ic.on{background:#492c15}
html[data-theme="dark"] .hl-row{border-bottom:1px solid #343b51}
html[data-theme="dark"] .hl-ic{background:#1d2740}
html[data-theme="dark"] .hl-badge{background:#432a14}
html[data-theme="dark"] .hl-badge .hl-ic{background:#5e3e1b}
html[data-theme="dark"] .tstatus.open{background:#22442f;color:#9deec3;border:1px solid #31533e}
html[data-theme="dark"] .tstatus.part{background:#4d3a16;color:#ecc494;border:1px solid #604c24}
html[data-theme="dark"] .tstatus.shut{background:#252a3a;color:#9ba4c1;border:1px solid #343b51}
html[data-theme="dark"] .tres.mine{color:#9deec3}
html[data-theme="dark"] .jokerinfo{background:#241443;color:#a38bd8;border:1px solid #39265f}
html[data-theme="dark"] .jokerbtn{border:1.5px solid #39265f;background:#241443}
html[data-theme="dark"] .jokerbtn:hover:not(:disabled){background:#2c174e;border-color:#37265e}
html[data-theme="dark"] .joker-item{background:#241443;border:1px solid #39265f}
@media (max-width:520px){html[data-theme="dark"] .tabs{background:#151c2e}}
html[data-theme="dark"] .badgebar{background:#151c2e}
html[data-theme="dark"] .prog-cmp select{background:#182035}
html[data-theme="dark"] .profile-photo{background:#252a3a}
html[data-theme="dark"] .profile-stats .ps{background:#182035}
html[data-theme="dark"] .rec{background:#182035}
html[data-theme="dark"] .bsheet-in{background:#151c2e}
html[data-theme="dark"] .bsheet-row:hover{background:#1a233a}
html[data-theme="dark"] .bsheet-row.cur{background:#492c15;color:#eab087}
html[data-theme="dark"] .mp-list a{background:#182035}
html[data-theme="dark"] .mp-rounds a{background:#151c2e}
html[data-theme="dark"] .duelcard{background:#182035}
html[data-theme="dark"] .dtag{background:#252a3a}
html[data-theme="dark"] .dtag.open{background:#60501c;color:#ecd394}
html[data-theme="dark"] .dtag.active{background:#16334d;color:#7eb3e8}
html[data-theme="dark"] .dtag.done{background:#19452b;color:#88e4af}
html[data-theme="dark"] .dtag.expired,html[data-theme="dark"] .dtag.cancelled{background:#461414}
html[data-theme="dark"] .dside.win{background:#4c4016}
html[data-theme="dark"] .duel-pick select{background:#151c2e}

/* ---- ručne dopune ---- */
html[data-theme="dark"] body{color:var(--ink)}
html[data-theme="dark"] select,html[data-theme="dark"] input,html[data-theme="dark"] textarea{color:var(--ink);border-color:var(--line)}
html[data-theme="dark"] input::placeholder{color:#6f7aa0}
html[data-theme="dark"] .card,html[data-theme="dark"] .bsheet-in,html[data-theme="dark"] .scard{background:var(--card)}
html[data-theme="dark"] .bnav{background:#0f1633;border-top-color:var(--line)}
html[data-theme="dark"] .bn-item{color:#9aa6c9}
html[data-theme="dark"] .bn-item.on,html[data-theme="dark"] .bn-item.sheet-open{color:#ff8a3d}
html[data-theme="dark"] .bsheet-row{color:var(--ink)}
html[data-theme="dark"] .mp-list a,html[data-theme="dark"] .mp-rounds a{color:var(--ink);border-color:var(--line)}
html[data-theme="dark"] a{color:#8fb0ff}
html[data-theme="dark"] a.btn,html[data-theme="dark"] .nd-row,html[data-theme="dark"] .bsheet-row,html[data-theme="dark"] .mp-play,html[data-theme="dark"] .mp-lang,html[data-theme="dark"] .mp-list a,html[data-theme="dark"] .mp-rounds a{color:inherit}
html[data-theme="dark"] img.logo,html[data-theme="dark"] .team img{background:#e9edf8;border-radius:6px}
html[data-theme="dark"] .nd-panel{background:#0c1330}
html[data-theme="dark"] .nav-burger{color:#fff}
html[data-theme="dark"] a.rp-btn{background:#182035;color:#cdd6f6;border-color:var(--line)}
html[data-theme="dark"] a.rp-btn:hover{color:#ff8a3d;border-color:#ff8a3d}
html[data-theme="dark"] .pf-share{background:#182035;color:#cdd6f6;border-color:var(--line)}
html[data-theme="dark"] .pf-share:hover{color:#ff8a3d;border-color:#ff8a3d}
html[data-theme="dark"] .formpill.now{background:#492c15;border-color:#634021;color:#eac088}
html[data-theme="dark"] .pf-game{border-color:#5a3a1f;background:rgba(255,138,61,.05)}
html[data-theme="dark"] .pf-game.board{border-color:#2f406a;background:rgba(143,176,255,.05)}
html[data-theme="dark"] .pf-game.board .pf-game-h{color:#8fb0ff}

html[data-theme="dark"] .pwa-ban{background:#16213f;color:#eaf0ff;border-color:rgba(255,255,255,.14)}

html[data-theme="dark"] .help-sec{background:rgba(255,255,255,.04);border-color:rgba(255,255,255,.14)}
html[data-theme="dark"] .help-sec[open]>summary{border-color:rgba(255,255,255,.14)}

html[data-theme="dark"] a.rp-inline{background:rgba(255,255,255,.08);border-color:rgba(255,255,255,.18);color:#dfe6ff}

/* Čitljivost u tamnom režimu: tekstovi koji su u svetloj temi tamnoplavi (var(--navy)/--navy2) */
html[data-theme="dark"] .avg,
html[data-theme="dark"] .stat b,
html[data-theme="dark"] .tmatch,
html[data-theme="dark"] a.rp-btn,
html[data-theme="dark"] .pf-share{color:#dfe6ff}
html[data-theme="dark"] button.btn,html[data-theme="dark"] a.btn{color:#e8ecfa}
html[data-theme="dark"] button.btn:disabled{opacity:.6;color:#aeb8d9;background:#1b2440;border-color:#3a4570}
html[data-theme="dark"] button.btn.primary,html[data-theme="dark"] a.btn.primary{color:#fff}
html[data-theme="dark"] button.btn.primary:disabled{background:#3a3f57;color:#c9cfe6;opacity:.75}
/* Džoker */
html[data-theme="dark"] .jokerbtn{color:#d6c4ff;border-color:#5a3fa0;background:#2a1850}
html[data-theme="dark"] .jokerbtn:hover:not(:disabled){background:#35206a;border-color:#7a5bd0}
html[data-theme="dark"] .jokerbtn.on{color:#fff;border-color:transparent}
html[data-theme="dark"] .joker-badge{color:#b79cff}
html[data-theme="dark"] .jokerinfo{background:#2a1850;color:#dccdff;border-color:#4d3a85}

html[data-theme="dark"] .tipi{background:#5b6cc0}
html[data-theme="dark"] .tipi:hover,html[data-theme="dark"] .tipi.tip-open{background:var(--orange)}
html[data-theme="dark"] .tip-pop{background:#eef1fb;color:#0b1430;border-color:rgba(0,0,0,.15)}

html[data-theme="dark"] .agr-bar{background:#26305c}

html[data-theme="dark"] .periodbar select{background:#141c3a;color:#e8ecf8;border-color:#2b3566}
html[data-theme="dark"] .achbadge.gold{background:#3a2d0c;color:#ffd77a;border-color:#7a5c14}
html[data-theme="dark"] .phase-card .ph-meta{color:#9aa4c7}
