/* The Pack Blocks – Post Grid (Latest News, Reviews, Video) */

/* Kop
–––––––––––––––––––––––––––––––––––––––––––––––––– */

.tpb-news__header {
    display: flex;
    flex-wrap: wrap;
    align-items: flex-end;
    justify-content: space-between;
    gap: 1rem 2rem;
    margin-bottom: 1.25rem;
    color: inherit;
    letter-spacing: normal;
    background: none;
}

.tpb-news__accent {
    display: block;
    width: 48px;
    height: 5px;
    margin-bottom: 0.5rem;
    background-color: #F2C200;
}

.tpb-news__title {
    margin: 0;
    font-size: clamp(1.75rem, 3vw, 2.5rem);
    font-weight: 900;
    line-height: 1;
    letter-spacing: normal;
    text-transform: uppercase;
    color: #111;
}

.tpb-news__subtitle {
    margin: 0.35rem 0 0;
    font-size: 0.95rem;
    letter-spacing: normal;
    color: #4a4a4a;
}

/* Ondertitel naast de titel: "VIDEO — Reviews, features & launches" */
.tpb-news__heading--inline {
    display: flex;
    flex-wrap: wrap;
    align-items: baseline;
    gap: 0.25rem 0.6rem;
}

.tpb-news__heading--inline .tpb-news__subtitle {
    margin: 0;
    font-size: 1.1rem;
    font-weight: 700;
    text-transform: uppercase;
    color: #111;
}

.tpb-news__heading--inline .tpb-news__subtitle::before {
    content: "— ";
}

.tpb-news__button {
    display: inline-flex;
    align-items: center;
    gap: 0.6rem;
    font-size: 0.9rem;
    font-weight: 700;
    color: #111;
    text-decoration: none;
    white-space: nowrap;
    transition: background-color 0.2s, color 0.2s, border-color 0.2s;
}

.tpb-news__button--outline {
    padding: 0.7rem 1.25rem;
    border: 1.5px solid #111;
    border-radius: 3px;
    background-color: transparent;
}

.tpb-news__button--outline:hover,
.tpb-news__button--outline:focus-visible {
    background-color: #111;
    color: #fff;
}

.tpb-news__button--link:hover,
.tpb-news__button--link:focus-visible {
    text-decoration: underline;
}

.tpb-news__arrow {
    width: 14px;
    height: 14px;
    flex-shrink: 0;
}

/* Raster
–––––––––––––––––––––––––––––––––––––––––––––––––– */

.tpb-news__grid {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 1rem;
}

/* Eerste bericht breder, alles op één rij (enkel desktop) */
@media (min-width: 1025px) {
    .tpb-news--featured .tpb-news__grid {
        display: flex;
    }

    .tpb-news--featured .tpb-news__card {
        flex: 1 1 0;
        min-width: 0;
    }

    .tpb-news--featured .tpb-news__card:first-child {
        flex-grow: 2;
    }
}

/* Kaartje: tekst onder de afbeelding
–––––––––––––––––––––––––––––––––––––––––––––––––– */

.tpb-news__card {
    position: relative;
    display: flex;
    flex-direction: column;
    overflow: hidden;
    background-color: #fff;
    border: 1px solid #e2e2e2;
}

.tpb-news__image {
    position: relative;
    display: block;
    aspect-ratio: 16 / 9;
    overflow: hidden;
    background-color: #ececec;
}

.tpb-news__image img {
    display: block;
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.4s;
}

.tpb-news__card:hover .tpb-news__image img {
    transform: scale(1.04);
}

.tpb-news__body {
    display: flex;
    flex: 1;
    flex-direction: column;
    align-items: flex-start;
    padding: 0.75rem 0.75rem 1rem;
}

.tpb-news__label {
    display: inline-block;
    padding: 0.2rem 0.45rem;
    font-size: 0.7rem;
    font-weight: 800;
    line-height: 1.2;
    letter-spacing: 0.02em;
    text-transform: uppercase;
    text-decoration: none;
    color: #111;
    background-color: #F2C200;
}

.tpb-news__card-title {
    margin: 0.6rem 0 0;
    font-size: 1.05rem;
    font-weight: 800;
    line-height: 1.25;
    letter-spacing: normal;
}

.tpb-news__card-title a {
    color: #111;
    text-decoration: none;
}

.tpb-news__card-title a:hover,
.tpb-news__card-title a:focus-visible {
    text-decoration: underline;
}

