.ks-hero-slider {
  --ks-orange: #ef711f;
  --ks-orange-hover: #ff812d;
  --ks-cream: #f6f1e9;
  --ks-line: rgba(255, 255, 255, 0.26);
  --ks-shell: min(1440px, calc(100% - 96px));
  position: relative;
  isolation: isolate;
  display: block;
  width: 100%;
  min-width: 0;
  min-height: 640px;
  height: clamp(640px, 65vw, 800px);
  margin: 0;
  padding: 0;
  overflow: hidden;
  color: var(--ks-cream);
  background: #211812;
  font-family: inherit;
  font-size: 16px;
  font-style: normal;
  font-weight: 400;
  line-height: 1.2;
  letter-spacing: normal;
  text-align: left;
  text-transform: none;
  font-synthesis: none;
}

.ks-hero-slider,
.ks-hero-slider *,
.ks-hero-slider *::before,
.ks-hero-slider *::after {
  box-sizing: border-box;
}

.ks-hero-slider button,
.ks-hero-slider a {
  -webkit-tap-highlight-color: transparent;
}

.ks-hero-slider button {
  appearance: none;
  margin: 0;
  font: inherit;
}

.ks-hero-slider__shell {
  width: var(--ks-shell);
  max-width: none;
  margin-inline: auto;
}

.ks-hero-slider__slides,
.ks-hero-slide {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  margin: 0;
  padding: 0;
}

.ks-hero-slide {
  z-index: 0;
  display: block;
  opacity: 0;
  visibility: hidden;
  transition: opacity 900ms cubic-bezier(0.22, 1, 0.36, 1), visibility 900ms;
}

.ks-hero-slide.is-active {
  z-index: 1;
  opacity: 1;
  visibility: visible;
}

.ks-hero-slide__media {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  background-repeat: no-repeat;
  background-position: center;
  background-size: cover;
  transform: scale(1.035);
  transition: transform 8s cubic-bezier(0.2, 0.75, 0.25, 1);
  user-select: none;
}

.ks-hero-slide__media--calculate {
  background-image: url("./hero-house-long.png");
}

.ks-hero-slide__media--production {
  background-image: url("./hero-house-wide.png");
  background-position: 58% center;
}

.ks-hero-slide.is-active .ks-hero-slide__media {
  transform: scale(1);
}

.ks-hero-slide__shade {
  position: absolute;
  inset: 0;
  background:
    linear-gradient(90deg, rgba(20, 14, 10, 0.83) 0%, rgba(25, 17, 12, 0.65) 28%, rgba(24, 16, 11, 0.16) 58%, rgba(20, 14, 10, 0.06) 100%),
    linear-gradient(180deg, rgba(12, 8, 6, 0.3) 0%, transparent 25%, transparent 67%, rgba(12, 8, 6, 0.68) 100%);
}

.ks-hero-slide__shade--deep {
  background:
    linear-gradient(90deg, rgba(20, 14, 10, 0.86) 0%, rgba(25, 17, 12, 0.62) 31%, rgba(24, 16, 11, 0.12) 61%, rgba(20, 14, 10, 0.03) 100%),
    linear-gradient(180deg, rgba(12, 8, 6, 0.3) 0%, transparent 30%, transparent 64%, rgba(12, 8, 6, 0.66) 100%);
}

.ks-hero-slide__content {
  position: relative;
  z-index: 2;
  display: flex;
  flex-direction: column;
  justify-content: center;
  height: 100%;
  padding-top: 42px;
  padding-bottom: 120px;
}

.ks-hero-slide__copy {
  width: min(670px, 54vw);
  margin: 0;
  padding: 0;
  transform: translateY(28px);
  opacity: 0;
  transition: transform 850ms 180ms cubic-bezier(0.22, 1, 0.36, 1), opacity 650ms 180ms ease;
}

.ks-hero-slide.is-active .ks-hero-slide__copy {
  transform: translateY(0);
  opacity: 1;
}

.ks-hero-slide__title {
  display: block;
  max-width: 760px;
  margin: 0;
  padding: 0;
  color: #fff;
  font-family: inherit;
  font-size: clamp(54px, 6vw, 88px);
  font-style: normal;
  font-weight: 700;
  line-height: 0.94;
  letter-spacing: -0.055em;
  text-align: left;
  text-transform: none;
  text-wrap: balance;
}

.ks-hero-slide__title em {
  color: var(--ks-orange);
  font: inherit;
}

.ks-hero-slide__time {
  display: flex;
  align-items: center;
  gap: 9px;
  margin-top: 14px;
  color: #fff;
  font-family: inherit;
  font-size: clamp(25px, 2.3vw, 38px);
  font-weight: 500;
  line-height: 1;
  letter-spacing: -0.035em;
}

.ks-hero-slide__time b {
  display: inline-grid;
  place-items: center;
  width: 58px;
  height: 58px;
  border: 1px solid rgba(255, 255, 255, 0.38);
  border-radius: 50%;
  color: var(--ks-orange);
  font-family: inherit;
  font-size: 38px;
  font-weight: 700;
  line-height: 1;
}

.ks-hero-slide__lead {
  max-width: 560px;
  margin: 26px 0 0;
  padding: 0;
  color: rgba(255, 255, 255, 0.76);
  font-family: inherit;
  font-size: clamp(16px, 1.35vw, 20px);
  font-weight: 400;
  line-height: 1.55;
  letter-spacing: 0;
}

.ks-hero-slider .btn.ks-hero-slide__button {
  will-change: transform;
}

.ks-hero-slider .btn.ks-hero-slide__button:hover,
.ks-hero-slider .btn.ks-hero-slide__button:focus-visible {
  transform: translateY(-3px);
}

