/* ============================================================
   PRODUCTADVANCE — WHMCS CLIENT CONSOLE THEME
   Child theme of twenty-one (WHMCS 8.13.6).
   Loaded automatically by WHMCS after theme.min.css via the
   parent's {assetExists file="custom.css"} block, so equal
   specificity wins by source order. Tactics used here:
     1. match Bootstrap's own selector where possible
     2. prefix `body.pa` (guaranteed by our header.tpl) for +1
     3. !important ONLY for color/background/border on stubborn
        utilities — never for layout
   Sections:
     00 FONT-FACE      01 TOKENS         02 BASE
     03 BOOTSTRAP DARK 04 WHMCS CHROME   05 PA COMPONENTS
     06 PAGES          07 AIRLOCK        08 RESPONSIVE + PRINT
     09-13 LIVE SWEEPS 01b LIGHT TOKENS  14 MODE TOGGLE UI
   Token trap carried over from the site on purpose: --red is
   the PRIMARY ELECTRIC BLUE (#2f7bff), --flame is CYAN. The
   names are kept identical to styles.css so values can be
   copy-synced verbatim between site and portal.
   ============================================================ */

/* ============================================================
   00 FONT-FACE — self-hosted, same woff2 files as the site
   ============================================================ */
@font-face {
  font-family: "Bespoke Stencil";
  src: url("../fonts/bespoke-stencil-500.woff2") format("woff2");
  font-weight: 500; font-style: normal; font-display: swap;
}
@font-face {
  font-family: "Bespoke Stencil";
  src: url("../fonts/bespoke-stencil-700.woff2") format("woff2");
  font-weight: 700; font-style: normal; font-display: swap;
}
@font-face {
  font-family: "Switzer";
  src: url("../fonts/switzer-400.woff2") format("woff2");
  font-weight: 400; font-style: normal; font-display: swap;
}
@font-face {
  font-family: "Switzer";
  src: url("../fonts/switzer-500.woff2") format("woff2");
  font-weight: 500; font-style: normal; font-display: swap;
}
@font-face {
  font-family: "Switzer";
  src: url("../fonts/switzer-600.woff2") format("woff2");
  font-weight: 600; font-style: normal; font-display: swap;
}

/* ============================================================
   01 TOKENS — verbatim from the site styles.css :root, plus
   portal-only status + surface tokens
   ============================================================ */
:root {
  --bg: #000;
  --bg-2: #020104;
  --panel: #04070e;
  --line: rgba(255, 255, 255, 0.09);
  --line-soft: rgba(255, 255, 255, 0.055);
  --ink: #e8e6e1;
  --ink-dim: #d3cdc3;
  --red: #2f7bff;        /* primary electric blue (legacy name) */
  --red-deep: #1c4fd6;
  --flame: #3ceaff;      /* cyan accent */
  --mono: ui-monospace, "SF Mono", SFMono-Regular, Menlo, Consolas, monospace;
  --disp: "Bespoke Stencil", Impact, sans-serif;
  --body: "Switzer", -apple-system, "Segoe UI", sans-serif;
  --rad: 10px;
  --rad-sm: 6px;
  /* portal-only */
  --good: #45e08a;
  --warn: #ff8a3c;
  --crit: #ff6b6e;
  --panel-glass: rgba(6, 10, 18, 0.72);
  --panel-solid: rgba(11, 13, 19, 0.94);
  --tint: rgba(255, 255, 255, 0.02);
  --input-fill: rgba(255, 255, 255, 0.03);
  --input-focus-fill: rgba(47, 123, 255, 0.045);
  --blue-wash: rgba(47, 123, 255, 0.07);
  --bracket: rgba(60, 234, 255, 0.55);
  /* mode tokens: every value below is byte-identical to the
     literal it replaced; light mode overrides them in 01b */
  --red-rgb: 47, 123, 255;
  --good-rgb: 69, 224, 138;
  --warn-rgb: 255, 138, 60;
  --crit-rgb: 255, 107, 110;
  --ink-rgb: 232, 230, 225;
  --ink-dim-rgb: 211, 205, 195;
  --wash-rgb: 255, 255, 255;
  --surface-opaque: #0b0d13;
  --surface-deep: #050608;
  --menu-bg: #101218;
  --dropdown-bg: rgba(15, 15, 16, 0.96);
  --console-bar-bg: rgba(5, 6, 10, 0.82);
  --mobile-nav-bg: rgba(11, 11, 12, 0.96);
  --dial-hub: rgba(6, 10, 18, 0.96);
  --airlock-fill: #0a0d14;
  --tool-fill: rgba(0, 0, 0, 0.36);
  --island: #fff;
  --on-accent: #06090f;
  --on-flame: #14100a;
  --on-good: #05130b;
  --flame-hi: #63f0ff;
  --good-hi: #63e9a0;
  --ink-faint: rgba(211, 205, 195, 0.35);
  --ink-placeholder: rgba(211, 205, 195, 0.45);
  --well: rgba(0, 0, 0, 0.35);
  --scrim: rgba(0, 0, 0, 0.82);
  --shadow-lg: 0 30px 80px rgba(0, 0, 0, 0.6);
  --shadow-md: 0 30px 70px rgba(0, 0, 0, 0.55);
  --shadow-menu: 0 30px 70px rgba(0, 0, 0, 0.65);
  --dial-shadow: 0 0 22px rgba(0, 0, 0, 0.4);
  --blue-glow: 0 0 12px rgba(47, 123, 255, 0.5);
  --flame-glow: 0 6px 30px rgba(60, 234, 255, 0.35);
  --good-glow: 0 6px 30px rgba(69, 224, 138, 0.35);
  --airlock-sheet: linear-gradient(165deg, rgba(47, 123, 255, 0.5), rgba(255, 255, 255, 0.12) 40%, rgba(60, 234, 255, 0.3));
  --airlock-glow: radial-gradient(820px 480px at 16% 0%, rgba(47, 123, 255, 0.09), transparent 65%), radial-gradient(700px 420px at 84% 100%, rgba(60, 234, 255, 0.05), transparent 65%);
  --selection: rgba(47, 123, 255, 0.35);
  --grain-opacity: 0.045;
  --grain-blend: normal;
  --stars-opacity: 0.5;
  --backdrop-opacity: 0.75;
  --scheme: dark;
}

/* ============================================================
   01b LIGHT TOKENS — "Day Ops". Dark above is the default; the
   toggle sets data-theme="light" on <html> (pre-paint script in
   includes/head.tpl, handler in js/pa.js). Palette: "Spec
   Sheet" — bone paper, near-black ink, deepened blue/cyan.
   Every color in this file is a var(), so this block IS the
   light theme; never add light override rules elsewhere.
   ============================================================ */
:root[data-theme="light"] {
  --bg: #f2efe9;
  --bg-2: #eae6de;
  --panel: #faf8f4;
  --line: rgba(20, 24, 32, 0.14);
  --line-soft: rgba(20, 24, 32, 0.085);
  --ink: #16181c;
  --ink-dim: #5a5e68;
  --red: #1a5fe0;
  --red-deep: #1243a8;
  --flame: #00718a;
  --good: #0f7a45;
  --warn: #a84a08;
  --crit: #c4262b;
  --panel-glass: rgba(255, 253, 250, 0.6);
  --panel-solid: rgba(252, 251, 248, 0.97);
  --tint: rgba(20, 24, 32, 0.035);
  --input-fill: rgba(255, 255, 255, 0.6);
  --input-focus-fill: rgba(236, 242, 255, 0.92);
  --blue-wash: rgba(26, 95, 224, 0.08);
  --bracket: rgba(0, 113, 138, 0.6);
  --red-rgb: 26, 95, 224;
  --good-rgb: 15, 122, 69;
  --warn-rgb: 168, 74, 8;
  --crit-rgb: 196, 38, 43;
  --ink-rgb: 22, 24, 28;
  --ink-dim-rgb: 40, 44, 52;
  --wash-rgb: 20, 24, 32;
  --surface-opaque: #fbfaf7;
  --surface-deep: #f2efe9;
  --menu-bg: #fbfaf7;
  --dropdown-bg: rgba(251, 250, 247, 0.97);
  --console-bar-bg: rgba(246, 244, 239, 0.82);
  --mobile-nav-bg: rgba(250, 248, 244, 0.97);
  --dial-hub: rgba(250, 248, 244, 0.97);
  --airlock-fill: #faf8f4;
  --tool-fill: rgba(255, 255, 255, 0.5);
  --island: #fff;
  --on-accent: #fff;
  --on-flame: #fff;
  --on-good: #fff;
  --flame-hi: #00809c;
  --good-hi: #0c6b3c;
  --ink-faint: rgba(40, 44, 52, 0.4);
  --ink-placeholder: rgba(40, 44, 52, 0.58);
  --well: rgba(20, 24, 32, 0.06);
  --scrim: rgba(28, 32, 40, 0.6);
  --shadow-lg: 0 24px 60px rgba(28, 32, 40, 0.16);
  --shadow-md: 0 20px 50px rgba(28, 32, 40, 0.14);
  --shadow-menu: 0 20px 50px rgba(28, 32, 40, 0.16);
  --dial-shadow: 0 0 22px rgba(28, 32, 40, 0.12);
  --blue-glow: 0 0 12px rgba(26, 95, 224, 0.3);
  --flame-glow: 0 6px 22px rgba(0, 113, 138, 0.22);
  --good-glow: 0 6px 22px rgba(15, 122, 69, 0.22);
  --airlock-sheet: linear-gradient(165deg, rgba(26, 95, 224, 0.55), rgba(20, 24, 32, 0.16) 40%, rgba(0, 113, 138, 0.4));
  --airlock-glow: radial-gradient(820px 480px at 16% 0%, rgba(26, 95, 224, 0.1), transparent 65%), radial-gradient(700px 420px at 84% 100%, rgba(0, 113, 138, 0.07), transparent 65%);
  --selection: rgba(26, 95, 224, 0.22);
  --grain-opacity: 0.06;
  --grain-blend: multiply;
  --stars-opacity: 0.18;
  --backdrop-opacity: 0.5;
  --scheme: light;
}

/* ============================================================
   02 BASE
   ============================================================ */
html { background: var(--bg); }
body.pa {
  background: var(--bg) !important;
  color: var(--ink);
  font-family: var(--body);
  font-weight: 400;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}
/* twenty-one paints .primary-bg-color light — repaint */
body.pa.primary-bg-color { background-color: var(--bg) !important; }

/* film grain, same feTurbulence idiom as the site body::after.
   z-index 2 sits above page paint, far below BS modals (1050). */
body.pa::after {
  content: "";
  position: fixed; inset: -50%;
  z-index: 2; pointer-events: none;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='300' height='300'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.65' numOctaves='2' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
  opacity: var(--grain-opacity);
  mix-blend-mode: var(--grain-blend);
}

