/* =============================================================
   TSP Team Carousel  —  v2.2   Light Theme  |  Poppins
   ============================================================= */

@import url('https://fonts.googleapis.com/css2?family=Poppins:ital,wght@0,300;0,400;0,500;0,600;0,700;0,800;1,400;1,500&display=swap');

/* ── Scope reset ── */
.ttcar-wrap,
.ttcar-wrap * {
    box-sizing: border-box;
    font-family: 'Poppins', sans-serif;
}

/* =============================================================
   WRAPPER  —  3-column light card
   ============================================================= */

.ttcar-wrap {
    display: grid;
    grid-template-columns: 1.1fr 1.3fr 1.4fr;
    height: 480px;
    background: #ffffff;
    border-radius: 18px;
    overflow: hidden;
    position: relative;
    width: 100%;
    box-shadow: 0 8px 48px rgba(11, 49, 94, 0.16);
}

/* =============================================================
   LEFT COLUMN  —  heading · counter · thumbnails
   ============================================================= */

.ttcar-col-left {
    display: flex;
    flex-direction: column;
    padding: 36px 28px 28px;
    position: relative;
    z-index: 2;
    background: #ffffff;
    overflow: hidden;
}

/* Subtle right border separator */
.ttcar-col-left::after {
    content: '';
    position: absolute;
    right: 0;
    top: 8%;
    bottom: 8%;
    width: 1px;
    background: rgba(11, 49, 94, 0.09);
}

/* Eyebrow */
.ttcar-eyebrow {
    display: inline-flex;
    align-items: center;
    gap: 7px;
    font-size: 9.5px;
    font-weight: 700;
    color: #D29C34;
    text-transform: uppercase;
    letter-spacing: 3px;
    margin-bottom: 12px;
}

.ttcar-eyebrow-dot {
    width: 6px;
    height: 6px;
    border-radius: 50%;
    background: #D29C34;
    flex-shrink: 0;
    display: inline-block;
}

/* Heading */
.ttcar-heading {
    font-size: 22px;
    font-weight: 700;
    color: #0B315E;
    line-height: 1.32;
    margin: 0 0 16px;
    letter-spacing: -0.3px;
}

/* Counter */
.ttcar-counter-wrap {
    display: flex;
    align-items: baseline;
    gap: 4px;
    margin-bottom: auto;   /* pushes thumbs to bottom on desktop */
    padding-bottom: 16px;
}

.ttcar-counter-num {
    font-size: 50px;
    font-weight: 800;
    color: #D29C34;
    line-height: 1;
    letter-spacing: -2px;
    transition: opacity 0.22s ease;
}

.ttcar-counter-sep {
    font-size: 16px;
    font-weight: 400;
    color: rgba(11, 49, 94, 0.25);
    margin: 0 2px;
}

.ttcar-counter-total {
    font-size: 14px;
    font-weight: 500;
    color: rgba(11, 49, 94, 0.30);
}

/* Counter fade animation on switch */
.ttcar-wrap.is-counting .ttcar-counter-num {
    opacity: 0;
}

/* ── Thumbnails ── */
.ttcar-thumbs {
    display: flex;
    align-items: flex-end;
    gap: 10px;
    flex-wrap: wrap;
    padding-top: 6px;
}

.ttcar-thumb {
    position: relative;
    width: 68px;
    height: 82px;
    border-radius: 10px;
    overflow: hidden;
    cursor: pointer;
    border: 2px solid rgba(11, 49, 94, 0.12);
    background: #eef2fb;
    padding: 0;
    transition: border-color 0.28s ease, transform 0.24s ease, box-shadow 0.28s ease;
    flex-shrink: 0;
    outline: none;
}

.ttcar-thumb img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: top center;
    display: block;
    transition: transform 0.4s ease, filter 0.3s ease;
    filter: brightness(0.72) saturate(0.75);
}

.ttcar-thumb:hover img {
    filter: brightness(0.9) saturate(0.95);
    transform: scale(1.05);
}

.ttcar-thumb.is-active img {
    filter: brightness(1) saturate(1);
}

.ttcar-thumb.is-active {
    border-color: #D29C34;
    box-shadow: 0 0 0 3px rgba(210, 156, 52, 0.20);
    transform: translateY(-3px);
}

