:root {
    /* Modern Color Palette - Refined Dark Theme */
    --bg-primary: #0f0f0f;
    --bg-secondary: #1a1a1a;
    --bg-card: #1e1e1e;
    --bg-card-hover: #252525;
    
    --text-primary: #ffffff;
    --text-secondary: #b0b0b0;
    --text-muted: #707070;
    
    --accent-primary: #00d4ff;
    --accent-success: #00ff88;
    --accent-warning: #ffaa00;
    --accent-danger: #ff3366;
    --accent-info: #00d4ff;
    
    --border-color: #2a2a2a;
    --glow: 0 0 20px rgba(0, 212, 255, 0.15);
    --shadow: 0 8px 32px rgba(0, 0, 0, 0.4);
    --shadow-lg: 0 16px 48px rgba(0, 0, 0, 0.6);
}

* {
    box-sizing: border-box;
}

body {
    background: var(--bg-primary);
    background-image: 
        radial-gradient(at 20% 30%, rgba(0, 212, 255, 0.03) 0%, transparent 50%),
        radial-gradient(at 80% 70%, rgba(0, 255, 136, 0.02) 0%, transparent 50%);
    color: var(--text-primary);
    font-family: 'Archivo', -apple-system, BlinkMacSystemFont, sans-serif;
    min-height: 100vh;
    overflow-x: hidden;
    line-height: 1.6;
}

/* Header Styles */
.dashboard-header {
    text-align: center;
    padding: 3rem 0 2rem;
    border-bottom: 1px solid var(--border-color);
    margin-bottom: 3rem;
    position: relative;
}

.time-display {
    font-size: 6rem;
    font-weight: 300;
    font-family: 'JetBrains Mono', monospace;
    background: linear-gradient(135deg, var(--accent-primary) 0%, var(--accent-success) 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    line-height: 1;
    letter-spacing: -0.04em;
    filter: drop-shadow(0 0 30px rgba(0, 212, 255, 0.3));
}

.date-display {
    font-size: 1.25rem;
    color: var(--text-secondary);
    margin-top: 1rem;
    font-weight: 400;
    letter-spacing: 0.05em;
}

.location-badge {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    margin-top: 1.5rem;
    padding: 0.75rem 1.5rem;
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: 100px;
    font-size: 0.875rem;
    color: var(--text-secondary);
    transition: all 0.3s ease;
}

.location-badge:hover {
    border-color: var(--accent-primary);
    box-shadow: var(--glow);
}

/* Card Styles */
.dashboard-card {
    background: var(--bg-card);
    backdrop-filter: blur(10px);
    border: 1px solid var(--border-color);
    border-radius: 20px;
    box-shadow: var(--shadow);
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    height: 100%;
    max-height: 600px;
    overflow: hidden;
    position: relative;
    display: flex;
    flex-direction: column;
}

.dashboard-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 1px;
    background: linear-gradient(90deg, transparent, var(--accent-primary), transparent);
    opacity: 0;
    transition: opacity 0.4s ease;
}

.dashboard-card:hover {
    border-color: var(--accent-primary);
    box-shadow: var(--shadow-lg), var(--glow);
    transform: translateY(-4px);
}

.dashboard-card:hover::before {
    opacity: 0.5;
}

.dashboard-card .card-body {
    padding: 2rem;
    overflow-y: auto;
    flex: 1;
}

.dashboard-card .card-title {
    font-size: 1.125rem;
    font-weight: 600;
    margin-bottom: 2rem;
    display: flex;
    align-items: center;
    gap: 0.75rem;
    color: var(--text-primary);
    padding-bottom: 1rem;
    border-bottom: 1px solid var(--border-color);
}

.dashboard-card .card-title i {
    font-size: 1.5rem;
    color: var(--accent-primary);
    filter: drop-shadow(0 0 8px rgba(0, 212, 255, 0.4));
}

/* Alert Styles */
.alert-card {
    background: linear-gradient(135deg, rgba(255, 51, 102, 0.15) 0%, rgba(220, 38, 38, 0.1) 100%);
    border: 1px solid rgba(255, 51, 102, 0.3);
    border-radius: 16px;
    box-shadow: 0 8px 32px rgba(255, 51, 102, 0.2);
    animation: pulse-alert 3s ease-in-out infinite;
    backdrop-filter: blur(10px);
}

