/* ============================================================
   EXPERT MODE WIZARD STYLES
   Updated: 2025-01-16 02:45 - FORCE HORIZONTAL WIZARD STEPS
   ============================================================ */

/* Wizard Progress Steps */
.wizard-progress {
    display: flex !important;
    flex-direction: row !important;
    justify-content: center;
    align-items: center;
    gap: 2.5rem;
    padding: 2rem;
    background: #f8fafc;
    border-bottom: 1px solid #e2e8f0;
    margin-bottom: 2rem;
    flex-wrap: nowrap;
}

.wizard-step {
    display: flex !important;
    flex-direction: column !important;
    align-items: center;
    justify-content: center;
    position: relative;
    transition: all 0.3s ease;
    flex-shrink: 0;
}

.wizard-step-number {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background: #e2e8f0;
    color: #64748b;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: bold;
    font-size: 1rem;
    transition: all 0.3s ease;
    margin-bottom: 0.5rem;
}

.wizard-step.active .wizard-step-number {
    background: #3b82f6;
    color: white;
    transform: scale(1.1);
}

.wizard-step.completed .wizard-step-number {
    background: #10b981;
    color: white;
}

.wizard-step-label {
    font-size: 0.875rem;
    font-weight: 600;
    color: #64748b;
    transition: all 0.3s ease;
}

.wizard-step.active .wizard-step-label,
.wizard-step.completed .wizard-step-label {
    color: #1e293b;
}

/* Wizard Content Container */
.wizard-content-container {
    position: relative;
    min-height: 500px;
}

.wizard-step-content {
    display: none;
    animation: fadeIn 0.3s ease-in;
}

.wizard-step-content.active {
    display: block;
}

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

/* Document Comparison */
.document-comparison {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 2rem;
    margin: 2rem 0;
}

/* Proofread Document Display */
.proofread-document-display {
    margin: 2rem 0;
}

