/* 🔧 DEBUG TOGGLE & PANEL STYLES */

/* Debug Toggle Button */
.debug-toggle {
  position: fixed;
  top: 15px;
  right: 15px;
  width: 45px;
  height: 45px;
  border-radius: 50%;
  background: linear-gradient(135deg, #007bff, #0056b3);
  color: white;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  z-index: 10001; /* Über allem anderen */
  box-shadow: 0 4px 12px rgba(0, 123, 255, 0.3);
  transition: all 0.3s ease;
  user-select: none;
  border: 2px solid rgba(255, 255, 255, 0.2);
}

.debug-toggle:hover {
  background: linear-gradient(135deg, #0056b3, #004085);
  transform: scale(1.1);
  box-shadow: 0 6px 16px rgba(0, 123, 255, 0.4);
}

.debug-toggle.active {
  background: linear-gradient(135deg, #28a745, #1e7e34);
  box-shadow: 0 4px 12px rgba(40, 167, 69, 0.3);
}

.debug-toggle.active:hover {
  background: linear-gradient(135deg, #1e7e34, #155724);
  box-shadow: 0 6px 16px rgba(40, 167, 69, 0.4);
}

.debug-toggle span {
  font-size: 20px;
  line-height: 1;
}

/* Debug Panel Overlay */
.debug-panel {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(0, 0, 0, 0.7);
  z-index: 10000;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 20px;
  box-sizing: border-box;
}

.debug-panel-content {
  background: #ffffff;
  border-radius: 12px;
  box-shadow: 0 20px 40px rgba(0, 0, 0, 0.3);
  max-width: 1200px;
  max-height: 90vh;
  width: 100%;
  overflow: hidden;
  position: relative;
  display: flex;
  flex-direction: column;
}

.debug-panel-header {
  background: linear-gradient(135deg, #007bff, #0056b3);
  color: white;
  padding: 20px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  border-radius: 12px 12px 0 0;
}

.debug-panel-header h3 {
  margin: 0;
  font-size: 24px;
  font-weight: 600;
}

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

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

.debug-panel-scrollable {
  padding: 20px;
  overflow-y: auto;
  flex: 1;
}

.debug-panel-content > div {
  padding: 20px;
  overflow-y: auto;
  flex: 1;
}

/* Admin Sections in Debug Panel */
.admin-section {
  margin-bottom: 30px;
  padding: 20px;
  background: #f8f9fa;
  border-radius: 8px;
  border-left: 4px solid #007bff;
}

.admin-section h3 {
  margin: 0 0 15px 0;
  color: #2c3e50;
  font-size: 18px;
  font-weight: 600;
}

.admin-section h4 {
  margin: 15px 0 10px 0;
  color: #495057;
  font-size: 16px;
  font-weight: 500;
}

/* Button Groups */
.btn-group {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-bottom: 15px;
}

.btn {
  padding: 8px 16px;
  border: none;
  border-radius: 6px;
  cursor: pointer;
  font-size: 14px;
  font-weight: 500;
  transition: all 0.3s ease;
  text-decoration: none;
  display: inline-flex;
  align-items: center;
  gap: 6px;
}

.btn-success {
  background: #28a745;
  color: white;
}

.btn-success:hover {
  background: #218838;
  transform: translateY(-1px);
}

.btn-info {
  background: #17a2b8;
  color: white;
}

.btn-info:hover {
  background: #138496;
  transform: translateY(-1px);
}

.btn-warning {
  background: #ffc107;
  color: #212529;
}

.btn-warning:hover {
  background: #e0a800;
  transform: translateY(-1px);
}

.btn-danger {
  background: #dc3545;
  color: white;
}

.btn-danger:hover {
  background: #c82333;
  transform: translateY(-1px);
}

.btn-primary {
  background: #007bff;
  color: white;
}

.btn-primary:hover {
  background: #0056b3;
  transform: translateY(-1px);
}

.btn-outline-primary {
  background: transparent;
  color: #007bff;
  border: 1px solid #007bff;
}

.btn-outline-primary:hover {
  background: #007bff;
  color: white;
}

.btn-outline-secondary {
  background: transparent;
  color: #6c757d;
  border: 1px solid #6c757d;
}

.btn-outline-secondary:hover {
  background: #6c757d;
  color: white;
}

.btn-outline-info {
  background: transparent;
  color: #17a2b8;
  border: 1px solid #17a2b8;
}

.btn-outline-info:hover {
  background: #17a2b8;
  color: white;
}

.btn-sm {
  padding: 6px 12px;
  font-size: 12px;
}

/* Debug Console */
.debug-console {
  background: #2c3e50;
  border-radius: 6px;
  overflow: hidden;
}

.debug-output {
  background: #34495e;
  color: #ecf0f1;
  padding: 15px;
  min-height: 200px;
  max-height: 300px;
  overflow-y: auto;
  font-family: 'Courier New', monospace;
  font-size: 13px;
  line-height: 1.4;
  white-space: pre-wrap;
}

.debug-input-group {
  display: flex;
  padding: 10px;
  background: #2c3e50;
}

.debug-input {
  flex: 1;
  padding: 10px;
  border: none;
  border-radius: 4px 0 0 4px;
  background: #ecf0f1;
  color: #2c3e50;
  font-family: 'Courier New', monospace;
  font-size: 13px;
}

.debug-input:focus {
  outline: none;
  background: #ffffff;
}

.debug-input-group .btn {
  border-radius: 0 4px 4px 0;
  margin: 0;
}

/* Network Diagnostic */
.diagnostic-output {
  background: #f8f9fa;
  border: 1px solid #dee2e6;
  border-radius: 4px;
  padding: 15px;
  margin-top: 10px;
  min-height: 100px;
  font-family: 'Courier New', monospace;
  font-size: 13px;
  white-space: pre-wrap;
  color: #495057;
}

/* System Info */
#systemInfo p {
  margin: 8px 0;
  padding: 8px 12px;
  background: white;
  border-radius: 4px;
  border-left: 3px solid #007bff;
}

#systemInfo strong {
  color: #2c3e50;
  min-width: 120px;
  display: inline-block;
}

/* Responsive Design */
@media (max-width: 768px) {
  .debug-panel {
    padding: 10px;
  }
  
  .debug-panel-content {
    max-height: 95vh;
  }
  
  .debug-panel-header {
    padding: 15px;
  }
  
  .debug-panel-header h3 {
    font-size: 20px;
  }
  
  .admin-section {
    padding: 15px;
    margin-bottom: 20px;
  }
  
  .btn-group {
    flex-direction: column;
  }
  
  .btn {
    width: 100%;
    justify-content: center;
  }
  
  .debug-toggle {
    top: 10px;
    right: 10px;
    width: 40px;
    height: 40px;
  }
  
  .debug-toggle span {
    font-size: 18px;
  }
}

/* Dark Mode Support */
body.dark-mode .debug-panel-content {
  background: #2c3e50;
  color: #ecf0f1;
}

body.dark-mode .admin-section {
  background: #34495e;
  border-left-color: #3498db;
}

body.dark-mode .admin-section h3,
body.dark-mode .admin-section h4 {
  color: #ecf0f1;
}

body.dark-mode .debug-input {
  background: #34495e;
  color: #ecf0f1;
}

body.dark-mode .debug-input:focus {
  background: #2c3e50;
}

body.dark-mode .diagnostic-output {
  background: #34495e;
  border-color: #495057;
  color: #ecf0f1;
}

body.dark-mode #systemInfo p {
  background: #34495e;
  border-left-color: #3498db;
  color: #ecf0f1;
} 