@charset "utf-8";

/* ============================
   퀵메뉴 (template-parts/quick-menu.php)
   PC : 상단이동 버튼(#ast-scroll-top, right 19px · bottom 48px · 70px) 바로 위에 같은 폭으로 세로 정렬
   모바일(900px 이하) : 화면 하단 고정 바
   스크롤을 조금 내리면(custom.js initQuickMenu → .is_show) 스르륵 나타난다
   아이콘 색은 SVG 원본 색 그대로, hover 시 #354746
============================ */
.quick_menu {
  position: fixed;
  right: 19px;
  bottom: calc(48px + 70px + 16px);
  z-index: 990;
  opacity: 0;
  visibility: hidden;
  transform: translateY(20px);
  transition: opacity 0.5s ease, transform 0.5s ease, visibility 0.5s;
}

.quick_menu.is_show {
  opacity: 1;
  visibility: visible;
  transform: none;
}

.quick_menu ul {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 20px;
  margin: 0;
  padding: 36px 0;
  width: 70px;
  border-radius: 999px;
  background: var(--white-c);
  box-shadow: 0 4px 24px rgba(0, 0, 0, 0.08);
}

.quick_menu li {
  list-style: none;
  margin: 0;
}

.quick_menu a {
  display: block;
  line-height: 0;
}

.quick_menu svg {
  display: block;
  width: 34px;
  height: 34px;
}

.quick_menu .qm_c1,
.quick_menu .qm_c2 {
  transition: fill 0.3s ease;
}

.quick_menu .qm_c1 {
  fill: #39bdae;
}

.quick_menu .qm_c2 {
  fill: #888a8c;
}

.quick_menu a:hover .qm_c1,
.quick_menu a:hover .qm_c2,
.quick_menu a:focus-visible .qm_c1,
.quick_menu a:focus-visible .qm_c2 {
  fill: #354746;
}

@media screen and (max-width: 900px) {
  .quick_menu {
    right: 0;
    bottom: 0;
    left: 0;
    transform: translateY(100%);
  }

  .quick_menu.is_show {
    transform: none;
  }

  .quick_menu ul {
    flex-direction: row;
    justify-content: space-around;
    gap: 0;
    width: 100%;
    padding: 10px 0 calc(10px + env(safe-area-inset-bottom));
    border-radius: 20px 20px 0 0;
    box-shadow: 0 -4px 20px rgba(0, 0, 0, 0.08);
  }

  .quick_menu li {
    flex: 1 1 0;
  }

  .quick_menu a {
    display: flex;
    justify-content: center;
    padding: 4px 0;
  }

  .quick_menu svg {
    width: 34px;
    height: 34px;
  }

  /* 하단 바에 푸터 끝부분이 가려지지 않게 바 높이만큼 띄운다 */
  body {
    padding-bottom: calc(62px + env(safe-area-inset-bottom));
  }
}


/* ============================
   하단 고정 빠른상담 바
   입력 필드는 CF7 출력이라 .wpcf7-* 선택자를 함께 다룬다
============================ */
/* 바 자체를 1200px 로 가둔다. 화면 전체를 덮으면 상단이동 버튼 등 뒤쪽 요소가 눌리지 않는다 */
.quick_form {
  position: fixed;
  left: 0;
  right: 0;
  bottom: 0;
  z-index: 95;
  max-width: 1200px;
  margin: 0 auto;
}

.quick_form_inner {
  position: relative;
  display: flex;
  height: 92px;
  background: var(--sub-c-05);
  box-shadow: 0 10px 34px rgba(18, 25, 51, 0.22);
}

/* ── 좌측 : 전화 ── */
.quick_form_tel {
  flex: 0 0 336px;
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 0 var(--space-sm);
  background: #e7ebf7;
}

.quick_form_ico {
  flex: none;
  display: grid;
  place-items: center;
  width: 46px;
  height: 46px;
  border-radius: 50%;
  background: #cdd7f0;
}

/* 아이콘 색을 CSS로 제어하기 위해 mask 사용 */
.quick_form_ico::before {
  content: '';
  width: 22px;
  height: 22px;
  background-color: var(--sub-c-03);
  -webkit-mask: url('../images/tel_icon.png') no-repeat center / contain;
  mask: url('../images/tel_icon.png') no-repeat center / contain;
}

.quick_form_label {
  display: block;
  font-size: var(--p-caption);
  color: #6a7185;
}

.quick_form_num {
  display: block;
  font-size: var(--h3-size);
  font-weight: var(--font-w-bm);
  line-height: 1.2;
  letter-spacing: -0.01em;
  color: var(--sub-c-03);
}

/* ── 우측 : 입력 필드 ── */
.quick_form_field {
  flex: 1 1 auto;
  display: flex;
  align-items: center;
  min-width: 0;
}

.quick_form_field .qf_row {
  display: flex;
  align-items: center;
  gap: var(--space-sm);
  height: 100%;
  padding: 0 var(--space-sm);
}

.quick_form_field .qf_item {
  flex: 1 1 0;
  min-width: 0;
  margin: 0;
  padding: 0;
}

.quick_form_field .qf_item--field {
  flex: 1.6 1 0;
}

