/* PDF scheda fase — A4 orizzontale, max 2 facciate
   Intro + metodo affiancati; AB/AC/CB in tre colonne. */

.schede-peso-toolbar {
  position: sticky;
  top: 0;
  z-index: 50;
  background: #0c0c0c;
  color: #f4efe6;
  padding: 0.75rem 0;
  border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}
.schede-peso-toolbar__inner {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 0.5rem 0.75rem;
}
.schede-peso-toolbar p { margin: 0; }
.schede-peso-toolbar__tip {
  width: 100%;
  margin: 0;
  color: #aaa;
}

.scheda-a4 {
  width: 297mm;
  min-height: 210mm;
  margin: 1rem auto 2rem;
  padding: 5mm;
  background: #fff;
  color: #111;
  box-shadow: 0 8px 40px rgba(0, 0, 0, 0.12);
  font-family: "Segoe UI", system-ui, sans-serif;
  font-size: 10pt;
  line-height: 1.22;
}
.scheda-a4__head {
  border-bottom: 2px solid #c9783a;
  padding-bottom: 2mm;
  margin-bottom: 2.5mm;
}
.scheda-a4__head-main {
  font-size: 9pt;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: #8b4513;
  font-weight: 700;
}
.scheda-a4__head-period {
  text-align: center;
  font-size: 14pt;
  margin: 1mm 0;
  line-height: 1.2;
  font-weight: 700;
}
.scheda-a4__badge {
  display: inline-block;
  font-size: 8.5pt;
  font-weight: 700;
  letter-spacing: 0.06em;
  border: 1px solid #c9783a;
  border-radius: 2px;
  padding: 0.2mm 1.4mm;
  margin-right: 1.5mm;
  vertical-align: middle;
}
.scheda-a4__head-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 1mm 6mm;
  font-size: 9.5pt;
  color: #333;
}
.scheda-a4__top {
  display: grid;
  grid-template-columns: 1.15fr 1fr;
  gap: 3mm;
  margin-bottom: 2.5mm;
}
.scheda-a4__top > :only-child { grid-column: 1 / -1; }
.scheda-a4__osservazioni {
  margin-bottom: 0;
  padding: 2mm 2.5mm;
  border: 1px solid #c9b8a4;
  background: #faf7f2;
}
.scheda-a4__osservazioni-label {
  font-size: 8pt;
  font-weight: 700;
  text-transform: uppercase;
  color: #8b4513;
  margin-bottom: 1mm;
}
.scheda-a4__osservazioni-line {
  border-bottom: 1px solid #c9b8a4;
  min-height: 4.5mm;
  margin-bottom: 1mm;
}
.scheda-a4__intro-fase { margin-bottom: 0 !important; }
.scheda-a4__intro-text {
  margin: 0.7mm 0 0;
  font-size: 8pt;
  line-height: 1.22;
  color: #333;
}
.scheda-a4__mini-table {
  width: 100%;
  font-size: 7.5pt;
  border-collapse: collapse;
  margin: 1.2mm 0 0;
}
.scheda-a4__mini-table th,
.scheda-a4__mini-table td {
  border: 1px solid #bbb;
  padding: 0.4mm 1mm;
  text-align: left;
}
.scheda-a4__grid {
  display: grid;
  grid-template-columns: 1fr 1fr 1fr;
  gap: 2.5mm;
  align-items: start;
}
.scheda-a4__quad {
  break-inside: avoid;
  page-break-inside: avoid;
  border: 1px solid #ddd;
  padding: 2mm;
}
.scheda-a4__quad h2 {
  margin: 0 0 1.5mm;
  font-size: 11pt;
  line-height: 1.15;
  color: #1a1a1a;
  border-bottom: 1px solid #c9783a;
  padding-bottom: 0.8mm;
}
.scheda-a4 table {
  width: 100%;
  border-collapse: collapse;
}
.scheda-a4 table th,
.scheda-a4 table td {
  font-size: 8pt;
  padding: 0.7mm 1mm;
  border: 1px solid #ccc;
  text-align: left;
  vertical-align: top;
}
.scheda-a4 table th {
  background: #f0ebe3;
  font-size: 7pt;
  text-transform: uppercase;
  letter-spacing: 0.03em;
}
.scheda-a4__foot {
  margin-top: 2.5mm;
  padding-top: 1.5mm;
  border-top: 1px solid #ccc;
  font-size: 8pt;
  color: #666;
  text-align: center;
}

@media print {
  @page { size: A4 landscape; margin: 7mm; }
  .no-print,
  .schede-peso-toolbar { display: none !important; }
  .scheda-a4 {
    width: auto;
    min-height: auto;
    margin: 0;
    padding: 0;
    box-shadow: none;
  }
}

@media (max-width: 900px) {
  .scheda-a4 { width: 100%; }
  .scheda-a4__top,
  .scheda-a4__grid { grid-template-columns: 1fr; }
}
