/* ============================================
   Sarkari Yojna - Professional Government Portal
   Accessible Design for All Citizens
   Senior Citizens & Students Friendly
   ============================================ */

/* === Reset & Base Styles === */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

:root {
    /* Professional Government Color Palette */
    --primary-color: #1a56db;
    --primary-dark: #1e40af;
    --primary-light: #3b82f6;
    --secondary-color: #111827;
    --accent-color: #7c3aed;
    --success-color: #059669;
    --danger-color: #dc2626;
    --warning-color: #d97706;
    --info-color: #0891b2;
    
    /* High Contrast Backgrounds */
    --light-bg: #f3f4f6;
    --card-bg: #ffffff;
    --dark-bg: #111827;
    
    /* Accessible Text Colors (WCAG AA Compliant) */
    --dark-text: #111827;
    --body-text: #374151;
    --light-text: #4b5563;
    --muted-text: #6b7280;
    
    /* Borders & Shadows */
    --border-color: #d1d5db;
    --border-light: #e5e7eb;
    --white: #ffffff;
    --shadow-sm: 0 1px 3px 0 rgba(0, 0, 0, 0.1);
    --shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -1px rgba(0, 0, 0, 0.06);
    --shadow-md: 0 10px 15px -3px rgba(0, 0, 0, 0.1), 0 4px 6px -2px rgba(0, 0, 0, 0.05);
    --shadow-lg: 0 20px 25px -5px rgba(0, 0, 0, 0.1), 0 10px 10px -5px rgba(0, 0, 0, 0.04);
    --shadow-xl: 0 25px 50px -12px rgba(0, 0, 0, 0.25);
    
    /* Professional Gradients */
    --gradient-primary: linear-gradient(135deg, #1a56db 0%, #1e40af 100%);
    --gradient-hero: linear-gradient(135deg, #1e3a8a 0%, #312e81 50%, #1a56db 100%);
    --gradient-card: linear-gradient(145deg, #ffffff 0%, #f9fafb 100%);
    
    /* Transitions */
    --transition-fast: all 0.15s ease;
    --transition: all 0.3s ease;
    --transition-slow: all 0.5s ease;
    
    /* Border Radius */
    --radius-sm: 8px;
    --radius: 12px;
    --radius-lg: 16px;
    --radius-xl: 24px;
    --radius-full: 9999px;
}

html {
    scroll-behavior: smooth;
    font-size: 18px; /* Larger base for accessibility */
}

body {
    font-family: 'Poppins', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
    font-size: 1rem;
    line-height: 1.8;
    color: var(--body-text);
    background: var(--light-bg);
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
    letter-spacing: 0.01em;
}

/* Accessibility Focus States */
*:focus {
    outline: 3px solid var(--primary-color);
    outline-offset: 2px;
}

*:focus:not(:focus-visible) {
    outline: none;
}

*:focus-visible {
    outline: 3px solid var(--primary-color);
    outline-offset: 2px;
}

/* Skip to content link for screen readers */
.skip-link {
    position: absolute;
    top: -40px;
    left: 0;
    background: var(--primary-color);
    color: white;
    padding: 8px 16px;
    z-index: 10000;
    transition: top 0.3s;
}

.skip-link:focus {
    top: 0;
}

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

a {
    text-decoration: none;
    color: inherit;
    transition: var(--transition);
}

ul {
    list-style: none;
}

.container {
    max-width: 95%;
    width: 95%;
    margin: 0 auto;
    padding: 0 20px;
}

/* === Typography === */
h1, h2, h3, h4, h5, h6 {
    font-weight: 600;
    line-height: 1.3;
    color: var(--dark-text);
    margin-bottom: 1rem;
}

h1 { font-size: clamp(1.875rem, 4vw, 2.5rem); }
h2 { font-size: clamp(1.5rem, 3vw, 2rem); }
h3 { font-size: clamp(1.125rem, 2vw, 1.5rem); }
h4 { font-size: 1.25rem; }

p {
    margin-bottom: 1rem;
}

/* === Buttons === */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    padding: 14px 32px;
    border-radius: var(--radius);
    font-weight: 600;
    font-size: 1rem;
    cursor: pointer;
    border: 2px solid transparent;
    transition: var(--transition);
    text-align: center;
    white-space: nowrap;
    min-height: 48px; /* Accessibility: Larger touch targets */
    letter-spacing: 0.02em;
}

.btn-primary {
    background: var(--primary-color);
    color: var(--white);
    box-shadow: 0 4px 14px 0 rgba(26, 86, 219, 0.35);
}

.btn-primary:hover {
    background: var(--primary-dark);
    transform: translateY(-2px);
    box-shadow: 0 6px 20px 0 rgba(26, 86, 219, 0.45);
}

.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px 0 rgba(37, 99, 235, 0.5);
}

.btn-outline {
    background: transparent;
    color: var(--white);
    border: 2px solid rgba(255, 255, 255, 0.8);
}

.btn-outline:hover {
    background: var(--white);
    color: var(--primary-color);
    border-color: var(--white);
}

.btn-secondary {
    background: var(--white);
    color: var(--primary-color);
    box-shadow: var(--shadow);
}

.btn-secondary:hover {
    transform: translateY(-2px);
    box-shadow: var(--shadow-md);
}

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

/* === Header === */
.header {
    position: sticky;
    top: 0;
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.05);
    z-index: 1000;
    border-bottom: 1px solid var(--border-light);
}

.top-bar {
    background: var(--secondary-color);
    color: var(--white);
    padding: 8px 0;
    font-size: 0.8rem;
}

