:root {
  --fondo: #faf7f2;
  --texto: #3d3733;
  --texto-suave: #756c64;
  --linea: #e5ddd3;
  --acento: #a34b54;
  --blanco: #ffffff;
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  background: var(--fondo);
  color: var(--texto);
  font-family: Georgia, "Times New Roman", serif;
  line-height: 1.75;
  -webkit-font-smoothing: antialiased;
}

.pagina {
  width: min(720px, 100% - 2.5rem);
  margin: 0 auto;
  padding: 3.5rem 0 2.5rem;
}

.cabecera {
  padding-bottom: 2rem;
  border-bottom: 1px solid var(--linea);
  text-align: center;
}

.corazon {
  margin: 0 0 0.8rem;
  color: var(--acento);
  font-size: 1.4rem;
  line-height: 1;
}

h1 {
  margin: 0 0 0.5rem;
  font-size: clamp(2.2rem, 7vw, 3.2rem);
  font-weight: normal;
  line-height: 1.15;
  letter-spacing: -0.01em;
}

.nombres {
  margin: 0 0 0.35rem;
  font-size: clamp(1.05rem, 3vw, 1.2rem);
}

.fecha,
.contador {
  margin: 0.2rem 0 0;
  font-family: "Segoe UI", system-ui, sans-serif;
  font-size: 0.85rem;
  color: var(--texto-suave);
}

.contador {
  color: var(--acento);
}

.carta {
  margin: 2.5rem 0 3.5rem;
  padding: clamp(1.5rem, 6vw, 3rem);
  border: 1px solid var(--linea);
  border-radius: 4px;
  background: var(--blanco);
  box-shadow: 0 1px 3px rgba(61, 55, 51, 0.04);
}

.carta p {
  margin: 0 0 1.25em;
  font-size: clamp(1rem, 2.4vw, 1.1rem);
  line-height: 1.9;
}

.carta__texto p {
  white-space: pre-line;
}

.carta__texto p:last-child {
  margin-bottom: 0;
}

.saludo {
  margin-bottom: 1.5em !important;
  font-size: clamp(1.15rem, 3vw, 1.35rem) !important;
}

.despedida {
  margin-top: 2em !important;
  color: var(--texto-suave);
  font-style: italic;
}

.firma {
  margin: 1.5em 0 0 !important;
  font-size: clamp(1.15rem, 3vw, 1.35rem) !important;
  font-style: italic;
  text-align: right;
}

.bloque {
  margin-bottom: 3.5rem;
}

.bloque h2 {
  margin: 0 0 1.4rem;
  padding-bottom: 0.6rem;
  border-bottom: 1px solid var(--linea);
  font-size: clamp(1.35rem, 4vw, 1.6rem);
  font-weight: normal;
}

.momentos {
  margin: 0;
  padding: 0;
  list-style: none;
}

.momento {
  margin-bottom: 1.8rem;
  padding-left: 1rem;
  border-left: 2px solid var(--acento);
}

.momento:last-child {
  margin-bottom: 0;
}

.momento__fecha {
  margin: 0 0 0.2rem;
  font-family: "Segoe UI", system-ui, sans-serif;
  font-size: 0.78rem;
  color: var(--texto-suave);
}

.momento__titulo {
  margin: 0 0 0.3rem;
  font-size: 1.08rem;
  font-weight: bold;
}

.momento__texto {
  margin: 0;
  font-size: 0.96rem;
  color: #5d544d;
}

.fotos {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 1rem;
}

.foto {
  margin: 0;
}

.foto img {
  display: block;
  width: 100%;
  height: auto;
  border: 1px solid var(--linea);
  border-radius: 3px;
}

.foto figcaption {
  margin-top: 0.35rem;
  font-family: "Segoe UI", system-ui, sans-serif;
  font-size: 0.78rem;
  color: var(--texto-suave);
  text-align: center;
}

.cierre {
  margin-bottom: 3rem;
  text-align: center;
}

.cierre p:first-child {
  max-width: 46ch;
  margin: 0 auto 0.8rem;
  font-size: clamp(1.05rem, 2.8vw, 1.18rem);
  font-style: italic;
  line-height: 1.8;
}

.cierre .firma {
  margin-top: 0.8em !important;
  text-align: center;
}

.pie {
  padding-top: 1.2rem;
  border-top: 1px solid var(--linea);
  text-align: center;
}

.pie p {
  margin: 0;
  font-family: "Segoe UI", system-ui, sans-serif;
  font-size: 0.75rem;
  color: var(--texto-suave);
}

@media (max-width: 480px) {
  .pagina {
    padding-top: 2.5rem;
  }

  .carta {
    margin: 2rem 0 3rem;
  }

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