/* =============================================================================
   site.css — Verwolf family site layout pass
   =============================================================================
   Composes verwolf.css's primitives (.vw-shell, .vw-panel, .vw-register, etc.)
   into this site's actual pages. Loaded after verwolf.css in base.html.
   Nothing here introduces new colour — only layout and a few small,
   site-specific components that the house style deliberately left open.
   ========================================================================== */


/* =============================================================================
   SHELL — masthead over one pane, at every screen size
   =============================================================================
   The house style ships a fixed left rail (.vw-shell__rail). We don't use it.
   Navigation is designed twice, on purpose (usability study N1, N2):
     desktop (>= 60rem)  the seven sections across the masthead (.vw-topnav),
                         and a worded Menu button for everything secondary;
     phones and tablets  a bottom bar of four sections and More (.vw-tabbar);
                         More opens the same slide-out menu.

   Deliberately NOT inside a media query — this must override verwolf.css's
   rail-based grid at all widths. Equal specificity, later file wins.
   ========================================================================== */
.vw-shell--drawer {
  grid-template-columns: 1fr;
  grid-template-areas:
    "masthead"
    "pane";
}

/* Auth pages (login, register, password reset) centre their single panel. */
.vw-shell--auth .vw-shell__pane {
  display: flex;
  align-items: flex-start;
  justify-content: center;
  padding-top: var(--vw-s-8);
}
@media (max-width: 60rem) {
  .vw-shell--auth .vw-shell__pane { padding-top: var(--vw-s-6); }
}


/* =============================================================================
   MASTHEAD
   ========================================================================== */

/* Menu button + wordmark, grouped so they stay together on the left. */
.vw-masthead__left {
  display: flex;
  align-items: center;
  gap: var(--vw-s-4);
  min-width: 0;                     /* lets the wordmark truncate, not overflow */
}

.vw-masthead__brand {
  display: flex;
  align-items: baseline;
  gap: var(--vw-s-4);
  text-decoration: none;
  color: inherit;
  min-width: 0;
}
/* The full wordmark, set in the display serif at every screen size — the
   masthead reads the same on a phone as on a desktop. */
.vw-masthead__name {
  font-family: var(--vw-face-display);
  font-size: var(--vw-t-lg);
  font-weight: 600;
  letter-spacing: -0.02em;
  white-space: nowrap;
}


/* =============================================================================
   HAMBURGER BUTTON
   =============================================================================
   Square and bordered to match .vw-btn. The three bars are one element plus
   its two pseudo-elements, which is what lets them animate into an X when the
   menu is open — the button always shows the action it will perform next.
   ========================================================================== */
.vw-burger {
  flex: none;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 2.6rem;
  height: 2.6rem;
  padding: 0;
  border: 1px solid var(--vw-ink);
  border-radius: var(--vw-edge);
  background: transparent;
  cursor: pointer;
  transition: background-color 120ms ease;
}
.vw-burger:hover { background: var(--vw-vellum-deep); }

/* Worded: the bars and the word "Menu", so nobody has to know what three
   lines mean. Desktop only — below 60rem the bottom bar's More does this. */
.vw-burger--worded {
  width: auto;
  gap: var(--vw-s-2);
  padding: 0 var(--vw-s-3);
}
.vw-burger__word {
  font-family: var(--vw-face-label);
  font-size: var(--vw-t-xs);
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.15em;
  color: var(--vw-ink);
}
@media (max-width: 59.99rem) {
  .vw-shell__masthead .vw-burger { display: none; }
}
.vw-burger:active { transform: translateY(1px); }

.vw-burger__bars {
  position: relative;
  display: block;
  width: 1.15rem;
  height: 2px;
  background: var(--vw-ink);
  transition: background-color 160ms ease;
}
.vw-burger__bars::before,
.vw-burger__bars::after {
  content: "";
  position: absolute;
  left: 0;
  width: 100%;
  height: 2px;
  background: var(--vw-ink);
  transition: transform 200ms ease;
}
.vw-burger__bars::before { top: -6px; }
.vw-burger__bars::after  { top: 6px; }

/* Open state: middle bar fades, outer two cross into an X. Driven off
   aria-expanded so the visual state can never disagree with what assistive
   technology is told. */
.vw-burger[aria-expanded="true"] .vw-burger__bars { background: transparent; }
.vw-burger[aria-expanded="true"] .vw-burger__bars::before {
  transform: translateY(6px) rotate(45deg);
}
.vw-burger[aria-expanded="true"] .vw-burger__bars::after {
  transform: translateY(-6px) rotate(-45deg);
}


/* =============================================================================
   MASTHEAD CONTROLS — the pair on the right
   =============================================================================
   Speech bubble then bell: what you'd like to tell the site, then what the site
   is telling you. Both are 2.6rem squares matching the hamburger on the left,
   so the masthead holds three controls of one shape rather than an assortment.

   Kept tight together and treated as one group, so the wordmark between them
   and the burger has the rest of the width to truncate into.
   ========================================================================== */
.vw-masthead__right {
  display: flex;
  align-items: center;
  gap: var(--vw-s-3);
  flex: none;
}

/* The square is shared; only the contents differ. Declared together so the two
   can't drift apart when one is adjusted. */
.vw-say-btn,
.vw-bell {
  position: relative;
  flex: none;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 2.6rem;
  height: 2.6rem;
  padding: 0;
  border: 1px solid var(--vw-ink);
  border-radius: var(--vw-edge);
  background: transparent;
  color: var(--vw-ink);
  text-decoration: none;
  transition: background-color 120ms ease;
}
.vw-say-btn:hover, .vw-bell:hover { background: var(--vw-vellum-deep); }
.vw-say-btn:active, .vw-bell:active { transform: translateY(1px); }

