/* Resources V2: the approved Lab layout (lab/lab.css), scoped to #v2Page .res-v2.
   App tokens from operato-design-system.css; Lab-only colours are local --rv-* with dark overrides.
   No :root tokens and no element-level globals, so nothing outside Resources changes. */
#v2Page .res-v2 {
  --rv-alloc-bg: #EEF0F6; --rv-alloc-ink: #3A4571; --rv-alloc-line: #D7DCEC;
  --rv-tent-bg: #FFFDF0; --rv-tent-ink: #5A5A12; --rv-tent-line: #D5D48A;
  --rv-off-a: #F4F5F7; --rv-off-b: #ECEEF2; --rv-sel: #E8EBF6;
  --rv-c1: #2F6F8F; --rv-c2: #3F7D5F;
  --rv-ease: var(--ease-standard, cubic-bezier(0.2, 0, 0, 1)); --rv-dur: var(--motion-duration-fast, 120ms);
  /* V2 shell tokens (body.v2-active) = the Lab's tokens; fallbacks are the Lab values. */
  --rv-ink: var(--ink, #16171c); --rv-ink2: var(--ink2, #43464e); --rv-ink3: var(--ink3, #5f6570);
  --rv-line: var(--line, #e8e9ec); --rv-line2: var(--line2, #f0f1f3); --rv-strong: var(--layer-02-line, #D9DDE4);
  --rv-page: var(--page, #f6f7f9); --rv-surf: var(--surface, #ffffff); --rv-surf2: var(--surface2, #fafbfc); --rv-mute: var(--surface-sunken, #F4F6FB);
  --rv-good: var(--status-good, #1D7A4D); --rv-good-bg: var(--status-good-bg, #E7F4EC); --rv-warn: var(--status-warn, #8F5400); --rv-warn-bg: var(--status-warn-bg, #FBF0DE);
  --rv-risk: var(--status-risk, #C0392B); --rv-risk-bg: var(--status-risk-bg, #FBEAE8); --rv-info: var(--info-fg, #1d62b8); --rv-info-bg: var(--info-soft, #e7f0fb);
  --rv-danger: var(--input-border-error, #D1293D);
  --rv-cta: var(--sulphur, #E8FF6B); --rv-cta-hover: var(--sulphur-500, #D4EB57); --rv-cta-press: var(--accent-pressed, #C0D63F); --rv-cta-ink: var(--surface-inverse, #0A0D14);
  --rv-sel-tint: var(--sulphur-wash, #fffdf0); --rv-sel-mark: var(--accent-stroke, #808F00);
  --rv-fs1: var(--fs-1, 11px); --rv-fs2: var(--fs-2, 12px); --rv-fs3: var(--fs-3, 14px); --rv-fs4: var(--fs-4, 16px); --rv-fs5: var(--fs-5, 24px);
  --rv-r-ctl: var(--radius-control, 6px); --rv-r-card: var(--radius-card, 8px); --rv-r-in: var(--input-radius, 10px);
  font-family: var(--font-sans, 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif); font-size: var(--rv-fs3); line-height: var(--line-height-snug, 1.35); color: var(--rv-ink);
  display: flex; flex-direction: column; min-height: 100%; background: var(--rv-page);
}
:root[data-theme="dark"] #v2Page .res-v2 {
  --rv-alloc-bg: rgba(122, 137, 214, 0.16); --rv-alloc-ink: #C9D0F2; --rv-alloc-line: rgba(122, 137, 214, 0.34);
  --rv-tent-bg: rgba(232, 255, 107, 0.08); --rv-tent-ink: #E8F2A6; --rv-tent-line: rgba(232, 255, 107, 0.36);
  --rv-off-a: rgba(255, 255, 255, 0.03); --rv-off-b: rgba(255, 255, 255, 0.07); --rv-sel: rgba(122, 137, 214, 0.22);
  --rv-c1: #6FB3D2; --rv-c2: #7CC49E;
}
#v2Page .res-v2 *, #v2Page .res-v2 *::before, #v2Page .res-v2 *::after { box-sizing: border-box; }
#v2Page .res-v2 button, #v2Page .res-v2 input, #v2Page .res-v2 select { font: inherit; color: inherit; }
#v2Page .res-v2 h2, #v2Page .res-v2 h3, #v2Page .res-v2 p { margin: 0; }
#v2Page .res-v2 .sr { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
#v2Page .res-v2.is-busy { cursor: progress; }
#v2Page .res-v2.is-busy .rv-stage :is(.rv-btn, .rv-blk, .rv-cand, .rv-row) { pointer-events: none; }
#v2Page .res-v2.is-busy .rv-stage::after { content: ""; position: fixed; left: 0; right: 0; top: 0; height: 2px; background: var(--rv-cta); animation: rv-bar 900ms var(--rv-ease) infinite; z-index: 60; }
@keyframes rv-bar { from { transform: translateX(-100%); } to { transform: translateX(100%); } }

/* Subbar 40px + context 36px (Lab) */
#v2Page .res-v2 .rv-subbar { min-height: 40px; display: flex; align-items: center; gap: 8px; padding: 0 16px; background: var(--rv-surf); border-bottom: 1px solid var(--rv-line2); }
#v2Page .res-v2 .rv-tabs { display: flex; gap: 4px; overflow-x: auto; scrollbar-width: none; min-width: 0; }
#v2Page .res-v2 .rv-tabs::-webkit-scrollbar { display: none; }
#v2Page .res-v2 .rv-sub { padding: 8px 12px; border-radius: var(--rv-r-ctl); border: 0; background: none; color: var(--rv-ink3); font-size: var(--rv-fs3); font-weight: 500; cursor: pointer; white-space: nowrap; transition: background var(--rv-dur) var(--rv-ease), color var(--rv-dur) var(--rv-ease); }
#v2Page .res-v2 .rv-sub:hover { color: var(--rv-ink); background: var(--rv-surf2); }
#v2Page .res-v2 .rv-sub.on { color: var(--rv-ink); background: var(--rv-page); font-weight: 600; }
#v2Page .res-v2 .rv-sub-end { margin-left: auto; display: flex; gap: 8px; align-items: center; padding: 8px 0; flex-wrap: wrap; justify-content: flex-end; }
#v2Page .res-v2 .rv-weeknav { display: flex; gap: 4px; align-items: center; }
#v2Page .res-v2-host { min-height: 100%; display: flex; flex-direction: column; }
#v2Page .res-v2-host > .res-v2 { flex: 1; }
#v2Page .res-v2 .rv-chip { height: 28px; padding: 0 12px; display: inline-grid; place-items: center; border: 1px solid var(--rv-line); border-radius: var(--rv-r-ctl); font-size: var(--rv-fs2); font-weight: 600; color: var(--rv-ink2); background: var(--rv-surf); white-space: nowrap; }
#v2Page .res-v2 .rv-chip.flat { border-color: transparent; background: none; color: var(--rv-ink3); font-weight: 500; }
#v2Page .res-v2 .rv-ctx { min-height: 36px; display: flex; align-items: center; padding: 0 16px; background: var(--rv-page); border-bottom: 1px solid var(--rv-line2); font-size: var(--rv-fs2); color: var(--rv-ink2); }
#v2Page .res-v2 .rv-stage { flex: 1; display: flex; flex-direction: column; min-height: 0; }

/* Buttons: default, hover, focus-visible, active, disabled, loading (is-busy) */
#v2Page .res-v2 .rv-btn { height: 32px; padding: 0 12px; border-radius: var(--rv-r-ctl); font-size: var(--rv-fs3); font-weight: var(--button-font-weight, 560); cursor: pointer; white-space: nowrap; display: inline-flex; align-items: center; justify-content: center; gap: 8px; transition: background var(--rv-dur) var(--rv-ease), border-color var(--rv-dur) var(--rv-ease), transform var(--rv-dur) var(--rv-ease); }
#v2Page .res-v2 .rv-btn.ghost { background: var(--rv-surf); border: 1px solid var(--rv-line); color: var(--rv-ink2); }
#v2Page .res-v2 .rv-btn.ghost:hover:not(:disabled) { border-color: var(--rv-strong); color: var(--rv-ink); }
#v2Page .res-v2 .rv-btn.ghost.danger { color: var(--rv-risk); }
#v2Page .res-v2 .rv-btn.ghost.danger:hover:not(:disabled) { border-color: color-mix(in srgb, var(--rv-risk) 45%, transparent); background: var(--rv-risk-bg); color: var(--rv-risk); }
#v2Page .res-v2 .rv-btn.ghost:active:not(:disabled) { background: var(--rv-surf2); }
#v2Page .res-v2 .rv-btn.pri { background: var(--rv-cta); border: 1px solid transparent; color: var(--rv-cta-ink); }
#v2Page .res-v2 .rv-btn.pri:hover:not(:disabled) { background: var(--rv-cta-hover); }
#v2Page .res-v2 .rv-btn.pri:active:not(:disabled) { background: var(--rv-cta-press); }
#v2Page .res-v2 .rv-btn:active:not(:disabled) { transform: scale(0.98); }
#v2Page .res-v2 .rv-btn:disabled { background: var(--surface-sunken, #F4F6FB); color: var(--text-disabled, #9BA3B7); border-color: var(--rv-line2); cursor: not-allowed; }
#v2Page .res-v2 .rv-btn.saving { cursor: progress; }
#v2Page .res-v2 .rv-spin { width: 12px; height: 12px; border: 2px solid currentColor; border-right-color: transparent; border-radius: 50%; animation: rv-rot 700ms linear infinite; }
@keyframes rv-rot { to { transform: rotate(360deg); } }
#v2Page .res-v2 .rv-btn.icon { width: 32px; padding: 0; font-size: var(--rv-fs4); }
#v2Page .res-v2 .rv-btn.full { width: 100%; height: auto; min-height: 32px; padding: 8px 12px; margin-top: 8px; white-space: normal; text-align: center; line-height: 1.3; }
#v2Page .res-v2 .rv-btn.sm { height: 28px; padding: 0 8px; font-size: var(--rv-fs2); }
#v2Page .res-v2 .rv-btn.link { height: auto; padding: 0; border: 0; background: none; color: var(--rv-ink); text-decoration: underline; text-decoration-color: var(--rv-strong); text-underline-offset: 3px; }
#v2Page .res-v2 .rv-btn.link:hover:not(:disabled) { text-decoration-color: currentColor; color: var(--link-text-hover, #6B7700); }
#v2Page .res-v2 .rv-btn.link.inv { color: inherit; margin-left: 8px; }
#v2Page .res-v2 :is(.rv-btn, .rv-sub, .rv-blk, .rv-nm, .rv-cand, .rv-row, .rv-link, .rv-zb, .rv-fc, .rv-banner):focus-visible,
#v2Page .res-v2 .rv-form :is(input, select, textarea):focus-visible, #v2Page .res-v2 .rv-seg-i:focus-within { outline: none; box-shadow: var(--v2-focus-ring, 0 0 0 2px #fff, 0 0 0 4px #4f5b93); }

/* Schedule */
#v2Page .res-v2 .rv-sched { flex: 1; display: grid; grid-template-columns: minmax(0, 1fr) 300px; min-height: 0; }
#v2Page .res-v2 .rv-main { padding: 12px 16px; display: flex; flex-direction: column; gap: 8px; min-width: 0; }
#v2Page .res-v2 .rv-insp { background: var(--rv-surf); border-left: 1px solid var(--rv-line2); padding: 16px; overflow: auto; }
#v2Page .res-v2 .rv-weekbar { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; min-height: 28px; }
#v2Page .res-v2 .rv-right { margin-left: auto; }
#v2Page .res-v2 .rv-zoom { display: flex; gap: 4px; }
#v2Page .res-v2 .rv-zb { height: 28px; padding: 0 8px; border: 1px solid var(--rv-line); background: var(--rv-surf); border-radius: var(--rv-r-ctl); font-size: var(--rv-fs2); font-weight: 600; cursor: pointer; color: var(--rv-ink2); }
#v2Page .res-v2 .rv-zb:hover { border-color: var(--rv-strong); color: var(--rv-ink); }
#v2Page .res-v2 .rv-zb:active { background: var(--rv-surf2); }
#v2Page .res-v2 .rv-zb.on { background: var(--rv-alloc-bg); color: var(--rv-alloc-ink); border-color: var(--rv-alloc-line); }
#v2Page .res-v2 .rv-grid { flex: 1; background: var(--rv-surf); border: 1px solid var(--rv-line2); border-radius: var(--rv-r-card); overflow: auto; min-height: 240px; position: relative; }
#v2Page .res-v2 .rv-ghead, #v2Page .res-v2 .rv-grow { display: grid; grid-template-columns: minmax(140px, 168px) repeat(5, minmax(84px, 1fr)) 80px; min-width: 700px; border-bottom: 1px solid var(--rv-line2); }
#v2Page .res-v2 .rv-ghead.one, #v2Page .res-v2 .rv-grow.one { grid-template-columns: minmax(140px, 168px) minmax(240px, 1fr) 80px; min-width: 480px; }
#v2Page .res-v2 .rv-ghead { background: var(--rv-page); position: sticky; top: 0; z-index: 2; }
#v2Page .res-v2 .rv-ghead > span { padding: 12px 12px; font-size: var(--rv-fs1); letter-spacing: 0.05em; text-transform: uppercase; color: var(--rv-ink3); font-weight: 600; text-align: center; }
#v2Page .res-v2 .rv-ghead > span:first-child { text-align: left; position: sticky; left: 0; background: var(--rv-page); }
#v2Page .res-v2 .rv-ghead > span.today { color: var(--rv-ink); }
#v2Page .res-v2 .rv-ghead em { font-style: normal; color: var(--rv-info); margin-left: 4px; }
#v2Page .res-v2 .rv-grow.sel .rv-nm { background: var(--rv-sel-tint); box-shadow: inset 2px 0 0 var(--rv-sel-mark); }
#v2Page .res-v2 .rv-grow.archived { opacity: 0.6; }
#v2Page .res-v2 .rv-nm { text-align: left; border: 0; background: var(--rv-surf); padding: 12px 12px; cursor: pointer; display: flex; flex-direction: column; gap: 4px; position: sticky; left: 0; z-index: 1; transition: background var(--rv-dur) var(--rv-ease); }
#v2Page .res-v2 .rv-nm:hover { background: var(--rv-surf2); }
#v2Page .res-v2 .rv-nm b { font-size: var(--rv-fs3); font-weight: 600; }
#v2Page .res-v2 .rv-nm b em { font-style: normal; font-weight: 500; font-size: var(--rv-fs1); color: var(--rv-ink3); }
#v2Page .res-v2 .rv-nm .s { font-size: var(--rv-fs1); color: var(--rv-ink3); }
#v2Page .res-v2 .rv-cell { min-height: 88px; border-left: 1px solid var(--rv-line2); padding: 4px; display: flex; flex-direction: column; gap: 4px; transition: background var(--rv-dur) var(--rv-ease); }
#v2Page .res-v2 .rv-cell.off { background: repeating-linear-gradient(-45deg, var(--rv-off-a), var(--rv-off-a) 6px, var(--rv-off-b) 6px, var(--rv-off-b) 12px); }
#v2Page .res-v2 .rv-cell.overday { box-shadow: inset 0 -3px 0 var(--rv-risk); }
#v2Page .res-v2 .rv-cell.drop-target { background: var(--rv-tent-bg); outline: 2px dashed var(--rv-cta-press); outline-offset: -2px; }
#v2Page .res-v2 .rv-blk { display: block; width: 100%; text-align: left; border-radius: var(--rv-r-ctl); padding: 4px 8px; font-size: var(--rv-fs2); line-height: 1.25; background: var(--rv-alloc-bg); color: var(--rv-alloc-ink); border: 1px solid var(--rv-alloc-line); cursor: pointer; display: flex; align-items: baseline; gap: 8px; min-width: 0; transition: transform var(--rv-dur) var(--rv-ease), box-shadow var(--rv-dur) var(--rv-ease); }
#v2Page .res-v2 .rv-blk .c { flex: 1; min-width: 0; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; overflow-wrap: anywhere; }
#v2Page .res-v2 .rv-blk .hr { flex: none; font-weight: 650; font-variant-numeric: tabular-nums; }
#v2Page .res-v2 .rv-blk.restricted .c { font-style: italic; }
#v2Page .res-v2 .rv-blk[draggable="true"] { cursor: grab; }
#v2Page .res-v2 .rv-blk:hover { transform: translateY(-1px); box-shadow: 0 2px 6px rgba(10, 13, 20, 0.08); }
#v2Page .res-v2 .rv-blk:active { cursor: grabbing; }
#v2Page .res-v2 .rv-blk.on { box-shadow: 0 0 0 2px var(--rv-sel-mark); }
#v2Page .res-v2 .rv-blk.tentative { background: var(--rv-tent-bg); color: var(--rv-tent-ink); border: 1px dashed var(--rv-tent-line); }
#v2Page .res-v2 .rv-blk.internal { background: var(--rv-page); color: var(--rv-ink2); border-color: var(--rv-line); }
#v2Page .res-v2 .rv-blk.to { background: var(--rv-mute); color: var(--rv-ink3); border-color: var(--rv-line2); cursor: default; }
#v2Page .res-v2 .rv-blk.to:hover { transform: none; box-shadow: none; }
#v2Page .res-v2 .rv-blk.dragging { opacity: 0.5; }
#v2Page .res-v2 .rv-flag { font-size: var(--rv-fs1); font-weight: 600; color: var(--rv-risk); padding: 0 4px; }
#v2Page .res-v2 .rv-load { display: flex; flex-direction: column; align-items: center; justify-content: center; border-left: 1px solid var(--rv-line2); font-size: var(--rv-fs3); font-weight: 650; font-variant-numeric: tabular-nums; text-align: center; padding: 4px; }
#v2Page .res-v2 .rv-load .sub { font-size: var(--rv-fs1); font-weight: 500; opacity: 0.75; margin-top: 1px; }
#v2Page .res-v2 .rv-load.ok { background: var(--rv-good-bg); color: var(--rv-good); }
#v2Page .res-v2 .rv-load.warn { background: var(--rv-warn-bg); color: var(--rv-warn); }
#v2Page .res-v2 .rv-load.over { background: var(--rv-risk-bg); color: var(--rv-risk); }
#v2Page .res-v2 .rv-load.unset { background: var(--rv-mute); color: var(--rv-ink3); font-size: var(--rv-fs2); }
#v2Page .res-v2 .rv-load.none { background: var(--rv-surf2); color: var(--rv-ink3); font-size: var(--rv-fs1); font-weight: 600; }
#v2Page .res-v2 .rv-ghead em.wk { color: var(--rv-ink3); font-weight: 500; text-transform: none; letter-spacing: 0; }
#v2Page .res-v2 .rv-foot-row { display: flex; justify-content: flex-end; font-size: var(--rv-fs2); }

/* Legend */
#v2Page .res-v2 .rv-legend { display: flex; gap: 8px; align-items: center; color: var(--rv-ink3); font-size: var(--rv-fs1); flex-wrap: wrap; }
#v2Page .res-v2 .rv-legend i { width: 14px; height: 14px; border-radius: var(--rv-r-ctl); display: inline-block; margin-right: 4px; vertical-align: -3px; border: 1px solid var(--rv-strong); }
#v2Page .res-v2 .rv-legend i.c { background: var(--rv-alloc-bg); border-color: var(--rv-alloc-line); }
#v2Page .res-v2 .rv-legend i.t { background: var(--rv-tent-bg); border: 1px dashed var(--rv-tent-line); }
#v2Page .res-v2 .rv-legend i.in { background: var(--rv-page); border-color: var(--rv-strong); }
#v2Page .res-v2 .rv-legend i.to { background: repeating-linear-gradient(-45deg, var(--rv-off-a), var(--rv-off-a) 3px, var(--rv-off-b) 3px, var(--rv-off-b) 6px); }
#v2Page .res-v2 .rv-legend i.ok { background: var(--rv-good-bg); border-color: var(--rv-good); }
#v2Page .res-v2 .rv-legend i.warn { background: var(--rv-warn-bg); border-color: var(--rv-warn); }
#v2Page .res-v2 .rv-legend i.risk { background: var(--rv-risk-bg); border-color: var(--rv-risk); }
#v2Page .res-v2 .rv-legend i.unset { background: var(--rv-mute); }
#v2Page .res-v2 .rv-legend i.none { background: var(--rv-surf2); border-style: dashed; }
#v2Page .res-v2 .rv-legend i.od { background: var(--rv-surf); box-shadow: inset 0 -2px 0 color-mix(in srgb, var(--rv-risk) 55%, transparent); }
#v2Page .res-v2 .cutex { display: inline-block; font-size: var(--rv-fs1); font-weight: 700; border-bottom: 2px solid var(--rv-strong); margin-right: 4px; }

/* Inspector content */
#v2Page .res-v2 .rv-lbl { font-size: var(--rv-fs1); font-weight: 600; letter-spacing: 0.06em; text-transform: uppercase; color: var(--rv-ink3); }
#v2Page .res-v2 .rv-lbl.gap-t { margin-top: 16px; }
#v2Page .res-v2 .rv-lbl.full { flex-basis: 100%; }
#v2Page .res-v2 .rv-note { font-size: var(--rv-fs2); color: var(--rv-ink3); line-height: 1.45; margin: 4px 0; }
#v2Page .res-v2 .rv-note.risk, #v2Page .res-v2 .v.risk { color: var(--rv-risk); }
#v2Page .res-v2 .rv-insp-h { font-size: var(--rv-fs4); font-weight: 650; letter-spacing: -0.02em; margin: 4px 0; }
#v2Page .res-v2 :is(.rv-insp-h, .rv-h2)[tabindex="-1"]:focus { outline: none; }
#v2Page .res-v2 .clamp { display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; overflow-wrap: anywhere; }
#v2Page .res-v2 .rv-h2 { font-size: var(--rv-fs5); font-weight: 650; letter-spacing: -0.02em; margin: 4px 0 12px; }
#v2Page .res-v2 .rv-h2.flat { margin: 0; }
#v2Page .res-v2 .rv-kv { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; margin: 12px 0; }
#v2Page .res-v2 .rv-kv > div, #v2Page .res-v2 .rv-kvstrip > div { background: var(--rv-surf2); border-radius: var(--rv-r-ctl); padding: 8px 12px; min-width: 0; }
#v2Page .res-v2 :is(.rv-kv, .rv-kvstrip) .k { font-size: var(--rv-fs1); text-transform: uppercase; letter-spacing: 0.04em; color: var(--rv-ink3); font-weight: 600; }
#v2Page .res-v2 :is(.rv-kv, .rv-kvstrip) .v { font-size: var(--rv-fs4); font-weight: 650; font-variant-numeric: tabular-nums; white-space: nowrap; margin-top: 8px; }
#v2Page .res-v2 .rv-kv .v.sm { font-size: var(--rv-fs2); }
#v2Page .res-v2 .rv-kv.one { grid-template-columns: 1fr; }
#v2Page .res-v2 .rv-sub-v { display: block; font-size: var(--rv-fs1); font-weight: 500; color: var(--rv-ink3); margin-top: 4px; }
#v2Page .res-v2 .rv-opt { border-top: 1px solid var(--rv-line2); padding: 12px 0 4px; margin-top: 8px; }
#v2Page .res-v2 .rv-opt > b { font-size: var(--rv-fs2); }
#v2Page .res-v2 .rv-kvstrip { display: grid; grid-template-columns: repeat(6, minmax(0, 1fr)); gap: 8px; }
#v2Page .res-v2 .rv-list { display: flex; flex-direction: column; gap: 8px; margin-top: 8px; }
#v2Page .res-v2 .rv-list.pad { padding: 0 16px 16px; }
#v2Page .res-v2 .rv-row { display: flex; justify-content: space-between; align-items: center; gap: 8px; padding: 8px; background: var(--rv-surf2); border: 0; border-radius: var(--rv-r-ctl); cursor: pointer; text-align: left; font-size: var(--rv-fs2); width: 100%; transition: background var(--rv-dur) var(--rv-ease); }
#v2Page .res-v2 .rv-row:hover:not(:disabled):not(.static) { background: var(--rv-mute); }
#v2Page .res-v2 .rv-row.on { background: var(--rv-sel-tint); box-shadow: inset 2px 0 0 var(--rv-sel-mark); }
#v2Page .res-v2 .rv-row.static { cursor: default; }
#v2Page .res-v2 .rv-row.total { background: none; border-top: 1px solid var(--rv-line2); border-radius: 0; font-weight: 600; }
#v2Page .res-v2 .rv-row-t { min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
#v2Page .res-v2 .rv-row b { flex: none; font-variant-numeric: tabular-nums; }
#v2Page .res-v2 .rv-row:active:not(:disabled):not(.static) { background: var(--rv-line); }
#v2Page .res-v2 .rv-row.tall > span { display: flex; flex-direction: column; gap: 4px; }
#v2Page .res-v2 .rv-row em { font-style: normal; color: var(--rv-ink3); }
#v2Page .res-v2 .rv-row:disabled { cursor: not-allowed; opacity: 0.6; }
#v2Page .res-v2 .rv-pair { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; margin-top: 8px; }
#v2Page .res-v2 .rv-pair .rv-btn { height: 32px; }
#v2Page .res-v2 .rv-callout { border-radius: var(--rv-r-card); padding: 12px; margin: 12px 0; background: var(--rv-page); }
#v2Page .res-v2 .rv-callout.risk { background: var(--rv-risk-bg); }
#v2Page .res-v2 .rv-callout p { font-size: var(--rv-fs2); color: var(--rv-ink2); margin-top: 4px; }
#v2Page .res-v2 .rv-profile { display: flex; gap: 12px; align-items: center; margin-bottom: 16px; }
#v2Page .res-v2 .rv-av { width: 48px; height: 48px; border-radius: 12px; background: var(--rv-alloc-bg); color: var(--rv-alloc-ink); display: grid; place-items: center; font-weight: 700; font-size: var(--rv-fs4); flex: none; }
#v2Page .res-v2 .rv-cand { width: 100%; display: flex; justify-content: space-between; align-items: center; gap: 8px; padding: 8px; margin-top: 8px; border: 1px solid var(--rv-line); border-radius: var(--rv-r-ctl); background: var(--rv-surf); text-align: left; cursor: pointer; transition: background var(--rv-dur) var(--rv-ease), border-color var(--rv-dur) var(--rv-ease); }
#v2Page .res-v2 .rv-cand:hover { border-color: var(--rv-strong); }
#v2Page .res-v2 .rv-cand.on { background: var(--rv-sel-tint); border-color: var(--rv-sel-mark); box-shadow: inset 2px 0 0 var(--rv-sel-mark); }
#v2Page .res-v2 .rv-cand.bad .rv-cand-n { color: var(--rv-risk); }

#v2Page .res-v2 .rv-cand > span:first-child { display: flex; flex-direction: column; gap: 4px; min-width: 0; }
#v2Page .res-v2 .rv-cand-n .rv-note { display: block; margin: 4px 0 0; }
#v2Page .res-v2 .rv-cand-n { text-align: right; font-variant-numeric: tabular-nums; font-weight: 600; white-space: nowrap; }
#v2Page .res-v2 .rv-fit { font-size: var(--rv-fs1); font-weight: 650; letter-spacing: 0.04em; text-transform: uppercase; }
#v2Page .res-v2 .rv-fit.match { color: var(--rv-good); }
#v2Page .res-v2 .rv-fit.mismatch { color: var(--rv-risk); }
#v2Page .res-v2 .rv-fit.unknown { color: var(--rv-ink3); }

/* Split screens (reassign, add, gap, profile, client, person trend) */
#v2Page .res-v2 .rv-split { flex: 1; display: grid; grid-template-columns: minmax(0, 1fr) 320px; min-height: 0; }
#v2Page .res-v2 .rv-pad { padding: 16px; display: flex; flex-direction: column; gap: 12px; min-width: 0; }
#v2Page .res-v2 .rv-pad.fill { flex: 1; }
#v2Page .res-v2 .rv-pad.narrow { max-width: 600px; }
#v2Page .res-v2 .rv-mod { background: var(--rv-surf); border: 1px solid var(--rv-line2); border-radius: var(--rv-r-card); overflow-x: auto; min-width: 0; }
#v2Page .res-v2 .rv-mod.p { padding: 12px 16px; }
#v2Page .res-v2 .rv-mod.tint-warn { background: linear-gradient(180deg, var(--rv-warn-bg) 0%, var(--rv-surf) 60%); }
#v2Page .res-v2 .rv-mod.tint-good { background: linear-gradient(180deg, var(--rv-good-bg) 0%, var(--rv-surf) 60%); }
#v2Page .res-v2 .rv-grow-fill { flex: 1; }
#v2Page .res-v2 .rv-mod-h { display: flex; justify-content: space-between; align-items: baseline; padding: 12px 16px 8px; }
#v2Page .res-v2 .rv-mod-h.flat { padding: 0 0 4px; }
#v2Page .res-v2 .rv-mod-h h3 { font-size: var(--rv-fs3); font-weight: 600; }
#v2Page .res-v2 .rv-banner { display: block; width: 100%; text-align: left; cursor: pointer; font-size: var(--rv-fs3); }
#v2Page .res-v2 .rv-gaptop { display: flex; flex-direction: column; gap: 8px; }
#v2Page .res-v2 .rv-gapbox { border-radius: var(--rv-r-card); padding: 12px 16px; }
#v2Page .res-v2 .rv-gapbox.risk { background: var(--rv-risk-bg); }
#v2Page .res-v2 .rv-gapbox.ok { background: var(--rv-good-bg); }
#v2Page .res-v2 .rv-gapbox .v { font-size: var(--rv-fs5); font-weight: 700; letter-spacing: -0.03em; font-variant-numeric: tabular-nums; }

/* Forms */
#v2Page .res-v2 .rv-form { display: flex; flex-direction: column; gap: 12px; max-width: 440px; }
#v2Page .res-v2 .rv-form.inline { max-width: none; flex-direction: row; flex-wrap: wrap; align-items: flex-end; background: var(--rv-surf); border: 1px solid var(--rv-line2); border-radius: var(--rv-r-card); padding: 12px 16px; }
#v2Page .res-v2 .rv-form label { display: flex; flex-direction: column; gap: 4px; font-size: var(--rv-fs1); font-weight: 600; letter-spacing: 0.05em; text-transform: uppercase; color: var(--rv-ink3); }
#v2Page .res-v2 .rv-form :is(input:not([type=radio]):not([type=checkbox]), select) { height: 32px; padding: 0 8px; border: 1px solid var(--input-border, var(--rv-line)); border-radius: var(--rv-r-in); background: var(--input-bg, var(--rv-surf)); color: var(--rv-ink); font-size: var(--rv-fs3); font-weight: 500; letter-spacing: 0; text-transform: none; min-width: 0; }
#v2Page .res-v2 .rv-form :is(input, select):hover:not(:disabled) { border-color: var(--input-border-hover, var(--rv-strong)); }
#v2Page .res-v2 .rv-form :is(input, select):disabled { opacity: 0.55; cursor: not-allowed; }
#v2Page .res-v2 .rv-form input::placeholder { color: var(--input-placeholder, var(--rv-ink3)); opacity: 0.7; }
#v2Page .res-v2 .rv-form-row { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
#v2Page .res-v2 .rv-form-actions { display: flex; gap: 8px; flex-wrap: wrap; }
#v2Page .res-v2 .rv-form-actions .rv-btn { height: 32px; }
#v2Page .res-v2 .rv-form-actions.full { flex-basis: 100%; }
#v2Page .res-v2 .rv-seg { border: 0; padding: 0; margin: 0; display: flex; gap: 8px; flex-wrap: wrap; }
#v2Page .res-v2 .rv-seg legend { font-size: var(--rv-fs1); font-weight: 600; letter-spacing: 0.05em; text-transform: uppercase; color: var(--rv-ink3); margin-bottom: 4px; padding: 0; }
#v2Page .res-v2 .rv-form .rv-seg-i { flex-direction: row; align-items: center; gap: 8px; height: 30px; padding: 0 12px; border: 1px solid var(--rv-line); border-radius: var(--rv-r-ctl); cursor: pointer; text-transform: none; letter-spacing: 0; font-size: var(--rv-fs2); font-weight: 600; color: var(--rv-ink2); background: var(--rv-surf); }
#v2Page .res-v2 .rv-form .rv-seg-i.on { background: var(--rv-alloc-bg); border-color: var(--rv-alloc-line); color: var(--rv-alloc-ink); }
#v2Page .res-v2 .rv-seg-i input { accent-color: var(--rv-alloc-ink); margin: 0; }
#v2Page .res-v2 .rv-form .rv-check { flex-direction: row; align-items: center; gap: 8px; text-transform: none; letter-spacing: 0; font-size: var(--rv-fs3); font-weight: 500; color: var(--rv-ink); }
#v2Page .res-v2 .rv-check em { font-style: normal; color: var(--rv-ink3); font-size: var(--rv-fs2); }
#v2Page .res-v2 .rv-need { margin: 0; font-size: var(--rv-fs2); font-weight: 560; color: var(--rv-ink); background: var(--rv-warn-bg); border-left: 3px solid var(--rv-warn); padding: 8px 12px; border-radius: var(--rv-r-ctl); }
#v2Page .res-v2 .rv-need[hidden], #v2Page .res-v2 .rv-client-why:empty { display: none; }
#v2Page .res-v2 .rv-err { font-size: var(--rv-fs2); color: var(--rv-risk); background: var(--rv-risk-bg); padding: 8px 12px; border-radius: var(--rv-r-ctl); }

/* Cards, tables, pills */
#v2Page .res-v2 .rv-cards { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 8px; }
#v2Page .res-v2 .rv-cards.two { grid-template-columns: repeat(2, minmax(0, 1fr)); }
#v2Page .res-v2 .rv-cards.four { grid-template-columns: repeat(4, minmax(0, 1fr)); }
#v2Page .res-v2 .rv-util-top { display: grid; grid-template-columns: 180px 180px 180px minmax(0, 1fr); gap: 8px; }
#v2Page .res-v2 .rv-kpi { background: var(--rv-surf); border: 1px solid var(--rv-line2); border-radius: var(--rv-r-card); padding: 12px 16px; min-width: 0; }
#v2Page .res-v2 .rv-kpi.tint-vio { background: linear-gradient(180deg, var(--rv-alloc-bg) 0%, var(--rv-surf) 62%); }
#v2Page .res-v2 .rv-kpi.tint-warn { background: linear-gradient(180deg, var(--rv-warn-bg) 0%, var(--rv-surf) 60%); }
#v2Page .res-v2 .rv-kpi .v { font-size: var(--rv-fs5); font-weight: 700; letter-spacing: -0.03em; line-height: 1.15; font-variant-numeric: tabular-nums; margin-top: 4px; }
#v2Page .res-v2 .rv-sr { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0; }
#v2Page .res-v2 .rv-dash { color: var(--rv-ink3); font-weight: 400; }
#v2Page .res-v2 .rv-att { list-style: none; margin: 8px 0 0; padding: 0; display: grid; gap: 8px; }
#v2Page .res-v2 .rv-att li { display: grid; min-width: 0; }
#v2Page .res-v2 .rv-att-n { font-size: var(--rv-fs2); font-weight: 600; color: var(--rv-ink); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
#v2Page .res-v2 .rv-att-v { font-size: var(--rv-fs2); color: var(--rv-ink3); font-variant-numeric: tabular-nums; }
#v2Page .res-v2 .rv-kpi .v.sm { font-size: var(--rv-fs4); margin-top: 12px; }
#v2Page .res-v2 .rv-chart { margin-top: 8px; padding: 0 4px 0 32px; color: var(--rv-ink); }
#v2Page .res-v2 .rv-plot { position: relative; height: 96px; }
#v2Page .res-v2 .rv-chart.tall .rv-plot { height: 160px; }
#v2Page .res-v2 .rv-plot svg { position: absolute; inset: 0; width: 100%; height: 100%; overflow: visible; }
#v2Page .res-v2 .rv-plot .grid { stroke: var(--rv-line); stroke-width: 1; }
#v2Page .res-v2 .rv-dot { position: absolute; width: 6px; height: 6px; margin: -3px 0 0 -3px; border-radius: 50%; }
#v2Page .res-v2 .rv-yt { position: absolute; left: -32px; width: 28px; text-align: right; transform: translateY(-50%); font-size: var(--rv-fs1); color: var(--rv-ink3); font-variant-numeric: tabular-nums; }
#v2Page .res-v2 .rv-xt { position: relative; height: 16px; margin-top: 4px; }
#v2Page .res-v2 .rv-xt span { position: absolute; transform: translateX(-50%); font-size: var(--rv-fs1); color: var(--rv-ink3); white-space: nowrap; font-variant-numeric: tabular-nums; }
#v2Page .res-v2 .rv-xt span.first { transform: none; }
#v2Page .res-v2 .rv-xt span.last { transform: translateX(-100%); }
#v2Page .res-v2 .rv-axis { display: flex; justify-content: space-between; padding: 0 0 0 5%; font-size: var(--rv-fs1); color: var(--rv-ink3); margin-top: 4px; font-variant-numeric: tabular-nums; }
#v2Page .res-v2 .rv-leg { display: flex; gap: 12px; flex-wrap: wrap; font-size: var(--rv-fs1); color: var(--rv-ink3); margin-top: 8px; }
#v2Page .res-v2 .rv-leg i { display: inline-block; width: 8px; height: 8px; border-radius: 2px; margin-right: 4px; }
#v2Page .res-v2 .rv-tbl { width: 100%; border-collapse: collapse; font-size: var(--rv-fs2); }
#v2Page .res-v2 .rv-tbl th { text-align: left; height: var(--table-header-height, 32px); font-size: var(--rv-fs2); color: var(--table-header-text, #6B7384); font-weight: var(--table-header-weight, 600); padding: 0 12px; border-bottom: 1px solid var(--rv-line); background: var(--table-header-bg, #FAFBFC); white-space: nowrap; }
#v2Page .res-v2 .rv-tbl td { padding: 8px 12px; border-bottom: 1px solid var(--rv-line2); }
#v2Page .res-v2 .rv-tbl.compact td { padding: 8px 12px; }
#v2Page .res-v2 .rv-tbl tbody tr.click { cursor: pointer; }
#v2Page .res-v2 .rv-tbl tbody tr.click:hover td { background: var(--rv-alloc-bg); }
#v2Page .res-v2 .rv-tbl tbody tr.click:focus-visible { outline: none; box-shadow: inset 0 0 0 2px var(--v2-focus, #4f5b93); }
#v2Page .res-v2 .rv-tbl .num { text-align: right; font-variant-numeric: tabular-nums; white-space: nowrap; }
#v2Page .res-v2 .rv-tbl td.act { white-space: nowrap; text-align: right; }
#v2Page .res-v2 .rv-tbl td.act .rv-btn + .rv-btn { margin-left: 4px; }
#v2Page .res-v2 .rv-foot { padding: 8px 12px; }
#v2Page .res-v2 .rv-link { border: 0; background: none; padding: 0; cursor: pointer; font-weight: 600; text-decoration: underline; text-decoration-color: var(--rv-strong); text-underline-offset: 3px; text-align: left; }
#v2Page .res-v2 .rv-link:hover { text-decoration-color: currentColor; color: var(--link-text-hover, #6B7700); }
#v2Page .res-v2 .rv-link.plain { text-decoration: none; }
#v2Page .res-v2 .rv-link.plain:hover { text-decoration: underline; }
#v2Page .res-v2 .rv-pill { display: inline-flex; align-items: center; gap: 4px; height: 20px; padding: 0 8px; border-radius: var(--radius-pill, 9999px); font-size: var(--rv-fs1); font-weight: 600; white-space: nowrap; }
#v2Page .res-v2 .rv-pill::before { content: ""; width: 6px; height: 6px; border-radius: 50%; background: currentColor; flex: none; }
#v2Page .res-v2 .rv-pill.good { background: var(--rv-good-bg); color: var(--rv-good); }
#v2Page .res-v2 .rv-pill.warn { background: var(--rv-warn-bg); color: var(--rv-warn); }
#v2Page .res-v2 .rv-pill.risk { background: var(--rv-risk-bg); color: var(--rv-risk); }
#v2Page .res-v2 .rv-pill.info { background: var(--rv-info-bg); color: var(--rv-info); }
#v2Page .res-v2 .rv-pill.neu { background: var(--rv-mute); color: var(--rv-ink2); }

/* Forecast */
#v2Page .res-v2 .rv-fc-wrap { padding: 12px; overflow-x: auto; }
#v2Page .res-v2 .rv-fc-row { --n: 8; display: grid; grid-template-columns: 140px repeat(var(--n), minmax(80px, 1fr)); gap: 4px; align-items: center; margin-bottom: 8px; min-width: calc(140px + var(--n) * 84px); }
#v2Page .res-v2 .rv-fc-row.head { margin-bottom: 4px; }
#v2Page .res-v2 .rv-fc-row.team > b { white-space: normal; line-height: 1.3; }
#v2Page .res-v2 .rv-fc-row.team { margin-top: 12px; padding-top: 12px; border-top: 1px solid var(--rv-line2); }
#v2Page .res-v2 .rv-fc-row > b { font-size: var(--rv-fs2); font-weight: 600; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
#v2Page .res-v2 .rv-fc { position: relative; min-height: 40px; padding: 4px; grid-auto-rows: auto; align-content: center; gap: 0; border-radius: var(--rv-r-ctl); display: grid; place-items: center; font-size: var(--rv-fs1); font-weight: 600; font-variant-numeric: tabular-nums; border: 0; cursor: pointer; transition: box-shadow var(--rv-dur) var(--rv-ease); }
#v2Page .res-v2 .rv-fc:hover { box-shadow: inset 0 0 0 1px var(--rv-strong); }
#v2Page .res-v2 .rv-fc.on { box-shadow: inset 0 0 0 2px var(--rv-sel-mark); }
#v2Page .res-v2 .rv-fc.ok { background: var(--rv-good-bg); color: var(--rv-good); }
#v2Page .res-v2 .rv-fc.warn { background: var(--rv-warn-bg); color: var(--rv-warn); }
#v2Page .res-v2 .rv-fc.risk { background: var(--rv-risk-bg); color: var(--rv-risk); }
#v2Page .res-v2 .rv-fc.unset { background: var(--rv-mute); color: var(--rv-ink3); }
#v2Page .res-v2 .rv-fc.none { background: var(--rv-surf2); color: var(--rv-ink3); font-weight: 500; border: 1px dashed var(--rv-line); }
#v2Page .res-v2 .rv-fc.cutcap { box-shadow: inset 0 -2px 0 var(--rv-strong); }
#v2Page .res-v2 .rv-fc.cutcap.on { box-shadow: inset 0 0 0 2px var(--rv-sel-mark), inset 0 -2px 0 var(--rv-strong); }
#v2Page .res-v2 .rv-fc .cut { position: absolute; top: 2px; right: 4px; font-size: var(--rv-fs1); font-weight: 700; color: var(--rv-ink3); line-height: 1; }

/* Empty, notices, skeleton, toast */
#v2Page .res-v2 .rv-empty { padding: 40px 16px; text-align: center; color: var(--rv-ink2); display: flex; flex-direction: column; align-items: center; gap: 8px; }
#v2Page .res-v2 .rv-empty b { color: var(--rv-ink); font-size: var(--rv-fs4); }
#v2Page .res-v2 .rv-empty.in-grid { padding: 32px 16px; }
#v2Page .res-v2 .rv-empty.inline { padding: 8px 12px; text-align: left; display: block; background: var(--rv-page); border: 1px dashed var(--rv-line); border-radius: var(--rv-r-card); font-size: var(--rv-fs2); }
#v2Page .res-v2 .rv-empty.inline b { font-size: inherit; }
#v2Page .res-v2 .rv-alert { margin: 8px 16px 0; padding: 8px 12px; border-radius: var(--rv-r-ctl); background: var(--rv-risk-bg); color: var(--rv-risk); display: flex; align-items: center; justify-content: space-between; gap: 12px; font-size: var(--rv-fs2); }
#v2Page .res-v2 .rv-note-bar { margin: 8px 16px 0; padding: 8px 12px; border-radius: var(--rv-r-ctl); background: var(--rv-info-bg); color: var(--rv-ink2); font-size: var(--rv-fs2); }
#v2Page .res-v2 .rv-sk { display: block; height: 12px; width: 100%; border-radius: 4px; background: var(--rv-surf2); margin: 4px 0; animation: rv-pulse 1.2s var(--rv-ease) infinite; }
#v2Page .res-v2 .rv-sk.w40 { width: 40%; } #v2Page .res-v2 .rv-sk.w60 { width: 60%; } #v2Page .res-v2 .rv-sk.big { height: 28px; width: 50%; } #v2Page .res-v2 .rv-sk.blk { height: 22px; }
#v2Page .res-v2 .rv-skrows { padding: 12px; }
@keyframes rv-pulse { 50% { opacity: 0.45; } }
#v2Page .res-v2 .rv-toast { position: fixed; bottom: 16px; left: 50%; transform: translateX(-50%); background: #16171c; color: #ffffff; padding: 8px 12px; border-radius: var(--rv-r-card); z-index: 50; box-shadow: 0 8px 24px rgba(22,23,28,.12); font-size: var(--rv-fs2); display: flex; align-items: center; max-width: calc(100vw - 32px); animation: rv-in 200ms var(--rv-ease); }
@keyframes rv-in { from { opacity: 0; transform: translate(-50%, 6px); } }
@media (prefers-reduced-motion: reduce) { #v2Page .res-v2 *, #v2Page .res-v2 *::before, #v2Page .res-v2 *::after { animation: none !important; transition: none !important; } }

/* Responsive */
@media (max-width: 1100px) {
  #v2Page .res-v2 .rv-util-top { grid-template-columns: 1fr 1fr; }
  #v2Page .res-v2 .rv-util-top > :last-child { grid-column: 1 / -1; }
  #v2Page .res-v2 .rv-kvstrip { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  #v2Page .res-v2 .rv-cards.four { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (max-width: 900px) {
  #v2Page .res-v2 .rv-sched, #v2Page .res-v2 .rv-split { grid-template-columns: 1fr; }
  #v2Page .res-v2 .rv-insp { border-left: 0; border-top: 1px solid var(--rv-line2); overflow: visible; }
  #v2Page .res-v2 .rv-subbar { flex-wrap: wrap; padding: 4px 12px; }
  #v2Page .res-v2 .rv-sub-end { margin-left: 0; width: 100%; justify-content: flex-start; padding: 4px 0 8px; }
  #v2Page .res-v2 .rv-grid { min-height: 0; flex: none; }
  #v2Page .res-v2 .rv-right { margin-left: 0; flex-basis: 100%; }
}
@media (max-width: 600px) {
  #v2Page .res-v2 .rv-main, #v2Page .res-v2 .rv-pad { padding: 12px 16px; }
  #v2Page .res-v2 .rv-ctx { padding: 8px 16px; }
  #v2Page .res-v2 .rv-subbar { padding: 4px 16px; }
  #v2Page .res-v2 .rv-insp { padding: 16px; }
  #v2Page .res-v2 .rv-tabs { -webkit-mask-image: linear-gradient(90deg, #000 85%, transparent); mask-image: linear-gradient(90deg, #000 85%, transparent); padding-right: 24px; }
  #v2Page .res-v2 .rv-blk { min-height: 32px; align-items: center; }
  #v2Page .res-v2 .rv-xt span.alt { display: none; }
  #v2Page .res-v2 .rv-util-top, #v2Page .res-v2 .rv-cards, #v2Page .res-v2 .rv-cards.two, #v2Page .res-v2 .rv-cards.four { grid-template-columns: 1fr; }
  #v2Page .res-v2 .rv-kvstrip { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  #v2Page .res-v2 .rv-ghead, #v2Page .res-v2 .rv-grow { grid-template-columns: 112px repeat(5, minmax(88px, 1fr)) 64px; }
  /* Day zoom fits a phone: person, the one day, week load. No sideways scroll. */
  #v2Page .res-v2 .rv-ghead.one, #v2Page .res-v2 .rv-grow.one { grid-template-columns: 96px minmax(0, 1fr) 64px; min-width: 0; }
  #v2Page .res-v2 .rv-grow.one .rv-blk { white-space: normal; overflow-wrap: anywhere; }
  #v2Page .res-v2 .rv-ghead.one > span { padding: 12px 8px; }
  #v2Page .res-v2 .rv-nm { padding: 8px; }
  #v2Page .res-v2 .rv-form-row { grid-template-columns: 1fr; }
  #v2Page .res-v2 .rv-h2 { font-size: var(--rv-fs5); }
  #v2Page .res-v2 .rv-btn, #v2Page .res-v2 .rv-btn.sm, #v2Page .res-v2 .rv-zb, #v2Page .res-v2 .rv-sub { min-height: 32px; }
  #v2Page .res-v2 .rv-btn.icon { width: 32px; }
  #v2Page .res-v2 .rv-load { position: sticky; right: 0; z-index: 1; box-shadow: -1px 0 0 var(--rv-line2); }
  #v2Page .res-v2 .rv-ghead > span:last-child { position: sticky; right: 0; background: var(--rv-page); }
  #v2Page .res-v2 .rv-load.none, #v2Page .res-v2 .rv-load.unset { background: var(--rv-surf2); }
  #v2Page .res-v2 .rv-note.rv-right { flex-basis: 100%; }
  /* Tables become cards below 600px */
  #v2Page .res-v2 .rv-tbl.stack thead { display: none; }
  #v2Page .res-v2 .rv-tbl.stack, #v2Page .res-v2 .rv-tbl.stack tbody, #v2Page .res-v2 .rv-tbl.stack tr, #v2Page .res-v2 .rv-tbl.stack td { display: block; width: 100%; }
  #v2Page .res-v2 .rv-tbl.stack tr { padding: 8px 12px; border-bottom: 1px solid var(--rv-line); }
  #v2Page .res-v2 .rv-tbl.stack td { display: flex; justify-content: space-between; gap: 12px; padding: 4px 0; border: 0; text-align: right; }
  #v2Page .res-v2 .rv-tbl.stack td::before { content: attr(data-l); font-size: var(--rv-fs1); letter-spacing: 0.05em; text-transform: uppercase; color: var(--rv-ink3); font-weight: 600; text-align: left; }
  #v2Page .res-v2 .rv-tbl.stack td:first-child { font-weight: 650; font-size: var(--rv-fs3); }
  #v2Page .res-v2 .rv-tbl.stack td[data-l=""]::before { content: none; }
  #v2Page .res-v2 .rv-tbl.stack td.act { justify-content: flex-end; padding-top: 8px; }
  #v2Page .res-v2 .rv-tbl.stack tbody tr.click:hover td { background: none; }
  #v2Page .res-v2 .rv-form.inline > label { flex: 1 1 140px; }
  #v2Page .res-v2 .rv-toast { left: 16px; right: 16px; transform: none; bottom: 12px; flex-wrap: wrap; animation: none; }
}
#v2Page .res-v2 .rv-weekbar > .rv-note.rv-right { flex-basis: 100%; margin-left: 0; }

/* Conflicts, alternatives and overrides (never silent) */
#v2Page .res-v2 .rv-conflict { border: 1px solid color-mix(in srgb, var(--rv-warn) 35%, transparent); background: var(--rv-warn-bg); border-radius: var(--rv-r-card); padding: 12px 16px; display: flex; flex-direction: column; gap: 8px; }
#v2Page .res-v2 .rv-conflict > b { color: var(--rv-warn); font-size: var(--rv-fs3); }
#v2Page .res-v2 .rv-conflict ul { margin: 0; padding-left: 16px; display: flex; flex-direction: column; gap: 4px; color: var(--rv-ink); font-size: var(--rv-fs2); }
#v2Page .res-v2 .rv-conflict textarea, #v2Page .res-v2 .rv-form textarea { min-height: 56px; padding: 8px 12px; border: 1px solid var(--rv-line); border-radius: var(--rv-r-in); background: var(--rv-surf); color: var(--rv-ink); font: inherit; font-size: var(--rv-fs3); resize: vertical; text-transform: none; letter-spacing: 0; font-weight: 400; }
#v2Page .res-v2 .rv-alts { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; }
#v2Page .res-v2 .rv-alts .rv-lbl { margin-right: 4px; }
#v2Page .res-v2 .rv-hist { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; }
#v2Page .res-v2 .rv-hist li { padding: 8px 0; border-bottom: 1px solid var(--rv-line2); font-size: var(--rv-fs2); display: flex; flex-direction: column; gap: 2px; }
#v2Page .res-v2 .rv-hist li:last-child { border-bottom: 0; }
#v2Page .res-v2 .rv-hist-mod { margin-top: 16px; max-width: 440px; }
#v2Page .res-v2 .rv-defs { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 8px 24px; margin: 0; padding: 12px 12px 0; }
#v2Page .res-v2 .rv-defs div { margin: 0; }
#v2Page .res-v2 .rv-defs dt { font-size: var(--rv-fs2); font-weight: 600; color: var(--rv-ink); }
#v2Page .res-v2 .rv-defs dd { margin: 0; font-size: var(--rv-fs2); color: var(--rv-ink3); }
#v2Page .res-v2 .rv-btn.danger-solid { background: var(--rv-danger); color: #fff; border: 1px solid transparent; }
#v2Page .res-v2 .rv-btn.danger-solid:hover:not(:disabled) { background: color-mix(in srgb, var(--rv-danger) 88%, #000); }
@media (max-width: 900px) { #v2Page .res-v2 .rv-defs { grid-template-columns: 1fr 1fr; } }
@media (max-width: 600px) { #v2Page .res-v2 .rv-defs { grid-template-columns: 1fr; } }
#v2Page .res-v2 .rv-fc .main { display: block; }
#v2Page .res-v2 .rv-fc .cue { display: block; font-size: var(--rv-fs1); font-weight: 600; }
/* Radii and colours from tokens */
#v2Page .res-v2 .rv-sk { border-radius: var(--radius-xs, 2px); }
#v2Page .res-v2 .rv-av { border-radius: var(--radius-xl, 12px); }
#v2Page .res-v2 .rv-toast { background: var(--surface-inverse, #0A0D14); color: var(--surface-elevated, #FFFFFF); }
/* The inline impact line repeats the side panel on wide screens; keep it where the panel drops below the form. */
@media (min-width: 901px) { #v2Page .res-v2 .rv-inline-impact { display: none; } }
@media (max-width: 600px) {
  #v2Page .res-v2 .rv-btn, #v2Page .res-v2 .rv-sub, #v2Page .res-v2 .rv-zb, #v2Page .res-v2 .rv-row, #v2Page .res-v2 .rv-cand { min-height: 44px; }
  /* Form choices and in-table links are touch targets too: the whole label or link is the 44px target. */
  #v2Page .res-v2 .rv-form .rv-seg-i { height: auto; min-height: 44px; }
  #v2Page .res-v2 .rv-form .rv-check { min-height: 44px; }
  #v2Page .res-v2 .rv-form .rv-check input, #v2Page .res-v2 .rv-form .rv-seg-i input { width: 20px; height: 20px; }
  #v2Page .res-v2 .rv-link { min-height: 44px; display: inline-flex; align-items: center; }
  #v2Page .res-v2 .rv-btn.sm, #v2Page .res-v2 .rv-btn.full, #v2Page .res-v2 .rv-fc, #v2Page .res-v2 .rv-grow .rv-blk { min-height: 44px; }   /* every tap target 44px on phones */
}

/* Headings receive focus only programmatically (after a screen change, for screen readers). They are not controls,
   so they show no focus ring; every interactive control keeps the app ring. */
body.v2-active #v2Page .res-v2 h2[tabindex="-1"]:is(:focus, :focus-visible), body.v2-active #v2Page .res-v2 .rv-insp-h[tabindex="-1"]:is(:focus, :focus-visible) { outline: none !important; box-shadow: none !important; }
