:root {
  --bg: #f4ede4;
  --bg-soft: rgba(255, 250, 244, 0.68);
  --surface: rgba(255, 251, 247, 0.76);
  --surface-strong: rgba(255, 251, 247, 0.92);
  --border: rgba(53, 82, 74, 0.14);
  --text: #1d2925;
  --muted: rgba(29, 41, 37, 0.7);
  --accent: #35524a;
  --accent-soft: rgba(53, 82, 74, 0.1);
  --accent-warm: #a47045;
  --shadow: 0 24px 80px rgba(61, 44, 32, 0.12);
  --radius-xl: 32px;
  --radius-lg: 24px;
  --radius-md: 18px;
  --radius-sm: 14px;
  --container: min(1160px, calc(100vw - 40px));
  --ease: 240ms ease;
}

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

[hidden] {
  display: none !important;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  min-height: 100vh;
  color: var(--text);
  background:
    radial-gradient(circle at top left, rgba(164, 112, 69, 0.12), transparent 30%),
    linear-gradient(180deg, #f7f1ea 0%, #f4ede4 45%, #efe7dd 100%);
  font-family: "Sora", sans-serif;
  line-height: 1.6;
}

body::selection {
  background: rgba(164, 112, 69, 0.18);
}

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

figure {
  margin: 0;
}

button,
input,
textarea {
  font: inherit;
}

button {
  cursor: pointer;
}

.ambient {
  position: fixed;
  inset: auto;
  pointer-events: none;
  border-radius: 999px;
  filter: blur(40px);
  opacity: 0.78;
  z-index: 0;
}

.ambient-one {
  top: 9vh;
  right: max(-14vw, -120px);
  width: 30vw;
  height: 30vw;
  min-width: 320px;
  min-height: 320px;
  background: radial-gradient(circle, rgba(164, 112, 69, 0.28), transparent 68%);
}

.ambient-two {
  bottom: 10vh;
  left: max(-12vw, -90px);
  width: 26vw;
  height: 26vw;
  min-width: 280px;
  min-height: 280px;
  background: radial-gradient(circle, rgba(53, 82, 74, 0.18), transparent 72%);
}

.access-screen,
.site-shell {
  position: relative;
  z-index: 1;
}

.access-screen {
  min-height: 100vh;
  display: grid;
  place-items: center;
  padding: 24px;
}

.access-card {
  width: min(540px, 100%);
  padding: clamp(28px, 4vw, 44px);
  border: 1px solid var(--border);
  border-radius: var(--radius-xl);
  background: rgba(255, 251, 247, 0.88);
  backdrop-filter: blur(18px);
  box-shadow: var(--shadow);
}

.access-form {
  display: grid;
  gap: 18px;
  margin: 24px 0 18px;
}

.site-shell {
  width: var(--container);
  margin: 0 auto;
  padding: 24px 0 56px;
}

.topbar {
  position: sticky;
  top: 18px;
  z-index: 10;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  margin-bottom: 28px;
  padding: 16px 18px;
  border: 1px solid var(--border);
  border-radius: 999px;
  background: rgba(255, 251, 247, 0.78);
  backdrop-filter: blur(18px);
  box-shadow: 0 16px 40px rgba(61, 44, 32, 0.08);
}

.brand {
  font-family: "Fraunces", serif;
  font-size: 1.1rem;
  letter-spacing: 0.05em;
  text-transform: uppercase;
}

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

.language-switch {
  display: inline-flex;
  padding: 4px;
  border-radius: 999px;
  background: rgba(53, 82, 74, 0.06);
}

.language-switch button {
  border: 0;
  min-width: 52px;
  padding: 8px 12px;
  border-radius: 999px;
  background: transparent;
  color: var(--muted);
  transition:
    background var(--ease),
    color var(--ease),
    transform var(--ease);
}

.language-switch button[aria-pressed="true"] {
  background: var(--accent);
  color: #fff;
}

.section {
  padding: clamp(44px, 8vw, 92px) 0;
  scroll-margin-top: 112px;
}

.hero {
  display: grid;
  grid-template-columns: 1.1fr 0.9fr;
  gap: clamp(28px, 5vw, 64px);
  align-items: center;
  min-height: calc(100vh - 180px);
}

.eyebrow,
.place-card-overline,
.calendar-eyebrow {
  margin: 0 0 12px;
  color: var(--accent-warm);
  font-size: 0.78rem;
  font-weight: 600;
  letter-spacing: 0.16em;
  text-transform: uppercase;
}

.hero-title,
.section-title {
  margin: 0;
  font-family: "Fraunces", serif;
  font-weight: 600;
  line-height: 0.94;
  letter-spacing: -0.03em;
}

.hero-title {
  max-width: 8ch;
  font-size: clamp(4rem, 10vw, 8rem);
}

.section-title {
  font-size: clamp(2.2rem, 4.8vw, 4.1rem);
}

.section-title.small {
  font-size: clamp(1.8rem, 3.2vw, 2.7rem);
}

.hero-subtitle,
.hero-text,
.section-copy,
.timeline-body p,
.place-card-copy,
.detail-card p,
.image-placeholder p,
.calendar-card p,
.microcopy {
  margin: 0;
  max-width: 62ch;
  color: var(--muted);
}

.hero-subtitle {
  margin-top: 18px;
  font-size: clamp(1.1rem, 2.2vw, 1.45rem);
  color: var(--text);
}

.hero-text {
  margin-top: 22px;
}

.hero-text.muted {
  margin-top: 14px;
}

.hero-actions,
.calendar-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-top: 30px;
}

