/* Each dashboard column owns its scroll; no financial data is painted outside this workspace. */
body.app-mode-home { height:100vh; height:100dvh; overflow:hidden; }
body.app-mode-home .app-shell { height:100vh; height:100dvh; min-height:0; }
body.app-mode-home .main { display:flex; flex-direction:column; height:100%; min-height:0; overflow:hidden; }
body.app-mode-home .topbar { flex:none; min-height:72px; padding-block:11px; background:var(--paper); backdrop-filter:none; }
body.app-mode-home .topbar h1 { font-size:23px; }
body.app-mode-home .topbar .eyebrow { font-size:11px; }
body.app-mode-home .primary-mode-button.home { --mode-color:var(--accent); }
#homeWorkspace.home-dashboard-workspace:not(.hidden) { display:flex; flex:1; flex-direction:column; gap:12px; width:100%; max-width:2000px; min-height:0; padding:18px clamp(14px,1.7vw,28px) 18px; }
.home-dashboard-workspace { --home-border:color-mix(in srgb,var(--line) 88%,transparent); --home-radius:14px; --home-elevation:0 2px 9px color-mix(in srgb,var(--ink) 3%,transparent); color:var(--ink); font-variant-numeric:tabular-nums; }
.home-dashboard-workspace button,.home-dashboard-workspace input,.home-dashboard-workspace select { font:inherit; }
.home-dashboard-workspace button { -webkit-tap-highlight-color:transparent; cursor:pointer; }
.home-dashboard-workspace button:disabled { opacity:.55; cursor:wait; }
.home-dashboard-workspace :is(button,input,select,summary,[tabindex]):focus-visible { outline:3px solid color-mix(in srgb,var(--accent) 68%,transparent); outline-offset:3px; }
.home-dashboard-workspace h3,.home-dashboard-workspace h4,.home-dashboard-workspace p { margin:0; }
.home-dashboard-workspace h3 { letter-spacing:-.025em; }
.home-sr-only { position:absolute; width:1px; height:1px; padding:0; margin:-1px; overflow:hidden; clip:rect(0,0,0,0); white-space:nowrap; border:0; }
.home-feed-compact { flex:none; display:flex; align-items:center; justify-content:space-between; gap:8px; min-height:51px; padding:7px 12px; border-bottom:1px solid var(--home-border); }
.home-feed-toggle { display:flex; align-items:center; gap:8px; min-height:36px; padding:7px 9px; border:1px solid transparent; border-radius:8px; background:transparent; color:var(--ink); font-size:12px!important; font-weight:600; }
.home-feed-toggle:hover,.home-feed-toggle[aria-expanded=true] { border-color:var(--home-border); background:var(--soft); }
.home-feed-toggle > svg { width:16px; height:16px; stroke:currentColor; stroke-width:1.6; fill:none; }
.home-feed-toggle > b:not(:empty) { padding:2px 5px; border-radius:4px; background:var(--accent); color:#fff; font-size:11px; }
.home-feed-toggle[aria-expanded=true] .home-toggle-chevron { transform:rotate(180deg); }
.home-feed-compact > #homeOrderCount { color:var(--muted); font-size:11px; white-space:nowrap; }
.home-today-counter { display:flex; flex:none; align-items:center; gap:6px; color:var(--muted); font-size:12px; white-space:nowrap; margin-left:auto; }
.home-today-counter b { font-size:15px; color:var(--ink); }
.home-customize { padding:6px 8px; border:1px solid var(--line); border-radius:7px; background:var(--paper); color:var(--muted); font-size:10px!important; }
.home-customize:hover { color:var(--ink); background:var(--soft); }
.home-summary-rail > .home-rail-heading { position:sticky; z-index:2; top:0; order:-1; padding:6px 0 9px; background:var(--canvas); }
#homeModelRankings,.home-model-rankings { display:contents!important; }
.home-summary-rail [data-home-tile][hidden] { display:none!important; }
.home-layout-dialog { width:min(760px,calc(100vw - 24px)); max-height:calc(100dvh - 32px); padding:0; border:1px solid var(--line); border-radius:18px; background:var(--paper); color:var(--ink); box-shadow:var(--shadow); }
.home-layout-dialog::backdrop { background:rgba(5,14,25,.6); }
.home-layout-dialog > header { display:flex; align-items:flex-start; gap:20px; padding:22px; border-bottom:1px solid var(--line); }
.home-layout-dialog h2 { margin:0 0 8px; font-size:20px; }
.home-layout-dialog p { margin:0; color:var(--muted); font-size:12px; line-height:1.5; }
.home-layout-dialog button { min-width:36px; min-height:36px; padding:7px 10px; border:1px solid var(--line); border-radius:8px; background:var(--soft); color:var(--ink); cursor:pointer; }
.home-layout-dialog > header > button { margin-left:auto; font-size:20px; }
#homeLayoutItems { display:grid; grid-template-columns:1fr 1fr; gap:20px; padding:20px; max-height:60dvh; overflow-y:auto; overscroll-behavior:contain; }
.home-layout-group h3 { font-size:13px; margin:0 0 12px; }
.home-layout-group ol { list-style:none; margin:0; padding:0; display:grid; gap:8px; }
.home-layout-group li { display:flex; align-items:center; gap:8px; padding:9px 8px; border:1px solid var(--line); border-radius:10px; background:var(--surface-field,var(--soft)); }
.home-layout-grip { color:var(--muted); cursor:grab; }
.home-layout-group label { display:flex; align-items:center; gap:8px; font-size:12px; flex:1; }
.home-layout-group input { width:17px; height:17px; accent-color:var(--accent); }
.home-layout-group li > div { display:flex; gap:3px; }
.home-layout-group button:disabled { opacity:.25; cursor:default; }
.home-layout-dialog > footer { display:flex; flex-wrap:wrap; justify-content:space-between; gap:12px; padding:16px 20px; border-top:1px solid var(--line); }
.home-layout-dialog > footer .primary { color:#fff; background:var(--accent); border-color:var(--accent); }
#homeLayoutError:not(:empty) { color:var(--error); padding:8px 20px; }
@media(max-width:550px) { #homeLayoutItems { grid-template-columns:1fr; gap:24px; max-height:58dvh; padding:16px; } .home-feed-compact { gap:6px; padding-inline:8px; } .home-feed-toggle { gap:5px; padding-inline:4px; font-size:11px!important; } .home-today-counter { gap:4px; font-size:11px; } .home-feed-compact > #homeOrderCount { font-size:10px; } }
@media(max-width:380px) { .home-feed-compact > #homeOrderCount { display:none; } }
.home-feed-controls:not([hidden]) { display:flex; flex:0 1 auto; flex-direction:column; min-height:0; max-height:min(53dvh,470px); overflow-y:auto; overscroll-behavior-y:contain; scrollbar-width:thin; border-bottom:1px solid var(--home-border); padding-top:10px; }
.home-feed-controls[hidden] { display:none; }
.home-feed-controls .home-order-filters,.home-feed-controls .home-advanced-filters { flex:none; max-height:none; overflow:visible; }
.home-info { margin-top:12px; color:var(--muted); font-size:11px; line-height:1.6; }
.home-info > summary { width:fit-content; cursor:pointer; padding:5px 0; color:var(--muted); }
.home-info > div { margin-top:7px; }
.home-info .home-result-definition { margin-top:0!important; }
.home-info p + p { margin-top:8px; }
.home-inline-status { display:flex; flex-wrap:wrap; gap:5px; margin-top:8px; color:var(--muted); font-size:11px; line-height:1.5; }
.home-inline-status > b { font-weight:500; }
.home-order-buyer { display:flex; align-items:center; justify-content:space-between; gap:12px; padding:9px 12px 0; color:var(--ink); font-size:12px; font-weight:600; line-height:1.5; overflow-wrap:anywhere; }
.home-order-buyer > b { min-width:0; font-weight:600; }
.home-order-buyer > span { color:var(--muted); font-weight:400; margin-right:5px; }
.home-model-rankings { display:flex; flex-direction:column; gap:14px; }
#homeModelRankings:empty { display:none; }
.home-ranking-list { list-style:none; margin:0; padding:0; counter-reset:home-rank; }
.home-ranking-list > li { display:grid; grid-template-columns:18px minmax(0,1fr) auto; gap:7px; align-items:start; padding:11px 0; border-top:1px solid var(--home-border); font-size:12px; }
.home-ranking-list > li:first-child { border-top:0; padding-top:0; }
.home-ranking-list > li::before { counter-increment:home-rank; content:counter(home-rank); padding-top:1px; color:var(--muted); font-size:11px; }
.home-ranking-name { min-width:0; }
.home-ranking-name > strong { display:-webkit-box; -webkit-line-clamp:2; -webkit-box-orient:vertical; overflow:hidden; font-weight:550; line-height:1.5; overflow-wrap:anywhere; }
.home-ranking-name > small { display:block; margin-top:4px; color:var(--muted); font-size:11px; line-height:1.5; }
.home-ranking-value { display:flex; flex-direction:column; gap:4px; align-items:flex-end; white-space:nowrap; font-size:12px; font-weight:650; }
.home-ranking-value > small { color:var(--muted); font-size:10px; font-weight:400; }
.home-ranking-empty { padding:4px 0; color:var(--muted); font-size:12px; line-height:1.6; }
.home-overline { color:var(--muted); font-size:11px; font-weight:700; letter-spacing:.11em; text-transform:uppercase; }
.home-overview-grid { flex:1; display:grid; grid-template-columns:minmax(215px,.94fr) minmax(360px,2.03fr) minmax(250px,1.12fr); gap:16px; min-height:0; }
.home-summary-rail { display:flex; flex-direction:column; gap:14px; min-width:0; min-height:0; overflow-y:auto; overflow-x:hidden; padding:1px 6px 12px 1px; overscroll-behavior-y:contain; scrollbar-gutter:stable; -webkit-overflow-scrolling:touch; }
.home-summary-rail,.home-order-scroll,.home-advanced-filters { scrollbar-width:thin; scrollbar-color:color-mix(in srgb,var(--muted) 32%,transparent) transparent; }
.home-rail-heading { display:flex; align-items:center; justify-content:space-between; padding:4px 2px 2px; }
.home-rail-heading h3 { margin-top:3px; font-size:21px; font-weight:650; letter-spacing:-.04em; }
.home-currency-label { padding:5px 7px; border:1px solid var(--home-border); border-radius:7px; color:var(--muted); font-size:11px; }
.home-stat-card { flex:none; min-width:0; padding:17px; background:var(--paper); border:1px solid var(--home-border); border-radius:var(--home-radius); box-shadow:var(--home-elevation); }
.home-card-heading { display:flex; align-items:center; justify-content:space-between; gap:7px; margin-bottom:14px; }
.home-card-heading h3 { font-size:13px; line-height:1.4; font-weight:650; }
.home-card-heading > span { font-size:11px; color:var(--muted); text-align:right; }
.home-card-heading > svg { width:18px; height:18px; color:var(--muted); }
.home-today-amount { margin:2px 0 9px; font-size:clamp(27px,2.15vw,37px); line-height:1.12; font-weight:700; letter-spacing:-.055em; overflow-wrap:anywhere; }
.home-stat-description,.home-small-note { color:var(--muted); font-size:11px; line-height:1.55; }
.home-today-counts { display:grid; grid-template-columns:1fr 1fr; gap:12px; margin-top:20px; }
.home-mini-metric { display:flex; flex-direction:column; gap:5px; min-width:0; }
.home-mini-metric strong { font-size:24px; line-height:1.15; font-weight:650; letter-spacing:-.035em; }
.home-mini-metric span { font-size:11px; line-height:1.4; color:var(--muted); }
.home-result-card { background:color-mix(in srgb,var(--accent) 4%,var(--paper)); }
.home-result-amount { display:flex; align-items:baseline; flex-wrap:wrap; gap:6px 8px; }
.home-result-amount strong { font-size:28px; line-height:1.15; letter-spacing:-.05em; font-weight:650; }
.home-result-amount > span { display:flex; align-items:center; gap:4px; color:var(--muted); font-size:11px; }
.home-monthly-card .home-card-heading { margin-bottom:12px; }
.home-month-picker { display:flex; align-items:center; justify-content:space-between; gap:10px; margin-bottom:18px; color:var(--muted); font-size:11px; }
.home-dashboard-workspace .home-month-picker > input { width:162px; max-width:72%; min-width:0; min-height:38px; padding:6px 9px; border:1px solid var(--home-border); border-radius:8px; background:var(--soft); color:var(--ink); font-size:13px; }
.home-monthly-value > strong { display:block; font-size:clamp(25px,2vw,34px); line-height:1.15; letter-spacing:-.045em; overflow-wrap:anywhere; }
.home-monthly-value > span { display:block; margin-top:7px; color:var(--muted); font-size:11px; }
.home-monthly-value .home-result-amount strong { font-size:clamp(25px,2vw,34px); overflow-wrap:anywhere; }
.home-monthly-earnings { background:color-mix(in srgb,var(--accent) 4%,var(--paper)); }
.home-monthly-notice { margin-top:12px!important; min-height:15px; color:var(--muted); font-size:10px; line-height:1.5; }
.home-monthly-notice.has-error { color:var(--error); }
@media(max-width:760px) { .home-dashboard-workspace .home-month-picker > input { font-size:16px; min-height:42px; width:177px; } }
.home-estimate { display:inline; color:var(--muted); font-size:11px; font-style:normal; font-weight:400; line-height:1.5; white-space:nowrap; }
.home-dashboard-workspace .home-estimate-link { display:inline; min-height:0; min-width:0; padding:0; border:0; border-radius:2px; background:transparent; color:var(--muted); font-size:11px; line-height:1.5; text-decoration:underline dotted; text-underline-offset:3px; }
.home-estimate-link:hover { color:var(--ink); }
.home-net-result { display:flex; align-items:center; justify-content:space-between; gap:8px; margin-top:13px; font-size:12px; color:var(--muted); }
.home-net-result b { color:var(--ink); font-weight:600; }
.home-result-definition { margin-top:14px!important; color:var(--muted); font-size:11px; line-height:1.6; }
.home-result-pending { display:flex; flex-direction:column; gap:7px; }
.home-result-pending b { font-size:16px; font-weight:600; }
.home-result-pending span { color:var(--muted); font-size:12px; line-height:1.55; }
.home-finance-coverage { display:flex; flex-direction:column; gap:4px; margin-top:13px; padding:10px; border-radius:8px; background:var(--warning-soft); color:var(--warning); }
.home-finance-coverage > strong { font-size:12px; line-height:1.5; font-weight:650; }
.home-finance-coverage > span { font-size:11px; line-height:1.5; }
.home-dashboard-workspace .negative { color:var(--error)!important; }
.home-cost-line { display:flex; align-items:start; justify-content:space-between; gap:10px; padding:12px 0; border-top:1px solid var(--home-border); font-size:12px; }
.home-cost-line:first-of-type { border-top:0; padding-top:0; }
.home-cost-line > div { min-width:0; }
.home-cost-line small { display:block; margin-top:5px; color:var(--muted); font-size:11px; line-height:1.5; }
.home-cost-line small.home-cost-partial { color:var(--warning); font-weight:600; }
.home-cost-line > b { flex:none; font-size:13px; font-weight:600; }
.home-data-warning { margin-top:11px!important; color:var(--warning); font-size:12px; line-height:1.6; }
.home-conversion-warning { color:var(--muted)!important; font-weight:500; }
.home-originals { margin:10px 0; min-width:0; color:var(--muted); font-size:11px; }
.home-originals > summary { cursor:pointer; width:fit-content; max-width:100%; padding:5px 0; color:var(--ink); line-height:1.5; }
.home-originals > div { min-width:0; overflow-x:auto; margin:5px 0; }
.home-originals table { width:100%; border-collapse:collapse; font-size:11px; }
.home-originals caption { text-align:left; color:var(--muted); line-height:1.5; padding-bottom:8px; }
.home-originals th,.home-originals td { padding:7px 3px; text-align:right; border-bottom:1px solid var(--home-border); font-weight:400; }
.home-originals th:first-child { text-align:left; }
.home-originals thead th { color:var(--muted); font-size:11px; }
.home-originals td { white-space:nowrap; }
.home-chart-readout > .home-originals { flex-basis:100%; width:100%; margin-bottom:0; }
.home-chart-readout > .home-chart-account-fees { flex:1 1 100%; color:var(--muted); font-size:11px; line-height:1.5; }
.home-provisional-note { margin-top:10px!important; }
.home-account-fee-groups { margin-bottom:12px; padding:10px; background:var(--soft); border-radius:7px; }
.home-account-fee-groups .home-cost-line { padding:8px 0; font-size:11px; }
.home-account-fee-groups .home-cost-line > b { font-size:12px; }
.home-account-fee-groups > p { margin-bottom:9px!important; }
.home-operation-counts { display:grid; grid-template-columns:repeat(3,minmax(0,1fr)); gap:10px; margin-bottom:13px; }
.home-operation-counts .home-mini-metric strong { font-size:22px; }
.home-operation-counts .attention strong { color:var(--warning); }
.home-feed { display:flex; flex-direction:column; min-width:0; min-height:0; overflow:hidden; border:1px solid var(--home-border); border-radius:var(--home-radius); background:var(--paper); box-shadow:var(--home-elevation); }
.home-feed-heading { display:flex; align-items:center; justify-content:space-between; gap:9px; padding:16px 18px 7px; }
.home-feed-heading .home-overline { display:none; }
.home-feed-heading h3 { display:flex; align-items:center; gap:9px; font-size:21px; font-weight:650; letter-spacing:-.04em; }
#homeOrderCount { display:inline-flex; align-items:center; padding:3px 6px; background:var(--soft); color:var(--muted); border-radius:6px; font-size:11px; font-weight:500; white-space:nowrap; }
#homeOrderCount:empty { display:none; }
.home-order-sort { color:var(--muted); font-size:11px; }
.home-overview-heading { display:flex; flex:none; align-items:center; justify-content:space-between; gap:8px; padding:0 18px 12px; }
.home-date { color:var(--muted); font-size:11px; text-transform:capitalize; }
.home-overview-actions { display:flex; align-items:center; gap:8px; }
.home-sync { display:flex; align-items:center; gap:6px; color:var(--muted); font-size:11px; }
.home-sync i { flex:none; width:5px; height:5px; border-radius:50%; background:var(--success); }
.home-sync.has-error i { background:var(--warning); }
.home-icon-button { display:inline-flex; align-items:center; justify-content:center; flex:none; width:30px; height:30px; min-height:30px; padding:7px; border:1px solid var(--home-border); border-radius:8px; background:var(--paper); color:var(--muted); }
.home-icon-button:hover { background:var(--soft); color:var(--ink); }
.home-icon-button svg { width:16px; height:16px; }
.home-icon-button.is-loading svg { animation:home-refresh-spin 1s linear infinite; }
.home-order-filters { display:flex; flex:0 1 auto; flex-direction:column; gap:9px; min-height:45px; max-height:42dvh; overflow-y:auto; padding:0 18px 10px; border-bottom:1px solid var(--home-border); overscroll-behavior-y:contain; }
.home-order-search { position:relative; display:flex; align-items:center; }
.home-order-search > svg { position:absolute; left:12px; width:17px; height:17px; color:var(--muted); pointer-events:none; }
.home-order-search > input { width:100%; min-width:0; min-height:41px; padding:10px 10px 10px 37px; border:1px solid var(--home-border); border-radius:9px; background:var(--soft); color:var(--ink); font-size:14px; }
.home-order-search > input:focus { background:var(--paper); border-color:var(--accent); }
.home-order-search > input::placeholder { color:var(--muted); opacity:.9; }
.home-filter-selects { display:flex; align-items:end; gap:7px; }
.home-filter-selects label { flex:1; min-width:0; }
.home-field-label { display:block; margin-bottom:5px; color:var(--muted); font-size:11px; }
.home-filter-selects select,.home-advanced-filters :is(select,input),.home-date-filters input { width:100%; min-width:0; min-height:36px; padding:6px 8px; border:1px solid var(--home-border); border-radius:8px; background:var(--paper); color:var(--ink); font-size:14px; text-overflow:ellipsis; }
.home-filter-clear { flex:none; width:30px; height:36px; padding:3px; border:1px solid var(--home-border); border-radius:8px; background:var(--soft); color:var(--muted); font-size:21px!important; }
.home-date-filters { display:grid; grid-template-columns:1fr 1fr; gap:10px; }
.home-date-filters label { display:flex; align-items:center; gap:7px; color:var(--muted); font-size:11px; }
.home-date-filters input { flex:1; width:100%; }
.home-advanced-toggle { display:flex; align-items:center; gap:7px; width:100%; min-height:26px; padding:2px 0; border:0; background:transparent; color:var(--muted); text-align:left; font-size:12px!important; }
.home-advanced-toggle svg { width:15px; height:15px; }
.home-advanced-toggle:hover { color:var(--accent); }
.home-advanced-toggle b:empty { display:none; }
.home-advanced-toggle b { padding:1px 5px; border-radius:5px; background:var(--soft); color:var(--accent); font-size:11px; }
.home-toggle-chevron { margin-left:auto; transition:transform .15s; }
.home-advanced-toggle[aria-expanded=true] .home-toggle-chevron { transform:rotate(180deg); }
.home-advanced-filters { display:grid; grid-template-columns:repeat(3,minmax(0,1fr)); gap:12px 8px; max-height:min(38vh,300px); overflow-y:auto; padding:12px 2px 3px; border-top:1px solid var(--home-border); }
.home-advanced-filters label > span { display:block; margin-bottom:5px; font-size:11px; color:var(--muted); }
.home-advanced-filters p { grid-column:1/-1; font-size:11px; color:var(--muted); line-height:1.5; }
.home-dashboard-workspace [hidden] { display:none!important; }
.home-feed-notice { flex:none; padding:10px 18px; color:var(--warning); background:var(--warning-soft); font-size:12px; line-height:1.5; border-bottom:1px solid var(--home-border); }
.home-order-scroll { flex:1; min-height:0; overflow-y:auto; overflow-x:hidden; padding:14px 12px 3px 16px; overscroll-behavior-y:contain; scrollbar-gutter:stable; overflow-anchor:auto; background:color-mix(in srgb,var(--canvas) 48%,var(--paper)); -webkit-overflow-scrolling:touch; }
.home-order-list { display:flex; flex-direction:column; gap:13px; }
.home-order-card { flex:none; min-width:0; border:1px solid var(--home-border); border-radius:11px; background:var(--paper); overflow:hidden; box-shadow:0 2px 4px color-mix(in srgb,var(--ink) 2%,transparent); contain:layout style; content-visibility:auto; contain-intrinsic-size:auto 260px; }
.home-order-card-header { display:flex; align-items:center; justify-content:space-between; gap:9px; min-height:39px; padding:9px 12px; border-bottom:1px solid var(--home-border); }
.home-order-card-header > div { display:flex; align-items:center; gap:8px; color:var(--muted); font-size:11px; }
.home-order-market { font-size:11px; font-weight:650; letter-spacing:.03em; }
.home-order-status { display:inline-flex; align-items:center; gap:5px; color:var(--muted); font-size:11px; font-weight:550; }
.home-order-status i { width:5px; height:5px; border-radius:50%; background:currentColor; }
.home-order-status.ready,.home-order-status.waiting { color:var(--accent); }
.home-order-status.packed,.home-order-status.completed { color:var(--success); }
.home-order-status.held { color:var(--warning); }
.home-order-status.cancelled { color:var(--error); }
.home-order-quantity,.home-quantity-badge { display:inline-flex; align-items:center; justify-content:center; padding:5px 8px; border-radius:7px; background:color-mix(in srgb,var(--accent) 13%,var(--paper)); color:var(--accent); border:1px solid color-mix(in srgb,var(--accent) 28%,var(--line)); font-size:15px; font-weight:750; white-space:nowrap; }
.home-order-quantity { padding:3px 7px; font-size:13px; }
.home-order-profit .home-finance-unavailable { color:var(--muted); font-size:12px; line-height:1.5; font-weight:550; }
.home-finance-tags { display:flex; flex-wrap:wrap; justify-content:flex-end; gap:4px 7px; }
.home-finance-tag { color:var(--muted); font-size:11px; line-height:1.5; font-weight:400; }
.home-order-profit .home-finance-unavailable.is-error,.home-finance-tag.is-error { color:var(--error); font-weight:600; }
.home-order-card.has-finance-error { border-color:color-mix(in srgb,var(--error) 40%,var(--line)); }
.home-finance-explanations { margin:10px 0 0; padding-left:16px; color:var(--muted); font-size:11px; line-height:1.6; }
.home-order-products { padding:0 12px; }
.home-order-delivery { padding:7px 12px 0; color:var(--muted); font-size:11px; line-height:1.6; overflow-wrap:anywhere; }
.home-delivery-smart { display:inline-block; flex:none; width:66px; height:22px; object-fit:contain; padding:0; border:0; vertical-align:middle; }
body.theme-dark .home-delivery-smart { box-sizing:border-box; padding:1px 3px; background:#fff; border-radius:4px; }
.home-delivery-converted { color:var(--muted); }
.home-order-item { display:grid; grid-template-columns:86px minmax(0,1fr) minmax(105px,145px); align-items:center; gap:12px; padding:14px 0; min-width:0; }
.home-order-item + .home-order-item { border-top:1px solid var(--home-border); }
.home-product-thumb { flex:none; display:flex; align-items:center; justify-content:center; width:86px; height:100px; border-radius:7px; background:var(--soft); overflow:hidden; }
.home-product-image { width:100%; height:100%; object-fit:contain; background:var(--paper); mix-blend-mode:multiply; }
body.theme-dark .home-product-image { mix-blend-mode:normal; }
.home-product-thumb > svg { width:25px; height:25px; color:var(--muted); opacity:.55; }
.home-product-thumb.image-missing::after { content:"—"; color:var(--muted); }
.home-product-copy { flex:1; min-width:0; }
.home-product-copy > strong { display:-webkit-box; -webkit-line-clamp:2; -webkit-box-orient:vertical; overflow:hidden; font-size:14px; line-height:1.5; font-weight:600; letter-spacing:-.015em; overflow-wrap:anywhere; }
.home-product-copy p { margin-top:6px; color:var(--muted); font-size:11px; line-height:1.55; }
.home-product-copy p > span:not(.home-product-code) { margin-inline:3px; opacity:.6; }
.home-product-code { overflow-wrap:anywhere; }
.home-item-price { min-width:0; text-align:right; white-space:normal; font-size:13px; font-weight:600; }
.home-item-profit { margin-top:9px; font-size:12px; color:var(--success); line-height:1.5; }
.home-item-profit > span { display:block; color:var(--muted); font-weight:400; font-size:10px; }
.home-item-profit > span small { display:inline; margin:0; font-size:10px; }
.home-item-profit > b { font-weight:650; }
.home-item-profit .home-unit-profits { display:block; margin-top:2px; color:var(--muted); font-weight:400; font-size:11px; overflow-wrap:anywhere; }
.home-item-profit.is-unavailable { color:var(--muted); font-size:11px; font-weight:400; }
.home-yesterday-metrics { display:grid; grid-template-columns:.75fr 1fr 1fr; gap:9px; margin-top:16px; }
.home-yesterday-metrics > div { min-width:0; border-top:2px solid currentColor; padding-top:9px; }
.home-yesterday :is(.orders,.home-yesterday-series.orders) { color:var(--accent); }
.home-yesterday :is(.revenue,.home-yesterday-series.revenue) { color:#119b92; }
.home-yesterday :is(.earnings,.home-yesterday-series.earnings) { color:#9c6ede; }
.home-yesterday-metrics span,.home-yesterday-metrics small { display:block; color:var(--muted); font-size:11px; line-height:1.5; }
.home-yesterday-metrics strong { display:block; color:var(--ink); font-size:17px; font-weight:650; letter-spacing:-.03em; line-height:1.6; overflow-wrap:anywhere; }
.home-yesterday-caption { margin:17px 0 6px; color:var(--muted); font-size:11px; }
.home-yesterday-plot { display:block; width:100%; height:auto; overflow:visible; }
.home-yesterday-series line { stroke:currentColor; stroke-width:2; vector-effect:non-scaling-stroke; }
.home-yesterday-series circle { fill:var(--paper); stroke:currentColor; stroke-width:1.5; }
.home-yesterday-series .home-yesterday-baseline { stroke:var(--line); stroke-width:1; stroke-dasharray:3 4; }
.home-yesterday-days { display:grid; grid-template-columns:repeat(7,minmax(0,1fr)); margin-top:3px; }
.home-yesterday-days button { min-width:0; min-height:38px; padding:4px 0; border:0; border-radius:7px; background:transparent; color:var(--muted); font:inherit; font-size:10px; cursor:pointer; }
.home-yesterday-days button[aria-pressed="true"] { background:var(--soft); color:var(--ink); font-weight:650; }
.home-yesterday-readout { display:flex; flex-wrap:wrap; gap:4px 10px; padding-top:9px; color:var(--muted); font-size:11px; line-height:1.5; }
.home-yesterday-readout time { width:100%; font-weight:600; color:var(--ink); }
.home-item-price small { display:block; margin-top:5px; font-size:11px; color:var(--muted); font-weight:400; }
.home-original-amount { display:block; color:var(--muted); font-size:11px; line-height:1.5; font-weight:400; white-space:normal; overflow-wrap:anywhere; }
.home-price-unavailable { display:block; color:var(--muted)!important; font-size:12px!important; line-height:1.5; white-space:normal; }
.home-item-price > .home-price-unavailable { max-width:95px; }
.home-order-total .home-original-amount { text-align:right; }
.home-order-profit .home-fees-provisional { color:var(--warning); font-weight:600; }
.home-order-more-items { padding-bottom:11px; }
.home-order-more-items > summary { width:max-content; max-width:100%; padding:5px 0; cursor:pointer; color:var(--muted); font-size:12px; }
.home-order-more-items > summary > b { margin-left:5px; padding:2px 5px; border-radius:4px; background:var(--soft); font-size:11px; }
.home-extra-items:not(:empty) { margin-top:7px; border-top:1px solid var(--home-border); }
.home-order-product-missing { padding:24px 0; color:var(--muted); font-size:12px; }
.home-order-card-footer { display:flex; align-items:end; justify-content:space-between; gap:9px; padding:13px 12px; border-top:1px solid var(--home-border); background:color-mix(in srgb,var(--soft) 30%,var(--paper)); }
.home-order-reference { max-width:80px; overflow:hidden; color:var(--muted); text-overflow:ellipsis; white-space:nowrap; font-size:11px; }
.home-order-financial { display:flex; justify-content:flex-end; gap:18px; min-width:0; }
.home-order-financial > div { display:flex; flex-direction:column; align-items:flex-end; gap:5px; min-width:0; }
.home-order-financial span,.home-order-financial small { font-size:11px; color:var(--muted); line-height:1.4; }
.home-order-profit b { color:var(--ink); font-size:14px; font-weight:650; text-align:right; }
.home-order-total strong { font-size:17px; font-weight:650; letter-spacing:-.035em; white-space:nowrap; }
.home-finance-breakdown { border-top:1px solid var(--home-border); }
.home-finance-breakdown > summary { display:flex; justify-content:space-between; gap:7px; padding:9px 12px; color:var(--muted); font-size:11px; cursor:pointer; list-style:none; }
.home-finance-breakdown > summary::-webkit-details-marker { display:none; }
.home-finance-breakdown > summary:hover { color:var(--accent); background:var(--soft); }
.home-finance-breakdown[open] > summary { color:var(--accent); }
.home-breakdown-body { padding:3px 12px 14px; }
.home-breakdown-body table { width:100%; border-collapse:collapse; font-size:11px; }
.home-breakdown-body caption { text-align:left; padding:5px 0 11px; color:var(--muted); line-height:1.5; }
.home-percentage-basis { display:block; margin-top:5px; }
.home-breakdown-percent { display:block; margin-top:4px; color:var(--muted); font-size:11px; line-height:1.35; font-weight:400; }
.home-commission-percentage { display:grid; grid-template-columns:minmax(0,1fr) minmax(0,1fr); gap:5px 10px; margin-top:12px; font-size:12px; line-height:1.5; }
.home-commission-percentage > strong { color:var(--ink); font-weight:600; }
.home-commission-percentage > span { color:var(--ink); text-align:right; }
.home-commission-percentage small { display:block; color:var(--muted); font-size:11px; }
.home-commission-percentage > p { grid-column:1/-1; color:var(--muted); font-size:11px; overflow-wrap:anywhere; }
.home-breakdown-body th { text-align:left; font-weight:500; }
.home-breakdown-body thead th { color:var(--muted); font-size:11px; }
.home-breakdown-body th,.home-breakdown-body td { padding:8px 3px; border-bottom:1px solid var(--home-border); }
.home-breakdown-body td,.home-breakdown-body thead th:not(:first-child) { text-align:right; white-space:nowrap; }
.home-breakdown-body tbody tr:last-child { font-weight:700; }
.home-breakdown-body > p { margin-top:11px; }
.home-exchange-note { display:flex; flex-direction:column; gap:4px; padding:10px; border-radius:7px; background:var(--soft); color:var(--muted); font-size:11px; line-height:1.5; }
.home-exchange-note strong { color:var(--ink); font-weight:600; }
.home-fee-coverage { margin-top:12px; padding:10px; border:1px solid var(--home-border); border-radius:7px; color:var(--muted); font-size:11px; line-height:1.6; }
.home-fee-coverage > strong { color:var(--ink); font-weight:600; }
.home-fee-coverage > p,.home-fee-coverage > ul { margin-top:6px; }
.home-fee-coverage > ul { padding-left:16px; }
.home-fee-coverage.is-incomplete { border-color:var(--home-border); background:var(--soft); }
.home-fee-coverage.is-incomplete > strong { color:var(--ink); }
.home-delivery-estimate,.home-commission-estimate { margin-top:12px; padding:10px; border:1px solid var(--home-border); border-radius:8px; color:var(--muted); background:var(--soft); font-size:11px; line-height:1.6; }
.home-delivery-estimate > strong,.home-commission-estimate > strong { color:var(--ink); font-weight:600; }
.home-commission-estimate > p { margin-top:5px; }
.home-commission-estimate > ul { margin:7px 0 0; padding-left:16px; }
.home-delivery-estimate > p { margin-top:5px; }
.home-delivery-estimate > ul { margin:7px 0 0; padding-left:16px; }
.home-delivery-estimate > small { display:block; color:var(--muted); margin-top:5px; }
.home-delivery-estimate > a { display:inline-block; padding:5px 0; color:var(--accent); }
.home-breakdown-sources,.home-breakdown-fees { margin-top:15px; }
.home-breakdown-body h4 { margin-bottom:8px; font-size:12px; font-weight:650; }
.home-breakdown-sources > div,.home-breakdown-fees > div { display:flex; justify-content:space-between; gap:10px; padding:7px 0; font-size:11px; line-height:1.5; }
.home-breakdown-sources > div > span,.home-breakdown-fees > div > span { min-width:0; overflow-wrap:anywhere; }
.home-breakdown-sources b,.home-breakdown-fees b { flex:none; text-align:right; font-weight:600; }
.home-breakdown-sources small { display:block; margin-top:3px; color:var(--muted); font-size:11px; font-weight:400; }
.home-source-percentage { display:block; margin-top:3px; color:var(--muted); font-size:11px; line-height:1.5; font-weight:400; }
.home-source-percentage > span { display:block; }
.home-order-end { padding:15px 0; }
.home-load-more { display:flex; align-items:center; justify-content:center; gap:8px; width:100%; min-height:42px; border:1px solid var(--home-border); border-radius:9px; background:var(--paper); color:var(--ink); font-size:12px!important; }
.home-load-more:hover { border-color:var(--accent); }
.home-load-more svg { width:15px; height:15px; }
.home-end-note { padding:3px 8px; color:var(--muted); font-size:12px; line-height:1.7; text-align:center; }
.home-end-note strong { display:block; color:var(--ink); }
.home-feed-state { display:flex; align-items:center; justify-content:center; gap:9px; padding:20px 8px; color:var(--muted); font-size:12px; }
.home-small-spinner { width:15px; height:15px; border:2px solid var(--line); border-top-color:var(--accent); border-radius:50%; animation:home-refresh-spin .8s linear infinite; }
.home-empty-orders { display:flex; align-items:center; flex-direction:column; gap:10px; padding:45px 20px; text-align:center; }
.home-empty-orders > svg { width:35px; height:35px; color:var(--muted); opacity:.55; }
.home-empty-orders > strong { font-size:16px; font-weight:600; letter-spacing:-.025em; }
.home-empty-orders > p { max-width:280px; color:var(--muted); font-size:12px; line-height:1.65; }
.home-text-button { padding:6px 9px; border:1px solid var(--line); border-radius:7px; background:var(--paper); color:var(--accent); font-size:12px!important; }
.home-feed-footer { display:flex; align-items:center; justify-content:space-between; gap:9px; flex:none; min-height:31px; padding:8px 15px; border-top:1px solid var(--home-border); font-size:11px; color:var(--muted); }
.home-feed-footer > span:last-child { white-space:nowrap; }
.home-chart-card { padding:16px; }
.home-chart-card .home-card-heading { margin-bottom:11px; }
.home-chart-controls { display:flex; align-items:center; justify-content:space-between; gap:6px; }
.home-chart-controls select { max-width:100%; min-height:32px; padding:5px 23px 5px 7px; border:1px solid var(--home-border); border-radius:7px; background:var(--paper); color:var(--ink); font-size:12px; }
.home-chart-range { color:var(--muted); font-size:11px; white-space:nowrap; }
.home-chart-dates { display:grid; grid-template-columns:1fr 1fr; gap:9px; margin-top:11px; }
.home-chart-dates label { display:block; min-width:0; color:var(--muted); font-size:11px; }
.home-chart-dates input { width:100%; min-width:0; min-height:33px; margin-top:5px; padding:5px; border:1px solid var(--line); border-radius:6px; color:var(--ink); background:var(--paper); font-size:12px; }
.home-chart-total { display:flex; align-items:baseline; flex-wrap:wrap; gap:5px 7px; margin-top:15px; }
.home-chart-total > strong { font-size:25px; line-height:1.15; font-weight:650; letter-spacing:-.04em; }
.home-partial-pill { padding:3px 6px; border-radius:5px; background:var(--soft); color:var(--muted); font-size:11px; font-weight:500; }
.home-chart-coverage { min-height:30px; margin-top:7px!important; color:var(--muted); font-size:11px; line-height:1.45; }
.home-chart-plot { position:relative; height:108px; margin-top:14px; color:var(--accent); touch-action:pan-y; border-radius:5px; cursor:crosshair; }
.home-chart-plot svg { width:100%; height:100%; overflow:visible; }
.home-chart-plot rect { fill:color-mix(in srgb,var(--accent) 66%,var(--paper)); }
.home-chart-plot .is-partial { fill:color-mix(in srgb,var(--warning) 25%,var(--paper)); stroke:var(--warning); stroke-width:1; stroke-dasharray:2 2; }
.home-chart-plot .is-projected { fill:color-mix(in srgb,var(--accent) 22%,var(--paper)); stroke:color-mix(in srgb,var(--accent) 60%,var(--muted)); stroke-width:1; stroke-dasharray:3 2; }
.home-chart-plot .is-missing { fill:var(--muted); opacity:.5; }
.home-chart-zero { stroke:var(--line); stroke-width:.7; }
.home-chart-cursor { stroke:var(--ink); stroke-opacity:.5; stroke-width:1; stroke-dasharray:2 3; pointer-events:none; }
.home-chart-empty { display:flex; align-items:center; justify-content:center; height:100%; color:var(--muted); background:var(--soft); border-radius:7px; font-size:12px; text-align:center; }
.home-chart-readout { display:flex; align-items:baseline; flex-wrap:wrap; justify-content:space-between; gap:4px 7px; min-height:24px; margin-top:10px; font-size:12px; }
.home-chart-readout time { color:var(--muted); font-size:11px; }
.home-chart-readout strong { font-size:13px; }
.home-chart-readout > span { flex:1 1 100%; color:var(--warning); font-size:11px; text-align:right; }
.home-chart-notice { margin-top:7px!important; min-height:28px; color:var(--muted); font-size:11px; line-height:1.5; }
.home-panel-tabs { display:none; }
@keyframes home-refresh-spin { to { transform:rotate(360deg); } }
@media(min-width:1161px) and (max-width:1400px) { .home-overview-grid { grid-template-columns:minmax(210px,.93fr) minmax(350px,1.9fr) minmax(240px,1.08fr); gap:12px; } .home-chart-range { display:none; } .home-stat-card { padding:14px; } .home-order-reference { display:none; } .home-order-financial { flex:1; justify-content:space-between; } .home-order-sort { display:none; } .home-sync span { max-width:130px; overflow:hidden; white-space:nowrap; text-overflow:ellipsis; } }
@media(min-width:761px) and (max-width:1100px) { body.app-mode-home:not(.sidebar-collapsed) .sidebar { width:auto; } }
@media(max-width:1160px) {
  #homeWorkspace.home-dashboard-workspace:not(.hidden) { gap:11px; padding:12px 14px max(12px,env(safe-area-inset-bottom)); }
  .home-panel-tabs { display:grid; flex:none; grid-template-columns:repeat(3,minmax(0,1fr)); gap:4px; padding:4px; border:1px solid var(--home-border); border-radius:11px; background:var(--soft); }
  .home-panel-tabs button { min-height:38px; padding:7px 9px; border:1px solid transparent; border-radius:8px; background:transparent; color:var(--muted); font-size:13px; font-weight:550; }
  .home-panel-tabs button[aria-selected=true] { border-color:var(--home-border); background:var(--paper); color:var(--ink); box-shadow:var(--home-elevation); }
  .home-overview-grid { display:block; position:relative; }
  .home-overview-grid > .home-summary-rail,.home-overview-grid > .home-feed { position:absolute; inset:0; visibility:hidden; pointer-events:none; }
  .home-overview-grid[data-panel=orders] > .home-feed,.home-overview-grid[data-panel=today] > .home-summary-left,.home-overview-grid[data-panel=statistics] > .home-summary-right { visibility:visible; pointer-events:auto; }
  .home-summary-rail { padding:1px 4px 12px 1px; gap:13px; }
  .home-stat-card { padding:19px; }
  .home-rail-heading { padding:5px 4px 2px; }
  .home-today-amount { font-size:35px; }
  .home-chart-card { padding:19px; }
  .home-chart-plot { height:145px; }
  .home-chart-coverage,.home-chart-notice { min-height:0; }
  .home-chart-total > strong { font-size:29px; }
}
@media(max-width:760px) {
  #homeWorkspace.home-dashboard-workspace:not(.hidden) { padding-inline:10px; }
  .home-feed-heading { padding:13px 13px 7px; }
  .home-feed-heading h3 { font-size:19px; }
  .home-order-sort { display:none; }
  .home-overview-heading { padding:0 13px 9px; }
  .home-date { font-size:11px; }
  .home-sync { font-size:11px; }
  .home-sync span { max-width:110px; overflow:hidden; white-space:nowrap; text-overflow:ellipsis; }
  .home-order-filters { flex:0 1 auto; min-height:45px; max-height:46dvh; overflow-y:auto; padding:0 12px 8px; gap:8px; overscroll-behavior-y:contain; }
  .home-filter-selects { gap:5px; }
  .home-filter-selects select { font-size:13px; padding-left:6px; }
  .home-order-search > input { min-height:39px; font-size:14px; }
  .home-feed-controls .home-order-filters :is(input,select) { font-size:16px; }
  .home-field-label { font-size:11px; margin-bottom:4px; }
  .home-advanced-filters { grid-template-columns:1fr 1fr; max-height:min(32vh,260px); }
  .home-date-filters label { flex-wrap:wrap; gap:4px; }
  .home-order-scroll { flex:1 1 140px; min-height:100px; padding:11px 8px 2px 10px; }
  .home-order-card-header { padding:8px 10px; gap:5px; }
  .home-order-card-header > div { gap:5px; font-size:11px; }
  .home-order-quantity { font-size:13px; padding:3px 5px; }
  .home-order-products { padding-inline:10px; }
  .home-order-item { grid-template-columns:88px minmax(0,1fr); gap:6px 12px; padding-block:13px; }
  .home-product-thumb { grid-row:1 / span 2; align-self:center; width:88px; height:108px; }
  .home-product-copy { grid-column:2; align-self:end; }
  .home-product-copy > strong { font-size:13px; }
  .home-product-code { display:none; }
  .home-item-price { grid-column:2; align-self:start; text-align:left; font-size:12px; }
  .home-item-price > small { display:inline; margin-left:5px; font-size:10px; }
  .home-item-profit { margin-top:5px; }
  .home-item-profit > span { display:inline; margin-right:5px; }
  .home-item-profit .home-unit-profits { margin-top:1px; }
  .home-order-card-footer { padding:11px 10px; }
  .home-order-reference { display:none; }
  .home-order-financial { flex:1; justify-content:space-between; gap:10px; }
  .home-order-financial > .home-order-profit { flex:1; align-items:flex-start; max-width:58%; }
  .home-order-profit b { font-size:14px; text-align:left; }
  .home-order-total strong { font-size:16px; }
  .home-feed-footer { padding:7px 11px; font-size:11px; }
  .home-feed-footer > span:last-child { display:none; }
  .home-breakdown-body { padding-inline:9px; }
  .home-breakdown-body table { font-size:11px; }
}
@media(max-width:370px) { .home-sync { display:none; } .home-order-card-header time { font-size:10px; } .home-order-quantity { font-size:12px; } .home-order-item { grid-template-columns:76px minmax(0,1fr); gap:6px 9px; } .home-product-thumb { width:76px; height:96px; } .home-item-price { font-size:12px; } .home-yesterday-metrics strong { font-size:15px; } }
@media(max-width:1160px) and (max-height:650px) { .home-overview-heading { padding-bottom:6px; } .home-feed-heading { padding-block:10px 5px; } .home-panel-tabs button { min-height:34px; } .home-order-filters { max-height:42dvh; } }
@media(max-width:1160px) and (max-height:520px) { .home-order-scroll { min-height:85px; flex:1 0 85px; } .home-feed-footer { display:none; } }
@media(max-width:760px) and (max-height:520px) { .home-overview-heading,.home-feed-footer { display:none; } .home-feed-heading { padding-block:8px; } .home-order-scroll { min-height:60px; flex:1 0 85px; } .home-order-filters { max-height:45dvh; min-height:42px; } .home-panel-tabs button { min-height:30px; } }
@media(prefers-reduced-motion:reduce) { .home-dashboard-workspace *,.home-dashboard-workspace *::before,.home-dashboard-workspace *::after { animation:none!important; transition:none!important; scroll-behavior:auto!important; } }
/* Calendar results use the same gross basis and order coverage. */
.home-calendar-profit {display:grid;gap:5px;padding:14px 0;border-bottom:1px solid var(--home-border)}
.home-calendar-profit > span {font-size:13px;font-weight:650}
.home-calendar-profit > strong {font-size:clamp(25px,2.2vw,34px);font-variant-numeric:tabular-nums;line-height:1.2}
.home-calendar-profit > small {font-size:12px;color:var(--muted,#75869b)}
.home-month-picker select {min-height:42px;max-width:105px;color:var(--ink);background:var(--soft);border:1px solid var(--home-border);border-radius:8px;padding:6px;font-size:14px}
@media (max-width:600px) {.home-month-picker select {font-size:16px}}
