/* BrockleyWellNess — rebuilt from nothing.
   ------------------------------------------------------------------
   The page is the story. It opens in the dark with nothing in it, and
   breaks into light and colour on the way down. Colours are lifted off
   the family's own photographs: the near-black green of Flagstaff pine,
   the turquoise of the water they train next to, and the sand.
   ------------------------------------------------------------------ */

:root{
  --void:#08120C;        /* rock bottom. near-black, green-shifted */
  --void-2:#0E1E15;      /* a step up out of it */
  --bone:#F4EFE4;        /* sand */
  --bone-2:#E7DECB;
  --surf:#19C4AC;        /* the water. the loud one */
  --surf-deep:#0A6B5E;   /* the same colour, dark enough to read on sand */
  --sun:#FFC233;         /* sunlight */
  --ember:#FF5F2E;       /* the hot accent, used once or twice, never as decoration */
  --ember-deep:#B8360F;  /* the same accent, dark enough to be read on sand */

  --ink:#08120C;
  --ink-soft:#4F6056;
  --bone-soft:#B9C4B8;

  --disp:"Bricolage Grotesque",system-ui,-apple-system,sans-serif;
  --serif:"Newsreader",Georgia,"Times New Roman",serif;
  --col:36rem;
  --wide:72rem;
}

*{box-sizing:border-box}
html{scroll-behavior:smooth;-webkit-text-size-adjust:100%}
html,body{overflow-x:hidden}
body{
  margin:0;background:var(--bone);color:var(--ink);
  font-family:var(--serif);font-size:1.18rem;line-height:1.62;
  -webkit-font-smoothing:antialiased;
  padding-bottom:env(safe-area-inset-bottom,0px);
}
img{max-width:100%;height:auto;display:block}
.sr{position:absolute;width:1px;height:1px;overflow:hidden;clip:rect(0 0 0 0)}
.skip{position:absolute;left:-999px;background:var(--surf);color:var(--void);padding:.7rem 1.1rem;z-index:50;font-family:var(--disp);font-weight:700;text-decoration:none}
.skip:focus{left:.5rem;top:.5rem}
:focus-visible{outline:3px solid var(--sun);outline-offset:3px}

/* ============ ACT ONE: the dark ============ */
.dark{background:var(--void);color:var(--bone)}
.dark a{color:var(--surf)}

.masthead{
  max-width:var(--wide);margin:0 auto;
  padding:calc(1.1rem + env(safe-area-inset-top,0px)) 1.5rem 1.4rem;
}
.topnav{
  display:flex;flex-wrap:wrap;gap:.4rem 1.5rem;justify-content:center;
  font-family:var(--disp);font-size:.78rem;font-weight:700;
  letter-spacing:.08em;text-transform:uppercase;
}
/* inline-block + padding so each is a 24px+ tap target, not a 12px word */
.topnav a{color:var(--bone-soft);text-decoration:none;display:inline-block;padding:.5rem 0}
.topnav a:hover,.topnav a:focus-visible{color:var(--surf)}
h1.wordmark{
  margin:1.5rem 0 0;text-align:center;
  font-family:var(--disp);font-weight:800;font-size:clamp(1.5rem,3.4vw,2.1rem);
  letter-spacing:-.03em;line-height:1;
}
.wordmark a{color:var(--bone);text-decoration:none}
.wordmark a:hover{color:var(--surf)}
.dateline{
  margin:.6rem 0 0;text-align:center;
  font-family:var(--disp);font-size:.72rem;font-weight:600;letter-spacing:.14em;
  text-transform:uppercase;color:var(--bone-soft);
}

/* ---- the opening: film hard against the type, no polite margins ---- */
.opening{
  max-width:var(--wide);margin:0 auto;padding:2.2rem 1.5rem 3rem;
  display:grid;grid-template-columns:minmax(0,.95fr) minmax(0,1.12fr);
  gap:clamp(1.6rem,3.4vw,3rem);align-items:center;
}
.film{margin:0;position:relative}
.film video{
  width:100%;height:auto;display:block;
  border-radius:2px;
  box-shadow:0 0 0 1px rgba(244,239,228,.14), 0 26px 60px -24px rgba(0,0,0,.9);
}
.film figcaption{
  font-family:var(--disp);font-size:.7rem;font-weight:700;letter-spacing:.13em;
  text-transform:uppercase;color:var(--bone-soft);margin-top:.85rem;
}

