body {
    background: #0f172a;
    height: 100vh;
    display: flex;
    justify-content: center;
    align-items: center;
    margin: 0;
    font-family: 'Segoe UI', sans-serif;
    perspective: 1500px;
}

.archive-container {
    width: 350px;
    height: 250px;
    cursor: pointer;
}

.folder {
    position: relative;
    width: 100%;
    height: 100%;
    transform-style: preserve-3d;
    transition: transform 0.6s ease;
    transform: rotateX(10deg);
}

/* THE FOLDER FRONT FLAP */
.folder-front {
    position: absolute;
    width: 100%;
    height: 100%;
    background: rgba(230, 227, 15, 0.1);
    backdrop-filter: blur(15px);
    border: 1px solid rgba(255, 255, 255, 0.2);
    border-radius: 0 15px 15px 15px;
    z-index: 10;
    transform-origin: bottom;
    transition: transform 0.8s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    display: flex;
    justify-content: center;
    align-items: center;
    color: white;
}

.folder-tab {
    position: absolute;
    top: -20px;
    left: 0;
    width: 100px;
    height: 20px;
    background: rgba(255, 255, 255, 0.15);
    border-radius: 10px 10px 0 0;
}

/* THE EXPERIENCE CARDS */
.experience-card {
    position: absolute;
    width: 90%;
    height: 120px;
    left: 5%;
    bottom: 20px;
    background: white;
    border-radius: 10px;
    padding: 20px;
    box-sizing: border-box;
    transition: transform 0.6s ease, opacity 0.4s;
    opacity: 0;
    z-index: 5;
    box-shadow: 0 10px 30px rgba(0,0,0,0.3);
    border-left: 8px solid var(--bg);
}

.experience-card h3 { margin: 0; color: #334155; font-size: 1.2rem; }
.experience-card p { margin: 5px 0 0; color: #64748b; font-weight: 600; }

/* HOVER LOGIC */

/* 1. Open the folder flap */
.archive-container:hover .folder-front {
    transform: rotateX(-80deg);
}

/* 2. Slide the cards out at different heights */
.archive-container:hover .experience-card {
    opacity: 1;
    /* Cards slide out and stagger in 3D space */
    transform: translateY(calc(var(--i) * -80px)) translateZ(calc(var(--i) * 20px)) scale(calc(1 - var(--i) * 0.05));
}

.folder-back {
    position: absolute;
    width: 100%;
    height: 100%;
    background: rgba(255, 255, 255, 0.05);
    border-radius: 0 15px 15px 15px;
    border: 1px solid rgba(255, 255, 255, 0.1);
    z-index: 1;
}

.folder-content h2 { font-size: 1.5rem; letter-spacing: 2px; }
.folder-content span { font-size: 0.8rem; opacity: 0.6; }