/* Premium Modal Styles - Reusable Package */
/* Version 1.0 - MyForge.ai */

/* === Core Modal Wrapper === */
.glass-modal {
    position: fixed !important;
    top: 0 !important;
    left: 0 !important;
    width: 100% !important;
    height: 100% !important;
    z-index: 10000 !important;
    display: none;
    align-items: center;
    justify-content: center;
    background: rgba(0, 0, 0, 0.7);
    backdrop-filter: blur(8px);
    padding: 1rem;
}

.glass-modal.is-open {
    display: flex !important;
}

/* === Core Modal Structure === */
.premium-modal-backdrop {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: -1;
    overflow: hidden;
    pointer-events: none;
}

.modal-floating-particles {
    position: absolute;
    width: 100%;
    height: 100%;
    overflow: hidden;
}

.modal-particle {
    position: absolute;
    background: linear-gradient(45deg, #667eea, #764ba2, #f093fb, #4facfe);
    border-radius: 50%;
    opacity: 0.1;
    animation: modalParticleFloat 20s infinite linear;
}

@keyframes modalParticleFloat {
    0% {
        transform: translateY(100vh) rotate(0deg);
        opacity: 0;
    }
    10% {
        opacity: 0.1;
    }
    90% {
        opacity: 0.1;
    }
    100% {
        transform: translateY(-10vh) rotate(360deg);
        opacity: 0;
    }
}

.modal-wave-animation {
    position: absolute;
    top: 0;
    left: -50%;
    width: 200%;
    height: 100%;
    background: linear-gradient(90deg, 
        transparent 0%,
        rgba(102, 126, 234, 0.05) 25%,
        rgba(118, 75, 162, 0.05) 50%,
        rgba(102, 126, 234, 0.05) 75%,
        transparent 100%
    );
    animation: modalWave 15s ease-in-out infinite;
}

@keyframes modalWave {
    0%, 100% {
        transform: translateX(0) scaleY(1);
    }
    50% {
        transform: translateX(-25%) scaleY(1.1);
    }
}

.modal-gradient-orb {
    position: absolute;
    border-radius: 50%;
    filter: blur(60px);
    animation: modalPulse 8s ease-in-out infinite;
}

.modal-gradient-orb:nth-child(3) {
    top: 20%;
    left: 20%;
    width: 120px;
    height: 120px;
    background: linear-gradient(135deg, #667eea, #764ba2);
    animation-delay: 0s;
}

.modal-gradient-orb:nth-child(4) {
    bottom: 30%;
    right: 20%;
    width: 80px;
    height: 80px;
    background: linear-gradient(135deg, #f093fb, #4facfe);
    animation-delay: 2s;
}

.modal-gradient-orb:nth-child(5) {
    top: 60%;
    left: 60%;
    width: 100px;
    height: 100px;
    background: linear-gradient(135deg, #764ba2, #667eea);
    animation-delay: 4s;
}

@keyframes modalPulse {
    0%, 100% {
        opacity: 0.1;
        transform: scale(1);
    }
    50% {
        opacity: 0.2;
        transform: scale(1.2);
    }
}

.modal-grid-pattern {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-image: 
        linear-gradient(rgba(255, 255, 255, 0.02) 1px, transparent 1px),
        linear-gradient(90deg, rgba(255, 255, 255, 0.02) 1px, transparent 1px);
    background-size: 20px 20px;
    animation: modalGridShift 20s ease-in-out infinite;
}

@keyframes modalGridShift {
    0%, 100% {
        transform: translate(0, 0);
    }
    50% {
        transform: translate(-10px, -10px);
    }
}

/* === Glass Content Container === */
.premium-glass-content {
    position: relative;
    background: linear-gradient(135deg, 
        rgba(255, 255, 255, 0.1) 0%,
        rgba(255, 255, 255, 0.05) 50%,
        rgba(255, 255, 255, 0.1) 100%
    );
    backdrop-filter: blur(20px);
    border: 1px solid rgba(255, 255, 255, 0.2);
    border-radius: 24px;
    padding: 3rem 2.5rem;
    width: 90%;
    max-width: 420px;
    box-shadow: 
        0 25px 50px rgba(0, 0, 0, 0.5),
        0 0 0 1px rgba(255, 255, 255, 0.1),
        inset 0 1px 0 rgba(255, 255, 255, 0.2);
    z-index: 10;
}

.premium-glass-content::before {
    content: '';
    position: absolute;
    inset: 0;
    border-radius: 24px;
    padding: 1px;
    background: linear-gradient(135deg, rgba(255, 255, 255, 0.3), rgba(255, 255, 255, 0.1));
    mask: linear-gradient(#fff 0 0) content-box, linear-gradient(#fff 0 0);
    mask-composite: exclude;
    pointer-events: none;
}

/* === Close Button === */
.premium-close {
    position: absolute;
    top: 1.5rem;
    right: 1.5rem;
    background: rgba(0, 0, 0, 0.3);
    border: 1px solid rgba(255, 255, 255, 0.2);
    border-radius: 50%;
    color: rgba(255, 255, 255, 0.7);
    cursor: pointer;
    font-size: 1.25rem;
    transition: all 0.3s ease;
    z-index: 20;
    width: 40px;
    height: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.premium-close:hover {
    background: rgba(239, 68, 68, 0.3);
    border-color: rgba(239, 68, 68, 0.5);
    color: white;
    transform: scale(1.1);
}

/* === Welcome Icon === */
.premium-welcome-icon {
    width: 80px;
    height: 80px;
    margin: 0 auto 2rem;
    background: linear-gradient(135deg, #667eea, #764ba2);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
    animation: premiumPulse 3s ease-in-out infinite;
}

.premium-welcome-icon i {
    font-size: 2rem;
    color: white;
}

.premium-welcome-icon::after {
    content: '';
    position: absolute;
    inset: -10px;
    border-radius: 50%;
    background: linear-gradient(135deg, #667eea, #764ba2);
    opacity: 0.3;
    filter: blur(10px);
    animation: premiumRipple 3s ease-in-out infinite;
}

@keyframes premiumPulse {
    0%, 100% {
        transform: scale(1);
        box-shadow: 0 0 0 0 rgba(102, 126, 234, 0.7);
    }
    50% {
        transform: scale(1.05);
        box-shadow: 0 0 0 15px rgba(102, 126, 234, 0);
    }
}

@keyframes premiumRipple {
    0%, 100% {
        transform: scale(1);
        opacity: 0.3;
    }
    50% {
        transform: scale(1.2);
        opacity: 0;
    }
}

/* === Title and Subtitle === */
.premium-modal-title {
    text-align: center;
    font-size: 2rem;
    font-weight: 700;
    color: white;
    margin-bottom: 0.5rem;
    background: linear-gradient(135deg, #667eea, #764ba2);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.premium-modal-subtitle {
    text-align: center;
    color: rgba(255, 255, 255, 0.7);
    font-size: 0.95rem;
    margin-bottom: 2rem;
    line-height: 1.5;
}

/* === Status Messages === */
.premium-verification-banner {
    background: linear-gradient(135deg, #10b981, #059669);
    color: white;
    padding: 1rem;
    border-radius: 12px;
    margin-bottom: 1.5rem;
    display: none;
    align-items: center;
    gap: 0.75rem;
    font-weight: 500;
}

.premium-status-message {
    padding: 1rem;
    border-radius: 12px;
    margin-bottom: 1rem;
    display: none;
    align-items: center;
    gap: 0.75rem;
    font-weight: 500;
}

.premium-status-success {
    background: linear-gradient(135deg, rgba(16, 185, 129, 0.2), rgba(5, 150, 105, 0.2));
    border: 1px solid rgba(16, 185, 129, 0.3);
    color: #10b981;
}

.premium-status-error {
    background: linear-gradient(135deg, rgba(239, 68, 68, 0.2), rgba(220, 38, 38, 0.2));
    border: 1px solid rgba(239, 68, 68, 0.3);
    color: #ef4444;
}

.premium-status-info {
    background: linear-gradient(135deg, rgba(59, 130, 246, 0.2), rgba(37, 99, 235, 0.2));
    border: 1px solid rgba(59, 130, 246, 0.3);
    color: #3b82f6;
}

/* === Input Fields === */
.premium-input-group {
    position: relative;
    margin-bottom: 2.5rem;
    text-align: left;
}

.premium-input-field {
    width: 100%;
    padding: 1.5rem 1.25rem 1rem 1.25rem;
    background: rgba(255, 255, 255, 0.12);
    border: 2px solid rgba(255, 255, 255, 0.25);
    border-radius: 16px;
    color: white;
    font-size: 1rem;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    backdrop-filter: blur(15px);
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.2);
}

.premium-input-field:focus {
    outline: none;
    border-color: #667eea;
    background: rgba(255, 255, 255, 0.15);
    box-shadow: 0 0 0 3px rgba(102, 126, 234, 0.3), 0 8px 32px rgba(0, 0, 0, 0.3);
}

.premium-input-field::placeholder {
    color: transparent;
}

.premium-input-label {
    position: absolute;
    left: 1.25rem;
    top: 1.5rem;
    color: rgba(255, 255, 255, 0.8);
    font-size: 1rem;
    font-weight: 500;
    transition: all 0.3s ease;
    pointer-events: none;
    background: linear-gradient(135deg, rgba(0, 0, 0, 0.6), rgba(0, 0, 0, 0.4));
    padding: 0.25rem 0.75rem;
    border-radius: 8px;
    backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.1);
}

.premium-input-field:focus + .premium-input-label,
.premium-input-field:not(:placeholder-shown) + .premium-input-label,
.premium-input-label.active,
.premium-input-label.focused {
    top: -0.75rem;
    left: 1rem;
    font-size: 0.75rem;
    color: #667eea;
    font-weight: 600;
    background: linear-gradient(135deg, rgba(102, 126, 234, 0.4), rgba(102, 126, 234, 0.2));
    backdrop-filter: blur(15px);
    border-color: rgba(102, 126, 234, 0.3);
    transform: translateZ(0);
}

/* === Password Toggle === */
.premium-password-toggle {
    position: absolute;
    right: 1.25rem;
    top: 50%;
    transform: translateY(-50%);
    background: rgba(0, 0, 0, 0.3);
    border: 1px solid rgba(255, 255, 255, 0.2);
    border-radius: 8px;
    color: rgba(255, 255, 255, 0.7);
    cursor: pointer;
    font-size: 1rem;
    transition: all 0.3s ease;
    z-index: 10;
    padding: 0.5rem;
    width: 2.5rem;
    height: 2.5rem;
    display: flex;
    align-items: center;
    justify-content: center;
}

.premium-password-toggle:hover {
    color: white;
    background: rgba(102, 126, 234, 0.3);
    border-color: rgba(102, 126, 234, 0.5);
}

/* === Form Options === */
.premium-form-options {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin: 2.5rem 0;
    font-size: 0.9rem;
}

.premium-remember-me {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    color: rgba(255, 255, 255, 0.7);
    cursor: pointer;
}

.premium-checkbox {
    width: 18px;
    height: 18px;
    border: 2px solid rgba(255, 255, 255, 0.3);
    border-radius: 4px;
    background: transparent;
    cursor: pointer;
    position: relative;
    transition: all 0.3s ease;
    appearance: none;
}

.premium-checkbox:checked {
    background: linear-gradient(135deg, #667eea, #764ba2);
    border-color: #667eea;
}

.premium-checkbox:checked::after {
    content: '✓';
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    color: white;
    font-size: 0.7rem;
    font-weight: bold;
}

.premium-forgot-password {
    color: #667eea;
    text-decoration: none;
    font-weight: 600;
    transition: all 0.3s ease;
}

.premium-forgot-password:hover {
    color: #764ba2;
    text-decoration: underline;
}

/* === Buttons === */
.premium-btn {
    padding: 1.25rem 2rem;
    border-radius: 16px;
    font-weight: 600;
    font-size: 1rem;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    border: none;
    cursor: pointer;
    position: relative;
    overflow: hidden;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    text-decoration: none;
    width: 100%;
    margin-bottom: 1.5rem;
    backdrop-filter: blur(10px);
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.3);
}

.premium-btn-primary {
    background: linear-gradient(135deg, #4f46e5, #7c3aed, #8b5cf6);
    color: white;
    border: 1px solid rgba(139, 92, 246, 0.4);
    box-shadow: 
        0 8px 32px rgba(79, 70, 229, 0.4),
        0 0 0 1px rgba(139, 92, 246, 0.2),
        inset 0 1px 0 rgba(255, 255, 255, 0.1);
}

.premium-btn-primary:hover:not(:disabled) {
    transform: translateY(-3px);
    background: linear-gradient(135deg, #4338ca, #6d28d9, #7c3aed);
    box-shadow: 
        0 12px 40px rgba(79, 70, 229, 0.5),
        0 0 0 1px rgba(139, 92, 246, 0.3),
        inset 0 1px 0 rgba(255, 255, 255, 0.2);
    border-color: rgba(139, 92, 246, 0.6);
}

.premium-btn-primary:active:not(:disabled) {
    transform: translateY(-1px);
    box-shadow: 
        0 6px 20px rgba(79, 70, 229, 0.3),
        0 0 0 1px rgba(139, 92, 246, 0.2),
        inset 0 1px 0 rgba(255, 255, 255, 0.1);
}

.premium-btn-primary:disabled {
    opacity: 0.6;
    cursor: not-allowed;
    transform: none;
    background: linear-gradient(135deg, #6b7280, #9ca3af);
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.2);
}

.premium-btn-google {
    background: linear-gradient(135deg, #dc2626, #b91c1c, #991b1b);
    color: white;
    border: 1px solid rgba(220, 38, 38, 0.4);
    box-shadow: 
        0 8px 32px rgba(220, 38, 38, 0.4),
        0 0 0 1px rgba(220, 38, 38, 0.2),
        inset 0 1px 0 rgba(255, 255, 255, 0.1);
}

.premium-btn-google:hover {
    transform: translateY(-3px);
    background: linear-gradient(135deg, #b91c1c, #991b1b, #7f1d1d);
    box-shadow: 
        0 12px 40px rgba(220, 38, 38, 0.5),
        0 0 0 1px rgba(220, 38, 38, 0.3),
        inset 0 1px 0 rgba(255, 255, 255, 0.2);
    border-color: rgba(220, 38, 38, 0.6);
}

/* === Divider === */
.premium-divider {
    display: flex;
    align-items: center;
    margin: 2.5rem 0;
    gap: 1rem;
}

.premium-divider::before,
.premium-divider::after {
    content: '';
    flex: 1;
    height: 1px;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.2), transparent);
}

.premium-divider span {
    color: rgba(255, 255, 255, 0.6);
    font-size: 0.875rem;
    font-weight: 500;
}

/* === Links === */
.premium-register-link {
    text-align: center;
    margin-top: 1.5rem;
    color: rgba(255, 255, 255, 0.7);
    font-size: 0.9rem;
}

.premium-link {
    color: #667eea;
    text-decoration: none;
    font-weight: 600;
    transition: all 0.3s ease;
}

.premium-link:hover {
    color: #764ba2;
    text-decoration: underline;
}

/* === Responsive Design === */
@media (max-width: 768px) {
    .premium-glass-content {
        padding: 2rem 1.5rem;
        margin: 1rem;
        max-width: calc(100% - 2rem);
    }
    
    .premium-modal-title {
        font-size: 1.75rem;
    }
    
    .premium-welcome-icon {
        width: 70px;
        height: 70px;
    }
    
    .premium-welcome-icon i {
        font-size: 1.75rem;
    }
    
    .premium-form-options {
        flex-direction: column;
        gap: 1rem;
        align-items: flex-start;
    }
}

@media (max-width: 480px) {
    .premium-glass-content {
        padding: 1.5rem 1rem;
    }
    
    .premium-modal-title {
        font-size: 1.5rem;
    }
    
    .premium-welcome-icon {
        width: 60px;
        height: 60px;
        margin-bottom: 1.5rem;
    }
    
    .premium-welcome-icon i {
        font-size: 1.5rem;
    }
} 