/* ==========================================================================
   House of Pros — About page (/about)
   Black, silver and the homepage's three faces: British Green for the big
   lines, Helvetica Neue Light for statements, Arial for reading text.
   Motion is gentle and happens once: the opening headline, blocks easing in
   as they arrive, and the closing line lighting up as you scroll through it.
   ========================================================================== */

.ab-page {
  --ab-text: #f2f3f5;
  --ab-mist: #9ba1aa;
  --ab-line: rgba(242, 243, 245, 0.12);
  --ab-glass: rgba(242, 243, 245, 0.04);
  --ab-wrap: 1180px;
  background: #000;
  color: var(--ab-text);
  font-family: var(--font-arial);
  font-size: 17px;
  line-height: 1.6;
}

.ab-page p {
  margin: 0;
}

/* The logo pill keeps the site's serif */
.ab-page .nav {
  font-family: var(--font);
}

.ab-page h2,
.ab-page h3 {
  margin: 0;
  font-weight: 400;
}

/* Soft white light behind everything, moved by the scroll (js/about.js) */
.ab-glow {
  position: fixed;
  inset: 0;
  z-index: -1;
  overflow: hidden;
  pointer-events: none;
}

.ab-glow span {
  position: absolute;
  top: 0;
  left: 0;
  width: 80vmax;
  height: 80vmax;
  margin: -40vmax 0 0 -40vmax; /* positioned by its centre */
  border-radius: 50%;
  background: radial-gradient(circle, rgba(255, 255, 255, 0.11), rgba(255, 255, 255, 0.04) 38%, rgba(255, 255, 255, 0) 68%);
  will-change: transform;
  transition: transform 1.2s cubic-bezier(0.22, 1, 0.36, 1), opacity 1.2s cubic-bezier(0.22, 1, 0.36, 1);
}

.ab-glow span:nth-child(1) {
  transform: translate(15vw, 10vh);
}

.ab-glow span:nth-child(2) {
  width: 64vmax;
  height: 64vmax;
  margin: -32vmax 0 0 -32vmax;
  transform: translate(90vw, 80vh);
}

.ab-glow span:nth-child(3) {
  width: 52vmax;
  height: 52vmax;
  margin: -26vmax 0 0 -26vmax;
  opacity: 0.7;
  transform: translate(50vw, 120vh);
}

/* --------------------------------------------------------------------------
   Opening
   -------------------------------------------------------------------------- */

.ab-hero {
  position: relative;
  display: grid;
  place-items: center;
  min-height: 100svh;
  padding: 120px var(--gutter) 96px;
  overflow: hidden;
  isolation: isolate;
  text-align: center;
}

/* The HP monogram, large and faint behind the headline */
.ab-hero__mark {
  position: absolute;
  top: 50%;
  left: 50%;
  z-index: -1;
  width: auto;
  height: min(86svh, 980px);
  max-width: none;
  opacity: 0.07;
  translate: -50% -50%;
  pointer-events: none;
  user-select: none;
}

/* A thin line at the bottom with a light running down it: keep scrolling */
.ab-hero__cue {
  position: absolute;
  left: 50%;
  bottom: 32px;
  width: 1px;
  height: 56px;
  overflow: hidden;
  background: rgba(242, 243, 245, 0.16);
}

.ab-hero__cue::after {
  content: "";
  position: absolute;
  left: 0;
  top: 0;
  width: 1px;
  height: 22px;
  background: rgba(242, 243, 245, 0.85);
  animation: ab-cue 2.4s cubic-bezier(0.65, 0, 0.35, 1) infinite;
}

@keyframes ab-cue {
  from {
    transform: translateY(-22px);
  }
  to {
    transform: translateY(56px);
  }
}

.ab-hero__inner {
  max-width: 1040px;
}

.ab-hero__title {
  margin: 0;
  font-family: var(--font-hero);
  font-weight: 400;
  font-size: clamp(3rem, min(14vw, 15svh), 8rem);
  line-height: 0.92;
  letter-spacing: -0.015em;
  color: #fff;
  -webkit-text-stroke: 0.02em #fff;
  paint-order: stroke fill;
  text-wrap: balance;
  text-shadow: 0 2px 40px rgba(0, 0, 0, 0.35);
}

