/* ==========================================================
   TEMPLATE 09 — RUSTIC KRAFT
   Kraft paper, twine, postmarks, snapshots, chalkboard.
   Bootstrap hanya untuk grid & utility.
   ========================================================== */

:root {
  --kraft: #C9A77C;
  --kraft-d: #A8845A;
  --cream: #F5EEDD;
  --white: #FBF7EC;
  --ink: #3B2A1E;
  --chalk: #2E2A27;
  --red: #B5412F;
  --blue: #3E5C76;
  --lav: #8B7BA8;
  --twine: #B89B6A;

  --f-display: 'Amatic SC', 'Arial Narrow', sans-serif;
  --f-type: 'Special Elite', 'Courier New', monospace;
  --f-hand: 'Caveat', 'Segoe Script', cursive;

  --col: 480px;
  --vh: 100svh;
  --pad: 1.5rem;
  --ease: cubic-bezier(.2, .7, .2, 1);
  --airmail: repeating-linear-gradient(-45deg, var(--red) 0 12px, var(--white) 12px 24px, var(--blue) 24px 36px, var(--white) 36px 48px);
}

html { scrollbar-gutter: stable; background: #6F5438; }
body { margin: 0; font-family: var(--f-type); font-size: .9rem; line-height: 1.7; color: var(--ink); background: #6F5438 url(../assets/textures/kraft.svg); -webkit-font-smoothing: antialiased; overflow-x: hidden; }
body.is-locked { overflow: hidden; height: var(--vh); }
img { max-width: 100%; display: block; }
a { color: inherit; text-decoration: none; }
h1, h2, h3, p, figure { margin: 0; font-weight: inherit; }
button { font: inherit; color: inherit; }
::selection { background: var(--red); color: var(--white); }

.invite { position: relative; width: min(100%, var(--col)); margin-inline: auto; background: var(--kraft); overflow: hidden; container-type: inline-size; box-shadow: 0 0 70px rgba(30, 18, 8, .6); }
.fixed-col { position: fixed; top: 0; bottom: 0; left: 50%; width: min(100%, var(--col)); margin-left: calc(min(100%, var(--col)) / -2); }
@media (min-width: 992px) {
  .invite { margin-right: 0; }
  .fixed-col { left: auto; right: 0; margin-left: 0; }
}

/* ---------- shared ---------- */
.sec { position: relative; padding: 4rem var(--pad) 5.4rem; overflow: hidden; isolation: isolate; text-align: center; }
.sec > *:not(.deco):not(.torn):not(.airmail) { position: relative; z-index: 2; }
.s-kraft { background: var(--kraft) url(../assets/textures/kraft.svg); }
.s-cream { background: var(--cream) url(../assets/textures/paper.svg); }
.s-chalk { background: var(--chalk) radial-gradient(120% 80% at 30% 20%, rgba(255, 255, 255, .07), transparent 60%); color: #E9E4DA; }
.s-cork { background: #B58A5C url(../assets/textures/kraft.svg); background-size: 260px; }
.deco { position: absolute; pointer-events: none; user-select: none; z-index: 0; max-width: none; translate: 0 var(--py, 0px); }
.torn { position: absolute; left: 0; bottom: -1px; width: 100%; height: 22px; z-index: 3; max-width: none; pointer-events: none; }
.airmail { position: absolute; inset: 0; z-index: 1; pointer-events: none; border: 9px solid transparent; border-image: var(--airmail) 9; }

.type { font-size: .72rem; letter-spacing: .2em; text-transform: lowercase; }
.s-kraft .type, .s-cork .type { color: #5A4028; }
.s-chalk .type { color: #CFC8B8; }
.ttl-k { font-family: var(--f-display); font-weight: 700; font-size: clamp(3.4rem, 16.5cqw, 4.4rem); line-height: 1; letter-spacing: .04em; color: var(--white); text-shadow: 2px 2px 0 rgba(59, 42, 30, .25); margin-top: .1rem; }
.ttl-k--ink { color: var(--ink); text-shadow: none; }
.s-cork .ttl-k { color: var(--white); }
.hand { font-family: var(--f-hand); font-weight: 500; font-size: 1.4rem; line-height: 1.3; }
.note-k { max-width: 33ch; margin: .7rem auto 0; font-size: .86rem; }

.btn-k { display: inline-flex; align-items: center; gap: .7rem; padding: .85rem 1.4rem .7rem; border: 2px dashed var(--ink); border-radius: 4px; background: var(--white); font-family: var(--f-type); font-size: .8rem; letter-spacing: .12em; text-transform: uppercase; color: var(--ink); box-shadow: 3px 4px 0 rgba(59, 42, 30, .28); cursor: pointer; transition: transform .3s var(--ease), box-shadow .3s; }
.btn-k i { color: var(--red); }
.btn-k:hover { color: var(--ink); transform: translate(2px, 3px) rotate(-1deg); box-shadow: 1px 1px 0 rgba(59, 42, 30, .28); }
.btn-k--chalk { background: transparent; border-color: #E9E4DA; color: #E9E4DA; box-shadow: none; }
.btn-k--chalk i { color: #F1B9A8; }
.btn-k--chalk:hover { color: #fff; }
.lnk-k { display: inline-flex; align-items: center; gap: .4rem; padding: 0; border: 0; border-bottom: 1.5px dashed currentColor; background: none; font-size: .76rem; color: var(--white); cursor: pointer; }
.lnk-k--ink { color: var(--red); }

/* snapshot */
.snap { position: relative; display: block; padding: 8px 8px 0; background: var(--white); box-shadow: 0 14px 22px -12px rgba(40, 24, 10, .6), 0 0 0 1px rgba(59, 42, 30, .08); }
.snap > img:not(.peg-pin):not(.clip):not(.deco) { width: 100%; aspect-ratio: 1; object-fit: cover; filter: sepia(.28) saturate(.82) contrast(1.02); }
.snap figcaption, .snap > span:not(.tape) { display: block; padding: .15rem 0 .35rem; font-family: var(--f-hand); font-size: 1.2rem; line-height: 1.2; text-align: center; color: var(--ink); }
.snap--sm { padding: 6px 6px 0; }
.snap--sm figcaption { font-size: 1rem; }
.tape { position: absolute; z-index: 3; left: 50%; top: -13px; width: 96px; height: 26px; margin-left: -48px; background: rgba(233, 222, 190, .82); box-shadow: 0 2px 4px rgba(40, 24, 10, .15); rotate: -3deg; clip-path: polygon(0 0, 3% 50%, 0 100%, 100% 100%, 97% 50%, 100% 0); }

@keyframes sway { 0%, 100% { rotate: var(--r, -3deg); } 50% { rotate: calc(var(--r, -3deg) + 2.4deg); } }

/* ---------- reveal ---------- */
[data-reveal] { transition: opacity 1s ease, transform 1.2s var(--ease); transition-delay: var(--d, 0s); }
[data-reveal]:not(.is-in) { opacity: 0; transform: translateY(24px); }
[data-reveal="fade"]:not(.is-in) { transform: none; }
[data-reveal="tilt"]:not(.is-in) { transform: translateY(34px) rotate(7deg) scale(.96); }

/* ==========================================================
   COVER — envelope
   ========================================================== */
.cover { z-index: 1000; overflow: hidden; container-type: size; background: var(--kraft) url(../assets/textures/kraft.svg); transition: transform 1.3s cubic-bezier(.7, 0, .3, 1) .7s; perspective: 1400px; }
.cover-flap { position: absolute; left: 0; right: 0; top: 0; height: 40%; z-index: 0; background: #BE9A6C url(../assets/textures/kraft.svg); clip-path: polygon(0 0, 100% 0, 50% 100%); filter: drop-shadow(0 6px 6px rgba(40, 24, 10, .35)); transform-origin: 50% 0; transition: transform .9s var(--ease); }
.cover.is-opening { transform: translateY(104%); pointer-events: none; }
.cover.is-opening .cover-flap { transform: rotateX(-170deg); }
.cover-body { position: relative; z-index: 3; height: 100%; display: flex; flex-direction: column; align-items: center; justify-content: flex-end; padding: 2rem 1.8rem clamp(2rem, 7cqh, 4rem); text-align: center; }
.cover-top { position: absolute; top: 26px; right: 26px; left: 26px; height: 150px; }
.stamp { position: absolute; right: 0; top: 0; width: 104px; padding: 7px 7px 2px; background: var(--white); rotate: 4deg; box-shadow: 0 6px 10px -6px rgba(40, 24, 10, .5); }
.stamp::after { content: ""; position: absolute; inset: -5px; border: 8px dotted #C4A277; pointer-events: none; }
.stamp img { width: 100%; aspect-ratio: 3 / 3.6; object-fit: cover; filter: sepia(.35) saturate(.8); }
.stamp span { display: block; font-size: .56rem; letter-spacing: .1em; line-height: 1.8; color: var(--red); }
.cover-postmark { position: absolute; right: 64px; top: 34px; width: 190px; rotate: -8deg; z-index: 2; }
.cover-names { font-family: var(--f-display); font-weight: 700; font-size: clamp(4.4rem, 22cqw, 6rem); line-height: .95; color: var(--white); text-shadow: 3px 3px 0 rgba(59, 42, 30, .28); margin-top: .2rem; }
.cover-names span, .hero-names span, .side-names span { color: var(--red); text-shadow: none; }
.cover-underline { width: 190px; margin: .2rem auto 0; }
.addr { width: 100%; max-width: 290px; margin-top: clamp(.9rem, 3cqh, 1.6rem); padding: .8rem 1rem .7rem; background: var(--white) url(../assets/textures/paper.svg); text-align: left; box-shadow: 0 10px 16px -10px rgba(40, 24, 10, .6); rotate: -1.2deg; display: flex; flex-direction: column; }
.addr span { font-size: .68rem; }
.addr strong { font-family: var(--f-hand); font-weight: 600; font-size: 1.7rem; line-height: 1.15; border-bottom: 1px dashed var(--ink); }
.cover .btn-k { margin-top: clamp(1rem, 3cqh, 1.6rem); }
.cover-lav { width: 34%; left: -6%; bottom: 18%; rotate: -24deg; z-index: 4; }
.cv { animation: cvIn 1.2s var(--ease) both; animation-delay: calc(.3s + var(--i) * .13s); }
@keyframes cvIn { from { opacity: 0; transform: translateY(18px); } }

/* ==========================================================
   HERO
   ========================================================== */
.hero { padding-top: 3.6rem; }
.hero-names { font-family: var(--f-display); font-weight: 700; font-size: clamp(5rem, 25cqw, 6.8rem); line-height: .95; color: var(--white); text-shadow: 3px 3px 0 rgba(59, 42, 30, .28); }
.hero-underline { width: 210px; margin: .1rem auto 0; }
.hero-snap { width: 74%; margin: 3rem auto 0; padding: 10px 10px 0; --r: -3deg; rotate: -3deg; }
.hero-snap > img.kenburns-wrap { aspect-ratio: 4 / 4.6 !important; }
.hero-snap figcaption { font-size: 1.5rem; padding: .2rem 0 .5rem; }
.hero-lav { width: 42%; right: -27%; bottom: -6%; rotate: 18deg; z-index: 3; }
.hero-postmark { width: 62%; left: -24%; top: 6%; rotate: -14deg; z-index: 3; }
.hero-hand { display: flex; justify-content: center; align-items: flex-start; gap: .4rem; margin: 1.6rem 0 0 14%; color: var(--white); font-size: 1.6rem; rotate: -4deg; }
.hero-hand img { width: 70px; margin-top: .6rem; }
.hero-date { display: flex; align-items: center; justify-content: center; gap: .9rem; margin-top: .9rem; }
.hero-date span { font-size: .7rem; letter-spacing: .14em; text-transform: lowercase; }
.hero-date strong { padding: .3rem .9rem .1rem; border: 2px solid var(--ink); font-weight: 400; font-size: 1.1rem; letter-spacing: .1em; }

/* ==========================================================
   QUOTE
   ========================================================== */
.quote { padding-inline: 2.2rem; }
.quote-wreath { position: absolute !important; z-index: 0 !important; width: 260px; left: 50%; top: 2.2rem; margin-left: -130px; opacity: .22; }
.quote blockquote { margin: 3.4rem 0 3rem; font-size: clamp(1.9rem, 9cqw, 2.3rem); line-height: 1.2; color: var(--ink); }
.quote-verse { margin-bottom: 1rem; font-size: .86rem; text-align: left; }
.quote-verse::first-letter { font-size: 1.6rem; }

/* ==========================================================
   COUPLE — clothesline
   ========================================================== */
.line { display: grid; grid-template-columns: 1fr auto 1fr; gap: .4rem; align-items: start; margin: 2.2rem -.3rem 0; padding-top: 34px; }
.line-rope, .string::before { content: ""; position: absolute; left: -2rem; right: -2rem; top: 20px; height: 8px; background: url(../assets/ornaments/twine.svg) 0 0 / 48px 8px; filter: drop-shadow(0 3px 2px rgba(40, 24, 10, .3)); }
.peg { --r: -4deg; rotate: var(--r); transform-origin: 50% -20px; animation: sway 7s ease-in-out infinite; }
.peg--alt { --r: 3deg; animation-duration: 9s; margin-top: 1.2rem; }
.peg-pin { position: absolute; z-index: 3; left: 50%; top: -38px; width: 20px; margin-left: -10px; }
.line .snap > img:not(.peg-pin) { aspect-ratio: 4 / 5; }
.line .snap figcaption { font-size: 1.6rem; }
.line-heart { width: 34px; margin-top: 5.4rem; }
.who { margin-top: 1.6rem; }
.who > div { padding: 0 .6rem; }
.who h3 { font-family: var(--f-display); font-weight: 700; font-size: 2.2rem; line-height: 1.05; color: var(--white); text-shadow: 2px 2px 0 rgba(59, 42, 30, .25); }
.who p { margin: .3rem 0 .6rem; font-size: .76rem; line-height: 1.6; }

/* ==========================================================
   EVENT — postcards
   ========================================================== */
.pc { position: relative; max-width: 340px; margin: 2.2rem auto 0; padding: 1.5rem 1.3rem 1.4rem; background: var(--white) url(../assets/textures/paper.svg); text-align: left; box-shadow: 0 20px 28px -16px rgba(40, 24, 10, .55); rotate: -1.6deg; }
.pc--alt { rotate: 1.6deg; }
.pc > *:not(.airmail) { position: relative; z-index: 2; }
.pc-top { height: 74px; }
.pc-top .type { font-size: .6rem; }
.pc-stamp { position: absolute; right: 0; top: 0; width: 54px; rotate: 4deg; box-shadow: 0 0 0 1px rgba(59, 42, 30, .15); }
.pc-mark { position: absolute; right: 34px; top: 4px; width: 132px; rotate: -8deg; }
.pc h3 { font-size: 3.2rem; margin-top: -.6rem; }
.pc-cols { display: grid; grid-template-columns: 1fr 1fr; gap: .9rem; margin: .5rem 0 .9rem; }
.pc-cols .hand { font-size: 1.22rem; line-height: 1.3; color: var(--blue); }
.pc-addr { padding-left: .9rem; border-left: 1.5px solid var(--ink); font-size: .7rem; line-height: 1.9; background: repeating-linear-gradient(transparent 0 calc(1.9em - 1px), rgba(59, 42, 30, .3) calc(1.9em - 1px) 1.9em); }
.pc-addr span { display: block; }
.pc-addr b { display: block; font-weight: 400; }

/* ==========================================================
   COUNTDOWN — chalkboard + calendar pads
   ========================================================== */
.count-wreath { position: absolute !important; z-index: 0 !important; width: 280px; left: 50%; top: 1rem; margin-left: -140px; opacity: .2; }
.pads { display: grid; grid-template-columns: repeat(4, 1fr); gap: .5rem; margin: 1.6rem 0 2rem; }
.pad { position: relative; padding: 1.3rem 0 .5rem; background: var(--white); color: var(--ink); box-shadow: 0 3px 0 #D9CDB4, 0 6px 0 #C9BCA0, 0 14px 16px -8px rgba(0, 0, 0, .6); }
.pad::before { content: ""; position: absolute; left: 0; right: 0; top: 0; height: 14px; background: var(--red) radial-gradient(circle, var(--chalk) 2.5px, transparent 3px) 0 2px / 16px 10px; }
.pad:nth-child(even)::before { background-color: var(--blue); }
.pad strong { display: block; font-family: var(--f-display); font-weight: 700; font-size: clamp(2.6rem, 13cqw, 3.4rem); line-height: 1; }
.pad span { font-size: .62rem; letter-spacing: .1em; }

/* ==========================================================
   STORY — journal
   ========================================================== */
.journal { margin-top: 2rem; padding: 1.6rem 1.1rem 1.4rem 2.4rem; text-align: left; background: var(--white) repeating-linear-gradient(transparent 0 27px, rgba(62, 92, 118, .3) 27px 28px); box-shadow: 0 22px 30px -18px rgba(40, 24, 10, .6); border-radius: 3px; }
.journal::before { content: ""; position: absolute; left: 1.7rem; top: 0; bottom: 0; border-left: 1.5px solid rgba(181, 65, 47, .5); }
.journal-holes { position: absolute; left: .55rem; top: 0; bottom: 0; width: 12px; background: radial-gradient(circle, var(--kraft-d) 5px, transparent 5.5px) 0 14px / 12px 56px; }
.entry { display: grid; grid-template-columns: 40% 1fr; gap: 1rem; align-items: center; padding: .9rem 0; }
.entry--alt { grid-template-columns: 1fr 40%; }
.entry--alt .snap { order: 2; rotate: 3deg; }
.entry .snap { rotate: -3deg; padding-bottom: 6px; }
.clip { position: absolute; z-index: 3; left: 10px; top: -16px; width: 16px; }
.entry-year { font-family: var(--f-display); font-weight: 700; font-size: 2.6rem; line-height: 1; color: var(--red); }
.entry h3 { font-family: var(--f-hand); font-weight: 600; font-size: 1.4rem; line-height: 1.1; color: var(--blue); margin-bottom: .2rem; }
.entry p { font-size: .74rem; line-height: 28px; }

/* ==========================================================
   GALLERY — on twine
   ========================================================== */
.string { position: relative; display: grid; grid-template-columns: repeat(3, 1fr); gap: .7rem; margin: 2rem -.4rem 0; padding-top: 34px; }
.string::before { left: -2rem; right: -2rem; }
.string .peg:nth-child(2) { --r: 2deg; margin-top: .9rem; animation-duration: 9s; }
.string .peg:nth-child(3) { --r: -2deg; animation-duration: 8s; }
.string .snap { padding: 5px 5px 0; }
.string .snap > span { font-size: 1.05rem; }
.ph { cursor: zoom-in; }
.wide { margin: 2.6rem auto 1rem; width: 88%; rotate: 2deg; }
.wide > img { aspect-ratio: 16 / 10 !important; }

/* ==========================================================
   VIDEO
   ========================================================== */
.slate { position: relative; display: block; width: 100%; margin: 1.6rem 0 1.2rem; padding: 12px; border: 0; background: #7A5A38 url(../assets/textures/kraft.svg); box-shadow: 0 22px 30px -16px #000, inset 0 0 0 2px rgba(0, 0, 0, .25); rotate: -1deg; cursor: pointer; }
.slate-img { display: block; aspect-ratio: 16 / 10.5; overflow: hidden; }
.slate-img img { width: 100%; height: 100%; object-fit: cover; filter: sepia(.35) saturate(.8) brightness(.85); transition: transform 2s var(--ease); }
.slate:hover .slate-img img { transform: scale(1.05); }
.slate-play { position: absolute; left: 50%; top: 50%; width: 66px; height: 66px; margin: -33px 0 0 -33px; display: grid; place-items: center; border-radius: 50%; border: 2px dashed var(--white); background: rgba(46, 42, 39, .55); color: var(--white); padding-left: 4px; }
.video .hand { color: #E9E4DA; }

/* ==========================================================
   LIVE
   ========================================================== */
.onair { display: inline-block; margin-bottom: 1rem; padding: 6px; background: #7A5A38 url(../assets/textures/kraft.svg); box-shadow: 0 14px 18px -10px rgba(40, 24, 10, .7); rotate: -3deg; }
.onair span { display: flex; align-items: center; gap: .6rem; padding: .5rem 1.2rem .3rem; background: var(--chalk); font-family: var(--f-display); font-weight: 700; font-size: 2.2rem; line-height: 1; letter-spacing: .14em; text-transform: uppercase; color: #F1B9A8; }
.onair i { width: 12px; height: 12px; border-radius: 50%; background: #E0553F; box-shadow: 0 0 12px #E0553F; animation: blink 1.4s ease-in-out infinite; }
@keyframes blink { 50% { opacity: .2; } }
.live .btn-k { margin-top: 1.4rem; }

/* ==========================================================
   RSVP — reply card
   ========================================================== */
.reply { margin-top: 2.8rem; padding: 2.6rem 1.5rem 1.8rem; text-align: left; background: var(--kraft) url(../assets/textures/kraft.svg); box-shadow: 0 22px 30px -16px rgba(40, 24, 10, .6); border-radius: 3px; rotate: -.8deg; }
.reply::before { content: ""; position: absolute; inset: 9px; border: 1.5px dashed rgba(59, 42, 30, .55); pointer-events: none; }
.reply-bow { position: absolute; left: 50%; top: -44px; width: 120px; margin-left: -60px; z-index: 3; }
.reply > form, .reply > .rsvp-done { position: relative; z-index: 2; }
.lbl { display: block; margin-bottom: .2rem; font-size: .74rem; letter-spacing: .06em; }
.fld { width: 100%; padding: .2rem 0; border: 0; border-bottom: 1.5px dotted var(--ink); border-radius: 0; background: transparent; font-family: var(--f-hand); font-weight: 600; font-size: 1.5rem; line-height: 1.3; color: #2A3F55; outline: 0; }
.fld::placeholder { color: rgba(59, 42, 30, .4); font-weight: 500; }
.fld:focus { border-bottom-style: solid; }
.fld.is-invalid { border-bottom: 1.5px solid var(--red); }
textarea.fld { resize: none; padding: .5rem .7rem; border: 1.5px dotted var(--ink); background: rgba(251, 247, 236, .45); font-size: 1.25rem; }
.choice { display: grid; gap: .3rem; }
.choice label { cursor: pointer; }
.choice input { position: absolute; opacity: 0; pointer-events: none; }
.choice span { display: flex; align-items: center; gap: .7rem; font-size: .8rem; }
.choice span::before { content: ""; flex: none; width: 20px; height: 20px; display: grid; place-items: center; border: 1.5px solid var(--ink); background: rgba(251, 247, 236, .6); font-family: var(--f-hand); font-weight: 600; font-size: 1.6rem; line-height: 0; color: var(--red); }
.choice input:checked + span::before { content: "✓"; }
.choice input:focus-visible + span::before { outline: 2px solid var(--red); outline-offset: 2px; }
.stepper { display: flex; align-items: center; gap: .2rem; }
.stepper button { width: 36px; height: 36px; border: 1.5px solid var(--ink); background: rgba(251, 247, 236, .6); font-size: 1.1rem; line-height: 1; }
.stepper button:hover { background: var(--ink); color: var(--white); }
.stepper output { width: 3rem; text-align: center; font-family: var(--f-hand); font-weight: 600; font-size: 2rem; line-height: 1; color: #2A3F55; }
.stepper em { margin-left: .3rem; font-style: normal; font-size: .8rem; }
.rsvp-done { text-align: center; animation: cvIn 1s var(--ease) both; }
.rsvp-done img { width: 50px; margin: 0 auto; }
.rsvp-done .ttl-k { font-size: 3rem; }
.rsvp-done p { margin: .3rem auto 1rem; max-width: 28ch; }

/* ==========================================================
   WISHES — pinned memos
   ========================================================== */
.board { list-style: none; margin: 1.8rem -.2rem 0; padding: 14px 6px 6px; max-height: 520px; overflow-y: auto; display: grid; grid-template-columns: 1fr 1fr; gap: 16px 12px; text-align: left; scrollbar-width: thin; scrollbar-color: var(--ink) transparent; }
.memo { position: relative; padding: 1.3rem .8rem .8rem; background: #F7E9A8; box-shadow: 0 12px 16px -10px rgba(40, 24, 10, .65); rotate: -2deg; align-self: start; }
.memo::before { content: ""; position: absolute; left: 50%; top: -11px; width: 22px; height: 26px; margin-left: -11px; background: url(../assets/icons/pushpin-red.svg) center / contain no-repeat; }
.memo:nth-child(4n + 2) { background: var(--white); rotate: 2deg; margin-top: 1rem; }
.memo:nth-child(4n + 2)::before { background-image: url(../assets/icons/pushpin-blue.svg); }
.memo:nth-child(4n + 3) { background: #E8D5E8; rotate: 1.5deg; }
.memo:nth-child(4n + 4) { background: #D6E6DA; rotate: -1.5deg; margin-top: .6rem; }
.memo:nth-child(4n + 4)::before { background-image: url(../assets/icons/pushpin-blue.svg); }
.memo.is-new { animation: cvIn 1s var(--ease) both; }
.memo-text { font-family: var(--f-hand); font-size: 1.12rem; line-height: 1.25; color: #2A3F55; }
.memo-by { margin-top: .5rem; font-size: .62rem; line-height: 1.5; }
.tg { display: inline-block; padding: 0 .3rem; border: 1px solid currentColor; font-style: normal; font-size: .54rem; color: #4E6B4A; rotate: -3deg; }
.tg--no { color: var(--red); } .tg--maybe { color: #8A6A1E; }

/* ==========================================================
   GIFT — parcel
   ========================================================== */
.parcel { position: relative; max-width: 320px; aspect-ratio: 1.3; margin: 2.2rem auto 0; display: grid; place-items: center; background: var(--kraft) url(../assets/textures/kraft.svg); box-shadow: 0 26px 30px -16px rgba(40, 24, 10, .65), inset 0 0 0 1px rgba(59, 42, 30, .15), inset 0 -14px 20px -10px rgba(59, 42, 30, .3); rotate: 1deg; }
.parcel-twine { position: absolute; background: url(../assets/ornaments/twine.svg) 0 0 / 48px 8px; }
.parcel-twine--h { left: 0; right: 0; top: 24%; height: 8px; }
.parcel-twine--v { top: 0; bottom: 0; left: 18%; width: 8px; background: var(--twine) repeating-linear-gradient(-30deg, transparent 0 5px, #8C7144 5px 6.5px); border-radius: 4px; }
.parcel-bow { position: absolute; left: 18%; top: 24%; width: 100px; margin: -34px 0 0 -46px; z-index: 3; }
.parcel-label { position: relative; z-index: 2; width: 62%; margin: 12% 0 0 16%; padding: .8rem .8rem .7rem; background: var(--white); text-align: center; box-shadow: 0 6px 10px -6px rgba(40, 24, 10, .5); rotate: -2deg; }
.parcel-label .type { font-size: .58rem; }
.parcel-bank { font-family: var(--f-display); font-weight: 700; font-size: 2.6rem; line-height: 1; color: var(--blue); }
.parcel-no { font-size: 1.12rem; letter-spacing: .06em; line-height: 1.4; }
.parcel-label .hand { font-size: 1.15rem; line-height: 1.2; margin-bottom: .2rem; }
.parcel-fragile { position: absolute; right: 5%; top: 8%; padding: .15rem .5rem 0; border: 2px solid var(--red); font-size: .56rem; letter-spacing: .14em; text-transform: uppercase; color: var(--red); rotate: -7deg; }
.send { margin-top: 2.6rem; }
.send .ttl-k { font-size: 3rem; }
.send p { max-width: 30ch; margin: .2rem auto 1.3rem; font-size: .86rem; }

/* ==========================================================
   LOCATION — treasure map
   ========================================================== */
.tmap { position: relative; margin: 2.2rem .4rem 0; padding: 8px; background: var(--white); box-shadow: 0 22px 30px -16px rgba(40, 24, 10, .6); rotate: -1.5deg; }
.tmap > img { width: 100%; aspect-ratio: 4 / 3; object-fit: cover; }
.tmap-venue { position: absolute !important; width: 32%; right: -5%; bottom: -12%; rotate: 6deg; }
.loc { margin-top: 3rem; }
.loc .hand { font-weight: 600; font-size: 2.2rem; color: var(--white); text-shadow: 2px 2px 0 rgba(59, 42, 30, .25); }
.loc p { margin: .2rem 0 1.3rem; font-size: .86rem; }

/* ==========================================================
   CLOSING + FOOTER
   ========================================================== */
.closing { padding: 4.4rem 2.2rem 4rem; }
.closing > *:not(.deco):not(.airmail) { position: relative; z-index: 2; }
.doily { width: 76%; aspect-ratio: 1; margin: 0 auto; }
.doily > img { position: absolute; inset: 0; width: 100%; filter: drop-shadow(0 12px 14px rgba(40, 24, 10, .3)); }
.doily div { position: absolute; inset: 21%; border-radius: 50%; overflow: hidden; }
.doily div img { width: 100%; height: 100%; object-fit: cover; filter: sepia(.28) saturate(.82); }
.closing-title { margin-top: .6rem; font-family: var(--f-display); font-weight: 700; font-size: clamp(5rem, 25cqw, 6.6rem); line-height: 1; color: var(--ink); }
.closing .hand { font-size: 1.6rem; color: var(--red); }
.closing-names { margin-top: 1.4rem; font-family: var(--f-hand); font-weight: 600; font-size: 1.9rem; line-height: 1.15; color: var(--blue); }
.closing-postmark { width: 200px; margin: 1rem auto 0; rotate: -6deg; }
.closing-lav { width: 30%; right: -7%; bottom: 3%; rotate: 20deg; z-index: 2; }

.footer { padding: 2rem var(--pad) 6.6rem; text-align: center; background: var(--kraft-d) url(../assets/textures/kraft.svg); border-top: 3px dashed rgba(59, 42, 30, .5); }
.footer-names { font-family: var(--f-display); font-weight: 700; font-size: 2.6rem; line-height: 1; color: var(--white); }
.footer-credit { margin-top: .6rem; font-size: .66rem; opacity: .75; }

/* ==========================================================
   FLOATING UI
   ========================================================== */
.ui { z-index: 800; pointer-events: none; opacity: 0; transition: opacity 1s ease 1.6s; }
body.is-open .ui { opacity: 1; }
.ui > * { pointer-events: auto; }
.dock { position: absolute; left: 50%; bottom: 14px; translate: -50% 0; display: flex; gap: .1rem; padding: .3rem .4rem; border-radius: 6px; background: var(--white); border: 2px dashed var(--ink); box-shadow: 3px 4px 0 rgba(59, 42, 30, .3); }
.dock a { width: 37px; height: 37px; border-radius: 4px; display: grid; place-items: center; font-size: .8rem; color: #8A7358; transition: background .3s, color .3s; }
.dock a.is-active { background: var(--red); color: var(--white); }
.fab { position: absolute; right: 14px; width: 44px; height: 44px; border-radius: 50%; display: grid; place-items: center; border: 2px dashed var(--ink); background: var(--white); color: var(--red); font-size: .85rem; box-shadow: 3px 4px 0 rgba(59, 42, 30, .3); transition: opacity .4s, transform .5s var(--ease), visibility .4s; }
.fab--music { bottom: 78px; }
.fab--music.is-playing i { animation: spin 5s linear infinite; }
@keyframes spin { to { transform: rotate(360deg); } }
.fab--music:not(.is-playing) { color: #8A7358; }
.fab--top { bottom: 132px; opacity: 0; visibility: hidden; transform: translateY(10px); }
.fab--top.is-show { opacity: 1; visibility: visible; transform: none; }
.toast-inv { position: absolute; left: 50%; bottom: 80px; translate: -50% 0; width: max-content; max-width: 72%; padding: .5rem 1rem .3rem; background: #F7E9A8; color: var(--ink); font-family: var(--f-hand); font-size: 1.2rem; line-height: 1.25; text-align: center; box-shadow: 0 10px 14px -8px rgba(40, 24, 10, .6); rotate: -1.5deg; opacity: 0; transform: translateY(14px); transition: opacity .4s, transform .5s var(--ease); pointer-events: none !important; }
.toast-inv.is-show { opacity: 1; transform: none; }
.grain { display: none; }

/* lightbox */
.lightbox { position: fixed; inset: 0; z-index: 2000; display: flex; align-items: center; justify-content: center; background: rgba(46, 42, 39, .96); opacity: 0; visibility: hidden; transition: opacity .5s, visibility .5s; }
.lightbox.is-open { opacity: 1; visibility: visible; }
.lb-fig { margin: 0; padding: 10px 10px 0; background: var(--white); text-align: center; rotate: -1.5deg; box-shadow: 0 30px 50px -20px #000; }
.lb-media img { max-width: min(80vw, 860px); max-height: 66vh; }
.lb-media iframe { display: block; width: min(88vw, 940px); aspect-ratio: 16 / 9; border: 0; background: #000; }
.lb-fig figcaption { padding: .3rem 0 .5rem; }
.lb-cap { display: block; font-family: var(--f-hand); font-weight: 600; font-size: 1.7rem; line-height: 1.1; color: var(--ink); }
.lb-count { display: block; font-size: .62rem; letter-spacing: .2em; color: var(--red); }
.lb-btn { position: absolute; z-index: 2; width: 44px; height: 44px; border-radius: 50%; border: 2px dashed var(--white); background: transparent; color: var(--white); display: grid; place-items: center; }
.lb-close { top: 16px; right: 16px; }
.lb-prev { left: 10px; top: 50%; translate: 0 -50%; } .lb-next { right: 10px; top: 50%; translate: 0 -50%; }
.lightbox.is-video .lb-prev, .lightbox.is-video .lb-next, .lightbox.is-video figcaption { display: none; }
.lightbox.is-video .lb-fig { rotate: 0deg; padding-bottom: 10px; }

/* desktop side */
.side { position: fixed; left: 0; top: 0; bottom: 0; width: calc(100% - var(--col)); align-items: center; justify-content: center; text-align: center; overflow: hidden; background: var(--kraft) url(../assets/textures/kraft.svg); }
.side .airmail { border-width: 16px; border-image: var(--airmail) 16; }
.side-body { position: relative; z-index: 2; width: min(60vh, 70%); aspect-ratio: 1; display: flex; flex-direction: column; align-items: center; justify-content: center; }
.side-wreath { position: absolute; inset: -12%; width: 124%; max-width: none; opacity: .5; }
.side-body > *:not(.side-wreath) { position: relative; }
.side-names { font-family: var(--f-display); font-weight: 700; font-size: clamp(4rem, 7vw, 7.6rem); line-height: 1; color: var(--white); text-shadow: 3px 3px 0 rgba(59, 42, 30, .28); }
.side-postmark { position: absolute; right: 7%; top: 9%; width: 280px; rotate: -8deg; }
.side-lav { position: absolute; left: 6%; bottom: -4%; width: 22vh; rotate: -16deg; }

@media (max-width: 374px) {
  :root { --pad: 1.2rem; }
  .pc-cols .hand { font-size: 1.1rem; }
  .journal { padding-left: 2.2rem; }
  .memo-text { font-size: 1.04rem; }
  .dock a { width: 34px; height: 34px; }
}
.is-shot .ui { display: none; }
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation: none !important; }
  [data-reveal] { transition-duration: .01s; }
}
