/* WhatsApp OTP Login Plugin Styles */

/* Checkout OTP Container */
#wol-checkout-otp-container {
    border: 1px solid #ddd;
    padding: 20px;
    border-radius: 8px;
    background-color: #f9f9f9;
    margin-top: 20px;
    margin-bottom: 20px;
}

#wol-checkout-otp-container h3 {
    margin-top: 0;
    color: #333;
    font-size: 18px;
}

#wol-checkout-otp-container p {
    margin-bottom: 15px;
    color: #666;
}

/* OTP Input Fields */
#wol-checkout-otp-input,
#wol-login-otp,
#wol-modal-otp {
    padding: 12px 16px;
    border: 2px solid #e1e5e9;
    border-radius: 8px;
    margin-right: 10px;
    width: 150px;
    font-size: 18px;
    text-align: center;
    letter-spacing: 3px;
    font-weight: 600;
    transition: all 0.3s ease;
    box-sizing: border-box;
}

#wol-checkout-otp-input:focus,
#wol-login-otp:focus,
#wol-modal-otp:focus {
    outline: none;
    border-color: #25d366;
    box-shadow: 0 0 0 3px rgba(37, 211, 102, 0.1);
}

/* Phone Input Fields */
#wol-login-phone,
#wol-modal-phone {
    padding: 12px 16px;
    border: 2px solid #e1e5e9;
    border-radius: 8px;
    width: 100%;
    font-size: 16px;
    transition: all 0.3s ease;
    box-sizing: border-box;
}

#wol-login-phone:focus,
#wol-modal-phone:focus {
    outline: none;
    border-color: #25d366;
    box-shadow: 0 0 0 3px rgba(37, 211, 102, 0.1);
}

/* Buttons */
#wol-send-checkout-otp-btn,
#wol-checkout-submit-otp-btn,
#wol-checkout-resend-otp-btn,
#wol-login-send-otp-btn,
#wol-login-verify-otp-btn,
#wol-modal-send-otp-btn,
#wol-modal-verify-otp-btn {
    background-color: #25d366;
    color: white;
    border: none;
    padding: 12px 24px;
    border-radius: 8px;
    cursor: pointer;
    font-size: 14px;
    font-weight: 600;
    transition: all 0.3s ease;
    display: inline-flex;
    align-items: center;
    gap: 8px;
    box-shadow: 0 2px 4px rgba(37, 211, 102, 0.2);
}

#wol-send-checkout-otp-btn:hover,
#wol-checkout-submit-otp-btn:hover,
#wol-checkout-resend-otp-btn:hover,
#wol-login-send-otp-btn:hover,
#wol-login-verify-otp-btn:hover,
#wol-modal-send-otp-btn:hover,
#wol-modal-verify-otp-btn:hover {
    background-color: #128c7e;
    transform: translateY(-1px);
    box-shadow: 0 4px 8px rgba(37, 211, 102, 0.3);
}

.wol-primary-btn {
    background: linear-gradient(135deg, #25d366 0%, #128c7e 100%);
    color: white;
    border: none;
    padding: 14px 28px;
    border-radius: 8px;
    cursor: pointer;
    font-size: 16px;
    font-weight: 600;
    transition: all 0.3s ease;
    display: inline-flex;
    align-items: center;
    gap: 8px;
    width: 100%;
    justify-content: center;
    box-shadow: 0 4px 8px rgba(37, 211, 102, 0.2);
}

.wol-primary-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 12px rgba(37, 211, 102, 0.3);
}

#wol-checkout-resend-otp-btn:disabled,
#wol-checkout-resend-otp-btn[disabled] {
    background-color: #ccc;
    cursor: not-allowed;
}

/* Success Message */
#wol-checkout-otp-success {
    padding: 15px;
    background-color: #d4edda;
    border: 1px solid #c3e6cb;
    border-radius: 5px;
    color: #155724;
    font-weight: bold;
    text-align: center;
}

.wol-otp-sent-message {
    background: #f0f9ff;
    border: 1px solid #bae6fd;
    border-radius: 8px;
    padding: 16px;
    margin-bottom: 20px;
    text-align: center;
}

.wol-success-icon {
    background: #25d366;
    color: white;
    width: 32px;
    height: 32px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 12px;
    font-size: 18px;
    font-weight: bold;
}

.wol-otp-sent-message p {
    margin: 0;
    color: #0369a1;
    font-weight: 500;
}

.wol-resend-section {
    margin-top: 20px;
    text-align: center;
}

.wol-resend-section button {
    background: none;
    border: none;
    color: #25d366;
    text-decoration: underline;
    cursor: pointer;
    font-size: 14px;
    padding: 8px 16px;
    border-radius: 4px;
    transition: all 0.3s ease;
}

.wol-resend-section button:hover:not(:disabled) {
    background: rgba(37, 211, 102, 0.1);
}

.wol-resend-section button:disabled {
    color: #999;
    cursor: not-allowed;
    text-decoration: none;
}

/* My Account Login Section */
#wol-login-otp-container {
    margin-top: 15px;
    text-align: center;
}

.wol-divider {
    position: relative;
    text-align: center;
    margin: 20px 0;
}

.wol-divider::before {
    content: '';
    position: absolute;
    top: 50%;
    left: 0;
    right: 0;
    height: 1px;
    background: #ddd;
}

.wol-divider span {
    background: #fff;
    padding: 0 15px;
    color: #666;
    font-size: 14px;
    position: relative;
    z-index: 1;
}

