/* v1465 — 🧭 Command Center. Calm white / light grey, navy nav, one teal accent; red only for an urgent exception.
   Inert unless #ccRoot exists. 14–16 px body, labels beside every colour, keyboard focus visible. */
#ccRoot { --cc-navy: #0f1f3d; --cc-teal: #0f766e; --cc-teal-soft: #e6f4f2; --cc-ink: #0f172a; --cc-mute: #64748b; --cc-line: #e2e8f0;
  --cc-bg: #f6f8fa; --cc-card: #ffffff; --cc-red: #b91c1c; --cc-red-soft: #fef2f2; --cc-amber: #92400e; --cc-amber-soft: #fffbeb;
  font-size: 14px; color: var(--cc-ink); background: var(--cc-bg); border-radius: 10px; padding: 0 0 18px; }
#ccRoot * { box-sizing: border-box; }
#ccRoot button, #ccRoot input, #ccRoot select { font: inherit; }
#ccRoot :focus-visible { outline: 3px solid #0ea5e9; outline-offset: 2px; }
.cc-head { background: var(--cc-navy); color: #fff; padding: 14px 18px; border-radius: 10px 10px 0 0; display: flex; flex-wrap: wrap; gap: 10px 16px; align-items: center; }
.cc-head h1 { margin: 0; font-size: 20px; font-weight: 700; letter-spacing: .01em; }
.cc-head .cc-date { font-size: 13px; opacity: .8; margin-top: 2px; }
.cc-head .cc-grow { flex: 1 1 260px; }
.cc-search { display: flex; gap: 6px; flex: 1 1 280px; max-width: 520px; }
.cc-search input { flex: 1; min-width: 0; padding: 8px 10px; border-radius: 8px; border: 1px solid #334766; background: #16294d; color: #fff; }
.cc-search input::placeholder { color: #9fb0cc; }
.cc-btn { padding: 7px 12px; border-radius: 8px; border: 1px solid var(--cc-line); background: #fff; color: var(--cc-ink); cursor: pointer; font-weight: 600; font-size: 13px; line-height: 1.2; }
.cc-btn.cc-primary { background: var(--cc-teal); border-color: var(--cc-teal); color: #fff; }
.cc-btn.cc-ghost { background: transparent; border-color: #41557a; color: #fff; }
.cc-btn:disabled { opacity: .5; cursor: default; }
.cc-seg { display: inline-flex; border: 1px solid #41557a; border-radius: 8px; overflow: hidden; }
.cc-seg button { background: transparent; color: #cfd9ea; border: 0; padding: 7px 12px; cursor: pointer; font-weight: 600; font-size: 13px; }
.cc-seg button[aria-pressed="true"] { background: #fff; color: var(--cc-navy); }
.cc-menu { position: relative; }
.cc-menu summary { list-style: none; cursor: pointer; }
.cc-menu summary::-webkit-details-marker { display: none; }
.cc-menu-list { position: absolute; right: 0; top: calc(100% + 6px); background: #fff; color: var(--cc-ink); border: 1px solid var(--cc-line); border-radius: 10px; box-shadow: 0 8px 24px rgba(15,23,42,.14); min-width: 220px; z-index: 30; padding: 6px; }
.cc-menu-list button { display: block; width: 100%; text-align: left; background: none; border: 0; padding: 8px 10px; border-radius: 6px; cursor: pointer; font-size: 14px; }
.cc-menu-list button:hover, .cc-menu-list button:focus-visible { background: var(--cc-teal-soft); }
.cc-note { padding: 8px 18px; font-size: 13px; color: var(--cc-mute); display: flex; gap: 14px; flex-wrap: wrap; align-items: center; }
.cc-note .cc-others { background: #eff6ff; color: #1e3a8a; border: 1px solid #bfdbfe; border-radius: 8px; padding: 5px 10px; }   /* v1496 */
.cc-note .cc-tag { background: var(--cc-amber-soft); color: var(--cc-amber); border: 1px solid #fde68a; border-radius: 6px; padding: 2px 8px; font-weight: 600; }
/* v1474 — My Day as home: the failed-source banner, "Last refreshed", where a card goes, the classic-dashboard link */
.cc-banner { margin: 10px 18px 0; display: flex; gap: 10px; align-items: center; flex-wrap: wrap; background: var(--cc-red-soft); color: var(--cc-red);
  border: 1px solid #fecaca; border-radius: 10px; padding: 9px 12px; font-size: 13.5px; }
.cc-banner[hidden] { display: none; }
.cc-banner > span:nth-child(2) { flex: 1 1 260px; }
.cc-card-go { font-style: normal; font-size: 12px; font-weight: 600; color: var(--cc-teal); margin-top: auto; }
.cc-classic small { font-weight: 400; opacity: .75; }
.cc-linkbtn { border: 0; background: none; color: #1d4ed8; font-weight: 700; cursor: pointer; padding: 0; }
.cc-cards { display: grid; grid-template-columns: repeat(5, minmax(0, 1fr)); gap: 10px; padding: 8px 18px 4px; }
.cc-card { background: var(--cc-card); border: 1px solid var(--cc-line); border-radius: 10px; padding: 12px 14px; text-align: left; cursor: pointer; display: flex; flex-direction: column; gap: 4px; min-height: 92px; }
.cc-card[aria-pressed="true"] { border-color: var(--cc-teal); box-shadow: inset 0 0 0 2px var(--cc-teal-soft); }
.cc-card b { font-size: 26px; font-weight: 700; line-height: 1.1; }
.cc-card b.cc-unv { font-size: 15px; color: var(--cc-amber); }
.cc-card span { font-size: 13px; font-weight: 600; }
.cc-card i { font-style: normal; font-size: 12px; color: var(--cc-mute); }
.cc-card.cc-alert b { color: var(--cc-red); }
.cc-main { display: grid; grid-template-columns: minmax(0, 1fr) 340px; gap: 14px; padding: 8px 18px; align-items: start; }
.cc-panel { background: var(--cc-card); border: 1px solid var(--cc-line); border-radius: 10px; }
.cc-panel h2 { font-size: 15px; margin: 0; padding: 12px 14px; border-bottom: 1px solid var(--cc-line); display: flex; align-items: center; gap: 8px; }
.cc-panel h2 small { font-weight: 500; color: var(--cc-mute); font-size: 12px; margin-left: auto; }
.cc-chips { display: flex; flex-wrap: wrap; gap: 6px; padding: 10px 14px; border-bottom: 1px solid var(--cc-line); align-items: center; }
.cc-chip { border: 1px solid var(--cc-line); background: #fff; border-radius: 999px; padding: 5px 11px; cursor: pointer; font-size: 13px; font-weight: 600; color: var(--cc-ink); }
.cc-chip[aria-pressed="true"] { background: var(--cc-navy); color: #fff; border-color: var(--cc-navy); }
.cc-chip em { font-style: normal; font-weight: 500; opacity: .75; margin-left: 4px; }
/* v1535 — the Overdue chip says how it splits (follow-ups · collection calls) */
.cc-chip-sub { font-weight: 500; font-size: 11.5px; opacity: .75; margin-left: 6px; padding-left: 6px; border-left: 1px solid currentColor; }
/* v1544 — a "No owner · <tracker>" group on the By owner row: after the people, drawn quieter (dashed) */
.cc-chip.cc-chip-muted:not([aria-pressed="true"]) { border-style: dashed; opacity: .85; }
.cc-chips .cc-spacer { flex: 1; }
/* the table wraps inside its box — never a sideways scroll (Georges 13/11) */
.cc-table-wrap { overflow: visible; }
.cc-table { width: 100%; border-collapse: collapse; font-size: 14px; table-layout: fixed; }
.cc-table th { text-align: left; font-size: 12px; text-transform: uppercase; letter-spacing: .04em; color: var(--cc-mute); padding: 8px 8px; border-bottom: 1px solid var(--cc-line); }
.cc-table td { padding: 9px 8px; border-bottom: 1px solid #eef2f6; vertical-align: top; overflow-wrap: anywhere; }
.cc-table th:nth-child(1) { width: 19%; } .cc-table th:nth-child(2) { width: 15%; } .cc-table th:nth-child(3) { width: 16%; } .cc-table th:nth-child(4) { width: 13%; }
.cc-table th:nth-child(5) { width: 15%; } .cc-table th:nth-child(6) { width: 98px; } .cc-table th:nth-child(7) { width: 84px; } .cc-table th:nth-child(8) { width: 118px; }
.cc-table td:nth-child(6), .cc-table td:nth-child(7), .cc-table td:nth-child(8) { overflow-wrap: normal; }
.cc-table td:nth-child(6) .cc-late, .cc-table td:nth-child(6) .cc-sub { display: block; }   /* the date on one line, "2d late" / "in 1d" under it */
.cc-table tr[tabindex] { cursor: pointer; }
.cc-table tr[tabindex]:hover, .cc-table tr[tabindex]:focus-visible { background: #f8fafc; }
.cc-table tr.cc-p0 td:first-child { border-left: 4px solid var(--cc-red); }
.cc-table tr.cc-p1 td:first-child { border-left: 4px solid #d97706; }
.cc-table tr.cc-p2 td:first-child { border-left: 4px solid #0ea5e9; }
.cc-table tr.cc-p3 td:first-child { border-left: 4px solid #94a3b8; }
.cc-table tr.cc-p4 td:first-child { border-left: 4px solid transparent; }
.cc-pri { display: inline-block; font-size: 12px; font-weight: 700; padding: 2px 8px; border-radius: 6px; }
.cc-pri.cc-p0 { background: var(--cc-red-soft); color: var(--cc-red); }
.cc-pri.cc-p1 { background: var(--cc-amber-soft); color: var(--cc-amber); }
.cc-pri.cc-p2 { background: #eff6ff; color: #1d4ed8; }
.cc-pri.cc-p3 { background: #f1f5f9; color: #475569; }
.cc-pri.cc-p4 { background: #f8fafc; color: var(--cc-mute); }
.cc-why { color: var(--cc-mute); font-size: 12.5px; margin-top: 2px; }
.cc-client b { font-weight: 700; }
.cc-sub { color: var(--cc-mute); font-size: 12.5px; }
.cc-late { color: var(--cc-red); font-weight: 700; }
.cc-cont { display: inline-block; font-size: 11.5px; border: 1px solid #fecaca; color: var(--cc-red); border-radius: 6px; padding: 1px 6px; margin-top: 3px; }
.cc-cont.cc-cov { border-color: #fde68a; color: var(--cc-amber); }
.cc-act { padding: 5px 10px; border-radius: 7px; border: 1px solid var(--cc-teal); background: #fff; color: var(--cc-teal); font-weight: 700; font-size: 12.5px; cursor: pointer; white-space: normal; max-width: 100%; }
.cc-act:hover { background: var(--cc-teal-soft); }
.cc-owner i { font-style: normal; color: var(--cc-mute); font-size: 12px; }
.cc-unassigned { color: var(--cc-amber); font-weight: 700; }
.cc-empty { padding: 26px 14px; text-align: center; color: var(--cc-mute); }
.cc-more { display: block; width: 100%; padding: 10px; background: #f8fafc; border: 0; border-top: 1px solid var(--cc-line); cursor: pointer; font-weight: 600; color: var(--cc-teal); }
.cc-side { display: flex; flex-direction: column; gap: 14px; }
.cc-list { list-style: none; margin: 0; padding: 6px 0; }
.cc-list li { padding: 9px 14px; border-bottom: 1px solid #eef2f6; font-size: 13.5px; }
.cc-list li:last-child { border-bottom: 0; }
.cc-list li b { display: block; }
.cc-list li .cc-sub { display: block; margin-top: 2px; }
.cc-list li button { margin-top: 5px; }
.cc-fresh { display: grid; grid-template-columns: auto 1fr; gap: 6px 10px; padding: 10px 14px; font-size: 13px; align-items: start; }
.cc-dot { display: inline-block; width: 10px; height: 10px; border-radius: 50%; margin-right: 6px; vertical-align: middle; }
.cc-dot.ok { background: #15803d; } .cc-dot.stale { background: #d97706; } .cc-dot.failed { background: var(--cc-red); } .cc-dot.unverified { background: #94a3b8; }
.cc-status { font-weight: 700; white-space: nowrap; }
.cc-trends { padding: 8px 18px; }
.cc-trend-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 12px; }
.cc-trend { padding: 12px 14px; }
.cc-trend h3 { margin: 0 0 8px; font-size: 14px; }
.cc-bars { display: grid; grid-template-columns: 56px 1fr auto; gap: 4px 8px; align-items: center; font-size: 12.5px; }
.cc-bar { height: 12px; background: var(--cc-teal-soft); border-radius: 4px; position: relative; }
.cc-bar i { position: absolute; left: 0; top: 0; bottom: 0; background: var(--cc-teal); border-radius: 4px; }
.cc-bars .cc-val { font-variant-numeric: tabular-nums; white-space: nowrap; }
.cc-drawer-bg { position: fixed; inset: 0; background: rgba(15,23,42,.35); z-index: 1200; display: none; }
.cc-drawer-bg.open { display: block; }
.cc-drawer { position: fixed; top: 0; right: 0; bottom: 0; width: min(560px, 100vw); background: #fff; z-index: 1201; box-shadow: -8px 0 30px rgba(15,23,42,.2); transform: translateX(100%); transition: transform .18s ease; display: flex; flex-direction: column; font-size: 14px; }
.cc-drawer.open { transform: none; }
.cc-drawer header { padding: 14px 16px; border-bottom: 1px solid var(--cc-line); display: flex; gap: 10px; align-items: flex-start; }
.cc-drawer header h2 { margin: 0; font-size: 17px; flex: 1; }
.cc-drawer .cc-body { overflow: auto; padding: 8px 16px 20px; flex: 1; }
.cc-drawer section { margin: 12px 0; }
.cc-drawer section h3 { font-size: 13px; text-transform: uppercase; letter-spacing: .04em; color: var(--cc-mute); margin: 0 0 6px; }
.cc-kv { display: grid; grid-template-columns: 130px 1fr; gap: 4px 10px; font-size: 13.5px; }
.cc-kv div:nth-child(odd) { color: var(--cc-mute); }
.cc-diag { font-size: 12px; color: var(--cc-mute); padding: 6px 14px 10px; }
.cc-diag summary { cursor: pointer; font-weight: 600; }
.cc-diag table { font-size: 12px; border-collapse: collapse; margin-top: 6px; }
.cc-diag td { padding: 2px 8px 2px 0; }
.cc-home-row { display: flex; gap: 10px; align-items: center; }
.cc-sr { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); }
@media (max-width: 1100px) { .cc-cards { grid-template-columns: repeat(3, minmax(0, 1fr)); } .cc-main { grid-template-columns: 1fr; } .cc-trend-grid { grid-template-columns: 1fr; } }
@media (max-width: 720px) { #ccRoot { font-size: 15px; } .cc-cards { grid-template-columns: repeat(2, minmax(0, 1fr)); padding: 8px 10px; } .cc-main, .cc-trends, .cc-note { padding-left: 10px; padding-right: 10px; } .cc-banner { margin: 8px 10px 0; }
  .cc-head { padding: 12px; } .cc-table { font-size: 13.5px; }
  /* narrow: each line becomes a small card — two columns, the action on its own row, no sideways scroll */
  .cc-table thead { display: none; }
  .cc-table, .cc-table tbody { display: block; }
  .cc-table tr { display: grid; grid-template-columns: 1fr 1fr; gap: 2px 10px; padding: 8px 0 10px; border-bottom: 1px solid var(--cc-line); }
  .cc-table td { display: block; border-bottom: 0; padding: 2px 10px; }
  .cc-table td:nth-child(1), .cc-table td:nth-child(2), .cc-table td:nth-child(8) { grid-column: 1 / -1; }
  .cc-table td:nth-child(3)::before { content: "Policy · "; color: var(--cc-mute); font-size: 12px; }
  .cc-table td:nth-child(4)::before { content: "Stage · "; color: var(--cc-mute); font-size: 12px; }
  .cc-table td:nth-child(5)::before { content: "Next · "; color: var(--cc-mute); font-size: 12px; }
  .cc-table td:nth-child(6)::before { content: "Due · "; color: var(--cc-mute); font-size: 12px; }
  .cc-table td:nth-child(7)::before { content: "Owner · "; color: var(--cc-mute); font-size: 12px; }
  .cc-table tr.cc-p0 td:first-child, .cc-table tr.cc-p1 td:first-child, .cc-table tr.cc-p2 td:first-child, .cc-table tr.cc-p3 td:first-child { border-left-width: 4px; } }

/* v1488 — the header time while a read runs, and when the snapshot is older than 2 minutes */
#ccFreshAt.cc-fresh-busy { color: #0f766e; font-weight: 700; }
#ccFreshAt.cc-fresh-stale { color: #b45309; font-weight: 700; background: #fffbeb; border-radius: 6px; padding: 0 6px; }
/* v1488 — a card whose lines a search hides says so */
.cc-hidden-note { background: #fffbeb; color: #92400e; border: 1px solid #fde68a; border-radius: 8px; padding: 6px 10px; margin: 6px 0; font-size: 12.5px; }
/* v1507 — Assign an Unassigned line */
.cc-assign { margin-top: 4px; padding: 3px 9px; border-radius: 7px; border: 1px solid var(--cc-teal); background: var(--cc-teal-soft); color: var(--cc-teal); font-weight: 700; font-size: 12px; cursor: pointer; }
.cc-assign-form { display: flex; flex-wrap: wrap; gap: 4px; align-items: center; }
.cc-assign-form input { width: 100%; min-width: 0; padding: 5px 7px; border: 1px solid var(--cc-line); border-radius: 7px; font-size: 13px; }
/* v1503 — the queue's sort */
.cc-panel h2 .cc-sort { margin-left: 8px; font-size: 12.5px; font-weight: 600; color: var(--cc-mute); display: inline-flex; gap: 6px; align-items: center; }
.cc-panel h2 .cc-sort select { font: inherit; font-weight: 600; color: var(--cc-ink); border: 1px solid var(--cc-line); border-radius: 7px; padding: 4px 6px; background: #fff; }
/* v1501 — scope label, card-overlap note, MTD tag, WhatsApp errors in plain language (technical details folded) */
.cc-seg .cc-seg-lbl { align-self: center; padding: 0 8px 0 10px; font-size: 12px; color: #cfd9ea; text-transform: uppercase; letter-spacing: .05em; }
.cc-overlap { grid-column: 1 / -1; margin: 2px 0 0; font-size: 12.5px; color: var(--cc-mute); }
.cc-bars small { font-size: 10.5px; font-weight: 700; color: var(--cc-teal); background: var(--cc-teal-soft); border-radius: 4px; padding: 0 4px; }
.cc-fresh .wa-err-act { color: var(--cc-ink); }
.cc-fresh details.wa-err-tech summary, .d3-panel details.wa-err-tech summary { cursor: pointer; color: var(--cc-teal, #0f766e); font-weight: 600; font-size: 12px; }
@media (max-width: 700px) { .cc-seg .cc-seg-lbl { display: none; } }
