/* 변호사 공개 프로필 — 위촉·감사장 섹션 (style5_1.css의 경력/학력 섹션 패턴과 동일한 레이아웃) */

.credentials {
    padding: 70px 20px 20px;
    box-sizing: border-box;
}

.credentials-inner {
    max-width: var(--wrap-max, 1200px);
    margin: 0 auto;
    display: grid;
    grid-template-columns: 200px 1fr;
    gap: 50px;
    align-items: start;
}

.credentials-title {
    width: auto;
    margin: 0;
}

.credentials-title h3 {
    font-size: 26px;
    color: var(--main-navi, #1c3d6e);
    border-bottom: 3px solid var(--main-navi, #1c3d6e);
    padding-bottom: 10px;
    margin: 0;
}

.credentials-content {
    width: 100%;
}

.credential-grid {
    list-style: none;
    margin: 0;
    padding: 0;
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 24px;
}

.credential-card {
    margin: 0;
}

.credential-zoom {
    display: block;
    text-decoration: none;
    color: inherit;
}

.credential-card figure {
    margin: 0;
    border: 1px solid #e2e5ea;
    border-radius: 10px;
    overflow: hidden;
    background: #fff;
    transition: box-shadow .2s ease, transform .2s ease;
}

.credential-zoom:hover figure,
.credential-zoom:focus-visible figure {
    box-shadow: 0 6px 18px rgba(28, 61, 110, .14);
    transform: translateY(-2px);
}

.credential-card img {
    display: block;
    width: 100%;
    height: auto;
    background: #fff;
}

.credential-card figcaption {
    padding: 10px 12px 12px;
    border-top: 1px solid #eef0f3;
}

.credential-card figcaption strong {
    display: block;
    font-size: 14px;
    line-height: 1.45;
    color: #222;
    font-weight: 600;
}

.credential-card figcaption span {
    display: block;
    margin-top: 4px;
    font-size: 13px;
    color: #6b7280;
}

/* 라이트박스 */
.credential-lightbox {
    position: fixed;
    inset: 0;
    z-index: 2000;
    background: rgba(10, 14, 22, .82);
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 40px 20px;
    box-sizing: border-box;
}

.credential-lightbox[hidden] {
    display: none;
}

.credential-lightbox img {
    max-width: min(92vw, 900px);
    max-height: 78vh;
    object-fit: contain;
    border-radius: 8px;
    background: #fff;
}

.credential-lightbox p {
    margin: 14px 0 0;
    color: #fff;
    font-size: 15px;
    text-align: center;
}

.credential-lightbox-close {
    position: absolute;
    top: 18px;
    right: 22px;
    width: 44px;
    height: 44px;
    border: 0;
    border-radius: 50%;
    background: rgba(255, 255, 255, .14);
    color: #fff;
    font-size: 26px;
    line-height: 1;
    cursor: pointer;
}

.credential-lightbox-close:hover {
    background: rgba(255, 255, 255, .28);
}

@media (max-width: 900px) {
    .credentials-inner {
        grid-template-columns: 1fr;
        gap: 24px;
    }

    /* 좁은 화면에서 카드 1개가 가로 전체를 차지하지 않도록 항상 2열 고정 */
    .credential-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
        gap: 16px;
    }
}
