/* The manager's planning page.
 *
 * On paper this page must never be mistaken for the official plan, so the
 * print rules below stamp it as a working copy on every page and strip the
 * layout back to something that plainly is not the whiteboard sheet. */

/* Aliased onto brand.css's shelter-wide tokens rather than redefined here
 * -- this page's own selectors are unchanged and keep reading these same
 * local names, but the values now come from one place. See brand.css for
 * where each colour comes from and its contrast ratio. */
:root {
  --ink: var(--lu-ink);
  --ink-soft: var(--lu-ink-soft);
  --rule: var(--lu-rule);
  --paper: var(--lu-paper);
  --page: var(--lu-page);
  --accent: var(--lu-accent);
  --accent-strong: var(--lu-accent-strong);
  --accent-strong-hover: var(--lu-accent-strong-hover);
  --font-display: var(--lu-font-display);
  --blocking: var(--lu-blocking);
  --blocking-wash: var(--lu-blocking-wash);
  --blocking-strong: var(--lu-blocking-strong);
  --warning: var(--lu-warning);
  --warning-wash: var(--lu-warning-wash);
  --warning-strong: var(--lu-warning-strong);
  --clear: var(--lu-ok);
  --clear-wash: var(--lu-ok-wash);
  --neutral-wash: var(--lu-neutral-wash);
  --unknown: var(--lu-unknown);
  --unknown-strong: var(--lu-unknown-strong);
  --unknown-wash: var(--lu-unknown-wash);
  --info-wash: var(--lu-info-wash);
}

* { box-sizing: border-box; }

body {
  margin: 0;
  padding: 0 1.5rem 4rem;
  background: var(--page);
  color: var(--ink);
  font: 16px/1.5 -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
}

h1, h2, h3 { margin: 0; font-weight: 650; letter-spacing: -0.01em; }
/* Only h1 (page titles: "Today's Plan", "Sign in to Lucky Dog Ops") gets
 * the display face. h2/h3 (section headings inside a page) stay on the
 * system stack -- see brand.css's --lu-font-display for why the split
 * exists at all. */
h1 { font-family: var(--font-display); font-size: 2rem; }
h2 { font-size: 1.25rem; }
h3 { font-size: 1rem; }
/* Ordinary links inherit the shared ink treatment from brand.css. */

/* The day's conditions (today's temperature/forecast) are ordinary,
 * everyday information on every real page load, so this is its own
 * quiet line. It sits flush against the topbar below it with no rule
 * of its own between them, reading as the masthead's own sub-line
 * rather than a separate strip. */
.conditions-strip {
  margin: 0;
  padding: 0.3rem 1.5rem;
  background: var(--page);
  color: var(--ink-soft);
  font-size: 0.78rem;
}
.board-shell .conditions-strip { padding-left: 1rem; padding-right: 1rem; }

.plan-changed-banner {
  margin: 0.5rem 0;
  padding: 0.5rem 0.75rem;
  border: 1px solid var(--warning);
  border-radius: 4px;
  background: var(--warning-wash);
  color: var(--ink);
  font-weight: 600;
}
.plan-changed-banner a { color: var(--warning); }

/* ── The board ────────────────────────────────────────────────────────
 *
 * Measured commitments, kept narrow enough to be true.
 *
 * Two claims used to live here that the page did not keep. The first was
 * that the 25-dog reference roster fits on a 1440x900 screen with nothing
 * scrolling: it missed by nineteen pixels, and once corrected it held by
 * nothing at all, and only with the source-provenance strips absent. A
 * promise with that much slack survives the harness and fails on a laptop
 * at 110% zoom, with one more banner, or with the browser's own font size
 * raised, so it is gone rather than propped up. The second was that no
 * text falls below 14px, while the count badges have always been 12px.
 *
 * What this file does commit to, and what the responsive tests check:
 *
 * - a dog's whole day is readable without scrolling sideways;
 * - a normal dog row stays between 28 and 30px tall;
 * - when there are more rows than fit, the rows are the only thing that
 *   scrolls — the people strip, the status line and the column headings
 *   stay put, at the same size;
 * - the smallest type on the page is 12px, on secondary count badges and
 *   eyebrow labels; cell and body text stays at 14px.
 *
 * Roughly 25 rows are visible at 1440x900 before the board starts to
 * scroll. That is a measurement of one configuration, not a guarantee.
 */

