/* history.css */
.history-shell {
    flex: 1;
    max-width: 800px;
    width: 100%;
    margin: 0 auto;
    padding: 40px 20px;
}

.history-timeline {
    position: relative;
    padding-left: 20px;
}

.history-timeline::before {
    content: '';
    position: absolute;
    left: 5px;
    top: 15px;
    bottom: 15px;
    width: 2px;
    background: linear-gradient(to bottom, var(--primary), transparent);
    opacity: 0.5;
    border-radius: 2px;
}

.history-card {
    position: relative;
    margin-bottom: 14px;
}

.history-dot {
    position: absolute;
    left: -20px;
    top: 16px;
    width: 10px;
    height: 10px;
    border-radius: 50%;
    background: var(--primary);
    border: 2px solid var(--bg-base);
    box-shadow: 0 0 8px var(--primary-glow);
    z-index: 1;
}

.history-content {
    background: var(--bg-glass);
    border: 1px solid var(--border-line);
    border-radius: 12px;
    overflow: hidden;
    transition: border-color 0.25s;
}

.history-content:hover {
    border-color: var(--border-glow);
}

.history-head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 12px 16px;
    cursor: pointer;
    user-select: none;
    background: var(--bg-surface);
    transition: background 0.2s;
}

.history-head:hover {
    background: var(--bg-surface-hover);
}

.history-head-left {
    display: flex;
    align-items: center;
    gap: 10px;
    flex-wrap: wrap;
}

.version-tag {
    background: var(--primary);
    color: #fff;
    font-size: 0.75rem;
    padding: 2px 10px;
    border-radius: 20px;
    font-weight: 600;
    font-family: monospace;
}

.history-date {
    color: var(--text-dim);
    font-size: 0.8rem;
}

.history-title-inline {
    color: var(--text-bright);
    font-size: 0.9rem;
    font-weight: 500;
}

.history-arrow {
    color: var(--text-dim);
    font-size: 0.8rem;
    transition: transform 0.3s ease;
}

.history-card.open .history-arrow {
    transform: rotate(180deg);
    color: var(--primary);
}

.history-body {
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.35s ease, padding 0.35s ease;
    padding: 0 16px;
}

.history-card.open .history-body {
    max-height: 800px;
    padding: 16px;
}

.history-list {
    list-style: none;
    padding: 0;
    margin: 0;
    border-top: 1px dashed var(--border-line);
    padding-top: 10px;
}

.history-list li {
    color: var(--text-main);
    font-size: 0.88rem;
    line-height: 1.6;
    position: relative;
    padding-left: 16px;
    margin-bottom: 6px;
}

.history-list li::before {
    content: '▸';
    position: absolute;
    left: 0;
    color: var(--primary);
    font-size: 0.75rem;
    top: 3px;
}

.history-footer {
    text-align: center;
    color: var(--text-dim);
    font-size: 0.8rem;
    margin-top: 12px;
    opacity: 0.8;
}

/* 移动端适配 */
@media (max-width: 720px) {
    .history-shell { padding: 20px 16px; }
    .history-head-left { gap: 6px; }
    .history-title-inline { width: 100%; margin-top: 4px; }
}