/* ============================================================================
   PARITY ROOT group CSS — all R batches (r01–r06) consolidated.
   ----------------------------------------------------------------------------
   Mirrors src/components/root/ — app shell (rail, sidebar, kit, tags), tables
   (data/simple/excel + row actions), records (details/dialog/resource), media
   (picker/studio/field/thumb), calendars (month/week/year), and sharing/misc.
   Each batch's rules are kept in the original order (r01 before r02 …), so
   the cascade is identical to the old per-batch imports.
   ========================================================================== */

/* ── r01.css (1/6) ──────────────────────────────────────────── */

.parity-r01 {
  /* The old app's sidebar tokens, mapped onto the new app's runtime palette so
     tenant accent + light/dark flow through (they derive from `--ta-*`). */
  --sidebar: var(--ta-glass);
  --sidebar-solid: var(--ta-glass-solid);
  --sidebar-foreground: var(--ta-text);
  --sidebar-primary: var(--ta-accent);
  --sidebar-primary-foreground: #ffffff;
  --sidebar-accent: color-mix(in oklab, var(--ta-accent) 8%, var(--ta-surface));
  --sidebar-accent-foreground: var(--ta-accent-hover);
  --sidebar-border: var(--ta-border);
  --sidebar-ring: var(--ta-accent);

  /* App tone — an app's brand hue turned into a readable chip (old app.css
     `--app-tone-*` light steps; the dark block below swaps them). */
  --app-tone-soft-l: 0.955;
  --app-tone-soft-c: 0.04;
  --app-tone-ink-l: 0.44;
  --app-tone-ink-c: 0.13;
}

@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]):not([data-theme="dark"]) .parity-r01 {
    --app-tone-soft-l: 0.3;
    --app-tone-soft-c: 0.055;
    --app-tone-ink-l: 0.79;
    --app-tone-ink-c: 0.11;
  }
}
:root[data-theme="dark"] .parity-r01 {
  --app-tone-soft-l: 0.3;
  --app-tone-soft-c: 0.055;
  --app-tone-ink-l: 0.79;
  --app-tone-ink-c: 0.11;
}

/* The shell's frosted pane — the demo wrapper restores the old rail/spine blur
   (shared shell.css leaves `.shell-pane` blur-free; scoped to the demo only). */
.parity-r01 .shell-pane {
  -webkit-backdrop-filter: blur(24px) saturate(150%);
  backdrop-filter: blur(24px) saturate(150%);
}

/* ── The `--sidebar*` utility vocabulary (old Tailwind theme colours) ────── */
.parity-r01 .bg-sidebar { background-color: var(--sidebar); }
.parity-r01 .bg-sidebar-solid { background-color: var(--sidebar-solid); }
.parity-r01 .text-sidebar-foreground { color: var(--sidebar-foreground); }
.parity-r01 .text-sidebar-foreground\/40 { color: color-mix(in oklab, var(--sidebar-foreground) 40%, transparent); }
.parity-r01 .text-sidebar-foreground\/45 { color: color-mix(in oklab, var(--sidebar-foreground) 45%, transparent); }
.parity-r01 .text-sidebar-foreground\/55 { color: color-mix(in oklab, var(--sidebar-foreground) 55%, transparent); }
.parity-r01 .text-sidebar-foreground\/60 { color: color-mix(in oklab, var(--sidebar-foreground) 60%, transparent); }
.parity-r01 .text-sidebar-foreground\/70 { color: color-mix(in oklab, var(--sidebar-foreground) 70%, transparent); }
.parity-r01 .text-sidebar-foreground\/75 { color: color-mix(in oklab, var(--sidebar-foreground) 75%, transparent); }
.parity-r01 .text-sidebar-accent-foreground { color: var(--sidebar-accent-foreground); }
.parity-r01 .border-sidebar-border { border-color: var(--sidebar-border); }
.parity-r01 .border-sidebar-border\/70 { border-color: color-mix(in oklab, var(--sidebar-border) 70%, transparent); }
.parity-r01 .bg-sidebar-border\/70 { background-color: color-mix(in oklab, var(--sidebar-border) 70%, transparent); }
.parity-r01 .bg-sidebar-accent { background-color: var(--sidebar-accent); }
.parity-r01 .bg-sidebar-accent\/40 { background-color: color-mix(in oklab, var(--sidebar-accent) 40%, transparent); }
.parity-r01 .bg-sidebar-accent\/60 { background-color: color-mix(in oklab, var(--sidebar-accent) 60%, transparent); }
.parity-r01 .bg-sidebar-foreground\/10 { background-color: color-mix(in oklab, var(--sidebar-foreground) 10%, transparent); }

