:root {
  color-scheme: light;
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  --bg: #f3f5f9;
  --surface: #ffffff;
  --surface-subtle: #f8fafc;
  --surface-strong: #edf1f7;
  --text: #182033;
  --muted: #667085;
  --border: #dce2eb;
  --border-strong: #c5cedb;
  --primary: #3f5fc6;
  --primary-hover: #304dad;
  --primary-soft: #eef2ff;
  --nav: #111827;
  --nav-muted: #aeb8c8;
  --success: #157347;
  --success-soft: #ecf8f2;
  --warning: #9a5b13;
  --warning-soft: #fff7e8;
  --danger: #b42318;
  --danger-soft: #fff1f0;
  --info: #2855a6;
  --info-soft: #eef4ff;
  --shadow: 0 1px 2px rgb(16 24 40 / 5%), 0 8px 24px rgb(16 24 40 / 5%);
}

* { box-sizing: border-box; }

html { min-width: 320px; background: var(--bg); }

body {
  min-height: 100vh;
  margin: 0;
  overflow-x: hidden;
  background: var(--bg);
  color: var(--text);
  font-size: 15px;
  line-height: 1.5;
}

a { color: var(--primary); text-underline-offset: 3px; }
button, input, select, textarea { font: inherit; }

button, .button {
  display: inline-flex;
  min-height: 42px;
  align-items: center;
  justify-content: center;
  gap: 0.45rem;
  padding: 0.65rem 1rem;
  border: 1px solid var(--primary);
  border-radius: 8px;
  background: var(--primary);
  color: #fff;
  font-weight: 700;
  line-height: 1.15;
  text-decoration: none;
  cursor: pointer;
  transition: background 120ms ease, border-color 120ms ease, box-shadow 120ms ease;
}

button:hover, .button:hover { border-color: var(--primary-hover); background: var(--primary-hover); }

