/* ============================================
   MODERN DESIGN SYSTEM - CSS VARIABLES
   ============================================ */

:root {
  /* Color Palette - Primary */
  --color-primary-50: #eff6ff;
  --color-primary-100: #dbeafe;
  --color-primary-200: #bfdbfe;
  --color-primary-300: #93c5fd;
  --color-primary-400: #60a5fa;
  --color-primary-500: #3b82f6;
  --color-primary-600: #2563eb;
  --color-primary-700: #1d4ed8;
  --color-primary-800: #1e40af;
  --color-primary-900: #1e3a8a;

  /* Color Palette - Accent (Purple) */
  --color-accent-50: #faf5ff;
  --color-accent-100: #f3e8ff;
  --color-accent-200: #e9d5ff;
  --color-accent-300: #d8b4fe;
  --color-accent-400: #c084fc;
  --color-accent-500: #a855f7;
  --color-accent-600: #9333ea;
  --color-accent-700: #7e22ce;
  --color-accent-800: #6b21a8;
  --color-accent-900: #581c87;

  /* Neutral Colors */
  --color-gray-50: #f8fafc;
  --color-gray-100: #f1f5f9;
  --color-gray-200: #e2e8f0;
  --color-gray-300: #cbd5e1;
  --color-gray-400: #94a3b8;
  --color-gray-500: #64748b;
  --color-gray-600: #475569;
  --color-gray-700: #334155;
  --color-gray-800: #1e293b;
  --color-gray-900: #0f172a;

  /* Semantic Colors */
  --color-success: #10b981;
  --color-warning: #f59e0b;
  --color-error: #ef4444;
  --color-info: #3b82f6;

  /* Enhanced Gradients */
  --gradient-primary: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
  --gradient-accent: linear-gradient(135deg, #f093fb 0%, #f5576c 100%);
  --gradient-blue-purple: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
  --gradient-ocean: linear-gradient(135deg, #2e3192 0%, #1bffff 100%);
  --gradient-sunset: linear-gradient(135deg, #fa709a 0%, #fee140 100%);
  --gradient-neon: linear-gradient(135deg, #00f5a0 0%, #00d9f5 100%);
  --gradient-fire: linear-gradient(135deg, #ff6b6b 0%, #feca57 100%);
  --gradient-background: linear-gradient(
    135deg,
    #667eea 0%,
    #764ba2 50%,
    #f093fb 100%
  );
  --gradient-mesh:
    radial-gradient(at 0% 0%, rgba(102, 126, 234, 0.3) 0px, transparent 50%),
    radial-gradient(at 100% 0%, rgba(118, 75, 162, 0.3) 0px, transparent 50%),
    radial-gradient(
      at 100% 100%,
      rgba(240, 147, 251, 0.3) 0px,
      transparent 50%
    ),
    radial-gradient(at 0% 100%, rgba(102, 126, 234, 0.3) 0px, transparent 50%);

  /* Spacing Scale (4px base) */
  --space-1: 4px;
  --space-2: 8px;
  --space-3: 12px;
  --space-4: 16px;
  --space-5: 20px;
  --space-6: 24px;
  --space-8: 32px;
  --space-10: 40px;
  --space-12: 48px;
  --space-16: 64px;
  --space-20: 80px;

  /* Typography */
  --font-family-base: "Inter", system-ui, -apple-system, sans-serif;
  --font-size-xs: 12px;
  --font-size-sm: 14px;
  --font-size-base: 16px;
  --font-size-lg: 18px;
  --font-size-xl: 20px;
  --font-size-2xl: 24px;
  --font-size-3xl: 30px;
  --font-size-4xl: 36px;

  --font-weight-normal: 400;
  --font-weight-medium: 500;
  --font-weight-semibold: 600;
  --font-weight-bold: 700;
  --font-weight-extrabold: 800;

  --line-height-tight: 1.25;
  --line-height-normal: 1.5;
  --line-height-relaxed: 1.75;

  /* Border Radius */
  --radius-sm: 6px;
  --radius-md: 8px;
  --radius-lg: 12px;
  --radius-xl: 16px;
  --radius-2xl: 20px;
  --radius-full: 9999px;

  /* Enhanced Shadows with Color */
  --shadow-sm: 0 1px 2px 0 rgba(0, 0, 0, 0.05);
  --shadow-md:
    0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -1px rgba(0, 0, 0, 0.06);
  --shadow-lg:
    0 10px 15px -3px rgba(0, 0, 0, 0.1), 0 4px 6px -2px rgba(0, 0, 0, 0.05);
  --shadow-xl:
    0 20px 25px -5px rgba(0, 0, 0, 0.1), 0 10px 10px -5px rgba(0, 0, 0, 0.04);
  --shadow-2xl: 0 25px 50px -12px rgba(0, 0, 0, 0.25);
  --shadow-colored: 0 10px 30px -5px rgba(102, 126, 234, 0.4);
  --shadow-colored-hover: 0 20px 40px -5px rgba(102, 126, 234, 0.6);
  --shadow-glow: 0 0 20px rgba(102, 126, 234, 0.3);
  --shadow-inner: inset 0 2px 4px 0 rgba(0, 0, 0, 0.05);

  /* Transitions */
  --transition-fast: 150ms cubic-bezier(0.4, 0, 0.2, 1);
  --transition-base: 250ms cubic-bezier(0.4, 0, 0.2, 1);
  --transition-slow: 350ms cubic-bezier(0.4, 0, 0.2, 1);
  --transition-bounce: 500ms cubic-bezier(0.68, -0.55, 0.265, 1.55);
  --transition-smooth: 400ms cubic-bezier(0.22, 1, 0.36, 1);

  /* Z-Index Scale */
  --z-base: 1;
  --z-dropdown: 100;
  --z-sticky: 200;
  --z-fixed: 300;
  --z-modal-backdrop: 400;
  --z-modal: 500;
  --z-popover: 600;
  --z-tooltip: 700;
}

/* ============================================
     GLOBAL STYLES
     ============================================ */

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

html {
  font-size: 16px;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  scroll-behavior: smooth;
}

body {
  font-family: var(--font-family-base);
  line-height: var(--line-height-normal);
  color: var(--color-gray-900);
  height: 100%;
  width: 100%;
  overflow: hidden;
}

::selection {
  background: var(--color-primary-200);
  color: var(--color-primary-900);
}

/* ============================================
     ANIMATIONS & KEYFRAMES
     ============================================ */

@keyframes gradient-shift {
  0% {
    background-position: 0% 50%;
  }
  50% {
    background-position: 100% 50%;
  }
  100% {
    background-position: 0% 50%;
  }
}

@keyframes fade-in-up {
  from {
    opacity: 0;
    transform: translateY(20px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@keyframes scale-in {
  from {
    opacity: 0;
    transform: scale(0.9);
  }
  to {
    opacity: 1;
    transform: scale(1);
  }
}

@keyframes shimmer {
  0% {
    background-position: -1000px 0;
  }
  100% {
    background-position: 1000px 0;
  }
}

@keyframes float {
  0%,
  100% {
    transform: translateY(0px);
  }
  50% {
    transform: translateY(-20px);
  }
}

@keyframes rotate {
  from {
    transform: rotate(0deg);
  }
  to {
    transform: rotate(360deg);
  }
}

@keyframes pulse-glow {
  0%,
  100% {
    box-shadow: 0 0 20px rgba(102, 126, 234, 0.3);
  }
  50% {
    box-shadow: 0 0 40px rgba(102, 126, 234, 0.6);
  }
}

@keyframes slide-in-right {
  from {
    opacity: 0;
    transform: translateX(20px);
  }
  to {
    opacity: 1;
    transform: translateX(0);
  }
}

/* ============================================
     VIEW CONTAINERS
     ============================================ */

.view-container {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: var(--color-gray-50);
  transition: opacity var(--transition-base);
}

.view-container.hidden {
  display: none !important;
  opacity: 0;
  pointer-events: none;
}

/* ============================================
     LOGIN VIEW - ENHANCED DESIGN
     ============================================ */

#login-view {
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 2000;
  background: var(--gradient-background);
  background-size: 400% 400%;
  animation: gradient-shift 20s ease infinite;
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  overflow: hidden;
}

#login-view::before {
  content: "";
  position: absolute;
  top: -50%;
  left: -50%;
  width: 200%;
  height: 200%;
  background: radial-gradient(
    circle,
    rgba(255, 255, 255, 0.08) 1px,
    transparent 1px
  );
  background-size: 50px 50px;
  animation: shimmer 30s linear infinite;
  pointer-events: none;
}

#login-view::after {
  content: "";
  position: absolute;
  inset: 0;
  background: var(--gradient-mesh);
  opacity: 0.5;
  pointer-events: none;
  animation: gradient-shift 15s ease infinite;
}

.login-box {
  background: rgba(255, 255, 255, 0.1);
  backdrop-filter: blur(30px) saturate(180%);
  -webkit-backdrop-filter: blur(30px) saturate(180%);
  padding: var(--space-10);
  border-radius: var(--radius-2xl);
  box-shadow:
    0 8px 32px 0 rgba(31, 38, 135, 0.37),
    inset 0 0 0 1px rgba(255, 255, 255, 0.18);
  text-align: center;
  max-width: 420px;
  width: 90%;
  border: 1px solid rgba(255, 255, 255, 0.18);
  animation: scale-in var(--transition-slow) var(--transition-bounce);
  position: relative;
  z-index: 1;
}

.login-box::before {
  content: "";
  position: absolute;
  inset: -2px;
  border-radius: var(--radius-2xl);
  background: linear-gradient(
    135deg,
    rgba(255, 255, 255, 0.4),
    rgba(255, 255, 255, 0.1)
  );
  z-index: -1;
  opacity: 0;
  transition: opacity var(--transition-base);
}

.login-box:hover::before {
  opacity: 1;
}

.login-box h1 {
  font-size: var(--font-size-3xl);
  font-weight: var(--font-weight-extrabold);
  margin-bottom: var(--space-6);
  background: linear-gradient(135deg, #fff 0%, rgba(255, 255, 255, 0.8) 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  letter-spacing: -1px;
  text-shadow: 0 2px 20px rgba(255, 255, 255, 0.3);
  animation: float 6s ease-in-out infinite;
}

.auth-actions {
  display: flex;
  flex-direction: column;
  gap: var(--space-3);
}

.divider {
  margin: var(--space-6) 0;
  color: rgba(255, 255, 255, 0.7);
  font-size: var(--font-size-xs);
  font-weight: var(--font-weight-semibold);
  text-transform: uppercase;
  letter-spacing: 2px;
  position: relative;
}

.divider::before,
.divider::after {
  content: "";
  position: absolute;
  top: 50%;
  width: 40%;
  height: 1px;
  background: linear-gradient(
    to right,
    transparent,
    rgba(255, 255, 255, 0.3),
    transparent
  );
}

.divider::before {
  left: 0;
}

.divider::after {
  right: 0;
}

#dev-login-block {
  display: flex;
  flex-direction: column;
  gap: var(--space-3);
}

/* ============================================
     APP VIEW LAYOUT
     ============================================ */

#app-view {
  display: flex;
  flex-direction: row;
}

/* ============================================
     SIDEBAR - ENHANCED DESIGN
     ============================================ */

#sidebar {
  width: 380px;
  background: rgba(255, 255, 255, 0.95);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border-right: 1px solid rgba(0, 0, 0, 0.05);
  display: flex;
  flex-direction: row;
  z-index: var(--z-dropdown);
  transition:
    width var(--transition-base),
    box-shadow var(--transition-base);
  flex-shrink: 0;
  overflow: hidden;
  box-shadow: 4px 0 24px rgba(0, 0, 0, 0.04);
}

#sidebar.collapsed {
  width: 0;
  border: none;
  box-shadow: none;
}

/* Sidebar Nav Rail */
.sidebar-nav {
  width: 60px;
  background: linear-gradient(to bottom, var(--color-gray-50), white);
  border-right: 1px solid var(--color-gray-200);
  display: flex;
  flex-direction: column;
  align-items: center;
  padding-top: var(--space-4);
  gap: var(--space-3);
  flex-shrink: 0;
  position: relative;
}

.sidebar-nav::after {
  content: "";
  position: absolute;
  top: 0;
  right: 0;
  width: 1px;
  height: 100%;
  background: linear-gradient(
    to bottom,
    transparent,
    var(--color-gray-200),
    transparent
  );
}

.nav-icon {
  background: transparent;
  border: none;
  font-size: 24px;
  width: 44px;
  height: 44px;
  border-radius: var(--radius-lg);
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 0;
  transition: all var(--transition-base);
  color: var(--color-gray-500);
  position: relative;
  overflow: hidden;
}

.nav-icon::before {
  content: "";
  position: absolute;
  inset: 0;
  border-radius: var(--radius-lg);
  background: var(--gradient-blue-purple);
  opacity: 0;
  transition: opacity var(--transition-base);
  z-index: 0;
}

.nav-icon::after {
  content: "";
  position: absolute;
  inset: 0;
  border-radius: var(--radius-lg);
  background: radial-gradient(
    circle at center,
    rgba(255, 255, 255, 0.8) 0%,
    transparent 70%
  );
  opacity: 0;
  transform: scale(0);
  transition: all var(--transition-base);
}

.nav-icon .nav-icon-svg {
  position: relative;
  z-index: 1;
  transition: transform var(--transition-base);
}

.nav-icon .nav-icon-svg {
  width: 26px;
  height: 26px;
  display: block;
}

.nav-icon:hover {
  background: var(--color-gray-100);
  transform: translateY(-2px) scale(1.05);
  color: var(--color-gray-700);
  box-shadow: var(--shadow-md);
}

.nav-icon:hover::after {
  opacity: 1;
  transform: scale(1);
}

.nav-icon:active .nav-icon-svg {
  transform: scale(0.95);
}

.nav-icon.active {
  color: white;
  box-shadow: var(--shadow-colored);
}

.nav-icon.active::before {
  opacity: 1;
}

.nav-icon.active:hover {
  transform: translateY(-2px) scale(1.05);
  box-shadow: var(--shadow-colored-hover);
}

.sidebar-content-wrapper {
  flex: 1;
  display: flex;
  flex-direction: column;
  overflow: hidden;
}

.sidebar-header {
  padding: var(--space-4);
  border-bottom: 1px solid var(--color-gray-100);
  display: flex;
  justify-content: space-between;
  align-items: center;
  background: linear-gradient(
    to bottom,
    rgba(255, 255, 255, 0.8),
    rgba(248, 250, 252, 0.8)
  );
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
}

.sidebar-header h2 {
  font-size: var(--font-size-lg);
  font-weight: var(--font-weight-semibold);
  margin: 0;
  color: var(--color-gray-800);
  background: var(--gradient-blue-purple);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.sidebar-content {
  flex: 1;
  overflow-y: auto;
  padding: var(--space-4);
  display: flex;
  flex-direction: column;
  gap: var(--space-6);
}

/* Enhanced Scrollbar */
.sidebar-content::-webkit-scrollbar {
  width: 8px;
}

.sidebar-content::-webkit-scrollbar-track {
  background: transparent;
}

.sidebar-content::-webkit-scrollbar-thumb {
  background: linear-gradient(
    to bottom,
    var(--color-primary-300),
    var(--color-accent-300)
  );
  border-radius: var(--radius-full);
  transition: background var(--transition-base);
}

.sidebar-content::-webkit-scrollbar-thumb:hover {
  background: linear-gradient(
    to bottom,
    var(--color-primary-400),
    var(--color-accent-400)
  );
}

/* ============================================
     PANEL SECTIONS
     ============================================ */

.panel-section {
  display: flex;
  flex-direction: column;
  gap: var(--space-4);
  animation: fade-in-up var(--transition-base);
}

.panel-section.hidden {
  display: none;
}

.panel-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: var(--space-2);
}

.panel-header h3 {
  font-size: var(--font-size-xs);
  color: var(--color-gray-500);
  text-transform: uppercase;
  font-weight: var(--font-weight-bold);
  letter-spacing: 1.5px;
}

.section-title {
  font-size: var(--font-size-sm);
  font-weight: var(--font-weight-semibold);
  color: var(--color-gray-700);
  margin-bottom: var(--space-2);
}

.spacer {
  height: var(--space-4);
}

/* ============================================
     MAIN CONTENT AREA
     ============================================ */

#main-content {
  flex: 1;
  position: relative;
  display: flex;
  flex-direction: column;
  overflow: hidden;
  background: linear-gradient(to bottom, var(--color-gray-50), white);
}

#map {
  width: 100%;
  height: 100%;
  border-radius: var(--radius-lg);
  overflow: hidden;
}

