:root {
  --red: #aa1119;
  --red-dark: #7b0910;
  --red-soft: #c94f54;
  --cream: #f7f1e9;
  --cream-deep: #eee4d8;
  --paper: #fffdf9;
  --ink: #2d2825;
  --muted: #746b66;
  --line: rgba(75, 48, 43, 0.16);
  --serif-cn: "Noto Serif SC", "Source Han Serif SC", "Songti SC", STSong, SimSun, serif;
  --sans-cn: "Noto Sans SC", "Microsoft YaHei UI", "Microsoft YaHei", sans-serif;
  --serif-en: "Bodoni 72", Didot, "Times New Roman", serif;
  --script-cn: "STKaiti", "KaiTi", "FangSong", serif;
  --ease: cubic-bezier(0.22, 1, 0.36, 1);
  --section-space: clamp(6rem, 12vw, 10rem);
}

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

html {
  scroll-behavior: smooth;
  background: var(--red-dark);
}

body {
  margin: 0;
  overflow-x: hidden;
  background: var(--cream);
  color: var(--ink);
  font-family: var(--sans-cn);
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

body.lightbox-open,
body.contact-modal-open {
  overflow: hidden;
}

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

[hidden] {
  display: none !important;
}

button,
a {
  -webkit-tap-highlight-color: transparent;
}

button {
  font: inherit;
}

a {
  color: inherit;
  text-decoration: none;
}

.page-shell {
  width: min(calc(100% - clamp(2rem, 8vw, 7rem)), 980px);
  margin-inline: auto;
}

.section-pad {
  padding-block: var(--section-space);
}

.section-mark {
  margin: 0 0 1.2rem;
  color: var(--red);
  font-family: var(--serif-en);
  font-size: 0.67rem;
  letter-spacing: 0.32em;
}

.skip-link {
  position: fixed;
  top: 0.75rem;
  left: 0.75rem;
  z-index: 1000;
  padding: 0.7rem 1rem;
  transform: translateY(-150%);
  background: var(--paper);
  color: var(--ink);
  font-size: 0.8rem;
  transition: transform 180ms ease;
}

.skip-link:focus {
  transform: translateY(0);
}

.scroll-progress {
  position: fixed;
  top: 0;
  right: 0;
  left: 0;
  z-index: 700;
  height: 2px;
  pointer-events: none;
}

.scroll-progress span {
  display: block;
  width: 100%;
  height: 100%;
  transform: scaleX(0);
  transform-origin: left;
  background: var(--red);
}

.music-toggle {
  position: fixed;
  right: max(1rem, env(safe-area-inset-right));
  bottom: max(1rem, env(safe-area-inset-bottom));
  z-index: 300;
  display: grid;
  grid-template-columns: 2.2rem auto 1rem;
  align-items: center;
  gap: 0.65rem;
  min-width: 10.8rem;
  padding: 0.42rem 0.75rem 0.42rem 0.42rem;
  border: 1px solid rgba(255, 255, 255, 0.34);
  border-radius: 999px;
  background: rgba(126, 9, 16, 0.9);
  box-shadow: 0 0.8rem 2.2rem rgba(68, 2, 7, 0.24);
  color: white;
  cursor: pointer;
  backdrop-filter: blur(12px);
}

.music-disc {
  display: grid;
  width: 2.2rem;
  height: 2.2rem;
  place-items: center;
  border: 1px solid rgba(255, 255, 255, 0.42);
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.08);
}

.music-disc svg {
  width: 1rem;
  fill: none;
  stroke: currentColor;
  stroke-linecap: round;
  stroke-linejoin: round;
  stroke-width: 1.55;
}

.music-label {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  line-height: 1.05;
}

.music-label small {
  font-family: var(--serif-en);
  font-size: 0.5rem;
  letter-spacing: 0.2em;
  opacity: 0.68;
}

.music-label strong {
  margin-top: 0.24rem;
  font-family: var(--serif-cn);
  font-size: 0.72rem;
  font-weight: 400;
  letter-spacing: 0.12em;
}

.music-bars {
  display: flex;
  height: 1rem;
  align-items: center;
  justify-content: center;
  gap: 2px;
}

.music-bars i {
  width: 2px;
  height: 35%;
  border-radius: 2px;
  background: currentColor;
}

.music-toggle[aria-pressed="true"] .music-disc {
  animation: spin 6s linear infinite;
}

.music-toggle[aria-pressed="true"] .music-bars i {
  animation: music-bar 0.75s ease-in-out infinite alternate;
}

.music-toggle[aria-pressed="true"] .music-bars i:nth-child(2) {
  animation-delay: -0.28s;
}

.music-toggle[aria-pressed="true"] .music-bars i:nth-child(3) {
  animation-delay: -0.5s;
}

@keyframes spin {
  to { transform: rotate(360deg); }
}

@keyframes music-bar {
  to { height: 100%; }
}

.hero {
  position: relative;
  display: grid;
  min-height: 100svh;
  overflow: hidden;
  place-items: center;
  background: #16090a;
  color: white;
}

.hero-media,
.hero-scrim {
  position: absolute;
  inset: 0;
}

.hero-media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center 48%;
  animation: hero-drift 16s ease-in-out infinite alternate;
}

@keyframes hero-drift {
  from { transform: scale(1.01); }
  to { transform: scale(1.075); }
}

.hero-scrim {
  background:
    linear-gradient(180deg, rgba(19, 6, 7, 0.2), rgba(19, 6, 7, 0.08) 38%, rgba(19, 6, 7, 0.84)),
    linear-gradient(90deg, rgba(19, 6, 7, 0.2), transparent 35%, transparent 65%, rgba(19, 6, 7, 0.2));
}