/* The shout.
   These spans MUST be display:block here and not inside the reduced-motion
   query below. They were only blocked inside that query, so on any machine with
   "Reduce motion" switched on the three words ran inline and rendered as
   "REBUILTFROM NOTHING." off the side of the screen. Layout never belongs
   inside a motion preference — only the animation does. */
.headline > span{display:block}
.headline{
  font-family:var(--disp);font-weight:800;
  font-size:clamp(2.7rem,7.7vw,5.6rem);line-height:.9;letter-spacing:-.045em;
  margin:0 0 1.3rem;text-transform:uppercase;
  /* Sized to leave roughly 15% slack on the longest word. The real face is
     Bricolage Grotesque, which this build environment cannot download, so the
     measurements come from a fallback — the headline must not be tuned to fit
     its column exactly or a different set of glyph widths pushes it off-screen. */
}
.headline .glow{
  color:var(--surf);
  display:block;
}
.opening .standfirst{
  font-size:clamp(1.08rem,1.45vw,1.26rem);line-height:1.5;color:var(--bone-soft);
  margin:0 0 1.7rem;max-width:34ch;
}
.opening .standfirst b{color:var(--bone);font-weight:400}

/* ---- buttons that look like buttons ---- */
/* These are deliberately `.dark a.cta`, not `.cta`. `.dark a` above sets every
   link in a dark block to turquoise, and it outranks a bare `.cta`, which painted
   turquoise text on a turquoise button. Specificity, not colour, was the bug. */
.cta,
.dark a.cta{
  display:inline-flex;align-items:center;gap:.5rem;
  font-family:var(--disp);font-weight:800;font-size:.9rem;letter-spacing:.01em;
  text-decoration:none;padding:.85rem 1.4rem;border-radius:2px;
  background:var(--surf);color:var(--void);border:2px solid var(--surf);
}
.dark a.cta:hover{background:var(--sun);border-color:var(--sun);color:var(--void)}
.dark a.cta-ghost{background:transparent;color:var(--bone);border-color:rgba(244,239,228,.45)}
.dark a.cta-ghost:hover{background:transparent;border-color:var(--surf);color:var(--surf)}
.actions{display:flex;gap:.9rem;flex-wrap:wrap;margin:0}

/* ---- the rock-bottom story, told in the dark ---- */
.lede{max-width:var(--col);margin:0 auto;padding:0 1.5rem 4.5rem}
.lede p{margin:0 0 1.2rem}
.lede .first::first-letter{
  float:left;font-family:var(--disp);font-weight:800;
  font-size:5.2rem;line-height:.76;padding:.3rem .6rem 0 0;color:var(--surf);
}
.byline{
  font-family:var(--disp);font-size:.72rem;font-weight:700;letter-spacing:.16em;
  text-transform:uppercase;color:var(--bone-soft);margin-top:2rem!important;
}

/* ============ THE TURN: full-bleed, out of the dark ============ */
.turn{position:relative;margin:0}
/* No fixed height and no object-fit. This is a five-person family portrait and
   every face sits in the top half of the frame; cropping it to a letterbox cut
   the top of two heads off. A photograph of people gets shown whole. */
.turn img{width:100%;height:auto;display:block}
.turn figcaption{
  position:absolute;inset:auto 0 0 0;
  padding:clamp(1.4rem,5vw,3.4rem);
  /* The caption sits over a photograph, so the scrim has to carry the whole
     height of the text, not just fade in at the very bottom. */
  background:linear-gradient(to top,rgba(8,18,12,.95) 0%,rgba(8,18,12,.88) 42%,rgba(8,18,12,.55) 72%,rgba(8,18,12,0) 100%);
  color:var(--bone);
  font-family:var(--disp);font-weight:800;text-transform:uppercase;
  font-size:clamp(1.5rem,4.6vw,3.2rem);line-height:.95;letter-spacing:-.035em;
}
/* The scrim has to run the full width of the photograph. Putting max-width on
   the figcaption itself sized the gradient to the text and left a hard vertical
   edge down the middle of the picture, so the measure goes on the span instead. */
.turn figcaption span{display:block;max-width:20ch}
.turn em{color:var(--surf);font-style:normal}