/* ============================================
     BUTTONS - ENHANCED DESIGN
     ============================================ */

button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background: var(--gradient-blue-purple);
  color: white;
  border: none;
  border-radius: var(--radius-md);
  padding: var(--space-3) var(--space-4);
  cursor: pointer;
  font-weight: var(--font-weight-semibold);
  font-size: var(--font-size-sm);
  transition: all var(--transition-base);
  position: relative;
  overflow: hidden;
  box-shadow: var(--shadow-md);
  font-family: var(--font-family-base);
}

button::before {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(
    135deg,
    rgba(255, 255, 255, 0.3) 0%,
    transparent 100%
  );
  opacity: 0;
  transition: opacity var(--transition-base);
}

button::after {
  content: "";
  position: absolute;
  top: 50%;
  left: 50%;
  width: 0;
  height: 0;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.5);
  transform: translate(-50%, -50%);
  transition:
    width var(--transition-base),
    height var(--transition-base);
}

button:hover {
  transform: translateY(-2px) scale(1.02);
  box-shadow: var(--shadow-colored-hover);
}

button:hover::before {
  opacity: 1;
}

button:active {
  transform: translateY(0) scale(0.98);
}

button:active::after {
  width: 200px;
  height: 200px;
}

button.secondary {
  background: white;
  color: var(--color-gray-700);
  box-shadow: var(--shadow-sm);
  border: 1px solid var(--color-gray-200);
}

button.secondary:hover {
  background: var(--color-gray-50);
  box-shadow: var(--shadow-md);
  border-color: var(--color-gray-300);
}

button.icon-btn {
  background: transparent;
  color: var(--color-gray-500);
  padding: var(--space-2);
  font-size: 24px;
  box-shadow: none;
  border-radius: var(--radius-md);
  transition: all var(--transition-fast);
}

button.icon-btn#refresh-suggestions-btn {
  color: rgba(255, 255, 255, 0.92);
  background: rgba(255, 255, 255, 0.1);
  border: 1px solid rgba(255, 255, 255, 0.18);
}

button.icon-btn#refresh-suggestions-btn:hover {
  background: rgba(255, 255, 255, 0.16);
  color: rgba(255, 255, 255, 1);
}

button.icon-btn#refresh-suggestions-btn:focus-visible {
  outline: 3px solid rgba(255, 255, 255, 0.35);
  outline-offset: 2px;
}

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

button.icon-btn::before,
button.icon-btn::after {
  display: none;
}

button.icon-btn:hover {
  background: var(--color-gray-100);
  color: var(--color-gray-700);
  transform: rotate(5deg) scale(1.1);
  box-shadow: none;
}

button.icon-btn:active {
  transform: rotate(-5deg) scale(1);
}

button.small {
  padding: var(--space-2) var(--space-3);
  font-size: var(--font-size-xs);
}

/* ============================================
     FORM INPUTS - ENHANCED DESIGN
     ============================================ */

input {
  width: 100%;
  padding: var(--space-3);
  margin-top: var(--space-2);
  border: 2px solid rgba(255, 255, 255, 0.3);
  border-radius: var(--radius-md);
  font-size: var(--font-size-sm);
  font-family: var(--font-family-base);
  transition: all var(--transition-base);
  background: rgba(255, 255, 255, 0.9);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  color: var(--color-gray-900);
  box-shadow: var(--shadow-inner);
}

input::placeholder {
  color: var(--color-gray-500);
}

input:focus {
  outline: none;
  border-color: rgba(255, 255, 255, 0.6);
  box-shadow:
    0 0 0 3px rgba(255, 255, 255, 0.2),
    var(--shadow-inner);
  transform: translateY(-1px);
  background: rgba(255, 255, 255, 1);
}

input:hover {
  border-color: rgba(255, 255, 255, 0.4);
}

/* ============================================
     TOGGLES & CHECKBOXES
     ============================================ */

.toggle {
  display: flex;
  align-items: center;
  gap: var(--space-2);
  font-weight: var(--font-weight-medium);
  color: var(--color-gray-700);
  cursor: pointer;
  user-select: none;
  transition: color var(--transition-base);
}

.toggle:hover {
  color: var(--color-gray-900);
}

.toggle input[type="checkbox"] {
  width: 20px;
  height: 20px;
  margin: 0;
  cursor: pointer;
  accent-color: var(--color-primary-600);
  transition: transform var(--transition-fast);
}

.toggle input[type="checkbox"]:hover {
  transform: scale(1.1);
}

