﻿/* =========================
    Footer
========================= */


.footer {
    padding: 100px 8%;
    background: #0f172a;
    color: white;
    text-align: center;
}

.footer-logo {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    text-align: center;
}

    .footer-logo img {
        width: 90px;
        margin-bottom: 20px;
    }

    .footer-logo h2 {
        font-size: 32px;
        letter-spacing: 4px;
    }

.footer-text {
    margin: 25px 0;
    color: rgba(255,255,255,0.7);
}

.social-links {
    display: flex;
    justify-content: center;
    gap: 22px;
    margin-top: 30px;
}

    .social-links a {
        width: 58px;
        height: 58px;
        display: flex;
        align-items: center;
        justify-content: center;
        border-radius: 16px;
        background: rgba(255,255,255,0.06);
        transition: 0.3s;
    }

        .social-links a:hover {
            transform: translateY(-6px);
            background: rgba(255,255,255,0.14);
        }

    .social-links img {
        width: 28px;
    }



/* =========================
    SOCIAL TOOLTIP
========================= */

.social-icon {
    position: relative;
}

    /* متن tooltip */
    .social-icon::after {
        content: attr(data-tooltip);
        position: absolute;
        bottom: 75%;
        left: 50%;
        transform: translateX(-50%) translateY(10px);
        background: rgba(0,0,0,0.75);
        color: white;
        padding: 6px 10px;
        border-radius: 8px;
        font-size: 12px;
        white-space: nowrap;
        opacity: 0;
        visibility: hidden;
        transition: all 0.25s ease;
        backdrop-filter: blur(8px);
    }

    /* فلش tooltip */
    .social-icon::before {
        content: "";
        position: absolute;
        bottom: 68%;
        left: 50%;
        transform: translateX(-50%) rotate(45deg);
        width: 8px;
        height: 8px;
        background: rgba(0,0,0,0.75);
        opacity: 0;
        visibility: hidden;
        transition: all 0.25s ease;
    }

    /* hover state */
    .social-icon:hover::after {
        opacity: 1;
        visibility: visible;
        transform: translateX(-50%) translateY(0);
    }

    .social-icon:hover::before {
        opacity: 1;
        visibility: visible;
    }


/* =========================
    Mobile Responsive (add to end of file)
========================= */

@media (max-width: 768px) {
    .footer {
        padding: 60px 5%;
    }

    .footer-logo img {
        width: 70px;
        margin-bottom: 15px;
    }

    .footer-logo h2 {
        font-size: 24px;
        letter-spacing: 3px;
    }

    .footer-text {
        margin: 20px 0;
        font-size: 14px;
        padding: 0 10px;
    }

    .social-links {
        gap: 15px;
        margin-top: 25px;
    }

        .social-links a {
            width: 48px;
            height: 48px;
            border-radius: 12px;
        }

        .social-links img {
            width: 22px;
        }

    /* fix tooltip position for mobile */
    .social-icon::after {
        bottom: 85%;
        font-size: 10px;
        white-space: nowrap;
    }

    .social-icon::before {
        bottom: 79%;
    }
}

/* small mobile */
@media (max-width: 480px) {
    .footer {
        padding: 50px 4%;
    }

    .footer-logo img {
        width: 60px;
    }

    .footer-logo h2 {
        font-size: 20px;
        letter-spacing: 2px;
    }

    .footer-text {
        font-size: 12px;
        margin: 15px 0;
    }

    .social-links {
        gap: 12px;
        flex-wrap: wrap;
    }

        .social-links a {
            width: 44px;
            height: 44px;
        }

        .social-links img {
            width: 20px;
        }
}






/* =========================
    Mobile Tooltip - Click Effect
========================= */

@media (max-width: 768px) {
    /* نمایش tooltip با کلیک (active) */
    .social-icon:active::after,
    .social-icon:active::before {
        opacity: 1;
        visibility: visible;
    }

    .social-icon:active::after {
        transform: translateX(-50%) translateY(0);
    }

    /* انیمیشن محو شدن خودکار بعد از 2 ثانیه */
    @keyframes fadeOut {
        0% {
            opacity: 1;
            visibility: visible;
        }

        70% {
            opacity: 1;
            visibility: visible;
        }

        100% {
            opacity: 0;
            visibility: hidden;
        }
    }

    .social-icon:active::after {
        animation: fadeOut 2s ease forwards;
    }

    .social-icon:active::before {
        animation: fadeOut 2s ease forwards;
    }

    /* هاور را در موبایل غیرفعال کنید */
    .social-links a:hover {
        transform: none;
        background: rgba(255,255,255,0.06);
    }
}