:root {
    color-scheme: light;
    --canvas: #fff; --surface: #fff; --surface-muted: #f4f6fa; --ink: #101828; --muted: #425168;
    --border: #ced6e2; --soft-border: #e2e7ef; --nav: #fff; --nav-text: #26364e;
    --blue: #2055c7; --blue-deep: #163f9d; --accent-soft: #eaf1ff; --accent-border: #bed0f6;
    --sidebar: 220px; --header: 64px; --corner: 8px;
    --shadow: 0 2px 4px rgb(17 37 71 / 3%);
    --safe-top: env(safe-area-inset-top, 0px);
    --safe-bottom: env(safe-area-inset-bottom, 0px);
    --safe-left: env(safe-area-inset-left, 0px);
    --safe-right: env(safe-area-inset-right, 0px);
    font: 14px/1.58 "Segoe UI", "Microsoft YaHei UI", "Microsoft YaHei", "PingFang SC", sans-serif;
}
*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
[hidden] { display: none !important; }
body { margin: 0; background: var(--canvas); color: var(--ink); }
body.nav-collapsed { --sidebar: 64px; }
h1, h2, h3, p { margin: 0; }
ul, ol { margin: 0; padding: 0; }
button, input, select, textarea { font: inherit; }
button, summary, select { cursor: pointer; }
button:disabled { cursor: default; opacity: .5; }
svg { flex: none; vertical-align: middle; }
a { color: var(--blue-deep); text-decoration: none; }
a:hover { text-decoration: underline; }
:focus-visible { outline: 2px solid var(--blue); outline-offset: 3px; }
input, select, textarea { max-width: 100%; color: var(--ink); }
input:not([type=checkbox]), select, textarea {
    min-height: 38px; padding: 7px 11px; border: 1px solid var(--border); border-radius: 5px; background: var(--surface);
}
input::placeholder, textarea::placeholder { color: #526179; opacity: 1; }
select { padding-right: 22px; }
textarea { resize: vertical; }
input[type=checkbox] { width: 15px; height: 15px; margin: 0; accent-color: var(--blue); }
input[type=file] { width: 100%; }
input[type=file]::file-selector-button { border: 0; padding: 3px 8px; margin-right: 8px; border-radius: 3px; background: var(--accent-soft); color: var(--blue-deep); }
input:focus, textarea:focus, select:focus { border-color: var(--blue); }
.sr-only, .skip-link:not(:focus) {
    position: absolute; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); white-space: nowrap;
}
.skip-link:focus { position: fixed; z-index: 12; top: 8px; left: 8px; border: 1px solid var(--blue); padding: 8px; background: white; }

