/* ── the chat transcript of the redesign, in every theme ────────────────
   Every message is a row with its writer's face on the left: the writer's
   own avatar, or an agent's * on a blue square and a person's initials on
   a green circle. No bubbles; your own messages sit on the left like the
   rest, marked by your name. A message's address reads "→ @name" in front
   of the words. Every theme reads this way; the selector keeps the weight
   the theme rules have, so a theme's colours still apply. */

.row > .face { display: none; }
.av-md { width: 36px; height: 36px; }
.av-md .picon { width: 20px; height: 20px; }
.av-md .avinitials { font-size: 12px; font-weight: 600; }

:root:not([data-layout="classic"]) .row { justify-content: flex-start; gap: 12px; padding: 4px 4px; }
:root:not([data-layout="classic"]) .row.mine { justify-content: flex-start; }
:root:not([data-layout="classic"]) .row > .face { display: block; flex: 0 0 36px; padding-top: 2px; }
:root:not([data-layout="classic"]) .row > .face .avatar { margin: 0; vertical-align: top; }
:root:not([data-layout="classic"]) .face-agent { background: color-mix(in srgb, var(--agent) 12%, var(--panel)); border: 1.5px solid color-mix(in srgb, var(--agent) 38%, transparent); color: var(--agent); font: 700 18px var(--mono); }
:root:not([data-layout="classic"]) .face-person { background: color-mix(in srgb, var(--human) 10%, var(--panel)); border: 1.5px solid color-mix(in srgb, var(--human) 38%, transparent); color: var(--human); }
:root:not([data-layout="classic"]) .bubble, :root:not([data-layout="classic"]) .row.mine .bubble { flex: 1 1 auto; width: auto; max-width: 100%; background: transparent; border: 0; border-radius: 0; padding: 0; }
:root:not([data-layout="classic"]) .bubble.mentioned { box-shadow: none; }
:root:not([data-layout="classic"]) .row.mentioned:not(.mine) { background: color-mix(in srgb, var(--agent) 6%, transparent); border-radius: 10px; }
:root:not([data-layout="classic"]) .row.pinned-source .bubble { box-shadow: none; }
:root:not([data-layout="classic"]) .row.pinned-source { box-shadow: inset 3px 0 0 var(--iye); border-radius: 4px; }
:root:not([data-layout="classic"]) .row.locareminder .bubble { background: transparent; border: 0; box-shadow: none; }
:root:not([data-layout="classic"]) .row.locareminder { background: color-mix(in srgb, var(--warn) 8%, transparent); border-radius: 10px; }
:root:not([data-layout="classic"]) .line { gap: 8px; margin-bottom: 3px; }
:root:not([data-layout="classic"]) .line .glyph { display: none; }
:root:not([data-layout="classic"]) .line .sender { font-size: 1.07em; font-weight: 600; }
:root:not([data-layout="classic"]) .sender.user, :root:not([data-layout="classic"]) .row.mine .sender { color: var(--txt); }
:root:not([data-layout="classic"]) .line .time { margin-left: 0; padding-left: 0; font: 12px var(--mono); color: var(--dim); }
:root:not([data-layout="classic"]) .body.chatmarkdown { line-height: 1.55; }
/* The actions sit right after the words, not a row gap away. */
:root:not([data-layout="classic"]) .row > .lineacts { margin-left: -12px; }
:root:not([data-layout="classic"]) .bubble .mention.addr { font: 600 13px var(--mono); color: var(--agent); background: color-mix(in srgb, var(--agent) 11%, transparent); border-radius: 5px; padding: 1px 6px; white-space: nowrap; }
:root:not([data-layout="classic"]) .bubble .mention.addr::before { content: "→ "; }
:root:not([data-layout="classic"]) .typing { height: auto; min-height: 20px; padding: 2px 28px 2px 76px; font-size: 13px; font-style: normal; color: var(--dim); }

/* The loca's header: its name and state on the first line, the views on a
   second line of underlined tabs that never has to scroll. */
:root:not([data-layout="classic"]) .top { height: auto; flex: 0 0 auto; flex-wrap: wrap; padding: 14px 24px 0; row-gap: 4px; }
:root:not([data-layout="classic"]) .tophead { flex: 1 1 260px; }
:root:not([data-layout="classic"]) .roomactions { margin-left: auto; }
:root:not([data-layout="classic"]) .top .rname { font-size: 18px; }
:root:not([data-layout="classic"]) .tabs { order: 5; flex: 1 0 100%; width: 100%; margin-left: 0; background: transparent; border: 0;
  border-radius: 0; padding: 0; gap: 20px; }
:root:not([data-layout="classic"]) .tab { padding: 8px 0 9px; border-radius: 0; font: inherit; font-size: 14px; line-height: 16px; }
:root:not([data-layout="classic"]) .tab.active { background: transparent; box-shadow: inset 0 -2px 0 var(--txt); color: var(--txt); font-weight: 600; }

/* ── Loca info beside the chat (locainfo.js) ─────────────────────────────
   Three columns on a wide screen in the redesign themes: the sidebar with
   Your Locas, the chat, and This Loca on the right. */
.locainfo { display: none; }
body.locainfo-on { grid-template-columns: 300px minmax(0, 1fr) 300px; }
body.locainfo-on .locainfo { display: block; grid-column: 3; grid-row: 1 / -1; height: 100vh;
  overflow-y: auto; background: var(--bg); border-left: 1px solid var(--line); padding: 16px 14px;
  box-sizing: border-box; }
