/* /for, Who It Helps (NEW-649; round two, plan 2026-11-10-1350 U20, signed spec round-two/specs/audience.md part A).
   The shared open hero (sections.css section 0) over the light morning-stoop still, five cards in one row, one
   navy close. v12 tokens only. Build three U24 adds the sixth card and, from section 4, the For AI Agents page
   (/for/agents, class prefix fa-). */

/* ---------- 1. the open hero, light tone ----------
   The still is light (focus record tone "light", settle #f8d6ad), so every word in the column is ink, on this page
   only: the headline and the quiet link in ink, the sentence in ink-2, no glow under it. sections.css already turns
   a light-tone block's color to ink; these rules name each element so a later site-wide rule cannot light them. */
.sx-hero.for-hero[data-tone="light"] .sx-hero__col > h1 { color: var(--ink); }
.sx-hero.for-hero[data-tone="light"] .sx-hero__sentence { color: var(--ink-2); text-shadow: none; }
.sx-hero.for-hero[data-tone="light"] .sx-hero__col .doors .tcta { color: var(--ink); }

/* ---------- 1b. the front-door hero's five painted doors (specs/hero-arrival.md, unit D) ----------
   Dan, 2026-11-11: "I want to move back to where we lost, the uwees the 5 doors with their buttons". Each door is a link
   (lib/site/pages/for.ts doorLinks), a child of the picture box (.ah__frame, arrive.css), placed by the record's door box
   in percent of the picture: --fd-w* wide, --fd-t* tall, so it stays on its painted door at every size and in both
   modes. Wide mode: a small name tag, clear of the handle and of Biscuit; it lifts 2px with an outline on hover (the
   first build's tag, 29d9d2b94; build five makes it a brass placard above the door, below). Tall mode: the door is still a link, no tag (a door
   is about 60px wide on a phone). In the play state the doors hide with the words and rise with them. */
/* Build nine close: the layer that holds the doors covers the whole picture, the hero's two buttons included, so a click
   on "Let's Talk" landed on this layer and went nowhere (found by the rendered check, measured at five screen sizes).
   The layer lets clicks through; each door still takes its own. */
.for-doors { position: absolute; inset: 0; pointer-events: none; }
.for-door { pointer-events: auto; }
.for-door { position: absolute; left: var(--fd-wx); top: var(--fd-wy); width: var(--fd-ww); height: var(--fd-wh); display: block; color: var(--ink); text-decoration: none; container-type: inline-size; }
/* Build five U4 (Sarah, thread On8E_oBJL6Gi: "Let's make them appear on a brass placard on the door, or sitting above
   the door"): the name tag is a small brass placard on the wall just above its door, no longer a white rounded pill.
   Brass from the amber tokens (--amber-hi to --amber), squared corners, a thin bevel from light and dark inset edges,
   two screw heads, and ink lettering with a light lip under it so it reads as engraved. No brown (Sarah's rule 5). */
