/* V46 (Oct 17 2026): The Letters hero, one shared component. These are The Letters' .lhero rules with the page scope dropped,
   values unchanged; The Letters keeps its own inline copy, which wins the cascade on that page. Per page: --lh-pos (desktop) and
   --lh-pos-ph (phone) set the plate's object-position. The dek and secondary-button rules use existing type styles. */
.lhero{position:relative;overflow:hidden;border-bottom:1px solid var(--stoa-hair)}
.lhero-media{position:absolute;inset:0;margin:0;display:block;overflow:hidden;z-index:0}
.lhero-media img{width:100%;height:100%;object-fit:cover;object-position:var(--lh-pos,75% 50%);display:block}
.lhero .wrap{position:relative;z-index:1;display:flex;align-items:flex-start;min-height:min(70vh,680px);padding-top:calc(var(--lh-head,72px) + 40px);padding-bottom:var(--space-block)}   /* --lh-head: the site header's height on this page (116px where a section subnav sits in the header) */
.lhero .hero-text{max-width:min(430px,34%)}
.lhero .hero-text .eyebrow{color:var(--stoa-ink);font-family:var(--stoa-sans);font-weight:600;font-size:var(--t-label);letter-spacing:.22em;text-transform:uppercase;margin:0 0 18px}
.lhero .hero-text .display{font-family:var(--stoa-serif);font-weight:400;font-size:var(--t-display);line-height:1.04;letter-spacing:-0.01em;color:var(--stoa-ink);margin:0}
.lhero .hero-text .rule{margin:22px 0 18px;max-width:60px}
.lhero .hero-text .tagline{font-family:var(--stoa-serif);font-weight:400;font-size:var(--t-h2);line-height:1.2;margin:0 0 22px;color:var(--stoa-ink)}
.lhero .hero-text .lh-dek{font-family:var(--stoa-sans);font-weight:400;font-size:var(--t-body);line-height:1.55;color:var(--stoa-ink);margin:0 0 22px}
.lhero-cta{display:flex;gap:14px;flex-wrap:wrap}
.lhero-cta .btn{display:inline-flex;align-items:center;gap:.5em;font-family:var(--stoa-sans);font-weight:600;font-size:var(--t-small);letter-spacing:.04em;text-transform:none;padding:11px 20px;border:1px solid var(--stoa-ink);border-radius:0;text-decoration:none;line-height:1;background:var(--stoa-ink);color:var(--stoa-base)}
.lhero-cta .btn::after{content:none}
.lhero-cta .btn:hover{background:transparent;color:var(--stoa-ink)}
@media (min-width:1025px){.lhero > :not(.lh-under){--stoa-ink:#20211f;--stoa-muted:#5e6070;--stoa-base:#f5f5f8;--stoa-surface:#fcfcfe;--stoa-rule:#20211f;--stoa-hair:#dcdde6;--stoa-sea-t:#3a6878}}
@media (min-width:601px) and (max-width:1100px){.lhero .hero-text{max-width:min(410px,34%)}.lhero .hero-text .display{font-size:30px;line-height:1.06}.lhero .hero-text .rule{margin:14px 0 12px}.lhero .hero-text .tagline{font-size:19px;margin:0 0 16px}.lhero .wrap{padding-top:calc(var(--lh-head,72px) + 26px)}}
@media (max-width:600px){.lhero{overflow:visible}.lhero-media{position:static;width:100%;aspect-ratio:4/5}.lhero-media img{object-position:var(--lh-pos-ph,50% 50%)}.lhero .wrap{display:block;min-height:0;padding-top:28px;padding-bottom:36px}.lhero .hero-text{max-width:none}.lhero .hero-text .display{font-size:var(--t-h1)}}

/* V50: the Terms and Privacy cross-link, under the hero, in the paper column */
.wrap > .lh-cross{margin:18px 0 0;font-family:var(--stoa-sans);font-size:var(--t-label)}

/* V51 (R67, Jake Oct 20 2026): the area under the hero holds The Letters' standard on the second-set pages. */
.lhero + main.nf-main{padding-top:40px}
.lhero + main.nf-main > .gd-list:first-child{margin-top:0}
.lhero + main.bfy > .bfy-hero{border-bottom:0;padding-bottom:8px}
.lhero + main.bfy .bfy-how{margin-top:0}
.lhero + main.bfy .bfy-card{background:none;border:1px solid var(--stoa-hair);padding:18px 18px 16px}
.lhero + main.bfy .bfy-rows li > span:first-child{max-width:65ch}
.lhero + main.gd-plain .gd-list li{border-bottom:1px solid var(--stoa-rule)}
.lhero + main.gd-plain .gd-list .nf-folio-meta{border-top-color:var(--stoa-hair)}
.lhero + main.gd-plain .gd-ledger li{display:grid;grid-template-columns:minmax(0,1fr) minmax(0,2fr);column-gap:32px;align-items:baseline}
.lhero + main.gd-plain .gd-ledger h2{margin:0}
.lhero + main.gd-plain .gd-ledger .gd-def{font-family:var(--stoa-sans);margin:0}
@media (max-width:640px){.lhero + main.gd-plain .gd-ledger li{grid-template-columns:minmax(0,1fr);row-gap:6px}}
.lhero ~ #top > .lh-cross{margin:40px 0 0}
.lhero ~ #top + .paper{padding-top:24px}
@media (min-width:1120px){.lhero ~ .paper .p78-summary{grid-template-columns:repeat(4,minmax(0,1fr))}}
@media (max-width:720px){.lhero ~ .paper .p78-summary .led-stat:nth-child(3){border-bottom:1px solid var(--stoa-rule)}}

/* R73 (Jake, Oct 20 2026): the hero button at --t-small (14px) outside /letters, which keeps its own inline rule */

/* R72 (Jake, Oct 20 2026): about 40px from the hero to the first content on the V46 pages (The Letters: 37px); /start's plan as ruled rows */
.lhero ~ main.nf-main{padding-top:11px}
.lhero + main.access-r3 > .room > .wrap{padding-top:40px}
.lhero + .dr-wrap > .dr-left{padding-top:40px}
.lhero + .dr-wrap > .dr-right{background:none;padding-top:40px}
.lhero + section.jhero{padding-top:20px}
.lhero + .hero-foot > .wrap{border-top:0;padding-top:37px}
.lhero + .mx-head{padding-top:26px}

/* R65 (Jake, Oct 20 2026): a page whose hero dek was shortened carries the full paragraph, word for word, as its first body paragraph (The Letters' intro style) */
.lh-body{padding-top:40px}
.lh-body-lede{font-family:var(--stoa-sans);font-weight:400;font-size:var(--t-body);line-height:1.6;color:var(--stoa-ink);margin:0;max-width:68ch}
main.bfy > .lh-body-lede{margin:0 0 28px}

/* R275 (Jake, Nov 2 2026, option B): split heroes. Only the eyebrow, an R230 line set in the hero, the h1 and the gold rule stay on the
   image; the tagline, the dek and the CTA row sit under it in .lh-under, on the page ground in the page's own theme, type styles unchanged.
   Desktop: the section is a two-row grid, the plate fills the first row only; the hero is about min(48vh, 440px). Phone: the plate at 3:2. */
.lhero > .wrap.lh-under{display:block;min-height:0;padding-top:28px;padding-bottom:8px}
.lhero .lh-under .tagline{font-family:var(--stoa-serif);font-weight:400;font-size:var(--t-h2);line-height:1.2;margin:0 0 22px;color:var(--stoa-ink)}
.lhero .lh-under .lh-dek{font-family:var(--stoa-sans);font-weight:400;font-size:var(--t-body);line-height:1.55;color:var(--stoa-ink);margin:0 0 22px;max-width:68ch}
.lhero .lh-under > :last-child{margin-bottom:0}
@media (min-width:1025px){
  .lhero:has(> .lh-under){display:grid;grid-template-columns:minmax(0,1fr)}
  .lhero:has(> .lh-under) > .lhero-media{position:relative;inset:auto;grid-area:1/1;contain:size}   /* the plate never sizes the row; the text block does */
  .lhero:has(> .lh-under) > .wrap:not(.lh-under){grid-area:1/1;min-height:min(60vh,max(min(48vh,440px),var(--lh-k,30vw)))}   /* R275's 60% cap; --lh-k keeps the registered subject whole as the plate scales with the width (Cowork's triage, Nov 4) */
  .lhero:has(> .lh-under) > .lh-under{grid-area:2/1}
}
@media (min-width:601px) and (max-width:1100px){.lhero .lh-under .tagline{font-size:19px;margin:0 0 16px}}
/* R288 (Jake, Nov 3 2026): the hero text column on every hero page, now that the dek has left the hero */
@media (min-width:1025px){.lhero .hero-text,.lhero--built-for-you .hero-text{max-width:min(640px,50%)}}
.lhero--record,.lhero--lookout{--lh-k:33.75vw}
.lhero--guides{--lh-k:32vw}
.lhero--built-for-you{--lh-k:37vw}
@media (max-width:1279px){.lhero--built-for-you{--lh-k:40vw}}
@media (min-width:1280px) and (max-width:1366px){.lhero--built-for-you > .wrap:not(.lh-under){padding-top:calc(var(--lh-head,72px) + 12px)}}
@media (max-width:600px){
  .lhero:has(> .lh-under) > .lhero-media{aspect-ratio:3/2}
  .lhero > .wrap:has(+ .lh-under){padding-bottom:0}
  .lhero > .wrap.lh-under{padding-top:0;padding-bottom:36px}
}

/* R293 (Jake, Nov 5 2026): on desktop the whole hero text block sits on the image again. The plate spans both rows; the tagline, the dek
   and the CTA row follow the gold rule in the plate's fixed light ink. No scrim. Phone (600 px and down) unchanged from R275. */
@media (min-width:1025px){
  .lhero > .lh-under{--stoa-ink:#20211f;--stoa-muted:#5e6070;--stoa-base:#f5f5f8;--stoa-surface:#fcfcfe;--stoa-rule:#20211f;--stoa-hair:#dcdde6;--stoa-sea-t:#3a6878}
  .lhero:has(> .lh-under){grid-template-rows:auto 1fr;min-height:var(--r293-h,max(min(70vh,680px),var(--lh-k,30vw)))}
  .lhero:has(> .lh-under) > .lhero-media{grid-area:1/1/3/2}
  .lhero:has(> .lh-under) > .wrap:not(.lh-under){min-height:0;padding-bottom:0}
  .lhero:has(> .lh-under) > .lh-under{grid-area:2/1;position:relative;z-index:1;padding-top:0;padding-bottom:var(--space-block)}
  .lhero > .lh-under > *{max-width:min(640px,50%)}
}

/* R299 (Jake, Nov 5 2026): on desktop the hero text sits in the sky and the CTA row on the water. The desktop height floor is 680 px for every
   page (no vh term). Phone unchanged. */
@media (min-width:1025px){
  .lhero:has(> .lh-under){min-height:var(--r293-h,max(680px,var(--lh-k,30vw)))}
  .lhero--jake{container-type:inline-size}
  .lhero--jake:has(> .lh-under) > .lh-under{position:static}   /* outranks R293's positioned under-block, so the row is placed against the hero */
  .lhero--jake > .lh-under > *{position:relative;z-index:1}
  .lhero--jake .lhero-cta{position:absolute;z-index:2;margin:0;top:calc((100% - max(100%, 100cqw * 0.4240)) * 0.70 + max(100%, 100cqw * 0.4240) * 0.6510 + 20px)}   /* on the water band: the horizon plus 20 px */
}
/* /marketplace: the water band is under the row plus 24 px at most widths (51 to 68 px), so the row stays in the sky under the text (rule 2);
   from 1800 to 2200 px the band reaches 77 px and the row sits on it, the horizon plus 14 px */
@media (min-width:1800px) and (max-width:2200px){
  .lhero--marketplace{container-type:inline-size}
  .lhero--marketplace:has(> .lh-under) > .lh-under{position:static}
  .lhero--marketplace > .lh-under > *{position:relative;z-index:1}
  .lhero--marketplace .lhero-cta{position:absolute;z-index:2;margin:0;top:calc((100% - max(100%, 100cqw * 0.4240)) * 0.75 + max(100%, 100cqw * 0.4240) * 0.7334 + 14px)}
}

/* R301 (Jake, Nov 6 2026): from 601 to 1024 px the hero takes the phone layout, the plate as a clean 3:2 band and the text on the page
   ground under it (the desktop hero rules start at 1025 px). The 601 to 1100 type sizes are unchanged. */
@media (min-width:601px) and (max-width:1024px){
  .lhero{overflow:visible}
  .lhero{--r301-band:min(100vw * 2 / 3, 52vh, 440px)}
  .lhero > .lhero-media{position:static;width:100%;height:var(--r301-band);aspect-ratio:auto;margin-top:var(--lh-head,72px)}
  .lhero-media img{object-position:100% clamp(calc(var(--r301-band) - max(var(--r301-band), 100vw * 0.4243)), calc(var(--r301-band) / 2 - var(--r301-c,0.5) * max(var(--r301-band), 100vw * 0.4243)), 0px)}   /* the band capped (Cowork, 7:03 PM): the subject's centre at the band's centre, never past the image */
  .lhero .wrap{display:block;min-height:0;padding-top:28px;padding-bottom:36px}
  .lhero > .wrap:has(+ .lh-under){padding-bottom:0}
  .lhero > .wrap.lh-under{padding-top:0;padding-bottom:36px}
  .lhero .hero-text{max-width:none}
}
/* R301: from 1025 px up every hero is the home hero's height at that width (R300). The plate keeps the box R299 gave it (never under the
   hero) and the hero is cropped from the bottom, so the sky, the text, the horizon and the CTA do not move. */
@media (min-width:1025px){
  .lhero[class*="lhero--"]:has(> .lh-under){--r301-r:max(808px, 100vw * 0.4297);--r301-h:calc(72px + (808px - var(--r301-r)) * 0.10 + var(--r301-r) * 0.5006 + 180px);--r301-b:max(max(680px, var(--lh-k,30vw)), var(--r301-h));
    --r301-pr:max(var(--r301-b), 100vw * 0.4243);
    --r301-d:clamp(0px, (var(--r301-b) - var(--r301-pr)) * var(--r301-py,0.5) + var(--r301-pr) * var(--r301-y1,0) - var(--r301-h) + 2px, var(--r301-b) - var(--r301-h));
    min-height:0;height:var(--r301-h);overflow:hidden}   /* every hero page but The Letters, which carries its own rules (R301 step 4) */
  .lhero[class*="lhero--"]:has(> .lh-under) > .lhero-media{position:absolute;top:calc(-1 * var(--r301-d));left:0;right:0;bottom:auto;height:var(--r301-b);grid-area:auto;z-index:0}
  .lhero--jake .lhero-cta{top:calc((var(--r301-b) - max(var(--r301-b), 100cqw * 0.4240)) * 0.70 + max(var(--r301-b), 100cqw * 0.4240) * 0.6510 + 20px - var(--r301-d))}
}
@media (min-width:1800px) and (max-width:2200px){
  .lhero--marketplace .lhero-cta{top:calc((var(--r301-b) - max(var(--r301-b), 100cqw * 0.4240)) * 0.75 + max(var(--r301-b), 100cqw * 0.4240) * 0.7334 + 14px - var(--r301-d))}
}

/* R303 (Jake, Nov 7 2026): no hero image under the header. From 1024 px down the plate starts at the header's bottom edge (73 px, or the
   fixed subnav's on /record/ and the Lookout pages); the bands keep their ruled sizes. Desktop unchanged. */
@media (max-width:1024px){.lhero > .lhero-media{margin-top:var(--r303-head,73px)}}
@media (max-width:600px){.lhero--built-for-you > .lhero-media,.lhero--marketplace > .lhero-media{margin-top:0}}   /* the text sits above the plate on phones */

/* R307 (Jake, Nov 7 2026): on phones /marketplace and /built-for-you/ lead with the image, as every hero page does: the plate first, below
   the header (R303), then the hero text and the CTA row on the page ground. Outranks the earlier text-first order in styles.css. */
@media (max-width:600px){
  .lhero.lhero--built-for-you > .wrap{order:0}
  .lhero.lhero--built-for-you > .wrap:not(.lh-under),.lhero.lhero--marketplace > .wrap:not(.lh-under){padding-top:28px}
  .lhero.lhero--built-for-you > .lhero-media{margin-top:73px}
  .lhero.lhero--marketplace > .lhero-media{order:-5;margin-top:73px}
}
