:root {
  --bg: #f3f6f9;
  --surface: #ffffff;
  --surface-2: #f8fafc;
  --surface-3: #eef4f7;
  --ink: #10243b;
  --ink-strong: #081c34;
  --muted: #61738a;
  --muted-2: #8997a9;
  --line: #d8e1e9;
  --line-strong: #c6d3de;
  --nav: #081b31;
  --nav-2: #0d2744;
  --nav-3: #123652;
  --accent: #00a9c4;
  --accent-strong: #007f98;
  --accent-dark: #00677c;
  --accent-soft: #e8f8fb;
  --success: #1f9d70;
  --success-soft: #e7f7f1;
  --warning: #d89a22;
  --danger: #c94f55;
  --danger-soft: #fdeff0;
  --shadow-sm: 0 3px 12px rgba(15, 37, 61, .06);
  --shadow: 0 10px 30px rgba(15, 37, 61, .08);
  --shadow-lg: 0 22px 55px rgba(10, 31, 54, .12);
  --radius-sm: 9px;
  --radius: 14px;
  --radius-lg: 20px;
  --sidebar-width: 278px;
  --transition: 160ms ease;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  min-height: 100vh;
  background:
    radial-gradient(circle at 92% 0%, rgba(0, 169, 196, .07), transparent 26rem),
    var(--bg);
  color: var(--ink);
  font-family: "Segoe UI", Tahoma, Arial, sans-serif;
  font-size: 14px;
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
}

button, input, textarea, select { font: inherit; }
button { -webkit-tap-highlight-color: transparent; }

/* Sidebar */
.sidebar {
  position: fixed;
  inset: 0 auto 0 0;
  width: var(--sidebar-width);
  display: flex;
  flex-direction: column;
  padding: 20px 16px 18px;
  color: #d8e5ef;
  background:
    radial-gradient(circle at 0 0, rgba(0, 169, 196, .18), transparent 19rem),
    linear-gradient(180deg, #0b223b 0%, #07182b 100%);
  border-right: 1px solid rgba(255,255,255,.05);
  box-shadow: 14px 0 34px rgba(3, 16, 30, .12);
  z-index: 20;
}

.brand {
  margin: 0 2px 18px;
  padding: 16px 14px 13px;
  border-radius: 15px;
  background: #fff;
  box-shadow: 0 9px 24px rgba(0,0,0,.16);
  overflow: hidden;
}
.brand img {
  display: block;
  width: min(100%, 196px);
  height: auto;
  margin: 0 auto;
  object-fit: contain;
}
.brand-copy {
  margin-top: 7px;
  text-align: center;
  color: #64758a;
  font-size: 10px;
  font-weight: 700;
  letter-spacing: 1.8px;
  text-transform: uppercase;
}

nav { overflow: auto; padding: 2px 3px 12px; scrollbar-width: thin; }
nav p {
  margin: 19px 10px 7px;
  color: #68829e;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 1.6px;
}
nav button {
  position: relative;
  width: 100%;
  margin: 2px 0;
  padding: 11px 13px 11px 17px;
  border: 1px solid transparent;
  border-radius: 10px;
  background: transparent;
  color: #afc2d4;
  text-align: left;
  font-size: 13px;
  font-weight: 600;
  cursor: pointer;
  transition: background var(--transition), color var(--transition), border-color var(--transition), transform var(--transition);
}
nav button:hover {
  color: #fff;
  background: rgba(255,255,255,.055);
  transform: translateX(2px);
}
nav button.active {
  color: #fff;
  background: linear-gradient(90deg, rgba(0,169,196,.22), rgba(255,255,255,.05));
  border-color: rgba(0, 169, 196, .28);
  box-shadow: inset 3px 0 0 var(--accent);
}
nav button.active::after {
  content: "";
  position: absolute;
  right: 12px;
  top: 50%;
  width: 6px;
  height: 6px;
  margin-top: -3px;
  border-radius: 50%;
  background: var(--accent);
  box-shadow: 0 0 0 4px rgba(0,169,196,.12);
}

.side-footer {
  margin-top: auto;
  padding: 14px 12px 3px;
  border-top: 1px solid rgba(255,255,255,.09);
  display: flex;
  align-items: center;
  gap: 9px;
  color: #8fa5bb;
  font-size: 11px;
}
.side-footer span:first-child {
  flex: 0 0 auto;
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--warning);
  box-shadow: 0 0 0 4px rgba(216,154,34,.12);
}

/* Main shell */
main {
  width: calc(100% - var(--sidebar-width));
  margin-left: var(--sidebar-width);
  padding: 0 34px 56px;
}
header {
  position: sticky;
  top: 0;
  z-index: 12;
  min-height: 88px;
  margin-bottom: 28px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  background: color-mix(in srgb, var(--bg) 89%, transparent);
  backdrop-filter: blur(16px);
  border-bottom: 1px solid var(--line);
}
.header-copy small,
header small {
  display: block;
  margin-bottom: 2px;
  color: var(--accent-strong);
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 1.7px;
}
header h1 {
  margin: 0;
  color: var(--ink-strong);
  font-size: 24px;
  font-weight: 760;
  letter-spacing: -.4px;
}
.header-actions {
  display: flex;
  align-items: center;
  gap: 10px;
}
.network-pill {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  min-height: 36px;
  padding: 0 12px;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: var(--surface);
  color: var(--muted);
  font-size: 11px;
  font-weight: 700;
  box-shadow: var(--shadow-sm);
}
.network-pill::before {
  content: "";
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: var(--success);
  box-shadow: 0 0 0 4px rgba(31,157,112,.10);
}
.icon-button {
  width: 38px;
  height: 38px;
  padding: 0;
  border-radius: 11px;
  background: var(--surface);
  color: var(--ink);
  border: 1px solid var(--line);
  box-shadow: var(--shadow-sm);
  font-size: 17px;
}
.icon-button:hover { border-color: var(--accent); color: var(--accent-strong); }

.page { display: none; max-width: 1380px; animation: page-in .2s ease; }
.page.active { display: block; }
@keyframes page-in { from { opacity: 0; transform: translateY(4px); } to { opacity: 1; transform: none; } }

/* Typography */
h1, h2, h3 { color: var(--ink-strong); }
h2 { margin: 8px 0 6px; font-size: 30px; line-height: 1.2; letter-spacing: -.55px; }
h3 { margin: 24px 0 10px; font-size: 18px; }
.section-lead { margin-bottom: 22px; }
.section-lead p { max-width: 760px; margin: 0; color: var(--muted); font-size: 14px; }
.pill {
  display: inline-flex;
  align-items: center;
  min-height: 24px;
  padding: 0 10px;
  border-radius: 999px;
  background: #dff6fa;
  color: #007c94;
  font-size: 9px;
  font-weight: 850;
  letter-spacing: 1.45px;
}

