/* ============================================================
   People Page — page-people.php
   ============================================================ */

/* ── CSS variables ── */
.people-firm-section {
    --people-blue: #1c3963;
    --people-ink:  #17272b;
    --people-muted: #687385;
    --people-line:  #d8dee7;
    font-family: "Graphik-Font", sans-serif;
}

/* ── Hero ── */
.people-hero {
    position: relative;
    min-height: 320px;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 80px 24px 70px;
    overflow: hidden;
    background:
        linear-gradient(rgba(0,0,0,0.55), rgba(0,0,0,0.55)),
        url("../images/people-hero.jpeg") top center / cover no-repeat;
    background-attachment: fixed;
}

.people-hero__inner {
    width: min(1160px, 100%);
    margin: 0 auto;
    position: relative;
    z-index: 1;
    text-align: center;
}

.people-hero__inner h1 {
    color: #ffffff;
    font-size: 44px;
    font-weight: 700;
    line-height: 1.4;
    letter-spacing: 0;
    margin: 0;
    font-family: "Graphik-Font", sans-serif;
    text-transform: capitalize;
}

.people-hero__inner p {
    color: rgba(255, 255, 255, 0.82);
    font-size: 18px;
    font-weight: 400;
    line-height: 1.6;
    margin: 14px 0 0;
    font-family: "Graphik-Font", sans-serif;
}

/* ── Page body ── */
.people-page {
    background: #eef1f5;
}

/* ── Grid container ── */
.people-grid-section {
    padding: 0 0 80px;
}

.people-grid-inner {
    width: 100%;
    margin: 0 auto;
}

/* ── Shared section base ── */
.people-firm-section {
    position: relative;
    overflow: hidden;
}

/* ── MANAGEMENT SECTION ── */
.people-management-section {
    margin: 0 calc(50% - 50vw);
    padding: clamp(48px, 5vw, 72px) max(24px, calc((100vw - 1180px) / 2)) clamp(58px, 6vw, 82px);
    background: #eef1f5;
}

.people-management-section .firm-section-title {
    position: relative;
    color: var(--people-blue);
    font-size: clamp(36px, 4vw, 54px);
    font-weight: 800;
    line-height: 1.1;
    letter-spacing: 0;
    text-align: left;
    margin: 0 0 30px;
    padding: 0;
    border: 0;
    background: none;
}

.people-management-section .firm-section-title::after {
    content: "Founders";
    display: block;
    margin-top: 8px;
    color: var(--people-muted);
    font-size: 13px;
    font-weight: 600;
    letter-spacing: 2.8px;
    text-transform: uppercase;
}

.people-management-section .firm-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: clamp(22px, 2.4vw, 32px);
}

.people-management-section .firm-card {
    border-radius: 10px;
    overflow: hidden;
    border: 1px solid rgba(28, 57, 99, 0.28);
    background: var(--people-blue);
    box-shadow: 0 18px 44px rgba(28, 57, 99, 0.18);
}

.people-management-section .firm-image-wrapper {
    position: relative;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: flex-start;
    border-radius: 10px;
    height: 440px;
    min-height: 440px;
    padding: 32px 26px 30px;
    background: var(--people-blue);
    cursor: default;
    overflow: hidden;
}

/* hexagon pattern overlay */
.people-management-section .firm-image-wrapper::before {
    content: "";
    position: absolute;
    inset: 0;
    z-index: 0;
    pointer-events: none;
    background-image: url("../images/people-founders-pattern.png");
    background-position: center;
    background-size: cover;
    background-repeat: no-repeat;
    opacity: 0.12;
    mix-blend-mode: screen;
}

.people-management-section .firm-image-wrapper::after {
    display: none;
}

.people-management-section .firm-image-wrapper img {
    position: relative;
    z-index: 1;
    width: 210px;
    height: 210px;
    flex: 0 0 210px;
    margin: 0 0 22px;
    border-radius: 50%;
    object-fit: cover;
    object-position: top center;
    border: 4px solid rgba(248, 250, 252, 0.34);
    background: #f8fafc;
    filter: saturate(0.98) contrast(1.02);
    transition: none;
}

.people-management-section .firm-hover-content {
    position: static;
    display: flex;
    z-index: 1;
    flex: 1;
    flex-direction: column;
    align-items: center;
    width: 100%;
    text-align: center;
    opacity: 1;
    visibility: visible;
    color: #f8fafc;
    bottom: auto;
    transition: none;
}