.hero::after {
  position: absolute;
  inset: clamp(0.7rem, 2vw, 1.5rem);
  border: 1px solid rgba(255, 255, 255, 0.48);
  content: "";
  pointer-events: none;
}

.hero-topline {
  position: absolute;
  top: clamp(1.6rem, 4vw, 3rem);
  right: clamp(1.4rem, 5vw, 4rem);
  left: clamp(1.4rem, 5vw, 4rem);
  z-index: 2;
  display: flex;
  justify-content: space-between;
  font-family: var(--serif-en);
  font-size: 0.63rem;
  letter-spacing: 0.24em;
}

.hero-copy {
  position: relative;
  z-index: 2;
  width: min(calc(100% - 3rem), 56rem);
  margin-top: 34svh;
  text-align: center;
  text-shadow: 0 2px 20px rgba(18, 4, 5, 0.4);
}

.hero-kicker {
  margin: 0;
  font-family: var(--serif-en);
  font-size: clamp(0.68rem, 1.4vw, 0.84rem);
  letter-spacing: 0.44em;
}

.hero-cn-title {
  margin: 0.7rem 0 1.3rem;
  font-family: var(--serif-cn);
  font-size: 0.82rem;
  letter-spacing: 0.5em;
}

.hero h1 {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: clamp(0.8rem, 3vw, 2rem);
  margin: 0;
  font-family: var(--serif-cn);
  font-size: clamp(2.6rem, 7vw, 6rem);
  font-weight: 400;
  letter-spacing: 0.14em;
}

.hero h1 b {
  font-family: var(--serif-en);
  font-size: 0.54em;
  font-style: italic;
  font-weight: 400;
}

.double-happiness {
  width: fit-content;
  margin: 1.1rem auto;
  padding: 0.22rem 0.5rem;
  border: 1px solid rgba(255, 255, 255, 0.7);
  font-family: var(--serif-cn);
  font-size: 1rem;
}

.hero-hello {
  margin: 0;
  font-family: var(--serif-cn);
  font-size: clamp(0.72rem, 1.3vw, 0.9rem);
  letter-spacing: 0.12em;
  line-height: 2;
}

.hero-scroll {
  position: absolute;
  bottom: max(1.5rem, calc(env(safe-area-inset-bottom) + 1rem));
  left: 50%;
  z-index: 2;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.55rem;
  transform: translateX(-50%);
  font-size: 0.58rem;
  letter-spacing: 0.22em;
}

.hero-scroll i {
  position: relative;
  width: 1px;
  height: 2rem;
  overflow: hidden;
  background: rgba(255, 255, 255, 0.3);
}

.hero-scroll i::after {
  position: absolute;
  inset: -100% 0 0;
  background: white;
  content: "";
  animation: scroll-line 2s ease-in-out infinite;
}

@keyframes scroll-line {
  0% { transform: translateY(0); }
  70%, 100% { transform: translateY(200%); }
}

.letter-section {
  position: relative;
  overflow: hidden;
  background:
    radial-gradient(circle at 0 20%, rgba(170, 17, 25, 0.055), transparent 24rem),
    var(--cream);
}

.letter-section::before,
.letter-section::after {
  position: absolute;
  width: 22rem;
  height: 22rem;
  border: 1px solid rgba(170, 17, 25, 0.08);
  border-radius: 50%;
  content: "";
}

.letter-section::before {
  top: -11rem;
  right: -11rem;
}

.letter-section::after {
  bottom: -13rem;
  left: -13rem;
}

.letter-inner {
  position: relative;
  z-index: 1;
  text-align: center;
}

.letter-title {
  margin: 0;
  color: var(--red);
  font-family: var(--serif-cn);
  font-size: clamp(2rem, 4.8vw, 4.2rem);
  font-weight: 400;
  letter-spacing: 0.28em;
  line-height: 1.55;
}

.letter-title span {
  color: var(--ink);
  font-size: 0.38em;
  letter-spacing: 0.2em;
}

.letter-copy {
  margin-top: 2.2rem;
  color: var(--muted);
  font-family: var(--serif-cn);
  font-size: 0.9rem;
  letter-spacing: 0.12em;
  line-height: 2;
}

.letter-copy p {
  margin: 0.2rem 0;
}

.letter-date {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 1rem;
  margin-top: 2.4rem;
  color: var(--red);
  font-family: var(--serif-en);
  font-size: clamp(2.6rem, 7vw, 5rem);
  font-style: italic;
}

.letter-date i {
  width: 2.8rem;
  height: 1px;
  background: var(--red);
}

.handwriting {
  margin: clamp(3rem, 7vw, 5rem) 0 0;
  font-family: var(--script-cn);
  font-size: clamp(1.35rem, 3.8vw, 2.3rem);
  letter-spacing: 0.16em;
}

.contact-profiles {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  align-items: start;
  width: min(100%, 38rem);
  gap: clamp(1rem, 8vw, 5rem);
  margin: 3.2rem auto 0;
}

.contact-profile {
  display: flex;
  min-width: 0;
  flex-direction: column;
  align-items: center;
  padding: 0;
  border: 0;
  background: transparent;
  color: var(--ink);
  cursor: pointer;
}

.contact-avatar {
  display: block;
  width: clamp(7rem, 15vw, 9.2rem);
  overflow: hidden;
  aspect-ratio: 1;
  border: 0.38rem solid var(--paper);
  border-radius: 50%;
  box-shadow: 0 0.8rem 2.2rem rgba(80, 42, 36, 0.14);
}

.contact-avatar img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 650ms var(--ease);
}

.contact-profile:hover .contact-avatar img {
  transform: scale(1.05);
}

.contact-role {
  margin-top: 1.1rem;
  color: var(--red);
  font-family: var(--serif-en), var(--serif-cn);
  font-size: 0.58rem;
  letter-spacing: 0.17em;
}

