﻿/* === Base Section Styling === */
.home-card-section {
    background-color: #f9f9f9;
    padding: 30px 20px;
}

/* === Section Headings === */
.section-title {
    font-size: 2rem;
    font-weight: 700;
    color: #1c7c54;
    margin-bottom: 20px;
    position: relative;
    display: inline-block;
}

    .section-title::after {
        content: "";
        display: block;
        width: 80px;
        height: 3px;
        background: #ffd700;
        margin: 10px auto 0;
        border-radius: 2px;
        transition: width 0.3s ease;
    }

    .section-title:hover::after {
        width: 120px;
    }

/* === Shared Card Style === */
.irsa-card {
    background: linear-gradient(135deg, #f0fff7, #fffeef);
    border-radius: 16px;
    padding: 30px 25px;
    text-align: center;
    position: relative;
    box-shadow: 0 6px 18px rgba(0,0,0,0.08);
    transition: all 0.4s ease;
    height: 100%;
}

    .irsa-card:hover {
        transform: translateY(-6px) !important;
        box-shadow: 0 10px 24px rgba(0,0,0,0.15);
    }

/* === Paragraph Text === */
.irsa-text {
    font-size: 1.05rem;
    line-height: 1.75;
    color: #444;
}

/* === Buttons === */
.irsa-btn {
    display: inline-block;
    margin-top: 20px;
    padding: 10px 24px;
    font-size: 14px;
    font-weight: 600;
    color: #fff;
    background: #1c7c54;
    border: none;
    border-radius: 25px;
    box-shadow: 0 4px 12px rgba(28,124,84,0.25);
    transition: all 0.3s ease;
    text-decoration: none;
}

    .irsa-btn:hover {
        background: #145a32;
        transform: translateY(-2px);
        box-shadow: 0 6px 18px rgba(20,90,50,0.35);
    }

/* === Data Table === */
#dashboardTable thead th {
    white-space: nowrap;
    text-align: center;
    vertical-align: middle;
    font-weight: 600;
    font-size: 14px;
    background: #1c7c54 !important;
    color: #fff !important;
    text-transform: uppercase;
}

#dashboardTable td {
    font-size: 0.95rem;
    vertical-align: middle;
}

.table-hover tbody tr:hover {
    background-color: rgba(16, 133, 99, 0.12) !important;
    transition: 0.2s;
}

