:root {
  --bg: #f6f0ea;
  --paper: rgba(255, 251, 247, 0.82);
  --paper-strong: #fffaf5;
  --panel: #f1e6da;
  --line: rgba(88, 62, 41, 0.12);
  --text: #33261d;
  --muted: #705749;
  --accent: #b26f4e;
  --accent-deep: #875138;
  --shadow: 0 18px 60px rgba(64, 35, 16, 0.12);
  --max-width: 1180px;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  min-width: 320px;
  color: var(--text);
  font-family: "Manrope", sans-serif;
  background:
    radial-gradient(circle at top left, rgba(210, 168, 138, 0.28), transparent 34%),
    radial-gradient(circle at top right, rgba(194, 154, 114, 0.18), transparent 30%),
    linear-gradient(180deg, #fcf8f3 0%, var(--bg) 52%, #f7efe7 100%);
}

body::before {
  position: fixed;
  inset: 0;
  z-index: -1;
  content: "";
  background-image:
    linear-gradient(rgba(255, 255, 255, 0.22) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255, 255, 255, 0.16) 1px, transparent 1px);
  background-size: 56px 56px;
  mask-image: linear-gradient(180deg, rgba(0, 0, 0, 0.35), transparent 75%);
}

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

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

button,
input,
select,
textarea {
  font: inherit;
}

.page-shell {
  width: min(calc(100% - 2rem), var(--max-width));
  margin: 0 auto;
  padding: 1.1rem 0 2.4rem;
}

.site-header {
  position: sticky;
  top: 0.85rem;
  z-index: 10;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  margin-bottom: 1.4rem;
  padding: 0.85rem 1.05rem;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: rgba(255, 250, 245, 0.85);
  backdrop-filter: blur(12px);
  box-shadow: var(--shadow);
}

.header-controls {
  display: flex;
  align-items: center;
  gap: 0.85rem;
  margin-left: auto;
}

.language-toggle {
  display: inline-flex;
  align-items: center;
  padding: 0.2rem;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: rgba(255, 250, 245, 0.9);
}

.lang-button {
  border: 0;
  background: transparent;
  color: var(--muted);
  padding: 0.42rem 0.7rem;
  border-radius: 999px;
  cursor: pointer;
  font-size: 0.75rem;
  font-weight: 700;
  letter-spacing: 0.08em;
}

.lang-button.is-active {
  background: rgba(178, 111, 78, 0.14);
  color: var(--text);
}

.brand {
  margin-left: 0.4rem;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  font-size: 0.96rem;
  font-weight: 700;
  color: var(--muted);
}

.site-nav {
  display: flex;
  align-items: center;
  gap: 0.35rem;
  flex-wrap: wrap;
  justify-content: flex-end;
}

.site-nav a,
.nav-toggle {
  padding: 0.6rem 0.9rem;
  border-radius: 999px;
  color: var(--muted);
  transition: background-color 180ms ease, color 180ms ease, transform 180ms ease;
}

.site-nav a:hover,
.site-nav a:focus-visible,
.nav-toggle:hover,
.nav-toggle:focus-visible {
  background: rgba(178, 111, 78, 0.12);
  color: var(--text);
  transform: translateY(-1px);
}

.nav-toggle {
  display: none;
  border: 0;
  background: transparent;
  cursor: pointer;
}

.hero-section,
.content-section,
.site-footer {
  border: 1px solid var(--line);
  border-radius: 34px;
  background: var(--paper);
  box-shadow: var(--shadow);
}

.hero-section {
  display: grid;
  grid-template-columns: minmax(0, 0.94fr) minmax(320px, 1.06fr);
  gap: 1.4rem;
  padding: 1.4rem;
  align-items: stretch;
}

.hero-copy,
.content-section {
  position: relative;
  overflow: hidden;
}

.hero-copy {
  display: flex;
  flex-direction: column;
  justify-content: center;
  padding: 1.6rem clamp(0.4rem, 1vw, 1rem) 1.6rem 0.7rem;
}

.hero-copy::after,
.content-section::after {
  position: absolute;
  inset: auto auto -1px -1px;
  width: 140px;
  height: 140px;
  border-top-right-radius: 100%;
  background: linear-gradient(135deg, rgba(178, 111, 78, 0.08), transparent 75%);
  content: "";
  pointer-events: none;
}

