.tab-collage {
  row-gap: 3rem;
  padding: 4rem 5%;
  color: rgb(var(--color-foreground));
  background-color: rgb(var(--color-background));
  --color-heading: rgb(var(--color-foreground));
}

.tab-collage__left {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: flex-start;
  row-gap: 2rem;
}

@media screen and (min-width: 750px) {
  .tab-collage {
    padding: 0;
    background-color: transparent;
  }

  .tab-collage__grid--reverse {
    flex-direction: row-reverse;
  }

  .tab-collage__left {
    row-gap: 5rem;
    background-color: rgb(var(--color-background));
  }

  .tab-collage__left.middle {
    justify-content: center;
  }

  .tab-collage__left.bottom {
    justify-content: flex-end;
  }

  .tab-collage__content {
    padding-top: 5rem;
  }

  .tab-collage__bottom {
    padding-bottom: 5rem;
  }
}

.tab-collage__content {
  width: 100%;
  display: flex;
  flex-direction: column;
  row-gap: 0.5rem;
  list-style: none;
}

.tab-collage__bottom {
  width: 100%;
}

@media screen and (max-width: 749px) {
  .tab-collage__grid-mobile--reverse {
    flex-direction: column-reverse;
    row-gap: 0;
  }

  .tab-collage__grid-mobile--reverse .tab-collage__left {
    margin-top: 3rem;
  }

  .tab-collage__content,
  .tab-collage__bottom {
    padding: 0;
  }

  .tab-collage__bottom.mobile-center .button {
    min-width: 60%;
  }
}

.tab-collage__heading {
  display: inline-block;
  letter-spacing: -0.01rem;
  font-weight: 700;
  margin: 0;
  cursor: pointer;
  opacity: 0.3;
  transition: opacity var(--duration-default) ease;
}

.tab-collage__heading.active {
  opacity: 1;
}

.tab-collage__desc {
  display: none;
  line-height: calc(1 + 0.6 / var(--font-body-scale));
}

.tab-collage__desc.active {
  display: block;
}

.tab-collage__card {
  display: block;
  position: absolute;
  visibility: hidden;
}

.tab-collage__card.active {
  z-index: 1;
  position: relative;
  visibility: visible;
}

.tab-collage__card .deferred-media__poster {
  display: flex;
  align-items: center;
  justify-content: center;
}

.tab-collage__card .media {
  width: 100%;
}

.tab-collage__desc p {
  margin: 0;
}

.tab-collage__desc :last-child:is(.button) {
  margin-top: 3rem;
}

@media screen and (min-width: 750px) {
  .tab-collage__desc div {
    min-height: 9rem;
  }
}

.tab-collage-video__modal {
  box-sizing: border-box;
  opacity: 0;
  position: fixed;
  visibility: hidden;
  z-index: -1;
  margin: 0 auto;
  top: 0;
  left: 0;
  overflow: auto;
  width: 100%;
  background-color: rgba(var(--color-base-text), 0.2);
  height: 100%;
}

.tab-collage-video__modal[open] {
  opacity: 1;
  visibility: visible;
  z-index: 101;
}

.tab-collage-video__modal-content {
  background-color: rgb(var(--color-base-background));
  overflow: auto;
  height: 100%;
  margin: 0;
  width: 100%;
  position: absolute;
  padding: 0;
}

.tab-collage-video__modal-toggle {
  background-color: rgb(var(--color-base-background));
  border: 0.1rem solid rgb(var(--color-border));
  border-radius: 50%;
  color: rgb(var(--color-base-text));
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  position: fixed;
  padding: 1.2rem;
  z-index: 2;
  top: 2rem;
  right: 0.5rem;
  width: 4.4rem;
  height: 4.4rem;
  margin: 0 0 0 auto;
}

@media screen and (min-width: 750px) {
  .tab-collage-video__modal-toggle {
    right: 4.8rem;
    top: 3.5rem;
  }
}

@media screen and (min-width: 990px) {
  .tab-collage-video__modal-toggle {
    right: 4.3rem;
    top: 3rem;
  }
}

.tab-collage-video__modal-toggle .icon {
  width: 1.5rem;
  height: 1.5rem;
  transition: transform var(--duration-default) ease;
}

@media screen and (hover: hover) {
  .tab-collage-video__modal-toggle:hover .icon {
    transform: scale(.8) rotate(90deg);
  }
}

.tab-collage-video__modal-video {
  width: calc(100% - 1rem);
  height: calc(100% - 6rem);
  margin: 0 auto;
  padding-top: 8rem;
}

@media screen and (min-width: 750px) {
  .tab-collage-video__modal-video {
    width: calc(100% - 9.6rem);
    height: calc(100% - 7.5rem);
    padding-top: 9.5rem;
  }
}

@media screen and (min-width: 990px) {
  .tab-collage-video__modal-video {
    width: calc(100% - 8.6rem);
    height: calc(100% - 7rem);
    padding-top: 9rem;
  }
}

.tab-collage-video__modal-video iframe {
  width: 100%;
  height: 100%;
  position: static;
  border: 0;
}
