/* ============================================================================
   Praise & December — Marriage Covenant
   STYLES.CSS
   Palette drawn from the original invitation artwork:
   warm ivory & cream, blush pink, sage green, dusty rose, golden tan,
   brown charcoal.
   ========================================================================== */

/* ---------------------------------- 1. Tokens & reset ------------------- */

:root {
  --ivory: #fdf6ec;
  --ivory-deep: #faeee0;
  --cream: #fef9f1;
  --blush: #f8e9e5;
  --blush-deep: #f1d9d5;
  --rose: #c89a92;
  --rose-deep: #a9736b;
  --sage: #93a585;
  --sage-deep: #67795e;
  --gold: #c6a063;
  --gold-deep: #8a6c3c;
  --gold-soft: #b08d57;
  --tan: #e4cab3;
  --charcoal: #3a332c;
  --ink: #2c2620;
  --muted: #6e6459;
  --line: rgba(90, 75, 63, 0.18);
  --line-soft: rgba(90, 75, 63, 0.1);

  --font-script: "Great Vibes", "Snell Roundhand", "Apple Chancery", cursive;
  --font-serif: "EB Garamond", "Cormorant Garamond", Georgia, "Times New Roman", serif;

  --shadow-soft: 0 18px 44px -26px rgba(58, 51, 44, 0.4);
  --shadow-lift: 0 26px 54px -28px rgba(58, 51, 44, 0.45);
  --radius: 18px;
  --nav-h: 72px;
  --ease-out: cubic-bezier(0.22, 0.61, 0.36, 1);
}

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

html {
  -webkit-text-size-adjust: 100%;
}

@media (prefers-reduced-motion: no-preference) {
  html {
    scroll-behavior: smooth;
  }
}

body {
  margin: 0;
  font-family: var(--font-serif);
  font-size: 1.125rem;
  line-height: 1.7;
  color: var(--charcoal);
  background: var(--ivory);
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

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

h1, h2, h3, p, blockquote, figure, fieldset {
  margin: 0;
}

a {
  color: var(--gold-deep);
}

::selection {
  background: var(--blush-deep);
  color: var(--ink);
}

:focus-visible {
  outline: 2px solid var(--gold-deep);
  outline-offset: 3px;
  border-radius: 4px;
}

.skip-link {
  position: absolute;
  top: -60px;
  left: 16px;
  z-index: 200;
  padding: 0.6rem 1.2rem;
  background: var(--charcoal);
  color: var(--cream);
  text-decoration: none;
  border-radius: 0 0 10px 10px;
  transition: top 0.25s ease;
}

.skip-link:focus {
  top: 0;
}

/* ---------------------------------- 2. Layout helpers -------------------- */

.container {
  width: min(1120px, 100% - clamp(2rem, 8vw, 6rem));
  margin-inline: auto;
}

.container--narrow {
  width: min(680px, 100% - clamp(2rem, 8vw, 6rem));
}

.center {
  text-align: center;
}

.section {
  position: relative;
  padding: clamp(4.5rem, 10vw, 8rem) 0;
  scroll-margin-top: calc(var(--nav-h) - 4px);
  overflow: hidden;
}

.section--ivory {
  background:
    radial-gradient(rgba(120, 100, 80, 0.05) 1px, transparent 1.4px),
    var(--ivory);
  background-size: 30px 30px, auto;
}

.section--blush {
  background:
    radial-gradient(rgba(169, 115, 107, 0.05) 1px, transparent 1.4px),
    var(--blush);
  background-size: 30px 30px, auto;
}

.eyebrow {
  font-size: 0.82rem;
  font-weight: 600;
  letter-spacing: 0.34em;
  text-transform: uppercase;
  color: var(--gold-deep);
  margin-bottom: 0.9rem;
}

.section-title {
  font-family: var(--font-serif);
  font-weight: 500;
  font-size: clamp(2.1rem, 4.6vw, 3.3rem);
  line-height: 1.15;
  letter-spacing: 0.01em;
  color: var(--ink);
  margin-bottom: 1rem;
}

.section-lead {
  max-width: 46ch;
  margin-inline: auto;
  color: var(--muted);
  font-size: clamp(1.05rem, 1.8vw, 1.2rem);
}

/* ---------------------------------- 3. Buttons & links ------------------- */

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  font-family: var(--font-serif);
  font-size: 0.85rem;
  font-weight: 600;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  text-decoration: none;
  padding: 1rem 2.3rem;
  border-radius: 999px;
  border: 1px solid transparent;
  cursor: pointer;
  transition: transform 0.3s var(--ease-out), background-color 0.3s ease,
    color 0.3s ease, border-color 0.3s ease, box-shadow 0.3s ease;
}

.btn--primary {
  background: var(--charcoal);
  color: var(--cream);
  box-shadow: var(--shadow-soft);
}

.btn--primary:hover {
  background: var(--gold-deep);
  transform: translateY(-2px);
}

.btn--ghost {
  background: rgba(254, 249, 241, 0.72);
  border-color: rgba(58, 51, 44, 0.38);
  color: var(--charcoal);
}

