/* ════════════════════════════════════════════════════════════════════════════
   EagleChirp v1.0 — app.css
   Mobile-first, responsive (bottom nav on phones, left rail on desktop),
   light + dark theming, Twitter-inspired but with EagleChirp's own identity.
   ════════════════════════════════════════════════════════════════════════════ */

:root {
  --accent: #1d9bf0;
  --accent-strong: #1a8cd8;
  --accent-soft: rgba(29,155,240,.10);
  --gold: #f5b301;
  --like: #f91880;
  --bg: #ffffff;
  --bg-elev: #ffffff;
  --bg-subtle: #f7f9f9;
  --bg-hover: #f2f5f7;
  --text: #0f1419;
  --text-dim: #536471;
  --border: #eff3f4;
  --border-strong: #cfd9de;
  --modal-veil: rgba(15,20,25,.45);
  --compose-bg: #f3f5f7;     /* light grey compose surface, per spec */
  --shadow: 0 0 18px rgba(0,0,0,.08), 0 2px 6px rgba(0,0,0,.04);
  --radius: 18px;
  --maxw: 1280px;
  --font: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif,
          "Apple Color Emoji", "Segoe UI Emoji";
}
@media (prefers-color-scheme: dark) {
  :root {
    --bg: #000000; --bg-elev: #16181c; --bg-subtle: #16181c; --bg-hover: #1d1f23;
    --text: #e7e9ea; --text-dim: #71767b; --border: #2f3336; --border-strong: #3e4144;
    --compose-bg: #1a1c20; --modal-veil: rgba(91,112,131,.4);
    --shadow: 0 0 22px rgba(255,255,255,.06);
  }
}
body.theme-dark {
  --bg: #000000; --bg-elev: #16181c; --bg-subtle: #16181c; --bg-hover: #1d1f23;
  --text: #e7e9ea; --text-dim: #71767b; --border: #2f3336; --border-strong: #3e4144;
  --compose-bg: #1a1c20; --modal-veil: rgba(91,112,131,.4);
}
body.theme-light {
  --bg:#fff; --bg-elev:#fff; --bg-subtle:#f7f9f9; --bg-hover:#f2f5f7;
  --text:#0f1419; --text-dim:#536471; --border:#eff3f4; --border-strong:#cfd9de;
  --compose-bg:#f3f5f7;
}

* { box-sizing: border-box; }
html, body { margin: 0; padding: 0; }
body {
  font-family: var(--font);
  background: var(--bg);
  color: var(--text);
  -webkit-font-smoothing: antialiased;
  overscroll-behavior-y: none;
}
a { color: inherit; text-decoration: none; }
button { font-family: inherit; cursor: pointer; border: none; background: none; color: inherit; }
svg { display: block; }
::-webkit-scrollbar { width: 8px; height: 8px; }
::-webkit-scrollbar-thumb { background: var(--border-strong); border-radius: 8px; }

/* ── Boot splash ─────────────────────────────────────────────────────────── */
.boot { position: fixed; inset: 0; display: grid; place-content: center; justify-items: center;
        gap: 14px; background: var(--bg); }
.boot-logo { font-size: 64px; animation: pop .6s ease, floaty 2.4s ease-in-out infinite .6s; }
.boot-name { font-weight: 800; font-size: 22px; letter-spacing: -.3px; color: var(--accent); }
@keyframes floaty { 50% { transform: translateY(-8px); } }
@keyframes pop { from { transform: scale(.4); opacity: 0; } }

/* ── App frame ───────────────────────────────────────────────────────────── */
.frame { display: grid; grid-template-columns: 1fr; max-width: var(--maxw); margin: 0 auto;
         min-height: 100vh; }
@media (min-width: 700px)  { .frame { grid-template-columns: 88px minmax(0,600px); } }
@media (min-width: 1100px) { .frame { grid-template-columns: 260px minmax(0,600px) 1fr; } }

