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

:root {
    --bg-primary: #0a0a0a;
    --bg-secondary: #111111;
    --bg-card: #1a1a1a;
    --text-primary: #ffffff;
    --text-secondary: #a0a0a0;
    --accent: #00d4ff;
    --accent-hover: #00b8e6;
    --gradient: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    --shadow: 0 20px 40px rgba(0, 212, 255, 0.1);
}

body {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
    background: var(--bg-primary);
    color: var(--text-primary);
    line-height: 1.6;
    overflow-x: hidden;
}

/* Animated background */
.bg-animated {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: -1;
    background: radial-gradient(circle at 20% 50%, #00d4ff15 0%, transparent 50%),
                radial-gradient(circle at 80% 20%, #667eea15 0%, transparent 50%),
                radial-gradient(circle at 40% 80%, #764ba215 0%, transparent 50%);
    animation: bgMove 20s ease-in-out infinite;
}

@keyframes bgMove {
    0%, 100% { transform: translateY(0px) rotate(0deg); }
    50% { transform: translateY(-20px) rotate(2deg); }
}

/* Navigation */
nav {
    position: fixed;
    top: 0;
    width: 100%;
    background: rgba(10, 10, 10, 0.9);
    backdrop-filter: blur(20px);
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
    z-index: 1000;
    padding: 1rem 2rem;
    transition: all 0.3s ease;
}

nav.scrolled {
    background: rgba(10, 10, 10, 0.95);
    box-shadow: var(--shadow);
}

.nav-container {
    display: flex;
    justify-content: space-between;
    align-items: center;
    max-width: 1200px;
    margin: 0 auto;
}

.logo {
    font-size: 1.5rem;
    font-weight: 700;
    background: var(--gradient);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.nav-links {
    display: flex;
    gap: 2rem;
    list-style: none;
}

.nav-links a {
    color: var(--text-secondary);
    text-decoration: none;
    transition: all 0.3s ease;
    position: relative;
    padding: 0.5rem 0;
}

.nav-links a:hover {
    color: var(--accent);
}

.nav-links a::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 0;
    height: 2px;
    background: var(--accent);
    transition: width 0.3s ease;
}

.nav-links a:hover::after {
    width: 100%;
}

/* Hero Section */
.hero {
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    padding: 2rem;
    position: relative;
}

.hero-content {
    max-width: 800px;
    animation: fadeInUp 1s ease-out;
}

.profile-image {
    width: 200px;
    height: 200px;
    border-radius: 50%;
    object-fit: cover;
    border: 4px solid var(--accent);
    box-shadow: var(--shadow);
    margin-bottom: 2rem;
    transition: transform 0.3s ease;
}

.profile-image:hover {
    transform: scale(1.05);
}

.hero h1 {
    font-size: 3.5rem;
    font-weight: 800;
    margin-bottom: 1rem;
    background: var(--gradient);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.hero .subtitle {
    font-size: 1.5rem;
    color: var(--accent);
    margin-bottom: 1rem;
}

.hero p {
    font-size: 1.1rem;
    color: var(--text-secondary);
    margin-bottom: 2rem;
    line-height: 1.8;
}

.cta-button {
    display: inline-block;
    padding: 1rem 2rem;
    background: var(--gradient);
    color: white;
    text-decoration: none;
    border-radius: 50px;
    font-weight: 600;
    transition: all 0.3s ease;
    box-shadow: var(--shadow);
}

.cta-button:hover {
    transform: translateY(-2px);
    box-shadow: 0 25px 50px rgba(0, 212, 255, 0.2);
}

/* Section Styles */
section {
    padding: 5rem 2rem;
    max-width: 1200px;
    margin: 0 auto;
}

.section-title {
    font-size: 2.5rem;
    font-weight: 700;
    text-align: center;
    margin-bottom: 3rem;
    background: var(--gradient);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

/* Education Section */
.education-grid {
    display: grid;
    gap: 2rem;
    max-width: 800px;
    margin: 0 auto;
}

.education-card {
    background: var(--bg-card);
    padding: 2rem;
    border-radius: 20px;
    border: 1px solid rgba(255, 255, 255, 0.1);
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
}

.education-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 2px;
    background: var(--gradient);
    transform: scaleX(0);
    transition: transform 0.3s ease;
}

.education-card:hover::before {
    transform: scaleX(1);
}

.education-card:hover {
    transform: translateY(-5px);
    box-shadow: var(--shadow);
}

.education-content {
    display: flex;
    align-items: center;
    gap: 1.5rem;
}

.edu-icon {
    width: 60px;
    height: 60px;
    background: var(--gradient);
    border-radius: 15px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.5rem;
    flex-shrink: 0;
}

.edu-details h3 {
    font-size: 1.2rem;
    margin-bottom: 0.5rem;
}

.edu-details p {
    color: var(--text-secondary);
}

.edu-year {
    color: var(--accent);
    font-weight: 600;
    margin-left: auto;
}

/* Experience Grid */
.experience-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 2rem;
    margin-top: 2rem;
}

.experience-card {
    background: var(--bg-card);
    padding: 2rem;
    border-radius: 20px;
    border: 1px solid rgba(255, 255, 255, 0.1);
    text-align: center;
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
}

.experience-card::before {
    content: '';
    position: absolute;
    top: -2px;
    left: -2px;
    right: -2px;
    bottom: -2px;
    background: var(--gradient);
    border-radius: 20px;
    opacity: 0;
    transition: opacity 0.3s ease;
    z-index: -1;
}

.experience-card:hover::before {
    opacity: 1;
}

.experience-card:hover {
    transform: translateY(-5px);
}

.exp-icon {
    width: 80px;
    height: 80px;
    background: var(--gradient);
    border-radius: 50%;
    margin: 0 auto 1rem;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 2rem;
}

/* Experience Detail Expansion */
.experience-wrapper {
    position: relative;
    display: flex;
    flex-direction: column;
    align-items: center;
}

.experience-description {
    display: none;
    background: var(--bg-card);
    color: var(--text-secondary);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 12px;
    padding: 1rem;
    margin-top: 0.5rem;
    max-width: 300px;
    width: 100%;
    font-size: 0.9rem;
    box-shadow: var(--shadow);
    z-index: 10;
    transition: all 0.3s ease;
}

.experience-wrapper:hover .experience-description {
    display: block;
}
.experience-descriptions {
    max-width: 800px;
    margin: 1rem auto 3rem auto;
    color: var(--text-secondary);
    font-size: 1rem;
    min-height: 80px; /* Reserve space */
    position: relative;
}

.exp-description {
    display: none;
    background: var(--bg-card);
    padding: 1rem 1.5rem;
    border-radius: 15px;
    box-shadow: var(--shadow);
}

/* Show only the active description */
.exp-description.active {
    display: block;
}


/* Projects Section */
.projects-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 2rem;
}

.project-card {
    background: var(--bg-card);
    padding: 2rem;
    border-radius: 20px;
    border: 1px solid rgba(255, 255, 255, 0.1);
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
}

.project-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(45deg, transparent, rgba(0, 212, 255, 0.1), transparent);
    transform: translateX(-100%);
    transition: transform 0.6s ease;
}

.project-card:hover::before {
    transform: translateX(100%);
}

.project-card:hover {
    transform: translateY(-5px);
    box-shadow: var(--shadow);
}

.project-card h3 {
    font-size: 1.3rem;
    margin-bottom: 1rem;
    color: var(--accent);
}

.project-card p {
    color: var(--text-secondary);
    font-size: 0.9rem;
}

/* Contact Section */
.contact {
    background: var(--bg-secondary);
    border-radius: 60px;
    margin: 2rem auto;
    max-width: 1200px;
    width: 90%;
    position: relative;
    overflow: hidden;
}

.contact::before {
    content: '';
    position: absolute;
    top: -2px;
    left: -2px;
    right: -2px;
    bottom: -2px;
    background: var(--gradient);
    border-radius: 60px;
    opacity: 0.3;
    z-index: -1;
}

.contact-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 2rem;
    margin-top: 2rem;
}

.contact-item {
    display: flex;
    align-items: center;
    gap: 1rem;
    padding: 1rem;
    background: rgba(255, 255, 255, 0.05);
    border-radius: 15px;
    transition: all 0.3s ease;
}

.contact-item:hover {
    background: rgba(0, 212, 255, 0.1);
    transform: translateX(5px);
}

.contact-icon {
    width: 40px;
    height: 40px;
    background: var(--gradient);
    border-radius: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.2rem;
}

/* Animations */
@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.fade-in {
    animation: fadeInUp 0.8s ease-out;
}

/* Responsive */
@media (max-width: 768px) {
    .nav-links {
        display: none;
    }

    .hero h1 {
        font-size: 2.5rem;
    }

    .hero .subtitle {
        font-size: 1.2rem;
    }

    .section-title {
        font-size: 2rem;
    }

    .education-content {
        flex-direction: column;
        text-align: center;
    }

    .edu-year {
        margin-left: 0;
    }
}

/* Scroll animations */
.scroll-reveal {
    opacity: 0;
    transform: translateY(50px);
    transition: all 0.8s ease;
}

.scroll-reveal.revealed {
    opacity: 1;
    transform: translateY(0);
}
