/* =========================================================================
   Álbum digital privado — Albert & Jenny
   CSS3 puro. Paleta cálida, tipografía editorial, animaciones discretas.
   ========================================================================= */

:root {
  --background: #fcf8f3;
  --surface: #f7f1ec;
  --foreground: #474240;
  --warm-white: #faf8f5;
  --gold: #b79b74;
  --blush: #ddbfc2;
  --muted: #8a827d;
  --border: #e7ded6;

  --font-display: "Cormorant Garamond", Georgia, serif;
  --font-sans: "Lato", system-ui, -apple-system, sans-serif;
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
  -webkit-font-smoothing: antialiased;
}

body {
  margin: 0;
  background-color: var(--background);
  color: var(--foreground);
  font-family: var(--font-sans);
  font-weight: 300;
  line-height: 1.8;
  font-size: 15px;
}

img {
  display: block;
  max-width: 100%;
  background-color: var(--surface);
}

figure {
  margin: 0;
}

h1,
h2 {
  font-family: var(--font-display);
  font-weight: 300;
  line-height: 1.12;
  margin: 0;
}

p {
  margin: 0;
}

.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0 0 0 0);
  white-space: nowrap;
  border: 0;
}

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

/* ---------- Layout base ---------- */
.section {
  padding: 6rem 1.5rem;
}

.section--surface {
  background-color: var(--surface);
}

.wrap {
  margin: 0 auto;
  max-width: 72rem;
}

.wrap--narrow {
  max-width: 36rem;
}

.center {
  text-align: center;
}

.narrow {
  max-width: 32rem;
}

.eyebrow {
  display: block;
  font-family: var(--font-sans);
  font-size: 0.6875rem;
  font-weight: 400;
  letter-spacing: 0.32em;
  text-transform: uppercase;
  color: var(--gold);
}

.h2 {
  margin-top: 1.5rem;
  font-size: clamp(1.875rem, 5vw, 3rem);
}

.h2--xl {
  font-size: clamp(2rem, 5vw, 3.25rem);
}

.hairline {
  display: block;
  width: 3rem;
  height: 1px;
  margin-top: 2rem;
  background-color: var(--gold);
  opacity: 0.6;
}

/* ---------- Hero ---------- */
.hero {
  position: relative;
  min-height: 92svh;
  width: 100%;
  overflow: hidden;
  background-color: var(--surface);
}

.hero__img {
  position: absolute;
  inset: 0;
  height: 100%;
  width: 100%;
  object-fit: cover;
  object-position: 40% center;
}

.hero__scrim {
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  height: 75%;
  background: linear-gradient(
    to top,
    rgba(0, 0, 0, 0.7),
    rgba(0, 0, 0, 0.25) 45%,
    rgba(0, 0, 0, 0)
  );
}

.hero__fade {
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  height: 6rem;
  background: linear-gradient(to top, var(--background), rgba(252, 248, 243, 0));
}

.hero__inner {
  position: relative;
  display: flex;
  min-height: 92svh;
  flex-direction: column;
  justify-content: flex-end;
  padding: 0 1.5rem 6rem;
}

.hero__text {
  max-width: 36rem;
  color: var(--warm-white);
}

.hero__title {
  font-size: clamp(2.75rem, 9vw, 5.5rem);
  line-height: 1.05;
  letter-spacing: -0.01em;
}

.hero__date {
  margin-top: 1.25rem;
  font-size: 0.7rem;
  letter-spacing: 0.32em;
  text-transform: uppercase;
  opacity: 0.95;
}

.hero__sub {
  margin-top: 1.5rem;
  max-width: 24rem;
  font-size: 0.95rem;
  line-height: 1.7;
  opacity: 0.9;
}

/* ---------- Gracias ---------- */
.thanks__grid {
  display: grid;
  gap: 3.5rem;
}

.thanks__text {
  max-width: 28rem;
}

.thanks__text p {
  margin-top: 1.5rem;
  line-height: 1.9;
}

.thanks__figure img {
  width: 100%;
  aspect-ratio: 3 / 4;
  object-fit: cover;
}

/* ---------- Votos ---------- */
.vows__block {
  display: grid;
  gap: 2.5rem;
  margin-top: 4rem;
}

.vows__photo img {
  width: 100%;
  aspect-ratio: 4 / 5;
  object-fit: cover;
}

.vows__name {
  font-family: var(--font-display);
  font-size: 1.875rem;
}

.vows__copy p:last-child {
  margin-top: 1.5rem;
  max-width: 28rem;
  line-height: 1.95;
}

/* ---------- Galería (mosaico editorial) ---------- */
.gallery {
  display: grid;
  grid-template-columns: 1fr;
  gap: 1.5rem;
  margin-top: 3.5rem;
}

.gallery img {
    width: 100%;
    height: auto;
    object-fit: contain;
}

