/* ============================================================
   Team Grid v2 — Hunter Advisors style
   ============================================================ */

.av2-wrapper { position: relative; }

/* ── Section ── */
.av2-section { background: #1c2628; padding: 60px 0 80px; }
.av2-section .page-head { margin-bottom: 36px; }
.av2-section .page-title { color: #fff; }
.av2-section .title-rule { border-color: rgba(255,255,255,.15); }

/* ── Filter Tabs — horizontal desktop ── */
.av2-tabs {
    display: flex;
    flex-direction: row;
    flex-wrap: wrap;
    gap: 0;
    margin-bottom: 40px;
    margin-top: 16px;
    border-bottom: 1px solid rgba(255,255,255,.12);
}
.av2-tab {
    background: none;
    border: none;
    border-bottom: 2px solid transparent;
    margin-bottom: -1px;
    color: rgba(255,255,255,.4);
    font-family: var(--f-head);
    font-weight: 600;
    font-size: 13px;
    letter-spacing: .07em;
    text-transform: uppercase;
    padding: 10px 22px 12px;
    cursor: pointer;
    transition: color .2s, border-color .2s;
    white-space: nowrap;
}
.av2-tab:hover { color: rgba(255,255,255,.8); }
.av2-tab.active { color: #fff; border-bottom-color: var(--lime); }

/* ── Grid ── */
.av2-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 24px 14px;
    align-items: start;
}

/* ── Card ── */
.av2-card { display: flex; flex-direction: column; cursor: pointer; }

.av2-photo {
    width: 100%;
    aspect-ratio: 1 / 1;
    background-size: cover;
    background-position: center top;
    background-color: #2e3c3f;
    position: relative;
    overflow: hidden;
}
.av2-photo-overlay {
    position: absolute;
    inset: 0;
    background: rgba(46,125,75,.0);
    transition: background .25s;
    display: flex;
    align-items: center;
    justify-content: center;
}
.av2-card:hover .av2-photo-overlay { background: rgba(46,125,75,.3); }
.av2-card.av2-active .av2-photo-overlay { background: rgba(46,125,75,.4); }
.av2-view-label {
    color: #fff;
    font-family: var(--f-head);
    font-size: 11px;
    font-weight: 700;
    letter-spacing: .1em;
    text-transform: uppercase;
    opacity: 0;
    transition: opacity .25s;
    background: rgba(0,0,0,.4);
    padding: 5px 12px;
}
.av2-card:hover .av2-view-label { opacity: 1; }

.av2-info { padding: 10px 0 0; display: flex; flex-direction: column; flex: 1; }
.av2-name { font-family: var(--f-head); font-weight: 700; font-size: 14px; color: #fff; line-height: 1.3; margin-bottom: 2px; }
.av2-role { font-size: 11px; color: rgba(255,255,255,.55); line-height: 1.4; flex: 1; margin-bottom: 8px; display: flex; flex-direction: column; gap: 1px; }
.av2-location { display: block; font-size: 11px; color: rgba(255,255,255,.35); }
.av2-bio-btn {
    display: inline-block;
    background: none;
    border: none;
    color: var(--lime);
    font-family: var(--f-head);
    font-size: 11px;
    font-weight: 700;
    letter-spacing: .07em;
    text-transform: uppercase;
    padding: 0;
    cursor: pointer;
    transition: color .2s;
    align-self: flex-start;
    text-decoration: underline;
    text-underline-offset: 3px;
}
.av2-bio-btn:hover { color: #fff; }
.av2-card.av2-active .av2-bio-btn { color: #fff; }

/* ── Bio Panel — inside grid, spans full width ── */
.av2-bio-panel {
    grid-column: 1 / -1;
    background: #fff;
    position: relative;
    overflow: hidden;
    /* Always in DOM — animate via max-height + opacity */
    max-height: 0;
    opacity: 0;
    padding-top: 0;
    padding-bottom: 0;
    transition:
        max-height .5s cubic-bezier(.4,0,.2,1),
        opacity .4s ease,
        padding .4s ease;
    pointer-events: none;
}
.av2-bio-panel[hidden] { display: block !important; }
.av2-bio-panel.open {
    max-height: 1200px;
    opacity: 1;
    padding: 40px 44px 44px;
    pointer-events: auto;
}

/* Arrow */
.av2-panel-arrow {
    position: absolute;
    top: -11px;
    left: 40px;
    width: 0;
    height: 0;
    border-left: 11px solid transparent;
    border-right: 11px solid transparent;
    border-bottom: 11px solid #fff;
    transition: left .25s ease;
    z-index: 2;
}

/* Close */
.av2-close {
    position: absolute;
    top: 14px;
    right: 14px;
    width: 30px;
    height: 30px;
    background: #f0f0f0;
    border: none;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    color: #666;
    transition: background .2s, color .2s;
    padding: 0;
}
.av2-close:hover { background: var(--forest); color: #fff; }
.av2-close svg { width: 14px; height: 14px; }

/* Bio layout */
.av2-bio-inner { display: grid; grid-template-columns: 200px 1fr; gap: 36px; align-items: start; }
.av2-bio-photo img { width: 100%; aspect-ratio: 1 / 1; object-fit: cover; object-position: top; display: block; }
.av2-bio-name { font-family: var(--f-head); font-size: 22px; font-weight: 700; color: var(--ink); margin: 0 0 2px; }
.av2-bio-role { font-size: 12px; color: var(--forest); font-weight: 700; text-transform: uppercase; letter-spacing: .06em; margin: 0 0 16px; display: flex; flex-direction: column; gap: 2px; }
.av2-bio-loc { display: block; font-size: 12px; color: var(--ink-2); font-weight: 400; letter-spacing: .02em; text-transform: none; }
.av2-bio-contacts { display: flex; flex-direction: column; gap: 7px; margin-bottom: 18px; padding-bottom: 18px; border-bottom: 1px solid #e4e8ea; }
.av2-bio-contacts a { display: inline-flex; align-items: center; gap: 8px; font-size: 13px; color: var(--ink-2); text-decoration: none; transition: color .2s; }
.av2-bio-contacts a:hover { color: var(--forest); }
.av2-bio-contacts svg { width: 14px; height: 14px; flex-shrink: 0; }
.av2-bio-text { font-size: 14px; line-height: 1.85; color: var(--ink); }
.av2-bio-text p { margin: 0 0 12px; }
.av2-bio-text p:last-child { margin: 0; }

/* ── Responsive ── */
@media (max-width: 900px) {
    .av2-grid { grid-template-columns: repeat(3, 1fr); gap: 16px 12px; }
    .av2-tabs { flex-direction: column; border-bottom: none; margin-bottom: 28px; }
    .av2-tab { border-bottom: 1px solid rgba(255,255,255,.08); border-left: 2px solid transparent; padding: 12px 0; text-align: left; white-space: normal; }
    .av2-tab.active { border-bottom-color: rgba(255,255,255,.08); border-left-color: var(--lime); padding-left: 12px; color: #fff; }
}
@media (max-width: 600px) {
    .av2-grid { grid-template-columns: repeat(2, 1fr); gap: 14px 10px; }
    .av2-bio-inner { grid-template-columns: 1fr; gap: 18px; }
    .av2-bio-panel.open { padding: 24px 16px; }
    .av2-bio-name { font-size: 18px; }
    .av2-section { padding: 40px 0 60px; }
}
