.containerteams {
    max-width: 1200px;
    margin: 0 auto;
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 20px;
}
.boxteams {
    background-color: #0000000e;
    border-radius: 8px;
    box-shadow: 0 4px 8px rgb(0, 0, 0);
    overflow: hidden;
    text-align: center;
    transition: transform 0.3s;
}
.boxteams:hover {
    transform: scale(1.05);
}
.boxteams img {
    width: 300px;
    height: 300px;
    object-fit: contain;
    max-width: 100%;
    height: auto;
}
.boxteams h3 {
    font-size: 1.2em;
    margin: 10px 0;
}
.boxteams p {
    font-size: 0.9em;
    color: #666;
    padding: 0 10px 10px;
    height: 120px; /* Hauteur fixe, par exemple 150px */
    overflow: hidden; /* Cache le texte qui dépasse la hauteur définie */
    text-overflow: ellipsis; /* Ajoute des points de suspension si le texte est trop long */
}
.personal-teams-header-image {
    position: absolute;
    top: 20px;
    left: 20px;
    z-index: 1;
}
.personal-teams-header-image img {
    width: 128px;
    height: 128px;
    border-radius: 50%;
    border: 5px solid #fff;
}
.personal-teams-container {
    flex: 1;
    display: flex;
    flex-direction: column;
    margin-top: 20px;
}
.personal-teams-character h1 {
    font-size: 3em;
    margin-bottom: 20px;
}
.personal-teams-rules {
    background-color: var(--sidebar-color);
    padding: 40px;
    border-radius: 15px;
    width: 100%;
    display: flex;
    justify-content: space-between;
}
.personal-teams-rule {
    font-weight: bold;
    margin-bottom: 15px;
    font-size: 1.2em;
    color: #f7f6f3;
}
.personal-teams-rules-text {
    max-width: 60%;
}
.personal-teams-icons {
    display: flex;
    justify-content: center;
    gap: 15px;
    margin-top: 20px;
    flex-wrap: wrap;
    max-width: 100%;
}
.personal-teams-icons a {
    text-decoration: none;
    font-size: 3em;
    background-color: #fff;
    width: 80px;
    height: 80px;
    border-radius: 5px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: inherit;
}
.containerteamssmall {
    max-width: 1200px;
    margin: 0 auto;
    display: grid;
    grid-template-columns: repeat(5, 1fr);
    gap: 20px;
}
.containerteamssmall .boxteams img {
    width: 200px;
    height: 200px;
    object-fit: contain;
    max-width: 100%;
    height: auto;
}

/* Media Queries pour le responsive */
@media (max-width: 768px) {
    /* Pour .containerteams : une seule colonne sur mobile */
    .containerteams {
        grid-template-columns: 1fr;
        padding: 10px;
    }
    /* Images dans .boxteams : s'adaptent au conteneur */
    .boxteams img {
        width: 100%;
        height: auto;
    }
    /* Ajustement de la taille des titres */
    .boxteams h3 {
        font-size: 1.4em;
    }
    /* Pour .containerteamssmall : 2 colonnes sur mobile */
    .containerteamssmall {
        grid-template-columns: repeat(2, 1fr);
        gap: 10px;
        padding: 10px;
    }
    /* Images dans .containerteamssmall */
    .containerteamssmall .boxteams img {
        width: 100%;
        height: auto;
    }
}

/* Ajustements pour la version desktop lorsque l'écran est redimensionné */
@media (max-width: 1200px) {
    .boxteams img,
    .containerteamssmall .boxteams img {
        max-width: 100%;
        height: auto;
    }
}