@charset "UTF-8";

/* 헤더와 관리자 바로가기의 공통 높이 --hd-h는 common.css에서 관리한다. */

#bo_v > header {
  display: none;
}

#content_wrap {
  padding-bottom: 3%;
}

#bo_v_title .bo_v_tit {
  display: block;
  font-size: 17px;
  margin: 5px 0 0;
  word-break: break-all;
  font-weight: 500;
  letter-spacing: -1px;
  font-family: "pretendard Variable" !important;
}

.board_title {
  font-family: "pretendard Variable";
}

#bo_v > header {
  display: block;
  position: relative;
  background: transparent;
  font-size: unset;
  padding: unset;
  border-bottom: 1px solid black;
  font-family: "pretendard Variable";
}

#content_wrap {
  padding-bottom: 0% !important;
}

/* 레거시 admin 드롭다운(ul.admin_head) 전용 스타일 삭제 —
   마크업이 프로젝트 어디에도 없고(0건), element 셀렉터라 신규 nav.header_menu > ul > li > a
   를 덮어써 메뉴에 빨간 3px 테두리·uppercase·float 이 걸리고 있었다. */

/* ★ 엘리먼트 셀렉터(header{})를 쓰지 않는다 — 본문에서 시맨틱하게 쓴 <header> 까지 잡힌다.
   섹션 안에 <header> 를 하나 넣었을 뿐인데 스크롤 시 position:fixed·top:-5vw 가 걸려
   요소가 화면 밖으로 날아가는 사고가 여기서 났다. 사이트 헤더는 항상 .header 로만 잡는다.
   (js/header.js 의 $(".header") 와 짝이다 — 한쪽만 바꾸면 drop/insert 가 안 걸린다) */
.header.drop {
  position: fixed;
}

.header.insert {
  position: fixed;
  top: calc(var(--px) * -147);
}

/* ═══════════════════════ HEADER (기본 형태) ═══════════════════════
   구조: header.header > a.header_logo + nav.header_menu > ul > li > a + .hamburger
   프로젝트마다 바꾸는 값 = 로고/메뉴 이미지 자연사이즈(width·aspect-ratio),
   메뉴 사이 간격(gap), 좌우 배치 여백(margin-left), 헤더 높이.
   ═══════════════════════════════════════════════════════════════ */
.header :where(img) {
  width: 100%;
}

.header_menu_text, .header_dim { display: none; }

.header_frame {
  width: 100%;
  height: var(--hd-h);
  background-color: var(--color-navy);
}

.header {
  position: fixed;
  left: 0;
  top: 0;
  z-index: 9999;
  display: flex;
  justify-content: center;
  align-items: flex-start;
  box-sizing: border-box;
  width: 100%;
  height: var(--hd-h); /* ★ 값은 :root --hd-h 에서 바꾼다 */
  padding-left: calc(var(--px) * 6);
  background: var(--color-navy);
  transition-duration: 0.3s;
  transition-property: top;
}

.header_logo {
  z-index: 2;
  display: flex;
  justify-content: center;
  align-items: center;
  flex-shrink: 0;
  width: calc(var(--px) * 189);
  aspect-ratio: 189 / 147;
}

.header_menu {
  display: flex;
  justify-content: flex-start;
  align-items: flex-start;
  flex-shrink: 0;
  width: 100%;
  box-sizing: border-box;
  padding: calc(var(--px) * 34) calc(var(--px) * 272) calc(var(--px) * 37) calc(var(--px) * 275);
}

.header_menu_list {
  display: flex;
  justify-content: flex-start;
  align-items: flex-start;
  gap: 0;
}

.header_menu_item {
  display: flex;
  justify-content: center;
  align-items: center;
}

.header_menu_1 {
  cursor: pointer;
  display: flex;
  justify-content: center;
  align-items: center;
  width: calc(var(--px) * 81);
  aspect-ratio: 81 / 20;
}

.header_menu_1:hover,
.header_menu_1:focus-visible,
.header_menu_1.remote_on {
  color: var(--color-red);
}

.header_menu_1:hover .header_menu_img,
.header_menu_1:focus-visible .header_menu_img,
.header_menu_1.remote_on .header_menu_img {
  filter: url('/images/header-menu-filter.svg#brand-red');
}

.header_menu_item:where(:nth-child(1), :nth-child(2), :nth-child(8)) {
  margin-top: 1px;
}

