/* Home page owned styles */
#home-page {
  overflow-x: hidden;
}

/* Hero */
.home-hero {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: var(--space-6);
  align-items: center;
  padding-block: var(--space-8);
  padding-inline: var(--container-padding);
  max-width: var(--container-max);
  margin-inline: auto;
}

.home-hero__copy {
  min-width: 0;
}

.home-hero__copy .eyebrow {
  margin-block-end: var(--space-3);
}

.home-hero__copy h1 {
  font-size: clamp(2.25rem, 4vw + 1rem, 3rem);
  line-height: 1.1;
  font-weight: 700;
  margin-block-end: var(--space-4);
}

.home-hero__lead {
  font-size: var(--text-body-size);
  line-height: var(--text-body-line-height);
  margin-block-end: var(--space-5);
  max-width: 34rem;
}

.home-hero__actions {
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-3);
  align-items: center;
}

.home-hero__actions .btn {
  min-width: 0;
}

.home-hero__maze {
  min-width: 0;
  display: flex;
  justify-content: center;
  align-items: center;
}

.home-hero__maze-svg {
  width: 100%;
  max-width: 26rem;
  height: auto;
  display: block;
}

.maze-path {
  fill: none;
  stroke: var(--color-ink);
  stroke-width: 4;
  stroke-linecap: round;
  stroke-linejoin: round;
  stroke-dasharray: 1000;
  stroke-dashoffset: 1000;
  transition: stroke-dashoffset 1.2s ease;
}

.maze-path--accent {
  stroke: var(--color-lime);
  stroke-width: 6;
}

.maze-dot {
  fill: var(--color-orange);
}

.maze-dot--start {
  fill: var(--color-lime);
}

.maze-dot--end {
  fill: var(--color-orange);
}

.home-hero__maze-svg.is-drawn .maze-path {
  stroke-dashoffset: 0;
}

/* About */
.home-about {
  background-color: var(--color-paper);
}

.home-about__grid {
  display: grid;
  grid-template-columns: 3fr 2fr;
  gap: var(--space-6);
  align-items: start;
}

.home-about__copy {
  min-width: 0;
}

.home-about__copy h2 {
  margin-block-end: var(--space-4);
}

.home-about__copy p {
  margin-block-end: var(--space-4);
}

.home-about__figure {
  min-width: 0;
  margin: 0;
}

.home-about__figure img {
  width: 100%;
  height: auto;
  display: block;
  border: var(--border-ink);
  border-radius: 8px 4px 12px 6px;
  transform: rotate(1.5deg);
  transition: transform 0.25s ease, box-shadow 0.25s ease;
}

.home-about__figure img:hover {
  transform: rotate(0deg) scale(1.02);
  box-shadow: var(--shadow-hover);
}

.home-about__figure figcaption {
  margin-block-start: var(--space-2);
  text-align: center;
}

/* How */
.home-how__grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: var(--card-gap);
  margin-block-start: var(--space-5);
}

.home-step {
  min-width: 0;
  display: flex;
  flex-direction: column;
  gap: var(--space-3);
  padding: var(--card-padding);
  background-color: var(--color-paper);
  border: var(--border-ink);
  border-radius: var(--radius-medium);
  transition: box-shadow 0.25s ease, border-color 0.25s ease;
}

.home-step:hover {
  box-shadow: var(--shadow-hover);
  border-color: var(--color-lime);
}

.home-step__number {
  font-family: var(--font-heading);
  font-size: 2.5rem;
  font-weight: 700;
  line-height: 1;
  color: var(--color-ink);
  display: block;
}

.home-step h3 {
  margin-block-end: 0;
}

.home-step p {
  margin-block-end: 0;
}

/* Levels */
.home-levels {
  background-color: var(--color-paper-dark);
}

.home-levels__grid {
  display: grid;
  grid-template-columns: 3fr 2fr;
  gap: var(--space-6);
  align-items: center;
}

.home-levels__copy {
  min-width: 0;
}

.home-levels__copy h2 {
  margin-block-end: var(--space-4);
}

.home-levels__copy p {
  margin-block-end: 0;
}

.home-levels__fact {
  min-width: 0;
  background-color: var(--color-lime);
  color: var(--color-ink-on-lime);
  padding: var(--space-5);
  border-radius: var(--radius-medium);
  font-family: var(--font-heading);
  font-size: var(--text-h3-size);
  font-weight: 600;
  line-height: 1.4;
  text-align: center;
  display: flex;
  align-items: center;
  justify-content: center;
}

.home-levels__fact p {
  margin: 0;
}

/* Logic */
.home-logic__copy {
  max-width: 70%;
  margin-inline: 0;
}

.home-logic__copy h2 {
  margin-block-end: var(--space-4);
}

.home-logic__copy p {
  margin-block-end: var(--space-4);
}

.home-logic__copy p:last-child {
  margin-block-end: 0;
}

