/* Loader */
.loader-container {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 4px;
    background: transparent;
    z-index: 10000;
    pointer-events: none;
}

.linear-loader {
    width: 0%;
    height: 100%;
    background: var(--accent-gradient);
    animation: loading 2s ease-in-out infinite;
    border-radius: 0 4px 4px 0;
    box-shadow: 0 0 10px var(--accent-color);
}

@keyframes loading {
    0% {
        width: 0%;
        left: 0;
    }

    50% {
        width: 70%;
    }

    100% {
        width: 100%;
        opacity: 0;
    }
}

/* Hide loader when loaded (handled via JS) */
.loaded .loader-container {
    display: none;
}

:root {
    --bg-color: #f8fafc;
    --text-primary: #0f172a;
    --text-secondary: #64748b;
    --accent-color: #2563eb;
    /* Stronger blue for white theme */
    --accent-gradient: linear-gradient(135deg, #2563eb 0%, #7c3aed 100%);
    --card-bg: rgba(255, 255, 255, 0.7);
    --card-border: rgba(226, 232, 240, 0.8);
    --glass-blur: 20px;
    --shadow-soft: 0 10px 40px -10px rgba(0, 0, 0, 0.05);
    --shadow-hover: 0 20px 40px -5px rgba(0, 0, 0, 0.1);

    --font-heading: 'Space Grotesk', sans-serif;
    --font-body: 'Outfit', sans-serif;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    scroll-behavior: smooth;
    -webkit-font-smoothing: antialiased;
}

body {
    background-color: var(--bg-color);
    color: var(--text-primary);
    font-family: var(--font-body);
    line-height: 1.6;
    overflow-x: hidden;
    /* Clean, subtle mesh gradient background for white theme */
    background-image:
        radial-gradient(at 0% 0%, rgba(37, 99, 235, 0.05) 0px, transparent 50%),
        radial-gradient(at 100% 0%, rgba(124, 58, 237, 0.05) 0px, transparent 50%),
        radial-gradient(at 100% 100%, rgba(37, 99, 235, 0.05) 0px, transparent 50%),
        radial-gradient(at 0% 100%, rgba(124, 58, 237, 0.05) 0px, transparent 50%);
    background-attachment: fixed;
    min-height: 100vh;
}

/* Custom Cursor */
.cursor-dot,
.cursor-outline {
    position: fixed;
    top: 0;
    left: 0;
    transform: translate(-50%, -50%);
    border-radius: 50%;
    z-index: 9999;
    pointer-events: none;
    mix-blend-mode: multiply;
}

.cursor-dot {
    width: 8px;
    height: 8px;
    background-color: var(--accent-color);
}

.cursor-outline {
    width: 40px;
    height: 40px;
    border: 1.5px solid var(--accent-color);
    transition: 0.15s ease-out;
}

.container {
    max-width: 1280px;
    margin: 0 auto;
    padding: 2rem;
}

/* Styles for Animations */
.fade-in-up {
    opacity: 0;
    transform: translateY(30px);
    transition: opacity 0.8s ease-out, transform 0.8s ease-out;
}

.fade-in-up.visible {
    opacity: 1;
    transform: translateY(0);
}

/* Glass Component */
.glass-effect {
    background: var(--card-bg);
    backdrop-filter: blur(var(--glass-blur));
    -webkit-backdrop-filter: blur(var(--glass-blur));
    border: 1px solid var(--card-border);
    box-shadow: var(--shadow-soft);
    border-radius: 24px;
    transition: all 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
}

.glass-effect:hover {
    transform: translateY(-5px);
    box-shadow: var(--shadow-hover);
    border-color: rgba(37, 99, 235, 0.3);
}

.highlight {
    background: var(--accent-gradient);
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
    font-weight: 700;
}

/* Typography */
h1,
h2,
h3,
h4 {
    font-family: var(--font-heading);
    color: var(--text-primary);
    letter-spacing: -0.02em;
}

/* Buttons */
.btn {
    padding: 0.8rem 2rem;
    border-radius: 50px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    text-decoration: none;
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    font-size: 1rem;
}

.primary-btn {
    background: var(--text-primary);
    color: white;
    border: none;
    box-shadow: 0 10px 20px -5px rgba(15, 23, 42, 0.3);
}

.primary-btn:hover {
    background: var(--accent-color);
    box-shadow: 0 15px 30px -5px rgba(37, 99, 235, 0.4);
    transform: translateY(-2px);
}

.secondary-btn {
    background: white;
    color: var(--text-primary);
    border: 1px solid var(--card-border);
}

.secondary-btn:hover {
    border-color: var(--accent-color);
    color: var(--accent-color);
}

/* Navbar */
.navbar {
    position: fixed;
    top: 20px;
    left: 50%;
    transform: translateX(-50%);
    width: 90%;
    max-width: 1000px;
    padding: 0.8rem 2rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
    border-radius: 100px;
    z-index: 1000;
    background: rgba(255, 255, 255, 0.85);
    /* Prevent the generic glass-effect hover transform from breaking centering */
    transition: transform 0.3s ease, background 0.3s ease, box-shadow 0.3s ease;
}

.navbar.glass-effect:hover {
    transform: translateX(-50%) translateY(0);
    /* Override generic hover to keep it centered and still */
    border-color: var(--card-border);
    /* Optional: keep border static or change it */
}

.logo {
    font-family: var(--font-heading);
    font-weight: 700;
    font-size: 1.2rem;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.nav-logo {
    width: 32px;
    height: 32px;
    border-radius: 50%;
}

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

.nav-links a {
    color: var(--text-secondary);
    text-decoration: none;
    font-weight: 500;
    font-size: 0.95rem;
    position: relative;
    transition: color 0.3s;
}

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

.menu-toggle {
    display: none;
    font-size: 1.5rem;
    cursor: pointer;
    color: var(--text-primary);
}

/* Hero Section */
.hero-section {
    margin-top: 140px;
    display: grid;
    grid-template-columns: 0.8fr 1.2fr;
    gap: 5rem;
    align-items: center;
    margin-bottom: 8rem;
}

.profile-card {
    padding: 3rem;
    text-align: center;
    background: white;
}

.profile-image-container {
    width: 140px;
    height: 140px;
    margin: 0 auto 1.5rem;
    border-radius: 50%;
    padding: 5px;
    background: white;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.08);
}

.profile-img {
    width: 100%;
    height: 100%;
    border-radius: 50%;
    object-fit: cover;
    object-position: top;
}

.name {
    font-size: 2.5rem;
    margin-bottom: 0.2rem;
}

.title {
    font-size: 1.1rem;
    color: var(--text-secondary);
    margin-bottom: 1.5rem;
    font-weight: 400;
}

.tags {
    display: flex;
    justify-content: center;
    gap: 0.5rem;
    flex-wrap: wrap;
    margin-bottom: 2rem;
}

.tag {
    padding: 0.4rem 1rem;
    background: #f1f5f9;
    border-radius: 20px;
    font-size: 0.85rem;
    color: var(--text-primary);
    font-weight: 500;
}

.social-links {
    display: flex;
    justify-content: center;
    gap: 1.5rem;
}

.social-btn {
    color: var(--text-secondary);
    font-size: 1.3rem;
    transition: all 0.3s;
}

.social-btn:hover {
    color: var(--accent-color);
    transform: scale(1.1);
}

.intro-text h3 {
    font-size: 3.5rem;
    margin-bottom: 1.5rem;
    line-height: 1.1;
    background: linear-gradient(to right, #0f172a, #475569);
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
}

.intro-text p {
    font-size: 1.15rem;
    color: var(--text-secondary);
    margin-bottom: 2.5rem;
    max-width: 90%;
}

.intro-text strong {
    color: var(--text-primary);
    font-weight: 600;
}

.stats-row {
    display: flex;
    gap: 4rem;
    margin-bottom: 3rem;
    border-left: 3px solid var(--accent-color);
    padding-left: 2rem;
}

.stat {
    display: flex;
    flex-direction: column;
}

.stat .number {
    font-size: 1.8rem;
    font-weight: 700;
    color: var(--text-primary);
}

.stat .label {
    font-size: 0.9rem;
    color: var(--text-secondary);
    text-transform: uppercase;
    letter-spacing: 0.05em;
    margin-top: 0.2rem;
}

/* Sections */
.section-header {
    text-align: center;
    margin-bottom: 4rem;
    max-width: 600px;
    margin-left: auto;
    margin-right: auto;
}

.section-header h2 {
    font-size: 2.5rem;
    margin-bottom: 1rem;
}

.section-header p {
    color: var(--text-secondary);
    font-size: 1.1rem;
}

/* Education Grid */
.education-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 2rem;
    margin-bottom: 8rem;
}

.edu-card {
    padding: 2rem;
    display: flex;
    gap: 1.5rem;
    align-items: flex-start;
    background: white;
}

.edu-icon {
    width: 50px;
    height: 50px;
    background: #eff6ff;
    color: var(--accent-color);
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.5rem;
    flex-shrink: 0;
}

.edu-content h4 {
    font-size: 1.2rem;
    margin-bottom: 0.2rem;
}

.institution {
    color: var(--text-primary);
    font-weight: 500;
    margin-bottom: 0.5rem;
}

.year {
    display: inline-block;
    font-size: 0.85rem;
    padding: 2px 8px;
    background: #f1f5f9;
    border-radius: 4px;
    color: var(--text-secondary);
    margin-bottom: 0.5rem;
}

.score {
    font-weight: 600;
    color: var(--accent-color);
}

/* Projects Grid - Redesigned for Logo Focus */
.projects-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(350px, 1fr));
    gap: 2rem;
    margin-bottom: 8rem;
}

