/* ================= events.html =================
   Events-only vocabulary: family glyphs and markers, year-rhythm grid, list rows, side columns. Colours are role
   tokens (--a-*) so the custom theme applies. Past occurrences are hollow, never faded: faded opacity measured
   1.6-2.9:1, an outline keeps the 3:1 non-text floor (sys_design-system.md section 18). */

.alt-app{
  --ev-weekly:var(--a-blue); --ev-monthly:var(--a-green); --ev-quarterly:var(--a-gold);
  --ev-pub:var(--a-purple); --ev-due:var(--a-amber);
}

/* ---------- type: sized by role like every page (DS-54) ----------
   This page carries no base size of its own. Each class that needs a size declares it; a bare <button> is
   13.33px, so the row buttons take `font:inherit`. Label classes get no size here; they inherit the shared rule. */
.ev-lane, .ev-pill, .ev-row, .ev-up button, .ev-chip-x{ font:inherit; }
.ev-main .a-hint, .a-modal.ev-drawer .a-hint, .a-modal.ev-modal .a-hint{ margin:0; }

/* ---------- the frame: the suite's three columns, with this page's widths ---------- */
.ev-main{ --a-left:260px; --a-right:400px; }
/* The suite keeps three columns down to 1024 (alt-responsive.css), so this page does too; a
   hybrid with the rail under the card took the card's height at 1024x768. Below 1024 the shell
   stacks and the page scrolls; the rail's cards sit side by side. */
@media (min-width:1024px) and (max-width:1279px){
  .ev-main{ --a-left:216px; --a-right:272px; }
}
@media (max-width:1023px){
  .ev-main > .a-right{ display:grid; grid-template-columns:repeat(auto-fit,minmax(260px,1fr)); align-items:start; overflow:visible; }
}
.ev-main > .a-centre{ overflow-y:auto; }
/* ---------- fill the column ----------
   From 1024px the shell is the viewport and each column scrolls itself (sys_design-system.md
   4c), so the centre card is a flex column: fixed header, scrolling body. Year rhythm and List
   scroll within the body; the Month grid stretches. Below 1024 everything stacks. */
@media (min-width:1024px){
  .ev-main > .a-centre{ display:flex; flex-direction:column; overflow:hidden; }
  .ev-centre{ flex:1 1 auto; min-height:0; }
  .ev-body{ flex:1 1 auto; min-height:0; overflow-y:auto; display:flex; flex-direction:column; }
  /* Nothing in the body shrinks below its content: the body scrolls instead. */
  .ev-body > *{ flex:0 0 auto; }
  /* Year rhythm: the grid is the one scroller on both axes, so the sticky month header and lane
       names stay put; the legend sits outside it and is always visible. */
  .ev-body:has(> .ev-scroll){ overflow:hidden; }
  .ev-body > .ev-scroll{ flex:1 1 auto; min-height:0; overflow:auto; }
  .ev-body > .ev-legend{ flex:0 0 auto; }
}
/* The five rail cards are the shared shell (.a-rail-card, alt-rail.css); this is what sits in a card's body.
   The wrapper, not the body, is the flex column: the shell hides a folded body with [hidden]. */
.ev-card-c{ display:flex; flex-direction:column; gap:10px; }
/* A folded card is one header row: the title keeps its size and the peek takes what is left and ellipsizes. */
.ev-main .a-rail-card.collapsed .a-w-fold{ flex:0 0 auto; }
.ev-main .a-w-peek{ flex:0 1 auto; min-width:0; overflow:hidden; text-overflow:ellipsis; white-space:nowrap; }

/* ---------- the left column ---------- */
.ev-teams{ display:flex; flex-wrap:wrap; gap:6px; }
.ev-chip-x{ display:inline-flex; align-items:center; justify-content:center; width:24px; height:24px; margin:-4px -8px -4px 0;
  border:0; border-radius:var(--a-r-sm); background:none; color:inherit; cursor:pointer; }
.ev-chip-x svg{ width:var(--a-glyph-xs); height:var(--a-glyph-xs); }
.ev-chip-x:hover{ background:var(--a-raised); }
.ev-chip-x:focus-visible{ outline:2px solid var(--a-ring); outline-offset:1px; }
.ev-teams .a-chip svg{ width:var(--a-glyph-xs); height:var(--a-glyph-xs); }
.a-modal.ev-drawer .inline-check{ min-height:24px; font-size:var(--a-fs-ctl); line-height:var(--a-lh-ui); }
.a-modal.ev-drawer .inline-check input{ accent-color:var(--a-blue); }

