:root{font-family:"Source Sans 3",system-ui,sans-serif;color:#362922;background:#fff9ed;--red:#a62a18;--line:#e4d3b7}*{box-sizing:border-box}[hidden]{display:none!important}body{margin:0}header{display:flex;align-items:center;gap:1rem;background:#fff2d6;border-bottom:4px solid #dd6b24;padding:.7rem max(4vw,calc((100vw - 880px)/2));min-height:90px}header img{width:92px;height:68px;object-fit:contain}header button{margin-left:auto}h1,h2{font-family:Georgia,serif;margin:.1em 0;line-height:1.15}h1{font-size:clamp(1.7rem,5vw,2.5rem);color:var(--red)}small{font-weight:750;letter-spacing:.09em;font-size:.7rem}main{max-width:880px;padding:1rem;margin:auto}#access,#recovery,article{background:#fff;border:1px solid var(--line);border-radius:16px;padding:clamp(1rem,3vw,2rem)}#access,#recovery{max-width:460px;margin:5vh auto}form label,#desk{display:block;margin:1rem 0;font-weight:650}input,textarea,select{width:100%;padding:.7rem;border:1px solid #bba78e;border-radius:8px;font:inherit;margin-top:.25rem}button,.button{background:#fff;border:1px solid #d3bfa3;border-radius:9px;color:#4e3224;padding:.65rem .85rem;cursor:pointer;font:600 .93rem system-ui;min-height:44px}.primary,nav button[aria-pressed=true]{background:var(--red);color:white;border-color:var(--red)}#modes,nav,.tools,.title{display:flex;gap:.5rem;align-items:center;flex-wrap:wrap}nav{margin-bottom:1rem}#modes{margin-top:1rem}.title{justify-content:space-between}.tools label{margin:0}.tools .primary{margin-left:auto}.sr{position:absolute;width:1px;height:1px;overflow:hidden;clip-path:inset(50%)}.tools:focus-within{outline-offset:2px}#feed{display:flex;flex-direction:column;gap:.65rem;min-height:170px;height:clamp(180px,40dvh,520px);overflow:auto;background:#fcf7ee;padding:1rem;border-radius:10px;margin:.8rem 0}.bubble{align-self:flex-start;background:white;border:1px solid var(--line);border-radius:12px;padding:.6rem .8rem;max-width:86%;overflow-wrap:anywhere}.mine{align-self:flex-end;background:#ffe7ba}.bubble p{white-space:pre-wrap;margin:.3rem 0}.bubble time{display:block;color:#6e6359;font-size:.72rem}.bubble img,.bubble audio{max-width:100%;width:240px}.bubble img{height:auto}#secret{display:block;overflow-wrap:anywhere;margin:1rem 0;font-size:1.05rem}#status{text-align:center;color:#862711;font-weight:650}button:disabled{opacity:.55}#attached:empty{display:none}@media(max-width:480px){main{padding:.7rem}article{padding:.75rem}header img{width:70px;height:54px}.tools{gap:.3rem}.button,button{padding:.55rem .65rem}}

main:has(#desk:not([hidden])){max-width:1240px}
#workspace:has(#desk:not([hidden])){display:grid;grid-template-columns:minmax(220px,28%) minmax(0,1fr);gap:12px;align-items:start}
#desk{background:white;border:1px solid var(--line);border-radius:16px;margin:0;padding:1rem;min-width:0}
#desk h2{font-size:1.35rem}#filterChats{margin:.65rem 0}#roomList{max-height:65dvh;overflow-y:auto}
#roomList button{display:flex;align-items:center;justify-content:space-between;gap:.45rem;text-align:left;width:100%;border:0;border-bottom:1px solid var(--line);border-radius:0;background:white;overflow-wrap:anywhere}
#roomList button[aria-pressed=true]{background:#fff0d7;box-shadow:inset 3px 0 var(--red)}
#roomList small{color:var(--red)}#workspace article{min-width:0}
@media(max-width:690px){#workspace:has(#desk:not([hidden])){display:block}#desk{margin-bottom:.6rem}#roomList{max-height:19dvh}}
#camera svg{display:block}#photoDialog{width:min(94vw,32rem);max-height:90dvh;overflow:auto;border:1px solid var(--line);border-radius:14px;color:inherit}#photoDialog::backdrop{background:#201911aa}#cameraView,#photoPreview{width:100%;max-height:55dvh;object-fit:contain;background:#211d18;margin-top:.7rem;border-radius:8px}
.voice-player{display:flex;align-items:center;gap:.65rem;margin:.4rem 0;max-width:100%}
.voice-player button{width:44px;height:44px;flex:none;border:0;border-radius:50%;background:var(--red);color:white;display:grid;place-items:center;padding:0}
.voice-player button::before{content:"";border-top:8px solid transparent;border-bottom:8px solid transparent;border-left:13px solid currentColor;margin-left:3px}
.voice-player button[data-playing=true]::before{width:12px;height:16px;border:0;background:linear-gradient(to right,currentColor 35%,transparent 35% 65%,currentColor 65%);margin:0}
.voice-player progress{width:clamp(3rem,14vw,8rem);height:5px;accent-color:var(--red)}
.voice-player span{font:600 .8rem system-ui;font-variant-numeric:tabular-nums}

#mic{touch-action:none;user-select:none;-webkit-touch-callout:none}

.bubble .chat-photo{display:grid;place-items:center;padding:0;margin:.35rem 0;border:0;border-radius:9px;overflow:hidden;width:min(240px,53vw);aspect-ratio:4/3;background:#f6ede0}
.bubble .chat-photo img{width:100%;height:100%;object-fit:cover}
#photoViewer{box-sizing:border-box;width:min(96vw,900px);padding:.6rem;border:0;border-radius:12px;background:#201813;color:white}
#photoViewer::backdrop{background:#15100de6}
#fullPhoto{display:block;width:100%;max-height:78dvh;object-fit:contain}