.button-secondary { border-color: var(--border-strong); background: var(--surface); color: var(--text); }
.button-secondary:hover { border-color: #a8b3c3; background: var(--surface-subtle); }

.button-quiet {
  min-height: 34px;
  padding: 0.4rem 0.7rem;
  border-color: var(--border);
  background: var(--surface);
  color: var(--primary);
  font-size: 0.875rem;
}

.button-quiet:hover { background: var(--primary-soft); border-color: #cbd5f7; }
.button-small { min-height: 32px; padding: 0.38rem 0.65rem; font-size: 0.8rem; }
.button-danger { border-color: #e2a6a0; background: #fff; color: var(--danger); }
.button-danger:hover { border-color: var(--danger); background: var(--danger-soft); }
button:disabled, .button:disabled { border-color: var(--border); background: var(--surface-strong); color: #8a94a3; cursor: not-allowed; }
:focus-visible { outline: 3px solid rgb(63 95 198 / 24%); outline-offset: 2px; }

.shell { width: min(calc(100% - 32px), 1320px); min-width: 0; margin-inline: auto; }

.skip-link {
  position: fixed;
  z-index: 100;
  top: 8px;
  left: 8px;
  padding: 0.55rem 0.75rem;
  border-radius: 6px;
  background: #fff;
  color: var(--nav);
  transform: translateY(-150%);
}
.skip-link:focus { transform: translateY(0); }

.app-header {
  position: sticky;
  z-index: 20;
  top: 0;
  width: 100%;
  border-bottom: 1px solid rgb(255 255 255 / 9%);
  background: var(--nav);
  color: #fff;
}

.header-inner { display: flex; min-width: 0; min-height: 72px; align-items: center; gap: 1.25rem; }

.brand {
  display: inline-flex;
  flex: 0 0 auto;
  align-items: center;
  gap: 0.7rem;
  color: #fff;
  text-decoration: none;
}

.brand-mark {
  display: grid;
  width: 34px;
  height: 34px;
  place-items: center;
  border-radius: 9px;
  background: #4d68d5;
  font-weight: 800;
}

.brand-copy { display: flex; flex-direction: column; line-height: 1.15; }
.brand-copy strong { font-size: 0.94rem; }
.brand-copy small { color: var(--nav-muted); font-size: 0.7rem; letter-spacing: 0.06em; text-transform: uppercase; }

.primary-nav { display: flex; min-width: 0; align-items: center; gap: 0.25rem; }
.primary-nav a {
  padding: 0.55rem 0.75rem;
  border-radius: 7px;
  color: #cbd3df;
  font-size: 0.9rem;
  font-weight: 650;
  text-decoration: none;
  white-space: nowrap;
}
.primary-nav a:hover, .primary-nav a.active { background: rgb(255 255 255 / 10%); color: #fff; }

.header-account { display: flex; flex: 0 0 auto; align-items: center; gap: 0.55rem; margin-left: auto; }
.account-chip { display: inline-flex; align-items: center; gap: 0.5rem; color: #d6dce6; font-size: 0.85rem; }
.account-avatar {
  display: grid;
  width: 30px;
  height: 30px;
  place-items: center;
  border: 1px solid rgb(255 255 255 / 18%);
  border-radius: 50%;
  background: rgb(255 255 255 / 8%);
  color: #fff;
  font-size: 0.75rem;
  font-weight: 800;
  text-transform: uppercase;
}

.nav-signout { margin: 0; padding: 0; border: 0; background: transparent; }
.nav-signout-button {
  min-height: 34px;
  padding: 0.45rem 0.65rem;
  border-color: rgb(255 255 255 / 18%);
  background: transparent;
  color: #d6dce6;
  font-size: 0.82rem;
  font-weight: 650;
}
.nav-signout-button:hover { border-color: rgb(255 255 255 / 30%); background: rgb(255 255 255 / 9%); }

.app-main { min-height: calc(100vh - 130px); padding-block: 2rem 3rem; }
.app-footer { padding-block: 0 1.5rem; color: var(--muted); font-size: 0.78rem; }
.footer-inner { display: flex; justify-content: space-between; gap: 1rem; }

.page-header { display: flex; min-width: 0; align-items: flex-end; justify-content: space-between; gap: 1.5rem; margin-bottom: 1.4rem; }
.page-header h1, .auth-card h1, .result-card h1 {
  margin: 0;
  color: var(--text);
  font-size: clamp(1.55rem, 2.6vw, 2.1rem);
  line-height: 1.2;
  letter-spacing: -0.025em;
}
.page-description { max-width: 720px; margin: 0.4rem 0 0; color: var(--muted); }
.eyebrow { margin: 0 0 0.35rem; color: var(--primary); font-size: 0.72rem; font-weight: 800; letter-spacing: 0.11em; text-transform: uppercase; }

.panel { min-width: 0; border: 1px solid var(--border); border-radius: 12px; background: var(--surface); box-shadow: var(--shadow); }
.panel-header { display: flex; align-items: flex-start; justify-content: space-between; gap: 1rem; padding: 1.1rem 1.2rem; border-bottom: 1px solid var(--border); }
.panel-header h2, .section-heading h2 { margin: 0; font-size: 1rem; line-height: 1.3; }
.panel-header p, .section-heading p { margin: 0.3rem 0 0; color: var(--muted); font-size: 0.85rem; }
.panel-body { padding: 1.2rem; }

.admin-grid { display: grid; min-width: 0; gap: 1.25rem; }
.provider-layout, .client-layout { grid-template-columns: minmax(0, 1.7fr) minmax(320px, 0.8fr); align-items: start; }
.editor-panel { position: sticky; top: 92px; }

.summary-strip, .metric-grid { display: grid; gap: 0.8rem; margin-bottom: 1.25rem; grid-template-columns: repeat(4, minmax(0, 1fr)); }
.summary-item, .metric-card { min-width: 0; padding: 1rem 1.1rem; border: 1px solid var(--border); border-radius: 10px; background: var(--surface); }
.summary-item span, .metric-label { display: block; color: var(--muted); font-size: 0.76rem; font-weight: 700; letter-spacing: 0.04em; text-transform: uppercase; }
.summary-item strong, .metric-value { display: block; margin-top: 0.2rem; color: var(--text); font-size: 1.55rem; line-height: 1.2; }
.metric-card { color: inherit; text-decoration: none; transition: border-color 120ms ease, transform 120ms ease, box-shadow 120ms ease; }
.metric-card:hover { border-color: #bdc9ee; box-shadow: 0 10px 30px rgb(42 57 106 / 9%); transform: translateY(-1px); }
.metric-meta { display: block; margin-top: 0.4rem; color: var(--muted); font-size: 0.8rem; }
.summary-strip > div { min-width: 0; padding: 1rem 1.1rem; border: 1px solid var(--border); border-radius: 10px; background: var(--surface); }
.summary-strip > div > span, .metric-card > span { display: block; color: var(--muted); font-size: 0.76rem; font-weight: 700; letter-spacing: 0.04em; text-transform: uppercase; }
.summary-strip > div > strong, .metric-card > strong { display: block; margin-top: 0.2rem; color: var(--text); font-size: 1.55rem; line-height: 1.2; }
.metric-card > small { display: block; margin-top: 0.4rem; color: var(--muted); font-size: 0.8rem; }

.overview-kpis { margin-bottom: 1.25rem; grid-template-columns: repeat(3, minmax(0, 1fr)); }
.dashboard-provider-panel { margin-bottom: 1.25rem; }
.provider-health-table th, .provider-health-table td { white-space: nowrap; }
.provider-health-table td:last-child { min-width: 280px; white-space: normal; }
.provider-switch {
  display: inline-flex;
  min-height: 34px;
  align-items: center;
  gap: 0.45rem;
  padding: 0.38rem 0.65rem;
  border: 1px solid var(--border-strong);
  border-radius: 8px;
  border-color: var(--border-strong);
  background: var(--surface);
  color: var(--text);
  font-size: 0.8rem;
  font-weight: 700;
  line-height: 1.15;
  box-shadow: none;
  cursor: pointer;
}
.provider-switch:hover { border-color: #a8b3c3; background: var(--surface-subtle); }
.provider-switch > input {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  overflow: hidden;
  border: 0;
  opacity: 0;
}
.provider-switch:has(input:focus-visible) { outline: 3px solid rgb(63 95 198 / 24%); outline-offset: 2px; }
.provider-switch-track { position: relative; width: 28px; height: 16px; border-radius: 999px; background: #98a2b3; transition: background 120ms ease; }
.provider-switch-track span { position: absolute; top: 2px; left: 2px; width: 12px; height: 12px; border-radius: 50%; background: #fff; transition: transform 120ms ease; }
.provider-switch:has(input:checked) { border-color: #a8d9c0; color: var(--success); }
.provider-switch input:checked + .provider-switch-track { background: var(--success); }
.provider-switch input:checked + .provider-switch-track span { transform: translateX(12px); }
.provider-switch:has(input:disabled) { border-color: var(--border); background: var(--surface-strong); color: #8a94a3; cursor: not-allowed; }
.provider-switch input:disabled + .provider-switch-track { background: #c8ced7; }
.account-note { display: block; max-width: 440px; margin-top: 0.38rem; color: var(--muted); font-size: 0.72rem; line-height: 1.35; white-space: normal; }
.chart-section { min-width: 0; }
.section-heading { display: flex; align-items: flex-start; justify-content: space-between; gap: 1rem; margin: 1.5rem 0 0.8rem; }
.section-heading h2 { margin: 0; font-size: 1rem; line-height: 1.3; }
.section-heading p { margin: 0.3rem 0 0; color: var(--muted); font-size: 0.85rem; }
.chart-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(280px, 1fr)); gap: 1rem; }
.chart-card { overflow: hidden; }
.chart-card-header { display: flex; align-items: flex-start; justify-content: space-between; gap: 0.75rem; padding: 1rem 1.1rem 0.7rem; }
.chart-card-header h3 { margin: 0; color: var(--text); font-size: 0.93rem; }
.chart-card-header p { margin: 0.15rem 0 0; color: var(--muted); font-size: 0.78rem; }
.chart-total { color: var(--text); font-size: 0.78rem; white-space: nowrap; }
.chart-metric-heading { display: flex; align-items: baseline; justify-content: space-between; gap: 0.75rem; padding: 0.1rem 1.1rem 0; color: var(--muted); font-size: 0.72rem; }
.chart-metric-heading > span { color: var(--text); font-weight: 700; }
.chart-metric-heading small { margin-left: 0.25rem; color: var(--muted); font-size: 0.65rem; font-weight: 400; }
.chart-metric-heading strong { color: var(--text); font-size: 0.72rem; white-space: nowrap; }
.chart-metric-heading-secondary { margin-top: 0.85rem; padding-top: 0.75rem; border-top: 1px solid var(--border); }
.chart-wrap { padding: 0.15rem 0.8rem 0; }
.mini-chart { display: block; width: 100%; height: 104px; overflow: visible; }
.chart-axis { stroke: var(--border-strong); stroke-width: 1; }
.chart-gridline { stroke: var(--border); stroke-width: 1; stroke-dasharray: 3 4; }
.chart-y-label { fill: var(--muted); font-size: 8px; font-variant-numeric: tabular-nums; }
.chart-line { fill: none; stroke: var(--primary); stroke-width: 2.1; stroke-linecap: round; stroke-linejoin: round; vector-effect: non-scaling-stroke; }
.chart-line-1 { stroke: #15958f; stroke-dasharray: 7 3; }.chart-line-2 { stroke: #d9772f; stroke-dasharray: 2 3; }.chart-line-3 { stroke: #7c5cbf; stroke-dasharray: 10 3 2 3; }.chart-line-4 { stroke: #c44f6b; stroke-dasharray: 5 5; }.chart-line-5 { stroke: #64748b; stroke-dasharray: 12 4; }
.chart-time-labels { display: flex; justify-content: space-between; padding: 0 0.18rem 0 1.65rem; color: var(--muted); font-size: 0.66rem; }
.chart-legend { display: flex; flex-wrap: wrap; gap: 0.55rem 0.8rem; padding: 0.15rem 1.1rem 1rem; color: var(--muted); font-size: 0.72rem; }
.chart-legend span { display: inline-flex; align-items: center; gap: 0.28rem; }
.chart-legend strong { color: var(--text); }
.legend-swatch { display: inline-block; width: 7px; height: 7px; border-radius: 2px; background: var(--primary); }
.legend-swatch-1 { background: #15958f; }.legend-swatch-2 { background: #d9772f; }.legend-swatch-3 { background: #7c5cbf; }.legend-swatch-4 { background: #c44f6b; }.legend-swatch-5 { background: #64748b; }
.chart-footer { display: flex; justify-content: space-between; gap: 1rem; padding: 0.6rem 1.1rem; border-top: 1px solid var(--border); background: var(--surface-subtle); color: var(--muted); font-size: 0.7rem; }
.compact-empty { padding-block: 1.25rem; }

.overview-grid, .dashboard-grid { display: grid; grid-template-columns: minmax(0, 1.45fr) minmax(280px, 0.55fr); gap: 1.25rem; align-items: start; }

.table-shell { width: 100%; min-width: 0; overflow-x: auto; }
.table-action { text-align: right; }
.row-actions { display: flex; flex-wrap: wrap; justify-content: flex-end; gap: 0.45rem; }
.inline-form { margin: 0; }
table { width: 100%; border-collapse: collapse; background: var(--surface); }
caption { padding: 0.75rem 1.2rem 0; color: var(--muted); font-size: 0.8rem; text-align: left; }
th, td { padding: 0.85rem 0.75rem; border-bottom: 1px solid var(--border); text-align: left; vertical-align: middle; }
th:first-child, td:first-child { padding-left: 1.2rem; }
th:last-child, td:last-child { padding-right: 1.2rem; }
th { background: var(--surface-subtle); color: #526071; font-size: 0.7rem; font-weight: 800; letter-spacing: 0.06em; text-transform: uppercase; }
tbody tr:last-child td { border-bottom: 0; }
tbody tr:hover td { background: #fbfcff; }

.cell-primary { display: block; color: var(--text); font-weight: 750; }
.cell-secondary { display: block; max-width: 360px; margin-top: 0.15rem; overflow: hidden; color: var(--muted); font-size: 0.78rem; text-overflow: ellipsis; white-space: nowrap; }
.row-title { display: block; color: var(--text); font-weight: 750; }
.row-meta { display: block; max-width: 360px; margin-top: 0.15rem; overflow: hidden; color: var(--muted); font-size: 0.78rem; font-weight: 400; text-overflow: ellipsis; white-space: nowrap; }
.align-right { text-align: right; }
.muted-value { color: var(--muted); font-size: 0.8rem; white-space: nowrap; }

.status-badge { display: inline-flex; align-items: center; gap: 0.35rem; padding: 0.27rem 0.5rem; border: 1px solid transparent; border-radius: 999px; font-size: 0.72rem; font-weight: 750; line-height: 1; white-space: nowrap; }
.status-dot { width: 6px; height: 6px; border-radius: 50%; background: currentColor; }
.status-success { border-color: #cbe9da; background: var(--success-soft); color: var(--success); }
.status-warning { border-color: #f0d9aa; background: var(--warning-soft); color: var(--warning); }
.status-info { border-color: #cfddf8; background: var(--info-soft); color: var(--info); }
.status-neutral { border-color: var(--border); background: var(--surface-strong); color: #596579; }
.badge { display: inline-flex; align-items: center; gap: 0.35rem; padding: 0.27rem 0.5rem; border: 1px solid transparent; border-radius: 999px; font-size: 0.72rem; font-weight: 750; line-height: 1; white-space: nowrap; }
.badge-success { border-color: #cbe9da; background: var(--success-soft); color: var(--success); }
.badge-warning { border-color: #f0d9aa; background: var(--warning-soft); color: var(--warning); }
.badge-info { border-color: #cfddf8; background: var(--info-soft); color: var(--info); }
.badge-neutral { border-color: var(--border); background: var(--surface-strong); color: #596579; }

.code-chip, code { border: 1px solid var(--border); border-radius: 5px; background: var(--surface-subtle); color: #3e4b60; font-family: "SFMono-Regular", Consolas, "Liberation Mono", monospace; font-size: 0.78em; }
.code-chip { display: inline-block; padding: 0.2rem 0.4rem; }
code { padding: 0.08rem 0.25rem; }

.form-stack { display: grid; gap: 1rem; }
.field, .field-group { display: grid; gap: 0.4rem; min-width: 0; }
.field > label, .field-label, .field-group > legend { color: #344054; font-size: 0.83rem; font-weight: 750; }
.field-group { margin: 0; padding: 0; border: 0; }
.field-help { margin: 0; color: var(--muted); font-size: 0.76rem; font-weight: 400; }
.field-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 0.9rem; }

input, select, textarea { width: 100%; min-width: 0; padding: 0.7rem 0.75rem; border: 1px solid var(--border-strong); border-radius: 8px; background: #fff; color: var(--text); box-shadow: 0 1px 2px rgb(16 24 40 / 3%); }
input:hover, select:hover, textarea:hover { border-color: #aeb9c9; }
input:focus, select:focus, textarea:focus { border-color: var(--primary); outline: 3px solid rgb(63 95 198 / 14%); }
input[readonly] { background: var(--surface-strong); color: #596579; }
textarea { min-height: 112px; resize: vertical; font-family: "SFMono-Regular", Consolas, "Liberation Mono", monospace; font-size: 0.82rem; line-height: 1.45; }

.switch-field { display: flex; align-items: flex-start; gap: 0.7rem; padding: 0.8rem; border: 1px solid var(--border); border-radius: 9px; background: var(--surface-subtle); }
.switch-field input { width: 17px; height: 17px; margin: 0.14rem 0 0; accent-color: var(--primary); }
.switch-field > span { display: grid; flex: 1; gap: 0.08rem; }
.switch-field > span > strong { font-size: 0.84rem; }
.switch-field > span > small { color: var(--muted); font-size: 0.76rem; font-weight: 400; }
.switch-copy { display: grid; gap: 0.08rem; }
.switch-copy strong { font-size: 0.84rem; }
.switch-copy span { color: var(--muted); font-size: 0.76rem; font-weight: 400; }

.credential-box { display: grid; gap: 0.75rem; padding: 0.9rem; border: 1px solid var(--border); border-radius: 9px; background: var(--surface-subtle); }
.credential-box > div:first-child { display: flex; align-items: center; justify-content: space-between; gap: 0.75rem; }
.credential-heading { display: flex; align-items: center; justify-content: space-between; gap: 0.75rem; }
.credential-heading strong { font-size: 0.84rem; }

.advanced-settings { border: 1px solid var(--border); border-radius: 9px; background: var(--surface-subtle); }
.advanced-settings summary { padding: 0.75rem 0.9rem; color: #445166; font-size: 0.82rem; font-weight: 750; cursor: pointer; }
.advanced-body { display: grid; gap: 0.9rem; padding: 0 0.9rem 0.9rem; }
.advanced-settings summary span { display: grid; gap: 0.1rem; }
.advanced-settings summary small { color: var(--muted); font-size: 0.74rem; font-weight: 400; }
.advanced-content { padding: 0 0.9rem 0.9rem; }
.form-actions { display: flex; flex-wrap: wrap; gap: 0.65rem; padding-top: 0.15rem; }
.editor-panel > .form-stack { padding: 1.2rem; }
.editor-panel > .notice { margin: 1.2rem 1.2rem 0; }
.notice + .admin-grid { margin-top: 1.25rem; }

.notice { padding: 0.8rem 0.95rem; border: 1px solid var(--border); border-radius: 9px; background: var(--surface-subtle); color: #445166; font-size: 0.83rem; }
.notice strong { color: var(--text); }
.notice-error { border-color: #f3c7c3; background: var(--danger-soft); color: var(--danger); }
.notice-warning { border-color: #eed7a8; background: var(--warning-soft); color: #80511a; }
.notice-success { border-color: #c9e7d7; background: var(--success-soft); color: var(--success); }
.notice-info { border-color: #cfddf8; background: var(--info-soft); color: var(--info); }

.health-pill { display: inline-flex; align-items: center; gap: 0.45rem; padding: 0.5rem 0.7rem; border: 1px solid #c9e7d7; border-radius: 999px; background: var(--success-soft); color: var(--success); font-size: 0.78rem; font-weight: 750; white-space: nowrap; }
.health-dot { width: 7px; height: 7px; border-radius: 50%; background: currentColor; box-shadow: 0 0 0 3px rgb(21 115 71 / 12%); }
.empty-state { padding: 2rem 1.2rem; color: var(--muted); text-align: center; }
.empty-state strong { display: block; margin-bottom: 0.25rem; color: var(--text); }

.plain-list, .state-list, .guide-list { margin: 0; padding: 0; list-style: none; }
.state-list li { display: flex; align-items: center; justify-content: space-between; gap: 1rem; padding: 0.8rem 1.2rem; border-bottom: 1px solid var(--border); }
.state-list li:last-child { border-bottom: 0; }
.state-count { font-size: 1.05rem; font-weight: 800; }
.guide-list, .step-list { display: grid; gap: 0.9rem; margin: 0; padding: 1.2rem; list-style: none; }
.guide-list li, .step-list li { display: grid; grid-template-columns: 24px 1fr; gap: 0.65rem; color: var(--muted); font-size: 0.84rem; }
.guide-list span, .step-list > li > span { display: grid; width: 24px; height: 24px; place-items: center; border-radius: 50%; background: var(--primary-soft); color: var(--primary); font-size: 0.72rem; font-weight: 800; }
.guide-list strong, .step-list strong { display: block; color: var(--text); font-size: 0.83rem; }
.step-list small { display: block; color: var(--muted); }

.auth-layout, .result-layout { display: grid; min-height: calc(100vh - 7rem); place-items: center; padding-block: 2rem; }
.auth-card, .result-card { width: min(100%, 460px); padding: clamp(1.3rem, 4vw, 2rem); border: 1px solid var(--border); border-radius: 14px; background: var(--surface); box-shadow: 0 18px 50px rgb(23 32 51 / 10%); }
.auth-mark { display: grid; width: 42px; height: 42px; margin-bottom: 1rem; place-items: center; border-radius: 11px; background: var(--primary); color: #fff; font-weight: 800; }
.auth-description, .result-description { margin: 0.5rem 0 1.4rem; color: var(--muted); }
.auth-heading > p:last-child { margin: 0.5rem 0 0; color: var(--muted); }
.full-width, .button-full { width: 100%; }
.auth-heading { margin-bottom: 1.35rem; }
.auth-heading .page-description { margin-top: 0.5rem; }
.auth-card-wide { width: min(100%, 600px); }
.success-mark { display: grid; width: 42px; height: 42px; margin-bottom: 1rem; place-items: center; border-radius: 50%; background: var(--success-soft); color: var(--success); font-size: 1.3rem; font-weight: 800; }

.secret-panel { margin: 1rem 0; padding: 1rem; border: 1px solid #efd599; border-radius: 9px; background: var(--warning-soft); }
.secret-value { display: block; margin-top: 0.55rem; padding: 0.75rem; overflow-wrap: anywhere; border: 1px solid #e4c67c; border-radius: 7px; background: #fff; font-family: "SFMono-Regular", Consolas, monospace; font-size: 0.84rem; user-select: all; }
.secret-panel > code { display: block; margin-top: 0.55rem; padding: 0.75rem; overflow-wrap: anywhere; border-color: #e4c67c; background: #fff; font-size: 0.84rem; user-select: all; }

.sr-only { position: absolute; width: 1px; height: 1px; padding: 0; overflow: hidden; clip: rect(0, 0, 0, 0); white-space: nowrap; border: 0; }

@media (max-width: 1040px) {
  .provider-layout, .client-layout, .overview-grid, .dashboard-grid { grid-template-columns: 1fr; }
  .editor-panel { position: static; }
}

@media (max-width: 820px) {
  .header-inner { flex-wrap: wrap; gap: 0.65rem 1rem; padding-block: 0.75rem; }
  .primary-nav { order: 3; width: 100%; padding-top: 0.15rem; overflow-x: auto; scrollbar-width: thin; }
  .page-header { align-items: flex-start; flex-direction: column; gap: 0.8rem; }
  .summary-strip, .metric-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}

@media (max-width: 560px) {
  .shell { width: min(calc(100% - 22px), 1320px); }
  .brand-copy small, .account-name, .app-footer span:last-child { display: none; }
  .header-inner { min-height: 64px; }
  .primary-nav { gap: 0.15rem; }
  .primary-nav a { padding-inline: 0.6rem; font-size: 0.82rem; }
  .nav-signout-button { padding-inline: 0.5rem; }
  .app-main { padding-block: 1.35rem 2rem; }
  .metric-grid, .field-grid { grid-template-columns: 1fr; }
  .summary-strip, .metric-grid { gap: 0.55rem; }
  .summary-item, .metric-card { padding: 0.8rem 0.9rem; }
  .summary-strip > div { padding: 0.8rem 0.9rem; }
  .summary-item strong, .metric-value { font-size: 1.3rem; }
  .panel-header, .panel-body { padding: 0.95rem; }
  th:first-child, td:first-child { padding-left: 0.95rem; }
  th:last-child, td:last-child { padding-right: 0.95rem; }
  .form-actions > * { flex: 1 1 auto; }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { scroll-behavior: auto !important; transition-duration: 0.01ms !important; }
}
