/* Printable generators (/tambola-ticket-generator, /bingo-card-generator).
   On screen: paper-white tickets on the site's plum. In print: black on white,
   two tickets/cards per row, nothing but the tickets. */
.tool-panel { background: var(--card); border: 1px solid var(--line); border-radius: 16px; padding: 18px 20px; margin: 18px 0 22px; }
.tool-row { display: flex; flex-wrap: wrap; gap: 12px; align-items: end; }
.tool-row label { display: flex; flex-direction: column; gap: 6px; color: var(--muted); font-size: 14px; font-weight: 600; }
.tool-row input[type=number] { font: inherit; font-weight: 700; width: 110px; padding: 10px 12px; border-radius: 10px; border: 1px solid var(--line); background: var(--plum); color: var(--cream); }
.tool-row .check { flex-direction: row; align-items: center; gap: 8px; padding-bottom: 12px; }
.btn { font: inherit; font-weight: 700; border: 1px solid var(--line); background: rgba(255,255,255,.08); color: var(--cream); padding: 11px 18px; border-radius: 12px; cursor: pointer; }
.btn:hover { background: rgba(255,255,255,.14); }
.btn.primary { background: var(--orange); border-color: transparent; color: #fff; }
.tool-summary { color: var(--muted); font-size: 14px; margin-top: 12px; }
.tool-summary b { color: var(--gold); letter-spacing: 1px; }

#out { display: grid; gap: 22px; }
.strip { display: grid; grid-template-columns: repeat(auto-fill, minmax(300px, 1fr)); gap: 12px; padding: 12px; border: 1px dashed var(--line); border-radius: 14px; }
#out:not(.tambola) { grid-template-columns: repeat(auto-fill, minmax(240px, 1fr)); }
.ticket, .card { background: #FFF8EE; color: var(--plum); border-radius: 10px; padding: 8px 10px 10px; box-shadow: 0 4px 14px rgba(0,0,0,.25); break-inside: avoid; }
.ticket-head { display: flex; justify-content: space-between; align-items: baseline; font-size: 11px; color: #6B5A5F; margin-bottom: 6px; }
.ticket-id { font-weight: 800; letter-spacing: 1.5px; color: var(--plum); font-size: 12px; }
table.grid90, table.grid75 { width: 100%; border-collapse: collapse; table-layout: fixed; }
table.grid90 td, table.grid75 td, table.grid75 th { border: 1px solid #5A4650; text-align: center; font-weight: 800; padding: 0; }
table.grid90 td { height: 34px; font-size: 16px; }
table.grid90 td.blank { background: repeating-linear-gradient(135deg, transparent 0 4px, rgba(90,70,80,.12) 4px 5px); }
table.grid75 th { height: 30px; font-size: 16px; background: var(--orange); color: #fff; border-color: #C9542A; letter-spacing: 1px; }
table.grid75 td { height: 44px; font-size: 18px; }
table.grid75 td.free { font-size: 11px; letter-spacing: 1px; background: rgba(244,183,64,.35); }
#out.large table.grid90 td { height: 46px; font-size: 22px; }
#out.large table.grid75 td { height: 58px; font-size: 26px; }
#out.large table.grid75 td.free { font-size: 13px; }

.cta-box { background: var(--card); border: 1px solid var(--line); border-radius: 16px; padding: 20px; margin: 30px 0 10px; text-align: center; }
.cta-box h2 { margin: 0 0 8px; }
.cta-box p { color: var(--muted); }
.cta-box .badge { margin-top: 10px; }

@media print {
  @page { margin: 12mm; }
  html, body { background: #fff !important; color: #000 !important; }
  .no-print, footer, .back, .tool-panel, .cta-box, .faq, .related, .jump, h1, .updated, .lede, .legal > p, .legal > h2 { display: none !important; }
  .wrap, .legal { max-width: none; padding: 0; margin: 0; }
  #out { display: block; }
  .strip { display: grid; grid-template-columns: 1fr 1fr; gap: 6mm; border: 0; padding: 0; margin-bottom: 6mm; }
  #out:not(.tambola) { display: grid; grid-template-columns: 1fr 1fr; gap: 6mm; }
  .ticket, .card { background: #fff; color: #000; box-shadow: none; border: 1px solid #000; border-radius: 4px; page-break-inside: avoid; break-inside: avoid; }
  .ticket-head, .ticket-id { color: #000; }
  table.grid90 td, table.grid75 td, table.grid75 th { border-color: #000; color: #000; }
  table.grid75 th { background: #fff; -webkit-print-color-adjust: exact; print-color-adjust: exact; }
  table.grid90 td.blank { background: repeating-linear-gradient(135deg, transparent 0 3px, #ccc 3px 4px); -webkit-print-color-adjust: exact; print-color-adjust: exact; }
  table.grid75 td.free { background: #eee; -webkit-print-color-adjust: exact; print-color-adjust: exact; }
  table.grid90 td { height: 11mm; font-size: 14pt; }
  table.grid75 td { height: 14mm; font-size: 16pt; }
  #out.large table.grid90 td { height: 13mm; font-size: 18pt; }
  #out.large table.grid75 td { height: 17mm; font-size: 22pt; }
}
