:root {
  --bg: #f6f0e6;
  --ink: #2a221f;
  --muted: #6a5b56;
  --accent-dark: #540202;
  --accent-soft: #f0d9dd;
  --card: #ffffff;
  --card-border: #e6ddd1;
}

.hero-red {
  color: var(--accent-dark);
}

@font-face {
  font-family: "Chopin";
  src: url("font/ChopinScript.otf") format("opentype");
  font-weight: 100;
  font-style: normal;
  font-display: block;
}

@font-face {
  font-family: "Cherolina";
  src: url("font/Cherolina.ttf") format("truetype");
  font-weight: normal;
  font-style: normal;
  font-display: block;
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  font-family: "Nunito", sans-serif;
  color: var(--ink);
  font-weight: 300;
  position: relative;
}

body::before,
body::after {
  content: "";
  position: fixed;
  top: 0;
  bottom: 0;
  width: 260px;
  background-image: url("img/thumbnail.png"), url("img/thumbnail1.png"),
    url("img/thumbnail2.png");
  background-repeat: no-repeat;
  background-size: 190px auto, 180px auto, 200px auto;
  background-position: 20px 120px, 20px 420px, 20px 740px;
  opacity: 0.5;
  pointer-events: none;
  filter: none;
  image-rendering: auto;
  z-index: 0;
  transform: rotate(25deg);
  transform-origin: center;
}

body::before {
  left: -40px;
}

body::after {
  right: -40px;
  transform: rotate(-25deg);
}

body > * {
  position: relative;
  z-index: 1;
}

main {
  padding-bottom: 40px;
}

h1 {
  font-family: "Chopin", "Great Vibes", cursive;
  font-weight: 100;
  letter-spacing: 1px;
  font-size: clamp(6rem, 7%, 6rem);
  line-height: 1.05;
  margin-bottom: 10px;
}
h2,
h3,
h4 {
  font-family: "Playfair Display", serif;
  margin: 0 0 12px;
  color: var(--accent-dark);
}

p {
  margin: 0 0 12px;
  color: var(--muted);
  font-size: clamp(0.95rem, 1.8vw, 1.5rem);
}

.section-inner {
  max-width: 960px;
  margin: 0 auto;
  padding: 0 20px;
}

.hero {
  position: relative;
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  color: #ffffff;
  font-family: "Chopin", "Great Vibes", cursive;
  font-weight: 100;
  letter-spacing: 1px;
  font-size: clamp(3rem, 6vw, 5rem);
  line-height: 1.05;
  margin-bottom: 0;
  background: url("img/couple-posing-together.jpg") center/cover no-repeat;
}

.hero-overlay {
  position: absolute;
  inset: 0;
  background: rgba(0, 0, 0, 0.35);
}

.hero-content {
  position: relative;
  z-index: 1;
  gap: 0;
}

.hero-kicker {
  font-family: "Nunito", sans-serif;
  font-weight: 300;
  text-transform: uppercase;
  letter-spacing: 4px;
  font-size: 0.8rem;
  color: rgba(255, 255, 255, 0.85);
  margin: 0;
}

.hero-title {
  font-family: "Cherolina", "Chopin", "Great Vibes", cursive;
  letter-spacing: 7px;
  font-size: clamp(11rem, 13vw, 11.5rem);
  line-height: 1;
  margin: 0;
  position: relative;
}

.hero-title .letter {
  display: inline-block;
  opacity: 0;
  transform: translateY(12px);
  animation: letterReveal 1.1s ease-out forwards;
}

@keyframes rotate3d {
  0% {
    transform: rotateY(-10deg);
  }
  50% {
    transform: rotateY(10deg);
  }
  100% {
    transform: rotateY(-10deg);
  }
}

.nombres {
  animation: nameFadeIn 2.8s ease forwards;
}

