.floating-contact {
    position: fixed;
    bottom: 24px;
    right: 24px;
    z-index: 9999;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 16px;
}

.floating-toggle {
    width: 50px;
    height: 50px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    position: relative;
    z-index: 1002;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.2);
}

.floating-toggle img {
    max-width: 100%;
}

.floating-toggle:hover {
    transform: scale(1.1);
}

.floating-toggle.active {
    background: #FC0;
    transform: rotate(45deg);
}

.floating-menu {
    display: flex;
    flex-direction: column;
    gap: 16px;
    opacity: 0;
    visibility: hidden;
    transform: translateY(20px);
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    pointer-events: none;
}

.floating-contact.active .floating-menu {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
    pointer-events: auto;
}

.floating-item {
    width: 50px;
    height: 50px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    text-decoration: none;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    position: relative;
    overflow: hidden;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
}

.floating-item:hover {
    transform: scale(1.15);
    box-shadow: 0 6px 16px rgba(0, 0, 0, 0.2);
}

.floating-item::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.3), transparent);
    transition: left 0.6s;
}

.floating-item:hover::before {
    left: 100%;
}

.floating-item img {
    width: 100%;
    height: 100%;
    display: block;
    object-fit: cover;
}

/* 置頂按鈕 */
.floating-scroll-top-container {
    width: 50px;
    height: 50px;
    border-radius: 50%;
    background: #FFDC37;
    backdrop-filter: blur(4px);
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: all 0.6s cubic-bezier(0.4, 0, 0.2, 1);
    position: relative;
    z-index: 1001;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
    opacity: 0;
    transform: translateX(100px);
    pointer-events: none;
    border: none;
    padding: 0;
    background-clip: padding-box;
}

.floating-scroll-top-container.show {
    opacity: 1;
    transform: translateX(0);
    pointer-events: auto;
}

.floating-scroll-top-container:hover {
    background: #ffde37b0;
    box-shadow: 0 6px 16px rgba(0, 0, 0, 0.15);
}

.floating-scroll-top-icon {
    width: 24px;
    height: 24px;
    color: black;
    transition: transform 0.2s ease;
    flex-shrink: 0;
    display: block;
    margin: 0;
    padding: 0;
    line-height: 1;
    transform: translateY(-3px);
}

.floating-scroll-top-container:hover .floating-scroll-top-icon {
    transform: translateY(-3px);
}

/* 響應式 */
@media (max-width: 900px) {
    .floating-contact {
        bottom: 16px;
        right: 16px;
        gap: 12px;
    }

    .floating-toggle {
        width: 38px;
        height: 38px;
    }

    .floating-item {
        width: 34px;
        height: 34px;
    }

    .floating-menu {
        gap: 8px;
    }
}

@media (max-width: 600px) {
    .floating-contact {
        bottom: 12px;
        right: 12px;
        gap: 10px;
    }

    .floating-toggle {
        width: 38px;
        height: 38px;
    }

    .floating-item {
        width: 34px;
        height: 34px;
    }

    .floating-menu {
        gap: 6px;
    }

    .floating-scroll-top-container {
        width: 40px;
        height: 40px;
    }
}