/* ── Left rail (desktop) ─────────────────────────────────────────────────── */
.rail { display: none; }
@media (min-width: 700px) {
  .rail { display: flex; flex-direction: column; position: sticky; top: 0; height: 100vh;
          padding: 8px 8px 16px; border-right: 1px solid var(--border); }
}
.rail-logo { font-size: 30px; padding: 12px; border-radius: 50%; width: 52px; height: 52px;
             display: grid; place-content: center; }
.rail-logo:hover { background: var(--accent-soft); }
.rail-nav { display: flex; flex-direction: column; gap: 4px; margin-top: 4px; }
.rail-item { display: flex; align-items: center; gap: 16px; padding: 12px; border-radius: 30px;
             font-size: 19px; font-weight: 500; color: var(--text); position: relative; }
.rail-item:hover { background: var(--bg-hover); }
.rail-item.active { font-weight: 800; }
.rail-item .ico { width: 26px; height: 26px; flex: none; }
.rail-item .label { display: none; }
@media (min-width: 1100px) { .rail-item .label { display: inline; } }
.rail-badge { position: absolute; top: 6px; left: 30px; min-width: 18px; height: 18px; padding: 0 5px;
              border-radius: 9px; background: var(--accent); color: #fff; font-size: 11px;
              font-weight: 700; display: grid; place-content: center; }
.rail-compose { margin-top: 14px; }
.rail-me { margin-top: auto; display: flex; align-items: center; gap: 10px; padding: 10px;
           border-radius: 30px; }
.rail-me:hover { background: var(--bg-hover); }
.rail-me .meta { display: none; min-width: 0; }
@media (min-width: 1100px) { .rail-me .meta { display: block; } }
.rail-me .name { font-weight: 700; font-size: 15px; white-space: nowrap; overflow: hidden;
                 text-overflow: ellipsis; }
.rail-me .handle { color: var(--text-dim); font-size: 14px; }

/* ── Buttons ─────────────────────────────────────────────────────────────── */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 8px;
       background: var(--accent); color: #fff; font-weight: 800; font-size: 15px;
       padding: 11px 20px; border-radius: 999px; transition: background .15s, transform .08s; }
.btn:hover { background: var(--accent-strong); }
.btn:active { transform: scale(.97); }
.btn:disabled { opacity: .5; cursor: default; }
.btn-block { width: 100%; padding: 14px; font-size: 16px; }
.btn-ghost { background: transparent; color: var(--text); border: 1px solid var(--border-strong); }
.btn-ghost:hover { background: var(--bg-hover); }
.btn-danger { background: transparent; color: var(--like); border: 1px solid var(--border-strong); }
.btn-sm { padding: 7px 16px; font-size: 14px; }
.btn-compose-full { width: 100%; }
@media (min-width: 1100px) { .rail-compose .btn { width: 100%; } }

/* ── Center column ───────────────────────────────────────────────────────── */
.col { min-height: 100vh; border-right: 1px solid var(--border); position: relative;
       padding-bottom: 70px; }
@media (min-width: 700px) { .col { padding-bottom: 0; } }
.topbar { position: sticky; top: 0; z-index: 30; backdrop-filter: blur(12px);
          background: color-mix(in srgb, var(--bg) 80%, transparent); border-bottom: 1px solid var(--border); }
.topbar-row { display: flex; align-items: center; gap: 14px; padding: 10px 16px; min-height: 53px; }
.topbar-title { font-weight: 800; font-size: 20px; }
.topbar-sub { color: var(--text-dim); font-size: 13px; }
.back-btn { width: 36px; height: 36px; border-radius: 50%; display: grid; place-content: center; }
.back-btn:hover { background: var(--bg-hover); }

/* Feed tabs */
.tabs { display: flex; }
.tab { flex: 1; text-align: center; padding: 16px 0 0; font-weight: 600; color: var(--text-dim);
       position: relative; }
