@font-face{font-family:DM;src:url(assets/body.woff2) format("woff2");font-weight:100 1000;font-display:swap}
@font-face{font-family:Bricolage;src:url(assets/display.woff2) format("woff2");font-weight:200 800;font-display:swap}
:root{--paper:#faf9f6;--ink:#232632;--muted:#62636c;--blue:#315eea;--line:#dededc;--orange:#ff965c;color-scheme:light;font-family:DM,Arial,sans-serif;color:var(--ink)}
*{box-sizing:border-box}
body{-webkit-user-select:none;user-select:none}
#messages,#messages *,#draft{-webkit-user-select:text;user-select:text}
body{background-color:var(--paper);background-image:radial-gradient(#dcdad580 .8px,transparent .9px);background-size:17px 17px;margin:0;min-height:100vh;min-height:100svh;display:flex;flex-direction:column}
button,input,select{font:inherit;color:inherit}
button,a,input,select{-webkit-tap-highlight-color:transparent}
button{cursor:pointer}
button{border:0;background:none}
:focus-visible{outline:3px solid #6885ff;outline-offset:3px}
[hidden]{display:none!important}
.frame{width:min(1120px,calc(100% - 100px));margin-inline:auto}
.bar{background:#faf9f6ee;border-bottom:1px solid var(--line)}
.nav,.nav-right,.brand,.subtle,.adult,.primary,.outline,.controls,.session-head,.session-actions,.dialog-top,footer,footer>div{display:flex;align-items:center}
.nav{min-height:78px;justify-content:space-between}
.brand{font:800 36px/1 Bricolage,Arial,sans-serif;letter-spacing:-2.6px;color:var(--ink);text-decoration:none}
.brand-period{color:#ea7539}
.brandmark{display:inline-flex;align-items:center;justify-content:center;gap:4px;width:36px;height:30px;background:var(--orange);border:2.7px solid var(--ink);border-radius:11px 12px 11px 8px;transform:rotate(-7deg);margin-right:11px;position:relative}
.brandmark:after{content:"";position:absolute;bottom:-6px;left:6px;background:var(--orange);border:solid var(--ink);border-width:0 0 3px 3px;width:7px;height:7px;transform:skewY(-30deg)}
.brandmark i{width:3px;height:9px;background:var(--ink);border-radius:3px}
.nav-right{gap:20px}.subtle{gap:7px;font-size:14px;font-weight:650}.subtle:hover,footer button:hover,.inline:hover{color:var(--blue)}
.adult{border:1px solid #d6d3ce;padding:4px 9px;border-radius:8px;font-size:12px;font-weight:750}
.ico{display:inline-flex;width:19px;height:19px;flex:none}.ico svg{width:100%;height:100%}
#landing{display:grid;grid-template-columns:1.13fr 1fr;align-items:center;gap:clamp(42px,7vw,108px);padding-block:clamp(42px,7vh,86px);flex:1}
.hero{padding-left:7px}
h1,h2,h3,p{margin:0}
h1,h2,h3{font-family:Bricolage,Arial,sans-serif}
h1{font-weight:800;font-size:clamp(68px,6.7vw,103px);letter-spacing:-.068em;line-height:.99}
h1 em{font-style:normal;color:var(--blue);position:relative;display:inline-block;isolation:isolate}
h1 em:after{content:"";position:absolute;left:2%;right:-2%;bottom:-.07em;height:.10em;border-radius:80% 45% 60% 45%;background:#ffb180;transform:rotate(-3deg);z-index:-1}
.hero>p{font-size:clamp(16px,1.45vw,19px);line-height:1.55;color:#555761;margin-top:27px;letter-spacing:-.015em}
.art{margin:23px 0 0 -17px;max-width:425px}.art img{width:100%;height:auto;display:block;image-rendering:pixelated}
.card,.chatbox,dialog{background:#fff;border:1px solid #d8d8d6;border-radius:23px;box-shadow:0 5px 0 rgba(39,40,48,.045),0 14px 44px -28px #31334360}
.setup{padding:clamp(22px,2.5vw,36px);min-width:0}
h2{font-size:clamp(27px,2.45vw,36px);font-weight:780;letter-spacing:-.05em;line-height:1.1}
.modes{border:1px solid #dfdfdf;border-radius:13px;background:#f3f3f2;display:flex;padding:4px;margin:21px 0 23px;gap:4px}
.modes label{position:relative;flex:1;cursor:pointer}.modes input,.sr{position:absolute;width:1px;height:1px;overflow:hidden;clip-path:inset(50%)}
.modes label>span{display:flex;align-items:center;justify-content:center;gap:9px;padding:10px;border-radius:9px;font-weight:700;font-size:15px;color:var(--muted);border:1px solid transparent}
.modes input:checked+span{color:#234dcc;background:white;border-color:#d8deed;box-shadow:0 1px 4px #24274115}
.modes input:focus-visible+span{outline:3px solid #7995ff}
.field{margin-bottom:17px}.field>label,#devices label{font-size:14px;font-weight:750;display:flex;gap:7px;align-items:baseline;margin-bottom:7px}
small{font-size:12px;font-weight:450;color:var(--muted)}.entry{height:45px;border:1px solid #d6d7dc;border-radius:10px;display:flex;align-items:center;padding:0 13px;gap:10px}
.entry:focus-within{border-color:var(--blue);box-shadow:0 0 0 2px #315eea18}
.entry .ico,.hash{color:#777b87}.hash{font-size:20px;font-weight:500;font-style:normal;width:19px;text-align:center}
.entry input,#draft{border:0;outline:0;background:transparent;width:100%;min-width:0;font-size:14px}
.suggestions{display:flex;gap:6px;margin-top:9px;flex-wrap:wrap}
.suggestions button{font-size:12px;padding:4px 8px;border-radius:7px;border:1px solid #dededc;background:#fafaf9}
.suggestions button:before{content:"+";margin-right:4px;color:#72757a}
.suggestions button[aria-pressed=true]{background:#eef2ff;color:#244dca;border-color:#a4b6f7}.suggestions button[aria-pressed=true]:before{content:"✓"}
.checks{border-top:1px solid #e8e7e4;padding-top:16px;margin:19px 0;display:grid;gap:10px}
.checks>label,.checks>div{display:flex;align-items:flex-start;gap:9px;font-size:13px;line-height:1.45}
.checks input{height:16px;width:16px;accent-color:var(--blue);flex:none;margin:1px 0 0;cursor:pointer}
.inline{text-decoration:underline;text-underline-offset:2px;padding:0}
.primary{justify-content:center;width:100%;background:var(--blue);color:white;gap:13px;border:1px solid #254bc2;border-radius:11px;font-weight:700;font-size:15px;min-height:49px;box-shadow:0 3px 0 #213ea4;transition:background .15s,transform .15s}
.primary:hover,#send:hover{background:#224cce}.primary:active{transform:translateY(2px);box-shadow:none}
.error,#deviceError{color:#a92d27;font-size:14px;margin-top:12px}
footer{min-height:66px;border-top:1px solid var(--line);justify-content:space-between;color:#64656e;font-size:12px;gap:10px}
footer>div{gap:7px}footer .ico{width:15px;height:15px}footer button{font-size:inherit;padding:6px}
dialog{width:min(475px,calc(100% - 28px));max-height:84vh;color:var(--ink);padding:26px;overflow:auto}
dialog::backdrop{background:#20233262;backdrop-filter:blur(3px)}
.dialog-top,.session-head{justify-content:space-between;gap:12px}.dialog-top{margin-bottom:20px}
dialog h2{font-size:26px}.close{font-size:25px;background:#f2f2f2;border-radius:50%;width:34px;height:34px;line-height:1}
dialog h3{font-size:18px;margin:16px 0 5px}dialog p{font-size:14px;line-height:1.55;color:#52545f;margin-bottom:9px}
.session{flex:1;padding:36px 0;max-width:900px}.session-head{margin:0 0 20px}.kicker{color:var(--blue);font-size:13px;font-weight:700;margin-bottom:5px}.outline{padding:8px 13px;border:1px solid #cccdd2;border-radius:10px;background:white;font-size:14px;min-height:38px;font-weight:600}.outline:hover{background:#f3f5fd}
.chatbox{overflow:hidden;display:flex;flex-direction:column}.chatbox #status{font-size:14px;color:#475271;padding:15px 20px;background:#f1f4ff;border-bottom:1px solid #d9dfef}
#messages{min-height:160px;height:clamp(175px,32vh,390px);overflow:auto;padding:17px;display:flex;flex-direction:column;gap:10px;align-items:flex-start}
.message{white-space:pre-wrap;overflow-wrap:anywhere;max-width:85%;border-radius:12px;background:#f0f1f3;padding:9px 13px;font-size:15px}.message.mine{background:#e9eeff;align-self:flex-end}.message b{display:block;font-size:11px;color:#525b78;margin-bottom:2px}
#compose{border-top:1px solid var(--line);display:flex;gap:10px;padding:10px 12px}#draft{padding:7px}#draft:focus-visible{outline:2px solid var(--blue);border-radius:6px}
#send{width:39px;height:39px;border-radius:9px;background:var(--blue);color:white;display:grid;place-items:center}
button:disabled{opacity:.5;cursor:default}
.session-actions{justify-content:flex-end;margin:15px 0}.compact{width:auto;padding-inline:20px}.screens{display:grid;grid-template-columns:1fr 1fr;gap:10px}.screen{position:relative;overflow:hidden;background:#25293b;border-radius:13px;aspect-ratio:16/9}.screen video{width:100%;height:100%;object-fit:contain}.screen #local{transform:scaleX(-1)}.screen>span{position:absolute;z-index:1;left:8px;bottom:8px;background:#161925be;color:white;border-radius:6px;padding:2px 6px;font-size:12px}.play{position:absolute;inset:35% 12% auto;justify-content:center}.controls{flex-wrap:wrap;gap:8px;margin:12px 0}.controls button[aria-pressed=false]{background:#ffeadf}
#devices select{width:100%;border:1px solid var(--line);background:white;border-radius:8px;margin-bottom:14px;padding:9px}
@media(min-width:1400px){#landing{gap:100px}}
@media(max-width:850px){.frame{width:calc(100% - 48px)}#landing{gap:27px;grid-template-columns:.9fr 1.15fr}.hero{padding:0}h1{font-size:clamp(52px,8vw,68px)}.art{margin-left:-10px}.hero>p br{display:none}}
@media(max-width:680px){.frame{width:min(440px,calc(100% - 32px))}.nav{min-height:63px}.brand{font-size:30px}.brandmark{transform:scale(.88) rotate(-7deg);margin-right:6px}.nav-right{gap:7px}.subtle{font-size:12px}.subtle .ico{width:16px}.adult{padding:3px 7px}#landing{grid-template-columns:1fr;gap:22px;padding:27px 0}.hero{position:relative;isolation:isolate}.hero h1{font-size:clamp(47px,11vw,62px)}.hero>p{font-size:14px;margin-top:17px;max-width:310px}.art{position:absolute;width:40%;max-width:162px;right:-4px;top:3px;margin:0;z-index:-1}.setup{padding:22px}.modes{margin:16px 0 18px}footer{font-size:11px;min-height:54px}.session-head h2{font-size:25px}.controls{gap:4px}.controls button{font-size:12px;padding:6px 8px}.screens{gap:6px}}
@media(max-width:360px){.art{width:32%}.checks>label,.checks>div{font-size:12px}}
.session[data-view=preview] .screen:first-child{display:none}
.session[data-view=preview] .screens{grid-template-columns:minmax(0,560px)}
.session:is([data-view=preview],[data-view=search]) :is(#compose,#messages){display:none}
.session:is([data-view=preview],[data-view=search]) .chatbox #status{border-bottom:0}
.session[data-view=search] #status:before{content:"";display:inline-block;width:9px;height:9px;margin-right:9px;border-radius:50%;background:var(--blue);animation:pulse 1.8s ease-in-out infinite}
@keyframes pulse{50%{opacity:.35}}
@media(prefers-reduced-motion:reduce){.session[data-view=search] #status:before{animation:none}}
footer a{color:inherit;text-underline-offset:3px}
.guide{max-width:720px;background:var(--paper);padding-block:48px}
.guide h1{font-size:clamp(38px,6vw,64px);margin-bottom:24px}
.guide h2{font-size:24px;margin:25px 0 8px}
.guide p{line-height:1.6}.guide>a{width:fit-content;margin-top:25px;text-decoration:none}

/* Shared preferences and theme controls. */
:root{--panel:#fff;--panel-soft:#f3f4f6;--stroke:#d8d9df;--accent:#315eea;--accent-tint:#e9eeff;--accent-ink:#264bb8}
.theme-button{display:grid;place-items:center;color:var(--ink);background:var(--panel);border:1px solid var(--stroke);width:39px;height:39px;flex:none;border-radius:13px}
.theme-button svg{height:20px;width:20px;fill:none;stroke:currentColor;stroke-width:1.8;stroke-linecap:round;stroke-linejoin:round}
.theme-button .sun,[data-theme=dark] .theme-button .moon{display:none}
[data-theme=dark] .theme-button .sun{display:block}
.storage-glyph{width:43px;height:43px;margin-bottom:18px;border-radius:13px;display:grid;place-items:center;background:var(--accent-tint);color:var(--accent-ink);font-size:24px}
#storage{max-width:415px;padding:28px}
#storage h2{margin-bottom:10px}
.storage-actions,.head-actions,.auto-switch,.rail-heading{display:flex;align-items:center}
.storage-actions{gap:10px;margin-top:22px}.storage-actions button{flex:1;justify-content:center;min-height:42px;font-size:14px}
.head-actions{gap:14px}.auto-switch{cursor:pointer;gap:8px;font-size:13px;font-weight:700;position:relative;white-space:nowrap}
.auto-switch input{position:absolute;inset:0;opacity:0;cursor:pointer;width:100%;height:100%;margin:0}
.switch-track{pointer-events:none;position:relative;width:34px;height:20px;background:var(--panel-soft);border:1px solid var(--stroke);border-radius:20px;transition:background .18s}
.switch-track:before{content:"";position:absolute;top:3px;left:3px;width:12px;height:12px;background:var(--muted);border-radius:50%;transition:transform .18s,background .18s}
.auto-switch input:checked+.switch-track{background:var(--accent);border-color:var(--accent)}
.auto-switch input:checked+.switch-track:before{background:#fff;transform:translateX(14px)}
.auto-switch input:focus-visible+.switch-track{outline:3px solid #7995ff;outline-offset:3px}
.rail-heading{display:none}
.session-head>div:first-child{min-width:0}.session-head h2{overflow-wrap:anywhere}
.video-room .nav,.video-room footer{width:calc(100% - 48px);max-width:none}
.video-room .nav{min-height:60px}.video-room footer{min-height:42px}
.video-room .session{width:calc(100% - 48px);max-width:none;padding:20px 0 12px;display:grid;grid-template-columns:minmax(0,1fr) clamp(250px,22vw,395px);grid-template-rows:auto minmax(0,1fr) auto;column-gap:14px;row-gap:12px}
.video-room .session-head{grid-column:1/-1;margin:0}.video-room .session-head h2{font-size:clamp(24px,2.3vw,36px)}
.video-room #videos{grid-column:1;grid-row:2;min-width:0;display:grid;grid-template-rows:1fr auto;gap:9px}
.video-room .screens{min-width:0;gap:10px}
.video-room .screen{aspect-ratio:auto;min-height:300px;height:100%;border-radius:18px;border:1px solid #343b50;background:radial-gradient(ellipse at 50% 40%,#333c52,#191e2d 80%);isolation:isolate}
.video-room .screen video{display:block;position:absolute;inset:0;object-fit:cover}
.video-room .screen>span{bottom:14px;left:14px;padding:5px 10px;max-width:90%;overflow:hidden;text-overflow:ellipsis;white-space:nowrap;border:1px solid #ffffff32;border-radius:9px;backdrop-filter:blur(8px)}
.video-room .play{inset:auto;top:50%;left:50%;transform:translate(-50%,-50%);max-width:95%;z-index:2}
.video-room .controls{margin:0;gap:7px;flex-wrap:wrap}
.video-room .chatbox{grid-column:2;grid-row:2;min-width:0;min-height:0;max-height:100%;border-radius:17px}
.video-room .rail-heading{display:flex;gap:9px;padding:15px 16px;font-size:17px;letter-spacing:-.03em;border-bottom:1px solid var(--line)}
.video-room #messages{height:0;min-height:0;flex:1}
.video-room .session-actions{grid-column:1/-1;margin:0;min-height:0}
.video-room .session-actions:has(#next[hidden]){display:none}
.video-room .session[data-view=preview] .screens{grid-template-columns:minmax(0,1fr)}
.video-room .session[data-view=preview] .screen video{object-fit:contain}
@media(min-width:901px){
  .video-room .session{height:calc(100dvh - 104px);min-height:500px;flex:none}
}
@media(max-width:900px){
  .video-room .session{width:calc(100% - 24px);display:flex;flex-direction:column;gap:12px}
  .video-room #videos{display:block}
  .video-room .screen{min-height:0;height:clamp(185px,34dvh,380px)}
  .video-room .controls{margin-top:8px}.video-room .chatbox{flex:1;min-height:100px}
  .video-room #messages{min-height:125px;max-height:40dvh;flex:1 1 165px}
  .video-room .session-actions{order:0}.video-room .session-head{align-items:flex-start}
  .video-room .nav,.video-room footer{width:calc(100% - 24px)}
}
@media(max-width:680px){
  .nav-right{gap:5px}.theme-button{width:32px;height:32px;border-radius:10px}
  .head-actions{gap:7px}.auto-switch{font-size:12px;gap:4px}
  .video-room .session-head h2{font-size:21px}.video-room .screens{gap:6px}
  .video-room .screen>span{bottom:7px;left:7px}
  footer{flex-wrap:wrap;justify-content:space-between;gap:4px;padding-block:10px}footer>div{flex-wrap:wrap}
}
:root[data-theme=dark]{color-scheme:dark;--paper:#131622;--ink:#f0eff5;--muted:#b5b7c9;--blue:#92abff;--line:#353a50;--panel:#1d2130;--panel-soft:#262b3d;--stroke:#414860;--accent:#496be5;--accent-tint:#2c3658;--accent-ink:#bdcdff;--orange:#ffa66c}
[data-theme=dark] body{background-image:radial-gradient(#858cab32 .8px,transparent .9px)}
[data-theme=dark] .bar{background:var(--paper)}
[data-theme=dark] .brandmark,[data-theme=dark] .brandmark:after{border-color:#171923}
[data-theme=dark] .brandmark i{background:#171923}
[data-theme=dark] :is(.card,.chatbox,dialog){background:var(--panel);border-color:var(--stroke);box-shadow:0 5px 0 #080a134d,0 18px 50px -28px #050610}
[data-theme=dark] :is(.hero>p,dialog p,footer,.entry .ico,.hash,.message b){color:var(--muted)}
[data-theme=dark] :is(.modes,.close,.suggestions button,.outline,#devices select){background:var(--panel-soft);border-color:var(--stroke);color:var(--ink)}
[data-theme=dark] :is(.entry,.adult,.checks){border-color:var(--stroke)}
[data-theme=dark] .entry{background:#191d2b}
[data-theme=dark] :is(input)::placeholder{color:#a8acbf}
[data-theme=dark] :is(.modes input:checked+span,.suggestions button[aria-pressed=true],.outline:hover){background:var(--accent-tint);color:var(--accent-ink);border-color:#536495}
[data-theme=dark] .suggestions button:before{color:var(--muted)}
[data-theme=dark] :is(.primary,#send){background:#4967d6;border-color:#758de7;color:white}
[data-theme=dark] :is(.primary:hover,#send:hover){background:#526fdc}
[data-theme=dark] .chatbox #status{background:var(--accent-tint);color:var(--accent-ink);border-color:var(--stroke)}
[data-theme=dark] .message{background:var(--panel-soft)}
[data-theme=dark] .message.mine{background:var(--accent-tint)}
[data-theme=dark] .controls button[aria-pressed=false]{background:#4a302b;color:#ffd5b8}
[data-theme=dark] :is(.error,#deviceError){color:#ffab9c}
[data-theme=dark] .guide{background:var(--paper)}
[data-theme=dark] dialog::backdrop{background:#080b14b3}
@keyframes arrive{from{opacity:0;transform:translateY(8px)}to{opacity:1;transform:translateY(0)}}
@keyframes bubble-in{from{opacity:0;transform:translateY(5px) scale(.97)}to{opacity:1;transform:translateY(0) scale(1)}}
@keyframes drift{0%,100%{transform:translateY(0) rotate(0)}50%{transform:translateY(-5px) rotate(-.65deg)}}
@media(prefers-reduced-motion:no-preference){
  body,.bar,.card,.chatbox,.entry,.outline,.modes,.theme-button{transition:background-color .22s ease,color .18s ease,border-color .18s ease}
  .hero,.setup,.session-head,.screens,.chatbox,.guide{animation:arrive .36s ease-out both}
  .setup{animation-delay:.06s}
  .art img{animation:drift 5s ease-in-out 1}
  dialog[open],.message{animation:bubble-in .2s ease-out both}
  button:not(:disabled),.modes label>span{transition:background-color .16s,color .16s,box-shadow .16s,translate .16s}
  @media(hover:hover){.primary:hover,.outline:hover,.theme-button:hover,.suggestions button:hover{translate:0 -2px}}
  button:not(:disabled):active{translate:0 1px}
  .theme-button:hover svg{transform:rotate(-12deg)}.theme-button svg{transition:transform .2s}
}
@media(prefers-reduced-motion:reduce){*,*::before,*::after{animation:none!important;transition:none!important;scroll-behavior:auto!important}}

#publicHint{margin:0 0 18px;color:var(--muted);font-size:14px;line-height:1.5}
@media(max-width:420px){.modes label>span{gap:5px;padding-inline:4px}.modes .ico{width:16px}}