.vw-say-btn svg, .vw-bell svg {
  width: 1.45rem;
  height: 1.45rem;
  display: block;
}


/* =============================================================================
   NOTIFICATION BELL
   =============================================================================
   The square itself is declared above, shared with the speech bubble. What
   follows is only what the bell has and the bubble doesn't: a count.

   The count is a badge notched over the top-right corner rather than a number
   beside the icon: it has to be legible at a glance on a phone without taking
   width the wordmark needs.
   ========================================================================== */
/* Unread: the frame thickens rather than the colour changing. A red-bordered
   control reads as an error on a page where madder already means "removed". */
.vw-bell--unread { border-width: 2px; }

.vw-bell__count {
  position: absolute;
  top: -0.45rem;
  right: -0.45rem;
  min-width: 1.25rem;
  height: 1.25rem;
  padding: 0 0.25rem;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  box-sizing: border-box;

  font-family: var(--vw-face-label);
  font-size: var(--vw-t-xs);
  font-weight: 700;
  line-height: 1;
  letter-spacing: 0;

  color: var(--vw-paper-bright);
  background: var(--vw-madder);
  /* A hairline in the page colour, so the badge stays legible where it
     overlaps the bell's own border. */
  border: 1px solid var(--vw-paper);
  border-radius: 999px;
}


/* -----------------------------------------------------------------------------
   The masthead on a phone
   -----------------------------------------------------------------------------
   THE BAR HAS A HARD MINIMUM WIDTH and it was over it. The wordmark is
   `white-space: nowrap` — correct, a brand should not wrap mid-word — so
   nothing in the bar could shrink, and the whole page scrolled sideways on
   every common phone: 35px over at 390, 65px at 360, 105px at 320.

   Measured, not guessed: with the speech bubble hidden the bar is exactly
   390px. The bell alone (Phase 11) fitted a 390px phone with nothing to spare;
   the speech bubble (Phase 12) is what pushed it over. Neither was ever looked
   at on a phone, and no test can see a horizontal scrollbar.

   So below 30rem everything in the bar gives up a little: the side padding
   halves, the three controls drop from 2.6rem to 2.25rem, the gaps tighten,
   and the wordmark steps down one size. It stays "Verwolf Family" — truncating
   a wordmark to "Verwolf Fam…" would look broken rather than tidy.
   -------------------------------------------------------------------------- */
@media (max-width: 30rem) {
  .vw-shell__masthead {
    padding-inline: var(--vw-s-4);
    gap: var(--vw-s-3);
  }

  .vw-masthead__left { gap: var(--vw-s-3); }
  .vw-masthead__name { font-size: var(--vw-t-md); }

  /* The three stay a matched set — shrinking two of them and leaving the
     hamburger at full size is worse than the overflow was. */
  .vw-burger,
  .vw-say-btn,
  .vw-bell {
    width: 2.25rem;
    height: 2.25rem;
  }
  .vw-say-btn svg, .vw-bell svg { width: 1.2rem; height: 1.2rem; }
  .vw-masthead__right { gap: var(--vw-s-2); }

  /* The count badge pulls in with them, so it stays clear of the viewport
     edge rather than being the thing that reintroduces the overflow. */
  .vw-bell__count {
    top: -0.35rem;
    right: -0.35rem;
    min-width: 1.1rem;
    height: 1.1rem;
  }
}

/* The oldest phones still in use — a 320px iPhone SE. Two more pixels than the
   step above can find, taken from the side padding rather than from the type,
   because a wordmark that shrinks twice starts to look like a mistake. */
@media (max-width: 22rem) {
  .vw-shell__masthead { padding-inline: var(--vw-s-3); }
}


/* -----------------------------------------------------------------------------
   The dashboard greeting on a phone
   -----------------------------------------------------------------------------
   DESIGN-NOTES.md has carried this since 2026-08-01 and nobody could confirm
   it without a phone: "Welcome back, {name}" is a bare <h1>, so it takes the
   display scale's largest step, which is tuned for a full-width page. At 390px
   it broke across THREE lines — "Welcome / back, / Zane" — and pushed
   everything the dashboard is actually for below the fold.

   One step down at phone widths. Two lines is right for a greeting and reads
   as deliberate; three reads as a heading that does not fit.
   -------------------------------------------------------------------------- */
@media (max-width: 30rem) {
  .dash__head > h1 {
    font-size: var(--vw-t-xl);
    line-height: var(--vw-lh-tight);
  }
}


/* =============================================================================
   SECTIONS ACROSS THE MASTHEAD — desktop
   =============================================================================
   A second row inside the masthead rather than squeezed between the wordmark
   and the bell: seven worded links do not fit beside them at 960px, and a
   row of their own means none ever has to be dropped or shortened. The
   current section's underline sits on the masthead's black bar.
   ========================================================================== */
.vw-topnav { display: none; }

@media (min-width: 60rem) {
  .vw-shell--tabbar .vw-shell__masthead {
    flex-wrap: wrap;
    row-gap: var(--vw-s-3);
    padding-bottom: 0;
  }
  .vw-topnav {
    order: 3;
    flex: 1 0 100%;
    display: flex;
    flex-wrap: wrap;
    gap: 0 var(--vw-s-2);
    /* Bleed to the masthead's edges so the hairline runs full width. */
    margin: 0 calc(-1 * var(--vw-s-6));
    padding: 0 calc(var(--vw-s-6) - var(--vw-s-3));
    border-top: 1px solid var(--vw-rule);
  }
  .vw-topnav a {
    display: inline-flex;
    align-items: center;
    min-height: 2.75rem;
    padding: 0 var(--vw-s-3);
    font-family: var(--vw-face-label);
    font-size: var(--vw-t-xs);
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.15em;
    color: var(--vw-ink-soft);
    text-decoration: none;
    border-bottom: 3px solid transparent;
    margin-bottom: -1px;
  }
  .vw-topnav a:hover { color: var(--vw-ink); border-bottom-color: var(--vw-rule-strong); }
  .vw-topnav a[aria-current="page"] {
    color: var(--vw-ink);
    border-bottom-color: var(--vw-madder);
  }
}


