/* Styles de l'écran reglages. Tout est préfixé par .e-reglages et passe par les variables de core.css. */
.e-reglages .bq-carte { background: var(--surface); border-radius: var(--r-4) var(--r-4) var(--r-4) var(--r-1); padding: 16px; display: flex; flex-direction: column; gap: 14px; box-shadow: var(--ombre); }
.e-reglages .bq-haut { display: grid; grid-template-columns: 52px minmax(0, 1fr) auto; gap: 12px; align-items: center; }
.e-reglages .bq-logo { width: 52px; height: 52px; border-radius: 17px 17px 17px 6px; background: var(--c2); color: var(--sur-accent); display: grid; place-items: center; font-size: var(--t-22); }
.e-reglages .bq-nom { display: flex; flex-direction: column; min-width: 0; }
.e-reglages .bq-nom b { font-family: var(--f-titre); font-weight: 800; font-size: var(--t-22); line-height: 1.1; letter-spacing: -.01em; overflow-wrap: anywhere; }
.e-reglages .bq-nom span { color: var(--encre-2); font-size: var(--t-13); overflow-wrap: anywhere; }
.e-reglages .bq-nom .etiquette { color: var(--c2); }
.e-reglages .bq-faits { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 8px; border-top: 1px solid var(--trait); padding-top: 12px; }
.e-reglages .bq-faits > div { display: flex; flex-direction: column; min-width: 0; }
.e-reglages .bq-faits small { color: var(--encre-2); font-size: var(--t-11); }
.e-reglages .bq-faits b { font-size: var(--t-15); font-weight: 800; overflow-wrap: anywhere; }

/* formulaires */
.e-reglages .rg-grille { display: grid; grid-template-columns: minmax(0, 1fr); gap: 12px; }
.e-reglages .rg-grille > * { min-width: 0; }
.e-reglages .rg-sous { display: flex; flex-direction: column; gap: 8px; }
.e-reglages .rg-actions { display: flex; flex-wrap: wrap; gap: 8px; }
.e-reglages .rg-zone:empty { display: none; }
.e-reglages .rg-note { padding: 0 4px; }
.e-reglages .rg-attente { background: var(--surface); border-radius: var(--r-3); padding: 16px; color: var(--encre-2); box-shadow: var(--ombre); }
.e-reglages .rg-attente[hidden], .e-reglages .sm[hidden] { display: none; }
.e-reglages .rg-barre { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; }
.e-reglages .rg-msg { font-size: var(--t-13); color: var(--encre-2); min-width: 0; flex: 1 1 140px; overflow-wrap: anywhere; }
.e-reglages .rg-msg.est-critique { color: var(--critique); font-weight: 600; }
.e-reglages .rg-adresse { display: flex; flex-direction: column; gap: 2px; background: var(--surface-2); border-radius: var(--r-2); padding: 10px 12px; }
.e-reglages .rg-adresse b { font-size: var(--t-15); overflow-wrap: anywhere; }
.e-reglages textarea { min-height: 96px; }

/* les campagnes suivies */
.e-reglages .cb-liste { display: flex; flex-direction: column; gap: 12px; }
.e-reglages .cb { display: flex; flex-direction: column; gap: 10px; background: var(--surface-2); border-radius: var(--r-3) var(--r-3) var(--r-3) var(--r-1); padding: 12px; }
.e-reglages .cb-tete { display: flex; justify-content: space-between; align-items: center; gap: 8px; flex-wrap: wrap; }

