.sgs-staff-group {
    margin: 2rem 0;
    --sgs-card-scale: 1;
    --sgs-card-base-width: 220px;
    --sgs-surface: var(--wp--preset--color--base, var(--wp--preset--color--background, Canvas));
    font-family: inherit;
    color: inherit;
}

.sgs-staff-group__header h2 {
    margin: 0 0 1rem;
}

.sgs-staff-group__items {
    display: grid;
    gap: 1rem;
}

.sgs-staff-group--tiles .sgs-staff-group__items {
    grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
    justify-items: center;
}

.sgs-staff-group--tiles .sgs-staff-card {
    width: calc(var(--sgs-card-base-width) * var(--sgs-card-scale));
    max-width: 100%;
}

.sgs-staff-group--scroller {
    position: relative;
    overflow: hidden;
}

.sgs-staff-group--scroller::before,
.sgs-staff-group--scroller::after {
    content: '';
    position: absolute;
    top: 0;
    bottom: 0;
    width: clamp(24px, 4vw, 56px);
    z-index: 2;
    pointer-events: none;
}

.sgs-staff-group--scroller::before {
    left: 0;
    background: linear-gradient(to right, var(--sgs-fade-color, #ffffff) 0%, rgba(255, 255, 255, 0) 100%);
}

.sgs-staff-group--scroller::after {
    right: 0;
    background: linear-gradient(to left, var(--sgs-fade-color, #ffffff) 0%, rgba(255, 255, 255, 0) 100%);
}

.sgs-staff-group--scroller .sgs-staff-group__items {
    display: flex;
    gap: 1rem;
    width: max-content;
    will-change: transform;
}

.sgs-staff-group--scroller .sgs-staff-group__items.is-scroll-animated {
    animation: sgs-staff-scroll var(--sgs-scroll-duration, 24s) linear infinite;
}

.sgs-staff-group--scroller .sgs-staff-group__items.is-scroll-animated:hover,
.sgs-staff-group--scroller .sgs-staff-group__items.is-scroll-animated:focus-within,
.sgs-staff-group--scroller.is-scroller-paused .sgs-staff-group__items.is-scroll-animated {
    animation-play-state: paused;
}

.sgs-staff-group--scroller .sgs-staff-card {
    width: calc(var(--sgs-card-base-width) * var(--sgs-card-scale));
    flex: 0 0 auto;
}

.sgs-staff-group--compact-list .sgs-staff-group__items {
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
}

.sgs-staff-group--compact-list .sgs-staff-card {
    flex-direction: row;
    align-items: center;
    border-radius: 12px;
}

.sgs-staff-group--compact-list .sgs-staff-card__media {
    width: calc(72px * var(--sgs-card-scale));
    min-width: calc(72px * var(--sgs-card-scale));
    height: calc(72px * var(--sgs-card-scale));
    aspect-ratio: auto;
    border-radius: 50%;
    margin: 0.75rem;
}

.sgs-staff-group--compact-list .sgs-staff-card__body {
    padding: 0.75rem 1rem 0.75rem 0;
}

.sgs-staff-group--single-slider .sgs-staff-group__slider-wrap,
.sgs-staff-group--multi-carousel .sgs-staff-group__slider-wrap {
    display: flex;
    align-items: center;
    gap: 0.75rem;
}

.sgs-staff-group--single-slider .sgs-staff-group__slider-wrap {
    position: relative;
    gap: 0;
}

.sgs-staff-group--single-slider .sgs-staff-group__items,
.sgs-staff-group--multi-carousel .sgs-staff-group__items {
    overflow: hidden;
    display: block;
    flex: 1;
}

.sgs-staff-group--single-slider .sgs-staff-group__items {
    width: 100%;
    min-width: 0;
}

.sgs-staff-group--single-slider .sgs-staff-group__track,
.sgs-staff-group--multi-carousel .sgs-staff-group__track {
    display: flex;
    gap: 1rem;
    width: max-content;
}

.sgs-staff-group--single-slider .sgs-staff-group__track {
    width: 100%;
    gap: 0;
}

.sgs-staff-group--single-slider .sgs-staff-card {
    flex: 0 0 100%;
    width: min(100%, calc(360px * var(--sgs-card-scale)));
    margin: 0 auto;
}

.sgs-staff-group--multi-carousel .sgs-staff-card {
    flex: 0 0 calc(var(--sgs-card-base-width) * var(--sgs-card-scale));
    width: calc(var(--sgs-card-base-width) * var(--sgs-card-scale));
}

.sgs-staff-group__nav {
    width: 40px;
    height: 40px;
    border: 1px solid color-mix(in srgb, currentColor 30%, transparent);
    background: var(--sgs-surface);
    color: inherit;
    border-radius: 999px;
    cursor: pointer;
    font-size: 20px;
    line-height: 1;
    display: flex;
    align-items: center;
    justify-content: center;
}

.sgs-staff-group--single-slider .sgs-staff-group__nav {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    z-index: 3;
}

.sgs-staff-group--single-slider .sgs-staff-group__nav--prev {
    left: 8px;
}

.sgs-staff-group--single-slider .sgs-staff-group__nav--next {
    right: 8px;
}

.sgs-staff-group__dots {
    margin-top: 0.75rem;
    display: flex;
    gap: 0.5rem;
    justify-content: center;
}

.sgs-staff-group__dot {
    width: 10px;
    height: 10px;
    border-radius: 999px;
    border: 0;
    background: color-mix(in srgb, currentColor 25%, transparent);
    cursor: pointer;
}

.sgs-staff-group__dot.is-active {
    width: 24px;
    background: color-mix(in srgb, currentColor 65%, transparent);
}

.sgs-staff-card {
    display: flex;
    flex-direction: column;
    width: 100%;
    font-size: calc(16px * var(--sgs-card-scale));
    border: 1px solid rgba(127, 127, 127, 0.32);
    border-color: color-mix(in srgb, currentColor 24%, transparent);
    border-radius: calc(18px * var(--sgs-card-scale));
    background: var(--sgs-surface);
    color: inherit;
    overflow: hidden;
    box-shadow: 0 14px 32px rgba(35, 52, 74, 0.08);
}

.sgs-staff-card:hover,
.sgs-staff-card:focus-within {
    transform: translateY(calc(-2px * var(--sgs-card-scale)));
    box-shadow: 0 18px 36px rgba(35, 52, 74, 0.14);
}

.sgs-staff-card__media img {
    display: block;
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: center top;
}

.sgs-staff-card__media {
    aspect-ratio: 3 / 4;
    overflow: hidden;
    background: color-mix(in srgb, currentColor 8%, transparent);
}

.sgs-staff-card__media--placeholder {
    background: #e5e7eb;
}

.sgs-staff-card__placeholder {
    display: block;
    width: 100%;
    height: 100%;
}

.sgs-staff-card__body {
    padding: 1em;
}

.sgs-staff-card__title {
    margin: 0 0 0.75em;
    font-size: 1.125em;
}

.sgs-staff-card__meta {
    margin: 0 0 0.5em;
    color: inherit;
    opacity: 0.82;
    font-size: 0.9em;
}

.sgs-staff-card__description p:last-child {
    margin-bottom: 0;
}

.sgs-staff-modal[hidden] {
    display: none;
}

.sgs-staff-modal {
    position: fixed;
    inset: 0;
    z-index: 9999;
    display: flex;
    justify-content: center;
    align-items: flex-start;
    padding: 72px 12px 20px;
    overflow-y: auto;
}

.sgs-staff-modal__backdrop {
    position: absolute;
    inset: 0;
    background: rgba(14, 22, 35, 0.6);
}

.sgs-staff-modal__dialog {
    position: relative;
    z-index: 1;
    width: min(680px, calc(100vw - 24px));
    margin: 0 auto;
    background: var(--sgs-surface);
    color: inherit;
    border-radius: 12px;
    padding: 18px;
    box-shadow: 0 20px 50px rgba(12, 22, 35, 0.28);
}

.sgs-staff-modal__photo-wrap {
    display: flex;
    justify-content: center;
    margin: 0 0 14px;
}

.sgs-staff-modal__photo {
    display: block;
    max-width: 100%;
    max-height: 360px;
    height: auto;
    object-fit: contain;
    border-radius: 12px;
    cursor: zoom-in;
}

.sgs-staff-modal__close {
    position: absolute;
    top: 8px;
    right: 10px;
    border: 0;
    background: transparent;
    font-size: 28px;
    line-height: 1;
    cursor: pointer;
}

.sgs-staff-modal__title {
    margin: 0 0 8px;
    font-size: 1.35rem;
}

.sgs-staff-modal__position,
.sgs-staff-modal__category,
.sgs-staff-modal__tenure {
    margin: 0 0 8px;
    color: inherit;
    opacity: 0.9;
    font-size: 0.93rem;
}

.sgs-staff-modal__description {
    font-size: 0.93rem;
    line-height: 1.45;
}

.sgs-staff-modal-open {
    overflow: hidden;
}

.sgs-staff-lightbox[hidden] {
    display: none;
}

.sgs-staff-lightbox {
    position: fixed;
    inset: 0;
    z-index: 10000;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 20px;
}

.sgs-staff-lightbox__backdrop {
    position: absolute;
    inset: 0;
    background: rgba(0, 0, 0, 0.86);
}

.sgs-staff-lightbox__image {
    position: relative;
    z-index: 1;
    display: block;
    width: auto;
    height: auto;
    max-width: calc(100vw - 40px);
    max-height: calc(100vh - 40px);
    object-fit: contain;
}

.sgs-staff-lightbox-open {
    overflow: hidden;
}

@keyframes sgs-staff-scroll {
    0% {
        transform: translateX(0);
    }

    100% {
        transform: translateX(calc(-1 * var(--sgs-scroll-distance, 0px)));
    }
}

@media (prefers-reduced-motion: reduce) {
    .sgs-staff-group--scroller .sgs-staff-group__items {
        animation: none;
    }
}

@media (max-width: 640px) {
    .sgs-staff-modal {
        padding-top: 56px;
    }

    .sgs-staff-group--scroller .sgs-staff-group__items {
        display: grid;
        width: auto;
        animation: none;
    }

    .sgs-staff-group--scroller .sgs-staff-card {
        width: auto;
    }

    .sgs-staff-group--multi-carousel .sgs-staff-card {
        flex: 0 0 100%;
        width: 100%;
    }

    .sgs-staff-group__nav {
        width: 34px;
        height: 34px;
        font-size: 16px;
    }

    .sgs-staff-group--single-slider .sgs-staff-group__nav--prev {
        left: 4px;
    }

    .sgs-staff-group--single-slider .sgs-staff-group__nav--next {
        right: 4px;
    }
}