.contact-profile strong {
  margin-top: 0.38rem;
  font-family: var(--serif-cn);
  font-size: clamp(1.2rem, 3vw, 1.75rem);
  font-weight: 400;
  letter-spacing: 0.14em;
}

.contact-cta {
  display: inline-flex;
  min-height: 1.9rem;
  align-items: center;
  gap: 0.45rem;
  margin-top: 0.9rem;
  padding: 0.58rem 0.95rem;
  border-radius: 999px;
  background: var(--red);
  color: white;
  font-size: 0.66rem;
  letter-spacing: 0.1em;
  line-height: 1;
  white-space: nowrap;
}

.contact-cta i {
  font-family: var(--serif-en);
  font-style: normal;
}

.details-section {
  background: var(--paper);
}

.details-inner {
  display: grid;
  gap: clamp(3rem, 7vw, 5rem);
}

.details-heading {
  text-align: center;
}

.details-heading h2,
.venue-card h3,
.tips-inner h2,
.rsvp-intro h2 {
  margin: 0;
  font-family: var(--serif-cn);
  font-size: clamp(1.8rem, 4vw, 3.3rem);
  font-weight: 400;
  letter-spacing: 0.14em;
}

.details-heading h2 span,
.venue-card h3 span {
  color: var(--red);
  font-family: var(--serif-en);
  font-size: 0.38em;
  font-style: italic;
  letter-spacing: 0.1em;
}

.details-heading > p:not(.section-mark) {
  margin: 1rem 0 0;
  color: var(--muted);
  font-family: var(--serif-cn);
  font-size: 0.82rem;
  letter-spacing: 0.1em;
}

.details-heading > p:last-child {
  margin-top: 0.45rem;
}

.countdown {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  width: min(100%, 33rem);
  gap: clamp(0.6rem, 2vw, 1rem);
  margin-inline: auto;
}

.countdown > div {
  display: flex;
  min-height: 5.6rem;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  border-radius: 0.35rem;
  background: var(--red);
  color: white;
  box-shadow: 0 0.8rem 1.8rem rgba(170, 17, 25, 0.12);
}

.countdown strong {
  font-family: var(--serif-en);
  font-size: clamp(1.75rem, 4vw, 3rem);
  font-weight: 400;
  font-variant-numeric: tabular-nums;
  line-height: 1;
}

.countdown span {
  margin-top: 0.55rem;
  font-size: 0.62rem;
  letter-spacing: 0.15em;
  opacity: 0.82;
}

.countdown-note {
  margin: -2rem 0 0;
  color: var(--muted);
  text-align: center;
  font-family: var(--serif-cn);
  font-size: 0.72rem;
  letter-spacing: 0.1em;
}

.wedding-calendar {
  width: min(100%, 38rem);
  margin-inline: auto;
  padding: clamp(1.5rem, 5vw, 3rem);
  border: 2px solid var(--red);
  background: var(--paper);
  color: var(--red);
}

.calendar-head {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  padding-bottom: 1.4rem;
  border-bottom: 1px solid var(--red);
}

.calendar-head strong {
  font-family: var(--serif-en);
  font-size: clamp(2.5rem, 7vw, 4.5rem);
  font-weight: 400;
}

.calendar-head span {
  font-family: var(--serif-en);
  font-size: 1rem;
  letter-spacing: 0.12em;
}

.calendar-week,
.calendar-days {
  display: grid;
  grid-template-columns: repeat(7, 1fr);
  text-align: center;
}

.calendar-week {
  padding-block: 1rem;
  border-bottom: 1px solid rgba(170, 17, 25, 0.35);
  font-size: 0.68rem;
  font-weight: 700;
}

.calendar-days {
  row-gap: 0.65rem;
  padding-top: 0.95rem;
  font-family: var(--serif-en);
  font-size: 0.78rem;
}

.calendar-days span {
  display: grid;
  min-height: 1.9rem;
  place-items: center;
}

.calendar-days .is-wedding-day {
  width: 1.9rem;
  margin-inline: auto;
  border-radius: 50%;
  background: var(--red);
  color: white;
  font-weight: 700;
}

.venue-card {
  width: min(100%, 42rem);
  margin-inline: auto;
  padding: clamp(2rem, 6vw, 4rem);
  border: 1px solid var(--line);
  background:
    linear-gradient(135deg, rgba(170, 17, 25, 0.025), transparent 45%),
    var(--cream);
  text-align: center;
}

.venue-card dl {
  display: grid;
  gap: 1rem;
  margin: 2rem 0 0;
}

.venue-card dl > div {
  display: grid;
  grid-template-columns: 4rem 1fr;
  gap: 1rem;
  padding-bottom: 1rem;
  border-bottom: 1px solid var(--line);
  text-align: left;
}

.venue-card dt {
  color: var(--red);
  font-family: var(--serif-cn);
  font-size: 0.75rem;
  letter-spacing: 0.18em;
}

.venue-card dd {
  margin: 0;
  color: var(--ink);
  font-family: var(--serif-cn);
  font-size: 0.84rem;
  letter-spacing: 0.08em;
  line-height: 1.65;
}

.venue-actions {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 0.7rem;
  margin-top: 2rem;
}

.red-button,
.outline-button {
  display: flex;
  min-height: 3rem;
  align-items: center;
  justify-content: center;
  padding: 0.7rem;
  border: 1px solid var(--red);
  border-radius: 0;
  font-size: 0.7rem;
  letter-spacing: 0.12em;
  cursor: pointer;
}

.red-button {
  background: var(--red);
  color: white;
}

.outline-button {
  background: transparent;
  color: var(--red);
}

.red-button:hover,
.outline-button:hover {
  background: var(--red-dark);
  color: white;
}

