/* ==========================================================================
   NaluScore — board-finder.css
   Styles spécifiques à la page Board Finder
   Réutilise les variables de style.css (:root)
   ========================================================================== */

/* --------------------------------------------------------------------------
   BOUTON RETOUR (header nav)
   Réutilise .feedback-nav-btn de style.css
   -------------------------------------------------------------------------- */
.feedback-nav-btn {
  background: rgba(255, 255, 255, 0.06);
  border: 1px solid rgba(255, 255, 255, 0.1);
  color: #9ca3af;
  font-size: 0.8rem;
  font-weight: 600;
  padding: 0.45rem 1rem;
  border-radius: 999px;
  cursor: pointer;
  text-decoration: none;
  transition: color var(--transition), border-color var(--transition), background var(--transition);
}

.feedback-nav-btn:hover {
  color: var(--cyan);
  border-color: rgba(0, 245, 255, 0.4);
  background: rgba(0, 245, 255, 0.07);
}

/* --------------------------------------------------------------------------
   CARTES QUESTIONNAIRE
   -------------------------------------------------------------------------- */
.bf-card {
  background: var(--card-bg);
  border: 1px solid var(--card-border);
}

.bf-card-title {
  color: #fff;
  font-weight: 700;
  font-size: 1rem;
  letter-spacing: -0.01em;
}

.bf-label {
  color: #9ca3af;
  font-size: 0.8rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.08em;
}

.bf-value-display {
  color: var(--cyan);
  font-size: 1.1rem;
  font-weight: 800;
  font-variant-numeric: tabular-nums;
}

/* --------------------------------------------------------------------------
   SLIDER
   -------------------------------------------------------------------------- */
.bf-slider {
  -webkit-appearance: none;
  appearance: none;
  width: 100%;
  height: 4px;
  border-radius: 999px;
  background: linear-gradient(
    to right,
    var(--cyan) 0%,
    var(--neon-green) var(--slider-pct, 50%),
    rgba(255, 255, 255, 0.1) var(--slider-pct, 50%)
  );
  outline: none;
  cursor: pointer;
  transition: box-shadow var(--transition);
}

.bf-slider:hover {
  box-shadow: 0 0 8px rgba(0, 245, 255, 0.3);
}

.bf-slider::-webkit-slider-thumb {
  -webkit-appearance: none;
  appearance: none;
  width: 20px;
  height: 20px;
  border-radius: 50%;
  background: linear-gradient(135deg, var(--cyan), var(--neon-green));
  cursor: pointer;
  border: 2px solid var(--bg-dark);
  box-shadow: 0 0 10px rgba(0, 245, 255, 0.5);
  transition: transform var(--transition), box-shadow var(--transition);
}

.bf-slider::-webkit-slider-thumb:hover {
  transform: scale(1.15);
  box-shadow: 0 0 16px rgba(0, 245, 255, 0.7);
}

.bf-slider::-moz-range-thumb {
  width: 20px;
  height: 20px;
  border-radius: 50%;
  background: linear-gradient(135deg, var(--cyan), var(--neon-green));
  cursor: pointer;
  border: 2px solid var(--bg-dark);
  box-shadow: 0 0 10px rgba(0, 245, 255, 0.5);
}

/* --------------------------------------------------------------------------
   BOUTONS TOGGLE (niveau / forme / conditions)
   -------------------------------------------------------------------------- */
.bf-toggle {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 4px;
  padding: 1rem 0.75rem;
  border-radius: 12px;
  border: 1px solid rgba(255, 255, 255, 0.08);
  background: rgba(255, 255, 255, 0.04);
  cursor: pointer;
  transition: all var(--transition);
  text-align: center;
}

.bf-toggle:hover {
  border-color: rgba(0, 245, 255, 0.3);
  background: rgba(0, 245, 255, 0.06);
}

.bf-toggle.is-active {
  border-color: var(--cyan);
  background: rgba(0, 245, 255, 0.1);
  box-shadow: 0 0 16px rgba(0, 245, 255, 0.2), inset 0 0 20px rgba(0, 245, 255, 0.05);
}

.bf-toggle-icon {
  font-size: 1.5rem;
  line-height: 1;
}

