/* =========================================
   CrescentSoft Blog Article Styles
   Modern, Clean, Professional Design
   ========================================= */

/* ===== Blog Header ===== */
.blog-header {
    background: linear-gradient(135deg, #0f0f1a 0%, #1a1a2e 50%, #16213e 100%);
    padding: 140px 0 80px;
    text-align: center;
    position: relative;
    overflow: hidden;
}

.blog-header::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background:
        radial-gradient(circle at 20% 50%, rgba(0, 212, 255, 0.1) 0%, transparent 50%),
        radial-gradient(circle at 80% 50%, rgba(124, 58, 237, 0.1) 0%, transparent 50%);
    pointer-events: none;
}

.blog-header .container {
    position: relative;
    z-index: 1;
}

.blog-category {
    display: inline-block;
    background: linear-gradient(135deg, var(--primary) 0%, var(--secondary) 100%);
    color: white;
    padding: 8px 20px;
    border-radius: 50px;
    font-size: 0.85rem;
    font-weight: 600;
    margin-bottom: 1.5rem;
    letter-spacing: 0.5px;
    text-transform: uppercase;
}

.blog-title {
    font-size: clamp(2rem, 5vw, 3rem);
    line-height: 1.2;
    margin-bottom: 1.5rem;
    color: white;
    max-width: 900px;
    margin-left: auto;
    margin-right: auto;
    font-weight: 800;
}

.blog-meta {
    color: rgba(255, 255, 255, 0.7);
    font-size: 0.95rem;
    display: flex;
    gap: 2rem;
    justify-content: center;
    flex-wrap: wrap;
    margin-top: 1rem;
}

.blog-meta span {
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.blog-meta svg {
    opacity: 0.7;
}

/* ===== Featured Image - Below Header ===== */
.blog-featured-image {
    width: 100%;
    max-width: 900px;
    margin: 0 auto;
    padding: 40px 20px;
    background: white;
}

.blog-featured-image picture {
    display: block;
}

.blog-featured-image img {
    width: 100%;
    max-height: 400px;
    object-fit: cover;
    object-position: center;
    display: block;
    border-radius: 16px;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.15);
}

/* ===== Blog Article Container ===== */
.blog-article {
    max-width: 800px;
    margin: 0 auto;
    padding: 60px 20px;
}

/* ===== Back Link ===== */
.back-link {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    color: var(--primary);
    font-weight: 600;
    font-size: 0.95rem;
    margin-bottom: 2.5rem;
    text-decoration: none;
    padding: 10px 20px;
    background: rgba(0, 212, 255, 0.08);
    border-radius: 50px;
    transition: all 0.3s ease;
    border: 1px solid rgba(0, 212, 255, 0.2);
}

.back-link:hover {
    background: rgba(0, 212, 255, 0.15);
    transform: translateX(-5px);
    border-color: rgba(0, 212, 255, 0.4);
}

.back-link svg {
    width: 18px;
    height: 18px;
    transition: transform 0.3s ease;
}

.back-link:hover svg {
    transform: translateX(-3px);
}

/* ===== Blog Content Typography ===== */
.blog-content {
    padding: 0;
}

.blog-content h2 {
    font-size: 1.75rem;
    margin: 3rem 0 1.25rem;
    color: var(--text-dark);
    font-weight: 700;
    position: relative;
    padding-left: 20px;
}

.blog-content h2::before {
    content: '';
    position: absolute;
    left: 0;
    top: 0;
    bottom: 0;
    width: 4px;
    background: linear-gradient(180deg, var(--primary), var(--secondary));
    border-radius: 4px;
}

.blog-content h3 {
    font-size: 1.35rem;
    margin: 2rem 0 1rem;
    color: var(--text-dark);
    font-weight: 600;
}

.blog-content p {
    color: #4a5568;
    line-height: 1.9;
    margin-bottom: 1.5rem;
    font-size: 1.1rem;
}

.blog-content ul,
.blog-content ol {
    margin: 1.5rem 0 2rem;
    padding-left: 0;
    list-style: none;
    color: #4a5568;
}

.blog-content li {
    margin-bottom: 1rem;
    line-height: 1.8;
    font-size: 1.05rem;
    padding-left: 2rem;
    position: relative;
}

.blog-content ul li::before {
    content: '';
    position: absolute;
    left: 0;
    top: 10px;
    width: 8px;
    height: 8px;
    background: linear-gradient(135deg, var(--primary), var(--secondary));
    border-radius: 50%;
}

.blog-content ol {
    counter-reset: list-counter;
}

.blog-content ol li::before {
    counter-increment: list-counter;
    content: counter(list-counter);
    position: absolute;
    left: 0;
    top: 0;
    width: 24px;
    height: 24px;
    background: linear-gradient(135deg, var(--primary), var(--secondary));
    border-radius: 50%;
    color: white;
    font-size: 0.75rem;
    font-weight: 700;
    display: flex;
    align-items: center;
    justify-content: center;
}

.blog-content blockquote {
    border-left: 4px solid var(--primary);
    padding: 1.5rem 2rem;
    margin: 2.5rem 0;
    background: linear-gradient(135deg, rgba(0, 212, 255, 0.05), rgba(124, 58, 237, 0.05));
    border-radius: 0 16px 16px 0;
    font-style: italic;
    color: var(--text-dark);
    font-size: 1.15rem;
    line-height: 1.7;
}

.blog-content a {
    color: var(--primary);
    text-decoration: none;
    font-weight: 500;
    border-bottom: 1px dashed var(--primary);
    transition: all 0.3s ease;
}

.blog-content a:hover {
    color: var(--secondary);
    border-bottom-color: var(--secondary);
}