.board-shell {
  display: flex;
  flex-direction: column;
  height: 100vh;
  margin: 0 -1.5rem;
  background: var(--paper);
  border-bottom: 3px solid var(--ink);
  font-size: 14px;
}
.accepted-obligation-plan .board-shell { height: auto; min-height: 0; }
.care-periods { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 1rem; }
.care-board-item { border-top: 1px solid #cbd5d1; padding: .75rem 0; overflow-wrap: anywhere; }
.care-board-item h4 { margin: 0; }
@media (max-width: 1000px) { .care-periods { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 600px) { .care-periods { grid-template-columns: 1fr; } }
.flexible-responsibilities article { margin: .75rem 0; }
.flexible-responsibilities form { margin: .5rem 0; }

.topbar {
  display: flex;
  flex-wrap: nowrap;
  align-items: baseline;
  gap: 0.75rem;
  padding: 0.25rem 1rem;
  border-bottom: 1px solid var(--rule);
}
.brand-mark-slot {
  display: flex;
  align-items: center;
  min-width: 0;
  /* The supplied wordmark retains its large intrinsic dimensions.  Its
   * rendered width is height-driven below, but clipping the noninteractive
   * asset's intrinsic overflow prevents a narrow viewport from gaining a
   * phantom horizontal page scrollbar. */
  overflow: hidden;
}
/* Height-driven scaling only, so the supplied original's own aspect ratio
 * (from its width/height attributes) can never be stretched. */
.brand-mark { height: 26px; width: auto; max-width: 100%; display: block; }
.brand-text { margin: 0; font-size: 13px; font-weight: 600; color: var(--ink-soft); white-space: nowrap; }
.topbar h1 { font-size: 18px; min-width: 0; overflow-wrap: anywhere; }
.topbar .dateline { margin: 0; font-size: 14px; color: var(--ink-soft); white-space: nowrap; }
.topbar nav {
  display: flex;
  align-items: center;
  gap: 0.6rem;
  margin-left: auto;
  white-space: nowrap;
}
.topbar nav a { font-size: 14px; text-decoration: none; }
.topbar .button { padding: 0.15rem 0.5rem; font-size: 14px; }


/* One-sentence page-level context below a topbar (currently just
 * Playgroups' own note) -- same horizontal inset as the topbar and
 * capacity bands above it, so it doesn't read as flush against the
 * edge while everything around it is indented. */
.playgroup-note { margin: 0; padding: 0.25rem 1rem; border-bottom: 1px solid var(--rule); }

.nav-icon { width: 15px; height: 15px; flex: 0 0 auto; stroke: currentColor; stroke-width: 1.6; fill: none; stroke-linecap: round; stroke-linejoin: round; }
.nav-icon-chevron { width: 11px; height: 11px; margin-left: 0.1rem; }

/* Three groups, not one flat row: see the template comment above this
 * nav for what belongs in each and why. */
.workspace-nav {
  display: flex;
  align-items: center;
  gap: 0.6rem;
  padding: 0.5rem 1rem;
  border-bottom: 1px solid var(--rule);
  background: var(--paper);
  flex-wrap: wrap;
}
.workspace-nav-group {
  display: inline-flex;
  gap: 0.15rem;
  padding: 0.2rem;
  background: var(--page);
  border: 1px solid var(--rule);
  border-radius: 10px;
}
.workspace-nav-group a {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  min-height: 2.25rem;
  padding: 0.35rem 0.7rem;
  border-radius: 7px;
  color: var(--ink-soft);
  font-weight: 600;
  font-size: 0.88rem;
  text-decoration: none;
  white-space: nowrap;
}
.workspace-nav-group a[aria-current="page"] {
  background: var(--paper);
  color: var(--accent);
  box-shadow: 0 1px 3px rgba(40,26,14,0.14);
}

/* Same segmented-pill treatment as .workspace-nav-group, for a
 * page-local filter bar (Dogs' All/Needs onboarding/Needs safety
 * review tabs) rather than the cross-page workspace nav. */
.dog-filter-tabs {
  display: inline-flex;
  gap: 0.15rem;
  margin: 0.9rem 0 0;
  padding: 0.2rem;
  background: var(--page);
  border: 1px solid var(--rule);
  border-radius: 10px;
}
.dog-filter-tabs a {
  display: inline-flex;
  align-items: center;
  min-height: 2.25rem;
  padding: 0.35rem 0.7rem;
  border-radius: 7px;
  color: var(--ink-soft);
  font-weight: 600;
  font-size: 0.88rem;
  text-decoration: none;
  white-space: nowrap;
}
.dog-filter-tabs a[aria-current="page"] {
  background: var(--paper);
  color: var(--accent);
  box-shadow: 0 1px 3px rgba(40,26,14,0.14);
}

/* Dogs keeps ordinary populations and bounded review queues in nearby,
 * clearly named groups.  The two groups share the workspace's established
 * segmented-control pattern, so this is hierarchy rather than a second
 * navigation language. */
.dogs-roster-guidance {
  max-width: 46rem;
  margin: 0.85rem 1rem 0;
  color: var(--ink-soft);
}
.dogs-roster-guidance-compact,
.import-review-compact-guidance { display: none; }
.dogs-roster-controls-mobile { display: none; }
.dog-filter-groups {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem 1.5rem;
  padding: 0 1rem;
}
.dog-filter-group { min-width: 0; }
.dog-filter-group-label {
  margin: 0.9rem 0 -0.35rem;
  color: var(--ink-soft);
  font-size: 0.72rem;
  font-weight: 650;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}
.dog-filter-group .dog-filter-tabs { margin-top: 0.55rem; }
.dogs-roster-results { margin: 1.25rem 1rem 0; }
.dogs-roster-results > p { max-width: 48rem; margin: 0.25rem 0 0; }
.roster-secondary {
  display: block;
  margin-top: 0.1rem;
  color: var(--ink-soft);
  font-size: 0.8rem;
  font-weight: 400;
}

/* Import review is intentionally a work queue, not a seventh column in the
 * ordinary roster: a generic table could not communicate why a record is
 * here and what the manager should do next.  It remains a neutral shared
 * panel rather than borrowing warning treatment from safety work. */
.import-review-queue { margin: 1.25rem 1rem 0; }
.import-review-queue > .muted { max-width: 54rem; }
.import-review-list {
  margin: 0.85rem 0 0;
  padding: 0;
  list-style: none;
  border-top: 1px solid var(--rule);
}
.import-review-item {
  display: grid;
  grid-template-columns: minmax(11rem, 0.8fr) minmax(15rem, 1.2fr) auto;
  gap: 0.65rem 1rem;
  align-items: start;
  padding: 0.9rem 0;
  border-bottom: 1px solid var(--rule);
}
.import-review-problem { grid-column: 1 / -1; }
.import-review-label,
.identity-review-next span,
.identity-review-notes span,
.identity-review-records span,
.identity-review-label {
  display: block;
  margin-bottom: 0.1rem;
  color: var(--ink-soft);
  font-size: 0.73rem;
  font-weight: 650;
  letter-spacing: 0.05em;
  text-transform: uppercase;
}
.import-review-record h3 { margin: 0.05rem 0 0; }
.import-review-record h3 a { text-decoration-thickness: 1px; text-underline-offset: 0.14em; }
.import-review-record p, .import-review-next p { margin: 0.15rem 0 0; }
.import-review-item > .button {
  align-self: end;
  white-space: nowrap;
}

/* ASM maintenance has a real, useful fallback action, but it belongs after
 * the day's dog work.  A quiet disclosure makes that secondary role clear
 * without hiding it when an exceptional sync is genuinely needed. */
.asm-sync {
  margin: 1.25rem 1rem 0;
  padding: 0.4rem 0 0;
  border-top: 1px solid var(--rule);
}
.asm-sync p { max-width: 46rem; margin: 0.1rem 0 0.6rem; }

.pagination {
  display: flex;
  align-items: center;
  gap: 0.9rem;
  margin: 0.9rem 0;
  font-size: 0.9rem;
  color: var(--ink-soft);
}
.pagination a { font-weight: 600; }

.workspace-nav-records { position: relative; }
.workspace-nav-records summary {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  min-height: 2.25rem;
  padding: 0.35rem 0.7rem;
  border-radius: 8px;
  border: 1px solid var(--rule);
  background: var(--paper);
  color: var(--ink-soft);
  font-weight: 600;
  font-size: 0.88rem;
  cursor: pointer;
  list-style: none;
}
.workspace-nav-records summary::-webkit-details-marker { display: none; }
.workspace-nav-records[open] summary { color: var(--ink); }
.workspace-nav-records[open] .nav-icon-chevron { transform: rotate(90deg); }
.workspace-nav-records-menu {
  position: absolute;
  top: calc(100% + 0.4rem);
  left: 0;
  z-index: 3;
  display: flex;
  flex-direction: column;
  min-width: min(11rem, calc(100vw - 1.5rem));
  padding: 0.35rem;
  background: var(--paper);
  border: 1px solid var(--rule);
  border-radius: 9px;
  box-shadow: 0 12px 24px -10px rgba(40,26,14,0.28);
}
.workspace-nav-records-menu a {
  display: flex;
  align-items: center;
  gap: 0.55rem;
  padding: 0.5rem 0.6rem;
  border-radius: 6px;
  color: var(--ink);
  font-weight: 600;
  font-size: 0.88rem;
  text-decoration: none;
}
.workspace-nav-records-menu a:hover { background: var(--page); }
.workspace-nav-records-menu a[aria-current="page"] { background: var(--info-wash); color: var(--accent); }
.workspace-nav-records:not([open]) .workspace-nav-records-menu { display: none; }

.workspace-nav-views { margin-left: auto; display: inline-flex; gap: 0.35rem; }
.workspace-nav-views a {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  padding: 0.32rem 0.65rem;
  border-radius: 99px;
  border: 1px solid var(--rule);
  color: var(--ink-soft);
  text-decoration: none;
  font-weight: 600;
  font-size: 0.82rem;
  white-space: nowrap;
}

/* Who's signed in + Log out, folded into the end of this same row
 * instead of a second full-width row underneath it -- see
 * _manager_shell_nav.html. A collapsed-by-default popover (2026-08-31
 * review, round 5), the same pattern .workspace-nav-records already
 * uses just to its left: an always-expanded identity line plus its own
 * Log out row cost a full extra row of vertical space at the mobile
 * breakpoint on top of the workspace-nav pills wrapping onto their own
 * -- exactly the large account band this whole pass exists to remove. */
.workspace-nav-account { position: relative; margin-left: 0.5rem; }
.workspace-nav-account summary {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.15rem;
  min-width: 2.75rem;
  min-height: 2.75rem;
  padding: 0.35rem 0.6rem;
  border-radius: 8px;
  border: 1px solid var(--rule);
  background: var(--paper);
  color: var(--ink-soft);
  cursor: pointer;
  list-style: none;
}
.workspace-nav-account summary::-webkit-details-marker { display: none; }
.workspace-nav-account[open] summary { color: var(--ink); }
.workspace-nav-account[open] .nav-icon-chevron { transform: rotate(90deg); }
.workspace-nav-account-menu {
  position: absolute;
  top: calc(100% + 0.4rem);
  right: 0;
  z-index: 3;
  min-width: min(14rem, calc(100vw - 1.5rem));
  max-width: min(20rem, calc(100vw - 1.5rem));
  padding: 0.7rem 0.75rem;
  background: var(--paper);
  border: 1px solid var(--rule);
  border-radius: 9px;
  box-shadow: 0 12px 24px -10px rgba(40,26,14,0.28);
}
.workspace-nav-account:not([open]) .workspace-nav-account-menu { display: none; }
.workspace-nav-account-identity {
  margin: 0 0 0.6rem;
  color: var(--ink-soft);
  font-size: 0.85rem;
}
.workspace-nav-account-menu form { margin: 0; }
.workspace-nav-account-menu button {
  min-height: 2.75rem;
  width: 100%;
  padding: 0.28rem 0.75rem;
  border: 1px solid var(--rule);
  border-radius: var(--lu-radius-sm, 4px);
  background: var(--page);
  color: var(--ink);
  font: inherit;
  font-weight: 600;
  cursor: pointer;
}

.surface-overview .board-shell,
.surface-setup .board-shell,
.surface-attention .board-shell,
.surface-team .board-shell { height: auto; min-height: 0; }
/* Preview keeps its content inside the shell, so the shell rule would
 * draw across the page under the last panel instead of under the nav. */
.surface-preview .board-shell { height: auto; min-height: 0; border-bottom: 0; }

/* Setup, Team, and the long record pages (Dog/Staff/Volunteer/Playgroup
 * detail -- see .surface-record) are read top to bottom, not scanned as
 * a wide grid the way the board or a roster table is. Left to fill
 * whatever the monitor happens to be, their panels ran to an
 * uncontrolled, unreadably long line length on a wide desktop screen.
 * The same deliberate reading column Overview already established
 * (.overview-main, 1280px)
 * applies here rather than inventing a second width -- wide enough for
 * these panels' own tables and multi-column fact grids, narrow enough
 * to stop prose stretching edge to edge. Nothing about the panel's own
 * box (padding, border, shadow) changes, so this is not a new card
 * template -- Plan's board and every roster keep their own full width. */
.surface-setup .panel,
.surface-setup .recent-history-note,
.surface-team .panel,
.surface-record .panel {
  /* width: 100% before the cap, not left auto: Setup's and every record
   * page's panels are flex children of .board-shell, where an auto
   * cross-axis width plus auto margins shrink-wraps to content instead
   * of stretching (flexbox's own auto-margin rule, independent of
   * max-width) -- every panel would size to its own content and the
   * column would stop reading as one consistent width. An explicit
   * width the max-width can then clamp keeps every panel the same
   * width, on Team's plain (non-flex) panels too. */
  width: 100%;
  max-width: 1280px;
  margin-left: auto;
  margin-right: auto;
}

/* Shared legacy execution summary used outside Overview. */
.execution-strip-list {
  display: flex;
  flex-wrap: wrap;
  gap: 0.4rem 1.5rem;
  margin: 0.6rem 0 0;
  color: var(--ink-soft);
}
.execution-strip-list b { color: var(--ink); }

.attention-queue {
  display: grid;
  gap: 0.75rem;
  padding: 1rem;
  background: var(--page);
}
.attention-group {
  padding: 1rem;
  border: 1px solid var(--rule);
  border-left: 5px solid var(--warning);
  border-radius: 0 6px 6px 0;
  background: var(--paper);
  box-shadow: 0 1px 2px rgba(0, 0, 0, 0.04);
}
/* Sits inside .attention-queue's own grid, so it needs no top margin of
 * its own -- the grid gap already separates it from the first group. */
.attention-lead { margin: 0; color: var(--ink-soft); }
/* Names the scope a manager is looking at (action required / worth
 * inspecting / record review) -- the one place on the page that states
 * the distinction the rest of the layout only implies. Plain text, no
 * color-as-verdict: only the action queue itself earns that. */
.attention-scope-heading, .attention-scope-subheading {
  margin: 0;
  font-size: 1.05rem;
  font-weight: 700;
}
.attention-worth-inspecting .band-lead { color: var(--ink-soft); }
.attention-group.attention-blocking { border-left-color: var(--blocking); }
.attention-group li {
  display: grid;
  grid-template-columns: 12rem 1fr 16rem;
  gap: 1rem;
  padding: 0.4rem 0.35rem;
  border-radius: 4px;
  transition: background-color 0.12s ease;
}
.attention-group li:hover { background: var(--page); }
.attention-group small { color: var(--ink-soft); }
.attention-more { grid-column: 1 / -1; margin-top: 0.2rem; font-size: 0.85rem; }
.attention-more ul { margin: 0.3rem 0 0; padding-left: 1.1rem; font-size: 0.9rem; }

/* Setup's staffing panel and the volunteer availability rows. */
.staffing-list { margin-top: 0.75rem; }
.staffing-list li { display: flex; flex-wrap: wrap; gap: 0.15rem 0.75rem; align-items: baseline; }
.staffing-list .hours { color: var(--accent); font-weight: 600; }
.staffing-list .load { color: var(--ink-soft); }
.surface-setup .manager-presence { margin: 0.75rem 0 0; }
.setup-fix-link { margin: 0.75rem 0 0; }

/* A blocked state and the one action that clears it: the sentence states
 * the condition, the button beside it is the way out. */
.repair-callout {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.6rem 1rem;
  margin-top: 0.75rem;
  padding: 0.75rem 0.9rem;
  border: 1px solid var(--rule);
  border-left: 4px solid var(--warning);
  border-radius: var(--lu-radius-md);
  background: var(--warning-wash);
}
.repair-callout p { margin: 0; flex: 1 1 14rem; }

/* One row per volunteer: name, then every effective window. */
.volunteer-availability-list > li { padding: 0.55rem 0; }
.volunteer-availability-line { display: flex; flex-wrap: wrap; align-items: baseline; gap: 0.15rem 0.75rem; margin: 0; }
.volunteer-availability-line b { min-width: 11rem; }
.volunteer-windows { display: inline-flex; flex-wrap: wrap; gap: 0.25rem 0.5rem; }
.volunteer-window {
  padding: 0.05rem 0.55rem;
  border: 1px solid var(--rule);
  border-radius: 999px;
  background: var(--neutral-wash);
  font-weight: 600;
  white-space: nowrap;
}
.volunteer-availability .chip { margin-top: 0.25rem; }
@media (min-width: 641px) {
  /* The disclosure shares the person's line while closed and takes the
   * full row once it is open. */
  .volunteer-availability { display: flex; flex-wrap: wrap; align-items: center; gap: 0 1rem; }
  .volunteer-availability-line { flex: 1 1 24rem; }
  .volunteer-availability > .disclosure-edit { flex: 0 0 auto; margin-top: 0; }
  .volunteer-availability > .disclosure-edit[open] { flex-basis: 100%; }
}
.signup-records { margin-top: 0; }
.signup-record { padding: 0.5rem 0; }
.signup-record-line { display: flex; flex-wrap: wrap; align-items: baseline; gap: 0.15rem 0.6rem; margin: 0 0 0.35rem; }
.signup-record-actions { display: flex; flex-wrap: wrap; align-items: center; gap: 0.4rem 0.9rem; }
.signup-record-actions .inline-form { margin: 0; }

/* Setup's own exception-first summary (2026-08-30 UX tranche, corrected
 * same day): the panel itself stays the same neutral .panel every other
 * Setup section uses -- R28's own lesson applies here too, an
 * accent-bordered panel reads as an alert, and most of what this lists
 * (a day note, a manual temperature, a capacity override) is an
 * ordinary, deliberate choice, not one. Only rendered at all when there
 * is something to say (setup.html), so an ordinary day never pays for
 * an empty box either way. */
.setup-exceptions h2 { display: flex; align-items: center; gap: 0.6rem; }
.setup-exceptions-list { margin: 0.5rem 0 0; }
.setup-exception-item { border-top: 1px solid var(--rule); }
.setup-exception-item:first-child { border-top: none; }
.setup-exception-item a {
  display: flex;
  flex-wrap: wrap;
  gap: 0.6rem;
  align-items: baseline;
  padding: 0.45rem 0;
  color: var(--ink);
  text-decoration: none;
}
.setup-exception-item a:hover { text-decoration: underline; }
.setup-exception-item b { flex: 0 0 auto; color: var(--ink-soft); }
.setup-exception-item span { color: var(--ink-soft); }
/* Per-item, not per-panel: only an entry plan.build_setup_exceptions
 * actually marks "warning" (nobody working, an unresolved volunteer
 * signup, a closed place) gets the colour real attention deserves --
 * the header's own count is every category listed, not only those, so
 * it keeps the same neutral .count styling as any other panel. */
.setup-exception-warning b { color: var(--warning); }

/* R28's original Setup-only fix (a left-accent border so repeated
 * .panel cards don't read as one continuous white stack) briefly became
 * a left-accent default on the shared .panel rule itself, then was
 * corrected the same day (2026-08-30): an accent-bordered panel reads
 * as an alert, and most panels are not one. Distinctness now comes from
 * .panel's own neutral card chrome -- paper on page, a rule border, and
 * real spacing -- identically on every surface, so no surface-scoped
 * override belongs here at all. See "Panels" below. */

.capacity {
  display: flex;
  gap: 1.25rem;
  padding: 0.25rem 1rem;
  border-bottom: 1px solid var(--rule);
}
.capacity-group { flex: 1 1 50%; min-width: 0; }
.capacity-group h2 { float: left; margin-right: 0.5rem; font-size: 14px; white-space: nowrap; }
.capacity-group h2 .count { font-size: 14px; padding: 0 0.35rem; }
.capacity-group ul {
  display: flex;
  flex-wrap: wrap;
  gap: 0 1rem;
  margin: 0;
  padding: 0;
  list-style: none;
  max-height: 40px;
  overflow-y: auto;
}
.capacity-group li { font-size: 14px; line-height: 20px; white-space: nowrap; }
.capacity-group .hours { color: var(--accent); }
.capacity-group .load { color: var(--ink-soft); }
.capacity-volunteers li b { font-weight: 500; }

.status { padding: 0.2rem 1rem; border-bottom: 1px solid var(--rule); }
/* Attention's own copy of this band sits below the board-shell, in
 * ordinary flowed content, not pinned inside it -- give it back the card
 * shape every other below-the-board section already has, rather than
 * the full-bleed pinned-header strip this class otherwise assumes. */
.attention-verdict {
  margin: 1.25rem 0 0;
  border: 1px solid var(--rule);
  border-radius: 6px;
  border-bottom-width: 1px;
}
.status-line { display: flex; gap: 0.6rem; align-items: baseline; margin: 0; font-size: 14px; }
.status-line b { white-space: nowrap; }
.status-line span { color: var(--ink-soft); }
.status-line .stamp { margin-left: auto; white-space: nowrap; }
.status-conflict { background: var(--blocking-wash); }
.status-conflict b { color: var(--blocking); }
.status-gap { background: var(--warning-wash); }
.status-gap b { color: var(--warning); }
.status-clear { background: var(--clear-wash); }
.status-clear b { color: var(--clear); }
/* Not planned is deliberately neutral, never green: nothing has been
 * checked, so the strip must not read as a day that passed. */
.status-not-planned { background: var(--page); }
.status-not-planned b { color: var(--ink); }

/* #163: execution status -- read-only, so deliberately styled as a
 * near-neutral cousin of .status rather than reusing any conflict/gap
 * color, which would misread as another safety verdict. */
.exec-summary-band { background: var(--neutral-wash); padding: 0.35rem 1rem; }
.exec-summary-note { margin: 0.15rem 0 0; font-size: 0.78rem; }
.diagnostic-details { font-size: 0.82rem; min-width: 0; }
.diagnostic-details[open] { flex-basis: 100%; }
.stack-row > .profile-edit-error, .chore-row > .profile-edit-error,
.inline-form > .profile-edit-error { flex-basis: 100%; }
.rotation-status {
  display: flex;
  gap: 0.5rem 1.5rem;
  padding: 0.4rem 1rem;
  background: var(--warning-wash);
  border-bottom: 1px solid var(--warning);
  flex-wrap: wrap;
}
.rotation-status p { display: flex; gap: 0.45rem; margin: 0; font-size: 0.82rem; }
.rotation-status b { color: var(--warning); }
.rotation-status span { color: var(--ink-soft); }

.exec-mark {
  display: inline-block;
  margin-left: 0.35rem;
  padding: 0.03rem 0.35rem;
  border-radius: 3px;
  font-size: 0.72rem;
  font-weight: 600;
  white-space: nowrap;
}
.exec-done { background: var(--clear-wash); color: var(--clear); }
.exec-could_not_complete { background: var(--blocking-wash); color: var(--blocking); }
.exec-due_now_unconfirmed { background: var(--info-wash); color: var(--accent); }
.exec-elapsed_unconfirmed { background: var(--warning-wash); color: var(--warning); }
.exec-partially_confirmed { background: var(--unknown-wash); color: var(--unknown); }

.exec-detail {
  display: flex;
  flex-direction: column;
  gap: 0.15rem;
  margin-top: 0.3rem;
  font-size: 0.82rem;
}
.exec-summary { font-weight: 600; }
.exec-role { color: var(--ink-soft); }

.exec-workload-heading { margin-top: 1.2rem; font-size: 0.95rem; }

.board-shell .messages { margin: 0; padding: 0.2rem 1rem 0; }
.board-shell .message { margin-bottom: 0.2rem; font-size: 14px; }

/* auto, not hidden: the board's columns are sized to fit without a
 * horizontal scrollbar today, but the sticky dog column below only means
 * anything if the browser is allowed to produce one when they don't. */
.board-scroll { flex: 1 1 auto; min-height: 0; overflow-y: auto; overflow-x: auto; }

/* border-collapse: collapse breaks position: sticky on <th> in every
 * major engine -- the collapsed border model removes the table headers
 * from their own stacking/scrolling context. border-collapse: separate
 * with zero spacing keeps the sticky header working and looks identical
 * except for a doubled 1px rule at cell boundaries, which the border
 * colors below are chosen not to make visible. */
.board { width: 100%; table-layout: fixed; border-collapse: separate; border-spacing: 0; }
.col-dog { width: 10.5%; }
.col-status { width: 24%; }
.col-period { width: 13.1%; }

.board thead th {
  position: sticky;
  top: 0;
  z-index: 2;
  padding: 0.2rem 0.35rem;
  background: var(--page);
  border-bottom: 2px solid var(--ink);
  text-align: left;
  font-size: 14px;
  font-weight: 650;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.board thead .th-time { font-weight: 400; color: var(--ink-soft); }

/* The one column that is "now" -- a manager scanning a live board's
   biggest first question ("what's happening right now?") otherwise
   requires reading every column's time range against a clock. Staff
   Today and Kitchen Display already flag "Now"/"current" for their own
   shapes; the board had no equivalent for its period columns. Shown
   only when the viewed date is today and the clock is inside the
   operating day -- see plan.build's current_period_key. */
.board thead .th-now { background: var(--info-wash); }
.now-flag {
  display: inline-block;
  /* --accent-strong, not --accent: this is a solid fill with white text on
   * top, and brand.css's own split exists exactly because --accent (a
   * text/badge colour) is too light against white in dark mode to also
   * serve as a fill -- see brand.css's accent-strong comment. */
  background: var(--accent-strong);
  color: var(--lu-accent-ink, #fff);
  font-size: 10px;
  font-weight: 700;
  letter-spacing: 0.03em;
  text-transform: uppercase;
  border-radius: 3px;
  padding: 0.05rem 0.3rem;
  margin-right: 0.2rem;
  vertical-align: middle;
}
.cell-now { background: var(--info-wash); }

.board tbody th, .board tbody td {
  /* 28px, the bottom of the 28-30px band this file declares. At 29px the
     25-dog reference roster overflowed its own scroller by 19px on a
     1440x900 screen, so the contract above was one pixel per row short of
     true. */
  height: 28px;
  padding: 1px 0.35rem;
  border-bottom: 1px solid var(--rule);
  border-right: 1px solid var(--rule);
  font-size: 14px;
  line-height: 1.25;
  vertical-align: middle;
  overflow: hidden;
}
.board tbody th:last-child, .board tbody td:last-child { border-right: 0; }

.dog-row .dog-name {
  position: sticky;
  left: 0;
  z-index: 1;
  background: var(--paper);
  text-align: left;
  font-weight: 650;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
/* The condensed gap line never shrinks: it is the only place in the normal
 * board that names what is still wrong for this dog, so it is the last
 * thing that may be clipped. A restriction chip gives up its width first —
 * its full wording is in the opened cell and in the day's inputs below. */
.dog-status { display: flex; align-items: center; gap: 0.25rem; white-space: nowrap; }
.dog-status .chip { flex: 0 0 auto; }
.dog-status .chip + .chip {
  flex: 0 1 auto;
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
}
.dog-status .gap-line { flex: 0 0 auto; }

.state-conflict .dog-name { box-shadow: inset 3px 0 0 var(--blocking); }
.state-gap .dog-name { box-shadow: inset 3px 0 0 var(--warning); }
.state-unknown .dog-name { box-shadow: inset 3px 0 0 var(--unknown-strong); }
.state-restricted .dog-name { box-shadow: inset 3px 0 0 var(--ink-soft); }

.chip {
  display: inline-block;
  margin-right: 0.25rem;
  padding: 0.05rem 0.4rem;
  border-radius: 4px;
  background: var(--neutral-wash);
  font-size: 14px;
  color: var(--ink-soft);
}
/* Previously duplicated ahead of the base .chip rule above with the same
 * specificity, so source order made the base rule's grey win regardless
 * of which of these was also applied -- every "Linked"/"Active"/"Record
 * complete" chip rendered flat grey no matter its real status. Moved
 * here, after .chip, alongside every other working chip variant. */
.chip-blocked { background: var(--blocking-wash); color: var(--blocking); font-weight: 600; }
.chip-incomplete { background: var(--warning-wash); color: var(--warning); font-weight: 600; }
.chip-covered { background: var(--clear-wash); color: var(--clear); }
.chip-not-assessed { background: var(--neutral-wash); color: var(--ink-soft); }
.chip-proposal-pending { background: var(--info-wash); color: var(--accent); font-weight: 600; }
.chip-conflict { background: var(--blocking-wash); color: var(--blocking); font-weight: 600; }
.chip-unknown { background: var(--unknown-wash); color: var(--unknown); font-weight: 600; }
.chip-restricted { background: var(--neutral-wash); color: var(--ink); }
.chip-gap { background: var(--warning-wash); color: var(--warning); }
.chip-evidenced_capacity_shortfall { background: var(--blocking-wash); color: var(--blocking); }
.chip-allocation_omission { background: var(--warning-wash); color: var(--warning); }
.chip-insufficient_data { background: var(--unknown-wash); color: var(--unknown); }
.chip-blocked_on_manager_action { background: var(--info-wash); color: var(--accent); }

.gap-line { color: var(--warning); font-weight: 600; text-decoration: none; }
.gap-line:hover { text-decoration: underline; }

.cell-line {
  display: block;
  overflow: hidden;
  white-space: nowrap;
  text-overflow: ellipsis;
  color: var(--ink);
  text-decoration: none;
}
.cell-line:hover { color: var(--accent); text-decoration: underline; }
.cell-line-empty { color: var(--ink-soft); }
.cell-line-open { color: var(--accent); font-weight: 600; }
.cell-line .more { color: var(--ink-soft); font-weight: 600; }
.cell-selected { background: var(--neutral-wash); box-shadow: inset 0 0 0 2px var(--accent); }
.cell[data-drag-source="true"] { cursor: grab; }
.cell-drag-active { opacity: 0.5; box-shadow: inset 0 0 0 2px var(--ink-soft); }
.cell-drop-valid { background: var(--clear-wash); box-shadow: inset 0 0 0 2px var(--clear); }
.cell-blocked { background: var(--blocking-wash); }
.cell-warned { background: var(--warning-wash); }
/* The wash background alone does not distinguish blocked from warned for
 * a manager who cannot rely on colour -- each cell also carries its own
 * text label, not only the row-level "Conflict" chip that names the dog
 * but not which of its cells is the problem. */
.cell-flag {
  display: inline-block;
  margin-right: 0.25rem;
  padding: 0 0.3rem;
  border-radius: 2px;
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.02em;
  text-transform: uppercase;
  color: #fff;
}
.cell-flag-blocked { background: var(--blocking-strong); }
.cell-flag-warning { background: var(--warning-strong); }

.detail-row td { padding: 0; background: var(--neutral-wash); }
.detail { padding: 0.6rem 1rem; border-left: 4px solid var(--accent); }
.detail h3 { font-size: 15px; margin-bottom: 0.4rem; }
.stack-row {
  display: flex;
  flex-wrap: wrap;
  gap: 0.3rem;
  align-items: center;
  padding: 0.25rem 0.35rem;
  margin-bottom: 0.25rem;
  background: var(--paper);
  border: 1px solid var(--rule);
  border-radius: 4px;
  font-size: 14px;
}
.stack-commitment { background: var(--warning-wash); }
.stack-add { background: var(--page); border-style: dashed; }

/* A compact visible caption above a control in a dense inline row --
 * .stack-row, .chore-row, .add-chore -- so a sighted manager reads what a
 * field is rather than inferring it from its position or its currently
 * selected option text. The control keeps its own aria-label as the
 * accessible name (unchanged); this caption is decorative, so it never
 * doubles a screen reader's announcement. */
.field { display: inline-flex; flex-direction: column; align-items: flex-start; gap: 0.05rem; }
.field-label {
  font-size: 0.65rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  line-height: 1;
  color: var(--ink-soft);
}

.equipment-ack { display: flex; flex-wrap: wrap; gap: 0.5rem; align-items: center; }
.check-label-inline { display: inline-flex; align-items: center; gap: 0.25rem; font-size: 13px; white-space: nowrap; }

.gap { margin-bottom: 0.5rem; padding-left: 0.6rem; border-left: 3px solid var(--rule); }
.gap-evidenced_capacity_shortfall { border-color: var(--blocking); }
.gap-allocation_omission { border-color: var(--warning); }
.gap-insufficient_data { border-color: var(--unknown-strong); }
.gap-blocked_on_manager_action { border-color: var(--accent); }
.gap-head { margin: 0; font-size: 14px; }
.gap-note { margin: 0.15rem 0 0; font-size: 14px; color: var(--ink-soft); }
.gap-unknown { color: var(--unknown); }
.gap-proposal { color: var(--accent); font-weight: 600; }
.gap-evidence { margin: 0.15rem 0 0 1rem; padding: 0; font-size: 14px; color: var(--ink-soft); }

.repair-note {
  margin: 0.75rem 0 0;
  padding: 0.4rem 0.7rem;
  background: var(--neutral-wash);
  border-left: 3px solid var(--ink-soft);
  font-size: 0.85rem;
  color: var(--ink-soft);
}
.summary-note { margin-left: 0.5rem; font-size: 0.85rem; color: var(--ink-soft); }

/* ── Masthead ─────────────────────────────────────────────────────── */

.masthead {
  display: flex;
  flex-wrap: wrap;
  gap: 1rem;
  align-items: flex-end;
  justify-content: space-between;
  padding: 1.75rem 0 1rem;
  border-bottom: 2px solid var(--ink);
}
.eyebrow {
  margin: 0 0 0.15rem;
  font-size: 0.75rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--ink-soft);
}
.dateline { margin: 0.25rem 0 0; color: var(--ink-soft); }
.masthead-nav { display: flex; gap: 0.6rem; align-items: center; flex-wrap: wrap; }
.day-step { font-size: 0.9rem; text-decoration: none; color: var(--ink-soft); }
.day-step:hover { color: var(--accent); }

.working-notice {
  margin: 0.9rem 0 0;
  padding: 0.6rem 0.85rem;
  background: var(--neutral-wash);
  border-left: 3px solid var(--ink-soft);
  font-size: 0.9rem;
  color: var(--ink-soft);
}

/* ── Buttons and small controls ───────────────────────────────────── */

.button {
  display: inline-block;
  padding: 0.5rem 0.9rem;
  border: 1px solid var(--ink);
  border-radius: 5px;
  background: var(--paper);
  color: var(--ink);
  font: inherit;
  font-size: 0.9rem;
  text-decoration: none;
  cursor: pointer;
  transition: background-color 0.12s ease, border-color 0.12s ease, transform 0.05s ease;
}
.button:hover { background: var(--neutral-wash); }
.button:active { transform: translateY(1px); }
.button-primary { background: var(--accent-strong); border-color: var(--accent-strong); color: #fff; }
.button-primary:hover { background: var(--accent-strong-hover); border-color: var(--accent-strong-hover); }
.button-undo { border-color: var(--warning); color: var(--warning); font-weight: 600; }
.button-quiet { border-color: var(--rule); color: var(--ink-soft); }
.button-small { padding: 0.25rem 0.55rem; font-size: 0.8rem; }
.button-repair {
  display: inline-flex;
  align-items: center;
  gap: 0.6rem;
  min-height: var(--lu-touch);
  padding: 0.5rem 1rem;
  border-color: var(--accent);
  background: var(--paper);
  color: var(--accent);
  font-weight: 650;
}
.button-repair::after {
  content: "";
  width: 0.5rem;
  height: 0.5rem;
  border-right: 2px solid currentColor;
  border-top: 2px solid currentColor;
  transform: rotate(45deg);
}
.button-repair:hover { background: var(--accent-wash, var(--lu-accent-wash)); color: var(--lu-link-hover); }
/* .link-button (an inline action that changes something) is defined once,
 * in brand.css's interactive-text system. */

input[type="time"], input[type="text"], input[type="number"],
input[type="search"], input[type="date"], input[type="url"],
input[type="email"], input[type="password"], select, textarea {
  padding: 0.35rem 0.5rem;
  min-width: 0;
  min-height: 2rem;
  border: 1px solid var(--rule);
  border-radius: var(--lu-radius-sm);
  background: var(--paper);
  font: inherit;
  font-size: 0.85rem;
  max-width: 100%;
}

.messages { list-style: none; margin: 1rem 0 0; padding: 0; }
.message {
  padding: 0.55rem 0.85rem;
  border-radius: 4px;
  margin-bottom: 0.4rem;
  font-size: 0.9rem;
  /* Command feedback (including the bounded ASM fallback) can contain a
   * short, useful multi-line summary. Preserve those line boundaries
   * instead of visually running its facts together. */
  white-space: pre-line;
}
textarea { resize: vertical; line-height: 1.5; }
[aria-invalid="true"] { border-color: var(--blocking); }
.message-success { background: var(--clear-wash); border-left: 3px solid var(--clear); }
.message-error { background: var(--blocking-wash); border-left: 3px solid var(--blocking); }
/* Previously undefined: a plain messages.warning() rendered with no
 * background/border at all, indistinguishable from ordinary body text
 * (2026-09-01 review round 3, item 3) -- reuses the same warning wash
 * .band-warning already established for Attention's own findings. */
.message-warning { background: var(--warning-wash); border-left: 3px solid var(--warning); color: var(--warning); }
/* The Attention recovery link/button sits inside its own warning block
 * (staff_detail.html #attention-recovery), separate from the ordinary
 * .messages list -- see ATTENTION_RECOVERY_SESSION_KEY. */
.attention-recovery p { margin: 0 0 0.5rem; }
.attention-recovery .button { display: inline-block; }

/* ── Bands ────────────────────────────────────────────────────────── */

.band {
  margin: 1.25rem 0 0;
  padding: 1rem 1.15rem;
  border-radius: 6px;
  border-left: 5px solid;
}
.band-lead { margin: 0.35rem 0 0; font-size: 0.92rem; }
.band-lead-loud { font-weight: 650; }
.band-list { margin: 0.6rem 0 0; padding-left: 1.1rem; }
.band-list li { margin-bottom: 0.25rem; }

.band-blocking { background: var(--blocking-wash); border-color: var(--blocking); color: var(--blocking); }
.band-blocking h2 { color: var(--blocking); }
.band-clear { background: var(--clear-wash); border-color: var(--clear); color: var(--clear); }
.band-clear h2 { color: var(--clear); }
.band-warning { background: var(--warning-wash); border-color: var(--warning); color: var(--warning); }
.band-warning h2 { color: var(--warning); }

.warning-columns {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: 0.75rem 1.5rem;
  margin-top: 0.75rem;
}
.warning-group ul { margin: 0.35rem 0 0; padding-left: 1.1rem; font-size: 0.9rem; }
.warning-group li { margin-bottom: 0.2rem; }
.warning-rest { margin-top: 0.3rem; font-size: 0.85rem; }
.warning-rest ul { margin: 0.3rem 0 0; padding-left: 1.1rem; font-size: 0.9rem; }
.count {
  display: inline-block;
  margin-left: 0.35rem;
  padding: 0 0.4rem;
  border-radius: 10px;
  background: rgba(0, 0, 0, 0.08);
  font-size: 0.75rem;
  font-weight: 600;
}

/* Preview's Accept/Discard/Regenerate row -- previously bare block-level
 * elements with no spacing rule of their own, reading as an afterthought
 * under whatever content happened to precede it. The same rule/gap
 * language every other bottom action area on the workspace already
 * uses, so Accept reads as the clear primary action it is rather than
 * one link among three with no visual hierarchy. */
.preview-actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.75rem;
  margin: 1.5rem 0 0;
  padding-top: 1rem;
  border-top: 1px solid var(--rule);
}
.preview-actions .inline-form { margin: 0; }
.button-note {
  flex-basis: 100%;
  margin: 0.3rem 0 0;
  font-size: 12px;
  color: var(--ink-soft);
}

/* ── Panels ───────────────────────────────────────────────────────────
 *
 * The one shared card component across the whole manager workspace
 * (2026-08-30 visual-system pass and same-day correction): Setup,
 * Attention and Team's sections, Records, Preview, and every card on the
 * redesigned Overview, are all a ``.panel`` -- same paper background,
 * rule, radius and shadow -- so moving between surfaces reads as one
 * product rather than several differently-decorated ones.
 *
 * An ordinary panel is neutral. The 2026-08-30 pass gave every panel a
 * brand-accent left border by default; in practice that made an
 * unremarkable container (a table of volunteer handoffs, a note field)
 * read as if it were flagging something, the same visual weight as an
 * actual alert. Colour is reserved for panels that state a real verdict
 * -- Overview's own safety statement and next-decision cards set their
 * own border-left explicitly, in the state's own colour, rather than
 * inheriting one here. Print strips this back further, to a plain
 * flowed section -- see @media print below. */
.panel {
  margin: 1.5rem 0 0;
  padding: 1.15rem 1.25rem;
  background: var(--paper);
  border: 1px solid var(--rule);
  border-radius: 8px;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.05);
}
/* Summaries inside a panel take their geometry from brand.css's
 * disclosure system (.disclosure-edit / -info / -section). */

/* Dog detail's own photo, shown when photo_url is set (now often ASM-
 * supplied) so staff can visually confirm they are editing the right
 * dog. Bounded rather than full-width -- this is an identity check, not
 * a gallery -- and scales down under its own max on narrow screens. */
.dog-photo {
  display: block;
  max-width: 220px;
  max-height: 220px;
  width: auto;
  height: auto;
  margin: 0.75rem 0;
  border: 1px solid var(--rule);
  border-radius: 8px;
}

/* ui.py's {% collapsible %} tag -- the same chevron/cursor styling as a
 * bare <details> inside .panel already gets; this just names the wrapper
 * for anywhere a collapsible needs to sit outside a .panel. */
.ui-collapsible-body { margin-top: 0.5rem; }

.input-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
  gap: 1.25rem;
  margin-top: 1rem;
}
.input-card { min-width: 0; }
.input-card h3 { padding-bottom: 0.35rem; border-bottom: 1px solid var(--rule); }
.note { margin: 0.5rem 0 0; font-size: 0.82rem; color: var(--ink-soft); }
.note-warn { color: var(--warning); }
.muted { color: var(--ink-soft); font-size: 0.85rem; }

/* The dogs-needing-information queue: one unanswered question per row,
 * with the dogs waiting on it. Replaces the same five sentences repeated
 * once per dog, which said how much was missing and nothing about what to
 * do first. */
.review-dimensions { list-style: none; margin: 0.6rem 0 0; padding: 0; font-size: 0.9rem; }
.review-dimensions > li {
  display: flex;
  flex-wrap: wrap;
  gap: 0 0.5rem;
  align-items: baseline;
  padding: 0.35rem 0;
  border-bottom: 1px dotted var(--rule);
}
.review-dimensions > li:last-child { border-bottom: 0; }
.review-dimensions .count {
  padding: 0 0.35rem;
  background: var(--warning-wash);
  color: var(--warning);
  border-radius: 3px;
  font-variant-numeric: tabular-nums;
}
.review-waiting { flex: 1 1 16rem; min-width: 0; color: var(--ink-soft); }
.review-by-dog { margin-top: 0.6rem; font-size: 0.85rem; }

.warning-names { margin: 0.35rem 0 0; font-size: 0.9rem; }
/* One line saying what this group is scoped to, where an adjacent count
 * elsewhere on the page could otherwise read as the same backlog. */
.warning-scope { margin: 0.25rem 0 0; font-size: 0.85rem; }

/* Workload: the totals a manager compares, then the people whose recorded
 * time went unplanned and why, then the full per-person table. */
.workload-totals {
  display: flex;
  flex-wrap: wrap;
  gap: 0.25rem 1.5rem;
  margin: 0.6rem 0 0.2rem;
}
.workload-totals > div { display: flex; gap: 0.4rem; align-items: baseline; }
.workload-totals dt { color: var(--ink-soft); font-size: 0.85rem; }
.workload-totals dd { margin: 0; font-weight: 600; font-variant-numeric: tabular-nums; }
.workload-note { margin: 0 0 0.5rem; font-size: 0.8rem; }

.unused-capacity {
  margin: 0.5rem 0;
  padding: 0.5rem 0.75rem;
  border-left: 3px solid var(--warning);
  background: var(--warning-wash);
}
.unused-capacity h3 { font-size: 0.9rem; color: var(--warning); }
.unused-capacity ul { margin: 0.3rem 0 0; padding-left: 1.1rem; font-size: 0.85rem; }
.unused-capacity li { margin-bottom: 0.15rem; }
.unused-amount { font-variant-numeric: tabular-nums; }

.plain-list { list-style: none; margin: 0.6rem 0 0; padding: 0; font-size: 0.9rem; }
.plain-list li { padding: 0.25rem 0; border-bottom: 1px dotted var(--rule); }
.plain-list li:last-child { border-bottom: 0; }

/* The handling tiers' own names don't say who they actually include (a
 * manager reading "Staff only" vs "Approved handlers only" has no way to know
 * staff are implicitly eligible under three of the four tiers) -- this
 * spells it out once, next to the control that sets it. */
.handling-tier-meanings { margin: 0.75rem 0 0; font-size: 0.85rem; }
.handling-tier-meanings dt { font-weight: 650; }
.handling-tier-meanings dd { margin: 0.1rem 0 0.6rem; color: var(--ink-soft); }
.handling-tier-meanings dd:last-child { margin-bottom: 0; }

.mini-table, .plan-table, .workload-table {
  width: 100%;
  border-collapse: collapse;
  margin-top: 0.6rem;
  font-size: 0.88rem;
}
.mini-table th, .plan-table th, .workload-table th {
  text-align: left;
  padding: 0.3rem 0.4rem;
  border-bottom: 1px solid var(--ink);
  font-size: 0.75rem;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--ink-soft);
}
.mini-table td, .plan-table td, .workload-table td {
  padding: 0.35rem 0.4rem;
  border-bottom: 1px solid var(--rule);
  vertical-align: top;
}
.dog-cell { font-weight: 600; white-space: nowrap; }
/* .roster-table's row header (the name -- see the phone-card rule below)
 * is a `<th scope="row">` for the sake of that mobile card layout, but on
 * desktop it is an ordinary first column and must read like one, not
 * inherit the header row's small uppercase treatment from ".mini-table
 * th" above. */
.roster-table td, .roster-table th[scope="row"] {
  border-bottom: 1px solid var(--rule);
  padding: 0.35rem 0.4rem;
  vertical-align: top;
}
.roster-table th[scope="row"] {
  text-align: left;
  font-size: inherit;
  font-weight: 600;
  letter-spacing: normal;
  text-transform: none;
  color: var(--ink);
}
.notes-cell { line-height: 1.9; }
.input-card .mini-table { display: block; max-height: 26rem; overflow-y: auto; }
.commitments-table { background: var(--warning-wash); }

/* Dog-care and job minutes, stacked against what a person is recorded as
 * available for. The exact minutes stay in the columns beside this one;
 * the bar is only the shape a manager scans first. */
.workload-bar {
  display: flex;
  width: 6rem;
  height: 0.6rem;
  border: 1px solid var(--rule);
  border-radius: 2px;
  overflow: hidden;
  background: var(--page);
}
.workload-bar-handling { background: var(--accent); height: 100%; }
.workload-bar-chore { background: var(--ink-soft); height: 100%; }

.tag {
  display: inline-block;
  margin: 0 0.25rem 0.15rem 0;
  padding: 0.05rem 0.4rem;
  border-radius: 3px;
  background: var(--neutral-wash);
  font-size: 0.75rem;
  color: var(--ink-soft);
  white-space: nowrap;
}
.tag-held { background: var(--blocking-wash); color: var(--blocking); }
.tag-apart { background: var(--warning-wash); color: var(--warning); white-space: normal; }

.row-unknown { background: var(--warning-wash); }
.row-held { background: var(--blocking-wash); }

.inline-form, .add-form { display: inline-flex; gap: 0.3rem; align-items: center; flex-wrap: wrap; min-width: 0; max-width: 100%; }
.add-form { margin-top: 0.6rem; }
.add-form-stacked { display: flex; flex-direction: column; align-items: stretch; gap: 0.5rem; }
.add-form-stacked label { font-size: 0.82rem; color: var(--ink-soft); display: grid; gap: 0.2rem; }
.add-form-inline { margin-top: 0.5rem; padding-top: 0.5rem; border-top: 1px dotted var(--rule); }

/* ── The plan ─────────────────────────────────────────────────────── */

.plan-head {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
  align-items: baseline;
  justify-content: space-between;
}
.plan-head-actions { display: flex; gap: 0.6rem; align-items: center; flex-wrap: wrap; }
.plan-summary { margin: 0; font-size: 0.85rem; color: var(--ink-soft); }
.empty-state {
  margin: 1rem 0 0;
  padding: 1.25rem;
  background: var(--page);
  border: 1px dashed var(--rule);
  border-radius: 5px;
  color: var(--ink-soft);
}

.period { margin-top: 1.5rem; padding-top: 0.75rem; border-top: 2px solid var(--ink); }
.period-head { display: flex; flex-wrap: wrap; gap: 0.5rem 0.9rem; align-items: baseline; }
.period-time { margin: 0; font-weight: 600; color: var(--accent); }
.period-character { margin: 0; font-size: 0.85rem; color: var(--ink-soft); }
.empty-period { margin: 0.6rem 0 0; color: var(--ink-soft); font-size: 0.9rem; }

.chores { margin-top: 0.7rem; }
.chore-card {
  padding: 0.5rem 0.6rem;
  background: var(--page);
  border-radius: 4px;
  margin-bottom: 0.4rem;
  font-size: 0.85rem;
}
.chore-card-needs-attention { box-shadow: inset 3px 0 0 var(--warning); }
.chore-state {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  align-items: center;
  margin: 0;
}
.chore-time-label, .chore-who-label { color: var(--ink-soft); }
.chore-row {
  display: flex;
  flex-wrap: wrap;
  gap: 0.35rem;
  align-items: center;
  padding: 0.3rem 0.4rem;
  margin-top: 0.4rem;
}
.chore-label { min-width: 12rem; font-weight: 600; }
/* .section-edit / .disclosure-edit summaries: see brand.css. */

/* Blank controls are not a job on the plan. The saved rows are filled
 * cards; this one is an outlined tool set below them, so a row with no
 * label cannot be mistaken for a job whose label failed to render. */
.add-chore {
  margin-top: 0.7rem;
  padding: 0.45rem 0.5rem;
  border: 1px dashed var(--rule);
  border-radius: 4px;
  background: none;
  font-size: 0.85rem;
}
.add-form-label {
  min-width: 12rem;
  color: var(--ink-soft);
  font-weight: 600;
}

.row-blocked { background: var(--blocking-wash); }
.finding-row td { border-bottom: 1px solid var(--rule); padding-top: 0; }
.row-blocking {
  margin: 0.15rem 0;
  color: var(--blocking);
  font-weight: 600;
  font-size: 0.85rem;
}
.row-warning { margin: 0.15rem 0; color: var(--warning); font-size: 0.82rem; }
.live-check:empty { display: none; }
.live-check-ok { margin: 0.15rem 0; color: var(--clear); font-size: 0.82rem; }
.live-check-conflicts { margin: 0.15rem 0; color: var(--blocking); font-weight: 600; font-size: 0.85rem; }
.live-check-refused { margin: 0.15rem 0; color: var(--blocking); font-weight: 600; font-size: 0.85rem; }
.actions-cell { white-space: nowrap; }
.volunteer-row td { color: var(--ink-soft); }
.manager-execution-row td { color: var(--ink-soft); }

.focused-safety { border-color: var(--warning); }
.focused-safety .section-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 1rem;
}
.focused-safety .eyebrow {
  margin: 0 0 0.15rem;
  color: var(--warning);
  font-size: 12px;
  font-weight: 800;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}
