/* Gîte en Règle — page « Loi Le Meur » (s'appuie sur les variables de /assets/style.css) */

.lm-module { background: var(--card); border: 1px solid var(--line); border-radius: 22px; padding: 28px; box-shadow: var(--shadow); }
.lm-module :where(h3) { margin-top: 0; }

/* Étiquettes */
.lm-tag { display: inline-flex; align-items: center; font-size: .78rem; font-weight: 800; letter-spacing: .03em; text-transform: uppercase; color: var(--primary); background: var(--primary-soft); padding: 3px 9px; border-radius: 8px; }
.lm-etat { font-size: .82rem; font-weight: 700; color: var(--muted); }

/* Cartes des 5 règles (blocs WordPress) */
.lm-regles { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.lm-regles > .card { display: flex; flex-direction: column; }
.lm-regles .card h3 { margin-bottom: .35em; }
.lm-regles .card .lm-regle { font-weight: 700; font-size: 1.02rem; }
body p.lm-statut { display: inline-flex; align-self: flex-start; align-items: center; gap: 6px; font-size: .8rem; font-weight: 800; padding: 4px 10px; border-radius: 999px; margin: 0 0 12px; }
body p.lm-statut::before { content: ""; width: 8px; height: 8px; border-radius: 50%; background: currentColor; }
body p.lm-statut.is-ok { color: var(--green); background: var(--green-soft); }
body p.lm-statut.is-soon { color: var(--warn); background: var(--warn-soft); }
body p.lm-statut.is-later { color: var(--primary); background: var(--primary-soft); }
.lm-regles .card details { margin: auto 0 0; background: var(--ground); border-color: var(--line); }
.lm-regles .card details p { margin-bottom: .7em; }
.lm-regles .card details p:last-child { margin-bottom: 12px; }
.lm-regles .card details strong { color: var(--ink); }
.lm-regles .card.lm-carte-cta { background: var(--primary); color: #fff; border-color: var(--primary); justify-content: center; }
.lm-regles .card.lm-carte-cta p { color: #DCE8EF; }
.lm-regles .card.lm-carte-cta h3 { color: #fff; }
.lm-regles .card.lm-carte-cta .wp-block-button .wp-block-button__link { background: var(--apple); color: var(--ink); }
.lm-regles .card.lm-carte-cta .wp-block-button .wp-block-button__link:hover { background: #8CC56F; }
.lm-regles .card.lm-carte-cta .wp-block-buttons { margin-top: 8px; }

/* Icônes des cartes Le Meur */
body .card[class*="lmi-"]::before { content: ""; display: block; width: 44px; height: 44px; border-radius: 12px; margin-bottom: 14px; background: var(--primary-soft) center / 22px no-repeat; }
body .card.lmi-numero::before { background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%231F4E6B' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M4 9h16M4 15h16M10 3 8 21M16 3l-2 18'/%3E%3C/svg%3E"); }
body .card.lmi-impots::before { background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%231F4E6B' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M19 5 5 19'/%3E%3Ccircle cx='7' cy='7' r='2.5'/%3E%3Ccircle cx='17' cy='17' r='2.5'/%3E%3C/svg%3E"); }
body .card.lmi-dpe::before { background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%231F4E6B' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M3 11 12 4l9 7'/%3E%3Cpath d='M5 10v10h14V10'/%3E%3Cpath d='M13 12l-3 4h4l-3 4'/%3E%3C/svg%3E"); }
body .card.lmi-mairie::before { background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%231F4E6B' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M3 21h18M4 10h16M12 3l8 5H4z'/%3E%3Cpath d='M6 10v8M10 10v8M14 10v8M18 10v8'/%3E%3C/svg%3E"); }
body .card.lmi-copro::before { background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%231F4E6B' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Crect x='5' y='3' width='14' height='18' rx='1'/%3E%3Cpath d='M9 7h1M14 7h1M9 11h1M14 11h1M9 15h1M14 15h1M11 21v-3h2v3'/%3E%3C/svg%3E"); }

/* Frise */
.lm-frise-resume { color: var(--muted); margin-bottom: 20px; }
.lm-frise-resume strong { color: var(--ink); }
.lm-frise { list-style: none; margin: 0; padding: 0 0 0 28px; position: relative; }
.lm-frise::before { content: ""; position: absolute; left: 9px; top: 6px; bottom: 6px; width: 3px; border-radius: 3px; background: linear-gradient(var(--apple) var(--lm-fait, 50%), var(--line) 0); background: var(--line); }
.lm-etape { position: relative; padding: 0 0 22px; }
.lm-etape::before { content: ""; position: absolute; left: -25px; top: 4px; width: 15px; height: 15px; border-radius: 50%; background: var(--card); border: 3px solid var(--line); }
.lm-etape.is-passe::before { background: var(--apple); border-color: var(--green); }
.lm-etape.is-bientot::before { background: var(--warn-soft); border-color: var(--warn); }
.lm-etape-tete { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; margin-bottom: 4px; }
.lm-etape-date { font-weight: 800; }
.lm-etape h3 { font-size: 1.02rem; margin: 0 0 2px; }
.lm-etape p { margin: 0; color: var(--muted); }
.lm-etape.is-passe .lm-etat { color: var(--green); }
.lm-etape.is-bientot .lm-etat { color: var(--warn); }
.lm-etape.is-futur { opacity: .85; }
.lm-ici { position: relative; padding: 2px 0 24px; display: flex; flex-wrap: wrap; align-items: center; gap: 10px; }
.lm-ici::before { content: ""; position: absolute; left: -31px; top: 3px; width: 27px; height: 27px; border-radius: 50%; background: var(--primary); box-shadow: 0 0 0 6px var(--primary-soft); animation: lm-pulse 2.2s ease-in-out infinite; }
.lm-ici-pastille { background: var(--primary); color: #fff; font-weight: 800; border-radius: 10px; padding: 5px 12px; }
.lm-ici-date { color: var(--muted); font-weight: 600; }
@keyframes lm-pulse { 50% { box-shadow: 0 0 0 11px rgba(31, 78, 107, .08); } }
@media (prefers-reduced-motion: reduce) { .lm-ici::before { animation: none; } }

/* Parcours */
.lm-progress { height: 8px; border-radius: 8px; background: var(--primary-soft); overflow: hidden; margin-bottom: 14px; }
.lm-progress span { display: block; height: 100%; background: var(--primary); border-radius: 8px; transition: width .25s; }
.lm-compteur { color: var(--muted); font-size: .9rem; font-weight: 700; margin-bottom: 6px; }
.lm-question { font-size: 1.3rem; margin-bottom: 8px; outline: none; }
.lm-aide { color: var(--muted); font-size: .94rem; }
.lm-choix { display: grid; gap: 10px; margin: 16px 0 12px; }
.lm-bouton-choix { text-align: left; font: inherit; font-weight: 700; color: var(--ink); background: var(--ground); border: 1px solid var(--line); border-radius: 14px; min-height: 54px; padding: 12px 18px; cursor: pointer; transition: background .15s, border-color .15s, transform .1s; }
.lm-bouton-choix:hover { background: var(--primary-soft); border-color: var(--primary); }
.lm-bouton-choix:active { transform: scale(.99); }
.lm-bouton-choix.is-choisi { background: var(--primary); border-color: var(--primary); color: #fff; }
.lm-bouton-choix:focus-visible, .lm-bouton-vf:focus-visible, .lm-puce:focus-visible, .lm-lien:focus-visible { outline: 3px solid #6FA8C9; outline-offset: 2px; }
.lm-lien { font: inherit; font-weight: 700; color: var(--primary); background: none; border: 0; padding: 8px 0; cursor: pointer; text-decoration: underline; text-underline-offset: 3px; }
.lm-resultat h3 { font-size: 1.35rem; outline: none; }
.lm-score { display: flex; flex-wrap: wrap; gap: 8px; margin: 4px 0 18px; }
.lm-pastille { font-weight: 800; font-size: .9rem; padding: 6px 12px; border-radius: 999px; }
.lm-pastille.is-urgent { background: #FBE3E0; color: #9B2C1F; }
.lm-pastille.is-attention { background: var(--warn-soft); color: var(--warn); }
.lm-pastille.is-ok { background: var(--green-soft); color: var(--green); }
.lm-bilan { list-style: none; padding: 0; margin: 0 0 14px; display: grid; gap: 12px; }
.lm-ligne { border: 1px solid var(--line); border-left: 5px solid var(--line); border-radius: 14px; padding: 14px 16px; background: var(--card); }
.lm-ligne p { margin: 4px 0 0; color: var(--muted); }
.lm-ligne .lm-action { color: var(--ink); }
.lm-ligne-tete { display: flex; align-items: center; gap: 8px; margin-bottom: 6px; }
.lm-ligne-titre { display: block; font-size: 1.05rem; }
.lm-feu { width: 12px; height: 12px; border-radius: 50%; background: var(--line); }
.lm-ligne.is-urgent { border-left-color: #C0392B; } .lm-ligne.is-urgent .lm-feu { background: #C0392B; } .lm-ligne.is-urgent .lm-etat { color: #9B2C1F; }
.lm-ligne.is-attention { border-left-color: #D9822B; } .lm-ligne.is-attention .lm-feu { background: #D9822B; } .lm-ligne.is-attention .lm-etat { color: var(--warn); }
.lm-ligne.is-info { border-left-color: var(--primary); } .lm-ligne.is-info .lm-feu { background: var(--primary); } .lm-ligne.is-info .lm-etat { color: var(--primary); }
.lm-ligne.is-ok { border-left-color: #5FA544; } .lm-ligne.is-ok .lm-feu { background: #5FA544; } .lm-ligne.is-ok .lm-etat { color: var(--green); }
.lm-mention { color: var(--muted); font-size: .86rem; margin: 12px 0 0; }
.lm-actions { display: flex; flex-wrap: wrap; align-items: center; gap: 12px; margin-top: 18px; }
.lm-teaser { margin-top: 20px; border-radius: 16px; background: var(--ink); color: #fff; padding: 18px 20px; }
.lm-teaser p { color: #C9D4DA; margin: 8px 0; }
.lm-teaser p strong { color: #fff; }
.lm-badge-abo { display: inline-block; font-size: .76rem; font-weight: 800; letter-spacing: .05em; text-transform: uppercase; background: #2A3E4B; color: var(--apple); padding: 4px 10px; border-radius: 8px; }
.lm-lien-fort { color: var(--apple); font-weight: 800; }
.lm-lien-fort:hover { color: #fff; }

/* Curseur */
.lm-curseur-ligne { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-bottom: 8px; }
.lm-montant { font-size: clamp(1.8rem, 5vw, 2.4rem); font-weight: 800; letter-spacing: -.02em; color: var(--primary); }
input.lm-saisie[type="number"] { width: 150px; min-height: 44px; }
#lm-recettes { width: 100%; accent-color: var(--primary); height: 28px; margin: 0; }
.lm-jauge { position: relative; height: 10px; border-radius: 10px; background: var(--primary-soft); margin: 6px 0 34px; }
.lm-jauge-remplie { display: block; height: 100%; border-radius: 10px; background: var(--apple); transition: width .1s; }
.lm-jauge.is-alerte .lm-jauge-remplie { background: #E5A15C; }
.lm-repere { position: absolute; top: -4px; width: 2px; height: 18px; background: var(--ink); }
.lm-repere em { position: absolute; top: 20px; left: 50%; transform: translateX(-50%); font-style: normal; font-size: .78rem; font-weight: 800; white-space: nowrap; color: var(--ink); }
.lm-tmi-titre { margin: 0 0 8px; }
.lm-puces { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 22px; }
.lm-puce { font: inherit; font-weight: 700; min-height: 42px; padding: 0 16px; border-radius: 12px; border: 1px solid var(--line); background: var(--ground); color: var(--ink); cursor: pointer; }
.lm-puce[aria-checked="true"] { background: var(--primary); border-color: var(--primary); color: #fff; }
.lm-colonnes { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; }
.lm-colonne { border: 1px solid var(--line); border-radius: 16px; padding: 18px; background: var(--ground); }
.lm-colonne.is-classe { background: var(--green-soft); border-color: #BFDDB1; }
.lm-colonne.is-hors { background: #FBE3E0; border-color: #F0C2BB; }
.lm-colonne-titre { font-weight: 800; margin-bottom: 10px; }
.lm-colonne dl { display: grid; grid-template-columns: 1fr auto; gap: 6px 12px; margin: 0; }
.lm-colonne dt { color: var(--muted); }
.lm-colonne dd { margin: 0; font-weight: 700; text-align: right; font-variant-numeric: tabular-nums; }
.lm-colonne .lm-total { color: var(--ink); font-weight: 800; font-size: 1.1rem; border-top: 1px solid rgba(19, 35, 46, .12); padding-top: 8px; }
.lm-gros { font-size: 1.2rem; font-weight: 800; color: #9B2C1F; margin-bottom: 4px; }
.lm-petit { color: var(--muted); font-size: .92rem; margin: 0; }
.lm-verdict { margin-top: 14px; border-radius: 14px; padding: 14px 16px; background: var(--primary-soft); }
.lm-verdict p { margin: 0; }
.lm-verdict.is-fort { background: var(--ink); color: #fff; }
.lm-verdict.is-fort strong { color: var(--apple); }

/* Quiz */
.lm-quiz-q { font-size: 1.25rem; font-weight: 800; line-height: 1.35; margin: 6px 0 16px; outline: none; }
.lm-vf { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.lm-bouton-vf { font: inherit; font-size: 1.1rem; font-weight: 800; min-height: 60px; border-radius: 16px; border: 2px solid var(--line); background: var(--ground); color: var(--ink); cursor: pointer; transition: transform .1s, background .15s; }
.lm-bouton-vf:hover:not(:disabled) { border-color: var(--primary); background: var(--primary-soft); }
.lm-bouton-vf:active:not(:disabled) { transform: scale(.98); }
.lm-bouton-vf:disabled { cursor: default; opacity: .55; }
.lm-bouton-vf.is-bon { opacity: 1; background: var(--green-soft); border-color: #5FA544; color: var(--green); }
.lm-bouton-vf.is-faux { opacity: 1; background: #FBE3E0; border-color: #C0392B; color: #9B2C1F; }
.lm-quiz-retour:empty { display: none; }
.lm-quiz-retour { margin-top: 16px; border-radius: 14px; padding: 16px; animation: lm-apparait .25s ease-out; }
.lm-quiz-retour.is-bon { background: var(--green-soft); }
.lm-quiz-retour.is-faux { background: var(--warn-soft); }
.lm-quiz-retour .btn { margin-top: 12px; }
.lm-quiz-score { text-align: center; margin: 4px 0 6px; outline: none; }
.lm-quiz-score span { display: inline-grid; place-items: center; width: 120px; height: 120px; border-radius: 50%; background: var(--primary); color: #fff; font-size: 2rem; font-weight: 800; box-shadow: 0 0 0 8px var(--primary-soft); }
.lm-quiz-message { text-align: center; font-weight: 700; max-width: 34em; margin: 16px auto 0; }
.lm-quiz .lm-actions { justify-content: center; }
@keyframes lm-apparait { from { opacity: 0; transform: translateY(4px); } }
@media (prefers-reduced-motion: reduce) { .lm-quiz-retour { animation: none; } }

/* Offre gratuite / abonnement */
.lm-offres { align-items: stretch; }
.lm-offres > .card { display: flex; flex-direction: column; }
.lm-offres .card h3 { font-size: 1.3rem; }
.lm-offres .card .lm-prix { font-size: 1.6rem; font-weight: 800; margin-bottom: 4px; }
.lm-offres .card .lm-prix-note { color: var(--muted); font-size: .92rem; }
.lm-offres .card ul.feature-list { grid-template-columns: 1fr; margin-bottom: 18px; }
.lm-offres .card .wp-block-buttons { margin-top: auto; }
.lm-offres .card.lm-offre-abo { background: var(--ink); color: #fff; border-color: var(--ink); }
.lm-offres .card.lm-offre-abo p { color: #C9D4DA; }
.lm-offres .card.lm-offre-abo h3, .lm-offres .card.lm-offre-abo .lm-prix { color: #fff; }
.lm-offres .card.lm-offre-abo .eyebrow { background: #2A3E4B; color: var(--apple); }
.lm-offres .card.lm-offre-abo .wp-block-button .wp-block-button__link { background: var(--apple); color: var(--ink); }

/* Sources */
.lm-sources { font-size: .92rem; color: var(--muted); }
.lm-sources a { word-break: break-word; }

/* Mobile */
@media (max-width: 900px) {
  .lm-regles { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (max-width: 640px) {
  .lm-module { padding: 20px; border-radius: 18px; }
  .lm-regles { grid-template-columns: 1fr; }
  .lm-colonnes { grid-template-columns: 1fr; }
  .lm-curseur-ligne { flex-wrap: wrap; }
  input.lm-saisie[type="number"] { width: 100%; }
}

/* Impression de la liste du parcours */
@media print {
  body.lm-impression * { visibility: hidden !important; }
  body.lm-impression .lm-imprimable, body.lm-impression .lm-imprimable * { visibility: visible !important; }
  body.lm-impression .lm-imprimable { position: absolute; left: 0; top: 0; width: 100%; }
  body.lm-impression .site-header { display: none; }
}