.top-bar-content {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.contact-info {
    display: flex;
    align-items: center;
    gap: 20px;
}

.contact-info span {
    display: flex;
    align-items: center;
    gap: 6px;
    opacity: 0.9;
}

.contact-info i {
    font-size: 0.75rem;
}

.social-links {
    display: flex;
    align-items: center;
    gap: 12px;
}

.social-links a {
    color: var(--white);
    opacity: 0.8;
    font-size: 0.9rem;
    transition: var(--transition);
}

.social-links a:hover {
    opacity: 1;
    color: var(--primary-light);
    transform: translateY(-2px);
}

.top-bar-right {
    display: flex;
    align-items: center;
    gap: 20px;
}

/* User Auth Links */
.user-auth-links {
    display: flex;
    align-items: center;
    gap: 12px;
}

.auth-link {
    display: flex;
    align-items: center;
    gap: 6px;
    padding: 6px 12px;
    color: rgba(255, 255, 255, 0.9);
    font-size: 0.85rem;
    border-radius: var(--radius-full);
    transition: var(--transition);
}

.auth-link:hover {
    color: white;
    background: rgba(255, 255, 255, 0.1);
}

.auth-link-primary {
    background: rgba(255, 255, 255, 0.15);
    border: 1px solid rgba(255, 255, 255, 0.3);
}

.auth-link-primary:hover {
    background: rgba(255, 255, 255, 0.25);
}

.user-profile-link {
    background: rgba(255, 255, 255, 0.1);
}

.user-avatar-small {
    width: 24px;
    height: 24px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.7rem;
    font-weight: 600;
    color: white;
}

.user-name-display {
    max-width: 100px;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.logout-link-small {
    padding: 6px 10px;
    color: rgba(255, 255, 255, 0.7);
}

.logout-link-small:hover {
    color: #fca5a5;
    background: rgba(239, 68, 68, 0.2);
}

/* Mobile Auth Links */
.mobile-auth-links {
    display: none;
}

@media (max-width: 768px) {
    .user-auth-links {
        display: none;
    }
    
    .mobile-auth-links {
        display: flex;
        flex-direction: column;
        gap: 10px;
        padding: 20px;
        border-top: 1px solid var(--border-color);
        margin-top: 16px;
    }
    
    .mobile-auth-btn {
        display: flex;
        align-items: center;
        justify-content: center;
        gap: 10px;
        padding: 14px 20px;
        background: var(--light-bg);
        color: var(--dark-text);
        border-radius: var(--radius);
        font-weight: 500;
        transition: var(--transition);
    }
    
    .mobile-auth-btn:hover {
        background: var(--primary-color);
        color: white;
    }
    
    .mobile-auth-btn.primary {
        background: var(--primary-color);
        color: white;
    }
    
    .mobile-auth-btn.primary:hover {
        background: var(--primary-dark);
    }
    
    .mobile-auth-btn.logout {
        background: #fef2f2;
        color: #dc2626;
    }
    
    .mobile-auth-btn.logout:hover {
        background: #fee2e2;
    }
}

/* Language Switcher */
.language-switcher {
    position: relative;
}

.lang-btn {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 6px 12px;
    background: rgba(255, 255, 255, 0.1);
    border: 1px solid rgba(255, 255, 255, 0.2);
    border-radius: var(--radius-full);
    color: var(--white);
    font-size: 0.85rem;
    cursor: pointer;
    transition: var(--transition);
}

.lang-btn:hover {
    background: rgba(255, 255, 255, 0.2);
}

.lang-flag {
    font-size: 1.1rem;
}

.lang-name {
    font-weight: 500;
}

.lang-btn i {
    font-size: 0.7rem;
    transition: var(--transition);
}

.language-switcher:hover .lang-btn i {
    transform: rotate(180deg);
}

.lang-dropdown {
    position: absolute;
    top: calc(100% + 8px);
    right: 0;
    background: var(--white);
    border-radius: var(--radius);
    box-shadow: var(--shadow-lg);
    min-width: 150px;
    opacity: 0;
    visibility: hidden;
    transform: translateY(10px);
    transition: var(--transition);
    z-index: 1001;
    overflow: hidden;
}

.language-switcher:hover .lang-dropdown,
.lang-dropdown.show {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

.lang-option {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 12px 16px;
    color: var(--dark-text);
    font-size: 0.9rem;
    transition: var(--transition);
}

.lang-option:hover {
    background: var(--light-bg);
}

.lang-option.active {
    background: var(--light-bg);
    color: var(--primary-color);
}

.lang-option i {
    margin-left: auto;
    color: var(--primary-color);
}

/* === Navbar === */
.navbar {
    padding: 12px 0;
}

.nav-wrapper {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 40px;
}

.logo a {
    display: flex;
    align-items: center;
    gap: 10px;
    font-size: 1.4rem;
    font-weight: 700;
    color: var(--primary-color);
}

.logo i {
    font-size: 1.6rem;
    background: var(--gradient-primary);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.logo span {
    background: var(--gradient-primary);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.nav-menu {
    display: flex;
    align-items: center;
    gap: 24px;
}

.nav-list {
    display: flex;
    align-items: center;
    gap: 8px;
}

.nav-link {
    display: flex;
    align-items: center;
    gap: 6px;
    padding: 10px 16px;
    color: var(--dark-text);
    font-weight: 500;
    font-size: 0.95rem;
    border-radius: var(--radius);
    transition: var(--transition);
}

.nav-link:hover {
    color: var(--primary-color);
    background: var(--light-bg);
}

.nav-link i.fa-chevron-down {
    font-size: 0.7rem;
    transition: var(--transition);
}

.dropdown:hover .nav-link i.fa-chevron-down {
    transform: rotate(180deg);
}

/* Dropdown */
.dropdown {
    position: relative;
}

.dropdown-menu {
    position: absolute;
    top: calc(100% + 8px);
    left: 0;
    background: var(--white);
    min-width: 260px;
    box-shadow: var(--shadow-lg);
    border-radius: var(--radius);
    padding: 8px;
    opacity: 0;
    visibility: hidden;
    transform: translateY(10px);
    transition: var(--transition);
    border: 1px solid var(--border-color);
}

.dropdown:hover .dropdown-menu {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

.dropdown-menu li {
    position: relative;
}

.dropdown-menu li a {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px 16px;
    color: var(--body-text);
    font-size: 0.9rem;
    border-radius: var(--radius-sm);
    transition: var(--transition);
}

.dropdown-menu li a i {
    width: 20px;
    font-size: 1rem;
}

.dropdown-menu li a:hover {
    background: var(--light-bg);
    color: var(--primary-color);
}

/* Sub-dropdown */
.sub-dropdown {
    position: absolute;
    left: 100%;
    top: 0;
    background: var(--white);
    min-width: 220px;
    box-shadow: var(--shadow-lg);
    border-radius: var(--radius);
    padding: 8px;
    opacity: 0;
    visibility: hidden;
    transition: var(--transition);
    border: 1px solid var(--border-color);
}

.dropdown-menu li:hover > .sub-dropdown {
    opacity: 1;
    visibility: visible;
}

/* Search Box */
.search-box {
    position: relative;
}

.search-box form {
    display: flex;
    align-items: center;
    background: var(--light-bg);
    border-radius: var(--radius-full);
    overflow: hidden;
    border: 2px solid transparent;
    transition: var(--transition);
}

.search-box form:focus-within {
    border-color: var(--primary-color);
    background: var(--white);
    box-shadow: 0 0 0 4px rgba(37, 99, 235, 0.1);
}

.search-box input {
    padding: 10px 16px;
    border: none;
    background: transparent;
    outline: none;
    width: 180px;
    font-size: 0.9rem;
    color: var(--dark-text);
}

.search-box input::placeholder {
    color: var(--muted-text);
}

.search-box button {
    padding: 10px 16px;
    border: none;
    background: var(--primary-color);
    color: var(--white);
    cursor: pointer;
    transition: var(--transition);
    font-size: 0.9rem;
}

.search-box button:hover {
    background: var(--primary-dark);
}

/* Mobile Toggle */
.mobile-toggle {
    display: none;
    flex-direction: column;
    gap: 5px;
    cursor: pointer;
    padding: 8px;
    border-radius: var(--radius-sm);
    transition: var(--transition);
}

.mobile-toggle:hover {
    background: var(--light-bg);
}

.mobile-toggle span {
    width: 24px;
    height: 2.5px;
    background: var(--dark-text);
    border-radius: 2px;
    transition: var(--transition);
}

/* === Hero Section === */
.hero {
    background: var(--gradient-hero);
    padding: 100px 0 120px;
    text-align: center;
    color: var(--white);
    position: relative;
    overflow: hidden;
}

.hero::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: url("data:image/svg+xml,%3Csvg width='60' height='60' viewBox='0 0 60 60' xmlns='http://www.w3.org/2000/svg'%3E%3Cg fill='none' fill-rule='evenodd'%3E%3Cg fill='%23ffffff' fill-opacity='0.05'%3E%3Cpath d='M36 34v-4h-2v4h-4v2h4v4h2v-4h4v-2h-4zm0-30V0h-2v4h-4v2h4v4h2V6h4V4h-4zM6 34v-4H4v4H0v2h4v4h2v-4h4v-2H6zM6 4V0H4v4H0v2h4v4h2V6h4V4H6z'/%3E%3C/g%3E%3C/g%3E%3C/svg%3E");
    opacity: 0.5;
}

.hero-content {
    max-width: 90%;
    margin: 0 auto;
    position: relative;
    z-index: 1;
}

.hero-badge {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 8px 16px;
    background: rgba(255, 255, 255, 0.15);
    border-radius: var(--radius-full);
    font-size: 0.85rem;
    margin-bottom: 24px;
    backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.2);
}

.hero-title {
    font-size: clamp(2rem, 5vw, 3rem);
    margin-bottom: 24px;
    font-weight: 700;
    line-height: 1.3;
    animation: fadeInUp 0.6s ease;
    letter-spacing: -0.02em;
}

.hero-subtitle {
    font-size: clamp(1.05rem, 2vw, 1.3rem);
    margin-bottom: 40px;
    opacity: 0.95;
    animation: fadeInUp 0.8s ease;
    max-width: 650px;
    margin-left: auto;
    margin-right: auto;
    line-height: 1.7;
    line-height: 1.8;
}

.hero-buttons {
    display: flex;
    justify-content: center;
    gap: 16px;
    flex-wrap: wrap;
    animation: fadeInUp 1s ease;
}

.hero-stats {
    display: flex;
    justify-content: center;
    gap: 48px;
    margin-top: 60px;
    padding-top: 40px;
    border-top: 1px solid rgba(255, 255, 255, 0.2);
    animation: fadeInUp 1.2s ease;
}

.hero-stat {
    text-align: center;
}

.hero-stat-number {
    font-size: 2.5rem;
    font-weight: 700;
    display: block;
}

.hero-stat-label {
    font-size: 0.9rem;
    opacity: 0.8;
}

/* === Section Styles === */
.section-header {
    text-align: center;
    margin-bottom: 56px;
}

.section-header h2 {
    font-size: clamp(1.75rem, 3vw, 2.25rem);
    color: var(--dark-text);
    margin-bottom: 16px;
    font-weight: 700;
    letter-spacing: -0.01em;
}

.section-header h2::after {
    content: '';
    display: block;
    width: 60px;
    height: 4px;
    background: var(--primary-color);
    margin: 16px auto 0;
    border-radius: 2px;
}

.section-header p {
    color: var(--body-text);
    font-size: 1.1rem;
    max-width: 650px;
    margin: 0 auto;
    line-height: 1.8;
}

/* === Categories Section === */
.categories-section {
    padding: 90px 0;
    background: var(--white);
}

.categories-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
    gap: 28px;
}

.category-card {
    background: var(--white);
    padding: 36px;
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow);
    transition: var(--transition);
    text-align: center;
    border: 1px solid var(--border-light);
    border: 1px solid var(--border-light);
    position: relative;
    overflow: hidden;
}

.category-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 4px;
    background: var(--gradient-primary);
    transform: scaleX(0);
    transition: var(--transition);
}

.category-card:hover {
    transform: translateY(-8px);
    box-shadow: var(--shadow-lg);
}

.category-card:hover::before {
    transform: scaleX(1);
}

.category-icon {
    width: 80px;
    height: 80px;
    margin: 0 auto 20px;
    border-radius: var(--radius-lg);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 2rem;
    transition: var(--transition);
}

.category-card:hover .category-icon {
    transform: scale(1.1);
}

.category-card h3 {
    color: var(--dark-text);
    margin-bottom: 12px;
    font-size: 1.3rem;
    font-weight: 600;
}

.category-card p {
    color: var(--body-text);
    margin-bottom: 24px;
    font-size: 1rem;
    line-height: 1.7;
}

.category-link {
    color: var(--white);
    background: var(--primary-color);
    font-weight: 600;
    font-size: 0.95rem;
    display: inline-flex;
    align-items: center;
    gap: 10px;
    padding: 12px 24px;
    border-radius: var(--radius);
    transition: var(--transition);
}

.category-link:hover {
    background: var(--primary-dark);
    transform: translateX(4px);
}

.category-link i {
    transition: var(--transition);
}

.category-card:hover .category-link i {
    transform: translateX(4px);
}

/* === Schemes Section === */
.schemes-section {
    padding: 80px 0;
    background: var(--light-bg);
}

.schemes-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(340px, 1fr));
    gap: 28px;
}

