/* StrategyRx report page. Uses the dashboard's theme variables. */
.strx { display: flex; flex-direction: column; gap: 14px; }
.strx .card { margin-bottom: 0; }
.strx-top { display: flex; flex-wrap: wrap; gap: 12px; align-items: flex-end; }
.strx-pick { display: flex; flex-direction: column; gap: 4px; min-width: 200px; }
.strx-pick label { font-size: 11px; color: var(--muted); text-transform: uppercase; letter-spacing: .05em; }
.strx-pick select { min-width: 220px; max-width: 340px; }
.strx-top-actions { margin-left: auto; display: flex; gap: 8px; }
.strx-busy { padding: 10px 14px; border-radius: 8px; background: var(--surface2); border: 1px solid var(--border); color: var(--text); font-size: 13px; }
.strx-note { display: flex; flex-wrap: wrap; gap: 10px; align-items: center; justify-content: space-between; padding: 10px 14px; border-radius: 8px; border: 1px solid var(--border); background: var(--surface2); color: var(--text); font-size: 13px; margin-bottom: 8px; }
.strx-note.amber { border-left: 3px solid var(--amber); }
.strx-note.accent { border-left: 3px solid var(--accent); }
.strx-note-actions { display: flex; gap: 8px; flex-wrap: wrap; }
.strx-brief { display: flex; flex-direction: column; gap: 8px; max-width: 900px; }
.strx-brief label { font-size: 12px; color: var(--muted); }
.strx-brief textarea { font-family: inherit; line-height: 1.5; resize: vertical; min-height: 320px; }
.strx-head { display: flex; flex-wrap: wrap; align-items: center; gap: 16px; padding: 16px 18px; border-radius: 12px; background: var(--surface); border: 1px solid var(--border); }
.strx-logo { max-height: 48px; max-width: 160px; object-fit: contain; }
.strx-head-main { flex: 1; min-width: 220px; }
.strx-hotel { font-size: 20px; font-weight: 700; color: var(--text); line-height: 1.2; }
.strx-head-sub { color: var(--muted); font-size: 13px; margin-top: 2px; }
.strx-head-meta { text-align: right; font-size: 12.5px; color: var(--muted); line-height: 1.6; }
.strx-head-title { font-size: 13px; font-weight: 700; letter-spacing: .08em; text-transform: uppercase; color: var(--accent); }
.strx-chip { display: inline-block; padding: 1px 8px; border-radius: 999px; border: 1px solid var(--border); font-size: 11.5px; color: var(--muted); }
.strx-chip.green { color: var(--green); border-color: var(--green); }
.strx-chip.amber { color: var(--amber); border-color: var(--amber); }
.strx-tabs { display: flex; gap: 2px; overflow-x: auto; border-bottom: 1px solid var(--border); scrollbar-width: thin; }
.strx-tab { background: none; border: 0; border-bottom: 2px solid transparent; padding: 9px 13px; font: inherit; font-size: 13px; color: var(--muted); cursor: pointer; white-space: nowrap; }
.strx-tab:hover { color: var(--text); }
.strx-tab.active { color: var(--text); border-bottom-color: var(--accent); font-weight: 600; }
#strxBody { display: flex; flex-direction: column; gap: 14px; }
.strx-bar { display: flex; flex-wrap: wrap; gap: 10px 14px; align-items: center; }
.strx-bar label { display: flex; align-items: center; gap: 6px; font-size: 12px; color: var(--muted); }
.strx-bar .form-input, .strx-bar .filter-select { width: auto; }
.strx-seg { display: inline-flex; gap: 4px; flex-wrap: wrap; }
.strx-muted { color: var(--muted); font-size: 12.5px; }
.strx-kpis { margin: 0; }
.strx-kpis .kpi-sub.strx-up, .strx-up { color: var(--green); }
.strx-kpis .kpi-sub.strx-dn, .strx-dn { color: var(--red); }
#page-rm-strategyrx.active { flex: 1; min-width: 0; padding: 16px 20px; overflow-y: auto; }
#strxRoot { min-width: 0; max-width: 100%; }
.strx-two { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 14px; }
.strx-two > div { min-width: 0; display: flex; flex-direction: column; }
.strx-two > div > .card { flex: 1; }
.strx-chart { position: relative; height: 260px; }
.strx-chart.tall { height: 320px; }
.strx-empty { padding: 22px 12px; text-align: center; color: var(--muted); font-size: 13px; }
.strx-wheels { display: flex; flex-wrap: wrap; gap: 14px; justify-content: space-around; }
.strx-wheel { width: 118px; text-align: center; }
.strx-wheel svg { width: 96px; height: 96px; }
.strx-wheel-val { fill: var(--text); font-size: 20px; font-weight: 700; }
.strx-wheel-label { font-size: 12.5px; font-weight: 600; color: var(--text); margin-top: 2px; }
.strx-wheel-sub { font-size: 11px; color: var(--muted); line-height: 1.3; }
.strx-insights, .strx-notes { margin: 0; padding: 0; list-style: none; display: flex; flex-direction: column; gap: 8px; }
.strx-insights li, .strx-notes li { padding: 8px 12px; border-radius: 8px; background: var(--surface2); border-left: 3px solid var(--border); font-size: 13px; line-height: 1.45; color: var(--text); }
.strx-insights li.strx-i-up { border-left-color: var(--green); }
.strx-insights li.strx-i-dn { border-left-color: var(--red); }
.strx-prose { font-size: 13px; line-height: 1.6; color: var(--text); max-width: 78ch; }
.strx-prose p { margin: 0 0 8px; }
.strx-h4 { margin: 0 0 6px; font-size: 13px; color: var(--text); }

