/* Below the hero: how it works, the product mock-up, the bands, data care, close, footer.
   Split from styles.css only to keep each file under 500 lines. */

/* ---- How it works ---- */

.how {
  position: relative;
  width: min(1120px, 100% - 2 * var(--gutter));
  margin: 0 auto;
  padding: 24px 0 var(--section);
  display: grid;
  gap: 40px;
}

.how-intro .lead {
  margin: 0;
}

.steps {
  margin: 0;
  padding: 0 0 0 24px;
  list-style: none;
  border-left: 1px solid var(--rule);
  display: grid;
  gap: 40px;
}

.steps li {
  position: relative;
  display: grid;
  grid-template-columns: 3rem 1fr;
  gap: 4px 16px;
}

/* Each step hangs off the rule by a short wire. */
.steps li::before {
  content: '';
  position: absolute;
  left: -24px;
  top: 1.6rem;
  width: 16px;
  height: 1px;
  background: var(--rule);
}

.step-num {
  font-family: var(--display);
  font-size: 3rem;
  font-weight: 700;
  line-height: 0.95;
  color: var(--navy);
}

.steps p {
  margin: 0;
  max-width: 52ch;
}

/* ---- Product mock-up (the volunteer's list screen, demo brand) ---- */

.mock-figure {
  margin: 0;
  justify-self: center;
  width: min(340px, 100%);
}

.mock {
  border: 8px solid var(--ink);
  border-radius: 28px;
  overflow: hidden;
  background: var(--demo-paper);
  color: var(--demo-ink);
  font-size: 1rem;
  line-height: 1.4;
}

.mock p {
  margin: 0;
}

.mock-bar,
.mock-foot {
  padding: 14px 16px;
  background: var(--demo-brand);
  color: var(--demo-on-brand);
  font-weight: 700;
}

.mock-body {
  padding: 18px 14px 20px;
}

.mock-heading {
  font-size: 1.625rem;
  font-weight: 700;
  line-height: 1.2;
  margin-bottom: 6px !important;
}