.scheme-card {
    background: var(--white);
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow);
    overflow: hidden;
    transition: var(--transition);
    border: 1px solid var(--border-color);
    position: relative;
}

.scheme-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 4px;
    background: var(--primary-color);
    opacity: 0;
    transition: var(--transition);
}

.scheme-card:hover {
    transform: translateY(-4px);
    box-shadow: var(--shadow-lg);
    border-color: var(--primary-light);
}

.scheme-card:hover::before {
    opacity: 1;
}

.scheme-image {
    height: 180px;
    background: var(--gradient-primary);
    display: flex;
    align-items: center;
    justify-content: center;
}

.scheme-image i {
    font-size: 4rem;
    color: rgba(255, 255, 255, 0.3);
}

.scheme-category {
    padding: 6px 16px;
    color: var(--white);
    font-size: 0.8rem;
    font-weight: 600;
    display: inline-block;
    border-radius: var(--radius-full);
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.scheme-content {
    padding: 28px;
}

.scheme-content h3 {
    margin-bottom: 14px;
    font-size: 1.2rem;
    line-height: 1.5;
    font-weight: 600;
}

.scheme-content h3 a {
    color: var(--dark-text);
    transition: var(--transition);
}

.scheme-content h3 a:hover {
    color: var(--primary-color);
}

.scheme-content p {
    color: var(--body-text);
    margin-bottom: 18px;
    font-size: 1rem;
    line-height: 1.8;
}

.scheme-meta {
    display: flex;
    flex-wrap: wrap;
    gap: 16px;
    font-size: 0.9rem;
    color: var(--light-text);
    margin-bottom: 18px;
    padding-top: 18px;
    border-top: 1px solid var(--border-light);
}

.scheme-meta span {
    display: flex;
    align-items: center;
    gap: 8px;
}

.scheme-meta i {
    color: var(--primary-color);
}

.read-more {
    color: var(--primary-color);
    font-weight: 600;
    font-size: 1rem;
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 10px 20px;
    background: rgba(26, 86, 219, 0.08);
    border-radius: var(--radius);
    transition: var(--transition);
}

.read-more i {
    transition: var(--transition);
    font-size: 0.9rem;
}

.read-more:hover {
    background: var(--primary-color);
    color: white;
    gap: 12px;
}

.read-more:hover i {
    transform: translateX(2px);
}

/* === Popular Section === */
.popular-section {
    padding: 80px 0;
    background: var(--white);
}

.popular-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 20px;
}

