.portada {
  padding-top: clamp(32px, 6vw, 72px);
}

.portada__grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1.05fr);
  align-items: center;
  gap: clamp(2rem, 5vw, 4rem);
}

.portada__title {
  position: relative;
  z-index: 0;
}

/* The flame sits behind the title, right of "SOM" and over the "RA" of "KABRA!". */
.portada__marca {
  position: absolute;
  z-index: -1;
  left: 1.42em;
  top: -0.66em;
  width: auto;
  height: 1.56em;
  opacity: 0.13;
  pointer-events: none;
}

.portada__title mark {
  color: inherit;
  background: linear-gradient(transparent 58%, var(--lila-clar) 58%, var(--lila-clar) 90%, transparent 90%);
  padding: 0 0.04em;
}

.portada__lead {
  margin-top: clamp(1.25rem, 3vw, 2rem);
  font-family: var(--font-label);
  font-size: clamp(1rem, 1.5vw, 1.15rem);
}

.portada__collage {
  position: relative;
  aspect-ratio: 1 / 0.92;
}

.portada__foto {
  position: absolute;
  margin: 0;
}

.portada__foto--correfoc {
  top: 8%;
  left: 0;
  width: 62%;
  aspect-ratio: 4 / 3;
}

.portada__foto--kabrona {
  top: 0;
  right: 0;
  width: 42%;
  aspect-ratio: 4 / 3;
  z-index: 1;
}

.portada__foto--tabals {
  right: 10%;
  bottom: 0;
  width: 42%;
  aspect-ratio: 4 / 5;
  z-index: 2;
}

/* On devices with a real pointer, hovering a photo brings back its colour. */
@media (hover: hover) and (pointer: fine) {
  .portada__foto img {
    transition: filter 500ms var(--ease-out);
  }

  .portada__foto:hover {
    z-index: 3;
  }

  .portada__foto:hover img {
    filter: none;
  }
}

/* The one authored moment: photos settle onto the paper on load. */
@media (prefers-reduced-motion: no-preference) {
  .portada__foto {
    animation: portada-settle 900ms var(--ease-out) both;
  }

  .portada__foto--kabrona {
    animation-delay: 110ms;
  }

  .portada__foto--tabals {
    animation-delay: 220ms;
  }
}

@keyframes portada-settle {
  from {
    transform: translateY(-18px) rotate(calc(var(--rot) * 2.2));
    box-shadow: 0 30px 50px rgba(17, 17, 17, 0.28);
  }
}

@media (max-width: 879px) {
  .portada__grid {
    grid-template-columns: 1fr;
  }

  .portada__collage {
    width: min(100%, 520px);
    margin: 0 auto;
  }
}