/* Home */
.hero {
  position: relative;
  min-height: 280px;
  padding: 42px 46px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  overflow: hidden;
  border-radius: 24px;
  background:
    radial-gradient(circle at 84% 20%, rgba(0,185,212,.24), transparent 18rem),
    linear-gradient(125deg, #09213a 0%, #0d3850 55%, #087f96 145%);
  color: #fff;
  box-shadow: var(--shadow-lg);
}
.hero::after {
  content: "";
  position: absolute;
  right: -110px;
  bottom: -170px;
  width: 420px;
  height: 420px;
  border: 1px solid rgba(255,255,255,.08);
  border-radius: 50%;
  box-shadow: 0 0 0 38px rgba(255,255,255,.018), 0 0 0 76px rgba(255,255,255,.012);
}
.hero > div:first-child { position: relative; z-index: 2; }
.hero .pill { background: rgba(255,255,255,.13); color: #dffbff; border: 1px solid rgba(255,255,255,.11); }
.hero h2 { margin: 16px 0 11px; color: #fff; font-size: clamp(34px, 4vw, 48px); line-height: 1.07; letter-spacing: -1.5px; }
.hero p { max-width: 650px; margin: 0; color: #c5d8e5; font-size: 15px; line-height: 1.7; }
.hero-mark { position: relative; z-index: 1; color: rgba(255,255,255,.045); font-size: 118px; font-weight: 900; letter-spacing: -8px; }

.stats {
  margin: 18px 0 24px;
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 12px;
}
.stats article {
  padding: 19px 21px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--surface);
  box-shadow: var(--shadow-sm);
}
.stats b { display: block; color: var(--ink-strong); font-size: 23px; font-weight: 760; }
.stats span { display: block; margin-top: 2px; color: var(--muted); font-size: 11px; }

.cards { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 13px; }
.cards button {
  min-height: 150px;
  padding: 22px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--surface);
  color: var(--ink);
  text-align: left;
  box-shadow: var(--shadow-sm);
  transition: transform var(--transition), border-color var(--transition), box-shadow var(--transition);
}
.cards button:hover { transform: translateY(-3px); border-color: rgba(0,169,196,.55); box-shadow: var(--shadow); }
.cards i { color: var(--accent-strong); font-style: normal; font-size: 10px; font-weight: 800; letter-spacing: 1.2px; }
.cards b { display: block; margin: 18px 0 5px; color: var(--ink-strong); font-size: 16px; }
.cards span { color: var(--muted); font-size: 12px; line-height: 1.55; }

/* Generic panels & controls */
.panel {
  padding: 22px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--surface);
  box-shadow: var(--shadow-sm);
}
.form-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 17px; }
.wide { grid-column: 1 / -1; }
label {
  display: flex;
  flex-direction: column;
  gap: 7px;
  color: #53667d;
  font-size: 11px;
  font-weight: 750;
}
label small { color: var(--muted-2); font-weight: 600; }
input, textarea, select {
  width: 100%;
  border: 1px solid var(--line-strong);
  border-radius: 10px;
  outline: none;
  background: var(--surface);
  color: var(--ink);
  padding: 10px 12px;
  font-size: 13px;
  box-shadow: inset 0 1px 1px rgba(14, 38, 63, .025);
  transition: border-color var(--transition), box-shadow var(--transition), background var(--transition);
}
input:hover, textarea:hover, select:hover { border-color: #b7c7d4; }
input:focus, textarea:focus, select:focus {
  border-color: var(--accent);
  box-shadow: 0 0 0 3px rgba(0,169,196,.11);
}
textarea { min-height: 104px; resize: vertical; line-height: 1.45; }

button {
  border: 1px solid transparent;
  border-radius: 9px;
  background: linear-gradient(180deg, #078ea6, #007e96);
  color: #fff;
  padding: 10px 17px;
  font-size: 12px;
  font-weight: 750;
  cursor: pointer;
  box-shadow: 0 3px 8px rgba(0, 126, 150, .12);
  transition: transform var(--transition), box-shadow var(--transition), filter var(--transition), opacity var(--transition);
}
button:hover:not(:disabled) { filter: brightness(1.035); box-shadow: 0 6px 14px rgba(0,126,150,.17); transform: translateY(-1px); }
button:active:not(:disabled) { transform: translateY(0); }
button:disabled { opacity: .58; cursor: wait; box-shadow: none; }
button.secondary {
  background: #eef2f6;
  border-color: #e2e8ee;
  color: #354a61;
  box-shadow: none;
}
button.secondary:hover:not(:disabled) { background: #e5ebf1; box-shadow: none; }
.actions { display: flex; justify-content: flex-end; align-items: center; gap: 8px; }

/* Tables */
.table-scroll {
  overflow: auto;
  margin-top: 17px;
  border: 1px solid var(--line);
  border-radius: 12px;
  background: var(--surface);
}
.result-table {
  width: 100%;
  margin: 0;
  border-collapse: separate;
  border-spacing: 0;
  background: var(--surface);
}
.result-table thead td {
  position: sticky;
  top: 0;
  z-index: 2;
  background: #f4f8fa;
  color: #526980;
  font-family: inherit;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: .25px;
  text-transform: none;
}
.result-table td {
  padding: 10px 13px;
  border-bottom: 1px solid #e7edf2;
  color: var(--ink);
  font-family: "Segoe UI", Tahoma, Arial, sans-serif;
  font-size: 12px;
  font-weight: 400;
  white-space: nowrap;
}
.result-table tbody tr:last-child td { border-bottom: 0; }
.result-table tbody tr:hover td { background: #f7fbfc; }
.result-table td:first-child { font-weight: 650; }

/* Config editor */
.config-controls {
  display: grid;
  grid-template-columns: minmax(220px, 2fr) minmax(120px, 1fr) minmax(130px, 1fr) minmax(130px, 1fr) auto auto;
  gap: 11px;
  align-items: end;
}
.code-editor {
  min-height: 500px;
  margin-top: 13px;
  padding: 18px;
  border: 1px solid #1b3a55;
  border-radius: 14px;
  background: #0a192b;
  color: #d4ecf4;
  font: 12px/1.55 Consolas, "SFMono-Regular", monospace;
  tab-size: 2;
  box-shadow: inset 0 0 0 1px rgba(255,255,255,.018), var(--shadow-sm);
}
.notice { padding: 10px 2px; color: var(--muted); font-size: 11px; }

/* Modem */
.toolbar { display: flex; align-items: center; gap: 12px; margin-bottom: 15px; }
.toolbar > input { max-width: 360px; }
.toolbar div { display: flex; flex-wrap: wrap; gap: 5px; }
.toolbar button { background: #edf2f6; color: #40536a; box-shadow: none; }
.toolbar button.active { background: var(--accent-strong); color: #fff; }
.command-list { display: grid; grid-template-columns: repeat(2, minmax(0,1fr)); gap: 13px; }
.command-card {
  padding: 18px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--surface);
  box-shadow: var(--shadow-sm);
}
.command-card h3 { margin: 8px 0 7px; font-size: 15px; }
.command-card small { color: var(--accent-strong); font-size: 9px; font-weight: 800; letter-spacing: 1px; }
.command-card p { min-height: 34px; color: var(--muted); font-size: 11px; line-height: 1.5; }
.command-card code {
  display: block;
  margin: 11px 0;
  padding: 12px 13px;
  overflow-x: auto;
  border: 1px solid #183d59;
  border-radius: 9px;
  background: #0c2035;
  color: #d6eff4;
  font-size: 11px;
  white-space: pre-wrap;
}

.placeholder { min-height: 300px; padding: 38px; border: 1px dashed var(--line); border-radius: var(--radius); background: var(--surface-2); }
.placeholder p { color: var(--muted); }

#toast {
  position: fixed;
  top: 84px;
  left: 50%;
  z-index: 2000;
  width: min(560px, calc(100vw - 32px));
  min-height: 46px;
  padding: 12px 18px 12px 46px;
  border: 1px solid rgba(74, 145, 196, .30);
  border-radius: 12px;
  background: rgba(16, 38, 63, .97);
  color: #fff;
  box-shadow: 0 12px 32px rgba(7, 25, 43, .20);
  opacity: 0;
  transform: translate(-50%, -12px);
  transition: opacity .18s ease, transform .18s ease;
  pointer-events: none;
  font-family: "Segoe UI", Tahoma, Arial, sans-serif;
  font-size: 13px;
  font-weight: 500;
  line-height: 1.45;
}

#toast::before {
  content: "i";
  position: absolute;
  left: 16px;
  top: 50%;
  width: 20px;
  height: 20px;
  display: grid;
  place-items: center;
  transform: translateY(-50%);
  border-radius: 50%;
  background: #0a8da7;
  color: #fff;
  font-size: 11px;
  font-weight: 700;
  font-style: normal;
}

#toast.show {
  opacity: 1;
  transform: translate(-50%, 0);
  pointer-events: auto;
  cursor: pointer;
}

body.dark #toast {
  border-color: #31506b;
  background: rgba(13, 32, 51, .98);
  box-shadow: 0 12px 34px rgba(0, 0, 0, .34);
}

@media (max-width: 700px) {
  #toast {
    top: 72px;
    width: calc(100vw - 24px);
    padding: 11px 14px 11px 42px;
    font-size: 12px;
  }
  #toast::before { left: 13px; }
}

