/* SpaceOps — Weekly Pattern.
 *
 * Scoped to the three pattern pages. Everything is .wp-* prefixed. Colours come
 * from the Kadence tokens only — nothing here hard-codes a hex.
 *
 * Density is deliberate. This screen replaces a spreadsheet, and a planner who
 * lives in Excel reads a sparse layout as a toy.
 */

/* Team colour palette, mirrored from the stack-plan artefact in
   space-ops/agent/conversation so a team keeps one colour across both surfaces.
   Index is hashString(name) % 51, same derivation as _shared/js/seed.js. */
/* Team colour palette (subset of space-ops-colors.scss — first 16). */
:root {
  --space-ops-0:  hsl(357, 96%, 58%);
  --space-ops-1:  hsl(25, 100%, 50%);
  --space-ops-2:  hsl(36, 100%, 50%);
  --space-ops-3:  hsl(44, 100%, 47%);
  --space-ops-4:  hsl(84, 100%, 41%);
  --space-ops-5:  hsl(144, 100%, 39%);
  --space-ops-6:  hsl(160, 100%, 37%);
  --space-ops-7:  hsl(174, 100%, 37%);
  --space-ops-8:  hsl(190, 100%, 43%);
  --space-ops-9:  hsl(199, 100%, 48%);
  --space-ops-10: hsl(216, 100%, 58%);
  --space-ops-11: hsl(241, 100%, 69%);
  --space-ops-12: hsl(261, 100%, 66%);
  --space-ops-13: hsl(273, 100%, 64%);
  --space-ops-14: hsl(293, 96%, 58%);
  --space-ops-15: hsl(328, 92%, 58%);
  --space-ops-16: hsl(345, 100%, 56%);
  --space-ops-17: hsl(359, 100%, 82%);
  --space-ops-18: hsl(31, 100%, 71%);
  --space-ops-19: hsl(47, 100%, 59%);
  --space-ops-20: hsl(52, 100%, 56%);
  --space-ops-21: hsl(81, 88%, 64%);
  --space-ops-22: hsl(143, 82%, 71%);
  --space-ops-23: hsl(157, 77%, 64%);
  --space-ops-24: hsl(172, 81%, 60%);
  --space-ops-25: hsl(187, 98%, 66%);
  --space-ops-26: hsl(199, 100%, 73%);
  --space-ops-27: hsl(210, 100%, 78%);
  --space-ops-28: hsl(229, 100%, 82%);
  --space-ops-29: hsl(254, 100%, 85%);
  --space-ops-30: hsl(271, 100%, 85%);
  --space-ops-31: hsl(292, 100%, 83%);
  --space-ops-32: hsl(328, 98%, 82%);
  --space-ops-33: hsl(351, 100%, 81%);
  --space-ops-34: hsl(358, 100%, 38%);
  --space-ops-35: hsl(16, 100%, 40%);
  --space-ops-36: hsl(25, 100%, 37%);
  --space-ops-37: hsl(34, 100%, 33%);
  --space-ops-38: hsl(85, 100%, 25%);
  --space-ops-39: hsl(145, 100%, 25%);
  --space-ops-40: hsl(162, 100%, 24%);
  --space-ops-41: hsl(176, 100%, 24%);
  --space-ops-42: hsl(193, 100%, 29%);
  --space-ops-43: hsl(203, 100%, 33%);
  --space-ops-44: hsl(225, 84%, 49%);
  --space-ops-45: hsl(248, 68%, 51%);
  --space-ops-46: hsl(268, 94%, 47%);
  --space-ops-47: hsl(276, 100%, 43%);
  --space-ops-48: hsl(295, 100%, 36%);
  --space-ops-49: hsl(332, 100%, 39%);
  --space-ops-50: hsl(344, 100%, 39%);
}
.stack-plan-tab { display: flex; flex-direction: column; }

/* ------------------------------------------------------------------ page */

wx-weekly-pattern {
  display: flex; flex-direction: column;
  flex: 1; min-height: 0;
  padding: 0 2rem 1rem;
  background: var(--bulma-background);
}

.wp-topline {
  display: flex; align-items: center; justify-content: space-between;
  gap: 0.875rem 1.5rem; padding: 1rem 0 0.875rem; flex-shrink: 0;
  /* The toolbar grew a lens and a scenario switcher. Below about 1300px those no
     longer fit beside the title, and a toolbar that cannot fit must wrap — until
     this it overlapped the building name instead. When it does wrap the row gap
     has to be generous, or the two rows read as one dense block. */
  flex-wrap: wrap;
}
.wp-topline__left { display: flex; align-items: center; gap: 0.75rem; min-width: 0; overflow: hidden; }
/* The building name never wraps. When space is tight it ellipses and the meta
   line gives way first — a two-line title costs a row of the grid. */
.wp-topline__title {
  font-size: 1.25rem; font-weight: 700; color: var(--bulma-text); margin: 0;
  white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
}
.wp-topline__meta { font-size: 0.75rem; font-weight: 500; color: var(--bulma-text-weak); white-space: nowrap; }
.wp-topline__meta b { color: var(--bulma-text); font-weight: 600; }
/* Seven controls in one even row read as one long undifferentiated strip. They
   are really four jobs — the model numbers, the two lenses, the panels, and the
   action — so they are spaced and ruled as four. */
.wp-toolbar { display: flex; align-items: center; gap: 0.5rem 1.25rem; flex-shrink: 0; flex-wrap: wrap; }
.wp-toolgroup { display: flex; align-items: center; gap: 0.375rem; }
/* --bulma-border is #eceeef, which on the toolbar's own near-white background is
   invisible — a rule nobody can see is not a rule. grey-300 reads as a divider
   without reading as a border. */
.wp-toolgroup + .wp-toolgroup::before {
  content: ''; width: 1px; height: 1.5rem; flex-shrink: 0;
  background: var(--kadence-grey-300); margin-right: 0.875rem;
}
/* The primary action keeps the right edge to itself at any width. */
.wp-toolgroup--action { margin-left: auto; gap: 0.5rem; }
@media (max-width: 1100px) {
  .wp-toolgroup--action { margin-left: 0; }
}

/* Segmented control — the two lenses (rows, headcount). A quiet grey track
   with the chosen segment lifted onto white, so the current choice reads at a
   glance without looking like two buttons. Each is a radio group. */
