.offices-section {
  position: relative;
  overflow: hidden;
  padding: 90px 0;
  background: linear-gradient(135deg, rgba(33, 169, 225, 0.08), rgba(229, 134, 11, 0.06)), #f8fbfd;
}

.offices-section .section-heading {
  margin-bottom: 38px;
}

.offices-section .offices-slider {
  max-width: 980px;
  margin: 0 auto;
  padding: 8px 64px 58px;
}

.offices-section .swiper-wrapper {
  align-items: stretch;
}

.offices-section .office-slide {
  height: auto;
}

.offices-section .office-card {
  display: grid;
  grid-template-columns: minmax(0, 1.05fr) minmax(320px, 0.95fr);
  min-height: 430px;
  height: 100%;
  overflow: hidden;
  border: 1px solid rgba(16, 24, 32, 0.08);
  border-radius: 22px;
  background: #ffffff;
  box-shadow: 0 24px 60px rgba(16, 24, 32, 0.12);
  transition: transform 0.3s ease, box-shadow 0.3s ease, border-color 0.3s ease;
}

.offices-section .office-card:hover {
  transform: translateY(-6px);
  border-color: rgba(33, 169, 225, 0.28);
  box-shadow: 0 30px 70px rgba(16, 24, 32, 0.16);
}

.offices-section .office-card:hover .office-image {
  transform: scale(1.04);
}

.offices-section .office-card__image {
  position: relative;
  min-height: 430px;
  margin: 0;
  overflow: hidden;
  background: #101820;
  padding: 12px;
}

.offices-section .office-card__image::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, rgba(16, 24, 32, 0.02), rgba(16, 24, 32, 0.18));
  pointer-events: none;
}

.offices-section .office-image {
  width: 100%;
  height: 100%;
  min-height: 430px;
  display: block;
  object-fit: cover;
  transition: transform 0.45s ease;
}

.offices-section .office-card__gallery {
  display: grid;
  min-height: 406px;
  height: 100%;
  gap: 10px;
}

.offices-section .office-card__gallery--count-1 {
  grid-template-columns: 1fr;
}

.offices-section .office-card__gallery--count-2 {
  grid-template-columns: 1fr 1fr;
}

.offices-section .office-card__gallery--count-3 {
  grid-template-columns: minmax(0, 1.35fr) minmax(170px, 0.85fr);
  grid-template-rows: repeat(2, minmax(0, 1fr));
}

.offices-section .office-card__gallery--count-3 .office-card__gallery-item--main {
  grid-row: 1 / 3;
}

.offices-section .office-card__gallery-item {
  position: relative;
  overflow: hidden;
  border-radius: 14px;
  background: #dfeaf0;
  border: 0;
  padding: 0;
  cursor: zoom-in;
}

.offices-section .office-card__gallery .office-image {
  min-height: 0;
}

.offices-section .office-card__zoom-label {
  position: absolute;
  right: 12px;
  bottom: 12px;
  z-index: 2;
  padding: 7px 11px;
  border-radius: 999px;
  background: rgba(16, 24, 32, 0.78);
  color: #ffffff;
  font-size: 12px;
  font-weight: 700;
  line-height: 1;
  opacity: 0;
  transform: translateY(6px);
  transition: opacity 0.22s ease, transform 0.22s ease;
}

.offices-section .office-card__gallery-item::after {
  content: "";
  position: absolute;
  inset: 0;
  background: rgba(16, 24, 32, 0.12);
  opacity: 0;
  transition: opacity 0.22s ease;
}

.offices-section .office-card__gallery-item:hover::after,
.offices-section .office-card__gallery-item:focus-visible::after {
  opacity: 1;
}

.offices-section .office-card__gallery-item:hover .office-card__zoom-label,
.offices-section .office-card__gallery-item:focus-visible .office-card__zoom-label {
  opacity: 1;
  transform: translateY(0);
}

.offices-section .office-card__body {
  display: flex;
  flex-direction: column;
  justify-content: center;
  padding: 42px;
}

.offices-section .office-card__title {
  margin: 0 0 24px;
  color: #000000;
  font-size: 34px;
  font-weight: 700;
  line-height: 1.18;
}