.focused-safety-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 0.9rem;
  margin-top: 0.8rem;
}
.focused-safety-grid > * {
  min-width: 0;
  padding: 0.75rem;
  border: 1px solid var(--rule);
  border-radius: 5px;
  background: var(--page);
}
/* Unscoped (not just under .focused-safety): dog_detail.html and
 * staff_detail.html reuse this same safety-form/check-label markup
 * outside that wrapper, and without these rules a <label>Text<input></label>
 * pair has no default block relationship at all -- it falls back to plain
 * inline flow, so adjacent fields' labels and inputs visually interleave
 * instead of each field staying a distinct row. See _safety_editor.html
 * for the one place this was previously scoped to. */
.safety-form { display: grid; gap: 0.65rem; }
.safety-form label { display: grid; gap: 0.25rem; }
/* A form's save is its one primary action: filled, and sized to its label
 * rather than stretched across the grid. Removal and other secondary
 * buttons keep the ordinary bordered .button look. */
.safety-form > button[type="submit"]:last-child {
  justify-self: start;
  border-color: var(--accent-strong);
  background: var(--accent-strong);
  color: var(--lu-accent-ink);
  font-weight: 600;
}
.safety-form > button[type="submit"]:last-child:hover {
  border-color: var(--accent-strong-hover);
  background: var(--accent-strong-hover);
}
.dog-profile-edit[open] { margin-bottom: 0.75rem; }
.safety-form input[aria-invalid="true"] { border-color: var(--blocking); }

