/* Resources Page Styles */

/* Global Styles */
.resources-page {
    background-color: #FAFAFA;
    min-height: 100vh;
}

.resources-page * {
    box-sizing: border-box;
}

/* Hero Section */
.resources-hero {
    background: #E8F8ED;
    padding: 80px 0 60px;
    text-align: center;
}

.resources-hero-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 24px;
}

.resources-hero h1 {
    font-size: 3rem;
    font-weight: 700;
    color: #027727;
    margin-bottom: 16px;
    line-height: 1.2;
}

.resources-hero-subtitle {
    font-size: 1.2rem;
    color: #4A4A4A;
    margin-bottom: 40px;
    max-width: 600px;
    margin-left: auto;
    margin-right: auto;
    line-height: 1.6;
}

/* Search Bar */
.resources-search {
    max-width: 500px;
    margin: 0 auto;
}

.search-form {
    position: relative;
    display: flex;
    background: white;
    border-radius: 12px;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.1);
    overflow: hidden;
    border: 2px solid #E0E0E0;
    transition: border-color 0.3s ease;
}

.search-form:focus-within {
    border-color: #027727;
}

.search-field {
    flex: 1;
    padding: 16px 20px;
    border: none;
    font-size: 1rem;
    background: transparent;
    outline: none;
}

.search-field::placeholder {
    color: #999;
}

.search-submit {
    background: #027727;
    border: none;
    padding: 16px 20px;
    cursor: pointer;
    transition: background-color 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
}

.search-submit:hover {
    background: #1976D2;
}

.search-submit svg {
    stroke: white !important;
}

.search-submit svg circle,
.search-submit svg path {
    stroke: white !important;
}

/* Navigation Section */
.resources-navigation {
    background: white;
    padding: 24px 0;
    border-bottom: 1px solid #E0E0E0;
    position: sticky;
    top: 0;
    z-index: 100;
}

.resources-nav-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 24px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 20px;
}

.category-filters {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
}

.filter-btn {
    background: #F5F5F5;
    border: 2px solid transparent;
    padding: 8px 16px;
    border-radius: 20px;
    font-size: 0.9rem;
    font-weight: 500;
    color: #666;
    cursor: pointer;
    transition: all 0.3s ease;
    white-space: nowrap;
}

.filter-btn:hover {
    background: #E3F2FD;
    color: #027727;
}

.filter-btn.active {
    background: #027727;
    color: white;
    border-color: #027727;
}

.view-options {
    display: flex;
    gap: 8px;
}

.view-btn {
    background: #F5F5F5;
    border: 2px solid transparent;
    padding: 8px;
    border-radius: 6px;
    cursor: pointer;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #666;
}

.view-btn:hover {
    background: #E3F2FD;
    color: #027727;
}

.view-btn.active {
    background: #027727;
    color: white;
    border-color: #027727;
}

/* Featured Article */
.featured-article {
    background: white;
    padding: 60px 0;
}

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

.section-title {
    font-size: 2rem;
    font-weight: 700;
    color: #2C2C2C;
    margin-bottom: 32px;
    text-align: center;
}

.featured-article-card {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 40px;
    background: white;
    border-radius: 16px;
    overflow: hidden;
    box-shadow: 0 8px 30px rgba(0, 0, 0, 0.1);
    border: 1px solid #E0E0E0;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.featured-article-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 12px 40px rgba(0, 0, 0, 0.15);
}

.featured-image {
    position: relative;
    overflow: hidden;
}

.featured-image img {
    width: 100%;
    height: 300px;
    object-fit: cover;
    transition: transform 0.3s ease;
}

.featured-article-card:hover .featured-image img {
    transform: scale(1.05);
}

.featured-badge {
    position: absolute;
    top: 16px;
    left: 16px;
    background: #43A047;
    color: white;
    padding: 6px 12px;
    border-radius: 16px;
    font-size: 0.8rem;
    font-weight: 600;
}

.featured-content {
    padding: 32px;
    display: flex;
    flex-direction: column;
    justify-content: center;
}

.featured-meta {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-bottom: 16px;
}

.featured-category {
    background: #E3F2FD;
    color: #1E88E5;
    padding: 4px 12px;
    border-radius: 12px;
    font-size: 0.8rem;
    font-weight: 600;
}

