/* --- Design Variables --- */
:root {
    --bg-color: #0f0c1b;       /* Dark, deep purple-tinted background */
    --card-bg: #1c1635;        /* Slightly lighter purple for containers */
    --primary-color: #8b5cf6;   /* Vibrant deep purple accent */
    --secondary-color: #d8b4fe; /* Soft lavender for highlights */
    --text-main: #f3f4f6;       /* Clean off-white */
    --text-muted: #9ca3af;      /* Muted gray for secondary text */
    --font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
}

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

body {
    background-color: var(--bg-color);
    color: var(--text-main);
    font-family: var(--font-family);
    line-height: 1.6;
    overflow-x: hidden;
}

/* --- Navigation --- */
header {
    background-color: rgba(15, 12, 27, 0.95);
    position: fixed;
    width: 100%;
    top: 0;
    z-index: 1000;
    border-bottom: 1px solid rgba(139, 92, 246, 0.2);
}

.navbar {
    display: flex;
    justify-content: space-between;
    align-items: center;
    max-width: 1200px;
    margin: 0 auto;
    padding: 1.5rem 2rem;
}

.logo {
    font-size: 1.5rem;
    font-weight: bold;
    letter-spacing: 1px;
}

.logo span {
    color: var(--primary-color);
}

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

.nav-links a {
    color: var(--text-main);
    text-decoration: none;
    font-weight: 500;
    transition: color 0.3s ease;
}

.nav-links a:hover, .nav-links a.active {
    color: var(--primary-color);
}

/* --- Content Layout Adjustment --- */
.main-content {
    padding-top: 100px; /* Pushes content down below the fixed navbar */
    min-height: 80vh;   /* Keeps footer pushed to the bottom of shorter pages */
}

.main-content h1 {
    font-size: 3rem;
    margin-bottom: 0.5rem;
}

.intro-text {
    font-size: 1.2rem;
    color: var(--text-muted);
    margin-bottom: 2.5rem;
}

/* --- Buttons & UI Elements --- */
.btn {
    display: inline-block;
    background-color: var(--primary-color);
    color: #fff;
    padding: 0.8rem 2rem;
    border-radius: 30px;
    text-decoration: none;
    font-weight: 600;
    transition: transform 0.2s ease, box-shadow 0.2s ease;
    box-shadow: 0 4px 15px rgba(139, 92, 246, 0.4);
}

.btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(139, 92, 246, 0.6);
}

.btn-alt {
    background-color: transparent;
    border: 2px solid var(--primary-color);
    color: var(--primary-color);
    box-shadow: none;
}

.btn-alt:hover {
    background-color: var(--primary-color);
    color: #fff;
}

/* --- Generic Layout Containers --- */
.container {
    max-width: 1000px;
    margin: 0 auto;
    padding: 6rem 2rem;
}

h2 {
    font-size: 2.25rem;
    margin-bottom: 2rem;
    position: relative;
    display: inline-block;
}

h2::after {
    content: '';
    position: absolute;
    left: 0;
    bottom: -5px;
    width: 40px;
    height: 3px;
    background-color: var(--primary-color);
}

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

.project-card {
    background-color: var(--card-bg);
    padding: 2rem;
    border-radius: 12px;
    border: 1px solid rgba(255, 255, 255, 0.05);
    transition: transform 0.3s ease, border-color 0.3s ease;
}

.project-card:hover {
    transform: translateY(-5px);
    border-color: var(--primary-color);
}

.project-card h3 {
    margin-bottom: 0.5rem;
    color: var(--secondary-color);
}

/* --- Footer --- */
footer {
    text-align: center;
    padding: 3rem;
    color: var(--text-muted);
    font-size: 0.9rem;
    border-top: 1px solid rgba(255, 255, 255, 0.05);
}

/* --- Scroll Animation Classes --- */
.reveal {
    opacity: 0;
    transform: translateY(30px);
    transition: all 0.8s ease;
}

.reveal.active {
    opacity: 1;
    transform: translateY(0);
}

/* --- Mobile Menu Responsive Styles --- */
.burger {
    display: none;
    cursor: pointer;
}

.burger div {
    width: 25px;
    height: 3px;
    background-color: var(--text-main);
    margin: 5px;
    transition: all 0.3s ease;
}

@media screen and (max-width: 768px) {
    .nav-links {
        position: fixed;
        right: 0px;
        height: 92vh;
        top: 8vh;
        background-color: var(--bg-color);
        display: flex;
        flex-direction: column;
        align-items: center;
        width: 100%;
        transform: translateX(100%);
        transition: transform 0.5s ease-in;
        padding-top: 3rem;
    }
    
    .burger {
        display: block;
    }
    
    .nav-active {
        transform: translateX(0%);
    }
}
