/* ──────────────────────────────────────────────────────────────
   Year of Love — stylesheet
   柔软 · 浪漫 · 复古衬线
   ────────────────────────────────────────────────────────────── */

:root {
  /* —— palette (matched to reference: vivid sky + bubblegum pink + coral) —— */
  --bg-cream:    #F5E9D2;     /* warm cream strip */
  --bg-cream-2:  #FBF3E0;     /* lighter cream for cards/sections */
  --bg-sky:      #7DC3EA;     /* saturated sky blue (matches photo) */
  --bg-sky-pale: #C6E2F2;     /* lighter sky for fades */
  --card:        #FFFCF4;     /* warm card off-white */
  --ink:         #111111;     /* near-black for outlines */
  --ink-soft:    #6B6B6B;
  --pink:        #F2A8C8;     /* bubblegum fill */
  --pink-deep:   #EA8AB4;
  --coral:       #E8554C;     /* swoosh red-coral */
  --cream-line:  #F2E4C9;
  --gold:        #C8A876;
  --gold-soft:   rgba(200,168,118,0.35);
  --line:        rgba(17,17,17,0.10);

  /* —— type —— */
  --serif-en:    "Cormorant Garamond", "Cormorant", "EB Garamond", Georgia, serif;
  --serif-cn:    "Noto Serif SC", "Songti SC", "STSong", "SimSun", serif;
  --sans:        "Inter", "Noto Sans SC", -apple-system, BlinkMacSystemFont, "Segoe UI", system-ui, sans-serif;
  --script:      "Caveat", "Snell Roundhand", cursive;

  /* —— rhythm —— */
  --container:   1200px;
  --pad-x:       clamp(20px, 5vw, 56px);
  --radius-card: 16px;
}

/* ── reset ─────────────────────────────────────────────── */
*,
*::before,
*::after { box-sizing: border-box; }

html, body { margin: 0; padding: 0; }
html { scroll-behavior: smooth; }

body {
  font-family: var(--sans);
  font-size: 17px;
  line-height: 1.65;
  color: var(--ink);
  background: var(--bg-cream);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  text-rendering: optimizeLegibility;
  overflow-x: hidden;
}

img { max-width: 100%; display: block; }

/* ════════════════════════════════════════════════════════
   FALLING HEARTS — site-wide overlay
   ════════════════════════════════════════════════════════ */
.hearts-rain {
  position: fixed;
  inset: 0;
  width: 100vw;
  height: 100vh;
  pointer-events: none;
  overflow: hidden;
  z-index: 2;          /* above content, below nav (nav uses higher z) */
}

.heart {
  position: absolute;
  top: -8vh;
  will-change: transform, opacity;
  animation-name: heart-fall;
  animation-timing-function: linear;
  animation-iteration-count: infinite;
  opacity: 0;
}

.heart svg {
  display: block;
  width: 100%;
  height: 100%;
  filter: drop-shadow(0 2px 4px rgba(232, 85, 76, 0.25));
  animation: heart-sway 3.2s ease-in-out infinite;
}

@keyframes heart-fall {
  0%   { transform: translate3d(0, -8vh, 0) rotate(-8deg); opacity: 0; }
  8%   { opacity: 1; }
  92%  { opacity: 1; }
  100% { transform: translate3d(0, 110vh, 0) rotate(12deg); opacity: 0; }
}

@keyframes heart-sway {
  0%, 100% { margin-left: 0; }
  50%      { margin-left: 22px; }
}

/* gentle reduce-motion fallback */
@media (prefers-reduced-motion: reduce) {
  .hearts-rain { display: none; }
}

a {
  color: inherit;
  text-decoration: none;
  transition: color .25s ease, opacity .25s ease;
}

/* ── shared helpers ────────────────────────────────────── */
.container {
  max-width: var(--container);
  margin: 0 auto;
  padding: 0 var(--pad-x);
}

.eyebrow-en {
  font-family: var(--serif-en);
  font-style: italic;
  font-weight: 600;
  font-size: clamp(44px, 9vw, 120px);
  letter-spacing: -0.015em;
  line-height: 0.95;
  color: var(--pink);
  -webkit-text-stroke: 1.5px var(--ink);
  paint-order: stroke fill;
  filter: drop-shadow(2px 3px 0 var(--ink));
  margin: 0;
  white-space: nowrap;
}

.subtitle-cn {
  font-family: var(--serif-cn);
  font-weight: 500;
  font-size: clamp(15px, 1.4vw, 18px);
  letter-spacing: 0.4em;
  color: var(--ink);
  margin: 14px 0 0;
}

.section-intro {
  font-family: var(--serif-cn);
  font-size: 16px;
  color: var(--ink);
  opacity: 0.7;
  margin: 22px 0 0;
  letter-spacing: 0.06em;
  font-style: italic;
}