.for-door__tag {
  /* Build six part two R3a (Sarah, the five placard threads): the placard clears the painted stone arch above its
     door (the record's box is the door leaf; the arch rises about a fifteenth of the door's width over it) with a
     little wall showing between, tracked in the door's own width so it holds at every size. */
  /* Build eight P3 (Sarah CJJe-N0xHi49: "The brass placards need to be shifted up above the door frame ... let's be
     consistent about placard sizing, regardless of how much copy is on them"): the plate sat on the arch's keystone, which
     rises about 13cqw over the door leaf at its crown, so it now clears the keystone too, with wall showing between. Every
     plate is one size: one width, set by the door and never by the words (wide enough for the longest title, "For
     E-commerce Brands", on one line), and one line tall. "For" and the name are two spans (for.ts doorName); here they run
     as one line. */
  /* Build nine (Sarah I3e_wWOBTtC6: "shift the placards up 2x the height they currently sit above the door frame"): the
     plate sat 10px + 2cqw over the keystone (15cqw + 10px over the leaf, the keystone at about 13cqw); it moves up by twice
     that, so 30px + 6cqw now shows between the keystone and the plate. Wide mode only; the phone plates are unchanged. */
  position: absolute; left: 50%; bottom: calc(100% + 30px + 19cqw); transform: translateX(-50%);
  box-sizing: border-box; width: calc(116cqw + 28px); max-width: none; text-align: center; white-space: nowrap;
  padding: 5px 14px; border-radius: 2px; color: var(--ink);
  background:
    radial-gradient(circle at 6px 50%, rgba(17, 22, 39, .45) 0 1.5px, transparent 2px),
    radial-gradient(circle at calc(100% - 6px) 50%, rgba(17, 22, 39, .45) 0 1.5px, transparent 2px),
    linear-gradient(180deg, var(--amber-hi) 0%, var(--amber) 100%);
  /* sized by the door's own width (its container), so the longest word line ("For E-commerce") fits the door at 1024 */
  font-family: var(--ui); font-weight: 700; font-size: clamp(.6rem, 9.6cqw, .95rem); line-height: 1.2; letter-spacing: .02em;
  text-shadow: 0 1px 0 rgba(255, 255, 255, .55);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, .7), inset 0 -1px 0 rgba(17, 22, 39, .3), 0 1px 0 rgba(17, 22, 39, .25), 0 3px 8px rgba(17, 22, 39, .22);
  outline: 2px solid transparent; outline-offset: 2px;
  transition: transform .18s ease, outline-color .18s ease;
}
.for-door:hover .for-door__tag { transform: translate(-50%, -2px); outline-color: var(--ink); }
/* R3a: a hyphenated word ("E-commerce") stays whole on the placard at every size, never "E- / commerce" */
.for-door__word { white-space: nowrap; }
@media (max-width: 860px), (max-aspect-ratio: 6/5) {
  .for-door { left: var(--fd-tx); top: var(--fd-ty); width: var(--fd-tw); height: var(--fd-th); }
  /* Build six part two R3a (Q21, phone-only styling): each door keeps a small brass plate above its arch, the
     audience's name without its "For" (the cards below carry the whole title), no screw heads at this size. */
  /* Build eight P3 (Sarah CJJe-N0xHi49: "you can make them two-lines in height to narrow the placards themselves, but let's be
     consistent"): every phone plate is one size, the door's width plus 4px and two lines tall, its words centered in it,
     whether the name takes one line ("Agencies") or two ("E-commerce / Brands"). */
  .for-door__tag {
    bottom: calc(100% + 8px); width: calc(100% + 4px); max-width: none; padding: 3px 2px; white-space: normal;
    display: grid; align-content: center; min-height: calc(2 * 1.15em + 6px);
    background: linear-gradient(180deg, var(--amber-hi) 0%, var(--amber) 100%);
    font-size: clamp(.5rem, 15.4cqw, .8rem); line-height: 1.15; letter-spacing: 0; /* the floor is .5rem so "E-commerce" (never broken) fits a 320px phone's plate */
  }
  .for-door__for { display: none; }
  /* the outer two doors run to the picture's edges on a phone: their plates sit inside the door, not centered on it */
  .for-door:first-child .for-door__tag, .for-door:first-child:hover .for-door__tag { left: 0; transform: none; }
  .for-door:last-child .for-door__tag, .for-door:last-child:hover .for-door__tag { left: auto; right: 2px; transform: none; }
}
/* Build six part two FIX-2 (Sarah: the placards crowd the hero's Let's Talk on a short screen). The record's words pocket
   runs down over the placards, and arrive.css centres the words in it, so on a short wide screen the buttons settle
   onto the placards. On this hero only (the one with painted doors), wide mode, up to 960 tall: the words sit at the
   pocket's top. Taller screens keep the centred words, which already clear the placards (about 60px at 1920x1080). */
@media (min-width: 861px) and (min-aspect-ratio: 6/5) and (max-height: 960px) {
  .ah:has(.for-doors) .ah__words { justify-content: flex-start; inset: 3% 6% 6%; }
}
@media (prefers-reduced-motion: reduce) {
  .for-door__tag { transition: none; }
  .for-door:hover .for-door__tag { transform: translateX(-50%); }
}
@media (prefers-reduced-motion: no-preference) {
  .ah[data-play] .for-doors { opacity: 0; visibility: hidden; }
  .ah[data-play="rise"] .for-doors { opacity: 1; visibility: visible; transition: opacity .9s ease; }
}

/* ---------- 2. the six audiences ----------
   Build three U24 (spec for-agents.md part B): the five doors and For AI Agents in one grid. Three across in two rows
   at 1100 px and up; two across from 861 to 1099 px; one column of picture-left rows under 861 px. Equal heights; the whole
   card opens its page and lifts (kit.css .kit-lift on the li; its ::after is the li's, the link's ::after is the
   card-wide hit area, so the two never meet). */
.for-grid { list-style: none; padding: 0; margin: 0; display: grid; gap: 16px; grid-template-columns: repeat(2, minmax(0, 1fr)); }
@media (max-width: 860px) {
  .for-grid { grid-template-columns: minmax(0, 1fr); }
}
@media (min-width: 1100px) {
  .for-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 20px; }
}
.for-card { position: relative; display: grid; gap: 10px; align-content: start; min-width: 0; }
/* build six G3-U2: the card titles are h2 (one level under the h1, the cards band has no heading of its own), styled
   as the h3 they were (site.css h3), like the footer's column titles (site.css SWEEP) */
