:root {
  --ink: #2f3130;
  --paper: #fbfaf7;
  --soft: #f0ebe2;
  --sage: #6f806f;
  --rose: #a86f63;
  --gold: #b48b55;
  --line: rgba(47, 49, 48, 0.16);
  --white: #fffdf9;
  --shadow: 0 18px 50px rgba(47, 49, 48, 0.14);
}

* {
  box-sizing: border-box;
}

[hidden] {
  display: none !important;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  color: var(--ink);
  background: var(--paper);
  font-family: "Inter", system-ui, sans-serif;
}

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

.topbar {
  position: fixed;
  z-index: 10;
  top: 0;
  left: 0;
  right: 0;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 18px clamp(18px, 4vw, 56px);
  background: rgba(251, 250, 247, 0.86);
  border-bottom: 1px solid rgba(255, 253, 249, 0.55);
  backdrop-filter: blur(16px);
}

.brand {
  width: 44px;
  height: 44px;
  display: grid;
  place-items: center;
  flex: 0 0 auto;
  border: 1px solid var(--line);
  border-radius: 50%;
  color: var(--sage);
  font-family: "Cormorant Garamond", Georgia, serif;
  font-size: 20px;
  font-weight: 700;
}

.nav-actions {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 8px;
  min-width: 0;
}

.nav-actions a {
  min-height: 40px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0 14px;
  border-radius: 999px;
  color: rgba(47, 49, 48, 0.78);
  font-size: 14px;
  font-weight: 700;
  white-space: nowrap;
}

.music-toggle {
  width: 40px;
  height: 40px;
  display: inline-grid;
  place-items: center;
  flex: 0 0 auto;
  border: 1px solid var(--line);
  border-radius: 50%;
  background: rgba(255, 253, 249, 0.9);
  color: var(--sage);
  cursor: pointer;
  font: 800 18px/1 "Inter", system-ui, sans-serif;
  transition: transform 180ms ease, background 180ms ease, color 180ms ease;
}

.music-toggle:hover {
  transform: translateY(-1px);
  background: rgba(111, 128, 111, 0.12);
}

.music-toggle.is-playing {
  background: var(--sage);
  color: var(--white);
}

.nav-actions a:hover {
  background: rgba(111, 128, 111, 0.12);
  color: var(--ink);
}

.nav-actions .nav-primary {
  color: var(--white);
  background: var(--sage);
}

.label-short {
  display: none;
}

.background-audio {
  position: fixed;
  width: 1px;
  height: 1px;
  overflow: hidden;
  opacity: 0;
  pointer-events: none;
}

.hero {
  min-height: 92svh;
  position: relative;
  display: grid;
  align-items: center;
  padding: 120px clamp(20px, 6vw, 84px) 72px;
  overflow: hidden;
}

.hero-bg,
.hero-overlay {
  position: absolute;
  inset: 0;
}

.hero-bg {
  background: url("./assets/deby-edu-milka-nos-casamos.png") center top / cover no-repeat;
  transform: scale(1.02);
}

.hero-overlay {
  background:
    linear-gradient(90deg, rgba(251, 250, 247, 0.9) 0%, rgba(251, 250, 247, 0.72) 34%, rgba(251, 250, 247, 0.18) 68%, rgba(251, 250, 247, 0.04) 100%),
    linear-gradient(0deg, rgba(47, 49, 48, 0.18), rgba(47, 49, 48, 0.02));
}

.hero-content {
  position: relative;
  width: min(660px, 100%);
}

.eyebrow,
.section-kicker,
.detail-label {
  margin: 0 0 12px;
  color: var(--rose);
  font-size: 13px;
  font-weight: 800;
  letter-spacing: 0;
  text-transform: uppercase;
}

h1,
h2 {
  margin: 0;
  color: var(--ink);
  font-family: "Cormorant Garamond", Georgia, serif;
  font-weight: 700;
  line-height: 0.94;
}

h1 {
  font-size: clamp(64px, 11vw, 136px);
}

h2 {
  font-size: clamp(38px, 6vw, 70px);
}

.hero-date {
  margin: 18px 0 0;
  color: var(--sage);
  font-family: "Cormorant Garamond", Georgia, serif;
  font-size: clamp(27px, 4vw, 44px);
  font-weight: 700;
}

.hero-copy,
.intro-band p,
.split-copy p,
.registry-band p,
.rsvp-copy p {
  color: rgba(47, 49, 48, 0.78);
  font-size: 18px;
  line-height: 1.7;
}

.hero-copy {
  max-width: 510px;
  margin: 20px 0 0;
}

.hero-ctas {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-top: 34px;
}