body.pa ::selection { background: var(--selection); color: var(--ink); }

body.pa a { color: var(--red); }
body.pa a:hover { color: var(--ink); text-decoration: none; }

body.pa h1, body.pa h2, body.pa h3,
body.pa h4, body.pa h5, body.pa h6,
body.pa .h1, body.pa .h2, body.pa .h3,
body.pa .h4, body.pa .h5, body.pa .h6 {
  font-family: var(--disp);
  font-weight: 700;
  text-transform: uppercase;
  color: var(--ink);
  letter-spacing: 0.01em;
}

body.pa hr {
  border: 0; height: 1px;
  background: repeating-linear-gradient(90deg, var(--line) 0 6px, transparent 6px 14px);
}

/* focus discipline, house rule */
body.pa a:focus-visible,
body.pa button:focus-visible,
body.pa input:focus-visible,
body.pa select:focus-visible,
body.pa textarea:focus-visible,
body.pa [tabindex]:focus-visible {
  outline: 2px solid var(--red);
  outline-offset: 2px;
  box-shadow: none;
}

/* thin console scrollbars */
body.pa {
  scrollbar-width: thin;
  scrollbar-color: rgba(var(--red-rgb), 0.45) rgba(var(--wash-rgb), 0.04);
}
body.pa ::-webkit-scrollbar { width: 8px; height: 8px; }
body.pa ::-webkit-scrollbar-track { background: rgba(var(--wash-rgb), 0.04); }
body.pa ::-webkit-scrollbar-thumb { background: rgba(var(--red-rgb), 0.45); border-radius: 4px; }

/* motion kill-switch: pa.js mirrors prefers-reduced-motion to
   html.no-motion; both roads lead to the same static state */
@media (prefers-reduced-motion: reduce) {
  body.pa *, body.pa *::before, body.pa *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }
}
html.no-motion body.pa *,
html.no-motion body.pa *::before,
html.no-motion body.pa *::after {
  animation: none !important;
  transition: none !important;
}

/* ============================================================
   03 BOOTSTRAP DARK — component-by-component 4.5.3 reskin
   ============================================================ */

/* --- utilities that fight the dark ground --- */
body.pa .bg-white { background-color: var(--panel) !important; }
body.pa .bg-light { background-color: var(--tint) !important; }
body.pa .text-dark { color: var(--ink) !important; }
body.pa .text-muted { color: var(--ink-dim) !important; }
body.pa .text-black-50 { color: rgba(var(--ink-rgb), 0.5) !important; }
body.pa .border { border-color: var(--line) !important; }

/* --- cards → console panels --- */
body.pa .card {
  background: var(--panel-glass);
  border: 1px solid var(--line);
  border-radius: var(--rad);
  color: var(--ink);
}
body.pa .card-header {
  background: transparent;
  border-bottom: 1px solid var(--line-soft);
  color: var(--ink);
}
body.pa .card-footer {
  background: rgba(var(--wash-rgb), 0.015);
  border-top: 1px solid var(--line-soft);
  color: var(--ink-dim);
}
body.pa .card-header .card-title,
body.pa .card-header h3 {
  font-family: var(--mono);
  font-size: 11.5px;
  font-weight: 600;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--ink);
}
body.pa .card-header .card-title::before,
body.pa .card-header h3.card-title::before {
  content: "// ";
  color: var(--red);
}

/* --- list groups --- */
body.pa .list-group-item {
  background: transparent;
  border-color: var(--line-soft);
  color: var(--ink-dim);
}
body.pa a.list-group-item:hover,
body.pa .list-group-item-action:hover {
  background: rgba(var(--wash-rgb), 0.04);
  color: var(--ink);
}
body.pa .list-group-item.active {
  background: var(--blue-wash);
  border-color: var(--line-soft);
  border-left: 2px solid var(--red);
  color: var(--ink);
}

/* --- modals → console dialogs --- */
body.pa .modal-content {
  background: var(--panel-solid);
  border: 1px solid var(--line);
  border-radius: var(--rad);
  color: var(--ink);
  position: relative;
  box-shadow: var(--shadow-lg);
}
/* signature 2px rule across the dialog head, Control Room idiom */
body.pa .modal-content::before {
  content: "";
  position: absolute; top: -1px; left: -1px; right: 30%;
  height: 2px;
  background: linear-gradient(90deg, var(--red) 0%, var(--red-deep) 55%, transparent 100%);
  border-top-left-radius: var(--rad);
}
body.pa .modal-header {
  border-bottom: 1px solid var(--line-soft);
}
body.pa .modal-header .modal-title {
  font-family: var(--mono);
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 0.2em;
  text-transform: uppercase;
}
body.pa .modal-footer { border-top: 1px solid var(--line-soft); }
body.pa .modal-backdrop.show { opacity: var(--backdrop-opacity); }
body.pa .close { color: var(--ink); text-shadow: none; opacity: 0.6; }
body.pa .close:hover { color: var(--flame); opacity: 1; }

/* --- dropdowns --- */
body.pa .dropdown-menu {
  background: var(--dropdown-bg);
  border: 1px solid var(--line-soft);
  border-radius: var(--rad);
  box-shadow: var(--shadow-md);
  color: var(--ink);
}
body.pa .dropdown-item { color: var(--ink-dim); }
body.pa .dropdown-item:hover,
body.pa .dropdown-item:focus {
  background: rgba(var(--wash-rgb), 0.05);
  color: var(--ink);
}
body.pa .dropdown-divider { border-color: var(--line-soft); }

/* --- alerts → chip-language banners --- */
body.pa .alert {
  border-radius: var(--rad-sm);
  border: 1px solid var(--pac, var(--line));
  background: var(--tint);
  color: var(--ink);
  border-left-width: 2px;
}
body.pa .alert a { color: inherit; text-decoration: underline; }
body.pa .alert-success { --pac: var(--good); background: rgba(var(--good-rgb), 0.06); }
body.pa .alert-warning { --pac: var(--warn); background: rgba(var(--warn-rgb), 0.06); }
body.pa .alert-danger  { --pac: var(--crit); background: rgba(var(--crit-rgb), 0.06); }
body.pa .alert-info    { --pac: var(--red);  background: rgba(var(--red-rgb), 0.06); }

/* --- tables → hairline instrument readouts --- */
body.pa .table {
  color: var(--ink-dim);
  border-color: var(--line-soft);
}
body.pa .table th,
body.pa .table td {
  border-color: var(--line-soft);
  vertical-align: middle;
}
body.pa .table thead th {
  font-family: var(--mono);
  font-size: 10.5px;
  font-weight: 600;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--ink);
  background: rgba(var(--wash-rgb), 0.03);
  border-bottom: 1px solid var(--line);
}
body.pa .table-striped tbody tr:nth-of-type(odd) { background: rgba(var(--wash-rgb), 0.018); }
body.pa .table-hover tbody tr:hover { background: var(--blue-wash); color: var(--ink); }
body.pa .table a { color: var(--red); }
body.pa .table a:hover { color: var(--ink); }

/* DataTables chrome */
body.pa .dataTables_wrapper,
body.pa .dataTables_info,
body.pa .dataTables_filter label,
body.pa .dataTables_paginate {
  color: var(--ink-dim);
  font-family: var(--mono);
  font-size: 11.5px;
  letter-spacing: 0.06em;
}
body.pa .dataTables_filter input {
  background: var(--input-fill);
  border: 1px solid var(--line);
  border-radius: var(--rad-sm);
  color: var(--ink);
}

/* --- pagination --- */
body.pa .page-link {
  background: transparent;
  border-color: var(--line-soft);
  color: var(--ink-dim);
  font-family: var(--mono);
  font-size: 12px;
}
body.pa .page-link:hover {
  background: var(--blue-wash);
  border-color: var(--red);
  color: var(--ink);
}
body.pa .page-item.active .page-link {
  background: var(--red);
  border-color: var(--red);
  color: var(--on-accent);
}
body.pa .page-item.disabled .page-link {
  background: transparent;
  border-color: var(--line-soft);
  color: var(--ink-faint);
}

/* --- tabs & pills --- */
body.pa .nav-tabs { border-bottom: 1px solid var(--line-soft); }
body.pa .nav-tabs .nav-link {
  font-family: var(--mono);
  font-size: 11px;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--ink-dim);
  border: 0;
  border-bottom: 2px solid transparent;
  border-radius: 0;
}
body.pa .nav-tabs .nav-link:hover { color: var(--ink); border-color: transparent; }
body.pa .nav-tabs .nav-link.active {
  background: transparent;
  color: var(--ink);
  border-bottom: 2px solid var(--red);
}
body.pa .nav-pills .nav-link {
  font-family: var(--mono);
  font-size: 11px;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--ink-dim);
  border-radius: var(--rad-sm);
}
body.pa .nav-pills .nav-link.active { background: var(--blue-wash); color: var(--ink); box-shadow: inset 0 0 0 1px var(--red); }

/* --- progress --- */
body.pa .progress {
  background: rgba(var(--wash-rgb), 0.08);
  border-radius: 2px;
  height: 6px;
}
body.pa .progress-bar { background: var(--red); box-shadow: var(--blue-glow); }
body.pa .progress-bar.bg-success { background: var(--good) !important; }
body.pa .progress-bar.bg-warning { background: var(--warn) !important; }
body.pa .progress-bar.bg-danger  { background: var(--crit) !important; }

/* --- badges --- */
body.pa .badge {
  font-family: var(--mono);
  font-weight: 600;
  letter-spacing: 0.1em;
  border-radius: var(--rad-sm);
}
body.pa .badge-info,
body.pa .badge-primary { background: var(--red); color: var(--on-accent); }
body.pa .badge-success { background: transparent; color: var(--good); border: 1px solid var(--good); }
body.pa .badge-warning { background: transparent; color: var(--warn); border: 1px solid var(--warn); }
body.pa .badge-danger  { background: transparent; color: var(--crit); border: 1px solid var(--crit); }
body.pa .badge-secondary,
body.pa .badge-default { background: transparent; color: var(--ink-dim); border: 1px solid var(--line); }

/* --- forms → boxed console inputs --- */
body.pa .form-control,
body.pa .custom-select,
body.pa select.form-control,
body.pa textarea.form-control {
  background: var(--input-fill);
  border: 1px solid var(--line);
  border-radius: var(--rad-sm);
  color: var(--ink);
  font-family: var(--body);
  transition: border-color 0.25s, background 0.25s;
  color-scheme: var(--scheme);
}
body.pa .form-control:focus,
body.pa .custom-select:focus {
  background: var(--input-focus-fill);
  border-color: var(--red);
  color: var(--ink);
  box-shadow: none;
}
body.pa .form-control::placeholder { color: var(--ink-placeholder); }
body.pa .form-control:disabled,
body.pa .form-control[readonly] {
  background: rgba(var(--wash-rgb), 0.015);
  color: var(--ink-dim);
  opacity: 0.7;
}
body.pa select.form-control option,
body.pa .custom-select option { background: var(--surface-opaque); color: var(--ink); }