.tab:hover { background: var(--bg-hover); }
.tab span { padding-bottom: 14px; display: inline-block; position: relative; }
.tab.active { color: var(--text); font-weight: 800; }
.tab.active span::after { content: ""; position: absolute; left: 0; right: 0; bottom: 0; height: 4px;
       border-radius: 4px; background: var(--accent); }

/* ── Pull-to-refresh + new-posts pill ────────────────────────────────────── */
.ptr { display: grid; place-items: center; height: 0; overflow: hidden; transition: height .18s ease; }
.ptr.show { height: 56px; }
.ptr-circle { width: 30px; height: 30px; }
.ptr-circle circle { fill: none; stroke: var(--accent); stroke-width: 3; stroke-linecap: round;
       stroke-dasharray: 64; stroke-dashoffset: 20; }
.ptr.spin .ptr-circle { animation: spin .8s linear infinite; }
@keyframes spin { to { transform: rotate(360deg); } }

.newpill-wrap { display: flex; justify-content: center; position: sticky; top: 105px; z-index: 20;
       pointer-events: none; }
.newpill { pointer-events: auto; margin-top: 10px; background: var(--accent); color: #fff;
       font-weight: 700; font-size: 14px; padding: 9px 18px; border-radius: 999px;
       box-shadow: var(--shadow); display: inline-flex; align-items: center; gap: 8px;
       transform: translateY(-12px); opacity: 0; transition: .2s; }