/* ---------- the centre ---------- */
.ev-centre{ display:flex; flex-direction:column; min-width:0; }
.ev-body{ padding:var(--a-3); min-width:0; }
.ev-body > .a-month{ border:1px solid var(--a-line-soft); border-radius:var(--a-r); overflow:hidden; background:var(--a-bg); }

/* ---------- family glyphs: a SHAPE per family, colour from the alias ---------- */
.ev-glyph{ display:inline-block; flex:0 0 auto; background:currentColor; }
.ev-glyph.weekly{ width:5px; height:14px; border-radius:var(--a-r-sm); color:var(--ev-weekly); }
.ev-glyph.monthly{ width:11px; height:11px; border-radius:50%; color:var(--ev-monthly); }
.ev-glyph.quarterly{ width:10px; height:10px; transform:rotate(45deg); border-radius:0; color:var(--ev-quarterly); margin:0 1px; }
.ev-glyph.pub{ width:10px; height:13px; border-radius:0 var(--a-r-sm) 0 0; color:var(--ev-pub); }
.ev-glyph.due{ width:0; height:0; background:transparent; border-left:6px solid transparent; border-right:6px solid transparent; border-top:11px solid var(--ev-due); }
.ev-glyph.ph{ width:11px; height:11px; border-radius:0; background:transparent; border:1.5px dashed var(--a-dim); }

/* ---------- Year rhythm ---------- */
.ev-scroll{ overflow-x:auto; scrollbar-gutter:stable; border:1px solid var(--a-line-soft); border-radius:var(--a-r); background:var(--a-bg); }
.ev-scroll:focus-visible{ outline:2px solid var(--a-ring); outline-offset:2px; }
/* overflow-x:clip, not hidden: a December marker's 24px hit box (.ev-mk::before) hangs ~11px
   past the grid edge and gave a 1920px window a sideways scrollbar. `clip` creates no scroll
   container, so the sticky header, corner and lane names still stick to .ev-scroll. */
/* Two header rows, per the request "Add or Move Quarter above the month": the quarter sits
   above the months it spans. `--ev-hd-h` holds that height; the quarter row is sticky at top,
   the month row just below, and the corner spans both via `grid-row:1 / span 2` in the markup. */
.ev-year{ width:100%; min-width:1040px; display:grid; grid-template-columns:240px repeat(12,minmax(0,1fr));
  grid-template-rows:var(--ev-hd-h) var(--ev-hd-h); --ev-hd-h:26px; overflow-x:clip; }
.ev-year .hd{ position:sticky; z-index:5; padding:0 4px; display:flex; align-items:center; justify-content:center;
  text-align:center; font-size:var(--a-fs-11); font-weight:700; line-height:var(--a-lh-tight); letter-spacing:.03em; color:var(--a-dim);
  background:var(--a-raised); }
.ev-year .hd.q-hd{ top:0; border-bottom:1px solid var(--a-line-soft); }
.ev-year .hd.mo-hd{ top:var(--ev-hd-h); border-bottom:1px solid var(--a-line); }
.ev-year .hd.q{ border-left:2px solid var(--a-line); }
.ev-year .hd.cur{ color:var(--a-blue-text); }
.ev-year .hd.corner{ justify-content:flex-start; text-align:left; padding-left:var(--a-3); top:0; left:0; z-index:6;
  border-bottom:1px solid var(--a-line); }
.ev-grp{ grid-column:1 / -1; position:sticky; left:0; display:flex; align-items:center; gap:10px; padding:12px 12px 6px; border-top:1px solid var(--a-line-soft); }
.ev-grp h3{ margin:0; }
.ev-lane{ position:sticky; left:0; z-index:3; display:flex; align-items:center; gap:9px; padding:7px 10px 7px 12px;
  border:0; border-bottom:1px dashed var(--a-line-soft); border-right:1px solid var(--a-line-soft); background:var(--a-bg); color:var(--a-text); text-align:left; cursor:pointer; }
