.paragraph--type--wrapper-section {
  overflow: hidden;
  .wrapper-section-paragraph {
    padding-block: 100px;

    .field--name-field-pre-heading {
      color: var(--Tertiary, #4AA8DE);
      text-align: center;
      font-family: var(--font-serif);
      font-size: 36px;
      font-style: normal;
      font-weight: 700;
      line-height: 94%; /* 33.84px */
      letter-spacing: 0.72px;
      text-transform: uppercase;
      margin-bottom: 20px;
      position: relative;
      z-index: 2;
    }

    > .field--name-field-heading {
      color: var(--Brand-Secondary, #DD3A31);
      text-align: center;
      font-family: var(--font-sans);
      font-size: 40px;
      font-style: normal;
      font-weight: 600;
      line-height: 110%; /* 33px */
      position: relative;
      z-index: 2;
      margin-bottom: 60px;
    }

    @media (max-width: 767px) {
      padding-block: 60px 40px;

      > .field--name-field-heading {
        font-size: 30px;
        max-width: 70%;
        margin: 0 auto 47px auto;
      }

      .field--name-field-alternating-gallery-items {
        gap: 40px !important;
        > .field__item:not(:last-child) {
          .paragraph--type--alternating-image-text {
            &::after {
              position: relative;
              content: "";
              width: 70px;
              height: 2px;
              background: #DD3A31;
              margin: auto;
              z-index: 3;
            }
          }
        }
      }
    }

    &.bg-image {
      padding-block: 254px 60px;
      background: linear-gradient(
        to bottom,
        rgba(255, 255, 255, 0) 0%,   /* fully transparent at top */
        rgba(255, 255, 255, 1) 25%  /* fully white at bottom */
      ),
      var(--wrapper-section-bg, none);
      background-repeat: no-repeat, no-repeat;
      background-position: top;
      background-size: contain;

      @media (max-width: 767px) {
        padding-block: 160px 40px;
        background: linear-gradient(
          to bottom,
          rgba(255, 255, 255, 0) 0%,   /* fully transparent at top */
          rgba(255, 255, 255, 1) 20%  /* fully white at bottom */
        ),
        var(--wrapper-section-bg, none);
        background-position: center;

        .field--name-field-alternating-gallery-items {
          gap: 40px !important;
          > .field__item:first-child {
            .paragraph--type--alternating-image-text {
              /* Soft cloudy white haze behind the row */
              .text-content {
                &::before {
                  content: "";
                  position: absolute;
                  inset: -140px -120px;
                  background: radial-gradient(
                    60% 75% at 50% 20%,
                    rgba(255, 255, 255, 0.98) 65%,
                    rgba(255, 255, 255, 0.9) 65%,
                    rgba(255, 255, 255, 0.75) 65%,
                    rgba(255, 255, 255, 0.55) 60%,
                    rgba(255, 255, 255, 0) 65%
                  );
                  filter: blur(32px);
                  z-index: 0;
                  pointer-events: none;
                }

                * {
                  position: relative;
                  z-index: 2;
                }
              }
            }
          }
        }
      }

      .field--name-field-alternating-gallery-items {
        &:has(.paragraph--type--featured-gallery) {
          position: relative;
          &::before {
            content: "";
            position: absolute;
            inset: -200px -120px;
            background: radial-gradient(
              80% 100% at 50% 50%,
              rgba(255, 255, 255, 0.98) 65%,
              rgba(255, 255, 255, 0.9) 65%,
              rgba(255, 255, 255, 0.75) 65%,
              rgba(255, 255, 255, 0.55) 60%,
              rgba(255, 255, 255, 0) 65%
            );
            filter: blur(32px);
            z-index: 0;
            pointer-events: none;
          }

          * {
            position: relative;
            z-index: 2;
          }

          @media (max-width: 767px) {
            &::before {
              content: "";
              position: absolute;
              inset: -260px -120px;
              background: radial-gradient(
                80% 100% at 50% 50%,
                rgba(255, 255, 255, 0.98) 65%,
                rgba(255, 255, 255, 0.9) 65%,
                rgba(255, 255, 255, 0.75) 65%,
                rgba(255, 255, 255, 0.55) 60%,
                rgba(255, 255, 255, 0) 65%
              );
              filter: blur(32px);
              z-index: 0;
              pointer-events: none;
            }
          }
        }
      }
    }

    .field--name-field-alternating-gallery-items {
      display: flex;
      flex-direction: column;
      gap: 100px;

      > .field__item:nth-child(odd) {
        .paragraph--type--alternating-image-text {
          flex-direction: row-reverse;
        }
      }

      @media (min-width: 767px) {
        > .field__item:first-child {
          .paragraph--type--alternating-image-text {
            /* Soft cloudy white haze behind the row */
            &::before {
              content: "";
              position: absolute;
              inset: -140px -120px;
              background: radial-gradient(
                100% 100% at 50% 50%,
                rgba(255, 255, 255, 0.98) 65%,
                rgba(255, 255, 255, 0.9) 65%,
                rgba(255, 255, 255, 0.75) 65%,
                rgba(255, 255, 255, 0.55) 60%,
                rgba(255, 255, 255, 0) 65%
              );
              filter: blur(32px);
              z-index: 0;
              pointer-events: none;
            }

            * {
              position: relative;
              z-index: 2;
            }
          }
        }
      }
    }

    .paragraph--type--featured-gallery {
      max-width: 1526px;
      margin: 0 auto;
      padding-left: 43px;
      padding-right: 43px;

      @media (max-width: 1440px) {
        padding-left: 3vw;
        padding-right: 3vw;
      }
      .field--name-field-images {
        --gallery-gap: 20px;
        display: flex;
        flex-wrap: wrap;
        gap: var(--gallery-gap);
        margin-bottom: 100px;

        > .field__item {
          flex: 0 0 100%;

          img {
            width: 100%;
            height: 444px;
            object-fit: cover;
            border-radius: 12px;
          }
        }

        @media (min-width: 768px) {
          > .field__item {
            flex: 0 0 calc(100% / 3 - (var(--gallery-gap) * 2 / 3));
          }

          > .field__item:nth-child(10n + 1) {
            flex-basis: calc(67% - (var(--gallery-gap) / 2));
          }

          > .field__item:nth-child(10n + 2) {
            flex-basis: calc(33% - (var(--gallery-gap) / 2));
          }

          > .field__item:nth-child(10n + 6) {
            flex-basis: calc(33% - (var(--gallery-gap) / 2));
          }

          > .field__item:nth-child(10n + 7) {
            flex-basis: calc(67% - (var(--gallery-gap) / 2));
          }

          > .field__item:nth-child(10n + 3),
          > .field__item:nth-child(10n + 4),
          > .field__item:nth-child(10n + 5),
          > .field__item:nth-child(10n + 8),
          > .field__item:nth-child(10n + 9),
          > .field__item:nth-child(10n) {
            flex-basis: calc(100% / 3 - (var(--gallery-gap) * 2 / 3));
          }
        }
      }
    }
  }
}
