#social-media .social-card {
    position: fixed;
    top: 70%;
    left: 10px; /* or right: 20px; for right side */
    transform: translateY(-50%);
    max-width: fit-content;
    border-radius: 15px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 1rem;
    z-index: 1000; /* Ensures it's on top */
}

#social-media.hidden {
    display: none;
}

.social-card:hover {
    animation: ease-out 5s;
    background: rgba(173, 173, 173, 0.05);
}

.social-card ul {
    padding: 1rem;
    display: flex;
    list-style: none;
    gap: 1.5rem;
    align-items: center;
    justify-content: center;
    align-content: center;
    flex-wrap: wrap;
    flex-direction: column;
}

.social-item {
    cursor: pointer;
    position: relative;
    transition: 0.5s;
}

.social-icon {
    font-size: 25px;
    padding: 1rem;
    height: 60px;
    width: 60px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    border: 1px solid rgba(255, 255, 255, 0.1);
    color: #ddd;
    background: #037e49;
    box-shadow: inset 0 0 20px rgba(255, 255, 255, 0),
        inset 0 0 5px rgba(255, 255, 255, 0),
        0 5px 5px rgba(0, 0, 0, 0);
    transition: all 0.3s ease;
}

.social-text {
    opacity: 0;
    border-radius: 5px;
    padding: 5px;
    transition: all 0.3s;
    color: #764DF0;
    background-color: rgba(255, 255, 255, 0.3);
    position: absolute;
    z-index: 9999;
    box-shadow: -5px 0 1px rgba(153, 153, 153, 0.2),
        -10px 0 1px rgba(153, 153, 153, 0.2),
        inset 0 0 20px rgba(255, 255, 255, 0.3),
        inset 0 0 5px rgba(255, 255, 255, 0.5),
        0 5px 5px rgba(0, 0, 0, 0.082);
}

.social-item span {
    opacity: 0;
    position: absolute;
    border: 2px solid transparent;
    box-shadow: inset 0 0 20px rgba(255, 255, 255, 0.3),
        inset 0 0 5px rgba(255, 255, 255, 0.5),
        0 5px 5px rgba(0, 0, 0, 0.164);
    border-radius: 50%;
    transition: all 0.3s ease;
    height: 60px;
    width: 60px;
}

/* Hover Effects */
.social-item:hover .social-icon {
    /* transform: translate(20px, -15px); */
     transform: translate(5px, -3px);
    /* background: rgba(187, 17, 254, 0.2); */
}

/* .social-item:hover .social-text {
  opacity: 1;
  transform: translate(25px, -2px) skew(-5deg);
} */

/* .social-item:hover span {
    opacity: 1;
}

.social-item:hover span:nth-child(1) {
    opacity: 0.2;
}

.social-item:hover span:nth-child(2) {
    opacity: 0.4;
    transform: translate(5px, -5px);
}

.social-item:hover span:nth-child(3) {
    opacity: 0.6;
    transform: translate(10px, -10px);
} */

/* Medium devices (tablets, 768px and up) */
@media (max-width: 768px) {
    .social-card {
        max-width: 100%;
        border-radius: 12px;
        gap: 0.8rem;
    }

    .social-card ul {
        padding: 0.8rem;
        gap: 0.5rem;
    }

    .social-icon {
        font-size: 22px;
        height: 55px;
        width: 55px;
    }

    .social-item:hover .social-icon {
        transform: translate(0px, 0px);
    }

    .social-item:hover span {
        opacity: 0;
    }

    .social-item:hover span:nth-child(1) {
        opacity: 0;
    }

    .social-item:hover span:nth-child(2) {
        opacity: 0;
        transform: translate(5px, -5px);
    }

    .social-item:hover span:nth-child(3) {
        opacity: 0;
        transform: translate(10px, -10px);
    }

}

/* Small devices (landscape phones, 576px and up) */
@media (max-width: 576px) {
    .social-card {
        border-radius: 10px;
        gap: 0.6rem;
    }

    .social-card ul {
        padding: 0.6rem;
        flex-direction: column;
    }

    .social-icon {
        font-size: 20px;
        height: 50px;
        width: 50px;
        padding: 0.8rem;
    }

    .social-item:hover .social-icon {
        transform: translate(0px, 0px);
    }

    .social-text {
        display: none;
        /* Hide tooltips on very small screens */
    }

    .social-item span {
        height: 50px;
        width: 50px;
    }
}

/* Extra small devices (portrait phones, less than 576px) */
@media (max-width: 400px) {
    .social-card ul {
        flex-direction: column;
        flex-wrap: wrap;
        justify-content: space-around;
    }

    .social-icon {
        font-size: 18px;
        height: 45px;
        width: 45px;
        padding: 0.7rem;
    }

    .social-item span {
        height: 45px;
        width: 45px;
    }
}