:root {
    --bg: #faf9f7;
    --fg: #1a1a1a;
    --accent: #ff6b35;
    --secondary: #4ecdc4;
    --tertiary: #8b5cf6;
    --border: #e0e0e0;
    --link: #0066cc;
    --success: #16a085;
    --warning: #f39c12;
    --danger: #e74c3c;
    --mono: 'JetBrains Mono', 'Fira Code', 'SF Mono', monospace;
    --serif: 'Playfair Display', 'Georgia', 'Times New Roman', serif;
    --sans: 'Inter', 'Roboto', 'Helvetica Neue', sans-serif;
    --shadow: 0 4px 20px rgba(0,0,0,0.08);
    --shadow-lg: 0 8px 32px rgba(0,0,0,0.12);
    --radius: 12px;
    --radius-lg: 16px;
    --transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    --glass: rgba(255, 255, 255, 0.85);
    --glass-border: rgba(255, 255, 255, 0.2);
}
html, body {
    margin: 0;
    padding: 0;
    background: var(--bg);
    color: var(--fg);
    font-family: var(--sans);
    font-size: 18px;
    line-height: 1.7;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
    text-rendering: optimizeLegibility;
}

/* Enhanced smooth scrolling */
html {
    scroll-behavior: smooth;
    scroll-padding-top: 80px;
}

/* Chic scrollbar */
::-webkit-scrollbar {
    width: 8px;
}

::-webkit-scrollbar-track {
    background: var(--bg);
}

::-webkit-scrollbar-thumb {
    background: linear-gradient(45deg, var(--accent), var(--secondary));
    border-radius: var(--radius);
    border: 1px solid var(--bg);
}

::-webkit-scrollbar-thumb:hover {
    background: linear-gradient(45deg, var(--secondary), var(--tertiary));
}

/* Glass morphism effect */
.glass {
    background: var(--glass);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border: 1px solid var(--glass-border);
    box-shadow: var(--shadow);
}

/* Enhanced selection styling */
::selection {
    background: var(--accent);
    color: white;
}

::-moz-selection {
    background: var(--accent);
    color: white;
}
header {
    background: linear-gradient(135deg, var(--bg) 0%, #f0f0f0 100%);
    border-bottom: 3px solid var(--accent);
    padding: 2em 0 1.5em 0;
    text-align: center;
    position: sticky;
    top: 0;
    z-index: 100;
    backdrop-filter: blur(10px);
    box-shadow: var(--shadow);
}

.site-title {
    font-family: var(--mono);
    font-size: 2.5em;
    color: var(--fg);
    margin: 0 0 0.5em 0;
    letter-spacing: -0.02em;
    font-weight: 700;
    background: linear-gradient(135deg, var(--accent), var(--secondary));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    animation: titlePulse 3s ease-in-out infinite;
}

@keyframes titlePulse {
    0%, 100% { transform: scale(1); }
    50% { transform: scale(1.05); }
}

nav {
    margin-bottom: 1em;
    display: flex;
    justify-content: center;
    flex-wrap: wrap;
    gap: 1em;
}

nav a {
    color: var(--link);
    text-decoration: none;
    font-family: var(--mono);
    font-size: 1.1em;
    font-weight: 500;
    padding: 0.5em 1em;
    border-radius: var(--radius);
    transition: var(--transition);
    position: relative;
    overflow: hidden;
}

nav a::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255,255,255,0.4), transparent);
    transition: var(--transition);
}

nav a:hover::before {
    left: 100%;
}

nav a:hover {
    background: var(--accent);
    color: white;
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0,0,0,0.15);
}
main {
    max-width: 800px;
    margin: 2em auto;
    background: white;
    border-radius: var(--radius);
    padding: 2.5em;
    box-shadow: var(--shadow);
    position: relative;
    overflow: hidden;
}

main::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 4px;
    background: linear-gradient(90deg, var(--accent), var(--secondary), var(--accent));
}

h1, h2, h3 {
    font-family: var(--sans);
    color: var(--fg);
    margin-top: 2em;
    margin-bottom: 0.5em;
    font-weight: 600;
}

h1 {
    font-size: 2.2em;
    margin-top: 0;
    background: linear-gradient(135deg, var(--accent), var(--secondary));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    position: relative;
}

h1::after {
    content: '';
    position: absolute;
    bottom: -0.2em;
    left: 0;
    width: 60px;
    height: 3px;
    background: var(--accent);
    border-radius: var(--radius);
}

h2 {
    font-size: 1.5em;
    color: var(--secondary);
    position: relative;
    padding-left: 1em;
}