.popular-card {
    background: var(--white);
    padding: 24px;
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow);
    display: flex;
    gap: 20px;
    align-items: flex-start;
    transition: var(--transition);
    border: 1px solid var(--border-light);
}

.popular-card:hover {
    transform: translateX(6px);
    box-shadow: var(--shadow-md);
    border-color: var(--primary-light);
}

.popular-number {
    font-size: 2.5rem;
    font-weight: 800;
    background: var(--gradient-primary);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    opacity: 0.4;
    line-height: 1;
}

.popular-content {
    flex: 1;
}

.popular-category {
    font-size: 0.8rem;
    font-weight: 600;
    margin-bottom: 6px;
    display: block;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.popular-content h4 {
    margin-bottom: 8px;
}

.popular-content h4 a {
    color: var(--dark-text);
    font-size: 1rem;
    line-height: 1.4;
}

.popular-content h4 a:hover {
    color: var(--primary-color);
}

.popular-meta {
    font-size: 0.85rem;
    color: var(--muted-text);
    display: flex;
    align-items: center;
    gap: 6px;
}

/* === Features Section === */
.features-section {
    padding: 80px 0;
    background: var(--light-bg);
}

.features-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 28px;
}

.feature-card {
    text-align: center;
    padding: 44px 32px;
    background: var(--white);
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow);
    transition: var(--transition);
    border: 2px solid var(--border-light);
}