.story-section {
  position: relative;
  overflow: hidden;
  background:
    linear-gradient(180deg, var(--cream), var(--paper) 12%, var(--paper) 88%, var(--cream));
}

.story-inner {
  display: grid;
  gap: clamp(4.5rem, 10vw, 8rem);
}

.story-heading {
  text-align: center;
}

.story-heading > span {
  display: inline-grid;
  width: 3rem;
  height: 3rem;
  place-items: center;
  border: 1px solid var(--red);
  color: var(--red);
  font-family: var(--serif-cn);
}

.story-heading h2 {
  margin: 2rem auto 0;
  color: var(--red);
  font-family: var(--script-cn);
  font-size: clamp(1.6rem, 4.5vw, 3rem);
  font-weight: 400;
  letter-spacing: 0.12em;
}

.story-heading p {
  margin: 2rem 0 0;
  color: var(--muted);
  font-family: var(--serif-cn);
  font-size: 0.82rem;
  letter-spacing: 0.1em;
  line-height: 2.15;
}

.story-photo {
  position: relative;
  margin: 0;
}

.photo-button {
  display: block;
  width: 100%;
  padding: 0;
  overflow: hidden;
  border: 0;
  background: #e8ded5;
  cursor: zoom-in;
}

.photo-button img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 5s var(--ease);
}

.story-photo.is-visible .photo-button img {
  transform: scale(1.035);
}

.story-photo--opening {
  width: min(100%, 42rem);
  margin-inline: auto;
}

.story-photo--opening .photo-button {
  aspect-ratio: 2 / 3;
}

.story-photo--opening figcaption {
  display: flex;
  align-items: flex-start;
  gap: 1.2rem;
  padding: 1.1rem 0 0 1.3rem;
  border-left: 1px solid var(--red);
}

.story-photo--opening figcaption span {
  color: var(--red);
  font-family: var(--serif-en);
  font-size: 1.7rem;
}

.story-photo--opening figcaption p {
  margin: 0.3rem 0 0;
  color: var(--muted);
  font-family: var(--serif-cn);
  font-size: 0.76rem;
  letter-spacing: 0.1em;
}

.love-layout {
  position: relative;
  display: grid;
  min-height: 42rem;
  place-items: center;
}

.story-photo--portrait {
  width: min(78%, 31rem);
}

.story-photo--portrait .photo-button {
  aspect-ratio: 2 / 3;
}

.love-label {
  position: absolute;
  top: 22%;
  left: 4%;
  z-index: 2;
  padding: 0.65rem 1rem;
  background: var(--red);
  color: white;
  font-family: var(--serif-en);
  letter-spacing: 0.15em;
}

.line-art {
  position: absolute;
  right: 3%;
  bottom: 2%;
  display: flex;
  width: min(50%, 18rem);
  flex-direction: column;
  align-items: center;
  gap: 0.55rem;
  color: var(--red);
  font-family: var(--serif-en);
  font-size: 2.2rem;
  letter-spacing: 0.25em;
  transform: rotate(-7deg);
}

.line-art i {
  width: 100%;
  height: 1px;
  background: currentColor;
}

.story-duo {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: clamp(0.8rem, 3vw, 1.6rem);
}

.story-duo .photo-button {
  aspect-ratio: 2 / 3;
}

.future-copy,
.forever-copy {
  text-align: center;
  font-family: var(--serif-cn);
  font-size: clamp(0.9rem, 2vw, 1.05rem);
  letter-spacing: 0.12em;
  line-height: 2;
}

.future-copy p,
.forever-copy p {
  margin: 0.4rem 0;
}

.expand-story {
  display: grid;
  grid-template-columns: 1.12fr 0.88fr;
  gap: clamp(2rem, 7vw, 6rem);
  align-items: center;
}

.story-photo--bride .photo-button {
  aspect-ratio: 2 / 3;
}

.expand-story blockquote {
  margin: 0;
  color: var(--muted);
  font-family: var(--serif-cn);
  font-size: clamp(0.85rem, 1.8vw, 1rem);
  letter-spacing: 0.1em;
  line-height: 2.2;
}

.ceremony-collage {
  position: relative;
  min-height: 43rem;
}

.story-photo--ceremony {
  width: 83%;
  margin-left: auto;
}

.story-photo--ceremony .photo-button {
  aspect-ratio: 3 / 2;
}

.story-photo--kiss {
  position: absolute;
  bottom: 0;
  left: 0;
  z-index: 2;
  width: 37%;
  padding: 0.55rem;
  background: var(--paper);
  box-shadow: 0 1.4rem 4rem rgba(76, 44, 39, 0.17);
}

.story-photo--kiss .photo-button {
  aspect-ratio: 2 / 3;
}

.ceremony-copy {
  position: absolute;
  right: 3%;
  bottom: 9%;
  margin: 0;
  color: var(--red);
  font-family: var(--script-cn);
  font-size: clamp(1.4rem, 3vw, 2.2rem);
  letter-spacing: 0.12em;
  line-height: 1.7;
  text-align: center;
}

.coast-copy {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 1.2rem;
  color: var(--red);
  font-family: var(--serif-cn);
  font-size: 0.85rem;
  letter-spacing: 0.16em;
}

.coast-copy i {
  width: 2rem;
  height: 1px;
  background: var(--red);
}

.coast-collage {
  display: grid;
  grid-template-columns: 1.15fr 0.85fr;
  gap: clamp(1rem, 3vw, 2rem);
  align-items: start;
}

.coast-collage .story-photo:first-child {
  margin-top: 4rem;
}

.coast-collage .photo-button {
  aspect-ratio: 3 / 2;
}

.story-photo--finale {
  width: min(100%, 50rem);
  margin-inline: auto;
}

