/* Three Columns Grid */
.three-columns__grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 2rem;
    width: 100%;
}

/* Column wrapper */
.three-columns__col {
    display: flex;
    flex-direction: column;
    justify-content: flex-start;
    align-items: stretch;
}

/* Media wrapper for images/videos/iframes */
.three-columns__media {
    position: relative;
    width: 100%;
    padding-top: 56.25%; /* 16:9 aspect ratio */
    overflow: hidden;
    margin-bottom: 1rem;
    border-radius: 4px; /* optional */
}

/* Images, videos, iframes fill the wrapper */
.three-columns__media img,
.three-columns__media video,
.three-columns__media iframe {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    object-fit: cover; /* Crop if needed */
    border: 0;
}

/* Text content */
.three-columns__text {
    flex: 0 0 auto;
    margin-top: 0.5rem;
}

/* Tablet: 2 columns */
@media (max-width: 1024px) {
    .three-columns__grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

/* Mobile: 1 column */
@media (max-width: 640px) {
    .three-columns__grid {
        grid-template-columns: 1fr;
    }
}