/* Dark mode */
body.dark {
  --bg: #09131f;
  --surface: #102035;
  --surface-2: #0c1a2b;
  --surface-3: #172b40;
  --ink: #dce8f2;
  --ink-strong: #f4f8fb;
  --muted: #91a3b7;
  --muted-2: #71869d;
  --line: #213850;
  --line-strong: #2c455e;
  --accent-soft: #123348;
  --shadow-sm: 0 3px 12px rgba(0,0,0,.11);
  --shadow: 0 10px 30px rgba(0,0,0,.18);
  --shadow-lg: 0 22px 55px rgba(0,0,0,.28);
}
body.dark header { background: rgba(9, 19, 31, .9); }
body.dark input,
body.dark textarea,
body.dark select { color-scheme: dark; }
body.dark button.secondary,
body.dark .toolbar button { background: #172b40; border-color: #284158; color: #c8d7e4; }
body.dark .result-table thead td { background: #15293d; color: #a9bbcb; }
body.dark .result-table tbody tr:hover td { background: #13283b; }
body.dark .pill { background: #123448; color: #78dce9; }
body.dark .brand { background: #fff; }

/* Responsive */
@media (max-width: 1100px) {
  :root { --sidebar-width: 238px; }
  main { padding-left: 24px; padding-right: 24px; }
  .config-controls { grid-template-columns: repeat(2, minmax(0,1fr)); }
  .config-controls button { width: 100%; }
}
@media (max-width: 860px) {
  :root { --sidebar-width: 78px; }
  .sidebar { padding-left: 10px; padding-right: 10px; }
  .brand { padding: 10px 6px; border-radius: 11px; }
  .brand img { width: 54px; }
  .brand-copy, nav p, .side-footer span:last-child { display: none; }
  nav button { padding: 11px 6px; text-align: center; font-size: 0; }
  nav button::before { content: attr(data-page); font-size: 8px; text-transform: uppercase; letter-spacing: .2px; }
  nav button.active::after { display: none; }
  .side-footer { justify-content: center; padding-left: 0; padding-right: 0; }
  main { padding: 0 18px 40px; }
  .network-pill { display: none; }
  .stats { grid-template-columns: repeat(2, minmax(0,1fr)); }
  .cards, .command-list { grid-template-columns: 1fr; }
}
@media (max-width: 620px) {
  .form-grid, .stats { grid-template-columns: 1fr; }
  .wide { grid-column: auto; }
  .hero { min-height: 250px; padding: 28px 25px; }
  .hero-mark { display: none; }
  .hero h2 { font-size: 32px; }
  header { min-height: 76px; }
  header h1 { font-size: 20px; }
  .toolbar { align-items: stretch; flex-direction: column; }
  .toolbar > input { max-width: none; }
  .config-controls { grid-template-columns: 1fr; }
  .actions { flex-wrap: wrap; }
}

/* -------------------------------------------------------------------------
   Overview dashboard
   ------------------------------------------------------------------------- */
.home-hero {
  min-height: 228px;
  padding: 34px 42px;
}
.home-hero h2 {
  margin: 14px 0 9px;
  font-size: clamp(32px, 3.5vw, 44px);
}
.home-hero p {
  max-width: 760px;
  font-size: 14px;
}
.hero-actions {
  position: relative;
  z-index: 2;
  display: flex;
  flex-wrap: wrap;
  gap: 9px;
  margin-top: 21px;
}
.hero-actions button {
  min-height: 38px;
  padding: 9px 16px;
  border-color: rgba(255,255,255,.18);
  background: #ffffff;
  color: #0b3650;
  box-shadow: 0 7px 20px rgba(0,0,0,.10);
}
.hero-actions button:hover:not(:disabled) {
  border-color: rgba(255,255,255,.55);
  box-shadow: 0 9px 24px rgba(0,0,0,.15);
}
.hero-actions .hero-secondary {
  background: rgba(255,255,255,.09);
  border-color: rgba(255,255,255,.20);
  color: #f0fbff;
  box-shadow: none;
}
.hero-actions .hero-secondary:hover:not(:disabled) {
  background: rgba(255,255,255,.15);
}

.home-stats {
  margin: 14px 0 20px;
  gap: 10px;
}
.home-stats article {
  min-height: 86px;
  padding: 14px 17px;
}
.home-stats .stat-kicker {
  margin: 0 0 3px;
  color: var(--accent-strong);
  font-size: 8px;
  font-weight: 850;
  letter-spacing: 1.05px;
}
.home-stats b {
  font-size: 21px;
  line-height: 1.08;
}
.home-stats article > span:last-child {
  margin-top: 5px;
  font-size: 10px;
}

.quick-access-heading {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  margin: 0 0 11px;
}
.quick-access-heading h3 {
  margin: 7px 0 1px;
  font-size: 18px;
}
.quick-access-heading p {
  margin: 0;
  color: var(--muted);
  font-size: 11px;
}

.quick-access-grid {
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: 10px;
}
.quick-access-grid button {
  position: relative;
  min-height: 116px;
  padding: 16px 17px 15px;
  overflow: hidden;
}
.quick-access-grid button::after {
  content: "›";
  position: absolute;
  right: 14px;
  top: 14px;
  color: #a8b8c6;
  font-size: 20px;
  font-weight: 400;
  line-height: 1;
  transition: color var(--transition), transform var(--transition);
}
.quick-access-grid button:hover::after {
  color: var(--accent-strong);
  transform: translateX(2px);
}
.quick-access-grid i {
  display: block;
  padding-right: 24px;
  font-size: 8px;
  line-height: 1.3;
}
.quick-access-grid b {
  margin: 14px 0 4px;
  padding-right: 16px;
  font-size: 14px;
}
.quick-access-grid span {
  display: -webkit-box;
  overflow: hidden;
  font-size: 10px;
  line-height: 1.45;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
}

body.dark .hero-actions button {
  background: #f7fbfd;
  color: #0b3650;
}
body.dark .hero-actions .hero-secondary {
  background: rgba(255,255,255,.09);
  color: #f0fbff;
}

@media (max-width: 1250px) {
  .quick-access-grid { grid-template-columns: repeat(4, minmax(0, 1fr)); }
}
@media (max-width: 1050px) {
  .quick-access-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); }
}
@media (max-width: 860px) {
  .quick-access-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (max-width: 620px) {
  .home-hero { min-height: 250px; padding: 28px 25px; }
  .hero-actions { align-items: stretch; flex-direction: column; }
  .quick-access-grid { grid-template-columns: 1fr; }
  .quick-access-grid button { min-height: 104px; }
}

/* -------------------------------------------------------------------------
   Gateway configuration workspace - desktop-parity mapping layout
   ------------------------------------------------------------------------- */
.config-workspace{display:grid;gap:14px}.config-card{background:var(--surface);border:1px solid var(--line);border-radius:14px;box-shadow:var(--shadow-sm);padding:18px}.config-card-heading{display:flex;align-items:center;justify-content:space-between;gap:14px;margin-bottom:14px}.config-card-heading h3{margin:3px 0 0;font-size:17px}.config-eyebrow{display:block;color:var(--accent-strong);font-size:9px;font-weight:850;letter-spacing:1.15px}.config-badge,.config-chip-count{display:inline-flex;align-items:center;min-height:28px;padding:5px 10px;border:1px solid var(--line);border-radius:999px;background:var(--surface-2);color:var(--muted);font-size:10px;font-weight:700}.config-selector-grid{display:grid;grid-template-columns:minmax(180px,.9fr) minmax(220px,1.2fr);gap:12px 16px}.config-template-field,.config-output-field{grid-column:1/-1}.config-mapping-panel{margin-top:16px;padding:12px;border:1px solid var(--line);border-radius:12px;background:var(--surface-2)}.config-mapping-title-row{display:flex;align-items:center;justify-content:space-between;gap:12px;margin-bottom:9px}.config-mapping-title-row strong{font-size:12px;color:var(--ink-strong)}.config-mapping-grid{--config-chip-count:8;display:grid;grid-template-columns:minmax(76px,.55fr) repeat(var(--config-chip-count),minmax(72px,1fr));gap:5px;align-items:center;overflow-x:auto;padding:5px}.config-map-corner,.config-map-row-label{font-size:10px;font-weight:750;color:var(--muted);padding:7px 8px}.config-map-head{text-align:center;font-size:10px;font-weight:800;color:var(--ink-strong);padding:6px}.config-mapping-grid select{min-width:68px;height:34px;padding:5px 25px 5px 9px;border-radius:6px;font-size:11px;text-align:center}.config-map-actions{display:flex;justify-content:center;margin-top:10px}.config-map-actions button{min-width:220px}.config-mapping-hint{margin:10px 0 0;text-align:center;color:var(--muted);font-size:10px}.config-preview-card{padding:0;overflow:hidden}.config-preview-summary{display:flex;align-items:center;justify-content:space-between;gap:18px;padding:14px 16px;border-bottom:1px solid var(--line);background:var(--surface-2)}.config-preview-summary>div{display:grid;grid-template-columns:auto auto;align-items:center;gap:3px 18px}.config-preview-summary .config-eyebrow{grid-column:1/-1}.config-preview-summary strong{font-size:12px}.config-preview-summary span:last-child{color:var(--muted);font-size:10px}.config-editor-collapsed{display:none}.config-preview-actions{display:flex;justify-content:center;gap:8px;padding:13px 16px 8px}.config-preview-actions button{min-width:150px}.config-status{margin:0 auto 14px;max-width:760px;padding:8px 14px;border-radius:8px;background:var(--accent-soft);color:var(--accent-strong);font-size:10px;text-align:center}.config-preview-dialog{width:min(1100px,94vw);height:min(760px,90vh);padding:0;border:1px solid var(--line);border-radius:15px;background:var(--surface);color:var(--ink);box-shadow:0 28px 90px rgba(0,0,0,.28)}.config-preview-dialog::backdrop{background:rgba(3,15,27,.62);backdrop-filter:blur(2px)}.config-dialog-head{display:flex;align-items:center;justify-content:space-between;padding:15px 18px;border-bottom:1px solid var(--line)}.config-dialog-head h3{margin:3px 0 0}.config-editor-max{display:block;width:calc(100% - 28px);height:calc(100% - 145px);min-height:430px;margin:14px}.config-dialog-actions{display:flex;justify-content:flex-end;padding:0 14px 14px}
@media(max-width:1100px){.config-mapping-grid{grid-template-columns:minmax(70px,.55fr) repeat(var(--config-chip-count),minmax(66px,1fr))}.config-preview-summary>div{grid-template-columns:1fr}.config-preview-summary .config-eyebrow{grid-column:auto}.config-preview-actions{flex-wrap:wrap}}
@media(max-width:720px){.config-selector-grid{grid-template-columns:1fr}.config-template-field,.config-output-field{grid-column:auto}.config-card{padding:13px}.config-preview-summary{align-items:flex-start;flex-direction:column}.config-preview-summary button{width:100%}.config-preview-actions{display:grid;grid-template-columns:1fr}.config-preview-actions button{width:100%}.config-mapping-panel{overflow:hidden}}

/* ========================================================================== */
/* Gateway Configurator - polished workstation layout                         */
/* ========================================================================== */
#page-config .section-lead{
  margin-bottom:18px;
}
#page-config .config-workspace{
  gap:18px;
}
#page-config .config-card{
  position:relative;
  overflow:hidden;
  border:1px solid color-mix(in srgb,var(--line) 86%,var(--accent) 14%);
  border-radius:18px;
  padding:22px;
  box-shadow:0 10px 28px rgba(22,45,72,.065);
}
#page-config .config-card:first-child::before{
  content:"";
  position:absolute;
  inset:0 0 auto 0;
  height:3px;
  background:linear-gradient(90deg,var(--accent),var(--accent2));
}
#page-config .config-card-heading{
  margin-bottom:20px;
  padding-bottom:14px;
  border-bottom:1px solid var(--line);
}
#page-config .config-card-heading h3{
  font-size:20px;
  line-height:1.2;
  letter-spacing:-.25px;
}
#page-config .config-eyebrow{
  margin-bottom:5px;
  color:var(--accent2);
  font-size:10px;
  font-weight:800;
  letter-spacing:1.55px;
}
#page-config .config-badge,
#page-config .config-chip-count{
  gap:7px;
  min-height:31px;
  padding:6px 12px;
  border-color:color-mix(in srgb,var(--accent) 22%,var(--line));
  background:linear-gradient(180deg,var(--surface),var(--surface-2));
  color:var(--accent2);
  font-size:10px;
  font-weight:800;
  box-shadow:0 2px 8px rgba(16,53,75,.05);
}
#page-config .config-badge::before,
#page-config .config-chip-count::before{
  content:"";
  width:7px;
  height:7px;
  border-radius:50%;
  background:var(--accent);
  box-shadow:0 0 0 3px color-mix(in srgb,var(--accent) 15%,transparent);
}
#page-config .config-selector-grid{
  grid-template-columns:minmax(210px,.9fr) minmax(260px,1.2fr);
  gap:16px 18px;
}
#page-config .config-selector-grid label{
  gap:8px;
  color:var(--ink-strong);
  font-size:11px;
  font-weight:750;
}
#page-config .config-selector-grid select,
#page-config .config-selector-grid input{
  height:44px;
  border-radius:11px;
  border-color:color-mix(in srgb,var(--line) 88%,var(--accent) 12%);
  background:var(--surface);
  padding:0 14px;
  font-weight:650;
  color:var(--ink-strong);
  box-shadow:0 1px 2px rgba(16,42,67,.02);
  transition:border-color .16s ease,box-shadow .16s ease,background .16s ease;
}
#page-config .config-selector-grid select:hover,
#page-config .config-selector-grid input:hover{
  border-color:color-mix(in srgb,var(--accent) 46%,var(--line));
}
#page-config .config-selector-grid select:focus,
#page-config .config-selector-grid input:focus{
  border-color:var(--accent);
  box-shadow:0 0 0 3px color-mix(in srgb,var(--accent) 13%,transparent);
}
#page-config #config-output-name{
  font-family:"Segoe UI",Tahoma,Arial,sans-serif;
}

