/* 곁목 가구공방 — N15 인덱스 목록 우선 */
:root {
  --paper: #F2EEE6;
  --paper-2: #E7E0D3;
  --ink: #1E1A16;
  --muted: #6E655A;
  --line: #CBC2B3;
  --walnut: #8A5530;
  --olive: #5E6B3A;
  --serif: 'Noto Serif KR', 'Nanum Myeongjo', serif;
  --sans: 'Pretendard Variable', Pretendard, -apple-system, BlinkMacSystemFont, 'Malgun Gothic', sans-serif;
  --mono: 'Spline Sans Mono', ui-monospace, Menlo, monospace;
  --wrap: 1080px;
}
* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body { margin: 0; background: var(--paper); color: var(--ink); font: 400 16px/1.75 var(--sans); word-break: keep-all; overflow-wrap: break-word; -webkit-font-smoothing: antialiased; }
a { color: inherit; }
img { display: block; max-width: 100%; height: auto; }
h1, h2 { font-family: var(--serif); font-weight: 500; letter-spacing: -0.02em; margin: 0; }

/* 머리 */
.top { position: sticky; top: 0; z-index: 50; display: flex; align-items: center; gap: 28px; max-width: var(--wrap); margin: 0 auto; padding: 14px 24px; background: var(--paper); border-bottom: 1px solid var(--ink); }
.top__name { font: 700 22px/1 var(--serif); text-decoration: none; letter-spacing: -0.03em; }
.top__name small { margin-left: 6px; font: 400 13px/1 var(--sans); color: var(--muted); letter-spacing: 0; }
.top__nav { display: flex; gap: 22px; margin-left: auto; font-size: 14.5px; }
.top__nav a { text-decoration: none; color: var(--muted); }
.top__nav a:hover { color: var(--ink); }
.top__tel { display: inline-flex; align-items: center; gap: 8px; font: 500 15px/1 var(--mono); text-decoration: none; padding: 9px 14px; border: 1px solid var(--ink); border-radius: 2px; }
.top__tel:hover { background: var(--ink); color: var(--paper); }
.dot { width: 7px; height: 7px; border-radius: 50%; background: var(--line); }
.dot.is-open { background: var(--olive); }

/* 첫 화면 = 작업 목록 */
.index { max-width: var(--wrap); margin: 0 auto; padding: 36px 24px 56px; }
.index__head { display: grid; grid-template-columns: 1.1fr 1fr; gap: 40px; align-items: end; margin-bottom: 26px; }
.index h1 { font-size: 34px; line-height: 1.35; }
.index__lede { margin: 0; color: var(--muted); font-size: 15px; max-width: 440px; justify-self: end; }
.filter { display: flex; flex-wrap: wrap; gap: 6px; margin-bottom: 14px; }
.filter button { font: 500 13.5px/1 var(--sans); color: var(--muted); background: none; border: 1px solid var(--line); border-radius: 99px; padding: 8px 14px; cursor: pointer; }
.filter button span { font-family: var(--mono); font-size: 12px; margin-left: 2px; }
.filter button:hover { color: var(--ink); border-color: var(--ink); }
.filter button.is-on { background: var(--ink); border-color: var(--ink); color: var(--paper); }

.list { border-top: 1px solid var(--ink); }
.row { display: block; border-bottom: 1px solid var(--line); text-decoration: none; }
.row > summary, .row--label, a.row { display: grid; grid-template-columns: 64px minmax(0, 1fr) 210px 130px 96px; align-items: baseline; gap: 16px; padding: 15px 0; }
.row > summary { list-style: none; cursor: pointer; }
.row > summary::-webkit-details-marker { display: none; }
.row .no, .row .yr { font: 400 13px/1 var(--mono); color: var(--muted); }
.row .yr { text-align: right; }
.row .name { font: 500 30px/1.25 var(--serif); letter-spacing: -0.03em; transition: transform .25s ease, color .25s ease; }
.row > summary > span:nth-child(3), .row > summary > span:nth-child(4), a.row > span:nth-child(3), a.row > span:nth-child(4) { font-size: 14.5px; color: var(--muted); }
.row--label { padding: 10px 0; font: 400 11.5px/1 var(--mono); letter-spacing: .08em; color: var(--muted); }
.row--label span:last-child { text-align: right; }
.row--label { border-bottom: 1px solid var(--line); }
.row .thumb { display: none; }
.row[hidden] { display: none; }

