/* Finance presentation only. No permissions, financial values, or request behavior. */
body:has(#appShell:not(.hidden)) { background:#f4f6f3; }
#appShell { --navy:#193e33; --blue:#29604b; --blue-soft:#edf3ee; --ink:#20372e; --muted:#66776e; --line:#dde5de; --surface:#fff; --green:#28764f; --red:#b3443e; --shadow:0 3px 14px #243c2e04; color:var(--ink); width:min(1560px,calc(100% - 56px)); display:grid; grid-template-columns:184px minmax(0,1fr); column-gap:32px; padding:32px 0 72px; align-items:start; }
#appShell.hidden { display:none !important; }
#appShell > :not(.tabs) { grid-column:2; min-width:0; }
#appShell > .tabs { grid-column:1; grid-row:1 / span 8; display:flex; flex-direction:column; align-self:start; position:sticky; top:24px; gap:5px; border:0; margin:0; padding:4px 0; overflow:visible; }
#appShell > .tabs::before { content:'WORKSPACE'; color:#596c50; font-size:10px; letter-spacing:.13em; font-weight:700; padding:0 14px 15px; }
#appShell > .tabs::after { content:'THE DELI GROUP\A Finance & performance'; white-space:pre-line; border-top:1px solid #dce5dd; margin:25px 12px 0; padding-top:18px; font-size:10px; line-height:1.9; letter-spacing:.025em; color:#596c50; }
#appShell > .tabs .tab { display:flex; align-items:center; gap:11px; width:100%; min-height:45px; padding:12px 14px; border:1px solid transparent; border-radius:9px; background:transparent; text-align:left; font-size:13px; font-weight:550; color:#596c50; line-height:1.3; white-space:normal; }
#appShell > .tabs .tab::before { content:''; display:block; width:14px; height:14px; flex:0 0 14px; border:1.5px solid currentColor; border-radius:4px; opacity:.65; }
#appShell > .tabs .tab[data-page=overview]::before { box-shadow:inset 0 -5px 0 currentColor; }
#appShell > .tabs .tab[data-page=branches]::before { border-radius:50%; }
#appShell > .tabs .tab[data-page=menus]::before { border-radius:50% 50% 3px 3px; }
#appShell > .tabs .tab[data-page=planning]::before,#appShell > .tabs .tab[data-page=budgets]::before { border-top-width:4px; }
#appShell > .tabs .tab[data-page=profitability]::before { transform:rotate(-12deg); border-top:0; border-right:0; }
#appShell > .tabs .tab[data-page=uploads] { margin-top:22px; }
#appShell > .tabs .tab:hover { color:#234e3b; background:#eaf0e9; }
#appShell > .tabs .tab.active { color:#fff; background:#24543f; border-color:#24543f; box-shadow:0 4px 10px #214b3b10; font-weight:650; }
#appShell > .tabs .tab.hidden { display:none !important; }
/* Only the active Finance app receives this header, not the portal or other apps. */
body:has(#appShell:not(.hidden)) #appHeader { background:#fff; color:#203d30; border-bottom:1px solid #dae3db; }
body:has(#appShell:not(.hidden)) .topbar-inner { width:min(1560px,calc(100% - 56px)); min-height:82px; }
body:has(#appShell:not(.hidden)) #appHeader .brand-mark { color:#fff; background:#24543f; border-radius:13px; width:44px; height:44px; flex-basis:44px; }
body:has(#appShell:not(.hidden)) #appHeader .eyebrow { color:#596c50; font-size:9px; letter-spacing:.15em; }
body:has(#appShell:not(.hidden)) #activeAppTitle { font-size:20px; font-weight:650; letter-spacing:-.6px; }
body:has(#appShell:not(.hidden)) #appHeader .user-area small { color:#596c50; font-size:11px; }
body:has(#appShell:not(.hidden)) #appHeader .outline { color:#43614d; border:1px solid #d9e2d9; border-radius:8px; padding:9px 12px; min-height:40px; font-size:12px; }
body:has(#appShell:not(.hidden)) #appHeader .status-dot { background:#548968; box-shadow:none; }
body:has(#appShell:not(.hidden)) #appHeader .esb-freshness-bar { background:#edf2eb; border-top:1px solid #e4ebe1; }
body:has(#appShell:not(.hidden)) #appHeader .esb-freshness-inner { width:min(1560px,calc(100% - 56px)); padding:8px 0; }
body:has(#appShell:not(.hidden)) #appHeader .esb-freshness { color:#596c50; font-size:11px; font-weight:500; line-height:1.5; }
body:has(#appShell:not(.hidden)) #appHeader .esb-freshness:is(.is-stale,.is-unavailable) { color:#895d19; }
#appShell .welcome { align-items:flex-start; gap:18px; margin:0 0 26px; }
#appShell .welcome h2 { color:#193c2c; font-size:clamp(25px,2.4vw,34px); font-weight:600; letter-spacing:-1px; line-height:1.2; margin:7px 0 9px; }
#appShell .welcome p:not(.eyebrow) { font-size:13px; line-height:1.6; }
#appShell .eyebrow.blue { color:#596c50; font-size:9px; letter-spacing:.13em; font-weight:700; }
#appShell .period-pill { margin-top:6px; max-width:330px; color:#596c50; border:1px solid #dce5d8; background:#edf2e8; border-radius:7px; font-size:11px; line-height:1.5; padding:9px 12px; }
#appShell .period-pill.is-stale { color:#895d19; border-color:#e2ca96; background:#fff8e7; }
#appShell .panel { border-color:var(--line); border-radius:13px; box-shadow:var(--shadow); }
#appShell .panel-heading { gap:14px; align-items:flex-start; margin-bottom:18px; }
#appShell h3 { font-size:16px; font-weight:650; letter-spacing:-.35px; line-height:1.4; margin:5px 0 0; }
#appShell .badge { background:#f2f5ef; color:#596c50; border-color:#e3e9dd; border-radius:6px; padding:5px 8px; font-size:10px; line-height:1.4; font-weight:500; }
#appShell .dashboard-filter-disclosure { border:1px solid #dce5da; border-radius:12px; background:#fff; margin-bottom:19px; overflow:hidden; }
#appShell .dashboard-filter-disclosure > summary { display:flex; justify-content:space-between; align-items:center; gap:14px; list-style:none; cursor:pointer; padding:13px 17px; color:#61755f; font-size:11px; line-height:1.5; }
#appShell .dashboard-filter-disclosure > summary::-webkit-details-marker { display:none; }
#appShell .dashboard-filter-disclosure > summary strong { font-size:11px; font-weight:650; color:#2c5c42; white-space:nowrap; display:flex; align-items:center; gap:10px; }
#appShell .dashboard-filter-disclosure > summary strong::after { content:''; width:6px; height:6px; border-right:1.5px solid; border-bottom:1.5px solid; transform:rotate(45deg); margin-top:-3px; }
#appShell .dashboard-filter-disclosure[open] > summary strong::after { transform:rotate(225deg); margin-top:3px; }
#appShell .filters { border:0; border-top:1px solid #eef2ea; border-radius:0; box-shadow:none; padding:16px; gap:11px; grid-template-columns:1.15fr 1fr 1fr 1fr 1fr auto; margin:0; }
#appShell .field { min-width:0; }
#appShell .field label { color:#596c50; font-size:10px; letter-spacing:.025em; font-weight:600; }
#appShell :is(select,input[type=date]) { min-width:0; min-height:42px; border:1px solid #d9e1d6; border-radius:7px; color:#3b523e; background:#fff; font-size:12px; padding:10px; }
#appShell :is(select,input,textarea):disabled { background:#f1f3ef; color:#8a9587; cursor:not-allowed; }
#appShell .primary,#appShell .file-button { background:#24543f; color:#fff; border-radius:7px; min-height:42px; font-size:12px; font-weight:600; padding:11px 16px; box-shadow:none; }
#appShell .primary:hover,#appShell .file-button:hover { background:#193f2d; }
#appShell .outline.dark,#appShell .secondary,#appShell .icon-action { color:#3b6548; border-color:#d4dfcd; background:#fff; border-radius:7px; }
#appShell .filter-scope-hint { padding:0 16px 14px; font-size:12px; color:#846325; }
#appShell .kpi-grid { grid-template-columns:repeat(5,minmax(0,1fr)); gap:12px; margin:0 0 23px; }
#appShell .kpi { position:relative; flex-direction:column; align-items:flex-start; justify-content:flex-start; gap:0; min-height:165px; padding:19px 16px 17px; }
#appShell .kpi-icon { display:none; }
#appShell .kpi small { color:#596c50; font-weight:550; font-size:11px; }
#appShell .kpi strong { color:#203e2d; font-size:clamp(19px,1.85vw,29px); font-weight:600; margin:10px 0 10px; letter-spacing:-.8px; white-space:normal; overflow-wrap:anywhere; line-height:1.2; font-variant-numeric:tabular-nums; }
#appShell .kpi em { color:#286e49; font-size:10px; line-height:1.55; }
#appShell .kpi em.negative { color:#a04a3d; }
#appShell .kpi:first-child { background:#eaf0e5; border-color:#cddcc4; }
#appShell .kpi:first-child small { color:#547247; }
#appShell .kpi:first-child strong { color:#244a2d; }
#appShell .page { min-width:0; }
#appShell .content-grid { grid-template-columns:minmax(0,1.8fr) minmax(250px,.9fr); gap:18px; margin-bottom:23px; }
#appShell .content-grid.equal { grid-template-columns:repeat(2,minmax(0,1fr)); }
#appShell :is(.chart-panel,.insights,.period-target-panel,.target-results-panel,.non-sales-panel,.planning-card,.staff-card) { padding:22px; min-width:0; }
#appShell .chart-panel .trend-heading { display:block; }
#appShell .trend-actions { margin-top:16px; width:100%; justify-content:flex-start; gap:12px; }
#appShell .compact-select { font-size:10px; color:#596c50; gap:5px; }
#appShell .compact-select select { padding:6px 9px; min-height:33px; font-size:11px; }
#appShell .legend { font-size:10px; color:#596c50; }
#appShell .trend-actions .legend { margin-left:auto; }
#appShell .period-context { color:#596c50; font-size:11px; line-height:1.6; margin-top:5px; }
#appShell .chart { min-width:0; }
#appShell .insights .panel-heading { flex-wrap:wrap; gap:10px; }
#appShell .insights ul { padding:0; gap:0; }
#appShell .insights li { padding:16px 0 16px 24px; border-bottom:1px solid #eef2e9; color:#5a7054; font-size:13px; line-height:1.65; }
#appShell .insights li:last-child { border-bottom:0; }
#appShell .insights li span { color:#72925c; background:#eef3e8; }
#appShell .period-target-panel { margin-bottom:23px; }
#appShell #periodTargetSummary { font-size:12px; line-height:1.65; color:#596c50; }
#appShell .period-target-kpis { border:1px solid #e4ebdd; border-radius:9px; background:#f7f9f3; gap:0; padding:16px 4px; margin:18px 0; }
#appShell .period-target-kpis > * { padding:0 15px; border-right:1px solid #e0e7d7; }
#appShell .period-target-kpis > :last-child { border:0; }
#appShell .period-target-kpis small { color:#596c50; font-size:10px; line-height:1.4; }
#appShell .period-target-kpis strong { color:#335332; font-size:17px; font-weight:600; letter-spacing:-.4px; font-variant-numeric:tabular-nums; }
#appShell .period-target-panel details summary { font-weight:550; font-size:11px; color:#59704d; padding:8px 0; }
#appShell .scope-warning { color:#8d702f; }
#appShell table { font-variant-numeric:tabular-nums; font-size:12px; }
#appShell th { background:#f5f7f1; color:#596c50; font-size:9px; letter-spacing:.07em; padding:12px; font-weight:650; border-color:#e6ecdf; line-height:1.5; }
#appShell td { padding:13px 12px; border-color:#ecf0e5; line-height:1.55; }
#appShell tbody tr:hover { background:#fafbf7; }
#appShell .table-wrap { border-radius:8px; }
#appShell .owner-grid { gap:16px; margin:0 0 23px; grid-template-columns:repeat(3,minmax(0,1fr)); }
#appShell .owner-card { padding:20px; }
#appShell .owner-card .badge { max-width:140px; }
#appShell .monthly-scope-notice { border-color:#e7dcbf; background:#fcf9f0; padding:17px 19px; margin-bottom:18px; }
#appShell .monthly-scope-notice strong { color:#877036; font-size:12px; }
#appShell .monthly-scope-notice p { color:#596c50; font-size:11px; line-height:1.7; }
#appShell .monthly-scope-notice button { background:#fff; border:1px solid #ddd3b6; color:#7e6b37; font-size:11px; }
#appShell .finance-disclosure { background:#fff; border:1px solid #dce5d5; border-radius:12px; margin:0 0 23px; overflow:hidden; }
#appShell .finance-disclosure > summary { display:flex; justify-content:space-between; align-items:center; padding:20px 22px; gap:18px; list-style:none; cursor:pointer; }
#appShell .finance-disclosure > summary::-webkit-details-marker { display:none; }
#appShell .finance-disclosure > summary strong { display:block; font-size:14px; font-weight:600; color:#36532b; }
#appShell .finance-disclosure > summary small { display:block; color:#596c50; font-size:11px; margin-top:6px; line-height:1.6; }
#appShell .finance-disclosure-action { flex-shrink:0; font-size:10px; color:#596c50; }
#appShell .finance-disclosure-action::after { content:' +'; font-size:16px; margin-left:8px; }
#appShell .finance-disclosure[open] .finance-disclosure-action::after { content:' −'; }
#appShell .finance-disclosure[open] > summary { border-bottom:1px solid #edf1e7; }
#appShell .finance-disclosure > .panel { margin:0; border:0; border-radius:0; box-shadow:none; background:#fff; }
#appShell .finance-menu-entry { padding:22px; margin:0 0 23px; border-color:#d7e3ce; background:#edf3e7; }
#appShell .finance-menu-entry .panel-heading { margin:0; align-items:center; }
#appShell .finance-menu-entry p:not(.eyebrow) { color:#596c50; font-size:12px; }
#appShell .finance-menu-entry .outline { white-space:nowrap; border-color:#bfd0b2; background:#fff; }
#appShell .quick-prompts button { color:#5f7750; border-color:#dce5d4; background:#f7f9f2; }
#appShell .assistant-answer { font-size:13px; line-height:1.65; }
#appShell .non-sales-summary { background:#f7f9f2; border-color:#e0e8d6; }
#appShell .non-sales-panel { margin-bottom:23px; }
#appShell :is(button,a,input,select,textarea,summary):focus-visible { outline:3px solid #779e60; outline-offset:3px; }
#appShell button:disabled { cursor:not-allowed; opacity:.55; }
#appShell [hidden],#appShell .hidden { display:none !important; }
@media (max-width:1250px) {
 #appShell { grid-template-columns:160px minmax(0,1fr); column-gap:22px; width:calc(100% - 40px); }
 #appShell .filters { grid-template-columns:repeat(3,minmax(0,1fr)); }
 #appShell .welcome { flex-direction:column; gap:12px; }
 #appShell .period-pill { margin:0; }
 #appShell .kpi-grid { grid-template-columns:repeat(3,minmax(0,1fr)); }
 #appShell .kpi { min-height:145px; }
 #appShell .kpi:nth-child(4),#appShell .kpi:nth-child(5) { grid-column:auto; }
 #appShell .content-grid { grid-template-columns:minmax(0,1fr); }
 #appShell .insights ul { display:grid; grid-template-columns:repeat(2,minmax(0,1fr)); column-gap:24px; }
 #appShell .owner-grid { grid-template-columns:repeat(2,minmax(0,1fr)); }
 #appShell .period-target-kpis { grid-template-columns:repeat(2,minmax(0,1fr)); row-gap:18px; }
 #appShell .period-target-kpis > :nth-child(2) { border:0; }
}
@media (max-width:900px) {
 #appShell { display:block; width:calc(100% - 36px); padding-top:24px; }
 #appShell > .tabs { flex-direction:row; position:static; gap:4px; overflow-x:auto; padding:0 0 12px; margin:0 0 18px; }
 #appShell > .tabs::before,#appShell > .tabs::after,#appShell > .tabs .tab::before { display:none; }
 #appShell > .tabs .tab { width:auto; flex-shrink:0; white-space:nowrap; padding:11px 14px; }
 #appShell > .tabs .tab[data-page=uploads] { margin:0; }
 #appShell .welcome { flex-direction:row; }
 #appShell .content-grid.equal { grid-template-columns:1fr; }
 body:has(#appShell:not(.hidden)) .topbar-inner,body:has(#appShell:not(.hidden)) #appHeader .esb-freshness-inner { width:calc(100% - 36px); }
}
@media (max-width:600px) {
 body:has(#appShell:not(.hidden)) .topbar-inner { flex-wrap:wrap; gap:14px; padding:15px 0 12px; }
 body:has(#appShell:not(.hidden)) #appHeader .brand { flex:1 1 100%; }
 body:has(#appShell:not(.hidden)) #activeAppTitle { max-width:none; font-size:20px; }
 body:has(#appShell:not(.hidden)) #appHeader .user-area { width:100%; justify-content:flex-end; gap:8px; }
 body:has(#appShell:not(.hidden)) #appHeader .user-area .outline { min-height:38px; margin:0; }
 body:has(#appShell:not(.hidden)) #appHeader .esb-freshness { font-size:10px; }
 #appShell { width:calc(100% - 28px); padding-top:24px; }
 #appShell .welcome { flex-direction:column; gap:13px; margin-bottom:21px; }
 #appShell .welcome h2 { font-size:28px; }
 #appShell .period-pill { width:auto; max-width:100%; text-align:left; font-size:10px; }
 #appShell > .tabs { display:none; }
 #appShell .mobile-section-picker { display:grid; grid-template-columns:66px minmax(0,1fr); align-items:center; padding:11px 12px; margin:0 0 14px; background:#e7eee1; border:1px solid #d9e4d0; border-radius:10px; color:#596c50; font-size:11px; }
 #appShell .mobile-section-picker select { min-height:42px; font-size:13px; border-color:#cad8bd; background:#fff; color:#35562a; }
 #appShell .dashboard-filter-disclosure { margin-bottom:14px; }
 #appShell .dashboard-filter-disclosure > summary { padding:13px; font-size:10px; }
 #appShell .dashboard-filter-disclosure > summary strong { font-size:10px; }
 #appShell .filters { grid-template-columns:repeat(2,minmax(0,1fr)); padding:13px; }
 #appShell .filters .field:nth-child(3) { grid-column:1 / -1; }
 #appShell .filters .primary { grid-column:1 / -1; }
 #appShell :is(select,input[type=date],input,textarea) { font-size:16px; }
 #appShell .kpi-grid { grid-template-columns:repeat(2,minmax(0,1fr)); gap:10px; margin-bottom:18px; }
 #appShell .kpi { padding:17px 14px; min-height:150px; }
 #appShell .kpi:first-child { grid-column:1 / -1; min-height:130px; }
 #appShell .kpi:last-child:nth-child(odd) { grid-column:auto; }
 #appShell .kpi:first-child strong { font-size:32px; }
 #appShell .kpi strong { font-size:23px; }
 #appShell .kpi em { font-size:10px; line-height:1.55; }
 #appShell :is(.chart-panel,.insights,.period-target-panel,.target-results-panel,.non-sales-panel,.planning-card,.staff-card) { padding:17px; }
 #appShell .content-grid,#appShell .owner-grid { grid-template-columns:1fr; gap:14px; margin-bottom:18px; }
 #appShell .insights ul { grid-template-columns:1fr; }
 #appShell .period-target-kpis { padding:15px 0; gap:18px 0; }
 #appShell .period-target-kpis > * { padding:0 10px; }
 #appShell .period-target-kpis strong { font-size:16px; overflow-wrap:anywhere; }
 #appShell .period-target-panel { margin-bottom:18px; }
 #appShell .trend-actions { flex-wrap:wrap; }
 #appShell .trend-actions .legend { width:100%; margin-left:0; }
 #appShell .compact-select select { font-size:14px; min-height:42px; }
 #appShell .finance-disclosure > summary { padding:17px; gap:10px; }
 #appShell .finance-disclosure-action { font-size:0; }
 #appShell .finance-disclosure-action::after { font-size:20px; }
 #appShell .finance-menu-entry { padding:18px; }
 #appShell .finance-menu-entry .panel-heading { flex-direction:column; align-items:flex-start; }
 #appShell .finance-menu-entry .outline { margin:0; }
 #appShell .monthly-scope-notice { padding:15px; }
 #appShell .monthly-scope-notice button { width:100%; white-space:normal; }
}
@media (prefers-reduced-motion:reduce) { #appShell *,#appShell *::before,#appShell *::after { animation:none !important; transition:none !important; scroll-behavior:auto !important; } }
@media print { #appShell { display:block; width:100%; } #appShell > .tabs,#appShell .mobile-section-picker { display:none; } #appShell .panel { box-shadow:none; break-inside:avoid; } }

/* Match the legend to the actual solid / dashed chart series. */
#appShell .legend i:first-of-type { background:var(--blue); }
#appShell .legend i:nth-of-type(2) { background:#aebbd4; margin-left:6px; }
/* Status color is meaning, not decoration. Preserve the established variants. */
#appShell .badge.ai { color:#0d6f4a; border-color:#b8e3d1; background:#eefaf5; }
#appShell .badge.fallback { color:#8a5b00; border-color:#f1d394; background:#fff9e9; }

#appShell .insights li::before { top:16px; }
