/* Performance in the new look (SKI-1281; portalPerformance/wide, lockedWide and phone; vault
   Design/portal.md). The page of figures: play around the numbers, never on them. Paper cards on
   the canvas, each title a Heading at its phone size; one red price per line, the shop's own, in
   the Price role and Bold; a chart whose line is rose's deep; one filled card, the unlock panel,
   on the locked page only; no character but Nejma waiting before the shop is shown. Every value
   reads a variable of css/tokens.css but the chart's two lengths in its own drawing space (see
   .perf-chart text). Nothing moves.

   The rows wear classes Ma boutique's rows wear too (.row, .head, .rows, .namecell, .brandline,
   .why, .price, .thumb, .noimg, .preparing, .ic), whose rules there are scoped to Ma boutique:
   every rule below that meets one is written whole. A phone is the base; 640, 900 and 1100 add
   room, and the positions' table its own 1220 and 1360 (the seat's ruling of 18 Nov, 20:15). */

/* ── the page: one column of cards on the canvas ─────────── */
.perf-page {
  display: flex;
  flex-direction: column;
  gap: 20px;
  max-width: 1080px;
}
.perf-page > .pagehead {
  margin-bottom: 0;
}
/* The freshness line sits under the page's sentence, on its own line. */
.perf-page .pagehead .sub {
  flex-wrap: wrap;
}
.perf-fresh {
  display: flex;
  flex-basis: 100%;
  align-items: center;
  gap: 6px;
  color: var(--color-muted);
  font-size: var(--text-small);
  line-height: var(--leading-small);
}
.perf-fresh .ph {
  width: 14px;
  height: 14px;
}

/* A card: paper, the thin edge, corners of 24 (css/controls.css), 16 inside on a phone. */
.perf-card {
  display: flex;
  flex-direction: column;
  gap: 16px;
  min-width: 0;
  padding: 16px;
}
.perf-card > div:empty {
  display: none;
}
.perf-cardhead {
  position: relative;
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 12px 24px;
}
.perf-cardhead > div:first-child {
  display: flex;
  flex: 1 1 280px;
  flex-direction: column;
  gap: 6px;
  min-width: 0;
}
/* A card's title is a Heading at its phone size, at every width. */
.perf-cardhead h2,
.perf-unlock h2 {
  display: flex;
  align-items: center;
  gap: 10px;
  color: var(--color-ink);
  font-size: var(--text-heading-mobile);
  font-weight: var(--font-weight-bold);
  line-height: var(--leading-heading);
  letter-spacing: var(--tracking-heading);
}
.perf-cardhead p,
p.perf-cardsub {
  max-width: 640px;
  color: var(--color-muted);
  font-size: var(--text-small);
  line-height: var(--leading-small);
}
/* The positions' sentence follows the head, 6 under its title as in the head itself. */
p.perf-cardsub {
  margin-top: -10px;
}
/* Under 1100 the positions' chips come under that sentence (portalPerformance/phone); from 1100,
   where they fit, at the title's right. */
#position > .perf-cardhead {
  display: contents;
}
#position > .perf-cardhead > div:first-child {
  flex: none;
}
#position .perf-filters {
  order: 1;
}
#position > .perf-rows,
#position > #position-pager {
  order: 2;
}
.perf-cardsub b {
  color: var(--color-ink);
  font-weight: var(--font-weight-bold);
}
p.perf-more,
p.perf-foot {
  color: var(--color-muted);
  font-size: var(--text-small);
  line-height: var(--leading-small);
}

