:root {
  --color-bg: #fffaf5;
  --color-primary: #b88746;
  --color-secondary: #6f7f5f;
  --color-text: #2f2a25;
  --color-muted: #756f68;
  --color-white: #ffffff;
  --color-rose: #d8a7a0;
  --color-line: rgba(184, 135, 70, 0.2);
  --shadow-soft: 0 20px 70px rgba(47, 42, 37, 0.12);
  --radius: 8px;
  --font-title: "Playfair Display", Georgia, serif;
  --font-body: "Inter", Arial, sans-serif;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  color: var(--color-text);
  background: var(--color-bg);
  font-family: var(--font-body);
  line-height: 1.65;
}

body.nav-open {
  overflow: hidden;
}

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

a {
  color: inherit;
}

button,
input,
textarea {
  font: inherit;
}

.container {
  width: min(1120px, calc(100% - 32px));
  margin-inline: auto;
}

.site-header {
  position: fixed;
  z-index: 20;
  top: 0;
  left: 0;
  right: 0;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 16px;
  color: var(--color-white);
  transition: background 0.25s ease, box-shadow 0.25s ease, color 0.25s ease;
}

.site-header.is-scrolled,
.site-header.menu-open {
  color: var(--color-white);
  background: rgb(155, 154, 140);
  box-shadow: 0 12px 40px rgba(47, 42, 37, 0.08);
  backdrop-filter: blur(16px);
}

.brand {
  z-index: 22;
  color: inherit;
  font-family: var(--font-title);
  font-size: 1.35rem;
  font-weight: 700;
  text-decoration: none;
}
.brand img {
  display: block;
  height: 50px;
  width: auto;
}

.site-nav {
  position: fixed;
  inset: 0;
  display: none;
  align-content: center;
  gap: 24px;
  padding: 72px 24px;
  background: rgba(255, 250, 245, 0.98);
  color: var(--color-text);
  opacity: 0;
  visibility: hidden;
  transform: translateY(-10px);
  transition: opacity 0.25s ease, visibility 0.25s ease, transform 0.25s ease;
}

.site-header.menu-open .site-nav {
  opacity: 1;
  visibility: visible;
  transform: translateY(0);
}

.site-nav a {
  color: inherit;
  font-size: 1.35rem;
  font-weight: 600;
  text-align: center;
  text-decoration: none;
}

.nav-toggle {
  z-index: 22;
  display: none;
  place-items: center;
  width: 44px;
  height: 44px;
  border: 1px solid rgba(255, 255, 255, 0.48);
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.12);
  color: inherit;
  cursor: pointer;
}

.site-header.is-scrolled .nav-toggle,
.site-header.menu-open .nav-toggle {
  border-color: rgba(184, 135, 70, 0.28);
  background: rgba(255, 255, 255, 0.64);
}

.nav-toggle span {
  width: 18px;
  height: 2px;
  border-radius: 2px;
  background: currentColor;
  transition: transform 0.2s ease;
}

.nav-toggle span + span {
  margin-top: -12px;
}

.site-header.menu-open .nav-toggle span:first-child {
  transform: translateY(5px) rotate(45deg);
}

.site-header.menu-open .nav-toggle span:last-child {
  transform: translateY(-5px) rotate(-45deg);
}

.hero {
  position: relative;
  display: grid;
  min-height: 100svh;
  place-items: center;
  overflow: hidden;
  padding: 104px 16px 72px;
  color: var(--color-white);
  text-align: center;
  background:
    linear-gradient(180deg, rgba(23, 20, 18, 0.42), rgba(23, 20, 18, 0.64)),
    url("../img/pareja.jpg") center / cover no-repeat;
}

.hero::after {
  position: absolute;
  right: 0;
  bottom: 0;
  left: 0;
  height: 32%;
  content: "";
  background: linear-gradient(180deg, rgba(255, 250, 245, 0), var(--color-bg));
  pointer-events: none;
}

.hero-content {
  position: relative;
  z-index: 1;
  width: min(860px, 100%);
}

.eyebrow {
  margin: 0 0 12px;
  color: var(--color-primary);
  font-size: 0.78rem;
  font-weight: 700;
  letter-spacing: 0.18em;
  text-transform: uppercase;
}

.hero .eyebrow,
.hero-date {
  color: #f8e4c9;
}

