/* ==========================================================================
   Lanna Wedding Invitation Theme
   Contemporary Lanna Heritage Wedding Invitation Design System
   Based on Lanna Wedding Invitation Template with Full eCard Feature Parity
   ========================================================================== */

:root {
  /* Lanna Signature Palette */
  --ivory: #f4eddf;
  --paper: #eee3cf;
  --paper-deep: #ddccb0;
  --teak: #3a281f;
  --teak-light: #6a4936;
  --crimson: #6f2523;
  --crimson-dark: #491716;
  --gold: #c3a36a;
  --gold-soft: #d8c496;
  --forest: #354839;
  --ink: #2e2722;
  --muted: #756b61;
  --white: #fffaf0;

  /* Typography */
  --font-body:
    "Bai Jamjuree", -apple-system, BlinkMacSystemFont, "Sarabun", sans-serif;
  --font-display: "Pridi", "Fahkwang", Georgia, serif;
  --font-script: "Charmonman", "Charm", cursive;

  /* Elevation */
  --shadow: 0 28px 80px rgba(53, 31, 21, 0.18);
  --shadow-sm: 0 8px 24px rgba(53, 31, 21, 0.1);
  --shadow-lg: 0 36px 90px rgba(53, 31, 21, 0.25);

  /* Dynamic Customization Hooks */
  --ln-primary-color: var(--gold);
  --ln-secondary-color: var(--crimson-dark);
  --ln-user-header-font: var(--font-display);
  --ln-user-body-font: var(--font-body);
  --ln-body-size: 16px;
  --ln-header-size: 38px;
}

/* Base & Reset */
* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body.lanna-body {
  margin: 0;
  color: var(--ink);
  background: var(--ivory);
  font-family: var(--ln-user-body-font, var(--font-body));
  font-size: var(--ln-body-size, 16px);
  line-height: 1.75;
  overflow-x: hidden;
  position: relative;
  -webkit-font-smoothing: antialiased;
}

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

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

button,
input,
textarea,
select {
  font: inherit;
}

/* Layout Container */
.section-wrap {
  width: min(1160px, calc(100% - 64px));
  margin-inline: auto;
}

/* Paper Texture Pattern */
.paper-section {
  position: relative;
  background-color: var(--ivory);
  background-image: radial-gradient(
    rgba(91, 58, 38, 0.045) 0.8px,
    transparent 0.8px
  );
  background-size: 7px 7px;
}

/* Typography Utilities */
.section-label {
  margin: 0 0 12px;
  color: var(--crimson);
  font-size: 0.72rem;
  font-weight: 600;
  letter-spacing: 0.25em;
  text-transform: uppercase;
  font-family: var(--font-body);
}

.section-label.light {
  color: var(--gold-soft);
}

/* Buttons */
.button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 14px;
  min-height: 52px;
  padding: 0 26px;
  border: 1px solid var(--gold);
  border-radius: 0;
  color: var(--white);
  background: var(--crimson);
  font-size: 0.82rem;
  font-weight: 600;
  letter-spacing: 0.08em;
  cursor: pointer;
  transition:
    transform 0.25s ease,
    color 0.25s ease,
    background 0.25s ease,
    box-shadow 0.25s ease;
  font-family: var(--font-body);
}

.button:hover {
  transform: translateY(-2px);
  color: var(--teak);
  background: var(--gold-soft);
  box-shadow: 0 6px 20px rgba(58, 40, 31, 0.2);
}

.button-small {
  min-height: 42px;
  padding-inline: 20px;
}

.button-ivory {
  color: var(--crimson-dark);
  background: var(--ivory);
  border-color: var(--gold-soft);
}

.button-ivory:hover {
  color: var(--white);
  background: var(--crimson);
}

/* Woven Rail - Traditional Northern Woven Silk Stripe */
.woven-rail {
  position: fixed;
  z-index: 60;
  inset: 0 auto 0 0;
  width: 10px;
  background: repeating-linear-gradient(
    0deg,
    var(--crimson-dark) 0 12px,
    var(--gold) 12px 16px,
    var(--ivory) 16px 19px,
    var(--teak) 19px 31px,
    var(--gold) 31px 35px
  );
  box-shadow: 2px 0 8px rgba(0, 0, 0, 0.15);
}

/* Floating Site Header */
.site-header {
  position: fixed;
  z-index: 50;
  top: 20px;
  left: 50%;
  transform: translateX(-50%);
  width: min(1160px, calc(100% - 52px));
  min-height: 68px;
  padding: 0 14px 0 24px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  border: 1px solid rgba(255, 250, 240, 0.28);
  color: var(--white);
  background: rgba(50, 31, 24, 0.76);
  box-shadow: 0 14px 40px rgba(28, 15, 11, 0.22);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  transition: all 0.3s ease;
}

.wordmark {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font: 500 1.45rem var(--ln-user-header-font, var(--font-display));
  letter-spacing: 0.08em;
}