.g1 img {
    object-position: center top;
}
.g3 img,
.g4 img {
  aspect-ratio: 3 / 4;
}

.g2 img,
.g5 img {
  aspect-ratio: 3 / 2;
}

.g6 img {
  aspect-ratio: 4 / 3;
}

/* ---------- Descarga privada ---------- */
.gate__desc {
  margin: 1.25rem auto 0;
  max-width: 24rem;
  font-size: 0.9rem;
  line-height: 1.7;
}

.gate__form {
  margin: 2.5rem auto 0;
  max-width: 24rem;
}

.gate__form input {
  width: 100%;
  border: 0;
  border-bottom: 1px solid #ddd2c7;
  background: transparent;
  padding: 0.75rem 0.25rem;
  text-align: center;
  font-family: var(--font-sans);
  font-size: 0.875rem;
  font-weight: 300;
  letter-spacing: 0.18em;
  color: var(--foreground);
  outline: none;
  transition: border-color 500ms ease;
}

.gate__form input::placeholder {
  color: var(--muted);
  letter-spacing: 0.18em;
}

.gate__form input:focus {
  border-color: var(--gold);
}

.gate__form button {
  margin-top: 2rem;
  width: 100%;
  border: 0;
  background-color: var(--foreground);
  color: var(--warm-white);
  padding: 0.9rem 2rem;
  font-family: var(--font-sans);
  font-size: 0.7rem;
  font-weight: 600;
  letter-spacing: 0.28em;
  text-transform: uppercase;
  cursor: pointer;
  transition: opacity 500ms ease;
}

.gate__form button:hover {
  opacity: 0.85;
}

.gate__form button:disabled {
  opacity: 0.5;
  cursor: default;
}

.gate__error {
  margin-top: 1.25rem;
  font-size: 0.75rem;
  letter-spacing: 0.02em;
  opacity: 0;
  transition: opacity 500ms ease;
}

.gate__error.is-shown {
  opacity: 1;
}

.downloads {
  list-style: none;
  margin: 3rem 0 0;
  padding: 0;
  display: grid;
  gap: 1.25rem;
}

.downloads a {
  display: flex;
  height: 100%;
  flex-direction: column;
  align-items: center;
  gap: 0.75rem;
  border: 1px solid var(--border);
  background-color: var(--warm-white);
  padding: 2.5rem 1.5rem;
  text-decoration: none;
  color: inherit;
  transition: border-color 500ms ease;
}

.downloads a:hover {
  border-color: var(--gold);
}

.downloads .icon {
  font-size: 1.25rem;
}

.downloads .title {
  font-family: var(--font-display);
  font-size: 1.25rem;
  line-height: 1.35;
}

.downloads .hint {
  font-size: 0.65rem;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--muted);
}

/* ---------- Footer ---------- */
.footer {
  padding: 5rem 1.5rem;
  text-align: center;
}

.footer__msg {
  font-size: 0.7rem;
  letter-spacing: 0.28em;
  text-transform: uppercase;
  color: var(--muted);
}

.footer__couple {
  margin-top: 1.25rem;
  font-family: var(--font-display);
  font-size: 1.5rem;
}

.footer__year {
  margin-top: 1.25rem;
  font-size: 0.65rem;
  letter-spacing: 0.28em;
  color: var(--muted);
}

/* ---------- Animaciones discretas ---------- */
.reveal {
  opacity: 0;
  transition:
    opacity 900ms cubic-bezier(0.22, 0.61, 0.36, 1),
    transform 900ms cubic-bezier(0.22, 0.61, 0.36, 1);
  transform: translateY(28px);
  will-change: opacity, transform;
}

.reveal--left {
  transform: translateX(-28px);
}

.reveal--right {
  transform: translateX(28px);
}

.reveal.is-visible {
  opacity: 1;
  transform: none;
}

/* =========================================================================
   Responsive
   ========================================================================= */
