/* Success Animation Styles */
.success-modal {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.8);
    z-index: 9999;
    align-items: center;
    justify-content: center;
    opacity: 0;
    transition: opacity 0.3s ease-in-out;
}

.success-modal.active {
    display: flex;
    opacity: 1;
}

.success-content {
    background: white;
    padding: 40px;
    border-radius: 20px;
    text-align: center;
    transform: scale(0.7);
    transition: transform 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    max-width: 90%;
    width: 400px;
}

.success-modal.active .success-content {
    transform: scale(1);
}

/* Checkmark Animation */
.checkmark-circle {
    width: 80px;
    height: 80px;
    position: relative;
    display: inline-block;
    vertical-align: top;
    margin-bottom: 20px;
}

.checkmark-circle .background {
    width: 80px;
    height: 80px;
    border-radius: 50%;
    background: #22c55e;
    position: absolute;
}

.checkmark-circle .checkmark {
    border-radius: 5px;
}

.checkmark-circle .checkmark.draw:after {
    animation-delay: 300ms;
    animation-duration: 1s;
    animation-timing-function: ease;
    animation-name: checkmark;
    transform: scaleX(-1) rotate(135deg);
    animation-fill-mode: forwards;
}

.checkmark-circle .checkmark:after {
    opacity: 1;
    height: 40px;
    width: 20px;
    transform-origin: left top;
    border-right: 4px solid white;
    border-top: 4px solid white;
    content: '';
    left: 20px;
    top: 40px;
    position: absolute;
}

@keyframes checkmark {
    0% {
        height: 0;
        width: 0;
        opacity: 1;
    }
    20% {
        height: 0;
        width: 20px;
        opacity: 1;
    }
    40% {
        height: 40px;
        width: 20px;
        opacity: 1;
    }
    100% {
        height: 40px;
        width: 20px;
        opacity: 1;
        transform: scaleX(-1) rotate(135deg);
    }
}

/* Plane Animation for Sending */
.sending-animation {
    width: 100px;
    height: 100px;
    margin: 0 auto 20px;
    position: relative;
}

.plane {
    width: 100%;
    height: 100%;
    fill: #3b82f6;
    animation: fly 2s infinite ease-in-out;
}

@keyframes fly {
    0% {
        transform: translateY(0) translateX(0) rotate(0);
    }
    25% {
        transform: translateY(-10px) translateX(10px) rotate(-5deg);
    }
    50% {
        transform: translateY(0) translateX(20px) rotate(0);
    }
    75% {
        transform: translateY(10px) translateX(10px) rotate(5deg);
    }
    100% {
        transform: translateY(0) translateX(0) rotate(0);
    }
}
