/* ============================================================================
   THE TRIBE — THE HEARTH IDENTITY  ·  "Daylight Hearth" design-token + component layer
   ----------------------------------------------------------------------------
   The Hearth = the warm, sunlit room you walk into where you're expected and
   welcome. Warmth comes from LIGHT + MATERIAL (bright warm-paper canvas, crisp
   TRUE-WHITE cards, soft real shadows, ONE luminous ember accent, ONE deep teal
   "trust" reserved for money/verified) — never from darkness.

   LIGHT ("Daylight") is the explicit default. DARK ("Evening") is a deliberately
   cozy chosen room, never a cave — reached only via the header sun/moon toggle
   (see /theme.js, which sets data-theme on <html> BEFORE first paint, no flash).

   Anti-cult law is enforced by these tokens + TRIBE_DESIGN_LAW.md: accent ~10%
   of any screen; money speaks in calm teal; the exit is as loud as the entrance;
   focus ring is ALWAYS visible (the founder is low-vision).

   Canonical tokens: --bg --bg-2 --surface --surface-2 --text --muted --faint
   --accent --accent-hover --accent-ink --accent-wash --secondary --trust
   --line --line-strong --focus-ring + shadow/radius/space scales.
   Legacy aliases (--ink --ember --growth …) mapped at the bottom so older pages
   keep working unchanged.
   ========================================================================== */

/* ---------------------------------------------------------------------------
   SELF-HOSTED FONTS (OFL, subset WOFF2, font-display:swap — no runtime CDN)
   Fraunces  = display ONLY (hero + section titles). Fallback Georgia, serif.
   Atkinson Hyperlegible Next = body/UI (built by the Braille Institute for low
   vision → serves the dyslexia/low-vision mandate). Fallback Inter/system-ui.
   Both are variable fonts; one file per subset covers the full weight range.
   --------------------------------------------------------------------------- */
@font-face{
  font-family:"Fraunces";font-style:normal;font-weight:400 600;font-display:swap;
  src:url("/fonts/fraunces-latin.woff2") format("woff2");
  unicode-range:U+0000-00FF,U+0131,U+0152-0153,U+02BB-02BC,U+02C6,U+02DA,U+02DC,U+0304,U+0308,U+0329,U+2000-206F,U+20AC,U+2122,U+2191,U+2193,U+2212,U+2215,U+FEFF,U+FFFD;
}
@font-face{
  font-family:"Fraunces";font-style:normal;font-weight:400 600;font-display:swap;
  src:url("/fonts/fraunces-latin-ext.woff2") format("woff2");
  unicode-range:U+0100-02BA,U+02BD-02C5,U+02C7-02CC,U+02CE-02D7,U+02DD-02FF,U+0304,U+0308,U+0329,U+1D00-1DBF,U+1E00-1E9F,U+1EF2-1EFF,U+2020,U+20A0-20AB,U+20AD-20C0,U+2113,U+2C60-2C7F,U+A720-A7FF;
}
@font-face{
  font-family:"Atkinson Hyperlegible Next";font-style:normal;font-weight:400 700;font-display:swap;
  src:url("/fonts/atkinson-latin.woff2") format("woff2");
  unicode-range:U+0000-00FF,U+0131,U+0152-0153,U+02BB-02BC,U+02C6,U+02DA,U+02DC,U+0304,U+0308,U+0329,U+2000-206F,U+20AC,U+2122,U+2191,U+2193,U+2212,U+2215,U+FEFF,U+FFFD;
}
@font-face{
  font-family:"Atkinson Hyperlegible Next";font-style:normal;font-weight:400 700;font-display:swap;
  src:url("/fonts/atkinson-latin-ext.woff2") format("woff2");
  unicode-range:U+0100-02BA,U+02BD-02C5,U+02C7-02CC,U+02CE-02D7,U+02DD-02FF,U+0304,U+0308,U+0329,U+1D00-1DBF,U+1E00-1E9F,U+1EF2-1EFF,U+2020,U+20A0-20AB,U+20AD-20C0,U+2113,U+2C60-2C7F,U+A720-A7FF;
}

/* ===========================================================================
   1) COLOR — LIGHT ("Daylight") is the DEFAULT (even on a dark-mode OS).
   Dark is opt-in only via [data-theme="dark"]. No prefers-color-scheme auto-dark
   here: if JS is disabled, the page still opens bright (the owner's core ask).
   =========================================================================== */
:root,:root[data-theme="light"]{
  /* --- surfaces:  true-white cards on warm near-white paper so things separate */
  --bg:#FBFAF7;          /* the warm room you walked into — page base */
  --bg-2:#F3EEE4;        /* a quieter alcove — banded/inset sections */
  --surface:#FFFFFF;     /* a card set on the table — TRUE white, raised */
  --surface-2:#FCFAF7;   /* a second, softer card layer */
  /* --- text */
  --text:#1C1714;        /* the person speaking to you — primary reading colour */
  --muted:#574E43;       /* a calm aside — secondary/help text (AA on --bg, ~7:1) */
  --faint:#776C5C;       /* a whisper — captions, meta (nudged darker from spec #8A7F70 to clear AA 4.5:1 on paper) */
  /* --- the ember (the ONE hero accent) */
  --accent:#D2571F;      /* the fire in the hearth — CTA fills, logo mark */
  --accent-hover:#B8481A;/* the ember catching — hover/active + gradient dark stop */
  --accent-ink:#A8490A;  /* accent as TEXT on light (links/eyebrows) — nudged from spec #B5520A to clear AA on banded --bg-2 too */
  --accent-wash:rgba(210,87,31,.08); /* warmth on the wall — faint accent fill */
  --secondary:#D9A441;   /* warm gold — sparingly, secondary highlights */
  --secondary-wash:rgba(217,164,65,.12);
  /* --- the trust colour (money / verified / vetting ONLY) */
  --trust:#167A5F;       /* a steady handshake — deep teal-green */
  --trust-wash:rgba(22,122,95,.10);
  --success:#2E9E6B; --warning:#C77A0A;
  /* --- structure */
  --line:rgba(28,23,20,.10);        /* where one thing ends and the next begins */
  --line-strong:rgba(28,23,20,.16); /* a firmer edge — inputs, active borders */
  --line-2:rgba(28,23,20,.07);      /* the faintest seam */
  /* --- focus (ALWAYS visible; never remove) */
  --focus-ring:#A63F04;
  /* --- ambient */
  --hero-glow:radial-gradient(70% 60% at 30% 20%,var(--accent-wash),transparent 60%);
  --glow:rgba(210,87,31,.14);

  /* --- warm shadow scale (brown, not gray) */
  --shadow-sm:0 1px 2px rgba(28,20,14,.06),0 1px 3px rgba(28,20,14,.09);
  --shadow-md:0 4px 12px -2px rgba(28,20,14,.10),0 2px 6px -2px rgba(28,20,14,.08);
  --shadow-lg:0 16px 40px -12px rgba(28,20,14,.18),0 6px 16px -6px rgba(28,20,14,.10);
  --shadow:var(--shadow-md); /* legacy alias */
  --raise-highlight:none;    /* inner top highlight only used on dark */

  /* --- radius scale */
  --r-sm:8px; --r-md:12px; --r-lg:16px; --r-xl:24px; --r-pill:999px;

  /* --- spacing (4px base) */
  --s-1:4px; --s-2:8px; --s-3:12px; --s-4:16px; --s-6:24px; --s-8:32px;
  --s-12:48px; --s-16:64px; --s-24:96px; --s-32:128px;

  /* --- type */
  --display:"Fraunces",Georgia,"Times New Roman",serif;                 /* hero + section titles ONLY */
  --body:"Atkinson Hyperlegible Next",Inter,system-ui,-apple-system,BlinkMacSystemFont,"Segoe UI",Roboto,sans-serif; /* everything else */
  --maxw:1120px; --readw:38rem;
}

