/* ============================================================
   Lift Hub · one stylesheet, brand tokens as variables
   ============================================================ */
:root {
  --scarlet: #F30031;
  --crimson: #CD1B2F;
  --plum: #311924;
  --plum-2: #4a3340;
  --plum-3: #6a5260;
  --plum-soft: #d9cfd4;
  --smoke: #f9f9f9;
  --white: #ffffff;
  --line: #e6e0e3;
  --line-2: #efeaec;
  --muted: #5a4a51;
  --tint: #f3eff1;
  --pink: #fff3f5;
  --green: #0f8a4a;
  --green-bg: #dff3e8;
  --green-ink: #0f5e34;
  --amber: #d08a00;
  --amber-bg: #fff3d6;
  --amber-ink: #6b4e00;
  --red: #F30031;
  --red-bg: #fbe0e6;
  --red-ink: #8a0d25;
  --radius: 16px;
  --radius-sm: 10px;
  --font: "Poppins", system-ui, sans-serif;
  --display: "Barlow Condensed", "Poppins", sans-serif;
}

*, *::before, *::after { box-sizing: border-box; }
[hidden] { display: none !important; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  background: var(--smoke);
  color: var(--plum);
  font-family: var(--font);
  font-size: 15px;
  line-height: 1.5;
}
#app { min-height: 100vh; display: flex; flex-direction: column; }
img { max-width: 100%; height: auto; }
a { color: var(--plum); }
a:hover { color: var(--scarlet); }
h1, h2, h3 { margin: 0; line-height: 1.2; }
p { margin: 0; }
button, input, select, textarea { font: inherit; color: inherit; }
:focus-visible { outline: 3px solid var(--scarlet); outline-offset: 2px; }

.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.skip-link { position: absolute; left: 12px; top: -60px; background: var(--plum); color: var(--white); padding: 10px 14px; border-radius: 8px; z-index: 100; }
.skip-link:focus { top: 12px; color: var(--white); }
.wrap { max-width: 1280px; margin: 0 auto; padding-left: 32px; padding-right: 32px; width: 100%; }
.page-pad { padding-top: 32px; padding-bottom: 56px; }
.site-main { flex: 1; outline: none; }
.muted { color: var(--muted); }
.small { font-size: 13px; }
.loading { color: var(--muted); }
.icon { display: inline-flex; vertical-align: -2px; }
.stack { display: flex; flex-direction: column; gap: 24px; min-width: 0; }
.split { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 24px; align-items: start; }
.grid-2 { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; }
.grid-3 { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 12px; }

/* ---------- display type ---------- */
.display, .display-dark, .display-md {
  font-family: var(--display); font-weight: 700; text-transform: uppercase; line-height: 1; letter-spacing: 0.01em;
}
.display { font-size: 56px; color: var(--white); }
.display-dark { font-size: 52px; color: var(--plum); }
.display-md { font-size: 34px; }
.eyebrow { font-size: 12px; font-weight: 600; letter-spacing: 0.1em; text-transform: uppercase; color: var(--scarlet); margin-bottom: 8px; }
.section-title { font-size: 20px; font-weight: 700; margin-bottom: 12px; }

/* ---------- buttons ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  border: 0; border-radius: var(--radius-sm); padding: 12px 18px; min-height: 44px;
  font-size: 14px; font-weight: 600; text-decoration: none; cursor: pointer; white-space: nowrap;
}
.btn:disabled { opacity: 0.6; cursor: progress; }
.btn-red { background: var(--scarlet); color: var(--white); }
.btn-red:hover, .btn-red:active { background: var(--crimson); color: var(--white); }
.btn-plum { background: var(--plum-2); color: var(--white); }
.btn-plum:hover { background: var(--plum-3); color: var(--white); }
.btn-dark { background: var(--plum); color: var(--white); }
.btn-dark:hover { background: var(--plum-2); color: var(--white); }
.btn-ghost { background: var(--white); color: var(--plum); border: 1px solid var(--line); }
.btn-ghost:hover { border-color: var(--plum); color: var(--plum); }
.btn-ghost-dark { background: transparent; color: var(--white); border: 1px solid var(--plum-3); }
.btn-ghost-dark:hover { border-color: var(--white); color: var(--white); }
.btn-small { padding: 8px 14px; min-height: 38px; font-size: 13px; }
.btn-block { width: 100%; }
.link-button {
  background: none; border: 0; padding: 4px 0; font-size: 13px; font-weight: 600; color: var(--scarlet);
  cursor: pointer; text-decoration: underline; text-underline-offset: 3px;
}
.link-button:hover { color: var(--crimson); }
.link-button.on-dark { color: var(--white); }
.link-button.danger { color: var(--red-ink); }
.link-button.on-dark.danger { color: #ffb3c2; }

/* ---------- forms ---------- */
.field { display: flex; flex-direction: column; gap: 4px; min-width: 0; }
.field > span, .field > label, .field-label { font-size: 12px; font-weight: 600; color: var(--muted); }
.field input, .field select, .field textarea, .search-box input {
  width: 100%; border: 1px solid #d9d1d5; background: var(--white); border-radius: 8px;
  padding: 10px 12px; font-size: 14px; min-height: 42px;
}
.field textarea { resize: vertical; line-height: 1.45; }
.field input[readonly] { background: var(--tint); }
.hint { font-size: 12px; color: var(--muted); font-weight: 400; }
.check { display: inline-flex; align-items: center; gap: 8px; font-size: 14px; cursor: pointer; }
.check input { width: 18px; height: 18px; accent-color: var(--scarlet); }
.row-actions { display: flex; flex-wrap: wrap; gap: 10px; align-items: center; }
.notice { padding: 10px 12px; border-radius: 8px; font-size: 13px; margin: 8px 0; }
.notice-error { background: var(--red-bg); color: var(--red-ink); }
.notice-ok { background: var(--green-bg); color: var(--green-ink); }

