/* Chef Bé : interrupteurs à la place des cases à cocher sur la partie publique.
 * Les cases déjà habillées ailleurs (interrupteurs .tgl, bootstrap-toggle, cartes de choix,
 * panneau des cookies, téléversement) sont laissées telles quelles.
 * Pour garder une vraie case à cocher, ajouter la classe .cbe-no-toggle. Le bouton de thème (#toggle-mode) garde son style d'origine.
 */
:root { --cbe-tg-off: rgba(127, 127, 127, .45); --cbe-tg-on: #04abf2; --cbe-tg-knob: #fff; }

input[type=checkbox]:not(.tgl):not(.custom-control-input):not([data-toggle=toggle]):not(.cbe-no-toggle):not(#toggle-mode):not(.pt_vdo_cstm_radio input):not(.select_radio_btn_innr input):not(.pt-upload-switch input):not(.cbe-cs-check input):not(.checkbox input) {
	-webkit-appearance: none; appearance: none;
	display: inline-block; flex: 0 0 36px;
	width: 36px; height: 20px; min-width: 36px;
	margin: 0 8px 0 0; padding: 0; border: 0;
	border-radius: 999px; background: var(--cbe-tg-off);
	position: relative; vertical-align: middle; cursor: pointer;
	transition: background .15s;
}
input[type=checkbox]:not(.tgl):not(.custom-control-input):not([data-toggle=toggle]):not(.cbe-no-toggle):not(#toggle-mode):not(.pt_vdo_cstm_radio input):not(.select_radio_btn_innr input):not(.pt-upload-switch input):not(.cbe-cs-check input):not(.checkbox input)::after {
	content: ''; position: absolute; top: 2px; left: 2px;
	width: 16px; height: 16px; border-radius: 50%;
	background: var(--cbe-tg-knob); box-shadow: 0 1px 2px rgba(0, 0, 0, .4);
	transition: transform .15s;
}
input[type=checkbox]:not(.tgl):not(.custom-control-input):not([data-toggle=toggle]):not(.cbe-no-toggle):not(#toggle-mode):not(.pt_vdo_cstm_radio input):not(.select_radio_btn_innr input):not(.pt-upload-switch input):not(.cbe-cs-check input):not(.checkbox input):checked { background: var(--cbe-tg-on); }
input[type=checkbox]:not(.tgl):not(.custom-control-input):not([data-toggle=toggle]):not(.cbe-no-toggle):not(#toggle-mode):not(.pt_vdo_cstm_radio input):not(.select_radio_btn_innr input):not(.pt-upload-switch input):not(.cbe-cs-check input):not(.checkbox input):checked::after { transform: translateX(16px); }
input[type=checkbox]:not(.tgl):not(.custom-control-input):not([data-toggle=toggle]):not(.cbe-no-toggle):not(#toggle-mode):focus-visible { outline: 2px solid var(--cbe-tg-on); outline-offset: 2px; }
input[type=checkbox]:not(.tgl):not(.custom-control-input):not([data-toggle=toggle]):not(.cbe-no-toggle):not(#toggle-mode):disabled { opacity: .45; cursor: not-allowed; }

/* Cases d'origine dessinées par le libellé (.pt_vdo_cstm_radio) : le rond devient un interrupteur. */
.pt_vdo_cstm_radio input[type=checkbox] + label { padding-left: 56px; }
.pt_vdo_cstm_radio input[type=checkbox] + label::before {
	width: 36px; height: 20px; top: 50%; left: 10px; margin-top: -10px;
	border: 0; border-radius: 999px; background: var(--cbe-tg-off);
}
.pt_vdo_cstm_radio input[type=checkbox] + label::after {
	width: 16px; height: 16px; top: 50%; left: 12px; margin-top: -8px;
	border-radius: 50%; background: var(--cbe-tg-knob); box-shadow: 0 1px 2px rgba(0, 0, 0, .4);
	transition: transform .15s;
}
.pt_vdo_cstm_radio input[type=checkbox]:checked + label::before { background: var(--cbe-tg-on); }
.pt_vdo_cstm_radio input[type=checkbox]:checked + label::after {
	width: 16px; height: 16px; top: 50%; left: 12px; margin-top: -8px;
	background: var(--cbe-tg-knob); transform: translateX(16px);
}
.pt_vdo_cstm_radio input[type=checkbox]:focus-visible + label { outline: 2px solid var(--cbe-tg-on); outline-offset: 2px; }

/* Libellés qui contiennent la case : alignement propre, le texte ne passe plus sous l'interrupteur. */
label:has(> input[type=checkbox]:not(.tgl):not(.custom-control-input):not([data-toggle=toggle]):not(.cbe-no-toggle):not(#toggle-mode)) { display: inline-flex; align-items: center; gap: 0; cursor: pointer; }
.terms label:has(> input[type=checkbox]) { display: block; }
.terms label > input[type=checkbox] { margin-top: -2px; }
