/* Blog Styles */

/* Font faces - required for header/nav rendering */
@font-face {
    font-family: "Poppins-Regular";
    src: url("../fonts/poppins/Poppins-Regular.ttf");
}
@font-face {
    font-family: "Poppins-Medium";
    src: url("../fonts/poppins/Poppins-Medium.ttf");
}

/* Blog Header */
.blog-header {
    background: linear-gradient(135deg, #1a1a2e 0%, #16213e 50%, #0f3460 100%);
    color: #fff;
    padding: 160px 0 60px;
    text-align: center;
}

.blog-header h1 {
    font-family: "Poppins-Medium", "Poppins", sans-serif;
    font-size: 42px;
    font-weight: 700;
    margin-bottom: 12px;
}

.blog-header__subtitle {
    font-size: 18px;
    color: rgba(255, 255, 255, 0.7);
}

/* Blog Index Grid */
.blog-list {
    padding: 60px 0 80px;
    background: #f8f9fa;
}

.blog-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(340px, 1fr));
    gap: 32px;
    max-width: 1100px;
    margin: 0 auto;
}

.blog-card {
    background: #fff;
    border-radius: 12px;
    border: 1px solid #eee;
    text-decoration: none;
    color: inherit;
    transition: box-shadow 0.2s, transform 0.2s;
    overflow: hidden;
    display: flex;
    flex-direction: column;
}

.blog-card:hover {
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.08);
    transform: translateY(-2px);
}

.blog-card__content {
    padding: 28px;
    flex: 1;
    display: flex;
    flex-direction: column;
}

.blog-card__category {
    display: inline-block;
    font-size: 12px;
    text-transform: uppercase;
    letter-spacing: 1.5px;
    color: #e14b5f;
    font-weight: 600;
    margin-bottom: 12px;
}

.blog-card__title {
    font-family: "Poppins-Medium", "Poppins", sans-serif;
    font-size: 22px;
    font-weight: 600;
    color: #1a1a2e;
    line-height: 1.3;
    margin-bottom: 12px;
}

.blog-card__excerpt {
    font-size: 15px;
    line-height: 1.6;
    color: #555;
    flex: 1;
}

.blog-card__meta {
    display: flex;
    gap: 16px;
    font-size: 13px;
    color: #999;
    margin-top: 16px;
    padding-top: 16px;
    border-top: 1px solid #f0f0f0;
}

.blog-empty {
    text-align: center;
    color: #999;
    padding: 60px 0;
    font-size: 18px;
}

/* Blog Article */
.blog-article {
    padding: 140px 0 60px;
    background: #fff;
}

.blog-article__header {
    max-width: 760px;
    margin: 0 auto 40px;
}

.blog-article__back {
    display: inline-block;
    font-size: 14px;
    color: #e14b5f;
    text-decoration: none;
    margin-bottom: 20px;
    font-weight: 500;
}

.blog-article__back:hover {
    text-decoration: underline;
}

.blog-article__category {
    display: inline-block;
    font-size: 12px;
    text-transform: uppercase;
    letter-spacing: 1.5px;
    color: #e14b5f;
    font-weight: 600;
    margin-bottom: 16px;
}

.blog-article__header h1 {
    font-family: "Poppins-Medium", "Poppins", sans-serif;
    font-size: 38px;
    font-weight: 700;
    color: #1a1a2e;
    line-height: 1.2;
    margin-bottom: 16px;
}

.blog-article__meta {
    display: flex;
    gap: 16px;
    font-size: 14px;
    color: #999;
}

.blog-article__meta span::after {
    content: "\00b7";
    margin-left: 16px;
}

.blog-article__meta span:last-child::after {
    content: "";
}

/* Article Body - Markdown Content */
.blog-article__body {
    max-width: 760px;
    margin: 0 auto;
    font-size: 17px;
    line-height: 1.8;
    color: #333;
}

.blog-article__body h2 {
    font-family: "Poppins-Medium", "Poppins", sans-serif;
    font-size: 28px;
    font-weight: 600;
    color: #1a1a2e;
    margin-top: 48px;
    margin-bottom: 16px;
}

.blog-article__body h3 {
    font-family: "Poppins-Medium", "Poppins", sans-serif;
    font-size: 22px;
    font-weight: 600;
    color: #1a1a2e;
    margin-top: 36px;
    margin-bottom: 12px;
}

.blog-article__body p {
    margin-bottom: 20px;
}

.blog-article__body a {
    color: #e14b5f;
    text-decoration: underline;
}

.blog-article__body ul,
.blog-article__body ol {
    margin-bottom: 20px;
    padding-left: 24px;
}

.blog-article__body li {
    margin-bottom: 8px;
}

.blog-article__body table {
    width: 100%;
    border-collapse: collapse;
    margin: 24px 0;
    font-size: 15px;
    display: block;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
}

/* Prevent horizontal page overflow on mobile */
html, body {
    overflow-x: hidden;
    max-width: 100vw;
}

.blog-article__body table th {
    background: #1a1a2e;
    color: #fff;
    padding: 12px 16px;
    text-align: left;
    font-weight: 600;
}

.blog-article__body table td {
    padding: 12px 16px;
    border-bottom: 1px solid #eee;
}

.blog-article__body table tr:nth-child(even) {
    background: #f8f9fa;
}

.blog-article__body blockquote {
    border-left: 4px solid #e14b5f;
    margin: 24px 0;
    padding: 16px 24px;
    background: #fef2f2;
    color: #333;
    font-style: italic;
}

.blog-article__body strong {
    font-weight: 600;
    color: #1a1a2e;
}

/* Article CTA */
.blog-article__cta {
    max-width: 760px;
    margin: 48px auto 0;
    padding: 48px 40px;
    background: linear-gradient(135deg, #1a1a2e 0%, #0f3460 100%);
    border-radius: 16px;
    color: #fff;
    text-align: center;
}

.blog-cta__logo {
    border-radius: 14px;
    margin-bottom: 20px;
}

.blog-article__cta h3 {
    font-family: "Poppins-Medium", "Poppins", sans-serif;
    font-size: 24px;
    font-weight: 700;
    margin-bottom: 12px;
    color: #fff;
}

.blog-article__cta p {
    font-size: 16px;
    color: rgba(255, 255, 255, 0.8);
    margin-bottom: 28px;
}

.blog-article__cta-buttons {
    display: flex;
    gap: 16px;
    justify-content: center;
    flex-wrap: wrap;
}

.blog-cta__btn {
    display: inline-block;
    padding: 14px 32px;
    border-radius: 8px;
    font-size: 16px;
    font-weight: 600;
    text-decoration: none;
    transition: all 0.2s ease;
    cursor: pointer;
    text-align: center;
}

.blog-cta__btn--primary {
    background: #e14b5f;
    color: #fff;
    border: 2px solid #e14b5f;
}

.blog-cta__btn--primary:hover {
    background: #c9384d;
    border-color: #c9384d;
}

.blog-cta__btn--outline {
    background: transparent;
    color: #fff;
    border: 2px solid rgba(255, 255, 255, 0.3);
}

.blog-cta__btn--outline:hover {
    border-color: #fff;
}

/* Responsive */
@media (max-width: 768px) {
    .blog-header {
        padding: 120px 0 40px;
    }

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

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

    .blog-article {
        padding: 120px 0 40px;
    }

    .blog-article__header h1 {
        font-size: 28px;
    }

    .blog-article__body {
        font-size: 16px;
    }

    .blog-article__cta {
        padding: 24px;
    }
}