.ks-hero-controls {
  position: absolute;
  z-index: 10;
  right: 0;
  bottom: 0;
  left: 0;
  display: grid;
  grid-template-columns: auto minmax(100px, 320px) 1fr auto;
  align-items: center;
  min-height: 92px;
  gap: 26px;
  border-top: 1px solid var(--ks-line);
}

.ks-hero-controls__counter {
  display: flex;
  align-items: center;
  gap: 9px;
  color: #fff;
  font-family: inherit;
  font-variant-numeric: tabular-nums;
  font-size: 12px;
  font-weight: 700;
  line-height: 1;
}

.ks-hero-controls__counter i {
  display: block;
  width: 22px;
  height: 1px;
  background: rgba(255, 255, 255, 0.36);
}

.ks-hero-controls__counter span:last-child {
  color: rgba(255, 255, 255, 0.48);
}

.ks-hero-controls__progress {
  height: 1px;
  overflow: hidden;
  background: rgba(255, 255, 255, 0.28);
}

.ks-hero-controls__progress span {
  display: block;
  width: 100%;
  height: 100%;
  background: var(--ks-orange);
  transform: scaleX(0);
  transform-origin: left center;
  will-change: transform;
}

.ks-hero-controls__dots {
  display: flex;
  align-items: center;
  gap: 10px;
}

.ks-hero-controls__dots button {
  display: block;
  width: 18px;
  height: 18px;
  padding: 0;
  border: 0;
  border-radius: 50%;
  background: transparent;
  box-shadow: none;
  cursor: pointer;
}

.ks-hero-controls__dots button::before {
  display: block;
  width: 5px;
  height: 5px;
  margin: auto;
  border-radius: 50%;
  content: "";
  background: rgba(255, 255, 255, 0.42);
  transition: background 180ms ease, transform 180ms ease;
}

.ks-hero-controls__dots button[aria-selected="true"]::before {
  background: var(--ks-orange);
  transform: scale(1.8);
}

.ks-hero-controls__arrows {
  display: flex;
  gap: 8px;
}

.ks-hero-controls__arrows button {
  display: grid;
  place-items: center;
  width: 48px;
  height: 48px;
  padding: 0;
  border: 1px solid rgba(255, 255, 255, 0.34);
  border-radius: 50%;
  color: #fff;
  background: rgba(25, 17, 12, 0.18);
  box-shadow: none;
  cursor: pointer;
  backdrop-filter: blur(7px);
  transition: border-color 200ms ease, background 200ms ease, transform 200ms ease;
}

.ks-hero-controls__arrows button:hover,
.ks-hero-controls__arrows button:focus-visible {
  border-color: var(--ks-orange);
  color: #fff;
  background: var(--ks-orange);
  transform: translateY(-2px);
}

.ks-hero-controls__arrows svg {
  display: block;
  width: 21px;
  height: 21px;
  fill: none;
  stroke: currentColor;
  stroke-linecap: round;
  stroke-linejoin: round;
  stroke-width: 1.7;
}

.ks-hero-slider :focus-visible {
  outline: 2px solid #fff;
  outline-offset: 4px;
}

@media (max-width: 1180px) {
  .ks-hero-slider {
    --ks-shell: calc(100% - 64px);
  }
}

@media (max-width: 760px) {
  .ks-hero-slider {
    --ks-shell: calc(100% - 36px);
    min-height: 700px;
    height: min(760px, 100svh);
    max-height: 860px;
  }

  .ks-hero-slide__media {
    background-position: 61% center;
  }

  .ks-hero-slide__media--production {
    background-position: 66% center;
  }

  .ks-hero-slide__shade,
  .ks-hero-slide__shade--deep {
    background:
      linear-gradient(90deg, rgba(20, 14, 10, 0.88) 0%, rgba(20, 14, 10, 0.66) 52%, rgba(20, 14, 10, 0.14) 100%),
      linear-gradient(180deg, rgba(12, 8, 6, 0.28) 0%, transparent 25%, transparent 55%, rgba(12, 8, 6, 0.78) 100%);
  }

  .ks-hero-slide__content {
    justify-content: flex-end;
    padding-top: 32px;
    padding-bottom: 122px;
  }

  .ks-hero-slide__copy {
    width: 100%;
  }

  .ks-hero-slide__title {
    max-width: 520px;
    font-size: clamp(42px, 13vw, 64px);
  }

  .ks-hero-slide__time {
    margin-top: 10px;
    font-size: 24px;
  }

  .ks-hero-slide__time b {
    width: 47px;
    height: 47px;
    font-size: 31px;
  }

  .ks-hero-slide__lead {
    max-width: 460px;
    margin-top: 18px;
    font-size: 15px;
    line-height: 1.48;
  }

  .ks-hero-controls {
    grid-template-columns: auto 1fr auto;
    min-height: 78px;
    gap: 16px;
  }

  .ks-hero-controls__progress {
    display: none;
  }

  .ks-hero-controls__dots {
    justify-content: center;
  }

  .ks-hero-controls__arrows button {
    width: 42px;
    height: 42px;
  }

  .ks-hero-controls__arrows button:first-child {
    display: none;
  }

}

@media (max-width: 440px) {
  .ks-hero-slide__lead {
    max-width: 330px;
  }

}

@media (prefers-reduced-motion: reduce) {
  .ks-hero-slider *,
  .ks-hero-slider *::before,
  .ks-hero-slider *::after {
    transition-duration: 0.01ms !important;
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
  }

  .ks-hero-slide__media {
    transform: none !important;
  }
}
