@font-face { font-family: "Plus Jakarta Sans"; font-style: normal; font-weight: 400 800; font-display: swap;
  src: url("fonts/PlusJakartaSans-latin.7660bd9909fb.woff2") format("woff2"); }
:root {
  /* Paper and ink, the brand default (docs/v1/DECISIONS.md, 2026-11-28). Every color comes from these tokens. The person picks
     System (follow the phone), Light or Dark; Light and Dark set data-theme on <html> before the page paints. */
  --page: #FCFCFA; --paper: #FFFFFF; --soft: color-mix(in srgb, var(--line) 35%, var(--page)); --track: color-mix(in srgb, var(--line) 55%, var(--page));
  --line: #E3E3E0; --line-strong: #8A8A86; --ink: #111111; --ink-2: #333333; --muted: #5F5F5C; --faint: var(--muted);
  --brand: #8A8A86; --brand-deep: #111111; --brand-text: #111111; --on-brand: #FFFFFF; --brand-soft: #EEEEEB;
  --accent: var(--btn); --accent-ink: var(--btn-ink); --accent-glow: transparent;
  --btn: #111111; --btn-ink: #FFFFFF;
  --ok: #23693F; --ok-bg: #E0F0E5; --warn: #85520C; --warn-bg: #FBEFD9; --warn-line: #F0C987;
  --bad: #A23B2A; --on-bad: #FFFFFF; --bad-bg: #F6E3DD; --bad-line: color-mix(in srgb, var(--bad) 35%, var(--bad-bg)); --heat: #C2551F; --cool: #2570B8;
  /* The health card is always dark, with its own readable health colors. */
  --hero: #111111; --hero-ink: #F7F7F5; --hero-muted: #C4C4C0; --hero-ok: #86D19F; --hero-warn: #F2C77A; --hero-bad: #F0907C;
  --hero-rule: color-mix(in srgb, var(--hero-ink) 14%, transparent); --shadow: 0 8px 24px rgba(17, 17, 17, .08);
  /* The logo's own colors (static/icons/icon.svg and pro/icon.svg), the same in light and dark. The green leaf is
     the brand mark, never part of the UI, so the reserved status colors don't apply to it. */
  --logo-tile: #111111; --logo-a: #FCFCFA; --logo-leaf: #4DB560; --logo-vein: #111111;
  --logo-pro-tile: #FCFCFA; --logo-pro-a: #111111; --logo-pro-leaf: #4DB560; --logo-pro-vein: #FCFCFA;
  /* Legacy names used across the stylesheet, mapped onto the new roles. */
  --navy: var(--ink); --green: var(--brand-text); --green-dark: var(--ink); --mint: var(--brand); --danger: var(--bad);
  --radius: 18px;
  --font: "Plus Jakarta Sans", "Segoe UI", system-ui, sans-serif;
  color-scheme: light;
  font-family: var(--font);
  color: var(--ink);
  background: var(--page);
  -webkit-text-size-adjust: 100%;
}
@media (prefers-color-scheme: dark) { :root:not([data-theme="light"]) {
  --page: #121212; --paper: #1C1C1C; --soft: color-mix(in srgb, var(--line) 45%, var(--paper)); --track: var(--line);
  --line: #323232; --line-strong: #8A8A86; --ink: #F5F5F3; --ink-2: #D6D6D3; --muted: #ADADA9; --faint: var(--muted);
  --brand: #8A8A86; --brand-deep: #F5F5F3; --brand-text: #F5F5F3; --on-brand: #121212; --brand-soft: #2A2A2A;
  --btn: #F5F5F3; --btn-ink: #121212;
  --ok: #86D19F; --ok-bg: #1B3324; --warn: #F2C77A; --warn-bg: #3A2F17; --warn-line: #6B5426;
  --bad: #F0907C; --on-bad: #121212; --bad-bg: #3E2622; --bad-line: color-mix(in srgb, var(--bad) 35%, var(--bad-bg)); --heat: #F08A55; --cool: #6DB7EC;
  --hero: #1C1C1C; --shadow: 0 8px 24px rgba(0, 0, 0, .45); --logo-ring: var(--line-strong); color-scheme: dark;
} }
:root[data-theme="dark"] {
  --page: #121212; --paper: #1C1C1C; --soft: color-mix(in srgb, var(--line) 45%, var(--paper)); --track: var(--line);
  --line: #323232; --line-strong: #8A8A86; --ink: #F5F5F3; --ink-2: #D6D6D3; --muted: #ADADA9; --faint: var(--muted);
  --brand: #8A8A86; --brand-deep: #F5F5F3; --brand-text: #F5F5F3; --on-brand: #121212; --brand-soft: #2A2A2A;
  --btn: #F5F5F3; --btn-ink: #121212;
  --ok: #86D19F; --ok-bg: #1B3324; --warn: #F2C77A; --warn-bg: #3A2F17; --warn-line: #6B5426;
  --bad: #F0907C; --on-bad: #121212; --bad-bg: #3E2622; --bad-line: color-mix(in srgb, var(--bad) 35%, var(--bad-bg)); --heat: #F08A55; --cool: #6DB7EC;
  --hero: #1C1C1C; --shadow: 0 8px 24px rgba(0, 0, 0, .45); --logo-ring: var(--line-strong); color-scheme: dark;
}
* { box-sizing: border-box; }
[hidden] { display: none !important; }
body { margin: 0; min-height: 100vh; }
a { color: var(--green); }