.wordmark-mark {
  display: grid;
  place-items: center;
  width: 34px;
  height: 34px;
  color: var(--gold-soft);
  border: 1px solid rgba(216, 196, 150, 0.5);
  font-family: serif;
  font-size: 1.1rem;
}

.desktop-nav {
  display: flex;
  align-items: center;
  gap: 24px;
  font-size: 0.88rem;
  font-family: var(--font-body);
  margin-left: auto;
}

.desktop-nav a:not(.button):hover {
  color: var(--gold-soft);
}

.header-actions {
  display: flex;
  align-items: center;
  gap: 12px;
}

.menu-button {
  display: none;
  width: 46px;
  height: 46px;
  padding: 13px;
  border: 0;
  color: var(--white);
  background: transparent;
  cursor: pointer;
}

.menu-button span {
  display: block;
  width: 100%;
  height: 1.5px;
  margin: 6px 0;
  background: currentColor;
  transition: 0.25s;
}

/* Audio Player Floating Button */
.audio-toggle-btn {
  width: 42px;
  height: 42px;
  display: inline-grid;
  place-items: center;
  border: 1px solid rgba(216, 196, 150, 0.45);
  background: rgba(58, 40, 31, 0.85);
  color: var(--gold-soft);
  border-radius: 50%;
  cursor: pointer;
  transition:
    transform 0.25s ease,
    background 0.25s ease,
    color 0.25s ease;
  font-size: 0.95rem;
}

.audio-toggle-btn:hover {
  transform: scale(1.08);
  background: var(--gold);
  color: var(--teak);
}

.audio-toggle-btn.is-playing {
  animation: pulse-gold 2s infinite;
}

@keyframes pulse-gold {
  0% {
    box-shadow: 0 0 0 0 rgba(216, 196, 150, 0.6);
  }
  70% {
    box-shadow: 0 0 0 12px rgba(216, 196, 150, 0);
  }
  100% {
    box-shadow: 0 0 0 0 rgba(216, 196, 150, 0);
  }
}

/* Hero Section */
.hero {
  position: relative;
  min-height: 100svh;
  display: flex;
  align-items: center;
  overflow: hidden;
  isolation: isolate;
  background: var(--teak);
}

.hero-image,
.hero-shade {
  position: absolute;
  inset: 0;
  z-index: -2;
}

.hero-image img {
  height: 100%;
  object-fit: cover;
  object-position: center 42%;
}

.hero-shade {
  z-index: -1;
  background:
    linear-gradient(
      90deg,
      rgba(28, 17, 13, 0.88) 0%,
      rgba(28, 17, 13, 0.62) 39%,
      rgba(28, 17, 13, 0.12) 70%
    ),
    linear-gradient(0deg, rgba(28, 17, 13, 0.55), transparent 55%);
}

.hero-copy {
  width: min(1160px, calc(100% - 64px));
  margin-inline: auto;
  padding: 140px 0 90px 44px;
  color: var(--white);
}

.kicker {
  margin: 0 0 20px;
  color: var(--gold-soft);
  font-size: 0.84rem;
  font-weight: 500;
  letter-spacing: 0.22em;
}

.hero h1,
.hero-couple-names {
  max-width: 760px;
  margin: 0;
  font: 400 clamp(3.4rem, 7.5vw, 6.2rem)/1.15
    var(--ln-user-header-font, var(--font-display));
  letter-spacing: -0.02em;
}

.hero h1 .hero-name-first,
.hero-name-first {
  display: block;
  line-height: 1.1;
  word-break: break-word;
}

.hero h1 .hero-amp-wrap,
.hero-amp-wrap {
  display: flex;
  align-items: baseline;
  gap: 0.28em;
  line-height: 1.1;
  margin-top: 0.08em;
  margin-left: 0.35em;
}

