:root {
  --zs-cases-title: #000;
  --zs-cases-text: #777;
  --zs-cases-line: #000;
}

.zs-cases-main {
  background: #fff;
}

.zs-cases-banner {
  position: relative;
  min-height: 440px;
  overflow: hidden;
}

.zs-cases-banner img {
  position: absolute;
  inset: 0;
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.zs-cases-banner__content {
  position: absolute;
  inset: 0;
  z-index: 1;
  display: flex;
  align-items: center;
}

.zs-cases-banner__inner {
  max-width: 860px;
  color: #fff;
}

.zs-cases-banner__inner h2 {
  margin: 0;
  font-size: clamp(24px, 3.2vw, 34px);
  line-height: 1.2;
  font-weight: 300;
  letter-spacing: 0.01em;
  text-transform: uppercase;
}

.zs-cases-banner__inner p {
  max-width: 760px;
  margin: 16px 0 0;
  color: rgba(255, 255, 255, 0.96);
  font-size: clamp(16px, 2vw, 24px);
  line-height: 1.8;
  font-weight: 300;
}

.zs-cases-breadcrumb {
  background: #f3f3f3;
}

.zs-cases-breadcrumb p {
  margin: 0;
  padding: 16px 0;
  color: #7d7d7d;
  font-size: 12px;
  line-height: 1.7;
}

.zs-cases-breadcrumb a,
.zs-cases-breadcrumb strong {
  color: inherit;
}

.zs-cases-breadcrumb span {
  margin: 0 6px;
  color: #b7b7b7;
}

.zs-cases-gallery {
  padding: 50px 0 64px;
}

.zs-cases-gallery__head {
  margin-bottom: 22px;
  text-align: center;
}

.zs-cases-gallery__head h2 {
  margin: 0;
  color: var(--zs-cases-title);
  font-size: 30px;
  line-height: 1.2;
  font-weight: 700;
}

.zs-cases-gallery__line {
  width: 100%;
  height: 2px;
  margin-top: 28px;
  background: var(--zs-cases-line);
}

.zs-cases-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 10px;
  margin: 0;
  padding: 0;
  list-style: none;
}

.zs-cases-card {
  display: block;
  width: 100%;
  padding: 0;
  border: 0;
  background: transparent;
  cursor: pointer;
}

.zs-cases-card img {
  display: block;
  width: 100%;
  height: auto;
  transition: opacity 0.22s ease, transform 0.22s ease;
}

.zs-cases-card:hover img,
.zs-cases-card:focus-visible img {
  opacity: 0.9;
}

.zs-cases-card:focus-visible {
  outline: 2px solid var(--zs-green);
  outline-offset: 4px;
}

.zs-cases-lightbox {
  position: fixed;
  inset: 0;
  z-index: 1300;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 40px;
  background: rgba(0, 0, 0, 0.86);
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
  transition: opacity 0.2s ease, visibility 0.2s ease;
}

.zs-cases-lightbox.is-open {
  opacity: 1;
  visibility: visible;
  pointer-events: auto;
}

.zs-cases-lightbox__stage {
  display: flex;
  align-items: center;
  justify-content: center;
  width: min(92vw, 1100px);
  height: min(82vh, 760px);
}

.zs-cases-lightbox__stage img {
  display: block;
  max-width: 100%;
  max-height: 100%;
  object-fit: contain;
  box-shadow: 0 18px 55px rgba(0, 0, 0, 0.35);
}

.zs-cases-lightbox__close,
.zs-cases-lightbox__nav {
  position: absolute;
  display: flex;
  align-items: center;
  justify-content: center;
  border: 0;
  background: transparent;
  color: #fff;
  cursor: pointer;
}

.zs-cases-lightbox__close {
  top: 20px;
  right: 22px;
  width: 44px;
  height: 44px;
  font-size: 34px;
  line-height: 1;
}

.zs-cases-lightbox__nav {
  top: 50%;
  width: 56px;
  height: 56px;
  margin-top: -28px;
}

.zs-cases-lightbox__nav--prev {
  left: 24px;
}

.zs-cases-lightbox__nav--next {
  right: 24px;
}

.zs-cases-lightbox__nav svg {
  width: 32px;
  height: 32px;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.8;
  stroke-linecap: round;
  stroke-linejoin: round;
}

@media (max-width: 1199px) {
  .zs-cases-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }
}

@media (max-width: 767px) {
  .zs-cases-banner {
    min-height: 280px;
  }

  .zs-cases-banner__inner h2 {
    font-size: 24px;
    line-height: 1.3;
  }

  .zs-cases-banner__inner p {
    margin-top: 12px;
    font-size: 14px;
    line-height: 1.75;
  }

  .zs-cases-breadcrumb p {
    padding: 16px 0;
    font-size: 14px;
    line-height: 1.6;
  }

  .zs-cases-gallery {
    padding: 40px 0 48px;
  }

  .zs-cases-gallery__head h2 {
    font-size: 28px;
  }

  .zs-cases-gallery__line {
    margin-top: 22px;
  }

  .zs-cases-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .zs-cases-lightbox {
    padding: 20px;
  }

  .zs-cases-lightbox__nav {
    width: 44px;
    height: 44px;
    margin-top: -22px;
  }

  .zs-cases-lightbox__nav--prev {
    left: 8px;
  }

  .zs-cases-lightbox__nav--next {
    right: 8px;
  }

  .zs-cases-lightbox__close {
    top: 10px;
    right: 12px;
  }
}