.alert-card.warning {
    background: linear-gradient(135deg, rgba(255, 170, 0, 0.15) 0%, rgba(249, 115, 22, 0.1) 100%);
    border-color: rgba(255, 170, 0, 0.3);
    box-shadow: 0 8px 32px rgba(255, 170, 0, 0.2);
}

.alert-card.info {
    background: linear-gradient(135deg, rgba(0, 212, 255, 0.15) 0%, rgba(8, 145, 178, 0.1) 100%);
    border-color: rgba(0, 212, 255, 0.3);
    box-shadow: 0 8px 32px rgba(0, 212, 255, 0.2);
}

@keyframes pulse-alert {
    0%, 100% {
        transform: scale(1);
        box-shadow: 0 8px 32px rgba(255, 51, 102, 0.2);
    }
    50% {
        transform: scale(1.01);
        box-shadow: 0 12px 40px rgba(255, 51, 102, 0.3);
    }
}

.alert-icon {
    font-size: 2.5rem;
    margin-right: 1.5rem;
    filter: drop-shadow(0 2px 8px rgba(0, 0, 0, 0.3));
}

/* Loading Spinner */
.loading-spinner {
    display: flex;
    justify-content: center;
    align-items: center;
    min-height: 200px;
}

.loading-spinner .spinner-border {
    width: 3rem;
    height: 3rem;
    border-width: 0.25rem;
    border-color: var(--accent-primary);
    border-right-color: transparent;
    animation: spinner-border 0.75s linear infinite;
}

@keyframes spinner-border {
    to {
        transform: rotate(360deg);
    }
}

/* Weather Specific Styles */
.weather-current {
    text-align: center;
    padding: 2rem 0;
}

.weather-temp {
    font-size: 5rem;
    font-weight: 200;
    font-family: 'JetBrains Mono', monospace;
    background: linear-gradient(135deg, var(--accent-primary), var(--accent-success));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    line-height: 1;
}

.weather-icon {
    font-size: 6rem;
    margin: 1.5rem 0;
    filter: drop-shadow(0 4px 8px rgba(0, 0, 0, 0.3));
}

.weather-description {
    font-size: 1.125rem;
    color: var(--text-secondary);
    text-transform: capitalize;
    margin-top: 0.5rem;
}

.weather-details {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 1rem;
    margin-top: 2rem;
}

.weather-detail-item {
    text-align: center;
    padding: 1.25rem;
    background: var(--bg-secondary);
    border: 1px solid var(--border-color);
    border-radius: 12px;
    transition: all 0.3s ease;
}

.weather-detail-item:hover {
    border-color: var(--accent-primary);
    background: var(--bg-card);
}

.weather-detail-item .label {
    font-size: 0.75rem;
    color: var(--text-muted);
    text-transform: uppercase;
    letter-spacing: 0.1em;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
}

.weather-detail-item .label i {
    color: var(--accent-primary);
}

.weather-detail-item .value {
    font-size: 1.5rem;
    font-weight: 600;
    margin-top: 0.75rem;
    color: var(--text-primary);
    font-family: 'JetBrains Mono', monospace;
}

/* Forecast */
.weather-forecast {
    display: grid;
    grid-template-columns: repeat(5, 1fr);
    gap: 0.75rem;
    margin-top: 2rem;
}

.forecast-day {
    text-align: center;
    padding: 1.25rem 0.75rem;
    background: var(--bg-secondary);
    border: 1px solid var(--border-color);
    border-radius: 12px;
    transition: all 0.3s ease;
}

.forecast-day:hover {
    background: var(--bg-card);
    border-color: var(--accent-primary);
    transform: translateY(-4px);
    box-shadow: 0 4px 12px rgba(0, 212, 255, 0.15);
}

.forecast-day .day {
    font-size: 0.75rem;
    color: var(--text-muted);
    text-transform: uppercase;
    letter-spacing: 0.05em;
    font-weight: 600;
}

.forecast-day .icon {
    font-size: 2.5rem;
    margin: 0.75rem 0;
}

.forecast-day .temp {
    font-weight: 600;
    color: var(--text-primary);
    font-size: 0.95rem;
    font-family: 'JetBrains Mono', monospace;
}

