/* 기본 레이아웃 */
.container {
    width: 100%;
    /*max-width: 1200px;*/
    margin: 0 auto;
    padding: 20px;
}

.main__con_title {
    font-size: 24px;
    font-weight: bold;
    margin-bottom: 20px;
    color: #333;
}

.sub__con_title {
    font-size: 16px;
    margin-bottom: 20px;
    color: #333;
}

/* 검색 박스 */
#hpf_search_box {
    background-color: #f5f5f5;
    border-radius: 5px;
    padding: 15px;
    margin-bottom: 20px;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

#hpf_sb_table {
    border: none;
    width: auto;
}

#hpf_sb_table th {
    font-weight: bold;
}

#hpf_sb_table select {
    padding: 8px;
    border: 1px solid #ddd;
    border-radius: 4px;
    min-width: 150px;
}

#hpf_sbd_reset {
    background-color: #48A2E3;
    color: white;
    border: none;
    border-radius: 4px;
    padding: 8px 15px;
    cursor: pointer;
    display: flex;
    align-items: center;
}

.hpf_sbd_class_svg {
    width: 16px;
    height: 16px;
    fill: white;
}

/* 중간 컨테이너 */
#hpf_middle_container {
    display: flex;
    gap: 20px;
    margin-bottom: 30px;
}

.hpf_class_contents_box {
    background: #fff;
    border: 1px solid #ddd;
    border-radius: 5px;
    padding: 15px;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.05);
}

#hpfmc_div_1 {
    flex: 3;
}

#hpfmc_div_2 {
    flex: 2;
}

/* 제목 스타일 */
.hpf_class_contests_title {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 15px;
    padding-bottom: 10px;
    border-bottom: 1px solid #eee;
}

.hpf_class_ct_text {
    font-size: 18px;
    font-weight: bold;
    color: #333;
    display: flex;
    align-items: center;
}

.hpf_class_info_btn {
    width: 20px;
    height: 20px;
    border-radius: 50%;
    background: #48A2E3;
    color: white;
    border: none;
    margin-left: 10px;
    cursor: pointer;
    position: relative;
}

.hpf_class_info_btn::after {
    content: "?";
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
}

.hide {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    border: 0;
}

/* 날짜 선택 버튼 */
#hpfmc_d1_navi {
    display: flex;
    margin-bottom: 15px;
}

.hpf_date_select {
    flex: 1;
    padding: 8px;
    border: 1px solid #ddd;
    background: #f9f9f9;
    cursor: pointer;
    text-align: center;
    transition: all 0.3s;
}

.hpf_date_select:hover {
    background: #eee;
}

.hpf_date_select.active {
    background: #48A2E3;
    color: white;
    border-color: #48A2E3;
}

/* 지도 영역 */
#hpfmc_d1_map {
    width: 100%;
    height: 480px;
    margin-bottom: 15px;
    position: relative;
    overflow: hidden;
}

/* 팝업 스타일 */
#hpfmc_d1_popup {
    position: absolute;
    display: none;
    background: white;
    padding: 8px 12px;
    border-radius: 4px;
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.2);
    z-index: 1000;
    white-space: nowrap; /* 내용이 줄바꿈되지 않도록 설정 */
    font-size: 14px;
    max-width: 200px; /* 최대 너비 설정 */
}

#hpfmc_d1p_content {
    list-style: none;
    padding: 0;
    margin: 0;
    display: inline-block; /* 인라인 블록으로 변경 */
}

#hpfmc_d1p_content li {
    padding: 3px 0;
}

#hpfmc_d1p_content li:first-child {
    font-weight: bold;
}

/* 범례 */
#hpfmc_d1_legend {
    display: flex;
    list-style: none;
    padding: 0;
    margin: 0;
    justify-content: center;
}

#hpfmc_d1_legend li {
    padding: 6px 15px;
    margin: 0 5px;
    color: white;
    border-radius: 4px;
    font-size: 14px;
    font-weight: bold;
    cursor: pointer;
}

/* 온열질환자 레벨에 따른 색상 */
.hpf_level_0 {
    background-color: #0000ff !important;
    color: white !important;
}