/* Gold top bar on active thumb */
.ttcar-thumb-active-bar {
    position: absolute;
    top: 0; left: 0; right: 0;
    height: 3px;
    background: #D29C34;
    transform: scaleX(0);
    transition: transform 0.30s ease;
    transform-origin: left;
    border-radius: 0 0 2px 2px;
}

.ttcar-thumb.is-active .ttcar-thumb-active-bar {
    transform: scaleX(1);
}

.ttcar-thumb-placeholder {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 100%; height: 100%;
}
.ttcar-thumb-placeholder i {
    font-size: 22px !important;
    color: rgba(11, 49, 94, 0.25) !important;
}

/* =============================================================
   CENTER COLUMN  —  large photo stage
   ============================================================= */

.ttcar-col-center {
    position: relative;
    overflow: hidden;
    background: #dde4ef;
}

.ttcar-photo-stage {
    position: absolute;
    inset: 0;
}

/* Photo slides — cross-fade with scale */
.ttcar-photo-slide {
    position: absolute;
    inset: 0;
    opacity: 0;
    transform: scale(1.04);
    transition: opacity 0.55s cubic-bezier(.4,0,.2,1),
                transform 0.55s cubic-bezier(.4,0,.2,1);
    pointer-events: none;
}

.ttcar-photo-slide.is-active {
    opacity: 1;
    transform: scale(1);
    pointer-events: auto;
}

.ttcar-photo-slide img {
    width: 100%;
    height: 100% !important;
    object-fit: cover;
    object-position: top center;
    display: block;
}

.ttcar-photo-placeholder {
    width: 100%; height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    background: #c8d4e8;
}
.ttcar-photo-placeholder i {
    font-size: 80px !important;
    color: rgba(11, 49, 94, 0.18) !important;
}

/* Very subtle tint over photo */
.ttcar-photo-tint {
    position: absolute;
    inset: 0;
    background: rgba(8, 15, 30, 0.10);
    pointer-events: none;
}

/* Gradient fade from center into right panel */
.ttcar-col-center::after {
    content: '';
    position: absolute;
    top: 0; right: 0;
    width: 72px;
    height: 100%;
    background: linear-gradient(to right, transparent, rgba(255, 255, 255, 0.92));
    pointer-events: none;
    z-index: 2;
}

/* =============================================================
   RIGHT COLUMN  —  detail panels  (WHITE background)
   ============================================================= */

.ttcar-col-right {
    position: relative;
    background: #ffffff;          /* ← white, not light-blue */
    overflow: hidden;
    border-left: 1px solid rgba(11, 49, 94, 0.08);
}

/* ── Detail panel (absolute stack on desktop) ── */
.ttcar-detail-panel {
    position: absolute;
    inset: 0;
    padding: 34px 30px 28px;
    overflow-y: auto;
    opacity: 0;
    transform: translateY(14px);
    transition: opacity 0.45s cubic-bezier(.4,0,.2,1),
                transform 0.45s cubic-bezier(.4,0,.2,1);
    pointer-events: none;

    scrollbar-width: thin;
    scrollbar-color: rgba(11,49,94,0.18) transparent;
}
.ttcar-detail-panel::-webkit-scrollbar       { width: 4px; }
.ttcar-detail-panel::-webkit-scrollbar-track { background: transparent; }
.ttcar-detail-panel::-webkit-scrollbar-thumb { background: rgba(11,49,94,0.18); border-radius: 2px; }

.ttcar-detail-panel.is-active {
    opacity: 1;
    transform: translateY(0);
    pointer-events: auto;
}

/* ── Name ── */
.ttcar-detail-name {
    font-size: 24px;
    font-weight: 700;
    color: #D29C34;
    margin: 0 0 6px;
    letter-spacing: -0.2px;
    line-height: 1.2;
}

/* ── Role / Position  —  20px, proper dark colour ── */
.ttcar-detail-role {
    display: block;
    font-size: 16px;              /* ← 20px as requested */
    font-weight: 600;
    color: #1a1a1a;               /* ← proper dark/black */
    letter-spacing: 0.2px;
    line-height: 1.3;
    margin-bottom: 14px;
}

/* ── Gold rule ── */
.ttcar-rule {
    width: 36px;
    height: 2px;
    background: #D29C34;
    border-radius: 2px;
    margin-bottom: 16px;
    opacity: 0.8;
}