/* DARK — "Evening": lifted off the void, warm charcoal, stepped surfaces. */
:root[data-theme="dark"]{
  --bg:#1E1915; --bg-2:#262019; --surface:#2A231D; --surface-2:#332A22;
  --text:#F5EEE3; --muted:#C4B7A3; --faint:#93856F;
  --accent:#F2894E; --accent-hover:#F5A742; --accent-ink:#F5A742; --accent-wash:rgba(242,137,78,.14);
  --secondary:#E8A13C; --secondary-wash:rgba(232,161,60,.16);
  --trust:#57C0A0; --trust-wash:rgba(87,192,160,.16); --success:#4FB596; --warning:#E8A13C;
  --line:rgba(245,238,227,.12); --line-strong:rgba(245,238,227,.20); --line-2:rgba(245,238,227,.07);
  --focus-ring:#F7B27A;
  /* ONE soft warm glow behind hero only — no full-page vignette */
  --hero-glow:radial-gradient(ellipse at 50% 0%,rgba(242,137,78,.10),transparent 60%);
  --glow:rgba(242,137,78,.20);
  /* depth via stepped surfaces + inner top highlight, not black shadows */
  --shadow-sm:0 1px 2px rgba(0,0,0,.30);
  --shadow-md:0 6px 18px -6px rgba(0,0,0,.45);
  --shadow-lg:0 24px 60px -18px rgba(0,0,0,.55);
  --shadow:var(--shadow-md);
  --raise-highlight:inset 0 1px 0 rgba(255,255,255,.04);
}

/* ---------------------------------------------------------------------------
   LEGACY ALIASES — pages built before "Daylight Hearth" used --ink/--ember/
   --growth inline. Map them so any page that drops its own :root inherits the
   correct new Hearth colours. Map: ink→text, ember→accent, growth→trust.
   --------------------------------------------------------------------------- */
:root{
  --ink:var(--text); --ink-soft:var(--muted); --ink-faint:var(--faint);
  --ember:var(--accent); --ember-2:var(--accent-hover);
  --growth:var(--trust);
}

/* ===========================================================================
   2) BASE
   =========================================================================== */
*{box-sizing:border-box}
html{-webkit-text-size-adjust:100%}
body{
  margin:0;background:var(--bg);color:var(--text);
  font-family:var(--body);font-size:1.0625rem;line-height:1.65;
  -webkit-font-smoothing:antialiased;text-rendering:optimizeLegibility;
  font-synthesis-weight:none;
}
a{color:var(--accent-ink)}
:root[data-theme="dark"] a{color:var(--accent-ink)}
/* @mention links inside posts/threads — clearly a person, not underlined-by-default */
a.mention{color:var(--accent-ink);font-weight:600;text-decoration:none}
a.mention:hover,a.mention:focus-visible{text-decoration:underline}
a.hashtag{color:var(--accent-ink);font-weight:600;text-decoration:none}
a.hashtag:hover,a.hashtag:focus-visible{text-decoration:underline}
h1,h2,h3,h4{font-family:var(--display);font-weight:600;line-height:1.08;
  letter-spacing:-.01em;text-wrap:balance;margin:0;font-optical-sizing:auto}
p{margin:0}
img,svg{max-width:100%}
:where(input,button,select,textarea){font:inherit}
.tabnum{font-variant-numeric:tabular-nums}

/* Triber number — the belonging primitive: every Triber's immutable member
   number shown as a small pill next to their name wherever they appear. Only
   ever rendered for a real, positive member_number (never #0/#null/invented).
   Uses accent-wash fill + accent-ink text (AA in both light & dark) + a --line
   edge so it never relies on colour alone; tabular-nums keeps digits tidy. */
.tribernum{display:inline-block;vertical-align:baseline;margin-left:.35rem;
  padding:.05em .45em;border-radius:var(--r-pill,999px);
  background:var(--accent-wash);color:var(--accent-ink);
  border:1px solid var(--line);font-size:.72em;font-weight:700;line-height:1.4;
  font-variant-numeric:tabular-nums;letter-spacing:.01em;white-space:nowrap}

/* ---------------------------------------------------------------------------
   ALWAYS-VISIBLE FOCUS RING (accessibility, non-negotiable).
   --------------------------------------------------------------------------- */
:where(a,button,input,select,textarea,summary,[tabindex]):focus-visible{
  outline:3px solid var(--focus-ring);outline-offset:2px;border-radius:4px;
}

/* ===========================================================================
   3) COMPONENT LAYER (classes referenced by every page)
   =========================================================================== */

