/* Polyglot Voice Design System */

:root {
  /* Colors */
  --bg-base: #07090e;
  --bg-surface: #111520;
  --bg-surface-elevated: #1a2030;
  --border-color: rgba(255, 255, 255, 0.08);
  --border-focus: rgba(79, 70, 229, 0.6);
  
  --primary: #5850ec;
  --primary-glow: rgba(88, 80, 236, 0.35);
  --accent: #a78bfa;
  --accent-glow: rgba(167, 139, 250, 0.25);
  
  --success: #10b981;
  --success-glow: rgba(16, 185, 129, 0.25);
  --danger: #f87171;
  --danger-glow: rgba(248, 113, 113, 0.35);
  
  --text-main: #f9fafb;
  --text-muted: #9ca3af;
  --text-dark: #4b5563;
  
  /* Fonts & Weights */
  --font-family: 'Outfit', -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
  
  /* Shadows & Glassmorphism */
  --glass-bg: rgba(17, 21, 32, 0.75);
  --glass-blur: blur(16px);
  --shadow-lg: 0 10px 30px -10px rgba(0, 0, 0, 0.7);
  --neon-glow: 0 0 20px rgba(88, 80, 236, 0.15);
  
  /* Borders */
  --radius-sm: 8px;
  --radius-md: 16px;
  --radius-lg: 24px;
  --radius-full: 9999px;
  
  --transition-smooth: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

/* Base resets */
* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html, body {
  width: 100%;
  height: 100%;
  background-color: var(--bg-base);
  color: var(--text-main);
  font-family: var(--font-family);
  overflow: hidden;
  -webkit-font-smoothing: antialiased;
}

/* App container */
.app-container {
  position: relative;
  width: 100%;
  height: 100%;
  max-width: 480px;
  margin: 0 auto;
  background-color: var(--bg-base);
  border-left: 1px solid var(--border-color);
  border-right: 1px solid var(--border-color);
  display: flex;
  flex-direction: column;
  box-shadow: var(--shadow-lg);
  overflow: hidden;
}

/* Screen manager */
.app-screen {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  opacity: 0;
  pointer-events: none;
  visibility: hidden;
  transition: opacity 0.4s ease, transform 0.4s cubic-bezier(0.16, 1, 0.3, 1);
  transform: scale(0.95);
  display: flex;
  flex-direction: column;
  background-color: var(--bg-base);
  z-index: 10;
}

.app-screen.active {
  opacity: 1;
  pointer-events: auto;
  visibility: visible;
  transform: scale(1);
  z-index: 20;
}

/* Buttons */
.btn {
  font-family: var(--font-family);
  font-size: 16px;
  font-weight: 600;
  padding: 14px 28px;
  border-radius: var(--radius-md);
  border: none;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  transition: var(--transition-smooth);
}

.btn-primary {
  background: linear-gradient(135deg, var(--primary), #4338ca);
  color: white;
}

.btn-primary:hover:not(:disabled) {
  transform: translateY(-2px);
  box-shadow: 0 0 20px var(--primary-glow);
  filter: brightness(1.1);
}

.btn-primary:disabled {
  opacity: 0.5;
  cursor: not-allowed;
  transform: none;
}

.btn-secondary {
  background-color: var(--bg-surface-elevated);
  color: var(--text-main);
  border: 1px solid var(--border-color);
}

.btn-secondary:hover {
  background-color: rgba(255, 255, 255, 0.08);
}

.btn-danger {
  background-color: var(--danger);
  color: white;
}

.btn-danger:hover {
  box-shadow: 0 0 15px var(--danger-glow);
  filter: brightness(1.1);
}

.btn-danger-outline {
  background: transparent;
  color: var(--danger);
  border: 1px solid rgba(248, 113, 113, 0.3);
}

.btn-danger-outline:hover {
  background-color: rgba(248, 113, 113, 0.1);
}

.btn-full {
  width: 100%;
}

.btn-glow {
  box-shadow: 0 0 15px var(--primary-glow);
}

.btn-back {
  position: absolute;
  top: 24px;
  left: 20px;
  background: transparent;
  border: none;
  color: var(--text-muted);
  cursor: pointer;
  padding: 8px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: var(--transition-smooth);
}

.btn-back:hover {
  color: var(--text-main);
  background-color: var(--border-color);
}

.icon-back {
  width: 24px;
  height: 24px;
  fill: currentColor;
}

/* Inputs */
.input-group {
  position: relative;
  width: 100%;
}

input[type="text"] {
  width: 100%;
  padding: 16px 20px;
  border-radius: var(--radius-md);
  border: 1.5px solid var(--border-color);
  background-color: var(--bg-surface);
  color: var(--text-main);
  font-family: var(--font-family);
  font-size: 18px;
  outline: none;
  transition: var(--transition-smooth);
}

input[type="text"]:focus {
  border-color: var(--primary);
  box-shadow: 0 0 12px var(--primary-glow);
}

/* Setup Layouts */
.setup-container {
  padding: 80px 24px 40px;
  display: flex;
  flex-direction: column;
  height: 100%;
}

.setup-header {
  margin-bottom: 32px;
}

.setup-step {
  font-size: 13px;
  font-weight: 700;
  text-transform: uppercase;
  color: var(--accent);
  letter-spacing: 1px;
  margin-bottom: 8px;
}

.setup-title {
  font-size: 28px;
  font-weight: 800;
  margin-bottom: 8px;
}

.setup-subtitle {
  font-size: 15px;
  color: var(--text-muted);
  line-height: 1.4;
}

.setup-body {
  flex: 1;
  display: flex;
  flex-direction: column;
  justify-content: center;
}

.setup-footer {
  margin-top: 24px;
}

.setup-footer .btn {
  width: 100%;
}

/* Splash Screen */
.splash-content {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: space-between;
  height: 100%;
  padding: 100px 32px 50px;
}

.logo-container {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
}

.logo-icon-wrapper {
  position: relative;
  width: 140px;
  height: 140px;
  margin-bottom: 24px;
}

.logo-svg {
  width: 100%;
  height: 100%;
}

.logo-bg {
  fill: var(--bg-surface);
  stroke: var(--border-color);
  stroke-width: 2;
}

.logo-waves {
  fill: none;
  stroke: var(--primary);
  stroke-width: 2.5;
  stroke-linecap: round;
  opacity: 0.7;
}

.logo-core {
  fill: var(--primary);
  filter: drop-shadow(0 0 8px var(--primary));
}

.logo-mic {
  fill: none;
  stroke: white;
  stroke-width: 3;
  stroke-linecap: round;
}

.logo-pulse {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  border-radius: 50%;
  border: 2px solid var(--primary);
  opacity: 0;
  animation: logo-pulsate 2.5s infinite;
}

@keyframes logo-pulsate {
  0% { transform: scale(1); opacity: 0; }
  50% { opacity: 0.35; }
  100% { transform: scale(1.3); opacity: 0; }
}

.app-title {
  font-size: 32px;
  font-weight: 900;
  letter-spacing: 2px;
  background: linear-gradient(135deg, var(--text-main), var(--text-muted));
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  margin-bottom: 8px;
}

.app-tagline {
  font-size: 15px;
  color: var(--text-muted);
  max-width: 260px;
  line-height: 1.4;
}

.splash-actions {
  width: 100%;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 24px;
}

.splash-actions .btn {
  width: 100%;
}

.powered-by {
  font-size: 11px;
  color: var(--text-dark);
  letter-spacing: 0.5px;
}

/* Language Selection Grid */
.language-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 12px;
  max-height: 320px;
  overflow-y: auto;
  padding-right: 4px;
}

.lang-card {
  background-color: var(--bg-surface);
  border: 1.5px solid var(--border-color);
  border-radius: var(--radius-md);
  padding: 16px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 8px;
  cursor: pointer;
  transition: var(--transition-smooth);
}

.lang-card:hover {
  border-color: var(--border-focus);
  background-color: var(--bg-surface-elevated);
}

.lang-card.selected {
  border-color: var(--primary);
  background: rgba(88, 80, 236, 0.08);
  box-shadow: 0 0 15px rgba(88, 80, 236, 0.15);
}

.lang-flag {
  font-size: 32px;
}

.lang-name {
  font-size: 15px;
  font-weight: 600;
  color: var(--text-main);
}

.lang-native {
  font-size: 12px;
  color: var(--text-muted);
}

/* Microphone Request screen */
.mic-request-body {
  align-items: center;
  text-align: center;
  gap: 24px;
  padding: 0 12px;
}

.mic-icon-wrapper {
  position: relative;
  width: 100px;
  height: 100px;
  background-color: var(--bg-surface-elevated);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--primary);
  border: 2px solid var(--border-color);
}