.story-photo--finale .photo-button {
  aspect-ratio: 3 / 2;
}

.story-photo--finale figcaption {
  margin-top: 1rem;
  color: var(--red);
  text-align: center;
  font-family: var(--serif-cn);
  font-size: 0.76rem;
  letter-spacing: 0.25em;
}

.story-pulse.is-visible {
  animation: story-pulse 3.4s ease-in-out 1.2s infinite;
}

@keyframes story-pulse {
  0%, 100% { transform: scale(1); }
  50% { transform: scale(1.012); }
}

.tips-section {
  background: var(--red);
  color: white;
}

.tips-inner {
  width: min(calc(100% - 2rem), 44rem);
}

.tips-inner .section-mark {
  color: rgba(255, 255, 255, 0.66);
}

.tips-inner h2 {
  color: white;
}

.tips-inner ul {
  display: grid;
  gap: 1rem;
  margin: 2.5rem 0 0;
  padding: 0;
  list-style: none;
}

.tips-inner li {
  display: grid;
  grid-template-columns: 3rem 1fr;
  gap: 1rem;
  align-items: start;
  padding: 1rem 0;
  border-bottom: 1px solid rgba(255, 255, 255, 0.2);
}

.tips-inner li span {
  font-family: var(--serif-en);
  font-size: 1.4rem;
  opacity: 0.55;
}

.tips-inner li p {
  margin: 0;
  font-family: var(--serif-cn);
  font-size: 0.8rem;
  letter-spacing: 0.08em;
  line-height: 1.9;
}

.rsvp-section {
  background: var(--cream);
}

.rsvp-card {
  display: grid;
  grid-template-columns: 0.82fr 1.18fr;
  width: min(calc(100% - 2rem), 56rem);
  padding: 0;
  overflow: hidden;
  background: var(--paper);
  box-shadow: 0 2rem 6rem rgba(76, 44, 39, 0.13);
}

.rsvp-intro {
  display: flex;
  flex-direction: column;
  justify-content: center;
  padding: clamp(2rem, 5vw, 4rem);
  border-right: 1px solid var(--line);
  background:
    radial-gradient(circle at 0 0, rgba(170, 17, 25, 0.08), transparent 16rem),
    var(--cream-deep);
}

.rsvp-intro > p:last-child {
  margin: 1.5rem 0 0;
  color: var(--muted);
  font-family: var(--serif-cn);
  font-size: 0.78rem;
  letter-spacing: 0.08em;
  line-height: 1.9;
}

.rsvp-panel {
  display: grid;
  min-height: 35rem;
  align-items: center;
  padding: clamp(2rem, 5vw, 4rem);
}

.rsvp-form {
  display: grid;
  gap: 1.5rem;
}

.form-field {
  display: grid;
  gap: 0.62rem;
  margin: 0;
  padding: 0;
  border: 0;
}

.form-field label,
.form-field legend {
  color: var(--ink);
  font-family: var(--serif-cn);
  font-size: 0.74rem;
  letter-spacing: 0.12em;
}

.form-field input[type="text"] {
  width: 100%;
  min-height: 3.1rem;
  padding: 0.75rem 0.9rem;
  border: 1px solid var(--line);
  border-radius: 0;
  background: transparent;
  color: var(--ink);
  font: inherit;
  font-size: 0.86rem;
}

.form-field input:focus {
  border-color: var(--red);
  outline: 0;
  box-shadow: 0 0 0 2px rgba(170, 17, 25, 0.1);
}

.attendance-options {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 0.5rem;
}

.attendance-options label {
  position: relative;
  cursor: pointer;
}

.attendance-options input {
  position: absolute;
  opacity: 0;
  pointer-events: none;
}

.attendance-options span {
  display: grid;
  min-height: 2.8rem;
  place-items: center;
  border: 1px solid var(--line);
  color: var(--muted);
  font-size: 0.69rem;
  letter-spacing: 0.03em;
}

.attendance-options input:checked + span {
  border-color: var(--red);
  background: var(--red);
  color: white;
}

.attendance-options input:focus-visible + span {
  outline: 2px solid var(--red);
  outline-offset: 2px;
}

.number-stepper {
  display: grid;
  grid-template-columns: 2.8rem 3.2rem 2.8rem auto;
  align-items: center;
  width: fit-content;
  border: 1px solid var(--line);
}

.number-stepper button {
  height: 2.8rem;
  border: 0;
  background: transparent;
  color: var(--red);
  font-size: 1.15rem;
  cursor: pointer;
}

.number-stepper input {
  width: 100%;
  height: 2.8rem;
  border: 0;
  border-right: 1px solid var(--line);
  border-left: 1px solid var(--line);
  background: transparent;
  color: var(--ink);
  text-align: center;
  font: inherit;
  appearance: textfield;
}

.number-stepper input::-webkit-outer-spin-button,
.number-stepper input::-webkit-inner-spin-button {
  margin: 0;
  appearance: none;
}

.number-stepper > span {
  padding-inline: 0.8rem;
  color: var(--muted);
  font-size: 0.7rem;
}

.field-error {
  min-height: 1em;
  color: var(--red);
  font-size: 0.68rem;
}

.form-honeypot {
  position: absolute !important;
  left: -9999px !important;
}

.rsvp-privacy,
.form-status {
  margin: 0;
  color: var(--muted);
  font-size: 0.65rem;
  line-height: 1.6;
}

.form-status {
  min-height: 1.2em;
  color: var(--red);
}

.rsvp-submit {
  display: flex;
  min-height: 3.2rem;
  align-items: center;
  justify-content: space-between;
  padding: 0.8rem 1.1rem;
  border: 1px solid var(--red);
  background: var(--red);
  color: white;
  font-family: var(--serif-cn);
  font-size: 0.76rem;
  letter-spacing: 0.16em;
  cursor: pointer;
}

