/* ############## SOCIAL SHARE - VERSION AMÉLIORÉE ############## */
:root {
	--primaire: #3da383;
    --secondaire: #000;
}

/* POPUP */
.share-popup {
    width: 90%;
    max-width: 800px;
	display: none;
	position: fixed;
	background-color: #fff;
	box-shadow: 0 10px 40px rgba(61, 163, 131, 0.3);
	left: 50%;
    top: 50%;
    transform: translate(-50%, -50%) scale(0.8);
    z-index: 9999995;
    border-radius: 4px;
    padding: 20px;
	opacity: 0;
	transition: all 0.3s cubic-bezier(0.68, -0.55, 0.265, 1.55);
}

.share-popup.showpop {
    display: block;
	opacity: 1;
    transform: translate(-50%, -50%) scale(1);
}

.share-popup h3 {
    padding: 15px 0;
    margin: 0;
    color: var(--primaire);
}

/* Bouton de fermeture */
.share-popup .close-popup {
    position: absolute;
    top: 10px;
    right: 10px;
    z-index: 9999999;
}

.share-popup .close-popup button {
    background-color: transparent !important;
    border: 0 !important;
    cursor: pointer;
    width: 40px;
    height: 40px;
}

.share-popup .close-popup button:before {
    display: block;
    font-family: 'dashicons';
    content: "\f335";
    font-size: 35px;
    color: var(--secondaire);
}

/* OVERLAY */
.overlay-popup { 
    display: none;
    position: fixed;
    width: 100vw !important;
    height: 100vh !important;
    top: 0;
    right: 0;
    bottom: 0;
    left: 0;
    background-color: rgba(61, 163, 131, 0.85);
    backdrop-filter: blur(3px);
    z-index: 9999990;
    opacity: 0;
    transition: opacity 0.3s ease;
}

.overlay-popup.showpop {
    display: block;
	opacity: 1;
}

/* Widget de partage */
#inline .share-wdgt {
    position: relative;
    width: 100%;
    max-width: 600px;
    left: 50%;
    top: 50%;
    opacity: 1;
	visibility: visible;
	z-index: 999999999999;
    transform: translate(-50%, -50%);
    transition: all 0.4s cubic-bezier(0.230, 1.000, 0.320, 1.000);
}

.share-wdgt a {
    text-transform: uppercase;
    color: var(--primaire);
	text-decoration: none;
    padding: 8px 16px;
}

.share-wdgt span {
    display: flex;
    color: var(--primaire);
    font-size: 12px;
    line-height: 35px;
    text-transform: uppercase;
    flex-direction: column;
    flex-wrap: nowrap;
    justify-content: center;
    align-items: center;
    font-family: sans-serif;
}

/* Boutons de partage */
.share-btns {
    display: flex;
    justify-content: center;
    flex-wrap: wrap;
    height: auto;
    margin: 0 6px;
    padding: 0;
    gap: 10px;
    list-style: none;
}

.share-btns li {
    display: inline-block;
    min-width: 130px;
    flex: 1 1 calc(50% - 20px);
    max-width: 200px;
    border-radius: 8px;
    border: 2px solid #eee;
    overflow: hidden;
}

.shr-btn {
    display: block;
    width: 100%;
    font-size: 1rem;
    text-align: center;
    line-height: 50px;
}

.share-btns li > * {
    border: 0;
    background-color: transparent;
}

#inline {
    padding: 30px !important;
}

/* Header */
.share-header h5 {
    text-transform: initial;
    font-size: 1.8rem;
    font-weight: 500;
    color: var(--primaire);
    margin: 0 0 20px 0;
    text-align: center;
}

/* Outils de partage */
#outils-partage > a, 
#outils-partage > p {
    color: #fff;
    position: relative;
    margin: 0 5px;
    display: inline-block;
}

#outils-partage > a img {
    height: 40px;
}

#outils-partage > *:not(:last-child):after {
    content: "";
    position: absolute;
    display: block;
    top: 0;
    right: -7px;
    width: 1px;
    height: 100%;
    background-color: rgba(255, 255, 255, 0.3);
}

/* MEDIA QUERIES */
@media screen and (max-width: 768px) {
    .share-popup {
        width: 95%;
        max-width: 500px;
        padding: 15px;
    }
    
    .share-btns {
        gap: 8px;
    }
    
    .share-btns li {
        min-width: 100px;
    }
    
    #inline {
        padding: 20px !important;
    }
}

@media screen and (max-width: 480px) {
    .share-popup {
        width: 95%;
        padding: 15px;
        border-radius: 8px;
    }
    
    .share-btns {
        display: flex;
        flex-direction: column;
        gap: 10px;
    }
    
    .share-btns li {
        min-width: 100%;
        max-width: 100%;
        flex: 1 1 100%;
    }
    
    #inline {
        padding: 10px !important;
    }
    
    .share-header h5 {
        font-size: 1.4rem;
        line-height: 1.3;
    }
    
    .share-popup .close-popup button:before {
        font-size: 30px;
    }
}

/* Animation au chargement */
@keyframes slideInUp {
    from {
        transform: translate(-50%, 100%);
        opacity: 0;
    }
    to {
        transform: translate(-50%, -50%);
        opacity: 1;
    }
}

/* Accessibilité */
.share-popup:focus-within {
    outline: 2px solid var(--primaire);
    outline-offset: 2px;
}

.share-btns li button:focus,
.share-popup .close-popup button:focus {
    outline: 2px solid var(--secondaire);
    outline-offset: 2px;
}