:root {
  --bg: #0d1020;
  --bg-2: #11152a;
  --surface: #161a30;
  --surface-2: #1c2140;
  --surface-3: #252b50;
  --border: rgba(255, 255, 255, .07);
  --border-strong: rgba(255, 255, 255, .13);
  --text: #eceefa;
  --muted: #8c93b5;
  --faint: #5d6488;
  --primary: #7b6cff;
  --primary-2: #4fd1c5;
  --primary-soft: rgba(123, 108, 255, .16);
  --grad: linear-gradient(135deg, #8b7bff 0%, #6a5cff 45%, #4fb8d1 100%);
  --green: #3ddc97;
  --amber: #ffbe55;
  --red: #ff6b7a;
  --gray: #6f7798;
  --radius: 16px;
  --shadow: 0 20px 50px rgba(0, 0, 0, .45);
  --shadow-sm: 0 6px 18px rgba(0, 0, 0, .28);
  --font-head: 'Plus Jakarta Sans', Inter, system-ui, sans-serif;
  font-family: Inter, system-ui, -apple-system, Segoe UI, sans-serif;
  color: var(--text);
  color-scheme: dark;
}
* { box-sizing: border-box; }
html, body { margin: 0; height: 100%; background: var(--bg); }
body { font-size: 14px; overflow: hidden; -webkit-font-smoothing: antialiased; }
button, input, select, textarea { font: inherit; color: inherit; }
h1, h2, h3 { font-family: var(--font-head); letter-spacing: -.01em; }
.hidden { display: none !important; }
.muted { color: var(--muted); }
.small { font-size: 12px; }
.error { color: var(--red); min-height: 1em; margin: 0; font-size: 13px; }
.row { display: flex; align-items: center; }
.row.center { justify-content: center; }
.gap { gap: 8px; }
.spacer { flex: 1; }
.ico { display: block; flex-shrink: 0; }
.inline-ico { display: inline-flex; align-items: center; gap: 4px; }
kbd { background: rgba(255,255,255,.1); border: 1px solid rgba(255,255,255,.12); border-bottom-width: 2px; border-radius: 5px; padding: 0 5px; font-size: 10px; font-family: inherit; margin-right: 2px; }
::-webkit-scrollbar { width: 10px; height: 10px; }
::-webkit-scrollbar-thumb { background: rgba(255,255,255,.1); border-radius: 10px; border: 3px solid transparent; background-clip: padding-box; }
::-webkit-scrollbar-thumb:hover { background-color: rgba(255,255,255,.2); }
.logo { width: 100%; height: 100%; display: block; }

/* ---------- Superfícies ---------- */
.glass { background: rgba(22, 26, 48, .72); border: 1px solid var(--border-strong); backdrop-filter: blur(18px); -webkit-backdrop-filter: blur(18px); border-radius: 22px; box-shadow: var(--shadow); }
.glass-dark { background: rgba(12, 15, 30, .74); border: 1px solid rgba(255,255,255,.09); backdrop-filter: blur(14px); -webkit-backdrop-filter: blur(14px); box-shadow: var(--shadow-sm); }
.card { background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); padding: 18px; }

