/* Waitlist Modal Styles - Centralized Implementation */
/* Version 1.1 - Enhanced with smooth bounce animations from About page */

/* Base Modal Container */
.waitlist-modal {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0);
    z-index: 10000;
    backdrop-filter: blur(0px);
    opacity: 0;
    visibility: hidden;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 20px;
    transition: all 0.4s cubic-bezier(0.25, 0.8, 0.25, 1);
}

.waitlist-modal.active {
    background: rgba(0, 0, 0, 0.8);
    backdrop-filter: blur(10px);
    opacity: 1;
    visibility: visible;
}

/* Modal Content Container */
.waitlist-modal-content {
    background: var(--accent-gradient);
    border-radius: 25px;
    max-width: 600px;
    width: 100%;
    max-height: 90vh;
    overflow-y: auto;
    position: relative;
    transform: scale(0.7) translateY(50px);
    transition: all 0.6s cubic-bezier(0.34, 1.56, 0.64, 1);
    opacity: 0;
    padding: 80px 40px;
    text-align: center;
    box-shadow: 0 25px 50px rgba(0, 0, 0, 0.5);
    backdrop-filter: blur(20px);
    border: 1px solid rgba(255, 255, 255, 0.1);
}

.waitlist-modal.active .waitlist-modal-content {
    transform: scale(1) translateY(0px);
    opacity: 1;
}

/* Closing Animation */
.waitlist-modal.closing {
    background: rgba(0, 0, 0, 0);
    backdrop-filter: blur(0px);
    opacity: 0;
    visibility: visible;
}

.waitlist-modal.closing .waitlist-modal-content {
    transform: scale(0.9) translateY(-30px);
    opacity: 0;
    transition: all 0.3s cubic-bezier(0.25, 0.8, 0.25, 1);
}

/* Modal Header */
.waitlist-modal-header {
    position: relative;
    z-index: 1;
    margin-bottom: 20px;
}

.waitlist-modal-header h2 {
    margin: 0;
    font-size: 2.8rem;
    font-weight: 700;
    color: white;
    line-height: 1.2;
}

/* Close Button - Form Modal */
.waitlist-modal-close {
    position: absolute;
    top: -40px;
    right: -20px;
    background: rgba(255, 255, 255, 0.1);
    border: 2px solid rgba(255, 255, 255, 0.3);
    border-radius: 50%;
    color: white;
    font-size: 24px;
    font-weight: bold;
    cursor: pointer;
    width: 50px;
    height: 50px;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s ease;
    backdrop-filter: blur(10px);
    z-index: 2;
    padding-bottom: 3px;
}

.waitlist-modal-close:hover {
    background: rgba(255, 255, 255, 0.2);
    border-color: rgba(255, 255, 255, 0.5);
    transform: scale(1.1);
}

/* Modal Body */
.waitlist-modal-body {
    position: relative;
    z-index: 1;
}

.waitlist-modal-body p {
    color: rgba(255, 255, 255, 0.9);
    margin-bottom: 25px;
    line-height: 1.6;
    font-size: 1.3rem;
}

/* Form Styles */
.form-group {
    margin-bottom: 25px;
    text-align: left;
}

.form-group label {
    display: block;
    color: white;
    margin-bottom: 10px;
    font-weight: 500;
    text-align: center;
    font-size: 1rem;
}

.form-group input[type="email"] {
    width: 100%;
    padding: 15px;
    border: 2px solid rgba(255, 255, 255, 0.3);
    border-radius: 8px;
    background: rgba(255, 255, 255, 0.1);
    color: white;
    font-size: 16px;
    box-sizing: border-box;
    transition: all 0.3s ease;
    backdrop-filter: blur(10px);
}

.form-group input[type="email"]:focus {
    outline: none;
    border-color: rgba(255, 255, 255, 0.6);
    background: rgba(255, 255, 255, 0.15);
}

.form-group input[type="email"]::placeholder {
    color: rgba(255, 255, 255, 0.7);
}

/* Email validation states */
.form-group input[type="email"].invalid {
    border-color: #ff6b6b;
    background: rgba(255, 107, 107, 0.1);
}

.form-group input[type="email"].invalid:focus {
    border-color: #ff6b6b;
    box-shadow: 0 0 0 3px rgba(255, 107, 107, 0.2);
}

.form-group input[type="email"].valid {
    border-color: #4caf50;
    background: rgba(76, 175, 80, 0.1);
}

.form-group input[type="email"].valid:focus {
    border-color: #4caf50;
    box-shadow: 0 0 0 3px rgba(76, 175, 80, 0.2);
}

/* Checkbox Group */
.checkbox-group {
    display: flex;
    gap: 20px;
    flex-wrap: wrap;
    justify-content: center;
}

