:root {
    --bg-color: #050505;
    --card-bg: rgba(255, 255, 255, 0.03);
    --glass-border: rgba(255, 255, 255, 0.05);
    --text-primary: #ffffff;
    --text-secondary: #a0a0a0;
    --accent-primary: #6c5ce7;
    --accent-secondary: #00cec9;
    --gradient-main: linear-gradient(135deg, #6c5ce7, #00cec9);
    --font-heading: 'Outfit', sans-serif;
    --font-body: 'Space Grotesk', sans-serif;
    --nav-height: 70px;
    --mobile-nav-height: 65px;
}

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

body {
    background-color: var(--bg-color);
    color: var(--text-primary);
    font-family: var(--font-body);
    line-height: 1.6;
    overflow-x: hidden;
    cursor: none;
    /* Custom cursor */
}

/* 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;
}

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

.cursor-outline {
    width: 40px;
    height: 40px;
    border: 2px solid rgba(255, 255, 255, 0.5);
    transition: width 0.2s, height 0.2s, background-color 0.2s;
}

body:hover .cursor-outline {
    width: 40px;
    height: 40px;
}

/* Typography */
h1,
h2,
h3,
h4 {
    font-family: var(--font-heading);
    font-weight: 700;
}

a {
    text-decoration: none;
    color: inherit;
    transition: 0.3s ease;
}

.highlight {
    background: var(--gradient-main);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

/* Glassmorphism Utility */
.glass {
    background: var(--card-bg);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    border: 1px solid var(--glass-border);
    border-radius: 20px;
    box-shadow: 0 4px 30px rgba(0, 0, 0, 0.1);
}

/* Desktop Navigation */
.desktop-nav {
    position: fixed;
    top: 0;
    width: 100%;
    padding: 1.5rem 5%;
    display: flex;
    justify-content: space-between;
    align-items: center;
    z-index: 1000;
    transition: 0.3s;
    background: rgba(5, 5, 5, 0.8);
    backdrop-filter: blur(10px);
}

.logo {
    font-family: var(--font-heading);
    font-size: 1.8rem;
    font-weight: 700;
}

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

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

.nav-links a {
    font-size: 1rem;
    font-weight: 500;
    opacity: 0.7;
    position: relative;
}

.nav-links a:hover,
.nav-links a.active {
    opacity: 1;
    color: var(--accent-secondary);
}

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

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

.btn-primary {
    padding: 0.8rem 1.8rem;
    background: var(--gradient-main);
    border-radius: 30px;
    color: white;
    font-weight: 600;
    border: none;
    cursor: pointer;
    transition: transform 0.2s, box-shadow 0.2s;
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
}

.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(108, 92, 231, 0.4);
}

/* Mobile Nav Structure */
.mobile-nav,
.mobile-top-bar {
    display: none;
}

/* Hero Section */
.hero {
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0 10%;
    padding-top: var(--nav-height);
    position: relative;
    overflow: hidden;
}

.hero-content {
    max-width: 600px;
    z-index: 2;
}

.greeting {
    font-size: 1.2rem;
    color: var(--accent-secondary);
    display: block;
    margin-bottom: 0.5rem;
}

.glitch-text {
    font-size: 4rem;
    line-height: 1.1;
    margin-bottom: 0.5rem;
    position: relative;
}

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

.bio-snippet {
    color: var(--text-secondary);
    margin-bottom: 2rem;
    font-size: 1.1rem;
    max-width: 500px;
}

.hero-actions {
    display: flex;
    gap: 2rem;
    align-items: center;
}

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

.social-links a {
    font-size: 1.5rem;
    color: var(--text-secondary);
}

.social-links a:hover {
    color: var(--accent-secondary);
    transform: translateY(-3px);
}

.hero-visual {
    position: relative;
    width: 45%;
    height: 500px;
    display: flex;
    justify-content: center;
    align-items: center;
}

.glowing-orb {
    position: absolute;
    width: 300px;
    height: 300px;
    background: var(--gradient-main);
    filter: blur(80px);
    opacity: 0.4;
    border-radius: 50%;
    animation: float 6s ease-in-out infinite;
}

.code-card {
    position: relative;
    width: 100%;
    max-width: 400px;
    padding: 1.5rem;
    z-index: 2;
    transform: perspective(1000px) rotateY(-10deg) rotateX(10deg);
    transition: transform 0.5s ease;
}

.code-card:hover {
    transform: perspective(1000px) rotateY(0) rotateX(0);
}

.code-header {
    display: flex;
    gap: 0.5rem;
    margin-bottom: 1rem;
}

.dot {
    width: 12px;
    height: 12px;
    border-radius: 50%;
}

.dot.red {
    background: #ff5f56;
}

.dot.yellow {
    background: #ffbd2e;
}

.dot.green {
    background: #27c93f;
}

code {
    font-family: 'Fira Code', monospace;
    color: #e0e0e0;
    font-size: 0.9rem;
    white-space: pre;
}

/* Sections General */
.section {
    padding: 6rem 10%;
    position: relative;
}

.section-title {
    font-size: 2.5rem;
    text-align: center;
    margin-bottom: 4rem;
    position: relative;
}

/* About & Skills */
.about-grid {
    display: grid;
    grid-template-columns: 3fr 2fr;
    gap: 3rem;
}

.about-text {
    padding: 2.5rem;
}

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

.stats-row {
    display: flex;
    justify-content: space-between;
}

.stat-item {
    text-align: center;
}

.stat-item .number {
    display: block;
    font-size: 2rem;
    font-weight: 700;
    color: var(--accent-primary);
}

.stat-item .label {
    font-size: 0.9rem;
    color: var(--text-secondary);
}

.skills-container {
    padding: 2.5rem;
}

.skills-container h3 {
    margin-bottom: 1.5rem;
}

.skill-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 1rem;
}

