/* ==========================================================================
   1. VARIABLES & RESET
   ========================================================================== */

:root {
  --paper: #fbf7ee;
  --cream: #f2eadc;
  --ink: #3f493c;
  --sage: #687761;
  --olive: #56634d;
  --terracotta: #b77761;
  --rust: #965c4b;
  --dusty: #8c9a96;
  --gold: #b99a61;
  --line: #d8cdbb;
  --white: #fffdf8;
  --serif: "Cormorant Garamond", Georgia, serif;
  --sans: "DM Sans", Arial, sans-serif;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
  scroll-padding-top: 5rem;
}

body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font: 16px/1.7 var(--sans);
}

a {
  color: inherit;
}

button,
input,
textarea {
  font: inherit;
}

button {
  cursor: pointer;
}

/* Accessibility Utilities */
.skip-link {
  position: fixed;
  left: 1rem;
  top: -4rem;
  z-index: 100;
  background: var(--ink);
  color: #fff;
  padding: 0.7rem 1rem;
}

.skip-link:focus {
  top: 1rem;
}

.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

/* ==========================================================================
   2. HEADER & NAVIGATION
   ========================================================================== */

.site-header {
  position: fixed;
  inset: 0 0 auto;
  z-index: 50;
  transition: background 0.25s ease, box-shadow 0.25s ease, backdrop-filter 0.25s ease;
  background: transparent;
}

.site-header.is-scrolled,
.site-header.menu-open {
  background: rgba(251, 247, 238, 0.96);
  backdrop-filter: blur(14px);
  box-shadow: 0 1px 0 var(--line);
}

.nav {
  position: relative;
  width: min(1120px, calc(100% - 2rem));
  min-height: 4.7rem;
  margin: auto;
  display: flex;
  align-items: center;
  justify-content: center; /* Centers the content horizontally */
}

.brand {
  text-decoration: none;
  font: 600 2rem/1 var(--serif);
  letter-spacing: 0.05em;
  white-space: nowrap;
  text-align: center; /* Ensures text is centered within its block */
}

@media (max-width: 719px) {
  .nav {
    min-height: 4.35rem;
    justify-content: center; /* Forces centering on smaller mobile screens */
  }

  .brand {
    font-size: 1.85rem;
  }
}

.nav-toggle {
  position: absolute;
  right: 0;
  top: 50%;
  transform: translateY(-50%);
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  width: 2rem;
  height: 1.45rem;
  padding: 0.1rem 0;
  border: 0;
  background: transparent;
  color: currentColor;
  z-index: 2;
}

.nav-toggle span:not(.sr-only) {
  display: block;
  width: 100%;
  height: 2px;
  border-radius: 999px;
  background: currentColor;
  transform-origin: center;
  transition: transform 0.2s ease, opacity 0.2s ease;
}

.nav-toggle[aria-expanded="true"] span:nth-of-type(2) {
  transform: translateY(0.45rem) rotate(45deg);
}

.nav-toggle[aria-expanded="true"] span:nth-of-type(3) {
  opacity: 0;
}

.nav-toggle[aria-expanded="true"] span:nth-of-type(4) {
  transform: translateY(-0.45rem) rotate(-45deg);
}

.nav-menu {
  position: absolute;
  top: calc(100% - 0.2rem);
  right: 0;
  width: min(320px, calc(100vw - 2rem));
  margin: 0;
  padding: 0.7rem;
  list-style: none;
  display: grid;
  gap: 0.25rem;
  background: rgba(251, 247, 238, 0.98);
  border: 1px solid var(--line);
  box-shadow: 0 18px 40px rgba(63, 73, 60, 0.12);
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
  transform: translateY(-0.5rem);
  transition: opacity 0.2s ease, transform 0.2s ease, visibility 0.2s ease;
}

.nav-menu.is-open {
  opacity: 1;
  visibility: visible;
  pointer-events: auto;
  transform: translateY(0);
}

.nav-menu a {
  display: block;
  padding: 0.75rem 0.85rem;
  text-decoration: none;
  font-size: 0.7rem;
  font-weight: 700;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  border-radius: 2px;
}

.nav-menu a:hover,
.nav-menu a:focus-visible {
  color: var(--terracotta);
  background: rgba(216, 205, 187, 0.2);
}

.nav-cta {
  border: 1px solid currentColor;
  border-radius: 99px;
  text-align: center;
}

