/* --- General Setup & Variables --- */
:root {
    --bg-dark: #1a1a2e;
    --bg-light: #16213e;
    --primary: #0f3460;
    --secondary: #e94560;
    --font-light: #ffffff;
    --font-dark: #BFCFE7; /* Lighter color for better clarity */
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    font-family: 'Poppins', sans-serif;
    color: var(--font-light);
    
    /* Animated Gradient Background */
    background: linear-gradient(-45deg, #1a1a2e, #16213e, #0f3460, #1a1a2e);
    background-size: 400% 400%;
    animation: gradientBG 15s ease infinite;
}

.container {
    max-width: 1100px;
    margin: 0 auto;
    padding: 0 2rem;
}

.section-title {
    text-align: center;
    font-size: 2.5rem;
    margin-bottom: 3rem;
    color: var(--secondary);
}

/* --- Navigation --- */
nav {
    position: fixed;
    width: 100%;
    top: 0;
    background-color: rgba(22, 33, 62, 0.8);
    backdrop-filter: blur(10px);
    z-index: 100;
}

nav .container {
    display: flex;
    justify-content: space-between;
    align-items: center;
    height: 60px;
}

nav .nav-logo {
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--secondary);
    text-decoration: none;
}

nav ul {
    list-style: none;
    display: flex;
    gap: 2rem;
}

nav a {
    color: var(--font-light);
    text-decoration: none;
    transition: color 0.3s ease;
}

nav a:hover {
    color: var(--secondary);
}

/* --- Hero Section --- */
.hero {
    min-height: 100vh;
    display: flex;
    align-items: center;
    text-align: center;
    padding-top: 60px;
}

.hero-intro { font-size: 1.2rem; }
.hero-name { font-size: 4rem; font-weight: 700; color: var(--secondary); }
.hero-title { font-size: 1.8rem; font-weight: 300; margin-bottom: 1rem; color: var(--font-dark); }
.hero-headline { max-width: 700px; margin: 0 auto 2rem auto; font-size: 1.1rem; line-height: 1.6; }

/* --- Buttons --- */
.btn {
    padding: 0.8rem 2rem;
    border-radius: 5px;
    text-decoration: none;
    font-weight: 600;
    transition: all 0.3s ease;
    display: inline-block;
    margin: 0.5rem;
}
.btn-primary { background-color: var(--secondary); color: var(--font-light); border: 2px solid var(--secondary); }
.btn-primary:hover { background-color: transparent; }
.btn-secondary { border: 2px solid var(--secondary); color: var(--secondary); }
.btn-secondary:hover { background-color: var(--secondary); color: var(--font-light); }

/* --- Main Content Sections --- */
main section {
    padding: 6rem 0;
}

/* --- About Section --- */
.about-content {
    display: flex;
    align-items: center;
    gap: 3rem;
    flex-direction: column;
}

.about-pic {
    width: 250px;
    height: 250px;
    border-radius: 50%;
    border: 5px solid var(--primary);
    object-fit: cover;
    object-position: 50% 40%; /* Adjusts image within the frame */
}

.about-text p {
    margin-bottom: 1rem;
    color: var(--font-dark);
    line-height: 1.7;
}

/* --- Skills Section --- */
.skills-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 1.5rem;
}
.skill-category {
    background: var(--bg-light);
    padding: 2rem;
    border-radius: 10px;
    border-left: 5px solid var(--secondary);
}
.skill-category h3 { margin-bottom: 1rem; }
.skill-category p { color: var(--font-dark); }

/* --- Projects Section --- */
.projects-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 2rem;
}
.project-card {
    background: var(--bg-light);
    border-radius: 10px;
    overflow: hidden;
    transition: all 0.3s ease;
}
.project-card:hover { transform: translateY(-5px); }
.project-card-content { padding: 2rem; }
.project-card h3 { margin-bottom: 1rem; }
.project-card .tech-stack { font-size: 0.9rem; color: var(--font-dark); margin: 1rem 0; }
.project-links { margin-top: 1rem; }

/* --- Achievements Section (Text List) --- */
.achievements-list {
    max-width: 800px;
    margin: 0 auto;
}

.achievements-list ul {
    list-style: none;
    padding: 0;
}

.achievements-list li {
    background-color: var(--bg-light);
    border-left: 5px solid var(--primary);
    border-radius: 8px;
    margin-bottom: 1rem;
    padding: 1.5rem;
    transition: all 0.3s ease;
}

.achievements-list li:hover {
    background-color: var(--primary);
    border-left-color: var(--secondary);
    transform: translateX(10px);
}

/* --- Footer / Contact --- */
footer {
    background: var(--bg-light);
    padding: 4rem 0;
    text-align: center;
}
.social-links { margin: 2rem 0; }
.social-links a { font-size: 2rem; color: var(--font-light); margin: 0 1rem; transition: color 0.3s ease; }
.social-links a:hover { color: var(--secondary); }
.footer-note { font-size: 0.9rem; color: var(--font-dark); }

/* --- Scroll Animation Styles --- */
.hidden {
    opacity: 0;
    filter: blur(5px);
    transform: translateX(-100%);
    transition: all 1s;
}

.show {
    opacity: 1;
    filter: blur(0);
    transform: translateX(0);
}

/* --- Keyframes for Background --- */
@keyframes gradientBG {
    0% { background-position: 0% 50%; }
    50% { background-position: 100% 50%; }
    100% { background-position: 0% 50%; }
}

/* --- Responsiveness --- */
@media (max-width: 768px) {
    /* General Spacing & Typography */
    .container {
        padding: 0 1rem; /* Less side padding on small screens */
    }
    
    main section {
        padding: 4rem 0; /* Reduced vertical padding */
    }

    .section-title {
        font-size: 2rem;
        margin-bottom: 2rem;
    }

    /* Navigation */
    nav ul {
        gap: 1.2rem; /* Tighter gap for nav links */
    }
    nav a {
        font-size: 0.9rem;
    }

    /* Hero Section */
    .hero {
        min-height: auto; /* Allow height to be based on content */
        padding: 100px 0 60px 0; /* Adjust vertical padding */
        text-align: left; /* Align text to the left on mobile */
    }

    .hero-name {
        font-size: 2.5rem; /* Reduced hero name size */
    }

    .hero-title {
        font-size: 1.3rem; /* Reduced hero title size */
    }
    
    .hero-headline {
        font-size: 1rem;
        margin-left: 0;
        margin-right: 0;
    }

    /* About Section */
    .about-content {
        flex-direction: column;
        gap: 2rem;
    }

    .about-pic {
        width: 200px; /* Smaller profile picture */
        height: 200px;
    }
    
    .about-text {
        text-align: center;
    }

    /* Projects */
    .projects-grid {
        grid-template-columns: 1fr; /* Single column layout */
    }

    /* Achievements List */
    .achievements-list li {
        padding: 1.2rem;
        font-size: 0.9rem;
    }
}
