/* Design Tokens */
:root {
    /* Colors */
    --color-text-primary: #111111;
    --color-text-secondary: #555555;
    --color-text-tertiary: #999999;
    --color-text-inverse: #e0e0e0;
    --color-bg-primary: #ffffff;
    --color-bg-dark: #1a1a1a;
    --color-accent: #6366f1;
    --color-accent-hover: #005fcc;
    --color-border: #f0f0f0;
    --color-border-dark: #333333;

    /* Spacing */
    --space-xs: 0.5rem;
    --space-sm: 1rem;
    --space-md: 1.5rem;
    --space-lg: 2rem;
    --space-xl: 3rem;

    /* Border radius */
    --radius-sm: 4px;
    --radius-md: 8px;
}

/* Reset and base styles */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    font-family: 'JetBrains Mono', 'Courier New', 'Monaco', 'Menlo', 'Consolas', monospace;
    font-size: 16px;
    font-weight: 400;
    line-height: 1.6;
    color: var(--color-text-primary);
    background-color: var(--color-bg-primary);
}

/* Layout */
.container {
    width: 100%;
    max-width: 720px;
    margin: 0 auto;
    padding: 2rem 1rem;
}

/* Breadcrumbs */
.breadcrumbs {
    font-size: 0.875rem;
    color: var(--color-text-secondary);
    margin-bottom: 1.5rem;
}

.breadcrumbs a {
    color: var(--color-text-secondary);
    text-decoration: none;
    transition: color 0.2s ease;
}

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

/* Typography */
h1 {
    font-size: 2rem;
    font-weight: 700;
    margin-bottom: 0.5rem;
    color: #000000;
}

h2 {
    font-size: 1.5rem;
    font-weight: 700;
    margin-bottom: 0.5rem;
    color: #000000;
}

h3 {
    font-size: 1.125rem;
    font-weight: 600;
    margin-bottom: 0.25rem;
}

p {
    margin-bottom: 1rem;
    color: #111111;
}

/* Links */
.link {
    color: inherit;
    text-decoration: underline;
    transition: color 0.2s ease, text-decoration 0.2s ease;
}

.link:hover {
    color: #005fcc;
    text-decoration: none;
}

/* Sections */
.section {
    margin-bottom: 3rem;
    opacity: 0;
    transform: translateY(20px);
    animation: slideUp 0.5s ease-out forwards;
    scroll-margin-top: 100px;
}

.section-title {
    margin-bottom: 1.5rem;
}

/* Hero section */
.hero {
    padding: 4rem 0;
    animation-delay: 0.1s;
    margin-bottom: 0;
}

.hero-title {
    margin-bottom: 1rem;
}

.hero-description {
    font-size: 1.125rem;
    color: #555555;
    margin-bottom: 2rem;
}

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

/* About section */
.about {
    animation-delay: 1.3s;
}

/* Projects section */
.projects {
    animation-delay: 0.3s;
}

/* Project styles */
.project-item {
    position: relative;
    opacity: 0;
    transform: translateY(20px);
    animation: slideUp 0.5s ease-out forwards;
}

.projects .project-item:nth-child(1) { animation-delay: 0.4s; }
.projects .project-item:nth-child(2) { animation-delay: 0.5s; }
.projects .project-item:nth-child(3) { animation-delay: 0.6s; }
.projects .project-item:nth-child(4) { animation-delay: 0.7s; }
.projects .project-item:nth-child(5) { animation-delay: 0.8s; }
.projects .project-item:nth-child(6) { animation-delay: 0.9s; }
.projects .project-item:nth-child(7) { animation-delay: 1.0s; }
.projects .project-item:nth-child(8) { animation-delay: 1.1s; }

