:root {
  --bg: #FAF9F5;
  --sidebar: #F0EEE6;
  --surface: #FFFFFF;
  --surface-2: #F5F4EE;
  --border: #E6E3D8;
  --border-strong: #D6D2C4;
  --text: #141413;
  --text-2: #3D3D3A;
  --muted: #75736C;
  --accent: #D97757;
  --accent-hover: #C6613F;
  --accent-soft: #F7E6DE;
  --accent-text: #A9502F;
  --ok: #4F7A3A;
  --ok-soft: #E5EEDC;
  --warn: #9A6B12;
  --warn-soft: #F6ECD3;
  --bad: #B3452F;
  --bad-soft: #F6E0DA;
  --bubble-me: #F0EEE6;
  --shadow: 0 1px 2px rgba(20,20,19,.04), 0 8px 24px rgba(20,20,19,.06);
  --serif: "Source Serif 4", "Iowan Old Style", Georgia, serif;
  --sans: "Inter", ui-sans-serif, -apple-system, "Segoe UI", system-ui, sans-serif;
  --mono: ui-monospace, "SF Mono", Menlo, monospace;
  color-scheme: light;
}
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --bg: #262624; --sidebar: #1F1E1D; --surface: #30302E; --surface-2: #2A2A28;
    --border: #3B3A36; --border-strong: #4A4944; --text: #F5F4EE; --text-2: #DEDCD1; --muted: #A3A096;
    --accent-soft: #4A3229; --accent-text: #EBA185; --ok: #9CC283; --ok-soft: #2F3A28;
    --warn: #E2BC6A; --warn-soft: #403522; --bad: #EE937C; --bad-soft: #452A24; --bubble-me: #3A3936;
    --shadow: 0 1px 2px rgba(0,0,0,.2), 0 8px 24px rgba(0,0,0,.25); color-scheme: dark;
  }
}
:root[data-theme="dark"] {
  --bg: #262624; --sidebar: #1F1E1D; --surface: #30302E; --surface-2: #2A2A28;
  --border: #3B3A36; --border-strong: #4A4944; --text: #F5F4EE; --text-2: #DEDCD1; --muted: #A3A096;
  --accent-soft: #4A3229; --accent-text: #EBA185; --ok: #9CC283; --ok-soft: #2F3A28;
  --warn: #E2BC6A; --warn-soft: #403522; --bad: #EE937C; --bad-soft: #452A24; --bubble-me: #3A3936;
  --shadow: 0 1px 2px rgba(0,0,0,.2), 0 8px 24px rgba(0,0,0,.25); color-scheme: dark;
}

* { box-sizing: border-box; }
[hidden] { display: none !important; }
html, body { margin: 0; height: 100%; }
body { background: var(--bg); color: var(--text); font: 14px/1.5 var(--sans); -webkit-font-smoothing: antialiased; }
svg { width: 18px; height: 18px; fill: none; stroke: currentColor; stroke-width: 1.7; stroke-linecap: round; stroke-linejoin: round; flex: none; }
button, input, select, textarea { font: inherit; color: inherit; }
a { color: inherit; }

.app { display: grid; grid-template-columns: 236px 1fr; height: 100vh; }