.hp-bar {
  position: sticky; top: 0; z-index: 5;
  display: flex; align-items: center; justify-content: space-between; gap: 12px;
  padding: max(12px, env(safe-area-inset-top)) 16px 12px;
  background: color-mix(in srgb, var(--page) 88%, transparent); -webkit-backdrop-filter: blur(12px); backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--line); color: var(--ink);
}
.hp-brand { display: inline-flex; align-items: center; gap: 10px; min-width: 0; color: var(--ink); text-decoration: none; font-weight: 800; font-size: 17px; letter-spacing: -.3px; }
.hp-mark { display: grid; place-items: center; flex: none; width: 32px; height: 32px; border-radius: 10px; background: var(--brand-deep); color: var(--on-brand); font-weight: 800; overflow: hidden; }
.hp-mark img { width: 100%; height: 100%; object-fit: contain; background: var(--paper); }
.hp-brand-sub { display: block; font-size: 11px; font-weight: 600; color: var(--faint); letter-spacing: 0; }
.hp-account { position: relative; margin: 0; font-size: 14px; min-width: 0; }
.hp-account summary { display: grid; place-items: center; cursor: pointer; list-style: none; width: 36px; height: 36px; border-radius: 50%; background: var(--soft); color: var(--ink-2); font-weight: 800; font-size: 13px; }
.hp-account summary::-webkit-details-marker { display: none; }
.hp-account-menu {
  position: absolute; right: 0; top: calc(100% + 6px); min-width: 220px; max-width: calc(100vw - 32px);
  padding: 12px 14px; background: var(--paper); color: var(--ink); border: 1px solid var(--line);
  border-radius: var(--radius); box-shadow: var(--shadow);
}
.hp-account-menu a { display: block; padding: 8px 0; color: var(--green); font-weight: 600; text-decoration: none; }
.hp-account-menu form { margin: 0; border-top: 1px solid var(--line); }
.hp-account-menu .hp-link { color: var(--ink); width: 100%; text-align: left; }
.hp-account-email { margin: 0 0 6px; color: var(--muted); font-size: 13px; overflow-wrap: anywhere; }
.hp-account-email strong { color: var(--ink); }
.hp-who { color: var(--faint); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; max-width: 40vw; }
.hp-link { border: 0; background: none; color: var(--btn-ink); font: inherit; font-weight: 600; padding: 8px 0; cursor: pointer; }

.hp-main { width: 100%; max-width: 680px; margin: 0 auto; padding: 20px 16px 48px; }
.hp-eyebrow { display: flex; align-items: center; gap: 8px; font-size: 12px; letter-spacing: .08em; font-weight: 800; color: var(--muted); text-transform: uppercase; }
h1 { font-size: 34px; line-height: 1.05; letter-spacing: -.02em; font-weight: 800; margin: 8px 0 0; text-wrap: balance; }
h2 { font-size: 20px; letter-spacing: -.02em; font-weight: 800; margin: 0; }
h3 { font-size: 13px; letter-spacing: .4px; text-transform: uppercase; color: var(--muted); margin: 0 0 8px; }
.hp-sub { color: var(--muted); margin: 8px 0 0; font-size: 17px; line-height: 1.4; }
.hp-intro { margin: -6px 0 16px; }
.hp-back { display: inline-block; margin-bottom: 12px; color: var(--muted); text-decoration: none; font-weight: 600; font-size: 15px; padding: 6px 0; }

.hp-head { display: flex; align-items: flex-start; justify-content: space-between; gap: 12px; margin-bottom: 20px; }
.hp-section-head { display: flex; align-items: center; justify-content: space-between; margin: 28px 0 12px; }
.hp-count { display: inline-grid; place-items: center; min-width: 26px; height: 22px; padding: 0 7px; margin-left: 6px; border-radius: 11px; background: var(--brand-soft); color: var(--green); font-size: 13px; vertical-align: 2px; }

.hp-card { background: var(--paper); border: 1px solid var(--line); border-radius: 22px; padding: 20px; }
.hp-button {
  display: inline-flex; align-items: center; justify-content: center; gap: 6px;
  min-height: 48px; padding: 0 24px; border: 1.5px solid var(--accent); border-radius: 999px;
  background: var(--accent); color: var(--accent-ink); font: 800 16px var(--font); text-decoration: none; cursor: pointer;
  box-shadow: 0 8px 22px var(--accent-glow); transition: transform .15s;
}
.hp-button:active { transform: scale(.98); }
.hp-button:hover { filter: brightness(1.08); }
.hp-button-quiet { background: var(--track); color: var(--ink); border-color: var(--track); box-shadow: none; }
.hp-button-quiet:hover { background: var(--soft); }
.hp-button-danger { background: var(--danger); border-color: var(--danger); color: var(--on-bad); }
.hp-button-danger:hover { background: var(--bad); }
.hp-small { min-height: 40px; padding: 0 14px; font-size: 15px; white-space: nowrap; }
.hp-wide { width: 100%; }
.hp-actions, .hp-form-actions { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 20px; }

.hp-list { list-style: none; margin: 0; padding: 0; display: grid; gap: 10px; }
.hp-row {
  display: flex; align-items: center; gap: 14px; padding: 16px; min-height: 64px;
  background: var(--paper); border: 1px solid var(--line); border-radius: 20px;
  color: var(--ink); text-decoration: none;
}
.hp-row:hover { border-color: var(--line-strong); }
.hp-row-icon { display: grid; place-items: center; flex: none; width: 40px; height: 40px; border-radius: 11px; background: var(--brand-soft); color: var(--green); font-size: 20px; }
.hp-row-body { display: grid; gap: 3px; min-width: 0; flex: 1; }
.hp-row-body strong { font-size: 17px; }
.hp-row-body span { color: var(--muted); font-size: 14px; line-height: 1.4; overflow-wrap: anywhere; }
.hp-row-body .hp-link-line { color: var(--green); font-size: 13px; }
.hp-row-meta { color: var(--muted); font-size: 13px; white-space: nowrap; }
.hp-chevron { color: var(--faint); font-size: 24px; }
.hp-group { margin-bottom: 22px; }

.hp-empty { text-align: center; padding: 32px 22px; }
.hp-empty p { color: var(--muted); line-height: 1.5; margin: 8px 0 20px; }
.hp-empty-icon { display: inline-grid; place-items: center; width: 52px; height: 52px; border-radius: 15px; background: var(--brand-soft); color: var(--green); font-size: 26px; margin-bottom: 12px; }
.hp-empty-small { padding: 22px; }
.hp-empty-small p { margin-top: 0; }

