/* 오디행 공통 화면 부품 — 모든 페이지에서 tokens.css 다음에 불러온다 */

body { background: var(--surface); }
.wrap { max-width: 1120px; margin: 0 auto; padding: 0 24px; }
.wrap.narrow { max-width: 760px; }
.muted { color: var(--muted); }
.center { text-align: center; }
.hidden { display: none !important; }

/* ── 상단 (js/layout.js 가 채움) ── */
.sn { position: sticky; top: 0; z-index: 50; background: rgba(255,255,255,.96); backdrop-filter: blur(8px); border-bottom: 1px solid var(--line); }
.sn-in { max-width: 1120px; margin: 0 auto; padding: 0 24px; height: 78px; display: flex; align-items: center; gap: 32px; }
.sn-logo { font-size: 20px; font-weight: 800; color: var(--ink); letter-spacing: -0.05em; }
.sn-logo b { color: inherit; }
.sn-logo i { display: none; } /* 상단·하단 로고 모두 점 없이 오디행 (2026-12-03 대표) */
.sn .sn-logo { transition: color .2s; }
/* 로고는 오·디·행만 보임. 커서를 올려도 펼쳐지지 않음(2026-12-03 대표). 숨은 글자는 화면 읽기용 */
.sn .sn-logo { position: relative; display: block; line-height: 1.2; flex-shrink: 0; white-space: nowrap; }
.sn-name { display: inline-block; vertical-align: baseline; }
.sn-was { margin-left: 6px; font-size: var(--fs-cap); font-weight: 500; letter-spacing: -0.01em; color: var(--muted); } /* 로고 옆 작은 글씨 (w.겨울과봄사이) (2026-12-04 대표) */
@media (max-width: 480px) { .sn-was { display: block; margin: 1px 0 0; font-size: 10px; } } /* 휴대폰: 로고 아래 줄로 (버튼이 많아도 가로 넘침 없게) */
.sn-name b { font-weight: 800; }
.sn-name s { text-decoration: none; vertical-align: middle; margin: 0; font-size: 0; font-weight: 400; letter-spacing: -0.01em; color: var(--text); opacity: 0; transition: font-size .35s ease, opacity .3s ease, margin .35s ease; }
.sn-name i { display: none; } /* 상단 로고는 점 없이 오디행 (2026-12-03 대표) */
@media (prefers-reduced-motion: reduce) { .sn-name s, .sn-name i { transition: none; } }
.sn-menu { display: flex; gap: 30px; font-size: var(--fs-body-s); font-weight: 700; color: var(--ink); margin-right: auto; }
.sn-menu a:hover, .sn-menu a.cur { color: var(--burgundy); }
/* '클래스 안내'에 커서를 올리면: 지금 신청 가능한 클래스 (버건디 · 얇고 작은 글씨). 목록은 js/layout.js 의 OPEN_CLASSES */
.sn-dd { position: relative; padding: 29px 0; margin: -29px 0; }
.sn-open { position: absolute; top: 100%; left: 50%; padding: 12px 16px 10px; border: 1px solid var(--line); border-radius: 12px; background: var(--surface); box-shadow: 0 10px 24px rgba(28,27,27,.08);
  opacity: 0; visibility: hidden; transform: translate(-50%, -4px); transition: opacity .18s ease, transform .18s ease, visibility .18s; white-space: nowrap; text-align: left; }
