.composer .composer-row,.composer[data-input-mode=voice] .composer-row{display:flex;flex-direction:column;gap:6px;align-items:stretch}
.composer #messageInput{width:100%;box-sizing:border-box;min-height:54px}
.composer #voiceRecord{width:100%;min-height:58px;margin:0;padding:14px;border:1px dashed #e9b6bd;background:#fff0f2;color:#ad3544;font-size:15px!important;border-radius:14px;touch-action:none}
.composer-tools{display:flex;flex-wrap:wrap;align-items:center;gap:4px;width:100%;min-width:0}
.composer-tools .quick-controls{display:contents;overflow:visible}
.composer-tools .quick-controls .composer-modes,.composer-tools .quick-controls .locale-control,.composer-tools .quick-controls .voice-stage{display:none!important}
.composer-tools button,.composer-tools .quick-controls button{display:inline-flex;align-items:center;justify-content:center;flex:0 0 34px;width:34px;height:36px;min-height:36px;margin:0;padding:0;border-radius:10px;gap:0}
.composer-tools .quick-controls button span,.composer-tools .quick-controls .reply-chip::after{display:none}
.composer-tools .quick-controls svg{width:18px;height:18px}
.composer-tools #inputModeToggle{font-size:0!important;background:#f4ece8;color:#845e50}
.composer-tools #inputModeToggle[aria-pressed=true]{background:#ffe8ec;color:#b5374b}
.composer-tools #sendMessage{margin-inline-start:auto;background:#ef4148;color:white}
.composer-tools #sendMessage[hidden]{display:none}
.composer-tools #attachButton{font-size:23px!important}
.composer-tools .quick-controls #microphoneToggle .control-icon,.composer-tools .quick-controls #outputAudioToggle .control-icon{fill:none;stroke:currentColor;stroke-width:1.7}
.composer-info:popover-open{position:fixed;inset:auto;display:block;margin:0;padding:9px 12px;max-width:min(270px,calc(100vw - 32px));border:1px solid #ead8d0;border-radius:11px;background:#fffaf6;color:#624a40;box-shadow:0 4px 16px #0001;font:13px/1.4 system-ui;pointer-events:none}
.composer-language-panel:popover-open{display:grid;grid-template-columns:1fr 1fr;position:fixed;inset:auto;margin:0;padding:8px;gap:4px;border:1px solid #e8d9d1;border-radius:12px;background:#fffcfa;box-shadow:0 5px 20px #0002}
.composer-language-panel button{min-height:40px;padding:8px 12px;border:0;border-radius:8px;background:transparent;font-size:13px;color:#604b44}.composer-language-panel button[aria-pressed=true]{background:#f8e3de;color:#ac3e30}
.vg-sheet{background:rgb(20 15 15 / 24%);backdrop-filter:none;-webkit-backdrop-filter:none;padding:16px}
.vg-card{width:min(100%,340px);border-radius:18px;padding:18px;box-shadow:0 8px 30px #0002;animation:none;background:#fffcfa;border:1px solid #e8ded7}
.vg-brand,.vg-orb,.vg-private,.vg-keyboard{display:none!important}
.vg-title{font-size:17px;margin:0 0 6px;letter-spacing:0}.vg-timer{font-size:22px;font-weight:600;color:#b83a46}
.vg-wave{height:24px;margin:10px auto;gap:3px}.vg-bar{max-height:24px!important;flex-basis:4px}
.vg-caption{font-size:14px;line-height:1.4;min-height:0;max-height:70px;margin:10px 0}
.vg-hint{font-size:12px;margin:8px 0;color:#816760}
.vg-targets{gap:8px;margin:12px 0 0}.vg-sheet button{font-size:12px!important;min-height:40px;padding:8px 10px;border-radius:10px}
.vg-actions{gap:8px;margin-top:10px}.vg-editor{font-size:16px;min-height:90px;max-height:160px}.vg-preview{height:36px;margin-top:10px;width:100%}
@media(max-width:380px){.composer-tools{gap:3px}.composer-tools button,.composer-tools .quick-controls button{flex-basis:32px;width:32px}}

.composer-tools #sendMessage{border:0;border-radius:11px;display:inline-flex;align-items:center;justify-content:center;padding:0}
#sendMessage svg{display:block;width:20px;height:20px;fill:none;stroke:currentColor;stroke-width:1.8;stroke-linecap:round;stroke-linejoin:round;pointer-events:none}
.composer-tools #sendMessage[hidden]{display:none}

.media-grid:has(.audio-tile):not(:has(.media-tile:not(.audio-tile))){width:min(300px,100%);grid-template-columns:1fr}
.media-tile.audio-tile{min-height:0;padding:0;border:0;border-radius:16px;background:transparent;cursor:default}
.voice-message-player{display:flex;align-items:center;gap:10px;padding:12px;border-radius:16px;background:#f6efeb;border:1px solid #ebded7;min-width:0;box-sizing:border-box}
.caption.user .voice-message-player{background:#fff0f2;border-color:#f1d4da}
.voice-message-player button{display:grid;place-items:center;flex:0 0 40px;width:40px;height:40px;min-height:40px;border:0;border-radius:50%;background:#c44c53;color:#fff;padding:0;cursor:pointer}
.voice-message-player svg{width:19px;height:19px;fill:currentColor}
.voice-message-track{flex:1;min-width:0;display:flex;flex-direction:column;gap:3px}
.voice-message-player input[type=range]{width:100%;min-width:0;margin:0;height:24px;accent-color:#c44c53;cursor:pointer;padding:0}
.voice-message-player time{font:11px/1.2 system-ui;color:#96766e;font-variant-numeric:tabular-nums;direction:ltr}
.voice-message-player audio{display:none!important}
.voice-message-error{font-size:12px;color:#a33;max-width:100%;overflow-wrap:anywhere}

/* Single-row composer, with an explicitly expandable text field. */
.composer .composer-row,.composer[data-input-mode=voice] .composer-row{display:flex;flex-direction:row;flex-wrap:nowrap;align-items:flex-end;gap:4px}
.composer .composer-entry{flex:1;min-width:0;display:block}
.composer #messageInput{display:block;width:100%;height:40px;min-height:40px;max-height:35dvh;padding:9px 6px;font-size:16px;line-height:22px;resize:vertical;overflow-y:auto;box-sizing:border-box}
.composer #messageInput[hidden],.composer #voiceRecord[hidden]{display:none!important}
.composer #voiceRecord{display:block;width:100%;height:40px;min-height:40px;padding:6px 8px;font-size:13px!important;border-radius:11px;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
.composer-row>#attachButton,.composer-row>#sendMessage,.composer-row>#composerResize{display:inline-flex;align-items:center;justify-content:center;flex:0 0 34px;width:34px;height:40px;min-height:40px;margin:0;padding:7px;border:0;border-radius:11px;background:transparent;grid-column:auto;grid-row:auto}
.composer-row>#sendMessage{background:var(--red);color:white}.composer-row>#sendMessage[data-empty=true]{background:#f4ece8;color:#845e50}.composer-row>#sendMessage[hidden]{display:none}
#composerResize svg{width:17px;height:17px;color:var(--muted)}
.composer[data-input-mode=voice] #composerResize{display:none}
.composer #chatOptions{display:none!important}
.topbar-actions{direction:ltr;display:flex;flex-wrap:nowrap;align-items:center;gap:4px}
.topbar-actions>#inboxButton{order:10}.topbar-actions>.composer-language{order:11}.topbar-actions>#outputAudioToggle{order:12}.topbar-actions>#conversationToggle{order:13}
.topbar-actions>.composer-language,.topbar-actions>#outputAudioToggle{display:inline-flex;align-items:center;justify-content:center;flex:0 0 40px;width:40px;height:44px;min-height:44px;padding:9px;border:0;border-radius:10px;background:transparent;color:var(--ink)}
.topbar-actions>#outputAudioToggle span{display:none}.topbar-actions>.composer-language svg,.topbar-actions>#outputAudioToggle svg{display:block;width:21px;height:21px;fill:none;stroke:currentColor;stroke-width:1.7}
.topbar-actions>button:hover{background:#f3f3f3}.topbar-actions>#outputAudioToggle[aria-pressed=true]{color:#b5374b;background:#fff0f2}
@media(max-width:767px){.topbar-actions{gap:0}.topbar-actions>button,.topbar-actions>.composer-language,.topbar-actions>#outputAudioToggle{flex:0 0 32px;min-width:32px;width:32px;padding:6px}.topbar-actions>button svg{width:20px;height:20px}.topbar{gap:3px}.conversation-title{min-width:0}}
.topbar-actions>#outputAudioToggle[aria-pressed=false] .audio-off-icon,.topbar-actions>#outputAudioToggle[aria-pressed=true] .audio-on-icon{display:none}