.hero-facts {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-top: 26px;
}

.fact-pill {
  display: inline-flex;
  align-items: center;
  padding: 10px 14px;
  border: 1px solid rgba(53, 82, 74, 0.14);
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.42);
  font-size: 0.92rem;
  color: var(--text);
}

.hero-visual {
  position: relative;
  min-height: 0;
}

.image-placeholder,
.hero-photo-card,
.photo-card,
.detail-card,
.place-card,
.calendar-card,
.success-panel,
.rsvp-form {
  border: 1px solid var(--border);
  border-radius: var(--radius-xl);
  background: var(--surface);
  backdrop-filter: blur(18px);
  box-shadow: var(--shadow);
}

.image-placeholder {
  position: relative;
  overflow: hidden;
  padding: 28px;
  background:
    linear-gradient(160deg, rgba(255, 251, 247, 0.94), rgba(247, 238, 230, 0.88)),
    linear-gradient(120deg, rgba(53, 82, 74, 0.12), rgba(164, 112, 69, 0.1));
}

.image-placeholder::after {
  content: "";
  position: absolute;
  inset: auto -10% -18% auto;
  width: 180px;
  height: 180px;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(53, 82, 74, 0.16), transparent 66%);
  pointer-events: none;
}

.image-placeholder-hero {
  height: 100%;
  min-height: 560px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
}

.hero-photo-card,
.photo-card {
  overflow: hidden;
  padding: 0;
}

.hero-photo-card {
  position: relative;
  display: grid;
  aspect-ratio: 5 / 4;
  min-height: 0;
}

.hero-photo-card img,
.photo-frame img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.hero-photo-card img {
  min-height: 0;
}

.hero-photo-image {
  object-position: center 28%;
  filter: saturate(0.94) contrast(1.03);
}

.placeholder-badge {
  display: inline-flex;
  width: fit-content;
  padding: 8px 12px;
  border-radius: 999px;
  background: rgba(53, 82, 74, 0.08);
  color: var(--accent);
  font-size: 0.8rem;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.image-placeholder h3,
.photo-caption h3,
.place-card h3,
.detail-card h3,
.calendar-card h5,
.timeline-body h3 {
  margin: 16px 0 10px;
  font-family: "Fraunces", serif;
  font-size: 1.55rem;
  font-weight: 600;
  line-height: 1.1;
}

.section-header {
  display: grid;
  gap: 12px;
  max-width: 700px;
  min-width: 0;
}

.timeline {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 16px;
  margin-top: 34px;
}

.timeline-item {
  display: flex;
  flex-direction: column;
  padding: 22px 22px 26px;
  border: 1px solid var(--border);
  border-radius: var(--radius-xl);
  background: rgba(255, 251, 247, 0.7);
  box-shadow: 0 4px 20px rgba(61, 44, 32, 0.06);
  position: relative;
  overflow: hidden;
}

.timeline-item::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 3px;
  background: linear-gradient(90deg, rgba(164, 112, 69, 0.55), transparent);
}

