/* Dark mode is the default visual language. The toggle keeps a light option for individual preference. */
:root{color-scheme:dark}
html[data-theme="dark"]{--canvas:#0b1315;--surface:#111c1f;--ink:#e7f0ee;--muted:#91a5a5;--border:#263a3c;--forest:#0c2426;--green:#61c5a0;--lime:#d6f3a9;--orange:#e3a566;--radius:14px}
html[data-theme="dark"] body{background:var(--canvas);color:var(--ink)}
html[data-theme="dark"] .sidebar{background:linear-gradient(180deg,#0d292b 0%,#0a1b1e 100%);border-right:1px solid #1f383a;color:#b4ceca;box-shadow:12px 0 35px #02080945}
html[data-theme="dark"] .brand{color:#f2fbf7}.brand-mark{box-shadow:0 0 0 4px #7bd7b01a}
html[data-theme="dark"] .brand small,.nav-label{color:#86aba3}.nav-item{color:#a7c1bd}.nav-item:hover{background:#ffffff0b;color:#e7f5f0}.nav-item.active{background:#c9efa4;color:#10272a;box-shadow:0 8px 20px #050e0f33}
html[data-theme="dark"] .sidebar-note{border-color:#ffffff1a;background:#ffffff05}.sidebar-note strong{color:#edf8f2}.sidebar-note p{color:#9bbcb3}.sidebar-bottom{border-color:#ffffff16}.sidebar-bottom strong{color:#e3f1ed}.sidebar-bottom small{color:#87a9a0}
html[data-theme="dark"] .workspace{background:var(--canvas)}.topbar{background:color-mix(in srgb,var(--surface) 94%,transparent);border-color:var(--border);backdrop-filter:blur(14px)}
html[data-theme="dark"] .breadcrumb{color:#809794}.breadcrumb strong{color:#d9e8e4}.slash{color:#3c5657}.demo-badge,.shared-badge,.live-badge{color:#9bcab8;background:#16302f;border-color:#284a47}.shared-badge i,.live-badge i{background:#65d3a5}.top-avatar{background:#203a3c;color:#b9efcf}.icon-button:hover{background:#ffffff0b}.notification-dot{border-color:var(--surface)}
html[data-theme="dark"] main{color:var(--ink)}.eyebrow{color:#78a79b}.subtitle{color:#8ca3a1}.context-line,.subtle{color:#79908d}.quiet-link{color:#89ceb2}
html[data-theme="dark"] .card,html[data-theme="dark"] .kpi,html[data-theme="dark"] .pipeline-stat,html[data-theme="dark"] .pipeline-workspace,html[data-theme="dark"] .management-kpi,html[data-theme="dark"] .conversation-list,html[data-theme="dark"] .conversation-detail,html[data-theme="dark"] .timeline-card,html[data-theme="dark"] .contact-card,html[data-theme="dark"] .relationship-card,html[data-theme="dark"] .assistant-main,html[data-theme="dark"] .client-panel,html[data-theme="dark"] .result-panel,html[data-theme="dark"] .context-card,html[data-theme="dark"] .draft-card{background:var(--surface);border-color:var(--border);color:var(--ink);box-shadow:0 14px 40px #02070822}
html[data-theme="dark"] .card:hover,html[data-theme="dark"] .pipeline-stat:hover,html[data-theme="dark"] .management-kpi:hover{border-color:#38595a}
html[data-theme="dark"] .card-heading,.form-heading,.directory-heading,.board-toolbar,.management-card-heading{border-color:var(--border)}html[data-theme="dark"] .card-heading p,html[data-theme="dark"] .directory-heading p,html[data-theme="dark"] .form-heading p{color:#8ca09e}
html[data-theme="dark"] .kpi-top,.kpi-bottom,.stat-label,.stat-note,.management-kpi .kpi-label,.management-kpi p{color:#8ca4a0}.kpi.featured,.management-kpi.featured{background:linear-gradient(135deg,#123b37,#102b2e);border-color:#1f5650}.kpi.featured .kpi-top,.kpi.featured .kpi-bottom,.management-kpi.featured .kpi-label,.management-kpi.featured p{color:#a6d7c5}.kpi-value,.stat-value{color:#e9f5ef}.featured .stat-value,.management-kpi strong{color:#dbf2bd}.trend{background:#193e35;color:#9be0bc}.trend.negative{background:#4a3027;color:#f0b68d}
html[data-theme="dark"] .section-icon,.mini-icon,.metric-icon{background:#173332;color:#76d0ad}.type-option{border-color:#2b4343;background:#121f21}.type-option:has(input:checked){border-color:#63b997;background:#193b35}.type-option strong,.field>span:first-child,.field label{color:#dcebe7}.type-option small,.field em,.field-help,.required-note{color:#839b97}.radio-indicator{border-color:#55716c}.type-option input:checked~.radio-indicator{border-color:#6dd0a5;background:#112022}
html[data-theme="dark"] .field input,html[data-theme="dark"] .field select,html[data-theme="dark"] .field textarea,html[data-theme="dark"] .management-filters input,html[data-theme="dark"] .management-filters select,html[data-theme="dark"] .alerts-panel .field select{background:#0c1719;border-color:#2a4142;color:#e4efec}.field input::placeholder,.field textarea::placeholder{color:#607976}.field input:focus,.field select:focus,.field textarea:focus,.search-control:focus-within{border-color:#5bbd99;box-shadow:0 0 0 3px #5bbd9920}.field [aria-invalid=true]{background:#281b1c;border-color:#d27a7d}.form-actions{background:#0f1b1d;border-color:var(--border)}
html[data-theme="dark"] .primary-button{background:#3f9e7d;border-color:#3f9e7d;color:#071513;box-shadow:0 8px 22px #0b1a1733}.primary-button:hover{background:#5ec59c}.secondary-button{background:#142426;border-color:#2c4546;color:#cce0db}.secondary-button:hover{background:#1d3435;border-color:#47706c}.text-button{color:#87c9aa}.text-button:hover{color:#b6f0cf}
html[data-theme="dark"] .preview-card{background:linear-gradient(145deg,#16342f,#142326);border-color:#2b4d46}.preview-card h2{color:#e2f3e6}.preview-card>p,.preview-line,.preview-footnote{color:#8ca9a0}.preview-divider,.progress-track{background:#29433d}.preview-avatar{background:#234b42;color:#bce8c1;border-color:#ffffff1a}.preview-progress{color:#8ca69d}.preview-progress strong{color:#b9dfa4}.help-card h3{color:#d3e8de}.help-card p,.help-card>div:not(.help-icon){color:#91a8a2}.aside-note{border-color:var(--border);color:#7f9692}
html[data-theme="dark"] .directory-tools select,html[data-theme="dark"] .search-control,html[data-theme="dark"] .pipeline-search,html[data-theme="dark"] .board-filters select{background:#0e1b1d;border-color:#2b4242;color:#cfe1dc}.search-control input,.pipeline-search input{color:#e4efec}.customer-table th,html[data-theme="dark"] th,.management-table th{background:#0d191b;color:#87a29b;border-color:var(--border)}html[data-theme="dark"] .customer-table td,html[data-theme="dark"] td{border-color:#203234;color:#aac0ba}.customer-name,.client-name,.management-table strong{color:#d9eee6}.customer-secondary,.client-work,.table-owner,.management-table small{color:#78918d}.customer-type{background:#183230;border-color:#2e4b46;color:#99cbbb}.empty-state{border-color:var(--border)}.empty-state strong{color:#acd5bd}.empty-state p{color:#809693}.message{background:#173631;border-color:#2d5950;color:#a9ddc2}.message.error{background:#342222;border-color:#714244;color:#f0aaa6}
html[data-theme="dark"] .view-switch,.chart-switch{background:#0d1a1c;border-color:#263d3e}.view-switch button,.chart-switch button{color:#7f9a94}.view-switch button.selected,.chart-switch button.selected{background:#234541;color:#c2efd5;box-shadow:none}.stage-column{background:#0e1c1e;border-color:#294040}.stage-column.kind-won{background:#102a23;border-color:#285441}.stage-column.kind-lost{background:#291f1d;border-color:#4a342d}.stage-counter,.deal-card,.stage-empty{background:#142224;border-color:#2b4444}.deal-card:hover{border-color:#55ad8f;box-shadow:0 10px 30px #02080955}.stage-title-line h2,.stage-total,.deal-amount{color:#c7e2d8}.stage-subtitle,.deal-date,.deal-contact,.stat-note{color:#78918c}.board-caption,.board-footer,.drag-tip{color:#7f9994}.kanban{scrollbar-color:#315452 #0c1719}.conversion-panel,.metric-explanation,.banner,.pipeline-note{background:#132525;border-color:#294845;color:#9bc9b3}.banner.error{background:#342323;border-color:#724341;color:#f0aaa6}.deal-dialog,.move-dialog,.stages-dialog,html[data-theme="dark"] dialog{background:#111d1f;border-color:#304647;color:#e7f0ee}.modal-header,.modal-actions{border-color:var(--border)}.modal-header p,.modal-footnote,.stage-help{color:#89a29c}
html[data-theme="dark"] .conversation-row{border-color:#223738;background:transparent;color:#d9ebe5}.conversation-row:hover,.conversation-row.selected{background:#173331;border-color:#4b8f79}.row-phone,.row-status,.message-note,.chat-footnote{color:#7e9994}.chat-message{background:#14292a;border-color:#29504c}.chat-message:nth-child(even){background:#122123}.connection-banner,.setup-notice,.setup-security{background:#14312c;border-color:#2b554b;color:#a8dbc0}.connection-tag,.setup-number.ready{background:#235644;color:#bce9c5}.conversation-pagination,.messages-toolbar{border-color:var(--border)}
html[data-theme="dark"] .management-card-heading h2,.goal-title,.stage-title,.forecast-total strong{color:#d4edc8}.management-filters input,.management-filters select{color:#acd2c0}.management-page .management-table td{border-color:#203537;color:#a8c5b8}.member-avatar{background:#1c3734;color:#a9ddb8}.team-progress,.stage-track,.forecast-split{background:#1b3231}.team-progress i,.stage-track i{background:#6cad8a}.goal-status,.allocation-preview,.goal-form-help,.team-goal-field{background:#172d2a;border-color:#2a4b45;color:#a2cdb8}.goal-status.behind,.month-alert{background:#382e22;border-color:#66503a;color:#e1b985}.alert-chip{background:#172827;border-color:#2b4946;color:#96bcb0}.alert-chip.active{background:#224b3e;border-color:#4b8e72;color:#c5efd7}.alert-row{border-color:#203638}.alert-row:hover{background:#142725}.alert-symbol{background:#3b3122;color:#e0bd85}.alert-row strong{color:#d2e7df}.alert-row p,.alert-empty,.forecast-note,.data-method-note{color:#849e98}.reason-tags span{background:#332d24;color:#d1b480}.management-page .setup-notice{background:#15342f;color:#a8dabe}.management-goal-ring .ring-base{stroke:#203b38}.management-goal-ring .ring-value{stroke:#6fbe93}.chart-gridline{stroke:#29403f}.chart-label{fill:#809a95}.chart-line{stroke:#6fc29c}.chart-goal{stroke:#678e7b}.chart-point{fill:#75c89e;stroke:#0f1b1d}.chart-point:hover,.chart-point:focus{fill:#d4f4a9;stroke:#539477}
html[data-theme="dark"] .notification-popover{background:#111d1f;border-color:#304647;box-shadow:0 20px 60px #0008}.notice{border-color:#253b3c}.notice strong,.notice-title{color:#d2e9df}.notice p{color:#8ba49f}.notice small{color:#748e89}.notice-icon{background:#3b3021;color:#e3bd7f}.notice.blue .notice-icon{background:#203243;color:#9fc5e6}.notice.green .notice-icon{background:#1b3a31;color:#9dd5ae}.activity-item p{color:#9ab3ac}.activity-item strong{color:#d7eee5}.activity-item small{color:#76908b}.page-footer{color:#708985}
html[data-theme="dark"] .theme-toggle{color:#a7d9c1;background:#142827;border-color:#2d504a}.theme-toggle:hover{background:#1d3a35;border-color:#4d8b72}.theme-toggle:focus-visible{outline-color:#72cba3}
html[data-theme="dark"] .toast,.client-toast,.pipeline-toast{background:#183f36;color:#d8f4e2;box-shadow:0 12px 35px #0008}.skip{background:#d7f3b2;color:#132b25}
.theme-toggle{display:inline-flex;align-items:center;gap:7px;min-height:34px;padding:7px 10px;border:1px solid #e1e8e3;border-radius:9px;background:#f6f8f6;color:#466b5a;font:600 11px var(--sans);white-space:nowrap;cursor:pointer;transition:background .2s,border-color .2s,transform .2s}.theme-toggle:hover{transform:translateY(-1px);background:#eef5f0}.theme-toggle>span:first-child{font-size:15px;line-height:1}.theme-toggle>span:last-child{font-size:10px;letter-spacing:.2px}
@media(max-width:760px){.theme-toggle{font-size:0;padding:8px;width:34px;justify-content:center}.theme-toggle>span:first-child{font-size:16px}.top-actions{gap:8px}}
@media(prefers-reduced-motion:reduce){.theme-toggle{transition:none}}

/* Keep the original light palette intact when the user switches away from dark mode. */
html:not([data-theme="dark"]){color-scheme:light}
html:not([data-theme="dark"]) body{background:#f5f7f8;color:#202d31}
html:not([data-theme="dark"]) .brand-mark{box-shadow:none}
html:not([data-theme="dark"]) .brand small{color:#a5bfb3}
html:not([data-theme="dark"]) .nav-label{color:#82a696}
html:not([data-theme="dark"]) .nav-item{color:#b3cbc0}
html:not([data-theme="dark"]) .nav-item:hover{background:#ffffff0d;color:inherit}
html:not([data-theme="dark"]) .sidebar-note strong{color:#ecf5ef}
html:not([data-theme="dark"]) .sidebar-note p{color:#a3beaf}
html:not([data-theme="dark"]) .sidebar-bottom strong{color:#e1ece5}
html:not([data-theme="dark"]) .sidebar-bottom small{color:#91ae9e}
html:not([data-theme="dark"]) .workspace{background:#f5f7f8}
html:not([data-theme="dark"]) .topbar{background:#fff;border-color:#e9edef;backdrop-filter:none}
html:not([data-theme="dark"]) .breadcrumb{color:#7e898d}
html:not([data-theme="dark"]) .breadcrumb strong{color:#354348}
html:not([data-theme="dark"]) .slash{color:#ccd2d5}
html:not([data-theme="dark"]) .demo-badge,html:not([data-theme="dark"]) .shared-badge,html:not([data-theme="dark"]) .live-badge{color:#718078;background:#f1f5f2;border-color:#e7eee8}
html:not([data-theme="dark"]) .shared-badge i,html:not([data-theme="dark"]) .live-badge i{background:#63a87b}
html:not([data-theme="dark"]) .top-avatar{background:#e4eee7;color:#48634e}
html:not([data-theme="dark"]) .icon-button:hover{background:#f0f4f2}
html:not([data-theme="dark"]) .notification-dot{border-color:#fff}
html:not([data-theme="dark"]) main{color:#202d31}
html:not([data-theme="dark"]) .eyebrow{color:#85928c}
html:not([data-theme="dark"]) .subtitle{color:#788780}
html:not([data-theme="dark"]) .context-line,html:not([data-theme="dark"]) .subtle{color:#78877e}
html:not([data-theme="dark"]) .quiet-link{color:#698574}
html:not([data-theme="dark"]) .card-heading,html:not([data-theme="dark"]) .form-heading,html:not([data-theme="dark"]) .directory-heading,html:not([data-theme="dark"]) .board-toolbar,html:not([data-theme="dark"]) .management-card-heading{border-color:#e9edef}
html:not([data-theme="dark"]) .card-heading p,html:not([data-theme="dark"]) .directory-heading p,html:not([data-theme="dark"]) .form-heading p{color:#7c8a82}
html:not([data-theme="dark"]) .kpi-top,html:not([data-theme="dark"]) .kpi-bottom,html:not([data-theme="dark"]) .stat-label,html:not([data-theme="dark"]) .stat-note,html:not([data-theme="dark"]) .management-kpi .kpi-label,html:not([data-theme="dark"]) .management-kpi p{color:#74827c}
html:not([data-theme="dark"]) .kpi-value,html:not([data-theme="dark"]) .stat-value{color:#202d31}
html:not([data-theme="dark"]) .kpi.featured,html:not([data-theme="dark"]) .management-kpi.featured{background:#123e35;border-color:#123e35;color:#fff}
html:not([data-theme="dark"]) .kpi.featured .kpi-top,html:not([data-theme="dark"]) .kpi.featured .kpi-bottom,html:not([data-theme="dark"]) .management-kpi.featured .kpi-label,html:not([data-theme="dark"]) .management-kpi.featured p{color:#c1d8c9}
html:not([data-theme="dark"]) .kpi.featured .stat-value,html:not([data-theme="dark"]) .management-kpi.featured strong{color:#fff}
html:not([data-theme="dark"]) .trend{background:#eef7f1;color:#25805e}
html:not([data-theme="dark"]) .trend.negative{background:#fae6d9;color:#965f33}
html:not([data-theme="dark"]) .section-icon,html:not([data-theme="dark"]) .mini-icon,html:not([data-theme="dark"]) .metric-icon{background:#f1f6f2;color:#6a8c73}
html:not([data-theme="dark"]) .type-option{border-color:#e0e7e4;background:#fff;color:#202d31}
html:not([data-theme="dark"]) .type-option:has(input:checked){border-color:#458369;background:#f1f7f3}
html:not([data-theme="dark"]) .type-option strong,html:not([data-theme="dark"]) .field>span:first-child,html:not([data-theme="dark"]) .field label{color:#425c4b}
html:not([data-theme="dark"]) .type-option small,html:not([data-theme="dark"]) .field em,html:not([data-theme="dark"]) .field-help,html:not([data-theme="dark"]) .required-note{color:#839086}
html:not([data-theme="dark"]) .radio-indicator{border-color:#9ab3a5}
html:not([data-theme="dark"]) .type-option input:checked~.radio-indicator{border-color:#5b9c75;background:#eaf5ec}
html:not([data-theme="dark"]) .field input,html:not([data-theme="dark"]) .field select,html:not([data-theme="dark"]) .field textarea,html:not([data-theme="dark"]) .management-filters input,html:not([data-theme="dark"]) .management-filters select,html:not([data-theme="dark"]) .alerts-panel .field select{background:#fff;border-color:#dfe6e2;color:#263b30}
html:not([data-theme="dark"]) .field input::placeholder,html:not([data-theme="dark"]) .field textarea::placeholder{color:#98a29e}
html:not([data-theme="dark"]) .field input:focus,html:not([data-theme="dark"]) .field select:focus,html:not([data-theme="dark"]) .field textarea:focus,html:not([data-theme="dark"]) .search-control:focus-within{border-color:#548d70;box-shadow:0 0 0 3px #548d7020}
html:not([data-theme="dark"]) .field [aria-invalid=true]{background:#fff;border-color:#d27a7d}
html:not([data-theme="dark"]) .form-actions{background:#fbfcfb;border-color:#e9edef}
html:not([data-theme="dark"]) .primary-button{background:#123e35;border-color:#123e35;color:#fff;box-shadow:0 8px 22px #123e3526}
html:not([data-theme="dark"]) .primary-button:hover{background:#1b5b4b}
html:not([data-theme="dark"]) .secondary-button{background:#fff;border-color:#e0e6e2;color:#466052}
html:not([data-theme="dark"]) .secondary-button:hover{background:#f1f5f2;border-color:#cbdad0}
html:not([data-theme="dark"]) .text-button{color:#698574}
html:not([data-theme="dark"]) .text-button:hover{color:#218060}
html:not([data-theme="dark"]) .preview-card{background:#edf5ec;border-color:#dfe8dc}
html:not([data-theme="dark"]) .preview-card h2{color:#2e4838}
html:not([data-theme="dark"]) .preview-card>p,html:not([data-theme="dark"]) .preview-line,html:not([data-theme="dark"]) .preview-footnote{color:#829480}
html:not([data-theme="dark"]) .preview-divider,html:not([data-theme="dark"]) .progress-track{background:#dce5d7}
html:not([data-theme="dark"]) .preview-avatar{background:#dce8d5;color:#547d4f;border-color:#fff}
html:not([data-theme="dark"]) .preview-progress{color:#6c806c}
html:not([data-theme="dark"]) .preview-progress strong{color:#54784f}
html:not([data-theme="dark"]) .help-card h3{color:#50604f}
html:not([data-theme="dark"]) .help-card p,html:not([data-theme="dark"]) .help-card>div:not(.help-icon){color:#829084}
html:not([data-theme="dark"]) .aside-note{border-color:#e4e9e2;color:#7f8e80}
html:not([data-theme="dark"]) .directory-tools select,html:not([data-theme="dark"]) .search-control,html:not([data-theme="dark"]) .pipeline-search,html:not([data-theme="dark"]) .board-filters select{background:#fff;border-color:#e0e7e4;color:#43564c}
html:not([data-theme="dark"]) .search-control input,html:not([data-theme="dark"]) .pipeline-search input{color:#263b30}
html:not([data-theme="dark"]) .customer-table th,html:not([data-theme="dark"]) th,html:not([data-theme="dark"]) .management-table th{background:#fafbfa;color:#93a096;border-color:#e9edef}
html:not([data-theme="dark"]) .customer-table td,html:not([data-theme="dark"]) td{border-color:#f0f3f1;color:#7a8b83}
html:not([data-theme="dark"]) .customer-name,html:not([data-theme="dark"]) .client-name,html:not([data-theme="dark"]) .management-table strong{color:#40534a}
html:not([data-theme="dark"]) .customer-secondary,html:not([data-theme="dark"]) .client-work,html:not([data-theme="dark"]) .table-owner,html:not([data-theme="dark"]) .management-table small{color:#94a096}
html:not([data-theme="dark"]) .customer-type{background:#f1f6f2;border-color:#dfe8df;color:#5a8064}
html:not([data-theme="dark"]) .empty-state{border-color:#eef1ed}
html:not([data-theme="dark"]) .empty-state strong{color:#61745e}
html:not([data-theme="dark"]) .empty-state p{color:#98a294}
html:not([data-theme="dark"]) .message{background:#eef6ef;border-color:#d6e8d9;color:#47735a}
html:not([data-theme="dark"]) .message.error{background:#fff2ef;border-color:#f0d3cc;color:#b4685d}
html:not([data-theme="dark"]) .view-switch,html:not([data-theme="dark"]) .chart-switch{background:#f4f6f2;border-color:#e4e9e2}
html:not([data-theme="dark"]) .view-switch button,html:not([data-theme="dark"]) .chart-switch button{color:#7c8c83}
html:not([data-theme="dark"]) .view-switch button.selected,html:not([data-theme="dark"]) .chart-switch button.selected{background:#fff;color:#47725b;box-shadow:0 2px 7px #17382e12}
html:not([data-theme="dark"]) .stage-column{background:#f7f9f7;border-color:#e2e9e3}
html:not([data-theme="dark"]) .stage-column.kind-won{background:#f0f7ef;border-color:#d9e9d5}
html:not([data-theme="dark"]) .stage-column.kind-lost{background:#fcf5f0;border-color:#efddd2}
html:not([data-theme="dark"]) .stage-counter,html:not([data-theme="dark"]) .deal-card,html:not([data-theme="dark"]) .stage-empty{background:#fff;border-color:#e0e7e4}
html:not([data-theme="dark"]) .deal-card:hover{border-color:#70a986;box-shadow:0 10px 30px #1b49321c}
html:not([data-theme="dark"]) .stage-title-line h2,html:not([data-theme="dark"]) .stage-total,html:not([data-theme="dark"]) .deal-amount{color:#3b5645}
html:not([data-theme="dark"]) .stage-subtitle,html:not([data-theme="dark"]) .deal-date,html:not([data-theme="dark"]) .deal-contact,html:not([data-theme="dark"]) .stat-note{color:#7c8b83}
html:not([data-theme="dark"]) .board-caption,html:not([data-theme="dark"]) .board-footer,html:not([data-theme="dark"]) .drag-tip{color:#7f8d84}
html:not([data-theme="dark"]) .kanban{scrollbar-color:#b8cdbd #eef3ee}
html:not([data-theme="dark"]) .conversion-panel,html:not([data-theme="dark"]) .metric-explanation,html:not([data-theme="dark"]) .banner,html:not([data-theme="dark"]) .pipeline-note{background:#edf5ec;border-color:#d9e8d6;color:#5c7b5e}
html:not([data-theme="dark"]) .banner.error{background:#fff4ef;border-color:#eed7cf;color:#a66b5e}
html:not([data-theme="dark"]) .deal-dialog,html:not([data-theme="dark"]) .move-dialog,html:not([data-theme="dark"]) .stages-dialog,html:not([data-theme="dark"]) dialog{background:#fff;border-color:#dfe6e2;color:#202d31}
html:not([data-theme="dark"]) .modal-header,html:not([data-theme="dark"]) .modal-actions{border-color:#e9edef}
html:not([data-theme="dark"]) .modal-header p,html:not([data-theme="dark"]) .modal-footnote,html:not([data-theme="dark"]) .stage-help{color:#7f8e84}
html:not([data-theme="dark"]) .conversation-row{border-color:#eef1ef;background:transparent;color:#40534a}
html:not([data-theme="dark"]) .conversation-row:hover,html:not([data-theme="dark"]) .conversation-row.selected{background:#f1f7f2;border-color:#b9d5c1}
html:not([data-theme="dark"]) .row-phone,html:not([data-theme="dark"]) .row-status,html:not([data-theme="dark"]) .message-note,html:not([data-theme="dark"]) .chat-footnote{color:#7e9185}
html:not([data-theme="dark"]) .chat-message{background:#f3f7f3;border-color:#dbe8dc}
html:not([data-theme="dark"]) .chat-message:nth-child(even){background:#f8faf8}
html:not([data-theme="dark"]) .connection-banner,html:not([data-theme="dark"]) .setup-notice,html:not([data-theme="dark"]) .setup-security{background:#eef7f1;border-color:#d4e8d8;color:#4f7b5d}
html:not([data-theme="dark"]) .connection-tag,html:not([data-theme="dark"]) .setup-number.ready{background:#dceede;color:#477d58}
html:not([data-theme="dark"]) .conversation-pagination,html:not([data-theme="dark"]) .messages-toolbar{border-color:#e9edef}
html:not([data-theme="dark"]) .management-card-heading h2,html:not([data-theme="dark"]) .goal-title,html:not([data-theme="dark"]) .stage-title,html:not([data-theme="dark"]) .forecast-total strong{color:#405e3b}
html:not([data-theme="dark"]) .management-filters input,html:not([data-theme="dark"]) .management-filters select{color:#4b6b55}
html:not([data-theme="dark"]) .management-page .management-table td{border-color:#edf1ed;color:#617b6a}
html:not([data-theme="dark"]) .member-avatar{background:#e6eee3;color:#7a946b}
html:not([data-theme="dark"]) .team-progress,html:not([data-theme="dark"]) .stage-track,html:not([data-theme="dark"]) .forecast-split{background:#e4eee4}
html:not([data-theme="dark"]) .team-progress i,html:not([data-theme="dark"]) .stage-track i{background:#5b9c75}
html:not([data-theme="dark"]) .goal-status,html:not([data-theme="dark"]) .allocation-preview,html:not([data-theme="dark"]) .goal-form-help,html:not([data-theme="dark"]) .team-goal-field{background:#f2f7ea;border-color:#dce8cf;color:#6a815b}
html:not([data-theme="dark"]) .goal-status.behind,html:not([data-theme="dark"]) .month-alert{background:#fff6e7;border-color:#f0dfbd;color:#a77b3d}
html:not([data-theme="dark"]) .alert-chip{background:#f1f6f2;border-color:#dfe8df;color:#64816b}
html:not([data-theme="dark"]) .alert-chip.active{background:#e2f1e5;border-color:#b9d9c0;color:#477d58}
html:not([data-theme="dark"]) .alert-row{border-color:#edf1ed}
html:not([data-theme="dark"]) .alert-row:hover{background:#f7faf7}
html:not([data-theme="dark"]) .alert-symbol{background:#fff4e2;color:#c7994a}
html:not([data-theme="dark"]) .alert-row strong{color:#4b6152}
html:not([data-theme="dark"]) .alert-row p,html:not([data-theme="dark"]) .alert-empty,html:not([data-theme="dark"]) .forecast-note,html:not([data-theme="dark"]) .data-method-note{color:#7b8b7f}
html:not([data-theme="dark"]) .reason-tags span{background:#fff3df;color:#b3803c}
html:not([data-theme="dark"]) .management-page .setup-notice{background:#eef7f1;color:#4f7b5d}
html:not([data-theme="dark"]) .management-goal-ring .ring-base{stroke:#e1eae0}
html:not([data-theme="dark"]) .management-goal-ring .ring-value{stroke:#5b9c75}
html:not([data-theme="dark"]) .chart-gridline{stroke:#e1e9e2}
html:not([data-theme="dark"]) .chart-label{fill:#89968d}
html:not([data-theme="dark"]) .chart-line{stroke:#348b71}
html:not([data-theme="dark"]) .chart-goal{stroke:#8ab49a}
html:not([data-theme="dark"]) .chart-point{fill:transparent;stroke:transparent}
html:not([data-theme="dark"]) .chart-point:hover,html:not([data-theme="dark"]) .chart-point:focus{fill:#358260;stroke:#fff}
html:not([data-theme="dark"]) .notification-popover{background:#fff;border-color:#e9edef;box-shadow:0 12px 45px #163b3521}
html:not([data-theme="dark"]) .notice{border-color:#eff2ef}
html:not([data-theme="dark"]) .notice strong,html:not([data-theme="dark"]) .notice-title{color:#536558}
html:not([data-theme="dark"]) .notice p{color:#7b8b7f}
html:not([data-theme="dark"]) .notice small{color:#7e8e81}
html:not([data-theme="dark"]) .notice-icon{background:#fff4e2;color:#c7994a}
html:not([data-theme="dark"]) .notice.blue .notice-icon{background:#edf2fa;color:#8298bf}
html:not([data-theme="dark"]) .notice.green .notice-icon{background:#eef6ef;color:#6e9970}
html:not([data-theme="dark"]) .activity-item p{color:#7b8b7e}
html:not([data-theme="dark"]) .activity-item strong{color:#455c4b}
html:not([data-theme="dark"]) .activity-item small{color:#a1aca2}
html:not([data-theme="dark"]) .page-footer{color:#9ba59f}
html:not([data-theme="dark"]) .toast,html:not([data-theme="dark"]) .client-toast,html:not([data-theme="dark"]) .pipeline-toast{background:#123e35;color:#fff;box-shadow:0 12px 35px #163b3526}

/* Athos Gran visual language: monochrome stone, editorial type and architectural lines. */
:root{--canvas:#f4f3ef;--surface:#fff;--ink:#202020;--muted:#85847e;--border:#deddd7;--forest:#080808;--green:#44443f;--lime:#f2f1ea;--orange:#b9ab96;--radius:8px}
html[data-theme="dark"]{--canvas:#080808;--surface:#111110;--ink:#f0f0eb;--muted:#999991;--border:#2b2b28;--forest:#050505;--green:#d8d8d1;--lime:#f2f1ea;--orange:#c4b9a6;--radius:8px}
html[data-theme="dark"] body{background:radial-gradient(circle at 82% 3%,#191916 0,#080808 34%),#080808}
html[data-theme="dark"] .sidebar{background:linear-gradient(180deg,#121211 0%,#050505 100%);border-right-color:#2b2b28;color:#c4c4bd;box-shadow:12px 0 35px #00000080}
html[data-theme="dark"] .brand{color:#f5f5ef;letter-spacing:-.2px}.brand-mark{border-color:#8c8c85;color:#f5f5ef;box-shadow:none}
html[data-theme="dark"] .brand-mark{font-size:0}.brand-mark::after{content:'AG';font:700 15px/1 var(--display);letter-spacing:-1px;color:currentColor}
html[data-theme="dark"] .brand small{color:#a9a9a1}.nav-label{color:#8f8f88}.nav-item{color:#b9b9b1;letter-spacing:.15px}.nav-item:hover{background:#ffffff0d;color:#f2f2ed}.nav-item.active{background:#f1f0e9;color:#090909;box-shadow:0 8px 24px #00000066}
html[data-theme="dark"] .sidebar-note{border-color:#3a3a36;background:#ffffff04}.sidebar-note strong{color:#efefe9}.sidebar-note p{color:#a8a8a0}.sidebar-bottom{border-color:#30302d}.sidebar-bottom strong{color:#e3e3dc}.sidebar-bottom small{color:#96968f}.stone-lines{border-color:#77776f;box-shadow:0 0 0 15px #ffffff04,0 0 0 30px #ffffff04}
html[data-theme="dark"] .workspace{background:transparent}.topbar{background:color-mix(in srgb,#0a0a09 94%,transparent);border-color:#2b2b28;backdrop-filter:blur(16px)}
html[data-theme="dark"] .breadcrumb{color:#92928b}.breadcrumb strong{color:#e6e6df}.slash{color:#585852}.demo-badge,html[data-theme="dark"] .shared-badge,html[data-theme="dark"] .live-badge{color:#d4d4cb;background:#1b1b19;border-color:#393934}.shared-badge i,.live-badge i{background:#eeeDE5}.top-avatar{background:#292925;color:#f2f1ea}.icon-button:hover{background:#ffffff0d}.notification-dot{border-color:#111110;background:#c4b9a6}
html[data-theme="dark"] main{color:#f0f0eb}.eyebrow{color:#a7a79f;letter-spacing:1.8px}.subtitle{color:#a2a29a}.context-line,html[data-theme="dark"] .subtle{color:#85857e}.quiet-link{color:#d8d8d1}
html[data-theme="dark"] .card,html[data-theme="dark"] .kpi,html[data-theme="dark"] .pipeline-stat,html[data-theme="dark"] .pipeline-workspace,html[data-theme="dark"] .management-kpi,html[data-theme="dark"] .conversation-list,html[data-theme="dark"] .conversation-detail,html[data-theme="dark"] .timeline-card,html[data-theme="dark"] .contact-card,html[data-theme="dark"] .relationship-card,html[data-theme="dark"] .assistant-main,html[data-theme="dark"] .client-panel,html[data-theme="dark"] .result-panel,html[data-theme="dark"] .context-card,html[data-theme="dark"] .draft-card{background:#111110;border-color:#2b2b28;box-shadow:0 16px 42px #00000052}
html[data-theme="dark"] .card:hover,html[data-theme="dark"] .pipeline-stat:hover,html[data-theme="dark"] .management-kpi:hover{border-color:#53534c}
html[data-theme="dark"] .card-heading,html[data-theme="dark"] .form-heading,html[data-theme="dark"] .directory-heading,html[data-theme="dark"] .board-toolbar,html[data-theme="dark"] .management-card-heading{border-color:#2b2b28}html[data-theme="dark"] .card-heading p,html[data-theme="dark"] .directory-heading p,html[data-theme="dark"] .form-heading p{color:#94948c}
html[data-theme="dark"] .kpi-top,html[data-theme="dark"] .kpi-bottom,html[data-theme="dark"] .stat-label,html[data-theme="dark"] .stat-note,html[data-theme="dark"] .management-kpi .kpi-label,html[data-theme="dark"] .management-kpi p{color:#a0a098}.kpi.featured,html[data-theme="dark"] .management-kpi.featured{background:linear-gradient(135deg,#24241f,#141412);border-color:#4a4a42}.kpi.featured .kpi-top,.kpi.featured .kpi-bottom,.management-kpi.featured .kpi-label,.management-kpi.featured p{color:#d4d4cb}.kpi-value,.stat-value{color:#f1f1eb}.featured .stat-value,html[data-theme="dark"] .management-kpi strong{color:#f2f1ea}.trend{background:#282823;color:#e4e3d9}.trend.negative{background:#3a3027;color:#d9c0a0}
html[data-theme="dark"] .section-icon,html[data-theme="dark"] .mini-icon,html[data-theme="dark"] .metric-icon{background:#24241f;color:#d9d8ce}.type-option{border-color:#373733;background:#151514}.type-option:has(input:checked){border-color:#d7d6cc;background:#24241f}.type-option strong,html[data-theme="dark"] .field>span:first-child,html[data-theme="dark"] .field label{color:#e2e2db}.type-option small,html[data-theme="dark"] .field em,html[data-theme="dark"] .field-help,html[data-theme="dark"] .required-note{color:#92928a}.radio-indicator{border-color:#787871}.type-option input:checked~.radio-indicator{border-color:#e7e6dd;background:#151514}
html[data-theme="dark"] .field input,html[data-theme="dark"] .field select,html[data-theme="dark"] .field textarea,html[data-theme="dark"] .management-filters input,html[data-theme="dark"] .management-filters select,html[data-theme="dark"] .alerts-panel .field select{background:#0d0d0c;border-color:#393936;color:#ededE6}.field input::placeholder,.field textarea::placeholder{color:#74746d}.field input:focus,.field select:focus,.field textarea:focus,.search-control:focus-within{border-color:#e1e0d6;box-shadow:0 0 0 3px #f2f1ea1f}.field [aria-invalid=true]{background:#261b1b;border-color:#cc8581}.form-actions{background:#0d0d0c;border-color:#2b2b28}
html[data-theme="dark"] .primary-button{background:#f0efe8;border-color:#f0efe8;color:#090909;box-shadow:0 8px 22px #00000055}.primary-button:hover{background:#fff}.secondary-button{background:#171715;border-color:#484842;color:#e8e8e1}.secondary-button:hover{background:#292925;border-color:#707069}.text-button{color:#c9c8bf}.text-button:hover{color:#fff}
html[data-theme="dark"] .preview-card{background:linear-gradient(145deg,#20201c,#121211);border-color:#484840}.preview-card h2{color:#f0efe8}.preview-card>p,.preview-line,.preview-footnote{color:#aaa9a0}.preview-divider,.progress-track{background:#3a3a34}.preview-avatar{background:#2d2d28;color:#f0efe8;border-color:#ffffff18}.preview-progress{color:#aaa9a0}.preview-progress strong{color:#e1e0d6}.help-card h3{color:#e5e4dc}.help-card p,.help-card>div:not(.help-icon){color:#9d9d95}.aside-note{border-color:#2b2b28;color:#888880}
html[data-theme="dark"] .directory-tools select,html[data-theme="dark"] .search-control,html[data-theme="dark"] .pipeline-search,html[data-theme="dark"] .board-filters select{background:#0f0f0e;border-color:#393936;color:#d7d6cd}.search-control input,.pipeline-search input{color:#eeeeE7}.customer-table th,html[data-theme="dark"] th,.management-table th{background:#171715;color:#a2a29a;border-color:#2b2b28}html[data-theme="dark"] .customer-table td,html[data-theme="dark"] td{border-color:#292926;color:#b8b8b0}.customer-name,.client-name,.management-table strong{color:#efefe8}.customer-secondary,.client-work,.table-owner,.management-table small{color:#898981}.customer-type{background:#24241f;border-color:#494941;color:#d7d6cd}.empty-state{border-color:#2b2b28}.empty-state strong{color:#deddd4}.empty-state p{color:#92928a}.message{background:#24241f;border-color:#4a4a41;color:#d7d6cd}.message.error{background:#342120;border-color:#704441;color:#e0aaa3}
html[data-theme="dark"] .view-switch,html[data-theme="dark"] .chart-switch{background:#161615;border-color:#353530}.view-switch button,.chart-switch button{color:#999991}.view-switch button.selected,.chart-switch button.selected{background:#32322c;color:#f0efe8;box-shadow:none}.stage-column{background:#141413;border-color:#373733}.stage-column.kind-won{background:#1b211d;border-color:#424d40}.stage-column.kind-lost{background:#241c1a;border-color:#554139}.stage-counter,.deal-card,.stage-empty{background:#1c1c1a;border-color:#3b3b36}.deal-card:hover{border-color:#c4c3b8;box-shadow:0 10px 30px #00000077}.stage-title-line h2,.stage-total,.deal-amount{color:#e2e1d9}.stage-subtitle,.deal-date,.deal-contact,.stat-note{color:#96968e}.board-caption,.board-footer,.drag-tip{color:#8e8e86}.kanban{scrollbar-color:#66665d #0f0f0e}.conversion-panel,.metric-explanation,.banner,.pipeline-note{background:#1c1c19;border-color:#44443c;color:#cfcec3}.banner.error{background:#342120;border-color:#704441;color:#e0aaa3}.deal-dialog,.move-dialog,.stages-dialog,html[data-theme="dark"] dialog{background:#111110;border-color:#484840;color:#f0f0eb}.modal-header,.modal-actions{border-color:#2b2b28}.modal-header p,.modal-footnote,.stage-help{color:#96968e}
html[data-theme="dark"] .conversation-row{border-color:#292926;background:transparent;color:#e2e1da}.conversation-row:hover,.conversation-row.selected{background:#252520;border-color:#77776d}.row-phone,.row-status,.message-note,.chat-footnote{color:#96968e}.chat-message{background:#20201c;border-color:#45453d}.chat-message:nth-child(even){background:#171715}.connection-banner,.setup-notice,.setup-security{background:#20201c;border-color:#47473f;color:#d0cfc5}.connection-tag,.setup-number.ready{background:#35352e;color:#ecebe3}.conversation-pagination,.messages-toolbar{border-color:#2b2b28}
html[data-theme="dark"] .management-card-heading h2,.goal-title,.stage-title,.forecast-total strong{color:#e9e8df}.management-filters input,.management-filters select{color:#d2d1c8}.management-page .management-table td{border-color:#2b2b28;color:#b9b9b0}.member-avatar{background:#2b2b26;color:#e6e5dc}.team-progress,.stage-track,.forecast-split{background:#31312a}.team-progress i,.stage-track i{background:#d1d0c5}.goal-status,.allocation-preview,.goal-form-help,.team-goal-field{background:#24241f;border-color:#45453d;color:#d0cfc5}.goal-status.behind,.month-alert{background:#3a3026;border-color:#65513b;color:#dfc49d}.alert-chip{background:#20201c;border-color:#44443c;color:#c6c5bb}.alert-chip.active{background:#35352e;border-color:#77776a;color:#f0efe8}.alert-row{border-color:#2b2b28}.alert-row:hover{background:#20201c}.alert-symbol{background:#3a3026;color:#dfc49d}.alert-row strong{color:#e2e1d9}.alert-row p,.alert-empty,.forecast-note,.data-method-note{color:#999990}.reason-tags span{background:#3a3026;color:#dbc49e}.management-page .setup-notice{background:#20201c;color:#d0cfc5}.management-goal-ring .ring-base{stroke:#383832}.management-goal-ring .ring-value{stroke:#d1d0c5}.chart-gridline{stroke:#363630}.chart-label{fill:#92928a}.chart-line{stroke:#efeee6}.chart-goal{stroke:#9f9f95}.chart-point{fill:#f1f0e8;stroke:#111110}.chart-point:hover,.chart-point:focus{fill:#fff;stroke:#aaa99f}
html[data-theme="dark"] .management-goal-ring strong{color:#e9e8df}.management-goal-ring span{color:#aaa9a0}.goal-amounts{border-color:#2b2b28}.goal-amounts span{color:#aaa9a0}.goal-amounts strong{color:#deddd5}.management-card-heading>.icon{color:#d2d1c8}.period-caption{color:#aaa9a0}.live-dot{background:#e8e7de}.quiet-badge{background:#24241f;color:#c7c6bc}.forecast-total span,.forecast-total .estimate-tag{color:#aaa9a0}.forecast-total .estimate-tag{background:#2b2b25}.forecast-breakdown>div{border-color:#2b2b28;color:#a3a39b}.forecast-breakdown strong,.micro-metrics strong{color:#d3d2c8}.micro-metrics{border-color:#2b2b28}.micro-metrics span{color:#a3a39b}.stage-row-heading,.stage-row-heading strong{color:#b1b1a8}.stage-total{border-color:#2b2b28;color:#aaa9a0}.stage-total strong{color:#d3d2c8}
html[data-theme="dark"] .notification-popover{background:#111110;border-color:#484840;box-shadow:0 20px 60px #000}.notice{border-color:#30302d}.notice strong,.notice-title{color:#e2e1d9}.notice p{color:#a2a29a}.notice small{color:#898981}.notice-icon{background:#3a3026;color:#dfc49d}.notice.blue .notice-icon{background:#293039;color:#bac8d3}.notice.green .notice-icon{background:#2b2b26;color:#d2d1c8}.activity-item p{color:#a4a49b}.activity-item strong{color:#e5e4dc}.activity-item small{color:#8b8b83}.page-footer{color:#85857d}
html[data-theme="dark"] .theme-toggle{color:#e2e1d9;background:#1d1d1a;border-color:#4b4b43}.theme-toggle:hover{background:#30302a;border-color:#8d8c81}.theme-toggle:focus-visible{outline-color:#efeee5}
html[data-theme="dark"] .toast,html[data-theme="dark"] .client-toast,html[data-theme="dark"] .pipeline-toast{background:#efeee6;color:#090909;box-shadow:0 12px 35px #00000099}.skip{background:#efeee6;color:#090909}

html:not([data-theme="dark"]) .brand-mark{font-size:0;color:#161615}.brand-mark::after{content:'AG';font:700 15px/1 var(--display);letter-spacing:-1px;color:currentColor}
html:not([data-theme="dark"]) .nav-item.active{background:#111110;color:#f1f0e9;box-shadow:0 8px 24px #00000022}
html:not([data-theme="dark"]) .primary-button{background:#111110;border-color:#111110;color:#f1f0e9}.primary-button:hover{background:#2a2a26}.secondary-button{border-color:#cfcfc8;color:#292925}.secondary-button:hover{background:#f0efe9;border-color:#a5a49b}