.ab-page .ab-hero__lede {
  max-width: 34em;
  margin: clamp(24px, 3.4vh, 36px) auto 0;
  font-family: var(--font-neue);
  font-weight: 300;
  font-size: clamp(17px, 1.7vw, 21px);
  line-height: 1.45;
  color: rgba(242, 243, 245, 0.86);
  text-wrap: balance;
}

/* --------------------------------------------------------------------------
   Sections
   -------------------------------------------------------------------------- */

.ab-sec {
  max-width: var(--ab-wrap);
  margin: 0 auto;
  padding: clamp(88px, 12vw, 168px) var(--gutter) 0;
}

.ab-h2 {
  font-family: var(--font-hero);
  font-size: clamp(2.4rem, 4.6vw, 4rem);
  line-height: 0.98;
  letter-spacing: -0.01em;
  color: #fff;
  text-wrap: balance;
}

.ab-sec p,
.ab-pin p {
  color: var(--ab-mist); /* the white lines below override this */
}

/* Heading on the left (stays in view), text on the right */
.ab-split {
  display: grid;
  grid-template-columns: minmax(0, 5fr) minmax(0, 7fr);
  gap: 40px clamp(40px, 7vw, 112px);
  align-items: start;
}

.ab-split__head {
  position: sticky;
  top: 120px;
}

.ab-split__head p {
  max-width: 30em;
  margin-top: 24px;
}

.ab-split__body > p + p {
  margin-top: 20px;
}

.ab-page .ab-statement {
  margin-bottom: 36px;
  font-family: var(--font-neue);
  font-weight: 300;
  font-size: clamp(24px, 2.6vw, 34px);
  line-height: 1.3;
  letter-spacing: -0.01em;
  color: var(--ab-text);
}

/* Free membership: the answer is the headline */
.ab-free {
  text-align: center;
}

.ab-free__q {
  font-family: var(--font-neue);
  font-weight: 300;
  font-size: clamp(20px, 2vw, 26px);
  color: var(--ab-mist);
}

.ab-page .ab-free__a {
  margin-top: 14px;
  word-spacing: 0.06em;
  font-family: var(--font-hero);
  font-size: clamp(3rem, 8.4vw, 7.5rem);
  line-height: 0.95;
  letter-spacing: -0.015em;
  color: #fff;
  text-wrap: balance;
}

.ab-free__cols {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 24px 48px;
  max-width: 860px;
  margin: clamp(40px, 5vw, 64px) auto 0;
  text-align: left;
}

/* Heading with a short line under it */
.ab-intro {
  max-width: 640px;
}

.ab-intro p {
  margin-top: 20px;
}

.ab-intro--center {
  margin: 0 auto;
  text-align: center;
}

/* --------------------------------------------------------------------------
   Sections that hold still while you scroll ([data-pin], see js/about.js)
   Without JavaScript (or with reduced motion) they're ordinary lists.
   -------------------------------------------------------------------------- */

.ab-pin {
  max-width: var(--ab-wrap);
  margin: 0 auto;
  padding: clamp(88px, 12vw, 168px) var(--gutter) 0;
}

/* The stage is as tall as its content and holds still in the middle of the
   screen (js/about.js measures it into --stage-h and --pin-top); the extra
   height below it is the scrolling that moves through the items */
.pin-on .ab-pin {
  --at: 0; /* 0 to 1 as you scroll through the section */
  max-width: none;
  height: calc(var(--stage-h, 100svh) + (var(--count) - 1) * 55svh);
  margin-top: clamp(88px, 12vw, 168px);
  padding: 0;
}

.pin-on .ab-pin {
  position: relative;
}

.pin-on .ab-pin__stage {
  position: sticky;
  top: var(--pin-top, 96px);
  display: grid;
  max-width: var(--ab-wrap);
  margin: 0 auto;
  padding: 0 var(--gutter);
}

/* What we offer: one at a time */
.ab-offers .ab-pin__stage {
  grid-template-columns: minmax(0, 5fr) minmax(0, 7fr);
  gap: 32px clamp(40px, 7vw, 112px);
  align-items: center;
}

.ab-offers__side p {
  max-width: 28em;
  margin-top: 20px;
}

