:root {
  --bg: #070d1a;
  --panel: #0e1729;
  --panel-2: #121d33;
  --panel-3: #18243d;
  --border: #1f2c45;
  --border-2: #2a3a5a;
  --text: #e6ecf7;
  --muted: #8a99b5;
  --dim: #5d6c88;
  --blue: #2563eb;
  --blue-2: #3b82f6;
  --green: #22c55e;
  --green-d: #16a34a;
  --red: #ef4444;
  --red-d: #dc2626;
  --amber: #f59e0b;
  --radius: 10px;
  --font: Inter, "Segoe UI", Roboto, system-ui, -apple-system, sans-serif;
  color-scheme: dark;
}
* { box-sizing: border-box; }
html, body { margin: 0; height: 100%; background: var(--bg); color: var(--text); font: 14px/1.4 var(--font); }
button, input, select, textarea { font: inherit; color: inherit; }
a { color: var(--blue-2); }
.hidden { display: none !important; }
.muted { color: var(--muted); }
.dim { color: var(--dim); }
.mono { font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace; font-size: 12.5px; }

/* ------------ layout */
.app { display: grid; grid-template-columns: 200px 1fr; grid-template-rows: 60px 1fr; height: 100vh; }
.topbar { grid-column: 1 / -1; display: flex; align-items: center; gap: 24px; padding: 0 20px; border-bottom: 1px solid var(--border); background: #0a1222; }
.brand { display: flex; align-items: center; gap: 10px; font-weight: 700; font-size: 19px; }
.brand .logo { width: 32px; height: 32px; }
.brand .ver { font-size: 12px; color: var(--green); font-weight: 500; margin-left: 6px; }
.top-stats { margin-left: auto; display: flex; align-items: center; gap: 26px; }
.sysdot { display: flex; align-items: center; gap: 7px; color: var(--green); font-size: 13px; }
.sysdot.off { color: var(--red); }
.dot { width: 8px; height: 8px; border-radius: 50%; background: var(--green); display: inline-block; flex: none; }
.dot.red { background: var(--red); } .dot.amber { background: var(--amber); } .dot.gray { background: var(--dim); }
.dot.blink { animation: blink 1.2s infinite; }
@keyframes blink { 50% { opacity: .35; } }
.meter { width: 120px; font-size: 12px; color: var(--muted); }
.meter b { color: var(--text); font-weight: 600; }
.meter .bar { height: 4px; background: var(--panel-3); border-radius: 2px; margin-top: 5px; overflow: hidden; }
.meter .bar i { display: block; height: 100%; width: 0; background: var(--blue-2); transition: width .5s; }
.clock { text-align: right; font-size: 18px; font-weight: 600; line-height: 1.1; }
.clock small { display: block; font-size: 11px; color: var(--muted); font-weight: 400; }
.icon-btn { background: none; border: 0; padding: 6px; border-radius: 8px; cursor: pointer; color: var(--muted); display: inline-flex; align-items: center; justify-content: center; }
.icon-btn:hover { background: var(--panel-3); color: var(--text); }
.icon-btn.on { color: var(--green); }
.icon-btn svg { width: 20px; height: 20px; }
.user-menu { position: relative; }
.user-menu .menu { position: absolute; right: 0; top: 40px; background: var(--panel-2); border: 1px solid var(--border-2); border-radius: 10px; min-width: 200px; padding: 6px; z-index: 50; box-shadow: 0 10px 30px #0008; }
.user-menu .menu div.who { padding: 8px 10px; color: var(--muted); font-size: 12px; border-bottom: 1px solid var(--border); margin-bottom: 4px; }
.user-menu .menu button { display: block; width: 100%; text-align: left; background: none; border: 0; padding: 8px 10px; border-radius: 6px; cursor: pointer; }
.user-menu .menu button:hover { background: var(--panel-3); }

.sidebar { border-right: 1px solid var(--border); padding: 12px 0; display: flex; flex-direction: column; background: #0a1222; }
.nav button { display: flex; align-items: center; gap: 12px; width: 100%; padding: 11px 22px; background: none; border: 0; cursor: pointer; color: var(--text); font-size: 15px; text-align: left; border-left: 3px solid transparent; }
.nav button svg { width: 19px; height: 19px; color: var(--muted); }
.nav button:hover { background: var(--panel); }
.nav button.active { background: linear-gradient(90deg, #1d4ed855, #1d4ed822); border-left-color: var(--blue-2); }
.nav button.active svg { color: var(--text); }
.sidebar .help { margin-top: auto; padding: 14px; }
.sidebar .help button { width: 100%; }
.sidebar .shortcuts { font-size: 11.5px; color: var(--dim); padding: 0 18px 10px; line-height: 1.7; }
.sidebar .shortcuts kbd { background: var(--panel-3); border: 1px solid var(--border-2); border-radius: 4px; padding: 0 5px; font-size: 11px; color: var(--muted); }

main { overflow: auto; padding: 14px; }
.page { display: none; }
.page.active { display: block; }

/* ------------ panels */
.panel { background: var(--panel); border: 1px solid var(--border); border-radius: var(--radius); }
.panel-h { display: flex; align-items: center; gap: 10px; padding: 12px 14px; border-bottom: 1px solid var(--border); }
.panel-h h2, .panel-h h3 { margin: 0; font-size: 16px; font-weight: 600; }
.panel-h .right { margin-left: auto; display: flex; gap: 8px; align-items: center; }
.panel-b { padding: 12px 14px; }

.btn { display: inline-flex; align-items: center; justify-content: center; gap: 6px; padding: 7px 13px; border-radius: 7px; border: 1px solid var(--border-2); background: var(--panel-3); cursor: pointer; font-size: 13px; white-space: nowrap; }
.btn:hover { border-color: var(--blue-2); }
.btn.primary { background: var(--blue); border-color: var(--blue); color: #fff; }
.btn.primary:hover { background: var(--blue-2); }
.btn.danger { background: transparent; border-color: #7f1d1d; color: #fca5a5; }
.btn.danger:hover { background: #7f1d1d55; }
.btn.green { background: var(--green-d); border-color: var(--green-d); color: #fff; }
.btn.red { background: var(--red-d); border-color: var(--red-d); color: #fff; }
.btn.sm { padding: 4px 9px; font-size: 12px; }
.btn:disabled { opacity: .5; cursor: not-allowed; }
.btn svg { width: 15px; height: 15px; }

/* ------------ switcher */
.sw-grid { display: grid; grid-template-columns: minmax(0, 1fr) 360px; gap: 14px; align-items: start; }
.sw-main { display: flex; flex-direction: column; gap: 14px; min-width: 0; }
.sw-side { display: flex; flex-direction: column; gap: 14px; }
.monitors { display: grid; grid-template-columns: minmax(0, 1fr) 104px minmax(0, 1fr); gap: 14px; }
.monitor { position: relative; border-radius: var(--radius); border: 2px solid var(--green); background: #000; overflow: hidden; aspect-ratio: 16 / 9; }
.monitor.pgm { border-color: var(--red); }
.monitor video, .monitor img.still { width: 100%; height: 100%; object-fit: contain; display: block; background: #000; }
.monitor .tag { position: absolute; left: 8px; top: 8px; background: var(--green-d); color: #fff; font-weight: 700; font-size: 13px; padding: 4px 10px; border-radius: 5px; letter-spacing: .5px; z-index: 3; }
.monitor.pgm .tag { background: var(--red-d); }
.monitor .label { position: absolute; left: 0; right: 0; bottom: 0; display: flex; justify-content: space-between; align-items: center; padding: 22px 12px 8px; background: linear-gradient(transparent, #000c); font-size: 13px; z-index: 3; }
.monitor .label .res { color: #cbd5e1; font-size: 12px; }
.monitor .snd { position: absolute; right: 8px; top: 8px; z-index: 3; background: #000a; border-radius: 6px; }
.monitor .empty { position: absolute; inset: 0; display: flex; flex-direction: column; gap: 8px; align-items: center; justify-content: center; color: var(--dim); font-size: 13px; z-index: 1; }
.monitor .empty svg { width: 34px; height: 34px; }
.monitor .pl-overlay { position: absolute; left: 50%; top: 50%; transform: translate(-50%, -50%); background: #000b; padding: 8px 14px; border-radius: 8px; font-size: 13px; z-index: 2; text-align: center; }
.monitor .transbar { position: absolute; left: 0; bottom: 0; height: 3px; background: var(--amber); z-index: 4; width: 0; }
.monitor .pending { position: absolute; right: 50px; top: 8px; z-index: 3; background: var(--amber); color: #000; font-size: 11px; font-weight: 700; padding: 3px 8px; border-radius: 5px; }

.tcontrols { display: flex; flex-direction: column; gap: 10px; align-items: stretch; justify-content: center; background: var(--panel); border: 1px solid var(--border); border-radius: var(--radius); padding: 12px 10px; }
.tcontrols .tbtn { height: 44px; border-radius: 8px; border: 1px solid var(--border-2); background: var(--panel-3); font-weight: 600; letter-spacing: .5px; cursor: pointer; font-size: 14px; }
.tcontrols .tbtn:hover { border-color: var(--blue-2); }
.tcontrols .tbtn:active { transform: scale(.97); }
.tcontrols .tbtn.cut:hover { background: var(--red-d); border-color: var(--red-d); }
.tcontrols .tbtn.auto:hover { background: var(--blue); border-color: var(--blue); }
.tcontrols label { font-size: 12px; color: var(--muted); text-align: center; margin-top: 4px; }
.tcontrols select { background: var(--panel-3); border: 1px solid var(--border-2); border-radius: 6px; padding: 5px; text-align: center; }

.inputs-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(210px, 1fr)); gap: 12px; }
.icard { position: relative; border: 2px solid var(--border-2); border-radius: 9px; background: var(--panel-2); overflow: hidden; cursor: pointer; user-select: none; transition: border-color .15s; }
.icard:hover { border-color: #3b4f75; }
.icard.online { border-color: #166534; }
.icard.is-pvw { border-color: var(--green); box-shadow: 0 0 0 1px var(--green) inset; }
.icard.is-pgm { border-color: var(--red); box-shadow: 0 0 0 1px var(--red) inset; }
.icard .thumb { position: relative; aspect-ratio: 16 / 9; background: #05080f; }
.icard .thumb video, .icard .thumb img { width: 100%; height: 100%; object-fit: contain; display: block; }
.icard .thumb .nosig { position: absolute; inset: 0; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 6px; color: var(--muted); font-size: 13px; }
.icard .thumb .nosig svg { width: 28px; height: 28px; }
.icard .num { position: absolute; left: 7px; top: 6px; font-size: 12px; color: #cbd5e1; background: #0009; padding: 0 6px; border-radius: 4px; z-index: 2; }
.icard .badges { position: absolute; right: 6px; top: 6px; display: flex; gap: 4px; z-index: 2; }
.badge { font-size: 10.5px; font-weight: 700; padding: 2px 6px; border-radius: 4px; letter-spacing: .4px; }
.badge.pgm { background: var(--red-d); color: #fff; }
.badge.pvw { background: var(--green-d); color: #fff; }
.badge.gray { background: var(--panel-3); color: var(--muted); }
.icard .meta { display: grid; grid-template-columns: 26px 1fr auto; gap: 2px 8px; align-items: center; padding: 7px 9px 4px; }
.icard .meta .big { grid-row: span 2; font-size: 22px; font-weight: 300; color: #cbd5e1; text-align: center; }
.icard .meta .name { font-weight: 600; font-size: 13px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.icard .meta .res { font-size: 12px; color: var(--muted); text-align: right; }
.icard .meta .proto { font-size: 11.5px; color: var(--muted); }
.icard .meta .kbps { font-size: 11.5px; color: var(--muted); text-align: right; }
.icard .foot { display: flex; align-items: center; gap: 4px; padding: 2px 6px 7px 9px; }
.icard .foot .st { display: flex; align-items: center; gap: 6px; font-size: 12px; color: var(--green); margin-right: auto; }
.icard .foot .st.off { color: var(--red); }
.icard .foot .icon-btn { padding: 3px; }
.icard .foot .icon-btn svg { width: 16px; height: 16px; }
.icard .take { font-size: 10.5px; padding: 2px 6px; border-radius: 4px; border: 1px solid var(--border-2); background: var(--panel-3); cursor: pointer; font-weight: 700; color: var(--muted); }
.icard .take.p:hover { background: var(--green-d); color: #fff; border-color: var(--green-d); }
.icard .take.g:hover { background: var(--red-d); color: #fff; border-color: var(--red-d); }
.icard.playlist .thumb { background: linear-gradient(135deg, #1e1b4b, #0f172a); }
.icard .progress { position: absolute; left: 0; bottom: 0; height: 3px; background: var(--blue-2); z-index: 2; }

.bottom-row { display: grid; grid-template-columns: minmax(0, 1.3fr) minmax(0, 1fr); gap: 14px; }
.evlist { list-style: none; margin: 0; padding: 4px 0; max-height: 260px; overflow: auto; font-size: 12.5px; }
.evlist li { display: flex; gap: 10px; padding: 4px 14px; align-items: baseline; }
.evlist li .t { color: var(--dim); flex: none; font-variant-numeric: tabular-nums; }
.evlist li .dot { transform: translateY(-1px); }
.evlist li.success .m { color: #86efac; }
.evlist li.error .m { color: #fca5a5; }
.evlist li.warn .m { color: #fcd34d; }
.evlist.full { max-height: calc(100vh - 210px); }

/* playlist mini */
.pl-ctrl { display: flex; gap: 6px; align-items: center; flex-wrap: wrap; }
.pl-now { display: flex; align-items: center; gap: 10px; padding: 8px 14px; border-bottom: 1px solid var(--border); font-size: 13px; }
.pl-now .bar { flex: 1; height: 4px; background: var(--panel-3); border-radius: 2px; overflow: hidden; }
.pl-now .bar i { display: block; height: 100%; background: var(--blue-2); width: 0; }
.pl-list { list-style: none; margin: 0; padding: 4px 0; max-height: 230px; overflow: auto; }
.pl-list li { display: flex; align-items: center; gap: 10px; padding: 5px 14px; font-size: 13px; }
.pl-list li:hover { background: var(--panel-2); }
.pl-list li.current { background: #1d4ed822; }
.pl-list li.current .n { color: var(--blue-2); font-weight: 600; }
.pl-list li.disabled .n { color: var(--dim); text-decoration: line-through; }
.pl-list li .n { flex: 1; min-width: 0; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.pl-list li .d { color: var(--muted); font-variant-numeric: tabular-nums; font-size: 12px; }
.pl-list li img { width: 48px; height: 27px; object-fit: cover; border-radius: 3px; background: #000; flex: none; }
.pl-list li .drag { cursor: grab; color: var(--dim); }
.pl-list li.dragover { border-top: 2px solid var(--blue-2); }
.pl-opts { display: flex; flex-wrap: wrap; gap: 10px 16px; align-items: center; padding: 10px 14px; border-top: 1px solid var(--border); font-size: 13px; }
.pl-opts label { display: flex; align-items: center; gap: 6px; }

/* right column */
.out-list { list-style: none; margin: 0; padding: 0; }
.out-list li { display: flex; align-items: center; gap: 12px; padding: 11px 14px; border-bottom: 1px solid var(--border); }
.out-list li:last-child { border-bottom: 0; }
.plat { width: 38px; height: 38px; border-radius: 50%; display: flex; align-items: center; justify-content: center; flex: none; background: var(--panel-3); }
.plat svg { width: 22px; height: 22px; }
.out-list .info { flex: 1; min-width: 0; }
.out-list .info .n { font-weight: 600; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.out-list .info .s { display: flex; align-items: center; gap: 6px; font-size: 12.5px; margin-top: 2px; }
.out-list .info .src { font-size: 11px; color: var(--dim); }
.out-list .rate { font-size: 12.5px; color: var(--muted); text-align: right; font-variant-numeric: tabular-nums; }
.st-live { color: var(--green); } .st-error { color: var(--red); } .st-wait { color: var(--amber); } .st-stop { color: var(--muted); }

.switch { position: relative; width: 40px; height: 22px; flex: none; }
.switch input { opacity: 0; width: 0; height: 0; }
.switch span { position: absolute; inset: 0; background: var(--panel-3); border: 1px solid var(--border-2); border-radius: 22px; cursor: pointer; transition: .2s; }
.switch span::before { content: ""; position: absolute; width: 16px; height: 16px; left: 2px; top: 2px; background: #cbd5e1; border-radius: 50%; transition: .2s; }
.switch input:checked + span { background: var(--blue); border-color: var(--blue); }
.switch input:checked + span::before { transform: translateX(18px); background: #fff; }

.vert { display: grid; grid-template-columns: 112px 1fr; gap: 14px; }
.vert .vprev { aspect-ratio: 9 / 16; background: #000; border: 1px solid var(--border-2); border-radius: 8px; overflow: hidden; position: relative; }
.vert .vprev video { width: 100%; height: 100%; object-fit: cover; }
.vert .vprev .off { position: absolute; inset: 0; display: flex; align-items: center; justify-content: center; color: var(--dim); font-size: 12px; text-align: center; padding: 8px; }
.vert .vprev .snd { position: absolute; right: 4px; bottom: 4px; background: #000a; border-radius: 6px; }
.field { display: flex; flex-direction: column; gap: 5px; margin-bottom: 10px; }
.field > span { font-size: 12.5px; color: var(--muted); }
.field input[type=text], .field input[type=password], .field input[type=number], .field input[type=url], .field select, .field textarea, input.inp, select.inp {
  background: var(--panel-2); border: 1px solid var(--border-2); border-radius: 7px; padding: 8px 10px; width: 100%; outline: none; }
.field input:focus, .field select:focus, input.inp:focus, select.inp:focus { border-color: var(--blue-2); }
.field input[type=range] { width: 100%; accent-color: var(--blue-2); }
.field .row { display: flex; gap: 8px; align-items: center; }
.field small { color: var(--dim); font-size: 11.5px; }
select.inp { padding: 6px 8px; }

.net { display: grid; gap: 10px; font-size: 14px; }
.net .r { display: flex; align-items: center; gap: 9px; }
.net .r b { margin-left: auto; font-weight: 600; font-variant-numeric: tabular-nums; }
.spark { width: 100%; height: 46px; display: block; }

/* tables / pages */
.page-h { display: flex; align-items: center; gap: 12px; margin: 2px 0 14px; }
.page-h h1 { margin: 0; font-size: 21px; }
.page-h .right { margin-left: auto; display: flex; gap: 8px; }
table.tbl { width: 100%; border-collapse: collapse; }
table.tbl th { text-align: left; font-weight: 500; color: var(--muted); font-size: 12.5px; padding: 10px 14px; border-bottom: 1px solid var(--border); }
table.tbl td { padding: 11px 14px; border-bottom: 1px solid var(--border); vertical-align: middle; }
table.tbl tr:last-child td { border-bottom: 0; }
.copy { display: flex; align-items: center; gap: 6px; margin: 3px 0; }
.copy code { background: var(--panel-2); border: 1px solid var(--border); border-radius: 5px; padding: 3px 7px; font-size: 12px; word-break: break-all; flex: 1; }
.copy .lbl { font-size: 11.5px; color: var(--muted); width: 74px; flex: none; }
.cards2 { display: grid; grid-template-columns: repeat(auto-fit, minmax(380px, 1fr)); gap: 14px; }
.kv { display: grid; grid-template-columns: 140px 1fr; gap: 6px 12px; font-size: 13px; }
.kv span:nth-child(odd) { color: var(--muted); }

.upload-zone { display: block; border: 2px dashed var(--border-2); border-radius: 10px; padding: 22px; text-align: center; color: var(--muted); cursor: pointer; }
.upload-zone.drag { border-color: var(--blue-2); background: #1d4ed811; }
.upload-zone input { display: none; }
.uprog { margin-top: 10px; display: grid; gap: 6px; }
.uprog .u { font-size: 12.5px; }
.uprog .u .bar { height: 5px; background: var(--panel-3); border-radius: 3px; overflow: hidden; margin-top: 3px; }
.uprog .u .bar i { display: block; height: 100%; background: var(--blue-2); width: 0; }

/* modal + toast */
.modal-bg { position: fixed; inset: 0; background: #000a; display: flex; align-items: center; justify-content: center; z-index: 100; padding: 16px; }
.modal { background: var(--panel); border: 1px solid var(--border-2); border-radius: 12px; width: 520px; max-width: 100%; max-height: calc(100vh - 32px); overflow: auto; box-shadow: 0 20px 60px #000a; }
.modal .panel-h { position: sticky; top: 0; background: var(--panel); z-index: 1; }
.modal .foot { display: flex; justify-content: flex-end; gap: 8px; padding: 12px 14px; border-top: 1px solid var(--border); }
.toasts { position: fixed; right: 16px; bottom: 16px; display: flex; flex-direction: column; gap: 8px; z-index: 200; }
.toast { background: var(--panel-2); border: 1px solid var(--border-2); border-left: 4px solid var(--blue-2); padding: 10px 14px; border-radius: 8px; min-width: 240px; max-width: 380px; box-shadow: 0 8px 24px #0008; font-size: 13px; animation: tin .2s; }
.toast.error { border-left-color: var(--red); } .toast.success { border-left-color: var(--green); }
@keyframes tin { from { transform: translateY(10px); opacity: 0; } }

.tabs { display: flex; gap: 4px; }
.tabs button { background: none; border: 1px solid transparent; padding: 5px 10px; border-radius: 6px; cursor: pointer; color: var(--muted); font-size: 12.5px; }
.tabs button.on { background: var(--panel-3); border-color: var(--border-2); color: var(--text); }

.conn-lost { position: fixed; top: 0; left: 0; right: 0; background: var(--red-d); color: #fff; text-align: center; padding: 6px; font-size: 13px; z-index: 300; }

@media (max-width: 1400px) {
  .sw-grid { grid-template-columns: minmax(0, 1fr) 320px; }
}
@media (max-width: 1150px) {
  .sw-grid { grid-template-columns: 1fr; }
  .bottom-row { grid-template-columns: 1fr; }
}
@media (max-width: 820px) {
  .app { grid-template-columns: 1fr; grid-template-rows: 56px auto 1fr; }
  .sidebar { flex-direction: row; overflow-x: auto; padding: 0; border-right: 0; border-bottom: 1px solid var(--border); }
  .nav { display: flex; }
  .nav button { padding: 10px 14px; border-left: 0; border-bottom: 3px solid transparent; }
  .nav button.active { border-bottom-color: var(--blue-2); }
  .sidebar .help, .sidebar .shortcuts { display: none; }
  .top-stats .meter, .top-stats .sysdot { display: none; }
  .monitors { grid-template-columns: 1fr 1fr; }
  .tcontrols { grid-column: 1 / -1; flex-direction: row; order: 3; }
  .tcontrols .tbtn { flex: 1; }
  main { padding: 10px; }
}
.net .r svg { width: 16px; height: 16px; color: var(--muted); flex: none; }
.net .r b { white-space: nowrap; }
@media (max-width: 820px) {
  .inputs-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 8px; }
  .brand { font-size: 16px; white-space: nowrap; }
  .brand .ver { display: none; }
  .icard .foot .take { display: none; }
}

/* switcher por usuário */
.ws-ctl { display: flex; align-items: center; gap: 8px; margin-left: 18px; }
.ws-ctl select { width: auto; min-width: 140px; }
.btn.power { gap: 7px; }
.btn.power.on { background: #14532d; border-color: var(--green-d); color: #bbf7d0; }
.btn.power.off { background: var(--panel-3); }
.btn.power svg { width: 16px; height: 16px; }
.off-overlay { position: absolute; inset: 0; z-index: 5; background: #000c; display: flex; flex-direction: column; gap: 12px; align-items: center; justify-content: center; font-size: 15px; color: var(--muted); }
.ws-banner { background: #1e3a8a; color: #dbeafe; text-align: center; font-size: 13px; padding: 6px; border-radius: 8px; margin-bottom: 12px; }
.ws-banner button { margin-left: 8px; }
.gbtn { display: inline-flex; align-items: center; gap: 8px; background: #fff; color: #1f2937; border: 1px solid #dadce0; border-radius: 7px; padding: 8px 14px; font-weight: 500; cursor: pointer; text-decoration: none; font-size: 14px; }
.gbtn:hover { background: #f1f5f9; }
.gbtn svg { width: 18px; height: 18px; }
.drive-folders { list-style: none; margin: 8px 0; padding: 0; max-height: 260px; overflow: auto; border: 1px solid var(--border); border-radius: 8px; }
.drive-folders li { padding: 7px 10px; cursor: pointer; display: flex; gap: 8px; align-items: center; border-bottom: 1px solid var(--border); font-size: 13px; }
.drive-folders li:hover { background: var(--panel-2); }
.drive-folders li:last-child { border-bottom: 0; }
.crumbs { font-size: 12.5px; color: var(--muted); display: flex; flex-wrap: wrap; gap: 4px; align-items: center; }
.crumbs a { cursor: pointer; color: var(--blue-2); }
.dbadge { font-size: 10px; font-weight: 700; background: #1e3a8a; color: #bfdbfe; padding: 1px 5px; border-radius: 4px; flex: none; }
@media (max-width: 820px) { .ws-ctl { margin-left: auto; } .ws-ctl .power span { display: none; } }

.tcontrols .tbtn.ftb { font-size: 12px; height: 36px; background: #000; }
.tcontrols .tbtn.ftb:hover { border-color: #fff; }
.direct-toggle { display: flex; align-items: center; gap: 7px; font-size: 12.5px; color: var(--muted); cursor: pointer; margin-right: 6px; }
.direct-toggle.on { color: #fca5a5; }
.icard .take.g.hidden { display: none; }
.monitor.pgm .label .name.black { color: var(--muted); }

.btn.power.warn { background: #78350f; border-color: var(--amber); color: #fde68a; animation: blink 1.2s infinite; }