.wp-seg {
  display: inline-flex; align-items: center; gap: 2px; padding: 3px;
  border-radius: 0.625rem; background: var(--kadence-grey-200);
}
.wp-seg + .wp-seg { margin-left: 0.5rem; }
.wp-seg__opt {
  display: inline-flex; align-items: center; gap: 0.375rem;
  height: 1.875rem; padding: 0 0.75rem; border: 0; border-radius: 0.4375rem;
  background: transparent; color: var(--kadence-grey-500);
  font: inherit; font-size: 0.8125rem; font-weight: 600; line-height: 1; white-space: nowrap;
  cursor: pointer; transition: background-color 0.15s ease, color 0.15s ease, box-shadow 0.15s ease;
}
.wp-seg__opt:hover { color: var(--bulma-text-strong); }
.wp-seg__opt.is-active {
  background: var(--bulma-scheme-main); color: var(--bulma-text-strong); cursor: default;
  box-shadow: 0 1px 2px rgba(13, 16, 19, 0.08), 0 1px 3px rgba(13, 16, 19, 0.06);
}
.wp-seg__opt .icon { color: var(--kadence-grey-400); }
.wp-seg__opt.is-active .icon { color: var(--bulma-primary); }
.wp-seg__opt:focus-visible { outline: var(--bulma-focus-width) solid hsl(var(--bulma-focus-h), var(--bulma-focus-s), var(--bulma-focus-l)); outline-offset: 1px; }
.wp-seg__hint {
  font-size: 0.6875rem; font-weight: 600; font-variant-numeric: tabular-nums;
  color: var(--kadence-grey-400);
}
.wp-seg__opt.is-active .wp-seg__hint { color: var(--kadence-grey-500); }

.wp-banner {
  display: flex; align-items: center; gap: 0.625rem;
  padding: 0.4375rem 0.75rem; margin-bottom: 0.625rem; flex-shrink: 0;
  border-radius: var(--bulma-radius-large);
  background: var(--kadence-blue-100);
  font-size: 0.75rem; font-weight: 500; color: var(--kadence-blue-600);
}
.wp-banner--warning { background: var(--kadence-yellow-100); color: var(--kadence-yellow-600); }
.wp-banner a { color: inherit; text-decoration: underline; font-weight: 700; }
.wp-banner__spacer { flex: 1; }
.wp-banner .delete { background: rgba(0,0,0,0.12); }

/* ------------------------------------------------------- staged reveal */

/* The grid is built in two passes, because the workbook itself has two layers.
   Pass one is the floor-day totals — those are the real figures photographed from
   Sandy's sheet, and they are what turn Floor 33 red. Pass two places the teams.
   Landing on both at once buries the capacity finding under fourteen team names.

   Columns reserve their space from the start, so nothing reflows as days arrive
   and the whole week still fits one viewport on the first frame. */
.wp-reveal {
  opacity: 0; transform: translateY(0.25rem);
  transition: opacity 0.28s ease, transform 0.28s ease;
}
.wp-reveal.is-in { opacity: 1; transform: none; }

.wp-grid .wp-bar__seg,
.wp-grid .wp-teams > li {
  opacity: 0;
  transition: opacity 0.3s ease, transform 0.3s ease;
}
.wp-grid .wp-teams > li { transform: scale(0.97); }
.wp-grid.is-teams .wp-bar__seg { opacity: 1; }
.wp-grid.is-teams .wp-teams > li { opacity: 1; transform: none; }

/* Holds the pills' height before they arrive so the reveal does not push the
   ledger around underneath them. */
.wp-teams { min-height: var(--wp-teams-h, 0); }

/* Per-day generation. A day that has not been generated shows its shape but not
   its numbers — there has to be something left for the click to do. */
.wp-cell--ungenerated {
  align-items: stretch; justify-content: center;
  background: repeating-linear-gradient(
    45deg, transparent, transparent 6px,
    var(--bulma-scheme-main-bis) 6px, var(--bulma-scheme-main-bis) 12px);
}
.wp-cell--ungenerated .wp-placeholder {
  border: 1px dashed var(--kadence-grey-300); border-radius: var(--bulma-radius-large);
  background: var(--bulma-scheme-main);
  padding: 0.5rem 0.375rem; text-align: center;
  font-size: 0.625rem; font-weight: 600; color: var(--kadence-grey-350);
}
/* The placeholder is a button: tap to assign teams before the day is generated. */
button.wp-placeholder { width: 100%; font-family: inherit; cursor: pointer; transition: border-color 0.12s ease, color 0.12s ease, background-color 0.12s ease; }
button.wp-placeholder .wp-placeholder__hover { display: none; }
button.wp-placeholder:hover, button.wp-placeholder:focus-visible {
  border-color: var(--kadence-pink-300); border-style: solid; color: var(--kadence-pink-500); background: var(--kadence-pink-50);
}
button.wp-placeholder:hover .wp-placeholder__idle, button.wp-placeholder:focus-visible .wp-placeholder__idle { display: none; }
button.wp-placeholder:hover .wp-placeholder__hover, button.wp-placeholder:focus-visible .wp-placeholder__hover { display: inline; }
button.wp-placeholder:focus-visible { outline: var(--bulma-focus-width) solid hsl(var(--bulma-focus-h), var(--bulma-focus-s), var(--bulma-focus-l)); outline-offset: 1px; }

.wp-gen {
  display: inline-flex; align-items: center; gap: 0.25rem;
  margin-top: 0.1875rem; padding: 0.0625rem 0.4375rem;
  border: 1px solid var(--kadence-pink-200); border-radius: 999px;
  background: var(--kadence-pink-100); color: var(--kadence-pink-600);
  font-size: 0.625rem; font-weight: 700; cursor: pointer; white-space: nowrap;
}
.wp-gen:hover { background: var(--kadence-pink-200); }
.wp-gen[disabled] { opacity: 0.45; cursor: default; }
.wp-gen.is-running { background: var(--kadence-grey-200); border-color: var(--kadence-grey-300); color: var(--kadence-grey-500); }

/* Reasoning lines in the generate modal. Each one is computed, so each one is
   worth reading — colour-coded by what kind of statement it is. */
.wp-reasons { display: flex; flex-direction: column; gap: 0.4375rem; min-height: 12rem; }
.wp-reason {
  display: flex; gap: 0.5rem; align-items: flex-start;
  font-size: 0.8125rem; line-height: 1.45; font-weight: 500; color: var(--bulma-text);
  opacity: 0; transform: translateY(0.1875rem);
  transition: opacity 0.22s ease, transform 0.22s ease;
}
.wp-reason.is-in { opacity: 1; transform: none; }
.wp-reason__dot {
  width: 0.4375rem; height: 0.4375rem; border-radius: 50%; flex-shrink: 0; margin-top: 0.375rem;
  background: var(--kadence-grey-300);
}
.wp-reason--scope .wp-reason__dot { background: var(--kadence-blue-400); }
.wp-reason--constraint .wp-reason__dot { background: var(--kadence-blue-400); }
.wp-reason--continuity .wp-reason__dot { background: var(--kadence-green-400); }
.wp-reason--placement .wp-reason__dot { background: var(--kadence-green-500); }
.wp-reason--finding .wp-reason__dot { background: var(--kadence-red-500); }
.wp-reason--finding { color: var(--kadence-red-600); font-weight: 600; }
.wp-reason--done .wp-reason__dot { background: var(--bulma-primary); }
.wp-reason--done { font-weight: 700; }

.wp-genfoot { display: flex; align-items: center; gap: 0.5rem; font-size: 0.75rem; font-weight: 600; color: var(--bulma-text-weak); }