body.pa label,
body.pa .form-control-label,
body.pa .col-form-label {
  font-family: var(--mono);
  font-size: 10.5px;
  font-weight: 600;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--ink-dim);
}
body.pa .form-check-input,
body.pa input[type="checkbox"],
body.pa input[type="radio"] { accent-color: var(--red); }
body.pa .custom-control-input:checked ~ .custom-control-label::before {
  background-color: var(--red);
  border-color: var(--red);
}
body.pa .custom-control-label::before {
  background: var(--input-fill);
  border: 1px solid var(--line);
}
body.pa .input-group-text {
  background: rgba(var(--wash-rgb), 0.04);
  border: 1px solid var(--line);
  color: var(--ink-dim);
  font-family: var(--mono);
  font-size: 12px;
}
/* twenty-one's merged input groups */
body.pa .input-group-merge .form-control { border-left: 0; }
body.pa .input-group-merge .input-group-prepend .input-group-text { border-right: 0; }

/* validation states */
body.pa .form-control.is-invalid { border-color: var(--crit); }
body.pa .invalid-feedback { color: var(--crit); font-family: var(--mono); font-size: 11.5px; }
body.pa .form-control.is-valid { border-color: var(--good); }

/* --- buttons → the house console voice --- */
body.pa .btn {
  font-family: var(--mono);
  font-size: 12px;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  border-radius: var(--rad-sm);
  transition: background 0.25s, color 0.25s, border-color 0.25s, box-shadow 0.25s;
}
/* primary = solid flame (cyan), dark text. Hover stays CYAN on
   purpose: the site's orange hover is a pre-rebrand leftover. */
body.pa .btn-primary {
  background: var(--flame);
  border: 1px solid var(--flame);
  color: var(--on-flame);
  font-weight: 600;
}
body.pa .btn-primary:hover,
body.pa .btn-primary:focus,
body.pa .btn-primary:not(:disabled):active {
  background: var(--flame-hi);
  border-color: var(--flame-hi);
  color: var(--on-flame);
  box-shadow: var(--flame-glow);
}
body.pa .btn-default,
body.pa .btn-secondary,
body.pa .btn-light {
  background: transparent;
  border: 1px solid var(--line);
  color: var(--ink);
}
body.pa .btn-default:hover,
body.pa .btn-secondary:hover,
body.pa .btn-light:hover {
  background: rgba(var(--wash-rgb), 0.04);
  border-color: rgba(var(--wash-rgb), 0.28);
  color: var(--ink);
}
body.pa .btn-info,
body.pa .btn-outline-primary,
body.pa .btn-outline-info {
  background: transparent;
  border: 1px solid var(--red);
  color: var(--ink);
}
body.pa .btn-info:hover,
body.pa .btn-outline-primary:hover,
body.pa .btn-outline-info:hover {
  background: rgba(var(--red-rgb), 0.12);
  border-color: var(--red);
  color: var(--ink);
}
/* solid go-green: payment and confirm actions must pop */
body.pa .btn-success {
  background: var(--good);
  border: 1px solid var(--good);
  color: var(--on-good);
  font-weight: 600;
}
body.pa .btn-success:hover,
body.pa .btn-success:focus {
  background: var(--good-hi);
  border-color: var(--good-hi);
  color: var(--on-good);
  box-shadow: var(--good-glow);
}
body.pa .btn-danger,
body.pa .btn-outline-danger {
  background: transparent;
  border: 1px solid var(--crit);
  color: var(--crit);
}
body.pa .btn-danger:hover,
body.pa .btn-outline-danger:hover { background: rgba(var(--crit-rgb), 0.12); color: var(--crit); }
body.pa .btn-warning {
  background: transparent;
  border: 1px solid var(--warn);
  color: var(--warn);
}
body.pa .btn-warning:hover { background: rgba(var(--warn-rgb), 0.12); color: var(--warn); }
body.pa .btn-link { color: var(--red); text-decoration: none; }
body.pa .btn-link:hover { color: var(--ink); }
body.pa .btn:disabled,
body.pa .btn.disabled { opacity: 0.45; cursor: not-allowed; }

/* --- tooltips & popovers --- */
body.pa .tooltip-inner {
  background: var(--panel-solid);
  border: 1px solid var(--line);
  color: var(--ink);
  font-family: var(--mono);
  font-size: 11px;
  letter-spacing: 0.06em;
}
body.pa .popover {
  background: var(--panel-solid);
  border: 1px solid var(--line);
  border-radius: var(--rad);
  color: var(--ink);
}
body.pa .popover-header {
  background: rgba(var(--wash-rgb), 0.03);
  border-bottom: 1px solid var(--line-soft);
  color: var(--ink);
  font-family: var(--mono);
  font-size: 11px;
  letter-spacing: 0.16em;
  text-transform: uppercase;
}
body.pa .popover-body { color: var(--ink-dim); }
body.pa .bs-popover-bottom .arrow::after,
body.pa .bs-popover-auto[x-placement^="bottom"] .arrow::after { border-bottom-color: var(--panel-solid); }
body.pa .bs-popover-top .arrow::after,
body.pa .bs-popover-auto[x-placement^="top"] .arrow::after { border-top-color: var(--panel-solid); }

/* --- misc chrome --- */
body.pa #fullpage-overlay { background: var(--scrim); color: var(--ink); }
body.pa .item-selector .item {
  border: 1px solid var(--line);
  border-radius: var(--rad-sm);
  background: var(--tint);
  color: var(--ink-dim);
}
body.pa .item-selector .item:hover { border-color: var(--red); color: var(--ink); }
body.pa .item-selector .item.active {
  border-color: var(--red);
  color: var(--ink);
  background: var(--blue-wash);
  box-shadow: inset 0 0 0 1px var(--red);
}
body.pa code, body.pa pre {
  font-family: var(--mono);
  color: var(--flame);
  background: var(--well);
  border-radius: var(--rad-sm);
}
body.pa pre {
  border: 1px solid var(--line-soft);
  padding: 10px 12px;
}

/* ============================================================
   04 WHMCS CHROME — header, nav, breadcrumb, sidebar, footer
   ============================================================ */

/* --- the console bar: ONE strip of chrome, everything in it ---
   Structure (header.tpl): .pa-head > nav.navbar.navbar-expand-xl
   .pa-head-bar > .container > [brand | tools | collapse(nav)] */
body.pa .pa-head {
  position: relative;
  background: var(--console-bar-bg);
  -webkit-backdrop-filter: blur(14px);
  backdrop-filter: blur(14px);
  border-bottom: 1px solid var(--line-soft);
}
/* signature ignition line across the very top of the console */
body.pa .pa-head::before {
  content: "";
  position: absolute; top: 0; left: 0; right: 60%;
  height: 2px;
  background: linear-gradient(90deg, var(--red) 0%, var(--red-deep) 55%, transparent 100%);
}
body.pa .pa-head-bar { padding: 0; }
body.pa .pa-head-bar > .container {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  min-height: 64px;
  gap: 8px 22px;
  padding-top: 8px;
  padding-bottom: 8px;
}
body.pa .pa-brand { margin: 0; padding: 0; }
body.pa .pa-brand .logo-img { width: 150px; height: auto; display: block; }

/* nav: mono uppercase, underline wipe, no band of its own */
body.pa .pa-nav-wrap { flex: 1 1 auto; }
body.pa .pa-nav { align-items: center; gap: clamp(4px, 1vw, 10px); }
body.pa .pa-nav > li { display: block; }
body.pa .pa-nav > li > a {
  display: inline-block;
  font-family: var(--mono);
  font-size: 11px;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--ink-dim);
  text-decoration: none;
  position: relative;
  padding: 22px 8px;
  transition: color 0.25s;
}
body.pa .pa-nav > li > a::after {
  content: "";
  position: absolute;
  left: 8px; right: 100%; bottom: 14px;
  height: 2px;
  background: var(--red);
  transition: right 0.3s cubic-bezier(0.6, 0, 0.2, 1);
}
body.pa .pa-nav > li > a:hover { color: var(--ink); }
body.pa .pa-nav > li > a:hover::after { right: 8px; }
body.pa .pa-nav .badge { background: var(--red); color: var(--on-accent); }

