/**
 * SPOTD — couche UX « humaine » (2026)
 * Charge après spotd-drafted-theme.css : calme les effets « glow / IA », améliore lisibilité et tactiles.
 * Voir aussi : assets/css/spotd-design-system.css (tokens).
 */

/* -------------------------------------------------------------------------- */
/* Accessibilité : respect OS + préférence compte (data-spotd-reduce-motion)   */
/* -------------------------------------------------------------------------- */
@media (prefers-reduced-motion: reduce) {
  body.spotd-theme-drafted *,
  body.spotd-theme-drafted *::before,
  body.spotd-theme-drafted *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
    scroll-behavior: auto !important;
  }
}

body.spotd-theme-drafted[data-spotd-reduce-motion="1"] *,
body.spotd-theme-drafted[data-spotd-reduce-motion="1"] *::before,
body.spotd-theme-drafted[data-spotd-reduce-motion="1"] *::after {
  animation-duration: 0.01ms !important;
  animation-iteration-count: 1 !important;
  transition-duration: 0.01ms !important;
  scroll-behavior: auto !important;
}

/* -------------------------------------------------------------------------- */
/* Hiérarchie : moins d’ombre « néon », surfaces plus plates (pro / humain)   */
/* -------------------------------------------------------------------------- */
body.spotd-theme-drafted .btn-primary {
  box-shadow: 0 4px 16px rgba(99, 102, 241, 0.22) !important;
}

body.spotd-theme-drafted .btn-primary:hover {
  box-shadow: 0 6px 20px rgba(124, 92, 255, 0.28) !important;
}

body.spotd-theme-drafted .btn-secondary,
body.spotd-theme-drafted .btn-outline-light {
  box-shadow: none !important;
}

body.spotd-theme-drafted .spotd-surface,
body.spotd-theme-drafted .card.border-secondary.bg-dark {
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.22) !important;
}

body.spotd-theme-drafted .spotd-surface--accent {
  box-shadow:
    0 4px 24px rgba(0, 0, 0, 0.24),
    0 0 0 1px rgba(99, 102, 241, 0.12) !important;
}

/* -------------------------------------------------------------------------- */
/* Zones de lecture : largeur max confortable (pages longues / dashboard)      */
/* -------------------------------------------------------------------------- */
.spotd-readable-width {
  max-width: min(100%, var(--spotd-content-max-width, 72rem));
  margin-inline: auto;
}

/* -------------------------------------------------------------------------- */
/* Mobile : zones tactiles minimum pour actions principales                    */
/* -------------------------------------------------------------------------- */
@media (max-width: 767.98px) {
  body.spotd-theme-drafted .btn:not(.btn-sm):not(.btn-link) {
    min-height: 2.75rem;
    padding-top: 0.5rem;
    padding-bottom: 0.5rem;
  }

  body.spotd-theme-drafted .form-control:not(textarea),
  body.spotd-theme-drafted .form-select {
    min-height: 2.75rem;
  }
}

/* -------------------------------------------------------------------------- */
/* États vides / messages — cadre discret                                     */
/* -------------------------------------------------------------------------- */
.spotd-empty-hint {
  border: 1px dashed rgba(255, 255, 255, 0.14);
  border-radius: var(--spotd-radius-md, 14px);
  background: rgba(255, 255, 255, 0.03);
  padding: 1.25rem 1.5rem;
  color: rgba(255, 255, 255, 0.72);
  font-size: 0.9375rem;
  line-height: 1.5;
}

/* Espace membre : halo haut de page un peu plus discret */
body.spotd-dashboard-shell .spotd-dashboard-main::before {
  opacity: 0.55;
}
