/* ===================================
   CONTACT FORM SUCCESS MODAL & NOTIFICATIONS
   =================================== */

/* Success Modal */
.success-modal {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 10000;
    display: none;
    align-items: center;
    justify-content: center;
}

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

.success-modal-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.7);
    backdrop-filter: blur(8px);
    animation: fadeIn 0.3s ease;
}

.success-modal-content {
    position: relative;
    background: #ffffff;
    border-radius: 24px;
    padding: 3rem 2.5rem 2.5rem;
    max-width: 500px;
    width: 90%;
    text-align: center;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.3);
    transform: scale(0.7);
    opacity: 0;
    z-index: 1;
}

.success-modal-content.animate-in {
    animation: modalSlideIn 0.5s cubic-bezier(0.68, -0.55, 0.265, 1.55) forwards;
}

.success-modal-content.animate-out {
    animation: modalSlideOut 0.3s ease forwards;
}

/* Success Animation */
.success-animation {
    margin-bottom: 1.5rem;
}

.success-checkmark {
    width: 100px;
    height: 100px;
    margin: 0 auto;
}

.checkmark {
    width: 100px;
    height: 100px;
    border-radius: 50%;
    display: block;
    stroke-width: 2;
    stroke: #4BB543;
    stroke-miterlimit: 10;
    box-shadow: inset 0 0 0 #4BB543;
    animation: fillGreen 0.4s ease-in-out 0.4s forwards, scale 0.3s ease-in-out 0.9s both;
}

.checkmark-circle {
    stroke-dasharray: 166;
    stroke-dashoffset: 166;
    stroke-width: 2;
    stroke-miterlimit: 10;
    stroke: #4BB543;
    fill: none;
    animation: stroke 0.6s cubic-bezier(0.65, 0, 0.45, 1) forwards;
}

.checkmark-check {
    transform-origin: 50% 50%;
    stroke-dasharray: 48;
    stroke-dashoffset: 48;
    stroke: #fff;
    stroke-width: 3;
    animation: stroke 0.3s cubic-bezier(0.65, 0, 0.45, 1) 0.8s forwards;
}

/* Success Text */
.success-title {
    font-size: 2rem;
    font-weight: 700;
    color: #133162;
    margin-bottom: 0.5rem;
    animation: slideUp 0.5s ease 0.6s both;
}

.success-message {
    font-size: 1.1rem;
    color: #333;
    margin-bottom: 0.5rem;
    animation: slideUp 0.5s ease 0.7s both;
}

.success-submessage {
    font-size: 0.95rem;
    color: #666;
    margin-bottom: 1.5rem;
    animation: slideUp 0.5s ease 0.8s both;
}

.success-details {
    background: linear-gradient(135deg, #f0f9ff 0%, #e0f2fe 100%);
    padding: 1.25rem;
    border-radius: 12px;
    margin-bottom: 2rem;
    animation: slideUp 0.5s ease 0.9s both;
}

.success-icon {
    font-size: 2rem;
    margin-bottom: 0.5rem;
}

.success-email {
    font-size: 0.9rem;
    color: #0369a1;
    font-weight: 500;
    margin: 0;
}

/* Close Button */
.btn-close-success {
    background: linear-gradient(135deg, #3498db 0%, #2ecc71 100%);
    color: #ffffff;
    border: none;
    border-radius: 12px;
    padding: 1rem 2rem;
    font-size: 1rem;
    font-weight: 600;
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    transition: all 0.3s ease;
    animation: slideUp 0.5s ease 1s both;
    box-shadow: 0 4px 15px rgba(52, 152, 219, 0.3);
}

.btn-close-success:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(52, 152, 219, 0.4);
}

.btn-close-success .btn-arrow {
    transition: transform 0.3s ease;
}

.btn-close-success:hover .btn-arrow {
    transform: translateX(5px);
}

/* Error Notification (Toast) */
.error-notification {
    position: fixed;
    top: 20px;
    right: -400px;
    max-width: 400px;
    width: 90%;
    background: #ffffff;
    border-radius: 12px;
    padding: 1rem 1.5rem;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.2);
    display: flex;
    align-items: flex-start;
    gap: 1rem;
    z-index: 10001;
    border-left: 4px solid #ef4444;
    transition: right 0.3s cubic-bezier(0.68, -0.55, 0.265, 1.55);
}

.error-notification.show {
    right: 20px;
}

.error-icon {
    font-size: 1.5rem;
    flex-shrink: 0;
}

.error-content {
    flex: 1;
}

.error-title {
    font-size: 1rem;
    font-weight: 700;
    color: #ef4444;
    margin: 0 0 0.25rem 0;
}

.error-message {
    font-size: 0.9rem;
    color: #666;
    margin: 0;
    line-height: 1.4;
}

.error-close {
    background: none;
    border: none;
    font-size: 1.2rem;
    color: #999;
    cursor: pointer;
    padding: 0;
    width: 24px;
    height: 24px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 4px;
    transition: all 0.2s ease;
    flex-shrink: 0;
}

.error-close:hover {
    background: #f3f4f6;
    color: #333;
}

/* Button Loading & Success States */
.btn-submit.loading {
    position: relative;
    pointer-events: none;
}

.btn-submit.loading::after {
    content: '';
    position: absolute;
    width: 16px;
    height: 16px;
    top: 50%;
    left: 50%;
    margin-left: -8px;
    margin-top: -8px;
    border: 2px solid #ffffff;
    border-radius: 50%;
    border-top-color: transparent;
    animation: spinner 0.6s linear infinite;
}

.btn-submit.success {
    background: linear-gradient(135deg, #10b981 0%, #059669 100%) !important;
}

/* Animations */
@keyframes fadeIn {
    from {
        opacity: 0;
    }
    to {
        opacity: 1;
    }
}

@keyframes modalSlideIn {
    to {
        transform: scale(1);
        opacity: 1;
    }
}

@keyframes modalSlideOut {
    to {
        transform: scale(0.7);
        opacity: 0;
    }
}

@keyframes stroke {
    100% {
        stroke-dashoffset: 0;
    }
}

@keyframes fillGreen {
    100% {
        box-shadow: inset 0 0 0 50px #4BB543;
    }
}

@keyframes scale {
    0%, 100% {
        transform: none;
    }
    50% {
        transform: scale(1.1);
    }
}

@keyframes slideUp {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes spinner {
    to {
        transform: rotate(360deg);
    }
}

/* Responsive */
@media (max-width: 768px) {
    .success-modal-content {
        padding: 2.5rem 1.5rem 2rem;
        width: 95%;
    }

    .success-checkmark {
        width: 80px;
        height: 80px;
    }

    .checkmark {
        width: 80px;
        height: 80px;
    }

    .success-title {
        font-size: 1.5rem;
    }

    .success-message {
        font-size: 1rem;
    }

    .success-submessage {
        font-size: 0.9rem;
    }

    .btn-close-success {
        padding: 0.875rem 1.5rem;
        font-size: 0.95rem;
    }

    .error-notification {
        top: 10px;
        max-width: calc(100% - 20px);
    }

    .error-notification.show {
        right: 10px;
    }
}

@media (max-width: 480px) {
    .success-modal-content {
        padding: 2rem 1rem 1.5rem;
    }

    .success-title {
        font-size: 1.3rem;
    }

    .success-icon {
        font-size: 1.5rem;
    }

    .error-notification {
        padding: 0.875rem 1rem;
    }

    .error-title {
        font-size: 0.9rem;
    }

    .error-message {
        font-size: 0.85rem;
    }
}