/* ── what every line of a list shares: the picture's tile, the brand, the name ── */
.perf-page .row > img,
.perf-page .row > .thumb,
.perf-action > img,
.perf-action > .thumb {
  flex: none;
  width: var(--size-tile);
  height: var(--size-tile);
  border: 0;
  border-radius: var(--radius-16);
  background: var(--color-oat);
  object-fit: cover;
}
.perf-page .row.perf-li > img,
.perf-page .row.perf-li > .thumb {
  width: 40px;
  height: 40px;
}
.perf-page .thumb.noimg {
  font-size: var(--text-body);
}
.perf-page .thumb.noimg .ph {
  width: 18px;
  height: 18px;
}
.perf-page .namecell {
  display: flex;
  flex-direction: column;
  gap: 3px;
  min-width: 0;
  padding-right: 0;
}
.perf-page .brandline,
.perf-action-body .brandline {
  margin-bottom: 0;
  color: var(--color-muted);
  font-size: var(--text-small);
  font-weight: var(--font-weight-regular);
  line-height: var(--leading-small);
  letter-spacing: normal;
  text-transform: none;
}
.perf-page .namecell .name {
  display: block;
  overflow: visible;
  -webkit-line-clamp: none;
  -webkit-box-orient: horizontal;
  color: var(--color-ink);
  font-size: var(--text-label);
  font-weight: var(--font-weight-medium);
  line-height: var(--leading-label);
}
/* Each cell of a row keeps its own width and place, at every width. */
.perf-page .row > *,
.perf-page .head > * {
  min-width: 0;
}
.perf-page .row > span:not(.pill):not(.price):not(.thumb),
.perf-page .row .namecell,
.perf-page .row .price,
.perf-page .row .pill {
  grid-column: auto;
  justify-self: auto;
}
.perf-name {
  color: inherit;
  text-decoration: none;
}
.perf-name:hover {
  text-decoration: underline 1px;
  text-underline-offset: 3px;
}
.perf-size {
  color: var(--color-muted);
  font-weight: var(--font-weight-regular);
}
.perf-page .namecell .why {
  margin-top: 0;
  color: var(--color-muted);
  font-size: var(--text-small);
  line-height: var(--leading-small);
}
/* What is missing to be the cheapest, under the name: a Small in ink 2. */
.perf-page .namecell .why.perf-hint {
  color: var(--color-ink-2);
}
/* The one red price of a line: the shop's own, in the Price role and Bold. */
.perf-page .price {
  color: var(--color-red);
  font-size: var(--text-price);
  font-weight: var(--font-weight-bold);
  line-height: var(--leading-price);
  font-variant-numeric: lining-nums tabular-nums;
  white-space: nowrap;
}

/* ── « Cette semaine »: three figures, each a sentence around its number ── */
.perf-week {
  display: flex;
  flex-direction: column;
  gap: 12px;
}
.perf-eyebrow {
  color: var(--color-rose-deep);
  font-size: var(--text-overline);
  font-weight: var(--font-weight-bold);
  line-height: var(--leading-overline);
  letter-spacing: var(--tracking-overline);
  text-transform: uppercase;
}
.perf-figs {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: 12px;
}
.perf-fig {
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  gap: 10px;
  padding: 16px;
  border: 1px solid var(--color-edge);
  border-radius: var(--radius-24);
  background: var(--color-paper);
  color: var(--color-ink-2);
  text-decoration: none;
}
@media (hover: hover) {
  .perf-fig:hover {
    box-shadow: var(--shadow-lift);
  }
}
.perf-fig:focus-visible {
  outline: 2px solid var(--color-ink);
  outline-offset: 2px;
}
.perf-fig-text {
  font-size: var(--text-label);
  font-weight: var(--font-weight-medium);
  line-height: 1.5;
}
.perf-fig-text b {
  color: var(--color-ink);
  font-size: var(--text-heading-mobile);
  font-weight: var(--font-weight-bold);
  letter-spacing: var(--tracking-heading);
  font-variant-numeric: lining-nums tabular-nums;
}
.perf-fig-hint {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  color: var(--color-muted);
  font-size: var(--text-small);
  line-height: var(--leading-small);
}
.perf-fig-hint .ph {
  width: 16px;
  height: 16px;
  color: var(--color-ink);
}