.wol-otp-login-btn {
    background: #25d366 !important;
    background-color: #25d366 !important;
    color: white !important;
    border: none !important;
    border-color: transparent !important;
    padding: 12px 24px;
    border-radius: 6px;
    cursor: pointer;
    font-size: 14px;
    font-weight: 500;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    transition: all 0.3s ease;
    box-shadow: 0 2px 4px rgba(37, 211, 102, 0.2) !important;
    width: 100%;
}

.wol-otp-login-btn:hover {
    background: #128c7e !important;
    background-color: #128c7e !important;
    color: white !important;
    transform: translateY(-1px);
    box-shadow: 0 4px 8px rgba(37, 211, 102, 0.3) !important;
}

.wol-whatsapp-icon {
    flex-shrink: 0;
}

/* Modal Styles */
.wol-modal {
    display: none;
    position: fixed;
    z-index: 99999 !important;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.5);
}

.wol-modal.show {
    display: block;
}

.wol-modal-content {
    background-color: #fefefe !important;
    margin: 5% auto;
    padding: 0;
    border-radius: 12px;
    width: 90%;
    max-width: 400px;
    position: relative;
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.15);
    overflow: hidden;
}

.wol-close {
    color: #999;
    float: right;
    font-size: 24px;
    font-weight: 300;
    position: absolute;
    right: 20px;
    top: 20px;
    cursor: pointer;
    z-index: 10;
    width: 30px;
    height: 30px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    transition: all 0.3s ease;
}

.wol-close:hover,
.wol-close:focus {
    color: #333;
    background: #f5f5f5;
}

.wol-modal-header {
    background: linear-gradient(135deg, #25d366 0%, #128c7e 100%) !important;
    background-color: #25d366 !important;
    color: white !important;
    padding: 30px 30px 25px;
    text-align: center;
}

.wol-modal-header h2 {
    margin: 0 0 8px 0;
    font-size: 22px;
    font-weight: 600;
    color: white !important;
}

.wol-modal-header p {
    margin: 0;
    opacity: 0.9;
    font-size: 14px;
    color: white !important;
}

#wol-modal-otp-form {
    padding: 30px;
}

.wol-form-step {
    transition: all 0.3s ease;
}

.wol-input-group {
    margin-bottom: 20px;
}

.wol-input-group label {
    display: block;
    margin-bottom: 8px;
    font-weight: 500;
    color: #333;
    font-size: 14px;
}

/* Form Row Styles */
.form-row {
    margin-bottom: 15px;
}

.form-row label {
    display: block;
    margin-bottom: 5px;
    font-weight: 500;
    color: #333;
}

.form-row .required {
    color: #e2401c;
}

/* Responsive Design */
@media (max-width: 768px) {
    .wol-modal {
        display: none !important;
        position: fixed !important;
        z-index: 99999 !important;
        left: 0 !important;
        top: 0 !important;
        width: 100% !important;
        height: 100% !important;
        background-color: rgba(0, 0, 0, 0.5) !important;
        -webkit-overflow-scrolling: touch !important;
    }
    
    .wol-modal.show {
        display: block !important;
    }
    
    .wol-modal-content {
        width: 95% !important;
        max-width: 350px !important;
        margin: 5% auto !important;
        padding: 0 !important;
        border-radius: 12px !important;
        position: relative !important;
        box-shadow: 0 10px 25px rgba(0, 0, 0, 0.15) !important;
        overflow: hidden !important;
        background-color: #fefefe !important;
    }
    
    .wol-modal-header {
        padding: 20px 20px 15px !important;
    }
    
    .wol-modal-header h2 {
        font-size: 18px !important;
    }
    
    #wol-modal-otp-form {
        padding: 20px !important;
    }
    
    #wol-checkout-otp-input,
    #wol-login-otp,
    #wol-modal-otp {
        width: 100% !important;
        font-size: 16px !important;
        padding: 12px 16px !important;
    }
    
    #wol-modal-phone {
        width: 100% !important;
        font-size: 16px !important;
        padding: 12px 16px !important;
    }
    
    #wol-send-checkout-otp-btn,
    #wol-checkout-submit-otp-btn,
    #wol-checkout-resend-otp-btn,
    #wol-login-send-otp-btn,
    #wol-login-verify-otp-btn,
    #wol-modal-send-otp-btn,
    #wol-modal-verify-otp-btn {
        width: 100% !important;
        margin-top: 10px !important;
        padding: 12px 24px !important;
        font-size: 16px !important;
    }
    
    .wol-close {
        right: 15px !important;
        top: 15px !important;
        width: 35px !important;
        height: 35px !important;
        font-size: 28px !important;
    }
}

/* Loading States */
.wol-loading {
    opacity: 0.6;
    pointer-events: none;
}

.wol-loading::after {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 20px;
    height: 20px;
    margin: -10px 0 0 -10px;
    border: 2px solid #f3f3f3;
    border-top: 2px solid #25d366;
    border-radius: 50%;
    animation: wol-spin 1s linear infinite;
}

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

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

/* WhatsApp Brand Colors */
.wol-whatsapp-brand {
    color: #25d366;
}

.wol-whatsapp-brand:hover {
    color: #128c7e;
}

/* Error States */
.wol-error {
    border-color: #dc3545 !important;
    box-shadow: 0 0 0 1px #dc3545 !important;
}

.wol-error-message {
    color: #dc3545;
    font-size: 14px;
    margin-top: 5px;
}

/* Success States */
.wol-success {
    border-color: #28a745 !important;
    box-shadow: 0 0 0 1px #28a745 !important;
}

.wol-success-message {
    color: #28a745;
    font-size: 14px;
    margin-top: 5px;
} 