/**
 * HD Contact Buttons Stylesheet
 * Hỗ trợ hiển thị thanh liên hệ nổi dọc trên Desktop và thanh công cụ cố định đáy trên Mobile
 */

/* ==========================================================================
   1. DESKTOP STYLES
   ========================================================================== */
.giuseart-nav {
    position: fixed;
    right: 13px;
    background: #ffffff;
    border-radius: 8px;
    width: auto;
    z-index: 9999;
    bottom: 60px;
    padding: 8px 0;
    border: 1px solid #f0f0f0;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.08);
    transition: all 0.3s ease;
}

.giuseart-nav.nav-position-left {
    right: auto;
    left: 13px;
}

.giuseart-nav ul {
    list-style: none !important;
    padding: 0 !important;
    margin: 0 !important;
}

.giuseart-nav ul li {
    list-style: none !important;
    margin: 4px 0 !important;
    padding: 0 !important;
}

.giuseart-nav ul > li a {
    border: none;
    padding: 5px 4px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    border-radius: 6px;
    text-align: center;
    font-size: 11.5px;
    line-height: 14px;
    color: #e00000;
    font-weight: 700;
    width: 68px;
    text-decoration: none !important;
    transition: transform 0.2s ease, color 0.2s ease;
}

.giuseart-nav ul > li a:hover {
    transform: translateY(-2px);
    color: #b00000;
}

.giuseart-nav ul > li a i {
    width: 34px;
    height: 34px;
    display: block;
    margin: 0 auto 3px;
    background-size: contain !important;
    background-repeat: no-repeat !important;
    background-position: center !important;
}

/* Icons */
.giuseart-nav ul > li a i.ticon-heart {
    background-image: url('../images/icon-map.png');
}

.giuseart-nav ul > li a i.ticon-messenger {
    background-image: url('../images/icon-messenger.png');
}

.giuseart-nav ul > li a i.icon-phone-w {
    background-image: url('../images/icon-phone.png');
}

.giuseart-nav ul > li a i.ticon-zalo-circle2 {
    background-image: url('../images/icon-zalo.png');
}

.giuseart-nav ul > li a i.ticon-angle-up {
    background-image: url('../images/icon-totop.png');
}

.giuseart-nav .phone-mobile .phone_animation {
    display: block;
}

.giuseart-nav .phone-mobile .btn_phone_txt {
    display: block;
    font-size: 10px;
    font-weight: bold;
    color: #e00000;
    white-space: nowrap;
}

/* ==========================================================================
   2. MOBILE STYLES (max-width: 768px)
   ========================================================================== */
@media only screen and (max-width: 768px) {
    .giuseart-nav {
        background: #ffffff;
        width: 100% !important;
        border-radius: 0 !important;
        height: 60px !important;
        position: fixed !important;
        bottom: 0 !important;
        left: 0 !important;
        right: 0 !important;
        z-index: 99999 !important;
        padding: 4px 0 0 !important;
        margin: 0 !important;
        border: none !important;
        border-top: 1px solid #eef0f3 !important;
        box-shadow: 0 -3px 12px rgba(0, 0, 0, 0.08) !important;
    }

    .giuseart-nav ul {
        display: flex !important;
        align-items: center !important;
        justify-content: space-around !important;
        height: 100% !important;
    }

    .giuseart-nav li {
        flex: 1 1 20% !important;
        max-width: 20% !important;
        height: 52px !important;
        text-align: center !important;
        position: relative !important;
        margin: 0 !important;
    }

    .giuseart-nav ul > li a {
        padding: 2px 0 !important;
        margin: 0 auto !important;
        width: 100% !important;
        max-width: 100% !important;
        height: 100% !important;
        font-size: 10.5px !important;
        line-height: 12px !important;
    }

    .giuseart-nav ul > li a i {
        width: 26px !important;
        height: 26px !important;
        margin-bottom: 2px !important;
    }

    /* Nút điện thoại ở giữa nổi bật (Floating Center Button) */
    .giuseart-nav li.phone-mobile {
        position: relative !important;
    }

    .giuseart-nav li.phone-mobile .phone_animation {
        position: absolute !important;
        top: -18px !important;
        left: 50% !important;
        transform: translateX(-50%) !important;
        width: 50px !important;
        height: 50px !important;
        border-radius: 50% !important;
        background: #e00000 !important;
        display: flex !important;
        align-items: center !important;
        justify-content: center !important;
        box-shadow: 0 4px 15px rgba(224, 0, 0, 0.38) !important;
        border: 3px solid #ffffff !important;
        animation: hd-phone-pulse 2s infinite ease-in-out !important;
    }

    .giuseart-nav li.phone-mobile .phone_animation i.icon-phone-w {
        width: 26px !important;
        height: 26px !important;
        margin: 0 !important;
        filter: brightness(0) invert(1) !important; /* Làm icon màu trắng nổi trên nền đỏ */
    }

    .giuseart-nav li.phone-mobile .btn_phone_txt {
        position: absolute !important;
        bottom: 2px !important;
        left: 0 !important;
        right: 0 !important;
        font-size: 9.5px !important;
        font-weight: 700 !important;
        color: #e00000 !important;
        text-align: center !important;
    }

    /* Đẩy lề chân trang để nội dung không bị thanh mobile che khuất */
    body {
        padding-bottom: 60px !important;
    }
}

/* ==========================================================================
   3. ANIMATION
   ========================================================================== */
@keyframes hd-phone-pulse {
    0% {
        transform: translateX(-50%) scale(1);
        box-shadow: 0 0 0 0 rgba(224, 0, 0, 0.6);
    }
    70% {
        transform: translateX(-50%) scale(1.06);
        box-shadow: 0 0 0 10px rgba(224, 0, 0, 0);
    }
    100% {
        transform: translateX(-50%) scale(1);
        box-shadow: 0 0 0 0 rgba(224, 0, 0, 0);
    }
}
