/* Formulaire global */
.formulaire-enseignant {
    display: flex;
    flex-wrap: wrap;
    gap: 20px;
    max-width: 900px;
    margin: 0 auto;
}

/* Chaque champ "simple" */
.formulaire-enseignant .champ {
    flex: 1 1 45%;
    display: flex;
    flex-direction: column;
}

/* Champs sur une ligne complète */
.formulaire-enseignant .champ-full {
    flex: 1 1 100%;
}

/* Ligne contenant deux champs (ex : code postal + checkbox) */
.champ-row {
    display: flex;
    flex-wrap: nowrap;
    width: 100%;
    gap: 20px;

}

/* Code postal champ */
.cp-champ {
    flex: 1 1 50%;
    max-width: 50%;
}

/* Checkbox champ */
.deja-compte-champ {
    flex: 1 1 50%;
    max-width: 50%;
    display: none; /* par défaut */
    justify-content: flex-start;


}

/* Affiche la checkbox quand nécessaire */
.deja-compte-champ.active {
    display: flex;
}

/* Style des inputs */
.formulaire-enseignant input,
.formulaire-enseignant textarea {
    width: 100%;
    padding: 12px;
    border: 1px solid #ccc;
    border-radius: 4px;
    font-size: 16px;
}
.champ-full{
    margin-top: -13%;
}

/* Labels */
.formulaire-enseignant label {
    margin-bottom: 5px;

    font-size: 14px;
}
.wpcf7-checkbox.custom-checkbox .wpcf7-list-item label {
    display: flex;
    align-items: center;
    margin-top: -18%;
    cursor: pointer;
}

.wpcf7-checkbox.custom-checkbox .wpcf7-list-item label input[type="checkbox"] {
    margin-right: 10px;
    width: 20px;
    height: 20px;
    cursor: pointer;

}
.fiche-ecole-inline {
    display: flex;
    align-items: center;
    gap: 20px; /* Espace entre les infos */
    background-color: #f9f9f9;
    border: 1px solid #ddd;
    border-radius: 4px;
    padding: 10px 15px;
    margin-top: 10px;
    width: 100%;
    box-sizing: border-box;
    font-size: 14px;
    color: #333;
}

.fiche-ecole-inline span {
    white-space: nowrap; /* Empêche le retour à la ligne */
}

/* Responsive */
@media (max-width: 768px) {
    .formulaire-enseignant .champ,
    .formulaire-enseignant .champ-full {
        flex: 1 1 100%;
    }

    .champ-row {
        flex-direction: column;
    }

    .cp-champ,
    .deja-compte-champ {
        flex: 1 1 100%;

    }
    .cp-champ{
        max-width: 100%;
    }
    .fiche-ecole-inline {
        flex-direction: column;
        align-items: flex-start;
        gap: 5px;
    }

    .fiche-ecole-inline span {
        white-space: normal; /* Autorise le retour à la ligne en mobile */
    }
}


@keyframes onAutoFillStart {
    from {}
    to {}
}

input:-webkit-autofill {
    animation-name: onAutoFillStart;
    animation-duration: 0.01s;
    animation-iteration-count: 1;
}
.niveau-classe-buttons {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    
}

.niveau-btn {
    padding: 10px 15px;
    border: 1px solid #ccc;
    background-color: #f9f9f9;
    cursor: pointer;
    user-select: none;
}

.niveau-btn.active {
    background-color: #e4332d;
    color: #fff;
    border-color: #e4332d;
}
.niveau-btn.disabled {
    background-color: #eee;
    color: #999;
    cursor: not-allowed;
    pointer-events: none;
}
.niveau-classe-wrapper p > label.niveaux {
    display: block; /* Ou ce que tu veux */
    /* Ton styling normal */
}

.niveau-classe-wrapper > p {
    margin: 0;
    padding: 0;
}
.wpcf7-response-output{
    margin-top: -7% !important;
}






.ressource-card:hover {
    transform: scale(1.01);
}

.ressource-image img {
    width: 150px;
    height: 100%;
    object-fit: cover;
    display: block;
}

.ressource-content {
    padding: 15px;
    display: flex;
    flex-direction: column;
    justify-content: center;
    flex: 1;
}

.ressource-content h4 {
    margin: 0 0 10px;
    font-size: 1.1rem;
    color: #333;
}

.btn-telechargement {
    background: #0073aa;
    color: #fff;
    text-decoration: none;
    padding: 8px 12px;
    border-radius: 5px;
    display: inline-block;
    font-weight: bold;
}

.btn-telechargement:hover {
    background: #005f8d;
}