.header_menu_item:where(:nth-child(2)) { margin-left: calc(var(--px) * 62); }
.header_menu_item:where(:nth-child(3)) { margin-left: calc(var(--px) * 64); }
.header_menu_item:where(:nth-child(4)) { margin-left: calc(var(--px) * 88); }
.header_menu_item:where(:nth-child(5)) { margin-left: calc(var(--px) * 349); }
.header_menu_item:where(:nth-child(6)) { margin-left: calc(var(--px) * 60); }
.header_menu_item:where(:nth-child(7), :nth-child(8)) { margin-left: calc(var(--px) * 61); }

:where(.header_menu_item:nth-child(1)) .header_menu_1 {
  width: calc(var(--px) * 61);
  aspect-ratio: 61 / 19;
}
:where(.header_menu_item:nth-child(3)) .header_menu_1 {
  width: calc(var(--px) * 60);
  aspect-ratio: 60 / 20;
}
:where(.header_menu_item:nth-child(5)) .header_menu_1 {
  width: calc(var(--px) * 80);
  aspect-ratio: 80 / 20;
}
:where(.header_menu_item:nth-child(6)) .header_menu_1 {
  width: calc(var(--px) * 82);
  aspect-ratio: 82 / 21;
}

/* ═══════════════════════ HEADER end ═══════════════════════ */

/* ═══════════════ 게시판 바로가기 (레벨 10 이상 전용) ═══════════════
   마크업은 theme/design/template/header/index.html — g5_board 를 읽어 자동 생성.
   헤더 바로 아래 우측에 fixed. top 은 헤더 높이(--hd-h) + 여백 24 로 계산해서, 헤더를 키워도
   따라 내려간다(고정값으로 두면 헤더가 커진 프로젝트에서 헤더에 가려진다).
   z-index 는 헤더보다 1 낮게 — 겹치는 상황이 오면 헤더가 이긴다.
   ★ 폰트: Pretendard 는 글로벌 section{} 으로만 카스케이드되는데 이 위젯은 section 밖이라
     상속을 못 받는다 → 여기서 직접 지정한다. */
.hd_boards {
  position: fixed;
  right: calc(var(--px) * 24);
  top: calc(var(--hd-h) + var(--px) * 24);
  z-index: 9998;
  display: flex;
  flex-direction: column;
  justify-content: flex-start;
  align-items: flex-end;
  font-family: "Pretendard Variable", Pretendard, sans-serif;
  letter-spacing: -0.02vw;
}

.hd_boards_btn {
  display: flex;
  justify-content: center;
  align-items: center;
  gap: calc(var(--px) * 8);
  box-sizing: border-box;
  height: calc(var(--px) * 36);
  padding: 0 calc(var(--px) * 15);
  font-family: inherit;
  font-size: calc(var(--px) * 14);
  font-weight: 600;
  color: #ffffff;
  white-space: nowrap;
  background-color: rgba(17, 17, 17, 0.88);
  border: 0;
  border-radius: calc(var(--px) * 18);
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.18);
  cursor: pointer;
  transition: background-color 0.2s ease, box-shadow 0.2s ease, transform 0.2s ease;
}

.hd_boards_btn:hover {
  background-color: #111111;
  box-shadow: 0 4px 16px rgba(0, 0, 0, 0.26);
  transform: translateY(-1px);
}

/* 셰브론 — border 2변을 돌려 만든 ∨ (열리면 ∧ 로 회전) */
.hd_boards_btn::after {
  content: "";
  width: calc(var(--px) * 7);
  height: calc(var(--px) * 7);
  margin-top: calc(var(--px) * -3);
  border-right: 2px solid currentColor;
  border-bottom: 2px solid currentColor;
  transform: rotate(45deg);
  transition: transform 0.25s ease;
}

.hd_boards.is_open .hd_boards_btn::after {
  margin-top: calc(var(--px) * 3);
  transform: rotate(-135deg);
}

/* 닫힘 상태 — display 로 껐다 켜면 transition 이 안 걸리므로 opacity/visibility 로 감춘다.
   ★ 단, 반드시 position:absolute 로 **흐름에서도 빼야 한다.** 시각만 감추면 접힌 상태에서도
     리스트 높이만큼 .hd_boards 박스가 남아(실측 178×238) 그 아래 콘텐츠의 클릭을 먹는다.
     리스트에 pointer-events:none 이 있어도 컨테이너에는 없어서 컨테이너가 받는다.
     부모 .hd_boards 가 position:fixed 라 그게 containing block 이 된다. */
.hd_boards_list {
  position: absolute;
  top: 100%;
  right: 0;
  display: flex;
  flex-direction: column;
  justify-content: flex-start;
  align-items: stretch;
  box-sizing: border-box;
  margin-top: calc(var(--px) * 8);
  min-width: calc(var(--px) * 178);
  padding: calc(var(--px) * 6);
  background-color: #ffffff;
  border: 1px solid #ececf2;
  border-radius: calc(var(--px) * 12);
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.14);
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
  transform: translateY(calc(var(--px) * -8)) scale(0.98);
  transform-origin: top right;
  transition: opacity 0.22s ease, transform 0.22s cubic-bezier(0.22, 1, 0.36, 1), visibility 0.22s;
}