/* Dog detail's read-only sections (2026-08-30 tranche; extended to every
 * section below Identity 2026-08-31): a plain fact grid or paragraph,
 * not a form -- read first, before the edit disclosure below it. See
 * dog_detail.html and .dog-profile-edit/.dog-profile-form. */
.dog-profile-summary {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(11rem, 1fr));
  gap: 0.5rem 1.5rem;
  margin: 0 0 1rem;
  /* Capped so a handful of short facts (e.g. Staff detail's five-item
   * Profile) don't stretch each column to fill an ultra-wide panel far
   * beyond its content's own width -- auto-fit already wraps sensibly
   * at narrower widths; this only bounds the widest case (2026-09-01
   * review round 2, item 7). Dog detail's own denser summaries are
   * unaffected in ordinary layouts, since they already fill more of
   * this width with real fields. */
  max-width: 42rem;
}
.dog-profile-summary dt { margin: 0; font-size: 0.78rem; color: var(--ink-soft); }
.dog-profile-summary dd { margin: 0.1rem 0 0; font-weight: 600; }

/* Dog detail stays read-first: LDR's own record leads, active identity
 * work is visibly bounded beneath it, resolved history is collapsed, and
 * advisory import evidence is a separate low-emphasis disclosure.  These
 * use the same tokens and disclosure rhythm as the other record surfaces. */