.parity-r01 .hover\:bg-sidebar-accent\/60:hover { background-color: color-mix(in oklab, var(--sidebar-accent) 60%, transparent); }
.parity-r01 .hover\:bg-sidebar-accent\/40:hover { background-color: color-mix(in oklab, var(--sidebar-accent) 40%, transparent); }
.parity-r01 .hover\:text-sidebar-foreground:hover { color: var(--sidebar-foreground); }
.parity-r01 .hover\:text-sidebar-foreground\/70:hover { color: color-mix(in oklab, var(--sidebar-foreground) 70%, transparent); }
.parity-r01 .group:hover .group-hover\:text-sidebar-foreground\/60 { color: color-mix(in oklab, var(--sidebar-foreground) 60%, transparent); }
.parity-r01 .group:hover .group-hover\:text-sidebar-foreground\/70 { color: color-mix(in oklab, var(--sidebar-foreground) 70%, transparent); }
.parity-r01 .group:hover .group-hover\:text-sidebar-foreground\/80 { color: color-mix(in oklab, var(--sidebar-foreground) 80%, transparent); }
.parity-r01 .focus-visible\:ring-sidebar-ring\/50:focus-visible {
  --tw-ring-color: color-mix(in oklab, var(--sidebar-ring) 50%, transparent);
}

/* Generic hover/outline faces the bundle omits but the ports use. */
.parity-r01 .hover\:bg-accent:hover { background-color: var(--ta-accent-soft); }
.parity-r01 .hover\:text-foreground:hover { color: var(--ta-text); }
.parity-r01 .hover\:border-ring\/40:hover { border-color: color-mix(in oklab, var(--ta-accent) 40%, transparent); }

/* ── `.tab-pill` — the platform's frosted tab pill (old app.css layer) ──────
   Resting pills are glass objects; the open one takes the accent wash + ink.
   No weight change on the active tab (colour carries the state). */
.parity-r01 .tab-pill {
  border: 1px solid transparent;
  color: var(--ta-muted);
  transition:
    color 140ms ease-out,
    background-color 140ms ease-out,
    border-color 140ms ease-out,
    box-shadow 140ms ease-out;
}
.parity-r01 .tab-pill:hover { color: var(--ta-text); }

.parity-r01 .tab-pill,
.parity-r01 .tab-pill[aria-current="page"],
.parity-r01 .tab-pill[data-state="active"] {
  border-color: var(--ta-border);
  background-color: var(--ta-glass);
  box-shadow: inset 0 1px 0 var(--ta-glass-rim), var(--ta-shadow-sm);
}
.parity-r01 .tab-pill[aria-current="page"],
.parity-r01 .tab-pill[data-state="active"] {
  color: var(--ta-accent);
  background-image: linear-gradient(
    color-mix(in oklab, var(--ta-accent) 12%, transparent),
    color-mix(in oklab, var(--ta-accent) 12%, transparent)
  );
}

/* ── `text-large-title` — the one Clarity type step missing from the bundle ── */
.parity-r01 .text-large-title {
  font-size: 1.75rem;
  line-height: 1.15;
  font-weight: 600;
  letter-spacing: -0.026em;
}

/* ── app-kit ListFrame — zero the vitrine `.glass-card`'s default padding ──
   A list frame's rows carry their own padding; the shared `.glass-card`
   rule would add a 1.25rem cushion around them. */
.parity-r01 .glass-card.list-frame { padding: 0; }