.rsvp-submit:disabled {
  cursor: wait;
  opacity: 0.65;
}

.rsvp-submit i {
  font-family: var(--serif-en);
  font-style: normal;
}

.rsvp-success {
  text-align: center;
}

.rsvp-success-mark {
  display: grid;
  width: 3rem;
  height: 3rem;
  margin: 0 auto 1.5rem;
  place-items: center;
  border: 1px solid var(--red);
  border-radius: 50%;
  color: var(--red);
  font-size: 1.2rem;
}

.rsvp-success h3 {
  margin: 0;
  font-family: var(--serif-cn);
  font-size: 1.8rem;
  font-weight: 400;
  letter-spacing: 0.12em;
}

.rsvp-success > p:not(.section-mark) {
  margin: 1.3rem 0;
  color: var(--muted);
  font-size: 0.82rem;
  line-height: 1.8;
}

.rsvp-success button {
  padding: 0.7rem 1rem;
  border: 0;
  border-bottom: 1px solid var(--red);
  background: transparent;
  color: var(--red);
  cursor: pointer;
}

.closing {
  background: var(--red-dark);
  color: white;
}

.closing-inner {
  text-align: center;
}

.closing-inner > p:first-child {
  margin: 0;
  font-family: var(--serif-en);
  font-size: 0.68rem;
  letter-spacing: 0.34em;
  opacity: 0.65;
}

.closing h2 {
  margin: 2rem 0 0;
  font-family: var(--serif-cn);
  font-size: clamp(2.5rem, 7vw, 5.2rem);
  font-weight: 400;
  letter-spacing: 0.2em;
  line-height: 1.5;
}

.closing-date {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 1rem;
  margin-top: 2rem;
  font-family: var(--serif-en);
  font-size: clamp(2.4rem, 6vw, 4rem);
}

.closing-date i {
  width: 2.4rem;
  height: 1px;
  background: rgba(255, 255, 255, 0.55);
}

.closing-inner > p:nth-of-type(2) {
  margin: 2rem 0 0;
  font-family: var(--serif-cn);
  font-size: 0.76rem;
  letter-spacing: 0.12em;
  opacity: 0.68;
}

.closing-inner > strong {
  display: block;
  margin-top: 1.6rem;
  font-family: var(--serif-cn);
  font-size: 0.82rem;
  font-weight: 400;
  letter-spacing: 0.2em;
}

footer {
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  padding: 1.3rem clamp(1rem, 5vw, 4rem);
  background: #4d0509;
  color: rgba(255, 255, 255, 0.56);
  font-family: var(--serif-en);
  font-size: 0.58rem;
  letter-spacing: 0.2em;
}

footer p {
  margin: 0;
}

footer > a:last-child {
  justify-self: end;
}

footer .icp-link {
  font-family: var(--sans-cn);
  font-size: 0.72rem;
  letter-spacing: 0.03em;
  text-align: center;
}

footer a:hover {
  color: white;
}

.contact-modal {
  position: fixed;
  inset: 0;
  z-index: 550;
  display: grid;
  padding: 1rem;
  place-items: center;
}

.contact-modal[hidden] {
  display: none;
}

.contact-modal-backdrop {
  position: absolute;
  inset: 0;
  background: rgba(45, 6, 9, 0.76);
  backdrop-filter: blur(10px);
}

.contact-sheet {
  position: relative;
  z-index: 1;
  width: min(100%, 29rem);
  max-height: calc(100svh - 2rem);
  padding: clamp(1.6rem, 5vw, 2.6rem);
  overflow-y: auto;
  background:
    radial-gradient(circle at 100% 0, rgba(170, 17, 25, 0.09), transparent 17rem),
    var(--paper);
  box-shadow: 0 2rem 8rem rgba(45, 6, 9, 0.42);
}

.contact-modal-close {
  position: absolute;
  top: 0.85rem;
  right: 0.85rem;
  display: grid;
  width: 2.5rem;
  height: 2.5rem;
  place-items: center;
  border: 1px solid var(--line);
  border-radius: 50%;
  background: rgba(255, 253, 249, 0.8);
  color: var(--red);
  font-size: 1.35rem;
  cursor: pointer;
}

.contact-sheet-person {
  display: flex;
  align-items: center;
  gap: 1.15rem;
  padding-right: 2.4rem;
}

.contact-sheet-person img {
  width: 4.8rem;
  height: 4.8rem;
  flex: 0 0 4.8rem;
  border: 0.25rem solid white;
  border-radius: 50%;
  object-fit: cover;
  box-shadow: 0 0.7rem 1.7rem rgba(76, 44, 39, 0.17);
}

.contact-sheet-person p {
  margin: 0 0 0.32rem;
  color: var(--red);
  font-family: var(--serif-en), var(--serif-cn);
  font-size: 0.62rem;
  letter-spacing: 0.16em;
}

.contact-sheet-person h2 {
  margin: 0;
  font-family: var(--serif-cn);
  font-size: 1.5rem;
  font-weight: 400;
  letter-spacing: 0.1em;
}

.contact-sheet-intro {
  margin: 1.5rem 0;
  color: var(--muted);
  font-family: var(--serif-cn);
  font-size: 0.8rem;
  letter-spacing: 0.06em;
  line-height: 1.8;
}

.contact-wechat-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  padding: 1rem 1.1rem;
  border: 1px solid var(--line);
  background: var(--cream);
}

.contact-wechat-row span {
  color: var(--muted);
  font-size: 0.7rem;
  letter-spacing: 0.12em;
}

.contact-wechat-row strong {
  font-family: var(--serif-en);
  font-size: 1rem;
  font-weight: 400;
  letter-spacing: 0.06em;
}

