/* hero.css (founder review 3): ink end to end. Left, work arriving from twelve channels; right, the six tools it lands on (real DOM, svg/tool-art.mjs). Prefix .hero__* only.
   The cinematic layer (html.js:not(.fx-fail):not(.static)) only adds tilt, entry and idle life; work chips and composed frames draw over this DOM.
   HAND-OFF (hero to #offer): .hero__trunk leaves the bottom edge at x = section width minus 0.7 of #offer's gutter; #offer's rail (offer.mjs) shares that x and nothing else. */

#hero { --wall-w: min(40vw, 580px, calc(2 * ((80svh - 28px) * .3913 + 10px))); --wall-r: calc(var(--gutter) + 40px); --lane-top: clamp(92px, 12svh, 132px);   /* never above 92: the nav pill ends at 72 and a card kicked upward needs room */ --lane-pitch: clamp(19px, 2.9svh, 28px); --legend-head-h: 22px; }
#hero picture { position: static; z-index: auto; }   /* the foundation lifts every stage child; the still positions against the stage */
#hero .stage { display: flex; flex-direction: column; justify-content: flex-end; align-items: flex-start; padding: 0 var(--gutter) clamp(26px, 6svh, 62px); }
:is(html:not(.js), html.static, html.fx-fail) #hero .stage { position: relative; overflow: clip; min-height: max(100svh, 40rem); padding-top: clamp(104px, 16svh, 168px); }

/* copy */
.hero__copy { position: relative; z-index: 4; width: min(46vw, 44rem); container-type: inline-size; }
.hero__eyebrow { margin: 0 0 1.1rem; max-width: 46ch; color: rgb(241 236 224 / .9); }   /* brighter than the muted token: it reads over the dust */
/* The soft scrim quiets the particles under the copy and fades back into the field around it. */
html.js:not(.fx-fail):not(.static) .hero__copy::before { content: ""; position: absolute; z-index: -1; pointer-events: none; inset: -2.2rem -1rem -2.4rem -6rem; background: rgb(11 12 15 / .6); filter: blur(26px); border-radius: 2rem; }
.hero__h1 { font-family: var(--font-display); font-size: min(clamp(3.2rem, 7.4vw, 7rem), 14.2cqw); font-weight: 560; letter-spacing: -.045em; line-height: .9; white-space: nowrap; margin: 0; }
.hero__line { display: block; }
.hero__sub { max-width: 56ch; margin: 1.6rem 0 0; font-size: clamp(1.125rem, 1.35vw, 1.5rem); line-height: 1.4; font-weight: 460; color: var(--fg); }
.hero__cta { display: flex; flex-wrap: wrap; align-items: center; gap: .9rem 1.5rem; margin-top: 2rem; }
.hero__free { display: inline-flex; align-items: center; gap: .55rem; font-family: var(--font-mono); font-size: var(--t-data); letter-spacing: .1em; text-transform: uppercase; white-space: nowrap; }
.hero__free i { width: 7px; height: 7px; background: var(--signal); clip-path: polygon(50% 0, 100% 50%, 50% 100%, 0 50%); flex: none; }
.hero__link { color: var(--fg); }

