/* 웨딩 셀렉 화면 스타일 — 종이 위 잉크 느낌, 장식은 줄과 숫자로만 */
:root {
  --paper: #faf9f6; --white: #ffffff; --ink: #1b1a18; --ink2: #4f4b45; --mute: #8f897f; --rule: #e3dfd7; --hi: #f2efe8;
  --sel: #1f6b47; --rej: #b4483a; --rej-bg: #fbeeec;
  --sans: "Pretendard Variable", Pretendard, -apple-system, "Apple SD Gothic Neo", "Noto Sans KR", sans-serif;
}
* { box-sizing: border-box; margin: 0; padding: 0; }
html, body { height: 100%; background: var(--paper); color: var(--ink); font: 15px/1.6 var(--sans); -webkit-font-smoothing: antialiased; letter-spacing: -0.005em; }
body { overflow: hidden; }
.num { font-variant-numeric: tabular-nums; }
.hidden { display: none !important; }

button { font: inherit; color: inherit; cursor: pointer; background: none; border: 0; }
.btn { display: inline-flex; align-items: center; gap: 10px; height: 46px; padding: 0 22px; border-radius: 3px; font-weight: 600; font-size: 15px; transition: background .15s, color .15s, border-color .15s; }
.btn-ink { background: var(--ink); color: var(--paper); }
.btn-ink:hover { background: #000; }
.btn-line { border: 1px solid var(--ink); color: var(--ink); }
.btn-line:hover { background: var(--ink); color: var(--paper); }
.btn:disabled { opacity: .35; cursor: default; }
.txt { color: var(--ink2); font-size: 14px; padding: 6px 2px; border-bottom: 1px solid transparent; }
.txt:hover { color: var(--ink); border-bottom-color: var(--ink); }
.txt:disabled { opacity: .35; cursor: default; border-color: transparent; }
kbd { font: 500 11px/18px var(--sans); padding: 0 5px; border: 1px solid var(--rule); border-radius: 3px; color: var(--mute); background: var(--white); }
input[type=text], input[type=password], input[type=number] { font: inherit; height: 46px; padding: 0 14px; border: 1px solid var(--rule); border-radius: 3px; background: var(--white); color: var(--ink); }
input:focus { outline: none; border-color: var(--ink); }
.eyebrow { font-size: 12px; font-weight: 600; letter-spacing: .14em; text-transform: uppercase; color: var(--mute); }

/* 머리 */
#app { height: 100%; display: flex; flex-direction: column; }
.top { position: relative; display: grid; grid-template-columns: 1fr auto 1fr; align-items: center; gap: 20px; height: 60px; padding: 0 28px; background: var(--paper); border-bottom: 1px solid var(--rule); }
.mark { font-weight: 700; font-size: 13px; letter-spacing: .2em; }
.mark span { font-weight: 400; letter-spacing: 0; color: var(--mute); margin-left: 12px; font-size: 13px; }
.steps { display: flex; gap: 26px; }
.steps div { font-size: 14px; color: var(--mute); cursor: pointer; height: 60px; display: flex; align-items: center; gap: 8px; border-bottom: 2px solid transparent; margin-bottom: -1px; }
.steps div i { font-style: normal; font-size: 12px; font-variant-numeric: tabular-nums; }
.steps div:hover { color: var(--ink2); }
.steps div.on { color: var(--ink); font-weight: 600; border-bottom-color: var(--ink); }
.steps div.done { color: var(--ink2); }
.steps div.done i::after { content: ' ✓'; color: var(--sel); }
.steps small { font-size: 11px; color: var(--sel); font-weight: 600; }
.count { justify-self: end; text-align: right; line-height: 1.2; }
.count b { font-size: 20px; font-variant-numeric: tabular-nums; }
.count span { color: var(--mute); font-size: 13px; }
.count .fee { display: block; font-size: 11px; color: var(--mute); margin-top: 2px; font-variant-numeric: tabular-nums; }
.count .fee.over { color: var(--rej); font-weight: 600; }
.feebox { margin-top: 34px; padding: 18px 0 4px; border-top: 1px solid var(--rule); max-width: 640px; }
.feebox .fh { display: flex; gap: 10px; align-items: baseline; }
.feebox .fh b { font-size: 15px; }
.feebox .fh span { font-size: 12px; color: var(--mute); }
.feebox p { color: var(--ink2); font-size: 13px; line-height: 1.65; margin: 6px 0 12px; }
.feebox .fi { display: flex; gap: 22px; flex-wrap: wrap; }
.feebox label { display: inline-flex; align-items: center; gap: 8px; color: var(--ink2); font-size: 14px; }
.feebox input { width: 110px; height: 40px; text-align: right; font-weight: 600; font-variant-numeric: tabular-nums; }
.page > .feebox + .grid { margin-top: 26px; }
.page > .feebox { margin-top: 0; }
.tally .feesum { font-size: 15px; margin-top: 10px; color: var(--ink2); }
.tally .feesum b { font-size: 15px; margin: 0; }
.tally .feesum b.over { color: var(--rej); font-size: 18px; }
.feesum small { color: var(--mute); font-size: 12px; margin-left: 4px; }
.feesum .note { display: block; margin: 4px 0 0; }
.pace .feeline { font-size: 13px; }
.sug { margin: -6px 0 24px; }
.sug .sh { font-size: 14px; font-weight: 600; margin-bottom: 10px; }
.sug .sh span { font-weight: 400; color: var(--mute); font-size: 13px; margin-left: 6px; }
.sug button { display: flex; align-items: center; gap: 14px; width: 100%; padding: 8px 0; border: 0; border-bottom: 1px solid var(--rule); background: none; cursor: pointer; font: inherit; text-align: left; }
.sug button:hover { background: var(--hi); }
.sug .thumbs { display: flex; gap: 3px; width: 169px; flex: none; }
.sug .thumbs img { width: 40px; height: 40px; object-fit: cover; }
.sug .t { flex: 1; font-size: 14px; }
.sug .m { font-size: 14px; font-weight: 600; color: var(--sel); font-variant-numeric: tabular-nums; padding-right: 4px; }
.count .lic { display: block; font-size: 11px; color: var(--sel); margin-top: 2px; }
.topbar { position: absolute; left: 0; right: 0; bottom: -1px; height: 2px; }
.topbar i { display: block; height: 100%; width: 0; background: var(--ink); transition: width .3s; }
.topbar.over i { background: var(--rej); } .topbar.hit i { background: var(--sel); }

main { flex: 1; min-height: 0; overflow-y: auto; }
.page { max-width: 1200px; margin: 0 auto; padding: 44px 28px 140px; }
h1 { font-size: 34px; line-height: 1.22; font-weight: 700; letter-spacing: -0.025em; }
.sub { color: var(--ink2); margin-top: 10px; max-width: 640px; }

/* 아래 고정 줄 */
.bar { position: sticky; bottom: 0; margin-top: 30px; background: var(--paper); border-top: 1px solid var(--rule); display: flex; align-items: center; gap: 18px; padding: 14px 0; }
.bar .grow { flex: 1; }
.hint { color: var(--mute); font-size: 13px; }

/* 첫 화면 */
.landing { display: grid; grid-template-columns: 1.05fr 1fr; gap: 72px; align-items: start; padding-top: 9vh; }
.landing h1 { font-size: 56px; line-height: 1.08; letter-spacing: -0.035em; margin: 18px 0 20px; }
.landing .sub { font-size: 17px; }
.landing .cta { display: flex; align-items: center; gap: 22px; margin-top: 34px; flex-wrap: wrap; }
.landing .fine { margin-top: 44px; display: grid; gap: 6px; color: var(--mute); font-size: 13px; }
.ledger { border-top: 1px solid var(--ink); margin-top: 6px; }
.ledger > div { display: grid; grid-template-columns: 44px 1fr auto; gap: 16px; padding: 20px 0; border-bottom: 1px solid var(--rule); align-items: baseline; }
.ledger i { font-style: normal; font-size: 13px; color: var(--mute); font-variant-numeric: tabular-nums; }
.ledger b { font-size: 17px; font-weight: 600; display: block; }
.ledger p { color: var(--ink2); font-size: 14px; margin-top: 3px; }
.ledger em { font-style: normal; font-size: 12px; color: var(--mute); white-space: nowrap; }
.ledger em.free { color: var(--sel); font-weight: 600; }

/* 분석 중 */
.working { padding-top: 16vh; max-width: 640px; }
.working .big { font-size: 64px; font-weight: 700; letter-spacing: -0.04em; font-variant-numeric: tabular-nums; margin: 18px 0 6px; }
.working .big span { color: var(--mute); font-weight: 400; }
.line { height: 2px; background: var(--rule); margin: 22px 0 12px; }
.line i { display: block; height: 100%; width: 0; background: var(--ink); transition: width .3s; }

/* 분석 결과 */
.stats { display: grid; grid-template-columns: repeat(4, 1fr); border-top: 1px solid var(--ink); border-bottom: 1px solid var(--rule); margin: 36px 0 34px; }
.stats div { padding: 22px 0; border-right: 1px solid var(--rule); padding-left: 22px; }
.stats div:first-child { padding-left: 0; }
.stats div:last-child { border-right: 0; }
.stats b { display: block; font-size: 40px; font-weight: 700; letter-spacing: -0.03em; font-variant-numeric: tabular-nums; line-height: 1.1; }
.stats span { color: var(--ink2); font-size: 14px; }
.target { display: inline-flex; align-items: center; gap: 10px; color: var(--ink2); font-size: 14px; }
.target input { width: 84px; text-align: center; font-weight: 600; }

/* 1단계 */
.sect { margin-top: 40px; }
.sect h2 { font-size: 19px; font-weight: 700; display: flex; gap: 10px; align-items: baseline; }
.sect h2 span { color: var(--mute); font-weight: 400; font-size: 14px; }
.sect > p { color: var(--ink2); font-size: 14px; margin: 6px 0 18px; max-width: 720px; }
.cards { display: grid; grid-template-columns: repeat(auto-fill, minmax(170px, 1fr)); gap: 14px; }
.cards.wide { grid-template-columns: repeat(auto-fill, minmax(250px, 1fr)); }
.card { position: relative; cursor: pointer; }
.card .im { position: relative; border-radius: 2px; overflow: hidden; background: var(--hi); outline: 2px solid var(--rej); outline-offset: -2px; }
.card .im > img { display: block; width: 100%; aspect-ratio: 2 / 3; object-fit: cover; }
.cards.wide .card .im > img { aspect-ratio: 5 / 3; }
.card .inset { position: absolute; right: 8px; bottom: 8px; width: 48%; aspect-ratio: 1; object-fit: cover; border: 2px solid var(--white); border-radius: 2px; background: #ccc; }
.card .meta { display: flex; justify-content: space-between; align-items: center; margin-top: 8px; font-size: 13px; }
.card .state { font-weight: 600; color: var(--rej); }
.card .zoom { color: var(--mute); font-size: 12px; }
.card .zoom:hover { color: var(--ink); }
.card.keep .im { outline-color: transparent; }
.card.keep .im > img, .card.keep .inset { opacity: .5; }
.card.keep .state { color: var(--ink2); font-weight: 400; }
.none { color: var(--mute); font-size: 14px; padding: 18px 0; border-top: 1px solid var(--rule); }

/* 2단계 */
.scenehead { display: flex; align-items: flex-end; justify-content: space-between; gap: 24px; flex-wrap: wrap; }
.scenehead h1 span { color: var(--mute); font-weight: 400; }
.pace { font-size: 14px; color: var(--ink2); text-align: right; }
.pace b { font-variant-numeric: tabular-nums; }
.pace.warn b, .pace.warn { color: var(--rej); }
.track { height: 2px; background: var(--rule); margin: 18px 0 24px; }
.track i { display: block; height: 100%; background: var(--ink); width: 0; transition: width .3s; }
.grid { display: grid; gap: 10px; }
.ph { position: relative; border-radius: 2px; overflow: hidden; cursor: pointer; background: var(--hi); }
.ph img { width: 100%; height: 100%; object-fit: contain; display: block; }
.ph::after { content: ''; position: absolute; inset: 0; border: 3px solid transparent; pointer-events: none; transition: border-color .1s; }
.ph:hover::after { border-color: rgba(27,26,24,.25); }
.ph.on::after { border-color: var(--sel); }
.ph .ck { position: absolute; left: 0; top: 0; min-width: 30px; height: 30px; padding: 0 8px; display: flex; align-items: center; gap: 6px; background: rgba(250,249,246,.92); color: var(--ink2); font-size: 12px; font-weight: 600; font-variant-numeric: tabular-nums; }
.ph.on .ck { background: var(--sel); color: var(--white); }
.ph.on .ck::after { content: '선택'; }
.ph .mag { position: absolute; right: 0; bottom: 0; height: 30px; padding: 0 12px; display: flex; align-items: center; background: rgba(27,26,24,.75); color: var(--white); font-size: 12px; opacity: 0; transition: opacity .15s; }
.ph:hover .mag { opacity: 1; }
.ph.out img { opacity: .3; }
.ph.out::before { content: '뺌'; position: absolute; left: 0; top: 0; z-index: 1; height: 26px; padding: 0 9px; display: flex; align-items: center; background: var(--rej); color: var(--white); font-size: 12px; font-weight: 600; }

/* 3단계 */
.grid.small { grid-template-columns: repeat(auto-fill, minmax(124px, 1fr)); gap: 8px; }
.grid.small .ph { aspect-ratio: 2 / 3; }
.grid.small .ph img { object-fit: cover; }
.grid.small .ph .ck { display: none; }
.tally { font-size: 18px; margin: 26px 0 22px; padding: 16px 0; border-top: 1px solid var(--ink); border-bottom: 1px solid var(--rule); }
.tally b { font-size: 28px; font-variant-numeric: tabular-nums; margin-right: 4px; }
.ok { color: var(--sel); } .over { color: var(--rej); }

/* 4단계 */
.exports { display: grid; grid-template-columns: 1fr 1fr; gap: 0; border-top: 1px solid var(--ink); margin-top: 34px; }
.exports > div { padding: 28px 28px 28px 0; }
.exports > div + div { border-left: 1px solid var(--rule); padding-left: 28px; }
.exports h2 { font-size: 19px; margin-bottom: 8px; }
.exports p { color: var(--ink2); font-size: 14px; margin-bottom: 18px; }
.prog { height: 2px; background: var(--rule); margin-top: 18px; display: none; }
.prog i { display: block; height: 100%; background: var(--sel); width: 0; }

/* 이용권 */
.modal { position: fixed; inset: 0; background: rgba(27,26,24,.42); display: none; align-items: center; justify-content: center; z-index: 40; padding: 16px; }
.sheet { background: var(--paper); border-radius: 3px; max-width: 480px; width: 100%; padding: 34px; max-height: 92vh; overflow-y: auto; }
.sheet h2 { font-size: 24px; font-weight: 700; letter-spacing: -0.02em; margin: 10px 0 8px; }
.sheet .sub { font-size: 14px; }
.terms { border-top: 1px solid var(--ink); margin: 22px 0; }
.terms div { display: flex; justify-content: space-between; padding: 11px 0; border-bottom: 1px solid var(--rule); font-size: 14px; }
.terms span { color: var(--ink2); }
.terms .price b { font-size: 22px; font-variant-numeric: tabular-nums; }
.terms .price small { color: var(--mute); font-size: 12px; margin-left: 8px; }
.redeem { display: flex; gap: 8px; margin-top: 8px; }
.redeem input { flex: 1; text-transform: uppercase; letter-spacing: .1em; font-weight: 600; }
.err { color: var(--rej); font-size: 13px; min-height: 22px; margin-top: 8px; }
.sheet .notice { color: var(--mute); font-size: 12px; line-height: 1.6; margin: 2px 0 10px; }
.sheet .foot2 { display: flex; justify-content: space-between; align-items: center; margin-top: 6px; }

/* 크게 보기 */
#lb { position: fixed; inset: 0; background: #0f0e0d; display: none; z-index: 20; flex-direction: column; }
#lb .stage { flex: 1; min-height: 0; display: flex; align-items: center; justify-content: center; overflow: hidden; position: relative; }
#lb img { max-width: 100%; max-height: 100%; object-fit: contain; cursor: zoom-in; }
#lb img.z { transform: scale(2.6); cursor: zoom-out; }
#lb .lbbar { display: flex; gap: 22px; justify-content: center; align-items: center; height: 64px; color: #bdb8b0; font-size: 13px; border-top: 1px solid #2a2826; }
#lb .lbbar button { color: #e8e4dc; font-size: 14px; padding: 8px 4px; }
#lb .lbbar button:hover { color: #fff; }
#lb .lbbar .pickbtn { border: 1px solid #5a5650; padding: 9px 18px; border-radius: 3px; }
#lb .lbbar .pickbtn.on { background: var(--sel); border-color: var(--sel); color: #fff; }
#lb .nm { position: absolute; top: 16px; left: 20px; color: #8f897f; font-size: 12px; font-variant-numeric: tabular-nums; }
#lb .x { position: absolute; top: 12px; right: 16px; color: #e8e4dc; font-size: 13px; padding: 6px; }
#lb .nav { position: absolute; top: 0; bottom: 0; width: 12%; display: flex; align-items: center; justify-content: center; color: #fff; font-size: 40px; font-weight: 200; opacity: 0; cursor: pointer; }
#lb .nav:hover { opacity: .6; } #lb .nav.l { left: 0; } #lb .nav.r { right: 0; }

#toast { position: fixed; bottom: 86px; left: 50%; transform: translateX(-50%); background: var(--ink); color: var(--paper); border-radius: 3px; padding: 11px 18px; font-size: 14px; display: none; z-index: 50; }

/* 전체 화면: 머리와 설명을 숨기고 사진을 화면 높이에 맞춤 */
body.full .top, body.full .scenehead .eyebrow, body.full .scenehead .sub, body.full .pace { display: none; }
body.full .page { max-width: none; padding: 14px 20px 0; }
body.full .scenehead h1 { font-size: 18px; }
body.full .track { margin: 8px 0 10px; }
body.full .bar { margin-top: 10px; padding: 10px 0; }
body.full .grid { gap: 8px; }
body.full #toast { bottom: 70px; }

/* 전체 화면 크게 보며 고르기 */
.bigview { height: 100vh; display: flex; flex-direction: column; background: #121110; color: #e8e4dc; }
.bvhead { display: flex; align-items: center; gap: 18px; height: 48px; padding: 0 20px; font-size: 14px; color: #a8a39a; }
.bvhead b { color: #f3efe7; font-size: 15px; } .bvhead b span { color: #8f897f; font-weight: 400; }
.bvhead .txt, .bvbar .txt { color: #cfc9bf; } .bvhead .txt:hover, .bvbar .txt:hover { color: #fff; border-color: #fff; }
.bvhead .grow, .bvbar .grow { flex: 1; }
.bvstage { flex: 1; min-height: 0; position: relative; display: flex; align-items: center; justify-content: center; overflow: hidden; }
.bvstage img { max-width: 100%; max-height: 100%; object-fit: contain; cursor: zoom-in; }
.bvstage img.z { transform: scale(2.6); cursor: zoom-out; }
.bvstage .nav { position: absolute; top: 0; bottom: 0; width: 10%; display: flex; align-items: center; justify-content: center; font-size: 44px; font-weight: 200; color: #fff; opacity: 0; cursor: pointer; }
.bvstage .nav:hover { opacity: .55; } .bvstage .nav.l { left: 0; } .bvstage .nav.r { right: 0; }
.bvpick { position: absolute; left: 20px; top: 14px; height: 40px; padding: 0 16px; border: 1px solid #6a655e; border-radius: 3px; color: #f3efe7; background: rgba(18,17,16,.6); font-weight: 600; }
.bvpick.on { background: var(--sel); border-color: var(--sel); }
.bvstrip { display: flex; gap: 6px; padding: 10px 20px; overflow-x: auto; justify-content: safe center; border-top: 1px solid #2a2826; }
.bvt { position: relative; flex: 0 0 auto; height: 86px; cursor: pointer; opacity: .55; outline: 2px solid transparent; outline-offset: -2px; }
.bvt img { height: 100%; display: block; }
.bvt span { position: absolute; left: 0; top: 0; font-size: 11px; padding: 1px 5px; background: rgba(18,17,16,.7); color: #ddd; }
.bvt:hover { opacity: .85; } .bvt.cur { opacity: 1; outline-color: #f3efe7; }
.bvt.on { outline: 3px solid var(--sel); outline-offset: -3px; } .bvt.on span { background: var(--sel); color: #fff; }
.bvbar { display: flex; align-items: center; gap: 18px; height: 64px; padding: 0 20px; border-top: 1px solid #2a2826; }
.bvbar .hint { color: #8f897f; } .bvbar kbd { background: #1e1c1a; border-color: #3a3734; color: #a8a39a; }
.bvbar .btn-ink { background: #f3efe7; color: #121110; } .bvbar .btn-ink:hover { background: #fff; }
body.full main { overflow: hidden; }

@media (max-width: 900px) {
  .landing { grid-template-columns: 1fr; gap: 40px; padding-top: 4vh; }
  .landing h1 { font-size: 40px; }
  .top { grid-template-columns: auto 1fr; height: auto; padding: 12px 16px; row-gap: 4px; }
  .steps { grid-column: 1 / -1; order: 3; gap: 16px; overflow-x: auto; }
  .steps div { height: 40px; white-space: nowrap; }
  .steps div span { display: none; }
  .page { padding: 28px 16px 140px; }
  h1 { font-size: 26px; }
  .stats { grid-template-columns: repeat(2, 1fr); }
  .stats div:nth-child(3) { padding-left: 0; }
  .exports { grid-template-columns: 1fr; }
  .exports > div + div { border-left: 0; padding-left: 0; border-top: 1px solid var(--rule); }
  .bar .hint { display: none; }
}
