/* Day palette for the same green/red controls and table geometry as night mode. */
@media screen {
  body:not(.theme-dark) {
    --bg: #f5f6f5;
    --surface: #ffffff;
    --surface-raised: #f0f2f0;
    --surface-hover: #edf3ef;
    --ink: #232923;
    --muted: #626c64;
    --line: #dce2dd;
    --green: #008637;
    --red: #bf303a;
    --amber: #916817;
    --action: #008637;
    --action-hover: #00772f;
    --purple: var(--action);
    --purple-soft: #e7f4eb;
    --shadow: none;
    background: var(--bg);
    color: var(--ink);
    color-scheme: light;
    font-family: "Microsoft YaHei UI", "Microsoft YaHei", "PingFang SC", "Noto Sans SC", Arial, sans-serif;
    font-size: 16px;
    line-height: 1.6;
    -webkit-font-smoothing: antialiased;
    scrollbar-color: #b6c0b8 #eef1ee;
  }
  body:not(.theme-dark) .main { background: var(--bg); }
  body:not(.theme-dark) .topbar { flex-wrap: wrap; gap: 14px; }
  body:not(.theme-dark) .top-actions { flex-wrap: wrap; gap: 10px; margin-left: auto; }
  body:not(.theme-dark) .today { white-space: nowrap; }
  body:not(.theme-dark) .sidebar { background: #fafbfa; border-color: var(--line); }
  body:not(.theme-dark) :is(.panel,.stat-card,.task-card,.link-card,.finance-summary article,.temu-placeholder,.auth-card,dialog) {
    color: var(--ink); background: var(--surface); border-color: var(--line); box-shadow: none;
  }
  body:not(.theme-dark) .auth-gate { background: var(--bg); }
  body:not(.theme-dark) .brand-mark { background: var(--action); box-shadow: none; }
  body:not(.theme-dark) .avatar { background: #e7f4eb; color: #176536; }
  body:not(.theme-dark) .nav-item { color: #59655c; font-size: 15px; }
  body:not(.theme-dark) .nav-item:hover { background: var(--surface-raised); color: var(--ink); }
  body:not(.theme-dark) .nav-item.active { background: var(--action); color: #fff; }
  body:not(.theme-dark) .nav-item.active em { color: #fff; }
  body:not(.theme-dark) :is(.brand span,.nav-label,.sidebar-bottom,.eyebrow,.today,.current-username,footer) { color: #68736b; }
  body:not(.theme-dark) .status-dot { background: var(--green); }
  body:not(.theme-dark) :is(h1,h2,h3,.welcome h2,.topbar h1,.section-intro h2,.panel-head h3) { color: #202820; font-weight: 650; }
  body:not(.theme-dark) .panel-head h3 { font-size: 17px; }
  body:not(.theme-dark) :is(.section-intro p,.panel-head p,.muted,.auth-card p,.auth-card label,.temu-shop-picker label,.stat-top,.stat-card small,.finance-summary span,.finance-summary small,.task-note,.due-label,.task-mini-meta,.recent-sub,.recent-date,.link-url,.empty) { color: var(--muted); }
  body:not(.theme-dark) :is(.section-intro p,.panel-head p,.muted,.task-note) { font-size: 13px; line-height: 1.7; }
  body:not(.theme-dark) :is(.stat-card strong,.finance-summary strong) { color: #202820; font-variant-numeric: tabular-nums; }

  body:not(.theme-dark) .primary { background: var(--action); color: #fff; border: 1px solid var(--action); box-shadow: none; font-size: 14px; font-weight: 600; }
  body:not(.theme-dark) .primary:hover { background: var(--action-hover); border-color: var(--action-hover); }
  body:not(.theme-dark) .secondary { background: #e8f4ec; border-color: #aecfb9; color: #196437; font-size: 14px; font-weight: 500; box-shadow: none; }
  body:not(.theme-dark) .secondary:hover { background: #daeddf; border-color: #75a986; color: #124c29; }
  body:not(.theme-dark) .text-btn { background: transparent; color: #14763b; font-size: 13px; }
  body:not(.theme-dark) .text-btn:hover { color: #004d22; }
  body:not(.theme-dark) :is(.theme-toggle,.dialog-actions button[value="cancel"],#cancelCollectionPublish) { background: #f0f2f0; border-color: #cdd4ce; color: #465048; }
  body:not(.theme-dark) :is(.theme-toggle,.dialog-actions button[value="cancel"],#cancelCollectionPublish):hover { background: #e4e8e4; border-color: #a5b0a7; }
  body:not(.theme-dark) #logout { background: #fcebed; border-color: #e2b7bc; color: #a92b35; }
  body:not(.theme-dark) #logout:hover { background: #f8dce0; border-color: #cb7d85; }
  body:not(.theme-dark) .icon-btn { color: #18763c; }
  body:not(.theme-dark) .icon-btn:hover { background: #e4f2e9; color: #105b2d; border-radius: 5px; }
  body:not(.theme-dark) .icon-btn[data-delete] { color: #bf303a; }
  body:not(.theme-dark) .icon-btn[data-delete]:hover { background: #fce8eb; color: #a6242e; }
  body:not(.theme-dark) .icon-close { color: #6a746c; background: transparent; }
  body:not(.theme-dark) .icon-close:hover { color: #222a23; }
  body:not(.theme-dark) .temu-action-icon { background: #e8f4ec; color: #196437; border-color: #aecfb9; }
  body:not(.theme-dark) .temu-action-icon:hover { background: #daeddf; color: #124c29; border-color: #75a986; }
  body:not(.theme-dark) :is(button.danger,.temu-action-icon.danger) { background: #bf303a; color: #fff; border-color: #ce454e; }
  body:not(.theme-dark) :is(button.danger,.temu-action-icon.danger):hover { background: #a6242e; color: #fff; border-color: #b72f39; }
  body:not(.theme-dark) :is(button,a,.temu-import-button):focus-visible { outline: 2px solid #22884a; outline-offset: 3px; }
  body:not(.theme-dark) button:disabled { cursor: not-allowed; }

  body:not(.theme-dark) :is(.select,.temu-list-tools input,.task-controls select,.progress-input,.field input,.field select,.field textarea,.auth-card input,.temu-page-size select,.temu-sales-filters input,.temu-sales-filters select,.temu-cost-input) {
    color: #273128; background: #fff; border-color: #cbd4cd; font-family: inherit; font-size: 14px;
  }
  body:not(.theme-dark) :is(input,textarea)::placeholder { color: #727d74; opacity: 1; }
  body:not(.theme-dark) :is(input,select,textarea):focus { border-color: #398b54; outline: none; box-shadow: 0 0 0 2px #31bc5d26; }
  body:not(.theme-dark) .field label { color: #59655c; font-size: 14px; }
  body:not(.theme-dark) .auth-card #authError { color: #af2833; }

  body:not(.theme-dark) :is(.temu-table-wrap,.temu-sales-table-wrap) { background: var(--surface); border: 1px solid #d4dcd6; border-radius: 10px; }
  body:not(.theme-dark) .temu-table { border: 0; }
  body:not(.theme-dark) table th { color: #536057; background: #edf1ee; border-color: #d5ddd7; font-size: 14px; font-weight: 500; line-height: 1.6; }
  body:not(.theme-dark) table td { color: #29322b; border-color: var(--line); font-size: 14px; font-weight: 400; }
  body:not(.theme-dark) .temu-table :is(th,td) { border-color: var(--line); padding-top: 14px; padding-bottom: 14px; }
  body:not(.theme-dark) .temu-table th { background: #edf1ee; color: #536057; font-size: 14px; }
  body:not(.theme-dark) .temu-table td { background: var(--surface); font-size: 15px; line-height: 1.65; }
  body:not(.theme-dark) .temu-table :is(tr.temu-product-first,tr.temu-skc-first) td { border-top: 0; }
  body:not(.theme-dark) .temu-table :is(th,td):last-child { border-right: 0; }
  body:not(.theme-dark) .temu-table tbody tr:last-child td { border-bottom: 0; }
  body:not(.theme-dark) .temu-table tbody tr:nth-child(even) td { background: var(--surface); }
  body:not(.theme-dark) .temu-table tbody tr.temu-product-shade td { background: #f6f8f6; }
  body:not(.theme-dark) .temu-table tbody :is(tr:hover,tr.temu-product-shade:hover) td { background: var(--surface-hover); }
  body:not(.theme-dark) .temu-table tbody tr.temu-product-hover td { background: var(--surface-hover) !important; }
  body:not(.theme-dark) .temu-title-copy { color: #202820; font-size: 15px; line-height: 1.7; font-weight: 600; }
  body:not(.theme-dark) .temu-title-copy:hover { color: #12642f; }
  body:not(.theme-dark) .temu-category-full { color: #5d6a60; text-decoration: none; }
  body:not(.theme-dark) :is(.temu-id-line>span,.temu-sku-line>span:first-child) { color: #626e65; font-size: 13px; }
  body:not(.theme-dark) :is(.temu-id-line code,.temu-sku-line code,.temu-sku-line>span:nth-child(2)) { color: #29332b; font-family: inherit; font-size: 14px; font-weight: 400; }
  body:not(.theme-dark) .temu-sku-info-cell+td { color: #008637; font-weight: 600; font-variant-numeric: tabular-nums; }
  body:not(.theme-dark) .temu-profit-rate { color: #626e65; font-size: 13px; }
  body:not(.theme-dark) .temu-profit-cell strong { font-weight: 500; }
  body:not(.theme-dark) :is(.temu-thumb-empty,.temu-thumb) { background: #f0f3f0; border: 1px solid #d5ddd7; color: #66736a; }
  body:not(.theme-dark) .temu-cost-editable:hover { box-shadow: inset 0 0 0 1px #70a37f; }
  body:not(.theme-dark) .temu-copy-btn { background: transparent; color: #adb8b0; border: 0; }
  body:not(.theme-dark) .temu-copy-btn:hover,body:not(.theme-dark) .temu-copy-btn:focus-visible { background: transparent; color: #5a6c60; }
  body:not(.theme-dark) :is(.temu-table-wrap,.temu-sales-table-wrap) .empty { background: var(--surface); color: var(--muted); }
  body:not(.theme-dark) :is(.temu-page-button:hover,.temu-page-arrow:not(:disabled):hover) { background: #e8f0eb; border-color: #9cbfa7; }
  body:not(.theme-dark) .temu-page-button.active { background: var(--action); border-color: var(--action); color: #fff; }

  body:not(.theme-dark) .welcome { background: #e4efe7; }
  body:not(.theme-dark) :is(.welcome p,.welcome-overline) { color: #526e5b; }
  body:not(.theme-dark) .orb-a { background: linear-gradient(145deg,#c5e2cf,#88bc98); }
  body:not(.theme-dark) .orb-b { background: linear-gradient(145deg,#d8eadf,#adcdb8); }
  body:not(.theme-dark) .art-card { background: #edf7f0e6; color: #287a46; box-shadow: none; }
  body:not(.theme-dark) :is(.purple,.green,.tx-symbol.income,.tx-kind.income) { background: #e4f3e9; color: #18743b; }
  body:not(.theme-dark) :is(.coral,.tx-symbol.expense,.tx-kind.expense) { background: #fce9eb; color: #b22e39; }
  body:not(.theme-dark) .amber { background: #faf1dc; color: #86611b; }
  body:not(.theme-dark) .tag.urgent { background: #fbe6e9; color: #b22e39; }
  body:not(.theme-dark) :is(.tag.normal,.tag.long) { background: #e5f2e9; color: #226d3c; }
  body:not(.theme-dark) .filter { color: #59675e; font-size: 13px; }
  body:not(.theme-dark) .filter.active { background: #e1f0e6; color: #1b6335; box-shadow: none; }
  body:not(.theme-dark) .filter span { color: #69766d; }
  body:not(.theme-dark) .progress-track { background: #e1e7e2; }
  body:not(.theme-dark) .link-name { color: var(--ink); }
  body:not(.theme-dark) .link-actions { opacity: 1; }
  body:not(.theme-dark) .quick-link { background: #f7f9f7; border-color: var(--line); color: #29362d; }
  body:not(.theme-dark) :is(.quick-link:hover,.link-card:hover) { background: #edf5ef; border-color: #9fc0a9; }
  body:not(.theme-dark) .favicon { background: #eaf1ec; color: #226e3d; }
  body:not(.theme-dark) .add-dashed { background: #f0f7f2; color: #336d46; border-color: #a9c7b2; }
  body:not(.theme-dark) :is(.tip-box,.coming-pill) { background: #eaf3ed; color: #466c53; }
  body:not(.theme-dark) .recent-row { border-color: var(--line); }
  body:not(.theme-dark) :is(.home-task-title,.recent-name) { font-size: 14px; }
  body:not(.theme-dark) .tx-amount.expense { color: #b52d39; }
  body:not(.theme-dark) .tx-amount.income { color: #12783a; }
  body:not(.theme-dark) :is(.ocr-text,.sync-token) { background: #f0f3f1; border-color: #d5ddd7; color: #3e5144; }
  body:not(.theme-dark) .ocr-status { color: #226e3d; }
  body:not(.theme-dark) .upload-box { background: #f7faf8; border-color: #aebfb3; color: #495e50; }
  body:not(.theme-dark) .upload-box span { color: #257d44; }
  body:not(.theme-dark) .upload-box small { color: #6a786f; }
  body:not(.theme-dark) dialog::backdrop { background: #16271c55; }
  body:not(.theme-dark) .toast { background: #273a2e; border: 1px solid #4b6353; color: #fff; }
}