/* right cluster: compact search + square instrument buttons */
body.pa .pa-head-tools {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-left: auto;
}
body.pa .pa-search { position: relative; }
body.pa .pa-search .form-control {
  width: 128px;
  height: 34px;
  padding: 6px 32px 6px 12px;
  font-family: var(--mono);
  font-size: 11px;
  letter-spacing: 0.06em;
  background: var(--input-fill);
  border: 1px solid var(--line);
  transition: width 0.3s cubic-bezier(0.2, 0.6, 0.2, 1), border-color 0.25s, background 0.25s;
}
body.pa .pa-search .form-control:focus { width: 220px; }
body.pa .pa-search-go {
  position: absolute; top: 1px; right: 1px; bottom: 1px;
  width: 32px;
  display: grid; place-items: center;
  background: transparent;
  border: 0;
  color: var(--ink-dim);
  cursor: pointer;
}
body.pa .pa-search-go:hover { color: var(--red); }
body.pa .pa-tool {
  position: relative;
  display: grid; place-items: center;
  width: 34px; height: 34px;
  border: 1px solid var(--line);
  border-radius: var(--rad-sm);
  background: var(--tool-fill);
  color: var(--ink-dim);
  font-size: 13px;
  cursor: pointer;
  text-decoration: none;
  transition: color 0.25s, border-color 0.25s;
  padding: 0;
}
body.pa .pa-tool:hover { color: var(--red); border-color: var(--red); }
body.pa .pa-tool .badge {
  position: absolute; top: -6px; right: -6px;
  background: var(--red); color: var(--on-accent);
  font-size: 9px; padding: 2px 5px;
}
body.pa .pa-account-chip {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  height: 34px;
  padding: 0 12px;
  max-width: 150px;
  border: 1px solid var(--line);
  border-radius: var(--rad-sm);
  font-family: var(--mono);
  font-size: 10.5px;
  font-weight: 600;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--ink);
  text-decoration: none;
  transition: border-color 0.25s;
}
body.pa .pa-account-chip span {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
body.pa .pa-account-chip:hover { border-color: var(--red); color: var(--ink); }
body.pa .pa-account-chip .pa-dot { flex: 0 0 auto; }

/* collapsed (mobile) nav panel */
@media (max-width: 1199.98px) {
  body.pa .pa-nav-wrap {
    order: 10;
    flex-basis: 100%;
    background: var(--mobile-nav-bg);
    border: 1px solid var(--line-soft);
    border-radius: var(--rad);
    padding: 14px;
    margin: 6px 0 10px;
  }
  body.pa .pa-nav > li > a { padding: 12px 8px; display: block; }
  body.pa .pa-nav > li > a::after { display: none; }
  body.pa .pa-search-mobile { margin-bottom: 10px; }
  body.pa .pa-search-mobile .form-control { width: 100%; }
  body.pa .pa-search-mobile .form-control:focus { width: 100%; }
}

/* --- breadcrumb: a floating mono crumb line, not a band --- */
body.pa .master-breadcrumb {
  background: transparent;
  border: 0;
  padding-top: 18px;
}
body.pa .breadcrumb {
  background: transparent;
  font-family: var(--mono);
  font-size: 10px;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  margin: 0;
  padding: 0;
  opacity: 0.85;
}
body.pa .breadcrumb-item a { color: var(--ink-dim); }
body.pa .breadcrumb-item a:hover { color: var(--ink); }
body.pa .breadcrumb-item.active { color: var(--ink-dim); }
body.pa .breadcrumb-item + .breadcrumb-item::before {
  content: "//";
  color: var(--red);
}

/* --- sidebars → open Control Room rails (no card boxes) --- */
body.pa .sidebar .card-sidebar {
  background: transparent;
  border: 0;
  border-top: 1px solid var(--line);
  border-radius: 0;
  position: relative;
}
body.pa .sidebar .card-sidebar::before {
  content: "";
  position: absolute; top: -1px; left: 0;
  width: 28px; height: 2px;
  background: var(--flame);
}
body.pa .sidebar .card-header {
  background: transparent;
  border: 0;
  padding: 14px 0 6px;
}
body.pa .sidebar .card-title i:first-child { display: none; }
body.pa .sidebar .card-minimise { color: var(--ink-dim); }
body.pa .sidebar .card-body { padding: 10px 0; }
body.pa .sidebar .list-group-item {
  background: transparent;
  border: 0;
  border-top: 1px solid var(--line-soft);
  border-left: 2px solid transparent;
  padding: 11px 8px;
  font-size: 13.5px;
}
body.pa .sidebar .list-group-item:first-child { border-top: 0; }
body.pa .sidebar .list-group-item.active {
  border-left-color: var(--red);
  background: var(--blue-wash);
  color: var(--ink);
}
body.pa .sidebar .badge { background: transparent; border: 1px solid var(--line); color: var(--ink-dim); }
body.pa .sidebar .card-footer { background: transparent; border: 0; padding: 8px 0; }

/* --- footer → compact console strip (lunar scene stays home) --- */
body.pa .footer {
  background: var(--bg-2);
  border-top: 1px solid var(--line-soft);
  color: var(--ink-dim);
  position: relative;
}
body.pa .footer::before {
  content: "";
  position: absolute; top: -1px; left: 0;
  width: 28px; height: 1px;
  background: var(--flame);
}
body.pa .footer .nav-link,
body.pa .footer a {
  color: var(--ink-dim);
  font-family: var(--mono);
  font-size: 11px;
  letter-spacing: 0.14em;
  text-transform: uppercase;
}
body.pa .footer a:hover { color: var(--ink); }
body.pa .footer .copyright {
  font-family: var(--mono);
  font-size: 11px;
  letter-spacing: 0.12em;
  color: var(--ink-dim);
}
body.pa .footer .btn {
  color: var(--ink-dim);
  font-size: 10.5px;
}

/* return-to-admin chip stays loud on purpose */
body.pa .btn-return-to-admin {
  background: transparent !important;
  border: 1px solid var(--warn) !important;
  color: var(--warn) !important;
}

/* --- notifications popover list --- */
body.pa .client-alerts li a { color: var(--ink-dim); }
body.pa .client-alerts li a:hover { color: var(--ink); }
body.pa .client-alerts li.none { color: var(--ink-dim); }

/* --- dashboard instrument strip (replaces the boxed tiles) ---
   One framed row, cells split by hairlines, number is the hero */
body.pa .pa-strip {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  border: 1px solid var(--line);
  border-radius: var(--rad);
  background: var(--panel-glass);
  overflow: hidden;
}
body.pa .pa-strip-cell {
  position: relative;
  display: grid;
  gap: 6px;
  padding: clamp(18px, 2.5vw, 28px) clamp(16px, 2vw, 26px);
  text-decoration: none;
  color: var(--ink-dim);
  border-left: 1px solid var(--line-soft);
  transition: background 0.25s, color 0.25s;
}
body.pa .pa-strip-cell:first-child { border-left: 0; }
body.pa .pa-strip-cell::before {
  content: "";
  position: absolute; top: -1px; left: 0;
  width: 28px; height: 2px;
  background: var(--red);
  opacity: 0;
  transition: opacity 0.25s;
}
body.pa .pa-strip-cell:hover { background: var(--blue-wash); color: var(--ink-dim); }
body.pa .pa-strip-cell:hover::before { opacity: 1; }
body.pa .pa-strip-label {
  font-family: var(--mono);
  font-size: 10.5px;
  font-weight: 600;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--ink-dim);
}
body.pa .pa-strip-num {
  font-family: var(--disp);
  font-weight: 700;
  font-size: clamp(30px, 3.4vw, 46px);
  line-height: 0.95;
  color: var(--ink);
}
body.pa .pa-strip-sub {
  font-family: var(--mono);
  font-size: 10px;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: rgba(var(--ink-dim-rgb), 0.5);
}
body.pa .pa-strip-cell.is-warn .pa-strip-num { color: var(--warn); }
@media (max-width: 767px) {
  body.pa .pa-strip { grid-template-columns: 1fr 1fr; }
  body.pa .pa-strip-cell:nth-child(3) { border-left: 0; }
  body.pa .pa-strip-cell:nth-child(n+3) { border-top: 1px solid var(--line-soft); }
}

/* legacy tiles (any addon still rendering them) stay presentable */
body.pa .tiles .tile {
  background: var(--panel-glass);
  border: 1px solid var(--line);
  color: var(--ink-dim);
}
body.pa .tiles .tile .stat { font-family: var(--disp); font-weight: 700; color: var(--ink); }
body.pa .tiles .tile .highlight { height: 2px; }
body.pa .bg-color-blue,
body.pa .bg-color-midnight-blue,
body.pa .bg-color-turquoise { background-color: var(--red) !important; }
body.pa .bg-color-green,
body.pa .bg-color-emerald,
body.pa .bg-color-lime { background-color: var(--good) !important; }
body.pa .bg-color-red,
body.pa .bg-color-pomegranate,
body.pa .bg-color-magenta,
body.pa .bg-color-pink { background-color: var(--crit) !important; }
body.pa .bg-color-gold,
body.pa .bg-color-sun-flower,
body.pa .bg-color-orange { background-color: var(--warn) !important; }
body.pa .bg-color-teal { background-color: var(--flame) !important; }
body.pa .bg-color-purple,
body.pa .bg-color-amethyst { background-color: var(--red-deep) !important; }
body.pa .bg-color-silver,
body.pa .bg-color-asbestos,
body.pa .bg-color-wet-asphalt { background-color: var(--line) !important; }

/* home panels: card accents → 2px left rules, house tones */
body.pa [class*="card-accent-"] { border-top: 1px solid var(--line) !important; }
body.pa .card-accent-blue,
body.pa .card-accent-midnight-blue,
body.pa .card-accent-turquoise { border-left: 2px solid var(--red) !important; }
body.pa .card-accent-green,
body.pa .card-accent-emerald,
body.pa .card-accent-lime { border-left: 2px solid var(--good) !important; }
body.pa .card-accent-red,
body.pa .card-accent-pomegranate,
body.pa .card-accent-magenta,
body.pa .card-accent-pink { border-left: 2px solid var(--crit) !important; }
body.pa .card-accent-gold,
body.pa .card-accent-sun-flower,
body.pa .card-accent-orange { border-left: 2px solid var(--warn) !important; }
body.pa .card-accent-teal { border-left: 2px solid var(--flame) !important; }
body.pa .card-accent-purple,
body.pa .card-accent-amethyst { border-left: 2px solid var(--red-deep) !important; }
body.pa .card-accent-silver,
body.pa .card-accent-asbestos,
body.pa .card-accent-wet-asphalt { border-left: 2px solid var(--line) !important; }

/* --- dashboard home panels: DE-BOXED ---
   No card chrome at all: an accent tick + hairline top rule,
   mono title, open hairline rows. Kills the boxes-in-boxes
   grid that made the dark skin still read as stock WHMCS. */
body.pa .client-home-cards .card,
body.pa .client-home-cards [class*="card-accent-"] {
  background: transparent;
  border: 0 !important;
  border-top: 1px solid var(--line) !important;
  border-radius: 0;
  position: relative;
  margin-bottom: clamp(28px, 4vw, 44px);
  box-shadow: none;
}
body.pa .client-home-cards .card::before {
  content: "";
  position: absolute; top: -1px; left: 0;
  width: 28px; height: 2px;
  background: var(--red);
}
body.pa .client-home-cards .card-header {
  background: transparent;
  border: 0;
  padding: 16px 0 4px;
}
body.pa .client-home-cards .card-title i { display: none; } /* icon clutter */
body.pa .client-home-cards .card-body { padding: 12px 0; color: var(--ink-dim); }
body.pa .client-home-cards .list-group-item {
  background: transparent;
  border: 0;
  border-top: 1px solid var(--line-soft);
  padding: 14px 2px;
  color: var(--ink-dim);
}
body.pa .client-home-cards .list-group-item:first-child { border-top: 0; }
body.pa .client-home-cards a.list-group-item:hover {
  background: transparent;
  color: var(--ink);
  padding-left: 8px;
  transition: padding-left 0.25s, color 0.25s;
}
body.pa .client-home-cards .list-group-item.active {
  background: transparent;
  border-left: 0;
  color: var(--ink);
}
body.pa .client-home-cards .card-footer {
  background: transparent;
  border: 0;
  padding: 6px 0 0;
}
body.pa .client-home-cards .card-footer:not(:has(*)) { display: none; }

/* --- status vocabulary → mono chips ---
   Every .status-* / .label-* renders as the house chip: mono
   uppercase, hairline border tinted by a local custom property. */
