/* Slide 1, "Steal the look": the creator's post, the designer's arrow, and your photo
   split before and after. Phone: stacked and centred like the slide. Desktop: copy left,
   the picture right. */
.hero {
  display: grid;
  grid-template-areas: "title" "story" "deck" "stores";
  justify-items: center;
  text-align: center;
  padding-block: 8px 48px;
}
.hero-copy { display: contents; }

.hero-title {
  grid-area: title;
  font-size: clamp(56px, 17vw, 92px);
  line-height: 0.86;
}
.hero-line { display: block; }
.hero-line-2 { white-space: nowrap; }
.hero-title .kick {
  display: inline-block;
  font-size: 0.32em;
  vertical-align: top;
  margin-top: 0.36em;
  margin-right: 0.12em;
  letter-spacing: 0;
}

.deck {
  grid-area: deck;
  max-width: 30em;
  margin-top: 28px;
  color: #3B3630;
  font-size: clamp(17px, 1.3vw, 19px);
  text-wrap: pretty;
}
.deck-name { white-space: nowrap; }
.deck-logo {
  display: inline-block;
  width: 1.05em;
  height: 1.05em;
  margin-right: 0.3em;
  vertical-align: -0.17em;
}
.deck-logo-pinterest { fill: #E60023; }
.hero .stores { grid-area: stores; margin-top: 28px; justify-content: center; }

.story {
  grid-area: story;
  position: relative;
  width: min(100%, 440px);
  aspect-ratio: 100 / 112;
  margin-top: 28px;
  container-type: inline-size;
}

.story-glow {
  position: absolute;
  left: 38%;
  top: 9%;
  width: 22%;
  aspect-ratio: 1;
  border-radius: 50%;
  background: radial-gradient(circle at 40% 40%, var(--orange), var(--pink));
  filter: blur(6cqw);
  opacity: 0.85;
}

.inspo {
  position: absolute;
  z-index: 2;
  left: 1%;
  top: 3%;
  width: 44%;
  aspect-ratio: 504 / 693;
  rotate: -5deg;
  border-radius: 5.4cqw;
  overflow: hidden;
  border: max(3px, 0.7cqw) solid var(--cream);
  box-shadow: 0 2.4cqw 6cqw -2cqw rgba(60, 30, 10, 0.35);
}
.inspo img { width: 100%; height: 100%; object-fit: cover; }
.inspo::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(to bottom, transparent 55%, rgba(0, 0, 0, 0.5));
}
.inspo figcaption {
  position: absolute;
  z-index: 1;
  inset-inline: 0;
  bottom: 6%;
  color: var(--cream);
  font-size: 5cqw;
  text-align: center;
}

.story-arrow {
  position: absolute;
  z-index: 3;
  left: 6%;
  top: 63%;
  width: 21%;
  height: auto;
  fill: var(--ink);
  rotate: -130.6deg;
}

.result-note {
  position: absolute;
  left: 63%;
  top: 13.5%;
  font-size: 5cqw;
  rotate: 5deg;
  white-space: nowrap;
}

.compare {
  --pos: 50%;
  position: absolute;
  z-index: 1;
  left: 31%;
  top: 22%;
  width: 68%;
  aspect-ratio: 1092 / 1349;
  rotate: 5deg;
  border-radius: 5.6cqw;
  overflow: hidden;
  box-shadow: 0 3cqw 8cqw -3cqw rgba(60, 30, 10, 0.4);
  touch-action: pan-y;
  cursor: ew-resize;
  user-select: none;
  -webkit-user-select: none;
}
.compare img { width: 100%; height: 100%; object-fit: cover; pointer-events: none; }
.compare-before { position: absolute; inset: 0; clip-path: inset(0 calc(100% - var(--pos)) 0 0); }
.compare::after {
  content: "";
  position: absolute;
  top: 0;
  bottom: 0;
  left: var(--pos);
  width: max(2px, 0.6cqw);
  translate: -50% 0;
  background: #fff;
}

.compare-label {
  position: absolute;
  z-index: 1;
  bottom: 5%;
  color: #fff;
  font-size: 5.2cqw;
  text-shadow: 0 1px 12px rgba(0, 0, 0, 0.35);
}
.compare-label-before { right: calc(100% - var(--pos) + 4%); }
.compare-label-after { left: calc(var(--pos) + 4%); }

.compare-handle {
  position: absolute;
  z-index: 2;
  top: 52%;
  left: var(--pos);
  translate: -50% -50%;
  display: grid;
  place-items: center;
  width: clamp(34px, 9cqw, 48px);
  aspect-ratio: 1;
  border-radius: 50%;
  background: #fff;
  color: var(--ink);
  box-shadow: 0 4px 14px rgba(0, 0, 0, 0.2);
}
.compare-handle .icon { width: 55%; height: 55%; }
.compare:has(.compare-range:focus-visible) .compare-handle { outline: 3px solid var(--orange-text); outline-offset: 3px; }

.compare-range {
  position: absolute;
  width: 1px;
  height: 1px;
  opacity: 0;
  pointer-events: none;
}

@media (min-width: 960px) {
  .hero {
    grid-template-columns: minmax(0, 1fr) minmax(0, 1.04fr);
    grid-template-areas: "title story" "deck story" "stores story";
    grid-template-rows: 1fr auto 1fr;
    column-gap: clamp(32px, 5vw, 72px);
    justify-items: start;
    text-align: left;
    padding-block: 24px 112px;
  }
  .hero-title { align-self: end; font-size: clamp(72px, 7.4vw, 108px); }
  .hero-line-2 { padding-left: 0.42em; }
  .deck { margin-top: 32px; }
  .hero .stores { align-self: start; justify-content: flex-start; margin-top: 32px; }
  .story { width: 100%; max-width: 540px; margin-top: 0; justify-self: end; }
}
