/* =====================================================================
   TengoFeed Talk, assets/talk/css/talk.css
   The design system. Every value here comes from the approved mockups;
   feature stylesheets build on these classes rather than inventing
   their own greys, radii or type sizes.

   v93, formal: black at night, white by day, the same for the app and
   the pages around it (html data-theme, settled before the first paint by
   au_theme_head()). The logo's purple is in the bars (the top bar and the
   bottom bar are frosted purple by day, frosted black at night) and in
   the few things that are yours: your messages, the counts waiting for
   you. Buttons are flat with a small radius: black on white by day, white
   on black at night. Type is Instrument Sans.

   v94, glass: the bars are frosted, semi-transparent glass (--bar,
   --bar-fx, --bar-sheen), and a main page's header stays at the top of
   its list so the list passes under it, blurred.
   ===================================================================== */

@font-face {
  font-family: 'Instrument Sans';
  src: url('/assets/talk/fonts/InstrumentSans-Variable.woff2') format('woff2');
  font-weight: 400 700; font-style: normal; font-display: swap;
}
@font-face {
  font-family: 'Instrument Sans';
  src: url('/assets/talk/fonts/InstrumentSans-Italic-Variable.woff2') format('woff2');
  font-weight: 400 700; font-style: italic; font-display: swap;
}
@font-face {
  font-family: 'Geist Mono';
  src: url('/assets/talk/fonts/GeistMono-Variable.woff2') format('woff2');
  font-weight: 100 900; font-style: normal; font-display: swap;
}

