/* 进度条样式 */
.progress-container {
    width: 100%;
    max-width: 640px;
    margin: 15px auto 0;
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    column-gap: 12px;
    row-gap: 10px;
    transition: opacity var(--motion-slow) var(--motion-ease);
}

.progress-container.fade-out {
    opacity: 0;
}

.progress-bar {
    flex: 1;
    min-width: 0;
    height: 10px;
    background-color: rgba(107, 93, 198, 0.15);
    border-radius: 10px;
    overflow: hidden;
    position: relative;
    isolation: isolate;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.05);
}

.progress-bar__steps {
    position: absolute;
    inset: 2px;
    display: flex;
    gap: 4px;
    z-index: 2;
    pointer-events: none;
}

.progress-bar__step {
    flex: 1 1 0;
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.18);
    transition: background-color var(--motion-base) var(--motion-ease),
        opacity var(--motion-base) var(--motion-ease);
    opacity: 0.95;
}

.progress-bar__step.is-complete,
.progress-bar__step.is-current {
    background: rgba(255, 255, 255, 0.46);
}

.progress-fill {
    height: 100%;
    width: 0%;
    /* 初始宽度 */
    background: linear-gradient(90deg, #3a7bd5 0%, #6d5dc6 100%);
    border-radius: 10px;
    transition: width var(--motion-base) var(--motion-ease);
    /* 更平滑的过渡 */
    box-shadow: 0 0 8px rgba(107, 93, 198, 0.5);
    position: absolute;
    top: 0;
    left: 0;
    overflow: hidden;
    z-index: 1;
}

.progress-text {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 34px;
    padding: 0 12px;
    border-radius: 999px;
    background: rgba(109, 93, 198, 0.09);
    color: #5246a8;
    font-size: 13px;
    font-weight: 700;
    font-variant-numeric: tabular-nums;
    letter-spacing: 0.01em;
    white-space: nowrap;
}

.progress-status {
    width: 100%;
    font-size: 12px;
    line-height: 1.6;
    color: #566172;
    text-align: left;
}

.progress-queue-card {
    width: 100%;
    padding: 12px 14px;
    border-radius: 14px;
    background: linear-gradient(135deg, rgba(58, 123, 213, 0.08) 0%, rgba(109, 93, 198, 0.08) 100%);
    border: 1px solid rgba(109, 93, 198, 0.16);
    box-shadow: 0 10px 24px rgba(58, 123, 213, 0.08);
}

.progress-queue-card__top {
    display: flex;
    align-items: center;
    gap: 10px;
    flex-wrap: wrap;
}

.progress-queue-badge {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 68px;
    height: 28px;
    padding: 0 10px;
    border-radius: 999px;
    background: rgba(59, 130, 246, 0.12);
    color: #1d4ed8;
    font-size: 12px;
    font-weight: 700;
    letter-spacing: 0.02em;
}

.progress-queue-card[data-queue-status="running"] .progress-queue-badge,
.progress-queue-card[data-queue-status="running_worker"] .progress-queue-badge,
.progress-queue-card[data-queue-status="accepted_inline"] .progress-queue-badge {
    background: rgba(16, 185, 129, 0.14);
    color: #047857;
}

.progress-queue-card[data-queue-status="retry"] .progress-queue-badge,
.progress-queue-card[data-queue-status="retrying_worker"] .progress-queue-badge {
    background: rgba(245, 158, 11, 0.16);
    color: #b45309;
}

.progress-queue-card[data-queue-status="waiting_ai_gate"] .progress-queue-badge {
    background: rgba(59, 130, 246, 0.16);
    color: #1d4ed8;
}

.progress-queue-title {
    font-size: 13px;
    font-weight: 600;
    color: #24324a;
}

.progress-queue-card__metrics {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-top: 10px;
}

.progress-queue-metric {
    display: inline-flex;
    align-items: center;
    min-height: 32px;
    padding: 0 10px;
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.82);
    color: #334155;
    font-size: 12px;
    font-weight: 600;
}

.progress-queue-hint {
    margin-top: 10px;
    font-size: 12px;
    line-height: 1.6;
    color: #5b6473;
}

@media (max-width: 640px) {
    .progress-container {
        row-gap: 10px;
    }

    .progress-text {
        width: 100%;
        justify-content: center;
    }

    .progress-queue-card {
        padding: 11px 12px;
    }

    .progress-queue-card__metrics {
        gap: 6px;
    }

    .progress-queue-metric {
        width: 100%;
        justify-content: flex-start;
    }
}

/* 禁用按钮样式 */
.btn:disabled {
    opacity: 0.7;
    cursor: not-allowed;
    transform: none !important;
    box-shadow: none !important;
}

.btn.platform-lang-locked {
    background: #94a3b8 !important;
    border-color: #94a3b8 !important;
    color: #f8fafc !important;
    box-shadow: none !important;
}



/* 进度条保持静态质感，避免流动渐变噪音 */

/* 进度条完成时的特殊效果 */
.progress-fill.completed {
    background: linear-gradient(90deg, #28a745 0%, #20c997 100%);
    animation: progress-complete var(--motion-slow) var(--motion-ease);
}

@keyframes progress-complete {
    0% {
        transform: scaleY(1);
        filter: brightness(1);
    }

    50% {
        transform: scaleY(1.04);
        filter: brightness(1.1);
    }

    100% {
        transform: scaleY(1);
        filter: brightness(1);
    }
}
