/* BEIGE MOOD — 시안 C: B의 구조 + A의 분위기 (세리프 로고, 아이보리, 잡지형 컬렉션) */
:root {
  --ivory: #f7f3ec; --paper: #fbf8f3; --beige: #ebe3d6; --line: #e2d9cb; --ink: #151515; --mute: #8a8173;
  --serif: "Cormorant Garamond", "Noto Serif KR", serif; --sans: "Noto Sans KR", system-ui, -apple-system, sans-serif;
  --latin: "Inter", "Helvetica Neue", Arial, sans-serif;
}
* { box-sizing: border-box; margin: 0; padding: 0; }
html, body { background: var(--ivory); color: var(--ink); font-family: var(--sans); font-weight: 300; -webkit-font-smoothing: antialiased; }
a { color: inherit; text-decoration: none; }
button { font: inherit; color: inherit; background: none; border: 0; cursor: pointer; }
img { display: block; width: 100%; height: 100%; object-fit: cover; }
.app { max-width: 480px; margin: 0 auto; min-height: 100vh; }
.caps { font-family: var(--latin); text-transform: uppercase; letter-spacing: .14em; font-size: 10px; font-weight: 500; }

header { position: sticky; top: 0; z-index: 10; background: rgba(247,243,236,.96); backdrop-filter: blur(8px);
  display: grid; grid-template-columns: 44px 1fr 44px; align-items: center; height: 54px; padding: 0 6px; }
.logo { white-space: nowrap; font-family: var(--serif); font-size: 19px; letter-spacing: .3em; padding-left: .3em; text-align: center; font-weight: 500; }
.icon { width: 44px; height: 44px; display: grid; place-items: center; }
.icon svg { width: 20px; height: 20px; }
.drop { display: flex; justify-content: space-between; align-items: center; padding: 8px 16px; border-top: 1px solid var(--line); border-bottom: 1px solid var(--line);
  background: var(--ivory); position: sticky; top: 54px; z-index: 9; }
.drop b { font-weight: 500; font-variant-numeric: tabular-nums; color: var(--ink); }
.drop span:first-child { color: var(--mute); }

.ph { width: 100%; height: 100%; background: var(--beige); display: grid; place-items: center; font-family: var(--serif); color: var(--mute); letter-spacing: .3em; font-size: 12px; }