.ev-lane:hover{ background:var(--a-raised); }
.ev-lane:focus-visible{ outline:2px solid var(--a-ring); outline-offset:-2px; }
.ev-lane .copy{ min-width:0; flex:1 1 auto; }
.ev-lane .t{ display:block; font-size:var(--a-fs-ctl); font-weight:600; line-height:var(--a-lh-ui); overflow:hidden; text-overflow:ellipsis; white-space:nowrap; }
.ev-lane .s{ display:block; font-size:var(--a-fs-11); line-height:var(--a-lh-ui); color:var(--a-dim); overflow:hidden; text-overflow:ellipsis; white-space:nowrap; }
.ev-lane.ph .t{ color:var(--a-dim); }
.ev-cell{ position:relative; min-height:44px; border-bottom:1px dashed var(--a-line-soft); border-left:1px solid var(--a-line-soft); }
.ev-cell.q{ border-left:2px solid var(--a-line); }
/* The past region is a hatch (32% of the faint-text colour), not a flat wash: `--a-raised` is
   lighter than `--a-bg` in dark mode and darker in light (CSS/tokens.css), so a flat tint
   would mute in one theme and brighten the past in the other. The hatch is symmetric in both.
   Done occurrences are muted the same way on `.ev-mk.done` below. */
.ev-cell.past{ background-image:repeating-linear-gradient(135deg, transparent 0 6px, var(--a-line-soft) 6px 7px); /* plain fallback first: an engine without color-mix() drops the whole declaration */
  background-image:repeating-linear-gradient(135deg, transparent 0 6px, color-mix(in srgb, var(--a-faint) 32%, transparent) 6px 7px); }
.ev-ph-hint{ position:absolute; inset:8px 6px; border:1px dashed var(--a-line-soft); border-radius:var(--a-r-sm); }
.ev-mk{ position:absolute; top:50%; transform:translate(-50%,-50%); padding:0; border:0; cursor:pointer; background:currentColor; }
.ev-mk::before{ content:""; position:absolute; left:50%; top:50%; width:24px; height:24px; transform:translate(-50%,-50%); }
.ev-mk.span::before{ width:100%; }
/* 15px apart, so a 24px box would overlap its neighbour: the LANE button (24px+) opens the same
   occurrences — the equivalent-control exception to the 24px target rule. */
.ev-mk.weekly::before{ width:14px; }
.ev-mk:focus-visible{ outline:2px solid var(--a-ring); outline-offset:2px; }
.ev-mk.weekly{ width:5px; height:16px; border-radius:var(--a-r-sm); color:var(--ev-weekly); }
.ev-mk.monthly{ width:12px; height:12px; border-radius:50%; color:var(--ev-monthly); }
.ev-mk.quarterly{ width:14px; height:14px; transform:translate(-50%,-50%) rotate(45deg); border-radius:0; color:var(--ev-quarterly);
  box-shadow:0 0 0 2px var(--a-bg), 0 0 0 3px currentColor; }
.ev-mk.pub{ width:12px; height:16px; border-radius:0 var(--a-r-sm) 0 0; color:var(--ev-pub); }
.ev-mk.due{ width:16px; height:14px; background:transparent; color:var(--ev-due); }
.ev-mk.due svg{ display:block; width:16px; height:14px; fill:currentColor; }
.ev-mk.span{ height:16px; border-radius:var(--a-r-pill); transform:translateY(-50%); color:var(--ev-quarterly); }
/* Past colours are muted by pulling the family colour toward --a-dim, not by opacity (a faded
   marker measured 1.6-2.9:1, under the 3:1 floor, sys_design-system.md §18). An opaque blend
   of two passing tokens stays legible while reading less saturated than an upcoming one. */
.ev-mk.done{ background:transparent;
  box-shadow:inset 0 0 0 2px var(--a-dim); /* plain fallback first: an engine without color-mix() drops the whole declaration */
  box-shadow:inset 0 0 0 2px color-mix(in srgb, currentColor 60%, var(--a-dim) 40%); }
.ev-mk.weekly.done{ width:6px; }
.ev-mk.quarterly.done{
  box-shadow:inset 0 0 0 2px var(--a-dim), 0 0 0 2px var(--a-bg), 0 0 0 3px var(--a-dim);
  box-shadow:inset 0 0 0 2px color-mix(in srgb, currentColor 60%, var(--a-dim) 40%), 0 0 0 2px var(--a-bg), 0 0 0 3px color-mix(in srgb, currentColor 60%, var(--a-dim) 40%); }