.for-card h2 { margin: 0; font-family: var(--head); font-weight: 700; font-size: 1.3rem; line-height: 1.2; letter-spacing: normal; text-wrap: wrap; }
.for-card h2 a { color: inherit; text-decoration: underline; text-decoration-thickness: 1px; text-underline-offset: 3px; }
/* the whole card opens the audience page; the link stays the one focus stop */
.for-card h2 a::after { content: ""; position: absolute; inset: 0; border-radius: inherit; }
.for-card:hover h2 a { text-decoration-thickness: 2px; }
.for-card:focus-within { outline: 3px solid var(--amber); outline-offset: 2px; }
.for-card p { margin: 0; }
@media (max-width: 860px) {
  .for-card { grid-template-columns: 40% minmax(0, 1fr); column-gap: 14px; row-gap: 6px; align-content: center; }
  .for-card .for-art { grid-row: 1 / span 2; align-self: center; }
  .for-card h2 { font-size: 1.15rem; align-self: end; }
  .for-card p { align-self: start; }
}

/* page art (KTD15): one picture on top of each card */
.for-art { margin: 0; overflow: hidden; border-radius: var(--radius-sm); background: var(--navy); aspect-ratio: 3 / 2; }
.for-art img { display: block; width: 100%; height: 100%; object-fit: cover; }

/* ---------- 4. For AI Agents (/for/agents; build three U24, spec for-agents.md part A) ----------
   The open hero (sections.css), then dated source cards, a two-column table that folds on phones, three record facts,
   the tools band, the questions and four text links. */

/* the hero still is light (focus record tone "light"): every word in the column in ink, as section 1 does for /for */
.sx-hero.fa-hero[data-tone="light"] .sx-hero__col > h1 { color: var(--ink); }
.sx-hero.fa-hero[data-tone="light"] .sx-hero__sentence { color: var(--ink-2); text-shadow: none; }
.sx-hero.fa-hero[data-tone="light"] .sx-hero__col .doors .tcta { color: var(--ink); }

/* a source card: the claim set large, its source line in mono, the outbound link last */
.fa-src { display: grid; gap: 12px; align-content: start; height: 100%; box-sizing: border-box; padding: clamp(20px, 2.4vw, 28px); border-radius: var(--radius); background: var(--card); box-shadow: inset 0 0 0 1px var(--rule); }
.fa-src__tag { justify-self: start; margin: 0; padding: 3px 10px; border-radius: 999px; background: var(--butter); color: var(--ink); font-family: var(--ui); font-size: .78rem; font-weight: 700; letter-spacing: .02em; }
.fa-src__text { margin: 0; font-family: var(--head); font-weight: 700; font-size: clamp(1.15rem, 1.6vw, 1.4rem); line-height: 1.3; color: var(--fg); }
.fa-src__line { margin: 10px 0 0; font-family: var(--mono); font-size: .8rem; line-height: 1.45; color: var(--muted); }
.fa-src__more { margin: 0; align-self: end; }

/* the shift: two by two from 861 px, one column under it */
.fa-shift .kit-build__list { grid-template-columns: minmax(0, 1fr); gap: 16px; }
.fa-shift .kit-build__step { display: grid; }
@media (min-width: 861px) {
  .fa-shift .kit-build__list { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 20px; }
}

/* the honest part: the words, then the card beside what follows from it */
.fa-honest__grid { display: grid; gap: clamp(20px, 3vw, 36px); }
.fa-honest__words h2, .fa-honest__words .lede { margin-top: 0; }
.fa-honest__then { display: grid; gap: 14px; align-content: start; }
.fa-honest__then p { margin: 0; }
.fa-honest__pull { font-family: var(--head); font-weight: 700; font-size: clamp(1.25rem, 2vw, 1.6rem); line-height: 1.25; }
@media (min-width: 861px) {
  .fa-honest__grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .fa-honest__words { grid-column: 1 / -1; }
}

/* readable to an agent: the table takes the full text width (two columns, so no full-width rule needed; it fills the wrap) */
.fa-legible .kit-build__table th[scope="row"] { width: 34%; padding: 14px 16px; font-family: var(--ui); font-weight: 700; vertical-align: top; background: var(--card); border-radius: var(--radius-sm) 0 0 var(--radius-sm); }
.fa-legible .kit-build__table td { padding: 14px 16px; vertical-align: top; background: var(--card); border-radius: 0 var(--radius-sm) var(--radius-sm) 0; }
.fa-legible .kit-build__table thead th { padding: 0 16px; }
.fa-more-link, .fa-links { margin: clamp(16px, 2vw, 24px) 0 0; }
.fa-links { display: flex; flex-wrap: wrap; gap: 10px 24px; }
@media (max-width: 639px) {
  .fa-legible .kit-build__table thead { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); }
  .fa-legible .kit-build__table tr { display: grid; }
  .fa-legible .kit-build__table th[scope="row"] { width: auto; border-radius: var(--radius-sm) var(--radius-sm) 0 0; padding-bottom: 4px; }
  .fa-legible .kit-build__table td { border-radius: 0 0 var(--radius-sm) var(--radius-sm); padding-top: 4px; }
}