body.pa .label,
body.pa [class*="status-"] {
  display: inline-block;
  font-family: var(--mono);
  font-size: 10.5px;
  font-weight: 600;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--pac, var(--ink-dim));
  background: transparent !important;
  border: 1px solid var(--pac, var(--line));
  border-radius: var(--rad-sm);
  padding: 4px 10px;
  line-height: 1.4;
}
/* good */
body.pa .status-active, body.pa .status-paid, body.pa .status-completed,
body.pa .status-delivered, body.pa .status-accepted, body.pa .status-open,
body.pa .label-success { --pac: var(--good); }
/* warn */
body.pa .status-pending, body.pa .status-pending-registration,
body.pa .status-pending-transfer, body.pa .status-payment-pending,
body.pa .status-unpaid, body.pa .status-answered, body.pa .status-customer-reply,
body.pa .status-inprogress, body.pa .status-grace, body.pa .status-suspended,
body.pa .status-onhold, body.pa .status-redemption, body.pa .status-collections,
body.pa .label-warning { --pac: var(--warn); }
/* crit */
body.pa .status-overdue, body.pa .status-terminated, body.pa .status-cancelled,
body.pa .status-expired, body.pa .status-fraud, body.pa .status-dead,
body.pa .status-lost, body.pa .status-transferred-away,
body.pa .label-danger { --pac: var(--crit); }
/* informational */
body.pa .label-info { --pac: var(--red); }
/* neutral */
body.pa .status-closed, body.pa .status-refunded,
body.pa .label-default, body.pa .label-placeholder { --pac: var(--ink-dim); }

/* ============================================================
   05 PA COMPONENTS — the house language, portable pieces
   ============================================================ */

/* the mono tag voice (eyebrow host) */
body.pa .tag {
  font-family: var(--mono);
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--red);
}

/* corner brackets: add .pa-corners to any panel */
body.pa .pa-corners { position: relative; }
body.pa .pa-corners::before,
body.pa .pa-corners::after {
  content: "";
  position: absolute;
  width: 16px; height: 16px;
  border: 1px solid var(--bracket);
  pointer-events: none;
}
body.pa .pa-corners::before { top: -1px; left: -1px; border-right: 0; border-bottom: 0; }
body.pa .pa-corners::after { bottom: -1px; right: -1px; border-left: 0; border-top: 0; }

/* hairline rule with accent tick */
body.pa .pa-rule {
  position: relative;
  border: 0; height: 1px;
  background: var(--line-soft);
  margin: 22px 0;
}
body.pa .pa-rule::before {
  content: "";
  position: absolute; top: 0; left: 0;
  width: 28px; height: 1px;
  background: var(--flame);
}

/* generic mono chip (set --pac inline or via a wrapper class) */
body.pa .pa-chip {
  display: inline-block;
  font-family: var(--mono);
  font-size: 10.5px;
  font-weight: 600;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--pac, var(--ink-dim));
  border: 1px solid var(--pac, var(--line));
  border-radius: var(--rad-sm);
  padding: 6px 12px;
  text-decoration: none;
  line-height: 1.4;
}
body.pa a.pa-chip:hover {
  color: var(--pac, var(--ink));
  box-shadow: inset 0 0 0 1px var(--pac, var(--line));
}

/* console note block */
body.pa .pa-note {
  font-family: var(--mono);
  font-size: 11.5px;
  letter-spacing: 0.08em;
  color: var(--ink-dim);
  border-left: 2px solid var(--red);
  padding: 12px 16px;
  background: rgba(var(--red-rgb), 0.05);
}

/* live dot */
body.pa .pa-dot {
  display: inline-block;
  width: 7px; height: 7px;
  border-radius: 50%;
  background: var(--red);
  box-shadow: 0 0 10px var(--red);
  animation: pa-pulse 2.2s infinite;
}
@keyframes pa-pulse { 50% { opacity: 0.35; } }

/* pure-CSS conic dial: set --p (0-100) and --pac inline */
body.pa .pa-dial {
  width: 120px; height: 120px;
  border-radius: 50%;
  background:
    radial-gradient(closest-side, var(--dial-hub) 78%, transparent 79%),
    conic-gradient(var(--pac, var(--red)) calc(var(--p, 0) * 1%), rgba(var(--wash-rgb), 0.08) 0);
  display: grid;
  place-content: center;
  filter: drop-shadow(var(--dial-shadow));
}

/* starfield tiles, pure CSS, used by airlock + dashboard bands */
body.pa .pa-stars {
  position: absolute; inset: 0;
  pointer-events: none;
  background-image:
    radial-gradient(1px 1px at 12% 24%, rgba(var(--ink-rgb), 0.5) 50%, transparent 51%),
    radial-gradient(1px 1px at 34% 68%, rgba(var(--ink-rgb), 0.35) 50%, transparent 51%),
    radial-gradient(1.4px 1.4px at 56% 12%, rgba(var(--ink-rgb), 0.45) 50%, transparent 51%),
    radial-gradient(1px 1px at 72% 48%, rgba(var(--ink-rgb), 0.3) 50%, transparent 51%),
    radial-gradient(1.2px 1.2px at 88% 80%, rgba(var(--ink-rgb), 0.4) 50%, transparent 51%),
    radial-gradient(1px 1px at 22% 88%, rgba(var(--ink-rgb), 0.3) 50%, transparent 51%);
  background-size: 520px 520px;
  opacity: var(--stars-opacity);
}

/* ------------------------------------------------------------
   eyebrow engine — ported verbatim from the site (styles.css
   tail). Markup contract identical: pa.js arms .is-live once
   per eyebrow; the ungated state is the complete static
   fallback (no JS = still reads correctly).
   ------------------------------------------------------------ */
body.pa .tag.eb {
  display: inline-flex; align-items: center;
  gap: 12px; flex-wrap: wrap; row-gap: 4px;
  max-width: 100%;
}
body.pa .eb .eb-text { font-weight: inherit; }
body.pa .eb .eb-fx { flex: 0 0 auto; pointer-events: none; }

/* pulse: EKG trace */
body.pa .eb-ekg { display: block; width: 120px; height: 22px; overflow: visible; }
body.pa .eb-ekg path {
  fill: none; stroke: currentColor;
  stroke-width: 1.5; stroke-linecap: round; stroke-linejoin: round;
}
body.pa .eb-ekg-base { opacity: 0.3; }
body.pa .eb-ekg-pulse {
  opacity: 0; stroke-width: 2;
  stroke-dasharray: 14 186;
  stroke-dashoffset: 14;
  filter: drop-shadow(0 0 3px currentColor);
}
body.pa .eb.is-live .eb-ekg-pulse { opacity: 1; animation: eb-ekg-run 2.6s linear infinite; }
@keyframes eb-ekg-run {
  0% { stroke-dashoffset: 14; }
  70%, 100% { stroke-dashoffset: -100; }
}

