/* G2R Base Server - Interface d'administration - Design Moderne */
/* ============================================
   MOBILE-FIRST RESPONSIVE DESIGN
   Base: Mobile (<768px)
   Tablet: 768px+
   Desktop: 1024px+
   Large: 1400px+
   ============================================ */

:root {
  /* Couleurs principales */
  --primary-color: #ff6b00;
  --primary-hover: #ff8533;
  --primary-dark: #cc5500;

  /* Couleurs de fond - Plus sombres */
  --bg-dark: #000000;
  --bg-darker: #000000;
  --bg-card: #0a0a0a;
  --bg-card-hover: #141414;
  --bg-modal: rgba(0, 0, 0, 0.9);

  /* Couleurs de texte */
  --text-primary: #e0e0e0;
  --text-secondary: #999999;
  --text-muted: #666666;

  /* Couleurs d'état */
  --success-color: #4caf50;
  --warning-color: #ff9800;
  --danger-color: #f44336;
  --info-color: #2196f3;

  /* Couleurs supplémentaires */
  --secondary-color: #999999;
  --light-color: #1f1f1f;
  --dark-color: #000000;
  --border-color: #1a1a1a;

  /* Paramètres UI */
  --border-radius: 8px;
  --box-shadow: 0 2px 8px rgba(0,0,0,0.5);
  --transition: all 0.2s ease;

  /* Grille subtile */
  --grid-color: rgba(255, 107, 0, 0.02);
  --grid-size: 40px;

  /* Layout - Mobile first */
  --header-height: 48px;
  --nav-height: 44px;
  --content-padding: 0.75rem;
}

/* Tablet+ */
@media (min-width: 768px) {
  :root {
    --header-height: 64px;
    --nav-height: 52px;
    --content-padding: 1.5rem;
  }
}

/* Desktop+ */
@media (min-width: 1024px) {
  :root {
    --header-height: 72px;
    --nav-height: 56px;
    --content-padding: 2rem;
  }
}

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

body {
  font-family: 'Orbitron', 'Rajdhani', 'Segoe UI', monospace;
  background-color: var(--bg-dark);
  color: var(--text-primary);
  line-height: 1.6;
  background-image: 
    linear-gradient(rgba(255, 107, 0, 0.03) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255, 107, 0, 0.03) 1px, transparent 1px);
  background-size: var(--grid-size) var(--grid-size);
  position: relative;
}

/* Import des polices cyberpunk */
@import url('https://fonts.googleapis.com/css2?family=Orbitron:wght@400;600;700;900&family=Rajdhani:wght@300;400;500;600;700&display=swap');

/* Animation de scan */
@keyframes scan {
  0% { transform: translateY(-100%); }
  100% { transform: translateY(100vh); }
}

body::before {
  content: '';
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: linear-gradient(transparent 0%, rgba(255, 107, 0, 0.05) 50%, transparent 100%);
  animation: scan 8s linear infinite;
  pointer-events: none;
  z-index: 1;
}

/* ============================================
   HEADER - Mobile First
   ============================================ */
.header {
  background: linear-gradient(180deg, var(--bg-darker) 0%, rgba(20, 20, 20, 0.95) 100%);
  color: var(--text-primary);
  height: var(--header-height);
  box-shadow: 0 2px 20px rgba(255, 107, 0, 0.3);
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 1000;
  border-bottom: 1px solid var(--primary-color);
  backdrop-filter: blur(10px);
  display: flex;
  align-items: center;
}

.header-content {
  width: 100%;
  max-width: 1400px;
  margin: 0 auto;
  padding: 0 var(--content-padding);
  display: flex;
  justify-content: space-between;
  align-items: center;
}

/* Logo - Mobile: image only */
.logo {
  font-size: 0; /* Hide text on mobile */
  font-weight: 900;
  font-family: 'Orbitron', monospace;
  display: flex;
  align-items: center;
  gap: 0.5rem;
  text-transform: uppercase;
  letter-spacing: 2px;
  color: var(--primary-color);
}

.logo-img {
  height: 28px;
  width: auto;
}

/* Tablet+: Show logo text */
@media (min-width: 768px) {
  .logo {
    font-size: 1.2rem;
    gap: 0.6rem;
  }
  .logo-img {
    height: 32px;
  }
}

/* Desktop+: Full logo */
@media (min-width: 1024px) {
  .logo {
    font-size: 1.6rem;
    gap: 0.75rem;
  }
  .logo-img {
    height: 40px;
  }
}

@keyframes neon-flicker {
  0%, 100% { opacity: 1; }
  50% { opacity: 0.8; }
}

/* User info - Mobile: minimal */
.user-info {
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

/* Hide non-essential on mobile */
.user-info #status-text,
.user-info .status-indicator {
  display: none;
}

.realtime-indicator {
  display: none;
}

/* Tablet+: Show status */
@media (min-width: 768px) {
  .user-info {
    gap: 0.75rem;
  }
  .user-info #status-text {
    display: inline;
    font-size: 0.85rem;
  }
  .user-info .status-indicator {
    display: inline-block;
  }
}

/* Desktop+: Show real-time indicator */
@media (min-width: 1024px) {
  .user-info {
    gap: 1rem;
  }
  .realtime-indicator {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    font-size: 0.8rem;
    font-family: 'Rajdhani', sans-serif;
    font-weight: 600;
    color: var(--success-color);
    margin-left: 0.5rem;
    text-transform: uppercase;
    letter-spacing: 1px;
  }
}

.status-indicator {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background-color: var(--success-color);
  box-shadow: 0 0 6px var(--success-color);
}

@keyframes pulse-neon {
  0% { box-shadow: 0 0 5px var(--success-color), 0 0 10px var(--success-color); }
  50% { box-shadow: 0 0 10px var(--success-color), 0 0 20px var(--success-color); }
  100% { box-shadow: 0 0 5px var(--success-color), 0 0 10px var(--success-color); }
}

@keyframes pulse {
  0% { opacity: 1; }
  50% { opacity: 0.5; }
  100% { opacity: 1; }
}

.pulse-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background-color: var(--success-color);
  box-shadow: 0 0 6px var(--success-color);
  animation: pulse-neon 1.5s infinite;
}

/* Logout button - responsive */
#logout-btn {
  padding: 0.35rem 0.6rem;
  font-size: 0.7rem;
}

@media (min-width: 768px) {
  #logout-btn {
    padding: 0.5rem 1rem;
    font-size: 0.85rem;
  }
}

/* ============================================
   NAVIGATION TABS - Mobile First
   ============================================ */
.nav-tabs {
  background: var(--bg-card);
  margin-top: var(--header-height);
  height: var(--nav-height);
  border-bottom: 1px solid var(--primary-color);
  position: sticky;
  top: var(--header-height);
  z-index: 100;
  box-shadow: 0 2px 10px rgba(255, 107, 0, 0.2);
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
}

