/* ===========================================================================
   SureEstate Panorama — hand-written CSS. No build step: shared hosting has no
   Node, so this file is the whole of the styling and is meant to be read.

   The register is neutral and typographic. Colour carries meaning and nothing
   else: a plot's status, a lease's state, money that is overdue. Everything
   structural is white, near-white and a hairline, so the eye goes to the words
   and the numbers rather than to the furniture.

   Layout:
     1. Tokens (light, then dark)
     2. Base and typography
     3. Shell — sidebar, topbar, content
     4. Blocks — cards, stats, panels
     5. Tables
     6. Forms and buttons
     7. Status — pills, badges, flashes
     8. Boards — pipeline and occupancy
     9. Panorama map
    10. Public site and the installer
    11. Responsive
    12. Print
   =========================================================================== */

/* --------------------------------------------------------------- 1. Tokens */

:root {
  /* Surfaces. The page is faintly grey so white cards separate without borders. */
  --bg:            #F7F7F8;
  --surface:       #FFFFFF;
  --surface-2:     #FAFAFA;
  --zebra:         #FAFAFA;

  /* Ink */
  --text:          #18181B;
  --text-strong:   #09090B;
  --muted:         #71717A;
  --faint:         #A1A1AA;

  /* Lines — hairlines only, never a frame */
  --line:          #E4E4E7;
  --line-strong:   #D4D4D8;

  /* One accent. Everything interactive is this colour and nothing else is.
     Navy, so Panorama and SureFleet read as one family at a glance. */
  --accent:        #1B3A5C;
  --accent-hover:  #16304C;
  --accent-tint:   #EDF2F8;
  --accent-ink:    #15304D;
  --accent-on:     #FFFFFF;

  /* Status. Used as small marks, not as fields of colour. */
  --green:  #15803D;  --green-tint:  #F0FDF4;
  --amber:  #B45309;  --amber-tint:  #FFFBEB;
  --orange: #C2410C;  --orange-tint: #FFF7ED;
  --red:    #DC2626;  --red-tint:    #FEF2F2;
  --blue:   #1D4ED8;  --blue-tint:   #EFF6FF;
  --purple: #6D28D9;  --purple-tint: #F5F3FF;
  --grey:   #71717A;  --grey-tint:   #F4F4F5;
  --slate:  #475569;  --slate-tint:  #F1F5F9;

  /* Kept for the brand mark and anything still asking for them by name. */
  --navy:      #18181B;
  --navy-dark: #09090B;
  --teal:      var(--accent);

  /* The navigation rail is tokenised so a theme can darken it on its own. */
  --rail-bg:          var(--surface);
  --rail-line:        var(--line);
  --rail-text:        var(--text);
  --rail-strong:      var(--text-strong);
  --rail-muted:       var(--faint);
  --rail-hover:       var(--surface-2);
  --rail-active-bg:   var(--accent-tint);
  --rail-active-text: var(--accent-ink);

  /* A promoter's own website takes one colour of its own (milestone 30). The
     layout writes it as a style attribute on <body>, which beats this; a
     company that never chose one inherits the platform accent and still looks
     finished. Declared here rather than only as a fallback at each use,
     because a fallback is not a definition — see the note on this in
     view-check. */
  --site-accent: var(--accent);

  --radius:    10px;
  --radius-sm: 6px;
  --shadow:    none;

  --sidebar:   248px;
}

/* ------------------------------------------------------------- 1b. Themes
   Three looks. A theme only moves tokens; not one rule below knows which is on.
   The company sets a house look, a person may override it for themselves, and
   the choice arrives as data-theme on <html>.

   Each theme also names its dark accent (--accent-d and friends), because in
   dark mode the surfaces converge to near-black across all three and only the
   accent really distinguishes them.
   ------------------------------------------------------------------------ */

:root,
[data-theme="neutral"] {
  --accent-d: #8AB4E8; --accent-hover-d: #A9C9F0; --accent-tint-d: #16233A; --accent-ink-d: #C3DAF6;
  --accent-on-d: #0B1220;
}

/* Classic — the navy and teal the platform launched with, softened. */
[data-theme="classic"] {
  --bg:          #F4F6F9;
  --surface:     #FFFFFF;
  --surface-2:   #F7F9FC;
  --zebra:       #F7F9FC;

  --text:        #1E293B;
  --text-strong: #0F1F35;
  --muted:       #64748B;
  --faint:       #94A3B8;

  --line:        #E2E8F0;
  --line-strong: #CBD5E1;

  --accent:       #0F766E;
  --accent-hover: #0B5C55;
  --accent-tint:  #ECFDF5;
  --accent-ink:   #115E59;

  --accent-d: #2DD4BF; --accent-hover-d: #5EEAD4; --accent-tint-d: #0B2E2B; --accent-ink-d: #99F6E4;

  /* The navy rail, which is what people remember about this look. */
  --rail-bg:          #1F3A5F;
  --rail-line:        #1F3A5F;
  --rail-text:        #D7E3F1;
  --rail-strong:      #FFFFFF;
  --rail-muted:       #8FA8C6;
  --rail-hover:       rgba(255,255,255,.09);
  --rail-active-bg:   #0F766E;
  --rail-active-text: #FFFFFF;
}

/* Contrast — a near-black rail against a white working area. */
[data-theme="contrast"] {
  --bg:          #FFFFFF;
  --surface:     #FFFFFF;
  --surface-2:   #F7F7F8;
  --zebra:       #F7F7F8;

  --text:        #18181B;
  --text-strong: #000000;
  --muted:       #52525B;
  --faint:       #A1A1AA;

  --line:        #E4E4E7;
  --line-strong: #D4D4D8;

  --accent:       #0D9488;
  --accent-hover: #0F766E;
  --accent-tint:  #ECFDF5;
  --accent-ink:   #0F766E;

  --accent-d: #2DD4BF; --accent-hover-d: #5EEAD4; --accent-tint-d: #0B2E2B; --accent-ink-d: #99F6E4;

  --rail-bg:          #0A0A0B;
  --rail-line:        #0A0A0B;
  --rail-text:        #A1A1AA;
  --rail-strong:      #FAFAFA;
  --rail-muted:       #52525B;
  --rail-hover:       rgba(255,255,255,.07);
  --rail-active-bg:   rgba(255,255,255,.12);
  --rail-active-text: #FFFFFF;
}

/* ---------------------------------------------------------- 1c. Dark mode

   Two selectors, one body. A person who chose dark gets it always; a person
   who left the choice alone gets whatever the device says. CSS has no way to
   say "this selector OR that media query" in one rule, so the body is written
   twice on purpose rather than by accident.
   ------------------------------------------------------------------------ */