/* stream: dotted strips */
body.pa .eb-dots {
  width: clamp(28px, 6vw, 84px); min-width: 12px; height: 5px;
  flex-shrink: 1;
  background-image: radial-gradient(1.2px 1.2px at 4px 2.5px, currentColor 50%, transparent 51%);
  background-size: 8px 5px; background-repeat: repeat-x;
  background-position: 0 50%;
  opacity: 0.55;
}
body.pa .eb-dots-l {
  -webkit-mask-image: linear-gradient(90deg, transparent, #000 65%);
  mask-image: linear-gradient(90deg, transparent, #000 65%);
}
body.pa .eb-dots-r {
  -webkit-mask-image: linear-gradient(270deg, transparent, #000 65%);
  mask-image: linear-gradient(270deg, transparent, #000 65%);
}
body.pa .eb.is-live .eb-dots-l { animation: eb-dots-in-l 2.8s linear infinite; }
body.pa .eb.is-live .eb-dots-r { animation: eb-dots-in-r 2.8s linear infinite; }
@keyframes eb-dots-in-l { to { background-position-x: 64px; } }
@keyframes eb-dots-in-r { to { background-position-x: -64px; } }
body.pa .eb-stream .eb-text::before { content: ":: "; content: ":: " / ""; }
body.pa .eb-stream .eb-text::after { content: " ::"; content: " ::" / ""; }

/* beacon: dot with staggered pings */
body.pa .eb-beacon-dot {
  position: relative; width: 8px; height: 8px; border-radius: 50%;
  background: currentColor;
  box-shadow: 0 0 10px currentColor;
}
body.pa .eb-beacon-dot::before,
body.pa .eb-beacon-dot::after {
  content: ""; position: absolute; inset: 0; border-radius: 50%;
  border: 1px solid currentColor; opacity: 0;
}
body.pa .eb.is-live .eb-beacon-dot::before,
body.pa .eb.is-live .eb-beacon-dot::after { animation: eb-ping 2.4s ease-out infinite; }
body.pa .eb.is-live .eb-beacon-dot::after { animation-delay: -1.2s; }
@keyframes eb-ping {
  0% { opacity: 0.9; transform: scale(1); }
  70%, 100% { opacity: 0; transform: scale(3.2); }
}

/* scan: radar sweep + ellipsis */
body.pa .eb-radar {
  position: relative; width: 16px; height: 16px; border-radius: 50%;
  border: 1px solid currentColor; opacity: 0.9;
  box-shadow: 0 0 8px currentColor;
}
body.pa .eb-radar-ping {
  position: absolute; inset: 0; border-radius: 50%;
  border: 1px solid currentColor; opacity: 0;
}
body.pa .eb.is-live .eb-radar-ping { animation: eb-ping 2.4s ease-out infinite; }
body.pa .eb.is-live .eb-radar-ping-2 { animation-delay: -1.2s; }
body.pa .eb-radar::before {
  content: ""; position: absolute; inset: 1px; border-radius: 50%;
  background: conic-gradient(from 0deg, transparent 0 260deg, currentColor 360deg);
  opacity: 0.8;
}
body.pa .eb-radar::after {
  content: ""; position: absolute; left: 50%; top: 50%;
  width: 3px; height: 3px; margin: -1.5px 0 0 -1.5px;
  border-radius: 50%; background: currentColor;
}
body.pa .eb.is-live .eb-radar::before { animation: eb-sweep 2.4s linear infinite; }
@keyframes eb-sweep { to { transform: rotate(360deg); } }
body.pa .eb-ellipsis { margin-left: -9px; }
body.pa .eb-ellipsis::after { content: "..."; }
body.pa .eb.is-live .eb-ellipsis::after { animation: eb-ellipsis 1.4s steps(1, end) infinite; }
@keyframes eb-ellipsis {
  0% { content: "."; }
  33% { content: ".."; }
  66% { content: "..."; }
}

/* ============================================================
   06 PAGES — body-class scoped adjustments
   ============================================================ */

/* dashboard head: title left, live status chip right */
body.pa .pa-dash-head {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 16px 28px;
  flex-wrap: wrap;
  margin-top: clamp(14px, 2.5vw, 30px);
}
body.pa .pa-dash-head .tag { font-size: 11px; letter-spacing: 0.26em; }
body.pa .pa-dash-title {
  font-size: clamp(30px, 4.6vw, 54px);
  line-height: 0.98;
  margin: 12px 0 0;
}
body.pa .pa-dash-meta { padding-bottom: 6px; }
body.pa .pa-dash-rule { margin: 18px 0 clamp(24px, 3.5vw, 38px); }

/* invoice view: dark console readout on screen, paper on print */
body.pa--viewinvoice .invoice-container { color: var(--ink-dim); }
body.pa .invoice-header { border-bottom: 1px solid var(--line-soft); }
body.pa .invoice-status {
  font-family: var(--disp);
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.04em;
}
body.pa .invoice-status.paid { color: var(--good); }
body.pa .invoice-status.unpaid,
body.pa .invoice-status.payment-pending { color: var(--warn); }
body.pa .invoice-status.overdue,
body.pa .invoice-status.cancelled { color: var(--crit); }
body.pa .invoice-status.refunded,
body.pa .invoice-status.draft,
body.pa .invoice-status.collections { color: var(--ink-dim); }
/* twenty-one paints the paid invoice card header solid green */
body.pa .card-header.bg-success {
  background: rgba(var(--good-rgb), 0.08) !important;
  color: var(--good) !important;
  border-bottom: 1px solid var(--good);
}
body.pa .payment-btn-container { padding: 14px 0; }

/* ticket thread: replies as console transmissions */
body.pa .ticket-reply {
  background: var(--panel-glass);
  border: 1px solid var(--line-soft);
  border-radius: var(--rad);
  border-left: 2px solid var(--line);
}
body.pa .ticket-reply.staff {
  border-left: 2px solid var(--red);
  background: rgba(var(--red-rgb), 0.04);
}
body.pa .attachments {
  border-top: 1px dashed var(--line);
  font-family: var(--mono);
  font-size: 12px;
}

/* ticket thread: message blocks as console panels */
body.pa--viewticket .card,
body.pa--supportticketsview .card { background: var(--panel-glass); }

/* knowledgebase articles read like sec-prose */
body.pa--knowledgebasearticle #main-body p { color: var(--ink-dim); line-height: 1.75; }

/* light-island: wrap anything that must stay light (gateway
   iframes, captcha imagery) so it reads as a deliberate
   instrument card instead of a broken white patch */
body.pa .pa-light-island {
  background: var(--island);
  border: 1px solid var(--line);
  border-radius: var(--rad-sm);
  padding: 10px;
}
body.pa .captchaimage img {
  border: 1px solid var(--line);
  border-radius: var(--rad-sm);
  background: var(--island);
  padding: 4px;
}

/* ============================================================
   07 AIRLOCK — login + password-reset family
   header.tpl adds .pa-airlock to <body> for these templates
   ============================================================ */
body.pa.pa-airlock {
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  background:
    var(--airlock-glow),
    var(--bg) !important;
}

/* strip the working chrome; the airlock is its own room */
body.pa.pa-airlock .pa-head-tools,
body.pa.pa-airlock .pa-nav-wrap,
body.pa.pa-airlock .master-breadcrumb { display: none !important; }
body.pa.pa-airlock .pa-head {
  background: transparent;
  border-bottom: 0;
  -webkit-backdrop-filter: none;
  backdrop-filter: none;
}
body.pa.pa-airlock .pa-head::before { display: none; }
body.pa.pa-airlock .pa-head-bar > .container {
  justify-content: center;
  padding-top: 30px;
}

/* flex-basis must stay auto: twenty-one sets an explicit
   min-height on #main-body, which would otherwise let the
   section stay shorter than the airlock card and slide the
   footer over it */
body.pa.pa-airlock #main-body {
  flex: 1 0 auto;
  display: flex;
  position: relative;
}
/* auto margins center when there is room and stay flush (no
   header overlap) when the airlock card is taller than the
   viewport — unlike align-items: center */
body.pa.pa-airlock #main-body > .container {
  margin-top: auto;
  margin-bottom: auto;
}
body.pa.pa-airlock .footer {
  background: transparent;
  border-top: 0;
  text-align: center;
}
body.pa.pa-airlock .footer::before { display: none; }
body.pa.pa-airlock .footer .float-lg-right { float: none !important; }
body.pa.pa-airlock .footer .nav { justify-content: center !important; }

/* the chamfered console frame (two-layer clip-path trick) */
body.pa .pa-airlock-frame {
  position: relative;
  width: 100%;
  max-width: 460px;
  margin: 24px auto;
  clip-path: polygon(20px 0, 100% 0, 100% calc(100% - 20px), calc(100% - 20px) 100%, 0 100%, 0 20px);
  background: var(--airlock-sheet);
  filter: drop-shadow(var(--shadow-lg));
}
body.pa .pa-airlock-frame::before {
  content: "";
  position: absolute; inset: 1px; z-index: 0;
  clip-path: polygon(19px 0, 100% 0, 100% calc(100% - 19px), calc(100% - 19px) 100%, 0 100%, 0 19px);
  background: var(--airlock-fill);
}
body.pa .pa-airlock-body {
  position: relative; z-index: 1;
  padding: clamp(28px, 5vw, 44px);
}
body.pa .pa-airlock-head { margin-bottom: 24px; }
body.pa .pa-airlock-head .tag { font-size: 11px; letter-spacing: 0.26em; }
body.pa .pa-airlock-title {
  font-family: var(--disp);
  font-weight: 700;
  font-size: clamp(26px, 4vw, 34px);
  line-height: 1;
  text-transform: uppercase;
  margin: 14px 0 6px;
}
body.pa .pa-airlock-sub {
  color: var(--ink-dim);
  font-size: 14px;
  margin: 0;
}
body.pa .pa-airlock-foot {
  border-top: 1px solid var(--line-soft);
  margin-top: 26px;
  padding-top: 18px;
  font-family: var(--mono);
  font-size: 11px;
  letter-spacing: 0.1em;
  color: var(--ink-dim);
}
body.pa .pa-airlock-foot a { color: var(--red); }
body.pa .pa-airlock-foot a:hover { color: var(--ink); }

/* inherited airlock-family pages we did not fork (two-factor
   challenge) keep their card, rendered as a console panel with
   brackets so they read as part of the same room */
body.pa.pa-airlock .card.mw-540 {
  background: var(--panel-solid);
  box-shadow: var(--shadow-lg);
}

/* remember-me: quiet mono line under the primary action */
body.pa .pa-remember {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  margin: 14px 0 0;
  cursor: pointer;
}
body.pa .pa-remember span {
  font-family: var(--mono);
  font-size: 10.5px;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--ink-dim);
}
body.pa .pa-remember .form-check-input { position: static; margin: 0; }

/* "or continue with" divider */
body.pa .pa-or {
  display: flex;
  align-items: center;
  gap: 14px;
  margin: 22px 0 14px;
}
body.pa .pa-or::before,
body.pa .pa-or::after {
  content: "";
  flex: 1;
  height: 1px;
  background: var(--line-soft);
}
body.pa .pa-or span {
  font-family: var(--mono);
  font-size: 10px;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: rgba(var(--ink-dim-rgb), 0.55);
  white-space: nowrap;
}

/* default image CAPTCHA → a proper instrument row: caption in
   the mono voice, image and input side by side, same height */
body.pa .pa-captcha { margin-top: 4px; }
body.pa .pa-captcha .row.justify-content-center,
body.pa .pa-captcha .col-md-8 { margin: 0; padding: 0; max-width: 100%; flex: 1 1 100%; }
body.pa .pa-captcha #default-captcha-domainchecker {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 10px;
  padding: 12px;
  margin: 0;
  border: 1px solid var(--line-soft);
  border-radius: var(--rad-sm);
  background: var(--tint);
  text-align: left;
}
body.pa .pa-captcha #default-captcha-domainchecker p {
  flex: 1 1 100%;
  margin: 0 0 2px;
  font-family: var(--mono);
  font-size: 10px;
  font-weight: 600;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--ink-dim);
  text-align: left;
}
body.pa .pa-captcha .captchaimage {
  flex: 0 0 auto;
  width: auto;
  max-width: none;
  padding: 0;
}
body.pa .pa-captcha .captchaimage img {
  height: 38px;
  width: auto;
  padding: 0;
  border: 1px solid var(--line);
  border-radius: var(--rad-sm);
  background: var(--island);
}
body.pa .pa-captcha #default-captcha-domainchecker > div:not(.captchaimage) {
  flex: 1 1 120px;
  padding: 0;
  max-width: none;
}
body.pa .pa-captcha #inputCaptcha {
  height: 38px;
  font-family: var(--mono);
  letter-spacing: 0.3em;
  text-transform: uppercase;
  text-align: center;
}
/* reCAPTCHA variant: just center it, Google draws the rest */
body.pa .pa-captcha .recaptcha-container { display: flex; justify-content: center; }

/* social sign-in row: center the provider button */
body.pa .social-signin-btns { display: flex; justify-content: center; }
body.pa .providerPreLinking { margin-top: 4px; }

/* ============================================================
   08 RESPONSIVE + PRINT
   ============================================================ */
@media (max-width: 767px) {
  body.pa .tiles .tile .stat { font-size: 26px; }
  body.pa .pa-airlock-frame { margin: 12px auto; }
  body.pa .pa-airlock-body { padding: 24px 20px; }
}

/* collapsed mobile nav panel */
@media (max-width: 1199px) {
  body.pa .main-navbar-wrapper .navbar-collapse {
    background: var(--mobile-nav-bg);
    border: 1px solid var(--line-soft);
    border-radius: var(--rad);
    padding: 12px;
    margin: 8px 0;
  }
}

