/* Blog Page Styles - iFiCode Inclusive */
/* Light Theme to match index.html */

/* Blog Hero Section */
.blog-hero {
    background: transparent;
    padding: 120px 0 80px;
    position: relative;
    overflow: hidden;
}

/* Remove dark gradients and overlays that were for dark theme */
.blog-hero::before {
    display: none;
}

.blog-hero-content {
    text-align: center;
    position: relative;
    z-index: 2;
}

/* Layout for Hero with Image (used in insight.html) */
.blog-hero-layout {
    display: flex;
    align-items: center;
    gap: 60px;
    justify-content: space-between;
}

.blog-hero-layout .blog-hero-content {
    flex: 1;
    text-align: left;
}

.blog-hero-layout .blog-hero-subtitle {
    margin-left: 0;
}

.blog-hero-layout .blog-stats {
    justify-content: flex-start;
}

.blog-hero-image {
    flex: 1;
    max-width: 50%;
    position: relative;
}

.blog-hero-image img {
    width: 100%;
    height: auto;
    /* Removed card styling to eliminate the 'background' box look */
    mix-blend-mode: multiply; /* key to making white image background appear transparent */
}

@media (max-width: 992px) {
    .blog-hero-layout {
        flex-direction: column;
    }

    .blog-hero-image {
        max-width: 100%;
        margin-top: 40px;
    }

    .blog-hero-layout .blog-hero-content {
        text-align: center;
    }

    .blog-hero-layout .blog-hero-subtitle {
        margin: 0 auto 40px;
    }

    .blog-hero-layout .blog-stats {
        justify-content: center;
    }
}

.blog-hero-title {
    font-size: 3.5rem;
    font-weight: 800;
    color: #111827; /* Dark text */
    margin-bottom: 24px;
    line-height: 1.2;
    font-family: 'Playfair Display', serif;
}

