/* Welcome cards for /carte-bienvenue-eglise/. Form chrome comes from ../qr-code-avis-google/qr.css.
   Card sizes are in container units, so the preview and the printed card look the same. */

.carte-aide { background: var(--surface-alt); padding: var(--sp-20); }
.carte-aide p { margin: 0 0 0.6rem; }
.carte-aide p:last-child { margin: 0; }
.qr .promo__champ input + input { margin-top: 0.5rem; }

.carte {
  --carte-accent: #1F3A5F;
  container-type: inline-size;
  width: min(100%, 26rem);
  aspect-ratio: 85 / 55;
  background: #fff; color: #1B211F;
  display: flex; flex-direction: column;
  box-shadow: 0 2px 14px rgba(0, 0, 0, 0.18);
  overflow: hidden;
  text-align: left;
}
.carte p, .carte ul { margin: 0; padding: 0; }
.carte__entete { flex: none; background: var(--carte-accent); color: #fff; padding: 1.8cqw 4cqw; }
.carte__nom {
  font-size: 3.4cqw; font-weight: 700; line-height: 1.15; overflow-wrap: anywhere;
  display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden;
}
.carte__corps {
  flex: 1; min-height: 0; padding: 3cqw 4cqw;
  display: grid; grid-template-columns: minmax(0, 1fr) 32cqw; column-gap: 3cqw; align-items: start;
}
.carte__texte { min-width: 0; }
.carte__titre { font-size: 4.6cqw; font-weight: 700; line-height: 1.1; color: var(--carte-accent); overflow-wrap: anywhere; text-wrap: balance; }
.carte__message { margin-top: 1.4cqw !important; font-size: 2.7cqw; line-height: 1.25; overflow-wrap: anywhere; }
.carte__horaires { list-style: none; margin-top: 1.8cqw !important; font-size: 2.7cqw; font-weight: 700; line-height: 1.3; }
.carte__horaires li { overflow-wrap: anywhere; }
.carte__adresse { margin-top: 1.4cqw !important; font-size: 2.5cqw; line-height: 1.25; color: #3b4440; overflow-wrap: anywhere; }
.carte__adresse[hidden], .carte__horaires[hidden] { display: none; }
.carte__scan { display: flex; flex-direction: column; align-items: center; }
.carte__qr { width: 32cqw; height: 32cqw; border: 0.7cqw solid var(--carte-accent); background: #fff; display: flex; align-items: center; justify-content: center; box-sizing: border-box; }
.carte__qr svg { width: 100%; height: 100%; display: block; }
.carte__qr--vide span { font-size: 2.4cqw; padding: 2cqw; text-align: center; color: #5F6B67; }
.carte__visez { margin-top: 1.2cqw !important; font-size: 2.2cqw; line-height: 1.2; text-align: center; color: #3b4440; }

/* A6, portrait */
.carte--a6 { width: min(100%, 18rem); aspect-ratio: 105 / 148; text-align: center; }
.carte--a6 .carte__entete { padding: 2.5cqw 5cqw; }
.carte--a6 .carte__nom { font-size: 4cqw; }
.carte--a6 .carte__corps { display: flex; flex-direction: column; align-items: center; padding: 4cqw 6cqw; }
.carte--a6 .carte__texte { display: contents; }
.carte--a6 .carte__titre { order: 1; font-size: 7cqw; }
.carte--a6 .carte__message { order: 2; margin-top: 2cqw !important; font-size: 4cqw; }
.carte--a6 .carte__scan { order: 3; margin-top: 3cqw; }
.carte--a6 .carte__qr { width: 44cqw; height: 44cqw; border-width: 1cqw; }
.carte--a6 .carte__qr--vide span { font-size: 3.4cqw; }
.carte--a6 .carte__visez { font-size: 3.2cqw; margin-top: 1.2cqw !important; }
.carte--a6 .carte__horaires { order: 4; margin-top: 3cqw !important; font-size: 4cqw; }
.carte--a6 .carte__adresse { order: 5; margin-top: 2cqw !important; font-size: 3.6cqw; }

/* Print: one A4 sheet, nothing else on the page. */
.impression { display: none; }
.feuille { position: relative; width: 210mm; height: 297mm; background: #fff; overflow: hidden; break-after: avoid; break-inside: avoid; }
.feuille .carte { box-shadow: none; max-width: none; print-color-adjust: exact; -webkit-print-color-adjust: exact; }
.feuille--carte .carte { width: 85mm; height: 55mm; aspect-ratio: auto; }
.feuille--a6 .carte { width: 105mm; height: 148mm; aspect-ratio: auto; outline: 0.2mm dashed #9aa3a0; outline-offset: -0.2mm; }
.feuille--carte {
  display: grid; grid-template-columns: 85mm 85mm; grid-template-rows: repeat(5, 55mm);
  padding: 11mm 20mm; box-sizing: border-box; align-content: start;
}
.feuille--a6 { display: grid; grid-template-columns: 105mm 105mm; grid-template-rows: 148mm 148mm; }
.feuille__repere { position: absolute; background: #555; }
.feuille__repere--v { width: 0.25mm; height: 4mm; }
.feuille__repere--h { width: 4mm; height: 0.25mm; }

@media print {
  html, body { background: #fff !important; margin: 0 !important; padding: 0 !important; }
  body > *:not(#impression) { display: none !important; }
  .impression { display: block !important; }
}
