/* ============================================================
   Robert & Autumn Wedding — style.css
   Palette:
     --forest:    #1e3a2f   (deep forest green)
     --pine:      #2d5a40   (mid forest green)
     --sage:      #6b8f71   (sage green)
     --sage-lt:   #a8c5a0   (light sage)
     --mist:      #d4e6d0   (misty green / tint)
     --cream:     #f8f4ee   (warm ivory / background)
     --parchment: #ede7db   (section alt background)
     --gold:      #b8975a   (warm gold accent)
     --text:      #2a2118   (near-black body text)
     --text-lt:   #5a4e42   (lighter body text)
   ============================================================ */

/* ---- Reset & base ---------------------------------------- */

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

html {
  scroll-behavior: smooth;
  font-size: 16px;
}

body {
  font-family: 'Lato', sans-serif;
  font-weight: 300;
  color: #2a2118;
  background-color: #f8f4ee;
  line-height: 1.75;
  overflow-x: hidden;
}

h1, h2, h3, h4 {
  font-family: 'Playfair Display', serif;
  font-weight: 400;
  line-height: 1.2;
}

p { max-width: 65ch; }

a {
  color: #2d5a40;
  text-decoration: underline;
  text-underline-offset: 3px;
}

a:hover { color: #1e3a2f; }

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

address { font-style: normal; }

/* ---- CSS custom properties ------------------------------- */

:root {
  --forest:    #1e3a2f;
  --pine:      #2d5a40;
  --sage:      #6b8f71;
  --sage-lt:   #a8c5a0;
  --mist:      #d4e6d0;
  --cream:     #f8f4ee;
  --parchment: #ede7db;
  --gold:      #b8975a;
  --text:      #2a2118;
  --text-lt:   #5a4e42;
  --radius:    4px;
  --shadow:    0 2px 16px rgba(30, 58, 47, 0.12);
  --transition: 0.25s ease;
}

/* ============================================================
   UTILITY
   ============================================================ */

.section {
  padding: 5rem 1.5rem;
}

.section:nth-child(even) {
  background-color: var(--parchment);
}

.section-inner {
  max-width: 1080px;
  margin: 0 auto;
}

.section-inner--narrow {
  max-width: 720px;
}

.section-header {
  text-align: center;
  margin-bottom: 3.5rem;
}

.section-eyebrow {
  font-family: 'Lato', sans-serif;
  font-weight: 400;
  font-size: 0.8rem;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--sage);
  margin-bottom: 0.5rem;
}

.section-title {
  font-family: 'Cormorant Garamond', serif;
  font-size: clamp(2rem, 4vw, 3rem);
  color: var(--forest);
  margin-bottom: 1rem;
}

.section-subtitle {
  color: var(--text-lt);
  font-style: italic;
  max-width: 50ch;
  margin: 0 auto;
}

/* Floral divider */
.divider {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  margin: 0.75rem auto 1.5rem;
  width: fit-content;
}

.divider::before,
.divider::after {
  content: '';
  display: block;
  width: 60px;
  height: 1px;
  background: var(--sage-lt);
}

.divider::before {
  content: '✦';
  font-size: 0.75rem;
  color: var(--sage);
  width: auto;
  height: auto;
  background: none;
}

/* Override so the lines appear either side of the pseudo-element */
.section-header .divider {
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  align-items: center;
  gap: 0.75rem;
  width: 200px;
}

.section-header .divider::before {
  content: '';
  width: 100%;
  height: 1px;
  background: var(--sage-lt);
  display: block;
}

.section-header .divider::after {
  content: '';
  width: 100%;
  height: 1px;
  background: var(--sage-lt);
  display: block;
}

/* Use a span trick with a pseudo-element in the middle */
.divider {
  position: relative;
}

/* Actually let's just use a clean single implementation */
.divider {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 200px;
  margin: 0.75rem auto 1.5rem;
  gap: 0;
}

.divider::before,
.divider::after {
  content: '';
  flex: 1;
  height: 1px;
  background: var(--sage-lt);
}

.divider::before { margin-right: 0.75rem; }
.divider::after  { margin-left: 0.75rem; }

/* ============================================================
   BUTTONS
   ============================================================ */

.btn {
  display: inline-block;
  font-family: 'Lato', sans-serif;
  font-weight: 400;
  font-size: 0.8rem;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  text-decoration: none;
  padding: 0.85rem 2.25rem;
  border-radius: var(--radius);
  cursor: pointer;
  transition: background var(--transition), color var(--transition), border-color var(--transition), box-shadow var(--transition);
  border: 1px solid transparent;
  line-height: 1;
}

.btn--primary {
  background-color: var(--pine);
  color: #fff;
  border-color: var(--pine);
}

.btn--primary:hover,
.btn--primary:focus-visible {
  background-color: var(--forest);
  border-color: var(--forest);
  color: #fff;
  box-shadow: 0 4px 20px rgba(30,58,47,0.25);
}

.btn--outline {
  background-color: transparent;
  color: var(--pine);
  border-color: var(--sage);
}

.btn--outline:hover,
.btn--outline:focus-visible {
  background-color: var(--mist);
  border-color: var(--pine);
  color: var(--forest);
}

.btn--full { width: 100%; text-align: center; }

/* ============================================================
   NAVIGATION
   ============================================================ */

.site-nav {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 100;
  padding: 0 1.5rem;
  background: rgba(248, 244, 238, 0.0);
  transition: background var(--transition), box-shadow var(--transition), padding var(--transition);
}

