/*
Theme Name: Avada Child
Description: Child theme for Avada theme
Author: ThemeFusion
Author URI: https://theme-fusion.com
Template: Avada
Version: 1.0.0
Text Domain:  Avada
*/
  
/* ============================================================================
STUDORIA – Activation des styles uniquement dans les LEÇONS

IMPORTANT :
Pour que les styles ci-dessous ne s’appliquent QUE dans les pages de leçon,
il faut les précéder de la classe CSS suivante : .studoria-lecon

→ Cette classe est automatiquement ajoutée au <body> uniquement sur les pages de leçon
   grâce à une fonction dans functions.php (basée sur le type de contenu "lesson").
============================================================================ */

/* Surlignage du texte en gras sur les leçons */
body.studoria-lecon strong { animation: highlight 1.5s 1.5s forwards; background: linear-gradient(90deg, #ffff66 50%, transparent 50%); background-size: 200% 100%; background-position: 100% 0; }
body.studoria-lecon mark { background: linear-gradient(120deg, #e2e2e2 0%, #f9f9fb 100%); background-repeat: no-repeat; background-size: 100% 40%; background-position: 0 90%; }
@keyframes highlight { to { background-position: 0 0; } }
@-webkit-keyframes highlight { to { background-position: 0 0; } }

/* Supression de la ligne "A propos de la leçon qui était en tête de chaque cours" */
body.studoria-lecon .tutor-col-xl-8 > .tutor-fs-5.tutor-fw-medium.tutor-color-black.tutor-mb-12 { display: none; }

/* Animation sur les onglets dans les leçons / Exercice(s) */
@keyframes bounceZoom { 0%, 100% { transform: translateY(0) scale(1); } 50% { transform: translateY(-5px) scale(1.05); } }
body.studoria-lecon .tutor-nav:not(.tutor-nav-pills):not(.tutor-nav-tabs) .tutor-nav-link.is-active { animation: bounceZoom 1s infinite ease-in-out; display: inline-block; }

/* Animation et visuel sur blockquote */
body.studoria-lecon blockquote { position: relative; border-left: 4px solid; border-color: var(--primary_color); border-radius: 0px; font-style: italic; overflow: visible; }
body.studoria-lecon blockquote::before { content: ""; position: absolute; left: -35px; top: 50%; width: 24px; height: 24px; transform: translateY(-25px); background-image: url('https://www.studoria.fr/wp-content/uploads/2024/10/favicon-64.png'); background-size: contain; background-repeat: no-repeat; animation: floatMiddle 8s ease-in-out infinite; }
@keyframes floatMiddle { 0%, 100% { transform: translateY(-25px); } 50% { transform: translateY(25px); } }


/* Dans le plugin tutor : modification des boutons suivants précédents des cours */
/* Boutons actifs (ni première ni dernière leçon) */
.tutor-single-course-content-prev a:not([disabled]),.tutor-single-course-content-next a:not([disabled]){font-size:18px;font-family:"Concert One";color:#ffffff;background-color:var(--tutor-color-primary);transition:background-color .3s ease,transform .3s ease;cursor:pointer;}
.tutor-single-course-content-prev a:not([disabled]):hover,.tutor-single-course-content-next a:not([disabled]):hover{background-color:var(--tutor-color-primary-hover);transform:scale(1.03);}
/* Boutons désactivés (première ou dernière leçon) */
.tutor-single-course-content-prev a[disabled],.tutor-single-course-content-next a[disabled]{font-size:18px;font-family:"Concert One";color:#aaa;background-color:#ccc;cursor:not-allowed;opacity:.6;}
/* Espaces superflus à la fin de la leçon */
.tutor-course-spotlight-wrapper .tutor-course-spotlight-tab { padding-top: 0px !important; padding-bottom: 0px !important; }


/* Ajout d'un padding pour le lecteur audio Studoria */
.mejs-container * {
  padding-bottom: 10px!important;
}

/* Masque les 3 cartes du tableau de bord */
.tutor-gx-lg-4 {
  display: none !important;
}
/* Masque le titre cours en cours */
.tutor-frontend-dashboard-course-progress > .tutor-fs-5.tutor-fw-medium.tutor-color-black.tutor-text-capitalize.tutor-mb-24 {
  display: none !important;
}
.tutor-ratings {
  display: none !important;
}

/* Icone custom pour le Suivi pédagogique du tableau de bord */
li.tutor-dashboard-menu-studoria-custom .tutor-dashboard-menu-item-icon::before {
    content: "\e923"; /* Icône du graphe Tutor (📊) */
    font-family: 'tutor-icon' !important;
    font-style: normal;
    font-weight: normal;
    font-variant: normal;
    text-transform: none;
    line-height: 1;
    speak: none;
    display: inline-block;
    font-size: 16px;
    color: var(--tutor-primary-color);
}

/* Fond quiz */
.tutor-course-single-content-wrapper #tutor-single-entry-content .tutor-quiz-wrapper {
  min-height: 100vh;
}

/* Exemple : masquer la 7e et 8e ligne si elles sont fixes dans l’ordre */
.tutor-dashboard-profile-data .tutor-row:nth-of-type(7),
.tutor-dashboard-profile-data .tutor-row:nth-of-type(8) {
    display: none !important;
}





/* Jamais afficher le menu dashboard sur mobile */
.tutor-dashboard #tutor-dashboard-footer-mobile {
  display: none !important;}
  
/* Toujours afficher le menu dashboard sur mobile */
.tutor-dashboard-left-menu {
    transform: translateX(0) !important;
    opacity: 1 !important;
    visibility: visible !important;
    display: block !important;
    position: relative !important;
}

/* Empêche le panneau de flotter par-dessus le contenu */
.tutor-dashboard-left-menu.tutor-dashboard-menu-hide {
    transform: translateX(0) !important;
    opacity: 1 !important;
    visibility: visible !important;
}

/* Supprime l'effet "slide" en mobile */
@media (max-width: 768px) {
    .tutor-dashboard-left-menu {
        max-width: 100% !important;
        width: 100% !important;
    }
}



/* Corrige les Contrast Errors */
.tutor-color-muted{color:#4a4a4a !important;}




/* Chapitre cliquable (ex-topic vide) */
.tutor-topic-chapter > .tutor-accordion-item-header{
  pointer-events:auto;
  cursor:pointer;
  font-weight:600;
  text-transform:uppercase;
  color:inherit;             /* comme avant */
  position:relative;
  padding:10px 20px 10px 10px;
}

/* Chapitre ouvert = vert */
.tutor-topic-chapter > .tutor-accordion-item-header.is-active{
  color: var(--tutor-color-primary);
}

/* Titre dans le header (mêmes valeurs qu'avant) */
.tutor-topic-chapter .tutor-course-topic-title{
  font-weight:600;
  font-size:.95rem;
  padding:6px 0 4px 0;
}

/* Chevron natif : rotation avec l'état is-active */
.tutor-topic-chapter > .tutor-accordion-item-header::after{
  transition:transform .3s ease;
  transform:rotate(0deg);            /* fermé = droite */
}
.tutor-topic-chapter > .tutor-accordion-item-header.is-active::after{
  transform:rotate(-90deg);          /* ouvert = haut */
}

/* Corps sans padding parasite et corps vide masqué (comme avant) */
.tutor-course-topic .tutor-accordion-item-body:empty{
  display:none!important;
  padding:0!important;
  margin:0!important;
}
.tutor-course-single-sidebar-wrapper .tutor-accordion-item-body{
  padding:0!important;
}



/* Style du bouton Suivi pédagogique dans le tableau de bord des enseignants et des responsables pédagogiques */
li.tutor-dashboard-menu-studoria-dashboard > a {display: flex; align-items: center;}
li.tutor-dashboard-menu-studoria-dashboard > a::before {content: ""; width: 20px; height: 20px; margin-right: 5px; -webkit-mask: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'><path fill='%23000' d='M4 2h14a2 2 0 0 1 2 2v16a1 1 0 0 1-1 1H4a2 2 0 0 1-2-2V4a2 2 0 0 1 2-2zm2 4v2h10V6H6zm0 4v2h10v-2H6zm0 4v2h7v-2H6z'/></svg>") no-repeat center / contain;  mask: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'><path fill='%23000' d='M4 2h14a2 2 0 0 1 2 2v16a1 1 0 0 1-1 1H4a2 2 0 0 1-2-2V4a2 2 0 0 1 2-2zm2 4v2h10V6H6zm0 4v2h10v-2H6zm0 4v2h7v-2H6z'/></svg>") no-repeat center / contain; background: #598a2f;}
