/**
 * Chargie Blog Showcase — front-page "Latest from the Blog" row.
 *
 * Scoped to .cbs-* and self-contained. Selectors are deliberately given (0,2,0)+
 * specificity (".cbs-section.cbs-section" for the root element, ".cbs-section .cbs-*"
 * for descendants) so they out-rank the Chargie front-page reset
 *   .chargie-modern-wrapper * { margin: 0; padding: 0 }   (in css/critical.min.css)
 *   .chargie-modern-wrapper a { ... }
 * which load AFTER this file and would otherwise strip the section/card padding
 * and override link colors (a single-class .cbs-x at (0,1,0) loses on source order).
 */

/* Root <section> — doubled class to beat ".chargie-modern-wrapper *" (0,1,0). */
.cbs-section.cbs-section {
    box-sizing: border-box;
    background: #f8fafc;
    margin: 0;
    padding: 4rem 1.5rem;
    font-family: inherit;
    color: #1a1a1a;
    text-align: left;
}
.cbs-section *,
.cbs-section *::before,
.cbs-section *::after { box-sizing: border-box; }

.cbs-section .cbs-inner {
    max-width: 1200px;
    margin: 0 auto;
}

.cbs-section .cbs-head {
    display: flex;
    align-items: baseline;
    justify-content: space-between;
    gap: 1rem;
    flex-wrap: wrap;
    margin: 0 0 2rem;
}
.cbs-section .cbs-title {
    margin: 0;
    font-size: 2rem;
    font-weight: 700;
    line-height: 1.2;
    color: #1e3a5f;
}
.cbs-section .cbs-viewall {
    font-size: 0.95rem;
    font-weight: 600;
    white-space: nowrap;
    color: #ff6b35;
    text-decoration: none;
}
.cbs-section .cbs-viewall:hover { color: #f7931e; }

.cbs-section .cbs-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 2rem;
}

.cbs-section .cbs-card {
    background: #ffffff;
    border-radius: 1.5rem;
    overflow: hidden;
    box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}
.cbs-section .cbs-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 20px 25px -5px rgba(0, 0, 0, 0.1);
}

.cbs-section .cbs-card-image {
    display: block;
    aspect-ratio: 16 / 10;
    overflow: hidden;
}
.cbs-section .cbs-card-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
    transition: transform 0.5s ease;
}
.cbs-section .cbs-card:hover .cbs-card-image img { transform: scale(1.05); }

.cbs-section .cbs-card-body { padding: 1.5rem; }

.cbs-section .cbs-meta {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 1rem;
    font-size: 0.875rem;
    color: #6b7280;
    margin: 0 0 0.5rem;
}
.cbs-section .cbs-cat {
    background: #1e3a5f;
    color: #ffffff;
    padding: 2px 10px;
    border-radius: 9999px;
    font-size: 0.75rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}
.cbs-section .cbs-read,
.cbs-section .cbs-meta time { white-space: nowrap; }

.cbs-section .cbs-card-title {
    font-size: 1.25rem;
    font-weight: 700;
    line-height: 1.3;
    margin: 0 0 0.5rem;
}
.cbs-section .cbs-card-title a {
    color: #1e3a5f;
    text-decoration: none;
}
.cbs-section .cbs-card-title a:hover { color: #ff6b35; }

.cbs-section .cbs-excerpt {
    font-size: 1rem;
    line-height: 1.6;
    color: #4a4a4a;
    margin: 0 0 1rem;
}

.cbs-section .cbs-readmore {
    display: inline-flex;
    align-items: center;
    font-size: 0.875rem;
    font-weight: 600;
    color: #ff6b35;
    text-decoration: none;
}
.cbs-section .cbs-readmore:hover { color: #f7931e; }

/* Tablet: 2 across */
@media (max-width: 900px) {
    .cbs-section .cbs-grid { grid-template-columns: repeat(2, 1fr); }
}

/* Mobile: single column */
@media (max-width: 600px) {
    .cbs-section.cbs-section { padding: 3rem 1rem; }
    .cbs-section .cbs-grid { grid-template-columns: 1fr; }
    .cbs-section .cbs-title { font-size: 1.6rem; }
}