.people-management-section .firm-hover-content h3 {
    display: flex;
    align-items: center;
    justify-content: center;
    min-height: 64px;
    color: #f8fafc;
    font-size: clamp(22px, 1.8vw, 30px);
    font-weight: 700;
    line-height: 1.12;
    margin: 0 0 8px;
}

.people-management-section .hover-designation {
    display: flex;
    align-items: center;
    justify-content: center;
    min-height: 30px;
    color: rgba(248, 250, 252, 0.72);
    font-size: 13px;
    letter-spacing: 1.7px;
    margin: 0 0 12px;
}

.people-management-section .action-links {
    display: flex;
    justify-content: center;
    margin-top: auto;
    gap: 10px;
    min-height: 34px;
}

.people-management-section .action-links .linkedin-link,
.people-management-section .action-links .popup-arrow {
    width: 32px;
    height: 32px;
    flex: 0 0 32px;
    border-radius: 50%;
    border: 1px solid rgba(248, 250, 252, 0.42);
    background: #f8fafc;
    color: var(--people-blue);
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-size: 15px;
    line-height: 1;
    padding: 0;
    margin: 0;
    box-sizing: border-box;
    text-decoration: none;
    cursor: pointer;
    transition: background 0.2s, color 0.2s;
}

.people-management-section .action-links .linkedin-link:hover,
.people-management-section .action-links .popup-arrow:hover {
    background: var(--people-blue);
    color: #fff;
    border-color: rgba(248, 250, 252, 0.6);
}

/* ── TEAM SECTION ── */
.people-team-section {
    margin: 0 calc(50% - 50vw);
    padding: clamp(52px, 5vw, 76px) 0 clamp(60px, 6vw, 88px);
    background: #eef1f5;
}

.people-team-section .firm-section-title {
    max-width: 1200px;
    margin: 0 auto 28px;
    padding: 0 24px;
    color: var(--people-blue);
    font-size: clamp(30px, 4vw, 48px);
    font-weight: 800;
    line-height: 1.1;
    text-align: left;
    border: 0;
    background: none;
}

.people-team-section .firm-section-title::after {
    content: "The best Finance people in India";
    display: block;
    margin-top: 8px;
    color: var(--people-muted);
    font-size: 14px;
    font-weight: 500;
    letter-spacing: 0;
    text-transform: none;
}

.people-team-section .firm-grid {
    display: grid;
    grid-template-columns: repeat(5, minmax(0, 1fr));
    width: min(1200px, calc(100% - 48px));
    gap: 22px;
    margin: 0 auto;
    padding: 4px 0 16px;
}

.people-team-section .firm-card {
    border: 1px solid var(--people-line);
    border-radius: 10px;
    background: #f8fafc;
    box-shadow: 0 10px 28px rgba(28, 57, 99, 0.08);
    overflow: hidden;
    transition: box-shadow 0.22s ease, transform 0.22s ease;
}

.people-team-section .firm-card:hover {
    box-shadow: 0 18px 40px rgba(28, 57, 99, 0.15);
    transform: translateY(-3px);
}

.people-team-section .firm-image-wrapper {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: flex-start;
    height: 322px;
    min-height: 322px;
    padding: 24px 16px 22px;
    border-radius: 10px;
    cursor: default;
    overflow: visible;
    background: transparent;
}

.people-team-section .firm-image-wrapper::after {
    display: none;
}

.people-team-section .firm-image-wrapper::before {
    display: none;
}

.people-team-section .firm-image-wrapper img {
    width: 154px;
    height: 154px;
    flex: 0 0 154px;
    margin: 0 0 18px;
    border-radius: 50%;
    object-fit: cover;
    object-position: top center;
    border: 3px solid rgba(28, 57, 99, 0.12);
    transition: transform 0.28s ease, border-color 0.28s ease;
    position: static;
}

.people-team-section .firm-card:hover .firm-image-wrapper img {
    transform: translateY(-3px);
    border-color: rgba(28, 57, 99, 0.34);
}

.people-team-section .firm-hover-content {
    position: static;
    display: flex;
    flex: 1;
    flex-direction: column;
    align-items: center;
    opacity: 1;
    visibility: visible;
    width: 100%;
    color: var(--people-ink);
    text-align: center;
    margin-top: 0;
    bottom: auto;
    transition: none;
}

.people-team-section .firm-hover-content h3 {
    display: flex;
    align-items: center;
    justify-content: center;
    min-height: 40px;
    color: var(--people-ink);
    font-size: 15px;
    font-weight: 700;
    line-height: 1.25;
    margin: 0 0 7px;
}