.btn--ghost:hover {
  background: var(--cream);
  border-color: var(--charcoal);
  transform: translateY(-2px);
}

.btn:active {
  transform: translateY(0);
}

.text-link {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  margin-top: 0.9rem;
  font-size: 0.86rem;
  font-weight: 600;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--gold-deep);
  text-decoration: none;
  border-bottom: 1px solid rgba(138, 108, 60, 0.4);
  padding-bottom: 2px;
  transition: color 0.25s ease, border-color 0.25s ease;
}

.text-link svg {
  width: 0.95em;
  height: 0.95em;
  transition: transform 0.25s var(--ease-out);
}

.text-link:hover {
  color: var(--rose-deep);
  border-color: var(--rose-deep);
}

.text-link:hover svg {
  transform: translate(2px, -2px);
}

.pill {
  display: inline-block;
  font-size: 0.72rem;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  padding: 0.3rem 0.85rem;
  border-radius: 999px;
  background: rgba(198, 160, 99, 0.16);
  border: 1px solid rgba(138, 108, 60, 0.35);
  color: var(--gold-deep);
}

/* ---------------------------------- 4. Header / nav ---------------------- */

.site-header {
  position: fixed;
  inset: 0 0 auto 0;
  z-index: 90;
  background: rgba(253, 246, 236, 0.9);
  border-bottom: 1px solid transparent;
  transition: background-color 0.4s ease, border-color 0.4s ease,
    box-shadow 0.4s ease;
}

@supports ((backdrop-filter: blur(8px)) or (-webkit-backdrop-filter: blur(8px))) {
  .site-header {
    -webkit-backdrop-filter: blur(10px);
    backdrop-filter: blur(10px);
    background: rgba(253, 246, 236, 0.78);
  }
}

.site-header.is-scrolled {
  background: rgba(253, 246, 236, 0.95);
  border-bottom-color: var(--line-soft);
  box-shadow: 0 12px 30px -24px rgba(58, 51, 44, 0.6);
}

.nav {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: var(--nav-h);
  padding-inline: clamp(1.1rem, 4vw, 2.75rem);
}

.brand {
  font-family: var(--font-script);
  font-size: 1.85rem;
  line-height: 1;
  color: var(--ink);
  text-decoration: none;
  letter-spacing: 0.02em;
}

.brand-amp {
  color: var(--gold-deep);
}

.nav-links {
  display: flex;
  align-items: center;
  gap: clamp(0.9rem, 2.2vw, 1.9rem);
  list-style: none;
  margin: 0;
  padding: 0;
}

.nav-links a {
  position: relative;
  display: inline-block;
  padding: 0.4rem 0.15rem;
  font-size: 0.78rem;
  font-weight: 600;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--charcoal);
  text-decoration: none;
}

.nav-links a::after {
  content: "";
  position: absolute;
  left: 0;
  right: 100%;
  bottom: 0;
  height: 1px;
  background: var(--gold-deep);
  transition: right 0.35s var(--ease-out);
}

.nav-links a:hover::after,
.nav-links a.is-active::after {
  right: 0;
}

.nav-toggle {
  display: none;
  flex-direction: column;
  justify-content: center;
  gap: 5px;
  width: 44px;
  height: 44px;
  padding: 10px;
  background: none;
  border: 1px solid var(--line);
  border-radius: 10px;
  cursor: pointer;
}

.nav-toggle-bar {
  display: block;
  height: 1.6px;
  width: 100%;
  background: var(--charcoal);
  border-radius: 2px;
  transition: transform 0.35s var(--ease-out), opacity 0.25s ease;
}

.nav-toggle[aria-expanded="true"] .nav-toggle-bar:nth-child(1) {
  transform: translateY(6.6px) rotate(45deg);
}

.nav-toggle[aria-expanded="true"] .nav-toggle-bar:nth-child(2) {
  opacity: 0;
}

.nav-toggle[aria-expanded="true"] .nav-toggle-bar:nth-child(3) {
  transform: translateY(-6.6px) rotate(-45deg);
}

body.nav-open {
  overflow: hidden;
}

/* ---------------------------------- 5. Hero ------------------------------ */

.hero {
  position: relative;
  display: flex;
  align-items: center;
  min-height: 100vh;
  min-height: 100svh;
  padding: calc(var(--nav-h) + 2.5rem) 0 4.5rem;
  animation: heroFade 1.2s ease both;
}

@keyframes heroFade {
  from { opacity: 0; }
  to { opacity: 1; }
}

