/* ============================================================
   레이아웃: 헤더 / 푸터 / 섹션 / 그리드 / 모바일 CTA 바
   -- 업체가 바뀌어도 구조는 유지하는 부분입니다 --
   ============================================================ */

/* ---------- Header ---------- */
.site-header {
  position: sticky;
  top: 0;
  z-index: 100;
  height: var(--header-h);
  background: rgba(248, 247, 243, 0.98);
  border-bottom: 1px solid var(--color-border);
  transition: box-shadow var(--transition);
}
.site-header.scrolled {
  box-shadow: var(--shadow-sm);
}
.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 100%;
}
.logo {
  font-size: 1.3rem;
  font-weight: 800;
  color: var(--color-brand);
  letter-spacing: -0.01em;
  flex-shrink: 0;
}
.nav {
  display: flex;
  align-items: stretch;
  gap: var(--space-6);
  height: 100%;
}
.nav-item {
  position: relative;
  display: flex;
  align-items: center;
}
.nav-link {
  display: flex;
  align-items: center;
  gap: 4px;
  font-weight: 600;
  font-size: var(--fs-sm);
  color: var(--color-nav);
  padding: 8px 0;
  position: relative;
  transition: color var(--transition);
}
.nav-link:hover,
.nav-link.active {
  color: var(--color-brand);
}
.nav-link.active::after {
  content: "";
  position: absolute;
  left: 0;
  right: 0;
  bottom: -2px;
  height: 2px;
  background: var(--color-brand);
  border-radius: 2px;
}
.nav-caret {
  width: 6px;
  height: 6px;
  border-right: 1.5px solid currentColor;
  border-bottom: 1.5px solid currentColor;
  transform: rotate(45deg);
  margin-top: -3px;
  opacity: 0.5;
  flex-shrink: 0;
  transition: transform var(--transition);
}

/* Dropdown panel (desktop hover) */
.nav-dropdown {
  position: absolute;
  top: 100%;
  left: 50%;
  min-width: 210px;
  background: #fff;
  border: 1px solid var(--color-border);
  box-shadow: var(--shadow-md);
  padding: var(--space-2) 0;
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
  transform: translate(-50%, -6px);
  transition: opacity 0.18s ease, transform 0.18s ease, visibility 0.18s;
  z-index: 200;
}
.nav-item.has-dropdown:hover .nav-dropdown,
.nav-item.has-dropdown:focus-within .nav-dropdown {
  opacity: 1;
  visibility: visible;
  pointer-events: auto;
  transform: translate(-50%, 0);
}
.nav-dropdown a {
  display: block;
  padding: 11px 20px;
  font-size: 0.86rem;
  font-weight: 500;
  color: var(--color-text-secondary);
  white-space: nowrap;
  transition: color var(--transition), background var(--transition);
}
.nav-dropdown a:hover {
  color: var(--color-brand);
  background: var(--color-bg-alt);
}
.header-cta {
  display: flex;
  align-items: center;
  gap: var(--space-4);
}
.nav-toggle {
  display: none;
  flex-direction: column;
  justify-content: center;
  gap: 5px;
  width: 28px;
  height: 28px;
}
.nav-toggle span {
  display: block;
  height: 2px;
  background: var(--color-text);
  border-radius: 2px;
  transition: var(--transition);
}
.nav-toggle.active span:nth-child(1) {
  transform: translateY(7px) rotate(45deg);
}
.nav-toggle.active span:nth-child(2) {
  opacity: 0;
}
.nav-toggle.active span:nth-child(3) {
  transform: translateY(-7px) rotate(-45deg);
}
.nav-scrim {
  display: none;
}