[data-scheme="dark"] {
  --bg:          #0A0A0B;
  --surface:     #151517;
  --surface-2:   #1B1B1E;
  --zebra:       #1B1B1E;

  --text:        #E4E4E7;
  --text-strong: #FAFAFA;
  --muted:       #A1A1AA;
  --faint:       #71717A;

  --line:        #27272A;
  --line-strong: #3F3F46;

  --accent:       var(--accent-d);
  --accent-hover: var(--accent-hover-d);
  --accent-tint:  var(--accent-tint-d);
  --accent-ink:   var(--accent-ink-d);
  --accent-on:    var(--accent-on-d, #0B1220);

  --green:  #4ADE80;  --green-tint:  #0C2717;
  --amber:  #FBBF24;  --amber-tint:  #2A1D05;
  --orange: #FB923C;  --orange-tint: #2A1608;
  --red:    #F87171;  --red-tint:    #2A1214;
  --blue:   #60A5FA;  --blue-tint:   #0C1A33;
  --purple: #A78BFA;  --purple-tint: #1B1338;
  --grey:   #A1A1AA;  --grey-tint:   #1F1F23;
  --slate:  #94A3B8;  --slate-tint:  #17202B;

  --navy:      #FAFAFA;
  --navy-dark: #FFFFFF;

  --rail-bg:          #0F0F11;
  --rail-line:        #27272A;
  --rail-text:        #A1A1AA;
  --rail-strong:      #FAFAFA;
  --rail-muted:       #52525B;
  --rail-hover:       rgba(255,255,255,.06);
  --rail-active-bg:   var(--accent-tint);
  --rail-active-text: var(--accent-ink);
}

@media (prefers-color-scheme: dark) {
  [data-scheme="auto"] {
    --bg:          #0A0A0B;
    --surface:     #151517;
    --surface-2:   #1B1B1E;
    --zebra:       #1B1B1E;

    --text:        #E4E4E7;
    --text-strong: #FAFAFA;
    --muted:       #A1A1AA;
    --faint:       #71717A;

    --line:        #27272A;
    --line-strong: #3F3F46;

    --accent:       var(--accent-d);
    --accent-hover: var(--accent-hover-d);
    --accent-tint:  var(--accent-tint-d);
    --accent-ink:   var(--accent-ink-d);
    --accent-on:    var(--accent-on-d, #0B1220);

    --green:  #4ADE80;  --green-tint:  #0C2717;
    --amber:  #FBBF24;  --amber-tint:  #2A1D05;
    --orange: #FB923C;  --orange-tint: #2A1608;
    --red:    #F87171;  --red-tint:    #2A1214;
    --blue:   #60A5FA;  --blue-tint:   #0C1A33;
    --purple: #A78BFA;  --purple-tint: #1B1338;
    --grey:   #A1A1AA;  --grey-tint:   #1F1F23;
    --slate:  #94A3B8;  --slate-tint:  #17202B;

    --navy:      #FAFAFA;
    --navy-dark: #FFFFFF;

    --rail-bg:          #0F0F11;
    --rail-line:        #27272A;
    --rail-text:        #A1A1AA;
    --rail-strong:      #FAFAFA;
    --rail-muted:       #52525B;
    --rail-hover:       rgba(255,255,255,.06);
    --rail-active-bg:   var(--accent-tint);
    --rail-active-text: var(--accent-ink);
  }
}

/* ------------------------------------------------- 2. Base and typography */

* { box-sizing: border-box; }

html { -webkit-text-size-adjust: 100%; }

body {
  margin: 0;
  /* Segoe UI Variable first: on the Windows machines this platform is run from
     it is the closest thing installed to the face the design was drawn in, and
     it costs nothing to download. No web font — a render-blocking request to a
     third party, on Cameroonian mobile data, for the shape of the letters. */
  font-family: "Segoe UI Variable Text", ui-sans-serif, system-ui, -apple-system,
               "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  font-size: 15px;
  line-height: 1.55;
  background: var(--bg);
  color: var(--text);
  -webkit-font-smoothing: antialiased;
  font-feature-settings: "cv05" 1;
}

/* Figures line up in columns; this is a platform about money. */
.num, td.num, th.num, .value, .stat-value, .price, table { font-variant-numeric: tabular-nums; }

a { color: var(--accent); text-decoration: none; }
a:hover { color: var(--accent-hover); text-decoration: underline; text-underline-offset: 2px; }

h1, h2, h3, h4 { margin: 0 0 .5rem; color: var(--text-strong); line-height: 1.25; letter-spacing: -.011em; }
h1 { font-size: 1.5rem; font-weight: 650; letter-spacing: -.018em; }
h2 { font-size: 1.05rem; font-weight: 620; }
h3 { font-size: .95rem; font-weight: 620; }

p { margin: 0 0 .75rem; }

.small { font-size: .85rem; }
.muted { color: var(--muted); }
.mb { margin-bottom: 1rem; }
.mt { margin-top: 1rem; }
.right { text-align: right; }
.mono {
  font-family: ui-monospace, "SF Mono", Menlo, Consolas, "Liberation Mono", monospace;
  font-size: .85em;
  color: var(--muted);
}

.page-head { margin-bottom: 1.25rem; }
.page-head h1 { margin-bottom: .15rem; }
.page-head p { margin: 0; color: var(--muted); }

/* --------------------------------------------------------------- 3. Shell */

.app { display: flex; min-height: 100vh; }

/* ---------------------------------------------------------------- the rail */

.sidebar {
  width: var(--sidebar);
  flex: none;
  background: var(--rail-bg);
  border-right: 1px solid var(--rail-line);
  position: sticky;
  top: 0;
  height: 100vh;
  display: flex;
  flex-direction: column;
  transition: width .16s ease;
}

.sidebar .brand {
  display: flex;
  align-items: center;
  gap: .6rem;
  padding: .95rem .85rem;
  border-bottom: 1px solid var(--rail-line);
  color: var(--rail-strong);
}
.sidebar .brand:hover { text-decoration: none; }

.brand-mark {
  flex: none;
  display: grid;
  place-items: center;
  width: 34px; height: 34px;
  border-radius: 9px;
  background: var(--accent);
  color: var(--accent-on);
}
.brand-mark .icon { width: 19px; height: 19px; }

.brand-words { display: flex; flex-direction: column; min-width: 0; line-height: 1.2; }
.brand-words strong {
  font-size: .96rem; font-weight: 660; letter-spacing: -.015em;
  white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
}
.brand-words small {
  font-size: .74rem; color: var(--rail-muted); font-weight: 400;
  white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
}

/* The links scroll; the brand and the person do not. */
.nav-scroll { flex: 1; overflow-y: auto; overflow-x: hidden; padding: .6rem .55rem 1rem; }

.sidebar a {
  display: flex;
  align-items: center;
  gap: .6rem;
  padding: .45rem .6rem;
  margin-bottom: 1px;
  border-radius: 8px;
  color: var(--rail-text);
  font-size: .885rem;
  font-weight: 450;
  white-space: nowrap;
}
.sidebar a > span { overflow: hidden; text-overflow: ellipsis; }
.sidebar a .icon { flex: none; color: var(--rail-muted); }
.sidebar a:hover { background: var(--rail-hover); color: var(--rail-strong); text-decoration: none; }
.sidebar a:hover .icon { color: var(--rail-strong); }
.sidebar a.active { background: var(--rail-active-bg); color: var(--rail-active-text); font-weight: 560; }
.sidebar a.active .icon { color: var(--rail-active-text); }

/* The little corner arrow on a link that leaves the platform. */
.sidebar a .icon + span + .icon { margin-left: auto; width: 13px; height: 13px; opacity: .6; }

.sidebar .group {
  margin: 1.25rem 0 .3rem;
  padding: 0 .6rem;
  font-size: .68rem;
  font-weight: 650;
  text-transform: uppercase;
  letter-spacing: .07em;
  color: var(--rail-muted);
}

.sidebar-user {
  display: flex;
  align-items: center;
  gap: .55rem;
  padding: .6rem .7rem;
  border-top: 1px solid var(--rail-line);
}
.sidebar-user-words { flex: 1; min-width: 0; display: flex; flex-direction: column; line-height: 1.25; }
.sidebar-user-words strong {
  font-size: .85rem; font-weight: 560; color: var(--rail-strong);
  white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
}
.sidebar-user-words small {
  font-size: .73rem; color: var(--rail-muted);
  white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
}
.sidebar-user form { margin: 0; }

/* -------------------------------------------------------- collapsed state */

.sidebar-collapsed .sidebar { width: 62px; }
.sidebar-collapsed .brand-words,
.sidebar-collapsed .sidebar-user-words,
.sidebar-collapsed .sidebar-user form,
.sidebar-collapsed .sidebar a > span,
.sidebar-collapsed .sidebar a .icon + span + .icon { display: none; }
.sidebar-collapsed .sidebar .brand,
.sidebar-collapsed .sidebar-user { justify-content: center; padding-left: .4rem; padding-right: .4rem; }
.sidebar-collapsed .sidebar a { justify-content: center; padding-left: 0; padding-right: 0; }
/* The headings would be a row of clipped letters, so they become a hairline. */
.sidebar-collapsed .sidebar .group {
  font-size: 0; margin: .7rem .55rem; padding: 0;
  border-top: 1px solid var(--rail-line);
}

/* ------------------------------------------------------------- the top bar */

.main { flex: 1; min-width: 0; display: flex; flex-direction: column; }

.topbar {
  display: flex;
  align-items: center;
  gap: .85rem;
  padding: .6rem 1.25rem;
  background: var(--surface);
  border-bottom: 1px solid var(--line);
  position: sticky;
  top: 0;
  z-index: 20;
}

.topbar-title {
  margin: 0;
  font-size: 1rem;
  font-weight: 620;
  letter-spacing: -.012em;
  color: var(--text-strong);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.topbar-right { margin-left: auto; display: flex; align-items: center; gap: .7rem; }
.topbar-company { font-size: .85rem; color: var(--muted); white-space: nowrap; }

.lang { display: flex; align-items: center; gap: .3rem; font-size: .8rem; }
.lang .icon { color: var(--faint); width: 17px; height: 17px; }
.lang a { color: var(--muted); padding: .1rem .2rem; border-radius: 4px; }
.lang a:hover { color: var(--text-strong); text-decoration: none; }
.lang a.is-on { color: var(--accent); font-weight: 600; }

/* The search box, centred, with its shortcut written on it. */
.searchbox {
  flex: 1 1 auto;
  max-width: 26rem;
  margin: 0 auto;
  position: relative;
  display: flex;
  align-items: center;
}
.searchbox .icon {
  position: absolute; left: .65rem;
  width: 17px; height: 17px; color: var(--faint); pointer-events: none;
}
.searchbox input {
  min-height: 36px;
  padding: .35rem 3.9rem .35rem 2.2rem;
  font-size: .87rem;
  border-radius: 8px;
  background: var(--surface-2);
}
.searchbox input:focus { background: var(--surface); }
.searchbox kbd {
  position: absolute; right: .45rem;
  font-family: inherit; font-size: .68rem; font-weight: 550;
  color: var(--muted);
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: 5px;
  padding: .1rem .3rem;
  pointer-events: none;
}

/* The lede under the top bar: what the screen is for, in one line. */
.page-lede {
  margin: 0;
  padding: .75rem 1.5rem 0;
  font-size: .88rem;
  color: var(--muted);
}

.content { padding: 1.25rem 1.5rem 2.5rem; flex: 1; }

/* The public pages have no sidebar, so nothing was holding them to a readable
   measure: on a wide monitor a catalogue page ran the full nineteen hundred
   pixels and every figure on it was drawn to match. The signed-in side gets
   this for free from the rail. */
.content.public { max-width: 72rem; margin: 0 auto; width: 100%; }

/* A safety net, not a substitute for sizing each figure.

   Twice now a drawing has rendered at its intrinsic size because nothing in
   this stylesheet claimed it — Laravel's Tailwind pagination chevrons, and the
   boundary plan on a public page. An SVG is the one element that will happily
   grow to fill a continent, so none of them may exceed their container. */
svg { max-width: 100%; }

/* A form is read down a column, not across a monitor. Forty characters of
   label and a field two feet wide is harder to fill in, not easier. */
.content.narrow { max-width: 46rem; margin: 0 auto; width: 100%; }

.breadcrumb { font-size: .82rem; color: var(--muted); margin-bottom: .6rem; }
.breadcrumb a { color: var(--muted); }
.breadcrumb a:hover { color: var(--text-strong); }

/* ---------------------------------------------------------------- 3b. Icons

   Geometry lives in partials/icons; weight and colour live here, so every glyph
   in the interface changes together and none of them can drift.
   ------------------------------------------------------------------------ */

.icon-sprite { position: absolute; width: 0; height: 0; overflow: hidden; }

.icon {
  width: 18px;
  height: 18px;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.7;
  stroke-linecap: round;
  stroke-linejoin: round;
  flex: none;
  vertical-align: -.18em;
}
.btn .icon { width: 16px; height: 16px; margin-right: .35rem; vertical-align: -.2em; }

/* A button that is only an icon: still 34px of target, on a phone as well. */
.icon-btn {
  display: grid;
  place-items: center;
  width: 34px; height: 34px;
  padding: 0;
  flex: none;
  background: transparent;
  border: 0;
  border-radius: 8px;
  color: var(--muted);
  cursor: pointer;
}
.icon-btn:hover { background: var(--surface-2); color: var(--text-strong); }
.icon-btn:focus-visible { outline: 2px solid var(--accent); outline-offset: 1px; }

/* The initials disc. Two letters, never a photograph — nobody uploads one. */
.avatar {
  display: grid;
  place-items: center;
  flex: none;
  width: 34px; height: 34px;
  border-radius: 50%;
  background: var(--accent);
  color: var(--accent-on);
  font-size: .78rem;
  font-weight: 650;
  letter-spacing: .01em;
  user-select: none;
}
.avatar-sm { width: 30px; height: 30px; font-size: .72rem; }

/* -------------------------------------------------------------- 4. Blocks */

.card {
  background: var(--surface);
  border-radius: var(--radius);
  padding: 1.15rem 1.25rem;
  margin-bottom: 1rem;
  border: 1px solid var(--line);
}
.card > h2:first-child, .card > h3:first-child { margin-top: 0; }

.panel { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 1rem; }
/* A card reporting something that should not be true of this installation — a
   second company, accounts outside yours. An amber edge, not amber text: `.warn`
   on its own recolours everything it contains, and the figures inside this card
   are the point of it. */
.card.warn { color: inherit; border-left: 3px solid var(--amber); }
.card.warn > h2:first-child { color: var(--amber); }

/* One stray company inside that card, with its counts and its two ways out. */
.stray { padding: .8rem 0; border-top: 1px solid var(--line); }
.stray:first-of-type { border-top: 0; padding-top: .2rem; }
.stray h3 { margin: 0 0 .35rem; }

/* Two separate forms that have to sit side by side: each button posts a
   different action, so they cannot share one form. */
.row { display: flex; flex-wrap: wrap; align-items: center; }
.gap { gap: .6rem; }


.grid { display: grid; gap: 1rem; margin-bottom: 1rem; }
.grid.cols-2 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.grid.cols-3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.grid.cols-4 { grid-template-columns: repeat(4, minmax(0, 1fr)); }
/* A field that needs two columns of a grid — a free-text box beside three
   narrow selects. Collapses with everything else at phone width. */
.grid > .span-2 { grid-column: span 2; }

/* A label for a screen reader and not for the eye.
   Eight agenda lines each need a label; eight visible labels saying "Item 3"
   would be noise around a column of empty boxes. The placeholder alone would
   leave the field unlabelled for anybody not looking at it, which is the
   shortcut this class exists to avoid taking. */
.sr-only {
  position: absolute;
  width: 1px; height: 1px;
  padding: 0; margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

/* A figure and what it means. The number does the talking. */
.stat {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 1rem 1.1rem;
}
.stat .label, .stat-label {
  font-size: .72rem;
  font-weight: 550;
  text-transform: uppercase;
  letter-spacing: .06em;
  color: var(--muted);
}
.stat .value, .stat-value {
  display: block;
  margin-top: .15rem;
  font-size: 1.65rem;
  font-weight: 620;
  letter-spacing: -.02em;
  color: var(--text-strong);
  line-height: 1.15;
}
.stat .sub { font-size: .8rem; color: var(--muted); margin-top: .1rem; }

.stat .value.teal, .stat-value.teal { color: var(--accent); }
.stat .value.amber, .stat-value.amber { color: var(--amber); }
.stat .value.red, .stat-value.red, .stat-value.bad { color: var(--red); }

.ok { color: var(--green); }
.bad { color: var(--red); }
.warn { color: var(--amber); }

/* Label and value, side by side */
.kv { width: 100%; border-collapse: collapse; }
.kv th, .kv td { padding: .45rem 0; text-align: left; vertical-align: top; border-bottom: 1px solid var(--line); }
.kv th { width: 40%; font-weight: 500; color: var(--muted); font-size: .86rem; }
.kv tr:last-child th, .kv tr:last-child td { border-bottom: 0; }

/* The same idea written as a div, which is how most screens actually write it —
   `<div class="kv"><span>label</span><span>value</span></div>`. Seventy of those
   existed across eleven views against a stylesheet that only ever styled the
   table flavour, so every one of them rendered as two inline spans with a single
   space between them: "Due date11/10/2026". Scoped to `div.kv` and to its own
   span children, so the table above is untouched. */
div.kv {
  display: flex;
  gap: 1rem;
  justify-content: space-between;
  align-items: baseline;
  padding: .45rem 0;
  border-bottom: 1px solid var(--line);
}
div.kv > span:first-child { flex: 0 1 auto; min-width: 0; color: var(--muted); font-size: .86rem; }
/* `anywhere` rather than `break-word`: these values include references and
   emails with no spaces in them, and on a phone they have to fold. */
div.kv > span:last-child { min-width: 0; text-align: right; overflow-wrap: anywhere; }
div.kv:last-child { border-bottom: 0; }

/* On a phone the two halves stop competing for one line. Rendering these at
   390px turned "Bonamoussadi Residences — Block C" into three words and a lone
   "C" on a line of its own, right-aligned against nothing — and every scope,
   address and estate name in the platform is that long. Stacked, the label sits
   above its value and neither has to be squeezed. */
@media (max-width: 480px) {
  div.kv { flex-direction: column; align-items: stretch; gap: .1rem; }
  div.kv > span:last-child { text-align: left; }
}
.block-label { display: block; font-size: .72rem; text-transform: uppercase; letter-spacing: .06em; color: var(--muted); margin-bottom: .2rem; }

.plain { list-style: none; margin: .4rem 0; padding: 0; }
.plain li { padding: .3rem 0; border-bottom: 1px solid var(--line); }
.plain li:last-child { border-bottom: 0; }

/* -------------------------------------------------------------- 5. Tables */

table { width: 100%; border-collapse: collapse; font-size: .9rem; }

thead th {
  text-align: left;
  font-size: .72rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: .06em;
  color: var(--muted);
  padding: .5rem .6rem;
  border-bottom: 1px solid var(--line-strong);
  white-space: nowrap;
}

tbody td { padding: .6rem; border-bottom: 1px solid var(--line); vertical-align: top; }
tbody tr:last-child td { border-bottom: 0; }
tbody tr:hover td { background: var(--surface-2); }

.num, td.num, th.num { text-align: right; }

tr.total td { border-top: 1px solid var(--line-strong); border-bottom: 0; font-weight: 650; color: var(--text-strong); }

/* --------------------------------------------------- 6. Forms and buttons */

label { display: block; font-size: .86rem; font-weight: 550; color: var(--text); margin-bottom: .3rem; }

/* A required field says so where the eye already is, next to its name. */
label .req, .req { color: var(--red); font-weight: 600; margin-left: .15rem; }

input, select, textarea {
  width: 100%;
  min-height: 42px;
  padding: .55rem .7rem;
  font: inherit;
  font-size: .92rem;
  color: var(--text);
  background: var(--surface);
  border: 1px solid var(--line-strong);
  border-radius: var(--radius-sm);
  outline: none;
}
input:focus, select:focus, textarea:focus {
  border-color: var(--accent);
  box-shadow: 0 0 0 3px var(--accent-tint);
}
input::placeholder, textarea::placeholder { color: var(--faint); }
input[type="checkbox"], input[type="radio"] { width: auto; min-height: 0; }
textarea { resize: vertical; }

.stack { display: flex; flex-direction: column; gap: .7rem; }
.stack label { margin-bottom: 0; }
.stack .grid { margin-bottom: 0; gap: .7rem; }
.stack button { align-self: flex-start; margin-top: .25rem; }

.check { display: flex; align-items: center; gap: .5rem; font-size: .89rem; font-weight: 450; margin-bottom: 0; }
.check input { margin: 0; accent-color: var(--accent); }

.filters { display: flex; flex-wrap: wrap; gap: .7rem; align-items: flex-end; margin-bottom: 1rem; }

.btn {
  display: inline-block;
  border: 1px solid transparent;
  border-radius: var(--radius-sm);
  padding: .45rem .85rem;
  font-size: .88rem;
  font-weight: 550;
  line-height: 1.4;
  cursor: pointer;
  background: var(--surface);
  color: var(--text);
  border-color: var(--line-strong);
}
.btn:hover { background: var(--surface-2); text-decoration: none; }
.btn-primary, .btn-navy { background: var(--accent); border-color: var(--accent); color: var(--accent-on); }
.btn-primary:hover, .btn-navy:hover { background: var(--accent-hover); border-color: var(--accent-hover); color: var(--accent-on); }
.btn-outline { background: transparent; border-color: var(--line-strong); color: var(--text); }
.btn-danger { background: transparent; border-color: var(--red); color: var(--red); }
.btn-danger:hover { background: var(--red-tint); }
.btn-small { padding: .25rem .55rem; font-size: .8rem; }
.btn[disabled] { opacity: .45; cursor: not-allowed; }

/* -------------------------------------------------------------- 7. Status */

/* Quiet by default: tinted, not filled. A screen of these should still read
   as a page of text rather than a bag of sweets. */
.pill {
  display: inline-block;
  padding: .1rem .45rem;
  border-radius: var(--radius-sm);
  font-size: .75rem;
  font-weight: 550;
  white-space: nowrap;
  background: var(--grey-tint);
  color: var(--grey);
}
.pill-green  { background: var(--green-tint);  color: var(--green); }
.pill-amber  { background: var(--amber-tint);  color: var(--amber); }
.pill-orange { background: var(--orange-tint); color: var(--orange); }
.pill-blue   { background: var(--blue-tint);   color: var(--blue); }
.pill-red    { background: var(--red-tint);    color: var(--red); }
.pill-purple { background: var(--purple-tint); color: var(--purple); }
.pill-grey   { background: var(--grey-tint);   color: var(--grey); }
.pill-slate  { background: var(--slate-tint);  color: var(--slate); }

/* Filled, for the few places a colour is set inline from a status enum. */
.badge {
  display: inline-block;
  padding: .08rem .4rem;
  border-radius: 999px;
  font-size: .7rem;
  font-weight: 600;
  color: #fff;
  background: var(--grey);
}

.swatch { display: inline-block; width: .7rem; height: .7rem; border-radius: 3px; vertical-align: -1px; }

.flash {
  border-left: 3px solid var(--accent);
  background: var(--accent-tint);
  color: var(--text);
  padding: .65rem .85rem;
  border-radius: var(--radius-sm);
  margin-bottom: 1rem;
  font-size: .9rem;
}
.flash.error { border-color: var(--red); background: var(--red-tint); }
.flash.ok    { border-color: var(--green); background: var(--green-tint); }
.flash.warn  { border-color: var(--amber); background: var(--amber-tint); }

/* --------------------------------------------------------------- 8. Boards */

.pipeline { display: flex; gap: .75rem; overflow-x: auto; padding-bottom: .5rem; align-items: flex-start; }

.pipeline-col {
  flex: 0 0 248px;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: .65rem;
}
.pipeline-col.over { border-color: var(--accent); background: var(--accent-tint); }

/* The column's colour is a mark, not a field: a dot beside the name. */
.pipeline-col header {
  display: flex;
  align-items: center;
  gap: .4rem;
  padding: .1rem .15rem .6rem;
  font-size: .8rem;
  font-weight: 600;
  color: var(--text-strong);
  letter-spacing: .01em;
}
.pipeline-col header .dot { width: .5rem; height: .5rem; border-radius: 999px; flex: none; }
.pipeline-col header .count {
  margin-left: auto;
  background: var(--surface-2);
  color: var(--muted);
  border-radius: 999px;
  padding: 0 .4rem;
  font-size: .73rem;
  font-weight: 600;
}

.deal {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius-sm);
  padding: .55rem .6rem;
  margin-bottom: .45rem;
  cursor: grab;
  font-size: .86rem;
}
.deal:hover { border-color: var(--line-strong); }
.deal:active { cursor: grabbing; }
.deal:last-child { margin-bottom: 0; }
.deal a { color: var(--text-strong); font-weight: 550; }
.deal .badge { font-size: .66rem; }

/* A .deal that is itself a link — the occupancy board, where every tile opens
   something. Block, so the whole card is the target rather than a line of text
   inside it, and pointer rather than grab: these are not draggable. */
a.deal-link { display: block; cursor: pointer; text-decoration: none; color: inherit; }
a.deal-link:hover { border-color: var(--accent); background: var(--surface-2, var(--surface)); }
a.deal-link:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }
a.deal-link strong { color: var(--text-strong); }
.strong { font-weight: 550; color: var(--text-strong); }

/* ------------------------------------------------------------ 9. Panorama */

.panorama { display: grid; grid-template-columns: 240px 1fr 320px; gap: 1rem; align-items: start; }
.map-wrap { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: .75rem; overflow: auto; }
.plot-shape { cursor: pointer; transition: opacity .12s; }
.plot-shape:hover { opacity: .78; }
.plot-shape.selected { stroke: var(--text-strong); stroke-width: 2.5; }
.plot-label { font-size: 9px; fill: #fff; pointer-events: none; font-weight: 600; }
.legend { display: flex; flex-wrap: wrap; gap: .5rem .9rem; font-size: .8rem; color: var(--muted); }
.price { font-size: 1.2rem; font-weight: 620; color: var(--text-strong); letter-spacing: -.015em; }

/* ------------------------------------------- 10. Public site and installer */

/* The bar is full width; what is inside it keeps the same measure as the page
   below, so the wordmark lines up with the first heading. */
.public-header {
  padding: 1rem 1.5rem;
  background: var(--surface);
  border-bottom: 1px solid var(--line);
}
.public-head-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  max-width: 72rem;
  margin: 0 auto;
}
.hero { padding: 2.5rem 1.5rem; text-align: center; background: var(--surface); border-bottom: 1px solid var(--line); }
.hero h1 { font-size: 1.9rem; }
.estate-card { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden; }

.wizard { max-width: 780px; margin: 2.5rem auto; padding: 0 1.25rem; }
.wizard .card { padding: 1.5rem 1.6rem; }
.steps { display: flex; gap: .5rem; margin: 0 0 1.5rem; padding: 0; list-style: none; flex-wrap: wrap; }
.steps li {
  flex: 1;
  min-width: 110px;
  font-size: .76rem;
  font-weight: 500;
  color: var(--faint);
  border-top: 2px solid var(--line);
  padding-top: .45rem;
}
.steps li.done { border-color: var(--green); color: var(--green); }
.steps li.current { border-color: var(--accent); color: var(--accent-ink); font-weight: 650; }

/* Names a few views still use for a colour directly. */
.teal { color: var(--accent); }
.amber { color: var(--amber); }
.red { color: var(--red); }

/* ------------------------------------------------------ 10b. Administration */

/* Sub-navigation inside a module. A row of links, underlined where you are,
   rather than a second sidebar — the settings screens are six pages, not a
   section of their own. */
.tabs {
  display: flex;
  flex-wrap: wrap;
  gap: .15rem;
  margin: 0 0 1.25rem;
  border-bottom: 1px solid var(--line);
}

.tabs a {
  padding: .45rem .8rem;
  font-size: .88rem;
  color: var(--muted);
  text-decoration: none;
  border-bottom: 2px solid transparent;
  margin-bottom: -1px;
}

.tabs a:hover { color: var(--text-strong); background: var(--surface-2); }

.tabs a.active {
  color: var(--text-strong);
  font-weight: 600;
  border-bottom-color: var(--accent);
}

/* The permission grid. Two columns on a wide screen, because 35 permissions in
   one column is a page nobody scrolls to the bottom of. */
.matrix {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: .1rem 1.5rem;
}

.matrix .check { padding: .3rem 0; align-items: flex-start; }
.matrix .check .mono { display: block; font-size: .72rem; }

/* Disclosure used for a detail nobody needs until they do: an audit entry's
   before-and-after values, a block's dimensions. */
details summary {
  cursor: pointer;
  padding: .15rem 0;
}

details summary:hover { color: var(--text-strong); }
details[open] summary { margin-bottom: .4rem; font-weight: 550; }
details .stack { margin: .3rem 0 .6rem; }

.result {
  display: flex;
  flex-wrap: wrap;
  gap: .1rem .6rem;
  align-items: baseline;
  padding: .3rem 0;
  border-bottom: 1px solid var(--line);
}

.result:last-child { border-bottom: 0; }

/* ---------------------------------------------------------- 11. Responsive */

@media (max-width: 1100px) {
  .panorama { grid-template-columns: 1fr; }
  .grid.cols-4 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}

@media (max-width: 860px) {
  /* The rail becomes a strip across the top: brand and person on one line, the
     links scrolling sideways under them. A 248px column is a third of a phone. */
  .app { flex-direction: column; }

  .sidebar {
    width: 100%;
    height: auto;
    position: static;
    flex-direction: row;
    flex-wrap: wrap;
    align-items: center;
    border-right: 0;
    border-bottom: 1px solid var(--rail-line);
  }

  .sidebar .brand { flex: 1; border-bottom: 0; padding: .6rem .8rem; }
  .sidebar-user { border-top: 0; padding: .6rem .8rem; }
  .sidebar-user-words { display: none; }

  .nav-scroll {
    order: 3;
    /* flex, not width: the desktop rule sets `flex: 1`, whose flex-basis of 0
       wins over any width and kept the links on the brand's row, running off
       the side of the screen. */
    flex: 0 0 100%;
    width: 100%;
    display: flex;
    gap: .2rem;
    overflow-x: auto;
    overflow-y: hidden;
    padding: .25rem .6rem .5rem;
    border-top: 1px solid var(--rail-line);
  }
  .sidebar a { flex: none; padding: .35rem .6rem; font-size: .85rem; }

  /* Headings would each take a whole column of a sideways strip. */
  .sidebar .group { display: none; }

  /* Collapsing belongs to a column, not a strip. */
  #sidebar-toggle { display: none; }
  .sidebar-collapsed .sidebar { width: 100%; }
  .sidebar-collapsed .sidebar a > span,
  .sidebar-collapsed .brand-words { display: inline; }

  .topbar { flex-wrap: wrap; gap: .5rem; }
  .topbar-title { flex: 1 1 auto; }
  .topbar-company { display: none; }

  .content, .topbar { padding: 1rem; }

  .grid.cols-2, .grid.cols-3, .grid.cols-4 { grid-template-columns: 1fr; }

  /* Wide tables scroll rather than squeezing every column to nothing. */
  .card > table, .panel > table { display: block; overflow-x: auto; white-space: nowrap; }

  .pipeline-col { flex: 0 0 82vw; }
  .filters { flex-direction: column; align-items: stretch; }

  /* One column of permissions on a phone, and the search box on its own line
     rather than squeezed between the page title and the sign-out button. */
  .matrix { grid-template-columns: 1fr; }
  .searchbox { order: 3; flex-basis: 100%; max-width: none; margin: .6rem 0 0; }
  .tabs { overflow-x: auto; flex-wrap: nowrap; }
  .tabs a { white-space: nowrap; }
}

@media (max-width: 520px) {
  body { font-size: 14px; }
  h1 { font-size: 1.3rem; }
  .stat .value, .stat-value { font-size: 1.4rem; }
  .card { padding: 1rem; border-radius: var(--radius-sm); }
}

/* --------------------------------------------------------------- 12. Print
   Invoices, receipts, owner statements and the rent roll are handed to people.
   On paper the navigation is noise and the colour is a waste of toner. */

@media print {
  :root {
    --bg: #FFFFFF; --surface: #FFFFFF; --surface-2: #FFFFFF; --zebra: #FFFFFF;
    --text: #000000; --text-strong: #000000; --muted: #333333; --faint: #555555;
    --line: #BBBBBB; --line-strong: #777777;
  }

  body { background: #fff; color: #000; font-size: 11pt; }

  .sidebar, .topbar, .breadcrumb, .filters, .btn, form, .flash, .steps,
  .tabs, .searchbox { display: none !important; }

  .app { display: block; }
  .content { padding: 0; }
  .card, .panel, .stat { border: 0; padding: 0; margin: 0 0 1rem; break-inside: avoid; }

  table { font-size: 10pt; }
  thead { display: table-header-group; }    /* repeat headings across pages */
  tr { break-inside: avoid; }
  tbody tr:hover td { background: none; }

  /* A tinted label prints as grey mush; outline it instead. */
  .pill, .badge { background: none !important; color: #000 !important; border: 1px solid #777; }

  a { color: #000; text-decoration: none; }
  /* Where a link's destination matters on paper, show it. */
  .content a[href^="http"]::after { content: " (" attr(href) ")"; font-size: 9pt; color: #555; }
}


/* ---------------------------------------------- 12. Surveyed boundaries */

/* The estate drawn from its boundary markers. Plain SVG built in PHP: there is
   no build step here and no map tiles to fetch on a Cameroonian connection, so
   the plan is part of the page rather than something the browser goes and gets. */
/* `max-height` as well as `width`, and the max-height is the one that matters.

   `width: 100%` alone means the drawing is as wide as whatever contains it and
   as tall as its own proportions then demand. Inside the signed-in shell the
   sidebar keeps that honest; on a public page on a wide monitor it drew the
   estate at nineteen hundred pixels across and taller than the screen, with
   corner labels to match, because an SVG with a viewBox scales its text too.

   The default `preserveAspectRatio` letterboxes rather than distorts, so a tall
   parcel scales down and centres instead of being squashed — a plan stretched
   to fill its box is a plan of a different piece of land. */
.boundary-plan {
  width: 100%;
  height: auto;
  max-height: 70vh;
  display: block;
  margin: .2rem 0 .8rem;
}
.boundary-shape {
  fill: var(--accent);
  fill-opacity: .10;
  stroke: var(--accent);
  stroke-width: 2;
  stroke-linejoin: round;
}
.boundary-marker { fill: #fff; stroke: var(--accent); stroke-width: 2; }
.boundary-label { font-size: 11px; fill: var(--muted); font-weight: 550; }
.boundary-north line, .boundary-scale line { stroke: var(--muted); stroke-width: 1.5; }
.boundary-north polygon { fill: var(--muted); }
.boundary-north text, .boundary-scale text { font-size: 10px; fill: var(--muted); }

/* A heading that introduces a run of cards — the portfolio page's two halves,
   land and lettings. Sits outside the cards, so it needs its own spacing. */
.section-heading { font-size: 1.05rem; margin: 1.4rem 0 .7rem; color: var(--text-strong); }
.section-heading:first-child { margin-top: 0; }

/* The vertex table: one row per surveyed corner, entered one at a time. Dense on
   purpose — a ten-corner plot should fit on a screen beside its own plan. */
.vertex-table { width: 100%; font-size: .85rem; }
.vertex-table th, .vertex-table td { padding: .2rem .3rem; }
.vertex-table input {
  width: 100%;
  min-width: 4rem;
  padding: .25rem .35rem;
  font-size: .85rem;
  margin: 0;
}
.vertex-table .row-actions { white-space: nowrap; text-align: right; }
.vertex-table .row-actions .btn { padding: .1rem .35rem; margin-left: .15rem; line-height: 1.3; }

/* A row whose coordinates could not be read. It keeps the text the operator
   typed — losing nine good rows because the tenth has a typo is the failure this
   whole screen exists to avoid — and says why underneath. */
.vertex-table .row-bad input { border-color: var(--red); background: var(--red-tint); }
.vertex-table .row-bad-note td { color: var(--red); padding-top: 0; padding-bottom: .4rem; }

/* Several surveyed shapes on one drawing: a phase outline with its plots inside,
   each in its status colour. */
/* The live plot map. Sized like the other two figures, and for the same reason:
   its viewBox grows a row at a time, so a phase with many blocks drew a map
   taller than the screen on any container wide enough to allow it. */
.plot-map {
  width: 100%;
  height: auto;
  max-height: 75vh;
  display: block;
}

.site-plan {
  width: 100%;
  height: auto;
  max-height: 70vh;      /* see .boundary-plan */
  display: block;
  margin: .2rem 0 .6rem;
}
.site-shape {
  stroke: #fff;
  stroke-width: 1.2;
  stroke-linejoin: round;
  fill-opacity: .85;
  cursor: pointer;
}
.site-shape:hover { fill-opacity: 1; stroke: var(--text-strong); }
.site-plan a:focus-visible .site-shape { stroke: var(--text-strong); stroke-width: 2.5; }

/* The containing phase or estate: an edge, not a fill, so the plots inside it
   are what the eye reads. */
.site-outline { fill: none; stroke: var(--accent); stroke-width: 2; stroke-dasharray: 6 4; cursor: default; }
.site-label { font-size: 10px; fill: #fff; text-anchor: middle; font-weight: 600; pointer-events: none; }

/* Clicking a plot's corners out against the block. The hooks the picker script
   binds to are classes, so they are declared here even where they carry no style
   of their own — a class the stylesheet has never heard of is a typo more often
   than it is a decision. */
.picker-plan { width: 100%; height: auto; display: block; cursor: crosshair; margin-bottom: .6rem; }
.picker-marker { fill: #fff; stroke: var(--accent); stroke-width: 2; }
.picker-marker:hover { fill: var(--accent); }

/* Plots already defined: visible, so a new one is clicked out beside them rather
   than on top of them, but quiet enough not to compete with the one being made. */
.picker-taken { fill: var(--line); fill-opacity: .55; stroke: var(--line-strong); stroke-width: 1; }

.picker-outline { fill: var(--accent); fill-opacity: .18; stroke: var(--accent); stroke-width: 2; }
.picker-pick { fill: var(--accent); stroke: #fff; stroke-width: 1.5; }
.picker-pick-label { font-size: 11px; fill: var(--text-strong); stroke: none; font-weight: 600; }

.picker-list { margin: .4rem 0; font-variant-numeric: tabular-nums; }
.picker-list li { padding: .1rem 0; }
.picker-area, .picker-corners { font-weight: 600; color: var(--text-strong); }
.picker-free { color: var(--amber); }
/* ------------------------------------------------------ The way mapper

   Drawing a road down its middle. The reserve is previewed under the draft line
   as it is clicked, so the shape is visible before it is saved — and shown in red
   when it folds through itself, which is the one outcome worth stopping for.
   ------------------------------------------------------------------------ */

.way-plan { width: 100%; height: auto; display: block; margin: .5rem 0 .75rem; }

/* Everything already on the plan, drawn in its land-use colour (set inline,
   because a palette token in an SVG fill attribute renders as nothing). */
.way-existing { stroke: var(--line-strong); stroke-width: 1; }
.way-existing-linear { stroke-dasharray: none; opacity: .9; }

/* The centrelines of the ways already drawn: the thing that was designed, down
   the middle of the thing that followed from it. */
.way-centre {
  fill: none;
  stroke: var(--amber);
  stroke-width: 1.5;
  stroke-dasharray: 7 4;
  opacity: .85;
}

/* The line being clicked now, and the reserve it would produce.

   The draft is drawn exactly like a saved way's centreline — amber, dashed —
   because that is what it is. Drawn in the accent colour it merged with the
   reserve's own outline and the two read as one thick line, which hides the
   relationship the whole screen exists to show: you click the middle, the width
   makes the edges. */
.way-draft { fill: none; stroke: var(--amber); stroke-width: 2; stroke-dasharray: 7 4; }
.way-preview { fill: var(--accent-tint); stroke: var(--accent); stroke-width: 2; }
.way-preview-bad { fill: var(--red-tint); stroke: var(--red); }

.way-point { fill: var(--accent); }
.way-point-label { font-size: 10px; font-weight: 600; fill: var(--text-strong); }

.way-list li { padding: .1rem 0; }
.way-points, .way-length, .way-area { font-weight: 600; color: var(--text-strong); }
.way-folds { color: var(--red); }

.way-field, .way-kind, .way-width, .way-undo, .way-clear { /* script hooks */ }

/* A neighbour's corner is not a peg, and must not look like one.

   The surveyed markers are round and filled; these are hollow squares in the
   amber the rest of the interface uses for "proceed with your eyes open". The
   difference has to survive a phone screen in daylight, which is why it is shape
   as well as colour — a mapper standing on the land is the person who most needs
   to know which of the two they are about to take. */
.picker-marker-shared {
  fill: var(--amber-tint);
  stroke: var(--amber);
  stroke-width: 2.5;
}
.picker-marker-shared:hover { fill: var(--amber); }

.picker-tally { margin-top: .35rem; }
.picker-tally strong { color: var(--text-strong); font-weight: 600; }

/* The confirmation, which only appears once a neighbour's corner is in the shape.
   It inherits .flash.warn, so this only has to hold the parts together. */
.picker-shared-confirm { margin-bottom: .75rem; }
.picker-shared-confirm > p:first-child { margin: 0 0 .5rem; font-weight: 600; }
.picker-shared-what { color: var(--text-strong); }

.picker-snap, .picker-field, .picker-undo, .picker-clear,
.picker-snap-shared, .picker-shared-tick, .picker-shared-reason { /* script hooks */ }

/* ------------------------------------------- Occupancy tiles, laid out properly

   A tile is 248px wide and has five things to say, so the old arrangement — five
   lines of the same size, one of them a link coloured like the rest — read as a
   paragraph rather than a card. This gives it one line that matters (the unit and
   its rent, on one row, the rent right-aligned so a column of tiles can be
   scanned down), and everything else quieter beneath it.

   Every line clips rather than wraps. "Buea Hills Commercial (sample)" wrapping to
   three lines is what made the board twice as tall as it needed to be and pushed
   tiles out of their columns. */
.deal-head {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: .5rem;
  margin-bottom: .15rem;
}
.deal-head strong {
  color: var(--text-strong);
  font-size: .88rem;
  line-height: 1.25;
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.deal-rent {
  flex: 0 0 auto;
  font-size: .8rem;
  font-variant-numeric: tabular-nums;
  color: var(--text-strong);
}
.deal-sub {
  font-size: .76rem;
  color: var(--muted);
  line-height: 1.35;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.deal-tenant {
  font-size: .8rem;
  font-weight: 550;
  color: var(--text);
  margin-top: .15rem;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

/* ------------------------------------------------------- The party number

   A contact's number travels with their name everywhere. It has to be readable
   and it must not compete with the name, so: monospaced (a reference is read
   character by character, not as a word), one step smaller, muted, and on its own
   line when the name is a block — which is why it is inline-block rather than
   inline. */
.party-ref {
  display: inline-block;
  font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  font-size: .72rem;
  letter-spacing: .01em;
  color: var(--muted);
  background: var(--surface-2, #FAFAFA);
  border: 1px solid var(--line);
  border-radius: 3px;
  padding: 0 .3rem;
  margin-left: .35rem;
  vertical-align: baseline;
  white-space: nowrap;
}
td .party-ref, .deal .party-ref { margin-left: 0; margin-top: .15rem; }
.party-ref-large { font-size: .9rem; padding: .15rem .45rem; margin-left: 0; color: var(--text-strong); }

/* The row under a dependent that opens into its editor. Quiet until opened —
   a table with an edit form permanently under every row is not a table. */
.row-editor > td { border-top: 0; padding-top: 0; }
.row-editor summary { cursor: pointer; color: var(--accent); }
.row-editor details[open] summary { margin-bottom: .5rem; }

/* The feature runner's output, read on a phone as often as on a desktop. */
.test-output {
  background: var(--surface-2, #FAFAFA);
  border: 1px solid var(--line);
  border-radius: var(--radius-sm);
  padding: .7rem .8rem;
  font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  font-size: .76rem;
  line-height: 1.5;
  max-height: 26rem;
  overflow: auto;
  white-space: pre-wrap;
  word-break: break-word;
}

/* Removing a stray company: folded away, because it is the one action on the
   update page that only a backup undoes. */
.stray-remove { margin-top: .75rem; border-top: 1px solid var(--line); padding-top: .6rem }
.stray-remove > summary { cursor: pointer; color: var(--red); font-weight: 600 }
.stray-remove > summary::marker { color: var(--red) }
.stray-remove .stack { margin-top: .5rem; max-width: 26rem }
.stray-remove input { width: 100% }

/* Receivables ageing.

   The table is seven columns of money and does not fit a phone, so it scrolls
   sideways inside its card rather than pushing the page wider — and the totals
   are repeated above it as tiles, because the one figure most people came for is
   the oldest column and it is the one furthest off-screen. */
.table-scroll { overflow-x: auto; -webkit-overflow-scrolling: touch }
.table-scroll > table { min-width: 44rem }

.ageing-totals { display: flex; flex-wrap: wrap; gap: .5rem }
.ageing-total {
  flex: 1 1 8rem; display: flex; flex-direction: column; gap: .15rem;
  padding: .6rem .7rem; border: 1px solid var(--line); border-radius: 8px;
  background: var(--surface);
}
.ageing-total strong { font-variant-numeric: tabular-nums; font-size: 1.05rem }
.ageing-total.is-oldest { border-color: var(--red); }
.ageing-total.is-oldest strong { color: var(--red) }
.ageing-total.is-total { border-color: var(--line-strong); }

td.is-late { color: var(--red) }

/* The brought-forward line on a statement. Set apart from the movements below
   it, because it is the one line that is not something that happened. */
.statement-opening > td { background: var(--surface-2); font-style: italic }

/* A row of buttons at the foot of a form: the action and the way out of it. */
.actions { display: flex; flex-wrap: wrap; gap: .5rem; align-items: center }

/* ------------------------------------------------------- 11b. Documents

   A page laid out for paper: an invoice, a receipt, a statement. The browser's
   own Save as PDF is the export, because no PDF library can be installed on this
   host — so the print rules below are not a nicety, they are the file format. */

.document-page { background: var(--surface-2); padding: 1.5rem 1rem 3rem; }

.doc-toolbar {
  display: flex; flex-wrap: wrap; gap: .6rem; align-items: center;
  max-width: 190mm; margin: 0 auto 1rem;
}

.doc {
  display: block;
  max-width: 190mm;
  margin: 0 auto;
  padding: 16mm 14mm;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: 4px;
}

.doc-head { display: flex; justify-content: space-between; gap: 2rem; align-items: flex-start; margin-bottom: 2rem; }
.doc-issuer { display: flex; gap: .8rem; font-size: .86rem; line-height: 1.45; }
.doc-issuer strong { font-size: 1rem; }
.doc-logo { max-height: 52px; max-width: 120px; object-fit: contain; }
.doc-legal { margin-top: .3rem; color: var(--muted); font-size: .78rem; }
.doc-legal span + span::before { content: " · "; }

.doc-mast { text-align: right; flex: none; }
.doc-mast h1 {
  margin: 0; font-size: 1.4rem; font-weight: 680;
  letter-spacing: .02em; text-transform: uppercase; color: var(--text-strong);
}
.doc-number { font-weight: 620; font-size: 1rem; }

.doc-parties { display: flex; gap: 2.5rem; margin-bottom: 1.5rem; }
.doc-parties > div { flex: 1; font-size: .88rem; line-height: 1.5; }
.doc-label {
  display: block; font-size: .7rem; font-weight: 650; text-transform: uppercase;
  letter-spacing: .06em; color: var(--muted); margin-bottom: .2rem;
}

.doc-table { width: 100%; border-collapse: collapse; font-size: .88rem; margin-bottom: 1.25rem; }
.doc-table th, .doc-table td { padding: .45rem .5rem; text-align: left; }
/* A figure broken across two lines reads as two figures. */
.doc-table .num, .doc-amount strong { white-space: nowrap; }
.doc-table thead th.num, .doc-table tbody td.num, .doc-table tfoot td.num, .doc-table tfoot th.num { text-align: right; }
.doc-table thead th { border-bottom: 1.5px solid var(--text); font-size: .74rem; text-transform: uppercase; letter-spacing: .05em; }
.doc-table tbody td { border-bottom: 1px solid var(--line); }
.doc-table tfoot th, .doc-table tfoot td { border-top: 1px solid var(--line); }
.doc-table tfoot tr.doc-total th, .doc-table tfoot tr.doc-total td {
  border-top: 1.5px solid var(--text); font-size: 1rem; font-weight: 680; padding-top: .55rem;
}

.doc-amount {
  margin: 0 0 1.25rem; padding: .7rem .9rem;
  border: 1.5px solid var(--text); border-radius: 4px;
}
.doc-amount strong { font-size: 1.35rem; font-variant-numeric: tabular-nums; }

.doc-foot {
  display: flex; justify-content: space-between; align-items: flex-end; gap: 2rem;
  margin-top: 2.5rem; padding-top: 1rem; border-top: 1px solid var(--line);
}
.doc-verify { display: flex; gap: .7rem; align-items: center; }
.doc-verify svg { flex: none; }
.doc-issued { text-align: right; }

@media print {
  /* The page becomes the document: no toolbar, no card, no margins of our own —
     the printer's own margins are the only ones that are real. */
  .document-page { background: #fff; padding: 0; }
  .doc-toolbar { display: none !important; }
  .doc { max-width: none; margin: 0; padding: 0; border: 0; border-radius: 0; }
  .doc-table thead { display: table-header-group; }
  .doc-table tr { break-inside: avoid; }
  .doc-foot { break-inside: avoid; }
  @page { margin: 14mm; }
}

@media (max-width: 720px) {
  .doc { padding: 1.2rem 1rem; }
  .doc-head, .doc-parties, .doc-foot { flex-direction: column; gap: 1rem; }
  .doc-mast, .doc-issued { text-align: left; }

  /* A document is a print object; on a phone it only has to be readable. The
     sale agreement's property table is five columns wide — plot, estate, area,
     title reference, price — and at 390px it pushed the page 52px sideways.
     Tighter, smaller, and long references fold rather than widen the table. The
     figures still refuse to break, because a figure split across two lines reads
     as two figures. */
  .doc-table { font-size: .78rem; }
  .doc-table th, .doc-table td { padding: .32rem .28rem; overflow-wrap: anywhere; }
}

/* ------------------------------------------------------- 13. Verdicts

   The scan pages: `/verify/{token}` for a document and for a badge at a gate.

   Read standing up, on a phone held at arm's length, by somebody with about a
   second of attention. So the answer is the largest thing on the page, and the
   three states differ by *shape* as well as colour — a tick, a bar and a cross
   — because roughly one man in twelve cannot separate the green from the red by
   hue, and a barrier in full sun flattens the difference for everybody else.

   The banner is a tint with coloured ink, not a solid fill with white text. A
   solid fill is stronger in the light scheme and impossible in the dark one,
   where `--green` is a pale mint that white text disappears into — the same
   mistake milestone 8 found on the accent colour. Tint and ink are defined as a
   pair per scheme, so this holds in both. */

.verify-page { max-width: 31rem; margin: 0 auto; }

.verdict {
  display: flex;
  /* Top-aligned, not centred. Centred looked right against a one-line reason
     and wrong against a three-line one, where the mark drifted down beside the
     middle of the paragraph instead of sitting next to the word it qualifies. */
  align-items: flex-start;
  gap: .9rem;
  padding: 1.05rem 1.15rem;
  margin-bottom: 1rem;
  border: 1px solid;
  border-left-width: 6px;
  border-radius: var(--radius);
}

/* Geometry only in the sprite, weight here — same arrangement as `.icon`, at a
   size no icon in the set is ever used at. */
.verdict-mark {
  flex: none;
  /* Half a line, so the circle's centre lands on the cap height of the word
     beside it rather than on its baseline. */
  margin-top: .12rem;
  width: 2.6rem;
  height: 2.6rem;
  fill: none;
  stroke: currentColor;
  stroke-width: 2;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.verdict-text { min-width: 0; }
.verdict-word { display: block; font-size: 1.3rem; line-height: 1.15; letter-spacing: -.01em; }
/* The reason reverts to body ink: it is a sentence, and a sentence set in the
   verdict colour reads as more alarm rather than more information. */
.verdict-why { display: block; margin-top: .15rem; color: var(--text); font-size: .92rem; }

.verdict-ok   { background: var(--green-tint); border-color: var(--green); color: var(--green); }
.verdict-warn { background: var(--amber-tint); border-color: var(--amber); color: var(--amber); }
.verdict-bad  { background: var(--red-tint);   border-color: var(--red);   color: var(--red); }

.verify-kind {
  margin: 0 0 .1rem;
  font-size: .72rem;
  text-transform: uppercase;
  letter-spacing: .08em;
  color: var(--muted);
}
.verify-name { margin: 0 0 .9rem; font-size: 1.45rem; line-height: 1.2; overflow-wrap: anywhere; }
/* The one card on a scan page. Its bottom margin goes, because the footer line
   below supplies the only gap the page needs and a card floating above a
   centred caption reads as an unfinished layout. */
.verify-card { margin-bottom: 0; }
.verify-foot { margin-top: 1.1rem; text-align: center; }

/* --------------------------------------------------------- 14. Gate passes

   A printed badge: 86 × 54mm, an ID-1 card on its side, which is what the
   lanyard pouches sold locally take. The dimensions are in millimetres and not
   in rems on purpose — this one is measured against a physical object, so a
   reader who has scaled their font up must not get a badge that no longer fits
   the pouch.

   Named `pass-*` and not `badge-*`. `.badge` was taken: it is the filled status
   pill at section 7, used on the pipeline, the catalogue and the invoice list.
   The first draft of this block reused the name and, being later in the file,
   won on background and border while silently inheriting `font-weight: 600` and
   `font-size: .7rem` from it — so every line on the card printed semibold at the
   wrong size, and the cause was two hundred lines away. Same failure as the
   stale `.searchbox` rule milestone 8 found, and the same fix: do not share a
   name with something that is not the same thing.

   The colours are fixed rather than themed, and the scheme is pinned to light in
   the markup. A badge is ink on card; it is not going to follow a reader's dark
   mode, and a themed token would mean a pass printed on a navy installation
   coming out in a colour nobody chose. */

.pass-sheet { display: flex; flex-wrap: wrap; gap: 6mm; }

.pass-card {
  width: 86mm;
  min-height: 54mm;
  box-sizing: border-box;
  display: flex;
  gap: 4mm;
  padding: 5mm;
  background: #fff;
  color: #111;
  border: 1px solid #bbb;
  border-radius: 3mm;
  font-size: 9pt;
  font-weight: 400;
  break-inside: avoid;
}

/* The photograph. Fixed in millimetres like the card itself, and cropped to
   fill rather than letterboxed — a passport photo and a phone snap arrive in
   different proportions and both have to end up the same size on the card. */
.pass-photo {
  flex: none;
  width: 18mm;
  height: 23mm;
  object-fit: cover;
  border: 1px solid #ccc;
  border-radius: 1mm;
}

.pass-body { flex: 1 1 auto; min-width: 0; display: flex; flex-direction: column; }
.pass-issuer { font-size: 6.5pt; font-weight: 600; text-transform: uppercase; letter-spacing: .06em; color: #555; }
.pass-name { margin: 1.2mm 0 0; font-size: 12pt; font-weight: 700; line-height: 1.12; overflow-wrap: anywhere; }
.pass-role { margin-top: .8mm; font-size: 8pt; color: #333; }
.pass-meta { margin-top: auto; padding-top: 2mm; font-size: 7pt; color: #444; }
.pass-meta div { margin-top: .7mm; }

/* Fixed to the code's own width. Left to size itself, the caption underneath is
   wider than the code and stretches this column, which at 86mm comes straight
   out of the name beside it — the first render lost a third of the name to a
   four-word hint. */
.pass-qr { flex: none; width: 24mm; display: flex; flex-direction: column; align-items: center; gap: 1mm; }
.pass-qr svg { display: block; width: 24mm; height: 24mm; }
.pass-hint { font-size: 5pt; line-height: 1.2; text-align: center; color: #777; }

/* A withdrawn or expired pass still prints, because somebody may need the card
   back in order to destroy it. It does not print looking valid. */
.pass-card.pass-void { border-color: #999; }
.pass-card.pass-void .pass-name { text-decoration: line-through; }
.pass-void-mark { margin-top: 1mm; font-size: 7.5pt; font-weight: 700; color: #b00; text-transform: uppercase; }

@media print {
  .pass-sheet { gap: 4mm; }
  .pass-card { border-color: #999; }
  @page { margin: 8mm; }
}

@media (max-width: 480px) {
  /* The card is a print object; on a phone it only has to be legible, so it
     stops being 86mm wide and becomes the column. */
  .pass-card { width: 100%; }
  .verdict { padding: .9rem; gap: .7rem; }
  .verdict-mark { width: 2.1rem; height: 2.1rem; }
  .verdict-word { font-size: 1.15rem; }
}

/* --------------------------------------------------- 15. Evidence rows

   A checklist item and the paper behind it: the parcel's due diligence, a
   contact's KYC. One set of rules for both, because two screens asking for
   evidence in two different shapes is how they drift until only one of them is
   the good one.

   The upload control is a <details>, not a dialog. A dialog would need script
   to open, to trap focus and to close, would be reimplemented eleven times on
   the parcel screen, and would break the one thing that page has to do on a bad
   connection: submit. A disclosure opens with no script at all and leaves the
   form working if nothing loads. */

.evidence-row {
  padding: .6rem 0 .7rem;
  border-bottom: 1px solid var(--line);
}
.evidence-row:last-of-type { border-bottom: 0; }

/* Met rows recede. The eye should land on what is still outstanding, which is
   the only reason somebody opens this screen.

   The pills are excluded, and that exclusion is the whole subtlety. Without it
   `color: inherit` on the span reached into `.pill-red`, which kept its pink
   background and lost its red ink — so a satisfied blocking check rendered grey
   text in a pink capsule and read as a rendering fault rather than as a
   decision. Found by looking at it. */
.evidence-row.is-met > .check,
.evidence-row.is-met > .check > span { color: var(--muted); }
/* Restated rather than reverted: `revert` goes back to the browser default, not
   to the rule this one outranks, which is how the first attempt at this fix
   produced the same grey text it was written to stop. */
.evidence-row.is-met > .check .pill-red { color: var(--red); }
.evidence-row.is-met > .check .pill-amber { color: var(--amber); }
.evidence-row.is-met > .check .pill-green { color: var(--green); }

.evidence-note { margin: .2rem 0 0 1.65rem; }

.evidence-files { list-style: none; margin: .45rem 0 0 1.65rem; padding: 0; }
.evidence-files li {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: .5rem;
  padding: .3rem 0;
  font-size: .88rem;
}
.evidence-files a { display: inline-flex; align-items: center; gap: .35rem; }
/* An expired document still shows — somebody has to see that it is the one on
   file — but it does not read as current. */
.evidence-files li.is-expired a { color: var(--muted); text-decoration: line-through; }

.evidence-add { margin: .4rem 0 0 1.65rem; }
.evidence-add > summary { color: var(--accent); cursor: pointer; }
.evidence-add[open] > summary { margin-bottom: .4rem; }

/* A one-button form sitting inside a row of other things. Without this it takes
   a line of its own and the row becomes two. */
.inline-form { display: inline; margin: 0; }

/* The company logo on the settings screen. Bounded in both directions so a
   5000-pixel scan does not take over the page and a tiny one is not stretched
   into mush — the letterhead sizes it separately for paper. */
.logo-preview {
  max-width: 220px;
  max-height: 90px;
  width: auto;
  height: auto;
  background: #fff;
  padding: .35rem;
  border: 1px solid var(--line);
  border-radius: var(--radius-sm);
}

@media (max-width: 480px) {
  .evidence-note, .evidence-files, .evidence-add { margin-left: 0; }
}

/* ------------------------------------------------------ 16. Contracts

   The four documents people sign: a reservation form, a sale agreement, an
   allocation letter and a tenancy agreement. They share the document layout
   from milestone 10; what is here is the part only a contract needs. */

/* The watermark (SRS DOC-008).

   Real text, not a background image. A browser prints background graphics only
   when the reader has turned that option on, and a watermark that disappears on
   exactly the copies that get printed is worse than none — it teaches people the
   unmarked ones are the real thing.

   `fixed` so it repeats on every page of a multi-page agreement instead of
   appearing once at the top, and `pointer-events: none` so it never swallows a
   click on the text beneath it. */
.doc-watermark {
  position: fixed;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%) rotate(-32deg);
  font-size: 5.5rem;
  font-weight: 700;
  letter-spacing: .25em;
  text-transform: uppercase;
  color: rgba(185, 28, 28, .13);
  white-space: nowrap;
  pointer-events: none;
  user-select: none;
  z-index: 1;
}

/* The content sits above it, so the mark reads as a watermark rather than as
   something printed over the terms. */
.doc > *:not(.doc-watermark) { position: relative; z-index: 2; }

.doc-h {
  /* Never last on a page. Printing the agreement put TERMS AND CONDITIONS alone
     at the foot of page one with its clauses overleaf, which reads as a heading
     for nothing. */
  break-after: avoid;
  break-inside: avoid;
  margin: 1.4rem 0 .5rem;
  font-size: .95rem;
  text-transform: uppercase;
  letter-spacing: .07em;
  border-bottom: 1px solid var(--line);
  padding-bottom: .25rem;
}

.doc-amount-words { margin: .6rem 0 0; font-size: .92rem; }

/* The platform's own sentence under the company's clauses — that this is not
   the deed, that a balance is outstanding. Set apart deliberately: printed, the
   deed note followed clause 5 with no break at all and read as a sixth clause,
   which puts words into the lawyer's mouth. */
.doc-note-own {
  margin-top: 1rem;
  padding-top: .7rem;
  border-top: 1px solid var(--line);
  font-size: .85rem;
  font-style: italic;
}

/* The company's own wording. Pre-wrap, because it is prose typed into a
   textarea and the paragraph breaks somebody put in are part of what they
   wrote. Justified and tightly leaded, which is what a contract looks like. */
.doc-clauses {
  white-space: pre-wrap;
  font-size: .88rem;
  line-height: 1.55;
  text-align: justify;
}

/* An agreement with no clauses, or a letter whose balance is outstanding: said
   on the face of the document rather than quietly left out. */
.doc-missing {
  border-left: 3px solid var(--amber);
  background: var(--amber-tint);
  padding: .6rem .8rem;
  font-size: .9rem;
  border-radius: var(--radius-sm);
}

/* ------------------------------------------------------------ signatures */

.doc-signatures { margin-top: 1.8rem; break-inside: avoid; }

.sign-grid { display: flex; gap: 2rem; margin-top: .6rem; }
.sign-block { flex: 1 1 0; min-width: 0; }
.sign-role { display: block; font-size: .72rem; text-transform: uppercase; letter-spacing: .07em; color: var(--muted); }
.sign-name { display: block; margin-top: .15rem; }

/* "Done at ……" and "On ……", with a rule to write on. The blanks are deliberate:
   a pre-printed date on a contract actually signed a fortnight later is a wrong
   fact sitting in the party's own handwriting space. */
.sign-line { display: flex; align-items: baseline; gap: .4rem; margin-top: .5rem; font-size: .85rem; }
.sign-line .rule { flex: 1 1 auto; border-bottom: 1px dotted #999; height: .9em; }

.sign-space {
  margin-top: 1.4rem;
  padding-top: 1.6rem;
  border-top: 1px solid #999;
  font-size: .75rem;
}

/* ---------------------------------------------------------------- letters */

.doc-letter-to { margin: 0 0 1.2rem; }
.doc-letter-sign { margin-top: 2rem; max-width: 16rem; }

/* A clause box is typed into, not read from. Monospace keeps numbered clauses
   lining up while somebody is editing them.

   The stack is written out rather than read from a custom property: there is no
   `--mono` token in this stylesheet, and `var(--mono, …)` would have *looked*
   like it used one while silently always taking the fallback. view-check
   refuses a var() with a fallback for exactly that reason. */
.mono-input {
  font-family: ui-monospace, "SF Mono", Menlo, Consolas, "Liberation Mono", monospace;
  font-size: .85rem;
  line-height: 1.5;
}

@media print {
  /* Fixed positioning is per-page in print, which is exactly what a watermark
     wants — but the colour has to survive a printer driver that drops light
     greys, so it is darkened for paper. */
  .doc-watermark { color: rgba(185, 28, 28, .18); }
  .doc-signatures { break-inside: avoid; }
}

@media (max-width: 720px) {
  .sign-grid { flex-direction: column; gap: 1.5rem; }
  .doc-watermark { font-size: 3rem; }
}

/* ------------------------------------------------------------------ platform

   The operator layer (milestone 15.1): the impersonation banner, and the
   plain shell its own screens use.

   The banner is deliberately loud. It is the only thing standing between an
   operator who has forgotten they are somebody else and a journal posted in
   that company's books under that person's name — so it is full width, it is
   amber, it sits above the content on every page, and it carries its own way
   out rather than making somebody find one. */
.impersonating {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  flex-wrap: wrap;
  padding: .55rem 1.25rem;
  background: var(--amber-tint);
  color: var(--amber);
  border-bottom: 1px solid var(--amber);
  font-size: .86rem;
  font-weight: 550;
}
.impersonating form { margin: 0; }

/* The operator's own shell. No sidebar: these are four screens, and a
   navigation rail for four screens is furniture. A header with the two links
   it needs is the whole chrome. */
.platform-shell { max-width: 1100px; margin: 0 auto; padding: 1.5rem 1.25rem 3rem; }
.platform-head {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 1rem;
  flex-wrap: wrap;
  padding-bottom: .9rem;
  margin-bottom: 1.4rem;
  border-bottom: 1px solid var(--line);
}
.platform-head nav { display: flex; align-items: center; gap: .9rem; font-size: .88rem; }
.platform-head form { margin: 0; }
.platform-mark { font-size: 1.15rem; font-weight: 600; }
.platform-mark small { display: block; font-weight: 400; font-size: .76rem; color: var(--muted); }

/* Usage figures, read across. A tabular-numbers column so eleven companies'
   plot counts line up as digits rather than as text. */
.usage-n { text-align: right; font-variant-numeric: tabular-nums; }

@media (max-width: 720px) {
  .impersonating { padding: .55rem .9rem; }
  .platform-shell { padding: 1.1rem .9rem 2.5rem; }
}

/* ------------------------------------------------------------ pagination */

/* Replaces Laravel's shipped controls, which are Tailwind markup: their
   previous/next SVGs are sized only by `w-5 h-5`, so against this stylesheet
   they rendered at their intrinsic size and every paginated screen drew a navy
   chevron the height of the page. Text controls instead — they say what they
   do, they translate, and they cannot grow. */
.pagination {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  flex-wrap: wrap;
  margin-top: 1.1rem;
}

.pagination-links { display: flex; align-items: center; gap: .3rem; flex-wrap: wrap; }

.pagination-step,
.pagination-page {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 2.1rem;
  height: 2.1rem;
  padding: 0 .6rem;
  border: 1px solid var(--line);
  border-radius: .4rem;
  background: var(--surface);
  color: var(--text);
  font-size: .86rem;
  font-variant-numeric: tabular-nums;
  text-decoration: none;
}

.pagination-step:hover,
.pagination-page:hover { border-color: var(--line-strong); background: var(--surface-2); }

.pagination-page.is-current {
  background: var(--accent);
  border-color: var(--accent);
  color: var(--accent-on);
  font-weight: 600;
}

.pagination-step.is-disabled {
  color: var(--faint);
  background: var(--surface-2);
  cursor: default;
}

.pagination-gap { padding: 0 .25rem; color: var(--faint); }

@media (max-width: 720px) {
  /* The page numbers go; previous and next are what a thumb uses. */
  .pagination-page:not(.is-current),
  .pagination-gap { display: none; }
}

/* The "showing 51 to 100 of 812" line beside the controls. Its own class so it
   can leave the flow on a narrow screen without taking the controls with it. */
.pagination-count { margin: 0; }

@media (max-width: 720px) {
  .pagination { justify-content: center; }
  .pagination-count { width: 100%; text-align: center; }
}

/* The key beside a site plan. Built from what the drawing actually contains —
   a key with eleven entries for a plan showing three of them teaches the reader
   to stop reading the key. */
.plan-key {
  display: flex;
  flex-wrap: wrap;
  gap: .4rem 1rem;
  list-style: none;
  margin: .6rem 0 0;
  padding: 0;
  font-size: .82rem;
  color: var(--muted);
}
.plan-key li { display: flex; align-items: center; gap: .4rem; }
.plan-swatch {
  width: .85rem;
  height: .85rem;
  border-radius: .2rem;
  border: 1px solid var(--line-strong);
  flex: none;
}

/* The gate desk (SRS SEC-021 … SEC-023).

   Held in one hand, at night, with a car waiting. Wider than the rest of the
   public pages because it carries a list and a form rather than one message,
   and every control is at least 2.75rem tall: a guard wearing gloves at four in
   the morning missing a button is how a register stops being written in.

   `details` rather than a tab strip or a modal for the optional half of the
   form — there is no build step here, and a disclosure that works with
   JavaScript switched off is worth more at a barrier than one that animates. */
.gate-desk { max-width: 38rem; }
.gate-desk h2 {
  font-size: 1rem;
  text-transform: uppercase;
  letter-spacing: .04em;
  color: var(--muted);
  margin: 1.4rem 0 .5rem;
}
.gate-desk .btn, .gate-desk input, .gate-desk select, .gate-desk textarea { min-height: 2.75rem; }
.gate-desk summary {
  cursor: pointer;
  padding: .7rem .2rem;
  font-weight: 600;
  color: var(--accent);
}
.gate-desk details { border-top: 1px solid var(--line); }
.gate-desk details > div { margin: .6rem 0; }

/* One arrival, and the button that closes it. The button keeps its own column
   so that a long name cannot push it off the screen — the one control on this
   page a guard reaches for without reading. */
.gate-row {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: .8rem;
  padding: .7rem .8rem;
}
.gate-row form { margin: 0; flex: none; }

@media (max-width: 26rem) {
  .gate-row { flex-direction: column; align-items: stretch; }
  .gate-row form .btn { width: 100%; }
}

/* A list of tick boxes that wraps: the gates a credential opens (SRS SEC-010).

   Its own class rather than a grid, because the labels are of wildly different
   lengths — "G1 Main gate" beside "CR Control room, Mile 16 road" — and a fixed
   column count leaves either a ragged gap or a line break inside a gate's name. */
.checks {
  display: flex;
  flex-wrap: wrap;
  gap: .35rem 1.1rem;
  margin: .5rem 0 0;
}
.checks label {
  display: flex;
  align-items: center;
  gap: .4rem;
  font-weight: 400;
  margin: 0;
}

/* The checkpoint sticker sheet (SRS SEC-026).

   A sheet of labels to be cut up and screwed to walls, not an A4 document — so
   it is a grid of fixed-size cards rather than a letterhead. Each sticker is
   about 85 × 40mm, which is what fits beside a light switch without covering
   anything, and each one repeats the estate's name because a sticker found on
   its own six months later must say whose it is. */
.sticker-sheet {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(17rem, 1fr));
  gap: .6rem;
  max-width: 54rem;
  margin: 1rem auto;
  padding: 0 1rem;
}
.sticker-head {
  grid-column: 1 / -1;
  display: flex;
  flex-direction: column;
  gap: .15rem;
  margin-bottom: .4rem;
}
.sticker {
  display: flex;
  align-items: center;
  gap: .7rem;
  border: 1px dashed #9aa3ad;   /* the line you cut along */
  border-radius: .3rem;
  padding: .6rem .7rem;
  background: #fff;
  color: #10151b;
  break-inside: avoid;
}
.sticker-qr { flex: none; line-height: 0; }
.sticker-text { display: flex; flex-direction: column; gap: .1rem; min-width: 0; }
.sticker-code {
  font-family: ui-monospace, SFMono-Regular, Menlo, monospace;
  font-size: 1.5rem;
  font-weight: 700;
  letter-spacing: .04em;
  line-height: 1.1;
}
.sticker-name { font-size: .95rem; font-weight: 600; }
.sticker-note, .sticker-issuer { font-size: .72rem; color: #5b6572; }

@media print {
  .doc-toolbar { display: none; }
  .sticker-sheet { max-width: none; margin: 0; padding: 0; gap: .4rem; }
  .sticker { border-color: #333; }
}

/* An incident narrative, and the additions under it (SRS SEC-032).

   Set a little wider in the line and a little narrower in the column than the
   rest of the interface, because it is the only place in the platform where
   somebody reads two hundred words of somebody else's prose rather than
   scanning a table. The left rule marks it as quoted material: what is inside
   it was written at the time and is not editable. */
.narrative {
  max-width: 46rem;
  margin: .6rem 0 0;
  padding-left: .9rem;
  border-left: 3px solid var(--line-strong);
  line-height: 1.6;
  white-space: normal;
}

/* A heading inside a printed document (SRS SEC-034).

   The incident report is the first document in the platform long enough to
   need sections — an account, the additions to it, the people, the outcome —
   and a printed section heading wants more space above it than below, so the
   reader's eye groups it with what follows. */
.doc-section {
  font-size: 1rem;
  text-transform: uppercase;
  letter-spacing: .05em;
  margin: 1.6rem 0 .4rem;
  padding-bottom: .2rem;
  border-bottom: 1px solid var(--line);
}

/* The alarm disclosure on the gate screen (SRS SEC-030).

   Red where the other summaries on that page are accent-coloured, because it
   is the one control a guard must be able to find at a glance in the dark —
   and deliberately still a disclosure rather than a button, so that a handset
   held in one hand cannot raise an alarm by being gripped. */
.gate-desk summary.alarm-summary { color: var(--red); }

/* ------------------------------------------------------------------ manual
   The in-platform manual (milestone 29).

   The body is rendered from Markdown, so these rules dress tags rather than
   classes — there is no way to put a class on a paragraph that came out of a
   .md file, and adding one would mean a renderer that knows about styling. */
.manual-body > :first-child { margin-top: 0; }
.manual-body h1 { font-size: 1.5rem; margin: 0 0 .6rem; }
.manual-body h2 {
  font-size: 1.15rem;
  margin: 1.8rem 0 .5rem;
  padding-bottom: .25rem;
  border-bottom: 1px solid var(--line);
}
.manual-body h3 { font-size: 1rem; margin: 1.3rem 0 .35rem; }
.manual-body h4 { font-size: .95rem; margin: 1rem 0 .3rem; color: var(--muted); }
/* A readable measure. Prose set to the full width of a wide monitor is prose
   nobody finishes a paragraph of — the same reason the public layout holds the
   catalogue in. */
.manual-body p, .manual-body ul, .manual-body ol { max-width: 46rem; line-height: 1.65; }
.manual-body li { margin-bottom: .3rem; }
.manual-body code {
  font-family: ui-monospace, SFMono-Regular, Menlo, monospace;
  font-size: .88em;
  padding: .1rem .3rem;
  border-radius: 3px;
  background: var(--surface-2, rgba(0,0,0,.05));
}
.manual-body pre {
  overflow-x: auto;
  padding: .7rem .9rem;
  border-radius: 4px;
  border: 1px solid var(--line);
  background: var(--surface-2, rgba(0,0,0,.04));
}
.manual-body pre code { background: none; padding: 0; }
.manual-body blockquote {
  margin: 1rem 0;
  padding: .1rem 0 .1rem 1rem;
  border-left: 3px solid var(--accent);
  color: var(--text);
  max-width: 46rem;
}
.manual-body hr { border: 0; border-top: 1px solid var(--line); margin: 1.6rem 0; }

/* The help link on a screen's own heading. Quiet on purpose: it is there for
   the person who needs it and should not compete with the screen's actions. */
.help-link { font-size: .82rem; font-weight: 400; color: var(--muted); }
.help-link:hover { color: var(--accent); }

/* Printing the whole manual. Ignored on screen, which is why the element is
   invisible until a print stylesheet asks for it. */
.page-break { height: 0; }

@media print {
  .page-break { break-before: page; page-break-before: always; }
  .manual-body h2, .manual-body h3 { break-after: avoid; page-break-after: avoid; }
  .manual-body pre, .manual-body blockquote, .manual-body table { break-inside: avoid; }
  .manual-body p, .manual-body ul, .manual-body ol { max-width: none; }
}

/* =========================================================================
   13. A promoter's own website

   The public face of one company: its own domain's worth of pages, served
   under /c/{company}. Deliberately not the application's chrome — a buyer
   looking at plots should never see anything that suggests a back office.

   Two rules hold this section together:

   1. One colour per company. `--site-accent` arrives inline from the editor
      (validated to #rrggbb) and everything interactive here uses it. It falls
      back to the platform accent, so a company that never chose a colour
      still looks finished rather than unstyled.
   2. Nothing here depends on JavaScript. The FAQ is <details>, the navigation
      wraps rather than collapsing into a menu button, and the hero is a
      picture with text over it. On a phone with one bar of signal that is the
      difference between a site and a spinner.
   ========================================================================= */

.site-page {
  /* `--site-accent` is deliberately NOT redeclared here.

     It is defined on :root and overridden by a style attribute on this same
     element, written by the layout from the colour the company chose. A
     declaration in *this* rule would beat the inherited :root value without
     beating the attribute — which is how the first version of this shipped
     with every company's site in the platform's own navy. */
  --site-ink: var(--text-strong);
  --site-measure: 38rem;
  --site-gutter: 1.25rem;
  background: var(--surface);
  color: var(--text);
}

/* ------------------------------------------------------------ 13a. Chrome */

.site-header {
  position: sticky;
  top: 0;
  z-index: 40;
  background: var(--surface);
  border-bottom: 1px solid var(--line);
}
.site-head-inner {
  display: flex;
  align-items: center;
  gap: 1rem 1.5rem;
  flex-wrap: wrap;
  max-width: 76rem;
  margin: 0 auto;
  padding: .85rem var(--site-gutter);
}
.site-brand { display: inline-flex; align-items: center; gap: .55rem; color: var(--site-ink); }
.site-brand:hover { text-decoration: none; color: var(--site-ink); }
.site-brand strong { font-size: 1.05rem; font-weight: 650; letter-spacing: -.01em; }
.site-logo { display: block; height: 38px; width: auto; max-width: 190px; object-fit: contain; }

/* The navigation takes the space between the mark and the actions, so on a
   wide screen the links sit in the middle and on a phone they wrap under. */
.site-nav {
  display: flex;
  flex-wrap: wrap;
  gap: .25rem 1.1rem;
  margin-right: auto;
  font-size: .92rem;
}
.site-nav a {
  padding: .3rem 0;
  color: var(--text);
  font-weight: 500;
  border-bottom: 2px solid transparent;
}
.site-nav a:hover { color: var(--site-accent); text-decoration: none; border-color: var(--line-strong); }
.site-nav a.is-on { color: var(--site-accent); border-color: var(--site-accent); }

.site-head-actions { display: flex; align-items: center; gap: .55rem; font-size: .82rem; }
.site-head-actions > a { color: var(--muted); }
.site-head-actions > a.is-on { color: var(--site-ink); font-weight: 650; }
.site-head-actions .btn { border-color: var(--site-accent); color: var(--site-accent); }
.site-head-actions .btn:hover { background: var(--site-accent); color: #fff; }

/* The preview bar, on a page only its own company can reach. Amber and full
   width, because the one misunderstanding this feature could cause is somebody
   believing their site is already public. */
.site-preview {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  gap: .3rem .8rem;
  padding: .6rem var(--site-gutter);
  background: var(--amber-tint);
  border-bottom: 1px solid var(--amber);
  color: var(--amber);
  font-size: .85rem;
}
.site-preview strong { font-weight: 650; }
.site-preview a { color: var(--amber); text-decoration: underline; text-underline-offset: 2px; }

/* -------------------------------------------------------------- 13b. Hero */

/* A picture with the sentence over it, or — with no picture — a tinted band.
   Both are the same height band so a company without photography does not get
   a visibly broken front page. */
.site-hero {
  position: relative;
  display: flex;
  align-items: flex-end;
  min-height: 24rem;
  padding: 3.5rem var(--site-gutter) 2.75rem;
  overflow: hidden;
  background: linear-gradient(180deg, var(--surface-2), var(--bg));
  border-bottom: 1px solid var(--line);
}
.site-hero-image {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
}
/* The scrim, not the image, is what makes the text readable: a photograph
   chosen by a customer can be any brightness at all. */
.site-hero.has-image::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, rgba(0,0,0,.18) 0%, rgba(0,0,0,.62) 100%);
}
.site-hero-text { position: relative; z-index: 1; max-width: 46rem; margin: 0 auto; width: 100%; }
.site-hero h1 {
  margin: 0;
  font-size: clamp(1.9rem, 5vw, 3rem);
  line-height: 1.12;
  letter-spacing: -.02em;
  color: var(--site-ink);
}
.site-hero-lede { margin: .9rem 0 0; font-size: 1.1rem; line-height: 1.55; color: var(--muted); max-width: var(--site-measure); }
.site-hero-actions { display: flex; flex-wrap: wrap; gap: .6rem; margin-top: 1.5rem; }
.site-hero .btn-primary { background: var(--site-accent); border-color: var(--site-accent); color: #fff; }
.site-hero .btn-primary:hover { filter: brightness(.92); background: var(--site-accent); border-color: var(--site-accent); }

.site-hero.has-image h1,
.site-hero.has-image .site-hero-lede { color: #fff; }
.site-hero.has-image .site-hero-lede { color: rgba(255,255,255,.88); }
.site-hero.has-image .btn-outline { background: rgba(255,255,255,.1); border-color: rgba(255,255,255,.7); color: #fff; }
.site-hero.has-image .btn-outline:hover { background: #fff; border-color: #fff; color: var(--site-ink); }

/* ---------------------------------------------------------- 13c. Sections */

.site-section { padding: 3.25rem var(--site-gutter); }
.site-section + .site-section { border-top: 1px solid var(--line); }
.site-wrap { max-width: 76rem; margin: 0 auto; }
.site-section h2 {
  margin: 0 0 1.4rem;
  font-size: clamp(1.35rem, 3vw, 1.75rem);
  letter-spacing: -.015em;
  color: var(--site-ink);
}

/* Text beside a picture, text under it on a phone. The picture is second in
   the markup so it reads in the right order when the layout collapses. */
.site-split { display: grid; grid-template-columns: 1fr 1fr; gap: 2rem; align-items: start; }
.site-figure {
  display: block;
  width: 100%;
  border-radius: var(--radius);
  border: 1px solid var(--line);
  object-fit: cover;
  max-height: 26rem;
}

/* Prose written by a customer in Markdown. A measure, because a paragraph the
   full width of a desktop is a paragraph nobody finishes. */
.site-prose { max-width: var(--site-measure); color: var(--text); line-height: 1.68; }
.site-prose.small { max-width: none; }
.site-prose > :first-child { margin-top: 0; }
.site-prose > :last-child { margin-bottom: 0; }
.site-prose p, .site-prose ul, .site-prose ol { margin: 0 0 .9rem; }
.site-prose h2, .site-prose h3 { margin: 1.6rem 0 .6rem; color: var(--site-ink); }
.site-prose li { margin-bottom: .35rem; }
.site-prose a { color: var(--site-accent); text-decoration: underline; text-underline-offset: 2px; }
.site-prose blockquote {
  margin: 1.2rem 0;
  padding: .1rem 0 .1rem 1rem;
  border-left: 3px solid var(--site-accent);
  color: var(--muted);
}

/* A few sections want a little more than the default band. The alternating
   tint is what stops a long front page reading as one continuous column of
   text, and it is done by name rather than by :nth-child so that hiding one
   section in the editor does not invert the whole page. */
.site-section-philosophy,
.site-section-why,
.site-section-testimonials,
.site-section-news { background: var(--surface-2); }
.site-section-faq { background: var(--surface); }
.site-section-contact .site-wrap { max-width: 64rem; }

/* ------------------------------------------------------------- 13d. Cards */

.site-cards {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(17rem, 1fr));
  gap: 1.1rem;
}
.site-card {
  display: flex;
  flex-direction: column;
  gap: .45rem;
  padding: 1.1rem 1.2rem;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  color: var(--text);
}
.site-card h3 { margin: 0; font-size: 1.05rem; line-height: 1.3; color: var(--site-ink); }
.site-card p { margin: 0; }
.site-card .pill { align-self: flex-start; }

/* Only the cards that are links get the lift. A services card is not
   clickable and should not pretend to be. */
a.site-card { transition: border-color .12s, transform .12s; }
a.site-card:hover { text-decoration: none; border-color: var(--site-accent); transform: translateY(-2px); }
a.site-card:focus-visible { outline: 2px solid var(--site-accent); outline-offset: 2px; }

.site-card-image {
  display: block;
  width: calc(100% + 2.4rem);
  margin: -1.1rem -1.2rem .35rem;
  height: 11rem;
  object-fit: cover;
  border-bottom: 1px solid var(--line);
  border-radius: var(--radius) var(--radius) 0 0;
}
.site-estate h3 { margin-bottom: .1rem; }

/* -------------------------------------------------------------- 13e. Items */

/* Four shapes rather than one. A list of services, a wall of quotes, a team
   and a set of questions look nothing alike, and rendering all four as the
   same card is what makes a website look like a template somebody bought. */

.site-faq { max-width: 52rem; border-top: 1px solid var(--line); }
.site-faq details { border-bottom: 1px solid var(--line); }
.site-faq summary {
  cursor: pointer;
  padding: .95rem .25rem;
  font-weight: 550;
  color: var(--site-ink);
  list-style: none;
  display: flex;
  justify-content: space-between;
  gap: 1rem;
}
.site-faq summary::-webkit-details-marker { display: none; }
.site-faq summary::after { content: "+"; color: var(--site-accent); font-weight: 400; font-size: 1.2rem; line-height: 1; }
.site-faq details[open] summary::after { content: "\2013"; }
.site-faq summary:hover { color: var(--site-accent); }
.site-faq .site-prose { padding: 0 .25rem 1rem; }

.site-quotes { display: grid; grid-template-columns: repeat(auto-fill, minmax(19rem, 1fr)); gap: 1.1rem; }
.site-quote {
  margin: 0;
  padding: 1.3rem 1.4rem;
  background: var(--surface-2);
  border-radius: var(--radius);
  border-left: 3px solid var(--site-accent);
}
.site-quote blockquote { margin: 0 0 .9rem; font-size: 1.02rem; line-height: 1.6; color: var(--text); }
.site-quote blockquote::before { content: "\201C"; }
.site-quote blockquote::after { content: "\201D"; }
.site-quote figcaption { display: flex; flex-direction: column; font-size: .85rem; }
.site-quote figcaption strong { color: var(--site-ink); }

.site-team { display: grid; grid-template-columns: repeat(auto-fill, minmax(10rem, 1fr)); gap: 1.4rem; }
.site-person { display: flex; flex-direction: column; gap: .3rem; }
.site-person img {
  width: 100%;
  aspect-ratio: 1 / 1;
  object-fit: cover;
  border-radius: var(--radius);
  margin-bottom: .45rem;
  background: var(--surface-2);
}
.site-person strong { color: var(--site-ink); }
.site-person p { margin: .25rem 0 0; }

/* --------------------------------------------------------- 13f. Inner pages */

.site-page-head { padding: 2.5rem var(--site-gutter) 0; }
.site-page-head .site-wrap > h1 { margin: 0 0 .4rem; font-size: clamp(1.6rem, 4vw, 2.25rem); letter-spacing: -.02em; color: var(--site-ink); }
.site-page-head p { margin: 0; max-width: var(--site-measure); color: var(--muted); }

.site-article { max-width: 44rem; margin: 0 auto; padding: 2.5rem var(--site-gutter) 3rem; }
.site-article h1 { font-size: clamp(1.6rem, 4vw, 2.2rem); line-height: 1.18; letter-spacing: -.02em; margin: .4rem 0 .6rem; color: var(--site-ink); }
.site-article img { max-width: 100%; border-radius: var(--radius); }
.site-article .site-prose { max-width: none; font-size: 1.04rem; }

/* The band at the foot of a page that asks for the next step. Tinted with the
   company's colour at low opacity rather than filled with it: a full-bleed
   block of an unknown customer-chosen colour is a gamble. */
.site-cta {
  padding: 2.5rem var(--site-gutter);
  text-align: center;
  background: var(--surface-2);
  border-top: 1px solid var(--line);
}
.site-cta h2 { margin: 0 0 .5rem; color: var(--site-ink); }
.site-cta p { margin: 0 auto 1.2rem; max-width: var(--site-measure); color: var(--muted); }
.site-cta .btn-primary { background: var(--site-accent); border-color: var(--site-accent); color: #fff; }
.site-cta .btn-primary:hover { filter: brightness(.92); }

/* ------------------------------------------------------------ 13g. Contact */

.site-contact { display: grid; grid-template-columns: 1.1fr .9fr; gap: 2.5rem; align-items: start; }
.site-contact-ways { display: flex; flex-direction: column; gap: 1.1rem; }
.site-contact-ways .btn { align-self: flex-start; }
.site-contact-where { font-size: .95rem; line-height: 1.6; }
.site-contact-where strong { display: block; color: var(--site-ink); margin-bottom: .2rem; }
.site-contact-where + .site-contact-where { margin-top: 1rem; }

/* A measure, like the prose. A contact form the full width of a desktop
   makes a three-field enquiry look like an application. */
.site-form { display: flex; flex-direction: column; gap: .85rem; max-width: 40rem; }
.site-form label { display: flex; flex-direction: column; gap: .3rem; font-size: .85rem; font-weight: 550; color: var(--site-ink); }
.site-form input, .site-form select, .site-form textarea { width: 100%; }
.site-form textarea { min-height: 7rem; resize: vertical; }
.site-form .check { flex-direction: row; align-items: center; gap: .5rem; font-weight: 400; }
.site-form .check input { width: auto; flex: none; }
.site-form .btn-primary { align-self: flex-start; background: var(--site-accent); border-color: var(--site-accent); color: #fff; }
.site-form .btn-primary:hover { filter: brightness(.92); }

/* ------------------------------------------------------------ 13h. Footer */

.site-footer { border-top: 1px solid var(--line); background: var(--surface-2); }
.site-foot-inner {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(14rem, 1fr));
  gap: 1.5rem 2rem;
  max-width: 76rem;
  margin: 0 auto;
  padding: 2.25rem var(--site-gutter);
}
.site-foot-inner strong { color: var(--site-ink); }
.site-foot-inner p { margin: .35rem 0 0; }
.site-social { display: flex; flex-direction: column; gap: .3rem; font-size: .88rem; }
.site-social a { color: var(--muted); }
.site-social a:hover { color: var(--site-accent); }
.site-foot-legal {
  display: flex;
  flex-wrap: wrap;
  gap: .4rem 1.2rem;
  max-width: 76rem;
  margin: 0 auto;
  padding: .9rem var(--site-gutter) 1.6rem;
  border-top: 1px solid var(--line);
}

/* --------------------------------------------------------- 13i. WhatsApp */

/* Fixed, because a visitor decides to ask a question while looking at a plot,
   not after scrolling to the bottom. Above the safe area so it clears the
   home indicator on a phone. */
.site-whatsapp {
  position: fixed;
  right: 1rem;
  bottom: calc(1rem + env(safe-area-inset-bottom, 0px));
  z-index: 50;
  display: inline-flex;
  align-items: center;
  gap: .5rem;
  padding: .7rem 1.05rem;
  border-radius: 999px;
  background: #25D366;
  color: #04301A;
  font-weight: 600;
  font-size: .92rem;
  box-shadow: 0 6px 20px rgba(0,0,0,.22);
}
.site-whatsapp:hover { text-decoration: none; color: #04301A; filter: brightness(1.05); }
.site-whatsapp:focus-visible { outline: 2px solid var(--site-ink); outline-offset: 2px; }
.site-whatsapp svg { width: 18px; height: 18px; }

/* ------------------------------------------------------ 13j. Small screens */

@media (max-width: 860px) {
  .site-split, .site-contact { grid-template-columns: 1fr; }
  .site-hero { min-height: 19rem; padding-top: 2.5rem; }
  .site-section { padding: 2.25rem var(--site-gutter); }
}

@media (max-width: 560px) {
  .site-nav { order: 3; width: 100%; margin-right: 0; border-top: 1px solid var(--line); padding-top: .5rem; }
  .site-head-inner { padding-bottom: .5rem; }
  /* The label goes, the icon stays: a thumb-sized target that does not cover
     the price of the plot being read. */
  .site-whatsapp span { position: absolute; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); }
  .site-whatsapp { padding: .85rem; }
  .site-whatsapp svg { width: 22px; height: 22px; }
}

/* ------------------------------------------------------------- 13k. Print */

/* A buyer printing a plot page wants the plot and the telephone number, not a
   floating button and a navigation bar. */
@media print {
  .site-header, .site-preview, .site-whatsapp, .site-hero-actions, .site-cta, .site-form { display: none; }
  .site-hero { min-height: 0; padding: 0 0 1rem; border: 0; }
  .site-hero.has-image::after, .site-hero-image { display: none; }
  .site-hero.has-image h1, .site-hero.has-image .site-hero-lede { color: #000; }
  .site-section { padding: 1rem 0; border: 0; }
  .site-footer { background: none; }
  .site-cards, .site-quotes, .site-team { display: block; }
  .site-card, .site-quote { break-inside: avoid; page-break-inside: avoid; margin-bottom: .6rem; }
}
