.iw-sectors {
  background: #dcdcdc;
  padding: clamp(2.5rem, 4vw, 4rem) 0;
}

.iw-sectors__header {
  margin: 0 0 clamp(1.4rem, 2vw, 2rem);
  padding: 0 5%;
}

.iw-sectors__title {
  margin: 0;
  text-align: center;
  color: #616966;
  font-family: 'Antic Didone', Georgia, "Times New Roman", serif;
  font-weight: 400;
  font-size: clamp(2rem, 2.8vw, 3rem);
  line-height: 1.05;
}

.iw-sectors__rows {
  display: grid;
  gap: 0;
}

.iw-sectors__row {
  display: flex;
  align-items: stretch;
  width: 100%;
  min-height: var(--iw-sector-h, 560px);
  isolation: isolate;
}

.iw-sectors__card {
  position: relative;
  flex: 1 1 0;
  min-width: 0;
  min-height: var(--iw-sector-h, 560px);
  background-position: center;
  background-size: cover;
  background-repeat: no-repeat;
  overflow: hidden;
  transition: flex-grow 650ms cubic-bezier(0.2, 0.8, 0.2, 1), opacity 380ms ease;
  will-change: flex-grow, opacity;
}

.iw-sectors__row:hover .iw-sectors__card {
  flex-grow: 0;
  opacity: 0;
  pointer-events: none;
}

.iw-sectors__row:hover .iw-sectors__card:hover,
.iw-sectors__row:hover .iw-sectors__card:focus-within {
  flex-grow: 6;
  opacity: 1;
  pointer-events: auto;
}

.iw-sectors__link {
  position: relative;
  display: block;
  width: 100%;
  height: 100%;
  text-decoration: none;
  color: #fff;
  overflow: hidden;
}

.iw-sectors__link::after {
  content: "";
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  height: 50%;
  background: rgba(0, 0, 0, 0.7);
  transform: translateY(102%);
  transition: transform 700ms cubic-bezier(0.22, 1, 0.36, 1);
  z-index: 1;
}

.iw-sectors__overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, rgba(12, 12, 12, 0.75) 0%, rgba(12, 12, 12, 0.35) 100%);
  transition: background 300ms ease;
  z-index: 0;
}

.iw-sectors__card:hover .iw-sectors__overlay,
.iw-sectors__card:focus-within .iw-sectors__overlay {
  background: linear-gradient(180deg, rgba(12, 12, 12, 0.75) 0%, rgba(12, 12, 12, 0.35) 100%);
}

.iw-sectors__content {
  position: absolute;
  inset: auto 0 14%;
  z-index: 2;
  display: grid;
  justify-items: center;
  gap: 1rem;
  padding: 0 1.2rem;
  opacity: 1;
  transform: translateY(0);
  transition: opacity 280ms ease, transform 280ms ease;
}

.iw-sectors__row:hover .iw-sectors__content {
  opacity: 0;
  transform: translateY(10px);
  pointer-events: none;
}

.iw-sectors__row:hover .iw-sectors__card:hover .iw-sectors__content,
.iw-sectors__row:hover .iw-sectors__card:focus-within .iw-sectors__content {
  opacity: 1;
  transform: translateY(0);
  pointer-events: auto;
  transition-delay: 140ms;
}

.iw-sectors__row:not(:hover) .iw-sectors__content {
  transition-delay: 260ms;
}

.iw-sectors__card-title {
  margin: 0;
  color: #fff;
  font-family: 'Antic Didone', Georgia, "Times New Roman", serif;
  font-weight: 400;
  font-size: clamp(2rem, 2.2vw, 3.3rem);
  line-height: 1.05;
  text-align: center;
  text-wrap: balance;
}

.iw-sectors__btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 112px;
  min-height: 44px;
  padding: 0.6rem 1rem;
  border-radius: 0;
  background: #ed8025;
  color: #fff;
  font-size: 1rem;
  font-weight: 600;
  line-height: 1;
  border: 1px solid #ed8025;
  transition: background-color 250ms ease, color 250ms ease, border-color 250ms ease;
}

.iw-sectors__card:hover .iw-sectors__link::after,
.iw-sectors__card:focus-within .iw-sectors__link::after {
  transform: translateY(0);
}

.iw-sectors__card:hover .iw-sectors__btn,
.iw-sectors__card:focus-within .iw-sectors__btn {
  background: transparent;
  color: #fff;
  border-color: #fff;
}

.iw-sectors__link:focus-visible {
  outline: 2px solid #ed8025;
  outline-offset: -2px;
}

@media (max-width: 980px) {
  .iw-sectors {
    padding: 2rem 0;
  }

  .iw-sectors__header {
    padding: 0 1rem;
    margin-bottom: 1rem;
  }

  .iw-sectors__row {
    display: grid;
    grid-template-columns: 1fr;
    min-height: 0;
  }

  .iw-sectors__card {
    min-height: clamp(260px, 62vw, 420px);
    transition: none;
  }

  .iw-sectors__row:hover .iw-sectors__card,
  .iw-sectors__row:hover .iw-sectors__card:hover,
  .iw-sectors__row:hover .iw-sectors__card:focus-within {
    flex-grow: 1;
  }

  .iw-sectors__content {
    inset: auto 0 10%;
  }

  .iw-sectors__link::after {
    display: none;
  }
}
