/* ==========================================
   1. 상단 카드 컴포넌트 튜닝 (시안 상단 매칭)
   ========================================== */
.detail-main-bg {
    background-color: #ffffff !important; /* 시안처럼 깨끗한 화이트 서페이스 베이스화 */
}

.novel-info-header-card {
    background-color: #ffffff;
    padding: 30px 10px;
    display: flex;
    gap: 35px;
    margin-bottom: 20px;
    border-bottom: 1px solid var(--border-soft);
}

/* 표지 이미지 비율 정밀화 */
.novel-detail-cover {
    position: relative;
    width: 250px;
    height: 350px;
    border-radius: 8px;
    overflow: hidden;
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.12);
    flex-shrink: 0;
}
.real-cover-img {
    object-fit: contain;
    min-width: 100%;
    height: 100%;
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
}

.novel-detail-meta-wrap {
    flex: 1;
    display: flex;
    flex-direction: column;
    padding-top: 10px;
}

.detail-novel-title {
    font-size: 2rem;
    font-weight: 800;
    color: #1A202C;
    margin-bottom: 6px;
}

.detail-novel-author {
    font-size: 0.95rem;
    color: var(--text-muted);
    font-weight: 600;
    margin-bottom: 15px;
}

/* 평점, 조회수 행 스펙 */
.novel-stats-row {
    display: flex;
    align-items: center;
    gap: 6px;
    font-size: 0.92rem;
    color: #4A5568;
    margin-bottom: 15px;
    font-weight: bold;
}
.stat-star i { color: #FF4D4D; margin-right: 2px; } /* 시안의 붉은 하트/별점 계열 반영 */
.stat-count { color: #A0AEC0; font-weight: normal; }
.stat-status-text { color: #3182CE; }
.stat-divider { color: #E2E8F0; }

/* 장르 태그 배지 */
.novel-genre-tags-wrap {
    display: flex;
    gap: 8px;
    margin-bottom: 25px;
}
.novel-genre-tags-wrap .g-tag {
    font-size: 0.82rem;
    background-color: #EDF2F7;
    color: #4A5568;
    padding: 4px 12px;
    border-radius: 6px;
    font-weight: 600;
}
.no-tag {
    font-size: 13px;
    color : #333;
}
.ep-main-info {
    flex : 1;
}

.detail-synopsis-box {
    font-size: 0.98rem;
    color: #4A5568;
    line-height: 1.6;
    margin-bottom: 30px;
    max-width: 750px;
}
.detail-synopsis-box p {
    font-size: 13.5px;
}

/* ==========================================
   2. 시안의 대형 액션 버튼 시스템 (버튼 색상/구조 완벽 싱크)
   ========================================== */
.detail-action-buttons {
    display: flex;
    gap: 15px;
    margin-top: auto;
}

/* 대형 네이비 이어보기 버튼 */
.btn-action.btn-continue-read {
    background-color: #1A2E5A; /* 시안 특유의 깊은 다크 네이비 청량 버튼 */
    color: #ffffff;
    flex: 1;
    max-width: 320px;
    height: 60px;
    padding: 0 25px;
    border-radius: 8px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    text-align: left;
    box-shadow: 0 4px 12px rgba(26, 46, 90, 0.2);
}
.btn-action.btn-continue-read:hover { background-color: #112042; }

.continue-text { display: flex; flex-direction: column; }
.continue-text .main-act { font-size: 1.05rem; font-weight: 800; letter-spacing: 0.5px; }
.continue-text .sub-act { font-size: 0.78rem; opacity: 0.7; font-weight: normal; margin-top: 1px; }
.arrow-icon { font-size: 1.1rem; }

/* 테두리형 찜하기 버튼 */
.btn-action.btn-wish-list {
    background-color: #ffffff;
    color: #4A5568;
    border: 1px solid #CBD5E0;
    height: 60px;
    padding: 0 25px;
    border-radius: 8px;
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 1rem;
    font-weight: bold;
}
.btn-action.btn-wish-list:hover { background-color: #F7FAFC; }
.btn-wish-list i { font-size: 1.15rem; color: #718096; }
.wish-count { color: #A0AEC0; font-weight: normal; margin-left: 2px; }

/* ==========================================
   3. 중간 탭 메뉴 바 컴포넌트
   ========================================== */
.novel-detail-tab-bar {
    display: flex;
    gap: 40px;
    border-bottom: 2px solid #E2E8F0;
    margin-bottom: 30px;
    padding-left: 5px;
}
.tab-item {
    background: none;
    border: none;
    padding: 12px 0;
    font-size: 1rem;
    font-weight: bold;
    color: #718096;
    cursor: pointer;
    position: relative;
}
.tab-item.active {
    color: #1A202C;
}
/* 활성화 탭 하단 블랙 라인 인디케이터 */
.tab-item.active::after {
    content: '';
    position: absolute;
    bottom: -2px;
    left: 0;
    width: 100%;
    height: 3px;
    background-color: #1A202C;
}
.tab-count { font-size: 0.85rem; font-weight: normal; opacity: 0.8; }

/* ==========================================
   4. 하단 콘텐츠 세션 레이아웃
   ========================================== */
.detail-content-grid {
    display: grid;
    grid-template-columns: 1fr 280px;
    gap: 35px;
}

.detail-chapter-list-area {
    background-color: #ffffff;
}
.chapter-list-top-meta {
    display: flex;
    justify-content: flex-end;
    margin-bottom: 15px;
}
.sort-btn {
    background: none;
    border: none;
    font-size: 0.85rem;
    color: #A0AEC0;
    font-weight: bold;
    cursor: pointer;
}
.sort-btn.active { color: #4A5568; }

/* 회차 목록 행 디자인 튜닝 */
.episode-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 20px 10px;
    border-bottom: 1px solid #F0F4F8;
}
.ep-title-link {
    font-size: 1.02rem;
    font-weight: 700;
    color: #2D3748;
    margin-bottom: 6px;
}
.ep-title-link:hover { color: var(--abydos-blue); }
.ep-title-link > span {
    font-size: 12px;
    color: #888;
}

.ep-meta-line {
    display: flex;
    gap: 15px;
    font-size: 0.85rem;
    color: #A0AEC0;
}
.ep-views i { margin-right: 2px; }


/* ==========================================
   5. 우측 사이드바 및 아카이브 스펙 그룹 (정밀 배치)
   ========================================== */
.detail-spec-sidebar {
    display: flex;
    flex-direction: column;
    gap: 25px;
}

.spec-card-box {
    background-color: #ffffff;
    border: 1px solid var(--border-soft);
    border-radius: 8px;
    padding: 22px;
}
.spec-card-box h4 {
    font-size: 0.95rem;
    font-weight: 800;
    color: #1A202C;
    margin-bottom: 18px;
}

/* 🌟 [새로 코딩된] 작품 관련 정보 리스트 메뉴 UI */
.relation-menu-list {
    list-style: none;
    display: flex;
    flex-direction: column;
    gap: 2px;
}
.relation-menu-list li a {
    display: flex;
    align-items: center;
    padding: 12px 10px;
    font-size: 0.9rem;
    font-weight: bold;
    color: #4A5568;
    border-radius: 6px;
    transition: background-color 0.2s;
}
.relation-menu-list li a i:first-child {
    margin-right: 10px;
    font-size: 1.05rem;
    color: #718096;
}
.relation-menu-list li a:hover {
    background-color: #F7FAFC;
    color: var(--abydos-blue);
}
.relation-menu-list li a:hover i:first-child { color: var(--abydos-blue); }
.arrow-r { margin-left: auto; font-size: 0.8rem; color: #CBD5E0; }


.relation-menu-list li.active a {
    background-color: #F7FAFC;
    color: var(--abydos-blue);
}
.relation-menu-list li.active a i:first-child { color: var(--abydos-blue); }

/* 기존 서지정보 상세 */
.spec-data-list {
    list-style: none;
    display: flex;
    flex-direction: column;
    gap: 12px;
}
.spec-data-list li {
    display: flex;
    justify-content: space-between;
    font-size: 0.85rem;
    padding-bottom: 6px;
    border-bottom: 1px dashed #EDF2F7;
}
.spec-label { color: #718096; }
.spec-value { font-weight: bold; color: #2D3748; }
.code-text { font-family: 'Courier New', monospace; font-size: 0.8rem; color: #2B6CB0; }

/* 이 작품의 태그 클라우드 */
.sidebar-tags-grid {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}
.sidebar-tags-grid span {
    font-size: 0.78rem;
    background-color: #EDF2F7;
    color: #4A5568;
    padding: 4px 10px;
    border-radius: 6px;
    font-weight: 600;
}

/* ==========================================
   6. 반응형 대응 규격
   ========================================== */
@media (max-width: 1024px) {
    .detail-content-grid { grid-template-columns: 1fr; }
}
@media (max-width: 768px) {
    .novel-info-header-card { flex-direction: column; align-items: center; text-align: center; }
    .detail-action-buttons { flex-direction: column; width: 100%; align-items: center; }
    .btn-action.btn-continue-read, .btn-action.btn-wish-list { max-width: 100%; width: 100%; justify-content: center; }
    .continue-text { text-align: center; }
    .arrow-icon { display: none; }
    .novel-detail-tab-bar { gap: 20px; justify-content: center; }
}
