﻿/* About Us page */

.about-hero {
    min-height: 0;
    padding: clamp(3rem, 8vw, 6rem) 0;
}

/* ---------- Story ---------- */

.about-story {
    padding-bottom: 1rem;
}

.about-story__title {
    margin: 0 0 1rem;
    font-size: clamp(1.5rem, 3vw, 2rem);
    font-weight: 700;
    color: var(--afc-navy);
}

.about-story__block {
    margin-bottom: 1.25rem;
}

.about-story__heading {
    margin: 0 0 .25rem;
    font-size: 1rem;
    font-weight: 700;
    color: var(--afc-navy);
}

.about-story__text p {
    margin: 0 0 .5rem;
    line-height: 1.6;
}

/* ---------- Team ---------- */

.about-team__title {
    margin-bottom: 2.25rem;
    padding-bottom: 1rem;
    position: relative;
}

.about-team__title::after {
    content: "";
    position: absolute;
    left: 50%;
    bottom: 0;
    width: 80px;
    height: 3px;
    margin-left: -40px;
    background: var(--afc-red);
}

.about-team__grid {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 1.25rem;
}

.team-card {
    display: flex;
    flex-direction: column;
    align-items: center;
    padding: 0;
    background: none;
    border: 0;
    text-align: center;
    cursor: pointer;
    color: inherit;
}

.team-card__photo {
    display: block;
    width: 100%;
    aspect-ratio: 3 / 4;
    overflow: hidden;
    background: #dfe8ef;
    transition: transform .2s;
}

.team-card:hover .team-card__photo,
.team-card:focus-visible .team-card__photo {
    transform: translateY(-3px);
}

.team-card__photo img,
.team-card__placeholder {
    display: block;
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.team-card__name {
    margin-top: .75rem;
    font-size: 1.05rem;
    font-weight: 700;
    line-height: 1.2;
    color: var(--afc-red);
}

.team-card__role {
    margin-top: .2rem;
    font-size: .85rem;
    line-height: 1.3;
}

/* Detail panel (shown below the grid) */

.team-detail {
    position: relative;
    display: grid;
    grid-template-columns: minmax(0, 300px) minmax(0, 1fr);
    margin-top: 2.5rem;
    background: var(--afc-navy);
    color: #fff;
    scroll-margin-top: 90px;
}

.team-detail[hidden] {
    display: none;
}

.team-detail__photo {
    position: relative;
    min-height: 380px;
    background: #17324c;
}

.team-detail__img,
.team-detail__placeholder {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.team-detail__img[hidden] {
    display: none;
}

.team-detail__photo::after {
    content: "";
    position: absolute;
    inset: 40% 0 0;
    background: linear-gradient(transparent, rgba(0, 0, 0, .75));
}

.team-detail__caption {
    position: absolute;
    left: 1.5rem;
    right: 1rem;
    bottom: 1.25rem;
    z-index: 1;
    display: flex;
    flex-direction: column;
}

.team-detail__name {
    font-size: clamp(1.4rem, 2.4vw, 2rem);
    font-weight: 700;
    line-height: 1.1;
}

.team-detail__role {
    font-size: 1rem;
}

.team-detail__body {
    padding: clamp(1.5rem, 3vw, 2.5rem);
}

.team-detail__heading {
    margin: 0 0 .75rem;
    font-size: 1.15rem;
    font-weight: 700;
    color: #fff;
}

.team-detail__text {
    margin: 0;
    font-size: 1rem;
    line-height: 1.9;
}

.team-detail__close {
    position: absolute;
    top: .5rem;
    right: .75rem;
    width: 2rem;
    height: 2rem;
    padding: 0;
    background: none;
    border: 0;
    font-size: 1.75rem;
    line-height: 1;
    color: #fff;
    cursor: pointer;
}

/* ---------- Responsive ---------- */

@media (max-width: 1199.98px) {
    .about-team__grid {
        grid-template-columns: repeat(4, minmax(0, 1fr));
        gap: 1.5rem 1.25rem;
    }
}

@media (max-width: 767.98px) {
    .about-team__grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .team-detail {
        grid-template-columns: minmax(0, 1fr);
    }

    .team-detail__photo {
        min-height: 0;
        aspect-ratio: 4 / 3;
    }

    .team-detail__text {
        line-height: 1.7;
    }
}

