/* ================================================================
   THW — Product Gallery
   ================================================================ */

/* ── Gallery wrapper ─────────────────────────────────────────────────────── */

.thwg-gallery {
    position: relative;
    width: 100%;
    margin-bottom: 2rem;
	max-width: 620px;
    display: inline-block;
}

/* ── PhotoSwipe trigger icon ─────────────────────────────────────────────── */

.thwg-pswp-trigger {
    position: absolute;
    top: .75rem;
    right: .75rem;
    z-index: 9;
    display: block;
    width: 2rem;
    height: 2rem;
    background: rgba(255,255,255,.9);
    border-radius: 3px;
    line-height: 2rem;
    text-align: center;
    text-decoration: none;
}

.thwg-pswp-trigger .emoji {
    width: 1.1em;
    height: 1.1em;
    vertical-align: middle;
}

/* ── Main Viewer ─────────────────────────────────────────────────────────── */

.thwg-main-wrap {
    position: relative;
    width: 100%;
    overflow: hidden;
    background: #000;
    /* No aspect-ratio — height is driven by image natural height */
}

.thwg-main-inner {
    position: relative;
    width: 100%;
    /* Height will match the active slide's image naturally */
}

/* ── Slides ──────────────────────────────────────────────────────────────── */

.thwg-slide {
    display: none;
    width: 100%;
}

.thwg-slide.is-active {
    display: block;
}

/* ── Image slides — zoom wrap ────────────────────────────────────────────── */

.thwg-zoom-wrap {
    position: relative;
    overflow: hidden;
    cursor: crosshair;
    display: block;
    width: 100%;
    /* Line-height 0 removes the grey gap below inline images */
    line-height: 0;
    font-size: 0;
}

.thwg-main-img {
    display: block;
    width: 100%;
    height: auto;
    /* No fixed height — image fills naturally, no grey gap */
}

/* Zoom overlay image */
.thwg-zoom-img {
    position: absolute;
    opacity: 0;
    pointer-events: none;
    max-width: none !important;
    max-height: none !important;
    border: none !important;
    transition: opacity .15s;
}

.thwg-zoom-wrap.is-zooming .thwg-zoom-img {
    opacity: 1;
}

/* ── Video slides ────────────────────────────────────────────────────────── */

.thwg-video-poster-wrap {
    position: relative;
    width: 100%;
    cursor: pointer;
    line-height: 0;
    font-size: 0;
}

.thwg-poster-img {
    display: block;
    width: 100%;
    height: auto;
}

.thwg-play-btn {
    position: absolute;
    inset: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    pointer-events: none;
}

.thwg-play-btn svg {
    width: 72px;
    height: 72px;
    filter: drop-shadow(0 2px 8px rgba(0,0,0,.4));
    transition: transform .2s;
}

.thwg-video-poster-wrap:hover .thwg-play-btn svg {
    transform: scale(1.1);
}

.thwg-video-frame {
    width: 100%;
    aspect-ratio: 16/9;
    background: #000;
}

.thwg-video-frame iframe {
    width: 100%;
    height: 100%;
    border: none;
    display: block;
}

/* ── Arrows ──────────────────────────────────────────────────────────────── */

.thwg-arrow {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    z-index: 9;
    background: rgba(255,255,255,.9);
    border: 1px solid #e0e0e0;
    border-radius: 50%;
    width: 36px;
    height: 36px;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: background .15s, box-shadow .15s;
    box-shadow: 0 1px 4px rgba(0,0,0,.12);
    color: #333;
    padding: 0;
}

.thwg-arrow:hover {
    background: #fff;
    box-shadow: 0 2px 8px rgba(0,0,0,.18);
}

.thwg-arrow--prev { left: 8px; }
.thwg-arrow--next { right: 8px; }

/* ── Thumbnail Rows ──────────────────────────────────────────────────────── */

.thwg-thumbs-row {
    display: flex !important;
    flex-wrap: wrap;
    gap: 4px;
    margin: 6px 0 0 !important;
    padding: 0 !important;
    list-style: none !important;
}

.thwg-thumbs-row li {
    position: relative;
    margin: 0 !important;
    cursor: pointer;
    opacity: .5;
    transition: opacity .2s;
    flex-shrink: 0;
}

.thwg-thumbs-row li:hover,
.thwg-thumbs-row li.thwg-thumb-active,
.thwg-thumbs-row li.flex-active {
    opacity: 1;
}

.thwg-thumbs-row li > img {
    display: block !important;
    width: 100px !important;
    height: 100px !important;
    object-fit: cover !important;
}

/* Video thumb play icon */
.thwg-thumb-play-icon {
    position: absolute;
    inset: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #fff;
    font-size: .85rem;
    background: rgba(0,0,0,.35);
    pointer-events: none;
    transition: background .15s;
}

.thwg-thumb-video:hover .thwg-thumb-play-icon {
    background: rgba(0,0,0,.55);
}

.thwg-thumb-play-icon > img{
	height: 2.5em !important;
    width: 2.5em !important;
}

/* Row 1 — auto width thumbnails in single row, no wrap */
.thwg-thumbs-row--1 {
    flex-wrap: nowrap !important;
    overflow-x: hidden !important;
}

.thwg-thumbs-row--1 li {
    flex: 1 1 0 !important;
    min-width: 0 !important;
}

.thwg-thumbs-row--1 li > img {
    width: 100% !important;
    height: 80px !important;
    object-fit: cover !important;
}

/* ── Row 2 label ─────────────────────────────────────────────────────────── */

.thwg-row2-label {
    margin-top: 10px;
    padding-top: 10px;
    border-top: 1px dashed #e0e0e0;
}

.thwg-row2-label span {
    font-size: .7rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: .06em;
    color: #aaa;
}

.thwg-thumbs-row--2 {
    margin-top: 4px !important;
}
.thwg-thumbs-row--2 li > img{
	width: 50px !important;
	height: 50px !important;
}
/* ── Body scroll lock (lightbox) ─────────────────────────────────────────── */

body.thwg-no-scroll {
    overflow: hidden;
}

@media screen and (min-width: 500px) {
	
}