/* 열림 — js/header.js 가 .hd_boards 에 .is_open 토글 */
.hd_boards.is_open .hd_boards_list {
  opacity: 1;
  visibility: visible;
  pointer-events: auto;
  transform: translateY(0) scale(1);
}

.hd_boards_link {
  display: flex;
  justify-content: flex-start;
  align-items: center;
  width: 100%;
  box-sizing: border-box;
  height: calc(var(--px) * 36);
  padding: 0 calc(var(--px) * 12);
  font-size: calc(var(--px) * 14);
  font-weight: 500;
  color: #2b2b33;
  white-space: nowrap;
  border-radius: calc(var(--px) * 8);
  transition: background-color 0.18s ease, color 0.18s ease;
}

.hd_boards_link:hover {
  color: #111111;
  background-color: #f3f4f8;
}

/* 관리자페이지 — 목록 맨 위에 고정. 구분선은 별도 요소 없이 이 링크의 border-bottom 으로 낸다
   (요소를 하나 더 넣으면 flex 항목이 늘어 목록 여백 계산이 흐트러진다) */
.hd_boards_adm {
  font-weight: 700;
  border-bottom: 1px solid #e5e6ec;
  border-radius: calc(var(--px) * 8) calc(var(--px) * 8) 0 0;
}

@media screen and (max-width: 599px) {
  .hd_boards {
    right: 4vw;
    top: calc(var(--hd-h) + 5vw);
  }
  .hd_boards_btn {
    gap: 1.6vw;
    height: 8vw;
    padding: 0 3.4vw;
    font-size: 3.2vw;
    border-radius: 4vw;
  }
  .hd_boards_btn::after {
    width: 1.6vw;
    height: 1.6vw;
    margin-top: -0.7vw;
  }
  .hd_boards.is_open .hd_boards_btn::after {
    margin-top: 0.7vw;
  }
  .hd_boards_list {
    margin-top: 1.8vw;
    min-width: 40vw;
    padding: 1.4vw;
    border-radius: 2.8vw;
  }
  .hd_boards_link {
    height: 8.4vw;
    padding: 0 2.8vw;
    font-size: 3.2vw;
    border-radius: 2vw;
  }
}