.people-team-section .hover-designation {
    display: flex;
    align-items: center;
    justify-content: center;
    min-height: 30px;
    color: var(--people-muted);
    font-size: 11px;
    letter-spacing: 1px;
    text-transform: uppercase;
    line-height: 1.35;
    margin: 0 0 12px;
}

.people-team-section .action-links {
    display: flex;
    justify-content: center;
    margin-top: auto;
    gap: 8px;
    min-height: 28px;
}

.people-team-section .action-links .linkedin-link,
.people-team-section .action-links .popup-arrow {
    width: 26px;
    height: 26px;
    flex: 0 0 26px;
    border-radius: 50%;
    border: 1px solid rgba(28, 57, 99, 0.16);
    background: rgba(28, 57, 99, 0.06);
    color: var(--people-blue);
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-size: 12px;
    line-height: 1;
    padding: 0;
    margin: 0;
    box-sizing: border-box;
    text-decoration: none;
    cursor: pointer;
    transition: background 0.2s, color 0.2s, border-color 0.2s;
}

.people-team-section .action-links .linkedin-link:hover,
.people-team-section .action-links .popup-arrow:hover {
    background: var(--people-blue);
    color: #fff;
    border-color: var(--people-blue);
}

/* ── POPUP ── */
.firm-popup {
    position: fixed;
    inset: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 28px;
    background: rgba(11, 22, 38, 0.72);
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.22s ease;
    z-index: 99999;
}

.firm-popup.is-active {
    opacity: 1;
    pointer-events: auto;
}

body.firm-popup-open {
    overflow: hidden;
}

.firm-popup-content {
    position: relative;
    display: grid;
    grid-template-columns: minmax(260px, 360px) minmax(0, 1fr);
    width: min(1120px, calc(100vw - 48px));
    max-height: min(82vh, 720px);
    overflow: hidden;
    background: #f8fafc;
    border: 1px solid rgba(248, 250, 252, 0.28);
    border-radius: 8px;
    box-shadow: 0 30px 90px rgba(8, 19, 35, 0.32);
    transform: translateY(12px) scale(0.98);
    transition: transform 0.22s ease;
}

.firm-popup.is-active .firm-popup-content {
    transform: translateY(0) scale(1);
}

.firm-close {
    position: absolute;
    top: 16px;
    right: 16px;
    z-index: 3;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 38px;
    height: 38px;
    padding: 0;
    border: 1px solid rgba(28, 57, 99, 0.12);
    border-radius: 50%;
    background: #ffffff;
    color: var(--people-blue);
    cursor: pointer;
    font-size: 26px;
    line-height: 1;
    box-shadow: 0 10px 26px rgba(28, 57, 99, 0.12);
    transition: background 0.18s, color 0.18s;
}

.firm-close:hover {
    background: var(--people-blue);
    color: #ffffff;
    border-color: var(--people-blue);
}