.site-nav.scrolled {
  background: rgba(248, 244, 238, 0.97);
  box-shadow: 0 1px 12px rgba(30,58,47,0.08);
  padding: 0 1.5rem;
}

.nav-inner {
  max-width: 1080px;
  margin: 0 auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 64px;
}

.nav-brand {
  font-family: 'Cormorant Garamond', serif;
  font-size: 1.5rem;
  font-style: italic;
  color: var(--cream);
  text-decoration: none;
  letter-spacing: 0.05em;
  transition: color var(--transition);
}

.site-nav.scrolled .nav-brand { color: var(--forest); }

.nav-links {
  list-style: none;
  display: flex;
  gap: 2rem;
}

.nav-links a {
  font-family: 'Lato', sans-serif;
  font-size: 0.78rem;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  text-decoration: none;
  color: rgba(248,244,238,0.9);
  transition: color var(--transition);
}

.site-nav.scrolled .nav-links a { color: var(--text-lt); }

.nav-links a:hover,
.site-nav.scrolled .nav-links a:hover { color: var(--pine); }

.nav-toggle {
  display: none;
  flex-direction: column;
  gap: 5px;
  background: none;
  border: none;
  cursor: pointer;
  padding: 4px;
}

.nav-toggle span {
  display: block;
  width: 24px;
  height: 2px;
  background: var(--cream);
  transition: transform var(--transition), opacity var(--transition), background var(--transition);
}

.site-nav.scrolled .nav-toggle span { background: var(--forest); }

.nav-toggle.open span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
.nav-toggle.open span:nth-child(2) { opacity: 0; }
.nav-toggle.open span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

/* ============================================================
   HERO
   ============================================================ */

.hero {
  position: relative;
  min-height: 100svh;
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  padding: 6rem 1.5rem 4rem;
  background-color: var(--forest);
  background-image:
    radial-gradient(ellipse at 20% 50%, rgba(45,90,64,0.6) 0%, transparent 60%),
    radial-gradient(ellipse at 80% 50%, rgba(45,90,64,0.6) 0%, transparent 60%);
  overflow: hidden;
}

/* Decorative floral corners via SVG data-uri */
.hero-floral {
  position: absolute;
  top: 0;
  width: 320px;
  height: 320px;
  opacity: 0.18;
  background-size: contain;
  background-repeat: no-repeat;
  pointer-events: none;
}

.hero-floral--left {
  left: -40px;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 200 200'%3E%3Cellipse cx='60' cy='80' rx='30' ry='50' fill='none' stroke='%23a8c5a0' stroke-width='1.5' transform='rotate(-30 60 80)'/%3E%3Cellipse cx='80' cy='60' rx='25' ry='45' fill='none' stroke='%23a8c5a0' stroke-width='1.5' transform='rotate(20 80 60)'/%3E%3Cellipse cx='100' cy='90' rx='28' ry='48' fill='none' stroke='%23a8c5a0' stroke-width='1.5' transform='rotate(-10 100 90)'/%3E%3Ccircle cx='70' cy='100' r='8' fill='none' stroke='%23a8c5a0' stroke-width='1.5'/%3E%3Cpath d='M40 160 Q70 100 100 140' stroke='%23a8c5a0' stroke-width='1.5' fill='none'/%3E%3Cpath d='M30 140 Q60 120 80 150' stroke='%23a8c5a0' stroke-width='1.5' fill='none'/%3E%3C/svg%3E");
}

.hero-floral--right {
  right: -40px;
  transform: scaleX(-1);
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 200 200'%3E%3Cellipse cx='60' cy='80' rx='30' ry='50' fill='none' stroke='%23a8c5a0' stroke-width='1.5' transform='rotate(-30 60 80)'/%3E%3Cellipse cx='80' cy='60' rx='25' ry='45' fill='none' stroke='%23a8c5a0' stroke-width='1.5' transform='rotate(20 80 60)'/%3E%3Cellipse cx='100' cy='90' rx='28' ry='48' fill='none' stroke='%23a8c5a0' stroke-width='1.5' transform='rotate(-10 100 90)'/%3E%3Ccircle cx='70' cy='100' r='8' fill='none' stroke='%23a8c5a0' stroke-width='1.5'/%3E%3Cpath d='M40 160 Q70 100 100 140' stroke='%23a8c5a0' stroke-width='1.5' fill='none'/%3E%3Cpath d='M30 140 Q60 120 80 150' stroke='%23a8c5a0' stroke-width='1.5' fill='none'/%3E%3C/svg%3E");
}

.hero-content {
  position: relative;
  z-index: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 1.25rem;
}

.hero-eyebrow {
  font-family: 'Lato', sans-serif;
  font-weight: 300;
  font-size: 0.8rem;
  letter-spacing: 0.25em;
  text-transform: uppercase;
  color: var(--sage-lt);
}

.hero-names {
  font-family: 'Cormorant Garamond', serif;
  font-size: clamp(3rem, 10vw, 7rem);
  font-weight: 300;
  font-style: italic;
  color: var(--cream);
  display: flex;
  align-items: center;
  gap: 0.5em;
  line-height: 1;
  letter-spacing: 0.02em;
}

.hero-ampersand {
  font-family: 'Cormorant Garamond', serif;
  font-size: 0.65em;
  color: var(--sage-lt);
  font-style: normal;
}

