/* ===== GRID WRAPPER ===== */
.cbg-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 25px;

    /* ✅ Fix: add space from screen edges */
    padding: 0 40px;
    max-width: 1400px;
    margin: 0 auto;
    margin-top: 60px;
    margin-bottom: 40px;
}

/* ===== CARD ===== */
.cbg-card {
    background: #fff;
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 4px 18px rgba(0, 0, 0, 0.08);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    display: flex;
    flex-direction: column;
    height: 100%;
}

.cbg-card:hover {
    transform: translateY(-6px);
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.12);
}

/* ===== IMAGE ===== */
.cbg-image img {
    width: 100%;
    height: 200px;
    object-fit: cover;
    display: block;
}

/* ===== CONTENT ===== */
.cbg-content {
    padding: 18px;
    display: flex;
    flex-direction: column;
    flex-grow: 1;
}

/* ===== TITLE ===== */
.cbg-title {
    font-size: 18px;
    margin-bottom: 10px;
    line-height: 1.4;
}

.cbg-title a {
    text-decoration: none;
    color: #222;
}

.cbg-title a:hover {
    color: #050029;
}

/* ===== EXCERPT ===== */
.cbg-excerpt {
    font-size: 14px;
    color: #666;
    margin-bottom: 15px;
}

/* ===== BUTTON ===== */
.cbg-button {
    display: inline-block;
    padding: 8px 16px;
    background: #080137;
    /* ✅ Your color */
    color: #fff;
    border-radius: 6px;
    text-decoration: none;
    font-size: 14px;
    transition: background 0.3s ease;

    /* keeps button aligned bottom */
    margin-top: auto;
}

.cbg-button:hover {
    background: #140a5a;
}

/* ===== TABLET ===== */
@media (max-width: 1024px) {
    .cbg-grid {
        grid-template-columns: repeat(2, 1fr);
        padding: 0 25px;
    }
}

/* ===== MOBILE ===== */
@media (max-width: 768px) {
    .cbg-grid {
        grid-template-columns: 1fr;
        padding: 0 15px;
    }

    .cbg-image img {
        height: 180px;
    }
}