/**
 * firmware.css — 固件升级面板样式
 *
 * 复用 card / btn / progress-bar 基础样式，只定义固件面板专属样式
 */

/* ── 固件信息网格 ── */
.firmware-panel .fw-info-grid {
    display: grid;
    grid-template-columns: auto 1fr;
    gap: 6px 20px;
    font-size: 15px;
    margin-top: 8px;
}

.firmware-panel .fw-info-label {
    color: var(--text-muted, #6b7280);
    white-space: nowrap;
}

.firmware-panel .fw-info-value {
    font-weight: 600;
    word-break: break-all;
}

/* ── 进度条 ── */
.firmware-panel .fw-progress-wrap {
    margin-top: 10px;
}

.firmware-panel .fw-progress-bar {
    height: 14px;
    background: var(--bg-tertiary, #e5e7eb);
    border-radius: 7px;
    overflow: hidden;
}

.firmware-panel .fw-progress-fill {
    height: 100%;
    width: 0%;
    background: linear-gradient(90deg, #3b82f6, #2563eb);
    border-radius: 7px;
    transition: width 0.3s ease;
}

.firmware-panel .fw-progress-info {
    display: flex;
    justify-content: space-between;
    margin-top: 6px;
    font-size: 14px;
}

.firmware-panel .fw-progress-pct {
    font-weight: 700;
    color: var(--accent, #3b82f6);
}

.firmware-panel .fw-progress-seq {
    color: var(--text-muted, #6b7280);
}

/* ── 大号百分比数字动画 ── */
.firmware-panel .fw-pct-number {
    font-size: 56px;
    font-weight: 800;
    color: var(--accent, #3b82f6);
    font-variant-numeric: tabular-nums;
    transition: transform 0.15s ease, color 0.3s ease;
    display: inline-block;
}

.firmware-panel .fw-pct-number.pulse {
    animation: fw-pulse 0.6s ease-in-out;
}

@keyframes fw-pulse {
    0% { transform: scale(1); }
    50% { transform: scale(1.15); }
    100% { transform: scale(1); }
}

/* ── 状态消息 ── */
.firmware-panel .fw-status {
    margin-top: 8px;
    font-size: 15px;
    padding: 8px 12px;
    border-radius: 6px;
}

.firmware-panel .fw-status.ok {
    color: #059669;
    background: #ecfdf5;
}

.firmware-panel .fw-status.err {
    color: #dc2626;
    background: #fef2f2;
}

.firmware-panel .fw-status.busy {
    color: #2563eb;
    background: #eff6ff;
}

/* ── 工具条 ── */
.firmware-panel .fw-toolbar {
    display: flex;
    align-items: center;
    gap: 12px;
    flex-wrap: wrap;
    margin-bottom: 16px;
}

.firmware-panel .fw-file-input {
    flex: 1;
    padding: 6px 0;
    font-size: 15px;
}

/* ── 警告框 ── */
.firmware-panel .fw-warning {
    margin-top: 12px;
    padding: 12px 16px;
    background: #fef3c7;
    border: 1px solid #f59e0b;
    border-radius: 8px;
    font-size: 14px;
    color: #92400e;
    line-height: 1.6;
}
