/* ════════════════════════════════════════════════════════════
   Style.theme-toggle.css — Toggle switch Clair / Sombre
   Positionné en haut à droite, style doré cohérent
════════════════════════════════════════════════════════════ */

#theme-toggle-wrapper {
  position: fixed;
  top: 41px;
  left: 30px;              /* à gauche du coin décoratif (.c-tr à right:20px) */
  z-index: 1000;
  display: flex;
  align-items: center;
  gap: 7px;
}

.toggle-icon {
  font-size: 15px;
  line-height: 1;
  color: var(--gold-dim);
  opacity: 0.6;
  transition: opacity 0.3s, color 0.3s;
  user-select: none;
}

/* Icône active selon le thème courant */
[data-theme="light"] .toggle-icon-dark  { opacity: 0.5; }
[data-theme="light"] .toggle-icon-light { opacity: 1; color: var(--gold); }
:not([data-theme="light"]) .toggle-icon-dark  { opacity: 1; color: var(--gold); }
:not([data-theme="light"]) .toggle-icon-light { opacity: 0.5; }

/* Conteneur du switch */
#theme-toggle-switch {
  position: relative;
  width: 38px;
  height: 20px;
  cursor: pointer;
  display: block;
}

/* Input caché */
#theme-toggle-switch input {
  opacity: 0;
  width: 0;
  height: 0;
  position: absolute;
}

/* Piste du switch */
#theme-toggle-slider {
  position: absolute;
  inset: 0;
  background: rgba(201,168,76,0.10);
  border: 1px solid rgba(201,168,76,0.30);
  border-radius: 20px;
  transition: background 0.3s, border-color 0.3s;
}

/* Curseur rond du switch */
#theme-toggle-slider::before {
  content: '';
  position: absolute;
  top: 3px;
  left: 3px;
  width: 12px;
  height: 12px;
  background: var(--gold-dim);
  border-radius: 50%;
  transition: transform 0.3s cubic-bezier(0.4,0,0.2,1), background 0.3s;
  box-shadow: 0 0 6px rgba(201,168,76,0.35);
}

/* État coché → thème clair */
#theme-toggle-switch input:checked + #theme-toggle-slider {
  background: rgba(201,168,76,0.18);
  border-color: rgba(201,168,76,0.55);
}

#theme-toggle-switch input:checked + #theme-toggle-slider::before {
  transform: translateX(18px);
  background: var(--gold);
  box-shadow: 0 0 10px rgba(201,168,76,0.65);
}
