:root {
    --dark-bg: #0a192f;
    --primary: #64ffda;
    --text-dark: #ccd6f6;
    --text-secondary: #8892b0;
    --card-bg: #112240;
}

html {
    scroll-behavior: smooth;
}

body {
    font-family: 'Inter', sans-serif;
    background-color: var(--dark-bg);
    color: var(--text-dark);
    transition: all 0.5s ease;
    margin: 0;
    padding: 0;
    overflow-x: hidden;
}

/* Navigation */
.navbar {
    background-color: rgba(10, 25, 47, 0.9);
    padding: 1.5rem 0;
    transition: background-color 0.5s ease;
}

.nav-link {
    color: var(--text-dark) !important;
    margin: 0 1rem;
    font-size: 0.9rem;
    position: relative;
    transition: color 0.3s ease, transform 0.3s ease;
}

.nav-link:hover {
    color: var(--primary) !important;
    transform: scale(1.05);
    background-color: rgba(100, 255, 218, 0.1);
}

.nav-link::after {
    content: '';
    position: absolute;
    width: 0;
    height: 2px;
    bottom: -5px;
    left: 0;
    background-color: var(--primary);
    transition: width 0.3s ease;
}

.nav-link:hover::after {
    width: 100%;
}

.navbar-brand {
    color: var(--primary) !important;
    font-weight: 700;
    transition: color 0.3s ease;
}

/* Hero Section */
.hero {
    min-height: 100vh;
    padding-top: 10rem;
    display: flex;
    align-items: center;
}

.hero h1 {
    font-size: clamp(2.5rem, 5vw, 4.5rem);
    font-weight: 700;
    margin-bottom: 1.5rem;
    font-family: 'Playfair Display', serif;
    opacity: 0;
    transform: translateY(40px);
}

.hero h2 {
    font-size: clamp(1.5rem, 3vw, 2.5rem);
    color: var(--primary);
    margin-bottom: 2rem;
    opacity: 0;
    transform: translateY(40px);
}

.hero p {
    max-width: 600px;
    opacity: 0;
    margin-bottom: 3rem;
    transform: translateY(40px);
}

.btn-outline {
    border: 1px solid var(--primary);
    color: var(--primary);
    padding: 0.75rem 1.5rem;
    border-radius: 5px;
    transition: all 0.3s ease;
    opacity: 0;
    transform: translateY(40px);
}

.btn-outline:hover {
    background-color: rgba(100, 255, 218, 0.1);
    transform: scale(1.05);
}

/* Sections */
section {
    padding: 6rem 0;
}

.section-title {
    font-size: 2rem;
    font-weight: 700;
    margin-bottom: 3rem;
    color: var(--primary);
    opacity: 0;
    transform: translateY(40px);
}

/* Experience */
.experience-item {
    margin-bottom: 3rem;
    opacity: 0;
    transform: translateY(40px);
}

.experience-item h3,
.experience-item p,
.experience-item ul,
.experience-item li {
    opacity: 0;
    transform: translateY(40px);
}

.experience-date {
    color: var(--text-secondary);
    font-size: 0.9rem;
}

/* Education */
.education-card {
    background: var(--card-bg);
    border-left: 2px solid var(--primary);
    padding: 1.5rem;
    margin-bottom: 1.5rem;
    transition: transform 0.3s ease;
    opacity: 0;
    transform: translateY(40px);
}

.education-card:hover {
    transform: translateY(-5px);
}

.education-card h3,
.education-card p {
    opacity: 0;
    transform: translateY(40px);
}

/* Skills & Experience Section */
.skills-experience-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 50px 20px;
    text-align: center;
}

.skills-experience-title {
    font-size: 2.5em;
    margin-bottom: 20px;
    opacity: 0;
    transform: translateY(40px);
}

.skills-experience-description {
    font-size: 1.1em;
    line-height: 1.6;
    margin-bottom: 20px;
    opacity: 0;
    transform: translateY(40px);
}

.linkedin-link {
    color: var(--primary);
    text-decoration: none;
    font-weight: bold;
    opacity: 0;
    transform: translateY(40px);
    transition: background-color 0.3s ease;
}

.linkedin-link:hover {
    background-color: rgba(100, 255, 218, 0.1);
}

.skills-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(120px, 1fr));
    gap: 20px;
    margin-top: 40px;
}

.skill-item {
    display: flex;
    flex-direction: column;
    align-items: center;
    opacity: 0;
    transform: translateY(40px);
}

.skill-item i {
    font-size: 50px;
    margin-bottom: 10px;
    color: var(--primary);
}

.skill-item span {
    font-size: 0.9em;
}

/* Projects Section */
.portfolio-section {
    text-align: center;
    padding: 4rem 0; /* Tighter padding for a compact, modern look */
    background: var(--dark-bg);
}

.portfolio-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(340px, 1fr)); /* Wider cards for prominence */
    gap: 1.5rem; /* Tighter spacing for a sleek grid */
    max-width: 1280px; /* Wider container for modern layouts */
    margin: 2rem auto 0;
}

.portfolio-item {
    position: relative;
    overflow: hidden;
    border-radius: 8px; /* Cleaner, modern corners */
    background: var(--card-bg); /* Consistent card background */
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.25); /* Subtle shadow for depth */
    transition: transform 0.4s ease, box-shadow 0.4s ease;
    opacity: 0;
    transform: translateY(20px); /* Smoother animation start */
}

