/* ===========================
   Team Cards – Full Stylesheet (Final)
   =========================== */

/* -------- Tokens -------- */
.team-cards {
    --tc-gap: 16px;
    --tc-radius: 16px;
    --tc-dark: #08193D;
    --tc-accent: #75B9FF;
    --tc-text: #08193DB2;
    margin-bottom: 100px;
}

button {
    border: 0;
}

/* -------- Tabs -------- */
.tc-tabs {
    display: flex;
    gap: 28px;
    margin-bottom: 18px;
    justify-content: center;
}

.tc-tab {
    position: relative;
    background: transparent;
    padding: 24px 16px;
    font-weight: 600;
    font-size: 24px;
    text-transform: uppercase;
    cursor: pointer;
    color: var(--tc-text);
    box-shadow: none;
}

@media screen and (max-width: 767px) {
    .tc-tab {
        font-size: 18px;
        padding: 6px;
    }
}


.tc-tab:hover, .tc-tab:focus {
    background: none;
    color: var(--tc-dark);
}

.tc-tab.is-active {
    opacity: 1;
    color: var(--tc-dark);
}

.tc-tab::after {
    content: "";
    position: absolute;
    left: 0;
    right: 0;
    bottom: -1px;
    height: 2px;
    background: #EEEEEE;
    border-top-left-radius: 2px;
    border-top-right-radius: 2px;
}

.tc-tab.is-active::after {
    content: "";
    position: absolute;
    left: 0;
    right: 0;
    bottom: -1px;
    height: 4px;
    background: currentColor;
    border-top-left-radius: 4px;
    border-top-right-radius: 4px;
}

/* -------- Panels -------- */
.tc-panel {
    display: none;
}

.tc-panel.is-active {
    display: block;
}

/* -------- Desktop Grid (2 per row, centered) -------- */
.tc-grid {
    display: grid;
    grid-template-columns: repeat(2, 420px);
    column-gap: var(--tc-gap);
    row-gap: calc(var(--tc-gap) + 8px);
    justify-content: center;
}

@media (max-width: 767px) {
    .tc-grid {
        display: none;
    }

    /* hide grid, show slider */
}

/* -------- Card Base (fixed 420x480, no jumping) -------- */
.tc-card {
    position: relative;
    overflow: hidden;
    border-radius: var(--tc-radius);
    background: var(--tc-dark);
    width: 420px;
    height: 480px;
    outline: none;
}

/* Focus ring */
.tc-card:focus-visible {
    box-shadow: 0 0 0 3px rgba(0, 120, 255, .45);
}

/* Layers fill full card area */
.tc-card-media,
.tc-card-gradient,
.tc-card-meta,
.tc-bio {
    position: absolute;
    inset: 0;
    z-index: 1;
}

/* Image layer */
.tc-card-media {
    background: #e5e7eb;
}

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

.tc-card-placeholder {
    width: 100%;
    height: 100%;
    background: #e5e7eb;
}

/* Gradient + meta overlay */
.tc-card-gradient {
    background: linear-gradient(180deg, rgba(0, 0, 0, 0) 40%, rgba(0, 0, 0, .55) 100%);
    pointer-events: none;
    transition: opacity .35s ease, transform .35s ease;
}

.tc-card-meta {
    inset: auto 16px 16px 16px;
    color: #fff;
    transition: opacity .35s ease, transform .35s ease;
}

/* Decorative SVG background */
.tc-card::before {
    content: "";
    position: absolute;
    inset: 0;
    background-image: url('star.svg');
    background-repeat: no-repeat;
    background-size: 80% auto;
    background-position: -20% 100%;
    opacity: 0;
    transition: opacity .35s ease;
    pointer-events: none;
    z-index: 0;
}

/* Typography */
.tc-name {
    margin: 0 0 6px 0;
    font-size: 24px;
    line-height: 32px;
    text-transform: uppercase;
    font-weight: 600;
    color: #fff;
    font-family: "Montserrat";
}

.tc-position {
    color: var(--tc-accent);
    font-weight: 600;
}

/* -------- Bio Panel (animated) -------- */
.tc-bio {
    padding: 20px;
    color: #fff;
    background: var(--tc-dark);
    overflow: auto;
    opacity: 0;
    transform: translateY(10px);
    pointer-events: none;
    transition: opacity .35s ease, transform .35s ease;
}

.tc-bio .tc-position {
    color: var(--tc-accent);
    margin-bottom: 10px;
    font-size: 20px;
    line-height: 32px;
    font-weight: 600;
}

.tc-bio-text p {
    margin: 0 0 10px;
}

/* --- Toggle State --- */
.tc-card.is-bio .tc-card-media,
.tc-card.is-bio .tc-card-gradient,
.tc-card.is-bio .tc-card-meta {
    opacity: 0;
    transform: translateY(-6px);
}

.tc-card.is-bio .tc-bio {
    opacity: 1;
    transform: translateY(0);
    pointer-events: auto;
}

.tc-card.is-bio::before {
    opacity: 1;
}

/* Reduced motion */
@media (prefers-reduced-motion: reduce) {
    .tc-card *,
    .tc-bio,
    .tc-card-gradient,
    .tc-card-meta {
        transition: none !important;
    }
}

/* -------- Mobile / Splide -------- */
.tc-splide {
    display: none;
}

@media (max-width: 767px) {
    .tc-splide {
        display: block;
        overflow: hidden;
    }

    .tc-splide .splide__slide {
        padding: 0 4px;
    }

    .tc-card {
        width: 100%;
        height: auto;
        aspect-ratio: 7 / 8; /* 420x480 ratio maintained */
    }

    /* Hide arrows & dots just in case (also disabled via JS) */
    .tc-splide .splide__arrow,
    .tc-splide .splide__pagination {
        display: none !important;
    }

    /* Allow a peek of the next slide */
    .tc-splide .splide__track {
        overflow-x: hidden;
        overflow-y: visible;
    }

    @supports (overflow-x: clip) {
        .tc-splide .splide__track {
            overflow-x: clip;
        }
    }

    /* so rounded corners don't clip */
    .tc-splide .splide__list {
        align-items: stretch;
    }

    /* Width < 100% makes the next card visible; tweak to taste (85–92%) */
    .tc-splide .splide__slide {
        width: 88%;
    }

    /* Make the card fill the slide width cleanly */
    .tc-splide .tc-card {
        width: 100%;
        height: auto;
        aspect-ratio: 7 / 8; /* ~420x480 proportion */
    }
}

/* Optional: empty state */
.tc-empty {
    margin: 12px 0 0;
    color: #6b7280;
    font-style: italic;
}