a.row--contact { background: var(--paper-2); padding-left: 0; }
a.row--contact .no { padding-left: 12px; }
a.row--contact .yr { padding-right: 12px; color: var(--walnut); }
a.row--contact .name { font-size: 22px; font-weight: 700; }
a.row--contact > span:nth-child(3) { font-family: var(--mono); color: var(--ink) !important; }
.row--end { border-bottom: 1px solid var(--ink); }
.row--making .yr { color: var(--olive); }
.row--making .name { color: var(--muted); }

@media (hover: hover) and (pointer: fine) {
  .list:hover .row:not(:hover):not(.row--label) { opacity: .45; }
  .row { transition: opacity .2s ease; }
  .row:hover .name { transform: translateX(10px); color: var(--walnut); }
  a.row--contact:hover { background: var(--ink); color: var(--paper); }
  a.row--contact:hover span { color: var(--paper) !important; }
}
.row[open] .name { color: var(--walnut); }
.note { display: grid; grid-template-columns: 64px minmax(0, 1fr); gap: 16px; padding: 0 0 22px; }
.note img { grid-column: 2; width: 360px; aspect-ratio: 3 / 2; object-fit: cover; }
.note p { grid-column: 2; margin: 0; max-width: 620px; font-size: 15px; color: var(--muted); }
.note em { font-style: normal; color: var(--ink); }
.nowrap { white-space: nowrap; }
.index__foot { margin: 14px 0 0; font: 400 12.5px/1.6 var(--mono); color: var(--muted); }

/* 커서를 따라오는 사진 */
.peek { position: fixed; left: 0; top: 0; z-index: 40; width: 340px; pointer-events: none; opacity: 0; transition: opacity .18s ease; will-change: transform; }
.peek img { width: 100%; aspect-ratio: 3 / 2; object-fit: cover; box-shadow: 0 18px 40px rgba(30, 26, 22, .22); }
.peek.is-on { opacity: 1; }
@media (hover: none), (pointer: coarse) { .peek { display: none; } }

/* 공방 소개 */
.about { max-width: var(--wrap); margin: 0 auto; padding: 56px 24px; display: grid; grid-template-columns: 1.15fr 1fr; gap: 48px; align-items: start; border-top: 1px solid var(--ink); }
.about__pic { margin: 0; }
.about__pic img { width: 100%; aspect-ratio: 3 / 2; object-fit: cover; }
.about h2, .block h2 { font-size: 26px; margin-bottom: 18px; }
.about p { margin: 0 0 14px; }

/* 공통 블록 */
.block { max-width: var(--wrap); margin: 0 auto; padding: 56px 24px; border-top: 1px solid var(--ink); }
.block h2 small { margin-left: 8px; font: 400 12.5px/1 var(--mono); color: var(--walnut); letter-spacing: 0; }
.small { font-size: 14px; color: var(--muted); margin: 14px 0 0; }

.steps { list-style: none; margin: 0; padding: 0; border-top: 1px solid var(--line); }
.steps li { display: grid; grid-template-columns: 64px 200px minmax(0, 1fr) 96px; gap: 16px; align-items: baseline; padding: 18px 0; border-bottom: 1px solid var(--line); }
.steps b { font: 400 13px/1 var(--mono); color: var(--muted); }
.steps .name { font: 500 22px/1.3 var(--serif); }
.steps p { margin: 0; color: var(--muted); font-size: 15px; }
.steps i { font: normal 400 13px/1 var(--mono); color: var(--walnut); text-align: right; }