/* ── « À faire cette semaine »: numbered lines, the best first ── */
#a-faire {
  gap: 12px;
}
.perf-actions {
  margin: 0;
  padding: 0;
  list-style: none;
}
/* On a phone the button goes under the words, from the picture's edge. */
.perf-action {
  display: grid;
  grid-template-columns: 22px var(--size-tile) minmax(0, 1fr);
  grid-template-areas:
    "n img body"
    ". go go";
  column-gap: 12px;
  row-gap: 12px;
  align-items: start;
  padding: 14px 0;
  border-top: 1px solid var(--color-edge);
}
.perf-action > img,
.perf-action > .thumb {
  grid-area: img;
}
.perf-action-n,
.perf-stepnum {
  display: grid;
  place-items: center;
  flex: none;
  width: 22px;
  height: 22px;
  border-radius: var(--radius-pill);
  background: var(--color-ink);
  color: var(--color-paper);
  font-size: var(--text-badge);
  font-weight: var(--font-weight-bold);
  line-height: var(--leading-badge);
}
.perf-action-n {
  grid-area: n;
}
.perf-action-body {
  grid-area: body;
  display: flex;
  flex-direction: column;
  gap: 3px;
  min-width: 0;
}
.perf-action-text {
  color: var(--color-ink);
  font-size: var(--text-label);
  font-weight: var(--font-weight-medium);
  line-height: var(--leading-small);
}
/* The gain says what the line is worth: green's deep, or butter's while the shop is out of stock. */
.perf-action-gain {
  color: var(--color-green-deep);
  font-size: var(--text-small);
  line-height: var(--leading-small);
}
.perf-action.restock .perf-action-gain {
  color: var(--color-butter-deep);
}
.perf-action-go {
  grid-area: go;
  justify-self: start;
}

/* ── locked: still skeletons, then one lock strip ──────────── */
.perf-locked {
  display: flex;
  flex-direction: column;
  gap: 12px;
  padding-top: 4px;
}
.perf-locked > div[aria-hidden] {
  display: flex;
  flex-direction: column;
  gap: 10px;
}
/* A skeleton: the picture's tile and two bars, on oat, still. */
.perf-skel {
  display: grid;
  grid-template-columns: var(--size-tile) minmax(0, 1fr);
  grid-template-rows: 1fr 1fr;
  column-gap: 14px;
  row-gap: 8px;
  height: var(--size-tile);
}
.perf-skel i {
  display: block;
  border-radius: var(--radius-pill);
  background: var(--color-oat);
}
.perf-skel i.sq {
  grid-row: 1 / span 2;
  width: var(--size-tile);
  height: var(--size-tile);
  border-radius: var(--radius-16);
}
.perf-skel i.w60 {
  align-self: end;
  width: 49%;
  height: 12px;
}
.perf-skel i.w20 {
  align-self: start;
  width: 30%;
  height: 10px;
}
.perf-skel:nth-child(even) i.w60 {
  width: 38%;
}
.perf-skel:nth-child(even) i.w20 {
  width: 23%;
}
/* The lock strip: oat, corners of 16, the lock and its sentence in ink; the whole strip is the
   link to the unlock panel. */
.perf-lockmsg,
.perf-lockstrip {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 12px 16px;
  border-radius: var(--radius-16);
  background: var(--color-oat);
  color: var(--color-ink);
  font-size: var(--text-label);
  font-weight: var(--font-weight-medium);
  line-height: var(--leading-label);
  text-decoration: none;
}
.perf-lockmsg .ph-duotone,
.perf-lockstrip .ph-duotone {
  width: 18px;
  height: 18px;
  color: var(--color-ink);
}
.perf-lockmsg:hover span,
.perf-lockstrip:hover span {
  text-decoration: underline 1px;
  text-underline-offset: 3px;
}
.perf-lockmsg:focus-visible,
.perf-lockstrip:focus-visible {
  outline: 2px solid var(--color-ink);
  outline-offset: 2px;
}

