:root {
  --bg: #fbf6ef;
  --paper: #fffdf9;
  --ink: #4a4039;
  --sub: #8c7f74;
  --accent: #d99a8b;     /* 살구 */
  --accent-2: #9fb59a;   /* 세이지 */
  --line: #eadfd3;
  --sun: #d0796a;
  --sat: #7f97b5;
  --serif: 'Gowun Batang', 'Nanum Myeongjo', serif;
  --sans: 'Gowun Dodum', -apple-system, 'Apple SD Gothic Neo', 'Malgun Gothic', sans-serif;
}
* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body { margin: 0; background: #efe7dc; color: var(--ink); font-family: var(--sans); line-height: 1.7; word-break: keep-all; }
body.noscroll { overflow: hidden; }
.wrap { max-width: 440px; margin: 0 auto; background: var(--bg); min-height: 100vh; overflow: hidden; box-shadow: 0 0 40px rgba(0,0,0,.06); }
h1, h2 { font-family: var(--serif); font-weight: 700; margin: 0; }
h2 { font-size: 1.35rem; margin-bottom: 1.4rem; }
b { font-weight: 700; }
.eyebrow { font-family: var(--serif); letter-spacing: .32em; font-size: .72rem; color: var(--accent); margin: 0 0 .5rem; }

/* 미리보기 배지 */
.pending { position: sticky; top: 0; z-index: 20; background: #fff3c4; color: #7a5b00; font-size: .78rem; text-align: center; padding: 6px; }

/* 히어로 */
.hero { text-align: center; padding: 56px 28px 40px; background: radial-gradient(circle at 50% 0%, #fde9e1 0, var(--bg) 70%); position: relative; }
.hero h1 { font-size: 1.7rem; line-height: 1.4; margin-bottom: 26px; }
.hero .name { color: var(--accent); }
.cover { border-radius: 200px 200px 18px 18px; overflow: hidden; aspect-ratio: 3/4; margin: 0 auto 26px; max-width: 320px; box-shadow: 0 12px 30px rgba(140,100,80,.15); }
.cover-img { width: 100%; height: 100%; object-fit: cover; display: block; }
.hero-date { font-family: var(--serif); letter-spacing: .08em; margin: 0; }
.hero-place { color: var(--sub); margin: 2px 0 0; }
.scroll-hint { margin-top: 20px; color: var(--accent); font-size: 1.4rem; animation: bob 2s infinite; }
@keyframes bob { 50% { transform: translateY(6px); } }

/* 사진 자리표시 */
.ph { display: flex; flex-direction: column; align-items: center; justify-content: center; width: 100%; height: 100%;
  background: repeating-linear-gradient(45deg, #f6ece2, #f6ece2 10px, #f2e6da 10px, #f2e6da 20px); color: var(--sub); text-align: center; }
.ph span { font-size: 1.6rem; opacity: .7; }
.ph small { font-size: .7rem; line-height: 1.4; margin-top: 4px; }
.ph.ph { display: flex; } /* .cover-img/.tl-img/.g-img 의 display:block 보다 우선 */

/* 공통 섹션 */
.sec { padding: 56px 28px; text-align: center; border-top: 1px solid var(--line); }
.body-text { font-size: .95rem; margin: 0 0 1.2rem; }
.body-text.small { font-size: .85rem; color: var(--sub); }
.parents { font-family: var(--serif); margin-top: 1.6rem; }
.reveal { opacity: 0; transform: translateY(16px); transition: opacity .8s ease, transform .8s ease; }
.reveal.in { opacity: 1; transform: none; }

/* 버튼 */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 4px; padding: 10px 16px; border: 1px solid var(--line);
  background: var(--paper); color: var(--ink); border-radius: 999px; font: inherit; font-size: .88rem; cursor: pointer; text-decoration: none; min-height: 44px; }
.btn.sm { padding: 6px 12px; font-size: .8rem; min-height: 36px; }
.btn.primary { background: var(--accent); border-color: var(--accent); color: #fff; }
.btn.wide { width: 100%; }
.btn:disabled { opacity: .55; cursor: default; }
.btn.kp { background: #fee500; border-color: #fee500; color: #3c1e1e; }
.btn-row { display: flex; gap: 8px; justify-content: center; flex-wrap: wrap; margin-top: 12px; }

/* 달력 */
.when-big { font-family: var(--serif); font-size: 1.15rem; margin: 0 0 1.4rem; }
.when-month { font-family: var(--serif); color: var(--accent); margin: 0 0 6px; letter-spacing: .1em; }
.cal { width: 100%; max-width: 320px; margin: 0 auto 1rem; border-collapse: collapse; font-size: .88rem; table-layout: fixed; }
.cal th { font-weight: 400; color: var(--sub); padding: 6px 0; font-size: .78rem; }
.cal td { height: 38px; text-align: center; }
.cal .sun { color: var(--sun); } .cal .sat { color: var(--sat); }
.cal td.on span { display: inline-flex; width: 34px; height: 34px; border-radius: 50%; align-items: center; justify-content: center; background: var(--accent); color: #fff; font-weight: 700; }
.dday { font-size: .9rem; margin: 1rem 0 0; }
.chip { display: inline-block; background: var(--accent-2); color: #fff; border-radius: 999px; padding: 0 10px; font-size: .78rem; margin-left: 4px; }

/* 타임라인 */
.tl { list-style: none; margin: 0; padding: 0 0 0 14px; text-align: left; position: relative; }
.tl::before { content: ''; position: absolute; left: 4px; top: 8px; bottom: 8px; width: 2px; background: var(--line); }
.tl-item { position: relative; display: flex; gap: 16px; align-items: center; margin-bottom: 22px; }
.tl-item::before { content: ''; position: absolute; left: -14px; top: 50%; width: 10px; height: 10px; margin-top: -5px; border-radius: 50%; background: var(--accent); }
.tl-photo { flex: 0 0 96px; height: 96px; border-radius: 50%; overflow: hidden; border: 3px solid var(--paper); box-shadow: 0 4px 12px rgba(0,0,0,.08); }
.tl-img { width: 100%; height: 100%; object-fit: cover; display: block; }
.tl-photo .ph small { font-size: .6rem; }
.tl-label { font-family: var(--serif); font-weight: 700; margin: 0; color: var(--accent); }
.tl-date { margin: 0; font-size: .78rem; color: var(--sub); }
.tl-desc { margin: 2px 0 0; font-size: .9rem; }
.tl-hit { position: absolute; inset: 0; background: none; border: 0; cursor: pointer; }

/* 갤러리 */
.grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 4px; }
.g-cell { aspect-ratio: 1; overflow: hidden; border-radius: 6px; padding: 0; border: 0; background: none; cursor: pointer; display: block; }
div.g-cell { cursor: default; }
.g-img { width: 100%; height: 100%; object-fit: cover; display: block; }

/* 오시는 길 */
.place-name { font-family: var(--serif); font-size: 1.15rem; font-weight: 700; margin: 0; }
.place-name small { font-size: .85rem; color: var(--sub); font-weight: 400; }
.place-addr { font-size: .88rem; color: var(--sub); margin: 4px 0 0; }
.map { position: relative; display: block; margin: 18px -28px 0; height: 200px; background: #f3ece2; overflow: hidden; text-decoration: none; color: var(--ink); }
.map img { width: 100%; height: 100%; object-fit: cover; display: block; }
.map-art { position: absolute; inset: 0;
  background:
    linear-gradient(90deg, transparent 47%, #fff 47%, #fff 53%, transparent 53%),
    linear-gradient(0deg, transparent 58%, #fff 58%, #fff 64%, transparent 64%),
    linear-gradient(120deg, transparent 30%, #fffaf3 30%, #fffaf3 33%, transparent 33%),
    repeating-linear-gradient(0deg, #efe6da 0 38px, #f3ece2 38px 76px); }
.map-pin { position: absolute; left: 50%; top: 42%; transform: translate(-50%, -100%); font-size: 2.2rem; filter: drop-shadow(0 4px 4px rgba(0,0,0,.2)); }
.map-cap { position: absolute; left: 50%; bottom: 14px; transform: translateX(-50%); background: rgba(255,253,249,.95); border: 1px solid var(--line);
  border-radius: 999px; padding: 6px 14px; font-size: .8rem; white-space: nowrap; }
.nav-row { display: grid; grid-template-columns: repeat(3, 1fr); border-bottom: 1px solid var(--line); margin: 0 -28px; }
.nav { padding: 13px 0; text-decoration: none; color: var(--ink); font-size: .85rem; background: var(--paper); border-right: 1px solid var(--line); }
.nav:last-child { border-right: 0; }
.nav::before { content: ''; display: inline-block; width: 8px; height: 8px; border-radius: 2px; margin-right: 6px; vertical-align: middle; }
.nav.naver::before { background: #03c75a; } .nav.kakao::before { background: #fee500; } .nav.tmap::before { background: #ef3e5c; }
.transport { list-style: none; padding: 0; margin: 22px 0 0; text-align: left; }
.transport li { display: flex; gap: 12px; padding: 12px 0; border-bottom: 1px dashed var(--line); }
.transport li:last-child { border-bottom: 0; }
.tr-ic { font-size: 1.2rem; }
.transport b { font-size: .9rem; }
.transport p { margin: 2px 0 0; font-size: .85rem; color: var(--sub); }

/* 연락처 */
.contacts { list-style: none; padding: 0; margin: 0 auto; max-width: 300px; }
.contacts li { display: flex; align-items: center; gap: 10px; padding: 12px 0; border-bottom: 1px solid var(--line); }
.c-role { color: var(--sub); font-size: .85rem; width: 36px; text-align: left; }
.c-name { flex: 1; text-align: left; font-family: var(--serif); }
.ic { display: inline-flex; width: 40px; height: 40px; align-items: center; justify-content: center; border-radius: 50%; background: var(--paper); border: 1px solid var(--line); text-decoration: none; }

/* 계좌 */
.acc { background: var(--paper); border: 1px solid var(--line); border-radius: 12px; margin-bottom: 10px; text-align: left; overflow: hidden; }
.acc summary { padding: 14px 16px; cursor: pointer; font-family: var(--serif); list-style: none; display: flex; justify-content: space-between; }
.acc summary::-webkit-details-marker { display: none; }
.acc summary::after { content: '⌄'; color: var(--sub); transition: transform .2s; }
.acc[open] summary::after { transform: rotate(180deg); }
.acc ul { list-style: none; padding: 0 16px 8px; margin: 0; }
.acc li { display: flex; justify-content: space-between; align-items: center; gap: 8px; padding: 10px 0; border-top: 1px solid var(--line); }
.a-who { margin: 0; font-size: .85rem; color: var(--sub); }
.a-num { margin: 0; font-size: .92rem; }
.a-btns { display: flex; gap: 6px; flex-shrink: 0; }

/* 마무리 */
.sign { font-family: var(--serif); color: var(--sub); font-size: .9rem; }
.foot { text-align: center; font-size: .72rem; color: var(--sub); padding: 24px 0 40px; letter-spacing: .1em; }

/* 라이트박스 */
.lb { position: fixed; inset: 0; z-index: 50; background: rgba(20,16,14,.94); display: flex; align-items: center; justify-content: center; }
.lb[hidden] { display: none; }
.lb img { max-width: 100%; max-height: 82vh; object-fit: contain; }
.lb button { position: absolute; background: none; border: 0; color: #fff; font-size: 2rem; cursor: pointer; padding: 12px; }
.lb-x { top: 8px; right: 8px; font-size: 1.4rem !important; }
.lb-nav.l { left: 0; } .lb-nav.r { right: 0; }
#lb-count { position: absolute; bottom: 18px; color: #ccc; font-size: .8rem; margin: 0; }

/* 토스트 */
.toast { position: fixed; left: 50%; bottom: 32px; transform: translate(-50%, 20px); background: rgba(60,50,44,.92); color: #fff;
  padding: 10px 18px; border-radius: 999px; font-size: .85rem; opacity: 0; pointer-events: none; transition: .3s; z-index: 60; white-space: nowrap; }
.toast.show { opacity: 1; transform: translate(-50%, 0); }

@media (prefers-reduced-motion: reduce) { .scroll-hint { animation: none; } .reveal { transition: none; } }
