/* Ispis: samo #print, uvijek svijetla podloga. */
#print { display: none; }

@page { size: A4; margin: 10mm; }

@media print {
  html, body { background: #fff !important; color: #000 !important; }
  body > *:not(#print) { display: none !important; }
  #print { display: block; font-family: 'Lexend', Arial, sans-serif; color: #000; background: #fff; }

  /* Kartice: 2×3 po stranici */
  .print-page { display: grid; grid-template-columns: 1fr 1fr; grid-template-rows: repeat(3, 90mm); width: 190mm; break-after: page; page-break-after: always; }
  .print-page:last-child { break-after: auto; page-break-after: auto; }
  .pcard { box-sizing: border-box; border: 1px dashed #777; margin: -0.5px; display: flex; flex-direction: column; align-items: center; justify-content: center; padding: 8mm; overflow: hidden; }
  .pcard-img { flex: 1; min-height: 0; width: 100%; display: flex; align-items: center; justify-content: center; }
  .pcard-img img { max-width: 100%; max-height: 62mm; object-fit: contain; border: 1px solid #ddd; }
  .pcard-sym { justify-content: flex-start; padding-bottom: 3mm; }
  .pcard-sym .pcard-img img { max-height: 58mm; }
  /* Crta za presavijanje/rezanje: ime je ispod nje, dijete ga ne vidi kad se kartica podigne. */
  .pcard-fold { width: 100%; margin-top: 4mm; border-top: 1px dashed #999; position: relative; }
  .pcard-fold::after { content: '✂ presavij ili odreži'; position: absolute; right: 0; top: -2.4mm; padding-left: 1.5mm; background: #fff; font-size: 6pt; color: #999; }
  .pcard-label { margin-top: 2mm; font-size: 8pt; text-align: center; color: #888; }
  .pcard-word { font-weight: 700; letter-spacing: .04em; text-align: center; line-height: 1.1; overflow-wrap: break-word; max-width: 100%; }
  .pcard-word.w4 { font-size: 60pt; }
  .pcard-word.w6 { font-size: 44pt; }
  .pcard-word.w9 { font-size: 30pt; }
  .pcard-word.w12 { font-size: 22pt; }

  /* Tjedni plan */
  .pweek-head { display: flex; align-items: center; gap: 5mm; border-bottom: 2px solid #000; margin-bottom: 6mm; padding-bottom: 2mm; }
  .plogo { height: 16mm; width: auto; filter: brightness(0); }
  .pweek-head h2 { margin: 0; font-size: 20pt; }
  .pweek-head p { margin: 1mm 0 3mm; font-size: 12pt; }
  .pday { margin-bottom: 6mm; }
  .pday h3 { font-size: 14pt; margin: 0 0 3mm; padding: 1mm 2mm; background: #eee; break-after: avoid; page-break-after: avoid; text-transform: capitalize; }
  .pblock { margin: 0 0 2mm 2mm; }
  .pblock-title { margin: 0 0 2mm; font-size: 12pt; text-transform: uppercase; letter-spacing: .05em; border-bottom: 1px solid #bbb; break-after: avoid; page-break-after: avoid; }
  .pex { break-inside: avoid; page-break-inside: avoid; margin: 0 0 4mm 2mm; font-size: 10.5pt; }
  .pex h5 { margin: 0 0 1mm; font-size: 11.5pt; }
  .pmin { text-transform: none; font-weight: 400; font-size: 10pt; color: #444; }
  .pprops { margin: 0 0 1mm; color: #333; }
  .pex ol { margin: 0; padding-left: 6mm; }
  .psource { margin: 1mm 0 0; font-size: 8.5pt; font-style: italic; color: #555; }
}
