/* preset css: card-grid — cards v2 (2026-11-05, rev 2). The card body, band, veil, bar and stroke run come from
   card-fx.css; this file lays a COPY card out as band (display icon / numeral + visual) over copy, and makes copy cards
   fill the safe height. Tokens only.
   © Dudoxx UG / Acceleate Consulting - Walid Boudabbous <walid@acceleate.com> */
.cards { perspective: 150cqw; }
/* fill: the grid takes the height the head leaves; rows share it (3 cards = 3 tall cards, 6 = two tall rows) */
.scene.stack > .cards.cards--fill { flex: 1 1 auto; min-height: 0; margin-block: 0; grid-auto-rows: minmax(0, 1fr); align-items: stretch; }
.cards--fill .card.cfx-card { display: flex; flex-direction: column; gap: 0.9cqw; padding: 1.2cqw 1.2cqw 1.8cqw; min-height: 0; }
.cards--fill .cfx-band { flex: 1 1 auto; align-items: flex-end; min-height: 6.4cqw; }
.cards--fill .cfx-band > .ik, .cards--fill .cfx-band > .cfx-ico--static, .cards--fill .cfx-band > .cfx-numeral { align-self: flex-start; }
.cards--fill .cfx-band .card-num { position: absolute; right: 1cqw; top: 0.9cqw; }
.cards--fill .card-head { margin: 0 0 0.3cqw; }
.cards--fill .card-copy { display: grid; gap: 0.35cqw; padding: 0 0.6cqw; min-width: 0; }
/* type: one display focal per card — the stat when there is one, else the title; copy >= the label floor */
.cards--fill .card h3 { font-size: calc(var(--fs-title) * 1.05); line-height: 1.12; letter-spacing: -0.015em; padding-right: 0; }
.cards--fill.cards--few .card h3 { font-size: calc(var(--fs-title) * 1.22); }
.cards--fill .card p { font-size: max(var(--fs-label), 1.55cqw); line-height: 1.32; }
.cards--fill .card-stat:not(.is-long) { font-family: var(--face-head); font-size: calc(var(--fs-title) * 1.5); font-weight: 700; letter-spacing: -0.025em; line-height: 1.05;
  padding-block: 0.08em; color: var(--brand-color-link, var(--accent)); }
.look-studio .cards--fill .card-stat:not(.is-long), .stage.on-dark .cards--fill .card-stat:not(.is-long) { color: var(--brand-color-dark-link, var(--accent)); }
.cards--fill.cards--few .card-stat:not(.is-long) { font-size: calc(var(--fs-title) * 1.9); }
.cards--fill.cards--few .cfx-band .ik.ik--tile { --ik-size: 5cqw; }
/* the band visual / chips sit right of the display icon, bottom-aligned */
.cards--fill .card-viz { min-height: 3.8cqw; padding-right: 0.4cqw; }
.cards--fill .card-viz.kpi-viz--spark { height: 4.4cqw; }
.cards--fill .card-viz.kpi-viz--ring { flex: 0 0 auto; width: 4.6cqw; aspect-ratio: 1; height: auto; margin-left: auto; align-self: flex-end; }
.cards--fill .card-chips { flex: 1 1 auto; justify-content: flex-end; align-self: flex-end; }
.cards--four.cards--fill .card h3 { font-size: var(--fs-title); }
/* 5-8 cards (two rows): the card turns sideways — the band is a left column (icon on top, visual under it), the copy a
   right column — so a row of ~13cqw always holds title + stat + copy without clipping */
.cards--fill:not(.cards--few) .card.cfx-card { flex-direction: row; align-items: stretch; gap: 1cqw; padding: 0.9cqw 0.9cqw 1.3cqw; }
.cards--fill:not(.cards--few) .cfx-band { flex: 0 0 38%; flex-direction: column; align-items: flex-start; justify-content: space-between; min-height: 0; padding: 0.9cqw; gap: 0.6cqw; }
.cards--fill:not(.cards--few) .cfx-band > .cfx-viz { flex: 0 1 auto; width: 100%; align-self: stretch; }
.cards--fill:not(.cards--few) .cfx-band .ik.ik--tile { --ik-size: 3.4cqw; }
.cards--fill:not(.cards--few) .card-viz { min-height: 2.6cqw; }
.cards--fill:not(.cards--few) .card-viz.kpi-viz--spark { height: 3cqw; }
.cards--fill:not(.cards--few) .card-viz.kpi-viz--ring { width: 3.6cqw; margin-left: 0; align-self: flex-end; }
.cards--fill:not(.cards--few) .card-chips { align-self: stretch; width: 100%; justify-content: flex-start; gap: 0.35cqw; }
.cards--fill:not(.cards--few) .cfx-stack-chip { font-size: var(--fs-eyebrow); padding: 0.2em 0.55em; gap: 0.35em; }
.cards--fill:not(.cards--few) .card-copy { flex: 1 1 auto; align-content: center; padding: 0 0.3cqw 0 0; }
.cards--fill:not(.cards--few) .card-head { margin: 0 0 0.2cqw; }
.cards--fill:not(.cards--few) .card-stat:not(.is-long) { font-size: calc(var(--fs-title) * 1.2); }
.cards--fill:not(.cards--few) .cfx-numeral { font-size: 3.2cqw; }
/* photo cards, one row (1-4): head + grid fit the safe height — the grid may shrink, the card is a column and the photo
   strip (2:1 at most) gives height first, down to a 6cqw floor, so the scene never measures an overflow and glides the
   kicker up under the strap (commfr toc-b1, 2026-11-05). Copy keeps its natural height. Phone keeps its 2-col layout. */
@media not all and (max-width: 600px) and (orientation: portrait) {
  .scene.stack > .cards.cards--photos.cards--few { flex: 0 1 auto; min-height: 0; grid-template-rows: minmax(0, 1fr); }
  .cards--photos.cards--few > .card.has-img { display: flex; flex-direction: column; min-height: 0; }
  .cards--photos.cards--few > .card.has-img > .card-img { flex: 0 1 auto; min-height: 6cqw; }
}
@media (max-width: 600px) and (orientation: portrait) {
  .stage .cards--fill .card.cfx-card { gap: 1.4cqw; padding: 2cqw 2cqw 3cqw; }
  .stage .cards--fill .cfx-band { min-height: 12cqw; padding: 2cqw; gap: 2cqw; }
  .stage .cards--fill .cfx-band .ik.ik--tile, .stage .cards--fill.cards--few .cfx-band .ik.ik--tile { --ik-size: 9cqw; }
  .stage .cards--fill .cfx-band .card-num { right: 1.6cqw; top: 1.4cqw; }
  .stage .cards--fill .card h3, .stage .cards--fill.cards--few .card h3 { font-size: var(--fs-title); }
  .stage .cards--fill .card-stat:not(.is-long), .stage .cards--fill.cards--few .card-stat:not(.is-long) { font-size: calc(var(--fs-title) * 1.3); }
  .stage .cards--fill .card-viz { min-height: 7cqw; }
  .stage .cards--fill .card-viz.kpi-viz--spark { height: 8cqw; }
  .stage .cards--fill .card-viz.kpi-viz--ring { width: 9cqw; }
  .stage .cfx-numeral { font-size: 8cqw; }
  .stage .cards--fill .cfx-chips { gap: 1cqw; }
}