.dog-record-provenance {
  display: flex;
  flex-wrap: wrap;
  gap: 0.2rem 0.55rem;
  margin: 0 0 0.75rem;
  padding: 0.45rem 0.6rem;
  border-left: 3px solid var(--accent);
  background: var(--neutral-wash);
  font-size: 0.88rem;
}
.dog-record-provenance span { color: var(--ink-soft); }
.identity-review {
  margin: 1rem 0 0;
  padding: 0.85rem;
  border: 1px solid var(--rule);
  border-left: 4px solid var(--accent);
  border-radius: 4px;
  background: var(--info-wash);
}
.identity-review > h3 { margin: 0; }
.identity-review > .muted { max-width: 52rem; margin: 0.3rem 0 0; }
.identity-review-pair {
  margin-top: 0.75rem;
  padding: 0.75rem;
  border: 1px solid var(--rule);
  border-left: 3px solid var(--accent);
  border-radius: 4px;
  background: var(--paper);
}
.identity-review-state-follow-up { border-left-color: var(--unknown); }
.identity-review-state-consolidation-outstanding { border-left-color: var(--lu-brand-brown); }
.identity-review-status { margin: 0 0 0.45rem; }
.identity-review-records {
  display: grid;
  grid-template-columns: repeat(2, minmax(12rem, 1fr));
  gap: 0.45rem 1rem;
}
.identity-review-records p { margin: 0; min-width: 0; overflow-wrap: anywhere; }
.identity-record-reference {
  display: block;
  margin-top: 0.1rem;
  color: var(--ink-soft);
  font-size: 0.8rem;
  font-weight: 600;
}
.identity-review-next,
.identity-review-notes {
  margin: 0.65rem 0 0;
  padding: 0.45rem 0.55rem;
  border-left: 2px solid var(--rule);
  background: var(--neutral-wash);
  overflow-wrap: anywhere;
}
.identity-review-next { border-left-color: var(--accent); }
.identity-review-notes { white-space: pre-line; }
.identity-review .safety-form,
.identity-review-history .safety-form {
  grid-template-columns: minmax(0, 1fr);
  min-width: 0;
}
.identity-review-pair .safety-form { margin-top: 0.75rem; }
.identity-review-context {
  margin-top: 0.55rem;
  padding-top: 0.25rem;
  border-top: 1px solid var(--rule);
}
.identity-review-context > .muted { margin: 0.1rem 0 0; }
.identity-review-context > .identity-review-notes { margin-top: 0.4rem; }
.identity-review-change {
  margin-top: 0.75rem;
  padding-top: 0.3rem;
  border-top: 1px solid var(--rule);
}
.identity-review-change > .muted { margin: 0.1rem 0 0; }
.identity-review-change > .safety-form { margin-top: 0.65rem; }
.identity-review .safety-form > label,
.identity-review-history .safety-form > label { min-width: 0; }
.identity-review .safety-form select,
.identity-review .safety-form textarea,
.identity-review-history .safety-form select,
.identity-review-history .safety-form textarea {
  width: 100%;
  min-width: 0;
  max-width: 100%;
}
.identity-review-recovery {
  margin-top: 0.75rem;
  padding: 0.75rem;
  border: 1px solid var(--blocking);
  border-radius: 4px;
  background: var(--blocking-wash);
}
.identity-review-recovery p { margin: 0 0 0.45rem; }
.identity-review-recovery .message { margin: 0 0 0.55rem; }
.identity-review-history {
  margin-top: 0.75rem;
  padding-top: 0.25rem;
  border-top: 1px solid var(--rule);
}
.identity-review-history > p { max-width: 52rem; }
.identity-review-history-item {
  margin-top: 0.55rem;
  padding: 0.55rem 0.65rem;
  border: 1px solid var(--rule);
  border-radius: 4px;
  background: var(--page);
}
.identity-review-history-item summary { cursor: pointer; font-weight: 600; }
.identity-review-history-item p { margin: 0.45rem 0 0; }
.identity-review-history-item .safety-form { margin-top: 0.65rem; }
.asm-source {
  margin-top: 0.75rem;
  padding: 0.55rem 0.65rem;
  border: 1px solid var(--rule);
  border-radius: 4px;
  background: var(--page);
}
.asm-source summary { cursor: pointer; font-weight: 600; }
.asm-source > .muted { margin: 0.55rem 0; max-width: 52rem; }
.asm-source .dog-profile-summary { max-width: 52rem; margin-bottom: 0; }
.asm-source-wide { grid-column: 1 / -1; }
.asm-source-wide dd { white-space: pre-line; overflow-wrap: anywhere; }
/* Staff detail's Login/Hours panels are a couple of lines of text and a
 * disclosure, not table-dense content -- unconstrained, they stretch to
 * the full board width and read as mostly empty (2026-09-01 review
 * round 2, item 7). IDs, not a shared class: scoped to this one page,
 * not a new panel style applied elsewhere. */
#profile, #login, #hours { max-width: 42rem; }
/* Volunteer records use the same read-first facts/disclosures as Dog and
 * Staff records, but have a different first question: can this person
 * handle a dog today?  Keep that fact visibly stronger without inventing a
 * new generic panel treatment for unrelated detail pages. */
