/* The Upstarts Club: site styles. Ported 1:1 from the locked homepage (type/homepage/, 6 Oct); only selectors changed
   to match WordPress block markup. Measurements: type/MOCKUP_SPEC.md. */
/* Mona Sans Condensed at weight 850: matches the lightness of Steve's lettering (Black, 900, is about 4% heavier) */
@font-face{font-family:'Head';src:url('../fonts/MonaSansCondensed-850.woff2') format('woff2');font-display:block;}
@font-face{font-family:'Num';src:url('../fonts/BarlowCondensed-300.woff2') format('woff2');font-weight:300;font-display:block;}
@font-face{font-family:'Nav';src:url('../fonts/BarlowCondensed-500.woff2') format('woff2');font-weight:500;font-display:block;}
@font-face{font-family:'B-GoogleSansFlex';src:url('../fonts/GoogleSansFlex-400.woff2') format('woff2');font-weight:400;font-display:block;}
@font-face{font-family:'B-GoogleSansFlex';src:url('../fonts/GoogleSansFlex-700.woff2') format('woff2');font-weight:700;font-display:block;}

/* Standard-density monitors draw thin strokes wider, so body text looks heavier there.
   On those screens only, use instances about 30 weight units lighter (optical compensation). Retina screens keep the measured weights. */
@media (max-resolution:1.5dppx){
@font-face{font-family:'B-GoogleSansFlex';src:url('../fonts/GoogleSansFlex-400lo.woff2') format('woff2');font-weight:400;font-display:block;}
@font-face{font-family:'B-GoogleSansFlex';src:url('../fonts/GoogleSansFlex-700lo.woff2') format('woff2');font-weight:700;font-display:block;}
}

/* Everything is measured from Steve's mock-ups (type/MOCKUP_SPEC.md). Sizes are % of the page width (cqw),
   so the layout is the mock-up at any laptop width; the page stops growing at 1280px. */
