/* Hangar, identidade SO Tech. Tema escuro, relevo leve. */

:root {
  --bg: #0B1329;
  --bg-side-top: #0F1B3C;
  --surface: #111C3C;
  --surface-top: #162449;
  --surface-2: #0E1836;
  --inset: #0B1329;
  --border: #22305E;
  --border-soft: #1B2748;
  --border-strong: #28396C;
  --text: #F6F8FC;
  --text-2: #C3CCE6;
  --muted: #8E9BC0;
  --muted-2: #6C7AA6;
  --faint: #5C6A94;
  --blue: #2F5DFB;
  --blue-light: #4A74FF;
  --blue-text: #8FB0FF;
  --cyan: #3BD6E8;
  --ok: #3DDC97;
  --warn: #F5B82E;
  --bad: #FF8A8A;
  --radius: 14px;
  --radius-sm: 10px;
  --font: 'IBM Plex Sans', system-ui, -apple-system, 'Segoe UI', sans-serif;
  --font-title: 'Space Grotesk', var(--font);
  --font-mono: 'IBM Plex Mono', ui-monospace, Menlo, Consolas, monospace;
}

* { box-sizing: border-box; }
html, body { margin: 0; padding: 0; }
body { background: var(--bg); color: var(--text); font-family: var(--font); font-size: 14px; line-height: 1.4; min-height: 100vh; }
a { color: inherit; text-decoration: none; }
button { font: inherit; color: inherit; background: none; border: 0; padding: 0; cursor: pointer; }
input, select, textarea { font: inherit; color: inherit; }
code { font-family: var(--font-mono); font-size: 12.5px; }
:focus-visible { outline: 2px solid var(--cyan); outline-offset: 2px; }