.feature-card:hover {
    transform: translateY(-4px);
    box-shadow: var(--shadow-lg);
    border-color: var(--primary-light);
}

.feature-icon {
    width: 90px;
    height: 90px;
    margin: 0 auto 28px;
    background: var(--primary-color);
    border-radius: var(--radius-lg);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 2.2rem;
    color: var(--white);
    box-shadow: 0 8px 20px rgba(26, 86, 219, 0.3);
}

.feature-card h3 {
    color: var(--dark-text);
    margin-bottom: 14px;
    font-size: 1.25rem;
    font-weight: 600;
}

.feature-card p {
    color: var(--body-text);
    font-size: 1rem;
    line-height: 1.8;
}

/* === Page Header === */
.page-header {
    background: var(--gradient-primary);
    padding: 48px 0;
    color: var(--white);
    position: relative;
    overflow: hidden;
}

.page-header::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: url("data:image/svg+xml,%3Csvg width='60' height='60' viewBox='0 0 60 60' xmlns='http://www.w3.org/2000/svg'%3E%3Cg fill='none' fill-rule='evenodd'%3E%3Cg fill='%23ffffff' fill-opacity='0.05'%3E%3Cpath d='M36 34v-4h-2v4h-4v2h4v4h2v-4h4v-2h-4zm0-30V0h-2v4h-4v2h4v4h2V6h4V4h-4zM6 34v-4H4v4H0v2h4v4h2v-4h4v-2H6zM6 4V0H4v4H0v2h4v4h2V6h4V4H6z'/%3E%3C/g%3E%3C/g%3E%3C/svg%3E");
    opacity: 0.5;
}

.page-header-content {
    position: relative;
    z-index: 1;
}

.page-header-content h1 {
    font-size: clamp(1.5rem, 3vw, 2rem);
    margin-bottom: 8px;
    font-weight: 700;
    color: var(--white);
}

.page-header-content p {
    font-size: 1rem;
    opacity: 0.9;
    margin: 0;
}

/* === Breadcrumb === */
.breadcrumb {
    background: var(--white);
    padding: 14px 0;
    font-size: 0.9rem;
    border-bottom: 1px solid var(--border-light);
}

.breadcrumb a {
    color: var(--primary-color);
    font-weight: 500;
}

.breadcrumb a:hover {
    text-decoration: underline;
}

.breadcrumb i {
    margin: 0 10px;
    font-size: 0.7rem;
    color: var(--muted-text);
}

/* === Post Page === */
.post-section {
    padding: 50px 0;
    background: var(--light-bg);
}

.post-layout {
    display: grid;
    grid-template-columns: 1fr 340px;
    gap: 40px;
}

.post-content {
    background: var(--white);
    padding: 40px;
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow);
    border: 1px solid var(--border-light);
}

.post-header {
    margin-bottom: 30px;
}