.section {
  padding: clamp(72px, 11vh, 120px) 0;
  position: relative;
}

.section-head {
  margin-bottom: clamp(40px, 6vh, 64px);
}

/* ── paper-grain noise overlay (very subtle) ──────────── */
.grain {
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: 1;
  opacity: 0.35;
  mix-blend-mode: multiply;
  background-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' width='240' height='240'><filter id='n'><feTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='2' stitchTiles='stitch'/><feColorMatrix values='0 0 0 0 0.17  0 0 0 0 0.17  0 0 0 0 0.17  0 0 0 0.05 0'/></filter><rect width='100%' height='100%' filter='url(%23n)'/></svg>");
}

/* ════════════════════════════════════════════════════════
   NAV
   ════════════════════════════════════════════════════════ */
.nav {
  position: fixed;
  top: 0; left: 0; right: 0;
  z-index: 50;
  padding: 22px var(--pad-x);
  display: flex;
  align-items: center;
  justify-content: space-between;
  background: transparent;
  transition: background .35s ease, backdrop-filter .35s ease,
              box-shadow .35s ease, padding .35s ease;
}

.nav.scrolled {
  background: rgba(250,247,242,0.78);
  backdrop-filter: saturate(140%) blur(14px);
  -webkit-backdrop-filter: saturate(140%) blur(14px);
  box-shadow: 0 1px 0 rgba(44,44,44,0.04);
  padding-top: 14px;
  padding-bottom: 14px;
}

.nav__monogram {
  font-family: var(--serif-en);
  font-style: italic;
  font-weight: 500;
  font-size: 22px;
  letter-spacing: 0.04em;
  color: var(--ink);
}

.nav__monogram .amp {
  font-family: var(--serif-en);
  font-style: italic;
  color: var(--coral);
  padding: 0 4px;
}

.nav__links {
  display: flex;
  gap: clamp(20px, 4vw, 40px);
}

.nav__link {
  font-family: var(--serif-en);
  font-style: italic;
  font-size: 17px;
  font-weight: 500;
  color: var(--ink);
  position: relative;
  padding: 4px 0;
  white-space: nowrap;
}

.nav__link::after {
  content: '';
  position: absolute;
  left: 0; right: 0; bottom: 0;
  height: 1.5px;
  background: var(--coral);
  transform: scaleX(0);
  transform-origin: left center;
  transition: transform .35s cubic-bezier(.4,0,.2,1);
}

.nav__link:hover::after { transform: scaleX(1); }

/* ════════════════════════════════════════════════════════
   HERO
   ════════════════════════════════════════════════════════ */
.hero {
  position: relative;
  min-height: 100vh;
  display: flex;
  align-items: center;
  padding: 140px var(--pad-x) 100px;
  overflow: hidden;
  background-color: var(--bg-sky);
  background-image:
    /* top fade for nav contrast */
    linear-gradient(180deg,
      rgba(125,195,234,0.15) 0%,
      rgba(125,195,234,0)   18%,
      rgba(125,195,234,0)   72%,
      rgba(245,233,210,0.85) 100%),
    url("assets/sky.jpg");
  background-size: cover, cover;
  background-position: center, center;
  background-repeat: no-repeat, no-repeat;
  isolation: isolate;
}

/* deprecated halos — kept invisible so old markup doesn't break */
.hero__halo { display: none; }

/* —— decorative ribbons —— */
.hero__ribbon {
  position: absolute;
  width: clamp(360px, 46vw, 720px);
  height: auto;
  aspect-ratio: 800 / 460;
  pointer-events: none;
  z-index: 1;
  overflow: visible;
  filter: drop-shadow(2px 3px 0 rgba(17,17,17,0.92));
}

.hero__ribbon--tr {
  top: -2vw;
  right: -8vw;
  transform: rotate(-2deg);
  animation: ribbonFloatA 7s ease-in-out infinite;
}

.hero__ribbon--bl {
  bottom: -3vw;
  left: -8vw;
  transform: rotate(-3deg);
  animation: ribbonFloatB 7s ease-in-out infinite;
  animation-delay: -2.5s;
}

@keyframes ribbonFloatA {
  0%, 100% { transform: rotate(-2deg) translate(0, 0); }
  50%      { transform: rotate(-1deg) translate(-6px, 8px); }
}
@keyframes ribbonFloatB {
  0%, 100% { transform: rotate(-3deg) translate(0, 0); }
  50%      { transform: rotate(-4deg) translate(6px, -8px); }
}

.hero__inner {
  position: relative;
  z-index: 2;
  width: 100%;
  max-width: var(--container);
  margin: 0 auto;
  text-align: center;
}

