/* ==========================================================================
   WIZARD LAYOUT V2.0 - Enterprise 2-Panel Design
   ========================================================================== */

/* Layout Container */
.wizard-layout {
    display: flex;
    flex-direction: column;
    height: calc(100vh - 60px);
    max-height: calc(100vh - 60px);
    overflow: hidden;
    background: var(--bg-primary, #FFFFFF);
}

/* Header Sticky */
.wizard-header {
    position: sticky;
    top: 0;
    z-index: 100;
    background: var(--bg-primary, #FFFFFF);
    border-bottom: 1px solid var(--border-light, #E5E7EB);
    padding: 16px 24px;
    flex-shrink: 0;
}

.wizard-header-content {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 24px;
}

.wizard-header-title {
    flex-shrink: 0;
}

.wizard-header-title h1 {
    margin: 0;
    font-size: 20px;
    font-weight: 600;
    color: var(--text-primary, #1F2937);
    letter-spacing: -0.02em;
}

.wizard-header-title p {
    margin: 4px 0 0 0;
    font-size: 13px;
    color: var(--text-tertiary, #9CA3AF);
}

/* Compact Stepper */
.compact-stepper {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 8px 16px;
    background: var(--bg-secondary, #F9FAFB);
    border-radius: 12px;
}

.stepper-step {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 8px 12px;
    border-radius: 8px;
    font-size: 13px;
    font-weight: 500;
    color: var(--text-tertiary, #9CA3AF);
    transition: all 0.2s ease;
    cursor: default;
}

.stepper-step.completed {
    color: var(--success, #22C55E);
}

.stepper-step.active {
    background: rgba(109, 74, 255, 0.10);
    color: var(--accent, #6366F1);
}

.stepper-step.future {
    color: var(--text-tertiary, #9CA3AF);
}

.stepper-number {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 24px;
    height: 24px;
    border-radius: 50%;
    font-size: 12px;
    font-weight: 600;
    background: var(--bg-tertiary, #E5E7EB);
    color: var(--text-tertiary, #9CA3AF);
}

.stepper-step.completed .stepper-number {
    background: var(--success, #22C55E);
    color: white;
}

.stepper-step.active .stepper-number {
    background: var(--accent, #6366F1);
    color: white;
}

.stepper-check {
    width: 14px;
    height: 14px;
}

.stepper-divider {
    width: 24px;
    height: 2px;
    background: var(--border-light, #E5E7EB);
    border-radius: 1px;
}

.stepper-divider.completed {
    background: var(--success, #22C55E);
}

/* Body Grid - 2 Columns */
.wizard-body {
    display: grid;
    grid-template-columns: minmax(0, 1fr) 320px; /* minmax prevents left column collapse */
    gap: 0;
    flex: 1 1 auto;
    overflow: hidden;
    min-height: 0; /* Allow flexbox to shrink properly */
}

/* Main Content Panel (scroll) */
.wizard-main {
    min-width: 0; /* Critical: prevents grid blowout in flex/grid children */
    overflow-y: auto;
    overflow-x: hidden;
    padding: 24px;
    background: var(--bg-secondary, #F9FAFB);
}

.wizard-main::-webkit-scrollbar {
    width: 6px;
}

.wizard-main::-webkit-scrollbar-track {
    background: transparent;
}

.wizard-main::-webkit-scrollbar-thumb {
    background: var(--border-light, #E5E7EB);
    border-radius: 3px;
}

.wizard-main::-webkit-scrollbar-thumb:hover {
    background: var(--text-tertiary, #9CA3AF);
}

/* Summary Sidebar (sticky) */
.wizard-sidebar {
    position: sticky;
    top: 0;
    height: 100%;
    overflow-y: auto;
    background: var(--bg-primary, #FFFFFF);
    border-left: 1px solid var(--border-light, #E5E7EB);
    padding: 24px;
    display: flex;
    flex-direction: column;
}

.wizard-sidebar-header {
    margin-bottom: 20px;
}

.wizard-sidebar-header h3 {
    margin: 0;
    font-size: 14px;
    font-weight: 600;
    color: var(--text-primary, #1F2937);
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

/* Summary Items */
.summary-item {
    display: flex;
    align-items: flex-start;
    gap: 12px;
    padding: 12px 0;
    border-bottom: 1px solid var(--border-light, #E5E7EB);
}

.summary-item:last-child {
    border-bottom: none;
}

.summary-icon {
    flex-shrink: 0;
    width: 32px;
    height: 32px;
    border-radius: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.summary-icon.file {
    background: rgba(109, 74, 255, 0.10);
    color: var(--ui-accent, #6D4AFF);
}

.summary-icon.project {
    background: rgba(109, 74, 255, 0.10);
    color: var(--ui-accent, #6D4AFF);
}

.summary-icon.brands {
    background: rgba(52, 211, 153, 0.12);
    color: #34D399;
}

.summary-icon.competitors {
    background: rgba(242, 182, 90, 0.12);
    color: #F2B65A;
}

.summary-content {
    flex: 1;
    min-width: 0;
}

.summary-label {
    font-size: 11px;
    font-weight: 500;
    color: var(--text-tertiary, #9CA3AF);
    text-transform: uppercase;
    letter-spacing: 0.05em;
    margin-bottom: 4px;
}

.summary-value {
    font-size: 13px;
    font-weight: 500;
    color: var(--text-primary, #1F2937);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.summary-value.empty {
    color: var(--text-tertiary, #9CA3AF);
    font-style: italic;
}

/* Status Checks */
.summary-checks {
    margin-top: 20px;
    padding-top: 16px;
    border-top: 1px solid var(--border-light, #E5E7EB);
}

.summary-check {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 8px 0;
    font-size: 13px;
}

.summary-check-icon {
    width: 20px;
    height: 20px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

.summary-check-icon.ok {
    background: rgba(52, 211, 153, 0.12);
    color: #34D399;
}

.summary-check-icon.pending {
    background: rgba(255, 255, 255, 0.08);
    color: var(--ui-muted-2, rgba(255,255,255,.45));
}

.summary-check-text {
    color: var(--text-secondary, #6B7280);
}

.summary-check-text.ok {
    color: var(--text-primary, #1F2937);
}

/* Sidebar CTA */
.sidebar-cta {
    margin-top: auto;
    padding-top: 20px;
}

/* Footer Sticky */
.wizard-footer {
    position: sticky;
    bottom: 0;
    z-index: 100;
    background: var(--bg-primary, #FFFFFF);
    border-top: 1px solid var(--border-light, #E5E7EB);
    padding: 16px 24px;
    flex-shrink: 0;
}

.wizard-footer-content {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
}

.wizard-footer-left {
    display: flex;
    align-items: center;
    gap: 12px;
}

.wizard-footer-right {
    display: flex;
    align-items: center;
    gap: 12px;
}

.wizard-footer-status {
    font-size: 13px;
    color: var(--text-tertiary, #9CA3AF);
}

.wizard-footer-status.ready {
    color: var(--success, #22C55E);
}

.wizard-footer-status.warning {
    color: var(--warning, #F59E0B);
}

/* Footer Buttons */
.btn-wizard {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 10px 20px;
    border-radius: 10px;
    font-size: 14px;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.2s ease;
    border: none;
}

.btn-wizard-secondary {
    background: var(--bg-secondary, #F9FAFB);
    color: var(--text-secondary, #6B7280);
    border: 1px solid var(--border-light, #E5E7EB);
}

.btn-wizard-secondary:hover:not(:disabled) {
    background: var(--bg-tertiary, #F3F4F6);
    color: var(--text-primary, #1F2937);
}

.btn-wizard-primary {
    background: var(--accent, #6366F1);
    color: white;
    box-shadow: 0 2px 8px rgba(109, 74, 255, 0.35);
}

.btn-wizard-primary:hover:not(:disabled) {
    background: #9B8CFF;
    box-shadow: 0 4px 12px rgba(109, 74, 255, 0.35);
}

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

.btn-wizard-success {
    background: linear-gradient(135deg, #34D399 0%, #10B981 100%);
    color: white;
    box-shadow: 0 2px 8px rgba(52, 211, 153, 0.25);
}

.btn-wizard-success:hover:not(:disabled) {
    box-shadow: 0 4px 12px rgba(52, 211, 153, 0.35);
}

/* ==========================================================================
   ACCORDION COMPONENT
   ========================================================================== */

.wizard-accordion {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.accordion-item {
    background: var(--bg-primary, #FFFFFF);
    border: 1px solid var(--border-light, #E5E7EB);
    border-radius: 12px;
    overflow: hidden;
    transition: all 0.2s ease;
}

.accordion-item.open {
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.04);
}

.accordion-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 16px 20px;
    cursor: pointer;
    transition: background 0.15s ease;
}

.accordion-header:hover {
    background: var(--bg-secondary, #F9FAFB);
}

.accordion-header-left {
    display: flex;
    align-items: center;
    gap: 12px;
}

.accordion-icon {
    width: 36px;
    height: 36px;
    border-radius: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

.accordion-icon.project {
    background: rgba(109, 74, 255, 0.10);
    color: var(--ui-accent, #6D4AFF);
}

.accordion-icon.columns {
    background: rgba(109, 74, 255, 0.10);
    color: var(--ui-accent, #6D4AFF);
}

.accordion-icon.advanced {
    background: rgba(255, 255, 255, 0.05);
    color: var(--ui-muted, rgba(255,255,255,.66));
}

.accordion-title {
    font-size: 14px;
    font-weight: 600;
    color: var(--text-primary, #1F2937);
}

.accordion-subtitle {
    font-size: 12px;
    color: var(--text-tertiary, #9CA3AF);
    margin-top: 2px;
}

.accordion-header-right {
    display: flex;
    align-items: center;
    gap: 12px;
}

.accordion-badge {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    padding: 4px 10px;
    border-radius: 6px;
    font-size: 11px;
    font-weight: 500;
    background: rgba(52, 211, 153, 0.12);
    color: #34D399;
    border: 1px solid rgba(52, 211, 153, 0.25);
}

.accordion-badge.info {
    background: rgba(109, 74, 255, 0.10);
    color: var(--ui-accent, #6D4AFF);
    border-color: rgba(109, 74, 255, 0.28);
}

.accordion-chevron {
    width: 20px;
    height: 20px;
    color: var(--text-tertiary, #9CA3AF);
    transition: transform 0.2s ease;
}

.accordion-item.open .accordion-chevron {
    transform: rotate(180deg);
}

.accordion-content {
    display: none;
    padding: 0 20px 20px;
    border-top: 1px solid var(--border-light, #E5E7EB);
}

.accordion-item.open .accordion-content {
    display: block;
}

/* ==========================================================================
   DROPZONE V2 - Compact & Clean
   ========================================================================== */

.dropzone-v2 {
    position: relative;
    min-height: 200px;
    max-height: 260px;
    border: 2px dashed var(--border-light, #E5E7EB);
    border-radius: 16px;
    background: var(--bg-primary, #FFFFFF);
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 32px;
    cursor: pointer;
    transition: all 0.2s ease;
}

.dropzone-v2:hover {
    border-color: var(--accent, #6366F1);
    background: rgba(109, 74, 255, 0.06);
}

.dropzone-v2.dragging {
    border-color: var(--accent, #6366F1);
    background: rgba(109, 74, 255, 0.10);
    border-style: solid;
}

.dropzone-v2.success {
    border-color: var(--success, #22C55E);
    background: rgba(52, 211, 153, 0.10);
}

.dropzone-icon {
    width: 48px;
    height: 48px;
    border-radius: 12px;
    background: var(--bg-secondary, #F9FAFB);
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 16px;
    color: var(--text-tertiary, #9CA3AF);
    transition: all 0.2s ease;
}

.dropzone-v2:hover .dropzone-icon,
.dropzone-v2.dragging .dropzone-icon {
    background: rgba(109, 74, 255, 0.10);
    color: var(--accent, #6366F1);
}

.dropzone-v2.success .dropzone-icon {
    background: rgba(52, 211, 153, 0.12);
    color: var(--success, #22C55E);
}

.dropzone-text {
    text-align: center;
}

.dropzone-text h4 {
    margin: 0 0 4px 0;
    font-size: 15px;
    font-weight: 600;
    color: var(--text-primary, #1F2937);
}

.dropzone-text p {
    margin: 0;
    font-size: 13px;
    color: var(--text-tertiary, #9CA3AF);
}

.dropzone-formats {
    margin-top: 16px;
    display: flex;
    gap: 8px;
}

.format-badge {
    padding: 4px 8px;
    border-radius: 4px;
    font-size: 11px;
    font-weight: 500;
    background: var(--bg-secondary, #F9FAFB);
    color: var(--text-tertiary, #9CA3AF);
}

/* ==========================================================================
   PREVIEW MODAL
   ========================================================================== */

.preview-modal-overlay {
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.5);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 1000;
    opacity: 0;
    visibility: hidden;
    transition: all 0.2s ease;
}

.preview-modal-overlay.open {
    opacity: 1;
    visibility: visible;
}

.preview-modal {
    background: var(--bg-primary, #FFFFFF);
    border-radius: 16px;
    width: 90%;
    max-width: 900px;
    max-height: 80vh;
    display: flex;
    flex-direction: column;
    overflow: hidden;
    transform: scale(0.95);
    transition: transform 0.2s ease;
}

.preview-modal-overlay.open .preview-modal {
    transform: scale(1);
}

.preview-modal-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 16px 20px;
    border-bottom: 1px solid var(--border-light, #E5E7EB);
    flex-shrink: 0;
}

.preview-modal-header h3 {
    margin: 0;
    font-size: 16px;
    font-weight: 600;
    color: var(--text-primary, #1F2937);
}

.preview-modal-close {
    width: 32px;
    height: 32px;
    border-radius: 8px;
    border: none;
    background: var(--bg-secondary, #F9FAFB);
    color: var(--text-tertiary, #9CA3AF);
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.15s ease;
}

.preview-modal-close:hover {
    background: var(--bg-tertiary, #F3F4F6);
    color: var(--text-primary, #1F2937);
}

.preview-modal-body {
    flex: 1;
    overflow: auto;
    padding: 0;
}

.preview-table-container {
    max-height: 400px;
    overflow: auto;
}

.preview-table {
    width: 100%;
    border-collapse: collapse;
    font-size: 13px;
}

.preview-table thead {
    position: sticky;
    top: 0;
    z-index: 10;
}

.preview-table th {
    background: var(--bg-secondary, #F9FAFB);
    padding: 12px 16px;
    text-align: left;
    font-weight: 600;
    color: var(--text-primary, #1F2937);
    border-bottom: 1px solid var(--border-light, #E5E7EB);
    white-space: nowrap;
}

.preview-table td {
    padding: 10px 16px;
    border-bottom: 1px solid var(--border-light, #E5E7EB);
    color: var(--text-secondary, #6B7280);
    max-width: 300px;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.preview-table tr:hover td {
    background: var(--bg-secondary, #F9FAFB);
}

.preview-modal-footer {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 12px 20px;
    border-top: 1px solid var(--border-light, #E5E7EB);
    background: var(--bg-secondary, #F9FAFB);
    flex-shrink: 0;
}

.preview-info {
    font-size: 13px;
    color: var(--text-tertiary, #9CA3AF);
}

/* ==========================================================================
   BADGES - Soft Style
   ========================================================================== */

.badge-soft {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    padding: 4px 10px;
    border-radius: 6px;
    font-size: 11px;
    font-weight: 500;
}

.badge-soft.optimized {
    background: rgba(52, 211, 153, 0.12);
    color: #34D399;
    border: 1px solid rgba(52, 211, 153, 0.25);
}

.badge-soft.context {
    background: rgba(109, 74, 255, 0.10);
    color: var(--ui-accent, #6D4AFF);
    border: 1px solid rgba(109, 74, 255, 0.28);
}

.badge-soft.reusable {
    background: rgba(109, 74, 255, 0.10);
    color: #9B8CFF;
    border: 1px solid rgba(109, 74, 255, 0.28);
}

/* ==========================================================================
   RESPONSIVE
   ========================================================================== */

@media (max-width: 1024px) {
    .wizard-body {
        grid-template-columns: 1fr;
    }
    
    .wizard-sidebar {
        display: none;
    }
    
    .compact-stepper {
        flex-wrap: wrap;
        justify-content: center;
    }
}

@media (max-width: 768px) {
    .wizard-header-content {
        flex-direction: column;
        align-items: flex-start;
    }
    
    .wizard-footer-content {
        flex-direction: column;
        gap: 12px;
    }
    
    .wizard-footer-left,
    .wizard-footer-right {
        width: 100%;
        justify-content: center;
    }
}

/* ==========================================================================
   WIZARD STEP VISIBILITY
   ========================================================================== */

/* Default: hide all step content (multi-step wizard) */
[data-wizard-step] {
    display: none;
    width: 100%;
    min-width: 0; /* Prevent grid/flex blowout */
}

/* When a step is active, show it and all its children */
[data-wizard-step].active {
    display: block !important;
    min-height: 400px;
    width: 100%;
    min-width: 0;
}

[data-wizard-step].active > * {
    display: block !important;
    width: 100%;
}

[data-wizard-step].active .wizard-section {
    display: block !important;
    width: 100%;
}

[data-wizard-step].active .step-card {
    display: block !important;
    visibility: visible !important;
}

/* Step card styling */
.step-card {
    background: var(--ui-surface, #141414);
    border: 1px solid var(--border-light, #E5E7EB);
    border-radius: 16px;
    padding: 24px;
    width: 100%;
    box-sizing: border-box;
}

.step-card h3 {
    margin: 0 0 16px 0;
    color: var(--text-primary, #1F2937);
    font-size: 18px;
    font-weight: 600;
}

.step-card p {
    margin: 8px 0;
    color: var(--text-secondary, #4B5563);
}

/* Step content cards */
[data-wizard-step] > .card {
    margin-bottom: 20px;
}

/* Ensure upload card is prominent */
#wizard-step-1 {
    min-height: 400px;
}

/* Step 2 styling - ensure content is visible */
#wizard-step-2 {
    min-height: 400px;
}

#wizard-step-2 .wizard-section {
    display: block !important;
}

/* Step 3 - ALWAYS show wizard-section and its children when Step 3 is active */
#wizard-step-3 .wizard-section {
    display: block !important;
    width: 100% !important;
}

#wizard-step-3 .step-card,
#wizard-step-3 #configSummaryCard {
    display: block !important;
    visibility: visible !important;
    width: 100% !important;
    padding: 24px;
    background: var(--ui-surface, #141414);
    border: 1px solid var(--ui-border, rgba(255,255,255,.08));
    border-radius: 16px;
    box-sizing: border-box;
}

/* Step 3 styling - Ensure visibility when active */
#wizard-step-3.active,
#wizard-step-3[style*="display: block"],
#wizard-step-3[style*="display:block"] {
    display: block !important;
    min-height: 400px;
    width: 100% !important;
    min-width: 0;
    /* DEBUG: subtle background to verify rendering */
    background: rgba(109, 74, 255, 0.05);
}

#wizard-step-3.active .wizard-section,
#wizard-step-3.active #wizardStep3,
#wizard-step-3[style*="display: block"] .wizard-section,
#wizard-step-3[style*="display:block"] .wizard-section {
    display: block !important;
    width: 100% !important;
}

#wizard-step-3.active .card,
#wizard-step-3.active .step-card,
#wizard-step-3.active #configSummaryCard {
    display: block !important;
    width: 100% !important;
    padding: 24px;
    background: var(--ui-surface, #141414);
    border: 1px solid var(--ui-border, rgba(255,255,255,.08));
    border-radius: 16px;
}

#wizard-step-3.active #configSummaryContent,
#wizard-step-3[style*="display: block"] #configSummaryContent {
    display: block !important;
    width: 100% !important;
    padding: 20px;
}

/* ==========================================================================
   STYLED SELECT DROPDOWN - Enterprise Design
   ========================================================================== */

/* Custom select wrapper */
.styled-select-wrapper {
    position: relative;
    width: 100%;
}

/* Main select styling */
#textColumnSelect,
.wizard-select,
.styled-select {
    appearance: none;
    -webkit-appearance: none;
    -moz-appearance: none;
    width: 100%;
    padding: 12px 40px 12px 14px;
    font-size: 14px;
    font-weight: 500;
    color: var(--text-primary, #1F2937);
    background: var(--bg-primary, #FFFFFF);
    border: 1px solid var(--border-light, #E5E7EB);
    border-radius: 8px;
    cursor: pointer;
    transition: all 0.15s ease;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='16' height='16' viewBox='0 0 24 24' fill='none' stroke='%236B7280' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpolyline points='6 9 12 15 18 9'%3E%3C/polyline%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 12px center;
    background-size: 16px;
}

#textColumnSelect:hover,
.wizard-select:hover,
.styled-select:hover {
    border-color: var(--primary, #2563EB);
    background-color: var(--bg-secondary, #F9FAFB);
}

#textColumnSelect:focus,
.wizard-select:focus,
.styled-select:focus {
    outline: none;
    border-color: var(--ui-accent, #6D4AFF);
    box-shadow: 0 0 0 3px rgba(109, 74, 255, 0.35);
}

/* Option styling */
#textColumnSelect option,
.wizard-select option,
.styled-select option {
    padding: 10px 14px;
    font-size: 14px;
    background: var(--bg-primary, #FFFFFF);
    color: var(--text-primary, #1F2937);
}

#textColumnSelect option:checked,
.wizard-select option:checked,
.styled-select option:checked {
    background: var(--ui-accent, #6D4AFF);
    color: white;
}

/* Disabled state */
#textColumnSelect:disabled,
.wizard-select:disabled,
.styled-select:disabled {
    opacity: 0.6;
    cursor: not-allowed;
    background-color: var(--bg-secondary, #F9FAFB);
}

/* Label for select */
.select-label {
    display: block;
    margin-bottom: 6px;
    font-size: 13px;
    font-weight: 500;
    color: var(--text-secondary, #6B7280);
}

/* ============================================================================
   STEP 3 EMERGENCY FIX - Force visibility regardless of .active class
   ============================================================================ */

/* When #wizard-step-3 has .active class, force ALL children to be visible */
#wizard-step-3.active {
    display: block !important;
    visibility: visible !important;
    opacity: 1 !important;
    min-height: 400px !important;
    width: 100% !important;
    position: relative !important;
}

#wizard-step-3.active * {
    visibility: visible !important;
}

#wizard-step-3.active > div,
#wizard-step-3.active > section,
#wizard-step-3.active .wizard-section,
#wizard-step-3.active .step-card,
#wizard-step-3.active #configSummaryCard,
#wizard-step-3.active #wizardStep3 {
    display: block !important;
    visibility: visible !important;
    opacity: 1 !important;
    width: 100% !important;
    min-height: auto !important;
    position: relative !important;
}

/* Force configSummaryCard to show with styling */
#wizard-step-3.active #configSummaryCard {
    display: block !important;
    visibility: visible !important;
    background: var(--ui-surface, #141414) !important;
    border: 1px solid var(--ui-border, rgba(255,255,255,.08)) !important;
    border-radius: 16px !important;
    padding: 24px !important;
    margin: 0 !important;
    min-height: 200px !important;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.35) !important;
}

#wizard-step-3.active #configSummaryCard h3 {
    display: block !important;
    color: var(--ui-text, #fff) !important;
    font-size: 18px !important;
    font-weight: 600 !important;
    margin-bottom: 16px !important;
}

#wizard-step-3.active #configSummaryCard p {
    display: block !important;
    color: var(--ui-muted, rgba(255,255,255,.66)) !important;
    font-size: 14px !important;
    margin-bottom: 8px !important;
}

/* ============================================================================
   Toggle Switch Styles for Celebrity Intelligence
   ============================================================================ */

.toggle-switch {
    position: relative;
    display: inline-block;
    width: 48px;
    height: 26px;
    flex-shrink: 0;
}

.toggle-switch input {
    opacity: 0;
    width: 0;
    height: 0;
}

.toggle-slider {
    position: absolute;
    cursor: pointer;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-color: var(--ui-border, rgba(255,255,255,.08));
    transition: 0.3s;
    border-radius: 26px;
}

.toggle-slider:before {
    position: absolute;
    content: "";
    height: 20px;
    width: 20px;
    left: 3px;
    bottom: 3px;
    background-color: white;
    transition: 0.3s;
    border-radius: 50%;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.15);
}

.toggle-switch input:checked + .toggle-slider {
    background: linear-gradient(135deg, #6D4AFF 0%, #9B8CFF 100%);
}

.toggle-switch input:checked + .toggle-slider:before {
    transform: translateX(22px);
}

.toggle-switch input:focus + .toggle-slider {
    box-shadow: 0 0 0 3px rgba(109, 74, 255, 0.35);
}

/* ============================================================
   STEP 3 REVIEW CARD - CORRECTED (2026-01-27)
   ============================================================ */

/* Step 3 is hidden by default (controlled by [data-wizard-step] rule above) */
/* Only show content when Step 3 has .active class */
#wizard-step-3.active {
    display: block !important;
    width: 100%;
    min-height: 400px;
    background: var(--ui-bg, #0A0A0A);
}

#wizard-step-3.active #reviewCard {
    display: block;
    width: 100%;
    background: var(--ui-surface, #141414);
}

/* Wizard body and main styling */
.wizard-body {
    background: var(--ui-bg, #0A0A0A);
}

.wizard-main {
    background: var(--ui-bg, #0A0A0A);
}
