/* ============================================================
   FloreData — Section 5 THE TEAM
   Spec: floredata/design/specs/landing-section5.md
   ============================================================ */

.fd-section--team {
    --andrew-accent:   #5E8836;
    --aron-accent:     #AD34D0;
    --riccardo-accent: #4C4CC8;
    --musa-accent:     #D5803F;
    background: var(--wp--preset--color--background);
    padding: 64px 0 56px;       /* tighten bottom 72→56 (Sandro 2026-06-28: gap to How-We-Work too big) */
    overflow: hidden;
}

/* --- 2-column header ------------------------------------------------ */

.fd-team__header {
    display: grid;
    grid-template-columns: 1.05fr 1fr;
    gap: clamp(40px, 6vw, 110px);
    align-items: center;   /* balance L/R cols — the heading column was top-aligned → big void below (Sandro 2026-06-28) */
    max-width: 1440px;   /* was 1660 — overflowed the nav pill (1441px); align to header + team band (1438px) */
    margin: 0 auto;
    padding: 0 40px;
}

/* --- Eyebrow chip (deep-Royal accented) ------------------------------ */

.fd-eyebrow--team {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    padding: 6px 20px 6px 6px;
    background: #EAEAEA;                        /* same chip bg as Results */
    color: var(--wp--preset--color--primary);
    border-radius: 999px;
    font-family: var(--wp--preset--font-family--satoshi);
    font-weight: 700;
    font-size: 0.875rem;
    letter-spacing: 0.08em;
    line-height: 1;
}

.fd-eyebrow--team .fd-eyebrow__badge {
    background: var(--wp--preset--color--primary);
    color: #ffffff;
    border-radius: 10px;                        /* squircle, not circle (.ai) */
    width: 32px;
    height: 27px;
    display: inline-grid;
    place-items: center;
    flex: none;
}

.fd-eyebrow--team .fd-eyebrow__badge svg {
    width: 15px;
    height: 15px;
    display: block;
}

/* --- Heading ---------------------------------------------------------- */

.fd-team__heading {
    font-family: var(--wp--preset--font-family--satoshi);
    font-weight: 300;                           /* Light — pixel-confirmed, pdfplumber says Bold */
    font-style: normal;
    font-size: clamp(2.8rem, 1.3rem + 4.3vw, 5.97rem);   /* 95.5px @1920 */
    line-height: 1.04;
    letter-spacing: -0.015em;
    color: var(--wp--preset--color--text);
    margin: 0 0 38px;           /* tightened from 67 so the heading+CTA read as one centred block (Sandro 2026-06-28) */
}

.fd-team__heading em {
    font-weight: 700;
    font-style: italic;                         /* slant .ai-confirmed */
}

/* --- Header CTAs ------------------------------------------------------ */

.fd-team__ctas {
    display: flex;
    gap: 16px;
    flex-wrap: wrap;
}

.fd-btn--team {
    display: inline-flex;
    align-items: center;
    gap: 14px;
    padding: 13px 13px 13px 26px;   /* pill height 61px — .ai-measured */
    border-radius: 999px;
    font-weight: 700;
    font-size: 1.22rem;                         /* 19.5px */
    line-height: 1;
    text-decoration: none;
    transition: transform 0.3s cubic-bezier(0.16, 1, 0.3, 1);
}

/* explicit hover colors — GP's global a:hover otherwise overrides them */
.fd-btn--team-story:hover {
    transform: translateY(-2px);
    background: var(--wp--preset--color--mulberry);
    color: var(--wp--preset--color--text);
}

.fd-btn--team-work:hover {
    transform: translateY(-2px);
    background: var(--wp--preset--color--primary);
    color: var(--wp--preset--color--background);
}

.fd-btn--team .fd-btn-arrow {
    width: 36px;
    height: 36px;
    flex: none;
}

.fd-btn--team-story {
    background: var(--wp--preset--color--bloom);
    color: var(--wp--preset--color--text);
}

.fd-btn--team-work {
    background: var(--wp--preset--color--primary-soft);
    color: var(--wp--preset--color--background);
}

/* --- Header right column ----------------------------------------------
   Padding-top drops the subtitle to heading-line-1 level (.ai y117) */

.fd-team__header-right {
    padding-top: 128px;
}

.fd-team__subtitle {
    font-weight: 700;
    font-style: italic;
    font-size: clamp(1.4rem, 0.9rem + 1vw, 1.875rem);     /* 30px */
    line-height: 1.25;
    color: var(--wp--preset--color--text);
    margin: 0 0 22px;
}

.fd-team__body {
    font-weight: 400;                           /* Regular — pixel-confirmed */
    font-style: normal;
    font-size: clamp(1.05rem, 0.95rem + 0.3vw, 1.25rem);  /* 20px */
    line-height: 1.75;                          /* .ai: 35px leading on 20px */
    color: #161616;
    margin: 0;
}

