:root {
  color-scheme: light;
  --ink: #19242e;
  --muted: #75818a;
  --line: #e8ecee;
  --paper: #f6f8f9;
  --white: #ffffff;
  --navy: #101820;
  --navy-2: #18232c;
  --teal: #00b89c;
  --teal-dark: #007c6c;
  --red: #d64f55;
  --amber: #d99624;
  --green: #23856d;
  --blue: #5a76ca;
  --radius: 14px;
  font-family: ui-sans-serif, -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
  font-synthesis: none;
}

* { box-sizing: border-box; }
body { margin: 0; min-width: 320px; background: var(--paper); color: var(--ink); font-size: 15px; }
button, input, select { font: inherit; }
button { color: inherit; }
button:focus-visible, input:focus-visible, select:focus-visible { outline: 3px solid rgba(0, 184, 156, .32); outline-offset: 2px; }
.app-shell { min-height: 100vh; display: flex; }

.sidebar { background: var(--navy); color: #d6e0e4; width: 250px; flex: 0 0 250px; min-height: 100vh; padding: 25px 16px 17px; display: flex; flex-direction: column; position: fixed; inset: 0 auto 0 0; z-index: 3; }
.brand { display: flex; align-items: center; gap: 11px; padding: 0 9px; color: inherit; text-decoration: none; }
.brand-mark { width: 35px; height: 35px; border-radius: 11px; background: #0ab99b; display: grid; place-items: center; font-size: 19px; line-height: 1; color: #09221f; font-weight: 800; letter-spacing: -2px; box-shadow: 0 7px 18px rgba(0, 184, 156, .18); }
.brand-mark span { color: #d8fff6; }
.brand-copy { display: grid; gap: 1px; }
.brand-copy strong { font-size: 16px; letter-spacing: -.5px; color: #f4f7f7; }
.brand-copy small { font: 500 9px 'DM Mono', monospace; letter-spacing: 1.55px; color: #82919a; }
.workspace-switcher { display: flex; align-items: center; gap: 10px; margin: 35px 0 30px; border: 1px solid #293640; border-radius: 10px; padding: 10px 11px; background: #17222b; }
.workspace-icon { height: 30px; width: 30px; flex: 0 0 30px; display: grid; place-items: center; border-radius: 8px; background: #293943; color: #8ccbbb; font-size: 13px; font-weight: 700; }
.workspace-copy, .server-copy { display: grid; min-width: 0; gap: 2px; }
.workspace-copy small { color: #82919a; font: 500 9px 'DM Mono', monospace; letter-spacing: 1.2px; }
.workspace-copy strong { color: #e5ebed; font-size: 13px; font-weight: 600; }
.chevron { color: #82919a; margin-left: auto; font-size: 17px; }
.nav-label, .sidebar-section-label { padding: 0 11px; color: #697983; font: 500 10px 'DM Mono', monospace; letter-spacing: 1.3px; }
.main-nav { display: grid; gap: 4px; margin-top: 10px; }
.nav-item { border: 0; height: 43px; border-radius: 8px; padding: 0 11px; background: transparent; color: #aebbc0; text-align: left; display: flex; align-items: center; gap: 12px; font-size: 13px; cursor: pointer; transition: background .15s, color .15s; }
.nav-item:hover { background: #19262e; color: white; }
.nav-item.active { color: #e8fbf7; background: #1e3738; box-shadow: inset 2px 0 #07c4a5; }
.nav-icon { width: 17px; text-align: center; color: #82939a; font-size: 17px; }
.active .nav-icon { color: #0fceb1; }
.nav-count { margin-left: auto; color: #63747e; font: 11px 'DM Mono', monospace; }
.nav-badge { margin-left: auto; color: #ffb6b3; background: #492d32; min-width: 22px; height: 20px; display: grid; place-items: center; border-radius: 6px; font: 11px 'DM Mono', monospace; }
.sidebar-spacer { flex: 1; min-height: 30px; }
.sidebar-section-label { margin-bottom: 10px; }
.server-switcher { display: flex; gap: 9px; align-items: center; padding: 11px 9px; background: #19242d; border: 1px solid #293640; border-radius: 9px; text-align: left; cursor: pointer; color: #dfe6e8; }
.server-dot, .snapshot-dot, .source-dot { width: 7px; height: 7px; background: #4cbd99; border-radius: 50%; box-shadow: 0 0 0 3px rgba(76, 189, 153, .13); flex: 0 0 7px; }
.server-dot.is-archive { background: #d5a247; box-shadow: 0 0 0 3px rgba(213, 162, 71, .14); }
.server-copy { flex: 1; }
.server-copy strong { font-size: 11px; white-space: nowrap; font-weight: 600; }
.server-copy small { font-size: 10px; color: #82919a; }
.server-menu { color: #81919a; letter-spacing: 2px; }
.sidebar-footer { border-top: 1px solid #29343d; display: flex; align-items: center; gap: 9px; margin-top: 17px; padding: 16px 5px 0; }
.avatar, .topbar-avatar { width: 30px; height: 30px; border-radius: 50%; display: grid; place-items: center; background: #315456; color: #d5fffa; font: 11px 'DM Mono', monospace; }
.profile-copy { display: grid; gap: 1px; flex: 1; }
.profile-copy strong { font-size: 11px; color: #e5ebed; }
.profile-copy small { font-size: 10px; color: #82919a; }
.icon-button { border: 0; background: transparent; color: #85949d; cursor: pointer; font-size: 18px; letter-spacing: 2px; border-radius: 6px; }
.footer-menu { padding: 2px 4px; }

.main-area { margin-left: 250px; width: calc(100% - 250px); min-width: 0; }
.topbar { height: 65px; background: rgba(255,255,255,.94); border-bottom: 1px solid var(--line); display: flex; align-items: center; justify-content: space-between; padding: 0 43px; position: sticky; top: 0; z-index: 2; }
.breadcrumbs { display: flex; align-items: center; gap: 11px; color: #8a969c; font-size: 12px; }
.breadcrumbs strong { color: #4d5b63; font-weight: 600; }
.crumb-slash { color: #c2cacc; }
.topbar-right { display: flex; align-items: center; gap: 14px; }
.snapshot-pill { border: 1px solid #e8edef; border-radius: 20px; height: 30px; display: flex; align-items: center; gap: 8px; padding: 0 11px; color: #627078; font-size: 11px; }
.snapshot-dot { width: 6px; height: 6px; flex-basis: 6px; box-shadow: none; }
.topbar-divider { height: 22px; width: 1px; background: #e7ebed; }
.help-button { border: 1px solid #dfe5e7; color: #7b888e; background: white; width: 23px; height: 23px; border-radius: 50%; font: 600 12px Georgia, serif; cursor: pointer; }
.topbar-avatar { background: #ddebe8; color: #357468; width: 29px; height: 29px; }
.page-wrap { max-width: 1480px; padding: 38px 43px 24px; margin: 0 auto; }
.page-heading { display: flex; justify-content: space-between; align-items: flex-end; gap: 24px; margin-bottom: 25px; }
.eyebrow, .section-kicker { color: #7a888e; font: 500 10px 'DM Mono', monospace; letter-spacing: 1.15px; display: flex; align-items: center; gap: 8px; }
.eyebrow-square { width: 6px; height: 6px; background: var(--teal); transform: rotate(45deg); }
.eyebrow-sep { color: #c0c8cb; }
h1 { margin: 11px 0 6px; color: #18252e; font-size: clamp(25px, 2.3vw, 33px); line-height: 1.22; letter-spacing: -1.45px; font-weight: 700; }
.page-heading p { margin: 0; color: #77848a; font-size: 13px; }
.heading-actions { display: flex; gap: 9px; flex: 0 0 auto; }
.button { min-height: 39px; border-radius: 8px; display: inline-flex; align-items: center; justify-content: center; gap: 8px; padding: 0 14px; font-size: 12px; font-weight: 600; border: 1px solid transparent; cursor: pointer; transition: transform .15s, box-shadow .15s; }
.button:hover { transform: translateY(-1px); }
.button-secondary { color: #43535b; background: white; border-color: #dfe5e7; }
.button-primary { background: #0ba98f; color: #fff; box-shadow: 0 5px 11px rgba(11, 169, 143, .15); }
.button-primary:hover { background: #078f7b; box-shadow: 0 7px 15px rgba(11, 169, 143, .23); }
.button-glyph { font-size: 16px; line-height: 1; }

.snapshot-banner { min-height: 59px; border: 1px solid #dcece8; background: #f2fbf8; border-radius: 10px; display: flex; gap: 12px; align-items: center; padding: 11px 16px; margin-bottom: 12px; }
.snapshot-banner.is-archive { border-color: #f0d6ac; background: #fff9ee; }
.snapshot-banner.is-archive .banner-icon { color: #9b6c21; background: #ffedca; }
.snapshot-banner.is-archive .banner-copy strong { color: #795a26; }
.snapshot-banner.is-archive .banner-copy span { color: #836d49; }
.banner-icon { width: 29px; height: 29px; border-radius: 8px; color: #118d79; background: #ddf4ed; display: grid; place-items: center; font-size: 16px; }
.banner-copy { display: grid; gap: 2px; flex: 1; min-width: 0; }
.banner-copy strong { font-size: 11px; font-weight: 700; color: #24645b; }
.banner-copy span { font-size: 11px; color: #617f79; }
.api-status { color: #7a898e; font: 10px 'DM Mono', monospace; white-space: nowrap; }
.api-status.api-connected { color: #21826e; }
.text-button { border: 0; color: #248776; background: transparent; font-size: 11px; font-weight: 600; cursor: pointer; white-space: nowrap; }
.text-button span { margin-left: 4px; }
.alert-strip { min-height: 62px; border: 1px solid #f1d6d6; background: #fff7f6; border-radius: 10px; display: flex; align-items: center; gap: 11px; padding: 10px 14px; margin-bottom: 18px; position: relative; }
.alert-symbol { width: 25px; height: 25px; flex: 0 0 25px; display: grid; place-items: center; border-radius: 50%; background: #ffe5e2; color: #c8464d; font-weight: 800; font-size: 15px; }
.alert-copy { display: grid; gap: 2px; flex: 1; }
.alert-copy strong { color: #8c353a; font-size: 12px; }
.alert-copy span { color: #a46e71; font-size: 11px; }
.alert-action { border: 0; background: transparent; color: #a84448; font-size: 11px; font-weight: 700; cursor: pointer; white-space: nowrap; }
.alert-action span { margin-left: 5px; font-size: 14px; }
.dismiss-button { background: transparent; border: 0; color: #b78183; font-size: 20px; padding: 0 2px; cursor: pointer; line-height: 1; }

.stat-grid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 12px; margin-bottom: 29px; }
.stat-card { background: var(--white); border: 1px solid var(--line); border-radius: 11px; min-height: 121px; padding: 14px 16px 13px; box-shadow: 0 2px 7px rgba(20, 41, 53, .018); }
.stat-top { display: flex; align-items: center; justify-content: space-between; color: #8a969b; font: 500 9px 'DM Mono', monospace; letter-spacing: .7px; }
.stat-icon { width: 25px; height: 25px; border-radius: 7px; display: grid; place-items: center; font-weight: 700; font-size: 14px; }
.icon-teal { background: #e4f7f2; color: #198e7d; }
.icon-red { background: #fff0ef; color: #d05158; }
.icon-amber { background: #fff7e8; color: #c28a21; }
.icon-blue { background: #edf1ff; color: #5d74bf; }
.stat-value { margin-top: 9px; color: #18252e; font-size: 27px; font-weight: 700; letter-spacing: -1.2px; line-height: 1; }
.stat-unit { margin-left: 7px; color: #78858a; font-size: 11px; font-weight: 500; letter-spacing: 0; }
.stat-foot { display: flex; align-items: center; gap: 7px; margin-top: 10px; color: #849096; font-size: 10px; white-space: nowrap; }
.mini-indicator { width: 5px; height: 5px; border-radius: 50%; flex: 0 0 5px; }
.indicator-neutral { background: #8da19f; }
.indicator-red { background: #d65359; }
.indicator-amber { background: #dc9a2a; }
.indicator-green { background: #37a27f; }

.section-toolbar { display: flex; align-items: flex-end; justify-content: space-between; gap: 16px; margin-bottom: 12px; }
.section-title-wrap { display: flex; align-items: baseline; gap: 10px; flex-wrap: wrap; }
.section-title-wrap .section-kicker { flex-basis: 100%; margin-bottom: -3px; }
h2 { font-size: 18px; margin: 0; letter-spacing: -.55px; color: #24313a; }
.table-total { font: 10px 'DM Mono', monospace; color: #7e8b90; background: #edf1f1; padding: 4px 7px; border-radius: 5px; }
.table-controls { display: flex; gap: 8px; }
.search-field { display: flex; align-items: center; width: 218px; height: 34px; border: 1px solid #e2e7e9; background: white; border-radius: 7px; padding: 0 8px; gap: 7px; color: #92a0a5; }
.search-field > span { font-size: 20px; line-height: 1; transform: rotate(-18deg); }
.search-field input { min-width: 0; width: 100%; border: 0; outline: 0; color: #31414a; font-size: 11px; background: transparent; }
.search-field input::placeholder { color: #a2acb0; }
.search-field kbd { background: #f4f6f7; border: 1px solid #edf0f1; color: #97a2a6; border-radius: 4px; font: 9px 'DM Mono', monospace; padding: 2px 4px; white-space: nowrap; }
.filter-button { height: 34px; border: 1px solid #e2e7e9; border-radius: 7px; background: white; color: #68767d; padding: 0 9px; font-size: 11px; display: flex; align-items: center; gap: 7px; cursor: pointer; }
.filter-glyph { color: #839096; font-size: 14px; }
.filter-chevron { color: #9ca7ab; margin-left: 3px; }
.filter-row { display: flex; align-items: center; gap: 7px; margin-bottom: 10px; }
.filter-chip { border: 1px solid transparent; background: transparent; color: #77858a; border-radius: 7px; padding: 6px 9px; cursor: pointer; font-size: 10px; display: flex; align-items: center; gap: 6px; }
.filter-chip > span:last-child { color: #9aa4a8; font: 10px 'DM Mono', monospace; }
.filter-chip:hover { background: white; }
.filter-chip.selected { border-color: #dfe8e7; color: #2e7569; background: white; box-shadow: 0 2px 5px rgba(20, 41, 53, .025); }
.filter-chip.selected > span:last-child { color: #548a80; }
.chip-dot { height: 6px; width: 6px; border-radius: 50%; }
.dot-red { background: #d75d62; }
.dot-amber { background: #dda137; }
.dot-green { background: #46a783; }

.inventory-card, .panel-card { border: 1px solid var(--line); background: white; border-radius: var(--radius); box-shadow: 0 3px 9px rgba(20, 41, 53, .02); }
.inventory-card { overflow: hidden; }
.table-scroll { overflow-x: auto; }
table { border-collapse: collapse; width: 100%; min-width: 670px; }
thead { background: #fafbfb; }
th { height: 37px; padding: 0 15px; color: #8a969b; border-bottom: 1px solid #edf0f1; text-align: left; font: 500 9px 'DM Mono', monospace; letter-spacing: .8px; white-space: nowrap; }
th:first-child { padding-left: 18px; }
td { height: 50px; padding: 7px 15px; border-bottom: 1px solid #f0f2f3; color: #59686f; font-size: 11px; white-space: nowrap; }
tbody tr:last-child td { border-bottom: 0; }
tbody tr:hover { background: #fbfdfd; }
.domain-col { width: 34%; }
.row-action-col { width: 36px; }
.domain-cell { display: flex; align-items: center; gap: 10px; padding-left: 18px; }
.domain-mark { width: 28px; height: 28px; border-radius: 8px; display: grid; place-items: center; color: #48877c; background: #edf7f4; font: 600 11px 'DM Mono', monospace; text-transform: uppercase; }
.domain-name { display: grid; gap: 2px; }
.domain-name strong { font-size: 11px; color: #25343c; font-weight: 700; }
.domain-name small { font-size: 10px; color: #9ba6aa; }
.config-tag { background: #f3f5f6; border: 1px solid #edf0f1; color: #758187; border-radius: 5px; padding: 4px 7px; font: 10px 'DM Mono', monospace; }
.expiry { display: grid; gap: 2px; }
.expiry strong { color: #526168; font-size: 10px; font-weight: 600; }
.expiry small { color: #9ca7ab; font-size: 9px; }
.expiry.expired strong, .expiry.expired small { color: #bd4c53; }
.expiry.soon strong { color: #b87b18; }
.status-pill { border-radius: 5px; padding: 4px 7px; display: inline-flex; align-items: center; gap: 6px; font-size: 10px; font-weight: 600; }
.status-pill::before { content: ''; height: 5px; width: 5px; border-radius: 50%; }
.status-expired { color: #b7444a; background: #fff0ef; }
.status-expired::before { background: #d4585c; }
.status-soon { color: #a6751e; background: #fff7e8; }
.status-soon::before { background: #d89a2b; }
.status-valid { color: #397f6b; background: #edf8f3; }
.status-valid::before { background: #49a984; }
.row-menu { border: 0; background: transparent; color: #a1abad; cursor: pointer; font-size: 16px; line-height: 1; padding: 6px; border-radius: 5px; }
.row-menu:hover { background: #eef5f3; color: #258b78; }
.table-footer { height: 40px; border-top: 1px solid #edf0f1; display: flex; align-items: center; justify-content: space-between; padding: 0 16px; color: #929da1; font-size: 10px; }
.table-footer strong { color: #59686f; font-weight: 600; }
.table-source { display: flex; align-items: center; gap: 7px; }
.source-dot { width: 5px; height: 5px; flex-basis: 5px; box-shadow: none; }
.empty-state { min-height: 170px; display: grid; place-content: center; text-align: center; gap: 5px; color: #819096; font-size: 11px; }
.empty-state[hidden] { display: none; }
.empty-icon { font-size: 22px; margin-bottom: 5px; }
.empty-state strong { color: #44525a; font-size: 13px; }

.lower-grid { display: grid; grid-template-columns: 1.05fr .95fr; gap: 12px; margin-top: 15px; }
.panel-card { min-width: 0; padding: 16px 17px 0; }
.card-heading { display: flex; align-items: flex-start; justify-content: space-between; gap: 12px; }
.card-heading h3 { margin: 5px 0 0; color: #26343c; font-size: 14px; letter-spacing: -.35px; }
.status-label { display: inline-flex; gap: 6px; align-items: center; border-radius: 5px; padding: 5px 7px; font-size: 9px; }
.status-label-neutral { background: #eef3f2; color: #4d756d; }
.status-label-neutral span { width: 5px; height: 5px; border-radius: 50%; background: #5fa58f; }
.protocol-list { display: grid; gap: 13px; margin: 18px 0 14px; }
.protocol-row { display: flex; align-items: center; gap: 10px; min-width: 0; }
.protocol-mark { width: 32px; height: 32px; border-radius: 9px; flex: 0 0 32px; display: grid; place-items: center; font: 600 11px 'DM Mono', monospace; }
.protocol-mark-green { color: #287b68; background: #eaf7f2; }
.protocol-mark-muted { color: #78858a; background: #f0f3f4; }
.protocol-copy { display: grid; gap: 3px; min-width: 0; flex: 1; }
.protocol-copy strong { color: #43535a; font-size: 11px; }
.protocol-copy small { color: #849095; font-size: 10px; line-height: 1.45; }
.protocol-state { border-radius: 5px; padding: 4px 6px; font-size: 9px; white-space: nowrap; }
.protocol-state-good { color: #397f6b; background: #edf8f3; }
.protocol-state-warn { color: #a6751e; background: #fff7e8; }
.capability-matrix { margin: 16px 0 12px; border: 1px solid #e9eeef; border-radius: 8px; overflow: hidden; }
.capability-head, .capability-row { display: grid; grid-template-columns: 1.1fr .72fr .72fr 1fr; align-items: center; gap: 5px; padding: 8px 9px; }
.capability-head { background: #f8fafa; color: #89969b; font: 500 8px 'DM Mono', monospace; letter-spacing: .35px; }
.capability-row { min-height: 38px; border-top: 1px solid #eef1f2; }
.capability-row strong { color: #48575e; font-size: 10px; }
.matrix-state { width: fit-content; border-radius: 5px; padding: 4px 5px; font-size: 9px; line-height: 1; white-space: nowrap; }
.matrix-good { background: #edf8f3; color: #397f6b; }
.matrix-bad { background: #fff0ef; color: #b7444a; }
.matrix-unknown { background: #fff7e8; color: #a6751e; }
.matrix-muted { background: #f1f3f4; color: #78858a; }
.acme-body { display: flex; gap: 11px; margin: 19px 0 14px; align-items: flex-start; }
.acme-mark { width: 35px; height: 35px; flex: 0 0 35px; border-radius: 10px; background: #f1f7f5; border: 1px solid #e2efeb; display: grid; place-items: center; color: #2e806e; font: 700 15px 'DM Mono', monospace; letter-spacing: -3px; }
.acme-mark span { color: #92b8ad; }
.acme-description { display: grid; gap: 5px; }
.acme-description strong { color: #43535a; font-size: 11px; }
.acme-description span { color: #79868b; font-size: 10px; line-height: 1.55; }
.acme-description code { color: #4f7470; background: #f4f8f7; padding: 1px 3px; font: 10px 'DM Mono', monospace; }
.acme-foot { min-height: 34px; border-top: 1px solid #eff2f2; display: flex; align-items: center; gap: 7px; color: #9b772c; font-size: 10px; }
.warning-dot { width: 5px; height: 5px; border-radius: 50%; background: #dba13e; }
.host-badge { vertical-align: 2px; margin-left: 5px; background: #eff2f3; color: #7d8a8f; border-radius: 4px; padding: 3px 5px; font: 500 8px 'DM Mono', monospace; letter-spacing: .35px; }
.host-info-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 12px 18px; padding: 17px 0 14px; }
.host-info-grid > div { display: grid; gap: 3px; }
.host-info-grid span { color: #9aa5a9; font: 9px 'DM Mono', monospace; letter-spacing: .5px; }
.host-info-grid strong { color: #516168; font-size: 10px; font-weight: 600; }
.host-info-grid .valid-value { color: #397d69; display: flex; align-items: center; gap: 5px; }
.host-info-grid .warning-value { color: #a6751e; }
.host-info-grid .muted-value { color: #7c888d; }
.valid-value i { display: inline-block; background: #4ea987; width: 5px; height: 5px; border-radius: 50%; }
.host-card-foot { min-height: 34px; border-top: 1px solid #eff2f2; display: flex; align-items: center; gap: 8px; color: #919da1; font-size: 10px; }
.host-card-foot code { color: #607078; background: #f5f7f7; padding: 3px 5px; border-radius: 4px; font: 10px 'DM Mono', monospace; }
.foot-lock { margin-left: auto; color: #73817f; }
.safe-pipeline-card { margin-top: 12px; padding-bottom: 14px; }
.safe-steps { display: grid; grid-template-columns: repeat(5, minmax(0, 1fr)); gap: 8px; margin: 15px 0; }
.safe-step { min-width: 0; min-height: 67px; border: 1px solid #e9eeef; border-radius: 8px; padding: 8px; display: grid; align-content: start; gap: 4px; }
.safe-step > span { color: #3e9986; font: 9px 'DM Mono', monospace; }
.safe-step strong { color: #48575e; font-size: 10px; }
.safe-step small { color: #8a969b; font-size: 9px; line-height: 1.35; }
.safe-pipeline-foot { padding-top: 11px; border-top: 1px solid #edf0f1; display: flex; align-items: center; justify-content: space-between; gap: 12px; }
.safe-pipeline-foot > div:first-child { display: grid; gap: 3px; }
.safe-pipeline-foot strong { color: #58676d; font-size: 10px; }
.safe-pipeline-foot span { color: #89959a; font-size: 10px; }
.safe-actions { display: flex; gap: 7px; }
.safe-actions .button { min-height: 32px; font-size: 10px; }
.button-disabled, .button-disabled:disabled { background: #edf0f1; border-color: #e6eaeb; color: #9ba5a8; box-shadow: none; cursor: not-allowed; transform: none; }
.page-footer { display: flex; align-items: center; gap: 10px; color: #9aa4a8; font-size: 10px; padding: 19px 2px 0; }
.footer-version { margin-left: 7px; color: #70857f; font: 9px 'DM Mono', monospace; letter-spacing: .3px; }
.page-footer > span:nth-child(2) { margin-left: auto; }
.page-footer button { border: 0; background: transparent; color: #5b9285; cursor: pointer; font-size: 10px; }

.modal { border: 0; padding: 0; width: min(740px, calc(100vw - 28px)); max-height: min(92vh, 900px); border-radius: 15px; box-shadow: 0 24px 80px rgba(12, 30, 39, .24); overflow: auto; color: var(--ink); }
.modal::backdrop { background: rgba(9, 19, 26, .52); backdrop-filter: blur(3px); }
.modal-shell { padding: 23px; }
.modal-top { display: flex; justify-content: space-between; align-items: flex-start; gap: 20px; }
.modal-top h2 { margin-top: 6px; font-size: 21px; }
.modal-top p { color: #78858b; font-size: 11px; margin: 7px 0 0; }
.modal-close { border: 0; background: #f3f5f6; color: #68767c; border-radius: 7px; font-size: 19px; width: 29px; height: 29px; cursor: pointer; }
.form-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 11px; margin-top: 19px; }
.field { display: grid; gap: 6px; min-width: 0; }
.field-wide { grid-column: 1 / -1; }
.field > span { font-size: 10px; color: #67757b; font-weight: 600; }
.field input, .field select { height: 37px; border: 1px solid #dfe6e8; border-radius: 7px; padding: 0 10px; color: #34444b; background: white; font-size: 11px; width: 100%; }
.field input::placeholder { color: #aab4b7; }
.field[hidden] { display: none; }
.modal-note { display: flex; gap: 8px; margin: 13px 0 17px; padding: 9px 10px; border-radius: 7px; background: #f4f8f7; color: #687e79; font-size: 10px; line-height: 1.5; }
.note-glyph { border: 1px solid #9bbcb4; border-radius: 50%; height: 14px; width: 14px; flex: 0 0 14px; text-align: center; font: 10px Georgia, serif; }
.feature-note { background: #fff8eb; color: #886e40; }
.feature-note .note-glyph { border-color: #d7b56c; color: #a17b29; }
.feature-field { margin: 0; border: 1px solid #e2e8e9; border-radius: 8px; padding: 9px 10px 10px; display: grid; grid-template-columns: 1fr 1fr; gap: 9px; }
.feature-field legend { color: #67757b; font-size: 10px; font-weight: 600; padding: 0 4px; }
.feature-option { border: 1px solid #edf0f1; border-radius: 7px; background: #fbfcfc; padding: 8px; display: flex; align-items: flex-start; gap: 7px; cursor: pointer; }
.feature-option input { accent-color: #0ba98f; margin: 2px 0 0; flex: 0 0 auto; }
.feature-option span { display: grid; gap: 3px; }
.feature-option strong { color: #47565d; font-size: 10px; }
.feature-option small { color: #89959a; font-size: 9px; line-height: 1.4; }
.preview-heading { display: flex; justify-content: space-between; align-items: center; color: #879399; font: 10px 'DM Mono', monospace; letter-spacing: .8px; margin-bottom: 7px; }
.preview-stage { display: flex; align-items: center; gap: 9px; margin-bottom: 8px; color: #718087; font-size: 10px; }
.preview-stage select { min-height: 30px; border: 1px solid #dfe6e7; border-radius: 6px; padding: 0 8px; background: #fff; color: #405159; font-size: 10px; }
.copy-button { border: 0; background: transparent; color: #268c7b; font: 600 10px Manrope, sans-serif; cursor: pointer; }
.config-preview { margin: 0; padding: 13px; background: #111b21; color: #b8d6cc; border-radius: 9px; white-space: pre-wrap; overflow-wrap: anywhere; max-height: 276px; overflow: auto; font: 10px/1.58 'DM Mono', monospace; }
.preview-warning { margin: 0 0 8px; padding: 9px 11px; border: 1px solid #f0ddae; border-radius: 7px; background: #fff8e8; color: #8a641d; font-size: 11px; line-height: 1.45; }
.preview-warning.saved { border-color: #cce9df; background: #f0faf6; color: #2d7668; }
.modal-bottom { display: flex; align-items: center; justify-content: space-between; gap: 14px; margin-top: 15px; }
.preview-only { display: flex; align-items: center; gap: 7px; font-size: 10px; color: #78868b; }
.preview-only > span { width: 6px; height: 6px; border-radius: 50%; background: #59aa8c; }
.small-modal { width: min(500px, calc(100vw - 28px)); }
.info-content { color: #67757c; font-size: 12px; line-height: 1.7; margin: 17px 0 22px; }
.info-content p { margin: 0 0 11px; }
.info-content h3 { margin: 18px 0 8px; color: #34454c; font-size: 12px; }
.info-content ul { margin: 8px 0 0; padding-left: 18px; }
.info-content li { margin-bottom: 5px; }
.info-content code { color: #39786d; background: #f0f7f5; padding: 1px 4px; border-radius: 4px; font: 11px 'DM Mono', monospace; }
.draft-list { list-style: none; padding: 0 !important; max-height: 150px; overflow: auto; }
.draft-open { display: flex; width: 100%; align-items: center; justify-content: space-between; gap: 12px; padding: 8px 10px; border: 1px solid #e6eceb; border-radius: 7px; background: #fff; color: #43545a; text-align: left; cursor: pointer; }
.draft-open:hover { border-color: #b9ddd2; background: #f5fbf8; }
.draft-open strong { font-size: 11px; }
.draft-open span { color: #899599; font: 9px 'DM Mono', monospace; }
.draft-task-actions { flex-wrap: wrap; margin: 10px 0 14px; }
.task-list { list-style: none; padding: 0 !important; max-height: 190px; overflow: auto; }
.task-item { display: flex; align-items: center; justify-content: space-between; gap: 10px; padding: 9px 10px; margin-bottom: 6px; border: 1px solid #e6eceb; border-radius: 7px; background: #fff; }
.task-item > div { display: grid; gap: 3px; min-width: 0; }
.task-controls { justify-items: end; flex: 0 0 auto; }
.task-actions { display: flex; align-items: center; gap: 5px; }
.task-target-select { max-width: 150px; min-height: 28px; padding: 3px 6px; border: 1px solid #dfe5e7; border-radius: 6px; color: #43535b; background: #fff; font: 9px 'DM Mono', monospace; }
.task-assign, .task-approve { flex: 0 0 auto; min-height: 28px !important; padding: 0 8px !important; font-size: 9px !important; }
.task-signing-note { padding: 8px 10px; border-radius: 6px; background: #fff8e9; color: #806522; }
.task-item strong { color: #43545a; font-size: 10px; }
.task-item small { color: #899599; font-size: 9px; overflow-wrap: anywhere; }
.task-item .task-request { color: #627278; }
.task-preview { margin-top: 4px; padding: 6px; border: 1px solid #e6eceb; border-radius: 5px; background: #f8faf9; }
.task-preview summary { color: #39786d; cursor: pointer; font-size: 9px; overflow-wrap: anywhere; }
.task-preview h4 { margin: 6px 0 3px; color: #43545a; font-size: 9px; }
.task-preview ul { margin: 4px 0 6px; }
.task-diff { max-height: 260px; overflow: auto; padding: 8px; background: #f0f4f3; color: #35494f; font: 9px/1.5 'DM Mono', monospace; white-space: pre; }
.task-state { color: #96702a; font-size: 9px; }
.task-cancel, .task-open-plan { flex: 0 0 auto; min-height: 28px !important; padding: 0 8px !important; font-size: 9px !important; }
.target-list { list-style: none; padding: 0 !important; max-height: 230px; overflow: auto; }
.target-item { display: flex; align-items: center; justify-content: space-between; gap: 10px; padding: 9px 10px; margin-bottom: 6px; border: 1px solid #e6eceb; border-radius: 7px; background: #fff; }
.target-item > div:first-child { display: grid; gap: 3px; min-width: 0; }
.target-item strong { color: #43545a; font-size: 11px; }
.target-item small { color: #899599; font-size: 9px; overflow-wrap: anywhere; }
.target-actions, .target-token-actions { display: flex; flex-wrap: wrap; gap: 6px; }
.target-actions .button { min-height: 28px; padding: 0 8px; font-size: 9px; }
.target-name-field { margin-bottom: 9px; }
.target-token-actions { margin: 10px 0 15px; }
.target-token-actions .button { min-height: 32px; font-size: 10px; }
.draft-config { max-height: 260px; overflow: auto; white-space: pre-wrap; overflow-wrap: anywhere; padding: 12px; border-radius: 8px; background: #111b21; color: #b8d6cc; font: 10px/1.55 'DM Mono', monospace; }

@media (max-width: 1180px) {
  .sidebar { width: 220px; flex-basis: 220px; }
  .main-area { margin-left: 220px; width: calc(100% - 220px); }
  .topbar { padding: 0 28px; }
  .page-wrap { padding-left: 28px; padding-right: 28px; }
  .stat-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (max-width: 980px) {
  .sidebar { width: 64px; flex-basis: 64px; padding: 20px 8px 12px; align-items: center; }
  .brand { padding: 0; }
  .brand-copy, .workspace-switcher, .nav-label, .sidebar-section-label, .nav-item:not(.active) .nav-count, .nav-count, .nav-badge, .sidebar-spacer, .server-copy, .server-menu, .profile-copy, .footer-menu { display: none; }
  .main-nav { margin-top: 32px; width: 100%; }
  .nav-item { justify-content: center; padding: 0; font-size: 0; }
  .nav-icon { font-size: 18px; }
  .server-switcher { padding: 12px; justify-content: center; margin-top: auto; }
  .sidebar-footer { padding: 13px 0 0; justify-content: center; width: 100%; }
  .main-area { margin-left: 64px; width: calc(100% - 64px); }
  .topbar { padding: 0 19px; }
  .page-wrap { padding: 25px 19px 22px; }
  .page-heading { align-items: flex-start; flex-direction: column; gap: 15px; }
  .heading-actions { width: 100%; }
  .heading-actions .button { flex: 1; }
  .snapshot-banner { align-items: flex-start; }
  .text-button { align-self: center; }
  .lower-grid { grid-template-columns: 1fr; }
  .safe-steps { grid-template-columns: repeat(3, minmax(0, 1fr)); }
}
@media (max-width: 520px) {
  .topbar { height: 55px; }
  .snapshot-pill { border: 0; padding: 0; font-size: 0; gap: 0; }
  .snapshot-pill time { font-size: 10px; margin-left: 6px; }
  .snapshot-pill .snapshot-dot { margin-right: 0; }
  .page-wrap { padding: 20px 13px; }
  .page-heading p { font-size: 12px; line-height: 1.5; }
  .heading-actions .button { padding: 0 8px; font-size: 10px; }
  .banner-copy span { line-height: 1.5; }
  .text-button { display: none; }
  .alert-strip { gap: 8px; padding: 9px; }
  .alert-copy span { font-size: 10px; }
  .alert-action { font-size: 0; }
  .alert-action span { font-size: 15px; }
  .stat-grid { gap: 8px; }
  .stat-card { padding: 12px 10px; min-height: 112px; }
  .stat-top { font-size: 8px; letter-spacing: .25px; }
  .stat-foot { font-size: 9px; white-space: normal; }
  .stat-value { font-size: 24px; }
  .section-toolbar { align-items: flex-start; flex-direction: column; }
  .table-controls { width: 100%; }
  .search-field { flex: 1; }
  .filter-row { overflow-x: auto; }
  .table-footer { padding: 0 10px; font-size: 9px; }
  .table-source { font-size: 9px; }
  .page-footer { flex-wrap: wrap; }
  .page-footer > span:nth-child(2) { margin-left: auto; }
  .page-footer button { flex-basis: 100%; text-align: left; padding: 0; }
  .safe-steps { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .safe-pipeline-foot { align-items: flex-start; flex-direction: column; }
  .safe-actions { width: 100%; }
  .safe-actions .button { flex: 1; }
  .modal-shell { padding: 17px; }
  .form-grid { grid-template-columns: 1fr; }
  .field-wide { grid-column: auto; }
  .modal-bottom { align-items: flex-start; flex-direction: column; }
  .modal-bottom .button { width: 100%; }
}
