:root {
  color-scheme: light;
  --ink: #192f32;
  --subtle: #52696a;
  --muted: #607472;
  --line: #dce4df;
  --surface: #fff;
  --page: #f5f7f4;
  --nav: #142e32;
  --nav-active: #29494b;
  --accent: #006849;
  --accent-dark: #00553b;
  --pale: #e8f3ec;
  --warm: #f1be74;
  font-family: "Inter", "Segoe UI", system-ui, -apple-system, sans-serif;
  font-size: 15px;
  -webkit-text-size-adjust: 100%;
}
*, *::before, *::after { box-sizing: border-box; }
body { margin: 0; color: var(--ink); background: var(--page); }
h1, h2, h3, p, ul, dl, dd { margin: 0; }
button, input, select, textarea { font: inherit; }
button, a, input, select, textarea { -webkit-tap-highlight-color: transparent; }
button, a { touch-action: manipulation; }
a { color: var(--accent); text-underline-offset: 3px; }
button:not(:disabled), select:not(:disabled), summary { cursor: pointer; }
button:disabled { cursor: wait; opacity: .55; }
button[disabled]:not(.primary) { cursor: default; }
button, input, textarea, select, summary, a { outline-offset: 3px; }
:focus-visible { outline: 3px solid #a86a23; }
[hidden] { display: none !important; }
.icon { width: 20px; height: 20px; flex: 0 0 auto; vertical-align: middle; }
.skip-link { z-index: 5; position: fixed; top: -60px; left: 8px; background: white; padding: 10px; }
.skip-link:focus { top: 8px; }
.app-shell { min-height: 100vh; display: grid; grid-template-columns: 218px minmax(0, 1fr); }
.sidebar { position: sticky; top: 0; height: 100vh; height: 100dvh; display: flex; flex-direction: column; padding: 29px 14px 23px; background: var(--nav); color: #f3f7ef; }
.brand { display: flex; align-items: center; gap: 11px; padding: 0 9px; }
.brand strong { display: block; letter-spacing: -.075em; font-size: 27px; line-height: 1; font-weight: 770; }
.brand div > span { display: block; font-size: 12px; letter-spacing: .01em; color: #bcd0c7; margin-top: 5px; }
.brand-symbol { display: grid; grid-template-columns: repeat(2, 12px); grid-template-rows: repeat(2, 12px); gap: 3px; transform: skewY(-8deg); }
.brand-symbol i { background: var(--warm); border-radius: 1px; }
.brand-symbol i:nth-child(2) { opacity:.54; }
.brand-symbol i:nth-child(3) { opacity:.78; }
.navigation { display: grid; gap: 5px; margin-top: 43px; }
.nav-link { color: #c6d7d0; text-decoration: none; display: flex; align-items: center; gap: 12px; min-height: 45px; padding: 10px 13px; border-radius: 7px; font-size: 14px; font-weight: 550; }
.nav-link:hover { background: #203d40; color: #fff; }
.nav-link.active { background: var(--nav-active); color: #fff; box-shadow: inset 3px 0 var(--warm); }
.nav-link.active .icon { color: var(--warm); }
.nav-short { display: none; }
.nav-more { display:none; border:0; background:transparent; font-family:inherit; }
.extra-nav { display:contents; }
.workspace-version { margin: auto 8px 0; padding-top: 20px; color: #a8bdb5; border-top: 1px solid #355053; font-size: 12px; }
.workspace { min-width: 0; }
.topbar { min-height: 66px; display: flex; align-items: center; justify-content: space-between; gap: 14px; padding: 10px clamp(20px, 3.4vw, 58px); background: #fff; border-bottom: 1px solid var(--line); }
.crumb, .identity { display: flex; align-items: center; gap: 10px; font-size: 13px; }
.crumb { color: var(--muted); }
.crumb > span:nth-child(2) { color: #9da9a4; }
.crumb strong { color: var(--ink); font-weight: 600; }
.identity { font-weight: 600; }
.account-menu { position: relative; }
.account-menu summary { display: flex; align-items: center; gap: 8px; list-style: none; border-radius: 6px; }
.account-menu summary::-webkit-details-marker { display: none; }
.account-menu form { position: absolute; z-index: 4; right: 0; top: calc(100% + 8px); border: 1px solid var(--line); background: white; border-radius: 6px; padding: 5px; box-shadow: 0 3px 12px #18362615; }
.account-menu button { padding: 8px 12px; white-space: nowrap; color: var(--ink); background: white; border: 0; border-radius: 4px; font-size: 13px; }
.account-menu button:hover { background: var(--pale); }
.avatar { display: grid; place-items: center; width: 31px; height: 31px; border: 1px solid #c9ddd4; border-radius: 50%; color: #295541; background: #e7efe7; font-size: 11px; letter-spacing: .03em; }
main:focus { outline: none; }
.page { width: 100%; max-width: 1660px; margin: 0 auto; padding: clamp(25px,4vw,54px) clamp(20px,3.4vw,58px) 60px; }
.page-heading { display: flex; align-items: center; justify-content: space-between; gap: 20px; margin-bottom: 26px; }
h1 { font-size: clamp(31px,3.1vw,47px); font-weight: 680; line-height: 1.12; letter-spacing: -.049em; }
.page-heading p, .login-card p { color: var(--subtle); font-size: 15px; line-height: 1.55; margin-top: 9px; }
.layout { display: grid; align-items: start; gap: 18px; }
.import-layout { grid-template-columns: minmax(0, 1.85fr) minmax(236px, .85fr); }
.settings-layout { grid-template-columns: minmax(0,1.65fr) minmax(240px,.85fr); }
.master-detail { grid-template-columns: minmax(250px, .95fr) minmax(0,1.45fr); }
.panel { min-width: 0; background: var(--surface); border: 1px solid var(--line); border-radius: 12px; box-shadow: 0 2px 4px #18362606; }
.panel-heading { display: flex; gap: 13px; align-items: center; padding: 22px 24px; border-bottom: 1px solid var(--line); }
.feature-icon, .small-icon, .upload-icon, .detail-icon { display: grid; place-items: center; color: var(--accent); background: var(--pale); border-radius: 9px; }
.feature-icon { width: 44px; height: 44px; }
.feature-icon .icon { width: 25px; height: 25px; }
h2 { font-size: 19px; font-weight: 650; line-height: 1.34; letter-spacing: -.027em; }
h3 { font-size: 15px; font-weight: 650; line-height: 1.42; }
.panel-heading p { color: var(--muted); margin-top: 4px; font-size: 13px; }
.panel-body, .detail-body { padding: 23px 24px; }
.file-pick { position: relative; display: flex; flex-direction: column; gap: 13px; align-items: center; justify-content: center; padding: 27px 20px; text-align: center; border: 1.5px dashed #93b2a2; border-radius: 9px; min-height: 210px; background: #f6faf6; color: var(--ink); cursor: pointer; }
.file-pick:hover, .file-pick.drag-active { border-color: var(--accent); background: #edf7ee; }
.file-pick:focus-within { outline: 3px solid #a86a23; outline-offset: 2px; }
.file-pick input { position: absolute; z-index: 1; width: 100%; height: 100%; inset: 0; margin: 0; padding: 0; opacity: 0; cursor: pointer; }
.upload-icon { width: 43px; height: 43px; border: 1px solid #d1e4d8; background: #e8f2e9; }
.upload-icon .icon { width: 23px; height: 23px; }
.pick-copy { display: grid; gap: 4px; max-width: 100%; }
.pick-copy strong { font-size: 17px; font-weight: 630; overflow-wrap: anywhere; }
.pick-copy small, .meta, .detail-meta { font-size: 13px; color: var(--subtle); line-height: 1.5; }
.file-cta, .button { display: inline-flex; align-items: center; justify-content: center; gap: 7px; padding: 9px 14px; min-height: 39px; border-radius: 6px; border: 1px solid transparent; font-size: 13px; font-weight: 650; text-decoration: none; line-height: 1.4; }
.file-cta, .button.primary { color: #fff; background: var(--accent); }
.button.primary:hover:not(:disabled), .file-pick:hover .file-cta { background: var(--accent-dark); }
.button.secondary { background: white; border-color: #cbd8cf; color: #274c3b; }
.button.secondary:hover:not(:disabled) { background: #f2f7f2; border-color: #8fa99a; }
.button .icon, .file-cta .icon { width: 16px; height: 16px; }
.file-pick.compact { min-height: 75px; flex-direction: row; justify-content: flex-start; padding: 13px; gap: 12px; text-align: left; }
.file-pick.compact .pick-copy { flex: 1; min-width: 0; }
.file-pick.compact .pick-copy strong { font-size: 14px; }
.file-pick.compact .file-cta { min-height: 32px; padding: 4px 8px; color: var(--accent-dark); background: #ecf4ed; }
.rail-heading { display: flex; align-items: center; gap: 10px; padding: 20px 21px; border-bottom: 1px solid var(--line); }
.rail-heading .icon { color: #57776b; }
.rail-heading h2 { font-size: 17px; }
.empty-state { padding: 23px 22px; }
.empty-state strong, .history-item strong { font-size: 14px; font-weight: 600; }
.empty-state p, .detail-placeholder p { margin-top: 5px; font-size: 13px; line-height: 1.53; color: var(--muted); }
.history-list { list-style: none; padding: 0 19px; max-height: 560px; overflow-y: auto; }
.history-item { display: flex; gap: 9px; align-items: center; padding: 14px 0; border-bottom: 1px solid var(--line); }
.history-item:last-child { border-bottom: 0; }
.history-item > div { min-width: 0; flex: 1; }
.history-item strong, .history-item small { display: block; overflow-wrap: anywhere; }
.history-item small, .record small { color: var(--muted); font-size: 12px; line-height: 1.4; font-weight: 400; }
.small-icon { width: 31px; height: 33px; flex-shrink: 0; border-radius: 6px; }
.small-icon .icon { width: 17px; height: 17px; }
.history-count { font-size: 12px; color: var(--subtle); white-space: nowrap; }
.history-search { display: flex; align-items: end; gap: 10px; padding: 20px; }
.history-search label { flex: 1; }
.memory-results { padding: 0 21px; margin: 0; list-style: none; }
.memory-results li { padding: 15px 0; border-bottom: 1px solid var(--line); }
.memory-results li:last-child { border-bottom: 0; }
.memory-results .detail-meta { overflow-wrap: anywhere; }
.memory-results .prose { margin-top: 4px; }
.history-search + .rail-heading { border-top: 1px solid var(--line); flex-wrap: wrap; }
.section-block { margin-top: 23px; padding-top: 20px; border-top: 1px solid var(--line); }
.section-title, .actions, .detail-meta { display: flex; align-items: center; gap: 9px; flex-wrap: wrap; }
.section-title { justify-content: space-between; gap: 9px; margin-bottom: 11px; }
.actions { margin-top: 19px; }
.form-stack .actions { margin-top: 0; }
fieldset { margin: 0; padding: 0; border: 0; min-width: 0; }
form label { display: grid; gap: 6px; font-size: 13px; color: #314a47; font-weight: 600; }
.required { display: contents; font-size: 12px; font-weight: 400; color: var(--muted); }
input:not([type=file]), select, textarea { display: block; width: 100%; border: 1px solid #bfcdc3; border-radius: 6px; background: #fff; color: var(--ink); line-height: 1.45; padding: 9px 10px; min-width: 0; }
select { text-overflow: ellipsis; padding-right: 20px; }
form input, select, textarea { font-size: 14px; font-weight: 400; }
textarea { resize: vertical; min-height: 70px; }
input::placeholder, textarea::placeholder { color: #6b7d76; opacity: 1; }
.field-grid { display: grid; grid-template-columns: repeat(2,minmax(0,1fr)); gap: 13px; margin-top: 12px; }
.form-stack { display: grid; gap: 15px; }
.table-scroll { overflow: auto; max-width: 100%; max-height: 250px; margin-top: 13px; border: 1px solid var(--line); border-radius: 6px; }
table { width: 100%; border-collapse: collapse; font-size: 12px; text-align: left; }
td, th { padding: 8px 10px; min-width: 74px; max-width: 300px; border-bottom: 1px solid var(--line); overflow-wrap: anywhere; }
th { background: #f1f5ef; color: #3f584a; }
tr:last-child td { border-bottom: 0; }
.inline-error, .inline-success { padding: 12px; border-radius: 6px; font-size: 13px; line-height: 1.45; overflow-wrap: anywhere; }
.inline-error { background: #fff1eb; color: #8f3827; border: 1px solid #f3c4b3; margin-top: 12px; }
.inline-success { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; background: #eff7eb; color: #245b35; border: 1px solid #c8ddc7; margin-bottom: 13px; }
.inline-success .icon { width: 17px; height: 17px; }
.inline-success a { font-weight: 650; }
.search-wrap { border-bottom: 1px solid var(--line); padding: 14px; }
.search-field { position: relative; display: block; }
.search-field .icon { position: absolute; left: 11px; top: 50%; transform: translateY(-50%); color: var(--muted); width: 17px; height: 17px; }
.search-field input { padding-left: 36px; font-size: 13px; background: #fafbf8; }
.record { display: flex; justify-content: space-between; align-items: center; gap: 9px; width: 100%; padding: 15px; border: 0; border-bottom: 1px solid var(--line); color: var(--ink); background: white; text-align: left; }
.record:last-child { border-bottom: 0; border-radius: 0 0 12px 12px; }
.record:hover { background: #f6f9f5; }
.record.selected { background: #ecf5ed; box-shadow: inset 3px 0 var(--accent); }
.record-main, .record-meta { display: grid; gap: 5px; min-width: 0; }
.record-main { flex: 1; overflow-wrap: anywhere; }
.record-main strong { font-size: 14px; line-height: 1.42; }
.record-meta { flex-shrink: 0; justify-items: end; }
.record-meta small { font-size: 11px; }
.record-arrow { width: 16px; height: 16px; color: #708176; }
.list-panel > div:last-child { max-height: 72vh; overflow: auto; }
.status { display: inline-flex; align-items: center; gap: 5px; border-radius: 5px; padding: 3px 7px; color: #435c50; background: #edf1ed; font-size: 11px; font-weight: 650; line-height: 1.45; }
.status.good { background: #e1f2df; color: #285d2c; }
.status.bad { background: #fde8e3; color: #8e372b; }
.status.active { background: #e2eeff; color: #294e83; }
.status.waiting { background: #fcf0db; color: #795322; }
.detail-title { font-size: clamp(22px,2vw,30px); margin: 10px 0 9px; letter-spacing: -.04em; overflow-wrap: anywhere; }
.detail-meta { font-size: 12px; }
.detail-placeholder { display: flex; flex-direction: column; align-items: flex-start; justify-content: center; padding: 35px 30px; min-height: 215px; }
.detail-placeholder .button { margin-top: 14px; }
.detail-icon { width: 40px; height: 40px; margin-bottom: 15px; }
.agent-label { display: flex; gap: 7px; align-items: center; color: var(--subtle); font-size: 13px; }
.agent-label .icon { width: 16px; height: 16px; }
.prose { white-space: pre-wrap; overflow-wrap: anywhere; margin-top: 9px; font-size: 14px; line-height: 1.65; }
.result { background: #f5f8f3; padding: 14px; border-radius: 6px; }
.properties { margin: 17px 0; }
.properties > div { display: grid; grid-template-columns: minmax(85px, .5fr) minmax(0,1.5fr); gap: 12px; padding: 10px 0; border-bottom: 1px solid var(--line); font-size: 13px; }
.properties dt { color: var(--muted); }
.properties dd { overflow-wrap: anywhere; font-weight: 550; }
.compact-props > div { display: block; }
.compact-props dd { margin-top: 4px; }
.graph-status p { margin-top: 8px; color: var(--subtle); font-size: 13px; line-height: 1.45; }
.graph-status .actions { margin-top: 12px; }
.contact-actions { margin-top: 20px; font-size: 13px; }
.contact-actions summary { color: var(--accent); font-weight: 650; padding: 5px 0; }
.contact-actions form { margin-top: 15px; }
.contact-actions form + form { border-top: 1px solid var(--line); padding-top: 15px; }
.contact-actions button { justify-self: start; }
.model-form + .model-form { padding-top: 20px; margin-top: 20px; border-top: 1px solid var(--line); }
.model-fields { display: grid; grid-template-columns: minmax(110px,1.6fr) minmax(78px,.7fr) auto; gap: 9px; align-items: end; margin-top: 10px; }
.login-card { width: min(100%,530px); margin: 6vh auto; padding: clamp(22px,4vw,40px); background: white; border: 1px solid var(--line); border-radius: 12px; }
.login-card .feature-icon { margin-bottom: 18px; }
.login-card .button { margin-top: 21px; }
.toast { position: fixed; bottom: 20px; right: 20px; z-index: 5; max-width: min(440px, calc(100vw - 40px)); padding: 13px 17px; background: #153a30; color: #fff; border-radius: 7px; box-shadow: 0 3px 10px #193c2733; font-size: 14px; line-height: 1.5; overflow-wrap: anywhere; }
.toast.error { background: #762d25; }
@media (min-width: 1100px) { .detail-panel { position: sticky; top: 16px; } }
@media (max-width: 1100px) {
  .app-shell { grid-template-columns: 185px minmax(0,1fr); }
  .sidebar { padding-left: 9px; padding-right: 9px; }
  .page { padding-left: 22px; padding-right: 22px; }
  .import-layout { grid-template-columns: minmax(0,1.7fr) minmax(212px,.9fr); }
  .settings-layout { grid-template-columns: minmax(0,1fr); }
  .master-detail { grid-template-columns: minmax(220px,.9fr) minmax(0,1.25fr); }
  .panel-body, .detail-body, .panel-heading { padding: 19px; }
}
@media (max-width: 850px) and (min-width: 761px) {
  .app-shell { grid-template-columns: 157px minmax(0,1fr); }
  .nav-link { padding-left: 9px; gap: 8px; font-size: 13px; }
  .import-layout { grid-template-columns: minmax(0,1fr); }
  .master-detail { grid-template-columns: minmax(160px,.8fr) minmax(0,1.2fr); }
  .record { flex-wrap: wrap; }
}
@media (max-width: 760px) {
  .app-shell { display: block; }
  .sidebar { position: static; padding: 12px 16px; height: auto; min-height: 57px; }
  .brand { padding: 0; gap: 8px; }
  .brand-symbol { grid-template-columns: repeat(2,8px); grid-template-rows: repeat(2,8px); gap: 2px; }
  .brand div { display: flex; gap: 8px; align-items: center; }
  .brand strong { font-size: 21px; }
  .brand div > span { margin: 0; font-size: 12px; }
  .navigation { position: fixed; z-index: 3; inset: auto 0 0; display: flex; justify-content: space-around; gap: 0; padding: 4px 4px max(4px, env(safe-area-inset-bottom)); margin: 0; background: var(--nav); border-top: 1px solid #335054; }
  .nav-link { flex: 1; flex-direction: column; justify-content: center; gap: 2px; min-height: 49px; padding: 4px; border-radius: 5px; font-size: 11px; }
  .nav-link.active { box-shadow: inset 0 2px var(--warm); }
  .nav-short { display: inline; }
  .nav-full, .workspace-version, .crumb { display: none; }
  .topbar { position: absolute; top: 12px; right: 15px; min-height: 30px; padding: 0; background: transparent; border: 0; color: #eef6ef; }
  .identity { gap: 6px; font-size: 11px; }
  .avatar { width: 27px; height: 27px; font-size: 10px; }
  .page { padding: 25px 15px calc(86px + env(safe-area-inset-bottom)); }
  .layout { grid-template-columns: minmax(0,1fr); gap: 14px; }
  .page-heading { align-items: flex-start; flex-wrap: wrap; gap: 12px; margin-bottom: 18px; }
  .page-heading p { font-size: 14px; margin-top: 6px; }
  .panel-heading, .panel-body, .detail-body, .rail-heading { padding: 16px; }
  .file-pick { min-height: 193px; padding: 20px 12px; }
  .empty-state { padding: 18px 16px; }
  .detail-panel { scroll-margin-top: 9px; }
  .list-panel > div:last-child { max-height: 42vh; }
  .search-wrap { padding: 11px; }
  .record { padding: 11px 13px; }
  .toast { bottom: calc(68px + env(safe-area-inset-bottom)); right: 12px; max-width: calc(100vw - 24px); }
  input:not([type=file]), select, textarea { font-size: 16px; }
  .model-fields { grid-template-columns: minmax(0,1.55fr) minmax(85px,1fr); }
  .model-fields button { justify-self: start; }
  .login-card { margin: 2vh auto; }
}
@media (max-width:420px) {
  .account-menu summary > span:last-child { max-width: 110px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
  .field-grid { grid-template-columns: minmax(0,1fr); }
  .history-item { gap: 7px; }
}
@media (prefers-reduced-motion: reduce) { *, *::before, *::after { scroll-behavior: auto !important; } }
.routing-wrap { display:grid; gap:16px; }
.routing-overview { display:grid; grid-template-columns:repeat(3,minmax(0,1fr)); padding:17px 20px; gap:16px; }
.routing-overview > div { min-width:0; display:grid; align-content:start; justify-items:start; gap:6px; }
.routing-overview small,.route-log small { color:var(--subtle); font-size:12px; }
.routing-overview strong { font-size:14px; overflow-wrap:anywhere; }
.routing-note { font-size:14px; line-height:1.55; color:var(--subtle); }
.routing-tabs { display:flex; flex-wrap:wrap; gap:6px; }
.routing-tabs button { border:1px solid var(--line); padding:8px 13px; border-radius:6px; color:var(--subtle); background:white; font-size:13px; font-weight:600; }
.routing-tabs button[aria-pressed=true] { border-color:#84a791; color:var(--accent-dark); background:var(--pale); }
.routing-tabs button span { display:inline-block; min-width:17px; margin-left:3px; padding:1px 4px; background:#fff1cf; color:#72461c; border-radius:4px; }
.route-log, .rules-diff { list-style:none; padding:0 20px; margin:0; }
.route-log li,.rules-diff li { min-width:0; padding:14px 0; border-bottom:1px solid var(--line); overflow-wrap:anywhere; }
.route-log li:last-child,.rules-diff li:last-child { border-bottom:0; }
.route-log-line { display:flex; justify-content:space-between; align-items:start; gap:10px; }
.route-log strong { font-size:14px; }
.route-log small { display:block; margin-top:4px; }
.route-log p { margin-top:5px; font-size:13px; line-height:1.5; }
.rules-diff { max-height:430px; overflow:auto; padding:0; margin:4px 0 15px; }
.rules-diff strong { display:block; font-size:13px; }
.rules-diff li > div { margin-top:8px; }
.rules-diff li span { font-size:12px; color:var(--subtle); }
.rules-diff pre,.rules-json { margin:4px 0; padding:8px; background:var(--page); font-size:12px; line-height:1.5; white-space:pre-wrap; overflow-wrap:anywhere; }
.rules-json { max-height:380px; overflow:auto; }
.route-daily > summary { padding:13px 18px; font-size:14px; font-weight:600; color:var(--ink); }
.route-daily[open] > summary { border-bottom:1px solid var(--line); }
.route-daily textarea { font-family:ui-monospace,Consolas,monospace; }
.mail-results a { display:inline-block; margin-top:7px; font-size:13px; font-weight:600; }
[data-routing-form] > .button { justify-self:start; }
@media (max-width:760px) {
  .nav-more { display:flex; }
  .extra-nav { display:none; }
  .mobile-open .extra-nav { display:grid; position:absolute; right:6px; bottom:calc(100% + 4px); width:min(240px,calc(100vw - 12px)); padding:5px; border-radius:7px; background:var(--nav); box-shadow:0 3px 14px #18352e4d; }
  .extra-nav .nav-link { flex-direction:row; justify-content:flex-start; padding-left:12px; gap:11px; font-size:14px; }
  .extra-nav .nav-short { display:none; }
  .extra-nav .nav-full { display:inline; }
  .routing-overview { grid-template-columns:repeat(2,minmax(0,1fr)); padding:15px; }
  .routing-overview > div:last-child { grid-column:1/-1; }
  #mail-status { grid-row:1; }
  .routing-tabs button { flex:1 1 43%; min-height:42px; }
}
.skill-category {padding:18px 16px 8px;font-size:16px}
.skill-row {display:flex;align-items:baseline;justify-content:space-between;gap:10px;text-align:left;width:100%;padding:10px 16px;border:0;border-bottom:1px solid var(--line);background:transparent;color:inherit;cursor:pointer;overflow-wrap:anywhere}
.skill-row[aria-pressed=true], .skill-row:hover {background:#e8f3ef}
.skill-row span,.skill-choice small,.skill-files small {color:var(--muted);font-size:12px}
.skill-row strong {font-weight:600}
.skill-choices {padding:10px 0;margin:6px 0;border-bottom:1px solid var(--line)}
.skill-choices summary {cursor:pointer;font-weight:600}
.skill-choices .skill-choice {display:flex;flex-direction:row;align-items:baseline;gap:8px;font-weight:400;margin:6px 0}
.skill-choice input {width:auto}
.skill-source {max-height:52vh;overflow:auto;overflow-wrap:anywhere;margin-top:10px;white-space:pre-wrap}
.skill-files {padding:0 0 0 18px;overflow-wrap:anywhere;max-height:36vh;overflow:auto}
.agent-menu { display:grid; grid-template-columns:repeat(auto-fit,minmax(120px,1fr)); gap:6px; margin-bottom:22px; }
.agent-menu a { display:grid; gap:3px; padding:11px 13px; color:var(--ink); background:var(--surface); border:1px solid var(--line); border-radius:7px; text-decoration:none; }
.agent-menu a:hover { background:#f0f5f0; }
.agent-menu a[aria-current=page] { background:var(--pale); border-color:#79a18b; box-shadow:inset 3px 0 var(--accent); }
.agent-menu a strong { font-size:15px; }
.agent-menu a span,.agent-selected small { color:var(--subtle); font-size:12px; }
.agent-layout { grid-template-columns:minmax(0,1.3fr) minmax(0,1fr); }
.agent-compose { display:grid; gap:19px; }
.agent-choices,.agent-selected { display:flex; flex-wrap:wrap; align-items:center; gap:7px; }
.agent-choice { padding:8px 13px; color:var(--subtle); background:var(--surface); border:1px solid var(--line); border-radius:6px; font-size:14px; font-weight:600; }
.agent-choice[aria-pressed=true] { border-color:#79a18b; background:var(--pale); color:var(--accent-dark); }
.agent-source { display:grid; gap:6px; color:var(--ink); font-size:13px; font-weight:600; }
.agent-mail-search { display:flex; align-items:flex-end; gap:8px; }
.agent-mail-search label { flex:1; min-width:0; }
.agent-mail-hits { margin-top:10px; }
.agent-hit-list { overflow:auto; max-height:218px; border:1px solid var(--line); border-radius:6px; }
.agent-hit-list .record { padding:10px 12px; }
.agent-selected { justify-content:space-between; padding:12px; border:1px solid var(--line); border-radius:6px; background:#f6f9f5; }
.agent-selected > div { display:grid; gap:3px; overflow-wrap:anywhere; }
#agent-output h3 { overflow-wrap:anywhere; }
#agent-output .result { margin-top:0; }
@media (max-width:900px) { .agent-layout { grid-template-columns:minmax(0,1fr); } }
@media (max-width:760px) {
  .agent-menu { grid-template-columns:repeat(3,minmax(0,1fr)); gap:5px; margin-bottom:16px; }
  .agent-menu a { padding:8px 9px; }
  .agent-menu a span { font-size:11px; overflow-wrap:anywhere; }
  .agent-choice { min-height:42px; }
}
@media (max-width:365px) { .agent-menu { grid-template-columns:repeat(2,minmax(0,1fr)); } }
.sara-tabs { display:flex; flex-wrap:wrap; gap:0 16px; margin:-4px 0 18px; border-bottom:1px solid var(--line); }
.sara-tabs a { padding:8px 0; color:var(--subtle); text-decoration:none; font-weight:600; }
.sara-tabs a[aria-current=page] { color:var(--accent-dark); border-bottom:3px solid var(--accent); }
.sara-list-actions { margin-top:0; justify-content:space-between; }
.sara-items { list-style:none; padding:0; border-top:1px solid var(--line); }
.sara-items li { border-bottom:1px solid var(--line); }
.sara-item-title { width:100%; display:flex; justify-content:space-between; align-items:center; gap:9px; color:var(--ink); background:transparent; border:0; text-align:left; padding:13px 0; }
.sara-item-title span { display:grid; gap:4px; min-width:0; overflow-wrap:anywhere; }
.sara-item-title small { font-size:12px; color:var(--subtle); }
.sara-item-title[aria-expanded=true] .icon { transform:rotate(90deg); }
.sara-item-body { padding:0 0 17px; }
.sara-task-form,.draft-editor { background:#f7faf6; padding:13px; border:1px solid var(--line); border-radius:7px; }
.sara-snooze { display:flex; flex-wrap:wrap; gap:8px; align-items:flex-end; }
.sara-snooze label { flex:1 1 124px; }
.draft-editor { margin-top:6px; }
.draft-editor a,.draft-editor summary { overflow-wrap:anywhere; }
.draft-editor .route-log { margin-top:8px; padding:0; }
.decision-sara { margin-bottom:18px; }
.decision-sara .record { text-decoration:none; }
.handoff-panel { margin-top:16px; }
.handoff-panel .record { flex-wrap:wrap; }
.handoff-panel .prose { max-height:22rem; overflow:auto; }
.outlook-consent { grid-template-columns:auto minmax(0,1fr); gap:8px; align-items:start; }
.outlook-consent input[type=checkbox] { width:18px; height:18px; }
.matti-fields { display:grid; gap:4px; overflow-wrap:anywhere; }
.matti-fields dt { color:var(--subtle); font-size:12px; font-weight:600; }
.matti-fields dd { margin:0 0 7px; }
.matti-excerpt { margin:0 0 12px; overflow-wrap:anywhere; }
#matti-desk .record { text-decoration:none; }
#matti-desk .route-log { padding:0; }
#matti-desk :is(h3,p,.section-block,a) { overflow-wrap:anywhere; }
