/* The one-page cheat sheet (4 Dec 2026; templates/cheat_sheet.html). On the screen it is a sheet of paper that narrows to
   fit a phone. Printed, it is one US Letter page: the page's own margins, no site header or footer, and a small
   address at the bottom so a printed copy brings people back. */
.cheat { --cs-ink: #232019; --cs-soft: #5c5445; --cs-line: #d9cfb8; --cs-felt: #35693f; --cs-wash: #f4efe3;
  display: grid; justify-items: center; gap: 1.2rem; padding: 0 12px 2rem; }
.cheat .share-line { width: 100%; max-width: 8.5in; margin: 0; }
.cs-screen { width: 100%; max-width: 8.5in; }
.cs-intro { font-size: 1.1rem; color: var(--ink-soft, #5c5445); margin: 0 0 0.8rem; }
.cs-screen .actions { display: flex; flex-wrap: wrap; gap: 0.7rem; margin: 0; }

.cs-sheet { width: 100%; max-width: 8.5in; padding: 0.4in 0.5in 0.3in; background: #fff; color: var(--cs-ink);
  border: 1px solid var(--cs-line); box-shadow: var(--shadow-md, 0 4px 14px rgba(40, 30, 10, .12)); font-size: 10.5pt; line-height: 1.4; }
.cs-sheet *, .cs-sheet *::before, .cs-sheet *::after { box-sizing: border-box; }
.cs-sheet p { margin: 0; }
.cs-top { border-bottom: 2px solid var(--cs-felt); padding-bottom: 0.1in; margin-bottom: 0.12in; }
.cs-brand { font-size: 8pt; letter-spacing: 0.08em; text-transform: uppercase; font-weight: 700; color: var(--cs-felt); }
.cs-top h1 { font-size: 24pt; line-height: 1.1; margin: 0.02in 0 0.02in; }
.cs-sub { color: var(--cs-soft); font-size: 10.5pt; }
.cs-sheet h2 { font-size: 13pt; margin: 0 0 0.07in; display: flex; align-items: center; gap: 0.08in; }
.cs-sheet h3 { font-size: 10.5pt; margin: 0 0 0.04in; }
.cs-n { display: inline-grid; place-items: center; width: 1.5em; height: 1.5em; border-radius: 50%; background: var(--cs-felt);
  color: #fff; font: 700 9.5pt var(--font, inherit); flex: none; }
.cs-block { margin-bottom: 0.14in; }

/* the tiles: the site's own art, drawn by cardlines.js */
.cs-sheet .figure { --tile-scale: 0.58; gap: 3px; }
.cs-sheet .figure .tile { box-shadow: 0 1px 0 var(--tile-shadow, rgba(60, 45, 25, .28)), 0 1px 3px rgba(30, 24, 12, .22); }
.cs-sheet .figure .figure-group { gap: 2px; }
.cs-sheet .cs-small { --tile-scale: 0.46; }
.cs-row { display: grid; grid-template-columns: 0.95in auto 1.05in auto 1fr; gap: 0.12in; align-items: center; padding: 0.045in 0;
  border-bottom: 1px solid var(--cs-line); }
.cs-name span { display: block; color: var(--cs-soft); font-size: 8.5pt; }
.cs-note { font-size: 8.5pt; color: var(--cs-soft); line-height: 1.25; }
.cs-note strong { color: var(--cs-ink); }
.cs-extra { display: grid; grid-template-columns: auto auto auto 1fr; gap: 0.3in; align-items: center; padding-top: 0.07in; }
.cs-extra > div { display: flex; align-items: center; gap: 0.1in; }
.cs-sum { font-size: 8.5pt; color: var(--cs-soft); text-align: right; }
.cs-sum strong { color: var(--cs-ink); }

/* the groups and the Charleston, side by side */
.cs-pair { display: grid; grid-template-columns: 1.1fr 1fr; gap: 0.25in; }
.cs-groups { width: 100%; border-collapse: collapse; font-size: 9.5pt; }
.cs-groups th, .cs-groups td { border-bottom: 1px solid var(--cs-line); padding: 0.04in 0.05in; text-align: left; vertical-align: middle; }
.cs-groups thead th { font-size: 8pt; text-transform: uppercase; letter-spacing: 0.04em; color: var(--cs-soft); background: var(--cs-wash); }
.cs-groups tbody th span { display: block; font-weight: 400; font-size: 8pt; color: var(--cs-soft); }
.cs-yes { color: #1a7a44; font-weight: 700; }
.cs-no { color: #b02a2f; font-weight: 700; }
.cs-rule { font: 700 11pt var(--display, inherit); margin: 0.08in 0 0.04in !important; padding: 0.06in 0.1in; border: 2px solid var(--cs-felt); border-radius: 8px; }
.cs-list { margin: 0; padding-left: 1.1em; font-size: 9pt; display: grid; gap: 0.03in; }
.cs-char { display: grid; gap: 0.06in; }
.cs-pass { border: 1px solid var(--cs-line); border-radius: 8px; padding: 0.05in 0.1in; }
.cs-pass h3 span { font: 400 8.5pt var(--font, inherit); color: var(--cs-soft); margin-left: 0.2em; }
.cs-pass ol { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(3, 1fr); gap: 0.05in; counter-reset: pass; }
.cs-pass li { display: flex; flex-direction: column; align-items: center; font-weight: 700; font-size: 9pt; text-align: center; }
.cs-pass li::before { counter-increment: pass; content: counter(pass); font-size: 7.5pt; color: var(--cs-soft); }
.cs-pass small { font: 400 7.5pt var(--font, inherit); color: var(--cs-soft); }
.cs-courtesy p { display: flex; align-items: center; gap: 0.08in; font-size: 8.5pt; }
.cs-arrow { width: 0.36in; height: 0.36in; color: var(--cs-felt); flex: none; }
.cs-fine { font-size: 8.5pt; color: var(--cs-soft); margin-top: 0.05in !important; }
.cs-turn { font-size: 11pt; font-weight: 700; }
.cs-foot { display: flex; justify-content: space-between; gap: 0.2in; border-top: 1px solid var(--cs-line); padding-top: 0.06in;
  font-size: 8.5pt; color: var(--cs-soft); }
.cs-foot strong { color: var(--cs-ink); }

@media (max-width: 700px) {
  .cs-sheet { padding: 0.3in 0.2in; }
  .cs-sheet .figure { --tile-scale: 0.4; }
  .cs-sheet .cs-small { --tile-scale: 0.36; }
  .cs-row { grid-template-columns: 1fr; gap: 0.04in; padding: 0.08in 0; }
  .cs-extra { grid-template-columns: 1fr; gap: 0.1in; }
  .cs-sum { text-align: left; }
  .cs-pair { grid-template-columns: 1fr; }
  .cs-foot { flex-direction: column; }
}

@media print {
  @page { size: Letter; margin: 0.4in; }
  html, body { background: #fff !important; }
  main:has(.cheat) { padding: 0 !important; max-width: none !important; margin: 0 !important; }
  .cheat { display: block; padding: 0; }
  .cs-screen, .share-line, .no-print, .feedback-tab { display: none !important; }
  .cs-sheet { max-width: none; width: 100%; padding: 0; border: 0; box-shadow: none; break-inside: avoid; }
  /* the site's print rules hide every footer; the sheet's own address line is the point of a printed copy */
  .cs-sheet .cs-foot { display: flex !important; margin-top: 0.1in; }
  .cs-pass, .cs-groups tr, .cs-row { break-inside: avoid; }
}
