.ts-wrapper {
    position: relative;
    width: 100%;
}

/* ============================
   Nav Slider
   ============================ */
.ts-nav-slider {
    position: relative;
    width: 100%;
    border: 0 solid transparent;
    border-bottom: 2px solid #eaeaea;
    margin-bottom: 30px;
    overflow: hidden;
}

/* Alignment Helpers */
.ts-nav-align-justify .ts-nav-item {
    text-align: center;
}
.ts-nav-align-tablet-justify .ts-nav-item {
    text-align: center;
}
.ts-nav-align-mobile-justify .ts-nav-item {
    text-align: center;
}

.ts-nav-item {
    cursor: pointer;
    opacity: 0.5;
    transition: opacity 0.35s ease;
    box-sizing: border-box;
    flex-shrink: 0;
    min-width: fit-content; /* Ensure items don't squash below their content size */
}

.ts-nav-item.swiper-slide-thumb-active {
    opacity: 1;
}

.ts-nav-inner {
    display: flex;
    align-items: center;
    gap: 15px;
    white-space: nowrap;
    position: relative;
    height: 100%;
    padding: 15px 30px;
}

.ts-nav-img {
    width: 45px;
    height: 45px;
    border-radius: 50%;
    overflow: hidden;
    background: #f0f0f0;
    flex-shrink: 0;
}

.ts-nav-img img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

.ts-nav-info {
    display: flex;
    flex-direction: column;
    gap: 2px;
}

.ts-nav-name {
    margin: 0;
}

.ts-nav-role {
}

/* Indicators (Top & Bottom) */
.ts-nav-indicator-top,
.ts-nav-indicator-bottom {
    position: absolute;
    left: 0;
    width: 100%;
    height: 3px;
    background-color: transparent;
    transition: background-color 0.35s ease;
    z-index: 10;
}

.ts-nav-indicator-top {
    top: 0;
}

.ts-nav-indicator-bottom {
    bottom: 0;
}

.ts-nav-item.swiper-slide-thumb-active .ts-nav-indicator-top,
.ts-nav-item.swiper-slide-thumb-active .ts-nav-indicator-bottom {
    background-color: #333;
}

/* ============================
   Main Slider
   ============================ */
.ts-main-slider {
    background: #faf8f5;
    border-radius: 8px;
    overflow: hidden;
}

.ts-main-slider .swiper-slide {
    height: auto;
}

/* Base Grid */
.ts-main-grid {
    display: flex;
    flex-wrap: wrap;
    width: 100%;
}

.ts-content-col {
    position: relative;
    box-sizing: border-box;
    display: flex;
    flex-direction: column;
    justify-content: center;
    flex-grow: 0;
    flex-shrink: 0;
}

.ts-desc-content {
    font-size: 18px;
    line-height: 1.8;
    color: #666;
    margin-bottom: 40px;
}

.ts-desc-content p {
    margin: 0;
}

.ts-desc-divider {
    width: 40px;
    height: 1px;
    background: #333;
    margin-bottom: 20px;
}

.ts-desc-signature {
    font-size: 18px;
    font-weight: 600;
    color: #333;
}

.ts-media-col {
    position: relative;
    overflow: hidden;
    box-sizing: border-box;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    flex-grow: 0;
    flex-shrink: 0;
}

/* Removed forced stacking to allow sliders to work */

.ts-media-wrap {
    width: 100%;
    overflow: hidden;
}

.ts-media-wrap > img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

/* Video */
.ts-video-wrap {
    width: 100%;
    height: 100%;
    position: relative;
    cursor: pointer;
    background: #000;
    overflow: hidden;
}

.ts-video-poster {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
    opacity: 0.9;
    transition: opacity 0.3s;
}

.ts-video-wrap:hover .ts-video-poster {
    opacity: 0.7;
}

.ts-play-btn {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    z-index: 10;
    transition: transform 0.3s;
}