/* Hide scrollbar but keep functionality */
.nav-tabs::-webkit-scrollbar {
  height: 0;
  display: none;
}

.nav-tabs ul {
  max-width: 1400px;
  margin: 0 auto;
  padding: 0 0.5rem;
  display: flex;
  list-style: none;
  height: 100%;
  min-width: max-content; /* Allow horizontal scroll */
}

.nav-tabs li {
  margin-right: 0;
  height: 100%;
}

/* Tab buttons - Mobile: compact */
.nav-tabs button {
  background: none;
  border: none;
  height: 100%;
  padding: 0 0.75rem;
  cursor: pointer;
  font-size: 0.75rem;
  font-family: 'Rajdhani', sans-serif;
  font-weight: 600;
  color: var(--text-secondary);
  border-bottom: 3px solid transparent;
  transition: var(--transition);
  display: flex;
  align-items: center;
  gap: 0.3rem;
  text-transform: uppercase;
  letter-spacing: 0;
  white-space: nowrap;
}

/* Tablet+: Bigger tabs */
@media (min-width: 768px) {
  .nav-tabs ul {
    padding: 0 1rem;
  }
  .nav-tabs li {
    margin-right: 0.5rem;
  }
  .nav-tabs button {
    padding: 0 1rem;
    font-size: 0.85rem;
    gap: 0.4rem;
    letter-spacing: 0.5px;
  }
}

/* Desktop+: Full tabs */
@media (min-width: 1024px) {
  .nav-tabs ul {
    padding: 0 var(--content-padding);
  }
  .nav-tabs li {
    margin-right: 1rem;
  }
  .nav-tabs button {
    padding: 0 1.5rem;
    font-size: 1rem;
    gap: 0.5rem;
    letter-spacing: 1px;
  }
}

.nav-tabs button:hover {
  color: var(--primary-color);
  background-color: rgba(255, 107, 0, 0.1);
}

.nav-tabs button.active {
  color: var(--primary-color);
  border-bottom-color: var(--primary-color);
  font-weight: 700;
  background: linear-gradient(180deg, transparent, rgba(255, 107, 0, 0.1));
}

/* ============================================
   MAIN CONTAINER - Mobile First
   ============================================ */
.container {
  max-width: 1400px;
  margin: 0 auto;
  padding: 1rem var(--content-padding);
  /* Account for fixed header + nav */
  min-height: calc(100vh - var(--header-height) - var(--nav-height));
}

/* Cards Design Moderne */
.card {
  background: #0f0f0f;
  border: 1px solid #1f1f1f;
  border-radius: 12px;
  box-shadow: 0 4px 6px rgba(0, 0, 0, 0.5);
  margin-bottom: 2rem;
  overflow: hidden;
  transition: all 0.2s ease;
}

.card:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 16px rgba(0, 0, 0, 0.6);
  border-color: #2a2a2a;
}

.card-header {
  background: #141414;
  padding: 1.25rem 1.5rem;
  border-bottom: 1px solid #1f1f1f;
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.card-title {
  font-size: 1.1rem;
  font-weight: 600;
  color: #ffffff;
  display: flex;
  align-items: center;
  gap: 0.5rem;
  margin: 0;
}

.card-body {
  padding: 1.5rem;
  background: #0a0a0a;
}

/* Stats Grid Cyberpunk */
.stats-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: 1.5rem;
  margin-bottom: 2rem;
}

.stat-item {
  text-align: center;
  padding: 1.5rem;
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  border-radius: var(--border-radius);
  box-shadow: var(--box-shadow);
  transition: var(--transition);
  position: relative;
  overflow: hidden;
}

.stat-item::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 0;
  width: 100%;
  height: 2px;
  background: linear-gradient(90deg, transparent, var(--primary-color), transparent);
  animation: slide 2s linear infinite;
}

.stat-item:hover {
  transform: translateY(-2px);
  border-color: var(--primary-color);
  box-shadow: 0 4px 20px rgba(255, 107, 0, 0.3);
}

.stat-value {
  font-size: 2.5rem;
  font-weight: 900;
  font-family: 'Orbitron', monospace;
  margin-bottom: 0.5rem;
  text-shadow: 0 0 10px currentColor;
}

.stat-label {
  color: var(--text-secondary);
  font-size: 0.9rem;
  font-family: 'Rajdhani', sans-serif;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 1px;
}

.stat-primary .stat-value { color: var(--primary-color); }
.stat-success .stat-value { color: var(--success-color); text-shadow: var(--neon-green-shadow); }
.stat-warning .stat-value { color: var(--warning-color); }
.stat-danger .stat-value { color: var(--danger-color); }
.stat-info .stat-value { color: var(--info-color); text-shadow: var(--neon-blue-shadow); }

/* Tables Cyberpunk */
.table {
  width: 100%;
  border-collapse: collapse;
  margin-top: 1rem;
  font-family: 'Rajdhani', sans-serif;
}

.table th,
.table td {
  padding: 1rem;
  text-align: left;
  border-bottom: 1px solid var(--border-color);
  color: var(--text-primary);
}

.table th {
  background-color: rgba(255, 107, 0, 0.1);
  font-weight: 700;
  color: var(--primary-color);
  position: sticky;
  top: 0;
  text-transform: uppercase;
  letter-spacing: 1px;
  font-size: 0.9rem;
}

.table tbody tr:hover {
  background-color: rgba(255, 107, 0, 0.05);
  cursor: pointer;
}

/* Status Badges Cyberpunk */
.badge {
  display: inline-block;
  padding: 0.5rem 1rem;
  font-size: 0.8rem;
  font-weight: 600;
  font-family: 'Rajdhani', sans-serif;
  text-transform: uppercase;
  border-radius: 2px;
  letter-spacing: 1px;
  border: 1px solid currentColor;
  position: relative;
  overflow: hidden;
}

.badge-success { 
  background-color: rgba(0,255,136,0.1); 
  color: var(--success-color); 
  box-shadow: inset 0 0 10px rgba(0,255,136,0.3);
}
.badge-warning { 
  background-color: rgba(255,170,0,0.1); 
  color: var(--warning-color); 
}
.badge-danger { 
  background-color: rgba(255,0,68,0.1); 
  color: var(--danger-color); 
}
.badge-primary { 
  background-color: rgba(255,107,0,0.1); 
  color: var(--primary-color); 
  box-shadow: inset 0 0 10px rgba(255,107,0,0.3);
}
.badge-secondary { 
  background-color: rgba(108,117,125,0.1); 
  color: var(--text-secondary); 
}

/* Progress Bars */
.progress {
  width: 100%;
  height: 8px;
  background-color: var(--light-color);
  border-radius: 4px;
  overflow: hidden;
}