.post-category {
    display: inline-block;
    padding: 6px 16px;
    border-radius: var(--radius-full);
    color: var(--white);
    font-size: 0.8rem;
    margin-bottom: 16px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.post-header h1 {
    font-size: clamp(1.5rem, 3vw, 2rem);
    line-height: 1.3;
    margin-bottom: 16px;
}

.post-meta {
    display: flex;
    gap: 24px;
    color: var(--muted-text);
    font-size: 0.9rem;
    flex-wrap: wrap;
}

.post-meta span {
    display: flex;
    align-items: center;
    gap: 6px;
}

.post-image {
    margin: 32px 0;
    border-radius: var(--radius-lg);
    overflow: hidden;
}

.post-body {
    font-size: 1.1rem;
    line-height: 2;
    color: var(--body-text);
}

.post-body h2 {
    margin-top: 40px;
    margin-bottom: 20px;
    color: var(--dark-text);
    font-size: 1.6rem;
    font-weight: 600;
    padding-bottom: 12px;
    border-bottom: 2px solid var(--border-light);
}

.post-body h3 {
    margin-top: 32px;
    margin-bottom: 16px;
    color: var(--dark-text);
    font-size: 1.35rem;
    font-weight: 600;
}

.post-body h4 {
    margin-top: 24px;
    margin-bottom: 12px;
    color: var(--dark-text);
    font-size: 1.2rem;
    font-weight: 600;
}

.post-body ul, .post-body ol {
    margin: 28px 0;
    padding-left: 32px;
}

.post-body ul {
    list-style: disc;
}

.post-body ol {
    list-style: decimal;
}

.post-body li {
    margin-bottom: 14px;
    line-height: 1.9;
    padding-left: 8px;
}

.post-body p {
    margin-bottom: 24px;
}

.post-body a {
    color: var(--primary-color);
    font-weight: 600;
    text-decoration: underline;
    text-underline-offset: 3px;
}

.post-body a:hover {
    text-decoration-thickness: 2px;
}

/* Important info boxes in content */
.post-body blockquote {
    background: #f0f7ff;
    border-left: 5px solid var(--primary-color);
    padding: 24px 28px;
    margin: 28px 0;
    border-radius: 0 var(--radius) var(--radius) 0;
    font-size: 1.05rem;
    color: var(--dark-text);
}

.post-body table {
    width: 100%;
    border-collapse: collapse;
    margin: 28px 0;
    font-size: 1rem;
}

.post-body table th,
.post-body table td {
    padding: 14px 16px;
    border: 1px solid var(--border-color);
    text-align: left;
}

.post-body table th {
    background: var(--primary-color);
    color: white;
    font-weight: 600;
}

.post-body table tr:nth-child(even) {
    background: var(--light-bg);
}

/* Share Section */
.share-section {
    margin-top: 48px;
    padding-top: 32px;
    border-top: 2px solid var(--border-light);
}

.share-section h4 {
    margin-bottom: 18px;
    font-size: 1.1rem;
}

.share-buttons {
    display: flex;
    gap: 12px;
    flex-wrap: wrap;
}

.share-btn {
    padding: 12px 24px;
    border-radius: var(--radius);
    color: var(--white);
    font-weight: 500;
    font-size: 0.9rem;
    display: inline-flex;
    align-items: center;
    gap: 8px;
    transition: var(--transition);
}

.share-btn:hover {
    transform: translateY(-3px);
    box-shadow: var(--shadow-md);
}

.share-btn.facebook { background: #1877f2; }
.share-btn.twitter { background: #1da1f2; }
.share-btn.whatsapp { background: #25d366; }

/* === Sidebar === */
.sidebar-widget {
    background: var(--white);
    padding: 28px;
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow);
    margin-bottom: 28px;
    border: 1px solid var(--border-light);
}

.sidebar-widget h3 {
    margin-bottom: 20px;
    padding-bottom: 16px;
    border-bottom: 2px solid var(--border-light);
    font-size: 1.1rem;
    color: var(--dark-text);
}

.related-post {
    padding: 16px 0;
    border-bottom: 1px solid var(--border-light);
}

.related-post:last-child {
    border-bottom: none;
    padding-bottom: 0;
}

.related-post:first-child {
    padding-top: 0;
}

.related-post h4 {
    margin-bottom: 6px;
}

.related-post h4 a {
    color: var(--dark-text);
    font-size: 0.95rem;
    line-height: 1.5;
}

.related-post h4 a:hover {
    color: var(--primary-color);
}

.related-date {
    font-size: 0.85rem;
    color: var(--muted-text);
    display: flex;
    align-items: center;
    gap: 6px;
}

.category-list li {
    margin-bottom: 6px;
}

.category-list li a {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px 14px;
    border-radius: var(--radius);
    transition: var(--transition);
    color: var(--body-text);
    font-size: 0.95rem;
}

.category-list li a:hover {
    background: var(--light-bg);
    color: var(--primary-color);
}

.category-list li a i {
    width: 20px;
}

/* === Empty State === */
.empty-state {
    text-align: center;
    padding: 80px 20px;
    background: var(--white);
    border-radius: var(--radius-lg);
}

.empty-state i {
    font-size: 5rem;
    color: var(--muted-text);
    margin-bottom: 24px;
    opacity: 0.5;
}

.empty-state h3 {
    margin-bottom: 12px;
    font-size: 1.5rem;
}

.empty-state p {
    color: var(--light-text);
    margin-bottom: 24px;
    font-size: 1.05rem;
}

/* === Contact Page === */
.contact-section {
    padding: 50px 0;
}

.contact-layout {
    display: grid;
    grid-template-columns: 1.5fr 1fr;
    gap: 40px;
}

.contact-form-wrapper,
.contact-info-wrapper {
    background: var(--white);
    padding: 40px;
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow);
    border: 1px solid var(--border-light);
}

.contact-form-wrapper h2,
.contact-info-wrapper h2 {
    margin-bottom: 28px;
    font-size: 1.5rem;
}

.form-group {
    margin-bottom: 24px;
}

.form-group label {
    display: block;
    margin-bottom: 8px;
    font-weight: 500;
    color: var(--dark-text);
    font-size: 0.95rem;
}

.form-group input,
.form-group textarea,
.form-group select {
    width: 100%;
    padding: 14px 18px;
    border: 2px solid var(--border-color);
    border-radius: var(--radius);
    font-family: inherit;
    font-size: 1rem;
    transition: var(--transition);
    background: var(--white);
}

.form-group input:focus,
.form-group textarea:focus,
.form-group select:focus {
    outline: none;
    border-color: var(--primary-color);
    box-shadow: 0 0 0 4px rgba(37, 99, 235, 0.1);
}

.contact-info-card {
    padding: 28px;
    border-radius: var(--radius);
    background: var(--light-bg);
    margin-bottom: 20px;
    transition: var(--transition);
}

.contact-info-card:hover {
    background: var(--border-light);
}

.contact-icon {
    width: 56px;
    height: 56px;
    background: var(--gradient-primary);
    color: var(--white);
    border-radius: var(--radius);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.4rem;
    margin-bottom: 18px;
    box-shadow: 0 6px 16px rgba(37, 99, 235, 0.3);
}

.contact-info-card h3 {
    margin-bottom: 10px;
    font-size: 1.1rem;
}

.contact-info-card p {
    color: var(--light-text);
    margin-bottom: 4px;
    font-size: 0.95rem;
}

.social-connect {
    text-align: center;
    padding: 24px;
}

.social-links-large {
    display: flex;
    justify-content: center;
    gap: 14px;
    margin-top: 18px;
}

.social-links-large a {
    width: 48px;
    height: 48px;
    background: var(--gradient-primary);
    color: var(--white);
    border-radius: var(--radius);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.1rem;
    transition: var(--transition);
    box-shadow: 0 4px 12px rgba(37, 99, 235, 0.3);
}

.social-links-large a:hover {
    transform: translateY(-4px);
    box-shadow: 0 8px 20px rgba(37, 99, 235, 0.4);
}

/* === Alerts === */
.alert {
    padding: 16px 20px;
    border-radius: var(--radius);
    margin-bottom: 24px;
    display: flex;
    align-items: center;
    gap: 12px;
    font-size: 0.95rem;
}

.alert-success {
    background: #ecfdf5;
    color: #065f46;
    border: 1px solid #a7f3d0;
}

.alert-error {
    background: #fef2f2;
    color: #991b1b;
    border: 1px solid #fecaca;
}

.alert-info {
    background: #eff6ff;
    color: #1e40af;
    border: 1px solid #bfdbfe;
}

/* === Footer === */
.footer {
    background: var(--dark-bg);
    color: var(--white);
    padding: 80px 0 28px;
}

.footer-content {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
    gap: 50px;
    margin-bottom: 50px;
}

.footer-section h3 {
    margin-bottom: 26px;
    color: var(--white);
    font-size: 1.2rem;
    font-weight: 600;
    position: relative;
    padding-bottom: 14px;
}

.footer-section h3::after {
    content: '';
    position: absolute;
    left: 0;
    bottom: 0;
    width: 45px;
    height: 3px;
    background: var(--primary-color);
    border-radius: 2px;
}

.footer-section p {
    color: rgba(255, 255, 255, 0.85);
    margin-bottom: 18px;
    line-height: 1.9;
    font-size: 1rem;
}

.footer-section ul li {
    margin-bottom: 14px;
}

.footer-section ul li a {
    color: rgba(255, 255, 255, 0.85);
    font-size: 1rem;
    display: inline-flex;
    align-items: center;
    gap: 10px;
    transition: var(--transition);
    padding: 4px 0;
}

.footer-section ul li a:hover {
    color: var(--white);
    padding-left: 8px;
}

.footer-section ul li a:hover {
    color: var(--primary-light);
    transform: translateX(4px);
}

.footer .social-links {
    display: flex;
    gap: 12px;
    margin-top: 20px;
}

.footer .social-links a {
    width: 42px;
    height: 42px;
    background: rgba(255, 255, 255, 0.1);
    border-radius: var(--radius);
    display: flex;
    align-items: center;
    justify-content: center;
    transition: var(--transition);
    font-size: 1rem;
}

.footer .social-links a:hover {
    background: var(--primary-color);
    transform: translateY(-4px);
}

.newsletter-form {
    display: flex;
    margin-top: 18px;
    border-radius: var(--radius);
    overflow: hidden;
    background: rgba(255, 255, 255, 0.1);
}

.newsletter-form input {
    flex: 1;
    padding: 14px 18px;
    border: none;
    background: transparent;
    outline: none;
    color: var(--white);
    font-size: 0.95rem;
}

.newsletter-form input::placeholder {
    color: rgba(255, 255, 255, 0.5);
}

.newsletter-form button {
    padding: 14px 24px;
    border: none;
    background: var(--primary-color);
    color: var(--white);
    cursor: pointer;
    transition: var(--transition);
    font-size: 1rem;
}

.newsletter-form button:hover {
    background: var(--primary-dark);
}

.footer-bottom {
    text-align: center;
    padding-top: 32px;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
}

.footer-bottom p {
    color: rgba(255, 255, 255, 0.6);
    margin-bottom: 6px;
    font-size: 0.9rem;
}

.footer-bottom i.fa-heart {
    color: #ef4444;
}

/* === Back to Top === */
.back-to-top {
    position: fixed;
    bottom: 30px;
    right: 30px;
    width: 52px;
    height: 52px;
    background: var(--gradient-primary);
    color: var(--white);
    border: none;
    border-radius: var(--radius);
    cursor: pointer;
    display: none;
    align-items: center;
    justify-content: center;
    font-size: 1.2rem;
    box-shadow: 0 8px 24px rgba(37, 99, 235, 0.4);
    transition: var(--transition);
    z-index: 999;
}

.back-to-top:hover {
    transform: translateY(-5px);
    box-shadow: 0 12px 32px rgba(37, 99, 235, 0.5);
}

.back-to-top.show {
    display: flex;
}

/* === Animations === */
@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes fadeIn {
    from { opacity: 0; }
    to { opacity: 1; }
}

@keyframes slideInRight {
    from {
        opacity: 0;
        transform: translateX(30px);
    }
    to {
        opacity: 1;
        transform: translateX(0);
    }
}

/* === Search Results === */
.search-count {
    margin-bottom: 32px;
    font-size: 1.1rem;
    color: var(--light-text);
}

/* === Page Content Styles === */
.page-content-section {
    padding: 50px 0;
    background: var(--light-bg);
}

.page-layout {
    display: grid;
    grid-template-columns: 1fr 340px;
    gap: 40px;
}

.page-content, .page-content-full {
    background: var(--white);
    padding: 40px;
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow);
    border: 1px solid var(--border-light);
    line-height: 1.9;
}

.page-content h2, .page-content-full h2 {
    color: var(--dark-text);
    margin-top: 36px;
    margin-bottom: 18px;
    font-size: 1.5rem;
}

.page-content h3, .page-content-full h3 {
    color: var(--dark-text);
    margin-top: 28px;
    margin-bottom: 14px;
    font-size: 1.25rem;
}

.page-content p, .page-content-full p {
    margin-bottom: 20px;
    color: var(--body-text);
}

.page-content ul, .page-content-full ul {
    margin: 24px 0;
    padding-left: 28px;
    list-style: disc;
}

.page-content li, .page-content-full li {
    margin-bottom: 12px;
    color: var(--body-text);
}

.contact-info-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 24px;
    margin: 32px 0;
}

