/* =============================================================================
   Centralino PBX - Mondo Hi-Tech
   White & blue theme derived from the Mondo Hi-Tech logo (#0083a8 / #57585a)
   ============================================================================= */
:root {
  --brand: #0083a8;
  --brand-600: #00728f;
  --brand-700: #005d76;
  --brand-800: #064b60;
  --brand-50: #eaf5f9;
  --brand-100: #d3ebf3;
  --cyan: #12a9d6;
  --ink: #1d2b33;
  --gray: #57585a;
  --muted: #64737c;
  --line: #d9e6ed;
  --bg: #f3f8fb;
  --white: #ffffff;
  --ok: #15803d;
  --ok-bg: #e5f5eb;
  --warn: #a15c00;
  --warn-bg: #fff4dc;
  --err: #b42318;
  --err-bg: #fdecea;
  --radius: 10px;
  --shadow: 0 1px 2px rgba(6, 75, 96, .06), 0 4px 16px rgba(6, 75, 96, .06);
  --topbar: 64px;
  --sidebar: 252px;
  font-family: system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
}
* { box-sizing: border-box; }
html, body { margin: 0; padding: 0; }
body { background: var(--bg); color: var(--ink); font-size: 14px; line-height: 1.5; }
a { color: var(--brand); text-decoration: none; }
a:hover { color: var(--brand-700); text-decoration: underline; }
code { font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace; font-size: 12.5px; background: var(--brand-50); color: var(--brand-800); padding: 1px 5px; border-radius: 4px; }
h1, h2, h3 { color: var(--brand-800); margin: 0 0 12px; line-height: 1.25; }
h1 { font-size: 22px; font-weight: 650; }
h2 { font-size: 17px; font-weight: 650; }
h3 { font-size: 15px; font-weight: 650; }
.ico { width: 18px; height: 18px; flex: none; }
.muted { color: var(--muted); }
.small { font-size: 12.5px; }
.mono { font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace; }
.nowrap { white-space: nowrap; }
.right { text-align: right; }
.hidden { display: none !important; }