.location-controls {
  display: flex;
  flex-direction: column;
  gap: var(--space-3);
  margin-top: var(--space-3);
}

#simulate-inputs {
  display: flex;
  flex-direction: column;
  gap: var(--space-2);
  margin-top: var(--space-2);
}

#simulate-inputs.hidden {
  display: none;
}

/* ============================================
     CARDS - ENHANCED DESIGN
     ============================================ */

#users-list,
#suggestions-list {
  display: flex;
  flex-direction: column;
  gap: var(--space-3);
}

.user-card,
.suggestion-card {
  border: 1px solid var(--color-gray-200);
  border-radius: var(--radius-lg);
  padding: var(--space-4);
  background: white;
  display: flex;
  flex-direction: column;
  gap: var(--space-2);
  transition: all var(--transition-smooth);
  position: relative;
  overflow: hidden;
  animation: slide-in-right var(--transition-base);
}

.user-card::before,
.suggestion-card::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 3px;
  background: var(--gradient-blue-purple);
  opacity: 0;
  transition: opacity var(--transition-base);
}

.user-card::after,
.suggestion-card::after {
  content: "";
  position: absolute;
  inset: -2px;
  border-radius: var(--radius-lg);
  background: var(--gradient-blue-purple);
  opacity: 0;
  z-index: -1;
  transition: opacity var(--transition-base);
}

.user-card:hover,
.suggestion-card:hover {
  transform: translateY(-6px) scale(1.02);
  box-shadow: var(--shadow-xl);
  border-color: transparent;
}

.user-card:hover::before,
.suggestion-card:hover::before {
  opacity: 1;
}

.user-card:hover::after,
.suggestion-card:hover::after {
  opacity: 0.1;
}

.user-card strong,
.suggestion-card strong {
  font-weight: var(--font-weight-semibold);
  color: var(--color-gray-800);
  background: var(--gradient-blue-purple);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.muted {
  color: var(--color-gray-400);
  font-size: var(--font-size-xs);
}

.actions {
  display: flex;
  gap: var(--space-2);
  margin-top: var(--space-2);
}

/* ============================================
     DESKTOP FAB (Floating Action Button)
     ============================================ */

.desktop-fab {
  position: absolute;
  top: var(--space-4);
  left: var(--space-4);
  z-index: 2000;
  background: rgba(255, 255, 255, 0.95);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  box-shadow: var(--shadow-lg);
  width: 48px;
  height: 48px;
  border-radius: var(--radius-lg);
  font-size: 20px;
  transition: all var(--transition-base);
  border: 1px solid rgba(255, 255, 255, 0.3);
}

.desktop-fab.hidden {
  display: none !important;
}

.desktop-fab:hover {
  background: white;
  transform: scale(1.1) rotate(5deg);
  box-shadow: var(--shadow-xl);
}

/* ============================================
     UTILITY CLASSES
     ============================================ */

.mobile-only {
  display: none !important;
}

.desktop-only-flex {
  display: flex !important;
}

.hidden {
  display: none !important;
}

#bottom-nav {
  display: none;
}

#mobile-sheet-overlay {
  display: none;
}

#user-info {
  font-size: var(--font-size-sm);
  color: var(--color-gray-600);
  font-weight: var(--font-weight-medium);
}

#presence-section {
  display: flex;
  flex-direction: column;
  gap: var(--space-3);
}

/* ============================================
     RESPONSIVE - MOBILE
     ============================================ */

@media (max-width: 768px) {
  .mobile-only {
    display: flex !important;
  }

  .desktop-only-flex {
    display: none !important;
  }

  .desktop-fab {
    display: none !important;
  }

  #app-view {
    flex-direction: column;
  }

  /* Mobile Sidebar Drawer (slides in from side) */
  #sidebar {
    position: fixed;
    top: 0;
    right: 0;
    bottom: 0;
    left: auto;
    width: min(420px, 86vw);
    height: 100%;
    max-height: none;
    border-right: none;
    border-left: 1px solid var(--color-gray-200);
    border-top: none;
    border-radius: var(--radius-2xl) 0 0 var(--radius-2xl);
    box-shadow: var(--shadow-2xl);
    transform: translateX(110%);
    z-index: 1002;
    padding-bottom: max(var(--space-5), env(safe-area-inset-bottom));
    flex-direction: column;
    transition: transform var(--transition-base);
    background: rgba(255, 255, 255, 0.98);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
  }

  .sidebar-nav {
    display: none;
  }

  .sidebar-content-wrapper {
    width: 100%;
    height: 100%;
  }

  #sidebar.mobile-open {
    transform: translateX(0);
  }

  .sidebar-header {
    display: none;
  }

  .sidebar-content {
    padding-top: var(--space-6);
  }

  /* Mobile Panel Logic */
  #sidebar.show-activities #profile-panel {
    display: none;
  }

  #sidebar.show-profile #activities-panel {
    display: none;
  }

  /* Bottom Navigation (Restored) */
  #bottom-nav {
    display: flex !important;
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    background: rgba(8, 12, 22, 0.95);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border-top: 1px solid rgba(96, 165, 250, 0.2);
    z-index: 2000;
    height: 70px; /* Explicit height */
    padding-bottom: env(safe-area-inset-bottom);
    box-shadow: 0 -4px 20px rgba(0, 0, 0, 0.4);
  }

  .nav-item {
    background: none;
    color: rgba(255, 255, 255, 0.5);
    flex-direction: column;
    gap: 4px;
    font-size: 11px;
    padding: 8px 0;
    flex: 1;
    border-radius: 0;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    transition: all 0.2s ease;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    border: none;
    box-shadow: none;
  }

  .nav-item::before,
  .nav-item::after {
    display: none;
  }

  .nav-item .icon {
    font-size: 24px;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 2px;
  }

  .nav-item .icon svg {
    width: 22px;
    height: 22px;
    display: block;
    stroke-width: 2.5;
  }

  .nav-item.active {
    color: #60a5fa; /* Primary blue */
    background: linear-gradient(to top, rgba(96, 165, 250, 0.1), transparent);
  }

  .nav-item.active .icon svg {
    filter: drop-shadow(0 0 8px rgba(96, 165, 250, 0.6));
  }

  .nav-item:hover {
    background: rgba(255, 255, 255, 0.03);
    color: #93c5fd;
  }

  #main-content {
    height: 100%;
    padding-bottom: 70px; /* Space for bottom nav */
  }

  #map {
    height: 100%;
  }

  #mobile-drawer-backdrop {
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.35);
    z-index: 1001;
    backdrop-filter: blur(2px);
    -webkit-backdrop-filter: blur(2px);
  }

  #mobile-side-nav {
    display: none !important;
  }

  .mobile-nav-icon {
    width: 52px;
    height: 52px;
    border-radius: 999px;
    background: rgba(8, 12, 22, 0.7);
    color: rgba(255, 255, 255, 0.82);
    border: 1px solid rgba(255, 255, 255, 0.16);
    box-shadow:
      0 10px 24px rgba(0, 0, 0, 0.35),
      inset 0 0 24px rgba(255, 255, 255, 0.06);
    padding: 0;
  }

  .mobile-nav-icon::before,
  .mobile-nav-icon::after {
    display: none;
  }

  .mobile-nav-icon svg {
    width: 26px;
    height: 26px;
    display: block;
  }

  .mobile-nav-icon.active {
    background: var(--gradient-blue-purple);
    color: rgba(255, 255, 255, 1);
    border-color: rgba(255, 255, 255, 0.24);
    box-shadow: var(--shadow-colored);
  }

  .mobile-nav-icon:active {
    transform: translateY(0) scale(0.98);
  }

  #sidebar-toggle-mobile {
    display: none !important;
  }

  #desktop-sidebar-toggle {
    display: none !important;
  }

  /* Mobile-specific adjustments */
  .login-box {
    padding: var(--space-8);
  }

  .login-box h1 {
    font-size: var(--font-size-2xl);
  }

  /* Ensure Panels Show (Override hidden) */
  #sidebar.show-profile #profile-panel {
    display: flex !important;
  }
  #sidebar.show-activities #activities-panel {
    display: flex !important;
  }
}

/* ============================================
     AVAILABLE BUTTON STATES
     ============================================ */

.available-btn {
  width: 100%;
  padding: var(--space-3);
  font-weight: var(--font-weight-bold);
  text-transform: uppercase;
  letter-spacing: 0.5px;
  transition: all var(--transition-base);
  border-radius: var(--radius-md);
  font-size: var(--font-size-sm);
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  position: relative;
  overflow: hidden;
}

.available-btn.hidden-state {
  background: var(--color-gray-100);
  color: var(--color-gray-600);
  border: 1px solid var(--color-gray-300);
  box-shadow: none;
}

.available-btn.hidden-state:hover {
  background: var(--color-gray-200);
  color: var(--color-gray-800);
  transform: translateY(-2px);
}

.available-btn.shared-state {
  background: var(--gradient-blue-purple);
  color: white;
  border: 1px solid transparent;
  box-shadow: var(--shadow-md);
  animation: pulse-border 2s infinite;
}

.available-btn.shared-state::before {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(
    135deg,
    rgba(255, 255, 255, 0.3) 0%,
    transparent 100%
  );
  opacity: 0;
  transition: opacity var(--transition-base);
}

.available-btn.shared-state:hover::before {
  opacity: 1;
}

@keyframes pulse-border {
  0% {
    box-shadow: 0 0 0 0 rgba(59, 130, 246, 0.4);
  }
  70% {
    box-shadow: 0 0 0 6px rgba(59, 130, 246, 0);
  }
  100% {
    box-shadow: 0 0 0 0 rgba(59, 130, 246, 0);
  }
}