.proofread-document-display h4 {
    margin: 0 0 1rem 0;
    color: #374151;
    font-size: 1.2rem;
    font-weight: 600;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.document-content {
    background: #ffffff;
    border: 2px solid #e2e8f0;
    border-radius: 12px;
    padding: 1.5rem;
}

.document-content textarea {
    width: 100%;
    min-height: 400px;
    border: 1px solid #d1d5db;
    border-radius: 8px;
    padding: 1.5rem;
    font-family: 'Monaco', 'Menlo', 'Ubuntu Mono', monospace;
    font-size: 0.9rem;
    line-height: 1.6;
    resize: vertical;
    background: #f9fafb;
}

.comparison-panel {
    border: 2px solid #e2e8f0;
    border-radius: 12px;
    overflow: hidden;
}

.comparison-panel h4 {
    background: #f8fafc;
    padding: 1rem;
    margin: 0;
    border-bottom: 1px solid #e2e8f0;
    color: #374151;
    font-weight: 600;
}

.comparison-panel textarea {
    width: 100%;
    height: 300px;
    border: none;
    padding: 1rem;
    font-family: 'Segoe UI', sans-serif;
    font-size: 0.9rem;
    line-height: 1.5;
    resize: vertical;
    background: white;
}

/* Improvements Section */
.improvements-section {
    background: #fef3c7;
    border: 2px solid #f59e0b;
    border-radius: 12px;
    padding: 1.5rem;
    margin: 2rem 0;
}

.improvements-section h4 {
    color: #92400e;
    margin-bottom: 1rem;
    font-size: 1.1rem;
}

.improvements-list {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 1rem;
}

.improvement-item {
    background: white;
    padding: 1rem;
    border-radius: 8px;
    border-left: 4px solid #f59e0b;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}

/* Intent Detection */
.intent-detection {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 2rem;
    margin: 2rem 0;
}

.intent-card {
    background: #dbeafe;
    border: 2px solid #3b82f6;
    border-radius: 12px;
    padding: 1.5rem;
}

.intent-card h3 {
    color: #1e40af;
    margin-bottom: 1rem;
    font-size: 1.2rem;
}

.intent-modification {
    background: #f3e8ff;
    border: 2px solid #8b5cf6;
    border-radius: 12px;
    padding: 1.5rem;
}

.intent-modification h3 {
    color: #6b21a8;
    margin-bottom: 1rem;
    font-size: 1.2rem;
}

.intent-modification textarea {
    width: 100%;
    height: 120px;
    border: 2px solid #c4b5fd;
    border-radius: 8px;
    padding: 1rem;
    font-family: 'Segoe UI', sans-serif;
    font-size: 0.9rem;
    resize: vertical;
    margin-bottom: 1rem;
}

.intent-details {
    background: white;
    padding: 1rem;
    border-radius: 8px;
    border: 1px solid #93c5fd;
}

.intent-detail-item {
    margin-bottom: 1rem;
    padding-bottom: 1rem;
    border-bottom: 1px solid #dbeafe;
}

.intent-detail-item:last-child {
    border-bottom: none;
    margin-bottom: 0;
}

.intent-detail-label {
    font-weight: 600;
    color: #1e40af;
    margin-bottom: 0.25rem;
    font-size: 0.9rem;
}

.intent-detail-value {
    color: #374151;
    line-height: 1.4;
}

/* SDLC Planning */
.methodology-info {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    padding: 1.5rem;
    border-radius: 12px;
    margin-bottom: 2rem;
    text-align: center;
}

.methodology-info h3 {
    font-size: 1.3rem;
    margin-bottom: 0.5rem;
}

.methodology-info p {
    font-size: 1rem;
    opacity: 0.9;
}

.sdlc-stages-container {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 1.5rem;
    margin: 2rem 0;
}

.sdlc-stage-card {
    background: white;
    border: 2px solid #e2e8f0;
    border-radius: 12px;
    padding: 1.5rem;
    transition: all 0.3s ease;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
}

.sdlc-stage-card:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 15px rgba(0, 0, 0, 0.15);
    border-color: #3b82f6;
}

.sdlc-stage-header {
    display: flex;
    align-items: center;
    margin-bottom: 1rem;
}

.sdlc-stage-number {
    background: #3b82f6;
    color: white;
    width: 35px;
    height: 35px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: bold;
    margin-right: 1rem;
    font-size: 0.9rem;
}

.sdlc-stage-title {
    font-size: 1.1rem;
    font-weight: 600;
    color: #1e293b;
}

.sdlc-stage-description {
    color: #64748b;
    line-height: 1.5;
    margin-bottom: 1rem;
}

.sdlc-stage-details {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1rem;
    margin-bottom: 1rem;
}

.sdlc-stage-detail {
    background: #f8fafc;
    padding: 0.75rem;
    border-radius: 6px;
    border-left: 3px solid #3b82f6;
}

.sdlc-stage-detail-label {
    font-size: 0.8rem;
    color: #64748b;
    font-weight: 600;
    margin-bottom: 0.25rem;
}

.sdlc-stage-detail-value {
    color: #374151;
    font-size: 0.85rem;
}

.sdlc-deliverables {
    background: #ecfdf5;
    padding: 1rem;
    border-radius: 8px;
    border-left: 4px solid #10b981;
}

.sdlc-deliverables h5 {
    color: #065f46;
    margin-bottom: 0.75rem;
    font-size: 0.9rem;
}

.sdlc-deliverables ul {
    list-style: none;
    padding: 0;
    margin: 0;
}

.sdlc-deliverables li {
    background: white;
    padding: 0.5rem 0.75rem;
    margin-bottom: 0.5rem;
    border-radius: 4px;
    font-size: 0.8rem;
    color: #374151;
}

.sdlc-deliverables li:before {
    content: "✓ ";
    color: #10b981;
    font-weight: bold;
}

/* Task Generation */
.tasks-summary {
    background: linear-gradient(135deg, #ff9a9e 0%, #fecfef 100%);
    color: white;
    padding: 1.5rem;
    border-radius: 12px;
    margin-bottom: 2rem;
    text-align: center;
}

.tasks-summary h3 {
    font-size: 1.3rem;
    margin-bottom: 1rem;
}

.tasks-summary-stats {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(120px, 1fr));
    gap: 1rem;
}

.tasks-stat-item {
    background: rgba(255, 255, 255, 0.2);
    padding: 1rem;
    border-radius: 8px;
    backdrop-filter: blur(10px);
}

.tasks-stat-number {
    font-size: 1.5rem;
    font-weight: bold;
    margin-bottom: 0.25rem;
}

.tasks-stat-label {
    font-size: 0.8rem;
    opacity: 0.9;
}

.tasks-container {
    margin: 2rem 0;
}

.tasks-stage {
    background: white;
    border: 2px solid #e2e8f0;
    border-radius: 12px;
    margin-bottom: 1.5rem;
    overflow: hidden;
}

.tasks-stage-header {
    background: #f8fafc;
    padding: 1rem;
    border-bottom: 1px solid #e2e8f0;
}

.tasks-stage-header h4 {
    color: #374151;
    margin: 0;
    font-size: 1.1rem;
}

.task-item {
    padding: 1rem;
    border-bottom: 1px solid #f1f5f9;
    transition: all 0.3s ease;
}

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

.task-item:hover {
    background: #f8faff;
}

.task-header {
    display: flex;
    align-items: center;
    margin-bottom: 0.75rem;
}

.task-id {
    background: #3b82f6;
    color: white;
    padding: 0.25rem 0.5rem;
    border-radius: 4px;
    font-size: 0.75rem;
    font-weight: bold;
    margin-right: 0.75rem;
}

.task-title {
    font-weight: 600;
    color: #1e293b;
    flex: 1;
}

.task-meta {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(100px, 1fr));
    gap: 0.75rem;
    margin: 0.75rem 0;
}

.task-meta-item {
    background: #f8fafc;
    padding: 0.5rem 0.75rem;
    border-radius: 4px;
    border-left: 3px solid #64748b;
}

.task-meta-label {
    font-size: 0.7rem;
    color: #64748b;
    font-weight: 600;
    margin-bottom: 0.125rem;
}

.task-meta-value {
    color: #374151;
    font-size: 0.8rem;
}

.task-description {
    color: #64748b;
    line-height: 1.4;
    margin: 0.5rem 0;
    font-size: 0.9rem;
}

.task-criteria {
    background: #ecfdf5;
    padding: 1rem;
    border-radius: 8px;
    border-left: 4px solid #10b981;
    margin-top: 0.75rem;
}

.task-criteria h6 {
    color: #065f46;
    margin-bottom: 0.5rem;
    font-size: 0.85rem;
}

.task-criteria ul {
    list-style: none;
    padding: 0;
    margin: 0;
}

.task-criteria li {
    background: white;
    padding: 0.375rem 0.5rem;
    margin-bottom: 0.25rem;
    border-radius: 3px;
    font-size: 0.8rem;
    color: #374151;
}

.task-criteria li:before {
    content: "• ";
    color: #10b981;
    font-weight: bold;
}

/* Jira Configuration */
.jira-config {
    background: #fef3c7;
    border: 2px solid #f59e0b;
    border-radius: 12px;
    padding: 1.5rem;
    margin: 2rem 0;
}

