/* ================================================================
   GRAM PANCHAYAT MODALGAON - COMPREHENSIVE ENHANCEMENTS CSS
   Covers: Population Section, Leadership, Members, Gallery,
           Services, Contact, Certificates, Mobile Responsive
================================================================ */

/* ============================================================
   1. POPULATION SECTION - Light attractive background
============================================================ */
.population-section {
    background: linear-gradient(135deg, #e8f4f8 0%, #d4e6f1 35%, #e8f0fe 65%, #f0e6ff 100%) !important;
    padding: 70px 0 !important;
    position: relative;
    overflow: hidden;
}

.population-section::before {
    content: '';
    position: absolute;
    top: -80px;
    left: -80px;
    width: 350px;
    height: 350px;
    background: radial-gradient(circle, rgba(74, 0, 114, 0.06) 0%, transparent 70%);
    pointer-events: none;
}

.population-section::after {
    content: '';
    position: absolute;
    bottom: -60px;
    right: -60px;
    width: 300px;
    height: 300px;
    background: radial-gradient(circle, rgba(194, 24, 91, 0.07) 0%, transparent 70%);
    pointer-events: none;
}

.population-section .section-heading {
    background: linear-gradient(135deg, #4A0072, #C2185B) !important;
    -webkit-background-clip: text !important;
    background-clip: text !important;
    -webkit-text-fill-color: transparent !important;
    font-size: 2.2rem !important;
}

.population-section .heading-underline {
    background: linear-gradient(90deg, #4A0072, #C2185B) !important;
}

/* Population grid cards - styled for light background */
.pop-main-card {
    background: #ffffff !important;
    border: 1px solid rgba(74, 0, 114, 0.12) !important;
    border-radius: 20px !important;
    padding: 30px !important;
    box-shadow: 0 8px 32px rgba(74, 0, 114, 0.10) !important;
}

.pop-census-badge {
    background: linear-gradient(90deg, #4A0072, #C2185B) !important;
    color: #fff !important;
    font-size: 0.75rem !important;
    font-weight: 700 !important;
    padding: 5px 14px !important;
    border-radius: 20px !important;
    letter-spacing: 0.05em !important;
}

.pop-stat-item {
    border-bottom: 1px solid rgba(74, 0, 114, 0.08) !important;
    padding: 14px 0 !important;
}

.pop-stat-label {
    color: #555 !important;
    font-size: 0.9rem !important;
    font-weight: 500 !important;
}

.pop-stat-value {
    color: #4A0072 !important;
    font-weight: 800 !important;
    font-size: 1.3rem !important;
}

.pop-detail-card {
    background: #ffffff !important;
    border: 1px solid rgba(74, 0, 114, 0.12) !important;
    border-radius: 20px !important;
    padding: 30px !important;
    box-shadow: 0 8px 32px rgba(74, 0, 114, 0.10) !important;
}

.pop-detail-title {
    color: #4A0072 !important;
    font-size: 1.1rem !important;
    font-weight: 700 !important;
    margin: 0 0 20px !important;
    padding-bottom: 12px !important;
    border-bottom: 2px solid rgba(74, 0, 114, 0.1) !important;
}

.pop-village-card {
    background: #f8f5ff !important;
    border-radius: 12px !important;
    overflow: hidden !important;
    border: 1px solid rgba(74, 0, 114, 0.1) !important;
}

.pop-village-header {
    background: linear-gradient(90deg, rgba(74, 0, 114, 0.12), rgba(194, 24, 91, 0.08)) !important;
    border-bottom: 1px solid rgba(74, 0, 114, 0.1) !important;
}

.pop-village-name {
    color: #4A0072 !important;
    font-weight: 700 !important;
}

.pop-village-grid {
    background: rgba(74, 0, 114, 0.03) !important;
}

.pop-village-item {
    background: #ffffff !important;
    transition: background 0.2s;
}

.pop-village-item:hover {
    background: #f8f5ff !important;
}

.pop-village-label {
    color: #888 !important;
    font-size: 0.65rem !important;
    font-weight: 600 !important;
    letter-spacing: 0.08em !important;
    text-transform: uppercase !important;
}

.pop-village-value {
    color: #1a1a2e !important;
    font-weight: 700 !important;
}

.pop-village-value.highlight-val {
    color: #1d9a4a !important;
}

.pop-counters-card {
    display: flex !important;
    flex-direction: column !important;
    gap: 20px !important;
}

.pop-counter-item {
    background: #ffffff !important;
    border: 1px solid rgba(74, 0, 114, 0.1) !important;
    border-radius: 16px !important;
    padding: 25px 20px !important;
    text-align: center !important;
    box-shadow: 0 4px 16px rgba(74, 0, 114, 0.08) !important;
    transition: all 0.3s ease !important;
    position: relative;
    overflow: hidden;
}

.pop-counter-item::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 3px;
    background: linear-gradient(90deg, #4A0072, #C2185B);
}

.pop-counter-item:hover {
    transform: translateY(-5px) !important;
    box-shadow: 0 12px 35px rgba(74, 0, 114, 0.15) !important;
    background: #f8f5ff !important;
}

.pop-counter-num {
    color: #4A0072 !important;
    font-size: 2.2rem !important;
    font-weight: 800 !important;
}

.pop-counter-label {
    color: #666 !important;
    font-size: 0.85rem !important;
    font-weight: 500 !important;
    margin-top: 6px !important;
}

/* ============================================================
   2. NAVIGATION / MENU SECTION - Enhanced
============================================================ */
.navbar {
    background: linear-gradient(135deg, #ffffff 0%, #f8f5ff 100%) !important;
    box-shadow: 0 4px 20px rgba(74, 0, 114, 0.08) !important;
    border-bottom: 2px solid rgba(74, 0, 114, 0.06) !important;
}

.nav-item.active {
    color: #4A0072 !important;
    background: linear-gradient(135deg, rgba(74, 0, 114, 0.08), rgba(194, 24, 91, 0.05)) !important;
}

.nav-item.active::after {
    background: linear-gradient(90deg, #4A0072, #C2185B) !important;
    transform: translateX(-50%) scaleX(1) !important;
    width: 80% !important;
}

/* ============================================================
   3. HOME PAGE - No blank space improvements
============================================================ */
.quick-links-grid {
    margin-top: -80px !important;
    margin-bottom: 0 !important;
    padding-bottom: 0 !important;
}

.home-gp-members-section {
    padding: 60px 0 !important;
    background: linear-gradient(135deg, #fdfbff 0%, #f0ebff 100%) !important;
}

.split-section {
    margin: 50px auto !important;
}

/* ============================================================
   4. LEADERSHIP SECTION - All 10 visible with grid fallback
============================================================ */
.leaders-section-full {
    background: linear-gradient(135deg, #f8f5ff 0%, #fdf0f8 100%) !important;
    padding: 70px 0 !important;
    overflow: hidden !important;
}

.leaders-carousel-wrapper {
    overflow: hidden !important;
    position: relative !important;
    padding: 20px 0 !important;
    margin-top: 20px !important;
}

.leaders-carousel-wrapper::before {
    background: linear-gradient(90deg, #f8f5ff, transparent) !important;
}

.leaders-carousel-wrapper::after {
    background: linear-gradient(270deg, #f8f5ff, transparent) !important;
}

.leaders-carousel {
    display: flex !important;
    gap: 20px !important;
    width: max-content !important;
    animation: scrollLeaders 40s linear infinite !important;
    padding: 10px 20px !important;
}

.leaders-carousel:hover {
    animation-play-state: paused !important;
}

@keyframes scrollLeaders {
    0% {
        transform: translateX(0);
    }

    100% {
        transform: translateX(-50%);
    }
}

.leader-card {
    background: #ffffff !important;
    border-radius: 20px !important;
    box-shadow: 0 6px 25px rgba(74, 0, 114, 0.10) !important;
    text-align: center !important;
    padding: 24px 18px 20px !important;
    width: 180px !important;
    min-width: 180px !important;
    transition: all 0.35s ease !important;
    position: relative !important;
    flex-shrink: 0 !important;
    border-top: 3px solid transparent !important;
    border-image: linear-gradient(90deg, #4A0072, #C2185B) 1 !important;
}

.leader-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 3px;
    background: linear-gradient(90deg, #4A0072, #C2185B);
    border-radius: 20px 20px 0 0;
}

.leader-card:hover {
    transform: translateY(-10px) !important;
    box-shadow: 0 20px 50px rgba(74, 0, 114, 0.22) !important;
    background: linear-gradient(135deg, #f8f5ff, #fff) !important;
}

.leader-img {
    width: 90px !important;
    height: 90px !important;
    border-radius: 50% !important;
    object-fit: cover !important;
    border: 3px solid rgba(74, 0, 114, 0.2) !important;
    box-shadow: 0 4px 15px rgba(74, 0, 114, 0.2) !important;
    transition: transform 0.3s ease !important;
}

.leader-card:hover .leader-img {
    transform: scale(1.08) !important;
    border-color: #C2185B !important;
}

.leader-img-container {
    position: relative !important;
    width: 90px !important;
    height: 90px !important;
    margin: 0 auto 14px !important;
}

.leader-badge {
    position: absolute !important;
    bottom: 0 !important;
    right: 0 !important;
    background: linear-gradient(135deg, #4A0072, #C2185B) !important;
    border-radius: 50% !important;
    width: 26px !important;
    height: 26px !important;
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    font-size: 0.75rem !important;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.15) !important;
    border: 2px solid #fff !important;
}

.leader-name {
    font-size: 0.82rem !important;
    font-weight: 700 !important;
    color: #4A0072 !important;
    line-height: 1.3 !important;
    display: block !important;
    margin-bottom: 4px !important;
}

.leader-role {
    font-size: 0.68rem !important;
    color: #C2185B !important;
    font-weight: 600 !important;
    text-transform: uppercase !important;
    letter-spacing: 0.5px !important;
}

/* ============================================================
   5. GP MEMBERS PAGE - Cards in rows with borders
============================================================ */
.member-grid {
    display: grid !important;
    grid-template-columns: repeat(3, 1fr) !important;
    gap: 28px !important;
    margin-top: 30px !important;
}

.member-ref-card {
    background: #ffffff !important;
    border: 2px solid rgba(74, 0, 114, 0.12) !important;
    border-radius: 20px !important;
    padding: 28px 20px 22px !important;
    text-align: center !important;
    box-shadow: 0 6px 25px rgba(74, 0, 114, 0.08) !important;
    transition: all 0.35s ease !important;
    position: relative;
    overflow: hidden;
}

.member-ref-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 4px;
    background: linear-gradient(90deg, #4A0072, #C2185B);
}

.member-ref-card:hover {
    transform: translateY(-8px) !important;
    box-shadow: 0 20px 50px rgba(74, 0, 114, 0.18) !important;
    border-color: rgba(194, 24, 91, 0.3) !important;
}

.member-img-circle {
    width: 110px !important;
    height: 110px !important;
    border-radius: 50% !important;
    object-fit: cover !important;
    border: 3px solid rgba(74, 0, 114, 0.15) !important;
    box-shadow: 0 4px 15px rgba(74, 0, 114, 0.15) !important;
    margin: 0 auto 16px !important;
    display: block !important;
    transition: all 0.3s ease !important;
}

.member-ref-card:hover .member-img-circle {
    border-color: #C2185B !important;
    transform: scale(1.05) !important;
}

.member-name-ref {
    font-size: 1rem !important;
    font-weight: 700 !important;
    color: #4A0072 !important;
    margin: 0 0 6px !important;
    line-height: 1.3 !important;
}

.member-role-ref {
    font-size: 0.8rem !important;
    color: #C2185B !important;
    font-weight: 600 !important;
    margin: 0 0 10px !important;
    text-transform: uppercase !important;
    letter-spacing: 0.5px !important;
}

/* Phone number in member card */
.member-phone-ref {
    font-size: 0.82rem !important;
    color: #555 !important;
    font-weight: 500 !important;
    margin: 0 !important;
    background: #f8f5ff !important;
    padding: 5px 12px !important;
    border-radius: 20px !important;
    display: inline-block !important;
    border: 1px solid rgba(74, 0, 114, 0.1) !important;
}

.section-title {
    font-size: 1.8rem !important;
    font-weight: 800 !important;
    background: linear-gradient(135deg, #4A0072, #C2185B) !important;
    -webkit-background-clip: text !important;
    background-clip: text !important;
    -webkit-text-fill-color: transparent !important;
    margin-bottom: 8px !important;
    padding-bottom: 10px !important;
    border-bottom: 2px solid rgba(74, 0, 114, 0.1) !important;
}

/* ============================================================
   6. GP SERVICES & REVENUE SERVICES - Table & Layout
============================================================ */
.ref-table-container {
    overflow-x: auto !important;
    border-radius: 12px !important;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.08) !important;
    margin: 20px 0 !important;
}

.ref-table {
    width: 100% !important;
    border-collapse: separate !important;
    border-spacing: 0 !important;
    font-size: 0.9rem !important;
    min-width: 650px !important;
}

.ref-table thead tr {
    background: linear-gradient(135deg, #4A0072, #C2185B) !important;
}

.ref-table thead th {
    color: #ffffff !important;
    font-weight: 700 !important;
    padding: 14px 16px !important;
    text-align: left !important;
    font-size: 0.85rem !important;
    letter-spacing: 0.03em !important;
    border: none !important;
}

.ref-table thead th:first-child {
    border-radius: 12px 0 0 0 !important;
}

.ref-table thead th:last-child {
    border-radius: 0 12px 0 0 !important;
}

.ref-table tbody tr {
    transition: background 0.2s ease !important;
    border-bottom: 1px solid rgba(74, 0, 114, 0.06) !important;
}

.ref-table tbody tr:nth-child(even) {
    background: rgba(74, 0, 114, 0.025) !important;
}

.ref-table tbody tr:hover {
    background: linear-gradient(135deg, rgba(74, 0, 114, 0.06), rgba(194, 24, 91, 0.04)) !important;
}

.ref-table tbody td {
    padding: 12px 16px !important;
    color: #333 !important;
    border-bottom: 1px solid rgba(74, 0, 114, 0.07) !important;
    border-right: 1px solid rgba(74, 0, 114, 0.05) !important;
}

.ref-table tbody td:first-child {
    font-weight: 700 !important;
    color: #4A0072 !important;
    border-left: 1px solid rgba(74, 0, 114, 0.07) !important;
}

.ref-table tbody tr:last-child td {
    border-bottom: none !important;
}

/* Reference box enhanced */
.reference-box {
    background: linear-gradient(135deg, #f0f7ff, #e8f4f8) !important;
    border-left: 4px solid #4A0072 !important;
    padding: 22px !important;
    border-radius: 10px !important;
    margin-bottom: 30px !important;
    box-shadow: 0 4px 15px rgba(74, 0, 114, 0.08) !important;
}

.reference-box h3 {
    color: #4A0072 !important;
    font-weight: 700 !important;
    margin-top: 0 !important;
    font-size: 1rem !important;
    letter-spacing: 0.05em !important;
}

/* Notes box enhanced */
.notes-box {
    background: linear-gradient(135deg, #fff7ed, #fff3e0) !important;
    border-left: 4px solid #f97316 !important;
    border-radius: 10px !important;
    padding: 22px !important;
    margin-top: 30px !important;
    box-shadow: 0 4px 15px rgba(249, 115, 22, 0.08) !important;
}

/* Excluded services */
.excluded-services-box {
    display: grid !important;
    grid-template-columns: 1fr 1fr !important;
    gap: 20px !important;
    margin: 20px 0 !important;
}

.excluded-service-card {
    background: #fff5f7 !important;
    border: 1px solid rgba(194, 24, 91, 0.15) !important;
    border-radius: 12px !important;
    padding: 18px 22px !important;
    box-shadow: 0 3px 12px rgba(194, 24, 91, 0.06) !important;
}

.excluded-service-card ol {
    margin: 0 !important;
    padding-left: 18px !important;
    color: #444 !important;
    line-height: 2 !important;
}

.gp-service-contact {
    background: linear-gradient(135deg, #f0f7ff, #e8f4f8) !important;
    border: 1px solid rgba(74, 0, 114, 0.1) !important;
    border-radius: 12px !important;
    padding: 22px !important;
    margin-top: 30px !important;
    box-shadow: 0 4px 15px rgba(74, 0, 114, 0.06) !important;
}

.scheme-detail-box {
    background: #ffffff !important;
    padding: 40px !important;
    border-radius: 20px !important;
    box-shadow: 0 10px 40px rgba(74, 0, 114, 0.08) !important;
    margin: 30px 0 !important;
    border: 1px solid rgba(74, 0, 114, 0.07) !important;
}

/* ============================================================
   7. GALLERY - Cards in rows with borders
============================================================ */
.gallery-grid {
    display: grid !important;
    grid-template-columns: repeat(3, 1fr) !important;
    gap: 22px !important;
    margin-top: 30px !important;
}

.gallery-card {
    border-radius: 16px !important;
    overflow: hidden !important;
    cursor: pointer !important;
    box-shadow: 0 6px 24px rgba(74, 0, 114, 0.10) !important;
    transition: all 0.35s ease !important;
    aspect-ratio: 4/3 !important;
    position: relative !important;
    background: #f0ebff !important;
    border: 2px solid rgba(74, 0, 114, 0.08) !important;
}

.gallery-card::after {
    content: '🔍';
    position: absolute;
    bottom: 12px;
    right: 14px;
    width: 36px;
    height: 36px;
    background: rgba(74, 0, 114, 0.85);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.9rem;
    opacity: 0;
    transition: opacity 0.3s ease;
    color: white;
}

.gallery-card:hover::after {
    opacity: 1;
}

.gallery-card:hover {
    transform: translateY(-8px) scale(1.01) !important;
    box-shadow: 0 20px 50px rgba(74, 0, 114, 0.22) !important;
    border-color: rgba(194, 24, 91, 0.3) !important;
}

.gallery-card img {
    width: 100% !important;
    height: 100% !important;
    object-fit: cover !important;
    transition: transform 0.4s ease !important;
}

.gallery-card:hover img {
    transform: scale(1.07) !important;
}

/* Gallery Lightbox */
.gallery-lightbox {
    display: none;
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.93);
    z-index: 10000;
    align-items: center;
    justify-content: center;
    animation: fadeInOverlay 0.3s ease;
}

@keyframes fadeInOverlay {
    from {
        opacity: 0;
    }

    to {
        opacity: 1;
    }
}

.lightbox-img {
    max-width: 90vw;
    max-height: 85vh;
    border-radius: 12px;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.5);
    object-fit: contain;
}

.close-lightbox {
    position: absolute;
    top: 20px;
    right: 28px;
    font-size: 2.5rem;
    color: #fff;
    cursor: pointer;
    background: rgba(74, 0, 114, 0.8);
    width: 48px;
    height: 48px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    line-height: 1;
    transition: background 0.2s;
    font-style: normal;
    text-decoration: none;
}

.close-lightbox:hover {
    background: #C2185B;
}

/* Gallery Section Header */
#gallery-section .section-heading {
    font-size: 2rem;
    margin-bottom: 8px;
}

/* ============================================================
   8. CONTACT US PAGE - Cards layout with proper sections
============================================================ */
.contact-ref-grid {
    display: grid !important;
    grid-template-columns: repeat(3, 1fr) !important;
    gap: 24px !important;
    margin-top: 20px !important;
}

.contact-ref-card {
    background: #ffffff !important;
    border: 2px solid rgba(74, 0, 114, 0.10) !important;
    border-radius: 18px !important;
    padding: 28px 20px 22px !important;
    text-align: center !important;
    box-shadow: 0 6px 25px rgba(74, 0, 114, 0.08) !important;
    transition: all 0.35s ease !important;
    position: relative;
    overflow: hidden;
}

.contact-ref-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 4px;
    background: linear-gradient(90deg, #4A0072, #C2185B);
}

.contact-ref-card:hover {
    transform: translateY(-8px) !important;
    box-shadow: 0 20px 50px rgba(74, 0, 114, 0.18) !important;
    border-color: rgba(194, 24, 91, 0.25) !important;
}

.contact-icon-ref {
    font-size: 2.5rem !important;
    display: block !important;
    margin-bottom: 12px !important;
    filter: drop-shadow(0 2px 4px rgba(74, 0, 114, 0.15)) !important;
}

.contact-role-title {
    font-size: 0.85rem !important;
    font-weight: 700 !important;
    color: #4A0072 !important;
    text-transform: uppercase !important;
    letter-spacing: 0.5px !important;
    margin-bottom: 14px !important;
    padding-bottom: 10px !important;
    border-bottom: 1px solid rgba(74, 0, 114, 0.12) !important;
}

.contact-detail-row {
    font-size: 0.85rem !important;
    color: #444 !important;
    display: flex !important;
    justify-content: center !important;
    gap: 6px !important;
    margin-bottom: 6px !important;
    align-items: center !important;
    flex-wrap: wrap !important;
}

.contact-detail-row strong {
    color: #777 !important;
    font-weight: 600 !important;
    font-size: 0.78rem !important;
}

.contact-detail-row a {
    color: #4A0072 !important;
    font-weight: 600 !important;
    text-decoration: none !important;
}

.contact-detail-row a:hover {
    color: #C2185B !important;
    text-decoration: underline !important;
}

/* Emergency Helpline - enhanced */
.emergency-ref-container {
    display: grid !important;
    grid-template-columns: repeat(4, 1fr) !important;
    gap: 20px !important;
    margin-top: 20px !important;
}

.emergency-item-ref {
    background: #ffffff !important;
    border: 2px solid rgba(220, 38, 38, 0.12) !important;
    border-radius: 16px !important;
    padding: 24px 16px !important;
    text-align: center !important;
    box-shadow: 0 6px 20px rgba(220, 38, 38, 0.08) !important;
    transition: all 0.3s ease !important;
    position: relative;
    overflow: hidden;
}

.emergency-item-ref::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 4px;
    background: linear-gradient(90deg, #dc2626, #ef4444);
}

.emergency-item-ref:hover {
    transform: translateY(-5px) !important;
    box-shadow: 0 15px 40px rgba(220, 38, 38, 0.18) !important;
    border-color: rgba(220, 38, 38, 0.3) !important;
}

.em-icon {
    font-size: 2.5rem !important;
    display: block !important;
    margin-bottom: 10px !important;
}

.em-text strong {
    display: block !important;
    font-size: 0.75rem !important;
    font-weight: 700 !important;
    color: #555 !important;
    text-transform: uppercase !important;
    letter-spacing: 0.06em !important;
    margin-bottom: 6px !important;
}

.em-number {
    font-size: 2rem !important;
    font-weight: 800 !important;
    color: #dc2626 !important;
    line-height: 1 !important;
}

/* Address box */
.address-ref-box {
    background: linear-gradient(135deg, #f0f7ff, #e8f4f8) !important;
    border: 1px solid rgba(74, 0, 114, 0.1) !important;
    border-radius: 14px !important;
    padding: 22px 28px !important;
    box-shadow: 0 4px 16px rgba(74, 0, 114, 0.06) !important;
    border-left: 5px solid #4A0072 !important;
}

/* ============================================================
   9. CERTIFICATE PAGE - Cards layout beautiful
============================================================ */
.modern-grid-4 {
    display: grid !important;
    grid-template-columns: repeat(4, 1fr) !important;
    gap: 24px !important;
    margin-top: 30px !important;
}

.glass-card {
    background: #ffffff !important;
    border: 2px solid rgba(74, 0, 114, 0.10) !important;
    border-radius: 18px !important;
    padding: 28px 20px 22px !important;
    text-align: center !important;
    box-shadow: 0 6px 25px rgba(74, 0, 114, 0.08) !important;
    transition: all 0.35s cubic-bezier(0.25, 0.8, 0.25, 1) !important;
    position: relative;
    overflow: hidden;
    display: flex;
    flex-direction: column;
    align-items: center;
}

.glass-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 4px;
    background: linear-gradient(90deg, #4A0072, #C2185B);
}

.glass-card:hover {
    transform: translateY(-10px) !important;
    box-shadow: 0 25px 60px rgba(74, 0, 114, 0.22) !important;
    border-color: rgba(194, 24, 91, 0.3) !important;
    background: linear-gradient(135deg, #fdfbff, #fff) !important;
}

.glass-card .card-icon-circle {
    width: 80px !important;
    height: 80px !important;
    background: linear-gradient(135deg, #f8f5ff, #ede7f6) !important;
    border-radius: 50% !important;
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    font-size: 2.2rem !important;
    margin-bottom: 16px !important;
    border: 2px solid rgba(74, 0, 114, 0.1) !important;
    transition: all 0.35s ease !important;
}

.glass-card:hover .card-icon-circle {
    background: linear-gradient(135deg, #4A0072, #C2185B) !important;
    font-size: 2.2rem !important;
    transform: scale(1.1) !important;
    border-color: transparent !important;
}

.glass-card h4 {
    font-size: 0.92rem !important;
    font-weight: 700 !important;
    color: #2d2d2d !important;
    margin: 0 0 auto !important;
    line-height: 1.4 !important;
    flex: 1;
    display: flex;
    align-items: center;
    text-align: center;
}

.declaration-download-btn {
    background: linear-gradient(135deg, #4A0072, #C2185B) !important;
    color: #ffffff !important;
    border: none !important;
    padding: 10px 22px !important;
    border-radius: 50px !important;
    font-size: 0.85rem !important;
    font-weight: 600 !important;
    cursor: pointer !important;
    font-family: var(--font-main) !important;
    box-shadow: 0 4px 15px rgba(74, 0, 114, 0.3) !important;
    transition: all 0.3s ease !important;
    letter-spacing: 0.02em !important;
    width: 100% !important;
}

.declaration-download-btn:hover {
    transform: translateY(-2px) !important;
    box-shadow: 0 8px 25px rgba(74, 0, 114, 0.4) !important;
}

/* ============================================================
   10. TRANSLATE BUTTON & LANGUAGE SELECTOR ENHANCEMENT
============================================================ */
.lang-selector select {
    border: 2px solid rgba(74, 0, 114, 0.2) !important;
    padding: 8px 14px !important;
    border-radius: 10px !important;
    font-weight: 600 !important;
    color: #4A0072 !important;
    cursor: pointer !important;
    background: #f8f5ff !important;
    transition: all 0.25s ease !important;
    font-family: var(--font-main);
}

.lang-selector select:hover,
.lang-selector select:focus {
    border-color: #C2185B !important;
    box-shadow: 0 0 0 3px rgba(194, 24, 91, 0.1) !important;
    outline: none !important;
}

/* ============================================================
   11. MOBILE RESPONSIVENESS - Comprehensive
============================================================ */
@media (max-width: 1024px) {
    .member-grid {
        grid-template-columns: repeat(2, 1fr) !important;
    }

    .contact-ref-grid {
        grid-template-columns: repeat(2, 1fr) !important;
    }

    .modern-grid-4 {
        grid-template-columns: repeat(2, 1fr) !important;
    }

    .emergency-ref-container {
        grid-template-columns: repeat(2, 1fr) !important;
    }

    .gallery-grid {
        grid-template-columns: repeat(2, 1fr) !important;
    }
}

@media (max-width: 768px) {

    /* Header mobile */
    .header-content {
        padding: 10px 16px !important;
    }

    .brand-section {
        gap: 10px !important;
    }

    .logo-container img {
        height: 44px !important;
    }

    .brand-text h1 {
        font-size: 1.1rem !important;
    }

    .lgd-code {
        font-size: 0.65rem !important;
        padding: 2px 6px !important;
    }

    .seal-container {
        width: 45px !important;
        height: 45px !important;
    }

    /* Navigation mobile */
    .nav-links {
        gap: 0 !important;
        flex-direction: column !important;
    }

    .nav-item {
        font-size: 0.9rem !important;
        padding: 10px 20px !important;
        border-radius: 0 !important;
        text-align: left !important;
    }

    /* Population */
    .population-section {
        padding: 50px 0 !important;
    }

    .population-grid {
        grid-template-columns: 1fr !important;
        gap: 18px !important;
    }

    .pop-counters-card {
        flex-direction: row !important;
        flex-wrap: wrap !important;
        gap: 14px !important;
    }

    .pop-counter-item {
        flex: 1 !important;
        min-width: 90px !important;
        padding: 18px 10px !important;
    }

    .pop-counter-num {
        font-size: 1.6rem !important;
    }

    /* Leadership */
    .leader-card {
        width: 150px !important;
        min-width: 150px !important;
        padding: 20px 14px 16px !important;
    }

    .leader-img,
    .leader-img-container {
        width: 75px !important;
        height: 75px !important;
    }

    /* Members */
    .member-grid {
        grid-template-columns: repeat(2, 1fr) !important;
        gap: 16px !important;
    }

    .member-img-circle {
        width: 80px !important;
        height: 80px !important;
    }

    /* Services & Revenue Tables */
    .scheme-detail-box {
        padding: 22px 16px !important;
    }

    .ref-table {
        font-size: 0.78rem !important;
    }

    .ref-table thead th,
    .ref-table tbody td {
        padding: 10px 10px !important;
    }

    .excluded-services-box {
        grid-template-columns: 1fr !important;
    }

    /* Gallery */
    .gallery-grid {
        grid-template-columns: repeat(2, 1fr) !important;
        gap: 14px !important;
    }

    /* Contact */
    .contact-ref-grid {
        grid-template-columns: 1fr 1fr !important;
        gap: 16px !important;
    }

    .emergency-ref-container {
        grid-template-columns: repeat(2, 1fr) !important;
        gap: 14px !important;
    }

    /* Certificates */
    .modern-grid-4 {
        grid-template-columns: repeat(2, 1fr) !important;
        gap: 16px !important;
    }

    /* Home section */
    .split-section {
        grid-template-columns: 1fr !important;
        gap: 30px !important;
    }

    .quick-links-grid {
        grid-template-columns: repeat(2, 1fr) !important;
        margin-top: 0 !important;
        gap: 16px !important;
    }

    .hero-content h1 {
        font-size: 1.8rem !important;
    }

    /* Footer */
    .main-footer {
        padding: 50px 16px 20px !important;
    }

    .footer-grid {
        grid-template-columns: 1fr !important;
        gap: 30px !important;
    }
}

@media (max-width: 480px) {
    .brand-text h1 {
        font-size: 0.95rem !important;
    }

    .section-heading {
        font-size: 1.8rem !important;
    }

    .population-grid {
        grid-template-columns: 1fr !important;
    }

    .pop-counters-card {
        flex-direction: column !important;
    }

    .member-grid {
        grid-template-columns: 1fr !important;
        gap: 14px !important;
    }

    .leader-card {
        width: 130px !important;
        min-width: 130px !important;
    }

    .gallery-grid {
        grid-template-columns: 1fr 1fr !important;
        gap: 12px !important;
    }

    .contact-ref-grid {
        grid-template-columns: 1fr !important;
        gap: 14px !important;
    }

    .emergency-ref-container {
        grid-template-columns: 1fr !important;
    }

    .modern-grid-4 {
        grid-template-columns: 1fr !important;
        gap: 14px !important;
    }

    .glass-card {
        padding: 22px 14px 18px !important;
    }

    .hero-content h1 {
        font-size: 1.8rem !important;
    }

    .hero-subtitle {
        font-size: 1rem !important;
    }

    .btn-primary,
    .btn-secondary {
        padding: 12px 22px !important;
        font-size: 0.95rem !important;
    }
}

/* ============================================================
   12. GENERAL SECTION IMPROVEMENTS
============================================================ */
.main-content-grid {
    padding: 0 !important;
}

.max-w-container {
    padding-left: 20px !important;
    padding-right: 20px !important;
}

/* Smooth page transitions */
#dynamic-content-area {
    animation: fadeInPage 0.4s ease-out;
}

@keyframes fadeInPage {
    from {
        opacity: 0;
        transform: translateY(12px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Section headers improvements */
.section-header {
    margin-bottom: 40px !important;
}

.center-text {
    text-align: center !important;
}

/* Inner page spacer */
.inner-page-spacer {
    height: 20px !important;
}

/* Scheme link external */
.scheme-link-external {
    display: inline-flex !important;
    align-items: center !important;
    gap: 8px !important;
    background: linear-gradient(135deg, #4A0072, #C2185B) !important;
    color: #fff !important;
    text-decoration: none !important;
    padding: 12px 24px !important;
    border-radius: 50px !important;
    font-weight: 600 !important;
    font-size: 0.9rem !important;
    margin-top: 24px !important;
    transition: all 0.3s ease !important;
    box-shadow: 0 6px 20px rgba(74, 0, 114, 0.25) !important;
}

.scheme-link-external:hover {
    transform: translateY(-3px) !important;
    box-shadow: 0 12px 35px rgba(74, 0, 114, 0.35) !important;
}

.scheme-icon {
    width: 20px !important;
    height: 20px !important;
}

/* Revenue Services - styled section intro */
#revenue-services h2,
#gp-services h2,
#gallery-section h2,
#self-declaration-section h2,
#elected-members h2,
#contact-us h2 {
    font-size: 2.2rem !important;
}

/* GP Services table for mobile - allow horizontal scroll instead of hiding columns */
@media (max-width: 600px) {
    .ref-table-container {
        overflow-x: auto !important;
        -webkit-overflow-scrolling: touch;
    }
}

/* Members inner page with full padding */
#elected-members,
#admin-staff {
    padding-left: 0 !important;
    padding-right: 0 !important;
}

/* Home quick-card improvements */
.quick-card {
    padding: 24px 16px !important;
}

.quick-card h3 {
    font-size: 1rem !important;
}

/* Fix hero section on mobile */
@media (max-width: 480px) {
    .hero-wrapper {
        height: auto !important;
        padding: 80px 16px 50px !important;
        min-height: 400px !important;
    }

    .hero-actions {
        flex-direction: column !important;
        gap: 12px !important;
    }

    .btn-primary,
    .btn-secondary {
        width: 100% !important;
        text-align: center !important;
    }
}

/* Seal img mobile fix */
@media (max-width: 480px) {
    .seal-container {
        width: 40px !important;
        height: 40px !important;
    }

    .header-controls {
        gap: 10px !important;
    }
}

/* Mobile nav toggle button */
.mobile-nav-toggle .bar {
    display: block;
    width: 25px;
    height: 3px;
    margin: 5px auto;
    background: #4A0072;
    border-radius: 3px;
    transition: all 0.3s ease;
}

@media (max-width: 768px) {
    .mobile-nav-toggle {
        display: flex !important;
        flex-direction: column;
        align-items: center;
        justify-content: center;
    }
}

/* Active nav link */
.nav-item.selected {
    color: #4A0072 !important;
    background: rgba(74, 0, 114, 0.08) !important;
    font-weight: 700 !important;
}