/* CROSS site: the hub page (index.html), Swiss style. Tokens, top bar and footer in chrome.css; components in site.css. */

/* ------------------------------------------------------------------ masthead: the wordmark and the title */
/* desktop: the wordmark with the highlights under it on the left, the title column on the right */
.mast {
  display: grid; grid-template-columns: repeat(12, minmax(0, 1fr)); grid-template-rows: auto 1fr; column-gap: var(--g); row-gap: 18px;
  padding: 10px var(--m) clamp(22px, 2.6vw, 34px);
}
.mast-mark { grid-column: 1 / 8; grid-row: 1; container-type: inline-size; min-width: 0; }
.mast-info { grid-column: 8 / 13; grid-row: 1 / 3; display: flex; flex-direction: column; gap: 14px; padding-top: 4px; min-width: 0; }
@media (max-width: 1000px) {
  .mast-mark, .mast-info, .mast .mast-points { grid-column: 1 / -1; grid-row: auto; }
}
/* the wordmark fills its column: CROSS is 2.845 em wide in Inter Tight at -0.065 em tracking */
.wm { --wm: calc(100cqw / 2.86); position: relative; display: block; width: 2.845em; height: .73em; font-size: var(--wm); }
.wm-mark {
  display: block; margin: 0 0 0 -.0332em; font-weight: 400; font-size: 1em; line-height: .73;
  letter-spacing: -.065em; white-space: nowrap; color: var(--ink);
}
/* the words of the acronym sit inside the letters, in the accent */
.wm-word {
  position: absolute; left: calc(var(--x) * var(--wm)); top: calc(var(--y) * var(--wm));
  font-size: max(8.5px, min(13px, calc(var(--wm) * .046))); line-height: 1; letter-spacing: -0.02em; white-space: nowrap; color: var(--accent-ink);
}
/* the title column grows with the window, as the wordmark does, and the install line sits at its foot, level with the
   rule under the strengths */