@media (min-width: 640px) {
  body {
    font-size: 16px;
  }

  .section {
    padding: 6rem 2.5rem;
  }

  .hero__img {
    object-position: center;
  }

  .hero__inner {
    padding: 0 2.5rem 6rem;
  }

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

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

@media (min-width: 768px) {
  .section {
    padding: 9rem 2.5rem;
  }

  .thanks__grid {
    grid-template-columns: 1fr auto;
    align-items: center;
    gap: 5rem;
  }

  .thanks__figure {
    width: 26rem;
  }

  .vows__block {
    grid-template-columns: repeat(12, 1fr);
    gap: 3rem;
    margin-top: 7rem;
  }

  .vows__block--a {
    align-items: end;
  }

  .vows__block--a .vows__photo {
    grid-column: 1 / span 5;
  }

  .vows__block--a .vows__copy {
    grid-column: 7 / span 6;
    padding-bottom: 2rem;
  }

  .vows__block--b {
    align-items: start;
    margin-top: 10rem;
  }

  .vows__block--b .vows__copy {
    grid-column: 2 / span 5;
    padding-top: 4rem;
  }

  .vows__block--b .vows__photo {
    grid-column: 8 / span 5;
  }

  .vows__name {
    font-size: 2.25rem;
  }

  /* Mosaico editorial asimétrico */
  .gallery {
    grid-template-columns: repeat(12, 1fr);
    column-gap: 2.5rem;
    row-gap: 0;
    margin-top: 6rem;
  }

  .g1 { grid-column: 1 / span 5; }
  .g2 { grid-column: 6 / span 7; margin-top: 6rem; }
  .g3 { grid-column: 2 / span 4; margin-top: 4rem; }
  .g4 { grid-column: 7 / span 5; margin-top: 1rem; }
  .g5 { grid-column: 1 / span 7; margin-top: 5rem; }
  .g6 { grid-column: 9 / span 4; margin-top: 2.5rem; }
}

@media (min-width: 1024px) {
  .section {
    padding: 12rem 5rem;
  }

  .hero__inner {
    padding: 0 5rem 6rem;
  }

  .thanks__grid {
    gap: 8rem;
  }

  .thanks__figure {
    width: 30rem;
  }
}

@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }

  .reveal {
    opacity: 1;
    transform: none;
    transition: none;
  }
}
/* Corrección temporal descargas */
#downloads {
  list-style: none !important;
  margin: 3rem 0 0 !important;
  padding: 0 !important;
  display: grid !important;
  grid-template-columns: repeat(2, minmax(0, 1fr)) !important;
  gap: 1.25rem !important;
}

#downloads li {
  list-style: none !important;
  margin: 0 !important;
  padding: 0 !important;
}

#downloads a {
  display: flex !important;
  min-height: 250px !important;
  flex-direction: column !important;
  justify-content: center !important;
  align-items: center !important;
  gap: 0.75rem !important;
  border: 1px solid var(--border) !important;
  background-color: var(--warm-white) !important;
  padding: 2.5rem 1.5rem !important;
  text-decoration: none !important;
  color: inherit !important;
}

#downloads .icon {
  font-size: 1.25rem !important;
}

#downloads .title {
  font-family: var(--font-display) !important;
  font-size: 1.25rem !important;
  line-height: 1.35 !important;
}

#downloads .hint {
  font-size: 0.65rem !important;
  letter-spacing: 0.22em !important;
  text-transform: uppercase !important;
  color: var(--muted) !important;
}

@media (max-width: 639px) {
  #downloads {
    grid-template-columns: 1fr !important;
  }
}/* ========= Aviso final ========= */

.memory-note{
    margin-top:60px;
    padding:36px;
    background:#ffffff;
    border:1px solid rgba(0,0,0,.08);
    border-radius:18px;
    box-shadow:0 10px 30px rgba(0,0,0,.05);
    text-align:center;
}

.memory-note h3{
    margin:0 0 22px;
    font-size:1.8rem;
    font-weight:600;
    color:#3f342d;
}

.memory-note p{
    max-width:760px;
    margin:0 auto 18px;
    line-height:1.9;
    color:#6b5d55;
}

.memory-note strong{
    color:#3f342d;
    font-weight:600;
}

@media (max-width:768px){

    .memory-note{
        padding:28px 22px;
        margin-top:45px;
    }

    .memory-note h3{
        font-size:1.45rem;
    }

    .memory-note p{
        line-height:1.75;
    }

}
/* ========= Ayuda descargas ========= */

.download-help{
    max-width:760px;
    margin:25px auto 35px;
    padding:22px 26px;
    background:#fff;
    border:1px solid rgba(0,0,0,.08);
    border-radius:16px;
    text-align:center;
}

.download-help h4{
    margin:0 0 12px;
    color:#3f342d;
    font-size:1.2rem;
}

.download-help p{
    margin:0 0 12px;
    line-height:1.7;
    color:#6b5d55;
}

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

.download-help-note{
    font-size:.95rem;
    color:#8a7d74;
}

@media (max-width:768px){

    .download-help{
        padding:18px;
    }

}
/* Enlace de ayuda ZIP: oculto en ordenador */

.mobile-zip-help{
    display:none;
}

@media (max-width:768px){

    .mobile-zip-help{
        display:inline-flex;
        align-items:center;
        justify-content:center;
        margin-top:14px;
        padding:11px 18px;
        border:1px solid rgba(75,64,57,.16);
        border-radius:999px;
        background:#f7f1ec;
        color:#4b4039;
        text-decoration:none;
        font-size:.95rem;
        font-weight:600;
    }

    .mobile-zip-help:active{
        transform:scale(.98);
    }

}