﻿
:root {
    /* Government-style palette */
    --gov-deep: #0d47a1; /* deep government blue (primary) */
    --gov-mid: #1976d2; /* medium blue for gradients */
    --gov-accent: #ff9933; /* saffron accent for highlights */
    --gov-light: #e9f6ff; /* very light blue background */
    --muted: #6c757d;
    --card-bg: #ffffff;
    /* Additional color tokens from previous theme */
    --water-blue: #00a8e8;
    --success-green: #28a745;
    --warning-orange: #ff8c00;
}

body {
    background: var(--gov-light);
    min-height: 100vh;
    color: #0b2546;
}

.card-header {
    border-bottom: none;
    padding: 1rem 0.5rem;
    border-radius: 0.5rem 0.5rem 0 0;
}

.nav-tabs {
    border-bottom: none;
}

    .nav-tabs .nav-item {
        margin: 0 10px;
    }

    .nav-tabs .nav-link.tab-custom {
        font-weight: 600;
        color: black;
        background-color: rgba(255, 255, 255, 0.15);
        border: none;
        border-radius: 50px;
        padding: 0.6rem 1.5rem;
        transition: all 0.3s ease;
    }

        .nav-tabs .nav-link.tab-custom:hover {
            background-color: rgba(255, 255, 255, 0.3);
            color: #fff;
        }

        .nav-tabs .nav-link.tab-custom.active {
            background-color: #ffffff;
            color: #007bff;
            box-shadow: 0 4px 10px rgba(0, 0, 0, 0.2);
        }

.chart-container {
    width: 100PX;
    height: 100PX;
    margin: 0 auto;
}
/* Header Section */
.dashboard-header {
    background: linear-gradient(135deg, var(--gov-deep) 0%, var(--gov-mid) 100%);
    color: white;
    padding: 2.2rem 0;
    box-shadow: 0 6px 18px rgba(11, 37, 70, 0.08);
    border-radius: 8px;
}

    .dashboard-header h1 {
        font-weight: 700;
        font-size: 2.25rem;
        margin-bottom: 0.25rem;
        letter-spacing: 0.2px;
    }

    .dashboard-header p.lead {
        opacity: 0.95;
        margin-bottom: 0.15rem;
    }

/* Stat Cards */
.stat-card {
    background: var(--card-bg);
    border-radius: 12px;
    padding: 1.25rem;
    box-shadow: 0 4px 14px rgba(11, 37, 70, 0.06);
    transition: transform 0.22s ease, box-shadow 0.22s ease;
    border-top: 4px solid var(--gov-deep);
    height: 100%;
}

    .stat-card:hover {
        transform: translateY(-6px);
        box-shadow: 0 8px 28px rgba(11, 37, 70, 0.10);
    }

    .stat-card h6 {
        color: var(--muted);
        font-size: 0.85rem;
        font-weight: 600;
        text-transform: uppercase;
        margin-bottom: 0.35rem;
    }

    .stat-card h3 {
        color: var(--gov-deep);
        font-weight: 700;
        font-size: 1.6rem;
        margin-bottom: 0.35rem;
    }

    .stat-card .subtext {
        color: var(--muted);
        font-size: 1rem;
    }

/* Reusable Icon Box */
.icon-box {
    width: 60px;
    height: 60px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.6rem;
    color: white;
    background: linear-gradient(135deg, var(--gov-mid), var(--gov-deep));
    margin-bottom: 0.8rem;
    box-shadow: 0 6px 16px rgba(11, 37, 70, 0.08);
}


/* Chart and Table Cards */
.chart-card3, .table-card {
    background: var(--card-bg);
    border-radius: 12px;
    padding: 1.5rem;
    box-shadow: 0 4px 18px rgba(11, 37, 70, 0.06);
    margin-bottom: 1.25rem;
    height: 350px;
    width: 350px;
}

.chart-card4 h4 {
    color: var(--gov-deep);
    font-weight: 600;
    display: flex;
    align-items: center;
    gap: 0.5rem;
    margin-bottom: 1rem;
}


.chart-card4 canvas {
    background: var(--card-bg);
    border-radius: 12px;
    padding: 1.5rem;
    box-shadow: 0 4px 18px rgba(11, 37, 70, 0.06);
    margin-bottom: 1.25rem;
    margin-left: 4.25rem;
    width: 520px !important;
    height: 500px !important;
}

.table-card {
    overflow-x: auto;
}

