/* =====================================================================
   HOUSEMADE — design tokens + styles
   Brand rationale (use in report, E-Business Model section):
   - Ink + cool paper = calm, technical, trustworthy (B2B buyer: ops/IT/finance lead)
   - Signal yellow = safety tape / hi-vis: "safe environment for work"; used ONLY for actions (CTAs)
   - Moss = secure / done states;  Rust = risk (used once, on passwords.xlsx)
   - Bricolage Grotesque (display) + IBM Plex Sans (body, engineering heritage)
   ===================================================================== */
:root {
  --ink: #1C2633;
  --ink-2: #4A5563;
  --paper: #EEF0EC;
  --paper-2: #E3E7E1;
  --white: #FFFFFF;
  --signal: #F2C12E;
  --signal-ink: #1C2633;
  --moss: #2E6A53;
  --rust: #B4472C;
  --line: #C6CCC4;
  --grid: rgba(28, 38, 51, .06);

  --f-display: "Bricolage Grotesque", "Arial Narrow", system-ui, sans-serif;
  --f-body: "IBM Plex Sans", system-ui, -apple-system, "Segoe UI", sans-serif;

  /* type scale ~1.25 (major third) */
  --t-0: .875rem; --t-1: 1rem; --t-2: 1.25rem; --t-3: 1.563rem; --t-4: 1.953rem; --t-5: 2.441rem; --t-6: clamp(2.6rem, 6vw, 4.4rem);
  --r-s: 6px; --r-m: 12px;
  --wrap: 1160px;
  --ease: cubic-bezier(.2, .7, .1, 1);
}

*, *::before, *::after { box-sizing: border-box; }
[hidden] { display: none !important; }
html { scroll-behavior: smooth; scroll-padding-top: 80px; }
body { margin: 0; background: var(--paper); color: var(--ink); font: 400 var(--t-1)/1.6 var(--f-body); -webkit-font-smoothing: antialiased; }
img { max-width: 100%; display: block; }
a { color: inherit; }
h1, h2, h3 { font-family: var(--f-display); line-height: 1.08; letter-spacing: -.02em; margin: 0 0 .5em; font-weight: 700; }
h1 { font-size: var(--t-6); font-weight: 800; letter-spacing: -.035em; max-width: 12ch; }
h2 { font-size: clamp(1.9rem, 3.6vw, var(--t-5)); max-width: 20ch; }
h3 { font-size: var(--t-2); letter-spacing: -.01em; }
p { margin: 0 0 1em; max-width: 64ch; }
:focus-visible { outline: 3px solid var(--signal); outline-offset: 3px; border-radius: 4px; }
.wrap { width: min(var(--wrap), 100% - 32px); margin-inline: auto; }
.skip { position: absolute; left: -999px; top: 8px; background: var(--ink); color: var(--white); padding: 8px 12px; z-index: 99; }
.skip:focus { left: 8px; }
.sr { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); }
.fine { font-size: var(--t-0); color: var(--ink-2); }

/* ---------- buttons (all CTAs) ---------- */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: .5em; min-height: 48px; padding: 0 1.3em;
  background: var(--signal); color: var(--signal-ink); font: 600 var(--t-1)/1 var(--f-body); text-decoration: none;
  border: 2px solid var(--ink); border-radius: var(--r-s); cursor: pointer; box-shadow: 3px 3px 0 var(--ink);
  transition: transform .15s var(--ease), box-shadow .15s var(--ease); }
.btn:hover { transform: translate(-1px, -1px); box-shadow: 4px 4px 0 var(--ink); }
.btn:active { transform: translate(2px, 2px); box-shadow: 1px 1px 0 var(--ink); }
.btn--ghost { background: transparent; box-shadow: none; }
.btn--ghost:hover { background: var(--white); box-shadow: none; transform: none; }
.btn--dark { background: var(--ink); color: var(--white); box-shadow: 3px 3px 0 var(--signal); }
.btn--small { min-height: 40px; padding: 0 1em; font-size: var(--t-0); box-shadow: 2px 2px 0 var(--ink); }

