/* Real-time WebSocket Styles */

/* Toast notifications */
.toast-container {
    z-index: 9999;
}

/* Rate update animation */
.rate-updated {
    animation: pulse 2s ease-in-out;
    background-color: rgba(13, 202, 240, 0.2);
    transition: background-color 0.3s ease;
}

@keyframes pulse {
    0% {
        background-color: rgba(13, 202, 240, 0.2);
        transform: scale(1);
    }
    50% {
        background-color: rgba(13, 202, 240, 0.4);
        transform: scale(1.02);
    }
    100% {
        background-color: rgba(13, 202, 240, 0.2);
        transform: scale(1);
    }
}

/* Transfer status update animation */
.transfer-status {
    transition: all 0.3s ease;
}

.transfer-status.updating {
    animation: statusPulse 0.5s ease-in-out;
}

@keyframes statusPulse {
    0%, 100% {
        opacity: 1;
    }
    50% {
        opacity: 0.5;
    }
}

/* WebSocket connection indicator */
.ws-connection-status {
    position: fixed;
    bottom: 20px;
    right: 20px;
    padding: 8px 16px;
    border-radius: 20px;
    font-size: 12px;
    font-weight: 500;
    display: flex;
    align-items: center;
    gap: 8px;
    transition: all 0.3s ease;
    z-index: 1000;
}

.ws-connection-status.connected {
    background-color: rgba(25, 135, 84, 0.9);
    color: white;
}

.ws-connection-status.disconnected {
    background-color: rgba(220, 53, 69, 0.9);
    color: white;
}

.ws-connection-status.connecting {
    background-color: rgba(255, 193, 7, 0.9);
    color: #212529;
}

.ws-connection-status .status-dot {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background-color: currentColor;
    animation: blink 2s infinite;
}

@keyframes blink {
    0%, 100% {
        opacity: 1;
    }
    50% {
        opacity: 0.3;
    }
}

/* Notification badge animation */
.notification-badge {
    animation: badgePop 0.3s ease-out;
}

@keyframes badgePop {
    0% {
        transform: scale(0);
    }
    50% {
        transform: scale(1.2);
    }
    100% {
        transform: scale(1);
    }
}

/* Real-time data indicator */
.realtime-indicator {
    display: inline-block;
    width: 8px;
    height: 8px;
    background-color: #28a745;
    border-radius: 50%;
    margin-left: 5px;
    animation: pulse-dot 2s infinite;
}

@keyframes pulse-dot {
    0% {
        box-shadow: 0 0 0 0 rgba(40, 167, 69, 0.7);
    }
    70% {
        box-shadow: 0 0 0 10px rgba(40, 167, 69, 0);
    }
    100% {
        box-shadow: 0 0 0 0 rgba(40, 167, 69, 0);
    }
}

/* Live update row highlight */
.live-update {
    background-color: rgba(13, 202, 240, 0.1);
    transition: background-color 1s ease-out;
}

/* Mobile responsive styles */
@media (max-width: 576px) {
    .ws-connection-status {
        bottom: 10px;
        right: 10px;
        padding: 6px 12px;
        font-size: 11px;
    }
    
    .toast-container {
        top: 60px !important;
    }
}