/* ── The `info` tone pair the bundle omits (StatusChip's auto-tone) ──────── */
.parity-r01 .bg-info-soft { background-color: oklch(0.95 0.04 236); }
.parity-r01 .text-info-ink { color: oklch(0.46 0.13 240); }
.parity-r01 .bg-info { background-color: var(--ta-info); }
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]):not([data-theme="dark"]) .parity-r01 .bg-info-soft { background-color: oklch(0.3 0.05 236); }
  :root:not([data-theme="light"]):not([data-theme="dark"]) .parity-r01 .text-info-ink { color: oklch(0.76 0.12 236); }
}
:root[data-theme="dark"] .parity-r01 .bg-info-soft { background-color: oklch(0.3 0.05 236); }
:root[data-theme="dark"] .parity-r01 .text-info-ink { color: oklch(0.76 0.12 236); }


/* ── r02.css (2/6) ──────────────────────────────────────────── */

/* ---- 1. Control-height aliases (the reference's paren utilities) ---------- */

.b13-h-control-sm {
  height: var(--h-control-sm);
}
.b13-size-control {
  width: var(--h-control);
  height: var(--h-control);
}
.b13-size-control-sm {
  width: var(--h-control-sm);
  height: var(--h-control-sm);
}

/* ---- 2. Field-tone badge/dot tones missing from the bundle --------------- */
/* old field-tone.ts TONE_CLASS (blue + the CRM stage ramp) — the bundle emits
   green/amber/red/slate; these carry the rest. Values are the old app.css
   oklch pairs (see the `.xls` ramp below for the `-soft`/`-ink`/`-dot` vars). */

.bg-info-soft {
  background-color: oklch(0.95 0.04 236);
}
.text-info-ink {
  color: oklch(0.46 0.13 240);
}
.bg-info {
  background-color: oklch(0.6 0.14 240);
}
.bg-stage-qualified-soft {
  background-color: var(--stage-qualified-soft);
}
.text-stage-qualified-ink {
  color: var(--stage-qualified-ink);
}
.bg-stage-proposal-soft {
  background-color: var(--stage-proposal-soft);
}
.text-stage-proposal-ink {
  color: var(--stage-proposal-ink);
}
.bg-stage-todo-soft {
  background-color: var(--stage-todo-soft);
}
.text-stage-todo-ink {
  color: var(--stage-todo-ink);
}
.bg-stage-negotiation-soft {
  background-color: var(--stage-negotiation-soft);
}
.text-stage-negotiation-ink {
  color: var(--stage-negotiation-ink);
}

/* The `bg-[var(--stage-qualified-dot)]` dots (old field-tone DOT_CLASS) —
   arbitrary-value utilities aren't emitted for the stage ramp, so spell them
   out. */
.bg-\[var\(--stage-todo-dot\)\] {
  background-color: var(--stage-todo-dot);
}
.bg-\[var\(--stage-qualified-dot\)\] {
  background-color: var(--stage-qualified-dot);
}
.bg-\[var\(--stage-proposal-dot\)\] {
  background-color: var(--stage-proposal-dot);
}
.bg-\[var\(--stage-negotiation-dot\)\] {
  background-color: var(--stage-negotiation-dot);
}

/* ---- 3. Fractional utilities the candidate walker missed ------------------ */

.bg-primary\/12 {
  background-color: color-mix(in oklab, var(--ta-accent) 12%, transparent);
}
.hover\:bg-foreground\/6:hover {
  background-color: color-mix(in oklab, var(--ta-text) 6%, transparent);
}
.not-sr-only {
  position: static;
  width: auto;
  height: auto;
  padding: 0;
  margin: 0;
  overflow: visible;
  clip: auto;
  white-space: normal;
}

/* ---- 4. The old content column is a size container ------------------------ */
/* simple-table's desktop/mobile split uses Tailwind `@md:` container queries
   (28rem+), which only resolve against the nearest size container. The old app
   content area was one; the app shell's main.container isn't, so restore it.
   Every other port omits bare @-prefixed utilities, so this is inert for them. */

main.container {
  container-type: inline-size;
}

