/* ============================================================
   Water Station Card Component - Light/Dark Mode Support
   ============================================================ */

.water-station-card {
    --status-color: #10b981;
    --status-glow: rgba(16, 185, 129, 0.3);

    /* Light mode defaults */
    background: linear-gradient(145deg, #ffffff 0%, #f8fafc 50%, #f1f5f9 100%);
    border-radius: 24px;
    position: relative;
    overflow: hidden;
    border: 1px solid rgba(0, 0, 0, 0.08);
    box-shadow: 0 10px 40px -10px rgba(0, 0, 0, 0.1);
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
}

.water-station-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 3px;
    background: linear-gradient(90deg, var(--status-color), transparent);
    opacity: 0.8;
}

.water-station-card:hover {
    transform: translateY(-8px) scale(1.02);
    box-shadow:
        0 25px 50px -12px rgba(0, 0, 0, 0.15),
        0 0 30px var(--status-glow);
    border-color: var(--status-color);
}

/* Status Variations */
.water-station-card.status-safe {
    --status-color: #10b981;
    --status-glow: rgba(16, 185, 129, 0.3);
}

.water-station-card.status-warning {
    --status-color: #f59e0b;
    --status-glow: rgba(245, 158, 11, 0.3);
}

.water-station-card.status-danger {
    --status-color: #ef4444;
    --status-glow: rgba(239, 68, 68, 0.4);
}

/* Wave Decoration */
.water-station-card .wave-decoration {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    height: 60px;
    overflow: hidden;
    opacity: 0.08;
    pointer-events: none;
}

.water-station-card .wave {
    position: absolute;
    bottom: 0;
    left: -100%;
    width: 300%;
    height: 100%;
    background-size: 50% 100%;
    animation: wsc-wave 8s linear infinite;
}

.water-station-card .wave-2 {
    opacity: 0.5;
    animation-delay: -4s;
    animation-duration: 10s;
}

@keyframes wsc-wave {
    0% { transform: translateX(0); }
    100% { transform: translateX(33.33%); }
}

/* Header */
.water-station-card .wsc-header {
    padding: 1.5rem 1.5rem 1rem;
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 1rem;
}

.water-station-card .station-info {
    flex: 1;
}

.water-station-card .station-code {
    font-family: 'JetBrains Mono', monospace;
    font-size: 0.7rem;
    font-weight: 500;
    color: #0891b2;
    letter-spacing: 0.1em;
    text-transform: uppercase;
    margin-bottom: 0.35rem;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.water-station-card .status-dot {
    width: 6px;
    height: 6px;
    background: var(--status-color);
    border-radius: 50%;
    animation: wsc-pulse-dot 2s ease-in-out infinite;
}

@keyframes wsc-pulse-dot {
    0%, 100% { opacity: 1; transform: scale(1); }
    50% { opacity: 0.5; transform: scale(1.2); }
}

.water-station-card .station-name {
    font-size: 1.25rem;
    font-weight: 700;
    color: #1e293b;
    line-height: 1.3;
    letter-spacing: -0.02em;
    margin: 0;
}

.water-station-card .station-location {
    font-size: 0.8rem;
    color: #64748b;
    margin-top: 0.25rem;
    display: flex;
    align-items: center;
    gap: 0.4rem;
}

.water-station-card .station-location i {
    font-size: 0.7rem;
    color: #0891b2;
}

/* Status Badge */
.water-station-card .status-badge {
    display: flex;
    align-items: center;
    gap: 0.4rem;
    padding: 0.4rem 0.8rem;
    border-radius: 20px;
    font-size: 0.7rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    background: rgba(255, 255, 255, 0.8);
    border: 1px solid var(--status-color);
    color: var(--status-color);
    box-shadow: 0 0 15px var(--status-glow);
}

.water-station-card .status-badge i {
    font-size: 0.6rem;
}

/* Level Section */
.water-station-card .wsc-level-section {
    padding: 0 1.5rem;
    margin-bottom: 1.25rem;
}

.water-station-card .level-display {
    background: rgba(241, 245, 249, 0.8);
    border-radius: 16px;
    padding: 1.25rem;
    position: relative;
    overflow: hidden;
    border: 1px solid rgba(0, 0, 0, 0.05);
}

.water-station-card .level-display::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(135deg, rgba(255, 255, 255, 0.5) 0%, transparent 50%);
    pointer-events: none;
}

.water-station-card .level-header {
    display: flex;
    align-items: baseline;
    justify-content: space-between;
    margin-bottom: 0.75rem;
}

.water-station-card .level-label {
    font-size: 0.75rem;
    color: #64748b;
    text-transform: uppercase;
    letter-spacing: 0.08em;
}

.water-station-card .level-trend {
    display: flex;
    align-items: center;
    gap: 0.3rem;
    font-size: 0.75rem;
    font-weight: 500;
}

