/* ==========================================================================
   Team Filter widget
   Fully self-contained: the filter controls, the card, and the skeleton loader
   are all styled here with unique classes, so this widget no longer depends on
   team-archive.css and can be restyled without affecting the other team widgets.
   ========================================================================== */

/* --------------------------------------------------------------------------
   Filter controls
   -------------------------------------------------------------------------- */
.team-filter-archive .filter-heading {
    font-family: "Klavika", Sans-serif;
    font-size: 20px;
    line-height: 120%;
    font-weight: 400;
    color: #000000;
    margin-bottom: 10px;
}

.team-filter-archive .team-filter-controls {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 20px;
    margin-bottom: 64px;
}

.team-filter-archive .team-filter-select {
    position: relative;
    cursor: pointer;
    background-repeat: no-repeat;
    background-position: right 16px center;
    background-size: 12px 12px;
    padding: 12px 48px 12px 16px;
    font-family: "Klavika", Sans-serif;
    font-size: 20px;
    line-height: 120%;
    font-weight: 400;
    appearance: none;
    -webkit-appearance: none;
    -moz-appearance: none;
    border: none;
    border-radius: 4px;
    min-width: 220px;
}

.team-filter-archive select#team-filter-functie {
    background-color: var(--mid-purple-color);
    background-image: url('../../icons/chevcon-arrow-down-primary.svg');
    color: var(--primary-color);
}

.team-filter-archive select#team-filter-sector {
    background-color: var(--primary-color);
    background-image: url('../../icons/chevcon-arrow-down-purple.svg');
    color: var(--mid-purple-color);
}

.team-filter-archive button#team-filter-reset {
    margin-left: auto;
    font-family: "Klavika", Sans-serif;
    font-size: 16px;
    font-weight: 500;
    line-height: 16px;
    fill: var(--magenta-color);
    color: var(--magenta-color);
    position: relative;
    padding: 0 24px 0 0;
    background-color: unset;
    border: none;
    cursor: pointer;
}

.team-filter-archive button#team-filter-reset::after {
    content: '';
    position: absolute;
    right: 0;
    top: 50%;
    transform: translateY(-50%);
    width: 12px;
    height: 12px;
    transition: transform 0.5s ease;
    background-image: url('../../icons/button-cross-magenta.svg');
    background-size: cover;
}

.team-filter-archive button#team-filter-reset:hover::after {
    transform: translateY(-50%) translateX(5px);
}

/* --------------------------------------------------------------------------
   Grid + cards (unique to this widget)
   -------------------------------------------------------------------------- */
.team-filter-grid-items {
    display: flex;
    flex-wrap: wrap;
    gap: 20px;
}

.team-filter-card {
    width: calc(25% - 15px);
    box-sizing: border-box;
    /* Hover: lift the card up; the transition is what makes it smooth */
    transition: transform 0.3s ease;
    will-change: transform;
}

.team-filter-card__image-link {
    display: block;
    overflow: hidden;         /* keeps the scaled photo inside the rounded frame */
    border-radius: 8px;
    margin-bottom: 16px;
}

/* Selector doubled so it beats Elementor's `.elementor img { height: auto }` */
.team-filter-card .team-filter-card__image {
    display: block;
    width: 100%;
    height: 400px;
    object-fit: cover;
    object-position: center;
    border-radius: 8px;
    transition: transform 0.4s ease;
    will-change: transform;
}

.team-filter-card__name {
    font-family: "Klavika", Sans-serif;
    font-size: 24px;
    font-weight: 400;
    line-height: 120%;
    color: #000;
    margin: 0 0 8px;
    transition: color 0.3s ease;
}

.team-filter-card__name-link {
    color: inherit;
    text-decoration: none;
}

.team-filter-card__functie {
    font-family: "Klavika", Sans-serif;
    font-size: 18px;
    line-height: 120%;
    color: #000;
}

/* Hover effect: card moves up, photo scales to 1.05 */
.team-filter-card:hover {
    transform: translateY(-8px);
}

.team-filter-card:hover .team-filter-card__image {
    transform: scale(1.05);
}

.team-filter-card:hover .team-filter-card__name {
    color: var(--magenta-color);
}

.team-filter-archive .team-filter-empty {
    font-family: "Klavika", Sans-serif;
    font-size: 20px;
    color: #000000;
}

/* --------------------------------------------------------------------------
   Skeleton loader (unique to this widget)
   -------------------------------------------------------------------------- */
.team-filter-skeleton {
    display: flex;
    flex-wrap: wrap;
    gap: 20px;
}

.team-filter-skeleton__member {
    width: calc(25% - 15px);
    box-sizing: border-box;
    border-radius: 8px;
    overflow: hidden;
}

.team-filter-skeleton__image,
.team-filter-skeleton__text {
    background: linear-gradient(90deg, #d4d4d4 25%, #e6e6e6 50%, #d4d4d4 75%);
    background-size: 200% 100%;
    animation: team-filter-shimmer 2s infinite;
}

.team-filter-skeleton__image {
    width: 100%;
    height: 400px;
    margin-bottom: 16px;
    border-radius: 8px;
}

.team-filter-skeleton__text {
    margin: 8px;
    height: 20px;
    border-radius: 4px;
}

@keyframes team-filter-shimmer {
    0% { background-position: -200% 0; }
    100% { background-position: 200% 0; }
}

/* --------------------------------------------------------------------------
   Responsive
   -------------------------------------------------------------------------- */
@media (max-width: 1240px) {
    .team-filter-card,
    .team-filter-skeleton__member {
        width: calc(33.333% - 14px);
    }
}

@media (max-width: 768px) {
    .team-filter-archive .team-filter-controls {
        flex-direction: column;
        align-items: stretch;
    }

    .team-filter-archive .team-filter-select {
        width: 100%;
    }

    .team-filter-archive button#team-filter-reset {
        margin-left: 0;
        align-self: flex-end;
        margin-top: 10px;
    }

    .team-filter-card,
    .team-filter-skeleton__member {
        width: calc(50% - 10px);
    }

    .team-filter-card .team-filter-card__image,
    .team-filter-skeleton__image {
        height: 300px;
    }
}
