/* ═══════════════════════════════════════════════════
   FARO Common Styles v2.0 — common.css
   모바일 퍼스트 | 최소 폰트 14px | 반응형 준비
   ═══════════════════════════════════════════════════ */


/* ─── 1. 리셋 & 기본 ─── */
*, *::before, *::after { box-sizing: border-box; }

html, body {
  margin: 0;
  background: #0f0d0b;
  color: var(--ink);
  font-family: var(--sans);
  font-size: var(--font-body);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  word-break: keep-all;
}

button, input, textarea, select { font: inherit; }
button  { border: 0; background: none; color: inherit; cursor: pointer; padding: 0; }
a       { color: inherit; text-decoration: none; }
img     { display: block; max-width: 100%; }
body.lock { overflow: hidden; }

/* ─── 1-1. 키보드 포커스 표시 (마우스 클릭 시엔 나타나지 않음) ─── */
button:focus-visible,
a:focus-visible,
input:focus-visible,
select:focus-visible,
textarea:focus-visible {
  outline: 2px solid var(--gold);
  outline-offset: 2px;
}


/* ─── 2. 타이포그래피 ─── */
h1, h2, h3 {
  font-family: var(--sans);
  letter-spacing: -.03em;
  margin: 0;
}
h1 { font-size: var(--font-h1); line-height: 1.08; font-weight: 600; }  /* Hero Title */
/* Section Title — h1(Home Hero/Page Hero)보다 항상 명확히 작도록 --font-h2 토큰 대신
   전용 clamp 사용(토큰값은 1440에서 46px까지 커져 Home Hero 42px을 넘어서던 문제 수정) */
h2 { font-size: clamp(28px, 3.3vw, 39px); line-height: 1.18; font-weight: 500; }
h3 { font-size: var(--font-h3); line-height: 1.3;  font-weight: 600; }  /* Point / Card Title */
p  { font-size: var(--font-body); line-height: 1.7; color: var(--muted); margin: 0; }

.eyebrow {
  font-family: var(--sans);
  font-size: var(--text-xs);   /* 14px */
  font-weight: 500;
  line-height: 1.4;
  letter-spacing: .18em;
  text-transform: uppercase;
  color: var(--gold);
  margin-bottom: 16px;
}

.page-title    { /* h1 역할과 동일 */ }
.page-subtitle { /* 인트로 단락과 동일 */ }