/* ---------- header ---------- */
.site-header { background: var(--white); border-bottom: 1px solid var(--line); position: relative; z-index: 20; }
.header-row { min-height: 68px; display: flex; align-items: center; gap: 20px; }
.brand { display: flex; align-items: center; flex: none; }
.brand img { height: 34px; width: auto; }
.menu-button { display: none; }
.nav-list { list-style: none; margin: 0; padding: 0; display: flex; gap: 2px; }
.nav-item { position: relative; }
.nav-row { display: flex; align-items: center; }
.nav-label {
  display: block; padding: 22px 6px 21px 12px; border-bottom: 3px solid transparent;
  font-size: 14px; font-weight: 500; text-decoration: none; white-space: nowrap;
}
.nav-item:not(.has-menu) .nav-label { padding-right: 12px; }
.nav-label.is-active { border-bottom-color: var(--scarlet); font-weight: 600; }
.nav-toggle {
  border: 0; background: none; padding: 6px 6px; margin-right: 4px; cursor: pointer; color: var(--muted);
  border-radius: 6px; display: flex; align-items: center;
}
.nav-toggle:hover { color: var(--scarlet); background: var(--tint); }
.nav-item.is-open .nav-toggle .icon { transform: rotate(180deg); }
.menu {
  display: none; position: absolute; top: 100%; left: 0; min-width: 250px; margin-top: -1px;
  background: var(--white); border: 1px solid var(--line); border-radius: 0 0 12px 12px;
  box-shadow: 0 16px 32px rgba(49, 25, 36, 0.12); padding: 10px;
}
.nav-item.is-open .menu { display: block; }
@media (hover: hover) and (min-width: 961px) {
  .nav-item.has-menu:hover .menu { display: block; }
}
.menu-head { font-size: 11px; font-weight: 600; letter-spacing: 0.1em; text-transform: uppercase; color: var(--muted); padding: 6px 10px 8px; }
.menu-item {
  display: flex; justify-content: space-between; align-items: center; gap: 12px; width: 100%;
  padding: 10px; border-radius: 8px; text-decoration: none; font-size: 14px; font-weight: 500;
  background: none; border: 0; text-align: left; cursor: pointer;
}
.menu-item:hover, .menu-item:focus-visible { background: var(--tint); color: var(--plum); }
.menu-item.is-soon { color: var(--muted); }
.soon-tag { font-size: 11px; font-weight: 600; color: var(--muted); background: var(--tint); padding: 2px 8px; border-radius: 999px; white-space: nowrap; }

.header-tools { flex: 1 1 auto; display: flex; justify-content: flex-end; align-items: center; gap: 14px; min-width: 0; }
.search { position: relative; width: 100%; max-width: 300px; }
.search-box { display: flex; align-items: center; gap: 8px; background: var(--tint); border-radius: var(--radius-sm); padding: 0 12px; color: var(--muted); }
.search-box input { border: 0; background: transparent; padding: 9px 0; min-height: 40px; font-size: 13px; outline: none; }
.search-box:focus-within { outline: 3px solid var(--scarlet); outline-offset: 1px; }
.search-wide { max-width: 520px; background: var(--white); border: 1px solid var(--line); margin-top: 20px; }
.search-results {
  position: absolute; top: calc(100% + 6px); right: 0; width: min(420px, 90vw); list-style: none; margin: 0; padding: 6px;
  background: var(--white); border: 1px solid var(--line); border-radius: 12px; box-shadow: 0 16px 32px rgba(49, 25, 36, 0.14); z-index: 30;
}
.search-result a { display: flex; flex-direction: column; padding: 8px 10px; border-radius: 8px; text-decoration: none; }
.search-result a:hover, .search-result.is-active a { background: var(--tint); color: var(--plum); }
.sr-kind { font-size: 11px; font-weight: 600; color: var(--scarlet); text-transform: uppercase; letter-spacing: 0.06em; }
.sr-title { font-size: 14px; font-weight: 500; }
.search-empty { padding: 10px; font-size: 13px; color: var(--muted); }