/* ── the unlock panel (locked only): the page's one filled card, in rose's tint ── */
.card.perf-unlock {
  display: flex;
  flex-direction: column;
  gap: 24px;
  padding: 20px;
  border: 0;
  background: var(--color-rose-tint);
}
.perf-unlock h2 .ph-duotone {
  width: 22px;
  height: 22px;
  color: var(--color-ink);
}
.perf-unlock p.perf-lead {
  max-width: 720px;
  margin-top: -16px;
  color: var(--color-ink-2);
  font-size: var(--text-body);
  line-height: var(--leading-body);
}
.perf-steps {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: 24px;
}
.perf-step {
  display: flex;
  flex-direction: column;
  gap: 10px;
  min-width: 0;
}
.perf-steptitle {
  display: flex;
  align-items: center;
  gap: 14px;
  color: var(--color-ink);
  font-size: var(--text-name);
  font-weight: var(--font-weight-bold);
  line-height: var(--leading-name);
}
/* What follows a step's title sits under its words, beside its number. */
.perf-step > :not(.perf-steptitle) {
  margin-left: 36px;
}
.perf-step p {
  color: var(--color-ink-2);
  font-size: var(--text-small);
  line-height: var(--leading-small);
}
.perf-step p a {
  color: var(--color-ink);
  text-decoration: underline 1px;
  text-underline-offset: 3px;
}
.perf-snippet {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  min-width: 0;
  padding: 12px 12px 12px 16px;
  border-radius: var(--radius-16);
  background: var(--color-paper);
  color: var(--color-ink-2);
  font-size: var(--text-label);
  font-weight: var(--font-weight-medium);
  line-height: var(--leading-label);
}
.perf-snippet > span {
  flex: 1;
  min-width: 0;
}
.perf-snippet u {
  color: var(--color-ink);
  text-decoration: underline 1px;
  text-underline-offset: 3px;
}
.perf-send {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
  min-width: 0;
}
.perf-send .input {
  flex: 1;
  min-width: 0;
}
.perf-snippet .btn,
.perf-send .btn {
  width: 100%;
}

/* ── « Votre position, produit par produit » ───────────────
   On a phone and a tablet each product is a card: its picture, its name and the chart's round
   button, then its figures as label over value, 104 wide, wrapping. From 1220 a table, the head
   over its columns (--perf-cols), where the name keeps at least 200. Rows are parted by the thin
   edge; none has a fill. */
.perf-card .perf-rows {
  margin: 0 -16px;
  overflow: visible;
  scroll-margin-top: 0;
}
/* The head: column names as a Small in muted, in sentence case; shown from 1220. */
.head.perf-row {
  display: none;
  grid-template-columns: none;
  column-gap: 16px;
  padding: 12px 16px;
  color: var(--color-muted);
  font-size: var(--text-small);
  font-weight: var(--font-weight-regular);
  line-height: var(--leading-small);
  letter-spacing: normal;
  text-transform: none;
}
.head.perf-row .span2 {
  grid-column: 1 / span 2;
}
.row.perf-row {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-start;
  grid-template-columns: none;
  gap: 0 8px;
  padding: 14px 16px;
  border-top: 1px solid var(--color-edge);
}
.head.perf-row + .row.perf-row,
.perf-group + .row.perf-row {
  border-top: 0;
}
.row.perf-row:hover,
.row.perf-li:hover,
.row.perf-chartfor:hover {
  background: none;
}
/* The figures start on a line of their own, under the picture, 12 below it and each other. */
.row.perf-row::before {
  content: "";
  flex-basis: 100%;
  order: 2;
}
.row.perf-row .namecell {
  flex: 1 1 0;
  margin: 0 4px;
}
.perf-num {
  color: var(--color-ink);
  font-size: var(--text-label);
  font-weight: var(--font-weight-medium);
  line-height: var(--leading-label);
  font-variant-numeric: lining-nums tabular-nums;
  white-space: nowrap;
}
/* A figure's cell: its label, a Small in muted, over its value. */
.row.perf-row .perf-num {
  display: block;
  order: 3;
  min-width: 104px;
  margin-top: 12px;
}
.row.perf-row .perf-num::before {
  content: attr(data-label);
  display: block;
  margin-bottom: 2px;
  color: var(--color-muted);
  font-size: var(--text-small);
  font-weight: var(--font-weight-regular);
  line-height: var(--leading-small);
}
/* « Le moins cher », the line's fourth cell, in ink 2; « Prix habituel » (.muted) in muted. */
.row.perf-row > .perf-num:nth-child(4) {
  color: var(--color-ink-2);
}
/* « Écart », the seventh, is 112 wide in every row, the table's column too, so that the 30 days
   beside it line up from one product to the next. */