.wp-import[hidden] { display: none; }
.wp-import {
  flex: 1; display: flex; flex-direction: column;
  align-items: center; justify-content: center; gap: 0.5rem;
  padding: 2rem; text-align: center;
}
.wp-import__title { font-size: 1rem; font-weight: 700; color: var(--bulma-text); }
.wp-import__sub { font-size: 0.8125rem; font-weight: 500; color: var(--bulma-text-weak); max-width: 26rem; line-height: 1.5; }
.wp-import__meta { font-size: 0.6875rem; font-weight: 600; color: var(--kadence-grey-350); }

.wp-progress {
  display: inline-flex; align-items: center; gap: 0.375rem;
  font-size: 0.75rem; font-weight: 600; color: var(--bulma-text-weak);
}
.wp-progress__dots { display: inline-flex; gap: 0.1875rem; }
.wp-progress__dot { width: 0.375rem; height: 0.375rem; border-radius: 50%; background: var(--kadence-grey-300); }
.wp-progress__dot.is-in { background: var(--bulma-primary); }

/* ------------------------------------------------------------- week grid */

.wp-gridwrap {
  flex: 1; min-height: 0; overflow: auto;
  background: var(--bulma-scheme-main);
  border-radius: var(--bulma-radius-large);
  box-shadow: var(--bulma-shadow);
}
/* .wp-grid's display would otherwise beat [hidden] on specificity order. */
.wp-grid[hidden] { display: none; }
.wp-grid {
  display: grid;
  grid-template-columns: 8.5rem repeat(5, minmax(0, 1fr));
  /* Five days must survive first paint at 1440. Anything wider than this and
     Friday falls off the edge, which is the one thing this screen cannot do. */
  min-width: 50rem;
  font-variant-numeric: tabular-nums;
}

.wp-head {
  position: sticky; top: 0; z-index: 3;
  background: var(--bulma-scheme-main);
  border-bottom: 1px solid var(--bulma-border);
  padding: 0.4375rem 0.5rem;
  display: flex; flex-direction: column; align-items: flex-start; gap: 0;
}
.wp-head--corner {
  position: sticky; left: 0; z-index: 4;
  font-size: 0.6875rem; font-weight: 600; color: var(--bulma-text-weak);
}
.wp-head__day { font-size: 0.8125rem; font-weight: 700; color: var(--bulma-text); }
.wp-head__bu { display: block; font-size: 0.625rem; font-weight: 500; color: var(--bulma-text-weak); line-height: 1.3; }
.wp-head__bu--contested { color: var(--kadence-orange-600); font-weight: 600; }

.wp-floorlabel {
  position: sticky; left: 0; z-index: 2;
  background: var(--bulma-scheme-main);
  border-right: 1px solid var(--bulma-border);
  border-bottom: 1px solid var(--bulma-border);
  padding: 0.4375rem 0.5rem;
  text-align: left; cursor: pointer;
  display: flex; flex-direction: column; gap: 0.125rem;
}
.wp-floorlabel:hover { background: var(--kadence-table-hover); }
.wp-floorlabel__top { display: flex; align-items: center; gap: 0.375rem; }
.wp-floorlabel__chev { color: var(--bulma-primary); font-size: 0.625rem; transition: transform 0.15s ease; }
.wp-floorlabel[aria-expanded="true"] .wp-floorlabel__chev { transform: rotate(90deg); }
.wp-floorlabel__name { font-size: 0.875rem; font-weight: 700; color: var(--bulma-text); }
.wp-floorlabel__note { font-size: 0.625rem; font-weight: 500; color: var(--bulma-text-weak); line-height: 1.35; }
.wp-floorlabel__cap {
  display: inline-flex; align-items: center; gap: 0.25rem;
  font-size: 0.6875rem; font-weight: 600; color: var(--bulma-text-weak);
}
.wp-floorlabel__cap wx-icon { color: var(--kadence-grey-350); }

.wp-nbhdlabel {
  position: sticky; left: 0; z-index: 2;
  background: var(--bulma-scheme-main-bis);
  border-right: 1px solid var(--bulma-border);
  border-bottom: 1px solid var(--bulma-border);
  padding: 0.3125rem 0.5rem 0.3125rem 1.5rem;
  display: flex; flex-direction: column; gap: 0.0625rem;
}
.wp-nbhdlabel__name { font-size: 0.75rem; font-weight: 600; color: var(--bulma-text); }
.wp-nbhdlabel__meta { font-size: 0.625rem; font-weight: 500; color: var(--bulma-text-weak); }

.wp-cell {
  border-right: 1px solid var(--bulma-border);
  border-bottom: 1px solid var(--bulma-border);
  padding: 0.4375rem 0.5rem 0.375rem;
  display: flex; flex-direction: column; gap: 0.3125rem;
  min-width: 0;
}
.wp-cell--nbhd { background: var(--bulma-scheme-main-bis); padding-top: 0.3125rem; padding-bottom: 0.3125rem; }

/* Utilisation bar, borrowed from the stack-plan screen: one segment per team in
   that team's colour, grey for the seats still free. When a floor-day is over its
   cap the segments fill the bar and it takes a red rule, because there is no
   honest way to draw 110% of a bar. */
.wp-bar {
  display: flex; height: 0.375rem; border-radius: 999px; overflow: hidden;
  background: var(--kadence-grey-200); flex-shrink: 0;
}
.wp-bar--over { box-shadow: 0 0 0 1px var(--kadence-red-500); }
.wp-bar__seg { height: 100%; min-width: 1px; }

.wp-used { font-size: 0.6875rem; font-weight: 600; color: var(--bulma-text-weak); }
.wp-used b { color: var(--bulma-text); font-weight: 700; }
.wp-used.is-over, .wp-used.is-over b { color: var(--kadence-red-600); }

/* Headroom encoding. The three-state ramp is the same idiom the move manager
   uses for deadline urgency, so it reads as one product. */
.wp-cell--comfortable .wp-ledger__rem { color: var(--kadence-green-600); }
.wp-cell--tight { background: var(--kadence-yellow-100); }
.wp-cell--tight .wp-ledger__rem { color: var(--kadence-yellow-600); }
.wp-cell--over  { background: var(--kadence-red-100); }
.wp-cell--over .wp-ledger__rem { color: var(--kadence-red-600); }