@keyframes nameFadeIn {
  from {
    opacity: 0;
    transform: translateY(10px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@keyframes letterReveal {
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.hero-date,
.hero-subtitle {
  color: var(--card);
  letter-spacing: 1px;
}

.hero-subtitle {
  margin: 0;
  font-family: "Playfair Display", serif;
  font-weight: 400;
  font-size: clamp(1.4rem, 2.8vw, 2rem);
  text-align: center;
}

.hero-subtitle-text {
  margin: 0 auto 24px;
  max-width: 700px;
  font-family: "Nunito", sans-serif;
  font-weight: 300;
  font-size: clamp(0.95rem, 1.8vw, 1.1rem);
  line-height: 1.6;
  color: --ink;
  text-align: center;
}

.hero-date {
  font-family: "Nunito", sans-serif;
  font-weight: 100;
  font-size: 1.6rem;
  color: #ffffff;
  margin-top: 0;
  margin-bottom: 0;
}

.countdown-section {
  background: var(--accent-dark);
  color: #fff;
  text-align: center;
  padding: 4%;
  margin-top: 7%;
}

.countdown-section h2 {
  color: #fff;
}

.countdown-section .section-subtitle {
  color: rgba(255, 255, 255, 0.75);
}

.countdown-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(120px, 1fr));
  gap: 16px;
  margin-top: 30px;
}

.countdown-item {
  border: 1px solid rgba(255, 255, 255, 0.2);
  padding: 18px;

}

.countdown-item span {
  display: block;
  font-size: 2rem;
  font-weight: 600;
  color: #fff;
}

.countdown-item small {
  letter-spacing: 1px;
  text-transform: uppercase;
  color: rgba(255, 255, 255, 0.75);
}

.section {
  padding: 60px 0;
  text-align: center;
}

.section {
  opacity: 0;
  transform: translateY(18px);
  transition: opacity 0.6s ease, transform 0.6s ease;
  will-change: transform, opacity;
}

.section.reveal-in {
  opacity: 1;
  transform: translateY(0);
}

.hero .hero-kicker,
.hero .hero-title,
.hero .hero-date {
  opacity: 1;
  transform: none;
}

.section.gifts {
  background-color: #fff;
  background-image: url("img/fondo-floral.svg"), url("img/fondo-floral.svg");
  background-repeat: no-repeat, no-repeat;
  background-position: left center, right center;
  background-size: 220px auto, 220px auto;
}

.section-subtitle {
  color: var(--muted);
  margin-bottom: 30px;
  text-align: center;
}

.hero-content .section-subtitle {
  text-align: center;
}

.card {
  background: var(--card);
  border: 1px solid var(--card-border);
  border-radius: 16px;
  padding: 24px;
}

.location-card {
  text-align: center;
  display: grid;
  gap: 18px;
}

.location-header {
  display: flex;
  gap: 16px;
  align-items: center;
  flex-direction: column;
}

.location-image {
  width: 120px;
  height: auto;
  margin: 8px 0 6px;
}

.location-icon {
  width: 46px;
  height: 46px;
  border-radius: 50%;
  background: var(--accent-dark);
  color: #fff;
  display: grid;
  place-items: center;
  font-size: 20px;
}

.location-actions {
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
  justify-content: center;
}

.ghost {
  padding: 10px 16px;
  border-radius: 999px;
  border: 1px solid var(--card-border);
  background: var(--accent-dark);
  color: #fff;
  cursor: pointer;
}

.map-embed iframe {
  width: 100%;
  height: 260px;
  border: none;
  border-radius: 12px;
}

.location-note {
  margin: 0;
  color: var(--muted);
}

.section.program {
  background: #fbf6f3;
}

/* Timeline del programa del evento */
.timeline {
  position: relative;
  max-width: 1200px;
  margin: 0 auto;
}

.timeline::after {
  content: '';
  position: absolute;
  width: 4px;
  background-color: #f0f0f0;
  top: 0;
  bottom: 0;
  left: 50%;
  margin-left: -2px;
}

.container {
  padding: 10px 40px;
  position: relative;
  width: 50%;
}

.left {
  left: 0;
}

.right {
  left: 50%;
}

.icon {
  width: 30px;
  height: 30px;
}

@media screen and (max-width: 790px) {
  .hero-subtitle,
  .hero-subtitle + .section-subtitle {
    padding: 0 16px;
  }
  .timeline::after {
    left: 50%;
  }

  .container {
    width: 50%;
    padding: 10px 40px;
    left: 0;
  }

  .right {
    left: 50%;
  }
}

@media screen and (min-width: 791px) {
  .timeline {
    display: grid;
    grid-template-columns: repeat(6, 1fr);
    gap: 24px;
  }

  .timeline::after {
    display: none;
  }

  .container {
    width: auto;
    left: 0;
    padding: 10px 16px;
    text-align: center;
  }

  .container.left,
  .container.right {
    left: 0;
  }
}

.program-time-pill {
  display: inline-block;
  padding: 6px 14px;
  border-radius: 999px;
  color: var(--accent-dark);
  font-size: 0.85rem;
  font-weight: 600;
  margin-bottom: 12px;
}

.program-icon {
  width: 80px;
  height: 80px;
  display: grid;
  place-items: center;
  margin: 0 auto 14px;
  transition: transform 0.25s ease, filter 0.25s ease;
}

.program-icon img {
  width: 56px;
  height: 56px;
  object-fit: contain;
  display: block;
}

.timeline h4 {
  font-size: 1rem;
  margin-bottom: 6px;
}

.timeline p {
  font-size: 0.85rem;
  color: var(--muted);
}

.card-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 20px;
}

.gift-card {
  background: #fff;
  border: 1px solid var(--card-border);
  border-radius: 20px;
  padding: 26px 24px;
  text-align: center;
  display: grid;
  gap: 14px;
  box-shadow: 0 14px 28px rgba(58, 0, 8, 0.08);
}

.gift-icon {
  width: 90px;
  height: 90px;
  object-fit: contain;
  margin: 0 auto;
  display: block;
}

.gift-title {
  font-weight: 600;
  color: var(--accent-dark);
  margin-bottom: 6px;
}

.gift-button {
  align-self: center;
  justify-self: center;
  padding: 12px 24px;
  border-radius: 999px;
  border: none;
  background: var(--accent-dark);
  color: #fff;
  cursor: pointer;
  font-weight: 600;
}

.gift-button:hover {
  background: #5f0f1b;
}

.info details {
  text-align: left;
  border: 1px solid var(--card-border);
  border-radius: 12px;
  padding: 12px 16px;
  margin-bottom: 12px;
}

.info summary {
  cursor: pointer;
  font-weight: 600;
}

.whatsapp-button {
  display: inline-flex;
  justify-content: center;
  align-items: center;
  padding: 12px 24px;
  border-radius: 999px;
  background: var(--accent-dark);
  color: #fff;
  text-decoration: none;
  font-weight: 600;
}

.whatsapp-button:hover {
  background: #5f0f1b;
}

input,
select,
textarea {
  padding: 12px 14px;
  border: 1px solid #dcd3c7;
  border-radius: 10px;
  font-family: inherit;
}

button {
  padding: 12px 18px;
  background: var(--accent-dark);
  color: #fff;
  border: none;
  border-radius: 999px;
  cursor: pointer;
  font-weight: 600;
}

button:hover {
  background: #4a121a;
}

footer {
  background: #4a121a;
  color: #fff;
  padding: 26px 0;
  text-align: center;
}

.footer-inner p {
  color: rgba(255, 255, 255, 0.8);
  margin: 0;
  font-size: 12px;
}

@media (max-width: 720px) {
  .hero {
    min-height: 100svh;
  }

  body::before,
  body::after {
    width: 100%;
    background-image: url("img/thumbnail1.png");
    background-repeat: no-repeat;
    background-size: 160px auto;
    background-position: center 55%;
    opacity: 0.4;
    transform: none;
    filter: sepia(1) saturate(6) hue-rotate(-10deg) brightness(0.9);
  }

  body::before {
    left: 0;
  }

  body::after {
    right: 0;
    background-image: none;
  }

  .location-card {
    text-align: center;
  }

  .location-header {
    flex-direction: column;
  }

  .location-actions {
    justify-content: center;
  }

  .timeline {
    padding: 0 24px;
  }

  .container {
    opacity: 0;
    transform: translateY(30px) scale(0.96);
    transition: opacity 0.7s ease, transform 0.7s ease;
    filter: blur(2px);
    will-change: transform, opacity;
  }

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

  .countdown-grid {
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 12px;
    margin-top: 20px;
  }

  .countdown-item {
    padding: 12px;
  }

  .countdown-item span {
    font-size: 1rem;
  }

  .countdown-item small {
    font-size: 0.5rem;
  }
}