/* Version imprimable : sobre, sur une page si possible. */
*, *::before, *::after { box-sizing: border-box; }
body { margin: 0; background: #fff; color: #111; font: 11pt/1.45 Georgia, "Times New Roman", serif; }
a { color: inherit; }
:focus-visible { outline: 3px solid #9a3f1a; outline-offset: 2px; }
.visually-hidden { position: absolute !important; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
[hidden] { display: none !important; }

.print-toolbar {
  display: flex; flex-wrap: wrap; align-items: center; gap: .75rem 1rem; padding: .75rem 1rem;
  background: #f4ebe1; border-bottom: 1px solid #e6d9cb; font: 15px/1.4 system-ui, sans-serif;
}
.btn { display: inline-flex; align-items: center; gap: .4rem; min-height: 40px; padding: .4rem .9rem; border-radius: 999px; border: 1px solid #d6c4b2; background: #fff; color: #2a211c; text-decoration: none; font: 600 15px/1 system-ui, sans-serif; cursor: pointer; }
.btn-primary { background: #9a3f1a; border-color: #9a3f1a; color: #fff; }
.btn-small { min-height: 36px; }
.icon { width: 18px; height: 18px; }
.toggle { display: inline-flex; gap: .4rem; align-items: center; }

.portions { display: flex; flex-wrap: wrap; align-items: center; gap: .5rem; margin: 0; }
.portions-label { font-weight: 700; }
.stepper { display: inline-flex; align-items: center; border: 1px solid #d6c4b2; border-radius: 999px; background: #fff; overflow: hidden; }
.stepper input { width: 3.2rem; min-height: 40px; border: 0; text-align: center; font: 700 16px system-ui, sans-serif; appearance: textfield; -moz-appearance: textfield; }
.stepper input::-webkit-outer-spin-button, .stepper input::-webkit-inner-spin-button { -webkit-appearance: none; margin: 0; }
.stepper-btn { width: 40px; height: 40px; border: 0; background: transparent; color: #9a3f1a; cursor: pointer; display: inline-flex; align-items: center; justify-content: center; }
.portions-base { margin: 0; font-size: 13px; color: #555; }

.print-recipe { max-width: 19cm; margin: 0 auto; padding: 1.2rem 1rem 2rem; }
.print-recipe h1 { font-size: 22pt; margin: 0 0 .2rem; line-height: 1.15; }
.print-meta { margin: 0 0 .8rem; color: #444; font-size: 10.5pt; }
.print-header { display: flex; justify-content: space-between; align-items: flex-start; gap: 1.2rem; margin-bottom: .4rem; }
.print-photo { flex: none; width: 4.5cm; height: auto; border-radius: 6px; }
.no-photo .print-photo { display: none; }
.print-recipe h2 { font-size: 13pt; margin: .9rem 0 .4rem; border-bottom: 1px solid #ccc; padding-bottom: .15rem; }
.print-recipe h3 { font-size: 11pt; margin: .6rem 0 .25rem; }
.print-columns { display: grid; grid-template-columns: 1fr; gap: 0 1.2rem; clear: both; }
@media (min-width: 640px), print { .print-columns { grid-template-columns: 2fr 3fr; } }
.ingredient-list { list-style: none; padding: 0; margin: 0; }
.ingredient { padding: .12rem 0; }
.ing-amount { font-weight: 700; }
.ing-note { color: #555; }
.step-list { margin: 0; padding-left: 1.3rem; }
.step { margin-bottom: .35rem; }
.step p { margin: 0; }
.step-time { color: #555; font-size: 9.5pt; }
.step-time .icon { width: 11px; height: 11px; vertical-align: -1px; margin-right: 3px; }
.print-notes { clear: both; }
.print-footer { margin-top: 1rem; font-size: 9pt; color: #666; border-top: 1px solid #ccc; padding-top: .3rem; }

@media print {
  .print-toolbar { display: none !important; }
  .print-recipe { padding: 0; max-width: none; }
  @page { margin: 1.4cm; }
  h2, h3 { break-after: avoid; }
  .step, .ingredient { break-inside: avoid; }
}