/*Flood Situation*/
.flood-status {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    padding: 4px 14px;
    border-radius: 20px;
    font-weight: 600;
    font-size: 0.9rem;
    min-width: 120px;
    text-transform: capitalize;
    box-shadow: 0 3px 8px rgba(0,0,0,0.15);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}


    /* Normal Flow (Green) */
    .flood-status.normal {
        background: linear-gradient(135deg, #22c55e, #15803d);
        color: #fff;
    }

    /* Low Flood (Blue) */
    .flood-status.low {
        background: linear-gradient(135deg, #2563eb, #1d4ed8);
        color: #fff;
    }

    /* Medium Flood (Yellow) */
    .flood-status.medium {
        background: linear-gradient(135deg, #eab308, #ca8a04);
        color: #000; /* better contrast on yellow */
        font-weight: 600;
    }

    /* High Flood (Orange) */
    .flood-status.high {
        background: linear-gradient(135deg, #f97316, #ea580c);
        color: #fff;
        animation: pulse 2s infinite, glow 1.5s infinite alternate;
    }

    /* Very High Flood (Red) */
    .flood-status.veryhigh {
        background: linear-gradient(135deg, #ef4444, #dc2626);
        color: #fff;
        animation: pulse 2s infinite, glow 1.5s infinite alternate;
    }

    /* Exceptional Flood (Dark Red) */
    .flood-status.exceptional {
        background: linear-gradient(135deg, #991b1b, #7f1d1d);
        color: #fff;
        font-weight: bold;
        animation: blink 1.5s infinite, glow 1.8s infinite alternate;
    }

/* Animations */
@keyframes pulse {
    0%, 100% {
        transform: scale(1);
    }

    50% {
        transform: scale(1.05);
    }
}

@keyframes blink {
    0%, 100% {
        opacity: 1;
    }

    50% {
        opacity: 0.6;
    }
}

@keyframes glow {
    from {
        box-shadow: 0 0 10px rgba(239,68,68,0.6), 0 0 20px rgba(220,38,38,0.5);
    }

    to {
        box-shadow: 0 0 25px rgba(220,38,38,0.9), 0 0 40px rgba(239,68,68,0.8);
    }
}

/* Hover lift effect */
.flood-status:hover {
    transform: scale(1.05);
    box-shadow: 0 5px 15px rgba(0,0,0,0.25);
}

/*Flood Situation*/

/*=== Blink Alert ====*/
.blink-alert {
    color: #fff !important;
    background-color: #e74c3c;
    font-weight: bold;
    padding: 5px 20px;
    border-radius: 8px;
    animation: blinker 1s linear infinite;
    box-shadow: 0 0 12px rgba(231, 76, 60, 0.8);
    transition: transform 0.2s ease-in-out, background-color 0.2s;
    text-decoration: none;
}

@keyframes blinker {
    50% {
        opacity: 0;
    }
}

.blink-alert:hover {
    color: white;
    background-color: #c0392b;
    transform: scale(1.05);
    box-shadow: 0 0 18px rgba(192, 57, 43, 0.9);
}
/*=================================
====== Map & Discharge Cards=======
==================================*/
/* ===  === */
.map-card img {
    width: 100%;
    border-radius: 12px;
    box-shadow: 0 4px 14px rgba(0,0,0,0.1);
    transition: transform 0.3s ease;
}

    .map-card img:hover {
        transform: scale(1.02);
    }

.card-icon img {
    height: 70px;
    width: 70px;
    object-fit: contain;
    margin-bottom: 12px;
}

/* === Responsive === */
@media (max-width: 768px) {
    .ministry-card {
        min-width: 100% !important;
        max-width: 100% !important;
        flex: 0 0 100%;
    }
}
/*================================
======== monitoring Section =========
==================================*/
.monitoring-section {
    background: linear-gradient(135deg, #12121c, #1e1e2f);
    padding: 20px;
}

.monitoring-card {
    padding: 10px;
    transition: all 0.4s ease;
}

.chart:hover {
    transform: translateY(-6px);
    box-shadow: 0 14px 32px rgba(0,0,0,0.3);
}

/*================================
======== Station Section =========
==================================*/
.station-card {
    background: linear-gradient(135deg, #ffffff, #fffdf7);
    border-radius: 16px;
    padding: 20px;
    border: 1px solid #eee;
    box-shadow: 0 6px 18px rgba(0,0,0,0.08);
    height: 100%;
    transition: all 0.4s ease;
}

.table-responsive {
    max-height: 565px;
}

.station-card:hover {
    transform: translateY(-6px) !important;
    box-shadow: 0 10px 24px rgba(0,0,0,0.15);
}

.station-card .section-title {
    color: #145a32;
    font-weight: 700;
    font-size: 24px;
    margin-bottom: 16px;
    padding-bottom: 6px;
}

.map-wrapper {
    text-align: center;
}

.map-img {
    width: 100%;
    max-height: 100%;
    object-fit: cover;
    border-radius: 12px;
    transition: transform 0.3s ease;
    cursor: pointer;
}

.map-img:hover {
    transform: scale(1.01);
}

.map-note {
    margin-top: 8px;
    font-size: 12px;
}

.ads-img {
    width: 100%;
    max-height: 100%;
    object-fit: cover;
    border-radius: 12px;
    transition: transform 0.3s ease;
    cursor: pointer;
}

.irsaAds-wrapper {
    display: block !important;
    text-align: center;
}

.ads-img:hover {
    transform: scale(1.01);
}


/*================================
======== Ministry Section ========
==================================*/
/* Wrapper */
.slider-wrapper {
    position: relative;
    display: flex;
    align-items: center;
}

/* Scroll area */
.ministries-slider {
    display: flex;
    gap: 20px;
    overflow: hidden;
    scroll-behavior: smooth;
    padding: 20px 10px;
}

/* Card */
.ministry-card {
    flex: 0 0 auto;
    min-width: 280px;
    max-width: 320px;
    background: linear-gradient(135deg, #ffffff, #f9f6ef);
    border-radius: 18px;
    padding: 24px 18px;
    text-align: center;
    box-shadow: 0 8px 20px rgba(0,0,0,0.08);
    transition: all 0.4s ease;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    border: 2px solid transparent;
}

    .ministry-card:hover {
        transform: translateY(-10px) scale(1.03);
        box-shadow: 0 15px 35px rgba(0,0,0,0.18);
        border-color: #d4af37;
        background: linear-gradient(135deg, #fffdf8, #fefae8);
    }

.card-icon img {
    height: 90px;
    width: 90px;
    object-fit: contain;
    margin-bottom: 15px;
    transition: transform 0.3s ease;
}

.ministry-card:hover .card-icon img {
    transform: scale(1.15) rotate(3deg);
}

.card-content h6 {
    font-size: 16px;
    font-weight: 700;
    color: #2c3e50;
    margin-bottom: 10px;
}

.card-content p {
    font-size: 13px;
    color: #555;
    flex-grow: 1;
    margin-bottom: 15px;
    line-height: 1.4;
}

/* Visit button */
.visit-btn {
    font-size: 13px;
    font-weight: 600;
    padding: 8px 18px;
    border-radius: 25px;
    background: linear-gradient(135deg, #145a32, #1d8348);
    border: none;
    color: #fff;
    box-shadow: 0 4px 10px rgba(20, 90, 50, 0.4);
    transition: all 0.3s ease;
}

    .visit-btn:hover {
        background: linear-gradient(135deg, #1d8348, #145a32);
        box-shadow: 0 6px 14px rgba(20, 90, 50, 0.6);
        transform: translateY(-2px);
    }

/* Buttons */
.slider-btn {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    background: #fff;
    border: none;
    color: #145a32;
    font-size: 22px;
    cursor: pointer;
    padding: 12px;
    border-radius: 50%;
    box-shadow: 0 4px 10px rgba(0,0,0,0.2);
    transition: all 0.3s;
    z-index: 5;
}

    .slider-btn:hover {
        background: #145a32;
        color: #fff;
        transform: translateY(-50%) scale(1.1);
    }

.prev-btn {
    left: -30px;
}

.next-btn {
    right: -30px;
}

/* Responsive */
@@media (max-width: 992px) {
    .ministry-card {
        min-width: 240px;
    }

    .card-icon img {
        height: 70px;
        width: 70px;
    }
}

@@media (max-width: 768px) {
    .ministry-card {
        min-width: 220px;
        padding: 18px;
    }

    .ministries-slider {
        gap: 14px;
    }
}

@@media (max-width: 576px) {
    .ministries-slider {
        overflow-x: auto;
        scroll-snap-type: x mandatory;
        gap: 12px;
    }

    .ministry-card {
        flex: 0 0 100%;
        max-width: 100%;
        scroll-snap-align: center;
    }

    .slider-btn {
        display: none;
    }
    /* hide buttons on mobile, swipe instead */
}

/*================================
======== Latest Updates Section ========
==================================*/
.updates-card {
    padding: 20px;
    border-radius: 12px;
    background: #fff;
    box-shadow: 0 4px 15px rgba(0,0,0,0.08);
}

.updates-wrapper {
    height: 350px;
    overflow: hidden;
    position: relative;
}

.updates-list {
    list-style: none;
    padding: 0;
    margin: 0;
}

.update-item {
    display: flex;
    gap: 15px;
    padding: 12px;
    margin-bottom: 12px;
    border-radius: 10px;
    background: #fafafa;
    transition: all 0.3s ease;
    align-items: center;
}

    .update-item:hover {
        background: #f3fdf7;
        transform: translateX(5px);
        box-shadow: 0 2px 6px rgba(0,0,0,0.05);
    }

.update-date {
    text-align: center;
    min-width: 60px;
}

.date-badge {
    display: block;
    font-size: 18px;
    font-weight: 700;
    color: #fff;
    background: #2d7a46;
    padding: 6px 10px;
    border-radius: 6px;
}

.month {
    font-size: 14px;
    color: #666;
    margin-top: 4px;
    display: block;
}

.update-content {
    flex: 1;
}

.update-link {
    font-size: 15px;
    font-weight: 600;
    color: #222;
    text-decoration: none;
}

    .update-link:hover {
        color: #2d7a46;
        text-decoration: underline;
    }

.update-more {
    display: inline-block;
    margin-top: 4px;
    font-size: 13px;
    color: #937017;
    text-decoration: none;
}

    .update-more:hover {
        text-decoration: underline;
    }

.see-all {
    text-align: center;
    margin-top: 15px;
}

.btn-see-all {
    display: inline-block;
    padding: 8px 18px;
    background: #2d7a46;
    color: #fff;
    border-radius: 20px;
    font-size: 13px;
    font-weight: 600;
    text-decoration: none;
    transition: background 0.3s;
}

    .btn-see-all:hover {
        background: #256337;
    }

/*================================
======== Person Section ==========
================================*/
.person-wrapper {
    display: flex;
    flex-direction: column;
    gap: 1.2rem;
}

.person-card {
    display: flex;
    align-items: center;
    background: linear-gradient(135deg, #fdfdfd, #f3f9f5);
    border-left: 5px solid #2d7a46; /* green accent */
    border-radius: 14px;
    padding: 12px 16px;
    box-shadow: 0 3px 8px rgba(0,0,0,0.08);
    transition: transform 0.3s, box-shadow 0.3s;
    flex-wrap: wrap; /* allows stacking when screen is too small */
}

    .person-card:hover {
        transform: translateY(-4px);
        box-shadow: 0 6px 16px rgba(0,0,0,0.12);
        background: linear-gradient(135deg, #fefefe, #edf7f0);
    }

.person-img {
    width: 190px;
    height: 190px;
    object-fit: cover;
    border-radius: 50%;
    margin-right: 15px;
    border: 2px solid #2d7a46;
    flex-shrink: 0;
}

.person-info {
    flex: 1;
    min-width: 180px; /* keeps text from squeezing too much */
}

.person-name {
    font-size: 1rem;
    font-weight: 600;
    color: #035630;
    margin: 0;
    text-align: left;
}

.person-role {
    font-size: 0.9rem;
    color: #555;
    margin: 4px 0 0;
    text-align: left;
}

/*===============================
======= Person Section =======
================================*/

/* Tablets */
@media (max-width: 768px) {
    .person-card {
        flex-direction: column;
        align-items: center;
        text-align: center;
        padding: 16px;
    }

    .person-img {
        margin: 0 0 12px 0;
        width: 110px;
        height: 110px;
    }

    .person-info {
        text-align: center;
    }

    .person-name {
        font-size: 1.05rem;
    }

    .person-role {
        font-size: 0.95rem;
    }
}

/* Mobile */
@media (max-width: 480px) {
    .person-img {
        width: 90px;
        height: 90px;
    }

    .person-name {
        font-size: 0.95rem;
    }

    .person-role {
        font-size: 0.85rem;
    }
}