.tpb-news__excerpt {
    margin: 0.6rem 0 0;
    font-size: 0.9rem;
    line-height: 1.45;
    color: #555;
}

.tpb-news__meta {
    display: flex;
    align-items: center;
    gap: 0.4rem;
    margin-top: auto;
    padding-top: 1rem;
    font-size: 0.8rem;
    color: #666;
}

.tpb-news__icon {
    width: 14px;
    height: 14px;
    flex-shrink: 0;
}

.tpb-news__play {
    display: block;
    width: 40px;
    height: 40px;
    color: #fff;
}

.tpb-news__play svg {
    display: block;
    width: 100%;
    height: 100%;
}

.tpb-news--boxed .tpb-news__play {
    position: absolute;
    left: 0.75rem;
    bottom: 0.75rem;
}

.tpb-news__empty {
    margin: 0;
    color: #666;
}

/* Kaartje: tekst op de afbeelding
–––––––––––––––––––––––––––––––––––––––––––––––––– */

.tpb-news--overlay .tpb-news__card {
    justify-content: flex-end;
    min-height: 280px;
    background-color: #111;
    border: 0;
}

.tpb-news--overlay .tpb-news__image {
    position: absolute;
    inset: 0;
    aspect-ratio: auto;
    background-color: #222;
}

.tpb-news--overlay .tpb-news__image::after {
    content: "";
    position: absolute;
    inset: 0;
    background: linear-gradient(to top, rgba(0, 0, 0, 0.85) 0%, rgba(0, 0, 0, 0.45) 45%, rgba(0, 0, 0, 0) 75%);
}

.tpb-news--overlay .tpb-news__body {
    position: relative;
    z-index: 1;
    flex: 0 0 auto;
    padding: 1rem;
    pointer-events: none;
}

.tpb-news--overlay .tpb-news__body a {
    pointer-events: auto;
}

.tpb-news--overlay .tpb-news__play {
    margin-bottom: 0.75rem;
}

.tpb-news--overlay .tpb-news__card-title a {
    color: #fff;
}

.tpb-news--overlay .tpb-news__excerpt {
    color: rgba(255, 255, 255, 0.8);
}

.tpb-news--overlay .tpb-news__meta {
    padding-top: 0.75rem;
    color: rgba(255, 255, 255, 0.75);
}

.tpb-news--overlay.tpb-news--featured .tpb-news__card:first-child .tpb-news__card-title {
    font-size: 1.35rem;
}

/* Dark mode: witte tekst. Geen achtergrond, die komt van de sectie/container errond
–––––––––––––––––––––––––––––––––––––––––––––––––– */

.tpb-news--dark {
    color: #fff;
}

.tpb-news--dark .tpb-news__title,
.tpb-news--dark .tpb-news__heading--inline .tpb-news__subtitle,
.tpb-news--dark .tpb-news__button {
    color: #fff;
}

.tpb-news--dark .tpb-news__subtitle {
    color: rgba(255, 255, 255, 0.75);
}

.tpb-news--dark .tpb-news__button--outline {
    border-color: #fff;
}

.tpb-news--dark .tpb-news__button--outline:hover,
.tpb-news--dark .tpb-news__button--outline:focus-visible {
    background-color: #fff;
    color: #111;
}

/* Licht doorschijnend, zodat het kaartje bij elke donkere achtergrond past */
.tpb-news--dark.tpb-news--boxed .tpb-news__card {
    background-color: rgba(255, 255, 255, 0.06);
    border-color: rgba(255, 255, 255, 0.14);
}

.tpb-news--dark.tpb-news--boxed .tpb-news__image {
    background-color: rgba(255, 255, 255, 0.08);
}

.tpb-news--dark .tpb-news__card-title a {
    color: #fff;
}

.tpb-news--dark .tpb-news__excerpt {
    color: rgba(255, 255, 255, 0.75);
}

.tpb-news--dark .tpb-news__meta,
.tpb-news--dark .tpb-news__empty {
    color: rgba(255, 255, 255, 0.65);
}

/* Responsive standaard (Elementor-instellingen gaan hierboven)
–––––––––––––––––––––––––––––––––––––––––––––––––– */

@media (max-width: 1024px) {
    .tpb-news__grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
}

@media (max-width: 600px) {
    .tpb-news__grid {
        grid-template-columns: minmax(0, 1fr);
    }
}
