/* KVIZ 90-IH – regija (temna) in urejevalnik (svetel). */
:root { --ui: system-ui, -apple-system, "Segoe UI", Roboto, sans-serif; --line: #2b3170; --panel: #12164a; --panel-2: #1a1f5e; }

/* ---------- gumbi ---------- */
.btn { font: 600 15px/1.2 var(--ui); padding: 9px 14px; border: 1px solid #5a62b8; background: #232a7a; color: #fff; cursor: pointer; border-radius: 3px; text-decoration: none; display: inline-flex; align-items: center; gap: 6px; }
.btn:hover { background: #2f379a; }
.btn:focus-visible, .lnk:focus-visible, input:focus-visible, select:focus-visible, textarea:focus-visible { outline: 3px solid var(--tt-yellow, #ffe600); outline-offset: 1px; }
.btn.primary { background: var(--tt-yellow, #ffe600); color: #0a0d58; border-color: var(--tt-yellow, #ffe600); }
.btn.primary:hover { filter: brightness(1.08); }
.btn.big { font-size: 20px; padding: 14px 22px; }
.btn.ghost { background: transparent; }
.btn.ok { background: #15803d; border-color: #22c55e; }
.btn.bad { background: #9f1d1d; border-color: #ef4444; }
.btn.on { background: #00e1ff; color: #0a0d58; border-color: #00e1ff; }
.btn.warnbtn { background: #b45309; border-color: #f59e0b; }
.btn.mini { padding: 3px 9px; font-size: 13px; }
.lnk { background: none; border: 0; color: #8fd8ff; text-decoration: underline; cursor: pointer; font: inherit; padding: 0 2px; }
body.is-busy .rg-panel .btn { opacity: .55; pointer-events: none; }

/* ---------- regija ---------- */
body.regija-body { background: #05072e; color: #e8eaff; font: 15px/1.4 var(--ui); overflow: hidden; }
.rg { display: grid; grid-template-columns: minmax(0, 1fr) 560px; height: 100vh; }
.rg-stage { position: relative; background: #000; min-width: 0; }
.rg-stage .stage-wrap { position: absolute; inset: 0; }
.rg-panel { overflow-y: auto; padding: 10px 12px 60px; background: var(--panel); border-left: 2px solid var(--line); }
.rg-top { display: flex; justify-content: space-between; gap: 10px; align-items: center; }
.rg-title { font-size: 15px; } .rg-title span { color: #00e1ff; margin-left: 6px; }
.rg-conn { display: flex; gap: 6px; flex-wrap: wrap; }
.cn { font-size: 12px; font-weight: 700; padding: 3px 8px; border-radius: 10px; background: #3b3f6b; }
.cn::before { content: "● "; }
.cn.ok { background: #14532d; color: #86efac; } .cn.slow { background: #713f12; color: #fde68a; } .cn.off { background: #450a0a; color: #fca5a5; }
.rg-tools { display: flex; flex-wrap: wrap; gap: 6px; margin: 10px 0; }
.rg-warn div { background: #4a2a00; border-left: 4px solid #f59e0b; padding: 6px 10px; margin-bottom: 6px; font-size: 14px; }
.card { background: var(--panel-2); border: 1px solid var(--line); padding: 10px 12px; margin-bottom: 10px; border-radius: 3px; }
.card h3 { margin: 0 0 8px; font-size: 16px; color: #ffe600; }
.card h3 .small { color: #c7cbf5; font-weight: 400; }
.card-flow { border-left: 6px solid #ffe600; }
.row { display: flex; flex-wrap: wrap; gap: 6px; align-items: center; margin: 8px 0; }
.row.sec { margin-top: 10px; padding-top: 8px; border-top: 1px dashed var(--line); }
.lbl { font-size: 13px; color: #a5abe8; margin: 0; }
.say { font-size: 17px; line-height: 1.45; margin: 4px 0 6px; white-space: pre-wrap; font-family: var(--ui); color: #fff; }
.qtxt { font-size: 18px; font-weight: 600; margin: 4px 0 8px; }
.ans-host { background: #ffe600; color: #0a0d58; padding: 8px 12px; font-size: 20px; }
.ans-host span { font-size: 12px; font-weight: 700; margin-right: 8px; text-transform: uppercase; }
.ans-host i { font-size: 15px; }
.secret { background: #4c1d95; padding: 6px 10px; }
.small { font-size: 13px; color: #c7cbf5; margin: 6px 0; } .small pre { white-space: pre-wrap; font: 13px/1.4 var(--ui); }
.err { color: #fca5a5; }
.code { font-family: Consolas, monospace; font-size: 13px; color: #00e1ff; }
.badge { font-size: 11px; padding: 2px 7px; border-radius: 8px; background: #3b3f6b; color: #fff; vertical-align: middle; }
.b-ok { background: #15803d; } .b-mid { background: #1d4ed8; } .b-warn { background: #b45309; } .b-err { background: #b91c1c; }
.next { font-size: 13px; color: #a5abe8; border-top: 1px dashed var(--line); padding-top: 6px; margin: 8px 0 0; }
.open { color: #86efac; } .locked { color: #ffe600; }
.judges { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }
#question .qtxt { font-size: 16px; }
#question .row { margin: 6px 0; }
.judge { display: flex; flex-direction: column; gap: 6px; padding: 8px; background: rgba(0,0,0,.25); border-top: 5px solid; }
.judge.team-a { border-color: #ff2f95; } .judge.team-b { border-color: #2ee36c; }
.judge .jn { font-weight: 700; }
.judge .btn { justify-content: center; }
.wagers-h { margin-top: 8px; border-top: 1px dashed var(--line); padding-top: 6px; }
.wg { display: flex; flex-wrap: wrap; gap: 6px; align-items: center; margin: 4px 0; }
.tbig { font-size: 22px; color: #fff; margin-left: 8px; font-variant-numeric: tabular-nums; }
.sc-tot { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }
.sc-tot > div { background: rgba(0,0,0,.3); padding: 6px 10px; border-top: 5px solid; display: flex; flex-direction: column; }
.sc-tot .team-a { border-color: #ff2f95; } .sc-tot .team-b { border-color: #2ee36c; }
.sc-tot b { font-size: 34px; line-height: 1; } .sc-tot small { color: #a5abe8; }
.manual { display: grid; grid-template-columns: 1fr 70px 90px; gap: 6px; margin: 10px 0 6px; }
.manual input[name=reason] { grid-column: 1 / 3; }
.manual input, .manual select { font: 15px var(--ui); padding: 7px; background: #0b0f3e; color: #fff; border: 1px solid #4b52a8; border-radius: 3px; min-width: 0; }
.sc-hist { list-style: none; padding: 0; margin: 6px 0 0; max-height: 220px; overflow: auto; font-size: 13px; }
.sc-hist li { padding: 3px 0; border-bottom: 1px solid #262c6e; }
.sc-hist li.undone { opacity: .5; text-decoration: line-through; }
.tm { font-weight: 700; } .tm.team-a { color: #ff7ab8; } .tm.team-b { color: #6ff09a; }
.plan { margin: 0; padding-left: 22px; font-size: 14px; }
.plan li.done { color: #7c82c4; } .plan li.current { color: #ffe600; font-weight: 700; }
.plan small { color: #8a90d0; }
.hints-row .btn { font-size: 13px; padding: 6px 10px; }
.dlg { border: 2px solid #ffe600; background: #12164a; color: #fff; max-width: 680px; width: 92vw; font: 15px/1.45 var(--ui); }
.dlg::backdrop { background: rgba(0,0,0,.7); }
.dlg p { font-size: 17px; }
.dlg-btns { display: flex; gap: 8px; justify-content: flex-end; margin-top: 12px; }
.chk { display: block; margin: 8px 0; }
.lnkrow { display: grid; grid-template-columns: 160px 1fr auto; gap: 6px; align-items: center; margin: 6px 0; }
.lnkrow input { font: 13px Consolas, monospace; padding: 6px; background: #0b0f3e; color: #fff; border: 1px solid #4b52a8; }
.toast { position: fixed; right: 16px; bottom: 16px; background: #14532d; color: #fff; padding: 12px 18px; font: 600 15px var(--ui); border-radius: 3px; opacity: 0; transform: translateY(20px); transition: .2s; pointer-events: none; z-index: 50; max-width: 520px; }
.toast.show { opacity: 1; transform: none; } .toast.err { background: #991b1b; }
.offline { position: fixed; left: 0; right: 0; top: 0; background: #b91c1c; color: #fff; text-align: center; padding: 6px; font: 700 15px var(--ui); display: none; z-index: 60; }
.offline.show { display: block; }
.tv-exit { position: absolute; right: 8px; top: 8px; z-index: 5; opacity: 0; font: 600 13px var(--ui); background: rgba(0,0,0,.6); color: #fff; border: 1px solid #555; padding: 6px 10px; cursor: pointer; display: none; }
body.tv-mode .tv-exit { display: block; }
.tv-exit:hover, .tv-exit:focus { opacity: 1; }
body.tv-mode .rg { grid-template-columns: 1fr; }
body.tv-mode .rg-panel { display: none; }
body.tv-mode .toast { display: none; }
@media (max-width: 1100px) { .rg { grid-template-columns: 1fr; grid-template-rows: 42vh 1fr; } body.regija-body { overflow: auto; } .rg { height: auto; min-height: 100vh; } .rg-panel { border-left: 0; } }

/* ---------- urejevalnik ---------- */
body.admin-body { margin: 0; background: #f3f4fb; color: #151834; font: 15px/1.5 var(--ui); }
.adm-nav { background: #0a0d58; color: #fff; display: flex; align-items: center; gap: 4px; padding: 0 16px; flex-wrap: wrap; }
.adm-nav .brand { font: 800 22px "Bahnschrift", "Barlow Condensed", "Arial Narrow", sans-serif; color: #ffe600; margin-right: 16px; padding: 10px 0; }
.adm-nav a { color: #e1e4ff; text-decoration: none; padding: 14px 10px; font-weight: 600; font-size: 14px; }
.adm-nav a.on, .adm-nav a:hover { color: #ffe600; box-shadow: inset 0 -4px 0 #ffe600; }
.adm-nav .sp { flex: 1; }
.adm { max-width: 1280px; margin: 0 auto; padding: 20px 20px 80px; }
.adm h1 { font-size: 26px; margin: 4px 0 16px; }
.adm h2 { font-size: 19px; margin: 24px 0 10px; }
.adm .btn { background: #232a7a; }
.adm .btn.primary { background: #0a0d58; color: #ffe600; border-color: #0a0d58; }
.adm .btn.ghost { background: #fff; color: #232a7a; }
.adm .btn.bad { background: #b91c1c; }
.adm .lnk { color: #1d4ed8; }
.flash { padding: 10px 14px; margin-bottom: 10px; border-left: 5px solid; background: #fff; }
.flash.ok { border-color: #16a34a; } .flash.warn { border-color: #d97706; } .flash.err { border-color: #dc2626; }
.panel { background: #fff; border: 1px solid #d8dbee; padding: 16px; margin-bottom: 16px; border-radius: 3px; }
table.tbl { width: 100%; border-collapse: collapse; background: #fff; font-size: 14px; }
.tbl th, .tbl td { padding: 7px 8px; border-bottom: 1px solid #e3e5f3; text-align: left; vertical-align: top; }
.tbl th { background: #e8eaf8; font-size: 13px; position: sticky; top: 0; }
.tbl tr.arch td { color: #888; }
.tbl td.num { text-align: right; font-variant-numeric: tabular-nums; }
.pill { display: inline-block; font-size: 12px; padding: 1px 8px; border-radius: 10px; background: #e5e7f5; white-space: nowrap; }
.pill.st-aktivno, .pill.st-preverjeno { background: #dcfce7; } .pill.st-osnutek { background: #fef3c7; } .pill.st-arhivirano { background: #e5e5e5; }
.pill.v-sporno { background: #fee2e2; } .pill.v-nepreverjeno { background: #ffedd5; } .pill.v-preverjeno { background: #dcfce7; } .pill.v-pregledano { background: #dbeafe; }
.form-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(280px, 1fr)); gap: 12px 18px; }
.field { display: flex; flex-direction: column; gap: 4px; }
.field.wide { grid-column: 1 / -1; }
.field label { font-weight: 600; font-size: 14px; }
.field .hint { font-size: 12px; color: #5b6086; }
.adm input[type=text], .adm input[type=number], .adm input[type=password], .adm input[type=url], .adm select, .adm textarea { font: 15px var(--ui); padding: 8px 10px; border: 1px solid #b8bcdb; border-radius: 3px; background: #fff; width: 100%; }
.adm textarea { min-height: 80px; resize: vertical; }
.filters { display: flex; flex-wrap: wrap; gap: 8px; align-items: end; margin-bottom: 12px; }
.filters .field { min-width: 150px; }
.actions { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 16px; }
.warnbox { background: #fff7ed; border-left: 5px solid #f59e0b; padding: 10px 14px; margin: 10px 0; }
.errbox { background: #fef2f2; border-left: 5px solid #dc2626; padding: 10px 14px; margin: 10px 0; }
.okbox { background: #f0fdf4; border-left: 5px solid #16a34a; padding: 10px 14px; margin: 10px 0; }
.stats { display: grid; grid-template-columns: repeat(auto-fill, minmax(170px, 1fr)); gap: 10px; }
.stat { background: #fff; border: 1px solid #d8dbee; padding: 12px; }
.stat b { display: block; font-size: 28px; }
.mono { font-family: Consolas, monospace; font-size: 13px; }
.diff { font-size: 13px; }
.diff del { background: #fee2e2; } .diff ins { background: #dcfce7; text-decoration: none; }
.opt-row { display: grid; grid-template-columns: 40px 1fr; gap: 6px; align-items: center; margin-bottom: 4px; }
.login { max-width: 380px; margin: 10vh auto; background: #fff; padding: 24px; border-top: 8px solid #0a0d58; }
.login h1 { font: 800 34px "Bahnschrift", "Barlow Condensed", sans-serif; margin: 0 0 12px; }
.sortable li { cursor: grab; }
.handle { cursor: grab; color: #888; padding-right: 6px; }

.bgctl { display: flex; align-items: center; gap: 10px; margin: 0 0 10px; padding: 6px 10px; background: var(--panel-2); border: 1px solid var(--line); font-size: 14px; }
.bgctl input[type=range] { flex: 1; accent-color: #ffe600; }
.bgctl output { width: 44px; text-align: right; font-variant-numeric: tabular-nums; }
.tset { display: flex; gap: 6px; align-items: center; }
.tset input { width: 74px; font: 15px var(--ui); padding: 7px; background: #0b0f3e; color: #fff; border: 1px solid #4b52a8; border-radius: 3px; }
.ansbox { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; margin: 8px 0; }
.ansbox > div { background: rgba(0,0,0,.25); padding: 8px; border-top: 5px solid; }
.ansbox .team-a { border-color: #ff2f95; } .ansbox .team-b { border-color: #2ee36c; }
.ansbox b { display: block; font-size: 22px; }
