:root{color-scheme:light;--bg:#f4f7f9;--bg-accent:rgba(37,99,235,.08);--surface:rgba(255,255,255,.92);--surface-solid:#fff;--surface-soft:#f6f8fa;--text:#111827;--muted:#697386;--faint:#96a0b0;--line:#e5eaf0;--line-strong:#d8dee7;--blue:#2563eb;--blue-strong:#1d4ed8;--blue-soft:#eaf1ff;--green:#059669;--green-soft:#e7f8f1;--orange:#d97706;--orange-soft:#fff4df;--red:#dc2626;--red-soft:#fff0f0;--shadow:0 18px 50px rgba(30,41,59,.08),0 2px 8px rgba(30,41,59,.04);--shadow-soft:0 8px 24px rgba(30,41,59,.06)}
:root[data-theme="dark"]{color-scheme:dark;--bg:#0d1117;--bg-accent:rgba(59,130,246,.12);--surface:rgba(23,29,38,.92);--surface-solid:#171d26;--surface-soft:#202733;--text:#f3f6fa;--muted:#a6b0bf;--faint:#7d8898;--line:#2a3340;--line-strong:#384354;--blue:#6ea8fe;--blue-strong:#4d8df7;--blue-soft:#1d2d49;--green:#34d399;--green-soft:#153a31;--orange:#fbbf24;--orange-soft:#3c3018;--red:#fb7185;--red-soft:#44242a;--shadow:0 20px 60px rgba(0,0,0,.28);--shadow-soft:0 10px 28px rgba(0,0,0,.2)}
*{box-sizing:border-box}html{min-width:320px;scroll-behavior:smooth}body{margin:0;min-height:100vh;color:var(--text);background:radial-gradient(circle at 14% -10%,var(--bg-accent),transparent 30%),radial-gradient(circle at 92% 8%,rgba(5,150,105,.06),transparent 24%),var(--bg);font-family:-apple-system,BlinkMacSystemFont,"SF Pro Display","Segoe UI",Inter,Arial,sans-serif;font-size:15px;-webkit-font-smoothing:antialiased}button,input{font:inherit}button{color:inherit}svg{width:1.25em;height:1.25em;fill:none;stroke:currentColor;stroke-width:1.8;stroke-linecap:round;stroke-linejoin:round}[hidden]{display:none!important}
.app-shell{width:min(1380px,calc(100% - 40px));margin:0 auto}.topbar{height:76px;display:flex;align-items:center;justify-content:space-between;border-bottom:1px solid var(--line)}.brand{display:inline-flex;align-items:center;gap:11px;color:var(--text);text-decoration:none}.brand-mark{display:grid;width:39px;height:39px;place-items:center;color:#fff;border-radius:12px;background:linear-gradient(145deg,#2563eb,#0f9f7a);box-shadow:0 8px 20px rgba(37,99,235,.2)}.brand-mark svg{width:24px;height:24px;stroke-width:2.1}.brand>span:last-child{display:flex;gap:5px;align-items:baseline;font-size:17px}.brand strong{font-weight:750;letter-spacing:-.02em}.brand small{color:var(--muted);font-size:14px}.topbar-actions{display:flex;align-items:center;gap:10px}.privacy-pill,.version-pill{display:inline-flex;align-items:center;height:34px;padding:0 12px;color:var(--muted);border:1px solid var(--line);border-radius:99px;background:var(--surface);font-size:12px;font-weight:600}.privacy-pill i{width:7px;height:7px;margin-right:7px;border-radius:50%;background:var(--green);box-shadow:0 0 0 4px var(--green-soft)}.version-pill{color:var(--blue);background:var(--blue-soft);border-color:transparent}.icon-button{display:grid;width:36px;height:36px;padding:0;place-items:center;color:var(--muted);border:1px solid var(--line);border-radius:50%;background:var(--surface);cursor:pointer;transition:.2s ease}.icon-button:hover{color:var(--text);border-color:var(--line-strong);transform:translateY(-1px)}.icon-button svg{width:17px;height:17px}.moon-icon{display:none}[data-theme="dark"] .sun-icon{display:none}[data-theme="dark"] .moon-icon{display:block}
main{padding:48px 0 30px}.hero{max-width:760px;margin-bottom:34px}.eyebrow{display:inline-block;color:var(--blue);font-size:11px;font-weight:800;letter-spacing:.15em}.hero h1{margin:10px 0;font-size:clamp(34px,4.2vw,54px);line-height:1.04;letter-spacing:-.045em}.hero p{max-width:700px;margin:0;color:var(--muted);font-size:17px;line-height:1.55}.surface{border:1px solid var(--line);background:var(--surface);box-shadow:var(--shadow);backdrop-filter:blur(16px)}
.workspace{display:grid;grid-template-columns:minmax(340px,410px) minmax(0,1fr);gap:22px;align-items:start}.setup-card{position:sticky;top:18px;padding:25px;border-radius:26px}.section-heading{display:flex;align-items:center;gap:13px;margin-bottom:24px}.step-number{display:grid;flex:0 0 35px;height:35px;place-items:center;color:var(--blue);border-radius:11px;background:var(--blue-soft);font-weight:800}.section-heading h2{margin:0 0 3px;font-size:19px;letter-spacing:-.02em}.section-heading p{margin:0;color:var(--muted);font-size:13px}.field-group{margin-bottom:20px}.field-label{display:block;margin-bottom:9px;color:var(--muted);font-size:12px;font-weight:700}.supplier-grid{display:flex;flex-wrap:wrap;gap:7px}.supplier-chip{min-height:34px;padding:7px 11px;border:1px solid var(--line);border-radius:10px;background:var(--surface-soft);color:var(--muted);font-size:12px;font-weight:700;cursor:pointer;transition:.18s ease}.supplier-chip:hover{color:var(--text);border-color:var(--line-strong)}.supplier-chip.is-active{color:var(--blue);border-color:color-mix(in srgb,var(--blue) 34%,transparent);background:var(--blue-soft)}
.upload-stack{display:grid;gap:10px}.drop-zone{position:relative;display:flex;min-height:82px;align-items:center;gap:12px;padding:14px;border:1px dashed var(--line-strong);border-radius:17px;background:var(--surface-soft);cursor:pointer;outline:none;transition:.2s ease}.drop-zone:hover,.drop-zone:focus-visible,.drop-zone.is-dragging{border-color:var(--blue);background:var(--blue-soft);transform:translateY(-1px)}.drop-zone.is-ready{border-style:solid;border-color:color-mix(in srgb,var(--green) 40%,var(--line));background:var(--green-soft)}.file-icon{display:grid;flex:0 0 44px;height:44px;place-items:center;border-radius:13px}.file-icon svg{width:23px;height:23px}.supplier-file{color:var(--orange);background:var(--orange-soft)}.crm-file{color:var(--blue);background:var(--blue-soft)}.file-copy{min-width:0;display:grid;gap:5px}.file-copy strong{font-size:13px}.file-copy small{overflow:hidden;color:var(--muted);font-size:11px;text-overflow:ellipsis;white-space:nowrap}.file-action{display:grid;flex:0 0 30px;height:30px;margin-left:auto;place-items:center;color:var(--faint);border-radius:9px;background:var(--surface-solid)}.file-action svg{width:16px;height:16px}.drop-zone.is-ready .file-action{color:var(--green)}
.settings-box{margin:14px 0 4px;border:1px solid var(--line);border-radius:15px;background:var(--surface-soft)}.settings-box summary,.diagnostics-card summary{display:flex;min-height:46px;align-items:center;justify-content:space-between;padding:0 14px;list-style:none;cursor:pointer}.settings-box summary::-webkit-details-marker,.diagnostics-card summary::-webkit-details-marker{display:none}.settings-box summary>span,.diagnostics-card summary>span{display:inline-flex;align-items:center;gap:8px;font-size:12px;font-weight:700}.settings-box summary svg,.diagnostics-card summary svg{width:17px;height:17px;color:var(--muted)}.chevron{transition:transform .2s ease}details[open]>summary .chevron{transform:rotate(180deg)}.settings-grid{display:grid;grid-template-columns:1fr 1fr;gap:9px;padding:0 12px 12px}.settings-grid label{display:grid;gap:6px;color:var(--muted);font-size:10px;font-weight:700}.settings-grid .dd-product-setting{grid-column:1/-1}.number-field{display:flex;height:38px;align-items:center;gap:4px;padding:0 9px;color:var(--muted);border:1px solid var(--line);border-radius:10px;background:var(--surface-solid)}.number-field input{min-width:0;width:100%;color:var(--text);border:0;outline:0;background:transparent;font-weight:750}.number-field b{font-size:11px}
.status-line{min-height:20px;margin:10px 2px 7px;color:var(--muted);font-size:12px;line-height:1.4}.status-line[data-tone="error"]{color:var(--red)}.status-line[data-tone="success"]{color:var(--green)}.primary-button,.download-button{display:inline-flex;min-height:48px;align-items:center;justify-content:center;gap:8px;color:#fff;border:0;border-radius:14px;background:linear-gradient(135deg,var(--blue-strong),#187e70);box-shadow:0 10px 24px rgba(37,99,235,.2);font-weight:750;cursor:pointer;transition:.2s ease}.primary-button{width:100%}.primary-button:hover,.download-button:hover{filter:brightness(1.05);transform:translateY(-1px)}.primary-button:disabled,.download-button:disabled{cursor:wait;opacity:.68;transform:none}.button-label{display:inline-flex;align-items:center;gap:8px}.button-label svg{width:19px;height:19px}.button-loader{display:none;width:18px;height:18px;border:2px solid rgba(255,255,255,.4);border-top-color:#fff;border-radius:50%;animation:spin .8s linear infinite}.primary-button.is-loading .button-label{display:none}.primary-button.is-loading .button-loader{display:block}@keyframes spin{to{transform:rotate(360deg)}}.text-button{display:block;margin:8px auto 0;padding:7px;color:var(--muted);border:0;background:transparent;font-size:11px;cursor:pointer}.text-button:hover{color:var(--text)}
.result-area{min-width:0}.welcome-card{min-height:530px;display:flex;flex-direction:column;align-items:center;justify-content:center;padding:40px;text-align:center;border-radius:26px}.welcome-visual{position:relative;width:244px;height:150px;margin-bottom:25px}.sheet{position:absolute;top:18px;width:104px;height:124px;padding:31px 18px 0;border:1px solid var(--line);border-radius:20px;background:var(--surface-solid);box-shadow:var(--shadow-soft)}.sheet-one{left:12px;transform:rotate(-6deg)}.sheet-two{right:12px;transform:rotate(6deg)}.sheet span{display:block;height:7px;margin-bottom:10px;border-radius:10px;background:var(--line)}.sheet-one span:first-child{width:70%;background:var(--orange-soft)}.sheet-two span:first-child{width:70%;background:var(--blue-soft)}.link-badge{position:absolute;z-index:2;top:55px;left:99px;display:grid;width:48px;height:48px;place-items:center;color:#fff;border:5px solid var(--surface-solid);border-radius:50%;background:linear-gradient(145deg,var(--blue-strong),var(--green));box-shadow:0 8px 20px rgba(37,99,235,.25)}.link-badge svg{width:22px;height:22px}.welcome-card h2{margin:0 0 8px;font-size:23px;letter-spacing:-.025em}.welcome-card>p{max-width:480px;margin:0;color:var(--muted);line-height:1.55}.trust-row{display:flex;flex-wrap:wrap;justify-content:center;gap:15px;margin-top:25px;color:var(--muted);font-size:11px;font-weight:650}.trust-row span{display:inline-flex;align-items:center;gap:5px}.trust-row svg{width:14px;height:14px;color:var(--green);stroke-width:2.4}
.results{display:grid;gap:16px}.results-header{display:flex;align-items:flex-end;justify-content:space-between;gap:18px;padding:5px 2px 3px}.results-header h2{margin:5px 0 3px;font-size:29px;letter-spacing:-.035em}.results-header p{margin:0;color:var(--muted);font-size:12px}.download-button{flex:0 0 auto;min-height:42px;padding:0 16px;border-radius:12px;font-size:12px}.download-button svg{width:18px;height:18px}.stats-grid{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:10px}.stat-card{min-width:0;padding:15px;border:1px solid var(--line);border-radius:17px;background:var(--surface);box-shadow:var(--shadow-soft)}.stat-top{display:flex;align-items:center;justify-content:space-between;margin-bottom:9px}.stat-icon{display:grid;width:29px;height:29px;place-items:center;color:var(--blue);border-radius:9px;background:var(--blue-soft)}.stat-icon svg{width:15px;height:15px}.stat-value{font-size:25px;font-weight:780;letter-spacing:-.035em}.stat-label{overflow:hidden;color:var(--muted);font-size:10px;font-weight:700;text-overflow:ellipsis;white-space:nowrap}.stat-card[data-tone="success"] .stat-icon,.stat-card[data-tone="success"] .stat-value{color:var(--green)}.stat-card[data-tone="success"] .stat-icon{background:var(--green-soft)}.stat-card[data-tone="danger"] .stat-icon,.stat-card[data-tone="danger"] .stat-value{color:var(--red)}.stat-card[data-tone="danger"] .stat-icon{background:var(--red-soft)}.stat-card[data-tone="warning"] .stat-icon,.stat-card[data-tone="warning"] .stat-value{color:var(--orange)}.stat-card[data-tone="warning"] .stat-icon{background:var(--orange-soft)}
.data-card{overflow:hidden;border-radius:22px}.tab-list{display:flex;gap:3px;padding:8px;border-bottom:1px solid var(--line);overflow-x:auto}.tab{min-height:38px;padding:0 12px;color:var(--muted);border:0;border-radius:10px;background:transparent;font-size:11px;font-weight:750;white-space:nowrap;cursor:pointer}.tab span{display:inline-grid;min-width:20px;height:20px;margin-left:4px;place-items:center;color:var(--faint);border-radius:99px;background:var(--surface-soft);font-size:9px}.tab:hover{color:var(--text)}.tab.is-active{color:var(--blue);background:var(--blue-soft)}.tab.is-active span{color:var(--blue);background:var(--surface-solid)}.tab-panel{min-height:190px}.table-scroll{overflow:auto;max-height:440px}table{width:100%;border-collapse:collapse;font-size:11px}th{position:sticky;z-index:1;top:0;padding:11px 13px;color:var(--muted);background:var(--surface-soft);font-size:9px;letter-spacing:.04em;text-align:left;text-transform:uppercase;white-space:nowrap}td{max-width:230px;padding:12px 13px;border-top:1px solid var(--line);vertical-align:top;line-height:1.4}td.money{font-variant-numeric:tabular-nums;white-space:nowrap}td.diff-positive{color:var(--red);font-weight:750}td.diff-negative{color:var(--green);font-weight:750}.method-badge{display:inline-block;padding:4px 7px;color:var(--muted);border-radius:7px;background:var(--surface-soft);font-size:9px}.empty-state{min-height:190px;display:grid;place-items:center;padding:25px;text-align:center}.empty-state>div{max-width:350px}.empty-check{display:grid;width:42px;height:42px;margin:0 auto 12px;place-items:center;color:var(--green);border-radius:13px;background:var(--green-soft)}.empty-check svg{width:22px;height:22px}.empty-state strong{display:block;margin-bottom:5px}.empty-state p{margin:0;color:var(--muted);font-size:11px;line-height:1.5}
.diagnostics-card{border-radius:18px;box-shadow:var(--shadow-soft)}.diagnostics-card summary{min-height:50px}.diagnostics-grid{display:grid;grid-template-columns:1fr 1fr;gap:10px;padding:0 13px 13px}.diagnostic-box{padding:12px;border-radius:12px;background:var(--surface-soft)}.diagnostic-box strong{display:block;margin-bottom:7px;font-size:11px}.diagnostic-box dl{display:grid;grid-template-columns:92px 1fr;gap:5px 8px;margin:0;font-size:10px;line-height:1.4}.diagnostic-box dt{color:var(--muted)}.diagnostic-box dd{min-width:0;margin:0;overflow-wrap:anywhere}
.rules-strip{display:grid;grid-template-columns:repeat(3,1fr);gap:0;margin-top:22px;border-radius:22px;box-shadow:var(--shadow-soft)}.rules-strip>div{display:flex;align-items:center;gap:12px;padding:18px 20px}.rules-strip>div+div{border-left:1px solid var(--line)}.rule-icon{display:grid;flex:0 0 37px;height:37px;place-items:center;color:var(--blue);border-radius:11px;background:var(--blue-soft)}.rule-icon svg{width:20px;height:20px}.rules-strip strong,.rules-strip small{display:block}.rules-strip strong{margin-bottom:3px;font-size:12px}.rules-strip small{color:var(--muted);font-size:10px;line-height:1.35}footer{display:flex;justify-content:space-between;gap:20px;padding:25px 2px 32px;color:var(--faint);font-size:10px}
@media(max-width:1050px){.workspace{grid-template-columns:1fr}.setup-card{position:static}.welcome-card{min-height:410px}.stats-grid{grid-template-columns:repeat(3,1fr)}}
@media(max-width:720px){.app-shell{width:min(100% - 24px,1380px)}.topbar{height:66px}.privacy-pill{display:none}main{padding-top:34px}.hero{margin-bottom:25px}.hero h1{font-size:36px}.hero p{font-size:15px}.setup-card{padding:20px;border-radius:22px}.stats-grid{grid-template-columns:repeat(2,minmax(0,1fr))}.results-header{align-items:flex-start;flex-direction:column}.download-button{width:100%}.diagnostics-grid,.rules-strip{grid-template-columns:1fr}.rules-strip>div+div{border-top:1px solid var(--line);border-left:0}.welcome-card{min-height:380px;padding:28px 18px}.trust-row{gap:9px}footer{flex-direction:column;gap:6px}}
@media(max-width:440px){.brand small,.version-pill{display:none}.settings-grid{grid-template-columns:1fr}.stats-grid{grid-template-columns:1fr 1fr;gap:8px}.stat-card{padding:13px}.stat-value{font-size:22px}.supplier-grid{display:grid;grid-template-columns:1fr 1fr}}
@media(prefers-reduced-motion:reduce){*,*::before,*::after{scroll-behavior:auto!important;animation-duration:.01ms!important;transition-duration:.01ms!important}}