.row.perf-row > .perf-num:nth-child(7) {
  min-width: 112px;
}
.perf-num.muted {
  color: var(--color-muted);
}
.perf-num .small.muted {
  color: var(--color-muted);
  font-size: var(--text-small);
  font-weight: var(--font-weight-regular);
  line-height: var(--leading-small);
}
.perf-group {
  padding: 10px 16px;
  background: var(--color-oat);
  color: var(--color-ink-2);
  font-size: var(--text-small);
  line-height: var(--leading-small);
}
.perf-acts {
  display: flex;
  justify-content: flex-end;
  order: 1;
}
.perf-acts .btn.sm {
  width: var(--spacing-control-small);
  padding: 0;
}
svg.perf-spark {
  display: block;
  width: 96px;
  height: 28px;
  overflow: visible;
}
.perf-spark path {
  fill: none;
  stroke-linejoin: round;
  stroke-linecap: round;
  vector-effect: non-scaling-stroke;
}
.perf-spark .sp-mine {
  stroke: var(--color-rose-deep);
  stroke-width: 2.5;
}
.perf-spark .sp-min {
  stroke: var(--color-muted);
  stroke-width: 1.25;
  stroke-dasharray: 3 3;
}
.perf-spark.none {
  color: var(--color-muted);
}
.perf-pager {
  margin: -16px -16px 0;
  padding: 16px 16px 0;
  border-top: 1px solid var(--color-edge);
}
/* Under the table, the skeletons sit inside the card's padding, below a last edge. */
.perf-rows > .perf-locked {
  padding: 14px 16px 0;
  border-top: 1px solid var(--color-edge);
}

/* ── « Historique des prix »: on a phone the rows' sparklines stand in for it, until a card
   asks for it ── */
.perf-card.perf-history {
  gap: 20px;
}
.perf-history:not(:target) {
  display: none;
}
.perf-history .perf-cardhead {
  row-gap: 20px;
}
/* The product and its span, on a line of their own under the title. */
.perf-chartctl {
  display: flex;
  flex: 1 1 100%;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
  min-width: 0;
}
.perf-picker {
  flex: 0 1 420px;
  min-width: 0;
  max-width: 100%;
}
.perf-picker .input {
  width: 100%;
  text-overflow: ellipsis;
}
.perf-periods {
  margin-left: auto;
}
.perf-chartbox {
  display: flex;
  flex-direction: column;
  gap: 20px;
}
.row.perf-chartfor {
  display: flex;
  align-items: center;
  grid-template-columns: none;
  gap: 14px;
  padding: 0;
  border-top: 0;
}
.row.perf-chartfor .namecell {
  flex: 1 1 0;
}
.perf-legend {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px 20px;
  color: var(--color-ink-2);
  font-size: var(--text-small);
  line-height: var(--leading-small);
}
.perf-legend span {
  display: inline-flex;
  align-items: center;
  gap: 8px;
}
.perf-legend i {
  flex: none;
  width: 18px;
}
.perf-legend .sw-mine {
  height: 4px;
  border-radius: var(--radius-pill);
  background: var(--color-rose-deep);
}
.perf-legend .sw-band {
  height: 12px;
  border: 1px solid var(--color-rose-soft);
  background: var(--color-rose-tint);
}
svg.perf-chart {
  display: block;
  width: 100%;
  height: auto;
  overflow: visible;
}
.perf-chart .grid line {
  stroke: var(--color-edge-pill);
  vector-effect: non-scaling-stroke;
}
/* The chart is drawn 760 wide and scaled to the card: its words' size is a length in that
   drawing space, not a size on the page, so no role's variable fits it (the seat's ruling, 18
   Nov). 22 of them read about 9 px on a phone; from 640 the size below. */
