/* The original table/card layout is shared; these rules only support static twins. */
body[data-rendering="static"] [hidden] { display: none !important; }
[data-static-list] { min-width: 0; scroll-margin-top: 1rem; }
[data-static-list] .static-mobile { display: none; }
[data-static-list] .character-card-value { white-space: normal; overflow-wrap: anywhere; }
[data-static-list] [data-static-count] { font-size: .8rem; text-align: right; margin: .5rem 0; }
[data-static-list] [data-static-reset] { font: inherit; cursor: pointer; }
[data-static-list] button:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }
[data-static-list] .character-detail { padding: 10px; }
@media (max-width: 850px) {
  [data-static-list] .static-desktop { display: none; }
  [data-static-list] .static-mobile { display: block; }
}

body[data-rendering="static"] .static-page-kind { display: inline-block; }

/* Static lists have two to four columns; legacy two-column widths hide later fields. */
[data-static-list] .character-table { min-width: 0; }
[data-static-list] .character-table tr > :is(th, td):nth-child(n):not([colspan]) { width: auto; }

/* A single detail uses the full row instead of leaving an empty second column. */
[data-static-list] .character-detail:has(> .character-detail-item:only-child) { grid-template-columns: minmax(0, 1fr); }

/* Keep the comparison area readable immediately above the card breakpoint. */
@media (min-width: 851px) and (max-width: 1100px) {
  body[data-rendering="static"] .layout-shell { gap: 16px; }
  body[data-rendering="static"] .main-content { padding-left: 40px; padding-right: 16px; }
  body[data-rendering="static"] .right-ad { width: 200px; }
  body[data-rendering="static"] .ad-disclosure { white-space: normal; }
  [data-static-list] .character-detail { grid-template-columns: minmax(0, 1fr); }
}
