/* tour.css - Enhanced with Validation Styles */
.tour-highlight {
    position: relative;
    z-index: 9999;
    transition: box-shadow 0.3s ease;
    border-radius: 4px;
}

#tour-popup {
    animation: tour-popup-fade 0.5s ease-out;
    will-change: transform, opacity;
}

#tour-overlay {
    animation: tour-overlay-fade 0.3s ease-out;
}

/* Welcome Modal Animations */
@keyframes modalFadeIn {
    from {
        opacity: 0;
    }
    to {
        opacity: 1;
    }
}

@keyframes modalFadeOut {
    from {
        opacity: 1;
    }
    to {
        opacity: 0;
    }
}

@keyframes modalSlideUp {
    from {
        opacity: 0;
        transform: translateY(30px) scale(0.95);
    }
    to {
        opacity: 1;
        transform: translateY(0) scale(1);
    }
}

@keyframes tour-popup-fade {
    from {
        opacity: 0;
        transform: translateY(20px) scale(0.95);
    }
    to {
        opacity: 1;
        transform: translateY(0) scale(1);
    }
}

@keyframes tour-overlay-fade {
    from { opacity: 0; }
    to { opacity: 1; }
}

/* Validation States */
#userNameInput.valid {
    border-color: #10b981 !important;
    background: #f0fdf4 !important;
}

#userNameInput.invalid {
    border-color: #ef4444 !important;
    background: #fef2f2 !important;
}

#userNameInput:focus {
    outline: none;
    border-color: #4a6ee0 !important;
    box-shadow: 0 0 0 3px rgba(74, 110, 224, 0.1);
}

/* Button States */
#submitNameBtn:enabled {
    background: #4a6ee0 !important;
    opacity: 1 !important;
    cursor: pointer !important;
}

#submitNameBtn:enabled:hover {
    background: #3a5ec0 !important;
    transform: translateY(-1px);
}

#submitNameBtn:disabled {
    background: #9ca3af !important;
    opacity: 0.6 !important;
    cursor: not-allowed !important;
    transform: none !important;
}

#skipNameBtn:hover {
    background: #f1f5f9 !important;
    transform: translateY(-1px);
}

/* Error Message Animation */
#nameError {
    animation: shake 0.5s ease-in-out;
}

@keyframes shake {
    0%, 100% { transform: translateX(0); }
    25% { transform: translateX(-5px); }
    75% { transform: translateX(5px); }
}

/* Character Count Styles */
#charCount.warning {
    color: #f59e0b !important;
    font-weight: bold;
}

#charCount.error {
    color: #ef4444 !important;
    font-weight: bold;
}

/* Tips Box */
#nameTips {
    transition: all 0.3s ease;
}

/* Responsive Design */
@media (max-width: 768px) {
    #tour-popup {
        max-width: 280px !important;
        min-width: 250px !important;
        left: 50% !important;
        transform: translateX(-50%) !important;
        top: 20px !important;
        margin: 0 10px;
    }
    
    #tour-arrow {
        display: none !important;
    }
    
    #welcome-modal > div {
        margin: 20px;
        padding: 24px !important;
    }
    
    #nameTips {
        font-size: 11px !important;
    }
}

@media (max-width: 480px) {
    #tour-popup {
        max-width: 90% !important;
        min-width: auto !important;
    }
    
    #welcome-modal > div {
        padding: 20px !important;
    }
    
    #nameTips div {
        margin-bottom: 1px !important;
    }
}