/* Page-owned styles for how-it-works */
.how-it-works-main {
  overflow-x: hidden;
}

/* Section titles */
.hiw-section-title {
  margin-block-end: var(--spacing-5);
  text-align: center;
}

/* Hero */
.hiw-hero {
  padding-block-start: var(--spacing-7);
  padding-block-end: var(--spacing-7);
  background-color: var(--color-midnight-indigo);
}

.hiw-hero__container {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: var(--spacing-4);
  max-width: 720px;
  margin-inline: auto;
  text-align: center;
}

.hiw-hero__title {
  font-size: var(--font-size-h1);
  margin-block-end: 0;
}

.hiw-hero__intro {
  font-size: var(--font-size-large-body);
  color: var(--color-silver-grey);
  max-width: 720px;
  margin-block-end: 0;
}

.hiw-hero__actions {
  display: flex;
  justify-content: center;
  gap: var(--spacing-3);
  margin-block-start: var(--spacing-2);
}

/* Basics and Host and Know card grids */
.hiw-basics__grid,
.hiw-host__grid,
.hiw-know__grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: var(--spacing-4);
}

.hiw-basics__card,
.hiw-host__card,
.hiw-know__card {
  display: flex;
  flex-direction: column;
  gap: var(--spacing-3);
  min-width: 0;
}

.hiw-basics__card-title,
.hiw-host__card-title,
.hiw-know__card-title {
  margin-block-end: 0;
}

.hiw-basics__card-text,
.hiw-host__card-text,
.hiw-know__card-text {
  margin-block-end: 0;
  color: var(--color-silver-grey);
  max-width: 65ch;
}

/* Icons */
.hiw-basics__icon,
.hiw-host__icon,
.hiw-know__icon {
  width: 40px;
  height: 40px;
  border-radius: var(--radius-md);
  background-color: var(--color-graphite-hover);
  position: relative;
  flex-shrink: 0;
}

.hiw-basics__icon::before,
.hiw-host__icon::before,
.hiw-know__icon::before {
  content: "";
  position: absolute;
  inset: 0;
  background-repeat: no-repeat;
  background-position: center;
  background-size: 24px 24px;
}

.hiw-basics__icon--card::before {
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='24' height='24' viewBox='0 0 24 24' fill='none' stroke='%232563EB' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Crect x='2' y='6' width='20' height='12' rx='2'/%3E%3Cpath d='M6 10h.01M10 10h.01M14 10h.01M18 10h.01M6 14h.01M10 14h.01M14 14h.01M18 14h.01'/%3E%3C/svg%3E");
}

.hiw-basics__icon--plate::before {
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='24' height='24' viewBox='0 0 24 24' fill='none' stroke='%232DD4BF' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Ccircle cx='12' cy='12' r='9'/%3E%3Ccircle cx='12' cy='12' r='4'/%3E%3C/svg%3E");
}

.hiw-basics__icon--speech::before {
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='24' height='24' viewBox='0 0 24 24' fill='none' stroke='%232563EB' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M21 15a2 2 0 0 1-2 2H7l-4 4V5a2 2 0 0 1 2-2h14a2 2 0 0 1 2 2z'/%3E%3C/svg%3E");
}

.hiw-host__icon--gavel::before {
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='24' height='24' viewBox='0 0 24 24' fill='none' stroke='%232563EB' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M14 13l-8 8M2 22l8-8M14 13l7-7M21 6l-3-3M14 13l-3 3M11 10l3-3'/%3E%3C/svg%3E");
}

.hiw-host__icon--handshake::before {
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='24' height='24' viewBox='0 0 24 24' fill='none' stroke='%232DD4BF' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M11 17l-3-3 3-3 2 2 3-3 3 3-3 3-2-2-3 3z'/%3E%3Cpath d='M8 14l-3 3M16 14l3 3M8 14l-2-2M16 14l2-2'/%3E%3C/svg%3E");
}