.button {
  min-height: 50px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 0 22px;
  border: 1px solid transparent;
  border-radius: 999px;
  cursor: pointer;
  font: 800 15px/1 "Inter", system-ui, sans-serif;
  transition: transform 180ms ease, box-shadow 180ms ease, background 180ms ease;
}

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

.button-primary {
  color: var(--white);
  background: var(--sage);
  box-shadow: var(--shadow);
}

.button-secondary,
.button-outline {
  color: var(--ink);
  background: rgba(255, 253, 249, 0.86);
  border-color: var(--line);
}

.button-outline {
  margin-top: 12px;
}

.intro-band {
  padding: 54px clamp(20px, 6vw, 84px);
  background: var(--white);
}

.content-narrow {
  max-width: 840px;
  margin: 0 auto;
  text-align: center;
}

.content-narrow p {
  margin: 0;
  color: var(--ink);
  font-family: "Cormorant Garamond", Georgia, serif;
  font-size: clamp(30px, 4vw, 48px);
  line-height: 1.18;
}

.details {
  position: relative;
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  border-block: 1px solid var(--line);
  background:
    linear-gradient(90deg, rgba(47, 49, 48, 0.76), rgba(47, 49, 48, 0.48)),
    url("./assets/anillo-deby.jpg") center / cover no-repeat;
  color: var(--white);
}

.detail-item {
  position: relative;
  min-height: 220px;
  padding: clamp(28px, 5vw, 58px);
  border-right: 1px solid rgba(255, 253, 249, 0.24);
}

.detail-item:last-child {
  border-right: 0;
}

.detail-item h2 {
  color: var(--white);
  font-size: clamp(34px, 4.5vw, 58px);
}

.detail-item p {
  margin: 14px 0 0;
  color: rgba(255, 253, 249, 0.78);
  font-size: 16px;
}

.detail-item .detail-label {
  color: rgba(255, 253, 249, 0.82);
}

.split-section,
.rsvp-section {
  display: grid;
  grid-template-columns: minmax(0, 0.9fr) minmax(300px, 1.1fr);
  gap: clamp(28px, 6vw, 72px);
  align-items: center;
  padding: clamp(72px, 10vw, 128px) clamp(20px, 6vw, 84px);
}

.split-copy,
.rsvp-intro {
  max-width: 540px;
}

.rsvp-copy {
  max-width: 520px;
}

.muted {
  color: rgba(47, 49, 48, 0.62) !important;
}

.map-panel {
  min-height: 420px;
  position: relative;
  display: grid;
  place-items: center;
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #e8eee7;
  box-shadow: var(--shadow);
}

.map-panel iframe {
  width: 100%;
  height: 100%;
  min-height: inherit;
  border: 0;
}

.registry-band {
  padding: clamp(72px, 10vw, 118px) clamp(20px, 6vw, 84px);
  background:
    linear-gradient(90deg, rgba(251, 250, 247, 0.88), rgba(251, 250, 247, 0.74) 44%, rgba(251, 250, 247, 0.3)),
    url("./assets/san-gabriel.jpg") center / cover no-repeat;
}

.content-grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(240px, 340px);
  gap: clamp(28px, 6vw, 72px);
  align-items: center;
  max-width: 1180px;
  margin: 0 auto;
}

.code-box {
  display: grid;
  gap: 14px;
  justify-items: center;
  justify-self: end;
  width: min(100%, 340px);
  padding: 26px 24px;
  border: 1px solid rgba(255, 253, 249, 0.48);
  border-radius: 8px;
  background: rgba(255, 253, 249, 0.42);
  box-shadow: 0 24px 70px rgba(47, 49, 48, 0.18);
  backdrop-filter: blur(18px) saturate(1.18);
  text-align: center;
}

.code-box span {
  color: rgba(47, 49, 48, 0.72);
  font-size: 13px;
  font-weight: 800;
  text-transform: uppercase;
}

.code-box strong {
  color: var(--ink);
  font-family: "Cormorant Garamond", Georgia, serif;
  justify-self: center;
  margin: -4px 0 14px;
  font-size: clamp(42px, 5vw, 58px);
  line-height: 1;
}

.copy-button {
  min-height: 42px;
  padding: 0 16px;
  border: 1px solid rgba(255, 253, 249, 0.52);
  border-radius: 999px;
  background: rgba(255, 253, 249, 0.58);
  color: var(--ink);
  cursor: pointer;
  font-weight: 800;
  backdrop-filter: blur(12px);
}

.code-actions {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 10px;
  align-items: center;
  width: 100%;
}