/* Busy Button State */
.available-btn.busy-state {
  background: linear-gradient(135deg, #f97316 0%, #ef4444 100%);
  color: white;
  border: 1px solid transparent;
  box-shadow: var(--shadow-md);
  animation: pulse-border-orange 2s infinite;
}

.available-btn.busy-state::before {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(
    135deg,
    rgba(255, 255, 255, 0.3) 0%,
    transparent 100%
  );
  opacity: 0;
  transition: opacity var(--transition-base);
}

.available-btn.busy-state:hover::before {
  opacity: 1;
}

@keyframes pulse-border-orange {
  0% {
    box-shadow: 0 0 0 0 rgba(239, 68, 68, 0.4);
  }
  70% {
    box-shadow: 0 0 0 6px rgba(239, 68, 68, 0);
  }
  100% {
    box-shadow: 0 0 0 0 rgba(239, 68, 68, 0);
  }
}

/* Badge Styles */
.busy-badge,
.distance-badge {
  display: inline-block;
  padding: 2px 8px;
  border-radius: var(--radius-sm);
  font-size: 0.75rem;
  font-weight: 600;
  margin-left: 8px;
  white-space: nowrap;
}

.busy-badge {
  background: #fecaca;
  color: #991b1b;
}

.busy-badge .status-dot {
  display: inline-block;
  width: 8px;
  height: 8px;
  border-radius: 999px;
  background: #dc2626;
  margin-right: 6px;
  vertical-align: middle;
}

.distance-badge {
  background: #dbeafe;
  color: #1e40af;
}

.suggestion-icon {
  color: var(--color-primary-600);
  display: inline-flex;
  align-items: center;
  justify-content: center;
}

.suggestion-icon svg {
  width: 20px;
  height: 20px;
  display: block;
}

/* Decorative Background Orbs */
.orb {
  position: absolute;
  filter: blur(80px);
  z-index: 0;
  opacity: 0.5;
  border-radius: 50%;
  animation: float 10s ease-in-out infinite;
}
.orb-1 {
  width: 400px;
  height: 400px;
  background: var(--color-primary-500);
  top: -10%;
  left: -10%;
}
.orb-2 {
  width: 300px;
  height: 300px;
  background: var(--color-accent-500);
  bottom: -5%;
  right: -5%;
  animation-delay: -2s;
}

/* Signup Specifics */
.signup-box {
  max-width: 500px !important;
  padding: var(--space-8) !important;
}

.signup-header {
  margin-bottom: var(--space-6);
}

.brand-badge {
  display: inline-block;
  padding: 4px 12px;
  background: rgba(255, 255, 255, 0.2);
  border-radius: var(--radius-full);
  font-size: 10px;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 2px;
  margin-bottom: var(--space-3);
  border: 1px solid rgba(255, 255, 255, 0.3);
}

/* Profile Photo UX */
.profile-upload-container {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: var(--space-3);
  margin-bottom: var(--space-6);
}

.avatar-preview {
  width: 80px;
  height: 80px;
  background: rgba(255, 255, 255, 0.1);
  border: 2px dashed rgba(255, 255, 255, 0.4);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 32px;
  color: white;
  background-size: cover;
  background-position: center;
  transition: all var(--transition-base);
}

.file-label {
  font-size: var(--font-size-xs);
  color: white;
  cursor: pointer;
  background: rgba(255, 255, 255, 0.1);
  padding: 6px 12px;
  border-radius: var(--radius-md);
  transition: background 0.2s;
}

.file-label:hover {
  background: rgba(255, 255, 255, 0.2);
}
.file-label input {
  display: none;
}

/* Modern Input Styling */
.input-group {
  position: relative;
  width: 100%;
  margin-bottom: var(--space-4);
}

.input-group i {
  position: absolute;
  left: 12px;
  top: 50%;
  transform: translateY(-50%);
  color: var(--color-gray-500);
  z-index: 10;
}

.input-group input {
  margin-top: 0;
  padding-left: 40px;
}

.input-row {
  display: flex;
  gap: var(--space-3);
}

/* CTA Button */
.cta-button {
  width: 100%;
  height: 50px;
  font-size: var(--font-size-base);
  gap: var(--space-2);
  background: white !important;
  color: var(--color-primary-800) !important;
}

.back-link {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  margin-top: var(--space-4);
  color: white;
  font-size: var(--font-size-sm);
  opacity: 0.8;
  text-decoration: none;
  transition: opacity 0.2s;
}

.back-link:hover {
  opacity: 1;
}

/* ============================================
   SPACE THEME - ULTRA REALISTIC WITH SPACESHIP
   ============================================ */

/* Deep Space Background with Nebula */
.space-background {
  position: fixed !important;
  inset: 0;
  background:
    radial-gradient(
      ellipse at 20% 80%,
      rgba(88, 28, 135, 0.15) 0%,
      transparent 50%
    ),
    radial-gradient(
      ellipse at 80% 20%,
      rgba(30, 58, 138, 0.2) 0%,
      transparent 50%
    ),
    radial-gradient(ellipse at center, #1a1f3a 0%, #0a0e1a 70%, #000000 100%) !important;
  z-index: -2 !important;
  display: block !important;
  overflow: hidden;
}

/* Multi-layer Starfield */
.stars {
  position: absolute;
  inset: 0;
  background-image:
    radial-gradient(2px 2px at 10% 20%, rgba(255, 255, 255, 1), transparent),
    radial-gradient(3px 3px at 25% 35%, rgba(200, 220, 255, 1), transparent),
    radial-gradient(2px 2px at 40% 60%, rgba(255, 240, 200, 1), transparent),
    radial-gradient(2px 2px at 60% 15%, rgba(255, 255, 255, 0.9), transparent),
    radial-gradient(1px 1px at 75% 45%, rgba(255, 255, 255, 0.8), transparent),
    radial-gradient(2px 2px at 85% 70%, rgba(200, 220, 255, 0.9), transparent),
    radial-gradient(1px 1px at 90% 25%, rgba(255, 255, 255, 0.7), transparent),
    radial-gradient(1px 1px at 15% 50%, rgba(255, 255, 255, 0.6), transparent),
    radial-gradient(1px 1px at 30% 80%, rgba(255, 240, 200, 0.6), transparent),
    radial-gradient(1px 1px at 50% 30%, rgba(255, 255, 255, 0.5), transparent),
    radial-gradient(1px 1px at 70% 65%, rgba(200, 220, 255, 0.5), transparent);
  background-size:
    300px 300px,
    300px 300px,
    300px 300px,
    300px 300px,
    250px 250px,
    250px 250px,
    250px 250px,
    200px 200px,
    200px 200px,
    200px 200px,
    200px 200px;
  animation: star-twinkle 4s ease-in-out infinite alternate;
  opacity: 0.9 !important;
  pointer-events: none;
  z-index: -1 !important;
}

@keyframes star-twinkle {
  0%,
  100% {
    opacity: 0.7;
  }
  50% {
    opacity: 1;
  }
}

/* Shooting Stars - Smaller */
.shooting-star {
  position: absolute;
  width: 2px;
  height: 2px;
  background: white;
  border-radius: 50%;
  box-shadow: 0 0 6px 1px rgba(255, 255, 255, 0.9);
  opacity: 0;
  z-index: 5;
}

.shooting-star::before {
  content: "";
  position: absolute;
  top: 0;
  right: 2px;
  width: 60px;
  height: 1px;
  background: linear-gradient(90deg, rgba(255, 255, 255, 0.9), transparent);
  transform: translateX(2px);
}

.shooting-star:nth-child(1) {
  top: 15%;
  right: 20%;
  animation: shooting 3s linear 1s infinite;
}

.shooting-star:nth-child(2) {
  top: 40%;
  right: 60%;
  animation: shooting 3s linear 4s infinite;
}

.shooting-star:nth-child(3) {
  top: 70%;
  right: 10%;
  animation: shooting 3s linear 7s infinite;
}

@keyframes shooting {
  0% {
    transform: translateX(0) translateY(0);
    opacity: 1;
  }
  70% {
    opacity: 1;
  }
  100% {
    transform: translateX(-1000px) translateY(500px);
    opacity: 0;
  }
}

/* ULTRA REALISTIC PLANETS */
.planet {
  position: absolute;
  border-radius: 50%;
  z-index: 0 !important;
  opacity: 1 !important;
}

/* Large Blue Gas Giant - Jupiter-like */
.planet-1 {
  width: 200px !important;
  height: 200px !important;
  background:
    radial-gradient(
      ellipse at 70% 30%,
      rgba(180, 220, 255, 0.4) 0%,
      transparent 30%
    ),
    linear-gradient(
      180deg,
      #4a7ba7 0%,
      #3a6a9b 15%,
      #5a8bbf 20%,
      #2a4a6b 35%,
      #4a7ba7 40%,
      #3a6a9b 55%,
      #5a8bbf 60%,
      #2a4a6b 75%,
      #3a5a7b 100%
    );
  top: 10%;
  left: 6%;
  box-shadow:
    inset -25px -25px 50px rgba(0, 0, 0, 0.9),
    inset 20px 20px 40px rgba(150, 200, 255, 0.2),
    0 0 80px rgba(96, 165, 250, 0.5),
    0 0 120px rgba(96, 165, 250, 0.3);
  animation: orbit-drift-1 40s ease-in-out infinite;
  overflow: hidden;
}

.planet-1::before {
  content: "";
  position: absolute;
  inset: 0;
  background: repeating-linear-gradient(
    0deg,
    transparent 0%,
    rgba(30, 58, 138, 0.3) 8%,
    transparent 10%,
    rgba(90, 139, 191, 0.2) 18%,
    transparent 20%
  );
  border-radius: 50%;
  transform: skewY(-3deg);
}

.planet-1::after {
  content: "";
  position: absolute;
  top: 35%;
  left: 25%;
  width: 40px;
  height: 50px;
  background: radial-gradient(ellipse, rgba(200, 100, 80, 0.6), transparent);
  border-radius: 50%;
  filter: blur(3px);
}

/* Medium Mars-like Rocky Planet */
.planet-2 {
  width: 130px !important;
  height: 130px !important;
  background:
    radial-gradient(
      circle at 38% 32%,
      rgba(255, 180, 120, 0.6) 0%,
      transparent 25%
    ),
    radial-gradient(
      circle at 25% 65%,
      rgba(120, 60, 40, 0.4) 0%,
      transparent 20%
    ),
    radial-gradient(
      circle at 70% 50%,
      rgba(100, 50, 30, 0.3) 0%,
      transparent 18%
    ),
    linear-gradient(135deg, #c1440e 0%, #8b3510 50%, #5a2410 100%);
  bottom: 16%;
  right: 10%;
  box-shadow:
    inset -18px -18px 40px rgba(0, 0, 0, 0.95),
    inset 15px 15px 30px rgba(255, 140, 80, 0.15),
    0 0 60px rgba(193, 68, 14, 0.4),
    0 0 90px rgba(193, 68, 14, 0.2);
  animation: orbit-drift-2 45s ease-in-out infinite reverse;
}

.planet-2::before {
  content: "";
  position: absolute;
  top: 22%;
  left: 35%;
  width: 30px;
  height: 30px;
  background: radial-gradient(circle, rgba(70, 35, 20, 0.8), transparent 70%);
  border-radius: 50%;
  box-shadow:
    inset -5px -5px 10px rgba(0, 0, 0, 0.7),
    20px 35px 0 -8px rgba(50, 25, 15, 0.6),
    -15px 20px 0 -12px rgba(60, 30, 18, 0.5);
}

.planet-2::after {
  content: "";
  position: absolute;
  bottom: 28%;
  right: 25%;
  width: 22px;
  height: 22px;
  background: radial-gradient(circle, rgba(60, 30, 18, 0.7), transparent 70%);
  border-radius: 50%;
  box-shadow: inset -4px -4px 8px rgba(0, 0, 0, 0.8);
}

/* Small Earth-like Planet */
.planet-3 {
  width: 90px !important;
  height: 90px !important;
  background:
    radial-gradient(
      circle at 40% 35%,
      rgba(150, 220, 255, 0.5) 0%,
      transparent 25%
    ),
    radial-gradient(
      circle at 55% 60%,
      rgba(80, 180, 100, 0.6) 0%,
      transparent 30%
    ),
    radial-gradient(
      circle at 25% 70%,
      rgba(70, 150, 90, 0.5) 0%,
      transparent 25%
    ),
    linear-gradient(135deg, #1e88e5 0%, #0d47a1 40%, #1b5e20 60%, #2e7d32 100%);
  top: 56%;
  left: 16%;
  box-shadow:
    inset -15px -15px 35px rgba(0, 0, 0, 0.9),
    inset 12px 12px 25px rgba(150, 220, 255, 0.2),
    0 0 50px rgba(30, 136, 229, 0.4),
    0 0 75px rgba(30, 136, 229, 0.2);
  animation: orbit-drift-3 30s ease-in-out infinite;
}

.planet-3::before {
  content: "";
  position: absolute;
  top: 15%;
  right: 20%;
  width: 100%;
  height: 100%;
  background:
    radial-gradient(
      ellipse at 30% 30%,
      rgba(255, 255, 255, 0.6) 0%,
      transparent 15%
    ),
    radial-gradient(
      ellipse at 70% 60%,
      rgba(255, 255, 255, 0.4) 0%,
      transparent 12%
    );
  border-radius: 50%;
}

/* Orbit Animations */
@keyframes orbit-drift-1 {
  0%,
  100% {
    transform: translate(0, 0) rotate(0deg);
  }
  25% {
    transform: translate(50px, -40px) rotate(3deg);
  }
  50% {
    transform: translate(40px, -80px) rotate(0deg);
  }
  75% {
    transform: translate(-30px, -50px) rotate(-3deg);
  }
}

@keyframes orbit-drift-2 {
  0%,
  100% {
    transform: translate(0, 0) rotate(0deg);
  }
  33% {
    transform: translate(-70px, 50px) rotate(-5deg);
  }
  66% {
    transform: translate(30px, -40px) rotate(5deg);
  }
}

@keyframes orbit-drift-3 {
  0%,
  100% {
    transform: translate(0, 0) rotate(0deg);
  }
  50% {
    transform: translate(45px, -55px) rotate(10deg);
  }
}

/* ULTRA REALISTIC SPACESHIP */
.spaceship {
  position: absolute;
  width: 120px;
  height: 60px;
  top: 30%;
  left: -150px;
  z-index: 6;
  animation: spaceship-fly 30s linear infinite;
}

/* Main Body */
.spaceship::before {
  content: "";
  position: absolute;
  width: 70px;
  height: 25px;
  background: linear-gradient(135deg, #b0bec5 0%, #78909c 50%, #546e7a 100%);
  clip-path: polygon(0% 50%, 15% 0%, 85% 0%, 100% 50%, 85% 100%, 15% 100%);
  top: 50%;
  right: 20px;
  transform: translateY(-50%);
  box-shadow:
    inset -3px -3px 8px rgba(0, 0, 0, 0.5),
    inset 2px 2px 6px rgba(255, 255, 255, 0.2),
    0 0 20px rgba(144, 202, 249, 0.4);
}

/* Cockpit Window */
.spaceship::after {
  content: "";
  position: absolute;
  width: 18px;
  height: 12px;
  background: radial-gradient(
    ellipse,
    rgba(100, 200, 255, 0.9),
    rgba(30, 136, 229, 0.7)
  );
  border-radius: 50%;
  top: 50%;
  right: 30px;
  transform: translateY(-50%);
  box-shadow:
    inset -2px -2px 4px rgba(0, 0, 0, 0.3),
    0 0 15px rgba(100, 200, 255, 0.8);
  animation: cockpit-glow 2s ease-in-out infinite alternate;
}

/* Wings */
.wing-left,
.wing-right {
  position: absolute;
  width: 35px;
  height: 18px;
  background: linear-gradient(135deg, #90a4ae 0%, #607d8b 100%);
  top: 50%;
  box-shadow:
    inset -2px -2px 6px rgba(0, 0, 0, 0.4),
    0 0 10px rgba(96, 125, 139, 0.3);
}

.wing-left {
  right: 25px;
  transform: translateY(-50%) skewY(-20deg);
  clip-path: polygon(0% 0%, 100% 20%, 100% 100%, 0% 80%);
}

.wing-right {
  right: 25px;
  transform: translateY(-50%) skewY(20deg);
  clip-path: polygon(0% 20%, 100% 0%, 100% 80%, 0% 100%);
}

/* Engine Glow - Multiple Thrusters */
.engine-1,
.engine-2,
.engine-3 {
  position: absolute;
  height: 8px;
  background: linear-gradient(
    270deg,
    rgba(100, 200, 255, 0.9),
    rgba(100, 200, 255, 0.6),
    rgba(255, 150, 100, 0.4),
    transparent
  );
  border-radius: 50%;
  left: -10px;
  animation: engine-pulse 0.2s ease-in-out infinite alternate;
}

.engine-1 {
  width: 60px;
  top: 50%;
  transform: translateY(-50%);
  box-shadow:
    0 0 15px rgba(100, 200, 255, 0.9),
    0 0 25px rgba(100, 200, 255, 0.6);
}

.engine-2 {
  width: 35px;
  top: 35%;
  transform: translateY(-30%);
  opacity: 0.7;
  animation-delay: 0.1s;
}

.engine-3 {
  width: 35px;
  top: 65%;
  transform: translateY(-30%);
  opacity: 0.7;
  animation-delay: 0.15s;
}

/* Engine Particles */
.particle-trail {
  position: absolute;
  width: 80px;
  height: 3px;
  background: linear-gradient(
    270deg,
    rgba(255, 200, 100, 0.6),
    rgba(100, 200, 255, 0.4),
    transparent
  );
  top: 50%;
  right: 80px;
  transform: translateY(50%);
  border-radius: 50%;
  opacity: 0.5;
  animation: particle-drift 0.4s ease-out infinite;
}

@keyframes spaceship-fly {
  0% {
    left: -150px;
    top: 30%;
  }
  25% {
    top: 25%;
  }
  50% {
    left: 50%;
    top: 28%;
  }
  75% {
    top: 32%;
  }
  100% {
    left: 110%;
    top: 35%;
  }
}

@keyframes engine-pulse {
  0% {
    transform: translateY(-50%) scaleX(1);
    opacity: 0.7;
  }
  100% {
    transform: translateY(-50%) scaleX(1.4);
    opacity: 1;
  }
}

@keyframes cockpit-glow {
  0% {
    box-shadow:
      inset -2px -2px 4px rgba(0, 0, 0, 0.3),
      0 0 15px rgba(100, 200, 255, 0.8);
  }
  100% {
    box-shadow:
      inset -2px -2px 4px rgba(0, 0, 0, 0.3),
      0 0 25px rgba(100, 200, 255, 1);
  }
}

@keyframes particle-drift {
  0% {
    transform: translateY(50%) translateX(0);
    opacity: 0.5;
  }
  100% {
    transform: translateY(50%) translateX(20px);
    opacity: 0;
  }
}

/* Login View Centered */
#login-view {
  background: transparent !important;
  position: fixed !important;
  display: flex !important;
  align-items: center !important;
  justify-content: center !important;
  z-index: 10;
  overflow: hidden;
}

#login-view::before,
#login-view::after {
  display: none !important;
}

/* Dark Glassmorphic Card */
.login-box,
.signup-box {
  background: rgba(8, 12, 22, 0.8) !important;
  backdrop-filter: blur(50px) saturate(180%) !important;
  -webkit-backdrop-filter: blur(50px) saturate(180%) !important;
  border: 1px solid rgba(255, 255, 255, 0.08) !important;
  box-shadow:
    0 50px 120px rgba(0, 0, 0, 0.9),
    inset 0 0 100px rgba(96, 165, 250, 0.02),
    0 0 0 1px rgba(96, 165, 250, 0.1) !important;
  z-index: 20 !important;
}

.login-box::before,
.signup-box::before {
  background: linear-gradient(
    135deg,
    rgba(96, 165, 250, 0.12),
    rgba(244, 114, 182, 0.12)
  ) !important;
  opacity: 0.6 !important;
}

.login-box:hover::before,
.signup-box:hover::before {
  opacity: 1 !important;
}

/* Subtitle */
.subtitle {
  color: rgba(255, 255, 255, 0.6);
  font-size: 15px;
  margin-bottom: 32px;
}

/* Responsive */
@media (max-width: 768px) {
  .planet-1 {
    width: 140px !important;
    height: 140px !important;
  }

  .planet-2 {
    width: 90px !important;
    height: 90px !important;
  }

  .planet-3 {
    width: 65px !important;
    height: 65px !important;
  }

  .spaceship {
    width: 60px;
    height: 30px;
  }
}
/* ============================================
   ENHANCED MAP & SIDEBAR UI
   Add this to the end of your existing styles.css
   ============================================ */

/* ============================================
   GLASSMORPHIC SIDEBAR WITH DARK SPACE THEME (Desktop Only)
   ============================================ */

@media (min-width: 769px) {
  #app-view {
    background: transparent !important;
    position: relative;
    height: 100vh;
  }

  #sidebar {
    width: 400px;
    background: rgba(8, 12, 22, 0.85) !important;
    backdrop-filter: blur(40px) saturate(180%) !important;
    -webkit-backdrop-filter: blur(40px) saturate(180%) !important;
    border-right: 1px solid rgba(96, 165, 250, 0.15) !important;
    box-shadow:
      4px 0 60px rgba(0, 0, 0, 0.5),
      inset 0 0 100px rgba(96, 165, 250, 0.03) !important;
    transition: all var(--transition-smooth);
  }

  #sidebar::before {
    content: "";
    position: absolute;
    inset: 0;
    background: linear-gradient(
      180deg,
      rgba(96, 165, 250, 0.08) 0%,
      transparent 50%,
      rgba(168, 85, 247, 0.05) 100%
    );
    pointer-events: none;
    z-index: 0;
  }

  /* Sidebar Nav Rail - Space Theme */
  .sidebar-nav {
    background: rgba(0, 0, 0, 0.4) !important;
    border-right: 1px solid rgba(96, 165, 250, 0.12) !important;
    position: relative;
    z-index: 1;
  }

  .sidebar-nav::after {
    background: linear-gradient(
      to bottom,
      rgba(96, 165, 250, 0.3),
      rgba(168, 85, 247, 0.3),
      rgba(96, 165, 250, 0.3)
    ) !important;
  }

  /* Enhanced Nav Icons with Solid Backgrounds for Emoji Visibility */
  .nav-icon {
    background: #1a1f2e !important;
    border: 1px solid rgba(96, 165, 250, 0.3);
    color: rgba(255, 255, 255, 0.6);
    position: relative;
    box-shadow:
      0 4px 12px rgba(0, 0, 0, 0.4),
      inset 0 0 20px rgba(0, 0, 0, 0.3);
  }

  .nav-icon::before {
    background: linear-gradient(
      135deg,
      rgba(96, 165, 250, 1),
      rgba(168, 85, 247, 1)
    );
    opacity: 0;
  }

  .nav-icon:hover {
    background: #252d42 !important;
    color: rgba(255, 255, 255, 0.9);
    transform: translateY(-2px) scale(1.05);
    box-shadow:
      0 8px 24px rgba(96, 165, 250, 0.5),
      inset 0 0 30px rgba(96, 165, 250, 0.1);
    border-color: rgba(96, 165, 250, 0.5);
  }

  .nav-icon.active {
    color: white;
    background: linear-gradient(
      135deg,
      rgba(96, 165, 250, 0.3),
      rgba(168, 85, 247, 0.3)
    ) !important;
    box-shadow:
      0 8px 32px rgba(96, 165, 250, 0.6),
      0 0 40px rgba(96, 165, 250, 0.4),
      inset 0 0 40px rgba(96, 165, 250, 0.15);
    border-color: rgba(96, 165, 250, 0.6);
  }

  .nav-icon.active::before {
    opacity: 0.7;
  }

  /* Sidebar Header - Dark Glass */
  .sidebar-header {
    background: rgba(0, 0, 0, 0.3) !important;
    backdrop-filter: blur(20px);
    border-bottom: 1px solid rgba(96, 165, 250, 0.15);
    position: relative;
    z-index: 1;
  }

  .sidebar-header h2 {
    color: white !important;
    background: linear-gradient(
      135deg,
      rgba(96, 165, 250, 1),
      rgba(168, 85, 247, 1)
    ) !important;
    -webkit-background-clip: text !important;
    -webkit-text-fill-color: transparent !important;
    background-clip: text !important;
    filter: drop-shadow(0 0 20px rgba(96, 165, 250, 0.5));
  }

  /* Sidebar Content */
  .sidebar-content {
    position: relative;
    z-index: 1;
  }

  /* Enhanced Scrollbar - Neon Glow */
  .sidebar-content::-webkit-scrollbar {
    width: 10px;
  }

  .sidebar-content::-webkit-scrollbar-track {
    background: rgba(0, 0, 0, 0.3);
    border-radius: var(--radius-full);
    margin: 8px 0;
  }

  .sidebar-content::-webkit-scrollbar-thumb {
    background: linear-gradient(
      to bottom,
      rgba(96, 165, 250, 0.8),
      rgba(168, 85, 247, 0.8)
    );
    border-radius: var(--radius-full);
    border: 2px solid rgba(0, 0, 0, 0.3);
    box-shadow:
      0 0 10px rgba(96, 165, 250, 0.5),
      inset 0 0 6px rgba(255, 255, 255, 0.2);
  }

  .sidebar-content::-webkit-scrollbar-thumb:hover {
    background: linear-gradient(
      to bottom,
      rgba(96, 165, 250, 1),
      rgba(168, 85, 247, 1)
    );
    box-shadow:
      0 0 20px rgba(96, 165, 250, 0.8),
      inset 0 0 10px rgba(255, 255, 255, 0.3);
  }

  /* Panel Section Headers */
  .panel-header h3 {
    color: rgba(255, 255, 255, 0.5) !important;
    font-size: 11px;
    letter-spacing: 2px;
    text-transform: uppercase;
    font-weight: 700;
  }

  .section-title {
    color: rgba(255, 255, 255, 0.9) !important;
    font-weight: 600;
  }
}

/* ============================================
     ENHANCED CARDS - FUTURISTIC DESIGN
     ============================================ */

.user-card,
.suggestion-card {
  background: #1a1f2e !important;
  backdrop-filter: blur(20px);
  border: 1px solid rgba(96, 165, 250, 0.2) !important;
  border-radius: 16px;
  box-shadow:
    0 8px 32px rgba(0, 0, 0, 0.3),
    inset 0 0 40px rgba(96, 165, 250, 0.03);
  transition: all var(--transition-smooth);
  position: relative;
  overflow: hidden;
}

.user-card::before,
.suggestion-card::before {
  background: linear-gradient(
    90deg,
    rgba(96, 165, 250, 0.6),
    rgba(168, 85, 247, 0.6)
  ) !important;
  height: 2px;
}

.user-card::after,
.suggestion-card::after {
  background: linear-gradient(
    135deg,
    rgba(96, 165, 250, 0.15),
    rgba(168, 85, 247, 0.15)
  ) !important;
  opacity: 0;
}

.user-card:hover,
.suggestion-card:hover {
  transform: translateY(-8px) scale(1.02);
  box-shadow:
    0 20px 60px rgba(96, 165, 250, 0.3),
    0 0 80px rgba(96, 165, 250, 0.2),
    inset 0 0 60px rgba(96, 165, 250, 0.05);
  border-color: rgba(96, 165, 250, 0.4);
}

.user-card:hover::before,
.suggestion-card:hover::before {
  opacity: 1;
  box-shadow: 0 0 20px rgba(96, 165, 250, 0.6);
}

.user-card:hover::after,
.suggestion-card:hover::after {
  opacity: 1;
}

.user-card strong,
.suggestion-card strong {
  color: white !important;
  background: linear-gradient(
    135deg,
    rgba(96, 165, 250, 1),
    rgba(168, 85, 247, 1)
  ) !important;
  -webkit-background-clip: text !important;
  -webkit-text-fill-color: transparent !important;
  background-clip: text !important;
  filter: drop-shadow(0 0 10px rgba(96, 165, 250, 0.5));
}

.suggestion-card {
  color: rgba(235, 242, 255, 0.9);
}

.suggestion-card .suggestion-label {
  color: #f5f7ff;
  font-weight: var(--font-weight-semibold);
  letter-spacing: 0.2px;
}

.suggestion-card .suggestion-detail {
  color: rgba(230, 237, 255, 0.78);
}

.suggestion-card .muted {
  color: rgba(255, 255, 255, 0.65) !important;
}

/* Suggestion modal */
.suggestion-modal-backdrop {
  position: fixed;
  inset: 0;
  background: rgba(10, 13, 26, 0.65);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 5000;
  backdrop-filter: blur(6px);
  padding: 16px;
}

.suggestion-modal {
  width: min(520px, 100%);
  background: #0f172a;
  border: 1px solid rgba(96, 165, 250, 0.35);
  border-radius: 16px;
  padding: 20px;
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.45);
}

