:root {
    --bg-color: #000000;
    --text-color: #ffffff;
    --text-muted: #888888;
    --font-sans: 'Inter', -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
    --font-mono: 'JetBrains Mono', 'Courier New', Courier, monospace;
    --font-serif: 'Playfair Display', Georgia, serif;
}

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

body {
    background-color: var(--bg-color);
    background-image: 
        linear-gradient(rgba(255, 255, 255, 0.05) 1px, transparent 1px),
        linear-gradient(90deg, rgba(255, 255, 255, 0.05) 1px, transparent 1px);
    background-size: 40px 40px;
    color: var(--text-color);
    font-family: var(--font-sans);
    line-height: 1.6;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
    display: flex;
    flex-direction: column;
    min-height: 100vh;
    padding: 2.5rem;
    position: relative;
    z-index: 0;
    overflow-x: hidden;
}

/* Entrance Animations */
@keyframes fadeBlurIn {
    0% { opacity: 0; filter: blur(8px); transform: translateY(15px); }
    100% { opacity: 1; filter: blur(0); transform: translateY(0); }
}

.animate-in {
    opacity: 0;
    animation: fadeBlurIn 1.2s cubic-bezier(0.16, 1, 0.3, 1) forwards;
}

.delay-1 { animation-delay: 0.1s; }
.delay-2 { animation-delay: 0.3s; }
.delay-3 { animation-delay: 0.5s; }
.delay-4 { animation-delay: 0.7s; }
.delay-typing { animation-delay: 1.6s; }
.delay-proj1 { animation-delay: 1.8s; }
.delay-proj2 { animation-delay: 2.0s; }
.delay-proj3 { animation-delay: 2.2s; }

::selection {
    background: var(--text-color);
    color: var(--bg-color);
}

a {
    color: var(--text-color);
    text-decoration: none;
    transition: color 0.2s, opacity 0.2s;
}

a:hover {
    opacity: 0.7;
}

/* Navbar */
.navbar {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    width: 100%;
}

.nav-left {
    display: flex;
    flex-direction: column;
}

.brand {
    font-family: var(--font-mono);
    font-variant: small-caps;
    font-size: 1.25rem;
    letter-spacing: 0.05em;
    font-weight: 700;
}

.brand .labs {
    text-transform: lowercase;
    font-weight: 400;
}

/* Main */
main {
    flex: 1;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    width: 100%;
    max-width: 720px;
    margin: 0 auto;
    padding: 2rem 0;
}

.hero {
    display: flex;
    flex-direction: column;
    align-items: center;
    width: 100%;
    margin-bottom: 3.5rem;
}

.hero-title {
    font-family: var(--font-serif);
    font-style: italic;
    font-weight: 500;
    font-size: clamp(3.5rem, 8vw, 6rem);
    letter-spacing: -0.02em;
    color: var(--text-color);
    margin: 0;
    text-align: center;
}

#hero-typing::after {
    content: '';
    display: inline-block;
    width: 0.05em;
    height: 0.9em;
    background-color: var(--text-color);
    margin-left: 0.1em;
    vertical-align: middle;
    animation: blink-caret 0.8s step-end infinite;
    transition: opacity 0.5s ease;
}

#hero-typing.finished::after {
    opacity: 0;
    animation: none;
}

@keyframes blink-caret {
    from, to { opacity: 0; }
    50% { opacity: 1; }
}

.hero-tagline {
    font-family: var(--font-serif);
    font-size: clamp(1.5rem, 5vw, 2.25rem);
    font-weight: 400;
    line-height: 1.4;
    color: var(--text-color);
    margin-top: 2rem;
    text-align: center;
    max-width: 600px;
}

/* Projects */
.projects {
    width: 100%;
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    gap: 2.5rem;
}

.project {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    text-align: left;
    gap: 0.4rem;
    width: 100%;
    max-width: 480px;
}

.project-header {
    display: flex;
    align-items: baseline;
    justify-content: flex-start;
    gap: 0.75rem;
}

.project-marker {
    font-family: var(--font-mono);
    font-size: 0.75rem;
    color: var(--text-muted);
}

.project-title {
    font-size: 0.95rem;
    font-weight: 500;
}

.project-desc {
    color: var(--text-muted);
    font-size: 0.85rem;
    padding-left: 0;
}

.arrow-link {
    display: inline-block;
    margin-left: 0.5rem;
    font-family: var(--font-mono);
    font-size: 0.75rem;
    color: var(--text-color);
}

.arrow-link:hover {
    text-decoration: underline;
}

.location-stamp {
    position: fixed;
    bottom: 2.5rem;
    left: 2.5rem;
    font-family: var(--font-mono);
    font-size: 0.75rem;
    color: var(--text-muted);
    z-index: 10;
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

/* Footer */
.footer {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 1rem;
    font-family: var(--font-mono);
    font-size: 0.8rem;
    color: var(--text-muted);
    padding-top: 3rem;
    padding-bottom: 1rem;
}

.footer a {
    color: var(--text-muted);
}

.footer a:hover {
    color: var(--text-color);
}

.separator {
    opacity: 0.3;
}

.social-icons {
    display: flex;
    align-items: center;
    gap: 1rem;
}

.social-icon {
    display: flex;
    align-items: center;
    justify-content: center;
}

.social-icon svg {
    display: block;
}

/* About Page Specific */
.about-main {
    align-items: center;
    justify-content: flex-start;
    padding: 6rem 0;
}

.about-content {
    width: 100%;
    display: flex;
    flex-direction: column;
    align-items: center;
}

.about-heading {
    font-family: var(--font-sans);
    font-weight: 600;
    font-size: clamp(2rem, 5vw, 2.5rem);
    margin-bottom: 3.5rem;
    color: var(--text-color);
    text-align: center;
}

.about-text {
    display: flex;
    flex-direction: column;
    align-items: center;
    max-width: 680px;
    margin: 0 auto 5rem auto;
}

.about-text p {
    font-family: var(--font-mono);
    font-size: 0.95rem;
    line-height: 1.8;
    color: var(--text-muted);
    margin-bottom: 2.2rem;
    text-align: center;
}

.about-text p strong {
    color: var(--text-color);
    font-weight: 700;
}

.contact-info {
    font-family: var(--font-mono);
    font-size: 0.85rem;
    color: var(--text-muted);
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.6rem;
}

.contact-info {
    font-family: var(--font-mono);
    font-size: 0.85rem;
    color: var(--text-muted);
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.6rem;
    text-align: center;
}

.contact-email {
    color: var(--text-color) !important;
    white-space: nowrap;
    text-decoration: none;
}

.contact-email:hover {
    text-decoration: underline;
}

/* Responsive adjustments */
@media (max-width: 600px) {
    body {
        padding: 1.5rem;
    }
    
    .nav-left {
        max-width: 70%;
    }

    .hero-title {
        font-size: clamp(2.5rem, 10vw, 3.5rem);
        letter-spacing: -0.04em;
    }

    .location-stamp {
        position: static;
        text-align: center;
        margin-top: 1rem;
        margin-bottom: 0rem;
    }
    
    .project-header {
        flex-direction: column;
        gap: 0.2rem;
    }
    
    .project-marker {
        display: none;
    }
    
    .project-desc {
        padding-left: 0;
    }
}
