/* Blog Page Styles */

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

.blog-hero h1 {
    font-size: 42px;
    font-weight: 700;
    color: var(--primary-dark);
    margin-bottom: 16px;
}

.blog-hero p {
    font-size: 18px;
    color: var(--text-light);
}

/* Blog Section */
.blog-section {
    padding: 60px 0 100px;
}

/* Blog Grid */
.blog-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 32px;
    margin-bottom: 60px;
}

/* Blog Card */
.blog-card {
    background: var(--white);
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.08);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.blog-card:hover {
    transform: translateY(-6px);
    box-shadow: 0 12px 40px rgba(0, 0, 0, 0.12);
}

.blog-image {
    width: 100%;
    height: 200px;
    overflow: hidden;
}

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

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

.blog-content {
    padding: 24px;
}

.blog-category {
    display: inline-block;
    padding: 4px 12px;
    background: var(--bg-light);
    color: var(--accent);
    font-size: 11px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    border-radius: 20px;
    margin-bottom: 12px;
}

.blog-content h2 {
    font-size: 18px;
    font-weight: 600;
    color: var(--primary-dark);
    line-height: 1.4;
    margin-bottom: 12px;
}

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

.blog-content h2 a {
    color: inherit;
    transition: color 0.2s;
}

.blog-content h2 a:hover {
    color: var(--accent);
}

.blog-meta {
    display: flex;
    gap: 8px;
    font-size: 13px;
    color: var(--text-light);
    margin-bottom: 12px;
}

.read-more {
    font-size: 14px;
    font-weight: 600;
    color: var(--accent);
    transition: color 0.2s;
}

.read-more:hover {
    color: var(--accent-light);
}

/* Newsletter Section */
.newsletter-section {
    padding: 80px 0;
    background: var(--bg-light);
}

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

.newsletter-content h2 {
    font-size: 28px;
    color: var(--primary-dark);
    margin-bottom: 12px;
}

.newsletter-content p {
    color: var(--text-light);
    margin-bottom: 24px;
}

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

.newsletter-form input {
    flex: 1;
    padding: 14px 18px;
    border: 1px solid var(--border);
    border-radius: 8px;
    font-size: 15px;
    font-family: inherit;
}

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

/* Pagination */
.pagination {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 8px;
}

.page-num {
    width: 40px;
    height: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 8px;
    font-size: 14px;
    font-weight: 500;
    color: var(--text);
    background: var(--bg-light);
    cursor: pointer;
    transition: all 0.2s;
}

.page-num:hover {
    background: var(--bg-alt);
}

.page-num.active {
    background: var(--accent);
    color: var(--white);
}

.page-next {
    padding: 10px 20px;
    font-size: 14px;
    font-weight: 500;
    color: var(--accent);
    cursor: pointer;
    transition: color 0.2s;
}

.page-next:hover {
    color: var(--accent-light);
}

/* Blog Article Page */
.blog-article {
    padding: 120px 0 80px;
}

.blog-article .container {
    max-width: 800px;
}

.article-header {
    margin-bottom: 40px;
}

.back-link {
    display: inline-block;
    font-size: 14px;
    color: var(--accent);
    margin-bottom: 24px;
    transition: color 0.2s;
}

.back-link:hover {
    color: var(--accent-light);
}

.article-category {
    display: inline-block;
    padding: 6px 14px;
    background: var(--bg-light);
    color: var(--accent);
    font-size: 12px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    border-radius: 20px;
    margin-bottom: 16px;
}

.article-header h1 {
    font-size: 40px;
    font-weight: 700;
    color: var(--primary-dark);
    line-height: 1.25;
    margin-bottom: 16px;
}

.article-meta {
    display: flex;
    gap: 12px;
    font-size: 14px;
    color: var(--text-light);
}

.article-image {
    margin-bottom: 40px;
    border-radius: 12px;
    overflow: hidden;
}

.article-image img {
    width: 100%;
    height: auto;
}

.article-content {
    font-size: 17px;
    line-height: 1.8;
    color: var(--text);
}

.article-content .intro {
    font-size: 20px;
    color: var(--text-dark);
    line-height: 1.7;
    margin-bottom: 32px;
}

.article-content h2 {
    font-size: 26px;
    font-weight: 600;
    color: var(--primary-dark);
    margin: 40px 0 20px;
}

.article-content p {
    margin-bottom: 20px;
}

.article-content ul {
    margin: 0 0 24px 0;
    padding-left: 24px;
}

.article-content ul li {
    margin-bottom: 12px;
}

.article-content strong {
    color: var(--text-dark);
}

/* Info Box */
.info-box {
    display: flex;
    gap: 24px;
    padding: 24px;
    background: var(--bg-light);
    border-radius: 12px;
    margin: 24px 0;
}

.info-item {
    flex: 1;
    text-align: center;
}

.info-label {
    display: block;
    font-size: 14px;
    color: var(--text-light);
    margin-bottom: 8px;
}

.info-value {
    display: block;
    font-size: 32px;
    font-weight: 700;
    color: var(--accent);
}

.info-desc {
    display: block;
    font-size: 13px;
    color: var(--text-light);
}

/* Content Table */
.content-table {
    width: 100%;
    border-collapse: collapse;
    margin: 24px 0;
    font-size: 15px;
}

