/* Tips Recettes — carte recette (reprend le rendu du thème Extra) */
.tr-card, .tr-rate { --tr-accent: var(--fz-cat, #c3004e); }
.tr-card { margin-top: 20px; scroll-margin-top: 140px; }
.tr-jump { margin: 0 0 14px; font-size: 15px; }
.tr-jump a { font-weight: bold; }

/* Infos */
.tr-infos { font-size: 15px; line-height: 1.8; }
.tr-yield { display: flex; align-items: center; gap: 10px; }
.tr-adjust { display: inline-flex; border: 1px solid #ddd; border-radius: 99px; overflow: hidden; }
.tr-adjust button { border: 0; background: #fff; width: 28px; height: 24px; line-height: 1; cursor: pointer; font-size: 16px; color: #333; padding: 0; }
.tr-adjust button:hover { background: var(--tr-accent); color: #fff; }
.tr-rating-line { display: flex; align-items: center; gap: 8px; margin-top: 2px; }
.tr-rating-text { font-size: 13px; color: #777; }
.tr-actions { display: flex; flex-wrap: wrap; gap: 14px; margin-top: 6px; font-size: 14px; }
.tr-print { background: none; border: 0; padding: 0; color: var(--tr-accent); cursor: pointer; font: inherit; text-decoration: underline; }

/* Étoiles (affichage) */
.tr-stars { display: inline-flex; gap: 2px; }
.tr-star { width: 16px; height: 16px; background: linear-gradient(90deg, var(--tr-accent) var(--fill), #d6d6d6 var(--fill)); -webkit-mask: var(--tr-star-mask) center / contain no-repeat; mask: var(--tr-star-mask) center / contain no-repeat; }
.tr-card, .tr-rate, .tr-entete { --tr-star-mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath d='M12 2l2.9 6.9 7.1.6-5.4 4.7 1.6 7L12 17.5 5.8 21.2l1.6-7L2 9.5l7.1-.6z'/%3E%3C/svg%3E"); }

/* Titre et listes */
.tr-card .nom-recette { padding-bottom: 0; }
.tr-card .lib-ingredients, .tr-card .lib-tools, .tr-card .lib-instructions, .tr-card .lib-astuces { display: block; font-weight: bold; margin-bottom: 8px; margin-top:12px; }
.tr-card .liste-ingredients.tr-has-photo { gap: 24px; }
@media (min-width: 768px) {
	.tr-card .liste-ingredients { flex-direction: row-reverse; align-items: flex-start; }
	.tr-card .liste-ingredients .ingredients { flex: 1 1 auto; margin: 0; }
	.tr-card .liste-ingredients .photo-ingredients { flex: 0 0 auto; max-width: 40%; margin: 0; }
}
@media (max-width: 767px) {
	.tr-card .liste-ingredients { display: flex; flex-direction: column-reverse; }
	.tr-card .liste-ingredients .photo-ingredients { margin: 16px auto 0; max-width: 80%; }
}
.tr-card .photo-ingredients figure { margin: 0; }
.tr-card .photo-ingredients img { height: auto; }
.tr-card .tr-group { font-size: 18px; margin: 14px 0 6px; padding: 0; } /* h4, couleur des titres du thème */
.tr-card .tr-sub { font-size: 18px; margin: 0 0 8px; padding: 0; } /* h3 Ingrédients, Ustensiles, Étapes, Astuce(s) */
.tr-card ul.tr-ing-list { list-style: none; padding: 0 !important; margin: 0 0 6px; }
.tr-card ul.tr-ing-list li { padding: 3px 0; list-style: none !important; margin-left: 0 !important; }
.tr-card ul.tr-ing-list li::before { content: none !important; }
.tr-card ul.tr-ing-list label { cursor: pointer; display: flex; gap: 8px; align-items: baseline; }
/* Ustensiles (sous les ingrédients, même présentation) */
.tr-card .tr-tools { margin-top: 18px; }
.tr-card ul.tr-tools-list { list-style: none !important; padding: 0 !important; margin: 0 0 6px; }
.tr-card ul.tr-tools-list li { padding: 3px 0; margin-left: 0 !important; list-style: none !important; }
.tr-card ul.tr-tools-list li::before { content: none !important; }
.tr-check { accent-color: var(--tr-accent); flex: none; position: relative; top: 1px; }
.tr-check:checked + .tr-ing { text-decoration: line-through; opacity: .5; }
.tr-q { font-weight: bold; }
.tr-note { color: #777; }

/* Étapes */
.tr-card ol.tr-steps { padding-left: 1.4em !important; margin: 0 0 10px; }
.tr-card ol.tr-steps li { padding: 4px 0 8px; }
.tr-step-title { color: #000; }
/* Étapes : pastille numérotée à cocher */
.tr-card ol.tr-steps { list-style: none !important; padding-left: 0 !important; }
.tr-card ol.tr-steps li.tr-step { display: grid; grid-template-columns: 34px 1fr; column-gap: 14px; align-items: start; padding: 6px 0 12px; margin-left: 0 !important; list-style: none !important; }
.tr-card ol.tr-steps li.tr-step::before { content: none !important; }
.tr-step-n { position: relative; display: block; margin: 0; cursor: pointer; }
.tr-step-n input { position: absolute; inset: 0; width: 100%; height: 100%; margin: 0; opacity: 0; cursor: pointer; }
.tr-step-n span { display: flex; align-items: center; justify-content: center; box-sizing: border-box; width: 34px; height: 34px; border: 2px solid var(--tr-accent); border-radius: 50%; color: var(--tr-accent); font-size: 15px; font-weight: 700; line-height: 1; transition: background-color .15s, color .15s; }
.tr-step-n:hover span { background: color-mix(in srgb, var(--tr-accent) 10%, transparent); }
.tr-step-n input:focus-visible + span { outline: 2px solid var(--tr-accent); outline-offset: 2px; }
.tr-step-n input:checked + span { background: var(--tr-accent); color: #fff; font-size: 0; }
.tr-step-n input:checked + span::after { content: '✓'; font-size: 18px; }
.tr-step-body { min-width: 0; padding-top: 4px; transition: opacity .15s; }
.tr-step:has(.tr-step-n input:checked) .tr-step-body { opacity: .45; }
@media (max-width: 480px) { .tr-card ol.tr-steps li.tr-step { grid-template-columns: 28px 1fr; column-gap: 10px; } .tr-step-n span { width: 28px; height: 28px; font-size: 13px; } .tr-step-body { padding-top: 2px; } }
.tr-step-img { margin: 10px 0 0; }
.tr-step-img img { height: auto; max-width: 100%; }
.tr-step-gallery { display: grid; grid-template-columns: repeat(var(--cols, 2), 1fr); gap: 8px; margin-top: 10px; }
@media (max-width: 600px) { .tr-step-gallery { grid-template-columns: repeat(2, 1fr); } }
.tr-step-gallery img { width: 100%; aspect-ratio: 1; object-fit: cover; display: block; }
.tr-notes { border-top: 1px solid #000; margin-top: 20px; padding-top: 20px; }
.tr-free { margin: 10px 0; }
.tr-free iframe, .tr-free video, .tr-free embed { display: block; width: 100%; max-width: 100%; height: auto; aspect-ratio: 16 / 9; margin: 16px 0; border: 0; }
.tr-free .wp-embedded-content { aspect-ratio: auto; }

/* Notation */
.tr-rate { border-top: 1px solid #000; margin-top: 20px; padding-top: 16px; display: flex; flex-wrap: wrap; align-items: center; gap: 10px; }
.tr-rate-title { font-weight: bold; }
.tr-rate-stars { display: inline-flex; gap: 4px; }
.tr-rate-star { width: 28px; height: 28px; border: 0; padding: 0; cursor: pointer; background: #d6d6d6; -webkit-mask: var(--tr-star-mask) center / contain no-repeat; mask: var(--tr-star-mask) center / contain no-repeat; }
.tr-rate-star.is-on { background: var(--tr-accent); }
.tr-rate-msg { font-size: 14px; color: #555; }

/* Agrandissement des photos */

/* Impression : uniquement la recette */
@media print {
	body.tr-printing * { visibility: hidden !important; }
	body.tr-printing .tr-card, body.tr-printing .tr-card * { visibility: visible !important; }
	body.tr-printing .tr-card { position: absolute; left: 0; top: 0; width: 100%; }
	body.tr-printing .tr-adjust, body.tr-printing .tr-actions, body.tr-printing .tr-rate, body.tr-printing .tr-check, body.tr-printing .tr-free.tr-after { display: none !important; }
	body.tr-printing .tr-step-gallery, body.tr-printing .tr-step-img { display: none !important; }
}

/* ------------------------------------------------------------ Bandeau coût / difficulté / score (sous les métas) */
.tr-badges { display: flex; flex-wrap: wrap; list-style: none !important; margin: 14px 0 6px !important; padding: 0 !important; }
.tr-badge { flex: 1 1 0; min-width: 96px; display: flex; flex-direction: column; align-items: center; justify-content: flex-end; gap: 6px; padding: 12px 8px 10px !important; margin: 0 !important; text-align: center; list-style: none !important; }
.tr-badge::before { content: none !important; }
.tr-badge-ic { display: flex; align-items: flex-end; justify-content: center; height: 28px; }
.tr-badge-l { font-size: 14px; line-height: 1.25; color: rgba(0,0,0,.8); }
.tr-badge-price i { font-style: normal; font-weight: 700; font-size: 23px; line-height: 1; color: var(--fz-cat, #c3004e); opacity: .22; margin: 0 1px; }
.tr-badge-price i.on { opacity: 1; }
.tr-badge-level svg { display: block; color: #3c3c3c; }
.tr-badge-level rect { fill: currentColor; opacity: .2; }
.tr-badge-level rect.on { opacity: 1; }
.tr-badge-score .tr-badge-ic { gap: 3px; }
.tr-badge-score i { font-style: normal; display: flex; align-items: center; justify-content: center; width: 15px; height: 19px; border-radius: 4px; font-size: 10px; font-weight: 700; line-height: 1; color: #fff; opacity: .3; }
.tr-badge-score i.on { width: 22px; height: 28px; font-size: 15px; opacity: 1; }
.tr-badge-score .s-a { background: #23794a; } .tr-badge-score .s-b { background: #78ac3c; } .tr-badge-score .s-c { background: #e9b300; color: #3a2c00; } .tr-badge-score .s-d { background: #e47622; } .tr-badge-score .s-e { background: #cf3e22; }
.tr-badge-kcal .tr-badge-ic { gap: 3px; align-items: baseline; color: #3c3c3c; }
.tr-badge-kcal b { font-size: 22px; line-height: 1; font-weight: 700; }
.tr-badge-kcal small { font-size: 13px; }
@media (max-width: 600px) { .tr-badge-l { white-space: nowrap; } .tr-badge-score { flex-grow: 1.5; } .tr-badges-4 .tr-badge { flex: 1 1 50%; } }
@media (max-width: 480px) { .tr-badge { min-width: 0; padding: 10px 4px 8px !important; } .tr-badge-l { font-size: 12px; } }
.tr-entete { text-align: center; }
.tr-entete-note { margin: 0 !important; padding: 0 !important; font-size: 20px; line-height: 1.2; letter-spacing: 2px; }
.tr-entete-note a { text-decoration: none; }
.tr-entete { --tr-accent: var(--fz-cat, #c3004e); }
.tr-entete-note .tr-stars { gap: 3px; vertical-align: -3px; }
.tr-entete-note .tr-star { width: 20px; height: 20px; }
.tr-entete-votes { font-size: 14px; letter-spacing: 0; color: rgba(0,0,0,.6); vertical-align: 2px; }
.tr-entete .tr-badges { margin-top: 10px !important; }

/* Image à la une : taille choisie dans l'éditeur (centrée, jamais étirée) */
.et_pb_title_featured_container img[class*="tr-thumb-"] { width: auto; max-width: 100%; height: auto; display: block; margin: 0 auto; }