/* =============================================================================
   BOTTOM BAR — phones and tablets
   =============================================================================
   Four sections and More, each an icon over its name, every target at least
   44px. Padded for the home indicator on notched phones, and the shell is
   padded by the same height so the last thing on a page is never under it.
   The current item gets a madder bar along its top edge and heavier ink —
   not colour alone.
   ========================================================================== */
:root {
  --vw-tabbar-h: 3.75rem;
  --vw-tabbar-space: calc(var(--vw-tabbar-h) + env(safe-area-inset-bottom, 0px));
}

.vw-tabbar { display: none; }

@media (max-width: 59.99rem) {
  .vw-shell--tabbar { padding-bottom: var(--vw-tabbar-space); }

  .vw-tabbar {
    position: fixed;
    left: 0;
    right: 0;
    bottom: 0;
    z-index: 50;                      /* under the scrim (55) and menu (60) */
    display: grid;
    grid-template-columns: repeat(5, minmax(0, 1fr));
    padding-bottom: env(safe-area-inset-bottom, 0px);
    background: var(--vw-paper);
    border-top: 5px solid var(--vw-rule-black);
    box-shadow: 0 -8px 18px -16px rgba(60, 40, 20, 0.7);
  }

  .vw-tabbar__item {
    position: relative;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 0.2rem;
    min-height: max(44px, var(--vw-tabbar-h));
    min-width: 0;
    padding: var(--vw-s-1) 2px;
    font-family: var(--vw-face-label);
    font-size: var(--vw-t-xs);
    font-weight: 700;
    line-height: 1.1;
    letter-spacing: 0.02em;
    text-align: center;
    color: var(--vw-ink-soft);
    text-decoration: none;
    background: transparent;
    border: 0;
    cursor: pointer;
  }
  .vw-tabbar__item span { max-width: 100%; overflow-wrap: anywhere; }
  .vw-tabbar__item svg {
    width: 1.5rem;
    height: 1.5rem;
    fill: none;
    stroke: currentColor;
    stroke-width: 1.7;
    stroke-linecap: square;
    stroke-linejoin: miter;
  }
  .vw-tabbar__item:hover { color: var(--vw-ink); }
  .vw-tabbar__item:focus-visible { outline-offset: -3px; }

  .vw-tabbar__item[aria-current="page"],
  .vw-tabbar__item.is-within {
    color: var(--vw-ink);
    background: var(--vw-vellum-deep);
  }
  .vw-tabbar__item[aria-current="page"] svg,
  .vw-tabbar__item.is-within svg { stroke-width: 2.2; }
  .vw-tabbar__item[aria-current="page"]::before,
  .vw-tabbar__item.is-within::before {
    content: "";
    position: absolute;
    top: 0;
    left: 18%;
    right: 18%;
    height: 3px;
    background: var(--vw-madder);
  }
}


/* ---- A phone held sideways: the bar becomes a slim rail on the left --------
   Short landscape leaves too little height for a header, a toolbar AND a bottom
   bar. The tabs stand in a column down the left edge instead, icons only (the
   names stay in the page for a screen reader and show as a tooltip), 44px
   targets, clear of the notch. The shell moves right by the rail's width. */
.vw-tabbar__extra, .vw-tabbar__dot { display: none; }
@media (orientation: landscape) and (max-height: 500px) and (max-width: 59.99rem) {
  :root { --vw-rail-w: calc(52px + env(safe-area-inset-left, 0px)); }
  .vw-shell--tabbar { padding-bottom: 0; padding-left: var(--vw-rail-w); }
  .vw-tabbar {
    right: auto;
    top: 0;
    width: var(--vw-rail-w);
    display: flex;
    flex-direction: column;
    justify-content: flex-start;
    overflow-y: auto;
    padding: 0 0 0 env(safe-area-inset-left, 0px);
    border-top: 0;
    border-right: 5px solid var(--vw-rule-black);
    box-shadow: 8px 0 18px -16px rgba(60, 40, 20, 0.7);
  }
  .vw-tabbar__item { flex: 1 0 auto; min-height: 44px; min-width: 44px; padding: var(--vw-s-2) 0; }
  .vw-tabbar__item span {
    position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px;
    overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0;
  }
  .vw-tabbar__item[aria-current="page"]::before,
  .vw-tabbar__item.is-within::before { top: 18%; bottom: 18%; left: 0; right: auto; width: 3px; height: auto; }
  /* No masthead on the tree page here, so its two buttons live in the rail. */
  .vw-shell:has(> .tree-pane) ~ .vw-tabbar .vw-tabbar__extra { display: flex; }
  .vw-shell:has(> .tree-pane) ~ .vw-tabbar .vw-tabbar__dot {
    display: block; position: absolute; top: 8px; right: 8px; width: 10px; height: 10px;
    background: var(--vw-madder); border: 1px solid var(--vw-paper);
  }
  .vw-shell:has(> .tree-pane) .vw-shell__masthead { display: none; }
}


/* =============================================================================
   SLIDE-OUT MENU
   ========================================================================== */

/* Dimmed backdrop. Clicking it closes the menu.
   visibility (not just opacity) matters here: a fully transparent element
   still swallows clicks across the entire page, so it has to be genuinely
   hidden while the menu is closed. */