.water-station-card .level-trend.trend-up { color: #dc2626; }
.water-station-card .level-trend.trend-down { color: #059669; }
.water-station-card .level-trend.trend-stable { color: #64748b; }

.water-station-card .level-value {
    display: flex;
    align-items: baseline;
    gap: 0.5rem;
}

.water-station-card .level-number {
    font-family: 'JetBrains Mono', monospace;
    font-size: 2.75rem;
    font-weight: 700;
    color: #0f172a;
    line-height: 1;
    letter-spacing: -0.03em;
}

.water-station-card .level-unit {
    font-size: 0.9rem;
    color: #64748b;
    font-weight: 500;
}

/* Progress Bar */
.water-station-card .level-progress {
    margin-top: 1rem;
}

.water-station-card .progress-labels {
    display: flex;
    justify-content: space-between;
    font-size: 0.65rem;
    color: #64748b;
    margin-bottom: 0.5rem;
    font-family: 'JetBrains Mono', monospace;
}

.water-station-card .progress-track {
    height: 8px;
    background: rgba(0, 0, 0, 0.1);
    border-radius: 10px;
    overflow: visible;
    position: relative;
}

.water-station-card .progress-fill {
    height: 100%;
    border-radius: 10px;
    background: linear-gradient(90deg, #10b981 0%, #f59e0b 70%, #ef4444 100%);
    position: relative;
    transition: width 1s cubic-bezier(0.4, 0, 0.2, 1);
}

.water-station-card .progress-fill::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(90deg, transparent 0%, rgba(255,255,255,0.4) 50%, transparent 100%);
    animation: wsc-shimmer 2s infinite;
}

@keyframes wsc-shimmer {
    0% { transform: translateX(-100%); }
    100% { transform: translateX(100%); }
}

.water-station-card .progress-marker {
    position: absolute;
    top: -6px;
    width: 2px;
    height: 20px;
    border-radius: 2px;
}

.water-station-card .progress-marker.warning-line {
    background: #f59e0b;
    box-shadow: 0 0 8px rgba(245, 158, 11, 0.4);
}

.water-station-card .progress-marker.danger-line {
    background: #ef4444;
    box-shadow: 0 0 8px rgba(239, 68, 68, 0.4);
}

/* Stats Grid */
.water-station-card .wsc-stats-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 1px;
    background: rgba(0, 0, 0, 0.06);
    margin: 0 1.5rem 1.25rem;
    border-radius: 12px;
    overflow: hidden;
}

.water-station-card .stat-item {
    background: rgba(248, 250, 252, 0.9);
    padding: 0.875rem 0.75rem;
    text-align: center;
    transition: background 0.3s ease;
}

.water-station-card .stat-item:hover {
    background: rgba(241, 245, 249, 1);
}

.water-station-card .stat-icon {
    font-size: 0.9rem;
    margin-bottom: 0.4rem;
    opacity: 0.8;
}

.water-station-card .stat-icon.stat-min { color: #059669; }
.water-station-card .stat-icon.stat-max { color: #dc2626; }
.water-station-card .stat-icon.stat-qmax { color: #0891b2; }

.water-station-card .stat-value {
    font-family: 'JetBrains Mono', monospace;
    font-size: 1rem;
    font-weight: 600;
    color: #1e293b;
    line-height: 1.2;
}

.water-station-card .stat-label {
    font-size: 0.65rem;
    color: #64748b;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    margin-top: 0.2rem;
}

/* Footer */
.water-station-card .wsc-footer {
    padding: 1rem 1.5rem 1.25rem;
    display: flex;
    align-items: center;
    justify-content: space-between;
    border-top: 1px solid rgba(0, 0, 0, 0.06);
    background: rgba(248, 250, 252, 0.5);
}

.water-station-card .last-update {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-size: 0.7rem;
    color: #64748b;
}

.water-station-card .last-update i {
    color: #0891b2;
    font-size: 0.65rem;
}

.water-station-card .action-buttons {
    display: flex;
    gap: 0.5rem;
}

.water-station-card .btn-action {
    width: 36px;
    height: 36px;
    border-radius: 10px;
    border: 1px solid rgba(0, 0, 0, 0.08);
    background: rgba(255, 255, 255, 0.9);
    color: #64748b;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: all 0.3s ease;
}

.water-station-card .btn-action:hover {
    background: #0891b2;
    border-color: #0891b2;
    color: #ffffff;
    transform: translateY(-2px);
    box-shadow: 0 5px 20px rgba(8, 145, 178, 0.3);
}

.water-station-card .btn-action i {
    font-size: 0.85rem;
}

/* ============================================================
   DARK MODE STYLES (.content-dark)
   ============================================================ */

.content-dark .water-station-card {
    background: linear-gradient(145deg, #111827 0%, #1a2234 50%, #0f172a 100%);
    border: 1px solid rgba(255, 255, 255, 0.08);
    box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.5);
}

.content-dark .water-station-card:hover {
    box-shadow:
        0 35px 60px -15px rgba(0, 0, 0, 0.6),
        0 0 40px var(--status-glow);
    border-color: var(--status-color);
}

/* Dark Mode Status Variations - Enhanced glow */
.content-dark .water-station-card.status-safe {
    --status-glow: rgba(16, 185, 129, 0.4);
}

.content-dark .water-station-card.status-warning {
    --status-glow: rgba(245, 158, 11, 0.4);
}

.content-dark .water-station-card.status-danger {
    --status-glow: rgba(239, 68, 68, 0.5);
}

/* Dark Mode Wave */
.content-dark .water-station-card .wave-decoration {
    opacity: 0.1;
}

/* Dark Mode Station Code */
.content-dark .water-station-card .station-code {
    color: #06b6d4;
}

/* Dark Mode Station Name */
.content-dark .water-station-card .station-name {
    color: #f1f5f9;
}

/* Dark Mode Location Icon */
.content-dark .water-station-card .station-location i {
    color: #06b6d4;
}

/* Dark Mode Status Badge */
.content-dark .water-station-card .status-badge {
    background: rgba(0, 0, 0, 0.3);
    box-shadow: 0 0 20px var(--status-glow);
}

/* Dark Mode Level Display */
.content-dark .water-station-card .level-display {
    background: rgba(30, 41, 59, 0.6);
    border: none;
}

.content-dark .water-station-card .level-display::before {
    background: linear-gradient(135deg, rgba(255, 255, 255, 0.03) 0%, transparent 50%);
}

/* Dark Mode Level Trend Colors */
.content-dark .water-station-card .level-trend.trend-up { color: #ef4444; }
.content-dark .water-station-card .level-trend.trend-down { color: #10b981; }

/* Dark Mode Level Number */
.content-dark .water-station-card .level-number {
    color: #f1f5f9;
    text-shadow: 0 0 30px var(--status-glow);
}

/* Dark Mode Level Unit */
.content-dark .water-station-card .level-unit {
    color: #94a3b8;
}

/* Dark Mode Progress Track */
.content-dark .water-station-card .progress-track {
    background: rgba(0, 0, 0, 0.4);
}

.content-dark .water-station-card .progress-fill::after {
    background: linear-gradient(90deg, transparent 0%, rgba(255,255,255,0.3) 50%, transparent 100%);
}

/* Dark Mode Stats Grid */
.content-dark .water-station-card .wsc-stats-grid {
    background: rgba(255, 255, 255, 0.08);
}

.content-dark .water-station-card .stat-item {
    background: rgba(30, 41, 59, 0.6);
}

.content-dark .water-station-card .stat-item:hover {
    background: rgba(51, 65, 85, 0.7);
}

.content-dark .water-station-card .stat-icon.stat-min { color: #10b981; }
.content-dark .water-station-card .stat-icon.stat-max { color: #ef4444; }
.content-dark .water-station-card .stat-icon.stat-qmax { color: #06b6d4; }

.content-dark .water-station-card .stat-value {
    color: #f1f5f9;
}

/* Dark Mode Footer */
.content-dark .water-station-card .wsc-footer {
    border-top: 1px solid rgba(255, 255, 255, 0.08);
    background: rgba(0, 0, 0, 0.2);
}

.content-dark .water-station-card .last-update i {
    color: #06b6d4;
}

/* Dark Mode Action Buttons */
.content-dark .water-station-card .btn-action {
    border: 1px solid rgba(255, 255, 255, 0.08);
    background: rgba(30, 41, 59, 0.6);
    color: #94a3b8;
}

.content-dark .water-station-card .btn-action:hover {
    background: #06b6d4;
    border-color: #06b6d4;
    color: #0a0f1a;
    box-shadow: 0 5px 20px rgba(6, 182, 212, 0.3);
}

/* ============================================================
   Station Cards Container - Light/Dark Mode
   ============================================================ */

.station-cards-container {
    background: linear-gradient(145deg, #ffffff 0%, #f8fafc 100%) !important;
    border-color: rgba(0, 0, 0, 0.08) !important;
}

.station-cards-title {
    color: #1e293b;
}

.station-cards-subtitle {
    color: #64748b;
}

.station-cards-badge {
    background: rgba(241, 245, 249, 0.9);
    color: #64748b;
    border: 1px solid rgba(0, 0, 0, 0.08);
}

/* Dark Mode Container */
.content-dark .station-cards-container {
    background: linear-gradient(145deg, #0f172a 0%, #1e293b 100%) !important;
    border-color: rgba(255, 255, 255, 0.08) !important;
}

.content-dark .station-cards-title {
    color: #f1f5f9;
}

.content-dark .station-cards-subtitle {
    color: #94a3b8;
}

.content-dark .station-cards-badge {
    background: rgba(30, 41, 59, 0.9);
    color: #94a3b8;
    border: 1px solid rgba(255, 255, 255, 0.08);
}

.station-cards-link {
    color: #0891b2;
}

.station-cards-link:hover {
    color: #06b6d4;
}

.content-dark .station-cards-link {
    color: #22d3ee;
}

.content-dark .station-cards-link:hover {
    color: #67e8f9;
}

/* ============================================================
   Responsive
   ============================================================ */

@media (max-width: 400px) {
    .water-station-card {
        border-radius: 20px;
    }

    .water-station-card .level-number {
        font-size: 2.25rem;
    }

    .water-station-card .stat-value {
        font-size: 0.9rem;
    }
}
