/* Sales recap pop-up (shared by both versions). */
.pr-link {
  background: none; border: 0; padding: 0; margin-top: 6px; cursor: pointer;
  font: 600 12px var(--font); color: var(--accent, #1c5cab); display: inline-block;
}
.pr-link:hover { text-decoration: underline; }
body.pr-lock { overflow: hidden; }
.pr-backdrop {
  position: fixed; inset: 0; z-index: 100; background: rgba(15, 22, 34, .45);
  display: flex; align-items: flex-start; justify-content: center; padding: 4vh 16px;
  overflow-y: auto; animation: pr-fade .2s ease both;
}
@keyframes pr-fade { from { opacity: 0; } to { opacity: 1; } }
.pr-modal {
  background: var(--page, #f4f3ef); border-radius: 14px; width: min(980px, 100%);
  box-shadow: 0 24px 60px -20px rgba(0,0,0,.45); overflow: hidden; animation: pr-up .25s cubic-bezier(.2,.7,.2,1) both;
}
@keyframes pr-up { from { transform: translateY(12px); opacity: 0; } to { transform: none; opacity: 1; } }
.pr-head { display: flex; justify-content: space-between; align-items: flex-start; gap: 12px; padding: 18px 20px 8px; background: var(--surface-1); }
.pr-head h2 { margin: 0; font-size: 18px; }
.pr-sub { margin: 3px 0 0; color: var(--text-muted); font-size: 13px; }
.pr-close { border: 1px solid var(--border); background: var(--surface-1); border-radius: 8px; width: 34px; height: 34px; cursor: pointer; font-size: 14px; flex-shrink: 0; }
.pr-close:hover { border-color: var(--text-muted); }
.pr-tabs { display: flex; gap: 6px; padding: 8px 20px 14px; background: var(--surface-1); border-bottom: 1px solid var(--border); overflow-x: auto; scrollbar-width: none; }
.pr-tabs::-webkit-scrollbar { display: none; }
.pr-tabs button {
  border: 1px solid var(--border); background: var(--surface-1); border-radius: 999px; padding: 6px 13px;
  font: 500 13px var(--font); color: var(--text-secondary); cursor: pointer; white-space: nowrap;
}
.pr-tabs button[aria-selected="true"] { background: var(--accent, #1c5cab); border-color: var(--accent, #1c5cab); color: #fff; font-weight: 600; }
.pr-custom { display: flex; gap: 14px; flex-wrap: wrap; padding: 10px 20px; background: var(--surface-1); border-bottom: 1px solid var(--border); font-size: 13px; color: var(--text-secondary); }
.pr-custom input { font: inherit; padding: 5px 8px; border: 1px solid var(--border); border-radius: 8px; margin-left: 6px; background: var(--surface-1); color: var(--text-primary); }
.pr-body { padding: 16px 20px 20px; display: flex; flex-direction: column; gap: 14px; }
.pr-stats { display: grid; grid-template-columns: repeat(5, minmax(0, 1fr)); background: var(--surface-1); border: 1px solid var(--border); border-radius: 10px; overflow: hidden; }
.pr-stats > div { padding: 12px 14px; border-left: 1px solid var(--border); display: flex; flex-direction: column; gap: 1px; min-width: 0; }
.pr-stats > div:first-child { border-left: 0; }
.pr-stats span { font-size: 11.5px; color: var(--text-muted); }
.pr-stats b { font-size: 21px; font-weight: 650; font-variant-numeric: tabular-nums; }
.pr-vs { font-size: 11.5px; color: var(--text-muted); }
.pr-vs.up { color: var(--good); } .pr-vs.down { color: var(--critical); }
.pr-card { background: var(--surface-1); border: 1px solid var(--border); border-radius: 10px; padding: 14px 16px; }
.pr-card h3 { margin: 0 0 10px; font-size: 13px; font-weight: 650; }
.pr-note { font-weight: 400; color: var(--text-muted); font-size: 12px; margin-left: 4px; }
.pr-chart { width: 100%; height: auto; display: block; }
.pr-ax { fill: var(--text-muted); font: 11px var(--font); }
.pr-val { fill: var(--text-secondary); font: 600 11px var(--font); }
.pr-table-wrap { overflow-x: auto; }
.pr-table { width: 100%; border-collapse: collapse; font-size: 13px; font-variant-numeric: tabular-nums; }
.pr-table th { text-align: left; font-weight: 500; font-size: 11.5px; color: var(--text-muted); padding: 0 8px 8px; border-bottom: 1px solid var(--border); white-space: nowrap; }
.pr-table td { padding: 8px; border-bottom: 1px solid var(--grid, #eee); vertical-align: top; white-space: nowrap; }
.pr-table tfoot td { font-weight: 650; border-bottom: 0; border-top: 1px solid var(--neutral-mark); }
.pr-table .r { text-align: right; }
.pr-stage { white-space: normal !important; font-size: 12px; color: var(--text-secondary); min-width: 160px; }
.pr-muted { color: var(--text-muted); font-size: 12px; }
.pr-pill { display: inline-block; font-size: 10.5px; font-weight: 600; padding: 1px 7px; border-radius: 999px; background: #fdf1d8; color: #6b4a00; vertical-align: 1px; }
.pr-pill.final { background: #e6f4e6; color: #0f5a0f; }
.pr-cols { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 14px; align-items: start; }
.pr-show { padding: 10px 0; border-top: 1px solid var(--grid, #eee); }
.pr-show:first-of-type { border-top: 0; padding-top: 0; }
.pr-show-top { display: flex; justify-content: space-between; gap: 10px; align-items: flex-start; }
.pr-kv { display: grid; grid-template-columns: auto 1fr; gap: 2px 12px; font-size: 12.5px; color: var(--text-secondary); margin-top: 6px; }
.pr-kv b { color: var(--text-primary); font-weight: 600; font-variant-numeric: tabular-nums; }
.pr-bar { margin-bottom: 9px; }
.pr-bar-top { display: flex; justify-content: space-between; gap: 10px; font-size: 13px; margin-bottom: 3px; }
.pr-bar-top span { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.pr-bar-top b { font-variant-numeric: tabular-nums; }
.pr-track { height: 6px; border-radius: 3px; background: var(--surface-2); overflow: hidden; }
.pr-track i { display: block; height: 100%; background: var(--series-1); border-radius: 3px; }
.pr-foot { margin: 0; font-size: 12px; color: var(--text-muted); }

@media (max-width: 760px) {
  .pr-backdrop { padding: 0; }
  .pr-modal { border-radius: 0; min-height: 100%; }
  .pr-head { padding-top: max(16px, env(safe-area-inset-top)); }
  .pr-stats { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .pr-stats > div { border-left: 0; border-top: 1px solid var(--border); }
  .pr-stats > div:nth-child(-n+2) { border-top: 0; }
  .pr-stats > div:nth-child(even) { border-left: 1px solid var(--border); }
  .pr-stats > div:last-child { grid-column: 1 / -1; border-left: 0; }
  .pr-cols { grid-template-columns: minmax(0, 1fr); }
  .pr-ch { display: none; }
  .pr-body { padding: 14px 12px 24px; }
}
.pr-custom[hidden] { display: none; }
.pr-chart { max-height: 160px; }

/* ==================================================================
   Shared extras: links, export buttons, toast, menus, About page,
   show report. Loaded by both versions; colors follow each skin.
   ================================================================== */
.go { display: inline-flex; align-items: center; gap: 4px; font: 600 12.5px var(--font); color: var(--accent, #1c5cab); text-decoration: none; margin-top: 10px; background: none; border: 0; padding: 0; cursor: pointer; }
.go:hover { text-decoration: underline; }

/* Export buttons */
.x-group { display: flex; gap: 6px; align-items: center; flex-wrap: wrap; justify-content: flex-end; }
.x-btn {
  display: inline-flex; align-items: center; gap: 4px; white-space: nowrap; cursor: pointer;
  border: 1px solid var(--border); background: var(--surface-1); color: var(--text-primary);
  border-radius: 8px; padding: 5px 10px; font: 550 12.5px var(--font);
}
.x-btn:hover:not(:disabled) { border-color: var(--accent, #1c5cab); color: var(--accent, #1c5cab); }
.x-btn:disabled { opacity: .45; cursor: default; }
.x-btn[hidden] { display: none; }
.x-mini { padding: 2px 7px; font-size: 11px; border-radius: 6px; margin-left: 4px; vertical-align: 1px; }
.zip-nums .x-mini { margin: 4px 0 0; align-self: flex-end; }
.x-toast {
  position: fixed; left: 50%; bottom: max(24px, env(safe-area-inset-bottom)); transform: translateX(-50%); z-index: 200;
  background: #131a26; color: #fff; padding: 10px 16px; border-radius: 10px; font: 500 13px var(--font);
  box-shadow: 0 8px 24px -10px rgba(0,0,0,.5); animation: pr-fade .25s ease both; max-width: calc(100vw - 32px);
}
.rfm-grid .cell.picked { outline: 2.5px solid var(--text-primary); outline-offset: 1px; }
.heat-cell { cursor: pointer; }

/* Last night line (main Snapshot) */
.lastnight { display: flex; flex-wrap: wrap; align-items: baseline; gap: 4px 12px; background: var(--surface-1); border: 1px solid var(--border); border-radius: var(--radius); padding: 12px 16px; margin-bottom: var(--gap); font-size: 13.5px; color: var(--text-secondary); }
.lastnight b { color: var(--text-primary); }
.lastnight .ln-k { font-size: 11px; font-weight: 650; text-transform: uppercase; letter-spacing: .06em; color: var(--text-muted); }
.lastnight .go { margin: 0 0 0 auto; }

/* ⋯ menu */
.m-more { position: relative; margin-left: 4px; }
.m-dots {
  width: 34px; height: 32px; border-radius: 8px; border: 1px solid var(--border); background: var(--surface-2);
  color: var(--text-primary); font-size: 20px; line-height: 1; cursor: pointer; padding-bottom: 6px;
}
.appbar .m-dots { background: var(--navy-2, #1a2d4a); border-color: #2c4366; color: #fff; }
html[data-skin="gulf"] .appbar .m-dots { background: var(--surface-2); border-color: var(--border); color: var(--text-primary); }
.m-pop {
  position: absolute; right: 0; top: calc(100% + 8px); z-index: 60; min-width: 270px;
  background: var(--surface-1); color: var(--text-primary); border: 1px solid var(--border); border-radius: 12px;
  box-shadow: 0 18px 40px -16px rgba(0,0,0,.35); padding: 6px; animation: pr-fade .15s ease both;
}
.m-pop button, .m-items button {
  display: flex; align-items: center; gap: 10px; width: 100%; text-align: left; background: none; border: 0;
  padding: 9px 10px; border-radius: 8px; font: 500 13.5px var(--font); color: var(--text-primary); cursor: pointer;
}
.m-pop button:hover, .m-items button:hover { background: var(--surface-2); }
.m-pop i, .m-items i { font-style: normal; width: 18px; text-align: center; color: var(--text-muted); }
.m-note { font-size: 11.5px; color: var(--text-muted); padding: 8px 10px 4px; border-top: 1px solid var(--border); margin-top: 4px; }

/* ☰ menu (phones) */
.m-burger { display: none; width: 34px; height: 32px; border: 0; background: none; cursor: pointer; padding: 6px; flex-direction: column; justify-content: space-between; margin-right: 2px; }
.m-burger span { display: block; height: 2px; border-radius: 2px; background: currentColor; }
.m-drawer { position: fixed; inset: 0; z-index: 120; background: rgba(15,22,34,.45); animation: pr-fade .2s ease both; }
.m-drawer[hidden] { display: none; }
.m-panel {
  position: absolute; top: 0; bottom: 0; left: 0; width: min(310px, 86vw); overflow-y: auto;
  background: var(--surface-1); color: var(--text-primary); padding: max(16px, env(safe-area-inset-top)) 14px 24px;
  box-shadow: 8px 0 30px -12px rgba(0,0,0,.4); animation: m-in .22s cubic-bezier(.2,.7,.2,1) both;
}
@keyframes m-in { from { transform: translateX(-24px); opacity: 0; } to { transform: none; opacity: 1; } }
.m-head { display: flex; align-items: center; gap: 10px; font-size: 18px; }
.m-head img { border-radius: 7px; }
.m-x { margin-left: auto; border: 1px solid var(--border); background: var(--surface-1); border-radius: 8px; width: 32px; height: 32px; cursor: pointer; }
.m-venue { font-size: 12.5px; color: var(--text-muted); margin: 4px 0 14px 36px; }
.m-tabs { display: flex; flex-direction: column; gap: 2px; }
.m-tabs a { padding: 10px 12px; border-radius: 10px; color: var(--text-primary); text-decoration: none; font-weight: 550; }
.m-tabs a[aria-current] { background: var(--surface-2); box-shadow: inset 3px 0 0 var(--accent, #1c5cab); }
.m-label { font-size: 11px; font-weight: 650; letter-spacing: .06em; text-transform: uppercase; color: var(--text-muted); margin: 18px 12px 6px; }
.m-markets { display: flex; flex-wrap: wrap; gap: 6px; padding: 0 8px; }
.m-markets button { border: 1px solid var(--border); background: var(--surface-1); border-radius: 999px; padding: 6px 12px; font: 500 13px var(--font); cursor: pointer; color: var(--text-primary); }
.m-markets button[aria-pressed="true"] { background: var(--accent, #1c5cab); border-color: var(--accent, #1c5cab); color: #fff; }
.m-foot { font-size: 11.5px; color: var(--text-muted); margin: 18px 12px 0; }

@media (max-width: 600px) {
  .m-burger { display: flex; }
  /* Phones: the ☰ menu holds the tabs, the market and the extras. */
  .nav, .appbar .nav { display: none; }
  .topbar .market, .topbar .badge { display: none; }
  .topbar, .appbar .topbar { flex-wrap: nowrap; gap: 8px; }
  .status { width: auto; margin-left: auto; }
  .brand-name { font-size: 18px; }
}
@media print {
  .m-more, .m-burger, .appbar .nav, .nav, .pr-link, .x-btn { display: none !important; }
}

/* About page */
.about { max-width: 1040px; margin: 0 auto; display: flex; flex-direction: column; gap: 28px; }
.about-hero { padding: 26px 0 6px; }
.about-kicker { font-size: 12px; font-weight: 650; letter-spacing: .08em; text-transform: uppercase; color: var(--accent, #1c5cab); margin: 0 0 8px; }
.about-hero h1 { font-size: clamp(28px, 4.2vw, 44px); line-height: 1.1; margin: 0 0 14px; letter-spacing: -0.02em; }
html[data-skin="gulf"] .about-hero h1 { font-family: var(--serif); font-weight: 600; letter-spacing: 0; }
.about-lede { font-size: 17px; color: var(--text-secondary); max-width: 720px; margin: 0; line-height: 1.55; }
.about-by { font-size: 13px; color: var(--text-muted); margin: 14px 0 0; }
.about-sec h2 { font-size: 20px; margin: 0 0 6px; }
html[data-skin="gulf"] .about-sec h2 { font-family: var(--serif); font-weight: 600; }
.about-sub, .about-p { color: var(--text-secondary); margin: 0 0 14px; max-width: 760px; line-height: 1.55; }
.about-key { display: inline-block; font-size: 11.5px; font-weight: 600; border-radius: 999px; padding: 1px 8px; margin-left: 6px; }
.about-key.demo { background: #e6f4e6; color: #0f5a0f; }
.about-key.more { background: var(--surface-2); color: var(--text-secondary); }
.about-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(280px, 1fr)); gap: 14px; }
.about-card { background: var(--surface-1); border: 1px solid var(--border); border-radius: var(--radius); padding: 16px 18px; }
html[data-skin="gulf"] .about-card { border: 0; box-shadow: 0 8px 24px -16px rgba(29,43,43,.25); }
.about-card h3 { margin: 0 0 8px; font-size: 15px; }
.about-card ul { margin: 0; padding: 0; list-style: none; display: flex; flex-direction: column; gap: 6px; font-size: 13.5px; }
.about-card li { padding-left: 18px; position: relative; color: var(--text-secondary); }
.about-card li::before { content: ""; position: absolute; left: 2px; top: 7px; width: 8px; height: 8px; border-radius: 50%; }
.about-card li.demo { color: var(--text-primary); }
.about-card li.demo::before { background: var(--good, #0f7a0f); }
.about-card li.more::before { border: 1.5px solid var(--neutral-mark); }
.about-sources { display: grid; grid-template-columns: repeat(auto-fill, minmax(300px, 1fr)); gap: 10px; }
.about-sources div { background: var(--surface-1); border: 1px solid var(--border); border-radius: 10px; padding: 12px 14px; display: flex; flex-direction: column; gap: 2px; }
.about-sources span { color: var(--text-secondary); font-size: 13px; }
.about-steps { margin: 0; padding-left: 20px; display: flex; flex-direction: column; gap: 10px; color: var(--text-secondary); max-width: 780px; line-height: 1.5; }
.about-steps b { color: var(--text-primary); }
.about-demo { border-top: 1px solid var(--border); padding-top: 22px; }
.about-cta { font-weight: 650; color: var(--accent, #1c5cab); text-decoration: none; }

/* Show report */
.sr-kicker { margin: 0 0 3px; font-size: 11px; font-weight: 650; text-transform: uppercase; letter-spacing: .07em; color: var(--accent, #1c5cab); }
.sr-head-r { display: flex; gap: 10px; align-items: center; }
.sr-times { display: flex; flex-direction: column; }
.sr-times div { display: grid; grid-template-columns: 120px auto 1fr; gap: 10px; align-items: baseline; padding: 7px 0; border-top: 1px solid var(--grid, #eee); font-size: 13px; }
.sr-times div:first-child { border-top: 0; }
.sr-times span { color: var(--text-muted); }
.sr-times b { font-variant-numeric: tabular-nums; }
.sr-times em { font-style: normal; font-size: 11.5px; color: #8a5a00; justify-self: end; }
.sr-times em.ok { color: var(--good, #0f7a0f); }
.sr-notes { display: flex; flex-direction: column; gap: 10px; }
.sr-notes div { display: grid; grid-template-columns: 120px 1fr; gap: 10px; align-items: baseline; }
.sr-notes p { margin: 0; font-size: 13.5px; color: var(--text-secondary); line-height: 1.45; }
.sr-tag { font-size: 11px; font-weight: 650; color: var(--text-secondary); background: var(--surface-2); border-radius: 6px; padding: 2px 7px; justify-self: start; }
.sr-open { background: none; border: 0; padding: 0; margin-top: 8px; font: 600 12.5px var(--font); color: var(--accent, #1c5cab); cursor: pointer; }
.sr-open:hover { text-decoration: underline; }
@media (max-width: 600px) {
  .sr-notes div { grid-template-columns: minmax(0, 1fr); gap: 4px; }
  .sr-times div { grid-template-columns: 104px auto; }
  .sr-times em { grid-column: 2; justify-self: start; }
}
@media (min-width: 1100px) {
  html[data-skin="gulf"] .appbar .m-more { align-self: flex-start; }
  html[data-skin="gulf"] .appbar .m-pop { left: 0; right: auto; }
}

/* ---------- Snapshot: show rows open a pop-up ---------- */
.sd-row { cursor: pointer; border-radius: 8px; }
.sd-row:hover { background: var(--surface-2); }
.sd-row:focus-visible { outline: 2px solid var(--accent, #1c5cab); outline-offset: 2px; }
.sd-more { color: var(--accent, #1c5cab); font-weight: 700; }
.sd-notes { margin: 0; padding-left: 18px; display: flex; flex-direction: column; gap: 8px; font-size: 13px; color: var(--text-secondary); line-height: 1.45; }
.sd-actions { display: flex; justify-content: space-between; align-items: center; gap: 12px; flex-wrap: wrap; }
.sd-actions .go { margin: 0; }

/* ---------- Snapshot: organization cards ---------- */
.org-cards { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: var(--gap); margin-bottom: var(--gap); }
.stack .org-cards { grid-template-columns: minmax(0, 1fr); margin: 0; }
.org-card {
  display: flex; flex-direction: column; gap: 3px; text-decoration: none; color: var(--text-primary);
  background: var(--surface-1); border: 1px solid var(--border); border-radius: var(--radius); padding: 14px 16px;
  transition: border-color .15s, box-shadow .15s;
}
.org-card:hover { border-color: var(--accent-light, #7fb0ee); box-shadow: 0 6px 18px -12px rgba(0,0,0,.3); }
.org-card .eyebrow { margin: 0 0 2px; font-size: 11px; font-weight: 650; letter-spacing: .06em; text-transform: uppercase; color: var(--text-muted); }
.org-card b { font-size: 15px; }
.org-card span { font-size: 12.5px; color: var(--text-secondary); }
.org-card em { font-style: normal; font-size: 12.5px; font-weight: 600; color: var(--accent, #1c5cab); margin-top: 4px; }
html[data-skin="gulf"] .org-card { border: 0; box-shadow: 0 1px 2px rgba(29,43,43,.05), 0 8px 24px -16px rgba(29,43,43,.22); }
@media (max-width: 700px) { .org-cards { grid-template-columns: minmax(0, 1fr); } }

/* ---------- Help desk ---------- */
.sev { display: inline-block; font-size: 10.5px; font-weight: 700; border-radius: 6px; padding: 2px 7px; white-space: nowrap; letter-spacing: .02em; }
.sev.s1 { background: #d03b3b; color: #fff; }
.sev.s2 { background: #fae3e3; color: #a12a2a; }
.sev.s3 { background: #fdf1d8; color: #7a5200; }
.sev.s4 { background: var(--surface-2); color: var(--text-secondary); }
.hd-systems { display: grid; grid-template-columns: repeat(auto-fill, minmax(190px, 1fr)); gap: 10px; margin-bottom: var(--gap); }
.hd-sys { display: flex; gap: 10px; align-items: flex-start; background: var(--surface-1); border: 1px solid var(--border); border-radius: 10px; padding: 10px 12px; }
.hd-sys > i { width: 10px; height: 10px; border-radius: 50%; margin-top: 4px; flex-shrink: 0; background: var(--good, #0f7a0f); box-shadow: 0 0 0 3px rgba(15,122,15,.15); }
.hd-sys.degraded > i { background: #e8a100; box-shadow: 0 0 0 3px rgba(232,161,0,.18); }
.hd-sys b { display: block; font-size: 13px; }
.hd-sys span { display: block; font-size: 11.5px; color: var(--text-muted); }
.hd-sys em { display: block; font-style: normal; font-size: 11.5px; color: #8a5a00; margin-top: 2px; }
html[data-skin="gulf"] .hd-sys { border: 0; box-shadow: 0 6px 18px -14px rgba(29,43,43,.3); }
.hd-row { display: grid; grid-template-columns: 54px minmax(0, 1fr) 190px; gap: 12px; align-items: start; padding: 11px 0; border-top: 1px solid var(--grid, #eee); }
.hd-row:first-child { border-top: 0; }
.hd-main b { font-size: 13.5px; }
.hd-meta { font-size: 12px; color: var(--text-muted); }
.hd-note { font-size: 12px; color: var(--text-secondary); margin-top: 3px; padding-left: 8px; border-left: 2px solid var(--border); }
.hd-when { display: flex; flex-direction: column; align-items: flex-end; gap: 1px; font-size: 11.5px; color: var(--text-muted); text-align: right; }
.hd-when b { font-size: 12.5px; color: var(--text-primary); }
.hd-when b.late, .hd-meta.late { color: var(--critical, #d03b3b); }
.hd-meta.soon { color: #8a5a00; }
.hd-meta.good { color: var(--good, #0f7a0f); }
.hd-row.done .hd-main b { font-weight: 550; }
.hd-area { display: flex; justify-content: space-between; gap: 10px; font-size: 12.5px; padding: 7px 0; border-top: 1px solid var(--grid, #eee); color: var(--text-secondary); }
.hd-area b { color: var(--text-primary); font-weight: 600; white-space: nowrap; }
.hd-levels summary { cursor: pointer; font-weight: 600; }
.hd-levtable { display: flex; flex-direction: column; gap: 10px; margin-top: 12px; }
.hd-levtable > div { display: grid; grid-template-columns: 60px 1fr; gap: 10px; align-items: start; }
.hd-levtable p { margin: 2px 0 0; font-size: 12.5px; color: var(--text-secondary); }
@media (max-width: 600px) {
  .hd-row { grid-template-columns: 50px minmax(0, 1fr); }
  .hd-when { grid-column: 2; align-items: flex-start; text-align: left; }
}

/* ---------- Budget ---------- */
.b-legend { display: flex; gap: 14px; flex-wrap: wrap; font-size: 12px; color: var(--text-secondary); margin: 2px 0 10px; }
.b-legend i { display: inline-block; width: 12px; height: 10px; border-radius: 3px; margin-right: 5px; vertical-align: -1px; }
.b-legend i.a, .b-bar i.a { background: var(--accent, #1c5cab); }
.b-legend i.c, .b-bar i.c { background: var(--accent-light, #7fb0ee); }
.b-legend i.p, .b-bar i.p { background: repeating-linear-gradient(135deg, #e8a33d 0 3px, #f7d9a6 3px 6px); }
.b-legend i.o { background: var(--surface-2); box-shadow: inset 0 0 0 1px var(--border); }
.b-row { display: grid; grid-template-columns: minmax(150px, 1.6fr) repeat(6, minmax(70px, 1fr)); gap: 4px 10px; align-items: center; padding: 10px 0 12px; border-top: 1px solid var(--grid, #eee); font-size: 13px; font-variant-numeric: tabular-nums; }
.b-head { border-top: 0; color: var(--text-muted); font-size: 11.5px; padding-top: 0; }
.b-row .r { text-align: right; }
.b-row .pos { color: var(--good, #0f7a0f); } .b-row .neg { color: var(--critical, #d03b3b); }
.b-name { font-weight: 600; }
.b-total { font-weight: 650; border-top: 1px solid var(--neutral-mark); }
.b-bar { grid-column: 1 / -1; height: 10px; border-radius: 5px; background: var(--surface-2); display: flex; overflow: visible; position: relative; box-shadow: inset 0 0 0 1px var(--border); }
.b-bar i { display: block; height: 100%; }
.b-bar i:first-child { border-radius: 5px 0 0 5px; }
.b-bar b { position: absolute; top: -4px; bottom: -4px; width: 2px; background: var(--text-primary); border-radius: 1px; }
.b-ph { display: flex; justify-content: space-between; gap: 12px; padding: 9px 0; border-top: 1px solid var(--grid, #eee); font-size: 13px; }
.b-ph:first-child { border-top: 0; }
.b-ph .r { text-align: right; white-space: nowrap; }
.b-reads { display: flex; flex-direction: column; gap: 8px; }
.b-reads > div { display: grid; grid-template-columns: 130px auto 1fr; gap: 10px; align-items: baseline; font-size: 13px; }
.b-reads span { color: var(--text-muted); }
.b-reads b { font-variant-numeric: tabular-nums; font-size: 15px; }
.b-reads em { font-style: normal; font-size: 12px; color: var(--text-secondary); }
.b-scale { position: relative; height: 14px; margin: 18px 0 6px; border-radius: 7px; background: var(--surface-2); box-shadow: inset 0 0 0 1px var(--border); }
.b-band { position: absolute; top: 0; bottom: 0; background: rgba(232,163,61,.35); border-radius: 7px; }
.b-scale > i { position: absolute; top: 2px; width: 10px; height: 10px; margin-left: -5px; border-radius: 50%; background: var(--accent-light, #7fb0ee); box-shadow: 0 0 0 2px var(--surface-1); }
.b-scale > i.exp { background: var(--accent, #1c5cab); }
.b-scale > b { position: absolute; top: -5px; bottom: -5px; width: 2px; background: var(--text-primary); }
.b-scale-key { display: flex; gap: 14px; flex-wrap: wrap; font-size: 11.5px; color: var(--text-muted); }
.b-scale-key i { display: inline-block; width: 9px; height: 9px; border-radius: 50%; background: var(--accent-light, #7fb0ee); margin-right: 4px; }
.b-scale-key i.exp { background: var(--accent, #1c5cab); }
.b-scale-key i.band { border-radius: 2px; background: rgba(232,163,61,.5); }
.b-scale-key i.bud { width: 2px; border-radius: 0; background: var(--text-primary); }
@media (max-width: 760px) {
  .b-row { grid-template-columns: minmax(0, 1fr) auto auto; }
  .b-row > span:nth-child(3), .b-row > span:nth-child(4), .b-row > span:nth-child(5) { display: none; }
  .b-head > span:nth-child(3), .b-head > span:nth-child(4), .b-head > span:nth-child(5) { display: none; }
  .b-row > span:nth-child(6) { display: none; }
  .b-reads > div { grid-template-columns: 110px 1fr; }
  .b-reads em { grid-column: 1 / -1; }
}

/* ---------- Call center monthly history ---------- */
.ch-open { font-size: 13px; padding: 7px 12px; }
.ch-modal { width: min(1120px, 100%); }
.ch-card { padding: 6px 4px 12px; }
.ch-wrap { overflow-x: auto; }
.ch-table { width: 100%; border-collapse: collapse; font-size: 13px; font-variant-numeric: tabular-nums; }
.ch-table th { font-weight: 500; font-size: 11.5px; color: var(--text-muted); padding: 8px 10px; border-bottom: 1px solid var(--border); white-space: nowrap; text-align: left; position: sticky; top: 0; background: var(--surface-1); }
.ch-table th:first-child, .ch-table td:first-child { position: sticky; left: 0; background: var(--surface-1); z-index: 1; }
.ch-table td { padding: 8px 10px; border-bottom: 1px solid var(--grid, #eee); white-space: nowrap; }
.ch-table .r { text-align: right; }
.ch-table tr.mtd td { color: var(--text-secondary); font-style: italic; }
.ch-table tfoot td { font-weight: 650; border-top: 1px solid var(--neutral-mark); border-bottom: 0; }
.ch-table .pos { color: var(--good, #0f7a0f); font-weight: 600; }
.ch-table .neg { color: var(--critical, #d03b3b); font-weight: 600; }

/* Help desk: who opened it, who's working it */
.hd-people { display: flex; flex-wrap: wrap; gap: 6px 14px; margin-top: 6px; }
.hd-person { display: inline-flex; align-items: center; gap: 6px; font-size: 12px; color: var(--text-primary); }
.hd-person em { font-style: normal; color: var(--text-muted); margin-right: 2px; }
.hd-person > i { width: 20px; height: 20px; border-radius: 50%; display: inline-grid; place-items: center; font-style: normal; font-size: 9.5px; font-weight: 700; background: var(--surface-2); color: var(--text-secondary); flex-shrink: 0; }
.hd-person > i.w { background: var(--accent, #1c5cab); color: #fff; }
.hd-person.un > i { background: #fdf1d8; color: #7a5200; }
.hd-person.un em { color: #8a5a00; font-weight: 650; }
.hd-toggles { display: flex; gap: 14px; flex-wrap: wrap; }

/* Show pop-up: trend projection */
.sd-trend { display: grid; grid-template-columns: 200px minmax(0, 1fr); gap: 16px; align-items: center; }
.sd-proj { display: flex; flex-direction: column; gap: 10px; }
.sd-proj > div { display: flex; flex-direction: column; }
.sd-proj span { font-size: 11.5px; color: var(--text-muted); }
.sd-proj b { font-size: 20px; font-weight: 650; font-variant-numeric: tabular-nums; }
.sd-proj em { font-style: normal; font-size: 11.5px; color: var(--text-secondary); }
.sd-proj em.up { color: var(--good, #0f7a0f); } .sd-proj em.down { color: var(--critical, #d03b3b); }
@media (max-width: 700px) {
  .sd-trend { grid-template-columns: minmax(0, 1fr); }
  .sd-proj { display: grid; grid-template-columns: 1fr 1fr; }
}
