/* Painel Signage — design system "central de controle".
   Barra lateral cobalto, conteúdo em painéis brancos, tabelas com faixa de estado, abas sublinhadas e edição travada por padrão.
   Claro: azul-gelo + tinta marinho. Escuro: tinta profunda. Cor de sinal: cobalto, com ponto laranja "ao vivo". */
@font-face { font-family: "Bricolage Grotesque"; src: url("fonts/bricolage-grotesque-latin-wght-normal.woff2") format("woff2"); font-weight: 200 800; font-display: swap; }
@font-face { font-family: "Instrument Sans"; src: url("fonts/instrument-sans-latin-wght-normal.woff2") format("woff2"); font-weight: 400 700; font-display: swap; }

:root {
  --bg: #eef2f9; --bg2: #f6f8fc; --panel: #ffffff; --panel2: #f5f7fb; --panel3: #e7ecf5; --line: #e0e6f0; --line2: #cdd6e6;
  --txt: #14213d; --mut: #53627f; --mut2: #7685a3;
  --acc: #2547f5; --acc-btn: #2547f5; --acc-hover: #1a39d6; --acc-soft: rgba(37,71,245,.09); --acc-txt: #fff;
  --sig: #ff6b3d; --teal: #0d9884; --teal-hover: #0b8272; --violet: #6d4bd1; --violet-hover: #5a3bb8;
  --ok: #0e9f5b; --warn: #b7740d; --bad: #d92d4a; --info: #0b7fb8; --idle: #7685a3;
  --ok-bg: rgba(14,159,91,.11); --warn-bg: rgba(183,116,13,.12); --bad-bg: rgba(217,45,74,.10); --idle-bg: rgba(118,133,163,.16);
  --side1: #0c42bd; --side2: #072a80;
  --r: 14px; --r-sm: 9px;
  --shadow: 0 1px 2px rgba(20,33,61,.05), 0 8px 24px -14px rgba(20,33,61,.18);
  --shadow-pop: 0 1px 0 rgba(20,33,61,.04), 0 20px 44px -14px rgba(20,33,61,.3);
  --grid-line: rgba(20,33,61,.045);
  --display: "Bricolage Grotesque", "Segoe UI Variable Display", "Segoe UI", system-ui, sans-serif;
  --body: "Instrument Sans", "Segoe UI Variable Text", "Segoe UI", system-ui, -apple-system, Roboto, sans-serif;
  color-scheme: light;
}
:root[data-theme="dark"] {
  --bg: #080c16; --bg2: #0c121e; --panel: #111827; --panel2: #172033; --panel3: #212c44; --line: #1e283c; --line2: #2c3852;
  --txt: #eaf0fb; --mut: #9aa7c2; --mut2: #7482a0;
  --acc: #8aa0ff; --acc-btn: #3f5dff; --acc-hover: #5873ff; --acc-soft: rgba(110,139,255,.14); --acc-txt: #fff;
  --sig: #ff7a50; --teal: #14b39d; --teal-hover: #19c8b0; --violet: #8b6af0; --violet-hover: #9d80f5;
  --ok: #3ddba0; --warn: #f5b84a; --bad: #ff7b92; --info: #46bdf0; --idle: #8794b1;
  --ok-bg: rgba(61,219,160,.12); --warn-bg: rgba(245,184,74,.13); --bad-bg: rgba(255,123,146,.12); --idle-bg: rgba(135,148,177,.16);
  --side1: #0a1f5c; --side2: #060f33;
  --shadow: 0 1px 0 rgba(255,255,255,.03) inset, 0 12px 30px -16px rgba(0,0,0,.7);
  --shadow-pop: 0 24px 60px -16px rgba(0,0,0,.8);
  --grid-line: rgba(255,255,255,.04);
  color-scheme: dark;
}
@media (prefers-color-scheme: dark) {
  :root:not([data-theme]) {
    --bg: #080c16; --bg2: #0c121e; --panel: #111827; --panel2: #172033; --panel3: #212c44; --line: #1e283c; --line2: #2c3852;
    --txt: #eaf0fb; --mut: #9aa7c2; --mut2: #7482a0;
    --acc: #8aa0ff; --acc-btn: #3f5dff; --acc-hover: #5873ff; --acc-soft: rgba(110,139,255,.14); --acc-txt: #fff;
    --sig: #ff7a50; --teal: #14b39d; --teal-hover: #19c8b0; --violet: #8b6af0; --violet-hover: #9d80f5;
    --ok: #3ddba0; --warn: #f5b84a; --bad: #ff7b92; --info: #46bdf0; --idle: #8794b1;
    --ok-bg: rgba(61,219,160,.12); --warn-bg: rgba(245,184,74,.13); --bad-bg: rgba(255,123,146,.12); --idle-bg: rgba(135,148,177,.16);
    --side1: #0a1f5c; --side2: #060f33;
    --shadow: 0 1px 0 rgba(255,255,255,.03) inset, 0 12px 30px -16px rgba(0,0,0,.7);
    --shadow-pop: 0 24px 60px -16px rgba(0,0,0,.8);
    --grid-line: rgba(255,255,255,.04);
    color-scheme: dark;
  }
}
* { box-sizing: border-box; }
html, body { margin: 0; min-height: 100%; }
body { background: var(--bg); color: var(--txt); font: 15px/1.55 var(--body); -webkit-font-smoothing: antialiased; text-rendering: optimizeLegibility; }
h1, h2, h3 { font-family: var(--display); }
h1 { font-size: 26px; line-height: 1.15; margin: 0; font-weight: 700; letter-spacing: -.03em; }
h2 { font-size: 17px; margin: 0; font-weight: 650; letter-spacing: -.015em; }
h3 { font-size: 11.5px; margin: 18px 0 8px; color: var(--mut); font-weight: 650; text-transform: uppercase; letter-spacing: .1em; font-family: var(--body); }
a { color: var(--acc); text-decoration: none; }
.mut { color: var(--mut); } .small { font-size: 13px; } .nowrap { white-space: nowrap; }
svg.ic { width: 18px; height: 18px; flex: none; stroke: currentColor; fill: none; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }

/* ---------- estrutura ---------- */
.shell { display: grid; grid-template-columns: 244px minmax(0, 1fr); min-height: 100vh; }
.side { background: linear-gradient(180deg, var(--side1), var(--side2)); color: #fff; padding: 20px 12px 14px; display: flex; flex-direction: column; gap: 4px; position: sticky; top: 0; height: 100vh; overflow-y: auto; }
.brand { display: flex; gap: 11px; align-items: center; padding: 2px 10px 14px; color: var(--txt); }
.brand .wm { font-family: var(--display); font-weight: 750; font-size: 23px; letter-spacing: -.045em; line-height: 1; }
.brand .wm i { font-style: normal; color: var(--sig); }
.logo { width: 34px; height: 34px; display: inline-flex; flex: none; border-radius: 9px; filter: drop-shadow(0 6px 10px rgba(37,71,245,.32)); }
.logo svg { width: 100%; height: 100%; display: block; }
.side .brand { color: #fff; }
.side .logo { box-shadow: 0 0 0 2px rgba(255,255,255,.88); filter: none; }
.side .brand .wm i { color: #ff9a76; }
.side-co { text-align: center; font-family: var(--display); font-weight: 650; font-size: 15.5px; letter-spacing: -.02em; padding: 2px 8px 10px; color: rgba(255,255,255,.94); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.side-plan { display: block; margin: -6px 2px 12px; padding: 7px 12px; border-radius: 10px; background: rgba(255,255,255,.09); color: rgba(255,255,255,.88); font-size: 12.5px; line-height: 1.35; text-align: center; transition: background .15s; }
.side-plan:hover { background: rgba(255,255,255,.15); color: #fff; }
.side-plan b { display: block; font-size: 13px; letter-spacing: .02em; }
.side-plan span { display: block; opacity: .75; font-variant-numeric: tabular-nums; }
.side-plan.gold b { color: #ffd166; }
.alert-pill { display: flex; align-items: center; gap: 9px; padding: 10px 12px; margin: 0 2px 12px; border-radius: 10px; background: #de3149; color: #fff; font-weight: 650; font-size: 14px; box-shadow: 0 8px 18px -10px rgba(0,0,0,.6); transition: filter .15s, transform .1s; }
.alert-pill:hover { filter: brightness(1.08); color: #fff; } .alert-pill:active { transform: translateY(1px); }
.alert-pill svg.ic { width: 18px; height: 18px; }
.alert-pill.ok { background: rgba(255,255,255,.13); box-shadow: none; font-weight: 560; }
.alert-pill.warn { background: #c98710; }
.alert-pill[hidden] { display: none; }
.nav-label { font-size: 11px; font-weight: 650; text-transform: uppercase; letter-spacing: .12em; color: rgba(255,255,255,.55); padding: 4px 12px 8px; }
.nav { display: flex; flex-direction: column; gap: 3px; }
.nav a { display: flex; gap: 12px; align-items: center; padding: 11px 12px; border-radius: 10px; color: rgba(255,255,255,.84); font-weight: 560; position: relative; transition: background .15s, color .15s; }
.nav a:hover { background: rgba(255,255,255,.1); color: #fff; }
.nav a.on { background: rgba(0,0,0,.27); color: #fff; }
.nav a.on::before { content: ""; position: absolute; left: -12px; top: 9px; bottom: 9px; width: 4px; border-radius: 0 4px 4px 0; background: var(--sig); }
.nav a.on svg.ic { stroke-width: 2.1; }
.side .grow { flex: 1; min-height: 12px; }
.theme-seg { display: flex; padding: 3px; background: rgba(0,0,0,.22); border-radius: 11px; margin: 0 0 10px; }
.theme-seg button { flex: 1; border: 0; background: none; padding: 6px 0; color: rgba(255,255,255,.6); border-radius: 8px; box-shadow: none; }
.theme-seg button svg.ic { width: 16px; height: 16px; }
.theme-seg button:hover { background: none; color: #fff; }
.theme-seg button.on { background: rgba(255,255,255,.2); color: #fff; box-shadow: none; }
.me { display: flex; align-items: center; gap: 10px; padding: 10px; border-radius: var(--r); background: rgba(0,0,0,.22); }
.avatar { width: 34px; height: 34px; border-radius: 11px; background: #fff; color: var(--side1); font-family: var(--display); font-weight: 700; display: flex; align-items: center; justify-content: center; flex: none; }
.me .who { min-width: 0; flex: 1; font-size: 13px; line-height: 1.25; }
.me .who b { display: block; font-weight: 600; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.me .who span { color: rgba(255,255,255,.65); font-size: 12px; }
.me button.ghost { color: rgba(255,255,255,.75); } .me button.ghost:hover { background: rgba(255,255,255,.12); color: #fff; }
main { padding: 26px 34px 80px; max-width: 1440px; width: 100%; animation: rise .35s cubic-bezier(.2,.7,.2,1); }

/* cabeçalho de página e painéis */
.page-head { display: flex; align-items: center; gap: 14px; margin-bottom: 20px; flex-wrap: wrap; }
.page-head .ph-main { flex: 1; min-width: 220px; }
.page-head h1 { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; }
.page-head h1 .ph-ico { width: 38px; height: 38px; border-radius: 11px; background: var(--acc-soft); color: var(--acc); display: inline-flex; align-items: center; justify-content: center; flex: none; }
.page-head h1 .crumb { font-family: var(--body); font-weight: 450; letter-spacing: 0; color: var(--mut); font-size: 17px; }
.page-head .sub { color: var(--mut); margin-top: 4px; font-size: 14.5px; }
.page-head .ph-actions { display: flex; gap: 10px; flex-wrap: wrap; align-items: center; }
.back { display: flex; width: fit-content; align-items: center; gap: 6px; font-size: 13px; color: var(--mut); margin-bottom: 8px; font-weight: 560; }
.back:hover { color: var(--txt); } .back svg.ic { width: 15px; height: 15px; transform: rotate(-90deg); }
.panel { background: var(--panel); border: 1px solid var(--line); border-radius: var(--r); box-shadow: var(--shadow); }
.panel + .panel { margin-top: 18px; }
.pad { padding: 22px; }
.sect { display: flex; align-items: center; gap: 10px; margin: 0 0 16px; padding-bottom: 12px; border-bottom: 1px solid var(--line); }
.sect .si { width: 30px; height: 30px; border-radius: 9px; background: var(--acc-soft); color: var(--acc); display: inline-flex; align-items: center; justify-content: center; flex: none; }
.sect .si.bad { background: var(--bad-bg); color: var(--bad); } .sect .si.ok { background: var(--ok-bg); color: var(--ok); } .sect .si.warn { background: var(--warn-bg); color: var(--warn); } .sect .si.violet { background: rgba(109,75,209,.12); color: var(--violet); }
.sect h2 { font-size: 18px; } .sect .grow { flex: 1; }
.sect.mt { margin-top: 30px; }

@media (max-width: 860px) {
  .shell { grid-template-columns: minmax(0, 1fr); }
  .side { position: static; height: auto; flex-direction: row; flex-wrap: wrap; align-items: center; padding: 10px 12px; gap: 6px; overflow: visible; }
  .brand { padding: 2px 8px; } .brand .wm { display: none; } .me { display: none; } .side .grow { display: none; } .nav-label { display: none; } .side-co { display: none; } .side-plan { display: none; }
  .alert-pill { margin: 0; padding: 7px 10px; font-size: 13px; order: 3; }
  .nav { flex-direction: row; flex-wrap: wrap; } .nav a { padding: 9px 10px; } .nav a span { display: none; } .nav a.on::before { display: none; }
  .theme-seg { margin: 0 0 0 auto; }
  .it { flex-wrap: wrap; } .it .acts { flex-basis: 100%; justify-content: flex-end; opacity: 1; } .it:not(.sel) .acts { display: none; }
  .it .tx span { white-space: normal; }
  main { padding: 20px 14px 60px; }
  h1 { font-size: 23px; }
  .stats { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; }
  .stat { padding: 16px; } .stat b { font-size: 29px; } .stat .ico { width: 32px; height: 32px; }
  .theme-seg button { padding: 6px 7px; } .theme-seg { gap: 1px; }
  .pad { padding: 16px; }
  .lab-row { grid-template-columns: minmax(0, 1fr); gap: 6px; } .lab-row > label:first-child { text-align: left; padding-top: 0; }
}

/* ---------- componentes ---------- */
.card { background: var(--panel); border: 1px solid var(--line); border-radius: var(--r); padding: 22px; box-shadow: var(--shadow); }
.card.flat { box-shadow: none; }
.card > h2 + * { margin-top: 14px; }
.card-head { display: flex; align-items: center; gap: 10px; }
.card-head .ico { width: 36px; height: 36px; border-radius: 11px; background: var(--acc-soft); color: var(--acc); display: flex; align-items: center; justify-content: center; flex: none; }
.grid { display: grid; gap: 18px; grid-template-columns: repeat(auto-fill, minmax(min(300px, 100%), 1fr)); }
.stats { display: grid; gap: 16px; grid-template-columns: repeat(auto-fit, minmax(176px, 1fr)); margin-bottom: 26px; }
.stat { display: grid; grid-template-columns: 1fr auto; grid-template-areas: "v i" "l l" "x x"; gap: 2px 12px; align-items: start; padding: 20px 22px; position: relative; overflow: hidden; color: inherit; transition: transform .18s, box-shadow .18s; }
a.stat:hover { transform: translateY(-2px); box-shadow: var(--shadow-pop); }
.stat::after { content: ""; position: absolute; inset: 0; background-image: linear-gradient(var(--grid-line) 1px, transparent 1px), linear-gradient(90deg, var(--grid-line) 1px, transparent 1px); background-size: 22px 22px; mask-image: linear-gradient(120deg, transparent 55%, #000); -webkit-mask-image: linear-gradient(120deg, transparent 55%, #000); pointer-events: none; }
.stat > div:last-child { display: contents; }
.stat .ico { grid-area: i; width: 38px; height: 38px; border-radius: 11px; display: flex; align-items: center; justify-content: center; background: var(--acc-soft); color: var(--acc); position: relative; z-index: 1; }
.stat .ico svg.ic { width: 19px; height: 19px; }
.stat.g1 .ico { background: var(--ok-bg); color: var(--ok); } .stat.g2 .ico { background: rgba(11,127,184,.11); color: var(--info); } .stat.g3 .ico { background: var(--warn-bg); color: var(--warn); } .stat.g4 .ico { background: var(--bad-bg); color: var(--bad); }
.stat b { grid-area: v; font-family: var(--display); font-size: 36px; line-height: 1.05; letter-spacing: -.04em; font-weight: 700; font-variant-numeric: tabular-nums; position: relative; z-index: 1; }
.stat span { grid-area: l; color: var(--mut); font-size: 13.5px; position: relative; z-index: 1; }
.stat .bar { grid-area: x; margin-top: 10px; position: relative; z-index: 1; }
.row { display: flex; gap: 10px; align-items: center; flex-wrap: wrap; }
.row.sp { justify-content: space-between; }
.col { display: flex; flex-direction: column; gap: 12px; }
.sec-title { display: flex; align-items: center; gap: 10px; margin: 6px 0 16px; }
.sec-title h2 { font-size: 19px; }

button, .btn { font: inherit; font-weight: 580; border: 1px solid var(--line2); background: var(--panel); color: var(--txt); padding: 9px 16px; border-radius: var(--r-sm); cursor: pointer; display: inline-flex; align-items: center; justify-content: center; gap: 8px; line-height: 1.2; box-shadow: 0 1px 1px rgba(20,33,61,.05); transition: background .15s, border-color .15s, transform .08s, box-shadow .15s, color .15s; }
button:hover, .btn:hover { background: var(--panel2); border-color: var(--mut2); }
button:active, .btn:active { transform: translateY(1px); box-shadow: none; }
button.pri, .btn.pri { background: var(--acc-btn); border-color: transparent; color: var(--acc-txt); box-shadow: 0 1px 0 rgba(255,255,255,.18) inset, 0 8px 18px -8px var(--acc-btn); }
button.pri:hover, .btn.pri:hover { background: var(--acc-hover); border-color: transparent; }
button.teal, .btn.teal { background: var(--teal); border-color: transparent; color: #fff; box-shadow: 0 8px 18px -10px var(--teal); }
button.teal:hover, .btn.teal:hover { background: var(--teal-hover); border-color: transparent; }
button.violet, .btn.violet { background: var(--violet); border-color: transparent; color: #fff; box-shadow: 0 8px 18px -10px var(--violet); }
button.violet:hover, .btn.violet:hover { background: var(--violet-hover); border-color: transparent; }
button.slate, .btn.slate { background: var(--mut); border-color: transparent; color: #fff; box-shadow: none; }
button.slate:hover, .btn.slate:hover { background: var(--txt); border-color: transparent; }
button.ghost { background: transparent; border-color: transparent; color: var(--mut); box-shadow: none; } button.ghost:hover { background: var(--panel2); color: var(--txt); border-color: transparent; }
.btn { text-decoration: none; }
.btn.ghost { background: transparent; border-color: transparent; color: var(--mut); box-shadow: none; } .btn.ghost:hover { background: var(--panel2); color: var(--txt); border-color: transparent; }
.btn.icon { padding: 7px; border-radius: 8px; } .btn.icon.sm { padding: 5px; }
button.bad { color: var(--bad); } button.bad:hover { background: var(--bad-bg); border-color: var(--bad); }
button.bad.solid { background: var(--bad); color: #fff; border-color: transparent; } button.bad.solid:hover { filter: brightness(1.08); background: var(--bad); }
button.sm, .btn.sm { padding: 6px 12px; font-size: 13px; border-radius: 8px; }
button.icon { padding: 7px; border-radius: 8px; } button.icon.sm { padding: 5px; }
button:disabled { opacity: .45; cursor: not-allowed; box-shadow: none; }
button:focus-visible, input:focus-visible, select:focus-visible, textarea:focus-visible, a:focus-visible, [tabindex]:focus-visible { outline: 2px solid var(--acc); outline-offset: 2px; }
input, select, textarea { font: inherit; color: var(--txt); background: var(--bg2); border: 1px solid var(--line2); border-radius: var(--r-sm); padding: 9px 12px; width: 100%; min-width: 0; transition: border-color .15s, box-shadow .15s, background .15s; }
input:hover, select:hover, textarea:hover { border-color: var(--mut2); }
input:focus, select:focus, textarea:focus { border-color: var(--acc-btn); background: var(--panel); box-shadow: 0 0 0 4px var(--acc-soft); outline: none; }
input::placeholder, textarea::placeholder { color: var(--mut2); }
input[type=checkbox] { width: 17px; height: 17px; accent-color: var(--acc-btn); padding: 0; }
input[type=color] { padding: 3px; height: 40px; width: 58px; cursor: pointer; }
input[type=range] { padding: 0; accent-color: var(--acc-btn); }
input[type=time] { max-width: 150px; } input[type=date], input[type=datetime-local] { max-width: 220px; }
textarea { min-height: 96px; resize: vertical; }
select { cursor: pointer; }
label.f { display: flex; flex-direction: column; gap: 6px; font-size: 13px; color: var(--mut); font-weight: 580; flex: 1; min-width: 160px; }
label.chk { display: inline-flex; gap: 8px; align-items: center; color: var(--txt); font-size: 14px; font-weight: 500; cursor: pointer; }
.fields { display: flex; gap: 14px; flex-wrap: wrap; }
.dot { width: 9px; height: 9px; border-radius: 50%; background: var(--idle); display: inline-block; flex: none; }
.dot.on { background: var(--ok); box-shadow: 0 0 0 4px var(--ok-bg); animation: pulse 2.4s ease-in-out infinite; }
.dot.checking { background: var(--warn); } .dot.offline { background: var(--bad); } .dot.offhours { background: var(--idle); }
.badge { font-size: 12px; font-weight: 620; padding: 3px 10px; border-radius: 99px; background: var(--panel3); color: var(--mut); white-space: nowrap; display: inline-flex; align-items: center; gap: 6px; }
.badge.ok { background: var(--ok-bg); color: var(--ok); } .badge.warn { background: var(--warn-bg); color: var(--warn); } .badge.bad { background: var(--bad-bg); color: var(--bad); } .badge.idle { background: var(--idle-bg); color: var(--idle); }
.badge.acc { background: var(--acc-soft); color: var(--acc); }
.badge svg.ic { width: 12px; height: 12px; }
.tagc { display: inline-flex; align-items: center; gap: 5px; font-size: 12px; font-weight: 580; padding: 2px 9px; border-radius: 7px; background: var(--acc-soft); color: var(--acc); white-space: nowrap; }
.empty { text-align: center; padding: 56px 20px; color: var(--mut); border: 1.5px dashed var(--line2); border-radius: var(--r); background: var(--panel); background-image: radial-gradient(circle at 50% 0%, var(--acc-soft), transparent 60%); }
.empty .ei { width: 64px; height: 64px; margin: 0 auto 16px; border-radius: 20px; background: var(--acc-soft); color: var(--acc); display: flex; align-items: center; justify-content: center; }
.empty .ei svg.ic { width: 28px; height: 28px; } .empty b { display: block; color: var(--txt); font-family: var(--display); font-size: 19px; letter-spacing: -.02em; margin-bottom: 4px; }
.bar { height: 7px; background: var(--panel3); border-radius: 99px; overflow: hidden; } .bar > i { display: block; height: 100%; background: var(--acc-btn); border-radius: 99px; transition: width .4s; }
.seg { display: inline-flex; padding: 3px; background: var(--bg2); border: 1px solid var(--line); border-radius: 10px; }
.seg button { border: 0; background: none; padding: 5px 12px; font-size: 13px; color: var(--mut); border-radius: 7px; box-shadow: none; }
.seg button.on { background: var(--panel); color: var(--txt); box-shadow: 0 1px 2px rgba(0,0,0,.14); }

/* abas sublinhadas (detalhes de TV, playlist, conta) */
.tabs { display: flex; gap: 4px; border-bottom: 1px solid var(--line); margin: 0 0 22px; flex-wrap: wrap; }
.tabs button { border: 0; background: none; padding: 11px 16px; color: var(--mut); border-radius: 0; box-shadow: none; position: relative; margin-bottom: -1px; border-bottom: 2px solid transparent; font-weight: 600; }
.tabs button:hover { background: none; color: var(--txt); border-color: transparent; border-bottom-color: var(--line2); }
.tabs button.on { color: var(--acc); border-bottom-color: var(--acc-btn); }
.tabs button .tdot { width: 8px; height: 8px; border-radius: 50%; background: var(--bad); display: inline-block; }
.tabs button svg.ic { width: 16px; height: 16px; }

/* linhas de formulário rotuladas (rótulo à esquerda, valor à direita) */
.lab-row { display: grid; grid-template-columns: 190px minmax(0, 1fr); gap: 14px; align-items: start; padding: 9px 0; }
.lab-row > label:first-child, .lab-row > .lb { text-align: right; color: var(--mut); font-weight: 580; font-size: 14px; padding-top: 10px; }
.lab-row.tight > .lb { padding-top: 2px; }
.lab-row .val { min-width: 0; display: flex; flex-direction: column; gap: 6px; max-width: 520px; }
.lab-row .hint { color: var(--mut); font-size: 12.5px; }
/* edição travada: campos viram texto até clicar em "Habilitar edição" */
fieldset.lock { border: 0; padding: 0; margin: 0; min-width: 0; }
fieldset.lock:disabled input:not([type=checkbox]):not([type=color]):not([type=range]), fieldset.lock:disabled select, fieldset.lock:disabled textarea { background: transparent; border-color: transparent; color: var(--acc); font-weight: 560; padding-left: 0; box-shadow: none; -webkit-appearance: none; appearance: none; resize: none; cursor: default; }
fieldset.lock:disabled select { background-image: none; }
fieldset.lock:disabled textarea { min-height: 0; field-sizing: content; }
fieldset.lock:disabled input[type=checkbox], fieldset.lock:disabled input[type=range] { opacity: .65; }
fieldset.lock:disabled button:not(.keep) { opacity: .5; }
fieldset.lock:disabled .chip, fieldset.lock:disabled .theme { pointer-events: none; opacity: .75; }
fieldset.lock:disabled .tagfield { background: transparent; border-color: transparent; padding-left: 0; box-shadow: none; }
fieldset.lock:disabled .tagfield input, fieldset.lock:disabled .tagfield .tagc button { display: none; }
fieldset.lock:disabled .lbrow { cursor: default; opacity: .8; }
fieldset.lock:disabled .lbrow .addbtn { display: none; }
fieldset.lock:disabled .it { cursor: pointer; }
.editbar { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; }

/* ---------- barra de ferramentas e tabela de dados ---------- */
.tbar { display: flex; gap: 12px; align-items: center; flex-wrap: wrap; padding: 16px 18px; border-bottom: 1px solid var(--line); }
.tbar .grow { flex: 1; }
.search { position: relative; flex: 1 1 260px; max-width: 380px; }
.search svg.ic { position: absolute; left: 12px; top: 50%; transform: translateY(-50%); color: var(--mut2); width: 16px; height: 16px; pointer-events: none; }
.search input { padding-left: 36px; }
.tbar label.sel { display: inline-flex; align-items: center; gap: 8px; font-size: 12px; color: var(--mut); font-weight: 650; text-transform: uppercase; letter-spacing: .06em; }
.tbar label.sel select { width: auto; text-transform: none; letter-spacing: 0; font-weight: 500; font-size: 14px; color: var(--txt); padding: 7px 10px; }
.tagbar { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; padding: 12px 18px; border-bottom: 1px solid var(--line); background: var(--bg2); font-size: 13px; }
.tagbar .lbl { color: var(--mut); font-weight: 650; text-transform: uppercase; font-size: 11.5px; letter-spacing: .08em; display: inline-flex; align-items: center; gap: 6px; }
.bulkbar { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; padding: 12px 18px; background: var(--acc-soft); border-bottom: 1px solid var(--line); font-size: 14px; }
.bulkbar select { width: auto; min-width: 220px; }
.tscroll { overflow-x: auto; }
table.dt { width: 100%; border-collapse: collapse; }
table.dt th { text-align: left; font-size: 11.5px; font-weight: 700; text-transform: uppercase; letter-spacing: .08em; color: var(--mut); padding: 12px 14px; border-bottom: 1px solid var(--line); background: var(--bg2); white-space: nowrap; user-select: none; }
table.dt th.s { cursor: pointer; } table.dt th.s:hover { color: var(--txt); }
table.dt th .arrow { color: var(--acc); margin-left: 4px; }
table.dt td { padding: 13px 14px; border-bottom: 1px solid var(--line); font-size: 14.5px; vertical-align: middle; }
table.dt tr:last-child td { border-bottom: 0; }
table.dt tbody tr { transition: background .12s; }
table.dt tbody tr:hover { background: var(--panel2); }
table.dt tbody tr.sel { background: var(--acc-soft); }
table.dt td.ck, table.dt th.ck { width: 44px; padding-right: 0; }
table.dt td:first-child { position: relative; }
table.dt tr.st-offline td:first-child, table.dt tr.st-checking td:first-child, table.dt tr.st-offhours td:first-child, table.dt tr.st-online td:first-child { box-shadow: inset 4px 0 0 var(--ok); }
table.dt tr.st-offline td:first-child { box-shadow: inset 4px 0 0 var(--bad); }
table.dt tr.st-checking td:first-child { box-shadow: inset 4px 0 0 var(--warn); }
table.dt tr.st-offhours td:first-child { box-shadow: inset 4px 0 0 var(--idle); }
table.dt tr.st-waiting td:first-child { box-shadow: inset 4px 0 0 var(--line2); }
table.dt td .nm { font-weight: 620; color: var(--txt); } table.dt td a.nm:hover { color: var(--acc); }
table.dt td .sub { color: var(--mut); font-size: 12.5px; }
.tfoot { display: flex; align-items: center; justify-content: space-between; gap: 12px; flex-wrap: wrap; padding: 12px 18px; border-top: 1px solid var(--line); font-size: 13px; color: var(--mut); }
.pager { display: flex; gap: 4px; align-items: center; }
.legend { display: flex; flex-wrap: wrap; gap: 8px 22px; padding: 14px 18px 4px; font-size: 13px; color: var(--mut); }
.legend span { display: inline-flex; align-items: center; gap: 8px; }
.stbadge { display: inline-flex; align-items: center; gap: 7px; font-size: 13px; font-weight: 620; padding: 3px 11px 3px 9px; border-radius: 99px; white-space: nowrap; }
.stbadge .dot { width: 8px; height: 8px; }
.stbadge.ok { background: var(--ok-bg); color: var(--ok); } .stbadge.warn { background: var(--warn-bg); color: var(--warn); } .stbadge.bad { background: var(--bad-bg); color: var(--bad); } .stbadge.idle { background: var(--idle-bg); color: var(--idle); }
.thumbmini { width: 56px; height: 34px; border-radius: 6px; background: #05070b; overflow: hidden; display: inline-flex; align-items: center; justify-content: center; color: #fff; flex: none; }
.thumbmini img, .thumbmini video { width: 100%; height: 100%; object-fit: cover; }
.thumbmini svg.ic { width: 18px; height: 18px; }

/* tags (editor de etiquetas) */
.tagfield { display: flex; flex-wrap: wrap; gap: 6px; align-items: center; padding: 6px 8px; background: var(--bg2); border: 1px solid var(--line2); border-radius: var(--r-sm); }
.tagfield:focus-within { border-color: var(--acc-btn); background: var(--panel); box-shadow: 0 0 0 4px var(--acc-soft); }
.tagfield input { border: 0; background: transparent; box-shadow: none; padding: 4px; flex: 1; min-width: 110px; width: auto; }
.tagfield input:focus { box-shadow: none; background: transparent; }
.tagfield .tagc button { padding: 0; border: 0; background: none; box-shadow: none; color: inherit; display: inline-flex; opacity: .7; } .tagfield .tagc button:hover { opacity: 1; background: none; }
.tagfield .tagc svg.ic { width: 12px; height: 12px; stroke-width: 2.4; }

/* ---------- TVs ---------- */
.tv { display: flex; flex-direction: column; gap: 14px; color: inherit; transition: transform .18s, border-color .18s, box-shadow .18s; }
.tv:hover { transform: translateY(-3px); border-color: var(--line2); box-shadow: var(--shadow-pop); }
.tv .screen { aspect-ratio: 16/9; border-radius: 11px; background: radial-gradient(120% 90% at 20% 0%, #1a2760, #0a0f26 70%); display: flex; align-items: center; justify-content: center; color: #8d9bd6; position: relative; overflow: hidden; border: 1px solid rgba(255,255,255,.08); box-shadow: 0 0 0 4px var(--panel2), 0 0 0 5px var(--line); margin: 5px 5px 4px; }
.tv .screen::before { content: ""; position: absolute; inset: 0; background: repeating-linear-gradient(0deg, rgba(255,255,255,.035) 0 1px, transparent 1px 3px); }
.tv .screen::after { content: ""; position: absolute; inset: 0; background: linear-gradient(115deg, rgba(255,255,255,.1), transparent 35%); }
.tv .screen svg.ic { width: 36px; height: 36px; stroke-width: 1.4; opacity: .75; position: relative; }
.tv .screen .live { position: absolute; top: 10px; left: 10px; z-index: 1; }
.tv .screen .badge:not(.ok):not(.warn):not(.bad) { background: rgba(255,255,255,.12); color: #c3cae6; }
.tv .nm { font-family: var(--display); font-weight: 650; font-size: 18px; letter-spacing: -.02em; }
.infotbl { width: 100%; border-collapse: collapse; }
.infotbl th, .infotbl td { text-align: left; padding: 10px 12px; font-size: 14px; border-bottom: 1px solid var(--line); }
.infotbl th { color: var(--mut); font-weight: 560; width: 46%; } .infotbl td { color: var(--acc); font-weight: 560; }
.infotbl tr:last-child th, .infotbl tr:last-child td { border-bottom: 0; }
.infotbl.bar-l { border-left: 4px solid var(--line2); } .infotbl.bar-l.bad { border-left-color: var(--bad); } .infotbl.bar-l.ok { border-left-color: var(--ok); } .infotbl.bar-l.warn { border-left-color: var(--warn); }
.twocol { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 34px; }
@media (max-width: 1000px) { .twocol { grid-template-columns: minmax(0, 1fr); gap: 20px; } }
.subhead { font-family: var(--display); font-size: 18px; font-weight: 650; letter-spacing: -.02em; color: var(--mut); padding-bottom: 8px; margin-bottom: 8px; border-bottom: 2px solid var(--line); }
.banner { display: flex; align-items: center; gap: 12px; padding: 16px 20px; border-radius: var(--r); font-weight: 650; font-size: 17px; color: #fff; background: var(--bad); box-shadow: var(--shadow); }
.banner.ok { background: var(--ok); } .banner.warn { background: #c98710; }
.banner svg.ic { width: 24px; height: 24px; }
.alerts { display: flex; flex-direction: column; gap: 10px; margin-bottom: 18px; }
.alerts .al { display: flex; align-items: center; gap: 12px; padding: 12px 16px; border-radius: 12px; background: var(--bad-bg); color: var(--bad); font-weight: 560; }
.alerts .al.warn { background: var(--warn-bg); color: var(--warn); }
.alerts .al a { margin-left: auto; font-weight: 650; }

/* mídias */
.thumbs { display: grid; gap: 18px; grid-template-columns: repeat(auto-fill, minmax(215px, 1fr)); }
.thumb { background: var(--panel); border: 1px solid var(--line); border-radius: var(--r); overflow: hidden; display: flex; flex-direction: column; box-shadow: var(--shadow); transition: border-color .15s, transform .18s, box-shadow .18s; position: relative; }
.thumb:hover { border-color: var(--line2); transform: translateY(-3px); box-shadow: var(--shadow-pop); }
.thumb .pv { aspect-ratio: 16/10; background: #05070b; display: flex; align-items: center; justify-content: center; position: relative; }
.thumb .pv img, .thumb .pv video { width: 100%; height: 100%; object-fit: cover; }
.thumb .pv .tag { position: absolute; top: 8px; left: 8px; background: rgba(5,7,11,.72); color: #fff; backdrop-filter: blur(4px); }
.thumb .meta { padding: 12px 14px 14px; display: flex; flex-direction: column; gap: 8px; font-size: 13px; }
.thumb .nm { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; font-weight: 620; font-size: 14px; color: var(--txt); }
.thumb.pick { cursor: pointer; } .thumb.pick.on { border-color: var(--acc-btn); box-shadow: 0 0 0 2px var(--acc-btn) inset; }
.thumb.pick .ck { position: absolute; top: 8px; right: 8px; width: 24px; height: 24px; border-radius: 50%; background: var(--acc-btn); color: #fff; display: none; align-items: center; justify-content: center; }
.thumb.pick.on .ck { display: flex; } .thumb .ck svg.ic { width: 14px; height: 14px; stroke-width: 3; }
.thumb .selbox { position: absolute; top: 8px; right: 8px; z-index: 2; width: 24px; height: 24px; border-radius: 7px; background: rgba(5,7,11,.6); display: flex; align-items: center; justify-content: center; backdrop-filter: blur(4px); }
.thumb .selbox input { width: 16px; height: 16px; }
.thumb.sel { border-color: var(--acc-btn); box-shadow: 0 0 0 2px var(--acc-btn) inset; }
.drop { border: 2px dashed var(--line2); border-radius: var(--r); padding: 22px 20px; text-align: center; color: var(--mut); cursor: pointer; background: var(--panel); transition: border-color .15s, background .15s; }
.drop:hover, .drop.over { border-color: var(--acc-btn); background: var(--acc-soft); color: var(--txt); }
.drop .ei { width: 48px; height: 48px; margin: 0 auto 8px; border-radius: 14px; background: var(--acc-soft); color: var(--acc); display: flex; align-items: center; justify-content: center; }
.drop b { color: var(--txt); display: block; font-family: var(--display); font-size: 17px; letter-spacing: -.02em; }
.upl { display: flex; gap: 12px; align-items: center; font-size: 13px; margin: 0 0 8px; padding: 10px 14px; background: var(--panel); border: 1px solid var(--line); border-radius: var(--r-sm); } .upl .bar { flex: 1; } .upl > span { min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; max-width: 46%; }
.mvbig { aspect-ratio: 16/9; background: #05070b; border-radius: 12px; overflow: hidden; display: flex; align-items: center; justify-content: center; border: 1px solid var(--line); }
.mvbig img, .mvbig video { width: 100%; height: 100%; object-fit: contain; }

/* ---------- playlist ---------- */
.libgrid { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 20px; align-items: start; }
@media (max-width: 1100px) { .libgrid { grid-template-columns: minmax(0, 1fr); } }
.libbox { border: 1px solid var(--line); border-radius: var(--r); overflow: hidden; background: var(--panel); display: flex; flex-direction: column; }
.libbox.final { border-top: 3px solid var(--ok); }
.libbox .lbhead { padding: 10px 12px 0; background: var(--bg2); border-bottom: 1px solid var(--line); }
.libbox .lbhead .tabs { margin: 0; border: 0; } .libbox .lbhead .tabs button { padding: 9px 14px; }
.libbox .lbtitle { text-align: center; font-weight: 650; padding: 11px; background: var(--bg2); border-bottom: 1px solid var(--line); }
.libbox .lbsearch { padding: 10px 12px; background: var(--bg2); border-bottom: 1px solid var(--line); }
.libbox.final .lbsearch { background: var(--ok-bg); }
.libbox .lblist { max-height: 520px; overflow-y: auto; padding: 10px; display: flex; flex-direction: column; gap: 6px; min-height: 120px; }
.lbrow { display: flex; align-items: center; gap: 12px; padding: 8px 10px; border: 1px solid var(--line); border-radius: 11px; background: var(--panel); cursor: pointer; transition: border-color .15s, background .15s; }
.lbrow:hover { border-color: var(--line2); background: var(--panel2); }
.lbrow .tx { flex: 1; min-width: 0; } .lbrow .tx b { display: block; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; font-weight: 620; font-size: 14px; } .lbrow .tx span { font-size: 12px; color: var(--mut); }
.lbrow .addbtn { width: 30px; height: 30px; padding: 0; border-radius: 50%; background: var(--acc-btn); color: #fff; border-color: transparent; box-shadow: none; flex: none; }
.lbrow .addbtn:hover { background: var(--acc-hover); }
.plgrid { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 20px; align-items: start; margin-top: 22px; }
.plgrid > * { min-width: 0; }
@media (max-width: 1100px) { .plgrid { grid-template-columns: minmax(0, 1fr); } }
.it { display: flex; align-items: center; gap: 12px; padding: 8px 10px 8px 8px; border: 1px solid var(--line); border-radius: 12px; background: var(--panel); cursor: pointer; transition: border-color .15s, background .15s, transform .15s, box-shadow .15s; }
.it:hover { border-color: var(--line2); box-shadow: var(--shadow); }
.it.sel { border-color: var(--acc-btn); background: var(--acc-soft); }
.it.drag { opacity: .35; } .it.over { border-color: var(--acc-btn); transform: translateY(2px); }
.it .grip { color: var(--mut2); cursor: grab; display: flex; padding: 4px 0; } .it .grip svg.ic { width: 16px; height: 16px; }
.tile { width: 64px; height: 40px; border-radius: 9px; flex: none; overflow: hidden; display: flex; align-items: center; justify-content: center; color: #fff; background: #000; }
.tile img, .tile video { width: 100%; height: 100%; object-fit: cover; }
.tile svg.ic { width: 21px; height: 21px; }
.tile.t-text { background: linear-gradient(135deg, #3d63ff, #1b2fbf); } .tile.t-news { background: linear-gradient(135deg, #ff8a3d, #e5392f); }
.tile.t-weather { background: linear-gradient(135deg, #0ea5e9, #2547f5); } .tile.t-clock { background: linear-gradient(135deg, #14b8a6, #0ea5e9); }
.tile.t-web { background: linear-gradient(135deg, #475569, #1e293b); } .tile.t-youtube { background: linear-gradient(135deg, #ff3d3d, #b00020); } .tile.t-countdown { background: linear-gradient(135deg, #ec4899, #8b5cf6); }
.tile.t-list { background: linear-gradient(135deg, #f59e0b, #e5392f); } .tile.t-quotes { background: linear-gradient(135deg, #10b981, #047857); }
.tile.t-qr { background: linear-gradient(135deg, #1e293b, #0f172a); }
.it .tx { flex: 1; min-width: 0; } .it .tx b { display: block; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; font-weight: 620; font-size: 14px; }
.it .tx span { font-size: 12px; color: var(--mut); }
.it .acts { display: flex; gap: 2px; opacity: 0; transition: opacity .15s; } .it:hover .acts, .it.sel .acts, .it:focus-within .acts { opacity: 1; }
.add-big { width: 100%; padding: 12px; border: 1.5px dashed var(--line2); background: transparent; color: var(--mut); border-radius: 12px; font-size: 14.5px; box-shadow: none; }
.add-big:hover { border-color: var(--acc-btn); color: var(--acc); background: var(--acc-soft); }
.types { display: grid; gap: 12px; grid-template-columns: repeat(auto-fill, minmax(190px, 1fr)); margin-top: 16px; }
.type { text-align: left; flex-direction: column; align-items: flex-start; gap: 10px; padding: 16px; border-radius: 14px; background: var(--panel2); height: 100%; }
.type:hover { border-color: var(--acc-btn); background: var(--panel); }
.type .tile { width: 44px; height: 44px; border-radius: 12px; color: #fff; } .type b { font-size: 15px; } .type span { font-size: 12.5px; color: var(--mut); font-weight: 400; line-height: 1.35; }
.pvbox { border-radius: var(--r); overflow: hidden; background: #000; aspect-ratio: 16/9; position: relative; border: 1px solid var(--line); box-shadow: var(--shadow-pop); }
.pvbox iframe { position: absolute; inset: 0; width: 100%; height: 100%; border: 0; }
.pvbox .pvmsg { position: absolute; inset: 0; display: flex; align-items: center; justify-content: center; color: #8b97ae; font-size: 14px; background: #05070b; text-align: center; padding: 12px; }
.pvbar { display: flex; align-items: center; justify-content: space-between; gap: 10px; margin-bottom: 10px; }
.days { display: flex; gap: 6px; flex-wrap: wrap; } .days label { cursor: pointer; }
.days input { display: none; }
.days span { display: inline-block; padding: 6px 11px; border: 1px solid var(--line2); border-radius: 9px; font-size: 13px; font-weight: 560; background: var(--bg2); color: var(--mut); }
.days input:checked + span { background: var(--acc-soft); border-color: var(--acc-btn); color: var(--acc); }
fieldset.lock:disabled .days label { pointer-events: none; opacity: .75; }
.feedrow { display: flex; gap: 8px; margin-bottom: 8px; align-items: center; }
.preview { font-size: 13px; background: var(--bg2); border: 1px solid var(--line); border-radius: var(--r-sm); padding: 10px 12px; margin: 0 0 10px; }
.preview li { margin: 3px 0; }
.chips { display: flex; gap: 6px; flex-wrap: wrap; }
.chip { padding: 5px 11px; font-size: 12.5px; border-radius: 99px; background: var(--panel2); box-shadow: none; }
.chip.on { background: var(--acc-soft); border-color: var(--acc-btn); color: var(--acc); }
.cat { font-size: 11.5px; font-weight: 700; text-transform: uppercase; letter-spacing: .1em; color: var(--mut2); margin: 10px 0 6px; }
.themes { display: flex; gap: 8px; flex-wrap: wrap; }
.theme { width: 46px; height: 32px; padding: 0; border-radius: 9px; position: relative; overflow: hidden; border: 2px solid var(--line2); }
.theme i { position: absolute; right: 5px; bottom: 5px; width: 9px; height: 9px; border-radius: 50%; }
.theme:hover { transform: scale(1.06); border-color: var(--acc-btn); }
.kv { display: flex; align-items: center; gap: 8px; margin-bottom: 8px; } .kv input:first-child { flex: 3; } .kv input:nth-child(2) { flex: 1.2; }
.note { font-size: 13px; color: var(--mut); background: var(--bg2); border: 1px solid var(--line); border-radius: var(--r-sm); padding: 10px 12px; }
.note.warn { border-color: rgba(183,116,13,.4); color: var(--warn); background: var(--warn-bg); }
.rulerow { display: grid; grid-template-columns: minmax(0, 1.3fr) minmax(0, 2fr) auto; gap: 14px; align-items: start; padding: 14px; border: 1px solid var(--line); border-radius: 12px; background: var(--bg2); margin-bottom: 10px; }
@media (max-width: 900px) { .rulerow { grid-template-columns: minmax(0, 1fr); } }

/* relatórios */
.hbars { display: flex; flex-direction: column; gap: 9px; }
.hbar { display: grid; grid-template-columns: minmax(120px, 34%) minmax(0, 1fr) 70px; gap: 12px; align-items: center; font-size: 13.5px; }
.hbar .nm { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; font-weight: 560; }
.hbar .tr { height: 10px; background: var(--panel3); border-radius: 99px; overflow: hidden; } .hbar .tr i { display: block; height: 100%; border-radius: 99px; background: linear-gradient(90deg, var(--acc-btn), #6f8bff); }
.hbar .n { text-align: right; font-variant-numeric: tabular-nums; color: var(--mut); font-weight: 600; }
.vbars { display: flex; align-items: flex-end; gap: 6px; padding-top: 6px; }
.vbars .vb { flex: 1; min-width: 0; display: flex; flex-direction: column; align-items: center; gap: 6px; font-size: 11px; color: var(--mut); }
.vbars .vb .bw { height: 120px; width: 100%; display: flex; align-items: flex-end; justify-content: center; }
.vbars .vb i { display: block; width: 100%; max-width: 46px; border-radius: 6px 6px 2px 2px; background: linear-gradient(180deg, #6f8bff, var(--acc-btn)); min-height: 3px; }
.vbars .vb b { font-size: 11.5px; color: var(--txt); font-variant-numeric: tabular-nums; }

/* modal, toast, login */
.modal-bg { position: fixed; inset: 0; background: rgba(6,9,18,.6); backdrop-filter: blur(6px); display: flex; align-items: center; justify-content: center; padding: 16px; z-index: 50; animation: fade .15s; }
.modal { background: var(--panel); border: 1px solid var(--line2); border-radius: 18px; padding: 26px; width: min(520px, 100%); max-height: 90vh; overflow: auto; box-shadow: var(--shadow-pop); animation: pop .2s cubic-bezier(.2,.8,.2,1); }
.modal.wide { width: min(900px, 100%); }
.modal h2 { font-size: 22px; letter-spacing: -.025em; margin-bottom: 4px; }
@keyframes fade { from { opacity: 0; } } @keyframes pop { from { opacity: 0; transform: translateY(8px) scale(.98); } }
@keyframes rise { from { opacity: 0; transform: translateY(8px); } }
@keyframes pulse { 50% { box-shadow: 0 0 0 7px transparent; } }
.grid > *, .thumbs > *, .stats > * { animation: rise .4s cubic-bezier(.2,.7,.2,1) backwards; }
.grid > :nth-child(2), .thumbs > :nth-child(2), .stats > :nth-child(2) { animation-delay: .04s; }
.grid > :nth-child(3), .thumbs > :nth-child(3), .stats > :nth-child(3) { animation-delay: .08s; }
.grid > :nth-child(4), .thumbs > :nth-child(4), .stats > :nth-child(4) { animation-delay: .12s; }
.grid > :nth-child(n+5), .thumbs > :nth-child(n+5) { animation-delay: .16s; }
@media (prefers-reduced-motion: reduce) { *, *::before, *::after { animation: none !important; transition: none !important; } }
#toasts { position: fixed; right: 18px; bottom: 18px; display: flex; flex-direction: column; gap: 8px; z-index: 100; }
.toast { background: var(--txt); color: var(--bg); border-left: 4px solid var(--ok); padding: 12px 16px; border-radius: 12px; box-shadow: var(--shadow-pop); max-width: 360px; font-weight: 520; animation: pop .2s; }
.toast.err { border-left-color: var(--bad); }

/* login */
.login { min-height: 100vh; display: grid; grid-template-columns: minmax(0, 1.15fr) minmax(0, 1fr); }
.login .art { background: #080b1a; color: #fff; padding: 40px 52px; display: flex; flex-direction: column; justify-content: space-between; gap: 22px; position: relative; overflow: hidden; isolation: isolate; }
.login .art::before { content: ""; position: absolute; inset: 0; z-index: -1; background: radial-gradient(60% 50% at 85% 5%, rgba(61,99,255,.55), transparent 70%), radial-gradient(45% 40% at 0% 100%, rgba(255,107,61,.22), transparent 70%), linear-gradient(rgba(255,255,255,.045) 1px, transparent 1px), linear-gradient(90deg, rgba(255,255,255,.045) 1px, transparent 1px); background-size: auto, auto, 36px 36px, 36px 36px; }
.login .art h1 { font-size: clamp(34px, 3.6vw, 48px); line-height: 1.04; max-width: 600px; letter-spacing: -.045em; margin: 0 0 14px; }
.login .art h1 em { font-style: normal; color: #ff8c66; }
.login .art p { color: rgba(255,255,255,.72); font-size: 16.5px; max-width: 470px; margin: 0 0 20px; }
.login .feats { display: flex; flex-direction: column; gap: 10px; }
.login .feats div { display: flex; gap: 12px; align-items: center; color: rgba(255,255,255,.88); font-weight: 500; }
.login .feats .fi { width: 34px; height: 34px; border-radius: 10px; background: rgba(255,255,255,.1); border: 1px solid rgba(255,255,255,.12); display: flex; align-items: center; justify-content: center; }
.login .brand { padding: 0; color: #fff; }
.login .formside { display: flex; align-items: center; justify-content: center; padding: 28px; background: var(--bg); }
.login .box { width: min(400px, 100%); display: flex; flex-direction: column; gap: 18px; animation: rise .5s cubic-bezier(.2,.7,.2,1); }
.login .box h2 { font-size: 30px; letter-spacing: -.04em; }
.login .brand.mobile { display: none; color: var(--txt); }
@media (max-width: 960px) { .login { grid-template-columns: 1fr; } .login .art { display: none; } .login .brand.mobile { display: flex; } }
.mock { position: relative; width: min(430px, 100%); aspect-ratio: 16/9.4; flex: none; border-radius: 16px; background: #0c1330; border: 1px solid rgba(255,255,255,.14); box-shadow: 0 0 0 7px rgba(255,255,255,.05), 0 40px 80px -20px rgba(0,0,0,.7); padding: 16px; display: grid; grid-template-columns: 1.5fr 1fr; grid-template-rows: auto 1fr 1fr; gap: 10px; transform: perspective(1400px) rotateY(-9deg) rotateX(3deg); transform-origin: left center; overflow: hidden; }
.mock .bar-top { grid-column: 1 / -1; display: flex; justify-content: space-between; align-items: center; font-size: 11px; color: rgba(255,255,255,.6); letter-spacing: .08em; text-transform: uppercase; font-weight: 650; }
.mock .live-pill { display: inline-flex; align-items: center; gap: 6px; } .mock .live-pill i { width: 7px; height: 7px; border-radius: 50%; background: #ff6b3d; animation: pulse 1.8s infinite; box-shadow: 0 0 0 3px rgba(255,107,61,.25); }
.mock .m-news { grid-row: 2 / 4; border-radius: 10px; padding: 14px; background: linear-gradient(160deg, #2547f5, #101a60); display: flex; flex-direction: column; justify-content: flex-end; gap: 8px; }
.mock .m-news b { font-family: var(--display); font-size: 21px; line-height: 1.1; letter-spacing: -.03em; }
.mock .m-news .ln { height: 6px; border-radius: 3px; background: rgba(255,255,255,.28); } .mock .m-news .ln.s { width: 60%; }
.mock .m-clock { border-radius: 10px; background: rgba(255,255,255,.07); display: flex; flex-direction: column; justify-content: center; padding: 0 14px; }
.mock .m-clock b { font-family: var(--display); font-size: 34px; letter-spacing: -.04em; line-height: 1; font-variant-numeric: tabular-nums; } .mock .m-clock span { font-size: 11px; color: rgba(255,255,255,.55); margin-top: 3px; }
.mock .m-w { border-radius: 10px; background: linear-gradient(135deg, #ff8a3d, #e5392f); display: flex; align-items: center; justify-content: space-between; padding: 0 14px; }
.mock .m-w b { font-family: var(--display); font-size: 28px; letter-spacing: -.04em; } .mock .m-w span { font-size: 11px; opacity: .85; text-align: right; line-height: 1.3; }
.err-txt { color: var(--bad); min-height: 1.3em; font-size: 14px; }
table { width: 100%; border-collapse: collapse; } td, th { text-align: left; padding: 11px 8px; border-bottom: 1px solid var(--line); font-size: 14px; } tr:last-child td, tr:last-child th { border-bottom: 0; }
pre.logs { margin: 0; max-height: 320px; overflow: auto; background: var(--bg2); border: 1px solid var(--line); border-radius: var(--r-sm); padding: 12px; font-size: 12px; white-space: pre-wrap; word-break: break-word; font-family: ui-monospace, "Cascadia Mono", Consolas, monospace; }

/* celular: vem por último para vencer as regras de base acima */
@media (max-width: 860px) {
  .lab-row { grid-template-columns: minmax(0, 1fr); gap: 4px; }
  .lab-row > .lb, .lab-row.tight > .lb { text-align: left; padding-top: 0; }
  .page-head h1 { font-size: 22px; }
  .search { max-width: none; flex-basis: 100%; }
  .tbar label.sel { width: 100%; justify-content: space-between; }
  .tabs button { padding: 10px 12px; }
}