.ts-video-wrap:hover .ts-play-btn {
    transform: translate(-50%, -50%) scale(1.1);
}

/* Embedded video iframe */
.ts-video-wrap iframe,
.ts-video-wrap video {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    border: 0;
}

/* ============================
   Responsive
   ============================ */
@media (max-width: 768px) {
    .ts-main-grid {
        flex-direction: column;
    }
    /* Fallbacks (Elementor responsive controls will override these due to higher specificity) */
    .ts-content-col,
    .ts-media-col {
        width: 100%;
        flex-basis: 100%;
    }
}

/* ==================================
   Category Slider Widget
   ================================== */
.ts-cat-tabs-container {
    width: 100%;
    margin-bottom: 40px;
    position: relative;
}

.ts-cat-tabs-swiper {
    width: 100%;
}

.ts-cat-tabs-swiper .swiper-wrapper {
    display: flex;
    align-items: center;
}

.ts-cat-tab {
    padding: 15px 30px;
    cursor: pointer;
    font-weight: 500;
    text-transform: uppercase;
    font-size: 13px;
    letter-spacing: 1.5px;
    color: #999;
    text-align: center;
    transition: all 0.3s ease;
    width: auto !important;
    position: relative;
}

.ts-cat-tab.active {
    color: #333;
}

/* ==================================
   Coco Footer Widget
   ================================== */
.coco-footer-wrap {
    background-color: #fff;
    padding: 80px 0 40px;
    font-family: 'Inter', sans-serif;
    color: #333;
}

.coco-footer-top {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 40px;
    margin-bottom: 60px;
}

.coco-news-col {
    flex: 1;
}

.coco-news-title {
    font-family: serif;
    font-size: 42px;
    line-height: 1.1;
    margin: 0;
    font-weight: 400;
}

.coco-form-col {
    flex: 2;
    display: flex;
    justify-content: flex-end;
}

.coco-newsletter-form {
    display: flex;
    align-items: center;
    background: #f8f8f8;
    border-radius: 50px;
    padding: 8px;
    width: 100%;
    max-width: 600px;
}

.coco-news-input {
    flex: 1;
    background: transparent;
    padding: 0 15px;
    font-size: 16px;
    outline: none;
    box-sizing: border-box;
    width: 100%;
}

.coco-news-btn {
    background: #222;
    color: #fff;
    border: none;
    border-radius: 40px;
    padding: 15px 35px;
    font-size: 12px;
    font-weight: 600;
    letter-spacing: 1px;
    cursor: pointer;
    display: flex;
    align-items: center;
    gap: 10px;
    transition: all 0.3s;
}

.coco-news-btn:hover {
    background: #000;
    transform: translateY(-2px);
}

.coco-footer-divider {
    height: 1px;
    background: #eaeaea;
    margin-bottom: 60px;
}

.coco-footer-bottom {
    display: flex;
    flex-wrap: wrap;
    gap: 40px;
}

.coco-footer-col {
    flex: 1;
    min-width: 200px;
}

.coco-branding-col {
    flex: 2;
}

.coco-footer-logo {
    margin-bottom: 30px;
}

.coco-footer-logo img {
    max-height: 40px;
}

.coco-footer-text {
    font-size: 15px;
    line-height: 1.6;
    color: #777;
    margin-bottom: 30px;
    max-width: 400px;
}

.coco-footer-copyright {
    font-size: 13px;
    color: #999;
}

.coco-menu-title {
    font-family: serif;
    font-size: 22px;
    margin-bottom: 25px;
    font-weight: 400;
}

.coco-footer-links {
    list-style: none;
    padding: 0;
    margin: 0;
}

.coco-footer-links li {
    margin-bottom: 15px;
}

.coco-footer-links a {
    text-decoration: none;
    color: #777;
    font-size: 14px;
    transition: color 0.3s;
}

.coco-footer-links a:hover {
    color: #000;
}

