/* =========================
   DIALOG FULLSCREEN
   ========================= */
.fullscreen-dialog {
    width: 100%;
    max-width: 100%;
    height: 100vh;
    max-height: 100vh;
    margin: 0;
    border-radius: 0;
    overflow-x: hidden;
}

.fullscreen-dialog .md-dialog-content {
    display: flex;
    flex-direction: column;
    flex: 1;
    min-height: 0;
    overflow: hidden;
}

/* =========================
   GLOBAL STEPPER
   ========================= */
*, *::before, *::after {
    box-sizing: border-box;
}

.ai-stepper {
    display: flex;
    flex-direction: column;
    flex: 1;
    min-height: 0;
    overflow: hidden;
    padding: 0 10px;
}

.ai-stepper-row {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    align-items: center;
    position: relative;
    flex-shrink: 0;
}


/* =========================
   LINE 1
   ========================= */
.ai-stepper-row.track {
    height: 96px;
    margin-bottom: 5px;
}

/* Barre de fond */
.ai-stepper-row.track .bar,
.ai-stepper-row.track .bar-progress {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    height: 6px;
    border-radius: 3px;
}

.ai-stepper-row.track .bar {
    left: 0;
    right: 0;
    background: #e0e0e0;
    z-index: 1;
}

.ai-stepper-row.track .bar-progress {
    left: 0;
    background: #A3D039;
    z-index: 2;
    transition: width 0.4s ease;
}

.ai-stepper-row.track .cell {
    display: flex;
    justify-content: center;
    z-index: 3;
}

.circle {
    width: 72px;
    height: 72px;
    border-radius: 50%;
    background: #eeeeee;
    display: flex;
    align-items: center;
    justify-content: center;
}

.tiny-circle {
    width: 20px;
    height: 20px;
    border-radius: 50%;
    background: #eeeeee;
    display: flex;
    align-items: center;
    justify-content: center;
}

.cell.active .circle,
.cell.running .circle {
    background: #77C6CB;
    animation: stepPulse 1.6s ease-in-out infinite;
}

@keyframes stepPulse {
    0% {
        transform: scale(1);
        box-shadow: 0 0 0 0 rgb(119, 198, 203);
    }
    50% {
        transform: scale(1.08);
        box-shadow: 0 0 0 10px rgba(63, 81, 181, 0);
    }
    100% {
        transform: scale(1);
        box-shadow: 0 0 0 0 rgba(63, 81, 181, 0);
    }
}

.cell.done .circle {
    background: #A3D039;
}

.cell.disabled .circle {
    background: #bdbdbd;
}

.cell.error .circle {
    background: #c62828;
}

.circle md-icon {
    width: 36px;
    height: 36px;
    fill: white;
}

/* =========================
   LINE 2
   ========================= */

.ai-stepper-row.labels {
    margin-bottom: 32px;
}

.ai-stepper-row.labels .cell {
    text-align: center;
}

.title {
    font-size: 16px;
    font-weight: 500;
}

.progress {
    font-size: 14px;
    color: #77C6CB;
}

.progress.done {
    color: #A3D039;
    font-weight: 600;
}

.error-message {
    color: #c62828;
    font-weight: 300;
}

/* =========================
   LINE 3
   ========================= */

.ai-stepper-row.actions .cell {
    text-align: center;
}

/* =========================
   LINE 4
   ========================= */

.ai-stepper-row.data {
    flex: 1;
    min-height: 0;
    overflow: hidden;
    margin-top: 32px;
    align-items: stretch;
    gap: 10px;
}

.ai-stepper-row.data .cell {
    display: flex;
    flex-direction: column;
    min-height: 0;
}

.parameter-card {
    position: relative;
}

.ai-badge {
    position: absolute;
    top: 6px;
    right: 6px;

    background-color: #673ab7;
    color: #fff;

    font-size: 10px;
    font-weight: 600;
    letter-spacing: 0.5px;

    padding: 2px 6px;
    border-radius: 10px;

    text-transform: uppercase;
    pointer-events: none;
}

