:root {
  color-scheme: dark;
  --nx-bg: #040d18;
  --nx-bg-deep: #010711;
  --nx-surface: rgba(8, 24, 39, .94);
  --nx-surface-elevated: rgba(11, 31, 49, .96);
  --nx-surface-solid: #091d2f;
  --nx-border: rgba(78, 139, 175, .34);
  --nx-border-soft: rgba(111, 169, 201, .15);
  --nx-text: #f4f8fb;
  --nx-text-muted: #8fa9bb;
  --nx-primary: #3ec7ff;
  --nx-success: #13d9c0;
  --nx-warning: #ffb327;
  --nx-danger: #ff6257;
  --nx-gold: #e8b84a;
  --nx-gold-bright: #ffdd79;
  --nx-purple: #9b7dff;
  --nx-radius-sm: 8px;
  --nx-radius-md: 12px;
  --nx-radius-lg: 16px;
  --nx-shadow-panel: 0 18px 46px rgba(0, 0, 0, .34), 0 1px 0 rgba(255, 255, 255, .035) inset;
  --nx-shadow-floating: 0 28px 80px rgba(0, 0, 0, .44), 0 0 34px rgba(38, 148, 216, .055);
  --nx-transition-fast: 150ms;
  --nx-transition-normal: 220ms;

  /* Backwards-compatible aliases used by the established v3.1 component layer. */
  --bg: var(--nx-bg);
  --bg-deep: var(--nx-bg-deep);
  --panel: var(--nx-surface-solid);
  --panel-2: #0c263b;
  --line: var(--nx-border);
  --line-soft: var(--nx-border-soft);
  --text: var(--nx-text);
  --muted: var(--nx-text-muted);
  --teal: var(--nx-success);
  --teal-soft: rgba(19, 217, 192, .12);
  --gold: var(--nx-gold);
  --gold-bright: var(--nx-gold-bright);
  --gold-soft: rgba(232, 184, 74, .12);
  --blue: var(--nx-primary);
  --amber: var(--nx-warning);
  --red: var(--nx-danger);
  --shadow: var(--nx-shadow-panel);
  --radius: var(--nx-radius-lg);
}

* { box-sizing: border-box; }
[hidden] { display: none !important; }
input[type="hidden"] { display: none !important; }
html { min-height: 100%; background: var(--bg-deep); }
body {
  min-height: 100vh;
  margin: 0;
  background:
    radial-gradient(circle at 70% 0%, rgba(12, 90, 122, .16), transparent 34%),
    linear-gradient(145deg, var(--bg-deep), var(--bg));
  color: var(--text);
  font: 14px/1.45 Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}
