.settlement-view{padding:0 var(--ws-page-gutter,24px) 32px;width:100%;max-width:none;color:var(--ink);font-size:14px;line-height:1.4;letter-spacing:-.025em}
.settlement-view button,.settlement-view input,.settlement-view select{font:inherit;color:var(--ink)}
.settlement-view input:focus-visible,.settlement-view [tabindex]:focus-visible,.settlement-view summary:focus-visible{outline:2px solid var(--ink);outline-offset:3px}
.sales-toolbar{display:flex;flex-wrap:wrap;align-items:flex-start;justify-content:space-between;gap:12px 24px;margin-bottom:24px;border-bottom:1px solid var(--line)}
.sales-date-controls{display:flex;flex-wrap:wrap;align-items:center;justify-content:flex-end;gap:8px;margin-left:auto;margin-bottom:12px;min-width:0}
.settlement-tabs{display:flex;gap:28px;min-width:0}.settlement-tabs button{position:relative;white-space:nowrap;padding:12px 0 18px;color:var(--muted);font-size:13px;font-weight:500}.settlement-tabs button:hover{color:var(--ink)}.settlement-tabs button[aria-selected=true]{color:var(--ink);font-weight:600}.settlement-tabs button[aria-selected=true]:after{content:'';position:absolute;bottom:-1px;left:0;right:0;height:2px;background:var(--ink)}
.sales-period{position:relative;flex-shrink:0}.sales-period summary{display:flex;align-items:center;gap:10px;cursor:pointer;list-style:none;border:1px solid var(--line);background:var(--white);border-radius:6px;padding:10px 12px;font-size:12px}.sales-period summary::-webkit-details-marker{display:none}.sales-period summary svg{width:16px;height:16px;fill:none;stroke:currentColor;stroke-width:1.4}
.sales-period-popover{position:absolute;z-index:10;right:0;top:48px;width:min(600px,100cqw);max-height:min(640px,70dvh);overflow-y:auto;overscroll-behavior:contain;padding:20px;background:var(--white);border:1px solid var(--line);border-radius:10px;box-shadow:0 12px 32px #0002}
.settlement-presets{display:flex;flex-wrap:wrap;gap:4px;min-width:0}.settlement-presets button{min-height:38px;padding:8px 10px;font-size:12px;white-space:nowrap;border:1px solid transparent;border-radius:6px;color:var(--muted)}.settlement-presets button:hover{background:var(--white);color:var(--ink)}.settlement-presets button[aria-pressed=true]{background:var(--accent-bg);border-color:var(--line);color:var(--ink);font-weight:600}.settlement-presets button:focus-visible{outline:2px solid var(--ink);outline-offset:2px}
.settlement-dates{display:flex;align-items:end;gap:8px;color:var(--muted);margin-top:16px}.settlement-dates>span{padding-bottom:10px}.settlement-dates label{flex:1;min-width:0;font-size:11px}.settlement-dates input{display:block;margin-top:6px;width:100%;min-width:0;border:1px solid var(--line);border-radius:6px;background:var(--white);height:38px;padding:8px;font-size:12px;color-scheme:light}
html[data-theme=dark] .settlement-dates input,html[data-theme=dark] .sales-page-size select{color-scheme:dark}.sales-period-popover p{font-size:12px;line-height:1.5;color:var(--muted);margin:12px 0}.sales-period-popover p:empty{display:none}
.settlement-filter-actions{display:flex;justify-content:flex-end;gap:8px;margin-top:16px}.settlement-filter-actions button{min-width:72px;min-height:36px;border:1px solid var(--line);border-radius:6px;font-size:12px;padding:8px 16px}.settlement-filter-actions button:hover{background:var(--accent-bg)}.settlement-filter-actions .settlement-submit{background:#333335;color:white;border-color:#414144}
.settlement-query{display:flex;align-items:center;justify-content:space-between;gap:12px;margin-bottom:12px;font-size:12px;color:var(--muted)}.settlement-demo{white-space:nowrap;border:1px solid var(--line);padding:4px 8px;border-radius:5px;font-size:11px}
.settlement-summary{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));padding:28px 0;background:var(--white);border:1px solid var(--line);border-radius:12px;margin-bottom:24px}.settlement-summary>div{padding:0 24px;border-right:1px solid var(--line)}.settlement-summary>div:last-child{border-right:0}.settlement-summary>div>span{font-size:13px;color:var(--muted)}.settlement-summary strong{display:block;font-size:28px;line-height:1.3;font-weight:600;margin-top:12px;font-variant-numeric:tabular-nums;overflow-wrap:anywhere}.settlement-summary small{font-size:13px;font-weight:400;margin-left:4px;color:var(--muted)}.sales-change{font-size:12px;margin:12px 0 0;color:var(--ink)}.sales-change span{color:var(--muted);margin-left:4px}
.sales-chart-card{padding:32px;border:1px solid var(--line);border-radius:12px;background:var(--white);margin-bottom:24px;min-width:0}.sales-chart-card>header{display:flex;align-items:center;justify-content:space-between;gap:12px;margin-bottom:20px}.sales-chart-card h2{font-size:16px;font-weight:600;margin:0}.sales-legend{display:flex;gap:16px;font-size:12px;color:var(--muted)}.sales-legend span:before{content:'';display:inline-block;width:12px;height:2px;background:var(--ink);vertical-align:middle;margin-right:6px}.sales-legend span:nth-child(2):before{background:var(--muted);opacity:.6}.sales-chart{position:relative;width:100%;min-height:340px;overflow:hidden;flex:1;cursor:default;touch-action:pan-y}.sales-chart svg{position:absolute;inset:0;display:block;max-width:100%}.sales-chart text{font-size:12px;fill:var(--muted)}.sales-grid{stroke:var(--line);stroke-width:1}.sales-line{fill:none;stroke:var(--ink);stroke-width:2;stroke-linejoin:round;stroke-linecap:round}.sales-line.previous{stroke:var(--muted);stroke-dasharray:5 5;opacity:.6}.sales-point{fill:var(--ink)}.sales-chart-note{font-size:11px;color:var(--muted);margin:12px 0 0;text-align:right}
.settlement-results{background:var(--white);border:1px solid var(--line);border-radius:12px;overflow:hidden}.settlement-results>header{display:flex;align-items:center;justify-content:space-between;gap:16px;padding:20px 24px}.settlement-results>header>div{display:flex;align-items:center;gap:8px}.settlement-results h2{font-size:16px;font-weight:600;margin:0}.settlement-count{font-size:12px;color:var(--muted)}.sales-page-size select{font-size:12px;padding:8px;border:1px solid var(--line);background:var(--white);border-radius:6px}
.settlement-table-scroll{overflow-x:auto;overscroll-behavior-x:contain}.settlement-results table{width:100%;border-collapse:collapse;white-space:nowrap;min-width:680px;font-size:13px;font-variant-numeric:tabular-nums}.settlement-results th{font-size:12px;font-weight:500;background:var(--bg);color:var(--muted);text-align:left;padding:14px 24px;border-top:1px solid var(--line);border-bottom:1px solid var(--line)}.settlement-results td{height:60px;padding:16px 24px;border-bottom:1px solid var(--line);color:var(--ink)}.settlement-results tbody tr:last-child td{border-bottom:0}.settlement-results tbody tr:hover{background:var(--bg)}.settlement-results .settlement-number{text-align:right}.settlement-results>footer{display:flex;align-items:center;justify-content:space-between;gap:16px;min-height:68px;border-top:1px solid var(--line);padding:16px 24px;font-size:12px;color:var(--muted)}.settlement-results footer strong{color:var(--ink);margin-left:8px;font-weight:600}.settlement-pagination{display:flex;align-items:center;gap:12px;white-space:nowrap}.settlement-pagination button{width:32px;height:32px;border:1px solid var(--line);border-radius:5px;font-size:20px}.settlement-pagination button:hover:not(:disabled){background:var(--accent-bg)}.settlement-pagination button:disabled{opacity:.35;cursor:default}
.settlement-product{display:block}.settlement-product-icon{display:grid;place-items:center;width:40px;height:44px;border-radius:6px;background:var(--accent-bg);font-size:13px;color:var(--muted)}.settlement-product strong{font-size:13px;font-weight:500;color:var(--ink)}.settlement-product small{display:block;font-size:11px;color:var(--muted);margin-top:4px}.settlement-empty{padding:52px 16px;display:flex;align-items:center;flex-direction:column;gap:12px;color:var(--muted);white-space:normal;text-align:center}.settlement-empty strong{font-size:14px;font-weight:500;color:var(--ink)}.settlement-empty span{font-size:12px}
@media(max-width:1250px){.settlement-summary strong{font-size:24px}.sales-change span{display:block;margin:4px 0 0}}
@media(max-width:720px){.settlement-view{padding:0 var(--ws-page-gutter,16px) 24px}.sales-toolbar{gap:12px;margin-bottom:20px}.settlement-tabs{gap:20px;overflow:auto;width:100%}.settlement-tabs button{font-size:12px;padding:0 0 14px}.sales-period{width:100%}.sales-period summary{justify-content:space-between;font-size:11px}.sales-period-popover{width:100%;padding:16px}.settlement-dates input{padding:6px 2px;font-size:10px}.settlement-summary{grid-template-columns:1fr;padding:0;margin-bottom:20px}.settlement-summary>div{border-right:0;border-bottom:1px solid var(--line);padding:20px;display:grid;grid-template-columns:1fr auto;gap:8px;align-items:center}.settlement-summary>div:last-child{border-bottom:0}.settlement-summary strong{font-size:21px;margin:0}.sales-change{grid-column:1/3;margin:0;text-align:right;font-size:11px}.sales-change span{display:inline;margin-left:4px}.settlement-summary>div>span{font-size:12px}.sales-chart-card{padding:20px 12px;margin-bottom:20px}.sales-chart-card>header{align-items:flex-start;flex-direction:column;padding:0 4px}.sales-chart-card h2,.settlement-results h2{font-size:14px}.settlement-results>header{padding:16px;gap:8px;flex-wrap:wrap}.settlement-results>footer{padding:16px;flex-wrap:wrap}.sales-total-note{display:none}.settlement-pagination{margin-left:auto;gap:8px}.settlement-results td,.settlement-results th{padding-left:16px;padding-right:16px}.settlement-demo{font-size:10px}}
.settlement-tabs button[aria-selected=true]:after{bottom:0}
@media(max-width:720px){.sales-date-controls{width:100%;justify-content:flex-start}.settlement-presets{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));width:100%}.settlement-presets button{min-height:40px;padding:8px}.sales-period{margin:0}.sales-period-popover{top:48px}}
@media(max-width:720px){.settlement-tabs{overflow-x:auto;overflow-y:hidden}.settlement-tabs button:focus-visible{outline-offset:-2px}}