.ab-pin__bar {
  display: none;
  height: 1px;
  max-width: 280px;
  margin-top: 40px;
  background: var(--ab-line);
}

.ab-pin__bar span {
  display: block;
  height: 100%;
  background: rgba(242, 243, 245, 0.85);
  transform-origin: left;
  transform: scaleX(var(--at));
}

.ab-offers__list {
  margin: 0;
  padding: 0;
  list-style: none;
}

.ab-offer {
  padding: 24px 0;
  border-top: 1px solid var(--ab-line);
}

.ab-offer h3 {
  font-family: var(--font-neue);
  font-weight: 300;
  font-size: clamp(22px, 2vw, 26px);
  line-height: 1.2;
  color: var(--ab-text);
}

.ab-offer p {
  max-width: 34em;
  margin-top: 10px;
}

.pin-on .ab-pin__bar {
  display: block;
}

.pin-on .ab-offers__list {
  display: grid;
}

.pin-on .ab-offer {
  grid-area: 1 / 1;
  align-self: center;
  padding: 0;
  border: 0;
  opacity: 0;
  filter: blur(8px);
  transform: translateY(36px);
  /* hidden offers stop being drawn once they've faded (lighter scrolling) */
  visibility: hidden;
  /* leaving: quick, so it's gone before the next one arrives */
  transition:
    opacity 0.28s cubic-bezier(0.4, 0, 1, 1),
    filter 0.28s cubic-bezier(0.4, 0, 1, 1),
    transform 0.32s cubic-bezier(0.4, 0, 1, 1),
    visibility 0s linear 0.32s;
  pointer-events: none;
}

.pin-on .ab-offer.is-past {
  transform: translateY(-36px);
}

/* arriving: starts as the previous one finishes leaving */
.pin-on .ab-offer.is-active {
  opacity: 1;
  filter: none;
  transform: none;
  visibility: visible;
  transition:
    opacity 0.6s var(--ease) 0.24s,
    filter 0.6s var(--ease) 0.24s,
    transform 0.8s var(--ease) 0.24s,
    visibility 0s linear 0s;
  pointer-events: auto;
}


.pin-on .ab-offer h3 {
  font-family: var(--font-hero);
  font-size: clamp(2.6rem, 5.4vw, 4.75rem);
  line-height: 0.98;
  letter-spacing: -0.01em;
  color: #fff;
  text-wrap: balance;
}

.pin-on .ab-offer p {
  margin-top: 24px;
  font-size: clamp(17px, 1.5vw, 20px);
  line-height: 1.55;
}

/* How to join: the steps light up in turn */
.ab-join__head {
  max-width: 640px;
}

.ab-join__head p {
  margin-top: 20px;
}

.ab-join__steps {
  position: relative;
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 32px;
  margin: clamp(48px, 7vh, 88px) 0 0;
  padding: 0;
  list-style: none;
}

/* The line joining the numbers, filling in as the steps advance */
.ab-join__steps::before,
.ab-join__steps::after {
  content: "";
  position: absolute;
  top: 28px;
  left: 28px;
  right: calc(25% - 52px); /* ends at the centre of the last number */
  height: 1px;
  background: var(--ab-line);
}

.ab-join__steps::after {
  background: rgba(242, 243, 245, 0.8);
  transform-origin: left;
  transform: scaleX(var(--step, 1));
  transition: transform 0.8s var(--ease);
}

.ab-step {
  position: relative;
}

.ab-step__n {
  position: relative;
  z-index: 1;
  display: grid;
  place-items: center;
  width: 56px;
  height: 56px;
  margin-bottom: 28px;
  border: 1px solid rgba(242, 243, 245, 0.28);
  border-radius: 50%;
  background: #000;
  /* British Green's digits sit high in their line; this drops them to the
     true centre of the circle (measured) */
  padding-top: 0.32em;
  font-family: var(--font-hero);
  font-size: 26px;
  line-height: 1;
  color: #fff;
  transition:
    background-color 0.6s var(--ease),
    color 0.6s var(--ease),
    border-color 0.6s var(--ease);
}

.ab-step h3 {
  font-family: var(--font-neue);
  font-weight: 300;
  font-size: 22px;
  line-height: 1.25;
  color: var(--ab-text);
}