.mic-svg {
  width: 44px;
  height: 44px;
}

.pulse-mic {
  position: absolute;
  width: 100%;
  height: 100%;
  border-radius: 50%;
  border: 2px solid var(--primary);
  opacity: 0.3;
  animation: logo-pulsate 2s infinite;
}

.mic-privacy-notice {
  font-size: 14px;
  color: var(--text-muted);
  line-height: 1.5;
}

/* Main Room Layout */
.main-room-layout {
  display: flex;
  flex-direction: column;
  height: 100%;
  overflow: hidden;
}

/* Room Header */
.room-header {
  height: 72px;
  padding: 0 20px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  border-bottom: 1px solid var(--border-color);
  background-color: var(--bg-surface);
  z-index: 30;
}

.room-info {
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.room-title-wrapper {
  display: flex;
  align-items: center;
  gap: 8px;
}

.alliance-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background-color: var(--success);
  box-shadow: 0 0 8px var(--success);
}

.room-name {
  font-size: 18px;
  font-weight: 700;
}

.room-meta-badge {
  font-family: var(--font-family);
  background: transparent;
  border: none;
  color: var(--text-muted);
  font-size: 12px;
  display: inline-flex;
  align-items: center;
  gap: 4px;
  cursor: pointer;
}

.room-meta-badge:hover {
  color: var(--text-main);
}

