/* 폰트 ---------------------------------------------------------------------- */
@font-face {
    font-family: 'Noto Sans KR';
    src: url('/static/css/fonts/NotoSansKR-VariableFont_wght.ttf') format('truetype-variations'),
         url('/static/css/fonts/NotoSansKR-VariableFont_wght.ttf') format('truetype');
    font-weight: 100 900;
    font-style: normal;
    font-display: swap;
}

body,
html {
    margin: 0;
    padding: 0;
    touch-action: manipulation;
    -webkit-user-select: none;
    -moz-user-select: none;
    -ms-user-select: none;
    user-select: none;
    width: 100%;
    color: #2a2a2a;
    letter-spacing: -0.28px;
    overflow-x: hidden;
    font-family: 'Noto Sans KR', sans-serif;
}

body {
    overflow: hidden;
}

* {
    box-sizing: border-box;
    word-break: break-all;
    -webkit-tap-highlight-color: transparent;
}

img {
    max-width: 100%;
    pointer-events: none;
    user-select: none;
    vertical-align: bottom;
}

button {
    padding: 0;
    cursor: pointer;
    border: none;
    background-color: transparent;
    color: inherit;
    font-family: 'Noto Sans KR', sans-serif;
}

a {
    color: inherit;
    text-decoration: none;
}

input, select, textarea {
    outline: none;
    font-family: 'Noto Sans KR', sans-serif;
}

.mobile-only {
    display: none !important;
}

.pc-only {
    display: block !important;
}

@media (max-width: 768px) {
    .mobile-only {
        display: block !important;
    }
    .pc-only {
        display: none !important;
    }
}

/* 헤더 ---------------------------------------------------------------------- */
.site-header {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    z-index: 100;
    background-color: #fff;
    box-shadow: 0 0 10px 0 rgba(0, 0, 0, 0.1);

    display: flex;
    flex-direction: column
}

.site-header .header-top {
    width: 100%;
    height: 130px;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10%;
    overflow: hidden;
    transition: height 0.3s ease;
}

/* 스크롤 내리면 상단 바(로고/문의) 접고 gnb만 남김 (최상단에선 펼침) */
@media (min-width: 1171px) {
    body.is-scrolled .site-header .header-top {
        height: 0;
    }

    body.is-scrolled .main-visual {
        margin-top: 45px;
    }
}

.site-header .header-top .header-top__slogan {
    font-size: 16px;
    color: #7d7d7d;
    font-weight: 400;
}

.site-header .header-logo a {
    width: 200px;
    height: 55px;
    background-image: url(/static/images/logo.png);
    background-repeat: no-repeat;
    background-size: contain;
    display: block
}

.site-header .header-contact {
    display: flex;
    flex-direction: column;
}

.site-header .header-contact .header-contact__label {
    display: flex;
    align-items: center;
    justify-content: flex-end;

    font-size: 15px;
    color: #87674f;
    font-weight: 600;
}

.site-header .header-contact .header-contact__label .header-contact__icon {
    width: 14px;
}

.site-header .header-contact .header-contact__tel {
    font-size: 23px;
    font-weight: 600;
}

.site-header .gnb {
    width: 100%;
}

.site-header .gnb__toggle {
    width: 30px;
    height: 22px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    flex-direction: column;
}

.site-header .gnb__toggle-bar {
    width: 100%;
    height: 2px;
    background-color: #2a2a2a;
    transition: transform 0.3s ease, opacity 0.3s ease;
}

/* 열린 상태(aria-expanded="true")에서 X자로 변형 */
.site-header .gnb__toggle[aria-expanded="true"] .gnb__toggle-bar:nth-child(1) {
    transform: translateY(10px) rotate(45deg);
}

.site-header .gnb__toggle[aria-expanded="true"] .gnb__toggle-bar:nth-child(2) {
    opacity: 0;
}

.site-header .gnb__toggle[aria-expanded="true"] .gnb__toggle-bar:nth-child(3) {
    transform: translateY(-10px) rotate(-45deg);
}

.site-header .gnb__menu {
    width: 100%;
    height: 45px;
    border-top: 1px solid #b1b1b1;
}