.mast h1 { font-size: clamp(30px, 3.05vw, 60px); line-height: 1.02; letter-spacing: -0.04em; font-weight: 400; }
.mast-sub { font-size: clamp(16px, 1.25vw, 24px); font-weight: 300; line-height: 1.3; letter-spacing: -0.015em; max-width: 34em; }
.mast-points {
  grid-column: 1 / 8; grid-row: 2; align-self: end;
  list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); column-gap: var(--g);
  border-top: 1px solid var(--rule); font-size: clamp(14px, 1.05vw, 16px); line-height: 1.25; letter-spacing: -0.012em;
}
@media (max-width: 1000px) { .mast-points { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
.mast-points li { padding: 6px 0 5px; border-bottom: 1px solid var(--line); }
.mast-note { font-size: 12.5px; letter-spacing: 0; color: var(--ink-3); }
.mast-note-line { display: block; }
.mast-links { display: flex; flex-wrap: wrap; gap: 6px 20px; font-size: 16px; }
.mast-install { display: flex; align-items: center; gap: 0; margin-top: auto; }
@media (max-width: 1000px) { .mast-install { margin-top: 0; } }
.mast-install code { display: inline-flex; align-items: center; height: 28px; padding: 0 10px; font-size: 13px; background: var(--surface-2); }

/* ------------------------------------------------------------------ highlights: playlist player + grouped list */
/* 1200 px and up: the player on the left; the title, what is playing and the list on the right, the list at the
   bottom. The right column's type is sized in container units (cqw, the section's width), so it grows with the
   player and fills its height at every width. Narrower: title, player, then what is playing beside the list. */
.hl {
  container-type: inline-size;
  display: grid; grid-template-columns: repeat(12, minmax(0, 1fr)); grid-template-rows: auto auto 1fr; column-gap: var(--g); row-gap: 1.6cqw;
  padding: 20px var(--m) clamp(44px, 5vw, 76px); border-top: 1px solid var(--rule);
}
.hl-player { grid-column: 1 / 9; grid-row: 1 / 4; min-width: 0; }
.hl-head { grid-column: 9 / 13; grid-row: 1; min-width: 0; }
.hl-now { grid-column: 9 / 13; grid-row: 2; min-width: 0; }
.hl-list { grid-column: 9 / 13; grid-row: 3; align-self: end; min-width: 0; }
@media (max-width: 1199px) {
  .hl { grid-template-rows: none; row-gap: 18px; }
  .hl-head, .hl-player { grid-column: 1 / -1; grid-row: auto; }
  .hl-now { grid-column: 1 / 7; grid-row: auto; }
  .hl-list { grid-column: 7 / 13; grid-row: auto; align-self: start; }
}
@media (max-width: 760px) { .hl-now, .hl-list { grid-column: 1 / -1; } }
.hl-frame { background: #000; }
.hl-frame video { object-fit: cover; }
.hl-bar { display: flex; align-items: center; gap: 8px; margin-top: 2px; }
html:not(.js) .hl-bar { display: none; }  /* without JS the video keeps its native controls */
.hl-bar .sx-track { flex: 1; min-width: 0; }
/* what is playing: the clip's number and group, its title, what to look at, the place */
.hl-now { display: flex; flex-direction: column; gap: .5em; padding-top: .45em; border-top: 1px solid var(--rule); font-size: clamp(13px, 1.1cqw, 17px); }
.hl-now-k { display: flex; justify-content: space-between; gap: 1em; }
.hl-now-k > :first-child { display: inline-flex; align-items: center; gap: .3em; }
.hl-now-k > :first-child::before { content: ""; width: .6em; height: .6em; margin-right: .25em; background: var(--accent); }
.hl-now-k > :last-child { color: var(--ink-3); text-align: right; }
.hl-now-t { font-size: clamp(24px, 2.05cqw, 36px); font-weight: 400; letter-spacing: -0.035em; line-height: 1.05; }
.hl-now-d { font-size: clamp(15px, 1.25cqw, 21px); font-weight: 300; line-height: 1.36; letter-spacing: -0.01em; max-width: 32em; }
@media (max-width: 1199px) { .hl-now-d { min-height: calc(1.36em * 3); } }
.hl-head .sx-h { font-size: clamp(48px, 5.4cqw, 96px); line-height: .9; }
.hl-head .sx-mid { margin-top: .5em; font-size: clamp(18px, 1.5cqw, 26px); }
.hl-list { gap: .85em; font-size: clamp(15px, 1.2cqw, 20px); }
.ov-link { white-space: nowrap; }
.hl-group .sx-runin { padding-top: .35em; }

/* ------------------------------------------------------------------ summary */
.summary-body { padding-top: clamp(20px, 2.6vw, 36px); padding-bottom: clamp(52px, 6.5vw, 104px); }
.summary-body .sx-statement { max-width: 30em; }
.figures { list-style: none; margin: clamp(34px, 4.5vw, 64px) 0 0; padding: 0; display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); column-gap: var(--g); row-gap: 28px; }
@media (max-width: 640px) { .figures { grid-template-columns: minmax(0, 1fr); } }
.figures li { display: flex; flex-direction: column; gap: 6px; padding-top: 8px; border-top: 1px solid var(--rule); }
.fig-v { font-size: clamp(52px, 7vw, 108px); font-weight: 200; letter-spacing: -0.06em; line-height: .9; font-variant-numeric: tabular-nums; }
.fig-k { font-size: clamp(15px, 1.15vw, 18px); line-height: 1.25; letter-spacing: -0.012em; max-width: 22em; }
.fig-c { font-size: 13px; color: var(--ink-3); }
.fig-c code { font-size: 12px; }
.figures-note { margin-top: 22px; max-width: 70em; }

/* ------------------------------------------------------------------ overview bands */
.ov { padding-bottom: var(--m); }
.ov-text { padding: .5rem var(--m) 1.6rem; row-gap: .4rem; }
.ov-name { grid-column: 1 / 5; font-size: clamp(24px, 2.6vw, 38px); letter-spacing: -0.035em; line-height: 1.05; }
.ov-sentence { grid-column: 5 / 13; font-size: clamp(21px, 2.55vw, 37px); font-weight: 400; letter-spacing: -0.032em; line-height: 1.1; }
.ov-sentence strong { font-weight: 600; }
@media (max-width: 760px) { .ov-name, .ov-sentence { grid-column: 1 / -1; } }
.ov-clips { padding-inline: var(--m); }
.ov .sx-frame { background: rgba(0, 0, 0, .12); }

/* ------------------------------------------------------------------ benchmark */
.bench-body { padding-top: clamp(20px, 2.6vw, 36px); padding-bottom: clamp(52px, 6.5vw, 104px); }
.bench-lead { max-width: 30em; margin-bottom: clamp(26px, 3.4vw, 48px); }
/* the side column (facts, how to read the ranking, links) has its type in container units, so it grows with the chart
   and ends level with it at desktop widths */
.bench-grid { row-gap: 32px; container-type: inline-size; }
.bench-chart { grid-column: 1 / 9; min-width: 0; }
.bench-side { grid-column: 10 / 13; min-width: 0; display: flex; flex-direction: column; gap: 1.5em; font-size: clamp(13.5px, calc(8.5px + .43cqw), 17px); }
/* below 1200 px (as the highlights and the video): the chart, then the facts beside the note and the links */
@media (max-width: 1199px) {
  .bench-chart { grid-column: 1 / -1; }
  .bench-side {
    grid-column: 1 / -1; display: grid; grid-template-columns: repeat(12, minmax(0, 1fr)); column-gap: var(--g); row-gap: 1.2em;
    align-items: start; font-size: 14.5px;
  }
  .bench-facts { grid-column: 1 / 8; grid-row: 1 / 3; }
  .bench-foot, .bench-links { grid-column: 9 / 13; }
}
@media (max-width: 760px) { .bench-side { display: flex; } }
.bench-tabs { margin-bottom: 14px; }
@media (max-width: 560px) { .bench-tabs [role="tab"] { font-size: 19px; } }
.js .hr-panel[hidden] { display: none; }
.hr-panel + .hr-panel { margin-top: 26px; }
.js .hr-panel + .hr-panel { margin-top: 0; }
.hr-title { margin-bottom: 8px; }
.hr-list { list-style: none; margin: 0; padding: 0; border-top: 1px solid var(--rule); }
.hr-row {
  display: grid; grid-template-columns: minmax(150px, 2.2fr) minmax(0, 5fr) 64px; align-items: center; column-gap: 16px;
  padding: 7px 0; border-bottom: 1px solid var(--line);
}
.hr-name { font-size: clamp(16px, 1.25vw, 20px); letter-spacing: -0.02em; line-height: 1.15; }
.hr-name small { display: block; margin-top: 2px; font-size: 12.5px; letter-spacing: 0; color: var(--ink-3); }
.hr-fail { color: var(--bad); white-space: nowrap; }
.hr-bar { height: 10px; background: none; }
.hr-bar i { display: block; width: var(--w); min-width: 2px; height: 100%; background: color-mix(in srgb, var(--ink) 30%, transparent); transition: width .6s cubic-bezier(.2, .7, .2, 1); }
.hr-row.is-cross .hr-bar i { background: var(--c-cross); }
.hr-row.is-cross .hr-name { font-weight: 600; }
.hr-row.is-ub .hr-bar i {
  background: repeating-linear-gradient(135deg, color-mix(in srgb, var(--ink) 40%, transparent) 0 2px, transparent 2px 5px);
  box-shadow: inset 0 0 0 1px color-mix(in srgb, var(--ink) 40%, transparent);
}
.hr-row.is-unranked .hr-bar i { opacity: .45; }
.hr-row.is-unranked .hr-val b { color: var(--ink-3); font-weight: 400; }
.hr-val { text-align: right; font-variant-numeric: tabular-nums; }
.hr-val b { font-size: clamp(16px, 1.3vw, 21px); font-weight: 400; letter-spacing: -0.02em; }
.hr-row.is-cross .hr-val b { font-weight: 600; }
.hr-val .lb-na { color: var(--ink-3); }
@media (max-width: 560px) {
  .hr-row { grid-template-columns: minmax(0, 1fr) 60px; row-gap: 6px; }
  .hr-bar { grid-column: 1 / -1; grid-row: 2; height: 8px; }
  .hr-val { grid-row: 1; grid-column: 2; }
}
.bench-foot { font-size: .88em; line-height: 1.4; color: var(--ink-3); max-width: 40em; }
.bench-facts { list-style: none; margin: 0; padding: 0; border-top: 1px solid var(--rule); }
.bench-facts li { display: grid; grid-template-columns: 6.5em minmax(0, 1fr); gap: .55em; padding: .5em 0; border-bottom: 1px solid var(--line); line-height: 1.3; }
.bench-facts li > span:first-child { color: var(--ink-3); }
.bench-links { display: flex; flex-direction: column; align-items: flex-start; gap: .5em; font-size: 1.1em; }

/* ------------------------------------------------------------------ video: the player, what is playing, the chapters */
/* 1200 px and up: the player on 8 columns; on the other 4, what the playing chapter shows at the top and the chapter list
   at the foot. Their type is in container units (cqw, the grid's width), so the column grows with the player and fills
   its height at every width. Narrower: the player, then what is playing beside the chapters; phones: one column. */
.tour-grid { container-type: inline-size; grid-template-rows: auto 1fr; row-gap: 1.6cqw; padding-top: 20px; padding-bottom: clamp(52px, 6.5vw, 104px); }
.tour-player { grid-column: 1 / 9; grid-row: 1 / 3; min-width: 0; }
.tour-player .sx-frame { background: #000; }
.tour-player video { object-fit: contain; background: #000; }
.tour-now {
  grid-column: 9 / 13; grid-row: 1; min-width: 0; display: flex; flex-direction: column; gap: .5em;
  padding-top: .45em; border-top: 1px solid var(--rule); font-size: clamp(13px, 1.05cqw, 19px);
}
.tour-now-k { display: flex; justify-content: space-between; gap: 1em; }
.tour-now-k > :first-child { display: inline-flex; align-items: center; gap: .3em; }
.tour-now-k > :first-child::before { content: ""; width: .6em; height: .6em; margin-right: .25em; background: var(--accent); }
.tour-now-k > :last-child { color: var(--ink-3); font-variant-numeric: tabular-nums; }
.tour-now-t { font-size: clamp(22px, 2.1cqw, 40px); letter-spacing: -0.035em; line-height: 1.06; text-wrap: balance; }
.tour-now-d { font-size: clamp(15px, 1.28cqw, 24px); font-weight: 300; line-height: 1.36; letter-spacing: -0.01em; }
.tour-side { grid-column: 9 / 13; grid-row: 2; align-self: end; min-width: 0; }
.tour-side .sx-list-head { font-size: clamp(14px, 1.05cqw, 19px); }
.chapters { list-style: none; margin: 0; padding: 0; }
.chapters button {
  width: 100%; display: grid; grid-template-columns: 2.2em minmax(0, 1fr) auto; column-gap: .6em; align-items: baseline;
  padding: .38em 0; border: 0; border-bottom: 1px solid var(--line); background: none; text-align: left;
  font-size: clamp(15px, 1.12cqw, 21px); letter-spacing: -0.015em; line-height: 1.2;
  color: color-mix(in srgb, var(--ink) 62%, transparent); transition: color .15s;
}
.chapters button:hover, .chapters button[aria-current] { color: var(--ink); }
.ch-i { font-variant-numeric: tabular-nums; }
.ch-n small { display: block; font-size: 12px; letter-spacing: 0; color: var(--ink-3); }
.ch-t { font-size: 13px; letter-spacing: 0; font-variant-numeric: tabular-nums; white-space: nowrap; }
.chapters button[aria-current] .ch-t::before { content: ""; display: inline-block; width: .5em; height: .5em; margin-right: .45em; background: var(--accent); }
@media (max-width: 1199px) {
  .tour-grid { grid-template-rows: none; row-gap: 20px; }
  .tour-player { grid-column: 1 / -1; grid-row: auto; }
  .tour-now { grid-column: 1 / 7; grid-row: auto; font-size: 15px; }
  .tour-side { grid-column: 7 / 13; grid-row: auto; align-self: start; }
  .tour-now-t { font-size: clamp(22px, 2.6vw, 28px); }
  .tour-now-d { font-size: 16px; min-height: calc(1.36em * 4); }
  .tour-side .sx-list-head, .chapters button { font-size: 15px; }
}
@media (max-width: 760px) { .tour-now, .tour-side { grid-column: 1 / -1; } }

/* ------------------------------------------------------------------ method */
.method .container { padding-top: clamp(20px, 2.6vw, 36px); padding-bottom: clamp(52px, 6.5vw, 104px); }
.method-lead { max-width: 30em; margin-bottom: clamp(30px, 4vw, 56px); }
.steps { list-style: none; margin: 0; padding: 0; row-gap: 32px; }
.step { grid-column: span 3; display: flex; flex-direction: column; gap: 10px; padding-top: 8px; border-top: 1px solid var(--rule); min-width: 0; }
@media (max-width: 1000px) { .step { grid-column: span 6; } }
@media (max-width: 760px) { .step { grid-column: 1 / -1; } }
.step-n { font-size: clamp(40px, 4.6vw, 68px); font-weight: 200; letter-spacing: -0.05em; line-height: .9; font-variant-numeric: tabular-nums; }
.step h3 { font-size: clamp(22px, 2vw, 30px); letter-spacing: -0.035em; }
.step p:not(.step-n) { font-size: 15.5px; font-weight: 300; line-height: 1.4; letter-spacing: -0.008em; }
.step-art { width: 100%; height: auto; max-height: 92px; margin: 6px 0 4px; }
.step-art .ln { fill: none; stroke: var(--ink); stroke-width: 1.4; }
.step-art .ln.dash { stroke-dasharray: 3 4; }
.step-art .ln.faint { opacity: .45; }
.step-art .ln.hi { stroke: var(--accent); stroke-width: 2.2; }
.step-art .nd { fill: var(--bg); stroke: var(--ink); stroke-width: 1.4; }
.step-art .nd.hi { fill: var(--accent); stroke: var(--accent); }
.step-art .hyp { fill: none; stroke: var(--ink); stroke-width: 1.2; stroke-dasharray: 3 3; }
.step-art .hyp.hi { stroke: var(--accent); stroke-dasharray: none; stroke-width: 1.8; }
.step-art .dot { fill: var(--ink); }
.step-art .dot.hi { fill: var(--accent); }
.method-more { margin-top: clamp(28px, 3.5vw, 48px); font-size: 17px; }

/* ------------------------------------------------------------------ get started */
/* the text column's type is in container units, so it grows with the width and ends level with the terminal, whose
   height does not change */
.start-grid { row-gap: 32px; padding-top: clamp(20px, 2.6vw, 36px); container-type: inline-size; }
.start-text { grid-column: 1 / 6; min-width: 0; display: flex; flex-direction: column; gap: 22px; }
.start-code { grid-column: 6 / 13; min-width: 0; }
@media (max-width: 1100px) { .start-text, .start-code { grid-column: 1 / -1; } }
.start-text .sx-statement { font-size: clamp(22px, 2.3cqw, 44px); }
.start-facts { list-style: none; margin: 0; padding: 0; border-top: 1px solid var(--rule); font-size: clamp(14px, calc(8.5px + .43cqw), 17px); }
.start-facts li { display: grid; grid-template-columns: 5.5em minmax(0, 1fr); gap: .55em; padding: .5em 0; border-bottom: 1px solid var(--line); line-height: 1.3; }
.start-facts li > span:first-child { color: var(--ink-3); }
.start-links { display: flex; flex-wrap: wrap; gap: 6px 22px; font-size: 16px; }
@media (max-width: 1100px) { .start-facts { font-size: 14.5px; } }
.start-code .sx-list-head { align-items: center; font-size: 15px; }
.start-code .sx-listing { padding-top: 8px; overflow-x: auto; }
.modes { padding-top: clamp(40px, 5vw, 72px); padding-bottom: clamp(52px, 6.5vw, 104px); }
.modes .sx-sub { padding-inline: 0; margin-bottom: 0; border-bottom: 0; }
.modes .table-wrap { margin-top: 8px; }
.modes-table th, .modes-table td { white-space: nowrap; }
.modes-table tbody th { font-weight: 400; }
.modes-table td code { font-size: 13px; background: none; padding: 0; }
.modes-table td.na { color: var(--ink-3); }
.rec-tag { margin-left: 6px; font-size: 12px; color: var(--accent-ink); }
.rec-tag::before { content: ""; display: inline-block; width: .5em; height: .5em; margin-right: .35em; background: var(--accent); }
.modes-more { margin-top: 14px; font-size: 16px; }
.modes-hint { display: none; margin-top: 8px; }
@media (max-width: 900px) {
  .modes-hint { display: block; }
  .modes-table tbody th { position: sticky; left: 0; z-index: 1; background: var(--bg); }
  .modes-table thead th:first-child { left: 0; z-index: 2; }
}

/* ------------------------------------------------------------------ papers: a bordered mosaic */
.mosaic { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); border-top: 2px solid var(--rule); border-left: 2px solid var(--rule); }
@media (max-width: 900px) { .mosaic { grid-template-columns: minmax(0, 1fr); } }
.mo-cell { position: relative; min-width: 0; border-right: 2px solid var(--rule); border-bottom: 2px solid var(--rule); }
.mo-text { display: flex; flex-direction: column; gap: 10px; min-height: 220px; padding: 12px 14px 14px; background: var(--bg); }
.mo-k { font-size: clamp(34px, 3.8vw, 58px); letter-spacing: -0.05em; line-height: .95; }
.mo-k span { display: block; margin-top: 6px; font-size: 13px; letter-spacing: 0; color: var(--accent-ink); }
.mo-text h3 { font-size: clamp(18px, 1.45vw, 23px); letter-spacing: -0.025em; line-height: 1.15; }
.mo-text h3 a { text-decoration: none; }
.mo-text h3 a:hover { text-decoration: underline; }
.mo-sub { font-size: 15px; font-weight: 300; line-height: 1.35; }
.mo-meta { margin-top: auto; font-size: 13px; color: var(--ink-3); }
.mo-soon::before { content: ""; display: inline-block; width: .5em; height: .5em; margin-right: .4em; border: 1px solid currentColor; }
.mo-links { display: flex; flex-wrap: wrap; gap: 4px 16px; font-size: 15px; }
/* the first paper's cell fills the height of the teaser beside it: its type is in container units, and from 1320 px a
   short list says what the paper shows (one to four points as the teaser grows) */
.mo-lead { container-type: inline-size; }
.mo-lead h3 { font-size: clamp(18px, 4.4cqw, 32px); }
.mo-lead .mo-sub { font-size: clamp(15px, 3cqw, 21px); }
.mo-lead .mo-meta { font-size: clamp(13px, 2.2cqw, 15px); }
.mo-lead .mo-links { font-size: clamp(15px, 2.6cqw, 18px); }
.mo-shows { display: none; list-style: none; margin: 4px 0 0; padding: 0; border-top: 1px solid var(--line); font-size: clamp(14px, 2.6cqw, 18px); line-height: 1.25; letter-spacing: -0.012em; }
.mo-shows li { padding: .38em 0; border-bottom: 1px solid var(--line); }
@media (min-width: 1320px) { .mo-shows { display: block; } }
@media (max-width: 1399px) { .mo-shows li:nth-child(n+2) { display: none; } }
@media (max-width: 1559px) { .mo-shows li:nth-child(n+3) { display: none; } }
@media (max-width: 1649px) { .mo-shows li:nth-child(4) { display: none; } }
.mo-media { display: block; overflow: hidden; background: #fff; }
.mo-wide { grid-column: span 2; }
@media (max-width: 900px) { .mo-wide { grid-column: auto; } }
.mo-wide img { width: 100%; height: 100%; object-fit: cover; object-position: center; }
/* halftone-like duotone: the grey image through a dot screen, multiplied onto a coloured ground */
.mo-duo { aspect-ratio: 16 / 9; background: var(--ground); }
/* tools/halftone.py renders the dots (black on transparent); the cell supplies the ground colour */
.mo-duo img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.mo-chip { position: absolute; left: 0; bottom: 0; padding: 2px 6px; font-size: 13px; background: var(--ground); color: #111; }
.mo-dark .mo-chip { color: #fff; }

/* ------------------------------------------------------------------ BibTeX */
.bib-body { padding-top: clamp(20px, 2.6vw, 36px); padding-bottom: clamp(52px, 6.5vw, 104px); }

/* without JavaScript the clips cannot load their posters (site.js reads data-poster on scroll): show the poster image */
html:not(.js) .ov-clips video { display: none; }
html:not(.js) .ov-clips .sx-frame img { display: block; width: 100%; height: 100%; object-fit: cover; }