.featured-date {
    color: #999;
    font-size: 0.9rem;
}

.featured-title {
    font-size: 1.8rem;
    font-weight: 700;
    line-height: 1.3;
    margin-bottom: 16px;
}

.featured-title a {
    color: #2C2C2C;
    text-decoration: none;
    transition: color 0.3s ease;
}

.featured-title a:hover {
    color: #1E88E5;
}

.featured-excerpt {
    color: #4A4A4A;
    line-height: 1.6;
    margin-bottom: 24px;
    font-size: 1.1rem;
}

.featured-read-more {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    background: #1E88E5;
    color: white;
    padding: 12px 24px;
    border-radius: 8px;
    text-decoration: none;
    font-weight: 600;
    transition: all 0.3s ease;
    align-self: flex-start;
}

.featured-read-more:hover {
    background: #1976D2;
    transform: translateY(-2px);
    text-decoration: none;
    color: white;
}

/* Resources Content */
.resources-content {
    padding: 60px 0;
}

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

.resources-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 40px;
    flex-wrap: wrap;
    gap: 20px;
}

.results-count {
    color: #666;
    font-size: 0.9rem;
}

/* Resources Grid */
.resources-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(350px, 1fr));
    gap: 32px;
    margin-bottom: 60px;
}

.resources-grid.list-view {
    grid-template-columns: 1fr;
}

.resources-grid.list-view .resource-card {
    display: grid;
    grid-template-columns: 200px 1fr;
    gap: 24px;
}

.resources-grid.list-view .resource-image {
    height: 140px;
}

.resource-card {
    background: white;
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.08);
    border: 1px solid #E0E0E0;
    transition: all 0.3s ease;
    opacity: 1;
    transform: translateY(0);
}

.resource-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 8px 30px rgba(0, 0, 0, 0.12);
}

.resource-card.hidden {
    opacity: 0;
    transform: translateY(20px);
    pointer-events: none;
}

.resource-image {
    position: relative;
    height: 200px;
    overflow: hidden;
}

.resource-image img {
    width: 100%;
    height: 100%;
    object-fit: contain;
    object-position: center;
    background-color: #f8f9fa;
    transition: transform 0.3s ease;
}

.resource-card:hover .resource-image img {
    transform: scale(1.05);
}

