/* --- CSS Variables & Reset --- */
:root {
    /* Light Mode (Default) */
    --primary-color: #0f4c75; 
    --secondary-color: #3282b8; 
    --accent-color: #bbe1fa; 
    --bg-color: #f0f2f5;
    --card-bg: #ffffff;
    --text-main: #333333;
    --text-light: #666666;
    --success-color: #28a745;
    --warning-color: #ffc107;
    --danger-color: #dc3545;
    --shadow: 0 4px 6px rgba(0,0,0,0.1);
    --radius: 12px;
    --map-filter: none;
}

/* DARK MODE VARIABLES */
body.dark-mode {
    --primary-color: #60a3bc; 
    --secondary-color: #82ccdd; 
    --accent-color: #3c6382; 
    --bg-color: #121212;
    --card-bg: #1e1e1e;
    --text-main: #e0e0e0;
    --text-light: #a0a0a0;
    --shadow: 0 4px 6px rgba(0,0,0,0.3);
    --map-filter: brightness(0.8) invert(1) hue-rotate(180deg); 
}

/* Dark Mode Overrides */
body.dark-mode .card { border-top-color: var(--primary-color); }
body.dark-mode .babbeler-box { background: #2c2c2c; border-left-color: #e67e22; }
body.dark-mode .babbeler-text { color: #ccc; }
body.dark-mode .env-item, body.dark-mode .level-item, body.dark-mode .hist-box, body.dark-mode .forecast-day-item, body.dark-mode .airport-metric, body.dark-mode .outfit-item, body.dark-mode .battle-item, body.dark-mode .pleasure-metric { background: #2c2c2c; border-color: #444; }
body.dark-mode .wind-badge { background: #333; color: #82ccdd; }
body.dark-mode tr:hover { background-color: #2c2c2c; }
body.dark-mode th { background-color: #2c3e50; color: #fff; }
body.dark-mode td { border-bottom-color: #333; }
body.dark-mode .forecast-row { background: #1e1e1e; border-color: #333; }
body.dark-mode .forecast-region-title { border-bottom-color: #333; }
body.dark-mode .f-day-name { color: #aaa; }
body.dark-mode .f-day-date { color: #777; }
body.dark-mode .f-temp { color: #fff; }
body.dark-mode .ls-icon { background: #333; }
body.dark-mode .ls-label { color: #ddd; }
body.dark-mode .ls-val { color: #bbb; }
body.dark-mode .hist-text { color: #bbb; }
body.dark-mode .hist-temp { color: #fff; }
body.dark-mode .quiz-btn { background: #2c2c2c; border-color: #444; color: #eee; }
body.dark-mode .quiz-btn:hover { background: #333; }
body.dark-mode .outfit-icon { background: #333; color: #e0e0e0; }
body.dark-mode .radar-controls { background: #2c2c2c; border-color: #444; }
body.dark-mode .radar-speed-select { background: #333; color: #eee; border-color: #555; }
body.dark-mode .traffic-info { background: rgba(255,255,255,0.05); }
body.dark-mode .history-controls { background: #2c2c2c; }
body.dark-mode .hist-btn { color: #aaa; }
body.dark-mode .hist-btn.active { color: #fff; background: var(--primary-color); }

/* Garden & Tick Specific Dark Mode */
body.dark-mode .garden-card { background: #2c2c2c; border-color: #444; }
body.dark-mode .garden-action { color: #fff; }
body.dark-mode .donut-inner { background: #2c2c2c; }
body.dark-mode .tick-marker { border-color: #333; background: #fff; }


/* Leaflet Dark Mode Hack */
body.dark-mode .leaflet-layer, body.dark-mode .leaflet-control-zoom-in, body.dark-mode .leaflet-control-zoom-out, body.dark-mode .leaflet-control-attribution { filter: invert(100%) hue-rotate(180deg) brightness(95%) contrast(90%); }
body.dark-mode .custom-marker-card { color: #333; } 

* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
    transition: background-color 0.3s, color 0.3s; 
}

html, body {
    max-width: 100%;
    overflow-x: hidden; /* Verhindert horizontales Scrollen auf Handys */
}

body {
    font-family: 'Roboto', sans-serif;
    background-color: var(--bg-color);
    color: var(--text-main);
    line-height: 1.6;
}

/* --- Layout --- */
.container { 
    max-width: 1200px; 
    margin: 0 auto; 
    padding: 20px; 
    width: 100%;
}

/* Responsive Padding für Mobile */
@media (max-width: 768px) {
    .container {
        padding: 10px;
    }
}

header { display: flex; justify-content: space-between; align-items: center; margin-bottom: 30px; flex-wrap: wrap; gap: 15px; }
.header-title { flex: 1; min-width: 250px; } /* Titel nimmt Platz ein, bricht aber um */
.header-title h1 { color: var(--primary-color); font-size: 1.8rem; font-weight: 700; line-height: 1.2; }
.header-title span { color: var(--text-light); font-size: 0.9rem; font-weight: 400; display: block; margin-top: 5px; }
.header-controls { display: flex; gap: 10px; align-items: center; flex-shrink: 0; }

.theme-toggle {
    background: none; border: 2px solid var(--primary-color); color: var(--primary-color);
    width: 40px; height: 40px; border-radius: 50%; cursor: pointer;
    display: flex; align-items: center; justify-content: center; font-size: 1.2rem; transition: all 0.2s;
}
.theme-toggle:hover { background: var(--primary-color); color: white; }

.date-badge { background-color: var(--primary-color); color: white; padding: 8px 15px; border-radius: 50px; font-weight: 500; display: flex; align-items: center; gap: 10px; box-shadow: var(--shadow); font-size: 0.9rem; white-space: nowrap; }

/* --- Grid System --- */
.dashboard-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 20px;
}

@media (min-width: 992px) {
    .dashboard-grid {
        grid-template-columns: 1fr 1fr; /* 2 Spalten auf Desktop */
        grid-template-areas: 
            "summary map"
            "table map"
            "outfit details"
            "radar radar" 
            "forecast forecast"
            "traffic airport"
            "energy bio"
            "garden env"
            "levels levels"
            "sat sat"
            "pleasure battle"
            "stars history"
            "quiz quiz"
            "game game"; 
    }
    /* Areas Zuweisung (Desktop) */
    .section-summary { grid-area: summary; }
    .section-map { grid-area: map; }
    .section-table { grid-area: table; }
    .section-outfit { grid-area: outfit; } 
    .section-radar { grid-area: radar; } 
    .section-details { grid-area: details; }
    .section-env { grid-area: env; }
    .section-energy { grid-area: energy; }
    .section-bio { grid-area: bio; }
    .section-garden { grid-area: garden; }
    .section-traffic { grid-area: traffic; } 
    .section-airport { grid-area: airport; } 
    .section-stars { grid-area: stars; }
    .section-battle { grid-area: battle; }
    .section-pleasure { grid-area: pleasure; }
    .section-history { grid-area: history; }
    .section-quiz { grid-area: quiz; } 
    .section-levels { grid-area: levels; }
    .section-forecast { grid-area: forecast; }
    .section-sat { grid-area: sat; }
    .section-game { grid-area: game; }
}

/* --- Cards General --- */
.card { background: var(--card-bg); border-radius: var(--radius); padding: 20px; box-shadow: var(--shadow); margin-bottom: 20px; border-top: 4px solid var(--secondary-color); display: flex; flex-direction: column; width: 100%; }
.card.h-100 { height: auto; } 
@media(min-width: 992px) { .card.h-100 { height: calc(100% - 20px); } } /* Nur auf Desktop volle Höhe */

.card-title { font-size: 1.2rem; color: var(--primary-color); margin-bottom: 15px; border-bottom: 1px solid #eee; padding-bottom: 10px; display: flex; align-items: center; gap: 10px; justify-content: space-between; flex-wrap: wrap; }

/* --- Specific Sections --- */
.weather-text { font-size: 1rem; color: var(--text-main); text-align: justify; margin-bottom: 20px; }
.warning-box { background-color: #e8f5e9; border-left: 5px solid var(--success-color); padding: 15px; border-radius: 4px; display: flex; align-items: center; gap: 15px; }
.warning-icon { font-size: 1.5rem; color: var(--success-color); flex-shrink: 0; } /* Icon schrumpft nicht */
.warning-content h4 { margin-bottom: 2px; color: #2e7d32; font-size: 1rem; }
.warning-content p { font-size: 0.9rem; margin: 0; }

/* Speak Button */
.speak-btn {
    background: none; border: 1px solid var(--secondary-color); color: var(--secondary-color);
    padding: 4px 8px; border-radius: 20px; cursor: pointer; font-size: 0.85rem;
    display: flex; align-items: center; gap: 5px; transition: all 0.2s; white-space: nowrap;
}
.speak-btn:hover { background: var(--secondary-color); color: white; }
.speak-btn.speaking { background: var(--danger-color); border-color: var(--danger-color); color: white; animation: pulse 1.5s infinite; }
@keyframes pulse { 0% { opacity: 1; } 50% { opacity: 0.7; } 100% { opacity: 1; } }

/* Babbeler */
.babbeler-box { background: #fdf2e9; border-left: 5px solid #d35400; padding: 15px; border-radius: 4px; margin-top: 15px; display: flex; gap: 15px; align-items: flex-start; }
.babbeler-icon { font-size: 2rem; color: #d35400; flex-shrink: 0; }
.babbeler-text { font-family: 'Georgia', serif; font-style: italic; color: #555; font-size: 1.05rem; }
.babbeler-title { font-weight: bold; font-style: normal; font-size: 0.85rem; text-transform: uppercase; color: #d35400; display: block; margin-bottom: 5px; font-family: 'Roboto', sans-serif; }

/* OUTFIT STYLE */
.outfit-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(90px, 1fr)); gap: 10px; text-align: center; }
.outfit-item { background: #f1f2f6; padding: 10px; border-radius: 8px; border: 1px solid #e0e0e0; transition: transform 0.2s; }
.outfit-item:hover { transform: translateY(-3px); }
.outfit-icon { width: 40px; height: 40px; background: #fff; border-radius: 50%; display: flex; align-items: center; justify-content: center; margin: 0 auto 8px auto; font-size: 1.2rem; color: #333; box-shadow: 0 2px 5px rgba(0,0,0,0.1); }
.outfit-label { font-size: 0.8rem; font-weight: 500; color: var(--text-main); display: block; line-height: 1.2; }

/* BATTLE STYLE */
.battle-container { display: flex; flex-direction: column; gap: 15px; }
.battle-row { display: flex; justify-content: space-between; align-items: center; padding: 10px 0; border-bottom: 1px solid #eee; }
.battle-row:last-child { border-bottom: none; }
.battle-rank { display: flex; align-items: center; gap: 10px; }
.rank-icon { font-size: 1.5rem; }
.rank-info h4 { margin: 0; font-size: 1rem; color: var(--text-main); }
.rank-info span { font-size: 0.8rem; color: var(--text-light); }
.battle-temp { font-size: 1.4rem; font-weight: bold; color: var(--primary-color); }
.crown-gold { color: #f1c40f; }
.ice-blue { color: #3498db; }

/* PLEASURE STYLE */
.pleasure-box { text-align: center; padding: 10px; display: flex; flex-direction: column; align-items: center; height: 100%; justify-content: center; }
.pleasure-icon { font-size: 3.5rem; color: #e67e22; margin-bottom: 15px; transition: transform 0.3s; }
.pleasure-icon:hover { transform: scale(1.1) rotate(10deg); }
.pleasure-title { font-size: 1.2rem; font-weight: bold; margin-bottom: 5px; color: var(--primary-color); }
.pleasure-desc { font-size: 0.9rem; color: var(--text-light); max-width: 100%; line-height: 1.4; }
.pleasure-meter { width: 100%; height: 10px; background: #eee; border-radius: 5px; margin-top: 15px; overflow: hidden; }
.pleasure-fill { height: 100%; background: linear-gradient(90deg, #f39c12, #e74c3c); width: 0%; transition: width 1s; }


/* --- GARTEN & ZECKEN (SPLIT DESIGN) --- */
.garden-grid { 
    display: grid; 
    grid-template-columns: 1fr 1fr; 
    gap: 15px; 
    height: 100%;
}
@media (max-width: 600px) {
    .garden-grid { grid-template-columns: 1fr; }
}

.garden-card {
    background: #f8f9fa;
    border-radius: 12px;
    padding: 15px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: space-between;
    text-align: center;
    border: 1px solid #eee;
    transition: transform 0.2s;
}
.garden-header {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-bottom: 10px;
    font-weight: bold;
    color: var(--text-light);
    text-transform: uppercase;
    font-size: 0.8rem;
}
.garden-icon-large { font-size: 1.2rem; color: var(--secondary-color); }
.tick-icon { color: #e67e22; }
.garden-action {
    font-weight: bold;
    font-size: 1rem;
    color: var(--primary-color);
    margin-top: 10px;
}

/* DONUT CHART */
.donut-container { margin: 5px 0; }
.donut-chart {
    width: 90px;
    height: 90px;
    border-radius: 50%;
    background: conic-gradient(#3498db calc(var(--pct) * 1%), #e0e0e0 0);
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: inset 0 0 5px rgba(0,0,0,0.1);
}
.donut-inner {
    width: 70px;
    height: 70px;
    background: var(--card-bg);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: bold;
    font-size: 1.2rem;
    color: var(--text-main);
}

/* ZECKEN BAROMETER */
.tick-meter-container {
    width: 100%;
    position: relative;
    height: 30px; 
    margin-top: 15px;
}
.tick-scale {
    width: 100%;
    height: 10px;
    background: linear-gradient(to right, #27ae60, #f1c40f, #e74c3c);
    border-radius: 5px;
    top: 10px;
    position: absolute;
}
.tick-marker {
    width: 4px;
    height: 18px;
    background: #333;
    border: 2px solid #fff;
    position: absolute;
    top: 6px;
    transform: translateX(-50%);
    border-radius: 2px;
    transition: left 0.5s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    box-shadow: 0 2px 4px rgba(0,0,0,0.3);
}
.tick-labels {
    display: flex;
    justify-content: space-between;
    width: 100%;
    font-size: 0.7rem;
    color: var(--text-light);
    margin-top: -5px;
}

/* --- ENDE GARTEN DESIGN --- */

.traffic-display { display: flex; justify-content: space-around; align-items: center; background: #333; padding: 15px; border-radius: 12px; color: white; }
.traffic-light { width: 40px; height: 40px; border-radius: 50%; background: #555; box-shadow: inset 0 0 10px rgba(0,0,0,0.5); transition: all 0.5s; border: 2px solid #222; }
.traffic-active-green { background: #2ecc71; box-shadow: 0 0 20px #2ecc71; }
.traffic-active-yellow { background: #f1c40f; box-shadow: 0 0 20px #f1c40f; }
.traffic-active-red { background: #e74c3c; box-shadow: 0 0 20px #e74c3c; }
.traffic-info { margin-top: 15px; font-size: 0.9rem; text-align: center; padding: 10px; background: rgba(0,0,0,0.05); border-radius: 6px; }

/* AIRPORT STYLE */
.airport-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; margin-top: 10px; }
.airport-metric { text-align: center; background: #f8f9fa; padding: 10px; border-radius: 8px; border: 1px solid #eee; }
.airport-val { display: block; font-size: 1.1rem; font-weight: bold; color: var(--primary-color); margin-top: 5px; }
.airport-runway { background: #2c3e50; color: #fff; padding: 15px; border-radius: 8px; text-align: center; margin-bottom: 10px; display: flex; align-items: center; justify-content: center; gap: 10px; }
.runway-icon { font-size: 1.5rem; transform: rotate(-90deg); /* Plane pointing */ }

/* QUIZ STYLE */
.quiz-container { text-align: center; padding: 10px 0; }
.quiz-question { font-weight: bold; margin-bottom: 15px; font-size: 1rem; color: var(--text-main); }
.quiz-options { display: flex; flex-direction: column; gap: 10px; }
.quiz-btn { padding: 10px 15px; border: 1px solid #ccc; background: #fff; border-radius: 6px; cursor: pointer; transition: all 0.2s; text-align: left; color: #333; font-size: 0.9rem; }
.quiz-btn:hover { background: #f0f0f0; }
.quiz-btn.correct { background: #d4edda; border-color: #28a745; color: #155724; pointer-events: none; }
.quiz-btn.wrong { background: #f8d7da; border-color: #dc3545; color: #721c24; pointer-events: none; }
.quiz-feedback { margin-top: 15px; font-size: 0.9rem; min-height: 20px; font-weight: bold; }
.quiz-score { font-size: 0.9rem; color: var(--text-light); margin-bottom: 10px; font-weight: bold; }
.quiz-next, .quiz-reset { margin-top: 10px; padding: 8px 15px; border-radius: 4px; cursor: pointer; font-size: 0.9rem; border:none; width: 100%; max-width: 200px; margin-left: auto; margin-right: auto; display: block; }
.quiz-next { background: var(--primary-color); color: white; }
.quiz-reset { background: transparent; border: 1px solid var(--text-light); color: var(--text-light); margin-top: 15px; }

/* Stars & History */
.star-card { background: linear-gradient(to bottom, #0c1c38, #1a3666); color: #fff; border: none; }
.star-card .card-title { color: #f1c40f; border-bottom-color: rgba(255,255,255,0.2); }
.star-content { text-align: center; padding: 10px 0; }
.star-icon-large { font-size: 3rem; margin-bottom: 10px; color: #f1c40f; text-shadow: 0 0 10px rgba(241, 196, 15, 0.5); }
.star-verdict { font-size: 1.2rem; font-weight: bold; margin-bottom: 5px; }
.star-details { font-size: 0.9rem; color: #bdc3c7; }

.history-content { display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 15px; padding: 10px 0; }
.history-compare { display: flex; align-items: center; gap: 15px; width: 100%; justify-content: center; }
.hist-box { text-align: center; background: #f8f9fa; padding: 10px; border-radius: 8px; flex: 1; min-width: 80px; }
.hist-date { font-size: 0.75rem; color: #666; text-transform: uppercase; margin-bottom: 5px; display: block; }
.hist-temp { font-family: 'Orbitron', sans-serif; font-size: 1.3rem; font-weight: bold; color: #333; }
.hist-arrow { font-size: 1.2rem; color: #aaa; }
.hist-text { font-size: 0.9rem; text-align: center; color: #444; }

/* HISTORY BUTTONS */
.history-controls {
    display: flex;
    justify-content: center;
    gap: 5px;
    margin-bottom: 15px;
    background: #f1f2f6;
    padding: 5px;
    border-radius: 20px;
    width: fit-content;
    margin-left: auto;
    margin-right: auto;
}
.hist-btn {
    background: transparent;
    border: none;
    padding: 5px 12px;
    border-radius: 15px;
    cursor: pointer;
    font-size: 0.8rem;
    color: var(--text-light);
    transition: all 0.2s;
}
.hist-btn:hover { color: var(--primary-color); background: rgba(0,0,0,0.05); }
.hist-btn.active { background: var(--primary-color); color: white; font-weight: bold; box-shadow: 0 2px 4px rgba(0,0,0,0.1); }

/* RADAR SECTION */
.radar-container {
    position: relative;
    width: 100%;
    height: 400px;
    border-radius: 8px;
    overflow: hidden;
    border: 1px solid #d1d9e0;
}
/* Mobile Radar Höhe */
@media (max-width: 768px) {
    .radar-container { height: 300px; }
    .sat-container { height: 300px; }
    .map-container { height: 350px; }
}

#radar-map { width: 100%; height: 100%; cursor: crosshair; }
.radar-controls { display: flex; align-items: center; gap: 10px; margin-top: 10px; padding: 10px; background: #f8f9fa; border-radius: 8px; border: 1px solid #eee; flex-wrap: wrap; }
.radar-btn { background: var(--primary-color); color: white; border: none; width: 40px; height: 40px; border-radius: 50%; cursor: pointer; display: flex; align-items: center; justify-content: center; font-size: 1rem; flex-shrink: 0; }
.radar-btn:hover { background: var(--secondary-color); }
.radar-slider { flex-grow: 1; cursor: pointer; min-width: 100px; }
.radar-speed-select { padding: 5px 10px; border-radius: 20px; border: 1px solid #ccc; background: #fff; font-size: 0.85rem; cursor: pointer; color: #333; }

/* Map & Table & Env */
.map-container { position: relative; width: 100%; height: 500px; border-radius: var(--radius); overflow: hidden; border: 1px solid #d1d9e0; z-index: 1; }
#map { height: 100%; width: 100%; cursor: crosshair; }
.leaflet-div-icon { background: transparent; border: none; }
/* Marker Card Mobile Anpassung */
.custom-marker-card { background: rgba(255, 255, 255, 0.95); padding: 5px 8px; border-radius: 8px; box-shadow: 0 3px 8px rgba(0,0,0,0.3); text-align: center; border: 1px solid #999; width: 80px; position: absolute; top: -50%; left: -50%; transition: transform 0.2s; }
.marker-city { font-size: 0.7rem; font-weight: 700; text-transform: uppercase; color: var(--text-light); display: block; }
.marker-icon { font-size: 1.3rem; display: block; margin: 2px 0; }
.marker-temp { font-size: 0.9rem; font-weight: 700; color: var(--primary-color); }

.leaflet-popup-content-wrapper { border-radius: 8px; padding: 0; }
.leaflet-popup-content { margin: 10px 15px; line-height: 1.4; }
.weather-rain { color: #4a90e2; } .weather-cloud { color: #7f8c8d; } .weather-partly { color: #f39c12; } .weather-sun { color: #f1c40f; } .weather-snow { color: #a4b0be; } .weather-storm { color: #2c3e50; }

.table-wrapper { overflow-x: auto; -webkit-overflow-scrolling: touch; width: 100%; }
table { width: 100%; border-collapse: collapse; min-width: 500px; }
th, td { padding: 10px; text-align: left; border-bottom: 1px solid #eee; font-size: 0.9rem; }
th { background-color: var(--secondary-color); color: white; font-weight: 500; text-transform: uppercase; letter-spacing: 0.5px; }
tr:last-child td { border-bottom: none; }
tr:hover { background-color: #f8f9fa; }
.wind-badge { background: #eef2f7; padding: 3px 6px; border-radius: 4px; font-size: 0.8rem; color: #4a69bd; display: inline-block; white-space: nowrap; }
.detail-value { font-family: monospace; color: #555; font-size: 0.9rem; }
.sun-times i { color: #f39c12; margin-right: 5px; }

/* Env Grid Responsive */
.env-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(140px, 1fr)); gap: 15px; margin-top: 10px; }
.env-item { background-color: #f8f9fa; padding: 12px; border-radius: 8px; text-align: center; border: 1px solid #e1e4e8; }
.env-icon { font-size: 1.8rem; margin-bottom: 8px; color: var(--secondary-color); }
.env-label { display: block; font-size: 0.85rem; color: var(--text-light); margin-bottom: 5px; }
.env-value { font-size: 1.1rem; font-weight: 700; color: var(--text-main); }
.env-status { display: inline-block; margin-top: 5px; font-size: 0.75rem; padding: 2px 6px; border-radius: 4px; font-weight: 500; }

/* Lifestyle & Energy */
.lifestyle-list { list-style: none; padding: 0; }
.lifestyle-item { display: flex; align-items: center; justify-content: space-between; padding: 10px 0; border-bottom: 1px solid #eee; }
.lifestyle-item:last-child { border-bottom: none; }
.ls-left { display: flex; align-items: center; gap: 10px; }
.ls-icon { width: 36px; height: 36px; background: #f0f2f5; border-radius: 50%; display: flex; align-items: center; justify-content: center; color: var(--primary-color); flex-shrink: 0; }
.ls-label { font-weight: 500; color: #333; font-size: 0.95rem; }
.ls-val { font-weight: bold; color: #555; font-size: 0.95rem; }
.solar-bar-bg { width: 80px; height: 6px; background: #e0e0e0; border-radius: 4px; overflow: hidden; }
.solar-bar-fill { height: 100%; background: #f1c40f; width: 0%; transition: width 1s; }

/* Level Grid */
.level-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(160px, 1fr)); gap: 15px; }
.level-item { background: #eef6fb; border-left: 4px solid #3498db; padding: 12px; border-radius: 6px; position: relative; }
.level-river { font-size: 0.75rem; text-transform: uppercase; color: #666; letter-spacing: 1px; margin-bottom: 5px; display: block; }
.level-station { font-weight: bold; color: var(--primary-color); font-size: 1rem; display: block; margin-bottom: 8px; }
.level-data { font-size: 1.5rem; font-weight: 700; color: var(--text-main); }
.level-unit { font-size: 0.9rem; color: #666; font-weight: normal; }
.level-trend { position: absolute; top: 12px; right: 12px; font-size: 1.1rem; }

/* Forecast */
.forecast-container { display: flex; flex-direction: column; gap: 15px; }
.forecast-row { background: #fdfdfd; border: 1px solid #eee; border-radius: 8px; padding: 12px; }
.forecast-region-title { font-size: 1rem; font-weight: bold; color: var(--primary-color); margin-bottom: 10px; display: flex; align-items: center; gap: 8px; border-bottom: 1px solid #f0f0f0; padding-bottom: 5px; }
.forecast-days-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 8px; }
.forecast-day-item { text-align: center; padding: 6px; border-radius: 6px; background: #f8f9fa; }
.f-day-name { font-size: 0.8rem; color: #444; font-weight: 500; margin-bottom: 2px; display: block; line-height: 1.2; }
.f-day-date { font-size: 0.7rem; color: #888; font-weight: normal; display: block; margin-bottom: 4px; }
.f-icon { font-size: 1.2rem; margin: 4px 0; display: block; }
.f-temp { font-size: 0.8rem; font-weight: bold; color: #333; }

/* Mobile Breakpoint Specifics */
@media (max-width: 600px) {
    .header-title h1 { font-size: 1.4rem; }
    .date-badge { width: 100%; justify-content: center; }
    .header-controls { width: 100%; justify-content: space-between; margin-top: 10px; }
    .forecast-days-grid { grid-template-columns: repeat(2, 1fr); } /* 2x2 Grid auf Handy */
    .history-compare { flex-direction: row; gap: 10px; }
    .radar-controls { flex-wrap: wrap; justify-content: center; }
    .radar-slider { width: 100%; }
}

.sat-container { position: relative; width: 100%; height: 400px; border-radius: 8px; overflow: hidden; border: 1px solid #eee; background: #000; }
#sat-map { width: 100%; height: 100%; background: #000; }
.sat-tooltip { background: transparent; border: none; box-shadow: none; color: #fff; font-weight: bold; text-shadow: 1px 1px 2px black; font-size: 0.9rem; }
.loading-spinner { display: inline-block; width: 1rem; height: 1rem; border: 2px solid rgba(0,0,0,0.1); border-radius: 50%; border-top-color: var(--primary-color); animation: spin 1s ease-in-out infinite; }
@keyframes spin { to { transform: rotate(360deg); } }
footer { text-align: center; margin-top: 40px; color: var(--text-light); font-size: 0.8rem; padding-bottom: 20px; }

/* --- GAME SECTION (CLOUD BUSTER 3000) --- */
.section-game {
    grid-area: game; /* Neue Grid Area */
    margin-top: 20px;
}

.arcade-wrapper {
    display: flex;
    justify-content: center;
    align-items: center;
    background: #111;
    padding: 20px;
    border-radius: 8px;
    box-shadow: inset 0 0 20px #000;
}

#arcade-cabinet {
    position: relative;
    width: 320px;
    height: 480px;
    background-color: #000;
    border: 4px solid #333;
    border-radius: 4px;
    overflow: hidden;
    font-family: 'Orbitron', monospace; /* Retro Font */
}

#gameCanvas {
    background-color: #2c3e50; /* Standard Himmel */
    width: 100%;
    height: 100%;
    display: block;
}

/* Scanline Effekt */
.scanlines {
    position: absolute;
    top: 0; left: 0; width: 100%; height: 100%;
    background: linear-gradient(to bottom, rgba(255,255,255,0), rgba(255,255,255,0) 50%, rgba(0,0,0,0.2) 50%, rgba(0,0,0,0.2));
    background-size: 100% 4px;
    pointer-events: none;
    z-index: 10;
}

#game-ui {
    position: absolute;
    top: 10px;
    left: 10px;
    color: #fff;
    z-index: 5;
    text-shadow: 1px 1px 0 #000;
}

.game-overlay {
    position: absolute;
    top: 0; left: 0; width: 100%; height: 100%;
    background: rgba(0,0,0,0.85);
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    color: #fff;
    z-index: 20;
    text-align: center;
}

.game-btn {
    background: #e74c3c;
    color: #fff;
    border: 2px solid #c0392b;
    padding: 10px 20px;
    font-family: 'Orbitron', monospace;
    font-size: 1.2rem;
    cursor: pointer;
    margin-top: 15px;
    transition: transform 0.1s;
}
.game-btn:hover { transform: scale(1.05); background: #ff5252; }
.game-btn:active { transform: scale(0.95); }