.contact-sheet-actions {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 0.65rem;
  margin-top: 0.8rem;
}

.contact-action {
  display: flex;
  min-height: 3rem;
  align-items: center;
  justify-content: center;
  padding: 0.75rem;
  border: 1px solid var(--line);
  background: transparent;
  color: var(--ink);
  font-size: 0.72rem;
  letter-spacing: 0.1em;
  cursor: pointer;
}

.contact-action--primary {
  grid-column: 1 / -1;
  border-color: var(--red);
  background: var(--red);
  color: white;
}

.contact-action:hover {
  border-color: var(--red);
}

.contact-action--primary:hover {
  background: var(--red-dark);
}

.contact-sheet-note {
  margin: 1rem 0 0;
  color: var(--muted);
  font-size: 0.65rem;
  line-height: 1.7;
}

.lightbox {
  position: fixed;
  inset: 0;
  z-index: 500;
  display: grid;
  place-items: center;
  color: white;
}

.lightbox[hidden] {
  display: none;
}

.lightbox-backdrop {
  position: absolute;
  inset: 0;
  background: rgba(24, 4, 6, 0.95);
  backdrop-filter: blur(12px);
}

.lightbox figure {
  position: relative;
  z-index: 1;
  display: flex;
  max-width: min(88vw, 86rem);
  max-height: 88vh;
  flex-direction: column;
  align-items: center;
  gap: 0.8rem;
}

.lightbox figure img {
  width: auto;
  max-width: 100%;
  height: auto;
  max-height: 82vh;
  object-fit: contain;
  box-shadow: 0 1rem 5rem rgba(0, 0, 0, 0.3);
}

.lightbox figcaption {
  font-family: var(--serif-cn);
  font-size: 0.72rem;
  letter-spacing: 0.12em;
  opacity: 0.72;
}

.lightbox-close,
.lightbox-arrow {
  position: absolute;
  z-index: 2;
  display: grid;
  width: 3rem;
  height: 3rem;
  place-items: center;
  border: 1px solid rgba(255, 255, 255, 0.35);
  border-radius: 50%;
  background: rgba(126, 9, 16, 0.32);
  color: white;
  cursor: pointer;
}

.lightbox-close {
  top: max(1rem, env(safe-area-inset-top));
  right: max(1rem, env(safe-area-inset-right));
  font-size: 1.45rem;
}

.lightbox-arrow {
  top: 50%;
  transform: translateY(-50%);
  font-family: var(--serif-en);
  font-size: 2rem;
}

.lightbox-arrow--prev { left: max(1rem, env(safe-area-inset-left)); }
.lightbox-arrow--next { right: max(1rem, env(safe-area-inset-right)); }

.toast {
  position: fixed;
  bottom: max(5.5rem, calc(env(safe-area-inset-bottom) + 5.5rem));
  left: 50%;
  z-index: 600;
  max-width: calc(100vw - 2rem);
  padding: 0.75rem 1.1rem;
  border: 1px solid rgba(255, 255, 255, 0.2);
  border-radius: 999px;
  background: rgba(126, 9, 16, 0.94);
  color: white;
  font-size: 0.74rem;
  letter-spacing: 0.08em;
  opacity: 0;
  transform: translate(-50%, 0.75rem);
  pointer-events: none;
  backdrop-filter: blur(10px);
  transition: opacity 220ms ease, transform 220ms ease;
}

.wechat-share-guide {
  position: fixed;
  inset: max(1.25rem, env(safe-area-inset-top)) 1rem auto auto;
  width: min(25rem, calc(100% - 2rem));
  max-height: calc(100svh - 3rem);
  margin: 0;
  overflow-y: auto;
  padding: 1.5rem;
  border: 1px solid var(--line);
  border-radius: 1rem;
  background: var(--paper);
  color: var(--ink);
  box-shadow: 0 1rem 4rem rgba(45, 6, 9, 0.25);
}

.wechat-share-guide::backdrop {
  background: rgba(45, 6, 9, 0.72);
}

.wechat-share-guide h2 {
  font-family: var(--serif-cn);
  font-size: 1.25rem;
  color: var(--red);
}

.wechat-share-guide p { line-height: 1.9; }
.wechat-share-direction { margin-top: 0; color: var(--red); text-align: right; }
.wechat-share-note { color: var(--muted); font-size: 0.78rem; }
.wechat-share-guide button { width: 100%; margin-top: 0.5rem; }

.toast.is-visible {
  opacity: 1;
  transform: translate(-50%, 0);
}

.contact-profile:focus-visible,
.red-button:focus-visible,
.outline-button:focus-visible,
.rsvp-submit:focus-visible,
.contact-action:focus-visible,
.contact-modal-close:focus-visible,
.photo-button:focus-visible,
.lightbox button:focus-visible,
.music-toggle:focus-visible {
  outline: 2px solid var(--red);
  outline-offset: 4px;
}

.js .reveal {
  opacity: 0;
  translate: 0 2.6rem;
  transition: opacity 1s var(--ease), translate 1s var(--ease), clip-path 1.25s var(--ease);
}

.js .reveal--left {
  translate: -5rem 0;
}

.js .reveal--right {
  translate: 5rem 0;
}

.js .reveal--expand-left,
.js .reveal--expand-right {
  opacity: 1;
  translate: 0;
}

/* Keep the observed figure unclipped so its entrance can be detected. */
.js .reveal--expand-left .photo-button,
.js .reveal--expand-right .photo-button {
  transition: clip-path 1.25s var(--ease);
}

.js .reveal--expand-left .photo-button {
  clip-path: inset(0 100% 0 0);
}

.js .reveal--expand-right .photo-button {
  clip-path: inset(0 0 0 100%);
}