#page-config .config-mapping-panel{
  position:relative;
  margin-top:22px;
  padding:18px;
  border:1px solid color-mix(in srgb,var(--accent) 21%,var(--line));
  border-radius:16px;
  background:
    radial-gradient(circle at 100% 0,color-mix(in srgb,var(--accent) 8%,transparent),transparent 32%),
    linear-gradient(180deg,color-mix(in srgb,var(--surface-2) 88%,white 12%),var(--surface-2));
  box-shadow:inset 0 1px 0 color-mix(in srgb,white 70%,transparent);
}
#page-config .config-mapping-title-row{
  margin-bottom:15px;
}
#page-config .config-mapping-title-row strong{
  display:flex;
  align-items:center;
  gap:9px;
  color:var(--ink-strong);
  font-size:14px;
  font-weight:800;
}
#page-config .config-mapping-title-row strong::before{
  content:"";
  width:4px;
  height:19px;
  border-radius:999px;
  background:linear-gradient(var(--accent),var(--accent2));
}
#page-config .config-mapping-grid{
  --config-chip-count:8;
  grid-template-columns:minmax(74px,.52fr) repeat(var(--config-chip-count),minmax(78px,1fr));
  gap:8px;
  padding:10px;
  border:1px solid color-mix(in srgb,var(--line) 92%,var(--accent) 8%);
  border-radius:13px;
  background:color-mix(in srgb,var(--surface) 89%,var(--surface-2) 11%);
  box-shadow:0 5px 16px rgba(21,48,71,.04);
}
#page-config .config-map-corner,
#page-config .config-map-row-label{
  display:flex;
  align-items:center;
  min-height:39px;
  padding:8px 10px;
  border-radius:9px;
  background:var(--surface-2);
  color:var(--muted);
  font-size:10px;
  font-weight:800;
  letter-spacing:.15px;
}
#page-config .config-map-head{
  display:flex;
  align-items:center;
  justify-content:center;
  min-height:39px;
  border-radius:9px;
  background:linear-gradient(180deg,color-mix(in srgb,var(--accent-soft) 64%,var(--surface)),var(--surface));
  color:var(--accent2);
  font-size:11px;
  font-weight:850;
}
#page-config .config-mapping-grid select{
  width:100%;
  min-width:72px;
  height:39px;
  padding:5px 27px 5px 10px;
  border:1px solid var(--line);
  border-radius:9px;
  background:var(--surface);
  color:var(--ink-strong);
  font-size:11px;
  font-weight:700;
  text-align:center;
  transition:border-color .16s ease,box-shadow .16s ease,transform .16s ease;
}
#page-config .config-mapping-grid select:hover{
  border-color:color-mix(in srgb,var(--accent) 55%,var(--line));
}
#page-config .config-mapping-grid select:focus{
  border-color:var(--accent);
  box-shadow:0 0 0 3px color-mix(in srgb,var(--accent) 12%,transparent);
  transform:translateY(-1px);
}
#page-config .config-map-actions{
  margin-top:16px;
}
#page-config .config-map-actions button{
  position:relative;
  min-width:250px;
  height:43px;
  border-radius:11px;
  background:linear-gradient(135deg,var(--accent2),var(--accent));
  box-shadow:0 7px 16px color-mix(in srgb,var(--accent2) 20%,transparent);
}
#page-config .config-map-actions button:hover{
  transform:translateY(-1px);
  box-shadow:0 10px 22px color-mix(in srgb,var(--accent2) 25%,transparent);
}
#page-config .config-mapping-hint{
  max-width:820px;
  margin:12px auto 0;
  color:var(--muted);
  font-size:10px;
  line-height:1.5;
}

#page-config .config-preview-card{
  padding:0;
  border-radius:18px;
}
#page-config .config-preview-card::before{
  content:"";
  position:absolute;
  inset:0 0 auto 0;
  height:3px;
  background:linear-gradient(90deg,color-mix(in srgb,var(--accent2) 72%,white),var(--accent));
}
#page-config .config-preview-summary{
  min-height:76px;
  padding:18px 20px 16px;
  background:linear-gradient(180deg,color-mix(in srgb,var(--surface-2) 78%,var(--surface)),var(--surface));
}
#page-config .config-preview-summary>div{
  grid-template-columns:auto 1fr;
  gap:3px 18px;
}
#page-config .config-preview-summary strong{
  color:var(--ink-strong);
  font-size:14px;
}
#page-config .config-preview-summary span:last-child{
  font-size:11px;
  line-height:1.45;
}
#page-config #maximize-config-preview{
  min-width:154px;
  height:40px;
  border:1px solid color-mix(in srgb,var(--accent) 18%,var(--line));
  background:var(--surface);
  color:var(--accent2);
}
#page-config #maximize-config-preview:hover{
  border-color:color-mix(in srgb,var(--accent) 45%,var(--line));
  background:var(--accent-soft);
}
#page-config .config-preview-actions{
  gap:10px;
  padding:16px 20px 10px;
  background:var(--surface);
}
#page-config .config-preview-actions button{
  min-width:158px;
  height:41px;
  border-radius:10px;
}
#page-config #download-config{
  background:linear-gradient(135deg,var(--accent2),var(--accent));
  box-shadow:0 6px 14px color-mix(in srgb,var(--accent2) 17%,transparent);
}
#page-config .config-status{
  max-width:820px;
  margin:0 auto 18px;
  padding:9px 16px;
  border:1px solid color-mix(in srgb,var(--accent) 15%,transparent);
  border-radius:999px;
  background:color-mix(in srgb,var(--accent-soft) 75%,var(--surface));
  color:var(--accent2);
  font-size:10px;
  font-weight:650;
}

#page-config .config-preview-dialog{
  border-radius:20px;
  overflow:hidden;
}
#page-config .config-dialog-head{
  padding:18px 20px;
  background:linear-gradient(180deg,var(--surface),var(--surface-2));
}
#page-config .config-editor-max{
  border-radius:13px;
  border:1px solid #20364d;
  box-shadow:inset 0 1px 0 rgba(255,255,255,.04);
}
#page-config .config-dialog-actions{
  padding:0 18px 18px;
}

body.dark #page-config .config-mapping-panel{
  background:linear-gradient(180deg,color-mix(in srgb,var(--surface-2) 88%,#07111d 12%),var(--surface-2));
}
body.dark #page-config .config-mapping-grid{
  background:color-mix(in srgb,var(--surface) 90%,#09131f 10%);
}
body.dark #page-config .config-map-head{
  background:color-mix(in srgb,var(--accent-soft) 45%,var(--surface));
}

@media(max-width:1100px){
  #page-config .config-mapping-grid{
    grid-template-columns:minmax(72px,.52fr) repeat(var(--config-chip-count),minmax(76px,1fr));
  }
}
@media(max-width:720px){
  #page-config .config-card{padding:16px;border-radius:15px}
  #page-config .config-card-heading{align-items:flex-start}
  #page-config .config-selector-grid{grid-template-columns:1fr}
  #page-config .config-template-field,#page-config .config-output-field{grid-column:auto}
  #page-config .config-mapping-panel{padding:12px}
  #page-config .config-preview-summary{padding:16px;align-items:stretch}
  #page-config .config-preview-summary>div{grid-template-columns:1fr}
  #page-config #maximize-config-preview{width:100%}
  #page-config .config-preview-actions{grid-template-columns:1fr;padding:14px 16px}
  #page-config .config-preview-actions button{width:100%}
}

/* Certificate output-folder picker */
.certificate-form-grid{margin-bottom:18px}
.certificate-format-row{margin-top:16px;max-width:620px}
.output-folder-card{margin-top:18px;padding:18px;border:1px solid var(--line);border-radius:14px;background:linear-gradient(180deg,var(--surface),var(--bg));box-shadow:0 8px 22px rgba(19,34,55,.05)}
.output-folder-copy{display:grid;gap:4px;margin-bottom:12px}
.output-folder-kicker{font-size:10px;font-weight:800;letter-spacing:1.4px;color:var(--accent2)}
.output-folder-copy strong{font-size:15px;color:var(--ink)}
.output-folder-copy small,.output-folder-note{font-size:12px;line-height:1.5;color:var(--muted)}
.output-folder-row{display:grid;grid-template-columns:minmax(0,1fr) auto;gap:10px;align-items:center}
.output-folder-row input[readonly]{background:var(--surface);font-weight:600;color:var(--muted)}
.output-folder-row input.has-folder{color:var(--ink);border-color:var(--accent);box-shadow:0 0 0 3px color-mix(in srgb,var(--accent) 12%,transparent)}
.output-folder-row button{white-space:nowrap;min-width:145px}
.output-folder-note{margin-top:8px}
@media(max-width:700px){.output-folder-row{grid-template-columns:1fr}.output-folder-row button{width:100%}}

/* ========================================================================== */
/* Gateway Configurator - refined workstation presentation                    */
/* ========================================================================== */
#page-config{
  --cfg-border:color-mix(in srgb,var(--line) 84%,var(--accent) 16%);
  --cfg-soft:color-mix(in srgb,var(--accent-soft) 34%,var(--surface) 66%);
}
#page-config .section-lead{
  margin-bottom:16px;
}
#page-config .section-lead h2{
  margin-bottom:5px;
}
#page-config .config-workspace{
  gap:16px;
}
#page-config .config-card{
  border:1px solid var(--cfg-border);
  border-radius:18px;
  padding:22px 24px 24px;
  background:
    linear-gradient(180deg,color-mix(in srgb,var(--surface) 98%,var(--accent-soft) 2%),var(--surface));
  box-shadow:0 12px 34px rgba(14,43,67,.075);
}
#page-config .config-card:first-child::before{
  height:4px;
  background:linear-gradient(90deg,var(--accent2),var(--accent) 58%,color-mix(in srgb,var(--accent) 25%,transparent));
}
#page-config .config-card-heading{
  align-items:flex-start;
  margin-bottom:18px;
  padding-bottom:16px;
}
#page-config .config-card-heading h3{
  margin-top:4px;
  font-size:21px;
  font-weight:750;
  letter-spacing:-.35px;
}
#page-config .config-eyebrow{
  color:var(--accent2);
  font-size:9px;
  font-weight:850;
  letter-spacing:1.7px;
}
#page-config .config-badge,
#page-config .config-chip-count{
  min-height:32px;
  padding:6px 12px;
  background:var(--surface);
  border:1px solid color-mix(in srgb,var(--accent) 28%,var(--line));
  color:var(--accent2);
  box-shadow:0 4px 14px rgba(20,57,80,.055);
}
#page-config .config-selector-grid{
  grid-template-columns:minmax(260px,.85fr) minmax(320px,1.15fr);
  gap:14px 18px;
}
#page-config .config-selector-grid label{
  gap:7px;
  padding:0;
  color:var(--ink-strong);
  font-size:11px;
  font-weight:750;
}
#page-config .config-selector-grid select,
#page-config .config-selector-grid input{
  height:46px;
  padding:0 15px;
  border:1px solid color-mix(in srgb,var(--line) 82%,var(--accent) 18%);
  border-radius:11px;
  background:linear-gradient(180deg,var(--surface),color-mix(in srgb,var(--surface) 96%,var(--bg) 4%));
  box-shadow:0 2px 5px rgba(18,48,70,.025);
  color:var(--ink-strong);
  font-size:13px;
  font-weight:650;
}
#page-config .config-selector-grid select:focus,
#page-config .config-selector-grid input:focus{
  border-color:var(--accent);
  box-shadow:0 0 0 3px color-mix(in srgb,var(--accent) 13%,transparent),0 4px 10px rgba(20,70,95,.05);
}
#page-config .config-template-field,
#page-config .config-output-field{
  grid-column:1/-1;
}

