.nav-item { color:inherit; font:inherit; font-size:13px; background:transparent; width:100%; text-align:left; text-decoration:none; }
.nav-item:focus-visible, button:focus-visible, a:focus-visible { outline:2px solid #00afee; outline-offset:3px; }
.overview-kpis { display:grid; grid-template-columns:repeat(4,minmax(0,1fr)); gap:14px; margin-bottom:18px; }
.overview-kpis .card { padding:18px; }
.overview-grid { display:grid; grid-template-columns:minmax(0,1.6fr) minmax(260px,1fr); gap:18px; margin-bottom:18px; }
.overview-title { font-size:15px; font-weight:650; margin-bottom:5px; }
.overview-sub { font-size:12px; color:#74839a; line-height:1.5; }
.overview-actions { display:flex; justify-content:space-between; gap:12px; align-items:center; margin-bottom:16px; }
/* Team form modal: the member role adds the Allowed Pages checklist, which can run past the
   viewport. The card scrolls inside the overlay so Save is always reachable. */
#user-form-modal > div { max-height:92vh; overflow-y:auto; -webkit-overflow-scrolling:touch; }
.attention-item { display:flex; align-items:center; gap:12px; width:100%; padding:14px 0; background:none; border:0; border-top:1px solid #e2e8f0; color:#0f1b2d; text-align:left; font:inherit; cursor:pointer; }
.attention-item strong { display:block; font-size:13px; margin-bottom:4px; }
.attention-item span { font-size:12px; color:#74839a; }
.attention-item .attention-arrow { margin-left:auto; color:#007bb0; }
.source-row { display:flex; align-items:center; gap:10px; padding:11px 0; border-bottom:1px solid #e2e8f0; font-size:12px; }
.source-row:last-child { border:0; }
.source-row small { display:block; margin-top:4px; color:#74839a; font-size:11px; }
.source-row .source-label { margin-left:auto; text-align:right; }
.tone-ok { color:#047857; } .tone-warn { color:#b45309; } .tone-error { color:#dc2626; } .tone-muted { color:#74839a; }
#sync-result { padding:12px 24px; border-bottom:1px solid #e2e8f0; font-size:12px; background:#f8fafc; }
#sync-result[hidden] { display:none; }
#sync-result summary { cursor:pointer; font-weight:600; }
#sync-result li { margin:8px 0 0 20px; }
.metric-definition { cursor:help; text-decoration:underline dotted #74839a; text-underline-offset:4px; }
.overview-table { overflow-x:auto; }
.overview-table td, .overview-table th { padding:10px 12px; }
.overview-kpis .kpi-value { font-size:29px; }
#app header { height:auto !important; min-height:60px; padding-top:10px !important; padding-bottom:10px !important; flex-wrap:wrap; }
#app header > div:last-child { flex-wrap:wrap; }
#custom-range { flex-wrap:wrap; }
.sync-confirm { margin:auto; width:min(440px,calc(100% - 32px)); padding:24px; background:#ffffff; color:#0f1b2d; border:1px solid #e2e8f0; border-radius:14px; box-shadow:0 24px 80px rgba(15,27,45,.2); }
.sync-confirm::backdrop { background:rgba(15,27,45,.45); }
.sync-confirm-actions { display:flex; justify-content:flex-end; gap:10px; margin-top:22px; }
@media (max-width:1100px) { .overview-kpis { grid-template-columns:repeat(2,minmax(0,1fr)); } .overview-grid { grid-template-columns:1fr; } }
@media (prefers-reduced-motion:reduce) { .fade-in,.pulse,.skeleton { animation:none; } .btn,.nav-item,.card-hover { transition:none; } }

/* ── Login: keep me signed in ── */
.login-remember { display:flex; align-items:center; justify-content:center; gap:8px; margin-top:12px; font-size:12px; color:#64748b; cursor:pointer; user-select:none; }
.login-remember input { accent-color:#00afee; width:14px; height:14px; margin:0; }
/* ── Daily Brief ── */
.brief { max-width:1180px; margin:0 auto; }
.brief-head { display:flex; justify-content:space-between; align-items:flex-end; gap:16px; margin-bottom:18px; flex-wrap:wrap; }
.brief-greeting { font-size:26px; font-weight:800; letter-spacing:-.4px; color:#0f1b2d; margin:0 0 4px; }
.brief-sub { font-size:13px; color:#64748b; margin:0; }
.brief-grid { display:grid; grid-template-columns:repeat(auto-fit,minmax(240px,1fr)); gap:14px; margin-bottom:16px; }
.brief-top { display:grid; grid-template-columns:repeat(auto-fit,minmax(260px,1fr)); gap:14px; margin-bottom:14px; }
.brief-channels { display:grid; grid-template-columns:repeat(auto-fit,minmax(170px,1fr)); gap:14px; margin-bottom:16px; }
.brief-total.neg { color:#b91c1c; }
/* Yesterday by ad platform: what Meta / Google / Amazon Ads each claim */
.brief-ads { margin-bottom:16px; }
.brief-ad-row { display:grid; grid-template-columns:minmax(0,1fr) 140px 90px; gap:12px; align-items:center; padding:11px 0; border-top:1px solid #e2e8f0; }
.brief-ad-row:first-child { border-top:0; }
.brief-ad-name { display:flex; align-items:center; gap:10px; min-width:0; font-size:13px; color:#0f1b2d; }
.brief-ad-name small, .brief-ad-num small { display:block; color:#64748b; font-size:11.5px; margin-top:2px; font-weight:400; }
.brief-ad-num { text-align:right; font-size:15px; font-weight:700; color:#0f1b2d; }
.brief-ad-foot { margin-top:10px; padding-top:10px; border-top:1px solid #e2e8f0; font-size:12px; color:#64748b; line-height:1.5; }
.brand-logo.ad-meta { color:#0866ff; } .brand-logo.ad-google { color:#4285f4; } .brand-logo.ad-amazon { color:#ff9900; } .brand-logo.ad-pinterest { color:#e60023; }
.brief-total { font-size:40px; font-weight:800; letter-spacing:-1px; color:#0f1b2d; line-height:1.05; }
.brief-label { font-size:11px; font-weight:600; text-transform:uppercase; letter-spacing:.06em; color:#64748b; margin-bottom:8px; display:flex; align-items:center; gap:7px; }
.brief-value { font-size:22px; font-weight:800; color:#0f1b2d; letter-spacing:-.3px; }
.brief-meta { font-size:12px; color:#64748b; margin-top:6px; display:flex; gap:10px; flex-wrap:wrap; align-items:center; }
.brief-delta { display:inline-flex; align-items:center; gap:4px; font-size:12px; font-weight:600; padding:2px 8px; border-radius:999px; background:#f1f5f9; color:#475569; white-space:nowrap; }
.brief-delta.up { background:rgba(16,185,129,.12); color:#047857; }
.brief-delta.down { background:rgba(220,38,38,.10); color:#b91c1c; }
.brief-two { display:grid; grid-template-columns:minmax(0,1.4fr) minmax(300px,1fr); gap:14px; margin-bottom:16px; }
.pace { height:10px; border-radius:6px; background:#e8eef5; position:relative; margin:14px 0 8px; }
.pace-fill { height:100%; border-radius:6px; background:#00afee; transition:width .6s ease-out; }
.pace-mark { position:absolute; top:-4px; width:2px; height:18px; background:#0f1b2d; border-radius:1px; }
.pace-row { display:flex; justify-content:space-between; font-size:12px; color:#64748b; }
.brief-list { display:flex; flex-direction:column; }
.brief-row { display:flex; justify-content:space-between; gap:12px; padding:10px 0; border-top:1px solid #e2e8f0; font-size:13px; color:#0f1b2d; }
.brief-row:first-child { border-top:0; }
.brief-row small { color:#64748b; display:block; font-size:11.5px; margin-top:2px; }
.brief-empty { color:#64748b; font-size:13px; padding:8px 0 0; margin:0; }
@media (max-width:900px) { .brief-two { grid-template-columns:1fr; } .brief-total { font-size:32px; } }

/* ── Shell: page padding, menu button, drawer backdrop, account menu ── */
.page-content { padding:24px; }
.nav-toggle { display:none; padding:7px 9px !important; line-height:0; flex-shrink:0; }
#nav-backdrop { display:none; position:fixed; inset:0; background:rgba(15,27,45,.35); z-index:940; }
#app header { position:relative; }
.avatar-btn { border:0; cursor:pointer; font-family:inherit; }
.user-menu { position:absolute; right:16px; top:calc(100% + 6px); min-width:220px; background:#fff; border:1px solid #e2e8f0; border-radius:12px; box-shadow:0 12px 40px rgba(15,27,45,.14); padding:8px; z-index:960; }
.user-menu[hidden] { display:none; }
.user-menu .um-head { padding:8px 10px 10px; border-bottom:1px solid #e2e8f0; margin-bottom:6px; }
.user-menu .um-name { font-weight:700; font-size:13px; color:#0f1b2d; }
.user-menu .um-role { font-size:11px; color:#64748b; margin-top:2px; }
.user-menu button { display:flex; align-items:center; gap:8px; width:100%; text-align:left; background:none; border:0; padding:9px 10px; border-radius:8px; font:inherit; font-size:13px; color:#0f1b2d; cursor:pointer; }
.user-menu button:hover { background:#f1f5f9; }
.user-menu button.danger { color:#b91c1c; }
/* ── Tablet and below: sidebar becomes a drawer, header tightens ── */
@media (max-width:900px) {
  .nav-toggle { display:inline-flex; }
  #sidebar { position:fixed; top:0; bottom:0; left:0; z-index:950; width:264px !important; min-width:264px !important; transform:translateX(-104%); transition:transform .22s ease; box-shadow:0 20px 60px rgba(15,27,45,.25); }
  body.nav-open #sidebar { transform:none; }
  body.nav-open #nav-backdrop { display:block; }
  #app header { padding:8px 14px !important; gap:10px !important; }
  #page-sub, #last-refresh { display:none; }
  .overview-grid { grid-template-columns:1fr; }
}
/* ── Phone: single/double columns, scrollable tables, full-width panels ── */
@media (max-width:700px) {
  .page-content { padding:14px; }
  #main-content [style*="repeat(4,"], #main-content [style*="repeat(3,"], #main-content [style*="1fr 1fr 1fr"] { grid-template-columns:repeat(2,minmax(0,1fr)) !important; }
  .overview-kpis, .kpi-grid { grid-template-columns:repeat(2,minmax(0,1fr)) !important; }
  .brief-channels { grid-template-columns:repeat(2,minmax(0,1fr)); }
  .brief-ad-row { grid-template-columns:minmax(0,1fr) 110px 64px; gap:8px; }
  .brief-two { grid-template-columns:1fr; }
  .card { overflow-x:auto; }
  td, th { padding:9px 10px; }
  #settings-modal { width:100vw !important; border-left:0 !important; }
  #user-form-modal > div { width:calc(100vw - 24px) !important; max-height:92vh; overflow-y:auto; }
  .login-card { width:calc(100vw - 32px) !important; padding:32px 22px !important; }
  .fresh-label { display:none; }
  .fresh-pill.busy .fresh-label, .fresh-pill.new .fresh-label, .fresh-pill.warn .fresh-label { display:inline; }   /* only when there is something to say */
  .fresh-pop { right:-40px; width:calc(100vw - 32px); }
  .brief-greeting { font-size:22px; }
}
@media (max-width:480px) {
  #main-content [style*="repeat(4,"], #main-content [style*="repeat(3,"], #main-content [style*="1fr 1fr 1fr"], .overview-kpis, .kpi-grid { grid-template-columns:1fr !important; }
  .brief-top { grid-template-columns:1fr; }
  .brief-total { font-size:34px; }
  #date-range, #compare-mode { font-size:11px !important; padding:6px 8px !important; }
  #app header button[aria-label="Refresh dashboard"] { display:none; }   /* pages re-read on navigation; the Brief has its own Refresh */
}

/* ── Estimates: hoverable EST badge with the basis of the estimate ── */
.est { position:relative; display:inline-flex; align-items:center; margin-left:6px; padding:1px 6px; border-radius:999px; font-size:9px; font-weight:700; letter-spacing:.04em; text-transform:uppercase; background:rgba(245,158,11,.14); color:#b45309; border:1px solid rgba(245,158,11,.35); cursor:help; vertical-align:middle; line-height:1.4; }
.est:focus-visible { outline:2px solid #00afee; outline-offset:2px; }
.est .est-tip { display:none; position:absolute; left:0; top:calc(100% + 7px); z-index:60; width:320px; max-width:min(320px, 82vw); background:#0f1b2d; color:#f4f7fb; font-size:11.5px; font-weight:400; line-height:1.5; letter-spacing:0; text-transform:none; padding:10px 12px; border-radius:10px; box-shadow:0 12px 32px rgba(15,27,45,.28); white-space:normal; text-align:left; }
.est .est-tip::before { content:''; position:absolute; top:-5px; left:14px; width:10px; height:10px; background:#0f1b2d; transform:rotate(45deg); }
.est:hover .est-tip, .est:focus .est-tip, .est:focus-visible .est-tip, .est.open .est-tip { display:block; }
td .est .est-tip, .brief-meta .est .est-tip { left:auto; right:0; }
td .est .est-tip::before, .brief-meta .est .est-tip::before { left:auto; right:14px; }
/* ── Table header variants (replace per-table inline styles) ── */
@media (max-width:700px) {
  /* Narrow screens: the tip becomes a sheet pinned to the bottom instead of a 320px flyout. */
  .est .est-tip { position:fixed; left:12px; right:12px; top:auto; bottom:16px; width:auto; max-width:none; font-size:12.5px; padding:12px 14px; }
  .est .est-tip::before { display:none; }
  #main-content { overflow-x:hidden; }
}
th.th-compact { padding:6px 10px; font-size:10px; }
th.right, td.right { text-align:right; }
th.center { text-align:center; }

/* Daily Brief task list (Notion GG Action Items) */
.task-head { display:flex; align-items:center; gap:10px; margin-bottom:4px; }
.task-head .brief-label { margin:0; flex:1; }
.task-tabs { display:flex; gap:4px; }
.task-tab { font:inherit; font-size:11.5px; font-weight:600; padding:4px 11px; border-radius:999px; border:1px solid var(--border); background:#fff; color:var(--muted); cursor:pointer; }
.task-tab.on { background:var(--accent); border-color:var(--accent); color:#fff; }
.task-list { display:flex; flex-direction:column; margin-top:6px; }
.task-row { display:flex; align-items:flex-start; gap:12px; padding:11px 0; border-top:1px solid var(--border); }
.task-row:first-child { border-top:0; }
.task-row.done { opacity:.45; }
.task-row.done .task-title { text-decoration:line-through; }
.task-check { width:20px; height:20px; border-radius:50%; border:1.5px solid #94a3b8; background:#fff; cursor:pointer; flex-shrink:0; margin-top:1px; padding:0; }
.task-check:hover, .task-check:focus-visible { border-color:var(--accent); box-shadow:0 0 0 3px rgba(0,175,238,.15); outline:none; }
.task-row.done .task-check { background:var(--accent); border-color:var(--accent); }
.task-main { flex:1; min-width:0; }
.task-title { font-size:13px; font-weight:600; color:var(--text); display:flex; align-items:center; gap:8px; flex-wrap:wrap; line-height:1.35; }
.task-meta { font-size:11.5px; color:var(--muted); margin-top:2px; }
.task-pri { font-size:10px; font-weight:700; text-transform:uppercase; letter-spacing:.05em; padding:2px 7px; border-radius:999px; }
.pri-critical { background:#fee2e2; color:#b91c1c; }
.pri-high { background:#ffedd5; color:#c2410c; }
.pri-medium { background:#fef9c3; color:#a16207; }
.pri-low { background:#f1f5f9; color:#64748b; }
.task-link { color:var(--accent-text); font-size:12px; font-weight:600; text-decoration:none; flex-shrink:0; }
.task-link:hover { text-decoration:underline; }
.task-add { display:flex; gap:8px; margin-top:12px; }
.task-add input, .task-add select { font:inherit; font-size:13px; padding:9px 12px; border:1px solid var(--border); border-radius:8px; background:#f4f7fb; color:var(--text); outline:none; }
.task-add input { flex:1; min-width:0; }
.task-add input:focus, .task-add select:focus { border-color:var(--accent); box-shadow:0 0 0 3px rgba(0,175,238,.15); }
@media (max-width:700px) { .task-add { flex-wrap:wrap; } .task-add input { flex-basis:100%; } .task-head { flex-wrap:wrap; } }

/* Settings → Your Notion account */
.notion-self { margin:16px 24px 0; }
.notion-self-head { display:flex; align-items:center; justify-content:space-between; gap:10px; flex-wrap:wrap; }
.notion-self-head .brief-label { margin:0; }
.notion-self-status { font-size:12px; color:var(--muted); }
.notion-self-status.ok { color:#059669; font-weight:600; }
.notion-self-status.warn { color:#c2410c; font-weight:600; }
.notion-self-help { font-size:11.5px; color:var(--muted); margin:8px 0 0; line-height:1.5; }
.notion-self-form { display:flex; gap:8px; margin-top:10px; }
.notion-self-form input { flex:1; min-width:0; font:inherit; font-size:12.5px; padding:9px 12px; border:1px solid var(--border); border-radius:8px; background:#f4f7fb; color:var(--text); outline:none; }
.notion-self-form input:focus { border-color:var(--accent); box-shadow:0 0 0 3px rgba(0,175,238,.15); }
@media (max-width:700px) { .notion-self-form { flex-wrap:wrap; } .notion-self-form input { flex-basis:100%; } }

/* "New action item" modal + "+ task" entry points */
.task-modal { position:fixed; inset:0; background:rgba(15,27,45,.45); z-index:2100; display:flex; align-items:center; justify-content:center; padding:16px; }
.task-modal[hidden] { display:none; }
.task-modal-card { background:#fff; border:1px solid var(--border); border-radius:16px; padding:22px 24px; width:520px; max-width:100%; max-height:92vh; overflow-y:auto; display:flex; flex-direction:column; gap:12px; }
.task-modal-title { font-size:16px; font-weight:700; color:var(--text); }
.tm-field { display:flex; flex-direction:column; gap:5px; }
.tm-field span { font-size:11px; color:var(--muted); font-weight:600; text-transform:uppercase; letter-spacing:.06em; }
.tm-field input, .tm-field select, .tm-field textarea { font:inherit; font-size:13px; padding:9px 12px; border:1px solid var(--border); border-radius:8px; background:#f4f7fb; color:var(--text); outline:none; width:100%; }
.tm-field textarea { resize:vertical; }
.tm-field input:focus, .tm-field select:focus, .tm-field textarea:focus { border-color:var(--accent); box-shadow:0 0 0 3px rgba(0,175,238,.15); }
.task-modal-grid { display:grid; grid-template-columns:1fr 1fr; gap:10px 12px; }
.task-modal-actions { display:flex; align-items:center; gap:8px; justify-content:flex-end; margin-top:4px; }
.task-modal-hint { flex:1; font-size:11.5px; color:var(--muted); }
.attention-row { display:flex; align-items:center; gap:8px; }
.attention-row .attention-item { flex:1; min-width:0; }
.task-from { font:inherit; font-size:11px; font-weight:600; padding:4px 9px; border-radius:999px; border:1px solid var(--border); background:#fff; color:var(--accent-text); cursor:pointer; white-space:nowrap; flex-shrink:0; }
.task-from:hover { border-color:var(--accent); background:#f0f9ff; }
@media (max-width:700px) { .task-modal-grid { grid-template-columns:1fr; } .task-modal-card { padding:18px 16px; } }
.task-from-inline { margin-top:4px; padding:2px 8px; font-size:10.5px; }

/* What sold: product tiles */
.sold-card { margin-bottom:24px; }
.sold-head { display:flex; align-items:center; justify-content:space-between; gap:10px; flex-wrap:wrap; margin-bottom:8px; }
.sold-head .brief-label { margin:0; }
.sold-grid { display:grid; grid-template-columns:repeat(auto-fill, minmax(132px, 1fr)); gap:12px; }
.sold-row { display:flex; gap:12px; overflow-x:auto; padding-bottom:4px; scrollbar-width:thin; }
.sold-tile { min-width:0; }
.sold-tile.compact { flex:0 0 96px; }
.sold-img { position:relative; aspect-ratio:1; border-radius:12px; background:#f4f7fb; border:1px solid var(--border); overflow:hidden; display:flex; align-items:center; justify-content:center; }
.sold-img img { width:100%; height:100%; object-fit:cover; display:block; }
.sold-ph { font-size:22px; font-weight:800; color:#94a3b8; letter-spacing:.04em; }
.sold-units { position:absolute; right:6px; bottom:6px; background:var(--text); color:#fff; font-size:12px; font-weight:700; padding:2px 8px; border-radius:999px; box-shadow:0 1px 3px rgba(0,0,0,.25); }
.sold-tile.compact .sold-units { font-size:11px; padding:1px 7px; }
.sold-name { font-size:12.5px; font-weight:600; color:var(--text); margin-top:7px; line-height:1.3; display:-webkit-box; -webkit-line-clamp:2; -webkit-box-orient:vertical; overflow:hidden; }
.sold-tile.compact .sold-name { font-size:11.5px; }
.sold-meta { font-size:11px; color:var(--muted); margin-top:2px; display:flex; flex-wrap:wrap; gap:4px; align-items:center; }
.sold-chan { font-size:9.5px; font-weight:700; text-transform:uppercase; letter-spacing:.04em; padding:1px 6px; border-radius:4px; background:#f1f5f9; color:#64748b; }
.sold-chan-shopify { background:#eef7e3; color:#5f8a1f; }
.sold-chan-amazon { background:#fff3e0; color:#b45309; }
.sold-chan-dealer { background:#e6f7f5; color:#0f766e; }
.sold-strip { margin-bottom:16px; }

/* Breakeven tanks */
.tank { position:relative; width:64px; height:112px; border-radius:14px; border:2px solid #94a3b8; background:#f8fafc; overflow:hidden; flex-shrink:0; }
.tank.sm { width:40px; height:64px; border-radius:10px; }
.tank-fill { position:absolute; left:0; right:0; bottom:0; background:linear-gradient(180deg, #5fd0ff 0%, var(--accent) 100%); transition:height .8s cubic-bezier(.2,.8,.2,1); }
.tank-fill::before { content:""; position:absolute; left:-20%; right:-20%; top:-6px; height:12px; border-radius:50%; background:rgba(255,255,255,.35); }
.tank.full { border-color:#10b981; }
.tank.full .tank-fill { background:linear-gradient(180deg, #6ee7b7 0%, #10b981 100%); }
.tank-pct { position:absolute; inset:0; display:flex; align-items:center; justify-content:center; font-size:14px; font-weight:800; color:var(--text); text-shadow:0 1px 0 rgba(255,255,255,.7); }
.tank.sm .tank-pct { font-size:11px; }
.tank.full .tank-pct { color:#065f46; }
.launch-section { margin-bottom:22px; display:flex; flex-direction:column; gap:12px; }
.launch-head { display:flex; align-items:flex-start; justify-content:space-between; gap:12px; flex-wrap:wrap; }
.launch-h { font-size:16px; font-weight:700; color:var(--text); margin:0 0 2px; }
.launch-card { display:flex; align-items:center; gap:18px; }
.launch-main { flex:1; min-width:0; display:flex; flex-direction:column; gap:3px; }
.launch-title { font-size:14px; font-weight:700; color:var(--text); }
.launch-title .muted { font-weight:500; font-size:12px; }
.launch-line { font-size:12.5px; color:var(--text); }
.launch-line .ok { color:#059669; font-weight:700; }
.launch-edit { flex-shrink:0; }
.launch-mini-grid { display:grid; grid-template-columns:repeat(auto-fill, minmax(220px, 1fr)); gap:12px; }
.launch-mini { display:flex; align-items:center; gap:12px; font-size:12px; }
.launch-mini-name { font-weight:700; color:var(--text); }
.lf-cost { display:flex; gap:8px; margin-bottom:6px; align-items:center; }
.lf-cost input:first-child { flex:2; }
.lf-cost input:nth-child(2) { flex:1; }
.lf-cost input { font:inherit; font-size:13px; padding:8px 10px; border:1px solid var(--border); border-radius:8px; background:#f4f7fb; color:var(--text); outline:none; min-width:0; }
@media (max-width:700px) { .launch-card { flex-wrap:wrap; } .launch-edit { width:100%; } .sold-grid { grid-template-columns:repeat(auto-fill, minmax(104px, 1fr)); } }
.launch-head .muted { font-size:12px; max-width:720px; }
.tm-field > .task-from { align-self:flex-start; }

/* Freshness pill (replaces the Sync button): data age, running refreshes, "Updated" offers */
.fresh { position:relative; }
.fresh-pill { display:inline-flex; align-items:center; gap:7px; font:inherit; font-size:12px; font-weight:600; color:var(--muted); background:#fff; border:1px solid var(--border); border-radius:999px; padding:7px 12px; cursor:pointer; white-space:nowrap; }
.fresh-pill:hover { border-color:#cbd5e1; color:var(--text); }
.fresh-dot { width:8px; height:8px; border-radius:50%; background:#cbd5e1; flex-shrink:0; }
.fresh-pill.ok .fresh-dot, .fresh-dot.ok { background:#10b981; }
.fresh-pill.warn .fresh-dot, .fresh-dot.warn { background:#f59e0b; }
.fresh-dot.err { background:#ef4444; }
.fresh-pill.busy .fresh-dot, .fresh-dot.busy { background:var(--accent); animation:fresh-pulse 1.2s ease-in-out infinite; }
.fresh-pill.busy { color:var(--accent-text); border-color:#bfe9fb; }
.fresh-pill.new { color:#fff; background:var(--accent); border-color:var(--accent); }
.fresh-pill.new .fresh-dot { background:#fff; }
@keyframes fresh-pulse { 0%,100% { opacity:1; transform:scale(1); } 50% { opacity:.45; transform:scale(.8); } }
.fresh-pop { position:absolute; top:calc(100% + 8px); right:0; width:340px; max-width:calc(100vw - 32px); background:#fff; border:1px solid var(--border); border-radius:14px; box-shadow:0 12px 32px rgba(15,27,45,.14); padding:10px 12px 12px; z-index:1500; font-size:12.5px; }
.fresh-pop[hidden] { display:none; }
.fresh-head { display:flex; justify-content:space-between; align-items:center; gap:10px; font-weight:700; color:var(--text); padding:2px 2px 8px; border-bottom:1px solid var(--border); margin-bottom:4px; }
.fresh-head .muted { font-weight:500; font-size:11.5px; }
.fresh-row { display:flex; align-items:center; gap:9px; padding:6px 2px; }
.fresh-name { flex:1; min-width:0; color:var(--text); white-space:nowrap; overflow:hidden; text-overflow:ellipsis; }
.fresh-age { color:var(--muted); font-variant-numeric:tabular-nums; white-space:nowrap; }
.fresh-btn { font:inherit; font-size:13px; line-height:1; padding:3px 7px; border-radius:999px; border:1px solid var(--border); background:#fff; color:var(--accent-text); cursor:pointer; }
.fresh-btn:hover { border-color:var(--accent); background:#f0f9ff; }
.fresh-actions { display:flex; justify-content:flex-end; gap:8px; margin-top:8px; padding-top:8px; border-top:1px solid var(--border); }
.tank.incomplete { border-style:dashed; border-color:#f59e0b; background:#fffbeb; }
.tank.incomplete .tank-pct { color:#b45309; font-size:20px; }
.launch-card.incomplete { border-color:#fcd34d; }
.launch-need { font:inherit; font-size:12.5px; font-weight:700; color:#b45309; background:#fef3c7; border:1px solid #fcd34d; border-radius:999px; padding:4px 11px; cursor:pointer; }
.launch-need:hover { background:#fde68a; }
.launch-need-text { font-weight:700; color:#b45309; }
.launch-img { width:56px; height:56px; border-radius:10px; object-fit:cover; border:1px solid var(--border); flex-shrink:0; }
.launch-fill-hint { color:#b45309; font-weight:600; }
.launch-pnl { display:flex; flex-wrap:wrap; gap:4px 12px; font-size:12px; color:var(--muted); }
.launch-pnl b { color:var(--text); font-weight:600; }
.launch-pnl em { font-style:normal; color:var(--accent-text); cursor:help; border-bottom:1px dotted currentColor; }
.launch-pnl em.warn { color:#b45309; }

/* Breakeven tiles: side by side, basics only; hover for the breakdown, click for the detail */
.tank.md { width:52px; height:88px; border-radius:12px; }
.tank.md .tank-pct { font-size:13px; }
.launch-grid { display:grid; grid-template-columns:repeat(auto-fill, minmax(236px, 1fr)); gap:12px; }
.launch-tile { position:relative; display:flex; align-items:center; gap:12px; padding:12px 14px; background:var(--surface); border:1px solid var(--border); border-radius:14px; cursor:pointer; min-width:0; }
.launch-tile:hover, .launch-tile:focus-visible { border-color:var(--accent); box-shadow:0 4px 18px rgba(0,175,238,.12); outline:none; }
.launch-tile.incomplete { border-color:#fcd34d; }
.launch-tile.done { border-color:#a7f3d0; }
.launch-tile-main { flex:1; min-width:0; }
.launch-tile-name { display:flex; align-items:center; gap:8px; font-size:13.5px; font-weight:700; color:var(--text); white-space:nowrap; overflow:hidden; text-overflow:ellipsis; }
.launch-tile-img { width:22px; height:22px; border-radius:6px; object-fit:cover; border:1px solid var(--border); flex-shrink:0; }
.launch-tile-status { font-size:12px; font-weight:600; color:var(--text); margin-top:3px; }
.launch-tile-status.warn { color:#b45309; }
.launch-tile-status.ok { color:#059669; }
.launch-tile-sub { font-size:11.5px; color:var(--muted); margin-top:2px; white-space:nowrap; overflow:hidden; text-overflow:ellipsis; }
.launch-pop { display:none; position:absolute; left:0; right:0; top:calc(100% + 6px); z-index:40; background:#fff; border:1px solid var(--border); border-radius:14px; box-shadow:0 12px 32px rgba(15,27,45,.16); padding:12px 14px; min-width:360px; cursor:default; }
.launch-pop .launch-main { gap:4px; }
.launch-pop .launch-title { font-size:13px; }
.launch-pop .launch-pnl { font-size:11.5px; }
.launch-tile:hover .launch-pop, .launch-tile:focus-visible .launch-pop { display:block; }
.launch-tile:last-child .launch-pop, .launch-tile:nth-child(3n) .launch-pop { left:auto; right:0; }
@media (hover:none) { .launch-pop { display:none !important; } }   /* phones: tap opens the detail instead */
@media (max-width:700px) { .launch-grid { grid-template-columns:1fr; } }
.launch-detail { max-width:640px; }
.launch-detail-head { display:flex; align-items:center; gap:14px; margin-bottom:4px; }
.launch-detail-head .task-modal-title { margin:0; }
.launch-detail .launch-need { display:inline-block; }

/* Shopify store filter (Sales) and store badges. Buttons center their label both ways. */
.store-filter { display:flex; justify-content:center; align-items:center; gap:8px; margin:0 auto 18px; flex-wrap:wrap; }
.store-filter-btn { display:inline-flex; align-items:center; justify-content:center; text-align:center; min-height:36px; padding:8px 14px; border-radius:999px; border:1px solid #cbd5e1; background:#fff; color:#334155; font:inherit; font-size:12px; font-weight:600; cursor:pointer; line-height:1; }
.store-filter-btn.is-active { background:#00afee; border-color:#00afee; color:#fff; }
.store-badge { display:inline-flex; align-items:center; justify-content:center; text-align:center; padding:2px 8px; border-radius:999px; background:rgba(0,175,238,.10); color:#007bb0; font-size:10px; font-weight:700; letter-spacing:.02em; line-height:1.4; white-space:nowrap; }
.store-directory { margin-top:12px; padding-top:11px; border-top:1px solid rgba(15,27,45,.08); display:grid; gap:8px; }
.store-directory-row { display:flex; align-items:center; gap:10px; font-size:12px; color:#64748b; flex-wrap:wrap; }
.store-directory-domain { flex:1; min-width:140px; text-align:center; }
.channel-head { display:flex; align-items:center; gap:10px; margin-bottom:14px; flex-wrap:wrap; }
.sales-kpis { display:grid; grid-template-columns:repeat(3,minmax(0,1fr)); gap:16px; margin-bottom:24px; }
@media (max-width:700px) { .sales-kpis { grid-template-columns:1fr; } }

/* Inventory: inbound containers vs quieter internal transfers. */
.inv-shipments { margin-top:24px; }
.inv-section-head { display:flex; align-items:center; justify-content:space-between; gap:12px; flex-wrap:wrap; margin-bottom:12px; }
.inv-section-head h3 { margin:0; font-size:14px; font-weight:700; color:#0f1b2d; }
.inv-section-head span { font-size:12px; color:#64748b; }
.inv-containers-loading, .container-empty { text-align:center; color:#64748b; font-size:13px; padding:22px 16px; }
.container-board { display:grid; grid-template-columns:repeat(auto-fit,minmax(280px,1fr)); gap:14px; margin-bottom:18px; }
.container-board:empty { display:none; }
.container-card { padding:16px 18px; }
.container-card-head { display:flex; align-items:flex-start; justify-content:space-between; gap:12px; }
.container-card-head > div:first-child { min-width:0; flex:1; }
.container-kicker { font-size:11px; font-weight:700; letter-spacing:.06em; text-transform:uppercase; color:#007bb0; }
.container-name { font-size:16px; font-weight:800; color:#0f1b2d; margin-top:2px; overflow-wrap:anywhere; }
.container-units { display:flex; flex-direction:column; align-items:flex-end; justify-content:center; flex-shrink:0; font-size:22px; font-weight:800; color:#0f1b2d; line-height:1; text-align:right; }
.container-units span { display:block; margin-top:4px; font-size:11px; font-weight:600; letter-spacing:.04em; text-transform:uppercase; color:#64748b; }
.container-meta { display:flex; align-items:center; justify-content:space-between; gap:8px; flex-wrap:wrap; margin:10px 0 4px; font-size:12px; color:#64748b; }
.container-line { display:flex; align-items:center; justify-content:space-between; gap:12px; padding:8px 0; border-top:1px solid #e2e8f0; font-size:13px; color:#334155; }
.container-line strong { font-variant-numeric:tabular-nums; color:#0f1b2d; }
.inv-transfers { padding:0; margin-top:4px; }
.inv-transfers .inv-section-head { padding:14px 16px 0; }
.inv-transfer-table td { font-size:12px; }
.btn.inv-action { min-height:36px; padding:8px 14px; font-size:12px; font-weight:600; }
.ship-card { padding:16px 18px; }
.ship-card-head { display:flex; align-items:center; justify-content:space-between; gap:12px; margin-bottom:14px; }
.ship-card-title { margin:0; font-size:14px; font-weight:700; color:#0f1b2d; }
.ship-form { display:grid; grid-template-columns:minmax(0,1.4fr) minmax(0,1fr) minmax(0,1fr) 96px; gap:12px; align-items:end; }
.ship-form label { display:block; margin-bottom:4px; font-size:11px; font-weight:600; color:#64748b; }
.ship-form-notes { grid-column:1 / -1; }
.ship-form-bar { display:flex; align-items:center; justify-content:space-between; gap:16px; margin-top:14px; padding-top:14px; border-top:1px solid #e2e8f0; }
.ship-form-hint { margin:0; flex:1; font-size:12px; line-height:1.45; color:#64748b; }
.ship-form-bar .btn { flex-shrink:0; min-height:40px; }
@media (max-width:700px) {
  .ship-form { grid-template-columns:1fr 1fr; }
  .ship-form-bar { flex-direction:column; align-items:stretch; }
  .ship-form-bar .btn { width:100%; }
  .container-board { grid-template-columns:1fr; }
}

/* ── Containers from China (Inventory page) ─────────────────────────────────────────────── */
.ctr-section { padding:14px 16px; margin-bottom:16px; }
.ctr-year > summary { cursor:pointer; list-style:none; font-size:12.5px; color:var(--text); padding:6px 0; }
.ctr-year > summary::-webkit-details-marker { display:none; }
.ctr-year > summary::before { content:'▸'; display:inline-block; width:14px; color:var(--muted); transition:transform .15s; }
.ctr-year[open] > summary::before { transform:rotate(90deg); }
.ctr-grid { display:grid; grid-template-columns:repeat(auto-fill, minmax(210px, 1fr)); gap:12px; padding:4px 0 8px; }
.ctr-tile { position:relative; cursor:pointer; border-radius:12px; padding:8px; outline:none; min-width:0; }
.ctr-tile:hover, .ctr-tile:focus-visible { background:#f1f8fd; }
.ctr-box { position:relative; display:flex; height:72px; border-radius:3px; overflow:hidden;
  background-color:#0b8fc4;
  background-image:repeating-linear-gradient(90deg, rgba(255,255,255,.16) 0 2px, rgba(0,0,0,.10) 2px 4px, transparent 4px 11px),
                   linear-gradient(180deg, rgba(255,255,255,.18), rgba(0,0,0,.14));
  border-top:4px solid #076f99; border-bottom:4px solid #076f99; box-shadow:0 3px 0 #d7e7f1; }
.ctr-tile.in_transit .ctr-box { background-color:#d97706; border-color:#a35a05; }
.ctr-tile.ordered .ctr-box { background-color:#94a3b8; border-color:#64748b; }
.ctr-side { flex:1; min-width:0; display:flex; flex-direction:column; justify-content:center; gap:2px; padding:0 12px; color:#fff; text-shadow:0 1px 1px rgba(0,0,0,.28); }
.ctr-po { font-size:15px; font-weight:800; letter-spacing:.02em; white-space:nowrap; overflow:hidden; text-overflow:ellipsis; }
.ctr-no { font-size:10.5px; font-weight:600; letter-spacing:.08em; opacity:.88; font-family:ui-monospace, SFMono-Regular, Menlo, monospace; }
.ctr-door { width:30px; flex-shrink:0; border-left:2px solid rgba(0,0,0,.2);
  background-image:linear-gradient(90deg, transparent 7px, rgba(0,0,0,.28) 7px 9px, transparent 9px 19px, rgba(0,0,0,.28) 19px 21px, transparent 21px); }
.ctr-cap { padding:7px 2px 0; }
.ctr-dates { font-size:12.5px; font-weight:600; color:var(--text); white-space:nowrap; overflow:hidden; text-overflow:ellipsis; }
.ctr-sub { font-size:11.5px; color:var(--muted); margin-top:1px; white-space:nowrap; overflow:hidden; text-overflow:ellipsis; }
.ctr-pop { display:none; position:absolute; left:0; top:calc(100% - 2px); z-index:40; width:420px; max-width:calc(100vw - 32px); max-height:64vh; overflow:auto;
  background:#fff; border:1px solid var(--border); border-radius:14px; box-shadow:0 12px 32px rgba(15,27,45,.16); padding:12px 14px; cursor:default; }
.ctr-pop.flip { left:auto; right:0; }
.ctr-tile:hover .ctr-pop, .ctr-tile:focus-visible .ctr-pop { display:block; }
@media (hover:none) { .ctr-pop { display:none !important; } }   /* phones: tap opens the dialog */
.ctr-detail { display:flex; flex-direction:column; gap:10px; font-size:12.5px; color:var(--text); }
.ctr-detail-head { display:flex; align-items:center; justify-content:space-between; gap:8px; }
.ctr-detail-title { font-size:14px; font-weight:700; }
.ctr-status { font-size:10.5px; font-weight:700; text-transform:uppercase; letter-spacing:.04em; padding:3px 8px; border-radius:999px; background:#e0f2fe; color:var(--accent-text); white-space:nowrap; }
.ctr-status.in_transit { background:#fef3c7; color:#b45309; }
.ctr-status.ordered { background:#f1f5f9; color:#475569; }
.ctr-meta, .ctr-basis { font-size:11.5px; color:var(--muted); }
.ctr-basis a { color:var(--accent-text); }
.ctr-timeline, .ctr-money { display:grid; grid-template-columns:repeat(4, 1fr); gap:8px; }
.ctr-timeline > div, .ctr-money > div { display:flex; flex-direction:column; gap:1px; min-width:0; padding:6px 8px; background:#f8fafc; border:1px solid var(--border); border-radius:10px; }
.ctr-timeline span, .ctr-money span { font-size:10px; color:var(--muted); text-transform:uppercase; letter-spacing:.04em; }
.ctr-timeline b, .ctr-money b { font-size:12.5px; white-space:nowrap; }
.ctr-timeline small, .ctr-money small { font-size:10.5px; color:var(--muted); }
.ctr-costs { display:flex; flex-direction:column; gap:6px; }
.ctr-cost-label { font-size:10px; font-weight:700; letter-spacing:.06em; text-transform:uppercase; color:var(--muted); }
.ctr-cost-grid b { white-space:normal; overflow-wrap:anywhere; }
.ctr-missing { color:var(--muted); font-weight:500; }
.ctr-items { width:100%; border-collapse:collapse; font-size:12px; }
.ctr-items td { padding:4px; border-top:1px solid #eef2f7; vertical-align:middle; }
.ctr-items td.right { font-variant-numeric:tabular-nums; white-space:nowrap; }
.ctr-items tfoot td { font-weight:700; border-top:2px solid var(--border); }
.ctr-item-img { width:20px; height:20px; border-radius:4px; object-fit:cover; vertical-align:middle; margin-right:6px; border:1px solid var(--border); }
.ctr-detail-card { width:640px; }
@media (max-width:700px) { .ctr-timeline, .ctr-money { grid-template-columns:1fr 1fr; } }
.ctr-section .sold-head > .muted { font-size:12px; }
@media (max-width:480px) {
  .ctr-grid { grid-template-columns:1fr 1fr; gap:8px; }
  .ctr-tile { padding:4px; }
  .ctr-box { height:56px; }
  .ctr-side { padding:0 8px; }
  .ctr-po { font-size:12.5px; }
  .ctr-no { font-size:9px; letter-spacing:.04em; }
  .ctr-door { width:18px; background-image:linear-gradient(90deg, transparent 4px, rgba(0,0,0,.28) 4px 6px, transparent 6px 11px, rgba(0,0,0,.28) 11px 13px, transparent 13px); }
  .ctr-dates { font-size:11.5px; }
  .ctr-sub { font-size:10.5px; }
}
.ctr-arrive { display:flex; align-items:center; gap:8px; font-size:12.5px; color:var(--text); margin-right:auto; }
.ctr-arrive input { padding:6px 8px; border:1px solid var(--border); border-radius:8px; font-size:12.5px; }

/* ── Warehouse page: floor plan (SVG in feet) ── */
.wh-page { display:flex; flex-direction:column; gap:16px; }
.wh-floor-wrap { overflow-x:auto; padding:6px 0 2px; }
.wh-floor { display:block; width:100%; min-width:640px; max-height:560px; }
.wh-room { fill:#eef2f7; }
.wh-wall { fill:none; stroke:#64748b; stroke-width:.5; }
.wh-excl { fill:url(#wh-hatch); stroke:#94a3b8; stroke-width:.3; }
.wh-excl-lab { font-size:1.6px; font-weight:700; fill:#64748b; text-anchor:middle; letter-spacing:.12px; text-transform:uppercase; }
.wh-door { fill:#fff; stroke:#64748b; stroke-width:.3; }
.wh-door-lab { font-size:1.3px; font-weight:600; fill:#64748b; }
.wh-rack { cursor:pointer; }
.wh-rack:focus-visible { outline:none; }
.wh-rack:focus-visible .wh-rack-box, .wh-rack:hover .wh-rack-box { stroke-width:.7; }
.wh-rack-base { fill:#fff; }
.wh-rack-box { fill:none; stroke:#2b5797; stroke-width:.45; }
.wh-rack.sel .wh-rack-box { stroke:#007bb0; stroke-width:.8; filter:drop-shadow(0 0 1.2px rgba(0,175,238,.55)); }
.wh-fill { fill:#00afee; }
.wh-res { fill:#f59e0b; }
.wh-tri { fill:#2b5797; }
.wh-rack-lab { font-size:1.8px; font-weight:800; fill:#0f1b2d; text-anchor:middle; paint-order:stroke; stroke:#fff; stroke-width:.55; stroke-linejoin:round; pointer-events:none; }
.wh-rack-sub { font-size:1.3px; font-weight:600; fill:#1e293b; text-anchor:middle; paint-order:stroke; stroke:#fff; stroke-width:.45; stroke-linejoin:round; pointer-events:none; }
.wh-legend { display:flex; align-items:center; gap:18px; flex-wrap:wrap; font-size:12px; color:#475569; margin-top:10px; }
.wh-legend > span { display:inline-flex; align-items:center; gap:8px; }
.wh-sw { display:inline-block; width:14px; height:14px; border-radius:3px; }
.wh-sw-open { background:#fff; border:2px solid #2b5797; box-sizing:border-box; }
.wh-sw-excl { background:repeating-linear-gradient(135deg,#d4dbe4 0 3px,#e6ebf1 3px 6px); }
.wh-legend .wh-mini { margin-left:auto; padding:6px 12px; font-size:12px; }
.wh-rack-head { align-items:flex-start; }
.wh-rack-meta { font-size:12px; margin-top:4px; }
.wh-rack-note { font-size:12px; margin-top:4px; }
.wh-rack-actions { display:flex; gap:8px; flex-shrink:0; }
.wh-rack-scroll { overflow-x:auto; padding:18px 4px 6px; }

/* ── The rack from the aisle: blue uprights, orange beams, pallets drawn at about 2.6 px per inch ── */
.wh-rackview { display:flex; flex-direction:column; }
.wh-ends { display:flex; justify-content:space-between; font-size:10px; font-weight:700; letter-spacing:.06em; text-transform:uppercase; color:#94a3b8; padding:0 2px 6px; }
.wh-rack { display:flex; align-items:stretch; }
.wh-up { flex:0 0 16px; border-radius:2px; background:#2b5797 radial-gradient(circle,rgba(255,255,255,.45) 1.4px,transparent 1.9px) 50% 4px / 16px 11px repeat-y; box-shadow:inset -3px 0 0 rgba(0,0,0,.18); }
.wh-bay { display:flex; flex-direction:column; justify-content:flex-end; min-width:0; }
.wh-levels { display:flex; flex-direction:column-reverse; }
.wh-lvl { display:flex; flex-direction:column; box-sizing:border-box; }
.wh-lvl.full { height:152px; }
.wh-lvl.half { height:108px; }
.wh-slots { flex:1; display:flex; gap:10px; padding:6px 8px 0; min-height:0; align-items:flex-end; }
.wh-lvl.decked .wh-slots { background:repeating-linear-gradient(90deg,transparent 0 13px,#eceff3 13px 14px),repeating-linear-gradient(0deg,transparent 0 13px,#eceff3 13px 14px); }
.wh-beam { height:10px; background:#ef6a1f; border-radius:2px; box-shadow:inset 0 -4px 0 rgba(0,0,0,.16),inset 0 1px 0 rgba(255,255,255,.3); }
.wh-beam.none { display:none; }
.wh-floorbar { height:10px; background:#9aa5b4; border-radius:0 0 3px 3px; box-shadow:inset 0 3px 0 rgba(0,0,0,.08); }
.wh-baylabs { display:flex; padding:0 16px; }
.wh-baylab { text-align:center; font-size:11px; color:#64748b; font-weight:600; padding-top:8px; }
.wh-p { position:relative; flex:1; min-width:0; display:flex; flex-direction:column; justify-content:flex-end; align-items:center; padding-bottom:2px; box-sizing:border-box; height:100%; border-radius:6px; }
.wh-p[role="button"] { cursor:pointer; }
.wh-p[role="button"]:hover, .wh-p[role="button"]:focus-visible { background:rgba(0,175,238,.08); outline:none; box-shadow:0 0 0 2px rgba(0,175,238,.35); }
.wh-tier { display:flex; width:100%; gap:2px; justify-content:center; margin-top:2px; }
.wh-bx { height:47px; background:#dcb582; border:1px solid #b08146; box-sizing:border-box; position:relative; border-radius:1px; box-shadow:inset 0 -3px 0 rgba(0,0,0,.08),inset 1px 0 0 rgba(255,255,255,.35); }
.wh-bx::after { content:''; position:absolute; left:50%; top:50%; width:9px; height:9px; transform:translate(-50%,-50%) rotate(45deg); border:1.5px solid #8a6238; }
.wh-bx::before { content:''; position:absolute; left:14%; right:14%; top:14%; height:3px; background:rgba(138,98,56,.25); border-radius:1px; }
.pat-std .t1 .wh-bx { flex:1 1 0; }
.pat-std .t2 .wh-bx { flex:0 0 calc(47.5% - 1px); }
.pat-std .t2 .wh-bx.c { display:none; }
.pat-tt .wh-bx { height:49px; }
.pat-tt .t1 .wh-bx.a, .pat-tt .t2 .wh-bx.c { flex:0 0 calc(53.5% - 2px); }
.pat-tt .t1 .wh-bx.b, .pat-tt .t1 .wh-bx.c, .pat-tt .t2 .wh-bx.a, .pat-tt .t2 .wh-bx.b { flex:0 0 calc(23.25% - 1px); }
.pat-tt .t1 .wh-bx.b::after, .pat-tt .t1 .wh-bx.c::after, .pat-tt .t2 .wh-bx.a::after, .pat-tt .t2 .wh-bx.b::after { display:none; }
.sz-half .t2 { display:none; }
.wh-pal { width:100%; height:13px; margin-top:1px; border:1px solid #9a6d3c; border-radius:1px; box-sizing:border-box; background:linear-gradient(90deg,transparent 0 20%,#7a5631 20% 42%,transparent 42% 58%,#7a5631 58% 80%,transparent 80%) 0 100% / 100% 5px no-repeat,#c99a5f; box-shadow:inset 0 2px 0 rgba(255,255,255,.3); }
.wh-lab { font-size:10px; line-height:1.2; text-align:center; margin-top:4px; max-width:100%; overflow:hidden; }
.wh-lab b { display:block; color:#0f1b2d; font-weight:700; white-space:nowrap; overflow:hidden; text-overflow:ellipsis; }
.wh-lab span { display:inline-block; color:#007bb0; font-weight:600; white-space:nowrap; max-width:100%; overflow:hidden; text-overflow:ellipsis; }
.wh-open { display:none; color:#94a3b8; font-size:11px; font-weight:600; }
.wh-tote { display:none; width:70%; height:26px; background:#e2e8f0; border:1.5px solid #94a3b8; border-radius:5px 5px 3px 3px; position:relative; margin-bottom:2px; }
.wh-tote::before { content:''; position:absolute; left:30%; right:30%; top:-7px; height:7px; border:1.5px solid #94a3b8; border-bottom:0; border-radius:4px 4px 0 0; }
.st-empty { border:1.5px dashed #d2dae4; justify-content:center; height:auto; align-self:stretch; margin-bottom:3px; }
.st-empty .wh-tier, .st-empty .wh-pal, .st-empty .wh-lab { display:none; }
.st-empty .wh-open { display:block; }
.st-reserved .wh-bx { background:transparent; border:1.5px dashed #94a3b8; box-shadow:none; }
.st-reserved .wh-bx::after { border-color:#a1acbb; }
.st-reserved .wh-bx::before { display:none; }
.st-reserved .wh-pal { background:transparent; border:1.5px dashed #94a3b8; box-shadow:none; }
.st-reserved .wh-lab b { color:#64748b; }
.st-reserved .wh-lab span { background:#fef3c7; color:#92400e; border-radius:999px; padding:0 7px; }
.st-misc .wh-tier, .st-misc .wh-pal { display:none; }
.st-misc .wh-tote { display:block; }
.st-misc .wh-lab span { color:#64748b; font-weight:500; }
.wh-legend-rack { align-items:flex-end; gap:14px; }
.wh-legend-rack .wh-p { flex:0 0 78px; height:130px; }
.wh-legend-rack .st-empty { height:60px; }

/* ── Slot and rack forms ── */
.wh-slot-sub { font-size:12px; margin-top:-6px; }
.wh-status-row { display:flex; gap:6px; flex-wrap:wrap; }
.wh-status { flex:1; min-width:90px; display:flex; align-items:center; justify-content:center; gap:6px; padding:10px 8px; border:1px solid #cbd5e1; border-radius:10px; font-size:13px; font-weight:600; color:#334155; cursor:pointer; background:#fff; }
.wh-status input { margin:0; }
.wh-status.on { border-color:#007bb0; background:#f0f9ff; color:#007bb0; }
.wh-f { display:flex; flex-direction:column; gap:4px; font-size:12px; font-weight:600; color:#475569; }
.wh-f input, .wh-f select, .wh-rack-form input, .wh-rack-form select, .wh-rack-form textarea { padding:9px 10px; border:1px solid #cbd5e1; border-radius:8px; font:inherit; font-size:14px; color:#0f1b2d; background:#fff; width:100%; box-sizing:border-box; }
.wh-f small { font-weight:500; min-height:14px; }
.wh-f[hidden] { display:none; }
.wh-wide { grid-column:1 / -1; }
.wh-rack-form label { display:flex; flex-direction:column; gap:4px; font-size:12px; font-weight:600; color:#475569; }
.wh-rack-form textarea { font-family:ui-monospace,SFMono-Regular,Menlo,monospace; font-size:13px; line-height:1.5; resize:vertical; }
.wh-rack-form small { font-weight:500; }
.wh-spacer { flex:1; }
@media (max-width:700px) {
  .wh-floor { max-height:none; }
  .wh-legend .wh-mini { margin-left:0; }
  .wh-rack-head { flex-direction:column; gap:10px; }
  .wh-legend-rack { display:none; }
}

/* ── Product color: a band on each carton, a dot by the SKU, the chip's left edge ── */
.col-cyan { --wh-c:#00afee; } .col-black { --wh-c:#111827; } .col-white { --wh-c:#ffffff; } .col-carbon { --wh-c:#6b7280; }
.col-wood { --wh-c:#b4833f; } .col-pink { --wh-c:#ec4899; } .col-green { --wh-c:#16a34a; } .col-sand { --wh-c:#d9c39a; }
.wh-p[class*="col-"] .wh-bx::before { left:0; right:0; top:0; height:6px; border-radius:0; background:var(--wh-c); opacity:1; box-shadow:0 1px 0 rgba(0,0,0,.12); }
.wh-p.col-white .wh-bx::before { box-shadow:inset 0 0 0 1px #cbd5e1; }
.wh-p[class*="col-"] .wh-bx::after { border-color:var(--wh-c); }
.wh-p.col-white .wh-bx::after { border-color:#94a3b8; }
.wh-p[class*="col-"] .wh-lab b::before, .wh-chip[class*="col-"] b::before { content:''; display:inline-block; width:8px; height:8px; border-radius:50%; background:var(--wh-c); margin-right:4px; vertical-align:0; box-shadow:inset 0 0 0 1px rgba(15,27,45,.25); }
.wh-p.st-reserved[class*="col-"] .wh-bx::before { opacity:.55; }
.wh-dot { display:inline-block; width:11px; height:11px; border-radius:50%; background:var(--wh-c); box-shadow:inset 0 0 0 1px rgba(15,27,45,.25); margin:0 3px 0 10px; vertical-align:-1px; }
.wh-colors { align-self:center; }
.wh-chip[class*="col-"] { border-left:4px solid var(--wh-c); }
.wh-chip.col-white { border-left-color:#cbd5e1; }

/* ── Pallet tray: tap a pallet, then tap open spots ── */
.wh-tray { display:flex; flex-direction:column; gap:10px; padding:12px 14px; border:1px solid #e2e8f0; border-radius:12px; background:#f8fafc; margin-bottom:12px; }
.wh-tray.active { border-color:#00afee; background:#f0f9ff; }
.wh-tray-head { display:flex; align-items:center; gap:12px; flex-wrap:wrap; font-size:13px; color:#0f1b2d; }
.wh-tray-what { flex:1; min-width:200px; font-weight:600; }
.wh-tray-qty { display:inline-flex; align-items:center; gap:8px; font-size:12px; color:#475569; font-weight:600; }
.wh-tray-qty input { width:72px; padding:6px 8px; border:1px solid #cbd5e1; border-radius:8px; font:inherit; font-size:13px; }
.wh-tray-group { display:flex; flex-direction:column; gap:6px; }
.wh-tray-label { font-size:12px; color:#475569; display:flex; align-items:center; gap:10px; flex-wrap:wrap; }
.wh-tray-label b { color:#0f1b2d; }
.wh-chips { display:flex; gap:8px; flex-wrap:wrap; align-items:center; }
.wh-chips input { padding:8px 10px; border:1px solid #cbd5e1; border-radius:8px; font:inherit; font-size:13px; min-width:220px; }
.wh-chip { display:flex; flex-direction:column; align-items:flex-start; gap:1px; padding:7px 10px; border:1px solid #cbd5e1; border-radius:10px; background:#fff; font:inherit; text-align:left; cursor:grab; color:#0f1b2d; min-width:120px; max-width:200px; }
.wh-chip b { font-size:12px; font-weight:700; }
.wh-chip span { font-size:11px; color:#64748b; white-space:nowrap; overflow:hidden; text-overflow:ellipsis; max-width:100%; }
.wh-chip em { font-style:normal; font-size:10.5px; color:#007bb0; font-weight:600; }
.wh-chip.reserved em { color:#92400e; }
.wh-chip.done { opacity:.55; }
.wh-chip:hover { border-color:#00afee; }
.wh-chip.on { border-color:#007bb0; background:#e0f2fe; box-shadow:0 0 0 2px rgba(0,175,238,.3); }
.wh-p.wh-target { border-color:#00afee; background:rgba(0,175,238,.06); }
.wh-p.wh-target .wh-open { color:#007bb0; }
.wh-p.wh-target:hover { background:rgba(0,175,238,.16); }
.wh-p.wh-lifted { opacity:.35; outline:2px dashed #00afee; outline-offset:-2px; }
.wh-p[draggable="true"] { cursor:grab; }
.wh-code { display:none; }
.wh-mini { padding:6px 12px; font-size:12px; }
.wh-rack-actions .wh-mini { padding:10px 14px; font-size:13px; }

/* ── Print: one rack per landscape page, spot codes shown ── */
#wh-print { display:none; }
@media print {
  @page { size: letter landscape; margin: 0.45in; }
  body.wh-printing > *:not(#wh-print) { display:none !important; }
  body.wh-printing { background:#fff !important; }
  #wh-print { display:block; color:#0f1b2d; font-family:inherit; }
  .wh-print-rack { page-break-after:always; break-after:page; }
  .wh-print-rack:last-child { page-break-after:auto; break-after:auto; }
  .wh-print-head { display:flex; justify-content:space-between; align-items:flex-start; gap:16px; margin-bottom:10px; }
  .wh-print-head h2 { margin:0; font-size:20px; }
  .wh-print-sub { font-size:11px; color:#475569; margin-top:2px; }
  .wh-print-stamp { font-size:11px; color:#475569; text-align:right; }
  .wh-print-scale { width:100%; }
  .wh-print-scale .wh-rackview { min-width:0 !important; }
  .wh-print-scale .wh-code { display:block; position:absolute; top:2px; left:4px; font-size:9px; font-weight:700; color:#475569; }
  .wh-print-scale .wh-p { padding-top:12px; }
  .wh-print-scale .wh-lab b { font-size:11px; }
  .wh-print-scale .wh-lab span { font-size:10.5px; }
  .wh-print-scale .st-reserved .wh-lab span { background:#fef3c7 !important; -webkit-print-color-adjust:exact; print-color-adjust:exact; }
  .wh-print-scale .wh-up, .wh-print-scale .wh-beam, .wh-print-scale .wh-bx, .wh-print-scale .wh-bx::before, .wh-print-scale .wh-pal, .wh-print-scale .wh-floorbar, .wh-print-scale .wh-tote, .wh-print-scale .wh-lab b::before { -webkit-print-color-adjust:exact; print-color-adjust:exact; }
  .wh-print-lists { display:grid; grid-template-columns:3fr 2fr; gap:18px; margin-top:12px; font-size:11px; }
  .wh-print-lists h3 { margin:0 0 6px; font-size:12px; text-transform:uppercase; letter-spacing:.05em; color:#475569; }
  .wh-print-table { width:100%; border-collapse:collapse; }
  .wh-print-table th, .wh-print-table td { text-align:left; padding:4px 6px; border-bottom:1px solid #e2e8f0; font-size:11px; }
  .wh-print-table th { font-size:10px; text-transform:uppercase; letter-spacing:.04em; color:#64748b; }
  .wh-print-open div { padding:2px 0; }
  .wh-print-note { margin:0; color:#64748b; }
  .wh-print-plan .wh-floor { width:100%; max-height:6.4in; min-width:0; }
}
