/* A document's blocks. Global, so a look's sheet reaches every class here; a look dresses a block through
   data-area="s-<kind>", data-tone and the template's own .display, .btn-brand, .btn-soft, --r-* and .num */
:root { --sec-gap: 96px }
@media (max-width: 699px) { :root { --sec-gap: 48px } }

/* A block sets no outer margin of its own: the list spaces them, and a toned block reads as a band */
.secs > .s + .s { margin-top: var(--sec-gap) }
.secs > .s:not([data-tone="ground"]) + .s:not([data-tone="ground"]) { margin-top: 0 }
.secs[data-area="page"] { padding-top: 56px; padding-bottom: 120px }
.secs[data-area="page"]:has(> .s[data-area="s-photo"][data-width="full"]:first-child) { padding-top: 0 }
@media (max-width: 699px) {
  .secs[data-area="page"] { padding-top: 20px; padding-bottom: 64px }
}

/* Every block is a size container: its phone layout follows its own width, in a page and a narrowed frame alike */
.s { container: s / inline-size; --s-ground: var(--ground); --s-ink: var(--ink); --s-card: var(--ground-2); --s-card-2: var(--ground-3) }
.s:not([data-tone="ground"]) { padding-block: var(--sec-gap); background: var(--s-ground); color: var(--ink) }
.s[data-tone="raised"] { --s-ground: var(--ground-2); --s-card: var(--ground); --s-card-2: var(--ground-3) }
.s[data-tone="tint"] { --s-ground: var(--tint); --s-card: var(--ground); --s-card-2: var(--ground-2) }
/* A toned block's neutrals are re-pointed in globals.css; on the band and the brand a card is an outline */
.s:is([data-tone="band"], [data-tone="brand"]) { --s-card: transparent; --s-card-2: color-mix(in oklab, var(--ink) 12%, transparent) }
.s[data-tone="band"] { --s-ground: var(--band) }
.s[data-tone="brand"] { --s-ground: var(--brand); background: var(--brand-fill) }
.s:is([data-tone="band"], [data-tone="brand"]) .s-card { box-shadow: inset 0 0 0 .5px var(--line-2) }
/* Four selectors deep, so a look that colours every .display still leaves a toned block's title in the block's ink */
.secs .s[data-tone="band"] .display, .secs .s[data-tone="brand"] .display { color: var(--ink); -webkit-text-fill-color: currentColor }
/* A soft button keeps the block's ink inside an outline, and the brand button is recoloured through the tokens it paints
   with, so a look that outlines one or moves its fill onto a pseudo-element follows */
.secs .s:is([data-tone="band"], [data-tone="brand"]) .btn-soft { --ground-2: transparent; background: transparent; box-shadow: inset 0 0 0 1px var(--line-2) }
.secs .s:is([data-tone="band"], [data-tone="brand"]) .btn-brand { --brand-fill: var(--s-ink); --brand-ink: var(--s-ground) }

.s-in {
  width: 100%; max-width: calc(var(--max) + var(--gutter) * 2); margin-inline: auto;
  padding-inline: max(var(--gutter), env(safe-area-inset-left, 0px)) max(var(--gutter), env(safe-area-inset-right, 0px));
}
/* A block on the lot or a car's page takes the page's column, and under the bar the bar's (docs/website/monitors.md, rule 10) */
.secs:is([data-okr="place:lot"], [data-okr="place:car"], [data-okr="place:all"]) { --max: var(--page-w) }
/* Beside a lot a look's band holds at 1280px, the blocks hold with it */
.secs[data-okr="place:lot"]:has(~ [data-area="lot"][data-banded]),
[data-okr-list="place:lot"]:has(~ [data-area="lot"][data-banded]) .secs { --max: 1280px }
/* Words keep the measure they read at, from under the mark: only a photo and a team take the whole column */
.secs:is([data-okr="place:lot"], [data-okr="place:car"], [data-okr="place:all"]) > .s:not([data-area="s-photo"], [data-area="s-team"]) > .s-in {
  max-width: calc(1280px + var(--gutter) * 2); margin-left: max(0px, (100% - var(--max)) / 2 - var(--gutter))
}
.s[data-width="text"] > .s-in > * { max-width: 880px }