.hero h1 .hero-amp,
.hero-amp {
  color: var(--gold, #c3a36a);
  font-family: var(--font-script, "Charmonman"), cursive;
  font-size: 0.82em;
  font-weight: 400;
  font-style: normal;
  line-height: 1;
  flex-shrink: 0;
  position: static !important;
}

.hero h1 .hero-name-second,
.hero-name-second {
  display: inline-block;
  word-break: break-word;
}

.hero-note {
  margin: 26px 0 32px;
  font: 400 clamp(1.35rem, 2.2vw, 1.85rem) var(--font-script);
  color: var(--gold-soft);
  letter-spacing: 0.02em;
}

.hero-date {
  display: flex;
  flex-direction: column;
  gap: 3px;
  margin-bottom: 32px;
  padding-left: 20px;
  border-left: 2px solid var(--gold);
  font: 400 1.2rem var(--font-display);
}

.hero-date small {
  color: rgba(255, 250, 240, 0.75);
  font: 400 0.82rem var(--font-body);
  letter-spacing: 0.08em;
}

.hero-actions {
  display: flex;
  align-items: center;
  gap: 18px;
  flex-wrap: wrap;
}

.hero-seal {
  position: absolute;
  right: 6vw;
  bottom: 9vh;
  width: 122px;
  height: 122px;
  display: grid;
  place-content: center;
  text-align: center;
  color: var(--gold-soft);
  border: 1px solid rgba(216, 196, 150, 0.65);
  border-radius: 50%;
  transform: rotate(-8deg);
  background: rgba(46, 28, 20, 0.35);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
}

.hero-seal::before {
  content: "";
  position: absolute;
  inset: 7px;
  border: 1px dashed rgba(216, 196, 150, 0.45);
  border-radius: 50%;
}

.hero-seal span {
  font: 400 1.35rem var(--font-display);
}

.hero-seal small {
  font-size: 0.58rem;
  letter-spacing: 0.22em;
  text-transform: uppercase;
}

.scroll-hint {
  position: absolute;
  left: 28px;
  bottom: 28px;
  display: flex;
  align-items: center;
  gap: 12px;
  color: rgba(255, 250, 240, 0.65);
  font-size: 0.66rem;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  transform: rotate(-90deg);
  transform-origin: left center;
}

.scroll-hint span {
  width: 46px;
  height: 1px;
  background: var(--gold-soft);
}

/* Bride & Groom Couple Section */
.couple-section {
  padding: 130px 0;
  background: var(--ivory);
}

.couple-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: clamp(40px, 6vw, 70px);
  max-width: 980px;
  margin: 0 auto;
}

.couple-card {
  text-align: center;
  padding: 48px 36px 42px;
  background: var(--white);
  border-top: 5px solid var(--crimson);
  box-shadow: var(--shadow);
  position: relative;
  transition:
    transform 0.3s ease,
    box-shadow 0.3s ease;
  border: 1px solid rgba(195, 163, 106, 0.25);
}

.couple-card:hover {
  transform: translateY(-5px);
  box-shadow: var(--shadow-lg);
}

.couple-avatar-wrap {
  width: 210px;
  height: 210px;
  margin: 0 auto 26px;
  position: relative;
}

.couple-avatar-wrap img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  border-radius: 50%;
  border: 4px solid var(--gold-soft);
  box-shadow: 0 10px 28px rgba(58, 40, 31, 0.16);
}

.couple-avatar-wrap::after {
  content: "";
  position: absolute;
  inset: -8px;
  border: 1px dashed var(--gold);
  border-radius: 50%;
  pointer-events: none;
}

.couple-role-tag {
  display: inline-block;
  margin-bottom: 12px;
  padding: 4px 18px;
  font-size: 0.76rem;
  font-weight: 600;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--gold-soft);
  background: var(--crimson-dark);
}

.couple-card h3 {
  margin: 6px 0 8px;
  font: 400 2.2rem var(--ln-user-header-font, var(--font-display));
  color: var(--teak);
}

.couple-card .couple-fullname {
  color: var(--crimson);
  font-size: 0.98rem;
  font-weight: 500;
  margin: 0 0 14px;
}

.couple-card .couple-bio {
  color: var(--muted);
  font-size: 1rem;
  line-height: 1.7;
  margin: 0 0 18px;
}

.couple-card .couple-parents-sub {
  display: block;
  padding-top: 16px;
  border-top: 1px dashed rgba(195, 163, 106, 0.4);
  font-size: 0.88rem;
  color: var(--teak-light);
  line-height: 1.6;
}

.couple-card .couple-parents-sub strong {
  display: block;
  color: var(--crimson);
  font-size: 0.76rem;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  margin-bottom: 2px;
}

/* Welcome Section */
.welcome {
  padding: 130px 0;
}

.welcome-grid {
  display: grid;
  grid-template-columns: 0.78fr 1.22fr;
  gap: clamp(50px, 8vw, 120px);
  align-items: start;
}

.welcome-title {
  position: sticky;
  top: 130px;
}

.welcome-title h2,
.story-card h2,
.section-heading h2,
.venue-panel h2,
.dresscode h2,
.rsvp-intro h2,
.guestbook-wrap h2 {
  margin: 0;
  font: 400 clamp(2.8rem, 5.2vw, 4.8rem)/1.1
    var(--ln-user-header-font, var(--font-display));
  letter-spacing: -0.03em;
  color: var(--teak);
}

.welcome-copy {
  padding-top: 54px;
}

.welcome-copy p {
  max-width: 650px;
  color: var(--muted);
  font-size: 1.05rem;
}

.welcome-copy .lead {
  color: var(--ink);
  font: 300 clamp(1.25rem, 2vw, 1.65rem)/1.75 var(--font-display);
  margin-bottom: 24px;
}

.parents-note {
  margin: 32px 0 20px;
  padding: 24px;
  border-left: 3px solid var(--crimson);
  background: rgba(255, 250, 240, 0.65);
  border-radius: 0 8px 8px 0;
}