.hero-visual {
  position: absolute;
  inset: 0;
  z-index: 0;
  overflow: hidden;
  background: linear-gradient(135deg, #e9c79a 0%, #f7e6d0 45%, #fdf6ec 100%);
}

.hero-visual picture,
.hero-img {
  width: 100%;
  height: 100%;
}

.hero-img {
  object-fit: cover;
  object-position: 22% center;
  animation: heroZoom 30s ease-in-out infinite alternate;
  will-change: transform;
}

@keyframes heroZoom {
  from { transform: scale(1); }
  to { transform: scale(1.055); }
}

/* graceful fallback if the artwork ever fails to load */
.hero-visual.is-missing .hero-img,
.hero-visual.is-missing picture {
  opacity: 0;
}

.hero-scrim {
  position: absolute;
  inset: 0;
  background: linear-gradient(
    90deg,
    rgba(253, 246, 236, 0) 26%,
    rgba(253, 246, 236, 0.55) 46%,
    rgba(253, 246, 236, 0.92) 62%,
    rgba(253, 246, 236, 0.97) 100%
  );
}

.hero-light {
  position: absolute;
  border-radius: 50%;
  pointer-events: none;
  filter: blur(14px);
}

.hero-light--one {
  top: -8%;
  right: 6%;
  width: 44vmax;
  height: 44vmax;
  background: radial-gradient(circle, rgba(255, 243, 220, 0.5), transparent 65%);
  animation: lightDrift 19s ease-in-out infinite alternate;
}

.hero-light--two {
  bottom: -14%;
  left: 26%;
  width: 38vmax;
  height: 38vmax;
  background: radial-gradient(circle, rgba(248, 224, 218, 0.42), transparent 68%);
  animation: lightDrift 24s ease-in-out infinite alternate-reverse;
}

@keyframes lightDrift {
  from { transform: translate3d(0, 0, 0) scale(1); opacity: 0.85; }
  to { transform: translate3d(-4%, 3%, 0) scale(1.08); opacity: 1; }
}

.hero-body {
  position: relative;
  z-index: 3;
  width: 100%;
  display: grid;
  grid-template-columns: 1fr minmax(420px, 620px);
  padding-inline: clamp(1.25rem, 5vw, 4.5rem);
}

.hero-panel {
  grid-column: 2;
  text-align: center;
  padding: clamp(2rem, 4vw, 3.2rem) clamp(1.5rem, 3.5vw, 3rem);
  border: 1px solid rgba(176, 141, 87, 0.35);
  border-radius: 4px;
  background: rgba(253, 246, 236, 0.6);
  box-shadow: 0 30px 70px -40px rgba(58, 51, 44, 0.45);
  outline: 1px solid rgba(176, 141, 87, 0.18);
  outline-offset: 7px;
}

@supports ((backdrop-filter: blur(6px)) or (-webkit-backdrop-filter: blur(6px))) {
  .hero-panel {
    -webkit-backdrop-filter: blur(5px);
    backdrop-filter: blur(5px);
  }
}

.hero-eyebrow {
  font-size: clamp(0.68rem, 1.4vw, 0.8rem);
  font-weight: 600;
  letter-spacing: 0.3em;
  text-transform: uppercase;
  color: var(--gold-deep);
}

.hero-lead {
  margin-top: 1.3rem;
  font-size: clamp(1.05rem, 2vw, 1.3rem);
  font-style: italic;
  color: var(--muted);
}

.hero-title {
  margin-top: 0.35rem;
  font-family: var(--font-serif);
  font-weight: 500;
  font-size: clamp(2.2rem, 4.6vw, 3.5rem);
  line-height: 1.08;
  letter-spacing: 0.015em;
  color: var(--ink);
}

.hero-names {
  display: flex;
  flex-direction: column;
  align-items: center;
  margin-top: clamp(0.9rem, 2vw, 1.5rem);
}

.hero-name {
  font-family: var(--font-script);
  font-size: clamp(3.4rem, 8.4vw, 5.6rem);
  line-height: 0.98;
  color: var(--ink);
  background: linear-gradient(120deg, #4a3f33 0%, #8a6c3c 52%, #4a3f33 100%);
  -webkit-background-clip: text;
  background-clip: text;
}

@supports not ((-webkit-background-clip: text) or (background-clip: text)) {
  .hero-name { color: var(--ink); background: none; }
}

.hero-amp {
  position: relative;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-family: var(--font-script);
  font-size: clamp(2rem, 4vw, 2.8rem);
  line-height: 1;
  color: var(--gold-deep);
  margin: 0.15rem 0;
}

.hero-heart {
  position: absolute;
  top: -0.85em;
  left: 50%;
  width: 1.05em;
  height: 1.05em;
  margin-left: -0.52em;
  fill: var(--rose);
  opacity: 0.9;
  animation: heartFloat 3.6s ease-in-out infinite alternate;
}

@keyframes heartFloat {
  from { transform: translateY(0) scale(1); }
  to { transform: translateY(-7px) scale(1.05); }
}

.hero-meta {
  margin-top: 1.4rem;
  font-size: 0.95rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--muted);
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 0.85rem;
  margin-top: 1.8rem;
}

/* staged entrance for hero children */
.anim {
  opacity: 0;
  animation: riseIn 1s var(--ease-out) both;
  animation-delay: var(--d, 0s);
}

@keyframes riseIn {
  from { opacity: 0; transform: translateY(26px); }
  to { opacity: 1; transform: translateY(0); }
}

.scroll-cue {
  position: absolute;
  z-index: 3;
  left: 50%;
  bottom: 1.6rem;
  transform: translateX(-50%);
  display: flex;
  align-items: center;
  justify-content: center;
  width: 44px;
  height: 44px;
  border-radius: 50%;
  background: rgba(253, 246, 236, 0.85);
  border: 1px solid rgba(176, 141, 87, 0.4);
  color: var(--gold-deep);
  text-decoration: none;
}

.scroll-cue svg {
  width: 20px;
  height: 20px;
  animation: cueBob 2.2s ease-in-out infinite;
}

@keyframes cueBob {
  0%, 100% { transform: translateY(-2px); }
  50% { transform: translateY(3px); }
}

/* ---------------------------------- 6. Petals ---------------------------- */

.petals {
  position: absolute;
  inset: 0;
  z-index: 2;
  overflow: hidden;
  pointer-events: none;
  contain: strict;
}

.petal {
  position: absolute;
  top: -8vh;
  left: var(--x);
  width: var(--s);
  height: calc(var(--s) * 1.35);
  background: linear-gradient(135deg, var(--c1), var(--c2));
  border-radius: 70% 30% 62% 38% / 58% 42% 58% 42%;
  opacity: var(--o);
  animation: petalFall var(--dur) linear var(--delay) infinite;
  will-change: transform;
}

@keyframes petalFall {
  0% { transform: translate3d(0, -10vh, 0) rotate(0deg); }
  25% { transform: translate3d(var(--dx1), 28vh, 0) rotate(140deg); }
  50% { transform: translate3d(var(--dx2), 58vh, 0) rotate(280deg); }
  75% { transform: translate3d(var(--dx1), 88vh, 0) rotate(420deg); }
  100% { transform: translate3d(var(--dx2), 118vh, 0) rotate(560deg); }
}

/* ---------------------------------- 7. Ornament / verse / sprigs --------- */

.ornament {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 1rem;
  color: var(--gold-soft);
  margin-bottom: 2.2rem;
}

.ornament-line {
  width: clamp(48px, 12vw, 110px);
  height: 1px;
  background: linear-gradient(90deg, transparent, var(--gold-soft));
}

.ornament-line:last-child {
  background: linear-gradient(90deg, var(--gold-soft), transparent);
}

.ornament-mark {
  width: 34px;
  height: 34px;
  flex: none;
}

.verse {
  max-width: 720px;
  margin-inline: auto;
}

.verse-text {
  font-family: var(--font-serif);
  font-style: italic;
  font-weight: 500;
  font-size: clamp(1.6rem, 3.6vw, 2.6rem);
  line-height: 1.35;
  color: var(--ink);
}

.verse-cite {
  display: block;
  margin-top: 1.1rem;
  font-style: normal;
  font-size: 0.86rem;
  font-weight: 600;
  letter-spacing: 0.3em;
  text-transform: uppercase;
  color: var(--gold-deep);
}

.verse--mini .verse-text {
  font-size: clamp(1.25rem, 2.6vw, 1.7rem);
}

.sprig {
  position: absolute;
  width: clamp(130px, 20vw, 230px);
  height: auto;
  color: var(--sage);
  opacity: 0.5;
  pointer-events: none;
}

.sprig--tl {
  top: clamp(1rem, 3vw, 2.5rem);
  left: clamp(-1.2rem, -1vw, 0);
}

.sprig--br {
  bottom: clamp(1rem, 3vw, 2.5rem);
  right: clamp(-1.2rem, -1vw, 0);
}

.sway {
  transform-origin: 20% 80%;
  animation: sway 8s ease-in-out infinite alternate;
}

.sprig--br.sway {
  transform-origin: 80% 20%;
  animation-duration: 10s;
}

@keyframes sway {
  from { transform: rotate(-1.6deg); }
  to { transform: rotate(1.8deg); }
}

/* ---------------------------------- 8. Three-strand cord ----------------- */

.cord {
  margin-top: clamp(2.2rem, 5vw, 3.5rem);
}

.cord-img {
  display: block;
  width: min(100%, 560px);
  margin-inline: auto;
  height: auto;
}

.cord-caption {
  margin-top: 1.3rem;
  font-size: 0.84rem;
  font-weight: 600;
  letter-spacing: 0.3em;
  text-transform: uppercase;
  color: var(--muted);
}

/* ---------------------------------- 9. Countdown ------------------------- */

.countdown {
  display: flex;
  align-items: stretch;
  justify-content: center;
  gap: clamp(0.35rem, 1.5vw, 1rem);
  margin-top: 2.4rem;
}

.count-box {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  min-width: clamp(72px, 15vw, 132px);
  padding: clamp(0.9rem, 2.4vw, 1.5rem) clamp(0.5rem, 1.6vw, 1.1rem);
  background: rgba(254, 249, 241, 0.8);
  border: 1px solid var(--line);
  border-radius: 14px;
  box-shadow: var(--shadow-soft);
}

.count-num {
  font-size: clamp(2rem, 6vw, 3.4rem);
  font-weight: 500;
  line-height: 1;
  color: var(--ink);
  font-variant-numeric: tabular-nums;
  transition: transform 0.25s ease;
}

.count-num.tick {
  transform: translateY(-2px) scale(1.04);
}

.count-label {
  margin-top: 0.55rem;
  font-size: 0.7rem;
  font-weight: 600;
  letter-spacing: 0.26em;
  text-transform: uppercase;
  color: var(--muted);
}

.count-sep {
  display: flex;
  align-items: center;
  font-size: clamp(1.4rem, 4vw, 2.4rem);
  color: var(--gold-soft);
  padding-bottom: 1.4rem;
}

.countdown-meta {
  margin-top: 1.6rem;
  font-size: 0.9rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--muted);
}

