/* Generator / Wizard */
.generator-page { padding: 2rem 0 4rem; }
.generator-header { text-align: center; margin-bottom: 2.5rem; }
.generator-header h1 { margin-bottom: 0.5rem; }
.generator-header p { color: var(--text-light); font-size: 1.0625rem; }

/* Progress */
.wizard-progress { position: relative; margin-bottom: 2.5rem; padding: 0 1rem; }
.wizard-progress-bar {
    position: absolute;
    top: 22px;
    left: 1rem;
    height: 3px;
    background: var(--primary);
    border-radius: 4px;
    transition: width var(--transition-slow);
    z-index: 1;
}
.wizard-steps { display: flex; justify-content: space-between; position: relative; }
.wizard-steps::before {
    content: '';
    position: absolute;
    top: 22px;
    left: 0;
    right: 0;
    height: 3px;
    background: var(--border);
    border-radius: 4px;
}
.wizard-step {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.5rem;
    background: none;
    border: none;
    cursor: pointer;
    position: relative;
    z-index: 2;
    padding: 0;
    font-family: var(--font-sans);
}
.wizard-step-num {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 44px;
    height: 44px;
    border-radius: 50%;
    background: var(--bg-white);
    border: 3px solid var(--border);
    font-weight: 700;
    font-size: 0.9375rem;
    color: var(--text-muted);
    transition: all var(--transition);
}
.wizard-step--active .wizard-step-num {
    background: var(--primary);
    border-color: var(--primary);
    color: #fff;
}
.wizard-step--done .wizard-step-num {
    background: var(--success);
    border-color: var(--success);
    color: #fff;
}
.wizard-step-label { font-size: 0.8125rem; color: var(--text-muted); font-weight: 500; }
.wizard-step--active .wizard-step-label { color: var(--primary); font-weight: 600; }

/* Panels */
.wizard-panel { display: none; background: var(--bg-white); border: 1px solid var(--border); border-radius: var(--radius-lg); padding: 2.5rem; }
.wizard-panel--active { display: block; animation: fadeIn 0.3s ease; }
.wizard-panel h2 { margin-bottom: 1.5rem; font-size: 1.5rem; }
.wizard-panel h3 { margin-bottom: 1rem; color: var(--dark-600); }

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

/* Radio cards */
.radio-cards { display: grid; grid-template-columns: repeat(3, 1fr); gap: 0.75rem; }
.radio-card { cursor: pointer; }
.radio-card input { display: none; }
.radio-card-content {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.5rem;
    padding: 1.25rem;
    border: 2px solid var(--border);
    border-radius: var(--radius);
    transition: all var(--transition);
    text-align: center;
    color: var(--text-light);
}
.radio-card-content span { font-size: 0.875rem; font-weight: 600; }
.radio-card input:checked + .radio-card-content {
    border-color: var(--primary);
    background: var(--primary-50);
    color: var(--primary);
}
.radio-card:hover .radio-card-content { border-color: var(--primary-light); }

/* Checkbox grid */
.checkbox-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); gap: 0.5rem; }
.checkbox-card {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.75rem 1rem;
    border: 1.5px solid var(--border);
    border-radius: var(--radius);
    cursor: pointer;
    transition: all var(--transition);
    font-size: 0.875rem;
}
.checkbox-card:hover { border-color: var(--primary-light); }
.checkbox-card input { accent-color: var(--primary); }
.checkbox-card input:checked ~ span { color: var(--primary); font-weight: 600; }

/* Toggle */
.toggle-group { display: flex; flex-direction: column; gap: 0.5rem; }
.toggle { display: flex; align-items: center; gap: 0.75rem; cursor: pointer; }
.toggle input { display: none; }
.toggle-slider {
    position: relative;
    width: 48px;
    height: 26px;
    background: var(--border);
    border-radius: 26px;
    transition: background var(--transition);
    flex-shrink: 0;
}
.toggle-slider::before {
    content: '';
    position: absolute;
    top: 3px;
    left: 3px;
    width: 20px;
    height: 20px;
    background: #fff;
    border-radius: 50%;
    transition: transform var(--transition);
    box-shadow: var(--shadow-sm);
}
.toggle input:checked + .toggle-slider { background: var(--primary); }
.toggle input:checked + .toggle-slider::before { transform: translateX(22px); }
.toggle-label { font-size: 0.9375rem; color: var(--text); }

/* Conditional sections */
.conditional-section { padding: 1rem 0; animation: fadeIn 0.3s ease; }

/* Recap */
.recap-card { background: var(--bg-alt); border-radius: var(--radius); padding: 1.5rem; margin-bottom: 2rem; }
.recap-row { display: flex; justify-content: space-between; padding: 0.5rem 0; border-bottom: 1px solid var(--border-light); }
.recap-row:last-child { border-bottom: none; }
.recap-label { color: var(--text-muted); font-size: 0.875rem; }
.recap-value { font-weight: 600; font-size: 0.875rem; color: var(--dark); }

/* Docs preview */
.docs-preview { margin: 1rem 0 2rem; }
.doc-preview-item {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.625rem 0;
    font-size: 0.9375rem;
}
.doc-preview-badge { margin-left: auto; padding: 0.125rem 0.5rem; border-radius: 50px; font-size: 0.75rem; font-weight: 600; }
.doc-preview-badge--green { background: var(--success-bg); color: #166534; }
.doc-preview-badge--blue { background: var(--primary-100); color: var(--primary-dark); }

/* Auth required */
.auth-required-notice {
    display: flex;
    align-items: flex-start;
    gap: 1rem;
    padding: 1.5rem;
    background: var(--warning-bg);
    border: 1px solid #fde68a;
    border-radius: var(--radius);
    margin: 2rem 0;
}
.auth-required-notice p { margin-bottom: 0.5rem; font-size: 0.9375rem; }
.auth-buttons { display: flex; gap: 0.5rem; margin-top: 0.75rem; }

/* Upsell */
.upsell-section { margin-top: 2rem; }
.upsell-card {
    background: linear-gradient(135deg, var(--primary-50) 0%, #ede9fe 100%);
    border: 2px solid var(--primary);
    border-radius: var(--radius-lg);
    padding: 2rem;
    text-align: center;
}
.upsell-card h3 { margin-bottom: 0.5rem; }
.upsell-card p { color: var(--text-light); margin-bottom: 1.5rem; }
.upsell-buttons { display: flex; gap: 1rem; justify-content: center; }

/* Generate section */
.generate-section { margin-bottom: 2rem; }
.generate-section h3 { font-size: 1.125rem; margin-bottom: 0.75rem; }

/* Loading */
.generator-loading {
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.5);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 1000;
}
.loading-content { background: var(--bg-white); padding: 3rem; border-radius: var(--radius-lg); text-align: center; }
.loading-spinner {
    width: 48px;
    height: 48px;
    border: 4px solid var(--border);
    border-top-color: var(--primary);
    border-radius: 50%;
    animation: spin 0.8s linear infinite;
    margin: 0 auto 1rem;
}
@keyframes spin { to { transform: rotate(360deg); } }

/* Responsive */
@media (max-width: 768px) {
    .wizard-panel { padding: 1.5rem; }
    .radio-cards { grid-template-columns: repeat(2, 1fr); }
    .checkbox-grid { grid-template-columns: 1fr; }
    .upsell-buttons { flex-direction: column; }
}

@media (max-width: 480px) {
    .radio-cards { grid-template-columns: 1fr; }
}
