#contact .officer-grid {
    display: grid;
    grid-template-columns: repeat(1, minmax(0, 1fr));
    gap: 0.9rem;
    align-items: start;
}

@media (min-width: 34em) {
    #contact .officer-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
}

@media (min-width: 62em) {
    #contact .officer-grid {
        grid-template-columns: repeat(4, minmax(0, 1fr));
    }
}

#contact .officer-card {
    position: relative;
    z-index: 1;
}

#contact .officer-card:hover,
#contact .officer-card:focus-within,
#contact .officer-card.is-open {
    z-index: 20;
}

#contact .officer-card-hitbox {
    width: 100%;
    height: 100%;
    padding:0;
    text-align: left;
    border: none;
    background: #f4f4f4;
    cursor: pointer;
}

#contact .officer-card-hitbox:focus {
    outline: 2px solid #6e2;
    outline-offset: 2px;
}

#contact .officer-photo {
    width: 100%;
    overflow: hidden;
    background-color: #d8d8d8;
    transition:300ms;
}

#contact .officer-photo img {
    width: 100%;
    aspect-ratio: 4 / 3;
    object-fit: cover;
    object-position: center;
}

#contact .officer-summary {
    margin: 1rem;
}

#contact .officer-name {
    margin: 0;
    font-size: 1rem;
    line-height: 1.2;
}

#contact .officer-role {
    margin: 0.3rem 0 0;
    font-size: 0.84rem;
    line-height: 1.2;
}

#contact .officer-popup {
    max-height: 0;
    overflow: hidden;
    opacity: 0;
    padding: 0 0.95rem;
    box-shadow: 0 5px 5px #00000022;
    background:white;
    transition: max-height 300ms, opacity 300ms, padding 300ms;
}

#contact .officer-card:hover .officer-popup,
#contact .officer-card:focus-within .officer-popup,
#contact .officer-card.is-open .officer-popup {
    max-height: 500px;
    opacity: 1;
    padding: 0.85rem 0.95rem;
    transition-delay: 0s;
}

#contact .officer-popup p {
    margin: 0 0 0.65rem;
    line-height: 1.42;
    font-size: 0.89rem;
}

#contact .officer-popup p:last-child {
    margin-bottom: 0;
}

#contact .officer-game strong {
    font-weight: 600;
}

#contact .officer-links {
    display: grid;
    gap: 0.35rem;
    margin-top: 0.7rem;
    padding-top: 0.6rem;
    border-top: 1px solid rgba(255, 255, 255, 0.2);
}

#contact .officer-link {
    color: #8ce95d;
    font-size: 0.86rem;
    line-height: 1.2;
    overflow-wrap: anywhere;
}

#contact .officer-link:hover,
#contact .officer-link:focus {
    color: #baf48c;
    text-decoration: none;
}

@media (max-width: 34em) {
    #contact .officer-popup {
        /* Mobile styles can go here if needed */
    }
}
