/* css/pages/manage.css: the Manage section's pages (pages/manage/*.js); the narrower screens' rules are in css/mobile.css */

/* Pricing: promotions and schedules on the left, bonuses and the desk's prices on the right; one column on narrower
   screens, in that same order. */
.pricing-grid { display: grid; grid-template-columns: minmax(0, 3fr) minmax(0, 2fr); gap: var(--s4); align-items: start; max-width: 1500px; }
.promo-now { margin: var(--s1) 0; }
.price-grid input { width: 7em; text-align: right; }

/* Comps & tills: the comps on the left, the till closes on the right; stacked on narrower screens. A row opened in
   place (tr.open) shows its whole reason and note and the addresses (.cmp-more). */
.comps-grid { display: grid; grid-template-columns: minmax(0, 4fr) minmax(0, 3fr); gap: var(--s4); align-items: start; }
.comps-grid > .kit-card + .kit-card { margin-top: 0; }     /* the grid's gap spaces them, side by side or stacked */
.comps-grid td.num { white-space: nowrap; }
/* both heads as tall as the comps filter (a bordered small control), so "1 more …" and its Show button never move the rows */
.comps-grid .kit-card-head { min-height: calc(var(--ctl-h-sm) + 2px); }
.cmp-clamp { display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; max-width: 28em; }
.cmp-more { display: none; }
.dt tr.open .cmp-clamp { display: block; -webkit-line-clamp: unset; }
.dt tr.open .cmp-more { display: block; }
.cmp-acts { display: flex; gap: var(--s1); margin-top: var(--s1); }
.cmp-days { margin-left: var(--s2); }

/* Sales: the figures row (four across, two on narrower screens), then the cards two to a row; a wide card spans both. */
.sales-head { margin-top: 0; }
.sales-stats { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: var(--s4); margin-bottom: var(--s4); align-items: start; }
.sales-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: var(--s4); align-items: start; }
.sales-grid > .wide { grid-column: 1 / -1; }
.sales-stats > .kit-card + .kit-card, .sales-grid > .kit-card + .kit-card { margin-top: 0; }
.sales-card .kit-card-head { min-height: calc(var(--ctl-h-sm) + 2px); flex-wrap: wrap; }
.sales-card .kit-card-head h3 .muted { font-weight: normal; margin-left: var(--s1); }
.sales-card.off { opacity: .75; }
.stat-figs { display: flex; flex-wrap: wrap; gap: var(--s2) var(--s5); }
.stat-figs > div { min-width: 0; }
.stat-figs.halves { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); }
.stat-big { display: block; font-size: 24px; font-weight: 600; font-variant-numeric: tabular-nums; }
.stat-unit { display: block; font-size: var(--fs-xs); letter-spacing: .05em; text-transform: uppercase; color: var(--muted); }
.sales-cmp { width: 100%; margin-top: var(--s2); border-collapse: collapse; font-size: var(--fs-sm); font-variant-numeric: tabular-nums; }
.sales-cmp th, .sales-cmp td { padding: 3px 0 3px var(--s2); text-align: right; font-weight: normal; border-top: 1px solid var(--line); }
.sales-cmp tr:first-child th { border-top: 0; color: var(--muted); font-size: var(--fs-xs); }
.sales-cmp th:first-child { padding-left: 0; text-align: left; color: var(--muted); }
.sales-note { margin: var(--s2) 0 0; font-size: var(--fs-sm); line-height: 1.5; }
.sales-up { color: var(--ok-fg); }
.sales-down { color: var(--err-fg); }
.sales-tag { display: inline-block; padding: 0 6px; border: 1px solid var(--line-2); border-radius: var(--radius-pill); font-size: var(--fs-xs);
  color: var(--text); white-space: nowrap; }