/* Workspace reference: neutral surfaces, semantic green/red/yellow accents. */
.settlement-view{--sales-green:#08794f;--sales-red:#bf3346;--sales-yellow:#866000;--sales-green-bg:#08794f12;--sales-red-bg:#bf334612;--sales-yellow-bg:#86600012}
html[data-theme=dark] .settlement-view{--sales-green:#45d6a0;--sales-red:#ff858d;--sales-yellow:#edc46a;--sales-green-bg:#45d6a014;--sales-red-bg:#ff858d14;--sales-yellow-bg:#edc46a14}
.sales-badge{display:inline-flex;align-items:center;gap:4px;font-size:12px;font-weight:500;padding:3px 7px;border-radius:4px;white-space:nowrap;color:var(--muted);background:var(--bg)}
.sales-badge.up{color:var(--sales-green);background:var(--sales-green-bg)}.sales-badge.down{color:var(--sales-red);background:var(--sales-red-bg)}.sales-badge.new{color:var(--sales-yellow);background:var(--sales-yellow-bg)}
.sales-change .sales-badge{margin-left:0}.sales-change span.sales-badge{display:inline-flex}.settlement-demo{color:var(--sales-yellow);background:var(--sales-yellow-bg);border-color:transparent}
.sales-section-sub{display:block;font-size:12px;color:var(--muted);margin-top:6px}.sales-chart-card>header{margin-bottom:32px;gap:16px;justify-content:flex-start;flex-wrap:wrap}
.sales-period-badges{display:flex;flex-wrap:wrap;gap:6px}.sales-period-badge{color:var(--sales-yellow);background:var(--sales-yellow-bg);font-size:11px;font-weight:500;padding:4px 8px;border-radius:4px;white-space:nowrap}.product-detail .sales-period-badges{margin-top:10px}
.sales-calendar-heading{display:flex;justify-content:space-between;align-items:center}.sales-calendar-heading strong{font-size:14px}.sales-calendar-heading button{width:30px;height:30px;font-size:22px;border-radius:6px;color:var(--muted)}
.sales-calendar-selection{display:flex;justify-content:space-between;flex-wrap:wrap;gap:6px;margin:12px 0 16px;font-size:12px;font-variant-numeric:tabular-nums}.sales-calendar-selection small{font-size:11px;color:var(--muted)}
.sales-calendar-navigation{display:flex;align-items:center;justify-content:space-between;margin-bottom:12px}.sales-calendar-navigation>div{display:flex;gap:4px}.sales-calendar-navigation button{min-width:30px;height:30px;padding:0 8px;border:1px solid var(--line);border-radius:6px;font-size:18px}.sales-calendar-navigation [data-calendar-today]{font-size:11px}.sales-calendar-navigation button:disabled{opacity:.3;cursor:default}.sales-calendar-heading button:hover,.sales-calendar-navigation button:hover:not(:disabled){background:var(--accent-bg)}
.sales-calendar-months{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:24px}.sales-calendar-month{width:100%;table-layout:fixed;border-collapse:collapse}.sales-calendar-month caption{font-size:13px;font-weight:600;margin:2px 0 16px}.sales-calendar-month th{font-size:11px;font-weight:400;color:var(--muted);height:30px}.sales-calendar-month td{padding:2px 0;text-align:center}.sales-calendar-month button,.sales-calendar-month td>span{display:block;width:100%;height:34px;font-size:12px}.sales-calendar-month button{border-radius:6px;position:relative}.sales-calendar-month button:disabled{color:var(--muted);opacity:.35;cursor:default}.sales-calendar-month button:hover:not(:disabled){background:var(--accent-bg)}.sales-calendar-month button.in-range{background:var(--accent-bg);border-radius:0}.sales-calendar-month button.range-start,.sales-calendar-month button.range-end{background:var(--ink);color:var(--white);border-radius:6px;font-weight:600}.sales-calendar-month button[aria-current=date]:after{content:'';position:absolute;bottom:4px;left:calc(50% - 2px);width:4px;height:2px;border-radius:1px;background:currentColor}.sales-period-popover button:focus-visible{outline:2px solid var(--ink);outline-offset:-2px}.sales-calendar-month button.range-start:focus-visible,.sales-calendar-month button.range-end:focus-visible{outline-color:var(--white);outline-offset:-4px}.sales-period-popover .sales-calendar-error{color:var(--sales-yellow);margin-bottom:0}
@container sales-view (max-width:580px){.sales-calendar-months{grid-template-columns:1fr;gap:20px}.sales-calendar-month button,.sales-calendar-month td>span{height:36px}.sales-calendar-selection{flex-direction:column}.sales-chart-card>header{align-items:flex-start;flex-direction:column}}
.sales-calendar-month th,.sales-calendar-month td,.sales-calendar-month tr:hover{background:transparent;border:0}.sales-calendar-month button.range-start:hover:not(:disabled),.sales-calendar-month button.range-end:hover:not(:disabled){background:var(--ink);color:var(--white)}
.sales-chart-layout{display:grid;grid-template-columns:minmax(0,3fr) minmax(180px,1fr) minmax(180px,1fr);gap:32px;align-items:stretch}.sales-chart-main{min-width:0;min-height:460px;display:flex;flex-direction:column}.sales-chart svg{pointer-events:none}.sales-legend{margin-bottom:20px;flex-wrap:wrap;row-gap:8px}.sales-legend span:first-child:before{background:var(--sales-green)}.sales-legend span:nth-child(2):before{height:0;background:none;border-top:2px dashed var(--muted)}
.sales-grid{stroke-dasharray:3 5;opacity:.7}.sales-line.current,.sales-focus-point{stroke:var(--sales-green)}.sales-line.current{stroke-width:2.5}.sales-point{fill:var(--sales-green)}.sales-area-top{stop-color:var(--sales-green);stop-opacity:.14}.sales-area-bottom{stop-color:var(--sales-green);stop-opacity:0}.sales-focus-point{fill:var(--white);stroke-width:2}.sales-crosshair{stroke:var(--muted);stroke-dasharray:3 5;opacity:.7}
.sales-chart,.product-detail-chart{--chart-color:var(--sales-green)}[data-trend=down]{--chart-color:var(--sales-red)}[data-trend=flat]{--chart-color:var(--muted)}[data-trend=new]{--chart-color:var(--sales-yellow)}.sales-line.current,.sales-focus-point{stroke:var(--chart-color)}.sales-point{fill:var(--chart-color)}.sales-area-top,.sales-area-bottom{stop-color:var(--chart-color)}.sales-chart-card:has([data-trend=down]) .sales-legend span:first-child:before{background:var(--sales-red)}.sales-chart-card:has([data-trend=flat]) .sales-legend span:first-child:before{background:var(--muted)}.sales-chart-card:has([data-trend=new]) .sales-legend span:first-child:before{background:var(--sales-yellow)}
.settlement-view{container:sales-view / inline-size}.sales-chart-card{container:sales-card / inline-size}
@container sales-view (max-width:620px){.settlement-summary{grid-template-columns:1fr;padding:0}.settlement-summary>div{border-right:0;border-bottom:1px solid var(--line);padding:20px;display:grid;grid-template-columns:1fr auto;gap:8px;align-items:center}.settlement-summary>div:last-child{border-bottom:0}.settlement-summary strong{font-size:21px;margin:0}.sales-change{grid-column:1/3;margin:0;text-align:right}.sales-change span{display:inline;margin-left:4px}.product-tools{flex-wrap:wrap}.product-tools>label,.product-tools input{width:100%}}
.sales-chart-tooltip>rect{fill:var(--white);stroke:var(--line);stroke-width:1;filter:drop-shadow(0 4px 7px #0002)}.sales-chart-tooltip>line{stroke:var(--line)}.sales-chart .sales-chart-tooltip text,.product-detail-chart .sales-chart-tooltip text{font-size:12px}.sales-chart-tooltip .tooltip-heading,.sales-chart-tooltip .tooltip-value{fill:var(--ink);font-weight:500}.sales-chart-tooltip .tooltip-total{fill:var(--ink);font-weight:600}.sales-chart-tooltip .tooltip-comparison.up{fill:var(--sales-green)}.sales-chart-tooltip .tooltip-comparison.down{fill:var(--sales-red)}.sales-chart-tooltip .tooltip-comparison.new{fill:var(--sales-yellow)}
/* Revenue and orders follow the chart and share identical row geometry. */
.sales-source-breakdown{min-width:0}.sales-revenue-breakdown{border-left:1px solid var(--line);padding-left:24px}.sales-orders-breakdown{border-left:1px solid var(--line);padding-left:24px}
.sales-source-breakdown h3{font-size:13px;font-weight:600;margin:0 0 20px;min-height:40px;display:flex;flex-direction:column;gap:6px}.sales-source-breakdown h3 span{font-size:11px;font-weight:400;color:var(--muted)}
.sales-source-item{display:grid;grid-template-columns:minmax(0,1fr) 80px;align-items:center;gap:10px 8px;width:100%;text-align:left;padding:18px 0;border-bottom:1px solid var(--line)}.sales-source-item:last-child{border-bottom:0}.sales-source-item:hover{background:var(--bg)}.sales-source-item>div{display:contents}.sales-source-item>div>span:first-child{grid-column:1/-1;font-size:12px;color:var(--muted)}.sales-source-item strong{grid-column:1/-1;font-size:20px;font-weight:600;white-space:nowrap;line-height:1.25;font-variant-numeric:tabular-nums}.sales-source-item small{font-size:11px;color:var(--muted);font-weight:400;margin-left:4px}.sales-source-item .sales-badge{justify-self:start;font-size:11px;padding:3px 6px}.sales-source-item .sales-spark{grid-column:2;grid-row:3;width:80px;height:26px}

.sales-spark{display:block;width:120px;height:38px;color:var(--muted);overflow:visible}.sales-spark.up{color:var(--sales-green)}.sales-spark.down{color:var(--sales-red)}.sales-spark.new{color:var(--sales-yellow)}.sales-spark .spark-line{fill:none;stroke:currentColor;stroke-width:1.8;stroke-linejoin:round;stroke-linecap:round}.sales-spark circle,.sales-spark .spark-area{fill:currentColor}.sales-spark .spark-area{opacity:.08}
.product-tools{display:flex;align-items:center;justify-content:flex-end;gap:16px;margin-bottom:16px}.product-tools input{font:inherit;font-size:12px;color:var(--ink);width:240px;max-width:100%;height:36px;padding:8px 12px;background:var(--white);border:1px solid var(--line);border-radius:6px}
.sales-product-row td{padding-top:8px;padding-bottom:8px;height:68px}.sales-product-row.is-open{background:var(--bg)}.settlement-product{width:100%;text-align:left}.product-rank{width:18px;font-size:13px;color:var(--muted);text-align:center;flex-shrink:0}.product-rank.top{color:var(--sales-yellow);font-weight:600}.settlement-product-icon{width:36px;height:40px;flex-shrink:0}.settlement-product-icon svg{width:26px;height:26px;fill:none;stroke:currentColor;stroke-width:1.2}.sales-product-row .settlement-number:nth-child(5){font-weight:600}.product-detail-row>td{padding:0!important;background:var(--bg)}.product-detail{padding:24px;width:100%}.product-detail header{display:flex;justify-content:space-between;align-items:flex-start;gap:24px;margin-bottom:16px}.product-detail h3{font-size:14px;margin:0;font-weight:600}.product-detail h3 span{font-size:12px;color:var(--muted);font-weight:400;margin-left:8px}.product-detail p{font-size:12px;margin:6px 0 0;color:var(--muted)}.product-detail header button{width:32px;height:32px;font-size:22px;border:1px solid var(--line);border-radius:6px}.product-detail-chart{height:340px;cursor:default;touch-action:pan-y}.product-detail-chart svg{display:block;pointer-events:none;max-width:100%}.product-detail-chart text{font-size:11px;fill:var(--muted)}
@media(max-width:720px){.sales-chart-card>header{flex-direction:row;align-items:center;gap:8px}.sales-section-sub{font-size:10px}.product-tools{flex-wrap:wrap;gap:12px}.product-tools>label,.product-tools input{width:100%}.product-tools button{padding:8px 10px}.sales-change span.sales-badge{margin:0}.product-detail{padding:20px}.settlement-summary{margin-bottom:20px}.sales-chart-tooltip>rect{filter:none}}

@container sales-card (max-width:900px){.sales-chart-layout{grid-template-columns:repeat(2,minmax(0,1fr));gap:28px}.sales-chart-main{grid-column:1/-1;grid-row:1;min-height:400px}.sales-source-breakdown{border-top:1px solid var(--line);padding-top:24px}.sales-revenue-breakdown{border-left:0;padding-left:0}.sales-orders-breakdown{padding-left:28px}.sales-source-breakdown h3{min-height:36px;margin-bottom:0}.sales-source-item{grid-template-columns:minmax(0,1fr) 80px}}
@container sales-card (max-width:540px){.sales-chart-layout{gap:20px}.sales-chart-main{min-height:360px}.sales-orders-breakdown{padding-left:20px}.sales-source-breakdown h3{font-size:12px;min-height:44px;display:block}.sales-source-breakdown h3 span{display:block;margin-top:6px}.sales-source-item{grid-template-columns:1fr;gap:8px;padding:16px 0}.sales-source-item strong{font-size:16px;white-space:normal;overflow-wrap:anywhere}.sales-source-item .sales-spark{grid-column:1;grid-row:4;width:100%;height:28px}.sales-legend{font-size:11px;gap:14px}.sales-chart text{font-size:11px}}
@container sales-card (max-width:220px){.sales-source-breakdown h3{min-height:56px}.sales-source-item strong{font-size:14px;min-height:40px}.sales-source-item small{display:block;font-size:10px;margin:4px 0 0}}

/* Sales workspace: centered content, purpose-led KPI cards and shared controls. */
.sales-summary-meta{display:flex;justify-content:space-between;align-items:center;gap:16px;margin-bottom:16px;color:var(--muted);font-size:12px}
.sales-summary-section .settlement-summary{grid-template-columns:repeat(5,minmax(0,1fr));gap:16px;padding:0;background:none;border:0;border-radius:0;margin-bottom:28px}
.sales-summary-section .sales-kpi{display:block;padding:24px 20px;background:var(--white);border:1px solid var(--line);border-radius:10px;min-width:0}
.sales-summary-section .sales-kpi>span{font-size:14px;font-weight:500;color:var(--ink)}
.sales-info{font-size:12px;margin-left:6px;color:var(--muted);cursor:help}
.sales-summary-section .sales-kpi strong{font-size:25px;line-height:1.4;margin-top:12px;white-space:nowrap}
.sales-summary-section .sales-kpi small{font-size:12px;margin-left:3px}
.sales-summary-section .sales-change{margin-top:12px;text-align:left;grid-column:auto}
.sales-summary-section .sales-change .sales-badge{margin:0;display:inline-block;font-size:11px;white-space:normal;line-height:1.5}
.sales-detail-link{display:inline-flex;align-items:center;justify-content:center;gap:8px;min-height:38px;padding:9px 14px;border:1px solid var(--line);border-radius:7px;background:var(--bg);font-size:12px;font-weight:500;color:var(--ink);margin-left:auto;text-decoration:none;white-space:nowrap}
.sales-detail-link:hover{background:var(--accent-bg);border-color:var(--muted)}.sales-detail-link span{color:var(--sales-yellow);font-size:16px}
.sales-period-badge{font-size:12px;padding:5px 8px}
.sales-chart-controls{display:flex;justify-content:center;flex-wrap:wrap;gap:20px 28px;padding:20px 16px;margin-top:28px;border:1px solid var(--line);border-radius:8px}
.sales-chart-controls fieldset{border:0;padding:0;margin:0;min-width:0;display:flex;gap:12px;align-items:center;font-size:12px}
.sales-chart-controls legend{float:left;padding:0;margin-right:12px;color:var(--muted)}
.sales-chart-controls fieldset>div{display:flex;gap:14px;flex-wrap:wrap}
.sales-chart-controls label{display:inline-flex;align-items:center;gap:6px;cursor:pointer;white-space:nowrap;min-height:24px}
.sales-chart-controls input{margin:0;width:14px;height:14px;accent-color:var(--ink)}
.sales-chart-controls input:checked+span{font-weight:600}.sales-chart-controls input:focus-visible{outline-offset:3px}
.sales-chart-unavailable{flex:1;display:flex;align-items:center;justify-content:center;flex-direction:column;gap:12px;color:var(--muted);font-size:13px;min-height:360px}
.sales-chart-unavailable strong{color:var(--ink);font-size:16px;font-weight:500}
.sales-bar.current{fill:var(--chart-color);opacity:.85}.sales-bar.previous{fill:var(--muted);opacity:.25}
.settlement-results th{font-size:14px;font-weight:600;color:var(--ink);padding-top:18px;padding-bottom:18px}
.settlement-results th button{padding:0;display:inline-flex;align-items:center;gap:8px;min-height:24px;text-align:inherit;white-space:nowrap}
.settlement-results th button span{font-size:13px;color:var(--muted)}.settlement-results th[aria-sort=ascending] button span,.settlement-results th[aria-sort=descending] button span{color:var(--ink)}
.settlement-results th button:hover{text-decoration:underline}.settlement-results th button:focus-visible{outline:2px solid var(--ink);outline-offset:4px}
.settlement-results> .settlement-table-scroll>table{min-width:1040px}
.settlement-results .sales-options-table{min-width:0;width:100%;table-layout:fixed;background:var(--white);border:1px solid var(--line)}
.sales-options-table td{height:60px}.sales-options-table .sales-spark{width:100%;max-width:120px}.sales-options-table strong{font-weight:500;color:var(--ink);font-size:13px}
.product-detail{padding:24px 28px}.product-detail h3 span{margin-left:12px}.product-detail header{align-items:center;margin-bottom:20px}
.product-detail .sales-period-badges{margin-top:12px}.product-detail .sales-badge{font-size:11px}
@container sales-view (max-width:1400px){.sales-summary-section .sales-kpi{padding:24px 16px}.sales-summary-section .sales-kpi strong{font-size:22px}}
@container sales-view (max-width:960px){.sales-summary-section .settlement-summary{grid-template-columns:repeat(3,minmax(0,1fr))}.sales-summary-section .sales-kpi strong{font-size:24px}}
@container sales-view (max-width:660px){.sales-summary-section .settlement-summary{grid-template-columns:repeat(2,minmax(0,1fr));gap:12px}.sales-summary-section .sales-kpi{padding:20px 16px}.sales-summary-section .sales-kpi:first-child{grid-column:1/-1}.sales-summary-section .sales-kpi strong{font-size:23px}.sales-summary-section .sales-kpi>span{font-size:13px}.sales-summary-meta{align-items:flex-start;font-size:11px}.sales-chart-controls{justify-content:flex-start;padding:16px;gap:16px}.sales-chart-controls fieldset{display:block;width:100%}.sales-chart-controls legend{float:none;margin:0 0 8px}.sales-period-badges{flex-direction:column;align-items:flex-start}.sales-period-badge{font-size:11px}.sales-detail-link{margin-left:0}.product-detail{padding:20px}.settlement-summary small{display:inline}.sales-source-item strong{font-size:18px}}
@container sales-view (max-width:350px){.sales-summary-section .settlement-summary{grid-template-columns:1fr}.sales-summary-section .sales-kpi:first-child{grid-column:auto}.sales-chart-controls fieldset>div{gap:10px}.sales-source-item strong{font-size:15px}}

.sales-chart.is-compact .sales-date-tick{font-size:10px}.sales-chart.is-compact .sales-chart-tooltip text{font-size:11px}

/* Shared product/option metrics, with an explicit action at the far right. */
.settlement-results>.settlement-table-scroll>.sales-products-table{min-width:1640px;table-layout:fixed}
.product-col-rank{width:48px}.product-col-image{width:64px}.product-col-type{width:136px}.product-col-name{width:200px}.product-col-amount{width:132px}.product-col-change{width:190px}.product-col-count,.product-col-plain{width:98px}.product-col-rate{width:110px}.product-col-trend{width:140px}.product-col-action{width:52px}
.settlement-results .sales-products-table th,.settlement-results .sales-products-table td{padding-left:12px;padding-right:12px}
.settlement-results .product-center,.settlement-results .product-trend{text-align:center}
.product-trend .sales-spark{width:112px;height:36px;margin-inline:auto}
.product-rank{display:inline-block}.settlement-product strong{display:block;overflow:hidden;text-overflow:ellipsis;white-space:nowrap;font-weight:600}.settlement-product small{font-variant-numeric:tabular-nums}
.settlement-product-icon{width:40px;height:46px;margin-inline:auto;border:1px solid var(--line);border-radius:8px;background:linear-gradient(145deg,var(--accent-bg),var(--white));color:var(--muted)}.settlement-product-icon svg{width:27px;height:27px;stroke-width:1.3;stroke-linecap:round;stroke-linejoin:round}
.settlement-results .sales-products-table>thead>tr>th:last-child,.sales-product-row>.product-action{position:sticky;right:0;z-index:1;text-align:center;box-shadow:none;background:var(--white)}
.settlement-results .sales-products-table>thead>tr>th:last-child,.sales-product-row.is-open>.product-action{background:var(--bg)}
.product-toggle,.product-detail header .product-toggle{display:inline-grid;place-items:center;width:36px;height:36px;padding:0;border:1px solid var(--line);border-radius:7px;color:var(--muted);background:var(--white);flex-shrink:0}
.product-toggle:hover,.product-toggle[aria-expanded=true]{color:var(--ink);background:var(--accent-bg);border-color:var(--muted)}.product-toggle svg{width:18px;height:18px;fill:none;stroke:currentColor;stroke-width:1.8;stroke-linecap:round;stroke-linejoin:round}.product-toggle.is-expanded svg{transform:rotate(180deg)}
.product-detail header .product-toggle{position:sticky;right:12px}.sales-products-table .sales-badge{white-space:nowrap;font-size:11px}
.settlement-results .sales-options-table .product-trend .sales-spark{width:112px;max-width:100%;margin-inline:auto}

/* Column selection keeps overflow inside the table, including with few columns. */
.settlement-results>.settlement-table-scroll>table,.settlement-results>.settlement-table-scroll>.sales-products-table{min-width:0;table-layout:auto}
.settlement-results .sales-options-table{table-layout:auto}
.table-tools{display:flex;align-items:center;gap:8px;flex-wrap:wrap;justify-content:flex-end}
.table-tools>button{min-height:36px;padding:8px 12px;border:1px solid var(--line);border-radius:6px;background:var(--white);font-size:12px;white-space:nowrap}
.table-tools>button:hover{background:var(--bg)}
.table-tools>button:focus-visible{outline:2px solid var(--ink);outline-offset:2px}
.table-status{font-size:12px;color:var(--muted);margin:0 0 12px;min-height:0}.table-status:empty{display:none}

/* View controls stay next to the table; export is a separate table action. */
.table-tools>button{display:inline-flex;align-items:center;gap:8px;height:38px;max-width:270px}.table-tools>button>span:nth-child(2){overflow:hidden;text-overflow:ellipsis}
.table-columns-icon{font-size:14px;color:var(--muted)}.table-columns-chevron{width:16px;height:16px;fill:none;stroke:currentColor;stroke-width:1.5;flex:none;transition:transform .15s}
.table-tools [aria-expanded=true]{background:var(--accent-bg);border-color:var(--muted)}.table-tools [aria-expanded=true] .table-columns-chevron{transform:rotate(180deg)}
.table-tools .sales-page-size select{height:38px}.settlement-results>header{gap:16px;flex-wrap:wrap}
.table-actions{display:flex;align-items:center;justify-content:space-between;gap:12px;padding:12px 24px;border-bottom:1px solid var(--line);background:var(--white)}
.table-actions>button{display:flex;align-items:center;gap:8px;min-height:36px;margin-left:auto;padding:8px 12px;border:1px solid var(--line);border-radius:6px;font-size:12px;white-space:nowrap;background:var(--white)}
.table-actions>button:hover{background:var(--bg)}.table-actions>button svg{width:16px;height:16px;fill:none;stroke:currentColor;stroke-width:1.5}
.table-search input{width:260px;max-width:100%;height:36px;padding:8px 12px;border:1px solid var(--line);border-radius:6px;background:var(--bg);color:var(--ink);font:inherit;font-size:12px}
.table-actions :focus-visible{outline:2px solid var(--ink);outline-offset:2px}
.settlement-results>header{padding-bottom:12px}
.table-actions{justify-content:flex-end;padding-top:4px;padding-bottom:16px}
.table-actions .table-search{margin-right:auto}
.table-actions .table-tools{margin-left:auto}
.table-actions>button{margin-left:0;height:38px}
.table-actions .table-search input{height:38px}
.table-download{position:relative;font-size:12px;flex-shrink:0}
.table-download>summary{display:flex;align-items:center;gap:8px;height:38px;padding:8px 12px;border:1px solid var(--line);border-radius:6px;background:var(--white);cursor:pointer;list-style:none;white-space:nowrap}
.table-download>summary::-webkit-details-marker{display:none}
.table-download>summary svg{width:16px;height:16px;fill:none;stroke:currentColor;stroke-width:1.5}
.table-download[open]>summary,.table-download>summary:hover{background:var(--ws-hover)}
.table-download-options{position:absolute;top:calc(100% + 6px);right:0;z-index:20;min-width:204px;padding:6px;background:var(--white);border:1px solid var(--line);border-radius:8px;box-shadow:0 8px 24px #0003}
.table-download-options button{display:flex;align-items:center;justify-content:space-between;gap:24px;width:100%;border:0;border-radius:5px;padding:12px;background:transparent;text-align:left;white-space:nowrap}
.table-download-options button:hover{background:var(--ws-hover)}
.table-download-options small,.profit-coming-soon{font-size:10px;color:var(--muted)}
@media(max-width:720px){.table-actions{gap:8px}.table-actions .table-search{flex-basis:100%}.table-actions .table-tools{margin-left:0;justify-content:flex-start;flex:1}.table-actions>button{margin-left:auto}}

/* Native modal keeps the table in context while isolating display settings. */
.column-panel,.column-editor{box-sizing:border-box;margin:auto;padding:0;color:var(--ink);background:var(--white);border:1px solid var(--ws-hover-edge,var(--line));border-radius:16px;font:14px/1.5 Pretendard,sans-serif;letter-spacing:-.025em;box-shadow:0 28px 100px #0006}
.column-panel{position:fixed;inset:0;width:1120px;max-width:calc(100vw - 48px);height:min(812px,calc(100dvh - 48px));max-height:calc(100dvh - 48px);overflow:hidden;display:none}
.column-panel[open]{display:flex;flex-direction:column}
.column-panel::backdrop{background:#0009;backdrop-filter:blur(6px)}
.column-panel *,.column-editor *{box-sizing:border-box}
.column-panel .sr-only,.column-editor .sr-only{position:absolute;width:1px;height:1px;padding:0;margin:-1px;overflow:hidden;clip:rect(0,0,0,0);white-space:nowrap;border:0}
.column-panel h2,.column-editor h2,.column-panel h3,.column-editor h3,.column-panel p,.column-editor p{margin:0}
.column-panel button,.column-editor button,.column-panel input,.column-editor input{font:inherit;color:inherit}
.column-panel button,.column-editor button{border:1px solid var(--line);border-radius:8px;background:transparent;cursor:pointer;min-height:36px;padding:8px 12px}
.column-panel button:hover:not(:disabled),.column-editor button:hover:not(:disabled){background:var(--accent-bg)}
.column-panel :focus-visible,.column-editor :focus-visible{outline:2px solid var(--ink);outline-offset:-2px}
.column-panel [hidden],.column-editor [hidden]{display:none}
.column-panel>header,.column-editor header{display:flex;align-items:center;justify-content:space-between;gap:16px;padding:18px 24px;border-bottom:1px solid var(--line);flex:none}
.column-panel h2,.column-editor h2{font-size:18px;font-weight:600}
.column-panel h3,.column-editor h3{font-size:13px;font-weight:500;color:var(--muted)}
.column-panel .column-icon,.column-editor .column-icon{display:grid;place-items:center;width:32px;min-height:32px;padding:6px;flex:none}
.column-icon svg{width:18px;height:18px;fill:none;stroke:currentColor;stroke-width:1.5;stroke-linecap:round;stroke-linejoin:round}
.column-panel>header>.column-icon,.column-editor header>.column-icon{border:0;width:36px;min-height:36px}
.column-panel-layout{display:grid;grid-template-columns:240px minmax(0,1fr);grid-template-rows:minmax(0,1fr);min-height:0;flex:1;overflow:hidden;overscroll-behavior:contain}
.column-panel-layout>aside{padding:24px 16px;background:var(--bg);border-right:1px solid var(--line);min-width:0;overflow-y:auto}
.column-panel [data-presets]{display:grid;gap:8px;margin:20px 0}
.column-preset{display:flex;align-items:center;gap:6px;min-width:0}
.column-preset>[data-preset]{border:1px solid transparent;display:flex;align-items:center;gap:8px;min-height:40px;min-width:0;flex:1;text-align:left;padding:8px}
.column-preset>[data-preset]>span:last-child{overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
.column-preset [aria-pressed=true]{font-weight:600;background:var(--accent-bg);border-color:var(--ws-hover-edge,var(--line))}
.column-check{width:16px;flex:none;text-align:center}
.column-panel .column-new{width:100%;font-size:12px;background:var(--white);min-height:40px}
.column-panel [data-delete-prompt]{font-size:12px;margin-top:12px}
.column-panel [data-delete-prompt]:empty{display:none}
.column-panel [data-delete-prompt]>div{display:flex;justify-content:flex-end;gap:6px;margin-top:8px}
.column-current{min-width:0;min-height:0;display:flex;flex-direction:column}
.column-current-title{height:60px;padding:12px 24px;display:flex;align-items:center;justify-content:space-between;gap:8px;border-bottom:1px solid var(--line);flex:none}
.column-current-title strong{font-size:15px;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
.column-current-title button{font-size:12px;white-space:nowrap;min-height:32px;padding:6px 10px}
.column-lists{display:grid;grid-template-columns:1fr 1fr;min-height:0;flex:1}
.column-lists>section{min-width:0;min-height:0;display:flex;flex-direction:column;padding:0 8px}
.column-lists>section+section{border-left:1px solid var(--line);background:var(--bg)}
.column-lists h3{height:52px;display:flex;align-items:center;justify-content:space-between;gap:8px;padding:12px 16px;flex:none}
.column-lists h3 span{font-size:12px;font-variant-numeric:tabular-nums}
.column-lists h3 [data-all]{font-size:11px;min-height:26px;padding:2px 8px;margin-left:auto}
.column-lists ul{flex:1;min-height:0;overflow:auto;overscroll-behavior:contain;list-style:none;margin:0;padding:0 16px 16px;scrollbar-width:thin}
.column-lists li{position:relative;min-height:42px;display:flex;align-items:center;gap:8px;border:1px solid var(--line);border-radius:8px;padding:4px 10px;margin:0 0 8px;background:var(--white);font-size:13px}
.column-lists li:has(input:checked){border-color:var(--ws-hover-edge,var(--line));background:color-mix(in srgb,var(--ink) 3%,var(--white))}
.column-lists li:last-child{margin-bottom:0}
.column-lists label{display:flex;align-items:center;gap:12px;min-height:30px;min-width:0;flex:1;cursor:pointer}
.column-lists label span{overflow-wrap:anywhere}
.column-lists input{width:18px;height:18px;margin:0;accent-color:var(--ink);flex:none}
.column-panel .column-handle,.column-editor .column-handle{display:grid;place-items:center;padding:0;width:28px;min-height:30px;border:0;cursor:grab;touch-action:none;color:var(--muted);flex:none;user-select:none}
.column-handle svg{width:16px;height:20px;pointer-events:none}
.column-lists .is-dragging{opacity:.5}
.column-lists .is-drop-before:before,.column-lists .is-drop-after:after{content:'';position:absolute;left:0;right:0;height:2px;background:var(--ink)}
.column-lists .is-drop-before:before{top:-5px}.column-lists .is-drop-after:after{bottom:-5px}
.column-drag-label{position:fixed;pointer-events:none;z-index:5;padding:8px 12px;border:1px solid var(--ink);border-radius:8px;background:var(--white);box-shadow:0 4px 12px #0003;font-size:13px}
.column-lists .column-empty{display:block;text-align:center;border:0;background:transparent;color:var(--muted);padding:40px 8px;font-size:13px}
.column-panel>footer{display:flex;align-items:center;justify-content:space-between;gap:20px;border-top:1px solid var(--line);padding:16px 24px;flex:none}
.column-panel>footer p{color:var(--muted);font-size:12px;line-height:1.6;word-break:keep-all}
.column-panel .column-done,.column-editor [data-save]{background:var(--ink);color:var(--white);border-color:var(--ink);min-width:88px;min-height:40px}
.column-panel .column-done:hover,.column-editor [data-save]:hover{background:var(--ink);color:var(--white);opacity:.85}
.column-panel .column-error,.column-editor .column-error{color:var(--sales-red,#bf3346);font-size:12px;padding:0 24px 12px}
.column-error:empty{display:none}
.column-editor{position:fixed;inset:0;width:min(920px,calc(100vw - 48px));max-height:calc(100dvh - 48px);overflow:hidden}
.column-editor::backdrop{background:#0008;backdrop-filter:blur(4px)}
.column-editor form{margin:0;display:flex;flex-direction:column;max-height:calc(100dvh - 50px)}
.column-editor-content{display:flex;flex-direction:column;padding:24px;min-height:0;overflow:auto}
.column-name{display:grid;gap:10px;margin-bottom:24px;font-size:14px}
.column-name input{width:100%;height:42px;padding:10px 12px;border:1px solid var(--line);border-radius:8px;background:var(--bg);outline-offset:2px}
.column-editor .column-lists{border:1px solid var(--line);border-radius:10px;min-height:160px;overflow:hidden}
.column-editor .column-lists ul{height:min(480px,calc(100dvh - 340px));flex:auto}
.column-editor .column-error{padding:12px 0 0}
.column-editor footer{display:flex;justify-content:flex-end;gap:8px;border-top:1px solid var(--line);padding:16px 24px;flex:none}
@media(max-height:800px) and (min-width:721px){
 .column-panel>header,.column-editor header{padding:12px 24px}
 .column-panel>footer,.column-editor footer{padding:12px 24px}
 .column-current-title{height:52px}.column-lists h3{height:44px}
 .column-lists li{min-height:36px;padding-block:2px;margin-bottom:6px}
 .column-lists ul{padding-bottom:12px}
}
@media(max-width:720px){
 .table-tools{justify-content:flex-end;width:auto}.table-tools>button{max-width:190px}
 .table-actions{padding:12px 16px;flex-wrap:wrap}.table-search{flex:1;min-width:150px}.table-search input{width:100%}
 .column-panel{width:calc(100vw - 24px);max-width:none;height:calc(100dvh - 24px);max-height:calc(100dvh - 24px);border-radius:12px}
 .column-panel-layout{display:block;overflow-y:auto}
 .column-panel-layout>aside{border-right:0;border-bottom:1px solid var(--line);padding:16px}
 .column-panel [data-presets]{display:grid;grid-template-columns:1fr 1fr;gap:8px;margin:12px 0}
 .column-preset>.column-icon{width:28px;min-height:32px;padding:4px}
 .column-preset{gap:2px}.column-preset>[data-preset]{padding:6px 2px;gap:2px;font-size:12px}
 .column-panel .column-new{width:100%}
 .column-current-title{padding:12px 16px}
 .column-panel .column-lists,.column-editor .column-lists{display:block}
 .column-lists>section{padding:0}.column-lists>section+section{border-left:0;border-top:1px solid var(--line)}
 .column-panel .column-lists ul,.column-editor .column-lists ul{height:auto;max-height:none;overflow:visible;padding:0 16px 16px}
 .column-lists h3{padding:12px 16px;height:48px}
 .column-panel>header,.column-panel>footer,.column-editor header,.column-editor footer{padding:12px 16px}
 .column-panel h2,.column-editor h2{font-size:16px}
 .column-panel>footer{gap:12px}.column-panel>footer p{font-size:11px}
 .column-panel .column-done{min-width:60px}
 .column-editor{width:calc(100vw - 24px);max-height:calc(100dvh - 24px)}
 .column-editor form{max-height:calc(100dvh - 26px)}.column-editor-content{padding:16px}
 .column-editor .column-lists{flex:none}.column-name{margin-bottom:16px}
 .table-actions{display:grid;grid-template-columns:minmax(0,1fr) minmax(0,1fr)}
 .table-actions .table-search{grid-column:1/-1;width:100%;min-width:0}.table-actions>.table-tools{display:contents}
 .table-actions .table-tools>button{grid-column:1;width:100%;max-width:none;justify-content:center;padding:8px}
 .table-actions .sales-page-size{grid-column:2;min-width:0}.table-actions .sales-page-size select{width:100%}
 .table-actions>button{grid-column:1/-1;justify-self:end;margin:0}
 .table-actions>.table-download{grid-column:1}.table-download>summary{justify-content:center}.table-actions>button[data-profit-notify]{grid-column:2;justify-self:stretch;gap:5px;padding:8px 6px}.profit-coming-soon{font-size:9px}.table-download-options{right:auto;left:0}
}
img.settlement-product-icon{object-fit:cover;padding:0;display:block}.product-detail p[role=status]{margin:0;padding:8px 0 4px}
/* 이익현황: 계산 설정과 손실 표시 */
.profit-loss{color:var(--sales-red,#d64545)}
.profit-settings{margin:24px 0;padding:20px;background:var(--white);border:1px solid var(--line);border-radius:10px}
.profit-settings h2{font-size:16px;font-weight:600;margin:0 0 8px}.profit-settings h2 span{margin-left:8px;font-size:13px;font-weight:500;color:var(--muted,#767676)}
.profit-settings p,.profit-settings li{font-size:13px;line-height:1.4;color:var(--muted,#767676);margin:0}
.profit-settings ul{list-style:none;margin:0 0 12px;padding:0;display:grid;gap:8px}.profit-settings li strong{display:inline-block;min-width:72px;color:var(--ink);font-weight:600}
.profit-settings form{display:flex;flex-wrap:wrap;align-items:flex-end;gap:12px 16px;margin:16px 0 8px}
.profit-settings label{display:grid;gap:4px;font-size:12px;color:var(--ink)}
.profit-field{display:flex;align-items:center;gap:4px}.profit-field input{width:104px;min-height:36px;padding:8px 12px;border:1px solid var(--line);border-radius:6px;background:var(--white);color:var(--ink);font:inherit;font-size:13px;text-align:right;font-variant-numeric:tabular-nums}
.profit-field input:focus-visible{outline:2px solid var(--ink);outline-offset:1px}.profit-field em{font-style:normal;font-size:12px;color:var(--muted,#767676)}
.profit-settings form button{min-height:36px;padding:8px 20px;border:1px solid var(--ink);border-radius:6px;background:var(--ink);color:var(--white);font-size:13px;font-weight:500}
.profit-settings form button:disabled{opacity:.5}.profit-note{font-size:12px}
.profit-results th[title]{cursor:help}
@media(max-width:720px){.profit-settings{padding:16px}.profit-settings label{flex:1 1 140px}.profit-field input{width:100%}.profit-settings form button{width:100%}}
/* Phone width: the comparison period and the data-range note each get their own row instead of a broken period and a cut-off note. */
@container sales-view (max-width:660px){.sales-summary-meta{flex-direction:column;align-items:flex-start;gap:8px}.sales-summary-meta>span:first-child{white-space:nowrap}.sales-summary-meta .settlement-demo{white-space:normal;line-height:1.5;max-width:100%}}

/* Long product labels must not push every profit metric beyond the viewport. */
.profit-results .sales-products-table>thead>tr>th:last-child{position:static;box-shadow:none;text-align:right}
.profit-results .settlement-product strong{white-space:normal;overflow-wrap:anywhere;min-width:180px;max-width:236px;line-height:1.5}
.profit-results .settlement-product small{white-space:normal;line-height:1.5}
.profit-results .sales-products-table>tbody>tr:hover>td{background:var(--ws-hover)}
.profit-results .settlement-number{min-width:112px}
.profit-settings h2{display:flex;align-items:baseline;flex-wrap:wrap;gap:6px 12px}
.profit-settings h2 span{margin-left:0}
.profit-settings li{display:grid;grid-template-columns:80px minmax(0,1fr);gap:12px;align-items:start}
.profit-settings li span{overflow-wrap:anywhere}
@media(max-width:720px){
  .profit-results .settlement-product strong{min-width:120px;max-width:136px;font-size:12px}
  .profit-settings li{grid-template-columns:1fr;gap:4px}
  .table-actions>button{justify-content:center;justify-self:stretch;width:100%}
}
/* Product type is a registered status, never an editable or inferred value here. */
.product-type{display:inline-flex;align-items:center;gap:5px;padding:4px 8px;border:1px solid var(--ws-hover-edge,var(--line));border-radius:5px;font-size:12px;font-weight:500;white-space:nowrap;background:var(--bg)}
.product-type.needs-check{color:var(--sales-yellow);border-color:color-mix(in srgb,var(--sales-yellow) 45%,transparent);background:var(--sales-yellow-bg);cursor:help}
.product-type.needs-check>span{display:inline-grid;place-items:center;border:1px solid currentColor;border-radius:50%;width:13px;height:13px;font-size:10px}
.product-type-notice{display:flex;flex-wrap:wrap;align-items:baseline;gap:6px 14px;margin:0;padding:12px 24px;background:var(--sales-yellow-bg);border-bottom:1px solid var(--line);font-size:12px;color:var(--muted)}
.product-type-notice strong{color:var(--sales-yellow);font-weight:600}.product-type-notice[hidden]{display:none}
.settlement-results .sales-product-row>.product-action,.settlement-results .sales-products-table>thead>tr>th:last-child{padding-left:8px;padding-right:8px}
@media(max-width:720px){.product-type-notice{padding:12px 16px}}

/* Profit uses the same compact cards and table tools as sales performance. */
.profit-controls{display:flex;align-items:center;justify-content:space-between;gap:16px;margin:0 0 20px;flex-wrap:wrap}
.profit-controls>[data-profit-settings]{display:inline-flex;align-items:center;gap:8px;margin-left:auto;padding:8px 12px;min-height:36px;background:var(--white);border:1px solid var(--line);border-radius:6px;font-size:12px}
.profit-controls svg{width:16px;height:16px;fill:none;stroke:currentColor;stroke-width:1.2}
.profit-controls button:hover{background:var(--ws-hover);border-color:var(--ws-hover-edge)}
.profit-toggles{display:flex;align-items:center;flex-wrap:wrap;gap:8px 20px}
.profit-toggles>button{display:inline-flex;align-items:center;gap:8px;min-height:36px;padding:0;font-size:12px}
.profit-toggles i{display:block;width:28px;height:16px;border-radius:10px;background:var(--line);position:relative}
.profit-toggles i:after{content:'';position:absolute;top:3px;left:3px;width:10px;height:10px;border-radius:50%;background:var(--muted)}
.profit-toggles [aria-pressed=true] i{background:var(--ink)}.profit-toggles [aria-pressed=true] i:after{left:15px;background:var(--white)}
.profit-toggles [aria-pressed=mixed] i:after{left:9px}.profit-toggles small{font-size:10px;color:var(--muted)}
.profit-summary .settlement-summary{grid-template-columns:repeat(4,minmax(0,1fr));margin-bottom:24px}
.profit-summary .sales-kpi{min-height:140px}.profit-kpi-foot{margin:12px 0 0;font-size:12px;color:var(--muted)}
.profit-summary .sales-kpi>strong.profit-unknown{font-size:18px;color:var(--muted)}
.profit-summary .sales-kpi>strong.profit-loss{color:var(--sales-red)}
.profit-companies{border:1px solid var(--line);border-radius:10px;background:var(--white);margin-bottom:24px;overflow:hidden}
.profit-companies table{border-collapse:collapse;width:100%;min-width:700px;font-size:13px;font-variant-numeric:tabular-nums}
.profit-companies th,.profit-companies td{text-align:right;padding:12px 20px;border-bottom:1px solid var(--line);font-weight:400}
.profit-companies thead th{font-size:12px;background:var(--bg);color:var(--muted)}
.profit-companies th:first-child{text-align:left}.profit-companies tbody th{font-weight:600}
.profit-companies tbody tr:last-child>*{border:0}.profit-companies tbody tr:hover{background:var(--ws-hover)}
.profit-companies tbody th{font-size:13px;color:var(--ink);background:transparent}.profit-companies tbody td{color:var(--ink)}.profit-companies tbody td.profit-loss{color:var(--sales-red)}
.profit-companies td{font-size:16px;font-weight:500}.profit-companies small{font-size:11px;color:var(--muted);margin-left:3px;font-weight:400}
.profit-companies th>small{display:block;margin:4px 0 0}
.profit-results th button{white-space:nowrap}.profit-need{color:var(--muted);font-size:12px}
.profit-table-notice{display:flex;align-items:center;gap:6px;padding:8px 24px;font-size:12px;color:var(--muted);border-top:1px solid var(--line);background:var(--bg)}
.profit-help{display:inline-flex;align-items:center;justify-content:center;vertical-align:middle;width:14px;height:14px;flex:none;border:1px solid var(--muted);border-radius:50%;color:var(--muted);font-size:10px;font-weight:400;cursor:help;position:relative}
.profit-help>[role=tooltip]{display:none;position:absolute;top:22px;left:-12px;width:240px;max-width:75vw;padding:12px;border:1px solid var(--line);border-radius:8px;background:var(--white);color:var(--ink);font-size:12px;font-weight:400;white-space:normal;text-align:left;line-height:1.6;z-index:20;box-shadow:0 8px 24px #0002}
.profit-help:hover>[role=tooltip],.profit-help:focus>[role=tooltip]{display:block}
.profit-companies th:last-child .profit-help>[role=tooltip]{left:auto;right:0}
.profit-results footer .profit-help>[role=tooltip]{top:auto;bottom:22px}
.profit-settings-dialog{width:min(640px,calc(100vw - 32px));max-height:calc(100dvh - 48px);overflow:auto;margin:auto;padding:0;border:1px solid var(--ws-hover-edge,var(--line));border-radius:14px;background:var(--white);color:var(--ink);box-shadow:0 24px 80px #0006;font:13px/1.5 Pretendard,sans-serif}
.profit-settings-dialog::backdrop{background:#0008;backdrop-filter:blur(5px)}
.profit-settings-dialog>header{display:flex;align-items:center;justify-content:space-between;padding:20px 24px;border-bottom:1px solid var(--line)}
.profit-settings-dialog h2{font-size:18px;font-weight:600;margin:0}.profit-settings-dialog header span{display:block;color:var(--muted);font-size:12px;margin-top:4px}
.profit-settings-dialog [data-profit-close]{display:grid;place-items:center;width:32px;height:32px;border-radius:6px;color:var(--muted)}
.profit-settings-dialog [data-profit-close]:hover{background:var(--ws-hover)}
.profit-settings-dialog svg{width:20px;height:20px;fill:none;stroke:currentColor;stroke-width:1.5}
.profit-settings-selectors{display:grid;grid-template-columns:1fr 1fr;gap:16px;padding:20px 24px;border-bottom:1px solid var(--line)}
.profit-settings-selectors label{display:grid;gap:6px;font-size:12px;color:var(--muted)}
.profit-settings-selectors select{width:100%;min-width:0;height:38px;padding:8px 10px;border:1px solid var(--line);border-radius:6px;background:var(--bg);color:var(--ink);font:inherit;font-size:13px}
.profit-settings-selectors select:disabled{opacity:.7}
.profit-settings-form{padding:20px 24px 24px}.profit-settings-status{display:flex;align-items:center;justify-content:space-between;font-size:14px;font-weight:600;margin-bottom:20px}
.profit-settings-status>span{font-size:11px;font-weight:400;color:var(--muted);border:1px solid var(--line);border-radius:4px;padding:2px 7px}
.profit-settings-fields{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:20px 24px}
.profit-setting-field{display:flex;flex-direction:column;gap:8px;min-width:0}.profit-setting-field>span:first-child{font-size:12px}
.profit-setting-input{display:flex;align-items:center;gap:8px}.profit-setting-input input{width:100%;min-width:0;height:38px;padding:8px 10px;border:1px solid var(--line);border-radius:6px;background:var(--bg);color:var(--ink);font:inherit;text-align:right;font-variant-numeric:tabular-nums}
.profit-setting-input em{font-style:normal;min-width:12px;font-size:12px;color:var(--muted)}.profit-setting-field b{font-weight:500;padding:8px 0;border-bottom:1px solid var(--line)}
.profit-settings-form footer{display:flex;align-items:center;justify-content:space-between;gap:16px;border-top:1px solid var(--line);padding-top:20px;margin-top:24px}
.profit-settings-form footer p{font-size:12px;color:var(--muted);margin:0;max-width:400px}
.profit-settings-form button[type=submit]{flex:none;min-height:36px;min-width:80px;padding:8px 16px;border:1px solid var(--ink);border-radius:6px;background:var(--ink);color:var(--white);font:inherit;font-size:12px}
.profit-settings-form button:disabled{opacity:.5;cursor:not-allowed}
.profit-settings-dialog :focus-visible{outline:2px solid var(--ink);outline-offset:3px}
.profit-setting-field:nth-child(even) .profit-help>[role=tooltip]{left:auto;right:0}
html[data-theme=dark] .profit-settings-dialog{color-scheme:dark}
@container sales-view (max-width:800px){.profit-summary .settlement-summary{grid-template-columns:repeat(2,minmax(0,1fr))}.profit-summary .sales-kpi:first-child{grid-column:auto}.profit-toggles{gap:4px 16px}}
@container sales-view (max-width:500px){.profit-summary .settlement-summary{grid-template-columns:1fr}.profit-summary .sales-kpi{min-height:0;padding:16px}.profit-summary .sales-kpi strong{font-size:23px}.profit-kpi-foot{margin-top:8px}.profit-controls{gap:12px}.profit-toggles{display:grid;grid-template-columns:1fr 1fr;gap:4px 12px;position:relative}.profit-toggles .profit-help{position:static}.profit-toggles .profit-help>[role=tooltip]{left:0;top:100%;max-width:100%}.profit-table-notice{padding:8px 16px;position:relative}.profit-table-notice .profit-help{position:static}.profit-table-notice [role=tooltip]{left:16px;top:32px}.profit-summary .sales-kpi{position:relative}.profit-summary .profit-help{position:static}.profit-summary [role=tooltip]{left:16px;top:44px;max-width:calc(100% - 32px)}}
@media(max-width:560px){.profit-settings-dialog>header,.profit-settings-selectors,.profit-settings-form{padding:16px}.profit-settings-selectors{gap:12px}.profit-settings-fields{grid-template-columns:1fr;gap:16px}.profit-setting-field{position:relative}.profit-setting-field .profit-help{position:static}.profit-setting-field .profit-help>[role=tooltip]{left:0;right:auto;top:22px;max-width:100%}.profit-settings-form footer{align-items:stretch;flex-direction:column}.profit-settings-form button[type=submit]{align-self:flex-end}}

/* Profit cards: a consistent grid beside an always-visible settings panel. */
.profit-exclusions{margin:20px 0 24px}.profit-exclusions>header{display:flex;align-items:center;gap:8px;margin-bottom:12px}
.profit-exclusions h2,.profit-card-section h2,.profit-settings-panel h2{margin:0;font-size:14px;font-weight:600}
.profit-exclusion-grid{display:flex;align-items:center;flex-wrap:wrap;gap:8px 32px}
.profit-exclusion-card{display:flex;align-items:center;gap:12px;min-height:36px;font-size:12px;position:relative;word-break:keep-all}

.settlement-view .profit-state-switch{display:inline-flex;align-items:center;gap:6px;min-height:32px;padding:2px 0;color:var(--sales-red);font-size:11px;flex:none}
.profit-state-switch b{font-weight:600;min-width:24px}.profit-state-switch i{width:30px;height:18px;background:var(--sales-red-bg);border:1px solid currentColor;border-radius:12px;position:relative}
.profit-state-switch i:after{content:'';position:absolute;width:10px;height:10px;left:3px;top:3px;background:currentColor;border-radius:50%;transition:left .15s}
.settlement-view .profit-state-switch[aria-pressed=true]{color:var(--sales-green)}.profit-state-switch[aria-pressed=true] i{background:var(--sales-green-bg)}.profit-state-switch[aria-pressed=true] i:after{left:15px}
.settlement-view .profit-state-switch[aria-pressed=mixed]{color:var(--sales-yellow)}.profit-state-switch[aria-pressed=mixed] i{background:var(--sales-yellow-bg)}.profit-state-switch[aria-pressed=mixed] i:after{left:9px}
.settlement-view .profit-state-switch:disabled{color:var(--muted);cursor:not-allowed}.profit-state-switch:disabled i{background:var(--line)}
.workspace-frame .settlement-view .profit-state-switch:hover:not(:disabled){background:transparent;box-shadow:none;filter:brightness(1.15)}.profit-state-switch:focus-visible{outline:2px solid currentColor;outline-offset:4px;border-radius:4px}
.profit-companies table{table-layout:fixed}.profit-companies thead th{height:44px}.profit-companies tbody tr{height:68px}.profit-companies th,.profit-companies td{width:20%;vertical-align:middle}
.profit-workbench{display:grid;grid-template-columns:1fr;align-items:start;gap:24px;margin:24px 0}
.profit-settings-panel.is-page{border-top:0;padding-top:0}.profit-seller-pick{grid-template-columns:minmax(200px,280px);padding:0;border:0;margin:0 0 16px}.profit-drop-note{margin:16px 0 0;font-size:12px;line-height:1.5;color:var(--muted)}.profit-drop-note a,.profit-formula-notice a{color:inherit;text-decoration:underline;text-underline-offset:2px}
.profit-main{min-width:0}.profit-main .profit-exclusions{margin:24px 0 0}.profit-exclusions .profit-scope{margin-left:auto}.profit-card-section>header{display:flex;align-items:center;justify-content:space-between;gap:12px;min-height:32px;margin-bottom:12px}
.profit-scope{font-size:11px;color:var(--muted)}
.profit-card-grid{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));grid-auto-rows:1fr;gap:12px}
.profit-metric-card{min-width:0;min-height:136px;padding:16px;background:var(--white);border:1px solid var(--line);border-radius:10px;display:flex;flex-direction:column;position:relative}
.profit-metric-card>header{display:flex;align-items:start;justify-content:space-between;gap:8px;min-height:32px}.profit-metric-card h3{margin:0;font-size:12px;font-weight:500;line-height:1.5}
.profit-card-group{font-size:10px;color:var(--muted);white-space:nowrap}.profit-metric-card strong{font-size:22px;font-weight:600;line-height:1.4;letter-spacing:-.5px;font-variant-numeric:tabular-nums;white-space:nowrap;margin:8px 0 12px}
.profit-metric-card strong small{font-size:11px;color:var(--muted);font-weight:400;margin-left:4px}.profit-metric-card strong.profit-unknown{font-size:17px;color:var(--muted)}
.profit-card-caption{margin-top:auto;font-size:11px;color:var(--muted)}.profit-metric-card.is-result{border-top:2px solid var(--sales-green)}.profit-metric-card .profit-loss{color:var(--sales-red)}
.profit-metric-card .profit-help{position:static}.profit-metric-card [role=tooltip]{left:12px;top:44px;max-width:calc(100% - 24px)}
.profit-settings-panel{min-width:0;display:grid;grid-template-columns:1fr minmax(280px,440px);gap:16px 24px;border-top:1px solid var(--line);padding-top:24px}.profit-settings-panel>[data-profit-editor]{grid-column:1/-1}
.profit-settings-panel>header{display:flex;align-items:center;gap:12px;min-height:32px}.profit-settings-panel>header>span{font-size:11px;color:var(--muted)}
.profit-settings-panel .profit-settings-selectors{padding:0;gap:12px;border:0;margin:0}.profit-settings-panel .profit-settings-form{padding:0}
.profit-settings-panel .profit-settings-fields{grid-template-columns:repeat(4,minmax(0,1fr));grid-auto-rows:1fr;gap:12px}.profit-settings-panel .profit-settings-status{margin-bottom:12px;font-size:12px}
.profit-settings-panel .profit-setting-field{display:flex;flex-direction:column;align-items:stretch;gap:8px;min-height:106px;padding:12px;background:var(--white);border:1px solid var(--line);border-radius:10px;position:relative}.profit-settings-panel .profit-setting-field>span:first-child{font-size:12px;min-height:36px}.profit-settings-panel .profit-setting-input{gap:4px;margin-top:auto}.profit-settings-panel .profit-setting-field b{text-align:right;min-height:38px;margin-top:auto;border:0}
.profit-settings-panel .profit-setting-field .profit-help{position:static}.profit-settings-panel .profit-setting-field .profit-help>[role=tooltip]{left:12px;right:auto;top:40px;max-width:calc(100% - 24px)}
.profit-settings-panel .profit-settings-form footer{margin-top:16px;padding-top:16px;align-items:center;flex-direction:row;gap:16px}.profit-settings-panel footer p{font-size:11px;line-height:1.5}.profit-settings-panel button[type=submit]{align-self:flex-end}
.profit-settings-panel :focus-visible{outline:2px solid var(--ink);outline-offset:3px}
.profit-exclusion-card .profit-help{position:static}.profit-exclusion-card [role=tooltip]{left:12px;top:48px;max-width:calc(100% - 24px)}
@container sales-view (min-width:1500px){.profit-card-grid{grid-template-columns:repeat(6,minmax(0,1fr))}.profit-metric-card{min-height:148px;padding:20px}.profit-settings-panel .profit-settings-fields{grid-template-columns:repeat(7,minmax(0,1fr))}}

@container sales-view (max-width:1050px){.profit-card-grid{grid-template-columns:repeat(3,minmax(0,1fr))}.profit-settings-panel .profit-settings-fields{grid-template-columns:repeat(3,minmax(0,1fr))}}
@container sales-view (max-width:800px){.profit-settings-panel .profit-settings-fields{grid-template-columns:repeat(2,minmax(0,1fr))}}
@container sales-view (max-width:600px){.profit-card-grid{grid-template-columns:repeat(2,minmax(0,1fr))}.profit-metric-card{padding:12px;min-height:136px}.profit-metric-card strong{font-size:18px}.profit-card-group{display:none}.profit-settings-panel .profit-settings-fields{grid-template-columns:1fr}.profit-card-section>header{align-items:start;flex-direction:column;gap:6px}.profit-companies th,.profit-companies td{padding:12px}.profit-exclusion-grid{gap:8px 24px}.profit-exclusion-card{gap:8px}.profit-settings-panel{grid-template-columns:1fr;gap:12px}.profit-exclusions>header{flex-wrap:wrap}.profit-exclusions .profit-scope{margin-left:0}}
@container sales-view (max-width:360px){.profit-card-grid{grid-template-columns:1fr}.profit-metric-card{min-height:128px}.profit-metric-card strong{font-size:23px}.profit-settings-panel .profit-settings-fields{grid-template-columns:1fr}.profit-settings-panel .profit-settings-form footer{flex-direction:column;align-items:stretch}}
@media(prefers-reduced-motion:reduce){.profit-state-switch i:after{transition:none}}

/* 2026-11-24 한규: 이익현황 표를 상품성과 표와 같은 앞 칸(순위 · 사진 · 상품유형)으로 — 첫 칸 고정은 없앤다. */
.profit-results.has-lead .settlement-product strong{min-width:200px}
.profit-results.has-lead th.product-center{font-weight:500}
.profit-formula-notice{margin:0 0 16px;border:1px solid var(--line);border-radius:8px;padding:12px 16px}
.profit-exclusions h2,.profit-card-section h2,.profit-settings-panel h2{font-size:16px}
.profit-settings-panel{grid-template-columns:1fr}.profit-settings-panel .profit-settings-selectors{grid-template-columns:minmax(200px,280px)}
.profit-settings-panel [data-profit-editor]>form+form{margin-top:24px;padding-top:24px;border-top:1px solid var(--line)}
.profit-settings-panel .profit-settings-status{font-size:14px}
/* 표 위 단추: 같은 높이 · 같은 간격 · 같은 화살표 */
.profit-results .table-actions{gap:8px;align-items:center}
.profit-results .table-actions>button[data-profit-notify]{display:inline-flex;align-items:center;height:38px;gap:8px}
.table-download>summary .table-columns-chevron{width:16px;height:16px}.table-download[open]>summary .table-columns-chevron{transform:rotate(180deg)}
/* 상품 표 맨 오른쪽 펼침 단추 칸: 열을 많이 켜 옆으로 넘칠 때 밑에 깔린 칸과 겹쳐 보이지 않게 경계를 긋고 자리를 넓힌다. */
.product-col-action{width:60px}
.settlement-results .sales-products-table>thead>tr>th:last-child,.sales-product-row>.product-action{min-width:60px;box-shadow:none}
.profit-results .sales-products-table>thead>tr>th:last-child{min-width:0;box-shadow:none}

/* 2026-11-24 한규: 표 머리의 위아래 화살표를 빼고 숫자와 머리 글자의 오른쪽 끝을 맞춘다 · 정렬 중인 칸만 밝게 · 정렬 법은 제목 옆에 한마디. */
.settlement-results th,.settlement-results th button{color:var(--muted)}
.settlement-results th[aria-sort=ascending] button,.settlement-results th[aria-sort=descending] button{color:var(--ink)}
.settlement-sort-hint{font-size:12px;color:var(--muted);margin-left:8px;white-space:nowrap}
/* 표 위 띠를 한 층으로: 제목 · 검색 · 단추가 같은 높이에(한규 "너무 두껍고"). */
.settlement-results>header{padding:14px 24px;gap:12px 24px;flex-wrap:wrap}
.settlement-results>header>div:first-child{flex-wrap:wrap;row-gap:4px}
.settlement-results>header>.table-actions{flex:1 1 560px;min-width:0;padding:0;border:0;background:none;gap:8px}
@container sales-view (max-width:900px){.settlement-sort-hint{display:none}}
/* 계산 설정 저장 꼬리표: 저장 대기 = 노랑 · 저장 완료 = 초록. */
.profit-settings-form footer p{margin-right:auto}
.profit-settings-form button[type=submit][data-save-state=pending]{color:var(--sales-yellow);background:var(--sales-yellow-bg);border-color:var(--sales-yellow)}
.profit-settings-form button[type=submit][data-save-state=saved]{color:var(--sales-green);background:var(--sales-green-bg);border-color:var(--sales-green);opacity:1;cursor:default}
/* 전체 탭의 계산 설정: 입력 칸 없이 판매처마다 저장됐는지만. */
.profit-settings-summary{display:flex;align-items:center;flex-wrap:wrap;gap:12px 24px;font-size:12px;color:var(--muted)}.profit-settings-summary p{margin:0}
.profit-settings-summary ul{display:flex;flex-wrap:wrap;gap:8px;list-style:none;margin:0;padding:0}.profit-settings-summary li{display:flex;align-items:center;gap:8px;padding:8px 12px;border:1px solid var(--line);border-radius:8px;background:var(--white);color:var(--ink)}
.profit-settings-summary b{font-weight:500;color:var(--muted)}.profit-settings-summary b[data-save-state=saved]{color:var(--sales-green)}
/* 판매성과 맨 위 알림 띠(한규 2026-11-24 "응, 띄워") — 상품성과 띠와 같은 모양, 표 밖이라 테두리만 둘러 줌 */
.sales-pending-notice{margin:0 0 16px;border:1px solid var(--line);border-radius:12px}

/* Option table: the option name on the left, every other column the same width and centred, header over its values
   (한규 2026-11-25 "너무 들쭉날쭉해 · 가운데 정렬을 하던가"). */
.settlement-results .sales-options-table{table-layout:fixed}
.sales-options-table col{width:auto}.sales-options-table col.product-col-name{width:20%}
.settlement-results .sales-options-table th:not(:first-child),.settlement-results .sales-options-table td:not(:first-child){text-align:center;padding-left:8px;padding-right:8px}
.sales-options-table td:first-child strong{display:block;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}

/* 2026-11-25: consistent table rhythm, scoped option detail, centred pagination. */
.settlement-results{overflow:clip;scroll-margin-top:16px}
.settlement-results .sales-daily-table{table-layout:fixed;min-width:1050px}
.sales-daily-table col{width:auto}.sales-daily-table col.product-col-name{width:164px}
.settlement-results .sales-daily-table th,.settlement-results .sales-daily-table td{padding-inline:20px}
.settlement-results>footer{display:grid;grid-template-columns:1fr auto 1fr;min-height:72px;position:relative}
.settlement-results>footer>.settlement-pagination{grid-column:2;margin:0;justify-content:center;gap:16px}
.settlement-pagination button{width:36px;height:36px;font-size:24px;display:grid;place-items:center}
.settlement-pagination>span{min-width:48px;text-align:center;font-variant-numeric:tabular-nums}
.table-period-total{grid-column:1;grid-row:1;white-space:nowrap}
.table-guide{display:flex;align-items:center;gap:16px;padding:8px 24px 12px;font-size:12px;color:var(--muted);position:relative}
.table-guide details>summary{cursor:pointer;list-style:none;display:flex;align-items:center;gap:6px}.table-guide summary::-webkit-details-marker{display:none}
.table-guide summary>span{display:grid;place-items:center;border:1px solid var(--muted);border-radius:50%;width:14px;height:14px;font-size:10px}
.table-guide details[open]>div{position:absolute;left:24px;top:38px;max-width:min(560px,calc(100% - 48px));padding:16px;background:var(--white);border:1px solid var(--line);border-radius:8px;color:var(--ink);z-index:12;box-shadow:0 8px 24px #0003;line-height:1.7;white-space:normal}.table-guide p{margin:0}.table-guide p+p{margin-top:8px}
.settlement-results .sales-product-row.is-open>td{background:var(--accent-bg);border:0}
.sales-product-row.is-open>td:first-child{box-shadow:inset 3px 0 var(--sales-green)}
.settlement-results .product-detail-row>td{background:var(--bg);border:0}
.product-detail{position:sticky;left:0;width:var(--table-visible-width,100%);max-width:var(--table-visible-width,100%);box-sizing:border-box;padding:12px 24px 20px;border:0}
.sales-options-scroll{overflow:auto;width:100%;max-width:100%;margin:0;border:0;border-radius:0;overscroll-behavior-x:contain}
.settlement-results .sales-options-table{width:100%;min-width:1020px;table-layout:fixed;border:0}
.sales-options-table col{width:auto}.sales-options-table col.product-col-name{width:14%}.sales-options-table col.product-col-change{width:14%}.sales-options-table col.product-col-trend{width:12%}
.settlement-results .sales-options-table th,.settlement-results .sales-options-table td{padding:12px;height:56px;border:0}
.settlement-results .sales-options-table th{height:44px;font-size:12px;font-weight:500}
.settlement-results .sales-options-table th:not(:first-child),.settlement-results .sales-options-table td:not(:first-child){padding-inline:8px;text-align:center}
.settlement-results .sales-options-table .sales-badge{font-size:11px;max-width:100%}
.settlement-results .sales-options-table .product-trend .sales-spark{width:112px;max-width:100%}
.table-floating-header{z-index:14;padding:0!important;container-type:normal;box-sizing:border-box;background:var(--bg);box-shadow:0 3px 8px #0003;border-bottom:1px solid var(--line)}
.table-floating-header[hidden]{display:none}.table-floating-clip{overflow:hidden;width:100%}
.table-floating-header table{border-collapse:collapse;table-layout:fixed;white-space:nowrap;min-width:0!important;font-size:12px}
.table-floating-header th{height:56px;padding:14px 12px;border:0;background:var(--bg);color:var(--muted);font-weight:500;box-sizing:border-box}
.table-floating-header th.settlement-number{text-align:right}.table-floating-header th.product-center{text-align:center}.table-floating-header .sales-daily-table th{padding-inline:20px;text-align:right}.table-floating-header .sales-daily-table th:first-child{text-align:left}
.table-floating-header th button{font:inherit;color:inherit;cursor:pointer}.table-floating-header th[aria-sort=ascending],.table-floating-header th[aria-sort=descending]{color:var(--ink)}
.table-floating-header .sales-options-table th:not(:first-child){text-align:center}
/* PC option names share the same centred alignment as their neighbouring metrics. */
@media(min-width:721px){
  .settlement-results .sales-options-table th:first-child,.settlement-results .sales-options-table td:first-child,.table-floating-header .sales-options-table th:first-child{text-align:center}
}
.table-floating-context{padding:8px 12px;font-size:12px;overflow:hidden;white-space:nowrap;text-overflow:ellipsis;background:var(--accent-bg)}
.table-floating-header :focus-visible{outline:2px solid var(--ink);outline-offset:3px}
@container sales-view (max-width:1200px){.settlement-results .sales-options-table th,.settlement-results .sales-options-table td{font-size:12px;padding-inline:8px}}

/* Profit: four equal columns, a readable calculation path, and day-by-day evidence. */
.profit-card-section>header h2{display:flex;align-items:center;gap:8px}
.profit-card-grid{grid-template-columns:repeat(4,minmax(0,1fr));gap:16px}
.profit-metric-card{padding:20px;min-height:176px;border-radius:12px}.profit-metric-card>header{min-height:24px}.profit-metric-card h3{font-size:13px}.profit-metric-card strong{font-size:25px;margin:8px 0 12px}
.profit-card-comparison{min-height:26px}.profit-comparison-empty{font-size:11px;color:var(--muted)}
.profit-card-trend{margin-top:12px;color:var(--muted);position:relative;min-height:74px;border-radius:4px;outline-offset:4px}.profit-card-trend.up{color:var(--sales-green)}.profit-card-trend.down{color:var(--sales-red)}
.profit-card-trend svg{display:block;width:100%;height:48px;overflow:visible}.profit-card-trend path{fill:none;stroke:currentColor;stroke-width:1.5;vector-effect:non-scaling-stroke}.profit-card-trend circle{fill:currentColor}
.profit-card-trend line{stroke:var(--muted);stroke-dasharray:3 3;stroke-width:1;vector-effect:non-scaling-stroke}.profit-card-trend line[hidden]{display:none}
.profit-card-trend output{display:block;margin-top:8px;font-size:11px;color:var(--muted);min-height:16px}.profit-card-trend-empty{display:flex;align-items:center;min-height:74px;margin-top:12px;font-size:11px;color:var(--muted)}
.profit-config-common>header,.profit-config-channels>header,.profit-config-channel>header{display:flex;align-items:center;justify-content:space-between;gap:16px;margin-bottom:16px}
.profit-config-common h3,.profit-config-channels h3{font-size:14px;margin:0;font-weight:600}.profit-config-common>header span,.profit-config-channels>header>span{font-size:12px;color:var(--muted)}
.profit-config-common>header>div{display:flex;align-items:center;gap:12px;flex-wrap:wrap}
.profit-settings-panel .profit-config-common .profit-settings-fields{grid-template-columns:repeat(3,minmax(0,1fr))}
.profit-config-common .profit-settings-form,.profit-channel-grid.is-single{max-width:1120px}
.profit-channel-tabs{margin-bottom:20px}
.profit-settings-panel .profit-setting-field{padding:16px;min-height:104px}.profit-settings-panel .profit-setting-field>span:first-child{min-height:24px}
.profit-config-channels{margin-top:24px;padding-top:24px;border-top:1px solid var(--line)}
.profit-channel-grid{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:24px}.profit-config-channel{min-width:0}.profit-config-channel+.profit-config-channel{border-left:0;padding-left:0}
.profit-settings-panel .profit-config-channel .profit-settings-fields{grid-template-columns:1fr;gap:12px}
.profit-config-state{font-size:11px;color:var(--muted)}.profit-revenue-basis{display:flex;align-items:center;flex-wrap:wrap;gap:6px;font-size:11px;min-height:40px;margin:-4px 0 12px;color:var(--muted)}.profit-revenue-basis strong{font-weight:400;color:var(--ink)}
.profit-not-applicable{display:flex;align-items:center;justify-content:space-between;gap:12px;height:104px;margin-top:12px;padding:16px;font-size:12px;color:var(--muted);border-bottom:1px dashed var(--line)}
.profit-common-values{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:16px;margin:0;padding:16px 0;border-block:1px solid var(--line)}.profit-common-values div{display:flex;align-items:center;justify-content:space-between;gap:8px;font-size:12px}.profit-common-values dt{color:var(--muted)}.profit-common-values dd{margin:0;font-weight:500}
.profit-common-link{font-size:12px;color:var(--ink);padding:8px 0}.profit-setting-conflict{display:flex;align-items:center;gap:8px;font-size:12px;color:var(--sales-yellow);margin-bottom:12px}
.profit-channel-grid.is-single{grid-template-columns:1fr}.profit-channel-grid.is-single .profit-settings-fields{grid-template-columns:repeat(auto-fit,minmax(min(100%,240px),1fr))}
.profit-readonly{font-size:11px;color:var(--muted)}
@container sales-view (min-width:1500px){.profit-card-grid{grid-template-columns:repeat(4,minmax(0,1fr))}.profit-metric-card{min-height:176px;padding:20px}}
@container sales-view (max-width:1100px){.profit-channel-grid{grid-template-columns:repeat(2,minmax(0,1fr));row-gap:24px}.profit-config-channel:nth-child(3){border-left:0;padding-left:0}.profit-common-values{grid-template-columns:repeat(2,minmax(0,1fr))}.profit-metric-card{padding:16px}.profit-metric-card strong{font-size:21px}}
@container sales-view (max-width:850px){.profit-card-grid{grid-template-columns:repeat(2,minmax(0,1fr))}.profit-settings-panel .profit-config-common .profit-settings-fields{grid-template-columns:repeat(2,minmax(0,1fr))}}
@container sales-view (max-width:600px){.table-period-total{grid-column:1/-1;grid-row:1;text-align:center}.settlement-results>footer{gap:12px;padding:16px}.settlement-results>footer>.settlement-pagination{grid-row:2;grid-column:1/-1}.product-detail{padding:16px}.product-detail>header{gap:12px}.product-detail h3>span{display:table;margin:8px 0 0}.table-guide{padding-inline:16px}.table-guide details[open]>div{left:16px;max-width:calc(100% - 32px)}.profit-channel-grid{grid-template-columns:1fr}.profit-config-channel+.profit-config-channel{border-left:0;padding-left:0;padding-top:20px;border-top:1px solid var(--line)}.profit-card-section>header{gap:12px}.profit-settings-panel .profit-config-common .profit-settings-fields{grid-template-columns:repeat(2,minmax(0,1fr))}.profit-channel-grid.is-single .profit-settings-fields{grid-template-columns:1fr}.profit-config-common>header{align-items:flex-start}.profit-common-values{grid-template-columns:1fr}.profit-metric-card{padding:16px;min-height:200px}.profit-metric-card strong{font-size:20px}}
@container sales-view (max-width:400px){.profit-card-grid{grid-template-columns:1fr}.profit-settings-panel .profit-config-common .profit-settings-fields{grid-template-columns:1fr}.profit-metric-card strong{font-size:25px}}
/* 이익현황 상세: 카드 [내역] · 최종 이익 내역 · 제외 사유 금액 · 상품 골라 보기 */
.profit-card-open{flex:none;height:24px;padding:0 8px;border:1px solid var(--line);border-radius:6px;background:transparent;color:var(--muted);font:inherit;font-size:12px;cursor:pointer}
.profit-card-open:hover,.profit-card-open[aria-pressed=true]{color:inherit;border-color:currentColor}
.profit-detail{margin-top:16px;padding:20px;background:var(--white);border:1px solid var(--line);border-radius:12px}
.profit-detail>header{display:flex;align-items:center;justify-content:space-between;gap:12px;margin-bottom:12px}.profit-detail h3{margin:0;font-size:14px;font-weight:600}
.profit-detail-scroll{overflow-x:auto}.profit-detail table{width:100%;min-width:560px;border-collapse:collapse;font-size:13px;font-variant-numeric:tabular-nums}
.profit-detail th,.profit-detail td{padding:8px 12px;border-bottom:1px solid var(--line);text-align:right;font-weight:400;white-space:nowrap}
.profit-detail tbody th{font-size:13px;color:inherit;background:transparent}.profit-detail thead th{background:transparent}.profit-detail th:first-child{text-align:left}.profit-detail thead th{font-size:12px;color:var(--muted)}.profit-detail td small{margin-left:2px;font-size:11px;color:var(--muted)}
.profit-detail tr.is-sum>*{font-weight:600}.profit-detail td.profit-unknown{color:var(--muted)}.profit-detail td:nth-child(3){color:var(--muted)}.profit-detail tr.is-selected>*{background:color-mix(in srgb,currentColor 7%,transparent)}.profit-detail .profit-loss{color:var(--sales-red)}
.profit-detail-gap,.profit-detail-empty{margin:12px 0 0;font-size:12px;color:var(--muted)}.profit-detail-gap button{margin-left:8px;padding:0;border:0;background:none;color:inherit;font:inherit;text-decoration:underline;cursor:pointer}
.profit-exclusion-worth{font-style:normal;font-size:12px;color:var(--muted);font-variant-numeric:tabular-nums;white-space:nowrap}
button.profit-exclusion-worth{padding:0;border:0;background:none;font:inherit;font-size:12px;text-decoration:underline;text-underline-offset:3px;cursor:pointer}button.profit-exclusion-worth[aria-pressed=true]{color:inherit;font-weight:600}
.profit-filter{display:flex;flex-wrap:wrap;gap:8px;padding:0 20px 12px}
.profit-filter button{height:32px;padding:0 12px;border:1px solid var(--line);border-radius:16px;background:transparent;color:var(--muted);font:inherit;font-size:12px;cursor:pointer}
.profit-filter button b{margin-left:4px;font-weight:500;font-variant-numeric:tabular-nums}.profit-filter button[aria-pressed=true]{color:inherit;border-color:currentColor;font-weight:600}
.profit-exclusion-table{margin-top:16px;overflow-x:auto}.profit-exclusion-table table{width:100%;min-width:480px;border-collapse:collapse;font-size:13px;font-variant-numeric:tabular-nums}
.profit-exclusion-table th,.profit-exclusion-table td{padding:8px 12px;border-bottom:1px solid var(--line);text-align:right;font-weight:400;white-space:nowrap;background:transparent}
.profit-exclusion-table th:first-child{text-align:left}.profit-exclusion-table thead th{font-size:12px;color:var(--muted)}.profit-exclusion-table tbody th{font-size:13px;color:inherit}
.profit-exclusion-table td small{margin-left:6px;font-size:12px;color:var(--muted)}.profit-exclusion-table td.is-off{text-decoration:line-through;color:var(--muted)}
.profit-detail td:nth-child(4){color:var(--muted)}
.profit-basis>summary{font-size:14px;font-weight:600;cursor:pointer}.profit-basis>summary small{margin-left:8px;font-size:12px;font-weight:400;color:var(--muted)}
.profit-basis[open]>summary{margin-bottom:12px}.profit-basis .profit-detail-scroll+.profit-detail-scroll{margin-top:16px}
.profit-basis td,.profit-basis thead th{text-align:left;white-space:normal}.profit-basis caption{padding:0 12px 8px;text-align:left;font-size:13px;font-weight:600}.profit-basis caption small{font-size:12px;font-weight:400;color:var(--muted)}.profit-basis caption span+small{margin-left:8px}
.profit-watch{margin-top:16px;padding:20px;background:var(--white);border:1px solid var(--line);border-radius:12px}
.profit-watch>header{display:flex;align-items:center;justify-content:space-between;gap:12px;margin-bottom:12px}.profit-watch h3{margin:0;font-size:14px;font-weight:600;display:flex;align-items:center;gap:8px}
.profit-watch>header button{height:28px;padding:0 12px;border:1px solid var(--line);border-radius:6px;background:transparent;color:inherit;font:inherit;font-size:12px;cursor:pointer}
.profit-watch table{width:100%;min-width:560px;border-collapse:collapse;font-size:13px;font-variant-numeric:tabular-nums}
.profit-watch th,.profit-watch td{padding:8px 12px;border-bottom:1px solid var(--line);text-align:right;font-weight:400;white-space:nowrap;background:transparent}
.profit-watch th:first-child{text-align:left;white-space:normal}.profit-watch thead th{font-size:12px;color:var(--muted)}.profit-watch tbody th{font-size:13px;color:inherit}
.profit-watch td small{margin-left:4px;font-size:11px;color:var(--muted)}.profit-watch .profit-loss{color:var(--sales-red)}.profit-watch tbody tr:last-child>*{border-bottom:0}

/* 카드: 금액 오른쪽에 지난 기간과 견준 표시(좁으면 아래로 넘어간다) */
.profit-card-value{display:flex;align-items:center;flex-wrap:wrap;gap:4px 12px;margin:8px 0 12px;min-width:0}.profit-card-value>strong{margin:0}.profit-card-value>.profit-card-comparison{display:flex;align-items:center;min-height:0}
/* 상품별 이익 맨 위: 상품 카드 넷과 짧은 목록 셋 */
.profit-board{display:grid;gap:16px}.profit-board .profit-card-grid{grid-template-columns:repeat(4,minmax(0,1fr))}.profit-board .profit-metric-card{min-height:0}
button.profit-metric-card{font:inherit;color:inherit;text-align:left;cursor:pointer;align-items:stretch}button.profit-metric-card:hover{border-color:var(--muted)}button.profit-metric-card[aria-pressed=true]{border-color:var(--ink)}button.profit-metric-card:focus-visible{outline:2px solid var(--ink);outline-offset:3px}
.profit-board-foot{margin:0;font-size:12px;line-height:1.5;color:var(--muted)}.profit-board-foot small{font-size:11px;margin-left:2px}.profit-board .profit-loss{color:var(--sales-red)}.profit-board .profit-gain{color:var(--sales-green)}
.profit-board-lists{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:16px}.profit-board-list{min-width:0;padding:20px;background:var(--white);border:1px solid var(--line);border-radius:12px}
.profit-board-list>header{display:flex;align-items:center;justify-content:space-between;gap:12px;min-height:28px;margin-bottom:8px}.profit-board-list h3{margin:0;font-size:14px;font-weight:600}.profit-board-list>header small{font-size:12px;color:var(--muted);text-align:right}
.profit-board-list>header button{height:28px;padding:0 12px;border:1px solid var(--line);border-radius:6px;background:transparent;color:inherit;font:inherit;font-size:12px;cursor:pointer;white-space:nowrap}
.profit-board-list ol{list-style:none;margin:0;padding:0}.profit-board-list li{display:grid;grid-template-columns:minmax(0,1fr) auto;align-items:center;gap:16px;padding:12px 0;border-bottom:1px solid var(--line);font-variant-numeric:tabular-nums}.profit-board-list li:last-child{border-bottom:0;padding-bottom:0}
.profit-board-list li>div{min-width:0;display:grid;gap:4px}.profit-board-list li strong{font-size:13px;font-weight:500;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.profit-board-list li small{font-size:12px;color:var(--muted);overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
.profit-board-list li>span{display:grid;gap:4px;text-align:right;white-space:nowrap}.profit-board-list li b{font-size:13px;font-weight:600}.profit-board-list li b small{font-size:11px;font-weight:400;margin-left:2px;color:var(--muted)}.profit-board-list li em{font-style:normal;font-size:12px;color:var(--muted)}
/* PC-only revision; phone composition remains for its separate follow-up. */
@media(min-width:721px){
  .settlement-results .sales-products-table:not(.profit-mobile-table)>thead>tr>th:first-child,.settlement-results .sales-product-row>td:first-child{padding-left:20px}
  .settlement-results .option-columns-row>th,.settlement-results .option-value-row>td{background:var(--accent-bg);border:0;height:56px;padding:12px;font-size:13px}
  .settlement-results .option-columns-row>th{height:44px;font-size:12px;font-weight:500;color:var(--muted)}
  .settlement-results .option-columns-row>.product-name-head,.settlement-results .option-choice{text-align:center;white-space:normal;overflow-wrap:anywhere}
  .settlement-results .option-value-row:last-child>td{padding-bottom:20px}
  .settlement-results .option-columns-row>.option-cost,.settlement-results .option-value-row>.option-cost{text-align:right;white-space:nowrap;font-variant-numeric:tabular-nums}
  .option-status-row p{margin:16px 20px}
  .profit-board-desktop .profit-board-list h3{font-size:16px;font-weight:700}
  .profit-board-desktop .profit-board-list li{min-height:64px;padding:8px 0;border:0}
  .profit-board-desktop .profit-board-list li b{font-size:16px;color:var(--ink)}
  .profit-board-desktop .profit-board-list .profit-rate-badge{justify-self:end;border-radius:4px;padding:3px 6px;font-size:11px;line-height:1.4;background:var(--accent-bg);color:var(--ink)}
  .profit-board-desktop .profit-board-list li:has(.profit-loss) .profit-rate-badge{background:var(--sales-red-bg);color:var(--sales-red)}
  .profit-results>.table-guide{display:none}
  .profit-results>header{padding-inline:20px}
  .profit-results .sales-products-table th,.profit-results .sales-products-table td{padding-inline:10px}
  .profit-results .sales-products-table>thead>tr>th:first-child,.profit-results .sales-products-table>tbody>tr>td:first-child{padding-left:16px}
  .profit-results .sales-products-table>thead>tr>th:last-child,.profit-results .sales-products-table>tbody>tr>td:last-child{padding-right:16px}
  .profit-settings-desktop{width:100%;max-width:1152px;box-sizing:border-box;padding-inline:16px}
  .profit-settings-desktop .profit-config-common .profit-settings-form{max-width:none}
  .profit-settings-desktop .profit-config-common h3,.profit-settings-desktop .profit-config-channels h3,.profit-aggregation-section>h3{font-size:18px;font-weight:700;margin:0}
  .profit-settings-desktop .profit-config-channel h4{font-size:14px;margin:0}
  .profit-settings-desktop .profit-config-common-card,.profit-settings-desktop .profit-config-common>.profit-exclusions,.profit-config-stacked>.profit-config-channel{padding:24px;border:1px solid var(--line);border-radius:12px;background:var(--white)}
  .profit-settings-desktop .profit-config-stacked{margin-top:32px;padding:0;border:0;background:transparent}
  .profit-config-stacked>.profit-config-channel{margin-top:16px}
  .profit-config-stacked>.profit-config-channel+section{margin-top:20px}
  .profit-settings-desktop .profit-config-channel .profit-settings-fields,.profit-settings-desktop .profit-config-common .profit-settings-fields{grid-template-columns:repeat(3,minmax(0,1fr))}
  .profit-settings-desktop form[data-channel=zigzag] .profit-settings-fields{grid-template-columns:repeat(4,minmax(0,1fr))}
  .profit-settings-desktop .profit-settings-form footer{margin-top:16px;padding:0;border:0}
  .profit-settings-desktop .profit-settings-form footer .profit-help{display:none}
  .profit-settings-desktop .profit-setting-field{min-height:76px;padding:0;border:0;border-radius:0;background:transparent}
  .profit-settings-desktop .profit-setting-field>span:first-child{min-height:20px}
  .profit-settings-desktop .profit-config-common>.profit-exclusions{margin:20px 0 0}
  .profit-settings-desktop .profit-config-common .profit-exclusions h2{font-size:14px}
  .profit-settings-desktop .profit-exclusion-grid{display:flex;gap:0}
  .profit-settings-desktop .profit-exclusion-card{gap:12px;justify-content:flex-start;padding-inline:24px}
  .profit-settings-desktop .profit-exclusion-card:first-child{padding-left:0}
  .profit-settings-desktop .profit-exclusion-card+ .profit-exclusion-card::before{content:"";position:absolute;left:0;top:50%;height:20px;border-left:1px solid var(--line);transform:translateY(-50%)}
  .profit-settings-desktop .profit-ad-note{display:inline;font-size:10px;font-weight:400;color:var(--muted);margin-left:6px;line-height:1.5}
  .profit-settings-desktop input[name=adRate]:placeholder-shown{background:var(--sales-yellow-bg);border-color:color-mix(in srgb,var(--sales-yellow) 45%,var(--line))}
  .profit-settings-desktop input[name=adRate]::placeholder,.profit-settings-desktop .profit-ad-auto{color:var(--sales-yellow);opacity:1}
  .profit-settings-desktop [data-profit-breakdown]{margin-top:0}
}
@container sales-view (max-width:820px){.profit-board-lists{grid-template-columns:1fr}}
@container sales-view (max-width:850px){.profit-board .profit-card-grid{grid-template-columns:repeat(2,minmax(0,1fr))}}
@container sales-view (max-width:400px){.profit-board .profit-card-grid{grid-template-columns:1fr}}

/* 모바일 상품표: 첫 화면 안에 상품명 + 최종 이익, 나머지는 기존 가로 스크롤로 확인. */
.profit-results .profit-mobile-table{width:max-content;table-layout:fixed}
.profit-results .profit-mobile-table>thead>tr>th,.profit-results .profit-mobile-table>tbody>tr>td{padding:12px;box-sizing:border-box}
.profit-results .profit-mobile-table>thead>tr>th:first-child,.profit-results .profit-mobile-table>tbody>tr>td:first-child{width:calc(var(--table-visible-width,100cqw) - 128px);min-width:calc(var(--table-visible-width,100cqw) - 128px);max-width:calc(var(--table-visible-width,100cqw) - 128px)}
.profit-results .profit-mobile-table>thead>tr>th:nth-child(2),.profit-results .profit-mobile-table>tbody>tr>td:nth-child(2){width:128px;min-width:128px;max-width:128px;font-variant-numeric:tabular-nums}
.profit-results .profit-mobile-table .settlement-product strong{min-width:0;max-width:none;font-size:12px;line-height:1.5}
.profit-results .profit-mobile-table .settlement-product small{font-size:11px}
.profit-results .profit-mobile-table>tbody>tr>td:nth-child(2){font-weight:600}

/* 열 설정: 숨겨진 지표의 묶음 이름 */
.column-lists li.column-group{min-height:0;border:0;background:transparent;padding:10px 2px 2px;margin-bottom:6px;font-size:12px;font-weight:500;color:var(--muted)}
.column-lists li.column-group:first-child{padding-top:0}
