/* Shared visual foundation. Loaded after each page's functional styles. */
:root{color-scheme:dark;--bg:#0d1015;--panel:#171b22;--line:#2b313b;--text:#e8eaed;--muted:#9aa0aa;--blue:#4285f4;--gp-bg:var(--bg);--gp-panel:var(--panel);--gp-panel-hover:#1d222b;--gp-border:var(--line);--gp-border-strong:#465367;--gp-text:var(--text);--gp-text-2:#b1b7c2;--gp-muted:var(--muted);--gp-blue:#4285f4;--gp-red:#ea4335;--gp-yellow:#fbbc05;--gp-green:#34a853}
html{scrollbar-gutter:stable;background:var(--bg)}
body{display:block;margin:0;color:var(--text);font:14px/1.5 "Segoe UI",Arial,sans-serif;background:radial-gradient(ellipse at 5% 0%,#4285f410,transparent 40%),radial-gradient(ellipse at 95% 0%,#34a85309,transparent 35%),var(--bg);background-attachment:fixed}
body::before{display:none}*,*::before,*::after{box-sizing:border-box}button,input,select,textarea{font-family:inherit}a,button,input,select,textarea{touch-action:manipulation}a:focus-visible,button:focus-visible{outline:2px solid #8ab4f8;outline-offset:3px}
.app-header,body>header{position:sticky;top:0;z-index:100;display:flex;flex-wrap:nowrap;align-items:center;gap:24px;min-height:84px;padding:12px 28px;margin:0;background:#101319f5;border-bottom:1px solid var(--line);box-shadow:none;backdrop-filter:blur(16px)}
.site-brand{display:flex;align-items:center;gap:12px;flex:0 0 220px;color:var(--text);text-decoration:none;white-space:nowrap}
.site-mark{display:grid;place-items:center;width:42px;height:42px;flex:none;border:3px solid transparent;border-radius:50%;background:linear-gradient(#101319,#101319) padding-box,conic-gradient(#4285f4 0 25%,#ea4335 25% 50%,#fbbc05 50% 75%,#34a853 75% 100%) border-box;font-size:13px;font-weight:800;letter-spacing:0}
.site-brand-copy{font-size:13px;font-weight:800;letter-spacing:1.7px;line-height:1.4}.site-brand-copy small{display:block;margin-top:3px;color:var(--muted);font-size:9px;font-weight:400;letter-spacing:1.8px}
.app-header .app-nav,body>header nav{display:flex;flex:1 1 auto;order:0;align-items:center;justify-content:flex-start;gap:4px;width:auto;margin:0;flex-wrap:nowrap;min-width:0}
.app-header .app-nav button,body>header nav a{display:inline-flex;align-items:center;justify-content:center;width:auto;min-height:38px;margin:0;padding:9px 12px;border:1px solid transparent;border-radius:9px;background:transparent;color:var(--muted);font:600 13px/18px "Segoe UI",Arial,sans-serif;white-space:nowrap;text-decoration:none;box-shadow:none}
.app-header .app-nav button::after{display:none}.app-header .app-nav button:hover,body>header nav a:hover{background:#ffffff08;color:var(--text)}
.app-header .app-nav button.nav-active,body>header nav a.selected,#workspace .app-nav button:first-child{color:#a8c7fa;background:#4285f41c;border-color:#4285f438}
.app-header .app-user,body>header .app-user{display:flex;flex:0 0 auto;order:0;align-items:center;justify-content:flex-end;gap:12px;width:auto;margin-left:auto;flex-wrap:nowrap}
.app-header .user-chip,body>header #identity{display:block;flex:0 0 140px;width:140px;max-width:140px;margin:0;color:var(--muted);text-align:right;font-size:11px;line-height:16px;white-space:normal;overflow-wrap:anywhere}
.header-stats{display:flex;order:0!important;flex:0 0 352px;width:352px;gap:5px}.header-stat{flex:1 1 0;min-width:0;padding:7px 8px;border:1px solid var(--line);border-radius:9px;background:#171b22;line-height:1.2}.header-stat.earning{flex-grow:1.15}.header-stat small{font-size:9px;color:var(--muted)}.header-stat strong{font-size:14px;color:var(--text)}.header-stat.earning strong{color:#81c995}.header-stat.rest strong{color:#fdd663}
.app-header .cabinet-link,body>header .cabinet-link{min-height:38px;margin:0!important;padding:9px 12px;font:600 12px/18px "Segoe UI",Arial,sans-serif;border-radius:9px}
.dashboard-shell,.section-content,.account-shell,body>main{width:100%;max-width:1840px;margin:0 auto;padding:32px 28px 64px}
.account-grid{max-width:1100px}.dashboard-hero{padding:32px;margin-bottom:24px;border-radius:16px;background:linear-gradient(120deg,#1b2029,#14181f);box-shadow:none}.dashboard-hero h1{font-size:36px;line-height:1.2;letter-spacing:-1px;text-align:left;margin:12px 0 16px}.dashboard-hero::after{opacity:.06}.dashboard-grid{grid-template-columns:repeat(2,minmax(0,1fr));gap:20px}.workspace-card{min-height:210px;border-radius:14px;box-shadow:none}.workspace-card.yellow::before{background:linear-gradient(90deg,#4285f4 0 25%,#ea4335 25% 50%,#fbbc05 50% 75%,#34a853 75%)}
body>main h1,.section-heading h1,.account-heading h1{font-size:30px;line-height:1.25;letter-spacing:-.6px;text-align:left}.section-toolbar .section-heading{margin:0}.account-heading h1{margin:8px 0 14px}.eyebrow,.section-eyebrow,.dashboard-eyebrow{color:#8ab4f8;font-size:11px;font-weight:700;letter-spacing:2px}
.table-wrap,.farm-empty{background:var(--panel);border-color:var(--line)}th{background:#20252e;color:#b4bdcb}.card,.account-card{background:var(--panel);border-color:var(--line);border-radius:14px;box-shadow:none}.farm-empty-icon,.account-avatar{background:#4285f41c;color:#a8c7fa}.primary{background:var(--blue);border-color:var(--blue)}
@media(max-width:1390px){.app-header,body>header{flex-wrap:wrap;gap:12px 24px}.app-header .app-user,body>header .app-user{flex:0 0 100%;width:100%;justify-content:flex-end}.app-header .user-chip,body>header #identity{margin-right:auto;text-align:left}.app-header .app-nav,body>header nav{flex:1 1 auto}}
@media(max-width:700px){.app-header,body>header{position:relative;padding:14px;gap:14px}.site-brand{flex-basis:100%}.app-header .app-nav,body>header nav{order:0;flex:0 0 100%;width:100%;overflow:auto}.app-header .app-nav button,body>header nav a{padding:8px 10px}.app-header .app-user,body>header .app-user{flex-wrap:wrap;gap:12px}.header-stats{order:2!important;flex:0 0 100%;width:100%;gap:5px}.header-stat{padding:7px 5px}.header-stat small{font-size:8px}.header-stat strong{font-size:13px}.dashboard-shell,.section-content,.account-shell,body>main{padding:24px 14px 40px}.dashboard-grid{grid-template-columns:1fr}.dashboard-hero{padding:24px}.dashboard-hero h1{font-size:30px}.account-grid{grid-template-columns:1fr}.section-toolbar{flex-wrap:wrap}.section-tools{max-width:100%;flex-wrap:wrap}.table-search-box{max-width:100%}.account-heading h1,body>main h1,.section-heading h1{font-size:26px}}
/* Override the legacy Old table paint, retaining its state colours and editors. */
.table-wrap{background:var(--panel)!important;border:1px solid var(--line)!important;box-shadow:none!important}.table-wrap table{background:var(--panel)!important}.table-wrap th,.table-wrap th:first-child{background:#20252e!important;color:#b4bdcb!important;border:0!important;border-bottom:1px solid var(--line)!important;font-size:12px!important;font-weight:600!important;letter-spacing:0!important;padding:14px 12px!important;text-align:left;text-transform:none}.table-wrap td{border-top:0;border-left:0}.table-wrap{scrollbar-color:#465367 var(--panel)}

/* Shared action button template, sourced from Old. Use .gp-button for future actions.
   Navigation, tabs and compact table tools retain their dedicated dimensions. */
:root{--button-fill:linear-gradient(135deg,#3478ea,#2667cf);--button-border:rgba(66,133,244,.28);--button-shadow:0 7px 20px rgba(66,133,244,.13);--button-radius:10px}
body button:not(:where(header *,.table-wrap *,.tabs *)),.gp-button{
 min-height:46px;padding:12px 16px!important;border:1px solid var(--button-border)!important;border-radius:var(--button-radius)!important;background:var(--button-fill)!important;color:#fff!important;font:700 14px/20px "Segoe UI",Arial,sans-serif!important;box-shadow:var(--button-shadow)!important;cursor:pointer;transition:transform .15s ease,filter .15s ease,border-color .15s ease;text-align:center;text-decoration:none;vertical-align:middle
}
body button:not(:where(header *,.table-wrap *,.tabs *)):enabled:hover,.gp-button:not(:disabled):hover{filter:brightness(1.08)}
body button:not(:where(header *,.table-wrap *,.tabs *)):enabled:active,.gp-button:not(:disabled):active{transform:translateY(1px)}
body button:not(:where(header *,.table-wrap *,.tabs *)):focus-visible,.gp-button:focus-visible{outline:2px solid #8ab4f8;outline-offset:3px}
/* Old's muted Cancel treatment is the secondary variant. */
body button:is(.account-secondary,[data-cancel],[data-remove],#issueBack,#issueClose,#closeSale,#closeDetail,#prevAccounts,#nextAccounts,#prevSales,#nextSales),body .modal-actions button:first-child,.gp-button--secondary{background:rgba(255,255,255,.045)!important;border-color:var(--gp-border)!important;color:#bac1cc!important;box-shadow:none!important}
body button.account-logout,.gp-button--danger{background:#ea433510!important;border-color:#ea433540!important;color:#f1b7bb!important;box-shadow:none!important}
body .outcome-rest-modal button[type=submit]{background:#65501c!important;border-color:#a98b3e!important;color:#ffe1a2!important;box-shadow:none!important}
body button:not(:where(header *,.table-wrap *,.tabs *)):disabled,.gp-button:disabled{opacity:.5!important;cursor:not-allowed!important;filter:none!important;transform:none!important;box-shadow:none!important}
@media(prefers-reduced-motion:reduce){body button,.gp-button{transition:none!important}}
@media(max-width:700px){.farm-actions button{flex:1 1 140px;white-space:nowrap}}
/* Farm-wide semantic palette and stable inline editing. */
:root{--farm-sold:#154c36;--farm-ready:#b5de70;--farm-working:#d1d5db;--farm-invalid:#b52c3c;--farm-rest-timer:#f5cf54;--farm-rest:#ed963e}
body .table-wrap tr[data-farm-state] td,body .table-wrap tr:is(.row-working,.row-ready,.row-ready_pending,.row-sold,.row-invalid,.row-rest_timer,.row-rest) td{background:var(--row-bg)!important;color:var(--row-fg)!important;border-bottom:1px solid #ffffff20!important}
[data-farm-state=working],.row-working{--row-bg:#292e36;--row-fg:var(--farm-working)}
[data-farm-state=sold],.row-sold{--row-bg:var(--farm-sold);--row-fg:#d3f8e3}
[data-farm-state=ready],.row-ready,.row-ready_pending{--row-bg:#334728;--row-fg:var(--farm-ready)}
[data-farm-state=invalid],.row-invalid{--row-bg:#53252e;--row-fg:#ffabb4}
[data-farm-state=rest_timer],.row-rest_timer{--row-bg:#4c4223;--row-fg:var(--farm-rest-timer)}
[data-farm-state=rest],.row-rest{--row-bg:#523721;--row-fg:var(--farm-rest)}
[data-farm-state=sale_reserved]{--row-bg:#243b50;--row-fg:#b6d9ff}
body #oldBody tr[data-farm-state] td:first-child,.farm-table tr[data-farm-state] td:first-child{border-left:4px solid var(--row-fg)!important}
.header-stat.ready strong{color:var(--farm-ready)}.header-stat.working strong{color:var(--farm-working)}.header-stat.rest_timer strong{color:var(--farm-rest-timer)}.header-stat.rest strong{color:var(--farm-rest)}
.table-wrap:has(#oldBody) table{table-layout:fixed;width:100%;min-width:1400px}.table-wrap:has(#oldBody) th:first-child{width:200px}.table-wrap:has(#oldBody) th:last-child{width:200px}
body #oldBody td{height:76px;position:relative;box-sizing:border-box;overflow:hidden;text-overflow:ellipsis;white-space:nowrap;padding:12px!important}
body #oldBody td.editing{padding:12px!important}body #oldBody .cell-editor{position:absolute;inset:12px;width:calc(100% - 24px)!important;height:calc(100% - 24px)!important;margin:0!important;padding:8px!important;min-width:0;box-sizing:border-box;border:2px solid #8ab4f8;border-radius:6px;color:#fff;background:#192335;font:inherit}
body #oldBody td[data-field=state]{white-space:normal}.outcome-note{max-height:32px;overflow:auto}.outcome-actions{align-items:center}.outcome-timer{color:inherit!important}
.farm-table table{table-layout:fixed;width:2400px;min-width:2400px}.farm-table th:first-child{width:250px}.farm-table th:nth-child(4){width:210px}.farm-table th:nth-child(8){width:240px}.farm-table td{height:100px;position:relative;overflow:hidden;text-overflow:ellipsis}.farm-table td:has(.field-editor){height:100px}.farm-table .field-editor{position:absolute;inset:12px;width:calc(100% - 24px)!important;height:44px;box-sizing:border-box;margin:0;border:2px solid #8ab4f8}.farm-table td .field-value{white-space:nowrap;overflow:hidden;text-overflow:ellipsis;max-width:100%}.farm-table td select{max-width:100%;width:100%}
.section-tools,.farm-actions{align-items:center!important}.section-tools>button,.farm-actions>button{flex:0 0 auto;min-height:46px;align-self:center}.section-toolbar{align-items:center!important}.table-wrap{overflow-x:auto;max-width:100%}
@media(max-width:700px){.section-tools{width:100%;gap:10px}.section-tools .table-search-box{flex:1 1 100%;width:100%}.section-tools>button,.farm-actions>button{flex:1 1 140px}.table-wrap td button{min-height:36px}.table-wrap{overscroll-behavior-x:contain}}
body .table-wrap #oldBody tr[data-farm-state] > td{background:var(--row-bg)!important;color:var(--row-fg)!important}body #oldBody .cell-copy{display:block;max-width:100%;overflow:hidden;text-overflow:ellipsis;white-space:nowrap;padding-right:32px}body #oldBody .cell-copy,.farm-table .field-copy{color:inherit!important}.farm-table .field-copy{overflow:hidden;text-overflow:ellipsis;white-space:nowrap;min-width:0!important;max-width:100%}
@media(max-width:700px){body .section-tools{display:grid!important;grid-template-columns:1fr 1fr;align-items:center;width:100%}body .section-tools .table-search-box{grid-column:1 / -1;width:100%;margin:0}body .section-tools>button{width:100%!important;height:46px!important;min-height:46px!important;flex:none!important;margin:0!important;padding:8px!important;font-size:12px!important}body .section-toolbar .section-heading{width:100%;text-align:left}body .section-toolbar .section-heading h1{text-align:left}body .farm-actions>button{flex:1 1 140px;height:46px}}
/* Equal toolbar control heights, with in-flow search icon and count. */
body .section-toolbar{flex-wrap:wrap;gap:18px}body .section-tools{flex:1 1 auto;display:flex!important;flex-direction:row;flex-wrap:wrap;justify-content:flex-end;gap:10px;min-width:0;max-width:100%}
body .section-tools .table-search-box{display:flex;align-items:center;gap:10px;height:46px!important;min-height:46px;flex:0 1 240px;width:240px;padding:0 12px!important;margin:0!important;box-sizing:border-box}
body .table-search-box .search-icon,body .table-search-box .row-count{position:static!important;transform:none!important;flex:none;margin:0!important;line-height:20px}body .table-search-box #tableSearch{flex:1 1 auto;min-width:0;width:100%;height:44px!important;margin:0!important;padding:0!important;line-height:44px!important;border:0;background:transparent;box-shadow:none;text-indent:0}
body .section-tools>button{height:46px!important;min-height:46px!important;margin:0!important;flex:0 0 auto}body .old-status-filters{display:flex;flex:1 1 auto;gap:5px;align-items:center;min-width:0;overflow-x:auto;max-width:100%;padding:2px 0}body .old-status-filters button{min-height:46px!important;height:46px!important;flex:0 0 auto;width:auto!important;padding:8px 10px!important;font-size:11px!important;background:#191f28!important;border:1px solid #424b58!important;box-shadow:none!important;white-space:nowrap;color:var(--tag-color,#d1d5db)!important}body .old-status-filters button[aria-pressed=true]{background:#344054!important;border-color:var(--tag-color,#d1d5db)!important;box-shadow:inset 0 -3px var(--tag-color,#d1d5db)!important} [data-status-filter=ready]{--tag-color:#b5de70}[data-status-filter=sold]{--tag-color:#6bb995}[data-status-filter=invalid]{--tag-color:#ff8997}[data-status-filter=rest_timer]{--tag-color:#f5cf54}[data-status-filter=rest]{--tag-color:#ed963e}[data-status-filter=sale_reserved]{--tag-color:#9dcaf1}
@media(max-width:1500px){body .section-tools{flex-basis:100%}body .old-status-filters{flex:1 1 500px}}
@media(max-width:700px){body .section-tools{display:grid!important;grid-template-columns:1fr 1fr}body .old-status-filters{grid-column:1 / -1;width:100%;flex-wrap:nowrap}body .section-tools .table-search-box{grid-column:1 / -1;width:100%;height:46px}body .section-tools>button{width:100%!important}body .old-status-filters button{min-height:44px!important;height:44px!important}}
/* Compact six-state account summary, separate from earnings. */
body .header-stats{flex:0 0 auto;width:auto;max-width:100%;gap:8px}body .header-stats .earning{flex:0 0 auto;min-width:78px}body .header-stat.account-summary{display:flex;align-items:center;justify-content:center;gap:8px;flex:0 1 auto;min-width:0;padding:10px 12px;white-space:nowrap;font-variant-numeric:tabular-nums}body .account-summary strong{font-size:15px;line-height:20px}body .account-summary .summary-divider{color:#626b78;font-size:12px}.account-summary .summary-sold{color:#58a980}.account-summary .summary-ready{color:#b5de70}.account-summary .summary-working{color:#d1d5db}.account-summary .summary-rest_timer{color:#f5cf54}.account-summary .summary-rest{color:#ed963e}.account-summary .summary-invalid{color:#ff8997}.account-summary strong:focus-visible{outline:1px solid currentColor;outline-offset:3px;border-radius:2px}
@media(max-width:700px){body .header-stats{flex:0 0 100%;width:100%}body .header-stat.account-summary{flex:1 1 auto;gap:7px;padding:8px}.account-summary strong{font-size:14px}}
/* Every Old state filter has the same dimensions. */
body .old-status-filters button{width:116px!important;min-width:116px!important;max-width:116px!important;flex:0 0 116px!important;height:46px!important;min-height:46px!important;padding:8px 5px!important;text-align:center}
@media(max-width:700px){body .old-status-filters button{width:116px!important;min-width:116px!important;height:46px!important;min-height:46px!important}}
body .account-summary .summary-caption{font-size:11px;font-weight:600;color:#aab4c2;margin-right:3px}body .account-summary .summary-link{display:inline-flex;align-items:center;justify-content:center;min-width:20px;min-height:28px;text-decoration:none;border-radius:5px;background:transparent;padding:0;color:inherit}body .account-summary .summary-link:hover{background:#ffffff12}body .account-summary .summary-link:focus-visible{outline:2px solid #8ab4f8;outline-offset:2px}@media(max-width:700px){body .header-stat.account-summary{gap:4px}body .account-summary .summary-link{min-width:22px;min-height:32px}}

/* Two independent account summaries, shared by farmer and staff headers. */
body .header-account-summaries{display:flex;flex-direction:column;gap:3px;min-width:0}
body .header-account-summaries .account-summary{padding:2px 8px;justify-content:flex-end;gap:4px}
body .header-account-summaries .summary-caption{margin-right:auto}
body .account-summary .summary-appeal{color:#ed963e}
body .header-account-summaries .summary-link{min-height:24px}
body button.f14-card{display:block!important;cursor:pointer;text-align:left!important;color:var(--text)!important;font:inherit!important;background:var(--panel)!important;border:1px solid var(--line)!important;box-shadow:none!important;padding:18px!important}
body button.f14-card:hover{border-color:#8ab4f8!important}body button.f14-card[aria-pressed=true]{border-color:#8ab4f8!important;box-shadow:inset 0 -3px #8ab4f8!important}
body .tabs{flex-wrap:wrap}
.f14-card:hover{border-color:#8ab4f8}.f14-card[data-f14-state=appeal] strong,.f14-appeal{color:#ed963e}
.f14-card[data-f14-state=ready] strong,.f14-ready{color:#b5de70}.f14-invalid{color:#ff8997}
@media(max-width:1250px){body .app-header,body>header{flex-wrap:wrap}body .app-header .app-user,body>header .app-user{flex:1 0 100%;justify-content:flex-end}}
@media(max-width:700px){body .header-stats{justify-content:space-between}body .header-account-summaries{flex:1 1 auto}body .header-account-summaries .account-summary{gap:3px;padding:2px 5px}body .header-stats .earning{min-width:70px}}