/* Air Quality */
.aqi-gauge {
    text-align: center;
    padding: 2.5rem 2rem;
}

.aqi-value {
    font-size: 5rem;
    font-weight: 200;
    font-family: 'JetBrains Mono', monospace;
    line-height: 1;
}

.aqi-label {
    font-size: 1rem;
    margin-top: 1rem;
    text-transform: uppercase;
    letter-spacing: 0.15em;
    font-weight: 600;
}

.aqi-good { 
    color: var(--accent-success);
    filter: drop-shadow(0 0 20px rgba(0, 255, 136, 0.3));
}

.aqi-moderate { 
    color: #fbbf24;
    filter: drop-shadow(0 0 20px rgba(251, 191, 36, 0.3));
}

.aqi-unhealthy { 
    color: var(--accent-warning);
    filter: drop-shadow(0 0 20px rgba(255, 170, 0, 0.3));
}

.aqi-very-unhealthy { 
    color: var(--accent-danger);
    filter: drop-shadow(0 0 20px rgba(255, 51, 102, 0.3));
}

.aqi-details {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 0.75rem;
    margin-top: 1.5rem;
}

.aqi-detail-item {
    padding: 1rem;
    background: var(--bg-secondary);
    border: 1px solid var(--border-color);
    border-radius: 10px;
    transition: all 0.3s ease;
}

.aqi-detail-item:hover {
    border-color: var(--accent-primary);
    background: var(--bg-card);
}

.aqi-detail-item .label {
    font-size: 0.7rem;
    color: var(--text-muted);
    text-transform: uppercase;
    letter-spacing: 0.05em;
    font-weight: 600;
}

.aqi-detail-item .value {
    font-size: 1.5rem;
    font-weight: 600;
    margin-top: 0.5rem;
    font-family: 'JetBrains Mono', monospace;
}

/* Traffic */
.traffic-list {
    list-style: none;
    padding: 0;
    margin: 0;
}

.traffic-item {
    padding: 1.25rem;
    margin-bottom: 0.75rem;
    background: var(--bg-secondary);
    border: 1px solid var(--border-color);
    border-left: 3px solid var(--accent-info);
    border-radius: 8px;
    transition: all 0.3s ease;
}

.traffic-item:hover {
    background: var(--bg-card);
    transform: translateX(4px);
    box-shadow: 0 4px 12px rgba(0, 212, 255, 0.1);
}

.traffic-item.traffic-warning {
    border-left-color: var(--accent-warning);
}

.traffic-item.traffic-blocked {
    border-left-color: var(--accent-danger);
}

.traffic-route {
    font-weight: 600;
    margin-bottom: 0.5rem;
    font-size: 1.05rem;
    color: var(--text-primary);
}