.s-title { font-size: var(--fs-big); line-height: 1.06 }
h1.s-title { font-size: clamp(var(--fs-hero), 4.6cqi, 72px); line-height: 1 }
.s-lead { margin-top: 12px; max-width: 680px; font-size: var(--fs-body); color: var(--ink-2); text-wrap: pretty }
.s-in > :is(.s-title, .s-lead) + :not(.s-title, .s-lead) { margin-top: 40px }
.s-in > h1.s-title + :not(.s-lead), .s-in > h1.s-title + .s-lead + * { margin-top: 48px }
.s-act { justify-self: start }

/* prose: the first paragraph set large */
.s-prose h1.s-title { font-size: var(--fs-launch); line-height: .98; max-width: 18ch }
.s-prose h1.s-title + .s-lead { margin-top: 18px; font-size: var(--fs-sm); font-weight: 500 }
.s-prose > h1.s-title + .s-words, .s-prose > h1.s-title + .s-lead + .s-words { margin-top: 56px }
.s-words { display: grid; gap: 28px }
.s-words p { max-width: 680px; font-size: var(--fs-name); letter-spacing: -.02em; line-height: 1.4; color: var(--ink-2); text-wrap: pretty; white-space: pre-line }
.s-words p:first-child { max-width: none; font-size: var(--fs-big); font-weight: 500; letter-spacing: -.028em; line-height: 1.18; color: var(--ink) }

/* photo: across the block, its words on the fade into the block's ground */
.s-photo { --s-title-size: var(--fs-big); display: grid }
.s-photo:has(h1) { --s-title-size: var(--fs-launch) }
.s[data-width="full"] > .s-photo { max-width: none; padding-inline: 0 }
.s-shot { position: relative; height: clamp(260px, 40vh, 420px); overflow: hidden }
.s-photo[data-height="tall"] .s-shot { height: clamp(440px, 74vh, 760px) }
/* Inset, the photo keeps its corners and its words sit under it */
.s:not([data-width="full"]) .s-shot { border-radius: var(--r-xl) }
.s:not([data-width="full"]) .s-shot::after { content: none }
.s:not([data-width="full"]) .s-over { margin-top: 24px; padding-inline: 0 }
.s-shot img { display: block; width: 100%; height: 100%; object-fit: cover; object-position: 50% 74% }
.s-shot::after {
  content: ""; position: absolute; inset: 0;
  background: linear-gradient(to bottom, transparent 48%, color-mix(in oklab, var(--s-ground) 72%, transparent) 78%, var(--s-ground));
}
.s-photo:not(:has(.s-over)) .s-shot::after { content: none }
/* On a wide page past 5:1 a short photo grows taller with its width, to half the window, and past 2.4:1 a tall one to 74vh (rule 8) */
@media (min-width: 1632px) {
  @supports (height: 1svh) {
    @container s not (max-width: 559px) {
      .s-shot { width: 100%; height: auto; aspect-ratio: 5; min-height: clamp(260px, 40vh, 420px); max-height: 50vh }
      .s-photo[data-height="tall"] .s-shot { height: auto; aspect-ratio: 12 / 5; min-height: clamp(440px, 74vh, 760px); max-height: max(440px, 74vh) }
    }
    /* Past its file's stop or --page-span a photo is a card on the page's or its words' column or 80px or more off both, its
       words flush with it or inside (rule 8); each clamp is a step a thousand times steeper than its length */
    @supports (width: 1cqi) {
      .s-photo { --s-photo-cap: max(1280px, var(--photo-own, 99999px) * var(--photo-stretch)) }
      .s[data-area="s-photo"] { --s-photo-col: var(--max) }
      .s:not([data-width="full"]) > .s-photo { --max: calc(var(--s-photo-col) - clamp(0px, (var(--s-photo-col) - var(--s-photo-cap)) * 1000, max(var(--s-photo-col) - var(--s-photo-cap), 160px))) }
      .s[data-width="full"] > .s-photo {
        --s-photo-fit: calc(var(--page-w) - clamp(0px, (var(--page-w) - var(--s-photo-cap)) * 1000, max(var(--page-w) - var(--s-photo-cap), 160px)));
        --s-photo-card: calc(var(--s-photo-fit) - clamp(0px, (var(--s-photo-col) + 160px - var(--s-photo-fit)) * 1000, max(0px, var(--s-photo-fit) - var(--s-photo-col))));
        --s-photo-past: calc((100cqi - min(var(--s-photo-cap), var(--page-span) - 1px)) * 1000);
        --max: calc(var(--s-photo-col) - clamp(0px, var(--s-photo-past), var(--s-photo-col) - var(--s-photo-card)));
      }
      .s[data-width="full"] .s-shot { max-width: calc(100cqi - clamp(0px, var(--s-photo-past), 100cqi - var(--s-photo-card))); margin-inline: auto; border-radius: clamp(0px, var(--s-photo-past), var(--r-xl)) }
      .secs:is([data-okr^="page:"], [data-okr="place:all"], [data-okr="place:lot"]) > .s[data-width="full"][data-tone="ground"]:first-child .s-shot { margin-top: clamp(0px, var(--s-photo-past), 56px) }
      .secs:not([data-okr^="page:"], [data-okr="place:all"], [data-okr="place:lot"]) > .s[data-width="full"][data-tone="ground"]:last-child > .s-photo { padding-bottom: clamp(0px, var(--s-photo-past), 56px) }
    }
  }
}
.s-over { position: relative; display: grid; gap: 18px; margin-top: calc(var(--s-title-size) * -1.9) }
.s-over .s-title { font-size: var(--s-title-size); line-height: .98; max-width: 18ch }
.s-over .s-lead { margin-top: 0; font-size: var(--fs-sm); font-weight: 500 }
.s-over:not(:has(.s-title)) { margin-top: -64px }