.parents-note h4 {
  margin: 0 0 10px;
  color: var(--crimson);
  font: 600 0.85rem var(--font-body);
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.parents-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 20px;
}

.parents-item p {
  margin: 0;
  font-size: 0.92rem;
  color: var(--ink);
}

.parents-item small {
  color: var(--muted);
  font-size: 0.8rem;
}

.couple-signature {
  margin-top: 36px;
  color: var(--crimson);
  font: 400 2.5rem var(--font-script);
}

/* Our Story Section */
.story {
  min-height: 780px;
  display: grid;
  grid-template-columns: 1.18fr 0.82fr;
  background: var(--paper-deep);
}

.story-photo {
  min-height: 780px;
  overflow: hidden;
}

.story-photo img {
  height: 100%;
  object-fit: cover;
  object-position: 57% 58%;
}

.story-card {
  align-self: center;
  margin-left: -90px;
  padding: clamp(46px, 7vw, 86px);
  background: var(--ivory);
  box-shadow: var(--shadow);
}

.story-card p {
  color: var(--muted);
  font-size: 1.05rem;
}

.story-card blockquote {
  margin: 38px 0 0;
  padding: 24px 0 0;
  border-top: 1px solid rgba(111, 37, 35, 0.25);
  color: var(--crimson);
  font: 400 1.55rem/1.85 var(--font-script);
}

/* Countdown Band */
.countdown-band {
  padding: 76px 0;
  color: var(--white);
  background: var(--crimson-dark);
  background-image: url(../../templates/images/countdown_background.png);
  background-size: cover;
  background-position: center;
  background-repeat: no-repeat;
  position: relative;
}

.countdown-layout {
  display: grid;
  grid-template-columns: 0.8fr 1.2fr;
  align-items: end;
  gap: 50px;
}

.countdown-layout h2 {
  margin: 0;
  color: var(--gold-soft);
  font: 400 clamp(2.6rem, 4vw, 3.8rem) var(--font-display);
}

.countdown-layout p.countdown-date-sub {
  margin: 8px 0 0;
  color: rgba(255, 250, 240, 0.75);
  font-size: 0.95rem;
}

.countdown {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  border-top: 1px solid rgba(216, 196, 150, 0.3);
  border-bottom: 1px solid rgba(216, 196, 150, 0.3);
}

.countdown div {
  padding: 18px 12px;
  text-align: center;
  border-left: 1px solid rgba(216, 196, 150, 0.25);
}

.countdown div:last-child {
  border-right: 1px solid rgba(216, 196, 150, 0.25);
}

.countdown strong {
  display: block;
  font: 300 clamp(2.4rem, 5vw, 4.3rem) var(--font-display);
  line-height: 1.1;
  color: var(--white);
}

.countdown span {
  color: var(--gold-soft);
  font-size: 0.72rem;
  letter-spacing: 0.12em;
}

/* Ceremony Schedule */
.ceremony {
  padding: 130px 0;
}

.section-heading {
  max-width: 720px;
  margin: 0 auto 66px;
  text-align: center;
}

.section-heading > p:last-child {
  color: var(--muted);
  font-size: 1.1rem;
}

.section-heading.light h2 {
  color: var(--white);
}

.section-heading.light > p:last-child {
  color: rgba(255, 250, 240, 0.75);
}

.schedule {
  max-width: 900px;
  margin-inline: auto;
}

.schedule-item {
  display: grid;
  grid-template-columns: 130px 1px 1fr;
  gap: 34px;
  min-height: 174px;
}

.schedule-item time {
  color: var(--crimson);
  font: 400 1.85rem var(--font-display);
  text-align: right;
  line-height: 1.2;
}

.schedule-line {
  position: relative;
  height: 100%;
  background: rgba(111, 37, 35, 0.22);
}

.schedule-line::before {
  content: "";
  position: absolute;
  top: 11px;
  left: 50%;
  width: 11px;
  height: 11px;
  border: 2px solid var(--gold);
  border-radius: 50%;
  background: var(--ivory);
  transform: translate(-50%, -50%);
}

.schedule-item small {
  color: var(--gold);
  font-weight: 600;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  font-size: 0.76rem;
}

.schedule-item h3 {
  margin: 4px 0 8px;
  font: 400 1.75rem var(--font-display);
  color: var(--teak);
}

.schedule-item p {
  margin: 0;
  color: var(--muted);
  font-size: 1rem;
}

/* Venue Section */
.venue {
  position: relative;
  min-height: 780px;
  display: flex;
  align-items: flex-end;
  isolation: isolate;
}

.venue-media {
  position: absolute;
  inset: 0;
  z-index: -2;
}

.venue-media img {
  height: 100%;
  object-fit: cover;
}

.venue::after {
  content: "";
  position: absolute;
  inset: 0;
  z-index: -1;
  background: linear-gradient(0deg, rgba(35, 20, 15, 0.72), transparent 68%);
}