.ev-mk.due.done svg{ fill:none; stroke-width:2;
  stroke:var(--a-dim);
  stroke:color-mix(in srgb, currentColor 60%, var(--a-dim) 40%); }
.ev-mk.has-task::after{ content:""; position:absolute; right:-5px; top:-5px; width:7px; height:7px; border-radius:50%;
  background:var(--a-blue-text); border:1.5px solid var(--a-bg); }
.ev-today{ position:absolute; top:0; bottom:0; width:2px; background:var(--a-blue); z-index:2; pointer-events:none; }
.ev-legend{ display:flex; flex-wrap:wrap; align-items:center; gap:14px; margin-top:10px; font-size:var(--a-fs-11); line-height:var(--a-lh-ui); color:var(--a-dim); }
.ev-legend > span{ display:inline-flex; align-items:center; gap:6px; }
.ev-dot{ display:inline-block; width:7px; height:7px; border-radius:50%; background:var(--a-blue-text); }
.ev-today-key{ display:inline-block; width:2px; height:12px; background:var(--a-blue); }

/* ---------- Month: the base grid skeleton (formerly shared from alt-calendar.css) ---------- */
.a-month{ display:grid; grid-template-columns:repeat(7,minmax(0,1fr));
  grid-template-rows:auto; grid-auto-rows:minmax(112px,auto); }
/* Narrow widths take the calendar grid's own rows by value: .a-cg-month is 112 − 16 = 96px at 900px and 64px (dots only) at 640px.
   alt-responsive.css used to set 74px here, which no calendar row matches. */
@media (max-width:900px){ .a-month{ grid-auto-rows:minmax(96px,auto); } }
@media (max-width:640px){ .a-month{ grid-auto-rows:minmax(64px,auto); } }
.a-month-cell{ border-right:1px solid var(--a-line-soft); border-bottom:1px solid var(--a-line-soft);
  padding:4px 0; display:flex; flex-direction:column; gap:3px; min-width:0; }
.a-month-cell.out{ background:color-mix(in srgb, var(--a-bg) 60%, transparent); }
.a-month-cell.today{ background:var(--a-blue-soft); }
.a-month-dow{
  font:600 var(--a-fs-11)/var(--a-lh-ctl) var(--a-display); letter-spacing:.06em; text-transform:uppercase;
  color:var(--a-faint); padding:6px 4px; text-align:center;
}
.a-month-h{ display:flex; justify-content:flex-start; padding:0 6px; }
.a-month-h b{ font-size:var(--a-fs-ctl-sm); font-weight:var(--a-fw-ctl); line-height:var(--a-lh-tight); font-variant-numeric:tabular-nums; color:var(--a-dim); }
.a-month-cell.today .a-month-h b{ color:var(--a-blue-text); }
.a-month-b{ display:flex; flex-direction:column; gap:2px; padding:0 4px; overflow:hidden; }

/* ---------- Month: the calendar grid's geometry (DS-54), by value, not by loading its 48 KB sheet ----------
   Rows are minmax(112px, auto) like .a-cg-month, cells 4px 0 with the same dividers, and a cell grows with its pills (never clips or
   scrolls inside); the card body scrolls when the month is taller than the card. The base .a-month above is that geometry. */
.ev-body .a-month-cell.out .a-month-h b{ color:var(--a-faint); }
.ev-pill{ display:flex; align-items:center; gap:5px; min-height:24px; min-width:0; padding:2px 6px; text-align:left;
  border:1px solid var(--a-line-soft); border-radius:var(--a-r-sm); background:var(--a-raised); color:var(--a-text); font-size:var(--a-fs-11); font-weight:600; line-height:var(--a-lh-tight); cursor:pointer; }
.ev-pill:hover{ background:var(--a-float); border-color:var(--a-line-strong); }
.ev-pill:focus-visible{ outline:2px solid var(--a-ring); outline-offset:1px; }
.ev-pill .l{ min-width:0; overflow:hidden; text-overflow:ellipsis; white-space:nowrap; }
.ev-pill .ev-dot{ margin-left:auto; }
@media (max-width:760px){
  .ev-pill{ justify-content:center; }
  .ev-pill .l{ display:none; }
}

