* { box-sizing: border-box; }
:root {
  --bg: #eef3f8;
  --bg-elevated: #f8fafc;
  --panel: #ffffff;
  --panel-soft: #f7f9fc;
  --panel-tint: #edf6ff;
  --ink: #101828;
  --ink-soft: #263244;
  --muted: #667085;
  --muted-strong: #475467;
  --line: #d6e0eb;
  --line-soft: #e9eef5;
  --blue: #2756d8;
  --blue-soft: #eef4ff;
  --cyan: #0e7490;
  --cyan-soft: #e8f7fb;
  --green: #067647;
  --green-soft: #ecfdf3;
  --amber: #946200;
  --amber-soft: #fffaeb;
  --red: #b42318;
  --red-soft: #fef3f2;
  --slate: #1d2939;
  --nav: #0b1220;
  --nav-soft: #111b2d;
  --shadow: 0 20px 45px rgba(15, 23, 42, .075);
  --shadow-soft: 0 1px 2px rgba(16, 24, 40, .06);
  --shadow-card: 0 10px 24px rgba(16, 24, 40, .06);
  --shadow-float: 0 24px 80px rgba(16, 24, 40, .16);
  --radius: 8px;
  --radius-sm: 6px;
  --space-1: 4px;
  --space-2: 8px;
  --space-3: 12px;
  --space-4: 16px;
  --space-5: 20px;
  --space-6: 24px;
  --control-h: 42px;
}
html { scroll-behavior: smooth; }
body {
  margin: 0;
  min-height: 100vh;
  font-family: "DM Sans", ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  color: var(--ink);
  background:
    radial-gradient(circle at top right, rgba(39, 86, 216, .06), transparent 300px),
    linear-gradient(180deg, #fbfcfe 0, var(--bg-elevated) 230px, var(--bg) 560px),
    var(--bg);
  letter-spacing: 0;
  overflow-x: hidden;
}
button, input, select, textarea { font: inherit; letter-spacing: 0; }
button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 7px;
  border: 0;
  border-radius: var(--radius);
  min-height: var(--control-h);
  padding: 10px 15px;
  background: linear-gradient(180deg, #263548, #1d2939);
  color: #fff;
  font-weight: 800;
  line-height: 1.2;
  white-space: nowrap;
  cursor: pointer;
  box-shadow: 0 1px 0 rgba(255,255,255,.1) inset, 0 1px 2px rgba(16,24,40,.14);
  transition: background .16s ease, border-color .16s ease, color .16s ease, transform .16s ease, box-shadow .16s ease;
}
button:hover { filter: none; transform: translateY(-1px); box-shadow: 0 1px 0 rgba(255,255,255,.12) inset, 0 8px 18px rgba(16,24,40,.14); }
button:active { transform: translateY(0); }
button:disabled {
  cursor: not-allowed;
  opacity: .45;
  filter: grayscale(.2);
}
button:focus-visible, input:focus-visible, select:focus-visible, textarea:focus-visible {
  outline: 3px solid rgba(49, 95, 220, .2);
  outline-offset: 2px;
}
.app-shell { display: grid; grid-template-columns: 276px minmax(0, 1fr); min-height: 100vh; }
.auth-checking .app-shell {
  display: none !important;
}
.auth-checking::before {
  content: "Checking session...";
  min-height: 100vh;
  display: grid;
  place-items: center;
  color: var(--muted);
  font-weight: 800;
}
.unauthenticated .app-shell {
  display: block;
  min-height: 100vh;
}
.unauthenticated .sidebar,
.unauthenticated .topbar {
  display: none;
}
.unauthenticated .workspace {
  min-height: 100vh;
  display: grid;
  align-content: center;
  padding: 56px 24px;
}
.unauthenticated .login-layout {
  width: min(1080px, 100%);
  max-width: none;
  margin: 0 auto;
  display: grid;
  grid-template-columns: minmax(0, .85fr) minmax(420px, 1fr);
  gap: 24px;
  align-items: stretch;
}
.unauthenticated .login-layout .panel {
  box-shadow: var(--shadow-float);
}
.sidebar {
  position: sticky;
  top: 0;
  height: 100vh;
  display: grid;
  grid-template-rows: auto auto minmax(0, 1fr) auto;
  gap: 18px;
  padding: 20px 16px;
  background:
    linear-gradient(180deg, rgba(49,95,220,.14), transparent 230px),
    linear-gradient(180deg, var(--nav-soft), var(--nav) 52%),
    var(--nav);
  color: #e5edf7;
  border-right: 1px solid rgba(255,255,255,.08);
}
.login-hero {
  display: grid;
  align-content: space-between;
  gap: 24px;
  min-height: 420px;
  padding: 32px;
  border-radius: 10px;
  background:
    linear-gradient(145deg, rgba(255,255,255,.055), transparent 34%),
    linear-gradient(145deg, #0b1220 0%, #142033 62%, #0e3340 100%);
  color: #f8fafc;
  box-shadow: var(--shadow-float);
}
.login-hero h1 {
  max-width: 420px;
  font-size: 38px;
  line-height: 1.05;
  color: #f8fafc;
}
.login-hero p {
  max-width: 460px;
  color: #cbd5e1;
  font-size: 16px;
  line-height: 1.6;
}
.login-points {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
}
.login-points span {
  padding: 7px 10px;
  border: 1px solid rgba(255,255,255,.14);
  border-radius: 999px;
  background: rgba(255,255,255,.07);
  color: #dce8f7;
  font-size: 12px;
  font-weight: 800;
}
.brand { display: flex; gap: 12px; align-items: center; }
.brand-mark {
  width: 38px;
  height: 38px;
  display: grid;
  place-items: center;
  border-radius: var(--radius);
  background: linear-gradient(135deg, #ffffff, #d7eafe);
  color: #0f172a;
  font-weight: 900;
  box-shadow: 0 10px 24px rgba(49, 95, 220, .2);
}
.brand strong, .brand small { display: block; }
.brand small { color: #9fb0c7; margin-top: 2px; }
.nav {
  min-height: 0;
  display: grid;
  align-content: start;
  gap: 5px;
  overflow: auto;
  padding-right: 2px;
}
.nav::-webkit-scrollbar { width: 8px; height: 8px; }
.nav::-webkit-scrollbar-thumb { background: rgba(255,255,255,.16); border-radius: 999px; }
.nav-group {
  display: grid;
  gap: 6px;
  padding: 8px 0 10px;
}
.nav-group > span {
  padding: 0 11px 4px;
  color: #7890ad;
  font-size: 11px;
  font-weight: 900;
  letter-spacing: .08em;
  text-transform: uppercase;
}
.nav-item {
  width: 100%;
  display: grid;
  grid-template-columns: 32px minmax(0, 1fr);
  gap: 11px;
  align-items: center;
  text-align: left;
  background: transparent;
  color: #cad5e4;
  border-radius: var(--radius);
  box-shadow: none;
  min-height: 46px;
  border: 1px solid transparent;
}
.nav-item:hover { transform: none; }
.nav-item i {
  width: 30px;
  height: 30px;
  display: grid;
  place-items: center;
  border-radius: 7px;
  background: rgba(255,255,255,.065);
  color: #d9e7f8;
  font-size: 10px;
  font-style: normal;
  font-weight: 900;
}
.nav-item span { min-width: 0; }
.nav-item strong { font-size: 13px; letter-spacing: .01em; }
.nav-item small {
  display: block;
  margin-top: 2px;
  color: #8fa3bf;
  font-size: 11px;
  font-weight: 600;
}
.nav-item:hover {
  background: rgba(255,255,255,.075);
  border-color: rgba(255,255,255,.1);
  color: #fff;
}
.nav-item.active {
  background: linear-gradient(90deg, rgba(49,95,220,.28), rgba(255,255,255,.075));
  border-color: rgba(164,191,255,.22);
  color: #fff;
}
.nav-item.active {
  box-shadow: inset 3px 0 0 #7dd3fc, 0 8px 18px rgba(0,0,0,.12);
}
.nav-item.active i { background: #e8f3ff; color: #0f172a; }
.nav-item.active small { color: #c7d2e2; }
.sidebar-note {
  display: grid;
  gap: 6px;
  padding: 14px;
  border: 1px solid rgba(255,255,255,.11);
  border-radius: 8px;
  color: #c9d5e4;
  background: rgba(255,255,255,.035);
  overflow-wrap: anywhere;
}
.sidebar-note strong { color: #fff; }
.workspace { min-width: 0; padding: 30px 34px 46px; }
.topbar, #notice, #appView { max-width: 1500px; margin-left: auto; margin-right: auto; }
.access-level-switcher {
  display: grid;
  gap: 6px;
  padding: 9px;
  border: 1px solid rgba(255,255,255,.12);
  border-radius: 8px;
  background: rgba(255,255,255,.04);
}
.access-level-switcher > span,
.switcher-label > span:first-child {
  padding: 0 2px;
  color: #8fa3bf;
  font-size: 10px;
  font-weight: 900;
  text-transform: uppercase;
}
.switcher-label {
  display: flex;
  justify-content: space-between;
  gap: 8px;
  align-items: center;
  position: relative;
}
.info-tip {
  width: 18px;
  height: 18px;
  display: inline-grid;
  place-items: center;
  border-radius: 999px;
  border: 1px solid rgba(125,211,252,.45);
  color: #dbeafe;
  background: rgba(56,189,248,.14);
  font-size: 11px;
  font-weight: 900;
  line-height: 1;
  cursor: help;
}
.info-tip::after {
  content: attr(aria-label);
  position: absolute;
  left: 0;
  top: calc(100% + 8px);
  z-index: 20;
  width: min(220px, calc(100vw - 48px));
  padding: 8px 10px;
  border-radius: 7px;
  background: #0f172a;
  color: #f8fafc;
  border: 1px solid rgba(255,255,255,.14);
  box-shadow: 0 12px 32px rgba(15,23,42,.28);
  font-size: 11px;
  font-weight: 800;
  line-height: 1.35;
  opacity: 0;
  pointer-events: none;
  transform: translateY(-4px);
  transition: opacity .14s ease, transform .14s ease;
}
.info-tip:hover::after,
.info-tip:focus-visible::after {
  opacity: 1;
  transform: translateY(0);
}
.access-level-switcher [role="group"] {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 4px;
}
.access-level-switcher button {
  min-height: 28px;
  padding: 5px 3px;
  background: transparent;
  color: #c7d2e2;
  box-shadow: none;
  border: 1px solid rgba(255,255,255,.09);
  border-radius: 6px;
  justify-content: center;
  text-align: center;
  font-size: 11px;
  line-height: 1;
}
.access-level-switcher button.active {
  background: rgba(125,211,252,.18);
  color: #fff;
  border-color: rgba(125,211,252,.45);
}
.access-level-switcher strong {
  color: #fff;
  font-size: 13px;
}
.access-level-switcher small {
  color: #9fb0c7;
  font-weight: 700;
}
.topbar {
  display: flex;
  justify-content: space-between;
  gap: 22px;
  align-items: flex-start;
  margin-bottom: 22px;
  padding-bottom: 22px;
  border-bottom: 1px solid rgba(217,226,236,.9);
}
h1, h2 { margin: 0; letter-spacing: 0; }
h1 { font-size: 30px; line-height: 1.08; font-weight: 850; color: #0b1220; }
h2 { font-size: 17px; font-weight: 800; color: #111827; }
h3 { margin: 0; font-size: 15px; }
p { margin: 0; }
.muted, #pageSubtitle { color: var(--muted); margin-top: 5px; }
.page-kicker, .eyebrow {
  margin: 0 0 6px;
  color: #315fdc;
  font-size: 11px;
  font-weight: 900;
  letter-spacing: .08em;
  text-transform: uppercase;
}
.top-actions { display: flex; gap: 10px; align-items: end; flex-wrap: wrap; justify-content: flex-end; }
.search-field { width: min(320px, 100%); }
label { display: grid; gap: 6px; color: var(--muted-strong); font-size: 12px; font-weight: 800; }
input, select, textarea {
  width: 100%;
  min-height: var(--control-h);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 10px 12px;
  background: #fbfcfe;
  color: var(--ink);
  box-shadow: 0 1px 0 rgba(255,255,255,.85) inset, 0 1px 2px rgba(15, 23, 42, .025);
  transition: background .16s ease, border-color .16s ease, box-shadow .16s ease;
}
input:hover, select:hover, textarea:hover { border-color: #c8d4e2; background: #fff; }
input:focus, select:focus, textarea:focus { border-color: rgba(49,95,220,.55); background: #fff; }
input::placeholder, textarea::placeholder { color: #98a2b3; }
textarea { min-height: 92px; resize: vertical; }
input[readonly], textarea[readonly] {
  background: #f8fafc;
  color: #475467;
}
.field-help {
  margin-top: 10px;
  color: var(--muted);
  font-size: 12px;
  line-height: 1.45;
}
.ghost-btn, .icon-btn {
  background: linear-gradient(180deg, #ffffff, #f4f7fb);
  color: var(--slate);
  border: 1px solid #d9e5f1;
}
.ghost-btn:hover, .icon-btn:hover { background: #fff; border-color: #c8d4e2; }
.danger-btn {
  background: linear-gradient(180deg, #fff8f7, #fff0ee);
  color: var(--red);
  border: 1px solid #ffd2cc;
}
.danger-btn:hover { background: linear-gradient(180deg, #c43227, var(--red)); color: #fff; border-color: var(--red); }
.link-btn {
  background: transparent;
  color: var(--blue);
  padding: 0;
  min-height: 0;
  font-weight: 800;
  box-shadow: none;
  white-space: normal;
}
.link-btn:hover { transform: none; filter: none; text-decoration: underline; }
.hidden { display: none !important; }
.notice {
  padding: 13px 15px;
  border-radius: 8px;
  margin-bottom: 20px;
  background: #eef4ff;
  color: #254999;
  border: 1px solid #d6e4ff;
  font-weight: 700;
  box-shadow: var(--shadow-soft);
}
.notice.success { background: #ecfdf3; color: #067647; border-color: #bbefd2; }
.notice.warn { background: #fff7e6; color: #8a5b12; border-color: #f4dfad; }
.notice.danger { background: #ffeceb; color: #9f2f2a; border-color: #ffc8c5; }
.login-layout { max-width: 760px; }
.two-factor-box {
  display: grid;
  gap: 12px;
  margin-top: 16px;
  padding: 14px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--panel-soft);
}
.view { display: grid; gap: 20px; }
.grid-2 { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 20px; margin-bottom: 20px; }
.panel {
  min-width: 0;
  padding: 20px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--panel);
  box-shadow: var(--shadow-card);
}
.panel:hover { border-color: #c9d6e5; }
.panel-head {
  display: flex;
  justify-content: space-between;
  gap: 14px;
  align-items: flex-start;
  margin-bottom: 16px;
}
.panel-head > div { min-width: 0; }
.panel-head > :last-child { flex-shrink: 0; }
.panel-head p {
  margin-top: 4px;
  color: var(--muted);
  font-size: 12px;
  line-height: 1.45;
}
.module-header {
  display: flex;
  justify-content: space-between;
  gap: 18px;
  align-items: flex-start;
  padding: 20px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: #fff;
  box-shadow: var(--shadow-card);
}
.module-header > div { min-width: 0; }
.module-header h2 {
  font-size: 23px;
  line-height: 1.15;
}
.module-header p {
  margin-top: 6px;
  color: var(--muted);
  line-height: 1.5;
}
.subnav {
  display: flex;
  gap: 8px;
  align-items: center;
  min-width: 0;
  width: 100%;
  max-width: 100%;
  overflow-x: auto;
  padding: 4px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: #fff;
  box-shadow: var(--shadow-soft);
}
.subnav button {
  min-height: 38px;
  padding: 8px 12px;
  background: transparent;
  color: var(--muted-strong);
  border: 1px solid transparent;
  box-shadow: none;
}
.subnav button.active {
  background: var(--blue-soft);
  color: #254999;
  border-color: #d6e4ff;
}
.list-toolbar {
  display: grid;
  grid-template-columns: minmax(220px, 1fr) repeat(2, minmax(150px, auto));
  gap: 10px;
  align-items: end;
  margin-bottom: 14px;
}
.list-toolbar label {
  min-width: 0;
}
.empty-state {
  display: grid;
  place-items: center;
  gap: 10px;
  min-height: 220px;
  padding: 28px;
  border: 1px dashed #cbd5e1;
  border-radius: 10px;
  background: linear-gradient(180deg, #fbfcfe, #f8fafc);
  text-align: center;
}
.empty-state strong {
  font-size: 17px;
}
.empty-state p {
  max-width: 460px;
  color: var(--muted);
  line-height: 1.5;
}
.row-actions {
  display: flex;
  gap: 6px;
  flex-wrap: wrap;
}
.table-wrap thead th {
  position: sticky;
  top: 0;
  z-index: 1;
}
.section-output {
  margin-top: 14px;
}
.dashboard-hero {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 22px;
  align-items: center;
  padding: 26px;
  border: 1px solid #c8d9f2;
  border-radius: var(--radius);
  background:
    linear-gradient(135deg, rgba(49,95,220,.095), rgba(14,116,144,.055)),
    #fff;
  box-shadow: var(--shadow-card);
}
.dashboard-hero h2 {
  font-size: 29px;
  line-height: 1.08;
  letter-spacing: 0;
}
.dashboard-hero p {
  max-width: 760px;
  margin-top: 9px;
  color: var(--muted);
  line-height: 1.55;
  overflow-wrap: anywhere;
}
.quick-actions {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
  justify-content: flex-end;
  min-width: 0;
}
.metric-grid {
  display: grid;
  grid-template-columns: repeat(6, minmax(132px, 1fr));
  gap: 16px;
}
.metric-card {
  display: grid;
  gap: 9px;
  min-height: 112px;
  padding: 18px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--panel);
  box-shadow: var(--shadow-card);
  position: relative;
  overflow: hidden;
}
.metric-card::before {
  content: "";
  width: 38px;
  height: 4px;
  border-radius: 999px;
  background: linear-gradient(90deg, var(--blue), var(--cyan));
}
.metric-card span, .metric-card small { color: var(--muted); }
.metric-card strong { font-size: 30px; line-height: 1; letter-spacing: -.01em; }
.status-block {
  display: grid;
  gap: 6px;
  min-width: 0;
  padding: 14px 15px;
  border-radius: 8px;
  margin-bottom: 16px;
  border: 1px solid var(--line);
  overflow-wrap: anywhere;
}
.status-block.success { background: var(--green-soft); color: #067647; border-color: #bfe8d3; }
.status-block.warn { background: var(--amber-soft); color: #7a4b08; border-color: #f2d58e; }
.status-block.danger { background: var(--red-soft); color: #8f241a; border-color: #ffc8c2; }
.status-block strong,
.status-block span {
  min-width: 0;
  overflow-wrap: anywhere;
}
.service-grid, .summary-grid, .feature-grid, .quota-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 12px;
}
.service-grid div, .summary-grid div, .feature-grid span, .checklist div, .list-item, .guidance-list div, .quota-card {
  display: grid;
  gap: 5px;
  padding: 13px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: linear-gradient(180deg, #fbfcfe, var(--panel-soft));
  min-width: 0;
}
.service-grid strong, .summary-grid strong, .feature-grid span, .checklist strong, .checklist span, .list-item strong, .guidance-list strong, .quota-card strong {
  min-width: 0;
  overflow-wrap: anywhere;
}
.service-grid span, .service-grid small, .summary-grid span, .checklist span, .list-item p, .guidance-list span, .quota-card span, .quota-card small { color: var(--muted); }
.guidance-list {
  display: grid;
  gap: 10px;
}
.guidance-list div {
  border-left: 3px solid #94a3b8;
}
.guidance-list div.success { border-left-color: var(--green); }
.guidance-list div.warn { border-left-color: var(--amber); }
.guidance-list div.danger { border-left-color: var(--red); }
.guidance-list .actions {
  margin-top: 4px;
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
}
.timeline-list {
  display: grid;
  gap: 10px;
}
.timeline-item {
  display: grid;
  grid-template-columns: 12px minmax(0, 1fr);
  gap: 10px;
  align-items: start;
  padding: 12px 0;
  border-bottom: 1px solid var(--line-soft);
}
.timeline-item:last-child { border-bottom: 0; }
.timeline-item strong,
.timeline-item span,
.timeline-item small {
  display: block;
  min-width: 0;
  overflow-wrap: anywhere;
}
.timeline-item span,
.timeline-item small { color: var(--muted); }
.timeline-dot {
  width: 10px;
  height: 10px;
  margin-top: 5px;
  border-radius: 50%;
  background: #94a3b8;
  box-shadow: 0 0 0 3px #eef2f7;
}
.timeline-dot.succeeded,
.timeline-dot.audit,
.timeline-dot.backup { background: var(--green); }
.timeline-dot.pending,
.timeline-dot.running { background: var(--amber); }
.timeline-dot.failed,
.timeline-dot.danger { background: var(--red); }
.dns-preset-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
}
.preset-btn {
  align-items: flex-start;
  justify-content: flex-start;
  display: grid;
  gap: 4px;
  text-align: left;
  white-space: normal;
  min-width: 0;
  color: var(--slate);
  background: linear-gradient(180deg, #ffffff, #f4f7fb);
  border: 1px solid #d9e5f1;
  box-shadow: none;
}
.preset-btn span {
  color: var(--muted);
  font-size: 12px;
  font-weight: 700;
}
.recommendation-grid {
  display: grid;
  gap: 10px;
  margin-top: 12px;
}
.recommendation-card {
  display: grid;
  gap: 8px;
  padding: 12px;
  border: 1px solid var(--line);
  border-left: 3px solid #94a3b8;
  border-radius: var(--radius);
  background: #fbfcfe;
  min-width: 0;
}
.recommendation-card.required {
  border-left-color: var(--amber);
}
.recommendation-card code {
  white-space: pre-wrap;
  overflow-wrap: anywhere;
}
.recommendation-card span {
  color: var(--muted);
  font-size: 12px;
}
.recommendation-card button {
  justify-self: start;
}
.quota-grid {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}
.quota-card {
  border-left: 3px solid #94a3b8;
}
.quota-card.success { border-left-color: var(--green); }
.quota-card.warn { border-left-color: var(--amber); }
.quota-card.danger { border-left-color: var(--red); }
.quota-card > div {
  display: flex;
  justify-content: space-between;
  gap: 10px;
}
.quota-card i {
  display: block;
  height: 8px;
  border-radius: 999px;
  background: #e2e8f0;
  overflow: hidden;
}
.quota-card i::after {
  content: "";
  display: block;
  width: 0;
  height: 100%;
  border-radius: inherit;
  background: var(--green);
}
.quota-card.warn i::after { background: var(--amber); }
.quota-card.danger i::after { background: var(--red); }
.service-card {
  border-left: 3px solid #94a3b8 !important;
}
.service-card.success { border-left-color: var(--green) !important; }
.service-card.warn { border-left-color: var(--amber) !important; }
.service-card.danger { border-left-color: var(--red) !important; }
.meters {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 12px;
}
.meter {
  display: grid;
  gap: 9px;
  padding: 13px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: linear-gradient(180deg, #fbfcfe, var(--panel-soft));
}
.meter div {
  display: flex;
  justify-content: space-between;
  gap: 10px;
  align-items: center;
}
.meter span, .meter small { color: var(--muted); }
.meter i {
  display: block;
  height: 8px;
  border-radius: 999px;
  background: #e2e8f0;
  overflow: hidden;
}
.meter i::after {
  content: "";
  display: block;
  width: 0;
  height: 100%;
  border-radius: inherit;
  background: var(--green);
}
.meter i.meter-fill-0::after, .quota-card i.meter-fill-0::after { width: 0%; }
.meter i.meter-fill-5::after, .quota-card i.meter-fill-5::after { width: 5%; }
.meter i.meter-fill-10::after, .quota-card i.meter-fill-10::after { width: 10%; }
.meter i.meter-fill-15::after, .quota-card i.meter-fill-15::after { width: 15%; }
.meter i.meter-fill-20::after, .quota-card i.meter-fill-20::after { width: 20%; }
.meter i.meter-fill-25::after, .quota-card i.meter-fill-25::after { width: 25%; }
.meter i.meter-fill-30::after, .quota-card i.meter-fill-30::after { width: 30%; }
.meter i.meter-fill-35::after, .quota-card i.meter-fill-35::after { width: 35%; }
.meter i.meter-fill-40::after, .quota-card i.meter-fill-40::after { width: 40%; }
.meter i.meter-fill-45::after, .quota-card i.meter-fill-45::after { width: 45%; }
.meter i.meter-fill-50::after, .quota-card i.meter-fill-50::after { width: 50%; }
.meter i.meter-fill-55::after, .quota-card i.meter-fill-55::after { width: 55%; }
.meter i.meter-fill-60::after, .quota-card i.meter-fill-60::after { width: 60%; }
.meter i.meter-fill-65::after, .quota-card i.meter-fill-65::after { width: 65%; }
.meter i.meter-fill-70::after, .quota-card i.meter-fill-70::after { width: 70%; }
.meter i.meter-fill-75::after, .quota-card i.meter-fill-75::after { width: 75%; }
.meter i.meter-fill-80::after, .quota-card i.meter-fill-80::after { width: 80%; }
.meter i.meter-fill-85::after, .quota-card i.meter-fill-85::after { width: 85%; }
.meter i.meter-fill-90::after, .quota-card i.meter-fill-90::after { width: 90%; }
.meter i.meter-fill-95::after, .quota-card i.meter-fill-95::after { width: 95%; }
.meter i.meter-fill-100::after, .quota-card i.meter-fill-100::after { width: 100%; }
.meter.warn i::after { background: var(--amber); }
.meter.danger i::after { background: var(--red); }
.meter.neutral { align-content: start; }
.form-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 14px; }
.wide { grid-column: 1 / -1; }
.actions, .toolbar { display: flex; gap: 10px; align-items: center; flex-wrap: wrap; margin-top: 14px; }
.actions.right { justify-content: flex-end; }
.toolbar {
  padding: 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: linear-gradient(180deg, #fbfcfe, var(--panel-soft));
  min-width: 0;
}
.toolbar label { min-width: min(240px, 100%); }
.compact-toolbar {
  margin-top: 0;
  padding: 0;
  border: 0;
  background: transparent;
}
.context-strip {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  align-items: center;
  padding: 9px 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #f8fbff;
  box-shadow: none;
  min-width: 0;
}
.context-strip > * { min-width: 0; }
.context-summary {
  display: flex;
  gap: 8px;
  align-items: baseline;
  min-width: 0;
}
.context-summary span,
.account-switch label > span {
  color: var(--muted);
  font-size: 11px;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0;
}
.context-summary strong {
  font-size: 14px;
}
.context-summary small {
  color: var(--muted);
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.account-switch {
  gap: 8px;
}
.account-switch label {
  display: flex;
  gap: 8px;
  align-items: center;
  min-width: 0;
}
.account-switch select {
  width: min(240px, 34vw);
  min-height: 34px;
  padding-top: 6px;
  padding-bottom: 6px;
}
.account-switch button {
  min-height: 34px;
  padding: 0 12px;
}
.file-browser {
  display: grid;
  gap: 12px;
}
.file-browser-toolbar {
  display: grid;
  grid-template-columns: minmax(220px, 1fr) auto;
  gap: 12px;
  align-items: end;
}
.file-browser-toolbar .actions {
  margin-top: 0;
}
.breadcrumb {
  display: flex;
  gap: 7px;
  align-items: center;
  flex-wrap: wrap;
  padding: 10px 12px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: #f8fbff;
  color: var(--muted);
}
.table-wrap {
  overflow: auto;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: #fff;
  box-shadow: 0 1px 2px rgba(16, 24, 40, .04);
  max-height: min(72vh, 860px);
}
table { width: 100%; border-collapse: separate; border-spacing: 0; min-width: 760px; background: #fff; }
th, td { padding: 12px 14px; border-bottom: 1px solid var(--line-soft); text-align: left; vertical-align: middle; font-size: 13px; }
th { color: #667085; background: #f8fafc; font-size: 10px; text-transform: uppercase; letter-spacing: .055em; white-space: nowrap; }
td { color: #182230; }
th .sort-btn {
  min-height: 0;
  padding: 0;
  background: transparent;
  color: inherit;
  border: 0;
  box-shadow: none;
  font-size: inherit;
  text-transform: inherit;
  letter-spacing: inherit;
}
th .sort-btn::after { content: " ↕"; color: #98a2b3; }
th .sort-btn.up::after { content: " ↑"; color: var(--blue); }
th .sort-btn.down::after { content: " ↓"; color: var(--blue); }
tr:last-child td { border-bottom: 0; }
tbody tr:hover { background: #fbfdff; }
tbody tr:hover td { background: #fbfdff; }
tr.filtered { display: none; }
.muted-row { opacity: .68; }
td:last-child {
  min-width: 150px;
  white-space: normal;
}
td button {
  min-height: 30px;
  padding: 6px 9px;
  font-size: 11px;
  margin: 0 4px 6px 0;
}
td .danger-btn, td button + button { margin-left: 0; }
td .actions { margin-top: 0; }
.table-controls {
  display: flex;
  justify-content: space-between;
  gap: 10px;
  align-items: center;
  padding: 12px 14px;
  border-top: 1px solid var(--line);
  color: var(--muted);
  font-size: 12px;
  font-weight: 800;
}
.table-controls > div { display: flex; gap: 8px; }
.table-controls button {
  min-height: 32px;
  padding: 6px 10px;
  font-size: 12px;
}
.empty { color: var(--muted); text-align: center; padding: 26px; }
.empty strong::before {
  content: "";
  width: 28px;
  height: 28px;
  display: block;
  margin: 0 auto 8px;
  border-radius: 8px;
  border: 1px solid #d9e2ec;
  background: linear-gradient(180deg, #fff, #f3f6fa);
}
.empty strong, .empty span { display: block; }
.empty strong { color: var(--ink); margin-bottom: 4px; }
.badge {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 999px;
  padding: 4px 8px;
  background: #eef2f6;
  color: #475569;
  font-size: 10px;
  font-weight: 900;
  text-transform: capitalize;
  white-space: nowrap;
}
.badge.active, .badge.succeeded { background: #dcfce7; color: var(--green); }
.badge.ok, .badge.unlimited { background: #dcfce7; color: var(--green); }
.badge.pending, .badge.running, .badge.queued { background: #fef3c7; color: var(--amber); }
.badge.near_limit { background: #fef3c7; color: var(--amber); }
.badge.failed, .badge.deleted, .badge.canceled, .badge.over_limit, .badge.block { background: #fee4e2; color: var(--red); }
.badge.allow { background: #dcfce7; color: var(--green); }
.output {
  width: 100%;
  overflow: auto;
  margin: 12px 0 0;
  padding: 12px;
  border-radius: var(--radius);
  background: #0b1220;
  color: #e6edf7;
  font-size: 12px;
  line-height: 1.55;
}
.small-output { max-height: 280px; }
.list { display: grid; gap: 10px; }
.priority {
  width: fit-content;
  border-radius: 999px;
  padding: 3px 8px;
  font-size: 11px;
  font-weight: 900;
  text-transform: uppercase;
  background: #eef2f6;
}
.priority.high { background: #ffe0de; color: var(--red); }
.priority.medium { background: #fff1cc; color: var(--amber); }
.priority.low { background: #ddf4e8; color: var(--green); }
.checklist { display: grid; gap: 10px; }
.security-stack, .setup-secret {
  display: grid;
  gap: 10px;
}
.divider {
  height: 1px;
  background: var(--line);
  margin: 4px 0;
}
.setup-secret {
  padding: 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--panel-soft);
}
code {
  display: inline-block;
  max-width: min(520px, 100%);
  overflow: hidden;
  text-overflow: ellipsis;
  overflow-wrap: anywhere;
  vertical-align: bottom;
  color: #334155;
  background: #f6f8fb;
  border: 1px solid #edf2f7;
  border-radius: 5px;
  padding: 1px 4px;
}
dialog {
  border: 0;
  border-radius: 12px;
  padding: 0;
  box-shadow: 0 28px 90px rgba(15,23,42,.25);
}
dialog::backdrop { background: rgba(15,23,42,.48); }
.dialog-card { width: min(480px, calc(100vw - 32px)); padding: 22px; background: #fff; }
.form-dialog-card { width: min(680px, calc(100vw - 32px)); }
.form-dialog-card .panel-head { margin-bottom: 18px; }
.dialog-card .actions { margin-top: 18px; }
.dialog-card p { color: var(--muted); margin-top: 8px; }
.stack-form {
  display: grid;
  gap: 2px;
}
.stack-form .actions {
  justify-content: flex-end;
  padding-top: 4px;
}
.panel > .stack-form:first-child .actions {
  justify-content: flex-start;
}
@media (max-width: 1120px) {
  .metric-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .grid-2, .service-grid, .summary-grid, .feature-grid, .quota-grid, .dns-preset-grid, .meters { grid-template-columns: 1fr; }
  .dashboard-hero { grid-template-columns: 1fr; }
  .quick-actions { justify-content: flex-start; }
  .file-browser-toolbar { grid-template-columns: 1fr; }
  .unauthenticated .login-layout { grid-template-columns: 1fr; }
  .login-hero { min-height: 300px; }
}
@media (max-width: 960px) {
  .app-shell { display: block; }
  .sidebar {
    position: relative;
    height: auto;
    min-height: 0;
    grid-template-rows: none;
    gap: 14px;
    padding: 16px;
    overflow: hidden;
  }
  .nav {
    display: flex;
    gap: 9px;
    overflow-x: auto;
    padding-bottom: 4px;
    scroll-snap-type: x proximity;
  }
  .nav-group {
    min-width: max-content;
    display: flex;
    gap: 8px;
    padding: 0;
  }
  .nav-group > span { display: none; }
  .nav-item {
    width: auto;
    min-width: 150px;
    min-height: 44px;
    scroll-snap-align: start;
    grid-template-columns: 28px minmax(0, 1fr);
  }
  .nav-item i { width: 26px; height: 26px; }
  .nav-item small { display: none; }
  .sidebar-note { grid-template-columns: 1fr; }
  .workspace { padding: 18px 16px 28px; }
  .topbar { display: grid; gap: 16px; margin-bottom: 18px; padding-bottom: 18px; }
  .top-actions { justify-content: stretch; }
  .top-actions > * { width: 100%; }
  .metric-grid, .form-grid { grid-template-columns: 1fr; }
  .module-header { display: grid; padding: 16px; }
  .module-header .actions { margin-top: 0; }
  .list-toolbar { grid-template-columns: 1fr; }
  .dashboard-hero { padding: 18px; }
  .dashboard-hero h2 { font-size: 22px; }
  .quick-actions {
    display: grid;
    grid-template-columns: 1fr;
    width: 100%;
  }
  .quick-actions > * {
    min-width: 0;
    width: 100%;
  }
  .login-hero { display: none; }
  .unauthenticated .workspace { align-content: start; padding-top: 32px; }
  .unauthenticated .login-layout { display: block; }
  .panel { padding: 16px; border-radius: 10px; }
  .panel-head { display: grid; gap: 12px; }
  .table-wrap {
    overflow: visible;
    border: 0;
    border-radius: 0;
    box-shadow: none;
  }
  table, thead, tbody, tr, th, td {
    display: block;
    width: 100%;
  }
  table {
    min-width: 0;
    background: transparent;
  }
  thead {
    position: absolute;
    width: 1px;
    height: 1px;
    overflow: hidden;
    clip: rect(0 0 0 0);
  }
  tbody {
    display: grid;
    gap: 10px;
  }
  tr {
    border: 1px solid var(--line);
    border-radius: 10px;
    background: #fff;
    overflow: hidden;
    box-shadow: var(--shadow-soft);
  }
  td {
    display: grid;
    grid-template-columns: minmax(92px, 32%) minmax(0, 1fr);
    gap: 10px;
    align-items: start;
    min-height: 43px;
    border-bottom: 1px solid var(--line-soft);
    word-break: break-word;
  }
  td:last-child { border-bottom: 0; }
  td > * { min-width: 0; }
  td::before {
    content: attr(data-label);
    color: #667085;
    font-size: 11px;
    font-weight: 900;
    text-transform: uppercase;
  }
  td.empty {
    display: block;
    text-align: left;
  }
  .empty strong::before { margin-left: 0; }
  td.empty::before { content: ""; display: none; }
  td .danger-btn, td button + button { margin-left: 0; }
  td button {
    width: auto;
    min-width: min(120px, 100%);
    margin: 0 6px 6px 0;
  }
  td .link-btn { width: auto; text-align: left; }
  .table-controls {
    display: grid;
  }
  .table-controls > div {
    display: grid;
    grid-template-columns: 1fr 1fr;
  }
}
@media (max-width: 480px) {
  .workspace { padding: 14px; }
  h1 { font-size: 25px; }
  .dashboard-hero, .panel { padding: 15px; }
  .dashboard-hero h2 { font-size: 23px; }
  .stack-form, .form-grid, .form-grid > *, .actions, .actions > *, .toolbar > * {
    max-width: 100%;
    min-width: 0;
  }
  .actions > *, .toolbar > * { width: 100%; }
  .actions button { white-space: normal; }
  .context-strip { display: grid; }
  td { grid-template-columns: minmax(82px, 30%) minmax(0, 1fr); }
  td:last-child { grid-template-columns: 1fr; }
  td:last-child::before { margin-bottom: -4px; }
}
@media (max-width: 340px) {
  td { grid-template-columns: 1fr; }
  td::before { margin-bottom: -4px; }
}