.project-title {
    margin-bottom: 0.5rem;
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.project-date {
    font-size: 0.875rem;
    color: #999999;
    margin-bottom: 0.5rem;
}

.project-description {
    color: #555555;
    margin-bottom: 0;
}

/* Project styles continued */
.project-item:not(:last-child) {
    margin-bottom: 2.5rem;
}

/* Status badges */
.status-badge {
    font-size: 0.625rem;
    font-weight: 600;
    padding: 0.25rem 0.5rem;
    border-radius: 4px;
    text-transform: lowercase;
    letter-spacing: 0.025em;
    background-color: #000000;
    color: #ffffff;
    line-height: 1;
    flex-shrink: 0;
    margin-left: 1rem;
}

/* Contact section */
.contact {
    animation-delay: 0.8s;
}

/* Footer */
.footer {
    padding: 2rem 0;
    text-align: center;
    font-size: 0.875rem;
    color: #555555;
    border-top: 1px solid #f0f0f0;
    margin-top: 2rem;
    opacity: 0;
    animation: fadeIn 0.6s ease-out forwards;
    animation-delay: 1.0s;
}

/* Animations */
@keyframes fadeIn {
    from {
        opacity: 0;
    }
    to {
        opacity: 1;
    }
}

@keyframes slideUp {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Responsive design */
@media (max-width: 768px) {
    .container {
        padding: 1rem;
    }

    .section {
        scroll-margin-top: 80px;
    }
}

@media (max-width: 640px) {
    .container {
        padding: 1rem 0.75rem;
    }

    h1 {
        font-size: 1.75rem;
        line-height: 1.2;
    }
    
    h2 {
        font-size: 1.25rem;
    }
    
    .hero {
        padding: 1.5rem 0;
        margin-bottom: 0;
    }
    
    .hero-description {
        font-size: 1rem;
        margin-bottom: 1.5rem;
    }
    
    .hero-links {
        gap: 1rem;
        flex-direction: row;
        align-items: flex-start;
    }
    
    .section {
        margin-bottom: 2.5rem;
        scroll-margin-top: 120px;
    }
    
    .section-title {
        margin-bottom: 1rem;
    }
    
    
    .timeline-date {
        font-size: 0.8rem;
        margin-bottom: 0.125rem;
    }
    
    .project-description,
    .article-description {
        font-size: 0.9rem;
        line-height: 1.5;
    }
}

@media (max-width: 480px) {
    .container {
        padding: 0.75rem 0.5rem;
    }

    h1 {
        font-size: 1.5rem;
    }

    h2 {
        font-size: 1.125rem;
    }

    .hero {
        padding: 1rem 0;
    }
    
    .hero-description {
        font-size: 0.95rem;
    }
    
    .section {
        margin-bottom: 2rem;
        scroll-margin-top: 100px;
    }
    
    
    .project-description,
    .article-description {
        font-size: 0.85rem;
    }
    
    .timeline-date {
        font-size: 0.75rem;
    }
}

/* Utility Classes */

/* Highlight boxes */
.highlight-box {
    background: var(--color-bg-dark);
    padding: var(--space-md);
    border-radius: var(--radius-md);
    margin: var(--space-lg) 0;
}

.highlight-box p {
    color: var(--color-text-inverse) !important;
    margin: 0.75rem 0;
}

.highlight-box p:first-child {
    margin-top: 0;
}

.highlight-box p:last-child {
    margin-bottom: 0;
}

.highlight-box pre {
    color: var(--color-text-inverse);
    margin: 0;
}

.highlight-box-accent {
    border-left: 3px solid var(--color-accent);
}

/* Stats box variant */
.stats-box {
    background: var(--color-bg-dark);
    padding: var(--space-md);
    border-radius: var(--radius-md);
    border-left: 3px solid var(--color-accent);
    margin: var(--space-lg) 0;
}

.stats-box p {
    color: var(--color-text-inverse) !important;
    margin: var(--space-xs) 0;
}

/* Diagram box */
.diagram-box {
    background: var(--color-bg-dark);
    padding: var(--space-md);
    border-radius: var(--radius-md);
    margin: var(--space-lg) 0;
}

/* Spacing utilities */
.mt-sm { margin-top: var(--space-sm); }
.mt-md { margin-top: var(--space-md); }
.mt-lg { margin-top: var(--space-lg); }
.mt-xl { margin-top: var(--space-xl); }

.mb-sm { margin-bottom: var(--space-sm); }
.mb-md { margin-bottom: var(--space-md); }
.mb-lg { margin-bottom: var(--space-lg); }
.mb-xl { margin-bottom: var(--space-xl); }