.countdown-meta .dot {
  margin-inline: 0.6rem;
  color: var(--gold-soft);
}

.countdown.is-finished .count-box {
  display: none;
}

.countdown-finished {
  display: none;
  margin-top: 2rem;
  font-family: var(--font-serif);
  font-style: italic;
  font-size: clamp(1.3rem, 3vw, 1.9rem);
  color: var(--ink);
}

.countdown.is-finished + .countdown-meta,
.countdown.is-finished ~ .countdown-finished {
  display: block;
}

.year-note {
  display: inline-block;
  margin-top: 1.1rem;
  padding: 0.45rem 1.1rem;
  font-size: 0.8rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--gold-deep);
  background: rgba(198, 160, 99, 0.14);
  border: 1px solid rgba(138, 108, 60, 0.3);
  border-radius: 999px;
}

/* ---------------------------------- 10. Detail cards --------------------- */

.detail-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: clamp(1.1rem, 2.6vw, 2rem);
  margin-top: 3rem;
}

.card {
  background: rgba(254, 249, 241, 0.85);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: clamp(1.8rem, 3.4vw, 2.6rem) clamp(1.3rem, 2.6vw, 2rem);
  box-shadow: var(--shadow-soft);
  transition: transform 0.4s var(--ease-out), box-shadow 0.4s ease;
}

