/* Visibility (/what-jinn-can-do/visibility), on top of the feature kit's sheet (feature.css). Round two (plan U15)
   built the page from kit parts only, so the run, answer card, fix card and ask table rules left with them. The file
   stays in the stylesheet list because the five Visibility sub-pages copy this page's list (feature-sub-page.ts);
   any rule here sits under a `vis-` class only one page prints (build six G1-U5 adds two sub-page figures below). */

/* Round two (U15), first-screen check at 861: the four-line hero sentence pushes the wrapped "Watch it work" link
   1px past the hero's open box (focus record open [0,8,50,92]). A tighter gap between the two door rows keeps it
   inside. The five sub-pages share this sheet and the body's data-product, and their open hero prints `.sx-hero` too
   (at the sub size, `.sx-hero--sub`), so the rule keys on `.sx-hero--full`: the full-size hero only this page prints. */
@media (min-width: 861px) and (max-width: 1023px) {
  [data-product="ai-visibility"] .sx-hero--full .sx-hero__col > .doors { row-gap: 6px; }
}

/* Build five (Sarah, tm_mVO46cq-O): the research band's own title and lede above the study card. */
.vis-study .fp-head { margin-bottom: clamp(24px, 3vw, 40px); }

/* Build six G1-U5: the two sub-page figures. Each keys on a `vis-` class only its own sub-page prints (the parent page
   prints neither), and each is aria-hidden: its facts stay in the text beside it. */

/* /why #study (navy): the Rate column as one bar per engine (the kit's bar, kit.css), in table order, the whole track
   standing for 100%, no axis; the table under it stays the text and carries the counts. Neutral fill, no accent: the
   bars rank nothing the table does not. One value column for all six, so every track starts and ends level. */
.vis-rates { display: grid; gap: 12px; max-width: 720px; margin: 8px 0 4px; }
.vis-rates .kit-bar__label { font-size: .92rem; line-height: 1.35; color: var(--fg); }
.vis-rates .kit-bar__value { color: var(--fg); }
.vis-rates .kit-bar__track { height: 12px; }
@media (min-width: 721px) { .vis-rates .kit-bar { grid-template-columns: minmax(0, 1.2fr) minmax(72px, 2fr) 3rem; } .vis-rates .kit-bar__value { text-align: right; } }

/* /features #measure: the Brand IQ row's six scores as a staircase rising left to right, the research page's ladder
   (`.rd-ladder`, research-doc.css, which sub-pages do not load) copied here without its keeper. The riser holds the
   score, the tread the row's own phrase; the top step is the one accent. Phones turn it on its side: a row per score,
   a bar as long as the score out of the top score. No rule above it: the last row already ends on one. */
.vis-ladder { max-width: 960px; margin: clamp(20px, 3vw, 36px) 0 0; }
.vis-ladder__list { display: grid; grid-auto-flow: column; grid-auto-columns: minmax(0, 1fr); align-items: end; margin: 0; padding: 0; list-style: none; border-bottom: 1.5px solid var(--ink); }
.vis-ladder__step { display: flex; flex-direction: column-reverse; min-width: 0; }
.vis-ladder__step p { margin: 0 0 10px; padding-right: 14px; font-size: .9rem; line-height: 1.35; color: var(--fg); }
.vis-ladder__step p::first-letter { text-transform: uppercase; }
.vis-ladder__riser { display: block; height: calc(38px + var(--vis-score) * 30px); margin-right: 2px; padding: 6px 0 0 10px; background: var(--paper); border-top: 1.5px solid var(--ink); }
.vis-ladder__step--top .vis-ladder__riser { background: var(--amber); }
.vis-ladder .n { font-family: var(--mono, ui-monospace, monospace); font-size: .95rem; font-weight: 600; font-variant-numeric: tabular-nums; color: var(--ink); }
@media (max-width: 720px) {
  .vis-ladder__list { grid-auto-flow: row; grid-auto-columns: auto; border-bottom: 0; }
  .vis-ladder__step { display: grid; grid-template-columns: minmax(0, .85fr) minmax(0, 1.15fr); align-items: center; gap: 12px; padding: 8px 0; border-bottom: 1px solid var(--rule); }
  .vis-ladder__step p { margin: 0; padding: 0; }
  .vis-ladder__riser { display: flex; align-items: center; height: 26px; width: calc(2.1em + var(--vis-score) / var(--vis-top) * (100% - 2.1em)); margin: 0; padding: 0 0 0 8px; border-top: 0; border-left: 1.5px solid var(--ink); }
}