/* ---------- List ---------- */
.ev-list{ display:flex; flex-direction:column; gap:14px; }
.ev-list-grp h3{ margin:0 0 6px; }
/* The surface, the hover and the 3px edge are the shared `.a-row` (alt-tasks.css); this is the grid inside it. The edge is the event's family colour. */
.ev-row{ display:grid; grid-template-columns:54px 16px minmax(0,1fr) auto; gap:10px; align-items:center; width:100%; text-align:left; color:var(--a-text); }
.ev-row.k-weekly{ border-left-color:var(--ev-weekly); }
.ev-row.k-monthly{ border-left-color:var(--ev-monthly); }
.ev-row.k-quarterly{ border-left-color:var(--ev-quarterly); }
.ev-row.k-pub{ border-left-color:var(--ev-pub); }
.ev-row.k-due{ border-left-color:var(--ev-due); }
.ev-row.k-ph{ border-left-color:var(--a-line-strong); }
.ev-date{ display:flex; flex-direction:column; align-items:center; line-height:var(--a-lh-tight); }
.ev-date .a-sec-h{ margin:0; }
.ev-date b{ font-family:var(--a-display); font-weight:600; font-size:var(--a-fs-18); font-variant-numeric:tabular-nums; }
.ev-row .copy{ min-width:0; }
.ev-row .t{ display:block; font-size:var(--a-fs-ctl); font-weight:600; line-height:var(--a-lh-ui); overflow:hidden; text-overflow:ellipsis; white-space:nowrap; }
.ev-row .s{ display:block; font-size:var(--a-fs-11); line-height:var(--a-lh-ui); color:var(--a-dim); overflow:hidden; text-overflow:ellipsis; white-space:nowrap; }
.ev-row .meta{ display:flex; align-items:center; gap:6px; }
@media (max-width:600px){
  .ev-row{ grid-template-columns:44px 14px minmax(0,1fr); }
  .ev-row .meta{ grid-column:3; }
}

/* ---------- the right rail ---------- */
.ev-up{ list-style:none; margin:0; padding:0; display:flex; flex-direction:column; gap:2px; }
.ev-up button{ display:grid; grid-template-columns:52px 14px minmax(0,1fr); gap:8px; align-items:center; width:100%; padding:6px; text-align:left; font-size:var(--a-fs-ctl-sm);
  border:0; border-radius:var(--a-r-sm); background:none; color:var(--a-text); cursor:pointer; }
.ev-up button:hover{ background:var(--a-raised); }
.ev-up button:focus-visible{ outline:2px solid var(--a-ring); outline-offset:-2px; }
.ev-up .d{ font-size:var(--a-fs-11); font-weight:600; color:var(--a-dim); font-variant-numeric:tabular-nums; }
.ev-up .l{ overflow:hidden; text-overflow:ellipsis; white-space:nowrap; }
/* An event task is a task: the row surface and status edge (`.a-row.k-<status>`), stacked. Not pressable as a whole, so it keeps the rest look. */
.ev-task{ flex-direction:column; align-items:stretch; gap:4px; min-height:0; margin-bottom:0; cursor:default; }
.ev-task:hover{ border-color:transparent; background:var(--a-panel); }
.ev-task .t{ font-size:var(--a-fs-ctl); font-weight:600; line-height:var(--a-lh-ui); overflow-wrap:anywhere; }
.ev-task .s{ display:flex; align-items:center; flex-wrap:wrap; gap:6px; font-size:var(--a-fs-11); line-height:var(--a-lh-ui); color:var(--a-dim); }
/* "Go to the task from the board": `margin-left:auto` pushes it to the row's trailing edge
   whatever the chip count. altOpenTaskPreview() (JS/alt/alt-shell.js) is the one route every
   "open this task" control on the Suite uses. */
.ev-task-open{ display:inline-flex; align-items:center; justify-content:center; width:22px; height:22px; margin-left:auto;
  padding:0; border:0; border-radius:var(--a-r-sm); background:none; color:var(--a-dim); cursor:pointer; }
