@charset "utf-8";

/* 기본 박스 모델 */
.nsw { width: 100%; display: block; margin-bottom: 20px; }

.nsw__section {
    border: 1px solid var(--bs-border-color);
    border-radius: 12px;
    overflow: hidden;
    background: var(--bs-body-bg);
}

/* position: relative;  추가 */
.nsw__head {
    position: relative; /* 중요: 자식 요소(:after)의 절대 위치 기준점 설정 */
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 10px 15px;
    background-color: var(--bs-tertiary-bg);
    border-bottom: 1px solid var(--bs-border-color); /* cite: 3 */
}

/*️ 이 부분을 CSS 파일 내용 제일 아래에 추가하세요 */
.nsw__head:after {
    content: "";
    position: absolute;
    top: 0;
    left: 0;
    width: 33%;
    height: 3px;
    background-color: rgba(var(--bs-primary-rgb), 1);
    z-index: 10;
}
.nsw__title { font-weight: 800; font-size: 15px; }

/* 🌟 핵심: 공간이 부족하면 자동으로 아래로 내려가도록 설정 */
.nsw__body {
    display: flex;
    flex-wrap: wrap; /* 폭 좁아지면 줄바꿈 */
    gap: 20px;
    padding: 15px;
}

/* 좌/우 영역 비율 조절 */
.nsw__left, .nsw__right {
    flex: 1 1 300px; /* 최소 300px 확보 시도, 안되면 아래로 */
    min-width: 0;
}

/* 웹진 리스트 스타일 */
.nsw__left { display: flex; flex-direction: column; gap: 15px; }

.nsw__webzine {
    display: flex;
    align-items: flex-start;
    gap: 12px;
    text-decoration: none;
}

.nsw__wthumb {
    flex: 0 0 130px; /* 썸네일 고정 크기 */
    width: 130px;
    aspect-ratio: 16 / 10;
    border-radius: 8px;
    overflow: hidden;
    border: 1px solid var(--bs-border-color);
    background: var(--bs-secondary-bg);
}

.nsw__wthumb img { width: 100%; height: 100%; object-fit: cover; display: block; }

.nsw__wmeta { flex: 1; min-width: 0; }

/* 기존 코드 (약 57번째 줄) */
.nsw__wtitle {
    font-weight: 700;
    font-size: 14px;
    line-height: 1.4;
    color: var(--bs-body-color);
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

/* ⬇️ [여기에 아래 코드를 추가하세요] ⬇️ */
.nsw__wdesc {
    font-size: 13px;
    line-height: 1.4;
    color: var(--bs-secondary-color);
    display: -webkit-box;
    -webkit-line-clamp: 2; /* 내용은 2줄까지만 표시 */
    -webkit-box-orient: vertical;
    overflow: hidden;
}
/* ⬆️ [추가 끝] ⬆️ */

.nsw__wsub {
    margin-top: 5px;
    font-size: 12px;
    color: var(--bs-secondary-color);
    display: flex;
    gap: 5px;
}

/* 제목 리스트 스타일 */
.nsw__right { display: flex; flex-direction: column; gap: 8px; }

.nsw__item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 10px;
    padding: 5px 0;
    text-decoration: none;
    border-bottom: 1px solid var(--bs-border-color);
}

.nsw__item:last-child { border-bottom: none; }

.nsw__ititle {
    flex: 1;
    min-width: 0;
    font-size: 14px;
    color: var(--bs-body-color);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.nsw__isrc { font-size: 12px; color: var(--bs-secondary-color); white-space: nowrap; }

.nsw__empty { padding: 20px; text-align: center; font-size: 13px; }

/* 📱 모바일 (폭 575px 이하) */
@media (max-width: 575px) {
    .nsw__webzine { flex-direction: column; }
    .nsw__wthumb { width: 100%; flex: 0 0 auto; aspect-ratio: 16 / 9; }
}