.js .reveal--expand-left.is-visible .photo-button,
.js .reveal--expand-right.is-visible .photo-button {
  clip-path: inset(0);
}

.js .reveal.is-visible {
  opacity: 1;
  translate: 0 0;
  clip-path: inset(0 0 0 0);
}

@media (max-width: 780px) {
  :root {
    --section-space: 6.5rem;
  }

  .page-shell {
    width: calc(100% - 2rem);
  }

  .music-toggle {
    grid-template-columns: 2.1rem 0.9rem;
    min-width: 0;
    padding: 0.38rem;
  }

  .music-disc {
    width: 2.1rem;
    height: 2.1rem;
  }

  .music-label {
    display: none;
  }

  .hero-media img {
    object-position: center 52%;
  }

  .hero-copy {
    margin-top: 36svh;
  }

  .hero h1 {
    flex-direction: column;
    gap: 0.12rem;
    font-size: clamp(2.55rem, 12vw, 4rem);
    line-height: 1.05;
  }

  .hero h1 b {
    margin-block: 0.2rem;
    font-size: 0.42em;
  }

  .hero-hello {
    font-size: 0.68rem;
  }

  .contact-profiles {
    gap: 0.65rem;
  }

  .contact-avatar {
    width: min(30vw, 7rem);
    border-width: 0.28rem;
  }

  .contact-role {
    font-size: 0.48rem;
    letter-spacing: 0.1em;
  }

  .contact-profile strong {
    font-size: 1.2rem;
  }

  .contact-cta {
    padding: 0.52rem 0.78rem;
    font-size: 0.62rem;
  }

  .countdown > div {
    min-height: 4.7rem;
  }

  .countdown-note {
    margin-top: -2rem;
  }

  .calendar-head {
    align-items: center;
  }

  .calendar-days {
    font-size: 0.72rem;
  }

  .venue-actions {
    grid-template-columns: 1fr;
  }

  .story-section {
    padding-block: clamp(3.5rem, 11vw, 5rem);
  }

  .story-inner {
    gap: clamp(2.25rem, 10vw, 3rem);
  }

  .story-heading h2 {
    margin-top: 1.4rem;
  }

  .story-heading p {
    margin-top: 1.25rem;
  }

  .story-photo--opening {
    width: calc(100% + 2rem);
    margin-left: -1rem;
  }

  .story-photo--opening figcaption {
    margin-inline: 1rem;
  }

  .love-layout {
    min-height: 0;
    padding-block: 0.5rem 2.5rem;
  }

  .story-photo--portrait {
    width: min(79%, 31rem);
  }

  .love-label {
    left: 0;
  }

  .line-art {
    right: 0;
    bottom: 0;
    font-size: 1.55rem;
  }

  .expand-story {
    grid-template-columns: 1fr;
    gap: 1.5rem;
  }

  .story-photo--bride {
    width: 86%;
  }

  .expand-story blockquote {
    padding-left: 1rem;
    border-left: 1px solid var(--red);
  }

  .ceremony-collage {
    display: grid;
    grid-template-columns: 44% minmax(0, 1fr);
    column-gap: 1rem;
    align-items: start;
    min-height: 0;
  }

  .story-photo--ceremony {
    grid-column: 1 / -1;
    grid-row: 1;
    width: 95%;
  }

  .story-photo--kiss {
    position: relative;
    grid-column: 1;
    grid-row: 2;
    width: 100%;
    margin-top: -2rem;
    padding: 0.4rem;
  }

  .ceremony-copy {
    position: static;
    grid-column: 2;
    grid-row: 2;
    align-self: center;
    font-size: 1.35rem;
  }

  .coast-copy {
    gap: 0.55rem;
    font-size: 0.66rem;
    letter-spacing: 0.08em;
  }

  .coast-copy i {
    width: 1rem;
  }

  .coast-collage {
    grid-template-columns: 1.08fr 0.92fr;
    gap: 0.7rem;
  }

  .coast-collage .story-photo:first-child {
    margin-top: 1rem;
  }

  .rsvp-card {
    grid-template-columns: 1fr;
  }

  .rsvp-intro {
    padding: 2.4rem 1.4rem;
    border-right: 0;
    border-bottom: 1px solid var(--line);
    text-align: center;
  }

  .rsvp-panel {
    min-height: 32rem;
    padding: 2.2rem 1.25rem;
  }

  .attendance-options {
    gap: 0.35rem;
  }

  .attendance-options span {
    font-size: 0.64rem;
  }

  footer {
    grid-template-columns: 1fr;
    padding-bottom: max(5.5rem, calc(env(safe-area-inset-bottom) + 5rem));
    text-align: center;
  }

  footer > a:last-child {
    justify-self: center;
  }

  .contact-modal {
    align-items: end;
    padding: 0;
  }

  .contact-sheet {
    width: 100%;
    max-height: calc(100svh - max(0.75rem, env(safe-area-inset-top)));
    padding: 1.55rem 1.2rem max(1.4rem, calc(env(safe-area-inset-bottom) + 1rem));
    border-radius: 1.25rem 1.25rem 0 0;
  }

  .lightbox-arrow {
    top: auto;
    bottom: max(1rem, env(safe-area-inset-bottom));
  }

  .lightbox-arrow--prev { left: calc(50% - 3.6rem); }
  .lightbox-arrow--next { right: calc(50% - 3.6rem); }

  .lightbox figure img {
    max-height: 76vh;
  }
}

@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }

  *,
  *::before,
  *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    scroll-behavior: auto !important;
    transition-duration: 0.01ms !important;
  }

  .js .reveal {
    opacity: 1;
    translate: 0 0;
    clip-path: none;
  }

  .js .reveal .photo-button {
    clip-path: none;
  }
}