.skill-tag {
    padding: 0.5rem 1rem;
    background: rgba(255, 255, 255, 0.05);
    border-radius: 20px;
    font-size: 0.9rem;
    display: flex;
    align-items: center;
    gap: 0.5rem;
    border: 1px solid transparent;
    transition: border-color 0.3s, background 0.3s;
    /* Specific transitions */
}

.skill-tag:hover {
    border-color: var(--accent-secondary);
    background: rgba(108, 92, 231, 0.1);
}

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

.project-card {
    padding: 2rem;
    transition: 0.4s;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    min-height: 250px;
    transition: background 0.4s, border-color 0.4s, box-shadow 0.4s;
    /* Removed transform/opacity transition to fix GSAP conflict */
}

.project-card:hover {
    transform: translateY(-10px);
    /* Transition handled by separate properties or JS interaction if needed, but visibility is key */
}

/* Nested elements styling */
.card-top {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    margin-bottom: 1.5rem;
}

.company-badge {
    font-size: 0.75rem;
    padding: 0.3rem 0.8rem;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 12px;
    color: var(--text-secondary);
    border: 1px solid var(--glass-border);
}

.project-icon {
    font-size: 2rem;
    color: var(--accent-secondary);
}

.project-card h3 {
    margin-bottom: 0.5rem;
}

.project-card p {
    color: var(--text-secondary);
    font-size: 0.95rem;
    margin-bottom: 1.5rem;
}

.card-tags {
    margin-top: auto;
    display: flex;
    gap: 0.8rem;
}

.card-tags span {
    font-size: 0.8rem;
    color: var(--accent-primary);
    font-family: monospace;
}

.project-card .links a {
    margin-left: 0.8rem;
    font-size: 1.2rem;
}

/* Timeline */
.timeline {
    position: relative;
    max-width: 900px;
    margin: 0 auto;
}

.timeline::after {
    content: '';
    position: absolute;
    width: 2px;
    background: rgba(255, 255, 255, 0.1);
    top: 0;
    bottom: 0;
    left: 50%;
    margin-left: -1px;
}

.timeline-item {
    padding: 10px 40px;
    position: relative;
    width: 50%;
}

.timeline-item.left {
    left: 0;
}

.timeline-item.right {
    left: 50%;
}

.timeline-item::after {
    content: '';
    position: absolute;
    width: 20px;
    height: 20px;
    right: -10px;
    background: var(--bg-color);
    border: 3px solid var(--accent-secondary);
    top: 25px;
    border-radius: 50%;
    z-index: 1;
}