.invite-header {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 12px;
}

.invite-title {
  font-weight: 700;
  font-size: 18px;
  color: #e7ecff;
}

.invite-detail {
  color: rgba(255, 255, 255, 0.7);
  font-size: 14px;
  margin-top: 4px;
}

.invite-close {
  cursor: pointer;
  color: rgba(255, 255, 255, 0.7);
}

.invite-confidence {
  margin: 12px 0;
  font-size: 13px;
  color: rgba(255, 255, 255, 0.7);
}

.invite-list {
  display: flex;
  flex-direction: column;
  gap: 10px;
  margin: 10px 0 18px;
}

.invite-row {
  display: grid;
  grid-template-columns: 110px 1fr auto;
  gap: 12px;
  align-items: center;
  padding: 10px 12px;
  border: 1px solid rgba(96, 165, 250, 0.2);
  border-radius: 10px;
  background: rgba(255, 255, 255, 0.02);
  cursor: pointer;
  transition:
    border-color var(--transition-fast),
    background var(--transition-fast);
}

.invite-row:hover {
  border-color: rgba(96, 165, 250, 0.45);
  background: rgba(96, 165, 250, 0.05);
}

.invite-row.selected {
  border-color: rgba(96, 165, 250, 0.8);
  background: rgba(96, 165, 250, 0.08);
  box-shadow: 0 8px 24px rgba(96, 165, 250, 0.12);
}