h1,
h2,
h3 {
  margin: 0;
  font-family: var(--font-title);
  font-weight: 700;
  line-height: 1.06;
}

h1 {
  font-size: 3.25rem;
}

h2 {
  color: var(--color-text);
  font-size: 2.2rem;
}

h3 {
  font-size: 1.45rem;
}

.hero-date {
  margin: 16px 0 0;
  font-size: 1rem;
  font-weight: 700;
}

.hero-copy {
  width: min(650px, 100%);
  margin: 18px auto 0;
  color: rgba(255, 255, 255, 0.9);
  font-size: 1.05rem;
}

.countdown {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
  width: min(560px, 100%);
  margin: 32px auto 0;
}

.countdown div,
.countdown-complete {
  min-height: 92px;
  padding: 16px 12px;
  border: 1px solid rgba(255, 255, 255, 0.24);
  border-radius: var(--radius);
  background: rgba(255, 255, 255, 0.12);
  backdrop-filter: blur(12px);
}

.countdown-complete {
  display: grid;
  grid-column: 1 / -1;
  place-items: center;
  margin: 0;
}

.countdown strong {
  display: block;
  font-family: var(--font-title);
  font-size: 2rem;
  line-height: 1;
}

.countdown span {
  display: block;
  margin-top: 8px;
  color: rgba(255, 255, 255, 0.84);
  font-size: 0.78rem;
  font-weight: 700;
  text-transform: uppercase;
}

.hero-actions,
.gift-actions {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 12px;
  margin-top: 30px;
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 48px;
  padding: 0 22px;
  border: 1px solid transparent;
  border-radius: 999px;
  cursor: pointer;
  font-weight: 700;
  text-decoration: none;
  transition: transform 0.2s ease, box-shadow 0.2s ease, background 0.2s ease, border-color 0.2s ease;
}

.btn:hover {
  transform: translateY(-2px);
}

.btn-primary {
  color: var(--color-white);
  background: var(--color-primary);
  box-shadow: 0 14px 32px rgba(184, 135, 70, 0.26);
}

.btn-primary:hover {
  background: #a9783d;
}

.btn-secondary {
  color: var(--color-white);
  border-color: rgba(255, 255, 255, 0.38);
  background: rgba(255, 255, 255, 0.12);
}

.section .btn-secondary,
.gifts-section .btn-secondary {
  color: var(--color-text);
  border-color: rgba(184, 135, 70, 0.28);
  background: rgba(255, 255, 255, 0.72);
}

.section {
  padding: 76px 0;
}

.section-soft {
  background: linear-gradient(180deg, rgba(111, 127, 95, 0.08), rgba(216, 167, 160, 0.08));
}

.intro-band {
  padding: 34px 0;
  background: var(--color-white);
}

.intro-grid {
  display: grid;
  gap: 14px;
}

.intro-grid article,
.panel {
  border: 1px solid rgba(184, 135, 70, 0.18);
  border-radius: var(--radius);
  background: rgba(255, 255, 255, 0.78);
  box-shadow: var(--shadow-soft);
}

.intro-grid article {
  padding: 22px;
}

.detail-label {
  display: block;
  margin-bottom: 8px;
  color: var(--color-primary);
  font-size: 0.75rem;
  font-weight: 800;
  text-transform: uppercase;
}

.intro-grid strong {
  display: block;
  font-family: var(--font-title);
  font-size: 1.35rem;
}

.intro-grid p {
  margin: 6px 0 0;
  color: var(--color-muted);
}

.section-heading {
  width: min(720px, 100%);
  margin: 0 auto 52px;
  text-align: center;
}

.section-heading p:not(.eyebrow) {
  line-height: 1.85;
}

.section-heading p:not(.eyebrow),
.location-copy p,
.gifts-layout p {
  color: var(--color-muted);
}

.story-timeline {
  display: grid;
  gap: 44px;
}

.story-item {
  display: grid;
  gap: 26px;
  align-items: center;
}

.story-item img {
  width: 100%;
  height: clamp(380px, 64vw, 660px);
  aspect-ratio: 4 / 5;
  border-radius: var(--radius);
  object-fit: cover;
  object-position: center;
  box-shadow: var(--shadow-soft);
}

.story-item:nth-child(1) img {
  object-position: 48% 30%;
}