.offices-section .office-card__detail {
  display: grid;
  grid-template-columns: 42px minmax(0, 1fr);
  gap: 14px;
  align-items: flex-start;
  color: #898787;
  font-size: 17px;
  line-height: 1.65;
}

.offices-section .office-card__detail + .office-card__detail {
  margin-top: 18px;
}

.offices-section .office-card__detail address {
  margin: 0;
  font-style: normal;
}

.offices-section .office-card__detail a {
  color: #000000;
  text-decoration: none;
  transition: color 0.2s ease;
}

.offices-section .office-card__detail a:hover {
  color: #21A9E1;
}

.offices-section .office-card__phone-list {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 4px;
}

.offices-section .office-card__icon {
  display: inline-flex;
  width: 42px;
  height: 42px;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
  background: rgba(33, 169, 225, 0.11);
  color: #21A9E1;
  flex: 0 0 auto;
}

.offices-section .office-card__icon svg {
  width: 20px;
  height: 20px;
  fill: currentColor;
}

.offices-section .swiper-button-prev,
.offices-section .swiper-button-next {
  width: 48px;
  height: 48px;
  margin-top: -24px;
  border: 1px solid rgba(33, 169, 225, 0.2);
  border-radius: 50%;
  background: #ffffff;
  color: #21A9E1;
  box-shadow: 0 12px 32px rgba(16, 24, 32, 0.14);
  transition: transform 0.2s ease, background-color 0.2s ease, color 0.2s ease, box-shadow 0.2s ease;
}

.offices-section .swiper-button-prev::after,
.offices-section .swiper-button-next::after {
  font-size: 18px;
  font-weight: 700;
}

.offices-section .swiper-button-prev:hover,
.offices-section .swiper-button-next:hover {
  transform: translateY(-2px);
  background: #21A9E1;
  color: #ffffff;
  box-shadow: 0 16px 36px rgba(33, 169, 225, 0.28);
}

.offices-section .swiper-button-prev {
  left: 0;
}

.offices-section .swiper-button-next {
  right: 0;
}

.offices-section .swiper-pagination {
  bottom: 10px;
}

.offices-section .swiper-pagination-bullet {
  width: 10px;
  height: 10px;
  background: rgba(16, 24, 32, 0.28);
  opacity: 1;
  transition: width 0.2s ease, border-radius 0.2s ease, background-color 0.2s ease;
}

.offices-section .swiper-pagination-bullet-active {
  width: 28px;
  border-radius: 999px;
  background: #21A9E1;
}

@media (max-width: 991px) {
  .offices-section {
    padding: 70px 0;
  }

  .offices-section .offices-slider {
    padding-right: 50px;
    padding-left: 50px;
  }

  .offices-section .office-card {
    grid-template-columns: 1fr;
    min-height: 0;
  }

  .offices-section .office-card__image,
  .offices-section .office-image {
    min-height: 320px;
  }

  .offices-section .office-card__gallery {
    min-height: 296px;
  }

  .offices-section .office-card__body {
    padding: 32px;
  }

  .offices-section .office-card__title {
    font-size: 28px;
  }
}

body.office-gallery-open {
  overflow: hidden;
}

.office-gallery-modal {
  position: fixed;
  inset: 0;
  z-index: 9999;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 72px 88px;
  background: rgba(8, 15, 22, 0.88);
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
  transition: opacity 0.24s ease, visibility 0.24s ease;
}

.office-gallery-modal.is-open {
  opacity: 1;
  visibility: visible;
  pointer-events: auto;
}

.office-gallery-modal__figure {
  width: min(1120px, 100%);
  margin: 0;
  text-align: center;
}

.office-gallery-modal__image {
  max-width: 100%;
  max-height: calc(100vh - 180px);
  border-radius: 16px;
  background: #101820;
  box-shadow: 0 30px 90px rgba(0, 0, 0, 0.42);
  object-fit: contain;
}

.office-gallery-modal__caption {
  margin-top: 14px;
  color: #ffffff;
  font-size: 15px;
  font-weight: 600;
}

