/* ==========================================================================
   ilmChat v10 — one coherent design system (replaces all earlier layers)
   Emerald & gilt · Islamic geometry used sparingly · calm, premium surfaces
   ========================================================================== */
:root {
  /* colour */
  --brand: #0E6E62; --brand-2: #16A08E; --brand-deep: #08453D; --head: #0B5A50;
  --gilt: #C9A227; --gilt-hi: #E9D27F;
  --gold-grad: linear-gradient(135deg, #F6E7A6 0%, #D4AF37 40%, #9C7A17 65%, #E9D27F 100%);
  --head-grad: linear-gradient(140deg, #0F766E 0%, #0A4E46 55%, #06312B 100%);
  --gold-line: linear-gradient(90deg, transparent, #C9A227 14%, #E9D27F 50%, #C9A227 86%, transparent);
  --ink: #0F201C; --muted: #6B7671; --bg: #F6F4EE; --panel: #FFFFFF; --panel-2: #FBFAF6; --line: #E8E3D6;
  --chatbg: #EEEAE0; --mine: #DCF1E7; --mine-2: #D2ECE0; --theirs: #FFFFFF;
  --brand-soft: #E2F2EC; --brand-tint: #F2F8F5; --gold-soft: rgba(201,162,39,.22);
  --danger: #D33A2C; --ok: #22B35E; --blue: #2B7FFF;
  /* shape & depth */
  --r-s: 10px; --r-m: 14px; --r-l: 20px; --r-xl: 28px;
  --sh-1: 0 1px 2px rgba(15,32,28,.06); --sh-2: 0 4px 16px rgba(15,32,28,.08); --sh-3: 0 20px 56px rgba(15,32,28,.20);
  --ease: cubic-bezier(.2, .8, .2, 1);
  /* type */
  --font: "Plus Jakarta Sans", "Hind Siliguri", "Noto Naskh Arabic", system-ui, sans-serif;
  --serif: "Playfair Display", "Tiro Bangla", "Amiri", Georgia, serif;
  --pat: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='64' height='64' viewBox='0 0 64 64'%3E%3Cg fill='none' stroke='%23C9A227' stroke-width='1'%3E%3Crect x='18' y='18' width='28' height='28'/%3E%3Crect x='18' y='18' width='28' height='28' transform='rotate(45 32 32)'/%3E%3Ccircle cx='32' cy='32' r='5'/%3E%3Cpath d='M0 0L12 12M64 0L52 12M0 64L12 52M64 64L52 52M32 0v8M32 56v8M0 32h8M56 32h8'/%3E%3C/g%3E%3C/svg%3E");
  --pat-dark: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='64' height='64' viewBox='0 0 64 64'%3E%3Cg fill='none' stroke='%23C9A227' stroke-opacity='.13' stroke-width='1'%3E%3Crect x='18' y='18' width='28' height='28'/%3E%3Crect x='18' y='18' width='28' height='28' transform='rotate(45 32 32)'/%3E%3Ccircle cx='32' cy='32' r='5'/%3E%3Cpath d='M0 0L12 12M64 0L52 12M0 64L12 52M64 64L52 52M32 0v8M32 56v8M0 32h8M56 32h8'/%3E%3C/g%3E%3C/svg%3E");
  --band: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='48' height='12' viewBox='0 0 48 12'%3E%3Cg fill='none' stroke='%23C9A227' stroke-width='1'%3E%3Cpath d='M0 6h14M34 6h14'/%3E%3Cpath d='M24 1l5 5-5 5-5-5z' fill='%23C9A227'/%3E%3Cpath d='M14 6q5-5 5 0M34 6q-5-5-5 0'/%3E%3C/g%3E%3C/svg%3E");
  --ros: url("/icons/rosette.svg");
  color-scheme: light;
}
:root[data-theme="dark"] { --ink: #ECF2EF; --muted: #93A59F; --bg: #0A1311; --panel: #111C19; --panel-2: #0E1816; --line: #1F2C29; --chatbg: #0C1614; --mine: #134238; --mine-2: #103A31; --theirs: #17231F; --brand-soft: #143A33; --brand-tint: #10231E; --head: #0E211D; --sh-1: none; --sh-2: 0 4px 16px rgba(0,0,0,.35); --sh-3: 0 20px 56px rgba(0,0,0,.6); color-scheme: dark; }
@media (prefers-color-scheme: dark) { :root:not([data-theme="light"]) { --ink: #ECF2EF; --muted: #93A59F; --bg: #0A1311; --panel: #111C19; --panel-2: #0E1816; --line: #1F2C29; --chatbg: #0C1614; --mine: #134238; --mine-2: #103A31; --theirs: #17231F; --brand-soft: #143A33; --brand-tint: #10231E; --head: #0E211D; --sh-1: none; --sh-2: 0 4px 16px rgba(0,0,0,.35); --sh-3: 0 20px 56px rgba(0,0,0,.6); color-scheme: dark; } }

/* ---------- base ---------- */
* { box-sizing: border-box; -webkit-tap-highlight-color: transparent; }
html, body { height: 100%; margin: 0; }
body { font-family: var(--font); background: var(--bg); color: var(--ink); font-size: 15.5px; line-height: 1.5; -webkit-font-smoothing: antialiased; text-rendering: optimizeLegibility; overscroll-behavior: none; }
[lang="ar"] body, [dir="rtl"] body { font-family: "Noto Naskh Arabic", var(--font); }
button, input, textarea, select { font: inherit; color: inherit; }
button { cursor: pointer; border: 0; background: none; padding: 0; }
input, textarea { outline: none; }
:focus-visible { outline: 2px solid var(--gilt); outline-offset: 2px; }
.hidden, [hidden] { display: none !important; }
::-webkit-scrollbar { width: 6px; height: 6px; } ::-webkit-scrollbar-thumb { background: var(--line); border-radius: 6px; }
h1, h2, h3, .serif { font-family: var(--serif); font-synthesis-weight: none; }
@keyframes spin { to { transform: rotate(360deg); } }
@keyframes pulse { 50% { opacity: .35; } }
@keyframes rise { from { opacity: 0; transform: translateY(6px); } }
@keyframes pop { from { opacity: 0; transform: translateY(4px) scale(.985); } }
@keyframes slideIn { from { transform: translateX(26px); opacity: .4; } }
@keyframes sheetUp { from { transform: translateY(40px); opacity: 0; } }
@keyframes fadeScale { from { transform: scale(.96); opacity: 0; } }
@keyframes ripple { 0% { transform: scale(1); opacity: .7; } 100% { transform: scale(2.4); opacity: 0; } }
@keyframes ring { 0%, 100% { transform: scale(1); } 50% { transform: scale(1.08); } }
@keyframes flash { 0%, 40% { box-shadow: 0 0 0 3px rgba(201,162,39,.7); } 100% { box-shadow: var(--sh-1); } }

/* ---------- shared atoms ---------- */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 8px; padding: 13px 18px; border-radius: var(--r-m); font-weight: 700; width: 100%; transition: transform .1s var(--ease), box-shadow .2s, background .2s; }
.btn:active { transform: scale(.985); }
.btn-brand { background: var(--head-grad); color: #fff; box-shadow: inset 0 0 0 1px rgba(233,210,127,.4), 0 6px 18px rgba(8,69,61,.28); }
.btn-ghost { background: var(--panel); border: 1px solid var(--line); }
.btn-text { width: auto; padding: 6px 8px; color: var(--brand); font-weight: 700; border-radius: var(--r-s); }
.btn-text:hover { background: var(--brand-tint); }
.icon-btn { width: 42px; height: 42px; border-radius: 50%; display: grid; place-items: center; color: var(--muted); flex: none; transition: background .15s, color .15s, transform .1s; }
.icon-btn:hover { background: var(--brand-tint); color: var(--brand); } .icon-btn:active { transform: scale(.92); }
.icon-btn svg { width: 23px; height: 23px; fill: currentColor; }
.avatar { width: 50px; height: 50px; border-radius: 50%; flex: none; position: relative; display: grid; place-items: center; overflow: hidden; color: #fff; font-weight: 800; font-size: 18px; border: 2px solid transparent; background: linear-gradient(135deg, var(--brand-2), var(--brand-deep)) padding-box, var(--gold-grad) border-box; }
.avatar img { width: 100%; height: 100%; object-fit: cover; }
.avatar.sm { width: 40px; height: 40px; font-size: 15px; }
.avatar.xl { width: 116px; height: 116px; font-size: 42px; border-width: 3px; }
.avatar.group { border-radius: 50% 50% 14px 14px / 46% 46% 14px 14px; }
.dot { position: absolute; right: 1px; bottom: 1px; width: 13px; height: 13px; border-radius: 50%; background: var(--ok); border: 2.5px solid var(--panel); }
[dir="rtl"] .dot { right: auto; left: 1px; }
.badge { min-width: 21px; padding: 2px 7px; border-radius: 999px; text-align: center; font-size: 11.5px; font-weight: 800; color: #3B2F07; background: var(--gold-grad); box-shadow: 0 2px 6px rgba(201,162,39,.35); }
.empty { padding: 48px 28px; text-align: center; color: var(--muted); line-height: 1.6; }
.err { color: var(--danger); font-size: 13px; min-height: 18px; margin: 4px 0 8px; } .err.ok { color: var(--brand); }
.toast { position: fixed; left: 50%; bottom: max(26px, env(safe-area-inset-bottom)); transform: translate(-50%, 8px); z-index: 80; max-width: calc(100vw - 32px); padding: 11px 18px; border-radius: 999px; background: #0F201C; color: #F3EFE4; font-size: 14px; box-shadow: var(--sh-3); opacity: 0; pointer-events: none; transition: opacity .2s, transform .2s var(--ease); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.toast.show { opacity: 1; transform: translate(-50%, 0); }
.live-dot { width: 9px; height: 9px; border-radius: 50%; flex: none; background: #EF4444; box-shadow: 0 0 0 4px rgba(239,68,68,.22); animation: pulse 1.2s infinite; }

/* inputs (dialogs, forms) */
.field { display: block; margin-bottom: 12px; }
.field input, .dlg input:not([type="checkbox"]):not([type="file"]) { width: 100%; padding: 13px 15px; border-radius: var(--r-m); border: 1px solid var(--line); background: var(--panel-2); transition: border-color .15s, box-shadow .15s, background .15s; }
.field input:focus, .dlg input:focus { border-color: var(--gilt); background: var(--panel); box-shadow: 0 0 0 4px rgba(201,162,39,.14); }
.dlg input[readonly] { border-color: transparent; background: none; padding-inline: 0; box-shadow: none; }

/* ---------- splash ---------- */
#splash { position: fixed; inset: 0; z-index: 90; display: grid; place-items: center; align-content: center; gap: 14px; background: var(--pat) 0 0 / 64px 64px, radial-gradient(700px 500px at 50% 40%, var(--brand-soft), var(--bg)); }
:root #splash { background-blend-mode: soft-light, normal; }
#splash .spin { width: 22px; height: 22px; border: 2.5px solid var(--line); border-top-color: var(--brand); border-radius: 50%; animation: spin .8s linear infinite; }
.ros-wrap { position: relative; width: 190px; height: 190px; margin: 0 auto; display: grid; place-items: center; }
.ros-wrap.big { width: 230px; height: 230px; }
.rosette { position: absolute; inset: 0; background: var(--ros) center / contain no-repeat; }
.spin-slow { animation: spin 100s linear infinite; }
.ros-wrap img { position: relative; width: 86px; height: 86px; border-radius: 50% 50% 18px 18px / 44% 44% 18px 18px; box-shadow: 0 0 0 3px var(--bg), 0 0 0 5px var(--gilt), var(--sh-3); }
.ros-wrap.big img { width: 100px; height: 100px; }
.motto { font-family: "Amiri", serif; font-size: 26px; font-weight: 700; direction: rtl; text-align: center; line-height: 1.5; background: var(--gold-grad); -webkit-background-clip: text; background-clip: text; color: transparent; }
.motto-tr { font-size: 12.5px; color: var(--muted); margin: 2px 0 14px; text-align: center; }

/* ---------- auth ---------- */
#auth { min-height: 100%; display: grid; place-items: center; padding: max(28px, env(safe-area-inset-top)) 20px 28px; background: radial-gradient(900px 520px at 50% -5%, rgba(15,118,110,.18), transparent 70%), var(--bg); position: relative; }
#auth::before { content: ""; position: absolute; inset: 0; background: var(--pat) 0 0 / 64px 64px; opacity: .06; pointer-events: none; -webkit-mask: linear-gradient(#000, transparent 70%); mask: linear-gradient(#000, transparent 70%); }
.auth-card { position: relative; width: 100%; max-width: 400px; padding: 26px 26px 22px; border-radius: var(--r-xl); background: linear-gradient(var(--panel), var(--panel)) padding-box, var(--gold-grad) border-box; border: 1.5px solid transparent; box-shadow: var(--sh-3); animation: rise .4s var(--ease); }
.auth-card .motto { font-size: 22px; margin-bottom: 4px; }
.logo { display: flex; align-items: center; justify-content: center; gap: 12px; margin-bottom: 4px; }
.logo img { width: 54px; height: 54px; border-radius: 50% 50% 14px 14px / 44% 44% 14px 14px; box-shadow: 0 0 0 3px var(--panel), 0 0 0 5px var(--gilt), 0 10px 26px rgba(8,69,61,.28); }
.logo h1 { margin: 0; font-size: 40px; font-weight: 800; letter-spacing: -.01em; }
.logo h1 span { background: var(--gold-grad); -webkit-background-clip: text; background-clip: text; color: transparent; }
.tagline { margin: 0 0 6px; text-align: center; color: var(--muted); font-family: var(--serif); font-size: 16.5px; }
.orn-line { display: flex; align-items: center; gap: 10px; height: 12px; margin: 6px 0 22px; background: var(--band) center / 48px 12px no-repeat; }
.orn-line span { display: none; }
.orn-line::before, .orn-line::after { content: ""; flex: 1; height: 1.5px; background: var(--gold-line); }
.sep { display: flex; align-items: center; gap: 12px; color: var(--muted); margin: 16px 0; font-size: 13px; }
.sep::before, .sep::after { content: ""; flex: 1; height: 1px; background: var(--line); }
.forgot-row { display: flex; justify-content: flex-end; margin: -4px 0 2px; } .forgot-row .btn-text { font-size: 13.5px; padding: 4px 2px; }
.lang-row { display: flex; gap: 6px; justify-content: center; margin-top: 22px; }
.lang-row button, .seg button { padding: 8px 14px; border-radius: 999px; border: 1px solid var(--line); background: var(--panel); font-size: 13.5px; transition: background .15s, color .15s; }
.lang-row button[aria-pressed="true"], .seg button[aria-pressed="true"] { background: var(--head-grad); color: #fff; border-color: transparent; box-shadow: inset 0 0 0 1px rgba(233,210,127,.45); }
.about-link { display: inline-flex; align-items: center; gap: 6px; margin-top: 16px; color: var(--brand); text-decoration: none; font-size: 14px; }
#auth .about-link { display: flex; justify-content: center; }
.about-link b { font-weight: 600; border-bottom: 1px solid var(--gold-soft); } .about-link span { color: var(--gilt); }

/* ---------- app shell ---------- */
#app { position: fixed; inset: 0; display: grid; grid-template-columns: 390px 1fr; }
body.has-mini #app { top: 42px; }
.side { display: flex; flex-direction: column; min-width: 0; min-height: 0; background: var(--panel); border-inline-end: 1px solid var(--line); }
.main { position: relative; display: flex; flex-direction: column; min-width: 0; min-height: 0; background: var(--chatbg); }
.main::before { content: ""; position: absolute; inset: 0; pointer-events: none; background: var(--pat) 0 0 / 64px 64px; opacity: .07; }
.main > * { position: relative; }
.topbar { position: relative; display: flex; align-items: center; gap: 8px; min-height: 64px; padding: 10px 12px; padding-top: max(10px, env(safe-area-inset-top)); background: var(--panel); flex: none; z-index: 2; }
.topbar::after { content: ""; position: absolute; left: 0; right: 0; bottom: 0; height: 1.5px; background: var(--gold-line); opacity: .85; }
.topbar h2 { flex: 1; margin: 0 0 0 6px; font-size: 26px; font-weight: 700; letter-spacing: .005em; }
.search { padding: 8px 12px 12px; background: var(--panel); flex: none; }
.search input { width: 100%; padding: 11px 18px 11px 42px; border-radius: 999px; border: 1px solid transparent; background: var(--bg) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='%236B7671'%3E%3Cpath d='M15.5 14h-.79l-.28-.27A6.47 6.47 0 0 0 16 9.5 6.5 6.5 0 1 0 9.5 16c1.61 0 3.09-.59 4.23-1.57l.27.28v.79l5 4.99L20.49 19l-4.99-5zm-6 0C7.01 14 5 11.99 5 9.5S7.01 5 9.5 5 14 7.01 14 9.5 11.99 14 9.5 14z'/%3E%3C/svg%3E") 14px center / 18px no-repeat; transition: border-color .15s, background-color .15s; }
[dir="rtl"] .search input { padding: 11px 42px 11px 18px; background-position: calc(100% - 14px) center; }
.search input:focus { border-color: var(--gilt); background-color: var(--panel); }
.list { flex: 1; min-height: 0; overflow-y: auto; }
.row { display: flex; align-items: center; gap: 13px; width: 100%; padding: 11px 14px; text-align: start; position: relative; transition: background .12s; }
.row + .row::before { content: ""; position: absolute; top: 0; inset-inline-start: 77px; inset-inline-end: 14px; height: 1px; background: var(--line); }
.row:hover { background: var(--brand-tint); }
.row[aria-current="true"] { background: var(--brand-soft); box-shadow: inset 3px 0 0 var(--gilt); }
[dir="rtl"] .row[aria-current="true"] { box-shadow: inset -3px 0 0 var(--gilt); }
.row .meta { flex: 1; min-width: 0; }
.row .top { display: flex; justify-content: space-between; align-items: baseline; gap: 8px; }
.row .top b { font-family: var(--serif); font-size: 17.5px; font-weight: 700; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.row .time { flex: none; font-size: 12px; color: var(--muted); font-feature-settings: "tnum"; }
.row .preview { display: flex; align-items: center; gap: 8px; margin-top: 2px; font-size: 14px; color: var(--muted); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.row .preview .badge { margin-inline-start: auto; }
.placeholder { flex: 1; display: grid; place-items: center; padding: 24px; text-align: center; color: var(--muted); }
.placeholder .motto { font-size: 30px; margin-top: 10px; }
.placeholder .about-link { margin-top: 14px; }
.tip { flex: none; display: flex; align-items: flex-start; gap: 10px; margin: 6px 12px; padding: 12px 14px; border-radius: var(--r-m); background: var(--brand-tint); border: 1px solid var(--gold-soft); }
.tip-body { flex: 1; min-width: 0; } .tip b { display: block; font-size: 14px; margin-bottom: 2px; } .tip p { margin: 0; font-size: 13px; color: var(--muted); line-height: 1.45; }
.tip.warn { background: #FFF6E6; border-color: #F2C98A; cursor: pointer; }

/* ---------- conversation ---------- */
.chat-head { min-height: 62px; padding: 8px 10px; padding-top: max(8px, env(safe-area-inset-top)); }
.chat-head .meta { flex: 1; min-width: 0; line-height: 1.25; cursor: pointer; }
.chat-head b { display: block; font-family: var(--serif); font-size: 17.5px; font-weight: 700; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.chat-head small { display: block; margin-top: 1px; font-size: 12.5px; color: var(--muted); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.chat-head small.on { color: var(--brand); font-weight: 700; }
.chat-head .avatar.sm { width: 42px; height: 42px; cursor: pointer; }
.class-banner { display: flex; align-items: center; gap: 10px; flex: none; margin: 8px 12px 0; padding: 10px 12px 10px 14px; border-radius: var(--r-m); color: #fff; background: var(--pat) 0 0 / 48px 48px, var(--head-grad); background-blend-mode: soft-light, normal; border: 1px solid rgba(233,210,127,.45); box-shadow: var(--sh-2); animation: rise .3s var(--ease); }
.class-banner b { flex: 1; font-size: 14px; font-weight: 600; }
.btn-join { padding: 7px 16px; border-radius: 999px; background: #fff; color: var(--brand-deep); font-weight: 800; font-size: 13.5px; }
#messages { flex: 1; min-height: 0; overflow-y: auto; display: flex; flex-direction: column; gap: 3px; padding: 12px 12px 16px; }
.day { align-self: center; display: flex; align-items: center; gap: 8px; margin: 12px 0 8px; padding: 4px 14px; border-radius: 999px; font-family: var(--serif); font-size: 13px; color: var(--muted); background: var(--panel); box-shadow: var(--sh-1); }
.day::before, .day::after { content: "✦"; color: var(--gilt); font-size: 8px; }
.sysmsg { align-self: center; max-width: 86%; margin: 6px 0; padding: 5px 13px; border-radius: 999px; font-size: 12.5px; text-align: center; color: var(--muted); background: var(--panel); box-shadow: var(--sh-1); }

/* bubbles */
.msg { position: relative; align-self: flex-start; max-width: min(78%, 580px); padding: 7px 11px; border-radius: 18px; border-start-start-radius: 6px; background: var(--theirs); color: var(--ink); box-shadow: var(--sh-1); border: 1px solid rgba(15,32,28,.05); word-break: break-word; white-space: pre-wrap; animation: pop .18s var(--ease); will-change: transform; -webkit-user-select: text; user-select: text; -webkit-touch-callout: none; font-size: 15.5px; line-height: 1.5; }
.msg.mine { align-self: flex-end; background: linear-gradient(180deg, var(--mine), var(--mine-2)); border-color: rgba(14,110,98,.10); border-start-start-radius: 18px; border-start-end-radius: 6px; }
.msg + .msg { margin-top: 1px; }
.msg::after { content: ""; display: inline-block; width: 58px; height: 1px; }
.msg.mine::after { width: 76px; }
.msg:has(.voice)::after, .msg:has(.poll)::after, .msg:has(.evcard)::after, .msg:has(.ccard)::after, .msg:has(.loccard)::after { display: none; }
.msg .who { display: block; margin-bottom: 1px; font-size: 12.5px; font-weight: 700; color: var(--brand); }
.msg .fwd { display: block; margin-bottom: 2px; font-size: 12px; font-style: italic; color: var(--muted); }
.msg a { color: var(--brand); }
.msg .stamp { position: absolute; bottom: 5px; inset-inline-end: 10px; display: inline-flex; align-items: center; gap: 3px; font-size: 11px; line-height: 1; color: var(--muted); font-feature-settings: "tnum"; }
.msg .stamp .ticks { font-weight: 800; letter-spacing: -.2em; } .msg .stamp .ticks.seen { color: var(--gilt); }
.msg.gone { font-style: italic; color: var(--muted); }
.msg.flash { animation: flash 1.2s ease-out; }
.msg .more { position: absolute; top: 3px; inset-inline-end: 4px; display: none; place-items: center; width: 24px; height: 22px; border-radius: 8px; font-size: 15px; line-height: 1; color: var(--muted); background: var(--panel); box-shadow: var(--sh-1); }
.msg:hover .more { display: grid; }
@media (hover: none) { .msg .more { display: none !important; } }
.msg img.pic { display: block; max-width: 100%; max-height: 380px; margin: 2px -5px 16px; border-radius: 14px; cursor: zoom-in; }
.msg video.vid { display: block; max-width: 100%; max-height: 380px; margin: 2px -5px 16px; border-radius: 14px; background: #000; }
.msg .call-log { color: var(--muted); font-weight: 600; }
.rq-in { margin: 2px 0 6px; padding: 3px 10px; border-radius: 8px; border-inline-start: 3px solid var(--gilt); background: var(--brand-tint); cursor: pointer; }
.msg.mine .rq-in { background: rgba(255,255,255,.5); }
.rq-in b, .reply-bar .rq b { display: block; font-size: 12.5px; font-weight: 700; color: var(--brand); }
.rq-in span, .reply-bar .rq span { display: block; font-size: 13px; color: var(--muted); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }

/* rich message bodies */
.filecard { display: flex; align-items: center; gap: 10px; min-width: 220px; padding: 4px 0 14px; color: inherit; text-decoration: none; }
.filecard .fic { flex: none; width: 42px; height: 42px; border-radius: 12px; display: grid; place-items: center; font-size: 11px; font-weight: 800; text-transform: uppercase; color: #fff; background: var(--head-grad); }
.filecard .fmeta { min-width: 0; } .filecard b { display: block; max-width: 220px; font-size: 14px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; } .filecard small { font-size: 12px; color: var(--muted); }
.msg:has(.voice) { min-width: 290px; padding: 9px 12px 24px; }
.voice { display: flex; align-items: center; gap: 12px; min-height: 44px; }
.vplay { flex: none; width: 42px; height: 42px; border-radius: 50%; display: grid; place-items: center; color: #fff; background: var(--head-grad); box-shadow: 0 0 0 1.5px var(--gilt); }
.vplay svg { width: 20px; height: 20px; fill: currentColor; } .vplay .ic-pause { display: none; } .playing .vplay .ic-play { display: none; } .playing .vplay .ic-pause { display: block; }
.vbody { flex: 1; min-width: 0; display: flex; align-items: center; gap: 10px; }
.vtrack { position: relative; flex: 1; min-width: 60px; height: 4px; margin: 0 7px; border-radius: 999px; background: rgba(15,32,28,.14); cursor: pointer; touch-action: none; }
.vtrack::before { content: ""; position: absolute; inset: -12px 0; }
.vfill { position: absolute; inset: 0 auto 0 0; width: 0; border-radius: 999px; background: var(--brand); }
[dir="rtl"] .vfill { inset: 0 0 0 auto; }
.vknob { position: absolute; top: 50%; inset-inline-start: 0; width: 14px; height: 14px; margin: -7px 0 0; margin-inline-start: -7px; border-radius: 50%; background: var(--brand); box-shadow: 0 0 0 2px var(--panel), 0 0 0 3.5px var(--gilt); transition: transform .15s; }
.playing .vknob { transform: scale(1.15); }
.vmeta { flex: none; display: flex; align-items: center; gap: 6px; }
.voice .dur { min-width: 34px; text-align: center; font-size: 12.5px; line-height: 1; color: var(--muted); font-feature-settings: "tnum"; }
.vspeed { display: grid; place-items: center; height: 22px; padding: 0 8px; border-radius: 999px; font-size: 11.5px; font-weight: 800; line-height: 1; color: var(--brand); background: var(--brand-soft); }
.loccard { display: flex; flex-direction: column; min-width: 230px; margin: -2px -5px 16px; border-radius: 14px; overflow: hidden; border: 1px solid var(--line); color: inherit; text-decoration: none; }
.locmap { height: 112px; display: grid; place-items: center; background: linear-gradient(90deg, transparent 47%, rgba(255,255,255,.9) 47%, rgba(255,255,255,.9) 53%, transparent 53%) 0 0 / 70px 100%, linear-gradient(0deg, transparent 47%, rgba(255,255,255,.9) 47%, rgba(255,255,255,.9) 53%, transparent 53%) 0 0 / 100% 56px, linear-gradient(35deg, transparent 48%, #F6E7A6 48%, #F6E7A6 52%, transparent 52%), #DCEFE6; }
.locmap svg { width: 40px; height: 40px; fill: #DC2626; filter: drop-shadow(0 4px 6px rgba(0,0,0,.3)); }
.locinfo { display: flex; flex-direction: column; padding: 8px 10px; background: var(--panel); }
.locinfo b { font-size: 14.5px; } .locinfo small { font-size: 12px; color: var(--muted); } .locinfo em { margin-top: 2px; font-style: normal; font-size: 13px; font-weight: 700; color: var(--brand); }
.ccard, .evcard { display: flex; gap: 12px; min-width: 230px; padding: 2px 0 9px; border-bottom: 1px solid var(--line); }
.ccard { align-items: center; } .cinfo b { display: block; font-size: 15px; } .cinfo small { color: var(--muted); }
.cbtns, .evbtns { display: flex; gap: 6px; padding-top: 8px; margin-bottom: 16px; }
.cbtns a, .cbtns button, .evbtns a, .evbtns button { flex: 1; padding: 7px; border-radius: var(--r-s); text-align: center; text-decoration: none; font-size: 13px; font-weight: 700; color: var(--brand); background: var(--brand-soft); }
.evbtns .evgo.on { background: var(--head-grad); color: #fff; }
.evdate { flex: none; width: 54px; overflow: hidden; border-radius: 12px; text-align: center; background: var(--panel); border: 1px solid rgba(201,162,39,.5); }
.evdate small { display: block; padding: 2px 0; font-size: 11px; font-weight: 800; text-transform: uppercase; color: var(--gilt-hi); background: var(--head-grad); }
.evdate b { display: block; padding: 2px 0 4px; font-family: var(--serif); font-size: 22px; }
.evinfo { min-width: 0; } .evinfo b { display: block; font-size: 15.5px; } .evinfo small { display: block; font-size: 12.5px; color: var(--muted); } .evinfo p { margin: 4px 0 0; font-size: 13.5px; }
.poll { display: flex; flex-direction: column; gap: 6px; min-width: 250px; margin-bottom: 16px; }
.pq { font-size: 15.5px; } .phint, .ptotal { font-size: 12px; color: var(--muted); } .ptotal { text-align: center; margin-top: 2px; }
.popt { display: grid; grid-template-columns: 22px 1fr auto; grid-template-rows: auto 6px; align-items: center; gap: 4px 8px; padding: 4px 0; text-align: start; }
.pchk { position: relative; width: 20px; height: 20px; border-radius: 50%; border: 2px solid var(--muted); }
.popt.multi .pchk { border-radius: 6px; }
.popt.sel .pchk { border-color: var(--brand); background: var(--brand); }
.popt.sel .pchk::after { content: "✓"; position: absolute; inset: 0; display: grid; place-items: center; font-size: 12px; font-weight: 800; color: #fff; }
.ptxt { font-size: 14.5px; } .pcnt { font-size: 12.5px; font-weight: 700; color: var(--brand); }
.pbar { grid-column: 2 / 4; height: 6px; border-radius: 6px; overflow: hidden; background: rgba(15,32,28,.08); }
.pbar i { display: block; height: 100%; border-radius: 6px; background: linear-gradient(90deg, var(--brand), var(--gilt)); transition: width .3s var(--ease); }

/* composer */
.reply-bar, .bn-prev { position: relative; z-index: 3; display: flex; align-items: center; gap: 8px; margin: 0 10px; padding: 8px 10px 8px 12px; background: var(--panel); border: 1px solid var(--gold-soft); border-bottom: 0; border-radius: var(--r-m) var(--r-m) 0 0; box-shadow: 0 -6px 16px rgba(15,32,28,.06); animation: rise .18s var(--ease); flex: none; }
.reply-bar .rq { flex: 1; min-width: 0; padding: 2px 10px; border-radius: 8px; border-inline-start: 3px solid var(--gilt); background: var(--brand-tint); }
.reply-bar + .bn-prev { border-radius: 0; border-top: 0; }
.bn-prev { align-items: flex-start; font-size: 15.5px; line-height: 1.5; }
.bn-tag { flex: none; margin-top: 2px; padding: 2px 8px; border-radius: 999px; font-size: 11px; font-weight: 800; white-space: nowrap; color: var(--brand); background: var(--brand-soft); }
.bn-tag.ai { color: #3B2F07; background: var(--gold-grad); }
.bn-text { flex: 1; min-width: 0; max-height: 96px; overflow-y: auto; white-space: pre-wrap; word-break: break-word; font-family: "Hind Siliguri", var(--font); }
.bn-text[dir="rtl"] { font-family: "Noto Naskh Arabic", "Amiri", serif; font-size: 17px; }
.bn-x { flex: none; width: 26px; height: 26px; border-radius: 50%; font-size: 13px; color: var(--muted); background: var(--bg); }
.compose { position: relative; display: flex; align-items: flex-end; gap: 6px; padding: 8px 10px; padding-bottom: max(10px, env(safe-area-inset-bottom)); background: var(--panel); flex: none; }
.compose::before { content: ""; position: absolute; left: 0; right: 0; top: 0; height: 1.5px; background: var(--gold-line); opacity: .8; }
.compose .icon-btn { width: 42px; height: 42px; }
.compose textarea { flex: 1; min-height: 44px; max-height: 140px; padding: 11px 16px; resize: none; border-radius: 22px; border: 1px solid var(--line); background: var(--bg); line-height: 1.4; font-size: 15.5px; transition: border-color .15s, background .15s, box-shadow .15s; }
.compose textarea:focus { border-color: var(--gilt); background: var(--panel); box-shadow: 0 0 0 3px rgba(201,162,39,.12); }
.compose .send { flex: none; width: 46px; height: 46px; border-radius: 50%; display: grid; place-items: center; color: #fff; background: var(--head-grad); box-shadow: 0 0 0 1.5px var(--gilt), 0 6px 16px rgba(8,69,61,.3); transition: transform .1s; }
.compose .send:active { transform: scale(.92); }
.compose .send svg { width: 21px; height: 21px; fill: currentColor; }
.compose .send.mic.rec { background: var(--danger); animation: pulse 1s infinite; }
[dir="rtl"] .compose #btnSend svg { transform: scaleX(-1); }
.bn-btn { color: var(--brand); border: 1.5px solid rgba(201,162,39,.55); }
.bn-btn span { font-family: "Tiro Bangla", "Amiri", "Hind Siliguri", serif; font-size: 18px; font-weight: 700; line-height: 1; }
.bn-btn.on { color: #fff; background: var(--head-grad); border-color: var(--gilt); }
.compose.recording textarea, .compose.recording #btnAttach, .compose.recording .bn-btn { display: none; }
#recBar { flex: 1; display: flex; align-items: center; gap: 12px; min-height: 44px; padding: 0 8px; font-weight: 700; font-feature-settings: "tnum"; }
.rec-dot { width: 10px; height: 10px; border-radius: 50%; background: var(--danger); animation: pulse 1s infinite; }

/* ---------- dialogs & sheets ---------- */
dialog { width: min(440px, 94vw); padding: 0; border-radius: var(--r-l); color: var(--ink); background: linear-gradient(var(--panel), var(--panel)) padding-box, var(--gold-grad) border-box; border: 1.5px solid transparent; box-shadow: var(--sh-3); animation: fadeScale .2s var(--ease); }
dialog::backdrop { background: rgba(8,18,16,.5); backdrop-filter: blur(4px); -webkit-backdrop-filter: blur(4px); }
dialog.sheet { margin: auto auto 0; width: min(480px, 100vw); max-width: 100vw; border-radius: var(--r-xl) var(--r-xl) 0 0; border-bottom: 0; padding-bottom: env(safe-area-inset-bottom); animation: sheetUp .24s var(--ease); }
@media (min-width: 761px) { dialog.sheet { margin: auto; border-radius: var(--r-xl); border-bottom: 1.5px solid transparent; } }
.dlg { padding: 22px; }
.dlg h3 { display: flex; align-items: center; gap: 10px; margin: 0 0 16px; font-size: 23px; }
.dlg h3::after { content: ""; flex: 1; height: 12px; background: var(--band) left center / 48px 12px repeat-x; opacity: .9; }
.dlg .actions { display: flex; justify-content: flex-end; gap: 8px; margin-top: 18px; }
.dlg .actions .btn { width: auto; padding: 11px 18px; }
.lbl { display: block; margin: 14px 0 6px; font-size: 13px; color: var(--muted); }
.seg { display: flex; gap: 6px; } .seg button { flex: 1; }
.avatar-edit { display: flex; align-items: center; gap: 14px; } .avatar-edit .avatar { width: 66px; height: 66px; font-size: 24px; cursor: pointer; }
.pick { max-height: 300px; overflow-y: auto; border: 1px solid var(--line); border-radius: var(--r-m); }
.pick label { display: flex; align-items: center; gap: 10px; padding: 9px 12px; cursor: pointer; border-bottom: 1px solid var(--line); }
.pick label:last-child { border-bottom: 0; }
.pick input, .chk input { width: 18px; height: 18px; accent-color: var(--brand); }
.chk { display: flex; align-items: center; gap: 8px; margin-top: 8px; font-size: 14px; }
.popts-edit { display: flex; flex-direction: column; gap: 8px; margin: 10px 0 4px; }
.dlg input[type="date"], .dlg input[type="time"] { flex: 1; }
.about-btn { display: flex; align-items: center; gap: 10px; margin-top: 16px; padding: 12px 14px; border-radius: var(--r-m); color: var(--ink); text-decoration: none; background: var(--brand-tint); border: 1px solid var(--gold-soft); }
.about-btn span { color: var(--gilt); font-size: 16px; } .about-btn b { flex: 1; font-size: 14.5px; font-weight: 600; } .about-btn i { font-style: normal; color: var(--brand); }
.push-status { margin-top: 14px; padding: 8px 10px; border-radius: var(--r-s); font-size: 12.5px; color: var(--muted); background: var(--bg); word-break: break-word; white-space: pre-wrap; }
.push-status.good { color: var(--brand); } .push-status.bad { color: var(--danger); }
.dlg.menu { display: flex; flex-direction: column; padding: 10px 10px 12px; }
.dlg.menu::before, .att-grid::before { content: ""; width: 42px; height: 4px; margin: 2px auto 10px; border-radius: 4px; background: var(--line); }
.menu-h { margin: 2px 14px 8px; font-size: 18px; color: var(--brand); }
.menu-h::after { display: none; }
.dlg.menu button { display: flex; align-items: center; gap: 14px; padding: 12px 14px; border-radius: var(--r-m); text-align: start; font-size: 16px; transition: background .12s; }
.dlg.menu button:hover, .dlg.menu button:active { background: var(--brand-tint); }
.dlg.menu button span { flex: none; width: 36px; height: 36px; border-radius: 11px; display: grid; place-items: center; font-size: 17px; color: var(--brand); background: var(--brand-soft); }
.dlg.menu button b { font-weight: 600; }
.dlg.menu button.danger { color: var(--danger); } .dlg.menu button.danger span { color: var(--danger); background: rgba(211,58,44,.1); }
.dlg.menu button.muted { justify-content: center; margin-top: 4px; color: var(--muted); border-top: 1px solid var(--line); border-radius: 0 0 var(--r-m) var(--r-m); }
.lm-ic { font-family: "Tiro Bangla", "Amiri", var(--serif) !important; font-size: 19px !important; font-weight: 700; }
#dlgMode [data-mode].sel { background: var(--brand-soft); box-shadow: inset 3px 0 0 var(--gilt); }
#dlgMode [data-mode].sel b::after { content: "  ✓"; color: var(--gilt); }
.att-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 18px 8px; padding: 14px 14px calc(18px + env(safe-area-inset-bottom)); }
.att-grid::before { grid-column: 1 / -1; }
.att { display: flex; flex-direction: column; align-items: center; gap: 8px; font-size: 13px; color: var(--ink); }
.att:focus { outline: none; } .att b { font-weight: 600; }
.att-ic { width: 62px; height: 62px; display: grid; place-items: center; border-radius: 20px; background: color-mix(in srgb, var(--c) 10%, var(--panel)); border: 1px solid color-mix(in srgb, var(--c) 24%, transparent); transition: transform .12s var(--ease); }
.att:active .att-ic { transform: scale(.92); } .att:focus-visible .att-ic { box-shadow: 0 0 0 2px var(--c); }
.att-ic svg { width: 28px; height: 28px; fill: var(--c); }
#lightbox { width: auto; max-width: 96vw; border: 0; background: transparent; box-shadow: none; }
#lightbox img { max-width: 96vw; max-height: 90vh; border-radius: var(--r-m); }

/* group info */
.ginfo { padding-bottom: 14px; }
.gi-head { display: flex; align-items: center; gap: 14px; }
.gi-head .avatar { width: 66px; height: 66px; font-size: 24px; cursor: pointer; }
.gi-meta { flex: 1; min-width: 0; } .gi-meta input { font-family: var(--serif); font-size: 19px; font-weight: 700; } .gi-meta small { font-size: 12.5px; color: var(--muted); }
.gi-sub { display: flex; align-items: center; justify-content: space-between; margin: 18px 0 6px; font-weight: 700; color: var(--brand); }
.gi-list { max-height: 46vh; overflow-y: auto; border: 1px solid var(--line); border-radius: var(--r-m); }
.gim { display: flex; align-items: center; gap: 10px; padding: 9px 12px; border-bottom: 1px solid var(--line); } .gim:last-child { border-bottom: 0; }
.gm-meta { flex: 1; min-width: 0; } .gm-meta b { display: block; font-size: 14.5px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; } .gm-meta small { font-size: 12px; color: var(--muted); }
.gm-badge { padding: 2px 8px; border-radius: 999px; font-size: 11px; font-weight: 800; color: #3B2F07; background: var(--gold-grad); }
.gm-act { padding: 4px 9px; border-radius: 8px; font-size: 12px; font-weight: 700; color: var(--brand); background: var(--brand-soft); }
.gm-act.danger { color: var(--danger); background: rgba(211,58,44,.1); }
.gi-foot { display: flex; flex-direction: column; gap: 4px; margin-top: 14px; }
.gi-danger { display: flex; align-items: center; gap: 12px; padding: 12px; border-radius: var(--r-m); text-align: start; color: var(--danger); }
.gi-danger:hover { background: rgba(211,58,44,.06); } .gi-danger span { width: 30px; text-align: center; font-size: 17px; } .gi-danger b { font-weight: 600; }

/* ---------- call screen ---------- */
#callScreen { position: fixed; inset: 0; z-index: 40; display: flex; flex-direction: column; align-items: center; justify-content: space-between; padding: max(48px, env(safe-area-inset-top)) 20px max(36px, env(safe-area-inset-bottom)); color: #fff; background: var(--pat-dark) 0 0 / 72px 72px, radial-gradient(900px 640px at 50% 18%, #1A4F48, #07120F 72%); animation: fadeScale .2s var(--ease); }
#callScreen::after { content: ""; position: absolute; inset: 0; z-index: 1; pointer-events: none; background: linear-gradient(180deg, rgba(0,0,0,.35), transparent 30%, transparent 62%, rgba(0,0,0,.55)); }
#remoteVideo { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; display: none; background: #000; }
#localVideo { position: absolute; z-index: 2; top: max(16px, env(safe-area-inset-top)); inset-inline-end: 16px; width: 112px; aspect-ratio: 3 / 4; object-fit: cover; display: none; border-radius: 16px; border: 2px solid rgba(233,210,127,.75); box-shadow: var(--sh-3); }
#localVideo.mirror, .tile video.mirror { transform: scaleX(-1); }
#callScreen.video #remoteVideo, #callScreen.video #localVideo { display: block; }
#callScreen.video:not(.live) #remoteVideo { display: none !important; }
#callScreen.video:not(.live) #localVideo { inset: 0; top: 0; width: 100%; height: 100%; aspect-ratio: auto; z-index: 0; border: 0; border-radius: 0; opacity: .55; }
.cmin { position: absolute; z-index: 4; top: max(14px, env(safe-area-inset-top)); inset-inline-start: 12px; width: 42px; height: 42px; display: grid; place-items: center; border-radius: 50%; color: #fff; background: rgba(255,255,255,.12); backdrop-filter: blur(8px); }
.cmin svg { width: 26px; height: 26px; fill: currentColor; } .cmin.inline { position: static; width: 36px; height: 36px; flex: none; }
.call-rosette { position: absolute; z-index: 1; left: 50%; top: calc(max(48px, env(safe-area-inset-top)) + 10vh + 58px); width: 300px; height: 300px; margin: -150px 0 0 -150px; opacity: .55; pointer-events: none; }
.call-rings { position: absolute; z-index: 1; left: 50%; top: calc(max(48px, env(safe-area-inset-top)) + 10vh + 58px); width: 0; height: 0; display: none; pointer-events: none; }
#callScreen.ringing .call-rings { display: block; }
.call-rings span { position: absolute; left: -58px; top: -58px; width: 116px; height: 116px; border-radius: 50%; border: 1.5px solid var(--gilt); opacity: 0; animation: ripple 2.4s ease-out infinite; }
.call-rings span:nth-child(2) { animation-delay: .8s; } .call-rings span:nth-child(3) { animation-delay: 1.6s; }
.call-info { position: relative; z-index: 2; display: flex; flex-direction: column; align-items: center; gap: 14px; margin-top: 10vh; text-align: center; }
.call-info .avatar.xl { box-shadow: 0 0 0 5px rgba(6,30,26,.9), 0 18px 40px rgba(0,0,0,.5); }
.call-info h2 { margin: 6px 0 0; font-size: 32px; font-weight: 700; background: var(--gold-grad); -webkit-background-clip: text; background-clip: text; color: transparent; }
.call-info p { margin: 0; font-size: 15px; color: rgba(255,255,255,.75); font-feature-settings: "tnum"; }
#callScreen.video.live .call-rosette, #callScreen.video.live .call-rings { display: none; }
#callScreen.video.live::after { background: linear-gradient(180deg, rgba(0,0,0,.55), transparent 22%, transparent 70%, rgba(0,0,0,.55)); }
#callScreen.video.live .call-info { position: absolute; top: 0; left: 0; right: 0; margin: 0; flex-direction: row; gap: 12px; padding: max(18px, env(safe-area-inset-top)) 150px 20px 66px; text-align: start; }
[dir="rtl"] #callScreen.video.live .call-info { padding: max(18px, env(safe-area-inset-top)) 66px 20px 150px; }
#callScreen.video.live .call-info .avatar.xl { width: 46px; height: 46px; font-size: 18px; box-shadow: none; }
#callScreen.video.live .call-info h2 { margin: 0; min-width: 0; font-size: 19px; color: #fff; background: none; -webkit-text-fill-color: #fff; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.call-btns { position: relative; z-index: 3; display: flex; gap: 28px; margin-top: auto; }
.call-dock { position: relative; z-index: 3; display: flex; align-items: center; gap: 10px; margin-top: auto; max-width: calc(100vw - 24px); overflow-x: auto; padding: 10px 12px; border-radius: 34px; border: 1px solid transparent; background: linear-gradient(rgba(8,20,17,.72), rgba(8,20,17,.72)) padding-box, var(--gold-grad) border-box; backdrop-filter: blur(20px) saturate(140%); -webkit-backdrop-filter: blur(20px) saturate(140%); box-shadow: 0 14px 40px rgba(0,0,0,.4); }
.cbtn { flex: none; width: 54px; height: 54px; border-radius: 50%; display: grid; place-items: center; color: #fff; background: rgba(255,255,255,.13); box-shadow: inset 0 0 0 1px rgba(233,210,127,.25); transition: transform .1s, background .15s; }
.cbtn:active { transform: scale(.92); } .cbtn svg { width: 25px; height: 25px; fill: currentColor; }
.cbtn.off { color: #07120F; background: #fff; } .cbtn.on { background: var(--brand-2); }
.cbtn.decline { width: 62px; border-radius: 27px; background: var(--danger); box-shadow: 0 8px 22px rgba(211,58,44,.45); }
.cbtn.accept { background: var(--ok); box-shadow: 0 0 0 3px rgba(233,210,127,.6), 0 8px 24px rgba(34,179,94,.45); }
#incomingBtns .cbtn { width: 74px; height: 74px; border-radius: 50%; } #incomingBtns .cbtn svg { width: 30px; height: 30px; }
#incomingBtns .cbtn.accept { animation: ring 1.2s infinite; }
.call-mini { position: fixed; top: 0; left: 0; right: 0; z-index: 39; display: flex; align-items: center; gap: 10px; height: 42px; padding: 0 14px; padding-top: env(safe-area-inset-top); cursor: pointer; font-size: 14px; color: #fff; background: var(--head-grad); border-bottom: 1px solid rgba(233,210,127,.5); box-shadow: var(--sh-2); }
.call-mini b { flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; } .call-mini #cmTime { font-feature-settings: "tnum"; }
.cm-back { font-size: 12px; opacity: .85; white-space: nowrap; }
.cm-dot { flex: none; width: 9px; height: 9px; border-radius: 50%; background: #4ADE80; box-shadow: 0 0 0 3px rgba(74,222,128,.3); animation: pulse 1.2s infinite; }
.mini-video { position: fixed; z-index: 39; right: 12px; bottom: 96px; width: 112px; aspect-ratio: 3 / 4; object-fit: cover; cursor: pointer; border-radius: 16px; background: #0C1C19; border: 2px solid var(--gilt); box-shadow: var(--sh-3); }
[dir="rtl"] .mini-video { right: auto; left: 12px; }

/* ---------- class / group call ---------- */
#classScreen { position: fixed; inset: 0; z-index: 41; display: flex; flex-direction: column; padding-bottom: max(14px, env(safe-area-inset-bottom)); color: #fff; background: var(--pat-dark) 0 0 / 72px 72px, radial-gradient(900px 600px at 50% 0%, #143A35, #07100E 70%); animation: fadeScale .2s var(--ease); }
.class-top { position: relative; display: flex; align-items: center; gap: 10px; padding: max(14px, env(safe-area-inset-top)) 14px 14px; }
.class-top::after { content: ""; position: absolute; left: 12px; right: 12px; bottom: 0; height: 1.5px; background: var(--gold-line); opacity: .7; }
.class-top b { flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-family: var(--serif); font-size: 20px; background: var(--gold-grad); -webkit-background-clip: text; background-clip: text; color: transparent; }
.class-meta { padding: 4px 10px; border-radius: 999px; font-size: 13px; color: rgba(255,255,255,.8); background: rgba(255,255,255,.1); font-feature-settings: "tnum"; }
.class-grid { flex: 1; min-height: 0; display: grid; gap: 8px; padding: 10px; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); grid-auto-rows: minmax(150px, 1fr); overflow-y: auto; }
.class-grid[data-n="1"] { grid-template-columns: 1fr; } .class-grid[data-n="2"] { grid-template-columns: 1fr 1fr; }
.class-grid.has-focus { grid-template-columns: 1fr !important; } .class-grid.has-focus .tile:not(.focus) { display: none; }
.tile { position: relative; overflow: hidden; cursor: pointer; border-radius: 18px; border: 1px solid transparent; background: linear-gradient(#11292A, #0C1D1A) padding-box, linear-gradient(135deg, rgba(246,231,166,.45), rgba(156,122,23,.3)) border-box; }
.tile.hand { border: 2px solid var(--gilt-hi); box-shadow: 0 0 0 4px rgba(233,210,127,.18); }
.tile video { display: block; width: 100%; height: 100%; object-fit: cover; background: #0C1C19; }
.tile.focus video { object-fit: contain; }
.tile .tav { position: absolute; inset: 0; display: none; place-items: center; width: 78px; height: 78px; margin: auto; border-radius: 50%; overflow: hidden; font-size: 28px; font-weight: 800; border: 2px solid transparent; background: linear-gradient(135deg, var(--brand-2), var(--brand-deep)) padding-box, var(--gold-grad) border-box; }
.tile .tav img { width: 100%; height: 100%; object-fit: cover; }
.tile.camoff video { visibility: hidden; } .tile.camoff .tav { display: grid; }
.tile .tname { position: absolute; left: 8px; bottom: 8px; max-width: calc(100% - 16px); padding: 4px 10px; border-radius: 999px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-size: 12.5px; font-weight: 600; background: rgba(0,0,0,.55); backdrop-filter: blur(6px); }
.tile .tmic, .tile .thand { position: absolute; top: 8px; display: none; padding: 3px 7px; border-radius: 999px; font-size: 16px; background: rgba(0,0,0,.5); }
.tile .tmic { left: 8px; } .tile .thand { right: 8px; font-size: 20px; }
.tile.micoff .tmic, .tile.hand .thand { display: block; }
.class-dock { margin: 0 auto; }

/* ---------- mobile ---------- */
@media (max-width: 760px) {
  #app { grid-template-columns: 1fr; }
  .side { border: 0; }
  #app.in-chat .side { display: none; }
  #app:not(.in-chat) .main { display: none; }
  #app.in-chat .main { animation: slideIn .22s var(--ease); }
  .side .topbar { min-height: 68px; padding: 12px 14px; padding-top: max(12px, env(safe-area-inset-top)); color: #fff; background: var(--head); }
  .side .topbar::after { display: none; }
  .side .topbar h2 { font-size: 27px; }
  .side .topbar .icon-btn { color: rgba(255,255,255,.92); } .side .topbar .icon-btn:hover { color: #fff; background: rgba(255,255,255,.14); }
  .side .search { position: relative; padding: 4px 12px 20px; background: var(--head); }
  .side .search::after { content: ""; position: absolute; left: 0; right: 0; bottom: 5px; height: 12px; background: var(--band) center / 48px 12px repeat-x; opacity: .9; }
  .side .search input { background-color: rgba(255,255,255,.96); box-shadow: inset 0 0 0 1px rgba(233,210,127,.35); }
  :root[data-theme="dark"] .side .search input { background-color: rgba(255,255,255,.08); color: #fff; }
  .side .list { position: relative; margin-top: -10px; border-radius: 20px 20px 0 0; background: var(--panel); }
  .chat-head { min-height: 58px; } .chat-head b { font-size: 16.5px; }
  .msg { max-width: 86%; }
  .call-dock { gap: 6px; padding: 7px 8px; } .call-dock .cbtn { width: 44px; height: 44px; } .call-dock .cbtn svg { width: 21px; height: 21px; } .call-dock .cbtn.decline { width: 54px; height: 44px; border-radius: 22px; }
  .class-grid { grid-template-columns: 1fr 1fr; grid-auto-rows: minmax(140px, 1fr); } .class-grid[data-n="1"], .class-grid[data-n="2"] { grid-template-columns: 1fr; }
}
@media (min-width: 761px) { .only-mobile { display: none !important; } }
@media (prefers-reduced-motion: reduce) { *, *::before, *::after { animation: none !important; transition: none !important; } }
.placeholder .ph-text { margin-top: 6px; font-family: var(--serif); font-size: 17px; }

/* v11 — safety & account */
.legal-row { display: flex; justify-content: center; gap: 8px; margin-top: 12px; font-size: 13px; color: var(--muted); }
.legal-row a, .legal-note a { color: var(--brand); text-decoration: none; }
.legal-note { margin: 10px 0 0; text-align: center; font-size: 12px; color: var(--muted); }
#btnDelAcc { width: 100%; margin-top: 10px; }
.btn-danger { background: var(--danger); color: #fff; }
.muted-p { margin: -6px 0 12px; color: var(--muted); font-size: 14px; line-height: 1.55; }
.reasons { display: flex; flex-direction: column; border: 1px solid var(--line); border-radius: var(--r-m); margin-bottom: 12px; }
.reasons label { display: flex; align-items: center; gap: 10px; padding: 10px 12px; border-bottom: 1px solid var(--line); cursor: pointer; font-size: 14.5px; }
.reasons label:last-child { border-bottom: 0; } .reasons input { width: 18px; height: 18px; accent-color: var(--brand); }
#rpText { width: 100%; padding: 11px 13px; border-radius: var(--r-m); border: 1px solid var(--line); background: var(--panel-2); resize: vertical; }
.blocked-bar { display: flex; align-items: center; justify-content: center; gap: 10px; padding: 14px; padding-bottom: max(14px, env(safe-area-inset-bottom)); background: var(--panel); color: var(--muted); font-size: 14px; flex: none; }
.uinfo .ui-head { display: flex; flex-direction: column; align-items: center; text-align: center; gap: 6px; }
.uinfo .ui-head h3 { margin: 8px 0 0; } .uinfo .ui-head h3::after { display: none; }
.uinfo .ui-head small { color: var(--muted); } .uinfo .ui-head p { margin: 4px 0 0; color: var(--ink); font-size: 14px; }

/* v11.2 — movable self-view, swap, tuck, peer states, Android PiP */
#callScreen.video.live #localVideo, #callScreen.video.live.swapped #remoteVideo { touch-action: none; cursor: grab; }
#callScreen.video.live.swapped #localVideo { inset: 0; top: 0; left: 0; width: 100%; height: 100%; aspect-ratio: auto; border: 0; border-radius: 0; z-index: 0; box-shadow: none; cursor: default; }
#callScreen.video.live.swapped #remoteVideo { inset: auto; width: 112px; height: auto; aspect-ratio: 3 / 4; z-index: 2; border-radius: 16px; border: 2px solid rgba(233,210,127,.75); box-shadow: var(--sh-3); }
#callScreen video.tucked { opacity: .55; }
#callScreen.video.live .call-info { flex-direction: row; align-items: center; padding-inline-end: 20px; }
#callScreen.video.live .call-info > div, #callScreen.video.live .call-info h2 { min-width: 0; }
#callScreen.video.live .call-info p { flex: none; margin-inline-start: auto; padding: 3px 10px; border-radius: 999px; background: rgba(0,0,0,.35); font-size: 13px; }
.remote-off { position: absolute; inset: 0; z-index: 1; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 16px; padding: 24px; text-align: center; background: var(--pat-dark) 0 0 / 72px 72px, radial-gradient(700px 500px at 50% 40%, #16403A, #07120F 75%); }
.remote-off p { margin: 0; max-width: 300px; font-size: 15px; color: rgba(255,255,255,.85); line-height: 1.5; }
.peer-muted { font-size: 13px; }
body.in-pip #callScreen { padding: 0; }
body.in-pip #callScreen .call-dock, body.in-pip #callScreen .cmin, body.in-pip #callScreen .call-info, body.in-pip #callScreen #localVideo, body.in-pip #callScreen::after { display: none !important; }
body.in-pip #callScreen.swapped #remoteVideo { inset: 0 !important; left: 0 !important; top: 0 !important; width: 100% !important; height: 100% !important; border: 0; border-radius: 0; }

/* v12 — reactions, edit, star, pin */
.msg.has-reacts { margin-bottom: 15px; }
.reacts { position: absolute; bottom: -14px; inset-inline-start: 10px; display: flex; gap: 3px; z-index: 1; }
.rchip { display: inline-flex; align-items: center; gap: 3px; height: 24px; padding: 0 7px; border-radius: 999px; font-size: 13.5px; line-height: 1; background: var(--panel); border: 1px solid var(--line); box-shadow: var(--sh-1); }
.rchip b { font-size: 11.5px; font-weight: 700; color: var(--muted); }
.rchip.mine { border-color: var(--gilt); background: var(--brand-tint); }
.msg .stamp .edited { font-style: italic; margin-inline-end: 4px; }
.msg .stamp .star { font-style: normal; color: var(--gilt); margin-inline-end: 3px; }
.msg.starred::after { width: 74px; } .msg.mine.starred::after { width: 92px; }
.msg:has(.edited)::after { width: 110px; } .msg.mine:has(.edited)::after { width: 128px; }
.react-row { display: flex; justify-content: space-between; gap: 4px; padding: 4px 6px 10px; margin-bottom: 4px; border-bottom: 1px solid var(--line); }
.react-row button { flex: 1; height: 46px; border-radius: 14px; font-size: 25px; display: grid; place-items: center; transition: transform .1s, background .15s; }
.react-row button:active { transform: scale(1.18); } .react-row button.sel { background: var(--brand-soft); box-shadow: inset 0 0 0 1.5px var(--gilt); }
.edit-bar .rq { border-inline-start-color: var(--brand); }
.pin-bar { display: flex; align-items: center; gap: 10px; flex: none; padding: 8px 10px 8px 14px; background: var(--panel); border-bottom: 1px solid var(--line); cursor: pointer; box-shadow: var(--sh-1); }
.pin-ic { font-size: 14px; } .pin-t { flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-size: 14px; }
.pin-bar small { font-size: 12px; font-weight: 700; color: var(--brand); }
.info-row { display: flex; align-items: center; gap: 12px; width: 100%; margin-top: 12px; padding: 12px; border-radius: var(--r-m); background: var(--brand-tint); text-align: start; }
.info-row span { color: var(--gilt); font-size: 17px; width: 30px; text-align: center; } .info-row b { flex: 1; font-weight: 600; } .info-row i { font-style: normal; color: var(--muted); font-size: 20px; }
.star-list { display: flex; flex-direction: column; max-height: 60vh; overflow-y: auto; border: 1px solid var(--line); border-radius: var(--r-m); }
.star-item { display: grid; grid-template-columns: 1fr auto; gap: 2px 10px; padding: 10px 12px; text-align: start; border-bottom: 1px solid var(--line); }
.star-item:last-child { border-bottom: 0; } .star-item:hover { background: var(--brand-tint); }
.star-item b { font-size: 13px; color: var(--brand); } .star-item small { grid-row: 1; grid-column: 2; font-size: 11.5px; color: var(--muted); }
.star-item span { grid-column: 1 / -1; font-size: 14px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }

/* v12.1 — mentions */
.mention { font-weight: 700; color: var(--brand); }
.mention.me { padding: 0 3px; border-radius: 5px; background: rgba(201,162,39,.18); }
.at-chip { flex: none; display: grid; place-items: center; width: 21px; height: 21px; border-radius: 50%; font-size: 12px; font-weight: 800; color: #fff; background: var(--head-grad); margin-inline-start: auto; }
.at-chip + .badge { margin-inline-start: 4px; }
.mention-box { position: relative; z-index: 4; flex: none; margin: 0 10px; max-height: 240px; overflow-y: auto; background: var(--panel); border: 1px solid var(--gold-soft); border-bottom: 0; border-radius: var(--r-m) var(--r-m) 0 0; box-shadow: 0 -8px 20px rgba(15,32,28,.10); animation: rise .15s var(--ease); }
.mopt { display: flex; align-items: center; gap: 10px; width: 100%; padding: 8px 12px; text-align: start; border-bottom: 1px solid var(--line); }
.mopt:last-child { border-bottom: 0; } .mopt:hover { background: var(--brand-tint); }
.mopt b { font-size: 14.5px; font-weight: 600; } .mopt small { margin-inline-start: auto; font-size: 12px; color: var(--muted); }
.mall { width: 40px; height: 40px; border-radius: 50%; display: grid; place-items: center; font-weight: 800; color: #fff; background: var(--head-grad); }

/* v12.2 — poll options, translation */
select.sel { width: 100%; padding: 12px 14px; border-radius: var(--r-m); border: 1px solid var(--line); background: var(--panel-2); }
.pfoot { display: flex; flex-wrap: wrap; align-items: center; justify-content: center; gap: 6px 12px; margin-top: 4px; }
.ptotal { font-size: 12.5px; color: var(--brand); font-weight: 600; } .ptotal[disabled] { color: var(--muted); font-weight: 400; }
.pend { font-size: 12px; color: var(--muted); } .pend.done { color: var(--brand); font-weight: 700; }
.pclose { font-size: 12px; font-weight: 700; color: var(--danger); }
.poll.closed .popt { cursor: default; } .popt.win .ptxt { font-weight: 700; } .popt.win .pbar i { background: var(--gold-grad); }
.voters { display: flex; flex-direction: column; gap: 10px; max-height: 60vh; overflow-y: auto; }
.vgrp { padding: 10px 12px; border-radius: var(--r-m); background: var(--brand-tint); display: flex; flex-wrap: wrap; gap: 6px; }
.vgrp b { width: 100%; font-size: 14.5px; } .vgrp b small { color: var(--brand); margin-inline-start: 6px; }
.vgrp span { padding: 3px 10px; border-radius: 999px; background: var(--panel); font-size: 13px; border: 1px solid var(--line); } .vgrp em { color: var(--muted); }
.trans { margin: 6px 0 2px; padding: 6px 10px; border-radius: 10px; background: rgba(201,162,39,.10); border-inline-start: 3px solid var(--gilt); white-space: pre-wrap; }
.trans small { display: block; font-size: 11px; font-weight: 700; color: var(--gilt); margin-bottom: 2px; }

/* v12.3 — privacy, lock, search, schedule */
.pin-dlg input { text-align: center; font-size: 24px; letter-spacing: .5em; margin-bottom: 10px; }
.pin-dlg #pin2::placeholder { letter-spacing: normal; font-size: 15px; }
.s-results { margin-top: 12px; min-height: 120px; } .s-results mark { background: rgba(201,162,39,.35); color: inherit; border-radius: 3px; padding: 0 2px; }
.sched-bar { background: var(--brand-tint); }
.ta { width: 100%; padding: 12px 14px; border-radius: var(--r-m); border: 1px solid var(--line); background: var(--panel-2); resize: vertical; }
.sched-list { display: flex; flex-direction: column; gap: 8px; max-height: 60vh; overflow-y: auto; }
.sched-item { display: flex; align-items: center; gap: 10px; padding: 10px 12px; border-radius: var(--r-m); background: var(--brand-tint); }
.sched-item > div { flex: 1; min-width: 0; } .sched-item small { display: block; font-size: 12px; color: var(--brand); font-weight: 700; }
.sched-item span { display: block; font-size: 14px; white-space: pre-wrap; word-break: break-word; }
#dlgProfile .sel { margin-bottom: 2px; }

/* v13 — disappearing & view once */
.eph-chip { display: inline-block; margin-top: 2px; font-size: 11.5px; font-weight: 700; color: var(--brand); }
.chat-head small + .eph-chip { margin-inline-start: 0; }
.vo-row { grid-column: 1 / -1; display: flex; align-items: center; gap: 10px; padding: 10px 12px; border-radius: var(--r-m); background: var(--brand-tint); font-size: 14px; cursor: pointer; }
.vo-row input { width: 18px; height: 18px; accent-color: var(--brand); }
.vo-ic { flex: none; width: 24px; height: 24px; border-radius: 50%; display: grid; place-items: center; font-size: 12px; font-weight: 800; border: 2px dashed currentColor; color: var(--brand); }
.vo { display: flex; align-items: center; gap: 10px; min-width: 210px; padding: 6px 2px 16px; text-align: start; }
.vo b { font-size: 14.5px; } .vo small { margin-inline-start: auto; font-size: 12px; color: var(--muted); }
.vo.open { cursor: pointer; } .vo.open .vo-ic { border-style: solid; background: var(--head-grad); color: #fff; border-color: transparent; }
.vo.done { color: var(--muted); font-style: italic; } .vo.done .vo-ic { color: var(--muted); }
#lightbox video { max-width: 96vw; max-height: 90vh; border-radius: var(--r-m); background: #000; }
.cn-row { display: flex; align-items: center; gap: 6px; min-width: 0; } .cn-row b { min-width: 0; }
.eph-chip { flex: none; margin: 0; padding: 1px 7px; border-radius: 999px; background: var(--brand-soft); font-family: var(--font); }

/* v13.3 — voice transcript (sits under the player; the player row itself is untouched) */
.vt-btn { display: inline-flex; align-items: center; gap: 4px; margin: 6px 0 0; padding: 4px 10px; border-radius: 999px; font-size: 12.5px; font-weight: 600; color: var(--brand); background: var(--brand-soft); }
.vt-btn[disabled] { opacity: .7; }
.vt { margin-top: 8px; padding: 7px 10px; border-radius: 10px; background: rgba(15,32,28,.05); border-inline-start: 3px solid var(--gilt); }
.msg.mine .vt { background: rgba(255,255,255,.45); }
.vt small { display: block; font-size: 11px; color: var(--muted); margin-bottom: 2px; }
.vt p { margin: 0; font-size: 14.5px; line-height: 1.55; white-space: pre-wrap; word-break: break-word; max-height: 7.8em; overflow: hidden; cursor: pointer; -webkit-mask: linear-gradient(#000 70%, transparent); mask: linear-gradient(#000 70%, transparent); }
.vt p.open { max-height: none; -webkit-mask: none; mask: none; }

/* ================= v14 — status · stickers · editor · downloads · app lock ================= */
/* status strip (top of chat list) */
.status-strip { display: flex; gap: 14px; overflow-x: auto; padding: 12px 14px 10px; background: var(--panel); border-bottom: 1px solid var(--line); flex: none; scrollbar-width: none; }
.status-strip::-webkit-scrollbar { display: none; }
.st-item { flex: none; width: 64px; display: flex; flex-direction: column; align-items: center; gap: 5px; }
.st-item small { max-width: 64px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-size: 11.5px; color: var(--muted); }
.st-ring { position: relative; width: 58px; height: 58px; border-radius: 50%; padding: 3px; display: grid; place-items: center; background: var(--line); }
.st-item.unseen .st-ring { background: conic-gradient(from 200deg, #F6E7A6, #D4AF37, #0F766E, #16A08E, #F6E7A6); }
.st-item.mine.has .st-ring { background: conic-gradient(from 200deg, #16A08E, #0F766E, #16A08E); }
.st-ring .avatar { width: 52px; height: 52px; border: 2.5px solid var(--panel); background: linear-gradient(135deg, var(--brand-2), var(--brand-deep)); font-size: 18px; }
.st-plus { position: absolute; right: -2px; bottom: -2px; width: 22px; height: 22px; border-radius: 50%; display: grid; place-items: center; font-style: normal; font-weight: 800; color: #fff; background: var(--head-grad); border: 2px solid var(--panel); font-size: 15px; line-height: 1; }
@media (max-width: 760px) {
  .side .status-strip { position: relative; margin-top: -10px; border-radius: 20px 20px 0 0; }
  .side .status-strip + .list { margin-top: 0; border-radius: 0; }
}
/* full-screen dialogs */
dialog.full { width: 100vw; max-width: 100vw; height: 100dvh; max-height: 100dvh; margin: 0; border: 0; border-radius: 0; background: #000; color: #fff; padding: 0; }
.st-compose { position: relative; height: 100%; display: flex; align-items: center; justify-content: center; padding: 80px 24px 100px; transition: background .3s; }
.st-top { position: absolute; top: max(14px, env(safe-area-inset-top)); left: 14px; right: 14px; display: flex; justify-content: space-between; }
#stTInput { width: 100%; max-width: 560px; min-height: 40vh; resize: none; border: 0; background: none; color: #fff; text-align: center; font-family: "Amiri", "Hind Siliguri", var(--font); font-size: clamp(24px, 6vw, 34px); line-height: 1.5; outline: none; }
#stTInput::placeholder { color: rgba(255,255,255,.6); }
.st-send { position: absolute; right: 20px; bottom: max(24px, env(safe-area-inset-bottom)); width: 58px; height: 58px; border-radius: 50%; display: grid; place-items: center; color: #fff; background: var(--head-grad); box-shadow: 0 0 0 2px var(--gilt), 0 10px 26px rgba(0,0,0,.4); }
.st-send svg { width: 24px; height: 24px; fill: currentColor; }
[dir="rtl"] .st-send { right: auto; left: 20px; } [dir="rtl"] .st-send svg { transform: scaleX(-1); }
/* status viewer */
.sv { position: relative; height: 100%; display: flex; flex-direction: column; background: #000; }
.sv-bars { position: absolute; top: max(8px, env(safe-area-inset-top)); left: 10px; right: 10px; z-index: 3; display: flex; gap: 4px; }
.sv-bars span { flex: 1; height: 3px; border-radius: 3px; background: rgba(255,255,255,.3); overflow: hidden; }
.sv-bars span i { display: block; width: 0; height: 100%; background: #fff; } .sv-bars span.done i { width: 100% !important; transition: none !important; }
.sv-head { position: absolute; top: calc(max(8px, env(safe-area-inset-top)) + 10px); left: 10px; right: 10px; z-index: 3; display: flex; align-items: center; gap: 10px; }
.sv-meta { flex: 1; min-width: 0; } .sv-meta b { display: block; font-size: 15px; } .sv-meta small { font-size: 12px; opacity: .8; }
.sv-body { flex: 1; display: grid; place-items: center; overflow: hidden; }
.sv-body img, .sv-body video { max-width: 100%; max-height: 100%; object-fit: contain; }
.sv-text { margin: 0; padding: 30px; max-width: 640px; text-align: center; font-family: "Amiri", "Hind Siliguri", var(--font); font-size: clamp(24px, 6vw, 36px); line-height: 1.5; white-space: pre-wrap; }
.sv-nav { position: absolute; top: 90px; bottom: 90px; width: 35%; z-index: 2; background: none; } .sv-nav.prev { left: 0; } .sv-nav.next { right: 0; }
[dir="rtl"] .sv-nav.prev { left: auto; right: 0; } [dir="rtl"] .sv-nav.next { right: auto; left: 0; }
.sv-foot { position: absolute; left: 0; right: 0; bottom: 0; z-index: 3; padding: 20px 20px max(20px, env(safe-area-inset-bottom)); text-align: center; background: linear-gradient(transparent, rgba(0,0,0,.6)); }
.sv-foot span { display: block; font-size: 15px; margin-bottom: 8px; white-space: pre-wrap; }
.sv-views { padding: 7px 16px; border-radius: 999px; color: #fff; background: rgba(255,255,255,.15); font-size: 14px; }
.sv .cbtn, .st-top .cbtn, .ed .cbtn { width: 42px; height: 42px; font-size: 17px; }
/* stickers */
.stk { position: relative; width: 150px; height: 150px; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 4px; padding: 14px; text-align: center; color: #F6E7A6; filter: drop-shadow(0 6px 14px rgba(8,40,36,.35)); }
.stk::before { content: ""; position: absolute; inset: 0; z-index: -1; background: var(--pat) center / 46px 46px, radial-gradient(circle at 50% 35%, #16857A, #08453D 70%); background-blend-mode: soft-light, normal; border: 3px solid transparent; }
.stk-circle::before { border-radius: 50%; box-shadow: inset 0 0 0 3px #08453D, inset 0 0 0 5px #D4AF37; }
.stk-arch::before { border-radius: 50% 50% 18px 18px / 40% 40% 18px 18px; box-shadow: inset 0 0 0 3px #08453D, inset 0 0 0 5px #D4AF37; }
.stk-ribbon::before { border-radius: 26px; box-shadow: inset 0 0 0 3px #08453D, inset 0 0 0 5px #D4AF37; background: var(--pat) center / 46px 46px, linear-gradient(140deg, #0F766E, #06312B); }
.stk-ar { max-width: 118px; font-family: "Amiri", serif; font-weight: 700; font-size: 22px; line-height: 1.35; direction: rtl; background: var(--gold-grad); -webkit-background-clip: text; background-clip: text; color: transparent; }
.stk-en { font-size: 10.5px; letter-spacing: .04em; color: rgba(246,231,166,.85); font-weight: 600; }
.stk-img { width: 150px; height: 150px; object-fit: cover; border-radius: 28px; display: block; }
.msg.sticker { background: none !important; border: 0 !important; box-shadow: none !important; padding: 2px 2px 18px; }
.msg.sticker::after { display: none; }
.msg.sticker .stamp { background: var(--panel); padding: 3px 8px; border-radius: 999px; box-shadow: var(--sh-1); }
.stk-sheet { padding: 12px 12px calc(16px + env(safe-area-inset-bottom)); }
.stk-tabs { display: flex; gap: 6px; margin-bottom: 12px; }
.stk-tabs button { flex: 1; padding: 9px; border-radius: 999px; background: var(--bg); font-weight: 600; } .stk-tabs button.on { background: var(--head-grad); color: #fff; }
.stk-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(110px, 1fr)); gap: 10px; max-height: 52vh; overflow-y: auto; padding: 4px; }
.stk-cell { position: relative; display: grid; place-items: center; aspect-ratio: 1; border-radius: 18px; background: var(--brand-tint); overflow: hidden; }
.stk-cell .stk { position: absolute; left: 50%; top: 50%; transform: translate(-50%, -50%) scale(.66); } .stk-cell .stk-img { width: 100%; height: 100%; border-radius: 18px; }
.stk-add { flex-direction: column; color: var(--brand); border: 2px dashed var(--gold-soft); } .stk-add span { font-size: 34px; font-weight: 300; line-height: 1; } .stk-add small { font-size: 12px; }
/* photo editor */
.ed { height: 100%; display: flex; flex-direction: column; background: #0B1210; }
.ed-top { display: flex; align-items: center; justify-content: space-between; gap: 8px; padding: max(12px, env(safe-area-inset-top)) 12px 10px; }
.ed-tools { display: flex; gap: 6px; } .ed .cbtn.on { background: var(--brand-2); }
.ed-colors { display: flex; justify-content: center; gap: 10px; padding: 4px 12px 10px; }
.ed-colors button { width: 28px; height: 28px; border-radius: 50%; border: 2px solid rgba(255,255,255,.4); } .ed-colors button.on { border-color: var(--gilt-hi); transform: scale(1.18); }
.ed-stage { flex: 1; min-height: 0; display: grid; place-items: center; padding: 8px; }
#edCanvas { max-width: 100%; max-height: 100%; touch-action: none; border-radius: 6px; box-shadow: 0 10px 40px rgba(0,0,0,.5); }
.ed-foot { position: relative; display: flex; align-items: center; gap: 10px; padding: 10px 12px max(14px, env(safe-area-inset-bottom)); }
.ed-foot input { flex: 1; padding: 13px 16px; border-radius: 24px; border: 1px solid rgba(255,255,255,.2); background: rgba(255,255,255,.08); color: #fff; }
.ed-foot .st-send { position: static; }
/* download placeholder */
.dl-ph { display: flex; align-items: center; gap: 10px; min-width: 220px; margin: 2px -5px 16px; padding: 18px 14px; border-radius: 14px; background: var(--pat) 0 0 / 40px 40px, var(--brand-tint); border: 1px dashed var(--gold-soft); text-align: start; }
.dl-ph span { font-size: 24px; } .dl-ph b { font-size: 14px; font-weight: 600; } .dl-ph small { margin-inline-start: auto; font-size: 12px; color: var(--muted); }
.dl-grid { display: grid; grid-template-columns: 1fr auto auto; gap: 8px 18px; align-items: center; padding: 10px 12px; border-radius: var(--r-m); background: var(--brand-tint); font-size: 14px; }
.dl-grid b { font-size: 12.5px; color: var(--muted); font-weight: 600; text-align: center; }
.dl-grid input { width: 18px; height: 18px; justify-self: center; accent-color: var(--brand); }
/* fingerprint lock screen (calls still appear above it) */
.bio-lock { position: fixed; inset: 0; z-index: 38; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 12px; padding: 24px; text-align: center; background: var(--pat) 0 0 / 64px 64px, radial-gradient(700px 500px at 50% 40%, var(--brand-soft), var(--bg)); }
.bio-lock img { width: 84px; height: 84px; border-radius: 50% 50% 18px 18px / 44% 44% 18px 18px; box-shadow: 0 0 0 3px var(--bg), 0 0 0 5px var(--gilt); }
.bio-lock b { font-family: var(--serif); font-size: 30px; } .bio-lock p { margin: 0 0 8px; color: var(--muted); } .bio-lock .btn { width: auto; padding: 12px 28px; }

/* ================= v15 — Islamic features ================= */
/* ayah / hadith card */
.msg.icard-msg { padding: 6px; max-width: min(88%, 520px); }
.msg.icard-msg::after { display: none; }
.icard { position: relative; margin-bottom: 18px; padding: 14px 16px 12px; border-radius: 16px; color: #F3EFE4; background: var(--pat) 0 0 / 54px 54px, radial-gradient(500px 300px at 50% 0%, #11665C, #06312B 75%); background-blend-mode: soft-light, normal; box-shadow: inset 0 0 0 1px rgba(233,210,127,.55), inset 0 0 0 5px rgba(6,49,43,.9), inset 0 0 0 6px rgba(233,210,127,.35); }
.ic-head { display: flex; align-items: center; justify-content: center; gap: 8px; margin-bottom: 10px; }
.ic-head b { font-family: var(--serif); font-size: 15px; letter-spacing: .03em; background: var(--gold-grad); -webkit-background-clip: text; background-clip: text; color: transparent; }
.ic-badge { font-family: "Amiri", serif; color: var(--gilt-hi); font-size: 14px; }
.ic-ar { font-family: "Amiri", "Noto Naskh Arabic", serif; font-size: 23px; line-height: 2.05; text-align: center; color: #FFF8E1; white-space: normal; }
.ic-num { font-size: 17px; color: var(--gilt-hi); }
.ic-tr { margin-top: 10px; padding-top: 10px; border-top: 1px solid rgba(233,210,127,.3); font-size: 14.5px; line-height: 1.65; color: rgba(243,239,228,.92); white-space: normal; }
.ic-tr i { font-style: normal; color: var(--gilt-hi); font-size: 12px; }
.ic-ref { margin-top: 10px; text-align: center; font-size: 12.5px; font-weight: 600; color: var(--gilt-hi); }
.ic-ref small { display: block; font-weight: 400; color: rgba(243,239,228,.7); margin-top: 2px; }
.icard-msg .stamp { background: rgba(6,49,43,.85); color: #E9D27F; padding: 3px 8px; border-radius: 999px; }
.is-dlg .sel { margin-bottom: 10px; }
.is-row { display: flex; align-items: flex-end; gap: 8px; } .is-row label { flex: 1; font-size: 12.5px; color: var(--muted); } .is-row label input { margin-top: 4px; }
.is-row .btn { width: auto; padding: 12px 18px; }
.is-preview { margin-top: 12px; max-height: 42vh; overflow-y: auto; } .is-preview .icard { margin-bottom: 0; }
/* prayer bar & dialog */
.prayer-bar { display: flex; align-items: center; gap: 10px; width: 100%; padding: 9px 16px; background: var(--brand-tint); border-bottom: 1px solid var(--line); text-align: start; font-size: 13.5px; flex: none; }
.prayer-bar span { flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; } .prayer-bar b { color: var(--brand); } .prayer-bar span span { color: var(--muted); } .prayer-bar i { font-style: normal; color: var(--muted); }
.pr-place { display: flex; align-items: center; justify-content: space-between; gap: 8px; margin-bottom: 10px; font-size: 14px; }
.pr-list { display: flex; flex-direction: column; gap: 6px; margin-bottom: 4px; }
.pr-row { display: flex; justify-content: space-between; padding: 11px 14px; border-radius: var(--r-m); background: var(--panel-2); border: 1px solid var(--line); font-size: 15px; }
.pr-row span { font-feature-settings: "tnum"; font-weight: 600; }
.pr-row.next { background: var(--head-grad); color: #fff; border-color: transparent; box-shadow: inset 0 0 0 1px rgba(233,210,127,.5); }
.pr-hijri { text-align: center; font-family: "Amiri", serif; font-size: 17px; color: var(--gilt); margin-top: 6px; direction: rtl; }
/* hifz & attendance */
.hz-pane { max-height: 56vh; overflow-y: auto; }
.att-s { border: 1px solid var(--line); border-radius: var(--r-m); margin-bottom: 8px; background: var(--panel-2); }
.att-s summary { display: flex; justify-content: space-between; gap: 10px; padding: 11px 14px; cursor: pointer; list-style: none; font-size: 14px; } .att-s summary::-webkit-details-marker { display: none; }
.att-s summary span { color: var(--brand); font-weight: 700; }
.att-names { display: flex; flex-wrap: wrap; gap: 6px; padding: 0 12px 12px; }
.att-names span { padding: 3px 10px; border-radius: 999px; font-size: 13px; } .att-names .in { background: var(--brand-soft); color: var(--brand); } .att-names .out { background: rgba(211,58,44,.08); color: var(--danger); }
.hz-add { margin: 10px 0; }
.hz-prog { padding: 12px 14px; border-radius: var(--r-m); background: var(--brand-tint); margin-bottom: 10px; }
.hz-prog div { display: flex; justify-content: space-between; gap: 8px; font-size: 13.5px; margin-bottom: 8px; } .hz-prog span { color: var(--brand); font-weight: 700; font-feature-settings: "tnum"; }
.hz-prog i { display: block; height: 8px; border-radius: 8px; background: rgba(15,32,28,.08); overflow: hidden; } .hz-prog u { display: block; height: 100%; background: linear-gradient(90deg, var(--brand), var(--gilt)); }
.hz-row { display: flex; align-items: center; gap: 10px; padding: 10px 12px; border-radius: var(--r-m); border: 1px solid var(--line); margin-bottom: 6px; border-inline-start: 4px solid var(--brand); font-size: 14px; }
.hz-row.g-ex { border-inline-start-color: var(--gilt); } .hz-row.g-weak { border-inline-start-color: var(--danger); }
.hz-row > div { flex: 1; min-width: 0; } .hz-row small { display: block; font-size: 12px; color: var(--muted); } .hz-row > span { font-size: 12px; font-weight: 700; color: var(--brand); }
.hz-del { width: 26px; height: 26px; border-radius: 50%; color: var(--muted); background: var(--bg); }
/* Ramadan & Eid */
body.ramadan .side .topbar, body.eid .side .topbar { background: var(--pat) 0 0 / 56px 56px, linear-gradient(140deg, #0B3B5C, #0A4E46 60%, #06312B); background-blend-mode: soft-light, normal; }
body.ramadan .side .search, body.eid .side .search { background: linear-gradient(140deg, #0A4E46, #06312B); }
body.ramadan .side .topbar h2::after { content: " ☪"; color: var(--gilt-hi); font-size: .7em; }
body.eid .side .topbar h2::after { content: " ✨"; font-size: .7em; }
body.ramadan .side .topbar::before, body.eid .side .topbar::before { content: ""; position: absolute; top: 0; inset-inline-end: 64px; width: 26px; height: 58px; pointer-events: none; opacity: .95;
  background: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 26 58'%3E%3Cpath d='M13 0v16' stroke='%23E9D27F' stroke-width='1.2'/%3E%3Cpath d='M7 18h12l-2 4H9z' fill='%23D4AF37'/%3E%3Cpath d='M8 22h10c2 6 2 14 0 20H8c-2-6-2-14 0-20z' fill='%23F6E7A6' fill-opacity='.25' stroke='%23D4AF37' stroke-width='1.2'/%3E%3Cpath d='M13 24v16M10 24c-1 5-1 11 0 16M16 24c1 5 1 11 0 16' stroke='%23D4AF37' stroke-width='.8'/%3E%3Cpath d='M9 42h8l-2 4h-4z' fill='%23D4AF37'/%3E%3Ccircle cx='13' cy='32' r='2.4' fill='%23FFE08A'/%3E%3C/svg%3E") center top / contain no-repeat; animation: sway 4s ease-in-out infinite; transform-origin: top center; }
@keyframes sway { 50% { transform: rotate(5deg); } }
body.ramadan .prayer-bar { background: linear-gradient(90deg, rgba(11,59,92,.10), rgba(201,162,39,.12)); }
@media (max-width: 760px) { .side .prayer-bar + .list { margin-top: 0; border-radius: 0; } }

/* ================= v16 — channels · communities · invites ================= */
.side-tabs { display: flex; gap: 4px; padding: 6px 12px 8px; background: var(--panel); flex: none; }
.side-tabs button { flex: 1; padding: 8px 6px; border-radius: 999px; font-size: 13.5px; font-weight: 600; color: var(--muted); }
.side-tabs button.on { color: #fff; background: var(--head-grad); box-shadow: inset 0 0 0 1px rgba(233,210,127,.45); }
.side:not([data-tab="chats"]) #statusStrip, .side:not([data-tab="chats"]) #prayerBar, .side:not([data-tab="chats"]) #chatList, .side:not([data-tab="chats"]) #results, .side:not([data-tab="chats"]) #tip { display: none !important; }
.side:not([data-tab="channels"]) #chanPane, .side:not([data-tab="communities"]) #commPane { display: none !important; }
.side:not([data-tab="chats"]) .search { display: none; }
.pane-actions { padding: 12px 14px 6px; } .pane-actions .btn { padding: 11px; }
.pane-search { width: calc(100% - 28px); margin: 6px 14px 4px; padding: 10px 16px; border-radius: 999px; border: 1px solid var(--line); background: var(--bg); }
.pane-h { padding: 12px 16px 4px; font-size: 12px; font-weight: 800; letter-spacing: .04em; color: var(--brand); text-transform: uppercase; }
.pane-note { padding: 10px 16px; margin: 0; }
.empty.small { padding: 14px 18px; font-size: 13.5px; }
@media (max-width: 760px) {
  .side .side-tabs { background: var(--head); padding-top: 0; }
  .side .side-tabs button { color: rgba(255,255,255,.8); } .side .side-tabs button.on { background: rgba(255,255,255,.16); color: #fff; }
  .side[data-tab="channels"] #chanPane, .side[data-tab="communities"] #commPane { margin-top: -10px; border-radius: 20px 20px 0 0; position: relative; }
}
/* channel view */
.ch-follow { flex: none; padding: 8px 16px; border-radius: 999px; font-weight: 700; font-size: 13.5px; color: #fff; background: var(--head-grad); box-shadow: inset 0 0 0 1px rgba(233,210,127,.45); }
.ch-follow.on { color: var(--brand); background: var(--brand-soft); box-shadow: none; }
.ch-desc { flex: none; padding: 10px 16px; font-size: 13.5px; color: var(--muted); background: var(--panel); border-bottom: 1px solid var(--line); white-space: pre-wrap; }
.ch-posts { flex: 1; min-height: 0; overflow-y: auto; display: flex; flex-direction: column; gap: 12px; padding: 14px 12px 18px; }
.post { align-self: center; width: 100%; max-width: 560px; padding: 10px 12px 8px; border-radius: 16px; background: var(--theirs); box-shadow: var(--sh-1); border: 1px solid rgba(15,32,28,.05); animation: pop .18s var(--ease); }
.post .pic, .post .vid { display: block; width: calc(100% + 24px); max-width: none; margin: -10px -12px 8px; border-radius: 16px 16px 0 0; max-height: 460px; object-fit: cover; cursor: zoom-in; }
.post-text { font-size: 15.5px; line-height: 1.6; white-space: pre-wrap; word-break: break-word; }
.post-foot { display: flex; align-items: center; gap: 8px; margin-top: 8px; position: relative; }
.reacts-inline { display: flex; flex-wrap: wrap; gap: 4px; flex: 1; } .rchip.add { opacity: .75; font-size: 12px; }
.post-time { font-size: 11.5px; color: var(--muted); } .post-del { font-size: 13px; opacity: .7; }
.react-pop { position: absolute; bottom: 30px; left: 0; z-index: 3; display: flex; gap: 2px; padding: 4px; border-radius: 999px; background: var(--panel); box-shadow: var(--sh-3); }
.react-pop button { width: 38px; height: 38px; border-radius: 50%; font-size: 21px; } .react-pop button:active { transform: scale(1.2); }
/* invites, join, community */
.inv-box { display: flex; align-items: center; gap: 8px; padding: 10px 12px; border-radius: var(--r-m); background: var(--brand-tint); border: 1px dashed var(--gold-soft); }
.inv-box code { flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-size: 13px; direction: ltr; }
.inv-acts { display: flex; gap: 8px; margin: 10px 0 2px; } .inv-acts .btn { padding: 10px; }
.join-dlg, .comm-head { text-align: center; display: flex; flex-direction: column; align-items: center; gap: 6px; }
.join-dlg h3::after, .comm-head h3::after { display: none; } .join-dlg .actions { width: 100%; }
.comm-dlg .info-row { margin-top: 10px; } .comm-dlg #cvGroups { border: 1px solid var(--line); border-radius: var(--r-m); overflow: hidden; }
.comm-dlg .actions { flex-wrap: wrap; }
.comm-av { border-radius: 14px; }
@media (max-width: 760px) {
  .side .search { padding-bottom: 6px; } .side .search::after { display: none; }
  .side .side-tabs { position: relative; padding: 2px 12px 20px; }
  .side .side-tabs::after { content: ""; position: absolute; left: 0; right: 0; bottom: 5px; height: 12px; background: var(--band) center / 48px 12px repeat-x; opacity: .9; }
}

/* ================= v17 — ilmChat Business ================= */
dialog.full-sheet { width: min(560px, 100vw); max-height: 92dvh; }
dialog.full-sheet .dlg { max-height: 92dvh; overflow-y: auto; }
.bz-switch { padding: 12px 14px; border-radius: var(--r-m); background: var(--brand-tint); margin-bottom: 6px; }
#bzForm.dim { opacity: .5; pointer-events: none; }
.bz-hours { display: flex; flex-direction: column; gap: 6px; }
.bz-day { display: grid; grid-template-columns: 90px 1fr auto 1fr; gap: 8px; align-items: center; font-size: 14px; }
.bz-day label { display: flex; align-items: center; gap: 6px; } .bz-day input[type="checkbox"] { width: 18px; height: 18px; accent-color: var(--brand); }
.bz-day input[type="time"] { padding: 8px 10px !important; }
.bz-tools { margin-top: 14px; display: flex; flex-direction: column; gap: 0; } .bz-tools .info-row { margin-top: 8px; }
.bz-card { margin-top: 14px; padding: 14px; border-radius: var(--r-m); text-align: center; background: linear-gradient(var(--panel), var(--panel)) padding-box, var(--gold-grad) border-box; border: 1.5px solid transparent; }
.bz-badge { display: inline-block; padding: 3px 12px; border-radius: 999px; font-size: 12.5px; font-weight: 700; color: #3B2F07; background: var(--gold-grad); }
.bz-open { margin-top: 6px; font-size: 13px; font-weight: 600; } .bz-card p { margin: 8px 0 0; font-size: 14px; color: var(--muted); }
.bz-links { display: flex; flex-direction: column; gap: 6px; margin: 10px 0; text-align: start; } .bz-links a { color: var(--ink); text-decoration: none; font-size: 14px; padding: 8px 10px; border-radius: 10px; background: var(--brand-tint); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
/* shop */
.shop-dlg { padding: 0; } .shop-head { position: sticky; top: 0; z-index: 2; display: flex; align-items: center; gap: 10px; padding: 14px 16px; background: var(--panel); border-bottom: 1px solid var(--line); }
.shop-head > div:not(.avatar) { flex: 1; min-width: 0; } .shop-head b { display: block; font-family: var(--serif); font-size: 18px; } .shop-head small { font-size: 12.5px; }
.cbtn-lite { width: 36px; height: 36px; border-radius: 50%; background: var(--bg); }
.shop-dlg > .btn { width: calc(100% - 32px); margin: 12px 16px 0; }
.shop-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); gap: 12px; padding: 14px 16px 90px; }
.pcard { display: flex; flex-direction: column; gap: 4px; padding: 8px; border-radius: 16px; background: var(--panel-2); border: 1px solid var(--line); }
.pcard.out { opacity: .6; } .pc-img { aspect-ratio: 1; border-radius: 12px; overflow: hidden; background: var(--brand-tint); display: grid; place-items: center; font-size: 34px; cursor: zoom-in; }
.pc-img img { width: 100%; height: 100%; object-fit: cover; } .pcard b { font-size: 14px; line-height: 1.3; } .pc-price { font-weight: 800; color: var(--brand); font-size: 14.5px; } .pcard small { color: var(--danger); font-size: 12px; }
.pc-acts { display: flex; align-items: center; justify-content: space-between; gap: 6px; margin-top: auto; padding-top: 4px; } .pc-acts .gm-act { min-width: 34px; font-size: 15px; } .pc-qty { font-weight: 800; font-feature-settings: "tnum"; }
.cart-bar { position: sticky; bottom: 0; display: flex; align-items: center; gap: 10px; padding: 12px 16px calc(12px + env(safe-area-inset-bottom)); background: var(--panel); border-top: 1px solid var(--line); box-shadow: 0 -8px 20px rgba(15,32,28,.08); }
.cart-bar span { flex: 1; font-weight: 700; } .cart-bar .btn { width: auto; padding: 11px 18px; }
.pd-photo { aspect-ratio: 16 / 10; border-radius: var(--r-m); background: var(--brand-tint); border: 1px dashed var(--gold-soft); display: grid; place-items: center; overflow: hidden; cursor: pointer; color: var(--muted); font-size: 14px; }
.pd-photo img { width: 100%; height: 100%; object-fit: cover; }
.order-list { border: 1px solid var(--line); border-radius: var(--r-m); padding: 6px 12px; }
.od-row { display: flex; justify-content: space-between; gap: 10px; padding: 6px 0; font-size: 14px; border-bottom: 1px dashed var(--line); } .od-row:last-child { border-bottom: 0; }
.od-row.total { font-size: 15px; } .od-row.total b { color: var(--brand); }
/* product & order cards in chat */
.msg.card-msg { min-width: min(280px, 82vw); } .msg.card-msg::after { display: none; }
.prod-card { display: flex; flex-direction: column; gap: 6px; margin-bottom: 16px; } .prod-card img { width: calc(100% + 10px); margin: -2px -5px 0; aspect-ratio: 4 / 3; object-fit: cover; border-radius: 14px; }
.prod-card b { display: block; font-size: 15px; } .prod-card span { font-weight: 800; color: var(--brand); } .prod-card small { display: block; color: var(--muted); font-size: 13px; } .prod-card .btn { padding: 9px; }
.order-card { margin-bottom: 16px; } .oc-head { display: flex; align-items: center; justify-content: space-between; gap: 8px; margin-bottom: 6px; } .oc-head b { font-size: 15px; }
.oc-st { padding: 2px 10px; border-radius: 999px; font-size: 12px; font-weight: 800; background: var(--brand-soft); color: var(--brand); }
.oc-st.st-new { background: rgba(201,162,39,.18); color: #8A6D12; } .oc-st.st-done { background: var(--head-grad); color: #fff; } .oc-st.st-cancel { background: rgba(211,58,44,.1); color: var(--danger); }
.oc-note, .oc-pay { margin: 8px 0 0; font-size: 13px; padding: 6px 10px; border-radius: 10px; background: rgba(15,32,28,.04); white-space: pre-wrap; }
.oc-acts { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 10px; }
/* labels & quick replies */
.label-bar { display: flex; gap: 6px; overflow-x: auto; padding: 8px 12px; background: var(--panel); border-bottom: 1px solid var(--line); flex: none; scrollbar-width: none; }
.lb-chip { flex: none; padding: 5px 12px; border-radius: 999px; font-size: 12.5px; font-weight: 600; border: 1.5px solid var(--lc, var(--line)); color: var(--lc, var(--ink)); background: var(--panel); }
.lb-chip.on { background: var(--lc, var(--brand)); color: #fff; border-color: transparent; }
.lb-dot { display: inline-block; width: 9px; height: 9px; border-radius: 50%; margin-inline-start: 6px; vertical-align: middle; }
.side:not([data-tab="chats"]) #labelBar { display: none !important; }
.qk-list { display: flex; flex-direction: column; gap: 6px; margin-bottom: 10px; max-height: 40vh; overflow-y: auto; }
.qk-row { display: grid; grid-template-columns: auto 1fr auto; gap: 8px; align-items: center; padding: 8px 10px; border-radius: var(--r-m); background: var(--brand-tint); font-size: 13.5px; }
.qk-row b { color: var(--brand); } .qk-row span { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
@media (max-width: 760px) { dialog.full-sheet { width: 100vw; max-width: 100vw; height: 100dvh; max-height: 100dvh; margin: 0; border-radius: 0; border: 0; } dialog.full-sheet .dlg { max-height: 100dvh; min-height: 100dvh; } }

/* ================= v18 — message context menu · attachment sheet · selection ================= */
/* no stray text-selection handles on bubbles; use "Select text" instead */
.msg, .msg * { -webkit-user-select: none; user-select: none; -webkit-touch-callout: none; }
.sel-text { max-height: 55vh; overflow-y: auto; padding: 12px 14px; border-radius: var(--r-m); background: var(--panel-2); border: 1px solid var(--line); font-size: 16px; line-height: 1.6; white-space: pre-wrap; word-break: break-word; -webkit-user-select: text; user-select: text; }
/* floating context menu */
dialog.ctx { width: 100vw; max-width: 100vw; height: 100dvh; max-height: 100dvh; margin: 0; padding: 0; border: 0; border-radius: 0; background: transparent; box-shadow: none; animation: none; overflow: hidden; }
dialog.ctx::backdrop { background: rgba(8,18,16,.42); backdrop-filter: blur(10px) saturate(120%); -webkit-backdrop-filter: blur(10px) saturate(120%); }
.ctx-wrap { position: absolute; left: 12px; right: 12px; display: flex; flex-direction: column; align-items: flex-start; gap: 8px; animation: ctxIn .22s cubic-bezier(.2,.9,.25,1.15); }
.ctx-wrap.mine { align-items: flex-end; }
@keyframes ctxIn { from { opacity: 0; transform: scale(.94); } }
.ctx-react { display: flex; gap: 2px; padding: 5px 6px; margin: 0; border: 0; border-radius: 999px; background: var(--panel); box-shadow: var(--sh-3), 0 0 0 1px rgba(201,162,39,.25); }
.ctx-react button { width: 42px; height: 42px; flex: none; border-radius: 50%; font-size: 24px; position: relative; display: grid; place-items: center; transition: transform .12s; animation: popIn .26s cubic-bezier(.2,.9,.3,1.4) both; }
.ctx-react button:nth-child(2) { animation-delay: .03s } .ctx-react button:nth-child(3) { animation-delay: .06s } .ctx-react button:nth-child(4) { animation-delay: .09s } .ctx-react button:nth-child(5) { animation-delay: .12s } .ctx-react button:nth-child(6) { animation-delay: .15s }
@keyframes popIn { from { opacity: 0; transform: scale(.4) translateY(6px); } }
.ctx-react button:active { transform: scale(1.25); }
.ctx-react button.sel { background: none; box-shadow: none; }
.ctx-react button.sel::after { content: ""; position: absolute; bottom: 1px; width: 5px; height: 5px; border-radius: 50%; background: var(--gilt); }
.ctx-preview { max-width: min(86%, 560px); overflow: hidden; border-radius: 18px; pointer-events: none; }
.ctx-preview .msg { margin: 0 !important; max-width: 100% !important; box-shadow: var(--sh-3) !important; animation: none !important; }
.ctx-menu { width: 236px; max-width: 80vw; padding: 6px; border-radius: 18px; background: var(--panel); box-shadow: var(--sh-3), 0 0 0 1px rgba(201,162,39,.22); }
.ctx-menu button { display: flex; align-items: center; gap: 12px; width: 100%; padding: 10px 12px; border-radius: 12px; text-align: start; font-size: 15px; color: var(--ink); transition: background .12s; }
.ctx-menu button:hover, .ctx-menu button:active { background: var(--brand-tint); }
.ctx-menu button svg { width: 20px; height: 20px; fill: var(--brand); flex: none; }
.ctx-menu button b { font-weight: 500; }
.ctx-menu button.danger { color: var(--danger); } .ctx-menu button.danger svg { fill: var(--danger); }
.ctx-menu .ctx-more-btn { color: var(--muted); } .ctx-menu .ctx-more-btn svg { fill: var(--muted); }
.ctx-more { display: none; border-top: 1px solid var(--line); margin-top: 4px; padding-top: 4px; }
dialog.ctx.show-more .ctx-more { display: block; animation: rise .18s var(--ease); } dialog.ctx.show-more .ctx-more-btn { display: none; }
.ctx-menu button + button, .ctx-more button + button { margin-top: 1px; }
/* attachment sheet: jewel-tone round icons, view-once switch, staggered entrance */
#dlgAttach .att-grid { gap: 14px 6px; padding-top: 10px; }
#dlgAttach .att { gap: 7px; font-size: 12.5px; animation: popIn .32s cubic-bezier(.2,.9,.3,1.3) both; animation-delay: calc(var(--i, 0) * 22ms + 60ms); }
#dlgAttach .att b { font-weight: 500; color: var(--ink); }
#dlgAttach .att-ic { width: 56px; height: 56px; border-radius: 50%; border: 0; background: radial-gradient(120% 120% at 30% 20%, color-mix(in srgb, var(--c) 72%, #fff) 0%, var(--c) 45%, color-mix(in srgb, var(--c) 70%, #000) 100%); box-shadow: 0 6px 16px color-mix(in srgb, var(--c) 35%, transparent), inset 0 0 0 1.5px rgba(246,231,166,.55), inset 0 1px 0 rgba(255,255,255,.35); transition: transform .14s cubic-bezier(.2,.9,.3,1.3); }
#dlgAttach .att-ic svg { width: 25px; height: 25px; fill: #fff; filter: drop-shadow(0 1px 1px rgba(0,0,0,.2)); }
#dlgAttach .att:active .att-ic { transform: scale(.88); }
#dlgAttach [data-att="gallery"] { --c: #2563EB !important; } #dlgAttach [data-att="camera"] { --c: #BE123C !important; } #dlgAttach [data-att="document"] { --c: #6D28D9 !important; } #dlgAttach [data-att="audio"] { --c: #C2410C !important; }
#dlgAttach [data-att="location"] { --c: #047857 !important; } #dlgAttach [data-att="contact"] { --c: #0369A1 !important; } #dlgAttach [data-att="poll"] { --c: #B45309 !important; } #dlgAttach [data-att="event"] { --c: #9D174D !important; }
#dlgAttach [data-att="islam"] { --c: #0A4E46 !important; } #dlgAttach [data-att="sticker"] { --c: #A16207 !important; } #dlgAttach [data-att="schedule"] { --c: #0F766E !important; }
.vo-row { grid-column: 1 / -1; display: flex; align-items: center; gap: 10px; padding: 8px 12px; margin-bottom: 2px; border-radius: 999px; background: var(--brand-tint); font-size: 13px; }
.vo-row .vo-txt { flex: 1; color: var(--muted); }
input.switch { appearance: none; -webkit-appearance: none; width: 40px; height: 24px; border-radius: 999px; background: var(--line); position: relative; cursor: pointer; transition: background .2s; flex: none; margin: 0; }
input.switch::after { content: ""; position: absolute; top: 3px; left: 3px; width: 18px; height: 18px; border-radius: 50%; background: #fff; box-shadow: 0 1px 3px rgba(0,0,0,.25); transition: transform .2s cubic-bezier(.2,.9,.3,1.3); }
input.switch:checked { background: linear-gradient(135deg, #D4AF37, #9C7A17); } input.switch:checked::after { transform: translateX(16px); }
[dir="rtl"] input.switch:checked::after { transform: translateX(-16px); } [dir="rtl"] input.switch::after { left: auto; right: 3px; }
dialog.sheet { transition: transform .2s cubic-bezier(.2,.8,.2,1); }
dialog.ctx :focus, dialog.ctx :focus-visible, input.switch:focus, input.switch:focus-visible, #dlgAttach .att:focus-visible { outline: none !important; }
.ctx-react button.sel { background: none !important; box-shadow: none !important; }
.ctx-react button::after { pointer-events: none; }

/* v18.1 — ayah card views & collapse */
.ic-body { position: relative; max-height: 360px; overflow: hidden; }
.ic-body.clipped::after { content: ""; position: absolute; left: 0; right: 0; bottom: 0; height: 64px; background: linear-gradient(transparent, #07352F); pointer-events: none; }
.ic-body.open { max-height: none; } .ic-body.open::after { display: none; }
.ic-more { display: block; margin: 6px auto 0; padding: 5px 14px; border-radius: 999px; font-size: 12.5px; font-weight: 700; color: #2E2405; background: var(--gold-grad); }
.ic-tr.solo { border-top: 0; margin-top: 0; padding-top: 0; font-size: 15.5px; }
.ic-wbw { display: flex; flex-wrap: wrap; justify-content: center; gap: 10px 8px; padding: 2px 0; }
.wb { display: inline-flex; flex-direction: column; align-items: center; gap: 2px; padding: 4px 6px; border-radius: 10px; background: rgba(246,231,166,.07); border: 1px solid rgba(233,210,127,.18); min-width: 46px; }
.wb b { font-family: "Amiri", "Noto Naskh Arabic", serif; font-weight: 400; font-size: 22px; line-height: 1.7; color: #FFF8E1; }
.wb small { direction: ltr; font-family: var(--font); font-size: 11.5px; line-height: 1.35; color: var(--gilt-hi); text-align: center; max-width: 110px; }
.wb.wb-n { background: none; border: 0; justify-content: center; min-width: 0; }
.ic-note { margin: 8px 0 0; font-size: 12px; text-align: center; color: rgba(243,239,228,.7); }
.ic-modes { display: flex; flex-wrap: wrap; justify-content: center; gap: 5px; margin-top: 10px; padding-top: 10px; border-top: 1px solid rgba(233,210,127,.25); }
.ic-modes button { padding: 4px 10px; border-radius: 999px; font-size: 11.5px; color: rgba(243,239,228,.85); background: rgba(255,255,255,.07); border: 1px solid rgba(233,210,127,.25); }
.ic-modes button.on { color: #2E2405; background: var(--gold-grad); border-color: transparent; font-weight: 700; }
.ctx-preview .ic-modes, .ctx-preview .ic-more { display: none; }
/* rich cards are built from templates: ignore their layout whitespace (bubbles use pre-wrap for typed text) */
.icard, .order-card, .prod-card, .poll, .evcard, .ccard, .loccard, .voice, .vt, .dl-ph, .vo { white-space: normal; }
.oc-note, .oc-pay, .vt p { white-space: pre-wrap; }

/* v18.4 — hadith views & tap-a-word meanings */
.hw { cursor: pointer; border-radius: 6px; transition: background .12s; padding: 0 1px; }
.hw:hover, .hw.hw-on { background: rgba(233,210,127,.22); }
.ic-hint { margin: 6px 0 0; text-align: center; font-size: 11.5px; color: rgba(243,239,228,.6); }
.gloss-pop { position: fixed; z-index: 70; transform: translateY(-100%); padding: 10px 14px; border-radius: 14px; text-align: center; color: #F3EFE4; background: linear-gradient(160deg, #11665C, #06312B); box-shadow: 0 0 0 1px rgba(233,210,127,.55), var(--sh-3); animation: rise .15s var(--ease); pointer-events: none; }
.gloss-pop.below { transform: none; }
.gloss-pop b { display: block; font-family: "Amiri", serif; font-size: 22px; font-weight: 400; color: var(--gilt-hi); line-height: 1.6; }
.gloss-pop span { display: block; font-size: 15px; font-weight: 600; margin: 2px 0 4px; }
.gloss-pop small { display: block; font-size: 10.5px; opacity: .65; }

/* v18.5 — context menu always fits on screen */
.ctx-wrap { overflow: hidden; }
.ctx-react { flex: none; }
.ctx-preview { flex: 0 1 auto; min-height: 56px; position: relative; }
.ctx-preview::after { content: ""; position: absolute; left: 0; right: 0; bottom: 0; height: 28px; background: linear-gradient(transparent, rgba(8,18,16,.25)); border-radius: 0 0 18px 18px; pointer-events: none; }
.ctx-menu { flex: 0 1 auto; min-height: 96px; overflow-y: auto; overscroll-behavior: contain; }
.ctx-menu { flex: none; max-height: calc(100% - 150px); }
.ctx-preview { flex: 1 1 auto; }

/* ================= v19.1 — limits & admin panel ================= */
.my-usage { display: flex; flex-direction: column; gap: 8px; padding: 12px 14px; border-radius: var(--r-m); background: var(--brand-tint); }
.us-row { display: grid; grid-template-columns: 1fr auto; gap: 4px 10px; font-size: 13.5px; } .us-row b { font-feature-settings: "tnum"; color: var(--brand); }
.us-row i { grid-column: 1 / -1; height: 6px; border-radius: 6px; background: rgba(15,32,28,.08); overflow: hidden; } .us-row u { display: block; height: 100%; background: linear-gradient(90deg, var(--brand), var(--gilt)); }
.us-more { align-self: flex-end; font-size: 12.5px; }
.adm-entry { background: linear-gradient(var(--panel), var(--panel)) padding-box, var(--gold-grad) border-box !important; border: 1.5px solid transparent !important; }
.lim-dlg { text-align: center; display: flex; flex-direction: column; align-items: center; gap: 10px; } .lim-dlg h3::after { display: none; }
.lim-ic { width: 64px; height: 64px; border-radius: 50%; display: grid; place-items: center; font-size: 30px; background: var(--brand-tint); box-shadow: 0 0 0 2px var(--gold-soft); }
.lim-dlg .btn { width: 100%; }
.lim-wa { display: flex; align-items: center; justify-content: center; gap: 10px; color: #fff; background: linear-gradient(135deg, #25D366, #128C7E); box-shadow: 0 8px 20px rgba(18,140,126,.3); }
.lim-wa svg { width: 22px; height: 22px; fill: #fff; }
.adm-dlg { padding: 0 0 20px; }
.adm-head { position: sticky; top: 0; z-index: 2; display: flex; align-items: center; gap: 12px; padding: 18px 18px 16px; color: #fff; background: var(--pat) 0 0 / 56px 56px, var(--head-grad); background-blend-mode: soft-light, normal; box-shadow: inset 0 -2px 0 rgba(233,210,127,.55); }
.adm-head > div:not(.adm-crest) { flex: 1; } .adm-head b { display: block; font-family: var(--serif); font-size: 21px; } .adm-head small { opacity: .75; font-size: 12px; }
.adm-crest { width: 48px; height: 48px; border-radius: 50%; display: grid; place-items: center; font-size: 24px; background: rgba(255,255,255,.1); box-shadow: 0 0 0 2px var(--gilt); }
.adm-head .cbtn-lite { background: rgba(255,255,255,.14); color: #fff; }
.adm-tabs { margin: 14px 16px 6px; } .adm-pane { padding: 6px 16px 0; }
.adm-stats { display: grid; grid-template-columns: repeat(2, 1fr); gap: 10px; margin-bottom: 12px; }
.adm-stat { padding: 16px 14px; border-radius: 16px; background: linear-gradient(var(--panel-2), var(--panel-2)) padding-box, linear-gradient(140deg, rgba(201,162,39,.6), rgba(15,118,110,.4)) border-box; border: 1.5px solid transparent; }
.adm-stat b { display: block; font-family: var(--serif); font-size: 28px; color: var(--brand); font-feature-settings: "tnum"; } .adm-stat span { font-size: 13px; color: var(--muted); }
.adm-stat.sm { padding: 10px 12px; } .adm-stat.sm b { font-size: 20px; } #auUsage { grid-template-columns: repeat(3, 1fr); }
.adm-results { margin-top: 10px; border: 1px solid var(--line); border-radius: var(--r-m); overflow: hidden; } .adm-results:empty { display: none; }
.adm-pane .is-row .btn { width: auto; padding: 12px 18px; }
.adm-rep { padding: 12px 14px; margin-bottom: 8px; border-radius: var(--r-m); border: 1px solid var(--line); border-inline-start: 4px solid var(--danger); background: var(--panel-2); }
.adm-rep.done { border-inline-start-color: var(--brand); opacity: .7; }
.ar-top { display: flex; justify-content: space-between; gap: 8px; font-size: 14px; } .ar-top span { font-size: 12px; color: var(--muted); }
.adm-rep p { margin: 6px 0; font-size: 13.5px; white-space: pre-wrap; } .adm-rep small { font-size: 12px; color: var(--muted); }
.ar-acts { display: flex; gap: 6px; margin-top: 8px; }
.au-head { display: flex; align-items: center; gap: 12px; margin-bottom: 8px; } .au-head b { display: block; font-size: 17px; } .au-head small { font-size: 11.5px; color: var(--muted); word-break: break-all; }
#dlgAdmUser .actions { flex-wrap: wrap; }
.adm-head .cbtn-lite:focus-visible, .lim-wa:focus-visible, #dlgLimit :focus-visible { outline: none; }

/* v19.2 — lighter, airier Quran & hadith cards */
.icard { background: var(--pat) 0 0 / 64px 64px, radial-gradient(520px 320px at 50% 0%, #1B8576, #0C5248 78%); background-blend-mode: soft-light, normal; box-shadow: inset 0 0 0 1px rgba(233,210,127,.45), 0 6px 18px rgba(8,40,36,.18); }
.ic-body.clipped::after { background: linear-gradient(transparent, #0C5248); }
.ic-wbw { gap: 8px 14px; padding: 4px 2px; }
.wb { background: none; border: 0; padding: 2px 2px 4px; min-width: 0; border-radius: 0; }
.wb b { font-size: 21px; line-height: 1.6; }
.wb small { font-size: 11px; font-weight: 500; color: rgba(246,231,166,.78); max-width: 96px; }
.wb:not(.wb-n) small { padding-top: 2px; border-top: 1px dotted rgba(233,210,127,.35); }
.ic-tr { border-top-color: rgba(233,210,127,.22); }
.ic-modes { gap: 4px; border-top-color: rgba(233,210,127,.18); }
.ic-modes button { padding: 3px 9px; font-size: 11px; background: transparent; border-color: rgba(233,210,127,.2); }
.ic-more { padding: 4px 12px; font-size: 12px; }

/* v19.3 — full-screen reading mode */
.icard-msg .icard { cursor: pointer; }
dialog.reader { background: #06312B; color: #F3EFE4; }
.rd-wrap { height: 100%; display: flex; flex-direction: column; background: var(--pat) 0 0 / 72px 72px, radial-gradient(900px 600px at 50% 0%, #17796C, #06312B 70%); background-blend-mode: soft-light, normal; }
.rd-head { display: flex; align-items: center; gap: 8px; padding: max(12px, env(safe-area-inset-top)) 12px 10px; border-bottom: 1px solid rgba(233,210,127,.3); }
.rd-head b { flex: 1; min-width: 0; text-align: center; font-size: 14px; font-weight: 700; color: var(--gilt-hi); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.rd-a { font-family: var(--font); font-weight: 800; font-size: 14px !important; }
.rd-body { flex: 1; min-height: 0; overflow-y: auto; padding: 10px 10px 24px; overscroll-behavior: contain; }
.rd-body .icard { max-width: 760px; margin: 0 auto; cursor: default; background: none; box-shadow: none; padding: 8px 10px 14px; }
.rd-body .ic-ar { font-size: calc(26px * var(--rs, 1)); line-height: 2.1; }
.rd-body .ic-tr { font-size: calc(16px * var(--rs, 1)); line-height: 1.75; }
.rd-body .wb b { font-size: calc(24px * var(--rs, 1)); }
.rd-body .wb small { font-size: calc(12px * var(--rs, 1)); max-width: 140px; }
.rd-body .ic-num { font-size: calc(18px * var(--rs, 1)); }
.rd-body .ic-modes button { font-size: 12.5px; padding: 6px 12px; }
.rd-body .ic-more, .rd-body .ic-head { display: none; }
.rd-foot { display: flex; gap: 10px; padding: 10px 14px max(14px, env(safe-area-inset-bottom)); border-top: 1px solid rgba(233,210,127,.3); }
.rd-foot .btn-ghost { color: #F3EFE4; border-color: rgba(233,210,127,.4); background: rgba(255,255,255,.05); }

/* v19.4 — clear cream-white Quran & hadith cards (and reading mode) */
.icard { color: #1E2B27; background: var(--pat) 0 0 / 64px 64px, linear-gradient(180deg, #FFFDF7, #FAF4E4); background-blend-mode: multiply, normal; box-shadow: inset 0 0 0 1px rgba(201,162,39,.55), inset 0 0 0 5px #FFFDF7, inset 0 0 0 6px rgba(201,162,39,.28), 0 4px 14px rgba(120,96,30,.12); }
.icard .ic-head b { background: linear-gradient(135deg, #9C7A17, #C9A227 50%, #8A6A10); -webkit-background-clip: text; background-clip: text; color: transparent; }
.icard .ic-badge, .icard .ic-num, .icard .ic-tr i { color: #A8841A; }
.icard .ic-ar { color: #0B3B34; }
.icard .ic-tr { color: #2E3A35; border-top-color: rgba(201,162,39,.35); }
.icard .ic-ref { color: #8A6A10; } .icard .ic-ref small { color: #6E7A74; }
.icard .ic-note, .icard .ic-hint { color: #6E7A74; }
.icard .wb b { color: #0B3B34; } .icard .wb small { color: #8A6A10; } .icard .wb:not(.wb-n) small { border-top-color: rgba(168,132,26,.35); }
.icard .ic-body.clipped::after { background: linear-gradient(rgba(250,244,228,0), #FAF4E4); }
.icard .ic-modes { border-top-color: rgba(201,162,39,.3); }
.icard .ic-modes button { color: #5B4A14; border-color: rgba(168,132,26,.35); background: transparent; }
.icard .ic-modes button.on { color: #2E2405; background: var(--gold-grad); border-color: transparent; }
.icard .hw:hover, .icard .hw.hw-on { background: rgba(201,162,39,.18); }
.icard-msg .stamp { background: rgba(255,253,247,.95); color: #8A6A10; box-shadow: 0 0 0 1px rgba(201,162,39,.35); }
dialog.reader { background: #FAF4E4; color: #1E2B27; }
.rd-wrap { background: var(--pat) 0 0 / 72px 72px, linear-gradient(180deg, #FFFDF7, #F6EED9); background-blend-mode: multiply, normal; }
.rd-head, .rd-foot { border-color: rgba(201,162,39,.35); }
.rd-head b { color: #8A6A10; }
.reader .cbtn { color: #5B4A14; background: rgba(201,162,39,.12); box-shadow: inset 0 0 0 1px rgba(201,162,39,.4); }
.rd-body .icard { background: none; box-shadow: none; }
.rd-foot .btn-ghost { color: #5B4A14; border-color: rgba(168,132,26,.45); background: #FFFDF7; }
[data-theme="dark"] .icard, html.dark .icard { color: #1E2B27; }
.icard { background: radial-gradient(420px 220px at 50% 0%, #FFFFFF, rgba(255,255,255,0) 70%), linear-gradient(180deg, #FFFDF8, #F8F1DF); background-blend-mode: normal; }
.rd-wrap { background: radial-gradient(800px 420px at 50% 0%, #FFFFFF, rgba(255,255,255,0) 70%), linear-gradient(180deg, #FFFDF8, #F5ECD6); }

/* v20.1 — verified badge, photo review */
.vbadge { display: inline-flex; vertical-align: -2px; margin-inline-start: 4px; }
.vbadge svg { width: 16px; height: 16px; fill: #C9A227; filter: drop-shadow(0 1px 1px rgba(0,0,0,.15)); }
.chat-head .vbadge svg, .ui-head .vbadge svg { width: 18px; height: 18px; }
.ph-rev { display: flex; gap: 12px; align-items: center; padding: 10px; margin-bottom: 8px; border-radius: var(--r-m); border: 1px solid var(--line); background: var(--panel-2); }
.ph-rev img { width: 72px; height: 72px; border-radius: 14px; object-fit: cover; flex: none; background: var(--brand-tint); }
.ph-rev b { display: block; } .ph-rev small { display: block; font-size: 12px; color: var(--muted); margin: 2px 0 6px; }
.au-v { padding: 10px 12px; border-radius: var(--r-m); background: linear-gradient(var(--panel), var(--panel)) padding-box, var(--gold-grad) border-box; border: 1.5px solid transparent; }
.adm-tabs { flex-wrap: wrap; }