.jira-config h3 {
    color: #92400e;
    margin-bottom: 1rem;
    font-size: 1.1rem;
}

.jira-config-row {
    display: flex;
    align-items: center;
    gap: 1rem;
}

.jira-config-row label {
    font-weight: 600;
    color: #92400e;
    min-width: 100px;
}

.jira-config-row input {
    flex: 1;
    padding: 0.75rem;
    border: 2px solid #fbbf24;
    border-radius: 6px;
    font-size: 0.9rem;
    transition: all 0.3s ease;
}

.jira-config-row input:focus {
    outline: none;
    border-color: #f59e0b;
    box-shadow: 0 0 0 3px rgba(245, 158, 11, 0.1);
}

/* Completion Summary */
.completion-summary {
    background: linear-gradient(135deg, #56ab2f 0%, #a8e6cf 100%);
    color: white;
    padding: 2rem;
    border-radius: 12px;
    margin: 2rem 0;
    text-align: center;
}

.completion-summary h3 {
    font-size: 1.3rem;
    margin-bottom: 1rem;
}

.completion-stats {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(120px, 1fr));
    gap: 1rem;
}

.completion-stat {
    background: rgba(255, 255, 255, 0.2);
    padding: 1rem;
    border-radius: 8px;
    backdrop-filter: blur(10px);
}

.completion-stat-number {
    font-size: 1.8rem;
    font-weight: bold;
    margin-bottom: 0.5rem;
}

.completion-stat-label {
    font-size: 0.8rem;
    opacity: 0.9;
}

/* Wizard Actions */
.wizard-actions,
.intent-actions,
.stage-actions,
.final-actions,
.completion-actions {
    display: flex;
    gap: 1rem;
    justify-content: center;
    margin-top: 2rem;
}

.wizard-actions .btn,
.intent-actions .btn,
.stage-actions .btn,
.final-actions .btn,
.completion-actions .btn {
    padding: 0.75rem 1.5rem;
    border-radius: 8px;
    font-weight: 600;
    transition: all 0.3s ease;
    cursor: pointer;
    border: none;
    font-size: 0.9rem;
}

.wizard-actions .btn:hover,
.intent-actions .btn:hover,
.stage-actions .btn:hover,
.final-actions .btn:hover,
.completion-actions .btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.2);
}

/* Responsive Design */
@media (max-width: 768px) {
    .wizard-progress {
        flex-wrap: wrap;
        padding: 1rem;
    }
    
    .wizard-step {
        margin: 0.5rem;
    }
    
    .wizard-step::after {
        display: none;
    }
    
    .document-comparison,
    .intent-detection {
        grid-template-columns: 1fr;
        gap: 1rem;
    }
    
    .sdlc-stages-container {
        grid-template-columns: 1fr;
        gap: 1rem;
    }
    
    .tasks-summary-stats,
    .completion-stats {
        grid-template-columns: repeat(2, 1fr);
        gap: 0.75rem;
    }
    
    .wizard-actions,
    .intent-actions,
    .stage-actions,
    .final-actions,
    .completion-actions {
        flex-direction: column;
        align-items: center;
    }
    
    .wizard-actions .btn,
    .intent-actions .btn,
    .stage-actions .btn,
    .final-actions .btn,
    .completion-actions .btn {
        width: 100%;
        max-width: 250px;
    }
}

@media (max-width: 480px) {
    .tasks-summary-stats,
    .completion-stats {
        grid-template-columns: 1fr;
    }
}

/* ============================================================
   SIMPLIFIED EXPERT MODE STYLES (Legacy)
   ============================================================ */

/* Document Preview */
.document-preview-card {
    background: white;
    border-radius: 12px;
    padding: 1.5rem;
    margin: 2rem 0;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
    border: 1px solid #e2e8f0;
}

.preview-tabs {
    display: flex;
    gap: 0.5rem;
    margin-bottom: 1rem;
    border-bottom: 2px solid #e2e8f0;
}

.preview-tabs .tab-btn {
    background: none;
    border: none;
    padding: 0.75rem 1.5rem;
    cursor: pointer;
    border-radius: 8px 8px 0 0;
    font-weight: 600;
    color: #64748b;
    transition: all 0.2s ease;
}

.preview-tabs .tab-btn.active {
    background: #3b82f6;
    color: white;
}

.preview-tabs .tab-btn:hover:not(.active) {
    background: #f1f5f9;
    color: #1e40af;
}

.preview-content {
    min-height: 400px;
    max-height: 600px;
    overflow-y: auto;
    border: 1px solid #e2e8f0;
    border-radius: 8px;
    padding: 1rem;
    background: #f8fafc;
}

.preview-content .tab-content {
    display: none;
    white-space: pre-wrap;
    font-family: 'Courier New', monospace;
    font-size: 0.9rem;
    line-height: 1.6;
    color: #374151;
}

.preview-content .tab-content.active {
    display: block;
}

/* Proofread Action */
.proofread-action {
    text-align: center;
    margin: 2rem 0;
}

/* Proofread Full Page View */
.proofread-container {
    margin: 2rem 0;
}

.proofread-textarea {
    width: 100%;
    min-height: 80vh;
    height: auto;
    max-height: none;
    padding: 2rem;
    border: 2px solid #e2e8f0;
    border-radius: 8px;
    font-family: 'Courier New', monospace;
    font-size: 0.9rem;
    line-height: 1.6;
    background: #f8fafc;
    resize: vertical;
    overflow-y: auto;
    box-sizing: border-box;
}

.proofread-actions {
    display: flex;
    justify-content: space-between;
    gap: 1rem;
    margin-top: 2rem;
}

/* SDLC Stage Buttons (Dynamic) */
.sdlc-stages-buttons {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 1rem;
    margin-top: 1.5rem;
}