/* ---- Buttons -------------------------------------------------------------- */
.btn{
  display:inline-flex;align-items:center;justify-content:center;gap:.5rem;
  font-family:var(--body);font-size:1rem;font-weight:600;line-height:1.1;
  min-height:48px;padding:.75rem 1.4rem;border-radius:var(--r-md);
  border:1.5px solid transparent;cursor:pointer;text-decoration:none;
  transition:transform .15s ease,box-shadow .15s ease,background .15s ease,border-color .15s ease,color .15s ease;
}
.btn-primary{
  background:linear-gradient(180deg,var(--accent-hover),var(--accent));
  color:#fff;box-shadow:var(--shadow-md),inset 0 1px 0 rgba(255,255,255,.18);
}
:root[data-theme="dark"] .btn-primary{color:#241203}
.btn-primary:hover{transform:translateY(-1px);box-shadow:var(--shadow-lg),inset 0 1px 0 rgba(255,255,255,.18)}
.btn-secondary{background:var(--surface);color:var(--text);border-color:var(--line-strong);box-shadow:var(--shadow-sm)}
.btn-secondary:hover{transform:translateY(-1px);border-color:var(--accent);color:var(--accent-ink);box-shadow:var(--shadow-md)}
.btn-ghost{background:transparent;color:var(--text);border-color:transparent}
.btn-ghost:hover{color:var(--accent-ink);background:var(--accent-wash)}
.btn:active{transform:translateY(0)}
.btn-lg{font-size:1.0625rem;min-height:54px;padding:.9rem 1.7rem}
.btn-block{width:100%}

/* ---- Cards ---------------------------------------------------------------- */
.card{
  background:var(--surface);border:1px solid var(--line);border-radius:var(--r-lg);
  padding:clamp(1.25rem,3vw,2rem);box-shadow:var(--shadow-md,var(--shadow));
}
:root[data-theme="dark"] .card{box-shadow:var(--shadow-md),var(--raise-highlight)}
.card-interactive{transition:transform .15s ease,box-shadow .15s ease,border-color .15s ease}
.card-interactive:hover{transform:translateY(-3px);box-shadow:var(--shadow-lg);border-color:var(--line-strong)}

/* ---- Eyebrow / badge ------------------------------------------------------ */
.eyebrow{display:inline-block;font-family:var(--body);font-size:.8125rem;font-weight:700;
  letter-spacing:.04em;text-transform:uppercase;color:var(--accent-ink)}
:root[data-theme="dark"] .eyebrow{color:var(--accent)}
.badge{display:inline-flex;align-items:center;gap:.4rem;font-size:.8rem;font-weight:600;
  padding:.28rem .7rem;border-radius:var(--r-pill);background:var(--trust-wash);
  color:var(--trust);border:1px solid color-mix(in srgb,var(--trust) 30%,transparent)}

/* ---- Fields: style EVERY native control (kills the #1 "unfinished" tell) --- */
.field{display:block;margin-bottom:1rem}
.field>label,.field-label{display:block;font-size:.9rem;font-weight:600;color:var(--text);
  margin-bottom:.4rem;letter-spacing:.01em}
.field .hint{display:block;font-size:.82rem;color:var(--faint);margin-top:.35rem}
.field input,.field select,.field textarea,
input[type=text],input[type=email],input[type=tel],input[type=number],
input[type=password],input[type=search],input[type=url],input[type=date],select,textarea{
  width:100%;min-height:48px;padding:.7rem .9rem;
  background:var(--surface);color:var(--text);
  border:1.5px solid var(--line-strong);border-radius:var(--r-md);
  font:inherit;line-height:1.4;transition:border-color .15s ease,box-shadow .15s ease;
  -webkit-appearance:none;appearance:none;
}
textarea{min-height:110px;resize:vertical;padding-top:.7rem}
.field input::placeholder,textarea::placeholder{color:var(--faint)}
.field input:focus,.field select:focus,.field textarea:focus,
input:focus,select:focus,textarea:focus{
  border-color:var(--accent);box-shadow:0 0 0 3px var(--accent-wash);outline:none;
}
/* custom <select> chevron */
select{
  background-image:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='16' height='16' viewBox='0 0 24 24' fill='none' stroke='%23574E43' stroke-width='2.2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M6 9l6 6 6-6'/%3E%3C/svg%3E");
  background-repeat:no-repeat;background-position:right .85rem center;padding-right:2.4rem;
}
:root[data-theme="dark"] select{
  background-image:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='16' height='16' viewBox='0 0 24 24' fill='none' stroke='%23C4B7A3' stroke-width='2.2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M6 9l6 6 6-6'/%3E%3C/svg%3E");
}
/* styled file input via label wrapper */
.file-field input[type=file]{position:absolute;width:1px;height:1px;opacity:0;overflow:hidden}
.file-label{display:inline-flex;align-items:center;gap:.6rem;min-height:48px;
  padding:.6rem 1.1rem;border:1.5px dashed var(--line-strong);border-radius:var(--r-md);
  background:var(--surface-2);color:var(--muted);cursor:pointer;font-weight:600;width:100%}
.file-label:hover{border-color:var(--accent);color:var(--accent-ink)}
/* autofill fix */
input:-webkit-autofill,input:-webkit-autofill:hover,input:-webkit-autofill:focus,
textarea:-webkit-autofill,select:-webkit-autofill{
  -webkit-box-shadow:0 0 0 100px var(--surface) inset;-webkit-text-fill-color:var(--text);
  caret-color:var(--text);
}
input[type=checkbox],input[type=radio]{width:auto;min-height:auto;accent-color:var(--accent)}

/* ---- Door cards (the crown jewel grid) ------------------------------------ */
.door-card{
  display:flex;flex-direction:column;gap:.6rem;text-decoration:none;color:inherit;
  background:var(--surface);border:1px solid var(--line);border-radius:var(--r-lg);
  padding:1.6rem 1.5rem;box-shadow:var(--shadow-sm);position:relative;overflow:hidden;
  transition:transform .15s ease,box-shadow .15s ease,border-color .15s ease;
}
:root[data-theme="dark"] .door-card{box-shadow:var(--shadow-sm),var(--raise-highlight)}
.door-card:hover{transform:translateY(-4px);box-shadow:var(--shadow-lg);border-color:var(--line-strong)}
.door-card .chip{width:46px;height:46px;border-radius:var(--r-md);display:grid;place-items:center;
  background:var(--door-wash,var(--accent-wash));color:var(--door-hue,var(--accent-ink))}
.door-card .chip svg{width:24px;height:24px;fill:none;stroke:currentColor;stroke-width:1.9;stroke-linecap:round;stroke-linejoin:round}
.door-card h3{font-size:1.28rem}
.door-card p{color:var(--muted);font-size:.98rem}
.door-card .go{margin-top:auto;padding-top:.6rem;font-weight:700;font-size:.88rem;color:var(--accent-ink);
  letter-spacing:.02em}
:root[data-theme="dark"] .door-card .go{color:var(--accent)}
.door-card::before{content:"";position:absolute;left:0;top:0;bottom:0;width:4px;
  background:var(--door-hue,var(--accent));opacity:.9}

/* ---- Header + theme toggle ------------------------------------------------ */
.theme-toggle{
  display:inline-grid;place-items:center;width:44px;height:44px;border-radius:var(--r-pill);
  background:transparent;border:1.5px solid var(--line);color:var(--muted);cursor:pointer;
  transition:border-color .15s ease,color .15s ease,background .15s ease;
}
.theme-toggle:hover{border-color:var(--accent);color:var(--accent-ink);background:var(--accent-wash)}
.theme-toggle svg{width:20px;height:20px;fill:none;stroke:currentColor;stroke-width:2;stroke-linecap:round;stroke-linejoin:round}
/* floating fallback toggle injected by /theme.js on pages without a header slot */
.theme-toggle-floating{position:fixed;right:16px;bottom:16px;z-index:60;
  background:var(--surface);box-shadow:var(--shadow-md)}

/* ===========================================================================
   4) UTILITIES
   =========================================================================== */
.shadow-sm{box-shadow:var(--shadow-sm)}.shadow-md{box-shadow:var(--shadow-md)}.shadow-lg{box-shadow:var(--shadow-lg)}
.r-sm{border-radius:var(--r-sm)}.r-md{border-radius:var(--r-md)}.r-lg{border-radius:var(--r-lg)}.r-xl{border-radius:var(--r-xl)}
.hearth-trust{color:var(--trust)}
.hearth-trust-card{background:var(--trust-wash);border:1px solid color-mix(in srgb,var(--trust) 30%,transparent);border-radius:var(--r-md)}

/* honour reduced motion everywhere */
@media (prefers-reduced-motion:reduce){
  *,*::before,*::after{animation-duration:.001ms!important;animation-iteration-count:1!important;
    transition-duration:.001ms!important;scroll-behavior:auto!important}
}

/* ===========================================================================
   5) CANONICAL SITE NAVIGATION — one sticky header + footer on EVERY page.
   Classes are namespaced .th-* so they always win over older per-page inline
   CSS (.bar/.nav) and can't be broken by it. Wired by /nav.js (mobile menu)
   and /theme.js (sun/moon toggle). Smooth in-page scroll for /#anchors.
   =========================================================================== */
html{scroll-behavior:smooth}
@media (prefers-reduced-motion:reduce){html{scroll-behavior:auto}}

.th-header{position:sticky;top:0;z-index:100;
  background:color-mix(in srgb,var(--bg) 86%,transparent);backdrop-filter:blur(12px);
  -webkit-backdrop-filter:blur(12px);border-bottom:1px solid var(--line-2);transition:transform .25s ease}
.th-header.hide{transform:translateY(-100%)}
.th-header.th-open{transform:none}  /* never hide while the mobile menu is open */
.th-bar{max-width:var(--maxw);margin:0 auto;padding:0 24px;
  display:flex;align-items:center;justify-content:space-between;gap:16px;min-height:64px}
.th-brand{display:flex;align-items:center;gap:.55rem;text-decoration:none;
  font-family:var(--display);font-weight:600;font-size:1.28rem;letter-spacing:-.01em;color:var(--text)}
.th-brand:hover{color:var(--text)}
.th-brand .th-mark{width:30px;height:30px;flex:0 0 auto;display:block}

/* desktop primary nav */
.th-nav{display:flex;align-items:center;gap:26px;font-size:.98rem}
.th-nav a:not(.btn){color:var(--muted);text-decoration:none;font-weight:500;padding:.35rem 0;
  border-bottom:2px solid transparent;transition:color .15s ease,border-color .15s ease}
.th-nav a:not(.btn):hover{color:var(--accent-ink)}
:root[data-theme="dark"] .th-nav a:not(.btn):hover{color:var(--accent)}
.th-nav a:not(.btn)[aria-current="page"]{color:var(--text);border-bottom-color:var(--accent)}
/* buttons inside the nav (mobile CTA) must never be styled like nav links */
.th-nav a.btn,.th-nav .btn{color:#fff;border-bottom:none}
:root[data-theme="dark"] .th-nav a.btn-primary,:root[data-theme="dark"] .th-nav .btn-primary{color:#241203}
.th-nav .th-bdg{display:none;min-width:18px;height:18px;margin-left:.3rem;padding:0 5px;
  border-radius:var(--r-pill);background:var(--accent);color:#fff;font-size:.72rem;font-weight:700;
  line-height:18px;text-align:center;vertical-align:middle;font-variant-numeric:tabular-nums}
:root[data-theme="dark"] .th-nav .th-bdg{color:#241203}
.th-nav .th-bdg.on{display:inline-block}

/* header right-side actions */
.th-actions{display:flex;align-items:center;gap:12px}
.th-signin{color:var(--text);text-decoration:none;font-weight:600;font-size:.98rem}
.th-signin:hover{color:var(--accent-ink)}
.th-actions .btn{min-height:44px;padding:.55rem 1.15rem;font-size:.95rem;border-radius:var(--r-md)}
.th-actions .btn-primary{background:linear-gradient(180deg,var(--accent-hover),var(--accent));color:#fff}
:root[data-theme="dark"] .th-actions .btn-primary{color:#241203}

/* hamburger — hidden on desktop */
.th-burger{display:none;align-items:center;justify-content:center;width:44px;height:44px;
  border:1.5px solid var(--line);border-radius:var(--r-md);background:transparent;cursor:pointer;
  color:var(--text);flex:0 0 auto}
.th-burger:hover{border-color:var(--accent);color:var(--accent-ink)}
.th-burger .th-burger-box{position:relative;width:20px;height:14px}
.th-burger .th-burger-box span{position:absolute;left:0;height:2px;width:100%;background:currentColor;border-radius:2px;transition:transform .2s ease,opacity .2s ease}
.th-burger .th-burger-box span:nth-child(1){top:0}
.th-burger .th-burger-box span:nth-child(2){top:6px}
.th-burger .th-burger-box span:nth-child(3){top:12px}
.th-header.th-open .th-burger .th-burger-box span:nth-child(1){transform:translateY(6px) rotate(45deg)}
.th-header.th-open .th-burger .th-burger-box span:nth-child(2){opacity:0}
.th-header.th-open .th-burger .th-burger-box span:nth-child(3){transform:translateY(-6px) rotate(-45deg)}

/* ---- mobile: collapse nav into a drawer opened by the hamburger ---- */
@media (max-width:860px){
  .th-burger{display:inline-flex}
  .th-signin{display:none}
  .th-nav{position:absolute;left:0;right:0;top:100%;flex-direction:column;align-items:stretch;
    gap:0;padding:8px 24px 20px;background:var(--bg);border-bottom:1px solid var(--line);
    box-shadow:var(--shadow-lg);display:none}
  .th-header.th-open .th-nav{display:flex}
  .th-nav a:not(.btn){padding:.95rem .25rem;border-bottom:1px solid var(--line-2);font-size:1.05rem}
  .th-nav a:not(.btn)[aria-current="page"]{border-bottom-color:var(--line-2);color:var(--accent-ink)}
  .th-nav .th-mobile-cta{margin-top:14px;border-bottom:none!important;padding:0}
  .th-nav .th-mobile-cta .btn{width:100%}
}
@media (min-width:861px){.th-nav .th-mobile-only{display:none}}
/* ---- smallest phones (<=360px): keep header within viewport, zero horizontal overflow (hdrfix) ---- */
@media (max-width:360px){
  .th-bar{padding:0 14px;gap:10px}
  .th-actions{gap:8px}
}

/* ---- canonical footer ---- */
.th-footer{border-top:1px solid var(--line);background:var(--bg-2);padding:56px 0 36px}
.th-footer .th-foot-wrap{max-width:var(--maxw);margin:0 auto;padding:0 24px}
.th-foot-grid{display:grid;grid-template-columns:1.5fr 1fr 1fr 1fr;gap:32px}
@media(max-width:820px){.th-foot-grid{grid-template-columns:1fr 1fr}}
@media(max-width:520px){.th-foot-grid{grid-template-columns:1fr}}
.th-foot-brand .th-brand{font-size:1.2rem}
.th-foot-brand p{color:var(--muted);font-size:.95rem;margin-top:.8rem;max-width:34ch;line-height:1.6}
.th-foot-grid h4{font-family:var(--body);font-size:.8rem;letter-spacing:.08em;text-transform:uppercase;
  color:var(--faint);font-weight:700;margin:0 0 .9rem}
.th-foot-grid nav{display:flex;flex-direction:column}
.th-foot-grid a{color:var(--muted);text-decoration:none;font-size:.95rem;padding:.28rem 0}
.th-foot-grid a:hover{color:var(--accent-ink)}
.th-foot-bottom{display:flex;justify-content:space-between;flex-wrap:wrap;gap:12px;margin-top:40px;
  padding-top:24px;border-top:1px solid var(--line-2);color:var(--faint);font-size:.85rem;line-height:1.6}

/* skip link (accessibility) */
.th-skip{position:absolute;left:-9999px;top:0;z-index:200;background:var(--accent);color:#fff;
  padding:.6rem 1rem;border-radius:var(--r-sm);font-weight:600;text-decoration:none}
.th-skip:focus{left:8px;top:8px}

/* ============================================================================
   WARM REACTIONS — a small, kind set of reactions on posts (not a slot machine)
   Used on the feed + community post cards. Reuses the .pactions row. The trigger
   is the primary control; a soft picker reveals the five warm options on
   hover/focus. Fully keyboard-operable, ≥44px targets, always-visible focus.
   ============================================================================ */
.rxn{position:relative;display:inline-flex;align-items:center;gap:.5rem}
.rxn-trigger{min-height:44px;display:inline-flex;align-items:center;gap:.45rem;
  background:transparent;border:1px solid var(--line);color:var(--muted);
  border-radius:var(--r-pill);padding:.35rem .9rem;font:inherit;font-size:.86rem;
  font-weight:600;cursor:pointer;transition:border-color .15s,color .15s,background .15s}
.rxn-trigger:hover{border-color:var(--accent);color:var(--accent-ink)}
.rxn-trigger:focus-visible{outline:3px solid var(--focus-ring);outline-offset:2px}
.rxn-trigger .rxn-emoji{font-size:1.1rem;line-height:1}
.rxn-trigger.on{border-color:var(--accent);color:var(--accent-ink);
  background:var(--accent-wash)}
/* the summary: total + up to three distinct emojis present (0 is 0 — honest) */
.rxn-summary{display:inline-flex;align-items:center;gap:.3rem;color:var(--faint);
  font-size:.84rem;font-weight:600}
.rxn-summary .rxn-faces{display:inline-flex;font-size:.95rem;line-height:1}
.rxn-summary .rxn-faces span{margin-left:-2px}
.rxn-summary .rxn-total{min-width:1ch}
/* the picker popover */
.rxn-picker{position:absolute;bottom:calc(100% + 8px);left:0;z-index:40;
  display:flex;gap:.15rem;padding:.35rem;background:var(--surface);
  border:1px solid var(--line-strong);border-radius:var(--r-pill);
  box-shadow:var(--shadow-lg);opacity:0;visibility:hidden;transform:translateY(4px);
  transition:opacity .15s ease,transform .15s ease,visibility .15s}
.rxn:hover .rxn-picker,.rxn.open .rxn-picker,.rxn-picker:focus-within{
  opacity:1;visibility:visible;transform:translateY(0)}
.rxn-opt{min-width:44px;min-height:44px;display:inline-flex;flex-direction:column;
  align-items:center;justify-content:center;gap:1px;background:transparent;border:0;
  border-radius:var(--r-md);cursor:pointer;font:inherit;color:var(--muted);
  padding:.2rem .35rem;transition:background .12s,transform .12s}
.rxn-opt .rxn-oe{font-size:1.5rem;line-height:1}
.rxn-opt .rxn-ol{font-size:.62rem;font-weight:700;letter-spacing:.01em}
.rxn-opt:hover{background:var(--accent-wash);transform:translateY(-2px)}
.rxn-opt:focus-visible{outline:3px solid var(--focus-ring);outline-offset:2px}
.rxn-opt.on{background:var(--accent-wash);color:var(--accent-ink)}
@media (prefers-reduced-motion:reduce){
  .rxn-picker,.rxn-opt,.rxn-trigger{transition:none}
  .rxn-opt:hover{transform:none}
}

/* ============================================================================
   MOBILE BOTTOM TAB BAR — app-like nav for logged-in Tribers on phones.
   ADDITIVE + reversible. Injected by /nav.js ONLY when the Triber is logged in,
   so the element's mere presence already means "logged in". This CSS then shows
   it ONLY on phone widths (<=700px); it stays hidden on tablet/desktop. Guests
   never get the element at all, so they always keep the header nav untouched.
   Sits above the sticky header (z 100) and content; leaves room via body padding
   + iOS home-indicator safe-area. Works in both Daylight (light) and dark.
   ========================================================================== */
.th-tabbar{display:none}
/* The doors launcher sheet + its backdrop are injected on document.body by
   nav.js for logged-in Tribers at ANY width, and their off-canvas/hidden CSS
   lives only inside the mobile media query below. Hide them by default (mirrors
   .th-tabbar) so they never paint in normal flow — as huge black-fill door
   icons — below the footer on desktop. The media query re-enables display. */
.th-doors-backdrop,.th-doors-sheet{display:none}
/* When the bar is present, reserve space so it never covers content/footer.
   env() resolves to 0 without viewport-fit=cover, which is correct: the browser
   already insets the viewport on notched devices in that case. */
body.th-has-tabbar{padding-bottom:0}

@media (max-width:700px){
  body.th-has-tabbar{padding-bottom:calc(58px + env(safe-area-inset-bottom,0px))}
  .th-tabbar{
    display:flex;position:fixed;left:0;right:0;bottom:0;z-index:300;
    align-items:stretch;justify-content:space-around;
    height:calc(58px + env(safe-area-inset-bottom,0px));
    padding-bottom:env(safe-area-inset-bottom,0px);
    background:var(--surface);border-top:1px solid var(--line);
    box-shadow:0 -6px 18px -8px rgba(28,20,14,.14);
    -webkit-backdrop-filter:saturate(1.1);backdrop-filter:saturate(1.1);
  }
  :root[data-theme="dark"] .th-tabbar{box-shadow:0 -8px 22px -10px rgba(0,0,0,.55)}
  .th-tab{
    flex:1 1 0;display:flex;flex-direction:column;align-items:center;justify-content:center;
    gap:2px;min-width:0;min-height:52px;padding:6px 2px 4px;
    background:transparent;border:0;cursor:pointer;
    color:var(--muted);text-decoration:none;font:inherit;
    -webkit-tap-highlight-color:transparent;
  }
  .th-tab svg{width:24px;height:24px;flex:none;stroke:currentColor;fill:none;
    stroke-width:1.9;stroke-linecap:round;stroke-linejoin:round}
  .th-tab .th-tab-l{font-size:.66rem;font-weight:600;letter-spacing:.01em;line-height:1;
    max-width:100%;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
  .th-tab:hover{color:var(--accent-ink)}
  :root[data-theme="dark"] .th-tab:hover{color:var(--accent)}
  .th-tab[aria-current="page"]{color:var(--accent-ink)}
  :root[data-theme="dark"] .th-tab[aria-current="page"]{color:var(--accent)}
  .th-tab:focus-visible{outline:3px solid var(--focus-ring);outline-offset:-3px;border-radius:10px}
  /* Emphasised centre "Post" action */
  .th-tab-post svg{
    width:40px;height:40px;margin-top:-14px;padding:8px;border-radius:var(--r-pill);
    color:#fff;background:linear-gradient(180deg,var(--accent-hover),var(--accent));
    box-shadow:var(--shadow-md);stroke-width:2.2}
  :root[data-theme="dark"] .th-tab-post svg{color:#241203}
  .th-tab-post{color:var(--muted)}
  .th-tab-post:hover{color:var(--accent-ink)}
  /* unread badge on Messages */
  .th-tab{position:relative}
  .th-tab .th-tab-bdg{
    position:absolute;top:4px;left:calc(50% + 7px);min-width:16px;height:16px;padding:0 4px;
    display:none;align-items:center;justify-content:center;
    background:var(--accent);color:#fff;font-size:.6rem;font-weight:800;line-height:1;
    border-radius:999px;border:2px solid var(--surface)}
  :root[data-theme="dark"] .th-tab .th-tab-bdg{color:#241203}
  .th-tab .th-tab-bdg.on{display:inline-flex}

  /* Doors launcher — a small bottom sheet above the tab bar */
  .th-doors-backdrop{
    display:block;
    position:fixed;inset:0;z-index:340;background:rgba(28,20,14,.42);
    opacity:0;visibility:hidden;transition:opacity .18s ease,visibility .18s ease}
  .th-doors-backdrop.open{opacity:1;visibility:visible}
  .th-doors-sheet{
    display:block;
    position:fixed;left:0;right:0;bottom:0;z-index:350;
    background:var(--surface);border-top-left-radius:var(--r-xl);border-top-right-radius:var(--r-xl);
    border-top:1px solid var(--line);box-shadow:0 -18px 48px -16px rgba(28,20,14,.28);
    padding:10px 16px calc(16px + 58px + env(safe-area-inset-bottom,0px));
    transform:translateY(100%);transition:transform .22s ease}
  .th-doors-sheet.open{transform:translateY(0)}
  .th-doors-grip{width:38px;height:4px;border-radius:999px;background:var(--line-strong);margin:2px auto 10px}
  .th-doors-h{font-weight:700;font-size:.95rem;color:var(--text);margin:0 4px 10px}
  .th-doors-list{display:grid;grid-template-columns:1fr 1fr;gap:8px}
  .th-doors-list a{
    display:flex;align-items:center;gap:10px;min-height:48px;padding:.6rem .8rem;
    border:1px solid var(--line);border-radius:var(--r-md);
    color:var(--text);text-decoration:none;font-weight:600;font-size:.92rem;background:var(--surface-2)}
  .th-doors-list a:hover{border-color:var(--accent);color:var(--accent-ink)}
  .th-doors-list a:focus-visible{outline:3px solid var(--focus-ring);outline-offset:2px}
  .th-doors-list a svg{width:20px;height:20px;flex:none;stroke:var(--accent);fill:none;
    stroke-width:1.9;stroke-linecap:round;stroke-linejoin:round}
}
@media (max-width:700px) and (prefers-reduced-motion:reduce){
  .th-doors-sheet,.th-doors-backdrop{transition:none}
}

/* ============================================================================
   DESKTOP LEFT RAIL — 240px app shell for logged-in Tribers (>=1000px).
   ADDITIVE + reversible. Injected by /nav.js ONLY when the Triber is logged in
   (so the element's mere presence already means "logged in"). This CSS then
   SHOWS it — and hides the top header + pads the body 240px — ONLY at >=1000px.
   Below 1000px it stays hidden and inert: the top header + mobile bottom-tab bar
   remain the nav, untouched. Guests never get the element, so their header is
   never affected at any width. Works in Daylight (light) + Evening (dark).
   ============================================================================ */
.th-leftrail{display:none}
@media (min-width:1000px){
  /* push page content clear of the fixed rail; hide the now-redundant top header
     (its theme toggle + search + alerts all live in the rail). */
  body.th-has-leftrail{padding-left:240px;padding-top:12px}
  body.th-has-leftrail .th-header{display:none}

  .th-leftrail{
    display:flex;flex-direction:column;
    position:fixed;top:0;left:0;bottom:0;width:240px;z-index:120;
    background:var(--surface);border-right:1px solid var(--line);
    box-shadow:1px 0 0 var(--line-2)}
  :root[data-theme="dark"] .th-leftrail{box-shadow:1px 0 0 rgba(0,0,0,.35)}

  .th-lr-brand{flex:0 0 auto;display:flex;align-items:center;gap:.55rem;
    padding:16px 16px 12px;text-decoration:none;color:var(--text);
    font-family:var(--display);font-weight:600;font-size:1.2rem;letter-spacing:-.01em}
  .th-lr-brand:hover{color:var(--text)}
  .th-lr-brand .th-mark{width:28px;height:28px;flex:0 0 auto;display:block}

  .th-lr-scroll{flex:1 1 auto;overflow-y:auto;padding:4px 12px 8px}
  .th-lr-nav{list-style:none;margin:0;padding:0;display:flex;flex-direction:column;gap:2px}
  .th-lr-nav>li{margin:0}

  /* primary rows (links + the Doors trigger share one look) */
  .th-lr-nav>li>a,.th-lr-doors{
    display:flex;align-items:center;gap:.7rem;width:100%;
    min-height:44px;padding:.5rem .7rem;border-radius:var(--r-md);
    color:var(--muted);text-decoration:none;font-weight:600;font-size:.95rem;
    background:transparent;border:0;cursor:pointer;text-align:left;font:inherit;font-weight:600;
    transition:background .15s ease,color .15s ease}
  .th-lr-nav>li>a:hover,.th-lr-doors:hover{background:var(--accent-wash);color:var(--accent-ink)}
  :root[data-theme="dark"] .th-lr-nav>li>a:hover,:root[data-theme="dark"] .th-lr-doors:hover{color:var(--accent)}
  .th-lr-nav>li>a svg,.th-lr-doors>svg:first-child{width:22px;height:22px;flex:none;
    stroke:currentColor;fill:none;stroke-width:1.9;stroke-linecap:round;stroke-linejoin:round}
  .th-lr-t{flex:1 1 auto;min-width:0;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}

  /* active = accent-wash pill */
  .th-lr-nav>li>a[aria-current="page"],.th-lr-sub a[aria-current="page"]{
    background:var(--accent-wash);color:var(--accent-ink);font-weight:700}
  :root[data-theme="dark"] .th-lr-nav>li>a[aria-current="page"],
  :root[data-theme="dark"] .th-lr-sub a[aria-current="page"]{color:var(--accent)}

  /* visible focus ring everywhere in the rail */
  .th-leftrail a:focus-visible,.th-leftrail button:focus-visible{
    outline:3px solid var(--focus-ring);outline-offset:-2px;border-radius:var(--r-md)}

  /* Doors caret + expandable sub-list */
  .th-lr-caret{width:16px;height:16px;flex:none;margin-left:auto;
    stroke:currentColor;fill:none;stroke-width:2;stroke-linecap:round;stroke-linejoin:round;
    transition:transform .15s ease}
  .th-lr-doors[aria-expanded="true"] .th-lr-caret{transform:rotate(180deg)}
  .th-lr-sub{list-style:none;margin:2px 0 2px 1.15rem;padding:2px 0 2px .55rem;
    display:flex;flex-direction:column;gap:1px;border-left:1px solid var(--line)}
  .th-lr-sub[hidden]{display:none}
  .th-lr-sub a{display:flex;align-items:center;gap:.55rem;min-height:40px;padding:.4rem .6rem;
    border-radius:var(--r-sm);color:var(--muted);text-decoration:none;font-weight:600;font-size:.9rem}
  .th-lr-sub a:hover{background:var(--accent-wash);color:var(--accent-ink)}
  :root[data-theme="dark"] .th-lr-sub a:hover{color:var(--accent)}
  .th-lr-sub a svg{width:18px;height:18px;flex:none;stroke:currentColor;fill:none;
    stroke-width:1.9;stroke-linecap:round;stroke-linejoin:round}

  /* unread badges on Messages / Alerts */
  .th-lr-bdg{display:none;margin-left:auto;flex:none;min-width:20px;height:20px;padding:0 6px;
    border-radius:var(--r-pill);background:var(--accent);color:#fff;font-size:.72rem;font-weight:800;
    line-height:20px;text-align:center;font-variant-numeric:tabular-nums}
  :root[data-theme="dark"] .th-lr-bdg{color:#241203}
  .th-lr-bdg.on{display:inline-block}

  /* footer: theme toggle + member menu */
  .th-lr-foot{flex:0 0 auto;border-top:1px solid var(--line);
    padding:10px 12px calc(10px + env(safe-area-inset-bottom,0px));
    display:flex;flex-direction:column;gap:10px}
  .th-lr-theme-row{display:flex;align-items:center;gap:.6rem}
  .th-lr-theme-lbl{color:var(--muted);font-size:.9rem;font-weight:600}
  .th-lr-me-wrap{position:relative}
  .th-lr-me{display:flex;align-items:center;gap:.6rem;width:100%;min-height:52px;
    padding:.45rem .55rem;border-radius:var(--r-md);background:transparent;
    border:1px solid var(--line);cursor:pointer;color:var(--text);text-align:left;font:inherit}
  .th-lr-me:hover{border-color:var(--accent)}
  .th-lr-av{width:34px;height:34px;flex:none;border-radius:50%;overflow:hidden;
    background:var(--accent-wash);color:var(--accent-ink);
    display:flex;align-items:center;justify-content:center;font-weight:700;font-size:.9rem}
  :root[data-theme="dark"] .th-lr-av{color:var(--accent)}
  .th-lr-av img{width:100%;height:100%;object-fit:cover;display:block}
  .th-lr-me-txt{display:flex;flex-direction:column;min-width:0;line-height:1.25;flex:1 1 auto}
  .th-lr-me-name{font-weight:700;font-size:.9rem;color:var(--text);
    white-space:nowrap;overflow:hidden;text-overflow:ellipsis}
  .th-lr-me-sub{font-size:.75rem;color:var(--muted);font-variant-numeric:tabular-nums;
    white-space:nowrap;overflow:hidden;text-overflow:ellipsis}
  .th-lr-menu{position:absolute;bottom:calc(100% + 6px);left:0;right:0;z-index:130;
    background:var(--surface);border:1px solid var(--line-strong);border-radius:var(--r-md);
    box-shadow:var(--shadow-lg);padding:6px;display:flex;flex-direction:column;gap:2px}
  .th-lr-menu[hidden]{display:none}
  .th-lr-menu a,.th-lr-menu button{display:flex;align-items:center;min-height:44px;
    padding:.5rem .7rem;border-radius:var(--r-sm);color:var(--text);text-decoration:none;
    font-weight:600;font-size:.92rem;background:transparent;border:0;cursor:pointer;
    text-align:left;width:100%;font:inherit}
  .th-lr-menu a:hover,.th-lr-menu button:hover{background:var(--accent-wash);color:var(--accent-ink)}
  :root[data-theme="dark"] .th-lr-menu a:hover,:root[data-theme="dark"] .th-lr-menu button:hover{color:var(--accent)}

  @media (prefers-reduced-motion:reduce){
    .th-lr-nav>li>a,.th-lr-doors,.th-lr-caret{transition:none}
  }
}

/* ============================================================================
   REPOST + QUOTE-POST — amplify genuinely good posts (Twitter/Bluesky parity).
   A repost shows a "🔁 Name reposted" header above the original; a quote-post
   embeds the original as a bordered card beneath the Triber's own words. All
   embedded content is escaped by the client (textContent / mentions). ≥44px
   targets, visible focus, theme-aware via tokens.
   ============================================================================ */
.repost-header{display:flex;align-items:center;gap:.4rem;color:var(--faint,#6b6459);
  font-size:.8rem;font-weight:600;margin:-.2rem 0 .6rem;padding-bottom:.1rem}
.repost-header .rp-ic{font-size:.9rem;line-height:1}
.repost-header a{color:var(--faint,#6b6459);text-decoration:none}
.repost-header a:hover{color:var(--accent);text-decoration:underline}
/* the embedded quoted original card */
.quote-card{margin-top:.85rem;border:1px solid var(--line);border-radius:12px;
  padding:.8rem .9rem;background:var(--bg-2,color-mix(in srgb,var(--surface) 60%,transparent))}
.quote-card .qc-head{display:flex;align-items:center;gap:.55rem;margin-bottom:.4rem}
.quote-card .qc-av{width:30px;height:30px;font-size:.8rem}
.quote-card .qc-body{white-space:pre-wrap;word-wrap:break-word;overflow-wrap:anywhere;
  font-size:.94rem;color:var(--ink)}
.quote-card.unavailable{color:var(--faint,#6b6459);font-style:italic;font-size:.9rem}
.quote-card .qc-un{color:var(--faint,#6b6459)}
.quote-card .qc-img-wrap{margin-top:.55rem;border-radius:8px;overflow:hidden;
  border:1px solid var(--line);background:var(--bg-2);max-width:100%}
.quote-card .qc-img{display:block;width:100%;height:auto;max-height:340px;
  object-fit:contain;background:var(--bg-2)}
/* the small quote composer that opens under a post */
.quote-composer{margin-top:.85rem;border-top:1px solid var(--line-2,var(--line));
  padding-top:.85rem}
.quote-composer .qc-text{width:100%;padding:.7rem .8rem;border:1px solid var(--line);
  border-radius:8px;background:var(--bg,var(--surface));color:var(--ink);font:inherit;
  min-height:70px;resize:vertical}
.quote-composer .qc-text:focus{outline:3px solid var(--focus-ring);outline-offset:1px;
  border-color:var(--accent)}
.quote-composer .qc-row{display:flex;align-items:center;gap:.6rem;margin-top:.6rem;flex-wrap:wrap}
/* make every post-action button a comfortable ≥44px touch target */
.pactions .act{min-height:44px}

/* ============================================================================
   KINDER REACTIONS v2 — inline row of four warm, positive-only kinds on posts.
   Each kind is a real <button> WITH a visible label (never colour/icon-only);
   the caller's active kind is marked with --accent AND aria-pressed. Counts are
   honest (0 shows no number). Supersedes the older .rxn picker (kept above for
   any legacy markup). ≥44px targets, always-visible focus, reduced-motion safe.
   ============================================================================ */
.rxn-row{display:flex;flex-wrap:wrap;gap:.4rem;align-items:center}
.rxn-btn{min-height:44px;display:inline-flex;align-items:center;gap:.35rem;
  background:transparent;border:1px solid var(--line);color:var(--muted);
  border-radius:var(--r-pill);padding:.3rem .8rem;font:inherit;font-size:.84rem;
  font-weight:600;cursor:pointer;transition:border-color .15s,color .15s,background .15s}
.rxn-btn:hover{border-color:var(--accent);color:var(--accent-ink)}
.rxn-btn:focus-visible{outline:3px solid var(--focus-ring);outline-offset:2px}
.rxn-btn .rxn-ic{font-size:1.15rem;line-height:1}
.rxn-btn .rxn-lb{white-space:nowrap}
.rxn-btn .rxn-ct{font-variant-numeric:tabular-nums;font-weight:700;min-width:1ch;padding-left:.1rem}
.rxn-btn.on{border-color:var(--accent);color:var(--accent-ink);
  background:var(--accent-wash);box-shadow:inset 0 0 0 1px var(--accent)}
@media (prefers-reduced-motion:reduce){.rxn-btn{transition:none}}
@media (max-width:430px){.rxn-btn{padding:.3rem .6rem;gap:.25rem}.rxn-btn .rxn-lb{font-size:.8rem}}

/* ---- "Why am I seeing this?" — honest, literally-accurate transparency ---- */
.feed-why{margin:0 0 1rem;color:var(--muted);font-size:.86rem;line-height:1.5;
  background:var(--trust-wash);border:1px solid var(--line);border-radius:var(--r-md);
  padding:.6rem .85rem}
.why-wrap{margin-top:.45rem}
.why-see{display:inline-flex;align-items:center;min-height:44px;background:transparent;
  border:0;color:var(--faint);font:inherit;font-size:.8rem;font-weight:600;cursor:pointer;
  padding:.2rem .1rem;text-decoration:underline;text-underline-offset:2px}
.why-see:hover{color:var(--accent-ink)}
.why-see:focus-visible{outline:3px solid var(--focus-ring);outline-offset:2px;border-radius:var(--r-sm)}
.why-body{margin-top:.3rem;color:var(--muted);font-size:.82rem;line-height:1.55;
  background:var(--bg-2);border-left:3px solid var(--trust);border-radius:var(--r-sm);
  padding:.55rem .7rem;max-width:62ch}

/* ---- Apply-form consent checkboxes: unmistakable checked state (owner-reported: native box showed no visible pressed state, esp. low-vision/mobile). Custom-repaint, both themes, forced-colors + reduced-motion safe. 2026-09-09 ---- */
input[type="checkbox"]{-webkit-appearance:none;appearance:none;box-sizing:border-box;padding:0!important;width:26px!important;height:26px!important;min-width:26px;min-height:26px!important;flex:0 0 auto;margin:.15rem .1rem 0 0;display:inline-grid;place-content:center;vertical-align:top;background:var(--surface,#fff);border:2px solid var(--muted,#6a6459);border-radius:7px;cursor:pointer;-webkit-tap-highlight-color:transparent;transition:background-color .12s ease,border-color .12s ease}
input[type="checkbox"]::before{content:"";width:7px;height:13px;margin-top:-2px;border:solid var(--bg,#fff);border-width:0 3px 3px 0;transform:rotate(45deg) scale(0);transition:transform .12s ease-in-out}
input[type="checkbox"]:checked{background:var(--accent);border-color:var(--accent)}
input[type="checkbox"]:checked::before{transform:rotate(45deg) scale(1)}
input[type="checkbox"]:focus-visible{outline:3px solid var(--focus-ring,var(--accent));outline-offset:2px}
@supports not selector(:focus-visible){input[type="checkbox"]:focus{outline:3px solid var(--focus-ring,var(--accent));outline-offset:2px}}
@media (hover:hover) and (pointer:fine){input[type="checkbox"]:hover:not(:checked){border-color:var(--accent)}}
@media (forced-colors:active){input[type="checkbox"]{border-color:CanvasText;background:Canvas}input[type="checkbox"]:checked{background:Highlight;border-color:Highlight}input[type="checkbox"]::before{border-color:HighlightText}}
@media (prefers-reduced-motion:reduce){input[type="checkbox"],input[type="checkbox"]::before{transition:none}}

/* PWA install prompt bar */
.tribe-install{position:fixed;left:12px;right:12px;bottom:12px;max-width:540px;margin:0 auto;z-index:60;background:var(--surface);border:1px solid var(--line);border-radius:12px;box-shadow:var(--shadow);padding:.9rem 1rem;display:flex;gap:.7rem;align-items:center;flex-wrap:wrap}
.tribe-install .ti-t{flex:1;min-width:180px;color:var(--text);font-size:.92rem;line-height:1.4}
.tribe-install .ti-yes{min-height:40px}
.tribe-install .ti-x{background:transparent;border:0;color:var(--faint);font-size:1.5rem;line-height:1;cursor:pointer;min-width:44px;min-height:44px}
.tribe-install .ti-x:hover{color:var(--text)}

/* Shared show/hide password toggle (site-wide, enhanced by theme.js) */
.pw-wrap{position:relative;display:block}
.pw-wrap>input{width:100%;padding-right:3.1rem}
.pw-toggle{position:absolute;top:0;right:0;height:100%;min-height:44px;min-width:44px;display:inline-flex;align-items:center;justify-content:center;padding:0 .75rem;background:none;border:0;color:var(--muted);cursor:pointer;border-radius:var(--r-md,10px)}
.pw-toggle:hover{color:var(--text)}
.pw-toggle:focus-visible{outline:2px solid var(--accent);outline-offset:2px}
.pw-toggle svg{width:20px;height:20px;fill:none;stroke:currentColor;stroke-width:2;stroke-linecap:round;stroke-linejoin:round}