.progress-bar {
  height: 100%;
  transition: width 0.3s ease;
}

.progress-success { background-color: var(--success-color); }
.progress-warning { background-color: var(--warning-color); }
.progress-danger { background-color: var(--danger-color); }

/* Buttons Cyberpunk */
.btn {
  display: inline-block;
  padding: 0.7rem 1.5rem;
  font-size: 0.9rem;
  font-weight: 600;
  font-family: 'Rajdhani', sans-serif;
  text-align: center;
  text-decoration: none;
  border: 1px solid #2a2a2a;
  border-radius: var(--border-radius);
  cursor: pointer;
  transition: var(--transition);
  margin: 0.25rem;
  text-transform: uppercase;
  letter-spacing: 1px;
  position: relative;
  overflow: hidden;
  background: #1a1a1a;
  color: #e0e0e0;
}

.btn-primary { 
  color: #ffffff;
  border-color: var(--primary-color);
  background: var(--primary-color);
}
.btn-success { 
  color: #ffffff;
  border-color: var(--success-color);
  background: var(--success-color);
}
.btn-warning { 
  color: #000000;
  border-color: var(--warning-color);
  background: var(--warning-color);
}
.btn-danger { 
  color: #ffffff;
  border-color: var(--danger-color);
  background: var(--danger-color);
}
.btn-secondary { 
  color: #e0e0e0;
  border-color: #2a2a2a;
  background: #1a1a1a;
}

.btn:hover {
  transform: translateY(-1px);
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.3);
  filter: brightness(1.1);
}

.btn-primary:hover {
  box-shadow: 0 4px 12px rgba(255, 107, 0, 0.4);
  background: var(--primary-hover);
}

.btn-success:hover {
  box-shadow: 0 4px 12px rgba(76, 175, 80, 0.4);
  filter: brightness(1.1);
}

.btn-warning:hover {
  box-shadow: 0 4px 12px rgba(255, 152, 0, 0.4);
  filter: brightness(1.1);
}

.btn-danger:hover {
  box-shadow: 0 4px 12px rgba(244, 67, 54, 0.4);
  filter: brightness(1.1);
}

.btn-secondary:hover {
  background: #2a2a2a;
  border-color: #3a3a3a;
}

.btn::before {
  content: '';
  position: absolute;
  top: 0;
  left: -100%;
  width: 100%;
  height: 100%;
  background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.3), transparent);
  transition: left 0.5s;
}

.btn:hover::before {
  left: 100%;
}

.btn:active {
  transform: translateY(0);
}

/* Forms Cyberpunk */
.form-group {
  margin-bottom: 1.5rem;
}

.form-label {
  display: block;
  margin-bottom: 0.5rem;
  font-weight: 600;
  font-family: 'Rajdhani', sans-serif;
  color: var(--primary-color);
  text-transform: uppercase;
  letter-spacing: 1px;
  font-size: 0.9rem;
}

.form-control {
  width: 100%;
  padding: 0.7rem;
  border: 1px solid #2a2a2a;
  border-radius: var(--border-radius);
  font-size: 1rem;
  font-family: 'Rajdhani', sans-serif;
  transition: var(--transition);
  background: #1a1a1a;
  color: #e0e0e0;
}

.form-control:hover {
  border-color: #3a3a3a;
  background: #1f1f1f;
}

.form-control:focus {
  outline: none;
  border-color: var(--primary-color);
  box-shadow: 0 0 0 3px rgba(255, 107, 0, 0.1);
  background: #1f1f1f;
  color: #ffffff;
}

select.form-control {
  cursor: pointer;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 12 12'%3E%3Cpath fill='%23e0e0e0' d='M6 8L2 4h8z'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 1rem center;
  background-size: 12px;
  padding-right: 2.5rem;
  appearance: none;
}

select.form-control option {
  background: #1a1a1a;
  color: #e0e0e0;
}

/* Filters Cyberpunk */
.filters {
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  padding: 1.5rem;
  border-radius: var(--border-radius);
  box-shadow: var(--box-shadow);
  margin-bottom: 2rem;
  display: flex;
  gap: 1rem;
  align-items: end;
  flex-wrap: wrap;
}

.filter-group {
  flex: 1;
  min-width: 200px;
}

/* Drone Status */
.drone-status {
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.drone-status-icon {
  width: 12px;
  height: 12px;
  border-radius: 50%;
}

.drone-online { 
  background-color: var(--success-color); 
  box-shadow: var(--neon-green-shadow);
}
.drone-offline { 
  background-color: var(--text-muted); 
}
.drone-error { 
  background-color: var(--danger-color); 
  box-shadow: 0 0 10px var(--danger-color);
}
.drone-warning { 
  background-color: var(--warning-color); 
  box-shadow: 0 0 10px var(--warning-color);
}

/* Battery Level */
.battery-level {
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.battery-bar {
  width: 40px;
  height: 16px;
  border: 1px solid var(--border-color);
  border-radius: 2px;
  position: relative;
  background-color: var(--bg-darker);
}

.battery-fill {
  height: 100%;
  transition: var(--transition);
}

.battery-high { 
  background-color: var(--success-color); 
  box-shadow: inset 0 0 5px var(--success-color);
}
.battery-medium { 
  background-color: var(--warning-color); 
  box-shadow: inset 0 0 5px var(--warning-color);
}
.battery-low { 
  background-color: var(--danger-color); 
  box-shadow: inset 0 0 5px var(--danger-color);
}

/* Loading States */
.loading {
  text-align: center;
  padding: 3rem;
  color: var(--text-secondary);
  font-family: 'Rajdhani', sans-serif;
  text-transform: uppercase;
  letter-spacing: 1px;
}

.spinner {
  display: inline-block;
  width: 40px;
  height: 40px;
  border: 2px solid var(--border-color);
  border-top: 2px solid var(--primary-color);
  border-radius: 50%;
  animation: spin 1s linear infinite;
  box-shadow: var(--neon-orange-shadow);
}

@keyframes spin {
  0% { transform: rotate(0deg); }
  100% { transform: rotate(360deg); }
}

/* Real-time Updates */
.realtime-indicator {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  font-size: 0.8rem;
  font-family: 'Rajdhani', sans-serif;
  font-weight: 600;
  color: var(--success-color);
  margin-left: 1rem;
  text-transform: uppercase;
  letter-spacing: 1px;
  text-shadow: var(--neon-green-shadow);
}

.pulse-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background-color: var(--success-color);
  box-shadow: var(--neon-green-shadow);
  animation: pulse-neon 1.5s infinite;
}

/* Drone Cards Grid Moderne */
.drones-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(400px, 1fr));
  gap: 1.5rem;
  padding: 1rem 0;
}