/* Build six part two PV (Sarah's round of 11-14). Each rule keys on an id only one page of the family prints (curl
   checked: #try, #gallery and #plans on the parent only, #four-questions on /compare only, #said on /why only). */

/* Parent #try (KN5oBcbsEpfs, "taller than necessary"): the band takes the tight padding, Biscuit's bubble runs wider
   at a smaller size so it sets in two or three lines, not four, and Biscuit stands smaller. */
#try { padding-block: clamp(36px, 5vw, 72px); }
#try .sx-host__uwee { width: min(140px, 100%); }
#try .tagline-bubble { max-width: 28ch; font-size: clamp(1.35rem, 1.9vw, 1.75rem); }
@media (min-width: 861px) { #try .sx-beside { grid-template-columns: minmax(0, 1fr) minmax(0, 440px); } }

/* Parent #watch (p3v66ySsmmzd): every panel's card carries its step's second sentence (ai-visibility.ts stepCopy). */
#watch .vis-step__more { margin: 0; font-size: 1.05rem; line-height: 1.55; color: var(--muted); }
/* FIX-8: the step cards' words keep more than one word on their last line (layout only) */
#watch .vis-step__more { text-wrap: pretty; }

/* Parent #gallery (0l1eFA3qYVj8): the lede runs the full width of the band, two or three lines shorter. */
#gallery .fp-head, #gallery .fp-head .lede { max-width: none; }

/* Parent #plans (rbUSAk5SN29k): the right column's first line sits level with "A project includes". The left column
   opens up into the grid, so the title takes the first row alone and the list's label and the right column start the
   second row together. Phones keep the one column. */
@media (min-width: 861px) {
  #plans .fp-plans__split { row-gap: 0; }
  #plans .fp-plans__main { display: contents; }
  #plans .fp-plans__main > h2 { grid-column: 1; grid-row: 1; }
  #plans .fp-plans__main > .fp-plans__head { grid-column: 1; grid-row: 2; margin-top: 0; align-self: baseline; }
  #plans .fp-plans__main > .fp-includes { grid-column: 1; grid-row: 3; }
  #plans .fp-plans__side { grid-column: 2; grid-row: 2 / span 2; align-self: baseline; }
}

/* Build eight P7 (Sarah zMiK-7-7lKSN, "a bit more breathing room between the paragraph and the CTA button"): the
   button sits further below the side column's last paragraph, at every width. */
#plans .fp-plans__side > .doors { margin-top: 28px; }

/* Build eight P7 (Sarah jmikaDQXCvw_): Fold under the /features Fix rows, his name and title, and her line beside him.
   Phones stack him over the words. `vis-fold` prints only on /what-jinn-can-do/visibility/features. */
.vis-fold { display: grid; grid-template-columns: auto minmax(0, 1fr); align-items: center; gap: clamp(16px, 2.4vw, 32px); max-width: 720px; margin: clamp(24px, 3vw, 40px) 0 0; }
.vis-fold__uwee { display: block; width: clamp(128px, 12vw, 168px); }
.vis-fold__words { display: grid; justify-items: start; gap: 12px; margin: 0; }
.vis-fold__line { font-family: var(--display, inherit); font-size: clamp(1.15rem, 1.5vw, 1.4rem); line-height: 1.35; color: var(--fg); text-wrap: pretty; max-width: 34ch; }
@media (max-width: 560px) {
  .vis-fold { grid-template-columns: minmax(0, 1fr); justify-items: center; text-align: center; }
  .vis-fold__words { justify-items: center; }
}

/* /compare #four-questions (dq51JIOd4im7): the paper card gets room inside its edges, and the last row ends on the
   card's edge, not on a rule that reads as a row cut off. */
#four-questions .dp-tablewrap { padding: clamp(16px, 2vw, 24px) clamp(18px, 2.4vw, 32px); border-radius: 12px; }
#four-questions .dp-tablewrap__uwee { right: clamp(18px, 2.4vw, 32px); }
#four-questions .dp-table tbody tr:last-child > * { border-bottom: 0; }
@media (max-width: 720px) { #four-questions .dp-table tbody tr:last-child { border-bottom: 0; } }
/* FIX-8 (post-walk): Traffic stood at 76px on the card's corner and read as a stray mark. He now stands larger on the
   card's top edge at right, feet on the edge, level with the fold's title. On a phone the title takes the full width,
   so there he stands inside the card's top right and the first row's words keep clear of him. */
#four-questions .dp-tablewrap__uwee { width: clamp(104px, 9vw, 132px); top: calc(-1 * clamp(96px, 8.4vw, 122px)); }
#four-questions .kit-fold__summary { padding-right: clamp(120px, 11vw, 150px); }
@media (max-width: 720px) {
  #four-questions .kit-fold__summary { padding-right: 0; }
  #four-questions .dp-tablewrap { padding-top: 92px; }
  #four-questions .dp-tablewrap__uwee { width: 88px; top: 6px; }
}

/* /why (Mi0Nih6JdY_v): #study and #said are both navy, back to back; a hairline at wrap width marks the seam, with the
   band's own space above and below it. */
#study + #said { padding-top: 0; }
#study + #said > .wrap { border-top: 1px solid var(--rule); padding-top: clamp(56px, 9vw, 120px); }

/* FIX-8 (post-walk, Visibility at 1024): "What Visibility covers" prints five groups. Where the kit sets them three
   across (961-1100) the second row held two and an empty cell; here the grid runs on six tracks, the first row's three
   groups take two each and the second row's two take three each, so both rows run full width. Where it sets them two
   across (561-960) the fifth group takes the whole row and lays its list in two columns. `#overview` and `#more` are
   printed by the parent page only. */
@media (min-width: 961px) and (max-width: 1100px) {
  #overview .fp-overview__grid[data-n="5"] { grid-template-columns: repeat(6, minmax(0, 1fr)); }
  #overview .fp-overview__grid[data-n="5"] > .fp-overview__group { grid-column: span 2; }
  #overview .fp-overview__grid[data-n="5"] > .fp-overview__group:nth-child(n+4) { grid-column: span 3; }
}
@media (min-width: 561px) and (max-width: 960px) {
  #overview .fp-overview__grid[data-n="5"] > .fp-overview__group:last-child { grid-column: 1 / -1; }
  #overview .fp-overview__grid[data-n="5"] > .fp-overview__group:last-child ul { columns: 2; column-gap: clamp(20px, 2.4vw, 32px); }
}
/* "Go deeper": four across from 1200 gave each card about 270px, so the fourth link ("See what AI says about your
   brand") broke onto two lines and its card sat out of line with the rest. The four keep the two-by-two they have
   from 861, where every line and link holds one line and each row's links share a baseline. */
@media (min-width: 1200px) { #more .fp-doors__list[data-n="4"] { grid-template-columns: repeat(2, minmax(0, 1fr)); } }

/* Go-live A2 (next-build "Things a visitor would notice"): /visibility/why's Wire picture after the #outcomes cards sat at
   the left of the band under a two-column card grid, so the right half stood empty on a laptop. It keeps its size
   (sub-page.css .sp-scene, 46rem at most) and is centred under the grid. Keyed on #outcomes, which only /why prints in
   this family; the Video sub-page's scene (video.css's family) is untouched. */
#outcomes .sp-scene { margin-inline: auto; }
