/* Minimal blog styles */

.main-container {
    max-width: 1400px;
    margin: 0 auto;
    padding: 30px 20px;
    background: linear-gradient(135deg, rgba(19, 53, 82, 0.4) 0%, rgba(11, 15, 27, 0.6) 100%);
    border: 1px solid rgba(83, 195, 255, 0.2);
    border-radius: 16px;
    margin-bottom: 40px;
}

/* Hero adjustments: larger title, smaller overall container, centered description */
.hero-section {
    max-width: 880px;
    margin: 0 auto 20px;
    text-align: center;
}

.hero-section .highlight-title {
    font-size: 3rem;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
    margin-bottom: 12px;
    letter-spacing: 1px;
}

/* Use WMCT_One for the main hero title on the blog page */
.blog-page .main-container .highlight-title {
    font-family: 'WMCT_One', sans-serif;
}

.hero-section p {
    margin: 0 auto;
    text-align: center;
    font-size: 1.1rem;
    max-width: 720px;
}

/* Fade transition for search/filter updates */
.blog-cards {
    transition: opacity 0.18s ease;
}

.blog-cards--fading {
    opacity: 0;
}

/* enlarge the visible post count */
#postCount {
    font-size: 1.6rem;
    font-weight: 800;
    color: #4c84b6;
}

/* Clear button: match player-popup-close appearance */
.btn-clear {
    /* Match projects modal action button */
    background: #162431;
    border: 1px solid #233549;
    color: #4da6ff;
    padding: 8px 12px;
    border-radius: 6px;
    cursor: pointer;
    font-family: "Blogger", sans-serif;
    font-size: 0.9rem;
    font-weight: 600;
}

.btn-clear:hover {
    background: #1c2e3f;
    border-color: #4da6ff;
}

/* Subtle blue tint for the search input */
#postSearch {
    background: rgba(76, 132, 182, 0.06) !important;
    border: 1px solid rgba(76, 132, 182, 0.12) !important;
    color: #dfeffc !important;
    box-shadow: 0 0 0 4px rgba(76, 132, 182, 0.03);
    transition: box-shadow .18s ease, background .12s ease;
}

#postSearch:focus {
    outline: none;
    background: rgba(76, 132, 182, 0.08) !important;
    box-shadow: 0 0 0 6px rgba(76, 132, 182, 0.12);
}

#postSearch::placeholder {
    color: rgba(223, 239, 252, 0.6);
}

.btn-clear.pulse {
    animation: popup-pulse 2.6s infinite ease-in-out;
}

/* ── Grid wrapper ───────────────────────────────────────────── */
.blog-grid-wrap {
    width: 100%;
    max-width: 1400px;
    margin: 0 auto;
    padding: 0 40px;
    box-sizing: border-box;
}

@media (max-width: 900px) {
    .main-container {
        margin-left: 12px;
        margin-right: 12px;
        padding: 20px 16px;
        box-sizing: border-box;
    }

    .blog-grid-wrap {
        padding: 0 16px;
    }
}

/* Blog-page specific title hero (scoped to avoid affecting other pages) */
.blog-page .page-title-container {
    max-width: 1100px;
    margin: 0 auto 18px auto;
    padding: 28px 30px;
    border-radius: 12px;
    background: linear-gradient(180deg, rgba(255, 255, 255, 0.02), rgba(255, 255, 255, 0.01));
    border: 1px solid rgba(83, 195, 255, 0.06);
    box-shadow: 0 14px 40px rgba(0, 0, 0, 0.55);
    text-align: center;
}

.blog-page .stat-title {
    font-size: 2.6rem;
    color: #ffea63;
    margin: 0;
    font-family: 'WMCT_One', sans-serif;
    letter-spacing: 1px;
    text-transform: none;
    line-height: 1.05;
    text-shadow: 0 0 8px rgba(255, 234, 99, 0.12);
}

/* Empty state — no post selected or search returns nothing */
/* Reuse inbox-style empty state for blog pages */
.empty-state {
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    height: 100%;
    padding: 40px;
    text-align: center;
}

.empty-state-icon {
    font-size: 3.5rem;
    color: rgba(159, 198, 255, 0.35);
    margin-bottom: 18px;
}

.empty-state-text {
    color: #9fb7c9;
    font-size: 1.05rem;
}


.btn-clear:active {
    transform: translateY(0);
}

.blog-page .hero-subtitle {
    font-family: 'Blogger', sans-serif;
    color: rgba(255, 255, 255, 0.78);
    font-size: 1.05rem;
    margin-top: 8px;
    letter-spacing: 0.6px;
}