.ev-task-open:hover{ background:var(--a-bg); color:var(--a-text); }
.ev-task-open:focus-visible{ outline:2px solid var(--a-ring); outline-offset:1px; }
/* The inline "Unlink?" confirm on a task card: one question about the card, so no dialog.
   Wraps so Unlink and "Keep the link" stack at 400px; `.a-hint` and `.a-row-actions`
   (alt-components.css) supply text and button spacing. */
.ev-unlink-confirm{ display:flex; flex-direction:column; gap:6px; margin-top:4px; padding-top:8px; border-top:1px solid var(--a-line-soft); }
.ev-unlink-confirm .a-hint{ margin:0; overflow-wrap:anywhere; }
.ev-task-open svg{ width:14px; height:14px; }
.ev-access .a-hint b{ color:var(--a-text); }

/* ---------- the drawer (docked right) and the two dialogs ---------- */
/* The shell is the shared `.a-modal` (14px radius, 1px edge, floating ground, shadow). Docked right, inset so the corners show. */
/* Beside Ask STRIDE it keeps its 460px and moves left of the panel (`--a-modal-reserve`), never widened. */
.a-modal.ev-drawer{ top:var(--a-sp-8); right:var(--a-sp-8); margin-right:var(--a-modal-reserve, 0px); bottom:var(--a-sp-8); left:auto; transform:none; width:min(460px,calc(100% - 16px - var(--a-modal-reserve, 0px))); height:auto; max-height:none; }
.a-modal.ev-modal{ width:min(680px,94vw); height:auto; max-height:88vh; }
.a-modal.ev-modal-sm{ width:min(560px,94vw); max-height:min(700px,88vh); }
/* Header, body, footer and the title are the shared bands (alt-shared-dialogs.css, DS-42/DS-45). The footer wraps so a question can take its width. */
.ev-drawer .a-drawer-f{ padding-bottom:max(var(--a-sp-12), env(safe-area-inset-bottom, 0px)); flex-wrap:wrap; }
.ev-modal .a-drawer-h h2{ flex:1 1 auto; min-width:0; }
.ev-modal .a-drawer-f{ flex-wrap:wrap; }
.ev-type-chip{ display:inline-flex; align-items:center; gap:6px; }
.ev-kv{ display:grid; grid-template-columns:96px minmax(0,1fr); gap:var(--a-2) var(--a-3); align-items:center; margin:0; font-size:var(--a-fs-ctl); line-height:var(--a-lh-ui); }
.ev-kv dd{ margin:0; min-width:0; display:flex; align-items:center; gap:6px; flex-wrap:wrap; }
.ev-occ{ flex:1 1 auto; min-width:0; }
.ev-notes{ margin:0; font-size:var(--a-fs-ctl); line-height:var(--a-lh-ui); color:var(--a-text); white-space:pre-wrap; overflow-wrap:anywhere; }
.ev-sec{ display:flex; flex-direction:column; gap:var(--a-2); }
.ev-sec-h{ display:flex; align-items:center; gap:var(--a-2); }
.ev-sec-h .a-sec-h{ flex:1 1 auto; }
.ev-form-grid{ display:grid; grid-template-columns:1fr 1fr; gap:var(--a-3); }
.ev-form-grid > .full{ grid-column:1 / -1; }
@media (max-width:560px){ .ev-form-grid{ grid-template-columns:1fr; } }
.ev-ranges{ display:flex; flex-direction:column; gap:var(--a-2); }
.ev-range{ display:grid; grid-template-columns:minmax(0,1fr) auto minmax(0,1fr) auto; gap:var(--a-2); align-items:center; }
.ev-radio{ display:flex; flex-wrap:wrap; gap:6px; }
.ev-radio label{ display:inline-flex; align-items:center; gap:6px; height:var(--a-ctl); padding:0 10px; cursor:pointer; font-size:var(--a-fs-ctl); font-weight:400; line-height:var(--a-lh-ui);
  border:1px solid var(--a-line); border-radius:var(--a-r-sm); background:var(--a-bg); }
.ev-radio label:has(input:checked){ border-color:var(--a-blue); background:var(--a-blue-soft); font-weight:600; }
.ev-radio input{ margin:0; accent-color:var(--a-blue); }
.ev-radio label:focus-within{ outline:2px solid var(--a-ring); outline-offset:1px; }
.ev-preview{ display:block; padding:var(--a-2) 10px; font-size:var(--a-fs-ctl-sm); line-height:var(--a-lh-ui); color:var(--a-dim);
  border:1px dashed var(--a-line); border-radius:var(--a-r-sm); background:var(--a-bg); }