.volunteer-authority-banner {
  max-width: 42rem;
  margin: 0.2rem 0 0;
  padding: 0.5rem 0.65rem;
  border-left: 4px solid var(--rule);
  border-radius: 0.3rem;
  background: var(--neutral-wash);
}
.volunteer-authority-cleared { border-left-color: var(--clear); }
.volunteer-authority-blocked { border-left-color: var(--warning); }
.volunteer-profile-panel, .volunteer-availability-panel, .volunteer-authority-panel { max-width: 42rem; }
.volunteer-profile-summary { max-width: none; margin-bottom: 0; }
.volunteer-profile-notes { grid-column: 1 / -1; }
.volunteer-profile-scope { margin: -0.15rem 0 0.85rem; color: var(--ink-soft); font-size: 0.9rem; }
.volunteer-availability-panel .dog-field-value:last-of-type { margin-bottom: 0; }
.availability-exception, .availability-adjustment {
  margin: 0.7rem 0 0;
  padding: 0.55rem 0.65rem;
  border-left: 3px solid var(--rule);
  background: var(--neutral-wash);
}
.availability-exception { border-left-color: var(--warning); background: var(--warning-wash); }
.volunteer-retained-approval-note { margin-top: 0.25rem; }
.profile-edit-error { margin: 0.5rem 0; padding: 0.55rem 0.65rem; border-left: 3px solid var(--blocking); background: var(--blocking-wash); }
.volunteer-authority-panel h3 { margin: 0.15rem 0 0.35rem; font-size: 0.9rem; }
.volunteer-automatic-eligibility { margin-top: 0.65rem; padding-top: 0.55rem; border-top: 1px solid var(--rule); }
.volunteer-refresh { margin: 0.5rem 0 0.75rem; }
/* The shared picker keeps a useful desktop minimum.  In this deliberately
 * bounded Volunteer panel it must instead fit the phone reading column when
 * its approval disclosure opens. */
.volunteer-authority-panel .filterable-select { min-width: 0; width: 100%; }
/* A section's single free-text field (critical handling, ordinary/
 * feeding notes, handling, placement) read as one line instead of an
 * always-open textarea -- an empty value reads as the one short phrase
 * "None recorded." rather than a blank box the same height as a filled
 * one. */
.dog-field-value { margin: 0 0 0.5rem; }
/* Approved handlers/separations/equipment/behavior-flags remove controls
 * (2026-08-31 review, round 4): now only reachable inside their own Edit
 * disclosure, but still a normal tap target once there -- .link-button's
 * own underlined-text size is too small for a mutation, several of them
 * safety-relevant. */
.dog-record-remove .link-button {
  display: inline-flex;
  align-items: center;
  min-height: 2.75rem;
  padding: 0 0.3rem;
}
/* Disclosure summaries (edit / info / section): see brand.css. */
.dog-profile-edit { margin-top: 0.25rem; }
/* Scoped to this one form, not the shared .safety-form rule every other
 * detail-page form also uses (staff/volunteer detail, the inline safety
 * editor on Plan/Attention) -- those keep their existing one-column
 * layout untouched. Short fields (name/breed/sex/size/DOB/weight) sit
 * side by side in sensible groups instead of each claiming the full
 * page width; the housing reason note and the submit button still span
 * the full row. */
.dog-profile-form {
  grid-template-columns: repeat(auto-fit, minmax(11rem, 1fr));
}
.dog-profile-form label:has(input[name="photo_url"]),
.dog-profile-form label:has(input[name="housing_reason"]),
.dog-profile-form > button {
  grid-column: 1 / -1;
}
.check-label {
  display: grid;
  grid-template-columns: auto 1fr;
  align-items: center;
}
/* One dimension, one form, one save action -- each dimension's own
 * "Reviewed"/"Not yet reviewed" chip sits right beside the button that
 * changes it, so a manager saving one fact can see it, and only it,
 * flip. Stacked with a rule between rather than merged into one grid:
 * these are independent submits, not one form's fields. */
.safety-dimension-form { padding-bottom: 0.65rem; border-bottom: 1px solid var(--rule); }
.safety-dimension-form:last-child { padding-bottom: 0; border-bottom: 0; }
.safety-dimension-actions { display: flex; align-items: center; gap: 0.5rem; }
.focused-safety .safety-list h3 { margin-top: 0; }
.gap-evidence { max-height: 18rem; overflow: auto; }

@media (max-width: 800px) {
  .focused-safety-grid { grid-template-columns: 1fr; }
}

.page-footer {
  margin-top: 2rem;
  padding-top: 0.75rem;
  border-top: 1px solid var(--rule);
  font-size: 0.8rem;
  color: var(--ink-soft);
}

/* ── Narrow screens ───────────────────────────────────────────────────
 *
 * The same route, the same markup, and the same forms — turned from a
 * seven-column grid into one card per dog. A phone cannot show a dog's
 * whole day across five columns without shrinking names to "Bri…" and
 * assignments to "Quic…", so on a narrow screen the columns become rows:
 * each dog is a card, each period is a labelled line inside it, and the
 * heading that would otherwise be off-screen is carried on the cell.
 *
 * Deliberately not a second rendering. Duplicating the board would
 * duplicate every edit form and every element id with it, and the copies
 * would drift; restyling the one DOM keeps opening a cell, correcting a
 * safety record and reassigning a handler working exactly as they do on
 * the desktop board.
 */