.hp-form { display: grid; gap: 14px; }
.hp-fieldset { margin: 0; display: grid; gap: 14px; min-width: 0; }
.hp-fieldset legend { float: left; width: 100%; font-weight: 700; font-size: 16px; margin-bottom: 2px; }
.hp-field { display: grid; gap: 6px; min-width: 0; }
.hp-field label { font-size: 14px; font-weight: 600; }
.hp-field input:not([type="checkbox"]), .hp-field select, .hp-field textarea {
  width: 100%; min-height: 46px; padding: 10px 12px; border: 1px solid var(--line-strong); border-radius: 10px;
  background: var(--paper); color: var(--ink); font: 16px var(--font);
}
.hp-field textarea { min-height: 96px; resize: vertical; }
.hp-field input:focus, .hp-field select:focus, .hp-field textarea:focus { outline: 3px solid color-mix(in srgb, var(--brand) 40%, transparent); border-color: var(--brand-deep); }
.hp-check { display: flex !important; align-items: center; gap: 10px; font-weight: 500 !important; font-size: 15px !important; min-height: 40px; }
.hp-check input { width: 22px; height: 22px; accent-color: var(--green); }
.hp-help { margin: 0; color: var(--muted); font-size: 13px; line-height: 1.4; }
.hp-error { margin: 0; color: var(--danger); font-size: 14px; font-weight: 600; }
.has-error input, .has-error select, .has-error textarea { border-color: var(--danger) !important; }
.hp-grid-2 { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.hp-sticky-actions { position: sticky; bottom: 0; margin: 0 -16px; padding: 12px 16px max(12px, env(safe-area-inset-bottom)); background: linear-gradient(transparent, var(--page) 30%); }
.hp-sticky-actions .hp-button { flex: 1; }

.hp-facts { margin: 0; display: grid; gap: 0; padding: 4px 20px; }
.hp-facts div { display: flex; justify-content: space-between; gap: 16px; padding: 13px 0; border-top: 1px solid var(--soft); }
.hp-facts div:first-child { border-top: 0; }
.hp-facts dt { color: var(--muted); font-size: 15px; }
.hp-facts dd { margin: 0; font-weight: 600; font-size: 15px; text-align: right; overflow-wrap: anywhere; }
.hp-links { margin-bottom: 14px; display: grid; gap: 10px; }
.hp-links p { margin: 0; display: flex; flex-wrap: wrap; gap: 6px 12px; align-items: baseline; }
.hp-links span { color: var(--muted); font-size: 14px; width: 100%; }
.hp-links a { font-weight: 600; }
.hp-notes { margin-top: 14px; }
.hp-notes p { margin: 0; line-height: 1.5; }
.hp-danger-link { margin-top: 28px; text-align: center; }
.hp-danger-link a { color: var(--danger); font-weight: 600; }
.hp-confirm h1 { font-size: 22px; }
.hp-confirm p { color: var(--muted); line-height: 1.5; }

.hp-auth-card { margin-top: 12px; }
.hp-auth-card form { display: grid; gap: 14px; margin-top: 18px; }
.hp-auth-card > .hp-button { margin-top: 18px; }
.hp-duplicate { border-color: var(--warn-line); background: var(--warn-bg); display: grid; gap: 12px; margin-bottom: 14px; }
.hp-duplicate p, .hp-duplicate form { margin: 0; }
.hp-note { color: var(--muted); font-size: 15px; margin: 18px 0 0; text-align: center; }

.hp-hero { padding: 28px 4px 8px; }
.hp-hero h1 { font-size: 32px; }
.hp-hero p { color: var(--muted); font-size: 17px; line-height: 1.5; margin: 14px 0 0; }
.hp-points { list-style: none; padding: 0; margin: 28px 0 0; display: grid; gap: 10px; }
.hp-points li { background: var(--paper); border: 1px solid var(--line); border-radius: var(--radius); padding: 16px 18px; display: grid; gap: 4px; }
.hp-points span { color: var(--muted); line-height: 1.45; }

@media (min-width: 640px) {
  .hp-main { padding-top: 32px; }
  h1 { font-size: 30px; }
  .hp-sticky-actions { position: static; margin: 0; padding: 0; background: none; }
  .hp-sticky-actions .hp-button { flex: none; }
}
@media (max-width: 380px) {
  .hp-grid-2 { grid-template-columns: 1fr; }
}

/* ── Logs: chips, photos, timeline ───────────────────────────────────────── */
.hp-chips { display: flex; flex-wrap: wrap; gap: 8px; }
.hp-chip { position: relative; display: inline-flex; }
.hp-chip input { position: absolute; opacity: 0; width: 1px; height: 1px; }
.hp-chip span {
  display: inline-flex; align-items: center; min-height: 44px; padding: 0 16px; border-radius: 22px;
  border: 1px solid var(--line-strong); background: var(--paper); font-size: 15px; font-weight: 600; color: var(--ink); cursor: pointer;
  user-select: none; -webkit-user-select: none;
}
.hp-chip input:checked + span { background: var(--green); border-color: var(--green); color: var(--btn-ink); }
.hp-chip input:focus-visible + span { outline: 3px solid color-mix(in srgb, var(--brand) 60%, transparent); outline-offset: 2px; }
.hp-chips-severity .hp-chip:last-child input:checked + span { background: var(--danger); border-color: var(--danger); }
.has-error .hp-chip span { border-color: var(--danger); }

.hp-safety { display: none; margin: 4px 0 0; padding: 14px 16px; border-radius: 10px; background: var(--bad-bg); color: var(--bad); font-weight: 600; line-height: 1.45; }
.hp-safety.is-shown, fieldset:has(input[value="smell"]:checked) .hp-safety { display: block; }
.hp-safety.is-shown { margin-bottom: 14px; }

.hp-contractor-only { display: none; }
.hp-who-did:has(input[value="contractor"]:checked) .hp-contractor-only { display: block; }

.hp-file { display: flex !important; align-items: center; justify-content: center; min-height: 52px; border: 2px dashed var(--line-strong); border-radius: 12px; color: var(--green); font-weight: 700 !important; font-size: 16px !important; cursor: pointer; position: relative; }
.hp-file input { position: absolute; inset: 0; opacity: 0; width: 100%; cursor: pointer; }
.hp-file:focus-within { outline: 3px solid color-mix(in srgb, var(--brand) 40%, transparent); }

.hp-photos h3 { margin-bottom: 12px; }
.hp-photo-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; }
.hp-photo-grid a, .hp-photo-remove { display: block; aspect-ratio: 1; border-radius: 10px; overflow: hidden; background: var(--track); }
.hp-photo-grid img { width: 100%; height: 100%; object-fit: cover; display: block; }
.hp-photo-remove { position: relative; cursor: pointer; }
.hp-photo-remove input { position: absolute; opacity: 0; }
.hp-photo-remove span { position: absolute; left: 6px; bottom: 6px; padding: 3px 8px; border-radius: 8px; background: color-mix(in srgb, var(--ink) 80%, transparent); color: var(--btn-ink); font-size: 12px; font-weight: 700; }
.hp-photo-remove:has(input:checked) img { opacity: .35; }
.hp-photo-remove:has(input:checked) span { background: var(--danger); }
.hp-photos { margin-top: 14px; }