.vw-drawer-scrim {
  position: fixed;
  inset: 0;
  z-index: 55;
  background: rgba(23, 19, 15, 0.55);
  opacity: 0;
  visibility: hidden;
  transition: opacity 220ms ease, visibility 220ms;
}
.vw-drawer-scrim.is-open {
  opacity: 1;
  visibility: visible;
}

.vw-drawer {
  position: fixed;
  top: 0;
  left: 0;
  bottom: 0;
  z-index: 60;
  width: min(19rem, 82vw);
  display: flex;
  flex-direction: column;
  background: var(--vw-paper);
  /* The house style's heavy black bar, turned on its side as the menu's edge. */
  border-right: 5px solid var(--vw-rule-black);
  box-shadow: var(--vw-lift-3);
  transform: translateX(-100%);
  visibility: hidden;
  transition: transform 220ms ease, visibility 220ms;
}
.vw-drawer.is-open {
  transform: translateX(0);
  visibility: visible;
  /* Visible AT ONCE on opening, not at the end of a 220ms transition: an
     element that is still visibility:hidden cannot take focus, which is why
     focus used to stay on the button behind the menu (usability finding
     #11). Closing keeps the delay, so the menu slides out before hiding. */
  transition: transform 220ms ease, visibility 0s;
}

.vw-drawer__head {
  flex: none;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--vw-s-4);
  padding: var(--vw-s-4) var(--vw-s-4) var(--vw-s-4) var(--vw-s-5);
  border-bottom: 5px solid var(--vw-rule-black);
}

.vw-drawer__close {
  flex: none;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 2.2rem;
  height: 2.2rem;
  font-size: 1.5rem;
  line-height: 1;
  color: var(--vw-ink-soft);
  background: transparent;
  border: 1px solid transparent;
  border-radius: var(--vw-edge);
  cursor: pointer;
}
.vw-drawer__close:hover {
  background: var(--vw-vellum-deep);
  border-color: var(--vw-rule-strong);
  color: var(--vw-ink);
}

/* The scrolling middle section — long menus scroll here, not the page. */
.vw-drawer__body {
  flex: 1 1 auto;
  min-height: 0;
  overflow-y: auto;
  padding: var(--vw-s-4) 0;
}

.vw-drawer__rule  { margin: var(--vw-s-4) var(--vw-s-4); }

/* Reunions, Recipes and Stories, at the top of the menu on phones and
   tablets only — on a desktop they are already across the masthead. */
.vw-drawer__sections { display: flex; flex-direction: column; gap: 2px; }
@media (min-width: 60rem) {
  .vw-drawer__sections { display: none; }
}
/* Fingertip-sized rows on touch. */
@media (pointer: coarse) {
  .vw-drawer .vw-nav a { min-height: 44px; display: flex; align-items: center; }
  .vw-drawer__close { width: 44px; height: 44px; }
}
.vw-drawer__group { display: block; padding: 0 var(--vw-s-4) var(--vw-s-2); }

.vw-drawer__foot {
  flex: none;
  padding: var(--vw-s-4) var(--vw-s-5) var(--vw-s-5);
  border-top: 1px solid var(--vw-rule);
  background: var(--vw-vellum-deep);
}
.vw-drawer__user {
  margin: var(--vw-s-1) 0 var(--vw-s-4);
  font-family: var(--vw-face-display);
  font-size: var(--vw-t-md);
  line-height: var(--vw-lh-snug);
}

/* Menu entry for a section that doesn't exist yet. Looks like a .vw-nav item
   but isn't a link — future phases replace each one with the real thing. */
.vw-nav__soon {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--vw-s-3);
  padding: var(--vw-s-3) var(--vw-s-4);
  font-family: var(--vw-face-label);
  font-size: var(--vw-t-xs);
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.17em;
  color: var(--vw-ink-faint);
  opacity: 0.55;
  border-left: 3px solid transparent;
}

/* Stops the page behind the menu from scrolling while it's open. */
body.vw-menu-open { overflow: hidden; }


/* =============================================================================
   SKIP LINK — hidden until focused by keyboard
   ========================================================================== */
.vw-skip {
  position: absolute;
  left: -9999px;
  z-index: 100;
  padding: var(--vw-s-3) var(--vw-s-4);
  background: var(--vw-delft);
  color: var(--vw-paper-bright);
  font-family: var(--vw-face-label);
  font-size: var(--vw-t-xs);
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.15em;
  text-decoration: none;
}
.vw-skip:focus {
  left: var(--vw-s-4);
  top: var(--vw-s-4);
}


/* =============================================================================
   PAGE COMPONENTS
   ========================================================================== */

/* Dashboard feature tile: a panel that also acts as a link. */
.vw-tile {
  display: flex;
  flex-direction: column;
  gap: var(--vw-s-3);
  min-height: 8.5rem;
  text-decoration: none;
  color: inherit;
}
.vw-tile__head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: var(--vw-s-3);
}

/* =============================================================================
   DASHBOARD LAYOUT
   =============================================================================
   Two columns: a rail running the length of the left side holding the family
   register (and, for staff, invites), with everything else to its right.
   ========================================================================== */
.dash {
  display: grid;
  grid-template-columns: 19rem minmax(0, 1fr);
  gap: var(--vw-s-7);
  align-items: start;
}

.dash__head { grid-column: 1 / -1; }
.dash__head > .vw-bar-stub { margin-bottom: 0; }

/* Sticky so it stays beside the content as the page scrolls, which is what
   makes it read as a full-length rail rather than a panel that scrolls away. */