.site-header:not(.is-scrolled):not(.menu-open) {
  color: var(--white);
}

@media (max-width: 719px) {
  .nav {
    min-height: 4.35rem;
  }

  .brand {
    font-size: 1.85rem;
  }
}

/* ==========================================================================
   3. GLOBAL TYPOGRAPHY & LAYOUT UTILITIES
   ========================================================================== */

.section {
  padding: 6.5rem 0;
}

.container {
  width: min(1100px, calc(100% - 2rem));
  margin: auto;
}

.narrow {
  max-width: 760px;
  text-align: center;
}

.eyebrow {
  margin: 0 0 0.4rem;
  color: var(--olive);
  font-size: 0.68rem;
  font-weight: 700;
  letter-spacing: 0.2em;
  text-transform: uppercase;
}

.script-title {
  margin: 0.1rem 0 0.25rem;
  color: var(--olive);
  font: 400 clamp(1.9rem, 5vw, 2.7rem)/1.1 "Parisienne", cursive;
}

h1,
h2,
h3 {
  font-family: var(--serif);
  line-height: 0.98;
  font-weight: 500;
  color: var(--ink);
}

h1 {
  font-size: clamp(4rem, 13vw, 8rem);
  margin: 0.2rem 0 1rem;
}

h2 {
  font-size: clamp(3rem, 7vw, 5rem);
  margin: 0.3rem 0 1.3rem;
}

h3 {
  font-size: 1.7rem;
  margin: 0.15rem 0 0.3rem;
}

.flourish {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.7rem;
  margin: 1rem auto;
}

.flourish span {
  width: 3rem;
  height: 1px;
  background: currentColor;
}

.flourish b {
  font-weight: 400;
  color: var(--gold);
}

/* Buttons */
.button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 3.1rem;
  padding: 0.75rem 1.35rem;
  border-radius: 99px;
  text-decoration: none;
  border: 1px solid transparent;
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.13em;
  text-transform: uppercase;
  transition: transform 0.2s, background 0.2s;
}

.button:hover {
  transform: translateY(-2px);
}

.button-primary {
  background: var(--olive);
  color: #fff;
}

.button-ghost {
  border-color: rgba(255, 255, 255, 0.8);
  color: #fff;
  background: rgba(255, 255, 255, 0.05);
}

.button-outline {
  border-color: var(--olive);
  color: var(--olive);
  background: transparent;
}

/* Animations */
.reveal {
  opacity: 0;
  transform: translateY(18px);
  transition: opacity 0.7s ease, transform 0.7s ease;
}

.reveal.visible {
  opacity: 1;
  transform: none;
}

/* ==========================================================================
   4. HERO SECTION
   ========================================================================== */

.hero {
  min-height: 100svh;
  position: relative;
  display: grid;
  place-items: center;
  overflow: hidden;
  background: 
    linear-gradient(rgba(0, 0, 0, 0.35), rgba(0, 0, 0, 0.45)),
    url("assets/LAKE_HERO.jpeg") center/cover no-repeat;
  color: white;
}

.hero .button-primary {
  background: rgb(243, 203, 209);
  color: black;
}

.hero .eyebrow {
  color: white;
}

.hero h1 {
  color: #fffdf8;
}

.hero h1 em {
  color: rgb(243, 203, 209);
  font-style: italic;
}

.hero-wash {
  position: absolute;
  inset: 0;
  background: linear-gradient(
    to bottom,
    rgba(57, 69, 53, 0.08),
    rgba(57, 69, 53, 0.12) 55%,
    rgba(50, 61, 49, 0.52)
  );
}

.hero-content {
  position: relative;
  z-index: 2;
  width: min(850px, calc(100% - 2rem));
  text-align: center;
  padding-top: 4rem;
}

.script-kicker {
  font: 400 clamp(1.7rem, 4vw, 2.3rem)/1 "Parisienne", cursive;
  margin: 0 0 0.5rem;
  color: var(--white);
}

.hero-date {
  font: 500 1.5rem/1.2 var(--serif);
  letter-spacing: 0.1em;
  margin: 0;
}

.hero-location {
  font-size: 0.86rem;
  letter-spacing: 0.04em;
  margin: 0.45rem auto 1.7rem;
}

.hero-actions {
  display: flex;
  justify-content: center;
  gap: 0.65rem;
  flex-wrap: wrap;
}