/* ---------- nav ---------- */
.nav { position: sticky; top: 0; z-index: 20; background: color-mix(in srgb, var(--paper) 92%, transparent); backdrop-filter: blur(8px); border-bottom: 1px solid var(--line); }
.nav__inner { display: flex; align-items: center; justify-content: space-between; min-height: 68px; }
.brand { display: inline-flex; align-items: center; gap: 10px; text-decoration: none; font: 800 1.35rem/1 var(--f-display); letter-spacing: -.03em; }
.nav__links { display: flex; align-items: center; gap: 22px; }
.nav__links a:not(.btn) { text-decoration: none; font-size: .95rem; color: var(--ink-2); }
.nav__links a:not(.btn):hover { color: var(--ink); text-decoration: underline; text-underline-offset: 4px; }
.nav__toggle { display: none; }

/* ---------- hero ---------- */
.hero { padding: clamp(40px, 7vw, 96px) 0 clamp(56px, 8vw, 110px); }
.hero__grid { display: grid; grid-template-columns: 1fr 1.05fr; gap: clamp(32px, 5vw, 72px); align-items: center; }
.lede { font-size: var(--t-2); line-height: 1.5; color: var(--ink-2); max-width: 40ch; }
.hero__ctas { display: flex; flex-wrap: wrap; gap: 14px; margin: 28px 0 16px; }
.hero__note { font-size: var(--t-0); color: var(--ink-2); max-width: 46ch; }

/* stage: the chaos -> house animation */
.stage { position: relative; margin: 0; height: 480px; border: 2px solid var(--ink); border-radius: var(--r-m); overflow: hidden;
  background-color: var(--white);
  background-image: linear-gradient(var(--grid) 1px, transparent 1px), linear-gradient(90deg, var(--grid) 1px, transparent 1px);
  background-size: 24px 24px; }
.stage__house { position: absolute; inset: 64px 28px 76px; opacity: 0; transform: translateY(12px); transition: opacity .6s var(--ease) .5s, transform .6s var(--ease) .5s;
  border: 3px solid var(--ink); border-top: 0; border-radius: 0 0 var(--r-s) var(--r-s); background: var(--paper); }
.stage__roof { position: absolute; left: -3px; right: -3px; top: -46px; height: 46px; background: var(--ink); clip-path: polygon(50% 0, 100% 100%, 0 100%); }
.stage__roof::after { content: ""; position: absolute; inset: 5px 8px 0; background: var(--paper); clip-path: polygon(50% 0, 100% 100%, 0 100%); }
.stage__bar { position: absolute; left: 0; right: 0; top: 0; height: 34px; display: flex; align-items: center; gap: 8px; padding: 0 12px;
  background: var(--ink); color: var(--white); font-size: .8rem; }
.lock { width: 10px; height: 8px; background: var(--signal); border-radius: 2px; position: relative; margin-top: 3px; }
.lock::before { content: ""; position: absolute; left: 1px; right: 1px; top: -6px; height: 7px; border: 2px solid var(--signal); border-bottom: 0; border-radius: 5px 5px 0 0; }
.tile { position: absolute; left: 0; top: 0; width: 128px; padding: 10px 12px; background: var(--white); border: 1.5px solid var(--ink); border-radius: var(--r-s);
  box-shadow: 2px 2px 0 var(--line); font-size: .85rem; line-height: 1.25; will-change: transform;
  transition: transform .9s var(--ease), background-color .5s, box-shadow .5s; transition-delay: calc(var(--d, 0) * 45ms); }
.tile b { display: block; font-weight: 600; }
.tile small { color: var(--ink-2); font-size: .72rem; }
.tile--risk { border-color: var(--rust); }
.tile--risk small { color: var(--rust); font-weight: 600; }
.stage__caption { position: absolute; left: 0; right: 0; bottom: 0; display: flex; align-items: center; justify-content: space-between; gap: 12px;
  padding: 12px 14px; border-top: 2px solid var(--ink); background: var(--paper); font-size: .9rem; }
.stage__btn { font: 600 .85rem/1 var(--f-body); padding: 10px 14px; border: 2px solid var(--ink); border-radius: var(--r-s); background: var(--white); cursor: pointer; white-space: nowrap; }
.stage__btn[aria-pressed="true"] { background: var(--ink); color: var(--white); }
.stage.is-home .stage__house { opacity: 1; transform: none; }
.stage.is-home .tile { box-shadow: none; }
.stage.is-home .tile small { color: var(--moss); }
.stage.is-home .tile--risk { border-color: var(--ink); }

/* ---------- section scaffolding ---------- */
section { padding: clamp(64px, 9vw, 120px) 0; }
.section-head { margin-bottom: clamp(28px, 4vw, 48px); }
.section-head p { font-size: var(--t-2); color: var(--ink-2); line-height: 1.5; max-width: 52ch; }