.avatar-wrap { position: relative; flex: none; }
.avatar {
  width: 40px; height: 40px; border-radius: 50%; border: 0; cursor: pointer;
  background: var(--plum); color: var(--white); font-size: 13px; font-weight: 600;
}
.avatar-menu {
  position: absolute; right: 0; top: calc(100% + 8px); width: 260px; background: var(--white);
  border: 1px solid var(--line); border-radius: 12px; box-shadow: 0 16px 32px rgba(49, 25, 36, 0.14); padding: 8px; z-index: 30;
}
.avatar-name { padding: 8px 10px 10px; font-weight: 600; font-size: 14px; border-bottom: 1px solid var(--line-2); margin-bottom: 6px; }
.avatar-name span { display: block; font-weight: 400; font-size: 12px; color: var(--muted); overflow-wrap: anywhere; }

/* ---------- footer ---------- */
.site-footer { border-top: 1px solid var(--line); background: var(--white); }
.footer-row { padding-top: 20px; padding-bottom: 20px; display: flex; flex-wrap: wrap; justify-content: space-between; gap: 12px; font-size: 12px; color: var(--muted); }
.demo-flag { position: fixed; bottom: 12px; left: 12px; background: var(--amber-bg); color: var(--amber-ink); font-size: 12px; font-weight: 600; padding: 6px 12px; border-radius: 999px; z-index: 50; }