.scroll-cue {
  position: absolute;
  z-index: 3;
  bottom: 1.4rem;
  left: 50%;
  font-size: 1.4rem;
  text-decoration: none;
  animation: float 1.8s ease-in-out infinite;
}

@keyframes float {
  50% {
    transform: translateY(8px);
  }
}

/* ==========================================================================
   5. COUNTDOWN SECTION
   ========================================================================== */

.countdown {
  position: relative;
  background: var(--cream);
  overflow: hidden;
}

.wildflower-strip {
  position: absolute;
  inset: auto 0 0;
  height: 50px;
  opacity: 0.25;
  background: url("assets/wildflower-border.svg") center bottom/auto 55px repeat-x;
}

.countdown h2 {
  margin-bottom: 2rem;
}

.countdown-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 0.7rem;
  max-width: 680px;
  margin: auto;
}

.time-card {
  padding: 1.2rem 0.5rem;
  border-top: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
  background: rgba(255, 253, 248, 0.42);
}

.time-card span {
  display: block;
  font: 500 clamp(2.5rem, 9vw, 4.6rem)/1 var(--serif);
  color: var(--olive);
}

.time-card small {
  font-size: 0.62rem;
  font-weight: 700;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--terracotta);
}

/* ==========================================================================
   6. STORY SECTION
   ========================================================================== */

.story {
  background: var(--paper);
}

.story-grid {
  display: grid;
  gap: 3rem;
  align-items: center;
}

.story-copy {
  max-width: 560px;
}

.story-copy > p:not(.eyebrow):not(.script-title) {
  color: var(--sage);
}

.signature {
  font: 500 2rem var(--serif);
  margin-top: 1.6rem;
}

.signature span {
  color: var(--terracotta);
  font-style: italic;
}

/* Detail Board */
.detail-board {
  position: relative;
  display: grid;
  grid-template-columns: 1fr 1fr;
  border: 2px solid var(--line);
  background: var(--white);
  padding: 1.4rem;
  box-shadow: 8px 8px 0 var(--line);
}

.detail-board article {
  padding: 1.3rem;
  border-bottom: 1px solid var(--line);
}

.detail-board article:nth-child(odd) {
  border-right: 1px solid var(--line);
}

.detail-board article:nth-last-child(-n + 2) {
  border-bottom: 0;
}

.detail-board span {
  display: block;
  color: var(--terracotta);
  font-size: 0.63rem;
  font-weight: 900; /* Increased bold weight */
  letter-spacing: 0.17em;
  text-transform: uppercase;
  margin-bottom: 0.4rem;
}

.detail-board strong {
  font: 900 1.25rem/1.1 var(--serif); /* Increased bold weight */
  color: var(--ink);
}

.pressed-flower {
  position: absolute;
  right: -18px;
  top: -23px;
  color: var(--terracotta);
  font-size: 3.5rem;
  transform: rotate(18deg);
}

/* ==========================================================================
   7. SCHEDULE SECTION
   ========================================================================== */

.schedule {
  background: var(--paper);
}

.section-heading {
  text-align: center;
  margin-bottom: 3rem;
}

/* ==========================================================================
   8. TRAVEL SECTION
   ========================================================================== */

.travel {
  background: var(--cream);
}

.travel-grid {
  display: grid;
  gap: 3rem;
  align-items: center;
}

.travel-image-container {
  min-height: 27rem;
  position: relative;
  overflow: hidden;
  box-shadow: 10px 10px 0 rgba(86, 99, 77, 0.14);
  background: var(--white);
}

.travel-photo {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  min-height: 27rem;
}

.travel-copy {
  max-width: 550px;
}

.travel-copy > p:not(.eyebrow):not(.script-title) {
  color: var(--sage);
}

.check-list {
  list-style: none;
  padding: 0;
  margin: 1.5rem 0;
}

.check-list li {
  margin: 0.65rem 0;
  padding-left: 1.5rem;
  position: relative;
}

.check-list li:before {
  content: "✿";
  position: absolute;
  left: 0;
  color: var(--terracotta);
}

.text-link {
  font-size: 0.76rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-underline-offset: 0.35em;
  color: var(--olive);
}

/* ==========================================================================
   9. REGISTRY & FAQ
   ========================================================================== */

.registry {
  background: var(--cream);
}

.mini-bouquet,
.rsvp-flower,
.footer-flora {
  color: var(--terracotta);
  letter-spacing: 0.5em;
  font-size: 1.5rem;
}

