/* Homepage insights section based on the reference card composition. */
.wp-block-group.bb-news {
    width: auto;
    max-width: none;
    margin-inline: calc(-1 * var(--bb-page-gutter));
    padding: var(--wp--preset--spacing--96) var(--bb-page-gutter);
    background: var(--wp--custom--color--black--50);
    color: var(--wp--preset--color--ink);
}
.bb-news__inner > * { margin-block-end: 0; }
.bb-news__inner > :first-child { margin-block-start: 0; }
.wp-block-group.bb-news__header {
    align-items: flex-end;
    gap: var(--wp--preset--spacing--32);
}
.bb-news__title {
    margin: 0;
    color: var(--wp--preset--color--ink);
}
.bb-news__view-all { margin: 0; }
.bb-news__grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: var(--wp--preset--spacing--24);
}
.bb-news .bb-news__grid { margin-block-start: 50px; }
.bb-news:not(.is-visible) .bb-news__title,
.bb-news:not(.is-visible) .bb-news__view-all,
.bb-news:not(.is-visible) .bb-insight-card {
    opacity: 0;
    transform: translateY(24px);
}
.bb-news.is-visible .bb-news__title,
.bb-news.is-visible .bb-news__view-all,
.bb-news.is-visible .bb-insight-card {
    opacity: 1;
    transform: translateY(0);
    transition: opacity .7s ease, transform .7s cubic-bezier(.2,.75,.2,1);
}
.bb-news.is-visible .bb-news__view-all { transition-delay: .06s; }
.bb-news.is-visible .bb-insight-card:nth-child(1) { transition-delay: .08s; }
.bb-news.is-visible .bb-insight-card:nth-child(2) { transition-delay: .14s; }
.bb-news.is-visible .bb-insight-card:nth-child(3) { transition-delay: .20s; }

/* The Site Editor does not run the frontend observer that adds `.is-visible`.
   Keep editable blocks visible on the canvas while retaining entrance motion live. */
.editor-styles-wrapper .bb-news:not(.is-visible) .bb-news__title,
.editor-styles-wrapper .bb-news:not(.is-visible) .bb-news__view-all,
.editor-styles-wrapper .bb-news:not(.is-visible) .bb-news-card {
    opacity: 1;
    transform: none;
}

@media (max-width: 900px) {
    .wp-block-group.bb-news { padding-block: var(--wp--preset--spacing--80); }
    .bb-news__grid { grid-template-columns: 1fr; }
    .bb-news .bb-news__grid { margin-block-start: 50px; }
}
@media (max-width: 600px) {
    .wp-block-group.bb-news {
        padding-block: var(--wp--preset--spacing--64);
        padding-inline: var(--bb-page-gutter);
    }
    .wp-block-group.bb-news__header { display: grid; align-items: start; }
    .bb-news__title br { display: none; }
    .bb-news__grid { gap: var(--wp--preset--spacing--16); }
    .bb-news .bb-news__grid { margin-block-start: 32px; }
}
@media (prefers-reduced-motion: reduce) {
    .bb-news__title,
    .bb-news__view-all { transition: none !important; }
    .bb-news:not(.is-visible) .bb-news__title,
    .bb-news:not(.is-visible) .bb-news__view-all,
    .bb-news:not(.is-visible) .bb-insight-card { opacity: 1; transform: none; }
}