.icon-users {
  width: 14px;
  height: 14px;
}

.btn-icon {
  background: transparent;
  border: none;
  color: var(--text-muted);
  cursor: pointer;
  padding: 8px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: var(--transition-smooth);
}

.btn-icon:hover {
  color: var(--text-main);
  background-color: var(--border-color);
}

.btn-icon svg {
  width: 22px;
  height: 22px;
}

/* Onboarding Banner */
.onboarding-banner {
  background: linear-gradient(90deg, rgba(88, 80, 236, 0.15) 0%, rgba(167, 139, 250, 0.1) 100%);
  border-bottom: 1px solid rgba(88, 80, 236, 0.2);
  padding: 12px 20px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  animation: slide-down 0.4s ease;
}

@keyframes slide-down {
  from { transform: translateY(-100%); }
  to { transform: translateY(0); }
}

.onboarding-banner-content {
  display: flex;
  align-items: flex-start;
  gap: 10px;
}

.banner-badge {
  background-color: var(--primary);
  color: white;
  font-size: 10px;
  font-weight: 700;
  text-transform: uppercase;
  padding: 2px 6px;
  border-radius: 4px;
  margin-top: 1px;
}

.banner-text {
  font-size: 13px;
  color: var(--text-main);
  line-height: 1.4;
}

.banner-close {
  background: transparent;
  border: none;
  color: var(--text-muted);
  font-size: 20px;
  cursor: pointer;
  padding: 0 4px;
}

.banner-close:hover {
  color: var(--text-main);
}

/* Chat Feed */
.chat-feed {
  flex: 1;
  overflow-y: auto;
  padding: 20px;
  display: flex;
  flex-direction: column;
  gap: 16px;
  background-color: var(--bg-base);
}

/* Empty Feed Placeholder */
.empty-feed-placeholder {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  height: 100%;
  color: var(--text-dark);
  text-align: center;
  gap: 12px;
}

.placeholder-icon {
  width: 80px;
  height: 80px;
  background-color: var(--bg-surface);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--text-dark);
}

.empty-feed-placeholder h3 {
  font-size: 18px;
  color: var(--text-muted);
  font-weight: 600;
}

.empty-feed-placeholder p {
  font-size: 14px;
  max-width: 220px;
  line-height: 1.4;
}

/* Message Bubble */
.msg-bubble {
  align-self: flex-start;
  max-width: 85%;
  display: flex;
  gap: 12px;
  animation: bubble-appear 0.3s cubic-bezier(0.16, 1, 0.3, 1);
}

@keyframes bubble-appear {
  from { opacity: 0; transform: translateY(10px); }
  to { opacity: 1; transform: translateY(0); }
}

.msg-bubble.self {
  align-self: flex-end;
  flex-direction: row-reverse;
}

.msg-avatar {
  width: 40px;
  height: 40px;
  border-radius: 50%;
  background-color: var(--bg-surface-elevated);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 22px;
  border: 1px solid var(--border-color);
  flex-shrink: 0;
}