.project-card {
    display: flex;
    flex-direction: column;
    text-decoration: none;
    padding: 2.5rem;
    background: white;
    position: relative;
    overflow: hidden;
}

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

.project-header img {
    width: 64px;
    height: 64px;
    border-radius: 16px;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.05);
}

.arrow-icon {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background: #f8fafc;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--text-primary);
    transition: all 0.3s;
}

.project-card:hover .arrow-icon {
    background: var(--text-primary);
    color: white;
    transform: rotate(45deg);
}

.project-info h3 {
    font-size: 1.5rem;
    margin-bottom: 0.5rem;
}

.project-url {
    color: var(--accent-color);
    font-size: 0.9rem;
    font-weight: 500;
    margin-bottom: 1rem;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.desc {
    color: var(--text-secondary);
    font-size: 1rem;
    line-height: 1.6;
}

/* AI Toolkit Bar */
.ai-toolkit-bar {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 2rem;
    padding: 1.5rem 3rem;
    margin: 0 auto 8rem;
    width: fit-content;
    background: white;
}

.tool {
    font-weight: 600;
    color: var(--text-primary);
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.tool i {
    color: var(--accent-color);
}

.divider {
    color: #cbd5e1;
}

/* Contact Section */
.contact-section {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 5rem;
    padding: 5rem;
    background: white;
    /* Stronger contrast for contact */
    margin-bottom: 4rem;
    align-items: center;
}

.contact-content h2 {
    font-size: 3rem;
    margin-bottom: 1.5rem;
    line-height: 1.1;
}

.contact-list {
    display: flex;
    flex-direction: column;
    gap: 1rem;
    margin-top: 2rem;
}

.contact-pill {
    display: inline-flex;
    align-items: center;
    gap: 1rem;
    padding: 1rem 1.5rem;
    background: #f8fafc;
    border-radius: 12px;
    text-decoration: none;
    color: var(--text-primary);
    font-weight: 500;
    transition: all 0.3s;
}

.contact-pill:hover {
    background: #eff6ff;
    color: var(--accent-color);
    transform: translateX(10px);
}

.contact-form {
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
}

.form-group input,
.form-group textarea {
    width: 100%;
    padding: 1.2rem;
    background: #f8fafc;
    border: 1px solid #e2e8f0;
    border-radius: 12px;
    font-family: var(--font-body);
    font-size: 1rem;
    color: var(--text-primary);
    transition: all 0.3s;
    outline: none;
}

.form-group input:focus,
.form-group textarea:focus {
    background: white;
    border-color: var(--accent-color);
    box-shadow: 0 0 0 4px rgba(37, 99, 235, 0.1);
}

footer {
    text-align: center;
    padding: 3rem 0;
    color: var(--text-secondary);
    border-top: 1px solid #e2e8f0;
}

/* Mobile Responsiveness */
@media (max-width: 900px) {
    .container {
        padding: 1.5rem;
    }

    .navbar {
        top: 10px;
        width: 95%;
        padding: 0.8rem 1.5rem;
    }

    .nav-links {
        position: fixed;
        top: 80px;
        left: 0;
        width: 100%;
        background: white;
        flex-direction: column;
        align-items: center;
        padding: 2rem;
        gap: 1.5rem;
        box-shadow: 0 20px 40px rgba(0, 0, 0, 0.1);
        clip-path: polygon(0 0, 100% 0, 100% 0, 0 0);
        transition: 0.5s ease-in-out;
    }

    .nav-links.active {
        clip-path: polygon(0 0, 100% 0, 100% 100%, 0 100%);
    }

    .menu-toggle {
        display: block;
    }

    .hero-section {
        grid-template-columns: 1fr;
        text-align: center;
        margin-top: 120px;
        gap: 3rem;
    }

    .profile-card {
        margin: 0 auto;
        width: 100%;
    }

    .intro-text h3 {
        font-size: 2.8rem;
    }

    .stats-row {
        justify-content: center;
        flex-direction: row;
        flex-wrap: wrap;
        gap: 2rem;
        border-left: none;
        padding-left: 0;
    }

    .stat {
        align-items: center;
    }

    .cta-buttons {
        justify-content: center;
    }

    .contact-section {
        grid-template-columns: 1fr;
        padding: 2rem;
        gap: 3rem;
    }

    .contact-content h2 {
        font-size: 2.2rem;
    }

    .ai-toolkit-bar {
        flex-wrap: wrap;
        gap: 1rem;
        padding: 1.5rem;
        width: 100%;
        border-radius: 16px;
    }

    .divider {
        display: none;
    }
}