.code-actions .button,
.code-actions .copy-button {
  min-height: 42px;
  padding-inline: 16px;
}

@supports not (backdrop-filter: blur(12px)) {
  .code-box {
    background: rgba(255, 253, 249, 0.78);
  }

  .copy-button {
    background: rgba(255, 253, 249, 0.86);
  }
}

.rsvp-section {
  background: var(--paper);
}

.rsvp-intro {
  display: grid;
  gap: 28px;
}

.rsvp-photo {
  position: relative;
  width: min(100%, 410px);
  margin: 0;
  overflow: hidden;
  border: 1px solid rgba(47, 49, 48, 0.14);
  border-radius: 8px;
  box-shadow: var(--shadow);
}

.rsvp-photo::after {
  content: "";
  position: absolute;
  inset: 0;
  border: 1px solid rgba(255, 253, 249, 0.5);
  border-radius: inherit;
  pointer-events: none;
}

.rsvp-photo img {
  display: block;
  width: 100%;
  aspect-ratio: 4 / 5;
  object-fit: cover;
  object-position: 50% 22%;
}

.rsvp-form {
  display: grid;
  gap: 16px;
  padding: clamp(24px, 4vw, 36px);
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--white);
  box-shadow: var(--shadow);
}

label {
  display: grid;
  gap: 8px;
  color: rgba(47, 49, 48, 0.72);
  font-size: 14px;
  font-weight: 800;
}

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

legend {
  margin: 0 0 10px;
  color: rgba(47, 49, 48, 0.72);
  font-size: 14px;
  font-weight: 800;
}

.radio-group {
  display: grid;
  gap: 10px;
}

.radio-option {
  min-height: 46px;
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 10px 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--paper);
}

.radio-option input {
  width: 18px;
  min-height: 18px;
  accent-color: var(--sage);
}

.diet-fieldset {
  display: grid;
  gap: 12px;
  padding: 16px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: rgba(240, 235, 226, 0.42);
}

.diet-note {
  margin: -2px 0 2px;
  color: rgba(47, 49, 48, 0.58);
  font-size: 13px;
  font-weight: 700;
  line-height: 1.5;
}

input,
select,
textarea {
  width: 100%;
  min-height: 48px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--paper);
  color: var(--ink);
  font: 500 16px/1.4 "Inter", system-ui, sans-serif;
  padding: 12px 14px;
}

textarea {
  resize: vertical;
}

.form-note {
  min-height: 22px;
  margin: 0;
  color: var(--sage);
  font-weight: 800;
}

.deadline-note {
  margin: -4px 0 0;
  color: rgba(47, 49, 48, 0.58);
  font-size: 13px;
  font-weight: 800;
  line-height: 1.5;
  text-align: center;
}

.footer {
  padding: 28px;
  text-align: center;
  color: rgba(47, 49, 48, 0.62);
  border-top: 1px solid var(--line);
  background: var(--white);
}

.footer p {
  margin: 0;
}

@media (max-width: 840px) {
  .topbar {
    align-items: flex-start;
    padding: 12px 14px;
  }

  .nav-actions {
    max-width: none;
    overflow: visible;
    padding-bottom: 4px;
  }

  .nav-actions a {
    min-height: 38px;
    padding: 0 8px;
    font-size: 12px;
  }

  .music-toggle {
    width: 38px;
    height: 38px;
  }

  .label-full {
    display: none;
  }

  .label-short {
    display: inline;
  }

  .hero {
    min-height: 88svh;
    padding-top: 112px;
  }

  .hero-overlay {
    background:
      linear-gradient(0deg, rgba(251, 250, 247, 0.88), rgba(251, 250, 247, 0.68)),
      linear-gradient(0deg, rgba(47, 49, 48, 0.12), rgba(47, 49, 48, 0.04));
  }

  .details,
  .split-section,
  .content-grid,
  .rsvp-section {
    grid-template-columns: 1fr;
  }

  .code-box {
    justify-self: end;
  }

  .detail-item {
    min-height: auto;
    border-right: 0;
    border-bottom: 1px solid rgba(255, 253, 249, 0.24);
  }

  .detail-item:last-child {
    border-bottom: 0;
  }

  .map-panel {
    min-height: 320px;
  }
}

@media (max-width: 520px) {
  .brand {
    width: 40px;
    height: 40px;
  }

  h1 {
    font-size: 62px;
  }

  .hero-ctas,
  .button {
    width: 100%;
  }

  .button {
    padding-inline: 16px;
  }

  .content-narrow {
    text-align: left;
  }

  .map-panel p {
    left: 14px;
    right: 14px;
    text-align: center;
  }
}