/* ===== casca ===== */
.shell { display: grid; grid-template-columns: 232px 1fr; min-height: 100vh; }
.side { padding: 20px 14px; display: flex; flex-direction: column; gap: 22px; border-right: 1px solid #16224A; background: linear-gradient(180deg, var(--bg-side-top) 0%, var(--bg) 100%); position: sticky; top: 0; height: 100vh; }
.logo { display: flex; align-items: center; gap: 12px; padding: 4px 8px; }
.logo .ic { width: 38px; height: 38px; border-radius: 10px; background: linear-gradient(180deg, #3E6BFF 0%, #2F5DFB 100%); box-shadow: 0 6px 14px rgba(47,93,251,.35), inset 0 1px 0 rgba(255,255,255,.3); display: flex; align-items: center; justify-content: center; flex: none; }
.logo .ic svg { width: 26px; height: 26px; }
.logo .nm { font-family: var(--font-title); font-weight: 700; font-size: 22px; letter-spacing: -.02em; line-height: 1; }
.nav { display: flex; flex-direction: column; gap: 3px; }
.nav a { display: flex; align-items: center; gap: 10px; padding: 10px 12px; border-radius: var(--radius-sm); color: var(--muted); font-weight: 500; font-size: 14px; }
.nav a::before { content: ''; width: 6px; height: 6px; border-radius: 50%; background: #26335C; flex: none; }
.nav a:hover { color: var(--text); }
.nav a.on { background: linear-gradient(180deg, #1A2A58 0%, #16224A 100%); color: var(--text); box-shadow: inset 0 1px 0 rgba(255,255,255,.07); }
.nav a.on::before { background: var(--cyan); box-shadow: 0 0 8px rgba(59,214,232,.9); }
.nav a.sub { padding: 7px 12px 7px 30px; font-size: 13px; color: var(--text-2); }
.nav a.sub::before { width: 4px; height: 4px; background: var(--blue); box-shadow: 0 0 6px rgba(47,93,251,.9); }
.side .out { margin-top: auto; font-size: 13px; color: var(--muted); padding: 0 12px; }
.side .out button:hover { color: var(--text); }
.main { padding: 28px 32px 48px; max-width: 1180px; width: 100%; }

/* ===== cabeçalhos ===== */
.crumb { display: inline-block; color: var(--muted); font-size: 13px; margin-bottom: 12px; }
.crumb:hover { color: var(--text); }
.head { display: flex; justify-content: space-between; align-items: flex-start; margin-bottom: 20px; gap: 16px; flex-wrap: wrap; }
h1 { font-family: var(--font-title); font-weight: 700; font-size: 28px; letter-spacing: -.02em; margin: 0; line-height: 1.1; }
.head p { margin: 6px 0 0; color: var(--muted); max-width: 64ch; }
.acts { display: flex; gap: 8px; align-items: center; flex-wrap: wrap; }
.t { display: flex; align-items: center; gap: 12px; flex-wrap: wrap; }

/* ===== botões ===== */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 8px; font-weight: 600; font-size: 13.5px; padding: 10px 16px; border-radius: var(--radius-sm); white-space: nowrap; color: #fff; line-height: 1.2;
       background: linear-gradient(180deg, var(--blue-light) 0%, var(--blue) 100%); box-shadow: 0 4px 14px rgba(47,93,251,.35), inset 0 1px 0 rgba(255,255,255,.28); transition: transform .08s ease, filter .12s ease; }
.btn:hover { filter: brightness(1.06); }
.btn:active { transform: translateY(1px); }
.btn.sec { background: linear-gradient(180deg, #1D2D5C 0%, #162348 100%); color: var(--text); border: 1px solid var(--border-strong); box-shadow: inset 0 1px 0 rgba(255,255,255,.08); }
.btn.ghost { background: transparent; color: var(--text-2); border: 1px solid var(--border-strong); box-shadow: none; }
.btn.wait, .btn[disabled] { background: #121E40; color: var(--faint); border: 1px solid var(--border-soft); box-shadow: none; cursor: default; filter: none; }
.btn.danger { background: transparent; color: var(--bad); border: 1px solid #3B2A4C; box-shadow: none; }
.btn.danger.solid { background: linear-gradient(180deg, #E05C5C 0%, #C94444 100%); color: #fff; border: 0; box-shadow: 0 4px 14px rgba(201,68,68,.3); }
.btn.big { font-size: 15px; padding: 13px 22px; border-radius: 12px; }
.btn.small { font-size: 12.5px; padding: 7px 12px; }
.lnk { color: var(--blue-text); font-size: 13px; font-weight: 500; }
.lnk:hover { text-decoration: underline; }
.lnk.muted { color: var(--muted); }

/* ===== avisos ===== */
.flash { margin: 0 0 18px; padding: 12px 16px; border-radius: var(--radius-sm); background: rgba(61,220,151,.1); border: 1px solid rgba(61,220,151,.3); color: var(--ok); font-weight: 500; }
.flash.err { background: rgba(255,138,138,.1); border-color: rgba(255,138,138,.3); color: var(--bad); }
.flash.info { background: rgba(47,93,251,.12); border-color: rgba(47,93,251,.35); color: var(--blue-text); }

/* ===== lista de apps ===== */
.cols { display: grid; grid-template-columns: 1.5fr 1.1fr 1.35fr 1.6fr 110px; gap: 18px; padding: 0 21px 8px; font-size: 12px; color: var(--muted-2); font-weight: 500; }
.list { display: flex; flex-direction: column; gap: 10px; }
.app .btn { justify-self: end; }
.app { display: grid; grid-template-columns: 1.5fr 1.1fr 1.35fr 1.6fr 110px; gap: 18px; align-items: center; padding: 16px 20px; border-radius: var(--radius);
       background: linear-gradient(180deg, var(--surface-top) 0%, var(--surface) 100%); border: 1px solid var(--border); box-shadow: 0 3px 10px rgba(0,0,0,.16), inset 0 1px 0 rgba(255,255,255,.06); }
.app .name { font-family: var(--font-title); font-weight: 600; font-size: 17px; }
.app .name:hover { color: var(--blue-text); }
.empty { padding: 40px 24px; text-align: center; color: var(--muted); border: 1px dashed var(--border-strong); border-radius: var(--radius); }
.empty p { margin: 0 0 14px; }

.pill { display: inline-flex; align-items: center; gap: 8px; padding: 5px 11px 5px 9px; border-radius: 999px; font-weight: 500; font-size: 13px; border: 1px solid transparent; white-space: nowrap; }
.pill::before { content: ''; width: 8px; height: 8px; border-radius: 50%; background: currentColor; box-shadow: 0 0 8px currentColor; }
.pill.ok { background: rgba(61,220,151,.1); color: var(--ok); border-color: rgba(61,220,151,.25); }
.pill.warn { background: rgba(245,184,46,.1); color: var(--warn); border-color: rgba(245,184,46,.25); }
.pill.bad { background: rgba(255,138,138,.1); color: var(--bad); border-color: rgba(255,138,138,.25); }
.pill.off { background: rgba(142,155,192,.1); color: var(--muted); border-color: rgba(142,155,192,.25); }
.pill.off::before { box-shadow: none; }
.pill.sm { padding: 2px 8px 2px 6px; font-size: 12px; }
.sub { display: block; color: var(--muted); font-size: 12px; margin-top: 4px; }
.chip { display: inline-block; font-family: var(--font-title); font-weight: 700; font-size: 14px; background: var(--inset); border: 1px solid var(--border-strong); border-radius: 8px; padding: 4px 10px; box-shadow: inset 0 2px 4px rgba(0,0,0,.45); white-space: nowrap; }
.new { display: inline-flex; align-items: center; gap: 6px; margin-top: 6px; font-size: 12px; font-weight: 500; color: var(--blue-text); }
.new::before { content: ''; width: 6px; height: 6px; border-radius: 50%; background: var(--blue); box-shadow: 0 0 8px rgba(47,93,251,.9); flex: none; }
.dom { color: var(--text-2); word-break: break-all; }
.dom.muted { color: var(--faint); }

/* ===== painel do app ===== */
.panel { border-radius: 16px; background: linear-gradient(180deg, var(--surface-top) 0%, var(--surface) 100%); border: 1px solid var(--border); box-shadow: 0 4px 14px rgba(0,0,0,.18), inset 0 1px 0 rgba(255,255,255,.06); overflow: hidden; }
.ph { padding: 22px 24px 0; display: flex; justify-content: space-between; align-items: flex-start; gap: 16px; flex-wrap: wrap; }
.ph .dom { display: block; margin-top: 8px; font-size: 13px; }
.tabs { display: flex; flex-wrap: wrap; gap: 2px; padding: 18px 24px 0; border-bottom: 1px solid var(--border); }
.tab { padding: 10px 14px; color: var(--muted); font-weight: 500; font-size: 14px; border-bottom: 2px solid transparent; margin-bottom: -1px; white-space: nowrap; }
.tab:hover { color: var(--text); }
.tab.on { color: var(--text); border-bottom-color: var(--cyan); }
.pb { padding: 20px 24px 24px; }
.grid2 { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; }
.cardx { background: var(--surface-2); border: 1px solid var(--border-soft); border-radius: 12px; padding: 18px 20px; box-shadow: inset 0 1px 0 rgba(255,255,255,.04); min-width: 0; }
.cardx h3 { font-family: var(--font-title); font-weight: 600; font-size: 15px; margin: 0 0 12px; display: flex; justify-content: space-between; align-items: center; gap: 10px; }
.cardx.hi { border-color: rgba(47,93,251,.6); box-shadow: 0 0 0 1px rgba(47,93,251,.25), 0 10px 26px rgba(47,93,251,.14), inset 0 1px 0 rgba(255,255,255,.06); background: linear-gradient(180deg, #152350 0%, var(--surface-2) 100%); }
.kv { display: flex; justify-content: space-between; gap: 12px; padding: 7px 0; border-top: 1px solid #16224A; font-size: 13.5px; }
.kv:first-of-type { border-top: 0; }
.kv > :first-child { color: var(--muted); flex: none; }
.kv > :last-child { text-align: right; min-width: 0; word-break: break-word; }
.bigv { font-family: var(--font-title); font-weight: 700; font-size: 32px; letter-spacing: -.02em; line-height: 1; }
.vrow { display: flex; align-items: center; justify-content: space-between; gap: 14px; flex-wrap: wrap; }
.vrow p { margin: 6px 0 0; color: var(--text-2); font-size: 13px; }
.logs { background: #070D1F; border: 1px solid var(--border-soft); border-radius: 8px; padding: 10px 12px; font-family: var(--font-mono); font-size: 11.5px; color: var(--text-2); line-height: 1.6; margin-top: 10px; box-shadow: inset 0 2px 6px rgba(0,0,0,.5); white-space: pre-wrap; word-break: break-all; overflow: auto; max-height: 220px; }
.logs.tall { max-height: 60vh; min-height: 320px; font-size: 12px; }
.logs .ts { color: var(--faint); }
.live { display: inline-flex; align-items: center; gap: 6px; font-size: 12px; color: var(--cyan); font-weight: 500; font-family: var(--font); }
.live::before { content: ''; width: 6px; height: 6px; border-radius: 50%; background: var(--cyan); box-shadow: 0 0 8px rgba(59,214,232,.9); animation: pulse 1.6s ease-in-out infinite; }
.live.off { color: var(--muted); } .live.off::before { background: var(--muted); box-shadow: none; animation: none; }
@keyframes pulse { 0%, 100% { opacity: 1; } 50% { opacity: .35; } }
.meter { height: 6px; background: var(--inset); border-radius: 3px; overflow: hidden; margin-top: 8px; box-shadow: inset 0 1px 3px rgba(0,0,0,.5); }
.meter i { display: block; height: 100%; background: linear-gradient(90deg, var(--blue), var(--cyan)); border-radius: 3px; transition: width .4s ease; }

/* ===== formulários ===== */
.form { display: grid; grid-template-columns: 1fr 1fr; gap: 16px 20px; }
.f { display: flex; flex-direction: column; gap: 6px; min-width: 0; }
.f.w { grid-column: 1 / -1; }
.f label, .lbl { font-size: 13px; color: var(--text-2); font-weight: 500; }
.help { font-size: 12px; color: var(--muted-2); }
.in { width: 100%; background: var(--inset); border: 1px solid var(--border-strong); border-radius: var(--radius-sm); padding: 10px 12px; font-size: 14px; color: var(--text); box-shadow: inset 0 2px 4px rgba(0,0,0,.4); }
.in::placeholder { color: var(--faint); }
.in:focus { outline: none; border-color: var(--blue); box-shadow: inset 0 2px 4px rgba(0,0,0,.4), 0 0 0 3px rgba(47,93,251,.25); }
.in.mono { font-family: var(--font-mono); font-size: 13px; }
select.in { appearance: none; background-image: linear-gradient(45deg, transparent 50%, var(--muted) 50%), linear-gradient(135deg, var(--muted) 50%, transparent 50%); background-position: calc(100% - 18px) 50%, calc(100% - 13px) 50%; background-size: 5px 5px, 5px 5px; background-repeat: no-repeat; padding-right: 34px; }
select.in option { background: #0E1836; color: var(--text); }
.row2 { display: flex; gap: 10px; align-items: center; flex-wrap: wrap; }
.seg { display: inline-flex; background: var(--inset); border: 1px solid var(--border-strong); border-radius: var(--radius-sm); padding: 3px; box-shadow: inset 0 2px 4px rgba(0,0,0,.4); }
.seg label { padding: 7px 14px; border-radius: 8px; color: var(--muted); font-size: 13px; font-weight: 500; cursor: pointer; }
.seg input { position: absolute; opacity: 0; width: 0; height: 0; }
.seg input:checked + label, .seg label.on { background: linear-gradient(180deg, #1D2D5C 0%, #162348 100%); color: var(--text); box-shadow: inset 0 1px 0 rgba(255,255,255,.08); }
.seg input:focus-visible + label { outline: 2px solid var(--cyan); }
.in.narrow { width: 120px; }
.sw { display: flex; align-items: center; gap: 12px; padding: 12px 14px; border-radius: 12px; background: var(--surface-2); border: 1px solid var(--border-soft); cursor: pointer; }
.sw input { position: absolute; opacity: 0; width: 0; height: 0; }
.sw .k { width: 40px; height: 22px; border-radius: 999px; background: #26335C; position: relative; flex: none; box-shadow: inset 0 1px 3px rgba(0,0,0,.5); transition: background .15s ease; }
.sw .k::after { content: ''; position: absolute; top: 2px; left: 2px; width: 18px; height: 18px; border-radius: 50%; background: var(--muted); transition: left .15s ease, background .15s ease; }
.sw input:checked ~ .k { background: var(--blue); }
.sw input:checked ~ .k::after { left: 20px; background: #fff; }
.sw input:focus-visible ~ .k { outline: 2px solid var(--cyan); outline-offset: 2px; }
.sw b { font-weight: 500; display: block; } .sw small { color: var(--muted); font-size: 12px; }
.vt { display: flex; flex-direction: column; gap: 8px; }
.vr { display: grid; grid-template-columns: 1fr 1.6fr auto auto; gap: 12px; align-items: center; }
.vr.saved { padding: 10px 14px 10px 16px; border-radius: var(--radius-sm); background: var(--surface-2); border: 1px solid var(--border-soft); box-shadow: inset 0 1px 0 rgba(255,255,255,.04); grid-template-columns: 1.1fr 1.9fr auto auto; min-height: 56px; }
.vr .val { font-family: var(--font-mono); font-size: 12.5px; color: var(--text-2); word-break: break-all; display: flex; align-items: center; gap: 8px; min-width: 0; }
.vr.removing code { text-decoration: line-through; color: var(--muted); }
.vr.removing .val, .vr.removing .tag { opacity: .35; }
.vr .undo { display: none; font-size: 12px; color: var(--bad); white-space: nowrap; }
.vr.removing .undo { display: inline; }
.vr.removing [data-toggle-remove] { display: none; }
.hidden-chk { position: absolute; opacity: 0; width: 0; height: 0; pointer-events: none; }
.tag { display: inline-block; font-size: 11.5px; padding: 2px 8px; border-radius: 999px; background: #16244A; color: var(--text-2); border: 1px solid var(--border-strong); white-space: nowrap; }
.chk { display: inline-flex; align-items: center; gap: 6px; font-size: 12.5px; color: var(--muted); white-space: nowrap; cursor: pointer; }
.chk input { accent-color: var(--blue); }
.foot { display: flex; align-items: center; gap: 12px; margin-top: 22px; flex-wrap: wrap; }
.foot p { margin: 0 0 0 6px; color: var(--muted); font-size: 13px; max-width: 48ch; }
.zone { margin-top: 26px; padding-top: 18px; border-top: 1px solid var(--border); display: flex; justify-content: space-between; align-items: center; gap: 16px; flex-wrap: wrap; }
.zone p { margin: 0; color: var(--muted); font-size: 13px; max-width: 56ch; }
.confirm { display: none; align-items: center; gap: 8px; }
.confirm.open { display: inline-flex; }

/* ===== domínios ===== */
.dlist { display: flex; flex-direction: column; gap: 10px; }
.dcols, .drow { display: grid; grid-template-columns: 1.7fr 1fr 1.3fr 1.2fr 122px; gap: 16px; align-items: center; }
.dcols { padding: 0 21px 8px; font-size: 12px; color: var(--muted-2); font-weight: 500; }
.drow .acts { justify-self: end; }
.drow { padding: 14px 20px; border-radius: var(--radius); background: linear-gradient(180deg, var(--surface-top) 0%, var(--surface) 100%); border: 1px solid var(--border); box-shadow: 0 3px 10px rgba(0,0,0,.16), inset 0 1px 0 rgba(255,255,255,.06); }
.drow .host { font-family: var(--font-title); font-weight: 600; font-size: 15px; word-break: break-all; }
.hint { margin-top: 16px; padding: 14px 16px; border-radius: 12px; background: rgba(47,93,251,.1); border: 1px solid rgba(47,93,251,.35); line-height: 1.55; }
.hint b { display: block; margin-bottom: 4px; }
.hint code { background: var(--inset); padding: 2px 6px; border-radius: 5px; border: 1px solid var(--border-strong); }
.hint .row2 { margin-top: 10px; }
.inline-form { display: flex; gap: 8px; align-items: center; flex-wrap: wrap; }

/* ===== atividade ===== */
.timeline { display: flex; flex-direction: column; gap: 6px; }
.ev { display: grid; grid-template-columns: 150px 150px 1fr; gap: 16px; align-items: center; padding: 12px 18px; border-radius: var(--radius-sm); background: var(--surface-2); border: 1px solid var(--border-soft); }
.ev .when { color: var(--muted); font-size: 13px; }
.ev .who { min-width: 0; }
.filters { display: flex; gap: 8px; flex-wrap: wrap; margin-bottom: 16px; }
.filters a { padding: 6px 12px; border-radius: 999px; border: 1px solid var(--border-strong); color: var(--muted); font-size: 13px; }
.filters a.on { background: #16244A; color: var(--text); }

/* ===== atualizar e acompanhar ===== */
.two { display: grid; grid-template-columns: 1fr 1.6fr; gap: 14px; }
.vlist { display: flex; flex-direction: column; gap: 6px; }
.v { display: grid; grid-template-columns: 16px auto 1fr; gap: 12px; align-items: center; padding: 10px 12px; border-radius: 8px; border: 1px solid transparent; color: var(--text-2); cursor: pointer; }
.v input { position: absolute; opacity: 0; width: 0; height: 0; }
.v .r { width: 16px; height: 16px; border-radius: 50%; border: 2px solid var(--border-strong); }
.v:hover { background: rgba(255,255,255,.03); }
.v.sel, .v:has(input:checked) { background: #16244A; border-color: var(--blue); color: var(--text); }
.v.sel .r, .v:has(input:checked) .r { border-color: var(--blue); background: var(--blue); box-shadow: inset 0 0 0 3px #16244A; }
.v .meta { font-size: 13px; } .v .meta em { font-style: normal; color: var(--muted); }
.note { margin-top: 12px; color: var(--muted); font-size: 13px; }
.steps { display: flex; flex-direction: column; gap: 14px; margin-top: 4px; }
.step { display: grid; grid-template-columns: 12px 1fr auto; gap: 14px; align-items: center; font-size: 15px; }
.step.done { color: var(--text-2); }
.step.todo { color: var(--faint); }
.step .when { color: var(--muted); font-size: 12px; }
.lamp { width: 12px; height: 12px; border-radius: 50%; background: var(--ok); box-shadow: 0 0 10px rgba(61,220,151,.75); }
.lamp.warn { background: var(--warn); box-shadow: 0 0 10px rgba(245,184,46,.75); animation: pulse 1.2s ease-in-out infinite; }
.lamp.bad { background: var(--bad); box-shadow: 0 0 10px rgba(255,138,138,.75); }
.lamp.off { background: #26335C; box-shadow: none; }
.bar { height: 6px; background: var(--inset); border-radius: 3px; margin-top: 18px; overflow: hidden; box-shadow: inset 0 1px 3px rgba(0,0,0,.5); }
.bar i { display: block; height: 100%; width: 0; background: linear-gradient(90deg, var(--blue), var(--cyan)); border-radius: 3px; transition: width .5s ease; }
.bar.err i { background: var(--bad); }

/* ===== ícones e botões de ícone ===== */
.i { width: 16px; height: 16px; flex: none; }
.btn .i { margin: 0 -1px; }
.btn.small .i { width: 14px; height: 14px; }
.ibtn { display: inline-flex; align-items: center; justify-content: center; width: 34px; height: 34px; border-radius: 9px; border: 1px solid var(--border-strong); color: var(--muted); background: transparent; flex: none; transition: color .12s ease, border-color .12s ease, background .12s ease; }
.ibtn:hover { color: var(--text); border-color: #3B4E8C; background: rgba(255,255,255,.04); }
.ibtn.danger:hover { color: var(--bad); border-color: rgba(255,138,138,.5); background: rgba(255,138,138,.08); }
.ibtn.small { width: 28px; height: 28px; border-radius: 7px; }
.ibtn.small .i { width: 14px; height: 14px; }
.ibtn.eye .off { display: none; }
.ibtn.eye.on .on { display: none; }
.ibtn.eye.on .off { display: inline; }
.ibtn.eye.on { color: var(--cyan); border-color: rgba(59,214,232,.45); }
.btn.ghost.on { color: var(--text); border-color: #3B4E8C; background: rgba(255,255,255,.04); }

/* ===== energia do app: iniciar, reiniciar, parar ===== */
.power { display: inline-flex; border: 1px solid var(--border-strong); border-radius: var(--radius-sm); overflow: hidden; background: linear-gradient(180deg, #1D2D5C 0%, #162348 100%); box-shadow: inset 0 1px 0 rgba(255,255,255,.08); }
.power form { display: contents; }
.pbtn { display: inline-flex; align-items: center; gap: 8px; padding: 10px 16px; font-weight: 600; font-size: 13.5px; border-right: 1px solid var(--border-strong); transition: background .12s ease, color .12s ease; white-space: nowrap; }
.pbtn:last-of-type, .power form:last-child .pbtn { border-right: 0; }
.pbtn.start { color: var(--ok); }
.pbtn.restart { color: var(--blue-text); }
.pbtn.stop { color: var(--bad); }
.pbtn:not([disabled]):hover { background: rgba(255,255,255,.06); }
.pbtn.start:not([disabled]):hover { background: rgba(61,220,151,.14); }
.pbtn.restart:not([disabled]):hover { background: rgba(47,93,251,.2); }
.pbtn.stop:not([disabled]):hover { background: rgba(255,138,138,.14); }
.pbtn[disabled] { color: var(--faint); cursor: default; }
.pbtn.armed { background: linear-gradient(180deg, #E05C5C 0%, #C94444 100%); color: #fff; }
.pbtn:active:not([disabled]) { transform: translateY(1px); }

/* ===== busca e ordenação ===== */
.tools { display: flex; gap: 10px; align-items: center; flex-wrap: wrap; }
.search { display: flex; align-items: center; gap: 8px; background: var(--inset); border: 1px solid var(--border-strong); border-radius: var(--radius-sm); padding: 0 12px; box-shadow: inset 0 2px 4px rgba(0,0,0,.4); color: var(--muted); }
.search input { background: transparent; border: 0; color: var(--text); padding: 10px 0; width: 240px; font-size: 14px; outline: none; }
.search input::placeholder { color: var(--faint); }
.search input::-webkit-search-cancel-button { filter: invert(.6); }
.search:focus-within { border-color: var(--blue); box-shadow: inset 0 2px 4px rgba(0,0,0,.4), 0 0 0 3px rgba(47,93,251,.25); color: var(--text); }
select.in.sort { width: auto; padding-top: 9px; padding-bottom: 9px; }
.empty-filter { display: none; margin-top: 10px; }
.empty-filter.show { display: block; }

/* ===== segredo (caixa com cadeado) ===== */
.sec { display: inline-flex; align-items: center; cursor: pointer; position: relative; }
.sec input { position: absolute; opacity: 0; width: 0; height: 0; }
.sec span { display: inline-flex; align-items: center; gap: 6px; height: 40px; padding: 0 12px; border-radius: var(--radius-sm); border: 1px solid var(--border-strong); color: var(--muted); font-size: 13px; font-weight: 500; background: var(--inset); white-space: nowrap; box-shadow: inset 0 2px 4px rgba(0,0,0,.4); transition: color .12s ease, border-color .12s ease, background .12s ease; }
.sec:hover span { color: var(--text); }
.sec input:checked + span { color: var(--cyan); border-color: rgba(59,214,232,.5); background: rgba(59,214,232,.08); box-shadow: none; }
.sec input:focus-visible + span { outline: 2px solid var(--cyan); outline-offset: 2px; }
.tag.lock { display: inline-flex; align-items: center; gap: 5px; color: var(--cyan); border-color: rgba(59,214,232,.35); background: rgba(59,214,232,.08); }
.tag.lock .i { width: 12px; height: 12px; }
.bulk { margin-top: 12px; }
.bulk textarea.in { min-height: 140px; resize: vertical; line-height: 1.55; }

/* ===== login ===== */
.login-wrap { min-height: 100vh; display: flex; align-items: center; justify-content: center; padding: 24px; }
.login { width: 100%; max-width: 380px; padding: 28px; }
.login .logo { padding: 0; margin-bottom: 22px; }
.login h1 { font-size: 22px; margin-bottom: 4px; }
.login p { color: var(--muted); margin: 0 0 18px; }
.login .f { margin-bottom: 14px; }

/* ===== responsivo ===== */
@media (max-width: 900px) {
  .shell { grid-template-columns: 1fr; }
  .side { position: static; height: auto; flex-direction: row; align-items: center; flex-wrap: wrap; gap: 12px; border-right: 0; border-bottom: 1px solid #16224A; padding: 12px 16px; }
  .nav { flex-direction: row; flex-wrap: wrap; }
  .nav a.sub { padding-left: 12px; }
  .side .out { margin-top: 0; margin-left: auto; }
  .main { padding: 20px 16px 40px; }
  .cols, .dcols { display: none; }
  .app, .drow { grid-template-columns: 1fr 1fr; }
  .app > :first-child, .drow > :first-child { grid-column: 1 / -1; }
  .grid2, .two, .form { grid-template-columns: 1fr; }
  .vr, .vr.saved { grid-template-columns: 1fr; }
  .ev { grid-template-columns: 1fr; gap: 4px; }
}
@media (prefers-reduced-motion: reduce) {
  .live::before, .lamp.warn { animation: none; }
  .btn, .meter i, .bar i, .sw .k, .sw .k::after { transition: none; }
}