/* Divider + label-beside-chips row (.ai: Bloom rule y334, label x1087, chips x1251) */
.fd-team__expertise {
    display: flex;
    align-items: flex-start;
    gap: 27px;
    border-top: 2px solid #DCD2FA;
    margin-top: 47px;
    padding-top: 12px;
}

.fd-team__expertise-label {
    flex: none;
    font-weight: 400;                           /* thin — pixel-confirmed, pdfplumber says Bold */
    font-style: italic;
    font-size: 1.5rem;                          /* 24px */
    color: #000000;
    margin: 8px 0 0;                            /* optically centers vs first chip row */
}

.fd-team__expertise-chips {
    display: grid;
    grid-template-columns: repeat(2, max-content);  /* never shrink — text must stay inside the pill */
    gap: 12px 14px;
    list-style: none;
    margin: 0;
    padding: 0;
}

.fd-team__expertise-chips li {
    display: inline-flex;
    align-items: center;
    gap: 13px;                                  /* dot→text 13px (.ai) */
    background: var(--wp--preset--color--sage);
    color: var(--wp--preset--color--growth);
    font-weight: 500;                           /* Medium — pixel-confirmed, pdfplumber says Bold */
    font-size: 1.3rem;                          /* 20.9px */
    line-height: 1;
    padding: 12px 26px 12px 18px;               /* .ai chip anatomy: h46, L18, R26 */
    border-radius: 999px;
    white-space: nowrap;
}

.fd-chip-dot {
    width: 18px;                                /* .ai-measured 18-19px */
    height: 18px;
    border-radius: 50%;
    background: currentColor;
    flex: none;
}

/* --- Punchy band + staggered cards -------------------------------------
   Band top lands 263px below the top-row card top (.ai: y842 vs y579);
   342px here calibrates against the rendered DOM (screenshot-verified) */

.fd-team__band {
    position: relative;
    margin-top: 126px;
    padding: 0 40px 64px;
}

.fd-team__band::before {
    content: "";
    position: absolute;
    inset: 263px 0 0 0;
    background: var(--wp--preset--color--punchy);
}

.fd-team__cards {
    position: relative;
    list-style: none;
    margin: 0 auto;
    padding: 0;
    max-width: 1438px;                          /* .ai-measured row span 227–1665 */
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 16px;
    align-items: start;
}

.fd-team-card {
    position: relative;
    transition: transform 0.35s cubic-bezier(0.16, 1, 0.3, 1);
}

.fd-team-card:hover { transform: translateY(-5px); }

/* Asymmetric stagger — .ai-measured photo tops (riccardo/andrew = top row) */
.fd-team-card--aron { margin-top: 136px; }
.fd-team-card--musa { margin-top: 94px; }

.fd-team-card__photo {
    position: relative;
    margin: 0;
    border-radius: 22px;
    overflow: hidden;
    aspect-ratio: 346 / 470;
}

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

/* No CSS overlay — the violet gradient is baked into the team photos
   (Geetha's card exports, swapped in 2026-06-12) */
.fd-team-card__photo figcaption {
    position: absolute;
    inset: auto 0 0 0;
    padding: 110px 26px 38px;
    color: var(--wp--preset--color--background);
}

.fd-team-card__photo figcaption strong {
    display: block;
    font-size: clamp(1.5rem, 1rem + 1vw, 2.29rem);        /* 36.6px */
    font-weight: 700;
    line-height: 1.15;
}

.fd-team-card__photo figcaption span {
    display: block;
    font-size: clamp(1.05rem, 0.85rem + 0.6vw, 1.6rem);   /* 25.7px */
    font-weight: 500;                           /* Medium — pixel-confirmed */
    opacity: 0.92;
    margin-top: 2px;
}

/* Personality pill — straddles the photo's bottom edge, centered */
.fd-team-card__pill {
    position: absolute;
    left: 50%;
    bottom: 0;
    transform: translate(-50%, 45%);
    display: inline-flex;
    align-items: center;
    gap: 10px;
    padding: 5px 18px 5px 5px;
    border-radius: 999px;
    font-size: 0.72rem;                         /* ~11.5px */
    font-weight: 700;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    color: #F8F1FD;
    white-space: nowrap;
    z-index: 1;
}

.fd-team-card__pill-badge {
    width: 42px;
    height: 32px;
    background: var(--wp--preset--color--background);
    border-radius: 11px;
    display: grid;
    place-items: center;
    flex: none;
}

.fd-team-card__pill-badge img {
    height: 20px;
    width: auto;
    display: block;
}

.fd-team-card--andrew   .fd-team-card__pill { background: var(--andrew-accent); }
.fd-team-card--aron     .fd-team-card__pill { background: var(--aron-accent); }
.fd-team-card--riccardo .fd-team-card__pill { background: var(--riccardo-accent); }
.fd-team-card--musa     .fd-team-card__pill { background: var(--musa-accent); }

/* --- Bottom centered CTA (on the band) --------------------------------- */