.dash__rail {
  position: sticky;
  top: 0;
  display: flex;
  flex-direction: column;
  gap: var(--vw-s-5);
  max-height: calc(100dvh - 9rem);
}

/* The register takes whatever height is left and scrolls inside itself, so a
   long member list never stretches the page — the house style's bounded-pane
   rule applied to a sidebar. */
.dash__register {
  display: flex;
  flex-direction: column;
  min-height: 0;
  flex: 1 1 auto;
}
.dash__register-head { padding: var(--vw-s-5) var(--vw-s-5) var(--vw-s-3); }
.dash__register-count {
  margin: var(--vw-s-2) 0 0;
  font-size: var(--vw-t-md);
  line-height: var(--vw-lh-snug);
  font-family: var(--vw-face-display);
}
.dash__register-body {
  flex: 1 1 auto;
  min-height: 0;
  overflow-y: auto;
  scrollbar-gutter: stable;
  padding: 0 var(--vw-s-5) var(--vw-s-5);
}
.dash__invites { flex: none; }

/* -- Time-zone notice: text, and a button to confirm the zone ---------------- */
.dash__tz {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--vw-s-3) var(--vw-s-4);
  flex-wrap: wrap;
}
.dash__tz-text { margin: 0; flex: 1 1 18rem; }
.dash__tz form { margin: 0; }

/* -- Start here card ------------------------------------------------------- */
.dash__start { margin: 0 0 var(--vw-s-5); }
.dash__start-title { margin: 0 0 var(--vw-s-3); font-size: var(--vw-t-lg); }
.dash__start-list { list-style: none; margin: 0 0 var(--vw-s-4); padding: 0; }
.dash__start-step {
  display: flex;
  align-items: center;
  gap: var(--vw-s-3);
  min-height: 2.75rem;
}
.dash__start-mark {
  flex: none;
  width: 1.75rem;
  height: 1.75rem;
  display: grid;
  place-items: center;
  border: 2px solid var(--vw-ink-soft);
  border-radius: 50%;
  font-weight: 700;
  line-height: 1;
}
.dash__start-step.is-done .dash__start-mark {
  background: var(--vw-verdigris);
  border-color: var(--vw-verdigris);
  color: var(--vw-paper-bright);
}
.dash__start-step.is-done a { color: var(--vw-ink-faint); text-decoration: line-through; }
.dash__start-done { color: var(--vw-ink-faint); font-size: var(--vw-t-sm); }
.dash__start form { margin: 0; }

/* -- "See all" links and panel titles: readable size, 44px target ----------- */
.dash__main .whatsnew__more {
  font-size: var(--vw-t-sm);
  color: var(--vw-ink-soft);
  text-decoration: underline;
  display: inline-flex;
  align-items: center;
  min-height: 2.75rem;
}
.dash__main .whatsnew__label.dash__panel-title {
  font-size: var(--vw-t-sm);
  font-weight: 700;
  line-height: var(--vw-lh-snug);
}

/* Phones: the rail is hidden entirely and the register lives in the slide-out
   menu instead (see .vw-drawer__register). Putting a tall sidebar first on a
   narrow screen is exactly the problem that moved navigation into the menu. */
@media (max-width: 60rem) {
  .dash { grid-template-columns: 1fr; gap: var(--vw-s-5); }
  /* On a phone the register still comes first, as it always has. */
  .dash__head { order: 2; }
  .dash__main { order: 3; }
  .dash__rail { display: none; }
}

/* -- Truncated register inside the slide-out menu ---------------------------
   The phone-sized counterpart to the dashboard's left rail. Capped in height
   so it can never push the account section out of reach. */
.vw-drawer__register {
  flex: none;
  padding: var(--vw-s-4) var(--vw-s-5) var(--vw-s-3);
  border-top: 1px solid var(--vw-rule);
}
.vw-drawer__register-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--vw-s-3);
  margin-bottom: var(--vw-s-3);
}
.vw-drawer__members {
  list-style: none;
  margin: 0;
  padding: 0;
  max-height: 11rem;
  overflow-y: auto;
  font-size: var(--vw-t-sm);
}
.vw-drawer__members li {
  padding: var(--vw-s-2) 0;
  border-bottom: 1px solid var(--vw-rule);
  line-height: var(--vw-lh-snug);
}
.vw-drawer__members li:last-child { border-bottom: 0; }
.vw-drawer__all {
  display: flex; align-items: center; min-height: 44px;
  font-size: var(--vw-t-sm); font-weight: 700;
}
/* Fold toggle, same look as the tree page's options chevron. */
.vw-drawer__register-head { gap: var(--vw-s-2); }
.vw-drawer__register-head .vw-label { flex: 1 1 auto; white-space: nowrap; }
.vw-drawer__fold {
  display: inline-flex; align-items: center; justify-content: center;
  flex: none; width: 44px; height: 44px; margin: -0.5rem 0;
  padding: 0; background: transparent; color: var(--vw-ink);
  border: 1px solid var(--vw-ink); cursor: pointer;
}
.vw-drawer__fold[hidden] { display: none; }
.vw-drawer__fold svg { transition: transform 0.15s; }
.vw-drawer__fold[aria-expanded="false"] svg { transform: rotate(180deg); }
.vw-drawer__fold:focus-visible { outline: 3px solid var(--vw-ochre); outline-offset: 2px; }
.vw-drawer__register.is-folded #drawer-members { display: none; }
.vw-drawer__register.is-folded .vw-drawer__register-head { margin-bottom: 0; }
@media (prefers-reduced-motion: reduce) { .vw-drawer__fold svg { transition: none; } }