.sdlc-stage-btn {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    padding: 1.5rem;
    background: linear-gradient(135deg, #f0f9ff 0%, #e0f2fe 100%);
    border: 2px solid #bae6fd;
    border-radius: 10px;
    cursor: pointer;
    transition: all 0.3s ease;
    text-align: left;
}

.sdlc-stage-btn:hover {
    transform: translateY(-4px);
    box-shadow: 0 8px 20px rgba(59, 130, 246, 0.3);
    border-color: #3b82f6;
}

.sdlc-stage-btn i {
    font-size: 1.5rem;
    color: #3b82f6;
    margin-bottom: 0.5rem;
}

.sdlc-stage-btn .stage-name {
    font-size: 1.1rem;
    font-weight: 700;
    color: #1e40af;
    margin-bottom: 0.5rem;
    display: block;
}

.sdlc-stage-btn .stage-summary {
    font-size: 0.9rem;
    color: #64748b;
    line-height: 1.4;
}

.sdlc-subtitle {
    color: #64748b;
    font-size: 0.95rem;
    margin-top: 0.5rem;
}

/* Modal for Stage Details */
.modal {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.7);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 10000;
    padding: 2rem;
}

.modal.hidden {
    display: none;
}

.modal-content {
    background: white;
    border-radius: 12px;
    max-width: 800px;
    width: 100%;
    max-height: 90vh;
    overflow-y: auto;
    box-shadow: 0 20px 50px rgba(0, 0, 0, 0.3);
}

.modal-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 1.5rem 2rem;
    border-bottom: 2px solid #e2e8f0;
    background: linear-gradient(135deg, #f0f9ff 0%, #e0f2fe 100%);
    border-radius: 12px 12px 0 0;
}

.modal-header h3 {
    margin: 0;
    color: #1e40af;
    font-size: 1.3rem;
}

.close-btn {
    background: none;
    border: none;
    font-size: 2rem;
    color: #64748b;
    cursor: pointer;
    line-height: 1;
    padding: 0;
    width: 32px;
    height: 32px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    transition: all 0.2s ease;
}

.close-btn:hover {
    background: #e2e8f0;
    color: #1e293b;
}

.modal-body {
    padding: 2rem;
}

.stage-detail-section {
    margin-bottom: 2rem;
}

.stage-detail-section h4 {
    color: #1e40af;
    margin-bottom: 0.75rem;
    font-size: 1.1rem;
}

.stage-detail-section p {
    color: #475569;
    line-height: 1.6;
}

.stage-detail-section ul {
    margin: 0.5rem 0;
    padding-left: 1.5rem;
}

.stage-detail-section ul li {
    color: #475569;
    margin-bottom: 0.5rem;
    line-height: 1.5;
}

.labels-container {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
}

.label-badge {
    background: #dbeafe;
    color: #1e40af;
    padding: 0.25rem 0.75rem;
    border-radius: 12px;
    font-size: 0.85rem;
    font-weight: 600;
}



/* Jira Ticket Cards */
.tickets-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(350px, 1fr));
    gap: 1.5rem;
}

.jira-ticket-card {
    background: #ffffff;
    border: 2px solid #e2e8f0;
    border-radius: 12px;
    padding: 1.5rem;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.05);
    transition: all 0.2s ease;
}

.jira-ticket-card:hover {
    border-color: #3b82f6;
    box-shadow: 0 4px 12px rgba(59, 130, 246, 0.15);
}

.ticket-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 1rem;
}

.ticket-type {
    background: #10b981;
    color: white;
    padding: 0.25rem 0.75rem;
    border-radius: 6px;
    font-size: 0.8rem;
    font-weight: 600;
}

.ticket-id {
    background: #6b7280;
    color: white;
    padding: 0.25rem 0.5rem;
    border-radius: 4px;
    font-size: 0.8rem;
    font-weight: 500;
}

.ticket-title {
    font-weight: 700;
    color: #1e293b;
    font-size: 1.1rem;
    margin-bottom: 0.75rem;
    line-height: 1.4;
}

.ticket-description {
    margin-bottom: 1rem;
    color: #64748b;
    line-height: 1.6;
    font-size: 0.9rem;
}

.ticket-metadata {
    display: flex;
    flex-wrap: wrap;
    gap: 1.5rem;
    margin-bottom: 1rem;
    align-items: center;
}

.metadata-item {
    display: flex;
    flex-direction: row;
    align-items: center;
    gap: 0.5rem;
}

.metadata-item .editable-input,
.metadata-item .editable-select {
    width: auto;
    min-width: 80px;
    max-width: 150px;
    flex-shrink: 0;
}

.metadata-label {
    font-size: 0.75rem;
    color: #64748b;
    font-weight: 500;
}

.metadata-value {
    font-weight: 600;
    color: #1e293b;
    font-size: 0.9rem;
}

.story-points {
    background: #fef3c7;
    color: #92400e;
    padding: 0.25rem 0.5rem;
    border-radius: 4px;
    display: inline-block;
    width: fit-content;
}

.priority-high {
    color: #dc2626;
    font-weight: 700;
}

.priority-medium {
    color: #d97706;
    font-weight: 600;
}

.priority-low {
    color: #059669;
    font-weight: 600;
}

.acceptance-criteria {
    border-top: 1px solid #e2e8f0;
    padding-top: 1rem;
}

.acceptance-criteria h6 {
    margin: 0 0 0.75rem 0;
    color: #374151;
    font-size: 0.9rem;
    font-weight: 600;
}

.acceptance-criteria ul {
    margin: 0;
    padding-left: 1.25rem;
}