a { color: var(--gold-bright); text-decoration: none; }
button, input, select { font: inherit; }
button, .button { cursor: pointer; }
h1, h2, p { margin-top: 0; }
h1 { margin-bottom: 5px; font-size: clamp(26px, 3vw, 38px); line-height: 1.12; letter-spacing: -.035em; }
h2 { margin-bottom: 8px; font-size: 19px; letter-spacing: -.02em; }
.muted, .page-heading p { color: var(--muted); }
.eyebrow { color: #74a8bd; font-size: 10px; font-weight: 800; letter-spacing: .15em; text-transform: uppercase; }
.mono { font-family: ui-monospace, SFMono-Regular, Menlo, monospace; font-size: 12px; }
.app-shell { min-height: 100vh; display: grid; grid-template-columns: 230px 1fr; }
.sidebar {
  position: fixed; inset: 0 auto 0 0; z-index: 20;
  display: flex; flex-direction: column; width: 230px;
  padding: 22px 11px 14px;
  border-right: 1px solid var(--line);
  background: rgba(3, 14, 24, .96);
  backdrop-filter: blur(20px);
}
.brand {
  display: flex; gap: 9px; align-items: center;
  padding: 0 11px 23px; color: var(--text); font-size: 19px; letter-spacing: -.04em;
}
.brand-logo {
  width: 38px; height: 38px; object-fit: contain;
  filter: drop-shadow(0 6px 12px rgba(232, 184, 74, .2));
}
.brand-name { color: var(--gold-bright); font-size: 17px; font-weight: 750; letter-spacing: .08em; }
.brand-product {
  padding: 4px 6px; border: 1px solid var(--line); border-radius: 5px;
  color: var(--gold-bright); font: 800 10px/1 ui-monospace, monospace; letter-spacing: .08em;
}
.brand-mark {
  display: inline-grid; place-items: center;
  width: 28px; height: 32px; overflow: hidden;
  color: var(--teal); font-size: 26px;
  filter: drop-shadow(0 0 15px rgba(19, 217, 192, .32));
}
.nav { display: grid; gap: 4px; overflow-y: auto; scrollbar-width: thin; }
.nav a, .nav-button {
  display: flex; gap: 12px; align-items: center; width: 100%;
  padding: 11px 13px; border: 0; border-radius: 8px;
  background: transparent; color: #afc1d0; text-align: left;
}
.nav a span { width: 20px; color: #a6b8c7; font-size: 18px; }
.nav-icon { display: inline-grid; flex: 0 0 20px; place-items: center; }
.nav-icon svg,
.metric-icon svg,
.map-node-icon svg {
  width: 100%;
  height: 100%;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.7;
  stroke-linecap: round;
  stroke-linejoin: round;
}
.nav a:hover, .nav a.active, .nav-button:hover { background: #292512; color: var(--gold-bright); }
.nav a.active { box-shadow: inset 3px 0 var(--gold); }
.nav a.active span { color: var(--gold-bright); }
.system-mini {
  margin-top: auto; padding: 14px; border: 1px solid var(--line); border-radius: 10px;
  background: linear-gradient(150deg, rgba(10, 37, 53, .7), rgba(5, 22, 35, .8));
}
.system-mini p { margin: 9px 0 4px; font-size: 12px; }
.system-mini small { color: var(--teal); font-size: 11px; }
.pulse { display: inline-block; width: 7px; height: 7px; border-radius: 50%; background: var(--teal); box-shadow: 0 0 0 5px rgba(19,217,192,.12); }
.logout { margin-top: 8px; }
.version { display: block; padding: 5px 13px 0; color: #4f7186; font: 10px/1 ui-monospace, monospace; }
.main { grid-column: 2; min-width: 0; }
.topbar {
  position: sticky; top: 0; z-index: 10;
  display: flex; align-items: center; justify-content: space-between; height: 67px;
  padding: 0 24px; border-bottom: 1px solid var(--line);
  background: rgba(5, 18, 30, .84); backdrop-filter: blur(18px);
}
.menu-toggle { display: none; border: 0; background: transparent; color: white; font-size: 0; }
.menu-toggle::before,
.public-menu-toggle::before {
  content: "";
  display: block;
  width: 18px;
  height: 14px;
  margin: auto;
  background:
    linear-gradient(currentColor, currentColor) top / 100% 2px no-repeat,
    linear-gradient(currentColor, currentColor) center / 100% 2px no-repeat,
    linear-gradient(currentColor, currentColor) bottom / 100% 2px no-repeat;
}
.status-chip {
  display: inline-flex; align-items: center; padding: 5px 9px;
  border: 1px solid rgba(19, 217, 192, .52); border-radius: 5px;
  color: var(--teal); background: rgba(19, 217, 192, .05);
  font: 700 10px/1 ui-monospace, monospace; letter-spacing: .08em;
}
.identity { display: flex; align-items: center; gap: 9px; }
.topbar-actions { display: flex; align-items: center; gap: 17px; }
.identity > span:last-child { display: grid; }
.identity small, .person small { color: var(--muted); font-size: 11px; }
.avatar {
  display: inline-grid; flex: 0 0 auto; place-items: center;
  width: 34px; height: 34px; border: 1px solid rgba(19,217,192,.35);
  border-radius: 50%; background: #0b3b45; color: var(--teal); font-weight: 750; text-transform: uppercase;
}
.avatar.small { width: 31px; height: 31px; }
.content { max-width: 1500px; margin: 0 auto; padding: 26px 24px 50px; }
.page-heading {
  display: flex; align-items: flex-end; justify-content: space-between; gap: 20px;
  margin-bottom: 20px;
}
.page-heading p { margin-bottom: 0; }
.heading-actions { display: flex; align-items: center; gap: 9px; }
.heading-actions form { margin: 0; }
.back { display: inline-block; margin-bottom: 12px; color: var(--muted); }
.button {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  min-height: 40px; padding: 0 15px; border: 1px solid var(--line); border-radius: 7px;
  background: transparent; color: var(--text); font-weight: 700;
}
.button.primary { border-color: var(--gold); background: linear-gradient(135deg, #f5cf68, #d99a25); color: #251600; box-shadow: 0 8px 30px rgba(232,184,74,.14); }
.button.secondary { background: #0d2638; color: #d5e2ea; }
.button.danger { border-color: rgba(255,98,87,.45); background: rgba(255,98,87,.08); color: #ff8b83; }
.button.wide { width: 100%; }
.button.compact { min-height: 32px; padding: 0 10px; font-size: 11px; }
.panel {
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: linear-gradient(150deg, rgba(12, 34, 52, .96), rgba(7, 23, 38, .96));
  box-shadow: var(--shadow);
}
.panel-head {
  display: flex; align-items: center; justify-content: space-between; gap: 16px;
  padding: 16px 18px; border-bottom: 1px solid var(--line-soft);
}
.panel-head h2 { margin: 4px 0 0; }
.panel-head a { font-size: 12px; }
.metric-grid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 14px; margin-bottom: 14px; }
.metric-grid.compact { grid-template-columns: repeat(2, minmax(220px, 1fr)); max-width: 650px; }
.metric {
  position: relative; display: flex; align-items: center; gap: 15px; min-height: 126px;
  padding: 19px; overflow: hidden; border: 1px solid var(--line); border-radius: 12px;
  background: linear-gradient(145deg, #0d2538, #081a2a);
}
.metric::after {
  content: ""; position: absolute; width: 120px; height: 120px; right: -50px; bottom: -65px;
  border-radius: 50%; background: currentColor; opacity: .04;
}
.metric.teal { color: var(--teal); } .metric.amber { color: var(--amber); } .metric.blue { color: var(--blue); } .metric.red { color: var(--red); }
.metric-icon { display: grid; place-items: center; flex: 0 0 49px; width: 49px; height: 49px; border: 1px solid currentColor; border-radius: 50%; background: color-mix(in srgb, currentColor 10%, transparent); font-size: 23px; }
.metric > div:last-child { display: grid; }
.metric span { color: #b4c4d1; font-size: 12px; }
.metric strong { color: var(--text); font-size: 32px; line-height: 1.15; letter-spacing: -.04em; }
.metric strong.metric-time { font-size: 21px; letter-spacing: -.02em; }
.metric small { color: var(--muted); font-size: 10px; }
.dashboard-grid { display: grid; grid-template-columns: minmax(0, 2fr) minmax(260px, .85fr); gap: 14px; margin-bottom: 14px; }
.dashboard-grid > .span-2 { grid-column: 1; }
.dashboard-signal-grid { display: grid; grid-template-columns: minmax(0, 1.45fr) minmax(320px, .55fr); gap: 14px; margin-bottom: 14px; }
.dashboard-stack { display: grid; gap: 14px; align-content: start; }
.dashboard-user-list { margin-bottom: 14px; }
.network-panel { min-width: 0; }
.network-status { color: var(--muted); font: 700 10px/1 ui-monospace, monospace; text-transform: uppercase; }
.network-status.live { color: var(--teal); }
.network-status.error { color: var(--red); }
.network-summary { display: flex; align-items: center; gap: 24px; padding: 13px 18px 0; }
.network-summary > div { display: grid; grid-template-columns: 8px auto auto auto; align-items: baseline; gap: 7px; }
.network-summary i { width: 7px; height: 7px; border-radius: 50%; background: var(--teal); box-shadow: 0 0 8px var(--teal); }
.network-summary i.tx { background: var(--blue); box-shadow: 0 0 8px var(--blue); }
.network-summary span, .network-summary small { color: var(--muted); font-size: 10px; }
.network-summary strong { font-size: 20px; }
.network-summary > small { margin-left: auto; }
.network-chart-wrap { height: 210px; padding: 8px 14px 14px; }
.network-chart-wrap canvas { width: 100%; height: 100%; }
.notification-list { display: grid; }
.notification-list > a { display: grid; grid-template-columns: 8px minmax(0, 1fr) auto; align-items: center; gap: 10px; padding: 14px 16px; border-bottom: 1px solid var(--line-soft); color: var(--text); }
.notification-list > a:last-child { border-bottom: 0; }
.notification-list > a:hover { background: rgba(19, 217, 192, .03); }
.notification-list a > span:nth-child(2) { display: grid; min-width: 0; }
.notification-list small { overflow: hidden; color: var(--muted); font-size: 11px; text-overflow: ellipsis; white-space: nowrap; }
.notification-list time { color: #6f8b9d; font: 10px/1.3 ui-monospace, monospace; text-align: right; }
.distribution { display: grid; grid-template-columns: 128px 1fr; gap: 18px; align-items: center; padding: 20px; }
.donut {
  display: grid; place-items: center; width: 128px; height: 128px; border-radius: 50%;
  background: var(--distribution); box-shadow: 0 0 35px rgba(19,217,192,.08);
}
.donut::before { content: ""; grid-area: 1 / 1; width: 80px; height: 80px; border-radius: 50%; background: #081b2b; box-shadow: inset 0 0 0 1px var(--line); }
.donut span { z-index: 1; grid-area: 1 / 1; display: grid; text-align: center; }
.donut strong { font-size: 25px; line-height: 1; }
.donut small { margin-top: 4px; color: var(--muted); font-size: 10px; }
.chart-legend { display: grid; gap: 8px; }
.chart-legend div { display: grid; grid-template-columns: 8px 1fr auto; gap: 8px; align-items: center; }
.chart-legend i { width: 7px; height: 7px; border-radius: 50%; background: var(--legend-color); box-shadow: 0 0 8px var(--legend-color); }
.chart-legend span { color: #aabfcd; font-size: 11px; }
.chart-legend b { font-size: 12px; }
.status-list { padding: 8px 16px; }
.status-list div { display: flex; align-items: center; justify-content: space-between; gap: 15px; padding: 15px 0; border-bottom: 1px solid var(--line-soft); }
.status-list div:last-child { border: 0; }
.status-list b { color: #a9becd; font-size: 11px; font-weight: 500; white-space: nowrap; }
.status-list i { display: inline-block; width: 7px; height: 7px; margin-left: 6px; border-radius: 50%; background: var(--teal); box-shadow: 0 0 9px var(--teal); }
.status-list i.off { background: var(--red); box-shadow: 0 0 9px rgba(255,98,87,.5); }
.table-wrap { overflow-x: auto; }
table { width: 100%; border-collapse: collapse; text-align: left; }
th { padding: 11px 14px; color: #87a2b5; background: rgba(2, 13, 23, .3); font-size: 10px; letter-spacing: .05em; text-transform: uppercase; }
td { padding: 11px 14px; border-top: 1px solid var(--line-soft); color: #d4e0e9; font-size: 12px; }
tbody tr:hover { background: rgba(19, 217, 192, .025); }
.person { display: flex; align-items: center; gap: 9px; min-width: 180px; }
.person > span:last-child { display: grid; }
.cell-sub { display: block; color: var(--muted); font-size: 10px; }
.empty { padding: 28px; color: var(--muted); text-align: center; }
.icon-link { display: grid; place-items: center; width: 28px; height: 28px; border: 1px solid var(--line); border-radius: 6px; }
.badge {
  display: inline-flex; align-items: center; padding: 4px 7px;
  border: 1px solid #3b5567; border-radius: 5px; background: rgba(78, 111, 132, .08);
  color: #aec0cc; font: 700 10px/1 ui-monospace, monospace; text-transform: uppercase;
}
.badge.active { border-color: rgba(19,217,192,.45); color: var(--teal); background: var(--teal-soft); }
.badge.expired, .badge.disabled { border-color: rgba(255,98,87,.45); color: #ff837a; background: rgba(255,98,87,.09); }
.badge.large { padding: 7px 11px; }
.event-row { display: grid; grid-template-columns: repeat(4, minmax(160px, 1fr)); }
.event-row > div { display: flex; align-items: center; gap: 10px; padding: 16px 18px; border-right: 1px solid var(--line-soft); }
.event-row > div:last-child { border: 0; }
.event-row span:last-child { display: grid; }
.event-row small { color: var(--muted); }
.event-dot { width: 7px; height: 7px; border-radius: 50%; background: var(--teal); }
.filters { display: flex; gap: 9px; padding: 15px; border-bottom: 1px solid var(--line-soft); }
.filters input { flex: 1; min-width: 180px; }
label { display: grid; gap: 7px; margin-bottom: 16px; color: #c8d6df; font-size: 12px; font-weight: 650; }
input, select {
  min-height: 43px; width: 100%; padding: 0 12px;
  border: 1px solid #24485d; border-radius: 7px; outline: none;
  background: #071725; color: var(--text);
}
input:focus, select:focus { border-color: var(--gold); box-shadow: 0 0 0 3px rgba(232,184,74,.1); }
label small { color: var(--muted); font-weight: 400; }
.check { display: flex; grid-template-columns: none; flex-direction: row; align-items: center; gap: 8px; font-weight: 450; }
.check input { min-height: 0; width: 15px; height: 15px; accent-color: var(--teal); }
.form-layout { display: grid; grid-template-columns: minmax(0, 1.4fr) minmax(300px, .6fr); gap: 15px; align-items: start; }
.form-card { padding: 22px; }
.form-card h2 { margin-top: 5px; margin-bottom: 20px; }
.form-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 0 14px; }
.span-2 { grid-column: span 2; }
.notice { margin: 7px 0 18px; padding: 12px; border-left: 2px solid var(--teal); background: var(--teal-soft); color: #a8c3cd; font-size: 11px; }
.narrow { max-width: 850px; }
.detail-grid, .customer-grid { display: grid; grid-template-columns: minmax(0, 1fr) minmax(320px, .8fr); gap: 15px; align-items: start; }
.sensitive { border-color: rgba(255,179,39,.24); }
.destructive { grid-column: 1 / -1; border-color: rgba(255,98,87,.32); }
.destructive .eyebrow { color: #ff8b83; }
.detail-list { margin: 0; }
.detail-list div { display: flex; justify-content: space-between; gap: 18px; padding: 12px 0; border-bottom: 1px solid var(--line-soft); }
.detail-list dt { color: var(--muted); }
.detail-list dd { margin: 0; text-align: right; }
.inline-actions { display: flex; gap: 9px; margin-top: 18px; }
.flash { margin-bottom: 14px; padding: 11px 13px; border: 1px solid var(--line); border-radius: 7px; background: #0d2737; }
.flash.success { border-color: rgba(19,217,192,.4); color: #91f5e7; }
.flash.error { border-color: rgba(255,98,87,.42); color: #ffaaa4; background: rgba(255,98,87,.07); }
.subscription-card { position: relative; min-height: 290px; padding: 25px; }
.subscription-card h2 { margin-top: 6px; font-size: 34px; }
.subscription-card > div:nth-child(2) { position: relative; z-index: 2; margin-top: 72px; }
.stream-art {
  position: absolute; width: 240px; height: 240px; right: -50px; top: 20px;
  display: grid; place-items: center; border: 1px solid rgba(19,217,192,.15); border-radius: 50%;
  background: radial-gradient(circle, rgba(19,217,192,.15), transparent 64%);
}
.stream-art::before, .stream-art::after { content: ""; position: absolute; inset: 25px; border: 1px solid rgba(19,217,192,.13); border-radius: 50%; }
.stream-art::after { inset: 55px; }
.stream-art span { color: var(--teal); font-size: 50px; filter: drop-shadow(0 0 20px rgba(19,217,192,.5)); }
.payment-plan-form { margin-top: 20px; }
.payment-plan-form fieldset { margin: 0; padding: 0; border: 0; }
.payment-plan-form legend { margin-bottom: 10px; color: #c8d6df; font-size: 12px; font-weight: 650; }
.plan-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.plan-choice { position: relative; margin: 0; cursor: pointer; }
.plan-choice input {
  position: absolute; width: 1px; height: 1px; min-height: 0; padding: 0;
  opacity: 0; pointer-events: none;
}
.plan-card {
  display: grid; gap: 2px; min-height: 130px; padding: 16px;
  border: 1px solid var(--line); border-radius: 10px; background: #071725; color: var(--text); text-align: left;
  transition: border-color .15s ease, background .15s ease, box-shadow .15s ease, transform .15s ease;
}
.plan-card.featured { border-color: rgba(19,217,192,.38); background: var(--teal-soft); }
.plan-card strong { color: var(--teal); font-size: 28px; }
.plan-card small { color: var(--muted); }
.plan-choice:hover .plan-card { border-color: rgba(232,184,74,.62); transform: translateY(-1px); }
.plan-choice input:checked + .plan-card {
  border-color: var(--gold); background: rgba(232,184,74,.11);
  box-shadow: 0 0 0 3px rgba(232,184,74,.12);
}
.plan-choice input:focus-visible + .plan-card { outline: 2px solid var(--teal); outline-offset: 3px; }
.payment-selection-help { margin: 12px 0; color: var(--muted); font-size: 11px; }
.payment-plan-form button[disabled] { cursor: wait; opacity: .72; }
.access-panel { margin-top: 15px; }
.access-grid { display: grid; grid-template-columns: 1.1fr .9fr; gap: 30px; padding: 22px; }
.access-grid h3 { margin: 0 0 14px; font-size: 15px; }
.steps { display: grid; gap: 11px; margin: 0; padding-left: 22px; color: #b9cbd7; }
.steps code {
  display: inline-block; padding: 3px 6px; border: 1px solid var(--line);
  border-radius: 4px; background: #04111d; color: var(--teal); word-break: break-all;
}
.download-links { display: grid; gap: 8px; }
.download-links a {
  display: flex; align-items: center; justify-content: space-between; gap: 12px;
  padding: 11px 12px; border: 1px solid var(--line); border-radius: 7px;
  background: #071725; color: #dbe7ef;
}
.download-links a:hover { border-color: rgba(19,217,192,.52); }
.download-links small { color: var(--teal); }
.support-note { margin: 14px 0 0; color: var(--muted); font-size: 12px; }
.account-panel { margin-top: 15px; scroll-margin-top: 82px; }
.account-security-grid { display: grid; grid-template-columns: minmax(260px, .8fr) minmax(320px, 1.2fr); gap: 38px; padding: 24px; }
.account-security-grid h3 { margin: 0 0 10px; font-size: 17px; }
.account-security-grid code { display: inline-block; padding: 6px 9px; border: 1px solid var(--line); border-radius: 6px; background: #04111d; color: var(--gold-bright); }
.account-security-grid form { margin: 0; }
.security-lock { display: grid; place-items: center; width: 36px; height: 36px; border: 1px solid rgba(232,184,74,.35); border-radius: 50%; color: var(--gold-bright); background: var(--gold-soft); }
.public-shell { min-height: 100vh; }
.public-header {
  position: sticky; top: 0; z-index: 50;
  display: grid; grid-template-columns: auto 1fr auto; align-items: center; gap: 28px;
  min-height: 72px; padding: 10px clamp(18px, 4vw, 58px); border-bottom: 1px solid rgba(232,184,74,.19);
  background: rgba(3, 13, 23, .94); box-shadow: 0 12px 40px rgba(0,0,0,.18); backdrop-filter: blur(18px);
}
.public-brand { display: inline-flex; align-items: center; gap: 8px; color: var(--gold-bright); font-size: 16px; font-weight: 800; letter-spacing: .08em; }
.public-brand img { width: 40px; height: 40px; object-fit: contain; filter: drop-shadow(0 5px 11px rgba(232,184,74,.22)); }
.public-brand b { padding: 4px 6px; border: 1px solid var(--line); border-radius: 5px; font: 800 9px/1 ui-monospace, monospace; letter-spacing: .08em; }
.public-nav { display: flex; align-items: center; justify-content: flex-end; gap: clamp(12px, 2.2vw, 30px); }
.public-nav a { color: #c8d4dc; font-size: 12px; font-weight: 650; white-space: nowrap; }
.public-nav a:hover { color: var(--gold-bright); }
.public-nav .public-login-link { padding: 8px 12px; border: 1px solid rgba(232,184,74,.38); border-radius: 7px; color: var(--gold-bright); background: var(--gold-soft); }
.public-nav .public-login-link.active { border-color: var(--gold); box-shadow: inset 0 0 0 1px rgba(232,184,74,.12); }
.public-menu-toggle { display: none; border: 0; background: transparent; color: var(--gold-bright); font-size: 0; }
.public-header-language { justify-self: end; }
.public-page { min-height: calc(100vh - 72px); }
.login-layout { min-height: calc(100vh - 72px); display: grid; grid-template-columns: minmax(420px, 1.2fr) minmax(420px, .8fr); }
.language-switch {
  display: inline-flex; align-items: center; gap: 7px;
  padding: 6px 9px; border: 1px solid var(--line); border-radius: 7px;
  background: rgba(4, 18, 29, .72); color: #607e90;
  font: 750 11px/1 ui-monospace, monospace; letter-spacing: .06em;
}
.language-switch a { color: #7894a7; }
.language-switch a:hover, .language-switch a.active { color: var(--gold-bright); }
.language-switch.compact { padding: 5px 8px; }
.login-visual {
  position: relative; display: flex; flex-direction: column; justify-content: space-between; min-height: calc(100vh - 72px);
  padding: 42px clamp(42px, 6vw, 90px);
  overflow: hidden; background:
    linear-gradient(rgba(4,18,29,.5), rgba(4,18,29,.94)),
    radial-gradient(circle at 70% 40%, rgba(232,184,74,.2), transparent 26%),
    linear-gradient(135deg, #061624, #0a3040);
}
.hero-brand { position: relative; z-index: 2; display: flex; align-items: center; gap: 13px; }
.hero-brand img { width: min(245px, 46vw); height: 128px; object-fit: contain; object-position: left center; filter: drop-shadow(0 12px 25px rgba(232,184,74,.15)); }
.login-visual .status-chip { border-color: rgba(232,184,74,.52); color: var(--gold-bright); background: var(--gold-soft); }
.login-visual > div:nth-child(2) { position: relative; z-index: 2; max-width: 710px; margin: auto 0; }
.login-visual h1 { margin: 18px 0; font-size: clamp(40px, 5vw, 72px); }
.login-visual p { max-width: 600px; color: #a5bac8; font-size: 17px; }
.hero-contact { display: inline-flex; align-items: center; gap: 18px; padding: 10px 13px; border-left: 2px solid var(--gold); background: rgba(3,13,23,.4); color: var(--text); }
.hero-contact > span { display: grid; gap: 2px; }
.hero-contact small { color: #8fa5b3; font-size: 9px; font-weight: 800; letter-spacing: .12em; text-transform: uppercase; }
.hero-contact strong { color: var(--gold-bright); font-size: 13px; }
.hero-contact b { color: var(--gold-bright); font-size: 16px; }
.visual-grid { position: absolute; inset: 0; opacity: .16; background-image: linear-gradient(var(--line) 1px, transparent 1px), linear-gradient(90deg, var(--line) 1px, transparent 1px); background-size: 52px 52px; mask-image: linear-gradient(to bottom right, transparent, black, transparent); }
.login-panel { display: grid; place-items: center; min-height: calc(100vh - 72px); padding: 28px; background: rgba(3,13,23,.7); }
.login-card { width: min(410px, 100%); padding: 34px; border: 1px solid var(--line); border-radius: 16px; background: rgba(10,27,44,.72); box-shadow: var(--shadow); }
.login-card h2 { margin: 8px 0 6px; font-size: 30px; }
.registration-card { width: min(600px, 100%); padding: 30px; }
.registration-layout .login-panel { padding-top: 32px; }
.auth-link { margin: 18px 0 0; color: var(--muted); text-align: center; font-size: 12px; }
.password-help { margin: -8px 0 15px; text-align: right; font-size: 12px; }
.terms-check { align-items: flex-start; margin: 3px 0 20px; line-height: 1.5; }
.terms-check input { margin-top: 3px; }
.captcha-wrap { min-height: 78px; margin: 0 0 20px; overflow-x: auto; }
.terms-page { min-height: calc(100vh - 72px); padding: 52px 20px 70px; }
.terms-card { max-width: 850px; margin: 0 auto; padding: 34px; }
.terms-brand { display: flex; align-items: center; gap: 12px; width: fit-content; padding-bottom: 30px; }
.terms-brand img { width: 185px; height: 112px; object-fit: contain; object-position: left center; }
.terms-card h1 { margin-top: 8px; }
.terms-sections { display: grid; gap: 0; margin: 26px 0; }
.terms-sections section { padding: 17px 0; border-top: 1px solid var(--line-soft); }
.terms-sections h2 { margin-bottom: 6px; }
.terms-sections p { margin-bottom: 0; color: #a9bdca; }
.terms-sections p + p { margin-top: 10px; }

@media (max-width: 1100px) {
  .metric-grid { grid-template-columns: repeat(2, 1fr); }
  .event-row { grid-template-columns: repeat(2, 1fr); }
  .dashboard-grid { grid-template-columns: 1fr; }
  .dashboard-signal-grid { grid-template-columns: 1fr; }
}
@media (max-width: 820px) {
  .app-shell { display: block; }
  .sidebar { transform: translateX(-101%); transition: transform .22s ease; box-shadow: 20px 0 60px rgba(0,0,0,.45); }
  .sidebar.open { transform: translateX(0); }
  .main { grid-column: auto; }
  .menu-toggle { display: block; }
  .topbar { padding: 0 16px; }
  .content { padding: 20px 15px 45px; }
  .form-layout, .detail-grid, .customer-grid, .access-grid, .account-security-grid { grid-template-columns: 1fr; }
  .login-layout { grid-template-columns: 1fr; }
  .login-visual { display: none; }
  .public-home-layout .login-visual { display: flex; min-height: auto; gap: 22px; padding: 30px 24px 34px; }
  .public-home-layout .hero-brand img { width: 180px; height: 96px; }
  .public-home-layout .group-intro { max-width: 680px; margin: 0; }
  .public-home-layout .login-visual h1 { margin: 14px 0; font-size: clamp(31px, 8vw, 46px); }
  .public-home-layout .login-visual p { font-size: 15px; }
  .public-home-layout .login-panel { min-height: auto; padding: 34px 16px 46px; }
  .public-header { grid-template-columns: auto 1fr auto; gap: 12px; }
  .public-menu-toggle { display: block; justify-self: end; }
  .public-nav {
    position: absolute; top: calc(100% + 1px); left: 14px; right: 14px;
    display: none; align-items: stretch; gap: 3px; padding: 10px; border: 1px solid var(--line); border-radius: 10px;
    background: rgba(3,13,23,.98); box-shadow: var(--shadow);
  }
  .public-nav.open { display: grid; }
  .public-nav a { padding: 11px 12px; border-radius: 6px; }
  .public-nav a:hover { background: var(--gold-soft); }
  .public-header-language { grid-column: 3; grid-row: 1; }
  .public-menu-toggle { grid-column: 2; grid-row: 1; }
}
@media (max-width: 560px) {
  .metric-grid, .metric-grid.compact, .form-grid, .plan-grid { grid-template-columns: 1fr; }
  .metric { min-height: 110px; }
  .span-2 { grid-column: auto; }
  .page-heading { align-items: stretch; flex-direction: column; }
  .page-heading .button { align-self: stretch; }
  .heading-actions { align-items: stretch; flex-direction: column; }
  .heading-actions form, .heading-actions button, .heading-actions .button { width: 100%; }
  .filters { flex-direction: column; }
  .identity > span:last-child { display: none; }
  .topbar-actions { gap: 9px; }
  .public-header { min-height: 66px; padding: 8px 13px; }
  .public-brand span { display: none; }
  .public-brand img { width: 36px; height: 36px; }
  .public-page, .login-layout, .login-panel { min-height: calc(100vh - 66px); }
  .public-home-layout .hero-contact { width: 100%; justify-content: space-between; }
  .event-row { grid-template-columns: 1fr; }
  .distribution { grid-template-columns: 1fr; justify-items: center; width: 100%; }
  .chart-legend { width: 100%; }
  .network-summary { align-items: flex-start; flex-wrap: wrap; gap: 12px 20px; }
  .network-summary > small { width: 100%; margin-left: 0; }
  .notification-list > a { grid-template-columns: 8px minmax(0, 1fr); }
  .notification-list time { grid-column: 2; text-align: left; }
}

textarea {
  width: 100%; padding: 11px 12px; resize: vertical;
  border: 1px solid #24485d; border-radius: 7px; outline: none;
  background: #071725; color: var(--text); font: inherit;
}
textarea:focus { border-color: var(--gold); box-shadow: 0 0 0 3px rgba(232,184,74,.1); }
.operations-section { margin-bottom: 15px; }
.session-summary-row { display: flex; align-items: center; justify-content: space-between; gap: 22px; padding: 20px; }
.session-summary-row p { max-width: 760px; margin: 0; }
.session-summary-row .inline-actions { margin: 0; }
.security-actions-panel { margin-bottom: 15px; }
.security-action-grid { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 18px 24px; align-items: center; padding: 22px; }
.security-action-grid h3 { margin: 0 0 5px; font-size: 15px; }
.security-action-grid p { margin: 0; }
.security-action-grid form { margin: 0; }
.attention-filters select { min-width: 155px; }
.attention-list { display: grid; gap: 12px; padding: 16px; }
.attention-card { padding: 18px; border: 1px solid var(--line); border-left-width: 3px; border-radius: 10px; background: rgba(4,18,29,.54); }
.attention-card.severity-critical { border-left-color: var(--red); }
.attention-card.severity-high { border-left-color: var(--amber); }
.attention-card.severity-warning { border-left-color: var(--gold); }
.attention-card.severity-info { border-left-color: var(--blue); }
.attention-card-head, .attention-card-head > div { display: flex; align-items: center; justify-content: space-between; gap: 7px; }
.attention-card h2 { margin: 13px 0 5px; }
.attention-card > p { color: #b5c7d3; }
.attention-meta { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 1px; margin: 15px 0; background: var(--line-soft); }
.attention-meta div { min-width: 0; padding: 10px; background: #071725; }
.attention-meta dt { color: var(--muted); font-size: 10px; text-transform: uppercase; }
.attention-meta dd { margin: 4px 0 0; overflow-wrap: anywhere; }
.attention-recommendation { padding: 12px; border-left: 2px solid var(--gold); background: var(--gold-soft); color: #c7d4dc; }
.attention-actions { display: grid; gap: 10px; margin-top: 14px; }
.attention-actions > div { display: flex; flex-wrap: wrap; gap: 8px; }
.attention-actions.inline { display: flex; align-items: center; }
.badge.severity.critical { border-color: rgba(255,98,87,.55); color: #ff8b83; background: rgba(255,98,87,.1); }
.badge.severity.high, .badge.severity.warning { border-color: rgba(255,179,39,.55); color: #ffc45c; background: rgba(255,179,39,.09); }
.badge.severity.info { border-color: rgba(62,199,255,.5); color: var(--blue); }
.health-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 14px; }
.health-card { padding-bottom: 4px; border-top-width: 3px; }
.health-card.status-healthy { border-top-color: var(--teal); }
.health-card.status-degraded { border-top-color: var(--amber); }
.health-card.status-failed { border-top-color: var(--red); }
.health-card.status-unknown, .health-card.status-not_configured { border-top-color: #607e90; }
.health-card-head { display: flex; align-items: center; justify-content: space-between; gap: 15px; padding: 18px 18px 0; }
.health-card-head h2 { margin-top: 4px; }
.health-card > p { min-height: 52px; margin: 7px 18px 12px; color: #aec0cc; }
.badge.health.healthy { border-color: rgba(19,217,192,.45); color: var(--teal); }
.badge.health.degraded, .badge.health.warning { border-color: rgba(255,179,39,.45); color: var(--amber); }
.badge.health.drift { border-color: rgba(232,184,74,.58); color: var(--gold-bright); background: var(--gold-soft); }
.badge.health.failed { border-color: rgba(255,98,87,.45); color: var(--red); }
.badge.health.unknown { border-color: rgba(96,126,144,.55); color: #90a9b8; }
.operations-section { margin-bottom: 15px; }
.operations-metrics { max-width: none; }
.integrity-summary { display: flex; flex-wrap: wrap; gap: 8px; padding: 14px 18px; border-bottom: 1px solid var(--line-soft); }
.operations-two-column { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 15px; margin-bottom: 15px; }
.evidence-list { padding: 7px 18px; }
.evidence-message { min-height: 48px; margin: 0; padding: 16px 18px 0; color: #b7c9d4; }
.safe-boundary, .lifecycle-boundary { margin: 0; padding: 13px 18px; border-top: 1px solid var(--line-soft); background: rgba(19,217,192,.035); color: var(--muted); font-size: 11px; }
.lifecycle-filters b { margin-left: 4px; color: var(--text); }
.lifecycle-boundary { border-top: 0; border-bottom: 1px solid var(--line-soft); }
.lifecycle-badges { min-width: 220px; }
.lifecycle-badges .badge { margin: 2px 3px 2px 0; }
.compact-list { padding: 0 18px 10px; }
.compact-list div { padding: 9px 0; }
.admin-metadata-grid { display: grid; grid-template-columns: minmax(0, .8fr) minmax(0, 1.2fr); gap: 28px; padding: 20px; }
.admin-metadata-grid h3 { margin-top: 0; }
.inline-form { display: flex; gap: 8px; margin-top: 14px; }
.inline-form input { min-width: 0; }
.tag-list { display: flex; flex-wrap: wrap; gap: 7px; }
.tag-list form { display: inline-flex; align-items: center; overflow: hidden; border: 1px solid rgba(232,184,74,.35); border-radius: 999px; background: var(--gold-soft); }
.tag-list span { padding: 5px 4px 5px 10px; color: var(--gold-bright); font-size: 11px; }
.tag-list button { padding: 4px 9px 5px 5px; border: 0; background: transparent; color: var(--gold-bright); }
.private-note-list { display: grid; gap: 10px; padding: 0 20px 20px; }
.private-note-list form { padding: 14px; border: 1px solid var(--line-soft); border-radius: 9px; background: rgba(3,13,23,.38); }
.private-note-list form > div { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-top: 9px; }
.private-note-list form > div > span { display: flex; gap: 7px; }
.private-note-list small { color: var(--muted); }
.timeline-filters { display: flex; flex-wrap: wrap; gap: 7px; padding: 14px 18px; border-bottom: 1px solid var(--line-soft); }
.timeline-filters a { padding: 6px 10px; border: 1px solid var(--line); border-radius: 999px; color: #a8bdca; font-size: 11px; }
.timeline-filters a.active { border-color: var(--gold); background: var(--gold-soft); color: var(--gold-bright); }
.timeline-list { padding: 5px 20px 20px; }
.timeline-entry { position: relative; display: grid; grid-template-columns: 18px minmax(0, 1fr); gap: 12px; }
.timeline-entry::before { content: ""; position: absolute; left: 6px; top: 0; bottom: 0; width: 1px; background: var(--line); }
.timeline-marker { position: relative; z-index: 1; width: 13px; height: 13px; margin-top: 25px; border: 3px solid #0a1b2c; border-radius: 50%; background: var(--teal); box-shadow: 0 0 10px rgba(19,217,192,.4); }
.timeline-entry.outcome-failure .timeline-marker { background: var(--red); box-shadow: 0 0 10px rgba(255,98,87,.4); }
.timeline-body { margin: 8px 0; padding: 14px; border: 1px solid var(--line-soft); border-radius: 9px; background: rgba(4,18,29,.48); }
.timeline-head { display: flex; align-items: flex-start; justify-content: space-between; gap: 16px; }
.timeline-head > div { display: flex; align-items: center; gap: 9px; }
.timeline-head h3 { margin: 0; font-size: 14px; }
.timeline-head time { color: var(--muted); font: 10px/1.4 ui-monospace, monospace; white-space: nowrap; }
.timeline-event-type { margin: 9px 0; color: #6f8da0; }
.timeline-meta { display: flex; flex-wrap: wrap; gap: 12px 24px; margin: 0; }
.timeline-meta div { display: flex; align-items: center; gap: 7px; }
.timeline-meta dt { color: var(--muted); font-size: 10px; }
.timeline-meta dd { margin: 0; font-size: 11px; }

@media (max-width: 1100px) {
  .health-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .attention-meta { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (max-width: 820px) {
  .health-grid, .admin-metadata-grid, .operations-two-column { grid-template-columns: 1fr; }
  .session-summary-row, .security-action-grid { align-items: stretch; grid-template-columns: 1fr; }
  .session-summary-row { flex-direction: column; }
}
@media (max-width: 560px) {
  .attention-meta { grid-template-columns: 1fr; }
  .timeline-head, .timeline-head > div { align-items: flex-start; flex-direction: column; }
  .timeline-meta { display: grid; }
  .inline-form, .private-note-list form > div { align-items: stretch; flex-direction: column; }
}

/* --------------------------------------------------------------------------
   v3.1.4 NextOne Operational Command visual layer
   Presentation-only: shared depth, atmosphere and component refinement.
   -------------------------------------------------------------------------- */

body {
  position: relative;
  overflow-x: hidden;
  background:
    radial-gradient(circle at 74% -8%, rgba(47, 142, 201, .18), transparent 30%),
    radial-gradient(circle at 22% 92%, rgba(19, 217, 192, .07), transparent 30%),
    linear-gradient(145deg, var(--nx-bg-deep), var(--nx-bg) 56%, #04111e);
}

body::before,
body::after {
  content: "";
  position: fixed;
  inset: 0;
  z-index: 0;
  pointer-events: none;
}

body::before {
  opacity: .23;
  background-image:
    linear-gradient(rgba(78, 139, 175, .11) 1px, transparent 1px),
    linear-gradient(90deg, rgba(78, 139, 175, .11) 1px, transparent 1px);
  background-size: 52px 52px;
  mask-image: linear-gradient(to bottom, rgba(0, 0, 0, .72), transparent 88%);
}

body::after {
  opacity: .18;
  background:
    linear-gradient(116deg, transparent 0 46%, rgba(62, 199, 255, .22) 46.1% 46.2%, transparent 46.3% 100%),
    linear-gradient(24deg, transparent 0 58%, rgba(19, 217, 192, .18) 58.1% 58.2%, transparent 58.3% 100%);
}

.app-shell,
.public-shell {
  position: relative;
  z-index: 1;
  isolation: isolate;
}

::selection { background: rgba(62, 199, 255, .3); color: #fff; }

a,
button,
.button,
input,
select,
textarea {
  transition:
    border-color var(--nx-transition-fast) ease,
    background-color var(--nx-transition-fast) ease,
    box-shadow var(--nx-transition-fast) ease,
    color var(--nx-transition-fast) ease,
    opacity var(--nx-transition-fast) ease,
    transform var(--nx-transition-fast) ease;
}

a:focus-visible,
button:focus-visible,
.button:focus-visible,
input:focus-visible,
select:focus-visible,
textarea:focus-visible {
  outline: 2px solid var(--nx-primary);
  outline-offset: 3px;
}

.sidebar {
  overflow: hidden;
  border-right-color: rgba(62, 199, 255, .25);
  background:
    radial-gradient(circle at 22% 8%, rgba(62, 199, 255, .09), transparent 25%),
    linear-gradient(180deg, rgba(3, 13, 24, .985), rgba(4, 17, 29, .975));
  box-shadow: 22px 0 70px rgba(0, 0, 0, .34), 1px 0 0 rgba(255, 255, 255, .025) inset;
}

.sidebar::before {
  content: "";
  position: absolute;
  top: 0;
  right: 22px;
  left: 22px;
  height: 1px;
  background: linear-gradient(90deg, transparent, rgba(255, 221, 121, .75), transparent);
  box-shadow: 0 0 18px rgba(232, 184, 74, .45);
}

.brand {
  position: relative;
  margin: 0 4px 17px;
  padding: 3px 7px 20px;
  border-bottom: 1px solid rgba(111, 169, 201, .12);
}

.brand-logo { filter: drop-shadow(0 7px 16px rgba(232, 184, 74, .3)); }

.nav { gap: 5px; padding: 2px 3px 8px; }

.nav a,
.nav-button {
  position: relative;
  min-height: 43px;
  border: 1px solid transparent;
  border-radius: var(--nx-radius-sm);
  color: #aec1cf;
}

.nav a span {
  display: grid;
  place-items: center;
  height: 25px;
  border-radius: 7px;
  color: #91aabd;
  text-shadow: 0 0 14px rgba(62, 199, 255, .18);
}

.nav a:hover,
.nav-button:hover {
  border-color: rgba(62, 199, 255, .16);
  background: rgba(62, 199, 255, .055);
  color: #edf7fd;
  transform: translateX(1px);
}

.nav a.active {
  border-color: rgba(62, 199, 255, .43);
  background:
    linear-gradient(90deg, rgba(34, 139, 222, .23), rgba(19, 217, 192, .055) 65%, rgba(232, 184, 74, .035));
  color: #fff;
  box-shadow:
    inset 3px 0 var(--nx-primary),
    0 0 24px rgba(34, 139, 222, .13),
    0 1px 0 rgba(255, 255, 255, .035) inset;
}

.nav a.active span { color: var(--nx-gold-bright); }

.system-mini {
  position: relative;
  border-color: rgba(19, 217, 192, .23);
  background:
    linear-gradient(145deg, rgba(10, 40, 57, .78), rgba(4, 19, 32, .9)),
    radial-gradient(circle at 100% 0, rgba(19, 217, 192, .12), transparent 44%);
  box-shadow: 0 13px 32px rgba(0, 0, 0, .25), 0 1px 0 rgba(255, 255, 255, .035) inset;
}

.pulse { box-shadow: 0 0 0 5px rgba(19, 217, 192, .1), 0 0 13px rgba(19, 217, 192, .7); }

.topbar {
  border-bottom-color: rgba(62, 199, 255, .18);
  background:
    linear-gradient(90deg, rgba(4, 16, 28, .91), rgba(5, 19, 32, .82)),
    rgba(5, 18, 30, .88);
  box-shadow: 0 16px 42px rgba(0, 0, 0, .18), 0 1px 0 rgba(255, 255, 255, .025) inset;
  backdrop-filter: blur(24px) saturate(128%);
}

.status-chip {
  border-color: rgba(19, 217, 192, .38);
  border-radius: 999px;
  background: rgba(19, 217, 192, .065);
  box-shadow: 0 0 18px rgba(19, 217, 192, .055) inset;
}

.identity {
  padding: 5px 8px 5px 5px;
  border: 1px solid rgba(111, 169, 201, .12);
  border-radius: 999px;
  background: rgba(8, 28, 44, .5);
}

.avatar {
  border-color: rgba(62, 199, 255, .32);
  background: linear-gradient(145deg, rgba(17, 79, 94, .92), rgba(9, 46, 63, .92));
  box-shadow: 0 7px 18px rgba(0, 0, 0, .22), 0 0 15px rgba(19, 217, 192, .08);
}

.content { max-width: 1580px; padding-top: 30px; }

.page-heading {
  position: relative;
  margin-bottom: 23px;
  padding-bottom: 16px;
}

.page-heading::after {
  content: "";
  position: absolute;
  right: 0;
  bottom: 0;
  left: 0;
  height: 1px;
  background: linear-gradient(90deg, rgba(62, 199, 255, .34), rgba(232, 184, 74, .1) 42%, transparent 92%);
}

.eyebrow { color: #7faec4; letter-spacing: .17em; }

.button {
  border-radius: var(--nx-radius-sm);
  box-shadow: 0 7px 18px rgba(0, 0, 0, .14), 0 1px 0 rgba(255, 255, 255, .035) inset;
}

.button:hover:not([disabled]) { transform: translateY(-1px); }
.button:active:not([disabled]) { transform: translateY(0) scale(.985); }
.button[disabled] { cursor: not-allowed; opacity: .55; }

.button.primary {
  background: linear-gradient(135deg, #ffe284, #e8b84a 58%, #ca8420);
  box-shadow: 0 10px 28px rgba(232, 184, 74, .16), 0 1px 0 rgba(255, 255, 255, .42) inset;
}

.button.primary:hover:not([disabled]) {
  border-color: var(--nx-gold-bright);
  box-shadow: 0 13px 34px rgba(232, 184, 74, .23), 0 1px 0 rgba(255, 255, 255, .5) inset;
}

.button.secondary {
  border-color: rgba(81, 145, 181, .32);
  background: linear-gradient(145deg, rgba(16, 47, 70, .95), rgba(8, 30, 48, .95));
}

.button.secondary:hover:not([disabled]) { border-color: rgba(62, 199, 255, .48); color: #fff; }

.button.danger { box-shadow: 0 8px 22px rgba(255, 98, 87, .07); }

.panel {
  position: relative;
  border-color: rgba(79, 139, 174, .3);
  background:
    radial-gradient(circle at 93% -12%, rgba(62, 199, 255, .075), transparent 30%),
    linear-gradient(145deg, rgba(12, 35, 54, .965), rgba(6, 21, 35, .97));
  box-shadow: var(--nx-shadow-panel);
}

.panel::before {
  content: "";
  position: absolute;
  top: 0;
  right: 8%;
  left: 8%;
  z-index: 2;
  height: 1px;
  background: linear-gradient(90deg, transparent, rgba(185, 228, 250, .36), transparent);
  pointer-events: none;
}

.panel-head {
  min-height: 64px;
  border-bottom-color: rgba(111, 169, 201, .14);
  background: linear-gradient(180deg, rgba(255, 255, 255, .018), transparent);
}

.metric-grid { gap: 15px; margin-bottom: 15px; }

.metric {
  isolation: isolate;
  min-height: 132px;
  border-color: rgba(74, 137, 173, .29);
  border-radius: var(--nx-radius-md);
  background:
    linear-gradient(145deg, rgba(13, 39, 59, .97), rgba(6, 22, 37, .98)),
    var(--nx-surface-solid);
  box-shadow: 0 16px 38px rgba(0, 0, 0, .25), 0 1px 0 rgba(255, 255, 255, .035) inset;
  transition:
    border-color var(--nx-transition-normal) ease,
    box-shadow var(--nx-transition-normal) ease,
    transform var(--nx-transition-normal) ease;
}

.metric::before {
  content: "";
  position: absolute;
  top: 0;
  right: 12px;
  left: 12px;
  height: 1px;
  background: linear-gradient(90deg, transparent, currentColor, transparent);
  opacity: .42;
}

.metric::after {
  right: -40px;
  bottom: -72px;
  width: 150px;
  height: 150px;
  opacity: .055;
  filter: blur(1px);
}

.metric:hover {
  border-color: color-mix(in srgb, currentColor 43%, var(--nx-border));
  box-shadow: 0 21px 48px rgba(0, 0, 0, .31), 0 0 25px color-mix(in srgb, currentColor 7%, transparent);
  transform: translateY(-2px);
}

.metric-icon {
  flex-basis: 50px;
  width: 50px;
  height: 50px;
  border-color: color-mix(in srgb, currentColor 54%, transparent);
  border-radius: 14px;
  background:
    linear-gradient(145deg, color-mix(in srgb, currentColor 18%, transparent), rgba(3, 13, 23, .42));
  box-shadow: 0 10px 24px rgba(0, 0, 0, .23), 0 0 18px color-mix(in srgb, currentColor 10%, transparent);
}

.metric-icon svg { width: 24px; height: 24px; }

.metric strong { text-shadow: 0 4px 18px rgba(0, 0, 0, .3); }

.dashboard-command-grid {
  display: grid;
  grid-template-columns: minmax(430px, 1.2fr) minmax(360px, 1fr);
  gap: 15px;
  margin-bottom: 15px;
}

.operational-map-panel { grid-row: span 2; min-width: 0; }

.operational-map {
  position: relative;
  min-height: 390px;
  overflow: hidden;
  background:
    radial-gradient(circle at 50% 52%, rgba(28, 132, 211, .18), transparent 17%),
    radial-gradient(circle at 50% 52%, transparent 0 31%, rgba(62, 199, 255, .08) 31.2% 31.6%, transparent 32%),
    linear-gradient(rgba(62, 199, 255, .055) 1px, transparent 1px),
    linear-gradient(90deg, rgba(62, 199, 255, .055) 1px, transparent 1px),
    linear-gradient(155deg, rgba(4, 17, 29, .84), rgba(5, 25, 40, .72));
  background-size: auto, auto, 34px 34px, 34px 34px, auto;
}

.operational-map::before,
.operational-map::after {
  content: "";
  position: absolute;
  pointer-events: none;
}

.operational-map::before {
  inset: 0;
  background:
    linear-gradient(135deg, transparent 0 39%, rgba(62, 199, 255, .07) 39.2% 39.4%, transparent 39.6%),
    linear-gradient(35deg, transparent 0 61%, rgba(19, 217, 192, .055) 61.2% 61.4%, transparent 61.6%);
}

.operational-map::after {
  right: 12%;
  bottom: -36%;
  left: 12%;
  height: 68%;
  border: 1px solid rgba(62, 199, 255, .11);
  border-radius: 50%;
  box-shadow: 0 0 45px rgba(62, 199, 255, .06) inset;
  transform: perspective(420px) rotateX(66deg);
}

.map-links {
  position: absolute;
  inset: 0;
  z-index: 1;
  width: 100%;
  height: 100%;
  overflow: visible;
}

.map-links line {
  stroke: rgba(62, 199, 255, .45);
  stroke-width: .34;
  stroke-dasharray: 1.6 1.2;
  vector-effect: non-scaling-stroke;
  filter: drop-shadow(0 0 2px rgba(62, 199, 255, .55));
}

.map-orbit {
  position: absolute;
  top: 50%;
  left: 50%;
  z-index: 1;
  border: 1px solid rgba(62, 199, 255, .14);
  border-radius: 50%;
  transform: translate(-50%, -50%);
  pointer-events: none;
}

.map-orbit-one { width: 44%; aspect-ratio: 1; }
.map-orbit-two { width: 66%; aspect-ratio: 1; border-color: rgba(19, 217, 192, .08); }

.map-node {
  position: absolute;
  z-index: 3;
  display: grid;
  justify-items: center;
  width: 112px;
  min-height: 76px;
  padding: 9px 8px;
  border: 1px solid color-mix(in srgb, currentColor 44%, rgba(79, 139, 174, .42));
  border-radius: 13px;
  background: linear-gradient(145deg, rgba(11, 33, 52, .94), rgba(3, 15, 27, .94));
  box-shadow: 0 14px 31px rgba(0, 0, 0, .38), 0 0 22px color-mix(in srgb, currentColor 9%, transparent);
  color: var(--nx-primary);
  text-align: center;
  transform: translate(-50%, -50%);
}

.map-node::after {
  content: "";
  position: absolute;
  top: 100%;
  width: 7px;
  height: 7px;
  margin-top: 4px;
  border-radius: 50%;
  background: currentColor;
  box-shadow: 0 0 11px currentColor;
}

.map-node-icon {
  display: grid;
  place-items: center;
  width: 30px;
  height: 30px;
  margin-bottom: 4px;
  border: 1px solid color-mix(in srgb, currentColor 42%, transparent);
  border-radius: 9px;
  background: color-mix(in srgb, currentColor 11%, transparent);
  font-size: 16px;
}

.map-node-icon svg { width: 17px; height: 17px; }

.map-node strong { color: #f5f9fc; font-size: 11px; line-height: 1.2; }
.map-node small { max-width: 100%; margin-top: 3px; overflow: hidden; color: #9db3c2; font-size: 9px; line-height: 1.3; text-overflow: ellipsis; white-space: nowrap; }
.map-node.is-healthy { color: var(--nx-success); }
.map-node.is-warning { color: var(--nx-warning); }
.map-node.is-critical { color: var(--nx-danger); }
.map-node.is-neutral { color: var(--nx-primary); }

.map-core {
  top: 50%;
  left: 50%;
  width: 132px;
  min-height: 110px;
  padding-top: 15px;
  border-radius: 50%;
  background:
    radial-gradient(circle at 50% 32%, rgba(62, 199, 255, .2), transparent 48%),
    linear-gradient(145deg, rgba(11, 44, 70, .98), rgba(4, 20, 35, .98));
  box-shadow:
    0 18px 38px rgba(0, 0, 0, .43),
    0 0 0 8px rgba(62, 199, 255, .045),
    0 0 42px rgba(62, 199, 255, .17);
}

.map-core::after { top: calc(100% + 5px); }
.map-core .map-node-icon { width: 39px; height: 39px; border-radius: 50%; font-size: 21px; }
.map-core .map-node-icon svg { width: 22px; height: 22px; }
.map-core strong { font-size: 12px; }
.map-core small { color: #fff; font-size: 18px; font-weight: 800; }
.map-jellyfin { top: 14%; left: 50%; }
.map-subscriptions { top: 31%; left: 84%; }
.map-observer { top: 72%; left: 84%; }
.map-payments { top: 72%; left: 16%; }
.map-resellers { top: 31%; left: 16%; }

.operational-map-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  min-height: 49px;
  padding: 11px 16px;
  border-top: 1px solid var(--nx-border-soft);
  background: rgba(2, 13, 23, .34);
  color: var(--nx-text-muted);
  font-size: 10px;
}

.operational-map-footer a { flex: 0 0 auto; font-size: 11px; }

.network-panel,
.reseller-notifications { min-width: 0; }

.network-chart-wrap {
  background: linear-gradient(180deg, transparent, rgba(62, 199, 255, .018));
}

.network-summary i { box-shadow: 0 0 11px var(--nx-success); }
.network-summary i.tx { box-shadow: 0 0 11px var(--nx-primary); }

.donut {
  position: relative;
  box-shadow: 0 14px 34px rgba(0, 0, 0, .26), 0 0 38px rgba(19, 217, 192, .08);
}

.donut::before {
  background: radial-gradient(circle at 50% 28%, rgba(62, 199, 255, .09), transparent 55%), #071a2b;
  box-shadow: inset 0 0 0 1px rgba(111, 169, 201, .24), 0 6px 22px rgba(0, 0, 0, .22);
}

.status-list div { transition: background-color var(--nx-transition-fast) ease, padding var(--nx-transition-fast) ease; }
.status-list div:hover { margin: 0 -8px; padding-right: 8px; padding-left: 8px; border-radius: 7px; background: rgba(62, 199, 255, .035); }

.table-wrap { scrollbar-color: rgba(62, 199, 255, .28) rgba(3, 13, 23, .3); }

table { background: rgba(3, 15, 27, .12); }

th {
  padding-top: 13px;
  padding-bottom: 13px;
  border-bottom: 1px solid rgba(111, 169, 201, .16);
  background: linear-gradient(180deg, rgba(11, 35, 54, .88), rgba(5, 21, 35, .78));
  color: #91adbf;
}

td { padding-top: 13px; padding-bottom: 13px; border-top-color: rgba(111, 169, 201, .115); }

tbody tr { transition: background-color var(--nx-transition-fast) ease, box-shadow var(--nx-transition-fast) ease; }
tbody tr:hover { background: rgba(62, 199, 255, .035); box-shadow: 3px 0 var(--nx-primary) inset; }

.icon-link {
  border-color: rgba(82, 145, 181, .35);
  background: rgba(11, 39, 59, .55);
  transition: border-color var(--nx-transition-fast) ease, background-color var(--nx-transition-fast) ease, transform var(--nx-transition-fast) ease;
}

.icon-link:hover { border-color: var(--nx-primary); background: rgba(62, 199, 255, .1); transform: translateX(1px); }

.badge {
  gap: 5px;
  border-radius: 999px;
  letter-spacing: .035em;
}

.badge::before {
  content: "";
  width: 5px;
  height: 5px;
  border-radius: 50%;
  background: currentColor;
  box-shadow: 0 0 6px currentColor;
}

.badge.large { border-radius: 999px; }

input,
select,
textarea {
  border-color: rgba(76, 137, 172, .42);
  border-radius: var(--nx-radius-sm);
  background:
    linear-gradient(180deg, rgba(4, 17, 29, .96), rgba(5, 22, 36, .96));
  box-shadow: 0 1px 0 rgba(255, 255, 255, .02) inset, 0 7px 16px rgba(0, 0, 0, .08);
}

input:hover,
select:hover,
textarea:hover { border-color: rgba(62, 199, 255, .44); }

input:focus,
select:focus,
textarea:focus {
  border-color: var(--nx-primary);
  box-shadow: 0 0 0 3px rgba(62, 199, 255, .1), 0 0 20px rgba(62, 199, 255, .06);
}

.form-card {
  background:
    radial-gradient(circle at 100% 0, rgba(232, 184, 74, .045), transparent 27%),
    linear-gradient(145deg, rgba(12, 35, 54, .97), rgba(6, 21, 35, .98));
}

.filters { background: linear-gradient(180deg, rgba(255, 255, 255, .016), transparent); }

.flash {
  border-radius: var(--nx-radius-sm);
  background: linear-gradient(145deg, rgba(14, 43, 61, .95), rgba(7, 25, 40, .95));
  box-shadow: 0 12px 26px rgba(0, 0, 0, .16), 0 1px 0 rgba(255, 255, 255, .025) inset;
}

.notice,
.attention-recommendation {
  border-radius: 0 var(--nx-radius-sm) var(--nx-radius-sm) 0;
  box-shadow: 0 8px 22px rgba(0, 0, 0, .11);
}

.attention-card,
.timeline-body,
.private-note-list form {
  background:
    linear-gradient(145deg, rgba(7, 27, 43, .82), rgba(3, 16, 28, .78));
  box-shadow: 0 12px 27px rgba(0, 0, 0, .16), 0 1px 0 rgba(255, 255, 255, .02) inset;
}

.health-card { box-shadow: 0 16px 39px rgba(0, 0, 0, .25), 0 1px 0 rgba(255, 255, 255, .03) inset; }

.subscription-card {
  background:
    radial-gradient(circle at 85% 46%, rgba(19, 217, 192, .13), transparent 34%),
    linear-gradient(145deg, rgba(12, 37, 56, .98), rgba(5, 20, 34, .98));
}

.stream-art {
  border-color: rgba(62, 199, 255, .16);
  background: radial-gradient(circle, rgba(19, 217, 192, .16), rgba(62, 199, 255, .035) 46%, transparent 67%);
  box-shadow: 0 0 52px rgba(19, 217, 192, .06) inset;
}

.plan-card,
.download-links a {
  background: linear-gradient(145deg, rgba(7, 27, 43, .98), rgba(3, 17, 29, .98));
  box-shadow: 0 10px 24px rgba(0, 0, 0, .14), 0 1px 0 rgba(255, 255, 255, .025) inset;
}

dialog,
[role="dialog"],
.modal {
  border: 1px solid rgba(81, 145, 181, .42);
  border-radius: var(--nx-radius-lg);
  background: rgba(8, 26, 42, .94);
  box-shadow: var(--nx-shadow-floating);
  backdrop-filter: blur(22px) saturate(125%);
}

dialog::backdrop,
.modal-backdrop { background: rgba(0, 6, 12, .72); backdrop-filter: blur(8px); }

.public-header {
  border-bottom-color: rgba(62, 199, 255, .17);
  background: rgba(2, 10, 19, .91);
  box-shadow: 0 16px 46px rgba(0, 0, 0, .25), 0 1px 0 rgba(255, 255, 255, .025) inset;
  backdrop-filter: blur(24px) saturate(125%);
}

.public-brand img { filter: drop-shadow(0 6px 14px rgba(232, 184, 74, .3)); }

.public-nav a {
  border: 1px solid transparent;
  border-radius: 7px;
}

.public-nav a:hover,
.public-nav a.active {
  border-color: rgba(62, 199, 255, .18);
  background: rgba(62, 199, 255, .045);
}

.login-layout {
  position: relative;
  background:
    radial-gradient(circle at 29% 48%, rgba(43, 132, 193, .13), transparent 25%),
    linear-gradient(135deg, rgba(1, 7, 14, .44), rgba(5, 19, 32, .32));
}

.login-visual {
  position: relative;
  isolation: isolate;
  overflow: hidden;
  border-right: 1px solid rgba(62, 199, 255, .16);
  background:
    radial-gradient(circle at 50% 58%, rgba(62, 199, 255, .12), transparent 27%),
    linear-gradient(rgba(62, 199, 255, .055) 1px, transparent 1px),
    linear-gradient(90deg, rgba(62, 199, 255, .055) 1px, transparent 1px),
    linear-gradient(145deg, rgba(4, 17, 29, .96), rgba(3, 13, 23, .98));
  background-size: auto, 48px 48px, 48px 48px, auto;
}

.login-visual::before,
.login-visual::after {
  content: "";
  position: absolute;
  z-index: -1;
  pointer-events: none;
}

.login-visual::before {
  top: 50%;
  left: 50%;
  width: min(54vw, 680px);
  aspect-ratio: 1;
  border: 1px solid rgba(62, 199, 255, .13);
  border-radius: 50%;
  box-shadow:
    0 0 0 76px rgba(62, 199, 255, .018),
    0 0 0 77px rgba(62, 199, 255, .055),
    0 0 75px rgba(62, 199, 255, .06) inset;
  transform: translate(-50%, -42%) perspective(650px) rotateX(57deg);
}

.login-visual::after {
  inset: 0;
  background:
    linear-gradient(32deg, transparent 0 55%, rgba(19, 217, 192, .1) 55.1% 55.2%, transparent 55.3%),
    linear-gradient(124deg, transparent 0 44%, rgba(62, 199, 255, .13) 44.1% 44.2%, transparent 44.3%);
}

.hero-brand,
.group-intro,
.visual-grid { position: relative; z-index: 2; }

.hero-brand img { filter: drop-shadow(0 18px 35px rgba(0, 0, 0, .28)) drop-shadow(0 0 16px rgba(232, 184, 74, .09)); }

.visual-grid span {
  border-color: rgba(62, 199, 255, .2);
  background: radial-gradient(circle, rgba(62, 199, 255, .18), rgba(5, 22, 36, .2) 60%, transparent 62%);
  box-shadow: 0 0 22px rgba(62, 199, 255, .09);
}

.login-panel {
  position: relative;
  background:
    radial-gradient(circle at 50% 45%, rgba(62, 199, 255, .07), transparent 32%),
    rgba(2, 10, 18, .45);
}

.login-card {
  position: relative;
  overflow: hidden;
  padding: clamp(26px, 3vw, 38px);
  border: 1px solid rgba(81, 145, 181, .34);
  border-radius: 18px;
  background:
    radial-gradient(circle at 90% 0, rgba(62, 199, 255, .08), transparent 28%),
    linear-gradient(145deg, rgba(12, 35, 54, .9), rgba(5, 19, 32, .94));
  box-shadow: var(--nx-shadow-floating);
  backdrop-filter: blur(22px) saturate(120%);
}

.login-card::before {
  content: "";
  position: absolute;
  top: 0;
  right: 9%;
  left: 9%;
  height: 1px;
  background: linear-gradient(90deg, transparent, rgba(213, 241, 255, .47), transparent);
}

.login-card h2 { margin-top: 5px; font-size: clamp(26px, 3vw, 34px); }

.hero-contact {
  border-color: rgba(62, 199, 255, .22);
  background: rgba(5, 24, 39, .62);
  box-shadow: 0 12px 28px rgba(0, 0, 0, .22), 0 1px 0 rgba(255, 255, 255, .025) inset;
}

.sidebar-backdrop { display: none; }

@media (max-width: 1100px) {
  .dashboard-grid > .span-2 { grid-column: auto; }
  .dashboard-command-grid { grid-template-columns: 1fr; }
  .operational-map-panel { grid-row: auto; }
  .operational-map { min-height: 430px; }
}

@media (max-width: 820px) {
  body.sidebar-open { overflow: hidden; }
  .sidebar { box-shadow: 28px 0 80px rgba(0, 0, 0, .62); }
  .sidebar-backdrop {
    position: fixed;
    inset: 0;
    z-index: 15;
    display: block;
    visibility: hidden;
    background: rgba(0, 6, 12, .68);
    opacity: 0;
    backdrop-filter: blur(4px);
    transition: opacity var(--nx-transition-normal) ease, visibility var(--nx-transition-normal) ease;
  }
  body.sidebar-open .sidebar-backdrop { visibility: visible; opacity: 1; }
  .menu-toggle {
    width: 38px;
    height: 38px;
    border: 1px solid rgba(81, 145, 181, .28);
    border-radius: 9px;
    background: rgba(9, 31, 49, .72);
  }
  .login-visual { border-right: 0; border-bottom: 1px solid rgba(62, 199, 255, .14); }
}

@media (max-width: 620px) {
  .operational-map { min-height: 480px; }
  .map-node { width: 96px; min-height: 72px; padding: 8px 6px; }
  .map-core { width: 116px; min-height: 105px; }
  .map-subscriptions, .map-observer { left: 80%; }
  .map-payments, .map-resellers { left: 20%; }
  .operational-map-footer { align-items: flex-start; flex-direction: column; }
  .content { padding-top: 22px; }
}

@media (max-width: 420px) {
  .map-node { width: 88px; }
  .map-node strong { font-size: 10px; }
  .map-node small { max-width: 76px; font-size: 8px; }
  .map-core { width: 108px; }
  .map-subscriptions, .map-observer { left: 78%; }
  .map-payments, .map-resellers { left: 22%; }
}

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    scroll-behavior: auto !important;
    animation-duration: .01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: .01ms !important;
  }
  .metric:hover,
  .button:hover:not([disabled]),
  .nav a:hover,
  .icon-link:hover { transform: none; }
}

@media (forced-colors: active) {
  .panel,
  .metric,
  .map-node,
  .login-card { border: 1px solid CanvasText; }
  .badge::before,
  .map-node::after { box-shadow: none; }
}
