/* Blog Page Styles - Dark Theme */

/* Blog Hero */
.blog-hero {
    padding: 140px 0 80px;
    text-align: center;
    background: var(--bg-primary);
}

.blog-hero-content h1 {
    font-size: clamp(36px, 5vw, 56px);
    font-weight: 700;
    margin-bottom: 16px;
    background: linear-gradient(135deg, var(--accent-primary) 0%, var(--accent-secondary) 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.blog-hero-content p {
    font-size: 18px;
    color: var(--text-secondary);
    margin-bottom: 48px;
}

/* Category Pills */
.blog-categories {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
    justify-content: center;
    margin-top: 32px;
}

.category-pill {
    padding: 8px 20px;
    background: var(--bg-tertiary);
    border: 1px solid var(--border-color);
    border-radius: 24px;
    font-size: 14px;
    font-weight: 500;
    color: var(--text-secondary);
    cursor: pointer;
    transition: var(--transition);
}

.category-pill:hover {
    background: var(--bg-secondary);
    color: var(--text-primary);
    border-color: var(--text-tertiary);
}

.category-pill.active {
    background: linear-gradient(135deg, var(--accent-primary) 0%, var(--accent-secondary) 100%);
    color: white;
    border-color: transparent;
}

/* Featured Article */
.blog-featured {
    padding: 80px 0;
    background: var(--bg-secondary);
}

.featured-article {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 60px;
    align-items: center;
    background: var(--bg-tertiary);
    padding: 48px;
    border-radius: 20px;
    border: 1px solid var(--border-color);
    transition: var(--transition);
}

.featured-article:hover {
    transform: translateY(-4px);
    box-shadow: 0 12px 40px rgba(99, 102, 241, 0.15);
    border-color: var(--accent-primary);
}

.featured-badge {
    display: inline-block;
    padding: 6px 16px;
    background: linear-gradient(135deg, var(--accent-primary) 0%, var(--accent-secondary) 100%);
    color: white;
    border-radius: 20px;
    font-size: 12px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    margin-bottom: 24px;
}

.featured-content h2 {
    font-size: 32px;
    font-weight: 700;
    margin-bottom: 16px;
    color: var(--text-primary);
}

.featured-content p {
    font-size: 16px;
    color: var(--text-secondary);
    line-height: 1.7;
    margin-bottom: 24px;
}

.article-meta {
    display: flex;
    gap: 16px;
    flex-wrap: wrap;
    align-items: center;
    font-size: 14px;
    color: var(--text-tertiary);
    margin-bottom: 24px;
}

.article-meta .author {
    font-weight: 600;
    color: var(--text-secondary);
}

.article-meta .date,
.article-meta .read-time {
    color: var(--text-tertiary);
}

.featured-image {
    position: relative;
    overflow: hidden;
    border-radius: 16px;
}

.placeholder-img {
    width: 100%;
    padding-bottom: 66%;
    background: linear-gradient(135deg, rgba(99, 102, 241, 0.2) 0%, rgba(139, 92, 246, 0.2) 100%);
    border-radius: 12px;
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
}

.placeholder-img::before {
    content: '';
    position: absolute;
    inset: 0;
    background-image:
        radial-gradient(circle at 20% 50%, rgba(99, 102, 241, 0.3) 0%, transparent 50%),
        radial-gradient(circle at 80% 80%, rgba(139, 92, 246, 0.3) 0%, transparent 50%);
    animation: pulse 4s ease-in-out infinite;
}

.placeholder-img::after {
    content: '📊';
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    font-size: 48px;
    opacity: 0.4;
}

@keyframes pulse {
    0%, 100% { opacity: 0.6; }
    50% { opacity: 1; }
}

/* Different themed placeholder images */
.featured-image .placeholder-img::after {
    content: '🚀';
    font-size: 80px;
}

.blog-card:nth-child(1) .placeholder-img {
    background: linear-gradient(135deg, rgba(34, 197, 94, 0.2) 0%, rgba(16, 185, 129, 0.2) 100%);
}

.blog-card:nth-child(1) .placeholder-img::after {
    content: '⚡';
}

.blog-card:nth-child(2) .placeholder-img {
    background: linear-gradient(135deg, rgba(251, 146, 60, 0.2) 0%, rgba(249, 115, 22, 0.2) 100%);
}

.blog-card:nth-child(2) .placeholder-img::after {
    content: '💰';
}

.blog-card:nth-child(3) .placeholder-img {
    background: linear-gradient(135deg, rgba(236, 72, 153, 0.2) 0%, rgba(219, 39, 119, 0.2) 100%);
}

.blog-card:nth-child(3) .placeholder-img::after {
    content: '🌐';
}

.blog-card:nth-child(4) .placeholder-img {
    background: linear-gradient(135deg, rgba(147, 51, 234, 0.2) 0%, rgba(126, 34, 206, 0.2) 100%);
}

.blog-card:nth-child(4) .placeholder-img::after {
    content: '🤖';
}

.blog-card:nth-child(5) .placeholder-img {
    background: linear-gradient(135deg, rgba(59, 130, 246, 0.2) 0%, rgba(37, 99, 235, 0.2) 100%);
}

.blog-card:nth-child(5) .placeholder-img::after {
    content: '📧';
}

.blog-card:nth-child(6) .placeholder-img {
    background: linear-gradient(135deg, rgba(168, 85, 247, 0.2) 0%, rgba(147, 51, 234, 0.2) 100%);
}

.blog-card:nth-child(6) .placeholder-img::after {
    content: '📈';
}

/* Blog Grid */
.blog-grid {
    padding: 80px 0;
    background: var(--bg-primary);
}

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

.blog-card {
    background: var(--bg-tertiary);
    border-radius: 16px;
    border: 1px solid var(--border-color);
    overflow: hidden;
    transition: var(--transition);
    cursor: pointer;
}

.blog-card:hover {
    transform: translateY(-4px);
    border-color: var(--accent-primary);
    box-shadow: 0 12px 40px rgba(99, 102, 241, 0.15);
}

.blog-card.hidden {
    display: none;
}

.blog-card-image {
    position: relative;
    overflow: hidden;
}

.blog-card-image .placeholder-img {
    padding-bottom: 56%;
}

.blog-card-content {
    padding: 24px;
}

.category-badge {
    display: inline-block;
    padding: 4px 12px;
    background: rgba(99, 102, 241, 0.2);
    color: var(--accent-primary);
    border-radius: 12px;
    font-size: 12px;
    font-weight: 600;
    margin-bottom: 16px;
}

.blog-card h3 {
    font-size: 20px;
    font-weight: 600;
    margin-bottom: 12px;
    line-height: 1.4;
    color: var(--text-primary);
}

.blog-card p {
    font-size: 14px;
    color: var(--text-secondary);
    line-height: 1.6;
    margin-bottom: 16px;
}

.card-meta {
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-size: 13px;
    color: var(--text-tertiary);
    padding-top: 16px;
    border-top: 1px solid var(--border-color);
}

/* Newsletter CTA */
.newsletter-cta {
    padding: 100px 0;
    background: linear-gradient(135deg, rgba(99, 102, 241, 0.1) 0%, rgba(139, 92, 246, 0.1) 100%);
    border-top: 1px solid var(--border-color);
}

.newsletter-content {
    max-width: 600px;
    margin: 0 auto;
    text-align: center;
}

.newsletter-content h2 {
    font-size: clamp(28px, 4vw, 40px);
    font-weight: 700;
    margin-bottom: 16px;
}

.newsletter-content p {
    font-size: 16px;
    color: var(--text-secondary);
    margin-bottom: 32px;
}

.newsletter-form {
    display: flex;
    gap: 12px;
    margin-bottom: 16px;
}

.newsletter-form input {
    flex: 1;
    padding: 14px 20px;
    background: var(--bg-tertiary);
    border: 1px solid var(--border-color);
    border-radius: 8px;
    color: var(--text-primary);
    font-size: 15px;
    transition: var(--transition);
}

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

.newsletter-form input::placeholder {
    color: var(--text-tertiary);
}

.newsletter-form button {
    white-space: nowrap;
}

.newsletter-note {
    font-size: 13px;
    color: var(--text-tertiary);
}

/* Active nav link */
.nav-links a.active {
    color: var(--accent-primary);
}

/* Responsive - Mobile First Design */
@media (max-width: 768px) {
    /* Global consistency fixes */
    * {
        -webkit-font-smoothing: antialiased;
        -moz-osx-font-smoothing: grayscale;
    }

    /* Blog Hero */
    .blog-hero {
        padding: 100px 0 48px;
    }

    .blog-hero-content h1 {
        font-size: 32px;
        line-height: 1.2;
        margin-bottom: 12px;
    }

    .blog-hero-content p {
        font-size: 15px;
        line-height: 1.6;
        margin-bottom: 32px;
    }

    /* Category Pills - Horizontal Scroll */
    .blog-categories {
        padding: 0 16px;
        justify-content: flex-start;
        overflow-x: auto;
        -webkit-overflow-scrolling: touch;
        scrollbar-width: none;
    }

    .blog-categories::-webkit-scrollbar {
        display: none;
    }

    .category-pill {
        padding: 8px 16px;
        font-size: 13px;
        white-space: nowrap;
        flex-shrink: 0;
    }

    .category-pill:hover {
        transform: none;
    }

    /* Featured Article - Compact Card */
    .blog-featured {
        padding: 48px 0;
    }

    .featured-article {
        grid-template-columns: 1fr;
        padding: 0;
        gap: 0;
        border-radius: 12px;
        background: var(--bg-tertiary);
    }

    .featured-article:hover {
        transform: none;
    }

    .featured-image {
        order: -1;
        border-radius: 12px 12px 0 0;
    }

    .featured-content {
        padding: 18px;
    }

    .featured-badge {
        font-size: 10px;
        padding: 4px 12px;
        margin-bottom: 10px;
        display: inline-block;
    }

    .featured-content h2 {
        font-size: 20px;
        line-height: 1.3;
        margin-bottom: 8px;
        color: var(--text-primary);
    }

    .featured-content p {
        font-size: 14px;
        line-height: 1.6;
        margin-bottom: 14px;
    }

    .article-meta {
        font-size: 12px;
        gap: 10px;
        margin-bottom: 0;
        display: flex;
        align-items: center;
    }

    /* Blog Grid - Compact List */
    .blog-grid {
        padding: 48px 0;
    }

    .articles-grid {
        grid-template-columns: 1fr;
        gap: 12px;
    }

    .blog-card {
        border-radius: 12px;
        display: flex;
        flex-direction: row;
        align-items: stretch;
        overflow: hidden;
        min-height: 110px;
    }

    .blog-card:hover {
        transform: none;
    }

    .blog-card-image {
        flex-shrink: 0;
        width: 110px;
        border-radius: 12px 0 0 12px;
        overflow: hidden;
    }

    .blog-card-image .placeholder-img {
        padding-bottom: 0;
        height: 100%;
        width: 100%;
        border-radius: 12px 0 0 12px;
    }

    .blog-card-image .placeholder-img::after {
        font-size: 28px;
    }

    .blog-card-content {
        padding: 14px;
        flex: 1;
        min-width: 0;
        display: flex;
        flex-direction: column;
        justify-content: center;
    }

    .category-badge {
        font-size: 10px;
        padding: 3px 10px;
        margin-bottom: 6px;
        display: inline-block;
        align-self: flex-start;
    }

    .blog-card h3 {
        font-size: 15px;
        font-weight: 600;
        margin-bottom: 6px;
        line-height: 1.3;
        color: var(--text-primary);
    }

    .blog-card p {
        font-size: 13px;
        line-height: 1.5;
        margin-bottom: 10px;
        display: -webkit-box;
        -webkit-line-clamp: 2;
        -webkit-box-orient: vertical;
        overflow: hidden;
    }

    .card-meta {
        font-size: 11px;
        padding-top: 10px;
        flex-wrap: wrap;
        gap: 8px;
        margin-top: auto;
    }

    /* Newsletter CTA - Compact */
    .newsletter-cta {
        padding: 48px 0;
    }

    .newsletter-content h2 {
        font-size: 24px;
        line-height: 1.2;
        margin-bottom: 10px;
    }

    .newsletter-content p {
        font-size: 14px;
        margin-bottom: 24px;
    }

    .newsletter-form {
        flex-direction: column;
        gap: 10px;
    }

    .newsletter-form input {
        width: 100%;
        padding: 12px 16px;
        font-size: 14px;
    }

    .newsletter-form button {
        width: 100%;
        padding: 12px 20px;
    }

    .newsletter-note {
        font-size: 12px;
        margin-top: 12px;
    }
}
