/*
 * category-insights.css
 * Styles for the dynamic blog section on category pages.
 * Existing blog card styles (.media-clm, .media-hd, etc.) live in style.css.
 * This file only adds the grid wrapper, loader, empty/error, and load-more styles.
 */

/* ── Section wrapper ───────────────────────────────────────────────────────── */
.section-category-insights {
    padding-bottom: 60px;
}

/* ── Grid view: ≤ 3 posts (no carousel) ─────────────────────────────────────── */
#category-blog-grid.as-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 24px;
    margin-top: 40px;
    text-align: left;
}

@media (max-width: 991px) {
    #category-blog-grid.as-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 575px) {
    #category-blog-grid.as-grid {
        grid-template-columns: 1fr;
        gap: 20px;
    }
}

/* ── Card: consistent height inside both grid and carousel ───────────────────── */
.category-blog-item {
    display: flex;
    flex-direction: column;
}

.category-blog-item .media-clm {
    display: flex;
    flex-direction: column;
    height: 100%;
	text-align: left;
}

.category-blog-item .media-content {
    flex: 1;
    display: flex;
    flex-direction: column;
}

/* Push "Know More" to the bottom of the card */
.category-blog-item .btn-wrap {
    margin-top: auto;
    padding-top: 16px;
}

/* ── Carousel nav arrow wrapper ──────────────────────────────────────────────── */
.category-slider-wrap {
    position: relative;
    margin-top: 40px;
}

/* ── Loading spinner ─────────────────────────────────────────────────────────── */
#category-blog-loading {
    text-align: center;
    padding: 50px 20px;
}

.blog-loader {
    display: inline-block;
    width: 44px;
    height: 44px;
    border: 3px solid rgba(0, 0, 0, 0.1);
    border-top-color: #555;
    border-radius: 50%;
    animation: blog-spin 0.7s linear infinite;
}

@keyframes blog-spin {
    to { transform: rotate(360deg); }
}

/* ── Empty state ─────────────────────────────────────────────────────────────── */
#category-blog-empty {
    text-align: center;
    padding: 60px 20px;
    color: #888;
    font-size: 16px;
}

/* ── Error state ─────────────────────────────────────────────────────────────── */
#category-blog-error {
    text-align: center;
    padding: 40px 20px;
    color: #c0392b;
    font-size: 15px;
}

/* ── Load More button ────────────────────────────────────────────────────────── */
#category-blog-loadmore-wrap {
    text-align: center;
    margin-top: 44px;
}

.load-more-btn {
    display: inline-block;
    background: transparent;
    border: 2px solid #333;
    color: #333;
    padding: 13px 44px;
    font-size: 13px;
    font-family: inherit;
    font-weight: 600;
    letter-spacing: 1.5px;
    text-transform: uppercase;
    cursor: pointer;
    border-radius: 2px;
    transition: background 0.25s, color 0.25s;
}
.inside-blog-section {
    border-top: 1px solid #eee;
}
.load-more-btn:hover,
.load-more-btn:focus {
    background: #333;
    color: #fff;
    outline: none;
}

.load-more-btn:disabled {
    opacity: 0.5;
    cursor: not-allowed;
}