/* reviews (components/pages/Reviews.tsx): the score and the link on one row over the quotes; --rev-cols widens the quotes */
.s-rev {
  display: grid; grid-template-columns: minmax(0, 1fr) auto; grid-template-areas: "score more" "quotes quotes";
  align-items: center; gap: 48px 16px; padding-top: 40px; border-top: .5px solid var(--line-2);
}
.s-rev:not(:has(.s-score)) { grid-template-areas: "more more" "quotes quotes" }
.s-score { grid-area: score; display: flex; flex-wrap: wrap; align-items: center; gap: 8px 16px }
.s-score b { font-size: var(--fs-stat); font-weight: 600; letter-spacing: -.03em; line-height: 1 }
.s-stars {
  --star: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath d='M12 3.8l2.5 5.1 5.6.8-4 4 .9 5.6L12 16.6l-5 2.7.9-5.6-4-4 5.6-.8Z'/%3E%3C/svg%3E");
  width: 100px; height: 18px;
  background: linear-gradient(to right, var(--ink) calc(var(--of) * 100%), var(--ink-3) 0);
  -webkit-mask: var(--star) 0 0 / 20px 18px repeat-x; mask: var(--star) 0 0 / 20px 18px repeat-x;
}
.s-count { font-size: var(--fs-sm); color: var(--ink-2) }
.s-more {
  grid-area: more; justify-self: start; display: inline-flex; align-items: center; gap: 6px; min-height: 44px;
  font-size: var(--fs-sm); font-weight: 600; color: var(--ink); transition: filter var(--t-quick) linear;
}
.s-more .i { width: 18px; height: 18px; color: var(--ink-2) }
@media (hover: hover) { .s-more:hover { filter: brightness(.84) } }
.s-more[data-pressed], :root:not([data-phone]) .s-more:active { filter: brightness(.7); transition: none }
.s-quotes { grid-area: quotes; display: grid; grid-template-columns: var(--rev-cols, repeat(2, minmax(0, 1fr))); gap: 56px 96px; align-items: start }
.s-quote { margin: 0 }
.s-quote blockquote { margin: 0; max-width: 560px; font-style: italic; quotes: "\201C" "\201D"; text-wrap: pretty }
/* The opening mark hangs outside the measure, so the words keep the column's edge */
.s-quote blockquote::before { content: open-quote; margin-left: -.45em }
.s-quote blockquote::after { content: close-quote }
.s-quote:first-child blockquote { font-size: var(--fs-name); letter-spacing: -.02em; line-height: 1.35 }
.s-quote figcaption { margin-top: 12px; font-size: var(--fs-sm); font-weight: 500; color: var(--ink-2) }