.contact-box {
    padding: 28px;
    background: var(--light-bg);
    border-radius: var(--radius-lg);
    text-align: center;
    transition: var(--transition);
    border: 1px solid var(--border-light);
}

.contact-box:hover {
    transform: translateY(-4px);
    box-shadow: var(--shadow);
}

.contact-box h4 {
    color: var(--primary-color);
    margin-bottom: 12px;
}

.contact-box i {
    font-size: 2.5rem;
    margin-bottom: 16px;
    color: var(--primary-color);
}

.dynamic-contact-form {
    margin: 32px 0;
    padding: 32px;
    background: var(--light-bg);
    border-radius: var(--radius-lg);
    border: 1px solid var(--border-light);
}

.form-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 20px;
}

.faq-item {
    padding: 28px;
    margin-bottom: 20px;
    background: var(--light-bg);
    border-radius: var(--radius-lg);
    border-left: 4px solid var(--primary-color);
}

.faq-item h3 {
    color: var(--primary-color);
    margin-top: 0;
}

.page-sidebar {
    /* Uses same styles as post sidebar */
}

/* === Responsive Design === */
@media (max-width: 1200px) {
    .container {
        max-width: 95%;
        width: 95%;
    }
    
    .post-layout,
    .page-layout {
        grid-template-columns: 1fr 300px;
    }
}