.perf-chart text {
  font: 22px var(--font-site);
  fill: var(--color-muted);
  font-variant-numeric: tabular-nums;
}
.perf-chart path {
  fill: none;
  stroke-linejoin: round;
  stroke-linecap: round;
}
.perf-chart .band-market {
  fill: var(--color-rose-tint);
  stroke: var(--color-rose-soft);
  stroke-width: 1;
  vector-effect: non-scaling-stroke;
}
/* The shop's price: one calm line in rose's deep, 3.5 on the screen at every width. */
.perf-chart .ln-mine {
  stroke: var(--color-rose-deep);
  stroke-width: 3.5;
  vector-effect: non-scaling-stroke;
}
.perf-chart .dot-mine {
  r: 9;
  fill: var(--color-rose-deep);
}
.perf-chart .dot-move {
  r: 8;
  fill: var(--color-paper);
  stroke: var(--color-rose-deep);
  stroke-width: 2;
  vector-effect: non-scaling-stroke;
}
.perf-chart .hit {
  fill: transparent;
}
.perf-chart .hit:hover {
  fill: var(--color-edge);
}
.perf-chartmoves {
  display: flex;
  flex-direction: column;
  gap: 6px;
  margin: 0;
  padding: 0;
  list-style: none;
  color: var(--color-ink-2);
  font-size: var(--text-small);
  line-height: var(--leading-small);
}
.perf-chartmoves li {
  display: flex;
  align-items: center;
  gap: 8px;
}
.perf-chartmoves .dot {
  flex: none;
  width: 9px;
  height: 9px;
  border: 2px solid var(--color-rose-deep);
  border-radius: var(--radius-pill);
  background: var(--color-paper);
}

/* ── « Cette semaine sur le marché » ───────────────────────
   Three items, each a line icon on a tile of its state's tint, its line in that colour's deep:
   falls on green, rises on butter, alone in stock on rose. No paint. */
