/**
 * DWD Unwetterwarnungen & Section Navigation
 * DUNKLES DESIGN passend zur Klima-Page
 */

/* ========================================
   SECTION NAVIGATION - Sprungmarken
   ======================================== */

.section-nav {
  display: flex;
  flex-wrap: wrap;
  gap: 15px;
  justify-content: center;
  padding: 25px 20px;
  margin: 20px auto;
  max-width: 1200px;
  background: rgba(20, 20, 20, 0.9);
  border-radius: 20px;
  box-shadow: 0 8px 20px rgba(0, 0, 0, 0.6);
}

.section-nav .nav-link {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 12px 24px;
  background: rgba(240, 240, 240, 0.1);
  color: #fff;
  text-decoration: none;
  border-radius: 15px;
  font-weight: 600;
  font-size: 0.95rem;
  transition: all 0.3s ease;
  border: 1px solid rgba(255, 255, 255, 0.1);
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.3);
  backdrop-filter: blur(4px);
}

.section-nav .nav-link:hover {
  background: rgba(255, 255, 255, 0.2);
  border-color: rgba(255, 255, 255, 0.3);
  transform: translateY(-3px);
  box-shadow: 0 6px 16px rgba(0, 0, 0, 0.5);
}

.section-nav .nav-link:active {
  transform: translateY(-1px);
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.4);
}

/* Smooth Scrolling */
html {
  scroll-behavior: smooth;
}

/* Section Scroll-Offset */
section[id] {
  scroll-margin-top: 100px;
}

/* ========================================
   DWD WARNINGS STYLES
   ======================================== */

/* Warnungen Container */
.warnings-container {
  display: flex;
  flex-direction: column;
  gap: 20px;
  margin-top: 20px;
}

/* Keine Warnungen - Dunkles Design */
.no-warnings {
  background: rgba(76, 175, 80, 0.15);
  border: 2px solid rgba(76, 175, 80, 0.4);
  border-radius: 15px;
  padding: 30px;
  text-align: center;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.3);
  backdrop-filter: blur(4px);
}

.no-warnings p {
  margin: 8px 0;
  color: #4caf50;
  font-size: 1.1rem;
  font-weight: 600;
}

.no-warnings .update-time {
  font-size: 0.85rem;
  color: #81c784;
  margin-top: 15px;
  opacity: 0.9;
  font-weight: normal;
}

/* Warning Card - Dunkles Design */
.warning-card {
  background: rgba(240, 240, 240, 0.1);
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 20px;
  padding: 25px;
  border-left: 6px solid #ff9800;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.4);
  backdrop-filter: blur(4px);
  transition: transform 0.2s ease, box-shadow 0.2s ease;
  animation: slideIn 0.3s ease-out;
  color: #fff;
}

.warning-card:hover {
  transform: translateY(-3px);
  box-shadow: 0 8px 20px rgba(0, 0, 0, 0.6);
}

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

/* Warning Header */
.warning-header {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 15px;
  flex-wrap: wrap;
}

.warning-icon {
  font-size: 2rem;
  line-height: 1;
}

.warning-header h3 {
  margin: 0;
  flex: 1;
  color: #fff;
  font-size: 1.3rem;
}

.warning-level-badge {
  padding: 8px 16px;
  border-radius: 20px;
  font-size: 0.85rem;
  font-weight: bold;
  color: #fff;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.3);
}

/* Warning Location */
.warning-location {
  font-weight: 600;
  color: #ddd;
  margin-bottom: 12px;
  font-size: 0.95rem;
}

/* Warning Headline */
.warning-headline {
  color: #ff6b6b;
  font-size: 1.1rem;
  font-weight: 600;
  margin: 12px 0;
  padding: 10px;
  background-color: rgba(255, 107, 107, 0.15);
  border-radius: 10px;
  border: 1px solid rgba(255, 107, 107, 0.3);
}

/* Warning Description */
.warning-description {
  background-color: rgba(0, 0, 0, 0.3);
  padding: 15px;
  border-radius: 12px;
  margin: 15px 0;
  line-height: 1.6;
  color: #eee;
  border: 1px solid rgba(255, 255, 255, 0.05);
}

/* Warning Time */
.warning-time {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 15px;
  margin: 15px 0;
  padding: 15px;
  background-color: rgba(0, 0, 0, 0.3);
  border-radius: 12px;
  font-size: 0.9rem;
  color: #eee;
  border: 1px solid rgba(255, 255, 255, 0.05);
}