.price { width: 100%; border-collapse: collapse; font-size: 15px; }
.price th, .price td { text-align: left; padding: 14px 12px 14px 0; border-bottom: 1px solid var(--line); }
.price thead th { font: 400 11.5px/1 var(--mono); letter-spacing: .08em; color: var(--muted); border-bottom: 1px solid var(--ink); }
.price tbody th { font: 500 18px/1.3 var(--serif); }
.price td { font-variant-numeric: tabular-nums; }

.newslist { list-style: none; margin: 0; padding: 0; }
.newslist li { display: grid; grid-template-columns: 140px minmax(0, 1fr); gap: 16px; padding: 14px 0; border-bottom: 1px solid var(--line); }
.newslist time { font: 400 13px/1.9 var(--mono); color: var(--muted); }
.newslist p { margin: 0; }

.visit__grid { display: grid; grid-template-columns: 1.4fr 1fr; gap: 48px; }
.info { margin: 0; }
.info div { display: grid; grid-template-columns: 90px minmax(0, 1fr); gap: 12px; padding: 12px 0; border-bottom: 1px solid var(--line); }
.info dt { font: 400 12.5px/1.9 var(--mono); color: var(--muted); }
.info dd { margin: 0; }
.info a { font-family: var(--mono); }
.copy { margin-left: 6px; font: 500 12px/1 var(--sans); padding: 5px 9px; background: none; border: 1px solid var(--line); border-radius: 99px; cursor: pointer; color: var(--muted); }
.copy:hover { border-color: var(--ink); color: var(--ink); }
.state { margin-left: 6px; font-size: 13px; color: var(--muted); }
.state.is-open { color: var(--olive); font-weight: 600; }
.hours { width: 100%; border-collapse: collapse; align-self: start; }
.hours caption { text-align: left; font: 400 12.5px/1 var(--mono); color: var(--muted); padding: 14px 0 10px; }
.hours th, .hours td { text-align: left; padding: 12px 0; border-bottom: 1px solid var(--line); font-weight: 400; }
.hours th { width: 80px; font-family: var(--serif); font-weight: 500; }
.hours small { margin-left: 6px; color: var(--walnut); font-size: 12.5px; }
.actions { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 22px; }
.btn { display: inline-flex; align-items: center; min-height: 46px; padding: 0 18px; border: 1px solid var(--ink); text-decoration: none; font-size: 15px; font-weight: 600; }
.btn:hover, .btn--dark { background: var(--ink); color: var(--paper); }
.btn--dark:hover { background: var(--walnut); border-color: var(--walnut); }

.foot { max-width: var(--wrap); margin: 0 auto; padding: 32px 24px 48px; border-top: 1px solid var(--ink); font-size: 13px; color: var(--muted); }
.foot p { margin: 0 0 4px; }
.foot b { color: var(--ink); font-weight: 600; }

/* 퀵메뉴: PC 오른쪽 세로 / 모바일 하단 바 */
.quick { position: fixed; z-index: 60; right: 14px; top: 50%; transform: translateY(-50%); display: flex; flex-direction: column; background: var(--ink); color: var(--paper); }
.quick a { display: flex; flex-direction: column; align-items: center; gap: 2px; width: 72px; padding: 11px 4px; text-decoration: none; border-bottom: 1px solid rgba(242, 238, 230, .14); text-align: center; }
.quick a:last-child { border-bottom: 0; }
.quick b { font-size: 13.5px; font-weight: 700; }
.quick span { font: 400 10px/1.2 var(--mono); opacity: .7; word-break: break-all; }
.quick a:hover { background: var(--walnut); }