.perf-moves {
  display: flex;
  flex-direction: column;
  gap: 16px;
  margin: 0;
  padding: 0;
  list-style: none;
}
.perf-moves > li {
  display: flex;
  align-items: flex-start;
  gap: 14px;
  padding-top: 16px;
  border-top: 1px solid var(--color-edge);
}
/* The lead stays one sentence around its bold part; what follows it, 10 under. */
.perf-moves > li > div {
  flex: 1;
  min-width: 0;
  padding-top: 8px;
  color: var(--color-ink-2);
  font-size: var(--text-label);
  font-weight: var(--font-weight-medium);
  line-height: var(--leading-small);
}
.perf-moves > li > div > :not(b) {
  margin-top: 10px;
}
.perf-moves b {
  color: var(--color-ink);
  font-weight: var(--font-weight-bold);
  font-variant-numeric: lining-nums tabular-nums;
}
.perf-moves .ic {
  display: grid;
  place-items: center;
  flex: none;
  width: var(--size-tile-small);
  height: var(--size-tile-small);
  margin-bottom: 0;
  border-radius: var(--radius-16);
}
.perf-moves .ic .ph-duotone {
  width: 20px;
  height: 20px;
}
.perf-moves .ic.green {
  background: var(--color-green-tint);
  color: var(--color-green-deep);
}
.perf-moves .ic.amber {
  background: var(--color-butter-tint);
  color: var(--color-butter-deep);
}
.perf-moves .ic.pink {
  background: var(--color-rose-tint);
  color: var(--color-rose-deep);
}
.perf-moves .small.muted {
  color: var(--color-muted);
  font-size: var(--text-small);
  font-weight: var(--font-weight-regular);
  line-height: var(--leading-small);
}
.perf-list {
  display: flex;
  flex-direction: column;
}
.perf-list > p.perf-more {
  padding-top: 8px;
}
.row.perf-li {
  display: flex;
  align-items: center;
  grid-template-columns: none;
  gap: 14px;
  padding: 8px 0;
  border-top: 0;
}
.row.perf-li .namecell {
  flex: 1 1 0;
  gap: 2px;
}
.row.perf-li > .small.muted {
  flex: none;
  color: var(--color-muted);
  font-size: var(--text-small);
  font-weight: var(--font-weight-regular);
  line-height: var(--leading-small);
}
.row.perf-li > .price,
.row.perf-li > .btn {
  flex: none;
}
.perf-more-rows summary {
  display: inline-block;
  padding-top: 8px;
  color: var(--color-ink);
  font-size: var(--text-small);
  font-weight: var(--font-weight-regular);
  line-height: var(--leading-small);
  text-decoration: underline 1px;
  text-underline-offset: 3px;
  cursor: pointer;
  list-style: none;
}
.perf-more-rows summary::-webkit-details-marker,
.perf-why summary::-webkit-details-marker {
  display: none;
}
.perf-more-rows[open] summary {
  display: none;
}
/* « Pourquoi pas de noms ? »: a quiet link with its line icon; it opens a popover, a menu's look
   at corners of 24 (spec P17). */
.perf-why {
  font-size: var(--text-small);
  line-height: var(--leading-small);
}
.perf-why summary {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  color: var(--color-ink-2);
  font-size: var(--text-small);
  line-height: var(--leading-small);
  text-decoration: underline 1px;
  text-underline-offset: 3px;
  cursor: pointer;
  list-style: none;
}
.perf-why summary .ph {
  width: 14px;
  height: 14px;
  color: var(--color-muted);
}
.perf-why summary:hover,
.perf-why[open] summary {
  color: var(--color-ink);
}
.perf-why summary:focus-visible {
  outline: 2px solid var(--color-ink);
  outline-offset: 2px;
  border-radius: var(--radius-pill);
}
.perf-tip {
  position: absolute;
  top: calc(100% + 8px);
  right: 0;
  left: 0;
  z-index: 5;
  padding: 16px 20px;
  border: 1px solid var(--color-edge);
  border-radius: var(--radius-24);
  background: var(--color-paper);
  box-shadow: var(--shadow-float);
  color: var(--color-ink);
  font-size: var(--text-small);
  line-height: var(--leading-small);
}

/* ── before the shop is shown: a whole-page moment, Nejma waiting at 132 (portalSmallPages/
   preparingWide's card, the page's only character) ── */
.card.empty.perf-none {
  gap: 0;
  padding: 72px 24px;
}
.perf-none .perf-waiting {
  flex: none;
  width: 132px;
  height: 132px;
  margin-bottom: 16px;
}
.perf-none b {
  max-width: 520px;
  color: var(--color-ink);
  font-size: var(--text-heading);
  font-weight: var(--font-weight-bold);
  line-height: var(--leading-heading);
  letter-spacing: var(--tracking-heading);
}
.perf-none .muted {
  max-width: 520px;
  margin-top: 8px;
  color: var(--color-ink-2);
  font-size: var(--text-body);
  line-height: var(--leading-body);
}

/* a large phone, a small tablet: the figures side by side, the cards roomier, the chart for
   every row */
