/* 1. BASE - Styles par défaut (plus faible priorité) */
.voir-plus-button-container {
    position: relative;
    height: fit-content;
    width: fit-content;
    max-width: 175px;
    margin-top: 30px;
}

.voir-plus-button {
    display: flex;
    padding: 12px 19px;
    gap: 5px;
    align-items: center;
    cursor: pointer;
    text-transform: uppercase;
    font-size: var(--font-size-25);
    position: relative;
    z-index: 2;
}

.voir-plus-button p {
    margin: 0;
    color: var(--black);
    word-wrap: break-word;
    width: min-content;
    min-width: 100px;
    display: inline-block;
    font-size: 17px;
    white-space: normal;
}

.icon {
    width: 12px;
}

/* 2. FOND PAR DÉFAUT */
.voir-plus-button-container::before {
    content: "";
    position: absolute;
    top: 0;
    left: 0;
    width: 85px;
    height: 100%;
    background-color: var(--yellow);
    transition: width 0.3s ease;
}

.voir-plus-button-container:hover::before {
    width: 100%;
}

/* 3. CLASSE .on-two-lines - Première modification */
.voir-plus-button-container.on-two-lines p {
    margin-bottom: 25px;
}

.voir-plus-button-container.on-two-lines .icon {
    position: absolute;
    width: 13px;
    left: 100px;
    bottom: 16px;
    /* Position par défaut pour two-lines */
}

/* 4. CLASSE .previous - Modifications plus spécifiques (priorité haute) */
.voir-plus-button-container.previous .voir-plus-button {
    flex-direction: row-reverse;
    /* Inverse l'ordre des éléments flex */
}

.voir-plus-button-container.previous::before {
    content: none;
    /* Annule le fond gauche */
}

.voir-plus-button-container.previous::after {
    content: "";
    position: absolute;
    top: 0;
    right: 0;
    width: 85px;
    height: 100%;
    background-color: var(--yellow);
    transition: width 0.3s ease;
}

.voir-plus-button-container.previous:hover::after {
    width: 100%;
}

.voir-plus-button-container.previous .icon {
    transform: rotate(180deg);
}

/* Si .previous est seul (sans .on-two-lines) */
.voir-plus-button-container.previous:not(.on-two-lines) .icon {
    width: 12px;
    margin: 0;
}

.voir-plus-button-container.previous:not(.on-two-lines) p {
    margin-bottom: 0;
}

/* Si .previous ET .on-two-lines ensemble - PRIORITÉ MAXIMALE */
.voir-plus-button-container.previous.on-two-lines .icon {
    left: auto;
    right: 100px;
    /* Override la position 100px de .on-two-lines */
}