/* ── Bio / Description  —  16px, proper dark colour ── */
.ttcar-detail-bio {
    font-size: 16px;              /* ← 16px as requested */
    font-weight: 400;
    color: #1a1a1a;               /* ← proper dark/black */
    line-height: 1.75;
    margin: 0 0 18px;
}

/* ── Contact rows ── */
.ttcar-contact-row {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 9px;
}

.ttcar-contact-icon {
    font-size: 13px !important;
    color: #D29C34 !important;
    flex-shrink: 0;
    width: 16px;
    text-align: center;
    line-height: 1;
}

.ttcar-contact-text {
    font-size: 16px;
    font-weight: 500;
    color: #333333;
    text-decoration: none;
    transition: color 0.2s;
    word-break: break-all;
	line-height:26px;
}

a.ttcar-contact-email:hover { color: #D29C34; }

/* ── Follow + social icons ── */
.ttcar-follow-row {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-top: 18px;
    padding-top: 14px;
    border-top: 1px solid rgba(11, 49, 94, 0.09);
}

.ttcar-follow-label {
    font-size: 9.5px;
    font-weight: 700;
    color: #D29C34;
    text-transform: uppercase;
    letter-spacing: 2.5px;
    flex-shrink: 0;
}

.ttcar-socials {
    display: flex;
    align-items: center;
    gap: 7px;
    flex-wrap: wrap;
}

.ttcar-social-link {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 32px;
    height: 32px;
    border-radius: 50%;
    background: rgba(11, 49, 94, 0.10);
    color: #0B315E;
    text-decoration: none;
    transition: background 0.22s, color 0.22s, transform 0.18s;
    flex-shrink: 0;
}

.ttcar-social-link:hover {
    background: #D29C34;
    transform: translateY(-2px) scale(1.1);
}

.ttcar-social-link i {
    font-size: 12px !important;
    color: inherit !important;
    display: block;
    line-height: 1;
    pointer-events: none;
}

.ttcar-social-link:hover i { color: #ffffff !important; }

/* =============================================================
   RESPONSIVE  ▸  Large Tablet  1025px – 1280px
   ============================================================= */

@media (max-width: 1280px) {
    .ttcar-wrap        { height: 460px; }
    .ttcar-heading     { font-size: 20px; }
    .ttcar-counter-num { font-size: 44px; }
    .ttcar-thumb       { width: 62px; height: 76px; }
    .ttcar-detail-bio  { font-size: 15px; }
    .ttcar-detail-role { font-size: 18px; }
}

/* =============================================================
   RESPONSIVE  ▸  Tablet  769px – 1024px
   ============================================================= */

@media (max-width: 1024px) {
    .ttcar-wrap {
        grid-template-columns: 1fr 1.15fr 1.25fr;
        height: 440px;
        border-radius: 14px;
    }

    .ttcar-col-left  { padding: 28px 22px 22px; }
    .ttcar-heading   { font-size: 17px; margin-bottom: 12px; }

    .ttcar-counter-num   { font-size: 38px; }
    .ttcar-counter-total { font-size: 12px; }

    .ttcar-thumb    { width: 56px; height: 68px; border-radius: 8px; }
    .ttcar-thumbs   { gap: 8px; }

    .ttcar-detail-panel { padding: 26px 22px 22px; }
    .ttcar-detail-name  { font-size: 20px; }
    .ttcar-detail-role  { font-size: 16px; }
    .ttcar-detail-bio   { font-size: 14px; line-height: 1.7; }
    .ttcar-contact-text { font-size: 12px; }
}

/* =============================================================
   RESPONSIVE  ▸  Mobile  ≤ 768px
   ============================================================= */

@media (max-width: 768px) {

    /* ── Grid: stack vertically ──
       IMPORTANT: !important overrides the Elementor inline height style */
    .ttcar-wrap {
        grid-template-columns: 1fr !important;
        grid-template-rows: auto auto auto !important;
        height: auto !important;      /* override Elementor inline style */
        min-height: 0 !important;
        border-radius: 14px;
        box-shadow: 0 4px 28px rgba(11, 49, 94, 0.13);
        overflow: visible;            /* allow col-center to use explicit height */
    }

    /* ── Left column ── */
    .ttcar-col-left {
        order: 1;
        padding: 24px 20px 18px;
        height: auto !important;      /* prevent Elementor height leak */
        overflow: visible;
    }
    .ttcar-col-left::after { display: none; }

    .ttcar-eyebrow  { font-size: 8.5px; letter-spacing: 2.5px; }
    .ttcar-heading  { font-size: 17px; margin-bottom: 10px; }

    /* Counter: override margin-bottom: auto so thumbs appear right after */
    .ttcar-counter-wrap {
        margin-bottom: 14px !important;
        padding-bottom: 0;
    }
    .ttcar-counter-num   { font-size: 36px; }
    .ttcar-counter-sep   { font-size: 14px; }
    .ttcar-counter-total { font-size: 12px; }

    /* Thumbnails: horizontal scroll strip — never wrap */
    .ttcar-thumbs {
        flex-wrap: nowrap;
        overflow-x: auto;
        overflow-y: visible;
        padding-bottom: 4px;
        gap: 10px;
        align-items: center;
        -webkit-overflow-scrolling: touch;
        scrollbar-width: none;
    }
    .ttcar-thumbs::-webkit-scrollbar { display: none; }
    .ttcar-thumb { width: 62px; height: 74px; flex-shrink: 0; }

    /* ── Center column: photo at explicit height ── */
    .ttcar-col-center {
        order: 2;
        height: 600px !important;     /* explicit — prevents collapse */
        position: relative;
        overflow: hidden;
    }
    .ttcar-col-center::after { display: none; }

    /* Photo stage fills the explicit height */
    .ttcar-photo-stage {
        position: absolute;
        inset: 0;
    }

    /* ── Right column: natural height, panels as blocks ── */
    .ttcar-col-right {
        order: 3;
        height: auto !important;
        overflow: visible;
        border-left: none;
        border-top: 1px solid rgba(11, 49, 94, 0.08);
    }

    /* Panels: reset to normal flow — JS toggles display */
    .ttcar-detail-panel {
        position: relative !important;
        inset: auto !important;
        opacity: 1 !important;
        transform: none !important;
        transition: none !important;
        pointer-events: auto !important;
        display: none;
        height: auto !important;
        overflow-y: visible;
        padding: 22px 20px 26px;
    }

    .ttcar-detail-panel.is-active {
        display: block;
        animation: ttcar-panel-in 0.38s ease both;
    }

    /* Adjust text sizes for mobile panel */
    .ttcar-detail-name { font-size: 20px; }
    .ttcar-detail-role { font-size: 16px; }
    .ttcar-detail-bio  { font-size: 14px; line-height: 1.72; }
    .ttcar-contact-text { font-size: 12.5px; }
}

/* =============================================================
   RESPONSIVE  ▸  Small Mobile  ≤ 480px
   ============================================================= */

@media (max-width: 480px) {
    .ttcar-wrap      { border-radius: 12px; }

    .ttcar-col-left  { padding: 18px 16px 14px; }
    .ttcar-heading   { font-size: 15px; }
    .ttcar-eyebrow   { font-size: 8px; letter-spacing: 2px; }

    .ttcar-counter-num   { font-size: 30px; letter-spacing: -1.5px; }
    .ttcar-counter-sep   { font-size: 12px; }
    .ttcar-counter-total { font-size: 11px; }

    .ttcar-thumb { width: 54px; height: 66px; border-radius: 8px; }
    .ttcar-thumbs { gap: 8px; }

    .ttcar-col-center { height: 250px !important; }

    .ttcar-detail-panel { padding: 18px 16px 22px; }
    .ttcar-detail-name  { font-size: 18px; }
    .ttcar-detail-role  { font-size: 14px; }
    .ttcar-detail-bio   { font-size: 13px; }
    .ttcar-contact-text { font-size: 11.5px; }

    .ttcar-follow-row { margin-top: 14px; padding-top: 12px; }
    .ttcar-social-link { width: 30px; height: 30px; }
    .ttcar-social-link i { font-size: 11px !important; }
}

/* =============================================================
   ANIMATION
   ============================================================= */

@keyframes ttcar-panel-in {
    from { opacity: 0; transform: translateY(10px); }
    to   { opacity: 1; transform: translateY(0); }
}
