/* =========================================================================
   Platform comparison (pages/compare.php) — layered on hub-d.css.
   Two brands side by side: each platform header carries its own --brand.
   ========================================================================= */
.hd-cmp { padding-bottom: 56px; }
.cx-hero h1 { margin-bottom: 10px; }
.cx-hero .lede { max-width: 72ch; }
.cx-pair { display: flex; flex-wrap: wrap; align-items: center; gap: 10px; margin-top: 18px; }
.cx-vs { font-size: 13px; font-weight: 700; color: var(--muted); text-transform: uppercase; letter-spacing: .08em; }
.cx-plat { display: inline-flex; align-items: center; gap: 8px; padding: 6px 12px 6px 6px; border-radius: 999px; background: var(--panel); border: 1px solid color-mix(in srgb, var(--brand) 35%, var(--line-strong)); font-weight: 700; font-size: 14px; color: var(--ink); white-space: nowrap; }
.cx-plat:hover { border-color: var(--brand); }
.cx-plat-logo { display: inline-flex; width: 26px; height: 26px; align-items: center; justify-content: center; border-radius: 999px; background: color-mix(in srgb, var(--brand) 12%, var(--panel)); }
th .cx-plat { padding: 3px 10px 3px 3px; font-size: 13px; }
th .cx-plat-logo { width: 22px; height: 22px; }

/* format-by-format table */
.cx-tbl { min-width: 760px; }
.cx-tbl th[scope="row"] a { font-weight: 700; color: var(--ink); }
.cx-tbl td { vertical-align: top; }
.cx-cell { display: grid; gap: 6px; }
.cx-cell-l { font-size: 13px; color: var(--muted); line-height: 1.3; }
.cx-cell-l:hover { color: var(--accent-ink); }
.cx-cell-spec { display: flex; flex-wrap: wrap; align-items: baseline; gap: 4px 10px; }
.cx-ratio { font-size: 13px; color: var(--muted); font-variant-numeric: tabular-nums; }
.cx-wt { font-size: 13px; font-weight: 600; color: var(--ink); }
.cx-verdict { display: inline-flex; align-items: center; gap: 6px; padding: 4px 10px; border-radius: 999px; font-size: 12.5px; font-weight: 700; white-space: nowrap; }
.cx-verdict::before { content: ''; width: 7px; height: 7px; border-radius: 50%; background: currentColor; }
.cx-verdict.is-same { color: var(--ok-ink); background: color-mix(in srgb, var(--ok) 13%, var(--panel)); }
.cx-verdict.is-ratio { color: var(--accent-ink); background: var(--accent-soft); }
.cx-verdict.is-diff { color: var(--warn-ink); background: color-mix(in srgb, var(--warn) 14%, var(--panel)); }
.cx-verdict.is-only { color: var(--muted); background: var(--panel-2); }

/* one creative set for both */
.cx-kit { min-width: 900px; }
.cx-kit tr.is-both th[scope="row"] { box-shadow: inset 3px 0 0 var(--ok); }
.cx-both { display: inline-block; margin-top: 6px; padding: 2px 8px; border-radius: 999px; font-size: 11px; font-weight: 700; color: var(--ok-ink); background: color-mix(in srgb, var(--ok) 13%, var(--panel)); }
.cx-kit .hd-covers { display: flex; flex-direction: column; align-items: flex-start; gap: 4px; }
.cx-kit .hd-covers small { color: var(--muted); font-weight: 500; }

/* checker card, full width */
.cx-checker .hd-ck-card { max-width: none; }
.cx-ck-row { display: grid; grid-template-columns: minmax(0, 1.2fr) minmax(0, 1fr); gap: 18px; align-items: start; }
.cx-checker .hd-result { margin-top: 14px; }
@media (max-width: 760px) { .cx-ck-row { grid-template-columns: 1fr; } }

/* text limits */
.cx-lim { min-width: 520px; }
.cx-lim td.hd-num { font-weight: 700; color: var(--ink); text-align: left; }

/* video side by side */
.cx-vid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 16px; }
.cx-vid-col { background: var(--panel); border: 1px solid var(--line-strong); border-radius: var(--radius); padding: 16px 18px; min-width: 0; }
.cx-vid-col h3 { margin-bottom: 10px; }
.cx-vid-col ul { list-style: none; margin: 0; padding: 0; display: grid; gap: 10px; }
.cx-vid-col li { display: grid; gap: 2px; }
.cx-vid-col li a { font-weight: 600; color: var(--ink); }
.cx-vid-col li a:hover { color: var(--accent-ink); }
.cx-vid-spec { font-size: 13px; color: var(--muted); }
@media (max-width: 760px) { .cx-vid { grid-template-columns: 1fr; } }