/* print: invoices and everything else go back to paper */
@media print {
  body.pa { background: #fff !important; color: #111 !important; }
  body.pa::after { display: none !important; }
  body.pa .header, body.pa .footer,
  body.pa .master-breadcrumb, body.pa .sidebar { display: none !important; }
  body.pa .card, body.pa .table, body.pa .table thead th {
    background: #fff !important;
    color: #111 !important;
    border-color: #ccc !important;
  }
  body.pa a { color: #111 !important; }
}

/* ============================================================
   09 LIVE-SWEEP OVERRIDES — first pass on the real install
   found twenty-one components that carry their own light
   backgrounds past our generic skin. Each block below names
   the shipped rule it neutralizes. Appended last on purpose:
   equal specificity resolves in our favor by source order.
   ============================================================ */

/* --- list tables (tickets / services / invoices lists) ---
   ships: .table-list>tbody>tr>td with background-color:#fff,
   light borders and a light sorted-column highlight */
body.pa .table-list > tbody > tr > td { background-color: transparent; }
body.pa .dataTables_wrapper table.table-list {
  border: 1px solid var(--line);
  border-radius: var(--rad-sm);
}
body.pa .dataTables_wrapper table.table-list thead th {
  border-bottom: 1px solid var(--line);
  background: rgba(var(--wash-rgb), 0.03);
}
body.pa .dataTables_wrapper table.table-list thead th.sorting_asc,
body.pa .dataTables_wrapper table.table-list thead th.sorting_desc {
  background-color: rgba(var(--red-rgb), 0.08);
  color: var(--ink);
}
body.pa table.dataTable tbody tr { background: transparent; }
body.pa table.dataTable td.sorting_1,
body.pa table.dataTable tbody > tr > .sorting_1 { background: rgba(var(--red-rgb), 0.04); }

/* DataTables search box: ships a #fff bg + search.png sprite */
body.pa .dataTables_wrapper .dataTables_filter label .form-control {
  background: var(--input-fill) none;
  border: 1px solid var(--line);
  border-radius: var(--rad-sm);
  color: var(--ink);
  padding: 8px 12px !important;
  font-family: var(--mono);
  font-size: 11.5px;
  letter-spacing: 0.06em;
}
body.pa .dataTables_wrapper .dataTables_filter label .form-control:focus {
  border-color: var(--red);
  background: var(--input-focus-fill) none;
}
body.pa .dataTables_wrapper .dataTables_length select {
  background: var(--input-fill);
  border: 1px solid var(--line);
  border-radius: var(--rad-sm);
  color: var(--ink);
  color-scheme: var(--scheme);
}

/* pagination: force the console look over any vendor skin */
body.pa .pagination .page-link,
body.pa .paginate_button .page-link,
body.pa a.paginate_button {
  background: transparent !important;
  border-color: var(--line-soft) !important;
  color: var(--ink-dim) !important;
}
body.pa .pagination .page-item.active .page-link,
body.pa .paginate_button.active .page-link {
  background: var(--red) !important;
  border-color: var(--red) !important;
  color: var(--on-accent) !important;
}
body.pa .pagination .page-link:hover {
  background: var(--blue-wash) !important;
  border-color: var(--red) !important;
  color: var(--ink) !important;
}
body.pa .pagination .page-item.disabled .page-link {
  background: transparent !important;
  color: var(--ink-faint) !important;
}

/* --- ticket reply editor (.md-editor ships white chrome) --- */
body.pa .md-editor {
  border: 1px solid var(--line);
  border-radius: var(--rad-sm);
  background: transparent;
}
body.pa .md-editor > .btn-toolbar {
  background: rgba(var(--wash-rgb), 0.03);
  border-bottom: 1px solid var(--line-soft);
  padding: 6px;
}
body.pa .md-editor > .md-preview,
body.pa .md-editor > textarea.markdown-editor,
body.pa .md-editor > textarea {
  background: var(--input-fill);
  color: var(--ink);
  border: 0;
}
body.pa .md-editor > textarea:focus,
body.pa .md-editor.active { border-color: var(--red); box-shadow: none; }
body.pa .markdown-content table,
body.pa .md-preview table { background: transparent; }

/* --- service detail drill-down --- */
body.pa div.product-details-tab-container {
  background-color: var(--panel-glass);
  border: 1px solid var(--line);
  border-top: 0;
  border-radius: 0 0 var(--rad-sm) var(--rad-sm);
}
body.pa .promo-container,
body.pa .promo-banner,
body.pa .mc-promo-login,
body.pa .mc-promo-manage,
body.pa .upgrade .products .product {
  background-color: var(--panel-glass);
  border: 1px solid var(--line);
  color: var(--ink-dim);
}

/* --- announcements (ships light-gray article blocks) --- */
body.pa .announcements .announcement article {
  background-color: var(--tint);
  border-left: 2px solid var(--red);
  color: var(--ink-dim);
}

/* --- knowledgebase hovers / registration / store bits --- */
body.pa .kb-category a:hover,
body.pa .kb-article-item:hover { background-color: rgba(var(--wash-rgb), 0.04); }
body.pa #registration .field,
body.pa #registration .form-control {
  background: var(--input-fill);
  color: var(--ink);
}
body.pa #registration .sub-heading span,
body.pa .sub-heading span { background-color: var(--bg); color: var(--ink-dim); }
body.pa .store-order-container .store-domain-tabs li.active a,
body.pa .responsive-tabs-sm .nav-item a.active { background-color: var(--blue-wash); color: var(--ink); }
body.pa .responsive-tabs-sm-connector .channel { background-color: var(--line); }
body.pa .featured-tld { background-color: var(--tint); }
body.pa .domain-pricing .tld-pricing-header div:nth-child(odd) { background-color: rgba(var(--wash-rgb), 0.03); }

/* --- domain search shell on home panels (ships a white tray) --- */
body.pa .home-domain-search .input-group-wrapper {
  background-color: var(--input-fill);
  border: 1px solid var(--line);
}
body.pa .home-domain-search .input-group-wrapper .form-control {
  background: transparent;
  color: var(--ink);
}

/* --- misc light leftovers --- */
body.pa .modal .modal-header { background: transparent; }
body.pa .table .thead-light th { background: rgba(var(--wash-rgb), 0.03); color: var(--ink); }
body.pa .img-thumbnail { background-color: var(--panel); border-color: var(--line); }
body.pa .jumbotron { background-color: var(--tint); }
body.pa .badge-light { background: transparent; border: 1px solid var(--line); color: var(--ink-dim); }
body.pa .custom-file-label {
  background: var(--input-fill);
  border: 1px solid var(--line);
  color: var(--ink-dim);
}
body.pa .custom-file-label::after {
  background: rgba(var(--wash-rgb), 0.06);
  color: var(--ink);
  border-left: 1px solid var(--line);
}
body.pa .sidebar .list-group-item .badge { background: transparent; }
body.pa .action-icon-btns a { background: var(--panel-glass); border: 1px solid var(--line); color: var(--ink-dim); }

/* ============================================================
   10 CONSOLE BAR v2 + BUTTON TONE PASS (live feedback round)
   ============================================================ */

/* full-bleed bar: brand hard left, tools hard right, one line.
   Content below stays in its own container, same relationship
   as the marketing site (full-bleed header, constrained page). */
body.pa .pa-head-bar > .container {
  max-width: none;
  padding-left: clamp(16px, 2.5vw, 44px);
  padding-right: clamp(16px, 2.5vw, 44px);
}
body.pa .pa-nav-wrap { min-width: 0; }

/* twenty-one's overflow "More" auto-dropdown duplicates links
   already visible; the full-bleed bar fits everything */
body.pa .pa-nav .collapsable-dropdown { display: none !important; }

/* Bootstrap paints its dropdown caret on the SAME ::after we
   used for the underline wipe: the collision rendered stray
   dashes under every nav item on live. Underline moves to
   ::before; every ::after (caret included) is retired. */
body.pa .pa-nav > li > a::after { display: none !important; border: 0 !important; }
body.pa .pa-nav > li > a::before {
  content: "";
  position: absolute;
  left: 8px; right: 8px; bottom: 14px;
  height: 2px;
  background: var(--red);
  transform: scaleX(0);
  transform-origin: left;
  transition: transform 0.3s cubic-bezier(0.6, 0, 0.2, 1);
}
body.pa .pa-nav > li > a:hover::before { transform: scaleX(1); }
@media (max-width: 1199.98px) {
  body.pa .pa-nav > li > a::before { display: none; }
}

/* nav dropdown: fully solid so page content never ghosts through */
body.pa .pa-nav .dropdown-menu {
  background: var(--menu-bg);
  border: 1px solid var(--line);
  margin-top: 0;
}
body.pa .pa-nav .dropdown-menu a.dropdown-item {
  font-family: var(--mono);
  font-size: 11px;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--ink-dim);
  padding: 9px 14px;
}
body.pa .pa-nav .dropdown-menu a.dropdown-item:hover { color: var(--ink); background: rgba(var(--wash-rgb), 0.05); }

/* green goes quiet: outline by default everywhere... */
body.pa .btn-success {
  background: transparent;
  border: 1px solid var(--good);
  color: var(--good);
  font-weight: 600;
  box-shadow: none;
}
body.pa .btn-success:hover,
body.pa .btn-success:focus {
  background: rgba(var(--good-rgb), 0.12);
  border-color: var(--good);
  color: var(--good);
  box-shadow: none;
}
/* ...solid ONLY where money moves */
body.pa .payment-btn-container .btn-success,
body.pa--viewinvoice .btn-success,
body.pa--clientareaaddfunds .btn-success,
body.pa .invoice-payment-btn-container .btn-success {
  background: var(--good);
  border-color: var(--good);
  color: var(--on-good);
}
body.pa .payment-btn-container .btn-success:hover,
body.pa--viewinvoice .btn-success:hover {
  background: var(--good-hi);
  border-color: var(--good-hi);
  color: var(--on-good);
  box-shadow: var(--good-glow);
}

/* panel-header mini buttons (MY SERVICES / PAY NOW / RENEW NOW
   pills): quiet mono chips instead of solid color blocks */
body.pa .client-home-cards .card-header .btn,
body.pa .client-home-cards .card-header .btn[class*="bg-color-"] {
  background: transparent !important;
  border: 1px solid var(--line) !important;
  color: var(--ink-dim) !important;
  font-size: 10px;
  letter-spacing: 0.16em;
  padding: 4px 10px;
}
body.pa .client-home-cards .card-header .btn:hover {
  border-color: var(--red) !important;
  color: var(--ink) !important;
}

/* ============================================================
   11 TICKET ROOM + DROPDOWN PAINT ORDER (live round two)
   ============================================================ */

/* backdrop-filter turns .pa-head into an isolated stacking
   context, so its dropdowns painted UNDER the breadcrumb and
   sidebar that follow in the DOM — that was the "transparent"
   menu. Lift the whole header above page content. */
body.pa .pa-head { z-index: 300; }
body.pa .pa-nav .dropdown-menu {
  background: var(--menu-bg);
  box-shadow: var(--shadow-menu);
  padding: 6px 0;
}
/* no default focus box on click; keyboard focus keeps the ring */
body.pa .pa-nav a:focus:not(:focus-visible) { outline: 0; }

/* --- SimpleMDE / CodeMirror (the real ticket reply editor) ---
   Ships light everything; its toolbar colors carry !important. */