.checkbox-label {
    display: flex;
    align-items: center;
    gap: 10px;
    cursor: pointer;
    color: white;
    font-weight: 500;
}

.checkbox-label:hover {
    color: rgba(255, 255, 255, 0.8);
}

.checkbox-label input[type="checkbox"] {
    width: 18px;
    height: 18px;
    cursor: pointer;
    accent-color: white;
}

/* hCaptcha Container */
.hcaptcha-container {
    display: flex;
    justify-content: center;
    margin: 20px 0;
    min-height: 78px;
    position: relative;
}

.hcaptcha-container.loading::before {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 20px;
    height: 20px;
    border: 2px solid rgba(255, 255, 255, 0.3);
    border-top: 2px solid white;
    border-radius: 50%;
    animation: spin 1s linear infinite;
}

@keyframes spin {
    0% { transform: translate(-50%, -50%) rotate(0deg); }
    100% { transform: translate(-50%, -50%) rotate(360deg); }
}

/* Submit Button */
.waitlist-submit-btn {
    width: 100%;
    padding: 18px 30px;
    background: white;
    color: var(--accent-primary);
    border: none;
    border-radius: 12px;
    font-size: 1.2rem;
    font-weight: 700;
    cursor: pointer;
    transition: all 0.3s ease;
    margin-top: 20px;
}

.waitlist-submit-btn:hover {
    background: rgba(255, 255, 255, 0.9);
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.2);
}

.waitlist-submit-btn:disabled {
    opacity: 0.7;
    cursor: not-allowed;
    transform: none;
}

/* Error Message */
.waitlist-error-message {
    color: #ff6b6b;
    background: rgba(255, 107, 107, 0.1);
    border: 1px solid rgba(255, 107, 107, 0.3);
    padding: 12px 16px;
    border-radius: 8px;
    margin: 15px 0;
    font-size: 0.9rem;
    display: none;
}

.waitlist-error-message.show {
    display: block;
}

/* Success State */
.waitlist-success {
    text-align: center;
    color: white;
    position: relative;
}

.waitlist-success h3 {
    color: white;
    margin-bottom: 25px;
    font-size: 2.8rem;
    font-weight: 700;
    line-height: 1.2;
}

.waitlist-success p {
    color: rgba(255, 255, 255, 0.9);
    margin-bottom: 35px;
    font-size: 1.3rem;
    line-height: 1.6;
}

/* Success Close Button */
.waitlist-success-close {
    position: absolute;
    top: -40px;
    right: -20px;
    background: rgba(255, 255, 255, 0.1);
    border: 2px solid rgba(255, 255, 255, 0.3);
    border-radius: 50%;
    color: white;
    font-size: 24px;
    font-weight: bold;
    cursor: pointer;
    width: 50px;
    height: 50px;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s ease;
    backdrop-filter: blur(10px);
    z-index: 3;
    line-height: 1;
    margin: 0;
    font-family: Arial, sans-serif;
}

.waitlist-success-close::before {
    content: '×';
}

.waitlist-success-close:hover {
    background: rgba(255, 255, 255, 0.2);
    border-color: rgba(255, 255, 255, 0.5);
    transform: scale(1.1);
}

/* Social Icons */
.waitlist-social-icons {
    display: flex;
    gap: 20px;
    justify-content: center;
    align-items: center;
    margin-top: 30px;
}

.waitlist-social-icons a {
    color: white;
    font-size: 2.2rem;
    transition: all 0.3s ease;
    text-decoration: none;
    padding: 10px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.1);
    display: flex;
    align-items: center;
    justify-content: center;
    width: 60px;
    height: 60px;
}

.waitlist-social-icons a:hover {
    color: white;
    background: rgba(255, 255, 255, 0.2);
    transform: translateY(-3px) scale(1.1);
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.3);
}

/* Responsive Design */
@media (max-width: 768px) {
    .waitlist-modal-content {
        margin: 10px;
        max-height: 95vh;
        padding: 50px 25px;
    }
    
    .waitlist-modal-header h2 {
        font-size: 2.2rem;
    }
    
    .waitlist-modal-body p {
        font-size: 1.1rem;
    }
    
    .waitlist-modal-close {
        top: -40px;
        right: -10px;
        width: 40px;
        height: 40px;
        font-size: 20px;
        padding-bottom: 3px;
    }

    .waitlist-success-close {
        top: -40px;
        right: -10px;
        width: 40px;
        height: 40px;
        font-size: 20px;
    }

    .checkbox-group {
        flex-direction: column;
        gap: 10px;
        align-items: center;
    }
}

@media (max-width: 480px) {
    .checkbox-group {
        flex-direction: column;
        gap: 10px;
        align-items: center;
    }
}