/* team (components/pages/People.tsx): auto-fill keeps a short team at the tile's own width from the left; outside a block
   a card takes the page's fills */
.s-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(264px, 1fr)); gap: 20px }
.s-card { display: flex; flex-direction: column; min-width: 0; padding-bottom: 24px; border-radius: var(--r-lg); background: var(--s-card, var(--ground-2)); overflow: hidden }
.s-card > :not(.s-ph) { margin-inline: 24px }
.s-ph { aspect-ratio: 4 / 3; display: grid; place-items: center; background: var(--tint); color: var(--brand-text); overflow: hidden }
.s:is([data-tone="tint"], [data-tone="band"], [data-tone="brand"]) .s-ph { background: var(--s-card-2) }
.s-ph img { width: 100%; height: 100%; object-fit: cover }
.s-ph .display { font-size: var(--fs-launch); line-height: 1; letter-spacing: 0 }
.s-name { margin-top: 22px; font-size: var(--fs-name); font-weight: 600; letter-spacing: -.02em; line-height: 1.2 }
.s-role { margin-top: 2px; font-size: var(--fs-sm); color: var(--ink-2) }
.s-line { margin-top: 16px; font-size: var(--fs-sm); line-height: 1.45; text-wrap: pretty }
.s-reach {
  display: grid; margin-top: auto; padding-top: 16px; border-top: .5px solid var(--line-2);
  font-size: var(--fs-xs); color: var(--ink-2); overflow-wrap: anywhere;
}
/* Pushed to the tile's foot, at least 16px under what is above it */
.s-card > :has(+ .s-reach) { margin-bottom: 16px }
.s-acts { display: flex; gap: 8px; padding-top: 16px }
.s-reach-act { flex: 1; min-width: 0; --ground-2: var(--s-card-2, var(--ground-3)) }
.s-reach-act .i { width: 18px; height: 18px }
/* A computer mostly cannot text, and its first way to reach someone is a soft button like the rest */
.s-text, .s-first { display: none }
:root[data-phone] .s-text { display: inline-flex }

/* The team on a page (fit="window") lays out by the window, as the team page always has: on a phone the same compact
   card, its first soft button painted in the brand */
@media (max-width: 699px) {
  .s-grid[data-fit="window"] { grid-template-columns: minmax(0, 1fr); gap: 12px }
  [data-fit="window"] .s-card { display: grid; grid-template-columns: 56px minmax(0, 1fr); column-gap: 14px; align-items: center; padding: 16px }
  [data-fit="window"] .s-card > :not(.s-ph) { margin-inline: 0 }
  [data-fit="window"] .s-ph { grid-row: 1 / 3; width: 56px; height: 56px; aspect-ratio: auto; border-radius: var(--r-md) }
  [data-fit="window"] .s-ph .display { font-size: var(--fs-name) }
  [data-fit="window"] .s-name { grid-column: 2; align-self: end; margin-top: 0; font-size: var(--fs-body) }
  [data-fit="window"] .s-role { grid-column: 2; align-self: start }
  [data-fit="window"] .s-card:not(:has(.s-role)) .s-name { grid-row: 1 / 3; align-self: center }
  [data-fit="window"] :is(.s-line, .s-acts) { grid-column: 1 / -1 }
  [data-fit="window"] .s-line { margin-top: 14px }
  [data-fit="window"] .s-card > :has(+ .s-reach) { margin-bottom: 0 }
  [data-fit="window"] .s-reach { display: none }
  [data-fit="window"] .s-acts { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 8px; padding-top: 16px }
  [data-fit="window"] .s-reach-act { height: 48px; font-size: var(--fs-body) }
  [data-fit="window"] .s-reach-act .i { width: 20px; height: 20px }
  /* Painted in the brand, so it shifts as a light fill does on either ground */
  [data-fit="window"] :is(.s-call, .s-email:first-child) { grid-column: 1 / -1; background: var(--brand-fill); color: var(--brand-ink); --shift: var(--shift-light); --shift-2: var(--shift-light-2) }
  [data-fit="window"] .s-text:last-child, :root:not([data-phone]) [data-fit="window"] .s-email { grid-column: 1 / -1 }
}

