[data-component-id="usfq_theme:section_hero_carousel"] {
  position: relative;
  overflow: hidden;
  width: 100%;
  color: white;

  &:not(:has(.carousel-item:nth-child(2))) .carousel-controls {
    display: none;
  }

  .section-hero__background {
    position: absolute;
    inset: 0;
    z-index: 0;

    div {
      height: 100%;
    }
  }

  .section-hero__background img,
  .section-hero__background video {
    width: 100%;
    height: 100%;
    object-fit: cover;
  }

  .section-hero__overlay {
    position: absolute;
    inset: 0;
    z-index: 1;
  }

  .section-hero__content {
    position: relative;
    z-index: 2;
    width: 100%;
    height: 100%;
    padding: 2rem 0;
    display: flex;
    flex-direction: column;
    justify-content: flex-end;
  }

  .section-hero__text .text-block .title {
    white-space: normal;
    overflow-wrap: break-word;
    word-break: normal;
    hyphens: none;
    max-width: 100%;
  }

  .section-hero__text {
    width: 100%;
    padding: 0 4rem;
  }

  .section-hero__link {
    margin-top: 2rem;
  }

  /* MOBILE (default) */
  .carousel-control-prev,
  .carousel-control-next {
    position: static;
    width: 36px;
    height: 36px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    border: 2px solid var(--white);
    color: var(--white);
  }

  /* TABLET */
  @media (min-width: 768px) and (max-width: 1024px) {
    .section-hero__content {
      padding: 4.5rem 0;
    }

    .section-hero__text {
      padding: 0 7rem;
    }

    .carousel-control-prev,
    .carousel-control-next {
      width: 40px;
      height: 40px;
    }
  }

  /* DESKTOP */
  @media (min-width: 1025px) {
    .section-hero__content {
      padding: 7.5rem 0 4rem;
    }
    
    .section-hero__text {
      width: 100%;
      max-width: 50%;
      padding: 0 7rem;
    }

    .carousel-controls {
      padding: 0 4rem;
    }

    .carousel-control-prev,
    .carousel-control-next {
      width: 53px;
      height: 53px;
    }
  }

  .section-hero__overlay--dark_1 {
    background-color: var(--dark-opacity-20);
  }


  .section-hero__overlay--dark_2 {
    background-color: var(--dark-opacity-60);
  }

  &.section-hero--dark_2 .section-hero__content,
  &.section-hero--dark_1 .section-hero__content {
    color: var(--white);
  }

  .section-hero__overlay--light_1 {
    background-color: var(--light-opacity-60);
  }
  &.section-hero--light_1 .section-hero__content,
  &.section-hero--light_2 .section-hero__content,
  &.section-hero--light_1 .section-hero__content h2, 
  &.section-hero--light_2 .section-hero__content h2,
  &.section-hero--light_1 .section-hero__content p,
  &.section-hero--light_2 .section-hero__content p {
    color: var(--dark);
  }

  .section-hero__overlay--light_2 {
    background-color: var(--light-opacity-20);
  }

  /* Opción "Degradado desde abajo" de field_opacity: la comparte con el hero,
     así que aquí se pinta igual — negro desde el pie hasta 0 arriba. */
  .section-hero__overlay--gradient {
    background-image: linear-gradient(to top,
        rgb(0 0 0 / 85%) 0%,
        rgb(0 0 0 / 55%) 40%,
        rgb(0 0 0 / 0%) 80%);
  }

  &.section-hero--gradient .section-hero__content {
    color: var(--white);
  }
  
  .carousel,
  .carousel-inner {
    height: 89vh;
  }

  .carousel-inner {
    display: grid;
    grid-template-columns: 1fr;
    grid-template-rows: 1fr;
  }

  .carousel-item {
    grid-column: 1;
    grid-row: 1;
    display: block !important;
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.6s ease-in-out, visibility 0.6s ease-in-out;
    z-index: 0;
  }

  .carousel-item.active {
    opacity: 1;
    visibility: visible;
    z-index: 1;
  }

  .carousel-item-next,
  .carousel-item-prev {
    display: block !important;
  }

  .carousel-item-next.carousel-item-start,
  .carousel-item-prev.carousel-item-end {
    opacity: 1;
    visibility: visible;
  }

  .carousel-item.active.carousel-item-start,
  .carousel-item.active.carousel-item-end {
    opacity: 0;
    visibility: hidden;
  }

  .carousel-item img {
    width: 100%;
    height: 100%;
    object-fit: cover;
  }

  .carousel-controls {
    position: absolute;
    display: flex;
    top: 50%;
    transform: translateY(-50%);
    justify-content: space-between;
    align-items: center;
    gap: 4rem;
    z-index: 5;
    width: 100%;
    padding: 0 1rem;
  }

  .carousel-indicators {
    position: absolute;
    bottom: 2rem;
    left: 50%;
    transform: translateX(-50%);
    z-index: 5;
    display: flex;
    justify-content: center;
    gap: 0.5rem;
    margin: 0;
    padding: 0;
  }

  .carousel-indicators button {
    width: 10px;
    height: 10px;
    border-radius: 50%;
    border: none;
    background-color: white;
    opacity: 0.3;
    transition: opacity 0.3s ease;
    padding: 0;
  }

  .carousel-indicators button.active {
    opacity: 1;
    background-color: var(--primary);
  }
  
  .carousel-control-prev .icon,
    .carousel-control-next .icon{
      color: var(--white)!important;
    }  

  .carousel-control-prev:hover,
  .carousel-control-next:hover,
  .carousel-control-prev:focus,
  .carousel-control-next:focus {
    color: white !important;
    background-color:  var(--secondary) !important;
  }

  [data-component-id="usfq_theme:link"] {
  /* Variantes color */
    &.link--color-secondary, .link--color-primary, 
    .link--color-light:not(-link--divier){
      color: inherit !important;
    }
  }
  :where(html[data-theme="dark"]) & {
    
  }
}