/* Registration Tracker — design-system Index/Compact-Detail surfaces.
   The status and event-type vocabularies replicate the prior surface
   exactly (tokens in design_tokens.css, kept for this module): solid
   pills mark action states (High Risk, Goal Met, Ahead); all other
   statuses are outlined colored text; event-type chips are color-coded
   by family (Live blue, Virtual pink, Webinar green, Meals orange). */

/* Status — shared geometry */
.rt-status {
  display: inline-block; padding: 2px 8px; border-radius: 4px;
  font-size: 0.75rem; font-weight: 500; white-space: nowrap;
}
/* Solid pills (action states) */
.rt-status--critical { background: var(--status-high-risk-bg); color: var(--status-high-risk-text); }
.rt-status--complete { background: var(--status-goal-met-bg);  color: var(--status-goal-met-text); }
.rt-status--ahead    { background: var(--status-ahead-bg);     color: var(--status-ahead-text); }
/* Outlined colored text (informational states) */
.rt-status--outlined { background: white; border: 1px solid var(--color-gray-300); }
.rt-status--danger   { color: var(--status-medium-risk-text); }
.rt-status--behind   { color: var(--status-some-risk-text); }
.rt-status--on-track { color: var(--status-on-track-text); }
.rt-status--early    { color: var(--status-early-text); }
.rt-status--no-goal  { color: var(--status-no-goal-text); }
.rt-status--no-data  { color: var(--status-no-data-text); }

/* Event-type chip — color-coded by family */
.rt-type {
  display: inline-flex; align-items: center; padding: 0.25rem 0.5rem;
  border-radius: 0.375rem; font-size: 0.75rem; font-weight: 500; white-space: nowrap;
}
.rt-type--live    { background: var(--event-type-live-bg);    color: var(--event-type-live-text); }
.rt-type--virtual { background: var(--event-type-virtual-bg); color: var(--event-type-virtual-text); }
.rt-type--webinar { background: var(--event-type-webinar-bg); color: var(--event-type-webinar-text); }
.rt-type--meal    { background: var(--event-type-meal-bg);    color: var(--event-type-meal-text); }

/* Zero / absent turnout values: present but muted (design-system zero state) */
.rt-zero { color: var(--color-slate-400); }

/* Number emphasis in table cells */
.rt-num-primary { font-weight: 700; font-size: 15px; }
.rt-num-strong  { font-weight: 600; }

/* Ratio — deliberately discrete (small, muted), matching the prior surface */
.rt-ratio { font-size: 11.5px; color: var(--fg-muted); }

/* --------- Index table fit (no horizontal scroll) ---------
   The column set is fixed and well-defined, so each column gets a
   tailored width (sized to its actual content) and cells use tighter
   8px side padding. Long mono headers (WEEKLY NEEDED, DAYS UNTIL)
   wrap to two lines instead of forcing column width. */
.rt-index .cpv1-tbl th,
.rt-index .cpv1-tbl td { padding-left: 8px; padding-right: 8px; }
.rt-index .cpv1-tbl th { white-space: normal; line-height: 1.25; }
.rt-index .cpv1-tbl .rt-col-status { width: 108px; }
.rt-index .cpv1-tbl td.rt-col-status { text-align: center; }
.rt-index .cpv1-tbl .rt-col-ratio  { width: 50px; text-align: right; font-variant-numeric: tabular-nums; }
.rt-index .cpv1-tbl .rt-col-type   { width: 170px; }
.rt-index .cpv1-tbl .rt-col-date   { width: 142px; }
.rt-index .cpv1-tbl .rt-col-num    { width: 64px; }
.rt-index .cpv1-tbl .rt-col-num-sm { width: 60px; }
.rt-index .cpv1-tbl .rt-col-num-lg { width: 72px; }
/* Expected attendance (turnout model): three-digit values; the header wraps like Weekly Needed.
   Paid for by the 8px trims above (num 72->64, num-lg 80->72, status 112->108) so Event Name keeps ~186px. */
.rt-index .cpv1-tbl .rt-col-expected { width: 66px; font-variant-numeric: tabular-nums; }
/* Slimmer chip geometry on the index so the longest type
   ("Dinner: Night Before Live") fits its column */
