/* HeyTextMe relay — "Warm Ink" skin (from the Claude Design handoff).
   The brand gradient survives; everything sitting on it switches to a deep warm
   ink (#3d1414 / #401515). Worst body-text contrast is 5.37:1 — all pairs AA.
   Token names match docs/design-system.md §2; values are the re-skin. */

* { margin: 0; padding: 0; box-sizing: border-box; -webkit-tap-highlight-color: transparent; }

:root {
  --primary: #ff6262;
  --orange: #ffb255;
  --yellow: #ffe74e;

  --bg: #fdf8f2;
  --bg-nav: rgba(253, 248, 242, .95);
  --ink: #2b2424;
  --sub: #6f6363;
  --maroon: #7f3d3d;
  --bubble: #ffffff;
  --bubble-ink: #2b2424;
  --line: rgba(127, 61, 61, .15);
  --card: #ffffff;
  --input-border: #6f6363;
  --shadow: 0 18px 50px rgba(127, 61, 61, .3);

  --grad: linear-gradient(172.31deg, #ffe74e 21.73%, #ff6262 44.02%);
  --grad-btn: linear-gradient(172.31deg, #ffe74e 0%, #ff6262 70%);
  --grad-screen: linear-gradient(117.46deg, rgba(255, 231, 78, .87) 21.73%, rgba(255, 98, 98, .89) 44.02%);
  --grad-soft: linear-gradient(160deg, rgba(255, 231, 78, .35) 0%, rgba(255, 98, 98, .28) 60%, rgba(255, 98, 98, .38) 100%);

  --ink-grad: #3d1414;         /* text on gradient: bubbles, gradient CTAs */
  --ink-grad-strong: #401515;  /* text on full-bleed takeover surfaces */
  --avatar-fill: #fff7ec;
  --bubble-border: 1px solid rgba(127, 61, 61, .14);
  --bubble-shadow: 0 1px 2px rgba(127, 61, 61, .06);
  --danger: #b3372f;
  --success: #2e9e44;
  --stat-val: var(--primary);
  --unread-tint: linear-gradient(90deg, rgba(255, 231, 78, .14), rgba(255, 98, 98, .10));
  --scrim: rgba(64, 21, 21, .4);
  --fill-0: #7f3d3d;
}
@media (prefers-color-scheme: dark) {
  :root {
    --bg: #221b19; --bg-nav: rgba(34, 27, 25, .95); --ink: #f4ece6; --sub: #b5a49c;
    --maroon: #e0968c; --bubble: #382c29; --bubble-ink: #f4ece6;
    --line: rgba(224, 150, 140, .18); --card: #2d2422; --input-border: #b5a49c;
    --shadow: 0 18px 50px rgba(0, 0, 0, .5);
    --bubble-border: none; --bubble-shadow: none;
    --danger: #e0776d; --success: #8fd8a5; --stat-val: #ff8a8a;
    --grad-screen: linear-gradient(117.46deg, rgba(255, 231, 78, .32) 21.73%, rgba(255, 98, 98, .32) 44.02%);
    --grad-soft: linear-gradient(160deg, rgba(255, 231, 78, .1) 0%, rgba(255, 98, 98, .08) 60%, rgba(255, 98, 98, .12) 100%);
    --unread-tint: linear-gradient(90deg, rgba(255, 231, 78, .08), rgba(255, 98, 98, .06));
    --scrim: rgba(0, 0, 0, .55);
    --fill-0: #e0968c;
  }
  .icon-ink svg { --fill-0: #f4ece6; }
}

html, body { height: 100%; }
body {
  font-family: 'Plus Jakarta Sans', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  background: var(--bg); color: var(--ink); overflow: hidden;
  font-feature-settings: "dlig" 1;
}

#app { position: relative; width: 100%; height: 100dvh; max-width: 480px; margin: 0 auto; overflow: hidden; background: var(--bg); }
@media (min-width: 481px) {
  body { background: #191110; }
  #app { box-shadow: 0 0 80px rgba(0, 0, 0, .5); }
}

.screen { position: absolute; inset: 0; display: flex; flex-direction: column; background: var(--bg); overflow: hidden; }
.scroll { flex: 1; overflow-y: auto; -webkit-overflow-scrolling: touch; }
.spacer { flex: 1; }
.center { text-align: center; }
.hide { display: none !important; }

/* Logo is an <img> (design spec), so it keeps its aspect ratio — height fixed,
   width auto. Injecting the raw SVG at width:100% is what stretched it. */
.logo { display: block; height: 18px; width: auto; }
.ic svg { width: 100%; height: 100%; display: block; }
.ic { display: inline-grid; place-items: center; flex: none; }
.icon-ink svg { --fill-0: var(--ink); }

/* ---------------- bars ---------------- */
.appbar {
  display: flex; align-items: center; gap: 10px; height: 59px; padding: 16px 16px 9px; flex: none;
  background: var(--bg-nav); backdrop-filter: blur(18px); -webkit-backdrop-filter: blur(18px);
  border-bottom: 1px solid var(--line); z-index: 5;
}
.appbar .grow { flex: 1; min-width: 0; }
.backwrap { display: flex; align-items: center; gap: 4px; background: none; border: none; cursor: pointer; padding: 0; }
.backwrap .ic { width: 24px; height: 24px; }
.badge {
  background-image: var(--grad-btn); color: var(--ink-grad);
  display: inline-flex; align-items: center; justify-content: center;
  min-width: 12px; height: 19px; padding: 0 6px; border-radius: 999px;
  font-size: 12px; line-height: 1; font-weight: 700;
}
.peer { display: flex; align-items: center; gap: 8px; min-width: 0; }
.peer b { font-size: 16px; font-weight: 700; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.iconbtn { background: none; border: none; cursor: pointer; width: 24px; height: 24px; padding: 0; flex: none; }

/* ---------------- avatars ----------------
   Accounts: cream disc + maroon rule. Guests: flat fill (hue rotates by name),
   no rule. The initial is nudged up 1px for optical centering (Jakarta Sans). */
.avatar {
  border-radius: 50%; flex: none;
  background: var(--avatar-fill); border: 2px solid var(--maroon); color: var(--maroon);
  display: grid; place-items: center; font-weight: 800;
  width: 44px; height: 44px; font-size: 19px; text-transform: lowercase; user-select: none;
}
.avatar span { display: block; line-height: 1; transform: translateY(-1px); }
.avatar.sm { width: 30px; height: 30px; font-size: 14px; border-width: 1.5px; }
.avatar.sm span { transform: translateY(-.5px); }
.avatar.lg {
  width: 78px; height: 78px; font-size: 34px;
  border: 2.5px solid var(--ink-grad-strong); color: var(--maroon);
  box-shadow: 0 0 0 4px rgba(255, 255, 255, .45);
}
.avatar.guest { border-color: transparent; font-weight: 700; background: var(--orange); color: #5a2a00; }
.avatar.sys { border-color: transparent; background: #f3e7d9; color: var(--maroon); font-weight: 400; }

/* ---------------- warp overlay + scan card ---------------- */
/* #3 — deliberately slow (~1100ms): the takeover rises up over the chat, which
   stays faintly visible/blurred behind. Do not cut or fade instantly. */
.warp {
  position: absolute; inset: 0; z-index: 40; overflow-y: auto; background: var(--grad-screen);
  display: flex; flex-direction: column;
  animation: rise 1100ms var(--ease-settle);
}
.warp.leaving { animation: warp-out 240ms var(--ease-sharp) forwards; }
@keyframes warp-out { to { opacity: 0; transform: scale(1.06); } }
/* The chat stays faintly legible behind — it's the thing being kept. */
.blurred { filter: blur(2.5px); transform: scale(.98); pointer-events: none; }

.scanpop {
  width: min(323px, calc(100% - 52px)); margin: 0 auto; padding: 18px 0 26px;
  display: flex; flex-direction: column; gap: 14px; color: var(--ink-grad-strong); flex: 1;
}
.scanpop .xrow { display: flex; justify-content: flex-end; }
.scanpop .xrow button {
  background: none; border: none; cursor: pointer; color: var(--ink-grad-strong);
  font-size: 26px; line-height: 1; padding: 4px; opacity: .75; width: 32px; height: 32px;
}
.scanpop .idblock { display: flex; flex-direction: column; align-items: center; gap: 14px; text-align: center; }
.scanpop h2 { font-size: 36px; font-weight: 800; line-height: 1.05; letter-spacing: -1.1px; }
.scanpop .uname { font-size: 15px; font-weight: 600; opacity: .8; margin-top: 2px; }
.scanpop .bio { font-size: 15.5px; font-weight: 500; line-height: 1.45; margin: 12px auto 0; max-width: 246px; }
.scanpop .disc { text-align: center; font-size: 15px; font-weight: 700; margin-top: 10px; }
.scanpop .disc span { display: block; font-size: 12px; font-weight: 600; opacity: .7; margin-top: 2px; }
.statcard {
  border: 1px solid rgba(64, 21, 21, .32); border-radius: 12px; min-height: 64px; margin-top: 4px;
  display: flex; align-items: center; gap: 12px; padding: 8px 14px; background: transparent;
}
.statcard > div { flex: 1; text-align: center; }
.statcard .val { font-size: 19px; font-weight: 700; line-height: 1.2; letter-spacing: -.2px; white-space: nowrap; }
.statcard .lbl { font-size: 12.5px; font-weight: 600; opacity: .7; line-height: 1.2; }
.statcard .div { flex: none; width: 1px; height: 38px; background: rgba(64, 21, 21, .32); }
.scanpop .helper { text-align: center; font-size: 15px; font-weight: 600; line-height: 1.35; padding: 0 8px; }
.scanpop .fineprint { text-align: center; font-size: 12.5px; font-weight: 700; opacity: .85; }
.btn-white {
  display: block; width: 100%; height: 52px; border: none; border-radius: 27px; cursor: pointer;
  background: #fff; color: var(--maroon); font-family: inherit; font-size: 17px; font-weight: 800;
  box-shadow: 0 12px 30px rgba(64, 21, 21, .26);
}
.btn-white:active { transform: scale(.98); }
.btn-white:disabled { opacity: .6; }

/* stat card on a light surface (owner inbox) */
.statcard.on-light { border-color: rgba(255, 98, 98, .55); color: var(--ink); }
.statcard.on-light .val { color: var(--stat-val); }
.statcard.on-light .lbl { color: var(--maroon); opacity: 1; }
.statcard.on-light .div { background: rgba(255, 98, 98, .55); }

/* name entry inside the warp (guest identity) */
.namebox { display: flex; flex-direction: column; gap: 10px; }
.namebox label { font-size: 14px; font-weight: 600; }
.namebox .bigq { font-size: 26px; font-weight: 800; line-height: 1.15; letter-spacing: -.5px; text-align: center; }
.namebox input {
  width: 100%; border: none; border-radius: 28px; padding: 14px 18px; font-family: inherit;
  font-size: 16px; background: rgba(255, 255, 255, .92); color: #2a2424; outline: none;
  caret-color: var(--primary);
}
.namebox .fine { font-size: 12.5px; font-weight: 700; opacity: .85; line-height: 1.5; text-align: center; }
.orrow { display: flex; align-items: center; gap: 10px; opacity: .7; font-size: 12px; font-weight: 700; }
.orrow::before, .orrow::after { content: ''; flex: 1; height: 1px; background: var(--ink-grad-strong); }
.btn-ghost-ink {
  display: block; width: 100%; height: 46px; border-radius: 27px; cursor: pointer;
  background: transparent; border: 1.5px solid rgba(64, 21, 21, .55);
  color: var(--ink-grad-strong); font-family: inherit; font-size: 14.5px; font-weight: 700;
}

/* ---------------- chat ---------------- */
.msgs { flex: 1; overflow-y: auto; overflow-x: hidden; background: var(--bg); touch-action: pan-y; scroll-behavior: smooth; }
.msgs-inner { display: flex; flex-direction: column; min-height: 100%; justify-content: flex-end; padding: 0 16px 8px; }
.datehead { text-align: center; font-size: 12px; font-weight: 600; color: var(--maroon); padding: 32px 0 8px; }
.datehead.first { padding-top: 16px; }
.msg-group { display: flex; flex-direction: column; gap: 4px; margin-bottom: 8px; }
.msg-group.out { align-items: flex-end; }
.msg-group.in { align-items: flex-start; }
.sender-label { font-size: 12px; line-height: 20px; color: var(--maroon); }
.msg-group.out .sender-label { padding-right: 8px; }
.msg-group.in .sender-label { padding-left: 16px; }
/* Offset with `left`, not `transform` — keeps the sent bubbles' shared gradient
   stationary while the bubble slides over it (and transforms would create a
   containing block that breaks fixed-style painting). */
.msgrow { position: relative; display: flex; max-width: 100%; left: var(--dx, 0px); transition: left .35s cubic-bezier(.25, 1, .35, 1); }
.msgrow.dragging { transition: none; }
.msg-group.out .msgrow { justify-content: flex-end; }
.bubble { max-width: 240px; min-width: 40px; padding: 10px 14px; border-radius: 18px; font-size: 16px; line-height: 24px; word-wrap: break-word; white-space: pre-wrap; }
/* Sent bubbles are windows onto ONE gradient spanning the thread; chat.js sets
   background-size/position per bubble. Ink 5.5:1 on coral, ~9:1 on yellow. */
.msg-group.out .bubble {
  background-image: var(--grad); background-repeat: no-repeat;
  color: var(--ink-grad); font-weight: 500;
}
.msg-group.in .bubble {
  background: var(--bubble); color: var(--bubble-ink);
  border: var(--bubble-border); box-shadow: var(--bubble-shadow);
}
/* Grouped bubbles tuck the corner nearest a same-side neighbour (iMessage-style):
   the class is set per bubble in chat.js render(). */
.msg-group.in .b-first { border-bottom-left-radius: 5px; }
.msg-group.in .b-mid   { border-top-left-radius: 5px; border-bottom-left-radius: 5px; }
.msg-group.in .b-last  { border-top-left-radius: 5px; }
.msg-group.out .b-first { border-bottom-right-radius: 5px; }
.msg-group.out .b-mid   { border-top-right-radius: 5px; border-bottom-right-radius: 5px; }
.msg-group.out .b-last  { border-top-right-radius: 5px; }
/* #1 — sent springs up from the composer, received slides in from the left.
   Uses the shared struct duration + settle easing (no per-component timing). */
.msg-group.out .msgrow.new .bubble { animation: bubble-in-sent var(--dur-struct) var(--ease-settle) both; }
.msg-group.in  .msgrow.new .bubble { animation: bubble-in-recv var(--dur-struct) var(--ease-settle) both; animation-delay: var(--stagger, 0ms); }
.stamp { position: absolute; top: 50%; transform: translateY(-50%); font-size: 12px; color: var(--maroon); font-weight: 500; white-space: nowrap; opacity: var(--dxP, 0); pointer-events: none; }
.msg-group.out .stamp { left: 100%; padding-left: 10px; }
.msg-group.in .stamp { right: 100%; padding-right: 10px; }
.receipt { text-align: right; font-size: 11px; color: var(--maroon); font-weight: 600; padding: 2px 8px 0; }

/* peer typing — received-side bubble with three pulsing dots */
.typing-bubble {
  align-self: flex-start; background: var(--bubble); border: var(--bubble-border); box-shadow: var(--bubble-shadow);
  border-radius: 18px 18px 18px 5px; padding: 12px 14px; display: inline-flex; gap: 5px;
  animation: bubble-in-recv var(--dur-struct) var(--ease-settle) both;
}
.typing-bubble i { width: 7px; height: 7px; border-radius: 50%; background: var(--sub); animation: tdot 1.2s infinite ease-in-out; }
.typing-bubble i:nth-child(2) { animation-delay: .18s; }
.typing-bubble i:nth-child(3) { animation-delay: .36s; }
@keyframes tdot { 0%, 60%, 100% { opacity: .35; transform: none; } 30% { opacity: 1; transform: translateY(-3px); } }

.composer { display: flex; gap: 10px; align-items: flex-end; padding: 4px 16px calc(8px + env(safe-area-inset-bottom)); flex: none; background: var(--bg); }
.inputpill { flex: 1; display: flex; align-items: center; min-height: 36px; border: 1.5px solid var(--input-border); border-radius: 22px; padding: 4px 8px 4px 16px; }
.inputpill textarea {
  flex: 1; border: none; outline: none; resize: none; background: transparent; font-family: inherit;
  font-size: 16px; line-height: 24px; color: var(--ink); max-height: 120px; min-width: 0;
  caret-color: var(--primary);
}
.inputpill textarea::placeholder { color: var(--sub); }
/* #7 — send samples the bubble gradient. Empty: dim + shrunk. Typing: full. */
.sendbtn {
  width: 44px; height: 44px; border-radius: 50%; border: none; flex: none; padding: 10px;
  background-image: var(--grad-btn); cursor: pointer; display: grid; place-items: center;
  opacity: .5; transform: scale(.88); margin-bottom: 1px;
  transition: opacity var(--dur-micro) ease, transform var(--dur-micro) var(--ease-settle);
}
.sendbtn.on { opacity: 1; transform: none; }
.sendbtn.on:active { transform: scale(.94); }
.sendbtn .ic { width: 22px; height: 22px; }
.sendbtn .ic svg { --fill-0: var(--ink-grad); }

/* owner inbox chrome — Design Sticker chip + account button (matches the product) */
.pill-btn {
  display: inline-flex; align-items: center; gap: 5px; height: 24px; padding: 0 10px;
  background: transparent; color: var(--maroon); border: 1px solid rgba(127, 61, 61, .35);
  border-radius: 999px; font-family: inherit; font-size: 12px; line-height: 1; font-weight: 600;
  text-decoration: none; cursor: pointer;
}
.pill-btn .ic { width: 12px; height: 12px; }
.account-btn { background: none; border: none; cursor: pointer; width: 24px; height: 24px; padding: 0; color: var(--ink); }
.account-btn .ic { width: 24px; height: 24px; }

/* ---------------- inbox ---------------- */
.h1row { padding: 20px 16px 8px; }
.h1row h1 { font-size: 28px; font-weight: 800; letter-spacing: -.84px; }
/* Read rows carry a 36px left indent (16 pad + 10 dot + 10 gap) so their avatars
   line up with unread rows, which show the dot inline instead. */
.convo-row { display: flex; align-items: center; gap: 10px; padding: 12px 16px 12px 36px; cursor: pointer; border-bottom: 1px solid var(--line); }
.convo-row:active { background-color: rgba(127, 61, 61, .05); }
/* #7 — gentle pulse so unread reads as live. */
.unread-dot {
  width: 10px; height: 10px; border-radius: 50%; flex: none;
  background-image: var(--grad-btn); box-shadow: 0 0 0 3px rgba(255, 98, 98, .28);
  animation: pulse 2s infinite;
}
.convo-main { flex: 1; min-width: 0; }
.convo-top { display: flex; align-items: baseline; gap: 8px; }
.convo-top b { font-size: 16px; font-weight: 700; flex: 1; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; display: flex; align-items: center; gap: 8px; }
.convo-top time { font-size: 12px; color: var(--sub); flex: none; font-weight: 400; }
.convo-top .chev { color: var(--maroon); font-weight: 400; }
.convo-preview { font-size: 14px; color: var(--sub); line-height: 1.4; margin-top: 2px; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
/* Unread is an event, not a dot: the row de-indents, warms up, bolds. */
.convo-row.unread { padding: 14px 16px; background-image: var(--unread-tint); }
.convo-row.unread .convo-top b { font-weight: 800; }
.convo-row.unread .convo-top time { color: var(--maroon); font-weight: 700; }
.convo-row.unread .convo-preview { color: var(--ink); font-weight: 600; }
.blocked-tag { font-size: 11px; font-weight: 700; color: var(--danger); }
.chip-stranger {
  display: inline-flex; align-items: center; height: 17px; padding: 0 7px;
  font-size: 10px; font-weight: 700; line-height: 1; letter-spacing: .2px;
  color: var(--maroon); border: 1px solid rgba(127, 61, 61, .4);
  border-radius: 999px; flex: none; text-transform: lowercase;
}

/* empty inbox — propeller char, headline, 1·2·3 steps, gradient CTA */
.empty-wrap { flex: 1; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 16px; padding: 0 32px; }
.empty-wrap .char { height: 128px; }
.empty-wrap .char svg { height: 128px; width: auto; --fill-0: var(--char-ink); }
.empty-note { font-size: 20px; font-weight: 800; letter-spacing: -.4px; color: var(--ink); text-align: center; line-height: 1.3; }
.steps { display: flex; flex-direction: column; gap: 10px; width: 100%; }
.steps .row { display: flex; align-items: center; gap: 10px; }
.steps .n { width: 22px; height: 22px; border-radius: 50%; display: inline-flex; align-items: center; justify-content: center; flex: none; font-size: 12px; font-weight: 800; }
.steps .n1 { background: var(--yellow); color: #5a4a00; }
.steps .n2 { background: var(--orange); color: #5a2a00; }
.steps .n3 { background: var(--primary); color: #4a0f0f; }
.steps .row span:last-child { font-size: 14px; line-height: 1.4; color: var(--ink); font-weight: 600; }
.empty-cta {
  margin-top: 6px; height: 48px; border: none; border-radius: 24px; cursor: pointer;
  background-image: var(--grad-btn); color: var(--ink-grad); font-family: inherit;
  font-size: 15px; font-weight: 800; padding: 0 26px; box-shadow: 0 10px 24px rgba(255, 98, 98, .3);
}
/* ---------------- generic ---------------- */
.pad { padding: 20px 16px; }
.btn {
  display: block; width: 100%; border: none; border-radius: 27px; cursor: pointer; font-family: inherit;
  font-size: 15px; font-weight: 700; padding: 13px 16px;
  background-image: var(--grad-btn); color: var(--ink-grad); margin-top: 12px;
}
.btn:active { transform: scale(.98); }
.btn:disabled { opacity: .45; pointer-events: none; }
.btn.ghost { background: transparent; border: 1px solid var(--line); color: var(--ink); }
.btn.plain { background: none; color: var(--maroon); font-weight: 700; }
.field { display: flex; align-items: center; gap: 8px; border: 1.5px solid var(--input-border); border-radius: 28px; padding: 12px 16px; }
.field input, .field textarea { flex: 1; border: none; outline: none; background: transparent; color: var(--ink); font-family: inherit; font-size: 16px; min-width: 0; caret-color: var(--primary); }
.fieldlabel { font-size: 13px; font-weight: 700; color: var(--maroon); margin: 12px 2px 6px; }
.lede { font-size: 14px; color: var(--sub); line-height: 1.5; }
.note {
  border: 1px solid var(--line); background: var(--card); border-radius: 16px; padding: 14px;
  font-size: 13.5px; line-height: 1.5; color: var(--sub); margin-top: 12px;
}
.note b { color: var(--ink); }
.err { color: var(--danger); font-size: 13px; font-weight: 600; text-align: center; min-height: 18px; }

/* #6 — drop in with overshoot; retract sharp. */
.toast {
  position: absolute; top: 10px; left: 10px; right: 10px; z-index: 70;
  background: var(--card); border: 1px solid var(--line); border-radius: 18px;
  padding: 12px 14px; box-shadow: 0 14px 40px rgba(64, 21, 21, .3);
  display: flex; gap: 10px; align-items: center; font-size: 13.5px;
  animation: banner-in 360ms var(--ease-settle);
}
@media (prefers-color-scheme: dark) { .toast { box-shadow: 0 14px 40px rgba(0, 0, 0, .5); } }
.toast.leaving { animation: banner-out 280ms var(--ease-sharp) forwards; }
.toast .dot { width: 32px; height: 32px; border-radius: 9px; background-image: var(--grad-btn); display: grid; place-items: center; flex: none; }
.toast .txt { flex: 1; min-width: 0; }
.toast .txt b { display: block; color: var(--ink); }
.toast .txt span { color: var(--sub); display: block; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }

.spin { width: 26px; height: 26px; border: 3px solid var(--line); border-top-color: var(--primary); border-radius: 50%; animation: spin .8s linear infinite; margin: 40px auto; }
@keyframes spin { to { transform: rotate(360deg); } }

/* login — the designed auth card on the soft gradient */
.auth-bg {
  flex: 1; display: flex; align-items: center; justify-content: center; padding: 22px;
  background: var(--grad-soft), var(--bg);
}
.auth-card {
  width: 100%; max-width: 360px; background: var(--card); border-radius: 24px;
  box-shadow: var(--shadow); padding: 26px 22px; display: flex; flex-direction: column; gap: 13px;
  animation: rise 550ms var(--ease-settle);
}
.auth-title { font-size: 24px; line-height: 1.2; font-weight: 800; letter-spacing: -.5px; color: var(--ink); }
.auth-legal { font-size: 11px; line-height: 1.5; color: var(--sub); text-align: center; }
.auth-alt { font-size: 13px; font-weight: 600; color: var(--maroon); text-align: center; text-decoration: none; }

/* report flow — radio reason rows (5a) */
.reason-row {
  display: flex; align-items: center; gap: 10px; padding: 12px 14px; margin-top: 8px;
  border: 1.5px solid var(--line); border-radius: 16px; cursor: pointer;
  font-size: 15px; font-weight: 600; color: var(--ink);
  transition: border-color var(--dur-micro), background var(--dur-micro);
}
.reason-row.sel { border-color: var(--maroon); background: var(--card); }
.reason-row .radio {
  width: 18px; height: 18px; border-radius: 50%; border: 2px solid var(--input-border); flex: none;
  display: grid; place-items: center; transition: border-color var(--dur-micro);
}
.reason-row.sel .radio { border-color: var(--maroon); }
.reason-row.sel .radio::after { content: ''; width: 9px; height: 9px; border-radius: 50%; background: var(--maroon); animation: check-pop 200ms var(--ease-settle); }
.check-big {
  width: 56px; height: 56px; border-radius: 50%; margin: 6px auto 10px;
  background-image: var(--grad-btn); display: grid; place-items: center;
  animation: check-pop 420ms var(--ease-settle);
}
.check-big svg { width: 28px; height: 28px; stroke: var(--ink-grad); stroke-width: 3.2; fill: none; stroke-linecap: round; stroke-linejoin: round; }
.btn.danger-solid { background: var(--danger); color: #fff; }
.sheet-item {
  display: flex; align-items: center; gap: 12px; width: 100%; text-align: left;
  background: none; border: none; font-family: inherit; font-size: 15.5px; font-weight: 600;
  color: var(--ink); padding: 13px 2px; border-top: 1px solid var(--line); cursor: pointer;
}
.sheet-item .emo { width: 26px; text-align: center; font-size: 17px; }
.sheet-item.danger { color: var(--danger); }

/* empty chat — "Say hi" nudge + starter chips (5a) */
.sayhi { flex: 1; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 10px; padding: 0 28px; text-align: center; }
.sayhi h3 { font-size: 19px; font-weight: 800; color: var(--ink); }
.sayhi p { font-size: 14px; color: var(--sub); line-height: 1.5; }
.sayhi p b { color: var(--ink); }
.chips { display: flex; flex-wrap: wrap; gap: 8px; justify-content: center; margin-top: 6px; }
.chip {
  height: 34px; padding: 0 14px; border-radius: 999px; cursor: pointer;
  border: 1.5px solid rgba(127, 61, 61, .4); background: transparent; color: var(--maroon);
  font-family: inherit; font-size: 13.5px; font-weight: 600;
  transition: transform 120ms var(--ease-settle);
}
.chip:active { transform: scale(.94); }

/* growth popup — in-chat, above the composer (5a) */
.growth {
  position: absolute; left: 14px; right: 14px; bottom: 78px; z-index: 30;
  background: var(--card); border: 1px solid var(--line); border-radius: 18px;
  padding: 14px 15px; display: flex; gap: 12px; align-items: center;
  box-shadow: 0 14px 40px rgba(64, 21, 21, .3);
  animation: sheet-up var(--dur-struct) var(--ease-settle);
}
.growth.leaving { animation: sheet-down 240ms var(--ease-sharp) forwards; }
.growth .char { height: 54px; flex: none; }
.growth .char svg { height: 54px; width: auto; --fill-0: var(--char-ink); }
.growth .txt { flex: 1; min-width: 0; }
.growth .txt b { display: block; font-size: 14.5px; font-weight: 800; color: var(--ink); }
.growth .txt span { font-size: 13px; color: var(--sub); }
.growth .go {
  height: 32px; padding: 0 13px; border: none; border-radius: 999px; cursor: pointer;
  background-image: var(--grad-btn); color: var(--ink-grad);
  font-family: inherit; font-size: 13px; font-weight: 800; white-space: nowrap;
  display: inline-flex; align-items: center; text-decoration: none;
}
.growth .x { background: none; border: none; cursor: pointer; color: var(--sub); font-size: 15px; padding: 4px; }

/* paused sticker — desaturated calm screen (5a) */
.paused-bg { position: absolute; inset: 0; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 14px; padding: 0 32px; text-align: center; background: var(--grad-soft), var(--bg); z-index: 40; }
.paused-bg .char { height: 120px; }
.paused-bg .char svg { height: 120px; width: auto; --fill-0: var(--char-ink); }
.paused-row { display: flex; align-items: center; gap: 12px; }
.paused-row .avatar { filter: grayscale(.3); }
.paused-row h2 { font-size: 22px; font-weight: 800; letter-spacing: -.4px; color: var(--ink); text-align: left; line-height: 1.15; }
.paused-bg p { font-size: 14.5px; line-height: 1.55; color: var(--sub); max-width: 250px; }
.paused-bg .fine { font-size: 12px; font-weight: 600; color: var(--sub); }
.btn-outline {
  height: 46px; padding: 0 22px; border-radius: 27px; cursor: pointer;
  border: 1.5px solid rgba(127, 61, 61, .5); background: transparent; color: var(--maroon);
  font-family: inherit; font-size: 14.5px; font-weight: 700;
  display: inline-flex; align-items: center; text-decoration: none;
}

/* inbox footer — angel + hint */
.inbox-foot { display: flex; align-items: center; justify-content: center; gap: 14px; padding: 20px; margin-top: auto; }
.inbox-foot .char { height: 62px; }
.inbox-foot .char svg { height: 62px; width: auto; --fill-0: var(--char-ink); }
.inbox-foot span { font-size: 12px; line-height: 1.5; color: var(--sub); max-width: 150px; }

/* #4 — bottom sheet: scrim + panel animate in parallel, dismiss reverses sharp. */
.sheet-scrim {
  position: absolute; inset: 0; z-index: 60; background: var(--scrim);
  display: flex; flex-direction: column; justify-content: flex-end;
  animation: scrim-in 280ms ease;
}
.sheet-scrim.leaving { animation: scrim-out 240ms var(--ease-sharp) forwards; }
.sheet-panel {
  background: var(--card); border-radius: 20px 20px 0 0; padding: 20px;
  padding-bottom: calc(20px + env(safe-area-inset-bottom));
  animation: sheet-up var(--dur-struct) var(--ease-settle);
}
.sheet-scrim.leaving .sheet-panel { animation: sheet-down 240ms var(--ease-sharp) forwards; }
.sheet-panel h2 { color: var(--ink); font-size: 18px; font-weight: 800; margin-bottom: 4px; }
.sheet-grab { width: 38px; height: 4px; border-radius: 2px; background: var(--line); margin: -6px auto 12px; }
.acct-card { display: flex; align-items: center; gap: 12px; margin-bottom: 6px; }
.acct-card .names b { font-size: 17px; font-weight: 800; display: block; }
.acct-card .names span { font-size: 13px; color: var(--sub); }
.set-row { display: flex; align-items: center; gap: 10px; padding: 13px 2px; border-top: 1px solid var(--line); font-size: 15px; }
.set-row .grow { flex: 1; min-width: 0; }
.set-row .grow small { display: block; color: var(--sub); font-size: 12.5px; margin-top: 1px; }
.set-row.tappable { cursor: pointer; }
.set-row .val { color: var(--sub); font-size: 13px; }
.switch { position: relative; width: 46px; height: 28px; flex: none; }
.switch input { opacity: 0; width: 100%; height: 100%; position: absolute; margin: 0; cursor: pointer; z-index: 2; }
.switch .knob { position: absolute; inset: 0; border-radius: 14px; background: var(--bubble); transition: background var(--dur-micro); }
.switch .knob::after { content: ''; position: absolute; top: 2px; left: 2px; width: 24px; height: 24px; border-radius: 50%; background: #fff; box-shadow: 0 2px 6px rgba(0,0,0,.3); transition: transform var(--dur-micro) var(--ease-settle); }
.switch input:checked + .knob { background: var(--primary); }
.switch input:checked + .knob::after { transform: translateX(18px); }
.acct-bio { width: 100%; border: 1.5px solid var(--input-border); border-radius: 14px; padding: 10px 12px; font-family: inherit; font-size: 14.5px; color: var(--ink); background: transparent; resize: none; line-height: 1.45; margin-top: 8px; caret-color: var(--primary); }
.danger-row { color: var(--danger); font-weight: 700; }
