@import url('https://fonts.googleapis.com/css2?family=Nunito:wght@400;500;600;700;800;900&family=Syne:wght@700;800&display=swap');

:root {
  --yellow: #FFD93D;
  --orange: #FF6B35;
  --orange-dark: #E8541E;
  --gold: #FFB800;
  --bg: #0F0F13;
  --bg2: #18181f;
  --bg3: #22222d;
  --surface: #1e1e28;
  --border: rgba(255,180,50,0.15);
  --text: #F5F0E8;
  --text-muted: #9994A0;
  --gradient: linear-gradient(135deg, var(--yellow) 0%, var(--orange) 100%);
  --gradient-soft: linear-gradient(135deg, rgba(255,217,61,0.12) 0%, rgba(255,107,53,0.12) 100%);
  --shadow-glow: 0 0 30px rgba(255,107,53,0.2);
  --radius: 16px;
  --radius-sm: 10px;
}

* { margin:0; padding:0; box-sizing:border-box; }
html,body { height:100%; font-family:'Nunito',sans-serif; background:var(--bg); color:var(--text); overflow:hidden; }

::-webkit-scrollbar { width:5px; }
::-webkit-scrollbar-track { background:transparent; }
::-webkit-scrollbar-thumb { background:rgba(255,107,53,0.4); border-radius:10px; }

/* ====== LANDING PAGE ====== */
.landing-page { min-height:100vh; overflow:auto; background:var(--bg); }
.landing-page::-webkit-scrollbar { width:6px; }

.land-nav {
  display:flex; align-items:center; justify-content:space-between;
  padding:20px 60px; border-bottom:1px solid var(--border);
  position:sticky; top:0; z-index:100;
  background:rgba(15,15,19,0.9); backdrop-filter:blur(20px);
}
.land-logo { display:flex; align-items:center; gap:12px; }
.land-logo .logo-icon {
  width:44px; height:44px; background:var(--gradient);
  border-radius:12px; display:flex; align-items:center; justify-content:center;
  font-size:22px; box-shadow:0 4px 16px rgba(255,107,53,0.4);
}
.land-logo h1 {
  font-family:'Syne',sans-serif; font-size:24px; font-weight:800;
  background:var(--gradient); -webkit-background-clip:text;
  -webkit-text-fill-color:transparent; background-clip:text;
}
.land-nav-links { display:flex; align-items:center; gap:12px; }
.land-nav-links a {
  padding:10px 22px; border-radius:10px; text-decoration:none;
  font-weight:700; font-size:14px; transition:all 0.2s;
}
.btn-outline {
  border:1.5px solid var(--border); color:var(--text-muted);
}
.btn-outline:hover { border-color:var(--orange); color:var(--orange); }
.btn-filled {
  background:var(--gradient); color:#0F0F13;
  box-shadow:0 4px 16px rgba(255,107,53,0.3);
}
.btn-filled:hover { transform:translateY(-2px); box-shadow:0 8px 24px rgba(255,107,53,0.45); }

.land-hero {
  text-align:center; padding:100px 20px 60px;
  position:relative;
}
.land-hero::before {
  content:''; position:absolute; top:0; left:50%; transform:translateX(-50%);
  width:800px; height:600px;
  background:radial-gradient(ellipse, rgba(255,107,53,0.12) 0%, transparent 70%);
  pointer-events:none;
}
.hero-badge {
  display:inline-flex; align-items:center; gap:8px;
  background:var(--gradient-soft); border:1px solid var(--border);
  border-radius:100px; padding:8px 18px; font-size:13px; font-weight:700;
  color:var(--orange); margin-bottom:32px;
}
.land-hero h2 {
  font-family:'Syne',sans-serif; font-size:64px; font-weight:800;
  line-height:1.1; margin-bottom:24px; letter-spacing:-2px;
}
.land-hero h2 span {
  background:var(--gradient); -webkit-background-clip:text;
  -webkit-text-fill-color:transparent; background-clip:text;
}
.land-hero p {
  font-size:18px; color:var(--text-muted); max-width:560px;
  margin:0 auto 40px; line-height:1.7;
}
.hero-btns { display:flex; justify-content:center; gap:14px; flex-wrap:wrap; }
.hero-btns a {
  padding:16px 36px; border-radius:12px; font-weight:800;
  font-size:16px; text-decoration:none; transition:all 0.2s;
}
.hero-btns .btn-primary-lg {
  background:var(--gradient); color:#0F0F13;
  box-shadow:0 8px 32px rgba(255,107,53,0.4);
}
.hero-btns .btn-primary-lg:hover { transform:translateY(-3px); box-shadow:0 16px 40px rgba(255,107,53,0.5); }
.hero-btns .btn-secondary-lg {
  background:var(--surface); border:1.5px solid var(--border);
  color:var(--text);
}
.hero-btns .btn-secondary-lg:hover { border-color:var(--orange); color:var(--orange); }

