/* ---- CARD BASE ---- */
.cluster-card {
    position: relative;
    height: 50vh; /* you can adjust this */
    border-radius: 0.7rem;
    overflow: hidden;
    cursor: pointer;
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.cluster-card:hover {
    transform: scale(1.02);
    box-shadow: 0 6px 18px rgba(0, 0, 0, 0.5);
}

/* ---- BACKGROUND ---- */
.cluster-card-bg {
    position: absolute;
    inset: 0;
    background-size: cover;
    background-position: center;
    filter: brightness(0.6);
    transition: filter 0.3s ease;
}

.cluster-card:hover .cluster-card-bg {
    filter: brightness(0.8);
}

.cluster-card-gradient {
    background: var(--secondary-lighter-color);
}

/* ---- CONTENT ---- */
.cluster-card-content {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    padding: 1rem;
    color: #fff;

    /* Gradient background: solid black at bottom → transparent at top */
    background: linear-gradient(
        to top,
        rgba(0, 0, 0, 0.918) 0%,
        rgba(0, 0, 0, 0.8) 60%,
        rgba(0, 0, 0, 0) 100%
    );
    padding-top: 50px;
}

.cluster-card-content-container {
    display: flex;
    width: 100%;
    height: 100%;
}

.cluster-card-content p {
    margin: 0;
    line-height: 1.4;
}

/* ---- RESPONSIVE ---- */
@media (max-width: 768px) {
    .cluster-card {
        display: flex;
        flex-direction: row;
        position: relative;
        overflow: hidden;
        height: 180px;
    }

    .cluster-card-bg {
        flex: 1;
        background-size: cover;
        background-position: center;
        z-index: 0;
    }

    .cluster-card-content-container {
        flex: 0 0 55%; /* right 55% of the card */
        display: flex;
        align-items: center;
        justify-content: flex-start;
        z-index: 1;
        background: linear-gradient(
            to right,
            rgba(0, 0, 0, 0.85) 0%,
            rgba(0, 0, 0, 0.6) 40%,
            rgba(0, 0, 0, 0) 100%
        );
    }

    .cluster-card-content {
        padding: 1rem;
        width: 100%;
        color: #fff;
    }

    .cluster-card-content p {
        text-align: left;
        margin: 0;
    }
}