.msg-content-wrapper {
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.msg-meta {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 12px;
  color: var(--text-muted);
}

.msg-bubble.self .msg-meta {
  flex-direction: row-reverse;
}

.msg-sender {
  font-weight: 600;
  color: var(--text-main);
}

.msg-time {
  font-size: 11px;
}

.msg-lang-tag {
  background-color: var(--bg-surface-elevated);
  padding: 1px 6px;
  border-radius: 4px;
  font-size: 10px;
  color: var(--accent);
}

.msg-card {
  background-color: var(--bg-surface);
  border: 1px solid var(--border-color);
  border-radius: 0 var(--radius-md) var(--radius-md) var(--radius-md);
  padding: 12px 16px;
  display: flex;
  flex-direction: column;
  gap: 8px;
  position: relative;
  transition: var(--transition-smooth);
}

.msg-bubble.self .msg-card {
  background-color: var(--bg-surface-elevated);
  border-color: rgba(88, 80, 236, 0.15);
  border-radius: var(--radius-md) 0 var(--radius-md) var(--radius-md);
}

.msg-audio-row {
  display: flex;
  align-items: center;
  gap: 12px;
  min-width: 200px;
}

.btn-play-bubble {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  background-color: var(--primary);
  border: none;
  cursor: pointer;
  color: white;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: var(--transition-smooth);
  flex-shrink: 0;
}

.btn-play-bubble:hover {
  transform: scale(1.08);
  box-shadow: 0 0 10px var(--primary-glow);
}

.btn-play-bubble svg {
  width: 18px;
  height: 18px;
  fill: currentColor;
}

.msg-waveform-canvas {
  flex: 1;
  height: 28px;
  width: 140px;
  background-color: transparent;
}

.msg-duration {
  font-size: 11px;
  color: var(--text-muted);
  font-weight: 500;
}

.msg-subtitles {
  font-size: 14px;
  line-height: 1.45;
  color: var(--text-main);
  border-top: 1px solid rgba(255, 255, 255, 0.05);
  padding-top: 8px;
}

.msg-trans-label {
  font-size: 10px;
  text-transform: uppercase;
  color: var(--text-muted);
  letter-spacing: 0.5px;
  margin-bottom: 2px;
  display: block;
}

.msg-reactions {
  display: flex;
  gap: 6px;
  margin-top: 2px;
}

.msg-bubble.self .msg-reactions {
  flex-direction: row-reverse;
}

.reaction-btn {
  background-color: var(--bg-surface);
  border: 1px solid var(--border-color);
  padding: 4px 8px;
  border-radius: var(--radius-full);
  font-size: 12px;
  color: var(--text-muted);
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 4px;
  transition: var(--transition-smooth);
}

.reaction-btn:hover {
  background-color: var(--bg-surface-elevated);
  color: var(--text-main);
}

.reaction-btn.reacted {
  background: rgba(88, 80, 236, 0.1);
  border-color: var(--primary);
  color: var(--accent);
}

/* System Message */
.msg-system {
  align-self: center;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background-color: var(--bg-surface);
  border: 1px solid var(--border-color);
  padding: 6px 14px;
  border-radius: var(--radius-full);
  font-size: 12px;
  color: var(--text-muted);
  animation: bubble-appear 0.3s ease;
}

.msg-system .sys-flag {
  font-size: 14px;
}

/* PTT Bottom Bar */
.ptt-footer {
  background-color: var(--bg-surface);
  border-top: 1px solid var(--border-color);
  padding: 16px 20px 30px;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 12px;
  position: relative;
  z-index: 30;
}

.recording-waveform-container {
  width: 100%;
  height: 40px;
  display: none;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  background-color: rgba(248, 113, 113, 0.05);
  border: 1px dashed rgba(248, 113, 113, 0.2);
  border-radius: var(--radius-md);
  padding: 0 16px;
}

.recording-waveform-container.active {
  display: flex;
}

.canvas-recording {
  flex: 1;
  height: 30px;
}

.recording-timer {
  font-size: 14px;
  font-weight: 700;
  color: var(--danger);
  font-family: monospace;
}

.ptt-actions {
  width: 100%;
  display: flex;
  justify-content: center;
}

.btn-ptt-trigger {
  position: relative;
  width: 140px;
  height: 140px;
  border-radius: 50%;
  border: none;
  background: transparent;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  outline: none;
  touch-action: none; /* Prevent browser scrolling during long-press */
  user-select: none;
  -webkit-user-select: none;
}

.ptt-inner-circle {
  width: 110px;
  height: 110px;
  border-radius: 50%;
  background: linear-gradient(135deg, var(--bg-surface-elevated) 0%, var(--bg-surface) 100%);
  border: 2px solid var(--border-color);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 6px;
  color: var(--text-muted);
  z-index: 5;
  transition: var(--transition-smooth);
  box-shadow: var(--shadow-lg);
}

.mic-ptt-icon {
  width: 28px;
  height: 28px;
  transition: var(--transition-smooth);
}

.ptt-label {
  font-size: 10px;
  font-weight: 800;
  letter-spacing: 1px;
}

.ptt-outer-ring {
  position: absolute;
  top: 10px;
  left: 10px;
  right: 10px;
  bottom: 10px;
  border-radius: 50%;
  border: 2px solid var(--primary);
  opacity: 0.3;
  z-index: 2;
  transition: var(--transition-smooth);
}

/* Press Active States */
.btn-ptt-trigger.recording .ptt-inner-circle {
  background: linear-gradient(135deg, var(--danger) 0%, #dc2626 100%);
  color: white;
  border-color: #fca5a5;
  box-shadow: 0 0 30px var(--danger-glow);
}

.btn-ptt-trigger.recording .ptt-outer-ring {
  border-color: var(--danger);
  transform: scale(1.15);
  opacity: 0.8;
}

.btn-ptt-trigger.recording .ptt-pulsing-rings {
  position: absolute;
  width: 100%;
  height: 100%;
  border-radius: 50%;
  border: 2px solid var(--danger);
  opacity: 0;
  animation: ptt-pulsate 1.5s infinite;
  z-index: 1;
}

@keyframes ptt-pulsate {
  0% { transform: scale(1); opacity: 0; }
  50% { opacity: 0.4; }
  100% { transform: scale(1.4); opacity: 0; }
}

/* Drawers & Sliding Panels */
.drawer {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  pointer-events: none;
  z-index: 100;
  visibility: hidden;
  transition: visibility 0s 0.3s;
}

.drawer.active {
  pointer-events: auto;
  visibility: visible;
  transition: visibility 0s 0s;
}

.drawer-overlay {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background-color: rgba(0, 0, 0, 0.6);
  opacity: 0;
  transition: opacity 0.3s ease;
  backdrop-filter: blur(4px);
}

.drawer.active .drawer-overlay {
  opacity: 1;
}

.drawer-content {
  position: absolute;
  top: 0;
  right: 0;
  width: 85%;
  height: 100%;
  background-color: var(--bg-surface);
  box-shadow: var(--shadow-lg);
  border-left: 1px solid var(--border-color);
  transform: translateX(100%);
  transition: transform 0.3s cubic-bezier(0.16, 1, 0.3, 1);
  display: flex;
  flex-direction: column;
}

.drawer.active .drawer-content {
  transform: translateX(0);
}

/* Drawer Bottom variant */
.drawer-content.drawer-bottom {
  top: auto;
  bottom: 0;
  right: auto;
  left: 0;
  width: 100%;
  height: auto;
  max-height: 80%;
  border-left: none;
  border-top: 1px solid var(--border-color);
  border-radius: var(--radius-lg) var(--radius-lg) 0 0;
  transform: translateY(100%);
}

.drawer.active .drawer-content.drawer-bottom {
  transform: translateY(0);
}

.drawer-header {
  height: 64px;
  padding: 0 20px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  border-bottom: 1px solid var(--border-color);
}

.drawer-header h3 {
  font-size: 18px;
  font-weight: 700;
}

.btn-close-drawer, .btn-close-modal {
  background: transparent;
  border: none;
  color: var(--text-muted);
  font-size: 26px;
  cursor: pointer;
  line-height: 1;
}

.btn-close-drawer:hover, .btn-close-modal:hover {
  color: var(--text-main);
}

.drawer-body {
  flex: 1;
  overflow-y: auto;
  padding: 20px;
}

/* Tabs */
.drawer-tabs {
  display: flex;
  border-bottom: 1px solid var(--border-color);
}

.tab-btn {
  flex: 1;
  background: transparent;
  border: none;
  color: var(--text-muted);
  font-family: var(--font-family);
  font-size: 14px;
  font-weight: 600;
  padding: 12px 0;
  cursor: pointer;
  border-bottom: 2px solid transparent;
  transition: var(--transition-smooth);
}

.tab-btn.active {
  color: var(--primary);
  border-bottom-color: var(--primary);
}

.tab-content {
  display: none;
  padding-top: 16px;
}

.tab-content.active {
  display: block;
}

/* Member list styling */
.member-list {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.roster-desc {
  font-size: 12px;
  color: var(--text-muted);
  margin-bottom: 16px;
}

.member-item {
  display: flex;
  align-items: center;
  justify-content: space-between;
  background-color: var(--bg-base);
  border: 1px solid var(--border-color);
  padding: 12px 16px;
  border-radius: var(--radius-md);
}

.member-info {
  display: flex;
  align-items: center;
  gap: 12px;
}

.member-flag {
  font-size: 24px;
}

.member-name {
  font-size: 15px;
  font-weight: 600;
}

.member-lang-badge {
  font-size: 11px;
  color: var(--text-muted);
}

.member-status {
  display: flex;
  align-items: center;
  gap: 6px;
}

.status-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background-color: var(--text-dark);
}

.status-dot.online {
  background-color: var(--success);
  box-shadow: 0 0 6px var(--success);
}

.status-text {
  font-size: 11px;
  color: var(--text-muted);
  font-weight: 500;
}

/* Settings elements */
.settings-group {
  margin-bottom: 24px;
}

.setting-label {
  font-size: 15px;
  font-weight: 700;
  margin-bottom: 4px;
  display: block;
}

.setting-desc {
  font-size: 12px;
  color: var(--text-muted);
  margin-bottom: 12px;
  line-height: 1.4;
}

.setting-toggle-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
}

.setting-toggle-row .setting-desc {
  margin-bottom: 0;
}

/* Toggle Switch */
.switch {
  position: relative;
  display: inline-block;
  width: 48px;
  height: 26px;
  flex-shrink: 0;
}

.switch input {
  opacity: 0;
  width: 0;
  height: 0;
}

.slider {
  position: absolute;
  cursor: pointer;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background-color: var(--bg-surface-elevated);
  border: 1px solid var(--border-color);
  transition: .4s;
}

.slider:before {
  position: absolute;
  content: "";
  height: 18px;
  width: 18px;
  left: 3px;
  bottom: 3px;
  background-color: var(--text-muted);
  transition: .4s;
}

input:checked + .slider {
  background-color: var(--primary);
  border-color: var(--primary);
}

input:checked + .slider:before {
  transform: translateX(22px);
  background-color: white;
}

.slider.round {
  border-radius: 34px;
}

.slider.round:before {
  border-radius: 50%;
}

.speed-btns {
  display: flex;
  gap: 8px;
}

.btn-speed {
  flex: 1;
  background-color: var(--bg-surface-elevated);
  border: 1px solid var(--border-color);
  color: var(--text-muted);
  padding: 8px 0;
  border-radius: var(--radius-sm);
  font-family: var(--font-family);
  font-weight: 600;
  font-size: 13px;
  cursor: pointer;
  transition: var(--transition-smooth);
}

.btn-speed.active, .btn-speed:hover {
  background-color: var(--primary);
  color: white;
  border-color: var(--primary);
}

.mt-10 { margin-top: 10px; }

/* Now Playing Screen Elements */
.np-audio-player {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  background-color: var(--bg-base);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-md);
  padding: 24px;
  margin-bottom: 20px;
}