@media (max-width: 820px) {
  body { padding: 0 0.75rem 3rem; }

  /* The desktop board is sized to a viewport height so 25 dogs fit at
   * once. On a phone that traps the whole page inside a short scroller. */
  .board-shell { height: auto; margin: 0 -0.75rem; }
  .board-scroll { overflow: visible; }

  /* .surface-dogs (dog/staff detail and roster) is a plain panel-of-forms
   * page, not the board grid the negative margin above exists for -- left
   * as-is, it cancels body's own horizontal padding exactly, so every
   * panel runs flush to the screen edges with no gutter at all. */
  .surface-dogs .board-shell { margin: 0; }

  .topbar { flex-wrap: wrap; row-gap: 0.35rem; }
  .topbar h1 { font-size: 17px; }
  .topbar nav { flex-wrap: wrap; margin-left: 0; width: 100%; row-gap: 0.35rem; }
  .topbar nav a, .topbar .button { flex: 0 0 auto; }
  /* Dogs' compact record-count line can be wider than a narrow phone's
   * remaining header row.  It is factual context, not a fixed label, so
   * let it take its own line instead of pushing the whole page sideways. */
  .surface-dogs .topbar .dateline {
    flex: 1 1 100%;
    min-width: 0;
    white-space: normal;
    overflow-wrap: anywhere;
  }
  /* Volunteer detail's clearance banner is factual content, not the short
   * decorative dateline most detail pages use.  It must wrap beneath the
   * name on a phone instead of inheriting .topbar .dateline's desktop-only
   * nowrap and forcing the whole page sideways. */
  .topbar .volunteer-authority-banner {
    flex: 1 1 100%;
    min-width: 0;
    white-space: normal;
    overflow-wrap: anywhere;
    font-size: 0.82rem;
  }
  /* Chrome that only repeats what the h1 already says (finding #14) --
   * never the line carrying information the h1 doesn't have, so still
   * shown at any width where that's true (see the template's own
   * surface/is_today condition for exactly which pages qualify). */
  .dateline-redundant { display: none; }

  /* R21: on phone, the conditions line, topbar,
   * account nav and all three workspace-nav groups together used to
   * run past 500px of a 844px-tall viewport before any of the
   * surface's own status or content appeared. Every destination stays
   * present -- nothing here is hidden or removed -- only the padding
   * and sizing tuned for desktop width is tightened so the status
   * band and next action arrive sooner. */
  .conditions-strip { padding: 0.3rem 0.75rem; font-size: 0.72rem; }
  .account-nav { padding: 0.3rem 0.75rem; gap: 0.2rem 0.6rem; font: 0.78rem/1.3 var(--lu-font); }
  .account-nav a, .account-nav button { min-height: 1.9rem; }
  .workspace-nav { position: relative; padding-top: 0.35rem; padding-bottom: 0.35rem; row-gap: 0.35rem; }
  .workspace-nav-group a,
  .workspace-nav-records summary,
  .workspace-nav-views a { min-height: 2.75rem; padding: 0.25rem 0.55rem; font-size: 0.82rem; }
  .workspace-nav-group .nav-icon { display: none; }
  .workspace-nav-account { position: static; margin-left: auto; }
  .workspace-nav-account-menu { right: 0.6rem; top: calc(100% + 0.25rem); }
  .button {
    min-height: 2.75rem;
    align-content: center;
  }
  input[type="time"], input[type="text"], input[type="number"],
  input[type="search"], input[type="date"], input[type="url"],
  input[type="email"], input[type="password"], select { min-height: 2.75rem; }
  .add-chore { display: flex; }
  .add-chore > * { min-width: 0; max-width: 100%; }


  /* One person per line. As a wrapping flex row the names ran off the
   * side, and capping the height turned the overflow into a horizontal
   * scroller nobody would find. */
  .capacity { flex-direction: column; gap: 0.35rem; order: 2; }
  /* Plan's own staffing strip is what the order-after-board-content rule
   * above is for -- the status band and the actual dog roster are what a
   * phone is opened for, so they come first. Dogs/Staff/Volunteers reuse
   * the same .capacity class for their unrelated search bar (a plain
   * search form, not a flex layout inside board-shell), and inherited
   * that ordering by accident: on phone width, live QA found the whole
   * roster's search box rendered below every row instead of above them
   * (item 6, 2026-08-26 UX corrections). */
  .roster-search { order: initial; }
  /* Setup has no board content competing for attention -- the whole
   * surface is inputs to review -- so the same order:2 meant for Plan's
   * board instead pushed "who is in today" behind every other panel on
   * the page, including the detailed Places/commitments sections a
   * manager should already have that context before reading (2026-08-30
   * correction). A manager deciding what to change needs to know who is
   * actually working before the rest of Setup's inputs, on phone exactly
   * as on desktop. */
  .capacity-group ul { display: block; max-height: 4.5rem; }
  .capacity-group li { line-height: 1.5rem; }
  /* Who is in, and when. How much each of them already has planned is a
   * whole column of its own in the workload section below; carrying it
   * here wrapped every name onto two ragged lines and cut the roster
   * mid-word. */
  .capacity-group .load { display: none; }

  /* The status and the next action are what a phone is opened for, so
   * they come before the roster rather than after it. */
  .board-scroll { order: 3; }
  .status { padding: 0.5rem 0.75rem; }
  .status-line { display: block; font-size: 15px; }
  .status-line b { display: block; white-space: normal; font-size: 16px; }
  .status-line span { display: block; }
  .status-line .stamp { margin-left: 0; font-size: 12px; }

  .board { border-collapse: separate; }
  .board colgroup, .board thead { display: none; }
  .board, .board tbody, .board tr, .board th, .board td { display: block; width: auto; }

  .dog-row {
    margin: 0.5rem 0;
    border: 1px solid var(--rule);
    border-radius: 6px;
    background: var(--paper);
    overflow: hidden;
  }
  .dog-row .dog-name {
    /* Full names, always. A clipped name is not a name. */
    position: static;
    width: auto;
    max-width: none;
    height: auto;
    padding: 0.4rem 0.6rem;
    border-bottom: 1px solid var(--rule);
    background: var(--page);
    font-size: 16px;
    text-align: left;
    white-space: normal;
    overflow: visible;
    text-overflow: clip;
  }
  .dog-row .dog-status {
    height: auto;
    padding: 0.35rem 0.6rem;
    white-space: normal;
  }
  .dog-row .gap-line { display: block; white-space: normal; }

  .dog-row .cell { height: auto; padding: 0; border-bottom: 1px solid var(--rule); }
  .dog-row .cell:last-child { border-bottom: 0; }
  /* The column heading is gone, so each line names its own period. */
  .dog-row .cell::before {
    content: attr(data-period);
    display: block;
    padding: 0.3rem 0.6rem 0;
    color: var(--ink-soft);
    font-size: 12px;
  }
  .dog-row .cell-line {
    display: block;
    height: auto;
    padding: 0 0.6rem 0.35rem;
    font-size: 14px;
    line-height: 1.35;
    white-space: normal;
    overflow: visible;
    text-overflow: clip;
  }
  /* A period with nothing in it is one quiet line, not a third of a card. */
  .dog-row .cell:has(.cell-line-empty) { display: flex; align-items: baseline; gap: 0.4rem; }
  .dog-row .cell:has(.cell-line-empty)::before { padding-bottom: 0.3rem; }

  .detail-row { display: block; height: auto; }
  /* The base ".board tbody th, .board tbody td { height: 28px }" rule
     (every td/th in tbody, so an open cell's edit form -- real content,
     not a data cell -- inherits it too) outranks a plain ".detail-row >
     td" on specificity alone regardless of source order, clipping the
     open form to one row-height and letting the next dog's opaque card
     paint over the rest of it: correcting an outing on phone looked
     like the form was simply missing. ".board tbody" in the selector
     matches that specificity so this override actually wins. */
  .board tbody .detail-row > td { display: block; padding: 0; height: auto; }
  .detail { padding: 0.6rem; }
  .stack-row { flex-wrap: wrap; }
  /* The edit form's own core actions (Save, remove, cancel/close) meet
     the established ~44px touch-target minimum here (see .panel summary,
     .dog-record-remove .link-button) -- scoped to this mobile form
     context rather than raised on .button-small/.link-button's own base
     rule, which are shared far too widely elsewhere on the page to
     change size everywhere just for this (2026-08-31 review). Desktop is
     unaffected: a mouse click does not need a 44px target, and the
     board's tight per-row rhythm depends on staying compact there. */
  .detail .button, .detail .link-button {
    min-height: 2.75rem;
    display: inline-flex;
    align-items: center;
    padding-left: 0.5rem;
    padding-right: 0.5rem;
  }
  .cell-line-open { min-height: 2.75rem; display: flex; align-items: center; }

  /* Workload is a reference table, not something to read across on a
   * phone: each person becomes a small labelled card. */
  .workload-table { border-collapse: separate; }
  .workload-table thead { display: none; }
  .workload-table, .workload-table tbody, .workload-table tr,
  .workload-table th, .workload-table td { display: block; width: auto; }
  .workload-table tr {
    margin: 0.5rem 0;
    padding: 0.4rem 0.6rem;
    border: 1px solid var(--rule);
    border-radius: 6px;
  }
  .workload-table tr > th[scope="row"] {
    padding: 0 0 0.25rem;
    border: 0;
    font-size: 15px;
    text-align: left;
  }
  .workload-table td {
    display: flex;
    justify-content: space-between;
    gap: 0.75rem;
    padding: 0.15rem 0;
    border: 0;
    font-size: 14px;
  }
  .workload-table td::before {
    content: attr(data-label);
    color: var(--ink-soft);
  }

  .warning-columns { display: block; }
  .review-dimensions > li { display: block; }
  .review-waiting { display: block; margin-top: 0.15rem; }

  /* The 12rem/1fr/16rem attention-group grid assumes desktop width; on a
   * phone the fixed side columns force the middle one down to almost
   * nothing, so "subject" / "problem" / "action" each wrap onto several
   * narrow lines instead of one row -- ten rows becoming a much longer
   * scroll than the same ten rows need to be. */
  .attention-group li { display: block; padding: 0.5rem 0.35rem; }
  .attention-group li > a { display: block; }
  .attention-group li > span { display: block; margin-top: 0.15rem; }
  .attention-group li > small { display: block; margin-top: 0.15rem; }

  .mini-table { display: block; overflow-x: auto; }

  /* Volunteer handoffs (Team): five columns of short values fit an
   * ordinary phone width, but not the narrower effective viewport a
   * 400% browser zoom produces -- contained horizontal scroll here
   * keeps that overflow off the page itself (2026-09-01 review round
   * 2 zoom/reflow check). */
  .plan-table { display: block; overflow-x: auto; }

  /* Dogs, Staff, and Volunteers are read on a phone as often as a desk,
   * and a generic table forced into horizontal scroll hides the very
   * thing a manager opened the roster to check (item 6, 2026-08-26 UX
   * corrections). Same card mechanism as .workload-table above -- the
   * name becomes each card's own heading (th scope="row" in the
   * template), every other column becomes one labelled line -- but each
   * roster keeps its own column order/content rather than a forced
   * identical template, since what matters first differs per roster. */
  .roster-table.mini-table { display: block; overflow-x: visible; border-collapse: separate; }
  .roster-table thead { display: none; }
  .roster-table, .roster-table tbody, .roster-table tr,
  .roster-table th, .roster-table td { display: block; width: auto; }
  .roster-table tr {
    margin: 0.5rem 0;
    padding: 0.5rem 0.7rem;
    border: 1px solid var(--rule);
    border-radius: 6px;
  }
  .roster-table tr > th[scope="row"] {
    padding: 0 0 0.3rem;
    border: 0;
    font-size: 16px;
  }
  .roster-table tr > th[scope="row"] a { text-decoration: none; }
  .roster-table td {
    display: flex;
    justify-content: space-between;
    align-items: baseline;
    gap: 0.75rem;
    padding: 0.2rem 0;
    border: 0;
    font-size: 14px;
  }
  .roster-table td::before {
    content: attr(data-label);
    color: var(--ink-soft);
    flex: 0 0 auto;
  }
  /* An empty-state row (no dog/staff/volunteer matches) has no data-label
   * columns to key off of -- let it read as one plain line, not a card
   * with a blank heading. */
  .roster-table tr:has(td[colspan]) { border: 0; padding: 0.35rem 0; }
  .roster-table tr:has(td[colspan]) td { display: block; }
  .roster-table tr:has(td[colspan]) td::before { content: none; }
  /* The three groups wrap onto their own lines (workspace-nav already
   * has flex-wrap); the segmented group itself now wraps its five
   * pills too, rather than scrolling them sideways with no visible
   * cue that Team was still there to find (finding #7, 2026-08-17 UX
   * handoff: "Team can sit offscreen" on phone width). Every
   * destination stays discoverable without a hidden horizontal tab. */
  .workspace-nav { padding-left: 0.6rem; padding-right: 0.6rem; }
  .workspace-nav-group { flex-wrap: wrap; max-width: 100%; }
  /* The two cross-device view pills are their own flex group. Giving that
   * group the same bounded, wrapping treatment as the day-nav group keeps
   * Staff Today + Kitchen Display from creating a few pixels of document
   * overflow at phone width or 400% reflow. */
  .workspace-nav-views { display: contents; }
  /* Dogs' own page-local filter tabs are the same segmented-pill
   * pattern as workspace-nav-group above, and need the identical fix:
   * five tabs in an unwrapping inline-flex row overflowed the viewport
   * at phone width with no visible cue that a filter still ran off the
   * side (R30). */
  .dog-filter-tabs { flex-wrap: wrap; max-width: 100%; }
  .surface-dogs .dog-filter-tabs a {
    min-height: 2.75rem;
    padding-left: 0.7rem;
    padding-right: 0.7rem;
  }
  .surface-dogs .button-small,
  .surface-dogs .topbar nav a {
    display: inline-flex;
    align-items: center;
    min-height: 2.75rem;
  }
  .dogs-roster-controls-desktop { display: none; }
  .surface-dogs .dogs-roster-total-count { display: none; }
  .dogs-roster-guidance { margin-top: 0.55rem; }
  .dogs-roster-guidance-full { display: none; }
  .dogs-roster-guidance-compact { display: inline; }
  .dogs-roster-controls-mobile {
    display: block;
    margin: 0.45rem 0.75rem 0;
    padding-top: 0.3rem;
    border-top: 1px solid var(--rule);
  }
  .dogs-roster-controls-mobile .dog-filter-groups { display: block; padding: 0; }
  .dogs-roster-controls-mobile .dog-filter-group + .dog-filter-group { margin-top: 0.1rem; }
  .dogs-roster-controls-mobile .roster-search { margin-left: 0; margin-right: 0; }
  .dogs-roster-results-heading,
  .dogs-roster-results-guidance,
  .import-review-heading {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    border: 0;
  }
  .import-review-guidance { display: none; }
  .import-review-compact-guidance {
    display: block;
    margin: 0;
    color: var(--ink-soft);
    font-size: 0.82rem;
  }
  .import-review-list { margin-top: 0.5rem; }
  .dog-filter-group + .dog-filter-group { margin-top: 0.1rem; }
  .dogs-roster-guidance, .dogs-roster-results, .import-review-queue, .asm-sync {
    margin-left: 0.75rem;
    margin-right: 0.75rem;
  }
  .import-review-item {
    grid-template-columns: minmax(0, 1fr);
    gap: 0.65rem;
  }
  .import-review-problem { grid-column: auto; }
  .import-review-item > .button { justify-self: start; }
  .dogs-roster-results, .import-review-queue { margin-top: 0.85rem; }
  .identity-review { padding: 0.7rem; }
  .identity-review-records { grid-template-columns: minmax(0, 1fr); }
  .identity-review-pair, .identity-review-recovery { padding: 0.65rem; }
  .volunteer-availability-line b { min-width: 0; flex-basis: 100%; }
  .repair-callout .button-repair { width: 100%; justify-content: space-between; }
}

/* ── The watermark, and printing the working copy ─────────────────── */

.working-watermark { display: none; }

