:root {
  --bg: #0b1020;
  --bg-2: #111832;
  --panel: #151d3a;
  --line: #243058;
  --text: #eef1fa;
  --muted: #8f9bbf;
  --red: #e0283d;
  --red-2: #ff4a5c;
  --mine: #2a1d36;
  --ok: #3ccf8e;
  --radius: 14px;
  --font: "Inter", system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
}

* { box-sizing: border-box; }
html, body { height: 100%; margin: 0; }
html { background: var(--bg); }
body {
  background: radial-gradient(1200px 600px at 80% -10%, #2a1230 0%, transparent 60%),
              radial-gradient(900px 500px at -10% 110%, #0f2a4a 0%, transparent 60%), var(--bg);
  color: var(--text);
  font: 15px/1.45 var(--font);
  -webkit-font-smoothing: antialiased;
}
[hidden] { display: none !important; }
button { font: inherit; color: inherit; cursor: pointer; }
input, textarea { font: inherit; color: var(--text); }
a { color: var(--red-2); }

.dot { display: inline-block; width: .55em; height: .55em; border-radius: 50%; background: var(--red);
  box-shadow: 0 0 0 .18em rgba(224, 40, 61, .25); margin-inline-end: .45em; vertical-align: .08em; }
.muted { color: var(--muted); }

.btn { border: 1px solid var(--line); background: var(--panel); border-radius: 10px; padding: .65em 1.1em; font-weight: 600; }
.btn.primary { background: var(--red); border-color: var(--red); color: #fff; }
.btn.primary:hover { background: var(--red-2); }
.btn.ghost { background: transparent; }
.link { background: none; border: 0; color: var(--muted); padding: .3em; text-decoration: underline; }

/* Auth */
.auth { min-height: 100%; display: grid; place-items: center; padding: calc(24px + env(safe-area-inset-top)) 16px calc(24px + env(safe-area-inset-bottom)); }
.auth-card { width: 100%; max-width: 400px; background: rgba(21, 29, 58, .85); border: 1px solid var(--line);
  border-radius: 20px; padding: 32px 28px 22px; backdrop-filter: blur(8px); box-shadow: 0 30px 80px rgba(0, 0, 0, .45); }
.brand-big { display: flex; align-items: center; gap: 12px; font-size: 34px; font-weight: 800; letter-spacing: .01em; }
.brand-big .c, .brand .c, .talk { color: var(--red-2); }
.room.on .talk { color: #fff; }
.tagline { color: var(--muted); margin: 6px 0 22px; }
.tabs { display: flex; gap: 4px; background: var(--bg-2); padding: 4px; border-radius: 12px; margin-bottom: 18px; }
.tab { flex: 1; border: 0; background: none; padding: .55em; border-radius: 9px; color: var(--muted); font-weight: 600; }
.tab.active { background: var(--panel); color: var(--text); }
.form { display: grid; gap: 14px; }
.form label { display: grid; gap: 6px; font-size: 13px; color: var(--muted); }
.form-row { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.form-note { color: var(--muted); font-size: 12px; margin-top: -6px; }
.form select { background: var(--bg-2); border: 1px solid var(--line); border-radius: 10px; padding: .7em .6em; font-size: 15px; color: var(--text); }
.form input[type=date] { color-scheme: dark; }
.form input:not([type=checkbox]) { background: var(--bg-2); border: 1px solid var(--line); border-radius: 10px; padding: .7em .8em; font-size: 15px; }
.form input:focus, textarea:focus { outline: 2px solid rgba(224, 40, 61, .55); outline-offset: 0; }
.form small { color: var(--muted); font-size: 12px; }
.form .check { display: flex; gap: 10px; align-items: flex-start; color: var(--text); font-size: 14px; }
.form .check input { margin-top: 3px; accent-color: var(--red); }
.auth-foot { display: flex; justify-content: space-between; align-items: center; margin-top: 22px; font-size: 13px; color: var(--muted); }
.auth-foot a { color: var(--muted); }
/* Language dropdown (same look as on the landing page) */
.lang-menu { position: relative; }
.lang-menu summary { list-style: none; cursor: pointer; display: inline-flex; align-items: center; gap: 6px; padding: 5px 11px;
  border-radius: 999px; border: 1px solid rgba(58, 160, 255, .55); background: rgba(58, 160, 255, .12); color: #cfe6ff;
  font-size: 13px; font-weight: 700; letter-spacing: .04em; }
.lang-menu summary::-webkit-details-marker { display: none; }
.lang-menu summary:hover, .lang-menu[open] summary { background: rgba(58, 160, 255, .22); border-color: #3aa0ff; }
.lang-menu .globe { color: #3aa0ff; }
.lang-menu[open] .chev { transform: rotate(180deg); }
.lang-list { position: absolute; inset-inline-end: 0; top: calc(100% + 6px); min-width: 170px; padding: 6px; border-radius: 12px;
  background: var(--panel); border: 1px solid var(--line); box-shadow: 0 16px 40px rgba(0, 0, 0, .45); z-index: 35; }
.auth-foot .lang-list { top: auto; bottom: calc(100% + 6px); inset-inline-start: 0; inset-inline-end: auto; }
.lang-list button { display: flex; align-items: center; gap: 10px; width: 100%; text-align: start; border: 0; background: none; padding: .55em .7em; border-radius: 8px; font-size: 14px; }
.lang-list button b { font-size: 11px; color: var(--muted); width: 20px; }
.lang-list button:hover { background: var(--bg-2); }
.lang-list button.on { background: rgba(58, 160, 255, .14); }
.lang-list button.on::after { content: "✓"; margin-inline-start: auto; color: #3aa0ff; font-weight: 800; }

/* Chat layout */
.chat { height: 100%; height: 100dvh; display: flex; flex-direction: column; }
.top { display: flex; align-items: center; gap: 16px; padding: calc(10px + env(safe-area-inset-top)) calc(16px + env(safe-area-inset-right)) 10px calc(16px + env(safe-area-inset-left)); border-bottom: 1px solid var(--line);
  background: rgba(11, 16, 32, .8); backdrop-filter: blur(8px); }
.brand { display: inline-flex; align-items: center; gap: 8px; font-weight: 800; font-size: 20px; letter-spacing: .01em; text-decoration: none; color: inherit; }
.rooms { display: flex; gap: 6px; overflow-x: auto; flex: 1; scrollbar-width: none; }
.room { border: 1px solid var(--line); background: none; border-radius: 999px; padding: .35em .9em; white-space: nowrap; color: var(--muted); font-weight: 600; font-size: 14px; }
.room.on { background: var(--red); border-color: var(--red); color: #fff; }
.room.community { border-color: rgba(58, 160, 255, .55); color: #cfe6ff; background: rgba(58, 160, 255, .1); }

/* Top bar: overview button + current room */
.rooms { align-items: center; gap: 10px; }
.overview-btn { flex: none; width: 38px; height: 34px; display: grid; place-items: center; border-radius: 10px; border: 1px solid var(--line); background: var(--panel); color: var(--muted); }
.overview-btn:hover { color: var(--text); border-color: #3aa0ff; }
.overview-btn.on { color: #fff; background: #1f6fd1; border-color: #3aa0ff; }
.current-room { display: inline-flex; align-items: center; gap: 8px; font-weight: 800; font-size: 16px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.current-icon { font-size: 18px; display: inline-flex; }
.current-icon .icon-img { width: 22px; height: 22px; }
.tile .ic .icon-img { width: 30px; height: 30px; display: block; }

/* Overview (lobby) */
.lobby { flex: 1; min-height: 0; overflow-y: auto; }
.lobby-wrap { max-width: 1000px; margin: 0 auto; padding: 26px 20px calc(40px + env(safe-area-inset-bottom)); }
.lobby-hello { display: flex; justify-content: space-between; align-items: flex-end; gap: 14px; flex-wrap: wrap; margin-bottom: 18px; }
.lobby-hello h1 { margin: 0; font-size: clamp(24px, 4vw, 34px); }
.lobby-hello p { margin: 4px 0 0; color: var(--muted); }
.lobby-live { display: inline-flex; align-items: center; gap: 8px; border: 1px solid var(--line); border-radius: 999px; padding: 6px 12px; font-size: 14px; color: var(--muted); }
.lobby-live i { width: 8px; height: 8px; border-radius: 50%; background: var(--ok); box-shadow: 0 0 0 4px rgba(60, 207, 142, .2); }
.lobby-live b { color: var(--text); }
.lobby h2 { font-size: 13px; letter-spacing: .1em; text-transform: uppercase; color: var(--muted); margin: 24px 0 10px; display: flex; justify-content: space-between; gap: 10px; }
.lobby h2 small { text-transform: none; letter-spacing: 0; font-size: 13px; }
.lobby button { text-align: start; color: var(--text); }
.lobby-notes { display: grid; grid-template-columns: repeat(auto-fit, minmax(260px, 1fr)); gap: 12px; }
.lobby-note { display: flex; align-items: center; gap: 12px; padding: 14px 16px; border-radius: 14px; border: 1px solid var(--line); background: var(--panel); }
.lobby-note .ic { width: 40px; height: 40px; border-radius: 12px; display: grid; place-items: center; font-size: 19px; background: var(--bg-2); flex: none; }
.lobby-note b, .lobby-note small { display: block; }
.lobby-note small { color: var(--muted); }
.lobby-note .go { margin-inline-start: auto; color: var(--muted); font-size: 18px; }
.lobby-note.dm { border-color: rgba(224, 40, 61, .6); background: linear-gradient(135deg, rgba(224, 40, 61, .16), var(--panel)); }
.lobby-note.dm .ic { background: var(--red); }
.lobby-main { width: 100%; display: flex; flex-direction: column; gap: 12px; padding: 20px; border-radius: 18px; border: 1px solid var(--line);
  background: linear-gradient(140deg, rgba(224, 40, 61, .22) 0%, rgba(21, 29, 58, .95) 55%), var(--panel); transition: transform .15s, border-color .15s; }
.lobby-main:hover { transform: translateY(-2px); border-color: var(--red); }
.lobby-main .row { display: flex; align-items: center; gap: 12px; }
.lobby-main .ic { width: 48px; height: 48px; border-radius: 14px; display: grid; place-items: center; font-size: 24px; background: var(--red); flex: none; }
.lobby-main h3 { margin: 0; font-size: 20px; }
.lobby-main .meta { display: flex; gap: 10px; flex-wrap: wrap; color: var(--muted); font-size: 13px; }
.lobby-main .last { background: rgba(11, 16, 32, .55); border: 1px solid var(--line); border-radius: 12px; padding: 10px 12px; font-size: 14px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.lobby-main .last b { color: #9fb4ff; margin-inline-end: 6px; }
.lobby-main .enter { align-self: flex-start; background: var(--red); color: #fff; font-weight: 700; border-radius: 10px; padding: 8px 14px; font-size: 14px; }
.lobby .on { color: var(--ok); font-weight: 700; }
.lobby .quiet { color: var(--muted); }
.tile { display: flex; flex-direction: column; gap: 3px; padding: 14px; border-radius: 14px; border: 1px solid var(--line); background: rgba(21, 29, 58, .75); transition: border-color .15s, transform .15s; }
.tile:hover { transform: translateY(-2px); }
.tile .ic { font-size: 24px; margin: 4px 0 2px; }
.tile b { font-size: 15px; line-height: 1.25; }
.tile small { font-size: 12px; }
.lobby-mainrow { display: grid; grid-template-columns: repeat(auto-fill, minmax(170px, 1fr)); gap: 10px; }
.tile.tile-main { border-color: rgba(224, 40, 61, .75); background: linear-gradient(160deg, rgba(224, 40, 61, .28), rgba(21, 29, 58, .9)); box-shadow: 0 10px 30px rgba(224, 40, 61, .18); }
.tile.tile-main:hover { border-color: var(--red-2); }
.lobby-events { display: flex; gap: 10px; overflow-x: auto; padding-bottom: 6px; scrollbar-width: thin; scrollbar-color: var(--line) transparent; }
.lobby-events .tile { flex: none; width: 190px; }
.lobby-events .tile:hover { border-color: #ffc27a; }
.lobby-events .when { font-size: 11px; font-weight: 800; letter-spacing: .08em; text-transform: uppercase; color: #ffc27a; }
.lobby-events .tile.live { border-color: rgba(60, 207, 142, .7); background: linear-gradient(160deg, rgba(60, 207, 142, .16), rgba(21, 29, 58, .9)); }
.lobby-events .tile.live .when { color: var(--ok); }
.lobby-topics { display: grid; grid-template-columns: repeat(auto-fill, minmax(170px, 1fr)); gap: 10px; }
.lobby-topics .tile { border-top: 3px solid #b06cff; }
.lobby-topics .tile:nth-child(2) { border-top-color: #3ccf8e; }
.lobby-topics .tile:nth-child(3) { border-top-color: #ffb347; }
.lobby-topics .tile:nth-child(4) { border-top-color: #ffd166; }
.lobby-topics .tile:nth-child(5) { border-top-color: #9fb4ff; }
.lobby-langs { display: grid; grid-template-columns: repeat(auto-fill, minmax(170px, 1fr)); gap: 10px; }
.lobby-langs .tile:hover { border-color: #3aa0ff; }
.lobby-langs .tile b { font-size: 17px; }
.lobby-langs .tile.mine { border-color: rgba(58, 160, 255, .7); background: rgba(58, 160, 255, .12); }
.lobby-foot { display: flex; gap: 8px; align-items: center; margin-top: 26px; color: var(--muted); font-size: 14px; cursor: pointer; }
.lobby-foot input { accent-color: var(--red); }
.room.community.on { background: #1f6fd1; border-color: #3aa0ff; color: #fff; }
.top-right { display: flex; align-items: center; gap: 8px; }
.me-btn { border: 1px solid var(--line); background: var(--panel); border-radius: 999px; padding: .35em .9em; font-weight: 600; font-size: 14px; }
.icon-btn { display: none; position: relative; border: 1px solid var(--line); background: var(--panel); border-radius: 10px; width: 38px; height: 34px; }

.main { flex: 1; min-height: 0; display: grid; grid-template-columns: 1fr 260px; }
.pane { display: flex; flex-direction: column; min-height: 0; min-width: 0; }
.pane-head { padding: 12px 18px; border-bottom: 1px solid var(--line); display: flex; align-items: center; gap: 10px; font-weight: 700; }
.pane-head .sub { color: var(--muted); font-weight: 400; font-size: 13px; }
.pane-head .back { border: 1px solid var(--line); background: none; border-radius: 8px; padding: .2em .6em; color: var(--muted); }
.pane-head .clear { margin-left: auto; font-weight: 400; font-size: 13px; }
.pane-head .clear:hover { color: var(--red-2); border-color: var(--red); }
.log { flex: 1; overflow-y: auto; padding: 14px 18px; display: flex; flex-direction: column; gap: 2px; }
.empty { margin: auto; color: var(--muted); text-align: center; max-width: 280px; }

.msg { display: grid; grid-template-columns: auto 1fr auto; gap: 0 10px; padding: 5px 8px; border-radius: 10px; align-items: baseline; }
.msg:hover { background: rgba(255, 255, 255, .03); }
.msg .nick { font-weight: 700; border: 0; background: none; padding: 0; color: var(--nick, #9fb4ff); }
.msg .body { white-space: pre-wrap; overflow-wrap: anywhere; }
.msg .time { color: var(--muted); font-size: 11px; }
.msg .flag { grid-column: 3; border: 0; background: none; color: var(--muted); font-size: 12px; opacity: 0; padding: 0 2px; }
.msg:hover .flag, .msg .flag:focus { opacity: 1; }
.msg.mine .nick { color: var(--red-2); }

.bubble-row { display: flex; margin: 3px 0; }
.bubble-row.mine { justify-content: flex-end; }
.bubble { max-width: 75%; background: var(--panel); border: 1px solid var(--line); border-radius: 16px 16px 16px 4px; padding: .5em .8em; white-space: pre-wrap; overflow-wrap: anywhere; }
.bubble-row.mine .bubble { background: var(--mine); border-color: #4a2a55; border-radius: 16px 16px 4px 16px; }
.bubble .time { display: block; color: var(--muted); font-size: 11px; margin-top: 2px; }
.bubble .flag { border: 0; background: none; color: var(--muted); font-size: 11px; padding: 0; margin-left: 8px; }

.composer { position: relative; display: flex; gap: 10px; padding: 12px 16px calc(12px + env(safe-area-inset-bottom)); border-top: 1px solid var(--line); }

/* Emoji picker */
.emoji-btn { flex: none; width: 44px; border: 1px solid var(--line); background: var(--bg-2); border-radius: 12px; font-size: 20px; line-height: 1; }
.emoji-btn:hover { border-color: #3aa0ff; }
.emoji-panel { position: absolute; bottom: calc(100% + 6px); inset-inline-start: 16px; width: min(360px, calc(100vw - 32px)); background: var(--panel);
  border: 1px solid var(--line); border-radius: 16px; box-shadow: 0 20px 50px rgba(0, 0, 0, .5); z-index: 30; overflow: hidden; }
.emoji-tabs { display: flex; gap: 2px; padding: 6px; border-bottom: 1px solid var(--line); background: var(--bg-2); }
.emoji-tabs button { flex: 1; border: 0; background: none; border-radius: 8px; padding: 6px 0; font-size: 18px; opacity: .55; }
.emoji-tabs button.on, .emoji-tabs button:hover { opacity: 1; background: var(--panel); }
.emoji-grid { display: grid; grid-template-columns: repeat(8, 1fr); gap: 2px; padding: 8px; max-height: 230px; overflow-y: auto; scrollbar-width: thin; scrollbar-color: var(--line) transparent; }
.emoji-grid button { border: 0; background: none; border-radius: 8px; font-size: 24px; line-height: 1; padding: 6px 0; }
.emoji-grid button:hover { background: var(--bg-2); transform: scale(1.15); }
.msg .body.jumbo { font-size: 30px; line-height: 1.2; }
.bubble.jumbo { font-size: 34px; line-height: 1.2; background: none !important; border-color: transparent !important; padding: 0; }
.composer textarea { flex: 1; resize: none; overflow-y: hidden; background: var(--bg-2); border: 1px solid var(--line); border-radius: 12px; padding: .65em .85em; max-height: 140px; }
.composer.closed { opacity: .5; pointer-events: none; }

.side { border-inline-start: 1px solid var(--line); overflow-y: auto; padding: 8px 10px; background: rgba(17, 24, 50, .5); }
.side h3 { font-size: 11px; text-transform: uppercase; letter-spacing: .1em; color: var(--muted); margin: 14px 8px 6px; }
.count { color: var(--ok); }
.list { list-style: none; margin: 0; padding: 0; }
.list button { width: 100%; text-align: start; border: 0; background: none; border-radius: 9px; padding: .45em .6em; display: flex; justify-content: space-between; align-items: center; gap: 8px; }
.list button:hover, .list button.on { background: var(--panel); }
.list .who::before { content: ""; display: inline-block; width: 7px; height: 7px; border-radius: 50%; background: var(--ok); margin-inline-end: 8px; vertical-align: .1em; }
.list .who.off::before { background: var(--line); }
.list .none { color: var(--muted); font-size: 13px; padding: .3em .6em; }
.badge { background: var(--red); color: #fff; font-size: 11px; font-weight: 700; border-radius: 999px; padding: 0 .5em; min-width: 1.6em; text-align: center; }
.icon-btn .badge { position: absolute; top: -6px; right: -6px; }

/* Menu, modal, toasts */
.menu { position: fixed; z-index: 30; background: var(--panel); border: 1px solid var(--line); border-radius: 12px; padding: 6px; min-width: 190px; box-shadow: 0 16px 40px rgba(0, 0, 0, .45); }
.menu .title { padding: .4em .7em; font-weight: 700; color: var(--muted); font-size: 13px; }
.menu button { display: block; width: 100%; text-align: start; border: 0; background: none; padding: .55em .7em; border-radius: 8px; }
.menu button:hover { background: var(--bg-2); }
.menu button.danger { color: var(--red-2); }

/* Profile card (opens from a nickname) and profile editor */
.profile { width: 260px; max-width: 80vw; padding: 8px 8px 10px; border-bottom: 1px solid var(--line); margin-bottom: 4px; }
.profile-head { display: flex; align-items: center; gap: 10px; }
.avatar { flex: none; width: 40px; height: 40px; border-radius: 50%; display: grid; place-items: center; font-weight: 800; color: #0b1020; font-size: 18px; }
.profile-name { display: flex; flex-direction: column; min-width: 0; }
.profile-name b { font-size: 16px; overflow: hidden; text-overflow: ellipsis; }
.profile-name small { color: var(--muted); font-size: 13px; }
.profile-online { margin-inline-start: auto; font-size: 12px; color: var(--ok); }
.profile-bio { margin: 10px 0 0; font-size: 14px; white-space: pre-wrap; overflow-wrap: anywhere; }
.profile-bio.empty { color: var(--muted); font-style: italic; }
.profile-form { display: grid; gap: 14px; }
.profile-form label { display: grid; gap: 6px; font-size: 13px; color: var(--muted); }
.profile-form select { background: var(--bg-2); border: 1px solid var(--line); border-radius: 10px; padding: .6em; color: var(--text); font: inherit; }
.profile-form input[type=date] { color-scheme: dark; }
.profile-form small { font-size: 12px; }
.profile-form .count-chars { text-align: end; }
.profile-age { margin: 0; color: var(--text); }
.modal { position: fixed; inset: 0; z-index: 40; background: rgba(5, 8, 18, .7); display: grid; place-items: center; padding: 16px; }
.modal-card { width: 100%; max-width: 420px; background: var(--panel); border: 1px solid var(--line); border-radius: 18px; padding: 22px; }
.modal-card h2 { margin: 0 0 8px; font-size: 19px; }
.modal-card p { color: var(--muted); margin: 0 0 14px; }
.modal-card .actions { display: flex; justify-content: flex-end; gap: 8px; margin-top: 18px; }
.modal-card textarea, .modal-card input { width: 100%; background: var(--bg-2); border: 1px solid var(--line); border-radius: 10px; padding: .65em .8em; }
.code { font: 700 22px/1.2 ui-monospace, Consolas, monospace; letter-spacing: .08em; text-align: center; background: var(--bg-2); border: 1px dashed var(--red); border-radius: 12px; padding: 16px; user-select: all; }
.report { border: 1px solid var(--line); border-radius: 12px; padding: 10px 12px; margin-bottom: 10px; font-size: 14px; }
.report .meta { color: var(--muted); font-size: 12px; margin-bottom: 4px; }
.report .q { background: var(--bg-2); border-radius: 8px; padding: 6px 8px; margin: 6px 0; white-space: pre-wrap; }
.report .row { display: flex; gap: 6px; flex-wrap: wrap; }
.report .btn { padding: .35em .7em; font-size: 13px; }
.reports-list { max-height: 60vh; overflow-y: auto; }
.setting { display: flex; gap: 10px; align-items: flex-start; margin: 8px 0; color: var(--text); }
.setting input { width: auto; accent-color: var(--red); margin-top: 4px; }
.toasts { position: fixed; bottom: 90px; left: 50%; transform: translateX(-50%); z-index: 50; display: grid; gap: 8px; width: min(92vw, 380px); }
.toast { background: #2a1420; border: 1px solid var(--red); color: var(--text); border-radius: 12px; padding: .7em 1em; box-shadow: 0 10px 30px rgba(0, 0, 0, .4); animation: in .2s ease-out; }
.toast.ok { background: #10291f; border-color: var(--ok); }
@keyframes in { from { opacity: 0; transform: translateY(6px); } }

@media (max-width: 760px) {
  .top { gap: 10px; padding: calc(8px + env(safe-area-inset-top)) 12px 8px; flex-wrap: wrap; }
  .lobby-topics, .lobby-langs, .lobby-mainrow { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .lobby-wrap { padding-left: 14px; padding-right: 14px; }
  .lobby-events .tile { width: 165px; }
  .rooms { order: 3; flex-basis: 100%; }
  .top-right { margin-left: auto; }
  .top .lang-menu summary .chev, .top .lang-menu summary .lang-current { display: none; }
  .top .lang-menu summary { padding: 7px 9px; }
  .icon-btn { display: inline-block; }
  .main { grid-template-columns: 1fr; }
  .side { position: fixed; top: 0; right: 0; bottom: 0; width: min(80vw, 300px); z-index: 20; background: var(--bg-2);
    transform: translateX(100%); transition: transform .2s ease; padding-top: 16px; }
  .side.open { transform: none; box-shadow: -20px 0 60px rgba(0, 0, 0, .5); }
  [dir=rtl] .side { right: auto; left: 0; transform: translateX(-100%); }
  [dir=rtl] .side.open { transform: none; }
  .pane-head { padding: 10px 12px; }
  .pane-head .sub { display: none; }
  .pane-head:not(:has(.back)) { display: none; }
  .log { padding: 10px 12px; }
  .msg { grid-template-columns: auto 1fr; }
  .msg .time { display: none; }
  .msg .flag { opacity: .6; grid-column: 2; justify-self: end; }
}