.hiw-host__icon--clock::before {
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='24' height='24' viewBox='0 0 24 24' fill='none' stroke='%232563EB' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Ccircle cx='12' cy='12' r='9'/%3E%3Cpath d='M12 7v5l3 2'/%3E%3C/svg%3E");
}

.hiw-know__icon--id::before {
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='24' height='24' viewBox='0 0 24 24' fill='none' stroke='%232563EB' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Crect x='2' y='5' width='20' height='14' rx='2'/%3E%3Ccircle cx='8' cy='11' r='2'/%3E%3Cpath d='M4 17l4-4 3 3 4-4 5 5'/%3E%3C/svg%3E");
}

.hiw-know__icon--cash::before {
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='24' height='24' viewBox='0 0 24 24' fill='none' stroke='%232DD4BF' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Crect x='2' y='6' width='20' height='12' rx='2'/%3E%3Ccircle cx='12' cy='12' r='3'/%3E%3Cpath d='M6 12h.01M18 12h.01'/%3E%3C/svg%3E");
}

.hiw-know__icon--etiquette::before {
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='24' height='24' viewBox='0 0 24 24' fill='none' stroke='%232563EB' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M12 2a5 5 0 0 1 5 5c0 1.5-.5 2.5-1 3.5L14 14h-4l-2-3.5c-.5-1-1-2-1-3.5a5 5 0 0 1 5-5z'/%3E%3Cpath d='M8 14l-3 3M16 14l3 3M8 14l-2 2M16 14l2 2'/%3E%3C/svg%3E");
}

/* Steps timeline */
.hiw-steps__timeline {
  list-style: none;
  padding-inline-start: 0;
  margin-block-end: 0;
  position: relative;
}

.hiw-steps__timeline::before {
  content: "";
  position: absolute;
  left: 19px;
  top: 10px;
  bottom: 10px;
  width: 2px;
  background-color: rgba(45, 212, 191, 0.5);
}

.hiw-steps__item {
  display: flex;
  gap: var(--spacing-4);
  padding-block-end: var(--spacing-5);
  position: relative;
  min-width: 0;
}

.hiw-steps__item:last-child {
  padding-block-end: 0;
}

.hiw-steps__marker {
  flex-shrink: 0;
  width: 40px;
  height: 40px;
  border-radius: 50%;
  background-color: var(--color-cobalt-blue);
  color: var(--color-ice-white);
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: var(--font-weight-semibold);
  z-index: 1;
}

.hiw-steps__content {
  flex: 1 1 auto;
  min-width: 0;
}

.hiw-steps__item-title {
  margin-block-end: var(--spacing-2);
}

.hiw-steps__item-text {
  margin-block-end: 0;
  color: var(--color-silver-grey);
  max-width: 75ch;
}

/* League */
.hiw-league__grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: var(--spacing-5);
}

.hiw-league__paragraph p {
  margin-block-end: 0;
  color: var(--color-silver-grey);
  max-width: 75ch;
}

.hiw-league__list-title {
  margin-block-end: var(--spacing-3);
}

.hiw-league__items {
  list-style: none;
  padding-inline-start: 0;
  margin-block-end: 0;
  display: flex;
  flex-direction: column;
  gap: var(--spacing-2);
}

.hiw-league__items li {
  position: relative;
  padding-inline-start: var(--spacing-5);
  color: var(--color-silver-grey);
}

.hiw-league__items li::before {
  content: "";
  position: absolute;
  left: 0;
  top: 0.2em;
  width: 20px;
  height: 20px;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='20' height='20' viewBox='0 0 24 24' fill='none' stroke='%232DD4BF' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M20 6L9 17l-5-5'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: center;
}

/* Scheduling */
.hiw-scheduling__grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: var(--spacing-5);
}

.hiw-scheduling__text p {
  margin-block-end: var(--spacing-3);
  color: var(--color-silver-grey);
  max-width: 75ch;
}

.hiw-scheduling__text p:last-child {
  margin-block-end: 0;
}