.office-gallery-modal__close,
.office-gallery-modal__nav {
  position: absolute;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border: 1px solid rgba(255, 255, 255, 0.22);
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.12);
  color: #ffffff;
  cursor: pointer;
  backdrop-filter: blur(10px);
  transition: transform 0.2s ease, background-color 0.2s ease, border-color 0.2s ease;
}

.office-gallery-modal__close:hover,
.office-gallery-modal__nav:hover,
.office-gallery-modal__close:focus-visible,
.office-gallery-modal__nav:focus-visible {
  transform: translateY(-2px);
  border-color: rgba(33, 169, 225, 0.55);
  background: rgba(33, 169, 225, 0.75);
  outline: none;
}

.office-gallery-modal__close {
  top: 24px;
  right: 24px;
  width: 48px;
  height: 48px;
  font-size: 34px;
  line-height: 1;
}

.office-gallery-modal__nav {
  top: 50%;
  width: 56px;
  height: 56px;
}

.office-gallery-modal__nav::before {
  content: "";
  width: 14px;
  height: 14px;
  border-top: 3px solid currentColor;
  border-right: 3px solid currentColor;
}

.office-gallery-modal__nav--prev {
  left: 24px;
}

.office-gallery-modal__nav--prev::before {
  transform: rotate(-135deg);
  margin-left: 5px;
}

.office-gallery-modal__nav--next {
  right: 24px;
}

.office-gallery-modal__nav--next::before {
  transform: rotate(45deg);
  margin-right: 5px;
}

@media (max-width: 767px) {
  .office-gallery-modal {
    padding: 70px 16px 60px;
  }

  .office-gallery-modal__image {
    max-height: calc(100vh - 180px);
    border-radius: 12px;
  }

  .office-gallery-modal__close {
    top: 16px;
    right: 16px;
    width: 42px;
    height: 42px;
  }

  .office-gallery-modal__nav {
    top: auto;
    bottom: 16px;
    width: 44px;
    height: 44px;
  }

  .office-gallery-modal__nav--prev {
    left: calc(50% - 58px);
  }

  .office-gallery-modal__nav--next {
    right: calc(50% - 58px);
  }
}

@media (max-width: 767px) {
  .offices-section {
    padding: 58px 0;
  }

  .offices-section .section-heading {
    margin-bottom: 26px;
  }

  .offices-section .offices-slider {
    padding: 4px 0 52px;
  }

  .offices-section .office-card {
    border-radius: 18px;
  }

  .offices-section .office-card__image,
  .offices-section .office-image {
    min-height: 250px;
  }

  .offices-section .office-card__image {
    padding: 10px;
  }

  .offices-section .office-card__gallery {
    min-height: 240px;
    gap: 8px;
  }

  .offices-section .office-card__gallery--count-2 {
    grid-template-columns: 1fr 1fr;
  }

  .offices-section .office-card__gallery--count-3 {
    grid-template-columns: 1fr 1fr;
    grid-template-rows: 1.2fr 0.8fr;
  }

  .offices-section .office-card__gallery--count-3 .office-card__gallery-item--main {
    grid-column: 1 / 3;
    grid-row: auto;
  }

  .offices-section .office-card__gallery-item {
    border-radius: 12px;
  }

  .offices-section .office-card__body {
    padding: 26px 22px 28px;
  }

  .offices-section .office-card__title {
    margin-bottom: 18px;
    font-size: 24px;
  }

  .offices-section .office-card__detail {
    grid-template-columns: 36px minmax(0, 1fr);
    gap: 12px;
    font-size: 15px;
  }

  .offices-section .office-card__icon {
    width: 36px;
    height: 36px;
  }

  .offices-section .office-card__icon svg {
    width: 18px;
    height: 18px;
  }

  .offices-section .swiper-button-prev,
  .offices-section .swiper-button-next {
    top: auto;
    bottom: 0;
    width: 42px;
    height: 42px;
    margin-top: 0;
  }

  .offices-section .swiper-button-prev {
    left: calc(50% - 78px);
  }

  .offices-section .swiper-button-next {
    right: calc(50% - 78px);
  }

  .offices-section .swiper-pagination {
    bottom: 12px;
    padding: 0 92px;
  }
}
