:root{
  --bg:#f4f7fb;--surface:#fff;--surface-2:#f8fafc;--surface-3:#eef2f7;
  --ink:#172033;--muted:#667085;--subtle:#98a2b3;--line:#e4e7ec;
  --brand:#3157d5;--brand-strong:#2545b8;--brand-soft:#eef2ff;
  --nav:#111827;--nav-2:#182233;--success:#15803d;--danger:#c0263d;
  --warning:#a16207;--radius:16px;--radius-sm:11px;
  --shadow-sm:0 1px 2px rgba(16,24,40,.04),0 1px 3px rgba(16,24,40,.08);
  --shadow:0 14px 34px rgba(16,24,40,.10);--max:1200px;
}
*{box-sizing:border-box}html{scroll-behavior:smooth}body{margin:0;font-family:Inter,ui-sans-serif,-apple-system,BlinkMacSystemFont,"Segoe UI",sans-serif;background:var(--bg);color:var(--ink);line-height:1.5}button,input,textarea{font:inherit}button,a{ -webkit-tap-highlight-color:transparent}button{cursor:pointer}a{color:var(--brand)}:focus-visible{outline:3px solid rgba(49,87,213,.22);outline-offset:2px}img{max-width:100%}
/* Shared buttons and forms */
.primary-btn,.send-button,.auth-card button,.sidebar-actions button,.modal-card>div>button{border:0;border-radius:var(--radius-sm);background:var(--brand);color:#fff;padding:11px 16px;font-weight:800;box-shadow:0 1px 2px rgba(16,24,40,.12);transition:.18s ease}.primary-btn:hover,.send-button:hover,.auth-card button:hover,.sidebar-actions button:hover{background:var(--brand-strong);transform:translateY(-1px)}.primary-btn:disabled,button:disabled{opacity:.55;cursor:not-allowed;transform:none}.secondary-btn,.sidebar-actions .secondary{background:#344054!important;color:#fff}.eyebrow{display:inline-block;font-size:11px;letter-spacing:.14em;font-weight:900;color:var(--brand);text-transform:uppercase}.backlink{display:inline-flex;align-items:center;gap:6px;color:#475467;text-decoration:none;font-weight:750;margin-bottom:14px}.backlink:hover{color:var(--brand)}
/* Messaging shell */
.app-shell{height:100dvh;display:grid;grid-template-columns:320px minmax(0,1fr);background:var(--surface)}.sidebar{background:linear-gradient(180deg,var(--nav),#0c1320);color:#fff;display:flex;flex-direction:column;min-width:0;border-right:1px solid rgba(255,255,255,.06)}.sidebar-header,.chat-header{min-height:72px;display:flex;align-items:center;padding:0 20px}.sidebar-header{justify-content:space-between;border-bottom:1px solid rgba(255,255,255,.08)}.brand-lockup{display:flex;align-items:center;gap:11px;min-width:0}.brand-mark{width:38px;height:38px;border-radius:12px;background:linear-gradient(145deg,#5f7df0,var(--brand));display:grid;place-items:center;font-weight:900;box-shadow:0 8px 22px rgba(49,87,213,.34)}.sidebar-header strong{font-size:16px;display:block;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}.sidebar-header small{display:block;color:#98a2b3;font-size:12px;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}.icon-button{width:38px;height:38px;border-radius:10px;color:#d0d5dd;text-decoration:none;display:grid;place-items:center;font-size:18px;background:rgba(255,255,255,.06)}.icon-button:hover{background:rgba(255,255,255,.12);color:#fff}.sidebar-actions{display:grid;grid-template-columns:1fr 1fr;gap:9px;padding:16px}.sidebar-actions button{padding:10px 12px}.community-nav-button{grid-column:1/-1;background:rgba(255,255,255,.08);border:1px solid rgba(255,255,255,.08);color:#fff;text-decoration:none;text-align:center;padding:10px;border-radius:var(--radius-sm);font-weight:800}.community-nav-button:hover{background:rgba(255,255,255,.13)}.conversation-list{overflow:auto;padding:0 9px 12px}.conversation{width:100%;border:0;background:transparent;color:#fff;display:flex;gap:11px;text-align:left;padding:11px;border-radius:12px;margin:2px 0;transition:.15s}.conversation:hover,.conversation.active{background:rgba(255,255,255,.09)}.avatar{width:42px;height:42px;flex:0 0 42px;border-radius:13px;display:grid;place-items:center;background:linear-gradient(145deg,#6d8af2,#3658d0);font-weight:850;box-shadow:inset 0 0 0 1px rgba(255,255,255,.18)}.conversation-copy{min-width:0;display:flex;flex-direction:column;justify-content:center}.conversation-copy strong,.conversation-copy small{white-space:nowrap;overflow:hidden;text-overflow:ellipsis}.conversation-copy strong{font-size:14px}.conversation-copy small{color:#98a2b3;margin-top:2px;font-size:12px}.sidebar-empty{padding:28px 18px;color:#98a2b3;text-align:center}.chat-panel{min-width:0;display:grid;grid-template-rows:72px minmax(0,1fr) auto;background:var(--surface)}.chat-header{border-bottom:1px solid var(--line);background:rgba(255,255,255,.92);backdrop-filter:blur(12px);justify-content:space-between}.chat-header h1{font-size:17px;margin:0}.chat-header p{margin:2px 0 0;color:var(--muted);font-size:12px}.chat-status{display:flex;align-items:center;gap:7px;color:var(--muted);font-size:12px}.status-dot{width:8px;height:8px;border-radius:50%;background:#22c55e}.mobile-menu{display:none;border:0;background:var(--surface-3);border-radius:10px;width:40px;height:40px;font-size:20px;margin-right:11px}.messages{overflow:auto;padding:26px clamp(16px,3vw,38px);display:flex;flex-direction:column;gap:14px;background:linear-gradient(180deg,#f8fafc,#f5f7fb)}.empty-state{margin:auto;text-align:center;color:var(--muted);max-width:340px}.empty-icon{width:68px;height:68px;border-radius:22px;margin:0 auto 14px;display:grid;place-items:center;font-size:30px;background:var(--brand-soft);box-shadow:var(--shadow-sm)}.empty-state h2{color:var(--ink);margin:0 0 4px;font-size:20px}.empty-state p{margin:0}.message{max-width:min(72%,720px)}.message.mine{align-self:flex-end}.message.theirs{align-self:flex-start}.message-meta{display:flex;gap:8px;align-items:center;font-size:11px;color:var(--muted);margin:0 7px 4px}.message.mine .message-meta{justify-content:flex-end}.bubble{background:#fff;border:1px solid var(--line);border-radius:17px 17px 17px 5px;padding:10px 13px;box-shadow:var(--shadow-sm);overflow-wrap:anywhere}.mine .bubble{background:var(--brand);color:#fff;border-color:var(--brand);border-radius:17px 17px 5px 17px}.bubble a{color:inherit;text-decoration:underline}.message-image{display:block;max-width:390px;width:100%;margin-top:8px;border-radius:12px}.composer{position:relative;display:grid;grid-template-columns:auto auto minmax(0,1fr) auto;gap:9px;align-items:end;padding:13px 18px calc(13px + env(safe-area-inset-bottom));border-top:1px solid var(--line);background:#fff}.composer textarea{resize:none;max-height:140px;border:1px solid #d0d5dd;border-radius:14px;padding:10px 13px;outline:none;min-height:42px;background:#fff}.composer textarea:focus{border-color:var(--brand);box-shadow:0 0 0 3px rgba(49,87,213,.10)}.composer-icon{border:0;background:var(--surface-3);border-radius:11px;width:42px;height:42px;font-size:19px;color:#344054}.composer-icon:hover{background:#e4e9f2}.attach{display:grid;place-items:center;cursor:pointer}.attach input{display:none}.send-button{height:42px;padding:10px 17px}.upload-preview{position:absolute;left:108px;bottom:63px;font-size:12px;background:#fff;padding:6px 9px;border-radius:8px;box-shadow:var(--shadow)}.upload-preview:empty{display:none}.emoji-picker{position:absolute;left:18px;bottom:68px;background:#fff;border:1px solid var(--line);border-radius:14px;padding:8px;display:grid;grid-template-columns:repeat(6,36px);box-shadow:var(--shadow)}.emoji-picker button{border:0;background:transparent;font-size:20px;padding:5px;border-radius:8px}.emoji-picker button:hover{background:var(--surface-3)}
/* Modal */
.modal{position:fixed;inset:0;background:rgba(15,23,42,.62);backdrop-filter:blur(5px);display:grid;place-items:center;padding:20px;z-index:50}.modal.hidden{display:none}.modal-card{position:relative;width:min(560px,100%);max-height:min(86dvh,780px);overflow:auto;background:#fff;border-radius:20px;padding:26px;box-shadow:0 30px 90px rgba(15,23,42,.32)}.modal-close{position:absolute;right:14px;top:12px;border:0;background:var(--surface-3);font-size:24px;width:36px;height:36px;border-radius:10px}.modal-card h2{margin:0 44px 18px 0;font-size:22px}.modal-card label,.auth-card label{display:block;font-weight:750;margin:14px 0 6px;color:#344054;font-size:13px}.modal-card input,.auth-card input,.modal-card textarea,.reply-form textarea{width:100%;padding:11px 12px;border:1px solid #d0d5dd;border-radius:11px;margin-top:6px;background:#fff;color:var(--ink)}.modal-card input:focus,.auth-card input:focus,.modal-card textarea:focus,.reply-form textarea:focus{border-color:var(--brand);outline:0;box-shadow:0 0 0 3px rgba(49,87,213,.10)}.user-results{max-height:270px;overflow:auto;margin:12px 0}.user-row{display:flex!important;align-items:center;gap:10px;padding:10px;margin:0!important;border-bottom:1px solid var(--line)}.user-row input{width:auto!important;margin:0!important}.user-row span{display:flex;flex-direction:column}.user-row small{color:var(--muted)}
/* Authentication */
.auth-page{min-height:100dvh;display:grid;place-items:center;padding:24px;background:radial-gradient(circle at 15% 10%,#e7edff 0,transparent 34%),radial-gradient(circle at 85% 85%,#e7f5f1 0,transparent 34%),#f7f9fc}.auth-card{width:min(450px,100%);background:#fff;border:1px solid rgba(228,231,236,.85);border-radius:24px;padding:34px;box-shadow:0 24px 80px rgba(16,24,40,.12)}.auth-brand{display:flex;align-items:center;gap:10px;margin-bottom:26px}.auth-brand .brand-mark{color:#fff}.auth-card h1{margin:0;font-size:29px;letter-spacing:-.02em}.auth-card>p{color:var(--muted);margin:7px 0 20px}.auth-card button{width:100%;margin-top:18px;padding:12px}.auth-switch{text-align:center;font-size:14px}.alert{background:#fff1f3;color:#9f1239;border:1px solid #fecdd3;padding:11px 12px;border-radius:11px;margin-top:16px}
/* Community application shell */
.community-page{background:var(--bg)}.community-topbar{height:68px;background:rgba(17,24,39,.97);color:#fff;display:flex;align-items:center;justify-content:space-between;padding:0 max(20px,calc((100vw - var(--max))/2));position:sticky;top:0;z-index:30;box-shadow:0 1px 0 rgba(255,255,255,.06)}.community-topbar .brand{color:#fff;text-decoration:none;font-size:17px;font-weight:900;display:flex;align-items:center;gap:9px}.community-topbar .brand:before{content:"M";width:32px;height:32px;border-radius:10px;background:linear-gradient(145deg,#6b82ee,var(--brand));display:grid;place-items:center;font-size:13px}.community-topbar nav{display:flex;align-items:center;gap:5px}.community-topbar nav a{color:#b8c0cf;text-decoration:none;font-weight:750;font-size:13px;padding:9px 12px;border-radius:9px}.community-topbar nav a:hover,.community-topbar nav a.active{color:#fff;background:rgba(255,255,255,.09)}.community-wrap{width:min(var(--max),calc(100% - 32px));margin:0 auto;padding:34px 0 54px}.community-hero{display:grid;grid-template-columns:minmax(0,1fr) minmax(320px,520px);align-items:end;gap:34px;margin:10px 0 28px}.community-hero h1,.community-banner h1,.original-post h1{font-size:clamp(30px,4.5vw,46px);line-height:1.07;letter-spacing:-.035em;margin:5px 0 10px}.community-hero p,.community-banner p{color:var(--muted);margin:0;max-width:680px}.community-search{display:flex;width:100%;box-shadow:var(--shadow-sm);border-radius:13px}.community-search input{flex:1;min-width:0;border:1px solid #d0d5dd;border-right:0;border-radius:13px 0 0 13px;padding:12px 14px;background:#fff}.community-search input:focus{outline:0;border-color:var(--brand)}.community-search button{border:0;background:var(--brand);color:#fff;font-weight:800;padding:12px 18px;border-radius:0 13px 13px 0}.community-grid,.thread-list{display:grid;gap:13px}.community-grid{grid-template-columns:repeat(2,minmax(0,1fr))}.community-card,.thread-card{display:flex;gap:16px;align-items:center;background:#fff;border:1px solid var(--line);border-radius:17px;padding:18px;text-decoration:none;color:inherit;box-shadow:var(--shadow-sm);transition:.18s ease}.community-card:hover,.thread-card:hover{border-color:#b8c5ef;box-shadow:0 10px 28px rgba(16,24,40,.08);transform:translateY(-2px)}.community-card h2,.thread-card h2{font-size:17px;line-height:1.3;margin:0 0 5px;letter-spacing:-.01em}.community-card p,.thread-card p{margin:0 0 8px;color:#475467;font-size:14px}.community-card small,.thread-card small,.community-banner small{color:var(--muted);font-size:12px}.community-avatar{width:50px;height:50px;flex:0 0 50px;border-radius:15px;display:grid;place-items:center;background:linear-gradient(145deg,#eef2ff,#dfe6ff);color:var(--brand);font-weight:900;font-size:20px;border:1px solid #d9e0fb}.community-avatar.large{width:72px;height:72px;font-size:28px;border-radius:20px}.community-banner{display:flex;align-items:center;gap:19px;background:#fff;border-radius:21px;padding:24px;border:1px solid var(--line);margin:6px 0 22px;box-shadow:var(--shadow-sm)}.grow{flex:1;min-width:0}.vote-stat{width:64px;flex:0 0 64px;text-align:center;background:var(--surface-2);border:1px solid var(--line);border-radius:13px;padding:9px 6px}.vote-stat strong{display:block;font-size:19px}.vote-stat span{font-size:11px;color:var(--muted)}.empty-card{padding:42px;background:#fff;border:1px dashed #cfd5df;border-radius:17px;text-align:center;color:var(--muted)}.check-row{display:flex!important;align-items:flex-start;gap:9px}.check-row input{width:auto!important;margin:3px 0 0!important}.blocked-badge{display:inline-flex;align-items:center;background:#fff1f3;color:#a8122d;border:1px solid #fecdd3;border-radius:999px;padding:9px 13px;font-weight:800;font-size:12px}
/* Thread */
.thread-layout{width:min(var(--max),calc(100% - 32px));margin:0 auto;padding:28px 0 54px;display:grid;grid-template-columns:minmax(0,1fr) 270px;gap:22px}.original-post,.highlights,.reply-form,.side-card,.rules-card,.rules-summary,.moderation-notice{background:#fff;border:1px solid var(--line);border-radius:18px;padding:22px;box-shadow:var(--shadow-sm)}.original-post{margin:0 0 17px}.thread-original-body{font-size:17px;line-height:1.72;color:#344054;margin:16px 0 20px}.original-post small{color:var(--muted)}.highlights{margin-bottom:17px;background:linear-gradient(180deg,#fffdf6,#fff);border-color:#f0df9f}.section-heading{display:flex;align-items:center;justify-content:space-between;gap:16px}.section-heading h2{margin:3px 0 11px;font-size:21px}.section-heading>span{font-size:12px;color:var(--warning);font-weight:800}.highlight-item{display:grid;grid-template-columns:70px minmax(0,1fr) auto;gap:13px;align-items:center;border-top:1px solid #eee5c5;padding:13px 0;text-decoration:none;color:inherit}.highlight-item strong{font-size:13px;color:#9a6700}.highlight-item blockquote{margin:0;color:#344054;font-size:14px;line-height:1.45}.highlight-item>span{font-size:12px;color:var(--brand);font-weight:800}.posts{display:grid;gap:11px}.reply-card{background:#fff;border:1px solid var(--line);border-radius:16px;padding:17px;scroll-margin-top:86px;box-shadow:var(--shadow-sm)}.reply-card header,.reply-card footer{display:flex;align-items:center;justify-content:space-between;gap:8px}.reply-card header strong{font-size:13px}.reply-card header a{color:var(--subtle);text-decoration:none;font-size:12px}.reply-body{padding:13px 0 15px;line-height:1.65;color:#344054}.reply-card footer{justify-content:flex-start;flex-wrap:wrap}.like-btn,.reply-link,.edit-btn,.flag-btn{border:1px solid var(--line);background:var(--surface-2);border-radius:9px;padding:7px 10px;font-weight:800;font-size:12px;color:#475467}.like-btn:hover,.reply-link:hover,.edit-btn:hover{background:var(--surface-3)}.like-btn.liked{background:#fff1f3;color:#b42342;border-color:#fecdd3}.flag-btn{background:#fff;border-color:transparent;color:#b42342;margin-left:auto}.flag-btn:hover{background:#fff1f3}.reply-form{margin-top:17px}.reply-form h2{margin:0 0 11px;font-size:20px}.reply-form .primary-btn{margin-top:11px}.thread-side{position:relative}.side-card{position:sticky;top:88px;display:grid;gap:4px;padding:16px}.side-card h3{margin:0 0 7px;padding:0 8px;font-size:14px}.side-card a{color:#475467;text-decoration:none;padding:8px 9px;border-radius:9px;font-size:12px;font-weight:700}.side-card a:hover{background:var(--surface-3);color:var(--brand)}.reply-card.flash{animation:flashPost 1.6s}@keyframes flashPost{0%,100%{box-shadow:var(--shadow-sm)}20%,70%{box-shadow:0 0 0 4px rgba(250,204,21,.55)}}.post-actions{margin-top:16px;display:flex;gap:8px}.rules-card,.rules-summary{margin:17px 0}.rules-summary{background:#fafbfc}.rules-summary p,.rules-card div{line-height:1.65;color:#475467}.moderation-notice{margin-top:17px;background:#fff1f3;border-color:#fecdd3;color:#9f1239;font-weight:800}.my-post-card{align-items:flex-start}.my-post-card a{display:inline-block;margin-right:12px;color:var(--brand);font-weight:800;text-decoration:none}.edit-note{font-size:12px;color:var(--muted);font-weight:700}
/* Mobile */
@media(max-width:900px){.community-grid{grid-template-columns:1fr}.community-hero{grid-template-columns:1fr;gap:18px}.thread-layout{grid-template-columns:1fr}.thread-side{order:-1}.side-card{position:static;display:flex;overflow:auto;white-space:nowrap;padding:10px}.side-card h3{display:none}.side-card a{background:var(--surface-2);flex:0 0 auto}.community-banner{align-items:flex-start;flex-wrap:wrap}.community-banner .primary-btn,.community-banner .blocked-badge{margin-left:91px}}
@media(max-width:760px){.app-shell{grid-template-columns:1fr}.sidebar{position:fixed;inset:0 14% 0 0;z-index:40;transform:translateX(-105%);transition:.22s ease;box-shadow:22px 0 50px rgba(0,0,0,.25)}.sidebar.open{transform:none}.mobile-menu{display:grid;place-items:center}.chat-status{display:none}.message{max-width:88%}.composer{padding:10px 10px calc(10px + env(safe-area-inset-bottom));grid-template-columns:auto auto minmax(0,1fr) auto}.send-button{width:42px;padding:0;font-size:0}.send-button:after{content:"➜";font-size:18px}.messages{padding:16px 13px}.community-topbar{padding:0 13px;height:62px}.community-topbar nav{gap:1px}.community-topbar nav a{padding:8px 9px;font-size:12px}.community-topbar nav a:last-child{display:none}.community-wrap,.thread-layout{width:min(100% - 22px,var(--max));padding-top:22px}.community-hero h1,.community-banner h1,.original-post h1{font-size:30px}.community-banner{padding:18px}.community-avatar.large{width:58px;height:58px;flex-basis:58px;border-radius:17px}.community-banner .primary-btn,.community-banner .blocked-badge{margin-left:0;width:100%;justify-content:center}.thread-card{align-items:flex-start;padding:15px}.vote-stat{width:54px;flex-basis:54px}.highlight-item{grid-template-columns:56px minmax(0,1fr)}.highlight-item>span{grid-column:2}.original-post,.highlights,.reply-form,.side-card,.rules-card,.rules-summary,.moderation-notice{padding:17px}.flag-btn{margin-left:0}.auth-card{padding:26px 22px;border-radius:20px}}
@media(max-width:480px){.community-topbar .brand{font-size:0}.community-topbar .brand:before{font-size:13px}.community-topbar nav a{padding:8px}.community-search button{padding:11px 13px}.composer-icon{width:38px;height:40px}.send-button{width:40px}.composer{gap:6px}.emoji-picker{left:8px;grid-template-columns:repeat(6,34px)}.message{max-width:94%}.community-card{padding:15px}.community-avatar{width:44px;height:44px;flex-basis:44px}.reply-card footer{gap:6px}}
.follow-btn{border:1px solid #cbd5e1;background:#fff;color:#334155;border-radius:999px;padding:.55rem .85rem;font-weight:700;cursor:pointer}.follow-btn.following{background:#eef2ff;border-color:#818cf8;color:#3730a3}.notification-card{display:block;background:#fff;border:1px solid #e2e8f0;border-radius:16px;padding:1rem 1.1rem;margin:.75rem 0;color:inherit;text-decoration:none}.notification-card.unread{border-left:5px solid #4f46e5;background:#f8faff}.notification-card p{margin:.4rem 0;color:#475569}.account-shell{max-width:900px;margin:0 auto;padding:2rem 1rem}.empty-state{padding:2rem;background:#fff;border:1px solid #e2e8f0;border-radius:16px;color:#64748b}
/* Link previews */
.link-preview-card{display:grid;grid-template-columns:minmax(140px,220px) minmax(0,1fr);margin:14px 0 18px;border:1px solid var(--line);border-radius:15px;overflow:hidden;background:var(--surface);color:inherit;text-decoration:none;box-shadow:var(--shadow-sm);transition:transform .18s ease,border-color .18s ease,box-shadow .18s ease}.link-preview-card:hover{transform:translateY(-2px);border-color:#b8c5ef;box-shadow:0 12px 30px rgba(16,24,40,.10)}.link-preview-card>img{width:100%;height:100%;min-height:150px;object-fit:cover;background:var(--surface-3)}.link-preview-copy{min-width:0;display:flex;flex-direction:column;justify-content:center;padding:16px 18px}.link-preview-copy small{font-size:11px;font-weight:850;letter-spacing:.08em;text-transform:uppercase;color:var(--brand);margin-bottom:5px}.link-preview-copy strong{font-size:17px;line-height:1.32;color:var(--ink);display:-webkit-box;-webkit-box-orient:vertical;-webkit-line-clamp:2;overflow:hidden}.link-preview-copy>span{font-size:13px;line-height:1.5;color:var(--muted);margin-top:7px;display:-webkit-box;-webkit-box-orient:vertical;-webkit-line-clamp:2;overflow:hidden}.link-preview-copy em{font-size:11px;font-style:normal;color:var(--subtle);margin-top:10px;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}.reply-card .link-preview-card{grid-template-columns:120px minmax(0,1fr);margin-top:0}.reply-card .link-preview-card>img{min-height:120px}.reply-card .link-preview-copy{padding:13px 15px}.reply-card .link-preview-copy strong{font-size:15px}
@media(max-width:600px){.link-preview-card,.reply-card .link-preview-card{grid-template-columns:1fr}.link-preview-card>img,.reply-card .link-preview-card>img{height:180px;min-height:0}.link-preview-copy{padding:14px 15px}.link-preview-copy strong{font-size:15px}}
/* Member profiles and post identity */
.post-author-row{display:flex;align-items:center;gap:10px;min-width:0}.post-author-row>div{display:flex;flex-direction:column;min-width:0}.post-author-row small{font-size:11px;color:var(--muted)}.post-avatar-link{display:flex;flex:0 0 auto}.post-avatar{width:40px;height:40px;border-radius:50%;object-fit:cover;border:1px solid var(--line);background:var(--surface-3)}.avatar-initial,.avatar-anonymous{display:grid;place-items:center;font-weight:900;color:var(--brand);background:var(--brand-soft)}.avatar-anonymous{color:#667085;background:#f2f4f7}.post-author-name{font-size:14px;font-weight:900;color:var(--ink);text-decoration:none;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}.post-author-name:hover{color:var(--brand);text-decoration:underline}.original-post>.post-author-row{margin-top:18px;padding-top:16px;border-top:1px solid var(--line)}.profile-shell{width:min(1100px,calc(100% - 32px));margin:0 auto;padding:32px 0 60px}.profile-hero{display:flex;align-items:center;gap:22px;background:#fff;border:1px solid var(--line);border-radius:22px;padding:26px;box-shadow:var(--shadow-sm);margin-bottom:22px}.profile-hero h1{margin:3px 0;font-size:32px}.profile-hero p{margin:0 0 14px;color:var(--muted)}.profile-avatar-xl{width:108px;height:108px;border-radius:28px;object-fit:cover;border:1px solid var(--line);background:var(--surface-3)}.profile-initial{display:grid;place-items:center;font-size:42px;font-weight:900;color:var(--brand);background:var(--brand-soft)}.profile-edit-link{display:inline-flex;text-decoration:none}.profile-columns{display:grid;grid-template-columns:1fr 1.25fr;gap:22px}.profile-panel,.profile-edit-card{background:#fff;border:1px solid var(--line);border-radius:20px;padding:22px;box-shadow:var(--shadow-sm)}.profile-panel h2{margin:3px 0 14px}.profile-group-list,.profile-thread-list{display:grid;gap:10px}.profile-group-list a,.profile-thread-list a{display:flex;flex-direction:column;gap:3px;padding:14px;border:1px solid var(--line);border-radius:13px;text-decoration:none;color:inherit;background:var(--surface-2)}.profile-group-list a:hover,.profile-thread-list a:hover{border-color:#b8c5ef;background:#fff}.profile-group-list span,.profile-thread-list small{color:var(--muted);font-size:12px}.profile-thread-list span{font-size:12px;color:var(--brand);font-weight:800;margin-top:4px}.profile-edit-shell{width:min(680px,calc(100% - 28px));margin:0 auto;padding:32px 0}.profile-edit-card h1{margin:4px 0 18px}.profile-edit-card form{display:grid;gap:16px}.profile-edit-card label{font-weight:800;font-size:13px}.profile-edit-card input{width:100%;margin-top:7px;border:1px solid var(--line);border-radius:11px;padding:11px}.profile-edit-card label small{display:block;color:var(--muted);font-weight:500;margin-top:5px}.profile-avatar-preview{width:96px;height:96px;border-radius:24px;object-fit:cover}.success-alert{padding:12px;border-radius:10px;background:#ecfdf3;color:#166534;margin-bottom:14px}@media(max-width:760px){.profile-columns{grid-template-columns:1fr}.profile-hero{align-items:flex-start;padding:19px}.profile-avatar-xl{width:76px;height:76px;border-radius:20px}.profile-hero h1{font-size:25px}.post-avatar{width:36px;height:36px}}
/* Chat and community branding */
.chat-panel{grid-template-rows:auto 72px minmax(0,1fr) auto}.chat-brand-hero{position:relative;height:clamp(150px,24vw,280px);overflow:hidden;background:linear-gradient(135deg,#182230,#344054)}.chat-brand-hero.hidden{display:none}.chat-brand-banner{width:100%;height:100%;object-fit:cover;display:block}.chat-brand-overlay{position:absolute;inset:0;background:linear-gradient(180deg,rgba(8,15,28,.08),rgba(8,15,28,.55))}.chat-brand-logo{position:absolute;left:clamp(18px,3vw,38px);bottom:18px;width:clamp(70px,9vw,104px);height:clamp(70px,9vw,104px);border-radius:22px;object-fit:cover;background:#fff;border:4px solid #fff;box-shadow:0 12px 30px rgba(0,0,0,.26)}.brand-edit{position:absolute;right:20px;top:18px;border:1px solid rgba(255,255,255,.5);background:rgba(17,24,39,.72);backdrop-filter:blur(8px);color:#fff;border-radius:10px;padding:9px 13px;font-weight:800}.icon-button.light{border:1px solid var(--line);background:#fff;color:var(--ink)}.community-cover{position:relative;height:clamp(170px,25vw,310px);border-radius:22px;overflow:hidden;margin:6px 0 0;background:linear-gradient(135deg,#172033,#394968)}.community-cover>img{width:100%;height:100%;object-fit:cover}.community-cover:after{content:"";position:absolute;inset:0;background:linear-gradient(180deg,rgba(0,0,0,.04),rgba(0,0,0,.50))}.community-cover-edit{position:absolute;z-index:2;top:16px;right:16px}.community-banner.has-cover{margin-top:-58px;position:relative;z-index:3;width:calc(100% - 34px);margin-left:auto;margin-right:auto}.community-logo-image{width:72px;height:72px;object-fit:cover;border-radius:20px;border:1px solid #d9e0fb;background:#fff}.branding-preview-note,.form-help{color:var(--muted);font-size:13px;margin-top:-4px}
@media(max-width:760px){.chat-brand-hero{height:170px}.chat-brand-logo{bottom:13px}.brand-edit{top:12px;right:12px}.community-cover{height:180px;border-radius:16px}.community-banner.has-cover{margin-top:-38px;width:calc(100% - 14px)}.community-logo-image{width:58px;height:58px;border-radius:17px}}
/* Public chat activity homepage */
.sr-only{position:absolute!important;width:1px!important;height:1px!important;padding:0!important;margin:-1px!important;overflow:hidden!important;clip:rect(0,0,0,0)!important;white-space:nowrap!important;border:0!important}
.public-home-wrap{padding-top:44px}.public-home-hero{display:grid;grid-template-columns:minmax(0,1fr) minmax(320px,520px);align-items:end;gap:42px;padding:34px;border:1px solid var(--line);border-radius:26px;background:linear-gradient(135deg,#fff 0%,#f7f9ff 60%,#eef2ff 100%);box-shadow:var(--shadow-sm);overflow:hidden;position:relative}.public-home-hero:after{content:"";position:absolute;width:260px;height:260px;border-radius:50%;right:-110px;top:-145px;background:rgba(49,87,213,.08)}.public-home-hero>div,.public-home-hero>form{position:relative;z-index:1}.public-home-hero h1{font-size:clamp(34px,5vw,58px);line-height:1;letter-spacing:-.045em;margin:7px 0 14px;max-width:680px}.public-home-hero p{margin:0;color:var(--muted);font-size:16px;max-width:660px}.public-chat-heading{display:flex;align-items:flex-end;justify-content:space-between;gap:16px;margin:34px 2px 16px}.public-chat-heading h2{font-size:24px;letter-spacing:-.025em;margin:0}.public-chat-heading p{color:var(--muted);margin:3px 0 0;font-size:13px}.sort-chip{display:inline-flex;align-items:center;gap:7px;border:1px solid var(--line);background:#fff;color:#475467;border-radius:999px;padding:8px 12px;font-size:12px;font-weight:800}.sort-chip:before{content:"↓";color:var(--brand)}.public-chat-grid{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:18px}.public-chat-card{display:block;overflow:hidden;text-decoration:none;color:inherit;background:#fff;border:1px solid var(--line);border-radius:21px;box-shadow:var(--shadow-sm);transition:transform .18s ease,border-color .18s ease,box-shadow .18s ease}.public-chat-card:hover{transform:translateY(-3px);border-color:#b8c5ef;box-shadow:0 18px 40px rgba(16,24,40,.10)}.public-chat-cover{height:148px;position:relative;overflow:hidden;background:linear-gradient(135deg,#172033,#344b73)}.public-chat-cover.no-cover:before{content:"";position:absolute;inset:0;background:radial-gradient(circle at 22% 18%,rgba(110,137,242,.48),transparent 33%),radial-gradient(circle at 82% 92%,rgba(49,87,213,.42),transparent 35%)}.public-chat-cover img{width:100%;height:100%;display:block;object-fit:cover;transition:transform .25s ease}.public-chat-card:hover .public-chat-cover img{transform:scale(1.025)}.public-chat-cover:after{content:"";position:absolute;inset:0;background:linear-gradient(180deg,rgba(7,13,24,.04),rgba(7,13,24,.44))}.activity-pill{position:absolute;right:13px;top:13px;z-index:2;color:#fff;background:rgba(17,24,39,.76);border:1px solid rgba(255,255,255,.25);backdrop-filter:blur(9px);border-radius:999px;padding:6px 10px;font-size:11px;font-weight:850}.public-chat-content{display:flex;gap:15px;padding:0 19px 20px}.public-chat-logo{width:64px;height:64px;flex:0 0 64px;border-radius:18px;object-fit:cover;background:#fff;border:4px solid #fff;box-shadow:0 7px 18px rgba(16,24,40,.16);margin-top:-28px;position:relative;z-index:3}.public-chat-initial{display:grid;place-items:center;background:linear-gradient(145deg,#eef2ff,#dce4ff);color:var(--brand);font-size:25px;font-weight:950}.public-chat-copy{min-width:0;flex:1;padding-top:14px}.public-chat-title-row{display:flex;align-items:center;gap:12px}.public-chat-title-row h3{font-size:19px;line-height:1.25;letter-spacing:-.02em;margin:0;flex:1}.public-chat-title-row>span{color:var(--brand);font-size:18px;font-weight:900;transition:transform .18s ease}.public-chat-card:hover .public-chat-title-row>span{transform:translateX(3px)}.public-chat-copy>p{color:#475467;font-size:13px;line-height:1.55;min-height:41px;margin:7px 0 13px}.public-chat-stats{display:flex;flex-wrap:wrap;gap:7px 13px;color:var(--muted);font-size:11px;font-weight:700}.public-chat-stats span{position:relative}.public-chat-stats span+span:before{content:"·";position:absolute;left:-8px;color:#c0c6d1}.public-chat-empty{grid-column:1/-1;display:grid;gap:4px}.public-chat-empty strong{color:var(--ink);font-size:17px}.public-chat-empty span{color:var(--muted)}
@media(max-width:900px){.public-home-hero{grid-template-columns:1fr;gap:22px}.public-chat-grid{grid-template-columns:1fr}}
@media(max-width:760px){.public-home-wrap{padding-top:22px}.public-home-hero{padding:24px 20px;border-radius:20px}.public-home-hero h1{font-size:37px}.public-chat-heading{align-items:center;margin-top:26px}.sort-chip{display:none}.public-chat-cover{height:126px}.public-chat-content{padding-left:15px;padding-right:15px}.public-chat-logo{width:58px;height:58px;flex-basis:58px;border-radius:16px}.home-public-page .community-topbar nav a:nth-child(3),.home-public-page .community-topbar nav a:nth-child(4){display:none}}
@media(max-width:480px){.public-home-hero{padding:22px 16px}.public-home-hero h1{font-size:33px}.public-chat-heading h2{font-size:21px}.public-chat-cover{height:112px}.public-chat-content{gap:12px}.public-chat-copy>p{min-height:0}.public-chat-stats{gap:5px 12px}}

/* Shared legal footer */
.site-footer {
  margin-top: auto;
  border-top: 1px solid rgba(148, 163, 184, .24);
  background: #0f172a;
  color: #cbd5e1;
}
.site-footer-inner {
  width: min(1180px, calc(100% - 32px));
  min-height: 76px;
  margin: 0 auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  padding: 18px 0;
  font-size: .88rem;
}
.site-footer-links,
.site-footer-brand {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 16px;
}
.site-footer a {
  color: #f8fafc;
  font-weight: 700;
  text-decoration: none;
}
.site-footer a:hover,
.site-footer a:focus-visible { text-decoration: underline; }
.footer-divider { color: #64748b; }
.auth-page { min-height: 100vh; display: flex; flex-direction: column; }
.auth-page .auth-card { flex: 0 0 auto; }
.auth-page .site-footer { width: 100%; margin-top: auto; }
.chat-panel + .site-footer { display: none; }
body:not(.auth-page) { min-height: 100vh; }

/* Legal pages */
.legal-page { background: #f4f7fb; }
.legal-wrap {
  width: min(920px, calc(100% - 32px));
  margin: 0 auto;
  padding: 54px 0 72px;
}
.legal-hero { margin-bottom: 24px; }
.legal-hero h1 { margin: 8px 0 8px; font-size: clamp(2.1rem, 5vw, 3.5rem); letter-spacing: -.04em; }
.legal-hero p { margin: 0; color: #64748b; }
.legal-card {
  border: 1px solid #e2e8f0;
  border-radius: 22px;
  background: #fff;
  box-shadow: 0 18px 55px rgba(15, 23, 42, .08);
  padding: clamp(24px, 5vw, 54px);
  color: #334155;
  line-height: 1.75;
}
.legal-card > p:first-child { font-size: 1.08rem; color: #1e293b; }
.legal-card h2 { margin: 38px 0 10px; color: #0f172a; font-size: 1.35rem; letter-spacing: -.015em; }
.legal-card h3 { margin: 23px 0 7px; color: #1e293b; font-size: 1rem; }
.legal-card p { margin: 0 0 15px; }
.legal-card ul { margin: 10px 0 20px; padding-left: 24px; }
.legal-card li { margin: 7px 0; }

@media (max-width: 700px) {
  .site-footer-inner { align-items: flex-start; flex-direction: column; gap: 13px; }
  .site-footer-brand { gap: 9px; }
  .legal-wrap { padding-top: 34px; }
  .legal-card { border-radius: 16px; }
}

.identity-grid{display:grid;grid-template-columns:repeat(auto-fit,minmax(220px,1fr));gap:16px;margin-top:24px}.identity-card{position:relative;overflow:hidden;min-height:190px;padding:72px 18px 18px;border:1px solid #dbe3ee;border-radius:18px;background:#fff;text-align:left;cursor:pointer}.identity-card.selected{outline:3px solid #2563eb;border-color:#2563eb}.identity-bg{position:absolute;inset:0 0 auto;width:100%;height:85px;object-fit:cover}.identity-thumb{position:relative;display:block;width:58px;height:58px;border-radius:15px;object-fit:cover;border:3px solid #fff;box-shadow:0 6px 18px rgba(15,23,42,.15);margin-bottom:10px}.identity-card strong,.identity-card small{position:relative;display:block}.message-sender-avatar{width:24px;height:24px;border-radius:8px;object-fit:cover;display:inline-flex;align-items:center;justify-content:center;margin-right:6px;vertical-align:middle}.message-meta{display:flex;align-items:center;gap:5px}.message-meta time{margin-left:auto}

.first-run-card{display:flex;align-items:center;justify-content:space-between;gap:24px;margin:0 0 24px;padding:24px;border:1px solid #f2c94c;border-radius:18px;background:#fff9df;box-shadow:0 10px 30px rgba(17,24,39,.08)}
.first-run-card h1{margin:.25rem 0 .4rem;font-size:clamp(1.45rem,3vw,2rem)}
.first-run-card p{margin:0;max-width:720px;color:#4b5563}
@media(max-width:720px){.first-run-card{align-items:stretch;flex-direction:column}.first-run-card .primary-btn{text-align:center}}

/* Nested discussion branches */
.threaded-posts{display:block}.thread-node{position:relative;margin:0 0 11px}.thread-children{position:relative;margin:11px 0 0 26px;padding-left:22px}.thread-children:before{content:"";position:absolute;left:0;top:-11px;bottom:20px;width:2px;background:#d9e0ea;border-radius:2px}.thread-children>.thread-node{position:relative}.thread-children>.thread-node:before{content:"";position:absolute;left:-22px;top:27px;width:18px;height:16px;border-left:2px solid #d9e0ea;border-bottom:2px solid #d9e0ea;border-bottom-left-radius:11px;pointer-events:none}.thread-children>.thread-node:last-child:after{content:"";position:absolute;left:-22px;top:45px;bottom:-12px;width:4px;background:var(--bg,#f6f8fb);pointer-events:none}.replying-to{margin:11px 0 -4px;padding:7px 10px;border-left:3px solid #c7d2fe;background:#f7f8ff;border-radius:0 8px 8px 0;color:#667085;font-size:12px}.replying-to a{font-weight:800;color:var(--brand);text-decoration:none}.reply-context{display:flex;align-items:center;justify-content:space-between;gap:12px;margin:0 0 11px;padding:10px 12px;background:#f5f7ff;border:1px solid #d9e0ff;border-left:4px solid var(--brand);border-radius:10px}.reply-context[hidden]{display:none}.reply-context>div{min-width:0;display:grid;gap:2px}.reply-context strong{font-size:13px}.reply-context [data-reply-excerpt]{white-space:nowrap;overflow:hidden;text-overflow:ellipsis;color:#667085;font-size:12px}.reply-context button{flex:0 0 auto;width:30px;height:30px;border:0;border-radius:8px;background:#e8ecf8;color:#475467;font-size:20px;line-height:1;cursor:pointer}.reply-context button:hover{background:#dce3f5}.thread-depth-4 .thread-children{margin-left:0;padding-left:18px}.thread-depth-4 .thread-children>.thread-node:before{left:-18px;width:14px}
@media(max-width:700px){.thread-children{margin-left:10px;padding-left:14px}.thread-children:before{left:0}.thread-children>.thread-node:before{left:-14px;width:11px;height:13px;top:25px}.thread-children>.thread-node:last-child:after{left:-14px;top:40px}.thread-node .reply-card{padding:14px}.replying-to{font-size:11px}.thread-depth-3 .thread-children,.thread-depth-4 .thread-children{margin-left:0;padding-left:12px}.thread-depth-3 .thread-children>.thread-node:before,.thread-depth-4 .thread-children>.thread-node:before{left:-12px;width:9px}}

/* v19 inline editing, reporting, and restricted rich-text formatting */
.formatted-large{font-size:1.5em;line-height:1.35}.formatted-small{font-size:.8em;line-height:1.45}.format-editor{position:relative}.format-editor textarea{width:100%;resize:vertical}.format-toolbar{display:flex;align-items:center;gap:6px;margin:8px 0 0;padding:7px;border:1px solid var(--line);border-radius:10px;background:#fff;opacity:.62;transition:opacity .16s ease,box-shadow .16s ease}.format-toolbar.selection-active{opacity:1;box-shadow:var(--shadow-sm)}.format-toolbar button{min-width:38px;height:34px;border:1px solid var(--line);border-radius:8px;background:var(--surface-2);color:var(--ink);font-weight:800;cursor:pointer}.format-toolbar button:hover{background:#fff;border-color:#aebbe9}.format-help{display:block;margin-top:6px;color:var(--muted);font-size:12px}.inline-edit-panel{display:grid;gap:10px;margin:12px 0;padding:14px;border:1px solid #b9c5ee;border-radius:14px;background:#f8faff}.inline-edit-panel label{display:grid;gap:6px;font-size:12px;font-weight:800}.inline-edit-panel input,.inline-edit-panel textarea{width:100%;border:1px solid var(--line);border-radius:10px;padding:10px;background:#fff;font:inherit}.inline-edit-actions{display:flex;justify-content:flex-end;gap:8px}.editing-hidden{display:none}.flag-popover{position:absolute;z-index:1000;width:min(320px,calc(100vw - 24px));padding:14px;border:1px solid var(--line);border-radius:14px;background:#fff;box-shadow:0 18px 55px rgba(16,24,40,.20)}.flag-popover.hidden{display:none}.flag-popover form{display:grid;gap:10px}.flag-popover strong{font-size:15px}.flag-popover p{margin:0;color:var(--muted);font-size:12px}.flag-popover label{display:grid;gap:6px;font-size:12px;font-weight:800}.flag-popover select{width:100%;border:1px solid var(--line);border-radius:9px;padding:10px;background:#fff}.flag-popover form>div{display:flex;justify-content:flex-end;gap:8px}.danger-btn{border:0;border-radius:9px;padding:9px 12px;background:#b42318;color:#fff;font-weight:800;cursor:pointer}.flag-btn.flagged{opacity:.6;pointer-events:none}.secondary-btn{border:1px solid var(--line);border-radius:9px;padding:9px 12px;background:#fff;color:var(--ink);font-weight:800;cursor:pointer}
@media(max-width:640px){.format-toolbar{overflow-x:auto}.inline-edit-actions{flex-direction:column-reverse}.inline-edit-actions button{width:100%}.flag-popover{position:fixed!important;left:12px!important;right:12px!important;bottom:12px!important;top:auto!important;width:auto}}
/* v20 community images and sharing */
.content-image-link{display:block;margin:14px 0;text-decoration:none}.content-image{display:block;width:auto;max-width:100%;max-height:720px;border-radius:14px;border:1px solid var(--line);object-fit:contain;background:#f5f7fa}.share-btn{border:1px solid var(--line);background:var(--surface-2);border-radius:9px;padding:7px 10px;font-weight:800;font-size:12px;color:#475467}.share-btn:hover{background:var(--surface-3)}.image-upload-row{display:grid;gap:6px;margin-top:12px;font-weight:800;color:#344054}.image-upload-row input[type=file]{border:1px dashed #cbd5e1;border-radius:12px;padding:11px;background:#fff}.image-upload-row small{font-weight:500;color:var(--muted)}

/* v21 post enhancements and external-link confirmation */
.enhancement-bar{display:flex;align-items:center;gap:8px;flex-wrap:wrap;margin:12px 0 0;padding-top:10px;border-top:1px solid var(--line)}
.enhancement-bar>span{font-size:12px;font-weight:800;color:var(--muted);text-transform:uppercase;letter-spacing:.06em}
.enhancement-button{display:inline-flex;align-items:center;gap:7px;border:1px solid var(--line);border-radius:10px;padding:8px 11px;background:var(--surface-2);color:var(--ink);font-weight:800}
.enhancement-button:hover,.enhancement-button[aria-expanded="true"]{background:var(--brand-soft);border-color:#aebbe9;color:var(--brand-strong)}
.enhancement-icon{font-size:18px;line-height:1}
.image-drop-panel{margin-top:10px}.image-drop-panel[hidden]{display:none}
.image-drop-zone{position:relative;display:grid;place-items:center;gap:5px;min-height:145px;padding:22px;border:2px dashed #b8c2d6;border-radius:14px;background:#fafbff;text-align:center;cursor:pointer;transition:border-color .15s ease,background .15s ease,transform .15s ease}
.image-drop-zone:hover,.image-drop-zone.drag-over{border-color:var(--brand);background:var(--brand-soft);transform:translateY(-1px)}
.image-drop-zone input[type=file]{position:absolute;inset:0;width:100%;height:100%;opacity:0;cursor:pointer}
.image-drop-zone strong{font-size:15px}.image-drop-zone span,.image-drop-zone small{color:var(--muted);font-weight:500}.image-file-status{margin-top:7px;color:var(--success);font-size:13px;font-weight:800}
.external-link-modal{position:fixed;inset:0;z-index:3000;display:grid;place-items:center;padding:20px;background:rgba(15,23,42,.72);backdrop-filter:blur(4px)}
.external-link-modal.hidden{display:none}.external-link-dialog{position:relative;width:min(620px,100%);padding:30px;border-radius:22px;background:#fff;box-shadow:0 30px 90px rgba(0,0,0,.3)}
.external-link-dialog h2{margin:6px 0 8px;font-size:clamp(1.55rem,4vw,2.2rem)}.external-link-dialog p{margin:0 0 20px;color:var(--muted)}
.external-link-close{position:absolute;right:14px;top:12px;width:38px;height:38px;border:0;border-radius:50%;background:#eef2f7;color:#344054;font-size:25px;line-height:1}
.external-url-label{font-size:12px;font-weight:900;text-transform:uppercase;letter-spacing:.05em;color:#475467}.external-url-value{margin:8px 0 20px;padding:14px;border:1px solid #d7deea;border-radius:12px;background:#f8fafc;overflow-wrap:anywhere;color:#172033;font-family:ui-monospace,SFMono-Regular,Consolas,monospace;font-size:13px}
.external-link-continue{display:block;padding:15px 18px;border-radius:12px;background:var(--brand);color:#fff;text-align:center;text-decoration:none;font-weight:900;font-size:16px}.external-link-continue:hover{background:var(--brand-strong);color:#fff}
.external-link-cancel{display:block;width:100%;margin-top:10px;padding:11px;border:0;background:transparent;color:var(--muted);font-weight:800}
@media(max-width:640px){.external-link-dialog{padding:24px 18px;border-radius:18px}.image-drop-zone{min-height:125px;padding:17px}}


/* v22 production stability: prevent narrow-screen overflow and keep account controls reachable. */
html,body{max-width:100%;overflow-x:hidden}
.community-page{min-width:0}
.community-topbar{height:auto;min-height:68px;gap:14px;padding-top:10px;padding-bottom:10px}
.community-topbar .brand{flex:0 1 auto;min-width:0;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}
.community-topbar nav{min-width:0;display:flex;align-items:center;justify-content:flex-end;flex-wrap:wrap;gap:4px}
.community-topbar nav a{white-space:nowrap}
.thread-layout,.community-wrap,.public-home-wrap{min-width:0;max-width:100%}
.thread-main,.thread-side,.original-post,.reply-card,.reply-form{min-width:0}
.post-actions,.reply-card footer{flex-wrap:wrap}
.image-file-status.error{color:var(--danger);font-weight:800}
.image-drop-zone{touch-action:manipulation}
.image-drop-zone input[type=file]{font-size:16px}
.logout-link{border:1px solid rgba(255,255,255,.22)!important;background:rgba(255,255,255,.08);border-radius:9px}
@media(max-width:760px){
  .community-topbar{align-items:flex-start;padding-left:14px;padding-right:14px}
  .community-topbar nav{gap:3px;max-width:72%;justify-content:flex-end}
  .community-topbar nav a{padding:7px 8px;font-size:12px}
  .thread-layout{display:block!important;width:100%!important;padding-left:12px!important;padding-right:12px!important}
  .thread-side{display:none!important}
  .original-post,.reply-card,.reply-form,.highlights,.rules-card{width:100%;max-width:100%;overflow:hidden}
  .post-actions button,.reply-card footer button{min-height:38px}
  .content-image{width:100%;height:auto;max-height:none}
}
@media(max-width:480px){
  .community-topbar{display:grid;grid-template-columns:minmax(0,1fr) auto}
  .community-topbar nav{max-width:none}
  .community-topbar nav a:not(.logout-link):nth-child(n+4){display:none}
}

/* v23 community administration */
.community-admin-link{white-space:nowrap}.admin-wrap{max-width:1180px}.admin-heading{display:flex;align-items:flex-end;justify-content:space-between;gap:20px;margin:8px 0 22px}.admin-heading h1{font-size:clamp(30px,4vw,44px);margin:5px 0 8px}.admin-heading p{margin:0;color:var(--muted)}.admin-grid{display:grid;grid-template-columns:minmax(0,1fr) minmax(0,1.25fr);gap:18px;margin-bottom:18px}.admin-card{background:#fff;border:1px solid var(--line);border-radius:18px;padding:20px;box-shadow:var(--shadow-sm)}.admin-card-head{display:flex;align-items:flex-start;justify-content:space-between;gap:14px;margin-bottom:16px}.admin-card h2{margin:0 0 5px;font-size:20px}.admin-card p{margin:0;color:var(--muted);font-size:14px}.brand-admin-preview{height:210px;border-radius:15px;overflow:hidden;position:relative;background:#eef2f6;margin-bottom:15px}.brand-admin-banner{width:100%;height:100%;object-fit:cover;display:block}.brand-admin-banner.empty{background:linear-gradient(135deg,#172033,#52627d)}.brand-admin-logo{position:absolute;left:18px;bottom:16px;width:72px;height:72px;border:4px solid #fff;border-radius:20px;object-fit:cover;background:#fff;box-shadow:0 8px 24px rgba(0,0,0,.22)}.brand-admin-logo.fallback{display:grid;place-items:center;font-size:26px;font-weight:900;color:var(--brand)}.member-row{display:flex;align-items:center;justify-content:space-between;gap:14px;padding:13px 0;border-top:1px solid var(--line)}.member-row:first-of-type{border-top:0}.member-identity{display:flex;align-items:center;gap:11px;min-width:0}.member-identity img,.member-identity>span{width:44px;height:44px;border-radius:13px;object-fit:cover;display:grid;place-items:center;background:#eef2ff;color:var(--brand);font-weight:900;flex:0 0 auto}.member-identity strong,.member-identity small{display:block}.member-identity small{color:var(--muted);margin-top:2px}.member-actions form,.member-action-stack,.role-form{display:flex;gap:7px;align-items:center;flex-wrap:wrap}.small{padding:7px 10px!important;font-size:12px!important}.danger{color:#b42318!important;border-color:#f3b8b2!important;background:#fff!important}.empty-inline{padding:18px;border:1px dashed var(--line);border-radius:12px;color:var(--muted);text-align:center}.notice{padding:12px 15px;border-radius:12px;margin:0 0 16px;font-weight:700}.notice.success{background:#ecfdf3;color:#067647;border:1px solid #abefc6}.notice.error{background:#fef3f2;color:#b42318;border:1px solid #fecdca}.member-table-wrap{overflow:auto}.member-table{width:100%;border-collapse:collapse;min-width:850px}.member-table th,.member-table td{text-align:left;padding:12px 10px;border-top:1px solid var(--line);vertical-align:middle}.member-table th{font-size:12px;color:var(--muted);text-transform:uppercase;letter-spacing:.05em}.member-identity.compact img,.member-identity.compact>span{width:38px;height:38px;border-radius:11px}.role-pill,.status-pill{display:inline-flex;align-items:center;border-radius:999px;padding:6px 10px;background:#eef2f6;color:#344054;font-size:12px;font-weight:800;text-transform:capitalize}.status-pending{background:#fffaeb;color:#b54708}.status-approved{background:#ecfdf3;color:#067647}.status-blocked{background:#fef3f2;color:#b42318}.blocked-note{display:block;color:#b42318;margin-top:4px}.role-form select{width:auto;min-width:110px;padding:7px 9px}.member-action-stack{min-width:190px}
@media(max-width:850px){.admin-grid{grid-template-columns:1fr}.admin-heading{align-items:flex-start;flex-direction:column}.member-row{align-items:flex-start;flex-direction:column}.member-actions{width:100%}.member-actions form{width:100%}.member-actions button{flex:1}.brand-admin-preview{height:170px}}

.math-check{border:0;padding:0;margin:1rem 0}.math-check legend{font-weight:700;margin-bottom:.65rem}.math-answer-buttons{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:.65rem}.math-answer-button{min-height:48px;font-size:1rem;font-weight:800}.success{padding:12px 14px;border-radius:10px;background:#e9f8ef;color:#176b3a;margin:1rem 0}@media(max-width:480px){.math-answer-buttons{gap:.45rem}.math-answer-button{min-height:52px}}

/* v27 discussion-card media */
.thread-card-image{width:96px;height:76px;flex:0 0 96px;object-fit:cover;border-radius:13px;border:1px solid var(--line);background:var(--surface-2)}
.thread-card.has-image{align-items:center}
@media(max-width:760px){.thread-card-image{width:82px;height:70px;flex-basis:82px}.thread-card.has-image{align-items:flex-start}}
@media(max-width:440px){.thread-card.has-image{display:grid;grid-template-columns:74px minmax(0,1fr);gap:12px}.thread-card-image{width:74px;height:68px;flex-basis:auto}.thread-card.has-image .grow{min-width:0}}