.hero-date {
  font-family: 'Cormorant Garamond', serif;
  font-size: clamp(1.1rem, 2.5vw, 1.5rem);
  font-style: italic;
  color: var(--mist);
  letter-spacing: 0.05em;
}

.hero-date sup { font-size: 0.6em; vertical-align: super; }

.hero-venue {
  font-family: 'Lato', sans-serif;
  font-weight: 300;
  font-size: 0.85rem;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--sage-lt);
}

/* Countdown */
.countdown {
  display: flex;
  gap: 1.5rem;
  margin: 1rem 0;
}

.countdown-unit {
  display: flex;
  flex-direction: column;
  align-items: center;
  min-width: 64px;
}

.countdown-number {
  font-family: 'Cormorant Garamond', serif;
  font-size: clamp(2.5rem, 6vw, 3.5rem);
  font-weight: 300;
  color: var(--cream);
  line-height: 1;
}

.countdown-label {
  font-family: 'Lato', sans-serif;
  font-size: 0.65rem;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  color: var(--sage-lt);
  margin-top: 0.25rem;
}

.hero-scroll-hint {
  position: absolute;
  bottom: 2rem;
  left: 50%;
  transform: translateX(-50%);
  color: var(--sage-lt);
  font-size: 1.5rem;
  animation: bounce 2s infinite;
  cursor: default;
}

@keyframes bounce {
  0%, 100% { transform: translateX(-50%) translateY(0); opacity: 0.7; }
  50%       { transform: translateX(-50%) translateY(8px); opacity: 1; }
}

/* ============================================================
   SCHEDULE / TIMELINE
   ============================================================ */

.schedule { background-color: var(--cream); }

.timeline {
  list-style: none;
  position: relative;
  max-width: 680px;
  margin: 0 auto;
}

/* Vertical line */
.timeline::before {
  content: '';
  position: absolute;
  left: 120px;
  top: 0;
  bottom: 0;
  width: 1px;
  background: var(--mist);
}

.timeline-item {
  display: grid;
  grid-template-columns: 120px 1px 1fr;
  gap: 0 1.5rem;
  padding: 0 0 2.5rem;
  align-items: start;
}

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

.timeline-time {
  text-align: right;
  font-family: 'Cormorant Garamond', serif;
  font-size: 1rem;
  font-style: italic;
  color: var(--sage);
  padding-top: 0.2rem;
}

.timeline-marker {
  position: relative;
  grid-column: 2;
  display: flex;
  justify-content: center;
}

.timeline-marker::before {
  content: '';
  display: block;
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: var(--sage);
  border: 2px solid var(--cream);
  box-shadow: 0 0 0 2px var(--sage-lt);
  margin-top: 0.3rem;
  flex-shrink: 0;
}

.timeline-body { padding-left: 0; }

.timeline-body h3 {
  font-family: 'Playfair Display', serif;
  font-size: 1.1rem;
  color: var(--forest);
  margin-bottom: 0.4rem;
}

.timeline-body p {
  font-size: 0.9rem;
  color: var(--text-lt);
  line-height: 1.65;
}

/* ============================================================
   TRAVEL
   ============================================================ */

.travel { background-color: var(--parchment); }

.travel-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: 1.5rem;
}

.travel-card {
  background: var(--cream);
  border: 1px solid var(--mist);
  border-radius: calc(var(--radius) * 2);
  padding: 2rem;
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
  box-shadow: var(--shadow);
}

.travel-icon {
  font-size: 1.75rem;
  line-height: 1;
}

.travel-card h3 {
  font-family: 'Playfair Display', serif;
  font-size: 1.15rem;
  color: var(--forest);
}

.travel-card p,
.travel-card address {
  font-size: 0.9rem;
  color: var(--text-lt);
  line-height: 1.65;
}

.travel-card .btn { margin-top: auto; align-self: flex-start; }

/* ============================================================
   GALLERY
   ============================================================ */

.gallery { background-color: var(--cream); }

.gallery-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  grid-template-rows: auto auto;
  gap: 0.75rem;
}

.gallery-placeholder {
  background: var(--mist);
  border: 1px dashed var(--sage-lt);
  border-radius: var(--radius);
  aspect-ratio: 4 / 3;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--sage);
  font-family: 'Cormorant Garamond', serif;
  font-style: italic;
  font-size: 0.95rem;
  letter-spacing: 0.05em;
  transition: background var(--transition);
}

.gallery-placeholder:hover { background: #c2dcc0; }

.gallery-placeholder--tall {
  grid-row: span 2;
  aspect-ratio: auto;
}

.gallery-placeholder--wide {
  grid-column: span 2;
}

/* ============================================================
   RSVP
   ============================================================ */

.rsvp { background-color: var(--parchment); }

.rsvp-form {
  background: var(--cream);
  border: 1px solid var(--mist);
  border-radius: calc(var(--radius) * 2);
  padding: 2.5rem;
  box-shadow: var(--shadow);
}

.form-group {
  display: flex;
  flex-direction: column;
  gap: 0.4rem;
  margin-bottom: 1.5rem;
}

.form-group label {
  font-family: 'Lato', sans-serif;
  font-size: 0.8rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--forest);
  font-weight: 400;
}

.form-group label span { color: var(--sage); }

.form-group input[type="text"],
.form-group input[type="email"],
.form-group select,
.form-group textarea {
  font-family: 'Lato', sans-serif;
  font-size: 0.95rem;
  font-weight: 300;
  color: var(--text);
  background: #fff;
  border: 1px solid #c9d9c6;
  border-radius: var(--radius);
  padding: 0.75rem 1rem;
  transition: border-color var(--transition), box-shadow var(--transition);
  width: 100%;
  appearance: none;
}

