:root{--bg:#0e0e0e;--bg2:#111;--surface:rgba(255,255,255,.06);--surface2:rgba(255,255,255,.1);--line:rgba(255,255,255,.08);--line2:rgba(255,255,255,.16);--text:#f7f7f3;--muted:rgba(247,247,243,.64);--soft:rgba(247,247,243,.3);--accent:#fff;--accentText:#111;--danger:#ff6b6b;--ok:#79d69c;--shadow:0 24px 80px rgba(0,0,0,.28);--r1:36px;--r2:24px;--r3:18px;--r4:14px;--header-surface:rgba(10,10,10,.78);--site-header-height:78px;--glass-bg:#1b1b1b;--input-autofill-bg:#2a2a2a;--page-bg-bak:radial-gradient(circle at 15% 18%, rgba(255,255,255,.08), transparent 18%),radial-gradient(circle at 85% 20%, rgba(255,255,255,.04), transparent 18%),linear-gradient(180deg,#090909,#111 48%,#151515)}
*{box-sizing:border-box}html,body{margin:0;padding:0}html{min-height:100%;background:var(--page-bg);background-color:var(--bg);color-scheme:dark;overscroll-behavior:none;scrollbar-gutter:stable;scroll-padding-top:calc(var(--site-header-height) + 12px)}body{font-family:Inter,system-ui,sans-serif;background:var(--page-bg);background-color:var(--bg);color:var(--text);min-height:100vh;min-height:100svh;min-height:100dvh;display:flex;flex-direction:column;position:relative;overflow-x:clip;overscroll-behavior:none;padding-top:var(--site-header-height)}
a{text-decoration:none;color:inherit}button,input,textarea,select{font:inherit}input,textarea,select{width:100%;background:rgba(255,255,255,.07);border:1px solid var(--line);color:var(--text);padding:14px 16px;border-radius:18px;outline:none;transition:border-color .25s ease,background-color .25s ease,color .25s ease,box-shadow .25s ease,transform .25s ease}input:focus,textarea:focus,select:focus{border-color:var(--line2);transform:translateY(-1px)}input:-webkit-autofill,input:-webkit-autofill:hover,input:-webkit-autofill:focus,textarea:-webkit-autofill,textarea:-webkit-autofill:hover,textarea:-webkit-autofill:focus,select:-webkit-autofill,select:-webkit-autofill:hover,select:-webkit-autofill:focus{-webkit-text-fill-color:var(--text)!important;caret-color:var(--text)!important;background-color:var(--input-autofill-bg)!important;background-image:none!important;-webkit-box-shadow:0 0 0 1000px var(--input-autofill-bg) inset!important;box-shadow:0 0 0 1000px var(--input-autofill-bg) inset!important;transition:background-color 9999s ease-out,color 9999s ease-out}textarea{min-height:108px;resize:vertical}.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}
.shell{width:min(1240px,calc(100% - 28px));margin:0 auto;position:relative;z-index:1}.site-header{width:100%;padding:18px 0;position:fixed;top:0;left:0;right:0;z-index:70;background:transparent;flex:0 0 auto;isolation:isolate}.site-header::before{content:"";position:absolute;inset:0;z-index:-1;background:var(--header-surface);-webkit-backdrop-filter:blur(18px);backdrop-filter:blur(18px);pointer-events:none}.site-header-inner{display:grid;grid-template-columns:auto minmax(0,1fr);align-items:center;gap:16px}.site-header-left{display:flex;align-items:center;gap:12px;min-width:0}
.brand{display:flex;align-items:center;gap:12px}.brand:hover .brand-name{opacity:1}.brand-mark{width:42px;height:42px;border-radius:14px;display:grid;place-items:center;background:var(--surface2);border:1px solid var(--line)}.brand-logo-wrap{padding:7px}.brand-logo{width:28px;height:28px;max-width:28px;max-height:28px;object-fit:contain;display:block;flex:0 0 28px}.brand-name{display:inline-block;font-weight:700;font-size:18px;line-height:1;letter-spacing:.01em;color:var(--text);opacity:.96;transition:opacity .2s ease}.language-switcher{position:relative;z-index:5;flex:0 0 auto}.language-switcher summary{display:inline-flex;align-items:center;justify-content:center;min-width:46px;height:40px;padding:0 12px;border:1px solid var(--line);border-radius:999px;background:var(--surface);color:var(--text);font-size:12px;font-weight:700;line-height:1;list-style:none;cursor:pointer}.language-switcher summary::-webkit-details-marker{display:none}.language-switcher[open] summary,.language-switcher summary:hover{background:var(--surface2);border-color:var(--line2)}.language-switcher-menu{position:absolute;left:0;top:calc(100% + 8px);display:grid;gap:4px;min-width:76px;padding:6px;border:1px solid var(--line2);border-radius:16px;background:rgba(10,10,10,.94);box-shadow:0 18px 50px rgba(0,0,0,.28)}.language-switcher-menu form{margin:0}.language-switcher-menu button{width:100%;min-height:34px;padding:0 10px;border:0;border-radius:12px;background:transparent;color:var(--muted);cursor:pointer;text-align:left;font-size:12px;font-weight:700}.language-switcher-menu button:hover,.language-switcher-menu button.active{background:var(--surface2);color:var(--text)}
.site-nav{display:flex;gap:10px;flex-wrap:wrap;align-items:center;justify-content:flex-end;min-width:0}.site-nav a{padding:10px 14px;border-radius:999px;border:1px solid transparent;color:var(--muted);position:relative}.site-nav a:hover{background:var(--surface);color:var(--text)}.site-nav a.auth-nav-link{transition:background-color .2s ease,border-color .2s ease,color .2s ease}.site-nav a.auth-nav-link.is-active{background:var(--accent);color:var(--accentText);border-color:transparent}.site-nav a.auth-nav-link.is-active:hover{background:var(--accent);color:var(--accentText)}.nav-logout-form{margin:0;display:flex}.nav-logout-form .btn{font:inherit}.nav-badge{display:inline-grid;place-items:center;min-width:20px;height:20px;padding:0 6px;border-radius:999px;background:#fff;color:#111;font-size:11px;margin-left:6px}.nav-badge[hidden]{display:none}
.page{padding:18px 0 42px;flex:1 1 auto;min-height:0}.glass{background:var(--glass-bg);border:1px solid var(--line);border-radius:var(--r1)}.hero{padding:30px;display:grid;grid-template-columns:1.15fr .85fr;gap:18px}
.eyebrow{font-size:12px;letter-spacing:.12em;text-transform:uppercase;color:var(--muted);margin-bottom: 10px;}h1,h2,h3,p{margin:0}.hero h1,.panel h1{font-size:clamp(34px,5vw,64px);line-height:.95;letter-spacing:-.05em;margin:8px 0 16px}.lead{color:var(--muted);font-size:18px;line-height:1.6}.small{font-size:14px;color:var(--muted);line-height:1.6}.grid2,.grid3,.dash{display:grid;gap:18px}.grid2{grid-template-columns:repeat(2,minmax(0,1fr))}.grid3{grid-template-columns:repeat(3,minmax(0,1fr))}.dash{grid-template-columns:320px 1fr}.stack{display:grid;gap:18px;grid-template-columns:minmax(0,1fr)}.panel{padding:24px}.stat{padding:20px;min-height:140px;display:flex;flex-direction:column;justify-content:space-between}.stat span{color:var(--muted);font-size:14px}.stat strong{font-size:28px;letter-spacing:-.04em}
.row,.chips,.actions,.toolbar,.profile-head,.conv-line,.gallery-strip,.gallery-grid,.voice-tools,.inline-form{display:flex;gap:12px;flex-wrap:wrap;align-items:center;}.profile-head{align-items:flex-start}.profile-head.compact{flex-wrap:nowrap}
.avatar-xl,.avatar-md,.avatar-sm{display:block;flex:0 0 auto;flex-shrink:0;aspect-ratio:1/1;object-fit:cover;border-radius:22px;background:var(--surface2)}.avatar-xl{width:192px;height:192px;min-width:96px;min-height:96px;max-width:192px;max-height:192px}.avatar-md{width:56px;height:56px;min-width:56px;min-height:56px;max-width:56px;max-height:56px;border-radius:18px}.avatar-sm{width:42px;height:42px;min-width:42px;min-height:42px;max-width:42px;max-height:42px;border-radius:14px}
.gallery-strip img,.gallery-grid img{width:72px;height:72px;object-fit:cover;border-radius:18px;border:1px solid var(--line)}.gallery-strip{margin-top:16px}.gallery-grid{margin-top:18px}.gallery-grid img{width:120px;height:120px}
.btn{display:inline-flex;align-items:center;justify-content:center;gap:10px;padding:14px 18px;border-radius:999px;border:1px solid var(--line);background:var(--surface);color:var(--text);cursor:pointer;transition:.25s;position:relative}.btn:hover{transform:translateY(-1px);background:var(--surface2)}.btn.primary{background:var(--accent);color:var(--accentText);border-color:transparent}.btn.small{padding:10px 14px;font-size:14px}.btn.danger{background:rgba(255,107,107,.16);color:#ffdada}
.btn.is-loading{pointer-events:none;opacity:.86}.btn.is-loading::after{content:"";width:16px;height:16px;border-radius:50%;border:2px solid currentColor;border-right-color:transparent;animation:spin .8s linear infinite}
.flash{padding:14px 18px;border-radius:18px;margin-bottom:18px;border:1px solid var(--line)}.flash-success{background:rgba(121,214,156,.12)}.flash-error{background:rgba(255,107,107,.12)}.flash-info{background:rgba(255,255,255,.08)}
.form-card{width:min(920px,100%);padding:28px;margin:0 auto}.auth{display:grid;place-items:center;min-height:72vh}.label{display:block;margin:14px 0;color:var(--muted);font-size:14px}.section-card{padding:18px;border-radius:24px;border:1px solid var(--line);background:rgba(255,255,255,.03)}.section-head{display:flex;justify-content:space-between;gap:12px;align-items:center;cursor:pointer}.section-body{display:none;padding-top:14px}.section-card.open .section-body{display:block;animation:fade .25s ease}
.email-verification-actions{display:flex;align-items:center;justify-content:space-between;gap:12px;margin-top:14px}.email-verification-actions form{margin:0}.email-verification-actions .btn{white-space:nowrap}
.chips input{display:none}.chip{padding:10px 14px;border-radius:999px;border:1px solid var(--line);background:var(--surface);color:var(--muted);cursor:pointer;transition:.25s}.chips input:checked + .chip,.chip.active{background:var(--accent);color:var(--accentText);border-color:transparent}.helper{margin:6px;font-size:12px;color:var(--soft)}
.searchbar{display:grid;grid-template-columns:minmax(0,1fr) auto auto;gap:12px}.results{display:grid;gap:16px;grid-template-columns:minmax(0,1fr)}.match{padding:22px;transition:.25s}.match:hover{transform:translateY(-2px)}.match-top{display:flex;justify-content:space-between;gap:16px;align-items:flex-start}.pill{padding:10px 12px;border-radius:999px;background:var(--accent);color:var(--accentText);font-size:13px}.tag{display:inline-flex;padding:10px 12px;border-radius:999px;background:var(--surface);color:var(--text);font-size:13px}.explain{margin-top:14px;color:var(--muted);line-height:1.6}
.profile-box{padding:24px}.meta-list{display:grid;gap:12px;margin-top:14px;grid-template-columns:minmax(0,1fr)}.meta{padding:12px 14px;border-radius:18px;background:rgba(255,255,255,.03);border:1px solid var(--line)}
.chat-layout{display:grid;grid-template-columns:340px 1fr;gap:18px}.conv-list{display:grid;gap:12px;align-content:start;grid-auto-rows:max-content;grid-template-columns:minmax(0,1fr)}.conv-item{padding:16px;border-radius:22px;background:rgba(255,255,255,.03);transition:.25s;display:flex;justify-content:space-between;align-items:center;min-width:0}.conv-item:hover,.conv-item.active{background:rgba(255,255,255,.08)}
.messages{display:grid;gap:12px;max-height:560px;overflow:auto;padding-right:6px;margin-top:18px}.msg{width:fit-content;max-width:min(78%,620px);padding:14px 16px;border-radius:20px;line-height:1.5;background:rgba(255,255,255,.05);animation:rise .25s ease;display:grid;gap:6px}.msg.me{margin-left:auto;background:rgba(255,255,255,.12)}.msg.flagged{border-color:rgba(255,107,107,.35)}.composer{display:grid;grid-template-columns:1fr auto;gap:12px;margin-top:16px}
.chat-shell{grid-template-columns:minmax(280px,320px) minmax(0,1fr);align-items:stretch}.chat-shell>*{min-width:0}.chat-sidebar,.chat-main{padding:16px}.chat-pane-head{display:flex;align-items:flex-start;justify-content:space-between;gap:12px;padding-bottom:10px;border-bottom:1px solid var(--line)}.chat-pane-title{margin-top:4px;font-size:20px;line-height:1.1;letter-spacing:-.03em;font-weight:700}.chat-count{display:inline-grid;place-items:center;min-width:32px;height:32px;padding:0 10px;border-radius:999px;background:var(--surface);border:1px solid var(--line);font-size:13px;color:var(--muted)}.chat-conv-list{gap:10px}.chat-sidebar .conv-item{padding:12px 14px;border-radius:18px}.conv-line{width:100%;min-width:0;align-items:center;flex-wrap:nowrap}.conv-copy{display:grid;gap:4px;min-width:0;flex:1 1 auto}.conv-topline{display:flex;align-items:center;gap:10px;min-width:0}.conv-topline strong{min-width:0;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.conv-preview{display:block;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}.conv-preview-rich{display:block;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}.conv-preview-emoji{display:inline-block;width:1.05em;height:1.05em;margin:0 .08em;vertical-align:-.18em;object-fit:contain;user-select:none;-webkit-user-select:none}.conv-badge{margin-left:auto}.chat-main{position:relative;display:flex;flex-direction:column;gap:12px;min-height:0}.chat-main-head{display:flex;justify-content:space-between;gap:14px;align-items:flex-start;padding-bottom:12px;border-bottom:1px solid var(--line)}.chat-peer{min-width:0}.chat-peer-copy{display:grid;gap:4px;min-width:0}.chat-peer-name{font-size:22px;line-height:1.05;letter-spacing:-.03em;font-weight:700}.chat-actions{justify-content:flex-end}.chat-actions .btn{padding:8px 12px}.chat-messages{padding:2px 6px 2px 0;margin-top:0;scrollbar-width:thin;align-content:start}.msg-author{display:block;font-size:13px;color:var(--muted)}.msg-body{overflow-wrap:anywhere}.msg-body audio,.voice-preview{display:block;width:min(320px,100%);max-width:100%}.chat-tools{display:grid;gap:10px;padding-top:12px;border-top:1px solid var(--line);flex:0 0 auto}.chat-composer{margin-top:0;grid-template-columns:minmax(0,1fr) auto;align-items:end}.chat-composer textarea{min-height:56px;max-height:140px;padding:12px 14px;line-height:1.45;overflow:auto;resize:none}.chat-secondary-tools{display:flex;justify-content:space-between;align-items:center;gap:10px;flex-wrap:wrap}.chat-upload-form,.chat-voice-form{gap:10px}.chat-voice-tools{margin-top:0;gap:10px;flex:1 1 auto}.chat-record-status{margin-top:0;min-width:0}.chat-empty{display:grid;place-content:center;justify-items:start;gap:8px;min-height:100%;padding:10px 0;flex:1 1 auto}.chat-empty-title{font-size:clamp(26px,4vw,38px);line-height:1.02;letter-spacing:-.04em;font-weight:700}
.mutual{padding:12px 14px;border-radius:18px;background:rgba(121,214,156,.12);border:1px solid rgba(121,214,156,.18);color:#d9ffe5}.hint{padding:12px 14px;border-radius:18px;background:rgba(255,255,255,.05);border:1px solid var(--line);color:var(--muted)}.anim-in{animation:rise .45s ease both}
@keyframes rise{from{opacity:0;transform:translateY(10px)}to{opacity:1;transform:none}}@keyframes fade{from{opacity:0}to{opacity:1}}@keyframes spin{to{transform:rotate(360deg)}}@keyframes profilePhotoIn{from{opacity:0;transform:translateY(18px) scale(.985)}to{opacity:1;transform:none}}@keyframes profileViewerIn{from{opacity:0;transform:translateY(16px) scale(.98)}to{opacity:1;transform:none}}@keyframes profileViewerOut{from{opacity:1;transform:none}to{opacity:0;transform:translateY(12px) scale(.985)}}@keyframes profileBackdropOut{from{opacity:1}to{opacity:0}}@keyframes profileMenuIn{from{opacity:0;transform:translateY(-4px) scale(.98)}to{opacity:1;transform:none}}@keyframes profileTagReveal{from{opacity:0;transform:translateY(6px) scale(.985)}to{opacity:1;transform:none}}@keyframes profileTagConceal{from{opacity:1;transform:none}to{opacity:0;transform:translateY(4px) scale(.985)}}@keyframes profileTagPanelReveal{from{opacity:0;transform:translateY(-4px) scaleY(.985)}to{opacity:1;transform:none}}@keyframes profileTagPanelConceal{from{opacity:1;transform:none}to{opacity:0;transform:translateY(-4px) scaleY(.985)}}
body.chat-screen{height:100vh;height:100svh;height:100dvh;overflow:hidden}
body.chat-screen .page.chat-page{display:flex;flex-direction:column;min-height:0;overflow:hidden;padding:clamp(10px,1.6vh,18px) 0}
body.chat-screen .page.chat-page>.flash{flex:0 0 auto;margin-bottom:0}
body.chat-screen .chat-shell{flex:1 1 auto;min-height:0;gap:14px;align-items:stretch}
body.chat-screen .chat-shell>.panel{min-height:0;overflow:hidden}
body.chat-screen .chat-shell>aside.panel{display:flex;flex-direction:column}
body.chat-screen .chat-shell>aside.panel .conv-list{flex:1 1 auto;min-height:0;overflow:auto;padding-right:4px}
body.chat-screen .chat-shell>section.panel{display:flex;flex-direction:column;min-height:0}
body.chat-screen .chat-shell>section.panel .messages{flex:1 1 auto;min-height:0;max-height:none}
body.chat-screen .chat-shell>section.panel .composer,body.chat-screen .chat-shell>section.panel .inline-form,body.chat-screen .chat-shell>section.panel .voice-tools{flex:0 0 auto}
body.chat-screen .chat-shell>section.panel .composer textarea{min-height:56px;max-height:140px;overflow:auto;resize:none}
@-moz-document url-prefix(){
body.chat-screen{height:100vh!important;min-height:0!important;overflow:hidden!important}
body.chat-screen .page.chat-page{display:flex!important;flex-direction:column!important;width:min(1240px,calc(100% - 28px))!important;max-width:1240px!important;height:calc(100vh - var(--site-header-height))!important;max-height:calc(100vh - var(--site-header-height))!important;min-height:0!important;margin:0 auto!important;overflow:hidden!important}
body.chat-screen .chat-shell{display:grid!important;grid-template-columns:300px minmax(0,1fr)!important;grid-template-rows:minmax(0,1fr)!important;width:100%!important;height:100%!important;max-height:100%!important;min-height:0!important;overflow:visible!important}
body.chat-screen .chat-shell>*{min-width:0!important;min-height:0!important}
body.chat-screen .chat-shell>.panel{height:100%!important;max-height:100%!important;min-width:0!important;min-height:0!important;overflow:hidden!important}
body.chat-screen .chat-shell>aside.panel,body.chat-screen .chat-shell>section.panel{display:flex!important;flex-direction:column!important}
body.chat-screen .chat-shell>aside.panel .conv-list{flex:1 1 0!important;min-width:0!important;min-height:0!important;overflow:auto!important;overscroll-behavior:contain!important}
body.chat-screen .chat-main{min-width:0!important;min-height:0!important;overflow:hidden!important}
body.chat-screen .chat-main-head{flex:0 0 auto!important;min-width:0!important}
body.chat-screen .chat-messages{flex:1 1 0!important;width:100%!important;height:auto!important;max-height:none!important;min-width:0!important;min-height:0!important;overflow-x:hidden!important;overflow-y:auto!important;overscroll-behavior:contain!important}
body.chat-screen .chat-tools{flex:0 0 auto!important;min-width:0!important;min-height:0!important}
body.chat-screen .chat-composer,body.chat-screen .chat-composer-anchor,body.chat-screen .chat-composer-bar,body.chat-screen .chat-compose-editor{min-width:0!important;min-height:0!important}
@media(max-width:1024px){body.chat-screen .chat-shell{grid-template-columns:minmax(0,1fr)!important;grid-template-rows:minmax(170px,28vh) minmax(0,1fr)!important}}
@media(max-width:760px){body.chat-screen .page.chat-page{width:calc(100% - 16px)!important}body.chat-screen.has-js .chat-shell{grid-template-columns:minmax(0,1fr)!important;grid-template-rows:minmax(0,1fr)!important}}
}
@media(max-width:1024px){.dash,.chat-layout,.searchbar{grid-template-columns:1fr}.grid3,.grid2{grid-template-columns:1fr}body.chat-screen .chat-shell{grid-template-columns:1fr;grid-template-rows:minmax(170px,28svh) minmax(0,1fr)}.chat-main-head{flex-direction:column;align-items:stretch}.chat-actions{justify-content:flex-start}.chat-secondary-tools{align-items:flex-start;flex-direction:column}.chat-voice-tools{width:100%}}
@media(max-width:760px){.shell{width:calc(100% - 18px)}.site-header{position:fixed;top:0;left:0;right:0;z-index:70}.site-header-inner{grid-template-columns:minmax(0,1fr) auto;justify-items:stretch}.site-nav{justify-content:flex-end}.panel,.form-card,.profile-box{padding:20px}.msg{max-width:88%}body.chat-screen .page.chat-page{padding:10px 0}.chat-sidebar,.chat-main{padding:14px}.chat-peer-name{font-size:20px}body.chat-screen .chat-shell{gap:12px;grid-template-rows:minmax(148px,24svh) minmax(0,1fr)}body.chat-screen .chat-shell>section.panel .composer{grid-template-columns:minmax(0,1fr)}.chat-actions{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));width:100%}.chat-actions .btn,.chat-upload-form .btn,.chat-voice-form .btn,.chat-voice-tools>.btn{width:100%}.chat-secondary-tools,.chat-upload-form,.chat-voice-form,.chat-voice-tools{display:grid;grid-template-columns:minmax(0,1fr)}.chat-record-status{margin-top:2px}}
.selectable-row{display:flex;justify-content:space-between;gap:16px;align-items:center;padding:14px 16px;border-radius:18px;border:1px solid var(--line);background:rgba(255,255,255,.03)}.selectable-row input[type="checkbox"]{width:20px;height:20px}
.hint-online{display:inline-flex;align-items:center;gap:8px;font-size:13px;color:var(--muted);line-height:1.1;vertical-align:middle}.hint-online>span{display:block;line-height:1.1}.hint-online::before{content:"";width:8px;height:8px;border-radius:50%;background:var(--soft);flex:0 0 auto;align-self:center}.hint-online.online::before{background:var(--ok);box-shadow:0 0 0 2px rgba(121,214,156,.08)}
.chat-peer-status-row .hint-online{transition:color .18s ease,opacity .18s ease,transform .18s ease}
.chat-peer-status-row .hint-online.is-activity{color:var(--text);animation:chatPresenceTextIn .2s ease both}
.chat-peer-status-row .hint-online.is-activity::before{animation:chatPresencePulse 1.15s ease-in-out infinite}
@keyframes chatPresenceTextIn{from{opacity:.45;transform:translateY(2px)}to{opacity:1;transform:none}}
@keyframes chatPresencePulse{0%,100%{transform:scale(.82);box-shadow:0 0 0 2px rgba(121,214,156,.08)}50%{transform:scale(1);box-shadow:0 0 0 5px rgba(121,214,156,.12)}}
.photo-card{padding:14px;border-radius:22px;border:1px solid var(--line);background:rgba(255,255,255,.04)}.photo-card img{width:100%;height:160px;object-fit:cover;border-radius:18px;border:1px solid var(--line)}
.toast{position:fixed;right:18px;bottom:18px;z-index:50;background:rgba(17,17,17,.94);color:#fff;padding:14px 16px;border-radius:18px;opacity:0;transform:translateY(10px);transition:.3s;box-shadow:0 16px 40px rgba(0,0,0,.25)}.toast.show{opacity:1;transform:translateY(0)}
.tag-picker{position:relative}.tag-suggestions{display:none;position:absolute;left:0;right:0;top:calc(100% + 8px);z-index:15;background:#161616;border:1px solid var(--line2);border-radius:18px;box-shadow:var(--shadow);max-height:240px;overflow:auto}.tag-suggestions.open{display:block}.tag-option{padding:12px 14px;border-bottom:1px solid var(--line);cursor:pointer}.tag-option:last-child{border-bottom:0}.tag-option:hover{background:rgba(255,255,255,.08)}
.voice-tools{margin-top:12px}.typing-live{color:var(--muted);min-height:18px}.voice-preview{width:100%}

:root{--r1:28px;--r2:18px;--r3:14px;--r4:12px}.panel,.form-card,.profile-box,.match{padding:clamp(24px, 5vw, 46px)}.site-nav a{padding:8px 12px}.btn{padding:10px 14px}.btn.small{padding:8px 12px}.chip,.tag{padding:7px 10px;font-size:12px}.searchbar{grid-template-columns:minmax(0,1fr) auto}.searchbar .btn.primary{display:none}.messages{max-height:480px}.msg{padding:10px 12px;border-radius:16px}.conv-item{padding:12px 14px;border-radius:18px}.photo-card{padding:10px}.photo-card img{height:132px}.gallery-grid{gap:12px}.section-card{padding:14px}.helper{font-size:11px}.chat-image{border-radius:14px;border:1px solid var(--line)}.chat-file{display:inline-flex;align-items:center;gap:8px;padding:10px 12px;border-radius:12px;background:var(--surface);border:1px solid var(--line)}.tag-group{margin-top:14px}.tag-group h4{margin:0 0 8px;font-size:13px;color:var(--muted);text-transform:uppercase;letter-spacing:.08em}.tag-grid{display:flex;flex-wrap:wrap;gap:8px}.tag-weight{font-size:11px;color:var(--soft);margin-left:6px}.split-tag-section{display:grid;gap:14px;grid-template-columns:minmax(0,1fr)}.compact-meta{display:flex;flex-wrap:wrap;gap:8px 14px;font-size:13px;color:var(--muted)}
.dashboard-page,.dashboard-main,.dashboard-sidebar,.profile-shell{display:grid;gap:16px}.dashboard-page{grid-template-columns:minmax(0,1fr) 320px;align-items:start}.profile-hero{display:grid;gap:18px}.profile-hero-head{display:grid;gap:18px}.profile-hero-identity{gap:16px;align-items:flex-start;flex-wrap:nowrap;min-width:0}.profile-hero-avatar{width:192px;height:192px;border-radius:28px;flex:0 0 auto}.profile-hero-copy{display:grid;gap:10px;min-width:0;flex:1 1 auto}.profile-title-row{display:flex;align-items:flex-start;justify-content:space-between;gap:12px;flex-wrap:wrap}.profile-title{font-size:clamp(32px,4.4vw,52px);line-height:.96;letter-spacing:-.05em}.profile-hero-summary{max-width:68ch}.profile-hero-meta{display:flex;flex-wrap:wrap;gap:10px 14px;align-items:center}.profile-presence{display:grid;gap:6px;align-content:start}.profile-last-seen{font-size:13px;line-height:1.4;color:var(--muted)}.profile-inline-link{display:inline-flex;align-items:center;justify-content:center;padding:9px 12px;border-radius:999px;border:1px solid var(--line);background:rgba(255,255,255,.04);font-size:13px;color:var(--text);transition:.2s}.profile-inline-link:hover{background:rgba(255,255,255,.08)}.profile-metrics{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:10px}.profile-metric{display:grid;gap:6px;min-width:0;padding:14px 16px;border-radius:20px;border:1px solid var(--line);background:rgba(255,255,255,.03)}.profile-metric span{font-size:13px;color:var(--muted)}.profile-metric strong{font-size:28px;line-height:1;letter-spacing:-.04em}.profile-actions{gap:10px}.profile-actions form{display:flex}.profile-section{display:grid;gap:16px}.section-heading{display:flex;align-items:flex-end;justify-content:space-between;gap:12px;flex-wrap:wrap}.section-heading.is-compact{align-items:flex-start}.section-heading h2{margin-top:6px;font-size:clamp(24px,3vw,34px);line-height:1;letter-spacing:-.04em}.profile-upload-form{display:grid;gap:10px;align-content:start}.profile-upload-input{padding:12px 14px;background:rgba(255,255,255,.04)}.profile-upload-actions{justify-content:flex-start;align-items:center}.profile-gallery-manage-grid{align-items:start}.profile-gallery-add-card{min-width:0}.profile-gallery-add-tile{position:relative;display:grid;place-items:center;width:100%;padding:0;border:1px dashed var(--line2);border-radius:24px;aspect-ratio:4/5;background:linear-gradient(180deg,rgba(255,255,255,.05),rgba(255,255,255,.02));cursor:pointer;overflow:hidden;transition:border-color .2s ease,background .2s ease,box-shadow .2s ease}.profile-gallery-add-tile:hover{background:linear-gradient(180deg,rgba(255,255,255,.07),rgba(255,255,255,.03))}.profile-gallery-add-card.is-dragover .profile-gallery-add-tile{border-color:rgba(247,247,243,.46);background:linear-gradient(180deg,rgba(255,255,255,.1),rgba(255,255,255,.04));box-shadow:0 0 0 1px rgba(255,255,255,.08),0 22px 48px rgba(0,0,0,.18)}.profile-gallery-add-card.is-dragover .profile-gallery-add-icon{background:rgba(255,255,255,.14)}.profile-gallery-add-placeholder{display:grid;justify-items:center;gap:8px;padding:18px;text-align:center}.profile-gallery-add-placeholder[hidden]{display:none}.profile-gallery-add-icon{display:inline-flex;align-items:center;justify-content:center;width:44px;height:44px;border-radius:16px;border:1px solid var(--line);background:rgba(255,255,255,.07);font-size:28px;line-height:1;color:var(--text)}.profile-gallery-add-placeholder strong{font-size:17px;line-height:1.1}.profile-gallery-add-placeholder span:last-child{max-width:16ch;font-size:13px;line-height:1.45;color:var(--muted)}.profile-gallery-add-preview{position:absolute;inset:0;display:block}.profile-gallery-add-preview[hidden]{display:none}.profile-gallery-add-preview img{display:block;width:100%;height:100%;object-fit:cover}.profile-gallery-add-preview::after{content:"";position:absolute;inset:0;background:linear-gradient(180deg,rgba(0,0,0,.04),rgba(0,0,0,.34))}.profile-gallery-add-count{position:absolute;right:12px;top:12px;z-index:1;display:inline-flex;align-items:center;justify-content:center;min-width:34px;height:34px;padding:0 10px;border-radius:999px;background:rgba(17,17,17,.88);color:#fff;font-size:12px;font-weight:600}.profile-gallery-add-count[hidden]{display:none}.profile-gallery-add-card .profile-upload-actions{display:grid;grid-template-columns:minmax(0,1fr)}.profile-gallery-add-card .profile-upload-actions[hidden]{display:none}.profile-gallery-add-card .profile-upload-actions .btn{width:100%}.photo-grid{display:grid;grid-template-columns:repeat(auto-fill,minmax(176px,1fr));gap:12px}.photo-card{display:grid;gap:10px;margin:0;padding:10px;border-radius:24px;border:1px solid var(--line);background:rgba(255,255,255,.04);align-content:start}.photo-card.is-primary{background:rgba(255,255,255,.07);border-color:var(--line2)}.photo-card-static{padding:0;border:0;background:transparent}.photo-card-media{position:relative;aspect-ratio:4/5;border-radius:18px;overflow:hidden;border:1px solid var(--line);background:rgba(0,0,0,.16)}.photo-card-media img{display:block;width:100%;height:100%;object-fit:cover}.photo-badge{position:absolute;left:10px;top:10px;display:inline-flex;align-items:center;padding:7px 10px;border-radius:999px;background:rgba(17,17,17,.86);font-size:11px;letter-spacing:.04em;text-transform:uppercase;color:#fff}.photo-card-actions{gap:8px}.photo-card-actions .btn{flex:1 1 auto}.empty-panel{display:grid;gap:10px;padding:18px;border-radius:22px;border:1px dashed var(--line2);background:rgba(255,255,255,.03)}.empty-panel strong{font-size:16px;line-height:1.25}.tag-cluster-grid{display:grid;grid-template-columns:repeat(auto-fit,minmax(220px,1fr));gap:12px}.tag-cluster{display:grid;gap:12px;padding:16px;border-radius:22px;border:1px solid var(--line);background:rgba(255,255,255,.03)}.tag-cluster-head{display:flex;align-items:flex-start;gap:12px}.tag-cluster h3{font-size:16px;line-height:1.2;letter-spacing:-.02em}.tag-cluster-group{display:grid;gap:8px}.tag-cluster-group+.tag-cluster-group{padding-top:10px;border-top:1px solid var(--line)}.profile-meta-list{display:flex;flex-wrap:wrap;gap:10px}.profile-meta-pill{display:inline-grid;gap:2px;min-width:min(180px,100%);padding:10px 12px;border-radius:16px;border:1px solid var(--line);background:rgba(255,255,255,.03)}.profile-meta-pill strong{font-size:11px;letter-spacing:.08em;text-transform:uppercase;color:var(--muted)}.profile-meta-pill span{font-size:14px;line-height:1.4;color:var(--text);overflow-wrap:anywhere}.profile-note{margin-top:0}.profile-content-grid{display:grid;grid-template-columns:minmax(0,1.05fr) minmax(280px,.95fr);gap:16px;align-items:start}.profile-content-grid.is-single{grid-template-columns:minmax(0,1fr)}.public-photo-grid{grid-template-columns:repeat(auto-fill,minmax(148px,1fr))}.profile-chat-list{gap:10px}
.profile-tag-section{gap:0}
.profile-tag-card{
  --tag-tilt-x:0deg;
  --tag-tilt-y:0deg;
  position:relative;
  overflow:hidden;
  padding:18px;
  border-radius:28px;
  border:1px solid var(--line2);
  background:linear-gradient(180deg, rgba(255,255,255,.06), rgba(255,255,255,.03));
  box-shadow:0 18px 48px rgba(0,0,0,.18);
  transform:perspective(1400px) rotateX(var(--tag-tilt-x)) rotateY(var(--tag-tilt-y));
  transform-style:flat;
  content-visibility:visible;
  contain:none;
  transition:height .28s cubic-bezier(.2,.72,.2,1),transform .28s ease,box-shadow .28s ease,border-color .28s ease,background .28s ease;
}
.profile-tag-card::after{
  content:"";
  position:absolute;
  pointer-events:none;
}
.profile-tag-card::after{
  inset:0;
  border-radius:inherit;
  border:1px solid rgba(255,255,255,.04);
  background:linear-gradient(135deg,rgba(255,255,255,.03),transparent 48%);
}
.profile-tag-card.is-expanded{border-color:var(--line2)}
.profile-tag-card-head{
  position:relative;
  z-index:1;
  display:flex;
  align-items:center;
  justify-content:space-between;
  gap:12px;
}
.profile-tag-card-title-wrap{min-width:0}
.profile-tag-card-title{
  font-size:clamp(22px,2.8vw,28px);
  line-height:1;
  letter-spacing:-.05em;
}
.profile-tag-card-actions{
  display:flex;
  align-items:center;
  justify-content:flex-end;
  gap:8px;
  flex-wrap:wrap;
}
.profile-tag-edit-button{
  display:inline-flex;
  align-items:center;
  justify-content:center;
  gap:8px;
  min-height:40px;
  padding:0 14px;
  border:1px solid var(--line);
  border-radius:999px;
  background:rgba(255,255,255,.04);
  color:var(--muted);
  cursor:pointer;
  transition:background .2s ease, border-color .2s ease, color .2s ease;
}
.profile-tag-edit-button:hover,
.profile-tag-edit-button:focus-visible{
  background:rgba(255,255,255,.08);
  border-color:var(--line2);
  color:var(--text);
  outline:none;
}
.profile-tag-edit-button-icon{
  display:inline-flex;
  align-items:center;
  justify-content:center;
  width:22px;
  height:22px;
  border-radius:999px;
  border:1px solid var(--line);
  background:rgba(255,255,255,.05);
  font-size:14px;
  line-height:1;
  transition:transform .18s ease;
}
.profile-tag-card-toggle{
  position:relative;
  z-index:1;
  display:inline-flex;
  align-items:center;
  justify-content:center;
  gap:10px;
  min-height:40px;
  padding:0 14px;
  border:1px solid var(--line);
  border-radius:999px;
  background:rgba(255,255,255,.04);
  color:var(--muted);
  cursor:pointer;
  white-space:nowrap;
  transition:background .2s ease, border-color .2s ease, box-shadow .2s ease;
  -webkit-tap-highlight-color:transparent;
}
.profile-tag-card-toggle:hover,
.profile-tag-card-toggle:focus-visible{
  background:rgba(255,255,255,.08);
  border-color:var(--line2);
  color:var(--text);
  box-shadow:none;
  outline:none;
}
.profile-tag-card-toggle-count{
  display:inline-flex;
  align-items:center;
  justify-content:center;
  min-width:30px;
  height:30px;
  padding:0 8px;
  border-radius:999px;
  background:rgba(255,255,255,.07);
  color:var(--text);
  font-size:12px;
  font-weight:600;
}
.profile-tag-card.is-expanded .profile-tag-card-toggle-count{display:none}
.profile-tag-card-grid{
  position:relative;
  z-index:1;
  display:grid;
  grid-template-columns:repeat(auto-fit, minmax(220px,1fr));
  gap:10px;
  margin-top:16px;
  transform-origin:top;
  transition:height .24s cubic-bezier(.2,.7,.2,1);
}
.profile-tag-card.is-expanding .profile-tag-card-grid{
  animation:profileTagPanelReveal .24s cubic-bezier(.2,.7,.2,1) both;
}
.profile-tag-card.is-collapsing .profile-tag-card-grid{
  animation:profileTagPanelConceal .18s ease both;
  overflow:hidden;
}
.profile-tag-lane{
  position:relative;
  display:grid;
  gap:10px;
  min-width:0;
  padding:14px;
  border-radius:22px;
  border:1px solid var(--line);
  background:rgba(255,255,255,.03);
  box-shadow:none;
  transition:border-color .25s ease, background .25s ease, box-shadow .25s ease;
  align-content: start;
}
.profile-tag-lane::before{
  content:"";
  position:absolute;
  inset:0;
  border-radius:inherit;
  background:linear-gradient(180deg, rgba(255,255,255,.04), transparent 38%);
  opacity:.9;
  pointer-events:none;
}
.profile-tag-lane:hover{
  border-color:var(--line2);
  background:rgba(255,255,255,.045);
  box-shadow:none;
}
.profile-tag-lane-head{
  position:relative;
  z-index:1;
  display:flex;
  align-items:center;
  justify-content:space-between;
  gap:10px;
}
.profile-tag-lane-label{
  min-width:0;
  font-size:11px;
  font-weight:600;
  line-height:1.25;
  letter-spacing:.08em;
  text-transform:uppercase;
  color:var(--muted);
}
.profile-tag-lane-count{
  flex:0 0 auto;
  display:inline-flex;
  align-items:center;
  justify-content:center;
  min-width:30px;
  height:30px;
  padding:0 8px;
  border-radius:999px;
  border:1px solid var(--line);
  background:rgba(255,255,255,.04);
  font-size:12px;
  color:var(--muted);
}
.profile-tag-cloud{
  position:relative;
  z-index:1;
  display:flex;
  flex-wrap:wrap;
  gap:6px;
  align-items:flex-start;
}
.profile-tag-category-list{
  position:relative;
  z-index:1;
  display:grid;
  gap:9px;
}
.profile-tag-category{
  display:grid;
  gap:8px;
  min-width:0;
  padding:9px 0 0;
  border-top:1px solid rgba(255,255,255,.075);
  transform-origin:top;
}
.profile-tag-category:first-child{
  padding-top:0;
  border-top:0;
}
.profile-tag-category-header{
  display:grid;
  grid-template-columns:minmax(0,1fr) auto auto;
  align-items:center;
  gap:8px;
  width:100%;
  min-height:32px;
  padding:0;
  border:0;
  background:transparent;
  color:inherit;
  text-align:left;
  cursor:pointer;
  -webkit-tap-highlight-color:transparent;
}
.profile-tag-category-header:focus-visible{
  outline:none;
}
.profile-tag-category-title{
  min-width:0;
  font-size:13px;
  font-weight:650;
  line-height:1.25;
  color:var(--text);
  overflow-wrap:anywhere;
}
.profile-tag-category-count{
  flex:0 0 auto;
  display:inline-flex;
  align-items:center;
  justify-content:center;
  min-width:26px;
  height:26px;
  padding:0 7px;
  border-radius:999px;
  border:1px solid var(--line);
  background:rgba(255,255,255,.045);
  color:var(--muted);
  font-size:11px;
  font-weight:600;
  line-height:1;
}
.profile-tag-category-chevron{
  position:relative;
  flex:0 0 auto;
  display:inline-flex;
  align-items:center;
  justify-content:center;
  width:26px;
  height:26px;
  border-radius:999px;
  border:1px solid var(--line);
  background:rgba(255,255,255,.035);
  color:var(--muted);
  transition:background .18s ease,border-color .18s ease,color .18s ease,transform .18s ease;
}
.profile-tag-category-chevron::before{
  content:"";
  width:7px;
  height:7px;
  border-right:1.5px solid currentColor;
  border-bottom:1.5px solid currentColor;
  transform:translateY(-1px) rotate(45deg);
}
.profile-tag-category-header:hover .profile-tag-category-count,
.profile-tag-category-header:focus-visible .profile-tag-category-count,
.profile-tag-category-header:hover .profile-tag-category-chevron,
.profile-tag-category-header:focus-visible .profile-tag-category-chevron{
  border-color:var(--line2);
  background:rgba(255,255,255,.07);
  color:var(--text);
}
.profile-tag-category-body{
  display:block;
  min-width:0;
  overflow:visible;
  transition:none;
}
.profile-tag-category.is-collapsed .profile-tag-category-body{
  display:none;
}
.profile-tag-category.is-collapsed{
  gap:0;
}
.profile-tag-category-body>.profile-tag-category-tags{min-width:0}
.profile-tag-category.is-collapsed .profile-tag-category-chevron{
  transform:rotate(-90deg);
}
.profile-tag-card.is-collapsible .profile-tag-category.is-collapsed-hidden{
  display:none;
}
.profile-tag-card.is-expanded .profile-tag-category.is-collapsed-hidden{
  display:grid;
  animation:profileTagReveal .24s ease both;
}
.profile-tag-card.is-collapsing .profile-tag-category.is-collapsed-hidden{
  display:grid;
  animation:profileTagConceal .16s ease both;
}
.profile-tag-pill{
  display:inline-flex;
  align-items:center;
  justify-content:center;
  min-height:32px;
  max-width:100%;
  padding:7px 11px;
  border-radius:999px;
  border:1px solid var(--line);
  background:rgba(255,255,255,.045);
  color:var(--text);
  font-size:12px;
  line-height:1.2;
  text-align:center;
  overflow-wrap:anywhere;
  user-select:none;
  -webkit-user-select:none;
  cursor:default;
  transition:background .2s ease, border-color .2s ease, box-shadow .2s ease, color .2s ease;
}
.profile-tag-pill.is-featured{
  background:rgba(255,255,255,.07);
  border-color:var(--line2);
  font-weight:600;
}
.profile-tag-pill:hover{
  background:rgba(255,255,255,.08);
  border-color:var(--line2);
  box-shadow:none;
}
.profile-tag-card.is-collapsible .profile-tag-pill.is-collapsed-hidden{display:none}
.profile-tag-card.is-expanded .profile-tag-pill.is-collapsed-hidden{
  display:inline-flex;
  animation:profileTagReveal .24s ease both;
}
.profile-tag-card.is-collapsing .profile-tag-pill.is-collapsed-hidden{
  display:inline-flex;
  animation:profileTagConceal .16s ease both;
}
.profile-tag-card.is-expanding .profile-tag-pill,
.profile-tag-category.is-opening .profile-tag-pill{
  animation:profileTagReveal .24s ease both;
}
.profile-tag-category.is-closing .profile-tag-pill{
  animation:profileTagConceal .16s ease both;
}
.profile-tag-empty-view{padding:14px;border:1px dashed var(--line);border-radius:18px;color:var(--muted);font-size:13px;line-height:1.45}
.profile-tag-card.is-editing{overflow:visible}
.profile-tag-card.is-editing .profile-tag-card-grid,
.profile-tag-card.is-editing .profile-tag-card-toggle{display:none}
.profile-tag-card.is-editing .profile-tag-edit-button{border-color:var(--line2);background:rgba(255,255,255,.09);color:var(--text)}
.profile-tag-card.is-editing .profile-tag-edit-button-icon{transform:rotate(45deg)}
.profile-tag-inline-editor{position:relative;z-index:4;display:grid;gap:14px;margin-top:16px;padding-top:16px;border-top:1px solid var(--line);transform-origin:top}
.profile-tag-inline-editor[hidden]{display:none!important}
.profile-tag-editor-intro{display:grid;gap:12px;padding:14px;border-radius:20px;border:1px solid var(--line);background:rgba(255,255,255,.035)}
.profile-tag-editor-intro>div{display:grid;gap:5px}
.profile-tag-editor-intro strong{font-size:15px;line-height:1.25}
.profile-tag-editor-intro p{color:var(--muted);font-size:12px;line-height:1.5}
.profile-tag-ai-balance{display:flex;align-items:center;justify-content:center;gap:5px;width:max-content;max-width:100%;min-height:32px;padding:6px 10px;border-radius:999px;border:1px solid rgba(121,214,156,.22);background:rgba(121,214,156,.09);color:#d9ffe5;font-size:11px;line-height:1.25}
.profile-tag-ai-balance strong{font-size:12px}
.profile-tag-ai-balance.is-empty{border-color:var(--line);background:rgba(255,255,255,.045);color:var(--muted)}
.profile-tag-editor-grid{display:grid;gap:12px}
.profile-tag-editor-container{display:grid;gap:8px}
.profile-tag-editor-container+.profile-tag-editor-container{padding-top:12px;border-top:1px solid var(--line)}
.profile-tag-editor-container-head{display:flex;align-items:center;justify-content:space-between;gap:10px;padding:0 2px}
.profile-tag-editor-container-head h3{font-size:15px;line-height:1.2;letter-spacing:-.02em}
.profile-tag-editor-container-head span{color:var(--muted);font-size:11px}
.profile-tag-editor-categories{display:grid;gap:7px}
.profile-tag-editor-category{position:relative;border:1px solid var(--line);border-radius:17px;background:rgba(255,255,255,.025);transition:border-color .18s ease,background-color .18s ease}
.profile-tag-editor-category.is-open{z-index:8;border-color:var(--line2);background:rgba(255,255,255,.045)}
.profile-tag-editor-category-toggle{display:flex;align-items:center;justify-content:space-between;gap:10px;width:100%;min-height:44px;padding:9px 11px;border:0;background:transparent;color:var(--text);text-align:left;cursor:pointer}
.profile-tag-editor-category-toggle>span:first-child{min-width:0;font-size:13px;font-weight:650;line-height:1.3;overflow-wrap:anywhere}
.profile-tag-editor-category-meta{display:flex;align-items:center;gap:7px;flex:0 0 auto}
.profile-tag-editor-category-meta strong{display:grid;place-items:center;min-width:26px;height:26px;padding:0 7px;border-radius:999px;background:rgba(255,255,255,.06);color:var(--muted);font-size:11px}
.profile-tag-editor-category-meta i{width:7px;height:7px;border-right:1.5px solid currentColor;border-bottom:1.5px solid currentColor;color:var(--muted);transform:translate(-2px,-2px) rotate(45deg);transition:transform .18s ease}
.profile-tag-editor-category.is-open .profile-tag-editor-category-meta i{transform:translate(-2px,2px) rotate(225deg)}
.profile-tag-editor-category-body{display:grid;gap:10px;padding:0 10px 11px;transform-origin:top}
.profile-tag-editor-category-body[hidden]{display:none!important}
.profile-tag-editor-selected{display:flex;flex-wrap:wrap;gap:6px;min-width:0}
.profile-tag-editor-selected-empty{color:var(--muted);font-size:11px;line-height:1.4}
.profile-tag-editor-selected-empty[hidden]{display:none}
.profile-tag-editor-pill{display:inline-flex;align-items:center;gap:6px;max-width:100%;min-height:30px;padding:5px 5px 5px 10px;border:1px solid rgba(121,214,156,.24);border-radius:999px;background:rgba(121,214,156,.1);color:#d9ffe5;font-size:11px;line-height:1.25;transform-origin:center;transition:background-color .16s ease,border-color .16s ease,color .16s ease,opacity .16s ease,transform .16s ease}
.profile-tag-editor-pill[hidden]{display:none!important}
.profile-tag-editor-pill>input{display:none}
.profile-tag-editor-pill>span{min-width:0;overflow-wrap:anywhere}
.profile-tag-editor-pill>button{display:grid;place-items:center;width:22px;height:22px;flex:0 0 auto;padding:0 0 2px;border:0;border-radius:999px;background:rgba(0,0,0,.15);color:currentColor;cursor:pointer;line-height:1}
.profile-tag-editor-pill.is-draft{border-style:dashed;border-color:rgba(255,255,255,.22);background:rgba(255,255,255,.055);color:var(--text)}
.profile-tag-editor-pill.is-draft small{padding:3px 5px;border-radius:999px;background:rgba(255,255,255,.08);color:var(--muted);font-size:9px;white-space:nowrap}
.profile-tag-editor-search{position:relative;z-index:5}
.profile-tag-editor-search input{min-height:42px;padding:10px 13px;border-radius:14px;font-size:12px}
.profile-tag-editor-suggestions{position:absolute;left:0;right:0;top:calc(100% + 6px);z-index:20;display:grid;max-height:230px;overflow:auto;padding:5px;border:1px solid var(--line2);border-radius:16px;background:rgba(18,18,18,.98);box-shadow:0 18px 50px rgba(0,0,0,.35)}
.profile-tag-editor-suggestions[hidden]{display:none!important}
.profile-tag-editor-option{display:flex;align-items:center;justify-content:space-between;gap:10px;width:100%;min-height:38px;padding:8px 10px;border:0;border-radius:11px;background:transparent;color:var(--text);text-align:left;cursor:pointer}
.profile-tag-editor-option:hover,.profile-tag-editor-option:focus-visible{background:rgba(255,255,255,.08);outline:none}
.profile-tag-editor-option:disabled{cursor:default;color:var(--muted)}
.profile-tag-editor-option>span{min-width:0;overflow-wrap:anywhere}
.profile-tag-editor-option small{flex:0 0 auto;color:var(--muted);font-size:10px}
.profile-tag-editor-no-results{padding:9px 10px;color:var(--muted);font-size:11px;line-height:1.4}
.profile-tag-create-row{display:grid;gap:7px}
.profile-tag-create-row[hidden]{display:none!important}
.profile-tag-create-parent{display:grid;gap:5px;color:var(--muted);font-size:10px}
.profile-tag-create-parent select{min-height:38px;padding:8px 11px;border-radius:13px;font-size:11px}
.profile-tag-create-button{display:flex;align-items:center;justify-content:space-between;gap:10px;min-height:38px;padding:8px 10px;border:1px dashed var(--line2);border-radius:13px;background:rgba(255,255,255,.035);color:var(--text);cursor:pointer;text-align:left}
.profile-tag-create-button:hover,.profile-tag-create-button:focus-visible{background:rgba(255,255,255,.07);outline:none}
.profile-tag-create-button:disabled{opacity:.48;cursor:not-allowed}
.profile-tag-create-button small{padding:3px 6px;border-radius:999px;background:rgba(255,255,255,.08);color:var(--muted);font-size:9px}
.profile-tag-editor-category-hint{color:var(--muted);font-size:10px;line-height:1.4}
.profile-tag-editor-footer{display:grid;gap:10px;padding-top:2px}
.profile-tag-editor-status{min-height:18px;color:var(--muted);font-size:11px;line-height:1.45}
.profile-tag-editor-status.is-error{color:#ffdada}
.profile-tag-editor-footer-actions{display:flex;justify-content:flex-end;gap:8px;flex-wrap:wrap}
.profile-tag-editor-footer-actions .btn{min-height:40px;padding:9px 13px;font-size:12px}
.profile-tag-editor-footer-actions .btn:disabled{opacity:.45;cursor:not-allowed;transform:none}
.profile-hero-photo{
  position:relative;
  display:inline-flex;
  flex:0 0 auto;
  padding:0;
  border:0;
  border-radius:28px;
  overflow:hidden;
  background:transparent;
  cursor:pointer;
}
.profile-hero-photo::after{
  content:"";
  position:absolute;
  inset:0;
  border-radius:inherit;
  background:rgba(0,0,0,.14);
  opacity:0;
  transition:opacity .2s ease;
  pointer-events:none;
}
.profile-hero-photo:hover::after,
.profile-hero-photo:focus-visible::after{opacity:1}
.profile-hero-photo:focus-visible{outline:none}
.profile-hero-photo:focus-visible .profile-hero-avatar{box-shadow:0 0 0 3px rgba(255,255,255,.16)}
.profile-hero-summary{position:relative;max-height:7.2em;overflow:auto;white-space:pre-wrap;overflow-wrap:anywhere;scrollbar-width:none;-ms-overflow-style:none}
.profile-hero-summary::-webkit-scrollbar{display:none;width:0;height:0}
.profile-hero-summary.is-overflowing{-webkit-mask-image:linear-gradient(to bottom,#000 0,#000 calc(100% - 28px),transparent 100%);mask-image:linear-gradient(to bottom,#000 0,#000 calc(100% - 28px),transparent 100%)}
.profile-bio-editor{display:block;max-width:68ch;margin-top:2px}.profile-bio-editor textarea{display:block;width:100%;height:4.5em;min-height:4.5em;max-height:4.5em;margin:0;padding:0;border:0;border-radius:0;background:transparent;box-shadow:none;resize:none;overflow:auto;scrollbar-width:none;-ms-overflow-style:none;white-space:pre-wrap;overflow-wrap:anywhere;line-height:1.5;color:var(--muted);mask-image:linear-gradient(to bottom,#000 0,#000 calc(100% - 22px),transparent 100%);-webkit-mask-image:linear-gradient(to bottom,#000 0,#000 calc(100% - 22px),transparent 100%);transition:color .2s ease}.profile-bio-editor textarea::-webkit-scrollbar{display:none;width:0;height:0}.profile-bio-editor textarea:focus{transform:none;border-color:transparent;color:var(--text)}.profile-bio-editor textarea::placeholder{color:var(--muted);opacity:1}.profile-meta-save{display:inline-flex;align-items:center;justify-content:center;align-self:stretch;min-width:100px;padding:10px 14px;border:1px solid var(--line);border-radius:16px;background:rgba(255,255,255,.1);color:var(--text);font:inherit;font-size:13px;font-weight:600;opacity:0;visibility:hidden;pointer-events:none;transform:translateY(4px);transition:opacity .18s ease,transform .18s ease,visibility 0s linear .18s}.profile-meta-save.is-visible{opacity:1;visibility:visible;pointer-events:auto;transform:none;transition-delay:0s}
.profile-section-title{font-size:clamp(22px,2.5vw,30px);line-height:1;letter-spacing:-.035em}
.profile-hero-avatar-upload::after{background:linear-gradient(180deg,transparent 38%,rgba(0,0,0,.55));opacity:1}
.profile-avatar-upload-hint{position:absolute;right:8px;bottom:8px;z-index:1;display:grid;place-items:center;width:30px;height:30px;border-radius:11px;background:rgba(17,17,17,.88);color:#fff;font-size:22px;line-height:1;transition:transform .2s ease}
.profile-hero-avatar-upload:hover .profile-avatar-upload-hint{transform:scale(1.08)}
.profile-cropper{position:fixed;inset:0;z-index:110;display:grid;place-items:center;padding:18px;overflow:auto}
.profile-cropper[hidden]{display:none}
.profile-cropper-backdrop{position:absolute;inset:0;background:rgba(7,7,7,.72);backdrop-filter:blur(10px)}
.profile-cropper-dialog{position:relative;z-index:1;display:grid;gap:14px;width:min(560px,100%);padding:18px;border:1px solid var(--line2);border-radius:28px;background:rgba(12,12,12,.98);box-shadow:0 30px 90px rgba(0,0,0,.45)}
.profile-cropper-head{display:flex;align-items:flex-start;justify-content:space-between;gap:12px}
.profile-cropper-head h2{margin:0}
.profile-cropper-stage{position:relative;width:min(420px,100%);aspect-ratio:4/5;margin:auto;overflow:hidden;border:1px solid var(--line2);border-radius:22px;background:#090909;cursor:grab;touch-action:none;user-select:none}
.profile-cropper-stage.is-avatar{width:min(420px,100%);aspect-ratio:1;border-radius:28px}
.profile-cropper-stage:active{cursor:grabbing}
.profile-cropper-stage img{position:absolute;left:0;top:0;max-width:none;max-height:none;pointer-events:none;transform-origin:0 0;will-change:transform}
.profile-cropper-stage.is-loading::after{content:"";position:absolute;left:50%;top:50%;z-index:2;width:34px;height:34px;margin:-17px;border:3px solid rgba(255,255,255,.24);border-top-color:#fff;border-radius:50%;animation:profileCropperSpin .7s linear infinite}
@keyframes profileCropperSpin{to{transform:rotate(360deg)}}
@media(max-width:760px){.profile-cropper-stage.is-avatar{border-radius:24px}}
.profile-cropper-zoom{gap:8px}
.profile-cropper-zoom input{width:100%}
.profile-cropper-open{overflow:hidden}
.profile-gallery-grid{display:grid;grid-template-columns:repeat(auto-fit,minmax(min(190px,100%),1fr));gap:12px}
.public-profile-gallery{grid-template-columns:repeat(auto-fit,minmax(min(190px,100%),1fr))}
.profile-gallery-item{
  position:relative;
  display:block;
  padding:0;
  border:0;
  background:transparent;
  cursor:pointer;
  border-radius:24px;
  opacity:1;
  transform:none;
  transition:box-shadow .2s ease;
}
@media(prefers-reduced-motion:no-preference){
  .profile-gallery-item{
    animation:profilePhotoIn .58s cubic-bezier(.19,1,.22,1) both;
    animation-delay:calc(var(--photo-index,0) * 55ms);
  }
}
.profile-gallery-item:focus-visible{
  outline:none;
  box-shadow:0 0 0 3px rgba(255,255,255,.16);
}
.profile-gallery-item.is-primary .profile-gallery-item-media::after{box-shadow:inset 0 0 0 1px rgba(255,255,255,.22)}
.profile-gallery-item-media{
  position:relative;
  display:block;
  aspect-ratio:4/5;
  border-radius:24px;
  overflow:hidden;
}
.profile-gallery-item-media::before{
  content:"";
  position:absolute;
  inset:0;
  z-index:1;
  background:rgba(0,0,0,.14);
  opacity:0;
  transition:opacity .2s ease;
  pointer-events:none;
}
.profile-gallery-item-media::after{
  content:"";
  position:absolute;
  inset:0;
  z-index:2;
  border-radius:24px;
  box-shadow:inset 0 0 0 1px rgba(255,255,255,.08);
  background:linear-gradient(180deg,transparent 45%,rgba(0,0,0,.18) 100%);
}
.profile-gallery-item:hover .profile-gallery-item-media::before,
.profile-gallery-item:focus-visible .profile-gallery-item-media::before{opacity:1}
.profile-gallery-item img{
  display:block;
  width:100%;
  height:100%;
  object-fit:cover;
}
.profile-gallery-item .photo-badge{
  left:12px;
  top:12px;
  z-index:3;
}
.notification-card{position:relative;padding:0;overflow:hidden}
.notification-page-head{display:flex;align-items:flex-end;justify-content:space-between;gap:14px;flex-wrap:wrap}
.notification-bulk-actions{display:flex;gap:8px;flex-wrap:wrap}
.notification-card-link{display:block;padding:22px}
.notification-card-actions{padding-right:38px}
.notification-delete{position:absolute;top:16px;right:16px;display:inline-flex;align-items:center;justify-content:center;width:32px;height:32px;padding:0;border:1px solid var(--line);border-radius:10px;background:var(--surface);color:var(--muted);cursor:pointer}
.notification-delete:hover,.notification-delete:focus-visible{border-color:rgba(255,107,107,.3);background:rgba(255,107,107,.12);color:#ffdada;outline:none}
.notification-delete:disabled{cursor:wait;opacity:.55}
.notification-delete svg{width:16px;height:16px}
.profile-photo-viewer{
  --profile-overlay-available-height:calc(100dvh - var(--site-header-height));
  position:fixed;
  top:var(--site-header-height);
  right:0;
  bottom:0;
  left:0;
  z-index:80;
  display:grid;
  place-items:center;
  min-height:0;
  padding:18px;
}
.profile-photo-viewer[hidden]{display:none}
.profile-photo-viewer.is-closing{pointer-events:none}
.profile-photo-viewer.is-closing .profile-photo-viewer-dialog{animation:profileViewerOut .2s ease forwards}
.profile-photo-viewer.is-closing .profile-photo-viewer-backdrop{animation:profileBackdropOut .2s ease forwards}
.profile-photo-viewer-backdrop{
  position:absolute;
  inset:0;
  background:rgba(5,5,5,.72);
  backdrop-filter:blur(16px);
  animation:fade .22s ease;
  border-radius:0;
}
.profile-photo-viewer-dialog{
  position:relative;
  z-index:1;
  display:grid;
  grid-template-rows:auto minmax(0,1fr) auto;
  gap:14px;
  width:min(1100px,calc(100vw - 36px));
  height:min(860px,calc(var(--profile-overlay-available-height) - 36px));
  max-width:100%;
  max-height:100%;
  padding:18px;
  border-radius:32px;
  border:1px solid var(--line2);
  background:rgba(10,10,10,.92);
  box-shadow:0 40px 110px rgba(0,0,0,.42);
  overflow:visible;
  isolation:isolate;
  animation:profileViewerIn .28s cubic-bezier(.2,.8,.2,1);
}
.profile-photo-viewer-topbar{
  position:relative;
  z-index:4;
  display:flex;
  align-items:flex-start;
  justify-content:space-between;
  gap:16px;
}
.profile-photo-viewer-copy{display:grid;gap:4px;min-width:0}
.profile-photo-viewer-copy strong{font-size:18px;line-height:1.1}
.profile-photo-viewer-copy span{font-size:13px;color:var(--muted)}
.profile-photo-like-counter{
  display:inline-flex;
  align-items:center;
  width:max-content;
  min-height:28px;
  padding:0 10px;
  border-radius:999px;
  border:1px solid var(--line);
  background:rgba(255,255,255,.05);
  color:var(--text)!important;
}
.profile-photo-likes{position:relative;margin-left:auto}
.profile-photo-likes[hidden]{display:none}
.profile-photo-likes-toggle{display:flex;align-items:center;gap:9px;min-height:38px;padding:4px 10px 4px 6px;border:1px solid var(--line);border-radius:999px;background:var(--surface);color:var(--text);cursor:pointer}
.profile-photo-likes-toggle:disabled{cursor:default;opacity:.72}
.profile-photo-likes-preview{display:flex;align-items:center;min-width:24px}
.profile-photo-likes-preview:empty::before{content:'♡';display:grid;place-items:center;width:26px;height:26px;color:var(--muted);font-size:17px}
.profile-photo-likes-preview img{display:block;width:26px;height:26px;margin-left:-7px;border:2px solid rgba(10,10,10,.92);border-radius:999px;object-fit:cover}
.profile-photo-likes-preview img:first-child{margin-left:0}
.profile-photo-likes-toggle strong{font-size:12px;white-space:nowrap}
.profile-photo-likers-menu{position:absolute;right:0;top:calc(100% + 8px);z-index:9;width:min(300px,calc(100vw - 44px));padding:8px;border:1px solid var(--line2);border-radius:16px;background:rgba(17,17,17,.98);box-shadow:0 24px 60px rgba(0,0,0,.34);animation:profileMenuIn .16s ease}
.profile-photo-likers-menu[hidden]{display:none}
.profile-photo-likers-list{display:grid;gap:3px;max-height:min(42vh,330px);overflow-y:auto;overscroll-behavior:contain;scrollbar-width:thin}
.profile-photo-likers-list a{display:flex;align-items:center;gap:10px;min-width:0;padding:7px;border-radius:11px;color:var(--text);text-decoration:none}
.profile-photo-likers-list a:hover,.profile-photo-likers-list a:focus-visible{background:var(--surface2);outline:none}
.profile-photo-likers-list img{width:36px;height:36px;border-radius:12px;object-fit:cover;flex:0 0 auto}
.profile-photo-likers-list span{display:grid;gap:2px;min-width:0}
.profile-photo-likers-list strong,.profile-photo-likers-list small{overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
.profile-photo-likers-list strong{font-size:13px}
.profile-photo-likers-list small{color:var(--muted);font-size:11px}
.profile-photo-viewer-controls{
  position:relative;
  z-index:5;
  display:flex;
  align-items:center;
  gap:8px;
}
.profile-photo-quick-action,
.profile-photo-menu-toggle,
.profile-photo-viewer-close{
  display:inline-flex;
  align-items:center;
  justify-content:center;
  width:42px;
  height:42px;
  padding:0;
  border:1px solid var(--line);
  border-radius:16px;
  background:var(--surface);
  color:var(--text);
  cursor:pointer;
  transition:.2s;
}
.profile-photo-quick-action:hover,
.profile-photo-menu-toggle:hover,
.profile-photo-viewer-close:hover{background:var(--surface2)}
.profile-photo-quick-action.is-active{
  border-color:rgba(239,104,153,.42);
  background:rgba(239,104,153,.16);
  color:#ff91b9;
  box-shadow:0 0 0 3px rgba(239,104,153,.08);
}
.profile-photo-quick-action.is-active svg path{fill:currentColor;stroke:currentColor}
.profile-photo-quick-action:disabled,.profile-photo-menu-item:disabled{cursor:wait;opacity:.7}
.profile-photo-quick-action svg,
.profile-photo-menu-toggle svg,
.profile-photo-viewer-close svg{width:18px;height:18px}
.profile-photo-viewer-stage{
  position:relative;
  z-index:1;
  display:grid;
  place-items:center;
  min-width:0;
  min-height:0;
  width:100%;
  border-radius:26px;
  background:rgba(0,0,0,.18);
  overflow:hidden;
}
.profile-photo-viewer-stage img{
  display:block;
  min-width:0;
  min-height:0;
  width:100%;
  height:100%;
  max-width:100%;
  max-height:100%;
  object-fit:contain;
}
.profile-photo-nav{
  position:absolute;
  top:50%;
  transform:translateY(-50%);
  display:inline-flex;
  align-items:center;
  justify-content:center;
  width:44px;
  height:44px;
  padding:0;
  border:1px solid var(--line);
  border-radius:16px;
  background:rgba(17,17,17,.72);
  color:#fff;
  cursor:pointer;
  z-index:2;
  transition:.2s;
}
.profile-photo-nav:hover{background:rgba(17,17,17,.9)}
.profile-photo-nav svg{width:18px;height:18px}
.profile-photo-nav.is-prev{left:16px}
.profile-photo-nav.is-next{right:16px}
.profile-photo-nav[hidden]{display:none}
.profile-photo-viewer-strip{
  position:relative;
  z-index:2;
  display:flex;
  gap:10px;
  overflow:auto;
  padding-bottom:4px;
  scrollbar-width:thin;
}
.profile-photo-viewer-strip:empty{display:none}
.profile-photo-thumb{
  position:relative;
  flex:0 0 78px;
  height:96px;
  padding:0;
  border:0;
  border-radius:18px;
  overflow:hidden;
  background:transparent;
  cursor:pointer;
  opacity:.72;
  transform:scale(.96);
  transition:transform .2s ease,opacity .2s ease;
}
.profile-photo-thumb img{display:block;width:100%;height:100%;object-fit:cover}
.profile-photo-thumb::after{
  content:"";
  position:absolute;
  inset:0;
  border-radius:18px;
  box-shadow:inset 0 0 0 1px rgba(255,255,255,.1);
}
.profile-photo-thumb.is-active{opacity:1;transform:scale(1)}
.profile-photo-thumb.is-active::after{box-shadow:inset 0 0 0 2px rgba(255,255,255,.62)}
.profile-photo-menu{
  position:absolute;
  top:54px;
  right:0;
  z-index:8;
  display:grid;
  gap:6px;
  padding:10px;
  border-radius:18px;
  border:1px solid var(--line2);
  background:rgba(17,17,17,.96);
  box-shadow:0 24px 60px rgba(0,0,0,.32);
  animation:profileMenuIn .16s ease;
}
.profile-photo-menu[hidden]{display:none}
.profile-photo-menu-actions{
  display:grid;
  grid-auto-flow:column;
  grid-auto-columns:44px;
  justify-content:end;
  gap:8px;
}
.profile-photo-menu-item,
.profile-photo-menu-submit{
  display:inline-flex;
  align-items:center;
  justify-content:center;
  width:44px;
  height:44px;
  min-height:42px;
  padding:0;
  border:1px solid var(--line);
  border-radius:14px;
  background:var(--surface);
  color:var(--text);
  cursor:pointer;
  text-align:center;
  text-decoration:none;
  transition:.2s;
}
.profile-photo-menu-item:hover,
.profile-photo-menu-submit:hover{background:rgba(255,255,255,.07)}
.profile-photo-menu-item.is-active,
.profile-photo-menu-submit.is-active{
  background:rgba(255,207,92,.16);
  border-color:rgba(255,207,92,.34);
  color:#ffd96f;
  box-shadow:0 0 0 3px rgba(255,207,92,.07);
}
.profile-photo-menu-item svg,
.profile-photo-menu-submit svg{display:block;width:18px;height:18px}
.profile-photo-action-icon{display:inline-flex}
.profile-photo-action-icon[hidden]{display:none}
.profile-photo-menu-item.danger{background:rgba(255,107,107,.12);border-color:rgba(255,107,107,.18);color:#ffdada}
.profile-photo-menu-item[hidden]{display:none}
.profile-photo-menu-forward{
  display:grid;
  grid-template-columns:minmax(0,1fr) 44px;
  align-items:center;
  gap:8px;
  padding-top:8px;
  margin-top:2px;
  border-top:1px solid var(--line);
}
.profile-photo-menu-forward select{
  min-width:0;
  min-height:42px;
  padding:10px 12px;
  border-radius:14px;
}
.profile-photo-menu-submit{
  justify-self:end;
}
.profile-photo-menu-submit:disabled{
  opacity:.45;
  pointer-events:none;
}
.profile-overlay-open,
.profile-photo-viewer-open{overflow:hidden}
@media(max-width:1100px){.dashboard-page,.profile-content-grid{grid-template-columns:minmax(0,1fr)}}
@media(max-width:760px){.dashboard-page,.dashboard-main,.dashboard-sidebar,.profile-shell{gap:14px}.profile-hero{gap:16px}.profile-hero-head{gap:14px}.profile-hero-identity.profile-head.compact,.profile-hero-identity{flex-wrap:wrap}.profile-hero-avatar{width:96px;height:96px;border-radius:24px}.profile-hero-photo{border-radius:24px}.profile-title{font-size:clamp(28px,9vw,40px)}.profile-metrics,.tag-cluster-grid,.photo-grid,.public-photo-grid{grid-template-columns:minmax(0,1fr)}.profile-meta-list{display:grid}.profile-meta-pill{min-width:0}.profile-actions,.profile-upload-actions,.photo-card-actions{display:grid;grid-template-columns:minmax(0,1fr)}.profile-actions form,.profile-actions .btn,.profile-upload-actions .btn,.photo-card-actions .btn{width:100%}.profile-inline-link{width:100%}.profile-gallery-grid{grid-template-columns:repeat(2,minmax(0,1fr));gap:10px}.profile-gallery-add-placeholder{padding:14px}.profile-gallery-add-placeholder strong{font-size:15px}.profile-gallery-add-placeholder span:last-child{font-size:12px}.profile-photo-viewer{padding:10px}.profile-photo-viewer-dialog{width:min(100%,calc(100vw - 20px));height:min(100%,calc(var(--profile-overlay-available-height) - 20px));padding:14px;border-radius:26px}.profile-photo-viewer-stage{min-height:0}.profile-photo-nav{width:38px;height:38px;border-radius:14px}.profile-photo-nav.is-prev{left:10px}.profile-photo-nav.is-next{right:10px}.profile-photo-thumb{flex-basis:64px;height:78px}.profile-photo-menu{min-width:min(220px,calc(100vw - 46px))}.profile-photo-menu-forward{grid-template-columns:minmax(0,1fr)}.profile-photo-menu-submit{width:100%}}
@media(max-width:760px){
  .profile-tag-card{padding:16px;border-radius:28px}
  .profile-tag-card-head{display:grid;grid-template-columns:minmax(0,1fr)}
  .profile-tag-card-actions{justify-content:flex-start}
  .profile-tag-edit-button,
  .profile-tag-card-toggle{width:100%}
  .profile-tag-lane{padding:12px;border-radius:22px}
  .profile-tag-lane-label{font-size:12px}
  .profile-tag-category-list{gap:8px}
  .profile-tag-category-title{font-size:12px}
  .profile-tag-category-count,
  .profile-tag-category-chevron{width:24px;height:24px;min-width:24px}
  .profile-tag-pill{min-height:32px;padding:7px 11px;font-size:12px}
  .profile-tag-editor-footer-actions{display:grid;grid-template-columns:1fr 1fr}
  .profile-tag-editor-footer-actions .btn{width:100%}
}
@media(prefers-reduced-motion:reduce){
  .policy-page.anim-in{animation:none!important}
  .profile-photo-viewer-backdrop,
  .profile-photo-viewer-dialog,
  .profile-photo-viewer.is-closing .profile-photo-viewer-backdrop,
  .profile-photo-viewer.is-closing .profile-photo-viewer-dialog{animation:none!important}
  .profile-tag-card,
  .profile-tag-lane,
  .profile-tag-pill,
  .profile-tag-card-toggle,
  .profile-tag-category-chevron,
  .profile-tag-card-grid,
  .profile-tag-category-body{transition:none!important}
  .profile-tag-card{transform:none!important}
  .profile-tag-card.is-expanded .profile-tag-pill.is-collapsed-hidden,
  .profile-tag-card.is-expanded .profile-tag-category.is-collapsed-hidden,
  .profile-tag-card.is-expanding .profile-tag-card-grid,
  .profile-tag-card.is-collapsing .profile-tag-card-grid,
  .profile-tag-card.is-expanding .profile-tag-pill,
  .profile-tag-card.is-collapsing .profile-tag-pill.is-collapsed-hidden,
  .profile-tag-card.is-collapsing .profile-tag-category.is-collapsed-hidden,
  .profile-tag-category.is-opening .profile-tag-category-body,
  .profile-tag-category.is-closing .profile-tag-category-body,
  .profile-tag-category.is-opening .profile-tag-pill,
  .profile-tag-category.is-closing .profile-tag-pill{animation:none!important}
}
@media(max-width:760px){.profile-photo-menu-forward{grid-template-columns:minmax(0,1fr) 44px}.profile-photo-menu-submit{width:44px}}
.font-sm{font-size:14px}.font-md{font-size:16px}.font-lg{font-size:17px}
.reduce-motion *, .reduce-motion *::before, .reduce-motion *::after{animation:none!important;transition:none!important;scroll-behavior:auto!important}
.settings-layout{display:grid;grid-template-columns:260px 1fr;gap:18px;align-items:start}
.settings-sidebar{position:sticky;top:98px;align-self:start}
.settings-nav{display:grid;gap:8px;margin-top:10px}
.settings-nav a{display:flex;align-items:center;padding:10px 12px;border-radius:14px;border:1px solid var(--line);background:var(--surface);color:var(--text)}
.settings-nav a.active{background:var(--accent);color:var(--accentText);border-color:transparent}
.settings-content{display:grid;gap:16px}
.settings-layout input[type="checkbox"]{accent-color:#eb7dae}
.settings-grid{display:grid;gap:12px}
.settings-section-split{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:16px}
.settings-stat-grid{display:grid;grid-template-columns:repeat(auto-fit,minmax(180px,1fr));gap:12px}
.settings-stat-card{display:grid;gap:6px;padding:14px 16px;border-radius:18px;border:1px solid var(--line);background:rgba(255,255,255,.03)}
.settings-stat-card span{font-size:12px;letter-spacing:.08em;text-transform:uppercase;color:var(--muted)}
.settings-stat-card strong{font-size:28px;line-height:1;letter-spacing:-.04em}
.settings-stat-card small{font-size:12px;line-height:1.45;color:var(--muted)}
.settings-fact-list,.settings-insight-list{display:grid;gap:10px}
.settings-fact-row{display:flex;align-items:center;justify-content:space-between;gap:16px;padding:12px 14px;border-radius:16px;border:1px solid var(--line);background:rgba(255,255,255,.03)}
.settings-fact-row span{font-size:13px;color:var(--muted)}
.settings-fact-row strong{font-size:14px;line-height:1.35;text-align:right}
.settings-insight-item{padding:12px 14px;border-radius:16px;border:1px solid var(--line);background:rgba(255,255,255,.03);font-size:14px;line-height:1.5}
.switch-row{display:grid;grid-template-columns:minmax(0,1fr) 44px;align-items:center;gap:10px;min-width:0;min-height:56px;padding:6px 12px;margin:0;border-radius:14px;border:1px solid var(--line);background:rgba(255,255,255,.03);cursor:pointer}
.switch-row-copy{min-width:0;overflow-wrap:anywhere}
.switch-row-control{display:inline-flex;align-items:center;justify-content:center;width:44px;height:44px}
.switch-row input{width:22px;min-width:22px;max-width:22px;height:22px;min-height:22px;max-height:22px;margin:0;accent-color:#eb7dae}
.switch-row:focus-within,.switch-row:has(input:focus-visible){border-color:var(--line2);background:rgba(255,255,255,.06);outline:2px solid rgba(247,247,243,.58);outline-offset:2px}
.interface-preview-card .section-body{display:grid;gap:14px}
.interface-preview-card,.interface-preview-shell{content-visibility:visible;contain:layout paint style;isolation:isolate}
.interface-preview-shell{display:grid;gap:14px;padding:16px;border-radius:22px;border:1px solid var(--line);background:#1b1b1b}
.interface-preview-topbar{display:flex;align-items:center;justify-content:space-between;gap:12px;padding-bottom:12px;border-bottom:1px solid var(--line)}
.interface-preview-person{display:flex;align-items:center;gap:10px;min-width:0}
.interface-preview-avatar{display:block;width:40px;height:40px;border-radius:14px;border:1px solid var(--line);background:rgba(255,255,255,.08);object-fit:cover}
.interface-preview-person-copy{display:grid;gap:2px;min-width:0}
.interface-preview-person-copy strong{font-size:15px;line-height:1.2}
.interface-preview-person-copy span{font-size:12px;color:var(--muted)}
.interface-preview-chip{display:inline-flex;align-items:center;justify-content:center;min-height:30px;padding:0 10px;border-radius:999px;border:1px solid var(--line);background:var(--surface);font-size:12px;color:var(--muted);white-space:nowrap}
.interface-preview-chat{display:grid;gap:10px}
.interface-preview-chat .msg{max-width:min(82%,420px);animation:none}
.interface-preview-chat .msg.me{margin-left:auto}
.interface-preview-meta{margin-top:6px}
.interface-preview-meta .msg-meta-group{margin-right:0}
.interface-preview-menu-trigger{pointer-events:none;opacity:.38}
.interface-preview-shell[data-show-sender-names="0"] [data-preview-author-row]{display:none!important}
.interface-preview-shell[data-show-message-times="0"] .msg:not(.is-meta-peek) [data-preview-time]{display:none!important}
.interface-preview-shell[data-show-message-status="0"] .msg:not(.is-meta-peek) [data-preview-status]{display:none!important}
.interface-preview-shell[data-show-message-times="0"][data-show-message-status="0"] .msg:not(.is-meta-peek) [data-preview-menu-trigger]{display:none!important}
.interface-preview-shell[data-show-message-times="0"][data-show-message-status="0"] .msg:not(.is-meta-peek) .interface-preview-meta{display:none}
@media(max-width:980px){.settings-layout{grid-template-columns:1fr}.settings-sidebar{position:static}.interface-preview-topbar{align-items:flex-start;flex-wrap:wrap}.settings-section-split{grid-template-columns:minmax(0,1fr)}}
@media(max-width:760px){.settings-stat-grid{grid-template-columns:minmax(0,1fr)}.settings-fact-row{display:grid;justify-content:stretch}.settings-fact-row strong{text-align:left}}

/* chat composer refresh */
:root{
  --chat-action:rgba(247,247,243,.84);
  --chat-action-soft:rgba(247,247,243,.08);
  --chat-action-soft-hover:rgba(247,247,243,.14);
  --chat-send-bg:#f7f7f3;
  --chat-send-fg:#111;
  --chat-compose-bg:rgba(255,255,255,.04);
  --chat-preview-bg:rgba(255,255,255,.045);
  --chat-preview-border:rgba(255,255,255,.08);
}
.chat-shell{grid-template-columns:minmax(260px,300px) minmax(0,1fr);gap:12px}
.chat-sidebar,.chat-main{padding:14px}
.chat-pane-head{padding-bottom:8px;margin-bottom: 10px;}
.chat-pane-title{margin-top:2px;font-size:18px}
.chat-conv-list{gap:6px;margin-top:2px}
.chat-sidebar .conv-item{padding:10px 12px;border-radius:16px}
.chat-sidebar .conv-line{gap:10px}
.chat-sidebar .avatar-sm{width:38px;height:38px;border-radius:12px}
.conv-entry{position:relative;display:grid;grid-template-columns:minmax(0,1fr);min-width:0}
.conv-entry.is-menu-open{z-index:30}
.conv-entry .conv-item{padding-right:42px}
.conv-entry.is-muted .conv-item{opacity:.72}
.chat-conversation-menu{position:absolute;right:7px;top:calc(50% - 15px);z-index:12}
.chat-conversation-menu-toggle{display:inline-grid;place-items:center;width:30px;height:30px;padding:0;border:1px solid transparent;border-radius:10px;background:transparent;color:var(--muted);cursor:pointer;line-height:1;transition:background .16s ease,border-color .16s ease,color .16s ease}
.chat-conversation-menu-toggle svg{display:block;width:18px;height:18px}
.chat-conversation-menu-toggle:hover,.chat-conversation-menu-toggle:focus-visible,.chat-conversation-menu.is-open .chat-conversation-menu-toggle{border-color:var(--line);background:var(--surface2);color:var(--text);outline:none}
.chat-conversation-menu-panel{position:absolute;top:calc(100% + 7px);right:0;z-index:20;display:grid;gap:4px;width:224px;padding:6px;border:1px solid var(--line2);border-radius:14px;background:rgba(13,13,13,.98);box-shadow:0 14px 32px rgba(0,0,0,.3);backdrop-filter:blur(18px);transform-origin:top right}
.chat-conversation-menu-panel[hidden],.chat-conversation-mute-options[hidden]{display:none}
.chat-conversation-menu-panel.is-open{animation:messageMenuIn .14s ease both}
.chat-conversation-menu-panel[data-placement="top"]{top:auto;bottom:calc(100% + 7px);transform-origin:bottom right}
.chat-conversation-menu-panel button{display:flex;align-items:center;gap:10px;width:100%;min-height:40px;padding:8px 9px;border:0;border-radius:9px;background:transparent;color:var(--text);font:inherit;text-align:left;cursor:pointer}
.chat-conversation-menu-panel button:hover,.chat-conversation-menu-panel button:focus-visible{background:var(--surface2);outline:none}
.chat-conversation-menu-panel button>span:nth-child(2){min-width:0;flex:1 1 auto}
.chat-conversation-menu-panel svg{width:17px;height:17px;flex:0 0 auto}
.chat-conversation-menu-panel .danger{margin-top:3px;border-top:1px solid var(--line);border-radius:0 0 9px 9px;color:#ffb8b8}
.chat-conversation-mute-options{display:grid;gap:2px;margin:0 3px;padding:4px;border:1px solid var(--line);border-radius:10px;background:rgba(255,255,255,.035)}
.chat-conversation-mute-options.is-open{animation:conversationMuteOptionsIn .14s ease both}
.chat-conversation-mute-options.is-closing{pointer-events:none;animation:conversationMuteOptionsOut .14s ease both}
.chat-conversation-mute-options button{min-height:34px;padding:6px 7px;color:var(--muted);font-size:12px}
.chat-conversation-delete-dialog{position:fixed;inset:0;z-index:140;display:grid;place-items:center;padding:18px}
.chat-conversation-delete-dialog[hidden]{display:none}
.chat-conversation-delete-backdrop{position:absolute;inset:0;width:100%;height:100%;padding:0;border:0;background:rgba(0,0,0,.68);backdrop-filter:blur(12px)}
.chat-conversation-delete-panel{position:relative;display:grid;justify-items:center;gap:12px;width:min(430px,100%);padding:24px;border:1px solid var(--line2);border-radius:24px;background:rgba(16,16,16,.98);box-shadow:0 28px 90px rgba(0,0,0,.45);text-align:center;animation:messageMenuIn .18s ease both}
.chat-conversation-delete-panel h2,.chat-conversation-delete-panel p{margin:0}
.chat-conversation-delete-panel p{color:var(--muted);line-height:1.5}
.chat-conversation-delete-icon{display:grid;place-items:center;width:48px;height:48px;border-radius:16px;background:rgba(255,107,107,.13);color:#ffb8b8}
.chat-conversation-delete-icon svg{width:22px;height:22px}
.chat-conversation-delete-panel .actions{justify-content:center}
.progressive-avatar{filter:blur(12px);transform:scale(1.06);transition:filter .24s ease,transform .24s ease,opacity .2s ease}
.progressive-avatar.has-preview{filter:blur(4px)}
.progressive-avatar.is-loaded{filter:blur(0);transform:none}
@media(prefers-reduced-motion:reduce){.progressive-avatar{transition:none}}
.conv-copy{gap:3px}
.conv-preview{font-size:13px;line-height:1.35}
.conv-preview-badge{display:inline-flex;align-items:center;max-width:100%;height:20px;padding:0 7px;border-radius:999px;background:rgba(255,255,255,.07);color:var(--muted);font-size:12px;line-height:1;vertical-align:middle}
.conv-preview-badge-image,.conv-preview-badge-gif{background:rgba(95,174,255,.14);color:#bfe0ff}
.conv-preview-badge-video{background:rgba(178,132,255,.16);color:#dbc8ff}
.conv-preview-badge-audio{background:rgba(255,205,99,.14);color:#ffe0a6}
.conv-preview-badge-file{background:rgba(180,190,205,.14);color:#d7dde7}
.conv-preview-badge-forward{background:rgba(121,214,156,.13);color:#c8f1d5}
.chat-main{gap:10px}
.chat-main-head{display:flex;align-items:center;justify-content:space-between;gap:12px;padding-bottom:10px;border-bottom:1px solid var(--line); padding: 0px 10px 10px; flex-direction: row;}
.chat-main-head.is-empty{justify-content:flex-end}
.chat-main-spacer{flex:1 1 auto}
.chat-peer{align-items:center}
.chat-peer-link{display:flex;align-items:center;gap:12px;min-width:0;flex:1 1 auto;color:inherit;border-radius:18px}
.chat-peer-link .avatar-md,.chat-peer-name{transition:opacity .2s ease,filter .2s ease}
.chat-peer-link:hover .chat-peer-name{opacity:.82}
.chat-peer-link:hover .avatar-md{opacity:.84;filter:brightness(.92)}
.chat-peer-link:focus-visible{outline:none;box-shadow:0 0 0 3px rgba(255,255,255,.1)}
.chat-peer-copy{display:flex;flex-direction:column;align-items:flex-start;justify-content:center;gap:4px;min-width:0}
.chat-peer-name{font-size:20px}
.chat-peer-status-row{display:flex;align-items:center;gap:10px;flex-wrap:wrap;min-width:0}
.chat-peer-status-row .typing-live{margin-top:0;min-height:0}
.chat-actions{display:flex;align-items:center;justify-content:flex-end;gap:8px;flex:0 0 auto}
.chat-action-icon{display:inline-flex;align-items:center;justify-content:center}
.chat-action-icon svg{width:16px;height:16px}
.chat-actions .btn{width:auto;min-height:36px;padding:7px 11px;font-size:13px}
.chat-head-icon-btn{display:inline-flex;align-items:center;justify-content:center;width:38px;height:38px;padding:0;border:1px solid var(--line);border-radius:14px;background:var(--surface);color:var(--text);cursor:pointer;flex:0 0 auto;transition:background-color .2s ease,border-color .2s ease,color .2s ease,transform .2s ease}
.chat-head-icon-btn:hover,.chat-head-icon-btn:focus-visible{background:var(--surface2);border-color:var(--line2);outline:none;transform:none}
.chat-head-icon-btn svg{display:block;width:18px;height:18px}
.chat-messages{position:relative;gap:0;overflow-x:hidden;overflow-y:auto;padding-right:10px;margin-right:-8px;scrollbar-gutter:stable}
.chat-main.is-dragging-file{border-color:rgba(119,190,255,.28)}
.chat-drop-overlay{position:absolute;inset:18px 8px 64px;z-index:30;display:grid;place-items:center;pointer-events:none;opacity:0;transform:scale(.985);transition:opacity .18s ease,transform .18s ease;overflow:hidden;border-radius:22px}
.chat-drop-overlay::before{content:"";position:absolute;inset:0;border:1px dashed rgba(247,247,243,.32);border-radius:22px;background:rgba(12,12,12,.54);backdrop-filter:blur(10px);box-shadow:inset 0 0 0 1px rgba(255,255,255,.04)}
.chat-drop-overlay.is-visible{opacity:1;transform:none;pointer-events:auto;animation:chatDropPulse 1.2s ease-in-out infinite}
.chat-drop-zones{position:relative;display:grid;grid-template-columns:minmax(0,1fr);gap:14px;width:min(760px,calc(100% - 18px))}
.chat-drop-card{position:relative;display:grid;grid-template-columns:auto minmax(0,1fr);align-items:center;justify-items:start;gap:16px;min-width:0;width:100%;min-height:128px;padding:26px 28px;border-radius:24px;border:1px solid var(--line2);background:rgba(21,21,21,.92);box-shadow:0 24px 70px rgba(0,0,0,.34);text-align:left;animation:chatDropCardIn .2s ease both;transition:background .16s ease,border-color .16s ease,box-shadow .16s ease,transform .16s ease}
.chat-drop-card.is-drop-target{border-color:rgba(119,190,255,.9);background:rgba(36,74,104,.94);box-shadow:0 24px 70px rgba(0,0,0,.34),0 0 0 3px rgba(119,190,255,.2);transform:translateY(-1px)}
.chat-drop-overlay.is-file-only .chat-drop-card[data-drop-mode="image"]{display:none}
.chat-drop-overlay.is-file-only .chat-drop-zones{width:min(620px,calc(100% - 18px))}
.chat-drop-icon{display:grid;place-items:center;width:58px;height:58px;border-radius:999px;background:rgba(119,190,255,.14);color:#cfe8ff}
.chat-drop-icon svg{width:30px;height:30px}
.chat-drop-card strong{font-size:20px;line-height:1.15}
.chat-drop-card span{grid-column:2;font-size:14px;line-height:1.35;color:var(--muted)}
.chat-drop-card.is-drop-target span{color:rgba(255,255,255,.78)}
.chat-messages::-webkit-scrollbar{width:8px}
.chat-messages::-webkit-scrollbar-track{background:transparent;margin-block:2px}
.chat-messages::-webkit-scrollbar-thumb{background:rgba(255,255,255,.24);border-radius:999px;border:2px solid transparent;background-clip:padding-box}
body.chat-screen .chat-messages .msg{animation:none;content-visibility:auto;contain:layout style paint;contain-intrinsic-size:auto 72px}
body.chat-screen .chat-messages .msg.with-visual{contain-intrinsic-size:auto 300px}
body.chat-screen .chat-messages .msg.with-audio{contain-intrinsic-size:auto 96px}
body.chat-screen .chat-messages .msg.msg-enter-mine{animation:chatMessageMineIn .22s ease both}
body.chat-screen .chat-messages .msg.msg-enter-peer{animation:chatMessagePeerIn .24s ease both}
body.chat-screen .chat-messages .msg.msg-removing{animation:chatMessageOut .18s ease both;overflow:hidden;pointer-events:none}
body.chat-screen .chat-day-separator{content-visibility:auto;contain-intrinsic-size:auto 36px}
.chat-day-separator{display:flex;justify-content:center;align-items:center;padding: 10px 0px 2px 0px;}
.chat-day-separator span{display:inline-flex;align-items:center;justify-content:center;min-height:24px;padding:4px 11px;border-radius:999px;background:var(--surface);font-size:12px;line-height:1;color:var(--muted);font-variant-numeric:tabular-nums;letter-spacing:.01em}
.chat-floating-layer{position:sticky;top:0px;z-index:25;display:grid;justify-items:center;gap:6px;pointer-events:none;margin:0 0 4px;padding:0;background:transparent!important;border:0!important;box-shadow:none!important}
.chat-sticky-day{display:inline-flex;align-items:center;justify-content:center;width:max-content;max-width:min(92%,560px);min-height:24px;padding:4px 11px;border-radius:999px;background:rgba(20,20,20,.8);font-size:12px;line-height:1;color:var(--muted);font-variant-numeric:tabular-nums;letter-spacing:.01em;backdrop-filter:blur(8px);opacity:0;transform:translateY(-3px);transition:opacity .16s ease,transform .16s ease}
.chat-sticky-day.is-visible{opacity:1;transform:none}
.chat-pinned-mini{pointer-events:auto;display:grid;gap:4px;justify-items:center}
.chat-pinned-head{display:inline-flex;align-items:center;gap:4px;max-width:min(82vw,460px)}
.chat-pinned-head svg{width:14px;height:14px;flex:0 0 auto;opacity:.84}
.chat-pinned-main{display:inline-flex;align-items:center;gap:6px;min-height:26px;max-width:min(72vw,390px);padding:4px 10px;border-radius:999px;border:1px solid var(--line);background:rgba(12,12,12,.78);backdrop-filter:blur(10px);font-size:12px;color:var(--muted);line-height:1.15}
.chat-pinned-count{display:inline-flex;align-items:center;justify-content:center;min-width:36px;height:18px;padding:0 6px;border-radius:999px;background:rgba(255,255,255,.08);font-size:10px;line-height:1;color:var(--muted)}
.chat-pinned-text{max-width:32ch;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
.chat-pinned-list{position:relative}
.chat-pinned-toggle{display:none}
.chat-pinned-menu{position:absolute;top:calc(100% + 6px);left:50%;transform:translateX(-50%);display:grid;gap:4px;min-width:min(76vw,340px);max-width:min(84vw,380px);padding:8px;border-radius:12px;border:1px solid var(--line2);background:rgba(12,12,12,.94);backdrop-filter:blur(12px);box-shadow:0 16px 36px rgba(0,0,0,.28)}
.chat-pinned-item{display:grid;grid-template-columns:auto minmax(0,1fr);align-items:center;gap:8px;padding:6px 7px;border-radius:10px;border:1px solid transparent;background:transparent;color:var(--text);cursor:pointer}
.chat-pinned-item:hover,.chat-pinned-item:focus-visible{border-color:var(--line2);background:rgba(255,255,255,.05);outline:none}
.chat-pinned-item-time{font-size:10px;color:var(--muted);white-space:nowrap}
.chat-pinned-item-text{font-size:12px;line-height:1.25;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
.chat-scroll-bottom{position:absolute;left:50%;bottom:var(--chat-scroll-bottom-offset,86px);z-index:24;display:inline-flex;align-items:center;justify-content:center;width:40px;height:40px;margin:0;padding:0;border:1px solid rgba(255,255,255,.22);border-radius:50%;background:rgba(20,20,20,.54);color:rgba(247,247,243,.86);box-shadow:0 8px 22px rgba(0,0,0,.18);backdrop-filter:blur(8px);cursor:pointer;opacity:0;pointer-events:none;transform:translate(-50%,8px) scale(.94);transition:opacity .18s ease,transform .18s ease,background-color .18s ease}
.chat-scroll-bottom.is-visible{opacity:1;pointer-events:auto;transform:translate(-50%,0) scale(1)}
.chat-scroll-bottom:hover,.chat-scroll-bottom:focus-visible{background:rgba(20,20,20,.72);outline:none}
.chat-scroll-bottom svg{width:20px;height:20px;margin-top:3px;}
.msg{padding:9px 12px;border-radius:15px;gap:4px;position:relative}
.msg-pin-marker{position:absolute;top:7px;right:9px;display:inline-flex;align-items:center;justify-content:center;width:16px;height:16px;color:var(--chat-action);opacity:.82;pointer-events:none}
.msg-pin-marker svg{width:14px;height:14px}
.msg.is-pinned .msg-body,.msg.is-pinned .msg-head{padding-right:18px}
.chat-messages .msg{margin-top:8px}
.chat-messages .msg:first-of-type{margin-top:0}
.chat-messages .msg.msg-gap-tight{margin-top:2px}
.chat-messages .msg.msg-gap-wide{margin-top:8px}
.chat-day-separator + .msg{margin-top:8px}
.chat-messages .msg.msg-chain-prev:not(.me){border-top-left-radius:7px}
.chat-messages .msg.msg-chain-next:not(.me){border-bottom-left-radius:7px}
.chat-messages .msg.me.msg-chain-prev{border-top-right-radius:7px}
.chat-messages .msg.me.msg-chain-next{border-bottom-right-radius:7px}
.msg-head{display:flex;align-items:center;justify-content:flex-start;gap:10px;min-width:0}
.msg-author{display:block;font-size:13px;color:var(--muted)}
.msg-body{min-width:0;overflow-wrap:anywhere}
.msg-meta{display:flex;align-items:center;gap:6px;width:100%;min-width:0;margin-top:4px}
.msg-meta-group{display:flex;align-items:center;gap:6px;min-width:max-content;margin-right:auto;flex:0 0 auto}
.msg-meta-group:empty{display:none}
.chat-messages[data-show-sender-names="0"] .msg:not(.me) .msg-head{display:none}
.msg-time{display:inline-block;min-width:max-content;flex:0 0 auto;font-size:11px;line-height:1;color:rgba(247,247,243,.42);font-variant-numeric:tabular-nums;white-space:nowrap}
.msg-edited-toggle{display:inline-flex;align-items:center;justify-content:center;min-width:12px;min-height:12px;color:rgba(247,247,243,.48);line-height:1;cursor:default}
.msg-edited-icon{display:inline-flex;align-items:center;justify-content:center;flex:0 0 auto}
.msg-edited-icon svg{width:12px;height:12px;display:block}
.msg-time-switch{position:relative;display:inline-block;width:18ch;height:1em;line-height:1;vertical-align:top}
.msg-time-switch .msg-time-created,.msg-time-switch .msg-time-edited{position:absolute;left:0;top:0;width:100%;line-height:1;transition:opacity .18s ease}
.msg-time-switch .msg-time-edited{opacity:0;pointer-events:none}
.msg-edited-toggle:hover + .msg-time-switch .msg-time-created,
.msg-edited-toggle:focus-visible + .msg-time-switch .msg-time-created{opacity:0}
.msg-edited-toggle:hover + .msg-time-switch .msg-time-edited,
.msg-edited-toggle:focus-visible + .msg-time-switch .msg-time-edited{opacity:1}
.msg-status{display:inline-flex;align-items:center;color:rgba(247,247,243,.18);line-height:1}
.msg-status-check{width:12px;height:12px;display:block}
.msg-status-check + .msg-status-check{margin-left:-6px}
.msg-status.is-sent .msg-status-check:last-child{display:none}
.msg-status.is-read{color:rgba(247,247,243,.64)}
.msg-menu-trigger{display:inline-flex;align-items:center;justify-content:center;width:20px;height:20px;padding:0;border:0;border-radius:999px;background:transparent;color:var(--muted);cursor:pointer;opacity:.72;transition:.18s;flex:0 0 auto;margin-left:auto}
.chat-messages[data-show-message-times="0"] .msg .msg-time{display:inline-block;min-width:0;max-width:0;opacity:0;overflow:hidden;transform:translateY(2px);transition:opacity .14s ease,transform .14s ease,max-width .14s ease}
.chat-messages[data-show-message-times="0"] .msg .msg-edited-toggle{display:inline-flex;max-width:0;opacity:0;overflow:hidden;transform:translateY(2px);transition:opacity .14s ease,transform .14s ease,max-width .14s ease}
.chat-messages[data-show-message-status="0"] .msg .msg-status{display:inline-flex;max-width:0;opacity:0;overflow:hidden;transform:translateY(2px);transition:opacity .14s ease,transform .14s ease,max-width .14s ease}
.chat-messages[data-show-message-times="0"] .msg.is-meta-peek .msg-time{min-width:max-content;max-width:18ch;opacity:1;transform:none}
.chat-messages[data-show-message-times="0"] .msg.is-meta-peek .msg-edited-toggle{max-width:14px;opacity:1;transform:none}
.chat-messages[data-show-message-status="0"] .msg.is-meta-peek .msg-status{max-width:22px;opacity:1;transform:none}
.chat-messages[data-show-message-times="0"][data-show-message-status="0"] .msg:not(.is-meta-peek) .msg-meta{margin-top:0}
.chat-messages[data-show-message-times="0"][data-show-message-status="0"] .msg .msg-meta{max-height:0;overflow:hidden;opacity:0;pointer-events:none;transform:translateY(3px);transition:opacity .14s ease,transform .14s ease,max-height .14s ease,margin-top .14s ease}
.chat-messages[data-show-message-times="0"][data-show-message-status="0"] .msg .msg-menu-trigger{display:inline-flex;opacity:0;pointer-events:none;transform:translateY(2px);transition:opacity .14s ease,transform .14s ease}
.chat-messages[data-show-message-times="0"][data-show-message-status="0"] .msg.is-meta-peek .msg-meta{margin-top:4px;max-height:26px;opacity:1;pointer-events:auto;transform:none}
.chat-messages[data-show-message-times="0"][data-show-message-status="0"] .msg.is-meta-peek .msg-menu-trigger{opacity:1;pointer-events:auto;transform:none}
.chat-messages[data-show-message-times="0"][data-show-message-status="0"] .msg.has-reactions:not(.is-meta-peek) .msg-meta{margin-top:4px;max-height:26px;opacity:1;pointer-events:auto;transform:none}
.chat-messages[data-show-message-times="0"][data-show-message-status="0"] .msg.has-reactions:not(.is-meta-peek) .msg-menu-trigger{display:none!important;opacity:0;pointer-events:none;transform:translateY(2px)}
.chat-messages[data-show-message-times="0"][data-show-message-status="0"] .msg.has-reactions:not(.is-meta-peek) .msg-reactions{margin-left:auto;margin-right:0}
@media (hover:hover) and (pointer:fine){
  .chat-messages[data-show-message-times="0"][data-show-message-status="0"] .msg .msg-menu-trigger{display:inline-flex !important}
}
.msg-menu-trigger:hover,.msg-menu-trigger:focus-visible{background:rgba(255,255,255,.05);color:var(--text);opacity:1}
.msg-menu-trigger svg{width:13px;height:13px}
.chat-tools{gap:8px;padding-top:10px}
.chat-selection-bar{display:flex;align-items:center;justify-content:space-between;gap:10px;padding:8px 10px;border-radius:16px;border:1px solid var(--line);background:var(--surface)}
.chat-selection-bar[hidden]{display:none}
.chat-selection-copy{display:flex;align-items:center;gap:8px;min-width:0;flex:1 1 auto}
.chat-selection-copy strong{display:inline-flex;align-items:center;justify-content:center;min-height:34px;padding:0 12px;border-radius:999px;background:rgba(255,255,255,.05);font-size:13px;line-height:1.1;white-space:nowrap}
.chat-selection-preview{display:flex;align-items:center;gap:6px;min-width:0;overflow:hidden}
.chat-selection-preview-item{display:inline-flex;align-items:center;gap:6px;min-width:0;max-width:132px;height:34px;padding:4px 9px 4px 5px;border-radius:12px;border:1px solid var(--line);background:rgba(255,255,255,.035);font-size:12px;line-height:1;color:var(--text)}
.chat-selection-preview-item img,.chat-selection-preview-icon{display:inline-grid;place-items:center;width:26px;height:26px;flex:0 0 auto;border-radius:8px;background:rgba(0,0,0,.18);object-fit:cover;color:var(--muted);font-size:12px}
.chat-selection-preview-item span:last-child{min-width:0;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
.chat-selection-preview-more{display:inline-flex;align-items:center;justify-content:center;height:28px;min-width:28px;padding:0 8px;border-radius:999px;background:rgba(255,255,255,.05);font-size:12px;color:var(--muted);flex:0 0 auto}
.chat-selection-actions{display:flex;align-items:center;justify-content:flex-end;gap:5px;flex:1 1 auto;min-width:0;flex-wrap:wrap}
.chat-selection-actions .btn.small{min-height:34px;padding:8px 11px;border-radius:12px}
.chat-selection-target{position:relative;min-width:136px;flex:0 0 auto}
.chat-selection-target[hidden]{display:none}
.chat-selection-target::after{content:"";position:absolute;right:11px;top:50%;width:7px;height:7px;border-right:1.7px solid currentColor;border-bottom:1.7px solid currentColor;transform:translateY(-65%) rotate(45deg);color:var(--muted);pointer-events:none}
.chat-selection-target select{appearance:none;-webkit-appearance:none;width:auto;min-width:136px;min-height:34px;padding:8px 30px 8px 11px;border-radius:12px;border:1px solid var(--line);background:var(--surface);color:var(--text);font:inherit;font-size:13px;line-height:1.6;cursor:pointer}
.chat-selection-target select:disabled{opacity:.55;cursor:not-allowed}
.chat-selection-target:has(select:disabled)::after{opacity:.55}
.chat-selection-close{display:inline-flex;align-items:center;justify-content:center;width:34px;height:34px;padding:0;border:1px solid var(--line);border-radius:12px;background:var(--surface);color:var(--muted);cursor:pointer;flex:0 0 auto}
.chat-selection-close:hover,.chat-selection-close:focus-visible{background:var(--surface2);color:var(--text)}
.chat-selection-close svg{width:16px;height:16px}
.chat-message-menu{position:fixed;left:12px;top:12px;z-index:80;display:grid;gap:8px;min-width:min(236px,calc(100vw - 20px));padding:10px;border-radius:16px;border:1px solid var(--line2);background:rgba(17,17,17,.96);box-shadow:0 22px 60px rgba(0,0,0,.35);backdrop-filter:blur(16px);transform-origin:top right}
.chat-message-menu[hidden]{display:none}
.chat-message-menu.is-open{animation:messageMenuIn .16s ease both}
.chat-message-menu.is-closing{animation:messageMenuOut .14s ease both;pointer-events:none}
.chat-reaction-menu{position:absolute;right:0;bottom:calc(100% + 8px);display:flex;align-items:center;gap:5px;max-width:min(344px,calc(100vw - 24px));padding:6px;border:1px solid var(--line2);border-radius:15px;background:inherit;box-shadow:0 14px 35px rgba(0,0,0,.2);animation:messageMenuIn .16s ease both;transition:width .2s ease}
.chat-reaction-menu-row{display:flex;gap:3px;max-width:250px;max-height:30px;overflow:hidden;transition:max-width .2s ease,max-height .22s ease,padding .2s ease}
.chat-reaction-menu.is-expanded .chat-reaction-menu-row{flex-wrap:wrap;max-width:292px;max-height:154px;overflow:auto;padding-right:2px;scrollbar-width:none}
.chat-reaction-menu.is-expanded .chat-reaction-menu-row::-webkit-scrollbar{display:none}
.chat-reaction-choice,.chat-reaction-more{display:inline-grid;place-items:center;width:30px;height:30px;padding:0;border:0;border-radius:10px;background:rgba(255,255,255,.07);font-size:18px;line-height:1;cursor:pointer;transition:transform .16s ease,background .16s ease}.chat-reaction-choice img{width:20px;height:20px;object-fit:contain}
.chat-reaction-choice:hover,.chat-reaction-choice:focus-visible,.chat-reaction-more:hover{background:rgba(255,255,255,.15);transform:scale(1.12)}
.chat-reaction-more{font-size:19px;color:var(--text);flex:0 0 auto}
.msg-reactions{position:relative;display:flex;flex:1 1 auto;flex-direction:row-reverse;align-items:center;gap:4px;min-width:0;max-width:220px;margin-left:auto;overflow-x:auto;overflow-y:hidden;scrollbar-width:none}
.msg-reactions.has-overflow{mask-image:linear-gradient(to right,transparent,#000 12px,#000 calc(100% - 12px),transparent);-webkit-mask-image:linear-gradient(to right,transparent,#000 12px,#000 calc(100% - 12px),transparent)}
.msg-reactions::-webkit-scrollbar{display:none}
.msg-reaction{display:inline-flex;align-items:center;gap:3px;flex:0 0 auto;height:24px;padding:2px 6px;border:1px solid var(--line);border-radius:999px;background:var(--surface);font-size:15px;line-height:1;cursor:pointer;animation:reactionPop .2s ease both;transition:background .16s ease,border-color .16s ease,transform .16s ease}.msg-reaction img{width:16px;height:16px;object-fit:contain}
.msg-reaction:hover{transform:translateY(-1px);background:var(--surface2)}
.msg-reaction:disabled{cursor:default}
.chat-reaction-menu[hidden]{display:none}
@keyframes reactionPop{0%{transform:scale(.65);opacity:0}100%{transform:scale(1);opacity:1}}
.chat-message-menu-actions{display:flex;align-items:center;flex-wrap:wrap;gap:6px}
.chat-message-menu-forward{display:grid;grid-template-columns:minmax(0,1fr) 36px;gap:6px;align-items:center}
.chat-message-menu-forward select{padding:8px 10px;border-radius:12px;min-height:36px}
.chat-message-menu-btn{display:inline-flex;align-items:center;justify-content:center;width:36px;height:36px;min-height:0;padding:0;border:1px solid var(--line);border-radius:12px;background:var(--surface);color:var(--text);cursor:pointer;transition:.2s;flex:0 0 auto}
.chat-message-menu-btn{text-decoration:none}
.chat-message-menu-btn:hover,.chat-message-menu-btn:focus-visible{background:var(--surface2)}
.chat-message-menu-btn:disabled{opacity:.45;pointer-events:none}
.chat-message-menu-btn svg{width:16px;height:16px}
.chat-message-menu-btn.danger{background:rgba(255,107,107,.12);color:#ffdada}
.chat-message-menu-btn.is-active{background:rgba(247,247,243,.16);color:#fff;border-color:rgba(247,247,243,.2)}
.chat-delete-dialog{position:absolute;inset:0;z-index:65;display:grid;place-items:center;padding:14px}
.chat-delete-dialog[hidden]{display:none}
.chat-delete-backdrop{position:absolute;inset:0;background:rgba(0,0,0,.42);backdrop-filter:blur(7px);border-radius:inherit}
.chat-delete-panel{position:relative;z-index:1;display:grid;gap:11px;width:min(312px,calc(100% - 28px));padding:14px;border-radius:16px;border:1px solid var(--line2);background:rgba(18,18,18,.96);box-shadow:0 24px 64px rgba(0,0,0,.38)}
.chat-delete-dialog.is-open .chat-delete-panel{animation:chatDeleteDialogIn .16s ease both}
.chat-delete-dialog.is-closing .chat-delete-panel{animation:chatDeleteDialogOut .14s ease both}
.chat-delete-copy{display:grid;gap:5px}
.chat-delete-copy strong{font-size:16px;line-height:1.2}
.chat-delete-copy span{font-size:12px;color:var(--muted);line-height:1.35}
.chat-delete-check{display:flex;align-items:flex-start;gap:8px;padding:9px;border-radius:12px;background:var(--surface);font-size:12px;line-height:1.35;color:var(--text);cursor:pointer}
.chat-delete-check input{width:16px;height:16px;margin:1px 0 0;min-height:0;flex:0 0 auto;accent-color:#ff7777}
.chat-delete-actions{display:flex;justify-content:flex-end;gap:7px}
.btn.danger{border-color:rgba(255,107,107,.28);background:rgba(255,107,107,.14);color:#ffdede}
.btn.danger:hover,.btn.danger:focus-visible{background:rgba(255,107,107,.2)}
.chat-overlay-open{overflow:hidden}
.chat-library-overlay,.chat-media-viewer{--chat-overlay-available-height:calc(100dvh - var(--site-header-height));--chat-overlay-pad-top:clamp(10px,3dvh,28px);--chat-overlay-pad-bottom:clamp(10px,3dvh,28px);--chat-overlay-pad-inline:clamp(10px,3vw,28px);position:fixed;top:var(--site-header-height);right:0;bottom:0;left:0;z-index:90;display:grid;place-items:center;min-height:0;padding:var(--chat-overlay-pad-top) var(--chat-overlay-pad-inline) var(--chat-overlay-pad-bottom);overflow:auto;overscroll-behavior:contain;box-sizing:border-box}
.chat-library-overlay[hidden],.chat-media-viewer[hidden]{display:none}
.chat-library-backdrop,.chat-media-viewer-backdrop{position:absolute;inset:0;z-index:0;background:rgba(7,7,7,.68);backdrop-filter:blur(10px);border-radius:0}
.chat-library-overlay{opacity:0;pointer-events:none;transition:opacity .24s ease}
.chat-library-overlay.is-open{opacity:1;pointer-events:auto}
.chat-library-backdrop{opacity:0;transition:opacity .24s ease}
.chat-library-overlay.is-open .chat-library-backdrop{opacity:1}
.chat-library-panel,.chat-media-viewer-dialog{position:relative;z-index:1;box-sizing:border-box;min-height:0}
.chat-library-panel{width:min(960px,100%);max-height:min(760px,calc(var(--chat-overlay-available-height) - var(--chat-overlay-pad-top) - var(--chat-overlay-pad-bottom)));margin:0;padding:18px;border-radius:28px;border:1px solid var(--line2);background:rgba(14,14,14,.96);box-shadow:0 32px 90px rgba(0,0,0,.4);display:grid;grid-template-rows:auto auto minmax(0,1fr);gap:14px;overflow:hidden;opacity:0;transform:translateY(18px) scale(.985);transition:opacity .24s ease,transform .24s ease}
.chat-library-overlay.is-open .chat-library-panel{opacity:1;transform:none}
.chat-library-head{display:flex;align-items:flex-start;justify-content:space-between;gap:12px}
.chat-library-copy{display:grid;gap:4px;min-width:0}
.chat-library-copy strong{font-size:18px;line-height:1.1}
.chat-library-copy span{font-size:13px;line-height:1.4;color:var(--muted)}
.chat-library-tabs{display:flex;flex-wrap:wrap;gap:8px}
.chat-library-tab{display:inline-flex;align-items:center;gap:10px;padding:10px 12px;border-radius:16px;border:1px solid var(--line);background:var(--surface);color:var(--text);cursor:pointer;min-height:44px}
.chat-library-tab.is-active{background:var(--surface2);border-color:var(--line2)}
.chat-library-tab-icon{display:inline-flex;align-items:center;justify-content:center;width:18px;height:18px;color:var(--chat-action)}
.chat-library-tab-icon svg{width:18px;height:18px}
.chat-library-tab-count{display:inline-flex;align-items:center;justify-content:center;min-width:22px;height:22px;padding:0 7px;border-radius:999px;background:rgba(255,255,255,.08);font-size:12px;color:var(--muted)}
.chat-library-list{display:grid;grid-template-columns:repeat(auto-fill,minmax(220px,1fr));grid-auto-rows:max-content;align-content:start;gap:12px;min-height:0;overflow:auto;padding-right:4px}
.chat-library-empty{grid-column:1/-1;align-self:start}
.chat-library-item{display:grid;grid-template-rows:minmax(0,1fr) auto auto;gap:10px;height:100%;min-height:0;padding:12px;border-radius:8px;border:1px solid var(--line);background:var(--surface)}
.chat-library-item.is-compact{grid-template-rows:auto auto auto;height:max-content;align-self:start}
.chat-library-item-preview{position:relative;display:grid;place-items:center;min-height:132px;padding:0;border-radius:8px;border:1px solid var(--line);background:rgba(0,0,0,.16);color:var(--text);text-decoration:none}
.chat-library-item-preview.is-visual{width:100%;cursor:pointer}
.chat-library-item-preview.is-visual:hover,.chat-library-item-preview.is-visual:focus-visible{border-color:var(--line2)}
.chat-library-item-preview img,.chat-library-item-preview video{display:block;width:100%;height:100%;max-height:180px;object-fit:cover}
.chat-library-preview-image{filter:blur(14px);transform:scale(1.06);transition:filter .28s ease,transform .28s ease}
.chat-library-item-preview.is-loaded .chat-library-preview-image{filter:blur(0);transform:none}
.chat-library-preview-play{position:absolute;inset:0;display:grid;place-items:center;color:#fff;background:rgba(0,0,0,.12);pointer-events:none}
.chat-library-preview-play svg{width:42px;height:42px;padding:9px;border-radius:50%;background:rgba(0,0,0,.54);box-sizing:border-box}
.chat-library-item-icon{display:inline-flex;align-items:center;justify-content:center;width:44px;height:44px;border-radius:8px;background:var(--chat-action-soft);color:var(--chat-action)}
.chat-library-item-icon svg{width:22px;height:22px}
.chat-library-item-preview.is-audio{min-height:0;height:auto;padding:8px;grid-template-rows:24px 34px;gap:5px;cursor:default;background:rgba(121,214,156,.08)}
.chat-library-audio-wave{display:block;width:100%;height:24px;color:var(--chat-action)}
.chat-library-item-preview.is-audio audio{display:block;width:100%;height:34px;min-height:34px}
.chat-library-item-preview.is-link{min-height:92px;background:var(--chat-action-soft)}
.chat-library-item-preview.is-file{min-height:116px;padding:10px;background:rgba(255,255,255,.025)}
.chat-library-file-sheet{display:grid;align-content:start;gap:6px;width:100%;height:100%;min-height:94px;padding:9px;border:1px solid var(--line);border-radius:6px;background:var(--surface2);box-sizing:border-box;overflow:hidden}
.chat-library-file-kind{font-size:10px;line-height:1;font-weight:800;color:var(--chat-action)}
.chat-library-file-text{max-height:62px;margin:0;overflow:hidden;white-space:pre-wrap;word-break:break-word;font:10px/1.25 ui-monospace,SFMono-Regular,Consolas,monospace;color:var(--muted)}
.chat-library-file-lines{display:grid;gap:6px;padding-top:4px}
.chat-library-file-lines i{display:block;height:3px;border-radius:2px;background:var(--line2)}
.chat-library-file-lines i:nth-child(2){width:78%}
.chat-library-file-lines i:nth-child(3){width:90%}
.chat-library-file-lines i:nth-child(4){width:58%}
.chat-library-item-copy{display:grid;gap:3px;min-width:0}
.chat-library-item-copy strong{font-size:14px;line-height:1.3;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
.chat-library-item-copy span{font-size:12px;color:var(--muted);overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
.chat-library-item-copy p{font-size:13px;line-height:1.4;color:var(--text);overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
.chat-library-item-actions{display:flex;align-items:center;gap:8px;min-width:0;flex-wrap:nowrap}
.chat-library-item-actions .btn{height:38px;min-height:38px;border-radius:8px}
.chat-library-jump{min-width:0;flex:1 1 auto;padding-inline:10px;white-space:nowrap}
.chat-library-download{width:38px;min-width:38px;padding:0;flex:0 0 38px}
.chat-library-download svg{width:18px;height:18px}
.chat-favorite-chip{display:inline-flex;align-items:center;justify-content:center;width:38px;height:38px;min-height:0;padding:0;border:1px solid var(--line);border-radius:8px;background:var(--surface);color:var(--muted);cursor:pointer;flex:0 0 38px}
.chat-favorite-chip svg{width:18px;height:18px;pointer-events:none}
.chat-favorite-chip.is-active{background:rgba(255,215,96,.12);border-color:rgba(255,215,96,.28);color:#ffd76a;box-shadow:inset 0 0 0 1px rgba(255,215,96,.06)}
.chat-media-viewer-dialog{width:min(1040px,100%);max-height:min(860px,calc(var(--chat-overlay-available-height) - var(--chat-overlay-pad-top) - var(--chat-overlay-pad-bottom)));margin:0;padding:16px;border-radius:30px;border:1px solid var(--line2);background:rgba(10,10,10,.97);box-shadow:0 32px 90px rgba(0,0,0,.44);display:grid;grid-template-rows:auto minmax(0,1fr) auto;gap:12px;overflow:hidden}
.chat-media-viewer-close{justify-self:end;display:inline-flex;align-items:center;justify-content:center;width:38px;height:38px;min-height:0;padding:0;border:1px solid var(--line);border-radius:14px;background:var(--surface);color:var(--text);cursor:pointer}
.chat-media-viewer-close svg{width:18px;height:18px}
.chat-media-viewer-stage{position:relative;display:grid;place-items:center;min-height:min(520px,max(180px,calc(var(--chat-overlay-available-height) - var(--chat-overlay-pad-top) - var(--chat-overlay-pad-bottom) - 132px)));max-height:100%;background:rgba(0,0,0,.18);overflow:hidden}
.chat-media-viewer-stage img{display:block;max-width:100%;max-height:min(720px,max(80px,calc(var(--chat-overlay-available-height) - var(--chat-overlay-pad-top) - var(--chat-overlay-pad-bottom) - 132px)));object-fit:contain}
.chat-media-viewer-stage .chat-media-viewer-blur{position:absolute;inset:0;z-index:0;width:100%;height:100%;max-width:none;max-height:none;object-fit:contain;filter:blur(16px);transform:scale(1.03);opacity:1;transition:opacity .32s ease,filter .32s ease;pointer-events:none;place-self:stretch;background:rgba(0,0,0,.18)}
.chat-media-viewer-image{position:relative;z-index:1;opacity:0;transition:opacity .24s ease}
.chat-media-viewer-video{position:relative;z-index:1;display:block;width:100%;height:min(720px,max(260px,calc(var(--chat-overlay-available-height) - var(--chat-overlay-pad-top) - var(--chat-overlay-pad-bottom) - 132px)));max-width:100%;max-height:min(720px,max(260px,calc(var(--chat-overlay-available-height) - var(--chat-overlay-pad-top) - var(--chat-overlay-pad-bottom) - 132px)));aspect-ratio:16/9;object-fit:contain;background:#000;border-radius:18px;opacity:0;transition:opacity .24s ease}
.chat-media-viewer-stage.is-loaded .chat-media-viewer-image{opacity:1}
.chat-media-viewer-stage.is-loaded .chat-media-viewer-video{opacity:1}
.chat-media-viewer-stage.is-loaded .chat-media-viewer-blur{opacity:0;filter:blur(0)}
.chat-media-viewer-stage.is-video .chat-media-viewer-blur{display:none}
.chat-media-viewer-meta{display:flex;align-items:center;justify-content:space-between;gap:12px;flex-wrap:wrap}
.chat-media-viewer-actions{display:flex;align-items:center;gap:8px;flex-wrap:wrap}
.chat-media-viewer-download{width:40px;justify-content:center;padding-inline:0}
.chat-media-viewer-copy{display:grid;gap:4px;min-width:0}
.chat-media-viewer-copy strong{font-size:16px;line-height:1.2}
.chat-media-viewer-copy span{font-size:13px;color:var(--muted)}
.chat-media-viewer-meta .btn.is-active{background:rgba(255,215,96,.16);border-color:rgba(255,215,96,.26)}
body.chat-screen .chat-library-overlay,
body.chat-screen .chat-media-viewer{position:fixed;border-radius:0;overflow:auto}
body.chat-screen .chat-library-backdrop,
body.chat-screen .chat-media-viewer-backdrop{border-radius:0}
.chat-composer{grid-template-columns:minmax(0,1fr);gap:8px}
.chat-compose-preview{display:grid;gap:10px;padding:12px;border-radius:20px;border:1px solid var(--chat-preview-border);background:var(--chat-preview-bg);transform-origin:bottom left;overflow:hidden;will-change:height,opacity,transform}
.chat-compose-preview.is-entering{animation:composeAttachmentIn .24s cubic-bezier(.2,.8,.2,1) both}
.chat-compose-preview.is-leaving{animation:composeAttachmentOut .18s ease both;pointer-events:none}
.chat-compose-preview.from-drop{border-color:rgba(119,190,255,.3);box-shadow:0 12px 34px rgba(119,190,255,.08)}
.chat-compose-preview.from-paste{border-color:rgba(166,224,137,.28);box-shadow:0 12px 34px rgba(166,224,137,.07)}
.chat-compose-preview.from-picker{border-color:var(--chat-preview-border)}
.chat-compose-preview[hidden]{display:none}
.chat-compose-preview-top{display:flex;align-items:flex-start;justify-content:space-between;gap:12px}
.chat-compose-preview-copy{display:grid;gap:3px;min-width:0}
.chat-compose-preview.is-media-only .chat-compose-preview-copy{display:none}
.chat-compose-preview.is-media-only .chat-compose-preview-top{justify-content:flex-end;}
.chat-compose-preview-title{font-size:14px;font-weight:700;line-height:1.2}
.chat-compose-preview-subtitle{font-size:12px;line-height:1.35;color:var(--muted)}
.chat-compose-preview-media{display:grid;gap:8px}
.chat-compose-preview-grid{display:grid;grid-template-columns:repeat(auto-fill,minmax(118px,1fr));gap:8px;max-width:min(100%,520px)}
.chat-compose-preview-grid>.chat-preview-file{min-width:0}
.chat-compose-preview-grid>.chat-preview-file .chat-preview-file-copy{min-width:0}
.chat-compose-preview-grid>.chat-preview-file .chat-preview-file-copy span{overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
.chat-compose-preview-grid>.chat-preview-file-image{display:block;position:relative;aspect-ratio:1.25;padding:0;border-radius:14px;overflow:hidden}
.chat-compose-preview-grid>.chat-preview-file-image img{width:100%;height:100%;max-width:none;border:0;border-radius:inherit;object-fit:cover}
.chat-compose-preview-grid>.chat-preview-file-image .chat-preview-file-copy{position:absolute;left:8px;bottom:8px;z-index:2}
.chat-compose-preview-grid>.chat-preview-file-image .chat-preview-file-copy strong{display:inline-flex;padding:4px 8px;border-radius:999px;background:rgba(0,0,0,.55);color:#fff;font-size:12px;line-height:1}
.chat-compose-preview-grid>.chat-preview-file-image .chat-preview-file-copy span{display:none}
.chat-composer.is-editing .chat-compose-preview{border-color:rgba(119,190,255,.24);background:rgba(119,190,255,.07)}
.chat-compose-preview-media img,.chat-compose-preview-media video{display:block;width:min(320px,100%);max-width:100%;height:clamp(150px,38vw,220px);object-fit:contain;border-radius:16px;border:1px solid var(--line);background:rgba(0,0,0,.24)}
.chat-compose-preview-grid>img,.chat-compose-preview-grid>video{width:100%;height:118px;object-fit:cover}
.chat-compose-preview-media audio{display:block;width:min(340px,100%);max-width:100%;min-height:40px}
.chat-compose-preview.has-audio-preview{gap:6px;padding:10px 12px;align-content:start}
.chat-compose-preview.has-audio-preview .chat-compose-preview-top{align-items:center}
.chat-compose-preview.has-audio-preview .chat-compose-preview-copy{gap:0}
.chat-compose-preview.has-audio-preview .chat-compose-preview-media{width:min(300px,100%);min-width:0;gap:0}
.chat-compose-preview.has-audio-preview .chat-compose-preview-media audio{width:100%;min-width:0;height:40px;min-height:40px}
.chat-preview-file{display:flex;align-items:center;gap:10px;padding:10px 12px;border-radius:16px;border:1px solid var(--line);background:var(--surface)}
.chat-preview-file-image{position:relative;overflow:hidden}
.chat-compose-preview-media .chat-preview-file-image img{width:112px;height:82px;max-width:112px;border-radius:12px;object-fit:cover;flex:0 0 auto}
.chat-compose-preview-grid>.chat-preview-file-image img{width:100%;height:100%;max-width:none;border:0;border-radius:inherit;object-fit:cover}
.chat-preview-file-icon{display:inline-flex;align-items:center;justify-content:center;width:36px;height:36px;border-radius:12px;background:var(--chat-action-soft);color:var(--chat-action);flex:0 0 auto}
.chat-preview-file-copy{display:grid;gap:2px;min-width:0}
.chat-preview-file-copy strong,.chat-attachment-caption{min-width:0;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
.chat-preview-file-copy span{font-size:12px;color:var(--muted)}
.chat-attachment-group{gap:8px;width:min(72vw,460px);max-width:100%}
.chat-attachment-group-grid{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));grid-auto-rows:132px;gap:4px;overflow:hidden;border-radius:16px}
.chat-attachment-group-item{min-width:0;min-height:0;overflow:hidden;background:rgba(0,0,0,.16)}
.chat-attachment-group-item>.chat-attachment-stack{height:100%;gap:0}
.chat-attachment-group-item>.chat-attachment-stack .chat-attachment-caption{display:none}
.chat-attachment-group .chat-image-link{width:100%;height:100%;aspect-ratio:auto;margin:0;border-radius:0;border:0}
.chat-attachment-group .chat-image{width:100%;height:100%;max-width:none;object-fit:cover;border:0;border-radius:0}
.chat-attachment-group .chat-video-wrap{width:100%;height:100%;max-width:none;border-radius:0}
.chat-attachment-group .chat-video{width:100%;height:100%;max-width:none;border-radius:0}
.chat-attachment-group .chat-file{width:100%;max-width:364px;min-height:48px;height:auto;border-radius:12px}
.chat-attachment-group.has-file-items .chat-attachment-group-grid{grid-auto-rows:auto;gap:6px;border-radius:0}
.chat-attachment-group.has-file-items .chat-attachment-group-item{background:transparent}
.chat-attachment-group.has-file-items .chat-attachment-group-item>.chat-attachment-stack{height:auto}
.chat-attachment-group.has-file-items .chat-attachment-group-item.is-file-item{overflow:visible}
.chat-attachment-group.has-file-items{width:min(72vw,420px)}
.chat-attachment-group.has-file-items .chat-file{min-height:42px;padding:8px 10px}
.chat-attachment-group.has-file-items .chat-file strong{font-size:13px}
.chat-group-image-file{position:relative;display:block;width:100%;height:100%;padding:0;overflow:hidden;border:0;border-radius:0;background:rgba(0,0,0,.16)}
.chat-group-image-file .chat-file-thumb{position:absolute;inset:0;z-index:1;width:100%;height:100%;border-radius:0;max-width:none;object-fit:cover}
.chat-group-image-file span{position:absolute;left:10px;bottom:10px;z-index:4;padding:4px 8px;border-radius:999px;background:rgba(0,0,0,.55);color:#fff}
.chat-attachment-group.group-count-1 .chat-attachment-group-grid{display:block;border-radius:16px}
.chat-attachment-group.group-count-1 .chat-attachment-group-item{height:auto;min-height:0}
.chat-attachment-group.group-count-1 .chat-image-link{aspect-ratio:4/3}
.chat-attachment-group.group-count-1 .chat-attachment-group-item.is-image-file{aspect-ratio:4/3}
.chat-attachment-group.group-count-2.all-landscape .chat-attachment-group-grid{grid-template-columns:minmax(0,1fr);grid-auto-rows:154px}
.chat-attachment-group.group-count-2:not(.all-landscape) .chat-attachment-group-grid{grid-template-columns:repeat(2,minmax(0,1fr));grid-auto-rows:248px}
.chat-attachment-group.group-count-3 .chat-attachment-group-grid{grid-template-columns:1.15fr .85fr;grid-template-rows:124px 124px}
.chat-attachment-group.group-count-3 .chat-attachment-group-item:first-child{grid-row:span 2}
.chat-attachment-group.group-count-4 .chat-attachment-group-grid{grid-template-columns:repeat(2,minmax(0,1fr));grid-auto-rows:132px}
.chat-attachment-group.group-count-5 .chat-attachment-group-grid,.chat-attachment-group.group-count-6 .chat-attachment-group-grid,.chat-attachment-group.group-count-7 .chat-attachment-group-grid,.chat-attachment-group.group-count-8 .chat-attachment-group-grid,.chat-attachment-group.group-count-9 .chat-attachment-group-grid,.chat-attachment-group.group-count-10 .chat-attachment-group-grid{grid-template-columns:repeat(3,minmax(0,1fr));grid-auto-rows:112px}
.chat-attachment-group.group-count-5 .chat-attachment-group-item:first-child,.chat-attachment-group.group-count-7 .chat-attachment-group-item:first-child{grid-column:span 2;grid-row:span 2}
.chat-attachment-group.has-file-items .chat-attachment-group-grid{grid-template-columns:minmax(0,1fr);grid-auto-rows:auto}
.chat-attachment-group.has-file-items .chat-attachment-group-item:first-child{grid-column:auto;grid-row:auto}
.chat-attachment-group.all-file-items{width:auto}
.chat-attachment-group.all-file-items .chat-attachment-group-grid{display:grid;grid-template-columns:minmax(0,1fr)!important;grid-template-rows:none!important;grid-auto-rows:auto;gap:8px;overflow:visible;border-radius:0}
.chat-attachment-group.all-file-items .chat-attachment-group-item{grid-column:auto!important;grid-row:auto!important}
.chat-attachment-group.all-file-items .chat-attachment-stack{gap:0}
.chat-attachment-group.all-file-items .chat-file{min-height:42px;padding:8px 10px;border-radius:12px}
.chat-recording-live{display:inline-flex;align-items:center;gap:10px;padding:10px 12px;border-radius:16px;border:1px solid rgba(255,107,107,.18);background:rgba(255,107,107,.08);color:var(--text)}
.chat-recording-dot{width:10px;height:10px;border-radius:50%;background:#ff6b6b;box-shadow:0 0 0 6px rgba(255,107,107,.16);animation:pulse 1.1s ease-in-out infinite}
.chat-preview-close{display:inline-flex;align-items:center;justify-content:center;width:30px;height:30px;min-height:0;padding:0;border:0;border-radius:50%;background:var(--chat-action-soft);color:var(--chat-action);cursor:pointer;flex:0 0 auto}
.chat-preview-close:hover{background:var(--chat-action-soft-hover)}
.chat-preview-close svg{width:16px;height:16px}
.chat-composer-anchor{position:relative}
.chat-emoji-picker{position:absolute;right:0;bottom:calc(100% + 10px);z-index:14;display:grid;grid-template-rows:auto minmax(0,1fr);gap:10px;width:min(360px,calc(100vw - 24px));height:356px;padding:12px;border-radius:24px;border:1px solid var(--line2);background:rgba(10,10,10,.96);box-shadow:0 28px 70px rgba(0,0,0,.34);overflow:hidden;transform-origin:bottom right}
.chat-emoji-picker[hidden]{display:none}
.chat-emoji-picker.is-open{animation:messageMenuIn .18s ease both}
.chat-emoji-picker.is-closing{animation:messageMenuOut .15s ease both;pointer-events:none}
.chat-emoji-tabs{display:flex;gap:8px;min-width:0;overflow-x:auto;padding-bottom:2px;scrollbar-width:thin}
.chat-emoji-tab{display:inline-flex;align-items:center;justify-content:center;flex:0 0 44px;height:44px;padding:0;border:1px solid var(--line);border-radius:16px;background:rgba(255,255,255,.04);color:var(--text);cursor:pointer;transition:background .2s ease,border-color .2s ease,transform .2s ease}
.chat-emoji-tab:hover{background:rgba(255,255,255,.08);transform:none}
.chat-emoji-tab.is-active{border-color:var(--line2);background:rgba(255,255,255,.1)}
.chat-emoji-tab img{display:block;width:24px;height:24px;object-fit:contain}
.chat-emoji-grid{display:grid;grid-template-columns:repeat(6,minmax(0,1fr));gap:8px;min-height:0;height:100%;overflow:auto;padding-right:2px;scrollbar-gutter:stable}
.chat-emoji-item{display:inline-flex;align-items:center;justify-content:center;aspect-ratio:1;width:100%;padding:0;border:1px solid transparent;border-radius:16px;background:rgba(255,255,255,.04);cursor:pointer;transition:background .2s ease,border-color .2s ease,transform .2s ease}
.chat-emoji-item:hover{background:rgba(255,255,255,.1);border-color:rgba(255,255,255,.08);transform:none}
.chat-emoji-item img{display:block;width:32px;height:32px;object-fit:contain;pointer-events:none}
.chat-composer-bar{display:grid;grid-template-columns:auto auto auto minmax(0,1fr) auto;align-items:center;padding:4px 6px;border-radius:22px;background:var(--chat-compose-bg);transition:box-shadow .18s ease,background-color .18s ease,transform .18s ease}
.chat-composer-bar:focus-within{border-color:var(--line2);box-shadow:0 0 0 3px rgba(255,255,255,.04)}
.chat-composer textarea{border:0;background:transparent;padding:9px 6px 9px 4px;min-height:22px;max-height:110px;border-radius:0;line-height:1.4;overflow-y:hidden}
.chat-composer textarea:focus{border-color:transparent;transform:none}
.chat-composer textarea::placeholder{color:var(--muted)}
.chat-compose-editor{position:relative;min-width:0;min-height:22px;max-height:110px;padding:9px;line-height:1.4;white-space:pre-wrap;overflow-y:auto;overflow-x:hidden;word-break:break-word;outline:none;caret-color:var(--text)}
.chat-compose-editor.is-empty::before{content:attr(data-placeholder);position:absolute;left:9px;right:9px;top:9px;display:block;line-height:1.4;color:var(--muted);pointer-events:none;user-select:none;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}
.chat-compose-editor.is-empty:focus::before{content:""}
.chat-compose-editor .chat-compose-emoji{display:inline-block;width:1.15em;height:1.15em;margin:0 .04em;line-height:1;vertical-align:-.17em;user-select:text;-webkit-user-select:text}
.chat-compose-editor .chat-compose-emoji img{display:block;width:100%;height:100%;object-fit:contain;pointer-events:none}
.chat-composer-actions{display:contents}
.chat-attach-menu{position:absolute;left:0;bottom:calc(100% + 8px);z-index:16;display:flex;gap:8px;padding:8px;border-radius:16px;border:1px solid var(--line2);background:rgba(10,10,10,.96);box-shadow:0 18px 44px rgba(0,0,0,.3);animation:messageMenuIn .16s ease both}
.chat-attach-menu[hidden]{display:none}
.chat-attach-choice{display:inline-flex;align-items:center;justify-content:center;width:38px;height:38px;padding:0;border:1px solid var(--line);border-radius:12px;background:var(--surface);color:var(--text);cursor:pointer}
.chat-attach-choice:hover,.chat-attach-choice:focus-visible{background:var(--surface2)}
.chat-attach-choice svg{width:19px;height:19px}
.chat-icon-btn,.chat-send-btn{display:inline-flex;align-items:center;justify-content:center;min-height:0}
.chat-icon-btn{width:36px;height:36px;padding:0;border:0;background:transparent;color:var(--chat-action);box-shadow:none}
.chat-icon-btn:hover{background:var(--chat-action-soft-hover);transform:none}
.chat-icon-btn:disabled{opacity:.38;cursor:default;background:transparent;color:var(--muted)}
.chat-icon-btn.is-recording{color:#ff4d4f;background:rgba(255,77,79,.18);box-shadow:0 0 0 3px rgba(255,77,79,.1)}
.chat-icon-btn.is-recording:hover,.chat-icon-btn.is-recording:focus-visible{background:rgba(255,77,79,.24);color:#ff4d4f}
.chat-icon-btn.is-active,.chat-icon-btn.is-open{background:var(--chat-action-soft-hover);color:var(--text)}
.chat-icon-btn svg,.chat-send-btn svg{width:18px;height:18px}
.chat-icon-btn.is-loading svg,.chat-send-btn.is-loading svg{opacity:0}
.chat-send-btn,.btn.chat-send-btn{width:36px;min-width:36px;max-width:36px;height:36px;min-height:36px;max-height:36px;padding:0!important;border:0;border-radius:999px;background:var(--chat-send-bg);color:var(--chat-send-fg);flex:0 0 auto;align-self:end;justify-self:end;gap:0;aspect-ratio:1/1;place-self: center;}
.chat-send-btn:hover{opacity:.94;transform:none}
.chat-send-btn:disabled{opacity:.7}
.chat-send-btn.is-loading{opacity:1}
.chat-send-btn.is-loading svg{visibility:hidden}
.chat-send-btn.is-loading::after{position:absolute;inset:0;margin:auto;width:14px;height:14px;border:2px solid rgba(255,255,255,.26);border-top-color:currentColor;border-right-color:currentColor;border-bottom-color:transparent;border-left-color:transparent;animation:spin .72s linear infinite}
.msg.with-visual{width:fit-content;max-width:min(84%,388px);padding:8px 8px 9px;gap:6px}
.msg.with-visual .msg-body{display:flex;justify-content:flex-start;line-height:0;border-radius:14px;overflow:hidden}
.msg.with-visual .msg-body>a{display:inline-block;max-width:100%}
.msg.with-visual .msg-meta{margin-top:5px}
.msg.with-audio{width:300px;max-width:min(82%,390px)}
.msg.forwarded-group{width:min(92%,560px);max-width:min(92%,560px)}
.chat-image-link{position:relative;display:block;width:min(72vw,372px);max-width:100%;aspect-ratio:4/3;border-radius:14px;border:1px solid var(--line);background:rgba(0,0,0,.16);overflow:hidden;contain:paint}
.chat-image{display:block;width:100%;height:100%;margin:0;border:0;border-radius:13px;background:transparent;object-fit:cover;filter:blur(18px);transform:scale(1.08);transition:filter .32s ease,transform .32s ease,opacity .22s ease;contain:paint}
.chat-image-link.is-preview-loaded .chat-image{filter:blur(0);transform:none}
.chat-image-download{position:absolute;right:8px;bottom:8px;z-index:4;display:inline-flex;align-items:center;justify-content:center;width:34px;height:34px;border-radius:999px;background:rgba(0,0,0,.58);color:#fff;opacity:0;transform:translateY(4px) scale(.96);transition:opacity .16s ease,transform .16s ease,background .16s ease;cursor:pointer;backdrop-filter:blur(8px)}
.chat-image-link:hover .chat-image-download,.chat-image-link:focus-within .chat-image-download{opacity:1;transform:none}
.chat-image-download:hover{background:rgba(0,0,0,.72)}
.chat-image-download svg{width:17px;height:17px}
.chat-video-wrap{position:relative;display:block;width:min(372px,100%);max-width:100%;border-radius:14px;overflow:hidden;background:#000;contain:paint}
.chat-video{display:block;width:100%;height:auto;max-width:100%;max-height:320px;margin:0;border:1px solid var(--line);border-radius:inherit;background:#000;overflow:hidden}
.chat-video-view-btn{position:absolute;right:10px;top:10px;z-index:3;display:inline-flex;align-items:center;justify-content:center;width:34px;height:34px;min-height:0;padding:0;border:1px solid rgba(255,255,255,.2);border-radius:999px;background:rgba(0,0,0,.52);color:#fff;box-shadow:0 10px 22px rgba(0,0,0,.24);cursor:pointer;opacity:0;transform:translateY(-2px);transition:opacity .16s ease,transform .16s ease,background .16s ease}
.chat-video-view-btn svg{width:18px;height:18px}
.chat-video-wrap:hover .chat-video-view-btn,.chat-video-view-btn:focus-visible{opacity:1;transform:none}
.chat-video-view-btn:hover{background:rgba(0,0,0,.68)}
.chat-attachment-stack{display:grid;gap:8px}
.chat-attachment-chip{
  display:inline-flex;
  align-items:center;
  gap:10px;
  min-height:36px;
  max-width:min(320px,100%);
  padding:8px 10px;
  border-radius:12px;
  border:1px solid var(--line);
  background:var(--surface);
  color:var(--text);
}
.chat-attachment-icon{
  display:inline-flex;
  align-items:center;
  justify-content:center;
  width:24px;
  height:24px;
  border-radius:8px;
  background:var(--chat-action-soft);
  color:var(--chat-action);
  flex:0 0 auto;
}
.chat-attachment-icon svg{width:14px;height:14px}
.chat-attachment-copy{display:grid;gap:2px;min-width:0}
.chat-attachment-copy span{
  font-size:11px;
  line-height:1.2;
  color:var(--muted);
  text-transform:uppercase;
  letter-spacing:.04em;
}
.chat-attachment-copy strong{
  font-size:13px;
  line-height:1.25;
  min-width:0;
  overflow:hidden;
  text-overflow:ellipsis;
  white-space:nowrap;
}
.chat-audio-attachment{display:grid;gap:8px;width:100%;max-width:100%;min-width:0}
.chat-audio-attachment audio{display:block;width:100%;min-width:0;height:40px}
.chat-attachment-caption,.chat-message-text{font-size:14px;line-height:1.45;color:var(--text);overflow-wrap:anywhere;user-select: text;}
body::selection { color: #fff; background-color: rgb(255, 132, 194);}
.chat-rich-text .chat-inline-emoji{display:inline-block;width:1.32em;height:1.32em;margin:0 .08em;vertical-align:-.24em;object-fit:contain;user-select:none;-webkit-user-select:none}
.chat-rich-text.is-emoji-only{display:flex;align-items:center;flex-wrap:wrap;gap:8px;line-height:1;font-size:0}
.chat-rich-text.is-emoji-only .chat-inline-emoji{margin:0;width:44px;height:44px;vertical-align:middle}
.chat-rich-text.is-emoji-count-1 .chat-inline-emoji{width:56px;height:56px}
.chat-rich-text.is-emoji-count-2 .chat-inline-emoji{width:50px;height:50px}
.chat-rich-text.is-emoji-count-3 .chat-inline-emoji{width:44px;height:44px}
.chat-rich-text.is-emoji-count-4 .chat-inline-emoji{width:38px;height:38px}
.msg.with-visual .chat-message-text,.msg.with-visual .chat-attachment-caption{padding-left:3px}
.chat-file{position:relative;display:inline-flex;align-items:center;gap:10px;min-height:54px;padding:8px 12px 8px 8px;border-radius:16px;background:var(--surface);border:1px solid var(--line);max-width:min(360px,100%);box-shadow:inset 0 1px 0 rgba(255,255,255,.04)}
.chat-file-preview{position:relative;display:grid;place-items:center;width:46px;height:46px;border-radius:13px;overflow:hidden;flex:0 0 auto;background:rgba(255,255,255,.045);border:1px solid rgba(255,255,255,.075);color:rgba(245,247,250,.62);box-shadow:inset 0 1px 0 rgba(255,255,255,.045)}
.chat-file-preview::before{content:"";position:absolute;inset:9px 12px;border-radius:5px 8px 5px 5px;background:linear-gradient(135deg,rgba(255,255,255,.13),rgba(255,255,255,.055));border:1px solid rgba(255,255,255,.28);box-shadow:inset 0 1px 0 rgba(255,255,255,.12)}
.chat-file-preview::after{content:"";position:absolute;right:12px;top:9px;width:10px;height:10px;border-left:1px solid rgba(255,255,255,.24);border-bottom:1px solid rgba(255,255,255,.24);border-radius:0 7px 0 3px;background:rgba(255,255,255,.16)}
.chat-file-preview>span{display:none}
.chat-file-preview-thumb::before,.chat-file-preview-thumb::after{display:none}
.chat-file-preview-thumb img{display:block;width:100%;height:100%;object-fit:cover;border-radius:inherit}
.chat-file-copy{display:grid;gap:3px;min-width:0}
.chat-file-type{width:max-content;min-width:0!important;padding:3px 7px;border-radius:999px;background:rgba(255,255,255,.08);border:1px solid rgba(255,255,255,.08);font-size:10px!important;font-weight:800;letter-spacing:.06em;color:rgba(255,255,255,.78)!important}
.chat-file.file-kind-docx .chat-file-type{background:rgba(99,133,184,.22);border-color:rgba(154,183,226,.18);color:rgba(198,216,246,.9)!important}
.chat-file.file-kind-xlsx .chat-file-type{background:rgba(72,137,104,.22);border-color:rgba(137,207,168,.18);color:rgba(190,235,209,.9)!important}
.chat-file.file-kind-pdf .chat-file-type{background:rgba(164,78,84,.24);border-color:rgba(231,150,154,.18);color:rgba(246,204,205,.92)!important}
.chat-file.file-kind-zip .chat-file-type{background:rgba(143,118,74,.23);border-color:rgba(224,194,141,.18);color:rgba(238,219,182,.9)!important}
.chat-file.file-kind-ico .chat-file-type{background:rgba(72,126,139,.22);border-color:rgba(144,205,217,.18);color:rgba(198,233,239,.9)!important}
.chat-file.file-kind-code .chat-file-type{background:rgba(120,104,155,.23);border-color:rgba(194,181,226,.18);color:rgba(222,214,245,.9)!important}
.chat-file.file-kind-generic .chat-file-type{background:rgba(130,140,155,.16);border-color:rgba(190,198,210,.12);color:rgba(218,224,232,.84)!important}
.chat-file-thumb{width:42px;height:42px;border-radius:10px;object-fit:cover;flex:0 0 auto;background:rgba(0,0,0,.2)}
.chat-file.has-image-thumb{overflow:hidden}
.chat-file.has-image-thumb .chat-file-thumb{position:relative;z-index:1}
.chat-file.chat-group-image-file.has-image-thumb{position:relative;display:block;width:100%;height:100%;min-height:0;padding:0;border:0;border-radius:0;background:rgba(0,0,0,.16);overflow:hidden}
.chat-file.chat-group-image-file.has-image-thumb .chat-file-thumb{position:absolute;inset:0;z-index:1;width:100%;height:100%;max-width:none;border-radius:0;object-fit:cover}
.chat-file.chat-group-image-file.has-image-thumb span{position:absolute;left:10px;bottom:10px;z-index:4;padding:4px 8px;border-radius:999px;background:rgba(0,0,0,.55);color:#fff;font-size:12px;line-height:1}
.chat-file.chat-group-image-file.has-image-thumb .chat-image-download{left:auto;right:8px;bottom:8px;z-index:5;padding:0;background:rgba(0,0,0,.58)}
.chat-file.chat-group-image-file.has-image-thumb:hover .chat-image-download,.chat-file.chat-group-image-file.has-image-thumb:focus-within .chat-image-download{opacity:1;transform:none}
.chat-file>span:not(.chat-file-copy):not(.chat-file-preview){font-size:12px;color:var(--muted);min-width:max-content;}
.chat-file strong{min-width:0;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
.chat-forward-group{display:grid;gap:8px;min-width:0;max-width:100%}
.chat-forward-comment{font-size:14px;line-height:1.45;color:var(--text);overflow-wrap:anywhere}
.chat-forward-single{display:grid}
.chat-forward-details{display:grid;gap:8px;min-width:0;max-width:100%}
.chat-forward-summary{display:flex;align-items:center;justify-content:space-between;gap:12px;padding:10px 12px;border-radius:14px;background:rgba(255,255,255,.045);border:1px solid rgba(255,255,255,.1);cursor:pointer;list-style:none}
.chat-forward-summary::-webkit-details-marker{display:none}
.chat-forward-summary-copy{display:grid;gap:2px;min-width:0}
.chat-forward-summary-copy strong{font-size:14px;line-height:1.2}
.chat-forward-summary-copy span{font-size:12px;color:var(--muted)}
.chat-forward-summary-toggle{display:inline-grid;align-items:center;font-size:12px;color:var(--muted);white-space:nowrap}
.chat-forward-toggle-collapse{display:none}
.chat-forward-details:not(.is-collapsed) .chat-forward-summary-toggle{color:var(--text)}
.chat-forward-details:not(.is-collapsed) .chat-forward-summary-preview{display:none}
.chat-forward-details:not(.is-collapsed) .chat-forward-toggle-expand{display:none}
.chat-forward-details:not(.is-collapsed) .chat-forward-toggle-collapse{display:inline}
.chat-forward-items{display:grid;gap:8px;min-width:0;max-width:100%;padding-top:0;overflow:hidden;max-height:1200px;opacity:1;transform:none;transition:max-height .26s ease,opacity .2s ease,transform .2s ease,padding-top .2s ease}
.chat-forward-details.is-collapsed .chat-forward-items{max-height:0;opacity:0;transform:translateY(-4px)}
.chat-forward-details:not(.is-collapsed) .chat-forward-items{padding-top:2px;overflow:visible;max-height:none}
.chat-forward-items.is-single{padding-top:0;overflow:visible;max-height:none;opacity:1;transform:none;transition:none}
.chat-forward-item{position:relative;display:grid;gap:5px;min-width:0;max-width:100%;padding:10px 22px 10px 14px;border-radius:14px;border-left:3px solid rgba(255,255,255,.18);background:rgba(255,255,255,.06)}
.chat-forward-item:hover{background:rgba(255,255,255,.1)}
.chat-forward-item.is-jumpable{cursor:pointer}
.chat-forward-author{font-size:12px;font-weight:700;color:rgba(247,247,243,.84)}
.chat-forward-body{display:grid;gap:6px;min-width:0;max-width:100%;padding-left:1px}
.chat-forward-item-meta{position:absolute;right:10px;bottom:8px;padding:2px 6px;border-radius:999px;background:rgba(0,0,0,.34);font-size:11px;line-height:1;color:rgba(247,247,243,.86);font-variant-numeric:tabular-nums;opacity:0;transform:translateY(3px);transition:opacity .18s ease,transform .18s ease;pointer-events:none}
.chat-forward-item:hover .chat-forward-item-meta,.chat-forward-item:focus-within .chat-forward-item-meta{opacity:1;transform:none}
.chat-forward-body .chat-attachment-stack,.chat-forward-body .chat-attachment-group,.chat-forward-body .chat-image-link,.chat-forward-body .chat-video-wrap,.chat-forward-body .chat-file{width:100%;max-width:100%}
.chat-forward-body .chat-image,.chat-forward-body .chat-video{max-width:100%;max-height:220px}
.chat-selection-mode .chat-messages,.chat-selection-mode .msg{cursor:pointer;user-select:none}
.chat-selection-mode .msg.is-selected{border-color:rgba(121,214,156,.4);background:rgba(121,214,156,.09)}
.msg.is-focused{border-color:rgba(255,215,96,.36);box-shadow:0 0 0 3px rgba(255,215,96,.12)}
body.chat-screen .chat-shell>section.panel .composer textarea{min-height:22px;max-height:110px}
.favorites-page{display:grid;gap:18px}
.favorites-tabs{display:flex;flex-wrap:wrap;gap:8px;padding:4px;border-radius:20px;background:rgba(255,255,255,.025)}
.favorites-tab{display:inline-flex;align-items:center;gap:10px;min-height:42px;padding:9px 13px;border-radius:16px;border:1px solid transparent;background:transparent;color:var(--muted);transition:background .18s ease,border-color .18s ease,color .18s ease,transform .18s ease}
.favorites-tab:hover{background:var(--surface);color:var(--text);transform:translateY(-1px)}
.favorites-tab.is-active{background:var(--surface2);border-color:var(--line2);color:var(--text);box-shadow:0 8px 24px rgba(0,0,0,.08)}
.favorites-tab-icon{display:inline-flex;align-items:center;justify-content:center;width:18px;height:18px;color:var(--chat-action)}
.favorites-tab-icon svg{width:18px;height:18px}
.favorites-grid{display:grid;grid-template-columns:repeat(auto-fill,minmax(280px,320px));justify-content:start;gap:14px;align-items:start}
.favorite-card{display:grid;grid-template-rows:auto auto auto;align-content:start;gap:12px;width:100%;max-width:320px;min-height:0;padding:14px;content-visibility:auto;contain-intrinsic-size:auto 230px;transition:transform .18s ease,border-color .18s ease,box-shadow .18s ease}
.favorite-card:hover{transform:translateY(-2px);border-color:var(--line2);box-shadow:0 18px 44px rgba(0,0,0,.12)}
.favorite-card-preview{display:grid;grid-template-columns:auto minmax(0,1fr);align-items:center;gap:10px;min-height:54px;padding:9px 10px;border-radius:14px;border:1px solid var(--line);background:rgba(0,0,0,.1);color:var(--text);text-decoration:none;overflow:hidden}
.favorite-card-preview.is-clickable{cursor:pointer}
.favorite-card-preview.is-clickable:hover{border-color:var(--line2);background:var(--surface2)}
.favorite-card-preview.is-media{grid-template-columns:minmax(0,1fr);padding:10px}
.favorite-card-preview-media{display:grid;gap:8px;min-width:0}
.favorite-card-preview-media img,.favorite-card-preview-media video{display:block;width:100%;height:170px;object-fit:cover;border-radius:12px;border:1px solid var(--line);background:rgba(0,0,0,.22)}
.favorite-card-preview-media audio{display:block;width:100%}
.favorite-card-icon{display:inline-flex;align-items:center;justify-content:center;width:32px;height:32px;border-radius:10px;background:var(--chat-action-soft);color:var(--chat-action);flex:0 0 auto}
.favorite-card-icon svg{width:18px;height:18px}
.favorite-card-preview-label{font-size:13px;line-height:1.35;color:var(--muted);overflow-wrap:anywhere}
.favorite-card-copy{display:grid;gap:4px;min-width:0;align-content:start}
.favorite-card-copy strong{font-size:16px;line-height:1.25}
.favorite-card-copy span{font-size:12px;color:var(--muted)}
.conv-item,.match,.photo-card,.tag-cluster{content-visibility:auto;contain-intrinsic-size:auto 180px}
.favorite-card-copy p{display:-webkit-box;margin:2px 0 0;font-size:14px;line-height:1.45;color:var(--text);overflow:hidden;overflow-wrap:anywhere;-webkit-box-orient:vertical;-webkit-line-clamp:3}
.favorite-card-actions{display:flex;align-items:center;flex-wrap:wrap;gap:8px;margin-top:auto;min-height:0}
.favorite-action-btn{
  display:inline-flex;
  align-items:center;
  justify-content:center;
  width:38px;
  height:38px;
  min-height:0;
  padding:0;
  border-radius:12px;
}
.favorite-action-btn svg{width:18px;height:18px}
.favorite-card-actions .favorite-action-btn{width:auto;max-width:100%;gap:8px;padding:0 12px;border:1px solid var(--line);background:var(--surface);color:var(--text);text-decoration:none;white-space:nowrap}
.favorite-card-actions .favorite-action-btn:hover{border-color:var(--line2);background:var(--surface2)}
.favorite-card-actions .favorite-open-btn{flex:1 1 auto}
.favorite-card-actions .favorite-external-btn{flex:0 1 auto}
.favorite-card-image{display:block;width:100%;height:170px;object-fit:cover;border-radius:12px;border:1px solid var(--line);background:rgba(0,0,0,.22)}
.favorite-person-card{grid-template-rows:auto auto;justify-self:start;width:fit-content;max-width:100%;contain-intrinsic-size:auto 132px}
.favorite-person-head{display:grid;grid-template-columns:auto minmax(0,1fr);align-items:center;gap:12px}
.favorite-person-avatar-link{display:inline-flex;border-radius:14px}
.favorite-person-avatar{width:52px;height:52px;border-radius:14px;object-fit:cover}
.favorite-person-summary{margin-top:2px}
.favorite-person-actions{display:flex;align-items:center;flex-wrap:wrap;gap:8px;margin-top:0}
.favorite-person-actions .favorite-action-btn{width:auto;gap:8px;padding:0 12px;color:var(--text);border:1px solid var(--line);background:var(--surface)}
@keyframes pulse{0%,100%{transform:scale(1);opacity:1}50%{transform:scale(.86);opacity:.7}}
@keyframes messageMenuIn{from{opacity:0;transform:translateY(6px) scale(.98)}to{opacity:1;transform:translateY(0) scale(1)}}
@keyframes conversationMuteOptionsIn{from{opacity:0;transform:translateY(-5px) scaleY(.92)}to{opacity:1;transform:translateY(0) scaleY(1)}}
@keyframes conversationMuteOptionsOut{from{opacity:1;transform:translateY(0) scaleY(1)}to{opacity:0;transform:translateY(-5px) scaleY(.92)}}
@keyframes messageMenuOut{from{opacity:1;transform:translateY(0) scale(1)}to{opacity:0;transform:translateY(5px) scale(.985)}}
@keyframes composeAttachmentIn{from{height:0;opacity:0;transform:translateY(8px) scale(.985)}to{height:var(--compose-preview-height);opacity:1;transform:none}}
@keyframes composeAttachmentOut{from{height:var(--compose-preview-height);opacity:1;transform:none}to{height:0;opacity:0;transform:translateY(8px) scale(.985)}}
@keyframes chatDropCardIn{from{opacity:0;transform:translateY(10px) scale(.98)}to{opacity:1;transform:none}}
@keyframes chatDropPulse{0%,100%{filter:brightness(1)}50%{filter:brightness(1.08)}}
@keyframes chatMessageMineIn{from{opacity:0;transform:translateY(16px) scale(.985)}to{opacity:1;transform:none}}
@keyframes chatMessagePeerIn{from{opacity:0;transform:translateX(-18px) scale(.985)}to{opacity:1;transform:none}}
@keyframes chatMessageOut{from{opacity:1;transform:none;max-height:420px;margin-top:8px}to{opacity:0;transform:translateY(-8px) scale(.985);max-height:0;margin-top:0;padding-top:0;padding-bottom:0}}
@keyframes chatDeleteDialogIn{from{opacity:0;transform:translateY(10px) scale(.98)}to{opacity:1;transform:none}}
@keyframes chatDeleteDialogOut{from{opacity:1;transform:none}to{opacity:0;transform:translateY(8px) scale(.985)}}
@media(max-width:1024px){.chat-shell{grid-template-columns:1fr;grid-template-rows:minmax(168px,27svh) minmax(0,1fr)}.chat-library-panel,.chat-media-viewer-dialog{width:100%;margin-top:0}.favorites-grid{grid-template-columns:repeat(auto-fill,minmax(240px,320px))}}
@media(max-width:760px){.chat-sidebar,.chat-main{padding:12px}.chat-selection-bar{align-items:stretch;flex-wrap:wrap}.chat-selection-copy{width:100%}.chat-selection-copy strong{width:max-content;max-width:100%}.chat-selection-actions{justify-content:stretch;width:100%}.chat-selection-target{min-width:0;flex:1 1 100%}.chat-selection-actions .btn,.chat-selection-target select{width:100%}.chat-selection-close{margin-left:auto}.chat-message-menu{min-width:min(220px,calc(100vw - 16px));padding:9px}.chat-message-menu-actions{gap:5px}.chat-message-menu-forward{grid-template-columns:minmax(0,1fr) 34px}.chat-drop-zones{grid-template-columns:minmax(0,1fr);gap:10px}.chat-compose-preview{padding:10px}.chat-emoji-picker{left:0;right:0;width:auto;height:320px;padding:10px;border-radius:20px}.chat-emoji-grid{grid-template-columns:repeat(5,minmax(0,1fr));gap:7px}.chat-emoji-item img{width:30px;height:30px}.chat-composer-bar{grid-template-columns:auto auto auto minmax(0,1fr) auto;gap:2px}.chat-icon-btn,.chat-send-btn,.chat-message-menu-btn{width:34px;height:34px}.chat-icon-btn svg,.chat-send-btn svg,.chat-message-menu-btn svg{width:17px;height:17px}.msg-menu-trigger{width:22px;height:22px}.msg.with-visual,.msg.with-audio,.msg.forwarded-group,.interface-preview-chat .msg{max-width:90%}.chat-compose-preview-media img,.chat-compose-preview-media video,.chat-compose-preview-media audio,.chat-video,.chat-file{width:100%}.chat-image{width:auto;max-width:100%;height:auto}.chat-library-panel,.chat-media-viewer-dialog{padding:14px;border-radius:24px}.chat-library-tabs,.favorites-tabs{display:grid;grid-template-columns:repeat(2,minmax(0,1fr))}.chat-library-list,.favorites-grid{grid-template-columns:minmax(0,1fr)}.chat-media-viewer-meta{align-items:flex-start}.interface-preview-shell{padding:12px}.interface-preview-topbar{gap:10px}.interface-preview-chip{width:100%;justify-content:flex-start}}

/* smartphone refinements */
body{padding-bottom:env(safe-area-inset-bottom)}
.page{padding-bottom:calc(42px + env(safe-area-inset-bottom))}
input,textarea,select{min-height:48px}
textarea{min-height:120px}
.page-title{font-size:clamp(30px,7vw,44px)!important;line-height:1.02;letter-spacing:-.05em;margin:8px 0 0}
.page-subtitle{max-width:62ch;margin-top:10px}
.summary-list{display:grid;gap:12px;padding:0 0 0 20px;color:var(--muted)}
.summary-list strong{color:var(--text)}
.summary-list li{line-height:1.55}
.hero{align-items:stretch}
.hero .inner{height:100%}
.home-demo{position:relative;display:grid;grid-template-rows:auto minmax(0,1fr);gap:14px;min-width:0;overflow:hidden}
.home-demo-tabs{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:8px;padding:5px;border-radius:18px;background:rgba(255,255,255,.035)}
.home-demo-tab{min-width:0;min-height:38px;padding:0 10px;border:0;border-radius:14px;background:transparent;color:var(--muted);font-weight:700;font-size:13px;cursor:pointer;transition:background .2s ease,color .2s ease,transform .2s ease}
.home-demo-tab:hover,.home-demo-tab.is-active{background:var(--surface2);color:var(--text);transform:none}
.home-demo-view{display:grid;gap:12px;min-width:0;align-content:start}
.home-demo-view[hidden]{display:none}
.home-demo-label{font-size:13px;font-weight:700;color:var(--text)}
.home-demo-found{margin-top:2px;color:var(--muted)}
.home-demo-tags{display:flex;flex-wrap:wrap;gap:8px}.home-demo-tags .tag{padding:7px 10px}
.home-demo-results{display:grid;gap:10px;min-width:0}
.home-demo-person{display:grid;grid-template-columns:auto minmax(0,1fr) auto;gap:4px 10px;align-items:center;padding:12px 14px;border-radius:18px;cursor:pointer}
.home-demo-person.is-active{background:rgba(255,255,255,.08);border-color:var(--line2)}
.home-demo-avatar{display:inline-flex;align-items:center;justify-content:center;width:44px;height:44px;min-height:0;padding:0;border:0px solid var(--line);border-radius:14px;background:rgba(255,255,255,.055);overflow:hidden;cursor:pointer;flex:0 0 auto;transition:border-color .2s ease,transform .2s ease,background .2s ease}
.home-demo-avatar:hover,.home-demo-avatar:focus-visible{border-color:var(--line2);background:rgba(255,255,255,.09);transform:translateY(-1px);outline:none}
.home-demo-avatar img{display:block;width:100%;height:100%;object-fit:cover}
.home-demo-person-copy{display:grid;gap:4px;min-width:0}.home-demo-person .hint-online,.home-demo-person .small{min-width:0}.home-demo-person .small{overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
.home-demo-person .btn{grid-column:3;grid-row:1;align-self:center;white-space:nowrap}
.home-demo-chat-head{display:grid;grid-template-columns:auto minmax(0,1fr);align-items:center;padding-bottom:8px}.home-demo-chat-head .hint-online{font-size:12px}
.home-demo-chat-empty{min-height:282px;place-content:center;justify-items:start;padding:4px 0}
.home-demo-chat-empty .chat-empty-title{font-size:clamp(22px,3vw,30px)}
.home-demo-chat-active{display:grid;gap:12px;min-width:0}
.home-demo-chat-active[hidden],.home-demo-chat-empty[hidden]{display:none}
.home-demo-messages{min-height:154px;max-height:176px;margin-top:0;padding:4px 4px 4px 0;gap:8px;align-content:start}
.home-demo-messages .msg{max-width:92%;padding:10px 12px;border-radius:16px;font-size:13px;line-height:1.45}
.home-demo-messages .msg.with-visual{padding:6px}.home-demo-chat-image{width:min(210px,100%);max-height:138px;border-radius:12px;cursor:pointer}
.home-demo-composer{margin-top:0}.home-demo .chat-composer-bar{border:1px solid var(--line);background:rgba(255,255,255,.055)}
.home-demo .chat-compose-editor{min-height:20px;max-height:76px;font-size:13px}.home-demo .chat-icon-btn,.home-demo .chat-send-btn,.home-demo .btn.chat-send-btn{width:34px;height:34px;min-width:34px;max-width:34px;min-height:34px;max-height:34px}
.home-demo-emoji-picker{right:0;bottom:calc(100% + 8px);grid-template-rows:minmax(0,1fr);width:min(284px,calc(100vw - 40px));height:218px;padding:10px;border-radius:20px;z-index:8}.home-demo-emoji-picker .chat-emoji-grid{grid-template-columns:repeat(6,minmax(0,1fr));gap:7px}.home-demo-emoji-picker .chat-emoji-item{border-radius:13px}.home-demo-emoji-picker .chat-emoji-item img{width:28px;height:28px}
.home-demo-photo-viewer{position:absolute;inset:0;z-index:5;display:grid;place-items:center;padding:18px;border-radius:inherit;background:rgba(8,8,8,.54);backdrop-filter:blur(10px);opacity:1}
.home-demo-photo-viewer[hidden]{display:none}
.home-demo-photo-viewer.is-closing{pointer-events:none}
.home-demo-photo-dialog{position:relative;display:grid;justify-items:center;gap:10px;width:min(300px,100%);padding:12px;border:1px solid var(--line2);border-radius:24px;background:rgba(17,17,17,.94);box-shadow:0 22px 60px rgba(0,0,0,.32);transform-origin:center;will-change:transform,opacity}
.home-demo-photo-dialog.is-media{width:min(360px,100%)}
.home-demo-photo-stage{position:relative;width:100%;aspect-ratio:1/1;border-radius:18px;border:1px solid var(--line);background:rgba(0,0,0,.18);overflow:hidden}
.home-demo-photo-stage.is-media{aspect-ratio:4/3}
.home-demo-photo-stage img{position:absolute;inset:0;display:block;width:100%;height:100%;object-fit:cover;border:0;border-radius:0}
.home-demo-photo-stage.is-media .home-demo-photo-main{object-fit:contain;background:rgba(0,0,0,.28)}
.home-demo-photo-stage.is-media .home-demo-photo-blur{object-fit:cover}
.home-demo-photo-blur{z-index:0;filter:blur(8px);transform:scale(1.05);opacity:1;transition:opacity .32s ease,filter .32s ease}
.home-demo-photo-main{z-index:1;opacity:0;transition:opacity .24s ease}
.home-demo-photo-stage.is-loaded .home-demo-photo-main{opacity:1}
.home-demo-photo-stage.is-loaded .home-demo-photo-blur{opacity:0;filter:blur(0)}
.home-demo-media-stage{position:relative;display:block;width:min(210px,100%);max-width:100%;max-height:138px;overflow:hidden;border-radius:12px;background:rgba(0,0,0,.18)}
.home-demo-media-stage img{display:block;width:100%;max-width:100%;max-height:138px;object-fit:cover}
.home-demo-media-preview{position:absolute;inset:0;height:100%;filter:blur(8px);transform:scale(1.05);transition:opacity .18s ease}
.home-demo-media-main{position:relative;z-index:1;opacity:0;filter:none;transform:none;transition:opacity .18s ease}
.home-demo-media-stage.is-loaded .home-demo-media-main{opacity:1}
.home-demo-media-stage.is-loaded .home-demo-media-preview{opacity:0}
.home-demo-media-stage.is-error .home-demo-media-main{display:none}
.home-demo-media-stage.is-error .home-demo-media-preview{filter:none;transform:none}
.chat-messages .msg{touch-action:pan-y;-webkit-touch-callout:none}
/* Category disclosure is driven by a single JS opacity/translate transition. */
.profile-tag-card-grid,.profile-tag-category,.profile-tag-category-body,.profile-tag-pill{animation:none!important}
.profile-tag-card-grid{transition:none!important}
.profile-tag-category-body{transition:none!important}
@media(prefers-reduced-motion:reduce){.profile-tag-category-body{transition:none!important}}
.home-demo-photo-dialog strong{font-size:15px}.home-demo-photo-close{position:absolute;right:10px;top:10px;z-index:10;background:rgba(0,0,0,.45)}
.searchbar{grid-template-columns:minmax(0,1.25fr) minmax(190px,.75fr) auto;align-items:end}
.searchbar .btn.primary{display:inline-flex}
.search-layout,.favorites-page,.moderation-page{gap:18px}
.search-page-head{display:grid;gap:18px}
.search-sidebar-card{align-self:start}
.match,.favorite-card,.section-card,.settings-stat-card,.settings-fact-row,.settings-insight-item,.selectable-row,.switch-row{overflow:hidden}
.site-nav-toggle{display:none;align-items:center;justify-content:center;width:44px;height:44px;padding:0;border:1px solid var(--line);border-radius:16px;background:var(--surface);color:var(--text);cursor:pointer;transition:background-color .2s ease,border-color .2s ease,transform .2s ease}
.site-nav-toggle:hover,.site-nav-toggle:focus-visible{background:var(--surface2);border-color:var(--line2);outline:none;transform:none}
.site-nav-toggle svg{width:18px;height:18px}
.chat-sidebar-backdrop{display:none;margin:0;padding:0;border:0;outline:none;background:transparent;-webkit-appearance:none;appearance:none}
.chat-sidebar-close,.chat-mobile-toggle{display:none}
.chat-pane-head-side{display:flex;align-items:center;justify-content:flex-end;gap:8px}
.chat-main-intro{display:flex;align-items:flex-start;gap:12px;min-width:0;flex:1 1 auto}
.chat-main-intro .chat-peer{flex:1 1 auto}

@media(max-width:980px){
  .hero{grid-template-columns:minmax(0,1fr)}
  .settings-layout{gap:14px}
  .settings-sidebar{display:grid;gap:12px}
  .settings-nav{display:grid;grid-auto-flow:column;grid-auto-columns:minmax(144px,1fr);overflow:auto;padding-bottom:4px;scrollbar-width:none}
  .settings-nav::-webkit-scrollbar{display:none}
}

@media(max-width:900px){
  :root{--site-header-height:66px}
  .site-header{padding:12px 0}
  .site-header-inner{position:relative;grid-template-columns:minmax(0,1fr) auto;gap:12px;justify-items:stretch}
  .site-nav-toggle{display:inline-flex}
  body.has-js .site-nav{display:none;position:absolute;top:calc(100% + 8px);right:0;left:auto;grid-column:auto;gap:10px;max-height:min(72svh,520px);padding:14px;opacity:0;overflow:auto;pointer-events:none;transform:translateY(-10px) scale(.98);transform-origin:top right;transition:opacity .24s ease,transform .24s ease;border-radius:24px;border:1px solid var(--line2);background:rgba(10,10,10,.94);box-shadow:0 24px 70px rgba(0,0,0,.28)}
  body.has-js.site-nav-open .site-nav{display:grid;opacity:1;pointer-events:auto;transform:none}
  body.has-js .site-nav a{display:flex;align-items:center;justify-content:space-between;gap:12px;min-height:48px;padding:0 14px;border:1px solid var(--line);background:rgba(255,255,255,.04);color:var(--text)}
  body.has-js .site-nav .btn{width:100%}
  body.has-js .site-nav .nav-badge{margin-left:auto}
}

@media(max-width:760px){
  .shell{width:calc(100% - 16px)}
  .site-header{position:fixed;top:0;left:0;right:0;z-index:70}
  .brand{min-width:0}
  .brand span:last-child{min-width:0}
  .page{padding-top:14px;padding-bottom:calc(28px + env(safe-area-inset-bottom))}
  .panel,.form-card,.profile-box,.match,.favorite-card{padding:16px}
  .hero{padding:20px;gap:16px}
  .hero h1,.panel h1,.page-title{font-size:clamp(28px,9.5vw,38px)!important}
  .lead{font-size:16px;line-height:1.55}
  .actions{display:grid;grid-template-columns:minmax(0,1fr);align-items:stretch}
  .actions>*{width:100%}
  .actions form{display:block;width:100%}
  .actions .btn, .actions form .btn{width:100%}
  .row,.inline-form{align-items:stretch}
  .chips{gap:8px}
  .chip,.tag{display:inline-flex;align-items:center;min-height:38px}
  .searchbar,.grid2,.grid3,.dash,.settings-section-split{grid-template-columns:minmax(0,1fr)}
  .match-top,.section-head,.selectable-row,.settings-fact-row,.interface-preview-topbar{display:grid}
  .pill{justify-self:flex-start}
  .selectable-row input[type="checkbox"]{justify-self:start}
  .favorites-tabs,.chat-library-tabs{grid-template-columns:repeat(2,minmax(0,1fr))}
  .settings-nav{grid-auto-columns:minmax(132px,76vw)}
  .toast{left:16px;right:16px;bottom:calc(14px + env(safe-area-inset-bottom))}
  .auth{min-height:auto}
  .auth .form-card{margin-top:4px}
  .email-verification-actions{flex-direction:column;align-items:stretch}
  .email-verification-actions form,.email-verification-actions .btn{width:100%}
  .search-sidebar-card .profile-head.compact{flex-wrap:wrap}
  .search-sidebar-card .profile-head.compact>div{min-width:0}
  .settings-content .btn.primary,.settings-content .btn.small{width:100%}
  .chat-peer-link{align-items:center}
  body.chat-screen.has-js .chat-shell{grid-template-columns:minmax(0,1fr);grid-template-rows:minmax(0,1fr)}
  body.chat-screen.has-js .chat-shell>aside.panel{position:fixed;top:calc(10px + env(safe-area-inset-top));left:10px;bottom:calc(10px + env(safe-area-inset-bottom));width:min(340px,calc(100vw - 20px));z-index:72;transform:translateX(calc(-100% - 22px));opacity:0;pointer-events:none;transition:transform .3s ease,opacity .24s ease,box-shadow .3s ease;box-shadow:0 32px 90px rgba(0,0,0,.42),inset 0 1px 0 rgba(255,255,255,.04);border-radius:30px;overflow:hidden;border:1px solid var(--line2);background:var(--glass-bg);-webkit-backdrop-filter:blur(22px) saturate(118%);backdrop-filter:blur(22px) saturate(118%);isolation:isolate}
  body.chat-screen.has-js .chat-shell>section.panel{min-height:0;transition:filter .3s ease,opacity .3s ease,transform .3s ease}
  body.chat-screen.has-js .chat-sidebar-backdrop{display:block;position:fixed;inset:0;z-index:71;margin:0;padding:0;border:0;outline:none;background:rgba(10,10,10,.58);-webkit-backdrop-filter:blur(16px) saturate(108%);backdrop-filter:blur(16px) saturate(108%);opacity:0;pointer-events:none;transition:opacity .28s ease}
  body.chat-screen.chat-sidebar-open .chat-sidebar-backdrop{opacity:1;pointer-events:auto}
  body.chat-screen.chat-sidebar-open .chat-shell>aside.panel{transform:none;opacity:1;pointer-events:auto}
  body.chat-screen.chat-sidebar-open .chat-shell>section.panel{filter:blur(10px) saturate(.88);opacity:.38;transform:scale(.985)}
  .chat-sidebar-close,.chat-mobile-toggle{display:inline-flex;align-items:center;justify-content:center}
  .chat-sidebar-close,.chat-mobile-toggle,.site-nav-toggle{min-height:0}
  .chat-sidebar-close{width:38px;height:38px;padding:0;border:1px solid var(--line);border-radius:14px;background:var(--surface);color:var(--text);cursor:pointer;flex:0 0 auto}
  .chat-sidebar-close svg{width:18px;height:18px}
  .chat-main-head{align-items:flex-start}
  .chat-peer .avatar-md{width:48px;height:48px;border-radius:14px}
  .chat-actions{justify-content:flex-end;gap:6px;align-self: center;}
  .chat-head-icon-btn{width:36px;height:36px;border-radius:13px}
  .chat-head-icon-btn.chat-mobile-toggle{padding:0}
  .chat-send-btn,.btn.chat-send-btn{width:34px;min-width:34px;max-width:34px;height:34px;min-height:34px;max-height:34px;place-self: center;}
  body.chat-screen .site-header{display:block}
  body.chat-screen .page.chat-page{padding-top:10px}
  .chat-library-overlay,.chat-media-viewer{--chat-overlay-pad-top:max(10px,env(safe-area-inset-top));--chat-overlay-pad-bottom:max(10px,env(safe-area-inset-bottom));display:grid;place-items:center;padding:var(--chat-overlay-pad-top) max(10px,env(safe-area-inset-right)) var(--chat-overlay-pad-bottom) max(10px,env(safe-area-inset-left))}
  .chat-library-panel,.chat-media-viewer-dialog{width:min(960px,calc(100vw - 20px));max-width:100%;max-height:calc(var(--chat-overlay-available-height) - env(safe-area-inset-top) - env(safe-area-inset-bottom) - 20px);margin:0;padding:16px 14px calc(16px + env(safe-area-inset-bottom));border-radius:24px;justify-self:center;align-self:center}
  .chat-library-head{display:grid;grid-template-columns:minmax(0,1fr) auto;align-items:start;gap:12px}
  .chat-library-head .chat-preview-close{grid-column:2;grid-row:1;justify-self:end;align-self:start}
  .chat-media-viewer-meta{display:grid}
  .chat-media-viewer-stage{min-height:min(180px,40dvh)}
  .chat-compose-preview-media img,.chat-compose-preview-media video,.chat-compose-preview-media audio,.chat-video,.chat-file{width:100%}
}
.bg-gallery{display:grid;grid-template-columns:repeat(auto-fill,minmax(140px,1fr));gap:12px}
.bg-card{position:relative;display:grid;gap:8px;padding:10px;border-radius:18px;border:1px solid var(--line);background:rgba(255,255,255,.03);cursor:pointer;transition:.2s ease;min-width:0}
.bg-card:hover{border-color:var(--line2);background:rgba(255,255,255,.06)}
.bg-card input{position:absolute;opacity:0;pointer-events:none}
.bg-thumb{border-radius:14px;aspect-ratio:4/3;background:linear-gradient(135deg,rgba(255,255,255,.06),rgba(255,255,255,.02));border:1px solid var(--line);background-size:cover;background-position:center;display:block;width:100%;overflow:hidden;text-align:center}
.bg-thumb-none{display:grid;place-items:center;color:var(--muted);font-size:12px;line-height:1.2;text-transform:uppercase;letter-spacing:.08em;padding:8px;word-break:break-word}
.bg-caption{font-size:12px;color:var(--muted)}
.bg-card input:checked + .bg-thumb{outline:2px solid rgba(255,255,255,.6);outline-offset:2px}
.bg-card input:checked ~ .bg-caption{color:var(--text)}
.bg-card-custom.is-empty .bg-thumb{display:grid;place-items:center;color:var(--soft);font-size:12px;text-transform:uppercase;letter-spacing:.08em}
.bg-upload{display:flex;gap:14px;align-items:center;justify-content:space-between;margin-top:14px;padding:12px;border-radius:16px;border:1px dashed var(--line);background:rgba(255,255,255,.03)}
.bg-upload input[type="file"]{max-width:280px}
.bg-sliders{display:grid;gap:12px;margin-top:14px}
.range-row{display:grid;grid-template-columns:160px 1fr auto;gap:12px;align-items:center}
.range-row span{color:var(--muted);font-size:13px}
.range-row input[type="range"]{width:100%}
.range-value{font-size:12px;color:var(--muted);min-width:46px;text-align:right}
body.has-bg::before{content:"";position:fixed;inset:0;background-image:var(--user-bg-image);background-size:cover;background-position:center;background-repeat:no-repeat;z-index:0}
body.has-bg.has-bg-blur::before{inset:calc(0px - var(--user-bg-blur) - var(--user-bg-blur) - var(--user-bg-blur));filter:blur(var(--user-bg-blur))}
body.has-bg::after{content:"";position:fixed;inset:0;background:rgba(12,12,12,var(--user-bg-dim));z-index:0}
body.has-bg > :not(.site-header):not(.eva-fab):not(.eva-widget):not(.eva-widget-backdrop){position:relative;z-index:1}
body.has-bg > .profile-photo-viewer,
body.has-bg > .profile-cropper,
body.has-bg > .chat-library-overlay,
body.has-bg > .chat-media-viewer{
  position:fixed;
  top:var(--site-header-height);
  right:0;
  bottom:0;
  left:0;
}
body.has-bg > .profile-photo-viewer{z-index:80}
body.has-bg > .profile-cropper{z-index:110}
body.has-bg > .chat-library-overlay,
body.has-bg > .chat-media-viewer{z-index:90}
body.has-bg{--glass-bg:rgba(18,18,18,.72);--header-surface:rgba(12,12,12,.62);--surface:rgba(255,255,255,.08);--surface2:rgba(0,0,0,.12);--line:rgba(255,255,255,.08);--line2:rgba(255,255,255,.18)}
@media(max-width:760px){.bg-upload{flex-direction:column;align-items:flex-start}.range-row{grid-template-columns:1fr}.range-value{text-align:left}}

.onboarding-shell{display:grid;grid-auto-rows:max-content;align-content:start;gap:14px;width:min(860px,100%);padding:22px;margin:0 auto}
.onboarding-shell>.onboarding-head{order:1}
.onboarding-shell>.flash{order:2;align-self:start;width:100%;height:auto;min-height:0;margin:0;padding:11px 14px;line-height:1.45}
.onboarding-shell>.profile-tag-editor{order:3}
.onboarding-validation[hidden]{display:none}
.onboarding-validation{margin:0;padding:11px 14px;line-height:1.45}
.onboarding-head{display:grid;grid-template-columns:minmax(0,1fr) auto;grid-template-areas:"eyebrow eyebrow" "title count" "rule rule";align-items:center;gap:6px 16px}
.onboarding-head h1{grid-area:title;font-size:clamp(30px,4vw,40px);line-height:1;letter-spacing:-.045em}
.onboarding-head .eyebrow{grid-area:eyebrow;margin:0}
.onboarding-rule{grid-area:rule;max-width:62ch;line-height:1.5}
.onboarding-head .tag-editor-summary-count{grid-area:count;align-self:center;padding:8px 12px;white-space:nowrap}
.onboarding-tabs{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:8px}
.onboarding-tab{display:flex;align-items:center;justify-content:center;gap:8px;min-height:42px;padding:8px 14px;border-radius:999px;border:1px solid var(--line);background:var(--surface);color:var(--muted);cursor:pointer;transition:.2s}
.onboarding-tab.is-active{background:var(--accent);border-color:transparent;color:var(--accentText)}
.onboarding-tab span{display:inline-flex;align-items:center;justify-content:center;min-width:34px;height:22px;padding:0 7px;border-radius:999px;background:rgba(255,255,255,.1);font-size:11px}
.onboarding-tab.is-active span{background:rgba(0,0,0,.12)}
.onboarding-panel{display:none}
.onboarding-panel.is-active{display:grid;gap:12px;animation:fade .2s ease}
.onboarding-optional{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:14px}
.profile-tag-editor{display:grid;gap:14px}
.onboarding-actions{display:flex;align-items:center;justify-content:space-between;gap:10px}
.onboarding-actions .btn{min-height:42px;padding:10px 20px}
.onboarding-actions .btn.primary{min-width:148px}
.confirmation-dialog{width:min(460px,calc(100% - 28px));padding:0;border:1px solid var(--line2);border-radius:24px;background:#171717;color:var(--text);box-shadow:0 28px 90px rgba(0,0,0,.58)}
.confirmation-dialog::backdrop{background:rgba(0,0,0,.72);backdrop-filter:blur(5px)}
.confirmation-dialog-card{display:grid;gap:12px;padding:22px}
.confirmation-dialog-card h2{font-size:clamp(24px,4vw,32px);line-height:1.05;letter-spacing:-.04em}
.confirmation-dialog-actions{display:flex;justify-content:flex-end;gap:10px;margin-top:6px}
.confirmation-dialog-actions form{margin:0}
.tag-editor-summary{display:grid;gap:16px;padding:20px;border-radius:24px;border:1px solid var(--line);background:linear-gradient(145deg,rgba(255,255,255,.06),rgba(255,255,255,.02))}
.tag-editor-summary-head{display:flex;justify-content:space-between;gap:16px;align-items:flex-start;flex-wrap:wrap}
.tag-editor-summary-head h2{margin:6px 0 0;font-size:clamp(20px,2.5vw,28px)}
.tag-editor-summary-count{display:inline-flex;align-items:center;gap:4px;padding:10px 14px;border-radius:999px;background:rgba(255,255,255,.08);border:1px solid var(--line);font-size:13px;color:var(--muted)}
.tag-editor-selected{display:flex;flex-wrap:wrap;gap:10px}
.tag-editor-empty{color:var(--muted);font-size:14px}
.tag-selected-pill{display:inline-flex;align-items:center;gap:8px;padding:10px 14px;border-radius:999px;border:1px solid rgba(255,255,255,.16);background:rgba(255,255,255,.08);color:var(--text);cursor:pointer;transition:.18s ease}
.tag-selected-pill:hover{transform:translateY(-1px);border-color:var(--line2);background:rgba(255,255,255,.12)}
.tag-selected-pill::after{content:"×";font-size:14px;color:var(--muted)}
.tag-editor-summary-footer{display:flex;flex-wrap:wrap;gap:10px 14px;color:var(--muted);font-size:12px}

.tag-editor-containers{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:16px}
.tag-container-card{padding:0;border-radius:26px;overflow:visible;border:1px solid var(--line)}
.tag-container-card.is-open{border-color:var(--line2)}
.tag-container-toggle{width:100%;display:flex;justify-content:space-between;align-items:flex-start;gap:16px;padding:20px 22px;border:0;background:transparent;color:inherit;text-align:left;cursor:pointer}
.tag-container-copy{display:grid;gap:6px}
.tag-container-copy strong{font-size:22px}
.tag-container-copy span:last-child{color:var(--muted);font-size:14px;line-height:1.5}
.tag-container-meta{display:inline-flex;align-items:center;gap:12px}
.tag-container-count{min-width:34px;height:34px;display:grid;place-items:center;border-radius:999px;background:rgba(255,255,255,.08);border:1px solid var(--line);font-weight:700}
.tag-container-body{display:grid;gap:18px;padding:0 22px 22px}
.tag-container-helper{padding:12px 14px;border-radius:16px;background:rgba(255,255,255,.05);color:var(--muted);font-size:13px;line-height:1.5}
.tag-container-branches{display:flex;flex-wrap:wrap;gap:10px;align-items:flex-start}

.tag-branch{display:inline-flex;align-items:flex-start;gap:8px;min-width:0;padding:0;border:0;background:transparent;overflow:visible}
.tag-branch[data-branch-depth="1"].is-active-branch,
.tag-branch[data-branch-depth="2"].is-active-branch,
.tag-branch[data-branch-depth="1"].is-closing-branch,
.tag-branch[data-branch-depth="2"].is-closing-branch{position:relative;z-index:20;display:grid;gap:12px;flex:1 1 100%;padding:12px;border-radius:20px;border:1px solid var(--line2);background:rgba(255,255,255,.045);overflow:visible}
.tag-branch[data-branch-depth="1"].is-active-branch,
.tag-branch[data-branch-depth="2"].is-active-branch{animation:tagPanelIn .18s cubic-bezier(.2,.7,.2,1) both}
.tag-branch[data-branch-depth="1"]:not(.is-active-branch):not(.is-closing-branch),
.tag-branch[data-branch-depth="2"]:not(.is-active-branch):not(.is-closing-branch){flex:0 1 auto}
.tag-branch.is-selected:not(.is-active-branch) .tag-choice-pill{border-color:rgba(121,214,156,.34);background:rgba(121,214,156,.12);color:#d9ffe5}
.tag-branch-main{display:flex;align-items:center;justify-content:flex-start;gap:8px}
.tag-branch-summary{display:flex;flex-wrap:wrap;gap:8px}
.tag-branch-summary[hidden]{display:none!important}
.tag-branch-summary.is-opening{animation:tagSummaryIn .16s cubic-bezier(.2,.7,.2,1) both}
.tag-branch-summary.is-closing{animation:tagSummaryOut .12s ease both;pointer-events:none}
.tag-summary-pill{display:inline-flex;align-items:center;min-height:30px;padding:6px 9px;border-radius:999px;background:rgba(255,255,255,.06);border:1px solid var(--line);color:var(--muted);font-size:12px}
.tag-choice{display:inline-flex;align-items:flex-start;gap:0;cursor:pointer;width: max-content;}
.tag-choice[hidden],.review-level2-item[hidden],.tag-branch[hidden],.tag-suggestion-toggle[hidden],[data-tag-suggestion-overflow][hidden]{display:none!important}
[data-tag-suggestion-overflow].is-suggestion-revealed{animation:tagSuggestionIn .16s cubic-bezier(.2,.7,.2,1) both}
[data-tag-suggestion-overflow].is-suggestion-hiding{animation:tagSuggestionOut .12s ease both;pointer-events:none}
.tag-category-choice{display:inline-flex;padding:0;border:0;background:transparent;color:inherit;cursor:pointer;text-align:left;width: max-content;}
.tag-choice input{position:absolute;opacity:0;pointer-events:none}
.tag-choice-pill{display:inline-flex;align-items:center;gap:0;min-height:42px;padding:10px 14px;border-radius:16px;border:1px solid rgba(255,255,255,.08);background:rgba(255,255,255,.04);transition:.18s ease;line-height:1.35;max-width: 350px;}
.tag-choice-label{min-width:0;overflow-wrap:anywhere}
.tag-choice-pill small{display:inline-flex;align-items:center;justify-content:center;min-height:20px;margin-left:7px;padding:0 7px;border-radius:999px;background:rgba(121,214,156,.14);font-size:11px;color:#d9ffe5}
.tag-choice input:checked + .tag-choice-pill{border-color:rgba(121,214,156,.42);background:rgba(121,214,156,.16);color:#d9ffe5;box-shadow:0 10px 24px rgba(0,0,0,.12)}
.pending-tag-pill{border-style:dashed!important;border-color:rgba(255,255,255,.18)!important;background:rgba(255,255,255,.055)!important;color:var(--muted)!important;cursor:not-allowed;box-shadow:none!important}
.pending-tag-pill small{background:rgba(255,255,255,.1)!important;color:var(--muted)!important}
.tag-choice.is-disabled{cursor:not-allowed}
.is-pending-custom-label{opacity:.78}
.pending-remove-button{width:22px!important;margin-left:8px!important;visibility:visible!important;opacity:.45!important;pointer-events:auto!important;cursor:pointer!important}
.pending-remove-button:hover,.pending-remove-button:focus-visible{opacity:.9!important;background:rgba(255,255,255,.12)!important}
.tag-remove-button{display:inline-flex;align-items:center;justify-content:center;flex:0 0 auto;width:0;height:22px;margin-left:0;padding:0 0 3px;border:0;border-radius:999px;background:transparent;color:currentColor;visibility:hidden;opacity:0;overflow:hidden;pointer-events:none;cursor:pointer;line-height:1;transition:width .16s ease,margin-left .16s ease,opacity .16s ease,background-color .16s ease}
.tag-choice input:checked + .tag-choice-pill .tag-remove-button{width:22px;margin-left:8px;visibility:visible;opacity:.42;pointer-events:auto}
.tag-choice input:checked + .tag-choice-pill .tag-remove-button:hover,
.tag-choice input:checked + .tag-choice-pill .tag-remove-button:focus-visible{opacity:.9;background:rgba(255,255,255,.12)}
.tag-category-choice:hover .tag-choice-pill{border-color:var(--line2);background:rgba(255,255,255,.08)}
.tag-add-level2{display:inline-flex;align-items:flex-start;min-width:min(360px,100%)}
.tag-level2-picker{min-width:min(360px,100%)}
.tag-branch-toggle{flex:0 0 auto;display:inline-flex;align-items:center;justify-content:center;min-width:96px;padding:10px 12px;border-radius:14px;border:1px solid var(--line);background:rgba(255,255,255,.04);color:var(--text);cursor:pointer}
.tag-branch-hint{margin:0;color:var(--muted);font-size:12px}
.tag-section-limit{margin:0;color:#ffdada}
.tag-branch-children{display:grid;gap:12px;padding:12px;border-radius:18px;background:rgba(255,255,255,.025);overflow:visible;transform-origin:top;transition:opacity .18s ease,transform .18s ease}
.tag-branch-children[hidden],.tag-branch-tools[hidden]{display:none!important}
.tag-branch-children.is-opening,.tag-branch-tools.is-opening{animation:tagExpand .2s ease both}
.tag-branch-children.is-closing,.tag-branch-tools.is-closing{animation:tagCollapse .14s ease both;pointer-events:none}
.tag-branch-list{display:flex;flex-wrap:wrap;gap:10px;align-items:center}
.tag-suggestion-toggle{display:inline-flex;align-items:center;justify-content:center;min-width:42px;min-height:42px;padding:8px 12px;border-radius:16px;border:1px solid rgba(255,255,255,.08);background:rgba(255,255,255,.04);color:var(--muted);cursor:pointer;line-height:1}
.tag-suggestion-toggle:hover,.tag-suggestion-toggle:focus-visible{border-color:var(--line2);background:rgba(255,255,255,.08);color:var(--text)}
.tag-branch-tools{display:grid;gap:10px;overflow:visible;transform-origin:top}
.tag-picker-inline{position:relative;z-index:30}
.tag-picker-inline .tag-suggestions{z-index:60}
.tag-picker-input,.tag-custom-add input{width:100%;padding: 9px 16px;min-height: 42px;}
.tag-custom-add{display:grid;grid-template-columns:minmax(0,1fr) 80px;gap:8px}
.tag-add-submit{width:42px;min-width:42px;height:42px;padding:0;border-radius:14px;font-size:20px;line-height:1}
.tag-entity-chip{gap:8px;padding-right:6px}
.tag-entity-remove{display:inline-flex;align-items:center;justify-content:center;width:24px;height:24px;padding-bottom: 3px;margin-left:2px;border:0;border-radius:999px;background:rgba(0,0,0,.18);color:inherit;cursor:pointer;line-height:1}
.tag-entity-remove:hover{background:rgba(0,0,0,.28)}
.tag-option{display:grid;gap:4px}
.tag-option small{color:var(--muted)}
.review-tags-shell h1{font-size:clamp(30px,4vw,46px);line-height:.98;letter-spacing:-.05em}
.review-rejections{display:grid;gap:8px;margin-bottom:14px}
.review-rejections ul{display:grid;gap:5px;margin:0;padding-left:20px;color:var(--muted);font-size:13px;line-height:1.45}
.review-grid{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:16px}
.review-container{display:grid;gap:14px;padding:16px;border-radius:24px;border:1px solid var(--line);background:rgba(255,255,255,.03);align-content: start;}
.review-container-head{display:flex;justify-content:space-between;align-items:center;gap:12px}
.review-container-head h2{font-size:22px;letter-spacing:-.03em}
.review-branches{display:grid;gap:10px}
.review-branch{display:grid;gap:8px;padding:8px;border-radius:16px;border:1px solid transparent;background:transparent;transition:border-color .18s ease,background-color .18s ease;align-content: start;}
.review-branch.is-selected{border-color:rgba(121,214,156,.18);background:rgba(121,214,156,.045)}
.review-branch.is-active-review-branch,
.review-branch.is-closing-review-branch{border-color:var(--line2);background:rgba(255,255,255,.05)}
.review-branch-opener{max-width:max-content}
.review-branch-summary{display:flex;flex-wrap:wrap;gap:6px;padding-left:2px}
.review-branch-summary[hidden]{display:none!important}
.review-branch-summary.is-opening{animation:tagSummaryIn .16s cubic-bezier(.2,.7,.2,1) both}
.review-branch-summary.is-closing{animation:tagSummaryOut .12s ease both;pointer-events:none}
.review-summary-pill{display:inline-flex;align-items:center;min-height:30px;padding:6px 9px;border-radius:999px;border:1px solid var(--line);background:rgba(255,255,255,.05);color:var(--muted);font-size:12px;cursor:pointer;transition:.18s ease}
.review-summary-pill:hover,.review-summary-pill:focus-visible{border-color:var(--line2);background:rgba(255,255,255,.09);color:var(--text)}
.review-level2{display:flex;flex-wrap:wrap;gap:8px;padding:4px 0 0 2px}
.review-level2-item{display:grid;gap:8px}
.review-level2-item.is-active-review-level2,
.review-level2-item.is-closing-review-level2{flex:1 1 100%;padding:10px;border-radius:16px;border:1px solid var(--line);background:rgba(255,255,255,.035)}
.review-level2-item.is-active-review-level2{animation:tagPanelIn .18s cubic-bezier(.2,.7,.2,1) both}
.review-level3{display:grid;gap:8px;padding:4px 0 0}
.review-level3-list{display:flex;flex-wrap:wrap;gap:8px}
.review-level3-choice .tag-choice-pill{max-width:100%}
.review-level3-picker{max-width:min(420px,100%)}
.review-level3-picker .tag-custom-add{grid-template-columns:minmax(0,1fr) 42px}
.review-level3-picker[data-existing-only="1"] .tag-custom-add{grid-template-columns:1fr}
.review-level2[hidden],.review-level3[hidden]{display:none!important}
.review-level2.is-opening,.review-level3.is-opening{animation:tagExpand .18s cubic-bezier(.2,.7,.2,1) both}
.review-level2.is-closing,.review-level3.is-closing{animation:tagCollapse .14s ease both;pointer-events:none}
[data-no-toggle] .section-head{cursor:default}

@keyframes tagPanelIn{from{opacity:0;transform:translateY(4px)}to{opacity:1;transform:none}}
@keyframes tagExpand{from{opacity:0;transform:translateY(-4px) scaleY(.98)}to{opacity:1;transform:none}}
@keyframes tagCollapse{from{opacity:1;transform:translateY(0)}to{opacity:0;transform:translateY(-4px)}}
@keyframes tagSuggestionIn{from{opacity:0;transform:translateY(-3px) scale(.98)}to{opacity:1;transform:none}}
@keyframes tagSuggestionOut{from{opacity:1;transform:none}to{opacity:0;transform:translateY(-3px) scale(.98)}}
@keyframes tagSummaryIn{from{opacity:0;transform:translateY(-3px)}to{opacity:1;transform:none}}
@keyframes tagSummaryOut{from{opacity:1;transform:none}to{opacity:0;transform:translateY(-3px)}}

@media(max-width:980px){
  .tag-editor-containers{grid-template-columns:1fr}
  .review-grid{grid-template-columns:1fr}
}
@media(max-width:760px){
  .onboarding-shell{gap:12px;width:100%;padding:16px}
  .onboarding-head{grid-template-columns:minmax(0,1fr) auto;gap:6px 10px}
  .onboarding-head h1{font-size:clamp(27px,8vw,34px)}
  .onboarding-head .tag-editor-summary-count{padding:7px 10px;font-size:12px}
  .onboarding-tabs{grid-template-columns:repeat(2,minmax(0,1fr));gap:6px}
  .onboarding-tab{gap:6px;min-height:40px;padding:7px 10px;font-size:13px}
  .onboarding-optional{grid-template-columns:1fr}
  .onboarding-actions{display:grid;grid-template-columns:1fr}
  .onboarding-actions .btn,.onboarding-actions .btn.primary{width:100%;min-width:0}
  .onboarding-actions .btn.primary{order:-1}
  .confirmation-dialog-actions{display:grid;grid-template-columns:1fr}
  .confirmation-dialog-actions .btn{width:100%}
  .tag-container-toggle{padding:18px}
  .tag-container-body{padding:0 18px 18px}
  .tag-custom-add{grid-template-columns:minmax(0,1fr) 80px}
  .tag-branch-children{padding-left:12px}
}

/* Interaction policy: block selection/drag by default, then allow only copy-critical content. */
html,
body,
body *{
  user-select:none;
  -webkit-user-select:none;
}
img,
a{
  -webkit-user-drag:none;
  /*user-drag:none;*/
}
input,
textarea,
select,
option,
[contenteditable],
.msg-author,
.msg-body,
.profile-title,
.profile-hero-summary,
.chat-peer-name,
.conv-topline strong,
.profile-head h3,
.favorite-card h3,
.favorite-card-copy span,
[data-notifications-list] h3,
[data-notifications-list] .small,
[data-notifications-list] .helper,
[data-notifications-list] .hint{
  user-select:text !important;
  -webkit-user-select:text !important;
}

.field-hint{
  display:block;
  min-height:1.2em;
  margin-top:6px;
}

.settings-content .section-body{padding-top:12px}
.settings-content .section-body.settings-grid{gap:12px}
.settings-content .settings-grid>.helper,.settings-content .settings-grid>.actions{margin:0}
.settings-field{display:grid;gap:6px;min-width:0;margin:0}
.settings-field>label{margin:0;font-weight:700}
.settings-field>select{margin:0!important}
.settings-account-form .settings-grid{gap:12px}
.settings-account-form .label{margin:0}
.settings-account-form .field-hint{margin-top:4px}
.session-list{display:grid;gap:10px}
.session-item{padding:12px 14px;border:1px solid var(--line);border-radius:12px;background:rgba(255,255,255,.025)}
.session-item.is-current{border-color:rgba(235,125,174,.5);background:rgba(235,125,174,.08)}
.session-item-heading{display:flex;align-items:center;justify-content:space-between;gap:10px}
.session-item-heading span{padding:3px 8px;border-radius:999px;background:rgba(235,125,174,.16);color:#ffd5e6;font-size:12px}
.session-item-details{display:flex;flex-wrap:wrap;gap:5px 14px;margin-top:8px;color:var(--muted);font-size:13px;line-height:1.45}
.session-item-details b{font-weight:600;color:var(--text)}
.session-revoke-form{display:flex;justify-content:flex-end;margin-top:10px}
.session-logout-all-form{display:flex;align-items:center;justify-content:space-between;gap:14px;flex-wrap:wrap;padding:2px 0 0}
.session-logout-all-form .helper{max-width:560px;margin:0}

.field-hint.field-error{
  color:#ff9a9a;
}

input.is-invalid{
  border-color:#ff6b6b;
  box-shadow:0 0 0 1px rgba(255,107,107,.35);
}

input.field-error-flash,
textarea.field-error-flash,
select.field-error-flash{
  animation:fieldErrorFlash 1.7s ease-out both;
}

@keyframes fieldErrorFlash{
  0%,22%{border-color:#ff6b6b;box-shadow:0 0 0 1px rgba(255,107,107,.42),0 0 0 5px rgba(255,107,107,.08)}
  100%{border-color:var(--line);box-shadow:none}
}

input.field-error-flash:focus,
textarea.field-error-flash:focus,
select.field-error-flash:focus{
  animation-name:fieldErrorFlashFocus;
}

@keyframes fieldErrorFlashFocus{
  0%,22%{border-color:#ff6b6b;box-shadow:0 0 0 1px rgba(255,107,107,.42),0 0 0 5px rgba(255,107,107,.08)}
  100%{border-color:var(--line2);box-shadow:none}
}

.profile-actions{
  position:relative;
  align-items:center;
}

.profile-action-bar{
  position:relative;
  display:flex;
  align-items:center;
  gap:8px;
  flex-wrap:wrap;
}

.profile-action-fallback{
  display:inline-flex;
  align-items:center;
  margin:0;
}

.profile-action-btn{
  display:inline-flex;
  align-items:center;
  justify-content:center;
  width:44px;
  height:44px;
  min-width:44px;
  padding:0;
  border-radius:16px;
  border:1px solid var(--line);
  background:var(--surface);
  color:var(--text);
  cursor:pointer;
  transition:background .18s ease,border-color .18s ease,color .18s ease,transform .18s ease,box-shadow .18s ease;
}

.profile-action-btn svg{
  width:20px;
  height:20px;
}

.profile-action-btn.primary{
  border-color:rgba(255,255,255,.28);
  background:linear-gradient(180deg,rgba(255,255,255,.18),rgba(255,255,255,.08));
  box-shadow:0 12px 30px rgba(0,0,0,.22);
}

.profile-action-btn.secondary{
  color:var(--muted);
}

.profile-action-btn:hover,
.profile-action-btn:focus-visible{
  border-color:var(--line2);
  background:var(--surface2);
  color:var(--text);
  transform:translateY(-1px);
  outline:none;
}

.profile-action-btn:focus-visible{
  box-shadow:0 0 0 3px rgba(255,255,255,.12);
}

.profile-action-btn.is-active{
  color:#ffd76a;
  border-color:rgba(255,215,106,.28);
  background:rgba(255,215,106,.12);
}

.profile-action-btn:disabled{
  cursor:not-allowed;
  opacity:.55;
  transform:none;
  box-shadow:none;
}

.profile-action-more-wrap{
  position:relative;
}

.profile-action-menu{
  position:absolute;
  left:0;
  right:auto;
  top:calc(100% + 10px);
  z-index:35;
  display:grid;
  gap:8px;
  width:min(260px,calc(100vw - 28px));
  padding:10px;
  border:1px solid var(--line2);
  border-radius:18px;
  background:rgba(18,18,20,.96);
  box-shadow:var(--shadow);
  backdrop-filter:blur(18px);
  transform-origin:top left;
  animation:profileActionMenuIn .16s cubic-bezier(.2,.7,.2,1) both;
}

.profile-action-menu.is-closing{
  animation:profileActionMenuOut .14s ease both;
  pointer-events:none;
}

.profile-action-menu[hidden],
.profile-message-popover[hidden],
.profile-action-submenu[hidden]{
  display:none;
}

.profile-action-menu-section{
  position:relative;
  display:grid;
  gap:4px;
}

.profile-action-menu button svg{
  width:17px;
  height:17px;
  flex:0 0 auto;
}

.profile-action-menu-item{
  display:flex;
  align-items:center;
  gap:10px;
  width:100%;
  padding:10px 11px;
  border:0;
  border-radius:12px;
  background:transparent;
  color:var(--text);
  text-align:left;
  cursor:pointer;
}

.profile-action-menu-item span{
  min-width:0;
  flex:1 1 auto;
}

.profile-action-menu-item:hover,
.profile-action-menu-item:focus-visible{
  background:rgba(255,255,255,.08);
  outline:none;
}

.profile-action-menu-item.danger{
  color:#ff9a9a;
}

.profile-action-menu-item:disabled{
  cursor:not-allowed;
  opacity:.55;
}

.profile-action-menu-item.is-forever{
  margin-top:4px;
  border-top:1px solid var(--line);
  border-radius:0 0 12px 12px;
}

.profile-action-submenu-toggle svg:last-child{
  width:16px;
  height:16px;
  opacity:.7;
  transition:transform .18s ease;
}

.profile-action-submenu-toggle[aria-expanded="true"] svg:last-child{
  transform:rotate(90deg);
}

.profile-action-submenu{
  position:absolute;
  left:calc(100% + 8px);
  right:auto;
  top:0;
  z-index:36;
  display:grid;
  gap:4px;
  width:180px;
  padding:8px;
  border:1px solid var(--line2);
  border-radius:16px;
  background:rgba(18,18,20,.98);
  box-shadow:var(--shadow);
  backdrop-filter:blur(18px);
  transform-origin:left top;
  animation:profileActionSubmenuIn .16s cubic-bezier(.2,.7,.2,1) both;
}

.profile-action-submenu.is-closing{
  animation:profileActionSubmenuOut .14s ease both;
  pointer-events:none;
}

.profile-action-submenu::before{
  content:"";
  position:absolute;
  top:0;
  left:-10px;
  width:10px;
  height:100%;
}

@keyframes profileActionMenuIn{
  from{opacity:0;transform:translateY(6px) scale(.98)}
  to{opacity:1;transform:none}
}

@keyframes profileActionMenuOut{
  from{opacity:1;transform:none}
  to{opacity:0;transform:translateY(4px) scale(.98)}
}

@keyframes profileActionSubmenuIn{
  from{opacity:0;transform:translateX(-6px) scale(.98)}
  to{opacity:1;transform:none}
}

@keyframes profileActionSubmenuOut{
  from{opacity:1;transform:none}
  to{opacity:0;transform:translateX(-4px) scale(.98)}
}

.profile-message-popover{
  position:relative;
  left:auto;
  right:auto;
  top:auto;
  z-index:34;
  flex:1 0 100%;
  width:min(380px,100%);
  max-width:100%;
  margin-top:4px;
  box-sizing:border-box;
  padding:14px;
  border:1px solid var(--line2);
  border-radius:22px;
  background:rgba(18,18,20,.96);
  box-shadow:var(--shadow);
  backdrop-filter:blur(18px);
}

.profile-message-popover form{
  display:grid;
  gap:12px;
}

.profile-message-popover-head{
  display:flex;
  align-items:center;
  justify-content:space-between;
  gap:10px;
}

.profile-popover-close{
  display:inline-flex;
  align-items:center;
  justify-content:center;
  width:34px;
  height:34px;
  border:1px solid var(--line);
  border-radius:12px;
  background:var(--surface);
  color:var(--text);
  cursor:pointer;
}

.profile-popover-close svg{
  width:18px;
  height:18px;
}

.profile-message-popover textarea{
  min-height:110px;
  resize:vertical;
}

.profile-action-status{
  min-height:18px;
  font-size:12px;
  color:var(--muted);
}

@media(max-width:760px){
  .profile-actions{
    display:flex;
  }

  .profile-actions .profile-action-bar{
    width:100%;
  }

  .profile-actions .profile-action-fallback{
    width:auto;
  }

  .profile-action-menu{
    right:auto;
    left:0;
  }

  .profile-action-submenu{
    position:static;
    width:100%;
    margin-top:4px;
    box-shadow:none;
    background:rgba(255,255,255,.04);
  }

  .profile-action-submenu::before{
    display:none;
  }

  .profile-message-popover{
    width:100%;
  }
}

.auth .form-card{
  width:min(690px,100%);
}

.auth form.form-card .label{
  margin:0 0 14px;
  font-size:16px;
  line-height:1.35;
}

.auth form.form-card .grid2 .label{
  margin-bottom:0;
}

.auth form.form-card > h1 + .label,
.auth form.form-card > .small + .label,
.auth form.form-card > .label + .label,
.auth form.form-card > .label + .grid2,
.auth form.form-card > .grid2 + .label{
  margin-top:18px;
}

.auth form.form-card .label input,
.auth form.form-card .label textarea,
.auth form.form-card .label select{
  display:block;
  margin-top:18px;
  font-size:16px;
}

.auth form.form-card input::placeholder,
.auth form.form-card textarea::placeholder{
  color:rgba(247,247,243,.18);
  font-size:14px;
  opacity:1;
}

.password-field{
  position:relative;
  display:block;
  margin-top:18px;
}

.auth form.form-card .label .password-field input{
  margin-top:0;
  padding-right:58px;
}

/* The custom animated control is the single password-visibility toggle. */
.password-field input[type="password"]::-ms-reveal,
.password-field input[type="password"]::-ms-clear{
  display:none;
}

.password-field input[type="password"]::-webkit-credentials-auto-fill-button,
.password-field input[type="password"]::-webkit-contacts-auto-fill-button{
  display:none !important;
}

.auth form.form-card input:-webkit-autofill,
.auth form.form-card input:-webkit-autofill:hover,
.auth form.form-card input:-webkit-autofill:focus,
.auth form.form-card input:-webkit-autofill:active{
  -webkit-text-fill-color:var(--text) !important;
  caret-color:var(--text) !important;
  background-color:var(--input-autofill-bg) !important;
  background-image:none !important;
  -webkit-box-shadow:0 0 0 1000px var(--input-autofill-bg) inset !important;
  box-shadow:0 0 0 1000px var(--input-autofill-bg) inset !important;
  color:var(--text) !important;
  transition:background-color 9999s ease-out,color 9999s ease-out !important;
}

.password-toggle{
  position:absolute;
  top:50%;
  right:8px;
  display:inline-flex;
  align-items:center;
  justify-content:center;
  width:40px;
  height:40px;
  padding:0;
  border:0;
  border-radius:14px;
  background:transparent;
  color:var(--muted);
  cursor:pointer;
  transform:translateY(-50%);
  transition:background-color .18s ease,color .18s ease;
}

.password-toggle:hover,
.password-toggle:focus-visible{
  background:var(--surface2);
  color:var(--text);
  outline:none;
}

.password-toggle-eye{
  width:22px;
  height:22px;
}

.password-toggle-slash{
  opacity:0;
  transition:opacity .18s ease;
}

.password-toggle.is-visible .password-toggle-slash{
  opacity:1;
}

.auth form.form-card .field-hint:empty{
  display:block;
  min-height:0;
  margin-top:0;
}

.registration-consents{
  display:grid;
  gap:10px;
  margin:24px 0 18px;
  padding:16px;
  border:1px solid var(--line);
  border-radius:18px;
  background:rgba(255,255,255,.025);
}

.registration-consents-head{margin:0 0 2px}
.registration-consents-head h2{margin:0;color:var(--muted);font-size:12px;font-weight:600;letter-spacing:.1em;text-transform:uppercase}

.consent-row{
  display:flex;
  align-items:center;
  gap:10px;
  padding:0px 15px;
  margin:5px;
  border:1px solid transparent;
  border-radius:12px;
  color:var(--muted);
  font-size:14px;
  line-height:1.5;
  cursor:pointer;
  transition:border-color .18s ease,background-color .18s ease,transform .18s ease;
}

.consent-row:hover{border-color:var(--line);background:rgba(255,255,255,.025)}
.consent-row:focus-within{border-color:var(--line2);background:rgba(255,255,255,.04)}
.consent-row input{width:17px;height:17px;margin:.2em 0 0;accent-color:#ef86b9;flex:0 0 auto}
.consent-row a,.policy-page a{color:#f4a2c7;text-decoration-thickness:1px;text-underline-offset:3px}
.consent-row-optional{color:rgba(247,247,243,.7)}
.registration-consents .field-hint{margin:-4px 10px 0}

.public-profile-consent{display:grid;gap:12px;margin:20px 0;padding:16px;border:1px solid var(--line);border-radius:18px;background:rgba(255,255,255,.025)}
.public-profile-consent h2,.public-profile-consent h3{margin:0;font-size:18px}
.public-profile-consent p{margin:0}
.public-profile-consent .label{display:grid;gap:7px}
.public-profile-consent .label input{margin-top:0}
.profile-tag-consent-revoke{margin-top:12px}

.policy-page{width:min(1080px,100%);margin:28px auto 56px}
.policy-page,.policy-page *{user-select:text;-webkit-user-select:text}
@media (prefers-reduced-motion:no-preference){html:has(.policy-page){scroll-behavior:smooth}}
.policy-hero{padding:clamp(24px,5vw,46px);border-radius:28px}
.policy-hero .eyebrow{margin:0 0 8px}
.policy-hero h1{max-width:800px;margin:0;font-size:clamp(30px,5vw,50px);line-height:1.04}
.policy-hero .lead{max-width:720px;margin:14px 0 0;color:var(--muted);font-size:17px;line-height:1.55}
.policy-actions{display:flex;flex-wrap:wrap;gap:10px;margin-top:22px}
.policy-layout{display:grid;grid-template-columns:220px minmax(0,1fr);gap:18px;margin-top:18px;align-items:start}
.policy-nav{position:sticky;top:calc(var(--site-header-height) + 16px);display:grid;gap:4px;padding:10px;border-radius:18px}
.policy-nav a{padding:9px 10px;border-radius:10px;color:var(--muted);font-size:14px;text-decoration:none;transition:background-color .18s ease,color .18s ease,transform .18s ease}
.policy-nav a:hover,.policy-nav a:focus-visible{background:rgba(255,255,255,.07);color:var(--text);outline:none;transform:translateX(2px)}
.policy-card{padding:clamp(20px,4vw,38px);border-radius:24px}
.policy-card section{scroll-margin-top:calc(var(--site-header-height) + 24px);padding:4px 0 24px;border-bottom:1px solid var(--line)}
.policy-card section + section{padding-top:24px}
.policy-card section:last-child{padding-bottom:0;border-bottom:0}
.policy-card h2{margin:0 0 10px;font-size:21px}
.policy-card p{max-width:800px;margin:10px 0;color:var(--muted);line-height:1.65}
.policy-card ul{display:grid;gap:7px;max-width:800px;margin:10px 0;padding-left:22px;color:var(--muted);line-height:1.55}
.policy-card:focus-visible{outline:2px solid rgba(244,162,199,.75);outline-offset:4px}
.policy-actions .btn{font-size:13px}
.site-footer{display:flex;align-items:center;justify-content:center;gap:14px;width:min(1180px,calc(100% - 36px));margin:0 auto;padding:20px 0 26px;color:rgba(247,247,243,.46);font-size:12px}
.site-footer nav{display:flex;gap:14px;flex-wrap:wrap}
.site-footer a{color:rgba(247,247,243,.54);text-decoration:none}
.site-footer a:hover,.site-footer a:focus-visible{color:var(--text);text-decoration:underline;text-underline-offset:3px;outline:none}
.info-page{max-width:680px}
.info-page p{line-height:1.65;color:var(--muted);margin-top:10px;}
.info-page a{color:#f4a2c7;text-underline-offset:3px}

@media (max-width:760px){
  .policy-page{margin-top:16px}
  .policy-hero,.policy-card{border-radius:20px}
  .policy-layout{grid-template-columns:1fr}
  .policy-nav{position:static;display:flex;overflow:auto;white-space:nowrap;padding:8px}
  .policy-nav a:hover,.policy-nav a:focus-visible{transform:none}
  .site-footer{align-items:flex-start;flex-direction:column;gap:8px;width:min(100% - 28px,1180px);padding:18px 0 22px}
}

/* Responsive hardening: these rules intentionally come last to cover legacy page-local styles. */
:root{--visual-viewport-height:100dvh}
body.search-filter-open{position:fixed;top:var(--search-filter-scroll-y,0px);right:0;left:0;width:100%;overflow:hidden}

/* Long user supplied values must shrink inside grid and flex layouts before they can overflow. */
.page,.panel,.form-card,.profile-box,.match,.settings-content,.settings-fact-row,.settings-insight-item,.admin-page,.admin-copy,.tag-entity-chip,.tag-summary-pill,.review-summary-pill,.search-active-tag,.search-active-tag>span,.search-tag-chip,.chat-file,.chat-media-viewer-copy,.chat-media-viewer-copy strong,.chat-media-viewer-copy span{min-width:0;max-width:100%}
.email,.username,.filename,.url,.admin-copy,.settings-fact-row strong,.settings-insight-item,.search-active-tag>span,.search-tag-chip,.chat-file,.chat-media-viewer-copy strong,.chat-media-viewer-copy span{overflow-wrap:anywhere;word-break:break-word}

/* Fixed chat surfaces use the visual viewport, including a software keyboard. */
body.chat-screen .page.chat-page{height:calc(var(--visual-viewport-height) - var(--site-header-height))!important;max-height:calc(var(--visual-viewport-height) - var(--site-header-height))!important}

@media(max-width:980px){
  /* Minimum touch area while preserving the visual size of glyphs. */
  .password-toggle,.profile-popover-close,.chat-media-viewer-close,.chat-sidebar-close,.chat-mobile-toggle,.chat-head-icon-btn,.chat-icon-btn,.chat-send-btn,.btn.chat-send-btn,.chat-message-menu-btn,.msg-menu-trigger,.chat-conversation-menu-toggle,.profile-photo-quick-action,.profile-photo-menu-toggle,.profile-photo-viewer-close{width:44px!important;height:44px!important;min-width:44px!important;min-height:44px!important}
  .profile-action-menu-item,.chat-conversation-menu-panel button{min-height:44px}
  .chat-compose-editor{min-height:44px;padding-top:11px;padding-bottom:11px}
  .chat-composer-bar{min-height:52px}
  .chat-library-overlay,.chat-media-viewer{top:0;padding-top:max(10px,env(safe-area-inset-top));padding-right:max(10px,env(safe-area-inset-right));padding-bottom:max(10px,env(safe-area-inset-bottom));padding-left:max(10px,env(safe-area-inset-left));--chat-overlay-available-height:var(--visual-viewport-height);z-index:100}
  .chat-emoji-picker{max-height:calc(var(--visual-viewport-height) - env(safe-area-inset-top) - 16px)}
  .settings-nav{position:relative;min-height:52px;padding:0 28px 8px 0;scroll-padding-inline:12px;scroll-snap-type:x proximity;scrollbar-width:thin}
  .settings-nav::after{content:'›';position:sticky;right:0;align-self:center;display:grid;place-items:center;width:24px;height:36px;margin-left:-24px;border-radius:999px;background:linear-gradient(90deg,transparent,rgba(14,14,14,.94) 42%);color:var(--muted);font-size:24px;pointer-events:none}
  .settings-nav a{min-height:48px;scroll-snap-align:start}
}

@media(max-width:760px){
  .chat-emoji-picker{height:min(320px,calc(var(--visual-viewport-height) - 16px - env(safe-area-inset-top) - env(safe-area-inset-bottom)));bottom:max(8px,env(safe-area-inset-bottom))}
  .chat-library-panel,.chat-media-viewer-dialog{max-height:calc(var(--visual-viewport-height) - env(safe-area-inset-top) - env(safe-area-inset-bottom) - 20px)}
}

@media(max-width:900px) and (orientation:landscape) and (max-height:500px){
  :root{--site-header-height:54px}
  .site-header{padding:6px 0}
  .brand-mark{width:38px;height:38px}
  body.chat-screen .page.chat-page{height:calc(var(--visual-viewport-height) - var(--site-header-height))!important}
  .chat-emoji-picker{height:min(250px,calc(var(--visual-viewport-height) - 12px));bottom:6px}
  .chat-media-viewer-dialog{padding:10px;border-radius:18px}
  .chat-media-viewer-stage{min-height:110px}
}

/* Eva is a self-contained fixed widget. These rules do not style ordinary
   buttons, form controls, chat panels, or page layout. */
.eva-fab,
.eva-widget,
.eva-widget-backdrop {
  --eva-motion-fast:120ms;
  --eva-motion-normal:180ms;
  --eva-motion-slow:220ms;
  --eva-motion-ease:cubic-bezier(.2,.8,.2,1);
}

.eva-fab {
  box-sizing: border-box;
  position: fixed;
  top: auto;
  right: max(22px, calc(env(safe-area-inset-right) + 8px));
  bottom: max(22px, calc(env(safe-area-inset-bottom) + 8px));
  left: auto;
  z-index: 78;
  display: grid;
  place-items: center;
  width: 56px;
  min-width: 56px;
  max-width: 56px;
  height: 56px;
  min-height: 56px;
  max-height: 56px;
  margin: 0;
  padding: 0;
  border: 1px solid rgba(244, 162, 199, .62);
  border-radius: 50%;
  background: linear-gradient(135deg, #d85f9f, #8d477b);
  box-shadow: 0 14px 34px rgba(0, 0, 0, .35);
  color: #fff;
  font: 800 25px/1 inherit;
  cursor: pointer;
  transition: transform var(--eva-motion-normal) var(--eva-motion-ease), box-shadow var(--eva-motion-normal) var(--eva-motion-ease), filter var(--eva-motion-fast) var(--eva-motion-ease), opacity var(--eva-motion-fast) var(--eva-motion-ease);
}

.eva-fab:hover { transform: translateY(-2px); box-shadow: 0 18px 38px rgba(0, 0, 0, .45); filter: brightness(1.07); }
.eva-fab:active { transform: translateY(0) scale(.96); }
.eva-fab:focus-visible,
.eva-widget .eva-icon-button:focus-visible,
.eva-widget .eva-user-card:focus-visible { outline: 2px solid #fff; outline-offset: 3px; }

.eva-widget-backdrop { display: none; }
.eva-widget-backdrop[hidden],
.eva-widget[hidden] { display: none !important; }

.eva-widget {
  box-sizing: border-box;
  position: fixed;
  top: auto;
  right: max(22px, calc(env(safe-area-inset-right) + 8px));
  bottom: max(94px, calc(env(safe-area-inset-bottom) + 78px));
  left: auto;
  z-index: 79;
  width: min(380px, calc(100vw - 32px));
  height: min(600px, calc(100dvh - 126px));
  margin: 0;
  padding: 0;
  isolation: isolate;
  animation: none;
}

.eva-widget .eva-widget-panel {
  box-sizing: border-box;
  display: grid;
  grid-template-rows: 64px minmax(0, 1fr) auto;
  width: 100%;
  height: 100%;
  overflow: hidden;
  border: 1px solid rgba(255, 255, 255, .18);
  border-radius: 20px;
  background: rgba(20, 17, 25, .98);
  box-shadow: 0 18px 56px rgba(0, 0, 0, .48);
  color: var(--text);
}

.eva-widget .eva-widget-header {
  display: flex;
  align-items: center;
  gap: 9px;
  min-width: 0;
  padding: 10px 12px;
  border-bottom: 1px solid var(--line);
}

.eva-widget .eva-widget-avatar,
.eva-widget .eva-empty-state-icon,
.eva-widget .eva-user-card-avatar {
  display: grid;
  place-items: center;
  flex: 0 0 auto;
  border-radius: 50%;
  background: rgba(216, 95, 159, .2);
  color: #f7c3dd;
  font-weight: 800;
}

.eva-widget .eva-widget-avatar { width: 34px; height: 34px; font-size: 17px; }
.eva-widget .eva-widget-title { display: grid; min-width: 0; line-height: 1.15; }
.eva-widget .eva-widget-title strong { font-size: 16px; }
.eva-widget .eva-widget-title small { margin-top: 2px; color: var(--muted); font-size: 11px; }
.eva-widget .eva-widget-credits { min-width: 0; margin-left: auto; overflow: hidden; color: var(--muted); font-size: 11px; text-overflow: ellipsis; white-space: nowrap; }

.eva-widget .eva-icon-button {
  box-sizing: border-box;
  display: grid;
  place-items: center;
  flex: 0 0 auto;
  width: 44px;
  min-width: 44px;
  height: 44px;
  min-height: 44px;
  margin: 0;
  padding: 0;
  border: 1px solid transparent;
  border-radius: 50%;
  background: rgba(255, 255, 255, .08);
  color: var(--text);
  font: 400 20px/1 inherit;
  cursor: pointer;
}

.eva-widget .eva-icon-button { transition: transform var(--eva-motion-fast) var(--eva-motion-ease), border-color var(--eva-motion-fast) var(--eva-motion-ease), background var(--eva-motion-fast) var(--eva-motion-ease); }
.eva-widget .eva-icon-button:hover { border-color: var(--line2); background: rgba(255, 255, 255, .14); transform:translateY(-1px); }
.eva-widget .eva-icon-button:active { transform:scale(.96); }

.eva-widget .eva-widget-body {
  display: grid;
  align-content: start;
  gap: 10px;
  min-width: 0;
  min-height: 0;
  overflow-x: hidden;
  overflow-y: auto;
  padding: 13px;
  overscroll-behavior: contain;
  scrollbar-gutter: stable;
}

.eva-widget .eva-widget-body:focus { outline: none; }
.eva-widget .eva-message { box-sizing: border-box; max-width: 94%; min-width: 0; padding: 10px 12px; border-radius: 14px; background: rgba(255, 255, 255, .07); transition:border-color var(--eva-motion-fast) var(--eva-motion-ease), background var(--eva-motion-fast) var(--eva-motion-ease); }
.eva-widget .eva-message-user { justify-self: end; background: rgba(216, 95, 159, .2); }
.eva-widget .eva-message-role { margin: 0 0 5px; color: var(--muted); font-size: 11px; font-weight: 700; }
.eva-widget .eva-message-content { margin: 0; overflow-wrap: anywhere; word-break: break-word; white-space: pre-wrap; line-height: 1.45; }

.eva-widget .eva-empty-state {
  display: grid;
  justify-items: start;
  gap: 8px;
  margin: auto 0;
  padding: 18px;
  border: 1px solid rgba(244, 162, 199, .18);
  border-radius: 16px;
  background: rgba(255, 255, 255, .035);
}

.eva-widget .eva-empty-state-icon { width: 34px; height: 34px; font-size: 17px; }
.eva-widget .eva-empty-state strong { font-size: 14px; }
.eva-widget .eva-empty-state p,
.eva-widget .eva-status { margin: 0; color: var(--muted); line-height: 1.45; }

.eva-widget .eva-error { display: grid; gap: 4px; margin: 0; padding: 11px 12px; border: 1px solid rgba(255, 173, 180, .34); border-radius: 12px; background: rgba(255, 107, 107, .09); color: #ffd6da; line-height: 1.4; }
.eva-widget .eva-error strong { font-size: 13px; }
.eva-widget .eva-error span { color: #f2c8cc; font-size: 12px; }

.eva-widget .eva-first-use { display:grid; gap:10px; min-width:0; padding:2px 1px 8px; }
.eva-widget .eva-first-use h2,.eva-widget .eva-first-use h3 { margin:0; }.eva-widget .eva-first-use h2 { font-size:16px; }.eva-widget .eva-first-use h3 { font-size:13px; }
.eva-widget .eva-first-use > .eva-status { font-size:13px; }
.eva-widget .eva-scope-cards { display:grid; gap:7px; min-width:0; margin:0; padding:0; border:0; }.eva-widget .eva-scope-cards legend { margin:0 0 2px; padding:0; color:var(--text); font-size:13px; font-weight:800; }
.eva-widget .eva-scope-card { display:grid; grid-template-columns:20px minmax(0,1fr); align-items:start; gap:9px; min-width:0; padding:10px; border:1px solid var(--line); border-radius:12px; background:rgba(255,255,255,.025); color:var(--text); cursor:pointer; transition:border-color .16s ease,background .16s ease; }.eva-widget .eva-scope-card:hover { border-color:rgba(244,162,199,.45); background:rgba(216,95,159,.07); }.eva-widget .eva-scope-card:has(input:focus-visible) { outline:2px solid #fff; outline-offset:2px; }.eva-widget .eva-scope-card:has(input:checked) { border-color:rgba(244,162,199,.68); background:rgba(216,95,159,.13); }
.eva-widget .eva-first-use input[type="radio"],.eva-widget .eva-first-use input[type="checkbox"] { box-sizing:border-box; width:20px; min-width:20px; height:20px; min-height:20px; margin:1px 0 0; padding:0; accent-color:#e47caf; }.eva-widget .eva-scope-card-copy,.eva-widget .eva-switch-copy { display:grid; min-width:0; gap:3px; }.eva-widget .eva-scope-card-copy strong,.eva-widget .eva-switch-copy strong { font-size:13px; }.eva-widget .eva-scope-card-copy small,.eva-widget .eva-switch-copy small { color:var(--muted); font-size:12px; line-height:1.35; }
.eva-widget .eva-extra-data { display:grid; gap:7px; }.eva-widget .eva-switch-row { position:relative; display:grid; grid-template-columns:minmax(0,1fr) 40px; align-items:center; gap:10px; min-width:0; min-height:56px; padding:8px 10px; border:1px solid var(--line); border-radius:12px; background:rgba(255,255,255,.025); cursor:pointer; }.eva-widget .eva-switch-row:hover { border-color:rgba(244,162,199,.4); }.eva-widget .eva-first-use .eva-switch-row input { position:absolute; width:1px; min-width:1px; height:1px; min-height:1px; margin:-1px; padding:0; overflow:hidden; clip:rect(0 0 0 0); clip-path:inset(50%); white-space:nowrap; border:0; opacity:0; }.eva-widget .eva-switch-control { grid-column:2; justify-self:end; position:relative; width:38px; max-width:38px; height:22px; border-radius:999px; background:rgba(255,255,255,.2); transition:background .16s ease; }.eva-widget .eva-switch-control::after { content:""; position:absolute; top:3px; left:3px; width:16px; height:16px; border-radius:50%; background:#fff; transition:transform .16s ease; }.eva-widget .eva-switch-row input:checked + .eva-switch-control { background:#d85f9f; }.eva-widget .eva-switch-row input:checked + .eva-switch-control::after { transform:translateX(16px); }.eva-widget .eva-switch-row:has(input:focus-visible) { outline:2px solid #fff; outline-offset:2px; }
.eva-widget .eva-consent-card { display:block; min-width:0; padding:10px; border:1px solid rgba(244,162,199,.5); border-radius:13px; background:rgba(216,95,159,.1); }.eva-widget .eva-consent-card > div { display:grid; min-width:0; gap:6px; }.eva-widget .eva-consent-heading { display:flex; align-items:center; gap:7px; min-width:0; }.eva-widget .eva-consent-card strong { font-size:13px; }.eva-widget .eva-required { flex:0 0 auto; width:max-content; padding:2px 6px; border-radius:999px; background:rgba(244,162,199,.22); color:#ffd9e9; font-size:10px; font-weight:800; white-space:nowrap; }.eva-widget .eva-consent-card p { margin:0; color:var(--muted); font-size:12px; line-height:1.35; }.eva-widget .eva-consent-check { display:flex; align-items:center; gap:8px; color:var(--text); font-size:12px; line-height:1.35; cursor:pointer; }.eva-widget .eva-consent-check input { flex:0 0 auto; width:20px; min-width:20px; height:20px; margin:0; }.eva-widget .eva-consent-card .eva-wizard-privacy-link { order:4; }
.eva-widget .eva-wizard-privacy-link { width:max-content; color:#f4a2c7; font-size:12px; }.eva-widget .eva-setup-result { min-height:18px; }.eva-widget .eva-setup-submit { width:100%; min-height:48px; justify-content:center; }

.eva-widget .eva-widget-composer { display: grid; gap: 8px; min-width: 0; padding: 10px 11px calc(11px + env(safe-area-inset-bottom)); border-top: 1px solid var(--line); background: rgba(16, 14, 21, .82); }
.eva-widget .eva-widget-composer textarea { box-sizing: border-box; display: block; width: 100%; min-height: 48px; max-height: 128px; margin: 0; padding: 10px 11px; resize: none; overflow-y: auto; line-height: 1.35; }
.eva-widget .eva-widget-actions { display: flex; gap: 8px; min-width: 0; }
.eva-widget .eva-widget-actions select { box-sizing: border-box; min-width: 0; min-height:44px; flex: 1; }
.eva-widget .eva-widget-actions .btn { flex: 0 0 auto; min-height:44px; padding: 9px 13px; font-size: 13px; transition:transform var(--eva-motion-fast) var(--eva-motion-ease),opacity var(--eva-motion-fast) var(--eva-motion-ease),filter var(--eva-motion-fast) var(--eva-motion-ease); }
.eva-widget .eva-widget-actions .btn:not(:disabled):hover { transform:translateY(-1px); }
.eva-widget .eva-widget-actions .btn:not(:disabled):active { transform:scale(.97); }
.eva-widget .eva-widget-actions .btn:disabled { cursor: wait; opacity: .7; }

.eva-widget .eva-user-card { display: grid; grid-template-columns:34px minmax(0, 1fr); gap: 9px; min-width: 0; padding: 10px; border: 1px solid rgba(244, 162, 199, .3); border-radius: 12px; color: var(--text); text-decoration: none; }
.eva-widget .eva-user-card:hover { border-color: #f4a2c7; background: rgba(255, 255, 255, .035); }
.eva-widget .eva-user-card-avatar { width: 34px; height: 34px; font-size: 13px; }
.eva-widget .eva-user-card-copy { display: grid; gap: 3px; min-width: 0; }
.eva-widget .eva-user-card-copy span { overflow-wrap: anywhere; color: var(--muted); font-size: 13px; }

@media (max-width:700px) {
  .eva-widget-backdrop:not([hidden]) { position: fixed; inset: 0; z-index: 77; display: block; background: rgba(7, 6, 10, .3); }
  .eva-widget { top: max(8px, env(safe-area-inset-top)); right: max(8px, env(safe-area-inset-right)); bottom: max(8px, env(safe-area-inset-bottom)); left: max(8px, env(safe-area-inset-left)); width: auto; height: auto; }
  .eva-widget .eva-widget-panel { border-radius: 18px; }
  .eva-fab { right: max(14px, calc(env(safe-area-inset-right) + 4px)); bottom: max(14px, calc(env(safe-area-inset-bottom) + 4px)); }
  .eva-widget .eva-widget-credits { display: none; }
}

@media (prefers-reduced-motion:reduce) { .eva-fab, .eva-widget { animation: none; transition: none; } }

/* Eva settings and subscription presentation are intentionally namespaced. */
[data-eva-settings] .eva-settings-subscription { display:flex; align-items:center; justify-content:space-between; gap:14px; padding:14px; border:1px solid var(--line); border-radius:14px; background:rgba(255,255,255,.035); }
[data-eva-settings] .eva-settings-subscription p { margin:4px 0 0; color:var(--muted); font-size:13px; }
[data-eva-settings] .eva-conversation-picker { display:grid; gap:10px; padding:14px; border:1px solid var(--line); border-radius:14px; background:rgba(255,255,255,.025); }
[data-eva-settings] .eva-picker-head { display:flex; align-items:flex-start; justify-content:space-between; gap:12px; }
[data-eva-settings] .eva-picker-head p { margin:3px 0 0; color:var(--muted); font-size:12px; }
[data-eva-settings] .eva-picker-actions { display:flex; flex-wrap:wrap; gap:6px; }
[data-eva-settings] .eva-picker-actions .btn { min-height:44px; padding:7px 10px; font-size:12px; }
[data-eva-settings] .eva-conversation-list { display:grid; gap:6px; max-height:300px; overflow:auto; padding-right:3px; overscroll-behavior:contain; }
[data-eva-settings] .eva-conversation-option { display:grid; grid-template-columns:auto 34px minmax(0,1fr); align-items:center; gap:9px; min-width:0; padding:8px; border:1px solid transparent; border-radius:11px; cursor:pointer; }
[data-eva-settings] .eva-conversation-option:has(input:checked) { border-color:rgba(244,162,199,.5); background:rgba(216,95,159,.11); }
[data-eva-settings] .eva-conversation-option input { width:18px; height:18px; margin:0; }
[data-eva-settings] .eva-conversation-avatar { display:grid; place-items:center; width:34px; height:34px; overflow:hidden; border-radius:50%; background:rgba(216,95,159,.2); color:#f7c3dd; object-fit:cover; }
[data-eva-settings] .eva-conversation-copy { display:grid; min-width:0; gap:2px; }
[data-eva-settings] .eva-conversation-copy strong,[data-eva-settings] .eva-conversation-copy small { overflow:hidden; text-overflow:ellipsis; white-space:nowrap; }
[data-eva-settings] .eva-conversation-copy small { color:var(--muted); }
[data-eva-settings] .eva-scope-warning { margin:0; padding:10px 12px; border:1px solid rgba(255,190,108,.35); border-radius:12px; background:rgba(255,190,108,.09); color:#ffe1ad; line-height:1.4; }

.subscription-page { display:grid; gap:22px; width:min(1160px,100%); margin:0 auto; padding:clamp(8px,1vw,16px) 0 36px; }
.subscription-page .eyebrow { margin:0 0 6px; color:#f4a2c7; font-size:12px; font-weight:800; letter-spacing:.08em; text-transform:uppercase; }
.subscription-hero { display:grid; gap:12px; padding:clamp(24px,5vw,52px); border:1px solid rgba(244,162,199,.22); border-radius:24px; background:radial-gradient(circle at top right,rgba(216,95,159,.2),transparent 42%),var(--surface); }
.subscription-hero h1,.subscription-page h2 { margin:0; }
.subscription-hero h1 { max-width:670px; font-size:clamp(30px,5vw,48px); line-height:1.05; }
.subscription-hero > p { max-width:680px; margin:0; color:var(--muted); font-size:17px; line-height:1.55; }
.subscription-hero .btn { justify-self:start; }
.subscription-payment-notice { display:flex; align-items:flex-start; gap:10px; padding:15px 17px; border:1px solid rgba(255,190,108,.38); border-radius:16px; background:rgba(255,190,108,.09); color:#ffe4b7; line-height:1.45; }
.subscription-payment-notice strong { flex:0 0 auto; }
.subscription-current,.subscription-comparison,.subscription-promo { padding:clamp(16px,3vw,26px); border:1px solid var(--line); border-radius:20px; background:var(--surface); }
.subscription-section-heading { display:flex; align-items:flex-start; justify-content:space-between; gap:16px; margin-bottom:16px; }
.subscription-loading { color:var(--muted); }
.subscription-current-summary { display:flex; align-items:center; justify-content:space-between; gap:12px; }
.subscription-status { display:inline-flex; align-items:center; width:max-content; padding:5px 9px; border:1px solid rgba(244,162,199,.36); border-radius:999px; background:rgba(216,95,159,.12); color:#ffd7e9; font-size:12px; font-weight:800; }
.subscription-credit-progress { height:9px; margin:13px 0 18px; overflow:hidden; border-radius:999px; background:rgba(255,255,255,.09); }
.subscription-credit-progress span { display:block; height:100%; min-width:0; border-radius:inherit; background:linear-gradient(90deg,#d85f9f,#a96de0); }
.subscription-current dl { display:grid; grid-template-columns:repeat(3,minmax(0,1fr)); gap:12px; margin:0; }
.subscription-current dl div { padding:10px; border-radius:12px; background:rgba(255,255,255,.035); }
.subscription-current dt { color:var(--muted); font-size:12px; }.subscription-current dd { margin:4px 0 0; font-weight:700; }
.subscription-current-modes { display:flex; flex-wrap:wrap; gap:7px; margin-top:16px; }.subscription-current-modes span { padding:6px 9px; border-radius:999px; background:rgba(255,255,255,.07); font-size:12px; }
.subscription-plans { display:grid; grid-template-columns:repeat(3,minmax(0,1fr)); gap:14px; }
.subscription-plan-card { display:flex; flex-direction:column; min-width:0; min-height:100%; padding:20px; border:1px solid var(--line); border-radius:18px; background:var(--surface); }
.subscription-plan-card.is-recommended { border-color:rgba(244,162,199,.58); box-shadow:0 16px 34px rgba(216,95,159,.1); }.subscription-plan-card.is-current { box-shadow:inset 0 0 0 1px rgba(244,162,199,.55); }
.subscription-plan-card header { position:relative; min-height:102px; }.subscription-plan-card h3 { margin:0; font-size:22px; }.subscription-price { margin:10px 0 1px; font-size:26px; font-weight:800; }.subscription-plan-card header small { color:var(--muted); }
.subscription-recommended { position:absolute; top:0; right:0; padding:5px 7px; border-radius:999px; background:rgba(216,95,159,.18); color:#ffd7e9; font-size:10px; font-weight:800; }
.subscription-plan-card ul { display:grid; gap:9px; flex:1; margin:16px 0; padding:0; list-style:none; }.subscription-plan-card li { display:flex; justify-content:space-between; gap:9px; color:var(--muted); font-size:13px; }.subscription-plan-card li strong { color:var(--text); text-align:right; }.subscription-plan-action { min-height:38px; margin-top:auto; }
.subscription-mode-grid { display:grid; grid-template-columns:repeat(4,minmax(0,1fr)); gap:10px; margin-bottom:18px; }.subscription-mode-grid article { padding:13px; border:1px solid var(--line); border-radius:14px; background:rgba(255,255,255,.03); }.subscription-mode-grid p { margin:6px 0 0; color:var(--muted); font-size:13px; line-height:1.4; }
.subscription-table-wrap { overflow-x:auto; overscroll-behavior:contain; border:1px solid var(--line); border-radius:14px; }.subscription-table-wrap:focus-visible { outline:2px solid #fff; outline-offset:3px; }.subscription-table-wrap table { width:100%; min-width:680px; border-collapse:collapse; }.subscription-table-wrap th,.subscription-table-wrap td { padding:11px 13px; border-bottom:1px solid var(--line); text-align:left; }.subscription-table-wrap th { font-size:13px; }.subscription-table-wrap td { color:var(--muted); font-size:13px; }.subscription-table-wrap tr:last-child th,.subscription-table-wrap tr:last-child td { border-bottom:0; }
.subscription-page .btn { min-height:44px; }.subscription-promo { display:grid; grid-template-columns:minmax(0,1fr) minmax(300px,460px); align-items:center; gap:24px; }.subscription-promo h2 { margin:0; }.subscription-promo p { margin:8px 0 0; color:var(--muted); }.subscription-promo form { display:grid; gap:8px; }.subscription-promo-row { display:flex; gap:8px; }.subscription-promo-row input { min-width:0; min-height:44px; flex:1; }.subscription-promo-result { min-height:20px; }

.eva-widget .eva-widget-panel { position:relative; }
.eva-widget .eva-thread-drawer { position:absolute; top:64px; right:10px; left:10px; z-index:2; display:grid; gap:9px; max-height:calc(100% - 138px); padding:11px; overflow:auto; border:1px solid var(--line2); border-radius:15px; background:rgba(22,18,28,.99); box-shadow:0 18px 38px rgba(0,0,0,.38); }
.eva-widget[data-eva-view="threads"] .eva-widget-main { opacity:.48; transform:translateY(2px); transition:opacity var(--eva-motion-fast) var(--eva-motion-ease),transform var(--eva-motion-fast) var(--eva-motion-ease); }
.eva-widget .eva-thread-drawer-head { display:flex; align-items:center; justify-content:space-between; gap:10px; }.eva-widget .eva-thread-filter { min-height:44px; padding:6px 9px; border:1px solid var(--line); border-radius:10px; background:rgba(255,255,255,.06); color:var(--text); cursor:pointer; transition:color var(--eva-motion-fast) var(--eva-motion-ease),background var(--eva-motion-fast) var(--eva-motion-ease),transform var(--eva-motion-fast) var(--eva-motion-ease); }
.eva-widget .eva-thread-filter:active { transform:scale(.97); }
.eva-widget .eva-thread-list { display:grid; gap:6px; }.eva-widget .eva-thread-item { display:grid; grid-template-columns:minmax(0,1fr) auto; gap:6px; padding:6px; border:1px solid transparent; border-radius:11px; transition:border-color var(--eva-motion-fast) var(--eva-motion-ease),background var(--eva-motion-fast) var(--eva-motion-ease); }.eva-widget .eva-thread-item.is-active { border-color:rgba(244,162,199,.45); background:rgba(216,95,159,.1); }
.eva-widget .eva-thread-select { display:grid; gap:2px; min-width:0; min-height:44px; padding:5px; border:0; background:transparent; color:var(--text); text-align:left; cursor:pointer; }.eva-widget .eva-thread-select strong,.eva-widget .eva-thread-select small { overflow:hidden; text-overflow:ellipsis; white-space:nowrap; }.eva-widget .eva-thread-select small { color:var(--muted); }
.eva-widget .eva-thread-actions { display:flex; align-items:center; gap:3px; }.eva-widget .eva-thread-actions .eva-icon-button { font-size:16px; }.eva-widget .eva-thread-empty { margin:0; color:var(--muted); font-size:13px; }
.eva-widget .eva-mode-help { display:grid; gap:3px; min-height:18px; margin:0; color:var(--muted); font-size:11px; line-height:1.35; }.eva-widget .eva-mode-help-copy { margin:0; }.eva-widget .eva-mode-upgrade { width:max-content; color:#f4a2c7; font-weight:700; transition:opacity var(--eva-motion-fast) var(--eva-motion-ease),transform var(--eva-motion-fast) var(--eva-motion-ease); }.eva-widget .eva-mode-upgrade:focus-visible { outline:2px solid #fff; outline-offset:3px; }
.eva-widget .eva-message-meta { display:flex; justify-content:space-between; gap:8px; margin-top:8px; color:var(--muted); font-size:10px; }.eva-widget .eva-message-meta span { color:#f4a2c7; }.eva-widget .eva-message-loading { opacity:.78; }.eva-widget .eva-message-loading .eva-message-content::after { content:'···'; display:inline-block; margin-left:4px; animation:eva-thinking 1s steps(3,end) infinite; }.eva-widget .eva-message-user.is-failed { border:1px solid rgba(255,173,180,.62); background:rgba(255,107,107,.12); }
.eva-widget .eva-message-metrics { display:grid; grid-template-columns:repeat(2,minmax(0,1fr)); gap:6px; margin:9px 0 0; }.eva-widget .eva-message-metrics div { padding:6px; border-radius:8px; background:rgba(255,255,255,.06); }.eva-widget .eva-message-metrics dt { color:var(--muted); font-size:10px; }.eva-widget .eva-message-metrics dd { margin:2px 0 0; font-size:12px; font-weight:800; }
.eva-widget .eva-observations { margin-top:9px; }.eva-widget .eva-observations summary { cursor:pointer; color:#f4a2c7; font-size:12px; }.eva-widget .eva-observations article { margin-top:7px; padding:8px; border-radius:9px; background:rgba(255,255,255,.055); }.eva-widget .eva-observations[open] > article { animation:eva-observation-in var(--eva-motion-fast) var(--eva-motion-ease) both; }.eva-widget .eva-observations p { margin:5px 0 0; font-size:12px; line-height:1.35; }
.eva-widget .eva-user-card-avatar { overflow:hidden; object-fit:cover; }.eva-widget .eva-user-card-copy small,.eva-widget .eva-user-card-tags,.eva-widget .eva-user-card-score { color:var(--muted); font-size:11px; }.eva-widget .eva-user-card-tags { overflow-wrap:anywhere; }
.eva-widget .eva-first-use .eva-conversation-picker { display:grid; gap:9px; padding:10px; border:1px solid var(--line); border-radius:12px; }.eva-widget .eva-picker-head { display:flex; justify-content:space-between; gap:8px; }.eva-widget .eva-picker-actions { display:flex; gap:5px; }.eva-widget .eva-picker-actions .btn { min-height:44px; padding:6px 8px; font-size:11px; }.eva-widget .eva-conversation-list { display:grid; gap:5px; max-height:180px; overflow:auto; }.eva-widget .eva-conversation-option { display:grid; grid-template-columns:auto 30px minmax(0,1fr); align-items:center; gap:7px; min-height:44px; padding:6px; border-radius:9px; }.eva-widget .eva-conversation-avatar { width:30px; height:30px; overflow:hidden; border-radius:50%; object-fit:cover; }.eva-widget .eva-conversation-copy { display:grid; min-width:0; }.eva-widget .eva-conversation-copy strong,.eva-widget .eva-conversation-copy small { overflow:hidden; text-overflow:ellipsis; white-space:nowrap; }.eva-widget .eva-conversation-copy small { color:var(--muted); }.eva-widget .eva-wizard-privacy-link { color:#f4a2c7; font-size:13px; }
@keyframes eva-thinking { from { opacity:.25; } to { opacity:1; } }
@keyframes eva-observation-in { from { opacity:0; transform:translateY(-3px); } to { opacity:1; transform:translateY(0); } }

.eva-widget .eva-thread-confirm { display:flex; flex-wrap:wrap; align-items:center; gap:6px; overflow:hidden; }
.eva-widget .eva-thread-rename-input { min-width:0; animation:eva-observation-in var(--eva-motion-fast) var(--eva-motion-ease) both; }
.eva-widget .eva-widget-actions select { transition:border-color var(--eva-motion-fast) var(--eva-motion-ease),background var(--eva-motion-fast) var(--eva-motion-ease),opacity var(--eva-motion-fast) var(--eva-motion-ease); }
.eva-widget .eva-widget-actions select:focus-visible { border-color:rgba(244,162,199,.7); }

@media (max-width:900px) { .subscription-plans { grid-template-columns:repeat(2,minmax(0,1fr)); }.subscription-mode-grid { grid-template-columns:repeat(2,minmax(0,1fr)); }.subscription-current dl { grid-template-columns:1fr; } }
@media (max-width:620px) { .subscription-page { gap:16px; padding-bottom:22px; }.subscription-hero,.subscription-current,.subscription-comparison,.subscription-promo { border-radius:17px; }.subscription-section-heading,.subscription-promo { grid-template-columns:1fr; display:grid; }.subscription-section-heading .btn { justify-self:start; }.subscription-payment-notice { display:grid; }.subscription-plans,.subscription-mode-grid { grid-template-columns:1fr; }.subscription-promo-row { flex-direction:column; }.subscription-promo-row .btn { min-height:44px; }.subscription-current-summary { align-items:flex-start; flex-direction:column; } [data-eva-settings] .eva-settings-subscription,[data-eva-settings] .eva-picker-head { align-items:flex-start; flex-direction:column; } }
@media (prefers-reduced-motion:reduce) { .eva-widget .eva-message-loading .eva-message-content::after { animation:none; }.eva-widget .eva-scope-card,.eva-widget .eva-switch-control,.eva-widget .eva-switch-control::after,.eva-widget .eva-widget-main,.eva-widget .eva-icon-button,.eva-widget .eva-message,.eva-widget .eva-widget-actions .btn,.eva-widget .eva-widget-actions select,.eva-widget .eva-thread-filter,.eva-widget .eva-thread-item,.eva-widget .eva-mode-upgrade,.eva-fab { transition:none; }.eva-widget .eva-observations[open] > article,.eva-widget .eva-thread-rename-input { animation:none; } }

/* Eva widget layout contract: hidden always wins over component display. */
.eva-fab[hidden],.eva-widget[hidden],.eva-widget-backdrop[hidden],.eva-widget [hidden]{display:none!important}
.eva-widget{right:max(20px,calc(env(safe-area-inset-right) + 8px));bottom:max(20px,calc(env(safe-area-inset-bottom) + 8px));left:auto;top:auto;width:min(416px,calc(100vw - 40px));height:min(680px,calc(var(--visual-viewport-height,100dvh) - max(96px,env(safe-area-inset-top) + 36px)));max-height:calc(var(--visual-viewport-height,100dvh) - max(96px,env(safe-area-inset-top) + 36px))}
.eva-widget .eva-widget-panel{grid-template-rows:64px minmax(0,1fr)}
.eva-widget .eva-widget-main{display:grid;grid-template-rows:minmax(0,1fr) auto;min-width:0;min-height:0;overflow:hidden;transition:opacity var(--eva-motion-fast) var(--eva-motion-ease),transform var(--eva-motion-fast) var(--eva-motion-ease)}

/* Mobile chat attachments and Eva FAB follow the composer instead of a fixed offset. */
body.chat-screen{--chat-tools-height:84px}
@media(max-width:760px){
  body.chat-screen .eva-fab{right:max(12px,calc(env(safe-area-inset-right) + 4px));bottom:calc(var(--chat-tools-height,84px) + env(safe-area-inset-bottom) + 12px);width:48px;min-width:48px;max-width:48px;height:48px;min-height:48px;max-height:48px;font-size:21px}
  body.chat-screen .chat-messages{padding-bottom:60px!important}
  body.chat-screen:has(.chat-emoji-picker:not([hidden])) .eva-fab,body.chat-screen:has(.chat-attach-menu:not([hidden])) .eva-fab{opacity:0;pointer-events:none}
  .msg.with-visual,.msg.with-audio,.msg.forwarded-group{width:auto;max-width:calc(100% - 8px)}
  .msg.with-audio{min-width:0}
  .chat-attachment-stack,.chat-attachment-group{width:min(100%,calc(100vw - 52px));max-width:100%;min-width:0}
  .chat-attachment-group.has-file-items,.chat-attachment-group.all-file-items{width:min(100%,calc(100vw - 52px));max-width:100%}
  .chat-attachment-group-grid,.chat-attachment-group.group-count-2.all-landscape .chat-attachment-group-grid,.chat-attachment-group.group-count-2:not(.all-landscape) .chat-attachment-group-grid,.chat-attachment-group.group-count-3 .chat-attachment-group-grid,.chat-attachment-group.group-count-4 .chat-attachment-group-grid,.chat-attachment-group.group-count-5 .chat-attachment-group-grid,.chat-attachment-group.group-count-6 .chat-attachment-group-grid,.chat-attachment-group.group-count-7 .chat-attachment-group-grid,.chat-attachment-group.group-count-8 .chat-attachment-group-grid,.chat-attachment-group.group-count-9 .chat-attachment-group-grid,.chat-attachment-group.group-count-10 .chat-attachment-group-grid{grid-template-columns:repeat(2,minmax(0,1fr));grid-template-rows:none;grid-auto-rows:auto}
  .chat-attachment-group.group-count-3 .chat-attachment-group-item:first-child,.chat-attachment-group.group-count-5 .chat-attachment-group-item:first-child,.chat-attachment-group.group-count-7 .chat-attachment-group-item:first-child{grid-column:auto;grid-row:auto}
  .chat-attachment-group.has-file-items .chat-attachment-group-grid{grid-template-columns:minmax(0,1fr);grid-auto-rows:auto}
  .chat-attachment-group.has-file-items .chat-attachment-group-item{aspect-ratio:auto}
  .chat-attachment-group:not(.has-file-items) .chat-attachment-group-item{aspect-ratio:1/1}
  .chat-attachment-group.group-count-1 .chat-attachment-group-item,.chat-attachment-group.group-count-1 .chat-image-link{aspect-ratio:4/3}
  .msg.with-visual>.msg-body>.chat-attachment-stack>.chat-image-link,.chat-attachment-group.group-count-1 .chat-image-link{width:min(100%,calc(100vw - 52px));max-width:100%;aspect-ratio:4/3}
  .msg.with-visual>.msg-body>.chat-attachment-stack>.chat-image-link .chat-image,.chat-attachment-group.group-count-1 .chat-image{object-fit:contain}
  .chat-attachment-group:not(.group-count-1) .chat-image,.chat-attachment-group:not(.group-count-1) .chat-video,.chat-attachment-group .chat-file-thumb{object-fit:cover}
  .chat-attachment-group .chat-image-link,.chat-attachment-group .chat-video-wrap{width:100%;height:100%;max-width:none}
  .chat-attachment-group .chat-video{width:100%;height:100%;max-height:none}
  .chat-file{display:grid;grid-template-columns:44px minmax(0,1fr);width:min(100%,calc(100vw - 52px));max-width:100%;min-width:0}
  .chat-file-preview{width:44px;height:44px}
  .chat-file-copy,.chat-file-copy strong{min-width:0;max-width:100%;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
  .chat-audio-attachment,.chat-audio-attachment audio,.chat-video-wrap,.chat-video{width:100%;min-width:0;max-width:100%}
  .chat-attachment-caption{display:-webkit-box;overflow:hidden;white-space:normal!important;text-overflow:clip;-webkit-box-orient:vertical;-webkit-line-clamp:3}
  .chat-forward-body .chat-attachment-stack,.chat-forward-body .chat-attachment-group,.chat-forward-body .chat-image-link,.chat-forward-body .chat-video-wrap,.chat-forward-body .chat-file{width:min(100%,calc(100vw - 52px));max-width:100%}
}
.eva-widget .eva-widget-header{gap:7px}.eva-widget .eva-widget-title{flex:1;overflow:hidden}.eva-widget .eva-widget-title strong,.eva-widget .eva-widget-title small{overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.eva-widget .eva-widget-credits{flex:0 1 auto;margin-left:0;padding:4px 7px;border:1px solid rgba(244,162,199,.28);border-radius:999px;background:rgba(216,95,159,.1);font-size:10px}
.eva-widget .eva-icon-button{width:40px;min-width:40px;height:40px;min-height:40px;border-radius:12px}.eva-widget .eva-icon-button svg{width:19px;height:19px;fill:none;stroke:currentColor;stroke-linecap:round;stroke-linejoin:round;stroke-width:2}
.eva-widget .eva-widget-body{align-content:start}.eva-widget .eva-empty-state,.eva-widget .eva-error{justify-self:stretch;align-self:center;margin:auto 0}.eva-widget .eva-empty-state{justify-items:center;text-align:center}
.eva-widget .eva-thread-drawer{position:absolute;inset:64px 0 0;z-index:4;grid-template-rows:auto minmax(0,1fr);gap:12px;max-height:none;padding:14px;overflow:hidden;border:0;border-radius:0;background:rgba(20,17,25,1);box-shadow:none}
.eva-widget .eva-thread-list{min-height:0;overflow:auto;overscroll-behavior:contain}.eva-widget .eva-thread-drawer-head{align-items:start}.eva-widget .eva-thread-tabs{display:flex;gap:5px;padding:3px;border-radius:11px;background:rgba(255,255,255,.06)}.eva-widget .eva-thread-filter{min-height:34px;padding:5px 9px;border:0;background:transparent;font-size:12px}.eva-widget .eva-thread-filter.is-active{background:rgba(216,95,159,.24);color:#fff}.eva-widget .eva-thread-empty{display:grid;place-items:center;min-height:160px;text-align:center}.eva-widget .eva-thread-item{align-items:center}.eva-widget .eva-thread-actions .eva-icon-button{width:34px;min-width:34px;height:34px;min-height:34px}
.eva-widget .eva-widget-composer{background:rgba(20,17,25,.99)}.eva-widget .eva-widget-composer textarea{min-height:42px}.eva-widget .eva-widget-actions .btn{min-height:40px}.eva-widget .eva-widget-actions select{min-height:40px}
@media (max-width:700px){body.eva-sheet-open{overflow:hidden}.eva-widget-backdrop:not([hidden]){display:block;background:rgba(7,6,10,.52)}.eva-widget{inset:max(6px,env(safe-area-inset-top)) max(6px,env(safe-area-inset-right)) max(6px,env(safe-area-inset-bottom)) max(6px,env(safe-area-inset-left));width:auto;height:calc(var(--visual-viewport-height,100dvh) - 12px);max-height:none}.eva-widget .eva-widget-panel{border-radius:20px}.eva-widget .eva-widget-credits{display:none}.eva-widget .eva-icon-button{width:44px;min-width:44px;height:44px;min-height:44px}.eva-widget .eva-thread-drawer{inset:64px 0 0}}