.timeline-body {
  min-width: 0;
}

.timeline-time {
  display: block;
  font-family: "Fraunces", serif;
  font-size: 2.2rem;
  font-weight: 600;
  color: var(--accent-warm);
  letter-spacing: -0.02em;
  line-height: 1;
  margin-bottom: 14px;
}

.timeline-body h3,
.timeline-body p {
  overflow-wrap: anywhere;
}

.section-split {
  display: grid;
  gap: 24px;
}

.place-grid,
.photo-plan-grid,
.rsvp-layout {
  display: grid;
  gap: 24px;
  margin-top: 32px;
}

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

.place-card,
.detail-card,
.calendar-card,
.success-panel,
.rsvp-form {
  padding: 28px;
}

.place-meta {
  display: grid;
  gap: 16px;
  margin: 26px 0;
}

.place-meta dt {
  color: var(--muted);
  font-size: 0.86rem;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.place-meta dd {
  margin: 6px 0 0;
}

#details {
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

.detail-card {
  min-height: 240px;
}

.contact-link {
  display: inline-flex;
  margin-top: 18px;
  color: var(--accent);
  font-weight: 600;
}

.photo-gallery {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 14px;
  margin-top: 32px;
}

.photo-tile {
  overflow: hidden;
  border-radius: var(--radius-lg);
  aspect-ratio: 4 / 3;
  background: var(--surface);
  border: 1px solid var(--border);
  box-shadow: 0 8px 24px rgba(61, 44, 32, 0.08);
}

.photo-tile-wide {
  grid-column: span 2;
  aspect-ratio: 16 / 9;
}

.photo-tile img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 480ms ease;
  filter: saturate(0.95) contrast(1.02);
}

.photo-tile:hover img {
  transform: scale(1.04);
}

.rsvp-section {
  padding-bottom: 48px;
}

.rsvp-layout {
  grid-template-columns: minmax(0, 1.08fr) minmax(340px, 0.92fr);
  align-items: start;
}

.rsvp-form {
  display: grid;
  gap: 24px;
}

.field,
.fieldset {
  display: grid;
  gap: 10px;
}

.fieldset {
  border: 0;
  margin: 0;
  padding: 0;
}

.field-label {
  font-size: 0.92rem;
  font-weight: 600;
}

.field-hint {
  margin: -4px 0 4px;
  color: var(--muted);
  font-size: 0.88rem;
}

.form-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 18px;
}

.field-full {
  grid-column: 1 / -1;
}

input,
textarea {
  width: 100%;
  padding: 14px 16px;
  border: 1px solid rgba(53, 82, 74, 0.16);
  border-radius: var(--radius-sm);
  background: rgba(255, 255, 255, 0.72);
  color: var(--text);
  transition:
    border-color var(--ease),
    box-shadow var(--ease),
    background var(--ease);
}

input:focus,
textarea:focus {
  outline: none;
  border-color: rgba(53, 82, 74, 0.42);
  box-shadow: 0 0 0 4px rgba(53, 82, 74, 0.1);
  background: rgba(255, 255, 255, 0.92);
}

textarea {
  resize: vertical;
}

.choice-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
}

.choice-pill {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 6px;
  padding: 24px 16px;
  border: 1.5px solid rgba(53, 82, 74, 0.14);
  border-radius: var(--radius-lg);
  background: rgba(255, 255, 255, 0.6);
  cursor: pointer;
  text-align: center;
  font-weight: 500;
  transition:
    border-color var(--ease),
    background var(--ease),
    color var(--ease),
    box-shadow var(--ease),
    transform var(--ease);
}

.choice-pill input[type="radio"] {
  position: absolute;
  opacity: 0;
  pointer-events: none;
  width: 0;
  height: 0;
}