.drone-card {
  background: #0f0f0f;
  border: 1px solid #1f1f1f;
  border-radius: 12px;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.4);
  overflow: hidden;
  transition: all 0.2s ease;
  display: flex;
  flex-direction: column;
}

.drone-card:hover {
  transform: translateY(-3px);
  box-shadow: 0 6px 20px rgba(0, 0, 0, 0.5);
  border-color: #2a2a2a;
}

.drone-card-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 1rem 1.25rem;
  background: #141414;
  border-bottom: 1px solid #1f1f1f;
}

.drone-info {
  flex: 1;
}

.drone-name {
  margin: 0 0 0.5rem 0;
  font-size: 1.1rem;
  font-weight: 600;
  color: #ffffff;
}

.drone-type {
  display: inline-block;
  background: rgba(255, 107, 0, 0.15);
  color: #ff6b00;
  padding: 0.25rem 0.75rem;
  border-radius: 6px;
  font-size: 0.75rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.drone-status {
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.status-indicator {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  display: inline-block;
}

.status-indicator.online {
  background: var(--success-color);
  box-shadow: 0 0 6px var(--success-color);
  animation: pulse 2s infinite;
}

.status-indicator.offline {
  background: var(--text-muted);
  animation: none;
}

.status-text {
  font-size: 0.85rem;
  font-weight: 500;
  color: #e0e0e0;
}

.drone-battery {
  display: flex;
  align-items: center;
}

.battery-card {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.5rem 0.75rem;
  border-radius: 8px;
  background: #0a0a0a;
  border: 1px solid #1f1f1f;
}

.battery-card.battery-high {
  border-left: 3px solid #4caf50;
  background: rgba(76, 175, 80, 0.1);
}

.battery-card.battery-medium {
  border-left: 3px solid #ff9800;
  background: rgba(255, 152, 0, 0.1);
}

.battery-card.battery-low {
  border-left: 3px solid #f44336;
  background: rgba(244, 67, 54, 0.1);
}

.battery-icon {
  font-size: 1.1rem;
  opacity: 0.8;
}

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

.battery-percentage {
  font-weight: 600;
  font-size: 0.95rem;
  color: #ffffff;
}

.battery-voltage {
  font-size: 0.75rem;
  color: #888;
  opacity: 0.8;
}

.no-battery {
  color: #666;
  font-size: 0.85rem;
}

/* Video Preview */
.drone-video-preview {
  position: relative;
  height: 180px;
  background: #000;
  overflow: hidden;
}

.drone-preview-frame {
  width: 100%;
  height: 100%;
  border: none;
}

/* WebRTC video elements */
.video-container-webrtc {
  position: relative;
  width: 100%;
  height: 100%;
  background: #000;
  overflow: hidden;
}

.drone-preview-video {
  width: 100%;
  height: 100%;
  object-fit: cover;
  background: #1a1a2e;
}

.drone-video-element {
  width: 100%;
  height: 100%;
  object-fit: contain;
  background: #000;
}

.video-error-overlay {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(0, 0, 0, 0.7);
  color: #888;
  font-size: 0.9rem;
}

.video-overlay {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  pointer-events: none;
  background: linear-gradient(to bottom, rgba(0,0,0,0.3) 0%, transparent 30%, transparent 70%, rgba(0,0,0,0.3) 100%);
}

.live-badge {
  position: absolute;
  top: 10px;
  right: 10px;
  background: #ff4444;
  color: white;
  padding: 0.25rem 0.5rem;
  border-radius: 12px;
  font-size: 0.7rem;
  font-weight: bold;
  animation: blink 1.5s infinite;
}

@keyframes blink {
  0%, 100% { opacity: 1; }
  50% { opacity: 0.7; }
}

.no-video-preview {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  height: 100%;
  color: #666;
  background: #050505;
  font-size: 0.85rem;
}

.no-video-icon {
  font-size: 2.5rem;
  margin-bottom: 0.5rem;
  opacity: 0.3;
}

/* Card Footer */
.drone-card-footer {
  padding: 1rem 1.25rem;
  background: #0a0a0a;
  border-top: 1px solid #1a1a1a;
  flex: 1;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
}

.drone-meta {
  margin-bottom: 1rem;
}

.meta-item {
  display: flex;
  justify-content: space-between;
  padding: 0.4rem 0;
  font-size: 0.85rem;
  border-bottom: 1px solid #1a1a1a;
}

.meta-item:last-child {
  border-bottom: none;
}

.meta-label {
  color: #777;
  font-weight: 500;
  font-size: 0.8rem;
}

.meta-value {
  font-weight: 500;
  color: #e0e0e0;
}

.drone-actions {
  display: flex;
  gap: 0.5rem;
  margin-top: 1rem;
  padding-top: 1rem;
}

.btn-video, .btn-details {
  flex: 1;
  padding: 0.6rem 1rem;
  border: none;
  border-radius: 8px;
  font-size: 0.85rem;
  font-weight: 500;
  cursor: pointer;
  transition: all 0.2s ease;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.4rem;
}

.btn-video {
  background: #1a1a1a;
  color: #2196f3;
  border: 1px solid #2196f3;
}

.btn-video:hover {
  background: #2196f3;
  color: white;
  transform: translateY(-1px);
  box-shadow: 0 4px 12px rgba(33, 150, 243, 0.3);
}

.btn-details {
  background: #ff6b00;
  color: white;
  border: 1px solid #ff6b00;
}

.btn-details:hover {
  background: #ff8533;
  transform: translateY(-1px);
  box-shadow: 0 4px 12px rgba(255, 107, 0, 0.3);
}

/* ============================================
   RESPONSIVE COMPONENTS - Mobile First
   ============================================ */

/* Stats Grid */
.stats-grid {
  grid-template-columns: repeat(2, 1fr);
  gap: 0.75rem;
}

@media (min-width: 768px) {
  .stats-grid {
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 1rem;
  }
}

@media (min-width: 1024px) {
  .stats-grid {
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 1.5rem;
  }
}

/* Stat Items - Mobile */
.stat-item {
  padding: 1rem 0.75rem;
}

.stat-value {
  font-size: 1.8rem;
}

.stat-label {
  font-size: 0.75rem;
}

@media (min-width: 768px) {
  .stat-item {
    padding: 1.25rem;
  }
  .stat-value {
    font-size: 2.2rem;
  }
  .stat-label {
    font-size: 0.85rem;
  }
}

@media (min-width: 1024px) {
  .stat-item {
    padding: 1.5rem;
  }
  .stat-value {
    font-size: 2.5rem;
  }
  .stat-label {
    font-size: 0.9rem;
  }
}

/* Filters - Mobile first */
.filters {
  flex-direction: column;
  align-items: stretch;
  padding: 1rem;
  gap: 0.75rem;
}

.filter-group {
  min-width: auto;
  width: 100%;
}

@media (min-width: 768px) {
  .filters {
    flex-direction: row;
    flex-wrap: wrap;
    padding: 1.25rem;
    gap: 1rem;
    align-items: end;
  }
  .filter-group {
    flex: 1;
    min-width: 180px;
    width: auto;
  }
}

@media (min-width: 1024px) {
  .filters {
    padding: 1.5rem;
  }
  .filter-group {
    min-width: 200px;
  }
}

/* Cards - Mobile first */
.card {
  margin-bottom: 1rem;
}

.card-header {
  padding: 1rem;
}

.card-body {
  padding: 1rem;
}

@media (min-width: 768px) {
  .card {
    margin-bottom: 1.5rem;
  }
  .card-header {
    padding: 1.25rem 1.5rem;
  }
  .card-body {
    padding: 1.5rem;
  }
}

/* Drones Grid - Mobile first */
.drones-grid {
  grid-template-columns: 1fr;
  gap: 1rem;
}

@media (min-width: 768px) {
  .drones-grid {
    grid-template-columns: repeat(auto-fit, minmax(350px, 1fr));
    gap: 1.25rem;
  }
}

@media (min-width: 1024px) {
  .drones-grid {
    grid-template-columns: repeat(auto-fit, minmax(400px, 1fr));
    gap: 1.5rem;
  }
}

/* Table responsive */
.table-responsive {
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
}

/* Tab Content Cyberpunk */
.tab-content {
  display: none;
}

.tab-content.active {
  display: block;
  animation: fadeIn 0.3s ease, scanlines 8s linear infinite;
  position: relative;
}

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

@keyframes scanlines {
  0% { background-position: 0 0; }
  100% { background-position: 0 10px; }
}

/* Session Controls */
.session-controls {
  display: flex;
  gap: 0.5rem;
  flex-wrap: wrap;
}

/* Video Stream */
.video-stream {
  width: 100%;
  max-width: 400px;
  border-radius: var(--border-radius);
  box-shadow: var(--box-shadow);
}

.stream-placeholder {
  width: 100%;
  height: 200px;
  background: linear-gradient(135deg, var(--light-color), #dee2e6);
  border-radius: var(--border-radius);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--secondary-color);
  font-style: italic;
}

/* Error Messages */
.error-message {
  background-color: rgba(220,53,69,0.1);
  color: var(--danger-color);
  padding: 1rem;
  border-radius: var(--border-radius);
  border-left: 4px solid var(--danger-color);
  margin-bottom: 1rem;
}

.success-message {
  background-color: rgba(40,167,69,0.1);
  color: var(--success-color);
  padding: 1rem;
  border-radius: var(--border-radius);
  border-left: 4px solid var(--success-color);
  margin-bottom: 1rem;
}

/* Modal Styles */
.modal-overlay {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: rgba(0, 0, 0, 0.7);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 2000;
  padding: 20px;
}

.modal-content {
  background: var(--card-bg);
  border-radius: var(--border-radius);
  box-shadow: var(--shadow);
  max-width: 800px;
  width: 100%;
  max-height: 90vh;
  overflow-y: auto;
}

.modal-header {
  padding: 1.5rem;
  border-bottom: 1px solid var(--border-color);
  display: flex;
  justify-content: between;
  align-items: center;
  background: var(--primary-color);
  color: white;
  border-radius: var(--border-radius) var(--border-radius) 0 0;
}

.modal-header h3 {
  margin: 0;
  flex: 1;
}

.modal-close {
  background: none;
  border: none;
  color: white;
  font-size: 1.5rem;
  cursor: pointer;
  padding: 0;
  margin-left: 1rem;
  width: 30px;
  height: 30px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
}

.modal-close:hover {
  background: rgba(255, 255, 255, 0.2);
}

.modal-body {
  padding: 1.5rem;
}

/* Drone Details Grid */
.drone-details-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 1.5rem;
}

.detail-section {
  background: var(--light-color);
  padding: 1rem;
  border-radius: var(--border-radius);
  border-left: 4px solid var(--primary-color);
}

.detail-section h4 {
  margin: 0 0 1rem 0;
  color: var(--primary-color);
  font-size: 1.1rem;
}

.detail-section p {
  margin: 0.5rem 0;
  line-height: 1.4;
}

.detail-section strong {
  color: var(--text-color);
  font-weight: 600;
}

/* Battery Display */
.battery-level {
  display: flex;
  align-items: center;
  gap: 8px;
}

.battery-bar {
  width: 60px;
  height: 20px;
  background: #e0e0e0;
  border-radius: 10px;
  border: 2px solid #ccc;
  overflow: hidden;
  position: relative;
}

.battery-fill {
  height: 100%;
  transition: width 0.3s ease;
  border-radius: 8px;
}

.battery-high {
  background: linear-gradient(90deg, #4CAF50, #66BB6A);
}

.battery-medium {
  background: linear-gradient(90deg, #FF9800, #FFB74D);
}

.battery-low {
  background: linear-gradient(90deg, #F44336, #EF5350);
}

/* Drone Status */
.drone-status {
  display: flex;
  align-items: center;
  gap: 8px;
}

.drone-status-icon {
  width: 12px;
  height: 12px;
  border-radius: 50%;
  display: inline-block;
}

.drone-online {
  background: var(--success-color);
  box-shadow: 0 0 4px var(--success-color);
}

.drone-offline {
  background: var(--secondary-color);
}

/* Drone Controls */
.drone-controls {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
}

.drone-controls .btn {
  font-size: 0.8rem;
  padding: 0.4rem 0.8rem;
}

/* Responsive modal */
@media (max-width: 768px) {
  .modal-overlay {
    padding: 10px;
  }
  
  .drone-details-grid {
    grid-template-columns: 1fr;
    gap: 1rem;
  }
  
  .modal-header {
    padding: 1rem;
  }
  
  .modal-body {
    padding: 1rem;
  }
  
  .drone-controls {
    justify-content: center;
  }
}

/* Drone Details Modal - Design Moderne */
.drone-details-modal {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: rgba(0, 0, 0, 0.95);
  z-index: 3000;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 20px;
  backdrop-filter: blur(5px);
}

.drone-details-container {
  background: #0a0a0a;
  border: 1px solid #1f1f1f;
  border-radius: 16px;
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.5);
  width: 100%;
  max-width: 1400px;
  height: 90vh;
  display: flex;
  flex-direction: column;
  overflow: hidden;
}

.drone-details-header {
  background: #141414;
  color: #ffffff;
  padding: 1.5rem;
  display: flex;
  justify-content: space-between;
  align-items: center;
  border-bottom: 1px solid #1f1f1f;
}

.drone-title {
  display: flex;
  align-items: center;
  gap: 1rem;
}

.drone-avatar {
  width: 50px;
  height: 50px;
  background: #1f1f1f;
  border: 2px solid #ff6b00;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.5rem;
}

.drone-info h2 {
  margin: 0 0 0.5rem 0;
  font-size: 1.4rem;
  font-weight: 600;
  color: #ffffff;
}

.drone-meta {
  display: flex;
  gap: 1rem;
  align-items: center;
}

.drone-status-badge {
  font-size: 0.75rem;
  padding: 0.25rem 0.75rem;
  border-radius: 6px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.drone-connection {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  font-size: 0.85rem;
}

.connection-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: currentColor;
}

.drone-connection.online {
  color: #4caf50;
}

.drone-connection.offline {
  color: #999;
}

.btn-outline {
  background: transparent;
  border: 1px solid #2a2a2a;
  color: #e0e0e0;
  padding: 0.5rem 1rem;
  border-radius: 6px;
  font-size: 0.85rem;
  cursor: pointer;
  transition: all 0.2s ease;
}

.btn-outline:hover {
  background: #1f1f1f;
  border-color: #ff6b00;
  color: #ff6b00;
}

.btn-close {
  background: #1f1f1f;
  color: #999;
  border: 1px solid #2a2a2a;
  width: 36px;
  height: 36px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  font-size: 1.2rem;
  transition: all 0.2s ease;
}

.btn-close:hover {
  background: #ff6b00;
  color: white;
  border-color: #ff6b00;
  transform: scale(1.05);
}

.drone-details-content {
  flex: 1;
  display: grid;
  grid-template-columns: 400px 1fr;
  grid-template-rows: 450px auto;
  gap: 0;
  overflow-y: auto;
  background: #0a0a0a;
}

.drone-map-panel,
.drone-video-panel,
.drone-controls-panel,
.drone-telemetry-panel {
  padding: 1.5rem;
}

.drone-map-panel {
  background: #0f0f0f;
  border-right: 1px solid #1a1a1a;
  border-bottom: 1px solid #1a1a1a;
}

.drone-video-panel {
  background: #000;
  border-bottom: 1px solid #1a1a1a;
}

.drone-controls-panel {
  background: #0f0f0f;
  border-right: 1px solid #1a1a1a;
}

.drone-telemetry-panel {
  background: #0a0a0a;
}

.video-header h3,
.map-header h3 {
  margin: 0;
  font-size: 1rem;
  color: #ffffff;
  font-weight: 600;
}

.video-controls,
.map-controls {
  display: flex;
  gap: 0.5rem;
}

.video-container {
  position: relative;
  background: #000;
  border-radius: 8px;
  border: 1px solid #1a1a1a;
  overflow: hidden;
  aspect-ratio: 16/9;
  min-height: 200px;
}

.drone-video-frame {
  width: 100%;
  height: 100%;
  border: none;
}

.video-overlay {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  pointer-events: none;
}

.video-info {
  position: absolute;
  top: 10px;
  left: 10px;
  display: flex;
  gap: 10px;
}

.live-indicator {
  background: #f44336;
  color: white;
  padding: 0.25rem 0.6rem;
  border-radius: 6px;
  font-size: 0.7rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.video-quality {
  background: rgba(0, 0, 0, 0.8);
  color: #e0e0e0;
  padding: 0.25rem 0.6rem;
  border-radius: 6px;
  font-size: 0.7rem;
  backdrop-filter: blur(10px);
}

.no-video {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  height: 100%;
  color: #666;
  background: #050505;
}

.drone-controls-section h3 {
  margin-bottom: 1rem;
  font-size: 1rem;
  color: #ffffff;
  font-weight: 600;
}

.controls-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1rem;
}

.control-btn {
  background: #1a1a1a;
  border: 1px solid #2a2a2a;
  border-radius: 8px;
  padding: 1rem;
  cursor: pointer;
  transition: all 0.2s ease;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.5rem;
  text-align: center;
  color: #e0e0e0;
}

.control-btn:hover {
  transform: translateY(-2px);
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.3);
  background: #1f1f1f;
}

.control-btn.takeoff:hover {
  border-color: #4caf50;
  color: #4caf50;
  background: rgba(76, 175, 80, 0.1);
}

.control-btn.land:hover {
  border-color: #ff9800;
  color: #ff9800;
  background: rgba(255, 152, 0, 0.1);
}

.control-btn.home:hover {
  border-color: #ff6b00;
  color: #ff6b00;
  background: rgba(255, 107, 0, 0.1);
}

.control-btn.emergency:hover {
  border-color: #f44336;
  color: #f44336;
  animation: shake 0.5s;
  background: rgba(244, 67, 54, 0.1);
}

.control-icon {
  font-size: 1.5rem;
}

.map-container {
  position: relative;
  background: #000;
  border: 1px solid #1a1a1a;
  border-radius: 8px;
  overflow: hidden;
  height: calc(100% - 60px);
  min-height: 300px;
}

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

.map-overlay {
  position: absolute;
  bottom: 10px;
  left: 10px;
  right: 10px;
  pointer-events: none;
}

.coordinates {
  background: rgba(0, 0, 0, 0.8);
  color: #e0e0e0;
  border: 1px solid #2a2a2a;
  padding: 0.5rem 1rem;
  border-radius: 6px;
  font-family: 'Courier New', monospace;
  font-size: 0.85rem;
  display: inline-block;
  backdrop-filter: blur(10px);
}

.telemetry-section h3,
.specs-section h3 {
  margin-bottom: 1.25rem;
  font-size: 1rem;
  color: #ffffff;
  font-weight: 600;
}

.telemetry-grid {
  display: flex;
  flex-direction: column;
  gap: 1rem;
  margin-bottom: 2rem;
}

.telemetry-item {
  background: #141414;
  border: 1px solid #1f1f1f;
  border-radius: 8px;
  padding: 1rem;
  display: flex;
  align-items: center;
  gap: 1rem;
  transition: all 0.2s ease;
}

.telemetry-item:hover {
  transform: translateY(-1px);
  background: #1a1a1a;
  border-color: #2a2a2a;
}

.telemetry-icon {
  width: 36px;
  height: 36px;
  background: #1f1f1f;
  color: #ff6b00;
  border: 1px solid #2a2a2a;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1rem;
  flex-shrink: 0;
}

.telemetry-content {
  flex: 1;
}

.telemetry-label {
  font-size: 0.75rem;
  color: #777;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  margin-bottom: 0.2rem;
}

.telemetry-value {
  font-size: 1rem;
  font-weight: 600;
  color: #ffffff;
  font-variant-numeric: tabular-nums;
}

.telemetry-item.battery .telemetry-icon {
  color: #4caf50;
  background: rgba(76, 175, 80, 0.1);
}

.telemetry-item.altitude .telemetry-icon {
  color: #2196f3;
  background: rgba(33, 150, 243, 0.1);
}

.telemetry-item.speed .telemetry-icon {
  color: #ff9800;
  background: rgba(255, 152, 0, 0.1);
}

.telemetry-item.heading .telemetry-icon {
  color: #9c27b0;
  background: rgba(156, 39, 176, 0.1);
}

.no-telemetry {
  text-align: center;
  padding: 2rem;
  color: #666;
  font-size: 0.9rem;
}

.specs-grid {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}

.spec-item {
  display: flex;
  justify-content: space-between;
  padding: 0.5rem 0;
  border-bottom: 1px solid #1a1a1a;
}

.spec-item:last-child {
  border-bottom: none;
}

.spec-label {
  color: #777;
  font-size: 0.85rem;
}

.spec-value {
  font-weight: 500;
  color: #e0e0e0;
}

.no-specs {
  text-align: center;
  padding: 2rem;
  color: #666;
  font-style: italic;
}

/* New Sexy Drone Details Modal */
.drone-details-modal {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: rgba(0, 0, 0, 0.9);
  z-index: 3000;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 20px;
}

.drone-details-modal.fullscreen {
  padding: 0;
}

.drone-details-container {
  background: var(--card-bg);
  border-radius: 16px;
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.3);
  width: 100%;
  max-width: 1400px;
  height: 90vh;
  display: flex;
  flex-direction: column;
  overflow-y: auto;
}

.drone-details-modal.fullscreen .drone-details-container {
  width: 100vw;
  height: 100vh;
  max-width: none;
  border-radius: 0;
}

/* Header */
.drone-details-header {
  background: linear-gradient(135deg, var(--primary-color), #4a90e2);
  color: white;
  padding: 1.5rem;
  display: flex;
  justify-content: space-between;
  align-items: center;
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
}

.drone-title {
  display: flex;
  align-items: center;
  gap: 1rem;
}

.drone-avatar {
  width: 60px;
  height: 60px;
  background: rgba(255, 255, 255, 0.2);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.8rem;
}

.drone-info h2 {
  margin: 0 0 0.5rem 0;
  font-size: 1.6rem;
  font-weight: 700;
}

.drone-meta {
  display: flex;
  gap: 1rem;
  align-items: center;
}

.drone-status-badge {
  font-size: 0.8rem;
  padding: 0.3rem 0.8rem;
}

.drone-connection {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  font-size: 0.9rem;
}

.connection-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: currentColor;
}

.drone-connection.online {
  color: #4CAF50;
}

.drone-connection.offline {
  color: #f44336;
}

.drone-connection.online .connection-dot {
  animation: pulse 2s infinite;
}

@keyframes pulse {
  0%, 100% { opacity: 1; transform: scale(1); }
  50% { opacity: 0.7; transform: scale(1.2); }
}

.drone-type {
  background: rgba(255, 255, 255, 0.2);
  padding: 0.3rem 0.8rem;
  border-radius: 12px;
  font-size: 0.8rem;
}

.drone-actions {
  display: flex;
  gap: 0.5rem;
}

.btn-close {
  background: rgba(255, 255, 255, 0.2);
  color: white;
  border: none;
  width: 40px;
  height: 40px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  font-size: 1.5rem;
  transition: all 0.3s ease;
}

.btn-close:hover {
  background: rgba(255, 255, 255, 0.3);
  transform: scale(1.1);
}

/* Content Layout */
.drone-details-content {
  flex: 1;
  display: grid;
  grid-template-columns: 400px 1fr;
  grid-template-rows: 450px auto;
  gap: 0;
  overflow: visible;
  min-height: 100vh;
}

/* Panel arrangement:
   Top-left: Map (400px x 450px)
   Top-right: Video (flexible x 450px)
   Bottom-left: Controls (400px x auto)
   Bottom-right: Telemetry (flexible x auto)
*/

.drone-map-panel {
  grid-column: 1;
  grid-row: 1;
}

.drone-video-panel {
  grid-column: 2;
  grid-row: 1;
}

.drone-controls-panel {
  grid-column: 1;
  grid-row: 2;
}

.drone-telemetry-panel {
  grid-column: 2;
  grid-row: 2;
}

.drone-map-panel,
.drone-telemetry-panel,
.drone-controls-panel,
.drone-video-panel {
  overflow: visible;
  padding: 1.5rem;
}

.drone-map-panel {
  background: var(--light-color);
  border-right: 1px solid var(--border-color);
  border-bottom: 1px solid var(--border-color);
}

.drone-video-panel {
  background: var(--surface-color);
  border-bottom: 1px solid var(--border-color);
}

.drone-controls-panel {
  background: var(--light-color);
  border-right: 1px solid var(--border-color);
}

.drone-telemetry-panel {
  background: var(--surface-color);
}

/* Video Section */
.video-section {
  margin-bottom: 2rem;
}

.video-header,
.map-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 1rem;
}