/* Responsive : 1 par ligne */
@media screen and (max-width: 768px) {
    .ressource-card {
        width: 100%;
        flex-direction: column;
    }

    .ressource-image img {
        width: 100%;
        height: auto;
    }
}




.ressource-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 12px 20px rgba(0, 0, 0, 0.1);
}

.ressource-image img {
    width: 100px;
    height: auto;
    object-fit: cover;
    display: block;
}

.ressource-content {
    padding-left: 15px;
    display: flex;
    flex-direction: column;
    justify-content: center;
    flex: 1;
}

.ressource-titre {
    margin: 0;
    font-size: 1rem;
    font-weight: bold;
    color: #333;
}

/* Bouton panier */
.add-to-cart-icon {
    position: absolute;
    top: 10px;
    right: 10px;
    background: #0073aa;
    color: white;
    border-radius: 50%;
    padding: 8px;
    font-size: 16px;
    text-decoration: none;
    transition: background 0.3s ease;
}

.add-to-cart-icon:hover {
    background: #005f8d;
}

/* Responsive : 1 par ligne */
@media screen and (max-width: 768px) {
    .ressource-card {
        flex: 1 1 100%;
        max-width: 100%;
        flex-direction: row;
    }

    .ressource-image img {
        width: 80px;
    }
}


.ressource-fichier {
    margin: 0;
    font-size: 0.9rem;
    color: #666;
}


.ressource-badge {
    position: absolute;
    top: 10px;
    left: 10px;
    background: #0073aa;
    color: white;
    padding: 4px 8px;
    border-radius: 4px;
    font-size: 11px;
    text-transform: uppercase;

}
.ressource-badge.lecture {
    background: #ffc107; /* Jaune */
    width: 25%;
}
.ressource-badge.telechargement {
    background: #28a745; /* Vert */
}
.badge-type {
    display: inline-block;
    padding: 2px 8px;
    border-radius: 3px;
    font-size: 12px;
    color: #fff;
    width: 25%;
    text-align: center;
}

.badge-lecture {
    background: #0073aa;
}

.badge-telechargement {
    background: #28a745;
}

/* Version Mobile : badge pleine largeur */
@media screen and (max-width: 768px) {
    .badge-type {
        width: 100%;
        display: block;
        margin-top: 5px;
    }
    .ressources-grid {

        flex-wrap: wrap;
        gap: 20px;
    }
    .ressource-card {
        display: flex;
        flex-direction: row;
        background: #fff;
        border: 1px solid #ddd;
        border-radius: 10px;
        overflow: hidden;

        box-shadow: 0 4px 10px rgba(0, 0, 0, 0.05);
        transition: transform 0.2s ease;
    }
    .ressource-card {
        display: flex;
        align-items: center;
        background: #fff;
        border: 2px solid #e0e0e0;
        border-left: 6px solid #0073aa;
        border-radius: 10px;
        overflow: hidden;
        text-decoration: none;
        color: inherit;
        transition: all 0.3s ease;
        box-shadow: 0 4px 8px rgba(0, 0, 0, 0.05);

        box-sizing: border-box;
        padding: 10px;
        position: relative;
    }
}
@media screen and (min-width: 769px) {

    .ressources-grid {
        display: flex;
        flex-wrap: wrap;
        gap: 20px;
        margin-top: 20px;
    }
    .ressource-card {
        display: flex;
        flex-direction: row;
        background: #fff;
        border: 1px solid #ddd;
        border-radius: 10px;
        overflow: hidden;
        width: calc(50% - 10px); /* Deux par ligne */
        box-shadow: 0 4px 10px rgba(0, 0, 0, 0.05);
        transition: transform 0.2s ease;
    }
    .ressource-card {
        display: flex;
        align-items: center;
        background: #fff;
        border: 2px solid #e0e0e0;
        border-left: 6px solid #0073aa;
        border-radius: 10px;
        overflow: hidden;
        text-decoration: none;
        color: inherit;
        transition: all 0.3s ease;
        box-shadow: 0 4px 8px rgba(0, 0, 0, 0.05);
        flex: 1 1 calc(50% - 10px);
        max-width: calc(50% - 10px);
        box-sizing: border-box;
        padding: 10px;
        position: relative;
    }
}
.filtres-container {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 20px;
    margin-bottom: 20px;
}

.filtre-item {
    display: flex;
    align-items: center;
    gap: 10px;
}

/* Responsive mobile */
@media screen and (max-width: 768px) {
    .filtres-container {
        flex-direction: column;
        align-items: flex-start;
    }

    .filtre-item {
        flex-direction: column;
        align-items: flex-start;
        width: 100%;
    }

    .filtre-item label {
        margin-bottom: 5px;
    }

    .filtre-item select {
        width: 100%;
        max-width: 100%;
    }
}
