/**
 * Email Capture Modal Styles
 * @package AI_Tarot_Reader
 * @since 3.5.0
 */

/* Modal Overlay */
.tarot-modal {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    z-index: 999999;
    display: flex;
    align-items: center;
    justify-content: center;
}

.tarot-modal-overlay {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.8);
    backdrop-filter: blur(5px);
}

.tarot-modal-content {
    position: relative;
    background: #fff;
    border-radius: 16px;
    max-width: 500px;
    width: 90%;
    max-height: 90vh;
    overflow-y: auto;
    box-shadow: 0 20px 60px rgba(0,0,0,0.4);
    z-index: 1;
}

.tarot-modal-close {
    position: absolute;
    top: 20px;
    right: 20px;
    width: 40px;
    height: 40px;
    border: none;
    background: #f5f5f5;
    color: #666;
    cursor: pointer;
    border-radius: 50%;
    transition: background 0.2s, color 0.2s;
    z-index: 10;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 0;
}

.tarot-modal-close svg {
    display: block;
}

.tarot-modal-close:hover {
    background: #e74c3c;
    color: #fff;
}

/* Modal Header */
.modal-header {
    padding: 40px 40px 30px;
    text-align: center;
    background: linear-gradient(135deg, #8e44ad 0%, #9b59b6 100%);
    color: #fff;
}

.modal-header .dashicons {
    font-size: 48px;
    width: 48px;
    height: 48px;
    color: #ffd700;
    margin-bottom: 15px;
    animation: pulse 2s infinite;
}

@keyframes pulse {
    0%, 100% { transform: scale(1); opacity: 1; }
    50% { transform: scale(1.1); opacity: 0.8; }
}

.modal-header h2 {
    margin: 0 0 10px 0;
    font-size: 28px;
    font-weight: 700;
}

.modal-header p {
    margin: 0;
    font-size: 16px;
    opacity: 0.95;
}

/* Forms */
.tarot-register-form,
.tarot-login-form {
    padding: 40px;
}

.form-group {
    margin-bottom: 20px;
}

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

.form-group input[type="email"],
.form-group input[type="text"],
.form-group input[type="password"] {
    width: 100%;
    padding: 12px 15px;
    border: 2px solid #e0e0e0;
    border-radius: 8px;
    font-size: 15px;
    transition: all 0.2s;
    box-sizing: border-box;
}

.form-group input:focus {
    outline: none;
    border-color: #8e44ad;
    box-shadow: 0 0 0 3px rgba(142, 68, 173, 0.1);
}

.form-group small {
    display: block;
    margin-top: 5px;
    font-size: 12px;
    color: #999;
}

/* Checkbox Groups */
.checkbox-group {
    margin-bottom: 20px;
}

.checkbox-label {
    display: flex;
    align-items: flex-start;
    cursor: pointer;
    font-weight: normal;
}

.checkbox-label input[type="checkbox"] {
    margin: 2px 10px 0 0;
    width: 18px;
    height: 18px;
    cursor: pointer;
    flex-shrink: 0;
}

.checkbox-label span {
    color: #555;
    font-size: 14px;
    line-height: 1.5;
}

.checkbox-label a {
    color: #8e44ad;
    text-decoration: none;
    font-weight: 600;
}

.checkbox-label a:hover {
    text-decoration: underline;
}

/* Error Message */
.form-error {
    padding: 12px 15px;
    background: #ffebee;
    color: #c62828;
    border-radius: 8px;
    margin-bottom: 20px;
    font-size: 14px;
    border-left: 4px solid #e74c3c;
    display: flex;
    align-items: center;
    gap: 8px;
}

.form-error .dashicons {
    font-size: 20px;
    width: 20px;
    height: 20px;
    flex-shrink: 0;
}

/* Buttons */
.tarot-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    padding: 14px 28px;
    border: none;
    border-radius: 8px;
    font-size: 16px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s;
    text-decoration: none;
}

.tarot-btn-primary {
    background: linear-gradient(135deg, #8e44ad 0%, #9b59b6 100%);
    color: #fff;
    box-shadow: 0 4px 15px rgba(142, 68, 173, 0.3);
}

.tarot-btn-primary:hover:not(:disabled) {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(142, 68, 173, 0.4);
}

.tarot-btn-primary:disabled {
    opacity: 0.7;
    cursor: not-allowed;
}

.tarot-btn-large {
    width: 100%;
    padding: 16px 28px;
    font-size: 17px;
}

.tarot-btn.success {
    background: linear-gradient(135deg, #27ae60 0%, #2ecc71 100%);
}

.tarot-btn .dashicons {
    font-size: 20px;
    width: 20px;
    height: 20px;
}

.dashicons.spin {
    animation: spin 1s linear infinite;
}

@keyframes spin {
    from { transform: rotate(0deg); }
    to { transform: rotate(360deg); }
}

/* Form Footer */
.form-footer {
    text-align: center;
    margin-top: 20px;
    font-size: 14px;
    color: #666;
}

.form-footer a {
    color: #8e44ad;
    text-decoration: none;
    font-weight: 600;
}

.form-footer a:hover {
    text-decoration: underline;
}

/* Responsive */
@media (max-width: 600px) {
    .modal-header {
        padding: 30px 20px 20px;
    }
    
    .modal-header h2 {
        font-size: 24px;
    }
    
    .tarot-register-form,
    .tarot-login-form {
        padding: 30px 20px;
    }
    
    .tarot-modal-content {
        width: 95%;
    }
}
