﻿
/* ---------- RESET & BASE ---------- */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
}

body {
    background-color: #f4f7f6;
    color: #333;
    height: 100vh;
    display: flex;
    overflow: hidden;
}

/* ---------- SIDEBAR (fixed left) ---------- */
.sidebar {
    width: 250px;
    background-color: #1a237e;
    color: #fff;
    display: flex;
    flex-direction: column;
    padding: 20px 0;
    height: 100vh;
    flex-shrink: 0;
    box-shadow: 2px 0 5px rgba(0, 0, 0, 0.1);
    transition: width 0.3s ease;
}

.sidebar-header {
    padding: 0 20px 20px 20px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
    margin-bottom: 20px;
}

    .sidebar-header h2 {
        font-size: 18px;
        display: flex;
        align-items: center;
        gap: 10px;
    }

        .sidebar-header h2 i {
            color: #ffc107;
        }

.nav-menu {
    list-style: none;
    flex: 1;
    display: flex;
    flex-direction: column;
}

.nav-item {
    width: 100%;
}

.nav-link {
    display: flex;
    align-items: center;
    gap: 15px;
    padding: 15px 25px;
    color: #cfd8dc;
    text-decoration: none;
    font-size: 16px;
    transition: all 0.3s ease;
    cursor: pointer;
    border-left: 4px solid transparent;
}

    .nav-link i {
        width: 20px;
        text-align: center;
        font-size: 18px;
    }

    .nav-link:hover,
    .nav-link.active {
        background-color: rgba(255, 255, 255, 0.1);
        color: #fff;
        border-left-color: #ffc107;
    }

    .nav-link.logout {
        margin-top: auto;
        border-top: 1px solid rgba(255, 255, 255, 0.1);
    }

        .nav-link.logout:hover {
            color: #ff5252;
            border-left-color: #ff5252;
        }

/* ---------- MAIN CONTENT (scrollable) ---------- */
.main-content {
    flex: 1;
    display: flex;
    flex-direction: column;
    height: 100vh;
    overflow-y: auto;
    padding: 30px;
}

/* ---------- SEARCH BAR ---------- */
.search-container {
    display: flex;
    justify-content: center;
    margin-bottom: 25px;
    padding: 0 10px;
}

.search-wrapper {
    position: relative;
    width: 100%;
    max-width: 600px;
}

    .search-wrapper input {
        width: 100%;
        padding: 14px 20px;
        padding-right: 50px;
        border-radius: 30px;
        border: 1px solid #e0e0e0;
        background-color: #fff;
        font-size: 16px;
        box-shadow: 0 2px 8px rgba(0, 0, 0, 0.05);
        outline: none;
        transition: all 0.3s ease;
    }

        .search-wrapper input:focus {
            border-color: #1a237e;
            box-shadow: 0 4px 12px rgba(26, 35, 126, 0.15);
        }

    .search-wrapper i {
        position: absolute;
        right: 20px;
        top: 50%;
        transform: translateY(-50%);
        color: #888;
    }

/* ---------- DASHBOARD TITLE ---------- */
.dashboard-title {
    margin-bottom: 20px;
    font-size: 24px;
    color: #1a237e;
    font-weight: 700;
}

/* ---------- SCHEME GRID (4 columns per row) ---------- */
.schemes-grid {
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.grid-row {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 20px;
}

/* ---------- SCHEME CARD (with image) ---------- */
.scheme-card {
    background: #fff;
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.06);
    transition: transform 0.2s, box-shadow 0.2s;
    border: 1px solid #eee;
    display: flex;
    flex-direction: column;
    position: relative;
}

    .scheme-card:hover {
        transform: translateY(-5px);
        box-shadow: 0 8px 20px rgba(0, 0, 0, 0.1);
    }

/* ---- SCHEME IMAGE (themed dummy) ---- */
.scheme-image {
    width: 100%;
    height: 150px;
    background-color: #dce3ed;
    overflow: hidden;
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
}

    .scheme-image img {
        width: 100%;
        height: 100%;
        object-fit: cover;
        display: block;
    }

    .scheme-image .fallback-icon {
        position: absolute;
        font-size: 48px;
        color: #3f4a5e;
        opacity: 0.5;
        pointer-events: none;
    }

/* ---- "New" Tag ---- */
.new-tag {
    position: absolute;
    top: 10px;
    left: 10px;
    background-color: #ff3d00;
    color: #fff;
    font-size: 10px;
    font-weight: bold;
    padding: 3px 12px;
    border-radius: 12px;
    text-transform: uppercase;
    z-index: 2;
    letter-spacing: 0.5px;
}

/* ---- Card Body ---- */
.card-header {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 14px 16px 6px 16px;
}

.card-icon {
    width: 38px;
    height: 38px;
    background-color: #e8eaf6;
    color: #1a237e;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 16px;
    flex-shrink: 0;
}

.card-title {
    font-size: 15px;
    font-weight: 600;
    color: #1a237e;
    line-height: 1.2;
}

.card-body {
    padding: 4px 16px 12px 16px;
    font-size: 13px;
    color: #666;
    line-height: 1.5;
    flex: 1;
}

.card-footer {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 10px 16px 14px 16px;
    border-top: 1px solid #f0f0f0;
    margin-top: auto;
}

.govt-badge {
    font-size: 11px;
    background-color: #f1f8e9;
    color: #33691e;
    padding: 4px 12px;
    border-radius: 12px;
    display: inline-flex;
    align-items: center;
    gap: 5px;
}

.btn-apply {
    background-color: #1a237e;
    color: #fff;
    border: none;
    padding: 6px 16px;
    border-radius: 5px;
    cursor: pointer;
    font-size: 12px;
    font-weight: 600;
    transition: background 0.3s;
}

    .btn-apply:hover {
        background-color: #0d1452;
    }

/* ---------- RESPONSIVE ---------- */
@media (max-width: 1200px) {
    .grid-row {
        grid-template-columns: repeat(3, 1fr);
    }
}

@media (max-width: 992px) {
    .grid-row {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 768px) {
    body {
        flex-direction: column;
        overflow-y: auto;
        height: auto;
    }

    .sidebar {
        width: 100%;
        height: auto;
        padding: 10px 0;
    }

    .nav-menu {
        flex-direction: row;
        flex-wrap: wrap;
        justify-content: center;
    }

    .nav-link {
        padding: 10px 15px;
        border-left: none;
        border-bottom: 2px solid transparent;
    }

        .nav-link:hover,
        .nav-link.active {
            border-left-color: transparent;
            border-bottom-color: #ffc107;
        }

        .nav-link.logout {
            margin-top: 0;
            border-top: none;
        }

    .main-content {
        height: auto;
        padding: 20px;
    }
}

@media (max-width: 600px) {
    .grid-row {
        grid-template-columns: 1fr;
    }

    .scheme-image {
        height: 140px;
    }

    .search-container {
        padding: 0;
    }
}


