/*
 * Emanelcor — slider pagina Acasă
 * Markup-ul este generat de features/home/home-slider.php.
 */

.ema-home-slider {
  position: relative;
  width: 100%;
  height: clamp(340px, 40vw, 560px);
  overflow: hidden;
  color: #fff;
  background: #0a202c;
  border-radius: var(--radius-lg, 20px);
  isolation: isolate;
}

.ema-home-slider__track,
.ema-home-slider__slide,
.ema-home-slider__link {
  position: absolute;
  inset: 0;
}

.ema-home-slider__slide {
  visibility: hidden;
  opacity: 0;
  transition: opacity .65s ease, visibility .65s ease;
}

.ema-home-slider__slide.is-active {
  z-index: 1;
  visibility: visible;
  opacity: 1;
}

.ema-home-slider__link {
  display: block;
  overflow: hidden;
  color: #fff !important;
  text-decoration: none !important;
}

.ema-home-slider__link img {
  width: 100% !important;
  height: 100% !important;
  max-width: none !important;
  display: block;
  margin: 0 !important;
  object-fit: cover !important;
  transition: transform .8s ease;
}

.ema-home-slider__image--top { object-position: center top !important; }
.ema-home-slider__image--middle { object-position: center center !important; }
.ema-home-slider__image--bottom { object-position: center bottom !important; }

.ema-home-slider__link:hover img { transform: scale(1.025); }

.ema-home-slider__shade {
  position: absolute;
  inset: 0;
  display: block;
  background:
    linear-gradient(90deg, rgba(5, 22, 31, .9) 0%, rgba(5, 22, 31, .68) 40%, rgba(5, 22, 31, .12) 76%),
    linear-gradient(0deg, rgba(5, 22, 31, .46), transparent 48%);
}

.ema-home-slider__content {
  position: absolute;
  z-index: 1;
  bottom: clamp(70px, 8vw, 102px);
  left: clamp(26px, 5.5vw, 76px);
  width: min(610px, calc(100% - 52px));
  display: flex;
  align-items: flex-start;
  flex-direction: column;
}

.ema-home-slider__content small {
  margin-bottom: 16px;
  color: #ee6d14;
  font-size: 11px;
  font-weight: 800;
  letter-spacing: .14em;
  text-transform: uppercase;
}

.ema-home-slider__content strong {
  max-width: 600px;
  color: #fff;
  font-family: var(--wd-title-font, "Mulish", Arial, sans-serif);
  font-size: clamp(34px, 4.7vw, 66px);
  font-weight: 750;
  line-height: 1.02;
  letter-spacing: -.04em;
}

.ema-home-slider__text {
  max-width: 540px;
  margin-top: 18px;
  color: rgba(255, 255, 255, .76);
  font-size: clamp(14px, 1.25vw, 17px);
  line-height: 1.55;
}

.ema-home-slider__cta {
  display: inline-flex;
  align-items: center;
  gap: 14px;
  margin-top: 25px;
  padding-bottom: 7px;
  color: #fff;
  border-bottom: 1px solid rgba(255, 255, 255, .55);
  font-size: 13px;
  font-weight: 750;
}

.ema-home-slider__cta svg,
.ema-home-slider__arrow svg {
  width: 20px;
  height: 20px;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.8;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.ema-home-slider__arrow svg {
  width: 27px;
  height: 27px;
  flex: 0 0 27px;
}

.ema-home-slider__navigation {
  position: absolute;
  z-index: 3;
  right: clamp(18px, 3vw, 34px);
  bottom: clamp(18px, 3vw, 30px);
  display: flex;
  gap: 8px;
}

.ema-home-slider__arrow {
  width: 54px;
  height: 54px;
  display: grid;
  place-items: center;
  padding: 0;
  color: #fff;
  background: rgba(10, 32, 44, .65);
  border: 1px solid rgba(255, 255, 255, .24);
  border-radius: 50%;
  cursor: pointer;
  backdrop-filter: blur(8px);
  transition: color .25s ease, background .25s ease, transform .25s ease;
}

.ema-home-slider__arrow:hover {
  color: #0a202c;
  background: #fff;
  transform: translateY(-2px);
}

.ema-home-slider__play-icon { display: none; }
.ema-home-slider__toggle.is-paused .ema-home-slider__pause-icon { display: none; }
.ema-home-slider__toggle.is-paused .ema-home-slider__play-icon { display: block; }
.ema-home-slider__arrow[hidden] { display: none !important; }

.ema-home-slider__dots {
  position: absolute;
  z-index: 3;
  bottom: clamp(24px, 3vw, 36px);
  left: clamp(22px, 5.5vw, 76px);
  display: flex;
  align-items: center;
  gap: 7px;
}

.ema-home-slider__dots button {
  width: 34px;
  height: 20px;
  display: grid;
  place-items: center;
  padding: 0;
  background: transparent;
  border: 0;
  cursor: pointer;
}

.ema-home-slider__dots button span {
  width: 100%;
  height: 3px;
  display: block;
  background: rgba(255, 255, 255, .38);
  border-radius: 99px;
  transition: background .25s ease, transform .25s ease;
}

.ema-home-slider__dots button[aria-current="true"] span {
  background: #ee6d14;
  transform: scaleY(1.5);
}

.ema-home-slider__link:focus-visible,
.ema-home-slider button:focus-visible {
  outline: 3px solid #fff;
  outline-offset: -5px;
}

.ema-home-slider .screen-reader-text {
  position: absolute !important;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

@media (max-width: 600px) {
  .ema-home-slider {
    height: 430px;
    border-radius: var(--radius-md, 14px);
  }

  .ema-home-slider__shade {
    background: linear-gradient(0deg, rgba(5, 22, 31, .94) 0%, rgba(5, 22, 31, .5) 65%, rgba(5, 22, 31, .08) 100%);
  }

  .ema-home-slider__content {
    right: 22px;
    bottom: 84px;
    left: 22px;
    width: auto;
  }

  .ema-home-slider__content small { margin-bottom: 11px; }
  .ema-home-slider__content strong { font-size: clamp(31px, 10vw, 43px); }

  .ema-home-slider__text {
    margin-top: 12px;
    font-size: 14px;
  }

  .ema-home-slider__cta { margin-top: 18px; }

  .ema-home-slider__dots {
    bottom: 28px;
    left: 17px;
  }

  .ema-home-slider__navigation {
    right: 16px;
    bottom: 16px;
  }

  .ema-home-slider__arrow {
    width: 48px;
    height: 48px;
  }

  .ema-home-slider__arrow svg {
    width: 24px;
    height: 24px;
    flex-basis: 24px;
  }
}

@media (prefers-reduced-motion: reduce) {
  .ema-home-slider__slide,
  .ema-home-slider__link img,
  .ema-home-slider__arrow,
  .ema-home-slider__dots button span {
    transition: none;
  }

  .ema-home-slider__link:hover img,
  .ema-home-slider__arrow:hover {
    transform: none;
  }
}