.venue-panel {
  width: min(600px, calc(100% - 70px));
  margin: 0 0 70px max(6vw, 60px);
  padding: 48px;
  color: var(--white);
  background: rgba(57, 34, 25, 0.86);
  box-shadow: var(--shadow);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border: 1px solid rgba(216, 196, 150, 0.25);
}

.venue-panel h2 {
  color: var(--gold-soft);
  margin-bottom: 8px;
}

.venue-panel > p {
  color: rgba(255, 250, 240, 0.78);
  font-size: 1.05rem;
}

.venue-meta {
  display: flex;
  gap: 28px;
  margin: 28px 0;
  padding: 20px 0;
  border-block: 1px solid rgba(216, 196, 150, 0.28);
  color: var(--gold-soft);
  font-size: 0.84rem;
}

/* Dress Code Section */
.dresscode {
  padding: 120px 0;
}

.dresscode-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 80px;
  align-items: center;
}

.dresscode-copy p:last-child {
  max-width: 580px;
  color: var(--muted);
  font-size: 1.05rem;
}

.palette {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(60px, 1fr));
  min-height: 320px;
  overflow: hidden;
  box-shadow: var(--shadow);
  border: 1px solid rgba(195, 163, 106, 0.35);
}

.palette div {
  position: relative;
  background: var(--swatch);
  display: flex;
  align-items: flex-end;
  justify-content: center;
}

.palette span {
  position: absolute;
  left: 50%;
  bottom: 22px;
  font-size: 0.72rem;
  font-weight: 600;
  letter-spacing: 0.08em;
  transform: translateX(-50%) rotate(-90deg);
  transform-origin: center;
  white-space: nowrap;
}

/* Gallery Section */
.gallery {
  padding: 120px 24px 80px;
  color: var(--white);
  background: var(--teak);
  background-image: url(../../templates/images/lanna_background_gallery.png);
  background-repeat: no-repeat;
  background-size: cover;
  background-position: center;
}

.gallery .section-heading {
  margin-bottom: 48px;
}

.gallery-grid {
  display: grid;
  grid-template-columns: 1.1fr 0.9fr 0.7fr;
  grid-template-rows: 330px 330px;
  gap: 14px;
  max-width: 1160px;
  margin: 0 auto;
}

.gallery-grid figure {
  margin: 0;
  overflow: hidden;
  background: var(--teak-light);
  cursor: pointer;
  position: relative;
}

.gallery-grid figure:first-child {
  grid-row: 1 / 3;
}

.gallery-grid figure:nth-child(2) {
  grid-column: 2 / 4;
}

.gallery-grid img {
  height: 100%;
  object-fit: cover;
  transition:
    transform 0.6s ease,
    filter 0.6s ease;
}

.gallery-grid figure:hover img {
  transform: scale(1.045);
  filter: brightness(1.05);
}

.gallery-grid figure:nth-child(1) img {
  object-position: 58% 48%;
}

.gallery-grid figure:nth-child(3) img {
  object-position: 88% center;
}

.gallery-grid figure:nth-child(4) img {
  object-position: center;
}

/* Our Love Story Timeline (Dynamic Component) */
.timeline-section {
  padding: 120px 0;
}

.timeline-feed {
  position: relative;
  max-width: 860px;
  margin: 50px auto 0;
  padding: 20px 0;
}

.timeline-feed::before {
  content: "";
  position: absolute;
  top: 0;
  bottom: 0;
  left: 50%;
  width: 2px;
  background: rgba(111, 37, 35, 0.22);
  transform: translateX(-50%);
}

.timeline-item {
  position: relative;
  width: 50%;
  padding: 24px 40px;
  box-sizing: border-box;
}

.timeline-item.left {
  left: 0;
  text-align: right;
}

.timeline-item.right {
  left: 50%;
  text-align: left;
}

.timeline-item::after {
  content: "ᨣ";
  position: absolute;
  top: 32px;
  width: 28px;
  height: 28px;
  border-radius: 50%;
  background: var(--ivory);
  border: 2px solid var(--gold);
  color: var(--crimson);
  display: grid;
  place-items: center;
  font-size: 0.8rem;
  z-index: 10;
}

.timeline-item.left::after {
  right: -14px;
}

.timeline-item.right::after {
  left: -14px;
}

.timeline-card {
  padding: 28px;
  background: var(--white);
  border-top: 4px solid var(--crimson);
  box-shadow: var(--shadow-sm);
  transition: transform 0.3s ease;
}

.timeline-card:hover {
  transform: translateY(-4px);
}

.timeline-date {
  color: var(--crimson);
  font: 600 0.85rem var(--font-body);
  letter-spacing: 0.08em;
  margin-bottom: 6px;
}

.timeline-title {
  margin: 0 0 10px;
  font: 400 1.45rem var(--font-display);
  color: var(--teak);
}

.timeline-desc {
  margin: 0;
  color: var(--muted);
  font-size: 0.95rem;
}

