/**
 * Button Deco layout – grille, titres centrés, introduction petite
 */

/* Conteneur principal : grille responsive */
ul.button_deco.grid-4-small-2 {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 15px;
    padding-left: 0;
    list-style: none;
    margin: 0;
}

/* Chaque élément */
ul.button_deco.grid-4-small-2 li {
    display: flex;
    margin: 0;
    padding: 0;
}

/* Le lien : bloc cliquable */
ul.button_deco.grid-4-small-2 li a {
    display: flex;
    flex-direction: column;     /* Pour empiler icône et contenu verticalement */
    align-items: center;
    justify-content: center;
    width: 100%;
    padding: 15px 10px;
    background-color: #e9f7f7;
    border: 1px solid #01b3a7;
    border-radius: 8px;
    text-decoration: none;
    color: #01b3a7;
    box-sizing: border-box;
    min-height: 120px;
    height: 100%;
    transition: background 0.2s;
    text-align: center;
}

/* Survol */
ul.button_deco.grid-4-small-2 li a:hover {
    background-color: #d0ecec;
}

/* Icône */
ul.button_deco.grid-4-small-2 li a .icon {
    margin-bottom: 8px;
    font-size: 1.5em;
}

/* Conteneur du texte */
.button-content {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    width: 100%;
}

/* Titre : gros, centré, gras */
.button-title {
    font-size: 1.3em;
    font-weight: bold;
    line-height: 1.3;
    margin-bottom: 6px;
    color: #01b3a7;
}

/* Introduction : plus petite, centrée */
.button-intro {
    font-size: 0.85em;
    line-height: 1.4;
    opacity: 0.8;
    color: #555;
}

/* Responsive : tablette -> 2 colonnes */
@media (max-width: 768px) {
    ul.button_deco.grid-4-small-2 {
        grid-template-columns: repeat(2, 1fr);
    }
}

/* Responsive : mobile -> 1 colonne */
@media (max-width: 480px) {
    ul.button_deco.grid-4-small-2 {
        grid-template-columns: 1fr;
    }
    
    ul.button_deco.grid-4-small-2 li a {
        flex-direction: row;    /* sur mobile, icône à gauche pour gagner de la place */
        justify-content: flex-start;
        text-align: left;
    }
    
    .button-content {
        align-items: flex-start;
    }
}

/* Annulation des styles globaux indésirables */
ul.button_deco.grid-4-small-2 li a,
ul.button_deco.grid-4-small-2 li a:hover,
ul.button_deco.grid-4-small-2 li a:focus {
    background-image: none;
    box-shadow: none;
    text-transform: none;
    white-space: normal;
    font-family: inherit;
}

/* Conservation des couleurs spécifiques si nécessaire (optionnel) */
.button1 { background-color: #bbeedb; }
.button2 { background-color: #bee4e7; }
.button3 { background-color: #b5d9f3; }
.button4 { background-color: #6dabd2; }
.button4 .button-title { color: #ffffff; }