#keter-theme-toggle{font:inherit;font-size:12px;min-height:40px;padding:8px 12px;border:1px solid currentColor;border-radius:4px;cursor:pointer;background:transparent;color:inherit;white-space:nowrap}#keter-theme-toggle:focus-visible{outline:2px solid currentColor;outline-offset:3px}
:root[data-color-mode="light"]{color-scheme:light;--bg:#faf8f1;--surface:#fff;--raised:#efede3;--line:#d4cfbc;--text:#29271f;--muted:#625e50;--accent-text:#5c500b}
:root[data-color-mode="light"][data-review-project="liranza"]{--accent-text:#874418}
:root[data-color-mode="light"][data-review-project="los-villarreales"]{--accent-text:#5D3A00}
[data-color-mode="light"] body{background:var(--bg,#faf8f1);color:var(--text,#29271f)}[data-color-mode="light"] header{background:#f1eee2}[data-color-mode="light"] .sales-alert,[data-color-mode="light"] .count{background:#eee7c9}[data-color-mode="light"] .message{background:#fff}[data-color-mode="light"] .message.outbound{background:#f1efdf}[data-color-mode="light"] #error,[data-color-mode="light"] .followup-error,[data-color-mode="light"] #sales-form-error{background:#fff0e8;color:#842b15}[data-color-mode="light"] button,[data-color-mode="light"] input,[data-color-mode="light"] select,[data-color-mode="light"] textarea{border-color:#807967}[data-color-mode="light"] dialog{background:var(--bg);color:var(--text)}
/* Portal theme overrides use named app surfaces; maps and inventory status fills stay intact. */
:root[data-color-mode="dark"] #root{--ui-paper:#20211f;--ui-ink:#f0f0e8;--ui-muted:#bbbfaf;--ui-line:#45483f;--brand-paper:#20211f;--brand-soft:#30322d;--brand-line:#45483f;--brand-muted:#bbbfaf;--brand-primary:#f0f0e8;--brand-accent:#d7ca79;--broker-v2-bg:#20211f;--broker-v2-card-bg:#272925;--broker-v2-text:#f0f0e8;--broker-v2-text-muted:#bbbfaf;--broker-v2-border:#45483f}
[data-color-mode="dark"] #root .crm-header,[data-color-mode="dark"] #root .admin-card,[data-color-mode="dark"] #root .admin-table-card,[data-color-mode="dark"] #root .brokers-card,[data-color-mode="dark"] #root .brokers-v2-card,[data-color-mode="dark"] #root .brokers-dashboard-card,[data-color-mode="dark"] #root .brokers-stat-card,[data-color-mode="dark"] #root .crm-resource-card,[data-color-mode="dark"] #root .crm-resource-file,[data-color-mode="dark"] #root .auth-card,[data-color-mode="dark"] #root .crm-upload-queue li{background:#272925;color:#f0f0e8;border-color:#45483f;box-shadow:none}
[data-color-mode="dark"] #root input,[data-color-mode="dark"] #root select,[data-color-mode="dark"] #root textarea,[data-color-mode="dark"] #root .crm-advisor-tools a,[data-color-mode="dark"] #root .crm-upload-picker{background:#30322d;color:#f0f0e8;border-color:#7f8376}
[data-color-mode="dark"] #root .admin-table td,[data-color-mode="dark"] #root .admin-table th{color:#f0f0e8;border-color:#45483f}[data-color-mode="dark"] #root .admin-table th,[data-color-mode="dark"] #root .admin-table tbody tr:hover{background:#30322d}[data-color-mode="dark"] #root .admin-note,[data-color-mode="dark"] #root .admin-field label,[data-color-mode="dark"] #root .brokers-field label{color:#bbbfaf}
[data-color-mode="dark"] #root button:focus-visible,[data-color-mode="dark"] #root a:focus-visible{outline:2px solid #F9EA9A;outline-offset:3px}[data-color-mode="dark"] #root .auth-tabs .is-active{background:#45483f;color:#f0f0e8}

[data-color-mode="dark"] body:has(#root){background:#20211f;color:#f0f0e8}[data-color-mode="dark"] #root #keter-theme-toggle{background:#30322d;color:#f0f0e8;border-color:#918f7f}[data-color-mode="dark"] #root .admin-action,[data-color-mode="dark"] #root .brokers-submit,[data-color-mode="dark"] #root .auth-primary{background:var(--project-action);color:var(--project-action-ink);border-color:#918a6c}[data-color-mode="dark"] #root .crm-resource-delete{background:#382b27;color:#ffc6b2;border-color:#b77d68}
/* Contrast repair for the portal's legacy white surfaces. */
[data-color-mode="dark"] #root .crm-advisor-onboarding,[data-color-mode="dark"] #root .admin-table-wrapper,[data-color-mode="dark"] #root .admin-note,[data-color-mode="dark"] #root .brokers-helper-card,[data-color-mode="dark"] #root .admin-modal,[data-color-mode="dark"] #root .admin-modal-content{background:#272925;color:#f0f0e8;border-color:#45483f}
[data-color-mode="dark"] #root h1,[data-color-mode="dark"] #root h2,[data-color-mode="dark"] #root h3,[data-color-mode="dark"] #root h4,[data-color-mode="dark"] #root .admin-title,[data-color-mode="dark"] #root .brokers-title-left{color:#f0f0e8}
[data-color-mode="dark"] #root .admin-muted,[data-color-mode="dark"] #root .admin-count,[data-color-mode="dark"] #root .admin-control-label,[data-color-mode="dark"] #root .crm-resource-file time,[data-color-mode="dark"] #root .crm-library-count,[data-color-mode="dark"] #root .crm-resource-meta,[data-color-mode="dark"] #root .brokers-helper-text{color:#c4c7b9}
[data-color-mode="dark"] #root .crm-skip{background:#272925;color:#f9ea9a;border:1px solid #918a6c}
[data-color-mode="dark"] #root .admin-card,[data-color-mode="dark"] #root .admin-table-card{--text-primary:#f0f0e8;--text-secondary:#c4c7b9}
[data-color-mode="dark"] #root .admin-action{background:var(--project-action);color:var(--project-action-ink)}
[data-color-mode="light"] #root .admin-action{background:var(--project-action);color:var(--project-action-ink)}
[data-color-mode="dark"] #root .admin-action:not(.admin-action-danger):not(.danger),[data-color-mode="light"] #root .admin-action:not(.admin-action-danger):not(.danger){background:var(--project-action);color:var(--project-action-ink);border-color:var(--brand-swatch)}
[data-color-mode="dark"] #root .admin-badge{background:#203c2c;color:#c4ebcc;border:1px solid #6b9977}[data-color-mode="dark"] #root .admin-badge.warning{background:#493d24;color:#f9ea9a;border-color:#a59152}[data-color-mode="dark"] #root .admin-badge.danger{background:#4c2c26;color:#ffcab8;border-color:#b57c6b}
[data-color-mode="dark"] #root .crm-library-toolbar>span{color:#c4c7b9}

/* Unified neutral CRM theme. Primary navy; secondary coral; explicit light/dark surfaces. */
html:root:root:root{color-scheme:light;--bg:#f7f8fa;--surface:#ffffff;--raised:#f2f4f7;--line:#dce2e8;--text:#213343;--muted:#596b7a;--accent:#ff5c35;--accent-text:#b93b1d;--project-color:#213343;--project-action:#ff5c35;--project-action-ink:#ffffff}
html:root:root:root[data-color-mode="dark"]{color-scheme:dark;--bg:#14191f;--surface:#1d242c;--raised:#252f39;--line:#3b4652;--text:#f2f5f8;--muted:#b5c0cb;--accent:#ff7a59;--accent-text:#ff9a80;--project-color:#213343;--project-action:#ff7a59;--project-action-ink:#14191f}
html:root:root #root{--brand-primary:var(--text);--brand-hover:#344b60;--brand-accent:var(--accent);--brand-paper:var(--bg);--brand-soft:var(--raised);--brand-line:var(--line);--brand-muted:var(--muted);--brand-swatch:#213343;--ui-ink:var(--text);--ui-muted:var(--muted);--ui-line:var(--line);--ui-paper:var(--bg);--broker-v2-primary:var(--accent);--broker-v2-secondary:var(--raised);--broker-v2-accent:var(--accent);--broker-v2-bg:var(--bg);--broker-v2-card-bg:var(--surface);--broker-v2-text:var(--text);--broker-v2-text-muted:var(--muted);--broker-v2-border:var(--line);--text-primary:var(--text);--text-secondary:var(--muted);font-family:-apple-system,BlinkMacSystemFont,"Segoe UI",Arial,sans-serif;font-size:14px;line-height:1.55;min-height:100vh;-webkit-text-size-adjust:100%;font-synthesis:none}
html:root body,html:root #root .admin-page,html:root #root .brokers-dashboard,html:root #root .brokers-page-v2{background:var(--bg)!important;color:var(--text)!important}html:root body{font-family:-apple-system,BlinkMacSystemFont,"Segoe UI",Arial,sans-serif;-webkit-text-size-adjust:100%}
html:root header,html:root #root .crm-header{background:var(--surface)!important;color:var(--text)!important;border-top:0!important;border-bottom:1px solid var(--line)!important;box-shadow:none!important}html:root #root .crm-header{display:flex;flex-wrap:wrap;height:auto;align-items:center;min-height:76px}html:root #root .crm-brand{min-width:0;max-width:100%}html:root #root .crm-header nav{display:flex;flex-wrap:wrap;align-items:center;max-width:100%;min-width:0;margin-left:auto}html:root #root .crm-header nav a,html:root #root .crm-brand span,html:root header a{color:var(--text)!important}html:root #root .crm-header nav a{line-height:1.4;font-weight:500!important}html:root #root .crm-header nav a[href*='/revision/']{background:var(--raised)!important;color:var(--text)!important;font-weight:600!important;border:1px solid var(--line)}html:root #root .crm-header nav a:hover{background:var(--raised)!important}
html:root #root .central-project{background:var(--surface)!important;border:1px solid var(--line)!important;border-left:3px solid #213343!important;min-width:0}html:root #root .central-project strong{color:var(--text)!important;font-weight:600}html:root #root .central-project small,html:root #root .central-project label{color:var(--muted)!important}
html:root #root .admin-card,html:root #root .admin-table-card,html:root #root .brokers-card,html:root #root .brokers-v2-card,html:root #root .brokers-dashboard-card,html:root #root .brokers-stat-card,html:root #root .crm-resource-card,html:root #root .crm-resource-file,html:root #root .auth-card,html:root #root .crm-advisor-onboarding,html:root #root .admin-table-wrapper,html:root #root .admin-note,html:root #root .brokers-helper-card,html:root #root .admin-modal,html:root #root .admin-modal-content{background:var(--surface)!important;color:var(--text)!important;border-color:var(--line)!important;box-shadow:none!important;min-width:0}
html:root #root h1,html:root #root h2,html:root #root h3,html:root #root h4,html:root #root .admin-title,html:root #root .brokers-title-left{color:var(--text)!important;font-weight:600;letter-spacing:-.02em}html:root #root strong{font-weight:600}html:root #root .admin-field label,html:root #root .brokers-field label{font-weight:500;color:var(--text)!important}
html:root #root button,html:root #root input,html:root #root select,html:root #root textarea{font-family:inherit}html:root #root .brokers-submit,html:root #root .admin-action:not(.admin-action-danger):not(.danger),html:root #root .btn-v2-primary,html:root #root .auth-primary{background:var(--project-action)!important;color:var(--project-action-ink)!important;border-color:var(--project-action)!important;font-weight:600!important;box-shadow:none!important}html:root #root .brokers-submit:hover,html:root #root .auth-primary:hover{filter:brightness(.95)}
html:root #root .brokers-inline-btn:not(.crm-resource-delete),html:root #root .crm-header nav button,html:root #root .crm-library-refresh button,html:root #root .crm-advisor-tools a,html:root #root .btn-v2-secondary{background:var(--surface)!important;color:var(--text)!important;border:1px solid var(--line)!important;box-shadow:none!important}html:root #root .crm-library-tabs,html:root #root .crm-file-kind,html:root #root .crm-upload-panel,html:root #root .crm-library-destination{background:var(--raised)!important;color:var(--text)!important;border-color:var(--line)!important}html:root #root .crm-library-tabs button{color:var(--muted)!important;background:transparent!important}html:root #root .crm-library-tabs button[aria-pressed="true"]{background:var(--surface)!important;color:var(--text)!important;border:1px solid var(--line)!important;border-bottom:2px solid var(--accent)!important;font-weight:600}
html:root #root .admin-table th,html:root th{background:var(--raised)!important;color:var(--muted)!important;font-weight:600}html:root #root .admin-table td{color:var(--text)!important;border-color:var(--line)!important}html:root #root .admin-table tbody tr:hover{background:var(--raised)!important}html:root #root .admin-table-wrapper{max-width:100%;overflow-x:auto;-webkit-overflow-scrolling:touch}html:root #root .crm-resource-file h3{overflow-wrap:break-word;word-break:break-word}html:root #root .crm-resource-description,html:root #root .crm-field-note,html:root #root .crm-resource-meta,html:root #root .admin-muted,html:root #root .admin-count,html:root #root .crm-library-count{color:var(--muted)!important}
html:root input:not([type="checkbox"]):not([type="radio"]):not([type="file"]),html:root select,html:root textarea,html:root #root input:not([type="checkbox"]):not([type="radio"]):not([type="file"]),html:root #root select,html:root #root textarea{background:var(--surface)!important;color:var(--text)!important;border-color:var(--line)!important;font-size:16px}html:root select{min-height:44px;max-width:100%}html:root #root .crm-upload-picker,html:root #root .crm-upload-queue li{background:var(--surface)!important;color:var(--text)!important;border-color:var(--line)!important}
html:root #root .crm-footer,html:root footer{background:var(--surface)!important;color:var(--muted)!important;border-color:var(--line)!important}html:root #root :focus-visible,html:root :focus-visible{outline:2px solid var(--accent)!important;outline-offset:3px}html:root #root .brokers-card>div:first-child,html:root #root .auth-tabs{background:var(--raised)!important}html:root #root .brokers-card .brokers-subtitle{color:var(--muted)!important}html:root #root .auth-screen{background:var(--bg)!important;min-height:100vh}
html:root .workspace-sidebar{background:var(--surface)!important;color:var(--text)!important;border-color:var(--line)!important}html:root .workspace-sidebar .sidebar-title{color:var(--text)!important}html:root .work-modes button,html:root .work-modes a,html:root .period-nav button,html:root .period-nav button[aria-pressed="true"]{background:transparent!important;color:var(--text)!important;border-color:var(--line)!important;font-weight:500}html:root .work-modes button[aria-pressed="true"],html:root .period-nav button[aria-pressed="true"]{background:var(--raised)!important;border-left:3px solid var(--accent)!important;font-weight:600}html:root main>section,html:root .summary-section,html:root .focus-layout>section,html:root #advisor-health,html:root .quote-selection,html:root .quote-proposal{background:var(--surface)!important;border-color:var(--line)!important;color:var(--text)!important;box-shadow:none!important}html:root .count,html:root .health-counts button{background:var(--raised)!important;color:var(--text)!important;border-color:var(--line)!important}html:root .message{background:var(--surface)!important;border-color:var(--line)!important}html:root .message.outbound{background:var(--raised)!important}html:root dialog{background:var(--surface)!important;color:var(--text)!important}html:root h1,html:root h2,html:root h3{font-weight:600;color:var(--text)}html:root .quote-summary,html:root #quote-summary{background:var(--raised)!important;color:var(--text)!important}
@media(max-width:760px){html:root #root .crm-header nav{width:100%;margin-left:0}html:root #root .central-project select{width:100%;min-width:0}html:root #root .admin-users-title-row,html:root #root .admin-users-controls,html:root #root .admin-controls-left,html:root #root .admin-controls-right{display:flex;flex-wrap:wrap;min-width:0;max-width:100%;gap:10px}html:root #root .admin-count{white-space:normal}}

html:root:root:root #root{--project-action:#213343;--project-action-ink:#ffffff;--brand-swatch:#213343}html:root:root #run-review,html:root:root #quote-save,html:root:root #sales-save-result{background:#213343!important;color:#fff!important;border-color:#213343!important}html:root:root .sidebar-help,html:root:root .muted{color:var(--muted)!important}html:root:root .work-modes a{display:block;padding:12px 16px;text-decoration:none;border-radius:6px}html:root:root #root .central-project{border-left-width:1px!important}html:root:root #root .brokers-stat-card{border-top:1px solid var(--line)!important}

html:root:root #root .admin-resource-library{background:var(--surface)!important;color:var(--text)!important;border-color:var(--line)!important}html:root:root #root .admin-resource-library>summary{color:var(--text)!important}

/* Advisor home uses the same neutral theme. */
body[data-workspace-mode="home"] #advisor-health,body[data-workspace-mode="home"] #advisor-notices{display:none!important}#sales-home{padding:28px!important;border:1px solid var(--line);border-radius:10px}.home-eyebrow{font-size:12px;font-weight:600;color:var(--muted);margin:0 0 8px}.home-welcome h2{font-size:28px;line-height:1.25;margin:0 0 10px}.home-stats{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:16px;margin:26px 0}.home-stat{display:flex;flex-direction:column;align-items:flex-start;gap:8px;padding:22px!important;background:var(--surface)!important;color:var(--text)!important;border:1px solid var(--line)!important;border-radius:8px;min-width:0;text-align:left}.home-stat strong{font-size:32px;line-height:1.1;font-weight:600}.home-stat span{font-size:13px;color:var(--muted)}.home-stat:hover{border-color:var(--accent)!important}.home-columns{display:grid;grid-template-columns:minmax(0,1.6fr) minmax(260px,1fr);gap:28px}.home-columns>section{min-width:0;padding:22px;border:1px solid var(--line);border-radius:8px}.home-next-item{padding:18px 0;border-top:1px solid var(--line)}.home-next-item h4{font-size:16px;margin:0 0 5px;color:var(--text)}.home-next-item p{font-size:14px;line-height:1.6}.home-next-item button{font-size:13px}.home-tools{display:grid;gap:10px;margin:18px 0}.home-tools a{display:block;padding:14px 16px;border:1px solid var(--line);border-radius:6px;text-decoration:none;color:var(--text);background:var(--surface);font-size:14px;font-weight:500}.home-tools a:hover{background:var(--raised);border-color:var(--accent)}#tester-settings{border:1px solid var(--line);padding:20px;border-radius:8px;margin:20px 0}#tester-settings button{margin-right:10px}@media(max-width:1000px){.home-columns{grid-template-columns:minmax(0,1fr)}.home-stats{grid-template-columns:repeat(2,minmax(0,1fr))}}@media(max-width:600px){#sales-home{padding:18px!important}.home-stats{gap:10px;margin:20px 0}.home-stat{padding:16px!important}.home-stat strong{font-size:27px}.home-welcome h2{font-size:24px}.home-columns>section{padding:16px}.home-columns .section-heading{flex-wrap:wrap;gap:10px}}