.gradient-text {
    background: linear-gradient(135deg, #6D28D9 0%, #A855F7 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.blog-hero-subtitle {
    font-size: 1.25rem;
    color: #4B5563; /* Gray text for subtitle */
    max-width: 600px;
    margin: 0 auto 40px;
    line-height: 1.6;
    font-weight: 400;
}

.blog-stats {
    display: flex;
    justify-content: center;
    gap: 60px;
    margin-top: 50px;
}

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

.stat-number {
    display: block;
    font-size: 2.5rem;
    font-weight: 700;
    background: linear-gradient(135deg, #6D28D9 0%, #A855F7 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    margin-bottom: 8px;
}

.stat-label {
    font-size: 0.9rem;
    color: #111827; /* Dark text */
    text-transform: uppercase;
    letter-spacing: 1px;
    font-weight: 500;
}

/* Blog Categories Filter */
.blog-categories {
    padding: 60px 0 40px;
    background: #FFFFFF; /* White */
    border-bottom: 1px solid #E5E7EB; /* Separator */
}

.categories-filter {
    display: flex;
    justify-content: center;
    flex-wrap: wrap;
    gap: 16px;
}

.category-btn {
    background: #F3F4F6; /* Light gray */
    border: 1px solid transparent;
    color: #4B5563; /* Dark gray text */
    padding: 12px 24px;
    border-radius: 25px;
    font-weight: 600;
    font-size: 0.9rem;
    cursor: pointer;
    transition: var(--transition);
    letter-spacing: 0.5px;
}

.category-btn:hover,
.category-btn.active {
    background: linear-gradient(135deg, #6D28D9 0%, #A855F7 100%);
    color: #FFFFFF;
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(109, 40, 217, 0.2);
}

/* Featured Article */
.featured-article {
    padding: 80px 0;
    background: #F9FAFB; /* Light Gray Background */
}

.featured-content {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 60px;
    align-items: center;
}

.featured-image {
    position: relative;
    border-radius: 20px;
    overflow: hidden;
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.1); /* Lighter shadow */
}

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

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

.featured-badge {
    position: absolute;
    top: 20px;
    left: 20px;
    background: linear-gradient(135deg, #6D28D9 0%, #A855F7 100%);
    color: white;
    padding: 8px 16px;
    border-radius: 20px;
    font-size: 0.8rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 1px;
}

.article-meta {
    display: flex;
    gap: 20px;
    margin-bottom: 20px;
    font-size: 0.9rem;
}

.article-meta .category {
    background: rgba(139, 92, 246, 0.1);
    color: #6D28D9;
    padding: 4px 12px;
    border-radius: 12px;
    font-weight: 600;
}

.article-meta .date,
.article-meta .read-time {
    color: #6B7280; /* Gray 500 */
}

.featured-title {
    font-size: 2.5rem;
    font-weight: 700;
    color: #111827; /* Dark text */
    margin-bottom: 20px;
    line-height: 1.3;
    font-family: 'Playfair Display', serif;
}

.featured-excerpt {
    font-size: 1.1rem;
    color: #4B5563; /* Gray 600 */
    line-height: 1.7;
    margin-bottom: 30px;
}

.author-info {
    display: flex;
    align-items: center;
    gap: 15px;
    margin-bottom: 30px;
}

.author-avatar {
    width: 45px;
    height: 45px;
    border-radius: 50%;
    overflow: hidden;
    border: 2px solid #E5E7EB;
}

.author-avatar img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

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

.author-name {
    font-weight: 700;
    color: #111827;
    font-size: 0.95rem;
}

.author-role {
    font-size: 0.85rem;
    color: #6B7280;
}

.read-more-btn {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    color: #6D28D9;
    font-weight: 600;
    font-size: 1rem;
    text-decoration: none;
    transition: var(--transition);
}

.read-more-btn:hover {
    color: #4C1D95;
    transform: translateX(5px);
}

/* Blog Grid */
.blog-grid {
    padding: 80px 0;
    background: #FFFFFF;
}

.section-header {
    text-align: center;
    margin-bottom: 60px;
}

.section-title {
    font-size: 2.5rem;
    font-weight: 700;
    color: #111827;
    margin-bottom: 16px;
    font-family: 'Playfair Display', serif;
}

.section-subtitle {
    font-size: 1.1rem;
    color: #4B5563;
    max-width: 500px;
    margin: 0 auto;
}

.blog-posts-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(350px, 1fr));
    gap: 40px;
    margin-bottom: 60px;
}

.blog-post {
    background: #FFFFFF;
    border-radius: 20px;
    overflow: hidden;
    transition: var(--transition);
    border: 1px solid #E5E7EB;
    box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -1px rgba(0, 0, 0, 0.06);
}

.blog-post:hover {
    transform: translateY(-10px);
    box-shadow: 0 20px 25px -5px rgba(0, 0, 0, 0.1), 0 10px 10px -5px rgba(0, 0, 0, 0.04);
    border-color: #D1D5DB;
}

.post-image {
    position: relative;
    height: 220px;
    overflow: hidden;
}

.post-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.5s ease;
}

.blog-post:hover .post-image img {
    transform: scale(1.1);
}