.mock svg {
  width: 1.15em;
  height: 1.15em;
  flex: none;
  fill: none;
  stroke: currentColor;
  stroke-width: 2.4;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.mock-summary {
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: 1.125rem;
}

.mock-check {
  color: var(--demo-voted);
}

.mock-toggle {
  display: flex;
  align-items: center;
  gap: 8px;
  margin: 14px 0 !important;
  padding: 10px 12px;
  border: 2px solid var(--demo-brand);
  border-radius: 8px;
  background: var(--demo-brand-tint);
  font-weight: 700;
}

.mock-rows {
  margin: 0;
  padding: 0;
  list-style: none;
  background: var(--demo-surface);
  border: 1px solid var(--demo-rule);
  border-radius: 12px;
}

.mock-rows li {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  padding: 12px;
}

.mock-rows li + li {
  border-top: 1px solid var(--demo-rule);
}

.mock-name {
  font-size: 1.125rem;
  font-weight: 700;
}

.mock-call {
  padding: 8px 18px;
  border-radius: 8px;
  background: var(--demo-brand);
  color: var(--demo-on-brand);
  font-weight: 700;
}

.mock-prompt {
  flex-basis: 100%;
  padding: 8px 10px;
  border: 2px solid var(--demo-brand);
  border-radius: 8px;
  font-weight: 700;
}

.mock-chip {
  display: flex;
  gap: 6px;
  flex-basis: 100%;
  padding: 6px 10px;
  border-radius: 4px;
  background: var(--demo-chip);
  color: var(--demo-muted);
}

.mock-figure figcaption {
  margin-top: 12px;
  font-size: 1rem;
  color: var(--ink-muted);
}

/* ---- Built for the volunteers you have (navy band) ---- */

.band-navy {
  padding: var(--section) 0;
  background: var(--navy);
  color: var(--on-navy);
}

.band-navy .headline {
  color: var(--on-navy);
}

.phrases {
  margin: 2.5rem 0;
  padding: 0;
  list-style: none;
  display: grid;
  gap: 0.25rem 2.5rem;
  font-family: var(--display);
  font-size: clamp(1.75rem, 1.4rem + 1.4vw, 2.5rem);
  font-weight: 700;
  line-height: 1.15;
}

.pair {
  display: grid;
  gap: 32px;
}

.pair > div {
  padding-top: 20px;
  border-top: 1px solid var(--rule-on-navy);
}

.pair p {
  margin: 0;
  max-width: 52ch;
}

/* ---- Your data ---- */

.data {
  padding: var(--section) 0;
}

.claims {
  margin: 2.5rem 0 2rem;
  padding: 0;
  list-style: none;
  border-top: 1px solid var(--rule);
}

.claims li {
  display: grid;
  gap: 4px 48px;
  padding: 20px 0;
  border-bottom: 1px solid var(--rule);
}

.claims .title,
.claims p {
  margin: 0;
}

.claims p {
  max-width: 34em;
}

.annex {
  margin: 0;
}

/* ---- Coming: organizations ---- */

.coming {
  padding: calc(var(--section) * 0.75) 0;
  background: var(--navy-tint);
}

.coming .wrap {
  position: relative;
}

.rider-label {
  display: inline-block;
  margin: 0 0 1.25rem;
  padding: 6px 14px;
  background: var(--white);
  border: 1px solid var(--navy);
  border-radius: 4px;
  color: var(--navy);
  font-size: 1rem;
  font-weight: 700;
  line-height: 1.3;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.coming .lead {
  margin: 0;
}

/* ---- Close: a navy panel with a thin red rule, and a white strip for the action ---- */

.close {
  width: var(--box);
  margin: var(--gutter) auto;
  padding: clamp(48px, 7vw, 96px) clamp(16px, 5vw, 72px) clamp(16px, 4vw, 56px);
  background: var(--navy);
  color: var(--on-navy);
  /* Square on the rule's side, so the red rule doesn't bend round a corner (review round 3). */
  border-radius: var(--sign-radius) var(--sign-radius) 0 0;
  border-bottom: 4px solid var(--red);
}

.close :focus-visible,
.band-navy :focus-visible {
  outline-color: var(--white);
}

.close-head {
  font-family: var(--display);
  font-size: clamp(2.5rem, 1.6rem + 3.6vw, 4.5rem);
  font-weight: 700;
  line-height: 1.05;
  margin: 0 0 1rem;
}

.close .lead {
  margin-bottom: clamp(2rem, 4vw, 3.5rem);
}

.close-rider {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px 24px;
  padding: 8px;
  background: var(--white);
  color: var(--ink);
  border-radius: 4px;
}

.close .close-rider :focus-visible {
  outline-color: var(--ink);
}

.close-rider .btn {
  flex: 1 1 100%;
}

.close-email {
  margin: 0;
  padding-inline: 8px;
}

.close-email a {
  display: inline-block;
  padding: 10px 0;
}

.mock-cta {
  margin: 32px 0 0;
}

.mock-cta .btn {
  width: 100%;
}

/* ---- Footer strip ---- */

.footer {
  padding: 28px 0 36px;
  font-size: 1rem;
}

.footer .wrap {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  gap: 8px 32px;
}

.footer .wordmark {
  margin-right: 0;
}

.footer p {
  margin: 0;
}

.footer p:last-child {
  color: var(--ink-muted);
}

/* Phones: numeral above the title so step text gets the full width. */
@media (max-width: 639px) {
  .steps li {
    grid-template-columns: 1fr;
  }

  .step-num {
    font-size: 2.5rem;
  }
}

@media (min-width: 640px) {
  .close-rider {
    width: fit-content;
  }

  .close-rider .btn {
    flex: none;
  }

  .phrases {
    grid-template-columns: repeat(2, max-content);
  }

  .pair {
    grid-template-columns: 1fr 1fr;
    gap: 48px;
  }
}

@media (min-width: 900px) {
  .claims li {
    grid-template-columns: minmax(0, 5fr) minmax(0, 7fr);
  }

  .footer p:last-child {
    margin-left: auto;
  }
}

/* Desktop: the left stake's line becomes the rule the steps hang off; the mock sits to the right. */
@media (min-width: 1200px) {
  .how {
    width: var(--box);
    padding-top: 0;
    grid-template-columns: 28% minmax(0, 1fr) 340px;
    gap: 0;
    align-items: start;
  }

  .how-intro {
    padding: 48px 48px 0 0;
  }

  .steps {
    padding: 56px 56px 0 40px;
    gap: 56px;
  }

  .steps li::before {
    left: -40px;
    width: 28px;
  }

  .mock-figure {
    padding-top: 56px;
    position: sticky;
    top: 0;
  }
}