.ab-step p {
  margin-top: 10px;
  font-size: 16px;
  transition: opacity 0.6s var(--ease), transform 0.8s var(--ease);
}

/* Steps ahead are dim, steps done are half-lit. Only the number and the text
   fade, never the circle itself, so the line never shows through it. */
.pin-on .ab-join .ab-step h3,
.pin-on .ab-join .ab-step__n {
  color: rgba(242, 243, 245, 0.3);
  transition: color 0.6s var(--ease), background-color 0.6s var(--ease), border-color 0.6s var(--ease);
}

.pin-on .ab-join .ab-step__n {
  border-color: rgba(242, 243, 245, 0.14);
}

.pin-on .ab-join .ab-step.is-past h3,
.pin-on .ab-join .ab-step.is-past .ab-step__n {
  color: rgba(242, 243, 245, 0.55);
}

.pin-on .ab-join .ab-step.is-past .ab-step__n {
  border-color: rgba(242, 243, 245, 0.3);
}

.pin-on .ab-join .ab-step.is-active h3 {
  color: var(--ab-text);
}

.pin-on .ab-join .ab-step.is-active .ab-step__n {
  border-color: #fff;
  background: #fff;
  color: #000;
}

.pin-on .ab-join .ab-step p {
  opacity: 0;
  transform: translateY(10px);
}

.pin-on .ab-join .ab-step.is-past p {
  opacity: 0.5;
  transform: none;
}

.pin-on .ab-join .ab-step.is-active p {
  opacity: 1;
  transform: none;
}

/* Who it's for: the roles, set as quiet pills */
.ab-chips {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 12px;
  max-width: 920px;
  margin: clamp(36px, 4vw, 52px) auto 0;
  padding: 0;
  list-style: none;
}

.ab-chips li {
  padding: 12px 20px;
  border: 1px solid var(--ab-line);
  border-radius: 999px;
  background: var(--ab-glass);
  font-family: var(--font-neue);
  font-weight: 300;
  font-size: clamp(15px, 1.4vw, 18px);
  line-height: 1.3;
  color: var(--ab-text);
}

.ab-page .ab-who__note {
  max-width: 34em;
  margin: clamp(32px, 4vw, 48px) auto 0;
  text-align: center;
}

/* Principles */
.ab-principles {
  margin: 0;
  padding: 0;
  list-style: none;
}

.ab-principles li {
  display: grid;
  grid-template-columns: 28px 1fr;
  padding: 20px 0;
  border-top: 1px solid var(--ab-line);
  font-family: var(--font-neue);
  font-weight: 300;
  font-size: clamp(18px, 1.7vw, 22px);
  line-height: 1.4;
  color: var(--ab-text);
}

.ab-principles li:last-child {
  border-bottom: 1px solid var(--ab-line);
}

.ab-principles li::before {
  content: "";
  width: 12px;
  height: 1px;
  margin-top: 0.7em;
  background: var(--ab-mist);
}

.ab-note {
  margin-top: 40px;
  padding: clamp(24px, 3vw, 36px);
  border: 1px solid var(--ab-line);
  border-radius: 20px;
  background: var(--ab-glass);
}

.ab-note h3 {
  font-family: var(--font-neue);
  font-weight: 300;
  font-size: 20px;
  color: var(--ab-text);
}

.ab-page .ab-note p {
  margin-top: 12px;
  font-size: 16px;
}

/* Closing */
.ab-close {
  max-width: 1040px;
  padding-bottom: clamp(96px, 12vw, 160px);
  text-align: center;
}

.ab-close__label {
  font-family: var(--font-neue);
  font-weight: 300;
  font-size: clamp(20px, 2vw, 26px);
  color: var(--ab-mist);
}

.ab-page .ab-close__big {
  margin-top: 24px;
  font-family: var(--font-hero);
  font-size: clamp(2.6rem, 6.2vw, 5.5rem);
  line-height: 1;
  letter-spacing: -0.015em;
  color: #fff;
  text-wrap: balance;
}

.ab-page .ab-close__text {
  max-width: 34em;
  margin: clamp(32px, 4vw, 48px) auto 0;
}