.traffic-status {
    font-size: 0.875rem;
    color: var(--text-secondary);
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.traffic-status i {
    color: var(--accent-info);
}

.traffic-item.traffic-warning .traffic-status i {
    color: var(--accent-warning);
}

.traffic-item.traffic-blocked .traffic-status i {
    color: var(--accent-danger);
}

/* News */
.news-list {
    list-style: none;
    padding: 0;
    margin: 0;
}

.news-item {
    padding: 1.25rem;
    margin-bottom: 0.75rem;
    background: var(--bg-secondary);
    border: 1px solid var(--border-color);
    border-radius: 12px;
    transition: all 0.3s ease;
    cursor: pointer;
    position: relative;
    overflow: hidden;
}

.news-item::before {
    content: '';
    position: absolute;
    left: 0;
    top: 0;
    bottom: 0;
    width: 3px;
    background: var(--accent-primary);
    transform: scaleY(0);
    transition: transform 0.3s ease;
}

.news-item:hover {
    background: var(--bg-card);
    border-color: var(--accent-primary);
    transform: translateX(4px);
    box-shadow: 0 4px 12px rgba(0, 212, 255, 0.15);
}

.news-item:hover::before {
    transform: scaleY(1);
}

.news-title {
    font-size: 1rem;
    font-weight: 600;
    margin-bottom: 0.5rem;
    color: var(--text-primary);
    line-height: 1.5;
}

.news-meta {
    font-size: 0.75rem;
    color: var(--text-muted);
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.news-meta i {
    color: var(--accent-primary);
}

/* Lippepegel */
.pegel-current {
    text-align: center;
    padding: 2.5rem 2rem;
}

.pegel-value {
    font-size: 4.5rem;
    font-weight: 200;
    font-family: 'JetBrains Mono', monospace;
    background: linear-gradient(135deg, var(--accent-info), var(--accent-primary));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    line-height: 1;
}

.pegel-trend {
    font-size: 1.125rem;
    margin-top: 1rem;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.75rem;
    font-weight: 600;
}

.pegel-trend.rising { 
    color: var(--accent-danger);
}

.pegel-trend.falling { 
    color: var(--accent-success);
}

.pegel-trend.stable { 
    color: var(--text-secondary);
}

.pegel-chart {
    margin-top: 2rem;
    height: 180px;
    padding: 0 1rem;
}

/* Calendar */
.calendar-list {
    list-style: none;
    padding: 0;
    margin: 0;
}

.calendar-item {
    padding: 1rem;
    margin-bottom: 0.75rem;
    background: var(--bg-secondary);
    border-radius: 8px;
    border-left: 4px solid var(--accent-primary);
    transition: all 0.3s ease;
}

.calendar-item:hover {
    background: var(--bg-card-hover);
    transform: translateX(5px);
}

.calendar-date {
    font-size: 0.85rem;
    color: var(--text-muted);
    margin-bottom: 0.5rem;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.calendar-title {
    font-weight: 600;
    font-size: 1.1rem;
    color: var(--text-primary);
}

/* Responsive Design */
@media (max-width: 1400px) {
    .time-display {
        font-size: 5rem;
    }
    
    .weather-temp {
        font-size: 4rem;
    }
    
    .pegel-value {
        font-size: 3.5rem;
    }
}

@media (max-width: 992px) {
    .time-display {
        font-size: 4rem;
    }
    
    .weather-forecast {
        grid-template-columns: repeat(3, 1fr);
    }
}

@media (max-width: 768px) {
    .time-display {
        font-size: 3rem;
    }
    
    .dashboard-card .card-body {
        padding: 1.5rem;
    }
}

/* Smooth Page Load Animation */
@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.dashboard-card {
    animation: fadeInUp 0.6s ease-out backwards;
}

.dashboard-card:nth-child(1) { animation-delay: 0.1s; }
.dashboard-card:nth-child(2) { animation-delay: 0.2s; }
.dashboard-card:nth-child(3) { animation-delay: 0.3s; }
.dashboard-card:nth-child(4) { animation-delay: 0.4s; }
.dashboard-card:nth-child(5) { animation-delay: 0.5s; }

.dashboard-header {
    animation: fadeInUp 0.8s ease-out;
}

/* Scrollbar Styling */
::-webkit-scrollbar {
    width: 10px;
    height: 10px;
}

::-webkit-scrollbar-track {
    background: var(--bg-secondary);
    border-radius: 5px;
}

::-webkit-scrollbar-thumb {
    background: var(--border-color);
    border-radius: 5px;
    transition: background 0.3s ease;
}

::-webkit-scrollbar-thumb:hover {
    background: var(--accent-primary);
}

/* Badge Styles */
.status-badge {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.375rem 1rem;
    border-radius: 100px;
    font-size: 0.75rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

.status-badge.success {
    background: rgba(0, 255, 136, 0.15);
    color: var(--accent-success);
    border: 1px solid rgba(0, 255, 136, 0.3);
}

.status-badge.warning {
    background: rgba(255, 170, 0, 0.15);
    color: var(--accent-warning);
    border: 1px solid rgba(255, 170, 0, 0.3);
}

.status-badge.danger {
    background: rgba(255, 51, 102, 0.15);
    color: var(--accent-danger);
    border: 1px solid rgba(255, 51, 102, 0.3);
}

.status-badge.info {
    background: rgba(0, 212, 255, 0.15);
    color: var(--accent-info);
    border: 1px solid rgba(0, 212, 255, 0.3);
}

/* Utility Classes */
.text-gradient {
    background: linear-gradient(135deg, var(--accent-primary), var(--accent-success));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}
