/* One surface owns attachments, editing, and turn control; no floating nested toolboxes. */
.hannah-composer { border: 1px solid #a78bfa55; border-radius: 22px; background: linear-gradient(120deg,#191d30,#121421); padding: 14px; box-shadow: 0 8px 30px #0003; }
.hannah-composer:focus-within { border-color: #ac83ed; box-shadow: 0 0 0 3px #a78bfa13; }
.hannah-composer textarea { display:block; resize:none; width:100%; min-height:32px; max-height:180px; overflow-y:auto; border:0; outline:0; background:transparent; color:#f2edff; font:inherit; font-size:16px; line-height:1.5; padding:2px 4px 10px; }
.hannah-composer textarea::placeholder { color:#aaa2bf; }
.hannah-composer .composer-toolbar, .hannah-composer .composer-tools, .hannah-composer .composer-url { display:flex; align-items:center; gap:6px; }
.hannah-composer .composer-toolbar { margin-top:4px; }
.hannah-composer .composer-tool { position:relative; display:grid; place-items:center; width:34px; height:34px; color:#b9accf; border:0; border-radius:9px; background:transparent; cursor:pointer; }
.hannah-composer .composer-tool:hover { color:#e9daff; background:#b18ae522; }
.hannah-composer .composer-tool input[type=file] { position:absolute; inset:0; width:100%; height:100%; opacity:0; cursor:pointer; }
.hannah-composer button:focus-visible, .hannah-composer .composer-tool:focus-within { outline:2px solid #c5a1ff; outline-offset:2px; }
.hannah-composer button:disabled, .hannah-composer .disabled { opacity:.45; cursor:default; }
.hannah-composer .composer-hint { flex:1; text-align:right; color:#aaa0b8; font-size:11px; padding:0 10px; }
.hannah-composer .composer-action { display:grid; place-items:center; flex:0 0 40px; height:40px; border:1px solid #c89dff80; border-radius:14px; color:#fff; background:#8151c0; cursor:pointer; }
.hannah-composer .composer-action.is-stop { background:#30213e; }
.hannah-composer .composer-stop { width:13px; height:13px; background:#ebd8ff; border-radius:3px; animation:hannah-composer-stop-pulse 1.5s ease-in-out infinite; }
@keyframes hannah-composer-stop-pulse { 50% { box-shadow:0 0 0 6px #c48cff25; opacity:.6; transform:scale(.88); } }
@media (prefers-reduced-motion:reduce) { .hannah-composer .composer-stop { animation:none; } }
.hannah-composer .composer-attachments { display:flex; gap:10px; flex-wrap:wrap; margin-bottom:12px; overflow:visible; }
/* Keep previews visual-only; names surface on hover or keyboard focus so the composer stays compact. */
.hannah-composer .composer-attachment { position:relative; flex:0 0 104px; width:104px; height:104px; border:1px solid #a78bfa66; border-radius:15px; background:linear-gradient(145deg,#242039,#111522); box-shadow:0 5px 18px #0005; }
.hannah-composer .composer-attachment-preview { position:relative; display:grid; place-items:center; width:100%; height:100%; overflow:hidden; border-radius:inherit; color:#d9c5ff; outline:none; }
.hannah-composer .composer-attachment-preview:focus-visible { box-shadow:inset 0 0 0 2px #d2b1ff; }
.hannah-composer .composer-attachment-preview img { width:100%; height:100%; object-fit:cover; }
.hannah-composer .composer-attachment-preview > .mud-icon-root { width:36px; height:36px; opacity:.9; filter:drop-shadow(0 4px 10px #0008); }
.hannah-composer .composer-attachment-tooltip { position:absolute; z-index:30; left:50%; bottom:calc(100% + 10px); width:max-content; max-width:min(280px,calc(100vw - 36px)); padding:8px 11px; border:1px solid #b48cff88; border-radius:10px; background:linear-gradient(135deg,#211a32,#101321); box-shadow:0 10px 28px #000a,0 0 18px #9c6bff22; color:#f1eaff; font-size:12px; line-height:1.4; overflow-wrap:anywhere; opacity:0; visibility:hidden; pointer-events:none; transform:translate(-50%,4px); transition:opacity .14s ease,transform .14s ease,visibility .14s; }
.hannah-composer .composer-attachment-tooltip::after { position:absolute; top:100%; left:50%; width:8px; height:8px; border-right:1px solid #b48cff88; border-bottom:1px solid #b48cff88; background:#151426; content:""; transform:translate(-50%,-4px) rotate(45deg); }
.hannah-composer .composer-attachment-preview:hover + .composer-attachment-tooltip, .hannah-composer .composer-attachment-preview:focus-visible + .composer-attachment-tooltip { opacity:1; visibility:visible; transform:translate(-50%,0); }
.hannah-composer .composer-attachment:first-child .composer-attachment-tooltip { left:0; transform:translate(0,4px); }
.hannah-composer .composer-attachment:first-child .composer-attachment-tooltip::after { left:20px; }
.hannah-composer .composer-attachment:first-child .composer-attachment-preview:hover + .composer-attachment-tooltip, .hannah-composer .composer-attachment:first-child .composer-attachment-preview:focus-visible + .composer-attachment-tooltip { transform:translate(0,0); }
.hannah-composer .composer-attachment:last-child:not(:first-child) .composer-attachment-tooltip { right:0; left:auto; transform:translate(0,4px); }
.hannah-composer .composer-attachment:last-child:not(:first-child) .composer-attachment-tooltip::after { right:20px; left:auto; }
.hannah-composer .composer-attachment:last-child:not(:first-child) .composer-attachment-preview:hover + .composer-attachment-tooltip, .hannah-composer .composer-attachment:last-child:not(:first-child) .composer-attachment-preview:focus-visible + .composer-attachment-tooltip { transform:translate(0,0); }
.hannah-composer .composer-attachment button { position:absolute; z-index:2; top:5px; right:5px; display:grid; place-items:center; width:25px; height:25px; padding:0; border:1px solid #ffffff30; border-radius:8px; background:#111321cf; color:#fff; font-size:17px; line-height:1; cursor:pointer; backdrop-filter:blur(8px); }
.hannah-composer .composer-attachment button:hover { background:#7a42c9e8; }
.hannah-composer .composer-url button, .hannah-composer .composer-camera button { border:0; border-radius:6px; background:#a78bfa22; color:#eadcff; padding:6px 9px; cursor:pointer; }
.hannah-composer .composer-url { margin-bottom:10px; }
.hannah-composer .composer-url input { flex:1; min-width:0; background:#080b17; border:1px solid #a78bfa55; color:#eee; padding:8px; border-radius:8px; }
.hannah-composer .composer-camera video { display:block; width:100%; max-height:280px; margin-bottom:8px; border-radius:10px; background:#000; }
.hannah-composer .composer-camera { margin-bottom:12px; }
.hannah-composer .composer-error { margin-top:8px; color:#ffb8c6; font-size:13px; }
@media (max-width:600px) { .hannah-composer { padding:10px; }
.hannah-composer .composer-hint { font-size:10px; padding:0 4px; }
.hannah-composer .composer-attachment { flex-basis:88px; width:88px; height:88px; } }
@media (prefers-reduced-motion:reduce) { .hannah-composer .composer-attachment-tooltip { transition:none; } }