@media (max-width: 900px) {
  .site-header {
    height: var(--header-h-mobile);
  }
  .nav {
    position: fixed;
    top: var(--header-h-mobile);
    right: 0;
    bottom: 0;
    width: min(320px, 82vw);
    height: auto;
    background: var(--color-white);
    flex-direction: column;
    align-items: stretch;
    padding: var(--space-6) var(--space-5);
    gap: var(--space-1);
    transform: translateX(100%);
    transition: transform 0.3s ease;
    overflow-y: auto;
    box-shadow: var(--shadow-lg);
    z-index: 150;
  }
  .nav.open {
    transform: translateX(0);
  }
  .nav-item {
    display: block;
    border-bottom: 1px solid var(--color-border);
  }
  .nav-link {
    font-size: 1.05rem;
    padding: 14px 4px;
    justify-content: space-between;
  }
  .nav-item.has-dropdown .nav-caret {
    width: 7px;
    height: 7px;
    transition: transform 0.2s ease;
  }
  .nav-item.mobile-open .nav-caret {
    transform: rotate(-135deg);
  }
  .nav-dropdown {
    position: static;
    left: auto;
    top: auto;
    min-width: 0;
    opacity: 1;
    visibility: visible;
    pointer-events: auto;
    transform: none;
    background: transparent;
    border: none;
    box-shadow: none;
    padding: 0;
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.25s ease;
  }
  .nav-item.has-dropdown:hover .nav-dropdown,
  .nav-item.has-dropdown:focus-within .nav-dropdown {
    position: static;
    transform: none;
  }
  .nav-item.mobile-open .nav-dropdown {
    max-height: 320px;
    padding-bottom: 6px;
  }
  .nav-dropdown a {
    padding: 11px 4px 11px 18px;
    font-size: 0.95rem;
    color: var(--color-text-secondary);
  }
  .nav-toggle {
    display: flex;
  }
  .header-cta .btn-sm .cta-phone-text {
    display: none;
  }
  .header-cta .header-kakao {
    display: none;
  }
  .nav-scrim {
    position: fixed;
    inset: 0;
    top: var(--header-h-mobile);
    background: rgba(16, 24, 40, 0.4);
    z-index: 99;
    opacity: 0;
    pointer-events: none;
    transition: opacity var(--transition);
  }
  .nav-scrim.open {
    display: block;
    opacity: 1;
    pointer-events: auto;
  }
}

/* ---------- Section ---------- */
.section {
  padding: var(--section-py) 0;
}
.section-alt {
  background: var(--color-bg-alt);
}
.section-dark {
  background: var(--color-dark);
  color: #fff;
}
.section-head {
  max-width: 640px;
  margin: 0 auto var(--space-7);
  text-align: center;
}
.section-label {
  display: inline-block;
  color: var(--color-brand);
  font-weight: 700;
  font-size: var(--fs-eyebrow);
  margin-bottom: var(--space-3);
  letter-spacing: var(--ls-eyebrow);
  text-transform: uppercase;
}
.section-dark .section-label {
  color: #5fb8c9;
}
.section-title {
  font-size: var(--fs-h2);
  font-weight: 800;
  line-height: var(--lh-tight);
  letter-spacing: -0.01em;
  margin-bottom: var(--space-4);
  white-space: pre-line;
}
.section-desc {
  color: var(--color-text-secondary);
  font-size: var(--fs-lg);
  line-height: var(--lh-normal);
}
.section-dark .section-desc {
  color: #98a2b3;
}

/* ---------- Grid utilities ---------- */
.grid-2 {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: var(--space-7);
  align-items: center;
}
@media (max-width: 900px) {
  .grid-2 {
    grid-template-columns: 1fr;
    gap: var(--space-6);
  }
}

/* ---------- Footer ---------- */
.site-footer {
  background: var(--color-dark);
  color: #b7bfcc;
  padding: var(--space-8) 0 var(--space-5);
}
.footer-grid {
  display: grid;
  grid-template-columns: 1.4fr 1fr 1fr;
  gap: var(--space-7);
  padding-bottom: var(--space-6);
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
}
.footer-logo {
  font-size: 1.2rem;
  font-weight: 800;
  color: #fff;
  margin-bottom: var(--space-3);
  display: inline-block;
  letter-spacing: -0.01em;
}
.footer-col h4 {
  color: #fff;
  font-size: var(--fs-sm);
  margin-bottom: var(--space-3);
  font-weight: 700;
}
.footer-col p,
.footer-col li {
  font-size: var(--fs-sm);
  line-height: var(--lh-loose);
}
.footer-col a:hover {
  color: #fff;
}
.footer-bottom {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding-top: var(--space-5);
  font-size: var(--fs-xs);
  flex-wrap: wrap;
  gap: 8px;
}
.footer-credit a {
  color: #fff;
  font-weight: 700;
}
@media (max-width: 768px) {
  .footer-grid {
    grid-template-columns: 1fr;
    gap: var(--space-6);
  }
  .footer-bottom {
    flex-direction: column;
    align-items: flex-start;
  }
}

/* ---------- Mobile bottom CTA bar ---------- */
.mobile-cta-bar {
  display: none;
}
@media (max-width: 900px) {
  .mobile-cta-bar {
    display: flex;
    position: fixed;
    left: 0;
    right: 0;
    bottom: 0;
    z-index: 200;
    background: #fff;
    box-shadow: 0 -6px 20px rgba(16, 24, 40, 0.12);
    padding: 10px;
    gap: 8px;
  }
  .mobile-cta-bar .btn {
    flex: 1;
  }
  body {
    padding-bottom: 66px;
  }
}