.ev-preview b, .ev-strong{ color:var(--a-text); }

/* ---------- the whole-page states ---------- */
.ev-state{ max-width:560px; margin:48px auto; padding:var(--a-2) var(--a-4); }
.ev-state-h{ margin:0; font-family:var(--a-display); font-weight:600; font-size:var(--a-fs-18); line-height:var(--a-lh-tight); color:var(--a-text); }
.ev-state-ico{ width:40px; height:40px; }
.ev-state-ico svg{ width:20px; height:20px; }

/* ---------- Customize docked: the page gives up the pane's width, so the three columns share what is left ----------
   At 1280 the docked pane (440px) left a ~180px centre with the suite's 260/400 rails. The rails narrow to
   what their cards need, and below 1280 the page stacks (as it does under 1024) rather than squeezing the
   centre; the empty state wraps inside whatever width the card has. */
@media (min-width:1280px){
  body.a-cz-docked .ev-main{ --a-left:200px; --a-right:232px; }
}
@media (min-width:1024px) and (max-width:1279px){
  body.a-cz-docked .ev-main{ --a-left:160px; --a-right:200px; }
}
.ev-body > .a-empty{ min-width:0; padding-left:var(--a-3); padding-right:var(--a-3); }
.ev-body > .a-empty .a-empty-a{ flex-wrap:wrap; max-width:100%; }
.ev-body > .a-empty .a-empty-a .a-btn{ max-width:100%; height:auto; min-height:var(--a-ctl); white-space:normal; text-align:center; }
.ev-card-c > .a-btn{ align-self:flex-start; max-width:100%; }

/* ---------- a date changed alone (team_event_occurrences): the mark, the words, Restore ----------
   The mark is a ring in the text colour round the marker or pill, never a colour of its own, so it reads in both themes
   and beside every family colour; the words ("Moved from …", "Cancelled") always come with it. */
.ev-mk.chg{ outline:2px dashed var(--a-text); outline-offset:2px; }
.ev-pill.chg{ border-style:dashed; border-color:var(--a-dim); }
.ev-chg{ display:block; font-size:var(--a-fs-11); font-weight:600; line-height:var(--a-lh-ui); color:var(--a-blue-text); overflow:hidden; text-overflow:ellipsis; white-space:nowrap; }
.ev-chg-dot{ display:inline-block; width:6px; height:6px; margin-left:auto; border-radius:50%; border:1.5px solid var(--a-dim); }
.ev-up button:has(.ev-chg-dot){ grid-template-columns:52px 14px minmax(0,1fr) auto; }
.ev-occ-state{ display:flex; flex-wrap:wrap; align-items:center; gap:6px; flex:1 1 100%; min-width:0; }
.ev-chg-chip{ border-style:dashed; }
.ev-chg-chip.off{ color:var(--a-red); border-color:var(--a-red); background:var(--a-red-soft); }
.ev-occ-state .a-hint.err{ flex:1 1 100%; }

/* ---------- the panel in edit mode (spec events-edit-in-panel-2026-11-12, proposal B) ----------
   One column at the drawer's 460px. #evEdRule (what Repeats decides) is display:contents, so its fields are items of the
   same grid while the wrapper is the one node a Repeats change repaints. The footer is the pinned save bar; a question it
   asks (discard, which dates, the clear count) takes the bar's whole width in place of its buttons. */