.story-item:nth-child(2) img {
  object-position: 54% 24%;
}

.story-item:nth-child(3) img {
  object-position: 50% 36%;
}

.story-item:nth-child(4) img {
  object-position: 50% 22%;
}

.story-item div {
  padding: 0 8px 6px;
}

.story-item span {
  color: var(--color-secondary);
  font-size: 0.82rem;
  font-weight: 800;
}

.story-item p {
  margin: 14px 0 0;
  color: var(--color-muted);
  line-height: 1.85;
}

.schedule {
  position: relative;
  display: grid;
  gap: 14px;
  width: min(760px, 100%);
  margin: 0 auto;
}

.schedule-item {
  display: grid;
  grid-template-columns: 88px 1fr;
  align-items: center;
  gap: 16px;
  min-height: 74px;
  padding: 18px;
  border: 1px solid var(--color-line);
  border-radius: var(--radius);
  background: var(--color-white);
  box-shadow: 0 12px 36px rgba(47, 42, 37, 0.08);
}

.schedule-item time {
  color: var(--color-primary);
  font-weight: 800;
}

.schedule-item span {
  font-family: var(--font-title);
  font-size: 1.35rem;
  font-weight: 700;
}

.schedule-item p {
  margin: 4px 0 0;
  color: var(--color-muted);
  font-size: 0.95rem;
}

.location-grid,
.gifts-layout,
.gallery-layout {
  display: grid;
  gap: 24px;
}

.gallery-layout-single {
  grid-template-columns: minmax(0, 680px);
  justify-content: center;
  max-width: 760px;
  margin: 0 auto;
}

.location-copy,
.gifts-layout > div:first-child {
  align-self: center;
}

.address {
  font-weight: 700;
}

.map-frame {
  min-height: 360px;
  overflow: hidden;
  border: 1px solid rgba(184, 135, 70, 0.18);
  border-radius: var(--radius);
  box-shadow: var(--shadow-soft);
}

.map-frame iframe {
  width: 100%;
  height: 100%;
  min-height: 360px;
  border: 0;
}

.form-card,
.gift-card {
  padding: 22px;
}

label,
fieldset {
  display: grid;
  gap: 8px;
  margin: 0 0 16px;
  color: var(--color-text);
  font-size: 0.94rem;
  font-weight: 700;
}

fieldset {
  padding: 0;
  border: 0;
}

legend {
  margin-bottom: 8px;
  font-weight: 700;
}

input,
textarea {
  width: 100%;
  border: 1px solid rgba(117, 111, 104, 0.24);
  border-radius: var(--radius);
  background: var(--color-white);
  color: var(--color-text);
  padding: 13px 14px;
  outline: none;
  transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

input:focus,
textarea:focus {
  border-color: rgba(184, 135, 70, 0.8);
  box-shadow: 0 0 0 4px rgba(184, 135, 70, 0.12);
}

textarea {
  resize: vertical;
}

.radio-row {
  display: flex;
  align-items: center;
  gap: 10px;
  margin: 0 0 8px;
  font-weight: 600;
}

.radio-row input {
  width: 18px;
  height: 18px;
  accent-color: var(--color-primary);
}

.form-note {
  min-height: 24px;
  margin: 14px 0 0;
  color: var(--color-secondary);
  font-size: 0.92rem;
  font-weight: 700;
}

.gallery-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 18px;
  margin-top: 28px;
}

.memory-card {
  overflow: hidden;
  border: 1px solid rgba(184, 135, 70, 0.16);
  border-radius: var(--radius);
  background: var(--color-white);
  box-shadow: 0 14px 40px rgba(47, 42, 37, 0.08);
}

.memory-card img,
.memory-card video {
  width: 100%;
  aspect-ratio: 1 / 1;
  object-fit: cover;
  background: #eee7dc;
}

.memory-card figcaption {
  padding: 14px;
}

.memory-card strong {
  display: block;
}

.memory-card p {
  margin: 6px 0 0;
  color: var(--color-muted);
  font-size: 0.92rem;
}

.empty-state {
  grid-column: 1 / -1;
  margin: 0;
  padding: 24px;
  border: 1px dashed rgba(184, 135, 70, 0.34);
  border-radius: var(--radius);
  color: var(--color-muted);
  text-align: center;
}