.land-features {
  padding:80px 60px;
  display:grid; grid-template-columns:repeat(3,1fr); gap:24px;
  max-width:1200px; margin:0 auto;
}
.feature-card {
  background:var(--surface); border:1px solid var(--border);
  border-radius:20px; padding:32px; transition:all 0.3s;
}
.feature-card:hover { border-color:rgba(255,107,53,0.4); transform:translateY(-4px); box-shadow:var(--shadow-glow); }
.feature-icon {
  width:52px; height:52px; background:var(--gradient-soft);
  border:1px solid var(--border); border-radius:14px;
  display:flex; align-items:center; justify-content:center;
  font-size:24px; margin-bottom:18px;
}
.feature-card h3 { font-size:18px; font-weight:800; margin-bottom:10px; }
.feature-card p { color:var(--text-muted); font-size:14px; line-height:1.7; }

.land-stats {
  display:flex; justify-content:center; gap:60px;
  padding:60px 20px; border-top:1px solid var(--border);
  border-bottom:1px solid var(--border);
}
.stat-item { text-align:center; }
.stat-num {
  font-family:'Syne',sans-serif; font-size:40px; font-weight:800;
  background:var(--gradient); -webkit-background-clip:text;
  -webkit-text-fill-color:transparent; background-clip:text;
}
.stat-label { color:var(--text-muted); font-size:14px; margin-top:4px; }

.land-cta {
  text-align:center; padding:100px 20px;
}
.land-cta h2 {
  font-family:'Syne',sans-serif; font-size:44px; font-weight:800;
  margin-bottom:16px;
}
.land-cta p { color:var(--text-muted); font-size:16px; margin-bottom:36px; }

.land-footer {
  text-align:center; padding:24px; border-top:1px solid var(--border);
  color:var(--text-muted); font-size:13px;
}

/* ====== AUTH ====== */
.auth-page {
  min-height:100vh; overflow:auto; display:flex;
  align-items:center; justify-content:center; background:var(--bg); position:relative;
}
.auth-page::before {
  content:''; position:fixed; top:-30%; right:-20%;
  width:700px; height:700px;
  background:radial-gradient(circle, rgba(255,107,53,0.15) 0%, transparent 70%);
  pointer-events:none;
}
.auth-card {
  background:var(--surface); border:1px solid var(--border);
  border-radius:24px; padding:48px 44px; width:100%; max-width:440px;
  position:relative; z-index:1;
  box-shadow:var(--shadow-glow), 0 40px 80px rgba(0,0,0,0.5);
}
.auth-logo { text-align:center; margin-bottom:36px; }
.auth-logo .logo-icon {
  width:64px; height:64px; background:var(--gradient);
  border-radius:18px; display:inline-flex; align-items:center;
  justify-content:center; font-size:30px; margin-bottom:14px;
  box-shadow:0 8px 24px rgba(255,107,53,0.4);
}
.auth-logo h1 {
  font-family:'Syne',sans-serif; font-size:28px; font-weight:800;
  background:var(--gradient); -webkit-background-clip:text;
  -webkit-text-fill-color:transparent; background-clip:text;
}
.auth-logo p { color:var(--text-muted); font-size:14px; margin-top:4px; }
.form-group { margin-bottom:18px; }
.form-group label {
  display:block; font-size:13px; font-weight:700;
  color:var(--text-muted); text-transform:uppercase;
  letter-spacing:0.8px; margin-bottom:8px;
}
.form-group input {
  width:100%; background:var(--bg3); border:1.5px solid var(--border);
  border-radius:var(--radius-sm); padding:13px 16px;
  color:var(--text); font-family:'Nunito',sans-serif; font-size:15px;
  font-weight:500; outline:none; transition:all 0.2s;
}
.form-group input:focus { border-color:var(--orange); box-shadow:0 0 0 3px rgba(255,107,53,0.15); }
.btn-primary {
  width:100%; padding:14px; background:var(--gradient);
  border:none; border-radius:var(--radius-sm); color:#0F0F13;
  font-family:'Nunito',sans-serif; font-size:16px; font-weight:800;
  cursor:pointer; transition:all 0.2s; margin-top:8px;
}
.btn-primary:hover { transform:translateY(-2px); box-shadow:0 8px 24px rgba(255,107,53,0.45); }
.auth-footer { text-align:center; margin-top:24px; font-size:14px; color:var(--text-muted); }
.auth-footer a { color:var(--orange); font-weight:700; text-decoration:none; }
.error-msg {
  background:rgba(255,80,80,0.1); border:1px solid rgba(255,80,80,0.3);
  border-radius:var(--radius-sm); padding:12px 16px; color:#ff7070;
  font-size:14px; margin-bottom:18px; display:none;
}