.content-table th,
.content-table td {
    padding: 14px 16px;
    text-align: left;
    border-bottom: 1px solid var(--border);
}

.content-table th {
    background: var(--bg-light);
    font-weight: 600;
    color: var(--primary-dark);
    font-size: 13px;
    text-transform: uppercase;
    letter-spacing: 0.3px;
}

.content-table td {
    color: var(--text);
}

/* Risk Badges */
.risk-badge {
    display: inline-block;
    padding: 4px 10px;
    border-radius: 12px;
    font-size: 12px;
    font-weight: 600;
}

.risk-badge.high {
    background: #fee2e2;
    color: #dc2626;
}

.risk-badge.medium {
    background: #fef3c7;
    color: #d97706;
}

.risk-badge.low {
    background: #d1fae5;
    color: #059669;
}

/* Status Badges in Articles */
.status-badge.normal { background: #d1fae5; color: #059669; }
.status-badge.warning { background: #fef3c7; color: #d97706; }
.status-badge.critical { background: #fee2e2; color: #dc2626; }
.status-badge.violation { background: #fecaca; color: #b91c1c; }

/* Checklist */
.checklist {
    background: var(--bg-light);
    border-radius: 12px;
    padding: 24px;
    margin: 24px 0;
}

.checklist-item {
    display: flex;
    align-items: flex-start;
    gap: 12px;
    padding: 10px 0;
    border-bottom: 1px solid var(--border);
    font-size: 15px;
}

.checklist-item:last-child {
    border-bottom: none;
}

.checklist-item .check {
    color: var(--accent);
    font-weight: 700;
    font-size: 16px;
}

/* Warning Box */
.warning-box {
    display: flex;
    gap: 16px;
    padding: 20px;
    background: #fef2f2;
    border-left: 4px solid #ef4444;
    border-radius: 8px;
    margin: 24px 0;
}

.warning-icon {
    font-size: 24px;
}

.warning-box strong {
    display: block;
    color: #b91c1c;
    margin-bottom: 4px;
}

.warning-box p {
    margin: 0;
    font-size: 14px;
    color: #991b1b;
}

/* Flow Diagram */
.flow-diagram {
    margin: 24px 0;
}

.flow-step {
    display: flex;
    gap: 20px;
    padding: 20px 0;
    border-bottom: 1px solid var(--border);
}

.flow-step:last-child {
    border-bottom: none;
}

.flow-num {
    width: 36px;
    height: 36px;
    background: var(--accent);
    color: var(--white);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 600;
    flex-shrink: 0;
}

.flow-content strong {
    display: block;
    color: var(--primary-dark);
    margin-bottom: 4px;
}

.flow-content p {
    margin: 0;
    font-size: 15px;
    color: var(--text-light);
}

/* Compare Box */
.compare-box {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 20px;
    margin: 24px 0;
}

.compare-item {
    padding: 24px;
    border-radius: 12px;
}

.compare-item.reactive {
    background: #fef2f2;
}

.compare-item.preventive {
    background: #ecfdf5;
}

.compare-item h4 {
    font-size: 16px;
    margin-bottom: 16px;
    color: var(--primary-dark);
}

.compare-item ul {
    padding-left: 20px;
    margin: 0;
}

.compare-item li {
    font-size: 14px;
    margin-bottom: 8px;
}

/* Formula Box */
.formula-box {
    background: var(--bg-light);
    padding: 20px;
    border-radius: 8px;
    text-align: center;
    margin: 24px 0;
}

.formula {
    font-family: monospace;
    font-size: 16px;
    color: var(--primary-dark);
}

/* Stats Row */
.stats-row {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 20px;
    margin: 24px 0;
}

.stat-item {
    text-align: center;
    padding: 24px;
    background: var(--bg-light);
    border-radius: 12px;
}

.stat-value {
    display: block;
    font-size: 36px;
    font-weight: 700;
    color: var(--accent);
    margin-bottom: 8px;
}

.stat-desc {
    font-size: 14px;
    color: var(--text-light);
}

/* CTA Box */
.cta-box {
    background: linear-gradient(135deg, var(--primary-dark) 0%, #312e81 100%);
    padding: 40px;
    border-radius: 16px;
    text-align: center;
    margin-top: 48px;
}

.cta-box h3 {
    font-size: 24px;
    color: var(--white);
    margin-bottom: 12px;
}

.cta-box p {
    color: rgba(255, 255, 255, 0.7);
    margin-bottom: 24px;
}

/* Responsive */
@media (max-width: 1024px) {
    .blog-grid {
        grid-template-columns: repeat(2, 1fr);
    }

    .compare-box {
        grid-template-columns: 1fr;
    }

    .stats-row {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 640px) {
    .blog-hero {
        padding: 120px 0 40px;
    }

    .blog-hero h1 {
        font-size: 32px;
    }

    .blog-grid {
        grid-template-columns: 1fr;
        gap: 24px;
    }

    .blog-content h2 {
        font-size: 16px;
    }

    .article-header h1 {
        font-size: 28px;
    }

    .article-content {
        font-size: 16px;
    }

    .article-content .intro {
        font-size: 18px;
    }

    .info-box {
        flex-direction: column;
    }
}