/* the legend: "Where work comes in" over the twelve intake types, two columns of six, each with the glyph its chips carry */
.hero__legend { position: absolute; z-index: 4; left: var(--gutter); top: var(--lane-top); pointer-events: none; }
.hero__legend-head { height: var(--legend-head-h); margin: 0; font-family: var(--font-mono); font-size: 11.5px; font-weight: 600; letter-spacing: .16em; line-height: 1.2; text-transform: uppercase; color: var(--signal-l, #8290FF); white-space: nowrap; }
.hero__lanes { display: grid; grid-auto-flow: column; grid-template-rows: repeat(6, var(--lane-pitch)); grid-template-columns: repeat(2, max-content); column-gap: 2.1rem; margin: 0; padding: 0; list-style: none; }
.hero__lane { position: relative; display: flex; align-items: center; gap: .6rem; height: var(--lane-pitch); overflow: clip; color: var(--on-ink-dim); }
.hero__lane-glyph { flex: none; width: 15px; height: 15px; fill: none; stroke: var(--on-ink); stroke-width: 1.6; stroke-linecap: round; stroke-linejoin: round; }
.hero__lane-label { flex: none; min-width: 4.6rem; font-family: var(--font-mono); font-size: 12.5px; font-weight: 500; letter-spacing: .12em; text-transform: uppercase; color: var(--on-ink); }   /* no ruled line: the work arrives as a crowd, not in lanes */
.hero__lane-run { display: none; }

/* the tool wall: where the work lands */
.hero__wall { position: absolute; z-index: 2; right: var(--wall-r); top: clamp(92px, 12svh, 132px); width: var(--wall-w); display: grid; grid-template-columns: 1fr 1fr; gap: 14px 16px; margin: 0; }
.hero__card { position: relative; display: flex; flex-direction: column; gap: 6px; padding: 8px 8px 7px; background: var(--bone); color: var(--on-bone); border: 1px solid var(--ink-0); border-radius: 3px; box-shadow: 0 12px 26px rgb(0 0 0 / .5); --r: 0deg; --tx: 0px; --ty: 0px; }
.hero__card-art { aspect-ratio: 240 / 150; overflow: clip; border-radius: 2px; }
.hero__card-art .ta { display: block; width: 100%; height: 100%; }
.ta text { font-family: var(--font-body); }
.hero__card-cap { display: flex; align-items: center; gap: .5rem; margin: 0; font-family: var(--font-body); font-size: clamp(.8125rem, .95vw, .9375rem); font-weight: 700; letter-spacing: -.005em; line-height: 1.2; color: var(--on-bone); }
.hero__card-cap::before { content: ""; width: 7px; height: 7px; flex: none; background: var(--signal); }
.hero__port { position: absolute; left: -6px; top: 34%; width: 11px; height: 11px; background: var(--signal); clip-path: polygon(50% 0, 100% 50%, 50% 100%, 0 50%); pointer-events: none; opacity: 0; transition: opacity .12s; }   /* the landing point only shows when work lands on it */
.hero__card.is-ping .hero__port { opacity: 1; }
.hero__trunk { display: none; }

/* mess notes: one sticky per card on the caption row (from --mess .2); the (2) badge and blue cross only in the impact phase (--impact), never at rest or in the still. */
.hero__mess { position: absolute; pointer-events: none; font-family: var(--font-mono); font-size: 11px; font-weight: 600; line-height: 1.15; color: var(--ink); }
.hero__mess[data-mess="1"] { right: 8px; bottom: 5px; padding: 3px 8px; white-space: nowrap; background: var(--kraft); box-shadow: 0 3px 8px rgb(0 0 0 / .3); opacity: clamp(0, (var(--mess, .3) - .2) * 20, 1); }
.hero__mess[data-mess="2"] { left: 12px; top: 33%; padding: 1px 7px; background: var(--kraft); letter-spacing: .02em; opacity: clamp(0, (var(--impact, 0) - .6) * 6, 1); }
.hero__mess[data-mess="3"] { right: 22px; top: 12%; width: 30px; height: 30px; opacity: clamp(0, (var(--impact, 0) - .75) * 6, 1); }
.hero__mess[data-mess="3"] svg { display: block; width: 100%; height: 100%; fill: none; stroke: var(--signal); stroke-width: 3.4; stroke-linecap: round; }

/* the still (no JS, reduced motion, fx-fail): composed frame behind, copy and the real wall at --mess .5, nothing moving */
:is(html:not(.js), html.static, html.fx-fail) #hero .composed { position: absolute; inset: 0; z-index: 0; width: 100%; height: 100%; object-fit: cover; object-position: 50% 50%; pointer-events: none; }
:is(html:not(.js), html.static, html.fx-fail) .hero__wall { --mess: .5 !important; }   /* beats the inline baseline: the static wall is always at .5 */

/* cinematic: tilt, entry and idle life (CSS only; transforms use the individual properties so motion can own `transform`) */
html.js:not(.fx-fail):not(.static) #hero .composed { opacity: 0; visibility: hidden; }
html.js:not(.fx-fail):not(.static) .hero__card { rotate: var(--r); translate: var(--tx) var(--ty); will-change: transform; }
html.js:not(.fx-fail):not(.static) .hero__card:nth-child(1) { --r: -1.8deg; --ty: 4px; }
html.js:not(.fx-fail):not(.static) .hero__card:nth-child(2) { --r: 1.6deg; --ty: -6px; --tx: 6px; }
html.js:not(.fx-fail):not(.static) .hero__card:nth-child(3) { --r: 2.4deg; --tx: -8px; }
html.js:not(.fx-fail):not(.static) .hero__card:nth-child(4) { --r: -1.3deg; --ty: 8px; --tx: 6px; }
html.js:not(.fx-fail):not(.static) .hero__card:nth-child(5) { --r: -2.5deg; --tx: 8px; --ty: -4px; }
html.js:not(.fx-fail):not(.static) .hero__card:nth-child(6) { --r: 1.9deg; --ty: 6px; --tx: -6px; }
html.js:not(.fx-fail):not(.static) .hero__mess[data-mess="1"] { rotate: -2deg; }
html.js:not(.fx-fail):not(.static) .hero__mess[data-mess="2"] { rotate: -4deg; }
html.js:not(.fx-fail):not(.static) .hero__mess[data-mess="3"] { rotate: 8deg; }
html.js:not(.fx-fail):not(.static) .hero__lane-label, html.js:not(.fx-fail):not(.static) .hero__lane-glyph { animation: hero-lane-in .5s cubic-bezier(.2, .7, .2, 1) both; animation-delay: calc(.35s + var(--i) * 60ms); }
@keyframes hero-lane-in { from { translate: -16px 0; opacity: 0; } to { translate: 0 0; opacity: 1; } }
html.js:not(.fx-fail):not(.static) .ta-caret { animation: hero-caret 1.06s steps(1, end) infinite; }
@keyframes hero-caret { 50% { opacity: 0; } }
html.js:not(.fx-fail):not(.static) .ta-dot { animation: hero-dot 2.4s ease-in-out infinite; transform-box: fill-box; transform-origin: center; }
@keyframes hero-dot { 50% { transform: scale(1.7); opacity: .55; } }
html.js:not(.fx-fail):not(.static) .ta-scrib { stroke-dasharray: 100; animation: hero-scrib 7s linear infinite; }
@keyframes hero-scrib { 0% { stroke-dashoffset: 100; } 45%, 85% { stroke-dashoffset: 0; } 100% { stroke-dashoffset: -100; } }
html.js:not(.fx-fail):not(.static) .ta-wobble { animation: hero-wobble 5s ease-in-out infinite; transform-box: fill-box; transform-origin: 50% 100%; }
@keyframes hero-wobble { 0%, 60%, 100% { transform: rotate(0); } 70% { transform: rotate(-3deg); } 80% { transform: rotate(2.4deg); } 90% { transform: rotate(-1deg); } }

/* low tier (?fx=lite and no GL): the lanes march in CSS, six <i> moving by translate3d; the wall stays still */
html.js.gl-fail:not(.static):not(.fx-fail) .hero__lane-run { display: block; position: absolute; left: -72px; right: 0; bottom: 0; height: 2px; pointer-events: none; background: repeating-linear-gradient(90deg, var(--signal) 0 12px, transparent 12px 72px); animation: hero-march 2.6s linear infinite; animation-delay: calc(var(--i) * -.4s); will-change: transform; }
@keyframes hero-march { to { transform: translate3d(72px, 0, 0); } }

html.js:not(.fx-fail):not(.static) .hero__trunk {
  display: block; position: absolute; z-index: 5; pointer-events: none; top: 14%; bottom: 0; width: 4px; right: calc(max(8px, var(--gutter) * .7) - 2px);
  background: linear-gradient(180deg, rgb(58 77 255 / 0), rgb(58 77 255 / .55) 35%, rgb(58 77 255 / .85) 80%); opacity: var(--carry, 0);
}
/* the pill's readout is quiet on the hero (the logo says it) */
.nav-pill__readout.is-hero-quiet { visibility: hidden; }

/* phone: the channel key, a band where chips arrive from the left edge, then they drop down the rail into the six tools */
@media (max-width: 900px) {
  #hero { --pcard-h: clamp(70px, 9.3svh, 92px); }
  #hero .stage { display: grid; grid-template-columns: 28px minmax(0, 1fr); column-gap: 8px; align-content: end; align-items: stretch; justify-items: stretch; padding-bottom: clamp(16px, 2.2svh, 22px); }
  :is(html:not(.js), html.static, html.fx-fail) #hero .stage { padding-top: 96px; }
  .hero__copy { display: contents; container-type: normal; width: auto; }
  .hero__eyebrow { grid-column: 1 / -1; grid-row: 1; margin-bottom: .55rem; max-width: none; }
  .hero__h1 { grid-column: 1 / -1; grid-row: 2; font-size: 13vw; }
  .hero__sub { grid-column: 1 / -1; grid-row: 3; position: relative; isolation: isolate; margin-top: .9rem; font-size: 1.0625rem; }
  .hero__legend { grid-column: 1 / -1; grid-row: 4; position: relative; left: auto; top: auto; margin-top: .55rem; }
  .hero__legend-head { height: auto; margin-bottom: 5px; font-size: 10px; letter-spacing: .1em; }
  .hero__lanes { grid-auto-flow: row; grid-template: none / repeat(4, minmax(0, 1fr)); gap: 2px 4px; padding-bottom: clamp(60px, 8.2svh, 72px); }
  .hero__lane { height: auto; gap: 4px; overflow: visible; }
  .hero__lane-label { min-width: 0; font-size: 12px; line-height: 1.15; letter-spacing: 0; }
  .hero__lane-glyph { width: 12px; height: 12px; padding: 1px; box-sizing: border-box; background: var(--signal); border-radius: 3px; stroke: #fff; stroke-width: 2.4; }
  :is(html:not(.js), html.static, html.fx-fail) .hero__lanes { padding-bottom: 0; }
  .hero__wall { grid-column: 2; grid-row: 5; position: relative; right: auto; top: auto; width: auto; margin-top: .5rem; gap: 8px; }
  .hero__card { height: var(--pcard-h); padding: 5px 5px 4px; gap: 3px; }
  .hero__card-art { position: relative; flex: 1; min-height: 0; aspect-ratio: auto; }
  /* each picture is zoomed (--z) and cropped (--cx/--cy, top-left as a share of it) to its one cue */
  .hero__card-art .ta { position: absolute; left: 0; top: 0; width: calc(var(--z) * 100%); height: auto; aspect-ratio: 240 / 150; translate: calc(var(--cx, 0) * -100%) calc(var(--cy, 0) * -100%); }
  .hero__card { --z: 1.5; }
  .hero__card[data-tool="spreadsheets"] { --cy: .08; }
  .hero__card[data-tool="erp"] { --cy: .03; }
  .hero__card[data-tool="paper"] { --cx: .2; --cy: .2; }
  .hero__card[data-tool="drives"] { --cy: .06; }
  .hero__card[data-tool="email"] { --z: 1.4; }
  .hero__card[data-tool="point"] { --cx: .02; --cy: .1; }
  .hero__card-cap { font-size: .6875rem; }
  .hero__card-cap::before { width: 5px; height: 5px; }
  .hero__port { left: -5px; top: 30%; width: 9px; height: 9px; }
  .ta-fine { display: none; }
  .hero__mess { display: none; }
  .hero__cta { grid-column: 1 / -1; grid-row: 6; position: relative; isolation: isolate; margin-top: .9rem; gap: .5rem 1.1rem; }
  html.js:not(.fx-fail):not(.static) .hero__copy::before { display: none; }   /* the phone's copy is display: contents: its scrim would fill the whole stage; the lead and CTA carry their own ink, the eyebrow gets a soft one */
  .hero__eyebrow { position: relative; isolation: isolate; }
  .hero__eyebrow::before { content: ""; position: absolute; z-index: -1; pointer-events: none; inset: -.5rem -16px -.5rem -16px; background: rgb(11 12 15 / .66); -webkit-mask-image: linear-gradient(180deg, transparent, #000 .5rem, #000 calc(100% - .5rem), transparent); mask-image: linear-gradient(180deg, transparent, #000 .5rem, #000 calc(100% - .5rem), transparent); }
  .hero__sub::before, .hero__cta::before { content: ""; position: absolute; z-index: -1; pointer-events: none; background: var(--ink); inset: -.9rem -16px -.5rem; -webkit-mask-image: linear-gradient(180deg, transparent, #000 .9rem); mask-image: linear-gradient(180deg, transparent, #000 .9rem); }
  .hero__cta::before { inset: -.4rem -16px -1.2rem; -webkit-mask-image: none; mask-image: none; }
  :is(html:not(.js), html.static, html.fx-fail) #hero .composed { object-position: 50% 100%; }
  html.js:not(.fx-fail):not(.static) .hero__card { rotate: calc(var(--r) * .5); translate: calc(var(--tx) * .4) calc(var(--ty) * .4); }
}
/* A compact viewport trades the last card row for room below the nav. */
@media (max-width: 900px) and (max-height: 780px), (max-width: 430px) and (max-height: 815px), (max-width: 374px) and (max-height: 860px) {
  html.js:not(.fx-fail):not(.static) .hero__card:nth-child(n + 5) { display: none; }
  html.js:not(.fx-fail):not(.static) #hero { --pcard-h: clamp(64px, 9.8svh, 90px); }
}
@media (max-width: 900px) and (max-height: 700px), (max-width: 359px) and (max-height: 719px) {
  html.js:not(.fx-fail):not(.static) .hero__legend { display: none; }
}
@media (max-width: 900px) and (max-height: 620px) {
  .hero__h1 { font-size: min(13vw, 14svh); }
  html.js:not(.fx-fail):not(.static) .hero__legend, html.js:not(.fx-fail):not(.static) .hero__wall { display: none; }
}

/* a short desktop keeps the wall inside the stage */
@media (min-width: 901px) and (max-height: 640px) { .hero__legend, .hero__wall { top: 92px; } }

@media (max-width: 359px) {
  .hero__lanes { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  html.js:not(.fx-fail):not(.static) #hero { --pcard-h: clamp(61px, 9.3svh, 86px); }
}

/* Short phones need room below the header even when the six-card layout comes back. */
@media (max-width: 520px) {
  .hero__lanes { padding-bottom: min(clamp(60px, 8.2svh, 72px), max(16px, calc(100svh - 786px))); }
}
@media (max-width: 430px) and (max-height: 800px) {
  .hero__sub { margin-top: .65rem; }
  .hero__cta { gap: .35rem .5rem; }
  .hero__free { gap: .35rem; font-size: .625rem; letter-spacing: .075em; }
  .hero__link { font-size: .875rem; }
}

@media (min-width: 521px) and (max-width: 900px) and (min-height: 621px) and (max-height: 910px) {
  .hero__h1 { font-size: min(13vw, 11svh); }
  .hero__lanes { padding-bottom: clamp(12px, calc(100svh - 800px), 72px); }
}

/* In very short landscape viewports the copy can scroll past the header. */
@media (max-width: 1024px) and (max-height: 374px) {
  html.js:not(.fx-fail):not(.static) #hero .track { height: auto; }
  html.js:not(.fx-fail):not(.static) #hero .track > .stage { position: relative; height: auto; min-height: 100svh; padding-block: 88px 16px; }
  html.js:not(.fx-fail):not(.static) :is(.hero__legend, .hero__wall) { display: none; }
  .hero__copy { width: 100%; }
  .hero__h1 { font-size: min(13vw, 14svh); }
}

@media print { .hero__legend, .hero__trunk { display: none !important; } }