.timeline-img {
  margin-top: 14px;
  border-radius: 0;
  max-height: 220px;
  object-fit: cover;
}

/* Video Section */
.video-section {
  padding: 100px 0;
  background: var(--paper-deep);
}

.video-wrapper {
  max-width: 920px;
  margin: 0 auto;
  aspect-ratio: 16 / 9;
  box-shadow: var(--shadow);
  border: 1px solid var(--gold);
  overflow: hidden;
  background: #000;
}

.video-wrapper iframe {
  width: 100%;
  height: 100%;
  border: 0;
}

/* Gift Registry / Banking Info */
.gift-section {
  padding: 100px 0;
}

.gift-card {
  max-width: 680px;
  margin: 0 auto;
  padding: 48px;
  text-align: center;
  background: var(--white);
  border-top: 5px solid var(--gold);
  box-shadow: var(--shadow);
}

.gift-card h3 {
  font: 400 1.9rem var(--font-display);
  margin: 0 0 12px;
  color: var(--teak);
}

.gift-qr {
  max-width: 220px;
  margin: 24px auto;
  padding: 14px;
  background: var(--white);
  border: 1px solid var(--gold-soft);
  box-shadow: 0 4px 16px rgba(0, 0, 0, 0.06);
}

.bank-details {
  display: inline-block;
  text-align: left;
  margin-top: 16px;
  padding: 16px 24px;
  background: var(--ivory);
  border-left: 3px solid var(--crimson);
}

/* RSVP Section */
.rsvp {
  padding: 130px 0;
}

.rsvp-grid {
  display: grid;
  grid-template-columns: 0.85fr 1.15fr;
  gap: clamp(55px, 9vw, 120px);
}

.rsvp-intro {
  position: relative;
}

.rsvp-intro > p:nth-of-type(2) {
  color: var(--muted);
  font-size: 1.05rem;
}

.rsvp-ornament {
  position: absolute;
  right: 15%;
  bottom: -40px;
  color: rgba(111, 37, 35, 0.08);
  font: 400 12rem/1 serif;
  pointer-events: none;
}

.rsvp-form {
  padding: 48px;
  border-top: 5px solid var(--crimson);
  background: var(--white);
  box-shadow: var(--shadow);
}

.form-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 22px;
}

.form-field {
  margin-bottom: 22px;
}

.form-field label {
  display: block;
  margin-bottom: 6px;
  color: var(--crimson);
  font-size: 0.76rem;
  font-weight: 600;
  letter-spacing: 0.08em;
}

.form-field input,
.form-field select,
.form-field textarea {
  width: 100%;
  padding: 13px 0;
  border: 0;
  border-bottom: 1px solid rgba(58, 40, 31, 0.3);
  border-radius: 0;
  outline: none;
  color: var(--ink);
  background: transparent;
  font-family: var(--font-body);
  transition: border-color 0.25s ease;
}

.form-field input:focus,
.form-field select:focus,
.form-field textarea:focus {
  border-color: var(--ln-primary-color, var(--crimson));
}

.rsvp-side-group {
  margin-bottom: 22px;
}

.rsvp-side-label-title {
  display: block;
  margin-bottom: 8px;
  color: var(--ln-primary-color, var(--crimson));
  font-size: 0.76rem;
  font-weight: 600;
  letter-spacing: 0.08em;
}

.rsvp-side-options {
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
}

.rsvp-side-btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 10px 18px;
  border: 1px solid rgba(58, 40, 31, 0.25);
  background: var(--ivory);
  font-size: 0.88rem;
  cursor: pointer;
  transition: all 0.2s ease;
  user-select: none;
}

.rsvp-side-btn input[type="radio"] {
  accent-color: var(--ln-primary-color, var(--crimson));
  margin: 0;
}

.rsvp-side-btn:has(input:checked) {
  border-color: var(--ln-primary-color, var(--crimson));
  background: var(--white);
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
  font-weight: 600;
  color: var(--ln-primary-color, var(--crimson));
}

.form-success {
  display: none;
  margin: 18px 0 0;
  padding: 14px 18px;
  color: #244331;
  background: #e6efe7;
  font-size: 0.9rem;
  border-left: 3px solid #244331;
}

.form-success.show {
  display: block;
}

/* Digital Guestbook Section (Modal & Status Card integration) */
.guestbook-section {
  padding: 120px 0;
  background: var(--paper);
}

.guestbook-status-card {
  background-image: url(../../templates/images/lanna_background_guestbook.png) !important;
  background-repeat: no-repeat;
  background-size: cover;
  background-position: center bottom !important;
  background-attachment: fixed;
}

.guestbook-wrap {
  max-width: 820px;
  margin: 0 auto;
}

.guestbook-form-card {
  max-width: 760px;
  margin: 0 auto 36px auto;
  padding: 48px;
  background: var(--white);
  border-top: 5px solid var(--crimson);
  box-shadow: var(--shadow);
}

