/*
 * Comparison pages only (/compare.html and /capifiq-vs-*.html built by
 * scripts/compare-pages/build.py). Loaded after pages.css.
 *
 * On a phone the shared .comparison-table keeps its desktop width and scrolls
 * sideways, which hides the competitor column entirely. Tables marked
 * .comparison-table--stack become one card per row instead; each cell carries a
 * data-label copied from its column header.
 */
@media (max-width: 760px) {
  .comparison-table-wrap:has(.comparison-table--stack) {
    overflow: visible;
    border: 0;
    border-radius: 0;
    background: transparent;
    box-shadow: none;
  }
  .comparison-table--stack,
  .comparison-table--stack tbody,
  .comparison-table--stack tr,
  .comparison-table--stack td {
    display: block;
    width: 100%;
    min-width: 0;
  }
  .comparison-table--stack { background: transparent; }
  .comparison-table--stack thead {
    position: absolute;
    width: 1px;
    height: 1px;
    overflow: hidden;
    clip: rect(0 0 0 0);
    white-space: nowrap;
  }
  .comparison-table--stack tr {
    margin-bottom: 12px;
    border: 1px solid var(--cf-light-border-subtle);
    border-radius: 14px;
    overflow: hidden;
    background: #fff;
  }
  .comparison-table--stack td {
    padding: 14px 16px;
    border-right: 0;
  }
  .comparison-table--stack tbody td:first-child {
    position: static;
    width: 100%;
    min-width: 0;
    font-size: 15px;
    border-bottom: 1px solid var(--cf-light-border-subtle);
  }
  .comparison-table--stack td[data-label]:not(:first-child)::before {
    content: attr(data-label);
    display: block;
    margin-bottom: 6px;
    color: var(--cf-light-text-muted);
    font-family: var(--cf-font-mono);
    font-size: 11px;
    letter-spacing: .08em;
    text-transform: uppercase;
  }
  .comparison-table--stack .cell-copy small { font-size: 13px; }
}
