/* =========================================================
   Gallery Section Layout
========================================================= */

.sec006 {
  width: 100%;
  margin: 0 auto 60px;
  color: #222222;
  position: relative;
  font-size: 14px;
  line-height: 1.7;
  letter-spacing: 0;
}

.sec006 > .ttl_w01,
.sec006 > p {
  width: 380px;
  margin-left: auto;
  margin-right: auto;
}

.sec006 > p {
  margin-bottom: 24px;
  text-align: center;
}

@media screen and (max-width: 768px) {
  .sec006 {
    width: 100%;
    margin: 0 auto 50px;
  }

  .sec006 > .ttl_w01,
  .sec006 > p {
    width: 80%;
  }

  .pbtm_ex {
    padding-bottom: 30px;
  }
}

/* =========================================================
   Gallery Slider
========================================================= */

:root {
  --gallery-gap: 2px;
  --gallery-modal-pc-width: 600px;
  --gallery-modal-sp-width: calc(100vw - 24px);
}

.gallerySlider {
  width: 100%;
  margin-top: 16px;
  user-select: none;
  -webkit-user-select: none;
  overflow: hidden;
  position: relative;
}

.gallerySlider,
.gallerySlider * {
  -webkit-user-drag: none;
}

.gallerySlider-viewport {
  width: 100%;
  overflow: hidden;
  position: relative;
  cursor: grab;
  touch-action: pan-y;
}

.gallerySlider.is-dragging .gallerySlider-viewport {
  cursor: grabbing;
}

.gallerySlider-track {
  display: flex;
  flex-wrap: nowrap;
  gap: var(--gallery-gap);
  list-style: none;
  padding: 0;
  margin: 0;
  width: max-content;
  will-change: transform;
  transform: translate3d(0, 0, 0);
}

.gallerySlider-item {
  flex: 0 0 320px;
  width: 320px;
}

@media screen and (max-width: 768px) {
  .gallerySlider-item {
    flex: 0 0 calc((100vw - 24px - var(--gallery-gap)) / 1.5);
    width: calc((100vw - 24px - var(--gallery-gap)) / 1.5);
  }
}

.gallerySlider-thumb {
  display: block;
  width: 100%;
  padding: 0;
  margin: 0;
  border: 0;
  background: none;
  appearance: none;
  -webkit-appearance: none;
  cursor: pointer;
  overflow: hidden;
  user-select: none;
  -webkit-user-select: none;
  -webkit-user-drag: none;
}

.gallerySlider-thumb img {
  display: block;
  width: 100%;
  aspect-ratio: 4 / 3;
  object-fit: cover;
  height: auto;
  user-select: none;
  -webkit-user-select: none;
  -webkit-user-drag: none;
}

/* =========================================================
   Gallery Modal
========================================================= */

.galleryModal {
  position: fixed;
  inset: 0;
  z-index: 999999;
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
  transition: opacity .25s ease, visibility 0s linear .25s;
}

.galleryModal.is-open {
  opacity: 1;
  visibility: visible;
  pointer-events: auto;
  transition: opacity .25s ease;
}

.galleryModal-bg {
  position: absolute;
  inset: 0;
  background: rgba(0, 0, 0, 0.68);
}

.galleryModal-inner {
  position: relative;
  z-index: 2;
  min-height: 100%;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 24px 16px 30px;
  box-sizing: border-box;
}

.galleryModal-imageWrap {
  width: min(var(--gallery-modal-pc-width), calc(100vw - 80px));
}

.galleryModal-image {
  display: block;
  width: 100%;
  height: auto;
  margin: 0 auto;
}

.galleryModal-controls {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 18px;
  margin-top: 18px;
}

.galleryModal-btn {
  width: 40px;
  height: 40px;
  background: none;
  border: 0;
  padding: 0;
  appearance: none;
  -webkit-appearance: none;
  cursor: pointer;
  position: relative;
}

.galleryModal-icon {
  display: block;
  width: 100%;
  height: 100%;
  position: relative;
}

/* prev */
.galleryModal-icon-prev::before,
.galleryModal-icon-prev::after,
.galleryModal-btn-prev::after {
  content: "";
  position: absolute;
  top: 50%;
  height: 1px;
  background: #fff;
}

.galleryModal-btn-prev::after {
  left: 10px;
  width: 18px;
  transform: translateY(-50%);
}

.galleryModal-icon-prev::before,
.galleryModal-icon-prev::after {
  left: 10px;
  width: 10px;
  transform-origin: left center;
}

.galleryModal-icon-prev::before {
  transform: translateY(-50%) rotate(45deg);
}

.galleryModal-icon-prev::after {
  transform: translateY(-50%) rotate(-45deg);
}

/* next */
.galleryModal-icon-next::before,
.galleryModal-icon-next::after,
.galleryModal-btn-next::after {
  content: "";
  position: absolute;
  top: 50%;
  height: 1px;
  background: #fff;
}

.galleryModal-btn-next::after {
  right: 10px;
  width: 18px;
  transform: translateY(-50%);
}

.galleryModal-icon-next::before,
.galleryModal-icon-next::after {
  right: 10px;
  width: 10px;
  transform-origin: right center;
}

.galleryModal-icon-next::before {
  transform: translateY(-50%) rotate(45deg);
}

.galleryModal-icon-next::after {
  transform: translateY(-50%) rotate(-45deg);
}

/* close */
.galleryModal-icon-close::before,
.galleryModal-icon-close::after {
  content: "";
  position: absolute;
  left: 9px;
  top: 50%;
  width: 22px;
  height: 1px;
  background: #d3d3d3;
}

.galleryModal-icon-close::before {
  transform: translateY(-50%) rotate(45deg);
}

.galleryModal-icon-close::after {
  transform: translateY(-50%) rotate(-45deg);
}

@media screen and (max-width: 768px) {
  .galleryModal-inner {
    padding: 20px 12px 24px;
  }

  .galleryModal-imageWrap {
    width: var(--gallery-modal-sp-width);
  }

  .galleryModal-controls {
    margin-top: 14px;
    gap: 10px;
  }

  .galleryModal-btn {
    width: 36px;
    height: 36px;
  }

  .galleryModal-btn-prev::after,
  .galleryModal-btn-next::after {
    width: 16px;
  }

  .galleryModal-icon-prev::before,
  .galleryModal-icon-prev::after,
  .galleryModal-icon-next::before,
  .galleryModal-icon-next::after {
    width: 9px;
  }

  .galleryModal-icon-close::before,
  .galleryModal-icon-close::after {
    width: 20px;
    left: 8px;
  }
}