/* Multi-Step Modal Styles */
.modal-overlay {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.8);
    z-index: 1000;
    overflow-y: auto;
    padding: 20px;
    box-sizing: border-box;
}

.modal-overlay.active {
    display: flex;
    align-items: center;
    justify-content: center;
}

.modal-dialog {
    background: white;
    border-radius: 12px;
    max-width: 600px;
    width: 100%;
    max-height: 90vh;
    overflow-y: auto;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.3);
    animation: modalSlideIn 0.3s ease-out;
}

@keyframes modalSlideIn {
    from {
        opacity: 0;
        transform: translateY(-50px) scale(0.95);
    }
    to {
        opacity: 1;
        transform: translateY(0) scale(1);
    }
}

/* Modal Header */
.modal-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 30px 30px 20px;
    border-bottom: 1px solid var(--color-neutral-200);
}

.modal-header .logo-section {
    display: flex;
    align-items: center;
}

.modal-header .logo-section .logo {
    height: 30px;
    width: auto;
}

.modal-header .logo-section span {
    font-size: 1.25rem;
    font-weight: 600;
    margin-left: 8px;
    color: var(--color-dark);
}

.modal-close {
    background: none;
    border: none;
    font-size: 28px;
    color: var(--color-gray);
    cursor: pointer;
    padding: 0;
    width: 32px;
    height: 32px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    transition: all 0.2s ease;
}

.modal-close:hover {
    background: var(--color-gray-light);
    color: var(--color-dark);
}

/* Modal Body */
.modal-body {
    padding: 20px 30px 30px;
}

/* Progress Indicator */
.progress-indicator {
    display: flex;
    justify-content: space-between;
    margin-bottom: 40px;
    position: relative;
}

.progress-indicator::before {
    content: '';
    position: absolute;
    top: 20px;
    left: 20px;
    right: 20px;
    height: 2px;
    background: var(--color-neutral-200);
    z-index: 1;
}

.step {
    display: flex;
    flex-direction: column;
    align-items: center;
    position: relative;
    z-index: 2;
    flex: 1;
}

.step-number {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background: var(--color-neutral-200);
    color: var(--color-gray);
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 600;
    font-size: 14px;
    margin-bottom: 8px;
    transition: all 0.3s ease;
}

.step-label {
    font-size: 12px;
    color: var(--color-gray);
    text-align: center;
    font-weight: 500;
    transition: color 0.3s ease;
}

.step.active .step-number {
    background: var(--logo-color);
    color: white;
}

.step.active .step-label {
    color: var(--logo-color);
}

.step.completed .step-number {
    background: var(--color-success);
    color: white;
}

.step.completed .step-label {
    color: var(--color-success);
}

/* Form Steps */
.form-step {
    display: none;
    animation: fadeIn 0.3s ease-in;
}

.form-step.active {
    display: block;
}

@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateX(20px);
    }
    to {
        opacity: 1;
        transform: translateX(0);
    }
}

.form-step h3 {
    color: var(--color-dark);
    font-size: 1.5rem;
    font-weight: 600;
    margin-bottom: 8px;
}

.form-step p {
    color: var(--color-gray);
    margin-bottom: 30px;
    line-height: 1.5;
}

/* Form Groups */
.form-group {
    margin-bottom: 24px;
}

.form-group label {
    display: block;
    margin-bottom: 8px;
    color: var(--color-dark);
    font-weight: 500;
    font-size: 14px;
}

.form-control {
    width: 100%;
    padding: 12px 16px;
    border: 2px solid var(--color-neutral-200);
    border-radius: 8px;
    font-size: 14px;
    color: var(--color-dark);
    background: white;
    transition: all 0.2s ease;
    box-sizing: border-box;
}

.form-control:focus {
    outline: none;
    border-color: var(--logo-color);
    box-shadow: 0 0 0 3px rgba(53, 125, 249, 0.1);
}

.form-control::placeholder {
    color: var(--color-gray);
}

select.form-control {
    cursor: pointer;
}

textarea.form-control {
    resize: vertical;
    min-height: 100px;
    font-family: inherit;
}

.form-help {
    display: block;
    margin-top: 4px;
    font-size: 12px;
    color: var(--color-gray);
}

/* Form Navigation */
.form-navigation {
    display: flex;
    justify-content: space-between;
    gap: 16px;
    margin-top: 40px;
    padding-top: 20px;
    border-top: 1px solid var(--color-neutral-200);
}

.btn-primary,
.btn-secondary {
    padding: 12px 24px;
    border-radius: 8px;
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s ease;
    border: none;
    min-width: 100px;
}

.btn-primary {
    background: var(--logo-color);
    color: white;
}

.btn-primary:hover {
    background: var(--color-azure-dark);
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(53, 125, 249, 0.3);
}

.btn-secondary {
    background: white;
    color: var(--color-gray);
    border: 2px solid var(--color-neutral-200);
}

.btn-secondary:hover {
    background: var(--color-gray-light);
    border-color: var(--color-gray);
    color: var(--color-dark);
}

/* Responsive Design */
@media (max-width: 768px) {
    .modal-overlay {
        padding: 10px;
    }
    
    .modal-dialog {
        margin: 0;
    }
    
    .modal-header,
    .modal-body {
        padding-left: 20px;
        padding-right: 20px;
    }
    
    .progress-indicator {
        margin-bottom: 30px;
    }
    
    .step-label {
        font-size: 11px;
    }
    
    .step-number {
        width: 32px;
        height: 32px;
        font-size: 12px;
    }
    
    .form-navigation {
        flex-direction: column-reverse;
    }
    
    .btn-primary,
    .btn-secondary {
        width: 100%;
    }
}

@media (max-width: 480px) {
    .modal-header .logo-section span {
        font-size: 1.1rem;
    }
    
    .form-step h3 {
        font-size: 1.25rem;
    }
    
    .progress-indicator {
        margin-bottom: 20px;
    }
}

/* Loading State */
.form-step.loading .form-control {
    opacity: 0.6;
    pointer-events: none;
}

.btn-primary.loading {
    position: relative;
    color: transparent;
}

.btn-primary.loading::after {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 16px;
    height: 16px;
    margin: -8px 0 0 -8px;
    border: 2px solid white;
    border-top-color: transparent;
    border-radius: 50%;
    animation: spin 0.8s linear infinite;
}

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