/* ═══════════════════════════════════════════════════════════
   Aakash Cooperative - Global Unified CSS
   ═══════════════════════════════════════════════════════════ */

/* Page Loader - Hide when loaded (CRITICAL - use !important to override all) */
html body.page-loaded .page-loader,
html body.page-loaded div.page-loader,
html body.page-loaded #pageLoader,
html body.page-loaded div#pageLoader {
    opacity: 0 !important;
    visibility: hidden !important;
    pointer-events: none !important;
    z-index: -1 !important;
    display: none !important;
}

/* Page Loader Styles */
html body .page-loader,
html body div.page-loader,
html body #pageLoader,
html body div#pageLoader {
    position: fixed !important;
    top: 0 !important;
    left: 0 !important;
    width: 100% !important;
    height: 100% !important;
    background: #fff !important;
    z-index: 99999 !important;
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
}

.loader-inner {
    text-align: center;
}

.loader-spinner {
    width: 50px;
    height: 50px;
    border: 4px solid #f3f3f3;
    border-top: 4px solid #1a5f2a;
    border-radius: 50%;
    animation: spin 1s linear infinite;
    margin: 0 auto 20px;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

.loader-progress {
    margin-bottom: 10px;
}

.progress-bar {
    width: 200px;
    height: 6px;
    background: #e0e0e0;
    border-radius: 3px;
    overflow: hidden;
    margin: 0 auto 8px;
}

.progress-fill {
    height: 100%;
    background: linear-gradient(90deg, #1a5f2a, #2e8b3a);
    width: 0%;
    transition: width 0.3s ease;
}

.progress-text {
    font-size: 14px;
    color: #666;
    font-weight: 600;
}

.loader-text {
    color: #1a5f2a;
    font-weight: 600;
    font-size: 16px;
}

/* Basic Reset */
*, *::before, *::after {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

html {
    scroll-behavior: smooth;
}

body {
    font-family: 'Noto Sans Devanagari', 'Mukta', Arial, sans-serif;
    line-height: 1.6;
    color: #333;
    background: #fff;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

a {
    color: #1a5f2a;
    text-decoration: none;
    transition: color 0.3s ease;
}

a:hover {
    color: #0d3d19;
}

img {
    max-width: 100%;
    height: auto;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 15px;
}

/* Header v2 */
body.header-v2 .top-bar,
body.header-v2 #mainNav,
body.header-v2 .old-header {
    display: none;
}

.pfl-header-wrapper {
    position: sticky;
    top: 0;
    z-index: 1000;
    background: #fff;
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
}

.pfl-top-bar {
    background: #1a5f2a;
    color: #fff;
    padding: 8px 0;
    font-size: 14px;
}

.pfl-top-bar a {
    color: #fff;
}

.pfl-top-bar a:hover {
    color: rgba(255,255,255,0.8);
}

.main-header {
    padding: 15px 0;
}

.site-logo img,
.pfl-site-logo img {
    max-height: 60px;
}

/* Main Content */
.main-wrapper {
    min-height: 60vh;
}

/* Hero Section */
.hero-slider,
.hero-section {
    background: linear-gradient(135deg, #1a5f2a 0%, #2e8b3a 100%);
    color: #fff;
    padding: 80px 0;
    text-align: center;
}

.hero-slider h1,
.hero-section h1 {
    font-size: 3rem;
    margin-bottom: 20px;
    color: #fff;
}

/* Section Styles */
section {
    padding: 60px 0;
}

section.bg-light {
    background: #f8f9fa;
}

section.bg-dark {
    background: #333;
    color: #fff;
}

section.bg-primary {
    background: #1a5f2a;
    color: #fff;
}

/* Footer */
footer, .site-footer, .pfl-footer {
    background: #1a5f2a;
    color: #fff;
    padding: 40px 0 20px;
}

footer a, .site-footer a, .pfl-footer a {
    color: rgba(255,255,255,0.8);
}

footer a:hover, .site-footer a:hover, .pfl-footer a:hover {
    color: #fff;
}

/* Cards */
.card {
    background: #fff;
    border-radius: 12px;
    padding: 24px;
    box-shadow: 0 4px 15px rgba(0,0,0,0.1);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.card:hover {
    transform: translateY(-5px);
    box-shadow: 0 8px 25px rgba(0,0,0,0.15);
}

/* Buttons */
.btn {
    display: inline-block;
    padding: 10px 24px;
    background: #1a5f2a;
    color: #fff;
    border-radius: 6px;
    font-weight: 600;
    transition: all 0.3s ease;
    cursor: pointer;
    border: none;
    text-align: center;
}

.btn:hover {
    background: #0d3d19;
    color: #fff;
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(26, 95, 42, 0.3);
}

.btn-secondary {
    background: #f59e0b;
    color: #000;
}

.btn-secondary:hover {
    background: #d97706;
    color: #000;
}

.btn-outline {
    background: transparent;
    border: 2px solid #1a5f2a;
    color: #1a5f2a;
}

.btn-outline:hover {
    background: #1a5f2a;
    color: #fff;
}

/* Forms */
input, select, textarea {
    width: 100%;
    padding: 12px 16px;
    border: 1px solid #ddd;
    border-radius: 6px;
    font-size: 16px;
    font-family: inherit;
    transition: border-color 0.3s ease, box-shadow 0.3s ease;
}

input:focus, select:focus, textarea:focus {
    outline: none;
    border-color: #1a5f2a;
    box-shadow: 0 0 0 3px rgba(26, 95, 42, 0.1);
}

label {
    font-weight: 500;
    margin-bottom: 6px;
    display: block;
    color: #333;
}

/* Navigation */
.main-nav, .pfl-main-nav {
    display: flex;
    gap: 20px;
}

.main-nav a, .pfl-main-nav a {
    padding: 10px 15px;
    color: #333;
    font-weight: 500;
}

.main-nav a:hover, .pfl-main-nav a:hover {
    color: #1a5f2a;
}

/* Utility Classes */
.text-center { text-align: center; }
.text-left { text-align: left; }
.text-right { text-align: right; }
.text-primary { color: #1a5f2a; }
.text-white { color: #fff; }
.text-muted { color: #666; }

.mb-0 { margin-bottom: 0; }
.mb-1 { margin-bottom: 0.5rem; }
.mb-2 { margin-bottom: 1rem; }
.mb-3 { margin-bottom: 1.5rem; }
.mb-4 { margin-bottom: 2rem; }
.mb-5 { margin-bottom: 3rem; }

.mt-0 { margin-top: 0; }
.mt-1 { margin-top: 0.5rem; }
.mt-2 { margin-top: 1rem; }
.mt-3 { margin-top: 1.5rem; }
.mt-4 { margin-top: 2rem; }

.p-1 { padding: 0.5rem; }
.p-2 { padding: 1rem; }
.p-3 { padding: 1.5rem; }
.p-4 { padding: 2rem; }
.p-5 { padding: 3rem; }

/* Grid */
.row {
    display: flex;
    flex-wrap: wrap;
    margin: 0 -15px;
}

.col {
    flex: 1;
    padding: 0 15px;
}

.col-2 { flex: 0 0 50%; max-width: 50%; }
.col-3 { flex: 0 0 33.333%; max-width: 33.333%; }
.col-4 { flex: 0 0 25%; max-width: 25%; }

/* Alert / Notice Boxes */
.alert {
    padding: 15px 20px;
    border-radius: 8px;
    margin-bottom: 20px;
}

.alert-success {
    background: #d4edda;
    color: #155724;
    border: 1px solid #c3e6cb;
}

.alert-error, .alert-danger {
    background: #f8d7da;
    color: #721c24;
    border: 1px solid #f5c6cb;
}

.alert-warning {
    background: #fff3cd;
    color: #856404;
    border: 1px solid #ffeeba;
}

.alert-info {
    background: #d1ecf1;
    color: #0c5460;
    border: 1px solid #bee5eb;
}

/* Tables */
table {
    width: 100%;
    border-collapse: collapse;
}

th, td {
    padding: 12px 15px;
    text-align: left;
    border-bottom: 1px solid #ddd;
}

th {
    background: #f8f9fa;
    font-weight: 600;
    color: #333;
}

tr:hover {
    background: #f8f9fa;
}

/* Badges */
.badge {
    display: inline-block;
    padding: 4px 10px;
    border-radius: 20px;
    font-size: 12px;
    font-weight: 600;
}

.badge-primary {
    background: #1a5f2a;
    color: #fff;
}

.badge-secondary {
    background: #6c757d;
    color: #fff;
}

.badge-success {
    background: #28a745;
    color: #fff;
}

.badge-warning {
    background: #ffc107;
    color: #333;
}

.badge-danger {
    background: #dc3545;
    color: #fff;
}

/* Mobile Footer Navigation */
.public-mobile-footer {
    display: none;
}

@media (max-width: 768px) {
    .public-mobile-footer {
        display: flex;
        position: fixed;
        bottom: 0;
        left: 0;
        right: 0;
        background: #fff;
        box-shadow: 0 -2px 10px rgba(0,0,0,0.1);
        z-index: 999;
        padding: 8px 0;
    }

    .public-mobile-footer a {
        flex: 1;
        text-align: center;
        padding: 8px;
        color: #666;
        font-size: 12px;
    }

    .public-mobile-footer a.active {
        color: #1a5f2a;
    }

    .public-mobile-footer i {
        display: block;
        font-size: 20px;
        margin-bottom: 4px;
    }

    body.has-mobile-footer {
        padding-bottom: 65px;
    }

    section { padding: 40px 0; }
    .container { padding: 0 10px; }

    .hero-slider h1,
    .hero-section h1 {
        font-size: 2rem;
    }

    .col-2, .col-3, .col-4 {
        flex: 0 0 100%;
        max-width: 100%;
    }

    .row {
        margin: 0;
    }

    .col {
        padding: 0;
        margin-bottom: 15px;
    }
}

/* Skip Link */
.skip-link {
    position: absolute;
    top: -100%;
    left: 0;
    background: #1a5f2a;
    color: #fff !important;
    padding: 12px 24px;
    z-index: 99999;
    font-weight: 600;
    text-decoration: none;
    border-radius: 0 0 8px 0;
    transition: top 0.3s ease;
}

.skip-link:focus {
    top: 0;
    outline: 3px solid #f59e0b;
    outline-offset: 2px;
}

/* AOS Animations fallback */
[data-aos] {
    opacity: 0;
    transition: opacity 0.6s ease, transform 0.6s ease;
}

[data-aos].aos-animate {
    opacity: 1;
}

/* FAB Help Button */
.public-fab-help {
    position: fixed;
    right: 18px;
    bottom: 96px;
    z-index: 60;
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 10px 14px 10px 12px;
    border-radius: 999px;
    background: #1a5f2a;
    color: #fff;
    font-weight: 600;
    font-size: 14px;
    text-decoration: none;
    box-shadow: 0 10px 24px rgba(15,23,42,.18);
    transition: transform 0.15s, box-shadow 0.15s;
}

.public-fab-help:hover {
    color: #fff;
    transform: translateY(-2px);
    box-shadow: 0 14px 30px rgba(15,23,42,.22);
}

@media (max-width: 768px) {
    .public-fab-help {
        bottom: 78px;
        padding: 9px 12px;
    }
}