.warning-time div {
  color: #eee;
}

.warning-time strong {
  color: #bbb;
  display: block;
  margin-bottom: 5px;
}

/* Warning Instruction */
.warning-instruction {
  background: rgba(255, 152, 0, 0.15);
  border: 2px solid rgba(255, 152, 0, 0.4);
  border-radius: 12px;
  padding: 15px;
  margin-top: 15px;
  line-height: 1.6;
  color: #ffb74d;
}

.warning-instruction strong {
  display: block;
  margin-bottom: 8px;
  font-size: 1rem;
  color: #ffa726;
}

/* Warnings Footer */
.warnings-footer {
  text-align: center;
  padding: 20px;
  color: #999;
  font-size: 0.85rem;
  border-top: 1px solid rgba(255, 255, 255, 0.1);
  margin-top: 20px;
}

.warnings-footer .dwd-regions {
  margin-top: 8px;
  font-weight: 600;
  color: #bbb;
}

/* Warnings Info */
.warnings-info {
  background: rgba(33, 150, 243, 0.15);
  border-left: 4px solid #2196f3;
  border: 1px solid rgba(33, 150, 243, 0.3);
  padding: 15px;
  margin-bottom: 20px;
  border-radius: 12px;
  font-weight: 600;
  color: #64b5f6;
  backdrop-filter: blur(4px);
}

/* Warning Altitude */
.warning-altitude {
  margin-top: 15px;
  padding: 10px;
  background-color: rgba(0, 0, 0, 0.2);
  border-radius: 8px;
  text-align: center;
  border: 1px solid rgba(255, 255, 255, 0.05);
}

.warning-altitude small {
  color: #bbb;
  font-size: 0.85rem;
}

/* Warning Error */
.warning-error {
  background: rgba(244, 67, 54, 0.15);
  border: 2px solid rgba(244, 67, 54, 0.4);
  border-radius: 15px;
  padding: 30px;
  text-align: center;
  backdrop-filter: blur(4px);
}

.warning-error p {
  margin: 8px 0;
  color: #ef5350;
  font-weight: 600;
}

.error-details {
  font-family: monospace;
  font-size: 0.85rem;
  background-color: rgba(0, 0, 0, 0.3);
  padding: 10px;
  border-radius: 8px;
  margin: 15px 0;
  color: #ffcdd2;
  border: 1px solid rgba(255, 255, 255, 0.05);
}

.retry-button {
  margin-top: 15px;
  padding: 12px 24px;
  background: rgba(244, 67, 54, 0.8);
  color: white;
  border: none;
  border-radius: 25px;
  cursor: pointer;
  font-size: 1rem;
  font-weight: 600;
  transition: all 0.3s ease;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.3);
}

.retry-button:hover {
  background: rgba(244, 67, 54, 1);
  transform: translateY(-2px);
  box-shadow: 0 6px 16px rgba(0, 0, 0, 0.4);
}

.retry-button:active {
  transform: translateY(0);
}

/* Warnstufen-spezifische Styles */
.warning-level-1 {
  border-left-color: #FFEB3B;
}

.warning-level-2 {
  border-left-color: #FF9800;
}

.warning-level-3 {
  border-left-color: #E53935; /* Offizielles DWD Rot */
}

.warning-level-4 {
  border-left-color: #7B1FA2; /* Offizielles DWD Violett */
  background: rgba(123, 31, 162, 0.1);
}

/* ========================================
   RESPONSIVE DESIGN
   ======================================== */

@media (max-width: 768px) {
  .warning-card {
    padding: 20px;
  }
  
  .warning-header h3 {
    font-size: 1.1rem;
  }
  
  .warning-time {
    grid-template-columns: 1fr;
    gap: 10px;
  }
  
  .warning-icon {
    font-size: 1.5rem;
  }
  
  /* Section Navigation - Mobile */
  .section-nav {
    gap: 10px;
    padding: 20px 15px;
  }
  
  .section-nav .nav-link {
    padding: 10px 16px;
    font-size: 0.85rem;
  }
}

@media (max-width: 480px) {
  .warning-card {
    padding: 15px;
  }
  
  .warning-header {
    gap: 8px;
  }
  
  .warning-header h3 {
    font-size: 1rem;
  }
  
  .warning-description,
  .warning-instruction {
    padding: 12px;
    font-size: 0.9rem;
  }
}