.hero__title {
  font-family: var(--serif-en);
  font-weight: 600;
  font-style: italic;
  line-height: 0.9;
  letter-spacing: -0.015em;
  margin: 0;
  /* pink fill + thick black stroke + offset shadow → reference look */
  color: var(--pink);
  -webkit-text-stroke: 2px var(--ink);
  paint-order: stroke fill;
  filter: drop-shadow(3px 4px 0 var(--ink));
  /* horizontal layout, centered */
  display: flex;
  align-items: center;
  justify-content: center;
  flex-wrap: nowrap;
  gap: clamp(18px, 3vw, 44px);
}

.hero__title-line {
  display: inline-block;
  font-size: clamp(64px, 13vw, 180px);
  position: relative;
  animation: heroFloat 5s ease-in-out infinite;
  will-change: transform;
}

/* per-line size + slight resting offset + staggered phase */
.hero__title-line:nth-child(1) {
  font-size: clamp(72px, 14vw, 196px);
  margin-top: -8px;
  animation-delay: 0s;
}
.hero__title-line:nth-child(2) {
  font-size: clamp(48px, 9vw, 120px);
  font-style: italic;
  font-weight: 500;
  color: var(--bg-cream-2);
  align-self: center;
  animation-delay: -1.6s;
}
.hero__title-line:nth-child(3) {
  font-size: clamp(72px, 14vw, 196px);
  margin-top: 6px;
  animation-delay: -3.2s;
}

@keyframes heroFloat {
  0%, 100% { transform: translateY(0); }
  50%      { transform: translateY(-10px); }
}

.hero__subtitle {
  margin-top: clamp(12px, 1.6vh, 20px);
  display: flex;
  flex-direction: column;
  gap: 10px;
  align-items: center;
}

.hero__sub-cn {
  font-family: var(--serif-cn);
  font-weight: 500;
  font-size: clamp(18px, 2vw, 22px);
  letter-spacing: 0.45em;
  color: var(--ink);
  padding-left: 0.45em; /* compensate for letter-spacing on right */
  text-align: center;
}

.hero__sub-en {
  font-family: var(--serif-en);
  font-style: italic;
  font-weight: 500;
  font-size: clamp(22px, 2.6vw, 32px);
  color: var(--ink);
  letter-spacing: 0.005em;
  opacity: 0.85;
  line-height: 1.25;
}

.hero__counter {
  margin-top: clamp(18px, 2.4vh, 28px);
  display: flex;
  align-items: baseline;
  justify-content: center;
  gap: 14px;
  flex-wrap: wrap;
  font-family: var(--serif-cn);
  font-size: clamp(18px, 1.8vw, 22px);
  color: var(--ink);
  letter-spacing: 0.1em;
  font-weight: 500;
  opacity: 0.9;
}

.hero__counter-num {
  font-family: var(--serif-en);
  font-style: italic;
  font-weight: 600;
  font-size: clamp(54px, 8vw, 84px);
  color: var(--coral);
  -webkit-text-stroke: 1.5px var(--ink);
  paint-order: stroke fill;
  filter: drop-shadow(2px 2px 0 var(--ink));
  letter-spacing: -0.02em;
  line-height: 1;
  display: inline-block;
  padding: 0 4px;
  /* gentle entry; JS adds .is-in to trigger */
  opacity: 0;
  transform: translateY(12px);
  transition: opacity 1.2s ease, transform 1.2s cubic-bezier(.2,.7,.2,1);
}
.hero__counter-num.is-in {
  opacity: 1;
  transform: none;
}

/* ════════════════════════════════════════════════════════
   SECTION HEADS (shared by Our Story / Wall of Love)
   ════════════════════════════════════════════════════════ */
.section-head .eyebrow-en {
  display: inline-block;
}

.section-head__row {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 18px;
}

.section-head__row .subtitle-cn {
  margin: 0;
  padding: 0;
}

/* ════════════════════════════════════════════════════════
   OUR STORY — zig-zag timeline
   ════════════════════════════════════════════════════════ */
.story {
  background-color: var(--bg-sky-pale);
  background-image:
    linear-gradient(180deg,
      var(--bg-cream) 0%,
      rgba(245,233,210,0) 10%,
      rgba(245,233,210,0) 90%,
      var(--bg-cream) 100%),
    url("assets/sky.jpg");
  background-size: cover, cover;
  background-position: center, center;
  background-repeat: no-repeat, no-repeat;
  background-attachment: scroll;
  position: relative;
}