.acceptance-criteria li {
    margin-bottom: 0.5rem;
    color: #64748b;
    font-size: 0.85rem;
    line-height: 1.5;
}

.stage-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 1.5rem;
    padding: 1rem 0;
    border-bottom: 2px solid #e2e8f0;
}

.stage-header h4 {
    margin: 0;
    color: #1e293b;
    font-size: 1.3rem;
    font-weight: 600;
}

.stage-task-count {
    background: #3b82f6;
    color: white;
    padding: 0.5rem 1rem;
    border-radius: 20px;
    font-size: 0.9rem;
    font-weight: 500;
}

/* Reasoning and Key Indicators Styling */
.reasoning-section {
    margin-bottom: 1.5rem;
}

.reasoning-content {
    line-height: 1.6;
    font-size: 0.9rem;
}

.reasoning-point {
    margin-bottom: 1rem;
    padding: 0.75rem;
    background: #f8fafc;
    border-left: 3px solid #3b82f6;
    border-radius: 4px;
}

.reasoning-header {
    font-weight: 600;
    color: #1e293b;
    margin-bottom: 0.5rem;
    font-size: 0.9rem;
}

.reasoning-content {
    color: #64748b;
    font-size: 0.85rem;
}

.reasoning-paragraph {
    margin-bottom: 0.75rem;
    color: #64748b;
    font-size: 0.9rem;
    line-height: 1.6;
}

.indicators-section {
    margin-bottom: 1.5rem;
}

.indicators-content {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.indicator-item {
    padding: 0.5rem 0.75rem;
    background: #e0f2fe;
    border: 1px solid #b3e5fc;
    border-radius: 6px;
    font-size: 0.85rem;
    color: #0277bd;
    font-weight: 500;
}

/* Ticket Editing Styles */
.ticket-actions {
    display: flex;
    gap: 0.5rem;
    align-items: center;
}

.edit-ticket-btn,
.save-ticket-btn,
.cancel-edit-btn {
    background: none;
    border: none;
    color: #6b7280;
    cursor: pointer;
    padding: 0.25rem;
    border-radius: 4px;
    transition: all 0.2s ease;
}

.edit-ticket-btn:hover {
    color: #3b82f6;
    background: #eff6ff;
}

.save-ticket-btn:hover {
    color: #10b981;
    background: #ecfdf5;
}

.cancel-edit-btn:hover {
    color: #ef4444;
    background: #fef2f2;
}

.jira-ticket-card.editing {
    border: 2px solid #3b82f6;
    box-shadow: 0 0 0 3px rgba(59, 130, 246, 0.1);
}

.editable-input,
.editable-textarea,
.editable-select {
    width: 100%;
    padding: 0.5rem;
    border: 1px solid #d1d5db;
    border-radius: 4px;
    font-size: 0.9rem;
    font-family: inherit;
    background: #fff;
    transition: border-color 0.2s ease;
    min-width: 120px;
    max-width: 200px;
}

.editable-input:focus,
.editable-textarea:focus,
.editable-select:focus {
    outline: none;
    border-color: #3b82f6;
    box-shadow: 0 0 0 3px rgba(59, 130, 246, 0.1);
}

.editable-textarea {
    resize: vertical;
    min-height: 60px;
}

.editable-select {
    cursor: pointer;
}

.add-criteria-btn {
    background: #f3f4f6;
    border: 1px dashed #9ca3af;
    color: #6b7280;
    padding: 0.5rem;
    border-radius: 4px;
    cursor: pointer;
    font-size: 0.85rem;
    margin-top: 0.5rem;
    transition: all 0.2s ease;
}

.add-criteria-btn:hover {
    background: #e5e7eb;
    border-color: #6b7280;
    color: #374151;
}

.acceptance-criteria li[contenteditable="true"] {
    background: #f9fafb;
    border: 1px solid #e5e7eb !important;
    transition: all 0.2s ease;
}

.acceptance-criteria li[contenteditable="true"]:focus {
    outline: none;
    border-color: #3b82f6 !important;
    background: #fff;
    box-shadow: 0 0 0 3px rgba(59, 130, 246, 0.1);
}

.hidden {
    display: none !important;
}

/* Interactive Intent Approval Styles */
.modification-prompt {
    color: #6b7280;
    font-size: 0.9rem;
    margin-bottom: 1.5rem;
    font-style: italic;
}

.editable-intent-form {
    background: #f8fafc;
    border: 1px solid #e2e8f0;
    border-radius: 8px;
    padding: 1.5rem;
    margin-bottom: 1.5rem;
}

.tech-stack-section {
    margin-top: 1.5rem;
    padding-top: 1.5rem;
    border-top: 1px solid #e2e8f0;
}

.tech-stack-section h4 {
    color: #374151;
    margin-bottom: 1rem;
    font-size: 1rem;
    font-weight: 600;
}

.tech-stack-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 1rem;
}

.form-group {
    margin-bottom: 1rem;
}

.form-group label {
    display: block;
    margin-bottom: 0.5rem;
    font-weight: 500;
    color: #374151;
    font-size: 0.9rem;
}

.form-control {
    width: 100%;
    padding: 0.75rem;
    border: 1px solid #d1d5db;
    border-radius: 6px;
    font-size: 0.9rem;
    transition: border-color 0.2s ease, box-shadow 0.2s ease;
    background: #fff;
}

.form-control:focus {
    outline: none;
    border-color: #3b82f6;
    box-shadow: 0 0 0 3px rgba(59, 130, 246, 0.1);
}

.form-control::placeholder {
    color: #9ca3af;
}

select.form-control {
    cursor: pointer;
}