@media (max-width: 968px) {
    .container {
        max-width: 95%;
        width: 95%;
        padding: 0 15px;
    }
    
    .post-layout,
    .contact-layout,
    .page-layout {
        grid-template-columns: 1fr;
    }
    
    .nav-menu {
        position: fixed;
        top: 0;
        right: -100%;
        width: 300px;
        height: 100vh;
        background: var(--white);
        flex-direction: column;
        padding: 80px 24px 32px;
        box-shadow: var(--shadow-xl);
        transition: var(--transition);
        z-index: 999;
        overflow-y: auto;
    }
    
    .nav-menu.active {
        right: 0;
    }
    
    .nav-list {
        flex-direction: column;
        align-items: stretch;
        width: 100%;
        gap: 4px;
    }
    
    .nav-link {
        justify-content: space-between;
        padding: 14px 16px;
    }
    
    .dropdown-menu {
        position: static;
        opacity: 1;
        visibility: visible;
        transform: none;
        box-shadow: none;
        border: none;
        padding: 0 0 0 16px;
        display: none;
        background: var(--light-bg);
        border-radius: var(--radius);
        margin-top: 8px;
    }
    
    .dropdown.active .dropdown-menu {
        display: block;
    }
    
    .search-box {
        width: 100%;
        margin-top: 16px;
    }
    
    .search-box input {
        width: 100%;
    }
    
    .mobile-toggle {
        display: flex;
        z-index: 1000;
    }
    
    .hero {
        padding: 70px 0 90px;
    }
    
    .hero-stats {
        gap: 32px;
        flex-wrap: wrap;
    }
    
    .categories-grid {
        grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
    }
    
    .schemes-grid {
        grid-template-columns: 1fr;
    }
    
    .post-content,
    .page-content,
    .page-content-full {
        padding: 28px;
    }
    
    .contact-form-wrapper,
    .contact-info-wrapper {
        padding: 28px;
    }
}

@media (max-width: 640px) {
    .hero {
        padding: 50px 0 70px;
    }
    
    .hero-title {
        font-size: 1.75rem;
    }
    
    .hero-buttons {
        flex-direction: column;
        align-items: center;
    }
    
    .hero-buttons .btn {
        width: 100%;
        max-width: 280px;
    }
    
    .hero-stats {
        flex-direction: column;
        gap: 24px;
    }
    
    .section-header h2 {
        font-size: 1.5rem;
    }
    
    .page-header {
        padding: 32px 0;
    }
    
    .page-header-content h1 {
        font-size: 1.35rem;
    }
    
    .post-header h1 {
        font-size: 1.35rem;
    }
    
    .top-bar {
        padding: 10px 0;
    }
    
    .top-bar-content {
        flex-direction: column;
        text-align: center;
        gap: 8px;
    }
    
    .contact-info {
        flex-direction: column;
        gap: 4px;
    }
    
    .share-buttons {
        flex-direction: column;
    }
    
    .share-btn {
        justify-content: center;
    }
    
    .categories-grid {
        grid-template-columns: 1fr;
    }
    
    .popular-grid {
        grid-template-columns: 1fr;
    }
    
    .features-grid {
        grid-template-columns: 1fr;
    }
    
    .category-card,
    .feature-card {
        padding: 24px;
    }
    
    .post-content,
    .page-content,
    .page-content-full {
        padding: 20px;
    }
    
    .form-row {
        grid-template-columns: 1fr;
    }
    
    .contact-info-grid {
        grid-template-columns: 1fr;
    }
    
    .footer-content {
        gap: 36px;
    }
    
    .back-to-top {
        bottom: 20px;
        right: 20px;
        width: 46px;
        height: 46px;
    }
}

/* === Accessibility Enhancements === */

/* Larger text option class */
body.large-text {
    font-size: 1.15rem;
}

body.large-text .post-body {
    font-size: 1.25rem;
    line-height: 2.1;
}

body.large-text h1 { font-size: 2.5rem; }
body.large-text h2 { font-size: 2rem; }
body.large-text h3 { font-size: 1.6rem; }

/* High contrast mode */
body.high-contrast {
    --primary-color: #0047ab;
    --body-text: #1a1a1a;
    --light-text: #333333;
}

/* Reduced motion for users who prefer it */
@media (prefers-reduced-motion: reduce) {
    *,
    *::before,
    *::after {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
    }
    
    html {
        scroll-behavior: auto;
    }
}

/* Better spacing for touch devices */
@media (pointer: coarse) {
    .btn {
        min-height: 52px;
        padding: 16px 36px;
    }
    
    .nav-link {
        padding: 14px 18px;
    }
    
    .read-more {
        padding: 14px 24px;
    }
}

/* === Print Styles === */
@media print {
    .header,
    .footer,
    .sidebar-widget,
    .back-to-top,
    .share-section {
        display: none !important;
    }
    
    .post-layout,
    .page-layout {
        grid-template-columns: 1fr;
    }
    
    .post-content,
    .page-content {
        box-shadow: none;
        border: none;
    }
    
    body {
        font-size: 12pt;
        line-height: 1.6;
        color: #000;
    }
    
    .post-body {
        font-size: 12pt;
    }
}