.portfolio-item:hover {
    transform: translateY(-10px); /* Bolder lift effect */
    box-shadow: 0 8px 20px rgba(0, 0, 0, 0.35); /* Stronger shadow on hover */
}

.portfolio-item img {
    width: 100%;
    height: 220px; /* Balanced height for modern cards */
    object-fit: cover;
    border-radius: 8px 8px 0 0; /* Rounded top only */
    transition: filter 0.4s ease;
}

.portfolio-item:hover img {
    filter: brightness(0.7); /* Darken image on hover for contrast with overlay */
}

.portfolio-overlay {
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(0deg, rgba(10, 25, 47, 0.95), rgba(10, 25, 47, 0.7)); /* Bottom-to-top gradient */
    display: flex;
    flex-direction: column;
    justify-content: flex-end; /* Content at bottom for slide-up effect */
    align-items: center;
    opacity: 0;
    transform: translateY(20px); /* Slide-up animation */
    transition: opacity 0.4s ease, transform 0.4s ease;
    padding: 1.5rem;
}

.portfolio-item:hover .portfolio-overlay {
    opacity: 1;
    transform: translateY(0);
}

.portfolio-overlay h3 {
    color: var(--primary);
    font-size: 1.8rem; /* Larger for emphasis */
    font-weight: 600;
    margin-bottom: 0.5rem;
    font-family: 'Inter', sans-serif;
}

.portfolio-overlay p {
    color: var(--text-dark);
    font-size: 1rem;
    line-height: 1.4;
    margin-bottom: 1rem;
    padding: 0 1rem;
}

.portfolio-tech {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
    justify-content: center;
    margin-bottom: 1rem;
}

.portfolio-tech span {
    background: rgba(100, 255, 218, 0.1); /* Subtle background for tech tags */
    color: var(--primary);
    font-size: 0.85rem;
    padding: 0.3rem 0.8rem;
    border-radius: 4px;
    border: 1px solid rgba(100, 255, 218, 0.3);
}

.portfolio-buttons {
    display: flex;
    gap: 0.75rem;
    justify-content: center;
    flex-wrap: wrap;
}

.portfolio-overlay .btn-outline {
    font-size: 0.85rem;
    padding: 0.6rem 1.4rem;
    border: 1px solid var(--primary);
    color: var(--primary);
    border-radius: 6px;
    text-decoration: none;
    transition: all 0.3s ease;
    background: transparent;
}

.portfolio-overlay .btn-outline:hover {
    background: var(--primary);
    color: var(--dark-bg);
    transform: scale(1.05); /* Subtle scale instead of lift */
    box-shadow: 0 2px 8px rgba(100, 255, 218, 0.3);
}

/* Animation */
@keyframes fadeInUp {
    0% {
        opacity: 0;
        transform: translateY(20px);
    }
    100% {
        opacity: 1;
        transform: translateY(0);
    }
}

.animate-pop-up {
    animation: fadeInUp 0.8s cubic-bezier(0.4, 0, 0.2, 1) forwards; /* Smoother, slightly slower */
}

/* Responsive */
@media (max-width: 768px) {
    .portfolio-grid {
        grid-template-columns: 1fr; /* Single column on mobile */
        gap: 1rem;
    }

    .portfolio-item img {
        height: 180px; /* Smaller for mobile */
    }

    .portfolio-overlay h3 {
        font-size: 1.5rem;
    }

    .portfolio-overlay p {
        font-size: 0.9rem;
        padding: 0 0.75rem;
    }

    .portfolio-buttons {
        flex-direction: column; /* Stack buttons */
        gap: 0.5rem;
    }
}

@media (max-width: 576px) {
    .portfolio-section {
        padding: 2.5rem 0; /* Tighter padding */
    }

    .portfolio-item {
        border-radius: 6px;
    }

    .portfolio-item img {
        height: 160px; /* Compact for small screens */
    }

    .portfolio-overlay h3 {
        font-size: 1.3rem;
    }
}

/* Contact Section */
.contact p {
    opacity: 0;
    transform: translateY(40px);
}

/* Footer */
footer {
    padding: 2rem 0;
    text-align: center;
}

.social-links {
    opacity: 0;
    transform: translateY(40px);
}

footer p {
    opacity: 0;
    transform: translateY(40px);
}

.social-icon {
    color: var(--text-dark);
    font-size: 1.5rem;
    margin: 0 1rem;
    transition: all 0.3s ease;
}

.social-icon:hover {
    color: var(--primary);
    transform: translateY(-3px);
    background-color: rgba(100, 255, 218, 0.1);
}

/* FadeInUp animation */
@keyframes fadeInUp {
    0% {
        opacity: 0;
        transform: translateY(40px);
    }
    100% {
        opacity: 1;
        transform: translateY(0);
    }
}

.animate-pop-up {
    animation: fadeInUp 0.6s cubic-bezier(0.4, 0, 0.2, 1) forwards;
}

/* Responsive */
@media (max-width: 768px) {
    .hero {
        padding-top: 8rem;
        text-align: center;
    }
}