@media (max-width: 1279px) and (min-width: 1024px) {
  .index, .about, .block, .foot, .top { margin-right: 96px; margin-left: 16px; }
}
@media (max-width: 1023px) {
  .quick { top: auto; bottom: 0; left: 0; right: 0; transform: none; flex-direction: row; padding-bottom: env(safe-area-inset-bottom); }
  .quick a { flex: 1; width: auto; min-height: 56px; justify-content: center; border-bottom: 0; border-right: 1px solid rgba(242, 238, 230, .14); }
  .quick a:last-child { border-right: 0; }
  .quick .quick__top { display: none; }
  .quick a:nth-child(4) { border-right: 0; }
  body { padding-bottom: calc(56px + env(safe-area-inset-bottom)); }
}
@media (max-width: 860px) {
  .top { gap: 12px; padding: 12px 16px; }
  .top__nav { display: none; }
  .top__tel { margin-left: auto; font-size: 14px; padding: 8px 11px; }
  .index { padding: 26px 16px 44px; }
  .index__head { grid-template-columns: 1fr; gap: 12px; margin-bottom: 20px; }
  .index h1 { font-size: 25px; }
  .index__lede { justify-self: start; font-size: 14.5px; }
  .filter { flex-wrap: nowrap; overflow-x: auto; margin: 0 -16px 12px; padding: 0 16px; scrollbar-width: none; }
  .filter button { flex: none; }
  .row--label { display: none !important; }
  .row > summary, a.row { grid-template-columns: 72px minmax(0, 1fr) auto; grid-template-rows: auto auto; gap: 2px 12px; padding: 13px 0; align-items: center; }
  .row .no { grid-column: 1; grid-row: 1 / 3; align-self: center; }
  .row .name { grid-column: 2; grid-row: 1; font-size: 21px; }
  .row .yr { grid-column: 3; grid-row: 1; }
  .row > summary > span:nth-child(3), a.row > span:nth-child(3) { grid-column: 2; grid-row: 2; font-size: 13.5px; }
  .row > summary > span:nth-child(4), a.row > span:nth-child(4) { grid-column: 3; grid-row: 2; font-size: 13px; text-align: right; }
  a.row--contact .name { font-size: 18px; }
  .note { grid-template-columns: 1fr; padding-bottom: 18px; }
  .note img, .note p { grid-column: 1; width: 100%; }
  .about { grid-template-columns: 1fr; gap: 24px; padding: 44px 16px; }
  .block { padding: 44px 16px; }
  .about h2, .block h2 { font-size: 23px; }
  .steps li { grid-template-columns: 40px minmax(0, 1fr) auto; gap: 4px 10px; }
  .steps b { grid-row: 1 / 3; }
  .steps p { grid-column: 2 / 4; }
  .steps i { grid-column: 3; grid-row: 1; }
  .price thead { display: none; }
  .price, .price tbody, .price tr { display: block; }
  .price tr { display: grid; grid-template-columns: 1fr 1fr; gap: 2px 12px; padding: 14px 0; border-bottom: 1px solid var(--line); }
  .price th, .price td { border: 0; padding: 0; }
  .price tbody th { grid-column: 1 / 3; }
  .price td:nth-of-type(1) { grid-column: 1 / 3; font-size: 13.5px; color: var(--muted); }
  .price td:nth-of-type(2)::before { content: '오크·애쉬 '; color: var(--muted); font-size: 13px; }
  .price td:nth-of-type(3)::before { content: '월넛·체리 '; color: var(--muted); font-size: 13px; }
  .newslist li { grid-template-columns: 1fr; gap: 2px; }
  .visit__grid { grid-template-columns: 1fr; gap: 12px; }
  .info div { grid-template-columns: 72px minmax(0, 1fr); }
  .btn { flex: 1 1 calc(50% - 4px); justify-content: center; padding: 0 10px; font-size: 14px; }
  .foot { padding: 28px 16px 32px; }
}
/* 터치 화면에선 썸네일을 항상 보여 준다 */
@media (hover: none), (pointer: coarse), (max-width: 860px) {
  .row .thumb { display: block; grid-column: 1; grid-row: 1 / 3; width: 72px; height: 50px; object-fit: cover; align-self: center; }
  .row:has(.thumb) .no { visibility: hidden; }
}
@media (hover: none) and (min-width: 861px) {
  .row .thumb { grid-row: 1; width: 64px; height: 44px; }
}
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .row .name, .peek { transition: none; }
}