.table-custom thead {
    background: linear-gradient(135deg, var(--gov-mid), var(--gov-deep));
    color: white;
}

    .table-custom thead th {
        border: none;
        padding: 0.9rem;
        font-weight: 600;
        text-align: center;
        font-size: 0.9rem;
    }

.table-custom tbody td {
    padding: 0.8rem;
    vertical-align: middle;
    border-color: #eaeef4;
    color: #0b2546;
}

.table-custom tbody tr:hover {
    background: #f2fbff;
}

/* Badges */
.badge-water,
.badge-water-dark {
    color: white;
    padding: 0.4rem 0.65rem;
    border-radius: 20px;
    font-weight: 600;
    font-size: 0.85rem;
}

.badge-water {
    background: var(--gov-mid);
}

.badge-water-dark {
    background: var(--gov-deep);
}


.stat-badge {
    background: var(--water-blue);
    color: white;
    padding: 0.4rem 1rem;
    border-radius: 20px;
    font-size: 0.9rem;
    font-weight: 600;
    margin: 0.25rem;
}

.authority-badge {
    background: var(--success-green);
    color: white;
    padding: 0.5rem 1rem;
    border-radius: 25px;
    font-weight: 600;
    display: inline-block;
    margin-bottom: 1rem;
}


/* Progress Bars */
.progress-custom {
    height: 28px;
    border-radius: 14px;
    background: var(--gov-light);
}

.progress-bar-water {
    background: linear-gradient(90deg, var(--gov-mid), var(--gov-deep));
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-weight: 700;
}

/* Section Headers */
.phase-header,
.section-header {
    background: linear-gradient(135deg, var(--gov-mid), var(--gov-deep));
    color: white;
    padding: 1rem 1.5rem;
    border-radius: 10px;
    margin-bottom: 1.5rem;
    display: flex;
    align-items: center;
    gap: 1rem;
}

    .phase-header h3,
    .section-header h2 {
        margin: 0;
        font-weight: 600;
    }

    .phase-header i,
    .section-header i {
        font-size: 1.6rem;
    }

/* Component Card */
.component-card {
    background: var(--gov-light);
    border-radius: 10px;
    padding: 1.5rem;
    margin-bottom: 1.5rem;
    border-left: 4px solid var(--gov-deep);
    transition: all 0.3s ease;
}

    .component-card:hover {
        background: #d9ebff;
        border-left-width: 6px;
    }

    .component-card h4 {
        color: var(--gov-mid);
        font-weight: 600;
        margin-bottom: 1rem;
        display: flex;
        align-items: center;
        gap: 0.5rem;
    }



/* List Styling */
.list-custom li {
    padding: 0.5rem 0;
    border-bottom: 1px solid #e0e0e0;
}

    .list-custom li:last-child {
        border-bottom: none;
    }

/* Summary Box */
.summary-box {
    background: linear-gradient(135deg, var(--gov-mid), var(--gov-deep));
    color: white;
    border-radius: 12px;
    padding: 1.6rem;
    box-shadow: 0 8px 26px rgba(11, 37, 70, 0.12);
}

.summary-stat {
    background: rgba(255, 255, 255, 0.08);
    border-radius: 8px;
    padding: 0.85rem;
    margin-bottom: 0.8rem;
}

    .summary-stat h5 {
        margin: 0;
        font-weight: 600;
    }

/* Map Placeholder */
.map-placeholder {
    height: 140px;
    border-radius: 10px;
    border: 1px dashed rgba(13, 71, 161, 0.12);
    background: linear-gradient(180deg, #eef8ff, #ffffff);
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--gov-deep);
    font-weight: 600;
}

/* Accordion Styling */
.accordion-button:not(.collapsed) {
    background: var(--gov-deep);
    color: white;
}

.accordion-button:focus {
    box-shadow: 0 0 0 0.25rem rgba(13, 71, 161, 0.25);
}

/* Responsive Styles */
@media (max-width: 768px) {
    .dashboard-header h1 {
        font-size: 1.6rem;
    }

    .stat-card h3 {
        font-size: 1.3rem;
    }
}
/* Section Headings (I, II, etc.) */
.section-heading {
    background: #0d6efd;
    color: #fff;
    padding: 0.5rem 1rem;
    border-radius: 0.4rem;
    margin-bottom: 0.5rem;
}

    .section-heading h2 {
        font-size: 1.2rem;
        font-weight: 600;
        margin: 0;
    }

/* Accordion Buttons */
.accordion-button {
    font-weight: 600;
    font-size: 1rem;
}