.sn-open p { margin: 0 0 4px; font-size: var(--fs-xs); font-weight: 500; color: var(--muted); }
.sn-open a { display: block; padding: 4px 0; font-size: var(--fs-sm); font-weight: 400; color: var(--burgundy); letter-spacing: -0.01em; }
.sn-open a:hover, .sn-open a:focus-visible { text-decoration: underline; text-underline-offset: 3px; }
.sn-dd:hover .sn-open, .sn-dd:focus-within .sn-open { opacity: 1; visibility: visible; transform: translate(-50%, 0); }
@media (prefers-reduced-motion: reduce) { .sn-open { transition: none; } }
/* 메뉴에 커서를 올리면 바로 아래(머리띠 안)에 작은 버건디 글씨로 하위 링크가 스르르 나타남. 상자·그림자 없음. 목록은 js/layout.js 의 SUB */
.sn-sub { position: relative; }
.sn-sub::after { content: ""; position: absolute; left: -12px; right: -12px; top: 100%; height: 30px; } /* 아래로 커서를 옮겨도 사라지지 않게 */
.sn-sub-l { position: absolute; left: 50%; top: calc(100% + 1px); z-index: 1; display: flex; gap: 12px; white-space: nowrap;
  opacity: 0; visibility: hidden; transform: translate(-50%, -4px); transition: opacity .2s ease, transform .2s ease, visibility .2s; }
.sn-sub-l a { font-size: var(--fs-cap); font-weight: 500; color: var(--burgundy); letter-spacing: -0.01em; }
.sn-sub-l a:hover { opacity: .75; } /* 밑줄 없이 살짝 흐려지기만 */
.sn-sub:hover .sn-sub-l, .sn-sub:focus-within .sn-sub-l { opacity: 1; visibility: visible; transform: translate(-50%, 0); }
@media (prefers-reduced-motion: reduce) { .sn-sub-l { transition: none; } }
.sn-btns { display: flex; gap: 8px; align-items: center; margin-left: auto; }
/* 메뉴는 화면 가운데 고정: 왼쪽(로고) · 가운데(메뉴) · 오른쪽(버튼) 3칸, 양옆 칸 너비가 같음 */
@media (min-width: 961px) {
  .sn-in { display: grid; grid-template-columns: 1fr auto 1fr; }
  .sn .sn-logo { justify-self: start; }
  .sn-menu { margin-right: 0; }
  .sn-btns { justify-self: end; }
}
.sn-burger { display: none; width: 40px; height: 40px; border: 0; background: none; font-size: var(--fs-h2); cursor: pointer; color: var(--ink); }
.sn-drawer { display: none; border-top: 1px solid var(--line); padding: 8px 16px 16px; background: var(--surface); }
.sn-drawer a { display: block; padding: 14px 4px; font-size: var(--fs-body); font-weight: 700; color: var(--ink); border-bottom: 1px solid var(--line); }
.sn-drawer.open { display: block; }

/* 회원 메뉴 */
.mn { border-bottom: 1px solid var(--line); background: var(--surface); }
.mn-in { max-width: 1120px; margin: 0 auto; padding: 0 24px; display: flex; gap: 4px; overflow-x: auto; scrollbar-width: none; }
.mn-in::-webkit-scrollbar { display: none; }
.mn a { flex-shrink: 0; height: 48px; display: flex; align-items: center; padding: 0 14px; font-size: var(--fs-body-s); font-weight: 700; color: var(--muted); border-bottom: 2px solid transparent; margin-bottom: -1px; }
.mn a.cur { color: var(--ink); border-bottom-color: var(--burgundy); }
.mn a.out { margin-left: auto; font-weight: 400; }