/* simple-table's glass wrapper carries `rounded-lg` (no border utility), so
   the u03 stat-grid/data-table `rounded-xl+border` padding-zero doesn't cover
   it — the vitrine .glass-card's 1.25rem padding must not leak around the
   flush table. */
div.glass-card.overflow-hidden.rounded-lg {
  padding: 0;
}

/* ============================================================================
   5. The Excel sheet (old app.css `.xls-*`, token-remapped to --ta-*)
   ========================================================================== */

:root {
  /* old app.css stage ramp — soft/ink/dot triples the sheet's pills use. */
  --stage-stack-soft: oklch(0.963 0.002 90);
  --stage-stack-ink: oklch(0.495 0.006 90);
  --stage-stack-dot: oklch(0.72 0.004 90);
  --stage-todo-soft: oklch(0.955 0.042 205);
  --stage-todo-ink: oklch(0.425 0.095 210);
  --stage-todo-dot: oklch(0.62 0.13 205);
  --stage-waiting-soft: oklch(0.969 0.0015 90);
  --stage-waiting-ink: oklch(0.505 0.005 90);
  --stage-waiting-dot: oklch(0.76 0.003 90);
  --stage-replied-soft: oklch(0.951 0.055 78);
  --stage-replied-ink: oklch(0.445 0.095 68);
  --stage-replied-dot: oklch(0.74 0.15 72);
  --stage-new-soft: oklch(0.955 0.04 240);
  --stage-new-ink: oklch(0.44 0.13 243);
  --stage-new-dot: oklch(0.6 0.14 240);
  --stage-qualified-soft: oklch(0.955 0.04 268);
  --stage-qualified-ink: oklch(0.44 0.145 270);
  --stage-qualified-dot: oklch(0.56 0.16 268);
  --stage-proposal-soft: oklch(0.955 0.042 300);
  --stage-proposal-ink: oklch(0.445 0.15 300);
  --stage-proposal-dot: oklch(0.56 0.17 300);
  --stage-negotiation-soft: oklch(0.955 0.045 332);
  --stage-negotiation-ink: oklch(0.455 0.16 332);
  --stage-negotiation-dot: oklch(0.58 0.18 332);
  --stage-won-soft: oklch(0.952 0.045 155);
  --stage-won-ink: oklch(0.43 0.11 155);
  --stage-won-dot: oklch(0.62 0.15 155);
  --stage-lost-soft: oklch(0.958 0.022 25);
  --stage-lost-ink: oklch(0.485 0.09 25);
  --stage-lost-dot: oklch(0.66 0.11 25);
}

/* The sheet's own ground — `bg-background` resolves to the undefined
   `--background` outside the app tables' scope, so pin it to the surface. */
.xls {
  background-color: var(--ta-surface);
  user-select: none;
}
/* …except the text inside the inspector bar and the cell editors. */
.xls input {
  user-select: text;
}

/* ── The paper ── cells carry no borders; `--xls-edges` is the one hook. */
.xls-cell {
  box-shadow: var(--xls-edges, none);
}

/* Rows compose two tint layers rather than overwriting one background. */
.xls-row {
  background-color: var(--ta-surface);
  background-image:
    linear-gradient(var(--xls-hover, transparent), var(--xls-hover, transparent)),
    linear-gradient(var(--xls-wash, transparent), var(--xls-wash, transparent)),
    linear-gradient(var(--xls-app, transparent), var(--xls-app, transparent));
  border-bottom: 1px solid var(--ta-border);
}

.xls-row:hover {
  --xls-hover: color-mix(in oklab, var(--ta-text) 3%, transparent);
}

/* The frozen gutter and action rail are sticky, so body cells scroll under
   them: they need their own opaque paint. */
.xls-gutter,
.xls-actions {
  background-color: var(--ta-surface);
  background-image:
    linear-gradient(var(--xls-hover, transparent), var(--xls-hover, transparent)),
    linear-gradient(var(--xls-wash, transparent), var(--xls-wash, transparent)),
    linear-gradient(var(--xls-app, transparent), var(--xls-app, transparent));
}

.xls-gutter {
  border-right: 1px solid var(--ta-border);
  color: color-mix(in oklab, var(--ta-muted) 85%, transparent);
}