.video-header h3,
.map-header h3 {
  margin: 0;
  font-size: 1.1rem;
  color: var(--primary-color);
}

.video-controls,
.map-controls {
  display: flex;
  gap: 0.5rem;
}

.video-container {
  position: relative;
  background: #000;
  border-radius: 12px;
  overflow: hidden;
  aspect-ratio: 16/9;
  min-height: 200px;
}

.drone-video-frame {
  width: 100%;
  height: 100%;
  border: none;
}

.video-overlay {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  pointer-events: none;
  background: linear-gradient(to bottom, rgba(0,0,0,0.5) 0%, transparent 30%, transparent 70%, rgba(0,0,0,0.5) 100%);
}

.video-info {
  position: absolute;
  top: 10px;
  left: 10px;
  display: flex;
  gap: 10px;
}

.live-indicator {
  background: #f44336;
  color: white;
  padding: 0.3rem 0.8rem;
  border-radius: 20px;
  font-size: 0.8rem;
  font-weight: bold;
}

.video-quality {
  background: rgba(0, 0, 0, 0.7);
  color: white;
  padding: 0.3rem 0.8rem;
  border-radius: 20px;
  font-size: 0.8rem;
}

.no-video {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  height: 100%;
  color: #666;
}

.no-video-icon {
  font-size: 3rem;
  margin-bottom: 1rem;
  opacity: 0.5;
}

