@import url("/fonts/fonts.css");

/* =================================================================
   Global Townhall: minimal, calm, alive.
   ================================================================= */
:root {
  --blue: #009edb;
  --blue-ink: #0077a8;      /* text and buttons on white (4.9:1) */
  --blue-deep: #00425c;
  --blue-soft: #e9f6fc;
  --bg: #f6fafc;
  --paper: #ffffff;
  --glass: rgba(255, 255, 255, .72);
  --glass-line: rgba(255, 255, 255, .9);
  --line: rgba(15, 40, 60, .08);
  --text: #0f1b26;
  --body: #2b3a47;
  --muted: #5f6f7d;
  --faint: #93a1ad;
  --ok: #17803d;
  --warn: #9a6700;
  --danger: #c0392b;
  --font: "GT Latin", "GT Arabic", -apple-system, BlinkMacSystemFont, "SF Pro Text", "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  --ease: cubic-bezier(.16, 1, .3, 1);
  --shadow: 0 1px 2px rgba(15,40,60,.04), 0 8px 24px rgba(15,40,60,.06);
  --shadow-lg: 0 2px 4px rgba(15,40,60,.04), 0 24px 60px rgba(15,40,60,.10);
  --r: 20px;
  --g1: rgba(0, 158, 219, .16);
  --g2: rgba(120, 190, 255, .16);
  --g3: rgba(0, 120, 170, .10);
}
html[data-theme="dark"] {
  --bg: #0c1218; --paper: #141c24; --glass: rgba(20, 28, 36, .78); --glass-line: rgba(255,255,255,.06); --line: rgba(255,255,255,.08);
  --text: #eef3f7; --body: #d3dce3; --muted: #9aa8b4; --faint: #6f7d89; --blue-ink: #55c6f2; --blue-soft: #0f2633;
  --shadow: none; --shadow-lg: 0 0 0 1px rgba(255,255,255,.06); --g1: rgba(0,158,219,.18); --g2: rgba(60,120,200,.14); --g3: rgba(0,90,140,.14);
}
html[data-contrast="high"] { --line: #000; --muted: #000; --body: #000; --faint: #222; --blue-ink: #005a80; --glass: #fff; --g1: transparent; --g2: transparent; --g3: transparent; }
html[data-contrast="high"][data-theme="dark"] { --line: #fff; --muted: #fff; --body: #fff; --faint: #ddd; --blue-ink: #8adcff; --glass: #000; }

* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body { margin: 0; background: var(--bg); color: var(--body); font: 16px/1.55 var(--font); -webkit-font-smoothing: antialiased; }
html[data-size="l"] body { font-size: 18.5px; }
html[data-size="xl"] body { font-size: 21px; }
h1, h2, h3 { color: var(--text); line-height: 1.18; margin: 0; font-weight: 700; letter-spacing: -.02em; }
[dir="rtl"] h1, [dir="rtl"] h2, [dir="rtl"] h3, :lang(ar) { letter-spacing: 0; }
p { margin: 0; }
button, input, textarea, select { font: inherit; color: inherit; }
.hidden { display: none !important; }
.muted { color: var(--muted); }
.small { font-size: .85rem; }
.label { font-size: .78rem; font-weight: 600; color: var(--muted); letter-spacing: .02em; }
[dir="rtl"] .label { letter-spacing: 0; }

/* ---------- moving gradient (soft, slow) ---------- */
.ambient { position: fixed; inset: 0; z-index: 0; overflow: hidden; pointer-events: none; }
.ambient i { position: absolute; border-radius: 50%; will-change: transform; }
.ambient i:nth-child(1) { width: 70vmax; height: 70vmax; top: -30vmax; left: -20vmax; background: radial-gradient(circle, var(--g1), transparent 62%); animation: g1 24s ease-in-out infinite alternate; }
.ambient i:nth-child(2) { width: 65vmax; height: 65vmax; bottom: -32vmax; right: -22vmax; background: radial-gradient(circle, var(--g2), transparent 62%); animation: g2 28s ease-in-out infinite alternate; }
.ambient i:nth-child(3) { width: 50vmax; height: 50vmax; top: 20%; left: 35%; background: radial-gradient(circle, var(--g3), transparent 62%); animation: g3 32s ease-in-out infinite alternate; }
@keyframes g1 { to { transform: translate(28vw, 22vh) scale(1.15); } }
@keyframes g2 { to { transform: translate(-30vw, -18vh) scale(1.1); } }
@keyframes g3 { to { transform: translate(-22vw, 16vh) scale(.88); } }

/* ---------- motion ---------- */
@keyframes rise { from { opacity: 0; transform: translateY(14px); } to { opacity: 1; transform: none; } }
@keyframes pop { from { opacity: 0; transform: translateY(10px) scale(.97); } to { opacity: 1; transform: none; } }
@keyframes glow { 0% { box-shadow: 0 0 0 0 rgba(0,158,219,.28), var(--shadow); } 100% { box-shadow: 0 0 0 14px rgba(0,158,219,0), var(--shadow); } }
@keyframes shimmer { to { background-position: -200% 0; } }
@keyframes breath { 0%, 100% { opacity: .35; transform: scale(.85); } 50% { opacity: 1; transform: scale(1); } }
@keyframes sheet { from { transform: translateY(100%); } to { transform: none; } }
@keyframes fade { from { opacity: 0; } to { opacity: 1; } }
.enter > * { animation: rise .55s var(--ease) both; }
.enter > *:nth-child(2) { animation-delay: .05s; } .enter > *:nth-child(3) { animation-delay: .1s; } .enter > *:nth-child(n+4) { animation-delay: .14s; }
.pulse-dots { display: inline-flex; gap: 6px; }
.pulse-dots i { width: 7px; height: 7px; border-radius: 50%; background: var(--blue); animation: breath 1.4s ease-in-out infinite; }
.pulse-dots i:nth-child(2) { animation-delay: .2s; } .pulse-dots i:nth-child(3) { animation-delay: .4s; }
.skeleton { display: grid; gap: 7px; margin-top: 4px; }
.skeleton i { height: 10px; border-radius: 99px; background: linear-gradient(90deg, rgba(0,158,219,.10), rgba(0,158,219,.22), rgba(0,158,219,.10)); background-size: 200% 100%; animation: shimmer 1.2s linear infinite; }
.skeleton i:nth-child(2) { width: 64%; }
.live-dot { width: 8px; height: 8px; border-radius: 50%; background: #e5484d; display: inline-block; box-shadow: 0 0 0 0 rgba(229,72,77,.5); animation: live 1.8s ease-out infinite; }
@keyframes live { 0% { box-shadow: 0 0 0 0 rgba(229,72,77,.45); } 100% { box-shadow: 0 0 0 9px rgba(229,72,77,0); } }

/* ---------- surfaces and controls ---------- */
.glass { background: var(--glass); border: 1px solid var(--glass-line); box-shadow: var(--shadow); border-radius: var(--r); -webkit-backdrop-filter: blur(20px) saturate(150%); backdrop-filter: blur(20px) saturate(150%); }
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px; min-height: 40px; padding: 0 16px; border-radius: 12px;
  border: 1px solid var(--line); background: var(--paper); color: var(--text); font-weight: 600; font-size: .92rem; cursor: pointer; text-decoration: none; white-space: nowrap;
  transition: transform .2s var(--ease), box-shadow .2s var(--ease), background .2s, border-color .2s;
}
.btn:hover { box-shadow: var(--shadow); }
.btn:active { transform: scale(.97); }
.btn.primary { background: var(--blue-ink); border-color: var(--blue-ink); color: #fff; box-shadow: 0 6px 16px rgba(0,119,168,.22); }
.btn.primary:hover { background: #006691; }
.btn.ghost { background: transparent; }
.btn.danger { color: var(--danger); }
.btn.small { min-height: 32px; padding: 0 12px; font-size: .82rem; border-radius: 10px; }
.btn:disabled { opacity: .45; cursor: default; }
:focus-visible { outline: 3px solid rgba(0,158,219,.45); outline-offset: 2px; }
.big-btn { display: flex; width: 100%; align-items: center; justify-content: center; gap: 10px; min-height: 54px; border: 0; border-radius: 16px; background: var(--blue-ink); color: #fff; font-size: 1.05rem; font-weight: 700; cursor: pointer; box-shadow: 0 10px 24px rgba(0,119,168,.25); transition: transform .2s var(--ease), background .2s; }
.big-btn:hover { background: #006691; }
.big-btn:active { transform: scale(.985); }
.text-btn { background: none; border: 0; color: var(--blue-ink); font-weight: 600; cursor: pointer; padding: 8px; }
.field { width: 100%; background: var(--paper); border: 1px solid var(--line); border-radius: 14px; padding: 13px 15px; color: var(--text); outline: none; transition: border-color .2s, box-shadow .2s; }
.field:focus { border-color: var(--blue); box-shadow: 0 0 0 4px rgba(0,158,219,.12); }
.field::placeholder { color: var(--faint); }
textarea.field { resize: none; }
.seg { display: inline-flex; padding: 3px; gap: 3px; border-radius: 12px; background: rgba(15,40,60,.05); }
html[data-theme="dark"] .seg { background: rgba(255,255,255,.06); }
.seg button { border: 0; background: transparent; padding: 7px 14px; border-radius: 9px; font-weight: 600; font-size: .9rem; color: var(--muted); cursor: pointer; transition: background .2s, color .2s, box-shadow .2s; }
.seg button[aria-pressed="true"] { background: var(--paper); color: var(--text); box-shadow: 0 1px 3px rgba(15,40,60,.12); }
.switch { display: flex; align-items: center; justify-content: space-between; gap: 12px; cursor: pointer; font-weight: 500; color: var(--text); }
.switch input { appearance: none; width: 44px; height: 26px; border-radius: 99px; background: rgba(15,40,60,.15); position: relative; cursor: pointer; transition: background .25s; flex: none; margin: 0; }
.switch input::after { content: ""; position: absolute; top: 3px; inset-inline-start: 3px; width: 20px; height: 20px; border-radius: 50%; background: #fff; box-shadow: 0 1px 3px rgba(0,0,0,.25); transition: transform .3s var(--ease); }
.switch input:checked { background: var(--blue); }
.switch input:checked::after { transform: translateX(18px); }
[dir="rtl"] .switch input:checked::after { transform: translateX(-18px); }
.pill { display: inline-flex; align-items: center; gap: 6px; padding: 4px 10px; border-radius: 99px; background: rgba(15,40,60,.05); font-size: .78rem; font-weight: 600; color: var(--body); white-space: nowrap; }
.pill .dot { width: 7px; height: 7px; border-radius: 50%; background: var(--faint); }
.pill.ok { background: rgba(23,128,61,.1); color: var(--ok); } .pill.ok .dot { background: var(--ok); }
.pill.warn { background: rgba(154,103,0,.1); color: var(--warn); } .pill.warn .dot { background: var(--warn); }
.pill.bad { background: rgba(192,57,43,.1); color: var(--danger); } .pill.bad .dot { background: var(--danger); }
.pill.blue { background: var(--blue-soft); color: var(--blue-ink); } .pill.blue .dot { background: var(--blue); }
.wordmark { display: inline-flex; align-items: center; font-weight: 650; color: var(--text); letter-spacing: -.015em; }
.wordmark .glyph { display: none; }
dialog { border: 0; padding: 0; background: transparent; color: var(--body); max-width: none; max-height: none; }
dialog::backdrop { background: rgba(10, 20, 30, .32); -webkit-backdrop-filter: blur(4px); backdrop-filter: blur(4px); animation: fade .25s ease both; }
.toast { position: fixed; bottom: 24px; left: 50%; transform: translateX(-50%); background: var(--text); color: var(--paper); padding: 11px 18px; border-radius: 12px; font-size: .9rem; z-index: 30; animation: pop .35s var(--ease) both; box-shadow: var(--shadow-lg); }

/* =================================================================
   PHONE
   ================================================================= */
/* The page never scrolls: the app is a fixed column sized to the visible screen (above the keyboard),
   and only the middle area scrolls. This stops the bouncing on phones. */
html:has(.phone-body), .phone-body { height: 100%; overflow: hidden; overscroll-behavior: none; }
.app { position: fixed; left: 0; right: 0; top: 0; height: var(--app-h, 100%); z-index: 1; display: flex; flex-direction: column; }
.p-top { flex: none; width: 100%; max-width: 640px; margin: 0 auto; display: flex; align-items: center; justify-content: space-between; gap: 10px; padding: calc(14px + env(safe-area-inset-top)) 18px 8px; }
.p-top .wordmark { font-size: 1rem; }
.p-tools { display: flex; gap: 4px; }
.chip-btn { display: inline-flex; align-items: center; height: 30px; padding: 0 11px; border-radius: 99px; border: 0; background: rgba(15,40,60,.05); font-size: .82rem; font-weight: 600; cursor: pointer; color: var(--body); }
html[data-theme="dark"] .chip-btn { background: rgba(255,255,255,.07); }
.p-main { flex: 1; min-height: 0; overflow-y: auto; overscroll-behavior: contain; -webkit-overflow-scrolling: touch; width: 100%; max-width: 640px; margin: 0 auto; padding: 6px 16px 16px; }
.p-foot { flex: none; width: 100%; max-width: 640px; margin: 0 auto; padding: 10px 16px calc(12px + env(safe-area-inset-bottom)); }
.picked-hello { min-height: 2.6em; font-size: 1.15rem; color: var(--blue-ink); font-weight: 600; margin-top: 6px; }
.picked-hello span { display: inline-block; animation: rise .45s var(--ease) both; }
.lang-btn.picked { border-color: var(--blue); background: var(--blue-soft); box-shadow: 0 0 0 3px rgba(0,158,219,.12); }
.lang-btn.picked strong::after { content: "  ✓"; color: var(--blue-ink); }

/* language list + confirmation sheet */
.lang-head { padding: 18px 4px 6px; }
.lang-head h1 { font-size: 1.75rem; }
.lang-head .sub { color: var(--muted); margin-top: 4px; }
.lang-search { margin: 14px 0 12px; }
.lang-list { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }
.lang-btn { display: grid; gap: 1px; text-align: start; padding: 13px 14px; border-radius: 16px; border: 1px solid var(--line); background: var(--glass); cursor: pointer; transition: transform .2s var(--ease), border-color .2s, background .2s; }
.lang-btn:hover { border-color: rgba(0,158,219,.4); }
.lang-btn:active { transform: scale(.97); }
.lang-btn strong { font-size: 1.05rem; color: var(--text); font-weight: 600; }
.lang-btn span { font-size: .78rem; color: var(--muted); }
.lang-btn.suggested { border-color: rgba(0,158,219,.45); background: var(--blue-soft); }
.sheet { position: fixed; inset: auto 0 0 0; margin: 0 auto; width: min(560px, 100%); padding: 10px 22px calc(22px + env(safe-area-inset-bottom)); border-radius: 28px 28px 0 0; background: var(--paper); box-shadow: 0 -10px 40px rgba(10,20,30,.18); animation: sheet .45s var(--ease) both; text-align: center; }
.sheet .grab { width: 40px; height: 5px; border-radius: 99px; background: rgba(15,40,60,.15); margin: 0 auto 18px; }
.sheet .hello { font-size: 2.1rem; font-weight: 700; color: var(--text); line-height: 1.2; animation: rise .6s var(--ease) .08s both; }
.sheet .which { color: var(--muted); margin: 8px 0 22px; animation: rise .6s var(--ease) .14s both; }
.sheet .badge { width: 64px; height: 64px; border-radius: 20px; margin: 4px auto 16px; display: grid; place-items: center; font-size: 1.5rem; font-weight: 700; color: #fff; background: linear-gradient(135deg, #3bbcec, var(--blue-ink)); box-shadow: 0 12px 26px rgba(0,119,168,.28); animation: pop .55s var(--ease) both; }
.sheet .big-btn { animation: rise .6s var(--ease) .2s both; }
.sheet .text-btn { margin-top: 8px; }

/* name step and waiting */
.step { padding: 26px 22px; display: grid; gap: 14px; margin-top: 6vh; }
.step h1 { font-size: 1.6rem; }
.wait { text-align: center; padding-top: 18vh; display: grid; gap: 10px; justify-items: center; }
.wait h1 { font-size: 1.6rem; }
.wait .tick { width: 56px; height: 56px; border-radius: 50%; display: grid; place-items: center; color: #fff; font-size: 1.5rem; background: linear-gradient(135deg, #3bbcec, var(--blue-ink)); box-shadow: 0 0 0 0 rgba(0,158,219,.3); animation: glow 2.4s ease-out infinite; margin-bottom: 8px; }

/* topic header */
.topic { padding: 16px 18px; margin-bottom: 14px; position: relative; overflow: hidden; }
.topic::before { content: ""; position: absolute; inset: 0; background: linear-gradient(120deg, rgba(0,158,219,.10), transparent 55%); pointer-events: none; }
.topic h1 { font-size: 1.3rem; margin-top: 4px; }
.topic .meta { display: flex; gap: 12px; margin-top: 10px; font-size: .8rem; color: var(--muted); }

/* chat thread */
.thread { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 10px; }
.row { display: flex; flex-direction: column; align-items: flex-start; max-width: 86%; }
.row.mine { align-self: flex-end; align-items: flex-end; }
.who { font-size: .74rem; font-weight: 600; color: var(--blue-ink); margin: 0 12px 3px; }
.bubble { padding: 10px 14px; border-radius: 20px 20px 20px 6px; background: var(--paper); box-shadow: var(--shadow); color: var(--text); font-size: 1rem; line-height: 1.45; cursor: pointer; border: 1px solid var(--line); }
[dir="rtl"] .bubble { border-radius: 20px 20px 6px 20px; }
.row.mine .bubble { background: var(--blue-ink); color: #fff; border-color: transparent; border-radius: 20px 20px 6px 20px; box-shadow: 0 6px 16px rgba(0,119,168,.18); }
[dir="rtl"] .row.mine .bubble { border-radius: 20px 20px 20px 6px; }
.row.new .bubble { animation: pop .45s var(--ease) both; }
.bubble .orig { margin-top: 8px; padding-top: 8px; border-top: 1px solid var(--line); font-size: .88rem; color: var(--muted); }
.row.mine .bubble .orig { border-color: rgba(255,255,255,.25); color: rgba(255,255,255,.85); }
.under { display: flex; align-items: center; gap: 8px; margin: 4px 12px 0; font-size: .72rem; color: var(--faint); }
.under button { background: none; border: 0; padding: 0; color: var(--blue-ink); font-size: .72rem; font-weight: 600; cursor: pointer; }
.under .ok { color: var(--ok); font-weight: 600; }
.system { align-self: center; max-width: 92%; text-align: center; font-size: .85rem; color: var(--body); background: var(--glass); border: 1px solid var(--line); border-radius: 14px; padding: 10px 14px; animation: pop .45s var(--ease) both; }
.system b { color: var(--text); }
.thread-empty { text-align: center; color: var(--muted); padding: 30px 10px; }

/* composer: fixed, follows the on-screen keyboard */
.composer { flex: none; padding: 8px 12px calc(10px + env(safe-area-inset-bottom)); }
.app.kb .composer, .app.kb .p-foot { padding-bottom: 10px; }
.composer-in { max-width: 640px; margin: 0 auto; display: flex; align-items: flex-end; gap: 8px; }
.input-wrap { flex: 1; display: flex; align-items: flex-end; background: var(--paper); border: 1px solid var(--line); border-radius: 24px; padding: 4px 4px 4px 16px; transition: border-color .2s, box-shadow .2s; }
[dir="rtl"] .input-wrap { padding: 4px 16px 4px 4px; }
.input-wrap:focus-within { border-color: var(--blue); box-shadow: 0 0 0 4px rgba(0,158,219,.12); }
.input-wrap textarea { flex: 1; border: 0; outline: none; background: transparent; resize: none; padding: 9px 0; max-height: 132px; line-height: 1.4; color: var(--text); font-size: 16px; }
.input-wrap textarea::placeholder { color: var(--faint); }
.icon { width: 40px; height: 40px; border-radius: 50%; border: 0; display: grid; place-items: center; cursor: pointer; flex: none; transition: transform .2s var(--ease), background .2s; background: transparent; color: var(--muted); }
.icon:active { transform: scale(.9); }
.icon svg { width: 22px; height: 22px; }
.icon.send { width: 46px; height: 46px; background: var(--blue-ink); color: #fff; box-shadow: 0 6px 16px rgba(0,119,168,.25); }
.icon.send:disabled { background: rgba(15,40,60,.12); color: var(--faint); box-shadow: none; }
.icon.rec { background: #e5484d; color: #fff; animation: live 1.4s ease-out infinite; }
[dir="rtl"] .icon.send svg { transform: scaleX(-1); }
.c-status { max-width: 640px; margin: 0 auto 6px; font-size: .8rem; color: var(--blue-ink); min-height: 0; }
.c-status:empty { display: none; }
.paused { max-width: 640px; margin: 0 auto; text-align: center; color: var(--muted); padding: 10px; }
.settings { width: min(440px, 92vw); padding: 22px; display: grid; gap: 16px; border-radius: 24px; background: var(--paper); box-shadow: var(--shadow-lg); animation: pop .35s var(--ease) both; }
.settings .row-title { font-weight: 600; margin-bottom: 8px; color: var(--text); }
.offline-bar { position: fixed; top: env(safe-area-inset-top); inset-inline: 0; z-index: 9; background: var(--text); color: var(--paper); text-align: center; padding: 6px; font-size: .85rem; }

/* =================================================================
   BIG SCREEN
   ================================================================= */
.screen-body { height: 100vh; overflow: hidden; font-size: clamp(14px, 1.1vw, 30px); }
.s-wrap { position: relative; z-index: 1; height: 100%; display: grid; grid-template-columns: minmax(0, 1fr) 31vw; gap: 3vw; padding: 3.2vh 3vw; }
.s-left { display: flex; flex-direction: column; min-height: 0; }
.s-top { display: flex; align-items: center; justify-content: space-between; gap: 2vw; margin-bottom: 4vh; }
.s-top .wordmark { font-size: 1.05em; }
.s-top .stats { display: flex; align-items: center; gap: 1.2em; color: var(--muted); font-size: .9em; font-weight: 500; }
.s-topic { margin-bottom: 3.4vh; }
.s-topic .label { font-size: .95em; color: var(--blue-ink); font-weight: 600; }
.s-topic h1 { font-size: 3.3em; line-height: 1.08; margin-top: .25em; letter-spacing: -.03em; max-width: 26ch; }
[dir="rtl"] .s-topic h1 { line-height: 1.3; }
.s-wall { flex: 1; min-height: 0; overflow: hidden; display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 1.6vh 1.2vw; align-content: start;
  -webkit-mask-image: linear-gradient(180deg, #000 80%, transparent); mask-image: linear-gradient(180deg, #000 80%, transparent); }
.w-card { padding: 1.3em 1.4em 1.1em; display: grid; gap: .7em; align-content: start; border-radius: 22px; }
.w-card.new { animation: pop .8s var(--ease) both, glow 1.6s ease-out .2s 1; }
.w-text { font-size: 1.45em; font-weight: 600; color: var(--text); line-height: 1.36; }
.w-meta { display: flex; align-items: center; gap: .7em; flex-wrap: wrap; font-size: .82em; color: var(--muted); }
.w-meta .name { font-weight: 600; color: var(--blue-ink); }
.w-meta .from { display: inline-flex; align-items: center; gap: .35em; }
.w-meta .from::before { content: ""; width: 4px; height: 4px; border-radius: 50%; background: var(--faint); }
.s-empty { grid-column: 1 / -1; display: grid; justify-items: start; gap: 1.2vh; padding-top: 3vh; color: var(--muted); }
.s-empty h2 { font-size: 1.8em; color: var(--text); }
.s-empty .pulse-dots i { width: .6em; height: .6em; }
.s-right { display: flex; flex-direction: column; justify-content: center; gap: 2.4vh; min-height: 0; }
.qr-card { padding: 2.4vh 2vw 2.6vh; display: grid; justify-items: center; gap: 1.6vh; text-align: center; border-radius: 32px; }
.qr-card .label { font-size: 1em; color: var(--blue-ink); }
.qr-card h2 { font-size: 1.9em; }
.qr-frame { width: min(25vw, 50vh); aspect-ratio: 1; padding: 1.1vw; border-radius: 26px; background: #fff; box-shadow: 0 0 0 1px rgba(15,40,60,.06), 0 18px 40px rgba(15,40,60,.10); }
.qr-frame img { width: 100%; height: 100%; display: block; }
.qr-card .url { font-weight: 600; color: var(--text); font-size: 1.05em; direction: ltr; }
.qr-card .hint { color: var(--muted); font-size: .95em; max-width: 26ch; }
.counts { display: grid; grid-template-columns: 1fr 1fr; gap: 1vw; }
.count { padding: 1.6vh 1.2vw; border-radius: 20px; display: grid; gap: .1em; }
.count b { font-size: 2.4em; line-height: 1; color: var(--text); font-weight: 700; font-variant-numeric: tabular-nums; }
.count span { font-size: .85em; color: var(--muted); font-weight: 500; }
.lang-cloud { display: flex; flex-wrap: wrap; gap: .5em; justify-content: center; }
.lang-cloud .pill { font-size: .85em; padding: .35em .9em; animation: pop .5s var(--ease) both; }
.paused-note { display: inline-flex; align-items: center; gap: .5em; margin-top: 1em; padding: .4em 1em; border-radius: 99px; background: rgba(15,40,60,.06); color: var(--muted); font-weight: 600; font-size: .9em; }
.s-lang { position: fixed; bottom: 2vh; inset-inline-start: 3vw; z-index: 4; opacity: 0; transform: translateY(8px); transition: opacity .3s, transform .3s var(--ease); }
.s-lang.show { opacity: 1; transform: none; }
.fs-btn { position: fixed; top: 0; left: 0; width: 90px; height: 90px; z-index: 50; border: 0; padding: 0; background: transparent; opacity: 0; cursor: default; }

/* =================================================================
   MODERATOR CONSOLE
   ================================================================= */
.host-body { min-height: 100vh; }
.h-top { position: sticky; top: 0; z-index: 5; background: color-mix(in srgb, var(--bg) 75%, transparent); -webkit-backdrop-filter: blur(20px) saturate(160%); backdrop-filter: blur(20px) saturate(160%); }
.h-top-in { max-width: 1400px; margin: 0 auto; display: flex; align-items: center; justify-content: space-between; gap: 16px; padding: 12px 24px; flex-wrap: wrap; }
.h-top .left, .h-top .right { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; }
.h-top .sep { width: 1px; height: 22px; background: var(--line); }
.h-wrap { position: relative; z-index: 1; max-width: 1400px; margin: 0 auto; padding: 22px 24px 48px; display: grid; grid-template-columns: 380px minmax(0, 1fr); gap: 20px; align-items: start; }
@media (max-width: 1050px) { .h-wrap { grid-template-columns: 1fr; } }
.h-col { display: grid; gap: 16px; }
.panel { padding: 20px; display: grid; gap: 14px; }
.panel h2 { font-size: 1.05rem; }
.panel .head { display: flex; align-items: center; justify-content: space-between; gap: 10px; }
.stats-row { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 12px; }
.stat { padding: 14px 16px; border-radius: 18px; }
.stat b { display: block; font-size: 1.7rem; line-height: 1.1; color: var(--text); font-variant-numeric: tabular-nums; }
.stat span { font-size: .8rem; color: var(--muted); }
.stat.alert b { color: var(--warn); }
.topic-tr { display: grid; gap: 4px; font-size: .84rem; color: var(--muted); }
.topic-tr b { color: var(--body); font-weight: 600; }
.join-row { display: flex; gap: 14px; align-items: center; }
.join-row img { width: 120px; height: 120px; border-radius: 14px; background: #fff; padding: 6px; box-shadow: 0 0 0 1px var(--line); }
.filters { display: flex; flex-wrap: wrap; gap: 6px; }
.filters button { border: 1px solid var(--line); background: var(--paper); padding: 6px 12px; border-radius: 99px; font-size: .82rem; font-weight: 600; color: var(--muted); cursor: pointer; transition: background .2s, color .2s, border-color .2s; }
.filters button[aria-pressed="true"] { background: var(--text); color: var(--paper); border-color: var(--text); }
.queue { list-style: none; margin: 0; padding: 0; display: grid; gap: 10px; }
.q { padding: 14px 16px; border-radius: 16px; background: var(--paper); border: 1px solid var(--line); display: grid; gap: 8px; animation: pop .4s var(--ease) both; }
.q.s-held { border-color: rgba(154,103,0,.45); box-shadow: 0 0 0 4px rgba(154,103,0,.08); }
.q.s-offtopic, .q.s-blocked, .q.s-hidden { background: color-mix(in srgb, var(--paper) 60%, transparent); }
.q-top { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; font-size: .82rem; color: var(--muted); }
.q-top .name { color: var(--text); font-weight: 600; }
.q-top .pill { margin-inline-start: auto; }
.q-orig { font-size: 1rem; font-weight: 500; color: var(--text); }
.q-sub { font-size: .88rem; color: var(--muted); display: grid; gap: 2px; }
.q-sub b { font-size: .72rem; color: var(--faint); margin-inline-end: 6px; font-weight: 700; }
.q-acts { display: flex; gap: 8px; }
.q-acts:empty { display: none; }
.empty-q { color: var(--muted); padding: 28px; text-align: center; border: 1.5px dashed var(--line); border-radius: 16px; }
.spinner { width: 12px; height: 12px; border: 2px solid rgba(0,158,219,.25); border-top-color: var(--blue); border-radius: 50%; animation: spin .8s linear infinite; display: inline-block; }
@keyframes spin { to { transform: rotate(360deg); } }

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation: none !important; transition: none !important; }
}
/* keep the join column inside the screen, even with both languages */
.s-right { gap: 1.8vh; overflow: hidden; }
.qr-card { gap: 1.1vh; padding: 2.2vh 1.6vw; }
.qr-card h2 { font-size: 1.7em; }
.qr-frame { width: min(23vw, 42vh); }
.qr-card .hint { font-size: .88em; line-height: 1.4; }
.count { padding: 1.3vh 1.1vw; }

/* ---------- big screen: join panel, solid and quiet ---------- */
.s-wrap { grid-template-columns: minmax(0, 1fr) 30vw; gap: 0; padding: 0; }
.s-left { padding: 4.4vh 3.6vw 3vh; }
.s-right { height: 100vh; display: flex; flex-direction: column; justify-content: center; align-items: center; text-align: center; gap: 2.2vh; padding: 5vh 2.8vw; background: var(--paper); border-inline-start: 1px solid var(--line); overflow: hidden; }
.join-title { font-size: 2.05em; white-space: nowrap; font-weight: 700; color: var(--text); letter-spacing: -.025em; line-height: 1.1; }
.join-title-2 { font-size: 1.5em; font-weight: 600; color: var(--muted); margin-top: -1.2vh; }
.qr-plain { width: min(23vw, 46vh); aspect-ratio: 1; margin: 1.2vh 0; }
.qr-plain img { width: 100%; height: 100%; display: block; }
.join-sub { color: var(--muted); font-size: 1.05em; line-height: 1.45; max-width: 24ch; }
.join-sub + .join-sub { margin-top: -1.4vh; }
.join-url { font-weight: 600; font-size: 1em; color: var(--blue-ink); direction: ltr; letter-spacing: .01em; }
.join-foot { min-height: 1.4em; color: var(--faint); font-size: .9em; max-width: 26ch; line-height: 1.5; }
.s-top .stats { display: none; }

/* =================================================================
   GLOBAL TOWNHALL: phone v3 (six languages, icons, ChatGPT-style composer)
   ================================================================= */
:root { --bg: #f3f8fb; --title: #3b8fd9; --display: "GT Display", "Roboto Condensed", "Arial Narrow", sans-serif; }
.gt-title { font-family: var(--display); font-weight: 800; text-transform: uppercase; letter-spacing: .045em; color: var(--title); line-height: 1; }
.p-top.v3 { flex-direction: column; align-items: stretch; gap: 10px; padding-bottom: 12px; border-bottom: 1.5px dashed rgba(59,143,217,.35); }
.p-top.v3 .row1 { display: flex; align-items: center; justify-content: space-between; gap: 10px; }
.p-top.v3 .gt-title { font-size: 1.65rem; }
.lang-menu-btn { display: inline-flex; align-items: center; gap: 6px; height: 32px; padding: 0 12px; border-radius: 99px; border: 1px solid rgba(15,40,60,.1); background: var(--paper); font-weight: 600; font-size: .85rem; color: var(--text); cursor: pointer; }
.lang-menu-btn svg { width: 12px; height: 12px; }
.menu { position: fixed; z-index: 20; min-width: 220px; padding: 6px; border-radius: 16px; background: var(--paper); box-shadow: 0 0 0 1px rgba(15,40,60,.06), 0 16px 40px rgba(15,40,60,.16); animation: pop .25s var(--ease) both; }
.menu button { display: flex; width: 100%; align-items: center; justify-content: space-between; gap: 10px; padding: 11px 12px; border: 0; border-radius: 10px; background: none; font-size: .95rem; color: var(--text); cursor: pointer; text-align: start; }
.menu button:hover, .menu button[aria-checked="true"] { background: var(--blue-soft); }
.menu button .tick { color: var(--blue-ink); font-weight: 700; }
.menu hr { border: 0; border-top: 1px dashed var(--line); margin: 6px 4px; }
.menu .menu-row { display: flex; align-items: center; justify-content: space-between; gap: 8px; padding: 8px 12px; font-size: .85rem; color: var(--muted); }
.menu .menu-row .seg button { width: auto; padding: 5px 10px; }
.menu-icon { display: grid; place-items: center; width: 34px; height: 34px; border-radius: 10px; background: var(--blue-soft); color: var(--blue-ink); flex: none; }
.menu-icon svg { width: 18px; height: 18px; }
.menu .with-icon { justify-content: flex-start; }

/* language boxes: the welcome line in each language, the language name below */
.welcome-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; margin-top: 16px; }
.wbox { display: grid; align-content: space-between; gap: 14px; min-height: 118px; padding: 16px; border-radius: 18px; border: 1px solid rgba(15,40,60,.08); background: rgba(255,255,255,.85); box-shadow: var(--shadow); text-align: start; cursor: pointer; transition: transform .2s var(--ease), border-color .2s, box-shadow .2s; }
.wbox:active { transform: scale(.97); }
.wbox .w { font-size: 1.02rem; font-weight: 700; color: var(--text); line-height: 1.3; }
.wbox .n { font-size: .82rem; color: var(--blue-ink); font-weight: 600; }
.wbox.picked { border-color: var(--blue); box-shadow: 0 0 0 3px rgba(0,158,219,.15), var(--shadow); background: #fff; }
.wbox.picked .n::after { content: "  ✓"; }
.wbox.more { grid-column: 1 / -1; min-height: 0; padding: 14px 16px; display: flex; align-items: center; justify-content: center; gap: 8px; color: var(--muted); font-weight: 600; border-style: dashed; background: transparent; box-shadow: none; }
.more-note { text-align: center; color: var(--muted); font-size: .85rem; margin-top: 8px; min-height: 1.2em; }

/* icon picker */
.av { display: inline-grid; place-items: center; border-radius: 50%; background: linear-gradient(145deg, #3bbcec, #0077a8); flex: none; box-shadow: inset 0 1px rgba(255,255,255,.35); }
.av svg { width: 72%; height: 72%; display: block; }
.icon-head { padding: 14px 2px 4px; }
.icon-head h1 { font-size: 1.5rem; }
.icon-head p { color: var(--muted); margin-top: 4px; }
.icon-group { margin-top: 16px; }
.icon-group .label { margin: 0 2px 8px; }
.icon-grid { display: grid; grid-template-columns: repeat(5, 1fr); gap: 10px; }
.icon-btn2 { display: grid; place-items: center; aspect-ratio: 1; border: 0; border-radius: 50%; padding: 0; background: none; cursor: pointer; transition: transform .2s var(--ease); }
.icon-btn2 .av { width: 100%; height: 100%; }
.icon-btn2:active { transform: scale(.92); }
.icon-btn2[aria-checked="true"] .av { box-shadow: 0 0 0 3px #fff, 0 0 0 6px var(--blue); }
.icon-btn2[aria-checked="false"] .av { opacity: .9; }
.picked-name { text-align: center; color: var(--blue-ink); font-weight: 600; min-height: 1.4em; margin-top: 12px; }

/* chat v3 */
.row.with-av { flex-direction: row; align-items: flex-end; gap: 8px; max-width: 92%; }
.row.with-av .av { width: 32px; height: 32px; }
.row .col { display: flex; flex-direction: column; align-items: flex-start; min-width: 0; }
.speak-btn { display: inline-grid; place-items: center; width: 26px; height: 26px; border-radius: 50%; border: 0; background: var(--blue-soft); color: var(--blue-ink); cursor: pointer; flex: none; }
.speak-btn svg { width: 14px; height: 14px; }
.speak-btn.on { background: var(--blue-ink); color: #fff; }
.under .from { color: var(--faint); }
.row.private .bubble { background: #fff8e8; color: var(--text); border: 1px dashed #d9a632; box-shadow: none; }
.row.private .under { color: #9a6700; }

/* vote card */
.vote-card { padding: 16px; margin-bottom: 14px; border-radius: 20px; background: linear-gradient(135deg, rgba(0,158,219,.12), rgba(255,255,255,.9)); border: 1px solid rgba(0,158,219,.25); box-shadow: var(--shadow); animation: pop .45s var(--ease) both; }
.vote-card .label { color: var(--blue-ink); }
.vote-card h2 { font-size: 1.1rem; margin: 6px 0 12px; }
.vote-opts { display: grid; gap: 8px; }
.vote-opt { display: flex; align-items: center; gap: 10px; width: 100%; padding: 12px 14px; border-radius: 14px; border: 1px solid rgba(15,40,60,.1); background: #fff; font-size: .98rem; font-weight: 500; color: var(--text); text-align: start; cursor: pointer; transition: border-color .2s, background .2s; }
.vote-opt .dot { width: 18px; height: 18px; border-radius: 50%; border: 2px solid rgba(15,40,60,.2); flex: none; display: grid; place-items: center; }
.vote-opt[aria-checked="true"] { border-color: var(--blue); background: var(--blue-soft); }
.vote-opt[aria-checked="true"] .dot { border-color: var(--blue); background: var(--blue); box-shadow: inset 0 0 0 3px #fff; }
.vote-opt:disabled { cursor: default; opacity: .75; }
.vote-note { margin-top: 10px; font-size: .85rem; color: var(--muted); }

/* composer v3: private toggle, plus, mic inside, send */
.composer .tools-row { max-width: 640px; margin: 0 auto 8px; display: flex; align-items: center; gap: 8px; }
.private-toggle { display: inline-flex; align-items: center; gap: 6px; height: 30px; padding: 0 12px; border-radius: 99px; border: 1px solid rgba(15,40,60,.12); background: var(--paper); font-size: .8rem; font-weight: 600; color: var(--muted); cursor: pointer; }
.private-toggle svg { width: 13px; height: 13px; }
.private-toggle[aria-pressed="true"] { background: #fff4dc; border-color: #d9a632; color: #8a5a00; }
.composer.is-private .input-wrap { border-color: #d9a632; box-shadow: 0 0 0 4px rgba(217,166,50,.14); background: #fffdf7; }
.icon.plus { width: 44px; height: 44px; background: var(--paper); border: 1px solid rgba(15,40,60,.1); color: var(--text); }
.icon.plus.open { transform: rotate(45deg); }
.icon.plus svg { transition: transform .25s var(--ease); }
.c-status.warn { color: #8a5a00; }
.hidden-input { position: absolute; width: 1px; height: 1px; opacity: 0; pointer-events: none; }

/* =================================================================
   GLOBAL TOWNHALL: big screen v3 (six languages, icons, voting, dial-in)
   ================================================================= */
.screen-body.v3 .s-top { margin-bottom: 3.6vh; padding-bottom: 2.2vh; border-bottom: 2px dashed rgba(59,143,217,.3); }
.screen-body.v3 .gt-title { font-size: 2.6em; }
.s-second { font-size: 1.45em; font-weight: 600; color: var(--muted); margin-top: .35em; line-height: 1.3; }
.s-topic .label span { color: var(--faint); font-weight: 500; }
.w-head { display: flex; align-items: flex-start; gap: .8em; }
.w-head .av { width: 2.4em; height: 2.4em; margin-top: .1em; }
.w-head .w-text { flex: 1; min-width: 0; }
.w-second { color: var(--muted); font-size: 1.02em; line-height: 1.38; padding-inline-start: 3.2em; }
.w-card .w-meta { padding-inline-start: 3.2em; }
.join-dial { display: flex; flex-wrap: wrap; align-items: center; justify-content: center; gap: .45em; padding: .7em 1.1em; border-radius: 99px; border: 1.5px dashed rgba(59,143,217,.45); color: var(--muted); font-size: 1em; }
.join-dial svg { width: 1.1em; height: 1.1em; color: var(--blue-ink); display: block; }
.join-dial b { color: var(--text); letter-spacing: .02em; }

/* voting on the big screen */
.s-poll { grid-column: 1 / -1; padding: 3.4vh 2.4vw; border-radius: 28px; background: rgba(255,255,255,.88); border: 1px solid rgba(0,158,219,.2); box-shadow: 0 20px 50px rgba(15,40,60,.08); }
.s-poll-head { display: flex; align-items: center; justify-content: space-between; gap: 1em; }
.s-poll-head .label { color: var(--blue-ink); font-weight: 700; font-size: .95em; }
.s-poll-head .label span { color: var(--faint); font-weight: 500; }
.poll-state { display: inline-flex; align-items: center; gap: .5em; padding: .35em .9em; border-radius: 99px; background: var(--blue-soft); color: var(--blue-ink); font-weight: 600; font-size: .9em; }
.poll-state.closed { background: rgba(15,40,60,.06); color: var(--muted); }
.s-poll h2 { font-size: 2.3em; line-height: 1.15; letter-spacing: -.02em; margin-top: .6em; max-width: 30ch; }
.s-opts { list-style: none; display: grid; gap: 1.4vh; margin-top: 3vh; padding: 0; }
.s-opt { position: relative; overflow: hidden; display: flex; align-items: center; gap: 1em; padding: 1.1em 1.3em; border-radius: 18px; background: #fff; border: 1px solid rgba(15,40,60,.08); font-size: 1.25em; font-weight: 600; }
.s-opt .bar { position: absolute; inset-block: 0; inset-inline-start: 0; background: linear-gradient(90deg, rgba(0,158,219,.18), rgba(0,158,219,.32)); border-radius: inherit; transition: width 1s var(--ease); z-index: 0; }
.s-opt.top .bar { background: linear-gradient(90deg, rgba(0,158,219,.35), rgba(0,158,219,.55)); }
.s-opt > :not(.bar) { position: relative; z-index: 1; }
.s-opt .letter { display: grid; place-items: center; width: 1.9em; height: 1.9em; border-radius: 50%; background: var(--blue-ink); color: #fff; font-size: .8em; flex: none; }
.s-opt .o-text { flex: 1; display: grid; gap: .15em; min-width: 0; }
.s-opt .o-second { color: var(--muted); font-weight: 500; font-size: .78em; }
.s-opt .share { font-size: 1.1em; color: var(--blue-ink); font-variant-numeric: tabular-nums; }
.s-poll-foot { margin-top: 2.2vh; color: var(--muted); font-weight: 600; }
.s-lang button { font-size: .85rem; }

/* =================================================================
   GLOBAL TOWNHALL: moderator v3 (languages, voting, private)
   ================================================================= */
.host-body .stats-row { grid-template-columns: repeat(5, minmax(0, 1fr)); }
.two-sel { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.two-sel label { display: grid; gap: 4px; }
.two-sel select { padding: 10px 12px; font-size: .92rem; }
.q-top .av { width: 26px; height: 26px; }
.pill.private { background: #fff4dc; color: #8a5a00; }
.pill.blue { background: var(--blue-soft); color: var(--blue-ink); }
.q.s-private { border-inline-start: 3px dashed #d9a632; }
.poll-list { list-style: none; padding: 0; display: grid; gap: 10px; }
.poll-item { padding: 12px 14px; border-radius: 16px; background: var(--paper); border: 1px solid var(--line); display: grid; gap: 8px; }
.poll-item.active { border-color: var(--blue); box-shadow: 0 0 0 3px rgba(0,158,219,.12); }
.poll-bars { list-style: none; padding: 0; display: grid; gap: 6px; }
.poll-bars li { position: relative; overflow: hidden; display: flex; justify-content: space-between; gap: 10px; padding: 7px 10px; border-radius: 10px; background: rgba(15,40,60,.04); font-size: .9rem; }
.poll-bars .bar { position: absolute; inset-block: 0; inset-inline-start: 0; background: rgba(0,158,219,.18); transition: width .6s var(--ease); }
.poll-bars li > :not(.bar) { position: relative; }
.poll-bars b { color: var(--blue-ink); font-variant-numeric: tabular-nums; white-space: nowrap; }

/* =================================================================
   GLOBAL TOWNHALL: dial-in demo
   ================================================================= */
.dial-body { min-height: 100vh; }
.dial-wrap { position: relative; z-index: 1; max-width: 1120px; margin: 0 auto; padding: 32px 28px 40px; }
.dial-top { display: flex; align-items: baseline; justify-content: space-between; gap: 16px; padding-bottom: 16px; border-bottom: 1.5px dashed rgba(59,143,217,.35); }
.dial-top .gt-title { font-size: 2.2rem; }
.dial-tag { color: var(--muted); font-weight: 600; letter-spacing: .02em; }
.dial-grid { display: grid; grid-template-columns: 380px minmax(0, 1fr); gap: 28px; margin-top: 28px; align-items: start; }
.call { display: grid; justify-items: center; gap: 18px; padding: 34px 26px 28px; border-radius: 38px; background: linear-gradient(170deg, #0f2a3d, #0a1a26 70%); color: #fff; box-shadow: 0 30px 60px rgba(10,26,38,.28); }
.call-head { display: grid; justify-items: center; gap: 8px; text-align: center; }
.call-av .av { width: 84px; height: 84px; }
.call.live .call-av .av { animation: callPulse 2s ease-in-out infinite; }
@keyframes callPulse { 0%, 100% { box-shadow: 0 0 0 0 rgba(59,188,236,.45); } 50% { box-shadow: 0 0 0 16px rgba(59,188,236,0); } }
.call-name { font-size: 1.5rem; font-weight: 700; letter-spacing: -.01em; }
.call-state { color: rgba(255,255,255,.62); font-variant-numeric: tabular-nums; font-size: .95rem; min-height: 1.3em; }
.call-state.busy { color: #7fd3f5; }
.caption { width: 100%; min-height: 6.2em; padding: 14px 16px; border-radius: 18px; background: rgba(255,255,255,.07); font-size: 1.02rem; line-height: 1.45; color: #fff; }
.caption:empty { visibility: hidden; }
.caption.in { animation: pop .35s var(--ease) both; }
.keypad { display: grid; grid-template-columns: repeat(3, 72px); gap: 14px 22px; }
.keypad button { width: 72px; height: 72px; border-radius: 50%; border: 0; background: rgba(255,255,255,.12); color: #fff; font-size: 1.7rem; font-weight: 500; cursor: pointer; transition: background .15s, transform .15s; }
.keypad button:hover { background: rgba(255,255,255,.18); }
.keypad button.down, .keypad button:active { background: rgba(255,255,255,.38); transform: scale(.94); }
.call.idle .keypad { opacity: .35; pointer-events: none; }
.call-btn { display: inline-flex; align-items: center; gap: 10px; height: 60px; padding: 0 30px; border: 0; border-radius: 99px; color: #fff; font-size: 1.05rem; font-weight: 700; cursor: pointer; }
.call-btn svg { width: 22px; height: 22px; display: block; }
.call-btn.green { background: #22b35e; box-shadow: 0 10px 24px rgba(34,179,94,.35); }
.call-btn.red { background: #e5484d; box-shadow: 0 10px 24px rgba(229,72,77,.35); }
.log-panel { padding: 22px 24px; border-radius: 26px; display: grid; gap: 14px; }
.log-panel .label { color: var(--blue-ink); }
.call-log { list-style: none; padding: 0; display: grid; gap: 10px; max-height: 58vh; overflow: auto; }
.call-log li { display: grid; grid-template-columns: 82px minmax(0, 1fr); gap: 10px; align-items: baseline; animation: pop .35s var(--ease) both; }
.call-log .who { font-size: .75rem; font-weight: 700; text-transform: uppercase; letter-spacing: .06em; color: var(--faint); }
.call-log .log-system .txt { color: var(--text); line-height: 1.45; }
.call-log .log-caller .who { color: var(--blue-ink); }
.call-log .log-caller .txt { color: var(--blue-ink); font-weight: 600; }
.call-log:empty::before { content: "Press Call to start the demo. Use the keypad or the number keys on the keyboard."; color: var(--muted); }
.log-note { border-top: 1px dashed var(--line); padding-top: 12px; }
@media (max-width: 860px) { .dial-grid { grid-template-columns: 1fr; } .call { max-width: 400px; margin: 0 auto; } }

/* fixes after review */
.h-col { min-width: 0; grid-template-columns: minmax(0, 1fr); }
.two-sel > label { min-width: 0; }
.two-sel select { width: 100%; min-width: 0; }
.wbox.more svg { width: 18px; height: 18px; }
.input-wrap textarea:placeholder-shown { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.s-poll { padding: 2.6vh 2vw; }
.s-poll h2 { font-size: 1.9em; margin-top: .45em; }
.s-poll .s-second { font-size: 1.15em; }
.s-opts { gap: 1vh; margin-top: 2.2vh; }
.s-opt { padding: .7em 1.1em; font-size: 1.1em; border-radius: 14px; }
.s-opt .bar { border-radius: 0; background: rgba(0,158,219,.13); }
.s-opt.top .bar { background: rgba(0,158,219,.26); }
.s-opt .o-second { font-size: .74em; }
.s-poll-foot { margin-top: 1.6vh; }
.s-wall:has(.s-poll) { -webkit-mask-image: none; mask-image: none; }
.poll-item, .poll-item > * { min-width: 0; }
.poll-item .q-acts { flex-wrap: wrap; }
.poll-item .q-top { flex-wrap: wrap; }
.poll-bars li span[dir] { min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.s-poll-head .right { display: inline-flex; align-items: center; gap: .9em; color: var(--muted); font-weight: 600; font-size: .9em; }
.call { gap: 14px; padding: 26px 24px 24px; }
.call-av .av { width: 68px; height: 68px; }
.call-name { font-size: 1.35rem; }
.caption { min-height: 5em; max-height: 8.4em; overflow: hidden; font-size: .95rem; padding: 12px 14px; }
.keypad { grid-template-columns: repeat(3, 62px); gap: 10px 22px; }
.keypad button { width: 62px; height: 62px; font-size: 1.5rem; }
.call-btn { height: 54px; }
.dial-wrap { padding-top: 26px; }
.dial-grid { margin-top: 22px; }
.caption { display: -webkit-box; -webkit-box-orient: vertical; -webkit-line-clamp: 6; max-height: none; }
.under { flex-wrap: wrap; row-gap: 2px; } .under > * { white-space: nowrap; }
.under .speak-btn { display: inline-grid; place-items: center; width: 24px; height: 24px; padding: 0; border-radius: 50%; background: var(--blue-soft); color: var(--blue-ink); }
.under .speak-btn.on { background: var(--blue-ink); color: #fff; box-shadow: 0 0 0 4px rgba(0,119,168,.15); }
.under .speak-btn svg { width: 13px; height: 13px; }
.caption { padding: 12px 14px 0; border-bottom: 12px solid rgba(255,255,255,.07); background-clip: padding-box; }

/* =================================================================
   GLOBAL TOWNHALL v4: the clean layout (old mock-up format)
   ================================================================= */
:root {
  --un: #009edb;
  --font: "GT Arabic", -apple-system, BlinkMacSystemFont, "SF Pro Text", "GT Latin", "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  --display: -apple-system, BlinkMacSystemFont, "SF Pro Display", "GT Latin", "Helvetica Neue", Arial, sans-serif;
}
.i { display: inline-grid; place-items: center; line-height: 0; flex: none; }
.i svg { display: block; }
.brand, .wordmark { font-family: var(--display); font-weight: 600; color: var(--un); letter-spacing: -.012em; text-transform: none; }
.brand { font-size: 1.08rem; line-height: 1.2; }

/* header: name on the left, language on the right, no divider */
.p-top.v4 { padding: calc(14px + env(safe-area-inset-top)) 18px 10px; border: 0; }
.lang-pill { display: inline-flex; align-items: center; gap: 2px; height: 34px; padding: 0 8px 0 14px; border: 0; border-radius: 99px; background: rgba(15,40,60,.06); color: var(--text); font: 600 .88rem/1 var(--font); cursor: pointer; }
.menu hr { border: 0; border-top: 1px solid var(--line); }
.menu button .i { color: var(--blue-ink); }

/* welcome: icon, greeting, languages */
.welcome { display: flex; flex-direction: column; align-items: center; padding: 8px 2px 4px; }
.av-picker { display: flex; align-items: center; gap: 22px; }
.av-picker .nav { width: 42px; height: 42px; padding: 0; display: grid; place-items: center; border-radius: 50%; border: 1px solid var(--line); background: #fff; color: var(--text); box-shadow: 0 4px 12px rgba(15,40,60,.06); cursor: pointer; }
.av-picker .nav:active { transform: scale(.94); }
.av svg { width: 62%; height: 62%; display: block; }
.av.hero { width: 128px; height: 128px; box-shadow: 0 0 0 6px #fff, 0 18px 40px rgba(0,119,168,.18); }
.av.hero.swap { animation: pop .35s var(--ease) both; }
.av-name { display: inline-flex; align-items: center; gap: 2px; margin-top: 14px; height: 30px; padding: 0 6px 0 12px; border: 0; border-radius: 99px; background: none; color: var(--blue-ink); font: 600 .9rem/1 var(--font); cursor: pointer; }
.speech { position: relative; width: 100%; margin-top: 12px; padding: 15px 18px 14px; border-radius: 20px; background: #fff; box-shadow: var(--shadow); text-align: center; }
.speech::before { content: ""; position: absolute; top: -8px; left: 50%; margin-left: -8px; width: 16px; height: 16px; background: #fff; transform: rotate(45deg); border-radius: 3px; }
.speech .ar { position: relative; font-size: 1.2rem; font-weight: 700; color: var(--text); line-height: 1.45; }
.speech .en { position: relative; font-size: .88rem; color: var(--muted); margin-top: 4px; line-height: 1.5; }
.lang-grid { width: 100%; display: grid; grid-template-columns: 1fr 1fr; gap: 10px; margin-top: 16px; }
.lang-grid .lang-btn { background: #fff; border-color: rgba(15,40,60,.07); padding: 12px 15px; }
.lang-grid .lang-btn strong { font-size: 1.02rem; }
.lang-btn.picked strong::after { content: none; }
.lang-btn.more { grid-column: 1 / -1; text-align: center; background: transparent; border-style: dashed; border-color: rgba(15,40,60,.14); }
.lang-btn.more strong { color: var(--muted); font-size: .95rem; }
.menu.av-menu { width: min(360px, calc(100vw - 24px)); max-height: 62vh; overflow: auto; padding: 12px 14px 14px; }
.av-head { font-size: .78rem; font-weight: 600; color: var(--muted); margin: 6px 2px 8px; }
.av-grid { display: grid; grid-template-columns: repeat(6, 1fr); gap: 8px; margin-bottom: 6px; }
.menu .av-cell { display: block; width: 100%; aspect-ratio: 1; padding: 0; border-radius: 50%; background: none; }
.menu .av-cell:hover { background: none; }
.av-cell .av { width: 100%; height: 100%; }
.av-cell.on .av { box-shadow: 0 0 0 3px #fff, 0 0 0 5px var(--un); }
.wait .av.hero { margin-bottom: 18px; }

/* conversation */
.topic-card { padding: 15px 18px 16px; margin-bottom: 16px; border-radius: 20px; background: #fff; box-shadow: var(--shadow); }
.topic-card .label { color: var(--muted); font-size: .78rem; font-weight: 600; letter-spacing: 0; text-transform: none; }
.topic-card h1 { font-size: 1.22rem; line-height: 1.3; margin-top: 3px; color: var(--text); }
.thread { gap: 14px; }
.row.with-av { flex-direction: row; align-items: flex-start; gap: 10px; max-width: 90%; }
.row.with-av .av { width: 34px; height: 34px; margin-top: 2px; box-shadow: none; }
.row.with-av .bubble { border-radius: 6px 20px 20px 20px; box-shadow: 0 2px 10px rgba(15,40,60,.05); }
[dir="rtl"] .row.with-av .bubble { border-radius: 20px 6px 20px 20px; }
.under { gap: 10px; margin: 7px 2px 0; font-size: .75rem; color: var(--faint); flex-wrap: wrap; }
.under > * { white-space: nowrap; }
.under .from { padding: 0; border: 0; background: none; color: var(--faint); font-size: .75rem; font-weight: 500; cursor: pointer; }
.under .listen { display: inline-flex; align-items: center; gap: 4px; height: 26px; padding: 0 11px 0 8px; border: 0; border-radius: 99px; background: var(--blue-soft); color: var(--blue-ink); font-size: .75rem; font-weight: 600; cursor: pointer; }
.under .listen.on { background: var(--blue-ink); color: #fff; }
.row.mine .under { justify-content: flex-end; gap: 4px; color: var(--muted); }
.system { padding: 12px 16px 14px; border-radius: 16px; background: #fff; border: 1px solid var(--line); box-shadow: none; }
.system p { margin: 0; line-height: 1.5; }
.note-btn { margin-top: 10px; height: 32px; padding: 0 14px; border-radius: 99px; border: 1px solid rgba(0,119,168,.25); background: #fff; color: var(--blue-ink); font: 600 .8rem/1 var(--font); cursor: pointer; }

/* composer: + menu (photo, document, private), input with mic, send */
.composer { padding: 8px 14px calc(12px + env(safe-area-inset-bottom)); }
.composer-in { align-items: flex-end; gap: 8px; }
.icon { padding: 0; display: grid; place-items: center; }
.icon.plus { width: 46px; height: 46px; border: 1px solid rgba(15,40,60,.1); background: #fff; color: var(--text); box-shadow: none; }
.icon.plus .i { transition: transform .25s var(--ease); }
.icon.plus.open .i { transform: rotate(45deg); }
.input-wrap { min-height: 46px; align-items: center; padding: 3px 4px 3px 16px; border-radius: 23px; }
.input-wrap textarea { padding: 10px 0; }
.input-wrap textarea:placeholder-shown { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.icon.mic { width: 38px; height: 38px; color: var(--muted); }
.icon.mic.rec { background: #e5484d; color: #fff; }
.icon.send { width: 46px; height: 46px; background: var(--un); box-shadow: 0 6px 16px rgba(0,158,219,.28); }
.private-chip { max-width: 640px; margin: 0 auto 8px; display: flex; align-items: center; gap: 8px; padding: 7px 7px 7px 12px; border-radius: 14px; background: #fff4dc; color: #8a5a00; font-size: .82rem; font-weight: 600; }
.private-chip > span:not(.i) { flex: 1; }
.chip-x { width: 28px; height: 28px; padding: 0; display: grid; place-items: center; border: 0; border-radius: 50%; background: rgba(138,90,0,.1); color: inherit; cursor: pointer; }
.menu.plus-menu { min-width: 270px; }
.menu .with-icon { justify-content: flex-start; gap: 12px; }
.menu-icon { width: 36px; height: 36px; border-radius: 11px; display: grid; place-items: center; background: var(--blue-soft); color: var(--blue-ink); }
.menu .with-icon:last-child .menu-icon { background: #fff4dc; color: #8a5a00; }
.c-status { padding: 0 4px; }

/* big screen v4: clean */
.screen-body.v3 .s-top { border-bottom: 0; padding-bottom: 0; margin-bottom: 4vh; }
.screen-body.v3 .brand { font-size: 1.55em; }
.screen-body.v3 .s-right { background: rgba(255,255,255,.72); border-inline-start: 1px solid rgba(15,40,60,.06); gap: 1.6vh; }
.screen-body.v3 .join-title { font-family: var(--display); font-size: 2.2em; font-weight: 700; letter-spacing: -.02em; }
.screen-body.v3 .join-title-2 { font-size: 1.6em; font-weight: 700; color: var(--muted); margin-top: -.6vh; }
.qr-card { width: min(21vw, 42vh); aspect-ratio: 1; margin: 2.4vh 0 1.4vh; padding: 1.2vw; border-radius: 28px; background: #fff; box-shadow: 0 20px 50px rgba(15,40,60,.08); }
.qr-card img { width: 100%; height: 100%; display: block; }
.screen-body.v3 .join-url { font-size: 1.15em; font-weight: 600; color: var(--blue-ink); }
.screen-body.v3 .join-dial { border: 0; padding: 0; font-size: .95em; color: var(--muted); }
.screen-body.v3 .join-dial b { color: var(--text); }
.screen-body.v3 .w-card { gap: .55em; }
.screen-body.v3 .w-head .av { width: 2.5em; height: 2.5em; }
.dial-top { border-bottom: 0; } .dial-top .brand { font-size: 1.5rem; }
.lang-grid .lang-btn.picked { background: #e8f6fc; border-color: rgba(0,158,219,.55); box-shadow: none; }
.screen-body.v3 .w-second { padding: 0 0 0 3.2em; } .screen-body.v3 .w-second[dir="rtl"] { text-align: right; }

/* minimal line icons on soft circles */
.av { background: #e4f3fa; color: #0a84c0; box-shadow: none; }
.av svg { width: 56%; height: 56%; }
.av.hero { background: #e4f3fa; box-shadow: 0 0 0 6px #fff, 0 16px 36px rgba(0,119,168,.14); }
.av.hero svg { width: 50%; height: 50%; stroke-width: 1.3; }
.av-cell.on .av { background: #fff; box-shadow: 0 0 0 2px var(--un); }
.call-av .av { background: rgba(255,255,255,.12); color: #fff; }
/* welcome card and one-line greetings */
.speech .title { position: relative; font-family: var(--display); font-size: 1.15rem; font-weight: 700; color: var(--text); line-height: 1.35; }
.speech .sub { position: relative; font-size: .86rem; color: var(--muted); line-height: 1.5; margin-top: 4px; }
.lang-grid .lang-btn span { display: block; font-size: .7rem; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; letter-spacing: -.005em; }
.lang-grid .lang-btn { padding: 12px 13px; min-width: 0; }
.lang-grid .lang-btn span { font-size: .76rem; }
.row.with-av .av, .w-head .av, .q-top .av { background: #fff; box-shadow: inset 0 0 0 1.5px rgba(0,158,219,.28); } .row.with-av .av svg, .w-head .av svg, .q-top .av svg { stroke-width: 1.8; }

/* v5: smoother phones, pinned topic, intro, leave, dialogs */
html:has(body.phone-body), body.phone-body { height: 100%; overflow: hidden; overscroll-behavior: none; }
body.phone-body { position: fixed; inset: 0; -webkit-tap-highlight-color: transparent; }
body.phone-body button { touch-action: manipulation; }
.app { will-change: transform; }
.top-right { display: flex; align-items: center; gap: 8px; }
.leave-btn { width: 34px; height: 34px; padding: 0; display: grid; place-items: center; border: 0; border-radius: 50%; background: rgba(15,40,60,.06); color: var(--muted); cursor: pointer; }
.leave-btn svg { display: block; }
[dir="rtl"] .leave-btn svg { transform: scaleX(-1); }
.topic-card { position: sticky; top: 0; z-index: 6; box-shadow: 0 6px 20px rgba(15,40,60,.07); }
.p-main { scroll-padding-top: 90px; }
.under .listen { order: 0; }
.intro { min-height: 100%; display: flex; flex-direction: column; align-items: center; justify-content: center; text-align: center; padding: 10px 14px 30px; animation: introIn .6s var(--ease) both; }
.intro .av.hero { width: 96px; height: 96px; margin-bottom: 26px; }
.intro-label { font-size: .85rem; font-weight: 600; color: var(--blue-ink); }
.intro h1 { font-family: var(--display); font-size: 1.9rem; line-height: 1.2; letter-spacing: -.02em; color: var(--text); margin: 8px 0 12px; max-width: 16ch; animation: introIn .7s .15s var(--ease) both; }
.intro p { color: var(--muted); font-size: .95rem; line-height: 1.5; max-width: 28ch; margin: 0; animation: introIn .7s .3s var(--ease) both; }
.intro-bar { width: 120px; height: 4px; border-radius: 4px; background: rgba(0,158,219,.15); margin: 30px 0 26px; overflow: hidden; }
.intro-bar i { display: block; height: 100%; width: 100%; background: var(--un); transform-origin: left; animation: introBar 5.2s linear both; }
.intro .big-btn { max-width: 300px; animation: introIn .7s .45s var(--ease) both; }
@keyframes introIn { from { opacity: 0; transform: translateY(10px); } to { opacity: 1; transform: none; } }
@keyframes introBar { from { transform: scaleX(0); } to { transform: scaleX(1); } }
.p-main.fade-out { opacity: 0; transition: opacity .3s ease; }
.dlg-back { position: fixed; inset: 0; z-index: 50; display: grid; place-items: center; padding: 24px; background: rgba(15,27,38,.32); animation: fadeIn .2s ease both; }
.dlg { width: min(340px, 100%); padding: 22px 20px 18px; border-radius: 22px; background: #fff; box-shadow: 0 30px 70px rgba(15,40,60,.25); text-align: center; animation: pop .3s var(--ease) both; }
.dlg h2 { font-family: var(--display); font-size: 1.15rem; margin: 0 0 8px; color: var(--text); }
.dlg p { margin: 0; color: var(--muted); font-size: .92rem; line-height: 1.5; }
.dlg-acts { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; margin-top: 18px; }
.dlg-acts button { height: 46px; border-radius: 14px; border: 0; font: 600 .95rem/1 var(--font); cursor: pointer; }
.dlg-acts button:only-child { grid-column: 1 / -1; }
.btn-ghost { background: rgba(15,40,60,.06); color: var(--text); }
.btn-primary { background: var(--un); color: #fff; }
.btn-danger { background: #e5484d; color: #fff; }
@keyframes fadeIn { from { opacity: 0; } to { opacity: 1; } }
@media (prefers-reduced-motion: reduce) { .intro, .intro h1, .intro p, .intro .big-btn, .dlg, .dlg-back { animation: none; } }
.p-main { padding-top: 0; } .topic-card { top: 0; margin-top: 4px; }
.topic-wrap { position: sticky; top: 0; z-index: 6; margin: 0 -16px 12px; padding: 6px 16px 10px; background: rgba(243,248,251,.86); -webkit-backdrop-filter: blur(16px) saturate(1.2); backdrop-filter: blur(16px) saturate(1.2); }
.topic-wrap .topic-card { position: static; margin: 0; }

/* =================================================================
   CROSS WORLD: terms, Sharik-style topic page, floor states
   ================================================================= */
:root { --navy: #00425c; --gov: #007eb0; }
.terms { padding: 18px 6px 10px; }
.terms-icon { width: 54px; height: 54px; border-radius: 16px; display: grid; place-items: center; background: #e8f6fc; color: var(--gov); margin-bottom: 18px; }
.terms h1 { font-family: var(--display); font-size: 1.55rem; color: var(--navy); margin: 0 0 18px; letter-spacing: -.02em; }
.term { display: flex; gap: 14px; padding: 16px; border-radius: 18px; background: #fff; box-shadow: 0 6px 22px rgba(0,66,92,.06); margin-bottom: 12px; }
.term .n { flex: none; width: 28px; height: 28px; border-radius: 50%; display: grid; place-items: center; background: var(--gov); color: #fff; font-weight: 700; font-size: .85rem; }
.term p { margin: 0; color: #34405e; line-height: 1.55; font-size: .95rem; }

.tp { padding: 6px 0 24px; }
.tp-hero { position: relative; height: 210px; border-radius: 48px 22px 22px 22px; overflow: hidden; box-shadow: 0 18px 40px rgba(0,66,92,.18); }
.tp-hero img { width: 100%; height: 100%; object-fit: cover; display: block; }
.tp-hero::after { content: ""; position: absolute; inset: 0; background: linear-gradient(160deg, rgba(0,158,219,.18) 0%, rgba(0,158,219,.42) 55%, rgba(0,66,92,.72) 100%); }
.tp-chip { position: absolute; z-index: 1; left: 14px; bottom: 14px; display: inline-flex; align-items: center; gap: 8px; padding: 8px 14px; border-radius: 12px; background: rgba(255,255,255,.18); border: 1px solid rgba(255,255,255,.35); color: #fff; font-size: .8rem; font-weight: 600; -webkit-backdrop-filter: blur(12px); backdrop-filter: blur(12px); }
.tp-chip .dot { width: 7px; height: 7px; border-radius: 50%; background: #7fe0ff; box-shadow: 0 0 0 3px rgba(127,224,255,.25); }
.tp-body { padding: 20px 4px 0; }
.tp-label { font-size: .78rem; font-weight: 700; color: var(--gov); letter-spacing: .06em; text-transform: uppercase; }
.tp h1 { font-family: var(--display); font-size: 1.6rem; line-height: 1.22; letter-spacing: -.02em; color: var(--navy); margin: 6px 0 16px; }
.tp-details { padding: 16px 16px 6px; border-radius: 18px; background: #fff; box-shadow: 0 6px 22px rgba(0,66,92,.06); }
.tp-details p { margin: 8px 0 12px; color: #34405e; line-height: 1.6; font-size: .95rem; }
.topic-status { margin-top: 18px; }
.floor-soon { display: grid; justify-items: center; gap: 6px; text-align: center; padding: 18px 14px; border-radius: 18px; background: #e8f6fc; color: #34405e; }
.floor-soon b { color: var(--navy); font-size: 1rem; }
.floor-soon span { font-size: .86rem; line-height: 1.5; }
.floor-closed { text-align: center; color: #34405e; margin: 0 0 12px; }
.big-btn.share { background: var(--gov); box-shadow: 0 12px 26px rgba(0,158,219,.3); animation: pop .5s var(--ease) both; }
.big-btn.ghost { background: #fff; color: var(--gov); box-shadow: inset 0 0 0 1.5px rgba(0,158,219,.35); }
.topic-top { display: flex; align-items: center; justify-content: space-between; gap: 10px; }
.details-link { display: inline-flex; align-items: center; gap: 0; padding: 0; border: 0; background: none; color: var(--blue-ink); font: 600 .78rem/1 var(--font); cursor: pointer; }
[dir="rtl"] .details-link svg { transform: scaleX(-1); }

/* Cross World on the big screen */
.screen-body.v3 .s-top { display: flex; align-items: center; justify-content: space-between; }
.cw-badge { display: inline-flex; align-items: center; gap: .75em; }
.cw-emblem { width: 2.9em; height: 2.9em; border-radius: 50%; display: grid; place-items: center; background: linear-gradient(145deg, #00a7e1, #009edb 70%, #00425c); box-shadow: 0 8px 22px rgba(0,158,219,.28); }
.cw-emblem svg { width: 74%; height: 74%; display: block; }
.cw-text { display: grid; line-height: 1.15; }
.cw-text b { font-family: var(--display); font-size: 1.05em; color: var(--navy); letter-spacing: -.01em; }
.cw-text span { font-size: .82em; color: var(--gov); font-weight: 600; }
.s-wall.pre { display: block; overflow: visible; -webkit-mask-image: none; mask-image: none; }
.s-hero { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1.05fr); gap: 2.6vw; align-items: center; height: 100%; }
.s-hero .label { font-size: .95em; color: var(--gov); font-weight: 700; letter-spacing: .06em; text-transform: uppercase; }
.s-hero .label span { color: var(--faint); font-weight: 600; letter-spacing: 0; text-transform: none; }
.s-hero h1 { font-family: var(--display); font-size: 2.75em; line-height: 1.12; letter-spacing: -.025em; color: var(--navy); margin: .35em 0 .25em; }
.s-hero .s-second { font-size: 1.3em; }
.s-details { margin-top: 1.4vh; color: #34405e; font-size: 1.08em; line-height: 1.6; max-width: 40em; }
.s-details p { margin: 0 0 .7em; display: -webkit-box; -webkit-box-orient: vertical; -webkit-line-clamp: 4; overflow: hidden; }
.floor-pill { display: inline-flex; align-items: center; gap: .6em; margin-top: 1.6vh; padding: .55em 1.1em; border-radius: 99px; background: #e8f6fc; color: var(--navy); font-weight: 600; font-size: .95em; }
.floor-pill .dot { width: .6em; height: .6em; border-radius: 50%; background: var(--gov); }
.floor-pill.before .dot { animation: live 1.8s ease-out infinite; }
.floor-pill.open { background: #e6f7ee; color: #0f5132; }
.floor-pill.open .dot { background: #22b35e; box-shadow: 0 0 0 0 rgba(34,179,94,.5); animation: live 1.8s ease-out infinite; }
.floor-pill.closed { background: rgba(15,40,60,.06); color: var(--muted); }
.floor-pill.closed .dot { background: var(--faint); }
.floor-pill .sub { color: var(--muted); font-weight: 500; }
.s-collage { display: grid; grid-template-columns: 1.25fr 1fr; grid-template-rows: 1fr 1fr; gap: 1vw; height: min(62vh, 100%); }
.s-collage .ph { position: relative; margin: 0; overflow: hidden; border-radius: 24px; box-shadow: 0 18px 44px rgba(0,66,92,.16); }
.s-collage .p1 { grid-row: 1 / 3; border-radius: 120px 24px 24px 24px; }
.s-collage .p3 { border-radius: 24px 24px 90px 24px; }
.s-collage img { width: 100%; height: 100%; object-fit: cover; display: block; }
.s-collage .ph::after { content: ""; position: absolute; inset: 0; background: linear-gradient(165deg, rgba(0,158,219,.12) 0%, rgba(0,158,219,.38) 60%, rgba(0,66,92,.62) 100%); }
.s-collage figcaption { position: absolute; z-index: 1; left: 1em; right: auto; bottom: 1em; display: inline-flex; align-items: center; gap: .55em; padding: .5em 1em; border-radius: 12px; background: rgba(255,255,255,.18); border: 1px solid rgba(255,255,255,.35); color: #fff; font-weight: 600; font-size: .9em; -webkit-backdrop-filter: blur(12px); backdrop-filter: blur(12px); }
.s-collage figcaption .dot { width: .5em; height: .5em; border-radius: 50%; background: #7fe0ff; }
.s-collage .p1 figcaption { top: 1.2em; bottom: auto; }
.floor-seg { display: grid; grid-template-columns: repeat(3, 1fr); width: 100%; } .floor-seg button { padding: 9px 6px; font-size: .85rem; }
.tr-edit { margin-inline-start: 8px; padding: 2px 8px; border-radius: 8px; border: 1px solid var(--line); background: #fff; color: var(--blue-ink); font-size: .75rem; font-weight: 600; cursor: pointer; }
.screen-body.v3 .s-left { padding-bottom: 3vh; }
.s-hero { align-items: center; }
.s-hero h1 { font-size: 2.2em; margin: .3em 0 .2em; }
.s-hero .s-second { font-size: 1.1em; line-height: 1.45; }
.s-details { font-size: 1em; line-height: 1.55; margin-top: 1.2vh; }
.s-details p { -webkit-line-clamp: 3; margin-bottom: .55em; }
.s-collage { height: min(64vh, 100%); }
.screen-body.v3 .s-topic { margin-bottom: 2.4vh; }
.screen-body.v3 .s-topic .label { color: var(--gov); font-weight: 700; letter-spacing: .06em; text-transform: uppercase; font-size: .85em; }
.screen-body.v3 .s-topic .label span { color: var(--faint); font-weight: 600; letter-spacing: 0; text-transform: none; }
.screen-body.v3 .s-topic h1 { font-family: var(--display); font-size: 2em; line-height: 1.15; color: var(--navy); max-width: 34ch; margin-top: .25em; }
.screen-body.v3 .s-topic .s-second { font-size: 1.05em; margin-top: .3em; }
.screen-body.v3 .s-topic .floor-pill { margin-top: 1.4vh; }

/* community guidelines */
.terms-kicker { font-size: .78rem; font-weight: 700; letter-spacing: .06em; text-transform: uppercase; color: var(--gov); margin-bottom: 6px; }
.terms h1 { margin-bottom: 12px; }
.g-intro { color: #34405e; line-height: 1.6; margin: 0 0 16px; font-size: .95rem; }
.g-card { padding: 16px 16px 6px; border-radius: 18px; background: #fff; box-shadow: 0 6px 22px rgba(0,66,92,.06); margin-bottom: 16px; }
.g-lead { margin: 0 0 10px; font-weight: 600; color: var(--navy); font-size: .95rem; }
.g-list { margin: 0; padding: 0; list-style: none; }
.g-list li { position: relative; padding-inline-start: 22px; margin-bottom: 11px; color: #34405e; line-height: 1.5; font-size: .92rem; }
.g-list li::before { content: ""; position: absolute; inset-inline-start: 2px; top: .5em; width: 8px; height: 8px; border-radius: 50%; background: var(--gov); }
.g-text { color: #4b5873; line-height: 1.6; margin: 0 0 12px; font-size: .88rem; }
.g-closing { color: var(--navy); font-weight: 600; line-height: 1.55; margin: 4px 0 18px; font-size: .95rem; }
.g-check { display: flex; gap: 12px; align-items: flex-start; padding: 14px 16px; border-radius: 16px; background: #e8f6fc; border: 1.5px solid rgba(0,158,219,.25); color: var(--navy); font-size: .9rem; line-height: 1.5; cursor: pointer; margin-bottom: 8px; }
.g-check input { flex: none; width: 22px; height: 22px; margin: 1px 0 0; accent-color: var(--gov); }
.big-btn:disabled { background: rgba(15,40,60,.14); color: rgba(15,40,60,.4); box-shadow: none; cursor: default; }
.g-ack { font-size: .78rem; font-weight: 700; letter-spacing: .06em; text-transform: uppercase; color: var(--gov); margin: 4px 2px 8px; }

/* v3 visuals: one image, no text on it; Cross World under the QR; pinned floor status */
.s-hero { grid-template-columns: minmax(0, 1.1fr) minmax(0, .9fr); }
.s-photo { margin: 0; position: relative; height: min(60vh, 100%); border-radius: 140px 28px 28px 28px; overflow: hidden; box-shadow: 0 24px 60px rgba(0,66,92,.16); }
.s-photo img { width: 100%; height: 100%; object-fit: cover; display: block; }
.s-photo::after { content: ""; position: absolute; inset: 0; background: linear-gradient(180deg, rgba(0,158,219,0) 45%, rgba(0,158,219,.22) 100%); }
.tp-hero::after { background: linear-gradient(180deg, rgba(0,158,219,0) 45%, rgba(0,158,219,.22) 100%); }
.cw-line { display: grid; gap: .2em; margin-top: 2.4vh; text-align: center; font-family: var(--display); }
.cw-line b { font-size: 1.25em; font-weight: 700; color: var(--navy); letter-spacing: -.01em; }
.cw-line span { font-size: 1em; font-weight: 500; color: var(--muted); }
#foot .floor-soon { grid-template-columns: auto 1fr; justify-items: start; text-align: start; column-gap: 12px; row-gap: 2px; padding: 14px 16px; border-radius: 16px; background: var(--navy); color: rgba(255,255,255,.8); box-shadow: 0 12px 30px rgba(0,66,92,.25); }
#foot .floor-soon .pulse-dots { grid-row: 1 / 3; align-self: center; }
#foot .floor-soon .pulse-dots i { background: #7fe0ff; }
#foot .floor-soon b { color: #fff; font-size: .98rem; }
#foot .floor-soon span { font-size: .82rem; }
.tp { padding-bottom: 8px; }
.big-btn.share { background: #009edb; } .term .n, .g-list li::before { background: #009edb; }
.s-photo.globe { border-radius: 0; box-shadow: none; overflow: visible; height: min(66vh, 100%); display: grid; place-items: center; }
.s-photo.globe::after { content: none; }
.s-photo.globe img { width: auto; height: 100%; max-width: 100%; object-fit: contain; }
.tp-hero { height: auto; aspect-ratio: 1 / .78; border-radius: 28px; background: radial-gradient(circle at 50% 45%, #ffffff 0%, #eef8fd 60%, #e3f3fb 100%); box-shadow: 0 10px 30px rgba(0,66,92,.08); display: grid; place-items: center; }
.tp-hero::after { content: none; }
.tp-hero img { width: auto; height: 100%; object-fit: contain; padding: 4px; }
.s-hero { grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 1.5vw; }
.s-photo.globe { position: relative; height: 70vh; display: block; }
.s-photo.globe img { position: absolute; inset: 0; width: 100%; height: 100%; max-width: none; object-fit: contain; }
.tp-hero { position: relative; display: block; }
.tp-hero img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: contain; padding: 6px; }
.s-photo.globe canvas, .tp-hero canvas { position: absolute; inset: 0; }
.s-hero { grid-template-columns: minmax(0, .92fr) minmax(0, 1.08fr); gap: 1vw; } .s-photo.globe { height: 74vh; }

/* cleaner hero on the big screen */
.s-hero { grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 3vw; }
.s-hero-text { max-width: 34em; }
.s-hero .label { font-size: .85em; }
.s-hero h1 { font-size: 2.35em; line-height: 1.16; margin: .55em 0 .5em; }
.s-hero .s-second { font-size: 1.12em; line-height: 1.55; color: #5f6f7d; font-weight: 600; }
.s-details { margin-top: 3vh; padding-top: 3vh; border-top: 1px solid rgba(0,66,92,.08); font-size: 1.02em; line-height: 1.7; color: #4b5873; }
.s-details p { -webkit-line-clamp: 4; margin: 0; }
.s-hero .floor-pill { margin-top: 3.6vh; }
.s-photo.globe { height: 62vh; overflow: visible; }
.screen-body.v3 .s-left, .s-wall.pre, .s-hero { overflow: visible; }
.tp-hero { overflow: hidden; background: linear-gradient(180deg, #f7fcfe, #eaf6fb); box-shadow: 0 8px 24px rgba(0,66,92,.06); }

/* pinned topic: soft gradient fade, no hard edges */
.topic-wrap { background: linear-gradient(180deg, rgba(243,248,251,0) 0%, rgba(243,248,251,.9) 22%, rgba(243,248,251,.9) 72%, rgba(243,248,251,0) 100%); -webkit-backdrop-filter: none; backdrop-filter: none; padding: 6px 16px 22px; margin-bottom: -4px; }
.topic-wrap .topic-card { box-shadow: 0 10px 30px rgba(0,66,92,.08); }
.p-top.v4 { background: transparent; }
