/* gallery / skin_3 — 슬라이더형(썸네일) */

.section-gallery-skin-3 {
    width: 100%;
    box-sizing: border-box;
}

.section-gallery-skin-3 .section-gallery__inner {
    max-width: var(--inner-width);
    margin: 0 auto;
    box-sizing: border-box;
    position: relative;
}

.section-gallery-skin-3 .section-gallery__title {
    margin: 0;
    font-weight: 700;
    line-height: 1.3;
}

.section-gallery-skin-3 .section-gallery__desc {
    margin: 0;
    line-height: 1.6;
    word-break: keep-all;
}

/* 슬라이드 영역 — 화살표는 콘텐츠 박스 바깥(좌우)으로 빼냄 */
.section-gallery-skin-3 .section-gallery-s3__nav-wrap {
    position: relative;
    padding: 0;
}

/* ── Swiper 필수 레이아웃 자체 정의 (swiper-bundle.css 미로드 대비) ── */
.section-gallery-skin-3 .swiper {
    position: relative;
    overflow: hidden;
}
.section-gallery-skin-3 .swiper-wrapper {
    position: relative;
    display: flex;
    box-sizing: content-box;
}
.section-gallery-skin-3 .swiper-slide {
    flex-shrink: 0;
    position: relative;
}
.section-gallery-skin-3 .section-gallery-s3__main {
    width: 100%;
    overflow: hidden;
}
.section-gallery-skin-3 .section-gallery__slide {
    height: auto;
    min-width: 0;
}

/* 메인 미디어 */
.section-gallery-skin-3 .section-gallery__media {
    position: relative;
    width: 100%;
    overflow: hidden;
    background: #f4f4f5;
}
.section-gallery-skin-3 .section-gallery__img {
    display: block;
    width: 100%;
    height: 100%;
    object-fit: cover;
}

/* 썸네일 */
.section-gallery-skin-3 .section-gallery-s3__thumb {
    height: auto;
    min-width: 0;
    cursor: pointer;
}
.section-gallery-skin-3 .section-gallery-s3__thumb-media {
    position: relative;
    width: 100%;
    overflow: hidden;
    background: #f4f4f5;
    transition: opacity 0.15s;
    opacity: 0.55;
}
/* 선택 테두리 — 이미지 위에 inset 으로 그려 swiper overflow 에 잘리지 않게 */
.section-gallery-skin-3 .section-gallery-s3__thumb-media::after {
    content: '';
    position: absolute;
    inset: 0;
    border-radius: inherit;
    pointer-events: none;
    opacity: 0;
    transition: opacity 0.15s;
    z-index: 2;
}
/* .section-gallery-skin-3 .section-gallery-s3__thumb:hover .section-gallery-s3__thumb-media {
    opacity: 0.85;
} */
.section-gallery-skin-3 .section-gallery-s3__thumb.is-active .section-gallery-s3__thumb-media {
    opacity: 1;
}
.section-gallery-skin-3 .section-gallery-s3__thumb-img {
    display: block;
    width: 100%;
    height: 100%;
    object-fit: cover;
}

/* 아이템 캡션 (메인 큰 이미지 / 썸네일 공용) — 정렬·폰트·배경은 render.php가 주입 */
.section-gallery-skin-3 .section-gallery-s3__cap {
    position: absolute;
    inset: 0;
    display: flex;
    flex-direction: column;
    pointer-events: none;
    z-index: 3;
}
.section-gallery-skin-3 .section-gallery-s3__cap-inner {
    width: 100%;
    box-sizing: border-box;
    min-width: 0;
}
.section-gallery-skin-3 .section-gallery-s3__cap-title {
    font-weight: 700;
    line-height: 1.3;
    word-break: keep-all;
    text-shadow: 0 1px 3px rgba(0, 0, 0, 0.45);
}
.section-gallery-skin-3 .section-gallery-s3__cap-desc {
    margin-top: 4px;
    line-height: 1.5;
    word-break: keep-all;
    white-space: normal;
    text-shadow: 0 1px 3px rgba(0, 0, 0, 0.45);
}

/* 화살표 — board/gallery 모달과 동일 통일 (44px 원형) */
.section-gallery-skin-3 .section-gallery-s3__prev,
.section-gallery-skin-3 .section-gallery-s3__next {
    position: absolute !important;
    top: 50% !important;
    --swiper-navigation-size: 16px;
    width: 44px !important;
    height: 44px !important;
    margin-top: -22px !important;
    display: flex !important;
    align-items: center;
    justify-content: center;
    background: rgba(0, 0, 0, 0.45);
    border-radius: 50%;
    color: #fff;
    z-index: 10;
    transition: background 0.15s;
    cursor: pointer;
    overflow: hidden;
}
/* .section-gallery-skin-3 .section-gallery-s3__prev:hover, */
.section-gallery-skin-3 .section-gallery-s3__next:hover {
    background: rgba(0, 0, 0, 0.65) !important;
}
.section-gallery-skin-3 .section-gallery-s3__prev { left: 8px !important; right: auto !important; }
.section-gallery-skin-3 .section-gallery-s3__next { right: 8px !important; left: auto !important; }

@media (max-width: 767px) {
    .section-gallery-skin-3 .section-gallery-s3__prev,
    .section-gallery-skin-3 .section-gallery-s3__next {
        width: 38px !important;
        height: 38px !important;
        margin-top: -19px !important;
    }
}

/* swiper 기본 폰트 글리프(::after) 제거 — SVG로 대체 */
.section-gallery-skin-3 .section-gallery-s3__prev::after,
.section-gallery-skin-3 .section-gallery-s3__next::after {
    content: '' !important;
    display: none !important;
    font-size: 0 !important;
}
.section-gallery-skin-3 .section-gallery-s3__prev svg,
.section-gallery-skin-3 .section-gallery-s3__next svg {
    display: block;
    width: 16px;
    height: 16px;
    flex-shrink: 0;
    fill: none;
}
.section-gallery-skin-3 .section-gallery-s3__prev.swiper-button-disabled,
.section-gallery-skin-3 .section-gallery-s3__next.swiper-button-disabled {
    opacity: 0.35;
    pointer-events: none;
}

/* 페이지네이션 — swiper 밖 별도 출력이라 static + 정중앙 */
.section-gallery-skin-3 .section-gallery-s3__pagination {
    position: static !important;
    bottom: auto !important;
    width: 100%;
    text-align: center;
    line-height: 0;
}
.section-gallery-skin-3 .section-gallery-s3__pagination .swiper-pagination-bullet {
    display: inline-block;
    vertical-align: middle;
}

.section-gallery-skin-3 .section-gallery__empty {
    text-align: center;
    padding: 60px 0;
    color: #999;
    font-size: 14px;
}

/* 분류 필터바 — skin_1/skin_2와 동일 (색/크기/패딩은 render.php가 주입) */
.section-gallery-skin-3 .section-gallery__cat-filter {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
    align-items: center;
}
.section-gallery-skin-3 .section-gallery__cat-filter-btn {
    border: 0;
    cursor: pointer;
    opacity: 0.5;
    transition: opacity 0.15s;
    font: inherit;
    line-height: 1.2;
}
/* .section-gallery-skin-3 .section-gallery__cat-filter-btn:hover { opacity: 0.75; } */
.section-gallery-skin-3 .section-gallery__cat-filter-btn.is-active { opacity: 1; }
.section-gallery-skin-3 .section-gallery__cat-select {
    border: 1px solid rgba(0, 0, 0, 0.1);
    cursor: pointer;
    font: inherit;
    line-height: 1.2;
    min-width: 120px;
}