/* Flight Controls */
.drone-controls-section h3 {
  margin-bottom: 1rem;
  font-size: 1.1rem;
  color: var(--primary-color);
}

.controls-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1rem;
}

.control-btn {
  background: white;
  border: 2px solid var(--border-color);
  border-radius: 12px;
  padding: 1rem;
  cursor: pointer;
  transition: all 0.3s ease;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.5rem;
  text-align: center;
}

.control-btn:hover {
  transform: translateY(-2px);
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
}

.control-btn.takeoff:hover {
  border-color: var(--success-color);
  color: var(--success-color);
  box-shadow: var(--neon-green-shadow);
}

.control-btn.land:hover {
  border-color: var(--warning-color);
  color: var(--warning-color);
  box-shadow: 0 0 10px var(--warning-color);
}

.control-btn.home:hover {
  border-color: var(--primary-color);
  color: var(--primary-color);
}

.control-btn.emergency:hover {
  border-color: var(--danger-color);
  color: var(--danger-color);
  animation: shake 0.5s;
  box-shadow: 0 0 20px var(--danger-color);
}

@keyframes shake {
  0%, 100% { transform: translateX(0); }
  25% { transform: translateX(-5px); }
  75% { transform: translateX(5px); }
}

.control-icon {
  font-size: 1.5rem;
}

