.pl-tmg,.pl-tmg *{box-sizing:border-box}.pl-tmg{width:100%;min-width:0;margin:0 auto;padding:var(--tmg-pad-top) var(--tmg-pad-side) var(--tmg-pad-bottom);background:var(--tmg-background);font-family:var(--tmg-font);isolation:isolate}.pl-tmg .pl-tmg-tabs-wrap{max-width:var(--tmg-tabs-width);margin:0 auto var(--tmg-tabs-bottom);padding:2px 2px 12px;overflow-x:auto;scrollbar-width:none}.pl-tmg-tabs-wrap::-webkit-scrollbar{display:none}.pl-tmg .pl-tmg-tabs{display:flex;justify-content:var(--tmg-alignment);gap:var(--tmg-tabs-gap);width:max-content;min-width:100%}.pl-tmg .pl-tmg-tab{appearance:none;position:relative;display:flex;flex:0 0 var(--tmg-tab-width);align-items:center;gap:14px;width:var(--tmg-tab-width);min-height:var(--tmg-tab-height);padding:var(--tmg-tab-px);padding-block:var(--tmg-tab-py);margin:0;background:var(--tmg-tab-bg);color:var(--tmg-tab-text);border:var(--tmg-border-width) solid var(--tmg-tab-border);border-radius:var(--tmg-tab-radius);font:inherit;text-align:left;text-decoration:none;box-shadow:none;cursor:pointer;white-space:normal;line-height:1.25;transition:background .2s,color .2s,border-color .2s;text-transform:none}.pl-tmg .pl-tmg-tab:hover{background:var(--tmg-hover-bg);color:var(--tmg-hover-text)}.pl-tmg .pl-tmg-tab[aria-selected=true]{background:var(--tmg-active-bg);color:var(--tmg-active-text);border-color:var(--tmg-active-border)}.pl-tmg[data-pointer=yes] .pl-tmg-tab[aria-selected=true]:after{content:"";position:absolute;bottom:-7px;left:50%;width:12px;height:12px;background:var(--tmg-active-bg);border-right:var(--tmg-border-width) solid var(--tmg-active-border);border-bottom:var(--tmg-border-width) solid var(--tmg-active-border);transform:translateX(-50%) rotate(45deg)}.pl-tmg .pl-tmg-number{font-family:var(--tmg-number-font);font-size:var(--tmg-number-size);font-weight:700;line-height:1;flex-shrink:0;border-right:1px solid currentColor;padding-right:14px}.pl-tmg .pl-tmg-label{display:flex;min-width:0;flex-direction:column;gap:3px;overflow-wrap:anywhere}.pl-tmg .pl-tmg-title{font-size:var(--tmg-title-size);font-weight:var(--tmg-weight);letter-spacing:var(--tmg-letter-spacing)}.pl-tmg .pl-tmg-subtitle{font-size:var(--tmg-subtitle-size);font-weight:400;color:var(--tmg-sub-text);line-height:1.35}.pl-tmg .pl-tmg-tab[aria-selected=true] .pl-tmg-subtitle{color:var(--tmg-active-sub)}.pl-tmg .pl-tmg-panel[hidden]{display:none!important}.pl-tmg .pl-tmg-track{display:flex;gap:var(--tmg-image-gap);overflow-x:auto;overscroll-behavior-x:contain;scrollbar-width:none;cursor:grab;touch-action:pan-x pan-y;direction:ltr}.pl-tmg .pl-tmg-track::-webkit-scrollbar{display:none}.pl-tmg[data-scrollbar=yes] .pl-tmg-track{scrollbar-width:thin}.pl-tmg[data-scrollbar=yes] .pl-tmg-track::-webkit-scrollbar{display:block;height:7px}.pl-tmg[data-scrollbar=yes] .pl-tmg-track::-webkit-scrollbar-thumb{background:var(--tmg-active-bg);border-radius:10px}.pl-tmg .pl-tmg-track.is-dragging{cursor:grabbing;user-select:none}.pl-tmg .pl-tmg-item{flex:0 0 min(var(--tmg-image-width),90%);width:var(--tmg-image-width);margin:0;padding:0;min-width:0}.pl-tmg .pl-tmg-photo{display:block;width:100%;height:var(--tmg-image-height);overflow:hidden;border-radius:var(--tmg-image-radius);background:var(--tmg-image-bg);border:var(--tmg-image-border-width) solid var(--tmg-image-border);box-shadow:none;text-decoration:none}.pl-tmg .pl-tmg-photo img{display:block;width:100%;height:100%;max-width:100%;object-fit:var(--tmg-fit);object-position:var(--tmg-position);pointer-events:none;margin:0;border:0;border-radius:0;transition:transform .3s}.pl-tmg a.pl-tmg-photo:hover img{transform:scale(1.025)}.pl-tmg figcaption{padding:10px 2px;font-size:14px;color:var(--tmg-tab-text)}.pl-tmg .pl-tmg-empty{padding:30px;text-align:center;color:var(--tmg-tab-text)}.pl-tmg :is(button,a,.pl-tmg-track):focus-visible{outline:3px solid var(--tmg-active-border);outline-offset:-3px}.pl-tmg-lightbox{border:0;padding:50px 20px 20px;background:#111;color:#fff;max-width:96vw;width:1100px;max-height:94vh;border-radius:8px}.pl-tmg-lightbox::backdrop{background:rgba(0,0,0,.88)}.pl-tmg-lightbox img{display:block;max-width:100%;max-height:75vh;width:auto;height:auto;margin:auto;object-fit:contain}.pl-tmg-lightbox button{position:absolute;top:8px;right:12px;background:#fff;color:#111;border:0;border-radius:4px;padding:6px 14px;cursor:pointer;font:16px Arial,sans-serif}.pl-tmg-lightbox p{text-align:center;color:#fff;font:14px Arial,sans-serif;margin:12px 0 0}@media(max-width:1024px){.pl-tmg .pl-tmg-item{flex-basis:min(var(--tmg-tablet-width),90%);width:var(--tmg-tablet-width)}.pl-tmg .pl-tmg-photo{height:var(--tmg-tablet-height)}}@media(max-width:600px){.pl-tmg{padding-inline:var(--tmg-mobile-padding)}.pl-tmg .pl-tmg-tabs{justify-content:flex-start}.pl-tmg .pl-tmg-tab{width:var(--tmg-mobile-tab-width);flex-basis:var(--tmg-mobile-tab-width)}.pl-tmg .pl-tmg-title{font-size:var(--tmg-mobile-title)}.pl-tmg .pl-tmg-subtitle{font-size:var(--tmg-mobile-subtitle)}.pl-tmg .pl-tmg-number{font-size:var(--tmg-mobile-number)}.pl-tmg .pl-tmg-item{flex-basis:min(var(--tmg-mobile-width),90%);width:var(--tmg-mobile-width)}.pl-tmg .pl-tmg-photo{height:var(--tmg-mobile-height)}}@media(prefers-reduced-motion:reduce){.pl-tmg *{transition:none!important;scroll-behavior:auto!important}}

/* A looping strip has no meaningful scrollbar endpoint. */
.pl-tmg .pl-tmg-track[data-loop=yes]{scrollbar-width:none!important;scroll-behavior:auto!important}.pl-tmg .pl-tmg-track[data-loop=yes]::-webkit-scrollbar{display:none!important}

/* Version 1.3: keep the existing strip style while allowing multiple independent rows. */
.pl-tmg .pl-tmg-panel:not([hidden]){display:flex;flex-direction:column;gap:var(--tmg-rows-gap,16px)}
.pl-tmg .pl-tmg-image-row{min-width:0;width:100%}
.pl-tmg .pl-tmg-image-row .pl-tmg-empty{margin:0;background:var(--tmg-image-bg);border-radius:var(--tmg-image-radius);font-size:14px}
.pl-tmg .pl-tmg-tab.is-ghosted,.pl-tmg .pl-tmg-tab.is-ghosted:hover{background:#ececec!important;border-color:#d4d4d4!important;color:#929292!important;opacity:.68;cursor:not-allowed;box-shadow:none;filter:grayscale(1)}
.pl-tmg .pl-tmg-tab.is-ghosted .pl-tmg-subtitle{color:#999!important}
.pl-tmg .pl-tmg-tab.is-ghosted:after{display:none!important}
/* Per-row scrollbar flags supersede the gallery-wide default. */
.pl-tmg .pl-tmg-track[data-scrollbar=yes]:not([data-loop=yes]){scrollbar-width:thin}
.pl-tmg .pl-tmg-track[data-scrollbar=yes]:not([data-loop=yes])::-webkit-scrollbar{display:block;height:7px}
.pl-tmg .pl-tmg-track[data-scrollbar=yes]:not([data-loop=yes])::-webkit-scrollbar-thumb{background:var(--tmg-active-bg);border-radius:10px}
.pl-tmg .pl-tmg-track[data-scrollbar=no]{scrollbar-width:none}
.pl-tmg .pl-tmg-track[data-scrollbar=no]::-webkit-scrollbar{display:none}
.pl-tmg-lightbox .pl-tmg-lightbox-close{top:9px;right:12px}
.pl-tmg-lightbox .pl-tmg-lightbox-prev,.pl-tmg-lightbox .pl-tmg-lightbox-next{top:50%;transform:translateY(-50%);display:flex;justify-content:center;align-items:center;width:46px;height:52px;padding:0;background:rgba(255,255,255,.93);border-radius:7px;font:40px/1 Arial,sans-serif;z-index:1}
.pl-tmg-lightbox .pl-tmg-lightbox-prev{left:8px;right:auto}
.pl-tmg-lightbox .pl-tmg-lightbox-next{right:8px;left:auto}
.pl-tmg-lightbox .pl-tmg-lightbox-prev[hidden],.pl-tmg-lightbox .pl-tmg-lightbox-next[hidden]{display:none!important}
.pl-tmg-lightbox .pl-tmg-lightbox-info{display:flex;align-items:center;justify-content:center;gap:16px;min-height:20px;margin-top:10px;flex-wrap:wrap}
.pl-tmg-lightbox .pl-tmg-lightbox-info p{margin:0}
.pl-tmg-lightbox .pl-tmg-lightbox-count{font:13px Arial,sans-serif;white-space:nowrap;color:#ddd}
.pl-tmg-lightbox :is(button):focus-visible{outline:3px solid #dabf83;outline-offset:3px}
@media(max-width:600px){.pl-tmg-lightbox{padding:52px 7px 14px;width:98vw}.pl-tmg-lightbox .pl-tmg-lightbox-prev,.pl-tmg-lightbox .pl-tmg-lightbox-next{width:34px;height:42px;font-size:30px}.pl-tmg-lightbox .pl-tmg-lightbox-prev{left:2px}.pl-tmg-lightbox .pl-tmg-lightbox-next{right:2px}}

/* Version 1.3.1: automatically fit all shown tabs into the desktop tab row.
 * Keep the user's configured tab width as an upper bound and a readable
 * minimum. Very narrow screens and longer lists remain swipe-scrollable. */
.pl-tmg .pl-tmg-tabs{width:100%;min-width:100%}
.pl-tmg .pl-tmg-tab{
  flex-basis:min(var(--tmg-tab-width),max(170px,var(--tmg-tab-fit-width,var(--tmg-tab-width))));
  width:min(var(--tmg-tab-width),max(170px,var(--tmg-tab-fit-width,var(--tmg-tab-width))));
}
@media(max-width:600px){
  .pl-tmg .pl-tmg-tab{width:var(--tmg-mobile-tab-width);flex-basis:var(--tmg-mobile-tab-width)}
}

/* Keep the first tab reachable when a long row must scroll horizontally. */
@supports (justify-content:safe center){
  .pl-tmg .pl-tmg-tabs{justify-content:safe var(--tmg-alignment)}
}

/* Version 1.3.2 — isolate tab focus/press/hover from site-wide button styles.
 * WordPress themes/Elementor can color a focused button pink even after a
 * different tab becomes selected. Define all interaction states explicitly;
 * preserve the gallery's own color settings, including configured hover.
 * Scoped to gallery tabs so buttons elsewhere on the site are unaffected. */
.pl-tmg button.pl-tmg-tab:not([aria-selected="true"]):not(.is-ghosted),
.pl-tmg button.pl-tmg-tab:not([aria-selected="true"]):not(.is-ghosted):focus,
.pl-tmg button.pl-tmg-tab:not([aria-selected="true"]):not(.is-ghosted):active {
  background:var(--tmg-tab-bg) !important;
  background-image:none !important;
  color:var(--tmg-tab-text) !important;
  border-color:var(--tmg-tab-border) !important;
  box-shadow:none !important;
}
.pl-tmg button.pl-tmg-tab:not([aria-selected="true"]):not(.is-ghosted):hover,
.pl-tmg button.pl-tmg-tab:not([aria-selected="true"]):not(.is-ghosted):hover:focus {
  background:var(--tmg-hover-bg) !important;
  background-image:none !important;
  color:var(--tmg-hover-text) !important;
}
.pl-tmg button.pl-tmg-tab[aria-selected="true"]:not(.is-ghosted),
.pl-tmg button.pl-tmg-tab[aria-selected="true"]:not(.is-ghosted):hover,
.pl-tmg button.pl-tmg-tab[aria-selected="true"]:not(.is-ghosted):focus,
.pl-tmg button.pl-tmg-tab[aria-selected="true"]:not(.is-ghosted):active {
  background:var(--tmg-active-bg) !important;
  background-image:none !important;
  color:var(--tmg-active-text) !important;
  border-color:var(--tmg-active-border) !important;
  box-shadow:none !important;
}
