.kemove-community-gallery {
  position: relative;
  padding-block: 44px 34px;
  font-family: var(--kemove-font-stack, Inter, Arial, sans-serif);
  background: #f5f7fa;
}

.kemove-community-gallery__inner {
  position: relative;
  max-width: var(--kemove-home-width, 1320px);
}

.kemove-community-gallery__head {
  display: flex;
  gap: 24px;
  align-items: flex-end;
  justify-content: space-between;
  margin-block-end: 22px;
}

.kemove-community-gallery__title {
  margin: 0;
  color: #111827;
  font-size: clamp(26px, 2.5vw, 36px);
  font-weight: 800;
  line-height: 1.1;
}

.kemove-community-gallery__title::after {
  display: inline-block;
  width: 9px;
  height: 9px;
  margin-inline-start: 10px;
  vertical-align: 45%;
  content: "";
  background: #0091ff;
  border-radius: 50%;
  box-shadow: 0 0 14px rgb(0 145 255 / 60%);
}

.kemove-community-gallery__text {
  max-width: 620px;
  margin: 10px 0 0;
  color: #6b7280;
  font-size: 14px;
  line-height: 1.55;
}

.kemove-community-gallery__button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 42px;
  padding: 0 18px;
  color: #006be6 !important;
  font-size: 13px;
  font-weight: 800;
  text-decoration: none;
  background: #fff;
  border: 1px solid rgb(0 145 255 / 20%);
  border-radius: 12px;
  box-shadow: 0 10px 30px rgb(15 23 42 / 5%);
}

.kemove-community-gallery__grid {
  display: grid;
  grid-template-columns: repeat(7, minmax(0, 1fr));
  gap: 12px;
}

.kemove-community-gallery__item {
  position: relative;
  aspect-ratio: 1 / 0.72;
  overflow: hidden;
  background: #eef2f7;
  border: 1px solid #e5e7eb;
  border-radius: 12px;
  box-shadow: 0 10px 30px rgb(15 23 42 / 5%);
}

.kemove-community-gallery__image,
.kemove-community-gallery__item img,
.kemove-community-gallery__item svg {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 340ms cubic-bezier(0.22, 1, 0.36, 1);
}

.kemove-community-gallery__kbot {
  position: absolute;
  right: -8px;
  bottom: -30px;
  width: min(128px, 14vw);
  pointer-events: none;
}

.kbot-community-image {
  display: block;
  width: 100%;
  height: auto;
  object-fit: contain;
}

@media (hover: hover) and (pointer: fine) {
  .kemove-community-gallery__item:hover img,
  .kemove-community-gallery__item:hover svg {
    transform: scale(1.045);
  }

  .kemove-community-gallery__button:hover {
    color: #fff !important;
    background: #0091ff;
  }
}

@media (max-width: 959px) {
  .kemove-community-gallery {
    padding-block: 34px 28px;
  }

  .kemove-community-gallery__head {
    align-items: flex-start;
    flex-direction: column;
  }

  .kemove-community-gallery__grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .kemove-community-gallery__kbot {
    display: none;
  }
}

@media (prefers-reduced-motion: reduce) {
  .kemove-community-gallery__image,
  .kemove-community-gallery__item img,
  .kemove-community-gallery__item svg {
    transition: none;
  }
}
/* KEMOVE homepage final community-gallery tuning */
.kemove-community-gallery {
  padding-block: 26px 26px !important;
}

.kemove-community-gallery__inner.page-width {
  max-width: min(var(--kemove-home-width, 1640px), calc(100vw - 96px)) !important;
  padding-inline: 0 !important;
}

.kemove-community-gallery__grid {
  grid-template-columns: repeat(7, minmax(0, 1fr));
  gap: 14px;
}

.kemove-community-gallery__item {
  aspect-ratio: 3 / 4 !important;
}

@media (max-width: 1180px) {
  .kemove-community-gallery__grid {
    grid-template-columns: repeat(4, minmax(0, 1fr));
  }
}

@media (max-width: 959px) {
  .kemove-community-gallery__inner.page-width {
    max-width: calc(100vw - 32px) !important;
  }

  .kemove-community-gallery__grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 12px;
  }
}
/* KEMOVE homepage final width parity with service/product sections */
.kemove-community-gallery__inner.page-width {
  max-width: min(var(--kemove-home-width, 1640px), calc(100vw - 96px)) !important;
  padding-inline: var(--page-padding) !important;
}