/* ---------------------------------------------------------------- night: black */
:root {
  --bg: #0E0A1C;
  --s1: #1C1634;
  --s2: #272046;
  --s3: #32295A;
  --line: #221B3F;
  --line2: #332A57;
  --ink1: #FFFFFF;
  --ink2: #C8C2E8;
  --ink3: #8C85B0;
  --ink4: #625B88;
  /* the logo's purple, lit for the dark: links, counts, the switch that is on */
  --acc: #A39BFF;
  --acc-hover: #BCB6FF;
  --acc-ink: #A39BFF;
  --on-acc: #0E0A1C;
  --acc-tint: rgba(163, 155, 255, .14);
  --acc-tint2: rgba(163, 155, 255, .28);
  --brand: #453F84;
  --brand-2: #5A52A8;
  --brand-3: #6E66BE;
  --on-brand: #FFFFFF;
  --brand-tint: rgba(110, 102, 190, .22);
  /* your messages */
  --me: #5A52A8;
  --me-ink: #FFFFFF;
  --live: #FF3B5C;
  --ok: #4FD39A;
  --bad: #FF6B6B;
  --scrim: rgba(8, 5, 18, .74);
  /* buttons (v103): the main one the logo's lilac, the others a quiet violet fill */
  --pri: #A39BFF; --pri-ink: #0E0A1C; --pri-hover: #BCB6FF;
  --sec: #1C1634; --sec-ink: #FFFFFF; --sec-line: #332A57; --sec-hover: #272046;
  --field: #1C1634;
  /* the bars: frosted black glass (v94: lighter, so what passes under them shows through, blurred) */
  --bar: rgba(22, 17, 41, .78); --bar-solid: #161129; --bar-line: rgba(255, 255, 255, .1);
  --bar-fx: blur(24px) saturate(180%);
  --bar-flat: #161129;
  --bar-sheen: linear-gradient(180deg, rgba(255, 255, 255, .06), rgba(255, 255, 255, 0) 70%);
  --bar-ink: #FFFFFF; --bar-ink2: rgba(255, 255, 255, .72); --bar-btn: rgba(255, 255, 255, .08); --bar-btn-line: rgba(255, 255, 255, .14); --bar-on: rgba(163, 155, 255, .16);
  --bar-shadow: 0 16px 40px rgba(0, 0, 0, .5);
  /* faint washes over the page (a row under the pointer, a quiet tile) */
  --wash: rgba(255, 255, 255, .035); --wash2: rgba(255, 255, 255, .065); --wash3: rgba(255, 255, 255, .1);
  /* people without a photo: a quiet circle with their initials */
  --av-bg: #272046; --av-ink: #E4DEFF;
  --tone-0: #3A2A22; --tone-1: #1F2B33; --tone-2: #2F2433; --tone-3: #26301F; --tone-4: #33291F; --tone-5: #1E2430; --tone-6: #2E2227; --tone-7: #2B3A2A; --tone-8: #3A2418; --tone-9: #22262D; --tone-10: #302329; --tone-11: #23302B; --tone-12: #1E2A3A; --tone-13: #2A2331;
  --sheet: #161129;
  --pg-ink1: #FFFFFF; --pg-ink2: #C8C2E8; --pg-ink3: #8C85B0; --pg-ink4: #625B88; --pg-s1: #1C1634; --pg-s2: #272046; --pg-line: #221B3F; --pg-line2: #332A57; --pg-acc: #A39BFF; --pg-sheet: #1C1634; --pg-wash: rgba(255, 255, 255, .05);
  /* what went wrong, what went right */
  --bad-bg: #2A1212; --bad-line: #4A2220; --bad-ink: #FFD9D5; --ok-bg: #12241B; --ok-ink: #7FD8AE;
  --lift: 0 24px 60px rgba(0, 0, 0, .65), 0 0 0 1px rgba(255, 255, 255, .08);
  --shadow: 0 10px 30px rgba(0, 0, 0, .5);
  --font: 'Instrument Sans', ui-sans-serif, system-ui, -apple-system, 'Segoe UI', Roboto, sans-serif;
  /* v90: small print is set in the same face as everything else (even-width
     figures where numbers line up); only codes people copy stay monospaced. */
  --mono: var(--font);
  --code: 'Geist Mono', ui-monospace, 'SF Mono', Menlo, monospace;
  /* glass: menus and panels that float over the page. A lite phone (chrome.js) gets them solid. */
  --glass: rgba(28, 22, 52, .86);
  --glass-2: rgba(34, 27, 62, .94);
  --glass-line: rgba(255, 255, 255, .08);
  --glass-hi: rgba(255, 255, 255, .06);
  --glass-blur: blur(22px) saturate(160%);
  --glass-shadow: 0 18px 46px rgba(0, 0, 0, .6), 0 2px 8px rgba(0, 0, 0, .4);
  --r-btn: 14px;
  --island-h: 68px;
  --island-gap: 12px;
  --spring: cubic-bezier(.3, 1.25, .45, 1);
  --glide: cubic-bezier(.22, 1, .36, 1);
  /* what the island takes at the bottom of a page: toasts and sheets float above it */
  --tabbar-h: calc(var(--island-h) + var(--island-gap));
  /* the Android app (3.2) passes its own gesture bar here, env() elsewhere */
  --safe-b: max(env(safe-area-inset-bottom, 0px), var(--app-safe-b, 0px));
  --safe-t: env(safe-area-inset-top, 0px);
  --ease: cubic-bezier(.2, .7, .2, 1);
  color-scheme: dark;
}
/* ---------------------------------------------------------------- day: white */
html[data-theme="day"] {
  --bg: #FFFFFF;
  --s1: #F3F1FC;
  --s2: #E9E5FA;
  --s3: #DDD7F5;
  --line: #ECE9F7;
  --line2: #DCD7F0;
  --ink1: #120E24;
  --ink2: #4A4566;
  --ink3: #6E6890;
  --ink4: #A39EBC;
  --acc: #5A52A8;
  --acc-hover: #453F84;
  --acc-ink: #5A52A8;
  --on-acc: #FFFFFF;
  --acc-tint: rgba(90, 82, 168, .12);
  --acc-tint2: rgba(90, 82, 168, .22);
  --brand-tint: rgba(90, 82, 168, .1);
  --me: #5A52A8;
  --live: #D61F45;
  --ok: #15835A;
  --bad: #C8322B;
  --scrim: rgba(18, 14, 36, .42);
  /* v96: the main buttons are the logo's purple by day, never black */
  --pri: #5A52A8; --pri-ink: #FFFFFF; --pri-hover: #453F84;
  --sec: #F3F1FC; --sec-ink: #120E24; --sec-line: #E9E5FA; --sec-hover: #E9E5FA;
  --field: #F3F1FC;
  /* the bars (v103): frosted white glass by day, the page's own ink on it */
  --bar: rgba(255, 255, 255, .86); --bar-solid: #FFFFFF; --bar-line: rgba(18, 14, 36, .1);
  --bar-sheen: none;
  --bar-flat: #FFFFFF;
  --bar-ink: #120E24; --bar-ink2: rgba(18, 14, 36, .72); --bar-btn: rgba(18, 14, 36, .06); --bar-btn-line: rgba(18, 14, 36, .1); --bar-on: rgba(90, 82, 168, .12);
  --bar-shadow: 0 12px 32px rgba(40, 30, 90, .16);
  --wash: rgba(18, 14, 36, .03); --wash2: rgba(18, 14, 36, .055); --wash3: rgba(18, 14, 36, .085);
  --av-bg: #E9E5FA; --av-ink: #4A4566;
  --tone-0: #F1E3DD; --tone-1: #DDE9F1; --tone-2: #EADFEE; --tone-3: #E5F0DE; --tone-4: #F1E7DD; --tone-5: #DDE4F0; --tone-6: #EEE0E6; --tone-7: #E1EEE0; --tone-8: #F1E4DD; --tone-9: #E0E5ED; --tone-10: #EEE0E6; --tone-11: #E0EEE8; --tone-12: #DDE5F1; --tone-13: #E7DFEE;
  --sheet: #FFFFFF;
  --pg-ink1: #120E24; --pg-ink2: #4A4566; --pg-ink3: #6E6890; --pg-ink4: #A39EBC; --pg-s1: #F3F1FC; --pg-s2: #E9E5FA; --pg-line: #ECE9F7; --pg-line2: #DCD7F0; --pg-acc: #5A52A8; --pg-sheet: #FFFFFF; --pg-wash: rgba(18, 14, 36, .04);
  --bad-bg: #FDEDEB; --bad-line: #F6C9C3; --bad-ink: #7F1D16; --ok-bg: #E7F5EE; --ok-ink: #14663F;
  --lift: 0 24px 60px rgba(20, 18, 50, .14), 0 2px 8px rgba(20, 18, 50, .06), 0 0 0 1px rgba(10, 10, 20, .06);
  --shadow: 0 10px 30px rgba(20, 18, 50, .14);
  --glass: rgba(255, 255, 255, .88);
  --glass-2: rgba(255, 255, 255, .95);
  --glass-line: rgba(18, 14, 36, .08);
  --glass-hi: rgba(255, 255, 255, .9);
  --glass-shadow: 0 18px 46px rgba(20, 18, 50, .16), 0 2px 8px rgba(20, 18, 50, .08);
  color-scheme: light;
}
html.t-lite { --glass: #1C1634; --glass-2: #221B3F; --glass-blur: none; --bar: var(--bar-solid); --bar-fx: none; --bar-sheen: none; }
html.t-lite[data-theme="day"] { --glass: #FFFFFF; --glass-2: #FFFFFF; }

/* Inside a bar (v103): a bar is the page's own glass now, white by day and deep violet at night,
   so its words, fills and buttons are the page's. A face keeps its online dot cut out of the bar. */
:is(.t-onbar, .t-island, .t-fab, .t-rhead, .t-bar, .t-bighead, .yu-head, .bz-head, .st-top, .gi-bar, .wq-bar, .wc-bar, .au .au-top) { color: var(--ink1); }
:is(.t-onbar, .t-rhead, .t-bar, .t-bighead, .yu-head, .bz-head, .st-top, .gi-bar, .wq-bar, .wc-bar) .t-av-dot { border-color: var(--bar-solid); }
/* The pages around the app (the home page, signing in and up, a public post or business page) keep a bar in the
   brand's purple by day, with white words on it: their mark and their buttons are drawn for a dark bar. */
html[data-theme="day"] :is(.au .au-top, .au .lx-sticky, .wp-top, .brd-login-top) {
  --bar: rgba(90, 82, 168, .92); --bar-solid: #5A52A8; --bar-flat: #5A52A8; --bar-line: rgba(255, 255, 255, .14);
  --bar-ink: #FFFFFF; --bar-ink2: rgba(255, 255, 255, .82); --bar-btn: rgba(255, 255, 255, .14); --bar-btn-line: rgba(255, 255, 255, .2);
  color: #FFFFFF;
}
/* the top bar of every other page, whichever screen draws it (settings, a profile, a business, a stage) */
.yu-head, .bz-head, .st-top, .gi-bar, .wq-bar, .wc-bar { position: relative; z-index: 3; background: var(--bar-sheen), var(--bar); -webkit-backdrop-filter: var(--bar-fx); backdrop-filter: var(--bar-fx); box-shadow: inset 0 -1px 0 var(--bar-line); }
/* and a panel that opens out of a bar (a menu) is the page's again */
.t-onpage, .au .au-th-menu {
  --ink1: var(--pg-ink1); --ink2: var(--pg-ink2); --ink3: var(--pg-ink3); --ink4: var(--pg-ink4);
  --s1: var(--pg-s1); --s2: var(--pg-s2); --line: var(--pg-line); --line2: var(--pg-line2);
  --acc: var(--pg-acc); --acc-ink: var(--pg-acc); --wash: var(--pg-wash);
  color: var(--ink1);
}

*, *::before, *::after { box-sizing: border-box; }
html, body { margin: 0; height: 100%; background: var(--bg); }
body {
  color: var(--ink1); font-family: var(--font); font-size: 15px; line-height: 1.42;
  letter-spacing: -0.003em; -webkit-font-smoothing: antialiased; -moz-osx-font-smoothing: grayscale;
  -webkit-tap-highlight-color: transparent; overscroll-behavior: none;
}
button, input, textarea, select { font: inherit; color: inherit; }
button { cursor: pointer; }
a { color: var(--acc); }
a:hover { color: var(--acc-hover); }
img { display: block; max-width: 100%; }
[hidden] { display: none !important; }
input::placeholder, textarea::placeholder { color: var(--ink3); }
:focus-visible { outline: 2px solid var(--brand-3); outline-offset: 2px; border-radius: 8px; }
.sr { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.mono { font-family: var(--mono); font-variant-numeric: tabular-nums; }
.svg { display: block; flex-shrink: 0; }
::selection { background: var(--acc-tint2); color: var(--ink1); }

/* ---------------------------------------------------------------- shell */
#app { position: fixed; inset: 0; display: flex; flex-direction: column; background: var(--bg); }
.t-panes { flex: 1; min-height: 0; display: flex; }
.t-pane { flex: 1; min-width: 0; min-height: 0; display: flex; flex-direction: column; position: relative; }
.t-pane.master { display: none; }
.t-screen { flex: 1; min-height: 0; display: flex; flex-direction: column; position: relative; background: var(--bg); }
.t-scroll { flex: 1; min-height: 0; overflow-y: auto; overflow-x: hidden; -webkit-overflow-scrolling: touch; overscroll-behavior: contain; }
.t-scroll::-webkit-scrollbar { width: 8px; }
.t-scroll::-webkit-scrollbar-thumb { background: var(--s3); border-radius: 8px; }
.t-grow { flex-grow: 1; }
.t-row-flex { display: flex; align-items: center; gap: 10px; }

/* Wide screens: tabs become a rail on the left, and a list keeps its
   place beside whatever was opened from it. */
@media (min-width: 900px) {
  #app { flex-direction: row-reverse; }
  .t-panes { max-width: 1200px; margin: 0 auto; width: 100%; border-left: 1px solid var(--line); border-right: 1px solid var(--line); }
  .t-pane.master:not(:empty) { display: flex; flex: 0 0 400px; border-right: 1px solid var(--line); }
  .t-pane.master:not(:empty) + .t-pane.detail .t-back { visibility: hidden; }
}

/* ---------------------------------------------------------------- the island (v90)
   The four main pages in a floating pill of frosted glass at the bottom
   of a phone, with a light behind the one you are on (app.js placeBlob).
   On a wide screen it stands up on the left as a rail. Every other page
   is the whole screen: the island slides away under it. */
.t-island {
  position: fixed; z-index: 50; left: 0; right: 0; bottom: calc(var(--island-gap) + var(--safe-b)); margin: 0 auto;
  width: min(420px, calc(100vw - 2 * var(--island-gap))); height: var(--island-h);
  display: flex; align-items: stretch; padding: 6px; border-radius: calc(var(--island-h) / 2);
  background: var(--bar-sheen), var(--bar); -webkit-backdrop-filter: var(--bar-fx); backdrop-filter: var(--bar-fx);
  box-shadow: var(--bar-shadow), inset 0 0 0 1px var(--bar-line);
  transition: transform .42s var(--glide), opacity .28s var(--glide), visibility 0s;
  view-transition-name: t-island;
}
/* With the page's action bubble beside it, the island keeps to the left. */
body.t-hasfab .t-island { left: var(--island-gap); right: auto; margin: 0; width: min(372px, calc(100vw - 3 * var(--island-gap) - var(--island-h))); }
.t-island.hide {
  transform: translateY(calc(100% + var(--island-gap) + var(--safe-b) + 16px)); opacity: 0; visibility: hidden;
  transition: transform .34s var(--glide), opacity .22s var(--glide), visibility 0s linear .34s;
}
.t-isl-blob {
  position: absolute; left: 0; top: 6px; bottom: 6px; width: 25%; z-index: 0; border-radius: 27px; opacity: 0; pointer-events: none;
  background: var(--bar-on);
  transition: opacity .25s var(--glide);
}
.t-isl-blob.on { opacity: 1; }
.t-tab {
  flex: 1 1 0; min-width: 0; position: relative; z-index: 1; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 3px;
  padding: 0; border-radius: 27px; text-decoration: none; color: var(--ink3); background: none; border: 0;
  transition: color .22s var(--glide), transform .2s var(--spring);
}
.t-tab:hover { color: var(--ink2); }
.t-tab:active { transform: scale(.93); }
.t-tab.on { color: var(--acc); }
.t-tab .svg { transition: color .22s var(--glide), filter .22s var(--glide); }
.t-tab.on .svg { color: var(--acc); stroke-width: 2; }
.t-tab-ic { position: relative; display: flex; }
.t-tab-label { font-size: 11.5px; font-weight: 620; letter-spacing: .005em; max-width: 100%; padding: 0 2px; overflow: hidden; white-space: nowrap; text-overflow: ellipsis; }
.t-tab-label.tight { font-size: 9.5px; letter-spacing: -0.02em; padding: 0 1px; }
.t-tab-badge {
  position: absolute; top: -6px; left: 14px; min-width: 17px; height: 17px; padding: 0 5px; border-radius: 9px;
  background: var(--acc); color: var(--on-acc); font-family: var(--mono); font-variant-numeric: tabular-nums; font-size: 10px; font-weight: 650;
  display: inline-flex; align-items: center; justify-content: center; box-shadow: 0 0 0 2px var(--bar-solid);
}
/* new posts in World: a dot, no number */
.t-tab-badge.dot { min-width: 0; width: 9px; height: 9px; padding: 0; top: -1px; left: 20px; border-radius: 50%; }
@media (max-width: 899px) {
  /* The island floats over the page: the end of a main page's list scrolls clear of it. */
  body.t-root .t-pane.detail .t-scroll::after { content: ''; display: block; flex-shrink: 0; height: calc(var(--island-h) + 2 * var(--island-gap) + var(--safe-b) + 6px); }
}
@media (min-width: 900px) {
  .t-island {
    position: relative; left: auto; right: auto; bottom: auto; margin: 0 14px; align-self: center; flex-direction: column; flex-shrink: 0;
    width: 76px; height: auto; padding: 8px 6px; border-radius: 38px; gap: 4px;
  }
  .t-island.hide { transform: none; opacity: 1; visibility: visible; }
  .t-tab { flex: 0 0 auto; height: 64px; }
  .t-isl-blob { left: 6px; right: 6px; top: 0; bottom: auto; width: auto; height: 64px; }
}

/* the page's main action, beside the island (chrome.js fab) */
.t-fab {
  position: fixed; z-index: 51; right: var(--island-gap); bottom: calc(var(--island-gap) + var(--safe-b));
  width: var(--island-h); height: var(--island-h); border-radius: 50%; border: 0; padding: 0; overflow: hidden; isolation: isolate;
  display: flex; align-items: center; justify-content: center; text-decoration: none; color: #FFFFFF;
  background: var(--bar-sheen), var(--bar); -webkit-backdrop-filter: var(--bar-fx); backdrop-filter: var(--bar-fx);
  box-shadow: var(--bar-shadow), inset 0 0 0 1px var(--bar-line);
  transition: transform .32s var(--spring), box-shadow .25s var(--glide);
  view-transition-name: t-fab;
}
.t-fab:hover { color: #FFFFFF; background: var(--bar-solid); }
.t-fab:active { transform: scale(.9); }
.t-fab .svg { position: relative; z-index: 1; }
.t-fab.live { background: var(--live); color: #fff; }
.t-fab-glow { display: none; }
body.t-inner .t-fab { display: none; }
@media (min-width: 900px) { .t-fab { display: none; } }

/* ---------------------------------------------------------------- headers */
.t-bighead { display: flex; align-items: center; justify-content: space-between; padding: calc(14px + var(--safe-t)) 10px 10px 20px; flex-shrink: 0; background: var(--bar-sheen), var(--bar); -webkit-backdrop-filter: var(--bar-fx); backdrop-filter: var(--bar-fx); box-shadow: inset 0 -1px 0 var(--bar-line); }
.t-bighead h1 { margin: 0; font-size: 30px; line-height: 1.1; font-weight: 600; letter-spacing: -0.035em; color: var(--ink1); }
.t-actions { display: flex; gap: 2px; align-items: center; }
.t-bar {
  display: flex; align-items: center; gap: 6px; padding: calc(8px + var(--safe-t)) 6px 8px 4px;
  flex-shrink: 0; min-height: 60px; background: var(--bar-sheen), var(--bar); -webkit-backdrop-filter: var(--bar-fx); backdrop-filter: var(--bar-fx);
  box-shadow: inset 0 -1px 0 var(--bar-line); position: relative; z-index: 3;
}
.t-bar-title { flex-grow: 1; min-width: 0; padding-left: 4px; }
.t-bar-name { font-size: 16px; font-weight: 600; letter-spacing: -0.015em; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.t-bar-sub { font-size: 12px; color: var(--ink3); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.t-bar-sub.ok { color: var(--ok); }
.t-bar-sub.acc { color: var(--acc); }
.t-bar a.t-bar-who { display: flex; align-items: center; gap: 10px; flex-grow: 1; min-width: 0; text-decoration: none; color: inherit; }

/* ---------------------------------------------------------------- buttons */
.t-ib {
  width: 44px; height: 44px; display: flex; align-items: center; justify-content: center; flex-shrink: 0;
  background: none; border: 0; padding: 0; color: var(--ink2); border-radius: var(--r-btn); text-decoration: none;
  transition: background-color .15s var(--ease), color .15s var(--ease), transform .12s var(--ease);
}
.t-ib:hover { background: var(--wash2); color: var(--ink1); }
.t-ib:active { transform: scale(.92); }
.t-ib.ink1 { color: var(--ink1); }
.t-ib.sm { width: 36px; height: 36px; }
/* the way back from any page opened from a tab, top left */
.t-ib.t-arrow { color: var(--ink1); }
.t-ib.t-arrow .svg { stroke-width: 2.2; }
.t-ib.t-arrow:hover { color: var(--ink1); background: var(--wash2); }
.t-ib[disabled] { opacity: .4; pointer-events: none; }

/* v93: one shape for every button, flat with a small radius. The main one (.acc) is solid:
   black on white by day, white on black at night. The rest are quiet with a line.
   .hot (gifts, going live, money) is the logo's purple. */
.t-btn {
  height: 36px; padding: 0 14px; border-radius: var(--r-btn); border: 1px solid var(--sec-line); background: var(--sec); color: var(--sec-ink);
  font-size: 13.5px; font-weight: 550; display: inline-flex; align-items: center; justify-content: center; gap: 7px;
  text-decoration: none; flex-shrink: 0; letter-spacing: -0.005em; white-space: nowrap;
  transition: background-color .15s var(--ease), border-color .15s var(--ease), transform .12s var(--ease), opacity .15s;
}
.t-btn:hover { background: var(--sec-hover); color: var(--sec-ink); border-color: var(--sec-line); }
.t-btn:active { transform: scale(.98); }
.t-btn.lg { height: 48px; padding: 0 20px; font-size: 15px; }
.t-btn.md { height: 40px; padding: 0 16px; font-size: 14px; }
.t-btn.block { width: 100%; }
.t-btn.acc { border-color: transparent; background: var(--pri); color: var(--pri-ink); }
.t-btn.acc:hover { background: var(--pri-hover); color: var(--pri-ink); }
.t-btn.hot { border-color: transparent; background: var(--acc); color: var(--on-acc); }
.t-btn.hot:hover { background: var(--acc-hover); color: var(--on-acc); }
.t-btn.danger { color: var(--bad); }
.t-btn.quiet { border-color: transparent; background: none; color: var(--ink3); padding: 0 4px; }
.t-btn.quiet:hover { background: none; color: var(--ink1); }
.t-btn[disabled], .t-btn.busy { opacity: .5; pointer-events: none; }
.t-textbtn { background: none; border: 0; color: var(--acc); font-size: 15px; font-weight: 600; height: 44px; padding: 0 8px; }
.t-textbtn.ink { color: var(--ink2); font-size: 13px; display: inline-flex; align-items: center; gap: 6px; height: 36px; }

/* ---------------------------------------------------------------- avatars */
.t-av { position: relative; flex-shrink: 0; }
.t-av-face {
  border-radius: 50%; background: var(--av-bg); color: var(--av-ink); display: flex; align-items: center; justify-content: center;
  font-weight: 600; letter-spacing: -0.01em; box-shadow: inset 0 0 0 1px var(--wash2); overflow: hidden;
  background-size: cover; background-position: center;
}
.t-av.sq .t-av-face { border-radius: 30%; }
.t-av-ring { padding: 2px; border-radius: 50%; border: 2px solid var(--acc); }
.t-av-ring.seen { border-color: var(--line2); }
.t-av-dot { position: absolute; right: 0; bottom: 0; border-radius: 50%; background: var(--ok); border: 2px solid var(--bg); }
.t-glyph { border-radius: 50%; flex-shrink: 0; display: flex; align-items: center; justify-content: center; box-shadow: inset 0 0 0 1px var(--wash2); color: var(--av-ink); }
.t-stack { display: flex; flex-shrink: 0; }
.t-stack > * + * { margin-left: -9px; }
.t-stack .t-av-face { box-shadow: 0 0 0 2px var(--s1); }

/* ---------------------------------------------------------------- small type */
.t-micro { font-size: 13px; font-weight: 600; letter-spacing: -0.005em; color: var(--ink2); }
.t-micro.acc { color: var(--acc); }
.t-sec { padding: 18px 20px 8px; }
.t-meta { font-family: var(--mono); font-variant-numeric: tabular-nums; font-size: 10.5px; color: var(--ink3); padding: 4px 4px 0; display: flex; align-items: center; gap: 5px; }
.t-time { font-family: var(--mono); font-variant-numeric: tabular-nums; font-size: 11.5px; color: var(--ink3); flex-shrink: 0; }
.t-time.acc { color: var(--acc); }
.t-tag { font-size: 11px; font-weight: 550; color: var(--ink2); border: 1px solid var(--line2); border-radius: 6px; padding: 1px 6px; }
.t-tag.acc { color: var(--acc); background: var(--acc-tint); border-color: var(--acc-tint); }
.t-rtag { display: inline-flex; align-items: center; gap: 4px; font-size: 11.5px; font-weight: 600; color: var(--acc); flex-shrink: 0; }
.t-rtag.dim { color: var(--ink3); }
.t-badge {
  min-width: 20px; height: 20px; padding: 0 6px; border-radius: 10px; background: var(--acc); color: var(--on-acc);
  font-family: var(--mono); font-variant-numeric: tabular-nums; font-size: 11px; font-weight: 600; display: inline-flex; align-items: center; justify-content: center; flex-shrink: 0;
}
.t-badge.at { width: 20px; padding: 0; font-family: var(--font); font-size: 12px; font-weight: 700; }
.t-help { font-size: 12.5px; color: var(--ink3); margin-top: 2px; line-height: 1.4; }

/* ---------------------------------------------------------------- search */
.t-search { display: flex; align-items: center; gap: 10px; margin: 8px 20px 2px; padding: 11px 0; border-bottom: 1px solid var(--line2); color: var(--ink3); flex-shrink: 0; }
.t-search:focus-within { border-bottom-color: var(--ink2); }
.t-search input { flex-grow: 1; min-width: 0; background: none; border: 0; outline: none; color: var(--ink1); font-size: 15px; padding: 0; }
.t-search input::-webkit-search-cancel-button { display: none; }

/* ---------------------------------------------------------------- tabs */
.t-tabs { display: flex; gap: 22px; padding: 0 20px; border-bottom: 1px solid var(--line); flex-shrink: 0; overflow-x: auto; scrollbar-width: none; }
.t-tabs::-webkit-scrollbar { display: none; }
.t-tabs button {
  background: none; border: 0; padding: 12px 0 11px; margin: 0; font-size: 13px; font-weight: 600; letter-spacing: -0.005em;
  color: var(--ink3); border-bottom: 2px solid transparent; white-space: nowrap; flex-shrink: 0;
}
.t-tabs button:hover { color: var(--ink2); }
.t-tabs button.on { color: var(--ink1); border-bottom-color: var(--ink1); }

/* ---------------------------------------------------------------- chips */
.t-chips { display: flex; gap: 8px; padding: 14px 20px 12px; overflow-x: auto; scrollbar-width: none; flex-shrink: 0; contain: inline-size; }
.t-chips::-webkit-scrollbar { display: none; }
.t-chip {
  height: 36px; padding: 0 14px; border-radius: var(--r-btn); flex-shrink: 0; display: inline-flex; align-items: center; gap: 8px;
  font-size: 13px; font-weight: 550; letter-spacing: -0.005em; background: transparent; color: var(--ink1); border: 1px solid var(--line2);
}
.t-chip.dot { padding-left: 11px; }
.t-chip i { width: 6px; height: 6px; border-radius: 50%; flex-shrink: 0; }
.t-chip.on { background: var(--pri); color: var(--pri-ink); border-color: var(--pri); }

/* ---------------------------------------------------------------- lists */
.t-list { padding-top: 6px; }
.t-item {
  display: flex; align-items: center; gap: 13px; padding: 10px 20px; text-decoration: none; color: inherit;
  width: 100%; background: none; border: 0; text-align: left; transition: background-color .12s var(--ease);
}
.t-item:hover { background: var(--wash); color: inherit; }
.t-item.active { background: var(--s1); }
.t-item.ruled { border-bottom: 1px solid var(--line); padding-top: 14px; padding-bottom: 14px; gap: 14px; }
.t-item-body { flex-grow: 1; min-width: 0; display: flex; flex-direction: column; gap: 4px; }
.t-item-top { display: flex; align-items: center; gap: 7px; }
.t-item-name { flex-grow: 1; min-width: 0; font-size: 15px; font-weight: 550; letter-spacing: -0.012em; color: var(--ink1); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.t-item.unread .t-item-name { font-weight: 650; }
.t-item-line { display: flex; align-items: center; gap: 6px; }
.t-item-prev { flex-grow: 1; min-width: 0; font-size: 13.5px; color: var(--ink3); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.t-item.unread .t-item-prev { color: var(--ink2); }
.t-item-prev.acc { color: var(--acc); }
.t-item-prev.bad { color: var(--bad); }
.t-item-ic { display: inline-flex; color: var(--ink3); flex-shrink: 0; }
.t-item-about { font-size: 13px; color: var(--ink2); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.t-item-meta { font-family: var(--mono); font-variant-numeric: tabular-nums; font-size: 11px; color: var(--ink3); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }

/* settings rows */
.t-srow {
  display: flex; align-items: center; gap: 12px; width: 100%; min-height: 52px; padding: 10px 20px; background: none; border: 0;
  border-bottom: 1px solid var(--line); text-align: left; color: var(--ink1); text-decoration: none;
}
.t-srow:hover { background: var(--wash); color: var(--ink1); }
.t-srow.danger { color: var(--bad); }
.t-srow-label { flex-grow: 1; min-width: 0; font-size: 15px; font-weight: 500; }
.t-srow-val { font-size: 14px; color: var(--ink3); white-space: nowrap; }
.t-srow .chev { color: var(--ink3); display: inline-flex; }

/* switch */
.t-switch { width: 46px; height: 28px; border-radius: 14px; background: var(--s3); position: relative; flex-shrink: 0; transition: background-color .18s var(--ease); }
.t-switch::after { content: ''; position: absolute; top: 3px; left: 3px; width: 22px; height: 22px; border-radius: 50%; background: var(--ink3); transition: transform .18s var(--ease), background-color .18s; }
.t-switch.on { background: var(--acc); }
.t-switch.on::after { transform: translateX(18px); background: #FFFFFF; }
html:not([data-theme="day"]) .t-switch.on::after { background: var(--on-acc); }

/* ---------------------------------------------------------------- messages */
.t-msgs { display: flex; flex-direction: column; padding: 12px 16px; }
.t-day { display: flex; align-items: center; gap: 12px; margin: 10px 0 4px; }
.t-day::before, .t-day::after { content: ''; flex-grow: 1; height: 1px; background: var(--line); }
.t-day span { font-size: 12px; font-weight: 600; color: var(--ink3); font-variant-numeric: tabular-nums; }
.t-sys { text-align: center; font-size: 12px; color: var(--ink3); margin: 6px 0; }
.t-m { max-width: 78%; display: flex; flex-direction: column; margin-top: 2px; position: relative; }
.t-m.first { margin-top: 8px; }
.t-m.them { align-self: flex-start; align-items: flex-start; }
.t-m.me { align-self: flex-end; align-items: flex-end; }
.t-bub {
  padding: 9px 13px; border-radius: 18px; font-size: 15px; line-height: 1.42; letter-spacing: -0.003em;
  overflow-wrap: anywhere; white-space: pre-wrap; user-select: text; -webkit-user-select: text;
}
.t-m.them .t-bub { background: var(--s2); color: var(--ink1); border-bottom-left-radius: 6px; }
.t-m.me .t-bub { background: var(--me); color: var(--me-ink); border-bottom-right-radius: 6px; }
.t-m.me .t-bub a, .t-m.me .t-bub .mention { color: #E6E3FF; }
.t-m.sending { opacity: .55; }
.t-m.failed .t-bub { box-shadow: inset 0 0 0 1px var(--bad); }
.t-bub .mention { color: var(--acc); font-weight: 600; }
.t-bub a { color: var(--acc); text-decoration: underline; text-underline-offset: 2px; }
.t-bub.locked { background: none !important; border: 1px dashed var(--line2); color: var(--ink3); font-size: 13px; }
.t-bub.deleted { background: none !important; border: 1px solid var(--line2); color: var(--ink3); font-size: 13px; font-style: italic; }
.t-quote { background: rgba(0, 0, 0, .12); border-radius: 10px; padding: 7px 10px; margin: 0 0 7px; }
.t-m.me .t-quote { background: rgba(0, 0, 0, .18); }
.t-m.me .t-quote b, .t-m.me .t-quote span { color: rgba(255, 255, 255, .86); }
.t-quote b { display: block; font-size: 12px; font-weight: 600; color: var(--ink2); margin-bottom: 2px; }
.t-quote span { font-size: 13px; color: var(--ink2); display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.t-ticks { color: var(--acc); display: inline-flex; }
.t-ticks.sent { color: var(--ink3); }
.t-react-row { display: flex; gap: 4px; margin-top: -6px; margin-right: 10px; margin-left: 10px; position: relative; z-index: 1; }
.t-react {
  display: inline-flex; align-items: center; gap: 4px; height: 22px; padding: 0 8px; border-radius: 11px; background: var(--s3);
  border: 2px solid var(--bg); color: var(--ink2); font-family: var(--mono); font-variant-numeric: tabular-nums; font-size: 11px;
}
.t-react.mine { color: var(--acc); }
.t-sender { display: flex; align-items: center; gap: 6px; margin: 0 0 4px 4px; }
.t-sender b { font-size: 12.5px; font-weight: 600; color: var(--ink2); }
.t-gm { display: flex; gap: 9px; align-items: flex-start; margin-top: 12px; max-width: 86%; align-self: flex-start; }
.t-gm.cont { margin-top: 3px; }
.t-gm.cont > .t-av, .t-gm.cont > .t-glyph { visibility: hidden; }
.t-gm-col { display: flex; flex-direction: column; align-items: flex-start; min-width: 0; }
.t-gm .t-bub { background: var(--s2); border-radius: 18px; }
.t-gm:not(.cont) .t-bub.firstb { border-top-left-radius: 4px; }
.t-photo { border-radius: 14px; overflow: hidden; background: var(--s2); max-width: 260px; }
.t-photo img, .t-photo video { width: 100%; max-height: 340px; object-fit: cover; }
.t-file { display: flex; align-items: center; gap: 10px; padding: 10px 12px; border-radius: 14px; background: var(--s2); text-decoration: none; color: var(--ink1); max-width: 260px; }
.t-voice { display: flex; align-items: center; gap: 10px; padding: 8px 14px 8px 8px; border-radius: 18px 18px 18px 6px; background: var(--s2); }
.t-m.me .t-voice { background: var(--acc-tint); border-radius: 18px 18px 6px 18px; }
.t-voice-play { width: 34px; height: 34px; border-radius: 50%; border: 0; background: var(--pri); color: var(--pri-ink); display: flex; align-items: center; justify-content: center; padding: 0; flex-shrink: 0; }
.t-wave { display: flex; align-items: center; gap: 2.5px; height: 24px; }
.t-wave span { width: 2.5px; border-radius: 2px; background: var(--ink2); flex-shrink: 0; }
.t-wave span.done { background: var(--acc); }
.t-typing { align-self: flex-start; display: flex; gap: 4px; padding: 12px 14px; border-radius: 18px 18px 18px 6px; background: var(--s2); margin-top: 8px; }
.t-typing i { width: 6px; height: 6px; border-radius: 50%; background: var(--ink3); animation: t-blink 1.2s infinite; }
.t-typing i:nth-child(2) { animation-delay: .15s; }
.t-typing i:nth-child(3) { animation-delay: .3s; }
@keyframes t-blink { 0%, 60%, 100% { opacity: .35; } 30% { opacity: 1; } }

/* notice strips under a bar */
.t-strip { display: flex; align-items: center; justify-content: center; gap: 7px; padding: 9px 20px; color: var(--ink3); font-size: 11.5px; border-bottom: 1px solid var(--line); flex-shrink: 0; text-align: center; }
.t-strip.left { justify-content: flex-start; text-align: left; }
.t-strip.fill { background: var(--s1); }
.t-strip.warn { color: var(--ink2); }
.t-strip.warn .svg { color: var(--acc); }
.t-pinbar { display: flex; align-items: center; gap: 10px; padding: 10px 20px; background: var(--s1); border: 0; border-bottom: 1px solid var(--line); color: var(--ink2); font-size: 13px; text-align: left; flex-shrink: 0; width: 100%; }
.t-pinbar b { color: var(--ink1); font-weight: 600; }
.t-pinbar .txt { flex-grow: 1; min-width: 0; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }

/* ---------------------------------------------------------------- composer */
.t-composer { display: flex; align-items: center; gap: 6px; padding: 10px 12px calc(12px + var(--safe-b)) 8px; border-top: 1px solid var(--line); flex-shrink: 0; background: var(--bg); }
.t-field { flex-grow: 1; min-width: 0; display: flex; align-items: flex-end; gap: 8px; min-height: 44px; padding: 0 6px 0 16px; border-radius: 22px; background: var(--s1); border: 1px solid var(--line2); }
.t-field:focus-within { border-color: var(--ink3); }
.t-field textarea, .t-field input {
  flex-grow: 1; min-width: 0; background: none; border: 0; outline: none; color: var(--ink1); font-size: 15px;
  padding: 11px 0; resize: none; max-height: 140px; line-height: 1.4;
}
.t-send { width: 44px; height: 44px; border-radius: 50%; border: 0; background: var(--me); color: var(--me-ink); display: flex; align-items: center; justify-content: center; padding: 0; flex-shrink: 0; transition: transform .12s var(--ease); }
.t-send:active { transform: scale(.9); }
.t-replybar { display: flex; align-items: center; gap: 10px; padding: 8px 12px 8px 20px; border-top: 1px solid var(--line); background: var(--s1); font-size: 13px; color: var(--ink2); flex-shrink: 0; }
.t-replybar .txt { flex-grow: 1; min-width: 0; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.t-replybar b { color: var(--ink1); }

/* ---------------------------------------------------------------- cards */
.t-card { border: 1px solid var(--line2); border-radius: 16px; background: var(--s1); padding: 16px; }
.t-card.plain { background: none; }
.t-cardlink { display: flex; align-items: center; gap: 13px; padding: 14px; border: 1px solid var(--line2); border-radius: 16px; background: var(--s1); text-decoration: none; color: inherit; }
.t-cardlink:hover { color: inherit; border-color: var(--ink4); }

/* ---------------------------------------------------------------- inputs */
.t-label { display: block; font-size: 12.5px; color: var(--ink3); margin: 0 0 7px; font-weight: 500; }
.t-input, .t-textarea, .t-select {
  width: 100%; height: 48px; padding: 0 14px; border-radius: var(--r-btn); background: var(--field); border: 1px solid var(--line2);
  color: var(--ink1); font-size: 15px; outline: none; transition: border-color .15s, box-shadow .15s;
}
.t-textarea { height: auto; min-height: 96px; padding: 12px 14px; resize: vertical; line-height: 1.45; }
.t-input:focus, .t-textarea:focus, .t-select:focus { border-color: var(--ink1); box-shadow: 0 0 0 4px var(--acc-tint); }
.t-input.bad { border-color: var(--bad); }
.t-fieldset { margin-bottom: 16px; }
.t-err { color: var(--bad); font-size: 13px; margin-top: 6px; }
.t-seg { display: flex; gap: 6px; flex-wrap: wrap; }
.t-seg button { height: 38px; padding: 0 14px; border-radius: var(--r-btn); border: 1px solid var(--line2); background: none; color: var(--ink2); font-size: 13px; font-weight: 550; }
.t-seg button.on { background: var(--pri); color: var(--pri-ink); border-color: var(--pri); }

/* ---------------------------------------------------------------- overlays */
.t-scrimlayer { position: fixed; inset: 0; z-index: 60; background: var(--scrim); display: flex; align-items: flex-end; justify-content: center; animation: t-fade .16s var(--ease); }
@keyframes t-fade { from { opacity: 0; } }
.t-sheet {
  width: 100%; max-width: 520px; max-height: 88vh; background: var(--sheet); border: 1px solid var(--line2); border-bottom: 0;
  border-radius: 20px 20px 0 0; display: flex; flex-direction: column; animation: t-up .22s var(--ease); padding-bottom: var(--safe-b);
}
@keyframes t-up { from { transform: translateY(24px); opacity: 0; } }
.t-sheet-grip { width: 38px; height: 4px; border-radius: 2px; background: var(--line2); margin: 10px auto 2px; flex-shrink: 0; }
.t-sheet-head { display: flex; align-items: center; gap: 8px; padding: 8px 10px 8px 20px; flex-shrink: 0; }
.t-sheet-head h2 { margin: 0; flex-grow: 1; font-size: 17px; font-weight: 600; letter-spacing: -0.02em; }
.t-sheet-body { overflow-y: auto; padding: 4px 20px 20px; }
.t-sheet-body.flush { padding: 0 0 12px; }
@media (min-width: 900px) {
  .t-scrimlayer { align-items: center; }
  .t-sheet { border-radius: 20px; border-bottom: 1px solid var(--line2); }
}
.t-menu { border-radius: 14px; background: var(--sheet); border: 1px solid var(--line2); overflow: hidden; }
.t-menu button {
  display: flex; align-items: center; gap: 13px; width: 100%; height: 48px; padding: 0 16px; background: none; border: 0;
  border-bottom: 1px solid var(--line); color: var(--ink1); font-size: 15px; font-weight: 500; text-align: left;
}
.t-menu button:last-child { border-bottom: 0; }
.t-menu button:hover { background: var(--s2); }
.t-menu button .svg { color: var(--ink2); }
.t-menu button.danger, .t-menu button.danger .svg { color: var(--bad); }
.t-menu button .aside { margin-left: auto; font-family: var(--mono); font-variant-numeric: tabular-nums; font-size: 11px; color: var(--ink3); }

.t-toasts { position: fixed; left: 0; right: 0; bottom: calc(var(--tabbar-h) + 14px + var(--safe-b)); z-index: 80; display: flex; flex-direction: column; align-items: center; gap: 8px; pointer-events: none; padding: 0 16px; }
.t-toast { pointer-events: auto; max-width: 420px; background: var(--ink1); color: var(--bg); padding: 11px 16px; border-radius: 12px; font-size: 14px; font-weight: 500; box-shadow: var(--shadow); animation: t-up .2s var(--ease); display: flex; align-items: center; gap: 12px; }
.t-toast.bad { background: var(--bad-bg); color: var(--bad-ink); border: 1px solid var(--bad-line); }
.t-toast button { background: none; border: 0; color: var(--acc); font-weight: 700; padding: 0; }

/* ---------------------------------------------------------------- states */
.t-empty { text-align: center; padding: 56px 32px; color: var(--ink3); }
.t-empty > .svg { margin: 0 auto 14px; color: var(--ink4); }
.t-empty b { display: block; color: var(--ink1); font-size: 16px; font-weight: 600; letter-spacing: -0.015em; margin-bottom: 6px; }
.t-empty p { margin: 0 auto 18px; font-size: 14px; max-width: 300px; line-height: 1.5; }
.t-skel { position: relative; overflow: hidden; background: var(--s1); border-radius: 10px; }
.t-skel::after { content: ''; position: absolute; inset: 0; transform: translateX(-100%); background: linear-gradient(90deg, transparent, var(--wash2), transparent); animation: t-shine 1.3s infinite; }
@keyframes t-shine { to { transform: translateX(100%); } }
.t-skel-row { display: flex; align-items: center; gap: 13px; padding: 10px 20px; }
.t-skel-row .c { width: 50px; height: 50px; border-radius: 50%; }
.t-skel-row .l { flex-grow: 1; display: flex; flex-direction: column; gap: 8px; }
.t-skel-row .l i { display: block; height: 11px; border-radius: 6px; }
.t-spin { width: 22px; height: 22px; border-radius: 50%; border: 2px solid var(--line2); border-top-color: var(--acc); animation: t-rot .7s linear infinite; }
@keyframes t-rot { to { transform: rotate(360deg); } }
.t-center { display: flex; align-items: center; justify-content: center; padding: 40px; }

/* Pull to refresh (pull.js, v81): a circle that comes down from the top
   of the list, turns orange when letting go would refresh, and spins while
   the screen loads. The screen opening again behind it (app.js) waits out
   of sight until it has something to show. */
.t-ptr-box { position: absolute; left: 0; right: 0; height: 140px; overflow: hidden; pointer-events: none; z-index: 20; }
.t-ptr {
  position: absolute; left: 50%; top: -44px; width: 40px; height: 40px; margin-left: -20px; border-radius: 50%;
  background: var(--sheet); border: 1px solid var(--line2); color: var(--ink2); box-shadow: var(--shadow);
  display: flex; align-items: center; justify-content: center; opacity: 0; will-change: transform;
}
.t-ptr.glide { transition: transform .22s var(--ease), opacity .22s var(--ease); }
.t-ptr.ready { color: var(--acc); border-color: var(--acc); }
.t-ptr-ic { display: flex; }
.t-ptr .t-spin { display: none; width: 20px; height: 20px; }
.t-ptr.spin .t-ptr-ic { display: none; }
.t-ptr.spin .t-spin { display: block; }
.t-screen-next { position: absolute; inset: 0; visibility: hidden; pointer-events: none; }

/* Back to top (pull.js, v81): at the bottom of a list scrolled far down. */
.t-top {
  position: fixed; z-index: 40; width: 44px; height: 44px; border-radius: 50%; padding: 0;
  background: var(--sheet); border: 1px solid var(--line2); color: var(--ink1); box-shadow: var(--shadow);
  display: flex; align-items: center; justify-content: center; opacity: 0; visibility: hidden; transform: translateY(10px) scale(.92);
  transition: opacity .18s var(--ease), transform .18s var(--ease), visibility 0s linear .18s;
}
.t-top.on { opacity: 1; visibility: visible; transform: none; transition: opacity .18s var(--ease), transform .18s var(--ease), visibility 0s; }
.t-top:hover { background: var(--s3); }

.t-top:active { transform: scale(.92); }
.t-offline { position: fixed; top: calc(8px + var(--safe-t)); left: 50%; transform: translateX(-50%); z-index: 90; display: flex; align-items: center; gap: 10px; max-width: calc(100vw - 24px); background: var(--s2); border: 1px solid var(--line2); color: var(--ink2); padding: 5px 5px 5px 14px; border-radius: 12px; font-size: 12.5px; white-space: nowrap; box-shadow: var(--shadow); }
.t-offline > span { overflow: hidden; text-overflow: ellipsis; }
.t-offline-go { display: inline-flex; align-items: center; gap: 5px; height: 28px; padding: 0 11px; border: 0; border-radius: 7px; background: var(--pri); color: var(--pri-ink); font: 600 12.5px var(--font); cursor: pointer; flex-shrink: 0; }
.t-offline-go:active { transform: scale(.97); }

/* ---------------------------------------------------------------- media stage (calls, live) */
.t-stage { position: absolute; inset: 0; background: #15171B; overflow: hidden; }
.t-stage video { width: 100%; height: 100%; object-fit: cover; }
.t-live-badge { display: inline-flex; align-items: center; height: 22px; padding: 0 7px; border-radius: 6px; background: var(--live); color: #fff; font-family: var(--mono); font-variant-numeric: tabular-nums; font-size: 10.5px; font-weight: 600; letter-spacing: 0.08em; }
.t-pill { display: inline-flex; align-items: center; gap: 5px; height: 24px; padding: 0 8px; border-radius: 7px; background: rgba(0, 0, 0, .62); color: #FFFFFF; font-family: var(--mono); font-variant-numeric: tabular-nums; font-size: 11px; }
.t-round { width: 60px; height: 60px; border-radius: 50%; border: 0; background: #26282E; color: var(--ink1); display: flex; align-items: center; justify-content: center; padding: 0; flex-shrink: 0; transition: transform .12s var(--ease), background-color .15s; }
.t-round:active { transform: scale(.92); }
.t-round.on { background: var(--pri); color: var(--pri-ink); }
.t-round.end { background: var(--live); color: #fff; }

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: .001ms !important; transition-duration: .001ms !important; }
}

/* ---------------------------------------------------------------- turn on notifications (v80, push-prompt.js) */
/* v89: a page opened from a tab is the whole screen on a phone (app.js): with
   no tab bar under it, what floated above the bar sits at the bottom instead. */
body.t-inner .t-toasts { bottom: calc(16px + var(--safe-b)); }
body.t-inner:not(.t-focus) .t-pane.detail { padding-bottom: var(--safe-b); }
body.t-inner .tp-ask { bottom: calc(12px + var(--safe-b)); }
.tp-ask {
  position: fixed; left: 12px; right: 12px; bottom: calc(var(--tabbar-h) + 12px + var(--safe-b)); z-index: 70;
  max-width: 460px; margin: 0 auto; display: flex; gap: 14px; align-items: flex-start;
  padding: 16px 16px 14px; border-radius: 16px; background: var(--sheet); border: 1px solid var(--line2);
  box-shadow: var(--lift); opacity: 0; transform: translateY(14px);
  transition: opacity .22s var(--ease), transform .22s var(--ease);
}
.tp-ask.in { opacity: 1; transform: none; }
.tp-ask-i { flex-shrink: 0; width: 44px; height: 44px; border-radius: 22px; display: flex; align-items: center; justify-content: center; background: var(--acc); color: var(--on-acc); }
.tp-ask-b { min-width: 0; flex: 1; }
.tp-ask-b b { display: block; font-size: 15.5px; font-weight: 650; color: var(--ink1); }
.tp-ask-b p { margin: 4px 0 12px; font-size: 13.5px; line-height: 1.4; color: var(--ink2); }
.tp-ask-btns { display: flex; gap: 8px; justify-content: flex-end; }
@media (min-width: 900px) { .tp-ask { left: auto; right: 24px; bottom: 24px; } }
@media (prefers-reduced-motion: reduce) { .tp-ask { transition: none; } }

/* A date field (v82, the date of birth asked once in assets/talk/js/age.js). */
.t-date { color-scheme: inherit; }
.t-date::-webkit-calendar-picker-indicator { opacity: 0.75; cursor: pointer; }

/* v87: inside the Android app nothing is sold (core.js canBuy); a safety
   net for any buy button a screen draws without asking. */
.tf-nobuy [data-buy], .tf-nobuy [data-getcoins], .tf-nobuy .lv-buy { display: none !important; }

/* =====================================================================
   v90: the frame of the four main pages (chrome.js), the launcher, light
   on glass, and the page transitions.
   ===================================================================== */

/* v93: the room is plain: white by day, black at night */
#app { background: var(--bg); }
.t-screen { background: transparent; }
.t-screen-next { background: var(--bg); }

/* ---------------------------------------------------------------- the header of a main page */
.t-rhead { position: relative; z-index: 3; display: flex; align-items: center; gap: 12px; padding: calc(10px + var(--safe-t)) 8px 10px 16px; flex-shrink: 0; min-height: calc(64px + var(--safe-t)); background: var(--bar-sheen), var(--bar); -webkit-backdrop-filter: var(--bar-fx); backdrop-filter: var(--bar-fx); box-shadow: inset 0 -1px 0 var(--bar-line); }
/* v94: a main page's header is glass that stays at the top of its list: the list passes under it, blurred */
.t-scroll .t-rhead { position: sticky; top: 0; z-index: 8; }
.t-scroll:has(.t-rhead) { scroll-padding-top: calc(76px + var(--safe-t)); }
.t-rhead-me { flex-shrink: 0; display: flex; border-radius: 50%; text-decoration: none; transition: transform .25s var(--spring); }
.t-rhead-me:active { transform: scale(.9); }
.t-rhead-me .t-av-face { box-shadow: 0 0 0 1.5px rgba(255, 255, 255, .24); }
.t-rhead-t { flex: 1 1 auto; min-width: 0; display: flex; flex-direction: column; justify-content: center; }
.t-rhead-t h1 { margin: 0; font-size: 26px; line-height: 1.06; font-weight: 600; letter-spacing: -0.035em; color: var(--ink1); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.t-rhead-sub { font-size: 12px; line-height: 1.3; color: var(--ink3); margin-top: 3px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.t-rhead-act { display: flex; align-items: center; gap: 2px; flex-shrink: 0; }
.t-rhead-menu { color: var(--ink1); }
.t-lnch { position: relative; display: block; width: 22px; height: 22px; }
.t-lnch svg { position: absolute; inset: 0; transition: transform .38s var(--spring), opacity .2s var(--glide); }
.t-lnch-lit { fill: currentColor; }
.t-lnch-x { opacity: 0; transform: rotate(-90deg) scale(.5); }
.t-rhead-menu.open .t-lnch-a { opacity: 0; transform: rotate(90deg) scale(.5); }
.t-rhead-menu.open .t-lnch-x { opacity: 1; transform: none; }

/* ---------------------------------------------------------------- Chats and Groups */
.t-segs { position: relative; display: inline-flex; align-self: flex-start; padding: 3px; border-radius: 11px; background: var(--wash2); box-shadow: inset 0 0 0 1px var(--line); max-width: 100%; }
.t-segs-pill {
  position: absolute; left: 0; top: 3px; bottom: 3px; width: 50%; border-radius: 8px; pointer-events: none;
  background: var(--pri); box-shadow: none;
  transition: transform .42s var(--spring), width .3s var(--glide);
  view-transition-name: t-segpill;
}
.t-seg-i { position: relative; z-index: 1; display: inline-flex; align-items: center; gap: 7px; height: 36px; padding: 0 16px; border-radius: 8px; color: var(--ink2); font-size: 15px; font-weight: 600; letter-spacing: -0.02em; text-decoration: none; white-space: nowrap; transition: color .22s var(--glide); }
.t-seg-i:hover { color: var(--ink2); }
.t-seg-i.on, .t-seg-i.on:hover { color: var(--pri-ink); }
.t-seg-n { min-width: 18px; height: 18px; padding: 0 5px; border-radius: 9px; background: var(--acc); color: var(--on-acc); font: 650 10.5px/18px var(--mono); font-variant-numeric: tabular-nums; text-align: center; }
@media (max-width: 370px) { .t-seg-i { padding: 0 12px; font-size: 15px; } }

/* ---------------------------------------------------------------- light on glass (chrome.js) */
/* Every [data-light] element is positioned and isolated, so this sits on its background, under its content. */
/* v93: formal, so no light follows the pointer over glass */
[data-light]::before { content: none; }
html.t-lite [data-light]::before { display: none; }

/* ---------------------------------------------------------------- the launcher */
.t-lnch-layer { position: fixed; inset: 0; z-index: 75; }
.t-lnch-scrim { position: absolute; inset: 0; background: var(--scrim); opacity: 0; transition: opacity .24s var(--glide); }
.t-lnch-layer.in .t-lnch-scrim { opacity: 1; }
.t-lnch-layer.out .t-lnch-scrim { opacity: 0; transition-duration: .16s; }
.t-lnch-panel {
  position: absolute; top: var(--top, 72px); right: var(--right, 12px); width: min(384px, calc(100vw - 24px)); max-height: calc(100% - var(--top, 72px) - 16px - var(--safe-b)); overflow-y: auto;
  padding: 10px; border-radius: 20px; outline: none;
  background: var(--glass-2); -webkit-backdrop-filter: var(--glass-blur); backdrop-filter: var(--glass-blur);
  box-shadow: var(--lift), inset 0 0 0 1px var(--glass-line);
  transform-origin: calc(100% - 26px) -6px; transform: scale(.88) translateY(-8px); opacity: 0;
  transition: transform .4s var(--spring), opacity .22s var(--glide);
}
.t-lnch-layer.in .t-lnch-panel { transform: none; opacity: 1; }
.t-lnch-layer.out .t-lnch-panel { transform: scale(.95) translateY(-4px); opacity: 0; transition: transform .16s var(--glide), opacity .16s var(--glide); }
.t-lnch-me { position: relative; isolation: isolate; display: flex; align-items: center; gap: 12px; padding: 10px 12px 10px 10px; border-radius: 14px; text-decoration: none; color: var(--ink1); background: var(--wash); }
.t-lnch-me:hover { color: var(--ink1); background: var(--wash2); }
.t-lnch-who { flex: 1 1 auto; min-width: 0; display: flex; flex-direction: column; gap: 2px; }
.t-lnch-who b { font-size: 16px; font-weight: 650; letter-spacing: -0.02em; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.t-lnch-who small { font: 500 12px var(--mono); font-variant-numeric: tabular-nums; color: var(--ink3); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.t-lnch-go { display: inline-flex; align-items: center; gap: 2px; font-size: 12.5px; font-weight: 600; color: var(--acc); flex-shrink: 0; }
.t-lnch-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 6px; margin-top: 8px; }
.t-lnch-tile {
  position: relative; isolation: isolate; display: flex; flex-direction: column; align-items: center; justify-content: flex-start; gap: 9px;
  min-height: 98px; padding: 14px 6px 12px; border-radius: 14px; border: 0; background: var(--wash); color: var(--ink1);
  text-decoration: none; font: inherit; cursor: pointer; opacity: 0; transform: translateY(8px) scale(.96);
}
.t-lnch-layer.in .t-lnch-tile { opacity: 1; transform: none; transition: opacity .3s var(--glide) calc(var(--i, 0) * 16ms + 50ms), transform .44s var(--spring) calc(var(--i, 0) * 16ms + 50ms), background-color .2s; }
.t-lnch-tile:hover { color: var(--ink1); background: var(--wash2); }
.t-lnch-layer.in .t-lnch-tile:active { transform: scale(.93); transition-delay: 0s; }
.t-lnch-tic {
  width: 46px; height: 46px; border-radius: 12px; display: grid; place-items: center; color: var(--ink1);
  background: var(--s2); box-shadow: inset 0 0 0 1px var(--line);
}
.t-lnch-l { font-size: 12.5px; font-weight: 600; letter-spacing: -0.01em; line-height: 1.2; text-align: center; overflow-wrap: anywhere; }
.t-lnch-n { position: absolute; top: 8px; right: 10px; z-index: 2; min-width: 18px; height: 18px; padding: 0 5px; border-radius: 9px; background: var(--acc); color: var(--on-acc); font: 650 10.5px/18px var(--mono); font-variant-numeric: tabular-nums; text-align: center; }
html.t-lite .t-lnch-tile, html.t-lite .t-lnch-panel { transition-duration: .001s !important; transition-delay: 0s !important; }

/* ---------------------------------------------------------------- page transitions (app.js swap) */
::view-transition-old(root), ::view-transition-new(root) { animation-duration: .3s; animation-timing-function: var(--glide); }
html[data-vt="push"]::view-transition-old(root) { animation-name: t-vt-push-out; }
html[data-vt="push"]::view-transition-new(root) { animation-name: t-vt-push-in; }
html[data-vt="pop"]::view-transition-old(root) { animation-name: t-vt-pop-out; }
html[data-vt="pop"]::view-transition-new(root) { animation-name: t-vt-pop-in; }
html[data-vt="pop"]::view-transition-old(root) { z-index: 1; }
html[data-vt="tab"]::view-transition-old(root) { animation-name: t-vt-fade-out; animation-duration: .18s; }
html[data-vt="tab"]::view-transition-new(root) { animation-name: t-vt-tab-in; animation-duration: .28s; }
::view-transition-group(t-island), ::view-transition-group(t-fab), ::view-transition-group(t-segpill) { animation-duration: .38s; animation-timing-function: var(--spring); }
html[data-vt] .t-island, html[data-vt] .t-fab { transition: none; }
@keyframes t-vt-push-in { from { transform: translateX(26%); opacity: 0; } }
@keyframes t-vt-push-out { to { transform: translateX(-10%); opacity: 0; } }
@keyframes t-vt-pop-in { from { transform: translateX(-10%); opacity: 0; } }
@keyframes t-vt-pop-out { to { transform: translateX(26%); opacity: 0; } }
@keyframes t-vt-fade-out { to { opacity: 0; } }
@keyframes t-vt-tab-in { from { opacity: 0; transform: translateY(6px) scale(.992); } }
@media (prefers-reduced-motion: reduce) {
  ::view-transition-group(*), ::view-transition-old(*), ::view-transition-new(*) { animation: none !important; }
}

/* =====================================================================
   v93: what stays dark in daylight. A call, a live, the reels, a story,
   a photo opened full screen: they are pictures and video, and they keep
   the night's colours whatever the time, so white words stay on them.
   ===================================================================== */
html[data-theme="day"] :is(.t-dark, .t-stage, .cl, .t-screen.lv-full, .lv-watch, .lv-stage, .wr, .sv2, .th.th-mm, .th-viewer) {
  --bg: #0E0A1C; --s1: #1C1634; --s2: #272046; --s3: #32295A; --line: #221B3F; --line2: #332A57;
  --ink1: #FFFFFF; --ink2: #C8C2E8; --ink3: #8C85B0; --ink4: #625B88;
  --acc: #A39BFF; --acc-hover: #BCB6FF; --acc-ink: #A39BFF; --on-acc: #0E0A1C; --acc-tint: rgba(163, 155, 255, .14); --acc-tint2: rgba(163, 155, 255, .28);
  --me: #5A52A8; --live: #FF3B5C; --ok: #4FD39A; --bad: #FF6B6B;
  --pri: #A39BFF; --pri-ink: #0E0A1C; --pri-hover: #BCB6FF;
  --sec: #1C1634; --sec-ink: #FFFFFF; --sec-line: #332A57; --sec-hover: #272046;
  --field: #1C1634; --sheet: #161129;
  --wash: rgba(255, 255, 255, .035); --wash2: rgba(255, 255, 255, .065); --wash3: rgba(255, 255, 255, .1);
  --av-bg: #272046; --av-ink: #E4DEFF;
  --tone-0: #3A2A22; --tone-1: #1F2B33; --tone-2: #2F2433; --tone-3: #26301F; --tone-4: #33291F; --tone-5: #1E2430; --tone-6: #2E2227; --tone-7: #2B3A2A; --tone-8: #3A2418; --tone-9: #22262D; --tone-10: #302329; --tone-11: #23302B; --tone-12: #1E2A3A; --tone-13: #2A2331;
  --bad-bg: #2A1212; --bad-line: #4A2220; --bad-ink: #FFD9D5; --ok-bg: #12241B; --ok-ink: #7FD8AE;
  --bar: rgba(22, 17, 41, .78); --bar-solid: #161129; --bar-line: rgba(255, 255, 255, .1);
  --bar-ink: #FFFFFF; --bar-ink2: rgba(255, 255, 255, .72); --bar-btn: rgba(255, 255, 255, .08); --bar-btn-line: rgba(255, 255, 255, .14); --bar-on: rgba(163, 155, 255, .16);
  --bar-sheen: linear-gradient(180deg, rgba(255, 255, 255, .06), rgba(255, 255, 255, 0) 70%);
  color-scheme: dark; color: var(--ink1);
}
.t-round { color: #FFFFFF; }
.t-round.on { background: #FFFFFF; color: #000000; }