#customIntentText {
    margin-top: 0.5rem;
}

.intent-actions {
    display: flex;
    gap: 1rem;
    justify-content: center;
    margin-top: 1.5rem;
}

.intent-actions .btn {
    min-width: 150px;
}

/* Custom intent field visibility */
#customIntentText.hidden {
    display: none !important;
}

/* Confirmation Summary Styles */
.confirmation-summary {
    background: #f0f9ff;
    border: 1px solid #0ea5e9;
    border-radius: 8px;
    padding: 1.5rem;
    margin-bottom: 1.5rem;
}

.summary-header {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    margin-bottom: 1rem;
    color: #0369a1;
    font-size: 1rem;
}

.summary-header i {
    color: #059669;
    font-size: 1.1rem;
}

.summary-content p {
    margin-bottom: 1rem;
    color: #374151;
    font-size: 0.9rem;
}

.detected-values {
    background: #fff;
    border: 1px solid #e5e7eb;
    border-radius: 6px;
    padding: 1rem;
    margin-bottom: 1rem;
}

.value-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0.5rem 0;
    border-bottom: 1px solid #f3f4f6;
}

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

.value-item .label {
    font-weight: 500;
    color: #374151;
    min-width: 100px;
}

.value-item .value {
    color: #059669;
    font-weight: 600;
    text-align: right;
    flex: 1;
    margin-left: 1rem;
}

.summary-question {
    font-weight: 500;
    color: #1f2937;
    text-align: center;
    margin-top: 1rem;
    font-style: italic;
}

/* Manual Entry Prompt Styles */
.manual-entry-prompt {
    background: #fef3c7;
    border: 1px solid #f59e0b;
    border-radius: 8px;
    padding: 1.5rem;
    margin-bottom: 1.5rem;
}

.prompt-header {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    margin-bottom: 1rem;
    color: #92400e;
    font-size: 1rem;
}

.prompt-header i {
    color: #d97706;
    font-size: 1.1rem;
}

.prompt-content p {
    margin: 0;
    color: #374151;
    font-size: 0.9rem;
}

@media (max-width: 768px) {
    .tech-stack-grid {
        grid-template-columns: 1fr;
    }
    
    .intent-actions {
        flex-direction: column;
        align-items: center;
    }
    
    .intent-actions .btn {
        width: 100%;
        max-width: 300px;
    }
    
    .value-item {
        flex-direction: column;
        align-items: flex-start;
        gap: 0.25rem;
    }
    
    .value-item .value {
        text-align: left;
        margin-left: 0;
    }
}

/* SDLC Stage Edit/Delete Controls */
.sdlc-stage-actions {
    display: flex;
    gap: 0.5rem;
    margin-left: auto;
}

.sdlc-stage-actions .btn {
    padding: 0.375rem 0.75rem;
    font-size: 0.875rem;
}

.edit-stage-btn {
    color: #3b82f6;
    border-color: #3b82f6;
}

.edit-stage-btn:hover {
    background-color: #3b82f6;
    color: white;
}

.delete-stage-btn {
    color: #ef4444;
    border-color: #ef4444;
}

.delete-stage-btn:hover {
    background-color: #ef4444;
    color: white;
}

/* SDLC Stage Edit Form */
.sdlc-stage-edit-form {
    background: #f8fafc;
    border: 1px solid #e2e8f0;
    border-radius: 8px;
    padding: 1.5rem;
    margin-top: 1rem;
}

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

.edit-form-header h5 {
    margin: 0;
    color: #374151;
    font-size: 1rem;
    font-weight: 600;
}

.edit-form-actions {
    display: flex;
    gap: 0.5rem;
}

.edit-form-content {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1rem;
}

.edit-form-content .form-group:first-child {
    grid-column: 1 / -1;
}

.edit-form-content .form-group:nth-child(2) {
    grid-column: 1 / -1;
}

.edit-form-content .form-group:nth-child(5) {
    grid-column: 1 / -1;
}

.edit-form-content .form-group label {
    display: block;
    margin-bottom: 0.5rem;
    font-weight: 500;
    color: #374151;
    font-size: 0.875rem;
}