.timeline-item.right::after {
    left: -10px;
}

.timeline-item .content {
    padding: 1.5rem;
    position: relative;
}

.timeline-item h3 {
    color: var(--text-primary);
    margin-bottom: 0.2rem;
}

.timeline-item h4 {
    color: var(--accent-primary);
    font-size: 0.9rem;
    margin-bottom: 0.5rem;
}

.timeline-item .date {
    display: block;
    font-size: 0.8rem;
    color: #666;
    margin-bottom: 1rem;
}

/* Contact */
.contact-container {
    display: grid;
    grid-template-columns: 1fr 1fr;
    overflow: hidden;
    padding: 0;
}

.contact-info {
    padding: 3rem;
    background: rgba(108, 92, 231, 0.05);
}

.contact-info h2 {
    margin-bottom: 1rem;
}

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

.detail-item {
    display: flex;
    align-items: center;
    gap: 1rem;
    color: var(--text-secondary);
}

.detail-item i {
    color: var(--accent-secondary);
    font-size: 1.2rem;
}

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

.form-group input,
.form-group textarea {
    width: 100%;
    padding: 1rem;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid var(--glass-border);
    border-radius: 10px;
    color: white;
    font-family: inherit;
    transition: 0.3s;
}

.form-group input:focus,
.form-group textarea:focus {
    outline: none;
    border-color: var(--accent-secondary);
    background: rgba(255, 255, 255, 0.1);
}

footer {
    text-align: center;
    padding: 2rem;
    color: #555;
    font-size: 0.9rem;
}

/* Animations */
@keyframes float {
    0% {
        transform: translateY(0px);
    }

    50% {
        transform: translateY(-20px);
    }

    100% {
        transform: translateY(0px);
    }
}

/* Mobile Responsiveness */
@media (max-width: 768px) {
    .section {
        padding: 4rem 5%;
        padding-bottom: 6rem;
        /* Space for bottom nav */
    }

    .desktop-nav {
        display: none;
    }

    /* Mobile Headers */
    .mobile-top-bar {
        display: flex;
        justify-content: space-between;
        align-items: center;
        padding: 1rem 5%;
        position: fixed;
        top: 0;
        left: 0;
        width: 100%;
        z-index: 1000;
        background: rgba(5, 5, 5, 0.9);
        backdrop-filter: blur(10px);
        border-bottom: 1px solid var(--glass-border);
    }

    /* Mobile Bottom Nav */
    .mobile-nav {
        display: flex;
        position: fixed;
        bottom: 0;
        left: 0;
        width: 100%;
        background: rgba(15, 15, 15, 0.95);
        backdrop-filter: blur(20px);
        justify-content: space-around;
        padding: 0.8rem 0;
        z-index: 1001;
        border-top: 1px solid var(--glass-border);
    }

    .nav-item {
        display: flex;
        flex-direction: column;
        align-items: center;
        gap: 0.3rem;
        font-size: 0.7rem;
        color: #666;
        transition: 0.3s;
    }

    .nav-item i {
        font-size: 1.2rem;
    }

    .nav-item.active {
        color: var(--accent-secondary);
    }

    /* Layout Adjustments */
    .hero {
        flex-direction: column-reverse;
        justify-content: center;
        text-align: center;
        gap: 3rem;
        padding-top: 100px;
    }

    .hero-content {
        display: flex;
        flex-direction: column;
        align-items: center;
    }

    .hero-actions {
        flex-direction: column;
        width: 100%;
    }

    .hero-visual {
        width: 100%;
        height: auto;
    }

    .code-card {
        transform: none;
    }

    .about-grid {
        grid-template-columns: 1fr;
    }

    .timeline::after {
        left: 31px;
    }

    .timeline-item {
        width: 100%;
        padding-left: 70px;
        padding-right: 25px;
    }

    .timeline-item::after {
        left: 21px;
    }

    .timeline-item.right {
        left: 0;
    }

    .contact-container {
        grid-template-columns: 1fr;
    }

    .cursor-dot,
    .cursor-outline {
        display: none;
    }

    .glitch-text {
        font-size: 2.5rem;
    }

    .role-text {
        font-size: 1.2rem;
    }
}