h2::before {
    content: '▶';
    position: absolute;
    left: 0;
    color: var(--accent);
    font-size: 0.8em;
}

h3 {
    font-size: 1.2em;
    color: var(--fg);
}
ul, ol {
    padding-left: 1.5em;
    margin-bottom: 1.5em;
}

li {
    margin-bottom: 0.5em;
    position: relative;
}

ul li::before {
    content: '→';
    color: var(--accent);
    font-weight: bold;
    position: absolute;
    left: -1.2em;
}

a {
    color: var(--link);
    text-decoration: none;
    font-weight: 500;
    position: relative;
    transition: var(--transition);
}

a::after {
    content: '';
    position: absolute;
    bottom: -2px;
    left: 0;
    width: 0;
    height: 2px;
    background: var(--accent);
    transition: var(--transition);
}

a:hover::after {
    width: 100%;
}

a:hover {
    color: var(--accent);
}

/* Button styles */
.btn {
    display: inline-block;
    padding: 0.8em 1.5em;
    background: var(--accent);
    color: white;
    border: none;
    border-radius: var(--radius);
    font-family: var(--sans);
    font-weight: 600;
    cursor: pointer;
    transition: var(--transition);
    text-decoration: none;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
}

.btn:hover {
    background: var(--secondary);
    transform: translateY(-2px);
    box-shadow: 0 4px 8px rgba(0,0,0,0.2);
}

.btn:active {
    transform: translateY(0);
}

.btn-secondary {
    background: var(--secondary);
}

.btn-secondary:hover {
    background: var(--accent);
}
img, .dither {
    display: block;
    margin: 1.5em auto;
    max-width: 100%;
    border-radius: var(--radius);
    box-shadow: var(--shadow);
    transition: var(--transition);
}

img:hover {
    transform: scale(1.02);
    box-shadow: 0 4px 16px rgba(0,0,0,0.15);
}