.np-avatar-wrapper {
  position: relative;
  width: 72px;
  height: 72px;
  margin-bottom: 12px;
}

.np-avatar {
  width: 100%;
  height: 100%;
  border-radius: 50%;
  background-color: var(--bg-surface-elevated);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 40px;
  border: 1.5px solid var(--border-color);
}

.np-waves-animation {
  position: absolute;
  top: -8px;
  left: -8px;
  width: 88px;
  height: 88px;
  border-radius: 50%;
  border: 1.5px solid var(--primary);
  opacity: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 3px;
}

.np-waves-animation.active {
  animation: logo-pulsate 1.8s infinite;
}

.np-meta h4 {
  font-size: 18px;
  font-weight: 700;
  margin-bottom: 2px;
}

.np-meta p {
  font-size: 11px;
  color: var(--text-muted);
  margin-bottom: 16px;
}

.np-controls {
  margin-bottom: 16px;
}

.btn-play-large {
  width: 54px;
  height: 54px;
  border-radius: 50%;
  background-color: var(--primary);
  border: none;
  cursor: pointer;
  color: white;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 0 15px var(--primary-glow);
  transition: var(--transition-smooth);
}

.btn-play-large:hover {
  transform: scale(1.08);
}

.btn-play-large svg {
  width: 26px;
  height: 26px;
}