.coco-footer-phone {
    font-size: 15px;
    font-weight: 600;
    margin-top: 15px;
}

.coco-footer-social {
    display: flex;
    gap: 15px;
    margin-bottom: 30px;
}

.coco-social-item {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 32px;
    height: 32px;
    border-radius: 50%;
    background: #f1f1f1;
    color: #333;
    font-size: 14px;
    transition: all 0.3s;
    text-decoration: none;
}

.coco-social-item:hover {
    background: #000;
    color: #fff;
    transform: translateY(-3px);
}

@media (max-width: 1024px) {
    .coco-footer-top {
        flex-direction: column;
        align-items: flex-start;
    }
    .coco-form-col {
        width: 100%;
    }
    .coco-newsletter-form {
        max-width: 100%;
    }
}

@media (max-width: 767px) {
    .coco-news-title {
        font-size: 32px;
    }
    .coco-footer-col {
        flex-basis: 100%;
    }
}


.ts-media-wrapper-outer {
    width: 100%;
}

.ts-media-wrapper {
    position: relative;
    overflow: hidden; /* Ensure it doesn't break page layout if not focused */
}

/* Focus Mode Transitions */
.ts-cat-swiper .swiper-slide {
    transition: opacity 0.4s ease;
    opacity: 1;
}

.ts-cat-swiper .swiper-slide:not(.swiper-slide-active) {
    opacity: 0.4;
}

.ts-cat-swiper .swiper-slide-active {
    opacity: 1;
}

.ts-cat-slider-container {
    display: none;
}

.ts-cat-slider-container.active {
    display: block;
    animation: tsFadeUp 0.5s ease;
}

@keyframes tsFadeUp {
    from { opacity: 0; transform: translateY(20px); }
    to { opacity: 1; transform: translateY(0); }
}

/* Hard clip: the swiper container crops the peeking next slide cleanly */
.ts-cat-swiper {
    overflow: hidden;
}

/* Custom infinite tabs (transform-based, no native scroll) */
.ts-cat-tabs-outer {
    width: 100%;
}

.ts-infinite-tabs {
    overflow: hidden;
    cursor: grab;
    -webkit-user-select: none;
    user-select: none;
}
.ts-infinite-tabs .swiper-wrapper {
    display: flex;
    flex-wrap: nowrap;
    will-change: transform; /* GPU acceleration */
}
.ts-infinite-tabs.ts-grabbing {
    cursor: grabbing;
}

.ts-cat-item-wrap {
    position: relative;
    width: 100%;
    height: 400px;
    overflow: hidden;
    background: #f0f0f0;
    border-radius: 12px; /* Premium rounded corners */
}

/* Fix for single slide - make it look like a card instead of full width banner */
.ts-cat-swiper.ts-single-slide .ts-cat-item-wrap {
    max-width: 60%;
    margin-left: auto;
    margin-right: auto;
}

@media (max-width: 768px) {
    .ts-cat-swiper.ts-single-slide .ts-cat-item-wrap {
        max-width: 90%;
    }
}

.ts-cat-lightbox-trigger {
    display: block;
    width: 100%;
    height: 100%;
    text-decoration: none;
    cursor: pointer;
}

/* ─── Custom Lightbox ─── */
.ts-lightbox-overlay {
    position: fixed;
    top: 0; left: 0;
    width: 100%; height: 100%;
    z-index: 999999;
    background: rgba(0, 0, 0, 0);
    backdrop-filter: blur(0px);
    display: flex;
    align-items: center;
    justify-content: center;
    transition: background 0.3s, backdrop-filter 0.3s;
    cursor: pointer;
}
.ts-lightbox-overlay.ts-lb-active {
    background: rgba(0, 0, 0, 0.85);
    backdrop-filter: blur(8px);
}