.quick_form_field input[type='text'],
.quick_form_field input[type='tel'],
.quick_form_field select {
  width: 100%;
  height: 38px;
  padding: 0 2px;
  border: 0;
  border-bottom: 1px solid rgba(18, 25, 51, 0.35);
  border-radius: 0;
  background: transparent;
  font-size: var(--p-caption);
  color: var(--sub-c-03);
  outline: none;
  transition: border-color 0.3s ease;
}

.quick_form_field input:focus,
.quick_form_field select:focus {
  border-bottom-color: var(--sub-c-03);
}

.quick_form_field input::placeholder {
  color: #6a7185;
}

/* 기본 화살표를 지우고 시안의 얇은 화살표로 대체 */
.quick_form_field select {
  -webkit-appearance: none;
  appearance: none;
  padding-right: 24px;
  background-image: linear-gradient(45deg, transparent 50%, #6a7185 50%),
                    linear-gradient(135deg, #6a7185 50%, transparent 50%);
  background-position: calc(100% - 12px) 17px, calc(100% - 7px) 17px;
  background-size: 5px 5px;
  background-repeat: no-repeat;
}

.quick_form_field .qf_agree {
  flex: none;
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  gap: 8px;
}

.quick_form_field .qf_agree_row {
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: var(--p-caption);
  color: var(--sub-c-03);
}

.quick_form_field .qf_agree_row .wpcf7-list-item {
  margin: 0;
}

.quick_form_field input[type='checkbox'] {
  width: 14px;
  height: 14px;
  accent-color: var(--sub-c-03);
}

.quick_form_field input[type='checkbox'],
.quick_form_field .qf_agree_row label {
  cursor: pointer;
}

.quick_form_field .qf_agree_link {
  color: var(--sub-c-03);
  text-decoration: underline;
  text-underline-offset: 3px;
}

.quick_form_field input[type='submit'] {
  min-width: 132px;
  height: 38px;
  padding: 0 18px;
  border: 0;
  border-radius: 0;
  background: var(--sub-c-03);
  color: var(--white-c);
  font-size: var(--p-caption);
  font-weight: var(--font-w-bm);
  cursor: pointer;
  transition: background-color 0.3s ease;
}

.quick_form_field input[type='submit']:hover {
  background: var(--main-c);
}

/* CF7 은 동의 체크 전까지 전송 버튼을 disabled 로 둔다.
   추가 설정에 acceptance_as_validation: on 을 넣으면 이 상태는 생기지 않는다 */
.quick_form_field input[type='submit']:disabled {
  opacity: 0.5;
  cursor: not-allowed;
}

.quick_form_field .wpcf7-form-control-wrap {
  display: block;
}

/* 오류 내용은 팝업(#formAlert)이 안내하므로, 여기서는 문제가 된 칸만 표시한다 */
.quick_form_field .wpcf7-not-valid {
  border-bottom-color: #c0392b;
}

/* 모바일 전용 토글 버튼 */
.quick_form_toggle {
  display: none;
  flex: 1 1 50%;
  border: 0;
  background: var(--sub-c-05);
  font-size: var(--p-body);
  font-weight: var(--font-w-bm);
  color: var(--sub-c-03);
  cursor: pointer;
}

@media screen and (max-width: 1279px) {
  .quick_form {
    padding: 0 var(--space-sm);
  }
}

@media screen and (max-width: 1023px) {
  .quick_form_tel {
    flex-basis: 260px;
  }

  .quick_form_field .qf_row {
    gap: var(--space-xs);
    padding: 0 var(--space-xs);
  }
}

/* 모바일 : 전화 + 상담신청하기 두 칸, 입력은 버튼으로 펼친다 */
@media screen and (max-width: 900px) {
  .quick_form {
    bottom: 0;
    padding: 0;
    max-width: none;
  }

  .quick_form_inner {
    height: 64px;
  }

  .quick_form_tel {
    flex: 1 1 50%;
    justify-content: center;
    gap: 10px;
    padding: 0 var(--space-xs);
  }

  .quick_form_ico {
    width: 36px;
    height: 36px;
  }

  .quick_form_ico::before {
    width: 17px;
    height: 17px;
  }

  .quick_form_num {
    font-size: 20px;
  }

  .quick_form_toggle {
    display: block;
  }
  /* 바 위로 펼쳐지는 입력 영역 */
  .quick_form_field {
    position: absolute;
    left: 0;
    right: 0;
    bottom: 100%;
    padding: var(--space-sm) var(--space-xs);
    background: #e7ebf7;
    box-shadow: 0 -10px 24px rgba(18, 25, 51, 0.14);
    opacity: 0;
    visibility: hidden;
    transform: translateY(12px);
    transition: opacity 0.3s ease, transform 0.3s ease, visibility 0.3s;
    justify-content: center;
  }

  .quick_form.is_open .quick_form_field {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
  }

  .quick_form_field .qf_row {
    display: block;
    height: auto;
    padding: 0;
  }

  .quick_form_field .qf_item {
    margin-bottom: 10px;
  }

  .quick_form_field .qf_agree {
    flex-direction: row;
    align-items: center;
    justify-content: space-between;
    gap: var(--space-xs);
    margin-top: var(--space-xs);
  }

  .quick_form_field input[type='submit'] {
    min-width: 120px;
  }

}

@media screen and (max-width: 480px) {
  .quick_form_num {
    font-size: 17px;
  }
}