.resource-placeholder {
    background: linear-gradient(135deg, #E3F2FD 0%, #F0F4F8 100%);
    display: flex;
    align-items: center;
    justify-content: center;
}

.placeholder-icon svg {
    opacity: 0.5;
}

.resource-content {
    padding: 24px;
}

.resource-meta {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 12px;
    flex-wrap: wrap;
    gap: 8px;
}

.resource-category {
    background: #E8F5E8;
    color: #2E7D32;
    padding: 4px 10px;
    border-radius: 12px;
    font-size: 0.75rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.resource-date {
    display: none;
}

.resource-title {
    font-size: 1.25rem;
    font-weight: 700;
    line-height: 1.4;
    margin-bottom: 12px;
}

.resource-title a {
    color: #2C2C2C;
    text-decoration: none;
    transition: color 0.3s ease;
}

.resource-title a:hover {
    color: #1E88E5;
}

.resource-excerpt {
    color: #4A4A4A;
    line-height: 1.6;
    margin-bottom: 20px;
    font-size: 0.95rem;
}

.resource-footer {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.resource-read-more {
    color: #1E88E5;
    text-decoration: none;
    font-weight: 600;
    font-size: 0.9rem;
    transition: all 0.3s ease;
}

.resource-read-more:hover {
    color: #1976D2;
    text-decoration: underline;
}

.resource-reading-time {
    color: #999;
    font-size: 0.8rem;
    display: flex;
    align-items: center;
    gap: 4px;
}

/* No Resources State */
.no-resources {
    grid-column: 1 / -1;
    text-align: center;
    padding: 60px 20px;
    color: #666;
}

.no-resources-icon {
    margin-bottom: 24px;
}

.no-resources h3 {
    font-size: 1.5rem;
    color: #999;
    margin-bottom: 12px;
}

.no-resources p {
    color: #999;
    font-size: 1rem;
}

/* Pagination */
.resources-pagination {
    display: flex;
    justify-content: center;
    margin-top: 40px;
}

.resources-pagination .page-numbers {
    display: inline-block;
    padding: 12px 16px;
    margin: 0 4px;
    background: white;
    color: #666;
    text-decoration: none;
    border-radius: 8px;
    border: 1px solid #E0E0E0;
    transition: all 0.3s ease;
}

.resources-pagination .page-numbers:hover,
.resources-pagination .page-numbers.current {
    background: #1E88E5;
    color: white;
    border-color: #1976D2;
    text-decoration: none;
}

/* Newsletter Section */
.resources-newsletter {
    background: linear-gradient(135deg, #1E88E5 0%, #1976D2 100%);
    padding: 60px 0;
    color: white;
}

.newsletter-container {
    max-width: 800px;
    margin: 0 auto;
    padding: 0 24px;
    text-align: center;
}

.newsletter-content h3 {
    font-size: 2rem;
    font-weight: 700;
    margin-bottom: 12px;
}

.newsletter-content p {
    font-size: 1.1rem;
    margin-bottom: 32px;
    opacity: 0.9;
}

.newsletter-form {
    display: flex;
    max-width: 400px;
    margin: 0 auto;
    background: white;
    border-radius: 8px;
    overflow: hidden;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.1);
}

.newsletter-form input {
    flex: 1;
    padding: 16px 20px;
    border: none;
    font-size: 1rem;
    outline: none;
}

.newsletter-form input::placeholder {
    color: #999;
}

.newsletter-form button {
    background: #43A047;
    color: white;
    border: none;
    padding: 16px 24px;
    font-weight: 600;
    cursor: pointer;
    transition: background-color 0.3s ease;
    white-space: nowrap;
}

.newsletter-form button:hover {
    background: #2E7D32;
}

/* Loading States */
.loading {
    opacity: 0.6;
    pointer-events: none;
}

.fade-in {
    animation: fadeIn 0.5s ease forwards;
}

@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Responsive Design */
@media (max-width: 1024px) {
    .featured-article-card {
        grid-template-columns: 1fr;
    }
    
    .featured-image {
        height: 250px;
    }
    
    .resources-grid {
        grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
        gap: 24px;
    }
    
    .resources-nav-container {
        flex-direction: column;
        align-items: stretch;
    }
    
    .category-filters {
        justify-content: center;
    }
    
    .view-options {
        justify-content: center;
    }
}

@media (max-width: 768px) {
    .resources-hero h1 {
        font-size: 2.5rem;
    }
    
    .resources-hero-subtitle {
        font-size: 1.1rem;
    }
    
    .resources-hero {
        padding: 60px 0 40px;
    }
    
    .resources-grid {
        grid-template-columns: 1fr;
        gap: 20px;
    }
    
    .resources-grid.list-view .resource-card {
        grid-template-columns: 1fr;
    }
    
    .featured-content {
        padding: 24px;
    }
    
    .featured-title {
        font-size: 1.5rem;
    }
    
    .category-filters {
        gap: 8px;
    }
    
    .filter-btn {
        font-size: 0.8rem;
        padding: 6px 12px;
    }
    
    .newsletter-form {
        flex-direction: column;
    }
    
    .newsletter-form input {
        border-radius: 8px 8px 0 0;
    }
    
    .newsletter-form button {
        border-radius: 0 0 8px 8px;
    }
}

@media (max-width: 480px) {
    .resources-hero h1 {
        font-size: 2rem;
    }
    
    .section-title {
        font-size: 1.75rem;
    }
    
    .resource-content {
        padding: 20px;
    }
    
    .featured-content {
        padding: 20px;
    }
    
    .resources-header {
        flex-direction: column;
        align-items: stretch;
        text-align: center;
    }
    
    .newsletter-content h3 {
        font-size: 1.75rem;
    }
}

/* Animation Classes */
.slide-in-up {
    animation: slideInUp 0.6s ease forwards;
}

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

/* Filter Animation */
.resource-card {
    transition: all 0.4s ease;
}

.resource-card.filtering {
    transform: scale(0.9);
    opacity: 0.3;
}
