/* styles/sections/hero-lead.css
 * Lead hero: the hero-copy recipe (components.css) on the page surface, no figure.
 * Frames: 390 headline display-md, deck 18/1.5, actions stacked; 1440 and 1920 headline
 * display-lg, deck 20/1.5, actions in a row 20 apart. Padding is section-xs at every width. */
@layer sections {
  .home-hero {
    padding-block: var(--section-xs);
  }

  .home-hero__copy {
    --hero-pad-top: 0px;
    --hero-gap: var(--space-20);
    --hero-deck-size: 18px;
    --hero-deck-lh: 1.5;
    align-items: stretch;
  }

  .home-hero__copy .hero-copy__heading {
    text-wrap: wrap;
  }

  /* 390: Book a demo fills the row, the CLI link sits centered under it */
  .home-hero__copy .hero-copy__actions {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: var(--space-8);
  }

  .home-hero__copy .hero-copy__actions .btn {
    align-self: stretch;
  }

  /* The frames draw the CLI link as a 44px row. Its hover and press chip takes Book a demo's
     box (44px tall, 20px side padding: 19px plus a 1px transparent border, radius sm), so the
     two hero actions pad alike (BRI-7805 J4). */
  .home-hero__copy .hero-copy__actions .cli-link {
    --hit-extend: 0px;
    min-height: 44px;
    margin: 0;
    padding: 0 19px;
    border: 1px solid transparent;
  }

  @media (width >= 900px) {
    .home-hero__copy {
      --hero-gap: 28px;
      --hero-deck-size: 20px;
      --hero-actions-gap: 0px;
      align-items: flex-start;
    }

    .home-hero__copy .hero-copy__deck {
      max-width: 720px;
    }

    .home-hero__copy .hero-copy__actions {
      flex-direction: row;
      gap: var(--space-20);
    }

    .home-hero__copy .hero-copy__actions .btn {
      align-self: auto;
    }
  }

  @media (width >= 1680px) {
    .home-hero {
      --container-max: 1280px;
    }

    .home-hero__copy {
      --hero-deck-size: 20px;
    }
  }
}

/* Pencil sets every line on a whole pixel (88 x 0.95 = 84, 18 x 1.6 = 29, 17 x 1.6 = 27);
   these rounded line heights keep the page's text boxes the frames' size. */
@layer sections {
  .home-hero__copy {
    --hero-heading-lh: round(nearest, 0.95em, 1px);
    --hero-deck-lh: round(nearest, 1.5em, 1px);
  }
}