@media (max-width: 959px) {
  .kemove-community-gallery__inner.page-width {
    max-width: calc(100vw - 32px) !important;
    padding-inline: var(--page-padding) !important;
  }
}
/* KEMOVE homepage final community carousel */
.kemove-community-gallery__carousel {
  position: relative;
}

.kemove-community-gallery__viewport {
  overflow: hidden;
  scroll-behavior: smooth;
}

.kemove-community-gallery__grid {
  display: flex !important;
  grid-template-columns: none !important;
  gap: 14px !important;
  will-change: scroll-position;
}

.kemove-community-gallery__item {
  flex: 0 0 calc((100% - 70px) / 6);
  min-width: 0;
  aspect-ratio: 3 / 4 !important;
}

.kemove-community-gallery__arrow {
  position: absolute;
  z-index: 4;
  top: 50%;
  display: none;
  place-items: center;
  width: 38px;
  height: 58px;
  color: #111827;
  background: rgb(255 255 255 / 88%);
  border: 1px solid rgb(229 231 235 / 80%);
  border-radius: 999px;
  box-shadow: 0 14px 34px rgb(15 23 42 / 14%);
  transform: translateY(-50%);
  transition: opacity 180ms ease, background-color 180ms ease, transform 180ms ease;
}

.kemove-community-gallery.is-overflowing .kemove-community-gallery__arrow {
  display: grid;
}

.kemove-community-gallery__arrow--prev {
  left: 10px;
}

.kemove-community-gallery__arrow--next {
  right: 10px;
}

.kemove-community-gallery__arrow--prev svg {
  transform: rotate(180deg);
}

.kemove-community-gallery__arrow svg {
  width: 18px;
  height: 18px;
}

.kemove-community-gallery__arrow:disabled {
  opacity: 0;
  pointer-events: none;
}

@media (hover: hover) and (pointer: fine) {
  .kemove-community-gallery__arrow:hover {
    color: #fff;
    background: #0091ff;
    transform: translateY(-50%) scale(1.04);
  }
}

@media (max-width: 1180px) {
  .kemove-community-gallery__item {
    flex-basis: calc((100% - 42px) / 4);
  }
}

@media (max-width: 959px) {
  .kemove-community-gallery__viewport {
    overflow-x: auto;
    scrollbar-width: none;
  }

  .kemove-community-gallery__viewport::-webkit-scrollbar {
    display: none;
  }

  .kemove-community-gallery__item {
    flex-basis: calc((100% - 12px) / 2);
  }

  .kemove-community-gallery__arrow {
    width: 34px;
    height: 48px;
  }
}
/* KEMOVE homepage hard community carousel override */
body[data-page-type="index"] .kemove-community-gallery .kemove-community-gallery__viewport {
  overflow: hidden !important;
}

body[data-page-type="index"] .kemove-community-gallery .kemove-community-gallery__grid {
  display: flex !important;
  grid-template-columns: none !important;
  grid-auto-flow: column !important;
  gap: 14px !important;
  overflow: visible !important;
}

body[data-page-type="index"] .kemove-community-gallery .kemove-community-gallery__grid > .kemove-community-gallery__item {
  flex: 0 0 calc((100% - 70px) / 6) !important;
  width: calc((100% - 70px) / 6) !important;
  max-width: calc((100% - 70px) / 6) !important;
  min-width: calc((100% - 70px) / 6) !important;
  aspect-ratio: 3 / 4 !important;
}

body[data-page-type="index"] .kemove-community-gallery .kemove-community-gallery__arrow {
  display: grid !important;
}

body[data-page-type="index"] .kemove-community-gallery .kemove-community-gallery__arrow--prev {
  left: 12px !important;
}

body[data-page-type="index"] .kemove-community-gallery .kemove-community-gallery__arrow--next {
  right: 12px !important;
}

@media (max-width: 1180px) {
  body[data-page-type="index"] .kemove-community-gallery .kemove-community-gallery__grid > .kemove-community-gallery__item {
    flex-basis: calc((100% - 42px) / 4) !important;
    width: calc((100% - 42px) / 4) !important;
    max-width: calc((100% - 42px) / 4) !important;
    min-width: calc((100% - 42px) / 4) !important;
  }
}

@media (max-width: 959px) {
  body[data-page-type="index"] .kemove-community-gallery .kemove-community-gallery__viewport {
    overflow-x: auto !important;
  }

  body[data-page-type="index"] .kemove-community-gallery .kemove-community-gallery__grid > .kemove-community-gallery__item {
    flex-basis: calc((100% - 12px) / 2) !important;
    width: calc((100% - 12px) / 2) !important;
    max-width: calc((100% - 12px) / 2) !important;
    min-width: calc((100% - 12px) / 2) !important;
  }
}
/* KEMOVE community carousel editor/frontstore fallback */
.kemove-community-gallery[data-kemove-community-gallery] .kemove-community-gallery__viewport {
  overflow: hidden !important;
}