.invite-map-shell {
  width: 110px;
  min-width: 110px;
  height: 80px;
  border-radius: 8px;
  overflow: hidden;
  border: 1px solid rgba(255, 255, 255, 0.08);
  background: linear-gradient(135deg, #1f2937, #111827);
  position: relative;
}

.invite-map {
  width: 100%;
  height: 100%;
}

.invite-map.missing {
  display: grid;
  place-items: center;
  color: rgba(255, 255, 255, 0.6);
  font-size: 12px;
}

.invite-copy {
  display: flex;
  flex-direction: column;
  justify-content: center;
  gap: 4px;
  flex: 1;
  min-width: 0;
}

.invite-name {
  color: #f5f7ff;
  font-weight: 600;
  font-size: 15px;
}

.invite-meta {
  color: rgba(255, 255, 255, 0.6);
  font-size: 13px;
}

.invite-confidence-pill {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 64px;
  height: 32px;
  padding: 0 10px;
  border-radius: 999px;
  background: rgba(96, 165, 250, 0.15);
  color: #cfe4ff;
  font-size: 12px;
  border: 1px solid rgba(96, 165, 250, 0.4);
}

.invite-actions {
  display: flex;
  justify-content: flex-end;
  gap: 10px;
  margin-top: 4px;
}

.muted {
  color: rgba(255, 255, 255, 0.5) !important;
}

/* Busy User Badge */
.busy-badge {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 2px 8px;
  background: rgba(239, 68, 68, 0.25);
  border: 1px solid rgba(239, 68, 68, 0.4);
  border-radius: 12px;
  font-size: 11px;
  font-weight: 600;
  color: #fca5a5;
  animation: pulse-glow-red 2s infinite;
  backdrop-filter: blur(10px);
  box-shadow: 0 2px 8px rgba(239, 68, 68, 0.3);
}

@keyframes pulse-glow-red {
  0%,
  100% {
    box-shadow: 0 0 10px rgba(239, 68, 68, 0.3);
  }
  50% {
    box-shadow: 0 0 20px rgba(239, 68, 68, 0.6);
  }
}

/* ============================================
     ENHANCED BUTTONS - GLOWING EFFECTS
     ============================================ */

button {
  background: linear-gradient(
    135deg,
    rgba(96, 165, 250, 0.9),
    rgba(168, 85, 247, 0.9)
  ) !important;
  box-shadow:
    0 8px 24px rgba(96, 165, 250, 0.4),
    inset 0 0 30px rgba(255, 255, 255, 0.1) !important;
  border: 1px solid rgba(255, 255, 255, 0.2);
  position: relative;
  overflow: hidden;
}

button::before {
  background: linear-gradient(
    135deg,
    rgba(255, 255, 255, 0.3) 0%,
    transparent 100%
  );
}

button:hover {
  transform: translateY(-3px) scale(1.03);
  box-shadow:
    0 12px 40px rgba(96, 165, 250, 0.6),
    0 0 60px rgba(96, 165, 250, 0.4),
    inset 0 0 40px rgba(255, 255, 255, 0.15) !important;
}

button.secondary {
  background: #1a1f2e !important;
  color: rgba(255, 255, 255, 0.9) !important;
  border: 1px solid rgba(96, 165, 250, 0.3);
  box-shadow:
    0 4px 16px rgba(0, 0, 0, 0.3),
    inset 0 0 20px rgba(96, 165, 250, 0.05);
}

button.secondary:hover {
  background: #252d42 !important;
  border-color: rgba(96, 165, 250, 0.5);
  box-shadow:
    0 8px 32px rgba(96, 165, 250, 0.4),
    inset 0 0 30px rgba(96, 165, 250, 0.1);
}

button.small {
  font-size: 12px;
  padding: 8px 14px;
}

button:disabled {
  opacity: 0.3;
  cursor: not-allowed;
  transform: none !important;
  box-shadow: none !important;
}

/* ============================================
     PRESENCE BUTTONS - ENHANCED STATES
     ============================================ */

#available-btn,
#busy-btn {
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 1px;
  position: relative;
  overflow: hidden;
  border: 2px solid transparent;
}