.form-group select {
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8' viewBox='0 0 12 8'%3E%3Cpath d='M1 1l5 5 5-5' stroke='%236b8f71' stroke-width='1.5' fill='none' stroke-linecap='round'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 1rem center;
  padding-right: 2.5rem;
  cursor: pointer;
}

.form-group input:focus,
.form-group select:focus,
.form-group textarea:focus {
  outline: none;
  border-color: var(--sage);
  box-shadow: 0 0 0 3px rgba(107,143,113,0.15);
}

.form-group textarea { resize: vertical; min-height: 80px; }

/* Radio buttons */
.radio-group {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}

@media (min-width: 480px) {
  .radio-group { flex-direction: row; gap: 1.5rem; }
}

.radio-label {
  display: flex;
  align-items: center;
  gap: 0.6rem;
  cursor: pointer;
  font-size: 0.95rem;
  font-weight: 300;
  color: var(--text);
  text-transform: none;
  letter-spacing: 0;
}

.radio-label input[type="radio"] {
  width: 18px;
  height: 18px;
  accent-color: var(--pine);
  cursor: pointer;
  flex-shrink: 0;
}

/* Validation */
.form-error {
  font-size: 0.8rem;
  color: #c0392b;
  min-height: 1em;
}

.form-group input.is-invalid,
.form-group textarea.is-invalid {
  border-color: #c0392b;
}

/* Form status */
.form-status {
  margin-top: 1rem;
  font-size: 0.9rem;
  text-align: center;
  min-height: 1.5em;
  padding: 0.5rem;
  border-radius: var(--radius);
}

.form-status.success {
  background: #eaf4eb;
  color: var(--forest);
  border: 1px solid var(--sage-lt);
}

.form-status.error {
  background: #fdf0ef;
  color: #922b21;
  border: 1px solid #f5b7b1;
}

/* ============================================================
   FAQ
   ============================================================ */

.faq { background-color: var(--cream); }

.faq-list {
  display: flex;
  flex-direction: column;
  gap: 0;
  border: 1px solid var(--mist);
  border-radius: calc(var(--radius) * 2);
  overflow: hidden;
  box-shadow: var(--shadow);
}

.faq-item {
  border-bottom: 1px solid var(--mist);
}

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

.faq-question button {
  width: 100%;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  padding: 1.25rem 1.5rem;
  background: var(--cream);
  border: none;
  cursor: pointer;
  text-align: left;
  font-family: 'Playfair Display', serif;
  font-size: 1rem;
  color: var(--forest);
  transition: background var(--transition);
}

.faq-question button:hover { background: var(--mist); }

.faq-question button[aria-expanded="true"] {
  background: var(--mist);
  color: var(--pine);
}

.faq-icon {
  width: 20px;
  height: 20px;
  border-radius: 50%;
  border: 1px solid var(--sage-lt);
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  position: relative;
  transition: transform var(--transition), background var(--transition);
}

.faq-icon::before,
.faq-icon::after {
  content: '';
  position: absolute;
  background: var(--sage);
  border-radius: 2px;
  transition: transform var(--transition), opacity var(--transition);
}

.faq-icon::before { width: 8px; height: 1.5px; }
.faq-icon::after  { width: 1.5px; height: 8px; }

button[aria-expanded="true"] .faq-icon::after {
  transform: rotate(90deg);
  opacity: 0;
}

.faq-answer {
  background: #fff;
  padding: 1.25rem 1.5rem 1.5rem;
  border-top: 1px solid var(--mist);
}

.faq-answer[hidden] { display: none; }

.faq-answer.is-open { display: block; }

.faq-answer p {
  font-size: 0.93rem;
  color: var(--text-lt);
  line-height: 1.75;
}

/* ============================================================
   FOOTER
   ============================================================ */

.site-footer {
  background-color: var(--forest);
  color: var(--mist);
  text-align: center;
  padding: 4rem 1.5rem;
  position: relative;
  overflow: hidden;
}

.footer-floral {
  position: absolute;
  inset: 0;
  opacity: 0.06;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='400' height='200' viewBox='0 0 400 200'%3E%3Cellipse cx='200' cy='100' rx='80' ry='50' fill='none' stroke='%23a8c5a0' stroke-width='1'/%3E%3Cellipse cx='200' cy='100' rx='60' ry='35' fill='none' stroke='%23a8c5a0' stroke-width='1' transform='rotate(45 200 100)'/%3E%3Cellipse cx='200' cy='100' rx='60' ry='35' fill='none' stroke='%23a8c5a0' stroke-width='1' transform='rotate(-45 200 100)'/%3E%3Ccircle cx='200' cy='100' r='10' fill='none' stroke='%23a8c5a0' stroke-width='1'/%3E%3C/svg%3E");
  background-repeat: repeat;
  background-size: 300px;
}

.footer-inner { position: relative; z-index: 1; }

.footer-names {
  font-family: 'Cormorant Garamond', serif;
  font-size: 2.25rem;
  font-style: italic;
  font-weight: 300;
  color: var(--cream);
  margin-bottom: 0.5rem;
}

.footer-date {
  font-family: 'Lato', sans-serif;
  font-size: 0.8rem;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--sage-lt);
  margin-bottom: 1.5rem;
}