.xls-actions {
  border-left: 1px solid var(--ta-border);
}

/* A selected row/column marks itself in the accent INK rather than by filling
   its header grey-blue. */
.xls-gutter--sel {
  color: var(--ta-accent);
  font-weight: 500;
}

/* ── Header ── opaque, one rule beneath field names. */
.xls-head {
  background-color: var(--ta-surface);
  border-bottom: 1px solid var(--ta-border);
}

.xls-headcell {
  background-color: var(--ta-surface);
}

.xls-headcell--sorted {
  color: var(--ta-text);
}
.xls-headcell--colsel {
  background-image: linear-gradient(
    color-mix(in oklab, var(--ta-accent) 9%, transparent),
    color-mix(in oklab, var(--ta-accent) 9%, transparent)
  );
}

/* ── Selection ── the focus cell keeps the heavy ring. */
.xls-cell--insel {
  background-image: linear-gradient(
    color-mix(in oklab, var(--ta-accent) 10%, transparent),
    color-mix(in oklab, var(--ta-accent) 10%, transparent)
  );
}

.xls-cell--focus {
  border-radius: var(--ta-r-xs);
  outline: 2px solid var(--ta-accent);
  outline-offset: -2px;
}

.xls-editor {
  border-radius: var(--ta-r-xs);
  box-shadow: inset 0 0 0 2px var(--ta-accent);
}

/* ── Cell inks ── */
.xls-cell--muted {
  color: var(--ta-muted);
}
.xls-cell--overdue,
.xls-cell--urgent {
  color: oklch(0.505 0.17 25);
  font-weight: 500;
}
.xls-cell--mail {
  cursor: pointer;
}
.xls-cell--indent {
  padding-left: 34px;
}

.xls-detail {
  border-bottom: 1px solid var(--ta-border);
  background: var(--ta-surface);
}

/* ── Stage tones ── one pill shape, ten tone pairs off the --stage-* ramp. */
.xls-pill {
  display: inline-flex;
  min-width: 0;
  max-width: 100%;
  height: var(--h-control-sm);
  align-items: center;
  padding-inline: 0.5625rem;
  border-radius: var(--ta-r-sm);
  background-color: var(--xls-tone-soft, var(--ta-surface-2));
  color: var(--xls-tone-ink, var(--ta-muted));
  font-size: 0.8125rem;
  font-weight: 500;
  letter-spacing: 0;
  transition:
    background-color 140ms ease-out,
    color 140ms ease-out;
}

.xls-dot {
  background-color: var(--xls-tone-dot, var(--ta-muted));
}

.xls-stage--stack {
  --xls-tone-soft: var(--stage-stack-soft);
  --xls-tone-ink: var(--stage-stack-ink);
  --xls-tone-dot: var(--stage-stack-dot);
}
.xls-stage--todo,
.xls-stage--todo-todo {
  --xls-tone-soft: var(--stage-todo-soft);
  --xls-tone-ink: var(--stage-todo-ink);
  --xls-tone-dot: var(--stage-todo-dot);
}
.xls-stage--waiting {
  --xls-tone-soft: var(--stage-waiting-soft);
  --xls-tone-ink: var(--stage-waiting-ink);
  --xls-tone-dot: var(--stage-waiting-dot);
}
.xls-stage--replied,
.xls-stage--todo-doing {
  --xls-tone-soft: var(--stage-replied-soft);
  --xls-tone-ink: var(--stage-replied-ink);
  --xls-tone-dot: var(--stage-replied-dot);
}
.xls-stage--new {
  --xls-tone-soft: var(--stage-new-soft);
  --xls-tone-ink: var(--stage-new-ink);
  --xls-tone-dot: var(--stage-new-dot);
}
.xls-stage--qualified {
  --xls-tone-soft: var(--stage-qualified-soft);
  --xls-tone-ink: var(--stage-qualified-ink);
  --xls-tone-dot: var(--stage-qualified-dot);
}
.xls-stage--proposal {
  --xls-tone-soft: var(--stage-proposal-soft);
  --xls-tone-ink: var(--stage-proposal-ink);
  --xls-tone-dot: var(--stage-proposal-dot);
}
.xls-stage--negotiation {
  --xls-tone-soft: var(--stage-negotiation-soft);
  --xls-tone-ink: var(--stage-negotiation-ink);
  --xls-tone-dot: var(--stage-negotiation-dot);
}
.xls-stage--won,
.xls-stage--todo-done {
  --xls-tone-soft: var(--stage-won-soft);
  --xls-tone-ink: var(--stage-won-ink);
  --xls-tone-dot: var(--stage-won-dot);
}
.xls-stage--lost {
  --xls-tone-soft: var(--stage-lost-soft);
  --xls-tone-ink: var(--stage-lost-ink);
  --xls-tone-dot: var(--stage-lost-dot);
}

