.container {
    max-width: 1200px;
    margin: 0 auto;
}

h1 {
    text-align: center;
    margin-bottom: 40px;
    font-size: 1.5rem;
}

.works-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 40px;
    padding: 0 10px; /* ✅ 슬쩍 여백 보완 */

}

.work-card {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.work-card img {
    width: 100%;
    height: 40vw;             /* ✅ 반응형 비율 기반 높이 */
    max-height: 300px;        /* ✅ PC에서는 240px 이하 유지 */
    object-fit: cover;
    border-radius: 8px;
    transition: transform 0.3s ease;
}

.work-card img:hover {
    transform: scale(1.03);
}

.work-info {
    font-size: 0.85rem;
    color: #444;
    line-height: 1.6;          /* ✅ 줄 간격 추가 */
    display: flex;
    flex-direction: column;
    gap: 4px;                  /* ✅ 항목 간 간격 */
    margin-top: 8px;           /* ✅ 이미지와 텍스트 사이 간격 */
}

.work-title {
    font-weight: bold;
    margin-bottom: 2px;
    font-size: 0.95rem;        /* ✅ 약간 크게 */
    color: #000;
}

.inquire-button {
    border: 1px solid #888;
    background: none;
    padding: 4px 12px;
    border-radius: 16px;
    font-size: 0.8rem;
    cursor: pointer;
}

.no-works {
    text-align: center;
    padding: 100px 20px;
    color: #999;
    font-size: 1.1rem;
}


@media (max-width: 1033px) {
    .works-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 20px;
    }
}


@media (max-width: 768px) {
    .works-grid {
        grid-template-columns: repeat(1, 1fr);
        gap: 20px;
    }
}



.popup-overlay {
    display: none;
    position: fixed;
    z-index: 9999;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    background: rgba(0, 0, 0, 0.85);
    justify-content: center;
    align-items: center;
    padding: 0;
    overflow: auto;
}

.popup-overlay.active {
    display: flex;
}

.popup-content {
    position: relative;
    background: #fff;
    padding: 20px;
    border-radius: 8px;
    text-align: center;
    box-sizing: border-box;
}

.popup-content img {
    width: auto;
    max-width: 100%;
    max-height: 80vh;
    height: auto;
    object-fit: contain;
    display: block;
    margin: 0 auto;
}

.popup-caption {
    margin-top: 10px;
    font-size: 0.95rem;
    color: #444;
    line-height: 1.5;
    white-space: pre-line;

}

.popup-close {
    position: absolute;
    top: 10px;
    right: 10px;
    width: 36px;
    height: 36px;
    font-size: 24px;
    background: #fff;
    border: none;
    border-radius: 50%;
    box-shadow: 0 2px 6px rgba(0, 0, 0, 0.2);
    z-index: 10;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
}