/* Popup left panel */
.firm-popup-left {
    display: flex;
    flex-direction: column;
    justify-content: center;
    min-height: 560px;
    padding: 42px 36px;
    background: linear-gradient(155deg, #1c3963 0%, #132946 100%);
    color: #ffffff;
}

.firm-popup-image-shell {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 230px;
    height: 230px;
    margin: 0 auto 28px;
    border-radius: 50%;
    border: 4px solid rgba(248, 250, 252, 0.26);
    background: #f8fafc;
    overflow: hidden;
    box-shadow: 0 20px 50px rgba(0, 0, 0, 0.24);
    flex-shrink: 0;
}

.firm-popup-image-shell img {
    display: block;
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: top center;
}

.firm-popup-label {
    margin: 0 0 8px;
    color: rgba(248, 250, 252, 0.7);
    font-size: 12px;
    font-weight: 700;
    letter-spacing: 2px;
    text-transform: uppercase;
    font-family: "Graphik-Font", sans-serif;
}

.firm-popup-left h3 {
    margin: 0 0 10px;
    color: #ffffff;
    font-family: "Graphik-Font", sans-serif;
    font-size: clamp(24px, 2.2vw, 34px);
    font-weight: 800;
    line-height: 1.1;
}

.firm-popup-left p {
    margin: 0;
    color: rgba(248, 250, 252, 0.74);
    font-size: 14px;
    font-weight: 700;
    letter-spacing: 1.4px;
    text-transform: uppercase;
    font-family: "Graphik-Font", sans-serif;
}

.firm-popup-actions {
    display: flex;
    gap: 10px;
    margin-top: 26px;
}

.firm-popup-actions a {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 38px;
    height: 38px;
    border-radius: 50%;
    border: 1px solid rgba(248, 250, 252, 0.34);
    background: rgba(248, 250, 252, 0.1);
    color: #ffffff;
    text-decoration: none;
    font-size: 16px;
    transition: background 0.18s, color 0.18s;
}

.firm-popup-actions a:hover {
    background: #ffffff;
    color: var(--people-blue);
}

/* Popup right panel */
.firm-popup-right {
    min-width: 0;
    padding: clamp(36px, 4vw, 58px);
    padding-right: clamp(48px, 5vw, 72px);
    overflow-y: auto;
}

.firm-popup-kicker {
    margin: 0 0 10px;
    color: var(--people-muted);
    font-size: 12px;
    font-weight: 800;
    letter-spacing: 2px;
    text-transform: uppercase;
    font-family: "Graphik-Font", sans-serif;
}

.firm-popup-right h2 {
    margin: 0 0 22px;
    color: var(--people-ink);
    font-family: "Graphik-Font", sans-serif;
    font-size: clamp(30px, 3vw, 48px);
    font-weight: 800;
    line-height: 1.06;
    text-transform: none;
    padding: 0;
    border: 0;
}

.firm-popup-bio {
    color: #5e6674;
    font-size: clamp(16px, 1.25vw, 20px);
    line-height: 1.65;
    font-family: "Graphik-Font", sans-serif;
}

.firm-popup-bio p {
    margin: 0 0 18px;
    color: inherit;
    font-size: inherit;
    line-height: inherit;
}

.firm-popup-bio strong {
    color: var(--people-ink);
    font-weight: 700;
}

.firm-popup-loading {
    padding: 32px 0;
    color: var(--people-muted);
    font-size: 15px;
    font-family: "Graphik-Font", sans-serif;
}

/* ── Responsive ── */
@media (max-width: 980px) {
    .people-management-section .firm-grid {
        grid-template-columns: 1fr;
        max-width: 520px;
        margin: 0 auto;
    }

    .people-management-section .firm-section-title {
        max-width: 520px;
        margin-left: auto;
        margin-right: auto;
    }

    .people-management-section .firm-image-wrapper {
        height: 420px;
        min-height: 420px;
    }

    .people-management-section .firm-image-wrapper img {
        width: 200px;
        height: 200px;
        flex-basis: 200px;
    }

    .people-team-section .firm-grid {
        grid-template-columns: repeat(3, minmax(0, 1fr));
    }

    .firm-popup-content {
        grid-template-columns: 1fr;
        max-height: 88vh;
    }

    .firm-popup-left {
        min-height: auto;
        padding: 32px 30px;
    }

    .firm-popup-image-shell {
        width: 170px;
        height: 170px;
        margin-bottom: 20px;
    }

    .firm-popup-right {
        padding: 32px 30px 36px;
    }
}

@media (max-width: 767px) {
    .people-hero {
        min-height: 240px;
        padding: 60px 18px 54px;
        background-attachment: scroll;
    }
    .people-hero__inner h1 { font-size: 32px; }
    .people-grid-section   { padding: 0 0 60px; }
}

@media (max-width: 576px) {
    .people-management-section,
    .people-team-section {
        margin: 0;
    }

    .people-management-section .firm-image-wrapper {
        height: 400px;
        min-height: 400px;
        padding: 28px 18px 26px;
    }

    .people-management-section .firm-image-wrapper img {
        width: 180px;
        height: 180px;
        flex-basis: 180px;
    }

    .people-team-section .firm-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
        width: min(100% - 28px, 520px);
        gap: 14px;
    }

    .people-team-section .firm-image-wrapper img {
        width: 132px;
        height: 132px;
        flex-basis: 132px;
    }

    .firm-popup {
        padding: 14px;
    }

    .firm-popup-content {
        width: calc(100vw - 28px);
        max-height: 90vh;
    }

    .firm-close {
        top: 10px;
        right: 10px;
        width: 34px;
        height: 34px;
        font-size: 24px;
    }

    .firm-popup-left {
        padding: 28px 22px;
    }

    .firm-popup-image-shell {
        width: 146px;
        height: 146px;
    }

    .firm-popup-right {
        padding: 26px 22px 30px;
    }
}

@media (max-width: 480px) {
    .people-hero__inner h1 { font-size: 26px; }
}
