/* =========================================================
   HISTORICAL RAIN PAGE
   ========================================================= */
   body {
    background:
        radial-gradient(
            circle at 50% 0%,
            #1c242c 0%,
            #11161b 45%,
            #0d1115 100%
        );
    color:
        #e5e9ed;
    min-height:
        100vh;
}
.rain-page {
    width: min(900px, 94%);
    margin: 0 auto 50px auto;
}
/* ---------------------------------------------------------
   Page heading
   --------------------------------------------------------- */
.page-header {
    text-align: center;
    margin: 35px 0 30px 0;
}
.page-header h1 {
    margin: 0;
    font-size: 32px;
    font-weight: 500;
    color: #d6b56c;
    font-family:
        "Oswald",
        Arial,
        sans-serif;
}
/* ---------------------------------------------------------
   Rain cards
   --------------------------------------------------------- */
.rain-card {
    width: 100%;
    margin: 0 auto 35px auto;
    background:
        linear-gradient(
            145deg,
            #252b32,
            #171b20
        );
    border: 1px solid #3b444d;
    border-radius: 14px;
    overflow: hidden;
    box-shadow:
        0 8px 20px rgba(0, 0, 0, 0.30);
}
/* ---------------------------------------------------------
   Card heading
   --------------------------------------------------------- */
.rain-card-heading {
    padding: 14px 18px;
    background:
        linear-gradient(
            145deg,
            #3a434d,
            #292f36
        );
    color: #ffffff;
    font-size: 20px;
    font-weight: 500;
	font-family:
        "Oswald",
        Arial,
        sans-serif;
    text-align: center;
    border-bottom: 1px solid #3b444d;
}
/* ---------------------------------------------------------
   Heading / year selector
   --------------------------------------------------------- */
.rain-heading-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 20px;
}
.rain-year-form {
    display: flex;
    align-items: center;
    gap: 8px;
    margin: 0;
}
.rain-year-form label {
    font-size: 15px;
    font-weight: normal;
}
.rain-year-select {
    min-width: 95px;
    padding: 7px 10px;
    border: 1px solid #59636e;
    border-radius: 6px;
    background: #171c21;
    color: #ffffff;
    font-family: inherit;
    font-size: 15px;
    cursor: pointer;
}
/* ---------------------------------------------------------
   Table scrolling
   --------------------------------------------------------- */
.table-scroll {
    width: 100%;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
}
/* ---------------------------------------------------------
   Rain table
   --------------------------------------------------------- */
.rain-table {
    width: 100%;
    border-collapse: collapse;
    color: #ffffff;
    font-size: 16px;
    font-family:
        "Oswald",
        Arial,
        sans-serif;
}
.rain-table th {
    padding: 11px 14px;
    background: #303840;
    color: #ffffff;
    font-weight: 500;
    font-family:
        "Oswald",
        Arial,
        sans-serif;
    text-align: center;
    border-bottom: 1px solid #4a535d;
}
.rain-table td {
    padding: 10px 14px;
    text-align: center;
    border-bottom: 1px solid #303840;
}
/* Current month */
.rain-table tbody tr.current-month td:first-child {
    color: #b9a06a;
    font-weight: 600;
}
/* ---------------------------------------------------------
   Year / month cells
   --------------------------------------------------------- */
.year-cell,
.month-cell {
    font-weight: 500;
    font-family:
        "Oswald",
        Arial,
        sans-serif,
        roboto;
}
/* ---------------------------------------------------------
   Current year
   --------------------------------------------------------- */
.rain-table tr.current-year td:first-child {
    font-weight: 500;
    color: #d6b56c;
    font-family:
        "Oswald",
        Arial,
        sans-serif,
        roboto;
}
/* ---------------------------------------------------------
   Rainfall colors
   --------------------------------------------------------- */