/* demand calendar */
.strx-heat { display: grid; grid-template-columns: repeat(7, minmax(0, 1fr)); gap: 4px; }
.strx-heat-h { font-size: 11px; color: var(--muted); text-align: center; padding-bottom: 2px; }
.strx-heat-c { position: relative; border-radius: 6px; padding: 5px 7px; min-height: 44px; display: flex; flex-direction: column; justify-content: space-between; border: 1px solid var(--border); overflow: hidden; }
.strx-heat-c::before { content: ''; position: absolute; inset: 0; background: var(--accent); opacity: var(--a, 0); }
.strx-heat-c > span { position: relative; }
.strx-heat-c.blank { border: 0; }
.strx-heat-c .dn { font-size: 11px; color: var(--text); opacity: .85; }
.strx-heat-c .ov { font-size: 13px; font-weight: 700; color: var(--text); font-variant-numeric: tabular-nums; }
.strx-heat-c.hol { border-color: var(--amber); box-shadow: inset 0 0 0 1px var(--amber); }
.strx-heat-c.ev::after { content: ''; position: absolute; top: 5px; right: 5px; width: 7px; height: 7px; border-radius: 50%; background: var(--teal); }
.strx-legend { display: flex; flex-wrap: wrap; gap: 14px; margin-top: 10px; font-size: 11.5px; color: var(--muted); }
.strx-legend .sw { display: inline-block; width: 12px; height: 12px; border-radius: 3px; margin-right: 5px; vertical-align: -2px; border: 1px solid var(--border); }
.strx-legend .sw.lo { background: color-mix(in srgb, var(--accent) 12%, transparent); }
.strx-legend .sw.hi { background: var(--accent); }
.strx-legend .sw.hol { border-color: var(--amber); box-shadow: inset 0 0 0 1px var(--amber); }
.strx-legend .sw.ev { background: var(--teal); border-radius: 50%; }