/* hand-drawn squiggle accent under section headers */
.section-head {
  position: relative;
}
.section-head::after {
  content: '';
  display: block;
  width: clamp(140px, 18vw, 220px);
  height: 14px;
  margin-top: 24px;
  background-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 220 14' fill='none'><path d='M2 8 Q 20 1 38 7 T 76 7 T 114 7 T 152 7 T 190 7 T 218 7' stroke='%23E8554C' stroke-width='2.5' stroke-linecap='round' fill='none'/></svg>");
  background-repeat: no-repeat;
  background-size: contain;
}

.story::before {
  /* warm cream gradient join under the hero's bottom fade */
  content: '';
  position: absolute;
  top: 0; left: 0; right: 0; height: 1px;
  background: var(--ink);
  opacity: 0.06;
}

.timeline {
  position: relative;
  margin-top: 60px;
}

/* center vertical line */
.timeline::before {
  content: '';
  position: absolute;
  top: 0; bottom: 0;
  left: 50%;
  width: 1.5px;
  background: linear-gradient(180deg,
    transparent 0%,
    var(--coral) 6%,
    var(--coral) 94%,
    transparent 100%);
  opacity: 0.5;
}

.tl-item {
  position: relative;
  width: 50%;
  padding: clamp(14px, 2.2vw, 26px) clamp(20px, 3vw, 40px);
  /* pull each row up so the NEXT row's date sits at the previous row's photo-bottom */
  margin-top: clamp(-220px, -15vw, -110px);
  opacity: 0;
  transform: translateY(30px);
  transition: opacity .9s ease, transform .9s cubic-bezier(.2,.7,.2,1);
}

/* first item shouldn't pull up (nothing above) */
.tl-item:first-child { margin-top: 0; }

.tl-item.is-in {
  opacity: 1;
  transform: none;
}

.tl-item:nth-child(odd) {
  margin-right: auto;
  text-align: right;
  padding-right: clamp(28px, 3.5vw, 56px);
}

.tl-item:nth-child(even) {
  margin-left: 50%;
  text-align: left;
  padding-left: clamp(28px, 3.5vw, 56px);
}

/* center dot */
.tl-item::before {
  content: '';
  position: absolute;
  top: clamp(50px, 7vw, 78px);
  width: 11px;
  height: 11px;
  border-radius: 50%;
  background: var(--coral);
  border: 1.5px solid var(--ink);
}
.tl-item:nth-child(odd)::before  { right: -4.5px; }
.tl-item:nth-child(even)::before { left: -4.5px;  }

.tl-card {
  display: inline-block;
  text-align: left;
  max-width: 310px;
  width: 100%;
}

.tl-date {
  font-family: var(--script);
  font-weight: 600;
  font-size: 24px;
  color: var(--coral);
  letter-spacing: 0.01em;
  margin: 0 0 14px;
  line-height: 1;
  display: inline-block;
  white-space: nowrap;
  transform: rotate(-3deg);
  transform-origin: left center;
}

.tl-photo {
  display: block;
  width: 100%;
  height: auto;                   /* override image-slot's internal height:160px so aspect-ratio drives height */
  aspect-ratio: 1 / 1;            /* default until a real image loads — autoFitStoryPhotos overrides via inline style */
  border-radius: var(--radius-card);
  background: var(--card);        /* visible only when the slot is empty */
  box-shadow: 0 16px 36px rgba(17,17,17,0.16),
              0 0 0 1.5px var(--ink);
  overflow: hidden;
  position: relative;
  margin-bottom: 16px;
}

.tl-photo svg {
  width: 100%;
  height: 100%;
  display: block;
}

.tl-title {
  font-family: var(--serif-cn);
  font-weight: 600;
  font-size: 22px;
  color: var(--ink);
  margin: 0 0 8px;
  letter-spacing: 0.02em;
}

.tl-title-en {
  display: block;
  font-family: var(--serif-en);
  font-style: italic;
  font-weight: 500;
  font-size: 18px;
  color: var(--coral);
  letter-spacing: 0.02em;
  margin: 0 0 6px;
  text-transform: lowercase;
}

.tl-body {
  font-family: var(--serif-cn);
  font-weight: 400;
  font-size: 14.5px;
  line-height: 1.75;
  color: var(--ink);
  opacity: 0.75;
  letter-spacing: 0.03em;
  margin: 0;
  text-wrap: pretty;
}

/* ════════════════════════════════════════════════════════
   WALL OF LOVE — flip cards
   ════════════════════════════════════════════════════════ */
.wall {
  background-color: var(--bg-sky-pale);
  background-image:
    linear-gradient(180deg,
      var(--bg-cream) 0%,
      rgba(245,233,210,0) 8%,
      rgba(245,233,210,0) 92%,
      var(--bg-cream) 100%),
    url("assets/sky.jpg");
  background-size: cover, cover;
  background-position: center, center;
  background-repeat: no-repeat, no-repeat;
  position: relative;
  overflow: hidden;
}