.sales-scroll { max-width: 100%; margin-top: var(--s2); overflow-x: auto; }
.sales-table { width: 100%; border-collapse: collapse; font-size: var(--fs-sm); font-variant-numeric: tabular-nums; }
.sales-table th, .sales-table td { padding: 5px 6px; border-bottom: 1px solid var(--line); text-align: right; vertical-align: top; }
.sales-table th { color: var(--muted); font-weight: 500; font-size: var(--fs-xs); }
.sales-table th:first-child, .sales-table td:first-child { text-align: left; }
.sales-table sup { color: var(--warn-fg); font-size: 9px; margin-left: 2px; }
.sales-table tr.sales-tot td { border-top: 1px solid var(--muted); font-weight: 500; }
.sales-table .sales-gap { border-left: 1px solid var(--line); }
.sales-table th.sales-group { text-align: center; color: var(--text); }
.sales-next td:first-child { white-space: nowrap; }
.sales-more { margin-top: var(--s2); }
.sales-more > summary, .sales-hol summary { cursor: pointer; }
.sales-lift { opacity: .65; }
.sales-lift.up { color: var(--ok-fg); }
.sales-lift.down { color: var(--err-fg); }
.sales-lift.clear { opacity: 1; font-weight: 700; }
.sales-split { display: block; font-size: 10.5px; color: var(--muted); }
.sales-years { padding: 4px 0 2px 12px; font-size: var(--fs-xs); line-height: 1.6; }
.sales-notes { margin: 0; padding-left: 18px; font-size: var(--fs-sm); line-height: 1.6; }
.sales-h4 { margin: var(--s3) 0 0; font-size: var(--fs-xs); letter-spacing: .05em; text-transform: uppercase; color: var(--muted); font-weight: 600; }
.sales-list { list-style: none; margin: var(--s1) 0 0; padding: 0; font-size: var(--fs-sm); }
.sales-list li { display: flex; flex-wrap: wrap; align-items: center; gap: 4px 6px; padding: 5px 0; border-bottom: 1px solid var(--line); }
.sales-list li:last-child { border-bottom: 0; }
.sales-replay { display: flex; flex-wrap: wrap; align-items: center; gap: var(--s2); margin-top: var(--s2); }
/* the Sales charts' own series: packages (cheapest first), rain and highs, and each bay's line */
.chart .s-tier { stroke: var(--panel); stroke-width: 1; }
.chart .s-tier-1 { fill: var(--chart-tier-1); }
.chart .s-tier-2 { fill: var(--chart-tier-2); }
.chart .s-tier-3 { fill: var(--chart-tier-3); }
.chart .s-tier-4 { fill: var(--chart-tier-4); }
.s-tier-1:not(rect) { background: var(--chart-tier-1); }
.s-tier-2:not(rect) { background: var(--chart-tier-2); }
.s-tier-3:not(rect) { background: var(--chart-tier-3); }
.s-tier-4:not(rect) { background: var(--chart-tier-4); }
.chart .s-rain { fill: var(--chart-1); opacity: .55; }
.chart-legend .s-rain { background: var(--chart-1); opacity: .55; }
.chart .s-hi { fill: none; stroke: var(--text); stroke-width: 1.2; opacity: .7; }
.chart-legend .s-hi { height: 0; border-top: 2px solid var(--text); border-radius: 0; vertical-align: 3px; opacity: .7; }
.chart .s-bay { fill: none; stroke-width: 1.6; }
.chart .s-bay.retired { stroke-dasharray: 4 3; }
.chart .s-bay-touchless { stroke: var(--chart-bay-touchless); }
.chart .s-bay-xl { stroke: var(--chart-bay-xl); }
.chart .s-bay-softtouch { stroke: var(--chart-bay-softtouch); }
.chart .s-bay-selfserve { stroke: var(--chart-bay-selfserve); }
.chart .s-bay-selfserve2 { stroke: var(--chart-bay-selfserve2); }
.chart-legend .s-bay-touchless { background: var(--chart-bay-touchless); }
.chart-legend .s-bay-xl { background: var(--chart-bay-xl); }
.chart-legend .s-bay-softtouch { background: var(--chart-bay-softtouch); }
.chart-legend .s-bay-selfserve { background: var(--chart-bay-selfserve); }
.chart-legend .s-bay-selfserve2 { background: var(--chart-bay-selfserve2); }
/* tables and prose no wider than the charts: a row stays easy to follow on a wide screen */
.sales-card .sales-table, .sales-card .sales-note, .sales-notes { max-width: 1200px; }

/* Manage › Wait times (pages/manage/waits.js): one card per bay, the wait the public board would show in large type */
.wait-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); gap: var(--s3); margin: var(--s3) 0 var(--s4); }
.wait-grid > .kit-card { margin: 0; }
.wait-card p { margin: var(--s1) 0; }
.wait-big { font-size: var(--fs-xl, 1.6rem); font-weight: 700; }
.wait-card.unknown .wait-big { color: var(--muted); }