.edit-form-content .form-control {
    width: 100%;
    padding: 0.5rem;
    border: 1px solid #d1d5db;
    border-radius: 4px;
    font-size: 0.875rem;
    transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

.edit-form-content .form-control:focus {
    outline: none;
    border-color: #3b82f6;
    box-shadow: 0 0 0 2px rgba(59, 130, 246, 0.1);
}

/* Modification Indicator Styles */
.modification-indicator {
    margin: 1.5rem 0;
}

/* Tech Stack Confirmation Styles */
.tech-stack-confirmation {
    background: linear-gradient(135deg, #e8f5e8 0%, #f0f8f0 100%);
    border: 1px solid #4caf50;
    border-radius: 8px;
    padding: 16px;
    margin: 16px 0;
    font-size: 14px;
}

.tech-stack-confirmation .confirmation-header {
    display: flex;
    align-items: center;
    margin-bottom: 12px;
    font-weight: 600;
    color: #2e7d32;
}

.tech-stack-confirmation .confirmation-header i {
    margin-right: 8px;
    font-size: 16px;
    color: #4caf50;
}

.tech-stack-confirmation .confirmation-content p {
    margin-bottom: 12px;
    color: #2e7d32;
}

.tech-stack-summary {
    background: rgba(255, 255, 255, 0.7);
    border-radius: 6px;
    padding: 12px;
    margin: 12px 0;
}

.tech-item {
    display: flex;
    justify-content: space-between;
    margin-bottom: 6px;
    padding: 4px 0;
}

.tech-item:last-child {
    margin-bottom: 0;
}

.tech-label {
    font-weight: 600;
    color: #2e7d32;
    min-width: 80px;
}

.tech-value {
    color: #1b5e20;
    font-weight: 500;
    text-align: right;
    flex: 1;
    margin-left: 12px;
}

.confirmation-note {
    font-style: italic;
    color: #388e3c !important;
    margin-top: 12px !important;
    font-size: 13px;
}

/* Step 4 - MD File Generation Styles */
.md-generation-status {
    margin: 1.5rem 0;
}

.step-ready {
    background: linear-gradient(135deg, #e3f2fd 0%, #f3e5f5 100%);
    border: 1px solid #2196f3;
    border-radius: 12px;
    padding: 24px;
    text-align: center;
}

.ready-header {
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 16px;
    font-size: 18px;
    font-weight: 600;
    color: #1976d2;
}

.ready-header i {
    margin-right: 12px;
    font-size: 24px;
    color: #2196f3;
}

.step-ready p {
    color: #1565c0;
    margin: 0;
    font-size: 16px;
}

/* Tickets List Container */
.tickets-list-container {
    margin: 1.5rem 0;
}

.tickets-generation-list h4 {
    color: #333;
    margin-bottom: 1rem;
    font-size: 18px;
    font-weight: 600;
}

.tickets-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(350px, 1fr));
    gap: 1rem;
    margin-bottom: 1.5rem;
}

/* Ticket Generation Card */
.ticket-generation-card {
    background: #fff;
    border: 1px solid #e0e0e0;
    border-radius: 8px;
    padding: 16px;
    transition: all 0.3s ease;
    position: relative;
}

.ticket-generation-card:hover {
    border-color: #2196f3;
    box-shadow: 0 2px 8px rgba(33, 150, 243, 0.1);
}

.ticket-generation-card.files-generated {
    border-color: #4caf50;
    background: linear-gradient(135deg, #f1f8e9 0%, #e8f5e8 100%);
}

.ticket-generation-card .ticket-header {
    display: flex;
    align-items: flex-start;
    margin-bottom: 12px;
}

.ticket-generation-card .ticket-key {
    background: #2196f3;
    color: white;
    padding: 4px 8px;
    border-radius: 4px;
    font-size: 12px;
    font-weight: 600;
    margin-right: 12px;
    flex-shrink: 0;
}

.ticket-generation-card .ticket-title {
    font-weight: 600;
    color: #333;
    font-size: 14px;
    line-height: 1.4;
    flex: 1;
}

.ticket-generation-card .ticket-details {
    margin-bottom: 16px;
}

.ticket-generation-card .ticket-details > div {
    font-size: 12px;
    color: #666;
    margin-bottom: 4px;
}

.ticket-generation-card .ticket-actions {
    display: flex;
    align-items: center;
    gap: 8px;
    flex-wrap: wrap;
}

.ticket-generation-card .btn-sm {
    padding: 6px 12px;
    font-size: 12px;
    border-radius: 4px;
}

.ticket-generation-status {
    font-size: 12px;
    color: #666;
    display: flex;
    align-items: center;
    gap: 4px;
}

.ticket-generation-status .fa-spinner {
    animation: spin 1s linear infinite;
}

.ticket-generation-status .text-success {
    color: #4caf50;
}

.ticket-generation-status .text-error {
    color: #f44336;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

.generation-success {
    background: linear-gradient(135deg, #e8f5e8 0%, #f0f8f0 100%);
    border: 1px solid #4caf50;
    border-radius: 12px;
    padding: 24px;
    text-align: center;
}

.success-header {
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 20px;
    font-size: 18px;
    font-weight: 600;
    color: #2e7d32;
}

.success-header i {
    margin-right: 12px;
    font-size: 24px;
    color: #4caf50;
}

.success-stats {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
    gap: 20px;
    margin-top: 20px;
}

.stat-item {
    text-align: center;
    padding: 16px;
    background: rgba(255, 255, 255, 0.7);
    border-radius: 8px;
}

.stat-number {
    display: block;
    font-size: 32px;
    font-weight: 700;
    color: #2e7d32;
    line-height: 1;
}

.stat-label {
    display: block;
    font-size: 14px;
    color: #388e3c;
    margin-top: 8px;
    font-weight: 500;
}

.generated-files-summary {
    margin: 2rem 0;
}

.files-summary {
    background: #f8f9fa;
    border: 1px solid #dee2e6;
    border-radius: 8px;
    padding: 20px;
}

.files-summary h4 {
    color: #495057;
    margin-bottom: 12px;
}

.files-summary p {
    color: #6c757d;
    margin-bottom: 20px;
}

.files-summary-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 16px;
}

.ticket-files-summary {
    background: white;
    border: 1px solid #e9ecef;
    border-radius: 6px;
    padding: 16px;
}

.ticket-files-summary .ticket-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 8px;
}

.ticket-key {
    font-weight: 600;
    color: #007bff;
    font-size: 14px;
}

.ticket-title {
    color: #495057;
    font-size: 14px;
    flex: 1;
    margin-left: 12px;
}

.files-count {
    color: #28a745;
    font-weight: 500;
    font-size: 14px;
}

.generated-files-container {
    margin: 2rem 0;
}

.files-by-ticket {
    background: #f8f9fa;
    border: 1px solid #dee2e6;
    border-radius: 8px;
    padding: 20px;
}

.files-by-ticket h4 {
    color: #495057;
    margin-bottom: 20px;
}

.ticket-files-detail {
    background: white;
    border: 1px solid #e9ecef;
    border-radius: 6px;
    padding: 16px;
    margin-bottom: 16px;
}

.ticket-files-detail:last-child {
    margin-bottom: 0;
}

.ticket-files-detail .ticket-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 16px;
    padding-bottom: 12px;
    border-bottom: 1px solid #e9ecef;
}

.ticket-files-detail .ticket-header h5 {
    color: #495057;
    margin: 0;
    font-size: 16px;
}

.files-list {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));
    gap: 12px;
}