.card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-lift);
}

.card-icon {
  width: 46px;
  height: 46px;
  margin-inline: auto;
  color: var(--gold-deep);
}

.card-icon svg {
  width: 100%;
  height: 100%;
}

.card-title {
  margin-top: 1rem;
  font-size: 0.78rem;
  font-weight: 600;
  letter-spacing: 0.28em;
  text-transform: uppercase;
  color: var(--gold-deep);
}

.card-big {
  margin-top: 0.5rem;
  font-size: clamp(1.5rem, 2.6vw, 1.9rem);
  font-weight: 500;
  line-height: 1.25;
  color: var(--ink);
}

.card-big--venue {
  font-size: clamp(1.3rem, 2.2vw, 1.6rem);
}

.card-sub {
  margin-top: 0.4rem;
  font-size: 1rem;
  color: var(--muted);
}

/* ---------------------------------- 11. Timeline / story ----------------- */

.timeline {
  position: relative;
  max-width: 760px;
  margin: 3rem auto 0;
  padding-left: clamp(1.4rem, 4vw, 2.2rem);
}

.timeline::before {
  content: "";
  position: absolute;
  top: 6px;
  bottom: 6px;
  left: 6px;
  width: 1px;
  background: linear-gradient(180deg, var(--sage), var(--gold-soft), var(--rose));
  opacity: 0.6;
}

.timeline-item {
  position: relative;
  padding: 0 0 2.4rem 1.6rem;
}

.timeline-item:last-child {
  padding-bottom: 0;
}

.timeline-item::before {
  content: "";
  position: absolute;
  top: 8px;
  left: -1.55rem;
  width: 11px;
  height: 11px;
  border-radius: 50%;
  background: var(--ivory);
  border: 2px solid var(--gold-soft);
}

.timeline-label {
  font-size: 0.74rem;
  font-weight: 600;
  letter-spacing: 0.28em;
  text-transform: uppercase;
  color: var(--gold-deep);
}

.timeline-title {
  margin-top: 0.3rem;
  font-size: clamp(1.35rem, 2.4vw, 1.7rem);
  font-weight: 500;
  color: var(--ink);
}

.timeline-text {
  margin-top: 0.5rem;
  color: var(--muted);
}

.timeline-text.is-placeholder {
  font-style: italic;
  color: #8a7f72;
}

/* ---------------------------------- 12. Gallery -------------------------- */

.gallery {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(215px, 1fr));
  gap: clamp(0.9rem, 2vw, 1.5rem);
  margin-top: 3rem;
}

.gallery-item {
  position: relative;
  aspect-ratio: 4 / 5;
  margin: 0;
  border-radius: 14px;
  overflow: hidden;
  background: linear-gradient(160deg, var(--cream), var(--ivory-deep));
  border: 1px solid var(--line);
  box-shadow: var(--shadow-soft);
  transition: transform 0.4s var(--ease-out), box-shadow 0.4s ease;
}

.gallery-item:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-lift);
}

.gallery-item img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.7s var(--ease-out);
}