/* questions: native disclosures, one open at a time; every answer shown is components/pages/AnswerList.tsx */
.s-questions h1.s-title { font-size: var(--fs-hero) }
.s-list { border-top: .5px solid var(--line-2) }
.s-q { border-bottom: .5px solid var(--line-2) }
.s-ask {
  display: flex; align-items: center; justify-content: space-between; gap: 16px; width: 100%; min-height: 68px; padding: 18px 0;
  list-style: none; cursor: pointer; font-size: var(--fs-body); font-weight: 600; line-height: 1.3; letter-spacing: -.015em; color: var(--ink);
  transition: filter var(--t-quick) linear;
}
.s-ask::-webkit-details-marker { display: none }
.s-ask .i { color: var(--ink-3); transition: transform var(--t-state) var(--ease), color var(--t-state) var(--ease) }
@media (hover: hover) { .s-ask:hover { filter: brightness(.84) } }
.s-ask[data-pressed], :root:not([data-phone]) .s-ask:active { filter: brightness(.7); transition: none }
.s-q[open] .s-ask .i { transform: rotate(180deg); color: var(--ink) }
.s-answer { max-width: 680px; padding: 0 40px 24px 0; color: var(--ink-2); text-wrap: pretty; white-space: pre-line }
.s-side > :is(.s-title, .s-lead) { margin-bottom: 32px }
/* Every answer shown */
.s-questions:not([data-fold]) h1.s-title { font-size: clamp(var(--fs-hero), 4.6cqi, 72px) }
.s-answers { border-top: .5px solid var(--line-2) }
.s-item { padding: 28px 0; border-bottom: .5px solid var(--line-2) }
.s-item dt { font-size: var(--fs-name); font-weight: 600; letter-spacing: -.02em; line-height: 1.25; text-wrap: balance }
.s-item dd { margin-top: 6px; max-width: 600px; color: var(--ink-2); text-wrap: pretty; white-space: pre-line }

/* A wide block: the title held at the left, the questions beside it */
@container s (min-width: 960px) {
  .s-questions { display: grid; grid-template-columns: minmax(0, 5fr) minmax(0, 7fr); column-gap: 96px; align-items: start }
  .s-questions:not(:has(.s-side > *)) { grid-template-columns: minmax(0, 1fr) }
  .s-questions:not(:has(.s-side > *)) > .s-side { display: none }
  .s-questions .s-side { position: sticky; top: calc(var(--top-h) + 48px) }
}
@container s (max-width: 959px) {
  .s-quotes { gap: 48px }
}

/* The reviews on a page (fit="window") lay out by the window, as the words page always has */
@media (max-width: 1023px) {
  .s-rev[data-fit="window"] .s-quotes { gap: 48px }
}
@media (max-width: 699px) {
  .s-rev[data-fit="window"], .s-rev[data-fit="window"]:not(:has(.s-score)) { grid-template-columns: minmax(0, 1fr); grid-template-areas: "score" "quotes" "more"; gap: 32px; padding-top: 28px }
  .s-rev[data-fit="window"] .s-quotes { grid-template-columns: minmax(0, 1fr); gap: 32px }
  .s-rev[data-fit="window"] .s-quote:first-child blockquote { font-size: var(--fs-body); letter-spacing: -.01em; line-height: 1.5 }
  .s-rev[data-fit="window"] .s-more {
    justify-self: stretch; justify-content: space-between; min-height: 56px; margin-inline: calc(var(--gutter) * -1);
    padding-inline: var(--gutter); border-block: .5px solid var(--line-2); font-size: var(--fs-body);
  }
  .s-rev[data-fit="window"] .s-more[data-pressed] { background: var(--press); filter: none }
}