.hpf_level_1 {
    background-color: #ffff00 !important;
    color: #333 !important;
}

.hpf_level_2 {
    background-color: #ffad00 !important;
    color: white !important;
}

.hpf_level_3 {
    background-color: #ff0000 !important;
    color: white !important;
}

#hpf_reative_box_2 {
  height: 100%;
}

/* 요약 정보 테이블 */
#hpf_summary_tbl {
    width: 100%;
    height: 90%;
    border-collapse: collapse;
    table-layout: fixed; /* 컬럼 폭 고정 */
}

#hpf_summary_tbl th,
#hpf_summary_tbl td {
    border: 1px solid #ddd;
    padding: 8px;
    text-align: center;
    vertical-align: middle; /* 세로 중앙 정렬 */
}

#hpf_summary_tbl th {
    background-color: #f5f5f5;
    font-weight: bold;
}

/* 하단 컨테이너 */
#hpf_bottom_container {
    margin-bottom: 30px;
}

#hpfbc_chart {
    width: 100%;
    height: 400px;
    margin-top: 15px;
}

#hpf_korea_tbl {
    width: 100%;
    border-collapse: collapse;
    margin-top: 15px;
    font-size: 14px;
}

#hpf_korea_tbl th,
#hpf_korea_tbl td {
    border: 1px solid #ddd;
    padding: 8px;
    text-align: center;
}

#hpf_korea_tbl th {
    background-color: #f5f5f5;
    font-weight: bold;
}

/* 첫 번째 열 너비 설정 */
#hpf_summary_tbl th:first-child {
    width: 20%;
}

/* 나머지 열 너비 균등 분배 */
#hpf_summary_tbl th:not(:first-child) {
    width: 20%;
}

/* 반응형 대응 */
@media (max-width: 768px) {
    #hpf_summary_tbl {
        font-size: 14px;
    }

    #hpf_summary_tbl th,
    #hpf_summary_tbl td {
        padding: 6px 4px;
    }
}

/* 테이블 내 날짜 강조 스타일 */
#hpf_summary_tbl em {
    font-style: normal;
    font-weight: bold;
}

/* 필요시 테이블 내용 줄바꿈 방지 */
#hpf_summary_tbl .nowrap {
    white-space: nowrap;
}

/* 도움말 팝업 스타일 */
#_back_wall {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.5);
    z-index: 9999;
    display: none;
}

#_bw_help_box {
    position: absolute;
    transform: translate(-50%, -50%);
    background-color: white;
    border-radius: 5px;
    box-shadow: 0 3px 10px rgba(0, 0, 0, 0.3);
    width: 80%;
    max-width: 800px;
    max-height: 80vh;
    overflow: auto;
}

#_bw_contents {
    padding: 20px;
}

#_bw_hb_btn_close {
    position: absolute;
    right: 15px;
    top: 15px;
    background: none;
    border: none;
    font-size: 20px;
    cursor: pointer;
    color: #666;
}

._bw_hb_class_contents {
    list-style: none;
    padding: 0;
    margin: 0 0 20px 0;
}

._bw_hb_class_title {
    font-size: 20px;
    font-weight: bold;
    margin-bottom: 15px;
    color: #333;
    border-bottom: 1px solid #eee;
    padding-bottom: 10px;
}

.hpf_info_tbl {
    width: 100%;
    border-collapse: collapse;
    margin: 15px 0;
}

.hpf_info_tbl th,
.hpf_info_tbl td {
    border: 1px solid #ddd;
    padding: 10px;
}

.hpf_info_tbl th {
    background-color: #f5f5f5;
    font-weight: bold;
    text-align: center;
}

.hpf_date_level {
    text-align: center;
    font-weight: bold;
}

/* 로딩 애니메이션 */
#_main_loading_section {
    position: absolute;
    transform: translate(-50%, -50%);
    z-index: 10000;
}