.np-progress-bar-container {
  width: 100%;
  display: flex;
  align-items: center;
  gap: 10px;
}

.np-time-curr, .np-time-tot {
  font-size: 11px;
  font-family: monospace;
  color: var(--text-muted);
}

.np-progress-track {
  flex: 1;
  height: 4px;
  background-color: var(--bg-surface-elevated);
  border-radius: var(--radius-full);
  cursor: pointer;
  position: relative;
}

.np-progress-fill {
  width: 0%;
  height: 100%;
  background-color: var(--primary);
  border-radius: var(--radius-full);
}

.np-text-section {
  background-color: var(--bg-base);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-md);
  padding: 16px;
  margin-bottom: 16px;
}

.np-text-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 11px;
  font-weight: 700;
  text-transform: uppercase;
  color: var(--text-muted);
  letter-spacing: 0.5px;
  margin-bottom: 8px;
}

.np-badge {
  background-color: var(--primary-glow);
  color: var(--accent);
  padding: 2px 6px;
  border-radius: 4px;
  font-size: 10px;
}

.np-badge.badge-dark {
  background-color: var(--bg-surface-elevated);
  color: var(--text-muted);
}

.np-transcript-text {
  font-size: 15px;
  line-height: 1.5;
}

.np-actions-row {
  margin-top: 10px;
}