.eyebrow,
.card-kicker,
.note-label {
  margin: 0;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  font-size: 0.72rem;
  font-weight: 700;
  color: var(--accent-deep);
}

h1,
h2,
h3 {
  margin: 0;
  font-family: "Cormorant Garamond", serif;
  font-weight: 600;
  line-height: 0.95;
}

h1 {
  margin-top: 0.7rem;
  font-size: clamp(3.1rem, 6.8vw, 5.8rem);
  letter-spacing: -0.04em;
}

h2 {
  font-size: clamp(2.7rem, 4.7vw, 4.3rem);
  letter-spacing: -0.035em;
}

h3 {
  font-size: clamp(2rem, 3vw, 2.55rem);
  letter-spacing: -0.03em;
}

.hero-date,
.hero-intro,
.detail-card p,
.story-copy p,
.rsvp-copy p,
.info-card p,
.contact-list,
.place-list,
.pill-list,
.site-footer p,
.rsvp-form label,
.rsvp-form input,
.rsvp-form select,
.rsvp-form textarea {
  line-height: 1.7;
}

.hero-date {
  margin: 0.8rem 0 0;
  color: var(--muted);
  font-size: 1rem;
}

.hero-intro {
  max-width: 46ch;
  margin: 1rem 0 0;
  font-size: 1.02rem;
}

.countdown-card {
  width: min(100%, 34rem);
  margin-top: 2rem;
  padding: 1rem 1rem 1.15rem;
  border: 1px solid rgba(178, 111, 78, 0.16);
  border-radius: 24px;
  background: rgba(255, 251, 247, 0.92);
}

.countdown-label {
  margin: 0 0 0.85rem;
  color: var(--muted);
}

.countdown-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 0.75rem;
}

.countdown-grid div {
  padding: 0.9rem 0.4rem;
  border-radius: 18px;
  background: var(--panel);
  text-align: center;
}

.countdown-grid span {
  display: block;
  font-family: "Cormorant Garamond", serif;
  font-size: clamp(2rem, 4vw, 2.9rem);
  line-height: 1;
}

.countdown-grid small {
  display: block;
  margin-top: 0.35rem;
  color: var(--muted);
  text-transform: uppercase;
  letter-spacing: 0.12em;
  font-size: 0.7rem;
}

.hero-media img {
  width: 100%;
  height: 100%;
  min-height: 540px;
  border-radius: 26px;
  object-fit: cover;
  object-position: center;
}

.content-section {
  margin-top: 1.4rem;
  padding: 2rem;
}

.section-heading {
  display: grid;
  gap: 0.45rem;
  margin-bottom: 1.6rem;
}

.day-grid,
.info-grid,
.story-layout,
.rsvp-layout {
  display: grid;
  gap: 1.15rem;
}

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

.detail-card,
.info-card,
.deadline-card,
.rsvp-form {
  padding: 1.2rem;
  border: 1px solid var(--line);
  border-radius: 26px;
  background: var(--paper-strong);
}

.detail-card,
.info-card {
  display: grid;
  align-content: start;
  gap: 0.7rem;
}

.pill-list,
.contact-list,
.place-list {
  margin: 0;
  padding: 0;
  list-style: none;
}

.pill-list {
  display: flex;
  flex-wrap: wrap;
  gap: 0.55rem;
}

.pill-list li {
  padding: 0.48rem 0.8rem;
  border-radius: 999px;
  background: var(--panel);
}

.service-note,
.helper-copy,
.footer-small,
.text-link,
.secondary-link,
.form-status {
  color: var(--muted);
}

.card-actions {
  margin-top: auto;
  padding-top: 0.35rem;
}

.text-link {
  display: inline-flex;
  align-items: center;
  gap: 0.45rem;
  font-weight: 700;
}

.text-link.is-disabled {
  opacity: 0.5;
  pointer-events: none;
}

.text-link::after {
  content: "->";
}

.story-layout,
.rsvp-layout {
  grid-template-columns: minmax(0, 0.88fr) minmax(0, 1.12fr);
  align-items: start;
}

.story-copy {
  padding-right: 0.6rem;
}