._ml_class_loader {
    font-size: 10px;
    margin: 50px auto;
    text-indent: -9999em;
    width: 80px;
    height: 80px;
    border-radius: 50%;
    background: #48A2E3;
    background: -moz-linear-gradient(left, #48A2E3 10%, rgba(72, 162, 227, 0) 42%);
    background: -webkit-linear-gradient(left, #48A2E3 10%, rgba(72, 162, 227, 0) 42%);
    background: -o-linear-gradient(left, #48A2E3 10%, rgba(72, 162, 227, 0) 42%);
    background: -ms-linear-gradient(left, #48A2E3 10%, rgba(72, 162, 227, 0) 42%);
    background: linear-gradient(to right, #48A2E3 10%, rgba(72, 162, 227, 0) 42%);
    position: relative;
    -webkit-animation: load3 1.4s infinite linear;
    animation: load3 1.4s infinite linear;
    -webkit-transform: translateZ(0);
    -ms-transform: translateZ(0);
    transform: translateZ(0);
}

._ml_class_loader:before {
    width: 50%;
    height: 50%;
    background: #48A2E3;
    border-radius: 100% 0 0 0;
    position: absolute;
    top: 0;
    left: 0;
    content: '';
}

._ml_class_loader:after {
    background: white;
    width: 75%;
    height: 75%;
    border-radius: 50%;
    content: '';
    margin: auto;
    position: absolute;
    top: 0;
    left: 0;
    bottom: 0;
    right: 0;
}

@-webkit-keyframes load3 {
    0% {
        -webkit-transform: rotate(0deg);
        transform: rotate(0deg);
    }
    100% {
        -webkit-transform: rotate(360deg);
        transform: rotate(360deg);
    }
}

@keyframes load3 {
    0% {
        -webkit-transform: rotate(0deg);
        transform: rotate(0deg);
    }
    100% {
        -webkit-transform: rotate(360deg);
        transform: rotate(360deg);
    }
}

/* 반응형 스타일 */
@media (max-width: 768px) {
    #hpf_middle_container {
        flex-direction: column;
    }

    #hpfmc_div_1, #hpfmc_div_2 {
        flex: none;
        width: 100%;
    }

    #hpfmc_d1_map {
        height: 300px;
    }

    #hpf_korea_tbl {
        font-size: 12px;
    }

    #hpf_korea_tbl th,
    #hpf_korea_tbl td {
        padding: 4px;
    }

    .hpf_date_select {
        font-size: 14px;
        padding: 6px 4px;
    }
}

/* 테이블을 감싸는 래퍼에 가로 스크롤 허용 */
.hpf_korea_tbl_wrapper {
    overflow-x: auto; /* or scroll */
    max-width: 100%; /* 부모 폭 이상 넘어가면 스크롤 */
}

/* 테이블 자체는 100% or 필요한 만큼만 */
#hpf_korea_tbl {
    width: 100%;
    border-collapse: collapse;
}

/* 셀렉트 박스 화살표 스타일 */
#hpf_sido_select {
  /* 기본 스타일 */
  padding: 8px 30px 8px 10px; /* 오른쪽 여백 확보 */
  border: 1px solid #ddd;
  border-radius: 4px;
  min-width: 150px;
  background-color: white;

  /* 기본 화살표 제거 */
  -webkit-appearance: none;
  -moz-appearance: none;
  appearance: none;

  /* 커스텀 화살표 추가 */
  background-image: url("data:image/svg+xml;charset=UTF-8,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23464646' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3e%3cpolyline points='6 9 12 15 18 9'%3e%3c/polyline%3e%3c/svg%3e");
  background-repeat: no-repeat;
  background-position: right 8px center;
  background-size: 16px;

  /* 커서 스타일 */
  cursor: pointer;

  /* 텍스트 오버플로우 처리 */
  text-overflow: ellipsis;
  white-space: nowrap;
  overflow: hidden;
}

/* 포커스 시 스타일 */
#hpf_sido_select:focus {
  outline: none;
  border-color: #48A2E3;
  box-shadow: 0 0 0 2px rgba(72, 162, 227, 0.2);
}

/* IE에서 기본 화살표 제거 */
#hpf_sido_select::-ms-expand {
  display: none;
}

/* 호버 효과 */
#hpf_sido_select:hover {
  border-color: #b3b3b3;
}

/* Firefox에서 내부 점선 테두리 제거 */
#hpf_sido_select:-moz-focusring {
  color: transparent;
  text-shadow: 0 0 0 #000;
}