blockquote {
    border-left: 4px solid var(--accent);
    margin: 1.5em 0;
    padding: 1em 1.5em;
    background: linear-gradient(135deg, #f8f9fa, #e9ecef);
    color: var(--fg);
    font-style: italic;
    border-radius: 0 var(--radius) var(--radius) 0;
    position: relative;
    box-shadow: var(--shadow);
}

blockquote::before {
    content: '"';
    position: absolute;
    top: -10px;
    left: 20px;
    font-size: 3em;
    color: var(--accent);
    opacity: 0.3;
}

hr {
    border: none;
    height: 2px;
    background: linear-gradient(90deg, transparent, var(--accent), transparent);
    margin: 2em 0;
}

/* Code blocks */
code {
    background: #f8f9fa;
    padding: 0.2em 0.4em;
    border-radius: 4px;
    font-family: var(--mono);
    font-size: 0.9em;
    color: #d63384;
    border: 1px solid #e9ecef;
}

pre {
    background: #f8f9fa;
    padding: 1.5em;
    border-radius: var(--radius);
    overflow-x: auto;
    border: 1px solid #e9ecef;
    box-shadow: var(--shadow);
}

pre code {
    background: none;
    padding: 0;
    border: none;
    color: var(--fg);
}

/* Loading animation */
.loading {
    display: inline-block;
    width: 20px;
    height: 20px;
    border: 3px solid var(--border);
    border-top: 3px solid var(--accent);
    border-radius: 50%;
    animation: spin 1s linear infinite;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

/* Fade in animation */
.fade-in {
    opacity: 0;
    transform: translateY(20px);
    animation: fadeIn 0.6s ease-out forwards;
}

@keyframes fadeIn {
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Project Page Specific Styles */
.project-hero {
    text-align: center;
    padding: 4rem 0;
    background: linear-gradient(135deg, rgba(var(--primary-rgb), 0.1) 0%, rgba(var(--secondary-rgb), 0.1) 100%);
    border-radius: 20px;
    margin-bottom: 3rem;
}

.project-hero h1 {
    font-size: 3rem;
    margin-bottom: 1rem;
    background: linear-gradient(135deg, var(--primary), var(--secondary));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.project-subtitle {
    font-size: 1.5rem;
    color: var(--text-secondary);
    margin-bottom: 2rem;
    font-style: italic;
}

.project-tags {
    display: flex;
    justify-content: center;
    flex-wrap: wrap;
    gap: 1rem;
}

.tag {
    background: rgba(var(--primary-rgb), 0.1);
    color: var(--primary);
    padding: 0.5rem 1rem;
    border-radius: 25px;
    font-size: 0.9rem;
    font-weight: 500;
    border: 1px solid rgba(var(--primary-rgb), 0.2);
}

.project-content {
    max-width: 1000px;
    margin: 0 auto;
    padding: 0 2rem;
}

.content-section {
    margin-bottom: 4rem;
}

.content-section h2 {
    font-size: 2.5rem;
    margin-bottom: 1.5rem;
    color: var(--primary);
}

.content-section p {
    font-size: 1.1rem;
    line-height: 1.8;
    margin-bottom: 1.5rem;
    color: var(--text-secondary);
}

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

.feature-card {
    background: rgba(var(--card-bg-rgb), 0.5);
    backdrop-filter: blur(10px);
    border: 1px solid rgba(var(--border-rgb), 0.1);
    border-radius: 15px;
    padding: 2rem;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.feature-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 30px rgba(var(--shadow-rgb), 0.3);
}

.feature-card h3 {
    color: var(--primary);
    margin-bottom: 1rem;
    font-size: 1.3rem;
}

/* Technical List */
.technical-list {
    list-style: none;
    padding: 0;
}

.technical-list li {
    background: rgba(var(--card-bg-rgb), 0.3);
    border-left: 4px solid var(--primary);
    padding: 1rem;
    margin-bottom: 1rem;
    border-radius: 0 10px 10px 0;
}

.technical-list li strong {
    color: var(--primary);
}

/* Lesson Grid */
.lesson-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 1.5rem;
    margin: 2rem 0;
}

.lesson-item {
    background: rgba(var(--secondary-rgb), 0.1);
    border: 1px solid rgba(var(--secondary-rgb), 0.2);
    border-radius: 10px;
    padding: 1.5rem;
    text-align: center;
}

.lesson-item h4 {
    color: var(--secondary);
    margin-bottom: 0.5rem;
    font-size: 1.1rem;
}

/* Hackathon Timeline */
.hackathon-timeline {
    position: relative;
    padding-left: 2rem;
}

.hackathon-timeline::before {
    content: '';
    position: absolute;
    left: 0;
    top: 0;
    bottom: 0;
    width: 2px;
    background: linear-gradient(to bottom, var(--primary), var(--secondary));
}

.timeline-item {
    position: relative;
    background: rgba(var(--card-bg-rgb), 0.5);
    backdrop-filter: blur(10px);
    border: 1px solid rgba(var(--border-rgb), 0.1);
    border-radius: 15px;
    padding: 2rem;
    margin-bottom: 2rem;
    margin-left: 2rem;
}

.timeline-item::before {
    content: '';
    position: absolute;
    left: -3rem;
    top: 2rem;
    width: 12px;
    height: 12px;
    background: var(--primary);
    border-radius: 50%;
    border: 3px solid var(--background);
}

.timeline-item h3 {
    color: var(--primary);
    margin-bottom: 1rem;
    font-size: 1.4rem;
}

.timeline-item p {
    margin-bottom: 0.5rem;
}

.timeline-item strong {
    color: var(--text-primary);
}

/* Skill Grid */
.skill-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 2rem;
    margin: 2rem 0;
}

.skill-card {
    background: rgba(var(--tertiary-rgb), 0.1);
    border: 1px solid rgba(var(--tertiary-rgb), 0.2);
    border-radius: 15px;
    padding: 2rem;
    text-align: center;
    transition: transform 0.3s ease;
}

.skill-card:hover {
    transform: translateY(-5px);
}

.skill-card h3 {
    color: var(--tertiary);
    margin-bottom: 1rem;
    font-size: 1.3rem;
}

/* Lesson Cards */
.lesson-cards {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 1.5rem;
    margin: 2rem 0;
}

.lesson-card {
    background: rgba(var(--card-bg-rgb), 0.4);
    backdrop-filter: blur(8px);
    border: 1px solid rgba(var(--border-rgb), 0.1);
    border-radius: 12px;
    padding: 1.5rem;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.lesson-card:hover {
    transform: translateY(-3px);
    box-shadow: 0 8px 25px rgba(var(--shadow-rgb), 0.2);
}

.lesson-card h4 {
    color: var(--primary);
    margin-bottom: 0.5rem;
    font-size: 1.1rem;
}

/* Tools Grid */
.tools-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 2rem;
    margin: 2rem 0;
}

.tool-category {
    background: rgba(var(--card-bg-rgb), 0.3);
    border: 1px solid rgba(var(--border-rgb), 0.1);
    border-radius: 10px;
    padding: 1.5rem;
}

.tool-category h4 {
    color: var(--secondary);
    margin-bottom: 1rem;
    font-size: 1.2rem;
}

.tool-category ul {
    list-style: none;
    padding: 0;
}

.tool-category li {
    padding: 0.5rem 0;
    border-bottom: 1px solid rgba(var(--border-rgb), 0.1);
    color: var(--text-secondary);
}

.tool-category li:last-child {
    border-bottom: none;
}

/* Impact List */
.impact-list {
    list-style: none;
    padding: 0;
}

.impact-list li {
    background: rgba(var(--primary-rgb), 0.1);
    border-left: 4px solid var(--primary);
    padding: 1rem;
    margin-bottom: 1rem;
    border-radius: 0 10px 10px 0;
    position: relative;
}

.impact-list li::before {
    content: '✓';
    position: absolute;
    left: -2px;
    top: 50%;
    transform: translateY(-50%);
    background: var(--primary);
    color: var(--background);
    width: 20px;
    height: 20px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.8rem;
    font-weight: bold;
}

/* CTA Section */
.cta-section {
    background: linear-gradient(135deg, rgba(var(--primary-rgb), 0.1) 0%, rgba(var(--secondary-rgb), 0.1) 100%);
    border-radius: 20px;
    padding: 3rem;
    text-align: center;
    margin-top: 4rem;
}

.cta-section h2 {
    color: var(--primary);
    margin-bottom: 1rem;
}

.cta-buttons {
    display: flex;
    justify-content: center;
    gap: 1rem;
    flex-wrap: wrap;
    margin-top: 2rem;
}

.cta-buttons .btn {
    min-width: 150px;
}

/* Responsive design */
@media (max-width: 900px) {
    main { 
        margin: 1em;
        padding: 1.5em;
    }
    
    .site-title {
        font-size: 2em;
    }
    
    nav {
        gap: 0.5em;
    }
    
    nav a {
        font-size: 1em;
        padding: 0.4em 0.8em;
    }
    
    h1 {
        font-size: 1.8em;
    }
    
    h2 {
        font-size: 1.3em;
    }
}

@media (max-width: 768px) {
    .project-hero h1 {
        font-size: 2.5rem;
    }
    
    .project-subtitle {
        font-size: 1.2rem;
    }
    
    .project-content {
        padding: 0 1rem;
    }
    
    .content-section h2 {
        font-size: 2rem;
    }
    
    .feature-grid,
    .skill-grid,
    .lesson-cards,
    .tools-grid {
        grid-template-columns: 1fr;
    }
    
    .hackathon-timeline {
        padding-left: 1rem;
    }
    
    .timeline-item {
        margin-left: 1rem;
    }
    
    .timeline-item::before {
        left: -2rem;
    }
    
    .cta-section {
        padding: 2rem;
    }
    
    .cta-buttons {
        flex-direction: column;
        align-items: center;
    }
}
#particles-js {
    position: fixed;
    top: 0; 
    left: 0;
    width: 100vw; 
    height: 100vh;
    z-index: -1;
    pointer-events: none;
    opacity: 0.3;
}

body > *:not(#particles-js) {
    position: relative;
    z-index: 1;
}

#particles-js canvas {
    filter: blur(0.5px);
}