.hiw-scheduling__figure {
  margin-block-end: 0;
  min-width: 0;
}

.hiw-scheduling__figure img {
  width: 100%;
  height: auto;
  display: block;
  border: 1px solid rgba(148, 163, 184, 0.1);
  transition: transform var(--transition-fast);
}

.hiw-scheduling__figure:hover img {
  transform: scale(1.02);
}

.hiw-scheduling__caption {
  margin-block-start: var(--spacing-2);
  text-align: center;
  color: var(--color-silver-grey);
}

/* Gallery */
.hiw-gallery__grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: var(--spacing-4);
}

.hiw-gallery__figure {
  margin-block-end: 0;
  min-width: 0;
}

.hiw-gallery__figure img {
  width: 100%;
  height: auto;
  display: block;
  border: 1px solid rgba(148, 163, 184, 0.1);
  transition: transform var(--transition-fast);
}

.hiw-gallery__figure:hover img {
  transform: scale(1.02);
}

.hiw-gallery__caption {
  margin-block-start: var(--spacing-2);
  text-align: center;
  color: var(--color-silver-grey);
}

/* Variations */
.hiw-variations__container {
  max-width: 800px;
  margin-inline: auto;
  text-align: center;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: var(--spacing-3);
}

.hiw-variations__note-icon {
  width: 48px;
  height: 48px;
  border-radius: 50%;
  background-color: rgba(45, 212, 191, 0.15);
  position: relative;
}

.hiw-variations__note-icon::before {
  content: "";
  position: absolute;
  inset: 0;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='24' height='24' viewBox='0 0 24 24' fill='none' stroke='%232DD4BF' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M12 22a10 10 0 1 0 0-20 10 10 0 0 0 0 20z'/%3E%3Cpath d='M12 16v-4M12 8h.01'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: center;
  background-size: 24px 24px;
}

.hiw-variations__text {
  max-width: 80ch;
  margin-block-end: 0;
  color: var(--color-silver-grey);
}

/* CTA */
.hiw-cta {
  padding-block-start: var(--spacing-7);
  padding-block-end: var(--spacing-7);
  background-color: var(--color-midnight-indigo);
}

.hiw-cta__container {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: var(--spacing-4);
  max-width: 600px;
  margin-inline: auto;
  text-align: center;
}

.hiw-cta__title {
  margin-block-end: 0;
}

.hiw-cta__text {
  margin-block-end: 0;
  color: var(--color-silver-grey);
  max-width: 70ch;
}

.hiw-cta__actions {
  display: flex;
  justify-content: center;
  gap: var(--spacing-3);
  margin-block-start: var(--spacing-2);
}

/* Tablet and desktop */
@media (min-width: 768px) {
  .hiw-basics__grid,
  .hiw-host__grid,
  .hiw-know__grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: var(--spacing-4);
  }

  .hiw-league__grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: var(--spacing-5);
  }

  .hiw-scheduling__grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: var(--spacing-5);
  }

  .hiw-gallery__grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: var(--spacing-4);
  }
}

@media (max-width: 767px) {
  .hiw-hero {
    padding-block-start: var(--spacing-5);
    padding-block-end: var(--spacing-6);
  }

  .hiw-hero__title {
    font-size: var(--font-size-h1);
  }

  .hiw-hero__intro {
    font-size: var(--font-size-body);
  }

  .hiw-cta {
    padding-block-start: var(--spacing-5);
    padding-block-end: var(--spacing-6);
  }

  .hiw-steps__timeline::before {
    left: 19px;
  }

  .hiw-steps__item {
    gap: var(--spacing-3);
  }

  .hiw-steps__marker {
    width: 36px;
    height: 36px;
    font-size: var(--font-size-caption);
  }
}

@media (min-width: 992px) {
  .hiw-basics__grid,
  .hiw-host__grid,
  .hiw-know__grid {
    gap: var(--spacing-5);
  }
}