/* ── 하단 ── */
.sf { background: var(--ink); color: rgba(255,255,255,.55); padding: 40px 0 48px; font-size: var(--fs-cap); line-height: 1.9; margin-top: 96px; }
.sf-in { max-width: 1120px; margin: 0 auto; padding: 0 24px; }
.sf-top { display: flex; justify-content: space-between; align-items: center; gap: 16px; flex-wrap: wrap; padding-bottom: 20px; margin-bottom: 20px; border-bottom: 1px solid rgba(255,255,255,.12); }
.sf-top .sn-logo { color: #fff; font-size: 18px; } /* 검은 바탕 하단 로고는 흰색 */
.sf nav { display: flex; gap: 18px; flex-wrap: wrap; }
.sf nav a:hover { color: #fff; }
.no-foot-gap .sf { margin-top: 0; }

/* ── 페이지 머리 ── */
.ph-head { padding: 56px 0 28px; }
.ph-head .crumbs { font-size: var(--fs-sm); color: var(--muted); margin-bottom: 10px; }
.ph-head .crumbs a:hover { color: var(--ink); }
.ph-head h1 { font-size: clamp(25px, 3.2vw, 33px); font-weight: 800; letter-spacing: -0.04em; line-height: 1.3; color: var(--ink); }
.ph-head p { margin-top: 10px; font-size: var(--fs-body); line-height: 1.7; color: var(--muted); }

.sec { padding: 40px 0; }
.h2 { font-size: var(--fs-h2); font-weight: 800; letter-spacing: -0.03em; color: var(--ink); margin-bottom: 16px; }
.h3 { font-size: var(--fs-h4); font-weight: 800; letter-spacing: -0.02em; color: var(--ink); }
.eyebrow { font-size: var(--fs-sm); font-weight: 700; color: var(--burgundy); margin-bottom: 8px; }
.txt { font-size: var(--fs-body); line-height: 1.8; color: var(--text); }
.txt + .txt { margin-top: 12px; }

/* ── 상자·격자 ── */
.card { border: 1px solid var(--line); border-radius: 18px; padding: 24px; background: var(--surface); }
.card.soft { border: 0; background: var(--bg); }
.card.hl { border: 2px solid var(--burgundy); }
.grid { display: grid; gap: 16px; }
.g2 { grid-template-columns: repeat(2, 1fr); }
.g3 { grid-template-columns: repeat(3, 1fr); }
.g4 { grid-template-columns: repeat(4, 1fr); }
.split { display: grid; grid-template-columns: 1.4fr 1fr; gap: 32px; align-items: start; }
.sticky { position: sticky; top: 102px; }
.row { display: flex; gap: 8px; flex-wrap: wrap; align-items: center; }
.between { display: flex; justify-content: space-between; align-items: center; gap: 12px; }
.stack > * + * { margin-top: 12px; }

.chips { display: flex; gap: 6px; flex-wrap: wrap; }
.chip { font-size: var(--fs-sm); padding: 6px 12px; border-radius: 99px; background: var(--bg); color: var(--text); border: 1px solid transparent; font-family: inherit; cursor: default; }
button.chip { cursor: pointer; }
.chip.on { background: var(--surface); border-color: var(--burgundy); color: var(--burgundy); font-weight: 700; }
.chip.lock { opacity: .5; }

.face { width: 56px; height: 56px; border-radius: 50%; background: var(--g2); display: grid; place-items: center; font-weight: 700; color: var(--g4); flex-shrink: 0; }
.face.lg { width: 120px; height: 120px; font-size: 40px; }
.face.blob { background: var(--bg); }
.face.blob { overflow: hidden; align-items: start; }
.face.blob svg { width: 74%; height: auto; margin-top: 8%; } /* 2026-12-04 대표: 원 안 캐릭터는 모두 상체만 */

.bar { height: 6px; border-radius: 99px; background: var(--line); overflow: hidden; }
.bar i { display: block; height: 100%; background: var(--burgundy); border-radius: 99px; }

.list { list-style: none; padding: 0; margin: 0; }
.list > li { display: flex; justify-content: space-between; align-items: center; gap: 12px; padding: 16px 0; border-bottom: 1px solid var(--line); font-size: var(--fs-body); color: var(--ink); }
.list > li:first-child { border-top: 1px solid var(--line); }
.list small { display: block; font-size: var(--fs-sm); color: var(--muted); }

.price { font-size: var(--fs-h1); font-weight: 800; color: var(--ink); letter-spacing: -0.02em; }
.tag-soon { font-size: var(--fs-xs); font-weight: 700; color: var(--muted); background: var(--bg); padding: 3px 8px; border-radius: 99px; }

/* ── 입력 ── */
.field { display: grid; gap: 6px; }
.field + .field { margin-top: 14px; }
.field label, .lbl { font-size: var(--fs-sm); font-weight: 700; color: var(--ink); }
.input, .field input[type=text], .field input[type=email], .field input[type=tel], .field input[type=password], .field input[type=date], .field select, .field textarea {
  width: 100%; height: 48px; border: 1px solid var(--line); border-radius: 12px; padding: 0 14px;
  font: inherit; font-size: var(--fs-body); color: var(--ink); background: var(--surface);
}
.field textarea { height: 110px; padding: 12px 14px; resize: vertical; }
.field input:focus, .field select:focus, .field textarea:focus { outline: 2px solid var(--burgundy); outline-offset: -1px; border-color: transparent; }
.check { display: flex; gap: 8px; align-items: flex-start; font-size: var(--fs-body-s); color: var(--text); line-height: 1.5; }
.check + .check { margin-top: 10px; }
.check input { margin-top: 3px; accent-color: var(--burgundy); }
.btn-full { width: 100%; }
.note { font-size: var(--fs-sm); color: var(--muted); margin-top: 10px; line-height: 1.6; }

/* ── 탭 ── */
.tabbar { display: flex; gap: 4px; border-bottom: 1px solid var(--line); overflow-x: auto; scrollbar-width: none; margin-bottom: 28px; }
.tabbar::-webkit-scrollbar { display: none; }
.tabbar button, .tabbar a { flex-shrink: 0; height: 48px; padding: 0 14px; border: 0; background: none; font: inherit; font-size: var(--fs-body); font-weight: 700; color: var(--muted); cursor: pointer; border-bottom: 2px solid transparent; margin-bottom: -1px; display: flex; align-items: center; }
.tabbar .on { color: var(--ink); border-bottom-color: var(--burgundy); }

/* ── 표 ── */
.tbl { width: 100%; border-collapse: collapse; font-size: var(--fs-body-s); }
.tbl th { text-align: left; font-size: var(--fs-cap); color: var(--muted); font-weight: 700; padding: 10px 8px; border-bottom: 1px solid var(--line); }
.tbl td { padding: 14px 8px; border-bottom: 1px solid var(--line); color: var(--ink); }
.tbl-wrap { overflow-x: auto; }

/* ── 아코디언 ── */
.acc details { border-bottom: 1px solid var(--line); }
.acc details:first-child { border-top: 1px solid var(--line); }
.acc summary { list-style: none; cursor: pointer; padding: 18px 4px; display: flex; justify-content: space-between; gap: 16px; font-size: var(--fs-body); font-weight: 700; color: var(--ink); }
.acc summary::-webkit-details-marker { display: none; }
.acc summary::after { content: "+"; font-weight: 400; font-size: var(--fs-h2); line-height: 1; color: var(--muted); }
.acc details[open] summary::after { content: "−"; }
.acc .a { padding: 0 4px 20px; font-size: var(--fs-body); line-height: 1.75; color: var(--text); }

/* ── 뼈대 안내 띠 ── */
.draft { background: var(--burgundy-soft); color: var(--burgundy); font-size: var(--fs-cap); font-weight: 600; text-align: center; padding: 8px 16px; }

/* ── 마을 사람 상세 창 (js/people.js) ── */
.sheet-bg { position: fixed; inset: 0; background: rgba(28,27,27,.4); z-index: 80; display: none; align-items: center; justify-content: center; padding: 16px; }
.sheet-bg.open { display: flex; }
.sheet { width: min(520px, 100%); max-height: 86vh; overflow-y: auto; background: var(--surface); border-radius: 24px; padding: 28px; position: relative; }
.sheet .x { position: absolute; right: 16px; top: 16px; width: 36px; height: 36px; border-radius: 50%; border: 0; background: var(--bg); cursor: pointer; font-size: var(--fs-h4); color: var(--ink); }
.sheet .head { display: flex; align-items: center; gap: 14px; }
.sheet h3 { font-size: var(--fs-h3); font-weight: 800; color: var(--ink); letter-spacing: -0.03em; }
.sheet .since { font-size: var(--fs-sm); color: var(--muted); margin-top: 2px; }
.sheet h4 { font-size: var(--fs-sm); font-weight: 700; color: var(--muted); margin: 24px 0 10px; }
.doing { display: grid; gap: 8px; }
.doing > div { padding: 12px 14px; border-radius: 12px; background: var(--bg); font-size: var(--fs-body-s); color: var(--ink); }
.doing .r { display: flex; justify-content: space-between; gap: 12px; }
.doing span { font-size: var(--fs-cap); color: var(--burgundy); font-weight: 700; white-space: nowrap; }
.doing .bar { margin-top: 8px; }
.posts { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; }
.posts figure { margin: 0; }
.posts .ph { aspect-ratio: 1; border-radius: 10px; }
.posts figcaption { font-size: var(--fs-cap); line-height: 1.45; color: var(--text); margin-top: 6px; }
.posts small { display: block; font-size: var(--fs-xs); color: var(--muted); }

/* ── 반응형 ── */
@media (max-width: 960px) {
  .sn-menu { display: none; }
  .sn-burger { display: block; }
  .g4 { grid-template-columns: repeat(2, 1fr); }
  .g3 { grid-template-columns: repeat(2, 1fr); }
}
@media (max-width: 720px) {
  .wrap, .sn-in, .sf-in, .mn-in { padding-left: 16px; padding-right: 16px; }
  .sn-in { height: 64px; justify-content: space-between; gap: 8px; }
  .sn-btns .btn-ghost { display: none; }
  .mn a.out { margin-left: 0; }
  .ph-head { padding: 36px 0 20px; }
  .g2, .g3, .g4, .split { grid-template-columns: 1fr; }
  .sticky { position: static; }
  .sheet-bg { align-items: flex-end; padding: 0; }
  .sheet { border-radius: 24px 24px 0 0; max-height: 88vh; padding: 24px 20px 32px; }
}

/* 오른쪽 아래 문의 버튼 (모든 페이지, 스크롤해도 따라다님): 요리사 캐릭터 + 늘 떠 있는 '문의하기' 말풍선 */
.ask-fab { position: fixed; right: 24px; bottom: 20px; z-index: 70; display: flex; flex-direction: column; align-items: center; }
.ask-fab-tip { position: relative; margin-bottom: 7px; padding: 5px 10px; border-radius: 10px; background: #fff; border: 1px solid var(--line); box-shadow: 0 6px 16px rgba(28,27,27,.12); color: var(--burgundy); font-size: var(--fs-cap); font-weight: 700; white-space: nowrap; transition: background .2s, color .2s, border-color .2s; }
.ask-fab-tip::after { content: ""; position: absolute; left: 50%; bottom: -5px; width: 8px; height: 8px; margin-left: -4px; background: inherit; border-right: 1px solid var(--line); border-bottom: 1px solid var(--line); transform: rotate(45deg); transition: inherit; }
.ask-fab-chef svg { display: block; height: 65px; /* 마을 사람과 같은 크기 (한 칸 약 2.2px) */ width: auto; transform-origin: 50% 100%; animation: fab-hop 3.2s ease-in-out infinite; }
.ask-fab-sh { width: 24px; height: 4px; margin-top: -2px; border-radius: 50%; background: rgba(28,27,27,.14); }
.ask-fab:hover .ask-fab-tip, .ask-fab:focus-visible .ask-fab-tip { background: var(--burgundy); color: #fff; border-color: var(--burgundy); }
.ask-fab:hover .ask-fab-chef svg, .ask-fab:focus-visible .ask-fab-chef svg { animation: none; } /* 커서를 올리면 멈춤 */
@keyframes fab-hop { 0%, 75%, 100% { transform: translateY(0) scale(1, 1); } 80% { transform: translateY(0) scale(1.06, .92); } 88% { transform: translateY(-7px) scale(.96, 1.05); } 95% { transform: translateY(0) scale(1.04, .96); } }
@media (prefers-reduced-motion: reduce) { .ask-fab-chef svg { animation: none; } }
@media (max-width: 720px) {
  .ask-fab { right: 14px; bottom: 14px; }
}
