* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html, body {
    height: 100%;
    overflow-x: hidden;
}

body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    margin: 0;
    padding: 0;
    display: flex;
    justify-content: center;
    min-height: 100vh;
    background-color: #f5f5f5;
    color: #333;
}

/* Animated background - fixed position */
.bg-animation {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: -1;
}

/* Page wrapper - scrollable content */
.page-wrapper {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    width: 100%;
    max-width: 100%;
    padding: 2rem 1rem;
    overflow-x: hidden;
    min-height: 100vh;
    transition: all 0.8s cubic-bezier(0.22, 1, 0.36, 1);
}

/* Content container with slight glass morphism */
.container {
    background-color: rgba(255, 255, 255, 0.9);
    border-radius: 12px;
    box-shadow: 0 8px 30px rgba(0, 0, 0, 0.1);
    padding: 2rem;
    margin-bottom: 2rem;
    width: 100%;
    max-width: 800px;
    position: relative;
    transition: transform 0.7s cubic-bezier(0.22, 1, 0.36, 1), 
                opacity 0.7s cubic-bezier(0.22, 1, 0.36, 1), 
                box-shadow 0.7s cubic-bezier(0.22, 1, 0.36, 1);
}

/* Main profile card */
.main-card {
    text-align: center;
    z-index: 10;
    margin-bottom: 0;
    transition: transform 0.8s cubic-bezier(0.22, 1, 0.36, 1), 
                margin-top 0.8s cubic-bezier(0.22, 1, 0.36, 1), 
                box-shadow 0.8s cubic-bezier(0.22, 1, 0.36, 1),
                background-color 0.8s cubic-bezier(0.22, 1, 0.36, 1);
    will-change: transform, margin-top, box-shadow, background-color;
}

/* Main card when content is visible - moves up with animation */
.main-card.content-visible {
    transform: scale(0.95) translateY(-1.5rem);
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.08);
    background-color: rgba(255, 255, 255, 0.95);
}

/* Content cards container */
#content-cards {
    width: 100%;
    display: flex;
    flex-direction: column;
    align-items: center;
    margin-top: 2rem;
    position: relative;
}

/* Individual content cards */
.content-card {
    opacity: 0;
    transform: translateY(30px);
    max-height: 0;
    overflow: hidden;
    padding-top: 0;
    padding-bottom: 0;
    margin-top: 0;
    margin-bottom: 0;
    transition: opacity 0.8s cubic-bezier(0.22, 1, 0.36, 1), 
                transform 0.8s cubic-bezier(0.22, 1, 0.36, 1), 
                max-height 0.8s cubic-bezier(0.22, 1, 0.36, 1), 
                padding 0.6s cubic-bezier(0.22, 1, 0.36, 1), 
                margin 0.6s cubic-bezier(0.22, 1, 0.36, 1);
    position: absolute;
    width: 100%;
    max-width: 800px;
    will-change: opacity, transform, max-height;
}

/* Active content card */
.content-card.active {
    opacity: 1;
    transform: translateY(0);
    max-height: 2000px;
    padding: 2rem;
    margin-bottom: 2rem;
    overflow: auto;
    position: relative;
}

.name {
    font-size: 2.5rem;
    margin-bottom: 0.5rem;
    color: #222;
}

.slogan {
    font-size: 1.2rem;
    margin-bottom: 2rem;
    color: #666;
}

.buttons {
    display: flex;
    justify-content: center;
    gap: 1rem;
    margin-bottom: 1rem;
    flex-wrap: wrap;
}

.btn {
    padding: 0.8rem 1.5rem;
    border: none;
    border-radius: 30px;
    font-size: 1rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.4s cubic-bezier(0.22, 1, 0.36, 1);
    will-change: transform, box-shadow, background-color;
}

.btn-primary {
    background-color: #4361ee;
    color: white;
}

.btn-primary:hover {
    background-color: #3a56d4;
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(67, 97, 238, 0.3);
}

.btn-secondary {
    background-color: #f72585;
    color: white;
}

.btn-secondary:hover {
    background-color: #e91e79;
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(247, 37, 133, 0.3);
}