.ai-badge-inline {
    display: inline-block;
    margin-left: 6px;
    padding: 2px 6px;
    font-size: 10px;
    font-weight: 600;
    line-height: 1;
    border-radius: 10px;
    background-color: #673ab7;
    color: #fff;
    vertical-align: middle;
}

.data-container {
    flex: 1;
    overflow-y: auto;
    border: 1px solid #e0e0e0;
    border-radius: 4px;
    background: #fafafa;
}

.data-table {
    width: 100%;
    border-collapse: collapse;
    font-size: 13px;
}

.data-table th,
.data-table td {
    padding: 8px 10px;
    border-bottom: 1px solid #e0e0e0;
    text-align: left;
}

.data-table thead th {
    position: sticky;
    top: 0;
    background: #f5f5f5;
    font-weight: 600;
    z-index: 1;
}

.no-data {
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 13px;
    color: #9e9e9e;
    border: 1px dashed #e0e0e0;
    border-radius: 4px;
    background: #fafafa;
}

.run-pipeline-button {
    display: inline-flex;
    align-items: center;
}

.run-pipeline-button .pipeline-icon {
    font-size: 28px;
}

.run-pipeline-button:hover {
    transform: translateY(-1px);
}

.run-pipeline-button:active {
    transform: translateY(0);
}

.pipeline-confirm-overlay {
    position: absolute;
    inset: 0;
    background: rgba(0,0,0,0.55);
    z-index: 100;
    display: flex;
    align-items: center;
    justify-content: center;
}

.confirm-box {
    background: #fff;
    padding: 32px;
    border-radius: 8px;
    width: 480px;
    max-width: 90%;
}

.kpartialsolution-color {
    color: #A3D039;
}

.kproblem-color {
    color: #CC6600;
}

/*.margin-top {*/
/*    margin-top: 16px;*/
/*}*/

.md-table-bordered {
    width: 100%;
    border-collapse: collapse;
    background-color: #fafafa;
}

.md-table-bordered th,
.md-table-bordered td {
    border: 1px solid rgba(0, 0, 0, 0.12);
    padding: 8px 12px;
}

.md-table-bordered thead tr {
    background-color: rgba(0, 0, 0, 0.04);
}

.triz-param-card {
    margin-top: 12px;
    padding: 12px;
    border: 1px solid rgba(0, 0, 0, 0.12);
    border-radius: 4px;
    background-color: #fafafa;
}

/*.margin-top {*/
/*    margin-top: 16px;*/
/*}*/

/*.margin-bottom {*/
/*    margin-bottom: 12px;*/
/*}*/

.contradiction-summary {
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.contradiction-summary-compact {
    font-size: 13px;
    line-height: 1.4;
}

.pe-improved {
    color: #A3D039;
}

.pe-degraded {
    color: #CC6600;
}

.fixed-icon-button {
    min-width: 36px;
    width: 36px;
    height: 36px;

    display: flex;
    align-items: center;
    justify-content: center;

    flex-shrink: 0;
}

.fixed-icon-button md-icon {
    line-height: 24px;
    width: 24px;
    height: 24px;
}

.solution-summary {
    font-size: 14px;
    line-height: 1.4;
    font-weight: 500;
}

.solution-section {
    margin-top: 12px;
}

.solution-section-title {
    font-size: 13px;
    font-weight: 600;
    margin-bottom: 4px;
}

.solution-section-title.positive {
    color: #A3D039;
}

.solution-section-title.negative {
    color: #CC6600;
}

.solution-col {
    padding-right: 8px;
}

.schema-indicator {
    display: flex;
    align-items: center;
    gap: 6px;
    margin-top: 12px;
    color: rgba(0, 0, 0, 0.6);
}

.project-title {
    margin: 0 8px 0 0;
    white-space: nowrap;
}

.project-change-button {
    width: 40px;
    height: 40px;
}