.footer-note {
  font-size: 0.85rem;
  color: rgba(168,197,160,0.5);
}

/* ============================================================
   RESPONSIVE
   ============================================================ */

@media (max-width: 768px) {
  /* Nav */
  .nav-toggle { display: flex; }

  .nav-links {
    position: absolute;
    top: 64px;
    left: 0;
    right: 0;
    background: rgba(248,244,238,0.98);
    flex-direction: column;
    align-items: center;
    gap: 0;
    padding: 0;
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.3s ease, padding 0.3s ease;
    box-shadow: 0 8px 16px rgba(30,58,47,0.08);
  }

  .nav-links.open {
    max-height: 400px;
    padding: 1rem 0;
  }

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

  .nav-links a {
    display: block;
    padding: 0.85rem 1.5rem;
    color: var(--text-lt) !important;
  }

  .nav-links a:hover { color: var(--pine) !important; }

  /* Hero */
  .hero-names {
    flex-direction: column;
    gap: 0.1em;
  }

  .hero-ampersand { font-size: 0.5em; }

  .countdown { gap: 0.75rem; }
  .countdown-unit { min-width: 52px; }

  /* Timeline */
  .timeline::before { left: 0; }

  .timeline-item {
    grid-template-columns: 1fr;
    grid-template-rows: auto auto auto;
    padding-left: 1.5rem;
    position: relative;
  }

  .timeline-time {
    text-align: left;
    grid-row: 1;
    font-size: 0.85rem;
    color: var(--sage);
  }

  .timeline-marker {
    display: none;
  }

  .timeline-item::before {
    content: '';
    position: absolute;
    left: 0;
    top: 0.35rem;
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: var(--sage);
    border: 2px solid var(--cream);
    box-shadow: 0 0 0 2px var(--sage-lt);
  }

  /* Gallery */
  .gallery-grid {
    grid-template-columns: repeat(2, 1fr);
  }

  .gallery-placeholder--tall { grid-row: auto; aspect-ratio: 4 / 3; }
  .gallery-placeholder--wide { grid-column: auto; }

  /* RSVP form */
  .rsvp-form { padding: 1.5rem; }

  /* Floral corners */
  .hero-floral { width: 200px; height: 200px; }
}

@media (max-width: 480px) {
  .section { padding: 3.5rem 1rem; }
  .hero { padding: 5rem 1rem 3rem; }
  .countdown { flex-wrap: wrap; justify-content: center; }
  .gallery-grid { grid-template-columns: 1fr; }
  .gallery-placeholder--wide { grid-column: auto; }
}

/* Focus-visible ring */
*:focus-visible {
  outline: 2px solid var(--sage);
  outline-offset: 3px;
}

/* ============================================================
   PORTAL PAGE  (/my-rsvp)
   ============================================================ */

body.portal-page {
  background: var(--parchment);
}

.portal-main {
  min-height: 100svh;
  padding: 80px 1rem 4rem;
  display: flex;
  flex-direction: column;
  align-items: center;
}

/* ---- Entry card (code form) ------------------------------ */

.portal-view {
  width: 100%;
  max-width: 560px;
}

.portal-card--entry {
  max-width: 480px;
  margin: 2rem auto;
}

.portal-entry-header {
  text-align: center;
  margin-bottom: 2rem;
}

.portal-entry-sub {
  font-size: 0.9rem;
  color: var(--text-lt);
  max-width: 38ch;
  margin: 0.5rem auto 0;
}

.code-form .form-group input {
  text-align: center;
  font-family: 'Lato', monospace;
  font-size: 1.15rem;
  letter-spacing: 0.2em;
  text-transform: uppercase;
}

.portal-back-link {
  text-align: center;
  margin-top: 1.25rem;
  font-size: 0.85rem;
  color: var(--text-lt);
}

/* ---- Portal view (loaded) -------------------------------- */

#view-portal {
  max-width: 720px;
  width: 100%;
}

.portal-title {
  font-family: 'Cormorant Garamond', serif;
  font-size: clamp(2rem, 5vw, 3rem);
  font-weight: 300;
  font-style: italic;
  color: var(--forest);
  margin: 0;
}

.portal-header-bar {
  background: var(--cream);
  border-bottom: 1px solid var(--mist);
  padding: 1.5rem;
  border-radius: calc(var(--radius) * 2) calc(var(--radius) * 2) 0 0;
  margin-bottom: 0;
}

.portal-header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  max-width: 720px;
  margin: 0 auto;
}

.role-badge {
  background: var(--pine);
  color: #fff;
  font-size: 0.7rem;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  padding: 0.3rem 0.75rem;
  border-radius: 20px;
  font-family: 'Lato', sans-serif;
  flex-shrink: 0;
}

.portal-body {
  display: flex;
  flex-direction: column;
  gap: 1.25rem;
  padding-top: 1.25rem;
}

/* ---- Portal card ----------------------------------------- */

.portal-card {
  background: var(--cream);
  border: 1px solid var(--mist);
  border-radius: calc(var(--radius) * 2);
  padding: 2rem;
  box-shadow: var(--shadow);
}

.portal-card-title {
  font-family: 'Playfair Display', serif;
  font-size: 1.3rem;
  color: var(--forest);
  margin-bottom: 0.25rem;
}

.portal-card-sub {
  font-size: 0.85rem;
  color: var(--sage);
  font-family: 'Lato', sans-serif;
  letter-spacing: 0.05em;
  margin-bottom: 1rem;
}

