/* Vibes: the social network of San Andreas.
   Plain CSS that also runs in FiveM's Chromium 103 (no :has, nesting, oklch or container queries). */

:root {
  --bg: #0b0c0f;
  --panel: #14161b;
  --panel-2: #1a1d23;
  --panel-3: #22252d;
  --hover: rgba(255, 255, 255, .055);
  --line: #23262e;
  --line-2: #2e323b;
  --text: #f2f3f5;
  --text-2: #b6bbc4;
  --text-3: #7e8591;
  --brand: #ff3d77;
  --brand-2: #ff8a3d;
  --brand-ink: #ff6b98;
  --brand-soft: rgba(255, 61, 119, .14);
  --grad: linear-gradient(120deg, #8b5cf6 0%, #ff3d77 50%, #ff9a3d 100%);
  --grad-ring: conic-gradient(from 210deg, #8b5cf6, #ff3d77, #ff9a3d, #ffd23d, #8b5cf6);
  --ok: #2fd27a;
  --warn: #f6b23c;
  --info: #4aa3ff;
  --verified: #3d8bff;
  --shadow: 0 12px 40px rgba(0, 0, 0, .45);
  --shadow-sm: 0 2px 10px rgba(0, 0, 0, .3);
  --r-xl: 24px;
  --r-lg: 18px;
  --r: 14px;
  --r-sm: 10px;
  --font: "Plus Jakarta Sans", "Segoe UI", system-ui, -apple-system, Roboto, Arial, sans-serif;
  --rail: 264px;
  --main: 620px;
  --side: 340px;
  color-scheme: dark;
}
[data-theme="light"] {
  --bg: #f2f3f6;
  --panel: #ffffff;
  --panel-2: #f6f7f9;
  --panel-3: #eceef2;
  --hover: rgba(17, 19, 24, .045);
  --line: #e7e9ee;
  --line-2: #d9dce3;
  --text: #121419;
  --text-2: #4a505c;
  --text-3: #7b818d;
  --brand: #e8336d;
  --brand-ink: #d61f5c;
  --brand-soft: rgba(232, 51, 109, .09);
  --shadow: 0 14px 40px rgba(20, 24, 35, .14);
  --shadow-sm: 0 2px 8px rgba(20, 24, 35, .07);
  color-scheme: light;
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
html, body { margin: 0; }
body { background: var(--bg); color: var(--text); font: 15px/1.5 var(--font); -webkit-font-smoothing: antialiased; }
a { color: inherit; text-decoration: none; }
button, input, select, textarea { font: inherit; color: inherit; }
button { cursor: pointer; }
img { max-width: 100%; }
[hidden] { display: none !important; }
h1, h2, h3 { margin: 0; line-height: 1.25; }
p { margin: 0; }
.muted { color: var(--text-3); }
.small { font-size: 13px; }
.inline { display: inline; }
svg.i { width: 20px; height: 20px; flex: none; fill: none; stroke: currentColor; stroke-width: 1.9; stroke-linecap: round; stroke-linejoin: round; vertical-align: middle; }
.only-light { display: none; }
[data-theme="light"] .only-light { display: inline; }
[data-theme="light"] .only-dark { display: none; }
:focus-visible { outline: 2px solid var(--brand); outline-offset: 2px; }
::selection { background: var(--brand); color: #fff; }

/* ---------- brand ---------- */
.logo { display: inline-flex; align-items: center; gap: 10px; font-weight: 800; }
.logo-mark {
  width: 36px; height: 36px; border-radius: 11px; background: var(--grad); color: #fff;
  display: grid; place-items: center; flex: none; overflow: hidden;
  box-shadow: 0 6px 18px rgba(255, 61, 119, .35);
}
.logo-mark svg { width: 100%; height: 100%; fill: #fff; }
.logo-mark-sm { width: 26px; height: 26px; border-radius: 8px; font-size: 14px; box-shadow: none; }
.logo-word { font-size: 22px; letter-spacing: -.045em; }
.grad-text { background: var(--grad); -webkit-background-clip: text; background-clip: text; color: transparent; }

/* ---------- buttons ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px; height: 40px; padding: 0 18px;
  border-radius: 999px; border: 1px solid transparent; font-weight: 700; font-size: 14px; white-space: nowrap;
  transition: transform .12s ease, background-color .15s ease, opacity .15s ease, box-shadow .15s ease;
}
.btn:active { transform: scale(.97); }
.btn[disabled] { opacity: .45; pointer-events: none; }
.btn svg.i { width: 18px; height: 18px; }
.btn-grad { background: var(--grad); color: #fff; box-shadow: 0 6px 20px rgba(255, 61, 119, .28); }
.btn-grad:hover { box-shadow: 0 8px 26px rgba(255, 61, 119, .42); filter: saturate(1.08); }
.btn-soft { background: var(--panel-3); color: var(--text); }
.btn-soft:hover { background: var(--line-2); }
.btn-ghost { background: transparent; color: var(--text-2); border-color: var(--line-2); }
.btn-ghost:hover { background: var(--hover); color: var(--text); }
.btn-danger { background: rgba(255, 59, 59, .14); color: #ff6b6b; }
.btn-danger:hover { background: rgba(255, 59, 59, .22); }
.btn-sm { height: 34px; padding: 0 14px; font-size: 13px; }
.btn-lg { height: 52px; font-size: 15.5px; }
.btn-block { width: 100%; }
.icon-btn {
  position: relative; width: 38px; height: 38px; border-radius: 50%; display: inline-grid; place-items: center;
  border: 0; background: transparent; color: var(--text-2); flex: none; transition: background-color .15s ease, color .15s ease;
}
.icon-btn:hover { background: var(--hover); color: var(--text); }
.icon-btn-soft { background: var(--panel-3); color: var(--text); width: 40px; height: 40px; }
.icon-btn-glass { background: rgba(0, 0, 0, .35); color: #fff; backdrop-filter: blur(8px); }
.link-btn { border: 0; background: none; padding: 0; color: var(--text-3); font-weight: 700; font-size: 12.5px; }
.link-btn:hover { color: var(--text); text-decoration: underline; }
.link-btn.on { color: var(--brand-ink); }
.pill { display: inline-flex; align-items: center; gap: 6px; height: 32px; padding: 0 14px; border-radius: 999px; border: 1px solid var(--line-2); background: transparent; font-weight: 700; font-size: 13px; color: var(--text); }
.pill:hover { background: var(--hover); }
.pill svg.i { width: 17px; height: 17px; }
.pill-brand { border: 0; width: 34px; padding: 0; justify-content: center; background: var(--brand-soft); color: var(--brand-ink); }
.pill-brand:hover { background: var(--brand); color: #fff; }
.pill-glass { border: 0; background: rgba(255, 255, 255, .14); color: #fff; backdrop-filter: blur(8px); }
.pill.done, .pill-brand.done { background: var(--panel-3); color: var(--text-3); pointer-events: none; }
.chip { display: inline-flex; align-items: center; height: 22px; padding: 0 9px; border-radius: 999px; background: var(--panel-3); color: var(--text-2); font-size: 11.5px; font-weight: 700; vertical-align: middle; }
.chip-page { background: var(--brand-soft); color: var(--brand-ink); }

/* ---------- avatars ---------- */
.av { position: relative; display: inline-block; flex: none; border-radius: 50%; background: var(--panel-3); }
.av > img, .av-ini { width: 100%; height: 100%; border-radius: inherit; object-fit: cover; display: grid; place-items: center; }
.av-page { border-radius: 28%; }
.av-ini { color: #fff; font-weight: 800; letter-spacing: -.02em; user-select: none; }
.av-h0 { background: linear-gradient(135deg, #ff3d77, #ff9a3d); }
.av-h1 { background: linear-gradient(135deg, #7b5cff, #3d8bff); }
.av-h2 { background: linear-gradient(135deg, #00b894, #2fd27a); }
.av-h3 { background: linear-gradient(135deg, #f6b23c, #ff6a2b); }
.av-h4 { background: linear-gradient(135deg, #0ea5e9, #14b8a6); }
.av-h5 { background: linear-gradient(135deg, #e84393, #a855f7); }
.av-h6 { background: linear-gradient(135deg, #475569, #94a3b8); }
.av-h7 { background: linear-gradient(135deg, #b91c1c, #f43f5e); }
.av-xs { width: 26px; height: 26px; font-size: 10.5px; }
.av-sm { width: 36px; height: 36px; font-size: 13px; }
.av-md { width: 44px; height: 44px; font-size: 15px; }
.av-lg { width: 58px; height: 58px; font-size: 19px; }
.av-xl { width: 88px; height: 88px; font-size: 28px; }
.av-xxl { width: 140px; height: 140px; font-size: 44px; }
.av-xxl .av-on, .av-xl .av-on { width: 20px; height: 20px; right: 8%; bottom: 8%; border-width: 3px; }
.av-on { position: absolute; right: 1px; bottom: 1px; width: 26%; height: 26%; min-width: 9px; min-height: 9px; border-radius: 50%; background: var(--ok); border: 2px solid var(--panel); }
.verified { display: inline-flex; color: var(--verified); margin-left: 4px; vertical-align: -3px; }
.verified svg.i { width: 17px; height: 17px; fill: var(--verified); stroke: #fff; stroke-width: 1.6; }

/* ---------- app shell ---------- */
.shell { display: flex; justify-content: center; gap: 28px; max-width: calc(var(--rail) + var(--main) + var(--side) + 56px + 32px); margin: 0 auto; padding: 0 16px; min-height: 100vh; }
.rail { position: sticky; top: 0; height: 100vh; width: var(--rail); flex: none; display: flex; flex-direction: column; gap: 6px; padding: 18px 0 16px; }
.rail .logo { padding: 4px 12px 18px; }
.rail-nav { display: flex; flex-direction: column; gap: 2px; min-height: 0; overflow-y: auto; scrollbar-width: none; flex: 0 1 auto; }
.rail-nav a { display: flex; align-items: center; gap: 16px; height: 46px; padding: 0 14px; border-radius: 999px; color: var(--text-2); font-size: 16px; font-weight: 600; transition: background-color .15s ease, color .15s ease; }
.rail-nav a:hover { background: var(--hover); color: var(--text); }
.rail-nav a.on { color: var(--text); font-weight: 800; }
.rail-nav a.on .rail-ic svg.i { stroke-width: 2.4; color: var(--brand); }
.rail-ic { position: relative; display: inline-flex; }
.rail-ic svg.i { width: 25px; height: 25px; }
.dot-count { position: absolute; top: -7px; right: -10px; min-width: 19px; height: 19px; padding: 0 5px; border-radius: 999px; background: var(--brand); color: #fff; font: 800 11px/19px var(--font); text-align: center; border: 2px solid var(--bg); box-sizing: content-box; }
.btn-post { margin: 14px 0 0; height: 50px; font-size: 16px; }
.btn-post svg.i { display: none; }
.me-menu { position: relative; margin-top: auto; }
.me-menu > summary { list-style: none; display: flex; align-items: center; gap: 10px; padding: 10px 12px; border-radius: 999px; cursor: pointer; }
.me-menu > summary::-webkit-details-marker { display: none; }
.me-menu > summary:hover { background: var(--hover); }
.me-who { display: flex; flex-direction: column; min-width: 0; flex: 1; line-height: 1.25; }
.me-who b, .me-who small { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.me-who small { color: var(--text-3); }
.main { width: var(--main); max-width: 100%; flex: none; padding: 0 0 80px; border-left: 1px solid var(--line); border-right: 1px solid var(--line); min-height: 100vh; }
.wide .main { width: calc(var(--main) + var(--side) + 28px); border-right: 0; }
.side { width: var(--side); flex: none; padding: 14px 0 40px; position: sticky; top: 0; align-self: flex-start; max-height: 100vh; overflow-y: auto; scrollbar-width: none; }
.side::-webkit-scrollbar { display: none; }
.topbar { display: none; }
.tabbar { display: none; }
.acting { display: flex; align-items: center; gap: 10px; margin: 12px 16px 0; padding: 10px 14px; border-radius: var(--r); background: var(--brand-soft); color: var(--text); font-size: 13.5px; flex-wrap: wrap; }
.acting form { margin-left: auto; }
.acting .link-btn { color: var(--brand-ink); }

/* ---------- menus ---------- */
details[data-menu] > summary { list-style: none; }
details[data-menu] > summary::-webkit-details-marker { display: none; }
.menu {
  position: absolute; z-index: 40; right: 0; top: calc(100% + 6px); min-width: 230px; padding: 6px;
  background: var(--panel-2); border: 1px solid var(--line-2); border-radius: var(--r); box-shadow: var(--shadow);
  animation: pop .14s ease-out;
}
.menu-up { top: auto; bottom: calc(100% + 8px); left: 0; right: auto; width: 290px; }
.menu form { margin: 0; }
.menu-item { width: 100%; display: flex; align-items: center; gap: 12px; padding: 10px 12px; border: 0; border-radius: var(--r-sm); background: none; text-align: left; font-weight: 600; font-size: 14px; color: var(--text); }
.menu-item:hover { background: var(--hover); }
.menu-item > span { flex: 1; display: flex; flex-direction: column; line-height: 1.25; min-width: 0; }
.menu-item small { color: var(--text-3); font-weight: 500; font-size: 12px; }
.menu-item.danger { color: #ff6b6b; }
.menu-item.on { background: var(--brand-soft); }
.menu-check { color: var(--brand); }
.menu-label { padding: 8px 12px 4px; font-size: 11.5px; font-weight: 800; text-transform: uppercase; letter-spacing: .06em; color: var(--text-3); }
.menu-sep { height: 1px; background: var(--line); margin: 6px 4px; }
@keyframes pop { from { opacity: 0; transform: translateY(-4px) scale(.98); } to { opacity: 1; transform: none; } }

/* ---------- page heads and tabs ---------- */
.page-head { display: flex; align-items: center; gap: 12px; padding: 16px 18px 10px; position: sticky; top: 0; z-index: 20; background: color-mix(in srgb, var(--bg) 82%, transparent); backdrop-filter: blur(14px); -webkit-backdrop-filter: blur(14px); }
@supports not (background: color-mix(in srgb, red 50%, transparent)) { .page-head, .tabs-sticky { background: var(--bg); } }
.page-head h1 { font-size: 22px; font-weight: 800; letter-spacing: -.02em; }
.page-head small { display: block; }
.head-btn { margin-left: auto; }
.feed-head { position: sticky; top: 0; z-index: 20; }
.tabs { display: flex; border-bottom: 1px solid var(--line); padding: 0 6px; overflow-x: auto; scrollbar-width: none; }
.tabs::-webkit-scrollbar { display: none; }
.tabs a { position: relative; flex: 1; min-width: max-content; text-align: center; padding: 15px 16px; font-weight: 700; color: var(--text-3); transition: color .15s ease, background-color .15s ease; }
.tabs a:hover { color: var(--text); background: var(--hover); }
.tabs a.on { color: var(--text); }
.tabs a.on::after { content: ""; position: absolute; left: 50%; bottom: -1px; transform: translateX(-50%); width: 56px; height: 4px; border-radius: 4px 4px 0 0; background: var(--grad); }
.tabs-sticky { background: color-mix(in srgb, var(--bg) 82%, transparent); backdrop-filter: blur(14px); -webkit-backdrop-filter: blur(14px); }
.tab-n { display: inline-block; min-width: 20px; padding: 0 6px; border-radius: 999px; background: var(--panel-3); color: var(--text-2); font-size: 12px; line-height: 20px; margin-left: 4px; }
.tab-n-hot { background: var(--brand); color: #fff; }
.section-h { font-size: 13px; font-weight: 800; text-transform: uppercase; letter-spacing: .07em; color: var(--text-3); padding: 22px 18px 10px; display: flex; align-items: center; gap: 6px; }

/* ---------- cards ---------- */
.card { background: var(--panel); border: 1px solid var(--line); border-radius: var(--r-lg); }
.main > .card, .main > .card-grid, .main > .post-list, .main > .empty, .main > .notice, .main > .tag-cloud, .main > .search-big, .main > .report-list, .main > .stories { margin-left: 14px; margin-right: 14px; }
.main > .card { margin-top: 12px; }
.card-h { display: flex; align-items: center; gap: 6px; font-size: 16px; font-weight: 800; padding: 16px 16px 10px; }
.notice { display: flex; align-items: center; gap: 10px; margin-top: 12px; padding: 12px 14px; border-radius: var(--r); font-size: 13.5px; font-weight: 600; }
.notice-warn { background: rgba(246, 178, 60, .12); color: var(--warn); }
.alert { padding: 11px 14px; border-radius: var(--r-sm); font-size: 13.5px; font-weight: 600; margin-bottom: 14px; }
.alert-error { background: rgba(255, 59, 59, .13); color: #ff7b7b; }
.alert-success { background: rgba(47, 210, 122, .12); color: var(--ok); }
.alert-info { background: rgba(74, 163, 255, .12); color: var(--info); }

/* ---------- stories tray ---------- */
.stories { margin-top: 12px; }
.stories-track { display: flex; gap: 14px; overflow-x: auto; padding: 6px 4px 8px; scrollbar-width: none; scroll-snap-type: x proximity; }
.stories-track::-webkit-scrollbar { display: none; }
.story-bubble { flex: none; width: 74px; display: flex; flex-direction: column; align-items: center; gap: 6px; border: 0; background: none; padding: 0; scroll-snap-align: start; }
.story-bubble[disabled] { opacity: .5; }
.story-ring { position: relative; display: inline-grid; place-items: center; padding: 3px; border-radius: 50%; background: var(--grad-ring); }
.story-ring > .av { border: 3px solid var(--bg); box-sizing: content-box; }
.story-ring-seen { background: var(--line-2); }
.story-ring-none { background: transparent; }
.story-ring-none > .av { border-color: transparent; }
.story-bubble:hover .story-ring { transform: scale(1.04); }
.story-ring { transition: transform .15s ease; }
.story-plus { position: absolute; right: 0; bottom: 0; width: 24px; height: 24px; border-radius: 50%; background: var(--grad); color: #fff; display: grid; place-items: center; border: 3px solid var(--bg); box-sizing: content-box; }
.story-plus svg.i { width: 14px; height: 14px; stroke-width: 3; }
.story-name { max-width: 74px; font-size: 12.5px; font-weight: 600; color: var(--text-2); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.stories-empty { display: flex; flex-direction: column; justify-content: center; padding: 0 10px; color: var(--text-3); font-size: 13px; }
.stories-empty b { color: var(--text-2); }

/* ---------- composer ---------- */
.composer-card { padding: 14px 16px 10px; }
.composer-row { display: flex; gap: 12px; }
.composer-main { flex: 1; min-width: 0; }
.composer-text { width: 100%; resize: none; border: 0; outline: 0; background: transparent; font-size: 18px; line-height: 1.45; padding: 9px 0 6px; min-height: 44px; max-height: 50vh; color: var(--text); }
.composer-text::placeholder { color: var(--text-3); }
.composer-media { display: grid; grid-template-columns: repeat(auto-fill, minmax(110px, 1fr)); gap: 8px; margin: 6px 0 4px; }
.cm-item { position: relative; aspect-ratio: 1; border-radius: var(--r); overflow: hidden; background: var(--panel-3); }
.cm-item img { width: 100%; height: 100%; object-fit: cover; display: block; }
.cm-item button { position: absolute; top: 6px; right: 6px; width: 28px; height: 28px; border-radius: 50%; border: 0; background: rgba(0, 0, 0, .65); color: #fff; display: grid; place-items: center; }
.cm-item button svg.i { width: 16px; height: 16px; }
.composer-bar { display: flex; align-items: center; gap: 4px; margin-top: 8px; padding-top: 10px; border-top: 1px solid var(--line); }
.tool { display: inline-flex; align-items: center; gap: 7px; height: 36px; padding: 0 12px; border-radius: 999px; border: 0; background: none; color: var(--text-2); font-weight: 700; font-size: 13.5px; cursor: pointer; position: relative; }
.tool:hover { background: var(--brand-soft); color: var(--brand-ink); }
.tool input[type=file] { position: absolute; inset: 0; opacity: 0; cursor: pointer; width: 100%; }
.tool svg.i { color: var(--brand-ink); }
.tool-select select { border: 0; background: transparent; font-weight: 700; color: inherit; cursor: pointer; padding: 0 2px; appearance: none; -webkit-appearance: none; }
.tool-select select option { background: var(--panel-2); color: var(--text); }
.tool[disabled], .composer[data-locked] .tool { opacity: .45; pointer-events: none; }
.composer-count { margin-left: auto; font-size: 12.5px; font-weight: 700; color: var(--text-3); }
.composer-count.warn { color: var(--warn); }
.composer-count.over { color: #ff6b6b; }
.composer-send { margin-left: auto; min-width: 84px; }
.composer-count:not([hidden]) + .composer-send { margin-left: 10px; }
.dlg-compose .composer { padding: 4px 18px 14px; }

/* ---------- posts ---------- */
.post-list { display: flex; flex-direction: column; gap: 12px; margin-top: 12px; }
.post { background: var(--panel); border: 1px solid var(--line); border-radius: var(--r-lg); padding: 14px 16px 6px; transition: border-color .2s ease; }
.post:target, .post.flash { border-color: var(--brand); }
.post-context { display: flex; align-items: center; gap: 8px; margin: -2px 0 10px 4px; font-size: 13px; font-weight: 700; color: var(--text-3); }
.post-context svg.i { width: 16px; height: 16px; color: var(--ok); }
.post-context a:hover { color: var(--text); text-decoration: underline; }
.post-context form { margin-left: auto; }
.post-head { display: flex; align-items: flex-start; gap: 12px; position: relative; }
.post-who { flex: 1; min-width: 0; padding-top: 1px; }
.post-name { display: flex; align-items: center; gap: 6px; flex-wrap: wrap; line-height: 1.25; }
.name { font-weight: 800; font-size: 15.5px; letter-spacing: -.01em; }
.name:hover { text-decoration: underline; }
.post-meta { display: flex; align-items: center; gap: 5px; color: var(--text-3); font-size: 13.5px; margin-top: 2px; flex-wrap: wrap; }
.post-meta a:hover { text-decoration: underline; color: var(--text-2); }
.post-meta .vis svg.i { width: 14px; height: 14px; }
.sep { opacity: .7; }
.post-menu { position: relative; }
.post-menu > summary { margin: -6px -8px 0 0; }
.post-body { margin: 10px 0 2px; font-size: 15.5px; line-height: 1.55; white-space: normal; overflow-wrap: anywhere; }
.post-body-big { font-size: 20px; line-height: 1.4; font-weight: 600; letter-spacing: -.01em; }
.post-body a.mention, .post-body a.tag, .bubble-text a.mention, .bubble-text a.tag { color: var(--brand-ink); font-weight: 700; }
.post-body a.ext, .bubble-text a.ext { color: var(--info); }
.post-body a:hover, .bubble-text a:hover { text-decoration: underline; }
.post-edit textarea { width: 100%; min-height: 90px; }
.post-edit-bar { display: flex; gap: 8px; justify-content: flex-end; margin-top: 8px; }

.media { display: grid; gap: 3px; margin: 12px -2px 4px; border-radius: var(--r); overflow: hidden; background: var(--panel-3); }
.media-1 { grid-template-columns: 1fr; }
.media-2 { grid-template-columns: 1fr 1fr; aspect-ratio: 16 / 10; }
.media-3 { grid-template-columns: 2fr 1fr; grid-template-rows: 1fr 1fr; aspect-ratio: 16 / 10; }
.media-3 .media-item:first-child { grid-row: span 2; }
.media-4 { grid-template-columns: 1fr 1fr; grid-template-rows: 1fr 1fr; aspect-ratio: 16 / 11; }
.media-item { display: block; overflow: hidden; background: #000; min-height: 0; }
.media-item img { display: block; width: 100%; height: 100%; object-fit: cover; transition: transform .35s ease, opacity .2s; }
.media-item:hover img { transform: scale(1.015); }
.media-1 .media-item img { height: auto; max-height: 640px; object-fit: contain; background: #000; }
.media-1 .media-item img.tall { max-height: 640px; width: auto; margin: 0 auto; }

.quote { display: block; margin: 12px 0 4px; padding: 12px 14px; border: 1px solid var(--line-2); border-radius: var(--r); transition: background-color .15s ease; }
.quote:hover { background: var(--hover); }
.quote-head { display: flex; align-items: center; gap: 7px; font-size: 13.5px; flex-wrap: wrap; }
.quote-body { display: block; margin-top: 6px; font-size: 14.5px; color: var(--text-2); white-space: pre-line; }
.quote-img { display: block; width: 100%; max-height: 300px; object-fit: cover; border-radius: var(--r-sm); margin-top: 10px; }
.quote-missing { color: var(--text-3); display: flex; align-items: center; gap: 8px; font-size: 14px; }

.post-stats { display: flex; align-items: center; justify-content: space-between; gap: 10px; min-height: 30px; margin-top: 8px; font-size: 13.5px; color: var(--text-3); }
.post-stats-right { display: flex; gap: 12px; margin-left: auto; }
.post-stats-right .link-btn { font-weight: 600; font-size: 13.5px; }
.react-sum { display: inline-flex; align-items: center; gap: 6px; border: 0; background: none; padding: 0; color: var(--text-3); font-weight: 600; font-size: 13.5px; }
.react-sum:hover { color: var(--text); text-decoration: underline; }
.react-stack { display: inline-flex; }
.rs { width: 22px; height: 22px; border-radius: 50%; background: var(--panel-2); border: 2px solid var(--panel); display: grid; place-items: center; font-size: 12px; margin-left: -6px; line-height: 1; }
.rs:first-child { margin-left: 0; }
.post-actions { display: flex; gap: 4px; border-top: 1px solid var(--line); padding-top: 4px; margin-top: 2px; }
.post-actions > *, .act-form { flex: 1; }
.act-form { display: flex; margin: 0; }
.act { width: 100%; display: inline-flex; align-items: center; justify-content: center; gap: 8px; height: 40px; border: 0; border-radius: var(--r-sm); background: none; color: var(--text-2); font-weight: 700; font-size: 14px; transition: background-color .15s ease, color .15s ease; user-select: none; -webkit-user-select: none; }
.act:hover { background: var(--hover); color: var(--text); }
.act svg.i { width: 19px; height: 19px; }
.act.on { color: var(--brand-ink); }
.act.on svg.i { fill: currentColor; }
.act-react.on svg.i { fill: none; }
.act-react.r1 { color: var(--info); }
.act-react.r2, .act-react.r6 { color: #ff4d6d; }
.act-react.r3, .act-react.r4, .act-react.r5 { color: var(--warn); }
.act-emoji { font-size: 18px; line-height: 1; display: inline-flex; }
.act-emoji.pop { animation: bump .35s ease; }
@keyframes bump { 40% { transform: scale(1.45) rotate(-8deg); } 100% { transform: none; } }
.react-wrap { position: relative; display: flex; }
.react-pick { position: absolute; z-index: 30; left: 0; bottom: calc(100% + 6px); display: flex; gap: 2px; padding: 6px; border-radius: 999px; background: var(--panel-2); border: 1px solid var(--line-2); box-shadow: var(--shadow); animation: pop .15s ease-out; }
.rp { width: 42px; height: 42px; border: 0; background: none; border-radius: 50%; font-size: 26px; line-height: 1; display: grid; place-items: center; transition: transform .12s ease; }
.rp:hover, .rp:focus-visible { transform: translateY(-5px) scale(1.25); }

/* ---------- comments ---------- */
.post-thread { border-top: 1px solid var(--line); margin-top: 4px; padding: 10px 0 8px; }
.comment-list { display: flex; flex-direction: column; gap: 10px; }
.comment { display: flex; gap: 9px; align-items: flex-start; }
.comment.flash .bubble { box-shadow: 0 0 0 2px var(--brand); }
.comment-main { flex: 1; min-width: 0; }
.bubble { position: relative; display: inline-block; max-width: 100%; padding: 8px 13px 9px; border-radius: 18px; background: var(--panel-3); }
.bubble-name { font-size: 13.5px; line-height: 1.3; }
.bubble-name .name { font-size: 13.5px; }
.bubble-text { font-size: 14.5px; line-height: 1.45; overflow-wrap: anywhere; }
.bubble-likes { position: absolute; right: -8px; bottom: -9px; display: inline-flex; align-items: center; gap: 3px; padding: 1px 7px 1px 5px; border-radius: 999px; background: var(--panel-2); border: 1px solid var(--line-2); font-size: 11.5px; font-weight: 700; box-shadow: var(--shadow-sm); }
.bubble-likes svg.i { width: 13px; height: 13px; fill: #ff4d6d; stroke: #ff4d6d; }
.comment-acts { display: flex; align-items: center; gap: 12px; padding: 4px 12px 0; font-size: 12.5px; color: var(--text-3); }
.comment-acts time { font-weight: 600; }
.replies { display: flex; flex-direction: column; gap: 8px; margin-top: 8px; }
.replies:empty { display: none; }
.comment-form { display: flex; align-items: flex-end; gap: 9px; margin-top: 12px; }
.comment-input { flex: 1; min-width: 0; background: var(--panel-3); border-radius: 20px; padding: 0 14px; }
.comment-input textarea { width: 100%; resize: none; border: 0; outline: 0; background: transparent; padding: 9px 0; font-size: 14.5px; line-height: 1.4; max-height: 160px; display: block; }
.replying { display: flex; gap: 8px; align-items: center; padding-top: 7px; font-size: 12px; color: var(--text-3); font-weight: 600; }
.replying b { color: var(--brand-ink); }
.send { color: var(--brand-ink); }
.send:hover { background: var(--brand-soft); color: var(--brand-ink); }
.send[disabled] { opacity: .4; }

/* ---------- empty states & more ---------- */
.empty { text-align: center; padding: 56px 24px; }
.empty-small { padding: 36px 20px; }
.empty-art { width: 76px; height: 76px; margin: 0 auto 16px; border-radius: 26px; display: grid; place-items: center; background: var(--brand-soft); color: var(--brand-ink); transform: rotate(-6deg); }
.empty-art svg.i { width: 34px; height: 34px; transform: rotate(6deg); }
.empty h2 { font-size: 20px; font-weight: 800; letter-spacing: -.02em; margin-bottom: 6px; }
.empty p { color: var(--text-3); max-width: 380px; margin: 0 auto; }
.empty-acts { display: flex; gap: 10px; justify-content: center; flex-wrap: wrap; margin-top: 18px; }
.empty-mini { padding: 24px; text-align: center; color: var(--text-3); }
.more { display: block; margin: 14px; padding: 13px; text-align: center; font-weight: 700; color: var(--brand-ink); border-radius: var(--r); background: var(--panel); border: 1px solid var(--line); }
.more:hover { background: var(--panel-2); }
.more.loading { opacity: .6; pointer-events: none; }
.end-note { text-align: center; color: var(--text-3); padding: 26px; font-size: 13.5px; font-weight: 600; }

/* ---------- right column widgets ---------- */
.side-search { position: sticky; top: 0; z-index: 5; display: flex; align-items: center; gap: 10px; height: 46px; margin-bottom: 14px; padding: 0 16px; border-radius: 999px; background: var(--panel-2); border: 1px solid var(--line); color: var(--text-3); }
.side-search:focus-within { border-color: var(--brand); background: var(--panel); color: var(--brand-ink); }
.side-search input { flex: 1; border: 0; outline: 0; background: transparent; min-width: 0; color: var(--text); }
.widget { background: var(--panel); border: 1px solid var(--line); border-radius: var(--r-lg); padding: 14px 6px 8px; margin-bottom: 14px; }
.widget-title { display: flex; align-items: center; gap: 10px; font-size: 16px; font-weight: 800; letter-spacing: -.01em; padding: 0 10px 10px; }
.widget-more { margin-left: auto; font-size: 13px; font-weight: 700; color: var(--brand-ink); }
.widget-more:hover { text-decoration: underline; }
.wt-ic { width: 30px; height: 30px; border-radius: 10px; display: grid; place-items: center; color: #fff; flex: none; }
.wt-ic svg.i { width: 17px; height: 17px; stroke-width: 2.2; }
.wt-trend { background: linear-gradient(135deg, #7b5cff, #3d8bff); }
.wt-hot { background: var(--grad); }
.wt-people { background: linear-gradient(135deg, #00b894, #2fd27a); }
.wt-pages { background: linear-gradient(135deg, #f6b23c, #ff6a2b); }
.trend-list { list-style: none; margin: 0; padding: 0; }
.trend-list a { display: flex; align-items: center; gap: 12px; padding: 8px 10px; border-radius: var(--r-sm); }
.trend-list a:hover { background: var(--hover); }
.trend-rank { width: 22px; text-align: center; font-weight: 800; color: var(--text-3); font-size: 13px; }
.trend-text { display: flex; flex-direction: column; line-height: 1.3; min-width: 0; }
.trend-text b { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.trend-text small { color: var(--text-3); font-size: 12.5px; }
.hot-list { display: flex; flex-direction: column; gap: 2px; }
.hot-item { display: flex; gap: 12px; padding: 8px 10px; border-radius: var(--r-sm); align-items: center; }
.hot-item:hover { background: var(--hover); }
.hot-thumb { width: 54px; height: 54px; border-radius: 12px; object-fit: cover; flex: none; background: var(--panel-3); }
.hot-text { display: grid; place-items: center; color: var(--text-3); }
.hot-meta { display: flex; flex-direction: column; min-width: 0; line-height: 1.3; }
.hot-meta b { font-size: 14px; }
.hot-snip { color: var(--text-2); font-size: 13px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.hot-meta small { color: var(--text-3); font-size: 12px; margin-top: 2px; }
.people-list { list-style: none; margin: 0; padding: 0; }
.person-row { display: flex; align-items: center; gap: 11px; padding: 8px 10px; border-radius: var(--r-sm); }
a.person-row:hover, .person-row:hover { background: var(--hover); }
.person-link { display: flex; align-items: center; gap: 11px; flex: 1; min-width: 0; }
.person-text { display: flex; flex-direction: column; min-width: 0; line-height: 1.3; flex: 1; }
.person-text b, .person-text small { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.person-text small { color: var(--text-3); font-size: 12.5px; }
.person-bio { color: var(--text-2); font-size: 13.5px; margin-top: 3px; }
.person-row form { margin: 0; }
.person-row-big { padding: 12px 16px; border-radius: 0; }
.list-card { overflow: hidden; }
.list-card .person-row-big + .person-row-big { border-top: 1px solid var(--line); }
.av-wrap { position: relative; }
.av-react { position: absolute; right: -4px; bottom: -4px; font-size: 14px; }
.side-foot { display: flex; flex-direction: column; gap: 6px; padding: 4px 12px; font-size: 12px; color: var(--text-3); }
.side-foot a:hover { text-decoration: underline; color: var(--text-2); }

/* ---------- profile ---------- */
.profile { background: var(--panel); border-bottom: 1px solid var(--line); }
.cover { position: relative; aspect-ratio: 3 / 1; background: var(--panel-3); overflow: hidden; }
.cover img { width: 100%; height: 100%; object-fit: cover; display: block; }
.cover-none { background: radial-gradient(120% 140% at 0% 0%, rgba(139, 92, 246, .55), transparent 55%), radial-gradient(120% 140% at 100% 100%, rgba(255, 61, 119, .45), transparent 55%), linear-gradient(135deg, #1f1433, #1c1a28 60%, #2b1520); }
[data-theme="light"] .cover-none { background: radial-gradient(120% 140% at 0% 0%, rgba(255, 61, 119, .35), transparent 55%), radial-gradient(120% 140% at 100% 100%, rgba(255, 61, 119, .3), transparent 55%), linear-gradient(135deg, #efe7ff, #ffe6ef); }
.cover-edit { position: absolute; right: 14px; bottom: 14px; display: inline-flex; align-items: center; gap: 8px; padding: 8px 14px; border-radius: 999px; background: rgba(0, 0, 0, .55); color: #fff; font-weight: 700; font-size: 13px; backdrop-filter: blur(8px); }
.cover-edit:hover { background: rgba(0, 0, 0, .75); }
.profile-bar { display: flex; align-items: flex-end; gap: 18px; padding: 0 22px 16px; flex-wrap: wrap; }
.profile-av { margin-top: -74px; flex: none; }
.story-ring-big { padding: 4px; }
.story-ring-big > .av { border-width: 5px; border-color: var(--panel); }
.profile-id { flex: 1; min-width: 220px; padding-bottom: 4px; }
.profile-id h1 { font-size: 28px; font-weight: 800; letter-spacing: -.03em; display: flex; align-items: center; gap: 2px; flex-wrap: wrap; }
.profile-id h1 .verified svg.i { width: 24px; height: 24px; }
.profile-handle { color: var(--text-3); font-weight: 600; margin-top: 2px; }
.profile-counts { display: flex; gap: 16px; margin-top: 8px; font-size: 14px; color: var(--text-3); flex-wrap: wrap; }
.profile-counts b { color: var(--text); font-weight: 800; }
.profile-counts a:hover { text-decoration: underline; }
.profile-acts { display: flex; align-items: center; gap: 8px; padding-bottom: 6px; flex-wrap: wrap; }
.profile-acts form { margin: 0; }
.profile .notice { margin: 0 22px 14px; }
.profile-tabs { padding: 0 12px; border-bottom: 0; border-top: 1px solid var(--line); }
.profile-tabs a { flex: 0 1 auto; }
.profile-grid { display: grid; grid-template-columns: 340px 1fr; gap: 16px; padding: 16px 14px; align-items: start; }
.profile-grid-full { display: block; }
.profile-side { display: flex; flex-direction: column; gap: 14px; position: sticky; top: 14px; }
.profile-side .card { padding-bottom: 14px; }
.profile-main .post-list { margin-top: 12px; }
.profile-main .composer-card { margin: 0; }
.intro { padding: 16px; }
.intro h3 { font-size: 18px; font-weight: 800; margin-bottom: 10px; }
.intro-bio { text-align: center; padding: 4px 4px 14px; margin-bottom: 12px; border-bottom: 1px solid var(--line); font-size: 15px; }
.facts { list-style: none; margin: 0 0 12px; padding: 0; display: flex; flex-direction: column; gap: 12px; font-size: 14.5px; }
.facts li { display: flex; align-items: center; gap: 12px; color: var(--text-2); }
.facts li svg.i { color: var(--text-3); }
.facts li a { color: var(--info); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.facts b { color: var(--text); }
.photo-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 4px; }
.photo-grid a { aspect-ratio: 1; overflow: hidden; background: var(--panel-3); border-radius: 6px; }
.photo-grid img { width: 100%; height: 100%; object-fit: cover; display: block; transition: transform .3s ease; }
.photo-grid a:hover img { transform: scale(1.05); }
.photo-grid-mini { padding: 0 14px; border-radius: var(--r); overflow: hidden; }
.friend-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 12px 8px; padding: 0 14px; }
.friend-grid a { display: flex; flex-direction: column; gap: 6px; align-items: center; text-align: center; font-size: 12.5px; font-weight: 700; }
.friend-grid a span { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; max-width: 100%; }
.friend-grid .av { width: 100%; height: auto; aspect-ratio: 1; border-radius: var(--r); }
.friend-grid .av-ini { font-size: 22px; }

/* ---------- people / page cards ---------- */
.card-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(180px, 1fr)); gap: 12px; margin-top: 12px; }
.pcard { background: var(--panel); border: 1px solid var(--line); border-radius: var(--r-lg); padding: 18px 14px 14px; display: flex; flex-direction: column; gap: 14px; text-align: center; }
.pcard-top { display: flex; flex-direction: column; align-items: center; gap: 4px; min-width: 0; }
.pcard-top .av { margin-bottom: 8px; }
.pcard-name { font-weight: 800; max-width: 100%; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.pcard-top small { color: var(--text-3); font-size: 12.5px; }
.pcard-acts { display: flex; flex-direction: column; gap: 6px; margin-top: auto; }
.pcard-acts form { margin: 0; }
.pcard.gone { opacity: .45; pointer-events: none; }
.pgcard { background: var(--panel); border: 1px solid var(--line); border-radius: var(--r-lg); overflow: hidden; display: flex; flex-direction: column; }
.pgcard-cover { display: block; aspect-ratio: 3 / 1; background: var(--panel-3); }
.pgcard-cover img { width: 100%; height: 100%; object-fit: cover; display: block; }
.pgcard-body { display: flex; flex-direction: column; align-items: center; gap: 2px; text-align: center; padding: 0 12px 12px; margin-top: -30px; }
.pgcard-body .av { border: 4px solid var(--panel); box-sizing: content-box; margin-bottom: 6px; }
.pgcard-body small { color: var(--text-3); font-size: 12.5px; }
.pgcard-acts { padding: 0 12px 14px; margin-top: auto; }
.pgcard-acts form { margin: 0; }

/* ---------- notifications ---------- */
.notif-list { overflow: hidden; }
.notif { display: flex; align-items: center; gap: 14px; padding: 14px 16px; position: relative; }
.notif + .notif { border-top: 1px solid var(--line); }
.notif:hover { background: var(--hover); }
.notif.unread { background: rgba(255, 61, 119, .06); }
[data-theme="light"] .notif.unread { background: rgba(232, 51, 109, .045); }
.notif.unread::before { content: ""; position: absolute; left: 6px; top: 50%; width: 6px; height: 6px; margin-top: -3px; border-radius: 50%; background: var(--brand); }
.notif-av { position: relative; flex: none; }
.notif-ic { position: absolute; right: -5px; bottom: -5px; width: 24px; height: 24px; border-radius: 50%; display: grid; place-items: center; color: #fff; border: 2px solid var(--panel); }
.notif-ic svg.i { width: 13px; height: 13px; stroke-width: 2.6; }
.n-react { background: #ff4d6d; } .n-comment { background: #2fd27a; } .n-mention { background: #3d8bff; }
.n-follow { background: #7b5cff; } .n-friend { background: #ff6a2b; } .n-repost { background: #14b8a6; }
.notif-text { flex: 1; min-width: 0; font-size: 14.5px; line-height: 1.4; }
.notif-text small { display: block; color: var(--text-3); font-size: 12.5px; font-weight: 600; margin-top: 2px; }
.notif-thumb { width: 52px; height: 52px; border-radius: 10px; object-fit: cover; flex: none; }

/* ---------- search ---------- */
.search-big { display: flex; align-items: center; gap: 12px; height: 54px; padding: 0 18px; margin-top: 6px; border-radius: 999px; background: var(--panel-2); border: 1px solid var(--line); color: var(--text-3); }
.search-big:focus-within { border-color: var(--brand); color: var(--brand-ink); }
.search-big input { flex: 1; border: 0; outline: 0; background: transparent; font-size: 16px; color: var(--text); min-width: 0; }
.main > .tabs { margin-top: 10px; }
.tag-cloud { display: flex; flex-wrap: wrap; gap: 8px; }
.tag-chip { display: inline-flex; align-items: center; gap: 8px; padding: 9px 14px; border-radius: 999px; background: var(--panel); border: 1px solid var(--line); font-weight: 800; }
.tag-chip small { color: var(--text-3); font-weight: 700; }
.tag-chip:hover { border-color: var(--brand); color: var(--brand-ink); }

/* ---------- forms ---------- */
.form-card { padding: 20px; }
.form-card h2 { font-size: 18px; font-weight: 800; margin-bottom: 6px; }
.form-card > p { margin-bottom: 16px; }
.form { display: flex; flex-direction: column; gap: 16px; margin-top: 14px; }
.field { display: flex; flex-direction: column; gap: 7px; flex: 1; min-width: 0; }
.field > span { font-weight: 700; font-size: 13.5px; color: var(--text-2); }
.field small { color: var(--text-3); font-size: 12.5px; }
.field-row { display: flex; gap: 14px; flex-wrap: wrap; }
.input { width: 100%; padding: 12px 14px; border-radius: var(--r-sm); border: 1px solid var(--line-2); background: var(--panel-2); color: var(--text); outline: 0; transition: border-color .15s ease, box-shadow .15s ease; }
.input:focus { border-color: var(--brand); box-shadow: 0 0 0 3px var(--brand-soft); }
textarea.input { resize: vertical; min-height: 44px; line-height: 1.45; }
select.input { appearance: none; -webkit-appearance: none; background-image: linear-gradient(45deg, transparent 50%, var(--text-3) 50%), linear-gradient(135deg, var(--text-3) 50%, transparent 50%); background-position: calc(100% - 20px) 50%, calc(100% - 14px) 50%; background-size: 6px 6px; background-repeat: no-repeat; padding-right: 36px; }
select.input option { background: var(--panel-2); }
.input-static { color: var(--text-2); }
.input-prefix { display: flex; align-items: center; border: 1px solid var(--line-2); border-radius: var(--r-sm); background: var(--panel-2); padding-left: 14px; }
.input-prefix:focus-within { border-color: var(--brand); box-shadow: 0 0 0 3px var(--brand-soft); }
.input-prefix b { color: var(--text-3); }
.input-prefix .input { border: 0; background: transparent; box-shadow: none; padding-left: 4px; }
.radio-list { display: flex; flex-direction: column; gap: 4px; margin: 12px 0; }
.radio { display: flex; align-items: center; gap: 12px; padding: 10px 12px; border-radius: var(--r-sm); cursor: pointer; font-weight: 600; }
.radio:hover { background: var(--hover); }
.radio input { accent-color: var(--brand); width: 18px; height: 18px; }
.pic-edit .cover { border-radius: var(--r); margin-top: 12px; }
.pic-row { display: flex; gap: 18px; align-items: flex-end; padding: 0 14px; flex-wrap: wrap; }
.pic-av { margin-top: -56px; }
.pic-av .av { border: 5px solid var(--panel); box-sizing: content-box; width: 110px; height: 110px; }
.pic-forms { display: flex; flex-direction: column; gap: 10px; flex: 1; min-width: 220px; padding-top: 12px; }
.pic-forms form { display: flex; gap: 8px; flex-wrap: wrap; margin: 0; }
.danger-zone { border-color: rgba(255, 59, 59, .25); }
.danger-zone form { margin-top: 14px; }

/* ---------- dialogs ---------- */
dialog { border: 0; padding: 0; color: var(--text); }
dialog::backdrop { background: rgba(5, 6, 9, .72); backdrop-filter: blur(3px); }
.dlg { width: min(560px, calc(100vw - 24px)); max-height: calc(100vh - 40px); background: var(--panel); border: 1px solid var(--line-2); border-radius: var(--r-xl); box-shadow: var(--shadow); overflow: auto; }
.dlg[open] { animation: rise .2s ease-out; }
@keyframes rise { from { opacity: 0; transform: translateY(14px) scale(.98); } to { opacity: 1; transform: none; } }
.dlg-head { display: flex; align-items: center; justify-content: space-between; padding: 14px 14px 10px 20px; border-bottom: 1px solid var(--line); position: sticky; top: 0; background: var(--panel); z-index: 2; }
.dlg-head h2 { font-size: 17px; font-weight: 800; }
.dlg form:not(.composer) { padding: 16px 20px 20px; display: flex; flex-direction: column; gap: 12px; }
.dlg-body { padding: 8px; max-height: 60vh; overflow: auto; }
.dlg-list { width: min(420px, calc(100vw - 24px)); }
.share-who { display: flex; align-items: center; gap: 10px; }
.share-text { min-height: 70px; }
.share-preview .post { pointer-events: none; padding-bottom: 12px; }
.share-preview .post-actions, .share-preview .post-stats, .share-preview .post-menu, .share-preview .post-thread, .share-preview .post-context { display: none; }
.story-drop { position: relative; display: grid; place-items: center; min-height: 280px; border: 2px dashed var(--line-2); border-radius: var(--r-lg); overflow: hidden; cursor: pointer; background: var(--panel-2); }
.story-drop:hover { border-color: var(--brand); }
.story-drop input { position: absolute; inset: 0; opacity: 0; cursor: pointer; }
.story-drop img { max-height: 420px; width: 100%; object-fit: contain; background: #000; }
.story-drop-hint { display: flex; flex-direction: column; align-items: center; gap: 4px; color: var(--text-3); text-align: center; padding: 20px; }
.story-drop-hint svg.i { width: 36px; height: 36px; color: var(--brand-ink); margin-bottom: 8px; }
.story-drop-hint b { color: var(--text); }
.lightbox { width: 100vw; height: 100vh; max-width: 100vw; max-height: 100vh; background: rgba(0, 0, 0, .94); display: none; }
.lightbox[open] { display: grid; place-items: center; }
.lightbox img { max-width: 94vw; max-height: 92vh; object-fit: contain; border-radius: 6px; }
.lightbox .icon-btn { position: fixed; background: rgba(255, 255, 255, .12); color: #fff; width: 46px; height: 46px; }
.lb-close { top: 16px; right: 16px; }
.lb-prev { left: 16px; top: 50%; margin-top: -23px; }
.lb-next { right: 16px; top: 50%; margin-top: -23px; }

/* ---------- toasts ---------- */
.toasts { position: fixed; z-index: 100; left: 50%; bottom: 24px; transform: translateX(-50%); display: flex; flex-direction: column; gap: 8px; align-items: center; pointer-events: none; width: max-content; max-width: calc(100vw - 32px); }
.toast { pointer-events: auto; padding: 12px 18px; border-radius: 999px; background: var(--text); color: var(--bg); font-weight: 700; font-size: 14px; box-shadow: var(--shadow); animation: rise .22s ease-out; text-align: center; }
.toast-error { background: #ff4d4d; color: #fff; }
.toast.out { opacity: 0; transform: translateY(8px); transition: opacity .3s ease, transform .3s ease; }

/* ---------- mention suggestions ---------- */
.mention-box { position: absolute; z-index: 120; min-width: 240px; padding: 6px; background: var(--panel-2); border: 1px solid var(--line-2); border-radius: var(--r); box-shadow: var(--shadow); }
.mention-box button { width: 100%; display: flex; align-items: center; gap: 10px; padding: 8px 10px; border: 0; border-radius: var(--r-sm); background: none; text-align: left; }
.mention-box button.on, .mention-box button:hover { background: var(--hover); }
.mention-box small { color: var(--text-3); display: block; font-size: 12px; }

/* ---------- moderation ---------- */
.report-list { display: flex; flex-direction: column; gap: 12px; }
.report { padding: 14px 16px; }
.report-head { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; }
.report-target { display: flex; gap: 12px; margin: 12px 0; padding: 12px; border-radius: var(--r); background: var(--panel-2); }
.report-body { margin-top: 6px; color: var(--text-2); font-size: 14px; }
.report-thumb { display: block; max-width: 220px; max-height: 160px; border-radius: 10px; margin-top: 8px; object-fit: cover; }
.report-acts { display: flex; gap: 8px; flex-wrap: wrap; }
.report-acts form { margin: 0; }
.table-card { margin: 0 14px; overflow-x: auto; }
.table { width: 100%; border-collapse: collapse; font-size: 13.5px; }
.table th, .table td { text-align: left; padding: 10px 14px; border-bottom: 1px solid var(--line); white-space: nowrap; }
.table th { color: var(--text-3); font-size: 12px; text-transform: uppercase; letter-spacing: .05em; }
.table tr:last-child td { border-bottom: 0; }

/* ---------- character picker, plain pages ---------- */
.bare { min-height: 100vh; }
.choose { min-height: 100vh; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 26px; padding: 30px 16px; background: radial-gradient(60% 50% at 50% 0%, rgba(139, 92, 246, .16), transparent 70%); }
.choose-card { width: min(460px, 100%); background: var(--panel); border: 1px solid var(--line); border-radius: var(--r-xl); padding: 28px 22px 18px; box-shadow: var(--shadow); text-align: center; }
.choose-card h1 { font-size: 24px; font-weight: 800; letter-spacing: -.03em; margin-bottom: 6px; }
.choose-list { display: flex; flex-direction: column; gap: 8px; margin: 22px 0 10px; text-align: left; }
.choose-list form { margin: 0; }
.choose-item { width: 100%; display: flex; align-items: center; gap: 14px; padding: 12px 14px; border-radius: var(--r-lg); border: 1px solid var(--line); background: var(--panel-2); transition: border-color .15s ease, transform .15s ease, background-color .15s ease; }
.choose-item:hover { border-color: var(--brand); transform: translateY(-1px); background: var(--panel-3); }
.choose-item.on { border-color: var(--brand); }
.choose-item svg.i { color: var(--text-3); }
.choose-text { flex: 1; display: flex; flex-direction: column; line-height: 1.3; text-align: left; }
.choose-text b { font-size: 16px; }
.choose-text small { color: var(--text-3); }
.choose-foot { display: flex; justify-content: space-between; align-items: center; gap: 10px; padding-top: 12px; border-top: 1px solid var(--line); margin-top: 10px; }
.choose-foot form { margin: 0; }
.plain-card { display: flex; flex-direction: column; gap: 14px; align-items: center; }

/* ---------- landing ---------- */
.landing { min-height: 100vh; overflow-x: hidden; position: relative; display: flex; flex-direction: column; }
.land-glow { position: fixed; width: 60vw; height: 60vw; border-radius: 50%; filter: blur(90px); opacity: .32; pointer-events: none; z-index: 0; }
.land-glow-1 { background: #8b5cf6; left: -20vw; top: -25vw; }
.land-glow-2 { background: #ff3d77; right: -25vw; bottom: -30vw; opacity: .22; }
[data-theme="light"] .land-glow { opacity: .16; }
.land { position: relative; z-index: 1; flex: 1; display: grid; grid-template-columns: 1.05fr 1fr; gap: 56px; align-items: center; max-width: 1180px; width: 100%; margin: 0 auto; padding: 48px 28px 24px; }
.logo-big .logo-mark { width: 48px; height: 48px; border-radius: 15px; font-size: 25px; }
.logo-big .logo-word { font-size: 30px; }
.land-copy h1 { font-size: clamp(40px, 6vw, 68px); line-height: 1.02; font-weight: 800; letter-spacing: -.045em; margin: 34px 0 20px; }
.land-sub { font-size: 18px; color: var(--text-2); max-width: 520px; line-height: 1.6; }
.land-points { list-style: none; padding: 0; margin: 28px 0 0; display: flex; flex-direction: column; gap: 12px; }
.land-points li { display: flex; align-items: center; gap: 12px; font-weight: 700; color: var(--text-2); }
.land-points svg.i { width: 34px; height: 34px; padding: 7px; border-radius: 11px; background: var(--brand-soft); color: var(--brand-ink); }
.land-side { position: relative; display: flex; align-items: center; justify-content: center; min-height: 560px; }
.land-card { position: relative; z-index: 2; width: min(400px, 100%); margin-left: 120px; padding: 30px 26px 24px; border-radius: var(--r-xl); background: color-mix(in srgb, var(--panel) 88%, transparent); border: 1px solid var(--line-2); backdrop-filter: blur(18px); box-shadow: var(--shadow); }
@supports not (background: color-mix(in srgb, red 50%, transparent)) { .land-card { background: var(--panel); } }
.land-card h2 { font-size: 26px; font-weight: 800; letter-spacing: -.03em; margin-bottom: 8px; }
.land-card > p.muted { margin-bottom: 22px; }
.cali-badge { width: 26px; height: 26px; border-radius: 8px; background: rgba(255, 255, 255, .22); display: grid; place-items: center; font-size: 11px; font-weight: 800; letter-spacing: -.02em; }
.land-small { margin-top: 18px; font-size: 13px; color: var(--text-3); text-align: center; }
.land-small a { color: var(--brand-ink); font-weight: 700; }
.land-foot { position: relative; z-index: 1; display: flex; justify-content: space-between; gap: 12px; flex-wrap: wrap; max-width: 1180px; width: 100%; margin: 0 auto; padding: 20px 28px 26px; color: var(--text-3); font-size: 13px; }
.land-foot a:hover { color: var(--text); }
.phone { position: absolute; left: 0; top: 50%; transform: translateY(-50%) rotate(-7deg); width: 250px; height: 500px; border-radius: 40px; background: #0d0e12; border: 8px solid #1d1f26; box-shadow: 0 30px 80px rgba(0, 0, 0, .55); padding: 30px 14px 14px; display: flex; flex-direction: column; gap: 12px; overflow: hidden; }
[data-theme="light"] .phone { background: #fff; border-color: #e6e7ec; box-shadow: 0 30px 80px rgba(30, 30, 60, .2); }
.phone-notch { position: absolute; top: 8px; left: 50%; width: 80px; height: 18px; margin-left: -40px; border-radius: 12px; background: #1d1f26; }
[data-theme="light"] .phone-notch { background: #e6e7ec; }
.phone-top { display: flex; justify-content: space-between; align-items: center; }
.phone-dots { display: flex; gap: 6px; }
.phone-dots i { width: 22px; height: 22px; border-radius: 50%; background: var(--panel-3); }
.phone-stories { display: flex; gap: 8px; }
.ps { width: 38px; height: 38px; border-radius: 50%; padding: 2px; background: var(--grad-ring); display: block; position: relative; }
.ps::after { content: ""; position: absolute; inset: 3px; border-radius: 50%; border: 2px solid #0d0e12; }
.ps1::after { background: linear-gradient(135deg, #7b5cff, #3d8bff); } .ps2::after { background: linear-gradient(135deg, #00b894, #2fd27a); }
.ps3::after { background: linear-gradient(135deg, #f6b23c, #ff6a2b); } .ps4::after { background: linear-gradient(135deg, #e84393, #a855f7); }
.ps5::after { background: linear-gradient(135deg, #0ea5e9, #14b8a6); }
.phone-post { border-radius: 16px; background: var(--panel-2); padding: 10px; display: flex; flex-direction: column; gap: 8px; }
.pp-head { display: flex; align-items: center; gap: 8px; }
.pp-head span { display: flex; flex-direction: column; gap: 4px; }
.pp-head b { width: 70px; height: 7px; border-radius: 4px; background: var(--text-3); opacity: .7; }
.pp-head small { width: 44px; height: 6px; border-radius: 4px; background: var(--line-2); }
.pp-av { width: 26px; height: 26px; border-radius: 50%; display: block; }
.pp-av1 { background: linear-gradient(135deg, #8b5cf6, #ff3d77); } .pp-av2 { background: linear-gradient(135deg, #7b5cff, #3d8bff); }
.pp-pic { height: 150px; border-radius: 12px; position: relative; overflow: hidden; background: linear-gradient(180deg, #ff7a59 0%, #ffb35c 45%, #6a3d8f 100%); }
.pp-sun { position: absolute; left: 50%; top: 48px; width: 64px; height: 64px; margin-left: -32px; border-radius: 50%; background: #ffe2a0; box-shadow: 0 0 40px #ffcf7a; }
.pp-hills { position: absolute; left: -10%; right: -10%; bottom: -30px; height: 80px; border-radius: 50% 50% 0 0; background: #2a1838; }
.pp-acts { display: flex; align-items: center; gap: 8px; font-size: 13px; }
.pp-line { flex: 1; height: 6px; border-radius: 4px; background: var(--line-2); }
.pp-lines { display: flex; flex-direction: column; gap: 6px; }
.pp-lines i { height: 7px; border-radius: 4px; background: var(--line-2); }
.pp-lines i.short { width: 60%; }

/* ---------- story viewer ---------- */
.story-view { position: fixed; inset: 0; background: #050507; display: grid; place-items: center; }
.story-frame { position: relative; height: 100vh; max-height: 100vh; aspect-ratio: 9 / 16; max-width: 100vw; background: #000; overflow: hidden; }
@media (min-width: 700px) { .story-frame { height: calc(100vh - 40px); border-radius: 18px; } }
.story-bars { position: absolute; z-index: 5; top: 10px; left: 10px; right: 10px; display: flex; gap: 4px; }
.story-bar { flex: 1; height: 3px; border-radius: 3px; background: rgba(255, 255, 255, .3); overflow: hidden; }
.story-bar i { display: block; height: 100%; width: 0; background: #fff; }
.story-bar.done i { width: 100%; }
.story-top { position: absolute; z-index: 6; top: 22px; left: 12px; right: 12px; display: flex; align-items: center; justify-content: space-between; color: #fff; }
.story-who { display: flex; align-items: center; gap: 9px; font-size: 14px; text-shadow: 0 1px 4px rgba(0, 0, 0, .6); }
.story-who small { opacity: .8; font-weight: 600; }
.story-tools { display: flex; gap: 6px; }
.when-paused { display: none; }
.paused .when-paused { display: inline; }
.paused .when-playing { display: none; }
.story-slide { position: absolute; inset: 0; margin: 0; display: grid; place-items: center; }
.story-slide img { width: 100%; height: 100%; object-fit: contain; }
.story-slide figcaption { position: absolute; left: 16px; right: 16px; bottom: 80px; text-align: center; color: #fff; font-weight: 700; font-size: 17px; text-shadow: 0 2px 10px rgba(0, 0, 0, .8); }
.story-tap { position: absolute; z-index: 4; top: 70px; bottom: 70px; width: 35%; border: 0; background: transparent; }
.story-tap-prev { left: 0; }
.story-tap-next { right: 0; width: 65%; }
.story-foot { position: absolute; z-index: 6; left: 12px; right: 12px; bottom: 16px; display: flex; gap: 8px; justify-content: center; }
.story-foot form { margin: 0; }
.pill-glass.liked { background: var(--grad); }

/* ---------- responsive ---------- */
@media (max-width: 1279px) {
  :root { --rail: 82px; }
  .rail { align-items: center; }
  .rail .logo { padding: 4px 0 18px; }
  .rail .logo-word, .rail-label, .me-who, .me-more { display: none; }
  .rail-nav a { width: 54px; justify-content: center; padding: 0; }
  .btn-post { width: 54px; height: 54px; padding: 0; }
  .btn-post span { display: none; }
  .btn-post svg.i { display: block; width: 24px; height: 24px; }
  .me-menu > summary { padding: 6px; }
}
@media (max-width: 1099px) {
  .side { display: none; }
  .wide .main, .main { width: min(720px, 100%); flex: 1; border-right: 0; }
  .profile-grid { grid-template-columns: 1fr; }
  .profile-side { position: static; }
}
@media (max-width: 899px) {
  .profile-grid { display: block; }
  .profile-side { margin-bottom: 12px; }
  .land { grid-template-columns: 1fr; gap: 28px; padding-top: 32px; }
  .land-side { min-height: 0; }
  .phone { display: none; }
  .land-card { margin-left: 0; }
}
@media (max-width: 699px) {
  body.app { padding-bottom: calc(64px + env(safe-area-inset-bottom)); }
  .shell { display: block; padding: 0; }
  .rail { display: none; }
  .main { width: 100%; border: 0; padding-bottom: 20px; }
  .topbar { display: flex; align-items: center; justify-content: space-between; padding: 10px 12px 6px 14px; }
  .topbar .logo-mark { width: 32px; height: 32px; font-size: 17px; border-radius: 10px; }
  .topbar .logo-word { font-size: 20px; }
  .topbar-actions { display: flex; gap: 2px; }
  .topbar .dot-count, .tabbar .dot-count { min-width: 14px; height: 16px; padding: 0 4px; font-size: 10px; line-height: 16px; top: 3px; right: 2px; }
  .feed-head, .page-head { top: 0; }
  .tabbar { position: fixed; z-index: 50; left: 0; right: 0; bottom: 0; display: flex; justify-content: space-around; align-items: center; height: calc(60px + env(safe-area-inset-bottom)); padding-bottom: env(safe-area-inset-bottom); background: color-mix(in srgb, var(--panel) 92%, transparent); backdrop-filter: blur(16px); -webkit-backdrop-filter: blur(16px); border-top: 1px solid var(--line); }
  @supports not (background: color-mix(in srgb, red 50%, transparent)) { .tabbar { background: var(--panel); } }
  .tabbar a, .tabbar button { position: relative; width: 52px; height: 46px; display: grid; place-items: center; border: 0; background: none; color: var(--text-2); }
  .tabbar a.on { color: var(--text); }
  .tabbar a.on svg.i { stroke-width: 2.5; }
  .tabbar svg.i { width: 26px; height: 26px; }
  .tabbar .dot-count { right: 6px; }
  .tabbar .tab-new { width: 46px; height: 36px; border-radius: 12px; background: var(--grad); color: #fff; }
  .tabbar .tab-new svg.i { width: 22px; height: 22px; stroke-width: 2.6; }
  .tabbar .av { box-shadow: 0 0 0 2px transparent; }
  .tabbar a.on .av { box-shadow: 0 0 0 2px var(--text); }
  .main > .card, .main > .card-grid, .main > .post-list, .main > .empty, .main > .notice, .main > .tag-cloud, .main > .search-big, .main > .report-list, .main > .stories { margin-left: 8px; margin-right: 8px; }
  .post-list { gap: 8px; margin-top: 8px; }
  .post { border-radius: var(--r); padding: 12px 12px 4px; }
  .post-body-big { font-size: 18px; }
  .act span:not(.act-emoji) { display: none; }
  .act { height: 42px; }
  .act-react span[data-react-label] { display: none; }
  .composer-text { font-size: 16.5px; }
  .tool span { display: none; }
  .tool-select select { display: inline; }
  .card-grid { grid-template-columns: repeat(2, 1fr); gap: 8px; }
  .profile-bar { padding: 0 14px 14px; gap: 12px; }
  .profile-av { margin-top: -52px; }
  .av-xxl { width: 100px; height: 100px; font-size: 32px; }
  .profile-id h1 { font-size: 23px; }
  .profile-acts { width: 100%; }
  .profile-acts > form, .profile-acts > a { flex: 1; }
  .profile-acts .btn { width: 100%; }
  .profile-grid { padding: 10px 8px; }
  .dlg { width: 100vw; max-width: 100vw; max-height: 92vh; border-radius: 22px 22px 0 0; margin: auto 0 0; }
  .menu-up { width: 260px; }
  .toasts { bottom: calc(76px + env(safe-area-inset-bottom)); }
  .land-copy h1 { margin: 24px 0 14px; }
  .land-sub { font-size: 16px; }
  .table-card { margin: 0 8px; }
  .pic-av .av { width: 90px; height: 90px; }
}
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: .01ms !important; transition-duration: .01ms !important; }
}

/* =====================================================================
   Messages, events and marketplace
   ===================================================================== */
.wt-events { background: linear-gradient(135deg, #8b5cf6, #ec4899); }
.wt-market { background: linear-gradient(135deg, #10b981, #0ea5e9); }
.n-event { background: #8b5cf6; }
.input-sm { padding: 8px 12px; font-size: 13.5px; width: auto; }
.sub-h { font-size: 13px; font-weight: 800; text-transform: uppercase; letter-spacing: .07em; color: var(--text-3); margin: 22px 0 10px; }
.form-note { margin-top: -6px; }

/* chips row (filters) */
.chips { display: flex; gap: 8px; overflow-x: auto; padding: 12px 14px 4px; scrollbar-width: none; }
.chips::-webkit-scrollbar { display: none; }
.chipf { flex: none; padding: 8px 14px; border-radius: 999px; background: var(--panel-2); border: 1px solid var(--line); font-weight: 700; font-size: 13px; color: var(--text-2); }
.chipf:hover { color: var(--text); border-color: var(--line-2); }
.chipf.on { background: var(--text); color: var(--bg); border-color: var(--text); }

/* date chips */
.date-chip { display: inline-flex; flex-direction: column; align-items: center; justify-content: center; min-width: 48px; padding: 5px 6px; border-radius: 12px; background: var(--panel); color: var(--text); line-height: 1; box-shadow: var(--shadow-sm); }
.date-chip b { font-size: 10.5px; font-weight: 800; text-transform: uppercase; letter-spacing: .08em; color: var(--brand-ink); }
.date-chip i { font-style: normal; font-size: 20px; font-weight: 800; margin-top: 3px; }
.date-chip-sm { min-width: 42px; box-shadow: none; background: var(--panel-3); }
.date-chip-sm i { font-size: 17px; }
.date-chip-big { min-width: 66px; padding: 8px; border-radius: 16px; }
.date-chip-big i { font-size: 28px; }
.live-chip { display: inline-flex; align-items: center; gap: 6px; height: 24px; padding: 0 10px; border-radius: 999px; background: var(--grad); color: #fff; font-size: 11.5px; font-weight: 800; }
.live-chip-off { background: #4b5563; }

/* event cards */
.egrid { display: grid; grid-template-columns: repeat(auto-fill, minmax(230px, 1fr)); gap: 12px; margin: 12px 14px 0; }
.ecard { display: flex; flex-direction: column; background: var(--panel); border: 1px solid var(--line); border-radius: var(--r-lg); overflow: hidden; transition: transform .15s ease, border-color .15s ease; }
.ecard:hover { transform: translateY(-2px); border-color: var(--line-2); }
.ecard-off { opacity: .6; }
.ecard-cover { position: relative; display: block; aspect-ratio: 5 / 2; background: var(--panel-3); }
.ecard-cover img { width: 100%; height: 100%; object-fit: cover; display: block; }
.ecard-cover .date-chip { position: absolute; left: 12px; bottom: -18px; }
.ecard-cover .live-chip { position: absolute; right: 10px; top: 10px; }
.ecard-body { display: flex; flex-direction: column; gap: 3px; padding: 24px 14px 14px; min-width: 0; }
.ecard-when { color: var(--brand-ink); font-weight: 800; font-size: 12.5px; text-transform: uppercase; letter-spacing: .03em; }
.ecard-title { font-size: 16px; font-weight: 800; line-height: 1.3; }
.ecard-where { display: flex; align-items: center; gap: 4px; color: var(--text-2); font-size: 13px; }
.ecard-where svg.i { width: 15px; height: 15px; flex: none; }
.ecard-meta { color: var(--text-3); font-size: 12.5px; margin-top: 4px; }
.ecard-mine { color: var(--ok); font-weight: 700; }
.ecard-compact { flex-direction: row; }
.ecard-compact .ecard-cover { width: 38%; aspect-ratio: auto; min-height: 120px; flex: none; }
.ecard-compact .ecard-cover .date-chip { left: 10px; top: 10px; bottom: auto; }
.ecard-compact .ecard-body { padding: 14px; justify-content: center; }
.embed { display: block; margin: 12px 0 4px; }
.embed .ecard { border-color: var(--line-2); }
.embed-listing { display: flex; gap: 14px; align-items: center; padding: 10px; border: 1px solid var(--line-2); border-radius: var(--r); }
.embed-listing:hover { background: var(--hover); }
.embed-listing img, .embed-listing .lcard-ph { width: 96px; height: 96px; border-radius: 12px; object-fit: cover; flex: none; }
.embed-listing > span { display: flex; flex-direction: column; gap: 2px; min-width: 0; }
.embed-listing small { color: var(--text-3); font-size: 12.5px; display: inline-flex; align-items: center; gap: 4px; }
.embed-listing small svg.i { width: 14px; height: 14px; }
.embed-price { font-weight: 800; font-size: 17px; }

/* event page */
.event-page { overflow: hidden; }
.event-cover { aspect-ratio: 5 / 2; border-radius: 0; }
.event-main { padding: 18px 20px 22px; }
.event-date { display: flex; gap: 16px; align-items: flex-start; }
.event-title { font-size: 26px; font-weight: 800; letter-spacing: -.025em; margin: 6px 0 10px; }
.event-when { display: flex; align-items: center; gap: 10px; color: var(--text-2); margin-top: 6px; }
.event-when svg.i { color: var(--text-3); }
.event-when a:hover { text-decoration: underline; }
.event-acts, .listing-acts { display: flex; gap: 8px; flex-wrap: wrap; align-items: center; margin-top: 18px; padding-bottom: 18px; border-bottom: 1px solid var(--line); }
.event-acts form, .listing-acts form { margin: 0; }
.event-acts .post-menu, .listing-acts .post-menu { margin-left: auto; }
.btn.on { color: var(--brand-ink); }
.event-cols { display: grid; grid-template-columns: 1.6fr 1fr; gap: 24px; }
.guest-counts { display: flex; gap: 10px; }
.guest-n { flex: 1; display: flex; flex-direction: column; align-items: center; padding: 12px; border-radius: var(--r); border: 1px solid var(--line); background: var(--panel-2); }
.guest-n:hover { border-color: var(--line-2); }
.guest-n b { font-size: 22px; font-weight: 800; }
.guest-n small { color: var(--text-3); font-weight: 700; }
.av-stack { display: flex; flex-wrap: wrap; margin-top: 12px; padding-left: 6px; }
.av-stack a { margin-left: -6px; }
.av-stack .av { border: 2px solid var(--panel); box-sizing: content-box; }

/* forms: cover picker and listing photos */
.cover-pick { position: relative; display: grid; place-items: center; aspect-ratio: 5 / 2; border-radius: var(--r); overflow: hidden; background: var(--panel-3); cursor: pointer; }
.cover-pick img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.cover-pick input { position: absolute; inset: 0; opacity: 0; cursor: pointer; }
.cover-pick-hint { position: relative; display: inline-flex; align-items: center; gap: 8px; padding: 10px 16px; border-radius: 999px; background: rgba(0, 0, 0, .55); color: #fff; font-size: 13.5px; backdrop-filter: blur(6px); }
.photo-pick { display: grid; grid-template-columns: repeat(auto-fill, minmax(110px, 1fr)); gap: 8px; }
.photo-add { position: relative; aspect-ratio: 1; border: 2px dashed var(--line-2); border-radius: var(--r); display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 6px; color: var(--text-3); font-weight: 700; font-size: 13px; cursor: pointer; }
.photo-add:hover { border-color: var(--brand); color: var(--brand-ink); }
.photo-add input { position: absolute; inset: 0; opacity: 0; cursor: pointer; }
.photo-thumb { position: relative; aspect-ratio: 1; border-radius: var(--r); overflow: hidden; background: var(--panel-3); }
.photo-thumb img { width: 100%; height: 100%; object-fit: cover; display: block; }
.photo-thumb button { position: absolute; top: 6px; right: 6px; width: 28px; height: 28px; border: 0; border-radius: 50%; background: rgba(0, 0, 0, .65); color: #fff; display: grid; place-items: center; }
.photo-thumb button svg.i { width: 15px; height: 15px; }
.photo-thumb.is-cover::after { content: "Cover"; position: absolute; left: 6px; bottom: 6px; padding: 2px 8px; border-radius: 999px; background: var(--grad); color: #fff; font-size: 11px; font-weight: 800; }

/* marketplace */
.market-filter { margin: 10px 14px 0; display: flex; flex-direction: column; gap: 10px; }
.search-mid { height: 48px; margin: 0; }
.market-filter-row { display: flex; gap: 8px; flex-wrap: wrap; }
.input-price { width: 96px; }
.lgrid { display: grid; grid-template-columns: repeat(auto-fill, minmax(170px, 1fr)); gap: 14px 12px; margin: 14px 14px 0; }
.lcard { display: flex; flex-direction: column; gap: 8px; min-width: 0; }
.lcard-pic { position: relative; display: block; aspect-ratio: 1; border-radius: var(--r-lg); overflow: hidden; background: var(--panel-3); }
.lcard-pic img { width: 100%; height: 100%; object-fit: cover; display: block; transition: transform .3s ease; }
.lcard:hover .lcard-pic img { transform: scale(1.04); }
.lcard-ph { width: 100%; height: 100%; display: grid; place-items: center; color: var(--text-3); background: var(--panel-3); }
.lcard-ph svg.i { width: 34px; height: 34px; }
.lcard-body { display: flex; flex-direction: column; min-width: 0; padding: 0 2px; }
.lcard-price { font-size: 16.5px; font-weight: 800; }
.lcard-title { font-size: 14px; color: var(--text); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.lcard-meta { color: var(--text-3); font-size: 12.5px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.lcard-sold .lcard-pic img { filter: grayscale(.7); opacity: .7; }
.sold-chip { position: absolute; left: 10px; top: 10px; padding: 4px 10px; border-radius: 999px; background: #111; color: #fff; font-size: 11.5px; font-weight: 800; letter-spacing: .04em; text-transform: uppercase; }
.sold-chip-big { left: 16px; top: 16px; font-size: 13px; padding: 6px 14px; }
.listing-page { display: grid; grid-template-columns: 1.15fr 1fr; overflow: hidden; }
.gallery { position: relative; background: #050507; display: flex; flex-direction: column; }
.gallery-main { display: block; aspect-ratio: 1; }
.gallery-main img { width: 100%; height: 100%; object-fit: contain; display: block; }
.gallery-thumbs { display: flex; gap: 6px; padding: 8px; overflow-x: auto; background: rgba(255, 255, 255, .03); }
.gallery-thumbs button { flex: none; width: 58px; height: 58px; padding: 0; border: 2px solid transparent; border-radius: 10px; overflow: hidden; background: none; opacity: .6; }
.gallery-thumbs button.on { border-color: var(--brand); opacity: 1; }
.gallery-thumbs img { width: 100%; height: 100%; object-fit: cover; display: block; }
.gallery-none, .gallery-ph { min-height: 280px; display: grid; place-items: center; color: var(--text-3); }
.gallery-ph svg.i { width: 48px; height: 48px; }
.listing-info { padding: 20px 22px 22px; min-width: 0; }
.listing-title { font-size: 24px; font-weight: 800; letter-spacing: -.02em; }
.listing-price { font-size: 26px; font-weight: 800; margin-top: 4px; background: var(--grad); -webkit-background-clip: text; background-clip: text; color: transparent; display: inline-block; }
.listing-tags { display: flex; gap: 8px; align-items: center; flex-wrap: wrap; margin-top: 10px; }
.is-sold .listing-price { -webkit-text-fill-color: var(--text-3); text-decoration: line-through; }
.seller { display: flex; align-items: center; gap: 12px; padding: 12px; border-radius: var(--r); border: 1px solid var(--line); }
.seller:hover { background: var(--hover); }
.seller > span { flex: 1; display: flex; flex-direction: column; min-width: 0; }
.seller small { color: var(--text-3); }
.listing-note { display: flex; align-items: center; gap: 8px; margin-top: 14px; }
.listing-note svg.i { width: 16px; height: 16px; flex: none; }

/* explore shortcuts and mini widgets */
.shortcuts { display: grid; grid-template-columns: repeat(5, 1fr); gap: 10px; margin: 14px 14px 4px; }
.shortcut { display: flex; flex-direction: column; gap: 2px; padding: 14px 12px; border-radius: var(--r-lg); color: #fff; min-width: 0; transition: transform .15s ease; }
.shortcut:hover { transform: translateY(-2px); }
.shortcut svg.i { width: 24px; height: 24px; margin-bottom: 8px; stroke-width: 2.2; }
.shortcut b { font-size: 14.5px; }
.shortcut small { opacity: .85; font-size: 12px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.sc-events { background: linear-gradient(135deg, #8b5cf6, #ec4899); }
.sc-market { background: linear-gradient(135deg, #10b981, #0ea5e9); }
.sc-pages { background: linear-gradient(135deg, #f59e0b, #f97316); }
.sc-people { background: linear-gradient(135deg, #3b82f6, #6366f1); }
.sc-saved { background: linear-gradient(135deg, #ff3d77, #ff9a3d); }
.mini-events { display: flex; flex-direction: column; gap: 2px; }
.mini-event { display: flex; gap: 12px; align-items: center; padding: 8px 10px; border-radius: var(--r-sm); }
.mini-event:hover { background: var(--hover); }
.mini-events-card { padding: 0 6px; }
.mini-market { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; padding: 0 10px 4px; }
.mini-market-card { padding: 0 14px; }
.mini-l { display: flex; flex-direction: column; gap: 2px; min-width: 0; }
.mini-l img, .mini-l .lcard-ph { width: 100%; aspect-ratio: 1; object-fit: cover; border-radius: 12px; display: block; }
.mini-l b { font-size: 14px; margin-top: 4px; }
.mini-l small { color: var(--text-3); font-size: 12.5px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }

/* moderation: reported message with context */
.report-chat { display: flex; flex-direction: column; gap: 4px; margin-top: 8px; padding: 10px; border-radius: var(--r-sm); background: var(--panel); font-size: 13.5px; }
.report-msg { color: var(--text-2); }
.report-msg.on { color: var(--text); background: var(--brand-soft); border-radius: 6px; padding: 2px 6px; }

/* ---------- messages ---------- */
.is-dm .main { padding-bottom: 0; }
.dm { display: grid; grid-template-columns: 340px 1fr; height: 100vh; }
.dm-list { display: flex; flex-direction: column; border-right: 1px solid var(--line); min-height: 0; }
.dm-head { display: flex; align-items: center; justify-content: space-between; padding: 16px 16px 8px; }
.dm-head h1 { font-size: 22px; font-weight: 800; letter-spacing: -.02em; }
.dm-tabs { display: flex; gap: 6px; padding: 4px 14px 8px; }
.dm-tabs a { padding: 7px 14px; border-radius: 999px; font-weight: 700; font-size: 13.5px; color: var(--text-2); background: var(--panel-2); }
.dm-tabs a.on { background: var(--text); color: var(--bg); }
.dm-filter { display: flex; align-items: center; gap: 8px; margin: 2px 14px 8px; padding: 0 12px; height: 38px; border-radius: 999px; background: var(--panel-2); color: var(--text-3); }
.dm-filter input { flex: 1; min-width: 0; border: 0; outline: 0; background: transparent; color: var(--text); }
.dm-filter svg.i { width: 17px; height: 17px; }
.dm-filter-big { margin: 6px 6px 10px; height: 44px; }
.dm-items { flex: 1; overflow-y: auto; padding: 0 8px 12px; min-height: 0; }
.dm-item { display: flex; align-items: center; gap: 12px; padding: 10px; border-radius: var(--r); position: relative; }
.dm-item:hover { background: var(--hover); }
.dm-item.on { background: var(--brand-soft); }
.dm-item-text { flex: 1; min-width: 0; display: flex; flex-direction: column; line-height: 1.3; }
.dm-item-text b { font-size: 14.5px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.dm-item-text > span { color: var(--text-3); font-size: 13px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.dm-item.unread .dm-item-text b, .dm-item.unread .dm-item-text > span { color: var(--text); font-weight: 800; }
.dm-item-meta { display: flex; flex-direction: column; align-items: flex-end; gap: 6px; color: var(--text-3); font-size: 12px; }
.dm-item-meta svg.i { width: 15px; height: 15px; }
.dm-dot { width: 10px; height: 10px; border-radius: 50%; background: var(--grad); display: block; }
.dm-none { display: flex; flex-direction: column; align-items: center; gap: 6px; text-align: center; padding: 40px 18px; color: var(--text-3); font-size: 13.5px; }
.dm-none svg.i { width: 34px; height: 34px; margin-bottom: 6px; }
.dm-none b { color: var(--text-2); }
.dm-thread { display: flex; flex-direction: column; min-height: 0; min-width: 0; background: var(--bg); }
.dm-empty { margin: auto; text-align: center; padding: 30px; max-width: 360px; }
.dm-empty h2 { font-size: 22px; font-weight: 800; margin-bottom: 6px; }
.dm-empty p { color: var(--text-3); margin-bottom: 18px; }
.dm-thread-head { display: flex; align-items: center; gap: 10px; padding: 10px 14px; border-bottom: 1px solid var(--line); background: var(--panel); }
.dm-back { display: none; }
.dm-who { flex: 1; display: flex; align-items: center; gap: 10px; min-width: 0; }
.dm-who > span { display: flex; flex-direction: column; line-height: 1.25; min-width: 0; }
.dm-who small { color: var(--text-3); font-size: 12.5px; }
.dm-scroll { flex: 1; overflow-y: auto; padding: 18px 18px 8px; display: flex; flex-direction: column; gap: 3px; min-height: 0; }
.dm-intro { display: flex; flex-direction: column; align-items: center; gap: 4px; text-align: center; padding: 18px 0 26px; }
.dm-intro b { font-size: 18px; margin-top: 8px; }
.dm-intro small { color: var(--text-3); margin-bottom: 10px; }
.dm-sep { align-self: center; margin: 14px 0 8px; padding: 3px 12px; border-radius: 999px; background: var(--panel-2); color: var(--text-3); font-size: 12px; font-weight: 700; }
.dm-sep-time { background: none; margin: 8px 0 4px; }
.msg { display: flex; align-items: flex-end; gap: 8px; max-width: 78%; position: relative; }
.msg-mine { align-self: flex-end; flex-direction: row-reverse; }
.msg-av { flex: none; }
.msg-col { display: flex; flex-direction: column; gap: 4px; align-items: flex-start; min-width: 0; }
.msg-mine .msg-col { align-items: flex-end; }
.msg-bubble { padding: 9px 14px; border-radius: 20px; background: var(--panel-3); font-size: 14.5px; line-height: 1.45; overflow-wrap: anywhere; }
.msg-mine .msg-bubble { background: var(--grad); color: #fff; }
.msg-mine .msg-bubble a { color: #fff; text-decoration: underline; }
.msg-bubble a.mention, .msg-bubble a.tag { font-weight: 700; color: var(--brand-ink); }
.msg-unsent { background: transparent !important; color: var(--text-3) !important; border: 1px solid var(--line-2); font-style: italic; font-size: 13px; }
.msg-photo { display: block; border-radius: 16px; overflow: hidden; max-width: 280px; }
.msg-photo img { display: block; width: 100%; height: auto; max-height: 360px; object-fit: cover; }
.msg-listing { display: flex; align-items: center; gap: 10px; padding: 8px; border-radius: 16px; border: 1px solid var(--line-2); background: var(--panel); max-width: 280px; }
.msg-listing img, .msg-listing-ph { width: 54px; height: 54px; border-radius: 10px; object-fit: cover; flex: none; display: grid; place-items: center; background: var(--panel-3); color: var(--text-3); }
.msg-listing > span { display: flex; flex-direction: column; min-width: 0; font-size: 13.5px; }
.msg-listing b { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.msg-listing small { color: var(--text-3); }
.msg-time { font-size: 11px; color: var(--text-3); padding: 0 6px; height: 0; overflow: hidden; transition: height .15s ease; }
.msg:hover .msg-time { height: 14px; }
.msg-menu { opacity: 0; transition: opacity .15s ease; align-self: center; position: relative; }
.msg-menu .menu { right: auto; left: 0; }
.msg-mine .msg-menu .menu { left: auto; right: 0; }
.msg:hover .msg-menu, .msg-menu[open] { opacity: 1; }
.msg-menu summary { width: 30px; height: 30px; }
.dm-seen { align-self: flex-end; color: var(--text-3); font-size: 12px; font-weight: 600; padding: 2px 6px; }
.dm-request { padding: 14px 18px; border-top: 1px solid var(--line); background: var(--panel); }
.dm-request p { color: var(--text-2); font-size: 14px; margin-bottom: 10px; }
.dm-request-acts { display: flex; gap: 8px; }
.dm-request-acts form { margin: 0; }
.dm-blocked { display: flex; align-items: center; gap: 10px; justify-content: center; padding: 16px; border-top: 1px solid var(--line); color: var(--text-3); font-size: 14px; }
.dm-compose { padding: 10px 14px 14px; border-top: 1px solid var(--line); background: var(--panel); }
.dm-compose-row { display: flex; align-items: flex-end; gap: 8px; }
.dm-compose textarea { flex: 1; min-width: 0; resize: none; border: 0; outline: 0; padding: 10px 16px; border-radius: 22px; background: var(--panel-3); font-size: 14.5px; line-height: 1.4; max-height: 160px; color: var(--text); }
.dm-photo { position: relative; color: var(--brand-ink); }
.dm-photo input { position: absolute; inset: 0; opacity: 0; cursor: pointer; width: 100%; }
.dm-attach, .dm-preview { position: relative; display: flex; align-items: center; gap: 10px; margin-bottom: 8px; padding: 8px 40px 8px 8px; border-radius: var(--r); background: var(--panel-2); font-size: 13.5px; }
.dm-attach img { width: 44px; height: 44px; border-radius: 8px; object-fit: cover; }
.dm-attach small { display: block; color: var(--text-3); font-size: 11.5px; }
.dm-attach .icon-btn, .dm-preview .icon-btn { position: absolute; right: 4px; top: 50%; margin-top: -19px; }
.dm-preview img { height: 90px; border-radius: 10px; }

@media (max-width: 1099px) {
  .dm { grid-template-columns: 300px 1fr; }
  .listing-page { grid-template-columns: 1fr; }
}
@media (max-width: 899px) {
  .event-cols { grid-template-columns: 1fr; }
  .shortcuts { grid-template-columns: repeat(3, 1fr); }
}
@media (max-width: 699px) {
  .is-dm .topbar { display: none; }
  .dm { grid-template-columns: 1fr; height: calc(100vh - 64px); }
  .dm-open .dm-list { display: none; }
  .dm:not(.dm-open) .dm-thread { display: none; }
  .dm-back { display: inline-grid; }
  .msg { max-width: 88%; }
  .egrid { grid-template-columns: 1fr; margin: 10px 8px 0; }
  .lgrid { grid-template-columns: repeat(2, 1fr); margin: 12px 8px 0; gap: 12px 8px; }
  .shortcuts { grid-template-columns: repeat(2, 1fr); margin: 10px 8px 4px; }
  .shortcuts .shortcut:last-child { grid-column: span 2; }
  .event-main, .listing-info { padding: 16px; }
  .event-title { font-size: 21px; }
  .ecard-compact { flex-direction: column; }
  .ecard-compact .ecard-cover { width: 100%; min-height: 0; aspect-ratio: 5 / 2; }
  .market-filter { margin: 8px 8px 0; }
  .chips { padding: 10px 8px 2px; }
}