/* Modals */
.modal {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  z-index: 200;
  display: flex;
  align-items: center;
  justify-content: center;
  pointer-events: none;
  visibility: hidden;
  transition: visibility 0s 0.3s;
}

.modal.active {
  pointer-events: auto;
  visibility: visible;
  transition: visibility 0s 0s;
}

.modal-overlay {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background-color: rgba(0, 0, 0, 0.7);
  opacity: 0;
  transition: opacity 0.3s ease;
  backdrop-filter: blur(4px);
}

.modal.active .modal-overlay {
  opacity: 1;
}

.modal-content {
  position: relative;
  width: 90%;
  max-height: 85%;
  background-color: var(--bg-surface);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-lg);
  display: flex;
  flex-direction: column;
  transform: scale(0.9);
  opacity: 0;
  transition: transform 0.3s cubic-bezier(0.16, 1, 0.3, 1), opacity 0.3s ease;
  z-index: 10;
}

.modal.active .modal-content {
  transform: scale(1);
  opacity: 1;
}

.modal-header {
  height: 60px;
  padding: 0 20px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  border-bottom: 1px solid var(--border-color);
}

.modal-body {
  flex: 1;
  overflow-y: auto;
  padding: 20px;
}

/* Side by Side Comparison */
.transcript-comparison {
  display: flex;
  flex-direction: column;
  gap: 20px;
}

.transcript-column {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.transcript-column h4 {
  font-size: 14px;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.transcript-column .badge {
  font-size: 11px;
  background-color: var(--bg-surface-elevated);
  padding: 2px 6px;
  border-radius: 4px;
  color: var(--text-muted);
}

.transcript-column .badge.badge-accent {
  background-color: var(--primary-glow);
  color: var(--accent);
}

.transcript-box {
  background-color: var(--bg-base);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-md);
  padding: 14px;
  font-size: 14px;
  line-height: 1.5;
  min-height: 80px;
  white-space: pre-wrap;
}

.btn-small {
  align-self: flex-end;
  font-size: 12px;
  padding: 8px 16px;
  border-radius: var(--radius-sm);
}

.btn-accent {
  background: var(--primary);
  color: white;
}

.btn-accent:hover {
  filter: brightness(1.1);
}

/* Hide scrollbars for slick look */
.chat-feed::-webkit-scrollbar,
.drawer-body::-webkit-scrollbar,
.language-grid::-webkit-scrollbar {
  width: 4px;
}

.chat-feed::-webkit-scrollbar-track,
.drawer-body::-webkit-scrollbar-track,
.language-grid::-webkit-scrollbar-track {
  background: transparent;
}

.chat-feed::-webkit-scrollbar-thumb,
.drawer-body::-webkit-scrollbar-thumb,
.language-grid::-webkit-scrollbar-thumb {
  background: var(--border-color);
  border-radius: 2px;
}

/* React Animation effects */
.reactions-wrapper {
  display: flex;
  gap: 6px;
}