.wall__halo { display: none; }

.wall-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: clamp(16px, 1.8vw, 24px);
  margin-top: 60px;
  max-width: 1180px;      /* cap overall width — 4 comfortable "note" cards per row */
  margin-left: auto;
  margin-right: auto;
  position: relative;
  z-index: 1;
}

@media (max-width: 1024px) {
  .wall-grid { grid-template-columns: repeat(3, 1fr); }
}
@media (max-width: 760px) {
  .wall-grid { grid-template-columns: repeat(2, 1fr); }
}
@media (max-width: 480px) {
  .wall-grid { grid-template-columns: 1fr; }
}

.wl-card {
  perspective: 1400px;
  aspect-ratio: 1 / 1;
  cursor: pointer;
  opacity: 0;
  transform: translateY(24px);
  transition: opacity .8s ease, transform .8s cubic-bezier(.2,.7,.2,1);
}

.wl-card.is-in {
  opacity: 1;
  transform: none;
}

.wl-card__inner {
  position: relative;
  width: 100%; height: 100%;
  transform-style: preserve-3d;
  transition: transform .7s cubic-bezier(.4,.05,.2,1),
              box-shadow .35s ease;
  border-radius: var(--radius-card);
  box-shadow: 0 12px 40px rgba(17,17,17,0.16),
              0 0 0 1.5px var(--ink);
}

/* —— flip buttons —— */
.wl-flip-btn {
  position: absolute;
  z-index: 5;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background: var(--card);
  border: 1.5px solid var(--ink);
  cursor: pointer;
  padding: 0;
  color: var(--coral);
  box-shadow: 0 4px 10px rgba(17,17,17,0.18);
  transition: transform .18s ease, box-shadow .18s ease, background .18s ease;
  -webkit-tap-highlight-color: transparent;
}
.wl-flip-btn:hover  { transform: translateY(-2px) scale(1.06); box-shadow: 0 6px 14px rgba(17,17,17,0.22); }
.wl-flip-btn:active { transform: translateY(0) scale(0.96); }

.wl-flip-btn--to-back {
  top: 10px;
  right: 10px;
  width: 36px;
  height: 36px;
  border-radius: 50%;
}
.wl-flip-btn--to-back svg { width: 18px; height: 18px; }

.wl-flip-btn--to-front {
  top: 10px;
  right: 10px;
  width: 28px;
  height: 28px;
  border-radius: 50%;
  background: transparent;
  border-color: rgba(17,17,17,0.35);
  color: var(--ink-soft);
  box-shadow: none;
}
.wl-flip-btn--to-front:hover {
  color: var(--coral);
  border-color: var(--coral);
}
.wl-flip-btn--to-front svg { width: 12px; height: 12px; }

/* —— replace-photo button (front face only, shows on hover) —— */
.wl-replace-btn {
  position: absolute;
  z-index: 5;
  left: 10px;
  top: 10px;
  padding: 6px 12px;
  border-radius: 999px;
  border: 1.5px solid var(--ink);
  background: var(--card);
  color: var(--ink);
  font-family: var(--serif-cn);
  font-size: 13px;
  letter-spacing: 0.08em;
  cursor: pointer;
  box-shadow: 0 4px 10px rgba(17,17,17,0.18);
  opacity: 0;
  transform: translateY(-4px);
  transition: opacity .2s ease, transform .2s ease, background .2s ease, color .2s ease;
  -webkit-tap-highlight-color: transparent;
}
.wl-card:hover .wl-replace-btn,
.wl-replace-btn:focus-visible {
  opacity: 1;
  transform: none;
}
.wl-replace-btn:hover {
  background: var(--coral);
  color: var(--card);
}
@media (hover: none) {
  .wl-replace-btn { opacity: 1; transform: none; }
}

/* hover = subtle lift only; flipping is click-only so the back stays put while editing */

/* —— pointer-events follow which face is currently facing the viewer ——
   backface-visibility hides the back face visually but doesn't block clicks,
   so we must explicitly disable pointer events on the side rotated away. */
.wl-face--back { pointer-events: none; }
.wl-card.is-flipped .wl-face--back  { pointer-events: auto; }
.wl-card.is-flipped .wl-face--front { pointer-events: none; }
.wl-card:hover .wl-card__inner {
  transform: translateY(-4px);
  box-shadow: 0 22px 60px rgba(17,17,17,0.18);
}

.wl-card.is-flipped .wl-card__inner {
  transform: rotateY(180deg);
}
.wl-card.is-flipped:hover .wl-card__inner {
  transform: rotateY(180deg) translateY(-4px);
}

/* —— while the user is dragging a file onto the page, freeze the flip
       so they can drop onto the front-side image slot —— */
