.share-container {
    position: relative;
    display: inline-block;
}

.share-buttons {
    display: none;
    position: absolute;
    /* Center the menu horizontally */
    top: 120%;
    left: 50%;
    transform: translateX(-50%);
    
    background-color: #fff;
    border-radius: 8px; /* Rounded corners */
    padding: 12px 15px;
    box-shadow: 0 4px 15px rgba(0,0,0,0.15); /* Soft depth shadow */
    z-index: 100;
    
    /* Animation setup */
    opacity: 0;
    transition: opacity 0.3s ease, transform 0.3s ease;
}

.share-container:hover .share-buttons {
    display: flex;
    opacity: 1;
    gap: 15px;
    /* Adjust transform to include the center and a slight lift */
    transform: translateX(-50%) translateY(0);
}

/* Optional: Add a small triangle pointing up */
.share-buttons::before {
    content: "";
    position: absolute;
    bottom: 100%;
    left: 50%;
    transform: translateX(-50%);
    border-width: 8px;
    border-style: solid;
    border-color: transparent transparent #fff transparent;
}

.share-buttons a {
    display: flex;
    align-items: center;
    color: #555; /* Neutral color */
    transition: transform 0.2s ease, color 0.2s ease;
}

/* Brand-specific colors on hover */
.share-buttons a:hover {
    transform: scale(1.2); /* Slight pop effect */
}

.share-buttons .fa-facebook:hover  { color: #1877F2; }
.share-buttons .fa-twitter:hover   { color: #1DA1F2; }
.share-buttons .fa-whatsapp:hover  { color: #25D366; }
.share-buttons .fa-telegram:hover  { color: #0088cc; }
.share-buttons .fa-envelope:hover  { color: #D44638; }
.share-buttons .fa-vk:hover        { color: #4C75A3; }

.share-buttons i {
    font-size: 24px; /* Slightly more balanced size */
}
/* Add this to your existing .share-buttons */
.share-buttons::before {
    content: '';
    position: absolute;
    top: -20px; /* Extends the hover area UP towards the button */
    left: 0;
    right: 0;
    height: 20px;
    background: transparent; /* Invisible but hoverable */
}


/* Ensure the container is the reference point */
.share-container {
    position: relative;
    display: inline-block;
}

.share-buttons {
    display: none; /* Changed to flex on hover */
    position: absolute;
    top: 100%; /* Sits exactly at the bottom edge of the button */
    left: 50%;
    transform: translateX(-50%);
    
    /* This creates the visual gap without losing the hover state */
    margin-top: 10px; 
    
    background-color: #fff;
    border-radius: 8px;
    padding: 12px 15px;
    box-shadow: 0 4px 15px rgba(0,0,0,0.15);
    z-index: 100;
    gap: 15px;
}

/* THE BRIDGE: This fills the 10px margin-top gap */
.share-buttons::before {
    content: '';
    position: absolute;
    top: -12px; /* Pulls it up to overlap the button slightly */
/*     left: 0; */
	left: 120px;
    right: 0;
    height: 15px; /* Enough to cover the 10px margin gap */
    background: transparent;
    border: none; /* Force remove any inherited borders */
    display: block;
    z-index: 1; /* Keep it below the icons if necessary */
}

/* Ensure icons stay clickable above the bridge */
.share-buttons a {
    position: relative;
    z-index: 2; 
    display: flex;
    align-items: center;
    transition: transform 0.2s ease;
}

.share-container:hover .share-buttons {
    display: flex;
}