.rt-index .rt-type { padding: 2px 6px; font-size: 11.5px; }

/* Pristine landing: the table renders at full natural height with no
   viewport, no resize handle, no landmark — so the wrap itself closes
   the card with the bottom rounding the landmark normally provides. */
.rt-index .rt-tbl-wrap--static { border-radius: 0 0 4px 4px; }

/* Reset-to-defaults in the page head — visible whenever the panel is
   engaged; returns to the bare path (and the static table with it). */
.rt-index .rt-reset-link { font-size: 12.5px; color: var(--fg-muted); text-decoration: none; margin-right: 14px; }
.rt-index .rt-reset-link:hover { color: var(--fg); text-decoration: underline; }

/* Page-head link to the Turnout Model reference page (how Expected Attend. is calculated). */
.rt-index .rt-head-link { font-size: 12.5px; color: var(--fg-muted); text-decoration: none; margin-right: 14px; }
.rt-index .rt-head-link:hover { color: var(--fg); text-decoration: underline; }

/* Same link on the event page, under the Audience numbers. */
.rt-section-link { font-size: 12.5px; margin: 10px 0 0; }

/* Compact Detail head + section eyebrow — used by the Turnout Model reference page
   (app/views/turnout_model/index.html.erb; turnout_model.css depends on these). */
.rt-detail { max-width: 880px; margin: 0 auto; }
.rt-detail-head { margin: 4px 0 18px; }
.rt-detail-prefix { font-family: var(--font-mono); font-size: 11px; font-weight: 600; text-transform: uppercase; letter-spacing: 0.07em; color: var(--fg-muted); margin-bottom: 4px; }
.rt-detail-name { font-size: 22px; font-weight: 700; color: var(--fg); margin: 0 0 4px; }
.rt-detail-sub { display: flex; align-items: center; gap: 10px; font-size: 13px; color: var(--fg-muted); }
.rt-section { border-top: 1px solid var(--border); margin-top: 18px; padding-top: 14px; }
.rt-section h2 { font-family: var(--font-mono); font-size: 11px; font-weight: 600; text-transform: uppercase; letter-spacing: 0.07em; color: var(--fg-muted); margin: 0 0 10px; }

/* ------------------------------------------------------------------
   Event dashboard (show page) — Dashboard archetype at the 1280 shell.
   Static: inline SVG from RegistrationTrackerDashboardHelper, no script.
   One type scale: mono 11 (titles, axes, column heads, chart labels),
   mono 12.5 (values), mono 20 semibold (subtotal instrument numbers),
   mono 26 bold (the fraction and grand-total instrument numbers);
   sans 12.5 (legends, captions, chart row labels), sans 13 (body).
   docs/handoff/registration-tracker-dashboard/PROJECT_LOG.md
   ------------------------------------------------------------------ */