/* ====== APP LAYOUT ====== */
.app-layout {
  display:grid;
  grid-template-columns:72px 300px 1fr;
  height:100vh; overflow:hidden;
}

/* ====== SIDEBAR NAV ====== */
.sidebar-nav {
  background:var(--bg2); border-right:1px solid var(--border);
  display:flex; flex-direction:column; align-items:center;
  padding:20px 0 14px; gap:6px; z-index:10;
}
.nav-logo {
  width:44px; height:44px; background:var(--gradient);
  border-radius:12px; display:flex; align-items:center;
  justify-content:center; font-size:22px; margin-bottom:16px;
  box-shadow:0 4px 16px rgba(255,107,53,0.35); cursor:pointer;
}
.nav-btn {
  width:44px; height:44px; background:transparent; border:none;
  border-radius:12px; color:var(--text-muted); font-size:20px;
  cursor:pointer; display:flex; align-items:center; justify-content:center;
  transition:all 0.2s; position:relative;
}
.nav-btn:hover { background:var(--gradient-soft); color:var(--orange); }
.nav-btn.active { background:var(--gradient); color:#0F0F13; }
.nav-btn .badge {
  position:absolute; top:4px; right:4px; background:#FF4040;
  color:white; font-size:10px; font-weight:800; width:18px; height:18px;
  border-radius:50%; display:flex; align-items:center; justify-content:center;
}
.nav-spacer { flex:1; }
.nav-avatar {
  width:40px; height:40px; border-radius:12px;
  border:2px solid var(--orange); cursor:pointer;
  object-fit:cover; transition:all 0.2s;
}
.nav-avatar:hover { border-color:var(--yellow); transform:scale(1.05); }

/* ====== PANEL ====== */
.panel {
  background:var(--bg2); border-right:1px solid var(--border);
  display:flex; flex-direction:column; overflow:hidden;
}
.panel-body { flex:1; overflow-y:auto; padding:10px; }
.tabs { display:flex; gap:2px; padding:10px 8px 0; }
.tab {
  flex:1; padding:8px 4px; background:transparent; border:none;
  border-radius:8px 8px 0 0; color:var(--text-muted);
  font-family:'Nunito',sans-serif; font-size:12px; font-weight:700;
  cursor:pointer; transition:all 0.2s; position:relative;
}
.tab.active { color:var(--orange); background:var(--gradient-soft); }
.tab.active::after {
  content:''; position:absolute; bottom:-1px; left:0; right:0;
  height:2px; background:var(--gradient); border-radius:2px 2px 0 0;
}
.search-box { position:relative; margin:10px; }
.search-box input {
  width:100%; background:var(--bg3); border:1.5px solid var(--border);
  border-radius:10px; padding:10px 14px 10px 38px;
  color:var(--text); font-family:'Nunito',sans-serif; font-size:14px;
  outline:none; transition:all 0.2s;
}
.search-box input:focus { border-color:var(--orange); }
.search-box .search-icon { position:absolute; left:12px; top:50%; transform:translateY(-50%); color:var(--text-muted); font-size:15px; }

/* ====== FRIEND ITEM ====== */
.friend-item {
  display:flex; align-items:center; gap:12px; padding:10px 12px;
  border-radius:var(--radius-sm); cursor:pointer; transition:all 0.15s;
}
.friend-item:hover { background:var(--gradient-soft); }
.friend-item.active { background:var(--gradient-soft); border:1px solid rgba(255,107,53,0.25); }
.friend-avatar-wrap { position:relative; flex-shrink:0; }
.friend-avatar {
  width:44px; height:44px; border-radius:12px; object-fit:cover;
  background:var(--bg3); border:2px solid var(--border);
}
.friend-avatar.placeholder {
  display:flex; align-items:center; justify-content:center;
  font-size:17px; font-weight:800; background:var(--gradient);
  color:#0F0F13; border:none;
}
.online-dot {
  position:absolute; bottom:-2px; right:-2px;
  width:12px; height:12px; border-radius:50%;
  border:2px solid var(--bg2); background:#4ade80;
}
.online-dot.offline { background:#555; }
.friend-info { flex:1; min-width:0; }
.friend-name { font-weight:700; font-size:14px; }
.friend-last { font-size:12px; color:var(--text-muted); white-space:nowrap; overflow:hidden; text-overflow:ellipsis; }

/* ====== ROLE TAGS ====== */
.role-tag {
  display:inline-flex; align-items:center; gap:4px;
  padding:2px 8px; border-radius:100px;
  font-size:10px; font-weight:800; letter-spacing:0.5px;
  text-transform:uppercase; margin-left:6px;
}
.role-owner { background:linear-gradient(135deg,#FFD700,#FF8C00); color:#0F0F13; }
.role-co-owner { background:linear-gradient(135deg,#C0C0C0,#808080); color:#0F0F13; }
.role-admin { background:linear-gradient(135deg,#FF6B35,#E8541E); color:#0F0F13; }
.role-member { background:rgba(255,255,255,0.08); color:var(--text-muted); }

/* ====== REQUEST ITEM ====== */
.request-item {
  display:flex; align-items:center; gap:10px; padding:12px;
  border-radius:var(--radius-sm); background:var(--gradient-soft);
  border:1px solid var(--border); margin-bottom:8px;
}
.request-actions { display:flex; gap:6px; margin-left:auto; }
.btn-accept, .btn-reject {
  padding:6px 12px; border:none; border-radius:8px;
  font-family:'Nunito',sans-serif; font-size:12px; font-weight:700; cursor:pointer; transition:all 0.2s;
}
.btn-accept { background:var(--gradient); color:#0F0F13; }
.btn-reject { background:rgba(255,80,80,0.15); color:#ff7070; border:1px solid rgba(255,80,80,0.3); }
.btn-accept:hover { box-shadow:0 4px 12px rgba(255,107,53,0.4); }

/* ====== SEARCH RESULT ====== */
.search-result-item {
  display:flex; align-items:center; gap:10px; padding:10px 12px;
  border-radius:var(--radius-sm); margin-bottom:6px; background:var(--bg3);
}
.btn-add {
  margin-left:auto; padding:6px 14px; background:var(--gradient);
  border:none; border-radius:8px; color:#0F0F13;
  font-family:'Nunito',sans-serif; font-size:12px; font-weight:800;
  cursor:pointer; transition:all 0.2s; white-space:nowrap;
}
.btn-add:hover { box-shadow:0 4px 12px rgba(255,107,53,0.4); }

/* ====== CHAT AREA ====== */
.chat-area {
  display:flex; flex-direction:column; background:var(--bg);
  position:relative; overflow:hidden;
}
.chat-area::before {
  content:''; position:absolute; inset:0;
  background:radial-gradient(ellipse at 80% 10%, rgba(255,107,53,0.05) 0%, transparent 50%),
             radial-gradient(ellipse at 20% 90%, rgba(255,217,61,0.03) 0%, transparent 50%);
  pointer-events:none;
}
.chat-header {
  padding:14px 20px; border-bottom:1px solid var(--border);
  display:flex; align-items:center; gap:12px;
  background:rgba(15,15,19,0.9); backdrop-filter:blur(10px);
  position:relative; z-index:2; flex-shrink:0;
}
.chat-header-info h3 { font-weight:800; font-size:15px; }
.chat-header-info p { font-size:12px; color:var(--text-muted); }
.chat-header-info p.online-text { color:#4ade80; }
.chat-header-info p.typing-text { color:var(--yellow); font-style:italic; }
.chat-header-actions { margin-left:auto; display:flex; gap:8px; }
.header-action-btn {
  width:36px; height:36px; background:var(--gradient-soft);
  border:1px solid var(--border); border-radius:10px;
  color:var(--text-muted); font-size:16px; cursor:pointer;
  display:flex; align-items:center; justify-content:center;
  transition:all 0.2s;
}
.header-action-btn:hover { color:var(--orange); border-color:var(--orange); }

.chat-messages {
  flex:1; overflow-y:auto; padding:20px;
  display:flex; flex-direction:column; gap:2px;
  position:relative; z-index:1;
}

/* ====== MESSAGES ====== */
.msg-group { display:flex; flex-direction:column; margin-bottom:10px; }
.msg-group.sent { align-items:flex-end; }
.msg-group.received { align-items:flex-start; }
.msg-wrapper { display:flex; align-items:flex-end; gap:8px; max-width:60%; }
.msg-group.sent .msg-wrapper { flex-direction:row-reverse; }
.msg-avatar {
  width:30px; height:30px; border-radius:8px; object-fit:cover;
  flex-shrink:0; background:var(--gradient); display:flex;
  align-items:center; justify-content:center; font-size:11px;
  font-weight:800; color:#0F0F13;
}
.msg-sender-name {
  font-size:11px; font-weight:700; color:var(--orange);
  margin-bottom:3px; padding-left:4px;
  display:flex; align-items:center; gap:4px;
}
.msg-bubble {
  padding:10px 14px; border-radius:16px;
  font-size:14px; line-height:1.5; word-break:break-word;
}
.msg-group.received .msg-bubble {
  background:var(--surface); border:1px solid var(--border);
  border-bottom-left-radius:4px; color:var(--text);
}
.msg-group.sent .msg-bubble {
  background:var(--gradient); color:#0F0F13;
  border-bottom-right-radius:4px; font-weight:600;
}
.msg-time { font-size:10px; color:var(--text-muted); margin-top:3px; padding:0 4px; }
.msg-file {
  display:flex; align-items:center; gap:10px; padding:10px 14px;
  border-radius:12px; background:var(--bg3); border:1px solid var(--border);
  text-decoration:none; color:var(--text); font-size:13px; font-weight:600; max-width:240px;
}
.msg-image { max-width:220px; border-radius:12px; cursor:pointer; display:block; }

/* ====== VOICE MESSAGE ====== */
.voice-msg {
  display:flex; align-items:center; gap:10px; padding:10px 14px;
  border-radius:14px; min-width:200px; max-width:280px;
}
.msg-group.received .voice-msg { background:var(--surface); border:1px solid var(--border); }
.msg-group.sent .voice-msg { background:var(--gradient); }
.voice-play-btn {
  width:34px; height:34px; border-radius:50%; border:none;
  background:rgba(255,255,255,0.2); color:inherit; font-size:14px;
  cursor:pointer; display:flex; align-items:center; justify-content:center;
  flex-shrink:0; transition:all 0.2s;
}
.voice-play-btn:hover { background:rgba(255,255,255,0.3); }
.voice-waveform { flex:1; display:flex; align-items:center; gap:2px; height:28px; }
.voice-bar {
  flex:1; border-radius:2px; background:rgba(255,255,255,0.4);
  transition:all 0.1s;
}
.msg-group.sent .voice-bar { background:rgba(15,15,19,0.3); }
.voice-dur { font-size:11px; font-weight:700; opacity:0.7; }

/* ====== CHAT INPUT ====== */
.chat-input-area {
  padding:12px 20px; border-top:1px solid var(--border);
  background:rgba(15,15,19,0.95); backdrop-filter:blur(10px);
  position:relative; z-index:2; flex-shrink:0;
}
.voice-recording-bar {
  display:none; align-items:center; gap:12px;
  background:rgba(255,80,80,0.1); border:1px solid rgba(255,80,80,0.3);
  border-radius:12px; padding:10px 16px; margin-bottom:8px;
}
.voice-recording-bar.active { display:flex; }
.rec-dot { width:10px; height:10px; border-radius:50%; background:#ff4040; animation:blink 1s infinite; }
@keyframes blink { 0%,100%{opacity:1} 50%{opacity:0.3} }
.rec-time { font-size:13px; font-weight:700; color:#ff7070; }
.rec-cancel { margin-left:auto; background:transparent; border:none; color:#ff7070; cursor:pointer; font-size:20px; }

.chat-input-wrap {
  display:flex; align-items:center; gap:8px; background:var(--surface);
  border:1.5px solid var(--border); border-radius:14px;
  padding:6px 6px 6px 14px; transition:border-color 0.2s;
}
.chat-input-wrap:focus-within { border-color:var(--orange); box-shadow:0 0 0 3px rgba(255,107,53,0.1); }
.chat-input-wrap input {
  flex:1; background:transparent; border:none; outline:none;
  color:var(--text); font-family:'Nunito',sans-serif; font-size:15px;
}
.chat-input-wrap input::placeholder { color:var(--text-muted); }
.input-btn {
  width:36px; height:36px; background:transparent; border:none;
  border-radius:9px; color:var(--text-muted); font-size:17px;
  cursor:pointer; display:flex; align-items:center; justify-content:center;
  transition:all 0.2s; flex-shrink:0;
}
.input-btn:hover { color:var(--orange); background:rgba(255,107,53,0.1); }
.input-btn.recording { color:#ff4040; background:rgba(255,64,64,0.15); }
.btn-send {
  width:38px; height:38px; background:var(--gradient); border:none;
  border-radius:11px; color:#0F0F13; font-size:16px; cursor:pointer;
  display:flex; align-items:center; justify-content:center;
  transition:all 0.2s; flex-shrink:0;
}
.btn-send:hover { box-shadow:0 4px 16px rgba(255,107,53,0.5); transform:scale(1.05); }

/* ====== VOICE CALL UI ====== */
.call-overlay {
  position:fixed; inset:0; background:rgba(0,0,0,0.85); backdrop-filter:blur(16px);
  z-index:500; display:none; flex-direction:column; align-items:center; justify-content:center;
}
.call-overlay.active { display:flex; }
.call-card {
  background:var(--surface); border:1px solid var(--border);
  border-radius:28px; padding:48px 40px; text-align:center;
  box-shadow:var(--shadow-glow); min-width:320px;
}
.call-avatar-big {
  width:90px; height:90px; border-radius:22px;
  background:var(--gradient); display:flex; align-items:center;
  justify-content:center; font-size:38px; font-weight:800;
  color:#0F0F13; margin:0 auto 20px;
  box-shadow:0 8px 32px rgba(255,107,53,0.4);
  animation:pulse 2s infinite;
}
@keyframes pulse {
  0%,100%{box-shadow:0 8px 32px rgba(255,107,53,0.4)}
  50%{box-shadow:0 8px 48px rgba(255,107,53,0.7)}
}
.call-name { font-size:22px; font-weight:800; margin-bottom:6px; }
.call-status { color:var(--text-muted); font-size:14px; margin-bottom:36px; }
.call-status.active-call { color:#4ade80; }
.call-btns { display:flex; justify-content:center; gap:20px; }
.call-btn {
  width:60px; height:60px; border-radius:50%; border:none;
  font-size:24px; cursor:pointer; transition:all 0.2s;
  display:flex; align-items:center; justify-content:center;
}
.call-btn.answer { background:linear-gradient(135deg,#4ade80,#22c55e); color:white; }
.call-btn.reject, .call-btn.end { background:linear-gradient(135deg,#ff4040,#cc0000); color:white; }
.call-btn.mute { background:var(--bg3); color:var(--text-muted); }
.call-btn.mute.muted { background:rgba(255,80,80,0.2); color:#ff7070; }
.call-btn:hover { transform:scale(1.1); }
.call-timer { font-size:28px; font-weight:800; font-family:'Syne',sans-serif; color:var(--orange); margin-bottom:8px; }

/* ====== GROUP VOICE ROOM ====== */
.voice-room-bar {
  display:none; align-items:center; gap:8px; padding:8px 16px;
  background:rgba(74,222,128,0.08); border-top:1px solid rgba(74,222,128,0.2);
  flex-shrink:0;
}
.voice-room-bar.active { display:flex; }
.voice-room-bar .room-label { font-size:12px; font-weight:700; color:#4ade80; }
.voice-participants { display:flex; gap:4px; flex:1; }
.voice-participant {
  width:28px; height:28px; border-radius:8px; background:var(--gradient);
  display:flex; align-items:center; justify-content:center;
  font-size:11px; font-weight:800; color:#0F0F13;
  border:2px solid transparent; transition:all 0.2s;
}
.voice-participant.speaking { border-color:#4ade80; box-shadow:0 0 8px rgba(74,222,128,0.5); }
.btn-leave-voice {
  padding:6px 14px; background:rgba(255,80,80,0.15); border:1px solid rgba(255,80,80,0.3);
  border-radius:8px; color:#ff7070; font-size:12px; font-weight:700;
  cursor:pointer; transition:all 0.2s;
}
.btn-leave-voice:hover { background:rgba(255,80,80,0.25); }
.btn-join-voice {
  padding:6px 14px; background:rgba(74,222,128,0.15); border:1px solid rgba(74,222,128,0.3);
  border-radius:8px; color:#4ade80; font-size:12px; font-weight:700;
  cursor:pointer; transition:all 0.2s;
}
.btn-join-voice:hover { background:rgba(74,222,128,0.25); }

/* ====== MODALS ====== */
.modal-overlay {
  position:fixed; inset:0; background:rgba(0,0,0,0.7);
  backdrop-filter:blur(8px); z-index:100;
  display:flex; align-items:center; justify-content:center;
  opacity:0; pointer-events:none; transition:opacity 0.2s;
}
.modal-overlay.open { opacity:1; pointer-events:all; }
.modal {
  background:var(--surface); border:1px solid var(--border);
  border-radius:24px; padding:32px; width:100%; max-width:400px;
  box-shadow:var(--shadow-glow); transform:scale(0.95); transition:transform 0.2s;
}
.modal-overlay.open .modal { transform:scale(1); }
.modal h3 {
  font-family:'Syne',sans-serif; font-size:20px; font-weight:800;
  background:var(--gradient); -webkit-background-clip:text;
  -webkit-text-fill-color:transparent; background-clip:text; margin-bottom:20px;
}
.profile-avatar-section { display:flex; align-items:center; gap:16px; margin-bottom:20px; }
.profile-avatar-big {
  width:80px; height:80px; border-radius:20px; object-fit:cover;
  border:3px solid var(--orange); cursor:pointer; transition:all 0.2s;
}
.profile-avatar-placeholder {
  width:80px; height:80px; border-radius:20px; background:var(--gradient);
  display:flex; align-items:center; justify-content:center;
  font-size:32px; font-weight:800; color:#0F0F13;
  cursor:pointer; transition:all 0.2s; flex-shrink:0;
}
.profile-username { font-size:17px; font-weight:800; }
.profile-email { font-size:13px; color:var(--text-muted); }
.btn-secondary {
  width:100%; padding:11px; background:transparent;
  border:1.5px solid var(--border); border-radius:var(--radius-sm);
  color:var(--text-muted); font-family:'Nunito',sans-serif;
  font-size:14px; font-weight:700; cursor:pointer; transition:all 0.2s; margin-top:8px;
}
.btn-secondary:hover { border-color:var(--orange); color:var(--orange); }
.btn-danger {
  width:100%; padding:11px; background:rgba(255,80,80,0.1);
  border:1.5px solid rgba(255,80,80,0.3); border-radius:var(--radius-sm);
  color:#ff7070; font-family:'Nunito',sans-serif;
  font-size:14px; font-weight:700; cursor:pointer; transition:all 0.2s; margin-top:8px;
}
.btn-danger:hover { background:rgba(255,80,80,0.2); }
.modal-input {
  width:100%; background:var(--bg3); border:1.5px solid var(--border);
  border-radius:var(--radius-sm); padding:11px 14px; color:var(--text);
  font-family:'Nunito',sans-serif; font-size:14px; outline:none;
  transition:all 0.2s; margin-bottom:10px;
}
.modal-input:focus { border-color:var(--orange); }

/* ====== MEMBER LIST ====== */
.member-item {
  display:flex; align-items:center; gap:10px; padding:10px 12px;
  border-radius:10px; background:var(--bg3); margin-bottom:6px;
}
.member-role-select {
  margin-left:auto; background:var(--bg2); border:1px solid var(--border);
  border-radius:8px; padding:4px 8px; color:var(--text-muted);
  font-family:'Nunito',sans-serif; font-size:12px; font-weight:700;
  cursor:pointer; outline:none;
}

/* ====== EMPTY / LOADING ====== */
.empty-chat {
  flex:1; display:flex; flex-direction:column;
  align-items:center; justify-content:center;
  gap:14px; color:var(--text-muted);
}
.empty-panel {
  display:flex; flex-direction:column; align-items:center;
  justify-content:center; padding:40px 20px;
  color:var(--text-muted); font-size:14px; gap:8px; opacity:0.6; text-align:center;
}
.loading { display:flex; align-items:center; justify-content:center; padding:40px; }
.spinner {
  width:28px; height:28px; border:3px solid var(--border);
  border-top-color:var(--orange); border-radius:50%; animation:spin 0.7s linear infinite;
}
@keyframes spin { to { transform:rotate(360deg); } }

/* ====== TOAST ====== */
.toast-container { position:fixed; bottom:24px; right:24px; z-index:999; display:flex; flex-direction:column; gap:8px; }
.toast {
  background:var(--surface); border:1px solid var(--border);
  border-left:3px solid var(--orange); border-radius:12px;
  padding:12px 16px; font-size:13px; font-weight:600;
  box-shadow:0 8px 24px rgba(0,0,0,0.4); max-width:280px;
  animation:slideIn 0.3s ease, fadeOut 0.3s ease 2.7s forwards;
}
@keyframes slideIn { from{opacity:0;transform:translateX(20px)} to{opacity:1;transform:translateX(0)} }
@keyframes fadeOut { to{opacity:0;transform:translateX(20px)} }

/* ====== IMAGE VIEWER ====== */
.img-viewer {
  position:fixed; inset:0; background:rgba(0,0,0,0.92);
  z-index:600; display:none; align-items:center; justify-content:center;
}
.img-viewer.open { display:flex; }
.img-viewer img { max-width:90vw; max-height:90vh; border-radius:12px; }
.img-viewer-close {
  position:absolute; top:20px; right:20px; background:rgba(255,255,255,0.1);
  border:none; border-radius:50%; width:44px; height:44px; color:white;
  font-size:22px; cursor:pointer; display:flex; align-items:center; justify-content:center;
}

/* ====== DIVIDER ====== */
.section-divider {
  font-size:11px; font-weight:800; text-transform:uppercase;
  letter-spacing:1px; color:var(--text-muted); padding:12px 12px 6px;
}

/* ====== GROUP CREATE BTN ====== */
.create-group-btn {
  display:flex; align-items:center; gap:10px; padding:10px 12px;
  border-radius:var(--radius-sm); cursor:pointer; transition:all 0.15s;
  border:1.5px dashed rgba(255,107,53,0.3); margin-bottom:8px;
  color:var(--orange); font-weight:700; font-size:13px;
}
.create-group-btn:hover { background:var(--gradient-soft); border-color:var(--orange); }