@media (min-width: 640px) {
  .perf-page {
    gap: 24px;
  }
  .perf-card {
    padding: 24px;
  }
  .card.perf-unlock {
    padding: 28px;
  }
  .perf-card .perf-rows {
    margin: 0 -24px;
  }
  .row.perf-row,
  .perf-group {
    padding-right: 24px;
    padding-left: 24px;
  }
  .perf-group + .row.perf-row {
    border-top: 1px solid var(--color-edge);
  }
  .perf-group {
    border-top: 1px solid var(--color-edge);
  }
  .perf-pager {
    margin: -16px -24px 0;
    padding: 16px 24px 0;
  }
  .perf-rows > .perf-locked {
    padding-right: 24px;
    padding-left: 24px;
  }
  /* The chart shows from here on, and a row's click opens its product there. */
  .perf-row.clickable {
    cursor: pointer;
  }
  .perf-figs {
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 16px;
  }
  .perf-fig {
    gap: 16px;
    padding: 20px;
  }
  .perf-action {
    grid-template-columns: 22px var(--size-tile) minmax(0, 1fr) auto;
    grid-template-areas: "n img body go";
    column-gap: 14px;
    align-items: center;
  }
  .perf-history:not(:target) {
    display: flex;
  }
  .perf-snippet,
  .perf-send {
    flex-wrap: nowrap;
  }
  .perf-snippet .btn,
  .perf-send .btn {
    width: auto;
  }
  .perf-why {
    position: relative;
  }
  .perf-cardhead {
    position: static;
  }
  .perf-tip {
    left: auto;
    width: min(360px, 80vw);
  }
  /* In the chart's drawing space, as above: 10 of its 760 read 13.6 px at 1440, the board's
     Small. */
  .perf-chart text {
    font-size: 10px;
  }
  .perf-chart .dot-mine {
    r: 4.5;
  }
  .perf-chart .dot-move {
    r: 4;
  }
}

/* a laptop: the unlock steps side by side */
@media (min-width: 900px) {
  .perf-steps {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 32px;
  }
}

/* a wide screen: the positions' chips at the title's right */
@media (min-width: 1100px) {
  #position > .perf-cardhead {
    display: flex;
  }
  #position > .perf-cardhead > div:first-child {
    flex: 1 1 280px;
  }
}

/* The positions as a table, the head over its columns, only where the name keeps at least 200
   of its own (the seat's ruling of 18 Nov, 20:15, lifts the page's three breakpoints for this one
   rule): narrower figures and a shorter sparkline from 1220, the board's columns from 1360.
   Narrower, the rows stay the stacked block above. */
@media (min-width: 1220px) {
  :root {
    --perf-cols: var(--size-tile) minmax(0, 1fr) 76px 68px 68px 104px 112px 64px 36px;
  }
  .row.perf-row,
  .head.perf-row {
    display: grid;
    grid-template-columns: var(--perf-cols);
    column-gap: 12px;
    row-gap: 0;
    align-items: center;
  }
  .row.perf-row .perf-spark {
    width: 64px;
  }
  .head.perf-row {
    padding: 12px 24px;
  }
  .head.perf-row .perf-num {
    color: inherit;
    font: inherit;
    white-space: normal;
  }
  .head.perf-row + .row.perf-row {
    border-top: 1px solid var(--color-edge);
  }
  .row.perf-row::before {
    content: none;
  }
  .row.perf-row .namecell {
    margin: 0;
  }
  .row.perf-row .perf-num {
    display: block;
    width: auto;
    min-width: 0;
    margin-top: 0;
    order: 0;
  }
  .row.perf-row .perf-num::before {
    content: none;
  }
  .perf-acts {
    order: 0;
  }
  .perf-gap {
    display: flex;
    align-items: baseline;
    gap: 6px;
  }
  .row.perf-row .perf-num.perf-gap {
    display: flex;
  }
}
@media (min-width: 1360px) {
  :root {
    --perf-cols: var(--size-tile) minmax(0, 1fr) 80px 84px 84px 104px 112px 96px 36px;
  }
  .row.perf-row,
  .head.perf-row {
    column-gap: 16px;
  }
  .row.perf-row .perf-spark {
    width: 96px;
  }
}
