/* Adaptations du design (site.css, repris tel quel de Claude Design) au site WordPress / WooCommerce. */

body.rm { margin: 0; min-height: 100vh; }
.rm .skip:focus { position: fixed; top: 8px; left: 8px; z-index: 100; width: auto; height: auto; clip: auto; padding: 12px 16px; background: var(--white); border-radius: var(--radius-md); }

/* Photos : vraie image dans le cadre .ph, ou fond neutre quand elle manque */
.rm .ph.ph-img { background: var(--white); }
.rm .ph.ph-img img, .rm .ph.ph-img video { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.rm .ph.ph-empty { background: var(--grey-300); }
.rm .ph.ph-empty::after { content: ""; position: absolute; inset: 0; background: url(../img/logo-rond.webp) center / min(22%, 72px) no-repeat; opacity: .35; filter: grayscale(1); }
.rm .dark .ph.ph-empty, .rm .hero .ph.ph-empty { background: #2a2a2a; }
.rm .ph.ph-product.ph-empty { background: var(--grey-100); align-items: center; justify-content: center; }
.rm .ph.ph-product.ph-empty::after { content: none; }
.rm .cat .ph.ph-empty::after { background-size: 50%; }
.rm .pc-media { display: block; }

/* Menu mobile */
.rm .nav .m-only { display: none; }
@media (max-width: 899px) {
  .rm .nav.open { display: flex; flex-direction: column; position: absolute; left: 0; right: 0; top: 100%; background: var(--white); border-bottom: 1px solid var(--grey-300); box-shadow: var(--shadow-raised); padding: 8px var(--space-4) 16px; }
  .rm .nav.open a { padding: 14px 4px; font-weight: 700; text-decoration: none; border-bottom: 1px solid var(--grey-100); }
  .rm .nav.open a[aria-current] { color: var(--ink); box-shadow: inset 4px 0 0 var(--orange); padding-left: 12px; }
  .rm .nav.open .m-only { display: block; }
  .rm .hdr .wrap { position: relative; }
}

/* Fenêtre de choix du statut */
.rm .scrim.rm-statut { position: fixed; inset: 0; z-index: 50; background: rgba(1,0,0,.62); display: flex; align-items: flex-end; justify-content: center; }
.rm .scrim.rm-statut[hidden] { display: none; }
.rm .modal { position: relative; }
.rm .modal h2 { font-size: 24px; }
@media (min-width: 900px) { .rm .scrim.rm-statut { align-items: center; padding: 40px; } }

/* Bandeau cookies (inc/consent.php) : deux boutons de même poids, comme l'exige la CNIL */
.rm .ck { position: fixed; left: 0; right: 0; bottom: 0; z-index: 40; display: grid; gap: 12px; padding: 16px var(--space-4); background: var(--white); border-top: 4px solid var(--orange); box-shadow: var(--shadow-raised); font-size: 15px; line-height: 1.5; }
.rm .ck[hidden] { display: none; }
.rm .ck p { margin: 0; }
.rm .ck b { display: block; font-weight: 800; }
.rm .ck a { color: var(--ink); font-weight: 700; }
.rm .ck-btns { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.rm .ck-btns .btn { min-height: 44px; }
@media (min-width: 700px) { .rm .ck { left: 16px; right: auto; bottom: 16px; max-width: 520px; border-radius: var(--radius-md); border: 1px solid var(--grey-300); border-top: 4px solid var(--orange); } }
.rm .ck-link { background: none; border: 0; padding: 0; font: inherit; color: inherit; text-decoration: underline; cursor: pointer; }

/* Compteur du panier masqué quand il est vide */
.rm .count[hidden] { display: none; }

/* Filtres : vraies cases à cocher, habillées comme dans le design */
.rm .fopt input[type="checkbox"] { appearance: none; -webkit-appearance: none; margin: 0; width: 20px; height: 20px; border-radius: 4px; border: 2px solid var(--ink); flex: none; display: grid; place-items: center; background: var(--white); cursor: pointer; }
.rm .fopt input[type="checkbox"]:checked { background: var(--ink); }
.rm .fopt input[type="checkbox"]:checked::after { content: ""; width: 5px; height: 10px; border: solid var(--white); border-width: 0 2px 2px 0; transform: rotate(45deg) translate(-1px, -1px); }
.rm .fopt { cursor: pointer; }
.rm .filters.open { display: block; margin-bottom: 16px; }
.rm .active-f { display: flex; flex-wrap: wrap; gap: 8px; }
.rm .active-f .chip .ico { width: 16px; height: 16px; }

/* Pagination des listes de produits */
.rm .pager { display: flex; flex-wrap: wrap; gap: 8px; justify-content: center; margin-top: 32px; }
.rm .pager .page-numbers { display: inline-grid; place-items: center; min-width: 44px; min-height: 44px; padding: 0 12px; border: 1.5px solid var(--grey-500); border-radius: var(--radius-md); background: var(--white); font-weight: 700; text-decoration: none; }
.rm .pager .current { background: var(--ink); color: var(--white); border-color: var(--ink); }
.rm .empty-list { background: var(--white); border-radius: var(--radius-md); padding: 24px; }

/* Fiche produit : galerie avec vraies photos */
.rm .gallery .main-ph { aspect-ratio: 1; }
.rm .gallery .thumbs button { padding: 0; border: 0; background: none; cursor: pointer; border-radius: var(--radius-md); }
.rm .gallery .thumbs button[aria-current="true"] .ph { outline: 3px solid var(--ink); outline-offset: -3px; }
.rm .qty input { width: 48px; border: 0; text-align: center; font-weight: 700; background: transparent; -moz-appearance: textfield; }
.rm .qty input::-webkit-outer-spin-button, .rm .qty input::-webkit-inner-spin-button { -webkit-appearance: none; margin: 0; }
.rm .tabs-h button { padding: 10px 14px; font-weight: 700; font-size: 15px; margin-bottom: -2px; white-space: nowrap; border: 0; background: none; cursor: pointer; border-bottom: 4px solid transparent; }
.rm .tabs-h button[aria-selected="true"] { border-bottom-color: var(--orange); }
.rm .piece-type { display: inline-flex; }

/* Messages WooCommerce (ajout au panier, erreurs) */
.rm .woocommerce-notices-wrapper:empty { display: none; }
.rm .woocommerce-message, .rm .woocommerce-info, .rm .woocommerce-error { list-style: none; margin: 16px 0; padding: 14px 16px; border-radius: var(--radius-md); background: var(--white); border-left: 6px solid var(--orange); display: flex; flex-wrap: wrap; gap: 12px; align-items: center; justify-content: space-between; font-weight: 600; }
.rm .woocommerce-error { border-left-color: var(--danger); }
.rm .woocommerce-message .button, .rm .woocommerce-info .button { order: 2; display: inline-flex; align-items: center; min-height: 40px; padding: 0 14px; border-radius: var(--radius-md); background: var(--ink); color: var(--white); text-decoration: none; font-weight: 700; font-size: 14px; }
.rm .added_to_cart { display: none; }
.rm .ajax_add_to_cart.loading { opacity: .6; pointer-events: none; }
.rm .ajax_add_to_cart.added::after { content: "✓"; margin-left: 4px; }
/* Sur ordinateur seulement : sur mobile, la fiche est une colonne et la galerie doit prendre toute la largeur. */
@media (min-width: 900px) { .rm .pdp .gallery { align-self: start; align-content: start; } }

/* ---------- Panier et commande ---------- */
.rm .rline > a { display: block; }
.rm .r-name { font-weight: 700; }
.rm .co-step[hidden] { display: none; }
.rm .co-step { display: grid; gap: 18px; align-content: start; }
.rm .co-step h2:focus { outline: none; }
.rm .choice { text-align: left; font: inherit; color: inherit; }
.rm .choice input.sr { position: absolute; }
.rm .choice:has(input:focus-visible), .rm .slot:has(input:focus-visible) { outline: 3px solid var(--ink); outline-offset: 2px; }
.rm label.slot { cursor: pointer; position: relative; }
.rm fieldset.is-missing .slots { outline: 2px solid var(--danger); outline-offset: 4px; border-radius: var(--radius-sm); }
.rm fieldset.is-missing legend::after { content: " · à choisir"; color: var(--danger); font-weight: 700; }
.rm:not([data-recv]) .liv-only { display: none; }

/* Champs WooCommerce habillés comme les champs du design */
.rm .rm-fields, .rm .woocommerce-additional-fields { display: grid; grid-template-columns: 1fr; gap: 14px; }
@media (min-width: 600px) { .rm .rm-fields { grid-template-columns: 1fr 1fr; } .rm .rm-fields .form-row-wide, .rm .rm-fields .pickup, .rm .rm-fields > p.hint { grid-column: 1 / -1; } }
.rm .form-row { margin: 0; display: grid; gap: 6px; }
.rm .form-row label { font-weight: 700; font-size: 15px; }
.rm .form-row .optional { font-weight: 500; color: var(--grey-700); font-size: 14px; }
.rm .form-row abbr.required { text-decoration: none; color: var(--danger); }
.rm .form-row .input-text, .rm .form-row select, .rm .form-row textarea { width: 100%; min-height: var(--tap-min); padding: 10px 14px; border: 1.5px solid var(--grey-500); border-radius: var(--radius-md); background: var(--white); font: inherit; }
.rm .form-row textarea { min-height: 96px; }
.rm .form-row .input-text:focus, .rm .form-row textarea:focus { border-color: var(--ink); outline: 3px solid var(--orange); outline-offset: 0; }
.rm .form-row .description { font-size: 13px; color: var(--grey-700); display: block; }
.rm .form-row.woocommerce-invalid .input-text { border-color: var(--danger); border-width: 2px; }
.rm .form-row.woocommerce-invalid label { color: var(--danger); }
.rm #billing_country_field { display: none; }

/* Moyens de paiement */
.rm .woocommerce-checkout-payment { display: grid; gap: 16px; }
.rm .wc_payment_methods { list-style: none; margin: 0; padding: 0; display: grid; gap: 10px; }
.rm .wc_payment_method { border: 1.5px solid var(--grey-500); border-radius: var(--radius-md); background: var(--white); padding: 12px 14px; }
.rm .wc_payment_method:has(input:checked) { border: 2px solid var(--ink); background: var(--orange-50); }
.rm .wc_payment_method > label { font-weight: 700; cursor: pointer; margin-left: 6px; }
.rm .wc_payment_method .payment_box { margin-top: 10px; font-size: 15px; color: var(--grey-700); }
.rm .wc_payment_method .payment_box p { margin: 0; }
.rm .woocommerce-terms-and-conditions-wrapper { font-size: 15px; }
.rm .woocommerce-privacy-policy-text p { font-size: 13px; color: var(--grey-700); margin: 0 0 8px; }
.rm #place_order { width: 100%; display: inline-flex; align-items: center; justify-content: center; min-height: 52px; border-radius: var(--radius-md); background: var(--orange); color: var(--ink); font-weight: 800; font-size: 17px; border: 0; cursor: pointer; }
.rm #place_order:hover { background: var(--orange-hover); }
.rm .blockUI.blockOverlay { background: rgba(255,255,255,.6) !important; }
.rm .woocommerce-NoticeGroup-checkout { grid-column: 1 / -1; }
.rm .woocommerce-form-coupon-toggle, .rm .checkout_coupon { display: none; }

/* ---------- Pages de contenu ---------- */
.rm .cal-consent { padding: 24px; display: grid; gap: 14px; justify-items: start; }
.rm .cal-consent p { color: var(--grey-700); font-size: 15px; }
.rm .calendly-inline-widget { background: var(--white); }
.rm .rdv-steps { margin: 0; padding-left: 20px; display: grid; gap: 10px; }
.rm .rdv-steps b { font-weight: 700; }
@media (min-width: 900px) { .rm .rdv-layout { grid-template-columns: 1fr 1.2fr; align-items: start; } }
.rm .input.is-error, .rm [aria-invalid="true"] { border-color: var(--danger); }
.rm .prose .stack > * + * { margin-top: 12px; }
.rm .prose h2 { font-size: 22px; margin-top: 28px; }
.rm .prose ul, .rm .prose ol { padding-left: 20px; }
/* Textes légaux et plan du site : largeur de lecture, sous-titres, tableaux et encadrés. */
.rm .prose .stack { max-width: 820px; }
.rm .prose h3 { font-size: 18px; margin-top: 20px; }
.rm .prose em { color: var(--grey-700); }
.rm .prose table { width: 100%; border-collapse: collapse; font-size: 15px; background: var(--white); border-radius: var(--radius-md); overflow: hidden; }
.rm .prose th, .rm .prose td { text-align: left; vertical-align: top; padding: 10px 12px; border-bottom: 1px solid var(--grey-300); }
.rm .prose th { background: var(--ink); color: var(--white); font-weight: 700; }
.rm .prose .table-scroll { overflow-x: auto; }
.rm .prose blockquote { margin: 0; padding: 14px 18px; background: var(--white); border-left: 4px solid var(--orange); border-radius: var(--radius-md); }
.rm .prose blockquote > * + * { margin-top: 10px; }

/* ---------- Page introuvable (404) ---------- */
.rm .e404-in { max-width: 980px; margin: 0 auto; text-align: center; }
.rm .e404 .lead, .rm .e404 .search { max-width: 760px; margin-left: auto; margin-right: auto; }
.rm .e404-num { font-family: var(--font-display); font-size: 96px; line-height: 1; color: var(--orange); letter-spacing: -.02em; margin-bottom: 12px; }
.rm .e404 .search { text-align: left; }
.rm .e404 h1 { font-size: 28px; }
.rm .e404 h1 em { display: block; }
.rm .e404 .quick, .rm .e404 .btns { justify-content: center; }
.rm .e404 .btns { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 28px; }
@media (min-width: 900px) { .rm .e404-num { font-size: 160px; } .rm .e404 h1 { font-size: 42px; } }

/* ---------- Tarif pro réservé aux SIRET vérifiés (voir inc/mode.php) ---------- */
.rm .st-step { display: grid; gap: 14px; }
.rm .st-step[hidden] { display: none; }
.rm .st-err { color: var(--danger); font-weight: 600; font-size: 15px; }
.rm .pp-pro:empty::before { content: "Tarif pro…"; color: var(--grey-700); font-size: 14px; }

/* Accessibilité : repère visible quand le champ de recherche reçoit le focus clavier (le champ lui-même n'a pas de contour). */
.rm .search:has(input:focus-visible) { outline: 3px solid var(--ink); outline-offset: 2px; box-shadow: 0 0 0 6px var(--orange); }

/* Nom sur une photo (portrait de la page À propos), dans le style des étiquettes du site. */
.rm .ph-tag { position: absolute; left: 16px; bottom: 16px; margin: 0; padding: 10px 16px 10px 14px; background: var(--ink); color: var(--white); border-radius: var(--radius-md); border-left: 4px solid var(--orange); display: grid; gap: 2px; line-height: 1.2; }
.rm .ph-tag b { font-family: var(--font-display); font-weight: 400; font-size: 18px; }
.rm .ph-tag span { font-size: 13px; color: var(--on-dark-muted); }

/* Page Contact : la valeur (numéro, adresse…) en normal, pour la distinguer du titre de l'encart en gras. */
.rm .ccard a, .rm .ccard .v { font-weight: 400; }
.rm .ccard a.tlink { text-decoration: underline; text-decoration-color: var(--orange); text-decoration-thickness: 2px; text-underline-offset: 3px; }
.rm .nowrap { white-space: nowrap; }
/* Contact : l'adresse e-mail reste sur une ligne (taille réduite là où l'encart est étroit). */
.rm .ccard a.mail-1l { white-space: nowrap; font-size: 15px; }
/* À propos : titre sur 3 lignes maximum. */
.rm .h1-apropos { font-size: clamp(20px, 5.6vw, 30px); }
@media (min-width: 900px) { .rm .h1-apropos { font-size: clamp(28px, 2.75vw, 38px); } }
/* Accueil : titre sur 3 lignes maximum. */
.rm .hero h1.h1-home { font-size: clamp(20px, 6.2vw, 34px); }
@media (min-width: 900px) { .rm .hero h1.h1-home { font-size: clamp(29px, 3.1vw, 44px); } }