@media (max-width: 768px) {
  .guestbook-form-card {
    padding: 28px 20px;
  }
}

/* Guestbook Modal Theming for Lanna */
.gb-status-card {
  background: var(--white) !important;
  border: 1px solid var(--gold-soft) !important;
  border-top: 4px solid var(--crimson) !important;
  box-shadow: var(--shadow) !important;
  border-radius: 0 !important;
}

.gb-status-btn {
  background: var(--crimson) !important;
  color: var(--white) !important;
  border-radius: 0 !important;
  border: 1px solid var(--gold) !important;
  font-family: var(--font-body) !important;
  font-weight: 600 !important;
  transition: all 0.25s ease !important;
}

.gb-status-btn:hover {
  background: var(--gold-soft) !important;
  color: var(--teak) !important;
  transform: translateY(-2px) !important;
}

.gb-modal-dialog {
  border-radius: 0 !important;
  background: var(--ivory) !important;
  border: 1px solid var(--gold) !important;
}

.gb-modal-header {
  background: var(--crimson-dark) !important;
  color: var(--white) !important;
  border-bottom: 2px solid var(--gold) !important;
}

.gb-modal-header h3 {
  font-family: var(--font-display) !important;
  color: var(--gold-soft) !important;
}

.gb-card-item {
  background: var(--white) !important;
  border: 1px solid rgba(195, 163, 106, 0.25) !important;
  border-radius: 0 !important;
}

/* Footer */
footer {
  padding: 65px 24px 108px;
  text-align: center;
  color: var(--gold-soft);
  background: var(--crimson-dark);
  background-image: url(../../templates/images/lanna_background.png);
}

.footer-mark {
  font: 400 3.2rem serif;
  margin-bottom: 8px;
  color: var(--gold);
}

footer p {
  margin: 4px 0;
  color: var(--white);
  font: 400 2.2rem var(--font-display);
}

footer p i {
  color: var(--gold);
  font: 400 1em var(--font-script);
  font-style: normal;
  margin-inline: 4px;
}

footer small {
  color: rgba(255, 250, 240, 0.65);
  font-size: 0.88rem;
  letter-spacing: 0.06em;
}

/* Mobile Bottom Navigation Bar */
.mobile-nav {
  display: none;
}

/* Reveal Scroll Animation */
.reveal {
  opacity: 0;
  transform: translateY(24px);
  transition:
    opacity 0.8s ease,
    transform 0.8s ease;
}

.reveal.visible {
  opacity: 1;
  transform: none;
}

/* ==========================================================================
   Responsive Breakpoints
   ========================================================================== */

