/* Quantum Finance - Client Wizard Animations & Enhanced Styling */

/* Fade In Animation */
@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.animate-fadeIn {
    animation: fadeIn 0.4s ease-out;
}

/* Pulse Animation for Active Step */
@keyframes pulse {
    0%, 100% {
        transform: scale(1);
    }
    50% {
        transform: scale(1.05);
    }
}

.animate-pulse {
    animation: pulse 2s infinite;
}

/* Slide In from Right */
@keyframes slideInRight {
    from {
        opacity: 0;
        transform: translateX(20px);
    }
    to {
        opacity: 1;
        transform: translateX(0);
    }
}

/* Form Group Enhancements */
.form-group {
    position: relative;
}

.form-group input:focus + label,
.form-group select:focus + label,
.form-group textarea:focus + label {
    color: #6366f1;
}

/* Input Field Focus Effects */
.form-group input:focus,
.form-group select:focus,
.form-group textarea:focus {
    transform: translateY(-2px);
    box-shadow: 0 8px 16px rgba(99, 102, 241, 0.1);
}

/* Smooth Transitions */
input, select, textarea, button {
    transition: all 0.3s ease;
}

/* Custom Checkbox and Radio Styles */
input[type="checkbox"],
input[type="radio"] {
    width: 1.25rem;
    height: 1.25rem;
    cursor: pointer;
}

input[type="checkbox"]:checked,
input[type="radio"]:checked {
    background-color: #6366f1;
    border-color: #6366f1;
}

/* Step Content Animation */
#wizardStepContent > form {
    animation: fadeIn 0.4s ease-out;
}

/* Button Hover Effects */
button:hover {
    transform: translateY(-1px);
}

button:active {
    transform: translateY(0);
}

/* Card Hover Effects */
.bg-white:hover {
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.08);
}

/* Gradient Text Animation */
@keyframes gradientShift {
    0% {
        background-position: 0% 50%;
    }
    50% {
        background-position: 100% 50%;
    }
    100% {
        background-position: 0% 50%;
    }
}

.gradient-text {
    background: linear-gradient(270deg, #6366f1, #a855f7, #ec4899);
    background-size: 300% 300%;
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    animation: gradientShift 5s ease infinite;
}

/* Floating Label Effect */
.floating-label {
    position: absolute;
    left: 1rem;
    top: 0.75rem;
    transition: all 0.3s ease;
    pointer-events: none;
    color: #9ca3af;
}

.form-group input:focus ~ .floating-label,
.form-group input:not(:placeholder-shown) ~ .floating-label {
    top: -0.5rem;
    left: 0.75rem;
    font-size: 0.75rem;
    color: #6366f1;
    background: white;
    padding: 0 0.25rem;
}

/* Progress Bar Animation */
@keyframes progressFill {
    from {
        width: 0%;
    }
    to {
        width: 100%;
    }
}

/* Tooltip Styles */
.tooltip {
    position: relative;
}

.tooltip:hover::after {
    content: attr(data-tooltip);
    position: absolute;
    bottom: 100%;
    left: 50%;
    transform: translateX(-50%);
    background: #1f2937;
    color: white;
    padding: 0.5rem 0.75rem;
    border-radius: 0.5rem;
    font-size: 0.75rem;
    white-space: nowrap;
    z-index: 1000;
    margin-bottom: 0.5rem;
}

/* Icon Rotation on Hover */
.icon-rotate:hover i {
    transform: rotate(360deg);
    transition: transform 0.6s ease;
}

/* Shake Animation for Errors */
@keyframes shake {
    0%, 100% { transform: translateX(0); }
    10%, 30%, 50%, 70%, 90% { transform: translateX(-5px); }
    20%, 40%, 60%, 80% { transform: translateX(5px); }
}

.shake {
    animation: shake 0.5s;
}

/* Glow Effect */
.glow {
    box-shadow: 0 0 20px rgba(99, 102, 241, 0.5);
}

/* Loading Spinner */
@keyframes spin {
    to { transform: rotate(360deg); }
}

.spinner {
    border: 3px solid rgba(99, 102, 241, 0.1);
    border-top-color: #6366f1;
    border-radius: 50%;
    width: 2rem;
    height: 2rem;
    animation: spin 0.8s linear infinite;
}

/* Success Checkmark Animation */
@keyframes checkmark {
    0% {
        stroke-dashoffset: 100;
    }
    100% {
        stroke-dashoffset: 0;
    }
}

.checkmark-circle {
    stroke-dasharray: 166;
    stroke-dashoffset: 166;
    animation: checkmark 0.6s ease-out forwards;
}

/* Responsive Text Sizing */
@media (max-width: 768px) {
    .modal-content {
        max-height: 95vh;
    }
    
    h4 {
        font-size: 1.5rem;
    }
    
    .grid.md\:grid-cols-2 {
        grid-template-columns: 1fr;
    }
}

/* Custom Scrollbar */
.overflow-y-auto::-webkit-scrollbar {
    width: 8px;
}

.overflow-y-auto::-webkit-scrollbar-track {
    background: #f1f5f9;
    border-radius: 10px;
}

.overflow-y-auto::-webkit-scrollbar-thumb {
    background: linear-gradient(180deg, #6366f1, #a855f7);
    border-radius: 10px;
}

.overflow-y-auto::-webkit-scrollbar-thumb:hover {
    background: linear-gradient(180deg, #4f46e5, #9333ea);
}

/* Glassmorphism Effect */
.glass {
    background: rgba(255, 255, 255, 0.1);
    backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.2);
}

/* Shine Effect on Hover */
@keyframes shine {
    to {
        background-position: 200% center;
    }
}

.shine-on-hover {
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.3), transparent);
    background-size: 200% 100%;
    background-position: -200% center;
}

.shine-on-hover:hover {
    animation: shine 1.5s ease;
}

/* Number Input Styling */
input[type="number"]::-webkit-inner-spin-button,
input[type="number"]::-webkit-outer-spin-button {
    opacity: 1;
    height: 2rem;
}

/* Select Dropdown Arrow */
select {
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' fill='none' viewBox='0 0 20 20'%3E%3Cpath stroke='%236b7280' stroke-linecap='round' stroke-linejoin='round' stroke-width='1.5' d='M6 8l4 4 4-4'/%3E%3C/svg%3E");
    background-position: right 0.5rem center;
    background-repeat: no-repeat;
    background-size: 1.5em 1.5em;
    padding-right: 2.5rem;
}

/* Focus Ring Custom Color */
*:focus {
    outline: none;
}

*:focus-visible {
    outline: 2px solid #6366f1;
    outline-offset: 2px;
}

/* Badge Styles */
.badge {
    display: inline-flex;
    align-items: center;
    padding: 0.25rem 0.75rem;
    border-radius: 9999px;
    font-size: 0.75rem;
    font-weight: 600;
}

.badge-success {
    background: #dcfce7;
    color: #166534;
}

.badge-warning {
    background: #fef3c7;
    color: #92400e;
}

.badge-info {
    background: #dbeafe;
    color: #1e40af;
}

/* Step Transition Effect */
.step-transition-enter {
    opacity: 0;
    transform: translateX(20px);
}

.step-transition-active {
    opacity: 1;
    transform: translateX(0);
    transition: all 0.3s ease;
}

.step-transition-exit {
    opacity: 1;
}

.step-transition-exit-active {
    opacity: 0;
    transform: translateX(-20px);
    transition: all 0.3s ease;
}