.sidebar {
    position: fixed; z-index: 4; left: 0; top: 0; bottom: 0; width: var(--sidebar);
    display: flex; flex-direction: column; background: var(--nav); color: var(--nav-text);
    border-right: 1px solid var(--border);
}
.brand {
    height: var(--header); flex: none; display: flex; align-items: center; gap: 10px; padding: 0 17px;
    color: var(--ink); white-space: nowrap;
}
.sidebar-header { display: flex; flex: none; align-items: center; border-bottom: 1px solid var(--soft-border); }
.sidebar-header .brand { flex: 1; min-width: 0; }
#nav-close { display: none; }
.brand:hover { color: var(--blue-deep); text-decoration: none; }
.brand-mark { display: grid; place-items: center; width: 35px; height: 35px; flex: none; border-radius: 8px; color: #fff; background: var(--blue); }
.brand strong, .brand small { display: block; }
.brand strong { font-size: 15px; line-height: 1.3; }
.brand small { font-size: 11px; color: var(--muted); margin-top: 3px; }
.sidebar nav { flex: 1; overflow: auto; padding: 18px 12px 20px; }
.nav-section + .nav-section { margin-top: 21px; }
.nav-label { margin: 0 9px 6px; font-size: 11px; font-weight: 650; color: #4c5b70; letter-spacing: .035em; }
.nav-item {
    display: flex; align-items: center; gap: 11px; min-height: 40px; padding: 7px 10px; margin: 2px 0;
    border: 1px solid transparent; border-radius: 6px; color: var(--nav-text); font-size: 14px; font-weight: 500; white-space: nowrap;
}
.nav-item svg { color: #506078; }
.nav-item:hover { text-decoration: none; background: var(--surface-muted); color: var(--ink); }
.nav-item[aria-current=page] { border-color: var(--accent-border); background: var(--accent-soft); color: var(--blue-deep); font-weight: 700; }
.nav-item[aria-current=page] svg { color: var(--blue); }
.side-footer { padding: 9px 12px; min-height: 52px; border-top: 1px solid var(--soft-border); }
.side-toggle {
    display: flex; align-items: center; gap: 9px; width: 100%; min-height: 36px; padding: 4px 8px;
    border: 0; border-radius: 6px; background: transparent; color: var(--muted); font-size: 12px; white-space: nowrap;
}
.side-toggle:hover { color: var(--blue-deep); background: var(--accent-soft); }
.nav-collapsed .brand { padding-left: 14px; }
.nav-collapsed .brand > :last-child, .nav-collapsed .nav-label, .nav-collapsed .nav-item span, .nav-collapsed .side-toggle span { display: none; }
.nav-collapsed .nav-item { justify-content: center; padding-inline: 0; }
.nav-collapsed .nav-section + .nav-section { padding-top: 8px; margin-top: 8px; border-top: 1px solid var(--soft-border); }
.nav-collapsed .side-toggle { justify-content: center; padding-inline: 0; }
.nav-collapsed .side-toggle svg { rotate: 180deg; }

.topbar {
    position: fixed; z-index: 3; top: 0; left: var(--sidebar); right: 0; min-height: var(--header);
    display: flex; justify-content: space-between; align-items: center; gap: 10px; padding: 0 25px 0 18px;
    background: var(--surface); border-bottom: 1px solid var(--border);
}
.top-start, .breadcrumbs, .identity { display: flex; min-width: 0; align-items: center; gap: 10px; }
.top-start { gap: 16px; }
.breadcrumbs { color: var(--muted); font-size: 13px; }
.breadcrumbs strong { color: var(--ink); font-weight: 650; }
.breadcrumbs svg { color: #667690; }
.icon-button { display: inline-grid; place-items: center; width: 35px; height: 35px; border: 1px solid transparent; border-radius: 6px; background: transparent; color: var(--muted); padding: 0; }
.icon-button:hover { background: var(--surface-muted); border-color: var(--border); }
.account-menu { position: relative; }
.account-menu summary { display: flex; align-items: center; gap: 8px; padding: 4px 6px; list-style: none; border-radius: 6px; }
.account-menu summary:hover { background: var(--surface-muted); }
.avatar { display: grid; place-items: center; width: 31px; height: 31px; background: var(--accent-soft); color: var(--blue-deep); font-weight: 700; border-radius: 50%; }
.account-name { color: var(--ink); font-size: 13px; font-weight: 650; white-space: nowrap; }
.account-popover { position: absolute; right: 0; top: 43px; width: 192px; display: grid; gap: 7px; padding: 13px; background: var(--surface); border: 1px solid var(--border); border-radius: var(--corner); box-shadow: 0 10px 25px #15264c24; }
.account-popover .button { justify-content: flex-start; }
.notification-menu { position: relative; }
.notification-toggle { position: relative; color: var(--nav-text); }
.notification-toggle[aria-expanded=true] { color: var(--blue-deep); background: var(--accent-soft); }
.notification-count {
    position: absolute; right: -4px; top: -3px; display: grid; place-items: center; border-radius: 99px;
    min-width: 19px; height: 19px; padding: 0 4px; border: 2px solid white; background: #c51e35; color: white;
    font-size: 10px; font-weight: 750; line-height: 1; font-variant-numeric: tabular-nums;
}
.notification-popover {
    position: absolute; top: calc(100% + 9px); right: 0; width: 310px; max-height: min(440px, 75dvh); overflow: auto;
    border: 1px solid var(--border); border-radius: var(--corner); background: white; box-shadow: 0 10px 28px #15264c24;
}
.notification-popover h2 { padding: 12px 15px; font-size: 15px; border-bottom: 1px solid var(--soft-border); }
.notification-list > .meta, .notification-list > .button { margin: 12px 15px; }
.notification-item { display: grid; gap: 2px; padding: 9px 15px; color: var(--ink); overflow-wrap: anywhere; }
.notification-item + .notification-item { border-top: 1px solid var(--soft-border); }
.notification-item:hover { text-decoration: none; background: var(--accent-soft); }
.notification-item small { color: var(--muted); }
.notification-footer { display: flex; align-items: center; gap: 7px; padding: 10px 15px; border-top: 1px solid var(--border); }
.scrim { display: none; }

#view:focus { outline: none; }
.authenticated #view { margin-left: var(--sidebar); padding-top: calc(var(--header) + var(--safe-top)); }
.page { width: min(100%, 1540px); margin-inline: auto; padding: 30px clamp(22px, 3vw, 47px) 46px; display: grid; grid-template-columns: minmax(0, 1fr); align-content: start; gap: 20px; }
.page-heading { display: flex; align-items: center; justify-content: space-between; gap: 12px 18px; }
.page-heading h1 { color: var(--ink); font-size: clamp(27px, 2.6vw, 36px); font-weight: 740; line-height: 1.22; letter-spacing: -.035em; overflow-wrap: anywhere; }
.page-heading .meta { margin-top: 6px; font-size: 14px; }
.heading-actions, .row, .badges { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }
.heading-actions { justify-content: flex-end; flex: none; }
.heading-actions:empty { display: none; }
.button {
    display: inline-flex; align-items: center; justify-content: center; gap: 7px; min-height: 38px;
    padding: 6px 12px; border: 1px solid var(--border); border-radius: 5px; background: var(--surface); color: var(--nav-text);
    font-size: 13px; font-weight: 600; white-space: nowrap; text-decoration: none;
}
.button:hover:not(:disabled) { background: var(--surface-muted); border-color: var(--accent-border); text-decoration: none; }
.button.primary { background: var(--blue); border-color: var(--blue); color: #fff; }
.button.primary:hover:not(:disabled) { background: var(--blue-deep); border-color: var(--blue-deep); }
.button.danger { color: #a42b36; }
.button.text-button { background: transparent; border-color: transparent; min-height: 28px; color: var(--blue-deep); padding: 2px 4px; }
.button.text-button.danger { color: #a42b36; }
.button.confirm-delete { color: white; background: #a42b36; border-color: #a42b36; }
.model-field-pair { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; }
.model-key { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 8px; align-items: end; }
.text-link { display: inline-flex; align-items: center; gap: 7px; font-size: 12.5px; font-weight: 650; white-space: nowrap; }
.entity-link { color: var(--blue-deep); font-weight: 650; }
.meta, .small { color: var(--muted); font-size: 12.5px; line-height: 1.5; overflow-wrap: anywhere; }

.tone-slate { --tone: #4f6078; --tint: #eef1f7; --tint-border: #d9e2ee; }
.tone-blue { --tone: #2055bb; --tint: #eaf1ff; --tint-border: #ccddfb; }
.tone-teal { --tone: #087465; --tint: #e6f5f1; --tint-border: #bee4da; }
.tone-amber { --tone: #8c560b; --tint: #fff3dc; --tint-border: #f2dbac; }
.tone-violet { --tone: #6245a8; --tint: #f1ecfc; --tint-border: #e2d8f8; }
.tone-orange { --tone: #a5531f; --tint: #fdf0e6; --tint-border: #f2d7c2; }
.tone-green { --tone: #1b6c40; --tint: #e9f7ed; --tint-border: #c5e8cd; }
.tone-red { --tone: #a32e45; --tint: #fceef1; --tint-border: #f2cdd6; }
.badge, .tag {
    display: inline-flex; align-items: center; max-width: 100%; min-height: 20px; border: 1px solid var(--tint-border, #d6e0f0);
    border-radius: 4px; padding: 2px 6px; background: var(--tint, #eef2f8); color: var(--tone, #30445e);
    font-size: 11.5px; font-weight: 650; white-space: nowrap; line-height: 1.35;
}
.metrics { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 12px; }
.metrics.three { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.metric { display: flex; align-items: flex-start; gap: 12px; min-width: 0; min-height: 93px; background: #fff; border: 1px solid var(--border); border-radius: 4px; box-shadow: var(--shadow); padding: 13px 16px; }
.metric-icon, .sector-icon, .panel-head-icon {
    display: inline-grid; place-items: center; flex: none; width: 35px; height: 35px; border: 1px solid var(--tint-border);
    border-radius: 4px; background: var(--tint); color: var(--tone);
}
.metric-label { display: block; font-size: 12px; font-weight: 650; color: #4c607c; }
.metric strong { display: block; font-size: 24px; line-height: 1.2; font-variant-numeric: tabular-nums; margin-block: 2px; overflow-wrap: anywhere; }
.metric small { color: var(--muted); font-size: 11px; }
.panel { min-width: 0; background: var(--surface); border: 1px solid var(--border); border-radius: var(--corner); box-shadow: var(--shadow); }
.panel-head { display: flex; align-items: center; justify-content: space-between; gap: 12px; min-height: 58px; padding: 13px 19px; border-bottom: 1px solid var(--soft-border); }
.panel-head h2, .editor-body h2 { font-size: 17px; line-height: 1.35; font-weight: 700; }
.panel-head .meta { margin-top: 4px; font-size: 12px; }
.panel-head-icon { width: 30px; height: 30px; }
.panel-foot { border-top: 1px solid var(--soft-border); padding: 12px 16px; }
.stack { display: grid; align-content: start; gap: 13px; min-width: 0; }
.padded { padding: 15px 16px; }
.padded > p + a { margin-top: 8px; display: inline-block; }
.preserve { white-space: pre-wrap; overflow-wrap: anywhere; }
.empty { min-height: 106px; display: grid; justify-items: center; align-content: center; gap: 6px; padding: 18px 12px; color: #59708d; text-align: center; }
.empty strong { color: #3f536e; font-weight: 600; }
.loading { color: var(--muted); padding: 34px 26px; }

.map-page { gap: 22px; }
.map-page .page-heading h1 { font-size: clamp(30px, 3vw, 40px); }
.product-line-deck {
    min-width: 0; overflow: hidden; padding: 14px 14px 11px;
    border: 1px solid var(--border); border-radius: var(--corner); background: var(--surface);
}
.product-line-deck h2 { padding: 0 8px; font-size: 12px; font-weight: 680; color: var(--muted); }
.product-line-rail {
    display: flex; gap: 5px; padding: 8px 1px 2px; min-width: 0; overflow-x: auto;
    scrollbar-width: thin; scrollbar-color: #afbfd6 transparent;
}
.product-line-tab {
    display: flex; flex: 1 0 90px; flex-direction: column; justify-content: center; align-items: flex-start; gap: 8px;
    min-width: 0; min-height: 80px; padding: 9px 10px; border: 1px solid transparent; border-radius: 6px;
    background: var(--surface); color: var(--nav-text); text-align: start; white-space: nowrap;
}
.product-line-tab:hover { background: var(--surface-muted); }
.product-line-tab[aria-pressed="true"] {
    flex-grow: 1.45; flex-basis: 117px; border-color: var(--accent-border); background: var(--accent-soft); color: var(--blue-deep);
}
.product-line-tab:focus-visible { outline-offset: -3px; }
.line-top { display: flex; align-items: center; justify-content: space-between; gap: 6px; width: 100%; }
.line-count { font-size: 13px; font-variant-numeric: tabular-nums; color: var(--muted); }
.ledger .button.need-excerpt { display: block; max-width: clamp(12ch, 26vw, 56ch); padding-inline: 0;
    white-space: nowrap; overflow: hidden; text-overflow: ellipsis; text-align: start; font-weight: 600; }
.need-evidence { margin: 0; padding: 9px 12px; border-left: 3px solid var(--accent-border); background: var(--surface-muted); }
.deletion-choices { display: grid; gap: 12px; }
.deletion-choices label { display: flex; gap: 9px; align-items: flex-start; cursor: pointer; }
.deletion-choices input[type=radio] { width: 16px; height: 16px; min-height: 0; margin: 3px 0; flex: none; accent-color: var(--blue); }
.deletion-choices label:has(input:disabled) { color: var(--muted); cursor: default; }
.line-symbol {
    display: grid; place-items: center; flex: none; width: 31px; height: 31px; border-radius: 6px;
    background: #f1f4f9; color: #435571;
}
.product-line-tab[aria-pressed="true"] .line-symbol { color: #fff; background: var(--blue); }
.line-label { font-size: 14px; font-weight: 660; }
.product-line-tab[aria-pressed="true"] .line-label { font-size: 15.5px; font-weight: 750; }
.table-panel.progress-board { overflow: visible; }
.progress-board .table-toolbar { display: block; padding: 0; }
.progress-toolbar { min-width: 0; }
.board-top { display: flex; justify-content: space-between; align-items: center; gap: 16px; padding: 17px 20px; }
.board-title { display: flex; gap: 10px; align-items: center; flex-wrap: wrap; }
.board-title h2 { font-size: 19px; }
.board-line { padding: 3px 8px; border-radius: 4px; background: var(--accent-soft); color: var(--blue-deep); white-space: nowrap; font-size: 12px; font-weight: 650; }
.board-stats { display: flex; gap: 15px; margin: 0; }
.board-stats > div { padding-inline-start: 14px; border-inline-start: 1px solid var(--border); }
.board-stats dt { color: var(--muted); white-space: nowrap; font-size: 11.5px; }
.board-stats dd { margin: 1px 0 0; color: var(--muted); font-size: 12px; white-space: nowrap; }
.board-stats strong { color: var(--ink); font-size: 23px; line-height: 1; font-variant-numeric: tabular-nums; }
.map-filters {
    display: flex; align-items: center; flex-wrap: wrap; gap: 8px; padding: 11px 20px;
    border-top: 1px solid var(--soft-border);
}
.map-filters .searchbox { flex: 1 1 235px; min-width: 0; max-width: 380px; }
.map-filters > select { width: 126px; max-width: 100%; }
.map-more-filters { position: relative; z-index: 2; }
.map-more-filters summary { list-style: none; }
.map-more-filters summary::-webkit-details-marker { display: none; }
.map-more-filters[open] > summary { border-color: var(--accent-border); background: var(--accent-soft); color: var(--blue-deep); }
.map-filter-popover {
    position: absolute; inset: calc(100% + 7px) auto auto 0; z-index: 2; display: grid; gap: 10px;
    min-width: 250px; padding: 12px; border: 1px solid var(--border); border-radius: var(--corner);
    background: var(--surface); box-shadow: 0 12px 28px rgb(18 37 72 / 13%);
}
.filter-count { padding: 0 4px; border-radius: 3px; background: var(--accent-soft); color: var(--blue-deep); font-size: 11px; }
.board-company-mark {
    display: grid; place-items: center; flex: none; width: 32px; height: 32px; border-radius: 6px;
    color: var(--blue-deep); background: var(--accent-soft); font-size: 13px; font-weight: 720;
}
.board-project-link { color: var(--blue-deep); font-weight: 650; }
.progress-date { display: inline-flex; align-items: center; gap: 5px; color: #665a3f; font-size: 12px; }
.progress-date svg { color: #92794b; }
.progress-board .table-scroll:last-child { border-radius: 0 0 var(--corner) var(--corner); }
.milestones { padding: 0 15px; }
.milestone { display: grid; gap: 4px; padding: 10px 0; border-bottom: 1px solid var(--soft-border); }
.milestone:last-child { border-bottom: 0; }
.milestone-time { display: flex; gap: 5px; flex-wrap: wrap; align-items: center; }
.milestone-time strong { font-size: 12px; color: #283f62; overflow-wrap: anywhere; }
.milestone-body { font-size: 12.5px; color: #1a3054; font-weight: 650; overflow-wrap: anywhere; }

.table-panel { overflow: hidden; }
.mobile-table-tools, .mobile-cell-label, .section-shortcuts { display: none; }
.table-toolbar { display: flex; align-items: center; flex-wrap: wrap; gap: 8px; padding: 13px 16px; border-bottom: 1px solid var(--soft-border); }
.filters, .table-footer { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }
.filters { width: 100%; }
.searchbox { position: relative; display: inline-flex; align-items: center; width: 226px; max-width: 100%; }
.searchbox svg { position: absolute; left: 10px; pointer-events: none; color: #506078; }
.searchbox input { min-width: 0; width: 100%; padding-left: 33px; }
.push { margin-left: auto; }
.table-scroll { width: 100%; overflow: auto; }
.table-scroll:focus-visible { outline-offset: -2px; }
.table-scroll[aria-busy=true] .data-table tbody { opacity: .62; }
.data-table { width: 100%; border-collapse: collapse; text-align: left; font-size: 13.5px; }
.data-table thead { background: #f1f4f9; }
.data-table td, .data-table th { padding: 12px 13px; border-bottom: 1px solid var(--soft-border); vertical-align: middle; }
.data-table th { min-width: max-content; color: #30415a; font-size: 12px; font-weight: 690; white-space: nowrap; }
.data-table th[aria-sort] { color: var(--blue-deep); }
.data-table tbody tr:hover { background: #f7f9fe; }
.data-table tbody tr.selected { background: var(--accent-soft); }
.data-table tbody tr:last-child td, .data-table tbody tr:last-child th { border-bottom: none; }
.data-table .check-cell { width: 39px; padding-inline: 12px; }
.data-table .check-cell input { display: block; }
.data-table .nowrap { white-space: nowrap; }
.data-table .table-empty { padding: 2px 12px; }
.data-table .row { flex-wrap: nowrap; }
.ledger { border-collapse: separate; border-spacing: 0; }
.ledger th, .ledger td { white-space: nowrap; padding: 10px 13px; }
.ledger td { height: 46px; }
.ledger .progress-status { flex-wrap: nowrap; }
.ledger tr > :first-child:not([colspan]) { position: sticky; left: 0; z-index: 1; background: white; box-shadow: 1px 0 var(--soft-border); }
.ledger thead tr > :first-child:not([colspan]) { background: #f1f4f9; }
.ledger tbody tr:hover > :first-child { background: #f7f9fe; }
.ledger-excerpt, .ledger .entity-link, .ledger .board-project-link, .ledger .progress-project {
    display: block; max-width: 22ch; overflow: hidden; text-overflow: ellipsis; white-space: nowrap;
}
.ledger-excerpt { max-width: clamp(16ch, 14vw, 35ch); }
.ledger .progress-project {
    padding: 0; border: 0; background: transparent; color: var(--blue-deep); font: inherit; font-weight: 650; text-align: start;
}
.ledger .progress-project:hover { text-decoration: underline; }
.table-toolbar:has(> .panel-head) { display: block; padding: 0; }
.table-toolbar > .panel-head { border-bottom: 0; }
.table-sort { display: inline-flex; align-items: center; gap: 6px; border: 0; background: transparent; padding: 0; color: inherit; font-weight: inherit; }
.table-sort svg { color: #526580; }
.data-table [aria-sort] svg { color: var(--blue-deep); }
.data-table .width-column, .brief-products .width-column { border-inline-end: 1px solid #cad3e1; }
thead th.width-column { position: relative; min-width: 72px; }
.ledger tr > .width-column:first-child { box-shadow: none; }
.column-grip {
    position: absolute; z-index: 2; inset-block: 0; inset-inline-end: 0; width: 9px;
    cursor: col-resize; touch-action: none; user-select: none;
}
.column-grip::after {
    content: ""; position: absolute; inset-block: 0; inset-inline-end: 0; width: 3px;
}
.column-grip:hover::after, .column-grip:focus-visible::after, .resizing-column .column-grip:focus::after { background: var(--blue); }
.column-grip:focus-visible { outline-offset: -2px; }
.resizing-column { cursor: col-resize; user-select: none; }
@media (pointer: coarse) {
    .column-grip { width: 16px; }
}
table.custom-column-widths { width: var(--table-width); min-width: 0; table-layout: fixed; }
.custom-column-widths thead th { min-width: 0; }
.custom-column-widths thead th.width-column { overflow: hidden; text-overflow: ellipsis; }
.custom-column-widths.information-table tbody th.width-column { white-space: normal; }
.custom-column-widths .table-sort { max-width: 100%; }
.custom-column-widths .table-sort span { overflow: hidden; text-overflow: ellipsis; }
.custom-column-widths .cell-summary { min-width: 0; }
.custom-column-widths .width-column { overflow-wrap: anywhere; }
.custom-column-widths.ledger .cell-content, .custom-column-widths .nowrap .cell-content { overflow: hidden; text-overflow: ellipsis; }
.custom-column-widths.ledger :is(.ledger-excerpt, .entity-link, .board-project-link, .progress-project) { max-width: 100%; }
.custom-column-widths .card-actions .row { flex-wrap: wrap; }
.custom-column-widths.wide-first-column.ledger tr > :first-child { position: relative; }
.cell-summary { display: -webkit-box; -webkit-box-orient: vertical; -webkit-line-clamp: 2; overflow: hidden; min-width: 150px; overflow-wrap: anywhere; }
.table-footer { min-height: 55px; justify-content: space-between; border-top: 1px solid var(--soft-border); padding: 9px 13px; }
.table-footer .button, .table-footer select { min-height: 31px; padding-block: 4px; font-size: 12px; }
.table-count { font-size: 12px; color: var(--muted); }
.dense .data-table td, .dense .data-table th { padding-block: 6px; }

.customer-facts { display: grid; grid-template-columns: repeat(3,minmax(0,1fr)); gap: 12px; padding: 15px 16px; }
.customer-facts > div + div { padding-left: 14px; border-left: 1px solid var(--soft-border); }
.customer-facts .meta { margin-bottom: 4px; }
.detail-layout, .review-layout { display: grid; grid-template-columns: minmax(0, 1fr) minmax(260px, .39fr); gap: 14px; align-items: start; }
.review-layout { grid-template-columns: minmax(0, 1fr) minmax(270px, .54fr); }
.draft-layout { grid-template-areas: "review materials"; }
#draft-review { grid-area: review; }
.draft-materials { grid-area: materials; }
.timeline { list-style: none; padding: 16px; }
.timeline-row { display: grid; grid-template-columns: 110px 19px minmax(0, 1fr); position: relative; }
.timeline-date { display: grid; align-content: start; gap: 3px; padding-top: 9px; }
.timeline-date strong { color: #243a61; font-size: 13px; font-variant-numeric: tabular-nums; }
.timeline-date span { color: var(--muted); font-size: 11px; }
.timeline-marker { position: relative; }
.timeline-marker::before { content: ""; position: absolute; top: 13px; left: 4px; width: 8px; height: 8px; border: 2px solid white; border-radius: 50%; background: #2a65db; outline: 1px solid #4679dd; z-index: 1; }
.timeline-row:not(:last-child) .timeline-marker::after { position: absolute; inset: 16px auto -16px 7px; width: 2px; content: ""; background: #dce7fb; }
.timeline-card { display: grid; gap: 9px; margin-bottom: 14px; padding: 10px 13px; border: 1px solid #dce5f2; border-radius: 3px; }
.timeline-row:last-child .timeline-card { margin-bottom: 0; }
.timeline-card-head { display: flex; align-items: center; justify-content: space-between; gap: 5px; }
.timeline-dates { background: #f2f7ff; border-left: 2px solid #5184ef; padding: 6px 9px; display: grid; gap: 4px; font-size: 12px; }
.timeline-dates div { display: flex; gap: 6px; align-items: baseline; flex-wrap: wrap; }
.timeline-dates strong, .timeline-dates svg { color: #2359ad; }
.timeline-dates span { overflow-wrap: anywhere; }
.callout { display: flex; gap: 12px; align-items: center; padding: 13px 16px; background: #f7faff; }
.callout .button { margin-left: auto; }
.editor-body, .form-stack { display: grid; min-width: 0; gap: 12px; align-content: start; }
.editor-body { padding: 15px 16px; }
.editor-body > .button { justify-self: start; }
.editor-body > div:has(> .field) { display: grid; gap: 8px; }
.editor-body .row:has(> input) { display: flex; }
.editor-body .row > input:not([type=checkbox]) { flex: 1; min-width: 150px; }
.field { display: grid; align-content: start; gap: 5px; width: 100%; color: #314866; font-size: 12.5px; font-weight: 650; }
.field input, .field select, .field textarea { width: 100%; font-weight: 400; }
.form-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
fieldset { margin: 0; padding: 9px 10px; border: 1px solid var(--border); min-width: 0; }
legend { padding: 0 5px; font-size: 12.5px; color: #314866; font-weight: 650; }
.check-options, .check-options label { display: flex; align-items: center; flex-wrap: wrap; gap: 8px; }
.check-options { gap: 10px 15px; }
.editor-footer { position: sticky; z-index: 2; bottom: 0; padding: 11px 16px; background: #fff; border-top: 1px solid var(--border); justify-content: flex-end; }
.source-group, .editor-body details, .padded details { min-width: 0; border: 1px solid #dce5f2; background: #fff; border-radius: 3px; padding: 8px 10px; }
.padded details + details { margin-top: 7px; }
.source-group summary, .editor-body details summary, .padded details summary { color: #2f4e80; font-weight: 650; overflow-wrap: anywhere; }
.review-editor { gap: 9px; padding: 12px 14px; }
.review-editor .field { gap: 3px; }
.progress-status { white-space: nowrap; }
.progress-status .badge { padding: 4px 7px; border: 0; }
.progress-status .badge::before {
    content: ""; display: inline-block; width: 5px; height: 5px; margin-inline-end: 5px; border-radius: 50%; background: currentColor;
}
.customer-heading { display: grid; gap: 14px; }
.brief-workspace { min-width: 0; container: customer-brief / inline-size; }
.brief-heading, .brief-controls, .brief-section-title, .brief-status, .brief-source, .brief-schedule, .brief-stage {
    display: flex; align-items: center;
}
.brief-heading { flex-wrap: wrap; justify-content: space-between; gap: 10px 18px; margin: 0 0 14px; padding: 14px 19px; background: #193858; border-radius: 4px; }
.brief-heading h2 { margin: 0; font-size: 21px; line-height: 1.35; font-weight: 720; color: white; }
.brief-heading .button { background: #fff; color: #183c71; border-color: #d5e4fa; }
.brief-heading .button:hover:not(:disabled) { background: #e9f1ff; color: #102e52; }
.brief-heading .text-link { color: white; }
.brief-controls { flex-wrap: wrap; gap: 10px; }
.brief-status { margin: 5px 0 0; gap: 4px 10px; flex-wrap: wrap; color: #e0e9f5; font-size: 12px; }
.brief-status > span + span { border-inline-start: 1px solid #cbd4e1; padding-inline-start: 10px; line-height: 1.1; }
.brief-mode { display: inline-flex; align-items: center; gap: 6px; }
.brief-mode::before { content: ""; width: 6px; height: 6px; background: #9cc5ff; border-radius: 50%; }
.brief-error { color: #ffc6ba; }
.brief-body, .brief-primary { display: grid; align-content: start; gap: 18px; min-width: 0; }
.brief-columns { display: grid; align-items: start; gap: 18px; min-width: 0; }
.brief-columns.split { grid-template-columns: minmax(0,1.86fr) minmax(270px,1fr); }
.brief-section-title { gap: 8px; margin: 0; color: #172f50; font-size: 16px; font-weight: 700; }
.brief-section-title svg { color: #496c9e; }
.brief-intent { min-width: 0; padding: 16px 19px; border-inline-start: 4px solid #285aca; background: #eef4ff; }
.brief-intent h3 { margin-bottom: 7px; font-size: 13px; font-weight: 700; color: #234c9b; }
.brief-point { min-width: 0; color: #25354b; }
.brief-point-text { margin: 0; line-height: 1.6; overflow-wrap: anywhere; }
.brief-intent .brief-point-text { color: #203850; font-size: 15px; line-height: 1.6; }
.brief-intent .brief-point:first-child .brief-point-text { font-size: 17px; font-weight: 650; color: #102e52; }
.brief-source { flex-wrap: wrap; gap: 4px 12px; margin-top: 6px; font-size: 12px; color: #4b6079; }
.brief-source details { min-width: 0; }
.brief-source details[open] { flex-basis: 100%; }
.brief-source summary, .brief-meeting-link, .brief-time-note { display: inline-flex; align-items: center; gap: 4px; }
.brief-source summary { color: #486384; list-style: none; cursor: pointer; }
.brief-source summary::-webkit-details-marker { display: none; }
.brief-source details[open] summary svg { transform: rotate(180deg); }
.brief-meeting-link { color: #4b6079; font-variant-numeric: tabular-nums; }
.brief-meeting-link:hover, .brief-source summary:hover { color: var(--blue-deep); text-decoration: underline; }
.brief-evidence { margin: 7px 0 2px; border-inline-start: 2px solid #97b2d7; padding: 5px 10px; background: #f7f9fc; }
.brief-evidence blockquote { margin: 0; white-space: pre-wrap; overflow-wrap: anywhere; }
.brief-evidence a { margin-top: 4px; }
.brief-time-note { color: #315589; }
.brief-point + .brief-point { margin-top: 11px; }
.brief-product-context, .brief-topic { color: #526581; font-size: 12px; overflow-wrap: anywhere; }
.brief-comparison, .brief-followup { min-width: 0; border: 1px solid var(--border); border-radius: 5px; background: white; }
.brief-comparison h3 { padding: 11px 15px; color: #124f53; background: #e1f2ef; border-top: 3px solid #24837c; border-radius: 4px 4px 0 0; }
.brief-comparison h3 svg { color: #14675f; }
.brief-claims { margin: 0; padding-inline-start: 1.05em; }
.brief-claims li::marker { color: #25756e; }
.brief-claims li + li { margin-block-start: 9px; }
.brief-unassigned { padding: 10px 14px; border-top: 1px solid var(--border); }
.brief-unassigned h4 { margin: 0 0 8px; }
.brief-unassigned strong { font-size: 13px; }
.brief-unassigned .brief-claims { margin-block: 4px 9px; }
.brief-table-wrap { overflow: auto; border-radius: 0 0 4px 4px; }
.brief-products { width: 100%; min-width: 500px; table-layout: fixed; border-collapse: collapse; }
.brief-products th, .brief-products td { padding: 12px 14px; text-align: left; vertical-align: top; border-top: 1px solid var(--soft-border); overflow-wrap: anywhere; }
.brief-products thead { background: #f1f5fa; }
.brief-products thead th { padding-block: 8px; font-size: 12px; font-weight: 650; color: #3e536d; }
.brief-products thead th:first-child { width: 23%; }
.brief-products tbody th { font-size: 14px; font-weight: 650; color: #173456; }
.brief-products .brief-point-text { font-size: 14px; }
.brief-stage { flex-wrap: wrap; gap: 4px 7px; font-size: 12px; color: #38516c; }
.brief-stage + p { margin-top: 5px; }
.brief-unstated { margin: 0; color: #586a80; font-size: 13px; }
.brief-followup > section { padding: 14px 17px; }
.brief-followup .brief-section-title { border-inline-start: 3px solid var(--section-accent); padding-inline-start: 8px; color: var(--section-ink); }
.brief-followup .brief-section-title svg { color: var(--section-ink); }
.brief-actions { --section-accent: #4c73c1; --section-ink: #234780; }
.brief-timing { --section-accent: #cc8b21; --section-ink: #74490c; background: #fffaf0; }
.brief-budget { --section-accent: #9975b1; --section-ink: #654679; background: #faf7fc; }
.brief-followup > section + section { border-top: 1px solid var(--soft-border); }
.brief-followup .brief-points { margin-top: 12px; }
.brief-actions .brief-points { padding-inline-start: 4px; }
.brief-actions .brief-point { position: relative; padding: 0 0 14px 16px; border-inline-start: 1px solid #b7c9e4; }
.brief-actions .brief-point::before { content: ""; position: absolute; inset: 7px auto auto -4px; width: 7px; height: 7px; border-radius: 50%; background: #3a69bb; }
.brief-actions .brief-point:last-child { padding-bottom: 0; border-color: transparent; }
.brief-actions .brief-point + .brief-point { margin: 0; }
.brief-schedule { flex-wrap: wrap; align-items: baseline; gap: 8px; font-size: 12px; color: #516680; }
.brief-schedule strong { font-size: 15px; font-weight: 700; color: #244b89; }
.brief-schedule + .brief-point-text, .brief-product-context + .brief-point-text { margin-top: 2px; }
.quiet-budget { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: center; gap: 5px 12px; }
.quiet-budget h3 { font-size: 14px; }
.brief-history, .brief-undated, .brief-empty { padding: 14px 17px; border: 1px solid var(--border); border-radius: 4px; overflow-wrap: anywhere; }
.brief-history h3, .brief-undated h3 { margin-bottom: 7px; }
.brief-undated > div + div { margin-top: 10px; }
.brief-empty { color: var(--muted); margin: 0; }
@container customer-brief (max-width: 850px) {
    .brief-columns.split { grid-template-columns: minmax(0,1fr); }
    .brief-body, .brief-primary, .brief-columns { gap: 14px; }
}
@container customer-brief (max-width: 500px) {
    .brief-heading h2 { font-size: 19px; }
    .brief-heading { align-items: flex-start; margin-bottom: 12px; }
    .brief-intent, .brief-followup > section { padding: 13px 14px; }
    .brief-comparison h3 { padding: 11px 13px; }
    .brief-products { min-width: 100%; }
    .brief-products th, .brief-products td { padding-inline: 8px; }
    .brief-source summary, .brief-meeting-link { min-height: 28px; }
}
.customer-heading > a { justify-self: start; }
.customer-heading-identity { display: flex; gap: 14px; align-items: center; min-width: 0; }
.customer-heading-identity > div { min-width: 0; }
.customer-heading-identity .row { margin-top: 6px; }
.customer-heading-identity .meta { margin: 0; }
.customer-mark {
    display: grid; place-items: center; flex: none; width: 57px; height: 57px; border-radius: 11px;
    color: var(--blue-deep); background: var(--accent-soft); border: 1px solid var(--accent-border); font-size: 25px; font-weight: 760;
}
.customer-tabs { display: flex; flex-wrap: wrap; gap: 13px; border-bottom: 1px solid var(--border); }
.customer-tabs button {
    display: inline-flex; align-items: center; gap: 7px; min-height: 44px; padding: 5px 7px;
    border: 0; border-bottom: 2px solid transparent; background: transparent; color: var(--muted);
}
.customer-tabs button:hover { color: var(--blue-deep); }
.customer-tabs button[aria-pressed="true"] { border-bottom-color: var(--blue); color: var(--blue-deep); font-weight: 700; }
.tab-count { min-width: 21px; padding: 1px 5px; border-radius: 4px; background: #edf1f7; font-size: 11px; line-height: 1.6; }
.customer-tabs [aria-pressed="true"] .tab-count { background: #dce8ff; }
.progress-products { padding: 8px 10px; border: 1px solid var(--border); border-radius: 5px; }
.progress-products summary { color: var(--blue-deep); }
.progress-product-choices { display: grid; gap: 4px; margin-top: 7px; max-height: 165px; overflow: auto; }
.progress-product-choices label { gap: 7px; padding-block: 3px; }
.progress-drawer-body { display: grid; gap: 20px; min-width: 0; }
.progress-drawer-identity { display: flex; align-items: center; flex-wrap: wrap; gap: 10px; }
.progress-drawer-title { display: flex; align-items: center; flex: 1; gap: 8px; min-width: min(160px, 100%); }
.progress-drawer-identity > .badges { gap: 5px; }
.stage-editor { display: grid; gap: 8px; }
.stage-editor-heading { display: flex; align-items: center; gap: 8px; min-height: 28px; }
.stage-editor-heading h3 { flex: 1; font-size: 15px; }
.stage-editor-heading [role="status"] { color: var(--muted); font-size: 12px; }
.drawer-stage-evidence:empty { display: none; }
.stage-editor .text-button { min-height: 24px; padding: 1px 4px; }
.stage-inline-select { width: auto; max-width: 100%; }
.progress-steps {
    position: relative; display: grid; grid-template-columns: repeat(var(--stage-count), minmax(0,1fr));
    list-style: none; margin: 0; padding: 4px; border: 1px solid var(--soft-border); border-radius: 6px; background: var(--surface-muted);
}
.progress-steps::before { content: ""; position: absolute; inset: 24px calc(50% / var(--stage-count)) auto; height: 1px; background: #cedaed; }
.progress-steps li { min-width: 0; isolation: isolate; }
.phase-choice {
    display: grid; align-content: start; justify-items: center; width: 100%; height: 100%; gap: 7px; padding: 12px 2px 8px;
    background: transparent; border: 0; color: var(--muted); font: inherit; font-size: 12px; text-align: center; cursor: pointer;
}
.phase-choice:enabled:hover { color: var(--blue-deep); background: #e7efff; }
.phase-choice:disabled { cursor: default; opacity: 1; }
.phase-choice:focus-visible { outline: 2px solid var(--blue); outline-offset: -2px; }
.progress-steps .phase-dot {
    display: grid; place-items: center; width: 17px; height: 17px; border: 1px solid #aebed6; border-radius: 50%;
    color: var(--blue-deep); background: var(--surface);
}
/* Completed, current and upcoming stages remain distinct even without hover. */
.progress-steps .past { position: relative; }
.progress-steps .past .phase-choice { color: #087443; font-weight: 650; }
.progress-steps .past .phase-choice:enabled:hover { background: #e8f8ef; color: #065c36; }
.progress-steps .past .phase-dot { border-color: #11844d; background: #11844d; color: white; }
.progress-steps .past .phase-dot:empty::after { content: "✓"; font-size: 11px; line-height: 1; }
.progress-steps .phase-dot svg { width: 85%; height: 85%; }
.progress-steps .past::before {
    content: ""; position: absolute; z-index: -1; pointer-events: none;
    top: 20px; left: 50%; width: 100%; height: 2px; background: #15965a;
}
.work-meter-track i.filled:has(+ .filled), .stage-mini-scale i.reached:has(+ .reached) { background: #15965a; }
@media (max-width: 550px) { .progress-steps .past::before { display: none; } }
@container account (max-width: 600px) { .account-stages .past::before { display: none; } }
.progress-steps [aria-pressed="true"] { color: var(--blue-deep); font-weight: 750; }
.progress-steps [aria-pressed="true"] .phase-dot { border: 5px solid var(--blue); }
@media (max-width: 550px) {
    .progress-steps { grid-template-columns: repeat(3, minmax(0,1fr)); gap: 3px; }
    .progress-steps::before { display: none; }
    .phase-choice { grid-auto-flow: column; align-items: center; justify-content: center; align-content: center; min-height: 44px; padding: 4px; }
    .phase-choice .phase-dot { width: 12px; height: 12px; }
}
.drawer-summary { display: grid; gap: 5px; justify-items: start; }
.drawer-summary h3, .drawer-next h3, .progress-meeting-list h3 { font-size: 15px; font-weight: 710; }
.drawer-next {
    display: flex; align-items: flex-start; gap: 10px; min-width: 0; padding: 12px 13px;
    border: 1px solid var(--accent-border); border-radius: 6px; background: #f4f7ff;
}
.drawer-next > div { display: grid; gap: 3px; min-width: 0; }
.drawer-next .line-symbol { background: #e2ebff; color: var(--blue-deep); }
.progress-facts { display: grid; grid-template-columns: 1.25fr .75fr; gap: 10px 15px; padding-block: 0 12px; border-bottom: 1px solid var(--soft-border); margin: 0; }
.progress-facts > div { display: grid; align-content: start; gap: 4px; min-width: 0; }
.progress-facts dt { color: var(--muted); font-size: 12px; }
.progress-facts dd { margin: 0; overflow-wrap: anywhere; }
.progress-meeting-list { display: grid; gap: 8px; min-width: 0; }
.progress-meeting-list ol { display: grid; gap: 8px; list-style: none; }
.progress-meeting-list li {
    display: grid; gap: 3px; justify-items: start; padding: 0 0 5px 12px; border-inline-start: 2px solid var(--accent-border); min-width: 0;
}
.progress-meeting-list li p { color: var(--muted); overflow-wrap: anywhere; }
.draft-customer-field { display: grid; gap: 6px; }
.draft-customer-field > .button { justify-self: start; }
.draft-progress-field { margin-top: 2px; }
.draft-progress-options { display: grid; gap: 5px; max-height: 170px; overflow: auto; }
.draft-progress-options label { align-items: center; gap: 7px; padding-block: 3px; }
.customer-picker { position: relative; min-width: 0; }
.customer-picker > .field { position: relative; }
.customer-picker input { padding-inline-end: 32px; }
.customer-picker .field > svg { position: absolute; inset-inline-end: 10px; bottom: 10px; pointer-events: none; }
.customer-picker-menu {
    position: absolute; z-index: 3; inset-inline: 0; top: calc(100% + 3px); max-height: 235px; overflow: auto;
    background: var(--surface); border: 1px solid var(--border); box-shadow: var(--shadow);
}
.customer-picker-menu [role="option"] {
    display: flex; justify-content: space-between; gap: 8px; padding: 8px 10px; cursor: pointer;
}
.customer-picker-menu [role="option"]:hover,
.customer-picker-menu [aria-selected="true"] { background: #e9f1ff; }
.customer-picker-menu p { padding: 7px 10px; margin: 0; }
.review-footer { padding: 8px 14px; }
.review-list-header { row-gap: 5px; }
.review-list-header > [role=group] { margin-inline-start: auto; gap: 6px; }
.review-list-header .button { min-height: 32px; padding-block: 3px; }
.review-item-list { display: grid; gap: 4px; min-width: 0; }
.review-item-list:empty { display: none; }
.review-fact-block { min-width: 0; border: 1px solid #becee5; border-inline-start: 3px solid #5279b0; padding: 11px 14px; background: #f6f9ff; }
.review-fact-block[data-state="confirmed"] { border-color: #a4cbb0; border-inline-start-color: #34864e; background: #edf8f0; }
.fact-heading, .fact-heading label { display: flex; align-items: center; gap: 8px; }
.fact-heading { justify-content: space-between; color: #183456; }
.fact-narrative { display: grid; gap: 8px; overflow-wrap: anywhere; }
.fact-narrative:not(:empty) { margin-block: 9px; }
.fact-paragraphs p { margin: 4px 0 0; line-height: 1.65; }
.fact-details > summary { cursor: pointer; color: #214f90; font-size: 13px; font-weight: 600; }
.fact-details[open] > summary { margin-bottom: 8px; }
.review-item-list-padded { padding: 8px 12px 10px; }
.review-edit-row { position: relative; min-width: 0; }
.review-row-check { position: absolute; z-index: 1; inset: 0 auto auto 3px; width: 34px; height: 36px; display: grid; place-items: center; cursor: pointer; }
.review-item-list .review-edit-row > details > summary { padding-inline-start: 38px; }
.review-item-list .review-item {
    --item-tone: #435676; --item-edge: #7190ba;
    min-width: 0; padding: 0; border: 1px solid #cbd8e8; border-inline-start: 3px solid var(--item-edge);
    border-radius: 3px; background: var(--surface);
}
.review-item-list > .review-item:nth-child(even), .review-edit-row:nth-child(even) .review-item { background: #f2f6fb; }
.review-item-list .review-item[data-state="confirmed"] { background: #e9f7ed; border-color: #b8dcc2; border-inline-start-color: var(--item-edge); }
.review-item[data-kind="date"] { --item-tone: #523494; --item-edge: #7853c5; }
.review-item[data-kind="need"] { --item-tone: #224ead; --item-edge: #3876db; }
.review-item-list .review-item > summary {
    display: grid; grid-template-columns: auto minmax(0, 1fr) auto auto 14px; gap: 8px; align-items: center;
    min-height: 36px; padding: 4px 8px; list-style: none; color: var(--ink); font-size: 13px; font-weight: 400;
}
.review-item > summary::-webkit-details-marker { display: none; }
.review-item > summary::marker { content: ""; }
.review-item > summary:focus-visible { outline-offset: -2px; }
.review-item > summary:hover { background: #e9f1ff; }
.review-item[open] > summary { background: #eaf0f9; }
.review-item[data-state="confirmed"] > summary:hover,
.review-item[data-state="confirmed"][open] > summary { background: #ddf0e3; }
.review-item[open] > summary > svg { transform: rotate(180deg); }
.review-item-type { color: var(--item-tone); font-size: 12px; font-weight: 650; white-space: nowrap; }
.review-item-title { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.review-item-status { color: #236745; font-size: 12px; white-space: nowrap; }
.review-meeting-date { color: #425570; font-size: 12px; font-variant-numeric: tabular-nums; white-space: nowrap; }
.review-meeting-date[datetime]::before { content: "会议 "; }
.review-item-status[data-state="verify"] { color: #82490a; }
.review-item-body { display: grid; gap: 7px; padding: 9px 10px; border-top: 1px solid #d8e2f0; background: #fff; }
.review-item-body > :empty { display: none; }
.review-item-body .row > .field { flex: 1 1 145px; }
.review-item-body :is(input:not([type=checkbox]), select, textarea) { min-height: 32px; padding-block: 4px; }
.review-item-body > div:has(> .row + .row) { display: grid; gap: 6px; }
.source-text { padding: 9px; margin: 8px 0; max-height: 350px; overflow: auto; border-radius: 4px; background: var(--surface-muted); color: var(--nav-text); font: inherit; font-size: 13px; }
.source-quote-actions { margin: 6px 0; }
.material-progress { display: grid; gap: 4px; }
.material-progress progress, .material-jobs progress { display: block; width: 100%; height: 9px; accent-color: var(--blue); }
.material-jobs { overflow-wrap: anywhere; }
.ai-status { gap: 5px; }
.ai-generation-controls { display: flex; flex-wrap: wrap; gap: 6px; margin: 0; padding: 0; border: 0; min-width: 0; }
.ai-generation-controls:disabled .button { opacity: .6; cursor: wait; }
.ai-status > :empty { display: none; }
.ai-status p { margin: 0; overflow-wrap: anywhere; }
audio { width: 100%; }
.material-input { display: grid; gap: 8px; justify-items: start; padding-top: 12px; border-top: 1px solid var(--soft-border); }
.material-input > label, .material-input textarea { width: 100%; }
.material-input h3, .material-input p { margin: 0; }
.voice-recorder { align-items: center; gap: 9px; }
.voice-status { color: var(--muted); font-size: 13px; overflow-wrap: anywhere; }
.voice-recorder[data-state="error"] .voice-status { color: #854311; border-left: 3px solid #c68428; padding-left: 9px; }
.voice-signal { width: 100%; display: flex; align-items: center; flex-wrap: wrap; gap: 8px; padding: 7px 10px; background: var(--surface-muted); color: var(--muted); font-size: 12px; }
.voice-signal meter { width: 65px; min-width: 36px; flex: 1; height: 14px; }
.voice-time { color: var(--ink); font-variant-numeric: tabular-nums; }
.voice-recorder audio { width: 100%; max-width: 100%; height: 38px; }
.voice-help { font-size: 12px; color: var(--muted); }
.voice-help summary { color: var(--blue-deep); }
.voice-help p { margin-top: 5px; }
.list { display: grid; padding: 0 13px; }
.list > article { padding: 11px 1px; border-bottom: 1px solid var(--soft-border); display: grid; gap: 7px; min-width: 0; }
.list > article:last-child { border-bottom: none; }
.list .button { justify-self: start; }
.source-group-head { display: inline-flex; align-items: center; gap: 9px; margin: 1px 0; }
.source-preview { display: block; overflow: hidden; white-space: nowrap; text-overflow: ellipsis; max-width: 100%; padding: 5px 8px; background: var(--surface-muted); color: var(--muted); font-size: 12.5px; font-weight: 400; }
.source-group[open] .source-preview { display: none; }
.dependencies { list-style: none; padding: 0 13px; }
.dependencies li { display: flex; gap: 7px; flex-wrap: wrap; align-items: center; padding: 10px 0; border-bottom: 1px solid var(--soft-border); }
.dependencies li:last-child { border: 0; }
.admin-links { display: flex; flex-wrap: wrap; gap: 9px; padding: 15px; }
.browser-checks { display: grid; gap: 0; padding: 0 16px; }
.browser-checks > div { display: flex; align-items: center; gap: 9px; padding: 11px 0; }
.browser-checks > div + div { border-top: 1px solid var(--soft-border); }
.browser-checks .badge { margin-left: auto; }
.browser-checks svg { color: #157468; }
.settings-list { margin: 0; padding: 0 16px; }
.settings-list > div { display: grid; grid-template-columns: 160px 1fr; gap: 8px; padding: 10px 0; border-bottom: 1px solid var(--soft-border); }
.settings-list > div:last-child { border-bottom: 0; }
.settings-list dt { font-weight: 650; }
.settings-list dd { margin: 0; color: var(--muted); }
.settings-input { display: grid; gap: 8px; }
.settings-input .field { max-width: 230px; }

.dialog { max-height: min(92vh, 720px); width: min(540px, calc(100% - 26px)); padding: 0; border: 1px solid var(--border); border-radius: 10px; color: var(--ink); box-shadow: 0 16px 45px #15243d38; }
.dialog::backdrop { background: #15223b64; }
.dialog-head, .dialog-actions { display: flex; gap: 8px; align-items: center; padding: 13px 17px; background: var(--surface); }
.dialog-head { border-bottom: 1px solid var(--soft-border); justify-content: space-between; }
.dialog-head h2 { font-size: 16px; }
.dialog-content { padding: 17px; display: grid; gap: 9px; }
.dialog-feedback { border: 1px solid #eab0bd; padding: 8px 10px; background: #fff4f5; color: #911f31; overflow-wrap: anywhere; }
.dialog-actions { justify-content: flex-end; border-top: 1px solid var(--soft-border); }
.dialog.progress-drawer {
    position: fixed; inset: 0 0 0 auto; margin: 0; width: min(560px, 100vw); max-width: 100%;
    height: 100dvh; max-height: 100dvh; border-block: 0; border-inline-end: 0; border-radius: 0;
}
.dialog.progress-drawer[open] { display: grid; grid-template-rows: auto minmax(0,1fr) auto; }
.progress-drawer .dialog-head { padding: max(17px, var(--safe-top)) 23px 15px; }
.progress-drawer .dialog-head h2 { font-size: 21px; line-height: 1.3; }
.progress-drawer .dialog-content { padding: 18px 23px; overflow-y: auto; overscroll-behavior: contain; align-content: start; min-height: 0; }
.progress-drawer .dialog-actions { padding: 12px 23px max(12px, var(--safe-bottom)); }
.progress-drawer::backdrop { background: #15223b48; }
@media (max-width: 760px) {
    .product-line-tab { flex-basis: 88px; min-height: 71px; padding-inline: 8px; }
    .product-line-tab[aria-pressed="true"] { flex-basis: 104px; }
    .progress-facts { grid-template-columns: 1fr; }
}
.confirmation-list { padding-inline-start: 20px; }
.confirmation-list li + li { margin-top: 6px; }
.notice {
    position: fixed; top: calc(var(--header) + 10px); right: 15px; z-index: 9; max-width: min(440px, calc(100vw - 30px));
    background: #f1fbf4; color: #1b6240; border: 1px solid #abdcb8; border-radius: 4px; box-shadow: 0 5px 18px #1a2e481e;
    padding: 7px 9px; display: flex; align-items: center; gap: 8px;
}
.notice.error { background: #fff4f5; color: #911f31; border-color: #eab0bd; }
.notice .icon-button { color: inherit; }
.notice.floating {
    top: auto; left: auto; right: max(18px, var(--safe-right)); bottom: max(18px, var(--safe-bottom)); width: max-content;
    max-width: calc(100% - 36px); padding: 8px 10px 8px 15px; background: #15171b; color: white;
    border: 1px solid #15171b; border-radius: 7px; box-shadow: 0 5px 22px #10182830;
}
.notice.floating .icon-button:hover { background: #33383f; border-color: #555c65; }

.login-layout { display: grid; grid-template-columns: minmax(350px, 1fr) minmax(420px, .92fr); min-height: 100vh; }
.login-aside {
    position: relative; display: flex; flex-direction: column; gap: clamp(56px, 14vh, 150px); overflow: hidden;
    background: #102d65; color: white; padding: 39px clamp(25px, 5vw, 88px);
}
.login-aside::after {
    content: ""; position: absolute; inset: auto -10% -26% 9%; height: 70%; pointer-events: none;
    border: 1px solid #afcbff38; border-radius: 50%; box-shadow: 0 0 0 35px #afcbff1d, 0 0 0 76px #afcbff11, 0 0 0 114px #afcbff0c;
}
.login-brand { display: flex; align-items: center; gap: 12px; font-size: 18px; font-weight: 700; }
.login-brand .brand-mark { width: 38px; height: 38px; color: #102d65; background: #dce8ff; }
.login-message { position: relative; z-index: 1; display: grid; gap: .15em; font-size: clamp(25px, 2.95vw, 54px); line-height: 1.35; letter-spacing: -.025em; }
.login-message span:last-child { color: #ccdeff; }
.login-diagram { position: relative; z-index: 1; display: flex; width: min(100%, 390px); align-items: center; justify-content: space-between; }
.login-diagram::before { content: ""; position: absolute; inset: 50% 22px auto; border-top: 1px dashed #80a3dc; }
.login-diagram span {
    position: relative; display: grid; place-items: center; width: 72px; height: 72px;
    border: 1px solid #668ac7; border-radius: 12px; color: #e4edff; background: #214785;
}
.login-diagram span:first-child { border-color: #c1d7ff; color: #173668; background: #d0e2ff; }
.login-main { display: grid; align-content: center; justify-items: center; padding: 28px; background: var(--canvas); }
.login-card { width: min(100%, 400px); padding: 28px; border: 1px solid var(--border); border-radius: 12px; background: var(--surface); box-shadow: var(--shadow); }
.login-card h2 { font-size: 29px; line-height: 1.25; letter-spacing: -.035em; }
.login-card .meta { margin-top: 7px; }
.login-card form { margin-top: 21px; }
.login-card input, .login-card .button { min-height: 40px; }
.login-card .button { margin-top: 7px; justify-content: space-between; }

@media (max-width: 1240px) {
    .page { padding-inline: 19px; }
}
@media (max-width: 1040px) {
    :root { --sidebar: 190px; }
    .detail-layout, .review-layout { grid-template-columns: minmax(0, 1fr); }
    .draft-layout { grid-template-areas: "materials" "review"; }
    .page-heading { align-items: flex-start; }
    .heading-actions { flex: 0 1 auto; }
}
@media (max-width: 860px) {
    :root, body.nav-collapsed { --sidebar: 0px; --header: 56px; }
    body.nav-open { overflow: hidden; }
    .sidebar {
        width: min(330px, 88vw); translate: -100% 0; visibility: hidden;
        padding: var(--safe-top) 0 var(--safe-bottom) var(--safe-left);
    }
    .sidebar nav { overscroll-behavior: contain; }
    #nav-close { display: inline-grid; flex: none; margin-inline: 4px 10px; color: var(--muted); }
    #nav-close:hover { background: var(--accent-soft); border-color: var(--accent-border); }
    .side-footer { display: none; }
    .brand { padding-inline: 13px 0; }
    .nav-item { min-height: 46px; font-size: 14px; }
    .topbar {
        min-height: calc(var(--header) + var(--safe-top));
        padding: var(--safe-top) max(10px, var(--safe-right)) 0 max(10px, var(--safe-left));
    }
    .top-start { gap: 7px; }
    .breadcrumbs { gap: 5px; }
    .breadcrumbs > :not(svg) { min-width: 0; text-overflow: ellipsis; overflow: hidden; white-space: nowrap; }
    .breadcrumbs strong { font-size: 14px; }
    .identity { flex: none; }
    .icon-button { width: 44px; height: 44px; }
    .account-menu summary { min-width: 44px; min-height: 44px; gap: 5px; }
    .account-popover { top: calc(100% + 3px); width: min(240px, calc(100vw - 25px)); }
    .account-popover strong { overflow-wrap: anywhere; }
    .nav-open .sidebar { translate: 0 0; visibility: visible; z-index: 7; }
    .nav-open .scrim { display: block; position: fixed; z-index: 6; inset: 0; width: 100%; border: 0; background: #15223870; }
    .page { padding-inline: max(13px, var(--safe-left)) max(13px, var(--safe-right)); padding-bottom: calc(24px + var(--safe-bottom)); }
    .dialog {
        position: fixed; inset: auto 0 var(--dialog-bottom, 0px); margin: 0 auto; width: min(100%, 580px); max-width: none;
        max-height: calc(var(--dialog-height, 100dvh) - max(8px, var(--safe-top))); border-radius: 8px 8px 0 0; overflow: hidden;
    }
    .dialog[open] { display: grid; grid-template-rows: auto minmax(0, 1fr) auto; }
    .dialog-content { min-height: 0; overflow-y: auto; overscroll-behavior: contain; align-content: start; }
    .dialog-head, .dialog-content, .dialog-actions { padding-inline: max(12px, var(--safe-left)) max(12px, var(--safe-right)); }
    .dialog-actions {
        display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); padding-bottom: max(10px, var(--safe-bottom));
    }
    .dialog-actions > :only-child { grid-column: 1 / -1; }
    .notice { top: calc(var(--header) + var(--safe-top) + 8px); right: max(10px, var(--safe-right)); }
    .section-shortcuts {
        position: sticky; z-index: 2; top: calc(var(--header) + var(--safe-top)); display: grid;
        grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 7px;
        padding-block: 7px; background: var(--canvas);
    }
    .section-shortcuts .button { min-height: 44px; white-space: normal; }
    :is(#draft-materials, #draft-review, #customer-timeline, #customer-progress, #meeting-record, #meeting-sources,
        .source-text mark, .editor-body details) {
        scroll-margin-top: calc(var(--header) + var(--safe-top) + 64px);
    }
}
@media (max-width: 700px) {
    :root { font-size: 15px; }
    .page { gap: 14px; padding-top: 15px; }
    .page-heading { flex-direction: column; gap: 10px; }
    .page-heading > div { max-width: 100%; }
    .page-heading .heading-actions { justify-content: flex-start; width: 100%; }
    .page-heading h1 { font-size: 24px; }
    .heading-actions { flex-wrap: wrap; min-width: 0; }
    .page-heading .heading-actions .button { flex: 0 1 auto; }
    .button, .button.text-button, .text-link { min-height: 44px; padding: 8px 11px; white-space: normal; text-align: center; }
    .button, .text-link { font-size: 14px; }
    .text-link { padding-inline: 0; }
    .meta, .small { font-size: 13px; }
    input:not([type=checkbox]), select, textarea { min-height: 44px; min-width: 0; font-size: 16px; }
    input[type="date"] { min-inline-size: 0; }
    input[type="file"] { padding-inline: 6px; }
    input[type="file"]::file-selector-button { min-height: 32px; font-size: 13px; }
    input[type=checkbox] { width: 19px; height: 19px; flex: none; }
    .touch-check { display: inline-flex; align-items: center; gap: 7px; min-height: 44px; min-width: 44px; cursor: pointer; }
    .touch-check .mobile-cell-label { display: inline; font-size: 13px; }
    .check-options label { min-height: 44px; }
    .badge, .tag { white-space: normal; overflow-wrap: anywhere; }
    .metrics { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 8px; }
    .metrics.three { grid-template-columns: repeat(2, minmax(0, 1fr)); }
    .metric { padding: 10px; gap: 8px; min-height: 82px; }
    .metric > div { min-width: 0; }
    .metric-icon { width: 30px; height: 30px; }
    .metric strong { font-size: 22px; }
    .metric small { font-size: 12px; }
    .map-page .page-heading { flex-direction: row; align-items: start; }
    .map-page .page-heading .heading-actions { width: auto; flex: none; }
    .map-page .page-heading h1 { font-size: 29px; }
    .map-page .page-heading .meta { font-size: 13px; }
    .map-page .heading-actions > .button { padding-inline: 9px; }
    .product-line-deck { padding: 10px 8px 7px; }
    .product-line-deck h2 { padding-inline: 5px; }
    .board-top { flex-wrap: wrap; gap: 9px; padding: 13px 12px; }
    .board-title h2 { font-size: 18px; }
    .board-stats { gap: 9px; }
    .board-stats > div { padding-inline-start: 8px; }
    .board-stats strong { font-size: 19px; }
    .map-filters { display: grid; grid-template-columns: repeat(2,minmax(0,1fr)); gap: 7px; padding: 10px 12px; }
    .map-filters > select { width: 100%; }
    .map-filters .searchbox { grid-column: 1 / -1; max-width: none; width: 100%; }
    .map-filter-popover { min-width: min(250px, calc(100vw - 58px)); }
    .map-filters .map-filter-reset { justify-self: start; }
    .customer-mark { width: 46px; height: 46px; }
    .customer-tabs { gap: 4px; }
    .customer-tabs button { gap: 5px; padding-inline: 5px; font-size: 13px; }
    .customer-tabs { flex-wrap: nowrap; overflow-x: auto; }
    .customer-tabs button { flex: none; white-space: nowrap; }
    .customer-tabs button > svg { display: none; }
    .ledger tr > :first-child .entity-link, .ledger .progress-project { max-width: 34vw; }
    .notification-popover { position: fixed; top: calc(var(--header) + var(--safe-top) + 3px); right: max(10px, var(--safe-right)); max-width: calc(100vw - 20px); }
    .notice.floating { bottom: calc(70px + var(--safe-bottom)); }
    .progress-drawer .dialog-head, .progress-drawer .dialog-content, .progress-drawer .dialog-actions { padding-inline: 15px; }
    .account-name { display: none; }
    .breadcrumbs > span:first-child { display: none; }
    .breadcrumbs > span:first-child + svg { display: none; }
    .breadcrumbs > svg:first-of-type { width: 11px; height: 11px; }
    .breadcrumbs > a { font-size: 12px; }
    .customer-facts { grid-template-columns: repeat(2, minmax(0, 1fr)); padding: 12px; gap: 10px 12px; }
    .customer-facts > div + div { border: none; padding: 0; }
    .customer-facts > div:nth-child(3) { grid-column: 1 / -1; }
    .timeline { padding: 12px 12px 15px; }
    .timeline-row { grid-template-columns: 20px minmax(0, 1fr); grid-template-rows: auto auto; }
    .timeline-date { grid-area: 1 / 2; display: flex; align-items: baseline; gap: 8px; padding: 0 1px 7px; }
    .timeline-date strong { font-size: 14px; }
    .timeline-date span { font-size: 12px; }
    .timeline-marker { grid-area: 1 / 1 / span 2; }
    .timeline-marker::before { top: 7px; }
    .timeline-row:not(:last-child) .timeline-marker::after { inset: 10px auto -7px 7px; }
    .timeline-card { grid-area: 2 / 2; min-width: 0; padding: 10px; gap: 8px; }
    .timeline-card-head { flex-wrap: wrap; }
    .timeline-dates { font-size: 13px; }
    .panel-head { padding: 10px 12px; flex-wrap: wrap; }
    .panel-head .meta { font-size: 12px; }
    .panel-head .heading-actions { justify-content: flex-start; }
    .callout { align-items: flex-start; flex-wrap: wrap; }
    .callout .button { margin-left: 0; }
    .table-toolbar { padding: 10px 12px; }
    .filters, .timeline-tools { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); align-items: end; }
    .filters > *, .timeline-tools > * { min-width: 0; }
    .filters .searchbox, .timeline-tools .searchbox, .filters .push, .timeline-tools .push { grid-column: 1 / -1; margin-left: 0; }
    .filters .searchbox { width: 100%; }
    .table-footer { padding: 10px 12px; gap: 6px 10px; }
    .table-footer > .row { display: grid; grid-template-columns: minmax(0, 1fr) auto auto; width: 100%; gap: 6px; }
    .table-footer .button, .table-footer select { min-height: 44px; font-size: 14px; }
    .table-scroll { scroll-margin-top: calc(var(--header) + var(--safe-top) + 8px); }
    .mobile-table-tools {
        display: grid; grid-template-columns: minmax(0, 1fr) minmax(88px, .57fr); align-items: end;
        gap: 7px; padding: 9px 12px; border-bottom: 1px solid var(--soft-border);
    }
    .mobile-table-tools .touch-check { grid-column: 1 / -1; }
    .card-table { display: block; font-size: 14px; }
    .card-table.custom-column-widths { width: 100%; table-layout: auto; }
    .card-table colgroup { display: none; }
    .card-table thead { display: none; }
    .card-table tbody { display: grid; gap: 8px; padding: 10px; }
    .card-table tbody > tr {
        min-width: 0; display: grid; grid-template-columns: repeat(2, minmax(0, 1fr));
        align-items: start; gap: 0 10px; padding: 6px 11px 8px;
        border: 1px solid var(--border); border-radius: 3px; background: #fff;
    }
    .card-table tbody tr:nth-child(even) { background: #fff; }
    .card-table tbody tr.selected { border-color: var(--accent-border); background: var(--accent-soft); }
    .card-table tbody > tr > :is(td, th) {
        display: block; min-width: 0; width: auto; padding: 6px 0; border: 0;
        white-space: normal; overflow-wrap: anywhere; font-size: inherit;
    }
    .card-table .mobile-cell-label { display: block; color: var(--muted); font-size: 12px; line-height: 1.35; }
    .card-table .mobile-cell-label + .cell-content { margin-top: 2px; }
    .card-table .card-title { font-size: 16px; font-weight: 650; }
    .card-table :is(.card-title, .card-wide, .card-actions, .table-empty, td[colspan]) { grid-column: 1 / -1; }
    .card-table td a { display: inline-flex; min-height: 44px; align-items: center; }
    .card-table td.check-cell { grid-column: 1 / -1; padding: 0; }
    .card-table .check-cell.no-check { display: none; }
    .card-table .card-actions { border-top: 1px solid var(--soft-border); margin-top: 4px; padding-bottom: 0; }
    .card-table .card-actions > .mobile-cell-label { display: none; }
    .card-table .row { flex-wrap: wrap; gap: 8px 14px; }
    .card-table .cell-summary { min-width: 0; max-width: none; }
    .information-table tbody > tr { display: block; }
    .information-table tbody > tr > .card-title { border-bottom: 1px solid var(--soft-border); }
    .settings-list > div { grid-template-columns: 1fr; }
    .editor-body, .padded { padding: 13px; }
    .review-item-list .review-item > summary { min-height: 44px; gap: 6px; padding-inline: 7px; }
    .review-row-check { height: 44px; width: 41px; }
    .review-item-list .review-edit-row > details > summary { padding-inline-start: 45px; }
    .review-item-body .row > .field { flex-basis: min(100%, 150px); }
    .source-text { font-size: 14px; line-height: 1.65; max-height: min(55dvh, 400px); }
    .source-group summary, .editor-body details summary, .padded details summary { min-height: 44px; padding-block: 9px; }
    :is(.editor-body, .padded) details > a { display: inline-flex; align-items: center; min-height: 44px; }
    .source-group-head { max-width: 100%; flex-wrap: wrap; }
    .editor-footer {
        z-index: 1; display: grid; grid-template-columns: repeat(2, minmax(0, 1fr));
        padding: 8px 10px max(8px, var(--safe-bottom));
    }
    .editor-footer > :only-child { grid-column: 1 / -1; }
    .panel:focus-within:has(input:not([type=checkbox]):focus, select:focus, textarea:focus) > .editor-footer { position: static; }
    .dialog { width: 100%; }
    .notice { left: max(10px, var(--safe-left)); max-width: none; overflow-wrap: anywhere; }
    .notice .icon-button { flex: none; margin-inline-start: auto; }
    .login-layout { grid-template-columns: 1fr; grid-template-rows: auto 1fr; min-height: 100dvh; }
    .login-aside { padding: calc(15px + var(--safe-top)) max(16px, var(--safe-right)) 15px max(16px, var(--safe-left)); gap: 0; }
    .login-main { align-content: start; padding: 25px max(16px, var(--safe-right)) calc(24px + var(--safe-bottom)) max(16px, var(--safe-left)); }
    .login-message { margin-top: 14px; font-size: clamp(22px, 5vw, 32px); }
    .login-diagram { display: none; }
    .login-card { width: min(100%, 410px); padding: 19px; }
    .login-card .button { width: 100%; min-height: 46px; }
}
@media (min-width: 701px) and (max-width: 820px) {
    .login-layout { grid-template-columns: 1fr 1fr; }
}
@media (max-width: 360px) {
    .form-grid { grid-template-columns: minmax(0, 1fr); }
    .breadcrumbs > a, .breadcrumbs > svg { display: none; }
    .table-footer .button { padding-inline: 7px; }
    .table-footer .button svg { display: none; }
}
@media (pointer: coarse) and (min-width: 701px) {
    .button, .button.text-button, .table-footer .button, .table-sort,
    input:not([type=checkbox]), select, .table-footer select { min-height: 44px; }
    input:not([type=checkbox]), select, textarea { font-size: 16px; }
    .data-table .check-cell { min-width: 48px; }
    .touch-check { display: inline-flex; align-items: center; min-width: 44px; min-height: 44px; }
}

/* Scale the painted box without changing layout or the column widths.
   Keep the dashboard bars anchored so their lengths still represent progress. */
@media (hover: hover) and (pointer: fine) and (prefers-reduced-motion: no-preference) {
    :where(.panel, .account-overview, .metric, .timeline-card, .review-item, .review-fact-block,
           .stage-review, .brief-intent, .brief-comparison, .brief-followup, .brief-history,
           .brief-undated, .brief-empty, .login-card, .perm-option, .ob-network, .ob-priorities,
           .stage-map, .ob-node, .ob-metric, .ob-stage, .dept-phase-list li, .stage-bar,
           .nav-item, .product-line-tab, .customer-tabs button, .work-departments button, .dept-tab,
           .button, .icon-button, .work-meter, .phase-choice, .notification-item, .searchbox,
           select, textarea, input:not([type=hidden], [type=checkbox], [type=radio], [type=range])) {
        --hover-scale: 1.024;
        transition: scale 160ms ease-out, box-shadow 160ms ease-out;
        &:hover:not(:disabled, [aria-disabled="true"]) { scale: var(--hover-scale); }
    }
    :is(.panel, .account-overview, .brief-comparison, .brief-followup, .ob-network, .ob-priorities, .stage-map) {
        --hover-scale: 1.004 1.002;
    }
    :is(.metric, .timeline-card, .review-item, .review-fact-block, .stage-review, .brief-intent,
        .brief-history, .brief-undated, .brief-empty, .login-card, .perm-option, .ob-metric,
        .ob-stage, .dept-phase-list li, .nav-item, .notification-item, .searchbox, select, textarea, input) {
        --hover-scale: 1.012;
    }
    :is(.panel, .metric, .timeline-card, .account-overview, .review-item, .brief-comparison, .brief-intent,
        .brief-followup, .login-card):hover { box-shadow: 0 5px 18px #1438661a, 0 0 0 1px #2969d331; }
    .ob-page :is(.ob-network, .ob-priorities, .stage-map):hover { box-shadow: 0 0 16px #4ecfff25; }
    .ob-page .stage-bar { --hover-scale: 1 1.08; }
    .searchbox input:hover { scale: none; }
    .nav-item { transform-origin: left center; }
    /* Don't move a resize grip, a text caret or an open suggestion list. */
    :is(.table-panel, .brief-comparison) { --hover-scale: 1 1.003; transform-origin: center top; }
    .panel:has(.customer-picker-menu:not([hidden])):hover,
    :is(input, textarea, select):focus:hover { scale: none; }
}