.kemove-community-gallery[data-kemove-community-gallery] .kemove-community-gallery__grid {
  display: flex !important;
  grid-template-columns: none !important;
  gap: 14px !important;
}

.kemove-community-gallery[data-kemove-community-gallery] .kemove-community-gallery__grid > .kemove-community-gallery__item {
  flex: 0 0 calc((100% - 70px) / 6) !important;
  width: calc((100% - 70px) / 6) !important;
  max-width: calc((100% - 70px) / 6) !important;
  min-width: calc((100% - 70px) / 6) !important;
}

.kemove-community-gallery[data-kemove-community-gallery] .kemove-community-gallery__arrow {
  display: grid !important;
}

.kemove-community-gallery[data-kemove-community-gallery] .kemove-community-gallery__arrow:disabled {
  opacity: 0.38 !important;
}

@media (max-width: 1180px) {
  .kemove-community-gallery[data-kemove-community-gallery] .kemove-community-gallery__grid > .kemove-community-gallery__item {
    flex-basis: calc((100% - 42px) / 4) !important;
    width: calc((100% - 42px) / 4) !important;
    max-width: calc((100% - 42px) / 4) !important;
    min-width: calc((100% - 42px) / 4) !important;
  }
}

@media (max-width: 959px) {
  .kemove-community-gallery[data-kemove-community-gallery] .kemove-community-gallery__viewport {
    overflow-x: auto !important;
  }

  .kemove-community-gallery[data-kemove-community-gallery] .kemove-community-gallery__grid > .kemove-community-gallery__item {
    flex-basis: calc((100% - 12px) / 2) !important;
    width: calc((100% - 12px) / 2) !important;
    max-width: calc((100% - 12px) / 2) !important;
    min-width: calc((100% - 12px) / 2) !important;
  }
}
/* KEMOVE community carousel block-wrapper fix */
.kemove-community-gallery[data-kemove-community-gallery] .kemove-community-gallery__grid > * {
  flex: 0 0 calc((100% - 70px) / 6) !important;
  width: calc((100% - 70px) / 6) !important;
  max-width: calc((100% - 70px) / 6) !important;
  min-width: calc((100% - 70px) / 6) !important;
}

.kemove-community-gallery[data-kemove-community-gallery] .kemove-community-gallery__grid > * > .kemove-community-gallery__item,
.kemove-community-gallery[data-kemove-community-gallery] .kemove-community-gallery__grid > .kemove-community-gallery__item {
  width: 100% !important;
  max-width: none !important;
  min-width: 0 !important;
}

body[data-page-type="index"] .kemove-community-gallery .kemove-community-gallery__grid > * {
  flex: 0 0 calc((100% - 70px) / 6) !important;
  width: calc((100% - 70px) / 6) !important;
  max-width: calc((100% - 70px) / 6) !important;
  min-width: calc((100% - 70px) / 6) !important;
}

body[data-page-type="index"] .kemove-community-gallery .kemove-community-gallery__grid > * > .kemove-community-gallery__item,
body[data-page-type="index"] .kemove-community-gallery .kemove-community-gallery__grid > .kemove-community-gallery__item {
  width: 100% !important;
  max-width: none !important;
  min-width: 0 !important;
}

@media (max-width: 1180px) {
  .kemove-community-gallery[data-kemove-community-gallery] .kemove-community-gallery__grid > *,
  body[data-page-type="index"] .kemove-community-gallery .kemove-community-gallery__grid > * {
    flex-basis: calc((100% - 42px) / 4) !important;
    width: calc((100% - 42px) / 4) !important;
    max-width: calc((100% - 42px) / 4) !important;
    min-width: calc((100% - 42px) / 4) !important;
  }
}

@media (max-width: 959px) {
  .kemove-community-gallery[data-kemove-community-gallery] .kemove-community-gallery__grid > *,
  body[data-page-type="index"] .kemove-community-gallery .kemove-community-gallery__grid > * {
    flex-basis: calc((100% - 12px) / 2) !important;
    width: calc((100% - 12px) / 2) !important;
    max-width: calc((100% - 12px) / 2) !important;
    min-width: calc((100% - 12px) / 2) !important;
  }
}