.newpill.show { transform: translateY(0); opacity: 1; }
.newpill .ptr-circle { width: 16px; height: 16px; }
.newpill .ptr-circle circle { stroke: #fff; }

/* ── Inline composer (top of feed) ───────────────────────────────────────── */
.inline-compose { display: flex; gap: 12px; padding: 12px 16px; border-bottom: 10px solid var(--border); }
.inline-compose .avatar { flex: none; }
.inline-compose .fake-input { flex: 1; display: flex; align-items: center; color: var(--text-dim);
       font-size: 19px; padding: 10px 0; }

/* ── Post card ───────────────────────────────────────────────────────────── */
.post { display: flex; gap: 12px; padding: 12px 16px; border-bottom: 1px solid var(--border);
        cursor: pointer; transition: background .12s; }
.post:hover { background: var(--bg-subtle); }
.avatar { width: 44px; height: 44px; border-radius: 50%; object-fit: cover; background: var(--bg-hover);
        display: grid; place-content: center; font-weight: 800; color: #fff; overflow: hidden; flex: none; }
.avatar.lg { width: 84px; height: 84px; font-size: 34px; }
.avatar.sm { width: 34px; height: 34px; font-size: 14px; }
.post-main { flex: 1; min-width: 0; }
.post-head { display: flex; align-items: center; gap: 5px; font-size: 15px; }
.post-name { font-weight: 700; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; max-width: 45%; }
.post-handle, .post-dot, .post-time { color: var(--text-dim); }
.post-menu { margin-left: auto; color: var(--text-dim); width: 30px; height: 30px; border-radius: 50%;
        display: grid; place-content: center; }
.post-menu:hover { background: var(--accent-soft); color: var(--accent); }
.block-text { font-size: 15px; line-height: 1.45; white-space: pre-wrap; word-wrap: break-word;
        margin: 2px 0; }
.block-media { margin: 10px 0; border-radius: var(--radius); overflow: hidden; border: 1px solid var(--border);
        background: var(--bg-subtle); }
.block-media img, .block-media video { width: 100%; display: block; max-height: 540px; object-fit: cover; }
.block-gif { margin: 10px 0; width: 160px; border-radius: 14px; overflow: hidden; }
.block-gif img { width: 100%; display: block; }
.news-chip { display: inline-flex; align-items: center; gap: 5px; font-size: 12px; font-weight: 800;
        color: var(--gold); background: rgba(245,179,1,.12); padding: 2px 9px; border-radius: 8px;
        margin-bottom: 4px; }

/* Action bar */
.actions { display: flex; justify-content: space-between; max-width: 420px; margin-top: 8px; }
.action { display: inline-flex; align-items: center; gap: 6px; color: var(--text-dim); font-size: 13px;
        border-radius: 999px; padding: 4px; transition: color .12s; }
.action .ico { width: 19px; height: 19px; }
.action.reply:hover { color: var(--accent); }
.action.like:hover { color: var(--like); }
.action.share:hover { color: var(--accent); }
.action.bookmark:hover { color: var(--accent); }
.action.bookmark.on { color: var(--accent); }
.action.bookmark.on .bk { fill: var(--accent); animation: likepop .35s ease; }
.action.like.on { color: var(--like); }
.action.like.on .heart { fill: var(--like); animation: likepop .35s ease; }
@keyframes likepop { 40% { transform: scale(1.4); } }

/* ── Empty / loading states ──────────────────────────────────────────────── */
.empty { text-align: center; padding: 60px 30px; color: var(--text-dim); }
.empty .big { font-size: 40px; margin-bottom: 10px; }
.spinner { display: grid; place-items: center; padding: 28px; }
.spinner svg { width: 28px; height: 28px; animation: spin .8s linear infinite; }
.spinner circle { fill: none; stroke: var(--accent); stroke-width: 3; stroke-linecap: round;
        stroke-dasharray: 64; stroke-dashoffset: 24; }

/* ── Right rail ──────────────────────────────────────────────────────────── */
.aside { display: none; }
@media (min-width: 1100px) {
  .aside { display: block; padding: 12px 22px; position: sticky; top: 0; height: 100vh; overflow: auto; }
}
.search-box { display: flex; align-items: center; gap: 10px; background: var(--bg-subtle);
        border: 1px solid transparent; border-radius: 999px; padding: 11px 16px; color: var(--text-dim); }
.search-box input { flex: 1; border: none; background: none; outline: none; color: var(--text);
        font-size: 15px; }
.search-box:focus-within { border-color: var(--accent); background: var(--bg); }
.card { background: var(--bg-subtle); border-radius: 16px; margin-top: 16px; overflow: hidden; }
.card h3 { margin: 0; padding: 14px 16px 6px; font-size: 19px; font-weight: 800; }
.who { display: flex; align-items: center; gap: 10px; padding: 11px 16px; }
.who:hover { background: var(--bg-hover); }
.who .meta { flex: 1; min-width: 0; }
.who .name { font-weight: 700; font-size: 14px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.who .handle { color: var(--text-dim); font-size: 13px; }
.trend { padding: 10px 16px; }
.trend:hover { background: var(--bg-hover); }
.trend .k { font-size: 12px; color: var(--text-dim); }
.trend .t { font-weight: 700; font-size: 15px; }

/* ── Bottom nav (mobile) ─────────────────────────────────────────────────── */
.bottomnav { position: fixed; bottom: 0; left: 0; right: 0; z-index: 40; display: flex;
        background: color-mix(in srgb, var(--bg) 92%, transparent); backdrop-filter: blur(12px);
        border-top: 1px solid var(--border); padding: 6px 2px env(safe-area-inset-bottom); }
@media (min-width: 700px) { .bottomnav { display: none; } }
.bn-item { flex: 1; display: grid; place-items: center; padding: 10px 0; color: var(--text);
        position: relative; }
.bn-item .ico { width: 25px; height: 25px; }
.bn-item.active { color: var(--accent); }
.bn-badge { position: absolute; top: 4px; left: 56%; min-width: 16px; height: 16px; padding: 0 4px;
        border-radius: 8px; background: var(--like); color: #fff; font-size: 10px; font-weight: 700;
        display: grid; place-content: center; }
.fab { position: fixed; right: 18px; bottom: 78px; z-index: 41; width: 56px; height: 56px;
        border-radius: 50%; background: var(--accent); color: #fff; display: grid; place-content: center;
        box-shadow: var(--shadow); }
.fab:active { transform: scale(.94); }
@media (min-width: 700px) { .fab { display: none; } }
.fab .ico { width: 28px; height: 28px; }

/* ── Modal shell ─────────────────────────────────────────────────────────── */
.modal-veil { position: fixed; inset: 0; z-index: 100; background: var(--modal-veil);
        display: flex; align-items: flex-start; justify-content: center; padding: 40px 14px;
        animation: fade .15s ease; overflow: auto; }
@keyframes fade { from { opacity: 0; } }
.modal { width: 100%; max-width: 600px; background: var(--bg); border-radius: 20px; box-shadow: var(--shadow);
        animation: rise .2s cubic-bezier(.2,.8,.2,1); overflow: hidden; }
@keyframes rise { from { transform: translateY(16px) scale(.98); opacity: 0; } }
.modal-head { display: flex; align-items: center; gap: 12px; padding: 12px 16px; }
.modal-head .x { width: 36px; height: 36px; border-radius: 50%; display: grid; place-content: center; }
.modal-head .x:hover { background: var(--bg-hover); }
.modal-head .title { font-weight: 800; font-size: 18px; }
.modal-head .spacer { flex: 1; }
.modal-body { padding: 0 16px 16px; }

/* ── Composer modal (light grey surface per spec) ────────────────────────── */
.composer { background: var(--compose-bg); }
.composer .modal-body { padding-top: 6px; }
.compose-row { display: flex; gap: 12px; }
.blocks { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 6px; padding-top: 6px; }
.blk-text { width: 100%; border: none; background: none; outline: none; resize: none; color: var(--text);
        font-size: 19px; line-height: 1.4; font-family: inherit; min-height: 30px; }
.blk-text::placeholder { color: var(--text-dim); }
.blk-media { position: relative; border-radius: var(--radius); overflow: hidden; border: 1px solid var(--border); }
.blk-media img, .blk-media video { width: 100%; display: block; max-height: 360px; object-fit: cover; }
.blk-media .rm { position: absolute; top: 8px; right: 8px; width: 30px; height: 30px; border-radius: 50%;
        background: rgba(0,0,0,.6); color: #fff; display: grid; place-content: center; }
.blk-gif { position: relative; width: 150px; border-radius: 14px; overflow: hidden; }
.blk-gif img { width: 100%; }
.cat-pick { display: flex; flex-wrap: wrap; gap: 8px; padding: 12px 0 4px; }
.cat-tag { font-size: 13px; font-weight: 600; padding: 6px 12px; border-radius: 999px;
        border: 1px solid var(--border-strong); color: var(--text-dim); }
.cat-tag.on { background: var(--accent-soft); color: var(--accent); border-color: var(--accent); }
.compose-toolbar { display: flex; align-items: center; gap: 4px; border-top: 1px solid var(--border);
        padding-top: 10px; margin-top: 6px; }
.tool { width: 38px; height: 38px; border-radius: 50%; display: grid; place-content: center; color: var(--accent); }
.tool:hover { background: var(--accent-soft); }
.tool .ico { width: 21px; height: 21px; }
.compose-toolbar .spacer { flex: 1; }
.counter { font-size: 13px; color: var(--text-dim); margin-right: 6px; }

/* ── Emoji + GIF pickers ─────────────────────────────────────────────────── */
.picker { position: absolute; z-index: 120; width: min(340px, 92vw); max-height: 360px;
        background: var(--bg-elev); border: 1px solid var(--border); border-radius: 16px;
        box-shadow: var(--shadow); overflow: hidden; display: flex; flex-direction: column; }
.picker-search { padding: 10px; border-bottom: 1px solid var(--border); }
.picker-search input { width: 100%; border: 1px solid var(--border-strong); border-radius: 999px;
        padding: 8px 14px; background: var(--bg-subtle); color: var(--text); outline: none; }
.picker-scroll { overflow: auto; padding: 8px; }
.emoji-cat-label { font-size: 12px; color: var(--text-dim); font-weight: 700; padding: 6px 4px; }
.emoji-grid { display: grid; grid-template-columns: repeat(8, 1fr); }
.emoji-grid button { font-size: 22px; padding: 5px 0; border-radius: 8px; }
.emoji-grid button:hover { background: var(--bg-hover); }
.gif-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; }
.gif-grid figure { margin: 0; cursor: pointer; border-radius: 12px; overflow: hidden; border: 1px solid var(--border); }
.gif-grid img { width: 100%; display: block; }
.gif-grid figcaption { font-size: 11px; text-align: center; padding: 3px; color: var(--text-dim); }
.gif-grid figure:hover { outline: 2px solid var(--accent); }

/* ── Auth + onboarding ───────────────────────────────────────────────────── */
.auth { min-height: 100vh; display: grid; place-items: center; padding: 24px; }
.auth-card { width: 100%; max-width: 440px; }
.auth-logo { font-size: 50px; text-align: center; }
.auth-h1 { font-size: 30px; font-weight: 800; letter-spacing: -.5px; margin: 6px 0 4px; text-align: center; }
.auth-sub { color: var(--text-dim); text-align: center; margin-bottom: 22px; }
.field { margin-bottom: 14px; }
.field label { display: block; font-size: 13px; color: var(--text-dim); margin-bottom: 6px; font-weight: 600; }
.field input { width: 100%; border: 1px solid var(--border-strong); border-radius: 10px; padding: 14px;
        font-size: 16px; background: var(--bg); color: var(--text); outline: none; }
.field input:focus { border-color: var(--accent); }
.auth-switch { text-align: center; margin-top: 18px; color: var(--text-dim); }
.auth-switch a { color: var(--accent); font-weight: 600; }
.auth-err { background: rgba(249,24,128,.1); color: var(--like); border-radius: 10px; padding: 10px 14px;
        font-size: 14px; margin-bottom: 14px; }
.steps { display: flex; gap: 6px; justify-content: center; margin-bottom: 18px; }
.steps i { width: 28px; height: 5px; border-radius: 3px; background: var(--border-strong); }
.steps i.on { background: var(--accent); }
.cat-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(110px, 1fr)); gap: 10px;
        margin: 6px 0 18px; }
.cat-cell { border: 1.5px solid var(--border-strong); border-radius: 14px; padding: 14px 8px;
        text-align: center; transition: .12s; user-select: none; }
.cat-cell:hover { border-color: var(--accent); }
.cat-cell.on { background: var(--accent-soft); border-color: var(--accent); }
.cat-cell .e { font-size: 26px; }
.cat-cell .n { font-size: 13px; font-weight: 600; margin-top: 4px; }
.pick-count { text-align: center; font-size: 14px; color: var(--text-dim); margin-bottom: 12px; }
.pick-count b { color: var(--accent); }

/* ── Profile ─────────────────────────────────────────────────────────────── */
.pf-banner { height: 140px; background: linear-gradient(120deg, var(--accent), var(--gold)); }
.pf-head { padding: 0 16px 12px; position: relative; }
.pf-avatar { margin-top: -42px; border: 4px solid var(--bg); }
.pf-actions { position: absolute; right: 16px; top: 12px; display: flex; gap: 8px; }
.pf-name { font-weight: 800; font-size: 21px; margin-top: 8px; }
.pf-handle { color: var(--text-dim); }
.pf-bio { margin: 10px 0; font-size: 15px; line-height: 1.4; }
.pf-meta { display: flex; flex-wrap: wrap; gap: 16px; color: var(--text-dim); font-size: 14px; margin-bottom: 10px; }
.pf-stats { display: flex; gap: 20px; font-size: 14px; }
.pf-stats b { color: var(--text); }
.pf-stats span { color: var(--text-dim); }
.pf-stats .stat { cursor: pointer; }
.pf-tiles { display: flex; gap: 10px; padding: 12px 16px; }
.pf-tile { flex: 1; background: var(--bg-subtle); border-radius: 14px; padding: 12px; text-align: center; }
.pf-tile b { display: block; font-size: 20px; }
.pf-tile span { font-size: 12px; color: var(--text-dim); }

/* ── Notifications + messages ────────────────────────────────────────────── */
.notif { display: flex; gap: 12px; padding: 14px 16px; border-bottom: 1px solid var(--border); }
.notif.unread { background: var(--accent-soft); }
.notif .txt { flex: 1; font-size: 15px; }
.notif .txt b { font-weight: 700; }
.notif .req-actions { display: flex; gap: 8px; margin-top: 8px; }
.thread { display: flex; gap: 12px; padding: 14px 16px; border-bottom: 1px solid var(--border); cursor: pointer; }
.thread:hover { background: var(--bg-subtle); }
.thread .meta { flex: 1; min-width: 0; }
.thread .top { display: flex; gap: 6px; align-items: baseline; }
.thread .name { font-weight: 700; }
.thread .time { color: var(--text-dim); font-size: 13px; margin-left: auto; }
.thread .last { color: var(--text-dim); font-size: 14px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.thread .dot { width: 9px; height: 9px; border-radius: 50%; background: var(--accent); align-self: center; }
.chat { display: flex; flex-direction: column; height: calc(100vh - 54px); }
@media (max-width: 699px) { .chat { height: calc(100vh - 54px - 64px); } }
.chat-scroll { flex: 1; overflow: auto; padding: 14px; display: flex; flex-direction: column; gap: 8px; }
.bubble { max-width: 75%; padding: 10px 14px; border-radius: 18px; font-size: 15px; line-height: 1.35;
        word-wrap: break-word; }
.bubble.them { align-self: flex-start; background: var(--bg-subtle); border-bottom-left-radius: 5px; }
.bubble.me { align-self: flex-end; background: var(--accent); color: #fff; border-bottom-right-radius: 5px; }
.chat-input { display: flex; gap: 8px; padding: 10px; border-top: 1px solid var(--border); align-items: flex-end; }
.chat-input textarea { flex: 1; border: 1px solid var(--border-strong); border-radius: 18px; padding: 10px 14px;
        resize: none; font-family: inherit; font-size: 15px; background: var(--bg-subtle); color: var(--text);
        outline: none; max-height: 120px; }
.chat-blocked { text-align: center; padding: 14px; color: var(--text-dim); font-size: 14px; }

/* ── Toast ───────────────────────────────────────────────────────────────── */
.toast-wrap { position: fixed; left: 50%; bottom: 90px; transform: translateX(-50%); z-index: 200;
        display: flex; flex-direction: column; gap: 8px; align-items: center; }
.toast { background: var(--accent); color: #fff; font-weight: 600; font-size: 14px; padding: 11px 18px;
        border-radius: 999px; box-shadow: var(--shadow); animation: rise .2s ease; }
.toast.err { background: var(--like); }

/* ── Misc menu sheet ─────────────────────────────────────────────────────── */
.sheet { position: fixed; inset: 0; z-index: 150; background: var(--modal-veil); display: flex;
        align-items: flex-end; justify-content: center; animation: fade .15s; }
.sheet-card { background: var(--bg); width: 100%; max-width: 480px; border-radius: 18px 18px 0 0;
        padding: 8px; animation: rise .2s ease; margin-bottom: 0; }
@media (min-width: 700px) { .sheet { align-items: center; } .sheet-card { border-radius: 18px; } }
.sheet-item { display: flex; align-items: center; gap: 12px; padding: 16px; border-radius: 12px;
        font-weight: 600; font-size: 15px; }
.sheet-item:hover { background: var(--bg-hover); }
.sheet-item.danger { color: var(--like); }