.gallery-item:hover img {
  transform: scale(1.05);
}

.gallery-placeholder {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 0.8rem;
  height: 100%;
  padding: 1rem;
  text-align: center;
  color: #93877a;
  font-size: 0.9rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
}

.gallery-placeholder svg {
  width: 40px;
  height: 40px;
  color: var(--sage);
  opacity: 0.8;
}

.gallery-hint {
  margin-top: 1.8rem;
  text-align: center;
  font-size: 0.92rem;
  color: var(--muted);
}

.gallery-hint code {
  padding: 0.1rem 0.45rem;
  background: rgba(198, 160, 99, 0.13);
  border-radius: 6px;
  font-size: 0.85em;
}

/* ---------------------------------- 13. Attire swatches ------------------ */

.swatches {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(160px, 1fr));
  gap: clamp(1rem, 2.4vw, 1.8rem);
  max-width: 880px;
  margin: 3rem auto 0;
}

.swatch {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.9rem;
  padding: 1.6rem 1rem;
  background: rgba(254, 249, 241, 0.8);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  transition: transform 0.4s var(--ease-out), box-shadow 0.4s ease;
}

.swatch:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-lift);
}

.swatch-chip {
  width: 68px;
  height: 68px;
  border-radius: 50%;
  border: 3px solid rgba(254, 249, 241, 0.95);
  box-shadow: 0 0 0 1px var(--line), var(--shadow-soft);
}

.swatch-name {
  font-size: 1.15rem;
  font-weight: 500;
  color: var(--ink);
}

.swatch-hex {
  font-size: 0.78rem;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--muted);
  margin-top: -0.5rem;
}

.swatch-note {
  margin-top: 2.4rem;
  font-style: italic;
  color: var(--muted);
}

/* ---------------------------------- 14. RSVP form ------------------------ */

.rsvp-badge {
  display: inline-block;
  margin-top: 1.5rem;
  padding: 0.5rem 1.25rem;
  font-size: 0.76rem;
  font-weight: 600;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  border-radius: 999px;
}

.rsvp-badge--demo {
  background: rgba(198, 160, 99, 0.16);
  border: 1px solid rgba(138, 108, 60, 0.4);
  color: var(--gold-deep);
}

.rsvp-badge--live {
  background: rgba(147, 165, 133, 0.2);
  border: 1px solid rgba(103, 121, 94, 0.45);
  color: var(--sage-deep);
}

.rsvp-form {
  margin-top: 2.4rem;
  padding: clamp(1.6rem, 4vw, 2.8rem);
  background: rgba(254, 249, 241, 0.9);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  box-shadow: var(--shadow-soft);
  text-align: left;
}

.field {
  margin-bottom: 1.5rem;
  border: 0;
  padding: 0;
  min-inline-size: 0;
}

.field label,
.field legend {
  display: block;
  margin-bottom: 0.5rem;
  font-size: 0.8rem;
  font-weight: 600;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--charcoal);
}

.field .opt {
  letter-spacing: 0.1em;
  text-transform: none;
  color: var(--muted);
  font-weight: 400;
}

.req {
  color: var(--rose-deep);
}

.field input[type="text"],
.field select,
.field textarea {
  width: 100%;
  padding: 0.85rem 1.05rem;
  font-family: var(--font-serif);
  font-size: 1.05rem;
  color: var(--ink);
  background: var(--cream);
  border: 1px solid var(--line);
  border-radius: 10px;
  transition: border-color 0.25s ease, box-shadow 0.25s ease;
}

.field textarea {
  resize: vertical;
  min-height: 110px;
}

.field input:focus,
.field select:focus,
.field textarea:focus {
  outline: none;
  border-color: var(--gold-soft);
  box-shadow: 0 0 0 3px rgba(198, 160, 99, 0.2);
}

.field input[aria-invalid="true"],
.field select[aria-invalid="true"] {
  border-color: var(--rose-deep);
}

.field-error {
  margin-top: 0.45rem;
  font-size: 0.92rem;
  color: var(--rose-deep);
}

.choice-row {
  display: flex;
  flex-wrap: wrap;
  gap: 0.8rem;
}

.choice {
  flex: 1 1 200px;
  cursor: pointer;
}

.choice input {
  position: absolute;
  opacity: 0;
  width: 1px;
  height: 1px;
}

.choice-face {
  display: block;
  padding: 0.9rem 1.2rem;
  text-align: center;
  font-size: 1rem;
  letter-spacing: 0.06em;
  color: var(--charcoal);
  background: var(--cream);
  border: 1px solid var(--line);
  border-radius: 10px;
  transition: border-color 0.25s ease, background-color 0.25s ease,
    box-shadow 0.25s ease;
}

.choice input:checked + .choice-face {
  border-color: var(--gold-soft);
  background: rgba(198, 160, 99, 0.14);
  box-shadow: 0 0 0 1px var(--gold-soft);
}

.choice input:focus-visible + .choice-face {
  outline: 2px solid var(--gold-deep);
  outline-offset: 2px;
}

.form-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.8rem;
  margin-top: 0.5rem;
}