.ab-page .ab-close__sign {
  margin-top: clamp(40px, 5vw, 64px);
  font-family: var(--font-neue);
  font-weight: 300;
  font-size: clamp(20px, 2.2vw, 28px);
  line-height: 1.35;
  color: var(--ab-text);
}

.ab-close__cta {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 20px;
  margin-top: 36px;
}

.ab-page .ab-close__cta p {
  font-size: 15px;
}

.ab-footer {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  gap: 16px;
  padding: 24px var(--gutter) calc(24px + env(safe-area-inset-bottom, 0px));
  border-top: 1px solid var(--ab-line);
  font-family: var(--font);
  font-size: 14px;
  color: var(--silver-500);
}

.ab-footer p {
  margin: 0;
}

.ab-footer nav {
  display: flex;
  gap: 24px;
}

.ab-footer a {
  color: inherit;
  text-decoration: none;
  transition: color 0.3s var(--ease);
}

.ab-footer a:hover {
  color: var(--ab-text);
}

.ab-page a:focus-visible {
  outline: 1px solid var(--ab-text);
  outline-offset: 4px;
  border-radius: 4px;
}

/* --------------------------------------------------------------------------
   Motion (only when JavaScript runs; without it everything is simply shown)
   -------------------------------------------------------------------------- */

/* Opening headline: words clear from a soft blur and rise into place */
.js .ab-hero__title .w {
  display: inline-block;
  /* Safari draws each animating word as its own layer, cut to the word's box;
     British Green's letters (the serif of the "I") reach just outside it.
     Room on every side, taken back by the margin, so nothing is cut off and
     nothing moves. */
  padding: 0.12em 0.1em;
  margin: -0.12em -0.1em;
  opacity: 0;
  filter: blur(10px);
  transform: translateY(0.18em);
  transition:
    opacity 1.1s var(--ease),
    filter 1.1s var(--ease),
    transform 1.1s var(--ease);
  transition-delay: calc(0.15s + var(--i) * 0.08s);
}

.js .ab-hero__lede {
  opacity: 0;
  transform: translateY(10px);
  transition: opacity 1.2s var(--ease) 0.75s, transform 1.2s var(--ease) 0.75s;
}

.js.is-ready .ab-hero__title .w,
.js.is-ready .ab-hero__lede {
  opacity: 1;
  filter: none;
  transform: none;
}

/* The monogram settles in behind the headline, then drifts with the scroll
   (js/about.js sets the drift as --drift) */
.js .ab-hero__mark {
  opacity: 0;
  scale: 1.08;
  transform: translateY(var(--drift, 0px));
  transition: opacity 2s var(--ease) 0.2s, scale 2.4s var(--ease) 0.2s;
}

.js.is-ready .ab-hero__mark {
  opacity: 0.07;
  scale: 1;
}

/* Blocks ease in once as they arrive */
.js [data-reveal] {
  opacity: 0;
  transform: translateY(18px);
  transition: opacity 1s var(--ease), transform 1s var(--ease);
  transition-delay: var(--d, 0s);
}

.js [data-reveal].is-in {
  opacity: 1;
  transform: none;
}

/* Closing line: each word lights up as you scroll through it */
.js .ab-close__big .w {
  opacity: 0.18;
  transition: opacity 0.5s var(--ease);
}

.js .ab-close__big .w.is-lit {
  opacity: 1;
}

@media (prefers-reduced-motion: reduce) {
  .js .ab-hero__title .w,
  .js .ab-hero__lede,
  .js [data-reveal],
  .js .ab-close__big .w {
    opacity: 1;
    filter: none;
    transform: none;
  }
  .js .ab-hero__mark {
    opacity: 0.07;
    scale: 1;
  }
  .ab-hero__cue::after {
    animation: none;
  }
}

/* --------------------------------------------------------------------------
   Smaller screens
   -------------------------------------------------------------------------- */

@media (max-width: 900px) {
  .ab-split {
    grid-template-columns: 1fr;
  }
  .ab-split__head {
    position: static;
  }
  .ab-offers .ab-pin__stage {
    grid-template-columns: 1fr;
  }
  /* One column: the list takes the height of the offer showing, so a short
     offer leaves no gap below it */
  .pin-on .ab-offers__list {
    display: block;
    position: relative;
    height: var(--list-h, auto);
    transition: height 0.6s var(--ease);
  }
  .pin-on .ab-offer {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
  }
}

