/* ================================================
   TEAM GLAM — Before & After Slider
   ================================================ */

.tg-ba-section {
    background: #f5f3ef;
    padding: 100px 0 80px;
}

/* ── Header ──────────────────────────────────── */
.tg-ba-header {
    text-align: center;
    padding: 0 40px;
    margin-bottom: 56px;
}

.tg-ba-eyebrow {
    display: block;
    font-family: 'brandon-grotesque', sans-serif;
    font-size: 11px;
    letter-spacing: 0.2em;
    text-transform: uppercase;
    color: #888888;
    margin-bottom: 16px;
}

.tg-ba-heading {
    font-family: 'beaufort-pro', serif;
    font-size: clamp(32px, 4vw, 56px);
    font-weight: 400;
    color: #000000;
    margin: 0 0 16px;
    line-height: 1.1;
}

.tg-ba-sub {
    font-family: 'brandon-grotesque', sans-serif;
    font-size: var(--tg-body-font-size, 18px);
    line-height: 1.6;
    color: #888888;
    margin: 0;
}

/* ── Carousel wrapper ─────────────────────────── */
.tg-ba-wrap {
    position: relative;
}

.tg-ba-swiper {
    overflow: hidden;
}

/* ── Pair ─────────────────────────────────────── */
.tg-ba-pair {
    position: relative;
    width: 100%;
    height: 600px;
    overflow: hidden;
    cursor: col-resize;
    user-select: none;
    -webkit-user-select: none;
}

/* ── Images ───────────────────────────────────── */
.tg-ba-layer {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
}

.tg-ba-layer img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: var(--tg-ba-pos, top center);
    display: block;
    pointer-events: none;
    user-select: none;
    -webkit-user-drag: none;
}

/* Before image is clipped from the right; JS updates clip-path on drag */
.tg-ba-before {
    clip-path: inset(0 50% 0 0);
}

.tg-ba-placeholder {
    position: absolute;
    inset: 0;
    background: #e8e4df;
}

.tg-ba-placeholder--before {
    background: #d6d0c8;
}

/* ── Drag handle ──────────────────────────────── */
.tg-ba-handle {
    position: absolute;
    top: 0;
    bottom: 0;
    left: 50%;
    transform: translateX(-50%);
    width: 48px;
    pointer-events: none;
    z-index: 10;
    display: flex;
    align-items: center;
    justify-content: center;
}

.tg-ba-line {
    position: absolute;
    top: 0;
    bottom: 0;
    left: 50%;
    transform: translateX(-50%);
    width: 2px;
    background: #ffffff;
}

.tg-ba-btn {
    width: 44px;
    height: 44px;
    border-radius: 50%;
    background: #ffffff;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #1a1a1a;
    box-shadow: 0 2px 16px rgba(0,0,0,0.18);
    flex-shrink: 0;
    z-index: 1;
}

.tg-ba-btn svg {
    width: 20px;
    height: 20px;
    fill: #1a1a1a;
}

/* ── Labels ──────────────────────────────────── */
.tg-ba-label {
    position: absolute;
    bottom: 24px;
    font-family: 'brandon-grotesque', sans-serif;
    font-size: 10px;
    letter-spacing: 0.18em;
    text-transform: uppercase;
    color: #ffffff;
    padding: 5px 12px;
    background: rgba(0,0,0,0.3);
    backdrop-filter: blur(4px);
    z-index: 5;
    pointer-events: none;
}

.tg-ba-label--before { left: 20px; }
.tg-ba-label--after  { right: 20px; }

.tg-ba-name {
    position: absolute;
    top: 20px;
    right: 20px;
    font-family: 'brandon-grotesque', sans-serif;
    font-size: 11px;
    letter-spacing: 0.14em;
    text-transform: uppercase;
    color: #ffffff;
    text-shadow: 0 1px 6px rgba(0,0,0,0.45);
    z-index: 5;
    pointer-events: none;
}

/* ── Arrow nav ───────────────────────────────── */
.tg-ba-prev,
.tg-ba-next {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    z-index: 20;
    width: 44px;
    height: 44px;
    background: rgba(255,255,255,0.88);
    border: none;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #1a1a1a;
    transition: background 0.2s ease;
}

.tg-ba-prev { left: 20px; }
.tg-ba-next { right: 20px; }
.tg-ba-prev:hover,
.tg-ba-next:hover { background: #ffffff; }

/* ── Dots ─────────────────────────────────────── */
.tg-ba-pagination {
    text-align: center;
    padding: 28px 0 0;
}

.tg-ba-pagination .swiper-pagination-bullet {
    width: 6px;
    height: 6px;
    background: #bbbbbb;
    border-radius: 0;
    opacity: 1;
    margin: 0 4px;
    transition: width 0.25s, background 0.25s;
}

.tg-ba-pagination .swiper-pagination-bullet-active {
    background: #1a1a1a;
    width: 24px;
}

/* ── Responsive ──────────────────────────────── */
@media (max-width: 1024px) {
    .tg-ba-section { padding: 72px 0 56px; }
}

@media (max-width: 767px) {
    .tg-ba-section { padding: 56px 0 40px; }
    .tg-ba-header  { padding: 0 24px; margin-bottom: 36px; }
    .tg-ba-prev    { left: 10px; }
    .tg-ba-next    { right: 10px; }
}