.gift-card dl {
  margin: 0;
}

.gift-block {
  padding-bottom: 18px;
  border-bottom: 1px solid rgba(184, 135, 70, 0.15);
}

.gift-block h3,
.yape-card h3 {
  margin: 0 0 8px;
}

.gift-block p,
.yape-card p {
  margin: 0;
  color: var(--color-muted);
}

.gift-note {
  margin-top: 4px !important;
  font-size: 0.92rem;
}

.gift-card dl > div {
  display: grid;
  gap: 4px;
  padding: 14px 0;
  border-bottom: 1px solid rgba(184, 135, 70, 0.15);
}

.gift-card dl > div:last-child {
  border-bottom: 0;
}

.gift-card dt {
  color: var(--color-muted);
  font-size: 0.78rem;
  font-weight: 800;
  text-transform: uppercase;
}

.gift-card dd {
  margin: 0;
  font-weight: 700;
  overflow-wrap: anywhere;
}

.yape-card {
  display: grid;
  gap: 18px;
  align-items: center;
  margin-top: 18px;
  padding: 18px;
  border: 1px solid rgba(184, 135, 70, 0.18);
  border-radius: var(--radius);
  background: rgba(255, 250, 245, 0.72);
}

.yape-card img {
  width: min(190px, 100%);
  justify-self: center;
  border-radius: var(--radius);
  box-shadow: 0 12px 28px rgba(47, 42, 37, 0.1);
}

.site-footer {
  padding: 28px 16px;
  color: var(--color-muted);
  text-align: center;
  background: var(--color-white);
}

.toast {
  position: fixed;
  z-index: 40;
  right: 16px;
  bottom: 18px;
  width: min(420px, calc(100% - 32px));
  padding: 16px 18px;
  border-left: 4px solid var(--color-secondary);
  border-radius: var(--radius);
  background: var(--color-white);
  box-shadow: var(--shadow-soft);
}

.toast-error {
  border-left-color: #b75b5b;
}

.upload-shortcut {
  position: fixed;
  z-index: 30;
  right: 18px;
  bottom: 18px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 48px;
  padding: 0 18px;
  border: 0;
  border-radius: 999px;
  color: var(--color-white);
  background: var(--color-secondary);
  box-shadow: 0 16px 38px rgba(47, 42, 37, 0.22);
  font-size: 0.9rem;
  font-weight: 800;
  text-decoration: none;
  cursor: pointer;
}

.upload-shortcut:hover {
  transform: translateY(-2px);
}

.reveal {
  opacity: 0;
  transform: translateY(20px);
  transition: opacity 0.6s ease, transform 0.6s ease;
}

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

@media (min-width: 700px) {
  .site-header {
    padding: 20px 34px;
  }

  .nav-toggle {
    display: none;
  }

  .site-nav {
    position: static;
    display: flex;
    align-items: center;
    gap: 24px;
    padding: 0;
    background: transparent;
    color: inherit;
    opacity: 1;
    visibility: visible;
    transform: none;
  }

  .site-nav a {
    font-size: 0.88rem;
    font-weight: 700;
  }

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

  h1 {
    font-size: 4.65rem;
  }

  h2 {
    font-size: 2.85rem;
  }

  .intro-grid {
    grid-template-columns: repeat(3, 1fr);
  }

  .story-item {
    grid-template-columns: 1fr 1fr;
    gap: 56px;
  }

  .story-item div {
    padding: 0 12px;
  }

  .story-item-reverse img {
    order: 2;
  }

  .location-grid,
  .gifts-layout,
  .gallery-layout {
    grid-template-columns: 1fr 1fr;
    gap: 36px;
  }

  .gallery-layout.gallery-layout-single {
    grid-template-columns: minmax(0, 680px);
    justify-content: center;
  }

  .form-card,
  .gift-card {
    padding: 30px;
  }

  .yape-card {
    grid-template-columns: 1fr auto;
  }
}

@media (max-width: 979px) {
  .nav-toggle,
  .site-nav {
    display: none !important;
  }
}

@media (min-width: 980px) {
  .section {
    padding: 100px 0;
  }

  .story-timeline {
    gap: 36px;
  }

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

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    scroll-behavior: auto !important;
    transition-duration: 0.01ms !important;
    animation-duration: 0.01ms !important;
  }
}