#page-config .config-mapping-panel{
  margin-top:20px;
  padding:18px;
  border:1px solid color-mix(in srgb,var(--accent) 29%,var(--line));
  border-radius:16px;
  background:
    radial-gradient(circle at 96% 7%,color-mix(in srgb,var(--accent) 8%,transparent),transparent 30%),
    linear-gradient(180deg,color-mix(in srgb,var(--surface-2) 90%,white 10%),color-mix(in srgb,var(--surface-2) 97%,var(--accent-soft) 3%));
  box-shadow:inset 0 1px 0 rgba(255,255,255,.65),0 5px 16px rgba(16,50,73,.035);
}
#page-config .config-mapping-title-row{
  margin-bottom:13px;
  padding:0 2px;
}
#page-config .config-mapping-title-row strong{
  gap:10px;
  font-size:14px;
  font-weight:800;
  letter-spacing:-.1px;
}
#page-config .config-mapping-title-row strong::before{
  width:5px;
  height:20px;
  border-radius:4px;
  background:linear-gradient(180deg,var(--accent),var(--accent2));
}
#page-config .config-mapping-grid{
  gap:7px;
  padding:10px;
  border:1px solid color-mix(in srgb,var(--line) 88%,var(--accent) 12%);
  border-radius:14px;
  background:var(--surface);
  box-shadow:0 5px 18px rgba(18,47,70,.045);
}
#page-config .config-map-corner,
#page-config .config-map-row-label{
  min-height:42px;
  padding:9px 10px;
  border:0;
  border-radius:9px;
  background:color-mix(in srgb,var(--surface-2) 88%,var(--accent-soft) 12%);
  color:var(--muted);
  font-size:10px;
  font-weight:800;
}
#page-config .config-map-head{
  min-height:42px;
  border:1px solid color-mix(in srgb,var(--accent) 14%,var(--line));
  border-radius:9px;
  background:linear-gradient(180deg,color-mix(in srgb,var(--accent-soft) 56%,var(--surface)),var(--surface));
  color:var(--accent2);
  font-size:11px;
  font-weight:850;
  box-shadow:inset 0 1px 0 rgba(255,255,255,.55);
}
#page-config .config-mapping-grid select{
  height:42px;
  min-width:74px;
  border:1px solid color-mix(in srgb,var(--line) 82%,var(--accent) 18%);
  border-radius:9px;
  background:var(--surface);
  color:var(--ink-strong);
  font-size:12px;
  font-weight:700;
  box-shadow:0 1px 3px rgba(19,49,70,.025);
}
#page-config .config-mapping-grid select:hover{
  border-color:color-mix(in srgb,var(--accent) 60%,var(--line));
  background:color-mix(in srgb,var(--surface) 96%,var(--accent-soft) 4%);
}
#page-config .config-mapping-grid select:focus{
  border-color:var(--accent);
  background:var(--surface);
  box-shadow:0 0 0 3px color-mix(in srgb,var(--accent) 14%,transparent);
  transform:none;
}
#page-config .config-map-actions{
  margin-top:18px;
}
#page-config .config-map-actions button{
  min-width:280px;
  height:45px;
  padding:0 22px;
  border-radius:11px;
  background:linear-gradient(135deg,#087990,#05a9c3);
  color:#fff;
  font-weight:750;
  box-shadow:0 9px 20px rgba(8,121,144,.2);
}
#page-config .config-map-actions button:hover{
  transform:translateY(-1px);
  box-shadow:0 12px 26px rgba(8,121,144,.26);
}
#page-config .config-mapping-hint{
  margin:13px auto 0;
  max-width:900px;
  color:var(--muted);
  font-size:10px;
  line-height:1.55;
}

#page-config .config-preview-card{
  padding:0;
  border-radius:17px;
  overflow:hidden;
}
#page-config .config-preview-summary{
  min-height:72px;
  padding:15px 18px;
  background:linear-gradient(180deg,color-mix(in srgb,var(--surface-2) 72%,var(--surface)),var(--surface));
}
#page-config .config-preview-summary>div{
  display:grid;
  grid-template-columns:auto 1fr;
  align-items:center;
  gap:3px 18px;
}
#page-config .config-preview-summary .config-eyebrow{
  grid-column:1/-1;
}
#page-config .config-preview-summary strong{
  font-size:14px;
  font-weight:750;
}
#page-config .config-preview-summary span:last-child{
  color:var(--muted);
  font-size:10px;
}
#page-config #maximize-config-preview{
  min-width:158px;
  height:40px;
  border:1px solid color-mix(in srgb,var(--accent) 24%,var(--line));
  border-radius:10px;
  background:var(--surface);
  color:var(--accent2);
  font-weight:700;
}
#page-config #maximize-config-preview::before{
  content:"↗";
  margin-right:7px;
  font-size:12px;
}
#page-config #maximize-config-preview:hover{
  border-color:var(--accent);
  background:var(--accent-soft);
}
#page-config .config-preview-actions{
  gap:9px;
  padding:14px 18px 9px;
}
#page-config .config-preview-actions button{
  min-width:155px;
  height:40px;
  border-radius:10px;
}
#page-config #download-config{
  background:linear-gradient(135deg,var(--accent2),var(--accent));
  color:#fff;
  box-shadow:0 7px 16px rgba(8,121,144,.16);
}
#page-config .config-status{
  max-width:760px;
  margin:0 auto 15px;
  padding:8px 14px;
  border:1px solid color-mix(in srgb,var(--accent) 16%,transparent);
  border-radius:9px;
  background:color-mix(in srgb,var(--accent-soft) 64%,var(--surface));
  color:var(--accent2);
  font-size:10px;
  font-weight:650;
}