.post-category {
    position: absolute;
    top: 15px;
    left: 15px;
    background: linear-gradient(135deg, #6D28D9 0%, #A855F7 100%);
    color: white;
    padding: 6px 12px;
    border-radius: 15px;
    font-size: 0.8rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.post-content {
    padding: 30px;
}

.post-meta {
    display: flex;
    gap: 15px;
    margin-bottom: 15px;
    font-size: 0.85rem;
    color: #6B7280;
}

.post-title {
    font-size: 1.25rem;
    font-weight: 700;
    margin-bottom: 12px;
    line-height: 1.4;
    font-family: 'Playfair Display', serif;
}

.post-title a {
    color: #111827;
    text-decoration: none;
    transition: var(--transition);
}

.post-title a:hover {
    color: #6D28D9;
}

.post-excerpt {
    font-size: 0.95rem;
    color: #4B5563;
    line-height: 1.6;
    margin-bottom: 20px;
    display: -webkit-box;
    -webkit-line-clamp: 3;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.post-footer {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding-top: 20px;
    border-top: 1px solid #F3F4F6;
}

.post-author {
    display: flex;
    align-items: center;
    gap: 10px;
}

.post-author img {
    width: 30px;
    height: 30px;
    border-radius: 50%;
    object-fit: cover;
}

.post-author span {
    font-size: 0.9rem;
    color: #111827;
    font-weight: 500;
}

.read-more {
    color: #6D28D9;
    font-weight: 600;
    text-decoration: none;
    font-size: 0.9rem;
    transition: var(--transition);
}

.read-more:hover {
    color: #4C1D95;
    text-decoration: underline;
}

/* Load More Section */
.load-more-section {
    text-align: center;
}

.load-more-btn {
    background: #FFFFFF;
    border: 2px solid #6D28D9;
    color: #6D28D9;
    padding: 15px 40px;
    border-radius: 30px;
    font-weight: 600;
    cursor: pointer;
    transition: var(--transition);
    display: inline-flex;
    align-items: center;
    gap: 10px;
}

.load-more-btn:hover {
    background: linear-gradient(135deg, #6D28D9 0%, #A855F7 100%);
    border-color: transparent;
    color: #FFFFFF;
    transform: translateY(-3px);
    box-shadow: 0 10px 25px rgba(109, 40, 217, 0.3);
}

.load-more-btn i {
    transition: transform 0.3s ease;
}

.load-more-btn:hover i {
    transform: translateY(3px);
}

/* Blog Newsletter */
.blog-newsletter {
    padding: 80px 0;
    background: linear-gradient(135deg, #1e1b4b 0%, #312e81 100%); /* Keep newsletter dark for contrast */
    position: relative;
    color: white;
}

.blog-newsletter::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: radial-gradient(circle at 30% 70%, rgba(139, 92, 246, 0.1) 0%, transparent 50%);
    pointer-events: none;
}

.newsletter-content {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 60px;
    align-items: center;
    position: relative;
    z-index: 2;
}

.newsletter-title {
    font-size: 2.5rem;
    font-weight: 700;
    color: #FFFFFF;
    margin-bottom: 20px;
    line-height: 1.3;
    font-family: 'Playfair Display', serif;
}

.newsletter-description {
    font-size: 1.1rem;
    color: #E5E7EB;
    line-height: 1.6;
}

.newsletter-form-wrapper {
    background: rgba(255, 255, 255, 0.1);
    padding: 40px;
    border-radius: 20px;
    border: 1px solid rgba(255, 255, 255, 0.1);
    backdrop-filter: blur(10px);
}

.newsletter-form {
    display: flex;
    gap: 10px;
    margin-bottom: 15px;
}

.newsletter-input {
    flex: 1;
    background: rgba(255, 255, 255, 0.1);
    border: 1px solid rgba(255, 255, 255, 0.2);
    color: #FFFFFF;
    padding: 15px 20px;
    border-radius: 30px;
    font-size: 1rem;
    outline: none;
    transition: var(--transition);
}

.newsletter-input:focus {
    background: rgba(255, 255, 255, 0.15);
    border-color: rgba(255, 255, 255, 0.4);
}

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

.newsletter-submit {
    background: #FFFFFF;
    color: #6D28D9;
    border: none;
    padding: 15px 30px;
    border-radius: 30px;
    font-weight: 700;
    cursor: pointer;
    transition: var(--transition);
    display: inline-flex;
    align-items: center;
    gap: 8px;
    white-space: nowrap;
}

.newsletter-submit:hover {
    background: #F3F4F6;
    transform: translateY(-2px);
    box-shadow: 0 10px 20px rgba(0, 0, 0, 0.2);
}

.newsletter-privacy {
    font-size: 0.85rem;
    color: #9CA3AF;
    display: flex;
    align-items: center;
    gap: 8px;
}

/* Responsive Styles */
@media (max-width: 991px) {
    .blog-hero-title {
        font-size: 2.8rem;
    }
    
    .featured-content,
    .newsletter-content {
        grid-template-columns: 1fr;
        gap: 40px;
    }
    
    .featured-image img {
        height: 300px;
    }
}

@media (max-width: 768px) {
    .blog-hero {
        padding: 100px 0 60px;
    }
    
    .blog-hero-title {
        font-size: 2.2rem;
    }
    
    .blog-stats {
        gap: 30px;
        flex-wrap: wrap;
    }
    
    .stat-number {
        font-size: 2rem;
    }
    
    .newsletter-form {
        flex-direction: column;
    }
    
    .newsletter-submit {
        width: 100%;
        justify-content: center;
    }
}