.wp-teams { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 0.1875rem; }
.wp-team {
  display: flex; align-items: center; gap: 0.25rem; width: 100%;
  padding: 0.03125rem 0.3125rem;
  background: var(--bulma-scheme-main);
  border: 1px solid var(--bulma-border);
  border-radius: 999px;
  font-size: 0.6875rem; line-height: 1.5; font-weight: 500;
  color: var(--bulma-text); text-align: left; cursor: pointer;
}
.wp-team:hover { border-color: var(--kadence-pink-300); }
.wp-team__dot { width: 0.375rem; height: 0.375rem; border-radius: 50%; flex-shrink: 0; }
.wp-team__name { flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.wp-team__num {
  flex-shrink: 0; font-size: 0.625rem; font-weight: 600; font-variant-numeric: tabular-nums;
  background: var(--kadence-blue-100); color: var(--kadence-blue-600);
  border-radius: 999px; padding: 0 0.25rem;
}
/* A team on Tue and Thu reads as one team without clicking: hovering any of its
   pills lights every other day it appears on. */
.wp-team.is-linked { border-color: var(--bulma-primary); background: var(--kadence-pink-50); }
.wp-team--empty { border-style: dashed; color: var(--kadence-grey-350); cursor: default; }
.wp-team--empty:hover { border-color: var(--bulma-border); }
/* A team sitting in more than one neighborhood on the same floor. Expand the
   floor to see how it splits. */
.wp-split { font-size: 0.5625rem; font-weight: 700; color: var(--bulma-text-weak); }

.wp-ledger {
  margin-top: auto;
  padding-top: 0.25rem;
  display: grid; grid-template-columns: 1fr auto; gap: 0 0.375rem;
  font-size: 0.625rem; line-height: 1.55;
}
.wp-ledger span { color: var(--kadence-grey-350); font-weight: 500; }
.wp-ledger b { font-weight: 600; color: var(--bulma-text-weak); text-align: right; font-variant-numeric: tabular-nums; }
.wp-ledger__rem { font-weight: 700 !important; }
.wp-ledger__lbl--rem { color: var(--bulma-text-weak) !important; font-weight: 600 !important; }

.wp-tag {
  display: inline-block; padding: 0 0.3125rem; border-radius: 999px;
  font-size: 0.5625rem; font-weight: 700; letter-spacing: 0.02em;
  background: var(--kadence-chip-neutral-bg); color: var(--kadence-chip-neutral-text);
}
.wp-tag--heads-down { background: var(--kadence-blue-100); color: var(--kadence-blue-600); }
.wp-tag--collaborative { background: var(--kadence-orange-100); color: var(--kadence-orange-600); }
.wp-tag--activity-based { background: var(--kadence-green-100); color: var(--kadence-green-600); }

/* ---------------------------------------------------------- side panels */

.wp-shell { flex: 1; min-height: 0; display: flex; gap: 0.75rem; position: relative; }
.wp-main { flex: 1; min-width: 0; display: flex; flex-direction: column; min-height: 0; }

.wp-rail {
  width: 16rem; flex-shrink: 0; display: flex; flex-direction: column; gap: 0.5rem;
  min-height: 0; overflow-y: auto;
}
.wp-card {
  background: var(--bulma-scheme-main);
  border-radius: var(--bulma-radius-large);
  box-shadow: var(--bulma-shadow);
  padding: 0.625rem 0.75rem;
}
.wp-card__title {
  font-size: 0.6875rem; font-weight: 700; text-transform: uppercase;
  letter-spacing: 0.04em; color: var(--bulma-text-weak); margin-bottom: 0.375rem;
}
.wp-item {
  display: block; padding: 0.375rem 0; border-top: 1px solid var(--bulma-border);
  font-size: 0.75rem; color: var(--bulma-text); text-decoration: none;
}
.wp-item:first-of-type { border-top: none; }
.wp-item:hover .wp-item__title { color: var(--bulma-primary); }
.wp-item__title { font-weight: 600; line-height: 1.35; display: block; }
.wp-item__meta { font-size: 0.6875rem; color: var(--bulma-text-weak); font-weight: 500; }

/* --------------------------------------------------------- change request */

.wp-page { flex: 1; min-height: 0; overflow-y: auto; padding-bottom: 1rem; }
.wp-section { margin-bottom: 1rem; }
.wp-section__title { font-size: 0.9375rem; font-weight: 700; color: var(--bulma-text); margin-bottom: 0.375rem; }
.wp-section__sub { font-size: 0.75rem; color: var(--bulma-text-weak); font-weight: 500; margin-bottom: 0.5rem; }

/* Delta chips are the contract between what the planner said and what the engine
   will solve. Editable, and never solved on until confirmed. */
.wp-chips { display: flex; flex-wrap: wrap; gap: 0.375rem; }
.wp-chip {
  display: inline-flex; align-items: center; gap: 0.375rem;
  padding: 0.25rem 0.5rem; border-radius: 999px;
  background: var(--kadence-pink-100); color: var(--kadence-pink-600);
  font-size: 0.75rem; font-weight: 600;
}
.wp-chip__kind {
  font-size: 0.5625rem; text-transform: uppercase; letter-spacing: 0.04em;
  background: var(--bulma-scheme-main); color: var(--kadence-pink-600);
  border-radius: 999px; padding: 0 0.3125rem; font-weight: 700;
}
.wp-chip input.input {
  width: 3.5rem; height: 1.5rem; font-size: 0.75rem; text-align: right;
  border-bottom-color: var(--kadence-pink-400); font-variant-numeric: tabular-nums;
}
.wp-chip .delete { background: rgba(0,0,0,0.14); }
.wp-chip--unconfirmed { background: var(--kadence-grey-200); color: var(--kadence-grey-500); }

/* The solve names what it is evaluating. A spinner with no content invites the
   question this screen exists to answer. */
.wp-solve { display: flex; flex-direction: column; gap: 0.5rem; max-width: 34rem; }
.wp-solve__step {
  display: flex; align-items: center; gap: 0.5rem;
  font-size: 0.8125rem; font-weight: 500; color: var(--kadence-grey-350);
  transition: color 0.2s ease;
}
.wp-solve__step.is-active { color: var(--bulma-text); font-weight: 600; }
.wp-solve__step.is-done { color: var(--bulma-text-weak); }
.wp-solve__dot {
  width: 0.5rem; height: 0.5rem; border-radius: 50%; flex-shrink: 0;
  background: var(--kadence-grey-300);
}
.wp-solve__step.is-active .wp-solve__dot { background: var(--bulma-primary); }
.wp-solve__step.is-done .wp-solve__dot { background: var(--bulma-success); }

.wp-option {
  background: var(--bulma-scheme-main);
  border: 1px solid var(--bulma-border);
  border-radius: var(--bulma-radius-large);
  margin-bottom: 0.625rem; overflow: hidden;
}
.wp-option.is-open { border-color: var(--bulma-primary); }
.wp-option.is-blocked { border-color: var(--kadence-red-400); }
.wp-option__head {
  display: flex; align-items: flex-start; gap: 0.75rem; width: 100%;
  padding: 0.625rem 0.75rem; background: none; border: none; cursor: pointer; text-align: left;
}
.wp-option__head:hover { background: var(--kadence-table-hover); }
.wp-option__rank {
  font-size: 0.6875rem; font-weight: 700; color: var(--bulma-text-weak);
  background: var(--kadence-grey-200); border-radius: 999px;
  padding: 0.0625rem 0.4375rem; flex-shrink: 0; margin-top: 0.125rem;
}
.wp-option__main { flex: 1; min-width: 0; }
.wp-option__label { display: block; font-size: 0.875rem; font-weight: 700; color: var(--bulma-text); }
/* The blast radius sits directly under the label, on its own line. It is the
   first thing a planner reads and the direct answer to "what did you touch?". */
.wp-option__radius { display: block; font-size: 0.75rem; font-weight: 600; color: var(--bulma-text-weak); margin-top: 0.0625rem; }
.wp-option__main .tag { display: inline-block; }
.wp-option__body { padding: 0 0.75rem 0.75rem; border-top: 1px solid var(--bulma-border); }

/* Score chips reuse the segmented-stat idiom from the move manager. */
.wp-scores { display: flex; gap: 0.25rem; flex-shrink: 0; }
.wp-score {
  min-width: 4.25rem; padding: 0.1875rem 0.375rem; border-radius: 0.375rem;
  background: var(--bulma-scheme-main-bis); text-align: center;
}
.wp-score__num { display: block; font-size: 0.9375rem; font-weight: 700; line-height: 1.1; font-variant-numeric: tabular-nums; }
.wp-score__lbl { display: block; font-size: 0.5625rem; font-weight: 600; color: var(--bulma-text-weak); line-height: 1.3; }
.wp-score--good .wp-score__num { color: var(--kadence-green-500); }
.wp-score--mid  .wp-score__num { color: var(--kadence-orange-600); }
.wp-score--poor .wp-score__num { color: var(--kadence-red-600); }

/* Move chains render as chains. A cascaded move sits under the move that forced
   it — that relationship is the answer to "why did my team move?". */
.wp-moves { list-style: none; margin: 0.5rem 0 0; padding: 0; }
.wp-move {
  display: flex; align-items: baseline; gap: 0.5rem;
  padding: 0.3125rem 0; font-size: 0.75rem; border-top: 1px solid var(--bulma-border);
}
.wp-move--cascaded { padding-left: 1.5rem; position: relative; }
.wp-move--cascaded::before {
  content: ""; position: absolute; left: 0.5rem; top: 0; bottom: 50%;
  border-left: 1px solid var(--kadence-grey-300);
  border-bottom: 1px solid var(--kadence-grey-300);
  width: 0.5rem; border-bottom-left-radius: 4px;
}
.wp-move__day {
  font-size: 0.625rem; font-weight: 700; color: var(--bulma-text-weak);
  background: var(--kadence-grey-200); border-radius: 999px; padding: 0 0.375rem; flex-shrink: 0;
}
.wp-move__team { font-weight: 600; color: var(--bulma-text); }
.wp-move__path { color: var(--bulma-text-weak); font-weight: 500; }
.wp-move__cause { font-size: 0.6875rem; color: var(--kadence-orange-600); font-weight: 600; }

.wp-violation {
  display: flex; gap: 0.5rem; align-items: flex-start;
  padding: 0.375rem 0.5rem; border-radius: 0.375rem; margin-top: 0.3125rem;
  font-size: 0.75rem; font-weight: 500; line-height: 1.4;
}
.wp-violation--hard { background: var(--kadence-red-100); color: var(--kadence-red-600); }
.wp-violation--soft { background: var(--kadence-yellow-100); color: var(--kadence-yellow-600); }
.wp-violation--inherited { background: var(--kadence-grey-200); color: var(--kadence-grey-500); }
.wp-violation b { font-weight: 700; }

/* Diff: only the affected floor-days by default, with the full week always one
   click away. Hiding the rest permanently is what destroys trust. */
.wp-diff { width: 100%; font-size: 0.75rem; font-variant-numeric: tabular-nums; }
.wp-diff th {
  text-align: left; font-size: 0.625rem; text-transform: uppercase; letter-spacing: 0.03em;
  color: var(--bulma-text-weak); font-weight: 700; padding: 0.25rem 0.5rem;
  position: sticky; top: 0; background: var(--bulma-scheme-main); z-index: 1;
}
.wp-diff td { padding: 0.1875rem 0.5rem; border-top: 1px solid var(--bulma-border); }
.wp-diff .num { text-align: right; }
.wp-diff tr.is-outside { opacity: 0.5; }
.wp-diff .was { color: var(--bulma-text-weak); text-decoration: line-through; margin-right: 0.25rem; }
.wp-diff .now { font-weight: 700; }
.wp-diff td.is-changed { background: var(--kadence-blue-100); }
.wp-diff td.is-over .now { color: var(--kadence-red-600); }

/* ------------------------------------------------------- drag and drop */

.wp-team[draggable="true"] { cursor: grab; }
.wp-team[draggable="true"]:active { cursor: grabbing; }
.wp-team.is-dragging { opacity: 0.35; border-style: dashed; }

/* Shows where the pill will land, and carries the count it will bring with it.
   pointer-events off so it cannot steal the drag's own enter/leave events. */
.wp-team--ghost {
  pointer-events: none;
  border-style: dashed; border-color: var(--bulma-primary);
  background: var(--kadence-pink-50); color: var(--kadence-pink-600);
}
.wp-team--ghost .wp-team__num { background: var(--kadence-pink-200); color: var(--kadence-pink-600); }

.wp-cell.is-droptarget { box-shadow: inset 0 0 0 2px var(--bulma-primary); }
.wp-cell.is-blocked { box-shadow: inset 0 0 0 2px var(--kadence-red-500); }
.wp-cell.is-blocked .wp-blockreason {
  font-size: 0.5625rem; font-weight: 700; line-height: 1.3;
  color: var(--kadence-red-600);
}
/* A valid target says how much room the drop leaves. */
.wp-cell.is-droptarget .wp-blockreason--fit {
  font-size: 0.5625rem; font-weight: 700; line-height: 1.3;
  color: var(--kadence-green-500);
}

/* Unsaved manual moves. They sit outside the committed pattern until applied, so
   the change-request loop stays the way allocations actually change. */
.wp-editbar {
  display: flex; align-items: center; gap: 0.75rem; flex-shrink: 0;
  margin-top: 0.5rem; padding: 0.4375rem 0.75rem;
  border-radius: var(--bulma-radius-large);
  background: var(--kadence-pink-100); color: var(--kadence-pink-600);
  font-size: 0.75rem; font-weight: 600; white-space: nowrap;
}
.wp-editbar > * { flex-shrink: 0; }
.wp-editbar__spacer { flex: 1 1 auto; min-width: 0.5rem; }
.wp-editbar__list,
.wp-editbar__block {
  flex-shrink: 1; min-width: 0;
  font-weight: 500; overflow: hidden; text-overflow: ellipsis; white-space: nowrap;
}
.wp-editbar__block { font-weight: 700; }
.wp-editbar--blocked { background: var(--kadence-red-100); color: var(--kadence-red-600); }
/* Moves that break a rule can still be applied — the bar says which rule first. */
.wp-editbar--warning { background: var(--kadence-yellow-100); color: var(--kadence-yellow-600); }

/* ---------------------------------------------------- constraints drawer */

.wp-constraint { padding: 0.5rem 0; border-top: 1px solid var(--bulma-border); }
.wp-constraint:first-child { border-top: none; }
.wp-constraint__top { display: flex; align-items: baseline; gap: 0.5rem; }
.wp-constraint__label { font-size: 0.8125rem; font-weight: 600; color: var(--bulma-text); flex: 1; }
.wp-constraint__detail { font-size: 0.75rem; color: var(--bulma-text-weak); margin-top: 0.125rem; line-height: 1.45; }
.wp-constraint__breach { font-size: 0.75rem; color: var(--kadence-red-600); margin-top: 0.1875rem; line-height: 1.4; }
.wp-sev {
  border: none; border-radius: 999px; cursor: pointer;
  font-size: 0.625rem; font-weight: 700; letter-spacing: 0.03em; padding: 0.0625rem 0.5rem;
}
.wp-sev--hard { background: var(--kadence-red-100); color: var(--kadence-red-600); }
.wp-sev--soft { background: var(--kadence-grey-200); color: var(--kadence-grey-500); }

/* --------------------------------------------------------------- review */

.wp-review { max-width: 46rem; margin: 0 auto; }
.wp-review__day { border-top: 1px solid var(--bulma-border); padding: 0.625rem 0; }
.wp-review__daylabel { font-size: 0.8125rem; font-weight: 700; color: var(--bulma-text); margin-bottom: 0.25rem; }
.wp-beforeafter { display: grid; grid-template-columns: 1fr auto 1fr; gap: 0.75rem; align-items: center; }
.wp-ba {
  background: var(--bulma-scheme-main-bis); border-radius: 0.375rem; padding: 0.5rem 0.625rem;
  font-size: 0.75rem;
}
.wp-ba__ttl { font-size: 0.625rem; text-transform: uppercase; letter-spacing: 0.04em; font-weight: 700; color: var(--bulma-text-weak); }
.wp-ba__place { font-weight: 700; color: var(--bulma-text); }
.wp-ba__neighbors { color: var(--bulma-text-weak); font-weight: 500; line-height: 1.45; }
.wp-ba--after { background: var(--kadence-blue-100); }
.wp-ba--after .wp-ba__place { color: var(--kadence-blue-600); }

.wp-empty { padding: 1.25rem; text-align: center; color: var(--bulma-text-weak); font-size: 0.8125rem; }

@media (max-width: 1215px) {
  .wp-rail { display: none; }
}

/* ------------------------------------------------------------- scenarios */

/* Which pattern is open is a fact about the page, not a setting, so the switcher
   sits against the building name rather than in the toolbar. */
.wp-scenariochip {
  display: inline-flex; align-items: center; gap: 0.375rem;
  padding: 0.1875rem 0.5rem; border: 1px solid var(--bulma-border);
  border-radius: 999px; background: var(--bulma-scheme-main);
  font-size: 0.75rem; font-weight: 600; color: var(--bulma-text-weak);
  white-space: nowrap;
}
/* Only the switcher is clickable; the same chip is used as a plain marker on the
   change-request screen, and a pointer there would be a lie. */
button.wp-scenariochip { cursor: pointer; }
button.wp-scenariochip:hover { background: var(--kadence-table-hover); color: var(--bulma-text); }
.wp-scenariochip wx-icon { color: var(--kadence-grey-350); font-size: 0.625rem; }
.wp-scenariochip__dot {
  width: 0.4375rem; height: 0.4375rem; border-radius: 999px; flex-shrink: 0;
  background: var(--kadence-green-600);
}
.wp-scenariochip.is-draft .wp-scenariochip__dot { background: var(--kadence-orange-600); }
/* A draft reads as a draft everywhere it is named. */
.wp-scenariochip.is-draft {
  background: var(--kadence-orange-100); border-color: var(--kadence-orange-100);
  color: var(--kadence-orange-600);
}
.wp-scenariochip.is-draft wx-icon { color: inherit; }

/* The bar is the standing reminder that nothing on screen is live. It takes the
   same shape as the provenance banner because it is the same kind of claim. */
.wp-scenariobar {
  display: flex; align-items: center; gap: 0.625rem;
  padding: 0.3125rem 0.625rem; margin-bottom: 0.375rem; flex-shrink: 0;
  border-radius: var(--bulma-radius-large);
  background: var(--kadence-orange-100);
  font-size: 0.75rem; font-weight: 500; color: var(--kadence-orange-600);
}
.wp-scenariobar__text { flex: 1; min-width: 0; }
.wp-scenariobar__actions { display: flex; gap: 0.375rem; flex-shrink: 0; }

.wp-screlist { display: flex; flex-direction: column; }
.wp-screrow {
  display: flex; flex-direction: column; gap: 0.125rem; width: 100%;
  padding: 0.5rem 0.625rem; text-align: left; cursor: pointer;
  border: 1px solid transparent; border-radius: var(--bulma-radius-large);
  background: transparent;
}
.wp-screrow:hover { background: var(--kadence-table-hover); }
.wp-screrow.is-active { border-color: var(--bulma-primary); background: var(--kadence-table-hover); }
.wp-screrow[disabled] { opacity: 0.55; cursor: default; }
.wp-screrow__name { font-size: 0.8125rem; font-weight: 700; color: var(--bulma-text); }
.wp-screrow__meta { font-size: 0.6875rem; font-weight: 500; color: var(--bulma-text-weak); }

/* Before and after, for the two numbers a planner is held to. Direction is
   coloured, not just shown — fewer breaches is the point of the exercise. */
.wp-stats { display: flex; gap: 0.5rem; flex-wrap: wrap; }
.wp-stat {
  flex: 1; min-width: 9rem;
  padding: 0.5rem 0.625rem; border-radius: var(--bulma-radius-large);
  background: var(--bulma-scheme-main-bis);
}
.wp-stat__label { display: block; font-size: 0.6875rem; font-weight: 600; color: var(--bulma-text-weak); }
.wp-stat__val {
  display: flex; align-items: center; gap: 0.3125rem;
  font-size: 1rem; font-variant-numeric: tabular-nums; color: var(--bulma-text);
}
.wp-stat__val .was { color: var(--bulma-text-weak); font-weight: 600; }
.wp-stat__val wx-icon { color: var(--kadence-grey-350); font-size: 0.625rem; }
.wp-stat.is-better .wp-stat__val b { color: var(--kadence-green-600); }
.wp-stat.is-worse .wp-stat__val b { color: var(--kadence-red-600); }

.wp-publishdate { display: inline-flex; align-items: center; gap: 0.375rem; }
.wp-publishdate label { font-size: 0.75rem; font-weight: 600; color: var(--bulma-text-weak); }
.wp-publishdate input.input { width: 9rem; height: 1.75rem; font-size: 0.8125rem; }

/* --------------------------------------------------- neighborhood lens */

/* In the neighborhood lens the floor stops owning the row and becomes the group
   it still is — permission and capacity live there, the week does not. */
.wp-grouphead {
  grid-column: 1 / -1;
  position: sticky; left: 0;
  display: flex; align-items: baseline; gap: 0.5rem;
  padding: 0.3125rem 0.5rem;
  background: var(--bulma-scheme-main-bis);
  border-bottom: 1px solid var(--bulma-border);
}
.wp-grouphead__name { font-size: 0.8125rem; font-weight: 700; color: var(--bulma-text); }
.wp-grouphead__meta { font-size: 0.6875rem; font-weight: 500; color: var(--bulma-text-weak); }

/* The lens row label is the neighborhood's own identity, so it loses the indent
   it carries when it is nested under a floor. */
.wp-nbhdlabel--lens { padding-left: 0.5rem; background: var(--bulma-scheme-main); }
.wp-nbhdlabel__occ { font-size: 0.625rem; font-weight: 600; color: var(--bulma-text-weak); }
/* A neighborhood more than one team passes through in a week is the case this
   lens exists for. Say so on the row. */
.wp-nbhdlabel__occ.is-shared { color: var(--kadence-orange-600); }
/* A draft chip stays a draft chip on hover — the generic hover would turn it grey
   and lose the one thing the colour is carrying. */
button.wp-scenariochip.is-draft:hover {
  background: var(--kadence-orange-200); color: var(--kadence-orange-600);
}

/* Why a publish is blocked belongs on the screen, not in a tooltip nobody opens. */
.wp-blocked { font-size: 0.75rem; font-weight: 600; color: var(--kadence-red-600); }

/* ------------------------------------------------------------- floor plan */

/* The plan button rides in the corner of a cell and only resolves on hover, so
   five columns of them do not compete with the numbers they sit beside. */
.wp-planbtn {
  position: absolute; top: 0.25rem; right: 0.25rem; z-index: 1;
  width: 1.25rem; height: 1.25rem; padding: 0;
  display: flex; align-items: center; justify-content: center;
  border: none; border-radius: 6px; cursor: pointer;
  background: transparent; color: var(--kadence-grey-350);
  opacity: 0.3; transition: opacity 0.12s ease;
}
.wp-planbtn wx-icon { font-size: 0.625rem; }
/* The assign button sits just left of the plan button. */
.wp-assignbtn { right: 1.5rem; }
.wp-cell[data-floor] { cursor: pointer; }
.wp-cell[data-floor] .wp-team { cursor: grab; }

/* ---------------------------------------------------- assign panel */
.wp-assign__place {
  display: flex; align-items: flex-start; justify-content: space-between; gap: 1rem;
  padding: 0.75rem 0.875rem; margin-bottom: 1rem;
  border-radius: var(--bulma-radius-large); background: var(--bulma-scheme-main-bis); border: 1px solid var(--bulma-border);
}
.wp-assign__placename { font-size: 1rem; font-weight: 700; color: var(--bulma-text-strong); }
.wp-assign__placemeta { font-size: 0.75rem; color: var(--bulma-text-weak); margin-top: 0.125rem; }
.wp-assign__cap { text-align: right; font-size: 0.75rem; color: var(--bulma-text-weak); white-space: nowrap; }
.wp-assign__cap b { font-size: 0.9375rem; color: var(--bulma-text-strong); }
.wp-assign__cap span { font-weight: 700; color: var(--kadence-green-500); }
.wp-assign__cap.is-over span { color: var(--kadence-red-600); }
.wp-assign__h { font-size: 0.6875rem; font-weight: 700; letter-spacing: 0.06em; text-transform: uppercase; color: var(--bulma-text-weak); margin: 0.25rem 0 0.375rem; }
.wp-assign__hrow { display: flex; align-items: center; justify-content: space-between; gap: 0.75rem; margin-top: 0.75rem; }
.wp-assign__search { max-width: 12rem; }
.wp-assign__list { list-style: none; margin: 0 0 0.5rem; padding: 0; }
.wp-assign__row {
  display: flex; align-items: center; gap: 0.625rem; padding: 0.5rem 0.25rem;
  border-top: 1px solid var(--bulma-border);
}
.wp-assign__row:first-child { border-top: none; }
.wp-assign__row .wp-team__dot { flex-shrink: 0; }
.wp-assign__main { display: flex; flex-direction: column; flex: 1 1 auto; min-width: 0; }
.wp-assign__name { font-size: 0.8125rem; font-weight: 600; color: var(--bulma-text-strong); }
.wp-assign__meta { font-size: 0.6875rem; color: var(--bulma-text-weak); }
.wp-assign__note { font-size: 0.6875rem; color: var(--kadence-yellow-600); font-weight: 600; }
.wp-assign__fit { font-size: 0.6875rem; font-weight: 700; white-space: nowrap; }
.wp-assign__fit.is-ok { color: var(--kadence-green-500); }
.wp-assign__fit.is-no { color: var(--kadence-red-600); }
.wp-assign__row.is-nofit .wp-assign__name { color: var(--kadence-grey-400); }
.wp-assign__foot { font-size: 0.6875rem; color: var(--bulma-text-weak); margin-top: 0.75rem; }
.wp-cell { position: relative; }
.wp-cell:hover .wp-planbtn, .wp-planbtn:focus-visible { opacity: 1; }
.wp-planbtn:hover { background: var(--bulma-scheme-main); color: var(--bulma-primary); }

.wp-planmodal .modal-card { --bulma-modal-content-width: 78rem; width: 78rem; max-width: calc(100vw - 3rem); }
.wp-planmodal .modal-card-head { gap: 0.75rem; align-items: center; }
.wp-planmodal .modal-card-title { flex: 0 0 auto; white-space: nowrap; }

.wp-plantabs { display: flex; gap: 0.125rem; padding: 0.125rem; border-radius: 999px; background: var(--bulma-background); }
.wp-plantab {
  border: none; background: transparent; cursor: pointer;
  padding: 0.1875rem 0.5rem; border-radius: 999px;
  font-size: 0.75rem; font-weight: 600; color: var(--bulma-text-weak);
}
.wp-plantab:hover { color: var(--bulma-text); }
.wp-plantab.is-active { background: var(--bulma-scheme-main); color: var(--bulma-text); box-shadow: var(--bulma-shadow); }

.wp-planbody { display: flex; gap: 0.75rem; padding: 0.75rem; min-height: 0; }
/* The plate is roughly 2.9:1. Giving the stage that shape instead of a fixed
   height keeps the plan filling it at any modal width, rather than floating in a
   band of dead space. */
.wp-planstage {
  position: relative; flex: 1; min-width: 0;
  aspect-ratio: 2.8 / 1; max-height: 62vh; min-height: 14rem;
  border-radius: var(--bulma-radius-large);
  background: var(--bulma-scheme-main-bis);
  overflow: hidden;
}
.wp-planhost { width: 100%; height: 100%; }
.wp-planhost svg { width: 100%; height: 100%; cursor: grab; display: block; }
.wp-planmissing { padding: 2rem; font-size: 0.8125rem; color: var(--bulma-text-weak); }

.wp-planzoom {
  position: absolute; top: 0.5rem; right: 0.5rem; z-index: 2;
  border-radius: var(--bulma-radius-large);
  background: var(--bulma-scheme-main); box-shadow: var(--bulma-shadow);
}
.wp-planzoom button {
  width: 1.75rem; height: 1.75rem; border: none; background: transparent;
  cursor: pointer; color: var(--bulma-text); border-radius: var(--bulma-radius-large);
}
.wp-planzoom button:hover { background: var(--bulma-background); }

/* The legend is the grid cell's own content, re-laid for a taller column — same
   neighborhoods, same teams, same numbers, so the two surfaces cannot drift. */
.wp-planlegend { width: 17rem; flex-shrink: 0; overflow-y: auto; }
.wp-planlegend__head {
  display: flex; align-items: baseline; gap: 0.375rem;
  font-size: 0.8125rem; font-weight: 500; color: var(--bulma-text-weak);
  padding: 0 0.25rem 0.5rem;
}
.wp-planlegend__head b { font-size: 1rem; color: var(--bulma-text); }
.wp-planlegend__rem { margin-left: auto; font-weight: 700; color: var(--kadence-green-600); }
.wp-planlegend__rem.is-over { color: var(--kadence-red-600); }

.wp-planzone {
  padding: 0.5rem 0.625rem; margin-bottom: 0.375rem;
  border-radius: var(--bulma-radius-large);
  background: var(--bulma-scheme-main-bis);
}
.wp-planzone.is-over { background: var(--kadence-red-100); }
.wp-planzone__top { display: flex; align-items: baseline; gap: 0.375rem; }
.wp-planzone__name { font-size: 0.8125rem; font-weight: 700; color: var(--bulma-text); }
.wp-planzone__cap { margin-left: auto; font-size: 0.75rem; font-weight: 600; color: var(--bulma-text-weak); font-variant-numeric: tabular-nums; }
.wp-planzone__meta { display: flex; align-items: center; gap: 0.375rem; margin-top: 0.1875rem; }
.wp-planzone__rem { margin-left: auto; font-size: 0.6875rem; font-weight: 700; color: var(--bulma-text-weak); }
.wp-planzone.is-over .wp-planzone__rem { color: var(--kadence-red-600); }
.wp-planzone__empty { margin: 0.375rem 0 0; font-size: 0.6875rem; color: var(--bulma-text-weak); }

.wp-planteams { list-style: none; margin: 0.375rem 0 0; padding: 0; }
.wp-planteams li { display: flex; align-items: center; gap: 0.375rem; padding: 0.0625rem 0; }
.wp-planteams__dot { width: 0.5rem; height: 0.5rem; border-radius: 999px; flex-shrink: 0; }
.wp-planteams__name {
  font-size: 0.75rem; font-weight: 500; color: var(--bulma-text);
  white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
}
.wp-planteams__num { margin-left: auto; font-size: 0.75rem; font-weight: 700; font-variant-numeric: tabular-nums; }

.wp-planfoot { font-size: 0.6875rem; font-weight: 500; color: var(--bulma-text-weak); margin: 0; }
.wp-plantab[disabled] { opacity: 0.35; cursor: default; }
.wp-plantab[disabled]:hover { color: var(--bulma-text-weak); }

/* ------------------------------------------------------------- day editor */

/* The day header is the way into the editor, so it has to look like a control
   without becoming a button the eye trips over on every column. */
.wp-head__edit {
  display: inline-flex; align-items: center; gap: 0.3125rem;
  border: none; background: transparent; cursor: pointer;
  padding: 0; border-radius: 6px; color: inherit;
}
.wp-head__edit wx-icon { color: var(--kadence-grey-350); font-size: 0.5625rem; opacity: 0; transition: opacity 0.12s ease; }
.wp-head__edit:hover wx-icon, .wp-head__edit:focus-visible wx-icon { opacity: 1; }
.wp-head__edit:hover .wp-head__day { color: var(--bulma-primary); }

.wp-dayedit { display: flex; flex-direction: column; gap: 0.75rem; }
.wp-dayedit__floor {
  border: 1px solid var(--bulma-border); border-radius: var(--bulma-radius-large);
  overflow: hidden;
}
.wp-dayedit__floorhead {
  display: flex; align-items: baseline; gap: 0.5rem;
  padding: 0.4375rem 0.625rem;
  background: var(--bulma-scheme-main-bis);
  border-bottom: 1px solid var(--bulma-border);
}
.wp-dayedit__floorname { font-size: 0.8125rem; font-weight: 700; color: var(--bulma-text); }
.wp-dayedit__floorcap {
  margin-left: auto; font-size: 0.6875rem; font-weight: 600;
  color: var(--bulma-text-weak); font-variant-numeric: tabular-nums;
}
.wp-dayedit__floorcap.is-over { color: var(--kadence-red-600); }

.wp-dayedit__nbhd { padding: 0.4375rem 0.625rem; }
.wp-dayedit__nbhd + .wp-dayedit__nbhd { border-top: 1px solid var(--bulma-border); }
.wp-dayedit__nbhd.is-over { background: var(--kadence-red-100); }
.wp-dayedit__nbhdhead { display: flex; align-items: center; gap: 0.375rem; }
.wp-dayedit__nbhdname { font-size: 0.75rem; font-weight: 700; color: var(--bulma-text); }
.wp-dayedit__nbhdcap {
  margin-left: auto; font-size: 0.6875rem; font-weight: 600;
  color: var(--bulma-text-weak); font-variant-numeric: tabular-nums;
}
.wp-dayedit__nbhd.is-over .wp-dayedit__nbhdcap { color: var(--kadence-red-600); }
.wp-dayedit__empty { margin: 0.25rem 0 0; font-size: 0.6875rem; color: var(--bulma-text-weak); font-style: italic; }

.wp-dayedit__teams { list-style: none; margin: 0.375rem 0 0; padding: 0; }
.wp-dayedit__team { display: flex; align-items: center; gap: 0.375rem; padding: 0.125rem 0; }
/* The name is the column that gives way, so it needs to be the one that grows.
   Without flex:1 it collapses to nothing and the row reads as a dot, a number
   and a dropdown with no indication of which team it belongs to. */
.wp-dayedit__teamname {
  flex: 1; min-width: 0;
  font-size: 0.75rem; font-weight: 500; color: var(--bulma-text);
  white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
}
.wp-dayedit__teamnum {
  margin-left: auto; font-size: 0.75rem; font-weight: 700;
  font-variant-numeric: tabular-nums; color: var(--bulma-text);
}
/* The destination picker holds one width whatever is selected, so changing a
   team's neighborhood does not shuffle every row beside it. The width has to be
   on the Bulma .select wrapper, not just the <select> inside it — the wrapper
   grows to fill the row otherwise and squeezes the team name to nothing. */
.wp-dayedit__team .select { flex: 0 0 13rem; width: 13rem; }
.wp-dayedit__team .select select { width: 100%; font-size: 0.6875rem; height: 1.625rem; }

/* Violations sit in the footer beside the action, because they are the reason
   the action is or is not safe. */
.wp-dayedit__status { display: flex; flex-wrap: wrap; gap: 0.375rem; max-width: 22rem; }
.wp-dayedit__ok { font-size: 0.6875rem; font-weight: 600; color: var(--kadence-green-600); }
.wp-dayedit__viol {
  font-size: 0.6875rem; font-weight: 600; padding: 0.0625rem 0.375rem;
  border-radius: 999px;
}
.wp-dayedit__viol--hard { background: var(--kadence-red-100); color: var(--kadence-red-600); }
.wp-dayedit__viol--soft { background: var(--kadence-yellow-100); color: var(--kadence-yellow-600); }
