/* Sales analysis workspace. All overrides are scoped to this page. */
main:has(#analysis-page:not([hidden]))>.page-header{padding:22px 0 16px;min-height:0}
main:has(#analysis-page:not([hidden]))>.page-header::after,main:has(#analysis-page:not([hidden])) .page-header .eyebrow{display:none}
main:has(#analysis-page:not([hidden])) .page-header h1{font-size:26px;margin:0;line-height:1.35}
main:has(#analysis-page:not([hidden])) .page-header p{font-size:12px;margin:6px 0 0;line-height:1.6}
main:has(#analysis-page:not([hidden]))>#filters{display:grid;grid-template-columns:minmax(105px,1fr) minmax(105px,1fr) minmax(100px,1fr) minmax(100px,1fr) minmax(115px,1.15fr) minmax(125px,1.15fr) 64px;gap:10px 12px;padding:15px 18px;margin-bottom:14px;border-radius:12px;align-items:end}
main:has(#analysis-page:not([hidden]))>#filters>label{min-width:0;max-width:none;width:100%;font-size:11px;gap:5px}
main:has(#analysis-page:not([hidden]))>#filters input,main:has(#analysis-page:not([hidden]))>#filters select,main:has(#analysis-page:not([hidden]))>#filters .select-button,main:has(#analysis-page:not([hidden]))>#filters #shop-picker{min-width:0;max-width:100%;width:100%;height:35px;font-size:12px;padding:7px 9px}
main:has(#analysis-page:not([hidden]))>#filters .date-separator,main:has(#analysis-page:not([hidden]))>#filters #yesterday,main:has(#analysis-page:not([hidden]))>#filters #this-month,main:has(#analysis-page:not([hidden]))>#filters #all-days{display:none}
main:has(#analysis-page:not([hidden]))>#filters #apply{grid-column:7;grid-row:1;height:35px;padding:7px 10px;font-size:12px}
main:has(#analysis-page:not([hidden]))>#filters #last7,main:has(#analysis-page:not([hidden]))>#filters #last30,main:has(#analysis-page:not([hidden]))>#filters #last90{grid-row:2;justify-self:start;padding:3px 8px;height:25px;font-size:11px;min-width:0;box-shadow:none;border:0;background:#eff3f2;color:#567166}
main:has(#analysis-page:not([hidden]))>#filters #last7{grid-column:1}main:has(#analysis-page:not([hidden]))>#filters #last30{grid-column:2}main:has(#analysis-page:not([hidden]))>#filters #last90{grid-column:3}
main:has(#analysis-page:not([hidden]))>#filters::after{content:'调整筛选后点击「查看」';font-size:11px;color:#8a9893;grid-column:4 / 8;grid-row:2;justify-self:end;align-self:center}
#analysis-page{min-width:0}.analysis-command{display:flex;align-items:center;justify-content:space-between;gap:16px;margin:0 0 12px;position:sticky;top:0;z-index:5;background:var(--bg);padding:3px 0}
.analysis-command>#analysis-export{font-size:12px;padding:8px 13px;flex-shrink:0}
.analysis-view-tabs{display:flex;gap:3px;border:1px solid #dfe6e1;background:#eaf0ec;border-radius:9px;padding:3px;position:static;margin:0}
.analysis-view-tabs button{border:0;border-radius:6px;background:transparent;color:#76877d;padding:8px 18px;font-size:13px;line-height:1.2;font-weight:600;white-space:nowrap}
.analysis-view-tabs button.active{background:#fff;color:#244c3c;box-shadow:0 1px 4px #1d382714;border-bottom:0}
.analysis-coverage{display:flex;align-items:center;justify-content:space-between;gap:8px 20px;background:#fbfaf4;border:1px solid #e9e5d6;border-radius:8px;padding:9px 12px;font-size:11px;color:#81734e;line-height:1.6;margin-bottom:10px;min-width:0}
.analysis-coverage-summary{display:flex;align-items:center;flex-wrap:wrap;gap:4px 10px;min-width:0}.analysis-coverage-summary>strong{font-size:11px;font-weight:600}.analysis-coverage-summary>span:not(.analysis-dot){color:#899087}
.analysis-dot{display:inline-block;width:5px;height:5px;border-radius:50%;background:#b88b39;flex-shrink:0}.analysis-dot.complete{background:#34725a}
.analysis-coverage details{position:relative}.analysis-coverage summary{cursor:pointer;color:#6f7c70;white-space:nowrap}.analysis-coverage details[open]{position:absolute;z-index:10;background:#fffdf8;border:1px solid #e4e0d3;border-radius:9px;box-shadow:0 8px 24px #182c2518;padding:12px 16px;max-width:min(550px,80vw)}
.analysis-coverage p{font-size:11px;line-height:1.8}.analysis-coverage>.text-button{font-size:11px;padding:3px 0;flex-shrink:0;color:#34725a}
.analysis-period-caption{font-size:11px;color:#839086;margin:0 0 8px}
#analysis-metrics{display:grid;grid-template-columns:1.25fr 1fr 1fr;gap:0;background:#fff;border:1px solid #e1e8e2;border-radius:12px;padding:15px 0;margin:0 0 12px;overflow:hidden}
#analysis-metrics>.metric{min-width:0;padding:0 22px;border:0;border-right:1px solid #e9eee9;border-radius:0;box-shadow:none;background:transparent;margin:0}
#analysis-metrics>.metric:last-child{border-right:0}#analysis-metrics .metric-title{font-size:11px;color:#77867a}#analysis-metrics .metric-value{font-size:28px;line-height:1.2;margin:6px 0 4px;color:#284d3b;font-weight:700;font-variant-numeric:tabular-nums}#analysis-metrics .metric-note{font-size:10px;line-height:1.5;color:#8a968c}
#analysis-signals{display:flex;gap:8px;flex-wrap:wrap;margin:0 0 16px}
.analysis-signal{display:flex;align-items:center;gap:9px;background:#fff;border:1px solid #e1e8e2;border-radius:7px;padding:7px 12px;color:#6d8172;text-align:left;box-shadow:none;min-width:0}
.analysis-signal:hover{background:#edf4ee;border-color:#adc6b3}.analysis-signal span{font-size:11px}.analysis-signal strong{font-size:13px;line-height:1;font-variant-numeric:tabular-nums;font-weight:700;color:#355d45}.analysis-signal small{display:none}.analysis-signal.decline strong{color:#ad644e}.analysis-signal.quiet strong{color:#94713d}
.analysis-insight-grid{display:grid;grid-template-columns:minmax(0,1.8fr) minmax(280px,1fr);gap:16px;margin-bottom:16px;align-items:start}
#analysis-page .analysis-panel{margin:0 0 16px;overflow:hidden;min-width:0;border-radius:12px;border:1px solid #e2e9e3;box-shadow:none}
#analysis-page .analysis-insight-grid>.analysis-panel{margin:0;height:334px}
#analysis-page .section-heading{padding:16px 18px 12px;gap:12px;align-items:center}#analysis-page .section-heading h2{font-size:15px;line-height:1.4;margin:0}#analysis-page .section-heading p{font-size:11px;line-height:1.5;margin:5px 0 0;color:#8b978e}
#analysis-page .section-heading select{border:1px solid #dfe6e0;background:#fff;border-radius:7px;font-size:11px;padding:6px 10px;max-width:140px}
.analysis-trend{padding:0 10px 5px}.analysis-line-chart{display:block;width:100%;height:auto;min-height:160px;max-height:260px}.analysis-line-chart text{font-size:11px;fill:#89978c}.analysis-trend .empty{font-size:11px;padding:8px}
.analysis-priorities{padding:0 18px 12px;max-height:255px;overflow:auto;scrollbar-width:thin}.analysis-priorities h3{font-size:10px;font-weight:500;letter-spacing:.5px;color:#8e9c91;margin:8px 0}
.analysis-priority{display:flex;align-items:center;justify-content:space-between;gap:12px;width:100%;background:none;border:0;border-bottom:1px solid #edf1ed;padding:10px 0;text-align:left}.analysis-priority>span:first-child{min-width:0}.analysis-priority strong{display:block;overflow:hidden;text-overflow:ellipsis;white-space:nowrap;font-size:12px;color:#425e48;max-width:210px;font-weight:600}.analysis-priority small{display:block;font-size:10px;color:#96a095;margin-top:3px}.analysis-priority:hover strong{color:#247046}
.analysis-change{white-space:nowrap;font-size:11px;font-variant-numeric:tabular-nums}.analysis-change.up{color:#437d5c}.analysis-change.down{color:#ad644e}.analysis-empty-note{font-size:11px;color:#929d92;line-height:1.9;padding:10px 0}
#analysis-page .analysis-panel table{font-size:12px}#analysis-page .analysis-panel th,#analysis-page .analysis-panel td{font-size:12px;padding:10px 16px;vertical-align:middle}#analysis-page .analysis-panel th{font-size:10px;font-weight:600;color:#7a8d7f;background:#f6f8f5}#analysis-page .analysis-panel td:not(:first-child),#analysis-page .analysis-panel th:not(:first-child){text-align:right;white-space:nowrap}#analysis-page .analysis-panel td:first-child,#analysis-page .analysis-panel th:first-child{text-align:left;min-width:0;width:auto}
#analysis-page .analysis-panel td small{font-size:10px;line-height:1.6;color:#94a093;margin:3px 0 0;display:block}.analysis-share{position:relative;min-width:90px;max-width:150px;margin-left:auto;height:20px;display:flex;align-items:center;justify-content:flex-end}.analysis-share i{position:absolute;left:0;top:7px;height:6px;border-radius:3px;background:#deebe0}.analysis-share span{position:relative;font-size:11px;color:#617d63}
#analysis-page .analysis-product-tools{display:flex;gap:8px;padding:12px 18px;border-top:1px solid #eff2ee;flex-wrap:wrap;align-items:center;background:#fbfcfa}
.analysis-product-tools>.search-control{flex:1 1 230px;max-width:360px;min-width:180px;margin:0}.analysis-product-tools>input{flex:1 1 230px;min-width:180px;max-width:360px}.analysis-product-tools select{font-size:11px;padding:8px 10px;border:1px solid #dfe7df;background:#fff;border-radius:7px;min-width:110px;max-width:180px}.analysis-product-tools input{font-size:12px}
#analysis-products-table{overflow:auto;max-height:650px;scrollbar-width:thin}#analysis-products-table table{min-width:860px;table-layout:fixed;width:100%}#analysis-products-table th:first-child{width:25%}#analysis-products-table th:nth-child(2),#analysis-products-table th:nth-child(3){width:9%}#analysis-products-table th:nth-child(4){width:15%}#analysis-products-table th:nth-child(5){width:8%}#analysis-products-table th:nth-child(6){width:16%}#analysis-products-table th:nth-child(7){width:18%}
#analysis-products-table td,#analysis-products-table th{padding:10px 12px!important}#analysis-products-table thead th{position:sticky;top:0;z-index:2}#analysis-products-table td:first-child{position:sticky;left:0;z-index:1;background:#fff;box-shadow:1px 0 0 #e9eee7}#analysis-products-table thead th:first-child{left:0;z-index:3}
.analysis-sku-link{border:0;background:none;color:#365e42;font-size:12px;font-weight:600;text-align:left;line-height:1.6;padding:0;display:block;max-width:100%;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.analysis-sku-link:hover{text-decoration:underline}.analysis-grade{display:inline-block;border-radius:4px;font-size:10px;padding:2px 6px;background:#f0f3ee;color:#81917e}.grade-A{color:#497553;background:#e8f1e5}.grade-B{color:#8c7d48;background:#f4f0e1}.analysis-chip{display:inline-block;font-size:9px;margin:2px;padding:3px 5px;border-radius:4px;background:#eff4ec;color:#71896a;white-space:nowrap}.analysis-chip.decline{background:#faeee6;color:#ae6c4f}.analysis-chip.quiet{background:#f8f2e4;color:#a08c53}
#analysis-page .pagination-footer{padding:10px 18px;display:flex;justify-content:space-between;gap:14px;align-items:center;border-top:1px solid #edf1e9;flex-wrap:wrap}#analysis-page .pagination-footer select{font-size:11px;padding:4px 8px;border:1px solid #dfe6dc;background:#fff;border-radius:6px}#analysis-page .pagination{padding:0;min-height:30px;font-size:11px}#analysis-page .pagination button{font-size:11px;padding:6px 10px}
#analysis-page #sku-matrix table{min-width:620px}#analysis-page #sku-matrix td:first-child,#analysis-page #category-matrix td:first-child{position:sticky;left:0;background:#fff;min-width:200px;z-index:1}#analysis-page #sku-matrix th:first-child,#analysis-page #category-matrix th:first-child{position:sticky;left:0;min-width:200px;z-index:2}
.analysis-rules{font-size:11px;line-height:1.9;color:#8c978a;margin:12px 0 18px}.analysis-rules summary{cursor:pointer;color:#758b72}.analysis-rules p{max-width:1100px;margin:8px 0}.analysis-thresholds{border-top:1px solid #e2e8df;padding-top:12px}.analysis-thresholds label{font-size:11px;display:flex;flex-direction:column;gap:6px}.analysis-thresholds input{width:110px}.analysis-thresholds .table-tools{padding:12px 0}
.analysis-detail h3{font-size:14px;margin:22px 0 12px}.analysis-detail>p{font-size:12px;line-height:1.8}.analysis-detail-kpis{display:grid;grid-template-columns:repeat(3,1fr);gap:12px;background:#f5f8f2;border:1px solid #e5ecdf;border-radius:10px;padding:16px}.analysis-detail-kpis small{display:block;color:#87967f;font-size:11px}.analysis-detail-kpis strong{display:block;margin-top:7px;font-size:18px;color:#486d43}.analysis-detail .notice{font-size:12px;line-height:1.8;margin:9px 0;padding:10px 14px}.analysis-detail .analysis-line-chart{max-height:270px}.analysis-detail table{margin-top:18px}
@media(max-width:1100px){main:has(#analysis-page:not([hidden]))>#filters{grid-template-columns:repeat(3,minmax(0,1fr)) 64px}main:has(#analysis-page:not([hidden]))>#filters>label:nth-of-type(4){grid-column:1;grid-row:2}main:has(#analysis-page:not([hidden]))>#filters>label:nth-of-type(5){grid-column:2;grid-row:2}main:has(#analysis-page:not([hidden]))>#filters>label:nth-of-type(6){grid-column:3;grid-row:2}main:has(#analysis-page:not([hidden]))>#filters #apply{grid-column:4;grid-row:1 / 3;align-self:end}main:has(#analysis-page:not([hidden]))>#filters #last7,main:has(#analysis-page:not([hidden]))>#filters #last30,main:has(#analysis-page:not([hidden]))>#filters #last90{grid-row:3}main:has(#analysis-page:not([hidden]))>#filters::after{display:none}.analysis-insight-grid{grid-template-columns:minmax(0,1.45fr) minmax(245px,1fr);gap:12px}}
@media(max-width:850px){.analysis-insight-grid{grid-template-columns:1fr}#analysis-page .analysis-insight-grid>.analysis-panel{height:auto;min-height:250px}.analysis-priorities{max-height:250px}.analysis-command{gap:8px}.analysis-view-tabs button{padding:8px 13px}.analysis-line-chart{max-height:270px}.analysis-signal{padding:6px 9px;gap:7px}}
@media(max-width:650px){main:has(#analysis-page:not([hidden]))>.page-header{padding:16px 0 12px}main:has(#analysis-page:not([hidden])) .page-header h1{font-size:23px}main:has(#analysis-page:not([hidden])) .page-header p{font-size:11px;max-width:240px}main:has(#analysis-page:not([hidden]))>#filters{grid-template-columns:1fr 1fr;padding:12px;gap:10px}main:has(#analysis-page:not([hidden]))>#filters>label:nth-of-type(n){grid-column:auto;grid-row:auto}main:has(#analysis-page:not([hidden]))>#filters #apply{grid-column:1 / -1;grid-row:auto;height:33px}main:has(#analysis-page:not([hidden]))>#filters #last7,main:has(#analysis-page:not([hidden]))>#filters #last30,main:has(#analysis-page:not([hidden]))>#filters #last90{display:none}.analysis-command{position:static;flex-wrap:wrap;margin-bottom:10px}.analysis-view-tabs{flex:1}.analysis-view-tabs button{flex:1;padding:8px 10px;font-size:12px}.analysis-command>#analysis-export{font-size:10px;padding:8px}.analysis-coverage{align-items:flex-start;flex-direction:column;gap:6px;padding:8px 10px}.analysis-coverage-summary{gap:4px 7px}.analysis-coverage-summary>span:not(.analysis-dot){display:none}.analysis-period-caption{font-size:10px}#analysis-metrics{padding:12px 0}#analysis-metrics>.metric{padding:0 12px}#analysis-metrics .metric-title{font-size:10px}#analysis-metrics .metric-value{font-size:23px}#analysis-metrics .metric-note{font-size:9px}.analysis-signal{padding:6px 8px}.analysis-signal span{font-size:10px}.analysis-signal strong{font-size:12px}#analysis-signals{gap:6px;margin-bottom:12px}.analysis-detail-kpis{padding:12px;gap:8px}.analysis-detail-kpis strong{font-size:15px}.analysis-product-tools>.search-control,.analysis-product-tools>input{flex-basis:100%;max-width:none}.analysis-product-tools select{flex:1;max-width:none;min-width:105px}#analysis-page .section-heading{padding:14px 14px 10px}#analysis-page .analysis-product-tools{padding:10px 14px}.analysis-coverage details[open]{left:14px;max-width:calc(100vw - 40px)}}
.analysis-signal.active{background:#e6f0e5;border-color:#a9c2a7;color:#386140}.analysis-signal.active strong{color:#315b36}
@media(max-width:900px){main:has(#analysis-page:not([hidden]))>#filters.mobile-collapsed{display:none}}