/* ── Row washes ── */
.xls-row--needs-reply {
  --xls-wash: color-mix(in oklab, var(--stage-replied-soft) 55%, transparent);
}
.xls-row--needs-reply .xls-gutter {
  color: var(--stage-replied-ink);
  font-weight: 500;
}
.xls-row--won {
  --xls-wash: color-mix(in oklab, var(--stage-won-soft) 40%, transparent);
}
.xls-row--lost {
  --xls-wash: color-mix(in oklab, var(--stage-lost-soft) 38%, transparent);
}
.xls-row--done {
  color: var(--ta-muted);
}

/* ── Structural rows ── */
.xls-row--batch {
  --xls-wash: color-mix(in oklab, var(--ta-text) 4%, transparent);
  border-bottom-color: var(--ta-border);
}
.xls-row--batch .xls-gutter {
  color: var(--ta-muted);
}
.xls-row--ghost {
  border-bottom-color: transparent;
}

/* Company blocks: an inset shadow (never a real border — the row heights are
   exact arithmetic). */
.xls-cocell--a {
  background-image: linear-gradient(
    color-mix(in oklab, var(--ta-text) 2%, transparent),
    color-mix(in oklab, var(--ta-text) 2%, transparent)
  );
}
.xls-cocell--b {
  background-image: linear-gradient(
    color-mix(in oklab, var(--ta-text) 0.8%, transparent),
    color-mix(in oklab, var(--ta-text) 0.8%, transparent)
  );
}
.xls-row--co-start,
.xls-row--co-start .xls-gutter,
.xls-row--co-start .xls-actions {
  box-shadow: inset 0 1px 0 color-mix(in oklab, var(--ta-border) 85%, transparent);
}

/* The app's base `button` (buttons.css) adds 0.5rem/1rem padding, a border and
   weight-600 type; the sheet's size-* buttons own their box, so zero it like
   the reference's preflight did. The inspector/editor inputs get the same
   treatment against the app's forms.css box. */
.xls button {
  padding: 0;
  border: 0;
  background: transparent;
  font-weight: inherit;
}
.xls input {
  padding: 0;
  border: 0;
  background: transparent;
  box-shadow: none;
}

@media (prefers-reduced-motion: reduce) {
  .xls *,
  .xls *::before,
  .xls *::after {
    transition-duration: 0.01ms !important;
    animation-duration: 0.01ms !important;
  }
}


/* ── r03.css (3/6) ──────────────────────────────────────────── */

/* SettingsCard (old ui/settings-list.tsx) — the vitrine `.glass-card` padding
   (1.25rem) would push the hairline-divided rows in from the card edge;
   neutralize it so the rows run edge to edge, as in the reference. */
.r03-settings-card.glass-card {
  padding: 0;
}

/* RecordDialog sheet — the static right-side sheet pane. Position/size come
   from Tailwind on the element; this adds the lifted shadow (shadow-2xl is
   not in the shared bundle) and the hairline it sits on. */
.r03-sheet {
  box-shadow: -24px 0 60px -18px rgb(0 0 0 / 0.35);
}

/* StorageRetentionCard slider — a static range slider matching the shadcn
   Slider face (6px track, accent fill, 20px thumb with a ring). */
.r03-slider {
  position: relative;
  display: flex;
  align-items: center;
  height: 1.25rem;
}