.chart-card canvas {
    height: 150px;
    align-content: center;
}

.chart-card h4 {
    font-size: 1rem;
    margin-bottom: 0.75rem;
}

.chart-card {
    background: #fff;
    border-radius: 12px;
    padding: 20px;
    text-align: center;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.08);
    transition: transform 0.2s ease;
}

    .chart-card:hover {
        transform: translateY(-4px);
    }

    .chart-card h5 {
        font-weight: 700;
        color: #0d47a1;
        margin-bottom: 15px;
    }

    .chart-card canvas {
        width: 100% !important;
        height: 320px !important;
    }

.total-box {
    text-align: center;
    margin-top: 10px;
    font-weight: bold;
    color: #d32f2f;
    border: 1px solid #ccc;
    background: #fdfdfd;
    padding: 5px 12px;
    border-radius: 6px;
    display: inline-block;
}





/* for Financial */

/* Large chart container (unused in 3-component chart, but fixed) */
.chart-large {
    width: 650px;
    height: 600px;
    position: relative;
    margin: auto;
}

/* Chart box (responsive) */
.chart-box {
    width: 100%;
    max-width: 400px;
    height: 400px;
    position: relative;
    margin: auto;
}

/* Unified chart SVG (no duplicates now) */
.chart-svg {
    width: 100% !important;
    height: 100% !important;
    position: absolute;
    top: 0;
    left: 0;
}

/* Label boxes */
.label-box,
.large-label-box {
    position: absolute;
    background: #fff;
    padding: 6px 14px;
    border-radius: 6px;
    font-weight: 600;
    font-size: 14px;
    white-space: nowrap;
    box-shadow: 0 2px 6px rgba(0,0,0,0.15);
    transform: translate(-50%, -50%);
    z-index: 100;
}

/* Percent text inside donut */
.percent-text {
    fill: #fff;
    font-size: 20px;
    font-weight: 700;
    text-anchor: middle;
}

/* Total text underline */
.totalBg {
    position: relative;
    display: inline-block;
    color: #000;
    font-weight: 600;
}

    .totalBg::after { /* FIXED — space removed */
        content: "";
        position: absolute;
        left: 0;
        right: 0;
        bottom: -6px;
        height: 3px;
        background: rgba(255, 0, 0, 1);
        border-radius: 5px;
        box-shadow: 0 0 10px rgba(255, 0, 0, 0.8);
    }

/* Heading style */
.headline1 {
    font-weight: 700;
    font-size: 28px;
}

    .headline1 span {
        background: linear-gradient(90deg,#e3f2fd,#ffffff);
        padding: 4px 6px;
        border-radius: 10px;
        box-shadow: 0 3px 10px rgba(0,0,0,0.08);
    }

    .headline1 i {
        color: #0d6efd;
        font-size: 50px;
        vertical-align: middle;
    }

/* ================= MOBILE ================= */
@media (max-width: 768px) {

    .stat-card h3 {
        font-size: 1.2rem;
    }

    .chart-box {
        max-width: 330px;
    }

    .chart-large {
        max-width: 100%;
    }

    .headline1 {
        font-size: 18px;
        text-align: center;
    }

    .label-box {
        font-size: 10px;
        padding: 4px 8px;
    }
}

/* ================= SMALL MOBILE ================= */
@media (max-width: 480px) {

    .chart-box {
        max-width: 330px;
    }

    .headline1 {
        font-size: 16px;
    }

    .stat-card {
        padding: 1rem;
    }
}


/* ══════════════════════════════════════
   FINANCIAL SECTION — MOBILE DESKTOP VIEW
   ══════════════════════════════════════ */

#financialSection {
    /* Desktop layout force karo */
    min-width: 900px;
}

/* Yeh wrapper scroll allow karega */
.financial-scroll-wrapper {
    width: 100%;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch; /* iOS smooth scroll */
}

/* Mobile pe sirf financial section scroll hoga */
@media (max-width: 768px) {
    .financial-scroll-wrapper {
        border-radius: 8px;
    }

        /* Scroll hint — user ko pata chale swipe karna hai */
        .financial-scroll-wrapper::before {
            content: "← Swipe to view full chart →";
            display: block;
            text-align: center;
            font-size: 12px;
            color: #1976d2;
            background: #e3f2fd;
            padding: 4px 8px;
            border-radius: 4px;
            margin-bottom: 8px;
            font-weight: 600;
        }
}

@media (min-width: 769px) {
    .financial-scroll-wrapper::before {
        display: none;
    }
}
