.composer-tools-grid {
  grid-template-columns: repeat(5, minmax(0, 1fr));
}
.composer-tool-label { color: var(--muted); }
.composer-tools-panel:has(.composer-media-panel:not([hidden])) .voice-feature-hint { display: none; }
.composer-subnav {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  padding: 0 12px;
  color: var(--ink);
  font-weight: 600;
  font-size: 12px;
}
.composer-subnav .text-button { min-height: 36px; }
.emoji-categories { display: flex; flex-wrap: wrap; gap: 3px; padding: 2px 10px 6px; }
.emoji-categories .text-button { min-height: 35px; padding-inline: 9px; color: var(--muted); }
.emoji-categories [aria-pressed="true"] { background: var(--green-light); color: var(--green); font-weight: 650; }
.composer-media-panel { padding: 0 0 12px; }
.composer-media-panel > .button { margin: 6px 12px; }
.composer-media-panel p { margin: 3px 12px 0; line-height: 1.6; }

.voice-bubble { min-width: 0; width: min(240px, 61vw); }
.voice-strip { display: flex; align-items: center; gap: 7px; min-width: 0; margin: 5px 0 0; }
.voice-play-button {
  display: grid;
  place-items: center;
  flex: 0 0 34px;
  width: 34px;
  height: 34px;
  border: 0;
  padding: 0;
  border-radius: 50%;
  background: var(--green);
  color: #fff;
  font-size: 12px;
  font-weight: 650;
}
.voice-play-button:hover { background: #0e674e; }
.voice-timeline { position: relative; flex: 1; min-width: 0; height: 34px; }
.voice-waveform { display: flex; align-items: center; gap: 2px; height: 100%; overflow: hidden; }
.voice-waveform span { flex: 1 0 1px; border-radius: 2px; background: var(--green); opacity: .38; }
.voice-waveform .played { opacity: 1; }
.voice-timeline input[type="range"] { position: absolute; inset: 0; width: 100%; height: 100%; padding: 0; margin: 0; opacity: 0; }
.voice-timeline:focus-within { outline: 2px solid var(--green); outline-offset: 2px; border-radius: 5px; }
.voice-strip .voice-duration { flex: 0 0 auto; color: var(--muted); white-space: nowrap; }
.voice-record-time { border-radius: 12px; margin-top: 15px; background: var(--green-light); padding: 14px 8px; }
.voice-record-dialog[data-recording="true"] .voice-record-time,
.voice-record-dialog[data-recording="true"] .voice-record-status { color: var(--danger); }
.call-invite-recipient { display: flex; align-items: center; gap: 11px; margin: 15px 0; }
.call-invite-recipient strong { overflow-wrap: anywhere; }

@media (max-width: 700px) {
  .composer-tools-grid { gap: 6px; padding: 9px 0; }
  .composer-tool { min-height: 53px; }
  .composer-tools-panel { max-height: min(259px, max(112px, calc(var(--app-viewport-height, 100dvh) - 200px))); }
  .composer-subnav { padding-inline: 3px; }
  .composer-media-panel > .button, .composer-media-panel p { margin-inline: 3px; }
  .emoji-categories { padding-inline: 1px; }
  .composer-tools-panel .voice-feature-hint[data-voice-warning="true"] {
    position: static;
    width: auto;
    height: auto;
    margin: 0;
    padding: 1px 3px 7px;
    clip-path: none;
    white-space: normal;
    color: var(--muted);
    font-size: 12px;
  }
}
@media (pointer: coarse) {
  .composer-subnav .text-button, .emoji-categories .text-button, .composer-media-panel .button { min-height: 44px; }
  .voice-play-button, .voice-timeline { height: 44px; }
  .voice-play-button { width: 44px; flex-basis: 44px; }
}
@media (max-width: 370px) {
  .composer-tool-icon { width: 38px; height: 38px; }
  .composer-tool-icon svg { width: 20px; height: 20px; }
}