.bf-toggle-label {
  color: #fff;
  font-size: 0.8rem;
  font-weight: 700;
}

.bf-toggle-sub {
  color: #6b7280;
  font-size: 0.68rem;
  line-height: 1.3;
}

.bf-toggle.is-active .bf-toggle-label {
  color: var(--cyan);
}

/* Conditions — boutons légèrement plus hauts */
.bf-toggle--cond {
  padding: 1.2rem 0.75rem;
}

/* --------------------------------------------------------------------------
   LOADING WAVE (avant l'affichage du résultat)
   -------------------------------------------------------------------------- */
.bf-loading-wave {
  width: 140px;
}

.bf-wave-anim {
  stroke-dasharray: 400;
  stroke-dashoffset: 400;
  animation: waveDrawBF 1.8s ease-in-out infinite;
}

@keyframes waveDrawBF {
  0%   { stroke-dashoffset: 400; opacity: 0.3; }
  50%  { stroke-dashoffset: 0;   opacity: 1; }
  100% { stroke-dashoffset: -400; opacity: 0.3; }
}

/* --------------------------------------------------------------------------
   CARTES RÉSULTAT
   -------------------------------------------------------------------------- */
.bf-result-card {
  background: var(--card-bg);
  border: 1px solid var(--card-border);
}

/* Carte héro — dégradé de bordure subtil */
.bf-result-card--hero {
  border-color: rgba(0, 245, 255, 0.15);
  background: linear-gradient(
    135deg,
    rgba(0, 245, 255, 0.05) 0%,
    rgba(0, 255, 136, 0.03) 100%
  );
}

/* Icône planche */
.bf-board-icon {
  width: 52px;
  height: 52px;
  background: rgba(0, 245, 255, 0.07);
  border: 1px solid rgba(0, 245, 255, 0.15);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 10px;
}

/* Icônes dimensions (Volume, Longueur, Analyse) */
.bf-dim-icon {
  width: 36px;
  height: 36px;
  min-width: 36px;
  background: rgba(0, 245, 255, 0.07);
  border: 1px solid rgba(0, 245, 255, 0.12);
  border-radius: 10px;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 7px;
}

/* --------------------------------------------------------------------------
   POINTS ANIMÉS (loading IA)
   -------------------------------------------------------------------------- */
.bf-ia-dots {
  display: flex;
  gap: 5px;
  align-items: center;
}

.bf-ia-dots span {
  display: block;
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--cyan);
  opacity: 0.3;
  animation: iaDotPulse 1.2s ease-in-out infinite;
}

.bf-ia-dots span:nth-child(2) { animation-delay: 0.2s; }
.bf-ia-dots span:nth-child(3) { animation-delay: 0.4s; }

@keyframes iaDotPulse {
  0%, 100% { opacity: 0.2; transform: scale(0.8); }
  50%       { opacity: 1;   transform: scale(1.15); background: var(--neon-green); }
}

/* --------------------------------------------------------------------------
   BOUTON SECONDAIRE (Recommencer)
   -------------------------------------------------------------------------- */
.bf-secondary-btn {
  background: rgba(255, 255, 255, 0.06);
  border: 1px solid rgba(255, 255, 255, 0.1);
  color: #d1d5db;
  cursor: pointer;
  transition: all var(--transition);
  font-family: inherit;
}

.bf-secondary-btn:hover {
  border-color: rgba(0, 245, 255, 0.3);
  color: var(--cyan);
  background: rgba(0, 245, 255, 0.06);
}

/* --------------------------------------------------------------------------
   SECTION RÉSULTAT — animation d'entrée
   -------------------------------------------------------------------------- */
#result {
  animation: none;
}

#result.visible {
  animation: resultFadeIn 0.4s ease-out forwards;
}

@keyframes resultFadeIn {
  from { opacity: 0; transform: translateY(16px); }
  to   { opacity: 1; transform: translateY(0); }
}

/* --------------------------------------------------------------------------
   ÉTAT DISABLED du bouton submit pendant le chargement
   -------------------------------------------------------------------------- */
#bf-submit:disabled {
  opacity: 0.6;
  cursor: not-allowed;
}
