/* ========================================
   CSS Variables & Theme
   ======================================== */
:root {
    /* Colors */
    --primary: #6366f1;
    --primary-light: #818cf8;
    --primary-dark: #4f46e5;
    --secondary: #06b6d4;
    --accent: #f472b6;

    /* Gradients */
    --gradient-primary: linear-gradient(135deg, #6366f1 0%, #06b6d4 100%);
    --gradient-accent: linear-gradient(135deg, #f472b6 0%, #6366f1 100%);
    --gradient-dark: linear-gradient(135deg, #0f172a 0%, #1e293b 100%);

    /* Background */
    --bg-dark: #0a0a0f;
    --bg-darker: #050507;
    --bg-card: rgba(15, 23, 42, 0.6);

    /* Glass Effect */
    --glass-bg: rgba(255, 255, 255, 0.05);
    --glass-border: rgba(255, 255, 255, 0.1);
    --glass-shadow: 0 8px 32px rgba(0, 0, 0, 0.3);
    --glass-blur: blur(20px);

    /* Text */
    --text-primary: #f8fafc;
    --text-secondary: #94a3b8;
    --text-muted: #64748b;

    /* Spacing */
    --section-padding: 100px 0;
    --container-width: 1200px;

    /* Animation */
    --transition-fast: 0.2s ease;
    --transition-normal: 0.3s ease;
    --transition-slow: 0.5s ease;
}

/* ========================================
   Reset & Base
   ======================================== */
*, *::before, *::after {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
    scroll-padding-top: 80px;
    overflow-x: hidden;
    width: 100%;
}

body {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
    background: var(--bg-dark);
    color: var(--text-primary);
    line-height: 1.6;
    overflow-x: hidden;
    width: 100%;
    max-width: 100vw;
    word-wrap: break-word;
    overflow-wrap: break-word;
}

::selection {
    background: var(--primary);
    color: white;
}

a {
    text-decoration: none;
    color: inherit;
    transition: var(--transition-fast);
}

ul {
    list-style: none;
}

img {
    max-width: 100%;
    height: auto;
}

/* ========================================
   Animated Background
   ======================================== */
.bg-animation {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: -1;
    overflow: hidden;
    background: var(--bg-dark);
}

.gradient-sphere {
    position: absolute;
    border-radius: 50%;
    filter: blur(80px);
    opacity: 0.5;
    animation: float 20s ease-in-out infinite;
}

.sphere-1 {
    width: 600px;
    height: 600px;
    background: var(--primary);
    top: -200px;
    right: -200px;
    animation-delay: 0s;
}

.sphere-2 {
    width: 500px;
    height: 500px;
    background: var(--secondary);
    bottom: -150px;
    left: -150px;
    animation-delay: -7s;
}

.sphere-3 {
    width: 400px;
    height: 400px;
    background: var(--accent);
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    animation-delay: -14s;
}

@keyframes float {
    0%, 100% {
        transform: translate(0, 0) scale(1);
    }
    25% {
        transform: translate(50px, -50px) scale(1.1);
    }
    50% {
        transform: translate(-30px, 30px) scale(0.95);
    }
    75% {
        transform: translate(-50px, -30px) scale(1.05);
    }
}

/* ========================================
   Glass Card Effect
   ======================================== */
.glass-card {
    background: var(--glass-bg);
    backdrop-filter: var(--glass-blur);
    -webkit-backdrop-filter: var(--glass-blur);
    border: 1px solid var(--glass-border);
    border-radius: 20px;
    box-shadow: var(--glass-shadow);
    transition: var(--transition-normal);
}

.glass-card:hover {
    border-color: rgba(255, 255, 255, 0.2);
    box-shadow: 0 12px 40px rgba(0, 0, 0, 0.4);
}

/* ========================================
   Container & Layout
   ======================================== */
.container {
    max-width: var(--container-width);
    margin: 0 auto;
    padding: 0 24px;
    width: 100%;
    overflow-x: hidden;
}

section {
    padding: var(--section-padding);
    position: relative;
    width: 100%;
    max-width: 100vw;
    overflow-x: hidden;
}

/* ========================================
   Navigation
   ======================================== */
.glass-nav {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 1000;
    background: rgba(10, 10, 15, 0.8);
    backdrop-filter: var(--glass-blur);
    -webkit-backdrop-filter: var(--glass-blur);
    border-bottom: 1px solid var(--glass-border);
    transition: var(--transition-normal);
}

.nav-container {
    max-width: var(--container-width);
    margin: 0 auto;
    padding: 16px 24px;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.logo {
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--text-primary);
}

.logo-bracket {
    color: var(--primary);
}

.nav-links {
    display: flex;
    gap: 32px;
}

.nav-links a {
    color: var(--text-secondary);
    font-weight: 500;
    font-size: 0.95rem;
    position: relative;
    padding: 8px 0;
}

.nav-links a::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 0;
    height: 2px;
    background: var(--gradient-primary);
    transition: var(--transition-normal);
}

.nav-links a:hover,
.nav-links a.active {
    color: var(--text-primary);
}

.nav-links a:hover::after,
.nav-links a.active::after {
    width: 100%;
}

.mobile-toggle {
    display: none;
    flex-direction: column;
    gap: 5px;
    background: none;
    border: none;
    cursor: pointer;
    padding: 5px;
}

.mobile-toggle span {
    width: 25px;
    height: 2px;
    background: var(--text-primary);
    transition: var(--transition-normal);
}

/* ========================================
   Hero Section
   ======================================== */
.hero {
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    justify-content: center;
    padding-top: 80px;
}

.hero-content {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 60px;
    align-items: center;
    max-width: var(--container-width);
    margin: 0 auto;
    padding: 0 24px;
}

.hero-greeting {
    font-size: 1.1rem;
    color: var(--primary);
    font-weight: 500;
    margin-bottom: 12px;
    letter-spacing: 2px;
    text-transform: uppercase;
}

.hero-name {
    font-size: clamp(2.5rem, 5vw, 4rem);
    font-weight: 800;
    line-height: 1.1;
    margin-bottom: 24px;
}

.name-line {
    display: block;
}

.gradient-text {
    background: var(--gradient-primary);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.hero-tagline {
    font-size: 1.25rem;
    color: var(--text-secondary);
    margin-bottom: 32px;
    max-width: 500px;
}

.hero-tech-stack {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
    margin-bottom: 40px;
}

.tech-pill {
    background: var(--glass-bg);
    border: 1px solid var(--glass-border);
    padding: 8px 16px;
    border-radius: 50px;
    font-size: 0.85rem;
    color: var(--text-secondary);
    transition: var(--transition-normal);
}

.tech-pill:hover {
    border-color: var(--primary);
    color: var(--primary);
}

.hero-cta {
    display: flex;
    gap: 16px;
}

/* Buttons */
.btn {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    padding: 14px 28px;
    border-radius: 12px;
    font-weight: 600;
    font-size: 1rem;
    cursor: pointer;
    border: none;
    transition: var(--transition-normal);
}

.btn-primary {
    background: var(--gradient-primary);
    color: white;
    box-shadow: 0 4px 20px rgba(99, 102, 241, 0.4);
}

.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 30px rgba(99, 102, 241, 0.5);
}

.btn-secondary {
    background: var(--glass-bg);
    border: 1px solid var(--glass-border);
    color: var(--text-primary);
}

.btn-secondary:hover {
    border-color: var(--primary);
    background: rgba(99, 102, 241, 0.1);
}

.btn-full {
    width: 100%;
    justify-content: center;
}

/* Code Window */
.code-window {
    padding: 0;
    overflow: hidden;
}

.window-header {
    display: flex;
    align-items: center;
    gap: 16px;
    padding: 16px 20px;
    background: rgba(0, 0, 0, 0.3);
    border-bottom: 1px solid var(--glass-border);
}

.window-dots {
    display: flex;
    gap: 8px;
}

.dot {
    width: 12px;
    height: 12px;
    border-radius: 50%;
}

.dot.red { background: #ff5f57; }
.dot.yellow { background: #febc2e; }
.dot.green { background: #28c840; }

.window-title {
    color: var(--text-muted);
    font-size: 0.85rem;
}

.code-content {
    padding: 24px;
    font-family: 'Fira Code', 'Monaco', monospace;
    font-size: 0.9rem;
    line-height: 1.8;
    overflow-x: auto;
    max-width: 100%;
    word-break: break-word;
    overflow-wrap: break-word;
}

.code-content .keyword { color: #c792ea; }
.code-content .variable { color: #82aaff; }
.code-content .property { color: #f78c6c; }
.code-content .string { color: #c3e88d; }
.code-content .function { color: #82aaff; }
.code-content .parameter { color: #ffcb6b; }

/* Scroll Indicator */
.scroll-indicator {
    position: absolute;
    bottom: 40px;
    left: 50%;
    transform: translateX(-50%);
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 12px;
    color: var(--text-muted);
    font-size: 0.85rem;
    animation: bounce 2s infinite;
}

.mouse {
    width: 24px;
    height: 38px;
    border: 2px solid var(--text-muted);
    border-radius: 12px;
    position: relative;
}

.wheel {
    width: 4px;
    height: 8px;
    background: var(--text-muted);
    border-radius: 2px;
    position: absolute;
    top: 8px;
    left: 50%;
    transform: translateX(-50%);
    animation: scroll 2s infinite;
}

@keyframes bounce {
    0%, 100% { transform: translateX(-50%) translateY(0); }
    50% { transform: translateX(-50%) translateY(10px); }
}

@keyframes scroll {
    0%, 100% { opacity: 1; top: 8px; }
    50% { opacity: 0.3; top: 16px; }
}

/* ========================================
   Section Titles
   ======================================== */
.section-title {
    font-size: clamp(1.8rem, 4vw, 2.5rem);
    font-weight: 700;
    margin-bottom: 60px;
    display: flex;
    align-items: center;
    gap: 16px;
}

.title-number {
    color: var(--primary);
    font-family: 'Fira Code', monospace;
    font-size: 1.2rem;
    font-weight: 400;
}

/* ========================================
   About Section
   ======================================== */
.about-content {
    display: grid;
    grid-template-columns: 2fr 1fr;
    gap: 40px;
    align-items: start;
}

.about-text {
    padding: 40px;
}

.about-text .lead {
    font-size: 1.2rem;
    color: var(--text-primary);
    margin-bottom: 20px;
}

.about-text p {
    color: var(--text-secondary);
    margin-bottom: 16px;
}

.about-text strong {
    color: var(--primary-light);
}

.about-highlights {
    display: flex;
    gap: 24px;
    margin-top: 32px;
    padding-top: 24px;
    border-top: 1px solid var(--glass-border);
}

.highlight-item {
    display: flex;
    align-items: center;
    gap: 10px;
    color: var(--text-secondary);
    font-size: 0.95rem;
}

.highlight-item i {
    color: var(--primary);
    font-size: 1.2rem;
}

.about-stats {
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.stat-card {
    padding: 24px;
    text-align: center;
    position: relative;
    overflow: hidden;
}

.stat-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 4px;
    height: 100%;
    background: var(--gradient-primary);
}

.stat-icon {
    font-size: 1.5rem;
    color: var(--primary);
    margin-bottom: 12px;
}

.stat-number {
    font-size: 2.5rem;
    font-weight: 800;
    background: var(--gradient-primary);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.stat-number::after {
    content: '+';
}

.stat-label {
    color: var(--text-secondary);
    font-size: 0.9rem;
    margin-top: 8px;
}

/* ========================================
   Organizations Section
   ======================================== */
.organizations {
    padding: var(--section-padding);
    background: var(--bg-darker);
}

.section-intro {
    text-align: center;
    color: var(--text-secondary);
    font-size: 1.1rem;
    max-width: 700px;
    margin: -20px auto 60px;
    line-height: 1.8;
}

.org-grid {
    display: grid;
    gap: 40px;
    max-width: 1400px;
    margin: 0 auto;
}

.org-card {
    padding: 50px;
    transition: var(--transition-normal);
}

.org-card:hover {
    transform: translateY(-8px);
    border-color: var(--primary);
}

.org-header {
    display: flex;
    align-items: center;
    gap: 24px;
    margin-bottom: 24px;
    padding-bottom: 24px;
    border-bottom: 1px solid var(--glass-border);
}

.org-icon {
    width: 80px;
    height: 80px;
    border-radius: 20px;
    background: var(--gradient-primary);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 2.5rem;
    color: white;
    flex-shrink: 0;
}

.org-icon.enterprise {
    background: var(--gradient-accent);
}

.org-title-group h3 {
    font-size: 2rem;
    margin-bottom: 4px;
    background: var(--gradient-primary);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.org-role {
    color: var(--text-muted);
    font-size: 0.95rem;
    font-weight: 500;
    text-transform: uppercase;
    letter-spacing: 1px;
}

.org-description {
    color: var(--text-secondary);
    font-size: 1.1rem;
    line-height: 1.8;
    margin-bottom: 32px;
}

.org-highlights {
    display: grid;
    gap: 16px;
    margin-bottom: 32px;
}

.org-feature {
    display: flex;
    align-items: flex-start;
    gap: 16px;
    padding: 16px;
    background: rgba(99, 102, 241, 0.05);
    border-radius: 12px;
    border: 1px solid rgba(99, 102, 241, 0.1);
    transition: var(--transition-fast);
}

.org-feature:hover {
    background: rgba(99, 102, 241, 0.1);
    border-color: rgba(99, 102, 241, 0.2);
}

.org-feature i {
    color: var(--primary);
    font-size: 1.3rem;
    margin-top: 2px;
    flex-shrink: 0;
}

.org-feature span {
    color: var(--text-secondary);
    font-size: 0.95rem;
    line-height: 1.6;
}

.org-feature strong {
    color: var(--text-primary);
    font-weight: 600;
}

.org-tech {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    margin-bottom: 32px;
    padding-top: 24px;
    border-top: 1px solid var(--glass-border);
}

.org-tech span {
    padding: 8px 16px;
    background: rgba(99, 102, 241, 0.1);
    border: 1px solid rgba(99, 102, 241, 0.2);
    border-radius: 20px;
    font-size: 0.85rem;
    color: var(--text-secondary);
    font-weight: 500;
}

.org-link {
    display: inline-flex;
    align-items: center;
    gap: 12px;
    padding: 14px 32px;
    background: var(--gradient-primary);
    border-radius: 50px;
    color: white;
    font-weight: 600;
    transition: var(--transition-normal);
}

.org-link:hover {
    transform: translateX(8px);
    box-shadow: 0 8px 24px rgba(99, 102, 241, 0.4);
}

.org-link i {
    font-size: 1.2rem;
}

@media (max-width: 768px) {
    .org-card {
        padding: 30px;
    }

    .org-header {
        flex-direction: column;
        text-align: center;
    }

    .org-title-group h3 {
        font-size: 1.6rem;
    }

    .org-tech {
        justify-content: center;
    }
}

/* ========================================
   Skills Section
   ======================================== */
.skills-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 24px;
}

.skill-category {
    padding: 32px;
}

.category-header {
    display: flex;
    align-items: center;
    gap: 16px;
    margin-bottom: 24px;
}

.category-header i {
    font-size: 1.5rem;
    color: var(--primary);
    width: 50px;
    height: 50px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: rgba(99, 102, 241, 0.1);
    border-radius: 12px;
}

.category-header h3 {
    font-size: 1.2rem;
    font-weight: 600;
}

.skill-list {
    list-style: none;
    padding-left: 0;
}

.skill-list li {
    color: var(--text-secondary);
    padding-left: 24px;
    position: relative;
    margin-bottom: 12px;
    line-height: 1.8;
}

.skill-list li strong {
    color: var(--text-primary);
    font-weight: 600;
}

.tech-badges {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    padding: 8px 0;
}

.tech-badge {
    padding: 8px 16px;
    background: rgba(100, 116, 139, 0.1);
    border: 1px solid rgba(100, 116, 139, 0.2);
    border-radius: 20px;
    font-size: 0.85rem;
    color: var(--text-secondary);
    font-weight: 500;
    transition: var(--transition-fast);
}

.tech-badge.primary {
    background: rgba(99, 102, 241, 0.15);
    border-color: rgba(99, 102, 241, 0.3);
    color: var(--primary-light);
    font-weight: 600;
}

.tech-badge:hover {
    transform: translateY(-2px);
    border-color: var(--primary);
}

.skill-list li {
    color: var(--text-secondary);
    font-size: 0.95rem;
    padding-left: 20px;
    margin-bottom: 12px;
    position: relative;
    line-height: 1.5;
}

.skill-list li::before {
    content: '✓';
    position: absolute;
    left: 0;
    top: 2px;
    color: var(--primary);
    font-weight: 600;
}

/* ========================================
   GitHub Showcase Section
   ======================================== */
.github-showcase {
    padding: var(--section-padding);
    background: var(--bg-darker);
}

.github-content {
    display: grid;
    grid-template-columns: 1fr 1.5fr;
    gap: 40px;
    align-items: start;
}

.github-intro {
    padding: 40px;
    text-align: center;
    position: sticky;
    top: 100px;
}

.github-icon {
    font-size: 4rem;
    color: var(--primary);
    margin-bottom: 20px;
    display: block;
}

.github-intro h3 {
    font-size: 1.8rem;
    margin-bottom: 16px;
    background: var(--gradient-primary);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.github-intro p {
    color: var(--text-secondary);
    margin-bottom: 24px;
    line-height: 1.8;
}

.github-stats-inline {
    display: flex;
    gap: 24px;
    justify-content: center;
    margin: 30px 0;
    padding: 20px 0;
    border-top: 1px solid var(--glass-border);
    border-bottom: 1px solid var(--glass-border);
}

.stat-inline {
    display: flex;
    align-items: center;
    gap: 8px;
    color: var(--text-secondary);
}

.stat-inline i {
    color: var(--primary);
    font-size: 1.2rem;
}

.stat-inline strong {
    color: var(--text-primary);
    font-size: 1.3rem;
}

.github-highlights {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 20px;
}

.highlight-repo {
    padding: 30px;
    transition: var(--transition-normal);
    cursor: pointer;
}

.highlight-repo:hover {
    transform: translateY(-5px);
    border-color: var(--primary);
}

.repo-header {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-bottom: 12px;
}

.repo-header i {
    font-size: 1.8rem;
    color: var(--primary);
}

.repo-header h4 {
    font-size: 1.2rem;
    color: var(--text-primary);
}

.highlight-repo p {
    color: var(--text-secondary);
    font-size: 0.95rem;
    margin-bottom: 16px;
    line-height: 1.6;
}

.repo-lang {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    font-size: 0.85rem;
    color: var(--text-muted);
}

.lang-dot {
    width: 12px;
    height: 12px;
    border-radius: 50%;
    display: inline-block;
}

.lang-dot.python {
    background: #3572A5;
}

.lang-dot.typescript {
    background: #3178c6;
}

.lang-dot.csharp {
    background: #178600;
}

.lang-dot.javascript {
    background: #f1e05a;
}

@media (max-width: 992px) {
    .github-content {
        grid-template-columns: 1fr;
    }

    .github-intro {
        position: relative;
        top: 0;
    }

    .github-highlights {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 576px) {
    .github-stats-inline {
        flex-direction: column;
        gap: 16px;
    }
}

/* ========================================
   Projects Section
   ======================================== */
.project-filters {
    display: flex;
    gap: 12px;
    margin-bottom: 40px;
    flex-wrap: wrap;
}

.filter-btn {
    padding: 10px 24px;
    background: var(--glass-bg);
    border: 1px solid var(--glass-border);
    border-radius: 50px;
    color: var(--text-secondary);
    font-size: 0.9rem;
    cursor: pointer;
    transition: var(--transition-normal);
}

.filter-btn:hover,
.filter-btn.active {
    background: var(--primary);
    border-color: var(--primary);
    color: white;
}

.projects-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(350px, 1fr));
    gap: 24px;
}

.project-card {
    overflow: hidden;
    transition: var(--transition-normal);
}

.project-card:hover {
    transform: translateY(-8px);
}

.project-image {
    position: relative;
    height: 200px;
    background: linear-gradient(135deg, rgba(99, 102, 241, 0.2), rgba(6, 182, 212, 0.2));
    display: flex;
    align-items: center;
    justify-content: center;
}

.project-placeholder {
    font-size: 4rem;
    color: rgba(255, 255, 255, 0.2);
}

.project-overlay {
    position: absolute;
    inset: 0;
    background: rgba(0, 0, 0, 0.8);
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 16px;
    opacity: 0;
    transition: var(--transition-normal);
}

.project-card:hover .project-overlay {
    opacity: 1;
}

.project-link {
    width: 50px;
    height: 50px;
    border: 2px solid white;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-size: 1.2rem;
    transition: var(--transition-normal);
}

.project-link:hover {
    background: var(--primary);
    border-color: var(--primary);
    transform: scale(1.1);
}

.project-content {
    padding: 24px;
}

.project-title {
    font-size: 1.2rem;
    font-weight: 600;
    margin-bottom: 12px;
}

.project-description {
    color: var(--text-secondary);
    font-size: 0.95rem;
    margin-bottom: 20px;
    line-height: 1.6;
}

.project-tech {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}

.project-tech span {
    font-size: 0.8rem;
    color: var(--primary-light);
    background: rgba(99, 102, 241, 0.1);
    padding: 4px 12px;
    border-radius: 4px;
}

/* ========================================
   Experience Section
   ======================================== */
.experience-content {
    display: grid;
    grid-template-columns: 2fr 1fr;
    gap: 40px;
    align-items: start;
}

.timeline {
    position: relative;
    padding-left: 30px;
}

.timeline::before {
    content: '';
    position: absolute;
    left: 0;
    top: 0;
    bottom: 0;
    width: 2px;
    background: var(--gradient-primary);
}

.timeline-item {
    position: relative;
    margin-bottom: 24px;
    padding: 28px;
}

.timeline-marker {
    position: absolute;
    left: -38px;
    top: 32px;
    width: 16px;
    height: 16px;
    background: var(--primary);
    border-radius: 50%;
    border: 4px solid var(--bg-dark);
}

.timeline-date {
    display: inline-block;
    padding: 4px 12px;
    background: rgba(99, 102, 241, 0.1);
    color: var(--primary);
    border-radius: 4px;
    font-size: 0.85rem;
    font-weight: 500;
    margin-bottom: 12px;
}

.timeline-title {
    font-size: 1.3rem;
    font-weight: 600;
    margin-bottom: 8px;
}

.timeline-company {
    color: var(--text-muted);
    font-size: 0.95rem;
    margin-bottom: 16px;
}

.timeline-details {
    list-style: none;
}

.timeline-details li {
    color: var(--text-secondary);
    font-size: 0.95rem;
    padding-left: 20px;
    margin-bottom: 8px;
    position: relative;
}

.timeline-details li::before {
    content: '';
    position: absolute;
    left: 0;
    top: 10px;
    width: 6px;
    height: 6px;
    background: var(--primary);
    border-radius: 50%;
}

.cv-download {
    padding: 40px;
    text-align: center;
    position: sticky;
    top: 100px;
}

.cv-content i {
    font-size: 3rem;
    color: var(--primary);
    margin-bottom: 20px;
}

.cv-content h3 {
    font-size: 1.3rem;
    margin-bottom: 12px;
}

.cv-content p {
    color: var(--text-secondary);
    margin-bottom: 24px;
}

/* ========================================
   Contact Section
   ======================================== */
.contact-content {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 40px;
}

.contact-info {
    padding: 40px;
}

.contact-info h3 {
    font-size: 1.5rem;
    margin-bottom: 16px;
}

.contact-info > p {
    color: var(--text-secondary);
    margin-bottom: 32px;
    line-height: 1.7;
}

.contact-methods {
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.contact-method {
    display: flex;
    align-items: center;
    gap: 16px;
    padding: 16px 20px;
    background: rgba(255, 255, 255, 0.03);
    border-radius: 12px;
    transition: var(--transition-normal);
}

.contact-method:hover {
    background: rgba(99, 102, 241, 0.1);
    transform: translateX(8px);
}

.contact-method i {
    font-size: 1.5rem;
    color: var(--primary);
    width: 24px;
}

.contact-method span {
    color: var(--text-secondary);
}

.contact-form {
    padding: 40px;
}

.form-status {
    padding: 16px 20px;
    border-radius: 12px;
    margin-bottom: 24px;
    font-size: 0.95rem;
    font-weight: 500;
    animation: slideIn 0.3s ease;
}

.form-status.success {
    background: rgba(16, 185, 129, 0.15);
    border: 1px solid rgba(16, 185, 129, 0.4);
    color: #10b981;
}

.form-status.error {
    background: rgba(239, 68, 68, 0.15);
    border: 1px solid rgba(239, 68, 68, 0.4);
    color: #ef4444;
}

@keyframes slideIn {
    from {
        opacity: 0;
        transform: translateY(-10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.form-group {
    margin-bottom: 24px;
}

.form-group label {
    display: block;
    margin-bottom: 8px;
    color: var(--text-secondary);
    font-size: 0.9rem;
    font-weight: 500;
}

.form-group input,
.form-group textarea {
    width: 100%;
    padding: 14px 18px;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid var(--glass-border);
    border-radius: 12px;
    color: var(--text-primary);
    font-size: 1rem;
    font-family: inherit;
    transition: var(--transition-normal);
}

.form-group input:focus,
.form-group textarea:focus {
    outline: none;
    border-color: var(--primary);
    box-shadow: 0 0 0 3px rgba(99, 102, 241, 0.2);
}

.form-group input::placeholder,
.form-group textarea::placeholder {
    color: var(--text-muted);
}

.form-group textarea {
    resize: vertical;
    min-height: 120px;
}

/* ========================================
   Footer
   ======================================== */
.footer {
    padding: 60px 0 30px;
    border-top: 1px solid var(--glass-border);
}

.footer-content {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 20px;
    margin-bottom: 30px;
}

.footer-logo {
    font-size: 2rem;
    font-weight: 700;
}

.footer-text {
    color: var(--text-secondary);
}

.footer-social {
    display: flex;
    gap: 16px;
}

.footer-social a {
    width: 45px;
    height: 45px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: var(--glass-bg);
    border: 1px solid var(--glass-border);
    border-radius: 50%;
    color: var(--text-secondary);
    font-size: 1.2rem;
    transition: var(--transition-normal);
}

.footer-social a:hover {
    background: var(--primary);
    border-color: var(--primary);
    color: white;
    transform: translateY(-4px);
}

.footer-bottom {
    text-align: center;
    padding-top: 30px;
    border-top: 1px solid var(--glass-border);
}

.footer-bottom p {
    color: var(--text-muted);
    font-size: 0.9rem;
}

/* ========================================
   Responsive Design
   ======================================== */
@media (max-width: 1024px) {
    .hero-content {
        grid-template-columns: 1fr;
        text-align: center;
    }

    .hero-tagline {
        margin-left: auto;
        margin-right: auto;
    }

    .hero-tech-stack {
        justify-content: center;
    }

    .hero-cta {
        justify-content: center;
    }

    .hero-visual {
        max-width: 500px;
        margin: 0 auto;
    }

    .about-content {
        grid-template-columns: 1fr;
    }

    .about-stats {
        flex-direction: row;
        flex-wrap: wrap;
        justify-content: center;
    }

    .stat-card {
        flex: 1;
        min-width: 150px;
    }

    .experience-content {
        grid-template-columns: 1fr;
    }

    .cv-download {
        position: static;
    }

    .contact-content {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 768px) {
    :root {
        --section-padding: 60px 0;
    }

    .nav-links {
        position: fixed;
        top: 70px;
        left: 0;
        right: 0;
        background: rgba(10, 10, 15, 0.98);
        backdrop-filter: var(--glass-blur);
        padding: 20px;
        flex-direction: column;
        gap: 0;
        text-align: center;
        transform: translateY(-150%);
        transition: var(--transition-normal);
        border-bottom: 1px solid var(--glass-border);
    }

    .nav-links.active {
        transform: translateY(0);
    }

    .nav-links a {
        display: block;
        padding: 16px;
    }

    .mobile-toggle {
        display: flex;
    }

    .mobile-toggle.active span:nth-child(1) {
        transform: rotate(45deg) translate(5px, 5px);
    }

    .mobile-toggle.active span:nth-child(2) {
        opacity: 0;
    }

    .mobile-toggle.active span:nth-child(3) {
        transform: rotate(-45deg) translate(5px, -5px);
    }

    .hero-name {
        font-size: 2rem;
    }

    .skills-grid {
        grid-template-columns: 1fr;
    }

    .projects-grid {
        grid-template-columns: 1fr;
    }

    .about-highlights {
        flex-direction: column;
        gap: 16px;
    }

    .about-stats {
        flex-direction: column;
    }

    .stat-card {
        min-width: auto;
    }

    .timeline {
        padding-left: 20px;
    }

    .timeline-marker {
        left: -28px;
        width: 12px;
        height: 12px;
    }

    .scroll-indicator {
        display: none;
    }
}

@media (max-width: 480px) {
    html {
        overflow-x: hidden;
        width: 100%;
    }

    body {
        overflow-x: hidden;
        width: 100%;
        position: relative;
        -webkit-overflow-scrolling: touch;
    }

    .container {
        padding: 0 16px;
        width: 100%;
    }

    section {
        width: 100%;
        overflow-x: hidden;
        position: relative;
    }

    .glass-card {
        width: 100%;
    }

    pre, code {
        max-width: 100%;
        overflow-x: auto;
        -webkit-overflow-scrolling: touch;
        white-space: pre-wrap;
        word-wrap: break-word;
    }

    .hero-name {
        font-size: 1.5rem;
    }

    .hero-greeting {
        font-size: 0.9rem;
    }

    .hero-tagline {
        font-size: 0.95rem;
    }

    .hero-tech-stack {
        gap: 6px;
    }

    .tech-pill {
        font-size: 0.7rem;
        padding: 4px 10px;
    }

    .hero-cta {
        flex-direction: column;
        gap: 12px;
    }

    .btn {
        width: 100%;
        justify-content: center;
        padding: 14px 24px;
    }

    .section-title {
        flex-direction: column;
        align-items: flex-start;
        gap: 8px;
        font-size: 1.75rem;
    }

    .title-number {
        font-size: 1rem;
    }

    .section-intro {
        font-size: 0.95rem;
    }

    .project-filters {
        justify-content: center;
        flex-wrap: wrap;
    }

    .filter-btn {
        padding: 8px 16px;
        font-size: 0.85rem;
    }

    .org-card,
    .skill-category,
    .project-card,
    .glass-card {
        padding: 20px;
    }

    .org-header h3,
    .category-header h3 {
        font-size: 1.1rem;
    }

    .org-tech,
    .tech-badges {
        gap: 6px;
    }

    .org-tech span,
    .tech-badge {
        font-size: 0.7rem;
        padding: 4px 8px;
    }

    .timeline-title {
        font-size: 1.1rem;
    }

    .timeline-company,
    .timeline-date {
        font-size: 0.85rem;
    }

    .contact-method {
        font-size: 0.9rem;
        padding: 12px;
    }

    .form-group input,
    .form-group textarea {
        font-size: 0.95rem;
        padding: 12px 16px;
    }

    .code-window {
        padding: 12px;
    }

    .code-content {
        font-size: 0.75rem;
    }

    /* Fix overflow issues */
    img {
        max-width: 100%;
        height: auto;
    }

    .hero-visual {
        width: 100%;
        overflow: hidden;
    }

    .code-window {
        width: 100%;
        overflow-x: auto;
        -webkit-overflow-scrolling: touch;
        word-break: break-word;
    }

    .terminal-window {
        width: calc(100% - 32px);
        overflow-x: auto;
        -webkit-overflow-scrolling: touch;
    }

    .hero-content {
        width: 100%;
    }

    .hero-text {
        width: 100%;
    }

    .hero-name,
    .hero-greeting,
    .hero-tagline {
        word-wrap: break-word;
        overflow-wrap: break-word;
    }

    .projects-grid,
    .skills-grid,
    .org-grid {
        grid-template-columns: 1fr;
        gap: 16px;
    }

    .about-content {
        grid-template-columns: 1fr;
        gap: 20px;
    }

    .footer-content,
    .contact-content {
        flex-direction: column;
        gap: 20px;
    }

    /* Ensure images don't overflow */
    img {
        max-width: 100%;
        height: auto;
    }

    /* Better spacing for small screens */
    .about-highlights .highlight-item {
        font-size: 0.9rem;
    }

    .stat-number {
        font-size: 2rem;
    }

    .stat-label {
        font-size: 0.85rem;
    }

    /* Footer adjustments */
    .footer-logo {
        font-size: 1.5rem;
    }

    .footer-text {
        font-size: 0.85rem;
    }

    .footer-social a {
        width: 40px;
        height: 40px;
        font-size: 1rem;
    }
}

/* ========================================
   Interactive Terminal
   ======================================== */
.terminal-toggle {
    position: fixed;
    bottom: 30px;
    right: 30px;
    width: 60px;
    height: 60px;
    background: var(--gradient-primary);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    z-index: 1001;
    box-shadow: 0 4px 20px rgba(99, 102, 241, 0.4);
    transition: var(--transition-normal);
    animation: pulse-glow 2s ease-in-out infinite;
}

.terminal-toggle:hover {
    transform: scale(1.1);
    box-shadow: 0 6px 30px rgba(99, 102, 241, 0.6);
}

.terminal-toggle i {
    font-size: 1.5rem;
    color: white;
}

.terminal-toggle.active {
    animation: none;
    background: var(--gradient-accent);
}

@keyframes pulse-glow {
    0%, 100% {
        box-shadow: 0 4px 20px rgba(99, 102, 241, 0.4);
    }
    50% {
        box-shadow: 0 4px 30px rgba(99, 102, 241, 0.7);
    }
}

.terminal-container {
    position: fixed;
    bottom: 100px;
    right: 30px;
    z-index: 1000;
    opacity: 0;
    visibility: hidden;
    transform: translateY(20px) scale(0.95);
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.terminal-container.active {
    opacity: 1;
    visibility: visible;
    transform: translateY(0) scale(1);
}

.terminal-container.maximized {
    bottom: 20px;
    right: 20px;
    left: 20px;
    top: 80px;
}

.terminal-container.maximized .terminal-window {
    width: 100%;
    height: 100%;
    max-width: none;
    max-height: none;
}

.terminal-window {
    width: 600px;
    max-width: calc(100vw - 60px);
    height: 400px;
    max-height: calc(100vh - 200px);
    display: flex;
    flex-direction: column;
    overflow: hidden;
    background: rgba(10, 10, 20, 0.95);
    border: 1px solid var(--glass-border);
    box-shadow: 0 25px 50px rgba(0, 0, 0, 0.5);
}

.terminal-header {
    display: flex;
    align-items: center;
    gap: 16px;
    padding: 12px 16px;
    background: rgba(0, 0, 0, 0.4);
    border-bottom: 1px solid var(--glass-border);
    cursor: default;
}

.terminal-dots {
    display: flex;
    gap: 8px;
}

.terminal-dots .dot {
    cursor: pointer;
    transition: var(--transition-fast);
}

.terminal-dots .dot:hover {
    transform: scale(1.2);
    filter: brightness(1.2);
}

.terminal-title {
    color: var(--text-muted);
    font-size: 0.85rem;
    font-family: 'Fira Code', 'Monaco', monospace;
    flex: 1;
    text-align: center;
}

.terminal-drag-area {
    flex: 1;
}

.terminal-body {
    flex: 1;
    display: flex;
    flex-direction: column;
    padding: 16px;
    overflow: hidden;
    font-family: 'Fira Code', 'Monaco', 'Consolas', monospace;
    font-size: 0.9rem;
    line-height: 1.6;
}

.terminal-output {
    flex: 1;
    overflow-y: auto;
    padding-right: 8px;
}

.terminal-output::-webkit-scrollbar {
    width: 6px;
}

.terminal-output::-webkit-scrollbar-track {
    background: rgba(255, 255, 255, 0.05);
    border-radius: 3px;
}

.terminal-output::-webkit-scrollbar-thumb {
    background: rgba(99, 102, 241, 0.5);
    border-radius: 3px;
}

.terminal-output::-webkit-scrollbar-thumb:hover {
    background: rgba(99, 102, 241, 0.7);
}

.terminal-line {
    margin-bottom: 4px;
    word-wrap: break-word;
}

.terminal-line.terminal-empty {
    height: 1em;
}

.terminal-welcome {
    color: var(--secondary);
    font-weight: 500;
}

.terminal-info {
    color: var(--text-secondary);
}

.cmd-highlight {
    color: var(--primary-light);
    background: rgba(99, 102, 241, 0.2);
    padding: 2px 6px;
    border-radius: 4px;
}

.terminal-command {
    color: var(--text-primary);
}

.terminal-command .prompt {
    color: var(--primary);
}

.terminal-response {
    color: var(--text-secondary);
    padding-left: 0;
}

.terminal-error {
    color: #ef4444;
}

.terminal-success {
    color: #10b981;
}

.terminal-heading {
    color: var(--secondary);
    font-weight: 600;
    margin-top: 8px;
}

.terminal-link {
    color: var(--primary-light);
    text-decoration: underline;
    cursor: pointer;
}

.terminal-link:hover {
    color: var(--secondary);
}

.terminal-ascii {
    color: var(--primary);
    white-space: pre;
    font-size: 0.7rem;
    line-height: 1.2;
}

.terminal-table {
    display: grid;
    grid-template-columns: auto 1fr;
    gap: 4px 16px;
    margin: 8px 0;
}

.terminal-table-key {
    color: var(--primary-light);
}

.terminal-table-value {
    color: var(--text-secondary);
}

.terminal-input-line {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-top: 8px;
    padding-top: 8px;
    border-top: 1px solid rgba(255, 255, 255, 0.05);
}

.terminal-prompt {
    color: var(--primary);
    white-space: nowrap;
}

.terminal-input {
    flex: 1;
    background: transparent;
    border: none;
    outline: none;
    color: var(--text-primary);
    font-family: inherit;
    font-size: inherit;
    caret-color: var(--primary);
}

.terminal-input::placeholder {
    color: var(--text-muted);
}

.terminal-cursor {
    display: none;
}

/* Terminal tag styling for command outputs */
.terminal-tag {
    display: inline-block;
    padding: 2px 8px;
    margin: 2px 4px 2px 0;
    background: rgba(99, 102, 241, 0.15);
    border: 1px solid rgba(99, 102, 241, 0.3);
    border-radius: 12px;
    font-size: 0.8rem;
    color: var(--text-secondary);
}

.terminal-project {
    margin: 8px 0;
    padding: 8px 12px;
    background: rgba(255, 255, 255, 0.03);
    border-left: 3px solid var(--primary);
    border-radius: 0 8px 8px 0;
}

.terminal-project-title {
    color: var(--text-primary);
    font-weight: 500;
}

.terminal-project-desc {
    color: var(--text-muted);
    font-size: 0.85rem;
    margin-top: 4px;
}

/* Matrix rain effect for easter egg */
.matrix-rain {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    pointer-events: none;
    overflow: hidden;
    opacity: 0.3;
}

/* Responsive terminal */
@media (max-width: 768px) {
    .terminal-toggle {
        bottom: 20px;
        right: 20px;
        width: 50px;
        height: 50px;
    }

    .terminal-toggle i {
        font-size: 1.2rem;
    }

    .terminal-container {
        bottom: 80px;
        right: 10px;
        left: 10px;
    }

    .terminal-window {
        width: 100%;
        height: 350px;
    }

    .terminal-body {
        font-size: 0.8rem;
    }
}

@media (max-width: 480px) {
    .terminal-window {
        height: 300px;
    }

    .terminal-prompt {
        font-size: 0.75rem;
    }
}

/* ========================================
   Animations & Utilities
   ======================================== */
.fade-in {
    opacity: 0;
    transform: translateY(30px);
    transition: opacity 0.6s ease, transform 0.6s ease;
}

.fade-in.visible {
    opacity: 1;
    transform: translateY(0);
}

/* Loading Animation */
@keyframes shimmer {
    0% { background-position: -200% 0; }
    100% { background-position: 200% 0; }
}

.loading {
    background: linear-gradient(90deg,
        var(--glass-bg) 25%,
        rgba(255, 255, 255, 0.1) 50%,
        var(--glass-bg) 75%
    );
    background-size: 200% 100%;
    animation: shimmer 1.5s infinite;
}