/* ============ ACT TWO: the light ============ */
.light{background:var(--bone);color:var(--ink)}
.light a{color:var(--surf-deep)}
main{padding:0}
.chapter{max-width:var(--wide);margin:0 auto;padding:clamp(3rem,7vw,5rem) 1.5rem 0}
.chapter:last-of-type{padding-bottom:clamp(3rem,7vw,5rem)}
.chapter-h{
  font-family:var(--disp);font-weight:800;text-transform:uppercase;
  font-size:clamp(1.6rem,4.4vw,2.6rem);letter-spacing:-.03em;line-height:1;
  margin:0 0 .7rem;
}
.chapter-h::after{
  content:"";display:block;width:3.5rem;height:5px;background:var(--surf);margin-top:.9rem;
}
.chapter-lede{max-width:52ch;margin:0 0 2.4rem;color:var(--ink-soft)}

/* A four-up grid, not a list. The old side-by-side entry left ~400px of empty
   paper to the right of every paragraph — the same dead space the hero had.
   Every figure is forced to 3:4: h1/h2.webp are already 700x933 so they are not
   cropped at all, and the two 9:16 gym clips lose ~12% top and bottom, which is
   ceiling and turf. 4:3 was tested and cuts hands and feet off. */
.entries{
  display:grid;grid-template-columns:repeat(4,minmax(0,1fr));
  gap:clamp(1.1rem,2.2vw,1.9rem);
}
.entry{
  display:block;padding:1rem 0 0;border-top:3px solid var(--ink);
  counter-increment:entry;
}
.chapter{counter-reset:entry}
.entry figure{margin:0 0 1rem}
.entry figure img,.entry figure video{
  /* height:auto is load-bearing. <video> carries width/height attributes as
     presentational hints, and with both set the aspect-ratio is ignored — the
     clips rendered 253x1280. <img> gets height:auto from the global rule, which
     is the only reason the photos happened to work. */
  width:100%;height:auto;aspect-ratio:3/4;object-fit:cover;display:block;
  border-radius:2px;background:var(--bone-2);
}
.entry h3{
  font-family:var(--disp);font-weight:800;text-transform:uppercase;
  font-size:clamp(1.05rem,2.3vw,1.5rem);letter-spacing:-.02em;line-height:1.05;margin:0 0 .7rem;
  /* "BODYWEIGHT," is one long word and overran a 127px column at 320px */
  overflow-wrap:break-word;hyphens:auto;
}
.entry h3::before{
  content:counter(entry,decimal-leading-zero);
  display:block;font-family:var(--disp);font-size:.78rem;font-weight:800;
  letter-spacing:.12em;color:var(--ember-deep);margin-bottom:.55rem;
}
.entry p{margin:0;font-size:1rem;line-height:1.5;color:var(--ink-soft)}

/* ---- the stack: a shopping list you can actually buy from ---- */
.index{width:100%;border-collapse:collapse}
.index tr{border-top:2px solid var(--bone-2)}
.index tr:last-child{border-bottom:2px solid var(--bone-2)}
.index th,.index td{text-align:left;padding:1.05rem .4rem;vertical-align:middle}
.index th{font-weight:400}
.index th a{
  display:inline-block;padding:.2rem 0;
  font-family:var(--disp);font-weight:700;font-size:clamp(1rem,2vw,1.2rem);
  color:var(--ink);text-decoration:none;
  background-image:linear-gradient(var(--surf),var(--surf));
  background-size:100% 3px;background-repeat:no-repeat;background-position:0 100%;
  padding-bottom:3px;
}
.index th a:hover{color:var(--surf-deep);background-image:linear-gradient(var(--ember-deep),var(--ember-deep))}
.index td{
  text-align:right;font-family:var(--disp);font-size:.7rem;font-weight:700;
  letter-spacing:.12em;text-transform:uppercase;color:var(--ink-soft);white-space:nowrap;
}

/* ---- three ways in ---- */
.compare{width:100%;border-collapse:collapse}
.compare thead th{
  font-family:var(--disp);font-size:.7rem;font-weight:800;letter-spacing:.13em;
  text-transform:uppercase;color:var(--ink-soft);text-align:left;
  padding:0 1.2rem .7rem 0;border-bottom:3px solid var(--ink);
}
.compare tbody th,.compare tbody td{
  text-align:left;padding:1.15rem 1.2rem 1.15rem 0;
  border-bottom:2px solid var(--bone-2);vertical-align:top;
}
.compare tbody th{font-weight:400}
.compare tbody th a{
  font-family:var(--disp);font-weight:800;font-size:clamp(1.02rem,2vw,1.24rem);
  color:var(--ink);text-decoration:none;
  background-image:linear-gradient(var(--surf),var(--surf));
  background-size:100% 3px;background-repeat:no-repeat;background-position:0 100%;
  padding-bottom:3px;
}
.compare tbody th a:hover{color:var(--surf-deep)}
.compare .price{
  font-family:var(--disp);font-weight:800;font-size:1.05rem;white-space:nowrap;color:var(--ember-deep);
}
.compare .who{color:var(--ink-soft);font-size:1.02rem;max-width:46ch}

