/* Back to Top Button */
.back-to-top {
    position: fixed;
    left: 30px;
    bottom: 30px;
    z-index: 9998;
    opacity: 0;
    visibility: hidden;
    transform: translateY(20px);
    transition: all 0.4s ease;
}

.back-to-top.visible {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

.back-to-top-btn {
    width: 56px;
    height: 56px;
    background: linear-gradient(135deg, #2c3e50, #4a6491);
    border: none;
    border-radius: 50%;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.15);
    cursor: pointer;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
    overflow: hidden;
}

.back-to-top-btn:hover {
    transform: translateY(-5px);
    box-shadow: 0 6px 25px rgba(0, 0, 0, 0.2);
    background: linear-gradient(135deg, #4a6491, #2c3e50);
}

.back-to-top-btn:active {
    transform: translateY(-2px);
}

.back-to-top-btn::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(255, 255, 255, 0.1);
    opacity: 0;
    transition: opacity 0.3s;
}

.back-to-top-btn:hover::before {
    opacity: 1;
}

.back-to-top-icon {
    width: 24px;
    height: 24px;
    fill: white;
    transition: transform 0.3s;
}

.back-to-top-btn:hover .back-to-top-icon {
    transform: translateY(-3px);
}

/* Pulse animation */
.back-to-top-btn::after {
    content: '';
    position: absolute;
    width: 100%;
    height: 100%;
    border-radius: 50%;
    background: rgba(74, 100, 145, 0.4);
    animation: pulse 2s infinite;
    z-index: -1;
}

@keyframes pulse {
    0% {
        transform: scale(1);
        opacity: 1;
    }
    70% {
        transform: scale(1.3);
        opacity: 0;
    }
    100% {
        opacity: 0;
    }
}

/* Responsive adjustments */
@media (max-width: 768px) {
    .back-to-top {
        left: 20px;
        bottom: 20px;
    }
    
    .back-to-top-btn {
        width: 48px;
        height: 48px;
    }
}