/* ========================================
   Blog Styles
   ======================================== */

/* Blog Header */
.blog-header {
    padding: 140px 0 80px;
    text-align: center;
    background: linear-gradient(180deg, var(--bg-secondary) 0%, var(--bg-primary) 100%);
}

.blog-header-content {
    max-width: 800px;
    margin: 0 auto;
}

.blog-header h1 {
    margin: 1.5rem 0;
}

.blog-header p {
    font-size: 1.25rem;
    margin-bottom: 3rem;
}

/* Search and Filters */
.blog-filters {
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
    align-items: center;
    margin-top: 2rem;
}

.search-box {
    position: relative;
    width: 100%;
    max-width: 500px;
}

.search-box i {
    position: absolute;
    left: 1.25rem;
    top: 50%;
    transform: translateY(-50%);
    color: var(--text-light);
}

.search-box input {
    width: 100%;
    padding: 1rem 1rem 1rem 3rem;
    border: 2px solid rgba(0, 0, 0, 0.1);
    border-radius: var(--radius-md);
    font-family: var(--font-primary);
    font-size: 1rem;
    transition: var(--transition);
}

.search-box input:focus {
    outline: none;
    border-color: var(--primary);
    box-shadow: 0 0 0 4px rgba(99, 102, 241, 0.1);
}

.filter-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 0.75rem;
    justify-content: center;
}

.filter-tag {
    padding: 0.625rem 1.25rem;
    background: white;
    border: 2px solid rgba(0, 0, 0, 0.1);
    border-radius: 100px;
    font-family: var(--font-heading);
    font-size: 0.875rem;
    font-weight: 600;
    color: var(--text-secondary);
    cursor: pointer;
    transition: var(--transition);
}

.filter-tag:hover {
    border-color: var(--primary);
    color: var(--primary);
}

.filter-tag.active {
    background: var(--gradient-1);
    border-color: transparent;
    color: white;
}

/* Featured Article */
.featured-article {
    padding: 4rem 0;
}

.featured-card {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 3rem;
    background: white;
    border-radius: var(--radius-xl);
    overflow: hidden;
    box-shadow: var(--shadow-xl);
    border: 2px solid rgba(0, 0, 0, 0.05);
}

.featured-image {
    position: relative;
    height: 100%;
    min-height: 400px;
    overflow: hidden;
}

.featured-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: var(--transition);
}

.featured-card:hover .featured-image img {
    opacity: 0.9;
}

.featured-badge {
    position: absolute;
    top: 1.5rem;
    left: 1.5rem;
    background: var(--gradient-1);
    color: white;
    padding: 0.625rem 1.25rem;
    border-radius: 100px;
    font-size: 0.875rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.featured-content {
    padding: 3rem;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
}

.article-meta {
    display: flex;
    align-items: center;
    gap: 1rem;
    margin-bottom: 1.5rem;
}

.category {
    display: inline-flex;
    padding: 0.5rem 1rem;
    background: rgba(99, 102, 241, 0.1);
    color: var(--primary);
    border-radius: 100px;
    font-size: 0.875rem;
    font-weight: 600;
}

.reading-time {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    color: var(--text-light);
    font-size: 0.875rem;
}

.featured-content h2 {
    font-size: 2rem;
    margin-bottom: 1rem;
    line-height: 1.3;
}

.featured-content > p {
    font-size: 1.125rem;
    margin-bottom: 2rem;
}

.article-footer {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding-top: 2rem;
    border-top: 1px solid rgba(0, 0, 0, 0.1);
}

.author-info {
    display: flex;
    align-items: center;
    gap: 1rem;
}

.author-avatar {
    width: 48px;
    height: 48px;
    background: var(--gradient-1);
    color: white;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.5rem;
}

.author-details {
    display: flex;
    flex-direction: column;
}

.author-name {
    font-weight: 600;
    color: var(--text-primary);
}

.publish-date {
    font-size: 0.875rem;
    color: var(--text-light);
}

/* Articles Section */
.articles-section {
    padding: 4rem 0;
}

.articles-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(350px, 1fr));
    gap: 2rem;
}

.article-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
    margin: 1rem 0;
}

.tag {
    padding: 0.375rem 0.75rem;
    background: rgba(99, 102, 241, 0.1);
    color: var(--primary);
    border-radius: 100px;
    font-size: 0.75rem;
    font-weight: 600;
}

/* Load More */
.load-more {
    text-align: center;
    margin-top: 3rem;
}

/* Newsletter Section */
.newsletter-section {
    padding: 4rem 0;
    background: var(--bg-secondary);
}

.newsletter-content {
    max-width: 700px;
    margin: 0 auto;
    text-align: center;
    background: white;
    padding: 4rem 3rem;
    border-radius: var(--radius-xl);
    box-shadow: var(--shadow-lg);
}

.newsletter-icon {
    width: 80px;
    height: 80px;
    background: var(--gradient-1);
    color: white;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 2rem;
    font-size: 2rem;
}

.newsletter-content h2 {
    margin-bottom: 1rem;
}

.newsletter-content > p {
    font-size: 1.125rem;
    margin-bottom: 2rem;
}

.newsletter-form {
    display: flex;
    gap: 1rem;
    margin-bottom: 1rem;
}

.newsletter-form input {
    flex: 1;
    padding: 1rem 1.5rem;
    border: 2px solid rgba(0, 0, 0, 0.1);
    border-radius: var(--radius-md);
    font-family: var(--font-primary);
    font-size: 1rem;
}

.newsletter-form input:focus {
    outline: none;
    border-color: var(--primary);
}

.newsletter-note {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    font-size: 0.875rem;
    color: var(--text-light);
    margin-top: 1rem;
}

/* Article Card Hidden State */
.blog-card.hidden {
    display: none;
}

/* Responsive Styles */
@media (max-width: 1024px) {
    .featured-card {
        grid-template-columns: 1fr;
    }
    
    .featured-image {
        min-height: 300px;
    }
    
    .articles-grid {
        grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    }
}

@media (max-width: 768px) {
    .blog-header {
        padding: 120px 0 60px;
    }
    
    .featured-content {
        padding: 2rem;
    }
    
    .featured-content h2 {
        font-size: 1.5rem;
    }
    
    .article-footer {
        flex-direction: column;
        gap: 1.5rem;
        align-items: flex-start;
    }
    
    .article-footer .btn {
        width: 100%;
        justify-content: center;
    }
    
    .articles-grid {
        grid-template-columns: 1fr;
    }
    
    .newsletter-content {
        padding: 2.5rem 1.5rem;
    }
    
    .newsletter-form {
        flex-direction: column;
    }
    
    .newsletter-form .btn {
        width: 100%;
        justify-content: center;
    }
}

@media (max-width: 480px) {
    .blog-filters {
        gap: 1rem;
    }
    
    .filter-tags {
        gap: 0.5rem;
    }
    
    .filter-tag {
        padding: 0.5rem 1rem;
        font-size: 0.8125rem;
    }
    
    .featured-badge {
        font-size: 0.75rem;
        padding: 0.5rem 1rem;
    }
}