/* ---------- Botões e campos ---------- */
.btn {
  border: 1px solid var(--border-strong); background: var(--surface-2); border-radius: 11px;
  padding: 9px 15px; cursor: pointer; font-weight: 600; white-space: nowrap; display: inline-flex; align-items: center; gap: 7px;
  transition: background .15s, border-color .15s, transform .1s, box-shadow .15s; text-decoration: none; font-size: 13.5px;
}
.btn:hover { background: var(--surface-3); }
.btn:active { transform: translateY(1px); }
.btn.primary { background: var(--grad); border-color: transparent; color: #fff; box-shadow: 0 6px 20px rgba(110, 92, 255, .35); }
.btn.primary:hover { filter: brightness(1.08); box-shadow: 0 8px 26px rgba(110, 92, 255, .5); }
.btn.success { background: linear-gradient(135deg, #3ddc97, #22b8a0); border-color: transparent; color: #08261b; box-shadow: 0 6px 20px rgba(61, 220, 151, .3); }
.btn.warn { background: rgba(255, 190, 85, .14); border-color: rgba(255, 190, 85, .35); color: var(--amber); }
.btn.danger { color: var(--red); background: rgba(255, 107, 122, .08); border-color: rgba(255, 107, 122, .25); }
.btn.danger:hover { background: rgba(255, 107, 122, .16); }
.btn.ghost { background: transparent; border-color: transparent; color: var(--muted); }
.btn.ghost:hover { background: var(--surface-2); color: var(--text); }
.btn.small { padding: 6px 11px; font-size: 12.5px; border-radius: 9px; }
.btn.block { width: 100%; padding: 13px; justify-content: center; font-size: 15px; border-radius: 13px; }
.btn:disabled { opacity: .45; cursor: not-allowed; }
.icon-btn { border: 0; background: transparent; cursor: pointer; padding: 6px; border-radius: 9px; color: var(--muted); display: inline-grid; place-items: center; }
.icon-btn:hover { background: rgba(255,255,255,.08); color: var(--text); }
label { display: grid; gap: 6px; font-size: 12.5px; font-weight: 600; color: var(--muted); }
input, select, textarea {
  border: 1px solid var(--border-strong); border-radius: 11px; padding: 10px 12px; background: var(--bg-2);
  outline: none; width: 100%; transition: border-color .15s, box-shadow .15s; font-weight: 400; color: var(--text);
}
input::placeholder, textarea::placeholder { color: var(--faint); }
input:focus, select:focus, textarea:focus { border-color: var(--primary); box-shadow: 0 0 0 4px var(--primary-soft); }
textarea { resize: vertical; min-height: 90px; line-height: 1.55; }
input[type=checkbox] { width: 17px; height: 17px; accent-color: var(--primary); }
input[type=date], input[type=time], input[type=datetime-local] { color-scheme: dark; }
select option, select optgroup { background: var(--surface); }

/* ---------- Telas de login / entrada ---------- */
.screen { position: relative; height: 100%; display: grid; place-items: center; padding: 20px; overflow: hidden;
  background: radial-gradient(1200px 600px at 10% -10%, #1d1a4a 0%, transparent 60%), radial-gradient(900px 500px at 110% 110%, #0f3440 0%, transparent 55%), var(--bg); }
.blob { position: absolute; border-radius: 50%; filter: blur(80px); opacity: .55; pointer-events: none; animation: float 14s ease-in-out infinite alternate; }
.b1 { width: 420px; height: 420px; background: #6a5cff; top: -120px; left: -80px; }
.b2 { width: 360px; height: 360px; background: #2fb7c7; bottom: -120px; right: -60px; animation-delay: -5s; }
.b3 { width: 260px; height: 260px; background: #c05cff; top: 40%; left: 45%; opacity: .25; animation-delay: -9s; }
@keyframes float { to { transform: translate(40px, 30px) scale(1.08); } }
.login-wrap { position: relative; display: grid; grid-template-columns: 1.1fr 1fr; gap: 56px; align-items: center; width: min(1020px, 100%); }
.login-hero h1 { font-size: 44px; line-height: 1.1; margin: 22px 0 26px; font-weight: 800; letter-spacing: -.03em; }
.grad { background: var(--grad); -webkit-background-clip: text; background-clip: text; color: transparent; }
.hero-list { list-style: none; padding: 0; margin: 0; display: grid; gap: 14px; color: #c3c8e4; font-size: 15px; }
.hero-list li { display: flex; align-items: center; gap: 12px; }
.hero-list li > span { width: 36px; height: 36px; border-radius: 11px; display: grid; place-items: center; background: rgba(255,255,255,.06); border: 1px solid var(--border-strong); color: #b5abff; }
.login-card, .join-card { position: relative; display: grid; gap: 16px; padding: 34px; }
.login-card h2, .join-card h2 { margin: 0; font-size: 26px; }
.login-card p, .join-card p { margin: 0; }
.join-card { width: min(540px, 100%); }
.brand { font-family: var(--font-head); font-size: 19px; font-weight: 800; display: flex; align-items: center; gap: 11px; letter-spacing: -.01em; }
.brand [data-logo] { width: 36px; height: 36px; }
.small-brand { font-size: 15px; }
.small-brand [data-logo] { width: 28px; height: 28px; }
.preview { position: relative; aspect-ratio: 16/9; background: radial-gradient(circle at 50% 40%, #232a52, #0b0e1c); border-radius: 18px; overflow: hidden; border: 1px solid var(--border-strong); }
.preview video { width: 100%; height: 100%; object-fit: cover; transform: scaleX(-1); }
.preview-off { position: absolute; inset: 0; display: grid; place-content: center; justify-items: center; gap: 10px; color: var(--muted); }
.preview-controls { position: absolute; bottom: 14px; left: 0; right: 0; display: flex; justify-content: center; gap: 12px; }
.round-btn { width: 50px; height: 50px; border-radius: 50%; border: 1px solid rgba(255,255,255,.15); background: rgba(255,255,255,.12); backdrop-filter: blur(8px); color: #fff; cursor: pointer; display: grid; place-items: center; transition: background .15s; }
.round-btn:hover { background: rgba(255,255,255,.2); }
.round-btn:not(.on) { background: #ff5468; border-color: transparent; }
.round-btn:disabled { opacity: .5; cursor: not-allowed; }

/* ---------- Layout do app ---------- */
#app { display: flex; height: 100%; }
#sidebar {
  width: 78px; background: #090b17; display: flex; flex-direction: column; align-items: center;
  padding: 14px 0 12px; gap: 4px; z-index: 30; flex-shrink: 0; border-right: 1px solid var(--border);
}
.nav-brand { width: 38px; height: 38px; margin-bottom: 14px; }
.nav-btn {
  position: relative; width: 62px; border: 0; background: transparent; color: #7f87ab; cursor: pointer;
  display: grid; justify-items: center; gap: 4px; padding: 9px 0 7px; border-radius: 13px; transition: color .15s, background .15s;
}
.nav-btn small { font-size: 10.5px; font-weight: 600; }
.nav-btn:hover { background: rgba(255,255,255,.05); color: #d5d9f0; }
.nav-btn.active { color: #fff; background: rgba(123, 108, 255, .16); }
.nav-btn.active::before { content: ''; position: absolute; left: -8px; top: 12px; bottom: 12px; width: 3px; border-radius: 0 3px 3px 0; background: var(--grad); }
.nav-btn.active .ico { color: #b5abff; }
.nav-spacer { flex: 1; }
.nav-me { margin-bottom: 6px; cursor: default; }
.badge { position: absolute; top: 4px; right: 11px; background: #ff5468; color: #fff; border-radius: 10px;
  font-size: 10px; font-weight: 700; padding: 1px 5px; min-width: 17px; text-align: center; box-shadow: 0 0 0 2px #090b17; }
.badge:empty { display: none; }

#office { position: relative; flex: 1; overflow: hidden; background: #0a0c18; }
#map { display: block; width: 100%; height: 100%; cursor: pointer; }

/* ---------- Vídeos ---------- */
#videoBar { position: absolute; top: 14px; left: 50%; transform: translateX(-50%); display: flex; gap: 10px; z-index: 5; max-width: calc(100% - 28px); overflow-x: auto; padding: 2px; }
.vtile { position: relative; width: 176px; aspect-ratio: 4/3; background: radial-gradient(circle at 50% 40%, #262d58, #12152a); border-radius: 16px; overflow: hidden;
  box-shadow: 0 10px 28px rgba(0,0,0,.5); flex-shrink: 0; border: 1px solid rgba(255,255,255,.12); animation: pop .25s ease-out; }
@keyframes pop { from { transform: scale(.85); opacity: 0; } }
.vtile video { width: 100%; height: 100%; object-fit: cover; }
.vtile.me video { transform: scaleX(-1); }
.vtile .vname { position: absolute; left: 8px; bottom: 8px; background: rgba(0,0,0,.5); backdrop-filter: blur(6px); color: #fff; font-size: 11.5px; font-weight: 600;
  padding: 3px 9px; border-radius: 8px; display: flex; gap: 5px; align-items: center; }
.vtile .vavatar { position: absolute; inset: 0; display: none; place-items: center; }
.vtile.nocam .vavatar { display: grid; }
.vtile.nocam video { visibility: hidden; }
.vavatar b { width: 56px; height: 56px; border-radius: 50%; display: grid; place-items: center; color: #fff; font-size: 19px; box-shadow: 0 0 0 4px rgba(255,255,255,.08); }

/* ---------- HUD e painéis flutuantes ---------- */
.hud { position: absolute; z-index: 4; color: #fff; border-radius: 14px; padding: 10px 14px; font-size: 13px; }
#zoneHud { top: 14px; left: 14px; max-width: 330px; display: flex; gap: 11px; align-items: flex-start; line-height: 1.4; }
#zoneHud .zone-ico { width: 34px; height: 34px; border-radius: 10px; display: grid; place-items: center; flex-shrink: 0; }
#zoneHud b { display: block; font-family: var(--font-head); font-size: 14px; }
#zoneHud span { color: #b6bcd9; font-size: 12px; }
.clock-hud { top: 14px; right: 14px; display: flex; gap: 12px; align-items: center; padding: 7px 7px 7px 14px; }
.clock-hud .dot { width: 9px; height: 9px; border-radius: 50%; display: inline-block; }
.clock-hud b { font-variant-numeric: tabular-nums; }
.floating { position: absolute; z-index: 4; color: #e8ebf5; border-radius: 18px; }
.floating-head { padding: 12px 14px 8px; font-weight: 700; font-size: 13px; display: flex; align-items: center; justify-content: space-between; gap: 8px; font-family: var(--font-head); }
.people { right: 14px; top: 66px; width: 236px; max-height: 46%; display: flex; flex-direction: column; }
.people ul { list-style: none; margin: 0; padding: 0 6px 8px; overflow-y: auto; }
.people li { display: flex; align-items: center; gap: 10px; padding: 7px 8px; border-radius: 11px; cursor: pointer; font-size: 13px; font-weight: 500; }
.people li:hover { background: rgba(255,255,255,.07); }
.people li .where { font-size: 11px; color: #8c93b5; display: flex; align-items: center; gap: 5px; font-weight: 400; }
.av-wrap { position: relative; display: inline-flex; }
.av-wrap .status-dot { position: absolute; right: -1px; bottom: -1px; box-shadow: 0 0 0 2px #0e1122; }
.pill { background: rgba(123,108,255,.2); color: #c9c1ff; border-radius: 10px; padding: 1px 8px; font-size: 11px; font-weight: 700; }
.chat { left: 14px; bottom: 80px; width: 310px; }
#chatList { height: 210px; overflow-y: auto; padding: 0 14px; display: flex; flex-direction: column; gap: 10px; font-size: 13px; }
#chatList .msg { display: flex; gap: 9px; }
#chatList .msg .body { min-width: 0; }
#chatList .msg b { font-weight: 700; font-size: 12.5px; }
#chatList .msg time { color: #6f7798; font-size: 10.5px; margin-left: 5px; }
#chatList .msg p { margin: 2px 0 0; color: #d2d6ec; word-wrap: break-word; line-height: 1.4; }
#chatList:empty::before { content: 'Nenhuma mensagem ainda. Diga oi! 👋'; color: var(--muted); font-size: 12px; margin: auto; }
#chatForm { padding: 10px; display: flex; gap: 6px; }
#chatForm input { background: rgba(255,255,255,.06); border-color: transparent; color: #fff; border-radius: 11px; }
.send-btn { border: 0; width: 40px; border-radius: 11px; background: var(--grad); color: #fff; cursor: pointer; display: grid; place-items: center; flex-shrink: 0; }
.chat.min #chatBody { display: none; }

#controls { position: absolute; bottom: 16px; left: 50%; transform: translateX(-50%); z-index: 5; display: flex; gap: 6px; align-items: center;
  padding: 7px; border-radius: 18px; color: #c5cbe0; }
.ctrl { width: 46px; height: 46px; border: 0; border-radius: 13px; background: rgba(255,255,255,.08); cursor: pointer; color: #fff; display: grid; place-items: center; transition: background .15s, transform .1s; }
.ctrl:hover { background: rgba(255,255,255,.15); }
.ctrl:active { transform: scale(.95); }
.ctrl.subtle { width: 38px; background: transparent; color: #9aa1c4; }
.ctrl.subtle:hover { background: rgba(255,255,255,.08); color: #fff; }
#micBtn:not(.on), #camBtn:not(.on) { background: #ff5468; }
#awayBtn.on { background: var(--amber); color: #2b1d00; }
.ctrl-sep { width: 1px; height: 28px; background: rgba(255,255,255,.12); margin: 0 4px; }
.ctrl-help { font-size: 12px; padding: 0 10px 0 4px; white-space: nowrap; color: #8c93b5; }

/* ---------- Painel lateral de conteúdo ---------- */
#panel {
  position: absolute; top: 0; bottom: 0; right: 0; left: 78px; z-index: 20; background: var(--bg);
  display: flex; flex-direction: column; box-shadow: -20px 0 60px rgba(0,0,0,.5); animation: slide .22s ease-out;
}
@keyframes slide { from { transform: translateX(24px); opacity: 0; } }
#panel.narrow { left: auto; width: min(640px, calc(100% - 78px)); border-left: 1px solid var(--border); }
#panelHead { display: flex; align-items: center; justify-content: space-between; padding: 18px 26px; border-bottom: 1px solid var(--border); background: var(--bg-2); }
#panelHead h1 { font-size: 21px; margin: 0; font-weight: 800; }
#panelBody { flex: 1; overflow: auto; padding: 24px 26px 48px;
  background: radial-gradient(700px 300px at 100% 0%, rgba(123,108,255,.07), transparent 70%), var(--bg); }
.section-title { font-size: 11.5px; text-transform: uppercase; letter-spacing: .08em; color: var(--muted); margin: 28px 0 12px; font-weight: 700; display: flex; align-items: center; gap: 8px; }
.section-title:first-child { margin-top: 0; }
.section-title .count { background: var(--surface-2); color: var(--text); border-radius: 8px; padding: 1px 7px; font-size: 11px; letter-spacing: 0; }
.grid2 { display: grid; grid-template-columns: repeat(auto-fit, minmax(270px, 1fr)); gap: 14px; }
.toolbar { display: flex; flex-wrap: wrap; gap: 10px; align-items: center; margin-bottom: 20px; }
.toolbar input, .toolbar select { width: auto; min-width: 170px; }
.search { position: relative; }
.search .ico { position: absolute; left: 11px; top: 50%; transform: translateY(-50%); color: var(--faint); }
.search input { padding-left: 34px; }
.empty { color: var(--muted); padding: 22px; text-align: center; border: 1px dashed var(--border-strong); border-radius: 14px; font-size: 13px; }

.avatar { border-radius: 50%; display: inline-grid; place-items: center; color: #fff; font-weight: 700; flex-shrink: 0; letter-spacing: -.02em; }
.status-dot { width: 9px; height: 9px; border-radius: 50%; display: inline-block; flex-shrink: 0; }
.st-trabalhando { background: var(--green); box-shadow: 0 0 8px rgba(61,220,151,.6); }
.st-pausa { background: var(--amber); }
.st-fora { background: var(--gray); }

/* ---------- Início ---------- */
.hello { display: flex; align-items: center; gap: 16px; margin-bottom: 22px; }
.hello h2 { margin: 0; font-size: 26px; font-weight: 800; }
.hello p { margin: 3px 0 0; }
.list-item { display: flex; align-items: center; gap: 12px; padding: 13px 15px; cursor: pointer; transition: border-color .15s, background .15s; }
.list-item:hover { border-color: var(--border-strong); background: var(--surface-2); }
.stack-list { display: grid; gap: 8px; }

/* ---------- Kanban ---------- */
.kanban { display: grid; grid-template-columns: repeat(4, minmax(250px, 1fr)); gap: 16px; align-items: start; overflow-x: auto; padding-bottom: 8px; }
.kcol { background: var(--bg-2); border: 1px solid var(--border); border-radius: 18px; padding: 12px; min-height: 240px; transition: outline-color .15s, background .15s; }
.kcol.drag-over { outline: 2px dashed var(--primary); background: rgba(123,108,255,.06); }
.kcol-head { display: flex; align-items: center; gap: 8px; font-weight: 700; padding: 4px 4px 12px; font-family: var(--font-head); }
.kcol-head .dotc { width: 10px; height: 10px; border-radius: 4px; }
.kcol-head .count { color: var(--muted); font-weight: 600; background: var(--surface-2); border-radius: 8px; padding: 0 8px; font-size: 12px; margin-left: auto; }
.kcards { display: grid; gap: 10px; }
.kcard { background: var(--surface); border: 1px solid var(--border); border-radius: 14px; padding: 13px 14px; cursor: grab; display: grid; gap: 10px; transition: border-color .15s, transform .15s, box-shadow .15s; }
.kcard:hover { border-color: var(--border-strong); transform: translateY(-2px); box-shadow: var(--shadow-sm); }
.kcard.mine { box-shadow: inset 3px 0 0 var(--primary); }
.kcard-title { font-weight: 600; line-height: 1.35; font-size: 14px; }
.kcard-meta { display: flex; align-items: center; gap: 10px; font-size: 12px; color: var(--muted); flex-wrap: wrap; }
.kcard-meta .inline-ico .ico { width: 13px; height: 13px; }
.kempty { color: var(--faint); font-size: 12px; text-align: center; padding: 18px 8px; border: 1px dashed var(--border); border-radius: 12px; }
.chip { font-size: 11px; font-weight: 700; padding: 3px 9px; border-radius: 20px; display: inline-flex; align-items: center; gap: 5px; }
.chip::before { content: ''; width: 6px; height: 6px; border-radius: 50%; background: currentColor; }
.chip.nodot::before { display: none; }
.p-baixa { background: rgba(140,147,181,.14); color: #aab1d3; }
.p-media { background: rgba(92,160,255,.14); color: #7fb5ff; }
.p-alta { background: rgba(255,190,85,.14); color: #ffc46b; }
.p-urgente { background: rgba(255,107,122,.16); color: #ff8a96; }
.overdue { color: var(--red) !important; font-weight: 600; }
.progress { height: 5px; background: rgba(255,255,255,.07); border-radius: 4px; overflow: hidden; }
.progress > i { display: block; height: 100%; background: linear-gradient(90deg, #3ddc97, #4fd1c5); border-radius: 4px; }

/* ---------- Modal ---------- */
.modal-back { position: fixed; inset: 0; background: rgba(5, 7, 16, .65); backdrop-filter: blur(4px); z-index: 100; display: grid; place-items: center; padding: 16px; animation: fade .15s; }
@keyframes fade { from { opacity: 0; } }
.modal { background: var(--surface); border: 1px solid var(--border-strong); border-radius: 22px; width: min(780px, 100%); max-height: calc(100vh - 32px); overflow: auto; box-shadow: var(--shadow); animation: pop .2s ease-out; }
.modal-head { display: flex; justify-content: space-between; align-items: center; padding: 18px 24px; border-bottom: 1px solid var(--border); position: sticky; top: 0; background: var(--surface); z-index: 1; }
.modal-head h2 { margin: 0; font-size: 18px; font-weight: 800; }
.modal-body { padding: 20px 24px; display: grid; gap: 16px; }
.modal-foot { padding: 14px 24px; border-top: 1px solid var(--border); display: flex; gap: 8px; justify-content: flex-end; position: sticky; bottom: 0; background: var(--surface); }
.form-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(160px, 1fr)); gap: 12px; }
.checklist { display: grid; gap: 6px; }
.check-item { display: flex; align-items: center; gap: 10px; padding: 9px 11px; border-radius: 11px; background: var(--bg-2); border: 1px solid var(--border); }
.check-item.done span { text-decoration: line-through; color: var(--faint); }
.check-item span { flex: 1; }
.comments { display: grid; gap: 12px; }
.comment { display: flex; gap: 10px; }
.comment .bubble { background: var(--bg-2); border: 1px solid var(--border); border-radius: 4px 14px 14px 14px; padding: 9px 13px; flex: 1; white-space: pre-wrap; line-height: 1.45; }
.comment .bubble small { color: var(--muted); display: block; margin-bottom: 3px; }
.hint { background: rgba(123,108,255,.1); border: 1px solid rgba(123,108,255,.25); color: #cfc8ff; border-radius: 13px; padding: 11px 14px; font-size: 13px; display: flex; gap: 10px; line-height: 1.45; }
.hint .ico { color: #b5abff; margin-top: 1px; }
.chips-select { display: flex; flex-wrap: wrap; gap: 7px; }
.chips-select label { display: flex; flex-direction: row; align-items: center; gap: 7px; border: 1px solid var(--border-strong); border-radius: 22px; padding: 5px 12px 5px 6px; cursor: pointer; color: var(--text); font-weight: 500; transition: background .15s, border-color .15s; }
.chips-select label input { display: none; }
.chips-select label:has(input:checked) { background: var(--primary-soft); border-color: var(--primary); }

/* ---------- Reuniões ---------- */
.meet { display: grid; gap: 12px; }
.meet-card { display: grid; grid-template-columns: 78px 1fr; gap: 16px; }
.meet-when { text-align: center; background: var(--bg-2); border: 1px solid var(--border); border-radius: 14px; padding: 10px 4px; align-self: start; }
.meet-when b { display: block; font-size: 21px; font-family: var(--font-head); font-variant-numeric: tabular-nums; margin: 2px 0; }
.meet-card.live { border-color: rgba(61,220,151,.45); background: linear-gradient(135deg, rgba(61,220,151,.08), transparent 60%), var(--surface); }
.live-tag { display: inline-flex; align-items: center; gap: 6px; color: var(--green); font-weight: 700; font-size: 11px; text-transform: uppercase; letter-spacing: .06em; }
.live-tag::before { content: ''; width: 7px; height: 7px; border-radius: 50%; background: var(--green); animation: pulse 1.4s infinite; }
@keyframes pulse { 50% { box-shadow: 0 0 0 6px rgba(61,220,151,0); } 0% { box-shadow: 0 0 0 0 rgba(61,220,151,.6); } }
.meet-card h3 { margin: 0 0 4px; font-size: 16px; }
.agenda { white-space: pre-wrap; color: #c7cbe3; font-size: 13px; margin: 10px 0 0; background: var(--bg-2); border-radius: 11px; padding: 10px 12px; line-height: 1.5; }
.stack { display: flex; }
.stack .avatar { box-shadow: 0 0 0 2px var(--surface); margin-left: -7px; }
.stack .avatar:first-child { margin-left: 0; }
.rooms { display: grid; grid-template-columns: repeat(auto-fit, minmax(170px, 1fr)); gap: 12px; }
.room-card { display: grid; gap: 12px; padding: 15px; position: relative; overflow: hidden; }
.room-card::after { content: ''; position: absolute; inset: 0 0 auto 0; height: 3px; background: var(--room, var(--primary)); }
.room-card .row { justify-content: space-between; }
.room-card b { font-family: var(--font-head); }

/* ---------- Ponto ---------- */
.ponto-card { position: relative; overflow: hidden; padding: 22px; }
.ponto-card::before { content: ''; position: absolute; width: 300px; height: 300px; right: -80px; top: -140px; border-radius: 50%; background: var(--glow, rgba(123,108,255,.18)); filter: blur(40px); pointer-events: none; }
.ponto-hero { position: relative; display: grid; grid-template-columns: 1fr auto; gap: 20px; align-items: center; }
.big-clock { font-family: var(--font-head); font-size: 50px; font-weight: 800; letter-spacing: -2px; font-variant-numeric: tabular-nums; line-height: 1.05; margin: 2px 0 8px; }
.ponto-actions { display: flex; flex-wrap: wrap; gap: 10px; }
.ponto-actions .btn { padding: 13px 20px; font-size: 14px; border-radius: 13px; }
.state-pill { display: inline-flex; align-items: center; gap: 7px; padding: 4px 11px; border-radius: 20px; font-weight: 700; font-size: 12px; background: rgba(255,255,255,.06); }
.workbar { height: 8px; border-radius: 6px; background: rgba(255,255,255,.07); overflow: hidden; margin-top: 14px; }
.workbar i { display: block; height: 100%; background: linear-gradient(90deg, #7b6cff, #4fd1c5); border-radius: 6px; transition: width .5s; }
.timeline { position: relative; display: flex; flex-wrap: wrap; gap: 8px; margin-top: 16px; }
.timeline span { background: var(--bg-2); border: 1px solid var(--border); border-radius: 10px; padding: 5px 11px; font-size: 12px; color: var(--muted); }
.timeline b { color: var(--text); }
table { width: 100%; border-collapse: separate; border-spacing: 0; background: var(--surface); border-radius: 16px; overflow: hidden; border: 1px solid var(--border); }
th, td { text-align: left; padding: 12px 14px; border-bottom: 1px solid var(--border); font-size: 13px; vertical-align: top; }
th { background: var(--bg-2); color: var(--muted); font-weight: 700; font-size: 11px; text-transform: uppercase; letter-spacing: .06em; }
tbody tr { transition: background .12s; }
tbody tr:hover { background: rgba(255,255,255,.025); }
tr:last-child td { border-bottom: 0; }
td.num, th.num { text-align: right; font-variant-numeric: tabular-nums; }
.pos { color: var(--green); }
.neg { color: var(--red); }
.tabs { display: flex; gap: 4px; background: var(--bg-2); border: 1px solid var(--border); padding: 4px; border-radius: 13px; width: fit-content; margin-bottom: 20px; }
.tabs button { border: 0; background: transparent; padding: 8px 16px; border-radius: 10px; cursor: pointer; font-weight: 600; color: var(--muted); }
.tabs button.active { background: var(--surface-3); color: var(--text); box-shadow: var(--shadow-sm); }
.stats { display: grid; grid-template-columns: repeat(auto-fit, minmax(150px, 1fr)); gap: 12px; }
.stat { display: grid; gap: 4px; background: var(--surface); border: 1px solid var(--border); border-radius: 16px; padding: 16px 18px; }
.stat b { font-size: 26px; font-variant-numeric: tabular-nums; font-family: var(--font-head); font-weight: 800; }
.stat > span { color: var(--muted); font-size: 12px; }
.person { display: flex; align-items: center; gap: 12px; }
.person .info { flex: 1; min-width: 0; }
.person .info b { display: block; }

/* ---------- Equipe ---------- */
.person-card { display: grid; gap: 14px; }
.person-card .top { display: flex; gap: 14px; align-items: center; }
.person-card .meta { display: flex; flex-wrap: wrap; gap: 6px; }
.tag { display: inline-flex; align-items: center; gap: 6px; background: var(--bg-2); border: 1px solid var(--border); border-radius: 9px; padding: 4px 9px; font-size: 12px; color: var(--muted); }

/* ---------- Toasts ---------- */
#toasts { position: fixed; right: 18px; bottom: 18px; z-index: 200; display: grid; gap: 10px; width: min(380px, calc(100% - 36px)); }
.toast { background: rgba(22, 26, 48, .92); backdrop-filter: blur(14px); border: 1px solid var(--border-strong); color: #fff; border-radius: 16px; padding: 13px 14px 13px 16px; box-shadow: var(--shadow); display: flex; gap: 10px; align-items: center; animation: slidein .25s ease-out; font-size: 13.5px; line-height: 1.4; }
.toast .btn { flex-shrink: 0; }
@keyframes slidein { from { transform: translateY(14px); opacity: 0; } }

@media (max-width: 860px) {
  .login-wrap { grid-template-columns: 1fr; gap: 28px; }
  .login-hero h1 { font-size: 32px; margin: 16px 0; }
  .hero-list { display: none; }
}
@media (max-width: 720px) {
  #sidebar { width: 60px; }
  .nav-btn { width: 50px; }
  .nav-btn small { display: none; }
  #panel { left: 60px; }
  #panel.narrow { width: calc(100% - 60px); }
  #panelBody { padding: 16px; }
  .people, .ctrl-help, .clock-hud { display: none; }
  .chat { width: calc(100% - 28px); }
  .vtile { width: 120px; }
  .ponto-hero { grid-template-columns: 1fr; }
  .big-clock { font-size: 40px; }
}

/* =====================================================================
   Tema "pixel hotel": janelas com borda grossa, sombra dura e fonte pixelada
   ===================================================================== */
:root {
  --bg: #15132b;
  --bg-2: #1b1838;
  --surface: #221e45;
  --surface-2: #2b2655;
  --surface-3: #363068;
  --border: #0c0a1c;
  --border-strong: #0c0a1c;
  --ink: #0c0a1c;
  --primary: #6a5cff;
  --pixel: 'Pixelify Sans', 'Silkscreen', monospace;
  --radius: 10px;
  --hard: 4px 4px 0 rgba(6, 4, 18, .7);
  --hard-sm: 3px 3px 0 rgba(6, 4, 18, .65);
}
h1, h2, h3, .brand, #panelHead h1, .section-title, .kcol-head, .floating-head, .nav-btn small,
.btn, .tabs button, .chip, .stat b, .big-clock, .meet-when b, .live-tag, .pill, .badge, .hello h2, .login-hero h1, .state-pill {
  font-family: var(--pixel); letter-spacing: 0;
}
.big-clock { letter-spacing: 1px; font-weight: 700; }
.login-hero h1 { font-weight: 700; line-height: 1.15; }

/* janelas e cartões */
.card, .kcol, .modal, .glass, .glass-dark, .toast, table, .stat, .tabs, .floating, #controls, .hud, .vtile, .meet-when, .preview, .hint, .agenda, .check-item, .comment .bubble, .empty, .timeline span, .tag {
  border: 2px solid var(--ink) !important;
  box-shadow: var(--hard-sm);
}
.card, .kcol, .stat, table { box-shadow: var(--hard); border-radius: 10px; }
.modal, .glass { border-radius: 12px; box-shadow: 6px 6px 0 rgba(6,4,18,.75); }
.card { background: var(--surface); position: relative; }
.card::before { content: ''; position: absolute; inset: 0 0 auto 0; height: 2px; background: rgba(255,255,255,.07); border-radius: 10px 10px 0 0; pointer-events: none; }
.kcard { border: 2px solid var(--ink); box-shadow: 2px 2px 0 rgba(6,4,18,.6); border-radius: 8px; background: var(--surface-2); }
.kcard:hover { transform: translate(-1px, -1px); box-shadow: 4px 4px 0 rgba(6,4,18,.7); border-color: var(--ink); }
.kcard.mine { box-shadow: inset 4px 0 0 var(--primary), 2px 2px 0 rgba(6,4,18,.6); }
.empty { border-style: dashed !important; box-shadow: none; background: rgba(255,255,255,.02); }
.timeline span, .tag, .check-item, .agenda, .comment .bubble { box-shadow: none; }

/* barra de título nas janelas */
.modal-head, #panelHead { background: linear-gradient(180deg, #4b3fd1 0%, #3a2fb0 100%); border-bottom: 2px solid var(--ink); }
.modal-head h2, #panelHead h1 { color: #fff; text-shadow: 2px 2px 0 rgba(6,4,18,.6); }
.modal-head .icon-btn, #panelHead .icon-btn { color: #fff; background: rgba(0,0,0,.2); border: 2px solid var(--ink); border-radius: 7px; }
.modal-head .icon-btn:hover, #panelHead .icon-btn:hover { background: #ff5468; }
.modal-foot { border-top: 2px solid var(--ink); background: var(--bg-2); }
#panel { border-left: 2px solid var(--ink); }
#panelBody { background:
  linear-gradient(rgba(255,255,255,.018) 1px, transparent 1px) 0 0 / 16px 16px,
  linear-gradient(90deg, rgba(255,255,255,.018) 1px, transparent 1px) 0 0 / 16px 16px, var(--bg); }

/* botões "3D" */
.btn {
  border: 2px solid var(--ink); border-radius: 9px; font-weight: 600; font-size: 14px;
  box-shadow: inset 0 -3px 0 rgba(0,0,0,.28), inset 0 2px 0 rgba(255,255,255,.12), 2px 2px 0 rgba(6,4,18,.6);
  background: var(--surface-3);
}
.btn:hover { background: #423b7c; transform: translateY(-1px); }
.btn:active { transform: translateY(1px); box-shadow: inset 0 2px 0 rgba(0,0,0,.25); }
.btn.primary { background: #6a5cff; box-shadow: inset 0 -3px 0 #4335c9, inset 0 2px 0 rgba(255,255,255,.25), 2px 2px 0 rgba(6,4,18,.6); }
.btn.primary:hover { background: #7a6dff; filter: none; }
.btn.success { background: #34c77b; color: #06240f; box-shadow: inset 0 -3px 0 #1f8f53, inset 0 2px 0 rgba(255,255,255,.3), 2px 2px 0 rgba(6,4,18,.6); }
.btn.warn { background: #ffbe55; color: #3a2400; box-shadow: inset 0 -3px 0 #c98a1e, inset 0 2px 0 rgba(255,255,255,.35), 2px 2px 0 rgba(6,4,18,.6); }
.btn.danger { background: #ff5468; color: #fff; box-shadow: inset 0 -3px 0 #c12a3e, inset 0 2px 0 rgba(255,255,255,.25), 2px 2px 0 rgba(6,4,18,.6); }
.btn.danger:hover { background: #ff6a7c; }
.btn.ghost { border-color: transparent; box-shadow: none; background: transparent; }
.btn.ghost:hover { background: var(--surface-3); border-color: var(--ink); }
.btn.block { font-size: 16px; }

/* campos */
input, select, textarea { border: 2px solid var(--ink); background: #120f28; border-radius: 8px; box-shadow: inset 2px 2px 0 rgba(0,0,0,.35); }
input:focus, select:focus, textarea:focus { border-color: var(--primary); box-shadow: inset 2px 2px 0 rgba(0,0,0,.35), 0 0 0 3px rgba(106,92,255,.3); }
#chatForm input { border: 2px solid var(--ink); background: #120f28; }
.send-btn { border: 2px solid var(--ink); background: #6a5cff; box-shadow: inset 0 -3px 0 #4335c9; }

/* chips e etiquetas */
.chip { border: 2px solid var(--ink); border-radius: 6px; padding: 1px 7px; font-size: 12px; }
.chip::before { border-radius: 1px; }
.p-baixa { background: #3a3e5c; color: #d2d6ee; }
.p-media { background: #2f5fd6; color: #fff; }
.p-alta { background: #f0a02a; color: #2b1800; }
.p-urgente { background: #e93a50; color: #fff; }
.pill { border: 2px solid var(--ink); border-radius: 6px; background: #6a5cff; color: #fff; }
.badge { border-radius: 5px; box-shadow: 0 0 0 2px var(--ink); font-size: 11px; }
.avatar { box-shadow: 0 0 0 2px var(--ink); border-radius: 8px; }
.stack .avatar { box-shadow: 0 0 0 2px var(--ink); }
.status-dot { border-radius: 2px; box-shadow: 0 0 0 1.5px var(--ink); }
.st-trabalhando { box-shadow: 0 0 0 1.5px var(--ink); }
.progress, .workbar { border: 2px solid var(--ink); border-radius: 5px; height: 12px; background: #120f28; }
.progress { height: 9px; }
.progress > i, .workbar i { border-radius: 0; background: repeating-linear-gradient(90deg, #3ddc97 0 6px, #2fbf80 6px 8px); }

/* barra lateral */
#sidebar { background: #0f0d22; border-right: 2px solid var(--ink); }
.nav-btn { border: 2px solid transparent; border-radius: 10px; }
.nav-btn.active { background: #2b2655; border-color: var(--ink); box-shadow: 2px 2px 0 rgba(6,4,18,.7); }
.nav-btn.active::before { display: none; }
.nav-btn small { font-size: 11px; font-weight: 500; }

/* tabelas e abas */
th { background: #2b2655; color: #c9c3f5; font-family: var(--pixel); font-size: 12px; letter-spacing: .02em; border-bottom: 2px solid var(--ink); }
.tabs { padding: 3px; }
.tabs button { border-radius: 7px; font-size: 14px; }
.tabs button.active { background: #6a5cff; color: #fff; box-shadow: inset 0 -3px 0 #4335c9; }
.kcol { background: #1b1838; }
.kcol-head .dotc { border: 2px solid var(--ink); border-radius: 3px; width: 12px; height: 12px; }
.kcol-head .count, .section-title .count { border: 2px solid var(--ink); border-radius: 6px; }
.section-title { color: #b3acdf; font-size: 13px; letter-spacing: .04em; }

/* elementos sobre o mapa */
.glass-dark { background: rgba(27, 24, 56, .94); backdrop-filter: none; }
.floating, .hud, #controls { border-radius: 12px; }
.floating-head { border-bottom: 2px solid var(--ink); background: #2b2655; border-radius: 10px 10px 0 0; padding: 9px 12px; margin-bottom: 6px; font-size: 14px; }
.ctrl { border: 2px solid var(--ink); border-radius: 10px; background: #363068; box-shadow: inset 0 -3px 0 rgba(0,0,0,.3), inset 0 2px 0 rgba(255,255,255,.1); }
.ctrl:hover { background: #423b7c; }
.ctrl.subtle { border-color: transparent; box-shadow: none; }
#micBtn:not(.on), #camBtn:not(.on) { background: #ff5468; box-shadow: inset 0 -3px 0 #c12a3e; }
#awayBtn.on { box-shadow: inset 0 -3px 0 #c98a1e; }
kbd { border: 2px solid var(--ink); background: #363068; border-radius: 4px; font-family: var(--pixel); }
.vtile { border-radius: 10px; }
.vtile .vname { border-radius: 5px; font-family: var(--pixel); }
.toast { background: #221e45; border-radius: 10px; backdrop-filter: none; }

/* telas de entrada */
.screen { background: #15132b; }
.screen::before { content: ''; position: absolute; inset: 0; background:
  linear-gradient(rgba(255,255,255,.03) 2px, transparent 2px) 0 0 / 32px 32px,
  linear-gradient(90deg, rgba(255,255,255,.03) 2px, transparent 2px) 0 0 / 32px 32px; }
.blob { filter: blur(90px); opacity: .35; }
.hero-list li > span { border: 2px solid var(--ink); border-radius: 8px; background: #2b2655; box-shadow: 2px 2px 0 rgba(6,4,18,.6); }
.round-btn { border: 2px solid var(--ink); box-shadow: inset 0 -3px 0 rgba(0,0,0,.3); }
.ponto-card::before { opacity: .6; }

/* ---------- Editor de avatar ---------- */
img.avatar.pixel { image-rendering: pixelated; object-fit: cover; display: inline-block; vertical-align: middle; background: var(--surface-3); }
.nav-me { cursor: pointer; border-radius: 10px; padding: 2px; transition: transform .1s; }
.nav-me:hover { transform: scale(1.08); }
.modal.wide { width: min(880px, 100%); }
.avatar-editor { display: grid; grid-template-columns: 300px 1fr; gap: 22px; align-items: start; }
.av-stage { position: sticky; top: 0; display: grid; gap: 12px; justify-items: center; padding: 16px; border: 2px solid var(--ink); border-radius: 12px; box-shadow: var(--hard-sm);
  background: radial-gradient(circle at 50% 35%, #3a3170, #1b1838 70%); }
#avCanvas { width: 288px; height: 256px; image-rendering: pixelated; }
.av-options { display: grid; gap: 16px; }
.av-group h4 { margin: 0 0 8px; font-family: var(--pixel); font-size: 15px; color: #d7d1ff; }
.opts { display: flex; flex-wrap: wrap; gap: 6px; margin-bottom: 8px; }
.opt { border: 2px solid var(--ink); background: var(--surface-3); color: var(--text); border-radius: 8px; padding: 5px 11px; cursor: pointer; font-family: var(--pixel); font-size: 13px;
  box-shadow: inset 0 -3px 0 rgba(0,0,0,.28); }
.opt:hover { background: #423b7c; }
.opt.on { background: #6a5cff; color: #fff; box-shadow: inset 0 -3px 0 #4335c9; }
.swatches { display: flex; flex-wrap: wrap; gap: 6px; }
.sw { width: 28px; height: 28px; border: 2px solid var(--ink); border-radius: 7px; cursor: pointer; box-shadow: inset 0 -3px 0 rgba(0,0,0,.25); transition: transform .1s; }
.sw:hover { transform: translateY(-2px); }
.sw.on { outline: 3px solid #fff; outline-offset: 1px; }
@media (max-width: 760px) { .avatar-editor { grid-template-columns: 1fr; } .av-stage { position: static; } }

/* ---------- Estilo Gather: status, cartões, reações, chat em canais, minimapa ---------- */
.sdot { position: absolute; right: -2px; bottom: -2px; width: 10px; height: 10px; border-radius: 2px; box-shadow: 0 0 0 2px var(--ink); }
.st-disponivel { background: #3ddc97; }
.st-ocupado { background: #ff5468; }
.st-ausente { background: #ffbe55; }
.st-off { background: #6c7092; }
.pstatus { display: inline-flex; align-items: center; gap: 6px; font-size: 12px; font-weight: 600; background: none !important; }
.pstatus i { width: 9px; height: 9px; border-radius: 2px; box-shadow: 0 0 0 1.5px var(--ink); }
.pstatus.st-disponivel i { background: #3ddc97; } .pstatus.st-ocupado i { background: #ff5468; }
.pstatus.st-ausente i { background: #ffbe55; } .pstatus.st-off i { background: #6c7092; }
.ptext { font-size: 12px; color: #c9c4e6; margin-left: 8px; }

.status-btn { width: auto !important; padding: 0 8px; gap: 6px; display: flex !important; align-items: center; }
.status-btn .avatar { width: 30px; height: 30px; }
.semoji { font-size: 16px; }
#screenBtn.sharing { background: #34c77b; color: #06240f; box-shadow: inset 0 -3px 0 #1f8f53; }
#handBtn.on, #reactBtn.on { background: #ffbe55; color: #2b1d00; box-shadow: inset 0 -3px 0 #c98a1e; }

.popover { position: absolute; z-index: 20; width: 300px; background: #221e45; color: #e8ebf5; border: 2px solid var(--ink); border-radius: 12px;
  box-shadow: 5px 5px 0 rgba(6,4,18,.7); padding: 12px; display: grid; gap: 10px; animation: pop .15s ease-out; }
.popover.react-pop { width: auto; padding: 8px; }
.popover.status-pop { width: 330px; }
.popover input { width: 100%; }
.pc-top { display: flex; gap: 11px; align-items: center; }
.pc-info { display: grid; gap: 2px; min-width: 0; }
.pc-info b { font-family: var(--pixel); font-size: 16px; font-weight: 600; }
.pc-status { margin-top: 3px; display: flex; flex-wrap: wrap; align-items: center; }
.pc-meta { display: flex; flex-wrap: wrap; gap: 6px; }
.pc-meta span { display: inline-flex; gap: 5px; align-items: center; font-size: 11.5px; color: #bdb7e4; background: #2b2655; border: 2px solid var(--ink); border-radius: 6px; padding: 2px 7px; }
.pc-actions { display: grid; grid-template-columns: repeat(3, 1fr); gap: 6px; }
.pc-btn { display: grid; justify-items: center; gap: 4px; padding: 8px 4px; border: 2px solid var(--ink); border-radius: 9px; background: #363068; color: #fff; cursor: pointer;
  font-family: var(--pixel); font-size: 12.5px; box-shadow: inset 0 -3px 0 rgba(0,0,0,.3), inset 0 2px 0 rgba(255,255,255,.1); }
.pc-btn:hover:not(:disabled) { background: #6a5cff; }
.pc-btn:disabled { opacity: .4; cursor: not-allowed; }
.pc-title { font-family: var(--pixel); font-size: 15px; display: flex; gap: 7px; align-items: center; }
.pc-row { display: flex; gap: 6px; align-items: center; flex-wrap: wrap; }
.pc-row input { flex: 1; min-width: 0; }
.popover p { margin: 0; }
.status-opts { display: grid; gap: 4px; }
.status-opt { display: flex; gap: 10px; align-items: center; text-align: left; border: 2px solid transparent; border-radius: 9px; background: transparent; color: #fff; padding: 7px 8px; cursor: pointer; }
.status-opt:hover { background: #2b2655; }
.status-opt.on { background: #2b2655; border-color: var(--ink); }
.status-opt b { display: block; font-size: 13.5px; }
.status-opt small { color: #a9a3d4; font-size: 11.5px; }
.emoji-row { display: flex; flex-wrap: wrap; gap: 4px; }
.emo { width: 34px; height: 34px; border: 2px solid var(--ink); border-radius: 8px; background: #2b2655; cursor: pointer; font-size: 17px; display: grid; place-items: center; transition: transform .1s; }
.emo:hover { transform: translateY(-2px); background: #423b7c; }
.emo.on { background: #6a5cff; }
.emoji-row.big .emo { width: 42px; height: 42px; font-size: 22px; }

.chat-tabs { display: flex; gap: 3px; }
.chat-tabs button { position: relative; border: 2px solid transparent; background: transparent; color: #b8b2e0; font-family: var(--pixel); font-size: 13px; padding: 3px 8px; border-radius: 7px; cursor: pointer; }
.chat-tabs button:hover { color: #fff; }
.chat-tabs button.active { background: #6a5cff; color: #fff; border-color: var(--ink); }
.chat-tabs .muted { color: inherit; opacity: .7; font-size: 11px; }
.cbadge { background: #ff5468; color: #fff; border-radius: 5px; font-size: 10px; padding: 0 4px; margin-left: 4px; box-shadow: 0 0 0 2px var(--ink); font-family: var(--pixel); }
.cbadge:empty { display: none; }
.chat { width: 340px; }
.chat-empty { color: #9690c4; font-size: 12px; margin: auto; text-align: center; padding: 0 10px; line-height: 1.5; }
.dm-head { display: flex; align-items: center; gap: 8px; padding: 0 12px 8px; font-size: 13px; }
.dm-head .icon-btn { color: #fff; }
#chatList.conv-list { gap: 2px; padding: 0 6px 8px; height: 262px; }
.conv { display: flex; align-items: center; gap: 9px; text-align: left; border: 0; background: transparent; color: #e8ebf5; padding: 6px 8px; border-radius: 9px; cursor: pointer; }
.conv:hover { background: rgba(255,255,255,.07); }
.conv > div { flex: 1; min-width: 0; }
.conv b { display: block; font-size: 13px; }
.conv small { display: block; color: #9690c4; font-size: 11.5px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.people li .pname { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }

.minimap { right: 14px; bottom: 80px; padding: 6px; cursor: crosshair; }
#minimap { display: block; width: 200px; height: 125px; image-rendering: pixelated; border: 2px solid var(--ink); border-radius: 6px; }
#followHud { top: 70px; left: 50%; transform: translateX(-50%); display: flex; gap: 8px; align-items: center; padding: 6px 6px 6px 12px; }

#spotStage { position: absolute; inset: 0; z-index: 15; background: rgba(8,6,20,.78); display: grid; place-items: center; padding: 40px 40px 90px; }
#spotStage .vtile.spot { width: min(100%, calc((100vh - 200px) * 16 / 9)); aspect-ratio: 16/9; height: auto; }
.vtile.screen video { object-fit: contain; background: #000; transform: none !important; }
.vexpand { position: absolute; top: 6px; right: 6px; width: 26px; height: 26px; border: 2px solid var(--ink); border-radius: 6px; background: rgba(20,16,40,.75); color: #fff;
  cursor: pointer; display: grid; place-items: center; opacity: 0; transition: opacity .15s; }
.vtile:hover .vexpand, .vtile.spot .vexpand { opacity: 1; }

.search-modal { width: min(560px, 100%); }
.search-input { font-size: 16px; padding: 12px 14px; width: 100%; }
.results { display: grid; gap: 4px; margin-top: 10px; max-height: 52vh; overflow-y: auto; }
.result { display: flex; align-items: center; gap: 10px; padding: 8px 10px; border-radius: 9px; cursor: pointer; border: 2px solid transparent; }
.result > div { flex: 1; min-width: 0; }
.result b { display: block; font-size: 14px; }
.result small { color: var(--muted); font-size: 12px; }
.result:hover, .result.sel { background: #2b2655; border-color: var(--ink); }
.ricon { width: 28px; height: 28px; border-radius: 8px; background: #363068; display: grid; place-items: center; border: 2px solid var(--ink); flex-shrink: 0; }
.rkind { font-family: var(--pixel); font-size: 11px; color: #a9a3d4; }
@media (max-width: 720px) { .minimap { display: none; } }

/* ---------- Autocadastro e convite ---------- */
.switch-auth { text-align: center; font-size: 13.5px; color: var(--muted); }
.switch-auth a { color: #a99cff; font-weight: 600; }
.invite-card { display: grid; gap: 10px; }
.invite-row { display: flex; gap: 8px; align-items: center; flex-wrap: wrap; }
.invite-code { font-family: var(--pixel); font-size: 22px; letter-spacing: .12em; background: #120f28; border: 2px solid var(--ink); border-radius: 8px; padding: 4px 12px; }
.invite-link { flex: 1; min-width: 220px; font-size: 12.5px; }

/* ---------- Editor do escritório ---------- */
body.editing #chatPanel, body.editing #controls, body.editing #peoplePanel, body.editing #zoneHud, body.editing #clockHud, body.editing #videoBar { display: none !important; }
body.editing #map { cursor: crosshair; }
.editor-panel { left: 14px; top: 14px; bottom: 14px; width: 300px; display: flex; flex-direction: column; z-index: 6; }
.ed-body { flex: 1; overflow-y: auto; padding: 4px 12px 12px; display: grid; gap: 12px; align-content: start; }
.ed-group h5 { margin: 0 0 6px; font-family: var(--pixel); font-size: 13px; color: #b3acdf; font-weight: 500; }
.ed-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 5px; }
.ed-tool { display: grid; justify-items: center; gap: 2px; padding: 6px 2px; border: 2px solid var(--ink); border-radius: 8px; background: #2b2655; color: #e8ebf5; cursor: pointer;
  box-shadow: inset 0 -3px 0 rgba(0,0,0,.28); }
.ed-tool span { font-size: 19px; line-height: 1.1; }
.ed-tool small { font-size: 10.5px; line-height: 1.15; text-align: center; color: #c9c4e6; }
.ed-tool:hover { background: #3a3470; }
.ed-tool.on { background: #6a5cff; box-shadow: inset 0 -3px 0 #4335c9; }
.ed-tool.on small { color: #fff; }
.ed-hint { margin: 6px 0 0; font-size: 11.5px; color: #9690c4; line-height: 1.4; }
.ed-zones { display: grid; gap: 4px; margin-top: 8px; }
.ed-zone { display: flex; align-items: center; gap: 8px; border: 2px solid var(--ink); border-radius: 8px; background: #221e45; color: #e8ebf5; padding: 5px 8px; cursor: pointer; font-size: 12.5px; text-align: left; }
.ed-zone:hover { background: #2b2655; }
.ed-zone i { width: 12px; height: 12px; border-radius: 3px; border: 2px solid var(--ink); flex-shrink: 0; }
.ed-zone small { margin-left: auto; color: #9690c4; font-size: 11px; }
.ed-body input[type=number] { width: 64px; }
.ed-body select { flex: 1; min-width: 0; }
.ed-foot { display: flex; gap: 6px; align-items: center; padding: 10px 12px; border-top: 2px solid var(--ink); }

/* ---------- Entrar / criar conta ---------- */
.auth-screen { padding: 0; place-items: stretch; }
.auth-shell { display: grid; grid-template-columns: minmax(0, 1.35fr) minmax(400px, 520px); height: 100%; width: 100%; }
.auth-scene { position: relative; overflow: hidden; margin: 16px 0 16px 16px; border-radius: 22px; border: 2px solid #0c0a1c; box-shadow: var(--hard);
  background:
    radial-gradient(70% 60% at 50% 45%, rgba(123,108,255,.28), transparent 70%),
    linear-gradient(rgba(255,255,255,.035) 1px, transparent 1px) 0 0 / 24px 24px,
    linear-gradient(90deg, rgba(255,255,255,.035) 1px, transparent 1px) 0 0 / 24px 24px,
    linear-gradient(160deg, #221c4f, #12102a 70%); }
#authScene { position: absolute; inset: 0; width: 100%; height: 100%; image-rendering: pixelated; }
#authBubbles { position: absolute; inset: 0; pointer-events: none; }
.auth-bubble { position: absolute; left: 0; top: 0; background: #fff; color: #1b1838; border: 2px solid #0c0a1c; border-radius: 10px; padding: 5px 9px 6px; font-size: 12.5px; font-weight: 600; white-space: nowrap; box-shadow: var(--hard-sm); animation: bubin .25s cubic-bezier(.3,1.6,.6,1); transition: opacity .3s; }
.auth-bubble b { display: block; font-family: var(--pixel); font-size: 10px; color: #6a5cff; font-weight: 700; margin-bottom: 1px; }
.auth-bubble::after { content: ''; position: absolute; left: 50%; bottom: -7px; width: 10px; height: 10px; background: #fff; border: 2px solid #0c0a1c; border-top: 0; border-left: 0; transform: translateX(-50%) rotate(45deg); }
.auth-bubble.out { opacity: 0; }
@keyframes bubin { from { opacity: 0; scale: .6; } }
.auth-scene-top { position: absolute; left: 26px; right: 26px; top: 22px; display: flex; justify-content: space-between; align-items: center; gap: 12px; }
.auth-live { display: inline-flex; align-items: center; gap: 8px; padding: 6px 12px; border-radius: 99px; background: rgba(12,10,28,.7); border: 2px solid #0c0a1c; font-size: 12.5px; color: #cfd3f0; font-weight: 600; }
.auth-live i { width: 8px; height: 8px; border-radius: 50%; background: var(--green); box-shadow: 0 0 0 0 rgba(61,220,151,.6); animation: pulse 1.8s infinite; }
@keyframes pulse { 70% { box-shadow: 0 0 0 8px rgba(61,220,151,0); } 100% { box-shadow: 0 0 0 0 rgba(61,220,151,0); } }
.auth-scene-foot { position: absolute; left: 0; right: 0; bottom: 0; padding: 60px 28px 24px; background: linear-gradient(transparent, rgba(10,8,24,.92) 55%); }
.auth-scene-foot h1 { margin: 0 0 14px; font-size: clamp(24px, 2.6vw, 36px); line-height: 1.15; font-family: var(--pixel); font-weight: 700; max-width: 620px; }
.auth-feats { display: flex; flex-wrap: wrap; gap: 8px; }
.auth-feats > span { display: inline-flex; align-items: center; gap: 7px; padding: 6px 11px 6px 8px; border-radius: 10px; background: rgba(255,255,255,.07); border: 1px solid rgba(255,255,255,.1); font-size: 13px; color: #d5d8f2; font-weight: 600; }
.auth-feats [data-icon] { color: #b5abff; display: inline-flex; }

.auth-panel { display: flex; flex-direction: column; justify-content: center; align-items: center; padding: 28px 34px; overflow-y: auto; }
.auth-card { width: 100%; max-width: 430px; padding: 10px 28px 26px; border-radius: 20px; }
.auth-tabs { position: relative; display: grid; grid-template-columns: 1fr 1fr; background: var(--bg-2); border: 2px solid #0c0a1c; border-radius: 13px; padding: 4px; margin: 18px 0 22px; }
.auth-tabs button { position: relative; z-index: 1; border: 0; background: none; padding: 9px 0; border-radius: 9px; cursor: pointer; color: var(--muted); font-family: var(--pixel); font-weight: 700; font-size: 14px; transition: color .2s; }
.auth-tabs button.on { color: #fff; }
.auth-tab-ink { position: absolute; top: 4px; bottom: 4px; left: 4px; width: calc(50% - 4px); border-radius: 9px; background: var(--grad); box-shadow: 0 4px 14px rgba(110,92,255,.35); transition: transform .28s cubic-bezier(.4,1.3,.5,1); }
.auth-tabs.right .auth-tab-ink { transform: translateX(100%); }
.auth-tabs:has(#toSignupWrap.hidden) { grid-template-columns: 1fr; }
.auth-tabs:has(#toSignupWrap.hidden) .auth-tab-ink { width: calc(100% - 8px); }
.auth-form { display: grid; gap: 14px; animation: authin .3s ease-out; }
@keyframes authin { from { opacity: 0; transform: translateY(6px); } }
.auth-head h2 { margin: 0 0 4px; font-size: 23px; }
.auth-head p { margin: 0; }
.field > span { display: flex; justify-content: space-between; align-items: baseline; }
.field em { font-style: normal; color: var(--faint); font-weight: 500; }
.forgot { font-weight: 600; color: #a99cff; font-size: 12px; }
.input-ico { position: relative; display: flex; align-items: center; }
.input-ico > [data-icon] { position: absolute; left: 12px; color: var(--faint); display: inline-flex; pointer-events: none; transition: color .15s; }
.input-ico input { padding-left: 38px; }
.input-ico:focus-within > [data-icon]:first-child { color: #a99cff; }
.input-ico .eye { position: absolute; right: 6px; border: 0; background: none; color: var(--muted); cursor: pointer; padding: 6px; border-radius: 8px; display: inline-flex; }
.input-ico .eye:hover { color: #fff; background: rgba(255,255,255,.06); }
.input-ico:has(.eye) input { padding-right: 40px; }
.input-ico .match { position: absolute; right: 12px; left: auto; color: var(--green); display: inline-flex; }
input.code { text-transform: uppercase; letter-spacing: .12em; font-family: var(--pixel); }
.caps { color: var(--amber); font-weight: 600; font-size: 12px; }
.forgot-note { margin: 0; font-size: 13px; line-height: 1.5; color: #cfd3f0; background: rgba(123,108,255,.12); border: 1px solid rgba(123,108,255,.3); border-radius: 11px; padding: 10px 12px; }
.pw-meter { display: grid; grid-template-columns: repeat(4, 1fr) 70px; gap: 5px; align-items: center; margin-top: 2px; }
.pw-meter i { height: 5px; border-radius: 3px; background: rgba(255,255,255,.08); transition: background .2s; }
.pw-meter small { text-align: right; font-size: 11.5px; color: var(--faint); }
.pw-meter[data-level="1"] i:nth-child(-n+1) { background: var(--red); }
.pw-meter[data-level="2"] i:nth-child(-n+2) { background: var(--amber); }
.pw-meter[data-level="3"] i:nth-child(-n+3) { background: #7fd36b; }
.pw-meter[data-level="4"] i { background: var(--green); }
.pw-meter[data-level="1"] small { color: var(--red); }
.pw-meter[data-level="2"] small { color: var(--amber); }
.pw-meter[data-level="3"] small, .pw-meter[data-level="4"] small { color: var(--green); }
.invite-ok { display: flex; gap: 11px; align-items: center; padding: 11px 13px; border-radius: 12px; background: rgba(61,220,151,.1); border: 1px solid rgba(61,220,151,.35); }
.invite-ok > [data-icon] { width: 30px; height: 30px; border-radius: 9px; background: var(--green); color: #0c2a1c; display: grid; place-items: center; flex-shrink: 0; }
.invite-ok b { display: block; font-size: 13.5px; }
.invite-ok small { color: var(--muted); font-size: 12.5px; }
.auth-submit { margin-top: 4px; position: relative; }
.auth-submit.loading span { opacity: 0; }
.auth-submit.loading::after { content: ''; position: absolute; left: 50%; top: 50%; width: 18px; height: 18px; margin: -9px 0 0 -9px; border-radius: 50%; border: 2.5px solid rgba(255,255,255,.35); border-top-color: #fff; animation: spin .7s linear infinite; }
@keyframes spin { to { transform: rotate(360deg); } }
.auth-form.shake { animation: shake .35s; }
@keyframes shake { 20%, 60% { transform: translateX(-6px); } 40%, 80% { transform: translateX(6px); } }
.auth-closed { margin: 6px 0 4px; color: var(--muted); text-align: center; line-height: 1.5; }
.auth-foot { margin: 16px 0 0; font-size: 12.5px; color: var(--faint); text-align: center; }

@media (max-width: 920px) {
  body:has(#login:not(.hidden)) { overflow: auto; }
  .auth-screen { height: auto; min-height: 100%; }
  .auth-shell { grid-template-columns: 1fr; height: auto; }
  .auth-scene { height: 300px; margin: 12px 12px 0; }
  .auth-scene-foot { padding: 40px 18px 14px; }
  .auth-scene-foot h1 { font-size: 20px; margin: 0; }
  .auth-feats { display: none; }
  .auth-panel { padding: 18px 12px 28px; }
  .auth-card { padding: 6px 18px 22px; }
}
@media (max-width: 520px) { .auth-card .form-grid { grid-template-columns: 1fr; } .auth-live { display: none; } }
