/* ========================================
   BACK TO TOP BUTTON - BOTÓN VOLVER ARRIBA
   Sistema Tramperas
   ======================================== */

.back-to-top {
    position: fixed;
    bottom: 30px;
    right: 30px;
    width: 50px;
    height: 50px;
    background: linear-gradient(135deg, #5BCEFA 0%, #F5A9B8 100%);
    border: none;
    border-radius: 50%;
    color: white;
    font-size: 18px;
    cursor: pointer;
    box-shadow: 0 4px 15px rgba(91, 206, 250, 0.3);
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    opacity: 0;
    visibility: hidden;
    transform: translateY(20px);
    z-index: 1000;
    display: flex;
    align-items: center;
    justify-content: center;
}

.back-to-top.visible {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

.back-to-top:hover {
    transform: translateY(-3px);
    box-shadow: 0 8px 25px rgba(91, 206, 250, 0.4);
    background: linear-gradient(135deg, #4AB8E6 0%, #E89BB0 100%);
}

.back-to-top:active {
    transform: translateY(-1px);
    box-shadow: 0 4px 15px rgba(91, 206, 250, 0.3);
}

.back-to-top i {
    transition: transform 0.3s ease;
}

.back-to-top:hover i {
    transform: translateY(-2px);
}

/* Animación de pulso cuando aparece */
.back-to-top.visible::before {
    content: '';
    position: absolute;
    top: -5px;
    left: -5px;
    right: -5px;
    bottom: -5px;
    background: linear-gradient(135deg, #5BCEFA 0%, #F5A9B8 100%);
    border-radius: 50%;
    opacity: 0.3;
    animation: pulse 2s infinite;
    z-index: -1;
}

@keyframes pulse {
    0% {
        transform: scale(1);
        opacity: 0.3;
    }
    50% {
        transform: scale(1.1);
        opacity: 0.1;
    }
    100% {
        transform: scale(1);
        opacity: 0.3;
    }
}

/* Responsive */
@media (max-width: 768px) {
    .back-to-top {
        bottom: 20px;
        right: 20px;
        width: 45px;
        height: 45px;
        font-size: 16px;
    }
}

@media (max-width: 480px) {
    .back-to-top {
        bottom: 15px;
        right: 15px;
        width: 40px;
        height: 40px;
        font-size: 14px;
    }
}

/* Accesibilidad */
.back-to-top:focus {
    outline: 2px solid #5BCEFA;
    outline-offset: 2px;
}

/* Modo oscuro */
[data-theme="dark"] .back-to-top {
    background: linear-gradient(135deg, #4AB8E6 0%, #E89BB0 100%);
    box-shadow: 0 4px 15px rgba(74, 184, 230, 0.3);
}

[data-theme="dark"] .back-to-top:hover {
    background: linear-gradient(135deg, #3A9BC6 0%, #D88BA0 100%);
    box-shadow: 0 8px 25px rgba(74, 184, 230, 0.4);
}