/* 첫 화면: 큰 사진은 화면 절반 */
.hero { position: relative; height: 50svh; min-height: 300px; max-height: 460px; overflow: hidden; background: var(--beige); display: block; }
.hero::after { content: ""; position: absolute; inset: auto 0 0 0; height: 45%; background: linear-gradient(to top, rgba(247,243,236,.92), rgba(247,243,236,0)); }
.hero .over { z-index: 1; position: absolute; left: 16px; right: 16px; bottom: 16px; display: flex; justify-content: space-between; align-items: flex-end; gap: 12px; }
.hero h1 { font-family: var(--serif); font-weight: 400; font-size: 30px; line-height: 1; letter-spacing: .02em; }
.hero p { font-size: 11.5px; margin-top: 6px; color: #4a443c; }
.hero .go { border-bottom: 1px solid; padding-bottom: 2px; white-space: nowrap; }

.cats { display: grid; grid-template-columns: repeat(5, 1fr); border-bottom: 1px solid var(--line); background: var(--ivory); }
.cats a { text-align: center; padding: 15px 0; font-size: 12.5px; border-right: 1px solid var(--line); color: #3a352e; }
.cats a:last-child { border-right: 0; }

.sec { display: flex; justify-content: space-between; align-items: baseline; padding: 30px 16px 14px; gap: 12px; }
.sec h2 { font-family: var(--serif); font-weight: 400; font-size: 24px; letter-spacing: .02em; }
.sec h2 small { font-family: var(--sans); font-size: 11px; color: var(--mute); margin-left: 8px; letter-spacing: .04em; }
.sec a { color: var(--mute); white-space: nowrap; }

.grid { display: grid; grid-template-columns: 1fr 1fr; gap: 1px; }
.grid.one { grid-template-columns: 1fr; }
.card { display: block; padding-bottom: 22px; background: var(--ivory); }
.card .img { position: relative; aspect-ratio: 4/5; overflow: hidden; background: var(--beige); }
.card .meta { padding: 10px 12px 0; }
.card .name { font-size: 12px; line-height: 1.45; color: #2a2620; }
.card .price { font-size: 10.5px; color: var(--mute); margin-top: 3px; font-family: var(--latin); letter-spacing: .02em; }
.card .price s { margin-right: 6px; }
.new { position: absolute; top: 10px; left: 10px; background: var(--ivory); padding: 3px 6px 2px; font-size: 9px; }
.card.sold .img img { filter: grayscale(.4) opacity(.55); }
.sold-label { position: absolute; inset: 0; display: grid; place-items: center; white-space: nowrap; font-family: var(--serif); font-size: 15px; letter-spacing: .22em; padding-left: .22em; }
.empty { grid-column: 1/-1; text-align: center; color: var(--mute); font-size: 12.5px; padding: 60px 16px; background: var(--ivory); line-height: 1.8; }

/* 컬렉션: 잡지형 문구 */
.edit { margin-top: 40px; background: var(--paper); border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); display: block; }
.edit .txt { text-align: center; padding: 40px 24px 28px; }
.eyebrow { font-size: 10.5px; letter-spacing: .28em; color: var(--mute); text-transform: uppercase; }
.edit h3, .coll-head h1 { font-family: var(--serif); font-weight: 400; font-style: italic; font-size: 40px; line-height: 1.05; margin: 12px 0 12px; }
.edit p, .coll-head p { font-size: 13px; color: #5c554b; line-height: 1.8; white-space: pre-line; }
.link { display: inline-block; margin-top: 18px; font-size: 11.5px; letter-spacing: .2em; border-bottom: 1px solid var(--ink); padding-bottom: 4px; }
.edit .pair { display: grid; grid-template-columns: 1fr 1fr; gap: 1px; }
.edit .pair > div { aspect-ratio: 4/5; overflow: hidden; background: var(--beige); }
.coll-head { text-align: center; padding: 40px 24px 32px; background: var(--paper); border-bottom: 1px solid var(--line); }
.coll-cover { aspect-ratio: 4/5; max-height: 60svh; width: 100%; overflow: hidden; background: var(--beige); }

footer { margin-top: 56px; padding: 30px 16px 34px; border-top: 1px solid var(--line); text-align: center; }
footer .logo { font-size: 15px; }
footer .row { display: flex; justify-content: center; gap: 22px; margin: 16px 0 12px; font-size: 12px; }
footer p { font-size: 10.5px; color: var(--mute); line-height: 1.8; }

/* 카테고리 */
.ptitle { display: flex; justify-content: space-between; align-items: baseline; padding: 24px 16px 4px; }
.ptitle h1 { font-family: var(--serif); font-weight: 400; font-size: 32px; letter-spacing: .03em; }
.tabs { display: flex; gap: 20px; overflow-x: auto; padding: 14px 16px 0; scrollbar-width: none; border-bottom: 1px solid var(--line); }
.tabs::-webkit-scrollbar { display: none; }
.tabs a { font-size: 13px; white-space: nowrap; color: var(--mute); padding-bottom: 12px; }
.tabs a.on { color: var(--ink); font-weight: 500; box-shadow: inset 0 -1px 0 var(--ink); }
.tools { display: flex; justify-content: space-between; align-items: center; padding: 12px 16px; border-bottom: 1px solid var(--line); }
.tools .r { display: flex; gap: 16px; align-items: center; }
.toggle { display: flex; align-items: center; gap: 8px; }
.sw { width: 28px; height: 16px; border-radius: 9px; background: var(--line); position: relative; transition: .2s; }
.sw::after { content: ""; position: absolute; top: 2px; left: 2px; width: 12px; height: 12px; border-radius: 50%; background: #fff; transition: .2s; }
.toggle.on .sw { background: var(--ink); }
.toggle.on .sw::after { left: 14px; }
.view { display: flex; gap: 6px; }
.view i { display: block; width: 14px; height: 14px; border: 1px solid var(--mute); }
.view i.two { background: linear-gradient(90deg, transparent 6px, var(--mute) 6px, var(--mute) 7px, transparent 7px); }
.view button.on i { border-color: var(--ink); }

/* 상품 상세 */
.gallery { display: flex; overflow-x: auto; scroll-snap-type: x mandatory; scrollbar-width: none; aspect-ratio: 4/5; background: var(--beige); }
.gallery::-webkit-scrollbar { display: none; }
.gallery > div { flex: 0 0 100%; scroll-snap-align: start; position: relative; }
.info { padding: 22px 16px 0; }
.info .code { color: var(--mute); }
.info h1 { font-family: var(--serif); font-weight: 400; font-size: 28px; line-height: 1.25; margin: 10px 0 8px; }
.info .price { font-family: var(--latin); font-size: 12.5px; color: #3a352e; }
.info .price s { color: var(--mute); margin-right: 8px; }
.opt { margin-top: 24px; }
.opt .caps { color: var(--mute); margin-bottom: 10px; }
.opt .caps b { color: var(--ink); font-weight: 500; margin-left: 6px; font-family: var(--sans); letter-spacing: 0; text-transform: none; }
.chips { display: flex; flex-wrap: wrap; gap: 6px; }
.chip { height: 38px; min-width: 48px; padding: 0 12px; border: 1px solid var(--line); font-size: 12px; display: inline-flex; align-items: center; justify-content: center; gap: 8px; background: var(--paper); }
.chip.on { border-color: var(--ink); }
.chip.x { color: #c3bdb3; text-decoration: line-through; background: none; }
.chip .dot { width: 12px; height: 12px; border-radius: 50%; border: 1px solid var(--line); }
.desc { margin-top: 26px; font-size: 13px; line-height: 1.9; color: #3a352e; white-space: pre-line; }
.rows { margin-top: 26px; border-top: 1px solid var(--line); }
.rows details { border-bottom: 1px solid var(--line); }
.rows summary { list-style: none; display: flex; justify-content: space-between; padding: 16px 0; font-size: 12.5px; cursor: pointer; }
.rows summary::-webkit-details-marker { display: none; }
.rows summary::after { content: "+"; }
.rows details[open] summary::after { content: "−"; }
.rows p { font-size: 12.5px; line-height: 1.85; color: #5c554b; padding-bottom: 16px; white-space: pre-line; }
.more { padding: 44px 0 170px; }
.more .sec { padding-top: 0; }

.bar { position: fixed; left: 50%; transform: translateX(-50%); bottom: 0; width: 100%; max-width: 480px; z-index: 20;
  background: rgba(247,243,236,.97); backdrop-filter: blur(8px); border-top: 1px solid var(--line); padding: 10px 12px calc(10px + env(safe-area-inset-bottom));
  display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }
.bar .main { grid-column: 1/-1; height: 50px; background: var(--ink); color: var(--ivory); font-size: 13px; letter-spacing: .12em; display: grid; place-items: center; }
.bar .main.sold { background: #6d665c; }
.bar .sub-btn { height: 42px; border: 1px solid var(--ink); font-size: 12px; letter-spacing: .04em; display: grid; place-items: center; }

.loading { padding: 120px 0; text-align: center; font-family: var(--serif); letter-spacing: .3em; color: var(--mute); }

#toast { position: fixed; left: 50%; bottom: 140px; transform: translate(-50%, 10px); opacity: 0; transition: .3s; z-index: 30;
  background: var(--ink); color: var(--ivory); font-size: 12.5px; line-height: 1.6; padding: 12px 16px; width: calc(100% - 32px); max-width: 448px; text-align: center; pointer-events: none; }
#toast.on { opacity: 1; transform: translate(-50%, 0); }