.ts-lb-content {
    max-width: 90vw;
    max-height: 90vh;
    position: relative;
    opacity: 0;
    transform: scale(0.92);
    transition: opacity 0.3s, transform 0.3s;
    cursor: default;
}
.ts-lb-active .ts-lb-content {
    opacity: 1;
    transform: scale(1);
}

.ts-lb-media {
    max-width: 90vw;
    max-height: 85vh;
    object-fit: contain;
    border-radius: 8px;
    display: block;
}
.ts-lb-media.ts-lb-video {
    width: 80vw;
    height: calc(80vw * 9 / 16); /* 16:9 aspect */
    max-height: 85vh;
    border-radius: 8px;
}

.ts-lb-close {
    position: fixed;
    top: 20px; right: 24px;
    z-index: 1000000;
    background: rgba(255,255,255,0.15);
    border: 1px solid rgba(255,255,255,0.3);
    color: #fff;
    width: 44px; height: 44px;
    border-radius: 50%;
    font-size: 24px;
    line-height: 1;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: background 0.2s, transform 0.2s;
    backdrop-filter: blur(4px);
}
.ts-lb-close:hover {
    background: rgba(255,255,255,0.3);
    transform: scale(1.1);
}

.ts-cat-item-wrap img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.5s;
}

.ts-cat-item-wrap:hover img {
    transform: scale(1.05);
}

.ts-cat-overlay {
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100%;
    padding: 30px;
    background: linear-gradient(transparent, rgba(0,0,0,0.7));
    color: #fff;
    pointer-events: none;
}

.ts-cat-title {
    font-size: 18px;
    font-weight: 600;
}

.ts-cat-video-wrap {
    width: 100%;
    height: 100%;
    position: relative;
    cursor: pointer;
}

.ts-cat-video-wrap iframe,
.ts-cat-video-wrap video {
    position: absolute;
    top: 0; left: 0; width: 100%; height: 100%;
    border: 0;
}

.ts-cat-poster {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

/* Responsive Tabs */
@media (max-width: 768px) {
    .ts-cat-tabs {
        flex-wrap: nowrap;
        overflow-x: auto;
        justify-content: flex-start;
        padding-bottom: 5px;
        gap: 25px;
        scrollbar-width: none;
    }
    .ts-cat-tabs::-webkit-scrollbar { display: none; }
}

/* Navigation Arrows */
.ts-cat-nav {
    display: flex;
    justify-content: space-between;
    width: 100%;
    position: absolute;
    top: 50%;
    left: 0;
    transform: translateY(-50%);
    z-index: 10;
    pointer-events: none;
    padding: 0 10px;
}

.ts-cat-arrow {
    width: 40px;
    height: 40px;
    border: 1px solid #333;
    background: #fff;
    color: #333;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    pointer-events: auto;
    transition: all 0.3s;
}

.ts-cat-arrow:hover {
    background: #333;
    color: #fff;
}

.ts-cat-prev {
    margin-right: auto;
}

.ts-cat-next {
    margin-left: auto;
}

/* Play Button */
.ts-play-btn {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    z-index: 5;
    transition: transform 0.3s;
}

.ts-cat-video-wrap:hover .ts-play-btn {
    transform: translate(-50%, -50%) scale(1.1);
}
/* ============================
   Mobile & Tablet Fixes
   ============================ */

/* Category Tab Fixes */
@media (max-width: 1024px) {
    .ts-cat-tab {
        flex-shrink: 0 !important;
        min-width: max-content !important;
        padding: 10px 20px !important;
    }
    
    .ts-cat-tabs-swiper {
        width: 100% !important;
    }

    /* Testimonial Nav Fixes */
    .ts-nav-item {
        min-width: 200px !important;
        flex-shrink: 0 !important;
    }
    .ts-nav-info {
        min-width: 0;
        flex-grow: 1;
        flex-shrink: 0;
    }
    .ts-nav-name, .ts-nav-role {
        overflow: hidden;
        text-overflow: ellipsis;
        white-space: nowrap;
    }
}