.story-slideshow {
  position: relative;
  min-height: 460px;
  border-radius: 24px;
  overflow: hidden;
  background: var(--panel);
}

.story-slide {
  position: absolute;
  inset: 0;
  margin: 0;
  opacity: 0;
  transition: opacity 700ms ease;
}

.story-slide.is-active {
  opacity: 1;
}

.story-slide img {
  width: 100%;
  height: 100%;
  min-height: 460px;
  object-fit: cover;
}

.rsvp-copy {
  display: grid;
  gap: 1rem;
}

.deadline-card {
  display: inline-flex;
  flex-direction: column;
  gap: 0.2rem;
  width: fit-content;
}

.deadline-card span {
  color: var(--muted);
  font-size: 0.88rem;
}

.deadline-card strong {
  font-family: "Cormorant Garamond", serif;
  font-size: 2rem;
}

.rsvp-form {
  display: grid;
  gap: 0.85rem;
}

.rsvp-form label {
  display: grid;
  gap: 0.45rem;
  font-size: 0.95rem;
}

.rsvp-form input,
.rsvp-form select,
.rsvp-form textarea {
  width: 100%;
  padding: 0.88rem 0.95rem;
  border: 1px solid rgba(88, 62, 41, 0.16);
  border-radius: 16px;
  background: #fffdf9;
  color: var(--text);
}

.rsvp-form textarea {
  resize: vertical;
}

.primary-button,
.ghost-button {
  width: fit-content;
  padding: 0.86rem 1.2rem;
  border-radius: 999px;
  font-weight: 700;
  cursor: pointer;
  transition: transform 180ms ease, background-color 180ms ease, color 180ms ease;
}

.primary-button {
  border: 0;
  background: var(--accent);
  color: #fffaf5;
}

.ghost-button {
  border: 1px solid rgba(88, 62, 41, 0.16);
  background: transparent;
  color: var(--text);
}

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

.primary-button:hover,
.primary-button:focus-visible {
  background: var(--accent-deep);
}

.iban-box {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.8rem;
  padding: 0.9rem 1rem;
  border-radius: 18px;
  background: var(--panel);
}

.iban-box code {
  overflow-wrap: anywhere;
}

.place-list,
.contact-list {
  display: grid;
  gap: 0.8rem;
}

.place-list li,
.contact-list li {
  padding-top: 0.8rem;
  border-top: 1px solid var(--line);
}

.place-list li:first-child,
.contact-list li:first-child {
  padding-top: 0;
  border-top: 0;
}

.place-title {
  display: block;
  margin-bottom: 0.18rem;
  font-weight: 700;
}

.site-footer {
  margin-top: 1.4rem;
  padding: 1.45rem 1.4rem;
  text-align: center;
}

@media (max-width: 960px) {
  .hero-section,
  .story-layout,
  .rsvp-layout,
  .day-grid,
  .info-grid {
    grid-template-columns: 1fr;
  }

  .hero-copy {
    order: 2;
    padding: 0.5rem 0.2rem 0.2rem;
  }

  .hero-media {
    order: 1;
  }

  .hero-media img {
    min-height: 400px;
  }

  .story-slideshow,
  .story-slide img {
    min-height: 360px;
  }
}

@media (max-width: 760px) {
  .page-shell {
    width: min(calc(100% - 1rem), var(--max-width));
    padding-top: 0.75rem;
  }

  .site-header {
    top: 0.5rem;
    flex-wrap: wrap;
    border-radius: 28px;
  }

  .header-controls {
    width: 100%;
    flex-wrap: wrap;
    justify-content: space-between;
  }

  .nav-toggle {
    display: inline-flex;
  }

  .site-nav {
    display: none;
    width: 100%;
    padding-top: 0.2rem;
    justify-content: flex-start;
  }

  .site-nav.is-open {
    display: flex;
  }

  .site-nav a {
    width: 100%;
  }

  .hero-section,
  .content-section,
  .site-footer {
    border-radius: 26px;
  }

  .hero-section {
    padding: 0.8rem;
  }

  .content-section {
    padding: 1.2rem;
  }

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

  .story-slideshow,
  .story-slide img {
    min-height: 460px;
  }

  .iban-box {
    flex-direction: column;
    align-items: stretch;
  }
}