body.is-file-dragging .wl-card:not(.is-flipped):hover .wl-card__inner {
  transform: none;
}
body.is-file-dragging .wl-card.is-flipped:hover .wl-card__inner {
  transform: rotateY(180deg);
}

/* photo slot on the front face — fills the entire card */
.wl-photo {
  position: relative;
  z-index: 1;
  display: block;
  width: 100%;
  height: 100%;
  margin: 0;
  box-shadow: none;
}

.wl-face {
  position: absolute;
  inset: 0;
  border-radius: var(--radius-card);
  background: var(--card);
  padding: clamp(18px, 1.8vw, 24px);
  display: flex;
  flex-direction: column;
  -webkit-backface-visibility: hidden;
  backface-visibility: hidden;
  overflow: hidden;
}

/* paper texture, very subtle */
.wl-face::before {
  content: '';
  position: absolute;
  inset: 0;
  background-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' width='200' height='200'><filter id='n'><feTurbulence type='fractalNoise' baseFrequency='0.85' numOctaves='2' stitchTiles='stitch'/><feColorMatrix values='0 0 0 0 0.55  0 0 0 0 0.45  0 0 0 0 0.35  0 0 0 0.08 0'/></filter><rect width='100%' height='100%' filter='url(%23n)'/></svg>");
  pointer-events: none;
  opacity: 0.55;
}