@media print {
  @page { margin: 14mm; }

  body {
    background: #fff;
    padding: 0;
    font-size: 10pt;
  }

  /* Repeats on every printed page. */
  .working-watermark {
    display: flex;
    position: fixed;
    inset: 0;
    align-items: center;
    justify-content: center;
    z-index: 9999;
    pointer-events: none;
  }
  .working-watermark span {
    transform: rotate(-32deg);
    font-size: 34pt;
    font-weight: 800;
    letter-spacing: 0.06em;
    color: rgba(163, 34, 29, 0.22);
    border: 6px solid rgba(163, 34, 29, 0.22);
    padding: 0.4em 0.8em;
    text-align: center;
    line-height: 1.15;
  }

  /* And a plain banner in the flow, at the top of every section, so the
   * notice survives print engines that drop fixed elements after page one. */
  .topbar::before { flex: 0 0 100%; order: -1; }

  .topbar::before,
  .panel::before,
  .band::before,
  .period::before {
    content: "WORKING PLAN — NOT FOR OPERATIONAL USE";
    display: block;
    margin-bottom: 0.35rem;
    padding: 2pt 0;
    border-top: 2pt solid #a3221d;
    border-bottom: 2pt solid #a3221d;
    color: #a3221d;
    font-size: 8pt;
    font-weight: 800;
    letter-spacing: 0.16em;
    text-align: center;
  }

  /* Deliberately not the whiteboard sheet: no boxed panels, no columns. */
  .panel, .band {
    border: 0;
    border-radius: 0;
    padding: 0;
    margin: 0.6rem 0 0;
    background: none;
  }
  .warning-columns { display: block; }
  .input-card .mini-table { display: table; max-height: none; overflow: visible; }
  .topbar { border-bottom: 1pt solid #999; padding-top: 0; flex-wrap: wrap; }
  .period { border-top: 1pt dashed #999; }
  .period-time { color: #000; }

  .topbar nav,
  .plan-head-actions,
  .add-form,
  .actions-cell,
  .link-button,
  .button,
  .messages,
  .conditions-strip { display: none !important; }

  /* The board is a screen layout: on paper it becomes an ordinary long
   * table so no dog row is cut off by the viewport height it was sized to. */
  .board-shell { display: block; height: auto; margin: 0; border-bottom: 0; }
  .board-scroll { overflow: visible; }
  .board thead th { position: static; }
  .capacity-group ul { max-height: none; overflow: visible; }
  .board tbody th, .board tbody td { height: auto; font-size: 9pt; }
  .cell-line { white-space: normal; overflow: visible; }

  details { display: block; }
  details > summary { list-style: none; }
  details:not([open]) > *:not(summary) { display: revert; }

  select, input {
    border: 0;
    padding: 0;
    background: none;
    -webkit-appearance: none;
    appearance: none;
    font-size: 9pt;
  }
}
.recent-history-note {
  margin: .65rem 1rem;
  padding: .55rem .75rem;
  border: 1px solid var(--rule);
  border-radius: .4rem;
  background: var(--neutral-wash);
  font-size: .88rem;
}
.recent-history-note summary { cursor: pointer; font-weight: 700; }
.recent-history-note p { margin: .45rem 0 0; max-width: 90ch; }

/* A searchable listbox for choosing one person/dog out of a large roster
   (e.g. an approved-handler picker) -- see filterable_select.js. */
.filterable-select { display: flex; flex-direction: column; gap: 0.3rem; min-width: 16rem; }
.filterable-select select { min-height: 8rem; }

/* Supervised group sessions, above the board: one interval, one place,
   the dogs in it, and the person supervising -- the unit a manager acts
   on, rather than N handlerless member rows to reassemble by eye. */
.group-sessions { display: flex; flex-wrap: wrap; gap: .6rem; }
.group-session {
  border: 1px solid var(--rule);
  border-left: 4px solid var(--accent);
  border-radius: .4rem;
  padding: .5rem .7rem;
  background: var(--neutral-wash);
  font-size: .9rem;
}
.group-session-blocked { border-left-color: var(--blocking); }
.group-session p { margin: 0; }
.group-session-dogs { font-weight: 600; }
.group-session-who { color: var(--ink-soft); }
.group-session-blockers { margin: .35rem 0 0; padding: 0; list-style: none; }

.uncovered-chores { margin: 0.6rem 0; }
.uncovered-chores h3 { font-size: 0.85rem; margin: 0 0 0.3rem; }
.uncovered-chores li { margin-bottom: 0.2rem; }

.row-needs-attention { background: var(--warning-wash); }

.workload-purpose { margin: 0.4rem 0 0.8rem; }
.workload-by-person, .execution-workload-detail { margin-top: 0.8rem; }

/* Dated hours and checkbox selectors remain usable at phone widths. */
.hours-batch-row { display: flex; flex-wrap: wrap; align-items: center; gap: .65rem; margin-block: .75rem; min-width: 0; }
.hours-batch-row label { display: flex; flex-wrap: wrap; align-items: center; gap: .4rem; }
[data-handler-choice] label { display: flex; align-items: center; gap: .6rem; min-height: 44px; }
[data-handler-choice][hidden] { display: none; }
.hours-batch-row .errorlist { flex-basis: 100%; }

/* A proposal exists but cannot be accepted as it stands (not ready, out of
 * date, or unfinished): the manager must act before Accept is possible. */
.chip-proposal-not-ready, .chip-proposal-stale, .chip-proposal-failed,
.chip-proposal-blocked { background: var(--blocking-wash); color: var(--blocking); font-weight: 600; }
.chip-proposal-building { background: var(--info-wash); color: var(--accent); font-weight: 600; }

/* Care proposal (Preview): verdict first, one compact row per dog. */
.preview-shell { height: auto; }
.submit-pending { margin-inline-start: .5rem; font-weight: 600; color: var(--ink, #342d24); }
.preview-main { display: grid; gap: 1rem; padding-block: 1rem; }
.preview-main > *, .preview-shell > * { min-width: 0; }
.proposal-verdict h2 { margin: 0 0 0.5rem; }
.proposal-verdict .chip { font-size: 1rem; padding: 0.3rem 0.8rem; }
.proposal-verdict-ready { border-left: 5px solid var(--clear); }
.proposal-verdict-not_ready, .proposal-verdict-stale, .proposal-verdict-failed { border-left: 5px solid var(--blocking); }
.proposal-verdict-building { border-left: 5px solid var(--accent); }
.chip-proposal-ready, .chip-proposal-accepted { background: var(--clear-wash, #f0f7f2); color: var(--clear); font-weight: 600; }
.chip-proposal-not_ready { background: var(--blocking-wash); color: var(--blocking); font-weight: 600; }
.verdict-detail { font-size: 1.02rem; margin: 0 0 0.5rem; }
.preview-actions { display: flex; flex-wrap: wrap; gap: 0.6rem; margin-top: 0.75rem; }
.band-links { margin: 0.75rem 0 0; }
.table-scroll { overflow-x: auto; max-width: 100%; }
.dog-day-table { border-collapse: collapse; width: 100%; min-width: var(--dog-table-min, 760px); display: var(--dog-table-display, table); font-size: 0.9rem; }
.dog-day-table th, .dog-day-table td { text-align: left; vertical-align: top; padding: 0.4rem 0.5rem; border-bottom: 1px solid var(--rule, #e2d6c4); }
.dog-day-table thead th { position: sticky; top: 0; background: var(--paper, #fdfaf5); font-size: 0.8rem; text-transform: uppercase; letter-spacing: 0.04em; }
.dog-day-table thead { display: var(--dog-head-display, table-header-group); }
.dog-day-table tbody { display: var(--dog-block-display, table-row-group); width: var(--dog-block-width, auto); }
.dog-day-table tr { display: var(--dog-block-display, table-row); width: var(--dog-block-width, auto); }
.dog-day-table tbody tr { padding: var(--dog-row-padding, 0); border-bottom: var(--dog-row-rule, 0); }
.dog-day-table tbody th, .dog-day-table tbody td { display: var(--dog-block-display, table-cell); width: var(--dog-block-width, auto); overflow-wrap: var(--dog-cell-wrap, inherit); border-bottom: var(--dog-cell-rule, 1px solid var(--rule, #e2d6c4)); }
.dog-day-table tbody th { white-space: var(--dog-cell-white, nowrap); }
.dog-day-table tbody td { white-space: var(--dog-cell-white, normal); }
.dog-day-table tbody td[data-period]::before { display: var(--dog-label-display, none); font-weight: 700; color: var(--ink, #342d24); }
.dog-day-table td[data-period="opening"]::before { content: "Opening potties"; }
.dog-day-table td[data-period="am"]::before { content: "Morning"; }
.dog-day-table td[data-period="midday"]::before { content: "Midday"; }
.dog-day-table td[data-period="pm"]::before { content: "Afternoon"; }
.dog-day-table td[data-period="closing"]::before { content: "Closing potties"; }
.dog-day-table td p { margin: 0 0 0.2rem; }
@media (max-width: 600px) {
  .preview-shell, .preview-main, .preview-main > * { width: 100%; min-width: 0; }
  .preview-main { display: block; }
  .preview-main > * { margin-block-end: 1rem; }
  .table-scroll {
    --dog-table-min: 0; --dog-table-display: block; --dog-head-display: none;
    --dog-block-display: block; --dog-block-width: 100%; --dog-cell-wrap: anywhere;
    --dog-row-padding: .5rem 0; --dog-row-rule: 1px solid var(--rule, #e2d6c4);
    --dog-cell-rule: 0; --dog-cell-white: normal; --dog-label-display: block;
    --dog-cell-min: 0;
  }
  .dog-day-table .dog-day-note td { padding-top: .5rem; }
}
.dog-day-note td { color: var(--blocking); font-size: 0.85rem; }
.preview-disclosure > summary h2 { display: inline-flex; align-items: center; gap: 0.5rem; margin: 0; }
.volunteer-routes li { padding: 0.25rem 0; }
.count { font-size: 0.8rem; font-weight: 700; background: var(--neutral-wash); border-radius: 999px; padding: 0.05rem 0.5rem; }

/* Attention recovery: one cause, its consequences, one decision each. */
.recovery-cause { border-top: 1px solid var(--rule); padding-top: 0.75rem; margin-top: 0.75rem; }
.recovery-cause h3 { display: flex; align-items: center; gap: 0.5rem; margin: 0 0 0.5rem; font-size: 1.05rem; }
.recovery-bulk { display: flex; flex-wrap: wrap; align-items: center; gap: 0.5rem; margin: 0 0 0.75rem;
  padding: 0.6rem 0.75rem; background: var(--info-wash); border-radius: var(--lu-radius-md, 8px); }
.recovery-bulk input[name="reason"] { min-width: 16rem; flex: 1; }
.recovery-item { padding: 0.4rem 0; border-bottom: 1px solid var(--rule); }
.recovery-item:last-child { border-bottom: 0; }
.recovery-item:target { background: var(--info-wash); outline: 2px solid var(--accent); outline-offset: 2px; }
.recovery-subject { margin: 0 0 0.35rem; }
.recovery-subject span { color: var(--ink-soft); }
.recovery-item form { display: flex; flex-wrap: wrap; align-items: center; gap: 0.5rem; }
.recovery-choose { display: grid !important; gap: 0.5rem; }
.recovery-choose fieldset { border: 1px solid var(--rule); border-radius: var(--lu-radius-sm, 4px); padding: 0.5rem 0.75rem; margin: 0; }
.recovery-choose legend { font-weight: 600; padding: 0 0.25rem; }
.recovery-option { display: flex; gap: 0.5rem; align-items: flex-start; padding: 0.3rem 0; min-height: 32px; }
.recovery-none { margin-top: 0.4rem; }
.recovery-none .inline-form { display: flex; flex-wrap: wrap; align-items: center; gap: 0.5rem; }
.recovery-none .inline-form input[name="reason"] { flex: 1 1 14rem; min-width: 0; }
.recovery-group { border-top: 1px solid var(--rule); }
.recovery-group:first-of-type { border-top: 0; }
.recovery-group > summary { cursor: pointer; padding: 0.45rem 0; min-height: 32px; }
.recovery-group[open] > summary { font-weight: 600; }
.recovery-group .recovery-option-block { padding-left: 1.25rem; }
.recovery-who { color: var(--ink-soft); }
.recovery-group > summary { flex-wrap: wrap; }
.recovery-group > summary .muted { margin-left: 0.35rem; white-space: nowrap; }
.recovery-equipment { margin: 0 0 0.3rem 1.6rem; font-size: 0.9rem; }
.recovery-equipment label { display: flex; gap: 0.4rem; align-items: center; min-height: 32px; }
.recovery-choose input[name="reason"] { font: inherit; padding: 0.35rem 0.5rem; border: 1px solid var(--rule); border-radius: var(--lu-radius-sm, 4px); max-width: 100%; }
.attention-decided { border-left: 4px solid var(--ink-soft); }
.attention-group li a b { color: var(--lu-link); text-decoration: underline; }

/* Accepted Plan board: one row per dog, expandable items per period. */
.plan-care-table td { min-width: var(--dog-cell-min, 150px); }
.care-cell { margin: 0 0 0.3rem; border-radius: var(--lu-radius-sm, 4px); }
.care-cell > summary { cursor: pointer; list-style: none; padding: 0.2rem 0.35rem; border-radius: var(--lu-radius-sm, 4px);
  display: flex; flex-wrap: wrap; gap: 0.15rem 0.4rem; align-items: baseline; }
.care-cell > summary::-webkit-details-marker { display: none; }
.care-cell > summary:hover, .care-cell[open] > summary { background: var(--neutral-wash); }
.care-cell-who { color: var(--ink-soft); font-size: 0.85rem; }
.care-cell-body { padding: 0.35rem 0.5rem 0.5rem; font-size: 0.85rem; border-left: 2px solid var(--rule); margin: 0.2rem 0 0.4rem 0.35rem; }
.care-cell-body p { margin: 0.15rem 0; }
.care-cell:target > summary { outline: 2px solid var(--accent); }
.state-chip { font-size: 0.72rem; font-weight: 700; border-radius: 999px; padding: 0 0.45rem; background: var(--neutral-wash); color: var(--ink-soft); white-space: nowrap; }
.state-ready { background: var(--clear-wash); color: var(--clear); }
.state-active { background: var(--clear); color: var(--lu-accent-ink); }
.state-failed { background: var(--blocking); color: var(--lu-accent-ink); }
.state-attention { background: var(--warning-wash, #fdf7e9); color: var(--warning); }
.state-done { background: transparent; color: var(--ink-soft); }
.duty-periods { display: grid; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); gap: 0.75rem; }
.duty-periods h3 { margin: 0 0 0.3rem; font-size: 0.95rem; }

/* Help topics are one column of equal-width cards, open or closed. */
.surface-help details { box-sizing: border-box; width: 100%; }


/* Change today's work: Add care / Add job. A compact grid of short choices,
 * then the checks that need reading (equipment, timing), then Why and the
 * one action -- instead of a loose run of labels and selects. One column on
 * a phone; the same order at every width. */
.adjust-form {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(13rem, 1fr));
  gap: 0.85rem 1rem;
  max-width: 52rem;
  margin-top: 0.75rem;
  padding: 1rem;
  border: 1px solid var(--rule);
  border-radius: var(--lu-radius-md);
  background: var(--page);
}
.adjust-field { display: flex; flex-direction: column; gap: 0.25rem; min-width: 0; }
.adjust-field label { font-size: 0.85rem; font-weight: 600; color: var(--ink-soft); }
.adjust-field select, .adjust-field input:not([type="checkbox"]) { width: 100%; min-width: 0; }
.adjust-wide, .adjust-equipment, .adjust-actions { grid-column: 1 / -1; }
.adjust-equipment {
  margin: 0;
  padding: 0.6rem 0.8rem;
  border: 1px solid var(--rule);
  border-radius: var(--lu-radius-sm);
  background: var(--paper);
}
.adjust-equipment legend { padding: 0 0.3rem; font-size: 0.85rem; font-weight: 600; color: var(--ink-soft); }
.adjust-equipment p { margin: 0 0 0.35rem; }
.adjust-check { display: flex; align-items: center; gap: 0.5rem; min-height: var(--lu-touch); font-weight: 600; }
.adjust-times { display: grid; grid-template-columns: repeat(auto-fit, minmax(9rem, 12rem)); gap: 0.75rem; margin-top: 0.25rem; }
.adjust-actions { display: flex; }

.next-step-action { display: flex; flex-wrap: wrap; align-items: center; gap: 0.6rem 0.9rem; }
.next-step-action .inline-form { margin: 0; }

/* Setup: Staff availability today. One row per person -- who (with any recorded
 * callout), the reason, the action -- in a grid that stacks on a phone. */
.availability-item { padding: 0.6rem 0; }
.availability-form {
  display: grid;
  grid-template-columns: minmax(10rem, 16rem) minmax(0, 1fr) auto;
  gap: 0.4rem 1rem;
  align-items: end;
}
.availability-who { align-self: center; min-width: 0; }
.availability-status { margin: 0.15rem 0 0; font-size: 0.85rem; }
.availability-reason { display: flex; flex-direction: column; gap: 0.2rem; min-width: 0; font-size: 0.85rem; font-weight: 600; color: var(--ink-soft); }
.availability-reason input { width: 100%; min-width: 0; font-weight: 400; }
@media (max-width: 640px) {
  .availability-form { grid-template-columns: minmax(0, 1fr); }
  .availability-form .button { justify-self: start; min-height: 2.75rem; }
}

/* The Volunteers roster sits inside the same page gutters as the Dogs roster,
 * with a wide table scrolling inside its own box rather than the page. */
.volunteer-roster-body { margin: 0 1rem; }
.volunteer-roster-body > .dog-filter-tabs { max-width: 100%; flex-wrap: wrap; }
.volunteer-roster-body .roster-table { max-width: 100%; }
@media (max-width: 640px) {
  .volunteer-roster-body { margin: 0 0.75rem; }
}