/* ---------- story / Monday ---------- */
.monday { background: var(--ink); color: var(--paper); }
.monday .section-head p { color: #B9C2CC; }
.switch { display: inline-flex; border: 2px solid var(--paper); border-radius: 999px; padding: 4px; margin-bottom: 36px; }
.switch button { font: 600 var(--t-0)/1 var(--f-body); color: var(--paper); background: none; border: 0; padding: 12px 18px; border-radius: 999px; cursor: pointer; }
.switch button[aria-checked="true"] { background: var(--signal); color: var(--ink); }
.day { list-style: none; margin: 0; padding: 0; display: grid; gap: 0; border-top: 1px solid #3A4656; }
.day li { display: grid; grid-template-columns: 110px 1fr; gap: 24px; padding: 22px 0; border-bottom: 1px solid #3A4656; align-items: baseline; }
.day time { font: 700 var(--t-3)/1 var(--f-display); color: var(--signal); font-variant-numeric: tabular-nums; }
.day p { grid-column: 2; grid-row: 1; margin: 0; font-size: var(--t-2); line-height: 1.45; max-width: 56ch; transition: opacity .35s var(--ease), transform .35s var(--ease); }
.day .h { opacity: 0; transform: translateY(6px); pointer-events: none; }
.day[data-mode="housemade"] .r { opacity: 0; transform: translateY(-6px); pointer-events: none; }
.day[data-mode="housemade"] .h { opacity: 1; transform: none; pointer-events: auto; }
.day[data-mode="housemade"] time { color: #8FD3B4; }

/* ---------- platform floor plan ---------- */
.plan { display: grid; grid-template-columns: 1.25fr 1fr; gap: clamp(24px, 4vw, 56px); align-items: stretch; }
.plan__drawing { display: grid; grid-template-columns: repeat(4, 1fr); grid-template-rows: 130px 130px 110px;
  grid-template-areas: "vault crm crm dash" "access flow flow dash" "audit hub hub hub";
  border: 6px solid var(--ink); background-color: var(--white);
  background-image: linear-gradient(var(--grid) 1px, transparent 1px), linear-gradient(90deg, var(--grid) 1px, transparent 1px); background-size: 16px 16px; }
.room { position: relative; border: 3px solid var(--ink); margin: -1.5px; background: transparent; cursor: pointer; text-align: left; padding: 12px 14px;
  font: 700 var(--t-1)/1.1 var(--f-display); color: var(--ink); display: flex; flex-direction: column; justify-content: flex-start; transition: background-color .25s; }
.room span { font: 400 .75rem/1.2 var(--f-body); color: var(--ink-2); margin-top: 4px; }
.room:hover { background: rgba(242, 193, 46, .18); }
.room[aria-selected="true"] { background: var(--signal); }
.room--vault { grid-area: vault; } .room--crm { grid-area: crm; } .room--dash { grid-area: dash; } .room--access { grid-area: access; }
.room--flow { grid-area: flow; } .room--audit { grid-area: audit; } .room--hub { grid-area: hub; }
/* the front door: a gap in the bottom wall of the Hub */
.room--hub::after { content: ""; position: absolute; bottom: -9px; left: 50%; width: 64px; height: 12px; margin-left: -32px; background: var(--paper); }
.room--hub::before { content: ""; position: absolute; bottom: -6px; left: calc(50% - 32px); width: 46px; height: 3px; background: var(--ink); transform-origin: left; transform: rotate(-35deg); z-index: 1; }
.plan__panel { border-left: 3px solid var(--ink); padding: 4px 0 4px clamp(20px, 3vw, 36px); }
.plan__panel h3 { font-size: var(--t-4); margin-bottom: .3em; }
.plan__panel .replaces { font-size: var(--t-0); color: var(--ink-2); margin-bottom: 1.2em; }
.plan__panel ul { margin: 0; padding-left: 1.1em; }
.plan__panel li { margin-bottom: .45em; }
.plan__panel.swap { animation: swap .35s var(--ease); }
@keyframes swap { from { opacity: 0; transform: translateX(8px); } to { opacity: 1; transform: none; } }

/* ---------- process ---------- */
.process { background: var(--paper-2); }
.steps { list-style: none; counter-reset: s; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(4, 1fr); gap: 0; border-top: 3px solid var(--ink); }
.steps li { counter-increment: s; padding: 20px 24px 8px 0; position: relative; }
.steps li::before { content: counter(s); display: block; font: 800 var(--t-5)/1 var(--f-display); color: var(--ink); margin-bottom: 14px; }
.steps li + li { padding-left: 24px; border-left: 1px solid var(--line); }
.steps p { color: var(--ink-2); font-size: .95rem; }

/* ---------- compare + calculator ---------- */
.table-scroll { overflow-x: auto; margin-bottom: clamp(40px, 6vw, 72px); }
.vs { width: 100%; border-collapse: collapse; min-width: 640px; }
.vs th, .vs td { text-align: left; padding: 16px 18px; border-bottom: 1px solid var(--line); vertical-align: top; }
.vs thead th { font: 700 var(--t-2)/1.2 var(--f-display); border-bottom: 3px solid var(--ink); }
.vs thead th:last-child { background: var(--ink); color: var(--paper); border-radius: var(--r-s) var(--r-s) 0 0; }
.vs tbody th { font-weight: 600; width: 22%; }
.vs td:first-of-type { color: var(--ink-2); }
.vs td:last-child { background: var(--white); font-weight: 500; }
.calc { display: grid; grid-template-columns: 1fr 1fr; border: 2px solid var(--ink); border-radius: var(--r-m); overflow: hidden; background: var(--white); }
.calc__inputs { padding: clamp(20px, 3vw, 36px); display: grid; gap: 18px; align-content: start; }
.calc__inputs label { display: grid; grid-template-columns: 1fr auto; gap: 6px 12px; font-size: .92rem; }
.calc__inputs output { font: 700 var(--t-2)/1 var(--f-display); font-variant-numeric: tabular-nums; }
.calc__inputs input[type=range] { grid-column: 1 / -1; width: 100%; accent-color: var(--ink); }
.calc__result { padding: clamp(20px, 3vw, 36px); background: var(--paper); border-left: 2px solid var(--ink); display: flex; flex-direction: column; gap: 12px; }
.calc__row { display: flex; justify-content: space-between; align-items: baseline; gap: 12px; }
.calc__row strong { font: 800 var(--t-4)/1 var(--f-display); font-variant-numeric: tabular-nums; }
.calc__bar { display: grid; gap: 6px; }
.calc__bar i { display: block; height: 14px; border-radius: 3px; transition: width .5s var(--ease); }
#bar-saas { background: var(--rust); } #bar-hm { background: var(--moss); }
.calc__verdict { font: 600 var(--t-2)/1.35 var(--f-display); margin: 6px 0 0; }
.calc__fine { font-size: .78rem; color: var(--ink-2); }
.calc__result .btn { align-self: flex-start; margin-top: auto; }

/* ---------- security ---------- */
.security { background: var(--white); border-block: 1px solid var(--line); }
.security__grid { display: grid; grid-template-columns: 1fr 1.1fr; gap: clamp(28px, 5vw, 72px); }
.security__grid > div p { font-size: var(--t-2); color: var(--ink-2); line-height: 1.5; }
.checks { list-style: none; margin: 0; padding: 0; }
.checks li { padding: 14px 0 14px 36px; border-bottom: 1px solid var(--line); position: relative; }
.checks li::before { content: ""; position: absolute; left: 4px; top: 19px; width: 14px; height: 8px; border-left: 3px solid var(--moss); border-bottom: 3px solid var(--moss); transform: rotate(-45deg); }

/* ---------- pricing ---------- */
.tiers { display: grid; grid-template-columns: 1fr 1.15fr 1fr; gap: 20px; align-items: stretch; }
.tier { padding: 28px; border: 2px solid var(--ink); border-radius: var(--r-m); background: var(--white); display: flex; flex-direction: column; gap: 6px; }
.tier .btn { margin-top: auto; align-self: flex-start; }
.tier--main { background: var(--ink); color: var(--paper); transform: translateY(-10px); }
.tier--main .price small { color: #B9C2CC; }
.price { font: 800 var(--t-4)/1.1 var(--f-display); margin-bottom: .4em; }
.price small { display: block; font: 400 var(--t-0)/1.4 var(--f-body); color: var(--ink-2); margin-top: 4px; }
.pricing .fine { margin-top: 20px; }

/* ---------- faq ---------- */
.faq__grid { display: grid; grid-template-columns: 1fr 1.5fr; gap: clamp(24px, 5vw, 72px); }
details { border-bottom: 1px solid var(--line); padding: 4px 0; }
summary { cursor: pointer; list-style: none; padding: 16px 40px 16px 0; font: 600 var(--t-2)/1.3 var(--f-display); position: relative; }
summary::-webkit-details-marker { display: none; }
summary::after { content: "+"; position: absolute; right: 6px; top: 12px; font: 400 1.8rem/1 var(--f-body); transition: transform .25s var(--ease); }
details[open] summary::after { transform: rotate(45deg); }
details p { color: var(--ink-2); padding-bottom: 12px; }

/* ---------- audit form + lead magnet ---------- */
.audit { background: var(--signal); }
.audit__grid { display: grid; grid-template-columns: 1fr 1.1fr; gap: clamp(28px, 5vw, 72px); align-items: start; }
.audit__intro p { font-size: var(--t-2); line-height: 1.5; }
.audit__get { padding-left: 1.1em; }
.audit__get li { margin-bottom: .5em; }
.form { background: var(--white); border: 2px solid var(--ink); border-radius: var(--r-m); padding: clamp(20px, 3vw, 32px); display: grid; grid-template-columns: 1fr 1fr; gap: 16px; box-shadow: 6px 6px 0 var(--ink); }
.field { grid-column: 1 / -1; display: grid; gap: 6px; }
.field--half { grid-column: span 1; }
.field label { font-weight: 600; font-size: .92rem; }
.opt { font-weight: 400; color: var(--ink-2); }
input, select, textarea { font: inherit; color: var(--ink); background: var(--white); border: 1.5px solid var(--ink-2); border-radius: var(--r-s); padding: 11px 12px; min-height: 46px; width: 100%; }
input:focus, select:focus, textarea:focus { border-color: var(--ink); outline: 3px solid var(--signal); outline-offset: 0; }
[aria-invalid="true"] { border-color: var(--rust); background: #FBF1EE; }
.consent { grid-column: 1 / -1; display: flex; gap: 10px; align-items: flex-start; font-size: .88rem; }
.consent input { width: 20px; min-height: 20px; margin-top: 2px; }
.form .btn { grid-column: 1 / -1; justify-self: start; }
.form__msg { grid-column: 1 / -1; margin: 0; font-weight: 600; min-height: 1.4em; }
.form__msg.ok { color: var(--moss); } .form__msg.err { color: var(--rust); }
.magnet { margin-top: clamp(40px, 6vw, 64px); display: grid; grid-template-columns: 1.1fr 1fr; gap: 24px; align-items: center; border-top: 3px solid var(--ink); padding-top: 32px; }
.magnet h3 { font-size: var(--t-3); }
.magnet p { margin: 0; }
.magnet__row { display: flex; gap: 10px; }
.magnet .form__msg { grid-column: 1 / -1; }

/* ---------- footer ---------- */
.foot { background: var(--ink); color: #B9C2CC; padding: 48px 0 28px; }
.foot__grid { display: grid; grid-template-columns: 2fr 1fr 1fr; gap: 24px; }
.foot nav { display: grid; gap: 8px; align-content: start; }
.foot a { color: var(--paper); text-decoration: none; }
.foot a:hover { text-decoration: underline; }
.brand--foot { color: var(--paper); margin-bottom: 10px; }
.brand--foot img { filter: invert(1) brightness(1.6); }
.foot__fine { font-size: .78rem; margin-top: 28px; border-top: 1px solid #3A4656; padding-top: 16px; }

/* ---------- cookie consent (consent.js) ---------- */
.cc { position: fixed; left: 16px; bottom: 16px; z-index: 60; width: min(520px, calc(100% - 32px)); }
.cc__box { background: var(--white); border: 2px solid var(--ink); border-radius: var(--r-m); padding: 20px; box-shadow: 5px 5px 0 var(--ink); max-height: calc(100vh - 32px); overflow: auto; }
.cc h2 { font-size: var(--t-2); margin-bottom: .4em; max-width: none; }
.cc p { font-size: .92rem; margin-bottom: 12px; }
.cc__prefs { border-top: 1px solid var(--line); margin-bottom: 12px; }
.cc__row { display: flex; justify-content: space-between; gap: 16px; padding: 12px 0; border-bottom: 1px solid var(--line); cursor: pointer; }
.cc__row b { display: block; font-size: .95rem; }
.cc__row small { display: block; color: var(--ink-2); font-size: .8rem; line-height: 1.4; }
.cc__row input { width: 22px; min-height: 22px; flex: none; accent-color: var(--moss); margin-top: 2px; }
.cc__actions { display: flex; flex-wrap: wrap; gap: 10px; }
.cc__actions [data-act="all"], .cc__actions [data-act="none"] { flex: 1 1 140px; }   /* equal weight: ICO */
.hp { position: absolute; left: -9999px; width: 1px; height: 1px; overflow: hidden; }
.consent--magnet { margin-top: 12px; }
.cta-row { margin-top: 32px; }

/* ---------- live chat (chat.js) ---------- */
.chat-launch { position: fixed; right: 16px; bottom: 16px; z-index: 55; display: inline-flex; align-items: center; gap: 8px; min-height: 52px; padding: 0 18px;
  background: var(--ink); color: var(--white); border: 2px solid var(--ink); border-radius: 999px; font: 600 var(--t-1)/1 var(--f-body); cursor: pointer; box-shadow: 3px 3px 0 var(--signal); }
.chat-launch:hover { transform: translate(-1px, -1px); box-shadow: 4px 4px 0 var(--signal); }
.chat-launch__badge { position: absolute; top: -6px; right: -4px; min-width: 22px; height: 22px; border-radius: 11px; background: var(--rust); color: var(--white); font-size: .75rem; display: grid; place-items: center; padding: 0 6px; }
.chat-launch__badge[hidden] { display: none; }
body.has-consent .chat-launch, body.chat-open .chat-launch { display: none; }
.chat { padding: 0; position: fixed; right: 16px; bottom: 16px; z-index: 56; width: min(380px, calc(100% - 32px)); height: min(600px, calc(100vh - 32px)); display: flex; flex-direction: column;
  background: var(--paper); border: 2px solid var(--ink); border-radius: var(--r-m); box-shadow: 5px 5px 0 var(--ink); overflow: hidden; animation: chatin .25s var(--ease); }
.chat[hidden] { display: none; }
@keyframes chatin { from { opacity: 0; transform: translateY(12px); } to { opacity: 1; transform: none; } }
.chat__head { display: flex; align-items: center; gap: 10px; padding: 12px 14px; background: var(--ink); color: var(--white); }
.chat__head b { display: block; font-family: var(--f-display); font-size: 1.05rem; }
.chat__head small { color: #B9C2CC; font-size: .78rem; display: flex; align-items: center; gap: 6px; }
.chat__head small::before { content: ""; width: 8px; height: 8px; border-radius: 50%; background: #8A94A0; }
.chat.is-online .chat__head small::before { background: #5BD39A; }
.chat__avatar { width: 36px; height: 36px; border-radius: 50%; background: var(--signal); color: var(--ink); display: grid; place-items: center; font: 800 .85rem/1 var(--f-display); flex: none; }
.chat__close { margin-left: auto; background: none; border: 0; color: var(--white); font-size: 1.8rem; line-height: 1; cursor: pointer; padding: 0 4px; }
.chat__log { list-style: none; margin: 0; padding: 14px; flex: 1; overflow-y: auto; display: flex; flex-direction: column; gap: 10px; }
.msg { max-width: 85%; }
.msg p { margin: 0; padding: 10px 12px; border-radius: 12px; font-size: .92rem; line-height: 1.45; white-space: pre-wrap; overflow-wrap: anywhere; }
.msg__who { display: block; font-size: .7rem; color: var(--ink-2); margin: 0 4px 3px; }
.msg--bot p, .msg--agent p { background: var(--white); border: 1.5px solid var(--ink); border-bottom-left-radius: 3px; }
.msg--agent p { border-color: var(--moss); }
.msg--visitor { align-self: flex-end; }
.msg--visitor .msg__who { text-align: right; }
.msg--visitor p { background: var(--ink); color: var(--white); border-bottom-right-radius: 3px; }
.chat__quick { display: flex; flex-wrap: wrap; gap: 6px; padding: 0 14px 10px; }
.chat__quick[hidden] { display: none; }
.chat__chip { font: 500 .8rem/1 var(--f-body); padding: 8px 10px; border: 1.5px solid var(--ink); border-radius: 999px; background: var(--white); cursor: pointer; }
.chat__chip:hover { background: var(--signal); }
.chat__email { padding: 10px 14px; border-top: 1px solid var(--line); background: var(--white); font-size: .85rem; }
.chat__email[hidden] { display: none; }
.chat__email div { display: flex; gap: 8px; margin-top: 6px; }
.chat__email input { min-height: 40px; padding: 8px 10px; }
.chat__form { display: flex; gap: 8px; padding: 10px 14px; border-top: 2px solid var(--ink); background: var(--white); }
.chat__form textarea { resize: none; min-height: 42px; max-height: 120px; padding: 10px; font-size: .92rem; }
.chat__legal { margin: 0; padding: 6px 14px 10px; font-size: .72rem; color: var(--ink-2); background: var(--white); }
@media (max-width: 600px) {
  .chat { right: 0; bottom: 0; width: 100%; height: 100%; border-radius: 0; border: 0; box-shadow: none; max-height: none; }
  .chat-launch span { display: none; }
  .chat-launch { padding: 0 15px; }
  .cc { left: 8px; right: 8px; bottom: 8px; width: auto; }
}

/* ---------- inner pages (journal, privacy, thank-you) ---------- */
.page { padding: clamp(40px, 7vw, 88px) 0; }
.page h1 { max-width: 18ch; font-size: clamp(2.2rem, 5vw, 3.4rem); }
.prose { max-width: 70ch; }
.prose h2 { font-size: var(--t-3); margin-top: 1.6em; }
.posts { display: grid; gap: 0; border-top: 3px solid var(--ink); margin-top: 32px; }
.post { display: grid; grid-template-columns: 160px 1fr; gap: 24px; padding: 28px 0; border-bottom: 1px solid var(--line); }
.post time { color: var(--ink-2); font-size: var(--t-0); }
.post h2 { font-size: var(--t-3); margin-bottom: .3em; max-width: none; }
.post a { text-decoration: none; }
.post a:hover h2 { text-decoration: underline; text-underline-offset: 5px; }
.tag { display: inline-block; font-size: .75rem; border: 1px solid var(--ink-2); border-radius: 999px; padding: 2px 10px; margin-top: 6px; }

/* ---------- responsive ---------- */
@media (max-width: 960px) {
  .hero__grid, .plan, .security__grid, .faq__grid, .audit__grid, .magnet, .calc { grid-template-columns: 1fr; }
  .calc__result { border-left: 0; border-top: 2px solid var(--ink); }
  .steps { grid-template-columns: 1fr 1fr; }
  .steps li:nth-child(3) { border-left: 0; padding-left: 0; }
  .tiers { grid-template-columns: 1fr; }
  .tier--main { transform: none; }
  .plan__panel { border-left: 0; border-top: 3px solid var(--ink); padding: 20px 0 0; }
  .foot__grid { grid-template-columns: 1fr 1fr; }
  .foot__grid > div:first-child { grid-column: 1 / -1; }
}
@media (max-width: 820px) {
  .nav__toggle { display: inline-flex; font: 600 var(--t-0)/1 var(--f-body); padding: 10px 14px; border: 2px solid var(--ink); border-radius: var(--r-s); background: var(--white); cursor: pointer; }
  .nav__links { position: absolute; left: 0; right: 0; top: 100%; flex-direction: column; align-items: flex-start; gap: 0; padding: 8px 16px 16px; background: var(--paper); border-bottom: 2px solid var(--ink); display: none; }
  .nav__links.open { display: flex; }
  .nav__links a:not(.btn) { padding: 12px 0; width: 100%; border-bottom: 1px solid var(--line); font-size: 1rem; }
  .nav__links .btn { margin-top: 14px; }
}
@media (max-width: 600px) {
  .stage { height: 520px; }
  .tile { width: 108px; padding: 8px 9px; font-size: .78rem; }
  .stage__caption { flex-direction: column; align-items: stretch; text-align: left; }
  .day li { grid-template-columns: 1fr; gap: 6px; }
  .day p { grid-column: 1; grid-row: 2; }
  .steps { grid-template-columns: 1fr; }
  .steps li + li { border-left: 0; padding-left: 0; border-top: 1px solid var(--line); }
  .plan__drawing { grid-template-rows: 100px 100px 96px; }
  .room { padding: 8px; font-size: .9rem; }
  .form { grid-template-columns: 1fr; }
  .field--half { grid-column: 1 / -1; }
  .magnet__row { flex-direction: column; }
  .post { grid-template-columns: 1fr; gap: 6px; }
}
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { transition-duration: .01ms !important; animation-duration: .01ms !important; scroll-behavior: auto !important; }
}