.portal-card-desc {
  font-size: 0.9rem;
  color: var(--text-lt);
  margin-bottom: 1.5rem;
}

.portal-hint {
  font-size: 0.85rem;
  color: var(--text-lt);
  margin-top: 0.75rem;
  font-style: italic;
}

/* ---- RSVP status chips ----------------------------------- */

.status-chips {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  margin-bottom: 1rem;
}

.status-chip {
  display: inline-block;
  padding: 0.35rem 0.85rem;
  border-radius: 20px;
  font-size: 0.8rem;
  font-family: 'Lato', sans-serif;
  font-weight: 400;
}

.status-chip--yes {
  background: #e8f5e9;
  color: #2e7d32;
  border: 1px solid #a5d6a7;
}

.status-chip--no {
  background: #fbe9e7;
  color: #bf360c;
  border: 1px solid #ffab91;
}

.status-chip--neutral {
  background: var(--mist);
  color: var(--forest);
  border: 1px solid var(--sage-lt);
}

.status-chip--pending {
  background: #fff9e6;
  color: #7a5800;
  border: 1px solid #ffe082;
}

.status-message--pending {
  font-family: 'Cormorant Garamond', serif;
  font-size: 1.15rem;
  font-style: italic;
  color: var(--text-lt);
  margin-bottom: 0.5rem;
}

.status-detail { margin: 0.75rem 0 1rem; }

.status-row {
  display: grid;
  grid-template-columns: 110px 1fr;
  gap: 0.25rem 0.75rem;
  padding: 0.4rem 0;
  border-bottom: 1px solid var(--mist);
  font-size: 0.9rem;
}

.status-row:last-child { border-bottom: none; }

.status-row dt {
  font-weight: 400;
  font-size: 0.78rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--sage);
}

.status-row dd { color: var(--text); }

.portal-edit-btn { margin-top: 1rem; }

/* ---- Family card ----------------------------------------- */

.portal-card--family {
  border-left: 3px solid var(--pine);
}

.family-badge {
  display: inline-block;
  background: var(--pine);
  color: #fff;
  font-size: 0.65rem;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  font-family: 'Lato', sans-serif;
  padding: 0.2rem 0.6rem;
  border-radius: 12px;
  margin-bottom: 0.75rem;
}

/* ---- Evening dinner info --------------------------------- */

.evening-info-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 1rem;
  margin-bottom: 1.25rem;
}

.evening-info-item {
  display: flex;
  gap: 0.75rem;
  align-items: flex-start;
  font-size: 0.9rem;
}

.evening-info-icon {
  font-size: 1.25rem;
  flex-shrink: 0;
  line-height: 1.4;
}

.evening-info-item strong {
  display: block;
  font-size: 0.78rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--sage);
  margin-bottom: 0.2rem;
}

.evening-info-item p { color: var(--text-lt); line-height: 1.55; }

.portal-note {
  background: var(--mist);
  border-radius: var(--radius);
  padding: 0.85rem 1rem;
  font-size: 0.85rem;
  color: var(--text-lt);
  line-height: 1.6;
}

/* ---- Lunch selection form -------------------------------- */

.lunch-menu-key {
  font-size: 0.8rem;
  color: var(--text-lt);
  margin-bottom: 1.25rem;
}

.menu-tag {
  display: inline-block;
  background: var(--mist);
  color: var(--pine);
  font-size: 0.7rem;
  padding: 0.1rem 0.4rem;
  border-radius: 3px;
  font-family: 'Lato', sans-serif;
  border: 1px solid var(--sage-lt);
}

.lunch-guest-row {
  border: 1px solid var(--mist);
  border-radius: var(--radius);
  padding: 1.25rem;
  margin-bottom: 1rem;
  background: #fff;
}

.lunch-guest-header {
  margin-bottom: 0.75rem;
}

.lunch-guest-num {
  font-family: 'Playfair Display', serif;
  font-size: 0.95rem;
  color: var(--forest);
}

.lunch-courses {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 1rem;
  margin-bottom: 0.75rem;
}

.menu-fieldset {
  border: none;
  padding: 0;
}

.menu-fieldset legend {
  font-size: 0.78rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--forest);
  font-family: 'Lato', sans-serif;
  font-weight: 400;
  margin-bottom: 0.5rem;
}

.menu-fieldset .optional {
  text-transform: none;
  letter-spacing: 0;
  color: var(--sage);
  font-size: 0.75rem;
}

.menu-fieldset .required-star { color: var(--sage); }

.menu-options {
  display: flex;
  flex-direction: column;
  gap: 0.4rem;
}

.menu-option {
  display: flex;
  flex-direction: column;
  padding: 0.6rem 0.75rem;
  border: 1px solid var(--mist);
  border-radius: var(--radius);
  cursor: pointer;
  transition: border-color var(--transition), background var(--transition);
  background: var(--cream);
}

.menu-option input[type="radio"] { display: none; }

.menu-option:hover { border-color: var(--sage-lt); background: var(--mist); }

.menu-option--selected {
  border-color: var(--pine);
  background: #f0f7f1;
}

.menu-option-label {
  font-size: 0.9rem;
  color: var(--text);
  font-family: 'Lato', sans-serif;
  font-weight: 400;
  line-height: 1.3;
}

.menu-option-note {
  font-size: 0.75rem;
  color: var(--sage);
  margin-top: 0.15rem;
}