/* the record: three facts, one per row, a rule between */
.fa-facts { list-style: none; margin: 0; padding: 0; display: grid; gap: 0; max-width: 72ch; }
.fa-facts li { padding: 16px 0; border-top: 1px solid var(--rule); }
.fa-facts li:last-child { border-bottom: 1px solid var(--rule); }

/* the tools: the words beside the protocol card */
.fa-tools__grid { display: grid; gap: clamp(20px, 3vw, 40px); align-items: start; }
.fa-tools__words p { margin: 0 0 12px; }
.fa-tools__words h2 { margin-top: 0; }
.fa-tools__not { font-weight: 600; }
.fa-tools__card .label { margin: 0 0 10px; }
@media (min-width: 861px) {
  .fa-tools__grid { grid-template-columns: minmax(0, 1.1fr) minmax(0, 1fr); }
}

/* other ways in: four text links that lift */
.fa-more__links { list-style: none; margin: 0; padding: 0; display: grid; gap: 12px; grid-template-columns: repeat(2, minmax(0, 1fr)); }
.fa-more__links li { padding: 16px 18px; border-radius: var(--radius-sm); background: var(--card); }
@media (min-width: 861px) {
  .fa-more__links { grid-template-columns: repeat(4, minmax(0, 1fr)); }
}

/* ---------- build five U5a (Sarah S9JdwDBfn0DX): a crew member beside the words of two bands below the fold ----------
   The shared host figure (sections.ts hostBeside: bubble, cut-out, title; the bubble and title take the sitewide
   treatment). Words left and the figure right from 861px; on a phone the figure follows the words, smaller. */
.fa-shift .sx-beside, .fa-record .sx-beside { display: grid; gap: clamp(16px, 3vw, 40px); align-items: center; }
.fa-shift .sx-beside { margin-bottom: clamp(16px, 2.4vw, 28px); }
.fa-shift .sx-beside .section-head, .fa-record .sx-beside .section-head { margin-bottom: 0; }
.fa-record .sx-beside .section-head { margin-bottom: clamp(16px, 2vw, 24px); }
.fa-shift .sx-host__uwee, .fa-record .sx-host__uwee { width: clamp(140px, 15vw, 210px); }
@media (min-width: 861px) {
  .fa-shift .sx-beside, .fa-record .sx-beside { grid-template-columns: minmax(0, 1fr) minmax(200px, 300px); }
}
@media (max-width: 860px) {
  .fa-shift .sx-host, .fa-record .sx-host { justify-self: center; }
  .fa-shift .sx-host__uwee, .fa-record .sx-host__uwee { width: min(150px, 44vw); }
}

/* Build six part two FIX-9 (walk audA, item 8): the Who It Helps bar (subnav.css) ran wider than the page from 1024 to
   1179px and cut a label at each end ("ommerce Brands", "For Individua"). On the seven /for pages, which load either
   pages/audience-pages.css or for.css (the same rule sits in both), the bar's links tighten there so all seven fit beside the name:
   less side padding and no gap from 1120, and a 13px label from 1024. Below 1024 the bar keeps its fade and scroll.
   The current page's underline follows the new padding. Scoped to this bar by its own link: no other bar changes. */
@media (min-width: 1024px) and (max-width: 1179px) {
  .subnav:not([data-grouped]):has(.subnav__link[href="/for/agents"]) .subnav__list { gap: 0; }
  .subnav:not([data-grouped]):has(.subnav__link[href="/for/agents"]) .subnav__list .subnav__link { padding-inline: 8px; }
  .subnav:not([data-grouped]):has(.subnav__link[href="/for/agents"]) .subnav__list .subnav__link[aria-current="page"]::after { left: 8px; right: 8px; }
}
@media (min-width: 1024px) and (max-width: 1119px) {
  .subnav:not([data-grouped]):has(.subnav__link[href="/for/agents"]) .subnav__list .subnav__link { padding-inline: 7px; font-size: 13px; }
  .subnav:not([data-grouped]):has(.subnav__link[href="/for/agents"]) .subnav__list .subnav__link[aria-current="page"]::after { left: 7px; right: 7px; }
}
