/* Vordenk — compact layout: less empty space, subheading items packed to the left.
   Loaded last. Spacing only: no colours here. */

/* subheading: mode name, Options, chat name and pin sit together on the left; the free room on the right stays free */
.chat-subheading{ padding:2px 14px; }
.chat-subheading .mode-head{ justify-content:flex-start; gap:6px; }
.chat-subheading .mode-titles{ flex:0 0 auto; }
.chat-subheading .mode-chat{ flex:0 1 auto; justify-content:flex-start; max-width:none; min-width:0; gap:0; }
.chat-subheading .mode-chat-name{ flex:0 1 auto; margin-inline-start:2px; }
.chat-subheading .mode-chat-pin{ width:24px; height:24px; }

/* heading */
.chat-header{ padding-bottom:2px; }
.chat-header-mid{ min-height:22px; }

/* chat column */
.chat-log{ padding:10px 14px; gap:9px; }
.msg-actions{ margin-top:2px; }
.msg-took{ margin-top:4px; }
.translate-row{ margin-top:2px; }
.translate-row .translate-link, .translate-row button{ padding-block:2px; }
.vk-disclaimer{ margin:0; padding:2px 12px 4px; line-height:1.25; }

/* Professionals: one slim title row on phones (traffic lights + tabs), a wider terminal window on desktops */
@media (max-width:699px){
  :root[data-mode="professionals"] .pt-chrome{ display:flex; align-items:flex-end; }
  :root[data-mode="professionals"] .pt-title{ padding:calc(6px + env(safe-area-inset-top)) 4px 8px 12px; }
  :root[data-mode="professionals"] .pt-wtitle, :root[data-mode="professionals"] .pt-split-btn{ display:none; }
  :root[data-mode="professionals"] .pt-tabs{ flex:1; min-width:0; padding:0 8px 0 0; }
}
@media (min-width:700px){
  :root[data-mode="professionals"]:not(.pt-split) #app{ max-width:min(1080px, calc(100vw - 24px)); }
}
:root[data-mode="professionals"] #chat-log{ gap:8px; }
:root[data-mode="professionals"] .pt-hint{ padding:3px 12px 0; }

/* ---- Professionals: heading + subheading merged into one slim row ----
   [ mode ⌄ ] [ Options ⌄ ] ............ [ chat name  pin ]
   The mode pill (it already names the mode) replaces the bold duplicate name; Options, chat name and pin stay. */
.chat-header-mid.is-empty{ display:none; }
.chat-subheading .mode-head-merged{ gap:6px; padding:1px 0; }
.mode-head-merged .source-modes{ position:relative; flex:none; padding:0; justify-content:flex-start; }
.mode-head-merged .source-mode-current{
  font-family:var(--pt-mono, inherit); font-size:12px; letter-spacing:.01em;
  padding:3px 5px 3px 10px; border-radius:5px;
}
.mode-head-merged .mode-opts-btn{
  font-family:var(--pt-mono, inherit); font-size:11.5px; padding:3px 4px 3px 9px; border-radius:5px;
}
.mode-head-merged .mode-chat{ margin-inline-start:auto; flex:0 1 auto; justify-content:flex-end; }
.mode-head-merged .mode-chat-name{ font-family:var(--pt-mono, inherit); font-size:12px; max-width:34vw; }
.mode-head-merged .source-mode-list{ left:0; right:auto; transform:none; }
:root[data-mode="professionals"] .chat-subheading{ padding:4px 12px; }

/* ---- message box: exact round-13 size (the base .composer-pill rules in style.css) — no size overrides here ----
   Kept from later rounds: the shortcuts line under the Professionals box. */
@media (max-width:699px){
  :root[data-mode="professionals"] .pt-hint{ padding:2px 12px 0; font-size:10.5px; gap:8px; }
}
/* no Esc key on a touch screen: drop that part of the shortcuts line so the rest is never cut off */
@media (pointer:coarse){ .pt-hint .pt-esc{ display:none; } }
.pt-hint span{ min-width:0; }