.form-status {
  margin-top: 1.3rem;
  padding: 1rem 1.2rem;
  border-radius: 10px;
  font-size: 1rem;
  line-height: 1.6;
}

.form-status--ok {
  background: rgba(147, 165, 133, 0.18);
  border: 1px solid rgba(103, 121, 94, 0.4);
  color: #46543e;
}

.form-status--warn {
  background: rgba(198, 160, 99, 0.16);
  border: 1px solid rgba(138, 108, 60, 0.4);
  color: #6f5730;
}

.form-status--error {
  background: rgba(200, 154, 146, 0.2);
  border: 1px solid rgba(169, 115, 107, 0.45);
  color: #8c534b;
}

.rsvp-receipt {
  margin-top: 1rem;
  padding: 1.1rem 1.2rem;
  border: 1px dashed var(--line);
  border-radius: 10px;
  font-size: 0.98rem;
  color: var(--muted);
  background: rgba(248, 233, 229, 0.45);
}

.rsvp-receipt strong {
  color: var(--charcoal);
}

/* ---------------------------------- 15. Contact -------------------------- */

.contact-list {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 0.9rem;
  margin-top: 2.2rem;
}

.contact-chip {
  display: inline-flex;
  flex-direction: column;
  align-items: center;
  gap: 0.15rem;
  padding: 1rem 1.7rem;
  background: rgba(254, 249, 241, 0.85);
  border: 1px solid var(--line);
  border-radius: 14px;
  box-shadow: var(--shadow-soft);
  text-decoration: none;
  transition: transform 0.35s var(--ease-out), box-shadow 0.35s ease;
}

.contact-chip:hover {
  transform: translateY(-3px);
  box-shadow: var(--shadow-lift);
}

.contact-chip .chip-label {
  font-size: 0.72rem;
  font-weight: 600;
  letter-spacing: 0.26em;
  text-transform: uppercase;
  color: var(--gold-deep);
}

.contact-chip .chip-value {
  font-size: 1.05rem;
  color: var(--ink);
}

.contact-note {
  margin-top: 1.6rem;
  font-style: italic;
  color: var(--muted);
}

/* ---------------------------------- 16. Footer --------------------------- */

.site-footer {
  padding: clamp(3.5rem, 7vw, 5.5rem) 0 3rem;
  background: var(--charcoal);
  color: #efe4d4;
  text-align: center;
}

.footer-names {
  font-family: var(--font-script);
  font-size: clamp(2.4rem, 5.5vw, 3.4rem);
  line-height: 1.1;
  color: #f7ecdc;
}

.footer-amp {
  color: var(--gold);
}

.footer-line {
  margin-top: 0.9rem;
  font-size: 0.84rem;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: #cdbfa9;
}

.footer-verse {
  margin-top: 1.8rem;
  font-style: italic;
  font-size: 1.15rem;
  color: #e8dcc8;
}

.footer-verse cite {
  display: block;
  margin-top: 0.5rem;
  font-style: normal;
  font-size: 0.74rem;
  font-weight: 600;
  letter-spacing: 0.3em;
  text-transform: uppercase;
  color: var(--gold);
}

.footer-nav {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 0.4rem 1.4rem;
  list-style: none;
  margin: 2.2rem 0 0;
  padding: 0;
}

.footer-nav a {
  font-size: 0.74rem;
  font-weight: 600;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: #cdbfa9;
  text-decoration: none;
  transition: color 0.25s ease;
}

.footer-nav a:hover {
  color: #f7ecdc;
}

.footer-copy {
  margin-top: 2.2rem;
  font-size: 0.8rem;
  letter-spacing: 0.12em;
  color: #a3937c;
}

/* ---------------------------------- 17. Music button & toast ------------- */

.music-btn {
  position: fixed;
  right: clamp(1rem, 3vw, 2rem);
  bottom: clamp(1rem, 3vw, 2rem);
  z-index: 95;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 56px;
  height: 56px;
  border-radius: 50%;
  background: rgba(254, 249, 241, 0.94);
  border: 1px solid rgba(176, 141, 87, 0.5);
  color: var(--charcoal);
  cursor: pointer;
  box-shadow: var(--shadow-lift);
  transition: transform 0.3s var(--ease-out), background-color 0.3s ease,
    color 0.3s ease;
}

.music-btn:hover {
  transform: translateY(-3px);
}

.music-btn[aria-pressed="true"] {
  background: var(--charcoal);
  color: var(--cream);
}

.music-icon {
  position: absolute;
  width: 24px;
  height: 24px;
  transition: opacity 0.25s ease, transform 0.25s ease;
}

.music-icon--pause {
  opacity: 0;
  transform: scale(0.7);
}

.music-btn[aria-pressed="true"] .music-icon--play {
  opacity: 0;
  transform: scale(0.7);
}

.music-btn[aria-pressed="true"] .music-icon--pause {
  opacity: 1;
  transform: scale(1);
}