/* The answers on a page (fit="window") lay out by the window, as the FAQ page always has */
@media (min-width: 1024px) {
  .s-questions[data-fit="window"] { display: grid; grid-template-columns: minmax(0, 5fr) minmax(0, 7fr); column-gap: 96px; align-items: start }
  .s-questions[data-fit="window"] .s-side { position: sticky; top: calc(var(--top-h) + 48px) }
}
@media (max-width: 699px) {
  [data-fit="window"] .s-item { padding: 22px 0 }
}

/* A phone's width */
@container s (max-width: 559px) {
  .s-in > h1.s-title + :not(.s-lead), .s-in > h1.s-title + .s-lead + * { margin-top: 24px }
  .s-side > :is(.s-title, .s-lead) { margin-bottom: 20px }

  .s-prose > h1.s-title + .s-words, .s-prose > h1.s-title + .s-lead + .s-words { margin-top: 32px }
  .s-words { gap: 18px }
  .s-words p { font-size: var(--fs-body); line-height: 1.5; letter-spacing: -.01em }
  .s-words p:first-child { font-size: var(--fs-name); line-height: 1.3; letter-spacing: -.02em }

  /* A tall crop of the photo */
  .s-shot { height: clamp(200px, 36svh, 320px) }
  .s-photo[data-height="tall"] .s-shot { height: min(76svh, 660px); min-height: 420px }
  .s-shot img { object-position: 60% 72% }
  .s-shot::after { background: linear-gradient(to bottom, transparent 40%, color-mix(in oklab, var(--s-ground) 72%, transparent) 74%, var(--s-ground)) }
  .s-over { gap: 16px; margin-top: calc(var(--s-title-size) * -2.6) }
  .s-over .s-title { max-width: none }

  /* One column, the link closing it edge to edge */
  .s-rev, .s-rev:not(:has(.s-score)) { grid-template-columns: minmax(0, 1fr); grid-template-areas: "score" "quotes" "more"; gap: 32px; padding-top: 28px }
  .s-quotes { grid-template-columns: minmax(0, 1fr); gap: 32px }
  .s-quote:first-child blockquote { font-size: var(--fs-body); letter-spacing: -.01em; line-height: 1.5 }
  .s-more {
    justify-self: stretch; justify-content: space-between; min-height: 56px; margin-inline: calc(var(--gutter) * -1);
    padding-inline: var(--gutter); border-block: .5px solid var(--line-2); font-size: var(--fs-body);
  }
  .s-more[data-pressed] { background: var(--press); filter: none }

  /* A compact card, the monogram beside the name, and the ways to reach them as thumb-sized rows, Call first */
  .s-grid { grid-template-columns: minmax(0, 1fr); gap: 12px }
  .s-card { display: grid; grid-template-columns: 56px minmax(0, 1fr); column-gap: 14px; align-items: center; padding: 16px }
  .s-card > :not(.s-ph) { margin-inline: 0 }
  .s-ph { grid-row: 1 / 3; width: 56px; height: 56px; aspect-ratio: auto; border-radius: var(--r-md) }
  .s-ph .display { font-size: var(--fs-name) }
  .s-name { grid-column: 2; align-self: end; margin-top: 0; font-size: var(--fs-body) }
  .s-role { grid-column: 2; align-self: start }
  .s-card:not(:has(.s-role)) .s-name { grid-row: 1 / 3; align-self: center }
  .s-line, .s-acts { grid-column: 1 / -1 }
  .s-line { margin-top: 14px }
  .s-card > :has(+ .s-reach) { margin-bottom: 0 }
  /* The buttons carry the number and the address */
  .s-reach { display: none }
  .s-acts { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 8px; padding-top: 16px }
  .s-reach-act { height: 48px; font-size: var(--fs-body) }
  .s-reach-act .i { width: 20px; height: 20px }
  .s-first { display: inline-flex; grid-column: 1 / -1 }
  .s-twin { display: none }
  .s-text:last-child, :root:not([data-phone]) .s-email { grid-column: 1 / -1 }

  .s-ask { min-height: 64px; padding: 16px 0 }
  .s-answer { padding: 0 32px 22px 0; font-size: var(--fs-body); line-height: 1.5 }
  .s-item { padding: 22px 0 }
}
