/* ===========================
   layout.css — 공통 레이아웃
=========================== */

/* =========================================
   1) GLOBAL LAYOUT
========================================= */

/* 1-1) 헤더 fixed 보정 */
body {
  padding-top: 80px; /* 데스크탑 헤더 높이 */
}

@media (max-width: 1023px) {
  body {
    padding-top: 64px; /* 태블릿·모바일 헤더 높이 */
  }
}

/* 1-2) 공통 섹션 폭/패딩 */
.section {
  width: 100%;
  max-width: none;
  margin: 0;
  padding: 80px 0;
}

@media (max-width: 1023px) {
  .section {
    padding: 56px 0;
  }
}


/* =========================================
   2) GLOBAL HEADER
========================================= */

/* 2-1) 헤더 래퍼 (fixed) */
.global-header {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  background-color: #ffffff;
  border-bottom: 1px solid #e5e5e6;
  z-index: 100;
}

/* 2-2) 헤더 본체 */
.site-header {
  width: 100%;
}

.site-header__inner {
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 0 24px;
  height: 80px;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

/* 로고 */
.site-logo {
  display: inline-flex;
  align-items: center;
  justify-content: center;
}

.logo-mark {
  width: 100px;
  height: 48px;
  background-image: url("../images/common/logo-boum.svg");
  background-size: contain;
  background-repeat: no-repeat;
  background-position: center;
}

/* 오른쪽 그룹: 메뉴 + 버튼 묶음 */
.site-header__right {
  display: flex;
  align-items: center;
  gap: 16px;
}

/* 데스크탑 메뉴 */
.nav-desktop {
  margin-left: 40px;
}

.nav-list {
  display: flex;
  gap: 16px;
  list-style: none;
}

.nav-link {
  display: inline-block;
  padding: 8px 18px;        /* 🔹 배경 들어갈 여유 패딩 */
  border-radius: 8px;     /* 🔹 알약 모양 */
  color: #4f4f4f;
  text-decoration: none;
  font-weight: 500;
  transition: background-color 0.2s ease, color 0.2s ease;
}

.nav-link:hover {
  background-color: #f5fafc;
  color: #13536b;
}

/* 우측 영역 (문의 버튼 + 햄버거) */
.nav-actions {
  display: flex;
  align-items: center;
  gap: 12px;
}

/* 문의 버튼 (헤더 전용) */
.btn-contact {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 10px 20px;
  border-radius: 12px;
  background-color: #5d9db6;
  color: #ffffff;
  font-size: 15px;
  font-weight: 600;
  text-decoration: none;
}

/* 햄버거 버튼 (모바일 전용) */
.nav-toggle {
  display: none; /* 데스크탑에서는 숨김 */
  border: none;
  background: transparent;
  padding: 8px;
}

.icon-menu {
  width: 24px;
  height: 24px;
}

/* 기본: 햄버거만 보이게 */
.nav-toggle .icon-menu {
  display: block;
}

/* 닫기 아이콘은 기본 숨김 */
.nav-toggle .icon-close {
  display: none;
}

/* 모바일 메뉴 열렸을 때: X 아이콘으로 교체 */
.global-header.is-open .nav-toggle .icon-menu {
  display: none;
}

.global-header.is-open .nav-toggle .icon-close {
  display: block;
}

/* 모바일 메뉴 레이어 */
.nav-mobile {
  display: none;
  position: fixed;
  top: 64px;              /* 모바일 헤더 높이 */
  left: 0;
  width: 100%;
  background: #ffffff;
  padding: 16px 20px 20px;
  border-top: 1px solid #e5e5e6;
  box-shadow: 0 8px 16px rgba(0, 0, 0, 0.06);
  z-index: 99;
}

/* header 열렸을 때 */
.global-header.is-open .nav-mobile {
  display: block;
}

/* nav-mobile 링크 */
.nav-mobile-list {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 14px;
}

.nav-mobile-link {
  display: block;
  padding: 12px 12px;
  font-size: 17px;
  color: #424242;
  text-decoration: none;
  font-weight: 500;
  border-radius: 6px;
}

.nav-mobile-link:hover,
.nav-mobile-link:active {
  background-color: #f3f7f9;
  color: #13536b;
}

/* 2-3) 헤더 반응형 */
@media (max-width: 1023px) {
  .site-header__inner {
    height: 64px;
    padding: 0 20px;
  }

  .nav-desktop {
    display: none;
  }

  .nav-toggle {
    display: inline-flex;
  }
}

@media (max-width: 1023px) {
  .logo-mark {
    width: 80px;
    height: 36px;
  }
}

/* PC에서 nav-mobile 무조건 숨김 */
@media (min-width: 1024px) {
  .nav-mobile {
    display: none !important;
    position: static;
    box-shadow: none;
    border-top: none;
    padding: 0;
  }

  .global-header.is-open .nav-mobile {
    display: none !important;
  }
}

/* =============================
   ACTIVE MENU (현재 페이지 표시)
============================= */

/* 병원 파트너 서비스 활성화 */
.page--dental .nav--dental {
  background-color: #f5fafc;  /* 모바일에서 쓰는 밝은 블루톤 배경 */
  color: #13536b;
  font-weight: 700;
}

/* 개인 케어 서비스 활성화 */
.page--insured .nav--insured {
  background-color: #f5fafc;
  color: #13536b;
  font-weight: 700;
}

/* 문의 페이지일 때는 문의 버튼 쪽만 강조 (필요 시) */
.page--contact .btn-contact {
  background-color: #1680ac;
  color: #ffffff;
}



/* =============================
   3) GLOBAL HERO
   - hero__bg : 고정 높이 배경 레이어
   - hero__content / hero__inner : 실제 콘텐츠
============================= */

.hero {
  position: relative;
  width: 100%;
  overflow: visible;         /* 비주얼이 아래 섹션과 살짝 겹쳐도 보이게 */
}

/* 3-0) 배경 레이어 */
.hero__bg {
  position: absolute;
  left: 0;
  top: 0;
  width: 100%;
  height: 760px;  /* PC 기준 그라데이션 높이 (모든 페이지 공통) */
  background: linear-gradient(180deg, #ffffff 0%, #ffffff 40%, #d5e6ef 100%);
  pointer-events: none;
  z-index: 0;
}

/* 3-0) 콘텐츠 레이어 */
.hero__content {
  position: relative;
  z-index: 1;   /* 배경보다 위로 */
}

/* 3-1) 인너 레이아웃 */
.hero__inner {
  max-width: 1320px;
  margin: 0 auto;
  padding: 120px 20px 120px;  /* 위/아래 여백 (PC 공통) */
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
}

/* 3-2) 타이틀 / 서브 카피 */
.hero__title {
  margin-bottom: 28px;
}

.hero__desc {
  margin-top: 0;
}


/* 3-3) 비주얼 공통 래퍼 */
.hero__visual {
  width: 100%;
  max-width: 860px;
  margin: 40px auto 0;
  position: relative;
  z-index: 1;
}

.hero__visual img,
.hero__image {
  width: 100%;
  height: auto;
  object-fit: contain;
  pointer-events: none;
  user-select: none;
  display: block;
}

/* ============================
   3-4) HERO 반응형 — 390~1023
   (모바일 + 태블릿 공통)
============================ */

@media (max-width: 1023px) {
  /* 배경 높이 조금 줄이기 */
  .hero__bg {
    height: 520px;
  }

  .hero__inner {
    padding: 96px 20px 72px;
  }

  .hero__title {
    margin-bottom: 16px;
  }

  .hero__desc {
    margin-top: 0;
  }

  .hero__visual {
    max-width: 90%;
    margin-top: 24px;
  }
}



/* =========================================
   4) GLOBAL FOOTER (PC + MOBILE)
========================================= */

.global-footer {
  width: 100%;
  background-color: #293344;
  padding: 56px 0 72px;
}

.footer {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 48px;
  display: flex;
  flex-direction: column;
  gap: 24px;
  color: #e5e5e5;
}

/* Logo */
.footer .b-logo {
  width: 116px;
  height: auto;
}

/* 텍스트 묶음 */
.footer-info {
  display: flex;
  flex-direction: column;
  gap: 8px;
  font-size: 14px;
  line-height: 22px;
}

/* 링크 영역 */
.footer-links {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-top: 8px;
}

.footer-link {
  color: #e5e5e5;
  text-decoration: none;
  font-weight: 500;
}

.footer-link:hover {
  opacity: 0.7;
}

/* Divider */
.footer-links .divider {
  width: 1px;
  height: 16px;
  background-color: #e5e5e5;
}

/* Copyright */
.footer .copyright {
  margin-top: 12px;
  font-size: 14px;
  opacity: 0.8;
}

/* MOBILE FOOTER */
@media (max-width: 1023px) {
  .footer {
    padding: 0 24px;
    gap: 20px;
  }

  .footer .b-logo {
    width: 77px;
  }

  .footer-info {
    font-size: 13px;
    line-height: 20px;
  }
}



/* ================================
   Floating Kakao Channel Button
================================ */

.floating-kakao {
  position: fixed;
  right: 24px;         /* PC에서 오른쪽 여백 */
  bottom: 24px;        /* PC에서 아래 여백 */
  width: 72px;
  height: 72px;
  z-index: 9999;       /* 다른 요소 위로 올라오게 */
  display: flex;
  align-items: center;
  justify-content: center;
  text-decoration: none;
  border-radius: 50%;
  box-shadow: 0 10px 25px rgba(0, 0, 0, 0.25);
  transition: transform 0.15s ease-out, box-shadow 0.15s ease-out;
}

.floating-kakao img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: contain;
  border-radius: 50%;
}

/* hover 효과 (PC에서만 체감) */
.floating-kakao:hover {
  transform: translateY(-2px) scale(1.03);
  box-shadow: 0 14px 30px rgba(0, 0, 0, 0.3);
}

/* 모바일일 때 위치/크기 살짝 줄이기 */
@media (max-width: 768px) {
  .floating-kakao {
    right: 16px;
    bottom: 16px;
    width: 60px;
    height: 60px;
    box-shadow: 0 8px 18px rgba(0, 0, 0, 0.22);
  }
}