/* LUXE HAUS — 세로 사진 중심 모바일 레이아웃. 색·글꼴·크기는 관리자 '디자인' 화면 설정(CSS 변수)으로 바뀜 */
:root {
  --ink: #111111; --page: #ecebe8; --notice-bg: #111111; --notice-fg: #ffffff;
  --font-body: "Noto Sans KR"; --font-body-ja: "Noto Sans JP"; --font-logo: "Cormorant Garamond"; --font-hero: "Nanum Pen Script";
  --fs-base: 15px; --fs-logo: 25px; --fs-notice: 12.5px; --fs-tab: 15px; --fs-section: 21px; --fs-card: 14px; --fs-price: 16px; --fs-dtitle: 20px;
  --fs-hero1: 60px; --fs-hero2: 40px;
  --ink-2: #555;
  --muted: #8a8a8a;
  --line: #e8e8e8;
  --bg: #fff;
  --soft: #f4f3f1;
  --accent: #8c6a43;
  --kakao: #fee500;
  --appw: 480px;
  --nav-h: 56px;
}
* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0; background: var(--page); color: var(--ink);
  font-family: var(--font-body), "Noto Sans KR", system-ui, -apple-system, sans-serif;
  font-size: var(--fs-base); line-height: 1.6; word-break: keep-all;
  -webkit-tap-highlight-color: transparent;
}
a { color: inherit; text-decoration: none; }
img { display: block; max-width: 100%; }
button { font: inherit; color: inherit; background: none; border: 0; padding: 0; cursor: pointer; }
.app { max-width: var(--appw); margin: 0 auto; min-height: 100vh; background: var(--bg); position: relative; padding-bottom: calc(var(--nav-h) + env(safe-area-inset-bottom)); }
.app.has-cta { padding-bottom: calc(var(--nav-h) + 60px + env(safe-area-inset-bottom)); }
@media (min-width: 520px) { .app { box-shadow: 0 0 40px rgba(0,0,0,.08); } }
.skip { position: absolute; left: -999px; }
.skip:focus { left: 8px; top: 8px; z-index: 50; background: #fff; padding: 6px 10px; }

/* 상단 공지 + 헤더 */
.notice { background: var(--notice-bg); color: var(--notice-fg); font-size: var(--fs-notice); text-align: center; padding: 8px 16px; letter-spacing: -.01em; }
.head { display: flex; align-items: center; justify-content: space-between; height: 56px; padding: 0 16px; }
.logo { display: flex; align-items: baseline; gap: 8px; }
.logo b { font-family: var(--font-logo), "Cormorant Garamond", serif; font-size: var(--fs-logo); font-weight: 600; letter-spacing: .16em; white-space: nowrap; }
.logo small { font-size: 10px; letter-spacing: .28em; color: var(--muted); }
.head-icons { display: flex; gap: 12px; }
.langs { display: flex; gap: 2px; margin-left: auto; margin-right: 10px; }
.langs a { font-size: 11.5px; font-weight: 500; letter-spacing: .06em; color: var(--muted); padding: 4px 5px; border: 1px solid transparent; }
.langs a.on { color: var(--ink); border-color: var(--ink); }
.head-icons a { width: 28px; height: 28px; display: grid; place-items: center; }
.head-icons svg { width: 24px; height: 24px; }

/* 카테고리 탭 — 가로 스크롤, 상단 고정 */
.cats { position: sticky; top: 0; z-index: 20; background: var(--bg); border-bottom: 1px solid var(--line); display: flex; overflow-x: auto; scrollbar-width: none; padding: 0 8px; }
.cats::-webkit-scrollbar { display: none; }
.cats a { flex: none; padding: 12px 10px 11px; font-size: var(--fs-tab); font-weight: 500; color: var(--ink-2); border-bottom: 2px solid transparent; white-space: nowrap; }
.cats a.on { color: var(--ink); border-bottom-color: var(--ink); font-weight: 700; }
.cats a.hl { color: var(--accent); }

/* 세로 슬라이드 (3:4) */
.slider { position: relative; }
.slides { display: flex; overflow-x: auto; scroll-snap-type: x mandatory; scrollbar-width: none; }
.slides::-webkit-scrollbar { display: none; }
.slide { flex: 0 0 100%; scroll-snap-align: start; position: relative; aspect-ratio: 3 / 4; background: var(--soft); }
.slide img { width: 100%; height: 100%; object-fit: cover; }
.slide .cap { position: absolute; left: 22px; right: 22px; bottom: 54px; color: #fff; text-shadow: 0 1px 12px rgba(0,0,0,.25); }
.slide .cap h2 { font-size: 30px; line-height: 1.3; margin: 0 0 8px; font-weight: 700; letter-spacing: -.03em; }
.slide .cap p { margin: 0; font-size: 13px; opacity: .92; }
.slide::after { content: ""; position: absolute; inset: 45% 0 0; background: linear-gradient(transparent, rgba(0,0,0,.5)); pointer-events: none; }
.counter { position: absolute; left: 22px; bottom: 20px; color: #fff; font-size: 13px; letter-spacing: .06em; z-index: 2; }
.dots { display: flex; justify-content: center; gap: 6px; padding: 12px 0 4px; }
.dots i { width: 6px; height: 6px; border-radius: 50%; background: #d4d4d4; }
.dots i.on { background: var(--ink); }

/* 섹션 */
.sec { padding: 34px 0 6px; }
.sec-head { display: flex; align-items: baseline; justify-content: space-between; padding: 0 16px 14px; }
.sec-head h2 { margin: 0; font-size: var(--fs-section); font-weight: 700; letter-spacing: -.03em; }
.sec-head a { font-size: 13px; color: var(--muted); }
.sec-bar { height: 2px; background: var(--line); margin: 18px 16px 0; position: relative; }
.sec-bar::before { content: ""; position: absolute; left: 0; top: 0; width: 48px; height: 2px; background: var(--ink); }

/* 상품 카드 (매물) */
.card { display: block; }
.thumb { position: relative; aspect-ratio: 3 / 4; background: var(--soft); overflow: hidden; }
.thumb img { width: 100%; height: 100%; object-fit: cover; transition: transform .4s; }
.card:active .thumb img { transform: scale(1.02); }
.badges { position: absolute; left: 8px; top: 8px; display: flex; gap: 4px; }
.badge { font-size: 10.5px; font-weight: 700; letter-spacing: .04em; padding: 3px 6px; background: rgba(255,255,255,.92); color: var(--ink); }
.badge.dark { background: var(--ink); color: #fff; }
.badge.sample { background: #c0392b; color: #fff; }
.info { padding: 9px 2px 0; }
.loc { font-size: 11.5px; color: var(--muted); margin: 0 0 2px; }
.ttl { font-size: var(--fs-card); margin: 0 0 4px; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.price { font-size: var(--fs-price); font-weight: 700; margin: 0; letter-spacing: -.02em; }
.spec { font-size: 11.5px; color: var(--muted); margin: 3px 0 0; }

.row { display: flex; gap: 10px; overflow-x: auto; scroll-snap-type: x mandatory; padding: 0 16px; scrollbar-width: none; }
.row::-webkit-scrollbar { display: none; }
.row .card { flex: 0 0 44%; scroll-snap-align: start; }
.grid { display: grid; grid-template-columns: 1fr 1fr; gap: 26px 10px; padding: 0 16px; }
.empty { padding: 40px 16px; text-align: center; color: var(--muted); }

/* 카테고리 페이지 헤드 */
.page-head { padding: 26px 16px 18px; }
.page-head h1 { margin: 0; font-size: 24px; letter-spacing: -.03em; }
.page-head p { margin: 4px 0 0; font-size: 13px; color: var(--muted); }

/* 매물 상세 */
.d-info { padding: 20px 16px 6px; }
.d-info .loc { font-size: 12.5px; }
.d-info h1 { font-size: var(--fs-dtitle); line-height: 1.4; margin: 2px 0 6px; font-weight: 500; letter-spacing: -.02em; }
.d-info .headline { font-size: 14px; color: var(--ink-2); margin: 0 0 14px; }
.d-price { display: flex; align-items: baseline; gap: 10px; border-top: 1px solid var(--ink); padding-top: 14px; }
.d-price b { font-size: 24px; letter-spacing: -.03em; }
.d-price span { font-size: 13px; color: var(--muted); }
.keys { display: grid; grid-template-columns: repeat(3, 1fr); border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); margin: 16px 0 0; }
.keys div { padding: 12px 6px; text-align: center; }
.keys div + div { border-left: 1px solid var(--line); }
.keys dt { font-size: 11px; color: var(--muted); }
.keys dd { margin: 2px 0 0; font-size: 14px; font-weight: 700; }
.d-actions { display: grid; grid-template-columns: 1fr 1.6fr; gap: 8px; padding: 16px; }
.btn { display: flex; align-items: center; justify-content: center; gap: 6px; height: 52px; font-size: 15px; font-weight: 700; border: 1px solid var(--ink); }
.btn.dark { background: var(--ink); color: #fff; }
.btn.kakao { background: var(--kakao); border-color: var(--kakao); color: #191919; }
.note-box { margin: 0 16px; background: var(--soft); padding: 12px 14px; font-size: 13px; text-align: center; color: var(--ink-2); }

.tabs2 { display: grid; grid-template-columns: 1fr 1fr; border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); margin-top: 34px; position: sticky; top: 45px; background: var(--bg); z-index: 10; }
.tabs2 a { text-align: center; padding: 13px 0; font-size: 14px; font-weight: 700; }
.tabs2 a + a { border-left: 1px solid var(--line); }

.story { padding: 30px 22px 10px; text-align: center; }
.story p { font-size: 15px; color: var(--ink-2); margin: 0; }
.stream figure { margin: 22px 0 0; }
.stream figcaption { font-size: 12px; color: var(--muted); text-align: center; padding: 8px 0 0; letter-spacing: .02em; }
.stream img { width: 100%; aspect-ratio: 3 / 4; object-fit: cover; background: var(--soft); }

.legal { padding: 34px 16px 0; }
.legal h2 { font-size: 15px; margin: 0 0 10px; }
.legal table { width: 100%; border-collapse: collapse; font-size: 13px; border-top: 1px solid var(--ink); }
.legal th, .legal td { text-align: left; padding: 9px 6px; border-bottom: 1px solid var(--line); vertical-align: top; }
.legal th { width: 1%; white-space: nowrap; padding-right: 18px; color: var(--muted); font-weight: 400; }

/* 하단 사무소 정보 */
.foot { margin-top: 44px; padding: 26px 16px 30px; background: var(--soft); font-size: 12px; color: var(--muted); line-height: 1.8; }
.foot b { color: var(--ink); font-size: 13px; }
.foot nav { display: flex; gap: 14px; margin-top: 10px; }

/* 상세 하단 상담 바 (주문하기 자리) */
.cta-bar { position: fixed; left: 50%; transform: translateX(-50%); bottom: calc(var(--nav-h) + env(safe-area-inset-bottom)); width: 100%; max-width: var(--appw); height: 60px; display: grid; grid-template-columns: 1fr 1.6fr; z-index: 30; }
.cta-bar a { display: flex; align-items: center; justify-content: center; font-weight: 700; font-size: 15px; }
.cta-bar .call { background: var(--ink); color: #fff; border-right: 1px solid #333; }
.cta-bar .talk { background: var(--kakao); color: #191919; }

/* 하단 내비게이션 */
.nav { position: fixed; left: 50%; transform: translateX(-50%); bottom: 0; width: 100%; max-width: var(--appw); height: calc(var(--nav-h) + env(safe-area-inset-bottom)); padding-bottom: env(safe-area-inset-bottom); background: var(--bg); border-top: 1px solid var(--line); display: grid; grid-template-columns: repeat(5, 1fr); z-index: 30; }
.nav a, .nav button { display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 2px; font-size: 10px; color: var(--ink-2); }
.nav svg { width: 24px; height: 24px; }

/* 오른쪽 플로팅 버튼 */
.float { position: fixed; bottom: calc(var(--nav-h) + 16px + env(safe-area-inset-bottom)); right: max(10px, calc(50% - var(--appw) / 2 + 10px)); display: grid; gap: 6px; z-index: 25; opacity: 0; pointer-events: none; transition: opacity .2s; }
.float.show { opacity: 1; pointer-events: auto; }
.has-cta .float { bottom: calc(var(--nav-h) + 76px + env(safe-area-inset-bottom)); }
.float a, .float button { width: 40px; height: 40px; display: grid; place-items: center; background: #fff; border: 1px solid var(--line); font-size: 10px; font-weight: 700; }
.float .talk { background: var(--kakao); border-color: var(--kakao); }

/* 전체 메뉴 */
.drawer { position: fixed; inset: 0; z-index: 60; display: none; }
.drawer.open { display: block; }
.drawer .dim { position: absolute; inset: 0; background: rgba(0,0,0,.4); }
.drawer .panel { position: absolute; top: 0; bottom: 0; left: max(0px, calc(50% - var(--appw) / 2)); width: min(84%, 400px); background: var(--bg); overflow-y: auto; padding: 18px 20px 40px; }
.drawer h3 { font-size: 12px; letter-spacing: .14em; color: var(--muted); margin: 26px 0 8px; font-weight: 500; }
.drawer ul { list-style: none; margin: 0; padding: 0; }
.drawer li a { display: block; padding: 11px 0; font-size: 17px; border-bottom: 1px solid var(--line); }
.drawer .close { font-size: 26px; line-height: 1; }
.drawer .office { font-size: 12.5px; color: var(--ink-2); line-height: 1.8; }

.note-box.warn { background: #fdecea; color: #a12a1f; margin-top: 8px; }
.legal td.need { color: #c0392b; }
.drawer li a.on { font-weight: 700; }
body.lang-ja { font-family: var(--font-body-ja), "Noto Sans JP", var(--font-body), system-ui, sans-serif; word-break: normal; line-break: strict; overflow-wrap: anywhere; }
body.lang-en .ttl, body.lang-en .d-info h1 { letter-spacing: 0; }

/* 첫 화면 슬라이드 제목 — 필기체, 둘째 줄은 첫 줄의 2/3 크기 */
.slide .cap h2 { font-weight: 400; letter-spacing: 0; line-height: 1.15; margin-bottom: 10px; }
.slide .cap h2 span { display: block; white-space: nowrap; }
.slide .cap h2 { transform-origin: left bottom; }
.slide .cap h2 { font-family: var(--font-hero), cursive; }
.slide .cap .l1 { font-size: var(--fs-hero1); }
.slide .cap .l2 { font-size: var(--fs-hero2); }
.lang-ja .slide .cap .l2 { margin-top: 4px; }

/* 표시사항 표 — 모든 줄 한 줄 고정, 넘치면 … 표시 후 눌러서 펼치기 */
.legal td { width: 100%; max-width: 0; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.legal tr.more { cursor: pointer; }
.legal tr.more td { padding-right: 24px; position: relative; }
.legal tr.more td::after { content: ""; position: absolute; right: 6px; top: 14px; width: 6px; height: 6px; border-right: 1.5px solid var(--muted); border-bottom: 1.5px solid var(--muted); transform: rotate(45deg); transition: transform .2s; }
.legal tr.open td { white-space: normal; overflow: visible; word-break: break-all; }
.legal tr.open td::after { transform: rotate(-135deg); top: 17px; }
.legal tr.more:active { background: var(--soft); }
.legal h2 small { display: block; font-size: .5em; font-weight: 400; color: var(--muted); margin-top: 3px; letter-spacing: 0; }