/* Map Section */
.map-section {
  height: 100%;
}

.map-container {
  position: relative;
  background: var(--bg-darker);
  border: 1px solid var(--border-color);
  border-radius: var(--border-radius);
  overflow: hidden;
  height: calc(100vh - 200px);
  min-height: 400px;
}

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

.map-overlay {
  position: absolute;
  bottom: 10px;
  left: 10px;
  right: 10px;
  pointer-events: none;
}

.coordinates {
  background: var(--bg-darker);
  color: var(--primary-color);
  border: 1px solid var(--primary-color);
  padding: 0.5rem 1rem;
  border-radius: var(--border-radius);
  font-family: 'Courier New', monospace;
  font-size: 0.9rem;
  display: inline-block;
  text-shadow: 0 0 5px var(--primary-color);
}

.simple-map {
  width: 100%;
  height: 100%;
  background: 
    linear-gradient(rgba(255, 107, 0, 0.1) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255, 107, 0, 0.1) 1px, transparent 1px);
  background-size: var(--grid-size) var(--grid-size);
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
}

.drone-marker-simple {
  font-size: 2rem;
  animation: bounce 2s infinite;
}

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

.map-info {
  position: absolute;
  bottom: 20px;
  left: 20px;
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  padding: 1rem;
  border-radius: var(--border-radius);
  font-size: 0.9rem;
  font-family: 'Rajdhani', sans-serif;
}