/* ---------- gate ---------- */
.gate { min-height: 100vh; display: flex; align-items: center; justify-content: center; padding: 24px 16px; background: var(--plum); }
.gate-card { background: var(--white); border-radius: var(--radius); padding: 36px 32px; width: 100%; max-width: 420px; display: flex; flex-direction: column; gap: 16px; }
.gate-logo { height: 40px; width: auto; align-self: flex-start; }
.gate-title { font-family: var(--display); text-transform: uppercase; font-size: 44px; line-height: 1; }
.gate-email { display: flex; flex-direction: column; gap: 8px; }
.gate-email label { font-size: 12px; font-weight: 600; color: var(--muted); }
.gate-email input { border: 1px solid #d9d1d5; border-radius: 8px; padding: 10px 12px; min-height: 44px; }
.gate .link-button { align-self: flex-start; }

/* ---------- cards ---------- */
.card { background: var(--white); border: 1px solid var(--line); border-radius: var(--radius); padding: 24px 26px; display: flex; flex-direction: column; gap: 16px; min-width: 0; }
.card-head { display: flex; justify-content: space-between; align-items: center; gap: 12px; flex-wrap: wrap; }
.card-head h2 { font-size: 18px; font-weight: 700; }
.card-title-sm { font-size: 16px; font-weight: 700; }
.card-link { font-size: 13px; font-weight: 600; color: var(--scarlet); text-decoration: none; }
.card-dark { background: var(--plum); color: var(--white); border-color: var(--plum); }

/* ---------- home ---------- */
.hero { background: var(--plum); color: var(--white); }
.hero-inner { padding-top: 44px; padding-bottom: 40px; display: flex; flex-direction: column; gap: 28px; }
.hero-top { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: flex-end; gap: 20px; }
.hero-text { display: flex; flex-direction: column; gap: 6px; }
.hero-date, .hero-summary { font-size: 15px; color: var(--plum-soft); }
.hero-actions { display: flex; flex-wrap: wrap; gap: 10px; }
.values { display: flex; flex-wrap: wrap; gap: 10px; align-items: center; }
.values-label { font-size: 12px; font-weight: 600; letter-spacing: 0.1em; text-transform: uppercase; color: var(--plum-soft); padding: 8px 4px 8px 0; }
.value-pill { font-size: 13px; font-weight: 500; padding: 8px 14px; border-radius: 999px; border: 1px solid var(--plum-3); }

.rocks-band { background: var(--white); border-bottom: 1px solid var(--line); }
.rocks-inner { padding-top: 26px; padding-bottom: 26px; display: flex; flex-wrap: wrap; align-items: center; gap: 14px 24px; }
.rocks-head { display: flex; align-items: baseline; gap: 12px; flex-wrap: wrap; }
.rocks-copy { flex: 1 1 280px; color: var(--muted); font-size: 14px; }

.home-grid { display: grid; grid-template-columns: minmax(0, 1fr) 360px; gap: 24px; padding-top: 36px; padding-bottom: 56px; align-items: start; }
.home-main, .home-aside { display: flex; flex-direction: column; gap: 24px; min-width: 0; }

.ann-list { display: flex; flex-direction: column; gap: 12px; }
.ann { padding: 14px 16px; background: var(--smoke); border-radius: var(--radius-sm); display: flex; flex-direction: column; gap: 4px; }
.ann.is-pinned { background: var(--pink); border-left: 4px solid var(--scarlet); }
.ann-title { font-size: 15px; font-weight: 600; }
.ann-body { font-size: 14px; color: var(--muted); line-height: 1.55; }
.ann-meta { display: flex; justify-content: space-between; flex-wrap: wrap; gap: 8px; font-size: 12px; color: var(--muted); margin-top: 4px; }
.ann-actions { display: flex; gap: 14px; }
.ann-form { display: flex; flex-direction: column; gap: 10px; padding: 16px; border: 1px solid var(--line); border-radius: var(--radius-sm); background: var(--smoke); }

.shoots { display: grid; grid-template-columns: repeat(auto-fill, minmax(200px, 1fr)); gap: 14px; }
.shoots > p { grid-column: 1 / -1; }
.shoot { border: 1px solid var(--line); border-radius: 12px; padding: 16px; display: flex; flex-direction: column; gap: 6px; }
.shoot-day { font-size: 12px; font-weight: 600; color: var(--crimson); text-transform: uppercase; letter-spacing: 0.06em; }
.shoot-title { font-size: 15px; font-weight: 600; line-height: 1.3; }
.shoot-line { font-size: 13px; color: var(--muted); }
.shoot-link { font-size: 13px; font-weight: 600; }

.team-list, .coming-list, .directory { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 10px; }
.person { display: flex; align-items: center; gap: 12px; font-size: 14px; }
.avatar-sm { flex: none; width: 34px; height: 34px; border-radius: 50%; background: #e9e4e6; display: flex; align-items: center; justify-content: center; font-size: 12px; font-weight: 600; }
.person-text { display: flex; flex-direction: column; min-width: 0; }
.person-name { font-weight: 600; }
.person-line { font-size: 12px; color: var(--muted); }
.coming-list li { font-size: 13px; color: var(--muted); }
.coming-list strong { color: var(--plum); font-weight: 600; }

/* ---------- Lift Time card ---------- */
.timecard { padding: 22px 24px; gap: 14px; scroll-margin-top: 16px; }
.tc-head { display: flex; justify-content: space-between; align-items: center; gap: 10px; }
.tc-title { font-size: 16px; font-weight: 700; }
.tc-day {
  background: var(--plum-2); color: var(--white); border: 1px solid var(--plum-3); border-radius: 999px;
  font-size: 12px; font-weight: 600; padding: 6px 10px; max-width: 170px; cursor: pointer;
}
.tc-nudge p { font-size: 13px; color: var(--plum-soft); background: var(--plum-2); border-radius: 8px; padding: 8px 12px; }
.tc-list { display: flex; flex-direction: column; gap: 8px; }
.tc-empty { font-size: 13px; color: var(--plum-soft); }
.tc-entry {
  display: flex; justify-content: space-between; align-items: center; gap: 10px; width: 100%; text-align: left;
  padding: 10px 12px; background: var(--plum-2); border: 1px solid transparent; border-radius: var(--radius-sm); color: var(--white); cursor: pointer;
}
.tc-entry:hover { border-color: var(--plum-3); }
.tc-entry-main { display: flex; flex-direction: column; gap: 1px; min-width: 0; }
.tc-entry-job { font-size: 13px; font-weight: 600; }
.tc-entry-sub { font-size: 12px; color: var(--plum-soft); overflow-wrap: anywhere; }
.tc-entry-hours { font-weight: 700; font-size: 15px; flex: none; }
.tc-form, .tc-edit { display: flex; flex-direction: column; gap: 8px; padding-top: 12px; border-top: 1px solid var(--plum-2); }
.tc-edit { padding: 12px; border: 1px solid var(--plum-3); border-radius: var(--radius-sm); }
.tc-form-head { font-size: 12px; color: var(--plum-soft); font-weight: 600; }
.timecard .field > span { color: var(--plum-soft); font-size: 11px; }
.timecard .field input, .timecard .field select {
  background: var(--plum); color: var(--white); border-color: var(--plum-3); font-size: 13px; padding: 9px 10px; min-height: 40px;
}
.timecard .field input::placeholder { color: #a8979f; }
.tc-row { display: grid; grid-template-columns: 90px minmax(0, 1fr); gap: 8px; }
.tc-why { font-size: 12px; color: #ffd0da; }
.tc-edit-actions { display: flex; gap: 10px; align-items: center; flex-wrap: wrap; }
.tc-week { display: flex; flex-direction: column; gap: 6px; }
.tc-week-row { display: flex; justify-content: space-between; font-size: 13px; }
.tc-week-row span:first-child { color: var(--plum-soft); }
.tc-open { font-size: 13px; color: var(--white); font-weight: 600; }
.tc-open:hover { color: #ffd0da; }
.timecard .notice-error { background: #5c1a2a; color: #ffd0da; }
.timecard .notice-ok { background: #1f4a35; color: #c9f0da; }

.bar { height: 6px; background: var(--plum-2); border-radius: 3px; overflow: hidden; }
.bar-light { background: var(--line-2); height: 5px; }
.bar-fill { height: 100%; background: var(--scarlet); border-radius: 3px; }

/* ---------- page band (Tools, Systems, etc) ---------- */
.page-band { background: var(--white); border-bottom: 1px solid var(--line); }
.band-inner { padding-top: 36px; padding-bottom: 28px; }
.band-row { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: flex-end; gap: 20px; }
.band-intro { color: var(--muted); max-width: 720px; margin-top: 10px; }
.crumbs { font-size: 13px; color: var(--muted); margin-bottom: 14px; }
.crumbs a { color: var(--muted); }
.crumbs.on-dark, .crumbs.on-dark a { color: var(--plum-soft); }
.filter-chips { display: flex; flex-wrap: wrap; gap: 8px; }
.filter-stack { display: flex; flex-direction: column; gap: 10px; margin-top: 14px; }
.filter-chip {
  font-size: 13px; padding: 7px 13px; border-radius: 999px; cursor: pointer; min-height: 36px;
  border: 1px solid #d9d1d5; background: var(--white); color: var(--plum); font-weight: 500;
}
.filter-chip:hover { border-color: var(--plum); }
.filter-chip.is-on { border-color: var(--plum); background: var(--plum); color: var(--white); font-weight: 600; }
.recent { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; margin-top: 20px; }
.recent-label { font-size: 12px; font-weight: 600; letter-spacing: 0.1em; text-transform: uppercase; color: var(--muted); margin-right: 6px; }
.recent-link { font-size: 13px; font-weight: 500; padding: 6px 12px; border-radius: 999px; background: var(--tint); text-decoration: none; }

/* ---------- tools ---------- */
.tool-groups { display: flex; flex-direction: column; gap: 40px; }
.tool-group { scroll-margin-top: 16px; }
.group-head { display: flex; align-items: baseline; flex-wrap: wrap; gap: 6px 14px; margin-bottom: 16px; }
.group-head h2 { font-size: 22px; font-weight: 700; }
.tiles { display: grid; grid-template-columns: repeat(auto-fill, minmax(250px, 1fr)); gap: 16px; }
.tiles-2 { grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); }
.tile {
  background: var(--white); border: 1px solid var(--line); border-radius: 14px; padding: 18px; text-decoration: none;
  display: flex; flex-direction: column; gap: 14px; min-height: 170px; transition: border-color 0.15s, box-shadow 0.15s;
}
a.tile:hover { border-color: var(--plum); box-shadow: 0 8px 20px rgba(49, 25, 36, 0.08); color: var(--plum); }
.tile.is-off { border-style: dashed; background: #fbfafa; color: var(--muted); }
.tile-top { display: flex; justify-content: space-between; align-items: flex-start; gap: 10px; }
.monogram {
  width: 44px; height: 44px; border-radius: 10px; background: var(--plum); color: var(--white);
  display: flex; align-items: center; justify-content: center; font-weight: 700; font-size: 15px;
}
.tile.is-off .monogram { background: #e9e4e6; color: var(--muted); }
.tile-body { display: flex; flex-direction: column; gap: 4px; }
.tile-name { font-size: 16px; font-weight: 600; display: flex; align-items: center; gap: 6px; }
.tile-desc { font-size: 13px; color: var(--muted); line-height: 1.5; }
.tile-coming { font-size: 12px; font-weight: 600; }
.chips { display: flex; flex-wrap: wrap; gap: 6px; margin-top: auto; }
.chip { font-size: 11px; font-weight: 600; padding: 3px 9px; border-radius: 999px; background: var(--tint); }
.pill { font-size: 11px; font-weight: 600; padding: 3px 9px; border-radius: 999px; white-space: nowrap; display: inline-block; }
.pill-live { background: var(--green-bg); color: var(--green-ink); }
.pill-building { background: var(--amber-bg); color: var(--amber-ink); }
.pill-planned { background: var(--tint); color: var(--muted); }
.status-anchor { background: var(--plum); color: var(--white); }
.status-active { background: var(--green-bg); color: var(--green-ink); }
.status-paused, .status-dormant { background: var(--amber-bg); color: var(--amber-ink); }
.status-past { background: var(--line-2); color: var(--muted); }
.status-dont_pursue { background: var(--white); color: var(--red-ink); border: 1px solid #f0c3cc; }
.status-anchor.on-dark { background: var(--scarlet); }
.pill-outline { border: 1px solid var(--plum-3); color: var(--white); }

/* ---------- placeholders ---------- */
.coming-soon { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 14px; }
.coming-soon li { display: flex; flex-direction: column; gap: 2px; font-size: 14px; }
.cs-top { display: flex; justify-content: space-between; align-items: center; gap: 10px; }
.link-card .btn { align-self: flex-start; }

/* ---------- client guides index ---------- */
.stats { display: flex; gap: 12px; margin: 0; }
.stats div { background: var(--smoke); border: 1px solid var(--line); border-radius: 12px; padding: 10px 16px; min-width: 104px; }
.stats dt { font-size: 12px; color: var(--muted); }
.stats dd { margin: 0; font-size: 26px; font-weight: 700; }
.guides-layout { display: grid; grid-template-columns: minmax(0, 1fr) 340px; gap: 24px; align-items: start; }
.guides-main { display: flex; flex-direction: column; gap: 12px; min-width: 0; }
.guides-aside { display: flex; flex-direction: column; gap: 20px; }
.guide-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(240px, 1fr)); gap: 14px; }
.guide-card {
  background: var(--white); border: 1px solid var(--line); border-radius: 14px; padding: 16px 18px; text-decoration: none;
  display: flex; flex-direction: column; gap: 8px;
}
a.guide-card:hover { border-color: var(--plum); color: var(--plum); }
.guide-card-top { display: flex; justify-content: space-between; align-items: flex-start; gap: 10px; }
.guide-card-name { font-size: 16px; font-weight: 600; }
.guide-card-meta, .guide-card-has { font-size: 12px; color: var(--muted); }
.completeness { display: flex; flex-direction: column; gap: 6px; }
.guide-card-open { font-size: 13px; font-weight: 600; color: var(--crimson); margin-top: auto; }
.empty { padding: 24px; background: var(--white); border: 1px dashed var(--line); border-radius: 12px; color: var(--muted); }
.rule-list, .gap-list { margin: 0; padding-left: 18px; display: flex; flex-direction: column; gap: 8px; font-size: 13px; line-height: 1.5; }
.rule-list a, .gap-list a { font-weight: 600; }
.key-list { margin: 0; display: grid; grid-template-columns: auto 1fr; gap: 6px 10px; font-size: 13px; }
.key-list dt { font-weight: 600; }
.key-list dd { margin: 0; color: var(--muted); }

/* ---------- client guide page ---------- */
.guide-hero { background: var(--plum); color: var(--white); }
.guide-hero-inner { padding-top: 28px; padding-bottom: 28px; display: flex; flex-direction: column; gap: 20px; }
.guide-hero-row { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: flex-end; gap: 20px; }
.pill-row { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 12px; }
.guide-summary { color: var(--plum-soft); max-width: 760px; margin-top: 12px; }
.fact-strip { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 1px; background: var(--plum-2); border-radius: 12px; overflow: hidden; margin: 0; }
.fact-strip div { background: #3b2330; padding: 12px 16px; }
.fact-strip dt { font-size: 11px; font-weight: 600; letter-spacing: 0.08em; text-transform: uppercase; color: var(--plum-soft); }
.fact-strip dd { margin: 2px 0 0; font-weight: 600; }
.fact-sub { display: block; font-size: 12px; font-weight: 400; color: var(--plum-soft); }
.guide-layout { display: grid; grid-template-columns: 220px minmax(0, 1fr); gap: 32px; align-items: start; }
.toc { position: sticky; top: 16px; display: flex; flex-direction: column; gap: 2px; font-size: 14px; }
.toc-head { font-size: 11px; font-weight: 600; letter-spacing: 0.1em; text-transform: uppercase; color: var(--muted); padding: 0 10px 8px; }
.toc a { padding: 7px 10px; border-radius: 8px; text-decoration: none; }
.toc a:hover { background: var(--tint); }
.guide-body { display: flex; flex-direction: column; gap: 22px; min-width: 0; overflow-wrap: anywhere; }
.card, .guide-card, .tile { overflow-wrap: break-word; }
.guide-section { background: var(--white); border: 1px solid var(--line); border-radius: var(--radius); padding: 24px 26px; display: flex; flex-direction: column; gap: 14px; scroll-margin-top: 16px; }
.guide-section h2 { font-size: 20px; font-weight: 700; }
.guide-section h3 { font-size: 15px; font-weight: 600; }
.guide-section:has(.callout), .guide-section:has(.gaps) { padding: 0; border: 0; background: none; }
.callout { background: var(--pink); border-left: 4px solid var(--scarlet); border-radius: 12px; padding: 20px 24px; display: flex; flex-direction: column; gap: 10px; }
.callout ul, .gaps ul, .plain-list, .panel ul { margin: 0; padding-left: 18px; display: flex; flex-direction: column; gap: 8px; }
.key-tag { display: inline-block; font-size: 11px; font-weight: 600; background: var(--scarlet); color: var(--white); padding: 1px 8px; border-radius: 999px; margin-right: 8px; vertical-align: 1px; }
.callout-soft { background: var(--smoke); border-radius: 10px; padding: 12px 14px; font-size: 14px; color: var(--muted); display: flex; flex-direction: column; gap: 6px; }
.gaps { border: 2px dashed #d9d1d5; border-radius: var(--radius); padding: 20px 24px; display: flex; flex-direction: column; gap: 10px; color: var(--muted); }
.gaps h2 { color: var(--plum); }
.people-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(230px, 1fr)); gap: 12px; }
.contact { border: 1px solid var(--line); border-radius: 12px; padding: 14px 16px; display: flex; flex-direction: column; gap: 2px; }
.contact-name { font-weight: 600; }
.contact-role, .contact-reach { font-size: 13px; color: var(--muted); }
.facts-list { margin: 0; display: grid; grid-template-columns: 120px minmax(0, 1fr); gap: 8px 16px; font-size: 14px; }
.facts-list dt { font-weight: 600; }
.facts-list dd { margin: 0; overflow-wrap: anywhere; }
.brand-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); gap: 12px; }
.brand-card, .panel { border: 1px solid var(--line); border-radius: 12px; padding: 16px; display: flex; flex-direction: column; gap: 8px; font-size: 14px; }
.brand-card dl { margin: 0; display: flex; flex-direction: column; gap: 4px; font-size: 13px; }
.brand-card dt { font-weight: 600; }
.brand-card dd { margin: 0 0 4px; color: var(--muted); }
.small-link { font-size: 13px; font-weight: 600; }
.rules { display: flex; flex-direction: column; gap: 8px; }
.rule { display: flex; gap: 12px; font-size: 14px; align-items: baseline; }
.rule-kind { flex: none; width: 92px; font-size: 11px; font-weight: 700; text-transform: uppercase; letter-spacing: 0.06em; padding: 3px 8px; border-radius: 6px; text-align: center; background: var(--tint); }
.rule-always .rule-kind { background: var(--green-bg); color: var(--green-ink); }
.rule-never .rule-kind { background: var(--red-bg); color: var(--red-ink); }
.tag-list { list-style: none; margin: 0; padding: 0; display: flex; flex-wrap: wrap; gap: 6px; }
.tag-list li { font-size: 13px; padding: 4px 10px; border-radius: 999px; background: var(--tint); }
.link-list { margin: 0; padding-left: 18px; font-size: 14px; }
.two-col, .pillar-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(240px, 1fr)); gap: 12px; }
details.state { border: 1px solid var(--line); border-radius: 12px; }
details.state summary { cursor: pointer; padding: 12px 16px; font-weight: 600; display: flex; justify-content: space-between; gap: 10px; list-style-position: inside; }
details.state[open] summary { border-bottom: 1px solid var(--line-2); }
.sites { list-style: none; margin: 0; padding: 4px 16px 10px; }
.sites li { padding: 10px 0; border-bottom: 1px solid var(--line-2); }
.sites li:last-child { border-bottom: 0; }
.site-name { font-weight: 600; font-size: 14px; display: flex; flex-wrap: wrap; align-items: center; gap: 8px; }
.site-tag { font-size: 11px; font-weight: 600; padding: 2px 8px; border-radius: 999px; background: var(--tint); color: var(--muted); }
.site-addr { font-size: 13px; color: var(--muted); }
.steps { margin: 0; padding-left: 22px; display: flex; flex-direction: column; gap: 10px; }
.steps li::marker { font-weight: 700; color: var(--scarlet); }
.project-list { list-style: none; margin: 0; padding: 0; }
.project-list li { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 4px 16px; padding: 10px 0; border-bottom: 1px solid var(--line-2); font-size: 14px; }
.project-list li:last-child { border-bottom: 0; }
.project-title { font-weight: 600; }

/* ---------- edit form ---------- */
.edit-form { display: flex; flex-direction: column; gap: 20px; max-width: 980px; }
.edit-set, .rows-set { border: 1px solid var(--line); border-radius: var(--radius); background: var(--white); padding: 18px 20px 20px; margin: 0; display: flex; flex-direction: column; gap: 12px; min-width: 0; }
.edit-set legend, .rows-set legend { font-weight: 700; font-size: 16px; padding: 0 6px; }
.edit-set .rows-set { border-style: dashed; padding: 14px 16px; }
.edit-set .rows-set legend { font-size: 14px; }
.rows { display: flex; flex-direction: column; gap: 10px; }
.row-item { display: flex; gap: 12px; align-items: flex-end; padding-bottom: 10px; border-bottom: 1px solid var(--line-2); }
.row-cells { flex: 1; display: grid; grid-template-columns: repeat(auto-fit, minmax(180px, 1fr)); gap: 8px; align-items: end; }
.rows-set > .btn { align-self: flex-start; }
.sticky-actions { position: sticky; bottom: 0; background: var(--smoke); padding: 14px 0; display: flex; gap: 10px; border-top: 1px solid var(--line); }

/* ---------- admin ---------- */
.table-wrap { overflow-x: auto; background: var(--white); border: 1px solid var(--line); border-radius: 12px; margin-bottom: 12px; }
.admin-table { width: 100%; border-collapse: collapse; font-size: 14px; }
.admin-table th { text-align: left; font-size: 12px; color: var(--muted); font-weight: 600; padding: 10px 12px; border-bottom: 1px solid var(--line); }
.admin-table td { padding: 10px 12px; border-bottom: 1px solid var(--line-2); vertical-align: top; }
.admin-table tr.is-archived td { color: var(--muted); }
.admin-table .pill { margin-left: 8px; }
.admin-form { margin-bottom: 16px; gap: 12px; }
.admin-form h3 { font-size: 16px; }

/* ---------- responsive ---------- */
@media (max-width: 1100px) {
  .header-row { gap: 12px; }
  .nav-label { padding-left: 8px; }
  .search { max-width: 220px; }
}
@media (max-width: 960px) {
  .wrap { padding-left: 16px; padding-right: 16px; }
  .header-row { flex-wrap: wrap; min-height: 60px; padding-top: 10px; padding-bottom: 10px; }
  .menu-button {
    display: flex; align-items: center; justify-content: center; order: 3;
    width: 40px; height: 40px; border: 0; border-radius: var(--radius-sm); background: var(--tint); cursor: pointer;
  }
  .header-tools { order: 2; gap: 10px; flex: 1 1 0; }
  .search { max-width: none; min-width: 0; }
  .nav { order: 4; flex-basis: 100%; display: none; }
  .site-header.nav-open .nav { display: block; }
  .nav-list { flex-direction: column; gap: 0; padding: 6px 0 8px; }
  .nav-item { border-top: 1px solid var(--line-2); }
  .nav-row { justify-content: space-between; }
  .nav-label { padding: 13px 4px; border-bottom: 0; border-left: 3px solid transparent; flex: 1; }
  .nav-label.is-active { border-left-color: var(--scarlet); padding-left: 10px; }
  .nav-toggle { padding: 12px; }
  .menu { position: static; box-shadow: none; border: 0; border-radius: 0; padding: 0 0 8px 8px; min-width: 0; }
  .menu-head { display: none; }
  .home-grid, .guides-layout, .split { grid-template-columns: minmax(0, 1fr); }
  .guide-layout { grid-template-columns: minmax(0, 1fr); }
  .toc { position: static; flex-direction: row; flex-wrap: wrap; gap: 6px; }
  .toc-head { width: 100%; padding-left: 0; }
  .toc a { background: var(--white); border: 1px solid var(--line); border-radius: 999px; padding: 5px 12px; font-size: 13px; }
  .fact-strip { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (max-width: 600px) {
  .display { font-size: 42px; }
  .display-dark { font-size: 40px; }
  .display-md { font-size: 30px; }
  .brand img { height: 28px; }
  .search-box input { font-size: 16px; } /* stops iOS zooming on focus */
  .field input, .field select, .field textarea { font-size: 16px; }
  .hero-inner { padding-top: 28px; padding-bottom: 28px; gap: 20px; }
  .hero-actions { width: 100%; }
  .hero-actions .btn { flex: 1 1 auto; }
  .card, .guide-section { padding: 18px; }
  .callout, .gaps { padding: 16px 18px; }
  .grid-2, .grid-3 { grid-template-columns: minmax(0, 1fr); }
  .stats { width: 100%; }
  .stats div { flex: 1; min-width: 0; padding: 8px 12px; }
  .facts-list { grid-template-columns: minmax(0, 1fr); gap: 2px; }
  .facts-list dd { margin-bottom: 8px; }
  .row-item { flex-direction: column; align-items: stretch; }
  .rule { flex-direction: column; gap: 4px; }
  .admin-table { font-size: 13px; }
}
