/* changelogs.css - Material Design 3 Timeline Changelog */

/* ========== CONTAINER ========== */
.changelog-container {
    max-width: 900px;
    margin: 0 auto;
    padding: 3rem 2rem;
    position: relative;
}

.changelog-header {
    text-align: center;
    margin-bottom: 4rem;
}

.changelog-header h1 {
    font-size: 3.5rem;
    font-weight: 900;
    color: #1C1B1F;
    margin: 0 0 1rem 0;
    letter-spacing: -0.02em;
}

.changelog-header p {
    font-size: 1.1rem;
    color: #49454F;
    margin: 0;
}

/* ========== TIMELINE ========== */
.timeline {
    position: relative;
    padding-left: 80px;
}

/* Vertical line */
.timeline::before {
    content: '';
    position: absolute;
    left: 30px;
    top: 0;
    bottom: 0;
    width: 3px;
    background: linear-gradient(180deg, #6750A4 0%, #E7E0EC 100%);
}

/* ========== VERSION CARDS ========== */
.version-card {
    position: relative;
    margin-bottom: 3rem;
    animation: fadeInUp 0.6s ease-out backwards;
}

.version-card:nth-child(1) {
    animation-delay: 0.1s;
}

.version-card:nth-child(2) {
    animation-delay: 0.2s;
}

.version-card:nth-child(3) {
    animation-delay: 0.3s;
}

.version-card:nth-child(4) {
    animation-delay: 0.4s;
}

.version-card:nth-child(5) {
    animation-delay: 0.5s;
}

/* Timeline node */
.timeline-node {
    position: absolute;
    left: -80px;
    top: 8px;
    width: 60px;
    height: 60px;
    background: #6750A4;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 4px 8px 3px rgba(0, 0, 0, 0.15), 0 1px 3px rgba(0, 0, 0, 0.3);
    z-index: 2;
}

.timeline-node::before {
    content: '';
    position: absolute;
    width: 70px;
    height: 70px;
    background: rgba(103, 80, 164, 0.1);
    border-radius: 50%;
    animation: pulse 2s ease-in-out infinite;
}

.version-number {
    font-size: 0.75rem;
    font-weight: 700;
    color: #FFFFFF;
    z-index: 1;
    text-align: center;
    line-height: 1.2;
}

/* Card content */
.card-content {
    background: #FFFBFE;
    border-radius: 16px;
    padding: 2rem;
    box-shadow: 0 1px 2px rgba(0, 0, 0, 0.3), 0 1px 3px 1px rgba(0, 0, 0, 0.15);
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    border: 1px solid #E7E0EC;
}

.card-content:hover {
    box-shadow: 0 2px 6px 2px rgba(0, 0, 0, 0.15), 0 1px 2px rgba(0, 0, 0, 0.3);
    transform: translateY(-2px);
    border-color: #D0BCFF;
}

/* Card header */
.card-header {
    margin-bottom: 1.5rem;
    padding-bottom: 1rem;
    border-bottom: 1px solid #E7E0EC;
}

.card-header h2 {
    font-size: 1.75rem;
    font-weight: 700;
    color: #1C1B1F;
    margin: 0 0 0.5rem 0;
}

.release-date {
    font-size: 0.95rem;
    color: #49454F;
    margin: 0 0 0.75rem 0;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.release-date i {
    color: #6750A4;
}

.release-badge {
    display: inline-block;
    background: linear-gradient(135deg, #6750A4, #7F67BE);
    color: #FFFFFF;
    padding: 0.4rem 1rem;
    border-radius: 20px;
    font-size: 0.85rem;
    font-weight: 600;
    letter-spacing: 0.02em;
}

/* ========== CHANGES LIST ========== */
.changes-list {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.change-item {
    display: flex;
    gap: 1rem;
    align-items: flex-start;
    padding: 0.75rem;
    border-radius: 8px;
    transition: background 0.2s;
}

.change-item:hover {
    background: #F7F2FA;
}

.change-item i {
    flex-shrink: 0;
    width: 24px;
    height: 24px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1rem;
    margin-top: 2px;
}

.change-content {
    flex: 1;
    font-size: 1rem;
    line-height: 1.6;
    color: #1C1B1F;
}

.change-content strong {
    color: #1C1B1F;
    font-weight: 600;
}

.change-content ul {
    margin: 0.5rem 0 0 0;
    padding-left: 1.5rem;
}

.change-content ul li {
    margin-bottom: 0.5rem;
    color: #49454F;
}

.change-content code {
    background: #E7E0EC;
    color: #6750A4;
    padding: 0.2rem 0.4rem;
    border-radius: 4px;
    font-size: 0.9em;
    font-family: 'Courier New', monospace;
}

/* ========== CHANGE TYPE ICONS ========== */
.change-item[data-type="feature"] i {
    color: #6750A4;
}

.change-item[data-type="bug"] i {
    color: #BA1A1A;
}

.change-item[data-type="performance"] i {
    color: #006E26;
}

.change-item[data-type="ui"] i {
    color: #0061A4;
}

.change-item[data-type="security"] i {
    color: #8B5000;
}

.change-item[data-type="docs"] i {
    color: #49454F;
}

.change-item[data-type="maintenance"] i {
    color: #625B71;
}

/* ========== VERSION TYPE VARIANTS ========== */
.version-card[data-version-type="major"] .timeline-node {
    background: linear-gradient(135deg, #6750A4, #7F67BE);
}

.version-card[data-version-type="minor"] .timeline-node {
    background: linear-gradient(135deg, #0061A4, #4285F4);
}

.version-card[data-version-type="patch"] .timeline-node {
    background: linear-gradient(135deg, #006E26, #4CAF50);
}

/* Latest version highlight */
.version-card.latest .card-content {
    border: 2px solid #6750A4;
    box-shadow: 0 2px 6px 2px rgba(103, 80, 164, 0.2), 0 1px 2px rgba(0, 0, 0, 0.3);
}

.version-card.latest .timeline-node {
    animation: pulseGlow 2s ease-in-out infinite;
}

/* ========== ANIMATIONS ========== */
@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes pulse {

    0%,
    100% {
        transform: scale(1);
        opacity: 0.3;
    }

    50% {
        transform: scale(1.1);
        opacity: 0.1;
    }
}

@keyframes pulseGlow {

    0%,
    100% {
        box-shadow: 0 4px 8px 3px rgba(103, 80, 164, 0.3), 0 1px 3px rgba(103, 80, 164, 0.5);
    }

    50% {
        box-shadow: 0 4px 12px 6px rgba(103, 80, 164, 0.4), 0 1px 3px rgba(103, 80, 164, 0.6);
    }
}

/* ========== RESPONSIVE DESIGN ========== */
@media (max-width: 768px) {
    .changelog-container {
        padding: 2rem 1rem;
    }

    .changelog-header h1 {
        font-size: 2.5rem;
    }

    .timeline {
        padding-left: 60px;
    }

    .timeline::before {
        left: 20px;
    }

    .timeline-node {
        left: -60px;
        width: 40px;
        height: 40px;
    }

    .timeline-node::before {
        width: 50px;
        height: 50px;
    }

    .version-number {
        font-size: 0.65rem;
    }

    .card-content {
        padding: 1.5rem;
    }

    .card-header h2 {
        font-size: 1.5rem;
    }

    .release-badge {
        font-size: 0.75rem;
        padding: 0.3rem 0.75rem;
    }
}

@media (max-width: 480px) {
    .changelog-header h1 {
        font-size: 2rem;
    }

    .timeline {
        padding-left: 40px;
    }

    .timeline::before {
        left: 10px;
    }

    .timeline-node {
        left: -40px;
        width: 32px;
        height: 32px;
    }

    .version-number {
        font-size: 0.55rem;
    }

    .card-content {
        padding: 1.25rem;
    }

    .change-item {
        flex-direction: column;
        gap: 0.5rem;
    }
}