/* -------------------header 커스텀 끝------------------- */
@media screen and (max-width: 599px) {
  .pc-mobile { display: none !important; }
  .mobile-pc { display: flex !important; }
  .pc-inline { display: none !important; }
  .header, .header.drop, .header.insert {
    top: 0;
    height: 15vw;
    padding: 0 5vw 0 2vw;
    justify-content: space-between;
    align-items: center;
    background: #fff;
    border-bottom: 1px solid var(--color-navy);
    transition: none;
    animation: none;
  }
  .header_logo {
    position: relative;
    inset: auto;
    transform: none;
    padding: 0;
    margin: 0;
    width: 24vw;
    z-index: 9999;
    align-self: flex-start;
  }
  .hamburger {
    display: flex;
    justify-content: center;
    align-items: center;
    position: relative;
    inset: auto;
    transform: none;
  }
  .hamburger-menu {
    width: 7vw;
    height: 4vw;
    padding: 0;
    border: 0;
    background: none;
    position: relative;
    display: flex;
    justify-content: center;
    align-items: center;
    cursor: pointer;
  }
  .hamburger-menu .line {
    display: block;
    background: var(--color-navy);
    width: 100%;
    height: 2px;
    border-radius: 0;
    transition: transform 0.3s ease, top 0.3s ease, bottom 0.3s ease, opacity 0.2s ease;
    transform-origin: center;
    position: absolute;
    left: 0;
    margin: 0;
  }
  .hamburger-menu .mid-reverse {
    top: 50%;
    transform: translateY(-50%);
    background-color: var(--color-red);
  }
  .top-reverse { top: 0; }
  .bot-reverse { bottom: 0; }
  .line_change.top-reverse { top: 50%; transform: translateY(-50%) rotate(45deg); }
  .line_change.mid-reverse { opacity: 0; }
  .line_change.bot-reverse { bottom: 50%; transform: translateY(50%) rotate(-45deg); }

  /* 기존 내비게이션을 헤더 아래로 펼치며 PC 이미지 메뉴는 그대로 둔다. */
  .header_menu {
    position: fixed;
    top: 15vw;
    left: 0;
    right: 0;
    width: 100%;
    height: auto;
    max-height: 0;
    padding: 0;
    margin: 0;
    visibility: hidden;
    opacity: 0;
    pointer-events: none;
    background: #fff;
    color: var(--color-navy);
    overflow: hidden;
    flex-wrap: nowrap;
    gap: 0;
    flex-direction: column;
    align-items: stretch;
    z-index: 9998;
    border-top: 1px solid #e9e9e9;
    box-shadow: 0 5px 12px rgba(0,0,0,0.1);
    transition: max-height 0.35s ease, opacity 0.25s ease, visibility 0s linear 0.35s;
  }
  .header_menu.header_menu_drop {
    max-height: calc(100dvh - 15vw);
    visibility: visible;
    opacity: 1;
    pointer-events: auto;
    overflow-y: auto;
    overscroll-behavior: contain;
    -webkit-overflow-scrolling: touch;
    transition-delay: 0s;
  }
  .header_menu_list {
    width: 100%;
    flex-direction: column;
    align-items: stretch;
    gap: 0;
    flex-shrink: 0;
  }
  .header_menu_item {
    width: 100%;
    margin: 0;
    border-bottom: 1px solid #e9e9e9;
  }
  .header_menu_1 {
    width: 100%;
    aspect-ratio: auto;
    box-sizing: border-box;
    justify-content: flex-start;
    padding: 4.5vw 6vw;
    font-family: "Pretendard Variable", Pretendard, sans-serif;
    font-size: 4.2vw;
    font-weight: 600;
    line-height: 1.4;
    color: var(--color-navy);
    transition: color 0.25s ease, background-color 0.25s ease;
  }
  .header_menu_1:hover,
  .header_menu_1:focus-visible,
  .header_menu_1.remote_on,
  .header_menu_1:active { color: var(--color-red); }
  .header_menu_img { display: none; }
  .header_menu_text { display: block; }
  .header_dim {
    display: block;
    position: fixed;
    inset: 0;
    z-index: 9997;
    background: rgba(0,0,0,0.45);
    -webkit-backdrop-filter: blur(5px);
    backdrop-filter: blur(5px);
    opacity: 0;
    visibility: hidden;
    pointer-events: none;
    transition: opacity 0.3s ease, visibility 0s linear 0.3s;
  }
  .header_dim.on {
    opacity: 1;
    visibility: visible;
    pointer-events: auto;
    transition-delay: 0s;
  }
}

#bo_v_title .bo_v_tit {
  display: block;
  font-size: 17px;
  margin: 5px 0 0;
  word-break: break-all;
  font-weight: 700;
  letter-spacing: -1px;
  font-family: "pretendard Variable" !important;
}

.board_title {
  font-weight: 700;
  font-family: "pretendard Variable";
}

#bo_w .bo_w_tit .frm_input {
  padding-right: 0px !important;
}

#bo_v > header {
  display: block;
  position: relative;
  background: transparent;
  font-size: unset;
  padding: unset;
  border-bottom: 1px solid black;
  font-family: "pretendard Variable";
  font-weight: 900;
}

#bo_v_con {
  margin: 30px 0 30px;
  width: 100%;
  line-height: 1.7em;
  min-height: 200px;
  word-break: break-all;
  overflow: hidden;
  font-size: 1.3em;
  font-family: "pretendard Variable";
}

@media screen and (max-width: 599px) {
  .main_small_title {
    font-size: 3.1vw;
    line-height: 4.7vw;
  }
}

/* 공통 전화 / TOP 바로가기 */
.floating_controls {
  position: fixed;
  right: calc(var(--px) * 42);
  bottom: calc(var(--quick-offset, 0px) + var(--px) * 24);
  z-index: 1112;
  display: flex;
  flex-direction: row;
  justify-content: flex-end;
  align-items: flex-end;
}

.floating_buttons {
  display: flex;
  flex-direction: column;
  justify-content: flex-start;
  align-items: center;
  gap: calc(13 / 1905 * 100vw);
}

.floating_btn {
  width: calc(var(--px) * 134);
  aspect-ratio: 1 / 1;
  border-radius: 50%;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
}

.phone_btn_image {
  width: 100%;
  height: auto;
}

.top_btn_image {
  width: 100%;
  height: auto;
}

@media screen and (max-width: 599px) {
  /* 모바일은 전화가 하단 퀵바에 있으므로 TOP 버튼만 퀵바 바로 위에 띄운다 */
  .floating_controls {
    right: 3vw;
    bottom: calc(var(--quick-offset, 0px) + 3vw);
  }

  .phone_btn {
    display: none;
  }

  .floating_buttons {
    gap: 2vw;
  }

  .floating_btn {
    width: 13vw;
  }

}
