@charset "UTF-8";

/* 루트 변수 */
:root { 
  --main_color: #e63946; 
  --border_color: #e5e5e5; 
  --bg_light: #fafafa; 
  --bg_header: #fff1f4;
  --text_primary: #222; 
  --text_secondary: #666;
  --text_light: #888; 
}

/* hidden 클래스 정의 */
.noncov-tab-modal.hidden { display: none !important; }

/* ===== 모달 전체 컨테이너 ===== */
.noncov-tab-modal { position: fixed !important; inset: 0 !important; z-index: 999998 !important; display: flex !important; align-items: center !important; justify-content: center !important; pointer-events: none !important; }

/* ===== 딤 배경 ===== */
.noncov-tab-modal-dim { position: fixed !important; inset: 0 !important; background: rgba(0, 0, 0, 0.55); cursor: pointer; z-index: 999997 !important; pointer-events: auto !important; }

/* ===== 모달 래퍼 (Flex 레이아웃) ===== */
.noncov-tab-modal-wrap { position: relative !important; background: #fff; width: min(920px, 92vw) !important; height: 75vh !important; max-height: 75vh !important; border-radius: 12px; box-shadow: 0 12px 40px rgba(0, 0, 0, 0.35); display: flex !important; flex-direction: column !important; z-index: 999999 !important; overflow: hidden !important; pointer-events: auto !important; }

/* ===== 헤더 ===== */
.noncov-tab-modal-header { display: flex; align-items: center; justify-content: space-between; padding: 18px 24px; border-bottom: 1px solid #eee; flex-shrink: 0; flex-basis: auto; }
.noncov-tab-modal-header h3 { font-size: clamp(16px, 1.6vw, 20px); font-weight: 700; color: var(--text_primary); margin: 0; }
.noncov-tab-modal-close { background: none; border: none; font-size: 22px; color: var(--text_light); cursor: pointer; padding: 4px 6px; transition: color 0.2s ease; }
.noncov-tab-modal-close:hover { color: var(--main_color); }

/* ===== 법적 근거 섹션 ===== */
.noncov-legal-notice { padding: 12px 24px; background: #f9f9f9; border-bottom: 1px solid #eee; flex-shrink: 0; flex-basis: auto; }
.noncov-legal-notice p { margin: 4px 0; font-size: 1rem; color: var(--text_secondary); line-height: 1.4; }
.noncov-legal-title { font-weight: 600; color: var(--text_primary); }

/* ===== 탭 메뉴 ===== */
.noncov-tab-menu { display: flex; gap: 0; border-bottom: 2px solid #f0f0f0; background: var(--bg_light); flex-shrink: 0; flex-basis: auto; overflow-x: auto; overflow-y: hidden; }
.noncov-tab-menu::-webkit-scrollbar { height: 4px; }
.noncov-tab-menu::-webkit-scrollbar-track { background: #eee; }
.noncov-tab-menu::-webkit-scrollbar-thumb { background: #ccc; border-radius: 2px; }

/* ===== 탭 버튼 ===== */
.noncov-tab-btn { flex: 1; min-width: 140px; padding: 14px 20px; background: var(--bg_light); border: none; color: var(--text_secondary); font-size: 1rem; font-weight: 600; cursor: pointer; transition: all 0.3s ease; position: relative; white-space: nowrap; }
.noncov-tab-btn:hover { background: #f5f5f5; color: var(--main_color); }
.noncov-tab-btn.active { color: var(--main_color); background: #fff; border-bottom: 2px solid var(--main_color);}
.noncov-tab-btn.active::after { content: ''; position: absolute; bottom: -2px; left: 0; right: 0; height: 2px; background: var(--main_color); }

/* ===== 스크롤 콘텐츠 영역 (마우스 스크롤 핵심!) ===== */
.noncov-tab-body { flex: 1 1 auto !important; min-height: 1px !important; overflow-y: scroll !important; overflow-x: hidden !important; padding: 20px 24px; -webkit-overflow-scrolling: touch; box-sizing: border-box !important; pointer-events: auto !important; display: block !important; position: relative !important; height: auto !important; }

/* 스크롤바 스타일 (Chrome/Safari) */
.noncov-tab-body::-webkit-scrollbar { width: 12px; }
.noncov-tab-body::-webkit-scrollbar-track { background: #f0f0f0; border-radius: 6px; }
.noncov-tab-body::-webkit-scrollbar-thumb { background: #999; border-radius: 6px; border: 3px solid #f0f0f0; }
.noncov-tab-body::-webkit-scrollbar-thumb:hover { background: #666; }

/* 스크롤바 스타일 (Firefox) */
.noncov-tab-body { scrollbar-color: #999 #f0f0f0; scrollbar-width: thin; }

/* ===== 모달 노트 ===== */
.noncov-modal-note { font-size: clamp(11px, 0.9vw, 13px); color: var(--text_light); margin: 0 0 14px; }

/* ===== 탭 패널 ===== */
.noncov-tab-panel { display: none; }
.noncov-tab-panel.active { display: block; animation: fadeIn 0.3s ease-in-out; }

@keyframes fadeIn {
  from { opacity: 0; }
  to { opacity: 1; }
}

/* ===== 테이블 ===== */
.noncov-tab-table { width: 100%; border-collapse: collapse; font-size: 1rem; margin-bottom: 10px; pointer-events: auto; }
.noncov-tab-table th, .noncov-tab-table td { padding: 10px 12px; border: 1px solid var(--border_color); text-align: center; line-height: 1.3;}
.noncov-tab-table thead th { background: var(--bg_header); color: var(--text_primary); font-weight: 700; white-space: nowrap; position: sticky; top: -21px; z-index: 10; }
.noncov-tab-table td:nth-child(3){ text-align: left; }
#tab-02 .noncov-tab-table td:nth-child(1){ text-align: left; }
#tab-04 .noncov-tab-table td:nth-child(4){ text-align: center; }
.noncov-tab-table td:last-child { font-weight: 700; color: var(--main_color); white-space: nowrap; }
.noncov-tab-table tbody tr:hover { background: #fffafb; }

/* ===== Body 오버플로우 고정 ===== */
body.noncov-tab-modal-open { overflow: hidden; }

/* ===== 모달 열기 버튼 (기본 스타일) ===== */
.noncov-btn-open { padding: 12px 24px; background: var(--main_color); color: #fff; border: none; border-radius: 6px; font-size: 14px; font-weight: 600; cursor: pointer; transition: background 0.2s ease; }
.noncov-btn-open:hover { background: #c1121f; }

@media screen and (max-width: 600px) {
  .noncov-tab-modal-wrap { width: 94vw; height: 88vh; max-height: 88vh; }
  .noncov-tab-modal-header { padding: 14px 16px; }
  .noncov-legal-notice { padding: 10px 16px; }
  .noncov-legal-notice p { font-size: 10px; }
  .noncov-tab-body { padding: 14px 16px; }
  .noncov-tab-btn { min-width: 80px; padding: 12px 10px; font-size: 12px; box-sizing: border-box;}

  /* 모바일: 테이블 → 카드 레이아웃 */
  .noncov-tab-table {font-size: 12px;}
  .noncov-tab-table thead { position: absolute; width: 1px; height: 1px; clip: rect(0 0 0 0); }
  .noncov-tab-table, .noncov-tab-table tbody, .noncov-tab-table tr, .noncov-tab-table td { display: block; width: 100%; }
  .noncov-tab-table tr { border: 1px solid var(--border_color); border-radius: 8px; margin-bottom: 10px; }
  .noncov-tab-table td { position: relative; box-sizing: border-box; width: 100%; min-height: 36px; padding: 8px 12px 8px 42%; text-align: right; word-break: break-word; border: none; border-bottom: 1px solid #f0f0f0; }
  .noncov-tab-table td:last-child { border-bottom: none; }
  .noncov-tab-table td::before { content: attr(data-th); position: absolute; left: 12px; top: 8px; width: calc(42% - 20px); font-weight: 600; color: var(--text_light); text-align: left; }
  .noncov-tab-table td:nth-child(3) { text-align: right; }
  #tab-02 .noncov-tab-table td:nth-child(1) { text-align: right; }
}

@media screen and (max-width: 320px) {
      .noncov-tab-btn {min-width: 70px; padding: 12px 5px;}
}
