/* Cuib — temă de primăvară: flori de cireș */
:root {
  /* Temă de noapte: flori de cireș sub lună (implicită) */
  --blossom: #f59bbd;
  --sakura: #e2588f;
  --sakura-hover: #ef6c9f;
  --bark: #f4e6ec;
  --leaf: #5cc27a;
  --branch: #a8807a;
  --bg-side: rgba(29, 20, 27, .985);
  --bg-main: rgba(23, 16, 22, .975);
  --bg-members: rgba(29, 20, 27, .98);
  --surface: #2a1f27;
  --hover: #33252e;
  --active: #46303e;
  --line: #3a2b35;
  --text: var(--bark);
  --muted: #b9a2ad;
  --faint: #86717c;
  --accent: var(--sakura);
  --accent-ink: #ffffff;
  --accent-soft: rgba(226, 88, 143, .18);
  --ok: var(--leaf);
  --danger: #f06070;
  --stage: #130d12;
  --shadow: 0 1px 2px rgba(0, 0, 0, .3), 0 8px 24px rgba(0, 0, 0, .35);
  --overlay: rgba(10, 6, 9, .62);
  --label-bg: rgba(22, 15, 20, .82);
  --link: #8fc1ff;
  --msg-hover: rgba(255, 255, 255, .03);
  --mention-bg: rgba(226, 88, 143, .12);
  --voice-panel-bg: rgba(255, 255, 255, .03);
  --user-panel-bg: rgba(0, 0, 0, .28);
  --ring: #1d141b;
  --scroll: #4a3843;
  --login-card: rgba(36, 26, 33, .94);
  --tile-bg: linear-gradient(160deg, #2b1f28 0%, #21171f 100%);
  --panel-solid: #1e161c;
  --ctl-off-bg: rgba(240, 96, 112, .16);
  --page-bg:
    radial-gradient(1100px 600px at 100% 0%, rgba(214, 70, 124, .20), transparent 60%),
    radial-gradient(900px 700px at 0% 100%, rgba(90, 80, 170, .16), transparent 60%),
    linear-gradient(170deg, #1d1419 0%, #171016 50%, #130e15 100%);
  --font: "Nunito", "Segoe UI", system-ui, -apple-system, Roboto, sans-serif;
  --display: "Fredoka", "Nunito", "Segoe UI", system-ui, sans-serif;
  color-scheme: dark;
}
:root[data-theme="light"] {
  /* Temă de zi: roz deschis */
  --blossom: #f28bb0;
  --sakura: #d6467c;
  --sakura-hover: #c43a6e;
  --bark: #4b2f3a;
  --leaf: #4f9e64;
  --branch: #6e4a48;
  --bg-side: rgba(255, 248, 251, .88);
  --bg-main: rgba(255, 255, 255, .78);
  --bg-members: rgba(255, 248, 251, .82);
  --surface: #ffffff;
  --hover: #fce6ee;
  --active: #f9d5e3;
  --line: #f1d6e1;
  --muted: #8a6575;
  --faint: #b893a3;
  --accent-soft: #fde0eb;
  --danger: #d94350;
  --stage: #f7e7ee;
  --shadow: 0 1px 2px rgba(120, 40, 70, .06), 0 8px 24px rgba(160, 60, 100, .10);
  --overlay: rgba(75, 47, 58, .35);
  --label-bg: rgba(255, 255, 255, .9);
  --link: #2f74c0;
  --msg-hover: rgba(251, 219, 230, .3);
  --mention-bg: rgba(253, 224, 235, .6);
  --voice-panel-bg: rgba(255, 255, 255, .6);
  --user-panel-bg: rgba(251, 219, 230, .55);
  --ring: #ffffff;
  --scroll: #efc6d6;
  --login-card: rgba(255, 255, 255, .9);
  --tile-bg: linear-gradient(160deg, #fff 0%, #fdeef4 100%);
  --panel-solid: #fff8fb;
  --ctl-off-bg: #fde4e6;
  --page-bg:
    radial-gradient(1200px 600px at 100% 0%, rgba(252, 205, 222, .75), transparent 60%),
    radial-gradient(900px 700px at 0% 100%, rgba(225, 236, 248, .9), transparent 60%),
    linear-gradient(170deg, #fff4f8 0%, #fbeaf1 45%, #f1eef8 100%);
  color-scheme: light;
}
* { box-sizing: border-box; }
html, body { margin: 0; height: 100%; color: var(--text); font: 15px/1.5 var(--font); -webkit-font-smoothing: antialiased; }
body { background: var(--page-bg); background-color: #171016; background-attachment: fixed; }
:root[data-theme="light"] body { background-color: #fbeaf1; }
button { font: inherit; color: inherit; background: none; border: 0; cursor: pointer; }
input, textarea, select { font: inherit; color: var(--text); }
[hidden] { display: none !important; }
svg { display: block; flex-shrink: 0; }
::selection { background: var(--active); }
::-webkit-scrollbar { width: 10px; height: 10px; }
::-webkit-scrollbar-thumb { background: var(--scroll); border-radius: 10px; border: 3px solid transparent; background-clip: padding-box; }
:focus-visible { outline: 2px solid var(--sakura); outline-offset: 2px; }

/* petale care cad (în spatele aplicației) */
.petals { position: fixed; inset: 0; width: 100%; height: 100%; pointer-events: none; z-index: 0; }

/* ---------- brand ---------- */
.brand-mark { width: 30px; height: 30px; flex-shrink: 0; filter: drop-shadow(0 1px 1px rgba(160, 50, 90, .25)); }

/* ---------- intrare ---------- */
.login { position: relative; z-index: 1; min-height: 100%; display: grid; place-items: center; padding: 24px 16px; }
.login-card { position: relative; width: 100%; max-width: 390px; background: var(--login-card); border: 1px solid var(--line); border-radius: 22px; padding: 64px 28px 28px; box-shadow: var(--shadow); }
.login-branch { position: absolute; top: -46px; right: -38px; width: 250px; height: 133px; pointer-events: none; }
.login-card h1 { margin: 0; font: 600 40px/1.1 var(--display); color: var(--sakura); letter-spacing: -.01em; }
.login-card .sub { color: var(--muted); margin: 6px 0 26px; }
.field { display: block; margin-bottom: 16px; }
.field > span { display: block; font-size: 13px; font-weight: 700; color: var(--muted); margin-bottom: 6px; }
.field input, .field select, .modal input, .modal select { width: 100%; padding: 11px 13px; background: var(--surface); border: 1.5px solid var(--line); border-radius: 12px; outline: none; transition: border-color .15s; }
.field input:focus, .modal input:focus, .modal select:focus { border-color: var(--blossom); }
.colors { display: flex; gap: 8px; flex-wrap: wrap; }
.colors button { width: 30px; height: 30px; border-radius: 50%; border: 3px solid var(--surface); box-shadow: 0 0 0 1px var(--line); }
.colors button.on { box-shadow: 0 0 0 2.5px var(--bark); }
.err { color: var(--danger); font-size: 14px; min-height: 20px; margin-bottom: 8px; font-weight: 600; }

.btn { padding: 10px 18px; border-radius: 999px; font-weight: 700; background: var(--hover); color: var(--bark); transition: filter .15s, background .15s; }
.btn:hover { background: var(--active); }
.btn.primary { background: var(--sakura); color: #fff; box-shadow: 0 4px 12px rgba(214, 70, 124, .3); }
.btn.primary:hover { background: var(--sakura-hover); }
.btn.danger { background: var(--danger); color: #fff; }
.btn.ok { background: var(--leaf); color: #fff; }
.btn.danger:hover, .btn.ok:hover { filter: brightness(1.08); }
.btn.wide { width: 100%; padding: 13px; font-size: 16px; }

/* ---------- layout ---------- */
.app { position: relative; z-index: 1; display: grid; grid-template-columns: 256px 1fr 236px; height: 100vh; height: 100dvh; overflow: hidden; }
.sidebar { background: var(--bg-side); display: flex; flex-direction: column; min-width: 0; border-right: 1px solid var(--line); position: relative; }
.main { display: flex; flex-direction: column; min-width: 0; min-height: 0; background: var(--bg-main); }
.members { background: var(--bg-members); border-left: 1px solid var(--line); overflow-y: auto; padding: 8px; }
.app.no-members { grid-template-columns: 256px 1fr 0; }
.app.no-members .members { display: none; }

.side-head { position: relative; height: 60px; display: flex; align-items: center; gap: 10px; padding: 0 16px; border-bottom: 1px solid var(--line); overflow: hidden; }
.side-head strong { font: 600 22px/1 var(--display); color: var(--sakura); position: relative; z-index: 1; }
.side-head .brand-mark { position: relative; z-index: 1; }
.side-branch { position: absolute; right: -36px; top: -18px; width: 150px; height: 80px; opacity: .9; pointer-events: none; }
.conn-dot { position: relative; z-index: 1; width: 9px; height: 9px; border-radius: 50%; background: var(--leaf); margin-left: 4px; box-shadow: 0 0 0 3px rgba(79, 158, 100, .18); }
.conn-dot.off { background: var(--danger); box-shadow: 0 0 0 3px rgba(217, 67, 80, .18); animation: blink 1s infinite; }
@keyframes blink { 50% { opacity: .3; } }
.side-scroll { flex: 1; overflow-y: auto; padding: 8px 8px 16px; }
.sec { display: flex; align-items: center; justify-content: space-between; padding: 16px 8px 6px; font-size: 13px; font-weight: 800; color: var(--muted); }
.sec:first-child { padding-top: 8px; }

.icon-btn { width: 34px; height: 34px; display: inline-grid; place-items: center; border-radius: 10px; color: var(--muted); transition: background .12s, color .12s; flex-shrink: 0; }
.icon-btn:hover { background: var(--hover); color: var(--bark); }
.icon-btn.sm { width: 24px; height: 24px; border-radius: 8px; }
.icon-btn.sm svg { width: 16px; height: 16px; }
.icon-btn.off { color: var(--danger); background: rgba(217, 67, 80, .08); }
.icon-btn.danger-hover:hover { color: var(--danger); }

.install-pill { margin: 10px 10px 0; padding: 9px 12px; border-radius: 12px; background: var(--accent-soft); color: var(--sakura); font-weight: 800; font-size: 13px; text-align: left; display: flex; align-items: center; gap: 8px; border: 1.5px dashed var(--blossom); }
.install-pill::before { content: ""; width: 18px; height: 18px; flex-shrink: 0; background: url(/icons/icon-192.png) center / contain no-repeat; border-radius: 5px; }
.install-pill:hover { background: var(--active); }
.install-login { margin-top: 10px; }

/* canale */
.ch { display: flex; align-items: center; gap: 8px; padding: 7px 10px; border-radius: 10px; color: var(--muted); cursor: pointer; user-select: none; position: relative; font-weight: 600; }
.ch:hover { background: var(--hover); color: var(--bark); }
.ch.active { background: var(--active); color: var(--bark); }
.ch.unread { color: var(--bark); font-weight: 800; }
.ch svg { width: 18px; height: 18px; opacity: .75; }
.ch-name { flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.badge { background: var(--sakura); color: #fff; font-size: 11px; font-weight: 800; border-radius: 10px; padding: 1px 7px; }
.ch-del { opacity: 0; width: 24px; height: 24px; border-radius: 7px; display: grid; place-items: center; color: var(--faint); }
.ch-del svg { width: 14px; height: 14px; }
.ch:hover .ch-del { opacity: 1; }
.ch-del:hover { color: var(--danger); background: var(--surface); }
.ch.connected { color: var(--leaf); }
.vmembers { padding: 2px 0 6px 30px; }
.vm { display: flex; align-items: center; gap: 8px; padding: 3px 6px; border-radius: 8px; font-size: 14px; color: var(--muted); font-weight: 600; }
.vm .icons { margin-left: auto; display: flex; gap: 4px; color: var(--faint); }
.vm .icons svg { width: 14px; height: 14px; }
.live { background: var(--danger); color: #fff; font-size: 10px; font-weight: 800; padding: 0 6px; border-radius: 6px; }

/* avatare */
.avatar { width: 36px; height: 36px; border-radius: 50%; display: grid; place-items: center; font-weight: 800; color: #fff; flex-shrink: 0; position: relative; font-size: 15px; transition: box-shadow .12s; text-shadow: 0 1px 1px rgba(0, 0, 0, .15); }
.avatar.sm { width: 32px; height: 32px; font-size: 13px; }
.avatar.xs { width: 22px; height: 22px; font-size: 10px; }
.avatar.speaking { box-shadow: 0 0 0 2px var(--ring), 0 0 0 4.5px var(--leaf); }

/* panou voce + panou utilizator */
.voice-panel { border-top: 1px solid var(--line); padding: 10px 10px 8px; background: var(--voice-panel-bg); }
.vp-top { display: flex; align-items: center; gap: 6px; }
.vp-info { flex: 1; min-width: 0; text-align: left; padding: 2px 6px; border-radius: 8px; }
.vp-info:hover { background: var(--hover); }
.vp-status { display: block; color: var(--leaf); font-weight: 800; font-size: 13px; }
.vp-room { display: block; color: var(--muted); font-size: 12px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.vp-actions { display: flex; gap: 6px; margin-top: 8px; }
.pill { flex: 1; display: flex; align-items: center; justify-content: center; gap: 6px; padding: 7px; border-radius: 999px; background: var(--hover); font-size: 13px; font-weight: 700; color: var(--muted); }
.pill:hover { color: var(--bark); background: var(--active); }
.pill.on { background: var(--sakura); color: #fff; }
.pill svg { width: 16px; height: 16px; }
.user-panel { display: flex; align-items: center; gap: 2px; padding: 8px; background: var(--user-panel-bg); border-top: 1px solid var(--line); }
.up-name { flex: 1; min-width: 0; padding-left: 8px; line-height: 1.25; }
.up-name strong, .up-name small { display: block; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.up-name small { color: var(--muted); font-size: 12px; }

/* antet principal */
.main-head { height: 60px; display: flex; align-items: center; gap: 8px; padding: 0 12px 0 18px; border-bottom: 1px solid var(--line); flex-shrink: 0; }
.title { display: flex; align-items: center; gap: 8px; font: 600 18px/1.2 var(--display); min-width: 0; }
.title svg { color: var(--blossom); width: 20px; height: 20px; }
.title span { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.spacer { flex: 1; }
.mobile-only { display: none; }

/* chat */
.chat-view { flex: 1; display: flex; flex-direction: column; min-height: 0; }
.messages { flex: 1; overflow-y: auto; padding: 16px 0 8px; }
.empty { color: var(--muted); text-align: center; padding: 48px 20px 40px; }
.empty b { display: block; color: var(--bark); font: 600 24px/1.2 var(--display); margin-bottom: 6px; }
.empty .empty-flower { width: 54px; height: 54px; margin: 0 auto 12px; }
.day { display: flex; align-items: center; gap: 12px; margin: 18px 18px 8px; color: var(--faint); font-size: 12px; font-weight: 800; }
.day::before, .day::after { content: ""; flex: 1; height: 1px; background: var(--line); }
.msg { display: flex; gap: 14px; padding: 4px 18px; position: relative; }
.msg:not(.grouped) { margin-top: 12px; }
.msg:hover { background: var(--msg-hover); }
.msg .gutter { width: 40px; flex-shrink: 0; }
.msg .gutter .avatar { width: 40px; height: 40px; }
.msg .hover-time { display: none; color: var(--faint); font-size: 11px; text-align: right; padding-top: 3px; }
.msg.grouped:hover .hover-time { display: block; }
.msg-body { flex: 1; min-width: 0; }
.msg-head { display: flex; align-items: baseline; gap: 8px; }
.author { font-weight: 800; }
.time { color: var(--faint); font-size: 12px; font-weight: 600; }
.msg-text { white-space: pre-wrap; overflow-wrap: anywhere; }
.msg-text a { color: var(--link); }
.msg-text code { background: var(--hover); padding: 1px 6px; border-radius: 6px; font-family: ui-monospace, Consolas, monospace; font-size: 13.5px; }
.mention { background: var(--accent-soft); color: var(--sakura); border-radius: 6px; padding: 0 4px; font-weight: 800; }
.msg.mentions-me { background: var(--mention-bg); box-shadow: inset 3px 0 0 var(--blossom); }
.msg-img { display: block; max-width: min(420px, 100%); max-height: 340px; border-radius: 12px; margin-top: 6px; cursor: zoom-in; background: var(--hover); }
.msg-del { position: absolute; right: 14px; top: -8px; display: none; background: var(--surface); border: 1px solid var(--line); border-radius: 9px; width: 30px; height: 30px; place-items: center; color: var(--muted); box-shadow: var(--shadow); }
.msg-del svg { width: 16px; height: 16px; }
.msg:hover .msg-del { display: grid; }
.msg-del:hover { color: var(--danger); }

.composer-wrap { padding: 0 18px 6px; flex-shrink: 0; }
.composer { display: flex; align-items: flex-end; gap: 4px; background: var(--surface); border: 1.5px solid var(--line); border-radius: 18px; padding: 6px; box-shadow: var(--shadow); transition: border-color .15s; }
.composer:focus-within { border-color: var(--blossom); }
.composer textarea { flex: 1; resize: none; border: 0; outline: none; background: transparent; padding: 7px 4px; max-height: 200px; line-height: 1.4; }
.composer textarea::placeholder { color: var(--faint); }
.composer .send { color: #fff; background: var(--sakura); border-radius: 12px; }
.composer .send:hover { background: var(--sakura-hover); color: #fff; }
.typing { height: 20px; font-size: 12px; color: var(--muted); padding: 2px 6px; font-weight: 600; }

/* scena (voce / video) */
.stage { flex: 1; display: flex; flex-direction: column; min-height: 0; background: var(--stage); position: relative; }
.stage-banner { text-align: center; padding: 10px; background: var(--accent-soft); color: var(--sakura); font-weight: 700; }
.focus-area { flex: 1; min-height: 0; padding: 12px 12px 0; display: flex; }
.focus-area .tile { flex: 1; aspect-ratio: auto; height: 100%; max-height: none; }
.grid { flex: 1; min-height: 0; display: grid; gap: 12px; padding: 12px; align-content: center; justify-content: center;
  grid-template-columns: repeat(var(--cols, 1), minmax(0, var(--tile-w, 640px))); overflow-y: auto; }
.stage.has-focus .grid { flex: 0 0 auto; grid-auto-flow: column; grid-template-columns: none; grid-auto-columns: 200px; justify-content: start; overflow-x: auto; overflow-y: hidden; padding-bottom: 6px; }
.tile { position: relative; aspect-ratio: 16 / 9; background: var(--tile-bg); border-radius: 18px; overflow: hidden; display: grid; place-items: center; cursor: pointer; outline: 3px solid transparent; transition: outline-color .12s; box-shadow: var(--shadow); }
.tile.speaking { outline-color: var(--leaf); }
.tile video { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: contain; background: #2a1b22; }
.tile video.cover { object-fit: cover; }
.tile video.mirror { transform: scaleX(-1); }
.tile .avatar { width: 84px; height: 84px; font-size: 34px; }
.tile.small .avatar { width: 46px; height: 46px; font-size: 19px; }
.tile .tile-label { position: absolute; left: 10px; bottom: 10px; display: flex; align-items: center; gap: 6px; background: var(--label-bg); color: var(--bark); padding: 3px 11px; border-radius: 999px; font-size: 13px; font-weight: 700; max-width: calc(100% - 20px); }
.tile .tile-label span { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.tile .tile-label svg { width: 14px; height: 14px; color: var(--danger); }
.tile .tile-tools { position: absolute; right: 10px; top: 10px; display: flex; gap: 6px; opacity: 0; transition: opacity .15s; }
.tile:hover .tile-tools { opacity: 1; }
.tile .tool { background: var(--label-bg); border-radius: 999px; height: 30px; min-width: 30px; display: grid; place-items: center; padding: 0 7px; color: var(--bark); }
.tile .tool svg { width: 16px; height: 16px; }
.tile select.tool { border: 0; font: 700 12px var(--font); padding: 0 10px; cursor: pointer; outline: none; -webkit-appearance: none; appearance: none; }
.tile .qbadge { font-style: normal; font-size: 11px; font-weight: 800; color: var(--sakura); background: var(--accent-soft); border-radius: 999px; padding: 0 7px; white-space: nowrap; }
.tile .vol { display: flex; align-items: center; gap: 6px; }
.tile .vol input { width: 96px; accent-color: var(--sakura); }
.tile .vol .volpct { font-size: 11px; min-width: 34px; text-align: right; }
.volrow { display: grid; grid-template-columns: 1fr auto; grid-template-areas: "l p" "i i"; gap: 6px; margin-bottom: 16px; }
.volrow .vollabel { grid-area: l; } .volrow input { grid-area: i; } .volrow .volpct { grid-area: p; }
.volrow .vollabel { display: flex; align-items: center; gap: 8px; font-weight: 800; color: var(--muted); font-size: 13px; }
.volrow .vollabel svg { color: var(--blossom); }
.volrow input { width: 100%; accent-color: var(--sakura); }
.volrow .volpct { font-size: 13px; color: var(--sakura); }
.member[data-member], .vm[data-volfor] { cursor: pointer; }
.vm[data-volfor]:hover { background: var(--hover); }
.tile .waiting { position: absolute; color: var(--muted); font-size: 13px; bottom: 44px; font-weight: 600; }
.stage-controls { display: flex; justify-content: center; gap: 10px; padding: 12px 12px 16px; flex-shrink: 0; }
.ctl { width: 54px; height: 54px; border-radius: 50%; background: var(--surface); display: grid; place-items: center; color: var(--bark); transition: background .12s, transform .1s; box-shadow: var(--shadow); }
.ctl:hover { background: var(--hover); }
.ctl:active { transform: scale(.94); }
.ctl.off { background: var(--ctl-off-bg); color: var(--danger); }
.ctl.on { background: var(--sakura); color: #fff; }
.ctl.leave { background: var(--danger); color: #fff; }
.ctl svg { width: 22px; height: 22px; }

/* membri */
.members .sec { padding-top: 10px; }
.member { display: flex; align-items: center; gap: 10px; padding: 6px 8px; border-radius: 12px; }
.member:hover { background: var(--hover); }
.member .info { flex: 1; min-width: 0; line-height: 1.25; }
.member .info strong { display: block; font-weight: 800; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.member .info small { color: var(--muted); font-size: 12px; display: block; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.member .call-btn { opacity: 0; color: var(--leaf); }
.member:hover .call-btn, .member .call-btn:focus-visible { opacity: 1; }
.member .call-btn:hover { background: rgba(79, 158, 100, .14); color: var(--leaf); }
.member .call-btn svg { width: 18px; height: 18px; }

/* ferestre (modale) */
.modal-bg { position: fixed; inset: 0; background: var(--overlay); display: grid; place-items: center; z-index: 50; padding: 16px; animation: fade .15s; }
.modal { width: 100%; max-width: 430px; max-height: calc(100dvh - 32px); overflow-y: auto; background: var(--surface); border: 1px solid var(--line); border-radius: 22px; padding: 24px; box-shadow: 0 30px 80px rgba(0, 0, 0, .35); animation: pop .18s cubic-bezier(.2, .9, .3, 1.2); }
.modal h2 { margin: 0 0 4px; font: 600 24px/1.2 var(--display); color: var(--bark); }
.modal p { margin: 0 0 16px; color: var(--muted); }
.modal .row { display: flex; gap: 8px; justify-content: flex-end; margin-top: 18px; flex-wrap: wrap; }
.modal .type-pick { display: grid; gap: 8px; margin-bottom: 14px; }
.modal .type-pick label { display: flex; gap: 10px; align-items: center; padding: 10px 12px; border-radius: 14px; background: var(--hover); border: 1.5px solid transparent; cursor: pointer; }
.modal .type-pick label:has(input:checked) { border-color: var(--blossom); background: var(--accent-soft); }
.modal .type-pick input { width: auto; accent-color: var(--sakura); }
.modal .type-pick svg { color: var(--blossom); }
.modal .setting { margin-bottom: 14px; }
.modal .setting > span { display: block; font-size: 13px; font-weight: 800; color: var(--muted); margin-bottom: 6px; }
.meter { height: 8px; border-radius: 4px; background: var(--hover); overflow: hidden; margin-top: 8px; }
.meter i { display: block; height: 100%; width: 0; background: var(--leaf); transition: width .08s; border-radius: 4px; }
.check { display: flex; align-items: center; gap: 10px; cursor: pointer; font-weight: 600; }
.check input { width: auto !important; accent-color: var(--sakura); }
.incoming { text-align: center; }
.incoming .avatar { width: 88px; height: 88px; font-size: 36px; margin: 6px auto 14px; animation: ring 1.4s infinite; }
@keyframes ring { 0% { box-shadow: 0 0 0 0 rgba(242, 139, 176, .7); } 100% { box-shadow: 0 0 0 24px rgba(242, 139, 176, 0); } }
.incoming .row { justify-content: center; }
.incoming .btn { display: inline-flex; align-items: center; gap: 8px; }
.incoming .btn svg { width: 18px; height: 18px; }
.lightbox { position: fixed; inset: 0; background: rgba(40, 20, 30, .85); z-index: 60; display: grid; place-items: center; cursor: zoom-out; padding: 24px; }
.lightbox img { max-width: 100%; max-height: 100%; border-radius: 12px; }
@keyframes fade { from { opacity: 0; } }
@keyframes pop { from { transform: scale(.94); opacity: 0; } }

/* notificări mici */
.toasts { position: fixed; top: 14px; left: 50%; transform: translateX(-50%); z-index: 70; display: grid; gap: 8px; pointer-events: none; width: max-content; max-width: calc(100% - 32px); }
.toast { background: var(--surface); color: var(--bark); border: 1px solid var(--line); padding: 10px 18px; border-radius: 999px; box-shadow: var(--shadow); animation: pop .2s; font-weight: 700; text-align: center; }

/* telefon / ecran mic */
.scrim { display: none; }
@media (max-width: 1000px) {
  .app, .app.no-members { grid-template-columns: 244px 1fr; }
  .members { position: fixed; right: 0; top: 0; bottom: 0; width: 264px; z-index: 30; transform: translateX(100%); transition: transform .2s; display: block !important; background: var(--panel-solid); }
  .app.show-members .members { transform: none; }
  .app.show-members .scrim { display: block; position: fixed; inset: 0; background: var(--overlay); z-index: 20; }
}
@media (max-width: 720px) {
  .app, .app.no-members { grid-template-columns: 1fr; }
  .sidebar { position: fixed; left: 0; top: 0; bottom: 0; width: 284px; z-index: 30; transform: translateX(-100%); transition: transform .2s; background: var(--panel-solid); }
  .app.show-side .sidebar { transform: none; }
  .app.show-side .scrim { display: block; position: fixed; inset: 0; background: var(--overlay); z-index: 20; }
  .mobile-only { display: inline-grid; }
  .grid { grid-template-columns: 1fr !important; }
  .tile .tile-tools { opacity: 1; }
  .ch-del, .member .call-btn { opacity: 1; }
  .login-branch { right: -20px; width: 210px; height: 112px; }
}
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: .01ms !important; transition-duration: .01ms !important; }
}

/* fereastra mică de volum lângă nume */
.vol-pop { position: fixed; z-index: 55; width: 280px; background: var(--surface); border: 1px solid var(--line); border-radius: 18px; padding: 14px 16px 12px; box-shadow: 0 20px 50px rgba(0, 0, 0, .4); animation: pop .15s cubic-bezier(.2, .9, .3, 1.2); }
.vol-pop .vp-head { display: flex; align-items: center; gap: 10px; margin-bottom: 14px; }
.vol-pop .vp-head strong { flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font: 600 17px/1.2 var(--display); }
.vol-pop .volrow { margin-bottom: 12px; }
.vol-pop .vp-hint { display: block; color: var(--faint); font-size: 12px; font-weight: 600; }
.volrow input[type=range] { height: 22px; cursor: pointer; }
.share-steps { display: grid; gap: 6px; margin-top: 14px; padding: 12px 14px; border-radius: 14px; background: var(--hover); font-size: 13.5px; color: var(--muted); }
.share-steps > b { color: var(--bark); }
.share-steps span { display: block; position: relative; padding-left: 28px; line-height: 1.45; }
.share-steps b { color: var(--bark); }
.share-steps i { position: absolute; left: 0; top: 0; font-style: normal; width: 20px; height: 20px; border-radius: 50%; background: var(--sakura); color: #fff; font-size: 11px; font-weight: 800; display: inline-grid; place-items: center; }

/* ---------- aplicația pentru Windows ---------- */
.titlebar { display: none; }
.desktop .titlebar { position: fixed; top: 0; left: 0; right: 0; height: 36px; z-index: 45; display: flex; align-items: center; gap: 8px; padding: 0 150px 0 12px;
  background: #1d141b; border-bottom: 1px solid var(--line); -webkit-app-region: drag; user-select: none; font: 600 14px/1 var(--display); color: var(--sakura); }
:root[data-theme="light"].desktop .titlebar { background: #fbe6ee; }
.desktop .titlebar .tb-flower { width: 18px; height: 18px; }
.desktop .app { margin-top: 36px; height: calc(100vh - 36px); height: calc(100dvh - 36px); }
.desktop .login { min-height: calc(100% - 36px); margin-top: 36px; }
@media (max-width: 1000px) { .desktop .members { top: 36px; } }
@media (max-width: 720px) { .desktop .sidebar { top: 36px; } }
.desktop .modal-bg { top: 36px; }
a.install-pill { text-decoration: none; }
.dl-pill::before { background: none !important; content: "⬇"; width: auto !important; height: auto !important; }

/* fereastra de alegere a ecranului */
.modal.wide { max-width: 780px; }
.picker h2 { margin-bottom: 12px; }
.pk-tabs { display: flex; gap: 6px; padding: 4px; background: var(--hover); border-radius: 999px; width: max-content; margin-bottom: 14px; }
.pk-tab { display: flex; align-items: center; gap: 8px; padding: 8px 16px; border-radius: 999px; font-weight: 800; color: var(--muted); }
.pk-tab em { font-style: normal; font-size: 11px; background: var(--active); color: var(--bark); border-radius: 999px; padding: 0 7px; }
.pk-tab.on { background: var(--sakura); color: #fff; }
.pk-tab.on em { background: rgba(255, 255, 255, .25); color: #fff; }
.pk-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(200px, 1fr)); gap: 12px; max-height: 340px; overflow-y: auto; padding: 4px; margin: 0 -4px; }
.pk-card { display: grid; gap: 8px; padding: 8px; border-radius: 14px; background: var(--hover); border: 2px solid transparent; text-align: left; transition: border-color .12s, background .12s; }
.pk-card:hover { background: var(--active); }
.pk-card.on { border-color: var(--sakura); background: var(--accent-soft); }
.pk-thumb { aspect-ratio: 16 / 9; border-radius: 9px; overflow: hidden; background: #0d090c; display: grid; place-items: center; }
.pk-thumb img { width: 100%; height: 100%; object-fit: contain; }
.pk-name { display: flex; align-items: center; gap: 7px; font-size: 13px; font-weight: 700; min-width: 0; }
.pk-name img { width: 16px; height: 16px; flex-shrink: 0; }
.pk-name svg { color: var(--blossom); }
.pk-name span { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.pk-empty { grid-column: 1 / -1; text-align: center; padding: 30px; }
.pk-q-row { display: grid; grid-template-columns: repeat(4, 1fr); gap: 8px; margin-top: 16px; }
.pk-q { display: grid; gap: 2px; padding: 9px 12px; border-radius: 12px; background: var(--hover); border: 2px solid transparent; text-align: left; }
.pk-q small { color: var(--muted); font-size: 12px; }
.pk-q.on { border-color: var(--sakura); background: var(--accent-soft); }
.pk-audio { display: flex; align-items: center; gap: 12px; margin-top: 12px; padding: 12px 14px; border-radius: 14px; background: var(--hover); cursor: pointer; }
.pk-audio.disabled { opacity: .5; cursor: default; }
.pk-audio-text { flex: 1; display: grid; }
.pk-audio-text small { color: var(--muted); font-size: 12.5px; }
.switch { appearance: none; -webkit-appearance: none; width: 46px; height: 26px; border-radius: 999px; background: var(--active); position: relative; cursor: pointer; transition: background .15s; flex-shrink: 0; margin: 0; }
.switch::after { content: ""; position: absolute; top: 3px; left: 3px; width: 20px; height: 20px; border-radius: 50%; background: #fff; transition: transform .15s; box-shadow: 0 1px 3px rgba(0, 0, 0, .3); }
.switch:checked { background: var(--sakura); }
.switch:checked::after { transform: translateX(20px); }
.btn:disabled { opacity: .45; cursor: default; filter: none; }
@media (max-width: 720px) { .pk-q-row { grid-template-columns: 1fr; } }
.modal input.switch { width: 46px; padding: 0; border: 0; }
.desktop .toasts { top: 50px; }

/* panoul de volum din bara de jos */
.vol-pop.panel { width: 320px; max-height: min(70vh, 560px); overflow-y: auto; }
.vp-person { padding-top: 12px; margin-top: 4px; border-top: 1px solid var(--line); }
.vp-who { display: flex; align-items: center; gap: 8px; margin-bottom: 8px; }
.vp-alone { color: var(--muted); font-size: 13.5px; margin: 4px 0 12px; }
/* propriul ecran partajat, fără previzualizare */
.own-share { display: grid; justify-items: center; gap: 6px; text-align: center; padding: 16px; color: var(--muted); }
.own-share svg { color: var(--blossom); }
.own-share b { color: var(--bark); font-size: 16px; }
.own-share small { font-size: 12.5px; max-width: 280px; }
.own-share .btn { margin-top: 6px; padding: 7px 14px; font-size: 13px; }
.tile.small .own-share small, .tile.small .own-share .btn { display: none; }