.choice-pill:has(input:checked) {
  border-color: var(--accent);
  background: var(--accent);
  color: #fff;
  transform: translateY(-2px);
  box-shadow: 0 8px 24px rgba(53, 82, 74, 0.22);
}

.choice-pill:hover:not(:has(input:checked)) {
  border-color: rgba(53, 82, 74, 0.28);
  background: rgba(255, 255, 255, 0.88);
  transform: translateY(-1px);
}

.button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 44px;
  width: fit-content;
  padding: 0 18px;
  border: 0;
  border-radius: 999px;
  font-size: 0.95rem;
  transition:
    transform var(--ease),
    background var(--ease),
    color var(--ease),
    box-shadow var(--ease);
}

.button:hover,
.button:focus-visible {
  transform: translateY(-1px);
}

.button:disabled {
  cursor: wait;
  opacity: 0.7;
  transform: none;
}

.button-primary {
  background: var(--accent);
  color: #fff;
  box-shadow: 0 12px 24px rgba(53, 82, 74, 0.2);
}

.button-secondary {
  background: rgba(255, 255, 255, 0.72);
  color: var(--text);
  border: 1px solid rgba(53, 82, 74, 0.12);
}

.button-ghost {
  background: transparent;
  color: var(--accent);
  border: 1px solid rgba(53, 82, 74, 0.16);
}

.button.compact {
  min-height: 38px;
  padding: 0 15px;
  font-size: 0.88rem;
}

.honeypot {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  opacity: 0;
  pointer-events: none;
}

.form-status {
  min-height: 1.5em;
  margin: 0;
  font-size: 0.94rem;
  color: var(--muted);
}

.form-status.error {
  color: #8a392d;
}

.form-status.success {
  color: var(--accent);
}

.success-panel[hidden] {
  display: none;
}

.success-panel {
  position: sticky;
  top: 116px;
  gap: 24px;
  background: var(--surface-strong);
}

.success-copy {
  margin-top: 14px;
}

.calendar-panel {
  display: grid;
  gap: 18px;
  margin-top: 10px;
}

.calendar-header {
  display: grid;
  gap: 8px;
}

.calendar-header h4 {
  margin: 0;
  font-family: "Fraunces", serif;
  font-size: 1.35rem;
  font-weight: 600;
}

.calendar-grid {
  display: grid;
  gap: 16px;
}

.calendar-card h5 {
  font-size: 1.3rem;
}

.site-footer {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 16px;
  padding-top: 24px;
  border-top: 1px solid rgba(53, 82, 74, 0.12);
  color: var(--muted);
}

[data-reveal] {
  opacity: 0;
  transform: translateY(20px);
  transition:
    opacity 560ms ease,
    transform 560ms ease;
}

[data-reveal].is-visible {
  opacity: 1;
  transform: translateY(0);
}

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

  [data-reveal] {
    opacity: 1;
    transform: none;
    transition: none;
  }

  .button,
  .choice-pill,
  .language-switch button,
  input,
  textarea {
    transition: none;
  }
}

@media (max-width: 1080px) {
  .hero,
  .rsvp-layout,
  .photo-plan-grid,
  #details,
  .place-grid {
    grid-template-columns: 1fr;
  }

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

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

  .photo-tile-wide {
    grid-column: span 2;
  }

  .hero-visual {
    min-height: 0;
  }

  .hero-photo-card {
    aspect-ratio: 16 / 11;
  }

  .photo-gallery {
    justify-content: stretch;
  }

  .success-panel {
    position: static;
  }
}

@media (max-width: 780px) {
  .site-shell {
    width: min(100vw - 24px, 1160px);
    padding-top: 18px;
  }

  .topbar {
    flex-direction: column;
    align-items: stretch;
    border-radius: 28px;
  }

  .topbar-actions {
    justify-content: space-between;
  }

  .hero {
    min-height: auto;
    padding-top: 24px;
  }

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

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

  .image-placeholder,
  .place-card,
  .detail-card,
  .calendar-card,
  .success-panel,
  .rsvp-form {
    padding: 22px;
  }

  .photo-caption {
    padding: 18px 20px 20px;
  }

  .hero-title {
    max-width: none;
  }
}
