/* popup.css - Nayako Reusable Animated Popup */

.nayako-popup-overlay {
    position: fixed; top: 0; left: 0; width: 100%; height: 100%;
    background: rgba(10, 10, 12, 0.85); backdrop-filter: blur(8px);
    display: flex; justify-content: center; align-items: center;
    z-index: 9999; opacity: 0; pointer-events: none; transition: opacity 0.3s ease;
}

.nayako-popup-overlay.active { opacity: 1; pointer-events: auto; }

.nayako-popup-box {
    background: rgba(18, 18, 24, 0.95);
    border: 1px solid rgba(255, 154, 158, 0.2); border-radius: 20px;
    padding: 30px; text-align: center;
    box-shadow: 0 0 50px rgba(0, 0, 0, 0.8);
    transform: scale(0.8) translateY(20px); transition: all 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    max-width: 350px; width: 90%;
}
.nayako-popup-overlay.active .nayako-popup-box { transform: scale(1) translateY(0); }

.nayako-popup-box h2 { font-size: 22px; margin-bottom: 8px; font-family: 'Prompt', sans-serif; }
.nayako-popup-box p { font-size: 14.5px; color: #a1a1aa; font-family: 'Prompt', sans-serif; line-height: 1.5; margin-bottom: 20px;}

.nayako-popup-btn {
    padding: 10px 24px; border: none; border-radius: 8px;
    font-size: 14px; font-weight: bold; cursor: pointer; transition: 0.2s;
    font-family: 'Prompt', sans-serif; margin-top: 10px;
}
.nayako-popup-btn:hover { opacity: 0.9; transform: translateY(-2px); }
.nayako-popup-btn.hidden { display: none; }

/* Success Animation */
.success-checkmark { width: 80px; height: 80px; margin: 0 auto 15px; position: relative; }
.check-icon { width: 80px; height: 80px; border-radius: 50%; box-sizing: content-box; border: 4px solid #4ade80; position: relative;}
.check-icon::before, .check-icon::after { content: ''; border-radius: 50%; position: absolute; width: 84px; height: 120px; background: #121218; transform: rotate(-45deg); }
.check-icon::before { border-radius: 120px 0 0 120px; top: -7px; left: -33px; transform-origin: 40px 40px; }
.check-icon::after { border-radius: 0 120px 120px 0; top: -11px; left: 30px; transform-origin: 0px 40px; animation: rotatePlaceholder 4.25s ease-in; }
.check-icon .icon-line { height: 5px; background-color: #4ade80; display: block; border-radius: 2px; position: absolute; z-index: 10; }
.check-icon .icon-line.line-tip { top: 46px; left: 14px; width: 25px; transform: rotate(45deg); animation: icon-line-tip 0.75s; }
.check-icon .icon-line.line-long { top: 38px; right: 8px; width: 47px; transform: rotate(-45deg); animation: icon-line-long 0.75s; }
.check-icon .icon-circle { top: -4px; left: -4px; z-index: 10; width: 80px; height: 80px; border-radius: 50%; position: absolute; box-sizing: content-box; border: 4px solid rgba(74, 222, 128, .5); }
.check-icon .icon-fix { top: 8px; width: 5px; left: 26px; z-index: 1; height: 85px; position: absolute; transform: rotate(-45deg); background-color: #121218; }

@keyframes rotatePlaceholder { 0%, 5% { transform: rotate(-45deg); } 100%, 12% { transform: rotate(-405deg); } }
@keyframes icon-line-tip { 0% { width: 0; left: 1px; top: 19px; } 54% { width: 0; left: 1px; top: 19px; } 70% { width: 50px; left: -8px; top: 37px; } 84% { width: 17px; left: 21px; top: 48px; } 100% { width: 25px; left: 14px; top: 46px; } }
@keyframes icon-line-long { 0% { width: 0; right: 46px; top: 54px; } 65% { width: 0; right: 46px; top: 54px; } 84% { width: 55px; right: 0px; top: 35px; } 100% { width: 47px; right: 8px; top: 38px; } }

/* Error Animation */
.error-cross { width: 80px; height: 80px; margin: 0 auto 15px; position: relative; }
.cross-icon { width: 80px; height: 80px; border-radius: 50%; border: 4px solid #ef4444; position: relative; animation: popIn 0.5s ease; }
.cross-icon .icon-line { position: absolute; height: 6px; background-color: #ef4444; border-radius: 3px; top: 50%; left: 50%; margin-top: -3px; z-index: 10; }
.cross-icon .icon-line.line-left { transform: rotate(45deg); animation: line-left-anim 0.5s forwards; }
.cross-icon .icon-line.line-right { transform: rotate(-45deg); animation: line-right-anim 0.5s forwards; }

@keyframes popIn { 0% { transform: scale(0); opacity: 0; } 50% { transform: scale(1.2); opacity: 1; } 100% { transform: scale(1); } }
@keyframes line-left-anim { 0% { width: 0; margin-left: 0; } 100% { width: 46px; margin-left: -23px; } }
@keyframes line-right-anim { 0% { width: 0; margin-left: 0; } 100% { width: 46px; margin-left: -23px; } }

/* Loading Animation */
.loading-spinner {
    width: 60px; height: 60px; margin: 0 auto 15px;
    border: 5px solid rgba(255, 154, 158, 0.2);
    border-top: 5px solid var(--primary);
    border-radius: 50%;
    animation: spinRotate 1s linear infinite;
}
@keyframes spinRotate { 0% { transform: rotate(0deg); } 100% { transform: rotate(360deg); } }