/* ---- Top bar (white: the logo always sits on white) ---------------------- */
.topbar {
  position: fixed; inset: 0 0 auto 0; height: var(--topbar); z-index: 30;
  display: flex; align-items: center; gap: 16px; padding: 0 20px 0 12px;
  background: var(--white); border-bottom: 1px solid var(--line); box-shadow: 0 1px 8px rgba(6, 75, 96, .05);
}
.brand { display: flex; align-items: center; gap: 12px; min-width: calc(var(--sidebar) - 28px); flex: none; }
.brand img { height: 40px; width: auto; display: block; background: #fff; }
.brand .product { white-space: nowrap; font-size: 11px; letter-spacing: .12em; text-transform: uppercase; color: var(--muted); border-left: 1px solid var(--line); padding-left: 10px; }
.menu-toggle { display: none; background: none; border: 0; color: var(--brand); cursor: pointer; padding: 6px; }
.topbar .spacer { flex: 1; }
.tenant-switch { display: flex; align-items: center; gap: 8px; }
.tenant-switch select { min-width: 220px; }
.tenant-badge { display: inline-flex; align-items: center; gap: 6px; background: var(--brand-50); color: var(--brand-800); border: 1px solid var(--brand-100); padding: 5px 12px; border-radius: 999px; font-weight: 600; }
.user-menu { display: flex; align-items: center; gap: 10px; }
.user-menu .who { text-align: right; line-height: 1.2; }
.user-menu .who b { display: block; color: var(--ink); }
.user-menu .who span { font-size: 12px; color: var(--muted); }
.avatar { width: 34px; height: 34px; border-radius: 50%; background: var(--brand); color: #fff; display: grid; place-items: center; font-weight: 700; }

/* ---- Sidebar (blue) ---------------------------------------------------------- */
.sidebar {
  position: fixed; top: var(--topbar); bottom: 0; left: 0; width: var(--sidebar); z-index: 20; overflow-y: auto;
  background: linear-gradient(180deg, var(--brand) 0%, var(--brand-700) 60%, var(--brand-800) 100%);
  color: #fff; padding: 14px 10px 24px;
}
.sidebar .group { margin-bottom: 10px; }
.sidebar .group-label { font-size: 10.5px; text-transform: uppercase; letter-spacing: .11em; color: rgba(255, 255, 255, .62); padding: 10px 12px 4px; }
.sidebar a { display: flex; align-items: center; gap: 10px; color: rgba(255, 255, 255, .92); padding: 7px 12px; border-radius: 8px; font-size: 13.5px; }
.sidebar a:hover { background: rgba(255, 255, 255, .12); color: #fff; text-decoration: none; }
.sidebar a.active { background: #fff; color: var(--brand-700); font-weight: 600; box-shadow: 0 2px 8px rgba(0, 0, 0, .12); }
.sidebar a.active .ico { color: var(--brand); }
.sidebar .ico { width: 17px; height: 17px; opacity: .95; }

/* ---- Content ----------------------------------------------------------------- */
.main { margin-left: var(--sidebar); padding: calc(var(--topbar) + 22px) 28px 40px; min-height: 100vh; }
.page-head { display: flex; align-items: flex-start; justify-content: space-between; gap: 16px; margin-bottom: 18px; flex-wrap: wrap; }
.page-head .sub { color: var(--muted); margin-top: -6px; }
.actions { display: flex; gap: 8px; flex-wrap: wrap; align-items: center; }
.footer { margin-top: 32px; color: var(--muted); font-size: 12px; text-align: center; }

.card { background: var(--white); border: 1px solid var(--line); border-radius: var(--radius); box-shadow: var(--shadow); padding: 20px; margin-bottom: 18px; }
.card > h2:first-child, .card > h3:first-child { margin-top: 0; }
.card.flush { padding: 0; overflow: hidden; }
.card-head { display: flex; justify-content: space-between; align-items: center; padding: 14px 18px; border-bottom: 1px solid var(--line); gap: 12px; }
.card-head h2, .card-head h3 { margin: 0; }
.grid { display: grid; gap: 18px; }
.grid.cols-2 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.grid.cols-3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.grid.cols-4 { grid-template-columns: repeat(4, minmax(0, 1fr)); }

/* ---- Stat tiles -------------------------------------------------------------- */
.stat { display: flex; align-items: center; gap: 14px; padding: 16px 18px; }
.stat .ico-wrap { width: 44px; height: 44px; border-radius: 12px; background: var(--brand-50); color: var(--brand); display: grid; place-items: center; }
.stat .ico-wrap .ico { width: 22px; height: 22px; }
.stat .val { font-size: 24px; font-weight: 700; color: var(--brand-800); line-height: 1.1; }
.stat .lbl { color: var(--muted); font-size: 12.5px; }
a.stat:hover { text-decoration: none; border-color: var(--brand-100); }

/* ---- Bar chart (pure CSS) ---------------------------------------------------- */
.bars { display: flex; align-items: flex-end; gap: 14px; height: 180px; padding: 10px 4px 0; border-bottom: 1px solid var(--line); }
.bars .col { flex: 1; display: flex; flex-direction: column; align-items: stretch; justify-content: flex-end; height: 100%; position: relative; }
.bars .seg { border-radius: 4px 4px 0 0; min-height: 2px; }
.bars .seg.ok { background: var(--brand); }
.bars .seg.ko { background: #9ccfe0; border-radius: 0; }
.bars .num { text-align: center; font-size: 11.5px; color: var(--muted); margin-bottom: 4px; }
.bars-labels { display: flex; gap: 14px; padding: 6px 4px 0; }
.bars-labels span { flex: 1; text-align: center; font-size: 12px; color: var(--muted); }
.legend { display: flex; gap: 16px; font-size: 12.5px; color: var(--muted); margin-top: 10px; }
.legend i { display: inline-block; width: 10px; height: 10px; border-radius: 2px; margin-right: 6px; vertical-align: -1px; }

/* ---- Tables ------------------------------------------------------------------- */
.table-wrap { overflow-x: auto; }
table.data { width: 100%; border-collapse: collapse; }
table.data th { text-align: left; font-size: 12px; font-weight: 650; color: var(--brand-800); text-transform: uppercase; letter-spacing: .04em; background: var(--brand-50); padding: 10px 14px; border-bottom: 1px solid var(--line); white-space: nowrap; }
table.data td { padding: 10px 14px; border-bottom: 1px solid #edf3f6; vertical-align: middle; }
table.data tr:last-child td { border-bottom: 0; }
table.data tbody tr:hover td { background: #f8fcfd; }
table.data td.act { white-space: nowrap; text-align: right; width: 1%; }
table.data audio { height: 30px; max-width: 240px; vertical-align: middle; }
.empty { padding: 36px; text-align: center; color: var(--muted); }

/* ---- Badges ------------------------------------------------------------------ */
.badge { display: inline-block; padding: 2px 9px; border-radius: 999px; font-size: 11.5px; font-weight: 600; white-space: nowrap; }
.badge.ok { background: var(--ok-bg); color: var(--ok); }
.badge.off { background: var(--err-bg); color: var(--err); }
.badge.warn { background: var(--warn-bg); color: var(--warn); }
.badge.muted { background: #edf2f5; color: var(--muted); }
.badge.blue { background: var(--brand-50); color: var(--brand-700); }
.dot { display: inline-block; width: 9px; height: 9px; border-radius: 50%; margin-right: 6px; background: #b8c6ce; }
.dot.on { background: #22a35a; box-shadow: 0 0 0 3px rgba(34, 163, 90, .15); }
.dot.off { background: #c9372c; }

/* ---- Buttons -------------------------------------------------------------- */
.btn { display: inline-flex; align-items: center; gap: 7px; border: 1px solid transparent; border-radius: 8px; padding: 8px 14px; font: inherit; font-weight: 600; font-size: 13.5px; cursor: pointer; line-height: 1.2; white-space: nowrap; transition: background .12s, border-color .12s, color .12s; }
.btn:hover { text-decoration: none; }
.btn .ico { width: 16px; height: 16px; }
.btn-primary { background: var(--brand); color: #fff; }
.btn-primary:hover { background: var(--brand-700); color: #fff; }
.btn-secondary { background: #fff; color: var(--brand-700); border-color: var(--brand-100); }
.btn-secondary:hover { border-color: var(--brand); color: var(--brand-800); }
.btn-danger { background: #fff; color: var(--err); border-color: #f3c7c2; }
.btn-danger:hover { background: var(--err); color: #fff; border-color: var(--err); }
.btn-ghost { background: transparent; color: var(--brand-700); padding: 6px 8px; }
.btn-ghost:hover { background: var(--brand-50); }
.btn-sm { padding: 5px 9px; font-size: 12.5px; }
.btn-apply { background: #fff5d6; color: #7a4a00; border-color: #f3d27a; animation: pulse 2s infinite; }
.btn-apply:hover { background: #ffe9a8; color: #5c3700; }
.btn-apply.clean { background: #fff; color: var(--brand-700); border-color: var(--brand-100); animation: none; }
@keyframes pulse { 0%, 100% { box-shadow: 0 0 0 0 rgba(243, 182, 54, .45); } 50% { box-shadow: 0 0 0 6px rgba(243, 182, 54, 0); } }
form.inline { display: inline; }

/* ---- Forms -------------------------------------------------------------------- */
.form-grid { display: grid; grid-template-columns: repeat(6, minmax(0, 1fr)); gap: 14px 18px; }
.form-grid .f-full { grid-column: span 6; }
.form-grid .f-half { grid-column: span 3; }
.form-grid .f-third { grid-column: span 2; }
.field label { display: block; font-weight: 600; font-size: 13px; margin-bottom: 5px; color: #23414f; }
.field .req { color: var(--err); margin-left: 2px; }
.field .help { font-size: 12px; color: var(--muted); margin-top: 4px; }
.field .error { font-size: 12.5px; color: var(--err); margin-top: 4px; font-weight: 600; }
.field.has-error input, .field.has-error select, .field.has-error textarea { border-color: var(--err); background: #fffafa; }
input[type=text], input[type=email], input[type=password], input[type=number], input[type=date], input[type=time], input[type=search], input[type=file], select, textarea {
  width: 100%; font: inherit; color: var(--ink); background: #fff; border: 1px solid #c9dbe4; border-radius: 8px; padding: 8px 10px; line-height: 1.35;
}
input:focus, select:focus, textarea:focus { outline: none; border-color: var(--brand); box-shadow: 0 0 0 3px rgba(0, 131, 168, .15); }
input[readonly] { background: #f3f7f9; color: var(--muted); }
textarea { min-height: 80px; resize: vertical; }
.check { display: flex; align-items: flex-start; gap: 9px; font-weight: 500 !important; cursor: pointer; padding: 4px 0; }
.check input { margin-top: 3px; accent-color: var(--brand); width: 16px; height: 16px; }
.inline-checks { display: flex; flex-wrap: wrap; gap: 6px 16px; }
.inline-checks label { display: flex; align-items: center; gap: 6px; font-weight: 500; cursor: pointer; }
.inline-checks input { accent-color: var(--brand); }
.input-group { display: flex; gap: 6px; }
.input-group input { flex: 1; }
.form-actions { display: flex; gap: 10px; justify-content: flex-end; padding-top: 16px; border-top: 1px solid var(--line); margin-top: 20px; flex-wrap: wrap; }
.form-actions .left { margin-right: auto; }
.filters { display: flex; flex-wrap: wrap; gap: 10px; align-items: flex-end; }
.filters .field { min-width: 140px; }
.filters .field label { font-size: 12px; }
.search-box { display: flex; gap: 8px; }
.search-box input { min-width: 260px; }

/* Tabs */
.tabs { display: flex; gap: 2px; border-bottom: 1px solid var(--line); margin: -4px 0 18px; flex-wrap: wrap; }
.tabs button { background: none; border: 0; border-bottom: 2px solid transparent; padding: 9px 14px; font: inherit; font-weight: 600; color: var(--muted); cursor: pointer; }
.tabs button:hover { color: var(--brand-700); }
.tabs button.active { color: var(--brand); border-bottom-color: var(--brand); }
.tabs button.has-error { color: var(--err); }
.tab-panel { display: none; }
.tab-panel.active { display: block; }

/* Repeater */
.repeater { border: 1px solid var(--line); border-radius: 10px; overflow: hidden; }
.repeater table { width: 100%; border-collapse: collapse; }
.repeater th { background: var(--brand-50); font-size: 12px; text-align: left; padding: 8px 10px; color: var(--brand-800); }
.repeater td { padding: 6px 8px; border-top: 1px solid #edf3f6; vertical-align: top; }
.repeater td.ctl { width: 1%; white-space: nowrap; }
.repeater .footer-row { padding: 10px; background: #fbfdfe; border-top: 1px solid var(--line); display: flex; gap: 8px; flex-wrap: wrap; align-items: center; }
.rule-card { border: 1px solid var(--line); border-radius: 10px; padding: 12px; margin: 8px; background: #fff; }
.rule-card .rule-grid { display: grid; grid-template-columns: 150px 1fr 110px 110px; gap: 10px; align-items: end; }
.rule-card .rule-grid2 { display: grid; grid-template-columns: 1fr 120px 160px; gap: 10px; margin-top: 10px; align-items: end; }
.rule-card .rule-head { display: flex; justify-content: space-between; align-items: center; margin-bottom: 8px; }

/* Members (chips) */
.members { border: 1px solid #c9dbe4; border-radius: 8px; padding: 8px; background: #fff; }
.members .chips { display: flex; flex-wrap: wrap; gap: 6px; min-height: 30px; margin-bottom: 8px; }
.chip { display: inline-flex; align-items: center; gap: 6px; background: var(--brand-50); border: 1px solid var(--brand-100); color: var(--brand-800); border-radius: 999px; padding: 3px 4px 3px 10px; font-size: 12.5px; }
.chip.ext-num { background: #f5f1ff; border-color: #ddd3fb; color: #4b2f8f; }
.chip button { border: 0; background: rgba(0, 0, 0, .06); color: inherit; border-radius: 50%; width: 20px; height: 20px; cursor: pointer; line-height: 1; padding: 0; }
.chip button:hover { background: rgba(0, 0, 0, .15); }
.members .adders { display: flex; gap: 6px; flex-wrap: wrap; }
.members .adders select, .members .adders input { width: auto; flex: 1; min-width: 160px; }

/* Codecs */
.codec-list { display: flex; flex-wrap: wrap; gap: 6px; }
.codec-item { display: inline-flex; align-items: center; gap: 6px; border: 1px solid #c9dbe4; border-radius: 8px; padding: 5px 8px; background: #fff; cursor: grab; user-select: none; }
.codec-item.on { border-color: var(--brand); background: var(--brand-50); }
.codec-item input { accent-color: var(--brand); }
.codec-item .mv { border: 0; background: none; color: var(--muted); cursor: pointer; padding: 0 2px; }

/* ---- Alerts ------------------------------------------------------------------- */
.flash-stack { display: flex; flex-direction: column; gap: 8px; margin-bottom: 16px; }
.alert { display: flex; gap: 10px; align-items: flex-start; padding: 11px 14px; border-radius: 10px; border: 1px solid; font-weight: 500; }
.alert .ico { margin-top: 1px; }
.alert.success { background: var(--ok-bg); border-color: #b9e3c7; color: #14532d; }
.alert.error { background: var(--err-bg); border-color: #f5c2bc; color: #7a1a12; }
.alert.warning { background: var(--warn-bg); border-color: #f3dca4; color: #6b3d00; }
.alert.info { background: var(--brand-50); border-color: var(--brand-100); color: var(--brand-800); }
.alert .close { margin-left: auto; background: none; border: 0; cursor: pointer; color: inherit; opacity: .6; }
.dirty-banner { display: flex; align-items: center; gap: 12px; background: #fff8e6; border: 1px solid #f3d98e; color: #6b4500; border-radius: 10px; padding: 10px 14px; margin-bottom: 16px; }
.dirty-banner .spacer { flex: 1; }

/* ---- Pagination --------------------------------------------------------------- */
.pager { display: flex; gap: 4px; justify-content: flex-end; padding: 12px 16px; border-top: 1px solid var(--line); align-items: center; }
.pager a, .pager span { padding: 4px 10px; border-radius: 6px; border: 1px solid var(--line); color: var(--brand-700); background: #fff; font-size: 13px; }
.pager span.cur { background: var(--brand); color: #fff; border-color: var(--brand); }
.pager .info { border: 0; background: none; color: var(--muted); margin-right: auto; }

/* ---- Console / logs --------------------------------------------------------- */
.console { background: #0b2833; color: #d6f1fa; border-radius: 10px; padding: 14px; font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace; font-size: 12.5px; min-height: 340px; max-height: 62vh; overflow: auto; white-space: pre-wrap; word-break: break-word; }
.console .cmd { color: #7fe0ff; }
pre.log { margin: 0; background: #0b2833; color: #d6f1fa; padding: 14px; font-size: 12px; max-height: 68vh; overflow: auto; white-space: pre-wrap; word-break: break-all; border-radius: 0 0 10px 10px; }
pre.conf { background: #f7fbfd; border: 1px solid var(--line); padding: 12px; border-radius: 8px; max-height: 520px; overflow: auto; font-size: 12px; }

/* ---- Guest (login) ------------------------------------------------------------ */
body.guest { min-height: 100vh; display: grid; place-items: center; background: radial-gradient(1200px 600px at 10% 0%, #d8eef6 0%, transparent 60%), linear-gradient(160deg, #f3f9fc 0%, #e3f1f7 100%); padding: 24px; }
.login-card { width: 100%; max-width: 420px; background: #fff; border: 1px solid var(--line); border-radius: 16px; box-shadow: 0 10px 40px rgba(6, 75, 96, .12); padding: 34px 34px 26px; }
.login-card .logo { display: flex; justify-content: center; padding: 6px 0 18px; background: #fff; }
.login-card .logo img { max-width: 300px; width: 100%; height: auto; background: #fff; }
.login-card h1 { text-align: center; font-size: 18px; margin-bottom: 4px; }
.login-card .sub { text-align: center; color: var(--muted); margin-bottom: 22px; }
.login-card .field { margin-bottom: 14px; }
.login-card .btn { width: 100%; justify-content: center; padding: 11px; font-size: 14.5px; }
.login-foot { text-align: center; color: var(--muted); font-size: 12px; margin-top: 18px; }

/* ---- Misc ---------------------------------------------------------------------- */
.kv { display: grid; grid-template-columns: 200px 1fr; gap: 8px 14px; }
.kv dt { color: var(--muted); }
.kv dd { margin: 0; font-weight: 600; }
.meter { height: 8px; background: #e5eff4; border-radius: 99px; overflow: hidden; margin-top: 6px; }
.meter i { display: block; height: 100%; background: linear-gradient(90deg, var(--brand), var(--cyan)); border-radius: 99px; }
.sip-box { background: var(--brand-50); border: 1px dashed var(--brand-100); border-radius: 10px; padding: 14px; }
.live-pill { display: inline-flex; align-items: center; gap: 6px; font-size: 12px; color: var(--muted); }
.live-pill .dot { margin: 0; }
details.help-box summary { cursor: pointer; color: var(--brand-700); font-weight: 600; }

@media (max-width: 1100px) {
  .grid.cols-4 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .grid.cols-3 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (max-width: 860px) {
  .menu-toggle { display: inline-flex; }
  .brand { width: auto; }
  .brand .product, .user-menu .who { display: none; }
  .sidebar { transform: translateX(-100%); transition: transform .2s; box-shadow: 4px 0 24px rgba(0, 0, 0, .2); }
  body.nav-open .sidebar { transform: none; }
  .main { margin-left: 0; padding: calc(var(--topbar) + 16px) 14px 30px; }
  .grid.cols-2, .grid.cols-3, .grid.cols-4 { grid-template-columns: 1fr; }
  .form-grid .f-half, .form-grid .f-third { grid-column: span 6; }
  .tenant-switch select { min-width: 140px; }
  .rule-card .rule-grid, .rule-card .rule-grid2 { grid-template-columns: 1fr 1fr; }
  .kv { grid-template-columns: 1fr; }
}

/* ---- Settings sub navigation ------------------------------------------------ */
.tabs.subnav { margin: 0 0 18px; background: #fff; border: 1px solid var(--line); border-radius: var(--radius); padding: 0 8px; box-shadow: var(--shadow); }
.tabs.subnav a { display: inline-block; padding: 11px 13px; font-weight: 600; color: var(--muted); border-bottom: 2px solid transparent; margin-bottom: -1px; }
.tabs.subnav a:hover { color: var(--brand-700); text-decoration: none; }
.tabs.subnav a.active { color: var(--brand); border-bottom-color: var(--brand); }
textarea[name$="_custom"], textarea[name^="pjsip_custom"], textarea[name="iax_custom_general"] { font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace; font-size: 12.5px; }

/* v1.1: login background, settings, firewall */
.alert > div { white-space: pre-line; }
body.guest.has-bg { background-color: #0b2b38; background-size: cover; background-position: center; background-repeat: no-repeat; position: relative; }
body.guest.has-bg::before { content: ""; position: fixed; inset: 0; pointer-events: none; }
body.guest.overlay-light::before { background: rgba(255, 255, 255, .45); }
body.guest.overlay-dark::before { background: rgba(5, 20, 28, .5); }
body.guest.overlay-brand::before { background: linear-gradient(160deg, rgba(0, 131, 168, .55), rgba(6, 60, 80, .65)); }
body.guest.has-bg .login-card { position: relative; box-shadow: 0 18px 60px rgba(0, 0, 0, .28); }
body.guest.has-bg .login-foot { color: var(--muted); }
.login-preview { position: relative; border-radius: 12px; border: 1px solid var(--line); overflow: hidden; padding: 28px 18px; display: grid; place-items: center; min-height: 360px;
  background: radial-gradient(600px 300px at 10% 0%, #d8eef6 0%, transparent 60%), linear-gradient(160deg, #f3f9fc 0%, #e3f1f7 100%); }
.login-preview.has-bg { background-size: cover; background-position: center; }
.login-preview.has-bg::before { content: ""; position: absolute; inset: 0; }
.login-preview.overlay-light::before { background: rgba(255, 255, 255, .45); }
.login-preview.overlay-dark::before { background: rgba(5, 20, 28, .5); }
.login-preview.overlay-brand::before { background: linear-gradient(160deg, rgba(0, 131, 168, .55), rgba(6, 60, 80, .65)); }
.login-preview .login-card { position: relative; transform: scale(.82); transform-origin: center; margin: -30px 0; pointer-events: none; }
.login-preview .login-card .btn { display: flex; }
details.card > summary { cursor: pointer; list-style: revert; }
.busy-note { margin-top: 14px; }
a.card.stat { color: inherit; text-decoration: none; }
a.card.stat:hover { border-color: var(--brand-100); }
.card > .field { margin-bottom: 14px; }
.card > .field + .form-grid { margin-top: 4px; }
.role-help { margin: 6px 0 0; padding-left: 16px; }
.role-help li { margin: 2px 0; }

/* ---- Backup ------------------------------------------------------------------------ */
.card-title { display: flex; align-items: center; justify-content: space-between; gap: 12px; flex-wrap: wrap; padding: 14px 16px; border-bottom: 1px solid var(--line); }
.card-title h3 { margin: 0; }
.job-panel { margin-bottom: 18px; border-left: 4px solid var(--brand); }
.job-panel.done { border-left-color: var(--ok); }
.job-panel.error { border-left-color: var(--err); }
.job-head { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; }
.job-step { margin: 8px 0; color: var(--brand-800); }
.progress { height: 8px; background: var(--brand-50); border-radius: 999px; overflow: hidden; margin: 6px 0 10px; }
.progress span { display: block; height: 100%; background: var(--brand); border-radius: 999px; transition: width .6s ease; }
.progress.indeterminate span { width: 35% !important; animation: cx-indeterminate 1.4s ease-in-out infinite; }
@keyframes cx-indeterminate { 0% { margin-left: -35%; } 100% { margin-left: 100%; } }
.restore-summary dd .badge { margin-right: 4px; }
.radio-cards { display: grid; gap: 10px; }
.radio-cards label { display: flex; gap: 10px; align-items: flex-start; padding: 12px 14px; border: 1px solid var(--line); border-radius: 10px; cursor: pointer; font-weight: 500; }
.radio-cards label:has(input:checked) { border-color: var(--brand); background: var(--brand-50); }
.radio-cards input { margin-top: 3px; accent-color: var(--brand); }
.maint { max-width: 560px; margin: 12vh auto; background: #fff; border: 1px solid var(--line); border-radius: 14px; padding: 28px; text-align: center; }
.maint img { height: 54px; margin-bottom: 14px; }
