/* ===================================
   WIZARD FORM STYLES
   Multi-Step Form with Sidebar Navigation
   =================================== */

/* Wizard Container */
.wizard-container {
    display: flex;
    gap: 2rem;
    max-width: 7xl;
    margin: 0 auto;
}

/* Sidebar Navigation */
.wizard-sidebar {
    width: 280px;
    flex-shrink: 0;
    position: sticky;
    top: 100px;
    align-self: flex-start;
    background: #ffffff;
    border-radius: 12px;
    padding: 1.5rem;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
    height: fit-content;
}

.wizard-sidebar-title {
    font-size: 1.125rem;
    font-weight: 600;
    color: #1f2937;
    margin-bottom: 1.5rem;
    padding-bottom: 0.75rem;
    border-bottom: 2px solid #e5e7eb;
}

.wizard-steps {
    list-style: none;
    padding: 0;
    margin: 0;
}

.wizard-step-item {
    position: relative;
    padding-left: 3rem;
    padding-bottom: 2rem;
    cursor: pointer;
    transition: all 0.2s ease;
}

.wizard-step-item:last-child {
    padding-bottom: 0;
}

.wizard-step-item:not(.completed):not(.active) {
    opacity: 0.6;
    cursor: not-allowed;
}

.wizard-step-item.completed {
    cursor: pointer;
}

.wizard-step-item.completed:hover .wizard-step-number {
    transform: scale(1.1);
}

/* Step Number Circle */
.wizard-step-number {
    position: absolute;
    left: 0;
    top: 0;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 600;
    font-size: 1rem;
    transition: all 0.3s ease;
    z-index: 2;
}

/* Pending State */
.wizard-step-item:not(.completed):not(.active) .wizard-step-number {
    background: #e5e7eb;
    color: #9ca3af;
    border: 2px solid #d1d5db;
}