/* Body: Google Sans Flex (Steve, 5 Oct), at the weights that match the mock-up's lightness (370 / bold 680) */
:root{--k:0.9576;--trk:0.02em;--body:'B-GoogleSansFlex'}
*{box-sizing:border-box}
html,body{margin:0;background:#000;color:#fff}
body{-webkit-font-smoothing:antialiased}
.page{max-width:1280px;margin:0 auto;container-type:inline-size}

/* Header, as in the mock-ups */
header.site{display:flex;align-items:center;justify-content:space-between;padding:2.1cqw 6cqw 0 5.9cqw}
.wordmark{font-family:'Head';font-size:2.32cqw;line-height:.79;letter-spacing:-0.012em;text-transform:uppercase}
nav{display:flex;align-items:center;gap:3.1cqw}
nav a{font-family:'Nav';font-weight:500;font-size:1.36cqw;letter-spacing:.01em;color:#fff;text-decoration:none;text-transform:uppercase}
.menu{width:2.2cqw;height:1.6cqw;display:flex;flex-direction:column;justify-content:space-between;margin-left:1.2cqw}
.menu i{display:block;height:2px;background:#fff}

/* Chapters */
section.ch{position:relative;padding:4.3cqw 0 9cqw}
.is-style-num{font-family:'Num';font-weight:300;font-size:calc(var(--cap)*0.33/0.71);line-height:1;margin:0 0 0 6.1cqw}
/* Number-to-headline and headline-to-body gaps exactly as Steve approved for chapters 1-2 (6 Oct), used on all chapters */
h1,h2{font-family:'Head';font-weight:400;text-transform:uppercase;margin:calc(var(--cap)*0.32) 0 0 6cqw;
  font-size:calc(var(--cap)/0.729);line-height:calc(var(--cap)*1.08);letter-spacing:-0.012em}
h1 span,h2 span{display:block}
/* Body column: starts 20% in, about 60% wide, quiet */
.copy{margin:calc(var(--cap)*0.45) 0 0 20cqw;width:62cqw;font-family:var(--body);letter-spacing:var(--trk)}
.copy p{margin:0 0 max(14px,calc(var(--bs)*var(--gap)));font-size:max(16px,calc(var(--bs)*var(--k)));line-height:var(--lh)}
.copy p.is-style-lede{font-size:max(20px,calc(var(--bs)*1.47*var(--k)));line-height:1.3;margin-bottom:max(22px,calc(var(--bs)*1.5))}
.copy b,.copy strong{font-weight:700}
/* In the mock-up the three short opening lines of chapter 1 are spaced more openly than the rest */
.copy p.is-style-airy{line-height:1.72}
/* Chapter 1 headline is sized so its longest line ends where the mock-up's does (about 84% across);
   chapters 2-4 match the mock-up's capital height. */
/* Column width, line spacing and paragraph gap per chapter, measured from each mock-up page */
#c1{--cap:8.4cqw;--bs:1.92cqw;--lh:1.38;--gap:1.2}
#c2{--cap:7.3cqw;--bs:1.74cqw;--lh:1.27;--gap:0.75}
#c1 .copy{width:63cqw}
#c2 .copy{width:60cqw;margin-left:21cqw}
/* On laptops the lines break exactly where the mock-ups break them; below 1024px text flows naturally */
.copy br.d{display:inline}
@media (min-width:1025px){.home .copy p{white-space:nowrap}}


/* Chapter 3: measured from mock-up page 3. Headline capital height 7.2% (88px at 1223); the founders line is a
   sub-headline at about half that (4.05%), inside the body column */
#c3{--cap:7.2cqw;--bs:1.74cqw;--lh:1.27;--gap:0.62}
#c3 .copy{width:60cqw;margin-left:20.7cqw}
h3{font-family:'Head';font-weight:400;text-transform:uppercase;letter-spacing:-0.012em;
  --sub:3.9cqw;font-size:calc(var(--sub)/0.729);line-height:calc(var(--sub)*1.09);margin:calc(var(--sub)*0.45) 0 calc(var(--sub)*0.5)}
h3 span{display:block}
/* Chapter 4: measured from mock-up page 4. Headline capital height 8.5% (104px), more open body lines */
#c4{--cap:8.5cqw;--bs:1.74cqw;--lh:1.42;--gap:0.75}
#c4 .copy{width:42cqw;margin-left:20.5cqw}
#c4 .is-style-num{font-size:calc(7.3cqw*0.33/0.71)}
.ch .wp-block-button__link{display:inline-flex;align-items:center;justify-content:space-between;gap:2cqw;box-sizing:border-box;width:25cqw;height:5.56cqw;
  margin-top:calc(var(--bs)*0.82);padding:0 2.2cqw;background:#fff;color:#000;text-decoration:none;
  font-family:'Nav';font-weight:500;font-size:1.95cqw;letter-spacing:.01em;text-transform:uppercase}
.ch .wp-block-button__link svg{width:2.1cqw;height:auto;flex:none}
.ch .wp-block-button__link:focus-visible,.scroll-cue:focus-visible,a:focus-visible{outline:2px solid #fff;outline-offset:4px}
/* The map from his page 4: real geography in a staggered dot grid at his dot spacing, cities where he placed them
   (San Francisco about 70%, New York 78%, London 91% across); the three city dots breathe */
#c4{overflow:hidden}
.map-wrap{position:absolute;left:66cqw;width:34cqw;top:63.4cqw;margin:0}
.map{display:block;width:100%;height:auto;overflow:visible;color:#fff}
.map__land{stroke:#fff;stroke-opacity:.8;stroke-width:6.6;stroke-linecap:round}
.map__dot{fill:#fff}
.map__halo{fill:#fff;opacity:0;transform-box:fill-box;transform-origin:center;animation:breathe 3.6s ease-in-out infinite}
.map__city:nth-of-type(2) .map__halo{animation-delay:1.2s}
.map__city:nth-of-type(3) .map__halo{animation-delay:2.4s}
@keyframes breathe{0%{opacity:.45;transform:scale(1)}70%{opacity:0;transform:scale(2.6)}100%{opacity:0;transform:scale(2.6)}}
.map text{font-family:'Nav';font-weight:500;font-size:28px;letter-spacing:.12em;fill:#fff}
/* Scroll cue, as in the mock-ups: bottom left of the first screen, inside the empty left margin (label ends before
   the body column at 20%); it fades once the reader scrolls. Without scripts it simply sits at the end of the first screen */
.scroll-cue{--pw:min(100vw,1280px);position:absolute;left:calc((100vw - var(--pw))/2 + var(--pw)*0.054);top:calc(100svh - var(--pw)*0.046 - 40px);
  display:flex;align-items:flex-end;gap:calc(var(--pw)*0.014);color:#fff;text-decoration:none;transition:opacity .4s ease;z-index:2}
.js .scroll-cue{position:fixed;top:auto;bottom:calc(var(--pw)*0.046)}
.js.scrolled .scroll-cue{opacity:0;pointer-events:none}
.scroll-cue svg{width:max(18px,calc(var(--pw)*0.022));height:auto}
.scroll-cue span{font-family:'Nav';font-weight:500;font-size:max(10px,calc(var(--pw)*0.0082));letter-spacing:.18em;text-transform:uppercase;line-height:1;padding-bottom:.3em;white-space:nowrap}
body{position:relative}
.page{position:relative}
/* Footer: quiet, same column logic as the chapters */
.site-foot{padding:6cqw 0 5cqw}
.foot{padding:0 6cqw;display:grid;grid-template-columns:14cqw 1fr;column-gap:0;row-gap:1.6cqw}
.foot .wordmark{grid-row:1 / span 4}
.foot-line{margin:0;font-family:var(--body);letter-spacing:var(--trk);font-size:max(15px,calc(1.45cqw*var(--k)));line-height:1.4;max-width:46cqw}
.foot-nav{display:flex;flex-wrap:wrap;gap:1.2cqw 2.6cqw}
.foot-nav a,.foot-small a{font-family:'Nav';font-weight:500;font-size:max(13px,1.15cqw);letter-spacing:.06em;text-transform:uppercase;color:#fff;text-decoration:none}
.foot-mail,.foot-small{margin:0}
.foot-mail a{font-family:var(--body);letter-spacing:var(--trk);font-size:max(15px,calc(1.45cqw*var(--k)));color:#fff}
.foot-small a{color:#bbb}
/* Motion: each chapter headline's lines rise in once as it comes into view. Text is in the page without scripts;
   nothing moves with reduced motion; print and PDF show everything */
.js .rise span{opacity:0;transform:translateY(.35em)}
.js .rise.in span{opacity:1;transform:none;transition:opacity .7s ease,transform .9s cubic-bezier(.2,.7,.2,1)}
.js .rise.in span:nth-child(2){transition-delay:.08s}
.js .rise.in span:nth-child(3){transition-delay:.16s}
.js .rise.in span:nth-child(4){transition-delay:.24s}
@media (prefers-reduced-motion:reduce){.js .rise span{opacity:1;transform:none;transition:none}.map__halo{animation:none}}
@media print{.js .rise span{opacity:1;transform:none}.scroll-cue{display:none}}

/* Tablet and small laptop: menu collapses to the icon; body text never drops below 16px (set above) */
@media (max-width:1024px){
  .copy br.d{display:none}
  .scroll-cue{display:none}
  header.site nav a{display:none}
  .wordmark{font-size:max(20px,2.32cqw)}
  .menu{width:max(24px,2.2cqw);height:max(17px,1.6cqw)}
  .copy{width:66cqw}
  #c4 .copy{width:66cqw}
  .map-wrap{position:static;width:auto;margin:6cqw 0 0 20.5cqw}
  .ch .wp-block-button__link{width:auto;height:auto;padding:16px 22px;font-size:20px;gap:28px}
  .ch .wp-block-button__link svg{width:22px}
}
/* Phone */
@media (max-width:700px){
  header.site{padding:20px 20px 0}
  .wordmark{font-size:22px}
  header.site nav a{display:none}
  .menu{width:24px;height:17px}
  section.ch{padding:40px 0 64px}
  .is-style-num{margin-left:20px}
  h1,h2{margin-left:20px}
  #c1{--cap:9.4cqw} #c2{--cap:8.6cqw} #c3{--cap:10.2cqw} #c4{--cap:11cqw}
  .copy{margin-left:20px;width:auto;margin-right:20px}
  #c1,#c2{--bs:16px}
  .copy p{font-size:calc(16.7px*var(--k));line-height:1.45}
  .copy p.is-style-lede{font-size:calc(21px*var(--k));line-height:1.3}
  .copy p.is-style-airy{line-height:1.6}
  #c3,#c4{--bs:16px}
  #c1 .copy,#c2 .copy,#c3 .copy,#c4 .copy{margin-left:20px;width:auto;margin-right:20px}
  #c4 .is-style-num{font-size:calc(var(--cap)*0.33/0.71)}
  h3{--sub:7cqw}
  .map-wrap{margin:40px -20px 0 72px}
  .scroll-cue{display:none}
  .foot{grid-template-columns:1fr;padding:0 20px;row-gap:18px}
  .foot .wordmark{grid-row:auto;font-size:22px}
  .foot-line{max-width:none}
  /* Footer links big enough to tap (Lighthouse target size, 18 Oct): taller tap area, more space between rows */
  .foot-nav{gap:6px 22px}
  .foot-nav a,.foot-small a{display:inline-block;padding:6px 0}
}

/* Theme additions (not in the preview page) */
a.wordmark{display:block;color:#fff;text-decoration:none}
/* Final logo file (once uploaded): same width as the text wordmark, i.e. the width of UPSTARTS (3.42 x font size) */
.wordmark-img{display:block;width:3.42em;height:auto}
.skip{position:absolute;left:-9999px;top:0;z-index:10;background:#fff;color:#000;padding:10px 14px;font:16px/1.2 system-ui,sans-serif}
.skip:focus{left:16px;top:16px}

/* Fergus's testimonial (Steve, 9 Oct): the whole text once, after chapter 4 and just before the footer. Un-numbered,
   no boxes, no oversized quotation marks: body typography in the body column 20% in, the opening mark hung just
   outside the column, name and role underneath in the small label style */
.testimonial{--bs:1.74cqw;padding:0 0 3cqw}
.testimonial blockquote{margin:0 0 0 20cqw;width:50cqw;font-family:var(--body);letter-spacing:var(--trk)}
.testimonial p{margin:0 0 max(14px,var(--bs));font-size:max(16px,calc(var(--bs)*var(--k)));line-height:1.42}
.testimonial p:first-child{text-indent:-.42em}
.testimonial cite{display:block;margin-top:max(24px,calc(var(--bs)*1.7));font-style:normal;font-family:'Nav';font-weight:500;
  text-transform:uppercase;letter-spacing:.14em;font-size:max(13px,1.2cqw);line-height:1.5}
@media (max-width:1024px){.testimonial blockquote{width:66cqw}}
@media (max-width:700px){
  .testimonial{padding:0 0 24px}
  .testimonial blockquote{margin:0 20px;width:auto}
  .testimonial p{font-size:calc(16.7px*var(--k));line-height:1.45}
}
