/* Stage 22: presentation only. No business state is stored here. */
:root{--ink:#233248;--muted:#5b6b80;--line:#dce3eb;--blue:#185da5;--surface:#fff;--bg:#f5f7fa}*{box-sizing:border-box}body{margin:0;background:var(--bg);color:var(--ink);font:15px/1.55 system-ui,sans-serif}a{color:var(--blue);text-underline-offset:3px}a:hover{color:#103c6a}button,input,select,textarea{font:inherit}button,a,input,select,summary{touch-action:manipulation}button:focus-visible,a:focus-visible,input:focus-visible,select:focus-visible,textarea:focus-visible,summary:focus-visible{outline:3px solid #dc9f20;outline-offset:3px}.visually-hidden,.skip-link:not(:focus){position:absolute;width:1px;height:1px;padding:0;overflow:hidden;clip-path:inset(50%)}.skip-link:focus{position:fixed;top:8px;left:8px;background:#fff;padding:12px;z-index:100}header{min-height:78px;background:var(--surface);border-bottom:1px solid var(--line);display:flex;align-items:center;gap:24px;padding:14px 28px}header b{font-size:22px;white-space:nowrap}header b span{font-size:13px;color:var(--muted);font-weight:400}.role-label{margin-left:auto;color:var(--muted);font-size:13px}.global-search{margin:0;display:flex;flex:1;max-width:620px;gap:8px}.global-search input{min-width:0;flex:1}.global-search button{margin:0}#menu-toggle{display:none}#sidebar{position:absolute;left:0;top:78px;width:226px;min-height:calc(100vh - 78px);padding:20px 14px;background:white;border-right:1px solid var(--line)}.nav-group{margin-bottom:22px}.nav-group h2{font-size:11px;letter-spacing:.08em;text-transform:uppercase;color:var(--muted);padding:0 12px;margin:0 0 8px}.nav-group a,.nav-extra a{display:block;text-decoration:none;color:var(--ink);padding:10px 12px;border-radius:7px;line-height:1.35;margin:2px 0}.nav-group a:hover{background:#f0f4f8}.nav-group a[aria-current=page]{background:#e9f1fb;color:#124d8b;font-weight:650}.nav-extra{padding:10px;font-size:13px}#sidebar form{padding:8px 12px}#sidebar button{background:#f0f3f7;color:var(--ink)}main{margin-left:226px;padding:28px 32px 60px;max-width:1900px;min-width:0}.signed-out main{margin:40px auto;max-width:520px}.page-heading{margin:0 0 24px}.page-heading h1{margin:0 0 6px;font-size:30px;line-height:1.25;letter-spacing:-.025em}.page-heading p{margin:0;color:var(--muted)}h2{font-size:21px;margin:30px 0 14px;line-height:1.3}h3{font-size:17px}p{overflow-wrap:anywhere}section,.notice{padding:20px;background:white;border:1px solid var(--line);border-radius:12px}.cards{display:grid;grid-template-columns:repeat(auto-fit,minmax(180px,1fr));gap:12px}.cards section{min-width:0}.cards small{color:var(--muted)}.cards strong{display:block;font-size:23px;font-weight:650;margin-top:8px;overflow-wrap:anywhere}.quick-actions{display:flex;gap:10px;flex-wrap:wrap;margin:0 0 28px}.quick-actions a,.focus-action{display:inline-block;text-decoration:none;border:1px solid #bed0e4;background:white;border-radius:8px;padding:11px 16px;min-height:44px}.quick-actions a:first-child{background:var(--blue);color:white;border-color:var(--blue)}.table{overflow:auto;max-width:100%;background:white;margin:16px 0 24px;border:1px solid var(--line);border-radius:10px}table{width:100%;border-collapse:separate;border-spacing:0}th,td{text-align:left;padding:14px;border-bottom:1px solid #e8edf2;vertical-align:top}th{position:sticky;top:0;z-index:1;background:#f0f4f8;font-size:12px;font-weight:650;color:#45556a}td{font-size:14px;min-width:95px;max-width:440px;overflow-wrap:anywhere}td:first-child{min-width:200px}tr:last-child td{border-bottom:0}tr:hover td{background:#f8fbfe}.badge{display:inline-block;border-radius:6px;padding:3px 8px;font-size:12px;line-height:1.5;background:#eaf1fa;color:#22588a}.badge.neutral{background:#edf0f3;color:#526070}.badge.ok{background:#e5f2eb;color:#246242}.badge.warn{background:#fff2d8;color:#805411}.badge.danger{background:#fce8e6;color:#a52927}form{display:flex;flex-wrap:wrap;gap:12px;align-items:end;margin:16px 0}label{display:block;font-size:13px;color:#43536a}input,select,textarea{display:block;width:auto;max-width:100%;min-height:44px;padding:10px 12px;border:1px solid #aab8c8;background:white;color:var(--ink);border-radius:7px}input[type=checkbox]{display:inline-block;width:20px;min-height:20px;height:20px;vertical-align:middle;margin:0 6px 0 0}label:has(input[type=checkbox]){font-size:14px;max-width:420px;line-height:1.6}button{background:var(--blue);color:white;border:1px solid transparent;border-radius:7px;padding:10px 16px;min-height:44px;cursor:pointer;font-weight:600}button:hover{filter:brightness(.93)}button:disabled{opacity:.5;cursor:wait}.result{flex-basis:100%;margin:0;color:#345571;overflow-wrap:anywhere}.notice{border-left:4px solid #c49225}details{font-size:13px;color:var(--muted);margin:12px 0}summary{cursor:pointer;padding:10px 0;font-weight:550}details[open]>summary{margin-bottom:8px}pre{white-space:pre-wrap;overflow-wrap:anywhere;font:inherit;background:white;padding:20px;border:1px solid var(--line);border-radius:10px}small{color:var(--muted)}li{margin:12px 0}#loading:empty{display:none}#daily-focus article{padding:16px 0;border-bottom:1px solid var(--line)}#daily-focus article:last-child{border-bottom:0}#daily-focus h3{margin:4px 0 8px}.stock-count{max-width:820px;margin:auto}.stock-count section{margin:20px 0}.stock-count input[type=number]{font-size:32px;min-height:64px;width:100%;max-width:360px}.stock-count #physical-count-form>label{flex:1 1 200px}.stock-count #physical-count-form>button{width:100%;min-height:56px;font-size:18px}.stock-quick{display:flex;gap:8px;width:100%}.stock-quick button{flex:1;font-size:20px;min-height:52px;background:#edf3fb;color:#22588a}.stock-count section>p>a{display:inline-block;min-height:48px;padding:12px 18px;border:1px solid #bed0e4;border-radius:7px}.stock-count .result{font-size:17px}#bulk-entry textarea{width:100%;min-height:260px;font:16px/1.5 monospace}#bulk-entry label{margin:12px 0}#bulk-entry button{margin:6px 8px 6px 0}td form{min-width:240px}td input,td select{max-width:100%}td form>label{flex-basis:100%}td form>button{width:100%}
@media(max-width:900px){header{flex-wrap:wrap;gap:12px;padding:12px 16px}header b{font-size:20px}#menu-toggle{display:block;background:#edf2f8;color:var(--ink)}.global-search{order:4;flex-basis:100%;max-width:none}.role-label{font-size:12px}#sidebar{display:none;position:static;width:auto;min-height:0;border-bottom:1px solid var(--line);border-right:0}body.nav-open #sidebar{display:block}main{margin-left:0;padding:22px 16px 48px}.page-heading h1{font-size:26px}.cards{grid-template-columns:repeat(2,minmax(0,1fr))}.cards section{padding:14px}.cards strong{font-size:20px}.quick-actions{display:grid;grid-template-columns:1fr 1fr}.quick-actions a{font-size:14px;text-align:center;padding:11px 8px}form>label{flex:1 1 160px}input,select{width:100%}form>button{max-width:100%}th,td{padding:12px}.table{border-radius:8px}.stock-count section{padding:16px}.stock-count h2{font-size:22px}.stock-count #physical-count-form>label{flex-basis:100%}.stock-count input[type=number]{max-width:none}#sidebar .nav-group{margin-bottom:12px}#sidebar nav{display:grid;grid-template-columns:1fr 1fr;gap:12px}.global-search input{width:0}.signed-out main{margin-top:16px}}@media(prefers-reduced-motion:no-preference){a,button{transition:background-color .12s ease}}
@media(max-width:900px){.cost-workspace table,.cost-workspace tbody,.cost-workspace tr,.cost-workspace td{display:block;width:100%;max-width:none;min-width:0}.cost-workspace tr:has(th){display:none}.cost-workspace td::before{content:attr(data-label);display:block;font-size:12px;color:var(--muted);margin-bottom:5px}.cost-workspace tr{border-bottom:6px solid var(--bg)}.cost-workspace td{border-bottom:0;padding:10px 14px}.cost-workspace td form{min-width:0}.cost-workspace td form>label{width:100%;max-width:none}.cost-workspace .table{overflow:visible}}
.cards time{font-size:16px;font-weight:500;line-height:1.6;display:block}.badge{white-space:nowrap}td{min-width:110px}

/* Denny Business: shared application shell and component palette. */
:root {
  --ink: #192c32; --muted: #51666d; --line: #d6e1e2;
  --blue: #09675f; --surface: #fff; --bg: #f2f6f5;
  --nav: #142d32; --nav-text: #e3eeed; --accent: #85e1c4;
}
body {font-family: "Segoe UI",system-ui,sans-serif; line-height: 1.5;}
header {background: #fff; min-height: 72px; border-bottom: 1px solid var(--line);}
header b {letter-spacing: -.04em; color: #153d3b;}
header b span {letter-spacing: .02em;}
.role-label {border: 1px solid var(--line); border-radius: 2em; padding: .3em .9em;}
#sidebar {background: var(--nav); color: var(--nav-text); border-right: 0;}
#sidebar h2 {color: #a9c4c4; font-weight: 650;}
#sidebar a, #sidebar summary {color: var(--nav-text);}
#sidebar a:hover, #sidebar a:focus-visible {background: #24474b; color: white;}
#sidebar a[aria-current="page"] {background: #29514e; color: #e5fff3; box-shadow: inset 3px 0 var(--accent);}
#sidebar details,#sidebar form {background: transparent; border-color: #3c585d;}
#sidebar button {color: #d9e9e8; background: #254349; border: 1px solid #486167;}
.page-heading {padding-bottom: 18px; border-bottom: 1px solid var(--line);}
.page-heading h1 {font-weight: 680; font-size: clamp(1.65rem, 3vw, 2.35rem); letter-spacing: -.04em;}
.cards {gap: 10px; margin-block: 12px;}
.cards section {border-radius: 10px; padding: 16px 18px; border-top: 3px solid #a8cfc4;}
.cards strong, td {font-variant-numeric: tabular-nums;}
.cards strong {line-height: 1.2; letter-spacing: -.025em;}
section, .table, details, .notice {border-color: var(--line);}
th {background: #eaf2ef; color: #334d4a;}
tr:hover td {background: #f5faf8;}
button {border-radius: 8px;}
input:not([type="checkbox"]):not([type="radio"]),select,textarea {border-color: #a4b7b7; border-radius: 7px; color: var(--ink);}
form[method="get"]:not(.global-search) {padding: 12px 16px; background: #eaf2ef; border-radius: 10px;}
.quick-actions a {border-color: #aecdc6; color: var(--blue);}
.quick-actions a:first-child {color: white;}
.notice {border-inline-start: 4px solid #aa740e;}
:focus-visible {scroll-margin: 12px;}
@media(min-width:901px) {
  .signed-in header {position: sticky; top: 0; z-index: 5; height: 72px;}
  #sidebar {position: fixed; top: 72px; bottom: 0; min-height: 0; overflow-y: auto; scrollbar-color: #507574 var(--nav);}
  .signed-in main {padding: 26px clamp(20px,3vw,50px) 60px;}
  :target {scroll-margin-top: 86px;}
}
@media(max-width:900px) {
  #sidebar nav {grid-template-columns: repeat(auto-fit,minmax(min(155px,100%),1fr));}
  .role-label {max-width: 38vw; overflow-wrap: anywhere;}
  .cards section {padding: 12px;}
  .quick-actions a, #sidebar a {min-height: 44px;}
  input, select, textarea {font-size: 16px;}
}
@media(max-width:380px) {
  .cards {grid-template-columns: minmax(0,1fr);}
  .quick-actions {grid-template-columns: minmax(0,1fr);}
}
.table-tools {display:flex;align-items:end;flex-wrap:wrap;gap:12px;margin:1rem 0 .35rem;}
.table-tools label {color:var(--muted);font-size:.85rem;}
.table-tools input {display:block;max-width:100%;width:16rem;}
.table-tools small {color:var(--muted);}
.table-tools + .table {max-height: min(76vh,850px);margin-top:0;}
.table-tools + .table td:first-child {position:sticky;left:0;background:white;box-shadow:1px 0 var(--line);min-width:105px;max-width:190px;}
.table-tools + .table th:first-child {left:0;z-index:2;}
.table th .sort-column {background:transparent;color:inherit;padding:4px 0;margin:0;border:0;text-align:left;font:inherit;min-height:32px;}
.sort-column::after {content:' ↕';color:#53756e;}
[aria-sort=ascending] .sort-column::after {content:' ↑';}
[aria-sort=descending] .sort-column::after {content:' ↓';}
#loading:not(:empty),.result:not(:empty) {padding:.55rem .8rem;background:#e8f3ef;border-left:3px solid var(--blue);}
[role=alert]:not(:empty) {border-color:#b34836;background:#fff0eb;}
@media(max-width:900px){.table-tools + .table td:first-child,.table-tools + .table th:first-child{position:static;}}

/* Sales Detective: presentation only, scoped to this page. */
.sales-detective-ux .sd-intro{font-size:1.15rem}.sales-detective-ux .sd-source{color:#51646b;font-size:.9rem}
.sales-detective-ux .sd-overview,.sales-detective-ux .sd-finding{padding:22px;border:1px solid #d9e4e5;border-radius:16px;background:white;margin:20px 0}
.sales-detective-ux .sd-finding{border-left:4px solid #cf8b32;background:#fffaf1}
.sales-detective-ux .cards strong{font-size:1.45rem}.sales-detective-ux .cards strong small{display:block;font-weight:400;font-size:.85rem;margin-top:12px;color:#51646b}
.sales-detective-ux .sd-help{background:#eaf3f2;padding:16px;border-radius:12px;margin:20px 0}.sales-detective-ux summary{cursor:pointer;font-weight:600;min-height:30px}
.sales-detective-ux .sd-charts details{background:white;border:1px solid #d9e4e5;border-radius:12px;padding:16px;margin:12px 0}
.sales-detective-ux svg{display:block;width:100%;height:auto;min-height:160px}.sales-detective-ux svg text{fill:#51646b;font-size:12px}.sales-detective-ux .sd-grid{stroke:#e1e9e9}.sales-detective-ux .sd-line{fill:none;stroke:#087c75;stroke-width:2.5;stroke-linejoin:round}.sales-detective-ux .sd-dot{fill:#087c75}
.sales-detective-ux .sd-dates label{flex:1 1 180px;min-width:0}.sales-detective-ux .sd-dates input{width:100%;min-width:0}
@media(max-width:600px){.sales-detective-ux .sd-overview,.sales-detective-ux .sd-finding{padding:16px}.sales-detective-ux .cards{grid-template-columns:1fr}.sales-detective-ux .sd-dates label{flex-basis:100%}.sales-detective-ux .sd-dates button{width:100%}.sales-detective-ux svg{min-height:120px}}

@media(max-width:600px){.sales-detective-ux svg text{font-size:28px}}