@media (max-width: 600px) {
  .ab-page {
    font-size: 16px;
  }
  .ab-hero {
    min-height: 88svh;
    padding-top: 104px;
  }
  .ab-hero__mark {
    height: min(60svh, 520px); /* whole monogram on screen */
  }
  .ab-free__cols {
    grid-template-columns: 1fr;
  }
  .ab-sec,
  .ab-pin {
    padding-top: 72px;
  }
  .pin-on .ab-pin {
    margin-top: 72px;
    padding-top: 0;
  }
  .ab-close {
    padding-bottom: 88px;
  }
  .pin-on .ab-offers .ab-pin__stage {
    gap: 28px;
  }
  .ab-offers__side p {
    margin-top: 12px;
  }
  .ab-pin__bar {
    margin-top: 20px;
  }
  .pin-on .ab-offer {
    align-self: start; /* title right under the progress line */
  }
  .pin-on .ab-offer p {
    margin-top: 16px;
  }
  .ab-join__head p {
    margin-top: 12px;
  }
  .ab-chips {
    gap: 8px;
  }
  .ab-chips li {
    padding: 10px 16px;
    border-radius: 20px; /* long roles wrap to two lines */
  }
  /* Steps stack. Each step draws the piece of line down to the next number,
     and that piece lights up once the step is done. */
  .ab-join__steps {
    grid-template-columns: 1fr;
    gap: 18px;
    margin-top: 28px;
  }
  .ab-join__steps::before,
  .ab-join__steps::after {
    display: none;
  }
  .ab-step {
    display: grid;
    grid-template-columns: 44px 1fr;
    column-gap: 18px;
    align-items: center;
  }
  .ab-step:not(:last-child)::after {
    content: "";
    position: absolute;
    top: 22px;
    left: 22px;
    width: 1px;
    height: calc(100% + 18px); /* down to the next number */
    background: var(--ab-line);
    transition: background-color 0.6s var(--ease);
  }
  .pin-on .ab-join .ab-step.is-past::after {
    background: rgba(242, 243, 245, 0.8);
  }
  .ab-step__n {
    width: 44px;
    height: 44px;
    margin: 0;
    font-size: 21px;
  }
  .ab-step h3 {
    font-size: 20px;
  }
  .pin-on .ab-join .ab-step h3 {
    transition: color 0.6s var(--ease), transform 0.6s var(--ease);
  }
  .pin-on .ab-join .ab-step.is-active h3 {
    transform: translateX(4px);
  }
  .ab-step p {
    grid-column: 2;
    margin-top: 6px;
    font-size: 15px;
  }
  /* Each step's description opens right under its title. Opening and
     closing run together at the same pace, so the steps below glide rather
     than jump. (Rows animate from 0fr to 1fr: a smooth height change.) */
  .pin-on .ab-join .ab-step {
    grid-template-rows: auto 0fr;
    transition: grid-template-rows 0.6s cubic-bezier(0.65, 0, 0.35, 1);
  }
  .pin-on .ab-join .ab-step.is-active {
    grid-template-rows: auto 1fr;
  }
  .pin-on .ab-join .ab-step p {
    grid-row: 2;
    min-height: 0;
    overflow: hidden;
    margin-top: 0;
    opacity: 0;
    transform: none;
    transition: opacity 0.3s var(--ease);
  }
  .pin-on .ab-join .ab-step.is-past p {
    opacity: 0;
  }
  .pin-on .ab-join .ab-step.is-active p {
    opacity: 1;
    transition: opacity 0.5s var(--ease) 0.2s;
  }
  /* the text's top gap lives inside the opening row, so it opens with it */
  .pin-on .ab-join .ab-step p::before {
    content: "";
    display: block;
    height: 6px;
  }
  .ab-footer {
    flex-direction: column;
    align-items: center;
    gap: 12px;
  }
  /* the icons lead, on a row of their own (as on the homepage) */
  .ab-footer .foot-socials {
    order: -1;
  }
}