.file-item {
    background: #f8f9fa;
    border: 1px solid #e9ecef;
    border-radius: 4px;
    padding: 12px;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.file-name {
    display: flex;
    align-items: center;
    flex: 1;
}

.file-name i {
    margin-right: 8px;
    color: #6c757d;
}

.file-name span {
    color: #495057;
    font-weight: 500;
    font-size: 14px;
}

.file-details {
    display: flex;
    flex-direction: column;
    align-items: flex-end;
    text-align: right;
}

.file-size {
    color: #6c757d;
    font-size: 12px;
}

.file-purpose {
    color: #28a745;
    font-size: 12px;
    font-weight: 500;
}

.modification-summary {
    background: #fef3c7;
    border: 1px solid #f59e0b;
    border-radius: 8px;
    padding: 1rem;
    display: flex;
    align-items: center;
    gap: 0.75rem;
}

.modification-summary i {
    color: #d97706;
    font-size: 1.2rem;
    flex-shrink: 0;
}

.modification-summary strong {
    color: #92400e;
    font-size: 0.9rem;
    flex-shrink: 0;
}

.modification-details {
    display: flex;
    gap: 1rem;
    margin-left: auto;
}

.edit-count, .delete-count {
    padding: 0.25rem 0.5rem;
    border-radius: 4px;
    font-size: 0.8rem;
    font-weight: 600;
}

.edit-count {
    background: #dbeafe;
    color: #1e40af;
}

.delete-count {
    background: #fecaca;
    color: #dc2626;
}

.modification-note {
    margin: 0.5rem 0 0 0;
    color: #92400e;
    font-size: 0.8rem;
    font-style: italic;
    flex-basis: 100%;
}

@media (max-width: 768px) {
    .sdlc-stage-header {
        flex-direction: column;
        align-items: flex-start;
        gap: 0.5rem;
    }
    
    .sdlc-stage-actions {
        margin-left: 0;
        align-self: flex-end;
    }
    
    .edit-form-content {
        grid-template-columns: 1fr;
    }
    
    .edit-form-header {
        flex-direction: column;
        align-items: flex-start;
        gap: 0.75rem;
    }
    
    .edit-form-actions {
        align-self: flex-end;
    }
}

@media (max-width: 768px) {
    .tickets-grid {
        grid-template-columns: 1fr;
    }
    
    .reasoning-point {
        padding: 0.5rem;
    }
    
    .indicator-item {
        padding: 0.4rem 0.6rem;
        font-size: 0.8rem;
    }
    
    .ticket-actions {
        flex-direction: column;
        gap: 0.25rem;
    }
    
    .edit-ticket-btn,
    .save-ticket-btn,
    .cancel-edit-btn {
        padding: 0.5rem;
        font-size: 0.8rem;
    }
}

/* Blueprint Section Styles */
.blueprint-section {
    background: #f8f9fa;
    border: 2px solid #e9ecef;
    border-radius: 12px;
    padding: 24px;
    margin-bottom: 24px;
}

.blueprint-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    margin-bottom: 16px;
}

.blueprint-header h3 {
    margin: 0;
    color: #495057;
    font-size: 1.25rem;
    font-weight: 600;
}

.blueprint-status {
    flex: 1;
    margin-left: 16px;
}

.status-badge {
    display: inline-flex;
    align-items: center;
    padding: 8px 12px;
    border-radius: 6px;
    font-size: 0.875rem;
    font-weight: 500;
    margin-bottom: 8px;
}

.status-badge i {
    margin-right: 6px;
}

.status-success {
    background-color: #d4edda;
    color: #155724;
    border: 1px solid #c3e6cb;
}

.status-warning {
    background-color: #fff3cd;
    color: #856404;
    border: 1px solid #ffeaa7;
}

.status-error {
    background-color: #f8d7da;
    color: #721c24;
    border: 1px solid #f5c6cb;
}

.blueprint-info {
    margin-top: 8px;
    color: #6c757d;
}

.blueprint-actions {
    display: flex;
    gap: 12px;
    flex-wrap: wrap;
}

.blueprint-actions .btn {
    min-width: 120px;
}

/* Generation Section */
.generation-section {
    background: #ffffff;
    border: 1px solid #dee2e6;
    border-radius: 8px;
    padding: 20px;
}

/* Blueprint responsive styles */
@media (max-width: 768px) {
    .blueprint-header {
        flex-direction: column;
        align-items: flex-start;
    }
    
    .blueprint-status {
        margin-left: 0;
        margin-top: 12px;
    }
    
    .blueprint-actions {
        flex-direction: column;
        gap: 8px;
    }
}

/* FORCE HORIZONTAL WIZARD STEPS - OVERRIDE ALL OTHER STYLES */
.wizard-progress {
    display: flex !important;
    flex-direction: row !important;
    flex-wrap: nowrap !important;
    justify-content: center !important;
    align-items: center !important;
    padding: 2rem !important;
    background: #f8fafc !important;
    border-bottom: 1px solid #e2e8f0 !important;
    margin-bottom: 2rem !important;
}

.wizard-progress .wizard-step {
    display: flex !important;
    flex-direction: column !important;
    align-items: center !important;
    margin: 0 1rem !important;
    position: relative !important;
    transition: all 0.3s ease !important;
    flex-shrink: 0 !important;
}