/* grid */
.strx-grid-bar { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; margin-bottom: 8px; }
.strx-grid-q { width: 200px !important; }
.strx-grid-presets { display: inline-flex; gap: 4px; flex-wrap: wrap; }
.strx-grid-count { margin-left: auto; font-size: 12px; color: var(--muted); }
.strx-cols { position: relative; }
.strx-cols > summary { list-style: none; cursor: pointer; display: inline-block; }
.strx-cols > summary::-webkit-details-marker { display: none; }
.strx-cols-list { position: absolute; z-index: 30; top: calc(100% + 4px); left: 0; width: 240px; max-height: 320px; overflow: auto; padding: 8px 10px; border-radius: 8px; background: var(--surface); border: 1px solid var(--border); box-shadow: var(--shadow-md, 0 8px 24px rgba(0,0,0,.3)); display: flex; flex-direction: column; gap: 4px; }
.strx-cols-list label { font-size: 12.5px; color: var(--text); display: flex; gap: 6px; align-items: center; cursor: pointer; }
.strx-grid-wrap { overflow-x: auto; }
.strx-table { width: 100%; font-size: 12.5px; }
.strx-table th { cursor: pointer; white-space: nowrap; user-select: none; }
.strx-table td { white-space: nowrap; font-variant-numeric: tabular-nums; }
.strx-table th.num, .strx-table td.num { text-align: right; }
.strx-table th:first-child, .strx-table td:first-child { position: sticky; left: 0; background: var(--surface); z-index: 1; }
.strx-table tr.strx-total td { font-weight: 700; border-top: 2px solid var(--border); }
.strx-table tr.strx-row-we td { background: color-mix(in srgb, var(--accent) 5%, transparent); }
.strx-table tr.strx-row-we td:first-child { background: color-mix(in srgb, var(--accent) 5%, var(--surface)); }
.strx-table tr.strx-row-hol td:first-child { box-shadow: inset 3px 0 0 var(--amber); }
.strx-table tr.strx-row-own td { font-weight: 700; }
.strx-grid-pager { display: flex; gap: 10px; align-items: center; justify-content: flex-end; margin-top: 8px; font-size: 12px; color: var(--muted); }
.strx-row-actions { display: flex; gap: 6px; justify-content: flex-end; }

/* comparing uploads */
.strx-hide { display: flex; align-items: center; gap: 6px; font-size: 12.5px; color: var(--muted); cursor: pointer; padding-bottom: 7px; white-space: nowrap; }
.strx-cmp-line { font-size: 12px; color: var(--muted); margin-top: 2px; }
.strx-mk { font-size: 9px; vertical-align: 1px; margin-left: 2px; }
.strx-mk.up { color: var(--green); }
.strx-mk.dn { color: var(--red); }
.strx-mk.warn { color: var(--amber); }
.strx-badge { display: inline-block; margin-left: 6px; padding: 0 7px; border-radius: 999px; font-size: 10.5px; font-weight: 600; line-height: 1.6; border: 1px solid var(--border); color: var(--muted); }
.strx-badge.new { color: var(--green); border-color: var(--green); }
.strx-badge.gone { color: var(--muted); }
.strx-insights li.strx-i-warn { border-left-color: var(--amber); }
.strx-table tr.strx-row-gone td { color: var(--muted); }
.strx-heat-c.pu-up::before { background: var(--green); }
.strx-heat-c.pu-dn::before { background: var(--red); }
.strx-legend .sw.up { background: var(--green); }
.strx-legend .sw.dn { background: var(--red); }

/* upload prompt */
.strx-drop { text-align: center; padding: 44px 20px; border: 1px dashed var(--border); display: flex; flex-direction: column; gap: 12px; align-items: center; }
.strx-drop-title { font-size: 17px; font-weight: 700; color: var(--text); }
.strx-drop-sub { font-size: 13px; color: var(--muted); max-width: 62ch; line-height: 1.5; }

/* presenting on a shared screen */
.strx-present { background: var(--bg); padding: 18px 22px; overflow: auto; }
.strx-present .strx-top, .strx-present #strxBanner, .strx-present .strx-grid-bar .strx-cols, .strx-present [data-g="csv"] { display: none; }
.strx-present .strx-hotel { font-size: 24px; }