/* ===== Warning/Tip Boxes ===== */
.warning-box {
    background: linear-gradient(135deg, #fff7e6, #fff3cd);
    border-left: 4px solid #f59e0b;
    padding: 1.5rem 2rem;
    margin: 2rem 0;
    border-radius: 0 16px 16px 0;
    color: #92400e;
}

.warning-box strong {
    color: #b45309;
}

.tip-box {
    background: linear-gradient(135deg, rgba(0, 212, 255, 0.08), rgba(124, 58, 237, 0.08));
    border-left: 4px solid var(--primary);
    padding: 1.5rem 2rem;
    margin: 2rem 0;
    border-radius: 0 16px 16px 0;
}

/* ===== Comparison Table ===== */
.comparison-table {
    width: 100%;
    border-collapse: separate;
    border-spacing: 0;
    margin: 2.5rem 0;
    font-size: 0.95rem;
    border-radius: 16px;
    overflow: hidden;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.08);
}

.comparison-table th,
.comparison-table td {
    padding: 16px 20px;
    text-align: left;
    border-bottom: 1px solid #e2e8f0;
}

.comparison-table th {
    background: linear-gradient(135deg, #0f0f1a, #1a1a2e);
    color: white;
    font-weight: 600;
}

.comparison-table tr:last-child td {
    border-bottom: none;
}

.comparison-table tr:nth-child(even) {
    background: #f8fafc;
}

.comparison-table tr:hover td {
    background: rgba(0, 212, 255, 0.05);
}

/* ===== Author Box - Modern Card ===== */
.author-box {
    display: flex;
    gap: 1.5rem;
    padding: 2rem;
    background: linear-gradient(135deg, #f8fafc, #f1f5f9);
    border-radius: 20px;
    margin: 4rem 0 3rem;
    align-items: center;
    border: 1px solid #e2e8f0;
    position: relative;
    overflow: hidden;
}

.author-box::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 4px;
    background: linear-gradient(90deg, var(--primary), var(--secondary));
}

.author-avatar {
    width: 80px;
    height: 80px;
    border-radius: 16px;
    background: linear-gradient(135deg, #1a1a2e, #0f0f1a);
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--primary);
    font-size: 1.75rem;
    font-weight: 800;
    flex-shrink: 0;
    border: 3px solid white;
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.15);
}

.author-info h4 {
    margin: 0 0 0.5rem;
    color: var(--text-dark);
    font-size: 1.15rem;
    font-weight: 700;
}

.author-info p {
    margin: 0;
    color: #64748b;
    font-size: 0.95rem;
    line-height: 1.6;
}

/* ===== FAQ Section ===== */
.faq-section {
    margin-top: 4rem;
    padding-top: 3rem;
    border-top: 2px solid #e2e8f0;
}

.faq-section h2 {
    text-align: center;
    margin-bottom: 2.5rem;
}

.faq-section h2::before {
    display: none;
}

.faq-item {
    margin-bottom: 1.5rem;
    padding: 1.5rem 2rem;
    background: #f8fafc;
    border-radius: 16px;
    border: 1px solid #e2e8f0;
    transition: all 0.3s ease;
}

.faq-item:hover {
    border-color: var(--primary);
    box-shadow: 0 4px 20px rgba(0, 212, 255, 0.1);
}

.faq-item h4 {
    color: var(--text-dark);
    margin: 0 0 0.75rem;
    font-weight: 600;
    font-size: 1.1rem;
}

.faq-item p {
    color: #64748b;
    margin: 0;
    font-size: 1rem;
    line-height: 1.7;
}

/* ===== View All Articles Button ===== */
.blog-content .btn-secondary {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 14px 28px;
    background: #f1f5f9;
    color: var(--text-dark) !important;
    border-radius: 50px;
    font-weight: 600;
    text-decoration: none;
    transition: all 0.3s ease;
    border: 1px solid #e2e8f0;
}

.blog-content .btn-secondary:hover {
    background: #e2e8f0;
    transform: translateY(-2px);
    border-bottom: 1px solid #e2e8f0;
    color: var(--text-dark) !important;
}

/* ===== Primary Button Override ===== */
.blog-content .btn-primary,
.blog-article .btn-primary,
a.btn-primary {
    color: white !important;
    text-decoration: none;
    border-bottom: none !important;
}

.blog-content .btn-primary:hover,
.blog-article .btn-primary:hover,
a.btn-primary:hover {
    color: white !important;
}

/* ===== Mobile Responsiveness ===== */
@media (max-width: 768px) {
    .blog-header {
        padding: 120px 0 60px;
    }

    .blog-title {
        font-size: 1.75rem;
        padding: 0 10px;
    }

    .blog-meta {
        gap: 1rem;
        font-size: 0.85rem;
    }

    .blog-featured-image {
        padding: 30px 15px;
    }

    .blog-article {
        padding: 40px 20px;
    }

    .blog-content h2 {
        font-size: 1.4rem;
        padding-left: 16px;
    }

    .blog-content p,
    .blog-content li {
        font-size: 1rem;
    }

    .author-box {
        flex-direction: column;
        text-align: center;
        padding: 2rem 1.5rem;
    }

    .author-avatar {
        margin: 0 auto;
    }

    .faq-item {
        padding: 1.25rem 1.5rem;
    }

    .back-link {
        padding: 8px 16px;
        font-size: 0.9rem;
    }
}

/* ===== Extra Small Devices ===== */
@media (max-width: 480px) {
    .blog-header {
        padding: 100px 0 50px;
    }

    .blog-title {
        font-size: 1.5rem;
    }

    .blog-category {
        font-size: 0.75rem;
        padding: 6px 14px;
    }

    .blog-article {
        padding: 30px 15px;
    }

    .blog-content h2 {
        font-size: 1.25rem;
    }
}