.wl-face--front {
  background: linear-gradient(160deg, #FFFCF4 0%, #F8EBD2 100%);
  /* photo fills the whole front \u2014 no internal padding, no grain */
  padding: 0;
  justify-content: stretch;
  align-items: stretch;
}

.wl-face--front::before { display: none; }

.wl-face--back {
  transform: rotateY(180deg);
  background: linear-gradient(160deg, #FFFCF4 0%, #FBD9D5 100%);
  justify-content: center;
  align-items: center;
  text-align: center;
}

.wl-front-top {
  position: relative;
  z-index: 1;
}

.wl-preview {
  font-family: var(--serif-en);
  font-style: italic;
  font-weight: 500;
  font-size: clamp(20px, 1.9vw, 24px);
  color: var(--ink);
  margin: 0 0 14px;
  letter-spacing: 0.01em;
}

.wl-preview-sub {
  font-family: var(--serif-cn);
  font-size: 16px;
  line-height: 1.8;
  color: var(--ink);
  margin: 0;
  letter-spacing: 0.04em;
  text-wrap: pretty;
}

.wl-front-bottom {
  position: relative;
  z-index: 1;
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 12px;
}

.wl-signature {
  font-family: var(--script);
  font-size: 22px;
  font-weight: 600;
  color: var(--coral);
  line-height: 1;
}

.wl-flip-hint {
  font-family: var(--serif-en);
  font-style: italic;
  font-size: 12px;
  color: var(--ink-soft);
  letter-spacing: 0.15em;
  text-transform: uppercase;
  opacity: 0.7;
}

.wl-message {
  position: relative;
  z-index: 1;
  font-family: var(--serif-cn);
  font-size: clamp(13px, 1vw, 14.5px);
  line-height: 1.85;
  color: var(--ink);
  letter-spacing: 0.04em;
  margin: 0;
  text-wrap: pretty;
  text-align: center;
}

.wl-back-mark {
  position: relative;
  z-index: 1;
  font-family: var(--serif-en);
  font-style: italic;
  font-size: 12px;
  color: var(--coral);
  letter-spacing: 0.12em;
  text-transform: uppercase;
  font-weight: 600;
}

.wl-back-foot {
  position: relative;
  z-index: 1;
  display: flex;
  justify-content: flex-end;
}

/* ════════════════════════════════════════════════════════
   TO BE CONTINUED — visitor wishlist
   ════════════════════════════════════════════════════════ */
.wishlist {
  background-color: var(--bg-cream);
  background-image:
    radial-gradient(ellipse at 15% 0%,  rgba(242,168,200,0.18) 0%, transparent 45%),
    radial-gradient(ellipse at 85% 100%, rgba(125,195,234,0.18) 0%, transparent 45%);
  position: relative;
  overflow: hidden;
}

.wishlist .container {
  position: relative;
  z-index: 1;
}

.wl2-list {
  list-style: none;
  margin: 60px auto 0;
  padding: 0;
  max-width: 760px;
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.wl2-item {
  display: grid;
  grid-template-columns: 32px 44px 1fr auto 28px;
  align-items: baseline;
  gap: 14px;
  padding: 18px 18px 18px 8px;
  border-bottom: 1.5px dashed rgba(17,17,17,0.18);
  font-family: var(--serif-cn);
  font-size: 17px;
  line-height: 1.5;
  color: var(--ink);
  letter-spacing: 0.03em;
  opacity: 0;
  transform: translateY(10px);
  animation: wl2In .7s cubic-bezier(.2,.7,.2,1) forwards;
  animation-delay: var(--delay, 0ms);
  transition: opacity .28s ease, transform .28s ease, max-height .28s ease, padding .28s ease, border-color .28s ease;
}

.wl2-item.is-removing {
  opacity: 0;
  transform: translateX(40px);
  border-color: transparent;
  pointer-events: none;
}

.wl2-empty {
  list-style: none;
  text-align: center;
  padding: 40px 8px;
  font-family: var(--serif-cn);
  font-size: 16px;
  color: var(--ink-soft);
  letter-spacing: 0.05em;
  border-top: 1.5px dashed rgba(17,17,17,0.18);
  border-bottom: 1.5px dashed rgba(17,17,17,0.18);
}

@keyframes wl2In {
  to { opacity: 1; transform: none; }
}

.wl2-item:last-child {
  border-bottom: none;
}

/* heart "checkbox" — unchecked outline; visitor adds get a pink fill; done items fill coral */
.wl2-check {
  display: inline-flex;
  width: 26px;
  height: 26px;
  align-items: center;
  justify-content: center;
  color: var(--ink);
  transform: translateY(3px);
  background: none;
  border: none;
  padding: 0;
  cursor: pointer;
  -webkit-tap-highlight-color: transparent;
  transition: transform .18s ease;
}
.wl2-check:hover { transform: translateY(2px) scale(1.12); }
.wl2-check:active { transform: translateY(3px) scale(0.94); }
.wl2-check svg {
  width: 100%;
  height: 100%;
  display: block;
}
.wl2-check svg path {
  fill: none;
  stroke: var(--ink);
  transition: fill .25s ease, stroke .25s ease;
}
.wl2-item--visitor .wl2-check svg path {
  fill: var(--pink);
  stroke: var(--coral);
}
.wl2-item.is-done .wl2-check svg path {
  fill: var(--coral);
  stroke: var(--ink);
}

.wl2-num {
  font-family: var(--serif-en);
  font-style: italic;
  font-weight: 600;
  font-size: 22px;
  color: var(--coral);
  letter-spacing: 0.04em;
  line-height: 1;
}

.wl2-text-wrap {
  position: relative;
  display: inline-flex;
  align-items: baseline;
  flex-wrap: wrap;
  min-width: 0;
}

.wl2-text {
  font-family: var(--serif-cn);
  font-size: clamp(17px, 1.4vw, 19px);
  color: var(--ink);
  text-wrap: pretty;
  transition: color .3s ease, opacity .3s ease;
}
.wl2-item--visitor .wl2-text {
  font-family: var(--script);
  font-size: clamp(22px, 1.9vw, 26px);
  line-height: 1.25;
  letter-spacing: 0.01em;
  color: var(--ink);
}

/* hand-drawn strikethrough that draws across the text when done */
.wl2-strike {
  position: absolute;
  left: -2px;
  right: -2px;
  top: 55%;
  height: 2px;
  background: var(--coral);
  border-radius: 2px;
  transform: scaleX(0);
  transform-origin: left center;
  transition: transform .45s cubic-bezier(.55,.05,.25,1);
  pointer-events: none;
}
.wl2-item.is-done .wl2-strike {
  transform: scaleX(1);
}
.wl2-item.is-done .wl2-text {
  color: var(--ink-soft);
  opacity: 0.65;
}
.wl2-item.is-done .wl2-num {
  opacity: 0.45;
}

.wl2-from {
  font-family: var(--serif-en);
  font-style: italic;
  font-size: 14px;
  color: var(--ink-soft);
  letter-spacing: 0.06em;
  white-space: nowrap;
}
.wl2-item--visitor .wl2-from {
  color: var(--coral);
}
.wl2-item.is-done .wl2-from {
  opacity: 0.5;
}

/* delete button (×) — subtle until row is hovered */
.wl2-del {
  display: inline-flex;
  width: 26px;
  height: 26px;
  align-items: center;
  justify-content: center;
  background: none;
  border: none;
  padding: 0;
  cursor: pointer;
  color: var(--ink-soft);
  opacity: 0.35;
  transition: opacity .2s ease, color .2s ease, transform .2s ease;
  -webkit-tap-highlight-color: transparent;
  border-radius: 50%;
}
.wl2-item:hover .wl2-del { opacity: 0.85; }
.wl2-del:hover {
  color: var(--coral);
  opacity: 1 !important;
  transform: rotate(90deg);
}
.wl2-del svg {
  width: 14px;
  height: 14px;
  display: block;
}
@media (hover: none) {
  .wl2-del { opacity: 0.7; }
}

/* ── add form ───────────────────────────────────── */
.wl2-form {
  max-width: 760px;
  margin: 36px auto 0;
}

.wl2-form__row {
  display: grid;
  grid-template-columns: 1fr 180px auto;
  gap: 10px;
  align-items: stretch;
}

.wl2-input {
  font-family: var(--serif-cn);
  font-size: 16px;
  color: var(--ink);
  padding: 14px 16px;
  background: var(--card);
  border: 1.5px solid var(--ink);
  border-radius: 999px;
  outline: none;
  transition: box-shadow .2s ease, transform .2s ease;
  letter-spacing: 0.03em;
}
.wl2-input::placeholder {
  color: var(--ink-soft);
  opacity: 0.7;
}
.wl2-input:focus {
  box-shadow: 4px 4px 0 var(--ink);
  transform: translate(-1px, -1px);
}

.wl2-btn {
  font-family: var(--serif-cn);
  font-weight: 500;
  font-size: 16px;
  padding: 0 28px;
  border: 1.5px solid var(--ink);
  border-radius: 999px;
  background: var(--coral);
  color: var(--card);
  cursor: pointer;
  letter-spacing: 0.1em;
  box-shadow: 3px 3px 0 var(--ink);
  transition: transform .15s ease, box-shadow .15s ease;
  white-space: nowrap;
}
.wl2-btn:hover {
  transform: translate(-1px, -1px);
  box-shadow: 5px 5px 0 var(--ink);
}
.wl2-btn:active {
  transform: translate(1px, 1px);
  box-shadow: 1px 1px 0 var(--ink);
}

.wl2-form__hint {
  margin: 12px 4px 0;
  font-family: var(--serif-en);
  font-style: italic;
  font-size: 14px;
  color: var(--coral);
  letter-spacing: 0.08em;
  min-height: 1.2em;
  opacity: 0;
  transform: translateY(-4px);
  transition: opacity .25s ease, transform .25s ease;
}
.wl2-form__hint.is-show {
  opacity: 1;
  transform: none;
}

@media (max-width: 640px) {
  .wl2-item {
    grid-template-columns: 26px 36px 1fr 24px;
    grid-template-areas:
      "check num text del"
      ".    .   from from";
    gap: 10px;
    row-gap: 4px;
  }
  .wl2-check    { grid-area: check; }
  .wl2-num      { grid-area: num; }
  .wl2-text-wrap{ grid-area: text; }
  .wl2-from     { grid-area: from; }
  .wl2-del      { grid-area: del; opacity: 0.7; }
  .wl2-form__row {
    grid-template-columns: 1fr;
  }
}

/* ════════════════════════════════════════════════════════
   FOOTER
   ════════════════════════════════════════════════════════ */
.footer {
  padding: 56px var(--pad-x) 48px;
  text-align: center;
  background: var(--bg-cream);
  border-top: 1px solid var(--line);
}

.footer__text {
  color: var(--ink) !important;
  opacity: 0.65;
}

.footer__text {
  font-family: var(--serif-en);
  font-style: italic;
  font-size: 13px;
  color: var(--ink-soft);
  letter-spacing: 0.18em;
  margin: 0;
}

/* ════════════════════════════════════════════════════════
   RESPONSIVE — collapse timeline to single column
   ════════════════════════════════════════════════════════ */
@media (max-width: 768px) {
  body { font-size: 16px; }

  .timeline::before {
    left: 14px;
  }

  .tl-item,
  .tl-item:nth-child(odd),
  .tl-item:nth-child(even) {
    width: 100%;
    margin-top: 0;
    margin-left: 0;
    margin-right: 0;
    text-align: left;
    padding: 28px 0 28px 40px;
  }

  .tl-item::before,
  .tl-item:nth-child(odd)::before,
  .tl-item:nth-child(even)::before {
    left: 10px;
    right: auto;
    top: 42px;
  }

  .tl-card { max-width: 100%; }

  .hero { padding-top: 120px; }

  /* allow title to wrap on small screens */
  .hero__title { flex-wrap: wrap; gap: 6px 14px; }

  .nav__monogram { font-size: 18px; }
  .nav__link { font-size: 15px; }
}

@media (max-width: 480px) {
  .hero__sub-cn { letter-spacing: 0.35em; }
}

/* ════════════════════════════════════════════════════════
   reduced-motion
   ════════════════════════════════════════════════════════ */
@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    animation-duration: 0.001ms !important;
    transition-duration: 0.001ms !important;
  }
  .tl-item, .wl-card, .hero__counter-num {
    opacity: 1 !important;
    transform: none !important;
  }
  .hero__title-line { animation: none !important; }
}
