.timeline {
    width: 100%;
    height: 20px;
    background-color: var(--heo-background);
    position: relative;
    overflow: hidden;
    margin-bottom: 20px;
    border-radius: 0.5rem;
    height: 2.5rem;
}

.progress {
    width: 0;
    height: 100%;
    background-color: var(--heo-main);
    position: absolute;
    animation: progressAnimation 2s linear forwards;
    animation-delay: -0.1s;
    border-radius: 0.5rem
}

.past-time {
    width: 2px;
    height: 20px;
    background-color: #3498db;
    position: absolute;
    transform-origin: left;
    animation: pastTimeAnimation 3s linear forwards;
}

.percentage-label {
    position: absolute;
    left: 0;
    font-size: 14px;
    color: var(--heo-card-bg);
    font-weight: bold;
    top: 10px;
    white-space: nowrap;
    transition: left 0.5s linear;
    visibility: hidden;
}

/* 新增：进度条中部信息容器 */
.progress-info {
    position: absolute;
    inset: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: .75rem;
    pointer-events: none;
    z-index: 2;
}

/* 新增：信息文字样式，适配深浅色模式 */
.progress-info .progress-percentage,
.progress-info .progress-days,
.progress-info .progress-date {
    font-weight: 700;
    line-height: 1;
    color: var(--heo-card-bg);
    text-shadow: 0 1px 2px rgba(0,0,0,.35);
    letter-spacing: .3px;
}

/* 深色背景上做轻微描边提升可读性 */
@media (prefers-color-scheme: dark) {
    .progress-info .progress-percentage,
    .progress-info .progress-days,
    .progress-info .progress-date {
        color: #fff;
        text-shadow: 0 2px 8px rgba(0,0,0,.45);
    }
}

/* 浅色模式下，适配更柔和的文字颜色 */
@media (prefers-color-scheme: light) {
    .progress-info .progress-percentage,
    .progress-info .progress-days,
    .progress-info .progress-date {
        color: #1f2937;
        text-shadow: 0 1px 1px rgba(255,255,255,.5), 0 1px 3px rgba(0,0,0,.2);
    }
}

.time-labels {
    display: flex;
    justify-content: space-between;
    width: 100%;
}

.time-labels>div {
    font-size: 14px;
    color: var(--heo-fontcolor);
}

@keyframes progressAnimation {
    0% {
        width: 0;
    }
    100% {
        width: var(--progress-percentage, 0);
    }
}

@keyframes pastTimeAnimation {
    0% {
        transform: scaleX(0);
    }
    100% {
        transform: scaleX(var(--past-time-percentage, 0));
    }
}

.timeline:hover {
    animation: btn31-eff 3s linear infinite;
    cursor: pointer;
}

@keyframes btn31-eff {
    0% {
        box-shadow: 0 0 2px var(--heo-main);
    }
    50% {
        box-shadow: 0 0 40px var(--heo-main);
    }
    100% {
        box-shadow: 0 0 2px var(--heo-main);
    }
}