/* Hidden State - Dark Gray */
#available-btn.hidden-state {
  background: rgba(71, 85, 105, 0.3) !important;
  color: rgba(255, 255, 255, 0.5) !important;
  border-color: rgba(71, 85, 105, 0.4);
  box-shadow:
    0 4px 16px rgba(0, 0, 0, 0.3),
    inset 0 0 20px rgba(0, 0, 0, 0.2);
}

#available-btn.hidden-state:hover {
  background: rgba(71, 85, 105, 0.5) !important;
  color: rgba(255, 255, 255, 0.8) !important;
  border-color: rgba(71, 85, 105, 0.6);
  transform: translateY(-2px);
  box-shadow:
    0 8px 24px rgba(0, 0, 0, 0.4),
    inset 0 0 30px rgba(0, 0, 0, 0.2);
}

/* Shared State - Bright Blue Glow */
#available-btn.shared-state {
  background: linear-gradient(
    135deg,
    rgba(96, 165, 250, 1),
    rgba(59, 130, 246, 1)
  ) !important;
  color: white !important;
  border-color: rgba(147, 197, 253, 0.5);
  box-shadow:
    0 8px 32px rgba(59, 130, 246, 0.6),
    0 0 60px rgba(59, 130, 246, 0.4),
    inset 0 0 40px rgba(255, 255, 255, 0.15);
  animation: pulse-glow-blue 2s infinite;
}

#available-btn.shared-state::before {
  background: linear-gradient(
    135deg,
    rgba(255, 255, 255, 0.4) 0%,
    transparent 100%
  );
}

#available-btn.shared-state:hover {
  transform: translateY(-3px) scale(1.02);
  box-shadow:
    0 12px 48px rgba(59, 130, 246, 0.8),
    0 0 80px rgba(59, 130, 246, 0.6),
    inset 0 0 50px rgba(255, 255, 255, 0.2);
}

@keyframes pulse-glow-blue {
  0%,
  100% {
    box-shadow:
      0 8px 32px rgba(59, 130, 246, 0.6),
      0 0 60px rgba(59, 130, 246, 0.4),
      inset 0 0 40px rgba(255, 255, 255, 0.15);
  }
  50% {
    box-shadow:
      0 12px 48px rgba(59, 130, 246, 0.8),
      0 0 80px rgba(59, 130, 246, 0.6),
      inset 0 0 50px rgba(255, 255, 255, 0.2);
  }
}

/* Busy State - Orange/Red Glow */
#busy-btn.busy-state {
  background: linear-gradient(
    135deg,
    rgba(249, 115, 22, 1),
    rgba(239, 68, 68, 1)
  ) !important;
  color: white !important;
  border-color: rgba(252, 165, 165, 0.5);
  box-shadow:
    0 8px 32px rgba(239, 68, 68, 0.6),
    0 0 60px rgba(239, 68, 68, 0.4),
    inset 0 0 40px rgba(255, 255, 255, 0.15);
  animation: pulse-glow-orange 2s infinite;
}

#busy-btn.busy-state:hover {
  transform: translateY(-3px) scale(1.02);
  box-shadow:
    0 12px 48px rgba(239, 68, 68, 0.8),
    0 0 80px rgba(239, 68, 68, 0.6),
    inset 0 0 50px rgba(255, 255, 255, 0.2);
}

@keyframes pulse-glow-orange {
  0%,
  100% {
    box-shadow:
      0 8px 32px rgba(239, 68, 68, 0.6),
      0 0 60px rgba(239, 68, 68, 0.4),
      inset 0 0 40px rgba(255, 255, 255, 0.15);
  }
  50% {
    box-shadow:
      0 12px 48px rgba(239, 68, 68, 0.8),
      0 0 80px rgba(239, 68, 68, 0.6),
      inset 0 0 50px rgba(255, 255, 255, 0.2);
  }
}

/* Available State - Green Subtle */
#busy-btn.shared-state {
  background: linear-gradient(
    135deg,
    rgba(34, 197, 94, 0.9),
    rgba(22, 163, 74, 0.9)
  ) !important;
  color: white !important;
  border-color: rgba(134, 239, 172, 0.5);
  box-shadow:
    0 8px 32px rgba(34, 197, 94, 0.4),
    0 0 60px rgba(34, 197, 94, 0.3),
    inset 0 0 40px rgba(255, 255, 255, 0.15);
}

#busy-btn.shared-state:hover {
  box-shadow:
    0 12px 48px rgba(34, 197, 94, 0.6),
    0 0 80px rgba(34, 197, 94, 0.4),
    inset 0 0 50px rgba(255, 255, 255, 0.2);
}

/* ============================================
     MAP CONTAINER - DARK THEME
     ============================================ */

#main-content {
  background: transparent !important;
  position: relative;
}

#map {
  border-radius: 0 !important;
  box-shadow: inset 0 0 100px rgba(0, 0, 0, 0.5);
  position: relative;
}

/* Map controls styling for dark theme */
.leaflet-control-zoom a {
  background: rgba(8, 12, 22, 0.85) !important;
  backdrop-filter: blur(20px);
  color: rgba(255, 255, 255, 0.8) !important;
  border: 1px solid rgba(96, 165, 250, 0.2) !important;
  box-shadow: 0 4px 16px rgba(0, 0, 0, 0.3);
}

.leaflet-control-zoom a:hover {
  background: rgba(96, 165, 250, 0.15) !important;
  color: white !important;
  border-color: rgba(96, 165, 250, 0.4) !important;
}

/* ============================================
     DESKTOP FAB - ENHANCED GLOW
     ============================================ */

.desktop-fab {
  background: #1a1f2e !important;
  backdrop-filter: blur(40px);
  box-shadow:
    0 8px 32px rgba(0, 0, 0, 0.4),
    0 0 60px rgba(96, 165, 250, 0.3),
    inset 0 0 40px rgba(96, 165, 250, 0.05);
  border: 1px solid rgba(96, 165, 250, 0.3);
  color: rgba(255, 255, 255, 0.8);
}

.desktop-fab:hover {
  background: #252d42 !important;
  transform: scale(1.15) rotate(10deg);
  box-shadow:
    0 12px 48px rgba(96, 165, 250, 0.6),
    0 0 80px rgba(96, 165, 250, 0.5),
    inset 0 0 60px rgba(96, 165, 250, 0.1);
  border-color: rgba(96, 165, 250, 0.6);
  color: white;
}

/* ============================================
     PROFILE SECTION
     ============================================ */

#profile-panel {
  color: rgba(255, 255, 255, 0.9);
}

#user-info {
  color: rgba(255, 255, 255, 0.7) !important;
  padding: 12px 16px;
  background: rgba(96, 165, 250, 0.1);
  border-radius: 12px;
  border: 1px solid rgba(96, 165, 250, 0.2);
  margin-bottom: 16px;
  text-align: center;
  font-weight: 600;
}

#logout-btn {
  width: 100%;
  background: linear-gradient(
    135deg,
    rgba(239, 68, 68, 0.9),
    rgba(220, 38, 38, 0.9)
  ) !important;
  margin-top: 16px;
}

#logout-btn:hover {
  box-shadow:
    0 12px 40px rgba(239, 68, 68, 0.6),
    0 0 60px rgba(239, 68, 68, 0.4) !important;
}

/* ============================================
     ACTIVITY SUGGESTIONS - ENHANCED
     ============================================ */

.suggestions-header {
  padding: 12px;
  background: #1a1f2e;
  border-radius: 12px;
  border: 1px solid rgba(96, 165, 250, 0.2);
  margin-bottom: 16px;
  box-shadow: 0 4px 16px rgba(0, 0, 0, 0.3);
}

.suggestions-header h3 {
  color: white !important;
  font-size: 16px !important;
  text-transform: none !important;
  letter-spacing: 0 !important;
}

/* Activity Cards - Solid backgrounds with gradient overlays */
.activity-card {
  position: relative;
  overflow: hidden;
  background: #1a1f2e !important;
}

.activity-card::before {
  content: "";
  position: absolute;
  inset: 0;
  background: inherit;
  opacity: 0.2;
  z-index: 0;
}

.activity-card > div {
  position: relative;
  z-index: 1;
}

/* Ensure emoji icons in activity cards are visible */
.activity-card .icon,
.activity-card [style*="font-size: 32px"],
.activity-card [style*="font-size: 24px"] {
  filter: drop-shadow(0 2px 4px rgba(0, 0, 0, 0.5));
}

/* ============================================
     LOADING & ERROR STATES
     ============================================ */