@media (max-width: 900px) {
    .blog-page .page-title-container {
        padding: 18px;
    }

    .blog-page .stat-title {
        font-size: 1.9rem;
    }

    .blog-page .hero-subtitle {
        font-size: 0.95rem;
    }
}

/* Pulse animation used by popup-close and clear button */
@keyframes popup-pulse {
    0% {
        box-shadow: 0 6px 20px rgba(51, 160, 255, 0.06);
    }

    50% {
        box-shadow: 0 14px 36px rgba(51, 160, 255, 0.12);
    }

    100% {
        box-shadow: 0 6px 20px rgba(51, 160, 255, 0.06);
    }
}

/* =====================================================
   Blog list card - horizontal thumbnail layout (2026)
   ===================================================== */

/* Force single-column flex list, overriding earlier grid rules */
.blog-cards {
    display: flex;
    flex-direction: column;
    gap: 16px;
}

/* Base card: column layout — top row has thumb + title, body has excerpt + meta */
.blog-cards .post-card {
    display: flex;
    flex-direction: column;
    aspect-ratio: unset;
    padding: 0;
    background: rgba(10, 18, 32, 0.7);
    border: 1px solid rgba(83, 195, 255, 0.25);
    border-left: 4px solid rgba(77, 166, 255, 0.6);
    border-radius: 10px;
    overflow: hidden;
    width: 100%;
    cursor: pointer;
    transition: transform .15s ease, box-shadow .15s ease, border-left-color .15s ease, background .15s ease;
}

.blog-cards .post-card:hover {
    transform: translateY(-3px);
    box-shadow: 0 10px 32px rgba(0, 0, 0, 0.55);
    border-left-color: rgba(77, 166, 255, 1);
    background: rgba(14, 25, 44, 0.85);
}

/* Top row: small square thumbnail + title side by side */
.blog-cards .post-card .post-card-top {
    display: flex;
    flex-direction: row;
    align-items: center;
    gap: 14px;
    padding: 14px 16px 10px;
}

/* Thumbnail panel */
.blog-cards .post-card .post-thumb {
    flex: 0 0 220px;
    width: 220px;
    aspect-ratio: 16 / 9;
    border-radius: 8px;
    overflow: hidden;
    background: #0d1828;
}

.blog-cards .post-card .post-thumb img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: center;
    background-color: #0d1828;
    display: block;
}

/* Title — fills remaining space in the top row */
.blog-cards .post-card .post-title {
    flex: 1;
    font-family: "Blogger", sans-serif;
    font-size: 3rem;
    color: #ffea63;
    text-align: left;
    margin: 0;
    line-height: 1.3;
}

/* Body: excerpt + meta below the top row */
.blog-cards .post-card .post-card-body {
    flex: 1;
    padding: 0 16px 14px;
    display: flex;
    flex-direction: column;
    gap: 8px;
    align-items: flex-start;
    text-align: left;
    overflow: hidden;
}

.blog-cards .post-card .post-excerpt {
    text-align: left;
    flex: 1;
    font-family: "Blogger", sans-serif;
    color: #c8d8e8;
    font-size: 1rem;
    margin: 0;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.blog-cards .post-card .post-meta-row {
    position: static;
    margin-top: auto;
    justify-content: flex-start;
    padding-bottom: 0;
    gap: 10px;
    font-size: 0.82rem;
    color: #7a93a8;
}

/* Extra-small phones: tighter side spacing */
@media (max-width: 480px) {
    .main-container {
        padding: 16px 12px;
    }

    .blog-grid-wrap {
        padding: 0 12px;
    }

    .blog-page .page-title-container {
        padding: 18px 14px;
    }

    .blog-page .stat-title {
        font-size: 1.8rem;
    }
}

/* Compact adjustments on small screens */
@media (max-width: 600px) {
    .blog-cards {
        gap: 10px;
    }

    .blog-cards .post-card .post-card-top {
        padding: 10px 12px 8px;
        gap: 10px;
    }

    .blog-cards .post-card .post-thumb {
        flex: 0 0 80px;
        width: 80px;
        aspect-ratio: 14 / 9;
    }

    .blog-cards .post-card .post-title {
        font-size: 1.3rem;
    }

    .blog-cards .post-card .post-card-body {
        padding: 0 12px 10px;
        gap: 6px;
    }

    .blog-cards .post-card .post-excerpt {
        font-size: 0.82rem;
    }

    .blog-cards .post-card .post-meta-row {
        font-size: 0.75rem;
    }

    .blog-page .stat-title {
        font-size: clamp(1.1rem, 4vw, 1.5rem);
    }

    .main-container {
        padding: 14px 12px;
    }

    .hero-section .highlight-title {
        font-size: clamp(1.3rem, 5vw, 2rem);
    }
}