.rtd { font-family: var(--font-sans); font-size: 13px; color: var(--fg);
  --rtd-mono-s: 11px; --rtd-mono-m: 12.5px; --rtd-mono-l: 20px; --rtd-mono-xl: 26px; --rtd-sans-s: 12.5px; --rtd-sans-m: 13px;
  --rtd-blue: #2a78d6; --rtd-sh: 0 1px 2px rgba(15,23,42,.04), 0 1px 3px rgba(15,23,42,.06); }
.rtd a { color: inherit; text-decoration: none; }
.rtd .muted { color: var(--fg-3, var(--color-slate-500)); }
/* head */
.rtd-head { display: flex; flex-wrap: wrap; align-items: flex-start; gap: 10px 22px; padding: 2px 0 16px; border-bottom: 1px solid var(--border); margin-bottom: 18px; }
.rtd-head-block { flex: 1 1 320px; min-width: 0; display: flex; flex-direction: column; gap: 5px; }
.rtd-head-prefix { font-family: var(--font-mono); font-size: var(--rtd-mono-s); font-weight: 600; text-transform: uppercase; letter-spacing: .08em; color: var(--color-slate-500); }
.rtd-head-prefix a:hover { text-decoration: underline; }
.rtd-head-name { font-size: 26px; font-weight: 700; letter-spacing: -.015em; line-height: 1.1; margin: 0; overflow-wrap: anywhere; }
.rtd-head-sub { display: flex; align-items: center; gap: 10px; color: var(--fg-muted); flex-wrap: wrap; }
.rtd-head-sub .dot { color: var(--fg-faint); }
.rtd-head-meta { font-family: var(--font-mono); font-size: var(--rtd-mono-s); color: var(--color-slate-500); margin-top: 2px; }
.rtd-head-r { display: flex; gap: 14px; align-items: center; flex-shrink: 0; font-size: var(--rtd-sans-s); padding-top: 4px; }
.rtd-head-r a { color: var(--fg-muted); }
.rtd-head-r a:hover { color: var(--fg); text-decoration: underline; }
.rt-status--past { color: var(--color-slate-500); }
/* widget grid + chrome (the Dashboard archetype's .w / .w-head / .w-body, scoped) */
.rtd-grid { display: grid; grid-template-columns: repeat(12, 1fr); gap: 14px; }
.rtd-w { background: var(--surface); border: 1px solid var(--border); border-radius: 3px; box-shadow: var(--rtd-sh); overflow: hidden; display: flex; flex-direction: column; min-width: 0; }
.rtd-w-head { padding: 10px 14px; border-bottom: 1px solid var(--border); display: flex; align-items: center; gap: 10px; }
.rtd-w-title { font-family: var(--font-mono); font-size: var(--rtd-mono-s); text-transform: uppercase; letter-spacing: .08em; font-weight: 700; display: flex; align-items: baseline; gap: 8px; }
.rtd-w-count { font-family: var(--font-mono); font-size: var(--rtd-mono-s); color: var(--color-slate-500); font-weight: 500; text-transform: none; letter-spacing: 0; }
.rtd-w-body { padding: 14px; flex: 1; min-width: 0; }
.rtd-w-body--flush { padding: 0; overflow-x: auto; }
.rtd-grid .span-4 { grid-column: span 4; }
.rtd-grid .span-8 { grid-column: span 8; }
.rtd-grid .span-12 { grid-column: span 12; }
@media (max-width: 900px) { .rtd-grid .span-4, .rtd-grid .span-8 { grid-column: span 12; } }
/* goal widget: the fraction, its bar, the pace facts */
.rtd-hero { padding: 16px 14px 12px; border-bottom: 1px solid var(--border); }
.rtd-hero-n { font-family: var(--font-mono); font-size: var(--rtd-mono-xl); font-weight: 700; letter-spacing: -.02em; line-height: 1; white-space: nowrap; }
.rtd-hero-sep { font-family: var(--font-sans); font-size: var(--rtd-sans-s); font-weight: 500; color: var(--color-slate-500); letter-spacing: 0; margin: 0 8px; }
.rtd-hero-bar-row { display: flex; align-items: center; gap: 10px; margin-top: 12px; }
.rtd-hero-bar { flex: 1; height: 6px; background: var(--surface-2); border-radius: 3px; overflow: hidden; }
.rtd-hero-fill { height: 100%; background: var(--rtd-blue); border-radius: 3px; }
.rtd-hero-pct { font-family: var(--font-mono); font-size: var(--rtd-mono-m); font-weight: 600; min-width: 36px; text-align: right; }
.rtd-hero-note { font-size: var(--rtd-sans-s); color: var(--fg-muted); margin-top: 10px; }
.rtd-hero-note a { color: var(--color-blue-700); }
.rtd-kv { display: grid; grid-template-columns: max-content 1fr; }
.rtd-kv > div { padding: 8px 14px; border-bottom: 1px solid var(--border-faint); }
.rtd-kv > div:nth-child(odd) { color: var(--fg-muted); }
.rtd-kv > div:nth-child(even) { font-family: var(--font-mono); font-size: var(--rtd-mono-m); text-align: right; font-variant-numeric: tabular-nums; }
.rtd-kv > div:nth-last-child(-n+2) { border-bottom: none; }
/* charts */
.rtd-chart { display: block; }
.rtd-chart .ax { font-family: var(--font-mono); font-size: var(--rtd-mono-s); fill: var(--color-slate-500); paint-order: stroke; stroke: #fff; stroke-width: 3px; stroke-linejoin: round; }
.rtd-chart .lbl { font-family: var(--font-mono); font-size: var(--rtd-mono-s); font-weight: 600; fill: var(--fg); paint-order: stroke; stroke: #fff; stroke-width: 3px; stroke-linejoin: round; }
.rtd-chart .lbl-muted { fill: var(--color-slate-500); font-weight: 500; }
.rtd-chart .rowlbl { font-family: var(--font-sans); font-size: var(--rtd-sans-s); fill: var(--fg); }
.rtd-chart .colhead { font-family: var(--font-mono); font-size: var(--rtd-mono-s); font-weight: 600; letter-spacing: .06em; fill: var(--color-slate-500); text-transform: uppercase; }
.rtd-chart .colhead--total { fill: var(--fg); }
.rtd-chart .bignum { font-family: var(--font-mono); font-size: var(--rtd-mono-xl); font-weight: 700; fill: var(--fg); letter-spacing: -.02em; }
.rtd-chart .subnum { font-family: var(--font-mono); font-size: var(--rtd-mono-l); font-weight: 600; fill: var(--fg); letter-spacing: -.02em; }
.rtd-empty { font-size: var(--rtd-sans-s); color: var(--color-slate-500); padding: 28px 0; text-align: center; }
.rtd-legend { display: flex; gap: 16px; flex-wrap: wrap; font-size: var(--rtd-sans-s); color: var(--fg-muted); margin-top: 10px; }
.rtd-legend i { display: inline-block; width: 10px; height: 10px; border-radius: 2px; margin-right: 6px; vertical-align: -1px; }
.rtd-legend i.key-dash { width: 14px; height: 0; border-top: 2px dashed; border-radius: 0; vertical-align: 2px; }
.rtd-legend i.key-tick { width: 2px; height: 12px; background: var(--fg); border-radius: 0; vertical-align: -2px; }
.rtd-legend i.key-dot { border-radius: 50%; }
.rtd-legend i.key-arrow { width: 0; height: 0; border-radius: 0; border-top: 4px solid transparent; border-bottom: 4px solid transparent; border-right: 7px solid var(--fg); vertical-align: -1px; }   /* the day's check-ins */
.rtd-legend-wrap { padding: 10px 14px 12px; }
.rtd-legend-wrap .rtd-legend { margin-top: 0; }
/* tables: by group and the two record tables */
.rtd-table { width: 100%; border-collapse: collapse; }
.rtd-table th { font-family: var(--font-mono); font-size: var(--rtd-mono-s); text-transform: uppercase; letter-spacing: .05em; color: var(--color-slate-500); font-weight: 600; text-align: left; padding: 6px 9px; background: var(--color-slate-50); border-bottom: 1px solid var(--border); white-space: nowrap; }
.rtd-table td { padding: 7px 9px; border-bottom: 1px solid var(--border-faint); white-space: nowrap; max-width: 180px; overflow: hidden; text-overflow: ellipsis; }
.rtd-table td:first-child, .rtd-table th:first-child { padding-left: 14px; }
.rtd-table td:last-child, .rtd-table th:last-child { padding-right: 14px; }
.rtd-table tr:last-child td { border-bottom: none; }
.rtd-table tbody tr:hover td { background: var(--color-slate-50); }
.rtd-table .num { text-align: right; font-family: var(--font-mono); font-size: var(--rtd-mono-m); font-variant-numeric: tabular-nums; }
.rtd-table .zero { color: var(--color-slate-400); }
.rtd-table tr.sub td { font-weight: 600; border-top: 1px solid var(--border); border-bottom: 1px solid var(--border); }
.rtd-table tr.tot td { font-weight: 700; border-top: 3px double var(--border-strong); }
.rtd-table td.barcell { padding-top: 4px; padding-bottom: 4px; width: 380px; }
.rtd-rowbar { display: block; }
