/* pa-grid.css · 30 Nov 2026 (Mikky: "big empty spaces inside cards"). Where each card sits is set by js/views/pa-grid.js; this file
   holds what it needs: rows that take up a small leftover, one-line notes, and the full-width partner audience. Screen only. */

/* a leftover too small to see is shared out between the rows of the card's own chart (--gf: px per row, set per card) */
body:not(.rp-body) .ovc[style*="--gf"] .ovrs { row-gap: calc(4px + var(--gf) * 1px); }
body:not(.rp-body) .ovc .skrp > ol:last-child { margin-bottom: 0; }
body:not(.rp-body) .ovc[style*="--gf"] .skrp :is(ol:not(:last-child) > li, li:not(:last-child)) { min-height: calc(32px + var(--gf) * 1px); }
body:not(.rp-body) .ovc[style*="--gf"] .skmv > li { padding-block: calc(var(--gf) * .5px); }
body:not(.rp-body) .ovc[style*="--gf"] .ocv1-p { height: calc(168px + var(--gf) * 1px); }
body:not(.rp-body) .ovc[style*="--gf"] .pa-geo { margin-top: calc(var(--space-3) + var(--gf) * .5px); }
body:not(.rp-body) .ovc[style*="--gf"] .pa-geo__m { margin-bottom: calc(var(--gf) * .5px); }

/* a card with nothing to chart: one line when it has the row to itself, and a short note under its neighbor when it doesn't */
body:not(.rp-body) .ovc.is-note .pa-st { display: flex; flex-wrap: wrap; align-items: center; gap: var(--space-1) var(--space-3); padding: 0 0 0 28px; }
body:not(.rp-body) .ovc.is-note .pa-st :is(h3, p) { font-size: var(--font-size-13); line-height: 20px; max-width: none; }
body:not(.rp-body) .ovc.is-note .pa-st > .gi { flex: none; }
body:not(.rp-body) .pa-card[data-state="not-tracked"] .pa-st { display: flex; flex-wrap: wrap; align-items: center; gap: var(--space-1) var(--space-3); padding: 0 0 0 28px; }
body:not(.rp-body) .pa-card[data-state="not-tracked"] .pa-st > p { order: -1; flex: 1 1 100%; max-width: none; }
body:not(.rp-body) .ovc.is-note[data-state="not-tracked"] .pa-st > p { order: 0; flex: 0 1 auto; }

/* partner page, Who we reached: Age, Country and Home area on one top line */
@container page (min-width: 901px) {
  body:not(.rp-body) .pa-blocks2 > .pa-card[data-card*="-audience-"]:not([data-state]) { grid-column: 1 / -1; }
  body:not(.rp-body) .pa-blocks2 > .pa-card[data-card*="-audience-"]:not([data-state]) .pa-card__b { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); column-gap: var(--space-8); align-items: start; }
  body:not(.rp-body) .pa-blocks2 > .pa-card[data-card*="-audience-"] .pa-card__b > .pa-2col { display: contents; }
  body:not(.rp-body) .pa-blocks2 > .pa-card[data-card*="-audience-"] .pa-card__b > :is(.ovc-k, .pa-card__f) { grid-column: 1 / -1; }
  body:not(.rp-body) .pa-blocks2 > .pa-card[data-card*="-audience-"] .pa-sub { margin-top: 0; }
}

/* a long table opened in half a row scrolls in its own pane, so a 30-day list never stretches its neighbor by 900px */
body:not(.rp-body) .ovc.is-half > details .dtable__s { max-height: 320px; overflow-y: auto; overscroll-behavior: contain; }
body:not(.rp-body) .ovc.is-half > details .dtable__s:focus-visible { outline: 2px solid var(--color-border-focus); outline-offset: 2px; }

/* ── 30 Nov (Mikky, "too much text" + "remove this unnecessary spacing"): Audience segments. Mark, name and a short line in a fixed
   first column; the players bar takes the free width so the chart leads; Share, Change and the weekly line sit tight on the right. ── */
body:not(.rp-body) .pa-tbl--seg { width: 100%; table-layout: fixed; }
body:not(.rp-body) .pa-tbl--seg th:nth-child(1) { width: 220px; }
body:not(.rp-body) .pa-tbl--seg th:nth-child(3) { width: 64px; }
body:not(.rp-body) .pa-tbl--seg th:nth-child(4) { width: 84px; }
body:not(.rp-body) .pa-tbl--seg th:nth-child(5) { width: 124px; }
body:not(.rp-body) .pa-tw:not(.is-stack) .pa-tbl--seg td:has(.pa-inl) { padding-left: var(--space-3); }
body:not(.rp-body) .pa-tw:not(.is-stack) .pa-tbl--seg td .pa-inl { left: var(--space-3); right: 88px; width: auto; }
body:not(.rp-body) .pa-tbl--seg td.n { font-weight: var(--font-weight-medium); }
body:not(.rp-body) .pa-tbl--seg .pa-segsp { margin-left: auto; }
body:not(.rp-body) .pa-segn { display: inline-flex; align-items: center; gap: var(--space-3); max-width: 100%; border-radius: 4px; cursor: default; }
body:not(.rp-body) .pa-segn > .gi { flex: none; }
body:not(.rp-body) .pa-segn__t { display: flex; flex-direction: column; min-width: 0; }
body:not(.rp-body) .pa-segn__t > b { font-weight: var(--font-weight-medium); color: var(--color-text-primary); }
body:not(.rp-body) .pa-segn__t > .pa-cellsub { margin-top: 1px; overflow: hidden; text-overflow: ellipsis; }
body:not(.rp-body) .pa-segn:focus-visible { outline: 2px solid var(--color-border-focus); outline-offset: 2px; }
/* the folded-groups line: short on screen, the rule in its tip */
body:not(.rp-body) .pa-foldn { display: inline-flex; align-items: center; gap: 6px; border-radius: 4px; cursor: default; }
body:not(.rp-body) .pa-foldn .pa-lock { fill: none; stroke: currentColor; }