/* Lunch confirmed state */
.lunch-confirmed-banner {
  display: flex;
  gap: 0.75rem;
  align-items: flex-start;
  background: #eaf4eb;
  border: 1px solid #a5d6a7;
  border-radius: var(--radius);
  padding: 1rem;
  margin-bottom: 1.25rem;
  font-size: 0.9rem;
}

.lunch-confirmed-banner > span {
  font-size: 1.25rem;
  color: #2e7d32;
  flex-shrink: 0;
  line-height: 1.3;
}

.lunch-confirmed-banner strong { display: block; color: var(--forest); }
.lunch-confirmed-banner p { color: var(--text-lt); font-size: 0.85rem; margin-top: 0.2rem; }

.lunch-summary-row {
  padding: 0.75rem 0;
  border-bottom: 1px solid var(--mist);
  font-size: 0.9rem;
}

.lunch-summary-row:last-child { border-bottom: none; }

.lunch-summary-row strong {
  display: block;
  color: var(--forest);
  margin-bottom: 0.3rem;
  font-family: 'Playfair Display', serif;
  font-weight: 400;
}

.lunch-summary-row ul {
  list-style: none;
  padding: 0;
  display: flex;
  flex-wrap: wrap;
  gap: 0.25rem 1rem;
  color: var(--text-lt);
}

/* ============================================================
   ADMIN PAGE (/admin)
   ============================================================ */

body.admin-page {
  background: #f2f4f2;
  font-family: 'Lato', sans-serif;
}

/* ---- Login ------------------------------------------------ */

.admin-login {
  min-height: 100svh;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 2rem;
}

.admin-login-card {
  background: var(--cream);
  border: 1px solid var(--mist);
  border-radius: calc(var(--radius) * 2);
  padding: 2.5rem;
  width: 100%;
  max-width: 400px;
  box-shadow: var(--shadow);
  text-align: center;
}

.admin-login-card .portal-title { margin-bottom: 0; }
.admin-login-card .form-group   { text-align: left; margin-top: 1.5rem; }

/* ---- Dashboard nav --------------------------------------- */

.admin-nav {
  background: var(--forest);
  padding: 0 1.5rem;
  position: sticky;
  top: 0;
  z-index: 50;
}

.admin-nav-inner {
  max-width: 1200px;
  margin: 0 auto;
  display: flex;
  align-items: center;
  gap: 1rem;
  height: 56px;
}

.admin-nav .nav-brand {
  font-family: 'Cormorant Garamond', serif;
  font-style: italic;
  font-size: 1.25rem;
  color: var(--cream);
  text-decoration: none;
  flex-shrink: 0;
}

.admin-tabs {
  display: flex;
  gap: 0.25rem;
  flex: 1;
  overflow-x: auto;
}

.admin-tab {
  background: none;
  border: none;
  color: rgba(248,244,238,0.65);
  font-family: 'Lato', sans-serif;
  font-size: 0.8rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  padding: 0.5rem 0.85rem;
  cursor: pointer;
  border-radius: var(--radius);
  white-space: nowrap;
  transition: color var(--transition), background var(--transition);
}

.admin-tab:hover  { color: var(--cream); background: rgba(255,255,255,0.08); }
.admin-tab.active { color: var(--cream); background: rgba(255,255,255,0.15); }

.admin-signout {
  flex-shrink: 0;
  font-size: 0.75rem;
  padding: 0.45rem 1rem;
  border-color: rgba(255,255,255,0.3);
  color: rgba(248,244,238,0.8);
}

.admin-signout:hover { border-color: var(--sage-lt); color: var(--cream); background: transparent; }

/* ---- Main layout ----------------------------------------- */

.admin-main {
  max-width: 1200px;
  margin: 0 auto;
  padding: 2rem 1.5rem;
}

.admin-section { margin-bottom: 3rem; }

.admin-section-title {
  font-family: 'Playfair Display', serif;
  font-size: 1.35rem;
  color: var(--forest);
  margin-bottom: 1rem;
}

.admin-section-subtitle {
  font-family: 'Playfair Display', serif;
  font-size: 1.1rem;
  color: var(--forest);
  margin: 2rem 0 0.75rem;
}

.admin-section-desc {
  font-size: 0.85rem;
  color: var(--text-lt);
  margin-bottom: 1.25rem;
}

.admin-section-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  flex-wrap: wrap;
  margin-bottom: 1rem;
}

/* ---- Stats grid ------------------------------------------ */

.admin-stats {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(140px, 1fr));
  gap: 1rem;
  margin-bottom: 1.5rem;
}

.stat-card {
  background: var(--cream);
  border: 1px solid var(--mist);
  border-radius: calc(var(--radius) * 2);
  padding: 1.25rem;
  text-align: center;
  box-shadow: var(--shadow);
}

.stat-number {
  display: block;
  font-family: 'Cormorant Garamond', serif;
  font-size: 2.5rem;
  font-weight: 300;
  color: var(--forest);
  line-height: 1;
  margin-bottom: 0.4rem;
}

.stat-label {
  font-size: 0.75rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--sage);
}

.admin-refresh-row {
  display: flex;
  align-items: center;
  gap: 1rem;
}

.admin-last-updated {
  font-size: 0.8rem;
  color: var(--text-lt);
  font-style: italic;
}

/* ---- Tables ---------------------------------------------- */