/* sidebar */
.sidebar { background: var(--sidebar); border-right: 1px solid var(--border); display: flex; flex-direction: column; padding: 18px 12px; }
.brand { display: flex; align-items: center; gap: 10px; padding: 4px 10px 22px; }
.brand-mark { width: 28px; height: 28px; border-radius: 8px; background: var(--accent); color: #fff; display: grid; place-items: center; }
.brand-mark svg { width: 16px; height: 16px; stroke-width: 2.2; }
.brand-name { font-family: var(--serif); font-size: 19px; font-weight: 500; letter-spacing: -.01em; }
.nav { display: flex; flex-direction: column; gap: 2px; }
.nav a { display: flex; align-items: center; gap: 10px; padding: 8px 10px; border-radius: 8px; text-decoration: none; color: var(--text-2); }
.nav a:hover { background: color-mix(in srgb, var(--text) 5%, transparent); }
.nav a.active { background: var(--surface); color: var(--text); box-shadow: 0 0 0 1px var(--border); }
.nav a.active svg { color: var(--accent); }
.nav-badge { margin-left: auto; background: var(--accent); color: #fff; font-size: 11px; font-weight: 600; border-radius: 99px; padding: 0 7px; line-height: 18px; }
.sidebar-foot { margin-top: auto; display: flex; align-items: center; justify-content: space-between; gap: 8px; padding: 0 6px; }
.conn { font-size: 12px; color: var(--muted); display: flex; align-items: center; gap: 6px; }
.conn .dot { width: 7px; height: 7px; border-radius: 50%; background: var(--ok); }
.conn .dot.mock { background: var(--warn); }

/* main */
.main { overflow: auto; }
.page { max-width: 1180px; margin: 0 auto; padding: 36px 40px 64px; }
.page-head { display: flex; align-items: flex-end; justify-content: space-between; gap: 16px; margin-bottom: 24px; flex-wrap: wrap; }
h1 { font-family: var(--serif); font-weight: 500; font-size: 30px; letter-spacing: -.015em; margin: 0; }
h2 { font-family: var(--serif); font-weight: 500; font-size: 21px; margin: 0; letter-spacing: -.01em; }
h3 { font-size: 13px; font-weight: 600; margin: 0 0 10px; color: var(--text-2); }
.sub { color: var(--muted); margin: 4px 0 0; }
.eyebrow { font-size: 12px; color: var(--muted); }

.toolbar { display: flex; gap: 8px; align-items: center; flex-wrap: wrap; }
.seg { display: inline-flex; background: var(--surface-2); border: 1px solid var(--border); border-radius: 10px; padding: 3px; }
.seg button { border: 0; background: none; padding: 5px 11px; border-radius: 7px; cursor: pointer; color: var(--muted); }
.seg button.on { background: var(--surface); color: var(--text); box-shadow: 0 1px 2px rgba(0,0,0,.08); }

.input, .select, .textarea { background: var(--surface); border: 1px solid var(--border-strong); border-radius: 9px; padding: 7px 11px; outline: none; transition: border-color .15s, box-shadow .15s; }
.input:focus, .select:focus, .textarea:focus { border-color: var(--accent); box-shadow: 0 0 0 3px color-mix(in srgb, var(--accent) 20%, transparent); }
.textarea { width: 100%; resize: vertical; min-height: 90px; line-height: 1.5; }
.input.block { width: 100%; }
label.field { display: block; margin-bottom: 14px; }
label.field > span { display: block; font-size: 12.5px; font-weight: 500; color: var(--text-2); margin-bottom: 5px; }

.btn { display: inline-flex; align-items: center; gap: 7px; border: 1px solid var(--border-strong); background: var(--surface); padding: 7px 14px; border-radius: 9px; cursor: pointer; font-weight: 500; white-space: nowrap; text-decoration: none; }
.btn:hover { background: var(--surface-2); }
.btn.primary { background: var(--accent); border-color: var(--accent); color: #fff; }
.btn.primary:hover { background: var(--accent-hover); border-color: var(--accent-hover); }
.btn:disabled { opacity: .55; cursor: default; }
.btn svg { width: 16px; height: 16px; }
.icon-btn { border: 0; background: none; width: 32px; height: 32px; border-radius: 8px; display: grid; place-items: center; cursor: pointer; color: var(--muted); }
.icon-btn:hover { background: color-mix(in srgb, var(--text) 6%, transparent); color: var(--text); }

/* cards & stats */
.card { background: var(--surface); border: 1px solid var(--border); border-radius: 14px; }
.stats { display: grid; grid-template-columns: repeat(4, 1fr); gap: 12px; margin-bottom: 20px; }
.stat { padding: 16px 18px; }
.stat .label { font-size: 12.5px; color: var(--muted); }
.stat .value { font-family: var(--serif); font-size: 26px; font-weight: 500; margin-top: 2px; letter-spacing: -.01em; }
.stat .hint { font-size: 12px; color: var(--muted); }

/* tables */
.table-wrap { overflow-x: auto; }
table { width: 100%; border-collapse: collapse; }
th { text-align: left; font-weight: 500; font-size: 12px; color: var(--muted); padding: 11px 14px; border-bottom: 1px solid var(--border); white-space: nowrap; text-decoration: none; }
th.sortable { cursor: pointer; user-select: none; }
th.sortable:hover { color: var(--text); }
td { padding: 11px 14px; border-bottom: 1px solid var(--border); vertical-align: middle; }
tbody tr:last-child td { border-bottom: 0; }
tbody tr.clickable { cursor: pointer; }
tbody tr.clickable:hover { background: var(--surface-2); }
.num { text-align: right; font-variant-numeric: tabular-nums; white-space: nowrap; text-decoration: none; }
.mono { font-family: var(--mono); font-size: 12.5px; }
.muted { color: var(--muted); }
.truncate { max-width: 320px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; text-decoration: none; }
.table-foot { display: flex; justify-content: space-between; align-items: center; padding: 10px 14px; border-top: 1px solid var(--border); color: var(--muted); font-size: 13px; }

.pill { display: inline-flex; align-items: center; gap: 5px; font-size: 12px; font-weight: 500; padding: 1px 9px; border-radius: 99px; background: var(--surface-2); color: var(--text-2); border: 1px solid var(--border); white-space: nowrap; text-decoration: none; }
.pill.ok { background: var(--ok-soft); color: var(--ok); border-color: transparent; }
.pill.warn { background: var(--warn-soft); color: var(--warn); border-color: transparent; }
.pill.bad { background: var(--bad-soft); color: var(--bad); border-color: transparent; }
.pill.accent { background: var(--accent-soft); color: var(--accent-text); border-color: transparent; }

.empty { padding: 56px 20px; text-align: center; color: var(--muted); }
.empty h2 { color: var(--text); margin-bottom: 6px; }
.skeleton { height: 14px; border-radius: 6px; background: linear-gradient(90deg, var(--surface-2), var(--border), var(--surface-2)); background-size: 200% 100%; animation: sk 1.2s infinite; }
@keyframes sk { to { background-position: -200% 0; } }

/* lookup */
.lookup-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; margin-bottom: 24px; }
.lookup-card { padding: 20px; }
.lookup-card p { color: var(--muted); margin: 2px 0 14px; font-size: 13px; }
.inline-form { display: flex; gap: 8px; }
.inline-form .input { flex: 1; }

/* key/value */
.kv { display: grid; grid-template-columns: 150px 1fr; gap: 8px 16px; font-size: 13.5px; }
.kv dt { color: var(--muted); }
.kv dd { margin: 0; word-break: break-word; }
.section { padding: 18px 0; border-top: 1px solid var(--border); }
.section:first-child { border-top: 0; padding-top: 0; }
.result-card { padding: 22px; }

/* drawer */
.scrim { position: fixed; inset: 0; background: rgba(20,20,19,.28); z-index: 20; }
.drawer { position: fixed; top: 0; right: 0; bottom: 0; width: min(520px, 100vw); background: var(--bg); border-left: 1px solid var(--border); box-shadow: var(--shadow); z-index: 21; transform: translateX(100%); transition: transform .22s ease; display: flex; flex-direction: column; }
.drawer.open { transform: none; }
.drawer-head { display: flex; justify-content: space-between; align-items: flex-start; gap: 12px; padding: 22px 24px 14px; border-bottom: 1px solid var(--border); }
.drawer-body { padding: 20px 24px 40px; overflow: auto; flex: 1; }
.tabs { display: flex; gap: 4px; border-bottom: 1px solid var(--border); margin: -6px 0 18px; }
.tabs button { border: 0; background: none; padding: 8px 12px; cursor: pointer; color: var(--muted); border-bottom: 2px solid transparent; margin-bottom: -1px; }
.tabs button.on { color: var(--text); border-bottom-color: var(--accent); }
.form-actions { display: flex; gap: 8px; justify-content: flex-end; margin-top: 6px; }
.note { font-size: 12.5px; color: var(--muted); background: var(--surface-2); border: 1px solid var(--border); border-radius: 10px; padding: 10px 12px; margin-bottom: 16px; }

/* chats */
.chat-shell { display: grid; grid-template-columns: 330px 1fr; height: calc(100vh - 140px); min-height: 420px; overflow: hidden; }
.chat-list { border-right: 1px solid var(--border); display: flex; flex-direction: column; min-height: 0; }
.chat-list-head { padding: 12px; border-bottom: 1px solid var(--border); display: flex; gap: 8px; }
.chat-list-head .input { flex: 1; min-width: 0; }
.chat-items { overflow: auto; flex: 1; }
.chat-item { display: block; width: 100%; text-align: left; border: 0; background: none; padding: 12px 14px; border-bottom: 1px solid var(--border); cursor: pointer; }
.chat-item:hover { background: var(--surface-2); }
.chat-item.on { background: var(--accent-soft); }
.chat-item .row1 { display: flex; justify-content: space-between; gap: 8px; align-items: center; }
.chat-item .email { font-weight: 500; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; text-decoration: none; }
.chat-item .when { font-size: 11.5px; color: var(--muted); white-space: nowrap; text-decoration: none; }
.chat-item .prod { font-size: 12.5px; color: var(--muted); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; margin-top: 2px; }
.chat-item .unread { background: var(--accent); color: #fff; font-size: 11px; font-weight: 600; border-radius: 99px; padding: 0 7px; line-height: 18px; }
.thread { display: flex; flex-direction: column; min-height: 0; }
.thread-head { padding: 12px 18px; border-bottom: 1px solid var(--border); display: flex; justify-content: space-between; align-items: center; gap: 12px; }
.thread-head .who { font-weight: 500; }
.messages { flex: 1; overflow: auto; padding: 20px 22px; display: flex; flex-direction: column; gap: 14px; }
.msg { max-width: 76%; }
.msg .body { padding: 9px 14px; border-radius: 16px; white-space: pre-wrap; word-break: break-word; line-height: 1.5; }
.msg.buyer .body { background: var(--surface-2); border: 1px solid var(--border); border-bottom-left-radius: 6px; }
.msg.me { align-self: flex-end; }
.msg.me .body { background: var(--bubble-me); border-bottom-right-radius: 6px; }
.msg .meta { font-size: 11.5px; color: var(--muted); margin-top: 3px; padding: 0 6px; }
.msg.me .meta { text-align: right; }
.msg a { color: var(--accent-text); }
.composer { padding: 12px 16px 16px; }
.composer-box { border: 1px solid var(--border-strong); border-radius: 16px; background: var(--surface); padding: 10px 10px 10px 14px; display: flex; gap: 10px; align-items: flex-end; box-shadow: var(--shadow); }
.composer-box:focus-within { border-color: var(--accent); }
.composer textarea { flex: 1; border: 0; outline: none; background: none; resize: none; max-height: 180px; min-height: 22px; line-height: 1.5; padding: 4px 0; }
.send-btn { width: 34px; height: 34px; border-radius: 10px; border: 0; background: var(--accent); color: #fff; display: grid; place-items: center; cursor: pointer; }
.send-btn:disabled { opacity: .45; cursor: default; }
.send-btn svg { stroke-width: 2.2; }
.composer .hint { font-size: 11.5px; color: var(--muted); margin: 6px 4px 0; }

/* toasts */
.toasts { position: fixed; bottom: 20px; left: 50%; transform: translateX(-50%); display: flex; flex-direction: column; gap: 8px; z-index: 40; align-items: center; }
.toast { background: var(--text); color: var(--bg); padding: 9px 16px; border-radius: 10px; box-shadow: var(--shadow); font-size: 13.5px; animation: tin .2s ease; max-width: 90vw; }
.toast.err { background: var(--bad); color: #fff; }
@keyframes tin { from { opacity: 0; transform: translateY(6px); } }

/* responsive */
@media (max-width: 900px) {
  .app { grid-template-columns: 1fr; grid-template-rows: auto 1fr; }
  .sidebar { flex-direction: row; align-items: center; padding: 8px 12px; overflow-x: auto; border-right: 0; border-bottom: 1px solid var(--border); }
  .brand { padding: 0 10px 0 0; }
  .brand-name { display: none; }
  .nav { flex-direction: row; }
  .nav a { white-space: nowrap; text-decoration: none; }
  .sidebar-foot { margin: 0 0 0 auto; }
  .conn { display: none; }
  .page { padding: 22px 16px 48px; }
  .stats { grid-template-columns: repeat(2, 1fr); }
  .lookup-grid { grid-template-columns: 1fr; }
  .chat-shell { grid-template-columns: 1fr; height: calc(100vh - 150px); }
  .chat-shell.has-thread .chat-list { display: none; }
  .chat-shell:not(.has-thread) .thread { display: none; }
  .kv { grid-template-columns: 120px 1fr; }
}
@media (min-width: 761px) { .back-btn { display: none; } }
@media (min-width: 761px) { .m-only { display: none !important; } }

/* ---------- iPhone / phone layout ---------- */
@media (max-width: 760px) {
  html { -webkit-text-size-adjust: 100%; }
  body { -webkit-tap-highlight-color: transparent; overscroll-behavior-y: none; }
  /* let the page itself scroll so Safari's toolbars can collapse */
  .app { display: block; height: auto; min-height: 100dvh; }
  .main { overflow: visible; padding-top: env(safe-area-inset-top); padding-bottom: calc(64px + env(safe-area-inset-bottom)); }
  .page { padding: 18px 16px 28px; }
  .page-head { margin-bottom: 16px; gap: 12px; }
  .page-head > div:first-child { width: 100%; }
  h1 { font-size: 27px; }
  .sub { font-size: 13.5px; }

  /* bottom tab bar */
  .sidebar { position: fixed; left: 0; right: 0; bottom: 0; z-index: 10; flex-direction: row; padding: 4px 6px calc(4px + env(safe-area-inset-bottom)); border: 0; border-top: 1px solid var(--border); background: color-mix(in srgb, var(--sidebar) 88%, transparent); -webkit-backdrop-filter: saturate(1.6) blur(18px); backdrop-filter: saturate(1.6) blur(18px); overflow: visible; }
  .brand, .sidebar-foot { display: none; }
  .nav { flex-direction: row; width: 100%; gap: 0; }
  .nav a { flex: 1; flex-direction: column; gap: 2px; padding: 6px 2px 4px; min-height: 52px; justify-content: center; font-size: 10.5px; font-weight: 500; color: var(--muted); border-radius: 10px; position: relative; white-space: nowrap; }
  .nav a svg { width: 23px; height: 23px; }
  .nav a.active { background: none; box-shadow: none; color: var(--accent-text); }
  .nav a.active svg { color: var(--accent); }
  .nav a:hover { background: none; }
  .nav-badge { position: absolute; top: 3px; left: calc(50% + 6px); margin: 0; font-size: 10px; line-height: 16px; padding: 0 5px; }

  /* touch-friendly controls; 16px inputs stop iOS from zooming on focus */
  .input, .select, .textarea, .composer textarea { font-size: 16px; }
  .input, .select { min-height: 42px; }
  .btn { min-height: 42px; padding: 9px 16px; justify-content: center; }
  .icon-btn { width: 40px; height: 40px; }
  .toolbar { width: 100%; }
  .toolbar > .input, .toolbar > .select { flex: 1; min-width: 0; }
  .seg { width: 100%; }
  .seg button { flex: 1; padding: 8px 6px; font-size: 13.5px; }
  #custom { display: flex; gap: 8px; align-items: center; }
  #custom .input { flex: 1; min-width: 0; }
  #products-tools .input { flex-basis: 100%; }

  /* stats */
  .stats { grid-template-columns: 1fr 1fr; gap: 10px; margin-bottom: 16px; }
  .stat { padding: 12px 14px; border-radius: 12px; }
  .stat .value { font-size: 21px; }

  /* tables become tappable cards */
  .card { border-radius: 14px; }
  .table-wrap { overflow: visible; }
  table, tbody { display: block; }
  thead { display: none; }
  tbody tr { display: grid; gap: 2px 12px; padding: 12px 14px; border-bottom: 1px solid var(--border); align-items: baseline; }
  tbody tr:last-child { border-bottom: 0; }
  tbody tr.clickable:active { background: var(--surface-2); }
  td { padding: 0; border: 0; display: block; min-width: 0; }
  td:empty { display: none; }
  .truncate { max-width: none !important; }
  tbody tr td[colspan] { grid-column: 1 / -1; }
  tbody tr:not([class]) td:nth-child(n+3) { display: none; } /* loading skeletons: 2 lines per card */

  .sales-row { grid-template-columns: 1fr auto; grid-template-areas: "prod paid" "date net" "buyer method"; }
  .sales-row .c-prod { grid-area: prod; font-weight: 500; }
  .sales-row .c-paid { grid-area: paid; font-weight: 500; }
  .sales-row .c-date { grid-area: date; font-size: 12.5px; }
  .sales-row .c-net { grid-area: net; font-size: 12.5px; color: var(--muted); }
  .sales-row .c-net::before { content: "net "; }
  .sales-row .c-buyer { grid-area: buyer; font-size: 12.5px; color: var(--muted); }
  .sales-row .c-method { grid-area: method; font-size: 12.5px; text-align: right; }
  .sales-row .c-order { display: none; }

  .prod-row { grid-template-columns: 1fr auto; grid-template-areas: "name price" "meta stock"; }
  .prod-row .c-name { grid-area: name; }
  .prod-row .c-price { grid-area: price; font-weight: 500; }
  .prod-row .c-stock { grid-area: stock; font-size: 12.5px; }
  .prod-row .c-meta { grid-area: meta; font-size: 12.5px; color: var(--muted); display: flex; gap: 10px; flex-wrap: wrap; align-items: center; }
  .prod-row .c-id, .prod-row .c-sold, .prod-row .c-rev, .prod-row .c-flag { display: none; }

  .table-foot { flex-wrap: wrap; gap: 10px; padding: 12px 14px; }
  .table-foot .toolbar { width: 100%; }
  .table-foot .btn { flex: 1; }

  /* lookup */
  .lookup-grid { gap: 12px; margin-bottom: 16px; }
  .lookup-card { padding: 16px; }
  .result-card { padding: 16px; }
  .kv { grid-template-columns: 110px 1fr; gap: 7px 12px; font-size: 14px; }

  /* drawer becomes a bottom sheet */
  .drawer { top: calc(env(safe-area-inset-top) + 28px); width: 100%; border-left: 0; border-radius: 18px 18px 0 0; transform: translateY(105%); transition: transform .28s cubic-bezier(.2,.8,.2,1); }
  .drawer::before { content: ""; position: absolute; top: 7px; left: 50%; width: 38px; height: 5px; margin-left: -19px; border-radius: 3px; background: var(--border-strong); }
  .drawer-head { padding: 22px 16px 12px; }
  .drawer-body { padding: 16px 16px calc(28px + env(safe-area-inset-bottom)); -webkit-overflow-scrolling: touch; overscroll-behavior: contain; }
  .tabs button { flex: 1; padding: 10px 6px; }
  .form-actions .btn { flex: 1; }
  .scrim { background: rgba(20,20,19,.38); }

  /* chats: list in the page, thread opens full screen */
  .chat-shell { display: block; height: auto; min-height: 0; overflow: visible; }
  .chat-list { border-right: 0; }
  .chat-list-head { position: sticky; top: env(safe-area-inset-top); background: var(--surface); z-index: 2; border-radius: 14px 14px 0 0; flex-wrap: wrap; }
  .chat-list-head .input { flex-basis: 100%; }
  .chat-list-head .seg { width: 100%; }
  .chat-items { overflow: visible; }
  .chat-item { padding: 13px 14px; }
  .chat-item:hover, tbody tr.clickable:hover { background: none; } /* no sticky hover after a tap */
  .chat-item:active { background: var(--surface-2); }
  .chat-item:last-child { border-bottom: 0; }
  .chat-shell:not(.has-thread) .thread { display: none; }
  .chat-shell.has-thread .chat-list { display: block; }
  .chat-shell.has-thread .thread {
    position: fixed; left: 0; right: 0; top: var(--vv-top, 0px); height: var(--vv-height, 100dvh); z-index: 15; /* above tab bar, below sheets */
    background: var(--bg); padding-top: env(safe-area-inset-top);
  }
  .thread-head { padding: 6px 10px 8px 4px; gap: 8px; background: color-mix(in srgb, var(--bg) 92%, transparent); }
  .thread-head .btn { min-height: 36px; padding: 6px 12px; font-size: 13px; }
  .messages { padding: 14px 12px; overscroll-behavior: contain; -webkit-overflow-scrolling: touch; }
  .msg { max-width: 84%; }
  .composer { padding: 8px 10px calc(8px + env(safe-area-inset-bottom)); }
  .keyboard-open .composer { padding-bottom: 8px; }
  .composer-box { border-radius: 22px; padding: 6px 6px 6px 14px; box-shadow: none; }
  .composer .hint { display: none; }
  .send-btn { width: 34px; height: 34px; border-radius: 50%; }
  body.thread-open { overflow: hidden; }

  .toasts { bottom: calc(76px + env(safe-area-inset-bottom)); width: calc(100% - 32px); }
  .toast { text-align: center; }
}