/* =============================================================================
   DRAFT NOTICE
   =============================================================================
   Shown on the dashboard to someone who left a recipe unfinished. Unfinished
   drafts are deleted after a month, so this carries the countdown — a deletion
   somebody was told about every time they signed in is fair; a silent one
   isn't.

   Dark ink-soft ground with paper-bright text: the one place on the site that
   reverses the palette, which is what makes it read as a notice rather than as
   another panel of the page.
   ========================================================================== */

.draft-notice {
  display: flex;
  align-items: flex-start;
  gap: var(--vw-s-4);
  margin-bottom: var(--vw-s-6);
  padding: var(--vw-s-4) var(--vw-s-5);
  background: var(--vw-ink-soft);
  color: var(--vw-paper-bright);
  border-radius: var(--vw-edge);
  border-left: 5px solid var(--vw-ochre);
  box-shadow: var(--vw-lift-2);
}

.draft-notice__body { flex: 1 1 auto; min-width: 0; }

.draft-notice__title {
  font-family: var(--vw-face-label);
  font-size: var(--vw-t-xs);
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.13em;
  margin: 0 0 var(--vw-s-2);
  color: var(--vw-ochre-wash);
}

.draft-notice__list {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: var(--vw-s-1);
}
.draft-notice__list a {
  color: var(--vw-paper-bright);
  text-decoration: underline;
  text-underline-offset: 3px;
}
.draft-notice__list a:hover { color: var(--vw-ochre-wash); }

.draft-notice__note {
  margin: var(--vw-s-3) 0 0;
  font-size: var(--vw-t-sm);
  /* Lighter than the links but still comfortably readable on the dark ground. */
  color: var(--vw-vellum);
}

.draft-notice__close {
  flex: 0 0 auto;
  background: transparent;
  border: 1px solid transparent;
  border-radius: var(--vw-edge);
  color: var(--vw-vellum);
  font-size: 1.4rem;
  line-height: 1;
  padding: 0.1rem 0.45rem;
  cursor: pointer;
}
.draft-notice__close:hover {
  border-color: var(--vw-vellum-shade);
  color: var(--vw-paper-bright);
}

@media (max-width: 40rem) {
  .draft-notice { padding: var(--vw-s-4); }
}


/* =============================================================================
   TIME ZONE — the notice, the menu line, and the preferences page
   =============================================================================
   Everyone starts on the family's usual zone without being asked, so the site
   says so in two quiet places: once on the dashboard until they answer, and
   permanently at the foot of the slide-out menu. Neither is a banner — this is
   information, not a warning, and it shouldn't compete with the page.
   ========================================================================== */

.tz-note {
  margin: 0 0 var(--vw-s-5);
  padding: var(--vw-s-3) var(--vw-s-4);
  background: var(--vw-delft-wash);
  border-left: 4px solid var(--vw-delft);
  border-radius: var(--vw-edge);
  font-size: var(--vw-t-sm);
  color: var(--vw-ink-soft);
}
.tz-note strong { color: var(--vw-ink); }
.tz-note a { color: var(--vw-delft-deep); }

/* The line under "Signed in as", present on every page. */
.vw-drawer__prefs {
  margin: var(--vw-s-1) 0 var(--vw-s-3);
  color: var(--vw-ink-faint);
}
.vw-drawer__prefs a { color: var(--vw-ink-soft); }
.vw-drawer__prefs a:hover { color: var(--vw-ink); }

/* ---- The preferences page --------------------------------------------------
   Deliberately small. One setting, plenty of air around it, and an explanation
   underneath — because "your time zone" sounds like it might move the event,
   and it doesn't. */
.prefs {
  max-width: 34rem;              /* --vw-measure: this page is mostly prose */
  margin-inline: auto;
}
.prefs__head { margin-bottom: var(--vw-s-6); }
.prefs__head .vw-bar-stub { margin: var(--vw-s-3) 0; }

.prefs__panel .vw-field { margin-bottom: var(--vw-s-4); }
.prefs__note {
  margin: 0 0 var(--vw-s-5);
  padding-top: var(--vw-s-4);
  border-top: 1px solid var(--vw-rule);
}
/* -----------------------------------------------------------------------------
   What the bell tells you
   -----------------------------------------------------------------------------
   A checkbox per kind, grouped as notifications/kinds.py groups them. Each row
   is label above, explanation beneath — the explanation is the point, because
   "Reactions to your words" doesn't tell anybody what they'd stop seeing.
   -------------------------------------------------------------------------- */
.prefs__notify {
  margin: 0 0 var(--vw-s-5);
  padding-top: var(--vw-s-4);
  border-top: 1px solid var(--vw-rule);
}
.prefs__notify-lede { margin: var(--vw-s-1) 0 var(--vw-s-4); }

.prefs__group {
  margin: 0 0 var(--vw-s-4);
  padding: 0;
  border: 0;                       /* the legend does the grouping, not a box */
}
.prefs__group:last-child { margin-bottom: 0; }

.prefs__group-name {
  padding: 0;
  margin-bottom: var(--vw-s-2);
  font-family: var(--vw-face-label);
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--vw-ink-faint);
}

.prefs__switch {
  display: flex;
  align-items: flex-start;
  gap: var(--vw-s-3);
  padding: var(--vw-s-2) 0;
  cursor: pointer;
}
/* The one kind nobody may switch off reads as settled rather than broken:
   still legible, just not actionable. */
.prefs__switch:has(input:disabled) { cursor: default; opacity: 0.75; }

.prefs__switch input {
  flex: none;
  width: 1.05rem;
  height: 1.05rem;
  margin: 0.2rem 0 0;              /* aligns the box with the first line */
  accent-color: var(--vw-delft);
}