/* ---- phones: both tables become one card per row ----------------------------
   (hub-d.css turns .hd-kit into a 3-column card grid built for the hub's 6
   columns; the comparison kit has 7, with one "covers" cell per platform.) */
@media (max-width: 760px) {
  .cx-tbl, .cx-kit { min-width: 0; }
  .cx-tbl, .cx-tbl tbody, .cx-tbl tr, .cx-tbl th, .cx-tbl td { display: block; }
  .cx-tbl thead { display: none; }
  .cx-tbl tbody tr { padding: 14px 16px; border-bottom: 1px solid var(--line); }
  .cx-tbl tbody th, .cx-tbl tbody td { padding: 0; border: 0; }
  .cx-tbl tbody th { margin-bottom: 10px; font-size: 16px; }
  .cx-tbl tbody td + td { margin-top: 12px; }
  .cx-tbl td[data-label]::before,
  .cx-kit td[data-label]::before { content: attr(data-label); display: block; margin-bottom: 4px; font-size: 11px; font-weight: 700; letter-spacing: .05em; text-transform: uppercase; color: var(--muted); }

  .cx-kit tbody tr { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .cx-kit td:nth-child(2) { order: 1; }                         /* master size */
  .cx-kit td:nth-child(4) { order: 2; }                         /* max weight */
  .cx-kit td:nth-child(5) { order: 3; grid-column: 1 / -1; }    /* formats */
  .cx-kit td:nth-child(3) { order: 4; grid-column: 1 / -1; }    /* exports */
  .cx-kit td:nth-child(6) { order: 5; grid-column: 1 / -1; }    /* platform A */
  .cx-kit td:nth-child(7) { order: 6; grid-column: 1 / -1; display: block; }  /* platform B */
  .cx-kit th[scope="row"] { gap: 8px; }
  .cx-kit tr.is-both th[scope="row"] { padding-left: 11px; }
  .cx-kit .cx-both { margin-top: 0; }
  .cx-lim { min-width: 0; }
}

/* ---- one creative set: a list, one row per layout (long labels wrap as prose) */
.cx-promo { margin-top: 28px; }
.cx-kitlist { list-style: none; margin: 0; padding: 0; background: var(--panel); border: 1px solid var(--line-strong); border-radius: var(--radius); box-shadow: var(--shadow-sm); overflow: hidden; }
.cx-kitrow { display: grid; grid-template-columns: 190px minmax(0, 1fr); gap: 8px 22px; padding: 14px 18px; border-top: 1px solid var(--line); }
.cx-kitrow:first-child { border-top: 0; }
.cx-kitrow.is-both { box-shadow: inset 3px 0 0 var(--ok); }
.cx-kr-meta { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; min-width: 0; }
.cx-kr-meta .cx-both { margin-top: 0; }
.cx-kr-body { min-width: 0; }
.cx-kr-spec { display: flex; flex-wrap: wrap; align-items: center; gap: 6px 20px; }
.cx-kr-spec > span { display: inline-flex; flex-wrap: wrap; align-items: center; gap: 6px; }
.cx-kr-k { font-size: 11px; font-weight: 700; letter-spacing: .05em; text-transform: uppercase; color: var(--muted); }
.cx-kr-capfor { font-size: 12px; color: var(--muted); }
.cx-kr-plat { margin: 8px 0 0; font-size: 13.5px; line-height: 1.6; color: var(--ink); overflow-wrap: anywhere; }
.cx-kr-plat a { color: var(--accent-ink); }
.cx-kr-plat a:hover { text-decoration: underline; }
.cx-kr-plat small { color: var(--muted); font-size: 12px; font-variant-numeric: tabular-nums; }
.cx-kr-plat a[data-fit="pass"] { color: var(--ok-ink); font-weight: 600; }
.cx-kr-plat a[data-fit="pass"]::after { content: ' ✓'; }
.cx-kr-plat a[data-fit="warn"] { color: var(--warn-ink); }
.cx-kr-plat a[data-fit="fail"] { opacity: .45; }
.cx-sep { margin: 0 6px; color: var(--faint); }
.cx-mini { display: inline-flex; align-items: center; gap: 5px; margin-right: 8px; font-weight: 700; color: var(--ink); white-space: nowrap; }
.cx-mini-logo { display: inline-flex; width: 20px; height: 20px; align-items: center; justify-content: center; border-radius: 999px; background: color-mix(in srgb, var(--brand) 12%, var(--panel)); }
@media (max-width: 760px) {
  .cx-kitrow { grid-template-columns: minmax(0, 1fr); padding: 14px 16px; }
  .cx-kitrow.is-both { padding-left: 19px; }
}