/* Theme toggle */
.theme-toggle {
    position: fixed;
    top: 20px;
    right: 20px;
    z-index: 1000;
    background: var(--accent);
    color: white;
    border: none;
    border-radius: 50%;
    width: 50px;
    height: 50px;
    cursor: pointer;
    font-size: 1.2em;
    transition: var(--transition);
    box-shadow: var(--shadow);
}

.theme-toggle:hover {
    background: var(--secondary);
    transform: scale(1.1);
}

/* Dark theme */
[data-theme="dark"] {
    --bg: #1a1a1a;
    --fg: #e0e0e0;
    --accent: #ff6b35;
    --secondary: #4ecdc4;
    --border: #404040;
    --link: #4da6ff;
}

[data-theme="dark"] main {
    background: #2d2d2d;
    color: var(--fg);
}

[data-theme="dark"] header {
    background: linear-gradient(135deg, var(--bg) 0%, #2d2d2d 100%);
}

[data-theme="dark"] code {
    background: #404040;
    color: #e0e0e0;
}

[data-theme="dark"] pre {
    background: #404040;
}

[data-theme="dark"] blockquote {
    background: linear-gradient(135deg, #3a3a3a, #4a4a4a);
}

/* Accessibility improvements */
.sr-only {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    border: 0;
}

/* Focus indicators */
*:focus {
    outline: 2px solid var(--accent);
    outline-offset: 2px;
}

/* Print styles */
@media print {
    header, .theme-toggle, #particles-js {
        display: none;
    }
    
    main {
        box-shadow: none;
        margin: 0;
        padding: 0;
    }
    
    a {
        color: black;
        text-decoration: underline;
    }
}