.admin-table-wrap {
  overflow-x: auto;
  border-radius: calc(var(--radius) * 2);
  border: 1px solid var(--mist);
  box-shadow: var(--shadow);
  background: var(--cream);
  margin-bottom: 1rem;
}

.admin-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.875rem;
  white-space: nowrap;
}

.admin-table th {
  background: var(--parchment);
  padding: 0.7rem 0.9rem;
  text-align: left;
  font-size: 0.72rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--sage);
  font-weight: 400;
  border-bottom: 1px solid var(--mist);
}

.admin-table td {
  padding: 0.7rem 0.9rem;
  border-bottom: 1px solid var(--mist);
  color: var(--text);
  vertical-align: middle;
}

.admin-table tr:last-child td { border-bottom: none; }
.admin-table tr:hover td { background: #f5f1eb; }

.td-wrap {
  white-space: normal;
  max-width: 180px;
  font-size: 0.82rem;
  color: var(--text-lt);
}

.admin-empty {
  text-align: center;
  padding: 2rem;
  color: var(--text-lt);
  font-style: italic;
  font-size: 0.9rem;
}

/* Status + role pills */
.status-pill {
  display: inline-block;
  padding: 0.2rem 0.6rem;
  border-radius: 12px;
  font-size: 0.75rem;
  font-family: 'Lato', sans-serif;
}

.status-pill--yes     { background: #e8f5e9; color: #2e7d32; }
.status-pill--no      { background: #fbe9e7; color: #bf360c; }
.status-pill--pending { background: #fff9e6; color: #7a5800; }

.role-pill {
  display: inline-block;
  padding: 0.2rem 0.55rem;
  border-radius: 12px;
  font-size: 0.72rem;
  font-family: 'Lato', sans-serif;
}

.role-pill--family { background: var(--mist); color: var(--forest); border: 1px solid var(--sage-lt); }
.role-pill--guest  { background: #f5f1eb; color: var(--text-lt); }

.code-mono {
  font-family: 'Courier New', Courier, monospace;
  font-size: 0.88rem;
  color: var(--pine);
  letter-spacing: 0.05em;
}

.btn-copy {
  background: none;
  border: 1px solid var(--sage-lt);
  color: var(--pine);
  font-size: 0.75rem;
  padding: 0.25rem 0.6rem;
  border-radius: var(--radius);
  cursor: pointer;
  font-family: 'Lato', sans-serif;
  transition: background var(--transition);
}

.btn-copy:hover { background: var(--mist); }

/* ---- Codes tab layout ------------------------------------ */

.admin-codes-layout {
  display: grid;
  grid-template-columns: 340px 1fr;
  gap: 1.5rem;
  align-items: start;
}

.admin-create-card {
  background: var(--cream);
  border: 1px solid var(--mist);
  border-radius: calc(var(--radius) * 2);
  padding: 1.5rem;
  box-shadow: var(--shadow);
  position: sticky;
  top: 72px;
}

.new-code-result {
  margin-top: 1.5rem;
  padding: 1.25rem;
  background: #f0f7f1;
  border: 1px solid var(--sage-lt);
  border-radius: var(--radius);
  font-size: 0.85rem;
}

.new-code-label,
.new-code-url-label {
  font-size: 0.72rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--sage);
  margin-bottom: 0.3rem;
  margin-top: 0.75rem;
}

.new-code-display {
  font-family: 'Courier New', monospace;
  font-size: 1.5rem;
  color: var(--forest);
  letter-spacing: 0.15em;
  font-weight: bold;
  margin-bottom: 0.25rem;
}

.new-code-url {
  font-family: 'Courier New', monospace;
  font-size: 0.78rem;
  color: var(--pine);
  word-break: break-all;
  margin-bottom: 0.75rem;
}

.new-code-hint {
  font-size: 0.8rem;
  color: var(--text-lt);
  line-height: 1.55;
}

.admin-filter-row {
  display: flex;
  gap: 1rem;
  align-items: center;
}

.filter-label {
  display: flex;
  align-items: center;
  gap: 0.4rem;
  font-size: 0.82rem;
  color: var(--text-lt);
  cursor: pointer;
}

/* ---- Admin responsive ------------------------------------ */

@media (max-width: 900px) {
  .admin-codes-layout {
    grid-template-columns: 1fr;
  }
  .admin-create-card { position: static; }
}

@media (max-width: 600px) {
  .admin-main  { padding: 1.25rem 0.75rem; }
  .admin-stats { grid-template-columns: repeat(2, 1fr); }
}

/* ---- Main site RSVP additions --------------------------- */

.form-label-optional {
  font-size: 0.75rem;
  color: var(--sage);
  font-weight: 300;
  letter-spacing: 0;
  text-transform: none;
  display: block;
  margin-top: 0.15rem;
}

.rsvp-portal-link {
  text-align: center;
  margin-top: 1rem;
  font-size: 0.85rem;
  color: var(--text-lt);
}

.rsvp-portal-link a {
  color: var(--pine);
  text-decoration: underline;
  text-underline-offset: 3px;
}

/* ---- Portal page responsive ------------------------------ */

@media (max-width: 600px) {
  .portal-main { padding: 72px 0.75rem 3rem; }

  .portal-card { padding: 1.25rem; }

  .lunch-courses { grid-template-columns: 1fr; }

  .evening-info-grid { grid-template-columns: 1fr; }

  .portal-header-inner { flex-direction: column; align-items: flex-start; gap: 0.5rem; }

  .status-row { grid-template-columns: 90px 1fr; }
}