body.dark #page-config .config-card{
  background:linear-gradient(180deg,var(--surface),color-mix(in srgb,var(--surface) 94%,#07121d 6%));
}
body.dark #page-config .config-mapping-panel{
  background:linear-gradient(180deg,color-mix(in srgb,var(--surface-2) 90%,#07121d 10%),var(--surface-2));
}
body.dark #page-config .config-mapping-grid{
  background:color-mix(in srgb,var(--surface) 93%,#07121d 7%);
}

@media(max-width:1180px){
  #page-config .config-selector-grid{grid-template-columns:1fr 1fr}
  #page-config .config-mapping-grid{grid-template-columns:minmax(72px,.52fr) repeat(var(--config-chip-count),minmax(76px,1fr))}
}
@media(max-width:760px){
  #page-config .config-card{padding:17px}
  #page-config .config-selector-grid{grid-template-columns:1fr}
  #page-config .config-template-field,#page-config .config-output-field{grid-column:auto}
  #page-config .config-mapping-panel{padding:13px}
  #page-config .config-preview-summary{align-items:stretch;flex-direction:column}
  #page-config #maximize-config-preview{width:100%}
  #page-config .config-preview-actions{display:grid;grid-template-columns:1fr;padding:13px 15px}
  #page-config .config-preview-actions button{width:100%}
}

/* ========================================================================== */
/* Products Lookup Tool branding + operational overview                        */
/* ========================================================================== */
.products-hero {
  min-height: 280px;
  padding: 36px 42px;
  background:
    radial-gradient(circle at 88% 20%, rgba(35,190,210,.22), transparent 22rem),
    linear-gradient(118deg, #0a2b45 0%, #0b4158 58%, #08748a 100%);
}
.products-hero h2 {
  max-width: 720px;
  margin-bottom: 12px;
  font-size: clamp(38px, 4vw, 54px);
  letter-spacing: -1.8px;
}
.products-hero p { max-width: 760px; }
.product-hero-icon {
  width: 190px;
  height: 190px;
  display: grid;
  place-items: center;
  border: 1px solid rgba(255,255,255,.10);
  border-radius: 50%;
  background: rgba(255,255,255,.035);
  box-shadow: inset 0 0 0 25px rgba(255,255,255,.018);
}
.product-hero-icon svg {
  width: 104px;
  height: 104px;
  fill: none;
  stroke: rgba(225,251,255,.42);
  stroke-width: 3;
  stroke-linecap: round;
  stroke-linejoin: round;
}
.overview-summary-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 12px;
  margin: 16px 0;
}
.overview-summary-card {
  min-height: 132px;
  display: grid;
  grid-template-columns: 42px minmax(0,1fr);
  gap: 12px;
  align-items: start;
  padding: 17px;
  border: 1px solid var(--line);
  border-radius: 14px;
  background: linear-gradient(180deg, var(--surface), var(--surface-2));
  box-shadow: var(--shadow-sm);
}
.overview-summary-icon {
  width: 40px;
  height: 40px;
  display: grid;
  place-items: center;
  border: 1px solid color-mix(in srgb, var(--accent) 24%, var(--line));
  border-radius: 11px;
  background: var(--accent-soft);
  color: var(--accent-strong);
  font-size: 21px;
  font-weight: 650;
}
.overview-summary-card strong { display:block; margin:2px 0 5px; color:var(--ink-strong); font-size:13px; }
.overview-summary-card p { margin:0; color:var(--muted); font-size:10.5px; line-height:1.55; }
.products-home-stats { margin-top: 0; }
.overview-ready-mark { color: var(--success) !important; font-size: 20px !important; line-height: 1; }

/* Persistent processing monitor shown on every main page. */
.global-processing-dock {
  position: relative;
  z-index: 10;
  margin: -10px 0 22px;
  padding: 12px 14px 13px;
  border: 1px solid color-mix(in srgb, var(--accent) 28%, var(--line));
  border-radius: 14px;
  background:
    radial-gradient(circle at 100% 0%, rgba(0,169,196,.08), transparent 18rem),
    linear-gradient(180deg, var(--surface), var(--surface-2));
  box-shadow: 0 8px 24px rgba(15,37,61,.07);
}
.global-processing-heading {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 9px;
  color: var(--muted);
  font-size: 10px;
}
.global-processing-heading > div { display:flex; align-items:center; gap:8px; }
.global-processing-heading strong { color: var(--ink-strong); font-size: 11.5px; }
#global-processing-count {
  padding: 2px 7px;
  border-radius: 999px;
  background: var(--accent-soft);
  color: var(--accent-strong);
  font-weight: 700;
}
.processing-live-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--accent);
  box-shadow: 0 0 0 4px rgba(0,169,196,.12);
  animation: global-processing-pulse 1.5s ease-in-out infinite;
}
@keyframes global-processing-pulse { 50% { box-shadow:0 0 0 7px rgba(0,169,196,.035); } }
.global-processing-jobs {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 8px;
}
.global-processing-job {
  position: relative;
  min-width: 0;
  min-height: 62px;
  display: grid;
  grid-template-columns: 34px minmax(0,1fr) auto;
  grid-template-rows: auto auto;
  column-gap: 10px;
  row-gap: 3px;
  align-items: center;
  padding: 9px 11px;
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: 11px;
  background: var(--surface);
  color: var(--ink);
  text-align: left;
  box-shadow: none;
  cursor: pointer;
  transition: border-color var(--transition), transform var(--transition), box-shadow var(--transition);
}
.global-processing-job:hover {
  border-color: color-mix(in srgb, var(--accent) 52%, var(--line));
  transform: translateY(-1px);
  box-shadow: var(--shadow-sm);
}
.global-job-icon {
  grid-row: 1 / 3;
  width: 32px;
  height: 32px;
  display: grid;
  place-items: center;
  border-radius: 9px;
  background: var(--accent-soft);
  color: var(--accent-strong);
  font-size: 15px;
  font-weight: 700;
}
.global-processing-job.complete .global-job-icon { background:var(--success-soft); color:var(--success); }
.global-processing-job.stopped .global-job-icon { background:#fff6e6; color:#a66f14; }
.global-processing-job.error .global-job-icon { background:var(--danger-soft); color:var(--danger); }
.global-job-copy { min-width:0; display:grid; gap:1px; }
.global-job-copy strong { overflow:hidden; color:var(--ink-strong); font-size:10.5px; text-overflow:ellipsis; white-space:nowrap; }
.global-job-copy small { color:var(--muted); font-size:9.5px; font-weight:500; }
.global-job-summary { grid-column:2; color:var(--muted); font-size:9px; }
.global-job-open { grid-column:3; grid-row:1/3; color:var(--accent-strong); font-size:9.5px; font-weight:700; }
.global-job-progress {
  position: absolute;
  inset: auto 0 0;
  height: 3px;
  background: var(--surface-3);
}
.global-job-progress span {
  display:block;
  height:100%;
  border-radius:0 999px 999px 0;
  background:linear-gradient(90deg,var(--accent-strong),var(--accent));
  transition:width .25s ease;
}
.global-processing-job.complete .global-job-progress span { background:var(--success); }
.global-processing-job.stopped .global-job-progress span { background:var(--warning); }
.global-processing-job.error .global-job-progress span { background:var(--danger); }
body.dark .global-processing-dock,
body.dark .overview-summary-card { background:linear-gradient(180deg,#10263a,#0d2033); }
body.dark .global-processing-job { background:#12283b; border-color:#29445a; }

@media (max-width: 1180px) {
  .overview-summary-grid { grid-template-columns: repeat(2,minmax(0,1fr)); }
}
@media (max-width: 760px) {
  .products-hero { padding:28px 24px; }
  .product-hero-icon { display:none; }
  .overview-summary-grid { grid-template-columns:1fr; }
  .global-processing-heading { align-items:flex-start; flex-direction:column; gap:5px; }
  .global-processing-jobs { grid-template-columns:1fr; }
}

/* ========================================================================== */
/* 2026-10 Global visual polish + sticky active processing monitor            */
/* ========================================================================== */

/* Keep the cross-workspace processing monitor visible while users scroll. */
.global-processing-dock {
  position: sticky;
  top: 96px;
  z-index: 11;
  margin: -12px 0 22px;
  max-height: min(36vh, 360px);
  overflow: auto;
  border-color: color-mix(in srgb, var(--accent) 36%, var(--line));
  background:
    linear-gradient(135deg, rgba(0,169,196,.055), transparent 42%),
    color-mix(in srgb, var(--surface) 94%, transparent);
  backdrop-filter: blur(18px) saturate(1.12);
  box-shadow: 0 14px 34px rgba(15,37,61,.12), 0 1px 0 rgba(255,255,255,.7) inset;
}
.global-processing-dock:not([hidden]) { animation: dock-enter .18s ease-out; }
@keyframes dock-enter { from { opacity:0; transform:translateY(-5px); } to { opacity:1; transform:none; } }
.global-processing-heading {
  position: sticky;
  top: -12px;
  z-index: 2;
  margin: -12px -14px 10px;
  padding: 12px 14px 10px;
  border-bottom: 1px solid color-mix(in srgb, var(--line) 78%, transparent);
  background: color-mix(in srgb, var(--surface) 92%, transparent);
  backdrop-filter: blur(18px);
}
.global-processing-jobs { gap: 10px; }
.global-processing-job {
  min-height: 68px;
  padding: 10px 12px;
  border-radius: 13px;
  background: linear-gradient(180deg, var(--surface), color-mix(in srgb, var(--surface-2) 68%, var(--surface)));
  box-shadow: 0 3px 12px rgba(15,37,61,.045);
}
.global-processing-job:hover {
  border-color: color-mix(in srgb, var(--accent) 65%, var(--line));
  box-shadow: 0 8px 20px rgba(15,37,61,.09);
}
.global-job-icon { width:34px; height:34px; border-radius:10px; }
.global-job-copy strong { font-size:11px; }
.global-job-copy small,
.global-job-summary { font-size:9.5px; }

/* Consistent content width, spacing and section hierarchy on every workspace. */
.page { padding-bottom: 20px; }
.section-lead {
  margin: 0 0 20px;
  padding: 0 2px;
}
.section-lead h2 {
  margin-top: 7px;
  font-size: clamp(26px, 2.4vw, 32px);
  letter-spacing: -.65px;
}
.section-lead p { margin-top: 7px; line-height: 1.6; }

.panel,
.tool-workspace,
.config-card,
.config-preview-card {
  border: 1px solid color-mix(in srgb, var(--line) 92%, transparent);
  box-shadow: 0 9px 27px rgba(15,37,61,.065);
}
.panel,
.tool-workspace { border-radius: 16px; }

/* Make all forms feel like one product rather than separate utilities. */
.form-grid {
  gap: 17px 18px;
  padding: 22px;
}
label {
  color: #445b73;
  font-size: 11px;
  font-weight: 680;
}
input,
select,
textarea {
  border-color: var(--line-strong);
  border-radius: 10px;
  background: var(--surface);
  color: var(--ink-strong);
  transition: border-color var(--transition), box-shadow var(--transition), background var(--transition);
}
input:not([type="checkbox"]):not([type="radio"]),
select { min-height: 42px; }
input:focus,
select:focus,
textarea:focus {
  outline: none;
  border-color: var(--accent);
  box-shadow: 0 0 0 3px rgba(0,169,196,.10);
}
textarea { resize: vertical; }

button {
  border-radius: 9px;
  font-weight: 650;
  letter-spacing: -.05px;
  transition: transform var(--transition), background var(--transition), border-color var(--transition), box-shadow var(--transition), color var(--transition);
}
button:hover:not(:disabled) { transform: translateY(-1px); }
button:active:not(:disabled) { transform: translateY(0); }
button:focus-visible {
  outline: 3px solid rgba(0,169,196,.16);
  outline-offset: 2px;
}
button.secondary {
  border: 1px solid var(--line);
  background: var(--surface-2);
  color: #38516a;
  box-shadow: none;
}
button.secondary:hover:not(:disabled) {
  border-color: color-mix(in srgb, var(--accent) 42%, var(--line));
  background: var(--accent-soft);
  color: var(--accent-strong);
}

/* Scope tabs and feature cards: clearer selected state and less visual noise. */
.scope-tabs {
  margin-bottom: 8px;
  padding: 4px;
  border-radius: 12px;
  background: color-mix(in srgb, var(--surface-2) 68%, var(--surface));
}
.scope-tabs button { min-height: 36px; }
.scope-tabs button.active {
  background: linear-gradient(180deg, #078da6, #007d96);
  box-shadow: 0 5px 13px rgba(0,126,150,.18);
}
.feature-grid { gap: 10px; margin-top: 16px; }
.feature-grid button {
  min-height: 52px;
  border-radius: 12px;
  background: linear-gradient(180deg, var(--surface), color-mix(in srgb, var(--surface-2) 62%, var(--surface)));
}
.feature-grid button.active {
  background: linear-gradient(180deg, #f0fbfd, #e5f7fa);
  box-shadow: inset 3px 0 0 var(--accent), 0 5px 15px rgba(15,37,61,.055);
}

/* Tables: slightly denser, clearer sticky header, softer striping and hover. */
.table-scroll,
.stream-table-scroll {
  border-radius: 13px;
  border-color: var(--line);
  box-shadow: 0 5px 18px rgba(15,37,61,.045);
}
.result-table,
.stream-result-table {
  border-collapse: separate;
  border-spacing: 0;
}
.result-table thead td,
.stream-result-table thead td {
  color: #405a73;
  font-size: 10.5px;
  font-weight: 750;
  letter-spacing: .02em;
  background: #f4f8fa;
  border-bottom: 1px solid var(--line-strong);
}
.result-table tbody tr:nth-child(even) td,
.stream-result-table tbody tr:nth-child(even) td {
  background: color-mix(in srgb, var(--surface-2) 58%, transparent);
}
.result-table tbody tr:hover td,
.stream-result-table tbody tr:hover td {
  background: color-mix(in srgb, var(--accent-soft) 46%, var(--surface));
}

/* Tool-specific surfaces. */
.toolbar {
  padding: 12px;
  border: 1px solid var(--line);
  border-radius: 13px;
  background: var(--surface);
  box-shadow: var(--shadow-sm);
}
.notice {
  border-radius: 11px;
  border: 1px solid var(--line);
  background: var(--surface-2);
}
.code-editor {
  border-radius: 13px;
  box-shadow: inset 0 1px 3px rgba(12,30,48,.04);
}
.command-card {
  border-radius: 15px;
  box-shadow: 0 7px 21px rgba(15,37,61,.055);
}
.command-card:hover { box-shadow: 0 11px 28px rgba(15,37,61,.085); }

/* Billing, LNS, Embedded LNS and reports share the same card language. */
#billing-form,
#lns-form,
#embedded-form,
#report-form,
#bulk-report-form,
#join-form {
  background:
    linear-gradient(180deg, rgba(255,255,255,.72), rgba(248,250,252,.86)),
    var(--surface);
}

/* Action areas feel anchored to the content they operate on. */
.inline-actions,
.actions {
  gap: 9px;
}
.inline-actions button,
.actions button { min-height: 38px; }

/* Dark mode parity. */
body.dark label { color: #a8bfd1; }
body.dark input,
body.dark select,
body.dark textarea { background:#102439; border-color:#29455c; color:#e4eef5; }
body.dark .panel,
body.dark .tool-workspace,
body.dark .config-card,
body.dark .config-preview-card { box-shadow:none; }
body.dark .feature-grid button { background:linear-gradient(180deg,#11273b,#0f2235); }
body.dark .feature-grid button.active { background:linear-gradient(180deg,#12394a,#102f40); }
body.dark .result-table thead td,
body.dark .stream-result-table thead td { background:#152c41; color:#bdd0de; }
body.dark .result-table tbody tr:nth-child(even) td,
body.dark .stream-result-table tbody tr:nth-child(even) td { background:#10263a; }
body.dark .result-table tbody tr:hover td,
body.dark .stream-result-table tbody tr:hover td { background:#143448; }
body.dark .global-processing-dock {
  background: color-mix(in srgb, #10263a 94%, transparent);
  border-color:#285169;
  box-shadow:0 14px 34px rgba(0,0,0,.28);
}
body.dark .global-processing-heading { background:color-mix(in srgb,#10263a 94%,transparent); }

@media (max-width: 760px) {
  .global-processing-dock { top: 82px; max-height: 45vh; }
  .form-grid { padding: 17px; gap: 14px; }
  .section-lead h2 { font-size: 25px; }
}

/* ========================================================================== */
/* Compact sticky active-processing strip                                     */
/* ========================================================================== */
.global-processing-dock {
  margin: -8px 0 12px;
  padding: 6px 9px 7px;
  max-height: min(24vh, 190px);
  border-radius: 11px;
  box-shadow: 0 6px 18px rgba(15,37,61,.08);
}
.global-processing-heading {
  position: static;
  margin: 0 0 5px;
  padding: 0;
  min-height: 18px;
  border-bottom: 0;
  background: transparent;
  backdrop-filter: none;
  font-size: 8.5px;
}
.global-processing-heading strong { font-size: 10px; }
.global-processing-heading > span:last-child {
  font-size: 8px;
  opacity: .78;
}
#global-processing-count {
  padding: 1px 5px;
  font-size: 8px;
}
.processing-live-dot {
  width: 6px;
  height: 6px;
  box-shadow: 0 0 0 3px rgba(0,169,196,.10);
}
.global-processing-jobs {
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: 5px;
}
.global-processing-job {
  min-height: 42px;
  grid-template-columns: 24px minmax(0,1fr) auto;
  grid-template-rows: auto auto;
  column-gap: 7px;
  row-gap: 0;
  padding: 5px 8px 6px;
  border-radius: 9px;
  box-shadow: none;
}
.global-processing-job:hover {
  transform: none;
  box-shadow: 0 3px 10px rgba(15,37,61,.07);
}
.global-job-icon {
  width: 22px;
  height: 22px;
  border-radius: 7px;
  font-size: 11px;
}
.global-job-copy { gap: 0; }
.global-job-copy strong { font-size: 9px; line-height: 1.2; }
.global-job-copy small { font-size: 8px; line-height: 1.2; }
.global-job-summary {
  font-size: 7.5px;
  line-height: 1.15;
}
.global-job-open {
  padding: 3px 6px;
  border-radius: 6px;
  background: var(--accent-soft);
  font-size: 8px;
  line-height: 1;
}
.global-job-progress { height: 2px; }

@media (max-width: 760px) {
  .global-processing-dock { top: 82px; max-height: 30vh; padding:6px 8px; }
  .global-processing-heading { flex-direction:row; align-items:center; gap:8px; }
  .global-processing-heading > span:last-child { display:none; }
  .global-processing-job { min-height:40px; }
}

/* ========================================================================== */
/* Minimal sticky active-processing status                                    */
/* ========================================================================== */
.global-processing-dock {
  margin: -5px 0 9px;
  padding: 5px 8px 6px;
  max-height: min(18vh, 130px);
  border-radius: 10px;
  box-shadow: 0 4px 12px rgba(15,37,61,.06);
}
.global-processing-heading {
  margin: 0 0 4px;
  min-height: 15px;
}
.global-processing-heading > div {
  gap: 6px;
}
.global-processing-heading strong {
  font-size: 9px;
  font-weight: 650;
}
#global-processing-count {
  padding: 1px 5px;
  font-size: 7.5px;
  font-weight: 650;
}
.processing-live-dot {
  width: 5px;
  height: 5px;
  box-shadow: 0 0 0 3px rgba(0,169,196,.08);
}
.global-processing-jobs {
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 4px;
}
.global-processing-job {
  min-height: 32px;
  grid-template-columns: minmax(0,1fr) auto;
  grid-template-rows: auto 2px;
  column-gap: 8px;
  row-gap: 4px;
  padding: 5px 8px 6px;
  border-radius: 8px;
}
.global-job-icon,
.global-job-summary {
  display: none !important;
}
.global-job-copy {
  display: flex;
  min-width: 0;
  align-items: baseline;
  gap: 7px;
}
.global-job-copy strong {
  max-width: 58%;
  overflow: hidden;
  color: var(--ink-strong);
  font-size: 8.5px;
  font-weight: 650;
  line-height: 1.15;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.global-job-copy small {
  overflow: hidden;
  color: var(--muted);
  font-size: 7.5px;
  line-height: 1.15;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.global-job-open {
  align-self: center;
  padding: 2px 6px;
  border-radius: 5px;
  background: transparent;
  color: var(--accent-strong);
  font-size: 7.5px;
  font-weight: 650;
}
.global-job-progress {
  grid-column: 1 / -1;
  height: 2px;
  overflow: hidden;
  border-radius: 999px;
  background: color-mix(in srgb, var(--line) 82%, transparent);
}
.global-job-progress span {
  display: block;
  height: 100%;
  border-radius: inherit;
}
@media (max-width: 760px) {
  .global-processing-dock { top: 82px; max-height: 22vh; }
  .global-processing-job { min-height: 34px; }
  .global-job-copy { display: grid; gap: 1px; }
  .global-job-copy strong { max-width: 100%; }
}

/* ========================================================================== */
/* Balanced active-processing status size                                     */
/* ========================================================================== */
.global-processing-dock {
  margin: -3px 0 11px;
  padding: 8px 10px 9px;
  max-height: min(22vh, 175px);
  border-radius: 12px;
  box-shadow: 0 6px 18px rgba(15,37,61,.07);
}
.global-processing-heading {
  min-height: 19px;
  margin-bottom: 6px;
}
.global-processing-heading > div {
  gap: 7px;
}
.global-processing-heading strong {
  font-size: 10.5px;
  font-weight: 650;
}
#global-processing-count {
  padding: 2px 7px;
  font-size: 8.5px;
  font-weight: 650;
}
.processing-live-dot {
  width: 6px;
  height: 6px;
  box-shadow: 0 0 0 4px rgba(0,169,196,.09);
}
.global-processing-jobs {
  grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
  gap: 6px;
}
.global-processing-job {
  min-height: 48px;
  grid-template-columns: minmax(0,1fr) auto;
  grid-template-rows: auto 4px;
  column-gap: 12px;
  row-gap: 7px;
  padding: 8px 11px 9px;
  border-radius: 10px;
}
.global-job-copy {
  gap: 9px;
}
.global-job-copy strong {
  max-width: 62%;
  font-size: 10.5px;
  font-weight: 650;
  line-height: 1.25;
}
.global-job-copy small {
  font-size: 9px;
  line-height: 1.25;
}
.global-job-open {
  min-height: 28px;
  padding: 5px 9px;
  border-radius: 7px;
  font-size: 9px;
  font-weight: 650;
}
.global-job-progress {
  height: 4px;
}
@media (max-width: 760px) {
  .global-processing-dock {
    top: 82px;
    padding: 7px 8px 8px;
    max-height: 26vh;
  }
  .global-processing-job {
    min-height: 52px;
    padding: 8px 10px;
  }
  .global-job-copy {
    display: grid;
    gap: 2px;
  }
  .global-job-copy strong {
    max-width: 100%;
    font-size: 10px;
  }
  .global-job-copy small {
    font-size: 8.5px;
  }
}

/* ========================================================================== */
/* 2026-10-02 Product-wide UX and readability refresh                         */
/* ========================================================================== */
:root {
  --ux-text: #10263f;
  --ux-muted: #5f738b;
  --ux-border: #d3dee8;
  --ux-soft: #f6f9fb;
}

body {
  font-size: 15px;
  line-height: 1.55;
  color: var(--ux-text);
}

/* Header and navigation: easier scanning without making the shell feel heavy. */
.sidebar { padding: 18px 15px 16px; }
.brand { margin-bottom: 16px; }
.brand-copy { font-size: 10.5px; letter-spacing: 1.65px; }
nav p { margin-top: 18px; font-size: 10.5px; letter-spacing: 1.45px; }
nav button {
  min-height: 42px;
  padding: 10px 13px 10px 16px;
  font-size: 13.5px;
  font-weight: 620;
}
.side-footer { font-size: 11.5px; }

header {
  min-height: 84px;
  margin-bottom: 24px;
}
.header-copy small,
header small { font-size: 10.5px; }
header h1 { font-size: 25px; font-weight: 720; }
.network-pill { min-height: 38px; font-size: 11.5px; }

/* Page headings and explanatory text. */
.section-lead { margin-bottom: 22px; }
.section-lead h2 {
  margin: 8px 0 7px;
  font-size: clamp(29px, 2.5vw, 34px);
  font-weight: 730;
  letter-spacing: -.65px;
}
.section-lead p {
  max-width: 900px;
  color: var(--ux-muted);
  font-size: 14.5px;
  line-height: 1.65;
}
.pill {
  min-height: 25px;
  padding: 0 11px;
  font-size: 9.5px;
  letter-spacing: 1.35px;
}

/* Overview: useful at a glance, with a clearer journey for first-time users. */
.home-hero {
  min-height: 236px;
  padding: 38px 44px;
  border-radius: 22px;
}
.home-hero h2 {
  margin: 14px 0 10px;
  font-size: clamp(36px, 3.6vw, 46px);
  font-weight: 760;
}
.home-hero p {
  max-width: 800px;
  color: #d2e1eb;
  font-size: 15px;
  line-height: 1.7;
}
.hero-actions { margin-top: 22px; }
.hero-actions button { min-height: 42px; padding: 10px 18px; font-size: 12.5px; }

.overview-summary-grid {
  gap: 12px;
  margin-top: 16px;
}
.overview-summary-card {
  min-height: 124px;
  padding: 19px 20px;
  border-radius: 15px;
  border-color: var(--ux-border);
  box-shadow: 0 6px 18px rgba(15,37,61,.055);
}
.overview-summary-icon {
  width: 42px;
  height: 42px;
  border-radius: 12px;
  font-size: 20px;
}
.overview-summary-card strong {
  margin: 0 0 6px;
  font-size: 14.5px;
  font-weight: 720;
}
.overview-summary-card p {
  color: var(--ux-muted);
  font-size: 12px;
  line-height: 1.58;
}

.overview-guide {
  margin: 15px 0 4px;
  padding: 18px 20px;
  border: 1px solid var(--ux-border);
  border-radius: 16px;
  background: linear-gradient(135deg, var(--surface), color-mix(in srgb, var(--accent-soft) 36%, var(--surface)));
  box-shadow: 0 6px 18px rgba(15,37,61,.045);
}
.overview-guide-heading {
  display: flex;
  align-items: center;
  gap: 13px;
  margin-bottom: 15px;
}
.overview-guide-heading > div { display:grid; gap:2px; }
.overview-guide-heading strong { color:var(--ink-strong); font-size:14px; font-weight:720; }
.overview-guide-heading span:not(.pill) { color:var(--muted); font-size:11.5px; }
.overview-guide-steps {
  display:grid;
  grid-template-columns:repeat(3,minmax(0,1fr));
  gap:10px;
}
.overview-guide-steps article {
  display:grid;
  grid-template-columns:34px minmax(0,1fr);
  gap:11px;
  align-items:start;
  padding:13px 14px;
  border:1px solid color-mix(in srgb,var(--line) 86%,transparent);
  border-radius:12px;
  background:color-mix(in srgb,var(--surface) 92%,transparent);
}
.overview-guide-steps article > b {
  width:30px;
  height:30px;
  display:grid;
  place-items:center;
  border-radius:9px;
  background:var(--accent-soft);
  color:var(--accent-strong);
  font-size:12px;
  font-weight:800;
}
.overview-guide-steps article div { display:grid; gap:3px; }
.overview-guide-steps article strong { color:var(--ink-strong); font-size:12.5px; font-weight:700; }
.overview-guide-steps article span { color:var(--muted); font-size:11px; line-height:1.5; }

.home-stats { margin: 15px 0 22px; }
.home-stats article {
  min-height: 94px;
  padding: 16px 18px;
  border-radius: 14px;
}
.home-stats .stat-kicker { font-size: 8.5px; }
.home-stats b { font-size: 23px; }
.home-stats article > span:last-child { font-size: 11px; }
.quick-access-heading h3 { font-size: 20px; }
.quick-access-heading p { font-size: 12px; }
.quick-access-grid { gap: 11px; }
.quick-access-grid button {
  min-height: 126px;
  padding: 18px 18px 16px;
  border-radius: 14px;
}
.quick-access-grid i { font-size: 8.5px; }
.quick-access-grid b { margin: 15px 0 5px; font-size: 15px; }
.quick-access-grid span { font-size: 11px; line-height: 1.5; }

/* Shared cards and forms. */
.panel,
.tool-workspace,
.config-card,
.config-preview-card {
  border-color: var(--ux-border);
  box-shadow: 0 7px 22px rgba(15,37,61,.055);
}
.panel,
.tool-workspace { border-radius: 16px; }
.tool-workspace { padding: 25px; }
.tool-workspace h3 { font-size: 19px; font-weight: 720; }
.tool-workspace .hint { font-size: 12.5px; color: var(--ux-muted); }

.form-grid { gap: 18px 20px; padding: 24px; }
label {
  gap: 8px;
  color: #425a73;
  font-size: 12px;
  font-weight: 680;
}
label small { font-size: 10.5px; }
input,
textarea,
select {
  border-color: var(--ux-border);
  border-radius: 11px;
  padding: 11px 13px;
  color: var(--ink-strong);
  font-size: 14px;
}
input:not([type="checkbox"]):not([type="radio"]),
select { min-height: 44px; }
textarea { min-height: 118px; line-height: 1.55; }
input::placeholder,
textarea::placeholder { color:#8a9aab; opacity:1; }

button {
  min-height: 40px;
  padding: 10px 17px;
  border-radius: 10px;
  font-size: 12.5px;
  font-weight: 650;
}
button.secondary { color:#334c65; }

/* Workspace navigation. */
.scope-tabs {
  padding: 5px;
  border-radius: 13px;
}
.scope-tabs button { min-height: 38px; padding: 9px 15px; font-size: 12.5px; }
.feature-grid { gap: 11px; }
.feature-grid button {
  min-height: 56px;
  padding: 14px 17px;
  border-radius: 13px;
  font-size: 12.5px;
  font-weight: 650;
}

/* Systems option picker: readable without becoming oversized. */
.column-picker { gap: 10px 12px; padding: 17px; }
.column-picker label {
  min-height: 42px;
  padding: 9px 11px;
  font-size: 11.5px;
}
.column-picker input[type="checkbox"] { width:20px; height:20px; min-width:20px; }

/* Results tables. */
.table-scroll,
.stream-table-scroll {
  border-radius: 13px;
  border-color: var(--ux-border);
}
.result-table thead td,
.stream-result-table thead td {
  padding: 11px 13px;
  color: #405a72;
  font-size: 11.5px;
  font-weight: 720;
}
.result-table td,
.stream-result-table td {
  padding: 10px 13px;
  font-size: 12.5px;
  line-height: 1.4;
}
.streaming-export-actions { margin-top: 12px; }

/* Processing status inside a workspace. */
.lookup-progress-card {
  padding: 16px 17px 15px;
  border-radius: 14px;
}
.lookup-progress-title strong { font-size: 13.5px; }
.lookup-progress-state { font-size: 9.5px; }
.lookup-progress-count { font-size: 11.5px; }
.lookup-progress-track { height: 10px; }
.lookup-stat { min-height: 26px; font-size: 10.5px; }
.lookup-stat b { font-size: 11.5px; }
.lookup-progress-current { font-size: 10.5px; }
.lookup-stop-button { font-size: 11px; font-weight: 500; }

/* Persistent cross-tab monitor: readable but still secondary to page content. */
.global-processing-dock {
  padding: 8px 10px 9px;
  border-radius: 12px;
}
.global-processing-heading strong { font-size: 10.5px; }
#global-processing-count { font-size: 8.5px; }
.global-processing-job {
  min-height: 50px;
  padding: 8px 11px 9px;
}
.global-job-copy strong { font-size: 10.5px; font-weight: 650; }
.global-job-copy small { font-size: 9px; }
.global-job-open { min-height: 28px; font-size: 9px; }
.global-job-progress { height: 4px; }

/* Pagination footer. */
.table-pagination,
.pagination-bar,
.stream-pagination {
  font-size: 11.5px;
}
.pagination-label,
.pagination-field label { font-size: 10px; font-weight: 700; }
.pagination-range { font-size: 11px; }

/* Modem cards and utility tools. */
.toolbar { padding: 13px; border-radius: 14px; }
.toolbar > input { min-height: 42px; }
.command-card { padding: 20px; border-radius: 15px; }
.command-card h3 { font-size: 16px; }
.command-card small { font-size: 9.5px; }
.command-card p { color:var(--ux-muted); font-size: 12px; }
.command-card code { font-size: 11.5px; line-height:1.55; }
.notice { font-size: 11.5px; line-height:1.55; }

/* Dialog readability. */
dialog { border-radius: 17px; }
.column-dialog-header h3 { font-size: 22px; }
.column-dialog-header p { font-size: 12.5px; }
.column-choice-copy strong { font-size: 12.5px; }
.column-choice-copy small { font-size: 10.5px; }

/* File import. */
.file-drop-copy strong { font-size: 16px; }
.file-drop-copy span { font-size: 12px; }
.file-picker-button { font-size: 12.5px !important; }
.file-selected-name { font-size: 11.5px; }
.file-format-hint { font-size: 11px; }

/* Dark mode: keep contrast at the same readability level. */
body.dark {
  --ux-text:#e3edf5;
  --ux-muted:#a9bccd;
  --ux-border:#29465d;
}
body.dark .overview-guide { background:linear-gradient(135deg,#10263a,#102b3d); }
body.dark .overview-guide-steps article { background:#11283b; border-color:#29465d; }
body.dark .overview-guide-heading strong,
body.dark .overview-guide-steps article strong { color:#e8f1f7; }
body.dark .overview-guide-heading span:not(.pill),
body.dark .overview-guide-steps article span { color:#a9bccd; }
body.dark input::placeholder,
body.dark textarea::placeholder { color:#7790a6; }

@media (max-width: 1100px) {
  .overview-guide-steps { grid-template-columns:1fr; }
}
@media (max-width: 760px) {
  body { font-size:14px; }
  main { padding-left:18px; padding-right:18px; }
  .home-hero { padding:28px 24px; }
  .home-hero h2 { font-size:34px; }
  .overview-guide { padding:15px; }
  .form-grid { padding:18px; }
  .tool-workspace { padding:19px; }
  .result-table thead td,
  .stream-result-table thead td,
  .result-table td,
  .stream-result-table td { padding:9px 11px; }
}

/* ========================================================================== */
/* Targeted typography refinement: active processing monitor only             */
/* Keep the full UX-refresh design; match the lighter action-button type.      */
/* ========================================================================== */
.global-processing-heading strong,
#global-processing-count,
.global-job-copy strong,
.global-job-copy small,
.global-job-open {
  font-family: "Segoe UI", Tahoma, Arial, sans-serif;
  font-weight: 500 !important;
  letter-spacing: 0 !important;
}

.global-processing-heading strong { font-size: 11px; }
#global-processing-count { font-size: 9px; }
.global-job-copy strong { font-size: 11px; }
.global-job-copy small { font-size: 9.5px; }
.global-job-open { font-size: 10px; }