/* Close button */
.close-btn {
    position: absolute;
    top: 1rem;
    right: 1rem;
    background: none;
    border: none;
    font-size: 1.5rem;
    color: #777;
    cursor: pointer;
    transition: color 0.3s ease;
    width: 2rem;
    height: 2rem;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
}

.close-btn:hover {
    color: #222;
    background-color: rgba(0, 0, 0, 0.05);
}

/* Loader */
.loader {
    display: none;
    width: 50px;
    height: 50px;
    border: 5px solid rgba(67, 97, 238, 0.2);
    border-radius: 50%;
    border-top-color: #4361ee;
    animation: spin 1s ease-in-out infinite;
    margin: 2rem auto;
}

@keyframes spin {
    to { transform: rotate(360deg); }
}

/* Content sections */
.content-card h2 {
    color: #333;
    margin-bottom: 1.5rem;
    padding-bottom: 0.5rem;
    border-bottom: 2px solid #4361ee;
}

/* Footer for extra content to enable scrolling */
.footer {
    margin-top: 1rem;
    padding: 1rem;
    text-align: center;
    color: #777;
    font-size: 0.9rem;
    width: 100%;
    max-width: 800px;
}

/* Responsive styles */
@media (max-width: 768px) {
    .container {
        padding: 1.5rem;
    }
    
    .name {
        font-size: 2rem;
    }
    
    .slogan {
        font-size: 1rem;
    }
    
    .btn {
        padding: 0.7rem 1.2rem;
        font-size: 0.9rem;
    }
}

@media (max-width: 480px) {
    .buttons {
        flex-direction: column;
        width: 100%;
    }
    
    .btn {
        width: 100%;
        margin-bottom: 0.5rem;
    }
}

/* Work experience and project items */
.experience-item,
.project-item {
    padding: 1.5rem;
    margin-bottom: 1.5rem;
    border-radius: 8px;
    background-color: rgba(255, 255, 255, 0.6);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.05);
    transition: transform 0.5s cubic-bezier(0.22, 1, 0.36, 1), 
                box-shadow 0.5s cubic-bezier(0.22, 1, 0.36, 1),
                opacity 0.5s cubic-bezier(0.22, 1, 0.36, 1);
    will-change: transform, box-shadow, opacity;
    opacity: 0;
    transform: translateY(20px);
}

/* Animation for work and project items when their container becomes active */
.content-card.active .experience-item,
.content-card.active .project-item {
    opacity: 1;
    transform: translateY(0);
}

/* Hover effects for work and project items */
.experience-item:hover,
.project-item:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 16px rgba(0, 0, 0, 0.1);
}

/* Staggered animation delay for sequential items */
.content-card.active .experience-item:nth-child(1),
.content-card.active .project-item:nth-child(1) {
    transition-delay: 0.1s;
}

.content-card.active .experience-item:nth-child(2),
.content-card.active .project-item:nth-child(2) {
    transition-delay: 0.2s;
}

.content-card.active .experience-item:nth-child(3),
.content-card.active .project-item:nth-child(3) {
    transition-delay: 0.3s;
}

.content-card.active .experience-item:nth-child(4),
.content-card.active .project-item:nth-child(4) {
    transition-delay: 0.4s;
}

.content-card.active .experience-item:nth-child(5),
.content-card.active .project-item:nth-child(5) {
    transition-delay: 0.5s;
}

.item-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    margin-bottom: 0.8rem;
}

.item-title {
    font-size: 1.2rem;
    font-weight: 600;
    color: #333;
    margin-bottom: 0.2rem;
}

.item-subtitle {
    font-size: 1rem;
    color: #555;
    margin-bottom: 0.5rem;
}

.item-period {
    font-size: 0.9rem;
    color: #777;
    white-space: nowrap;
    font-style: italic;
}

.item-description {
    font-size: 0.95rem;
    line-height: 1.5;
    color: #444;
    margin-bottom: 1rem;
}

.item-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
}

.tag {
    padding: 0.3rem 0.8rem;
    background-color: rgba(67, 97, 238, 0.1);
    color: #4361ee;
    border-radius: 30px;
    font-size: 0.8rem;
    font-weight: 500;
    white-space: nowrap;
}

/* Last item in the list */
.experience-item:last-child,
.project-item:last-child {
    margin-bottom: 0;
} 