/* ─── 3. 앱 셸 ─── */
.app {
  width: 100%;
  min-height: 100vh;
  background: linear-gradient(180deg, #fffaf3, #f3eadf 52%, #fffaf3);
  position: relative;
}


/* ─── 4. 상단 진행 표시줄 ─── */
.progress {
  position: fixed;
  top: 0; left: 0;
  height: 2px;
  width: 0;
  background: linear-gradient(90deg, var(--champ), var(--gold));
  z-index: 300;
  transition: width .1s linear;
}


/* ─── 5. 공지 바 ─── */
.notice {
  height: 36px;
  background: #f4eee6;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: var(--text-xs);  /* 14px */
  color: #5a4a3a;
  letter-spacing: .06em;
  border-bottom: 1px solid var(--line);
}


/* ─── 6. 헤더 ─── */
.header {
  height: var(--header-height-mobile);  /* 60px */
  position: sticky;
  top: 0;
  z-index: 80;
  background: rgba(250, 246, 239, .93);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 20px;  /* --space-5가 신규 spacing scale(24px)로 갱신되어 리터럴로 고정 — 헤더 값 불변 보장 */
  border-bottom: 1px solid var(--line);
}

/* 헤더 로고 (logo.png 1개 — FARO/모양/필리아가 이미 정렬된 단일 이미지) */
.header-logo, .logo {
  display: flex;
  align-items: center;
  flex-shrink: 0;
  padding: 0;
}
/* 일반 .logo img — Footer/Mobile Menu 등 헤더 밖 모든 로고의 기본 크기.
   .header-logo img(아래)와 완전히 분리된 selector — 헤더 크기 변경이 여기로 새지 않음 */
.logo img {
  height: 21px;
  width: auto;
}
/* 헤더 전용 로고 — .logo img보다 뒤에 위치해 header-logo(class="header-logo logo")에서 우선 적용.
   높이는 브레이크포인트별로 아래에서 재정의(모바일 common.css 기본값 = mobile.css/redesign.css가 각 구간에서 override) */
.header-logo img {
  height: 21px;
  width: auto;
  position: relative;
  top: 5px;  /* 헤더 높이는 그대로 두고 로고만 살짝 하향 보정 */
}

/* 헤더 우측 액션 영역 */
.header-actions {
  display: flex;
  align-items: center;
  gap: var(--space-3);
  flex-shrink: 0;
}

/* 헤더 예약 상담 버튼 (모바일 숨김, 데스크톱 표시) */
.header-cta {
  display: none;
  height: 38px;
  padding: 0 18px;
  background: var(--brown);
  color: #fff;
  font-size: 15px;
  letter-spacing: .08em;
  text-transform: uppercase;
  border-radius: var(--radius-sm);
  transition: var(--duration-fast) var(--ease);
}
.header-cta:hover { opacity: .88; }

/* ─── 7. 데스크톱 네비게이션 (모바일 숨김) ─── */
.desktop-nav {
  display: none;
  align-items: center;
  gap: 28px;
  flex: 1;
  justify-content: center;
}

.desktop-nav button, .desktop-nav a {
  font-size: 15px;
  letter-spacing: .1em;
  text-transform: uppercase;
  color: var(--muted);
  padding: 6px 0;
  position: relative;
  transition: color var(--duration-fast);
}
.desktop-nav button:hover, .desktop-nav a:hover { color: var(--ink); }
.desktop-nav button.active, .desktop-nav a.active { color: var(--ink); }
.desktop-nav button.active::after, .desktop-nav a.active::after {
  content: '';
  position: absolute;
  bottom: -2px;
  left: 0; right: 0;
  height: 1px;
  background: var(--color-primary);
}


/* ─── 8. 햄버거 버튼 ─── */
.hamb {
  width: 44px;
  height: 44px;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  gap: 5px;
  border-radius: var(--radius-sm);
  flex-shrink: 0;
}
.hamb svg { color: var(--ink); }


/* ─── 9. 메뉴 오버레이 ─── */
.menu {
  position: fixed;
  inset: 0;
  z-index: 200;
  background: linear-gradient(180deg, #fbf7ef, #f3eadf);
  transform: translateX(-105%);
  transition: transform var(--duration-slow) var(--ease);
  overflow-y: auto;
  overflow-x: hidden;
  max-width: 440px;
}
.menu.open { transform: translateX(0); }

.menu-head {
  height: 72px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 0 20px;
  border-bottom: 1px solid var(--line);
  position: sticky;
  top: 0;
  background: inherit;
  z-index: 1;
}
.menu-head .logo { padding: 0; }
/* 메뉴 진입 시 상단 로고를 현재 표시 크기(height:21px, width≈218px)의 120%로 —
   실제 width 지정 + height:auto로 비율 유지(transform:scale 미사용) */
.menu-head .logo img { width: 262px; height: auto; }
.x {
  width: 44px;
  height: 44px;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  color: var(--muted);
}
.x svg { width: 22px; height: 22px; }

.menu-links { padding: 4px 20px 8px; }
.menu-links button, .menu-links a {
  position: relative;
  isolation: isolate;
  width: 100%;
  box-sizing: border-box;
  display: grid;
  grid-template-columns: 1fr auto;
  align-items: center;
  gap: 12px;
  text-align: left;
  padding: 16px 10px;
  border-bottom: 1px solid rgba(139, 115, 81, .16);
}
.menu-links button > *, .menu-links a > * { position: relative; z-index: 1; }
.menu-main { display: block; font-family: var(--sans); font-size: 22px; line-height: 1.15; }
.menu-ko   { display: block; margin-top: 4px; font-size: var(--text-xs); color: #8d7351; }

/* 현재 페이지 표시 — 배경 박스를 좌우 4px씩 더 넓게(::before, 텍스트/화살표 위치는 무영향) */
.menu-links button.is-active::before, .menu-links a.is-active::before {
  content: "";
  position: absolute;
  inset: 0 -4px;
  background: rgba(176, 134, 83, .09);
  border-radius: 6px;
  z-index: 0;
}
.menu-links button.is-active .menu-main, .menu-links a.is-active .menu-main { color: var(--gold); }
.menu-links button.is-active .menu-ko, .menu-links a.is-active .menu-ko { color: var(--ink); }
.menu-links button.is-active > span:last-child, .menu-links a.is-active > span:last-child { color: var(--gold); }

/* ─── 10. 페이지 시스템 (SPA) ─── */
.page {
  display: none;
  min-height: calc(100vh - var(--header-height-mobile));
  min-height: calc(100svh - var(--header-height-mobile));
  animation: page-fade var(--duration) var(--ease);
}
.page.active { display: block; }

@keyframes page-fade {
  from { opacity: 0; transform: translateY(6px); }
  to   { opacity: 1; transform: none; }
}


/* ─── 11. 섹션 & 구분선 ─── */
section.block, .section {
  padding: var(--section-py) var(--section-px);
  border-bottom: 1px solid rgba(38, 29, 22, .08);
}

.rule {
  height: 1px;
  background: linear-gradient(90deg, transparent, rgba(168, 135, 93, .4), transparent);
  margin: 32px 0;
}



/* ─── 13. 프레임 (이미지 플레이스홀더) ─── */
.frame {
  min-height: 320px;
  border: 1px solid var(--line-gold);
  background:
    radial-gradient(circle at 76% 18%, rgba(199, 170, 114, .2), transparent 30%),
    linear-gradient(135deg, #fffaf3, #d8c8b6 56%, #b99150);
  position: relative;
  box-shadow: var(--shadow-card);
  overflow: hidden;
}
.frame::before {
  content: "";
  position: absolute;
  inset: 14px;
  border: 1px solid rgba(255, 255, 255, .6);
  pointer-events: none;
}
.frame.dark {
  background:
    radial-gradient(circle at 76% 18%, rgba(199, 170, 114, .18), transparent 30%),
    linear-gradient(135deg, #15110e, #3b2d21 56%, #a8875d);
}


/* ─── 15. 그리드 & 카드 ─── */
.grid { display: grid; gap: 14px; }

/* ─── 16. 버튼 ─── */
.btn {
  height: 48px;
  min-height: 48px;
  padding: 0 26px;
  border: 1px solid rgba(38, 29, 22, .22);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  font-size: var(--text-xs);  /* 14px */
  letter-spacing: .09em;
  text-transform: uppercase;
  transition: transform var(--duration) var(--ease), box-shadow var(--duration) var(--ease);
  border-radius: var(--radius-sm);
}
.btn:hover { transform: translateY(-2px); box-shadow: var(--shadow); }
.btn.dark   { background: var(--brown); color: #fff; border-color: var(--brown); }
.btn.full   { width: 100%; margin-top: 0; }

/* .btn 컴포넌트 자체는 배치 margin을 갖지 않음 — 버튼과 앞 요소의 간격은 문맥(copy-stack)이 담당.
   아래는 이번 1차 범위 밖(Collection/Craft/Store CTA 밴드, B&A 프리뷰 링크 카드) 셀렉터로,
   기존에 .btn의 margin-top:24px에 암묵적으로 의존하던 곳 — 값 변경 없이 명시적으로 고정해
   회귀를 방지. 문맥별 spacing token 정리는 2차 작업으로 이월 */
.collection-cta-band .btn,
.craft-cta .btn,
.stores-cta .btn,
.ba-link-copy .btn {
  margin-top: 24px;
}

/* ─── 17. 탭 / 칩 ─── */
.tabs {
  display: flex;
  gap: 8px;
  overflow-x: auto;
  overflow-y: hidden;
  padding: 18px 20px;  /* --space-5 갱신에 따른 리터럴 고정 — 값 불변 */
  border-bottom: 1px solid var(--line);
  position: sticky;
  top: var(--header-height-mobile);
  z-index: 50;
  background: rgba(251, 247, 241, .95);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
}
.tabs::-webkit-scrollbar { display: none; }
.tabs { -ms-overflow-style: none; scrollbar-width: none; }

.tab {
  flex-shrink: 0;
  white-space: nowrap;
  height: 40px;
  min-height: 40px;
  padding: 0 16px;
  border: 1px solid var(--line);
  border-radius: var(--radius-pill);
  font-size: var(--text-xs);  /* 14px */
  color: var(--muted);
  transition: background var(--duration-fast), color var(--duration-fast), border-color var(--duration-fast);
}
.tab.active { background: var(--brown); color: #fff; border-color: var(--brown); }


/* ─── 20. 제품 카드 ─── */
.product { border: 1px solid var(--line); background: var(--surface-color); margin-bottom: 16px; overflow: hidden; }
.product .ph {
  height: 260px;
  background: linear-gradient(135deg, #f5eee4, #c9b79f);
  position: relative;
}
.product .ph::after {
  content: attr(data-label);
  position: absolute;
  left: 16px; bottom: 14px;
  font-family: var(--sans);
  color: #fff;
  font-size: var(--text-xs);  /* 14px */
  letter-spacing: .14em;
  text-shadow: 0 2px 10px rgba(0, 0, 0, .28);
}
.product-info { padding: 20px; }
.price { font-size: 15px; letter-spacing: .1em; color: var(--gold); text-transform: uppercase; margin-top: 14px; }
.product-grid { display: grid; gap: 16px; }
.product-info .tags { display: flex; gap: 6px; flex-wrap: wrap; margin: 14px 0 0; }
.product-info .tags span {
  border: 1px solid rgba(168, 135, 93, .26);
  color: #826644;
  font-size: 15px;
  letter-spacing: .07em;
  padding: 6px 10px;
  text-transform: uppercase;
}




/* ─── 22. 비포 & 애프터 ─── */
.ba {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 8px;
  padding: 8px;
  border: 1px solid var(--line-gold);
  background: rgba(255, 255, 255, .4);
}
.ba-panel       { min-height: 300px; background: linear-gradient(135deg, #eee4d7, #c9b497); position: relative; }
.ba-panel.after { background: linear-gradient(135deg, #f7efe3, #b99150); }
.ba-panel::after {
  content: attr(data-label);
  position: absolute;
  left: 14px; bottom: 14px;
  color: #fff;
  font-family: var(--sans);
  font-size: var(--text-xs);  /* 14px */
  letter-spacing: .14em;
}


/* ─── 23. 매장 ─── */
.search-input {
  width: 100%;
  height: 52px;
  border: 0;
  border-bottom: 1px solid var(--line);
  background: transparent;
  outline: none;
  font-family: var(--sans);
  font-size: 20px;
}
.region-tabs { display: flex; gap: 8px; overflow-x: auto; margin-top: 16px; -ms-overflow-style: none; scrollbar-width: none; }
.region-tabs::-webkit-scrollbar { display: none; }
.region-tabs button {
  white-space: nowrap;
  height: 38px;
  min-height: 38px;
  padding: 0 14px;
  border: 1px solid var(--line);
  border-radius: var(--radius-pill);
  font-size: var(--text-xs);  /* 14px */
  color: var(--muted);
  transition: background var(--duration-fast), color var(--duration-fast);
}
.region-tabs button.active { background: var(--brown); color: #fff; border-color: var(--brown); }

.store-card {
  border: 1px solid var(--line);
  background: var(--surface-color);
  padding: 22px;
  transition: transform var(--duration) var(--ease), box-shadow var(--duration) var(--ease), border-color var(--duration);
}
.store-card:hover { transform: translateY(-2px); box-shadow: var(--shadow-card); border-color: var(--line-gold); }
.store-card small {
  display: block;
  margin-bottom: 10px;
  font-family: var(--sans);
  font-size: var(--text-xs);  /* 14px */
  letter-spacing: .14em;
  color: var(--gold);
  text-transform: uppercase;
}
.store-actions { display: flex; gap: 14px; flex-wrap: wrap; margin-top: 14px; }
.store-actions a { font-family: var(--sans); color: #5b4128; font-size: var(--text-xs); }


/* ─── 24. 폼 ─── */
.form { display: grid; gap: 18px; }

.field, .form-field { /* 래퍼 */ }
.field label,
.form-field label {
  display: block;
  font-size: var(--text-xs);  /* 14px */
  letter-spacing: .14em;
  color: #806f5e;
  margin-bottom: 8px;
  text-transform: uppercase;
}
.field input,
.field select,
.field textarea,
.input {
  width: 100%;
  height: 52px;
  border: 0;
  border-bottom: 1px solid var(--line);
  background: transparent;
  outline: none;
  font-size: var(--text-base);  /* 16px */
  transition: border-color var(--duration-fast);
}
.field input:focus,
.field select:focus,
.input:focus { border-color: var(--gold); }
.field textarea,
textarea.input { height: 100px; resize: none; padding-top: 10px; }
.field-hint { margin: 8px 0 0; font-size: 13px; line-height: 1.5; color: var(--muted); }
.agree { display: flex; gap: 10px; font-size: var(--text-xs); line-height: 1.6; color: var(--muted); }


/* ─── 26. 컬렉션 ─── */
.collection-intro-card {
  margin-top: 24px;
}
.collection-intro-card b { display: block; font-family: var(--sans); font-weight: 600; margin-bottom: 10px; }

.collection-section-title {
  margin: 0 0 20px;
  font-family: var(--sans);
  font-weight: 600;
  font-size: var(--font-subtitle);
  line-height: 1.25;
}
.collection-section-title small {
  display: block;
  font-family: var(--sans);
  font-size: var(--text-xs);  /* 14px */
  letter-spacing: .14em;
  color: var(--gold);
  margin-bottom: 10px;
  text-transform: uppercase;
}
.collection-group:first-child .collection-section-title { margin-top: 0; }


/* ─── 27. 푸터 ─── */
/* 상단(브랜드+링크)과 하단(SNS+Copyright) 두 그룹, 경계에 구분선 하나만.
   Mobile 기준 여백: 상단 32 / 좌우 20 / 하단 24, 영역 사이 20px */
.footer { background: var(--ink); color: #eee5da; padding: 32px 20px 24px; }
.footer-inner { max-width: var(--container-wide); margin: 0 auto; }  /* 사이트 본문 container(1200px)와 통일 */

.footer .logo { justify-content: flex-start; }
.footer .logo img { filter: invert(1) brightness(1.85); height: 24px; width: auto; }
.footer p { color: rgba(255, 255, 255, .56); margin: 8px 0 0; font-size: 15px; }

/* 링크: + 기호·개별 구분선 없이 2열×2행 텍스트 링크만 사용(Mobile/Tablet 공통, Desktop만 한 줄로 재배치) */
.foot-links {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 14px 20px;
  margin-top: 20px;
}
.foot-links button, .foot-links a {
  padding: 0;
  border: none;
  background: none;
  text-align: left;
  color: #eee5da;
  font-size: var(--text-base);
}
/* 개인정보처리방침: 다른 푸터 링크와 시각적으로 구별(개인정보위 작성지침) — 굵기+색상 강조, 구조는 동일 */
.foot-link-privacy { font-weight: 600; color: #fff; }

/* 상단(브랜드+링크) → 하단(Copyright+SNS): 구분선은 이 경계 하나만 사용.
   Mobile은 SNS가 위, Copyright가 아래로 보이도록 column-reverse(DOM 순서는 copy→social 그대로 유지) */
.footer-bottom {
  display: flex;
  flex-direction: column-reverse;
  gap: 12px;
  margin-top: 20px;
  padding-top: 20px;
  border-top: 1px solid rgba(255, 255, 255, .12);
}
.footer-copy {
  margin: 0;
  color: rgba(255, 255, 255, .52);
  font-size: 15px;
  line-height: 1.7;
  text-align: left;
}

/* SNS 아이콘: 문자 링크 대신 inline SVG — 기본색은 보조 텍스트 색상, hover 시 gold 통일 */
.footer-social { display: flex; align-items: center; justify-content: flex-end; gap: 14px; }
.footer-social a {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 40px;
  height: 40px;
  color: rgba(255, 255, 255, .56);
}
.footer-social a svg { width: 22px; height: 22px; }
.footer-social a:hover { color: var(--gold); }


/* ─── 28. 스티키 CTA ─── */
.sticky {
  position: fixed;
  left: 50%;
  bottom: 20px;
  transform: translateX(-50%) translateY(130%);
  width: min(440px, calc(100vw - 32px));
  height: 52px;
  background: rgba(25, 20, 15, .92);
  color: #fff;
  z-index: 90;
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 0 20px;
  border: 1px solid rgba(199, 170, 114, .26);
  border-radius: var(--radius-sm);
  transition: transform var(--duration) var(--ease);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
}
.sticky.show { transform: translateX(-50%) translateY(0); }
.sticky > span { font-size: var(--text-xs); letter-spacing: .06em; }


/* ─── 30. 유틸리티 ─── */
.sr-only  { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0,0,0,0); border: 0; }
