
    :root {
      --ink: #10282d;
      --muted: #758286;
      --teal-950: #072a30;
      --teal-900: #0a343b;
      --teal-700: #137a75;
      --teal-600: #23928b;
      --teal-300: #82d9d0;
      --teal-100: #dff6f2;
      --teal-50: #effaf8;
      --line: #dce6e5;
      --surface: #ffffff;
      --page: #f3f8f7;
      --amber: #d29a2e;
      --amber-bg: #fff8e6;
      --danger: #bf4a4a;
      --danger-bg: #fff0f0;
      --shadow: 0 12px 35px rgba(16, 64, 66, 0.08);
    }

    * { box-sizing: border-box; }
    [hidden] { display: none !important; }
    html { min-width: 320px; background: var(--page); }
    body {
      margin: 0;
      min-height: 100vh;
      color: var(--ink);
      background:
        linear-gradient(rgba(255,255,255,.68), rgba(255,255,255,.68)),
        repeating-linear-gradient(0deg, transparent 0 31px, rgba(35,146,139,.025) 31px 32px),
        var(--page);
      font-family: "Noto Sans SC", "Microsoft YaHei", sans-serif;
      letter-spacing: 0;
    }
    button, input, select, textarea { font: inherit; letter-spacing: 0; }
    button { cursor: pointer; }
    button:focus-visible, input:focus-visible, select:focus-visible, textarea:focus-visible {
      outline: 3px solid rgba(35,146,139,.2);
      outline-offset: 2px;
    }
    .icon { width: 18px; height: 18px; flex: 0 0 auto; stroke-width: 1.8; }

    .topbar {
      height: 76px;
      padding: 0 clamp(20px, 4vw, 52px);
      display: flex;
      align-items: center;
      justify-content: space-between;
      color: #fff;
      background: var(--teal-950);
      box-shadow: 0 4px 18px rgba(4, 33, 37, .12);
    }
    .brand { display: flex; align-items: center; gap: 13px; min-width: 0; }
    .brand-mark {
      width: 43px; height: 43px; border-radius: 12px;
      display: grid; place-items: center;
      color: var(--teal-950); background: #72d8cf;
      box-shadow: inset 0 0 0 1px rgba(255,255,255,.28);
    }
    .brand-mark .icon { width: 23px; height: 23px; stroke-width: 2; }
    .brand strong { display: block; font-size: 17px; line-height: 1.2; white-space: nowrap; }
    .brand small { display: block; margin-top: 3px; color: #b9cdcf; font-size: 12px; }
    .top-actions { display: flex; align-items: center; gap: 18px; }
    .status { display: flex; align-items: center; gap: 8px; font-size: 13px; color: #dcebec; }
    .status-dot { width: 8px; height: 8px; border-radius: 50%; background: #58d4af; box-shadow: 0 0 0 5px rgba(88,212,175,.08); }

    .btn {
      min-height: 39px; padding: 0 15px; border: 1px solid var(--line); border-radius: 7px;
      display: inline-flex; align-items: center; justify-content: center; gap: 8px;
      color: var(--ink); background: #fff; font-weight: 500; transition: .18s ease;
    }
    .btn:hover { border-color: #b8d4d1; background: var(--teal-50); transform: translateY(-1px); }
    .btn:active { transform: translateY(0); }
    .btn:disabled, .action-link:disabled { cursor: not-allowed; opacity: .45; transform: none; }
    .btn:disabled:hover { border-color: var(--line); color: inherit; background: #fff; transform: none; }
    .btn-primary:disabled:hover { color: #fff; background: var(--teal-700); border-color: var(--teal-700); }
    .btn-ghost-dark { min-height: 36px; padding: 0 11px; color: #e5f2f2; background: rgba(255,255,255,.04); border-color: rgba(255,255,255,.12); }
    .btn-ghost-dark:hover { color: #fff; background: rgba(255,255,255,.09); border-color: rgba(255,255,255,.2); }
    .btn-primary { color: #fff; background: var(--teal-700); border-color: var(--teal-700); }
    .btn-primary:hover { color: #fff; background: #0f6a66; border-color: #0f6a66; }
    .btn-danger { color: var(--danger); border-color: #f0cccc; background: var(--danger-bg); }
    .btn-icon { width: 38px; padding: 0; }

    .shell {
      width: min(1220px, calc(100% - 48px));
      margin: 24px auto 42px;
      display: grid;
      grid-template-columns: 290px minmax(0, 1fr);
      gap: 22px;
      align-items: start;
    }
    .sidebar, .workspace {
      border: 1px solid rgba(182, 205, 203, .75);
      background: rgba(255,255,255,.92);
      box-shadow: var(--shadow);
    }
    .sidebar { border-radius: 18px; padding: 20px 18px; }
    .account-head { display: flex; align-items: start; justify-content: space-between; gap: 10px; margin: 0 2px 15px; }
    .eyebrow { margin: 0 0 4px; color: var(--muted); font-size: 12px; }
    .account-id { font-family: ui-monospace, SFMono-Regular, Consolas, monospace; font-size: 13px; font-weight: 600; }
    .connected { padding: 3px 8px; border: 1px solid #bfe0d6; border-radius: 99px; color: #2b765f; background: #f1fbf7; font-size: 11px; white-space: nowrap; }

    .stat-list { display: grid; gap: 10px; }
    .stat {
      min-height: 72px; padding: 14px 15px;
      display: grid; grid-template-columns: 38px 1fr; align-items: center; gap: 12px;
      border: 1px solid #e2e9e8; border-radius: 10px;
      background: linear-gradient(120deg, #fff, #fbfdfd);
    }
    .stat-icon { width: 36px; height: 36px; border-radius: 10px; display: grid; place-items: center; color: var(--teal-700); background: var(--teal-50); }
    .stat:nth-child(2) .stat-icon { color: #9a7a25; background: var(--amber-bg); }
    .stat:nth-child(3) .stat-icon { color: #66787c; background: #f2f5f5; }
    .stat span { color: var(--muted); font-size: 12px; }
    .stat strong { display: block; margin-top: 2px; color: var(--ink); font-size: 21px; line-height: 1; }

    .recharge {
      margin-top: 14px; padding: 18px 16px; border-radius: 14px; color: #fff;
      background: var(--teal-900); box-shadow: 0 12px 25px rgba(7,42,48,.14);
    }
    .recharge h3 { margin: 0 0 13px; display: flex; align-items: center; gap: 8px; font-size: 14px; }
    .recharge-row { display: flex; gap: 8px; }
    .recharge input {
      width: 100%; min-width: 0; height: 42px; padding: 0 12px; color: #fff;
      border: 1px solid rgba(255,255,255,.16); border-radius: 8px; background: rgba(255,255,255,.06);
    }
    .recharge input::placeholder { color: #91aaad; }
    .recharge .btn { width: 42px; height: 42px; min-height: 42px; padding: 0; border: 0; color: #07373a; background: #61c8be; }

    .safety { margin: 20px 4px 0; display: grid; grid-template-columns: 24px 1fr; gap: 9px; }
    .safety .icon { margin-top: 1px; color: var(--teal-600); }
    .safety h4 { margin: 0 0 4px; font-size: 13px; }
    .safety p { margin: 0; color: var(--muted); font-size: 11px; line-height: 1.7; }

    .workspace { min-height: 640px; border-radius: 20px; padding: 25px 24px 22px; overflow: hidden; }
    .workspace-head { display: flex; align-items: end; justify-content: space-between; gap: 20px; margin-bottom: 12px; }
    .section-kicker { margin: 0 0 2px; color: var(--teal-700); font-size: 12px; font-weight: 700; }
    h1 { margin: 0; font-size: clamp(24px, 3vw, 31px); line-height: 1.2; letter-spacing: 0; }
    .workspace-head-actions { display: flex; align-items: center; gap: 12px; }
    .updated { color: var(--muted); font-size: 12px; white-space: nowrap; }
    .refresh-status { height: 36px; white-space: nowrap; }
    .refresh-status .spin { animation: refreshSpin .9s linear infinite; }
    @keyframes refreshSpin { to { transform: rotate(360deg); } }

    .count { min-width: 24px; padding: 2px 6px; border-radius: 99px; color: #48716d; background: var(--teal-50); font-size: 10px; }

    .panel { display: none; padding-top: 17px; }
    .panel.active { display: block; }
    .panel-bar { min-height: 53px; display: flex; align-items: start; justify-content: space-between; gap: 16px; }
    .panel-bar h2 { margin: 0 0 3px; font-size: 16px; }
    .panel-bar p { margin: 0; color: var(--muted); font-size: 12px; line-height: 1.6; }
    .bar-actions { display: flex; align-items: center; gap: 8px; flex: 0 0 auto; }
    select, .field {
      height: 39px; padding: 0 12px; color: var(--ink); border: 1px solid var(--line); border-radius: 7px; background: #fff;
    }

    .table-wrap { border: 1px solid var(--line); border-radius: 9px; overflow: auto; background: #fff; }
    table { width: 100%; min-width: 690px; border-collapse: collapse; table-layout: fixed; }
    th, td { height: 57px; padding: 10px 12px; border-bottom: 1px solid #e4e9e8; text-align: left; vertical-align: middle; font-size: 12px; }
    th { height: 42px; color: #455559; background: #f7faf9; font-weight: 500; }
    tr:last-child td { border-bottom: 0; }
    tbody tr:hover { background: #fcfefe; }
    .sku-cell { display: flex; align-items: center; gap: 10px; min-width: 0; }
    .thumb { width: 42px; height: 42px; flex: 0 0 auto; border-radius: 7px; object-fit: cover; background: #e8efee; }
    .sku-meta { min-width: 0; }
    .sku-code { display: block; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-weight: 600; }
    .sku-name { display: block; margin-top: 2px; overflow: hidden; color: var(--muted); text-overflow: ellipsis; white-space: nowrap; font-size: 10px; }
    .tag { width: fit-content; max-width: 100%; padding: 4px 8px; border-radius: 4px; display: inline-flex; align-items: center; gap: 6px; white-space: nowrap; color: #267262; background: #e9f8f2; font-size: 11px; }
    .tag::before { content: ""; width: 5px; height: 5px; flex: 0 0 auto; border-radius: 50%; background: currentColor; }
    .tag.pending { color: #997522; background: var(--amber-bg); }
    .tag.failed { color: var(--danger); background: var(--danger-bg); }
    .result-ok { color: #1a5e52; font-weight: 600; }
    .result-pending { color: #8b7024; font-weight: 600; }
    .action-link { padding: 6px 7px; border: 0; display: inline-flex; align-items: center; gap: 6px; color: #385055; background: transparent; white-space: nowrap; }
    .action-link:hover { color: var(--teal-700); }
    .empty { padding: 55px 20px; text-align: center; color: var(--muted); }
    .empty .icon { width: 28px; height: 28px; margin-bottom: 8px; }

    .submit-layout { display: grid; grid-template-columns: minmax(0, 1.3fr) minmax(250px, .7fr); gap: 18px; }
    .form-section { padding: 20px; border: 1px solid var(--line); border-radius: 9px; background: #fff; }
    .form-section h3 { margin: 0 0 17px; font-size: 15px; }
    .batch-hint { margin-left: 8px; color: var(--muted); font-size: 11px; font-weight: 400; }
    .form-group { margin-bottom: 15px; }
    .form-group label { display: flex; align-items: center; justify-content: space-between; margin-bottom: 7px; color: #405054; font-size: 12px; font-weight: 500; }
    .form-group label small { color: var(--muted); font-weight: 400; }
    textarea {
      width: 100%; min-height: 170px; padding: 12px; resize: vertical; color: var(--ink);
      border: 1px solid var(--line); border-radius: 8px; background: #fbfdfd; line-height: 1.7;
    }
    .sku-entry-layout { display: grid; grid-template-columns: minmax(0, 1fr) 138px; gap: 10px; align-items: stretch; }
    .sku-entry-help { padding: 11px 10px; border: 1px solid var(--line); border-radius: 7px; color: var(--muted); background: #f7fbfa; font-size: 11px; line-height: 1.7; }
    .sku-entry-help strong { display: block; margin-bottom: 5px; color: var(--ink); font-size: 11px; }
    .sku-entry-help code { display: block; color: var(--teal-700); font-family: Consolas, monospace; font-size: 11px; }
    textarea::placeholder { color: #9aa7a8; }
    .mode-control { display: grid; grid-template-columns: 1fr 1fr; gap: 0; border: 1px solid #bfd8d5; border-radius: 8px; overflow: hidden; }
    .mode-option { min-height: 52px; padding: 7px 12px; border: 0; border-right: 1px solid #d6e5e3; color: #536568; background: #fff; }
    .mode-option:last-child { border-right: 0; }
    .mode-option strong, .mode-option small { display: block; }
    .mode-option strong { font-size: 13px; }
    .mode-option small { margin-top: 2px; color: #839092; font-size: 10px; }
    .mode-option.active { color: #fff; background: var(--teal-700); }
    .mode-option.active small { color: #d9f3ef; }
    .form-footer { display: flex; align-items: center; justify-content: space-between; gap: 12px; }
    .cost-hint { color: var(--muted); font-size: 12px; }
    .guide { padding: 20px; border: 1px solid #d9ebe8; border-radius: 9px; background: var(--teal-50); }
    .guide h3 { margin: 0 0 13px; font-size: 15px; }
    .guide ol { margin: 0; padding-left: 19px; color: #56676a; font-size: 12px; line-height: 2; }
    .guide-note { margin-top: 14px; padding-top: 13px; border-top: 1px solid #cde4e0; display: flex; gap: 8px; color: #43726d; font-size: 11px; line-height: 1.6; }

    .ledger-summary { display: grid; grid-template-columns: repeat(3, 1fr); gap: 10px; margin-bottom: 15px; }
    .ledger-metric { padding: 15px; border: 1px solid var(--line); border-radius: 8px; background: #fff; }
    .ledger-metric span { color: var(--muted); font-size: 11px; }
    .ledger-metric strong { display: block; margin-top: 4px; font-size: 20px; }

    .toast-region { position: fixed; right: 22px; bottom: 22px; z-index: 20; display: grid; gap: 8px; }
    .toast {
      min-width: 260px; max-width: min(390px, calc(100vw - 44px)); padding: 13px 15px;
      display: flex; align-items: center; gap: 10px; color: #fff; background: var(--teal-950);
      border-radius: 8px; box-shadow: 0 16px 35px rgba(4,33,37,.22); animation: toastIn .24s ease-out;
    }
    .toast.error { background: #7b3232; }
    .toast .icon { color: #6be0c1; }
    @keyframes toastIn { from { opacity: 0; transform: translateY(8px); } to { opacity: 1; transform: none; } }

    @media (max-width: 900px) {
      .shell { width: min(100% - 28px, 720px); grid-template-columns: 1fr; }
      .sidebar { display: grid; grid-template-columns: 1fr 1fr; gap: 14px 18px; }
      .account-head, .stat-list { grid-column: 1; }
      .recharge, .safety { grid-column: 2; }
      .recharge { margin-top: 0; align-self: start; }
      .safety { margin-top: 0; }
      .submit-layout { grid-template-columns: 1fr; }
    }
    @media (max-width: 620px) {
      .topbar { height: 68px; padding: 0 15px; }
      .brand-mark { width: 38px; height: 38px; }
      .brand strong { font-size: 15px; }
      .brand small { display: none; }
      .status span:last-child { display: none; }
      .top-actions { gap: 9px; }
      .btn-ghost-dark span { display: none; }
      .btn-ghost-dark { width: 38px; padding: 0; }
      .shell { width: calc(100% - 20px); margin-top: 10px; gap: 10px; }
      .sidebar { padding: 15px; grid-template-columns: 1fr; border-radius: 12px; }
      .account-head, .stat-list, .recharge, .safety { grid-column: 1; }
      .stat-list { grid-template-columns: repeat(3, 1fr); }
      .stat { min-height: 90px; padding: 10px 6px; grid-template-columns: 1fr; justify-items: center; text-align: center; gap: 6px; }
      .stat-icon { width: 30px; height: 30px; }
      .stat strong { font-size: 18px; }
      .safety { display: none; }
      .workspace { min-height: 580px; padding: 19px 14px; border-radius: 12px; }
      .workspace-head { align-items: start; flex-wrap: wrap; }
      .workspace-head-actions { width: 100%; justify-content: flex-end; }
      .updated { display: none; }
      .tab { min-width: 0; flex: 1; height: 44px; padding: 0 7px; font-size: 12px; }
      .tab .icon { width: 16px; }
      .tab .count { display: none; }
      .panel-bar { align-items: stretch; flex-direction: column; }
      .bar-actions { justify-content: space-between; }
      .bar-actions select { flex: 1; }
      .ledger-summary { grid-template-columns: 1fr; }
      .form-section, .guide { padding: 16px; }
      .sku-entry-layout { grid-template-columns: 1fr; }
      .form-footer { align-items: stretch; flex-direction: column; }
      .form-footer .btn { width: 100%; }
    }

    /* Local edition: readable account access, manual settlement, and batch lookup. */
    :root { --teal-950: #082d35; --teal-900: #0a3941; --teal-700: #0d756f; --page: #eef5f4; }
    body { font-family: "Noto Sans SC", "Microsoft YaHei UI", "Microsoft YaHei", system-ui, sans-serif; }
    .shell { width: min(1360px, calc(100% - 48px)); }
    .sidebar, .workspace { background: rgba(255,255,255,.96); }
    .sidebar { position: sticky; top: 18px; }
    .account-name { margin-top: 4px; color: #607376; font-size: 12px; overflow-wrap: anywhere; }
    .recharge-help { margin: 11px 0 0; color: #b5d0d1; font-size: 11px; line-height: 1.5; }
    .logout-link { margin: 18px 3px 0; padding: 4px 0; display: inline-flex; gap: 7px; align-items: center; color: #61777a; border: 0; background: none; font-size: 12px; }
    .logout-link:hover { color: var(--danger); }
    .logout-link .icon { width: 15px; height: 15px; }
    .status.offline .status-dot { background: #ee8f7e; box-shadow: 0 0 0 5px rgba(238,143,126,.1); }
    .submit-layout { grid-template-columns: minmax(0, 1.55fr) minmax(235px, .65fr); }
    .form-section { border-radius: 13px; }
    .guide { border-radius: 13px; align-self: start; }
    .field-meta { margin-top: 6px; display: flex; justify-content: space-between; gap: 8px; color: var(--muted); font-size: 11px; }
    .field-meta .invalid { color: var(--danger); }
    .sku-file-row { display:flex; align-items:center; flex-wrap:wrap; gap:10px; margin-top:10px; }
    .sku-file-row input[type=file] { position:absolute; width:1px; height:1px; opacity:0; overflow:hidden; }
    .sku-file-button { display:inline-flex; align-items:center; min-height:34px; padding:0 13px; border:1px solid var(--line); border-radius:9px; background:#fff; color:var(--ink); font-size:12px; font-weight:700; cursor:pointer; }
    .sku-file-button:hover { border-color:var(--teal-700); color:var(--teal-700); }
    .sku-file-row:focus-within .sku-file-button { outline:2px solid var(--teal-700); outline-offset:2px; }
    .sku-file-row small { color:var(--muted); font-size:11px; }
    .competitor-lookup { grid-column: 1 / -1; margin-top: 0; padding: 20px; border: 1px solid var(--line); border-radius: 13px; background: #fff; }
    .lookup-head { margin-bottom: 14px; display: flex; justify-content: space-between; align-items: start; gap: 12px; }
    .lookup-head h3 { margin: 0 0 4px; }
    .lookup-head p { margin: 0; color: var(--muted); font-size: 11px; line-height: 1.5; }
    .bridge-state { flex: 0 0 auto; padding: 5px 8px; border: 1px solid #ecd9b5; border-radius: 20px; color: #956b24; background: #fff9ec; font-size: 10px; }
    .bridge-state.ready { border-color: #bfe1d5; color: #247a5c; background: #f1fbf6; }
    .competitor-lookup label { margin: 13px 0 7px; display: flex; justify-content: space-between; gap: 8px; color: #405054; font-size: 12px; font-weight: 500; }
    .competitor-lookup label small { color: var(--muted); font-weight: 400; }
    .lookup-url-row input { min-width: 0; width: 100%; height: 39px; padding: 0 11px; border: 1px solid var(--line); border-radius: 7px; background: #fff; }
    .lookup-url-row .btn { flex: 0 0 auto; }
    .lookup-textarea { min-height: 100px; background: #fff; }
    .lookup-actions { margin-top: 12px; display: flex; justify-content: flex-end; align-items: center; gap: 8px; flex-wrap: wrap; }
    .competitor-lookup .concurrency-label { margin: 0 auto 0 0; align-items: center; justify-content: flex-start; white-space: nowrap; }
    .concurrency-label select { margin-left: 6px; height: 34px; min-width: 64px; }
    .lookup-result { margin-top: 12px; padding: 10px 12px; min-height: 38px; border-radius: 8px; color: #577376; background: #f4f9f8; font-size: 11px; line-height: 1.6; }
    .lookup-results { margin-top: 16px; }
    .lookup-results-head { margin-bottom: 9px; display: flex; align-items: center; justify-content: space-between; gap: 12px; }
    .lookup-results-head strong { font-size: 12px; }
    .lookup-results-head div { display: flex; gap: 6px; }
    .btn-small { min-height: 30px; padding: 0 10px; font-size: 11px; }
    .lookup-table { min-width: 590px; }
    .lookup-table th, .lookup-table td { width: auto; height: auto; min-height: 42px; }
    .lookup-table td { overflow-wrap: anywhere; }
    .lookup-status { color: #276d5a; }
    .lookup-status.uncertain { color: #a66a2d; }
    .lookup-free { display: inline-flex; vertical-align: middle; margin-left: 8px; padding: 4px 8px; border-radius: 20px; background: #e8f6ef; color: #287d65; font-size: 10px; font-weight: 600; }
    .lookup-install { margin-bottom: 18px; padding: 10px 13px; border: 1px solid #deebe5; border-radius: 10px; background: #f8fcf9; color: #4b6860; font-size: 12px; line-height: 1.7; }
    .lookup-install summary { cursor: pointer; font-weight: 650; }
    .lookup-install p { margin: 8px 0; }
    .lookup-install .btn { margin-top: 3px; text-decoration: none; }
    .competitor-lookup { scroll-margin-top: 115px; }
    .lookup-table { min-width: 820px; }
    .lookup-offer { margin-bottom: 6px; }
    .lookup-offer:last-child { margin-bottom: 0; }
    .lookup-offer strong { display: block; font-size: 12px; }
    .lookup-offer span { display: block; margin-top: 2px; font-size: 11px; color: var(--muted); }
    .competitor-lookup { min-width: 0; }
    .lookup-price-groups { display: grid; grid-template-columns: minmax(0, 1fr); gap: 14px; }
    .lookup-price-group { min-width: 0; padding: 16px; border: 1px solid #dce9e2; border-radius: 12px; background: #f8fcfa; }
    .lookup-high-group { border-color: #e2e7ee; background: #fafbfd; }
    .lookup-unknown-group { margin-top: 14px; border-color: #efdfc3; background: #fffaf2; }
    .lookup-group-head { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 10px; margin-bottom: 13px; }
    .lookup-group-head h4 { margin: 0 0 4px; color: #245e51; font-size: 14px; line-height: 1.5; }
    .lookup-high-group h4 { color: #455d76; }
    .lookup-unknown-group h4 { color: #8e652e; }
    .lookup-group-head span { color: var(--muted); font-size: 11px; }
    .lookup-group-actions { display: flex; gap: 7px; }
    .lookup-group-table { min-width: 660px; background: #fff; }
    .lookup-group-table th, .lookup-group-table td { width: auto; height: auto; }
    .lookup-group-table td { padding-top: 13px; padding-bottom: 13px; }
    .lookup-group-empty { color: var(--muted); text-align: center; }
    .lookup-group-hint { margin: 0 0 13px; color: var(--muted); font-size: 11px; line-height: 1.7; }
    .lookup-seller-name { display: block; margin-top: 3px; color: var(--muted); font-size: 10px; }
    .lookup-delta { white-space: nowrap; font-variant-numeric: tabular-nums; }
    .lookup-overview { margin-top: 18px; }
    .lookup-overview summary { margin-bottom: 12px; color: #507369; cursor: pointer; font-size: 12px; font-weight: 650; }
    #lookupValidation.invalid { color: #c34c3c; }
    .competitor-lookup .sku-file-row .sku-file-button { justify-content: center; margin: 0; }
    @media (max-width: 620px) {
      .lookup-actions .concurrency-label { flex: 1; }
      .lookup-actions > .btn { flex: 1 0 90px; }
      .lookup-install { font-size: 11px; }
      .lookup-install a { width: 100%; }
      .lookup-price-group { padding: 12px; }
      .lookup-group-head h4 { font-size: 13px; }
      .lookup-group-actions { width: 100%; }
      .lookup-group-actions .btn { flex: 1; }
      .competitor-lookup > label small { max-width: 180px; }
    }
    .task-metrics { margin: 10px 0 16px; display: grid; grid-template-columns: repeat(4, 1fr); gap: 8px; }
    .task-metrics > div { min-height: 65px; padding: 12px 15px; border: 1px solid var(--line); border-radius: 9px; display: flex; justify-content: space-between; align-items: center; gap: 8px; background: #fff; }
    .task-metrics strong { color: var(--teal-900); font-size: 21px; }
    .task-metrics span { color: var(--muted); font-size: 11px; white-space: nowrap; }
    .sku-avatar { width: 42px; height: 42px; flex: 0 0 auto; border-radius: 8px; display: grid; place-items: center; color: #347f78; background: #e4f5f1; font-size: 10px; font-weight: 700; }
    .done-label { color: #2c765d; }
    .pending-label { color: #849294; }
    .credit { color: #267262; font-weight: 600; }
    .debit { color: #9a5b2a; font-weight: 600; }
    .neutral { color: #607476; font-weight: 600; }
    .activation-panel { display: grid; grid-template-columns: minmax(0, .9fr) minmax(280px, 1.1fr); gap: 22px; align-items: center; margin: 0 0 26px; padding: 20px 22px; border: 1px solid #b9e0d9; border-radius: 16px; background: linear-gradient(125deg, #e8f9f4, #fff); }
    .activation-panel.activated { border-color: #cddfdb; background: linear-gradient(125deg, #f4faf8, #fff); }
    .activation-copy h2 { margin: 4px 0 6px; font-size: 20px; line-height: 1.3; }
    .activation-copy p { margin: 0; color: #617779; font-size: 12px; line-height: 1.7; }
    .activation-form label { display: block; margin-bottom: 7px; color: #304d4d; font-size: 12px; font-weight: 700; }
    .activation-controls { display: flex; gap: 8px; }
    .activation-controls input { min-width: 0; flex: 1; height: 44px; padding: 0 13px; border: 1px solid #bcd9d4; border-radius: 8px; background: #fff; }
    .activation-controls .btn { min-height: 44px; white-space: nowrap; }
    .activation-tools { min-height: 20px; display: flex; align-items: start; justify-content: space-between; gap: 10px; margin-top: 6px; }
    .activation-visibility { padding: 0; border: 0; background: transparent; color: #437973; font-size: 11px; }
    .activation-visibility:hover { text-decoration: underline; }
    .activation-error { color: var(--danger); font-size: 11px; line-height: 1.5; text-align: right; }
    .account-name { margin-top: 4px; color: var(--muted); font-size: 11px; line-height: 1.5; overflow-wrap: anywhere; }
    .connected.inactive { color: #6f7f81; background: #f2f5f4; border-color: #dfe7e5; }
    .locked-note { margin: 0 0 14px; padding: 12px 14px; border: 1px solid #d4e5e2; border-radius: 9px; color: #526e6c; background: #f3faf8; font-size: 12px; }
    @media (max-width: 900px) { .sidebar { position: static; } .submit-layout { grid-template-columns: 1fr; } .activation-panel { grid-template-columns: 1fr; } }
    @media (max-width: 620px) { .shell { width: calc(100% - 20px); } .task-metrics { grid-template-columns: repeat(2, 1fr); } .lookup-head { flex-wrap: wrap; } .lookup-results-head { flex-wrap: wrap; } .lookup-results-head div { width: 100%; } .lookup-results-head .btn { flex: 1; } .activation-panel { padding: 17px; } .activation-controls { flex-direction: column; } .activation-controls .btn { width: 100%; } }

    /* Customer workspace refresh: quiet surfaces, clear hierarchy, fast motion. */
    :root {
      --ink: #1a3332;
      --muted: #677d7d;
      --teal-950: #112e30;
      --teal-900: #173b3c;
      --teal-700: #1e726c;
      --teal-600: #278980;
      --teal-50: #eaf5f1;
      --line: #dfe8e4;
      --page: #f4f6f2;
      --shadow: 0 16px 42px rgba(29, 59, 52, .07);
    }
    html { min-width: 0; scroll-behavior: smooth; }
    body {
      background:
        radial-gradient(ellipse 70% 400px at 6% -130px, rgba(127,178,160,.15), transparent 75%),
        radial-gradient(ellipse 45% 380px at 100% 8%, rgba(215,204,173,.11), transparent 75%),
        var(--page);
      color: var(--ink);
      font-family: "PingFang SC", "Microsoft YaHei UI", "Noto Sans SC", system-ui, sans-serif;
      -webkit-font-smoothing: antialiased;
    }
    .topbar {
      height: 76px;
      position: sticky;
      top: 0;
      z-index: 10;
      padding: 0 clamp(20px, 3.7vw, 64px);
      background: linear-gradient(105deg, #102b2e, #163c3e 68%, #214c49);
      box-shadow: 0 7px 25px rgba(19,49,47,.12);
    }
    .topbar::after {
      content: ""; position: absolute; inset: auto 0 0;
      height: 1px; background: rgba(255,255,255,.12);
    }
    .brand { gap: 14px; }
    .brand-mark {
      width: 45px; height: 45px; border-radius: 14px;
      color: #143b38;
      background: linear-gradient(145deg, #9ce4d3, #5dc7bd);
      box-shadow: 0 6px 18px rgba(36,186,166,.17), inset 0 1px 0 rgba(255,255,255,.55);
    }
    .brand strong { font-size: 17px; font-weight: 700; letter-spacing: .03em; }
    .brand small { margin-top: 4px; color: #a9c7c6; font-size: 11px; letter-spacing: .11em; }
    .status { font-size: 12px; color: #c6dbd8; }
    .status-dot { width: 7px; height: 7px; background: #6ee2b8; box-shadow: 0 0 0 4px rgba(110,226,184,.12); }
    .btn {
      min-height: 42px; border-radius: 11px; padding: 0 16px;
      font-size: 12px; font-weight: 650;
      transition: color .18s ease, background-color .18s ease, border-color .18s ease, box-shadow .18s ease, transform .18s ease;
    }
    .btn:hover { box-shadow: 0 6px 17px rgba(23,80,72,.1); }
    .btn-primary {
      color: #fff; border-color: #176963;
      background: linear-gradient(135deg, #207e76, #175d5c);
      box-shadow: 0 8px 17px rgba(29,111,105,.17);
    }
    .btn-primary:hover { color: #fff; border-color: #155f5c; background: linear-gradient(135deg, #278c80, #176560); box-shadow: 0 10px 22px rgba(29,111,105,.22); }
    .btn-ghost-dark { border-color: rgba(255,255,255,.14); border-radius: 10px; color: #e6f3f0; background: rgba(255,255,255,.06); }
    .btn-ghost-dark:hover { background: rgba(255,255,255,.12); box-shadow: none; }
    .btn.is-loading { cursor: progress; }
    .btn.is-loading::before {
      content: ""; width: 13px; height: 13px; border: 2px solid currentColor;
      border-right-color: transparent; border-radius: 50%; animation: refreshSpin .75s linear infinite;
    }
    button:focus-visible, a:focus-visible, input:focus-visible, select:focus-visible, textarea:focus-visible, .panel:focus-visible {
      outline: 3px solid rgba(42,155,141,.35); outline-offset: 3px;
    }
    .shell { width: min(1440px, calc(100% - 64px)); margin: 28px auto 64px; grid-template-columns: 278px minmax(0,1fr); gap: 22px; }
    .sidebar, .workspace { border: 1px solid #e5ece8; background: #fff; box-shadow: var(--shadow); }
    .sidebar { top: 104px; padding: 19px 18px 14px; border-radius: 20px; overflow: hidden; }
    .sidebar::before { content: ""; display: block; height: 4px; width: 54px; margin: -19px 0 16px -18px; background: #54b8aa; border-radius: 0 0 8px 0; }
    .account-head { margin: 0 0 13px; gap: 8px; }
    .eyebrow { margin-bottom: 6px; color: #81918f; font-size: 11px; font-weight: 650; letter-spacing: .04em; }
    .account-id { color: #203d3b; font-size: 13px; line-height: 1.45; }
    .account-name { margin-top: 5px; font-size: 11px; line-height: 1.55; }
    .connected { border-color: #cde7de; color: #2d7461; background: #eef9f3; font-weight: 650; }
    .stat-list { gap: 9px; }
    .stat { min-height: 65px; grid-template-columns: 34px 1fr; gap: 11px; padding: 10px 12px; border-color: #e9efeb; border-radius: 12px; background: #f9fbf9; }
    .stat:first-child { border-color: #cee4db; background: #eff8f3; }
    .stat-icon { width: 34px; height: 34px; border-radius: 10px; background: #e0f3eb; }
    .stat strong { margin-top: 3px; font-size: 23px; font-weight: 750; letter-spacing: -.04em; }
    .stat span { font-size: 11px; }
    .safety { margin-top: 23px; padding: 15px 0 0; border-top: 1px solid #edf1ed; }
    .safety p { font-size: 11px; }
    .logout-link { font-size: 11px; }
    .logout-link { margin-top: 8px; min-height: 44px; }
    .workspace { min-width: 0; padding: clamp(18px, 2vw, 26px); border-radius: 24px; overflow: visible; }
    .activation-panel {
      position: relative; isolation: isolate; overflow: hidden;
      grid-template-columns: minmax(0, 1fr) minmax(290px, 1.13fr);
      min-height: 190px; gap: 24px; margin-bottom: 30px; padding: clamp(22px, 2.5vw, 32px);
      border: 1px solid #1a4845; border-radius: 21px;
      background: linear-gradient(118deg, #143637 0%, #1e4b49 58%, #286257 100%);
      box-shadow: 0 18px 31px rgba(22,66,61,.14);
    }
    .activation-panel::after {
      content: ""; position: absolute; z-index: -1; width: 370px; height: 370px; right: 26%; top: -238px;
      border: 1px solid rgba(192,233,208,.13); border-radius: 50%;
      box-shadow: 0 0 0 74px rgba(179,221,197,.035), 0 0 0 148px rgba(179,221,197,.025);
      pointer-events: none;
    }
    .activation-panel.activated {
      grid-template-columns: minmax(0,1fr); min-height: 0; gap: 9px; margin-bottom: 10px; padding: 0 12px;
      border-color: #2c635b; background: linear-gradient(118deg, #153e3d, #20544e 65%, #297062);
      box-shadow: 0 10px 22px rgba(22,66,61,.1);
    }
    .activation-panel.activated .activation-copy .section-kicker { display: none; }
    .activation-panel.activated .activation-copy { display: flex; align-items: center; justify-content: space-between; gap: 10px; }
    .activation-panel.activated .activation-copy h2 { margin: 0; font-size: 13px; }
    .activation-panel.activated .activation-copy p { display: none; }
    .activation-panel.activated .activation-expand { display: inline-flex; align-items: center; justify-content: center; min-height: 44px; padding: 0 12px; border: 1px solid #639588; border-radius: 9px; color: #fff; background: rgba(255,255,255,.08); font-size: 12px; white-space: nowrap; }
    .activation-panel.activated:not(.activation-open) .activation-form { display: none; }
    .activation-panel.activated .activation-form { padding: 0; border: 0; background: transparent; box-shadow: none; }
    .activation-panel.activated .activation-form label { margin-bottom: 5px; color: #d4e8df; font-size: 10px; }
    .activation-panel.activated .activation-controls input { height: 40px; }
    .activation-panel.activated .activation-controls .btn { min-height: 40px; }
    .activation-panel.activated .activation-tools { min-height: 0; margin-top: 4px; }
    .activation-panel.activated .activation-visibility { color: #d0eade; }
    .activation-panel.activated .activation-error { color: #ffd6cb; }
    body:not(.is-activated) .sidebar .stat-list { display: none; }
    body.is-switching .sidebar, body.is-switching .panel-stage { visibility: hidden; }
    body.is-switching .tabs { pointer-events: none; opacity: .5; }
    .switch-notice {
      display: flex; align-items: center; gap: 11px; margin: -12px 0 23px; padding: 14px 16px;
      border: 1px solid #cbe6d8; border-radius: 11px; color: #226d5e; background: #edf8f1;
      font-size: 12px; font-weight: 650;
    }
    .switch-spinner { width: 16px; height: 16px; border: 2px solid #86bb9f; border-right-color: transparent; border-radius: 50%; animation: refreshSpin .75s linear infinite; }
    .activation-copy .section-kicker { color: #9ae0be; font-size: 11px; letter-spacing: .14em; }
    .activation-copy h2 { margin: 11px 0 9px; color: #fff; font-size: clamp(21px, 2vw, 26px); font-weight: 740; line-height: 1.3; letter-spacing: -.025em; }
    .activation-copy p { max-width: 32em; color: #c0d8d3; font-size: 12px; line-height: 1.85; }
    .activation-form { padding: 17px 18px 10px; border: 1px solid rgba(255,255,255,.4); border-radius: 15px; background: rgba(255,255,255,.96); box-shadow: 0 12px 25px rgba(10,45,42,.13); }
    .activation-form label { margin-bottom: 8px; color: #36514c; font-size: 11px; }
    .activation-controls { gap: 8px; }
    .activation-controls input { height: 46px; border-color: #d6e2dc; border-radius: 10px; background: #fbfdfb; font-size: 12px; }
    .activation-controls input::placeholder { color: #99aaa4; }
    .activation-controls .btn { min-height: 46px; padding-inline: 18px; }
    .activation-visibility { padding: 2px 0; color: #2b786d; }
    .activation-tools { margin-top: 8px; }
    .activation-error { font-size: 11px; }
    .workspace-head { margin-bottom: 23px; align-items: end; }
    .section-kicker { margin-bottom: 7px; color: #278076; font-size: 10px; font-weight: 750; letter-spacing: .1em; }
    .section-kicker span { padding: 0 4px; color: #aec4ba; }
    h1 { color: #1a3533; font-size: clamp(25px, 2.6vw, 34px); font-weight: 750; letter-spacing: -.035em; line-height: 1.2; }
    .workspace-intro { margin: 9px 0 0; color: #758783; font-size: 12px; line-height: 1.6; }
    .workspace-head-actions { gap: 13px; }
    .updated { color: #8b9b94; font-size: 11px; }
    .refresh-status { min-height: 36px; color: #37655d; background: #f4faf6; }
    .tabs {
      position: sticky; isolation: isolate; top: 82px; z-index: 4;
      display: flex; align-items: stretch; gap: 0; padding: 5px; border: 1px solid #cfe4dc; border-radius: 15px; background: #edf5f2;
      scroll-margin-top: 94px;
    }
    .tab-indicator { position: absolute; z-index: 0; inset: 5px auto 5px 5px; width: calc((100% - 10px) / 3); border: 1px solid #b5dccd; border-radius: 10px; background: #fff; box-shadow: 0 2px 7px #145a4512; pointer-events: none; transform: translateX(calc(var(--tab-index,0) * 100%)); transition: transform 220ms cubic-bezier(.22,.8,.3,1), opacity 180ms ease; }
    .tabs[data-active="ledger"] .tab-indicator { opacity: 0; }
    .tab {
      position: relative; z-index: 1; min-width: 0; flex: 1 1 0; height: 44px; padding: 0 12px; border: 0; border-radius: 10px;
      display: inline-flex; align-items: center; justify-content: center; gap: 7px;
      color: #607a72; background: transparent; font-size: 12px; font-weight: 600;
      transition: color 180ms ease;
    }
    .tab:hover { color: #0b6b57; background: transparent; }
    .tab.active { color: #086d55; font-weight: 750; background: transparent; box-shadow: none; }
    .count { padding: 3px 7px; background: #e2f2e8; color: #2a7160; font-size: 10px; font-variant-numeric: tabular-nums; }
    .panel-stage { min-width: 0; scroll-margin-top: calc(var(--site-header-height) + 66px + env(safe-area-inset-top)); }
    .panel { padding-top: 10px; scroll-margin-top: 148px; }
    .form-section, .competitor-lookup, .guide { border-radius: 18px; }
    .submit-layout { grid-template-columns: minmax(0, 1.47fr) minmax(250px, .65fr); gap: 17px; }
    .form-section { padding: 20px; border-color: #e6ece8; background: #fff; }
    .form-section h3, .guide h3, .lookup-head h3 { color: #1b3734; font-size: 16px; font-weight: 750; }
    .form-section h3 { margin-bottom: 12px; }
    .batch-hint { display: block; margin: 5px 0 0; font-size: 11px; line-height: 1.5; }
    .form-group { margin-bottom: 12px; }
    .form-group label, .competitor-lookup label { margin-bottom: 8px; color: #435e57; font-size: 12px; font-weight: 650; }
    textarea, select, .field, .lookup-url-row input { border-color: #dce6df; border-radius: 10px; background: #fbfdfb; }
    textarea { min-height: 186px; padding: 14px; font-size: 13px; line-height: 1.75; }
    textarea:focus, input:focus, select:focus { border-color: #8cc8b5; background: #fff; }
    .mode-control { gap: 8px; border: 0; overflow: visible; }
    .mode-control { grid-template-columns: minmax(0, 1fr); max-width: 320px; }
    .mode-option { min-height: 44px; border: 1px solid #dce7df; border-radius: 11px; background: #fbfdfb; text-align: left; }
    .mode-option:last-child { border-right: 1px solid #dce7df; }
    .mode-option.active { border-color: #44978a; color: #176b5f; background: #eaf6ef; box-shadow: inset 0 0 0 1px #aad9c7; }
    .mode-option.active small { color: #538679; }
    .mode-option:disabled { opacity: .56; cursor: not-allowed; }
    .mode-option strong { font-size: 12px; }
    .mode-option small { font-size: 10px; }
    .cost-hint { color: #6f857c; }
    .cost-hint strong { color: #19685e; font-size: 21px; font-variant-numeric: tabular-nums; }
    .guide { padding: 23px 22px; border-color: #e7eee5; background: linear-gradient(145deg, #f6f9f3, #edf5ee); }
    .guide h3 { margin-bottom: 15px; }
    .batch-lead { margin: 0 0 13px; color: #205f55; font-size: 19px; font-weight: 750; line-height: 1.3; }
    .batch-copy { margin: 0 0 11px; color: #5e7468; font-size: 12px; line-height: 1.8; }
    .batch-copy:last-child { margin-bottom: 0; }
    .guide ol { list-style: decimal; padding-left: 22px; }
    .guide li { min-height: 27px; margin: 0 0 11px; padding-left: 6px; color: #5e7468; font-size: 11px; line-height: 1.7; }
    .guide li::marker { color: #298573; font-weight: 750; }
    .guide-note { margin-top: 16px; border-color: #d6e3d7; color: #537669; }
    .competitor-lookup { padding: clamp(19px, 2vw, 26px); border-color: #e6ece8; }
    .lookup-head { margin-bottom: 19px; }
    .lookup-head h3 { margin-bottom: 6px; }
    .lookup-head p { font-size: 12px; }
    .bridge-state { padding: 6px 10px; font-weight: 650; }
    .lookup-result { border: 1px solid #e0ede7; border-radius: 11px; background: #f3f9f5; }
    .panel-bar { margin-bottom: 16px; }
    .panel-bar h2 { margin-bottom: 6px; font-size: 19px; font-weight: 750; }
    .panel-bar p { font-size: 12px; }
    .task-metrics, .ledger-summary { gap: 10px; margin-bottom: 18px; }
    .task-metrics > div, .ledger-metric { border: 1px solid #e5ece6; border-radius: 13px; background: #f9fbf9; }
    .task-metrics > div { padding: 15px; }
    .task-metrics strong, .ledger-metric strong { font-size: 23px; font-variant-numeric: tabular-nums; }
    .task-metrics span, .ledger-metric span { font-size: 11px; }
    .ledger-metric { padding: 18px; }
    .table-wrap { border-color: #e0e9e3; border-radius: 13px; }
    #resultsPanel table { min-width: 760px; }
    .tag.refunded { color: #98662d; background: #fff3e7; }
    .submitted-at, .batch-cutoff { display: block; line-height: 1.5; }
    .batch-cutoff { margin-top: 3px; color: #70867b; font-size: 10px; white-space: normal; }
    .withdraw-action { padding: 7px 9px; border: 1px solid #cfe5d7; border-radius: 8px; color: #1d6a58; background: #f1f9f3; font-weight: 700; }
    .withdraw-action:hover { border-color: #8bc7a8; color: #155f4c; background: #e5f5e9; }
    th { color: #59736a; background: #f7faf7; font-size: 11px; font-weight: 700; }
    td { color: #435950; }
    tbody tr { transition: background-color .15s ease; }
    tbody tr:hover { background: #f7fbf8; }
    .sku-avatar { color: #257366; background: #e4f3e9; }
    .tag { padding: 5px 9px; border-radius: 7px; }
    .empty { padding: 60px 20px; }
    .toast { border-radius: 12px; box-shadow: 0 14px 34px rgba(15,47,42,.22); }
    @media (max-width: 1100px) {
      .shell { width: min(100% - 32px, 860px); grid-template-columns: minmax(0, 1fr); gap: 14px; }
      body:not(.is-activated) .sidebar { display: none; }
      .sidebar { position: static; display: grid; grid-template-columns: minmax(175px, .8fr) minmax(0, 1.7fr); gap: 7px 17px; padding: 16px 20px; }
      .sidebar::before { display: none; }
      .account-head { grid-column: 1; margin: 0; align-self: center; }
      .stat-list { grid-column: 2; display: grid; grid-template-columns: repeat(3, minmax(0,1fr)); gap: 7px; }
      .stat { min-height: 68px; padding: 10px; grid-template-columns: 1fr; gap: 3px; }
      .stat-icon { display: none; }
      .stat strong { font-size: 20px; }
      .safety { display: none; }
      .logout-link { grid-column: 1; margin: 0; }
      .workspace { min-height: 0; }
      .submit-layout { grid-template-columns: minmax(0, 1.3fr) minmax(200px, .7fr); }
    }
    @media (max-width: 720px) {
      .shell { width: calc(100% - 24px); margin-top: 12px; }
      .workspace { padding: 19px; border-radius: 20px; }
      .activation-panel { grid-template-columns: 1fr; gap: 16px; padding: 23px; margin-bottom: 26px; }
      .activation-panel.activated { gap: 9px; margin-bottom: 15px; padding: 15px 18px; }
      .activation-panel.activated .activation-controls { flex-direction: row; }
      .activation-panel.activated .activation-controls .btn { width: auto; }
      .activation-copy h2 { margin-top: 6px; }
      .activation-form { padding: 14px; }
      .workspace-head { align-items: start; }
      .workspace-head-actions { width: auto; }
      .updated { display: none; }
      .submit-layout { grid-template-columns: 1fr; }
      .tabs { top: 76px; }
    }
    @media (max-width: 540px) {
      .topbar { height: 66px; padding: 0 14px; }
      .brand-mark { width: 38px; height: 38px; border-radius: 11px; }
      .brand strong { font-size: 14px; }
      .shell { width: calc(100% - 18px); }
      .sidebar { grid-template-columns: 1fr; padding: 14px; gap: 8px; }
      .account-head, .stat-list, .logout-link { grid-column: 1; }
      .stat-list { grid-template-columns: repeat(3,minmax(0,1fr)); }
      .stat { min-height: 61px; text-align: center; }
      .stat strong { font-size: 19px; }
      .workspace { padding: 16px 13px; border-radius: 16px; }
      .activation-panel { padding: 18px; border-radius: 16px; }
      .activation-controls { flex-direction: column; }
      .activation-controls .btn { width: 100%; }
      body.is-activated .sidebar { grid-template-columns: repeat(2,minmax(0,1fr)); padding: 11px 14px; gap: 7px; }
      body.is-activated .account-head, body.is-activated .stat-list { grid-column: 1 / -1; }
      body.is-activated .account-head { align-items: center; }
      body.is-activated .account-head .eyebrow, body.is-activated .account-name { display: none; }
      body.is-activated .account-id { font-size: 12px; }
      body.is-activated .connected { font-size: 10px; }
      body.is-activated .stat { min-height: 52px; padding: 6px 4px; }
      body.is-activated .stat strong { font-size: 18px; }
      body.is-activated .stat span { font-size: 10px; }
      body.is-activated .logout-link { grid-column: 1; margin: 0; font-size: 10px; }
      .activation-panel.activated { padding: 13px 14px; gap: 8px; margin-bottom: 13px; }
      .activation-panel.activated .activation-copy h2 { margin-bottom: 2px; font-size: 15px; }
      .activation-panel.activated .activation-copy p { font-size: 10px; line-height: 1.45; }
      .activation-panel.activated .activation-form label { position: absolute; width: 1px; height: 1px; padding: 0; overflow: hidden; clip-path: inset(50%); white-space: nowrap; }
      .activation-panel.activated .activation-controls { flex-direction: row; }
      .activation-panel.activated .activation-controls input { height: 39px; min-width: 0; padding-inline: 9px; font-size: 11px; }
      .activation-panel.activated .activation-controls .btn { width: auto; min-height: 39px; padding: 0 10px; font-size: 11px; }
      .activation-panel.activated .activation-tools { margin-top: 3px; }
      .activation-panel.activated .activation-visibility { font-size: 10px; }
      .workspace-head { margin-bottom: 16px; }
      .workspace-head-actions { width: 100%; justify-content: flex-start; }
      .workspace-intro { font-size: 11px; }
      .tabs { top: 68px; border-radius: 12px; }
      .tab { height: 43px; padding: 0 4px; gap: 5px; font-size: 11px; }
      .tab .icon { width: 15px; height: 15px; }
      .tab .count { display: none; }
      .panel { padding-top: 14px; }
      .form-section, .guide, .competitor-lookup { padding: 17px; border-radius: 14px; }
      .form-group label, .competitor-lookup label { align-items: start; gap: 8px; }
      .form-group label small, .competitor-lookup label small { text-align: right; }
      .task-metrics { grid-template-columns: repeat(2,1fr); }
      .ledger-summary { grid-template-columns: 1fr; }
      .panel-bar { flex-direction: column; }
      .bar-actions { width: 100%; }
      .bar-actions select { flex: 1; }
      .lookup-url-row { flex-direction: column; }
      .lookup-url-row .btn { width: 100%; }
    }
    /* Customer navigation, live balances and legal notice, October 2026. */
    :root { --site-header-height: 124px; }
    .site-header { position: sticky; top: 0; z-index: 30; padding-top: env(safe-area-inset-top); box-shadow: 0 5px 22px rgba(16,43,46,.08); }
    .site-header .topbar { position: relative; top: auto; box-shadow: none; }
    .legal-banner { height: 48px; display: flex; align-items: center; gap: 15px; padding: 0 clamp(16px,3.7vw,64px); border-bottom: 1px solid #f0e1c4; background: #fff8eb; color: #85622b; }
    .legal-label { flex: 0 0 auto; display: flex; align-items: center; gap: 7px; font-size: 12px; font-weight: 750; }
    .legal-label .icon { width: 16px; height: 16px; color: #af792f; }
    .legal-window { min-width: 0; flex: 1; overflow: hidden; mask-image: linear-gradient(90deg,transparent,#000 12px,#000 calc(100% - 12px),transparent); }
    .legal-track { display: flex; width: max-content; animation: legalScroll 155s linear infinite; }
    .legal-track span { flex: 0 0 auto; padding-right: 90px; white-space: nowrap; font-size: 12px; line-height: 1.7; }
    @keyframes legalScroll { to { transform: translateX(-50%); } }
    .legal-banner:hover .legal-track, .legal-banner:focus-within .legal-track, .legal-banner.is-paused .legal-track { animation-play-state: paused; }
    .legal-pause, .legal-open { flex: 0 0 auto; border: 0; border-radius: 7px; color: #77582c; background: transparent; min-height: 32px; }
    .legal-pause { width: 30px; font-size: 14px; }
    .legal-open { padding: 0 10px; font-size: 11px; font-weight: 650; background: #f6ead4; }
    .legal-pause:hover, .legal-open:hover { background: #f0dfbd; }
    .shell { grid-template-areas: "account navigation" "account content"; row-gap: 14px; align-items: start; }
    .shell > .tabs { grid-area: navigation; top: calc(var(--site-header-height) + env(safe-area-inset-top)); margin: 0; z-index: 20; box-shadow: 0 5px 18px rgba(28,67,56,.07); }
    .shell > .sidebar { grid-area: account; top: calc(var(--site-header-height) + 14px + env(safe-area-inset-top)); }
    .shell > .workspace { grid-area: content; }
    .workspace-head { margin-bottom: 10px; }
    body.is-activated .workspace-head { align-items: center; }
    body.is-activated .workspace-head .section-kicker { display: none; }
    body.is-activated .workspace-head h1 { font-size: 24px; line-height: 1.25; }
    body.is-activated .workspace-intro { margin-top: 3px; font-size: 11px; line-height: 1.5; }
    .workspace-intro { max-width: 55ch; }
    .balance-sync { margin: 12px 0 0; color: #66827b; font-size: 10px; display: flex; align-items: center; gap: 6px; line-height: 1.5; }
    .balance-sync::before { content: ""; flex: 0 0 auto; width: 5px; height: 5px; border-radius: 50%; background: #49a88c; }
    .stat strong, .ledger-metric strong { font-variant-numeric: tabular-nums; }
    .activation-expand { display: none; }
    .table-wrap { overscroll-behavior-x: contain; }
    .legal-dialog { padding: 0; width: min(570px,calc(100% - 32px)); max-height: min(82dvh,740px); border: 1px solid #ece4d7; border-radius: 22px; color: #203d39; background: #fffefb; box-shadow: 0 30px 80px rgba(10,35,31,.24); }
    .legal-dialog::backdrop { background: rgba(10,32,30,.48); backdrop-filter: blur(4px); }
    .legal-dialog-head { padding: 24px 26px 20px; display: flex; align-items: center; gap: 13px; border-bottom: 1px solid #f0e9dd; }
    .legal-dialog-icon { display: grid; place-items: center; width: 44px; height: 44px; border-radius: 13px; background: #fff0d6; color: #b47a2c; }
    .legal-dialog-head h2 { margin: 4px 0 0; font-size: 21px; }
    .legal-dialog-head .section-kicker { margin: 0; color: #9b835f; font-size: 10px; }
    .legal-close { margin-left: auto; flex: 0 0 auto; width: 36px; height: 36px; border: 0; border-radius: 10px; color: #7d8278; background: #f2f2ec; font-size: 25px; }
    .legal-body { padding: 4px 26px 14px; font-size: 13px; line-height: 1.95; }
    .legal-body p { margin: 17px 0 0; }
    .legal-body p:first-child strong { color: #ab6337; }
    .legal-dialog-foot { padding: 16px 26px 22px; color: #929184; background: #faf8f1; font-size: 11px; line-height: 1.7; }
    .legal-dialog-foot div { margin-top: 7px; display: flex; gap: 17px; }
    .legal-dialog-foot a { color: #617e6f; text-decoration: underline; text-underline-offset: 3px; }
    @media (max-width:1100px) {
      .shell { grid-template-areas: "navigation" "account" "content"; margin-top: 12px; }
      .balance-sync { grid-column: 1 / -1; margin-top: 1px; justify-content: flex-end; }
      .shell > .sidebar { top: auto; }
    }
    @media (max-width:620px) {
      :root { --site-header-height: 110px; }
      .legal-banner { height: 44px; padding: 0 12px; gap: 7px; }
      .legal-label { gap: 4px; font-size: 10px; }
      .legal-label .icon { width: 14px; height: 14px; }
      .legal-track span { font-size: 11px; }
      .legal-open { padding: 0 7px; min-height: 28px; font-size: 10px; }
      .legal-open span { display: none; }
      .legal-pause { min-height: 28px; width: 22px; }
      .shell { width: calc(100% - 20px); gap: 10px; margin-top: 10px; }
      .shell > .tabs { border-radius: 13px; }
      .tab { height: 44px; font-size: 12px; gap: 5px; }
      .tab .count { display: inline-flex; padding: 1px 5px; font-size: 9px; min-width: 17px; }
      .shell > .sidebar { padding: 10px 12px; border-radius: 16px; grid-template-columns: minmax(0,1fr) auto; gap: 7px 10px; }
      body.is-activated .shell > .sidebar { grid-template-columns: minmax(0,1fr) auto; }
      .account-head, body.is-activated .account-head { grid-column: 1; display: flex; align-items: center; margin: 0; min-height: 28px; }
      .account-id { font-size: 12px; }
      .account-name, .eyebrow { display: none; }
      .account-head .connected { margin-left: auto; font-size: 10px; }
      .stat-list, body.is-activated .stat-list { grid-column: 1 / -1; grid-row: auto; grid-template-columns: repeat(3,minmax(0,1fr)); gap: 6px; }
      .stat, body.is-activated .stat { min-height: 56px; padding: 6px 8px; border: 1px solid #e8efea; background: #f8fbf8; border-radius: 10px; }
      .stat strong, body.is-activated .stat strong { font-size: 21px; line-height: 1.2; }
      .stat span, body.is-activated .stat span { font-size: 10px; }
      .stat:first-child { background: #eff8f2; border-color: #dceddf; }
      .balance-sync { grid-column: 1 / -1; justify-content: flex-start; font-size: 9px; margin: -1px 0 0; }
      .logout-link, body.is-activated .logout-link { position: static; grid-column: 2; grid-row: 1; justify-self: end; margin: -8px -4px -8px 0; min-height: 44px; padding: 0 4px; font-size: 9px; }
      .shell > .sidebar { position: relative; }
      .workspace { padding: 15px 13px; }
      .workspace-head h1 { font-size: 21px; }
      .workspace-head { gap: 8px; margin-bottom: 9px; }
      .workspace-head-actions { display: flex; width: 100%; align-items: center; justify-content: space-between; }
      .workspace-head .section-kicker { font-size: 10px; }
      .activation-panel.activated .activation-copy p { display: none; }
      .activation-panel.activated .activation-copy h2 { font-size: 13px; }
      .activation-panel.activated { padding: 4px 10px; margin-bottom: 10px; }
      .activation-panel.activated .activation-copy { display: flex; align-items: center; justify-content: space-between; gap: 8px; }
      .activation-panel.activated .activation-copy h2 { margin: 0; color: #d0e8dd; font-size: 11px; font-weight: 500; }
      .activation-panel.activated .activation-expand { padding: 0 9px; font-size: 11px; }
      body.is-activated .workspace-head .section-kicker { display: none; }
      body.is-activated .workspace-head { display: grid; grid-template-columns: 1fr auto; align-items: center; }
      body.is-activated .workspace-head-actions { width: auto; }
      body.is-activated .workspace-head h1 { font-size: 18px; }
      body.is-activated .workspace-intro { max-width: 22em; margin-top: 5px; font-size: 10px; }
      .task-metrics { grid-template-columns: repeat(4,minmax(0,1fr)); gap: 6px; }
      .task-metrics > div { padding: 11px 8px; min-height: 66px; flex-direction: column; align-items: flex-start; gap: 4px; }
      .task-metrics span { font-size: 10px; }
      .panel { padding-top: 8px; scroll-margin-top: 174px; }
      .form-section, .guide, .competitor-lookup { padding: 15px; }
      textarea { font-size: 14px; }
      .activation-controls input { font-size: 16px; }
      .activation-panel.activated .activation-controls input { font-size: 16px; }
      .legal-dialog { border-radius: 18px; }
      .legal-dialog-head { padding: 20px 18px 16px; }
      .legal-body { padding: 0 18px 16px; font-size: 12px; }
      .legal-dialog-foot { padding: 14px 18px 18px; }
      #resultsPanel table, #ledgerPanel table { display: block; min-width: 0; width: 100%; border-collapse: separate; }
      #resultsPanel thead, #ledgerPanel thead { display: none; }
      #resultsBody, #ledgerBody { display: grid; gap: 10px; }
      #resultsBody tr, #ledgerBody tr { display: grid; grid-template-columns: minmax(0,1fr) auto; column-gap: 9px; row-gap: 8px; padding: 14px; border: 1px solid #e3ece5; border-radius: 14px; background: #fff; }
      #resultsBody td, #ledgerBody td { border: 0; padding: 0; min-width: 0; width: auto; font-size: 11px; line-height: 1.65; }
      #resultsBody td:first-child { grid-column: 1 / -1; }
      #resultsBody td:nth-child(3), #resultsBody td:last-child { justify-self: end; text-align: right; }
      #resultsBody td:nth-child(4) { color: #819389; font-size: 10px; }
      #resultsBody td:last-child { align-self: end; }
      #resultsBody .sku-avatar { width: 32px; height: 32px; font-size: 9px; border-radius: 9px; }
      #resultsBody .sku-code { font-size: 13px; }
      #resultsBody .sku-name { font-size: 10px; }
      #resultsBody .batch-cutoff { white-space: normal; line-height: 1.6; }
      #resultsBody .withdraw-action { min-height: 32px; padding: 0 9px; border: 1px solid #d9e7df; border-radius: 8px; background: #f3f8f4; font-size: 10px; white-space: nowrap; }
      #resultsBody .withdraw-action .icon { width: 12px; height: 12px; }
      #ledgerBody td:first-child { font-size: 10px; color: #89998f; }
      #ledgerBody td:nth-child(2) { justify-self: end; color: #668477; font-size: 10px; }
      #ledgerBody td:nth-child(3) { grid-column: 1 / -1; padding-top: 2px; }
      #ledgerBody td:nth-child(4) { font-size: 15px; font-weight: 700; }
      #ledgerBody td:last-child { grid-column: 1 / -1; color: #85978c; font-size: 10px; padding-top: 7px; border-top: 1px solid #eef2ed; }
      #resultsPanel .table-wrap, #ledgerPanel .table-wrap { padding: 0; border: 0; border-radius: 0; background: transparent; }
    }
    @media (max-width:360px) {
      .tab { font-size: 11px; gap: 3px; }
      .tab .icon { width: 13px; height: 13px; }
      .balance-sync { font-size: 8px; }
    }
    @media (prefers-reduced-motion: reduce) {
      .legal-track { animation: none; }
      html { scroll-behavior: auto; }
      *, *::before, *::after { animation-duration: .01ms !important; animation-iteration-count: 1 !important; transition-duration: .01ms !important; scroll-behavior: auto !important; }
    }

    /* Lightweight customer accents and manually refreshed account views. */
    .brand-mark { overflow: hidden; padding: 0; border: 0; background: transparent; box-shadow: 0 4px 12px rgba(31,111,88,.11); }
    .brand-mark img { display: block; width: 100%; height: 100%; object-fit: contain; }
    .shell > .tabs { scroll-margin-top: calc(var(--site-header-height) + 10px); }
    .competitor-lookup, .panel { scroll-margin-top: calc(var(--site-header-height) + 70px); }
    .legal-banner { background: #fff3dd; border-bottom-color: #ebcf9b; box-shadow: inset 4px 0 #d78920; color: #744818; }
    .legal-label { color: #92500e; }
    .legal-subtitle { font-size: 11px; }
    .legal-label .icon { color: #cc7412; }
    .activation-panel { position: relative; isolation: isolate; }
    .activation-panel::before { content: ""; position: absolute; inset: 0; z-index: -1; pointer-events: none; border-radius: inherit; background: linear-gradient(112deg,transparent 30%,rgba(118,224,229,.13) 45%,rgba(255,255,255,.12) 48%,transparent 60%); transform: translateX(-115%); animation: accountSheen 12s ease-in-out infinite; }
    @keyframes accountSheen { 0%, 50% { transform: translateX(-115%); opacity: 0; } 58% { opacity: .8; } 82% { transform: translateX(115%); opacity: 0; } 100% { transform: translateX(115%); opacity: 0; } }
    .batch-countdown { margin: 15px 0; padding: 14px 16px; border: 1px solid #d4e8e4; border-radius: 13px; background: rgba(255,255,255,.82); }
    .batch-countdown span, .batch-countdown small { display: block; color: #67807a; font-size: 11px; }
    .batch-countdown strong { display: block; margin: 5px 0 6px; color: #137b77; font-family: ui-monospace, Consolas, monospace; font-size: 27px; font-variant-numeric: tabular-nums; letter-spacing: .06em; }
    .pagination { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-top: 14px; color: #71867f; font-size: 11px; }
    .pagination > div { display: flex; gap: 7px; }
    .pagination .btn { min-height: 34px; padding-inline: 12px; }
    body.has-announcement { --site-header-height: 164px; }
    .announcement-banner { height: 40px; padding: 0 clamp(16px,3.7vw,64px); display: flex; align-items: center; gap: 14px; border-bottom: 1px solid #d5e7ff; color: #345b86; background: #edf5ff; }
    .announcement-label { flex: 0 0 auto; display: flex; gap: 7px; align-items: center; color: #1766c8; font-size: 12px; font-weight: 700; }
    .announcement-label .icon { width: 16px; height: 16px; }
    .announcement-window { flex: 1; min-width: 0; overflow: hidden; }
    .announcement-track { display: flex; width: max-content; animation: legalScroll 60s linear infinite; }
    .announcement-track span { padding-right: 90px; white-space: nowrap; font-size: 12px; }
    .announcement-banner:hover .announcement-track, .announcement-banner:focus-within .announcement-track, .announcement-banner.is-paused .announcement-track { animation-play-state: paused; }
    .announcement-pause, .announcement-open { flex: 0 0 auto; border: 0; border-radius: 7px; color: #245c9b; background: transparent; min-height: 28px; font-size: 11px; }
    .announcement-pause { width: 28px; }
    .announcement-open { padding-inline: 9px; background: #dceafe; }
    .announcement-pause:hover, .announcement-open:hover { background: #d1e3fb; }
    .announcement-dialog { background: #fff; }
    .announcement-dialog .legal-dialog-icon { color: #005bff; background: #edf4ff; }
    .announcement-body { padding: 22px 26px 26px; white-space: pre-wrap; overflow-wrap: anywhere; font-size: 13px; line-height: 1.9; }
    @media (max-width:620px) {
      body.has-announcement { --site-header-height: 146px; }
      .legal-subtitle { display: none; }
      .legal-label { font-weight: 800; }
      .announcement-banner { height: 36px; padding-inline: 12px; gap: 7px; }
      .announcement-label, .announcement-track span { font-size: 11px; }
      .announcement-open { padding-inline: 7px; font-size: 10px; }
      .announcement-pause { width: 22px; }
      .announcement-body { padding: 18px; }
      .batch-countdown { padding: 12px 14px; }
      .batch-countdown strong { font-size: 25px; }
      .pagination { gap: 7px; font-size: 10px; }
      .pagination .btn { min-height: 34px; padding-inline: 9px; font-size: 11px; }
    }
    @media (prefers-reduced-motion: reduce) {
      .activation-panel::before { animation: none !important; opacity: 0; }
      .announcement-track { animation: none; }
    }

    /* Invitation rewards stay beside the current account without obscuring task navigation. */
    .referral-card { grid-column: 1 / -1; margin-top: 12px; padding: 0 11px; border: 1px solid #cee6d9; border-radius: 13px; background: linear-gradient(135deg,#eff9f2,#f8fcf9); }
    .referral-card-head { display: flex; align-items: center; gap: 7px; min-height: 44px; cursor: pointer; list-style: none; }
    .referral-card-head::-webkit-details-marker { display: none; }
    .referral-card-head:focus-visible { outline: 3px solid #087f7233; outline-offset: 2px; border-radius: 7px; }
    .referral-chevron { flex: 0 0 auto; color: #368473; transition: transform 180ms ease; }
    .referral-disclosure[open] .referral-chevron { transform: rotate(180deg); }
    .referral-details-body { padding-bottom: 9px; }
    .referral-gift { display: inline-grid; place-items: center; flex: 0 0 auto; width: 29px; height: 29px; border: 1px solid #c8e5d8; border-radius: 9px; color: #247562; background: #ddf2e5; }
    .referral-gift .icon { width: 16px; height: 16px; }
    .referral-card h3 { margin: 0; color: #2e5b4c; font-size: 12px; }
    .referral-earned { margin-left: auto; color: #618476; font-size: 10px; white-space: nowrap; }
    .referral-code-row { display: flex; align-items: center; justify-content: space-between; gap: 8px; padding: 13px 0 7px; }
    .referral-code-row > strong { min-width: 0; color: #185d4c; font-family: ui-monospace,Consolas,monospace; font-size: 16px; letter-spacing: .035em; overflow-wrap: anywhere; user-select: all; }
    .referral-copy { display: inline-flex; align-items: center; gap: 4px; flex: 0 0 auto; min-height: 44px; padding: 0 9px; border: 1px solid #c5dfd2; border-radius: 8px; color: #33745c; background: #fff; font-size: 11px; }
    .referral-copy .icon { width: 12px; height: 12px; }
    .referral-copy:disabled { opacity: .45; cursor: not-allowed; }
    .referral-card-note { margin: 3px 0 12px; color: #648273; font-size: 10px; line-height: 1.7; }
    .referral-card-actions { display: flex; gap: 12px; justify-content: space-between; border-top: 1px solid #dcece1; padding-top: 2px; }
    .referral-card-actions button { padding: 2px 0; min-height: 44px; border: 0; color: #367560; background: transparent; font-size: 11px; text-align: left; }
    .referral-card-actions button:hover { color: #134f3d; }
    .referral-dialog { width: min(560px,calc(100% - 28px)); max-height: min(86dvh,800px); padding: 0; overflow-y: auto; border: 1px solid #d8e9df; border-radius: 22px; color: #264d40; background: #fff; box-shadow: 0 30px 80px rgba(14,53,38,.22); }
    .referral-dialog::backdrop { background: rgba(10,32,30,.46); backdrop-filter: blur(4px); }
    .referral-dialog-head { display: flex; align-items: center; gap: 12px; padding: 23px 26px 20px; border-bottom: 1px solid #e1ede5; background: linear-gradient(125deg,#f1f9f3,#fff); }
    .referral-dialog-head .referral-gift { width: 42px; height: 42px; border-radius: 13px; }
    .referral-dialog-head .referral-gift .icon { width: 22px; height: 22px; }
    .referral-dialog-head .section-kicker { color: #6b9580; font-size: 10px; }
    .referral-dialog-head h2 { margin: 5px 0 0; color: #24523f; font-size: 20px; }
    .referral-dialog-body { padding: 19px 26px 25px; }
    .referral-rule { margin: 0 0 17px; color: #6a8274; font-size: 12px; line-height: 1.9; }
    .referral-tiers { display: grid; gap: 6px; margin-bottom: 17px; }
    .referral-tier { display: flex; align-items: center; justify-content: space-between; gap: 10px; padding: 9px 11px; border: 1px solid #e4eee7; border-radius: 9px; color: #789381; background: #fbfdfb; font-size: 11px; }
    .referral-tier.qualified { border-color: #b8dcc8; color: #3c7656; background: #f0f9f2; }
    .referral-tier > span { display: flex; flex-wrap: wrap; align-items: center; gap: 6px; }
    .referral-tier small { padding: 2px 5px; border-radius: 5px; color: #2a8054; background: #dcefe2; font-size: 9px; }
    .referral-tier > strong { color: #3e7856; font-size: 11px; font-weight: 650; white-space: nowrap; }
    .referral-form { padding: 15px; border: 1px solid #d9e9dc; border-radius: 13px; background: #f7fbf7; }
    .referral-form label { display: block; margin-bottom: 8px; color: #3e6652; font-size: 12px; font-weight: 700; }
    .referral-input-row { display: flex; gap: 8px; }
    .referral-input-row input { min-width: 0; flex: 1; height: 43px; padding: 0 11px; border: 1px solid #cfe1d5; border-radius: 9px; color: #285641; background: #fff; font-size: 13px; }
    .referral-input-row .btn { min-height: 43px; flex: 0 0 auto; padding-inline: 13px; }
    .referral-form small { display: block; margin-top: 8px; color: #809587; font-size: 10px; line-height: 1.6; }
    .referral-used { margin: 0; padding: 13px 15px; border: 1px solid #d3e8d9; border-radius: 11px; color: #3d7b55; background: #f0f9f2; font-size: 12px; line-height: 1.8; overflow-wrap: anywhere; }
    .referral-error { min-height: 18px; margin: 7px 0 0; color: #b95b42; font-size: 11px; line-height: 1.65; }
    .referral-history-head { display: flex; align-items: center; justify-content: space-between; gap: 10px; margin: 17px 0 12px; }
    .referral-history-head h3 { margin: 0; font-size: 13px; }
    .referral-history-head > span { color: #749583; font-size: 11px; }
    .referral-history-row { display: flex; align-items: center; justify-content: space-between; gap: 15px; padding: 13px 0; border-bottom: 1px solid #ebf1ec; }
    .referral-history-row > div { display: grid; gap: 5px; min-width: 0; }
    .referral-history-row strong { color: #406853; font-size: 12px; font-weight: 650; }
    .referral-history-row span { color: #789183; font-size: 11px; overflow-wrap: anywhere; }
    .referral-history-row small { color: #9aaca0; font-size: 10px; }
    .referral-history-row b { flex: 0 0 auto; color: #25815b; font-size: 16px; font-variant-numeric: tabular-nums; }
    .referral-history-empty { margin: 0; padding: 24px 0 13px; color: #92a698; font-size: 12px; text-align: center; }
    .referral-pagination { display: flex; align-items: center; justify-content: space-between; gap: 10px; margin-top: 14px; color: #7f9787; font-size: 10px; }
    .referral-pagination > div { display: flex; gap: 5px; }
    .referral-pagination .btn { min-height: 32px; padding-inline: 9px; font-size: 10px; }
    @media (max-width:1100px) {
      .referral-card { margin-top: 2px; }
      .referral-code-row { padding-top: 9px; }
    }
    @media (max-width:620px) {
      .referral-card { padding: 0 10px; border-radius: 11px; margin-top: 0; }
      .referral-card-head .referral-gift { width: 24px; height: 24px; border-radius: 7px; }
      .referral-card h3 { font-size: 11px; }
      .referral-code-row > strong { font-size: 17px; }
      .referral-card-note { margin-bottom: 8px; }
      .referral-card-actions { padding-top: 2px; }
      .referral-dialog { border-radius: 18px; }
      .referral-dialog-head { padding: 18px; gap: 9px; }
      .referral-dialog-head h2 { font-size: 18px; }
      .referral-dialog-body { padding: 17px 18px 21px; }
      .referral-form { padding: 12px; }
      .referral-input-row input { font-size: 16px; padding-inline: 9px; }
      .referral-input-row .btn { font-size: 11px; padding-inline: 10px; }
    }

    /* Clear white surfaces, cool emerald accents and restrained light sweeps. */
    :root {
      --ink: #173c40;
      --muted: #5f737c;
      --teal-950: #073f3d;
      --teal-900: #08534e;
      --teal-700: #087f72;
      --teal-600: #0e9383;
      --teal-300: #74dcc7;
      --teal-100: #d9f5ed;
      --teal-50: #edf9f5;
      --line: #dbe6eb;
      --surface: #fff;
      --page: #f5f9fb;
      --amber: #96610e;
      --amber-bg: #fff6e4;
      --shadow: 0 8px 28px rgba(21,67,74,.055), 0 1px 2px rgba(21,67,74,.025);
    }
    body { background: radial-gradient(ellipse 85% 340px at 50% 0, #e4f3f1 0, transparent 100%), var(--page); }
    .topbar { background: linear-gradient(110deg,#073b3d,#09574f 72%,#126a5f); }
    .brand strong { letter-spacing: .015em; }
    .brand small { color: #c0e2dc; letter-spacing: .08em; }
    .brand-mark { border-radius: 12px; box-shadow: 0 3px 8px #052b3420; }
    .sidebar, .workspace { border-color: #dfe9ed; background: #fff; }
    .sidebar::before { width: 54px; background: #2ab89a; }
    .account-id, h1, .form-section h3, .guide h3, .lookup-head h3 { color: #173e41; }
    .eyebrow, .account-name, .workspace-intro, .updated, .balance-sync { color: #5f737c; }
    .connected { border-color: #b7e5d5; color: #086b53; background: #eaf9f1; }
    .stat, .task-metrics > div, .ledger-metric { background: #f8fbfd; border-color: #dfe9ee; }
    .stat:first-child { background: #ecfaf4; border-color: #bce6d5; }
    .stat:first-child strong { color: #076b54; }
    .stat:first-child .stat-icon { color: #077f65; background: #d1f2e4; }
    .stat:nth-child(2) { background: #fffaf0; border-color: #efdfbb; }
    .stat:nth-child(2) strong { color: #855514; }
    .stat:nth-child(2) .stat-icon { color: #946117; background: #fff0cb; }
    .stat:nth-child(3) { background: #f2f7fe; border-color: #d4e4f5; }
    .stat:nth-child(3) strong { color: #2b5d92; }
    .stat:nth-child(3) .stat-icon { color: #366b9d; background: #e0edfc; }
    .stat span, .task-metrics span, .ledger-metric span { color: #586f78; }
    .stat strong, .task-metrics strong, .ledger-metric strong { letter-spacing: -.025em; }
    .balance-sync::before { background: #1aa582; }
    .safety { border-color: #e2ebee; }
    .safety .icon { color: #0e8874; }
    .logout-link { color: #5a727a; }
    .shell > .tabs { border-color: #cfe4dc; background: #edf5f2; box-shadow: 0 4px 14px #1e56610d; }
    .tab .count { color: #367a67; background: #dceee6; }
    .tab.active .count { color: #076c51; background: #d4f1e3; }
    .account-ledger-link { width: 100%; display: flex; align-items: center; gap: 10px; min-height: 58px; margin-top: 12px; padding: 9px 12px; border: 1px solid #eadfc8; border-radius: 12px; color: #855c21; background: #fffbf2; text-align: left; transition: border-color 180ms ease, background-color 180ms ease; }
    .account-ledger-link > .icon { width: 21px; height: 21px; }
    .account-ledger-copy { display: grid; gap: 3px; min-width: 0; }
    .account-ledger-copy strong { font-size: 12px; font-weight: 700; }
    .account-ledger-copy small { color: #8b795d; font-size: 10px; }
    .account-ledger-link > span:last-child { margin-left: auto; }
    .account-ledger-link:hover, .account-ledger-link[aria-expanded="true"] { border-color: #d9bd82; color: #76501a; background: #fff3d7; }
    .lookup-mobile-notice { padding: 26px 22px; border: 1px solid #cfe2e9; border-radius: 17px; background: linear-gradient(130deg,#edf8f5,#f5f9fd); color: #355b61; text-align: center; }
    .lookup-mobile-notice > .icon { width: 38px; height: 38px; color: #208478; margin-bottom: 8px; }
    .lookup-mobile-notice h2, .lookup-mobile-notice h3 { margin: 4px 0 9px; color: #164f4d; font-size: 17px; }
    .lookup-mobile-notice p { margin: 0; font-size: 13px; line-height: 1.85; }
    .lookup-mobile-notice .btn { min-height: 44px; margin-top: 17px; }
    body:not(.is-mobile-lookup) .lookup-mobile-notice { display: none; }
    body.is-mobile-lookup .lookup-desktop-content { display: none; }
    .lookup-desktop-content { min-width: 0; }
    .lookup-desktop-guide { display: flex; align-items: center; justify-content: space-between; gap: 10px 16px; margin-bottom: 14px; padding: 10px 12px; border: 1px solid #d0e7dd; border-radius: 11px; background: #f1faf6; }
    .lookup-desktop-guide > div { min-width: 0; }
    .lookup-desktop-guide strong { color: #166958; font-size: 12px; }
    .lookup-desktop-guide p { margin: 4px 0 0; color: #53776e; font-size: 11px; line-height: 1.55; }
    .lookup-desktop-guide .btn { min-height: 44px; flex: 0 0 auto; white-space: nowrap; }
    .btn { transition-duration: 180ms; }
    .btn:hover { border-color: #b5d8d6; background: #f2faf8; box-shadow: 0 3px 9px #16505b10; }
    .btn-primary { position: relative; isolation: isolate; overflow: hidden; color: #fff; border-color: #08766a; background: linear-gradient(110deg,#078574,#086b64); box-shadow: 0 5px 13px #0785742b; }
    .btn-primary:hover { color: #fff; border-color: #065f56; background: linear-gradient(110deg,#087f70,#075f59); box-shadow: 0 6px 16px #07857433; }
    .btn-primary:disabled:hover { color: #fff; background: #087f72; border-color: #087f72; }
    .btn-primary::after { content: ""; position: absolute; z-index: -1; inset: -60% -35%; pointer-events: none; background: linear-gradient(112deg,transparent 36%,rgba(203,255,242,.14) 44%,rgba(255,255,255,.28) 49%,rgba(203,255,242,.12) 54%,transparent 64%); opacity: 0; transform: translate3d(-85%,0,0); animation: actionLightSweep 10s ease-in-out infinite; }
    .btn-primary:disabled::after { animation: none; opacity: 0; }
    @keyframes actionLightSweep { 0%,62% { opacity: 0; transform: translate3d(-85%,0,0); } 68% { opacity: 1; } 89% { opacity: .7; } 94%,100% { opacity: 0; transform: translate3d(85%,0,0); } }
    .btn-ghost-dark { background: #ffffff0d; border-color: #ffffff30; color: #e6f6f1; }
    .btn-ghost-dark:hover { color: #fff; background: #ffffff20; border-color: #ffffff50; }
    .refresh-status { color: #096e63; background: #eef9f6; border-color: #cae5df; }
    .activation-panel, .activation-panel.activated { border-color: #0b5f54; background: linear-gradient(112deg,#094946,#0d6458 62%,#147a65); box-shadow: 0 9px 22px #0a5a4f18; }
    .activation-panel::after { right: -150px; top: -200px; border-color: #b5ffdf24; box-shadow: 0 0 0 64px #b5ffdf07,0 0 0 128px #b5ffdf04; }
    .activation-panel::before { display: block; inset: -45% -25%; z-index: -1; pointer-events: none; opacity: 0; background: linear-gradient(113deg,transparent 32%,rgba(115,246,215,.11) 43%,rgba(237,255,249,.25) 49%,rgba(115,246,215,.10) 54%,transparent 65%); transform: translate3d(-85%,0,0); animation: workspaceLightSweep 12s ease-in-out infinite; transition: none; }
    .activation-panel:hover::before, .activation-panel:focus-within::before { opacity: unset; }
    @keyframes workspaceLightSweep { 0%,48% { opacity: 0; transform: translate3d(-85%,0,0); } 55% { opacity: 1; } 77% { opacity: .8; } 88%,100% { opacity: 0; transform: translate3d(85%,0,0); } }
    .activation-copy .section-kicker { color: #acf2d5; }
    .activation-copy p { color: #d3ede4; }
    .activation-panel.activated .activation-form label, .activation-panel.activated .activation-visibility { color: #d7f2e7; }
    .activation-controls input { color: #173e41; background: #fff; border-color: #d5e7e1; }
    .activation-controls input::placeholder { color: #687f80; }
    .activation-panel.activated .activation-expand { border-color: #b4dfd570; background: #ffffff12; }
    .mode-option.active { border-color: #8bd2b9; color: #086b53; background: #e6f8ed; box-shadow: inset 0 0 0 1px #c5ebd9; }
    .mode-option.active small { color: #35765e; }
    .form-section { border-color: #d5e8e1; border-top: 3px solid #35b596; }
    .competitor-lookup { border-color: #d9e6f1; border-top: 3px solid #79aee2; background: #fff; }
    .competitor-lookup .lookup-head h3 { color: #245e83; }
    .guide { background: linear-gradient(135deg,#effaf8,#f8fcfb); border-color: #cee8df; }
    .guide h3, .batch-lead { color: #0b6b60; }
    .batch-copy, .guide li, .guide-note { color: #496d6d; }
    .guide-note { border-color: #d5e8e2; }
    .batch-countdown { border-color: #bce4d7; background: #fff; }
    .batch-countdown span, .batch-countdown small { color: #526f72; }
    .batch-countdown strong { color: #077865; letter-spacing: .035em; }
    .cost-hint { color: #5d747b; }
    .cost-hint strong { color: #086f5d; }
    .form-group label, .competitor-lookup label { color: #385760; }
    .field-meta, .lookup-head p, .lookup-group-hint, .lookup-result, .bridge-state { color: #526f77; }
    input, select, textarea { transition: border-color 160ms ease, background-color 160ms ease; }
    textarea, select, .field, .lookup-url-row input { background: #fbfdfe; border-color: #d8e5eb; }
    textarea::placeholder, input::placeholder { color: #6d8188; }
    textarea:focus, input:focus, select:focus { border-color: #1ba08a; background: #fff; }
    .table-wrap { border-color: #dbe7ed; }
    th { background: #f1f7fb; color: #426273; }
    td { color: #35515e; }
    tbody tr:hover { background: #f3fafc; }
    .sku-name, .batch-cutoff, .pagination { color: #5f737c; }
    .sku-avatar { background: #def5e9; color: #077762; }
    #resultsPanel .panel-bar h2 { color: #245e9f; }
    #ledgerPanel .panel-bar h2 { color: #855815; }
    .task-metrics > div:nth-child(1) { border-color: #dbe7ee; background: #f8fbfd; }
    .task-metrics > div:nth-child(2) { border-color: #cbdff5; background: #edf5ff; }
    .task-metrics > div:nth-child(2) strong { color: #255f9b; }
    .task-metrics > div:nth-child(3) { border-color: #bde6d6; background: #edfaf3; }
    .task-metrics > div:nth-child(3) strong { color: #086e52; }
    .task-metrics > div:nth-child(4) { border-color: #efdfb8; background: #fff8e9; }
    .task-metrics > div:nth-child(4) strong { color: #875919; }
    .ledger-metric:nth-child(1) { background: #edfaf3; border-color: #bde6d6; }
    .ledger-metric:nth-child(1) strong { color: #087353; }
    .ledger-metric:nth-child(2) { background: #fff8eb; border-color: #efdfbc; }
    .ledger-metric:nth-child(2) strong { color: #875919; }
    .ledger-metric:nth-child(3) { background: #f0f6fe; border-color: #d1e3f7; }
    .ledger-metric:nth-child(3) strong { color: #2a5e95; }
    .tag { color: #086d52; background: #dff6eb; }
    .tag.pending { color: #775510; background: #fff1c8; }
    .tag.refunded { color: #85510f; background: #fff0d7; }
    .withdraw-action { border-color: #bce4d4; color: #087054; background: #eefaF3; }
    .withdraw-action:hover { border-color: #83cdb2; color: #075c45; background: #dcf6e8; }
    .lookup-result { border-color: #d4e8e3; background: #f1faf7; }
    .lookup-low-group { border-color: #c3e8d8; background: #f0faf5; }
    .lookup-low-group .lookup-group-head h4 { color: #096e53; }
    .lookup-high-group { border-color: #cddff6; background: #f3f7fe; }
    .lookup-high-group .lookup-group-head h4 { color: #2b5d9b; }
    .lookup-unknown-group { border-color: #eedfb9; background: #fffaf0; }
    .lookup-unknown-group .lookup-group-head h4 { color: #855815; }
    .referral-card { border-color: #aae0cd; background: linear-gradient(128deg,#e8f8ef,#f3fcf8); }
    .referral-card h3, .referral-code-row > strong { color: #086c54; }
    .referral-gift { color: #087257; border-color: #a3d9c4; background: #cdf0df; }
    .referral-earned, .referral-card-note { color: #4c7468; }
    .referral-copy { border-color: #b8dfce; color: #096e56; }
    .referral-card-actions { border-color: #c7e9da; }
    .referral-card-actions button { color: #0c7055; }
    .referral-dialog-head { background: linear-gradient(125deg,#ecfaf3,#fff); }
    .referral-rule, .referral-tier, .referral-form small, .referral-history-row span, .referral-history-row small, .referral-history-head > span, .referral-history-empty, .referral-pagination { color: #536f70; }
    .referral-tier.qualified, .referral-tier > strong { color: #126b4e; }
    .referral-history-row b { color: #087052; }
    .referral-entry { position: relative; isolation: isolate; overflow: hidden; display: grid; grid-template-columns: 34px minmax(0,1fr) auto; align-items: center; gap: 10px; margin: 0 0 10px; padding: 8px 13px; border: 1px solid #9fdac7; border-radius: 14px; background: linear-gradient(118deg,#effbf5,#fff 60%,#f2f9fc); box-shadow: 0 3px 13px #0995780c,inset 3px 0 #32b996; }
    .referral-entry::before { content: ""; position: absolute; z-index: -1; inset: -65% -35%; pointer-events: none; background: linear-gradient(112deg,transparent 35%,rgba(84,218,179,.07) 44%,rgba(115,230,197,.20) 49%,rgba(84,218,179,.07) 54%,transparent 64%); opacity: 0; transform: translate3d(-85%,0,0); animation: actionLightSweep 11s ease-in-out infinite; animation-delay: -3s; }
    .referral-entry-icon { display: grid; place-items: center; width: 34px; height: 34px; border: 1px solid #aae0c8; border-radius: 10px; color: #087358; background: linear-gradient(140deg,#d9f7e8,#c9f1df); box-shadow: inset 0 1px 0 #ffffffb3; }
    .referral-entry-icon .icon { width: 19px; height: 19px; }
    .referral-entry-copy { min-width: 0; }
    .referral-entry-kicker { display: none; }
    .referral-entry-copy h2 { margin: 0 0 3px; color: #164b43; font-size: 15px; font-weight: 750; line-height: 1.5; }
    .referral-entry-note { margin: 0; color: #4f716f; font-size: 11px; line-height: 1.6; overflow-wrap: anywhere; }
    .referral-entry-open { min-height: 44px; flex: 0 0 auto; border-color: #a8d9c7; color: #086b52; background: #e3f7ec; white-space: nowrap; }
    .referral-entry-open:hover { color: #075d49; border-color: #7fc6ac; background: #d1f1e0; }
    .announcement-banner { color: #275d74; background: #edf7ff; border-color: #cce3f4; }
    .announcement-label { color: #245e9f; }
    .announcement-pause, .announcement-open { color: #245e91; }
    .announcement-open { background: #dceeff; }
    .announcement-pause:hover, .announcement-open:hover { background: #cfe5fb; }
    .announcement-dialog .legal-dialog-icon { color: #245e9f; background: #edf5ff; }
    .legal-banner { background: #fff6e7; border-bottom-color: #eedbb9; color: #76521b; box-shadow: inset 4px 0 #d69429; }
    .legal-label, .legal-label .icon { color: #8a5b15; }
    .legal-pause, .legal-open { color: #7b571c; }
    .legal-open { background: #f6e7ca; }
    .legal-dialog::backdrop, .referral-dialog::backdrop { backdrop-filter: none; background: #12323b61; }
    .legal-dialog[open], .referral-dialog[open] { animation: clearDialogIn 180ms ease-out both; }
    @keyframes clearDialogIn { from { opacity: .5; transform: translateY(5px); } to { opacity: 1; transform: none; } }
    .toast { border-color: #cbe6de; box-shadow: 0 8px 24px #123b4020; }
    @media (hover:none) {
      .btn:hover { transform: none; }
    }
    @media (max-width:620px) {
      .workspace { border-radius: 18px; }
      .lookup-desktop-guide { flex-wrap: wrap; }
      .stat, body.is-activated .stat { border-color: #dce7ec; background: #f8fbfd; }
      .stat:first-child, body.is-activated .stat:first-child { border-color: #bce6d5; background: #ecfaf4; }
      .stat:nth-child(2), body.is-activated .stat:nth-child(2) { border-color: #efdfbb; background: #fffaf0; }
      .stat:nth-child(3), body.is-activated .stat:nth-child(3) { border-color: #d4e4f5; background: #f2f7fe; }
      .activation-panel.activated .activation-copy h2 { color: #d7f2e7; }
      .guide { padding: 17px; }
      .referral-card { border-color: #aae0cd; }
      .account-ledger-link { grid-column: 1 / -1; margin-top: 0; min-height: 44px; padding: 6px 10px; }
      .account-ledger-copy { grid-template-columns: auto minmax(0,1fr); gap: 9px; align-items: center; }
      .account-ledger-copy strong { font-size: 11px; }
      .account-ledger-copy small { font-size: 9px; }
      .referral-entry { grid-template-columns: minmax(0,1fr) auto; gap: 7px; padding: 10px 11px; margin-bottom: 11px; border-radius: 12px; }
      .referral-entry-icon { display: none; }
      .referral-entry-copy h2 { font-size: 12px; margin: 0 0 2px; }
      .referral-entry-note { font-size: 10px; }
      .referral-entry-open { min-height: 44px; padding-inline: 8px; font-size: 11px; }
      #resultsBody tr, #ledgerBody tr { border-color: #dce7ec; }
      #resultsBody td:nth-child(4), #ledgerBody td:first-child, #ledgerBody td:nth-child(2), #ledgerBody td:last-child { color: #5e727a; }
      .form-footer .btn, .lookup-actions .btn { min-height: 44px; }
    }
    @media (prefers-reduced-motion:reduce) {
      .legal-dialog[open], .referral-dialog[open] { animation: none !important; }
      .activation-panel::before, .btn-primary::after, .referral-entry::before { display: none; animation: none !important; }
      .btn, .tab, .tab-indicator, .referral-chevron, .account-ledger-link, input, select, textarea { transition: none !important; }
    }
  