.music-eq {
  position: absolute;
  bottom: 9px;
  display: flex;
  align-items: flex-end;
  gap: 2.5px;
  height: 9px;
  opacity: 0;
  transition: opacity 0.25s ease;
}

.music-btn[aria-pressed="true"] .music-eq {
  opacity: 1;
}

.music-eq i {
  width: 2.5px;
  height: 100%;
  background: currentColor;
  border-radius: 2px;
  animation: eqBounce 0.85s ease-in-out infinite;
}

.music-eq i:nth-child(2) { animation-delay: 0.18s; }
.music-eq i:nth-child(3) { animation-delay: 0.36s; }

@keyframes eqBounce {
  0%, 100% { transform: scaleY(0.35); }
  50% { transform: scaleY(1); }
}

.toast {
  position: fixed;
  left: 50%;
  bottom: clamp(1.2rem, 4vw, 2.4rem);
  z-index: 120;
  max-width: min(92vw, 420px);
  padding: 0.9rem 1.4rem;
  background: var(--charcoal);
  color: #f7ecdc;
  font-size: 0.98rem;
  line-height: 1.5;
  border-radius: 12px;
  box-shadow: var(--shadow-lift);
  text-align: center;
  opacity: 0;
  transform: translate(-50%, 18px);
  pointer-events: none;
  transition: opacity 0.35s ease, transform 0.35s var(--ease-out);
}

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

/* ---------------------------------- 18. Reveal on scroll ----------------- */

html.js .reveal {
  opacity: 0;
  transform: translateY(24px);
  transition: opacity 0.95s ease var(--delay, 0s),
    transform 0.95s var(--ease-out) var(--delay, 0s);
}

html.js .reveal.is-visible {
  opacity: 1;
  transform: none;
}

/* ---------------------------------- 19. Responsive ----------------------- */

@media (max-width: 1080px) {
  .hero-body {
    grid-template-columns: 1fr minmax(380px, 540px);
  }
}

@media (max-width: 960px) {
  .nav-toggle {
    display: flex;
  }

  .nav-links {
    position: fixed;
    top: var(--nav-h);
    left: 0;
    right: 0;
    flex-direction: column;
    align-items: center;
    gap: 0;
    padding: 0.6rem 0 1.4rem;
    background: rgba(253, 246, 236, 0.98);
    border-bottom: 1px solid var(--line);
    box-shadow: 0 24px 40px -30px rgba(58, 51, 44, 0.7);
    opacity: 0;
    visibility: hidden;
    transform: translateY(-14px);
    transition: opacity 0.35s ease, transform 0.35s var(--ease-out),
      visibility 0.35s;
  }

  @supports ((backdrop-filter: blur(8px)) or (-webkit-backdrop-filter: blur(8px))) {
    .nav-links {
      -webkit-backdrop-filter: blur(12px);
      backdrop-filter: blur(12px);
    }
  }

  .nav-links.is-open {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
  }

  .nav-links li {
    width: 100%;
    text-align: center;
  }

  .nav-links a {
    display: block;
    padding: 0.95rem 1rem;
    font-size: 0.92rem;
  }

  .nav-links a::after {
    display: none;
  }
}

@media (max-width: 880px) {
  /* Hero stacks: illustration on top, invitation text below */
  .hero {
    display: block;
    min-height: 0;
    padding: 0;
  }

  .hero-visual {
    position: relative;
    height: 58vh; /* fallback for browsers without svh units */
    height: clamp(320px, 58svh, 560px);
  }

  .hero-img {
    object-position: 24% 38%;
  }

  .hero-scrim {
    background: linear-gradient(
      180deg,
      rgba(253, 246, 236, 0) 52%,
      rgba(253, 246, 236, 0.65) 82%,
      rgba(253, 246, 236, 0.96) 100%
    );
  }

  .hero-light--one {
    width: 70vmax;
    height: 70vmax;
    top: -20%;
    right: -25%;
  }

  .hero-body {
    grid-template-columns: 1fr;
    padding: 0 clamp(1.1rem, 6vw, 2.5rem) 4.5rem;
    margin-top: -3.5rem;
    background: var(--ivory);
  }

  .hero-panel {
    grid-column: 1;
    border: 0;
    outline: 0;
    box-shadow: none;
    background: transparent;
    -webkit-backdrop-filter: none;
    backdrop-filter: none;
    padding-inline: 0;
  }

  .scroll-cue {
    display: none;
  }
}

@media (max-width: 560px) {
  body {
    font-size: 1.06rem;
  }

  .hero-name {
    font-size: clamp(3rem, 15vw, 4.2rem);
  }

  .count-sep {
    display: none;
  }

  .countdown {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 0.7rem;
    max-width: 340px;
    margin-inline: auto;
  }

  .hero-actions .btn {
    flex: 1 1 100%;
  }
}

/* ---------------------------------- 20. Reduced motion ------------------- */

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    animation-duration: 0.001s !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.001s !important;
    scroll-behavior: auto !important;
  }

  .petals {
    display: none;
  }

  .anim,
  html.js .reveal {
    opacity: 1 !important;
    transform: none !important;
  }
}