.registry h2 {
  margin-bottom: 1rem;
}

.registry p:not(.eyebrow):not(.script-title) {
  max-width: 560px;
  margin: 0 auto 1.6rem;
  color: var(--sage);
}

.faq {
  background: var(--paper);
}

.faq-grid {
  max-width: 850px;
  margin: auto;
  display: grid;
  gap: 0.7rem;
}

.faq-grid details {
  padding: 1.1rem 1.2rem;
  border: 1px solid var(--line);
  background: var(--white);
}

.faq-grid summary {
  cursor: pointer;
  font: 500 1.5rem/1.1 var(--serif);
}

.faq-grid details p {
  margin: 1rem 0 0;
  color: var(--sage);
  font-size: 0.9rem;
}

/* ==========================================================================
   10. RSVP SECTION & FORMS
   ========================================================================== */

.rsvp {
  background: var(--cream);
}

.rsvp-grid {
  display: grid;
  gap: 3rem;
  align-items: start;
}

.rsvp-copy {
  padding-top: 1rem;
}

.rsvp-copy p:not(.eyebrow):not(.script-title) {
  max-width: 450px;
  color: var(--sage);
}

.rsvp-flower {
  font-size: 4rem;
  margin-top: 2rem;
}

.rsvp-form {
  background: var(--white);
  border: 1px solid var(--line);
  padding: 1.5rem;
  box-shadow: 10px 10px 0 rgba(183, 119, 97, 0.12);
}

.rsvp-form > .button {
  width: 100%;
}

.form-row {
  margin-bottom: 1rem;
}

.form-row > label,
legend {
  display: block;
  margin-bottom: 0.4rem;
  font-size: 0.7rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.form-row label span,
legend span {
  color: var(--terracotta);
}

input[type="text"],
input[type="email"],
input[type="tel"],
input[type="number"],
textarea {
  display: block;
  width: 100%;
  padding: 0.8rem 0.85rem;
  border: 1px solid var(--line);
  border-radius: 2px;
  background: var(--white);
  color: var(--ink);
  outline: none;
}

input:focus,
textarea:focus {
  border-color: var(--olive);
  box-shadow: 0 0 0 3px rgba(104, 119, 97, 0.12);
}

textarea {
  resize: vertical;
}

.radio-group {
  border: 0;
  padding: 0;
}

.radio-group label {
  display: flex;
  gap: 0.5rem;
  align-items: center;
  margin: 0.55rem 0;
  cursor: pointer;
  font-size: 0.9rem;
  text-transform: none;
  letter-spacing: 0;
  font-weight: 500;
}

.radio-group input {
  accent-color: var(--olive);
}

.field-help,
.field-error {
  font-size: 0.72rem;
}

.field-help {
  color: var(--dusty);
  margin: 0.25rem 0 0;
}

.field-error {
  min-height: 1rem;
  color: var(--rust);
  margin: 0.25rem 0 0;
}

.form-status {
  min-height: 1.4rem;
  margin-top: 0.8rem;
  font-size: 0.85rem;
  font-weight: 600;
}

.form-status.success {
  color: var(--olive);
}

.form-status.error {
  color: var(--rust);
}

.honeypot {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
}

/* ==========================================================================
   11. FOOTER
   ========================================================================== */

.site-footer {
  padding: 2rem 1rem;
  text-align: center;
  background: var(--ink);
  color: var(--white);
  font-size: 0.76rem;
}

.site-footer p {
  margin: 0.3rem 0;
}

.site-footer a {
  text-underline-offset: 0.25em;
}

.footer-flora {
  color: var(--gold);
}

/* ==========================================================================
   12. MEDIA QUERIES
   ========================================================================== */

@media (min-width: 720px) {
  .countdown-grid {
    grid-template-columns: repeat(4, 1fr);
  }

  .story-grid {
    grid-template-columns: 1.05fr 0.95fr;
    gap: 6rem;
  }

  .travel-grid {
    grid-template-columns: 1fr 1fr;
    gap: 6rem;
  }

  .rsvp-grid {
    grid-template-columns: 0.8fr 1.2fr;
    gap: 6rem;
  }

  .rsvp-form {
    padding: 2.1rem;
  }
}

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    scroll-behavior: auto !important;
    animation: none !important;
    transition: none !important;
  }

  .reveal {
    opacity: 1;
    transform: none;
  }
}