/*
 * Home page "How it works": the three steps stacked on the left, a looping video of the
 * site on the right. Below 1024px the video moves under the steps at full width.
 */
.skc-how {
  display: grid;
  /* The steps take as much width as their longest title needs; the video gets the rest. */
  grid-template-columns: max-content minmax(0, 1fr);
  gap: 32px;
  width: 100%;
  align-items: stretch;
}

.skc-how-steps {
  display: flex;
  flex-direction: column;
  gap: 28px;
}

/* A step reads as a row here: icon on the left, title and text beside it. */
.skc-how-steps > .group {
  flex: 1 1 0;
  flex-direction: row;
  align-items: center;
  justify-content: flex-start;
  gap: 22px;
  padding: 22px 26px;
}

.skc-how-steps > .group > .mb-5 {
  margin-bottom: 0;
  flex: none;
}

.skc-how-steps > .group > .flex-col.relative.z-10 {
  align-items: flex-start;
  text-align: left;
}

.skc-how-steps > .group > .flex-col.relative.z-10 > span:first-child {
  white-space: nowrap;
}

.skc-how-steps > .group > .flex-col.relative.z-10 > span:last-child {
  max-width: 19rem;
}

/* The glow sat above a centred icon; in a row it belongs above the icon on the left. */
.skc-how-steps > .group > .blur-3xl {
  left: 56px;
}

/* The horizontal connectors joined cards side by side; stacked cards do without them. */
.skc-how-steps > .group > .h-px {
  display: none;
}

.skc-how-media {
  position: relative;
  overflow: hidden;
  /* The footage is 16:9; the steps stretch to its height, not the other way round. */
  aspect-ratio: 16 / 9;
  align-self: center;
  border: 1px solid #2a2a2e;
  border-radius: 12px;
  background: #0f0f12;
}

.skc-how-media video {
  position: absolute;
  inset: 0;
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
}

/* A soft inner edge so the footage sits in the card instead of on top of it. */
.skc-how-media::after {
  content: '';
  position: absolute;
  inset: 0;
  pointer-events: none;
  border-radius: inherit;
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.03), inset 0 0 40px rgba(0, 0, 0, 0.45);
}

@media (max-width: 1023px) {
  .skc-how {
    grid-template-columns: minmax(0, 1fr);
  }

  /* On narrow screens a long title wraps rather than pushing the card wider than the page. */
  .skc-how-steps > .group > .flex-col.relative.z-10 > span:first-child {
    white-space: normal;
  }

  /* No video beside them to match, so each step takes its own height. */
  .skc-how-steps > .group {
    flex: none;
  }

  .skc-how-media {
    align-self: stretch;
  }
}

@media (max-width: 640px) {
  .skc-how-steps > .group {
    gap: 16px;
    padding: 18px;
  }
}