.ev-edit{ display:flex; flex-direction:column; gap:12px; min-width:0; }
.ev-drawer .ev-form-grid{ grid-template-columns:minmax(0,1fr); }
.ev-rule{ display:contents; }
.ev-edit-chip{ display:inline-flex; align-items:center; gap:6px; border-color:var(--a-blue); background:var(--a-blue-soft); color:var(--a-blue-text); font-weight:600; }
.ev-occ-edit{ display:flex; flex-direction:column; gap:var(--a-2); padding:10px; border:1px solid var(--a-line); border-radius:var(--a-r); background:var(--a-raised); }
.ev-occ-edit .a-sec-h{ margin:0; }
.ev-drawer .ev-occ-edit .ev-form-grid{ grid-template-columns:minmax(0,1fr) auto; align-items:end; }
.ev-occ-cancel{ height:var(--a-ctl); }
.ev-dirty{ font-size:var(--a-fs-ctl-sm); color:var(--a-dim); }
.ev-foot-err{ flex:1 1 100%; order:-1; }
.ev-ask{ display:flex; flex-direction:column; gap:var(--a-2); flex:1 1 100%; min-width:0; }
.ev-ask-h{ margin:0; font-size:var(--a-fs-ctl); font-weight:600; line-height:var(--a-lh-ui); color:var(--a-text); }
.ev-ask .a-row-actions{ justify-content:flex-end; }
.ev-scope-opts{ display:flex; flex-wrap:wrap; gap:6px; }
.ev-scope-opt{ position:relative; display:flex; flex-direction:column; justify-content:center; gap:2px; flex:1 1 180px; min-width:0; min-height:var(--a-ctl); padding:6px 10px; cursor:pointer;
  font-size:var(--a-fs-ctl); line-height:var(--a-lh-ui); border:1px solid var(--a-line); border-radius:var(--a-r-sm); background:var(--a-bg); }
.ev-scope-opt input{ position:absolute; inset:0; width:100%; height:100%; margin:0; opacity:0; cursor:inherit; }
.ev-scope-opt:has(input:checked){ border-color:var(--a-blue); background:var(--a-blue-soft); }
.ev-scope-opt:has(input:checked) .ev-scope-l{ font-weight:600; }
.ev-scope-opt:focus-within{ outline:2px solid var(--a-ring); outline-offset:1px; }
.ev-scope-opt.off{ cursor:not-allowed; border-style:dashed; background:var(--a-panel); }
.ev-scope-opt.off .ev-scope-l{ color:var(--a-dim); }
.ev-scope-l{ color:var(--a-text); overflow-wrap:anywhere; }
.ev-drawer .a-drawer-f.ev-asking{ background:var(--a-raised); }
@media (max-width:560px){
  .ev-scope-opts{ flex-direction:column; }
  .ev-scope-opt{ flex:0 0 auto; }
}

/* ---------- the task assignee: the drawer's row and its status line (spec event-assignee-2026-11-11) ----------
   Status is always words; the green and amber only add to them. The Which-dates radios stack one per line on a phone. */
.ev-assignee{ display:flex; flex-wrap:wrap; align-items:center; gap:6px 8px; min-width:0; flex:1 1 100%; }
.ev-assignee-status{ flex:1 1 100%; min-width:0; font-size:var(--a-fs-ctl-sm); line-height:var(--a-lh-ui); color:var(--a-dim); overflow-wrap:anywhere; }
.ev-assignee-status.done{ color:var(--a-green); }
.ev-assignee-status.warn{ color:var(--a-amber); }
@media (max-width:560px){
  #evAsgScope.ev-radio{ flex-direction:column; align-items:stretch; }
}

/* ---------- a whole rail hidden ----------
   A shut rail keeps a 34px track holding only the shared .a-pane-tab (CSS/alt/alt-panels.css), as Notes' panes do. These rules
   come AFTER the docked and narrowed width rules and carry `body` so they win at equal specificity. The class is only set
   from 1024 up (evApplyRails), so below it the stacked rails show in full and the Hide control stands down. */
.ev-rail-head{ display:flex; flex:0 0 auto; }
.ev-main > .a-left .ev-rail-head{ justify-content:flex-end; }
.ev-main > .a-right .ev-rail-head{ justify-content:flex-start; }
@media (max-width:1023px){
  .ev-rail-head{ display:none; }
}
body .ev-main.ev-left-off{ --a-left:34px; }
body .ev-main.ev-right-off{ --a-right:34px; }
.ev-main > .a-left.collapsed,
.ev-main > .a-right.collapsed{ overflow:visible; gap:0; padding:0; }
.ev-main > .a-left.collapsed > *:not(.a-pane-tab),
.ev-main > .a-right.collapsed > *:not(.a-pane-tab){ display:none; }
.ev-main > .a-left.collapsed > .a-pane-tab,
.ev-main > .a-right.collapsed > .a-pane-tab{ display:flex; }