@media (max-width: 900px) {
  body.lanna-body {
    padding-bottom: 76px;
  }

  .woven-rail {
    width: 5px;
  }

  .section-wrap {
    width: min(100% - 32px, 700px);
  }

  .site-header {
    top: 12px;
    width: calc(100% - 28px);
    min-height: 60px;
    padding: 0 8px 0 14px;
  }

  .desktop-nav {
    position: absolute;
    top: 72px;
    left: 0;
    right: 0;
    margin-left: 0;
    padding: 18px 24px;
    display: flex;
    flex-direction: column;
    align-items: stretch;
    gap: 0;
    color: var(--ink);
    background: rgba(255, 250, 240, 0.98);
    box-shadow: var(--shadow);
    opacity: 0;
    visibility: hidden;
    transform: translateY(-10px);
    transition: 0.25s;
    border: 1px solid var(--gold);
  }

  .desktop-nav.open {
    opacity: 1;
    visibility: visible;
    transform: none;
  }

  .desktop-nav a {
    padding: 12px;
    text-align: center;
    border-bottom: 1px solid rgba(58, 40, 31, 0.08);
  }

  .desktop-nav a:last-child {
    border-bottom: 0;
  }

  .desktop-nav .button {
    color: var(--white);
    margin-top: 10px;
  }

  .menu-button {
    display: block;
  }

  .menu-button.open span:first-child {
    transform: translateY(3.5px) rotate(45deg);
  }

  .menu-button.open span:last-child {
    transform: translateY(-3.5px) rotate(-45deg);
  }

  .hero {
    min-height: 880px;
    align-items: flex-end;
  }

  .hero-image img {
    object-position: 58% center;
  }

  .hero-shade {
    background: linear-gradient(
      0deg,
      rgba(30, 18, 14, 0.92) 0%,
      rgba(30, 18, 14, 0.35) 68%,
      rgba(30, 18, 14, 0.12)
    );
  }

  .hero-copy {
    width: calc(100% - 36px);
    padding: 0 0 60px;
    text-align: center;
  }

  .kicker {
    font-size: 0.74rem;
  }

  .hero h1,
  .hero-couple-names {
    margin-inline: auto;
    font-size: clamp(3rem, 13vw, 4.8rem);
  }

  .hero h1 .hero-amp-wrap,
  .hero-amp-wrap {
    justify-content: center;
    margin-left: 0;
  }

  .hero-date {
    align-items: center;
    padding: 14px 0 0;
    border-left: 0;
    border-top: 1px solid rgba(195, 163, 106, 0.55);
  }

  .hero-actions {
    justify-content: center;
  }

  .hero-seal,
  .scroll-hint {
    display: none;
  }

  .couple-section,
  .welcome,
  .ceremony,
  .dresscode,
  .rsvp,
  .timeline-section,
  .guestbook-section {
    padding: 84px 0;
  }

  .couple-grid {
    grid-template-columns: 1fr;
    gap: 32px;
  }

  .couple-avatar-wrap {
    width: 170px;
    height: 170px;
  }

  .welcome-grid,
  .story,
  .countdown-layout,
  .dresscode-grid,
  .rsvp-grid {
    grid-template-columns: 1fr;
  }

  .welcome-title {
    position: static;
    text-align: center;
  }

  .welcome-copy {
    padding-top: 0;
    text-align: center;
  }

  .welcome-copy p {
    margin-inline: auto;
  }

  .parents-grid {
    grid-template-columns: 1fr;
    gap: 14px;
    text-align: left;
  }

  .story {
    min-height: 0;
    padding-bottom: 58px;
  }

  .story-photo {
    min-height: 540px;
  }

  .story-card {
    width: calc(100% - 32px);
    margin: -80px auto 0;
    padding: 42px 28px;
  }

  .countdown-layout {
    gap: 28px;
    text-align: center;
  }

  .countdown {
    width: 100%;
  }

  .schedule-item {
    grid-template-columns: 86px 1px 1fr;
    gap: 22px;
  }

  .schedule-item time {
    font-size: 1.5rem;
  }

  .venue {
    min-height: 720px;
    align-items: flex-end;
  }

  .venue-media img {
    object-position: 49% center;
  }

  .venue-panel {
    width: calc(100% - 32px);
    margin: 0 auto 24px;
    padding: 36px 26px;
  }

  .dresscode-grid {
    gap: 45px;
    text-align: center;
  }

  .dresscode-copy p:last-child {
    margin-inline: auto;
  }

  .palette {
    min-height: 250px;
  }

  .gallery {
    padding: 86px 16px 40px;
  }

  .gallery-grid {
    grid-template-columns: 1fr 1fr;
    grid-template-rows: 320px 180px 180px;
  }

  .gallery-grid figure:first-child {
    grid-column: 1 / 3;
    grid-row: auto;
  }

  .gallery-grid figure:nth-child(2) {
    grid-column: auto;
  }

  /* Timeline on mobile */
  .timeline-feed::before {
    left: 20px;
  }

  .timeline-item {
    width: 100%;
    padding-left: 54px;
    padding-right: 0;
    text-align: left !important;
  }

  .timeline-item.right {
    left: 0;
  }

  .timeline-item::after {
    left: 8px !important;
    right: auto !important;
  }

  .rsvp-ornament {
    display: none;
  }

  .mobile-nav {
    position: fixed;
    z-index: 70;
    left: 9px;
    right: 9px;
    bottom: 9px;
    height: 66px;
    padding: 6px 8px;
    display: grid;
    grid-template-columns: repeat(5, 1fr);
    border: 1px solid rgba(195, 163, 106, 0.35);
    color: var(--teak);
    background: rgba(255, 250, 240, 0.94);
    box-shadow: 0 12px 36px rgba(42, 25, 18, 0.2);
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
  }

  .mobile-nav a {
    display: grid;
    place-items: center;
    gap: 2px;
    font-size: 0.62rem;
    text-align: center;
    font-family: var(--font-body);
  }

  .mobile-nav span {
    display: block;
    color: var(--crimson);
    font-size: 1.15rem;
    line-height: 1;
  }

  footer {
    padding-bottom: 40px;
  }
}

@media (max-width: 520px) {
  .hero {
    min-height: 820px;
  }

  .hero-copy {
    padding-bottom: 38px;
  }

  .hero-note {
    font-size: 1.15rem;
  }

  .story-photo {
    min-height: 460px;
  }

  .countdown strong {
    font-size: 2.1rem;
  }

  .countdown div {
    padding-inline: 4px;
  }

  .countdown span {
    font-size: 0.62rem;
    letter-spacing: 0.04em;
  }

  .schedule-item {
    grid-template-columns: 66px 1px 1fr;
    gap: 16px;
  }

  .schedule-item time {
    font-size: 1.25rem;
  }

  .venue-meta {
    flex-direction: column;
    gap: 6px;
  }

  .palette {
    min-height: 220px;
  }

  .form-row {
    grid-template-columns: 1fr;
    gap: 0;
  }

  .rsvp-form {
    padding: 34px 22px;
  }
}

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

  *,
  *::before,
  *::after {
    transition: none !important;
  }

  .reveal {
    opacity: 1;
    transform: none;
  }
}