/* le curseur de marge */
.e-reglages .sm { background: var(--surface); border-radius: var(--r-4) var(--r-4) var(--r-4) var(--r-1); padding: 16px; display: flex; flex-direction: column; gap: 14px; box-shadow: var(--ombre); }
.e-reglages .sm-haut { display: flex; justify-content: space-between; align-items: flex-start; gap: 8px; }
.e-reglages .sm-haut > div { display: flex; flex-direction: column; }
.e-reglages .sm-pct { font-size: var(--t-44); line-height: 1; letter-spacing: -.02em; }
.e-reglages .sm-curseur { display: grid; grid-template-columns: 44px minmax(0, 1fr) 44px; gap: 6px; align-items: center; }
.e-reglages .sm-pas { width: 44px; height: 44px; border-radius: 14px 14px 14px 5px; background: var(--creux) !important; display: grid !important; place-items: center; }
.e-reglages .sm-pas .ico { width: 20px; height: 20px; }
.e-reglages .curseur { width: 100%; min-width: 0; height: 44px; margin: 0; accent-color: var(--c3); background: none; cursor: pointer; }
.e-reglages .sm-chiffres { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
.e-reglages .sm-chiffres > div { display: flex; flex-direction: column; background: var(--surface-2); border-radius: var(--r-2) var(--r-2) var(--r-2) 4px; padding: 10px 12px; min-width: 0; }
.e-reglages .sm-chiffres .sm-gros { grid-column: 1 / -1; background: var(--c3-doux); }
.e-reglages .sm-chiffres small { color: var(--encre-2); font-size: var(--t-11); font-weight: 600; }
.e-reglages .sm-chiffres b { font-size: var(--t-30); line-height: 1.05; font-variant-numeric: tabular-nums; }
.e-reglages .sm-chiffres .sm-gros b { font-size: var(--t-44); line-height: 1; }
.e-reglages .sm-echelle { display: flex; flex-direction: column; gap: 6px; padding-top: 14px; }
.e-reglages .sm-piste { position: relative; height: 12px; border-radius: 6px; background: var(--creux); }
.e-reglages .sm-piste em { position: absolute; left: 0; top: 0; bottom: 0; border-radius: 6px; background: var(--bon); transition: width .3s; }
.e-reglages .sm-piste.sous em { background: var(--critique); }
.e-reglages .sm-seuil-marq { position: absolute; top: -6px; bottom: -6px; width: 3px; margin-left: -1.5px; border-radius: 2px; background: var(--encre); transition: left .15s; }
.e-reglages .sm-seuil-marq span { position: absolute; bottom: 100%; left: 50%; transform: translateX(-50%); margin-bottom: 2px; font-family: var(--f-titre); font-stretch: 112%; font-size: var(--t-11); font-weight: 700; letter-spacing: .07em; text-transform: uppercase; color: var(--encre); }
.e-reglages .sm-act { position: absolute; top: 50%; width: 18px; height: 18px; margin: -9px 0 0 -9px; border-radius: 50%; background: var(--surface); box-shadow: 0 0 0 3px var(--encre-2); }
.e-reglages .sm-act span { display: none; }
.e-reglages .sm-bas { display: flex; justify-content: space-between; gap: 8px; color: var(--encre-2); font-size: var(--t-11); font-variant-numeric: tabular-nums; }
.e-reglages .sm-phrase { font-size: var(--t-15); line-height: 1.35; }
.e-reglages .sm-pied { display: flex; justify-content: space-between; align-items: center; gap: 8px; border-top: 1px solid var(--trait); padding-top: 8px; }
.e-reglages .sm-pied small { color: var(--encre-2); font-size: var(--t-13); }

/* les branchements */
.e-reglages .br-etat { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; }

/* l'accès téléphone */
.e-reglages .tel-etapes { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 10px; font-size: var(--t-13); }
.e-reglages .tel-etapes li { display: grid; grid-template-columns: 24px minmax(0, 1fr); gap: 8px; align-items: start; line-height: 1.3; }
.e-reglages .tel-etapes b { width: 24px; height: 24px; border-radius: 8px 8px 8px 3px; background: var(--c3-doux); color: var(--c3); display: grid; place-items: center; font-size: var(--t-13); }

/* le thème */
.e-reglages .themes { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
.e-reglages .th { position: relative; display: flex !important; flex-direction: column; gap: 8px; padding: 8px; border-radius: var(--r-3) var(--r-3) var(--r-3) var(--r-1); box-shadow: inset 0 0 0 1.5px var(--trait-fort); }
.e-reglages .th.choisi { box-shadow: inset 0 0 0 2.5px var(--accent); }
.e-reglages .th-apercu { display: flex; flex-direction: column; gap: 5px; height: 64px; border-radius: 12px; padding: 10px; justify-content: center; }
.e-reglages .th-apercu i { display: block; height: 8px; border-radius: 4px; }
.e-reglages .th-apercu i:nth-child(1) { width: 60%; } .e-reglages .th-apercu i:nth-child(2) { width: 85%; } .e-reglages .th-apercu i:nth-child(3) { width: 40%; }
.e-reglages .th-light .th-apercu { background: var(--p-nuage); } .e-reglages .th-light .th-apercu i { background: var(--p-bord); opacity: .75; }
.e-reglages .th-dark .th-apercu { background: var(--p-bord); } .e-reglages .th-dark .th-apercu i { background: var(--p-nuage); opacity: .75; }
.e-reglages .th-nom { display: flex; align-items: center; gap: 6px; font-weight: 700; font-size: var(--t-13); padding: 0 2px 2px; }
.e-reglages .th-nom .ico { width: 18px; height: 18px; }
.e-reglages .th-coche { position: absolute; right: 12px; top: 12px; width: 22px; height: 22px; border-radius: 50%; background: var(--accent); color: var(--sur-accent); display: grid; place-items: center; }
.e-reglages .th-coche .ico { width: 14px; height: 14px; }

/* plus large : formulaires sur 2 colonnes */
@container app (min-width: 700px) {
  .e-reglages .rg-grille { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