.map-note {
  color: var(--text-secondary);
  font-size: 0.8rem;
  margin-top: 0.5rem;
  font-style: italic;
}

/* Telemetry Section */
.telemetry-section h3,
.specs-section h3 {
  margin-bottom: 1.5rem;
  font-size: 1.1rem;
  font-family: 'Orbitron', monospace;
  color: var(--primary-color);
  text-transform: uppercase;
  letter-spacing: 1px;
}

.telemetry-grid {
  display: flex;
  flex-direction: column;
  gap: 1rem;
  margin-bottom: 2rem;
}

.telemetry-item {
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  border-radius: var(--border-radius);
  padding: 1rem;
  display: flex;
  align-items: center;
  gap: 1rem;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.5);
  transition: all 0.3s ease;
}

.telemetry-item:hover {
  transform: translateY(-2px);
  box-shadow: 0 4px 16px rgba(255, 107, 0, 0.3);
  border-color: var(--primary-color);
}

.telemetry-icon {
  width: 40px;
  height: 40px;
  background: transparent;
  color: var(--primary-color);
  border: 2px solid var(--primary-color);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.2rem;
  flex-shrink: 0;
  box-shadow: inset 0 0 10px rgba(255, 107, 0, 0.3);
}

.telemetry-content {
  flex: 1;
}

.telemetry-label {
  font-size: 0.8rem;
  color: var(--text-secondary);
  font-family: 'Rajdhani', sans-serif;
  text-transform: uppercase;
  letter-spacing: 1px;
  margin-bottom: 0.2rem;
}

.telemetry-value {
  font-size: 1.1rem;
  font-weight: 700;
  font-family: 'Orbitron', monospace;
  color: var(--text-primary);
}

.telemetry-item.battery .telemetry-icon {
  color: var(--success-color);
  border-color: var(--success-color);
  box-shadow: inset 0 0 10px rgba(0, 255, 136, 0.3);
}

.telemetry-item.altitude .telemetry-icon {
  color: var(--info-color);
  border-color: var(--info-color);
  box-shadow: inset 0 0 10px rgba(0, 170, 255, 0.3);
}

.telemetry-item.speed .telemetry-icon {
  color: var(--warning-color);
  border-color: var(--warning-color);
  box-shadow: inset 0 0 10px rgba(255, 170, 0, 0.3);
}

.telemetry-item.heading .telemetry-icon {
  color: #9C27B0;
  border-color: #9C27B0;
  box-shadow: inset 0 0 10px rgba(156, 39, 176, 0.3);
}

.no-telemetry {
  text-align: center;
  padding: 2rem;
  color: var(--text-secondary);
  font-style: italic;
  font-family: 'Rajdhani', sans-serif;
  text-transform: uppercase;
  letter-spacing: 1px;
}

/* Specs Section */
.specs-grid {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}

.spec-item {
  display: flex;
  justify-content: space-between;
  padding: 0.5rem 0;
  border-bottom: 1px solid var(--border-color);
}

.spec-item:last-child {
  border-bottom: none;
}

.spec-label {
  color: #666;
  font-size: 0.9rem;
}

.spec-value {
  font-weight: 600;
  color: var(--text-color);
}

.no-specs {
  text-align: center;
  padding: 2rem;
  color: #666;
  font-style: italic;
}

/* Responsive Design */
@media (max-width: 1200px) {
  .drone-details-content {
    grid-template-columns: 300px 1fr 280px;
  }
}

@media (max-width: 1000px) {
  .drone-details-content {
    grid-template-columns: 1fr;
    grid-template-rows: auto auto auto;
  }
  
  .drone-left-panel,
  .drone-right-panel {
    border: none;
    border-top: 1px solid var(--border-color);
  }
  
  .controls-grid {
    grid-template-columns: repeat(4, 1fr);
  }
  
  .map-container {
    height: 300px;
  }
}

@media (max-width: 768px) {
  .drone-details-modal {
    padding: 0;
  }
  
  .drone-details-container {
    width: 100vw;
    height: 100vh;
    border-radius: 0;
  }
  
  .drone-details-header {
    padding: 1rem;
  }
  
  .drone-title {
    gap: 0.5rem;
  }
  
  .drone-avatar {
    width: 45px;
    height: 45px;
    font-size: 1.4rem;
  }
  
  .drone-info h2 {
    font-size: 1.3rem;
  }
  
  .controls-grid {
    grid-template-columns: 1fr 1fr;
  }
  
  .drone-left-panel,
  .drone-center-panel,
  .drone-right-panel {
    padding: 1rem;
  }
}