body.pa .editor-toolbar {
  background: rgba(var(--wash-rgb), 0.03);
  border: 1px solid var(--line);
  border-radius: var(--rad-sm) var(--rad-sm) 0 0;
  opacity: 1;
}
body.pa .editor-toolbar a,
body.pa .editor-toolbar button {
  color: var(--ink-dim) !important;
  background: transparent;
  border: 0;
}
body.pa .editor-toolbar a:hover,
body.pa .editor-toolbar button:hover,
body.pa .editor-toolbar a.active {
  background: rgba(var(--wash-rgb), 0.07);
  color: var(--ink) !important;
  border-radius: var(--rad-sm);
}
body.pa .editor-toolbar i.separator {
  border-left: 1px solid var(--line-soft);
  border-right: 0;
}
/* WHMCS drops its own Preview button into the toolbar */
body.pa .editor-toolbar .btn,
body.pa .editor-toolbar .btn-primary {
  background: transparent !important;
  border: 1px solid var(--line) !important;
  color: var(--ink-dim) !important;
  font-size: 10px;
  padding: 3px 10px;
  box-shadow: none;
}
body.pa .editor-toolbar .btn:hover {
  border-color: var(--red) !important;
  color: var(--ink) !important;
}
body.pa .CodeMirror {
  background: var(--input-fill);
  color: var(--ink);
  border: 1px solid var(--line);
  border-top: 0;
  border-radius: 0 0 var(--rad-sm) var(--rad-sm);
}
body.pa .CodeMirror-focused { border-color: var(--red); }
body.pa .CodeMirror-cursor { border-left: 1px solid var(--flame); }
body.pa .CodeMirror-selected,
body.pa .CodeMirror-focused .CodeMirror-selected { background: var(--selection); }
body.pa .CodeMirror-placeholder { color: var(--ink-placeholder) !important; }
body.pa .CodeMirror-gutters { background: transparent; border-right: 1px solid var(--line-soft); }
body.pa .editor-statusbar {
  color: var(--ink-dim);
  font-family: var(--mono);
  font-size: 10px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}
body.pa .editor-preview,
body.pa .editor-preview-side {
  background: var(--surface-opaque);
  color: var(--ink-dim);
  border: 1px solid var(--line);
}
/* fullscreen editing keeps the dark room and sits above the bar */
body.pa .editor-toolbar.fullscreen,
body.pa .CodeMirror-fullscreen,
body.pa .editor-preview-side {
  background: var(--surface-opaque);
  z-index: 400;
}

/* --- ticket message header strip (ships #f6f6f6 / #888) --- */
body.pa .view-ticket .posted-by {
  background-color: rgba(var(--wash-rgb), 0.03);
  color: var(--ink-dim);
  border-bottom: 1px solid var(--line-soft);
  font-family: var(--mono);
  font-size: 11px;
  letter-spacing: 0.06em;
}
body.pa .view-ticket .posted-by .posted-by-name { color: var(--ink); font-weight: 600; }

/* requestor badges: pastel blocks → house chips */
body.pa .requestor-type-operator { --pac: var(--flame); }
body.pa .requestor-type-owner { --pac: var(--good); }
body.pa .requestor-type-registereduser { --pac: var(--warn); }
body.pa .requestor-type-authorizeduser,
body.pa .requestor-type-subaccount { --pac: var(--ink-dim); }
body.pa .label.requestor-badge {
  background: transparent !important;
  border: 1px solid var(--pac, var(--line));
  color: var(--pac, var(--ink-dim));
}

/* ============================================================
   12 MD-EDITOR, FOR REAL THIS TIME
   The ticket reply editor is WHMCS's own bootstrap-markdown
   fork (.md-editor / .md-header / .md-input / .md-footer) and
   its shipped whites carry !important:
     .md-editor>.btn-toolbar{background-color:#fff!important}
     .md-editor>.md-preview,.md-editor>textarea.markdown-editor
       {background-color:#fff!important}
   So this block matches importance property for property.
   ============================================================ */
body.pa .md-editor {
  border: 1px solid var(--line) !important;
  border-radius: var(--rad-sm);
  background: transparent;
}
body.pa .md-editor > .md-header,
body.pa .md-editor .md-footer {
  background: rgba(var(--wash-rgb), 0.03) !important;
}
body.pa .md-editor > .btn-toolbar { background-color: rgba(var(--wash-rgb), 0.03) !important; }
body.pa .md-editor > .md-preview,
body.pa .md-editor > textarea.markdown-editor,
body.pa .md-editor > textarea {
  background-color: var(--input-fill) !important;
  color: var(--ink) !important;
  border-top: 1px solid var(--line-soft) !important;
  border-bottom: 1px solid var(--line-soft) !important;
}
body.pa .md-editor > textarea:focus,
body.pa .md-editor > textarea.markdown-editor:focus {
  background-color: rgba(var(--red-rgb), 0.05) !important;
  color: var(--ink) !important;
}
body.pa div.md-editor.active,
body.pa .md-editor.active {
  border-color: var(--red) !important;
  box-shadow: none !important;
}
body.pa .md-editor .md-footer {
  color: var(--ink-dim);
  font-family: var(--mono);
  font-size: 10px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}
body.pa .md-editor .md-controls .md-control { color: var(--ink-dim); }
body.pa .md-editor .md-controls .md-control:hover { color: var(--flame); }

/* toolbar buttons: quiet icons; WHMCS's Preview pill included */
body.pa .md-editor .md-header .btn,
body.pa .md-editor .btn-toolbar .btn {
  background: transparent !important;
  border: 0 !important;
  color: var(--ink-dim) !important;
  box-shadow: none !important;
}
body.pa .md-editor .md-header .btn:hover,
body.pa .md-editor .md-header .btn.active {
  background: rgba(var(--wash-rgb), 0.07) !important;
  color: var(--ink) !important;
  border-radius: var(--rad-sm);
}
body.pa .md-editor .md-header .btn-primary {
  border: 1px solid var(--line) !important;
  font-size: 10px;
  letter-spacing: 0.14em;
}
body.pa .md-editor .md-header .btn-primary:hover {
  border-color: var(--red) !important;
}

/* fullscreen mode ships background:#fff!important on everything */
body.pa .md-editor.md-fullscreen-mode { background: var(--surface-deep) !important; }
body.pa .md-editor.md-fullscreen-mode .md-input,
body.pa .md-editor.md-fullscreen-mode .md-preview {
  background: var(--surface-deep) !important;
  color: var(--ink) !important;
}
body.pa .md-editor.md-fullscreen-mode .md-input:focus,
body.pa .md-editor.md-fullscreen-mode .md-input:hover {
  background: var(--surface-deep) !important;
  color: var(--ink) !important;
}
body.pa .md-editor.md-fullscreen-mode .btn { color: var(--ink-dim) !important; }
body.pa .md-editor.md-fullscreen-mode .btn.active,
body.pa .md-editor.md-fullscreen-mode .btn:hover { color: var(--ink) !important; }
body.pa .md-editor.md-fullscreen-mode .md-fullscreen-controls a { color: var(--ink-dim); }
body.pa .md-editor.md-fullscreen-mode .md-fullscreen-controls a:hover { color: var(--flame); }

/* rendered markdown (ticket messages + preview) ships #333
   headings and light tables — unreadable on the dark ground */
body.pa .markdown-content h1, body.pa .md-preview h1,
body.pa .markdown-content h2, body.pa .md-preview h2,
body.pa .markdown-content h3, body.pa .md-preview h3,
body.pa .markdown-content h4, body.pa .md-preview h4 { color: var(--ink); }
body.pa .markdown-content blockquote, body.pa .md-preview blockquote {
  border-left: 2px solid var(--red);
  color: var(--ink-dim);
  background: rgba(var(--red-rgb), 0.04);
}
body.pa .markdown-content table, body.pa .md-preview table {
  background-color: transparent;
  border: 1px solid var(--line-soft);
}
body.pa .markdown-content table > thead > tr > th, body.pa .md-preview table > thead > tr > th {
  background-color: rgba(var(--wash-rgb), 0.03);
  border: 1px solid var(--line-soft);
  color: var(--ink);
}
body.pa .markdown-content table > tbody > tr > td, body.pa .md-preview table > tbody > tr > td {
  border: 1px solid var(--line-soft);
}

/* ============================================================
   13 TICKET THREAD RHYTHM
   twenty-one wraps every reply in its own .card-body with
   padding:0 and border-bottom:1px solid #ddd — that light rule
   was the stray white line over each posted-by strip, and the
   zero padding left our reply panels welded edge to edge.
   ============================================================ */
body.pa .view-ticket .card-body { border-bottom: 0; }
/* first .card-body is the title block; the rest are replies —
   give them breathing room so each reads as its own panel */
body.pa .view-ticket .card-body + .card-body { padding: 8px 14px; }
body.pa .view-ticket .card-body:last-child { padding-bottom: 16px; }
body.pa .view-ticket .ticket-reply { border-radius: var(--rad-sm); overflow: hidden; }
body.pa .view-ticket .posted-by { border-radius: var(--rad-sm) var(--rad-sm) 0 0; }
/* star rating: dim idle, flame on hover/active */
body.pa .ticket-reply .rating span.star:before,
body.pa .ticket-reply .rating-done span.star:before { color: var(--ink-faint); }
body.pa .ticket-reply .rating span.star:hover:before,
body.pa .ticket-reply .rating span.star:hover ~ span.star:before,
body.pa .ticket-reply .rating-done span.star.active:before { color: var(--warn); }

/* ============================================================
   14 MODE TOGGLE UI — header instrument + footer switch
   Icon and word states are pure CSS keyed on the root attribute;
   pa.js only flips data-theme and persists it.
   ============================================================ */
body.pa .pa-mode .pa-mode-ico-day { display: none; }
:root[data-theme="light"] body.pa .pa-mode .pa-mode-ico-night { display: none; }
:root[data-theme="light"] body.pa .pa-mode .pa-mode-ico-day { display: inline; }
/* the phone tool cluster is at capacity; the footer switch covers it */
@media (max-width: 575.98px) { body.pa .pa-mode { display: none; } }

body.pa .footer .pa-mode-switch {
  background: transparent;
  border: 0;
  padding-top: 0.5rem;
  padding-bottom: 0.5rem;
  cursor: pointer;
  color: var(--ink-faint);
  font-family: var(--mono);
  font-size: 11px;
  letter-spacing: 0.14em;
  text-transform: uppercase;
}
body.pa .footer .pa-mode-switch:hover { color: var(--ink-dim); }
body.pa .footer .pa-mode-switch .pa-mode-night { color: var(--ink); }
:root[data-theme="light"] body.pa .footer .pa-mode-switch .pa-mode-night { color: var(--ink-faint); }
:root[data-theme="light"] body.pa .footer .pa-mode-switch .pa-mode-day { color: var(--ink); }

/* light mode: the white wordmark (grayscale on transparent)
   inverts to ink with zero asset work */
:root[data-theme="light"] body.pa .pa-brand .logo-img { filter: invert(1); }