.prefs__switch-text {
  display: flex;
  flex-direction: column;
  gap: 0.1rem;
  min-width: 0;
}
.prefs__switch-label {
  font-size: var(--vw-t-base);
  line-height: var(--vw-lh-snug);
}
.prefs__switch-help { color: var(--vw-ink-faint); }

.prefs__buttons {
  display: flex;
  justify-content: flex-end;
  gap: var(--vw-s-3);
}

@media (max-width: 40rem) {
  .prefs__buttons { flex-direction: column-reverse; }
  .prefs__buttons .vw-btn { width: 100%; }
}


/* =============================================================================
   WHAT'S NEW — the dashboard's lead
   =============================================================================
   The newest few of each thing, always. Not "since your last visit": that rule
   renders an empty panel whenever nothing happened, and an empty front page is
   what this family already walked away from once.

   The accent is carried by a left edge and the label colour, using the house
   hues directly. `.vw-label--verdigris` does not exist — only delft, madder and
   ochre do — so this defines its own label rather than depending on a class
   that isn't there.
   ========================================================================== */
.whatsnew {
  border-left: 3px solid var(--vw-delft);
  padding: 0 0 0 var(--vw-s-4);
  margin: 0 0 var(--vw-s-5);
}
.whatsnew--ochre      { border-left-color: var(--vw-ochre); }
.whatsnew--verdigris  { border-left-color: var(--vw-verdigris); }
.whatsnew--madder     { border-left-color: var(--vw-madder); }

.whatsnew__label { color: var(--vw-delft); margin: 0; }
.whatsnew--ochre     .whatsnew__label { color: var(--vw-ochre-ink); }
.whatsnew--verdigris .whatsnew__label { color: var(--vw-verdigris); }
.whatsnew--madder    .whatsnew__label { color: var(--vw-madder); }

.whatsnew__head {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: var(--vw-s-4);
  margin-bottom: var(--vw-s-3);
}
.whatsnew__more {
  font-family: var(--vw-face-label);
  font-size: var(--vw-t-xs);
  letter-spacing: 0.04em;
  color: var(--vw-ink-faint);
  text-decoration: none;
  white-space: nowrap;
}
.whatsnew__more:hover { color: var(--vw-ink); text-decoration: underline; }

/* -- The photograph strip ---------------------------------------------------
   Square thumbnails on one row. `minmax(0, 1fr)` rather than `1fr`, because a
   grid track's default minimum is its content and an image would refuse to
   shrink below its natural width — the trap this project has hit three times. */
.whatsnew__strip {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  grid-template-columns: repeat(6, minmax(0, 1fr));
  gap: var(--vw-s-2);
}
.whatsnew__strip img {
  display: block;
  width: 100%;
  aspect-ratio: 1;
  object-fit: cover;
  background: var(--vw-vellum-shade);
  border: 1px solid var(--vw-vellum-deep);
}
@media (max-width: 40rem) {
  .whatsnew__strip { grid-template-columns: repeat(3, minmax(0, 1fr)); }
}

/* -- The worded panels ------------------------------------------------------ */
.whatsnew__list { list-style: none; margin: 0; padding: 0; }
.whatsnew__list li + li { border-top: 1px solid var(--vw-rule); }
.whatsnew__list a {
  display: block;
  padding: var(--vw-s-2) 0;
  text-decoration: none;
  color: inherit;
}
.whatsnew__list a:hover .whatsnew__who { text-decoration: underline; }
.whatsnew__who {
  display: block;
  font-weight: 600;
  font-size: 0.95rem;
  color: var(--vw-ink);
}
.whatsnew__what {
  display: block;
  font-size: 0.85rem;
  color: var(--vw-ink-faint);
  margin-top: 0.1rem;
}

/* -- Only when the family has put nothing anywhere at all ------------------- */
.whatsnew__none { padding: var(--vw-s-5); }
.whatsnew__none h3 { margin: 0 0 var(--vw-s-2); }
.whatsnew__none-acts {
  display: flex;
  gap: var(--vw-s-3);
  flex-wrap: wrap;
  margin: var(--vw-s-4) 0 0;
}

/* The greeting is a courtesy, not content. It used to take the display scale's
   largest step and most of the first screen with it. */
/* Specific enough to beat `.dash__main > h1` in the phone media query above,
   which was tuned when this was a display-sized heading. The clamp already
   handles narrow screens, so there is nothing left for that rule to fix. */
.dash__head > h1.dash__greeting {
  font-size: clamp(1.5rem, 1.1rem + 1.6vw, 2.1rem);
  line-height: 1.15;
  margin: var(--vw-s-2) 0 var(--vw-s-4);
}


/* =============================================================================
   MESSAGES — spacing under the masthead (markup: templates/_messages.html)
   ========================================================================== */
.vw-messages { margin-bottom: var(--vw-s-6); }


/* =============================================================================
   PRINT — no navigation on paper
   ========================================================================== */
@media print {
  .vw-topnav, .vw-tabbar, .vw-burger, .vw-drawer, .vw-drawer-scrim { display: none !important; }
  .vw-shell--tabbar { padding-bottom: 0; }
}


/* =============================================================================
   ONE CONTENT COLUMN (usability follow-up I1-A)
   =============================================================================
   Each section used to centre its own column at its own width (wall 44rem,
   reunions and recipes 54rem, stories 52rem, staff 58rem, photos 74rem), so a
   page title sat at a different left edge in every section. They now share
   one column: the same width, the same left edge. `.vw-shell__pane >` gives
   these rules the weight to win over the section stylesheets, which load
   after this one and so would otherwise win a tie.
   ========================================================================== */