.hp-log-actions { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; margin: 4px 0 8px; }
.hp-button-alert { background: var(--bad); border-color: var(--bad); color: var(--on-bad); }
.hp-text-link { font-weight: 700; text-decoration: none; }
.hp-empty-line { margin-top: 12px; }

.hp-row-icon.is-symptom { background: var(--warn-bg); color: var(--warn); font-weight: 800; }
.hp-row-icon.is-resolved { background: var(--ok-bg); color: var(--ok); font-weight: 800; }
.hp-row-icon.is-maintenance { background: var(--soft); font-size: 18px; }
.hp-status { display: inline-block; justify-self: start; padding: 2px 10px; border-radius: 10px; background: var(--warn-bg); color: var(--warn) !important; font-size: 12px !important; font-weight: 700; }
.hp-status.is-urgent { background: var(--bad-bg); color: var(--bad) !important; }
.hp-status.is-resolved { background: var(--ok-bg); color: var(--ok) !important; }
.hp-timeline { margin-bottom: 8px; }
.hp-log-actions .hp-button { padding: 0 10px; font-size: 15px; text-align: center; line-height: 1.2; }

/* ── Household ───────────────────────────────────────────────────────────── */
.hp-person { display: flex; align-items: center; gap: 14px; padding: 14px 16px; background: var(--paper); border: 1px solid var(--line); border-radius: var(--radius); }
.hp-person form { margin: 0; }
.hp-person .hp-row-icon { font-weight: 800; font-size: 17px; }
.hp-row-icon.is-pending { background: var(--soft); color: var(--muted); }
.hp-link-button { border: 0; background: none; padding: 8px 4px; color: var(--danger); font: 600 15px var(--font); cursor: pointer; }
.hp-people { margin-bottom: 8px; }
.hp-household-link { margin-top: 28px; }
.hp-options { display: grid; gap: 8px; }
.hp-option { position: relative; display: block; }
.hp-option input { position: absolute; opacity: 0; }
.hp-option span { display: block; padding: 14px 16px; border: 1px solid var(--line-strong); border-radius: 12px; background: var(--paper); font-size: 15px; font-weight: 500 !important; line-height: 1.4; cursor: pointer; }
.hp-option input:checked + span { border-color: var(--green); box-shadow: inset 0 0 0 1px var(--green); background: var(--brand-soft); }
.hp-option input:focus-visible + span { outline: 3px solid color-mix(in srgb, var(--brand) 60%, transparent); }
.hp-home-only { display: none; }
.hp-invite-form:has(input[value="log_home"]:checked) .hp-home-only { display: grid; gap: 14px; }
.hp-link-box input { width: 100%; min-height: 48px; padding: 10px 12px; margin-top: 16px; border: 1px solid var(--line-strong); border-radius: 10px; background: var(--soft); font: 15px ui-monospace, monospace; color: var(--ink); }
.hp-invite-ready h1, .hp-join h1 { font-size: 23px; }

.hp-person:has(> .hp-person-main) { flex-direction: column; align-items: stretch; gap: 10px; }
.hp-person-main { display: flex; align-items: center; gap: 14px; }
.hp-person.is-flagged { border-color: var(--bad-line); }
.hp-renew summary { cursor: pointer; color: var(--green); font-weight: 700; font-size: 14px; padding: 4px 0; }
.hp-renew-form { display: flex; gap: 8px; margin-top: 8px; }
.hp-renew-form input { flex: 1; min-height: 40px; padding: 6px 10px; border: 1px solid var(--line-strong); border-radius: 10px; font: 15px system-ui, sans-serif; }
.hp-ends-on, .hp-for-tenant, .hp-for-guest { display: none; }
.hp-invite-form:has(input[name="occupant_kind"]:checked) .hp-ends-on { display: grid; }
.hp-invite-form:has(input[value="tenant"]:checked) .hp-for-tenant,
.hp-invite-form:has(input[value="guest"]:checked) .hp-for-guest { display: inline; }
.hp-invite-form:has(input[value="tenant"]:checked) p.hp-for-tenant,
.hp-invite-form:has(input[value="guest"]:checked) p.hp-for-guest { display: block; }
.hp-ends-on.has-error { display: grid; }