/* Offline */
.home-offline__grid {
  display: grid;
  grid-template-columns: 3fr 2fr;
  gap: var(--space-6);
  align-items: center;
}

.home-offline__copy {
  min-width: 0;
}

.home-offline__copy h2 {
  margin-block-end: var(--space-4);
}

.home-offline__copy p {
  margin-block-end: 0;
}

.home-offline__icon {
  min-width: 0;
  display: flex;
  justify-content: center;
  align-items: center;
  color: var(--color-ink);
}

.home-offline__icon svg {
  width: 100%;
  max-width: 8rem;
  height: auto;
  display: block;
}

/* Tips */
.home-tips__grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: var(--card-gap);
  margin-block-start: var(--space-5);
}

.home-tip {
  min-width: 0;
  display: flex;
  flex-direction: column;
  gap: var(--space-3);
  padding: var(--card-padding);
  background-color: var(--color-paper);
  border: var(--border-ink);
  border-radius: var(--radius-medium);
  transition: box-shadow 0.25s ease, border-color 0.25s ease;
}

.home-tip:hover {
  box-shadow: var(--shadow-hover);
  border-color: var(--color-lime);
}

.home-tip__icon {
  font-size: 2rem;
  line-height: 1;
  display: block;
}

.home-tip h3 {
  margin-block-end: 0;
}

.home-tip p {
  margin-block-end: 0;
}

/* Review */
.home-review {
  background-color: var(--color-paper);
}

.home-review__grid {
  display: grid;
  grid-template-columns: 3fr 2fr;
  gap: var(--space-6);
  align-items: center;
}

.home-review__copy {
  min-width: 0;
}

.home-review__copy h2 {
  margin-block-end: var(--space-4);
}

.home-review__copy p {
  margin-block-end: 0;
}

.home-review__rating {
  min-width: 0;
  background-color: var(--color-paper-dark);
  border: var(--border-ink);
  border-radius: var(--radius-medium);
  padding: var(--space-5);
  text-align: center;
  display: flex;
  flex-direction: column;
  gap: var(--space-3);
  align-items: center;
  justify-content: center;
}

.home-review__stars {
  font-size: 2rem;
  color: var(--color-orange);
  letter-spacing: 0.1em;
  margin: 0;
  line-height: 1;
}

.home-review__rating p:last-child {
  margin: 0;
  font-weight: 600;
}

/* Audience */
.home-audience__copy {
  max-width: 70%;
  margin-inline: 0;
}

.home-audience__copy h2 {
  margin-block-end: var(--space-4);
}

.home-audience__copy p {
  margin-block-end: var(--space-4);
}

.home-audience__copy p:last-child {
  margin-block-end: 0;
}

/* Final CTA */
.home-final {
  background-color: var(--color-lime);
  color: var(--color-ink-on-lime);
  padding-block: var(--space-8);
}

.home-final__copy {
  max-width: 60%;
  margin-inline: auto;
  text-align: center;
  display: flex;
  flex-direction: column;
  gap: var(--space-4);
  align-items: center;
}

.home-final__copy h2 {
  color: var(--color-ink-on-lime);
  margin-block-end: 0;
}

.home-final__copy p {
  margin-block-end: 0;
  max-width: 30rem;
}

.home-final__copy .btn {
  margin-block-start: var(--space-2);
}

/* Responsive */
@media (max-width: 64rem) {
  .home-hero {
    grid-template-columns: 1fr;
    gap: var(--space-5);
    padding-block: var(--space-7);
  }

  .home-hero__copy {
    text-align: left;
  }

  .home-hero__actions {
    justify-content: flex-start;
  }

  .home-hero__maze {
    order: 2;
  }

  .home-about__grid,
  .home-levels__grid,
  .home-offline__grid,
  .home-review__grid {
    grid-template-columns: 1fr;
    gap: var(--space-5);
  }

  .home-about__figure img {
    transform: rotate(0deg);
  }

  .home-about__figure img:hover {
    transform: scale(1.02);
  }

  .home-how__grid,
  .home-tips__grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .home-logic__copy,
  .home-audience__copy {
    max-width: 100%;
  }

  .home-final__copy {
    max-width: 80%;
  }
}

@media (max-width: 48rem) {
  .home-hero {
    padding-block: var(--space-6);
  }

  .home-hero__copy h1 {
    font-size: clamp(1.75rem, 5vw + 0.75rem, 2.25rem);
  }

  .home-how__grid,
  .home-tips__grid {
    grid-template-columns: 1fr;
    gap: var(--space-4);
  }

  .home-final__copy {
    max-width: 100%;
  }
}

@media (max-width: 36rem) {
  .home-hero__actions {
    flex-direction: column;
    align-items: stretch;
  }

  .home-hero__actions .btn {
    width: 100%;
  }

  .home-offline__icon svg {
    max-width: 6rem;
  }
}
