body {
    font-family: 'Roboto', sans-serif;
    background-color: #1a1a2e;
    color: #e0e0e0;
}

.title-font {
    font-family: 'Orbitron', sans-serif;
}

/* Timeline container */
.timeline {
    position: relative;
    max-width: 1200px;
    margin: 0 auto;
}

/* The vertical line */
.timeline::after {
    content: '';
    position: absolute;
    width: 6px;
    background-color: #4a4a7c;
    top: 0;
    bottom: 0;
    left: 50%;
    margin-left: -3px;
    border-radius: 3px;
    animation: grow-line 2s ease-out forwards;
}

@keyframes grow-line {
    from { height: 0; }
    to { height: 100%; }
}

/* Container around content */
.timeline-container {
    padding: 10px 40px;
    position: relative;
    background-color: inherit;
    width: 50%;
    opacity: 0;
    animation: fade-in 0.5s forwards;
}

/* Stagger the fade-in animation for each item */
.timeline-container:nth-child(1) { animation-delay: 0.2s; }
.timeline-container:nth-child(2) { animation-delay: 0.4s; }
.timeline-container:nth-child(3) { animation-delay: 0.6s; }
.timeline-container:nth-child(4) { animation-delay: 0.8s; }
.timeline-container:nth-child(5) { animation-delay: 1.0s; }
.timeline-container:nth-child(6) { animation-delay: 1.2s; }
.timeline-container:nth-child(7) { animation-delay: 1.4s; }
.timeline-container:nth-child(8) { animation-delay: 1.6s; }
.timeline-container:nth-child(9) { animation-delay: 1.8s; }
.timeline-container:nth-child(10) { animation-delay: 2.0s; }
.timeline-container:nth-child(11) { animation-delay: 2.2s; }
.timeline-container:nth-child(12) { animation-delay: 2.4s; }
.timeline-container:nth-child(13) { animation-delay: 2.6s; }
.timeline-container:nth-child(14) { animation-delay: 2.8s; }
.timeline-container:nth-child(15) { animation-delay: 3.0s; }
.timeline-container:nth-child(16) { animation-delay: 3.2s; }
.timeline-container:nth-child(17) { animation-delay: 3.4s; }
.timeline-container:nth-child(18) { animation-delay: 3.6s; }
.timeline-container:nth-child(19) { animation-delay: 3.8s; }
.timeline-container:nth-child(20) { animation-delay: 4.0s; }
/* Additional children will need to have their animation delay set by JS */

@keyframes fade-in {
    from { opacity: 0; transform: translateY(20px); }
    to { opacity: 1; transform: translateY(0); }
}

/* The circles on the timeline */
.timeline-container::after {
    content: '';
    position: absolute;
    width: 25px;
    height: 25px;
    right: -12px;
    background-color: #162447;
    border: 4px solid #eebbc3;
    top: 15px;
    border-radius: 50%;
    z-index: 1;
    transition: transform 0.3s ease, background-color 0.3s ease;
}

.timeline-container:hover::after {
    transform: scale(1.2);
    background-color: #eebbc3;
}

/* Place the container to the left */
.left {
    left: 0;
}

/* Place the container to the right */
.right {
    left: 50%;
}

/* Add arrows to the left container (pointing right) */
.left::before {
    content: " ";
    height: 0;
    position: absolute;
    top: 22px;
    width: 0;
    z-index: 1;
    right: 30px;
    border: medium solid #2b2e4a;
    border-width: 10px 0 10px 10px;
    border-color: transparent transparent transparent #2b2e4a;
}

/* Add arrows to the right container (pointing left) */
.right::before {
    content: " ";
    height: 0;
    position: absolute;
    top: 22px;
    width: 0;
    z-index: 1;
    left: 30px;
    border: medium solid #2b2e4a;
    border-width: 10px 10px 10px 0;
    border-color: transparent #2b2e4a transparent transparent;
}

/* Fix the circle for containers on the right side */
.right::after {
    left: -13px;
}

/* The actual content */
.content {
    padding: 20px 30px;
    background-color: #2b2e4a;
    position: relative;
    border-radius: 8px;
    border: 1px solid #4a4a7c;
    box-shadow: 0 4px 15px rgba(0,0,0,0.2);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.content:hover {
    transform: translateY(-5px);
    box-shadow: 0 8px 25px rgba(238, 187, 195, 0.2);
}

/* Media queries - Responsive layout */
@media screen and (max-width: 600px) {
    /* Full-width timeline */
    .timeline::after {
        left: 31px;
    }

    /* Full-width containers */
    .timeline-container {
        width: 100%;
        padding-left: 70px;
        padding-right: 25px;
    }

    /* Make sure that all arrows are pointing leftwards */
    .timeline-container::before {
        left: 60px;
        border: medium solid #2b2e4a;
        border-width: 10px 10px 10px 0;
        border-color: transparent #2b2e4a transparent transparent;
    }

    /* Make sure all circles are at the same spot */
    .left::after, .right::after {
        left: 18px;
    }

    /* Make all containers behave like the right ones */
    .right {
        left: 0%;
    }
}

/* Game Cover Art Styling */
.game-cover-art {
    max-width: 100%; /* Ensure image is responsive within its container */
    height: auto; /* Maintain aspect ratio */
    margin-top: 15px; /* Space above the image */
    border-radius: 6px; /* Slightly rounded corners for the images */
    opacity: 0; /* Start fully transparent */
    transition: opacity 0.75s ease-in-out; /* Smooth transition for opacity */
    display: block; /* Ensure it takes up its own line if needed */
}

.game-cover-art.visible {
    opacity: 1; /* Fully visible */
}