.site-header .gnb__menu-inner {
    width: 1170px;
    height: 100%;
    margin: 0 auto;
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.site-header .gnb__item {
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;

    font-weight: 600;
}

.site-header .gnb__link {
    position: relative;
    display: block;
    transition: color 0.3s ease;
}

/* 글자 아래 밑줄: 가운데에서부터 글자 너비만큼 퍼지는 효과 */
.site-header .gnb__link::after {
    content: '';
    position: absolute;
    left: 0;
    bottom: -6px;
    width: 100%;
    height: 2px;
    background-color: #000;
    transform: scaleX(0);
    transform-origin: center;
    transition: transform 0.3s ease;
}

.site-header .gnb__item:hover .gnb__link {
    color: #87674f;
}

.site-header .gnb__item:hover .gnb__link::after {
    transform: scaleX(1);
}

/* 퀵메뉴 ---------------------------------------------------------------------- */
.quick-menu {
    position: fixed;
    top: 50%;
    transform: translateY(-50%);
    right: 20px;
    width: 80px;
    z-index: 9;
}

.quick-menu .quick_list {
    width: 100%;
    display: flex;
    flex-direction: column;
}

/* 아이콘 링크/버튼: 기본+호버 이미지를 겹쳐 둠 */
.quick-menu .quick_item a,
.quick-menu .quick_top {
    position: relative;
    display: block;
    width: 100%;
}

.quick-menu .quick_icon {
    display: block;
    width: 100%;
    transition: opacity 0.3s ease;
}

/* 호버 이미지는 위에 겹쳐서 평소엔 숨김 */
.quick-menu .quick_icon--hover {
    position: absolute;
    top: 0;
    left: 0;
    opacity: 0;
}

/* 마우스 올리면 크로스페이드 */
.quick-menu .quick_item a:hover .quick_icon--default {
    opacity: 0;
}

.quick-menu .quick_item a:hover .quick_icon--hover {
    opacity: 1;
}

/* 모바일 전용 요소는 PC에서 숨김 */
.quick-menu .quick_icon--mo,
.quick-menu .quick_item--phone {
    display: none;
}

/* 모바일: 화면 하단에 가로 바로 고정 */
@media (max-width: 768px) {
    .quick-menu {
        top: auto;
        bottom: 0;
        left: 0;
        right: 0;
        width: 100%;
        transform: none;
        background-color: #fff;
        box-shadow: 0 0 10px 0 rgba(0, 0, 0, 0.1);
        z-index: 90;
    }

    .quick-menu .quick_list {
        flex-direction: row;
        justify-content: space-around;
        align-items: center;
    }

    .quick-menu .quick_item {
        flex: 1;
    }

    /* PC용 아이콘(기본/호버) 숨기고 모바일용 아이콘 표시 */
    .quick-menu .quick_icon--default,
    .quick-menu .quick_icon--hover {
        display: none;
    }

    .quick-menu .quick_icon--mo {
        display: block;
    }

    /* 전화상담 버튼 표시, TOP 버튼 숨김 */
    .quick-menu .quick_item--phone {
        display: block;
    }

    .quick-menu .quick_item--top {
        display: none;
    }
}

/* 메인 비주얼 ---------------------------------------------------------------------- */

.main-visual {
    margin-top: 175px;
    transition: margin-top 0.3s ease;
}

@media (max-width: 1170px) {
    .main-visual {
        margin-top: 50px;
    }
}

/* 갤러리 ---------------------------------------------------------------------- */
.gallery {
    padding: 100px 0;
}

.gallery .inner {
    width: 1170px;
    margin: 0 auto;
}

.gallery .gallery_list {
    position: relative;
    width: 100%;
    height: 700px;
}

.gallery .gallery_item {
    position: relative;
    width: 100%;
    height: 100%;
    overflow: hidden;
}

.gallery .gallery_item img {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    opacity: 0;
    transition: opacity 0.6s ease-in-out;
    pointer-events: none;
}

.gallery .gallery_item img.is-active {
    opacity: 1;
    pointer-events: auto;
}

.gallery .nav {
    position: absolute;
    bottom: 0;
    right: 0;
    display: flex;
    z-index: 1;
}

.gallery .nav .caption {
    width: 250px;
    height: 70px;
    background-color: #4c392b;
    display: flex;
    align-items: center;
    justify-content: center;

    color: #fff;
    font-weight: 600;
    font-size: 20px;
}

.gallery .nav .nav_btn {
    display: flex;
}

.gallery .nav_btn button {
    width: 70px;
    height: 70px;
    background-color: #4c392b;
    color: #fff;
    font-size: 20px;
}

.gallery .nav_btn button.nav_btn_next {
    background-color: #87674f;
}

/* 갤러리 반응형 (1170px 이하) ------------------------------------------------ */
@media (max-width: 1170px) {
    .gallery .inner {
        width: 100%;
        padding: 0 10%;
    }

    /* 높이를 가로값에 맞춰 자동(이미지 비율 1170:700) */
    .gallery .gallery_list {
        height: auto;
        aspect-ratio: 1170 / 700;
    }
}

@media screen and (max-width: 768px) {
    .gallery {
        padding: 50px 0;
    }

    .gallery .inner {
        padding: 0 5%;
    }

    .gallery .nav {
        width: 100%;
    }

    .gallery .nav .caption {
        width: 100%;
        height: 40px;
        font-size: 16px;
    }

    .gallery .nav_btn button {
        width: 40px;
        height: 40px;
        font-size: 16px;
    }
}

/* 푸터 ---------------------------------------------------------------------- */
.site-footer {
    position: relative;
}

.site-footer .map {
    position: absolute;
    width: 36.5vw;
    height: 19vw;
    top: 8%;
    right: 9%;
}

/* 다음(카카오) 약도가 .map 박스를 100% 채우도록 (인라인 height 덮어쓰기) */
.site-footer .map .root_daum_roughmap,
.site-footer .map .root_daum_roughmap .wrap_map {
    width: 100% !important;
    height: 100% !important;
}

/* 약도가 자체 주입하는 희미한 테두리/그림자 제거 */
.site-footer .map .root_daum_roughmap,
.site-footer .map .root_daum_roughmap_landing,
.site-footer .map .root_daum_roughmap .wrap_map,
.site-footer .map .root_daum_roughmap .wrap_controllers {
    border: none !important;
    box-shadow: none !important;
    outline: none !important;
}

.site-footer .sns-btns {
    position: absolute;
    top: 49%;
    left: 19.5%;
    display: flex;
    gap: 10px;
}

.site-footer .agreements {
    position: absolute;
    bottom: 20%;
    left: 19.5%;
    display: flex;
    gap: 30px;
}

.site-footer .agreements button {
    color: #fff;
    font-weight: 600;
    flex-shrink: 0;
}

/* 약관 팝업(모달) ---------------------------------------------------------- */
.agreement-modal {
    position: fixed;
    inset: 0;
    z-index: 998;
    display: none;
    align-items: center;
    justify-content: center;
    padding: 20px;
}

.agreement-modal.is-open {
    display: flex;
}

.agreement-modal__dim {
    position: absolute;
    inset: 0;
    background-color: rgba(0, 0, 0, 0.5);
}

.agreement-modal__panel {
    position: relative;
    width: min(760px, 100%);
    max-height: 85vh;
    display: flex;
    flex-direction: column;
    background-color: #fff;
    border-radius: 8px;
    overflow: hidden;
    box-shadow: 0 12px 40px rgba(0, 0, 0, 0.3);
}

.agreement-modal__head {
    flex: 0 0 auto;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    padding: 20px 24px;
    background-color: #4c392b;
    color: #fff;
}

.agreement-modal__title {
    font-size: 20px;
    font-weight: 700;
}

.agreement-modal__close {
    flex: 0 0 auto;
    width: 32px;
    height: 32px;
    color: #fff;
    font-size: 28px;
    line-height: 1;
    display: flex;
    align-items: center;
    justify-content: center;
}

.agreement-modal__body {
    flex: 1 1 auto;
    overflow-y: auto;
    padding: 24px;
    line-height: 1.7;
    color: #2a2a2a;
    user-select: text;
}

.agreement-modal__body p {
    margin: 0 0 12px;
}

/* 빈 줄 뒤에 오는 단락(조항 시작 등)에 위쪽 여백 */
.agreement-modal__body p.is-section {
    margin-top: 1.4em;
}

.agreement-modal__body img {
    width: 100%;
    height: auto;
    pointer-events: auto;
}

@media (max-width: 768px) {
    .agreement-modal__head {
        padding: 16px 18px;
    }

    .agreement-modal__title {
        font-size: 17px;
    }

    .agreement-modal__body {
        padding: 18px;
    }
}

@media (max-width: 768px) {
    .site-footer .map {
        top: 5%;
        right: 4%;
        width: 90vw;
        height: 50vw;
    }

    .wrap_btn_zoom {
        display: none !important;
    }

    .site-footer .sns-btns {
        display: none;
    }

    .site-footer .agreements {
        width: 100%;
        left: 0;
        justify-content: center;
        gap: 10px;
    }
}

/* 헤더 반응형 (모바일) ------------------------------------------------------ */
@media (max-width: 1170px) {
    /* 헤더 높이 50px, 로고만 가운데 */
    .site-header .header-top {
        height: 50px;
        gap: 0;
    }

    .site-header .header-top__slogan,
    .site-header .header-contact {
        display: none;
    }

    .site-header .header-logo a {
        width: 120px;
        height: 30px;
        background-position: center;
    }

    /* 햄버거 아이콘: 왼쪽 끝에 고정 (.mobile-only 의 block 을 flex 로 복구) */
    .site-header .gnb__toggle {
        display: flex !important;
        position: absolute;
        top: 50%;
        transform: translateY(-50%);
        left: 20px;
        z-index: 1;
    }

    /* 메뉴: 평소엔 접혀 있고(max-height 0), 햄버거 클릭(.is-open) 시 스르륵 펼쳐짐 */
    .site-header .gnb__menu {
        position: absolute;
        top: 100%;
        left: 0;
        width: 100%;
        height: auto;
        max-height: 0;
        overflow: hidden;
        background-color: #fff;
        border: none;
        transition: max-height 0.35s ease;
    }

    .site-header .gnb__menu.is-open {
        max-height: 400px;
        box-shadow: 0 10px 10px 0 rgba(0, 0, 0, 0.1);
    }

    .site-header .gnb__menu-inner {
        width: 100%;
        height: auto;
        flex-direction: column;
        align-items: stretch;
    }

    /* 메뉴 항목: 한 줄당 45px, 전체 너비 */
    .site-header .gnb__item {
        width: 100%;
        height: 45px;
        padding: 0 20px;
        justify-content: flex-start;
    }

    /* a 태그에 밑줄(PC hover 밑줄과 동일한 #000), 글자 너비만큼 */
    .site-header .gnb__link {
        padding: 3px 0;
        border-bottom: 2px solid #8f5830;
    }

    /* 모바일에서는 가운데부터 퍼지는 호버 효과 제거 */
    .site-header .gnb__link::after {
        display: none;
    }
}

/* 스크린리더 전용: 화면에서는 숨기되 크롤러/보조기기에는 노출 (로고 대체 텍스트 등) */
.visually-hidden {
    position: absolute;
    width: 1px;
    height: 1px;
    margin: -1px;
    padding: 0;
    border: 0;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
}

/*메인 팝업 ---------------------------------------------------------------------- */

#popupArea {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    z-index: 999;
    margin: 0;
    display: none;
    background-color: rgba(0, 0, 0, 0.5);
    align-items: center;
    justify-content: center;
    flex-wrap: wrap;
    gap: 24px;
    padding: 40px 20px;
    overflow-y: auto;
  }
  
  #popupArea.is-visible {
    display: flex;
  }
  
  #popupArea .item {
    position: relative;
    background: #fff;
    border-radius: 8px;
    overflow: hidden;
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.25);
    width: min(420px, 92vw);
    flex: 0 0 auto;
  }
  
  #popupArea.size-l .item { width: min(550px, 92vw); }
  #popupArea.size-m .item { width: min(550px, 44vw); }
  #popupArea.size-s .item { width: min(350px, 30vw); }
  
  #popupArea .item .popup-image {
    display: block;
    text-decoration: none;
    line-height: 0;
  }
  
  #popupArea .item .popup-image img {
    width: 100%;
    height: auto;
    display: block;
  }
  
  #popupArea .item .button_group {
    display: flex;
    justify-content: flex-end;
    align-items: stretch;
    background: #1a1a1a;
  }
  
  #popupArea .item .button_group button {
    flex: 0 0 auto;
    border: none;
    background: transparent;
    color: #fff;
    padding: 10px 16px;
    font-size: 13px;
    font-family: 'Pretendard-Medium', 'Noto Sans', sans-serif;
    cursor: pointer;
    line-height: 1.4;
  }
  
  #popupArea .item .button_group button + button {
    border-left: 1px solid rgba(255, 255, 255, 0.15);
  }
  
  #popupArea .item .button_group button:hover {
    background: rgba(255, 255, 255, 0.1);
  }
  
  @media (max-width: 768px) {
    #popupArea {
      padding: 0;
      gap: 0;
      align-items: center;
      justify-content: center;
      overflow: hidden;
    }
  
    #popupArea .item,
    #popupArea.size-l .item,
    #popupArea.size-m .item,
    #popupArea.size-s .item {
      position: absolute;
      top: 50%;
      left: 50%;
      width: 86vw;
      max-width: 400px;
      transform: translate(-50%, -50%);
    }
  
    #popupArea .item .button_group button {
      flex: 1 1 auto;
      padding: 12px 14px;
      font-size: 12px;
      text-align: center;
    }
  }