.fd-team__cta {
    position: relative;
    width: fit-content;
    margin: 58px auto 0;       /* .ai CTA y1245 — calibrated against rendered DOM */
    display: flex;
    align-items: center;
    gap: 14px;
    background: var(--wp--preset--color--surface-dark);
    color: #F6F6F6;
    font-weight: 700;
    font-style: italic;                         /* slant .ai-confirmed */
    font-size: 1.3rem;                          /* 20.8px */
    line-height: 1;
    padding: 8px 8px 8px 28px;
    border-radius: 999px;
    text-decoration: none;
    transition: transform 0.3s cubic-bezier(0.16, 1, 0.3, 1);
}

/* dark→primary on hover (typography.css .fd-btn--dark convention);
   text stays cream — GP's a:hover would otherwise darken it to invisible */
.fd-team__cta:hover {
    transform: translateY(-2px);
    background: var(--wp--preset--color--primary);
    color: #F6F6F6;
}

.fd-team__cta:hover .fd-btn-arrow { transform: translateX(3px); }

.fd-team__cta .fd-btn-arrow { transition: transform 0.3s cubic-bezier(0.16, 1, 0.3, 1); }

.fd-team__cta .fd-btn-arrow {
    width: 38px;
    height: 38px;
    flex: none;
}

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

@media (max-width: 1100px) {
    .fd-team__header {
        grid-template-columns: 1fr;
        gap: 48px;
    }

    .fd-team__header-right { padding-top: 0; }

    /* nowrap 2×max-content grid forces the column wider than small
       viewports — switch to a wrapping flex row below 1100px */
    .fd-team__expertise-chips {
        display: flex;
        flex-wrap: wrap;
    }
    .fd-team__expertise-chips li { white-space: normal; }

    .fd-team__band { margin-top: 88px; }

    .fd-team__cards {
        grid-template-columns: repeat(2, 1fr);
        gap: 20px;
        max-width: 760px;
    }

    /* 2-up: keep a hint of the stagger on the right column */
    .fd-team-card--aron     { margin-top: 64px; }
    .fd-team-card--musa     { margin-top: 64px; }
    .fd-team-card--riccardo { margin-top: 0; }

    .fd-team__band::before { inset: 20% 0 0 0; }
}

@media (max-width: 640px) {
    .fd-section--team { padding: 56px 0 56px; }   /* tighter mobile rhythm (was 80px bottom → big gap) */

    .fd-team__header { padding: 0 24px; }
    .fd-team__heading { margin-bottom: 36px; }

    /* r6: header CTAs → full-width, stacked, centred label (site-wide mobile standard) */
    .fd-team__ctas { flex-direction: column; align-items: stretch; gap: 12px; }
    .fd-btn--team { width: 100%; justify-content: center; box-sizing: border-box; }

    .fd-team__expertise { flex-direction: column; gap: 14px; }
    .fd-team__expertise-label { margin-top: 0; }
    .fd-team__expertise-chips li { font-size: 1.1rem; }

    .fd-team__band { padding: 0 18px 56px; }

    /* r7: 2-up team grid on mobile (was a single tall stack) — reads as a designed
       team wall, not 4 giant cards. Figcaption + pill scaled down to fit ~165px cards. */
    .fd-team__cards {
        grid-template-columns: 1fr 1fr;
        max-width: 440px;
        gap: 12px;
        row-gap: 40px;                          /* room for the hanging pills */
    }
    .fd-team-card--aron,
    .fd-team-card--musa,
    .fd-team-card--riccardo { margin-top: 0; }  /* no stagger at 2-up mobile */

    .fd-team-card__photo figcaption { padding: 64px 14px 16px; }
    .fd-team-card__photo figcaption strong { font-size: 1.15rem; }
    .fd-team-card__photo figcaption span { font-size: 0.82rem; }

    .fd-team-card__pill { font-size: 0.6rem; padding: 4px 12px 4px 4px; gap: 7px; }
    .fd-team-card__pill-badge { width: 30px; height: 23px; border-radius: 8px; }
    .fd-team-card__pill-badge img { height: 14px; }

    .fd-team__cta { font-size: 1.1rem; }

    .fd-team__band::before { inset: 12% 0 0 0; }
}

@media (prefers-reduced-motion: reduce) {
    .fd-team-card,
    .fd-btn--team,
    .fd-team__cta {
        transition: none;
    }

    .fd-team-card:hover { transform: none; }
}

/* Make each Team-section card a link to the member's /team/ profile (stretched
   link — overlays the card, leaves the verified photo/figcaption/pill layout intact). */
.fd-team-card { transition: transform 0.2s ease; }
.fd-team-card:hover { transform: translateY(-5px); }
.fd-team-card__link {
    position: absolute;
    inset: 0;
    z-index: 5;                 /* above the (transparent-to-view) pill so the whole card clicks */
    border-radius: 16px;
}
.fd-team-card__link:focus-visible {
    outline: 3px solid #6E2DEB;
    outline-offset: -3px;
    border-radius: 16px;
}