.loading-state,
.error-state {
  color: rgba(255, 255, 255, 0.7);
  text-align: center;
  padding: 32px;
}

.spinner div {
  border-color: rgba(96, 165, 250, 0.2) !important;
  border-top-color: rgba(96, 165, 250, 1) !important;
}

/* ============================================
     MOBILE RESPONSIVE - DARK THEME
     ============================================ */

@media (max-width: 768px) {
  #sidebar {
    background: rgba(8, 12, 22, 0.95) !important;
    border-left: 1px solid rgba(96, 165, 250, 0.25) !important;
    box-shadow:
      -8px 0 60px rgba(0, 0, 0, 0.8),
      inset 0 0 100px rgba(96, 165, 250, 0.05);
  }

  #bottom-nav {
    display: none !important;
  }

  .nav-item {
    color: rgba(255, 255, 255, 0.5) !important;
  }

  .nav-item.active {
    color: rgba(96, 165, 250, 1) !important;
    text-shadow: 0 0 20px rgba(96, 165, 250, 0.8);
  }

  .nav-item:hover {
    color: rgba(96, 165, 250, 0.8) !important;
  }
}

/* Specific override for the back arrow color */
#sidebar-close-btn {
  background: #1a1f2e !important;
  border: 1px solid rgba(96, 165, 250, 0.3) !important;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.4) !important;
}

/* Optional: change the arrow icon color inside the button */
#sidebar-close-btn i {
  color: rgba(255, 255, 255, 0.8);
}

/* Keep a subtle glow only when hovering */
#sidebar-close-btn:hover {
  background: #252d42 !important;
  border-color: rgba(96, 165, 250, 0.5) !important;
}

#logout-btn {
  width: fit-content !important; /* Prevents button from stretching */
  padding: 8px 20px !important; /* Makes the button a standard size */
  margin-left: auto !important; /* Centers it if in a flex container */
  margin-right: auto !important; /* Centers it if in a flex container */
  display: flex !important; /* Required for centering */
  font-size: 13px !important; /* Slightly smaller text for a cleaner look */
}

/* ============================================
   PAGING MODAL
   ============================================ */

.pager-modal-overlay {
  position: fixed;
  inset: 0;
  background: rgba(15, 23, 42, 0.4);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: var(--z-modal);
  animation: fade-in-up var(--transition-base);
  opacity: 1;
  transition: opacity var(--transition-base);
}

.pager-modal-overlay.hidden {
  opacity: 0;
  pointer-events: none;
  display: none !important;
}

.pager-modal {
  background: rgba(255, 255, 255, 0.95);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  padding: var(--space-6);
  border-radius: var(--radius-xl);
  box-shadow: var(--shadow-2xl);
  width: 90%;
  max-width: 500px;
  border: 1px solid white;
  animation: scale-in var(--transition-base);
}

.pager-title {
  display: flex;
  align-items: center;
  gap: var(--space-2);
  margin-bottom: var(--space-2);
  font-size: var(--font-size-lg);
  font-weight: var(--font-weight-bold);
  background: var(--gradient-blue-purple);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.pager-title::before {
  content: "";
  width: 24px;
  height: 24px;
  display: inline-block;
  background: var(--gradient-blue-purple);
  -webkit-mask: url('data:image/svg+xml;utf8,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24" fill="none" stroke="black" stroke-width="2" stroke-linecap="round" stroke-linejoin="round"><rect x="6" y="3" width="12" height="18" rx="2"/><path d="M9 7h6"/><path d="M9 11h6"/><path d="M10 16h4"/></svg>')
    no-repeat center / contain;
  mask: url('data:image/svg+xml;utf8,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24" fill="none" stroke="black" stroke-width="2" stroke-linecap="round" stroke-linejoin="round"><rect x="6" y="3" width="12" height="18" rx="2"/><path d="M9 7h6"/><path d="M9 11h6"/><path d="M10 16h4"/></svg>')
    no-repeat center / contain;
}

.pager-subtitle {
  color: var(--color-gray-500);
  font-size: var(--font-size-sm);
  margin-bottom: var(--space-4);
}

.pager-textarea {
  width: 100%;
  padding: var(--space-3);
  border: 2px solid var(--color-gray-200);
  border-radius: var(--radius-md);
  font-family: var(--font-family-base);
  font-size: var(--font-size-sm);
  margin-bottom: var(--space-4);
  resize: vertical;
  min-height: 80px;
  transition: all var(--transition-base);
}

.pager-textarea:focus {
  outline: none;
  border-color: var(--color-primary-400);
  box-shadow: 0 0 0 4px var(--color-primary-100);
}

.pager-actions {
  display: flex;
  justify-content: flex-end;
  gap: var(--space-3);
}

.friend-select {
  width: 100%;
  padding: var(--space-3);
  border: 2px solid var(--color-gray-200);
  border-radius: var(--radius-md);
  font-family: var(--font-family-base);
  font-size: var(--font-size-sm);
  margin-bottom: var(--space-4);
  background: white;
  cursor: pointer;
  transition: all var(--transition-base);
}

.friend-select:focus {
  outline: none;
  border-color: var(--color-primary-400);
  box-shadow: 0 0 0 4px var(--color-primary-100);
}

/* ============================================
   SUGGESTION MODAL STYLES
   ============================================ */
/* ============================================
   SUGGESTION MODAL STYLES (Refined Match)
   ============================================ */
.friend-multiselect {
  background: transparent;
  border: none;
  padding: 0;
  margin-top: var(--space-2);
  display: flex;
  flex-direction: column;
  gap: 12px;
}

/* The card row itself */
.invite-row.selection-row {
  display: flex;
  align-items: center;
  background: rgba(30, 41, 59, 0.5); /* Dark slate/blueish */
  border: 1px solid rgba(255, 255, 255, 0.15);
  border-radius: 12px; /* Matches the rounded look */
  padding: 12px;
  cursor: pointer;
  transition: all 0.2s ease;
  position: relative;
  /* ensure text is white */
  color: white;
}

.invite-row.selection-row:hover {
  background: rgba(51, 65, 85, 0.6);
  border-color: rgba(255, 255, 255, 0.3);
}

.invite-row.selection-row.selected {
  border-color: #3b82f6; /* Bright blue border */
  background: rgba(59, 130, 246, 0.1); /* Subtle blue tint */
  box-shadow: 0 0 0 1px #3b82f6; /* Double thickness visual */
}

/* Map Shell */
.invite-map-shell {
  width: 80px;
  height: 80px;
  flex-shrink: 0;
  border-radius: 8px;
  overflow: hidden;
  margin-right: 16px;
  background: #000;
}

/* Text Content */
.invite-copy {
  flex: 1;
  display: flex;
  flex-direction: column;
  justify-content: center;
}

.invite-name {
  font-weight: 600;
  font-size: 16px;
  color: white;
  margin-bottom: 4px;
}

.invite-meta {
  font-size: 13px;
  color: #94a3b8; /* Slate-400 */
}

/* Custom Selection Circle (Radio/Checkbox look) */
.selection-check {
  width: 24px;
  height: 24px;
  border-radius: 50%;
  border: 2px solid #475569; /* Slate-600 */
  margin-left: 12px;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.2s ease;
}

.selection-row.selected .selection-check {
  background: #3b82f6;
  border-color: #3b82f6;
}

.selection-row.selected .selection-check::after {
  content: "";
  width: 10px;
  height: 10px;
  border-radius: 50%; /* Or checkmark? Reference usually has circle or check. Let's do white dot for radio logic, check for multi. User said 'friends' -> multi. */
  background: white;
  /* If we want a checkmark: */
  /*
    width: 5px;
    height: 10px;
    border: solid white;
    border-width: 0 2px 2px 0;
    transform: rotate(45deg);
    margin-top: -2px;
    background: transparent;
    border-radius: 0;
    */
}

/* Hiding original native checkbox if present */
.friend-multiselect input[type="checkbox"] {
  display: none;
}

/* ============================================
     TOAST NOTIFICATIONS
     ============================================ */

#toast-container {
  position: fixed;
  bottom: var(--space-6);
  right: var(--space-6);
  z-index: var(--z-tooltip);
  display: flex;
  flex-direction: column;
  gap: var(--space-2);
  pointer-events: none;
}

.toast {
  background: white;
  color: var(--color-gray-900);
  padding: var(--space-3) var(--space-4);
  border-radius: var(--radius-md);
  box-shadow: var(--shadow-lg);
  display: flex;
  align-items: center;
  gap: var(--space-3);
  min-width: 250px;
  max-width: 350px;
  pointer-events: auto;
  animation: slide-in-right var(--transition-base) forwards;
  border-left: 4px solid var(--color-primary-500);
  font-size: var(--font-size-sm);
  font-weight: var(--font-weight-medium);
}

.toast.fade-out {
  opacity: 0;
  transform: translateX(100%);
  transition: all var(--transition-base);
}

.toast-icon {
  font-size: var(--font-size-lg);
}

/* ============================================
     SKELETON UI ANIMATIONS
     ============================================ */
.skeleton-card {
  display: flex !important;
  justify-content: flex-start;
  align-items: flex-start;
  padding: 12px;
  background: white;
  border-radius: 8px;
  border: 1px solid var(--color-gray-200);
  margin-bottom: 8px;
}

.skeleton-info {
  display: flex;
  flex-direction: column;
}

.skeleton-text,
.skeleton-avatar,
.skeleton-btn {
  background: var(--color-gray-300);
  border-radius: 4px;
  position: relative;
  overflow: hidden;
  /* Ensure shimmer is visible on top of background */
  z-index: 1;
}

.skeleton-text {
  height: 12px;
  width: 100%;
}

.skeleton-avatar {
  background: var(--color-gray-300);
  flex-shrink: 0;
}

/* Enhanced Shimmer */
.skeleton-text::after,
.skeleton-avatar::after,
.skeleton-btn::after {
  content: "";
  display: block;
  position: absolute;
  top: 0;
  right: 0;
  bottom: 0;
  left: 0;
  transform: translateX(-100%);
  background: linear-gradient(
    90deg,
    transparent 0,
    rgba(255, 255, 255, 0.4) 20%,
    rgba(255, 255, 255, 0.7) 60%,
    transparent
  );
  animation: skeleton-shimmer 1.2s infinite;
  z-index: 2;
}

.skeleton-title {
  height: 16px;
  background: var(--color-gray-400);
  margin-bottom: 6px;
}

.skeleton-actions {
  display: flex;
  gap: 8px;
}

.skeleton-btn {
  width: 60px;
  height: 28px;
  border-radius: 6px;
}

@keyframes skeleton-shimmer {
  100% {
    transform: translateX(100%);
  }
}
