@import url('https://fonts.googleapis.com/css2?family=IBM+Plex+Mono:ital,wght@0,300;0,700;1,300&display=swap');

:root {
    /* Dark Theme (Default) - Inspired by GitHub Dark Dimmed/High Contrast */
    --bg-color: #0d1117;
    --text-color: #f0f6fc;
    --text-muted: #8b949e;
    --surface-color: #21262d;
    --surface-hover: #30363d;
    --accent-color: #58a6ff;
    --font-mono: 'IBM Plex Mono', monospace;
    --weight-body: 300;
}

[data-theme="light"] {
    /* Light Theme - Clean and High Contrast */
    --bg-color: #ffffff;
    --text-color: #1f2328;
    --text-muted: #656d76;
    --surface-color: #f6f8fa;
    --surface-hover: #eaeef2;
    --accent-color: #0969da;
    --weight-body: 400;
}


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

a {
    color: var(--accent-color);
    text-decoration: none;
    transition: filter 0.2s, background-color 0.3s, color 0.3s;
}

a:hover {
    text-decoration: underline;
    filter: brightness(1.2);
}

body {
    background-color: var(--bg-color);
    color: var(--text-color);
    font-family: var(--font-mono);
    line-height: 1.6;
    font-weight: var(--weight-body);
    transition: background-color 0.3s, color 0.3s;
}

header {
    max-width: 900px;
    margin: 0 auto;
    padding: 2rem 1rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

nav {
    display: flex;
    gap: 1.5rem;
}

nav a {
    text-decoration: none;
    color: var(--text-color);
    background-color: var(--surface-color);
    padding: 5px 15px;
    font-size: 0.9rem;
    font-weight: 400;
    border-radius: 20px;
}

nav a:hover {
    background-color: var(--accent-color);
    color: var(--bg-color);
    text-decoration: none;
}

nav a.active {
    background-color: var(--accent-color);
    color: var(--bg-color);
}

.theme-toggle {
    background: none;
    border: none;
    color: var(--text-color);
    cursor: pointer;
    font-family: var(--font-mono);
    font-size: 1.2rem;
}

main {
    max-width: 900px;
    margin: 0 auto;
    padding: 0 1rem 4rem;
}

h1,
h2,
h3,
h4 {
    margin-bottom: 1rem;
    line-height: 1.2;
    font-weight: 700;
}

h1 {
    font-size: 2.5rem;
    font-weight: 700;
}

h2 {
    font-size: 1.8rem;
    font-weight: 700;
    margin-top: 2rem;
}

h3 {
    font-size: 1.4rem;
    font-weight: 700;
}

section {
    margin-bottom: 3rem;
}

.intro {
    margin-top: 4rem;
    margin-bottom: 4rem;
}

.intro p {
    font-size: 1.2rem;
}

.project-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 1.5rem;
}

.project-card {
    background-color: var(--surface-color);
    padding: 1.5rem;
    display: flex;
    flex-direction: column;
}

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

.project-card p {
    font-size: 0.9rem;
    margin-bottom: 1rem;
    flex-grow: 1;
}

.project-link {
    text-decoration: none;
    color: var(--text-color);
    font-weight: 700;
}

.project-link::after {
    content: " \2192";
}

footer {
    max-width: 900px;
    margin: 0 auto;
    padding: 4rem 1rem 2rem;
    border-top: 1px solid var(--surface-color);
    display: flex;
    justify-content: space-between;
    align-items: center;
}

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

.social-links a {
    color: var(--text-color);
    font-size: 1.5rem;
    text-decoration: none;
    width: 40px;
    height: 40px;
    /* Fixed height to match width */
    display: flex;
    /* Use flex to center content */
    align-items: center;
    /* Vertical center */
    justify-content: center;
    /* Horizontal center */
    transition: background-color 0.2s, color 0.2s;
}

/* Blog List Styles */
.latest-list {
    list-style: none;
    padding: 0;
}

.latest-item {
    display: flex;
    gap: 2rem;
    margin-bottom: 0.8rem;
    align-items: baseline;
}

.latest-date {
    color: var(--text-muted);
    min-width: 100px;
    font-size: 0.9rem;
}

.latest-title {
    font-weight: 400;
}

/* Filter Styles */
.filters {
    margin-bottom: 2rem;
    display: flex;
    gap: 0.8rem;
    flex-wrap: wrap;
}

.filter-btn {
    background-color: var(--surface-color);
    border: none;
    color: var(--text-color);
    padding: 5px 15px;
    cursor: pointer;
    font-family: var(--font-mono);
    font-size: 0.9rem;
    border-radius: 20px;
    transition: background-color 0.2s, color 0.2s;
}

.filter-btn:hover {
    background-color: var(--accent-color);
    color: var(--bg-color);
}

.filter-btn.active {
    background-color: var(--accent-color);
    color: var(--bg-color);
}

@media (max-width: 600px) {
    header {
        flex-direction: column;
        align-items: flex-start;
        gap: 1rem;
    }

    footer {
        flex-direction: column;
        align-items: center;
        gap: 2rem;
        text-align: center;
    }

    #about-container {
        flex-direction: column;
        align-items: center;
        text-align: center;
    }

    .about-photo {
        margin-bottom: 1.5rem !important;
    }

    .social-links {
        justify-content: center;
    }
}

/* About Section Specifics */
.about-photo {
    width: 80px;
    height: 80px;
    border-radius: 50%;
    object-fit: cover;
    flex-shrink: 0;
}

#about-container {
    display: flex;
    gap: 2.5rem;
    align-items: flex-start;
}

/* Utility Classes */
.text-center {
    text-align: center;
}

.text-success {
    color: #2ea043;
}

.mt-1 {
    margin-top: 1rem;
}

.mt-2 {
    margin-top: 2rem;
}

.mb-1 {
    margin-bottom: 1rem;
}

.mb-2 {
    margin-bottom: 2rem;
}

.section-header {
    font-size: 0.9rem;
    text-transform: uppercase;
    letter-spacing: 0.1rem;
    color: var(--text-muted);
}

.footer-text {
    text-align: center;
    font-size: 0.8rem;
    color: var(--text-muted);
    margin-top: 2rem;
}

.logo-link {
    text-decoration: none;
    font-weight: 700;
    font-size: 1.2rem;
    color: var(--text-color);
}