.r03-slider-track {
  position: relative;
  width: 100%;
  height: 0.375rem;
  border-radius: 9999px;
  background: var(--ta-muted);
}

.r03-slider-fill {
  position: absolute;
  inset-block: 0;
  left: 0;
  border-radius: 9999px;
  background: var(--ta-accent);
}

.r03-slider-thumb {
  position: absolute;
  top: 50%;
  width: 1.25rem;
  height: 1.25rem;
  border-radius: 9999px;
  background: var(--ta-surface);
  border: 1px solid var(--ta-border-strong);
  box-shadow: 0 1px 2px rgb(0 0 0 / 0.15);
  transform: translate(-50%, -50%);
}


/* ── r04.css (4/6) ──────────────────────────────────────────── */

/* The old app's control-height utility pair (`h-(--h-control)` /
 * `h-(--h-control-sm)`) — the variant-picker rows and the media-cell chips
 * carry them verbatim. The bundle normally provides them; these fallbacks
 * keep the row/chip height stable regardless of bundle churn.
 */
.h-\(--h-control\) {
  height: var(--h-control, 34px);
}
.h-\(--h-control-sm\) {
  height: var(--h-control-sm, 22px);
}


/* ── r05.css (5/6) ──────────────────────────────────────────── */

/* Week calendar: cap the time grid height so a tall day scrolls instead of
   blowing the card (the reference's `overflow-y-auto max-h-[36rem]`). */
.max-h-\[36rem\] {
  max-height: 36rem;
}

/* Month calendar: drop the right border on the 7th cell of each week row —
   the reference's `[&:nth-child(7n)]:border-r-0` (Tailwind arbitrary variant,
   not in the compiled utilities bundle). */
.\[\&\:nth-child\(7n\)\]\:border-r-0 {
  border-right-width: 0;
}


/* ── r06.css (6/6) ──────────────────────────────────────────── */

.r06-chart {
  --chart-1: #3b82f6;
  --chart-2: #8b5cf6;
  --chart-3: #22c55e;
  --chart-4: #f59e0b;
  --chart-5: #ef4444;
  --chart-6: #0ea5e9;
  --chart-7: #ec4899;
  --chart-8: #64748b;
}

/* The fixed-overlay demo pages (share-dialog, plan-lock, create-button,
   action-note) reuse u02's stage + toaster grammar, so their scrim/content are
   painted immediately (no entrance fade) — the same rule u02.css applies. */
.enter-stack > .r06-stage,
.enter-stack > [data-slot="sheet-overlay"],
.enter-stack > [data-slot="sheet-content"] {
  animation: none;
}

/* ── 3. The `signature` block's capture-pad faces (PARITY B05 gap fix) ─────
   `src/components/signature.rs` renders `.signature-pad`, `.signature-hint`,
   `.signature-clear`, … but NO theme file ever defined them — the pad was an
   empty, zero-height div and "Sign above." / "Clear" were unstyled on every
   page that drew a signature. The old signature-pad.tsx's own face (canvas
   `aspect-[3/1] w-full touch-none rounded-md border bg-white`, hint `text-xs
   text-muted-foreground`, clear `text-xs font-medium text-muted-foreground
   hover:text-foreground`) is reproduced here so the reused block renders. */
.signature-title {
  margin: 0;
  font-size: 1.0625rem;
  line-height: 1.35;
  font-weight: 500;
  letter-spacing: -0.014em;
}

.signature-pad {
  aspect-ratio: 3 / 1;
  width: 100%;
  border-radius: 0.375rem;
  border: 1px solid var(--ta-border);
  background: #ffffff;
}

.signature-pad-foot {
  margin-top: 0.5rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.signature-hint {
  font-size: 0.75rem;
  color: var(--ta-muted);
}

.signature-clear {
  display: inline-flex;
  align-items: center;
  gap: 0.375rem;
  font-size: 0.75rem;
  font-weight: 500;
  color: var(--ta-muted);
}

.signature-clear:hover {
  color: var(--ta-text);
}

.signature-read img {
  max-width: 100%;
}

.signature-empty {
  font-size: 0.875rem;
  color: var(--ta-muted);
}
