﻿/* Reset */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

:root {
  --bg: #f6f1ed;
  --bg-alt: #f1ebe6;
  --page-gradient: linear-gradient(180deg, #8a5a66 0%, #e2d8ee 55%, #fbf9f7 100%);
  --accent: #e8d2cd;
  --accent-strong: #dcb8b1;
  --text: #6e4a55;
  --muted: #8a6b73;
  --card: #ffffff;
  --shadow: 0 16px 40px rgba(63, 61, 58, 0.08);
  --radius: 18px;
  --container: 1100px;
  --section-padding: clamp(38px, 6vw, 64px);
  --hero-extra-space: clamp(18px, 4vw, 36px);
  --hero-title-size: clamp(3rem, 8vw, 4.6rem);
  --hero-phrase-size: clamp(1.8rem, 4.2vw, 2.6rem);
  --countdown-size: clamp(1.9rem, 5.2vw, 3rem);
}

html {
  scroll-behavior: smooth;
}

body {
  font-family: "Manrope", system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  color: var(--text);
  background-color: #ffffff;
  background-image: var(--page-gradient);
  font-size: 16px;
  line-height: 1.65;
  text-rendering: optimizeLegibility;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

@keyframes section-reveal {
  0% {
    opacity: 0;
    transform: translateY(34px) scale(0.98);
    filter: blur(8px);
  }
  55% {
    opacity: 1;
    transform: translateY(0) scale(1);
    filter: blur(0);
  }
  100% {
    opacity: 1;
    transform: translateY(0) scale(1);
    filter: blur(0);
  }
}

@keyframes fade-up {
  from {
    opacity: 0;
    transform: translateY(18px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

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

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

/* Layout */
.container {
  width: min(100% - 32px, var(--container));
  margin: 0 auto;
}

.section {
  padding: var(--section-padding) 0;
}

.section.alt {
  background: transparent;
}

@supports (animation-timeline: view()) {
  .section {
    opacity: 0;
    transform: translateY(26px);
    animation: section-reveal 1.6s ease-out forwards;
    view-timeline-name: --section;
    view-timeline-axis: block;
    animation-timeline: --section;
    animation-range: entry 10% cover 45%;
  }
}

.scroll-reveal .section {
  opacity: 0;
  transform: translateY(32px) scale(0.985);
  filter: blur(8px);
  transition: opacity 0.9s ease,
    transform 0.9s cubic-bezier(0.2, 0.7, 0.25, 1),
    filter 0.9s ease;
  will-change: opacity, transform, filter;
}

.scroll-reveal .section.is-visible {
  opacity: 1;
  transform: translateY(0) scale(1);
  filter: blur(0);
}

.scroll-reveal .section .container > * {
  opacity: 0;
  transform: translateY(14px);
  transition: opacity 0.6s ease, transform 0.6s ease;
}

.scroll-reveal .section.is-visible .container > * {
  opacity: 1;
  transform: translateY(0);
}

.scroll-reveal .section.is-visible .container > *:nth-child(1) { transition-delay: 0.03s; }
.scroll-reveal .section.is-visible .container > *:nth-child(2) { transition-delay: 0.09s; }
.scroll-reveal .section.is-visible .container > *:nth-child(3) { transition-delay: 0.15s; }
.scroll-reveal .section.is-visible .container > *:nth-child(4) { transition-delay: 0.21s; }
.scroll-reveal .section.is-visible .container > *:nth-child(5) { transition-delay: 0.27s; }
.scroll-reveal .section.is-visible .container > *:nth-child(6) { transition-delay: 0.33s; }



h1 {
  font-family: "Prata", "Times New Roman", serif;
  font-weight: 700;
  letter-spacing: 0.015em;
}

h2 {
  font-family: "Prata", "Times New Roman", serif;
  font-weight: 700;
  letter-spacing: 0.015em;
}

h2 {
  font-size: clamp(1.5rem, 2.1vw, 2.1rem);
  margin-bottom: 24px;
}

#details h2 {
  color: var(--text);
}


h3 {
  font-family: "Prata", "Times New Roman", serif;
  font-weight: 700;
  letter-spacing: 0.01em;
  font-size: 1.05rem;
  margin-bottom: 10px;
}

p {
  color: var(--text);
}

.lead {
  max-width: 720px;
  color: var(--muted);
  margin-bottom: 24px;
}

.section .container > *:last-child {
  margin-bottom: 0;
}


.muted {
  color: var(--muted);
  font-size: 0.95rem;
}

/* Header */
.site-header {
  position: sticky;
  top: 0;
  z-index: 10;
  background: rgba(246, 241, 237, 0.85);
  backdrop-filter: blur(8px);
  border-bottom: 1px solid rgba(63, 61, 58, 0.08);
}

.nav {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 16px 0;
  flex-direction: column;
}

.logo {
  font-weight: 600;
  letter-spacing: 0;
  text-transform: uppercase;
  font-size: 1.1rem;
  color: #c7b0e3;
}

.nav-links {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 12px;
  font-size: 0.9rem;
  color: var(--muted);
}

.nav-links a:hover {
  color: var(--text);
}

/* Hero */
.hero {
  padding: var(--section-padding) 0 calc(var(--section-padding) + var(--hero-extra-space));
  background: transparent;
  color: #f7f2f0;
}

.hero-content {
  text-align: center;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 14px;
}

.hero-content > * {
  margin-left: auto;
  margin-right: auto;
}

.hero-content > * {
  opacity: 0;
  animation: fade-up 0.9s ease forwards;
}

.hero-content > *:nth-child(1) { animation-delay: 0.05s; }
.hero-content > *:nth-child(2) { animation-delay: 0.15s; }
.hero-content > *:nth-child(3) { animation-delay: 0.25s; }
.hero-content > *:nth-child(4) { animation-delay: 0.35s; }
.hero-content > *:nth-child(5) { animation-delay: 0.45s; }
.hero-content > *:nth-child(6) { animation-delay: 0.55s; }

.hero-photo {
  width: clamp(260px, 70vw, 440px);
  aspect-ratio: 1 / 1;
  border-radius: 50%;
  background: url("assets/hero-photo.webp") center/115% no-repeat;
  background-color: rgba(255, 255, 255, 0.08);
  box-shadow: none;
  border: 1px solid rgba(255, 255, 255, 0.22);
  margin: 0 auto 6px;
}

.eyebrow {
  text-transform: uppercase;
  letter-spacing: 0.16em;
  font-size: 0.74rem;
  font-weight: 500;
  color: rgba(255, 255, 255, 0.7);
}

.hero h1 {
  font-weight: 400;
  width: clamp(260px, 70vw, 440px);
  font-size: var(--hero-title-size);
  line-height: 1.05;
  letter-spacing: 0.06em;
  text-align: center;
  margin: 0 auto;
  font-variant-numeric: tabular-nums;
}

.date {
  font-size: 1.2rem;
  color: #edd7d3;
}

.subtitle {
  max-width: 560px;
  font-size: 1.05rem;
  color: #f7f2f0;
  font-family: "Manrope", system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
}

.hero-note {
  max-width: 680px;
  color: rgba(255, 255, 255, 0.68);
  font-size: 0.95rem;
  line-height: 1.7;
}

.hero-phrase {
  font-family: "Prata", "Times New Roman", serif;
  font-size: var(--hero-phrase-size);
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: #f7f2f0;
  font-weight: 700;
}

.btn {
  margin-top: 12px;
  display: inline-block;
  padding: 12px 28px;
  border-radius: 999px;
  background: #f3ebe7;
  color: var(--text);
  font-weight: 600;
  transition: transform 0.2s ease, background 0.2s ease;
}

.btn:hover {
  background: #e8dcd7;
  transform: translateY(-1px);
}

.rsvp-btn {
  display: block;
  width: fit-content;
  margin: 24px auto 0;
  background: var(--text);
  color: #f7f2f0;
  font-size: 1.05rem;
  padding: 16px 36px;
}

.rsvp-btn:hover {
  background: #5a3c46;
}

/* Cards */
.cards {
  display: grid;
  gap: 24px;
}

.card {
  background: var(--card);
  padding: 24px;
  border-radius: var(--radius);
  box-shadow: var(--shadow);
}

.card .time {
  font-size: 1.4rem;
  color: var(--accent-strong);
  margin-bottom: 12px;
}

/* Details */
.details {
  display: grid;
  gap: 24px;
}

.details-title,
.details-meta {
  font-family: "Manrope", system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  font-size: 1rem;
  font-weight: 600;
  letter-spacing: 0.02em;
  color: var(--text);
}

.details-title {
  margin-bottom: 8px;
}

.details-meta {
  margin-top: 12px;
}

.map-thumb {
  display: block;
  width: min(100%, 260px);
  aspect-ratio: 1 / 1;
  border-radius: 50%;
  overflow: hidden;
  border: 1px solid rgba(110, 74, 85, 0.18);
  box-shadow: 0 12px 30px rgba(63, 61, 58, 0.08);
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.map-thumb:hover {
  transform: translateY(-1px);
  box-shadow: 0 16px 36px rgba(63, 61, 58, 0.12);
}

.map-thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

/* Timeline */
.timeline {
  --snake-width: 140px;
  --snake-offset: 36px;
  --timeline-line: rgba(110, 74, 85, 0.35);
  --timeline-connector: 60px;
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 26px;
  position: relative;
  padding: 10px 0 6px;
  color: var(--text);
}

.timeline::before {
  content: "";
  position: absolute;
  left: 50%;
  top: 0;
  bottom: 0;
  width: 2px;
  transform: translateX(-50%);
  background: linear-gradient(180deg, rgba(110, 74, 85, 0.15), var(--timeline-line), rgba(110, 74, 85, 0.15));
  opacity: 1;
  pointer-events: none;
}

.timeline-item {
  display: grid;
  grid-template-columns: 88px 20px 1fr;
  gap: 12px;
  align-items: center;
  position: relative;
  min-height: 0;
  z-index: 1;
  width: min(100%, 520px);
  max-width: calc(50% - var(--timeline-connector));
  padding: 16px 20px;
  border-radius: 18px;
  background: rgba(255, 255, 255, 0.72);
  border: 1px solid rgba(110, 74, 85, 0.12);
  box-shadow: 0 16px 34px rgba(63, 61, 58, 0.08);
  backdrop-filter: blur(6px);
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.timeline-item::before {
  content: "";
  position: absolute;
  top: 50%;
  width: var(--timeline-connector);
  height: 2px;
  background: var(--timeline-line);
  transform: translateY(-50%);
}

.timeline-item:nth-child(odd) {
  align-self: flex-start;
}

.timeline-item:nth-child(even) {
  align-self: flex-end;
}

.timeline-item:nth-child(odd)::before {
  right: calc(-1 * var(--timeline-connector));
}

.timeline-item:nth-child(even)::before {
  left: calc(-1 * var(--timeline-connector));
}

.timeline-dot {
  width: 14px;
  height: 14px;
  border-radius: 50%;
  background: radial-gradient(circle, #ffffff 0 35%, #c9a5ac 36% 70%, #6e4a55 71% 100%);
  position: absolute;
  top: 50%;
  z-index: 2;
  box-shadow: 0 4px 10px rgba(110, 74, 85, 0.25);
}

.timeline-item:nth-child(odd) .timeline-dot {
  right: calc(-1 * var(--timeline-connector));
  transform: translate(50%, -50%);
}

.timeline-item:nth-child(even) .timeline-dot {
  left: calc(-1 * var(--timeline-connector));
  transform: translate(-50%, -50%);
}

.timeline-time {
  font-weight: 600;
  letter-spacing: 0.02em;
  text-align: center;
  padding: 6px 10px;
  border-radius: 999px;
  background: rgba(110, 74, 85, 0.08);
  border: 1px solid rgba(110, 74, 85, 0.18);
}

.timeline-dash {
  text-align: center;
  color: rgba(110, 74, 85, 0.45);
  font-weight: 600;
  justify-self: center;
}

.timeline-text {
  color: var(--text);
  margin: 0;
  font-weight: 500;
}

.timeline-item:hover {
  transform: translateY(-2px);
  box-shadow: 0 20px 40px rgba(63, 61, 58, 0.12);
}

@media (max-width: 900px) {
  .timeline {
    --timeline-connector: 18px;
  }

  .timeline::before {
    left: 18px;
    transform: none;
  }

  .timeline-item {
    width: auto;
    max-width: none;
    margin-left: 36px;
    align-self: stretch;
  }

  .timeline-item:nth-child(odd),
  .timeline-item:nth-child(even) {
    align-self: stretch;
  }

  .timeline-item:nth-child(odd)::before,
  .timeline-item:nth-child(even)::before {
    left: calc(-1 * var(--timeline-connector));
    right: auto;
  }

  .timeline-item:nth-child(odd) .timeline-dot,
  .timeline-item:nth-child(even) .timeline-dot {
    left: calc(-1 * var(--timeline-connector));
    right: auto;
    transform: translate(-50%, -50%);
  }
}

/* Countdown */
.countdown {
  display: flex;
  align-items: center;
  justify-content: center;
  flex-wrap: nowrap;
  gap: 4px;
  white-space: nowrap;
  color: var(--text);
  font-family: "Prata", "Times New Roman", serif;
  font-size: var(--countdown-size);
  font-weight: 400;
  letter-spacing: 0.03em;
  text-align: center;
  font-variant-numeric: tabular-nums;
  line-height: 1.05;
}

.countdown-part {
  display: inline-flex;
  align-items: baseline;
  gap: 4px;
}

.countdown-unit {
  font-size: 0.6em;
}

.countdown-separator {
  opacity: 0.85;
}


.countdown-note {
  margin-top: 14px;
  text-align: center;
  color: var(--muted);
}

/* Route */
.info-grid {
  display: grid;
  gap: 20px;
}

.info-item {
  display: grid;
  grid-template-columns: 48px 1fr;
  gap: 16px;
  align-items: start;
  padding: 16px 20px;
  background: var(--card);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
}

.icon {
  width: 44px;
  height: 44px;
  border-radius: 50%;
  background: var(--accent);
  color: #fff;
  display: grid;
  place-items: center;
  font-weight: 600;
}

/* Dress code */
.palette {
  display: flex;
  gap: 14px;
  flex-wrap: wrap;
}

.swatch {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  box-shadow: inset 0 0 0 1px rgba(63, 61, 58, 0.08);
}

.swatch-1 { background: #e8d8cf; }
.swatch-2 { background: #d7e0d3; }
.swatch-3 { background: #cfc6bd; }
.swatch-4 { background: #f1e9e2; }

/* RSVP */
.contacts {
  display: grid;
  gap: 14px;
  max-width: 520px;
}

.contact-item {
  display: grid;
  grid-template-columns: 44px 1fr;
  gap: 12px;
  align-items: center;
  padding: 0;
  border-radius: 0;
  background: transparent;
  box-shadow: none;
  transition: color 0.2s ease;
}

.contact-item:hover {
  color: var(--text);
}

/* Footer */
.site-footer {
  border-top: 1px solid rgba(63, 61, 58, 0.1);
  padding: 32px 0 40px;
  text-align: center;
  color: var(--muted);
}

/* Responsive */
@media (min-width: 768px) {
  .nav {
    flex-direction: row;
  }

  .nav-links {
    justify-content: flex-end;
    gap: 18px;
    font-size: 0.95rem;
  }

  .cards {
    grid-template-columns: repeat(2, 1fr);
  }

  .details {
    grid-template-columns: 1.2fr 0.8fr;
    align-items: center;
  }

  .info-grid {
    grid-template-columns: repeat(2, 1fr);
  }

  .contacts {
    grid-template-columns: repeat(2, 1fr);
    max-width: none;
  }
}

@media (min-width: 1024px) {
}

@media (max-width: 600px) {
  h2 {
    font-size: 1.85rem;
  }

  .hero-photo {
    width: min(92vw, 380px);
  }

  .map-thumb {
    width: min(90vw, 320px);
    margin: 0 auto;
  }
}

@media (prefers-reduced-motion: reduce) {
  .hero-content > *,
  .section {
    animation: none;
    opacity: 1;
    transform: none;
  }

  .scroll-reveal .section,
  .scroll-reveal .section .container > * {
    transition: none;
    filter: none;
  }
}