.chapter-foot{margin:1.6rem 0 0}
.arrow{
  display:inline-block;font-family:var(--disp);font-weight:800;font-size:.86rem;
  text-decoration:none;color:var(--surf-deep);
  border-bottom:3px solid var(--surf);padding-bottom:3px;
}
.arrow::after{content:" \2192"}
.arrow:hover{color:var(--ember-deep);border-bottom-color:var(--ember-deep)}

/* ============ CLOSING: back to the dark, pointing forward ============ */
.closing{
  max-width:var(--wide);margin:0 auto;
  padding:clamp(3rem,7vw,5rem) 1.5rem;
  display:grid;grid-template-columns:19rem 1fr;gap:clamp(1.8rem,4vw,3rem);align-items:center;
}
.closing figure{margin:0}
.closing figure img{border-radius:2px;box-shadow:0 24px 60px -28px rgba(0,0,0,.9)}
.closing h2{
  font-family:var(--disp);font-weight:800;text-transform:uppercase;
  font-size:clamp(2rem,5.6vw,3.6rem);line-height:.92;letter-spacing:-.04em;margin:0 0 1rem;
}
.closing h2 em{color:var(--surf);font-style:normal}
.closing p{margin:0 0 1.5rem;max-width:44ch;color:var(--bone-soft)}

/* ============ colophon ============ */
.colophon{
  max-width:var(--wide);margin:0 auto;padding:2.6rem 1.5rem 3.2rem;text-align:center;
  border-top:1px solid rgba(244,239,228,.14);
}
.wordmark.small{font-size:1.25rem;margin:0}
.colophon nav{
  display:flex;justify-content:center;flex-wrap:wrap;gap:.4rem 1.4rem;margin:1.1rem 0 1.5rem;
  font-family:var(--disp);font-size:.74rem;font-weight:700;letter-spacing:.1em;text-transform:uppercase;
}
.colophon nav a{color:var(--bone-soft);text-decoration:none;display:inline-block;padding:.5rem 0}
.colophon nav a:hover{color:var(--surf)}
.fine{font-family:var(--disp);font-size:.78rem;font-weight:500;color:var(--bone-soft);margin:.45rem 0;line-height:1.5}
.fine a{color:var(--surf);display:inline-block;padding:.3rem 0}

/* ============ arrival: one orchestrated moment, not fades on everything ============ */
@media(prefers-reduced-motion:no-preference){
  .js .headline > span{
    opacity:0;transform:translateY(.55em);
    animation:rise .75s cubic-bezier(.16,.84,.34,1) forwards;
  }
  .js .headline > span:nth-child(1){animation-delay:.10s}
  .js .headline > span:nth-child(2){animation-delay:.21s}
  .js .headline > span:nth-child(3){animation-delay:.32s}
  .js .opening .standfirst,.js .opening .actions{
    opacity:0;animation:rise .7s cubic-bezier(.16,.84,.34,1) .46s forwards;
  }
  .js .film{opacity:0;animation:rise .9s cubic-bezier(.16,.84,.34,1) .04s forwards}
  @keyframes rise{to{opacity:1;transform:none}}
}

@media(max-width:900px){
  .opening{grid-template-columns:1fr;gap:1.5rem;padding-bottom:2.4rem}
  .closing{grid-template-columns:1fr;gap:1.5rem}
  .closing figure{max-width:15rem}
  .entries{grid-template-columns:repeat(2,minmax(0,1fr))}
}
@media(max-width:380px){
  .entries{grid-template-columns:1fr}
}
@media(max-width:620px){
  body{font-size:1.1rem}
  .compare thead{display:none}
  .compare tbody th,.compare tbody td{display:block;border-bottom:0;padding:.15rem 0}
  .compare tbody tr{display:block;padding:1.2rem 0;border-bottom:2px solid var(--bone-2)}
  .index th,.index td{display:block;text-align:left;padding:.75rem .2rem}
  .index td{padding-top:0}
  .actions{width:100%}
  .cta{flex:1 1 auto;justify-content:center}
}
@media(prefers-reduced-motion:reduce){html{scroll-behavior:auto}}
