@import "variables";
@import "mixins";

section.carousel-boxes {
  .carousel-boxes-wrap {
    padding: $space-md 0 5rem;
    // overflow: unset;
    div.carousel-box {
      position: relative;
      padding: 4rem 3rem 6rem;
      border-radius: 2rem;
      box-shadow: 0px 8px 24px 0px rgba(0, 0, 0, 0.25);
      h6,
      p {
        position: relative;
        z-index: 1;
        color: $black;
      }
      a.link {
        position: relative;
        z-index: 1;
      }
    }
    div.carousel-box:not(.carousel-box-placeholder) {
      //filled with background
      &:has(h6) {
        &:after {
          z-index: 0;
          content: "";
          position: absolute;
          top: 0;
          left: 0;
          width: 100%;
          height: 100%;
          border-radius: 2rem;
          background: linear-gradient(
            180deg,
            rgba(255, 255, 255, 0.5) 0%,
            rgba(255, 255, 255, 0.9) 100%
          );
        }
      }
    }
    .dots .dot {
      background-color: $gray300;
    }
    .dots .dot.active {
      background-color: $col-prm;
    }
  }
  .carousel-box-placeholder {
    background-color: $white;
  }
}

body.wp-admin {
  .carousel-boxes-wrap {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    grid-template-rows: 1fr;
    grid-column-gap: 1rem;
    grid-row-gap: 1rem;
  }
}