.rain-table tbody td.rain-extreme-cold {
    background: #343f83;
}
.rain-table tbody td.rain-cold {
    background: #274b76;
}
.rain-table tbody td.rain-cool {
    background: #286b82;
}
.rain-table tbody td.rain-mild {
    background: #397c62;
}
.rain-table tbody td.rain-warm {
    background: #8a762c;
}
.rain-table tbody td.rain-hot {
    background: #a65a30;
}
.rain-table tbody td.rain-extreme-hot {
    background: #9d3838;
}

/* =========================================================
   RAINFALL ANALYSIS
   ========================================================= */

.rain-analysis-control {

    display: flex;

    align-items: center;

    gap: 7px;

    font-size: 0.85rem;

}


.rain-analysis-control label {

    color: #c2c8ce;

}


.rain-chart-container {

    position: relative;

    height: 250px;

    padding: 20px;

}

/* =========================================================
   RAINFALL VS. NORMAL SUMMARY
   ========================================================= */

.rainfall-summary-content {
    padding: 24px;
}


/* BAR GROUP */

.rainfall-bar-group {
    margin-bottom: 24px;
}

.rainfall-label {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 15px;

    margin-bottom: 9px;

    color: #e4e9ee;
    font-size: 14px;
    font-weight: 600;
    letter-spacing: 0.5px;
}

.rainfall-label strong {
    font-size: 17px;
    font-weight: 700;
    white-space: nowrap;
}


/* BAR TRACK */

.rainfall-track {
    width: 100%;
    height: 18px;

    overflow: hidden;

    background: #10161d;
    border: 1px solid #3b444d;
    border-radius: 5px;
}


/* BAR FILL */

.rainfall-fill {
    height: 100%;
    min-width: 0;

    border-radius: 4px;

    transition: width 0.4s ease;
}

.rainfall-actual {
    background: linear-gradient(
        90deg,
        #2879a8,
        #45a7cf
    );
}

.rainfall-normal {
    background: linear-gradient(
        90deg,
        #596572,
        #8996a3
    );
}


/* COMPARISON RESULTS */

.rainfall-comparison {
    display: flex;
    align-items: center;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 15px;

    margin-top: 27px;
    padding-top: 19px;

    border-top: 1px solid #3b444d;
}

.rainfall-difference {
    display: flex;
    flex-direction: column;
    gap: 5px;
}

.rainfall-status {
    font-size: 12px;
    font-weight: 700;
    letter-spacing: 1px;
}

.rainfall-difference strong {
    font-size: 28px;
    line-height: 1.2;
    font-weight: 700;
}

.rainfall-percent {
    font-size: 25px;
    font-weight: 700;
}


/* STATUS COLORS */

.rainfall-difference.above,
.rainfall-percent.above {
    color: #83c98a;
}

.rainfall-difference.below,
.rainfall-percent.below {
    color: #e6a36e;
}

.rainfall-difference.normal,
.rainfall-percent.normal {
    color: #d6b56c;
}


/* MOBILE */

@media (max-width: 600px) {

    .rainfall-summary-content {
        padding: 18px;
    }

    .rainfall-label {
        font-size: 12px;
    }

    .rainfall-label strong {
        font-size: 15px;
    }

    .rainfall-comparison {
        align-items: flex-start;
    }

    .rainfall-difference strong {
        font-size: 25px;
    }

    .rainfall-percent {
        font-size: 22px;
    }
}


/* ---------------------------------------------------------
   MOBILE / IPAD
   --------------------------------------------------------- */

@media (max-width: 768px) {

    .rain-chart-container {

        height: 400px;

        padding: 10px;

    }

}
/* ---------------------------------------------------------
   Mobile
   --------------------------------------------------------- */
@media (max-width: 600px) {
    .rain-page {
        width: 96%;
    }
    .rain-card-heading {
        font-size: 18px;
    }
    .rain-heading-row {
        flex-direction: column;
        gap: 10px;
    }
    .rain-table {
        min-width: 420px;
    }
}