/* ── Home pulse ──────────────────────────────────────────────────────────── */
.hp-pulse { --beat: var(--hero-ok); --beat-soft: color-mix(in srgb, var(--hero-ok) 25%, transparent); position: relative; overflow: hidden; margin: 0 0 16px; padding: 18px 20px 14px; border-radius: 18px; background: var(--hero); color: var(--hero-ink); }
.hp-pulse-attention { --beat: var(--hero-warn); --beat-soft: var(--hero-warn); }
.hp-pulse-sick { --beat: var(--hero-bad); --beat-soft: var(--hero-bad); }
.hp-pulse-none { --beat: var(--muted); }
.hp-pulse-top { display: flex; align-items: flex-start; justify-content: space-between; }
.hp-pulse-score { display: flex; align-items: baseline; gap: 12px; }
.hp-pulse-score strong { font-size: 52px; line-height: 1; letter-spacing: -2px; font-weight: 800; color: var(--hero-ink); }
.hp-pulse-band { font-size: 18px; font-weight: 700; color: var(--beat); }
.hp-pulse-line { height: 64px; margin: 8px -20px 0; -webkit-mask-image: linear-gradient(90deg, transparent, #000 12%, #000 88%, transparent); mask-image: linear-gradient(90deg, transparent, #000 12%, #000 88%, transparent); }
.hp-pulse-line svg { width: 100%; height: 100%; display: block; overflow: visible; }
.hp-pulse-line path { fill: none; stroke: var(--beat); stroke-width: 2.4; stroke-linejoin: round; stroke-linecap: round; vector-effect: non-scaling-stroke; filter: drop-shadow(0 0 4px var(--beat)); }
.hp-pulse-track { animation-name: hp-beat; animation-timing-function: linear; animation-iteration-count: infinite; }
.hp-pulse-none .hp-pulse-track, .hp-pulse-none path { animation: none; opacity: .4; }
@keyframes hp-beat { from { transform: translateX(0); } to { transform: translateX(-480px); } }
@media (prefers-reduced-motion: reduce) { .hp-pulse-track { animation: none !important; } }
.hp-pulse-summary { margin: 4px 0 0; color: var(--hero-muted); font-size: 15px; line-height: 1.4; }
.hp-pulse-why { margin-top: 10px; }
.hp-pulse-why summary { cursor: pointer; color: var(--hero-ink); font-weight: 700; font-size: 15px; padding: 6px 0; }
.hp-pulse-why ul { list-style: none; margin: 6px 0 0; padding: 0; display: grid; gap: 2px; }
.hp-pulse-why li { display: grid; grid-template-columns: 1fr auto; gap: 2px 12px; padding: 10px 0; border-top: 1px solid var(--hero-rule); }
/* Each item says how urgent it is in words, so the tier never rests on color alone. */
.hp-why-tier { grid-column: 1; color: var(--hero-muted); font-size: 12px; font-weight: 800; letter-spacing: .4px; text-transform: uppercase; }
.hp-why-tier.is-attention { color: var(--hero-warn); } .hp-why-tier.is-urgent { color: var(--hero-bad); }
.hp-pulse-why a { display: contents; color: inherit; text-decoration: none; }
.hp-why-title { grid-column: 1; font-weight: 600; font-size: 15px; color: var(--hero-ink); }
.hp-why-detail { grid-column: 1; color: var(--hero-muted); font-size: 13px; }
.hp-why-points { grid-column: 2; grid-row: 1; font-weight: 800; color: var(--hero-muted); font-variant-numeric: tabular-nums; }
.hp-pulse-why .hp-help { color: var(--hero-muted); margin-top: 10px; }

.hp-row-meta { display: grid; justify-items: end; gap: 4px; }
.hp-mini-pulse { --beat: var(--ok); display: inline-flex; align-items: center; gap: 6px; padding: 2px 9px; border-radius: 12px; background: var(--ok-bg); color: var(--ok); font-weight: 800; font-size: 14px; }
.hp-mini-pulse.hp-pulse-attention { --beat: var(--warn); background: var(--warn-bg); color: var(--warn); }
.hp-mini-pulse.hp-pulse-sick { --beat: var(--bad); background: var(--bad-bg); color: var(--bad); }
.hp-mini-pulse i { width: 8px; height: 8px; border-radius: 50%; background: var(--beat); animation: hp-dot 1.25s ease-in-out infinite; }
.hp-mini-pulse.hp-pulse-attention i { animation-duration: .8s; }
.hp-mini-pulse.hp-pulse-sick i { animation-duration: .58s; }
@keyframes hp-dot { 0%, 100% { transform: scale(1); opacity: 1; } 50% { transform: scale(.55); opacity: .6; } }
@media (prefers-reduced-motion: reduce) { .hp-mini-pulse i { animation: none; } }

/* Contractor card */
.hp-contractor { margin: 14px 0 6px; display: grid; gap: 14px; }
.hp-contractor-head { display: flex; justify-content: space-between; align-items: flex-start; gap: 12px; }
.hp-contractor-head > div { display: grid; gap: 2px; }
.hp-contractor-name { font-size: 19px; margin-top: 4px; }
.hp-contractor-head .hp-sub { margin: 0; font-size: 14px; }
.hp-contact-actions { display: grid; grid-auto-flow: column; grid-auto-columns: 1fr; gap: 10px; }
.hp-contact {
  display: inline-flex; align-items: center; justify-content: center; gap: 6px; min-height: 44px; padding: 0 14px;
  border-radius: 999px; border: 2px solid var(--brand-deep); background: transparent; color: var(--ink);
  font-weight: 800; font-size: 15px; text-decoration: none;
}
.hp-contact:first-child { background: var(--btn); border-color: var(--btn); color: var(--btn-ink); }
.hp-contact span { font-size: 16px; line-height: 1; }
.hp-contact:active { transform: scale(.98); }
.hp-after-hours a { font-weight: 700; }
.hp-send { margin: 0; }
.hp-tenant-note { padding-top: 12px; border-top: 1px solid var(--soft); }
.hp-add-contractor { margin: 14px 0 6px; }
.hp-row-button { width: 100%; font: inherit; text-align: left; cursor: pointer; }
.hp-frequency { margin-top: 12px; }
.hp-frequency h1 { margin: 0 0 8px; }
.hp-frequency-options { display: grid; gap: 10px; margin-top: 20px; }
.hp-frequency-choice { display: grid; gap: 4px; width: 100%; padding: 15px 16px; border: 1px solid var(--line); border-radius: var(--radius); background: var(--paper); color: var(--ink); font: inherit; text-align: left; cursor: pointer; }
.hp-frequency-choice:hover, .hp-frequency-choice.is-current { border-color: var(--green); background: var(--brand-soft); }
.hp-frequency-choice-main { display: flex; align-items: center; justify-content: space-between; font-weight: 700; }
.hp-frequency-check { color: var(--green); font-size: 20px; }
.hp-frequency-detail, .hp-frequency-note { color: var(--muted); font-size: 14px; line-height: 1.4; }
.hp-frequency-note { margin: 12px 0 0; }
.hp-use { color: var(--green); font-weight: 700; font-size: 15px; }
.hp-or { margin-top: 22px; }
.hp-more summary { font-weight: 700; cursor: pointer; padding: 2px 0; }
.hp-more-body { display: grid; gap: 14px; margin-top: 16px; }

/* Sending a report */
.hp-picks { display: grid; gap: 8px; }
.hp-pick { display: flex; gap: 12px; align-items: flex-start; padding: 12px; border: 1px solid var(--line); border-radius: 10px; font-size: 15px; line-height: 1.35; cursor: pointer; }
.hp-pick input { flex: none; width: 22px; height: 22px; margin: 0; accent-color: var(--green); }
.hp-pick:has(input:checked) { border-color: var(--green); background: var(--brand-soft); }
.hp-symptom-actions { display: grid; gap: 10px; margin: 0 0 14px; }
.hp-sent-line { margin: 0 0 14px; color: var(--muted); font-size: 14px; text-align: center; }
.hp-banner { display: flex; align-items: center; gap: 10px; margin: 0 0 14px; padding: 14px 16px; border-radius: 18px; border: 1px solid color-mix(in srgb, var(--brand) 25%, var(--line)); background: var(--brand-soft); color: var(--ink); font-weight: 600; line-height: 1.45; }
.hp-banner::before { content: ""; flex: none; width: 10px; height: 10px; border-radius: 50%; background: var(--brand); box-shadow: 0 0 0 4px color-mix(in srgb, var(--brand) 22%, transparent); }

/* Tenant or guest emergency */
.hp-emergency { margin: 0 0 14px; display: grid; gap: 10px; border-color: var(--bad-line); background: var(--bad-bg); }
.hp-emergency h2 { margin: 0; font-size: 19px; }
.hp-emergency p { margin: 0; line-height: 1.45; }
.hp-emergency .hp-help { text-align: center; }

/* Contractor's report page */
.hp-report-contact { margin: 4px 0 6px; }
.hp-center { text-align: center; }
.hp-report-h { margin: 26px 0 10px; }
.hp-report-entry { margin-bottom: 10px; display: grid; gap: 6px; }
.hp-report-entry-head { display: flex; justify-content: space-between; align-items: flex-start; gap: 10px; }
.hp-report-entry-head strong { font-size: 17px; line-height: 1.3; }
.hp-report-entry-head .hp-status { flex: none; }
.hp-report-note { margin: 4px 0 0; line-height: 1.5; }
.hp-report-entry .hp-photo-grid { margin-top: 6px; }
.hp-send-entry { margin: 0 0 10px; }
.hp-sent { display: grid; gap: 12px; text-align: center; }
.hp-sent .hp-empty-icon { justify-self: center; margin: 0; }
.hp-sent h1, .hp-sent .hp-sub { margin: 0; }
.hp-share-more summary { color: var(--green); font-weight: 700; cursor: pointer; padding: 6px 0; }
.hp-share-body { display: grid; gap: 10px; margin-top: 10px; text-align: left; }
.hp-share-body .hp-form-actions { margin: 0; }
.hp-banner.is-error { background: var(--bad-bg); color: var(--bad); border-color: var(--bad-line); }
.hp-banner.is-error::before { background: var(--bad); box-shadow: 0 0 0 4px var(--bad-line); }
.hp-verify { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin: 0 0 14px; padding: 10px 14px; border-radius: 10px; background: var(--warn-bg); color: var(--warn); font-size: 14px; line-height: 1.4; }
.hp-link-quiet { flex: none; border: 0; background: none; padding: 6px 2px; color: var(--warn); font: 700 14px var(--font); text-decoration: underline; cursor: pointer; }

/* Contractor gifts */
.hp-pro-link { margin-top: 12px; }
.hp-gift-row { display: flex; justify-content: space-between; align-items: center; gap: 12px; padding: 14px 16px; }
.hp-gift-main { display: grid; gap: 3px; min-width: 0; }
.hp-gift-main span { color: var(--muted); font-size: 14px; overflow-wrap: anywhere; }
.hp-gift-status { font-weight: 700; font-size: 13px !important; }
.hp-gift-status.is-joined { color: var(--green) !important; }
.hp-gift-status.is-waiting { color: var(--warn) !important; }
.hp-gift-actions { display: grid; justify-items: end; gap: 2px; flex: none; }
.hp-gift-actions .hp-link-button { font-size: 14px; padding: 4px; color: var(--muted); }
.hp-two { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.hp-gift-hero { margin: 4px 0 18px; }
.hp-gift-hero h1 { margin-top: 6px; }
.hp-gift-logo { display: block; max-height: 56px; max-width: 200px; width: auto; margin: 0 0 12px; }
.hp-gift-banner { border: 2px solid var(--mint); margin-bottom: 14px; }
.hp-row-static { cursor: default; }
.hp-gift-cta { display: grid; gap: 12px; margin-top: 16px; text-align: center; }
.hp-gift-cta .hp-note { margin: 0; }
.hp-notes + .hp-group { margin-top: 22px; }

/* Monthly checklist */
.hp-checklist-link { margin-top: 10px; }
.hp-tasks { gap: 10px; }
.hp-task { display: flex; justify-content: space-between; align-items: flex-start; gap: 14px; padding: 16px; }
.hp-task-body { display: grid; gap: 4px; min-width: 0; }
.hp-task-body strong { font-size: 16px; line-height: 1.3; }
.hp-task-body p { margin: 0; color: var(--muted); font-size: 14px; line-height: 1.45; }
.hp-task-for { color: var(--green); font-size: 13px; font-weight: 600; }
.hp-task-actions { display: grid; justify-items: center; gap: 6px; flex: none; }

/* Account */
a.hp-who { text-decoration: none; }
a.hp-who:hover { color: var(--btn-ink); }
.hp-footer { max-width: 680px; margin: 0 auto; padding: 8px 16px 32px; text-align: center; color: var(--muted); font-size: 13px; }
.hp-footer a { color: var(--muted); }
.hp-setting { display: flex; justify-content: space-between; align-items: center; gap: 14px; padding: 16px; }
.hp-setting > div { display: grid; gap: 3px; }
.hp-setting span { color: var(--muted); font-size: 14px; line-height: 1.4; }
.hp-delete-summary { display: grid; gap: 10px; margin-bottom: 14px; }
.hp-delete-summary p, .hp-delete-summary ul { margin: 0; line-height: 1.5; }
.hp-delete-summary ul { padding-left: 20px; }

/* Privacy policy and terms */
.hp-legal { line-height: 1.6; }
.hp-legal h2 { font-size: 18px; margin: 26px 0 8px; }
.hp-legal p, .hp-legal li { font-size: 15px; }
.hp-legal ul { padding-left: 20px; }
.hp-draft { margin: 0 0 16px; padding: 12px 14px; border-radius: 10px; background: var(--warn-bg); color: var(--warn); font-size: 14px; line-height: 1.45; }

.hp-offer-count { display: flex; align-items: center; justify-content: space-between; gap: 12px; }
.hp-offer-count span { min-width: 0; overflow-wrap: anywhere; }
.hp-offer-count strong { font-size: 1.25rem; font-variant-numeric: tabular-nums; }

/* Contractor application review */
.hp-review-row { display: grid; gap: 3px; padding: 14px 16px; }
.hp-review-row span { color: var(--muted); font-size: 14px; overflow-wrap: anywhere; }
.hp-review-row .hp-gift-actions { display: flex; justify-content: flex-start; gap: 8px; margin-top: 8px; }
.hp-review-flag { color: var(--warn); font-style: normal; font-weight: 700; }
.hp-review-warning { margin: 6px 0 0; color: var(--warn); font-size: 14px; }

/* Contractor landing page */
.hp-landing-section { margin: 32px 0 0; }
.hp-landing-section h2 { font-size: 22px; margin: 0 0 10px; }
.hp-landing-section p { line-height: 1.55; margin: 0 0 10px; }
.hp-landing-section .hp-points { margin-top: 0; }
.hp-steps { padding-left: 22px; margin: 0; display: grid; gap: 10px; line-height: 1.5; }
.hp-faq dt { font-weight: 700; margin: 16px 0 4px; }
.hp-faq dd { margin: 0; color: var(--muted); line-height: 1.5; }
.hp-landing-close { padding: 8px 0 24px; }
.hp-landing-close p { font-size: 18px; font-weight: 600; }

/* Company switcher for admins of more than one contractor company */
.hp-company-switch { display: flex; align-items: center; gap: 8px; margin: 0 0 12px; flex-wrap: wrap; }
.hp-company-switch select { flex: 1; min-width: 0; }

/* Contractor coupons on the home's card */
.hp-coupon { display: grid; gap: 4px; padding: 10px 12px; margin-top: 10px; border: 1px dashed var(--line); border-radius: var(--radius); }
.hp-coupon span { color: var(--muted); font-size: 14px; }
.hp-coupon .hp-button { justify-self: start; }

/* Bookings listed under each coupon on /pro/coupons/ */
.hp-coupon-bookings { list-style: none; padding: 0; margin: 8px 0 0; display: grid; gap: 6px; }
.hp-coupon-bookings li { display: flex; align-items: center; justify-content: space-between; gap: 8px; flex-wrap: wrap; font-size: 14px; }
.hp-coupon-bookings a { color: var(--green); overflow-wrap: anywhere; }

/* The two spaces: a segmented control under the header, for people who have both. */

/* Section nav: a scrolling row of chips with icons; the current one is filled with the brand color. */
.hp-tabs { display: flex; gap: 10px; overflow-x: auto; padding: 14px 16px 2px; scrollbar-width: none; }
.hp-tabs::-webkit-scrollbar { display: none; }
.hp-tabs a { display: inline-flex; align-items: center; gap: 8px; flex: none; min-height: 46px; padding: 0 18px; border-radius: 16px; background: var(--soft); color: var(--ink-2); text-decoration: none; font-weight: 700; font-size: 15px; }
.hp-tabs a svg { width: 18px; height: 18px; flex: none; }
.hp-tabs a[aria-current="page"] { background: var(--brand-deep); color: var(--on-brand); }
@media (min-width: 720px) { .hp-tabs { max-width: 680px; margin: 0 auto; padding-left: 16px; padding-right: 16px; } }

/* Status pills and rows with a colored bar on the left. */
.hp-pill { display: inline-flex; align-items: center; padding: 4px 12px; border-radius: 999px; font-size: 13px; font-weight: 800; white-space: nowrap; background: var(--track); color: var(--ink-2); }
.hp-pill.is-ok { background: var(--ok-bg); color: var(--ok); } .hp-pill.is-warn { background: var(--warn-bg); color: var(--warn); }
.hp-pill.is-bad { background: var(--bad-bg); color: var(--bad); } .hp-pill.is-info { background: var(--brand-soft); color: var(--brand-text); }
.hp-barred { position: relative; padding-left: 26px; }
.hp-barred::before { content: ""; position: absolute; left: 12px; top: 14px; bottom: 14px; width: 6px; border-radius: 3px; background: var(--track); }
.hp-barred.is-ok::before { background: var(--ok); } .hp-barred.is-warn::before { background: var(--warn); } .hp-barred.is-bad::before { background: var(--bad); } .hp-barred.is-info::before { background: var(--brand-deep); }

/* Design step 2: page heads, banners as links, home cards with a health ring, empty boxes. */
.hp-hero-head { margin: 4px 0 20px; }
.hp-banner-link { text-decoration: none; justify-content: space-between; }
.hp-banner-link span { flex: 1; min-width: 0; }
.hp-banner-link b { flex: none; font-weight: 800; color: var(--ink); white-space: nowrap; }
.hp-banner.is-warn { background: var(--warn-bg); border-color: var(--warn-line); }
.hp-banner.is-warn::before { background: var(--warn); box-shadow: 0 0 0 4px color-mix(in srgb, var(--warn) 25%, transparent); }
.hp-home-card { display: grid; gap: 12px; padding: 18px; border: 1px solid var(--line); border-radius: 22px; background: var(--paper); color: var(--ink); text-decoration: none; }
.hp-home-card:hover { border-color: var(--line-strong); }
.hp-home-top { display: flex; align-items: center; gap: 14px; }
.hp-home-pills { display: flex; flex-wrap: wrap; gap: 8px; }
.hp-home-pills:empty { display: none; }
.hp-ring { --ring: var(--ok); display: grid; place-items: center; flex: none; width: 52px; height: 52px; border-radius: 50%; background: conic-gradient(var(--ring) var(--p, 0%), var(--track) 0); }
.hp-ring i { display: grid; place-items: center; width: 40px; height: 40px; border-radius: 50%; background: var(--paper); font-style: normal; font-weight: 800; font-size: 14px; }
.hp-ring.is-attention { --ring: var(--warn); } .hp-ring.is-sick { --ring: var(--bad); } .hp-ring.is-none { --ring: var(--track); }
.hp-empty-box { padding: 28px 22px; text-align: center; border: 1.5px dashed var(--line-strong); border-radius: 22px; }
.hp-empty-box p { color: var(--muted); margin: 8px 0 18px; }
.hp-actions-row { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 20px; }
.hp-button-outline { background: transparent; color: var(--ink); border: 2px solid var(--brand-deep); box-shadow: none; }

/* A segmented control for views of one thing (a home: Overview, Equipment, History). */
.hp-seg { display: flex; margin: 0 0 18px; padding: 4px; border-radius: 16px; background: var(--track); }
.hp-seg a { flex: 1; text-align: center; padding: 9px 8px; border-radius: 12px; color: var(--muted); font-weight: 700; font-size: 15px; text-decoration: none; }
.hp-seg a[aria-current="page"] { background: var(--paper); color: var(--ink); box-shadow: var(--shadow); }

/* Design step 3: the company space. */
.hp-stats { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; margin: 4px 0 16px; }
.hp-stat { display: grid; gap: 6px; padding: 16px; border: 1px solid var(--line); border-radius: 20px; background: var(--paper); }
.hp-stat strong { font-size: 34px; line-height: 1; font-weight: 800; letter-spacing: -.02em; font-variant-numeric: tabular-nums; }
.hp-stat span { color: var(--muted); font-size: 14px; }
.hp-section-card { margin: 0 0 16px; padding: 18px; }
.hp-section-head.hp-tight { margin: 0 0 6px; }
.hp-list-plain { gap: 0; }
.hp-list-row { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 14px 4px 14px 26px; border-top: 1px solid var(--line); list-style: none; }
.hp-list-plain > .hp-list-row:first-child { border-top: 0; }
.hp-list-row .hp-row-body strong { font-size: 16px; }
.hp-row-link { color: inherit; text-decoration: none; }
.hp-list-side { display: grid; justify-items: end; gap: 6px; flex: none; max-width: 52%; text-align: right; }
.hp-list-side .hp-pill { white-space: normal; }
.hp-link-strong { color: var(--ink); font-weight: 800; }
.hp-section-card.hp-list { padding: 6px 16px; }
.hp-roles { display: grid; gap: 10px; }
.hp-roles p { margin: 0; color: var(--muted); font-size: 14px; line-height: 1.5; }
.hp-roles .hp-pill { margin-right: 6px; }

/* Design step 4: forms and "what happened, what's next" after sending something. */
.hp-field input:not([type="checkbox"]):not([type="color"]), .hp-field select, .hp-field textarea { border-radius: 14px; background: var(--paper); color: var(--ink); }
.hp-field input[type="color"] { width: 64px; height: 44px; padding: 4px; border: 1px solid var(--line-strong); border-radius: 12px; background: var(--paper); }
.hp-next { list-style: none; margin: 16px 0; padding: 0; display: grid; gap: 12px; text-align: left; }
.hp-next li { display: grid; grid-template-columns: 28px 1fr; gap: 10px; align-items: start; font-size: 15px; line-height: 1.45; color: var(--ink-2); }
.hp-next li::before { content: "→"; display: grid; place-items: center; width: 28px; height: 28px; border-radius: 50%; background: var(--track); color: var(--muted); font-weight: 800; font-size: 14px; }
.hp-next li.is-done::before { content: "✓"; background: var(--ok-bg); color: var(--ok); }
.hp-next li.is-stop::before { content: "!"; background: var(--warn-bg); color: var(--warn); }
.hp-next strong { color: var(--ink); }

/* ── Light and dark ──────────────────────────────────────────────────────── */
.hp-bar-end { display: flex; align-items: center; gap: 8px; }
.hp-theme { margin: 0; }
.hp-theme button { display: grid; place-items: center; width: 44px; height: 44px; padding: 0; border-radius: 50%; border: 1px solid var(--line); background: var(--paper); color: var(--ink); cursor: pointer; }
.hp-theme svg { width: 20px; height: 20px; }
.hp-theme .hp-theme-light { display: none; }
@media (prefers-color-scheme: dark) { :root:not([data-theme="light"]) .hp-theme .hp-theme-dark { display: none; } :root:not([data-theme="light"]) .hp-theme .hp-theme-light { display: grid; } }
:root[data-theme="dark"] .hp-theme .hp-theme-dark { display: none; }
:root[data-theme="dark"] .hp-theme .hp-theme-light { display: grid; }
.hp-seg button { flex: 1; padding: 9px 8px; border: 0; border-radius: 12px; background: none; color: var(--muted); font: 700 15px var(--font); cursor: pointer; }
.hp-seg button[aria-pressed="true"] { background: var(--paper); color: var(--ink); box-shadow: var(--shadow); }
.hp-setting-theme { display: grid; gap: 10px; }
.hp-setting-theme .hp-seg { margin: 0; }
.hp-seg-stack { flex-direction: column; }

/* ── The logo mark in the header ─────────────────────────────────────────── */
.hp-logo { background: var(--logo-tile); box-shadow: inset 0 0 0 1px var(--logo-ring, transparent); }
.hp-logo svg { width: 17px; height: 20px; }
.hp-logo .hp-logo-a { fill: var(--logo-a); }
.hp-logo .hp-logo-leaf { fill: var(--logo-leaf); }
.hp-logo .hp-logo-vein { fill: none; stroke: var(--logo-vein); stroke-width: 14; stroke-linecap: round; }
.hp-logo.is-pro { background: var(--logo-pro-tile); box-shadow: inset 0 0 0 1px var(--line-strong); }  /* A light tile: outlined on the light page. */
.hp-logo.is-pro .hp-logo-a { fill: var(--logo-pro-a); }
.hp-logo.is-pro .hp-logo-leaf { fill: var(--logo-pro-leaf); }
.hp-logo.is-pro .hp-logo-vein { stroke: var(--logo-pro-vein); }
.hp-brand-pro { color: var(--brand-text); }