body.locainfo-on .side .sideviewtabs { display: none; }
body.locainfo-on .locainfo .sideview { display: block; }

/* ── the composer of the redesign: one line ──────────────────────────────
   Attach, who it is for, the words, Send; /stop and clear stay at the end,
   quiet. The guidance line under it is the address line's job now. */
:root:not([data-layout="classic"]) .composer { display: flex; align-items: center; flex-wrap: nowrap;
  gap: 10px; margin: 0 28px 22px; padding: 8px 10px; border-radius: 12px; background: var(--panel); }
:root:not([data-layout="classic"]) .composer button.attach { order: 1; width: 40px; height: 40px; padding: 0;
  border: 0; border-radius: 8px; background: var(--panel2); display: grid; place-items: center; }
:root:not([data-layout="classic"]) .composer select#target { order: 2; flex: 0 0 auto; max-width: 190px;
  height: 30px; border: 0; border-radius: 5px; background: var(--panel2); color: var(--muted);
  font: 600 13px var(--font-mono, var(--mono)); padding: 0 6px; }
:root:not([data-layout="classic"]) .composer textarea#msg { order: 3; flex: 1 1 auto; min-width: 0; width: auto;
  min-height: 40px; padding: 10px 2px; }
:root:not([data-layout="classic"]) .composer button.send { order: 4; height: 40px; padding: 0 18px; border-radius: 8px;
  font-weight: 600; text-transform: capitalize; }
:root:not([data-layout="classic"]) .composer button.ctl:not(.attach) { order: 5; height: 30px; padding: 0 8px;
  font-size: 12px; border-color: transparent; }
:root:not([data-layout="classic"]) #hint { display: none; }
:root:not([data-layout="classic"]) .addressline { margin: 0 28px 6px; }

/* The board's three planes: the sidebar a shade down, the chat on the
   raised paper, This Loca on the page. */
:root:not([data-layout="classic"]) .main { background: var(--panel); }
@media (max-width: 760px) {
  :root:not([data-layout="classic"]) .composer { margin: 0 8px 10px; flex-wrap: wrap; }
  :root:not([data-layout="classic"]) .composer textarea#msg { flex-basis: 100%; order: 0; }
}

/* ── where one message ends and the next begins ──────────────────────────
   Without bubbles the rows ran together. Each message is a block with room
   around it, a hairline between messages, a soft ground under the one the
   pointer is on, and a thin edge in its writer's colour: blue for an agent,
   green for a person, the brand for your own. */
:root:not([data-layout="classic"]) #feed .row[data-id] { padding: 10px 12px 10px 14px; border-radius: 10px;
  box-shadow: inset 2px 0 0 color-mix(in srgb, var(--human) 55%, transparent); }
:root:not([data-layout="classic"]) #feed .row[data-id][data-kind="agent"] {
  box-shadow: inset 2px 0 0 color-mix(in srgb, var(--agent) 60%, transparent); }
:root:not([data-layout="classic"]) #feed .row[data-id].mine {
  box-shadow: inset 2px 0 0 var(--brand); }
:root:not([data-layout="classic"]) #feed .row[data-id] + .row[data-id] { margin-top: 2px; }
:root:not([data-layout="classic"]) #feed .row[data-id] + .row[data-id]::before { content: ""; position: absolute;
  left: 62px; right: 12px; top: -2px; height: 1px; background: color-mix(in srgb, var(--line) 70%, transparent); }
:root:not([data-layout="classic"]) #feed .row[data-id]:hover { background: color-mix(in srgb, var(--panel2) 55%, transparent); }
:root:not([data-layout="classic"]) #feed .row[data-id].mentioned:not(.mine) {
  background: color-mix(in srgb, var(--agent) 7%, transparent); }
:root:not([data-layout="classic"]) #feed .row[data-id].locareminder { box-shadow: inset 3px 0 0 var(--warn); }
:root:not([data-layout="classic"]) #feed .row[data-id].pinned-source { box-shadow: inset 3px 0 0 var(--iye); }

/* ── This Loca beside the chat: who is at the table, read at a glance ─────
   The panel is narrow: a seat shows its mark, the whole name and its state;
   the kit version and the seat's actions (release, mute, message, more)
   come forward on hover or keyboard focus instead of squeezing the name. */
#locaInfo { overflow-x: hidden; }
#locaInfo .omem { position: relative; gap: 10px; padding: 7px 4px; font-size: 14px; border-radius: 8px; }
#locaInfo .omem .oname { flex: 1 1 auto; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
#locaInfo .omem .obadges { flex: 0 0 auto; }
#locaInfo .omem .kitver, #locaInfo .omem .kitold { display: none; }
#locaInfo .omem .seatacts { position: absolute; right: 2px; top: 50%; transform: translateY(-50%);
  padding: 2px 4px; border-radius: 8px; background: var(--panel); border: 1px solid var(--line);
  opacity: 0; pointer-events: none; }
#locaInfo .omem:hover .seatacts, #locaInfo .omem:focus-within .seatacts { opacity: 1; pointer-events: auto; }
#locaInfo .omem:hover { background: color-mix(in srgb, var(--panel2) 60%, transparent); }
#locaInfo .online { margin: 0; }
#locaInfo .online .rlabel { padding: 6px 4px; }
#locaInfo .callbtn { margin: 10px 0 0; width: 100%; }