/* Active State */
.wizard-step-item.active .wizard-step-number {
    background: linear-gradient(135deg, #3b82f6 0%, #2563eb 100%);
    color: #ffffff;
    border: 2px solid #3b82f6;
    box-shadow: 0 4px 12px rgba(59, 130, 246, 0.4);
}

/* Completed State */
.wizard-step-item.completed .wizard-step-number {
    background: linear-gradient(135deg, #10b981 0%, #059669 100%);
    color: #ffffff;
    border: 2px solid #10b981;
}

/* Connector Line */
.wizard-step-item::before {
    content: '';
    position: absolute;
    left: 19px;
    top: 45px;
    bottom: 0;
    width: 2px;
    background: #e5e7eb;
    z-index: 1;
}

.wizard-step-item.completed::before {
    background: #10b981;
}

.wizard-step-item.active::before {
    background: linear-gradient(to bottom, #3b82f6 0%, #e5e7eb 100%);
}

.wizard-step-item:last-child::before {
    display: none;
}

/* Step Content */
.wizard-step-content {
    display: flex;
    flex-direction: column;
    justify-content: center;
    min-height: 40px;
}

.wizard-step-title {
    font-weight: 600;
    font-size: 0.9375rem;
    color: #374151;
    margin-bottom: 0.25rem;
    line-height: 1.4;
}

.wizard-step-item.active .wizard-step-title {
    color: #1f2937;
}

.wizard-step-subtitle {
    font-size: 0.75rem;
    color: #6b7280;
    line-height: 1.3;
}

/* Wizard Content Area */
.wizard-content {
    flex: 1;
    min-width: 0;
}

.wizard-content-inner {
    background: #ffffff;
    border-radius: 12px;
    padding: 2rem;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
}

/* Step Containers */
.wizard-form-step {
    display: none;
}

.wizard-form-step.active {
    display: block;
    animation: fadeIn 0.3s ease-in-out;
}

@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(10px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Step Header */
.wizard-step-header {
    margin-bottom: 1.5rem;
    padding-bottom: 1rem;
    border-bottom: 2px solid #e5e7eb;
}

.wizard-step-header h2 {
    font-size: 1.5rem;
    font-weight: 700;
    color: #1f2937;
    margin-bottom: 0.5rem;
}

.wizard-step-header p {
    color: #6b7280;
    font-size: 0.875rem;
}

/* Navigation Buttons */
.wizard-navigation {
    display: flex;
    justify-content: space-between;
    gap: 1rem;
    /* margin-top and padding-top now handled by Tailwind classes (mt-8 pt-6) */
    /* border-top now handled by Tailwind class (border-t) */
}

.wizard-nav-group {
    display: flex;
    gap: 0.75rem;
}

.wizard-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    padding: 0.5rem 1.25rem;
    border-radius: 0.5rem;
    font-weight: 600;
    font-size: 0.875rem;
    transition: all 0.2s ease;
    border: none;
    cursor: pointer;
}

.wizard-btn:disabled {
    opacity: 0.5;
    cursor: not-allowed;
}

.wizard-btn-secondary {
    background: #f3f4f6;
    color: #374151;
    border: 1px solid #d1d5db;
}

.wizard-btn-secondary:hover:not(:disabled) {
    background: #e5e7eb;
    border-color: #9ca3af;
}

.wizard-btn-primary {
    background: linear-gradient(135deg, #059669 0%, #047857 100%);
    color: #ffffff;
    box-shadow: 0 2px 4px rgba(5, 150, 105, 0.3);
}

.wizard-btn-primary:hover:not(:disabled) {
    box-shadow: 0 4px 8px rgba(5, 150, 105, 0.4);
    transform: translateY(-1px);
}

.wizard-btn-link {
    background: transparent;
    color: #059669;
    padding: 0.5rem 1rem;
    text-decoration: underline;
    text-underline-offset: 2px;
}

.wizard-btn-link:hover {
    color: #047857;
}

/* Review Section (Step 7) */
.wizard-review-section {
    background: #f9fafb;
    border: 1px solid #e5e7eb;
    border-radius: 0.75rem;
    padding: 1.5rem;
    margin-bottom: 1.5rem;
}

.wizard-review-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 1rem;
    padding-bottom: 0.75rem;
    border-bottom: 1px solid #e5e7eb;
}

.wizard-review-title {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-weight: 600;
    font-size: 1rem;
    color: #1f2937;
}

.wizard-review-title i {
    color: #10b981;
    font-size: 1.125rem;
}

.wizard-review-edit-btn {
    display: inline-flex;
    align-items: center;
    gap: 0.375rem;
    padding: 0.375rem 0.875rem;
    background: #ffffff;
    border: 1px solid #d1d5db;
    border-radius: 0.375rem;
    color: #374151;
    font-size: 0.8125rem;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.2s ease;
}

.wizard-review-edit-btn:hover {
    background: #f3f4f6;
    border-color: #9ca3af;
}

.wizard-review-content {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 0.75rem;
}

.wizard-review-item {
    display: flex;
    flex-direction: column;
}

.wizard-review-label {
    font-size: 0.75rem;
    font-weight: 500;
    color: #6b7280;
    margin-bottom: 0.25rem;
    text-transform: uppercase;
    letter-spacing: 0.025em;
}

.wizard-review-value {
    font-size: 0.9375rem;
    color: #1f2937;
    font-weight: 500;
}

/* Confirmation Checkbox */
.wizard-confirmation {
    background: #fef3c7;
    border: 2px solid #fbbf24;
    border-radius: 0.75rem;
    padding: 1.5rem;
    margin-bottom: 1.5rem;
}

.wizard-confirmation-title {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-weight: 600;
    font-size: 1rem;
    color: #92400e;
    margin-bottom: 1rem;
}

.wizard-confirmation-title i {
    font-size: 1.25rem;
}

.wizard-confirmation-text {
    color: #78350f;
    font-size: 0.9375rem;
    line-height: 1.6;
    margin-bottom: 1rem;
}

.wizard-confirmation-checkbox {
    display: flex;
    align-items: start;
    gap: 0.75rem;
    cursor: pointer;
}

.wizard-confirmation-checkbox input[type="checkbox"] {
    width: 20px;
    height: 20px;
    margin-top: 0.125rem;
    cursor: pointer;
    accent-color: #059669;
}

.wizard-confirmation-checkbox label {
    flex: 1;
    font-size: 0.9375rem;
    font-weight: 500;
    color: #78350f;
    cursor: pointer;
    user-select: none;
}

/* Turnstile Container in Step 7 */
.wizard-turnstile-container {
    background: #f0fdf4;
    border: 1px solid #10b981;
    border-radius: 0.75rem;
    padding: 1.5rem;
    margin-bottom: 1.5rem;
}

.wizard-turnstile-title {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-weight: 600;
    font-size: 1rem;
    color: #065f46;
    margin-bottom: 1rem;
}

.wizard-turnstile-title i {
    font-size: 1.25rem;
}

/* Mobile Responsive */
@media (max-width: 1024px) {
    .wizard-sidebar {
        width: 240px;
    }
}

@media (max-width: 767px) {
    .wizard-container {
        flex-direction: column;
        gap: 1rem;
    }

    .wizard-sidebar {
        width: 100%;
        position: relative;
        top: 0;
        padding: 1rem;
    }

    .wizard-sidebar-title {
        font-size: 1rem;
        margin-bottom: 1rem;
    }

    /* Horizontal Progress Bar on Mobile */
    .wizard-steps {
        display: flex;
        justify-content: space-between;
        overflow-x: auto;
        padding-bottom: 0.5rem;
        /* Hide scrollbar */
        scrollbar-width: none;
        /* Firefox */
        -ms-overflow-style: none;
        /* IE/Edge */
    }

    .wizard-steps::-webkit-scrollbar {
        display: none;
        /* Chrome/Safari/Opera */
    }

    .wizard-step-item {
        flex: 0 0 auto;
        padding: 0;
        padding-bottom: 0 !important;
        min-width: 50px;
        text-align: center;
    }

    .wizard-step-item::before {
        display: none;
    }

    .wizard-step-number {
        position: relative;
        left: auto;
        top: auto;
        margin: 0 auto 0.5rem;
        width: 36px;
        height: 36px;
        font-size: 0.875rem;
    }

    .wizard-step-content {
        min-height: auto;
    }

    .wizard-step-title {
        display: none;
        /* Hide text on mobile, show only numbers */
    }

    .wizard-step-subtitle {
        display: none;
    }

    .wizard-content-inner {
        padding: 1.5rem 1rem;
    }

    .wizard-step-header h2 {
        font-size: 1.25rem;
    }

    .wizard-step-header p {
        display: none;
        /* Hide description text on mobile */
    }

    .wizard-navigation {
        flex-direction: row;
        flex-wrap: nowrap;
        gap: 0.5rem;
        justify-content: space-between;
    }

    .wizard-nav-group {
        flex-direction: row;
        flex: 0 1 auto;
        gap: 0.5rem;
    }

    .wizard-nav-group:first-child {
        justify-content: flex-start;
    }

    .wizard-nav-group:last-child {
        justify-content: flex-end;
    }

    .wizard-btn {
        flex: 0 0 auto;
        min-width: auto;
        padding: 0.5rem 1rem !important;
        font-size: 0.8125rem;
        white-space: nowrap;
    }

    .wizard-btn span {
        display: inline;
    }

    .wizard-btn i {
        font-size: 0.875rem;
    }

    .wizard-review-content {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 480px) {
    .wizard-step-number {
        width: 32px;
        height: 32px;
        font-size: 0.75rem;
    }

    .wizard-step-title {
        font-size: 0.625rem;
    }
}

/* Print Styles */
@media print {

    .wizard-sidebar,
    .wizard-navigation {
        display: none !important;
    }

    .wizard-form-step {
        display: block !important;
    }

    .wizard-content-inner {
        box-shadow: none;
    }
}