:root { --vw-column: 66rem; }
.vw-shell__pane > :is(.vw-messages, .dash__tz, .draft-notice, .dash, .wall, .shelf, .gatherings, .gathering-form,
    .invite, .cookbook, .archive, .back, .queue, .modlog, .folk, .prefs, .members) {
  max-width: var(--vw-column);
  margin-inline: auto;
}
/* The wall and stories are reading pages: they keep the shared left edge but
   not the full width, or a post runs to 120 characters a line. */
.vw-shell__pane > :is(.wall, .archive) > * { max-width: 44rem; }


/* =============================================================================
   PHONE HELP — /phone/ page and the small card on Home
   ========================================================================== */
.dash__phone { display: none; margin: 0 0 var(--vw-s-5); }
.dash__phone[hidden] { display: none !important; }
@media (max-width: 59.99rem) {
  .dash__phone { display: block; }
}
@media (display-mode: standalone) {
  .dash__phone { display: none !important; }
}
.dash__phone-title { margin: 0 0 var(--vw-s-2); font-size: var(--vw-t-md); }
.dash__phone-text { margin: 0 0 var(--vw-s-3); }
.dash__phone-acts { display: flex; flex-wrap: wrap; gap: var(--vw-s-3); }
.dash__phone-acts .vw-btn { min-height: 2.75rem; }

.phone { max-width: 44rem; }
.phone__head { margin-bottom: var(--vw-s-5); }
.phone__head .vw-bar-stub { margin: var(--vw-s-3) 0; }
.phone__secs { display: flex; flex-direction: column; gap: var(--vw-s-5); }
.phone__done {
  margin: 0 0 var(--vw-s-5);
  padding: var(--vw-s-4);
  border: 2px solid var(--vw-verdigris);
  font-weight: 700;
}
.phone__sec h2 { margin: 0 0 var(--vw-s-3); font-size: var(--vw-t-lg); }
.phone__steps { margin: 0 0 var(--vw-s-3); padding-left: 1.5rem; }
.phone__steps li { margin-bottom: var(--vw-s-3); padding-left: var(--vw-s-1); }
.phone__icon {
  display: inline-block;
  width: 1.75rem; height: 1.75rem;
  vertical-align: middle;
  margin: 0 0.15rem;
  padding: 0.2rem;
  border: 1px solid var(--vw-ink-soft);
  border-radius: 0.35rem;
  background: var(--vw-paper-bright);
}
.phone__note { margin: 0; color: var(--vw-ink-soft); }
.phone__install { margin: var(--vw-s-3) 0 0; min-height: 2.75rem; }
.phone__get ul { margin: 0; padding-left: 1.5rem; }
.phone__get li { margin-bottom: var(--vw-s-2); }

.help__item { margin: 0 0 var(--vw-s-3); padding: 0; }
.help__item > summary { cursor: pointer; display: flex; align-items: center; min-height: 2.75rem; list-style: none; }
.help__item > summary::-webkit-details-marker { display: none; }
.help__q { padding: var(--vw-s-2) var(--vw-s-4); font-weight: 700; }
.help__q::after, .help__sum::after { content: "+"; margin-left: auto; padding-left: var(--vw-s-3); font-size: 1.4em; line-height: 1; }
.help__item[open] > summary::after { content: "\2212"; }
.help__sum { justify-content: flex-start; width: 100%; box-sizing: border-box; }
.help__body { padding: var(--vw-s-4); }
.help__body > :last-child { margin-bottom: 0; }
.help__sub { margin: var(--vw-s-4) 0 var(--vw-s-2); font-size: var(--vw-t-md); }
.help__h { margin: var(--vw-s-6) 0 var(--vw-s-3); font-size: var(--vw-t-lg); }
.phone__sec.vw-panel { box-shadow: none; }


/* =============================================================================
   FAMILY MEMBERS PAGE (/members/)
   ========================================================================== */
.members .vw-panel { padding: 0; }
.members__list { list-style: none; margin: 0; padding: 0; }
.members__list li {
  display: flex; flex-wrap: wrap; align-items: baseline; gap: var(--vw-s-1) var(--vw-s-3);
  padding: var(--vw-s-3) var(--vw-s-4); border-bottom: 1px solid var(--vw-rule);
}
.members__list li:last-child { border-bottom: 0; }
.members__name { font-family: var(--vw-face-display); font-size: var(--vw-t-md); }
.members__joined { margin-left: auto; color: var(--vw-ink-soft); }
.members__manage { margin: var(--vw-s-5) 0 0; display: flex; flex-wrap: wrap; align-items: center; gap: var(--vw-s-4); }
/* The heading is also the way to the full list, so it still works while the
   list is folded. */
.vw-drawer__register-link { display: inline-flex; align-items: center; min-height: 44px; text-decoration: none; }
.vw-drawer__register-link:hover, .vw-drawer__register-link:focus-visible { text-decoration: underline; }
.members__invited { list-style: none; margin: 0 0 var(--vw-s-5); padding: 0; display: grid; gap: var(--vw-s-2); color: var(--vw-ink-soft); font-style: italic; }
/* In the landscape rail the menu button leads, at the top, rather than sitting
   between the sections and the two masthead buttons (Zane, 2026-11-12). */
@media (orientation: landscape) and (max-height: 500px) and (max-width: 59.99rem) {
  .vw-tabbar > .js-menu-toggle { order: -1; }
}
/* "Reunions & Events" made the seven sections a little too long for a
   1024px window, and Family tree wrapped onto a second row. Tighter spacing
   between 60rem and 75rem keeps them on one line. */
@media (min-width: 60rem) and (max-width: 75rem) {
  .vw-topnav { gap: 0; }
  .vw-topnav a { padding: 0 var(--vw-s-2); letter-spacing: 0.1em; }
}