@media (max-width: 1100px) { .strx-two { grid-template-columns: minmax(0, 1fr); } }
@media (max-width: 720px) {
  .strx-top-actions { margin-left: 0; width: 100%; }
  .strx-head-meta { text-align: left; }
  .strx-heat-c { min-height: 38px; padding: 3px 4px; }
  .strx-heat-c .ov { font-size: 11px; }
  .strx-grid-q { width: 100% !important; }
}
@media print { .strx-top, #strxBanner, .strx-tabs, .strx-grid-bar, .strx-grid-pager { display: none !important; } }

/* company logo controls */
.strx-link { background: none; border: 0; padding: 0; font: inherit; font-size: 12px; color: var(--accent); cursor: pointer; text-decoration: underline; }
.strx-logo-acts { display: flex; gap: 10px; justify-content: flex-end; margin-top: 2px; }

/* print view: the whole report stacked, on a light page */
.strx-print-only { display: none; margin-top: 6px; }
body.strx-printing { --bg: #ffffff; --surface: #ffffff; --surface2: #fafaf7; --surface3: #f5f2ea; --border: #cccccc; --text: #000000; --muted: #555555; }
body.strx-printing #page-rm-strategyrx { background: #ffffff; color: #000000; }
body.strx-printing .strx-top, body.strx-printing #strxBanner { display: none; }
.strx-printing .strx-tabs { border-bottom: 0; overflow: visible; }
.strx-print-bar { width: 100%; margin-bottom: 0; }
.strx-print-sec { display: flex; flex-direction: column; gap: 10px; }
.strx-print-h { font-size: 17px; font-weight: 700; color: var(--text); margin: 8px 0 0; padding-bottom: 4px; border-bottom: 2px solid var(--accent); }
.strx-print-body { display: flex; flex-direction: column; gap: 14px; }
.strx-print-img { display: block; width: 100%; height: 100%; object-fit: contain; }
.strx-printing .strx-grid-bar, .strx-printing .strx-grid-pager, .strx-printing .strx-print-body .strx-bar { display: none; }
.strx-printing .strx-print-only { display: block; }
@media print {
  body.strx-printing .page:not(#page-rm-strategyrx) { display: none !important; }
  body.strx-printing, body.strx-printing .main-wrap, body.strx-printing .main { display: block !important; min-height: 0 !important; height: auto !important; overflow: visible !important; }
  body.strx-printing #page-rm-strategyrx { page: strx; padding: 0 !important; overflow: visible !important; height: auto !important; page-break-after: auto; }
  body.strx-printing .strx-grid-wrap { overflow: visible; }
  body.strx-printing .strx-table { font-size: 8pt; }
  body.strx-printing .strx-table td, body.strx-printing .strx-table th { padding: 3px 5px; }
  body.strx-printing .strx-table th:first-child, body.strx-printing .strx-table td:first-child { position: static; }
  body.strx-printing .strx-print-sec + .strx-print-sec { break-before: page; }
  body.strx-printing .strx-print-h { break-after: avoid; }
  .strx-logo-acts { display: none !important; }
  @page strx { size: letter landscape; margin: 0.5in; }
}

/* several workbooks at once: the review list */
.strx-chip.red { color: var(--red); border-color: var(--red); }
.strx-batch-card { padding: 0; overflow-x: auto; }
.strx-batch { width: 100%; border-collapse: collapse; font-size: 13px; }
.strx-batch th, .strx-batch td { padding: 9px 12px; text-align: left; border-bottom: 1px solid var(--border); vertical-align: top; }
.strx-batch th { font-size: 11.5px; text-transform: uppercase; letter-spacing: .04em; color: var(--muted); font-weight: 600; white-space: nowrap; }
.strx-batch tr:last-child td { border-bottom: 0; }
.strx-batch th.num, .strx-batch td.num { text-align: right; font-variant-numeric: tabular-nums; }
.strx-batch td:nth-child(2), .strx-batch td:nth-child(3), .strx-batch td:nth-child(5) { white-space: nowrap; }
.strx-batch-file { font-weight: 600; min-width: 190px; word-break: break-word; }
.strx-batch td:last-child { min-width: 200px; }
.strx-batch-warn { color: var(--amber); white-space: nowrap; }
