.formats {
  padding: clamp(calc(64px * var(--s, 1)), calc(8vw * var(--s, 1)), calc(120px * var(--s, 1))) 0;
  background: var(--bg);
}
.formats__head { max-width: calc(800px * var(--s, 1)); margin-bottom: clamp(calc(28px * var(--s, 1)), calc(3.4vw * var(--s, 1)), calc(44px * var(--s, 1))); }
.formats__head .h-1 { line-height: 1.05; }
.formats__lede { font-size: clamp(calc(17px * var(--s, 1)), calc(1.4vw * var(--s, 1)), calc(20px * var(--s, 1))); margin: calc(16px * var(--s, 1)) 0 0; }

/* Two rows of four, every card the same (Tom, 14 Nov 2026). */
.formats__grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: calc(16px * var(--s, 1));
  list-style: none;
  margin: 0;
  padding: 0;
}
.formats__item {
  display: flex;
  flex-direction: column;
  background: var(--paper);
  border: 1.5px solid var(--ink);
  border-radius: calc(14px * var(--s, 1));
  overflow: hidden;
}
.formats__item:nth-child(n+9) { display: none; }

/* Per-format picture: the same files the app shows (/format-thumbs, drawn by
   scripts/format-thumbs.mjs in the Fantenna palette), with no words in the
   image; the name is the live text below (FANTENNA-2747). It runs edge to
   edge across the top of the card, cropped to 3:2. */
.formats__diagram {
  width: 100%;
  aspect-ratio: 3 / 2;
  background: var(--paper-2);
  border-bottom: 1.5px solid var(--ink);
  overflow: hidden;
}
.formats__diagram img { display: block; width: 100%; height: 100%; object-fit: cover; }

.formats__body { padding: calc(16px * var(--s, 1)) calc(18px * var(--s, 1)) calc(20px * var(--s, 1)); }
.formats__name {
  font-family: var(--display);
  font-weight: 800;
  font-size: clamp(calc(18px * var(--s, 1)), calc(1.5vw * var(--s, 1)), calc(21px * var(--s, 1)));
  line-height: 1.2;
  letter-spacing: -0.02em;
  color: var(--ink);
  margin: 0;
}
.formats__caption {
  font-size: calc(17px * var(--s, 1));
  line-height: 1.4;
  color: var(--ink-2);
  margin: calc(6px * var(--s, 1)) 0 0;
}
.formats__foot {
  font-size: calc(17px * var(--s, 1));
  color: var(--ink-3);
  margin: calc(32px * var(--s, 1)) 0 0;
}

/* Two columns: three rows of two. */
@media (max-width: 1023px) {
  .formats__grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .formats__item:nth-child(n+7) { display: none; }
}

/* Phone: one column of row cards, picture on the left. */
@media (max-width: 559px) {
  .formats__grid { grid-template-columns: minmax(0, 1fr); gap: calc(12px * var(--s, 1)); }
  .formats__item {
    display: grid;
    grid-template-columns: calc(112px * var(--s, 1)) minmax(0, 1fr);
  }
  .formats__diagram {
    grid-row: 1 / span 2;
    aspect-ratio: auto; height: 100%; min-height: calc(96px * var(--s, 1));
    border-bottom: 0; border-right: 1.5px solid var(--ink);
  }
  .formats__body { padding: calc(12px * var(--s, 1)) calc(14px * var(--s, 1)); align-self: center; }
  .formats__name { font-size: calc(18px * var(--s, 1)); }
}
