/* /how: the two cards on how the points add up and the tiers, then the
   table of every rule with its bands and its source. */

.how-grid { display: grid; grid-template-columns: minmax(0, 1.6fr) minmax(0, 1fr); gap: 12px; align-items: start; }
.how-grid .card p { margin-top: 10px; font-size: 15px; line-height: 22.5px; color: var(--ink-muted); }
.tiers { margin-top: 10px; }
.tier-row {
  display: flex; align-items: center; justify-content: space-between; gap: 12px; min-height: 44px;
  border-top: 1px solid var(--divider); font-size: 14px;
}
.tier-row:first-child { border-top: 0; }
.tier-range { color: var(--ink-2); }
.rules-card { margin-top: 12px; }
.main > .rules-card { width: min(var(--page-max), 100% - var(--gutter)); margin-inline: auto; }
.rules { width: 100%; margin-top: 10px; font-size: 14px; line-height: 20px; }
.rules th, .rules td { padding: 12px 10px; vertical-align: top; text-align: left; border-top: 1px solid var(--divider); }
.rules th:first-child, .rules td:first-child { padding-left: 0; }
.rules thead th { padding-top: 6px; padding-bottom: 10px; border-top: 0; color: var(--ink-muted); font-weight: var(--w-body); }
.rules tbody th { width: 30%; font-weight: var(--w-body); }
.rule-name { display: block; font-weight: var(--w-title); color: var(--ink); }
.rule-chain { margin-top: 6px; }
.bands li { padding: 1px 0; color: var(--ink-2); }
.rule-src { width: 18%; color: var(--ink-muted); }

/* Below 700px of card width each rule stacks: name and chain, its bands,
   then the source */
.rules-card { container: rules / inline-size; }
@container rules (max-width: 700px) {
  .rules thead { display: none; }
  .rules, .rules tbody, .rules tr, .rules th, .rules td { display: block; width: auto; }
  .rules tr { padding: 12px 0; border-top: 1px solid var(--divider); }
  .rules tbody tr:first-child { border-top: 0; }
  .rules th, .rules td { padding: 0; border: 0; }
  .rules .rule-points { margin-top: 8px; }
  .rules .rule-src { margin-top: 4px; }
  .rules .rule-src::before { content: "Source: "; }
}
