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

:root {
    --primary-color: #2c3e50;
    --text-color: #333;
    --light-text: #666;
    --border-color: #e0e0e0;
    --hover-color: #1a252f;
    --background: #ffffff;
    --spacing-unit: 1.5rem;
}

body {
    font-family: 'Lato', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
    font-size: 16px;
    line-height: 1.7;
    color: var(--text-color);
    background-color: var(--background);
    font-weight: 300;
}

h1, h2, h3, h4, h5, h6 {
    font-family: 'Crimson Text', Georgia, serif;
    font-weight: 600;
    line-height: 1.3;
    margin-bottom: 1rem;
    color: var(--primary-color);
}

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

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

h3 {
    font-size: 1.5rem;
    margin-top: 1.5rem;
}

p {
    margin-bottom: 1rem;
}

a {
    color: var(--primary-color);
    text-decoration: none;
    transition: color 0.3s ease;
}

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

.container {
    max-width: 1100px;
    margin: 0 auto;
    padding: 0 2rem;
}

/* Header styles */
.site-header {
    background-color: var(--background);
    border-bottom: 1px solid var(--border-color);
    padding: 1.5rem 0;
    position: sticky;
    top: 0;
    z-index: 100;
    backdrop-filter: blur(10px);
    background-color: rgba(255, 255, 255, 0.95);
}

.header-content {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 2rem;
}

.site-title a {
    color: var(--primary-color);
    text-decoration: none;
}

.site-title h1 {
    font-size: 1.75rem;
    margin: 0;
    font-weight: 700;
}

.site-title .motto {
    font-size: 0.9rem;
    font-style: italic;
    color: var(--light-text);
    margin: 0.25rem 0 0 0;
    font-family: 'Crimson Text', Georgia, serif;
}

.main-nav ul {
    list-style: none;
    display: flex;
    gap: 2rem;
    align-items: center;
}

.main-nav a {
    font-size: 1rem;
    font-weight: 400;
    text-transform: lowercase;
    letter-spacing: 0.5px;
    padding: 0.5rem 0;
    border-bottom: 2px solid transparent;
    transition: border-color 0.3s ease;
}

.main-nav a:hover,
.main-nav a.active {
    border-bottom-color: var(--primary-color);
}

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

.social-links a {
    color: var(--light-text);
    transition: color 0.3s ease;
    display: flex;
    align-items: center;
}

.social-links a:hover {
    color: var(--primary-color);
}

/* Main content */
main {
    min-height: calc(100vh - 200px);
    padding: 3rem 0;
}

/* Home page hero */
.hero {
    text-align: center;
    padding: 4rem 0 5rem;
    border-bottom: 1px solid var(--border-color);
}

.hero h1 {
    font-size: 3.5rem;
    margin-bottom: 1rem;
}

.hero .motto-large {
    font-size: 1.3rem;
    font-style: italic;
    color: var(--light-text);
    font-family: 'Crimson Text', Georgia, serif;
    max-width: 600px;
    margin: 0 auto;
}

/* Content sections */
.content {
    max-width: 800px;
    margin: 0 auto;
    padding: 2rem 0;
}

.content img {
    max-width: 100%;
    height: auto;
    margin: 2rem 0;
    border-radius: 4px;
}

/* Blog list */
.post-list {
    list-style: none;
    margin-top: 2rem;
}

.post-list li {
    margin-bottom: 2.5rem;
    padding-bottom: 2.5rem;
    border-bottom: 1px solid var(--border-color);
}

.post-list li:last-child {
    border-bottom: none;
}

.post-title {
    font-size: 1.75rem;
    margin-bottom: 0.5rem;
}

.post-meta {
    color: var(--light-text);
    font-size: 0.9rem;
    margin-bottom: 0.75rem;
}

.post-excerpt {
    color: var(--text-color);
}

/* Projects grid */
.projects-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 2rem;
    margin-top: 2rem;
}

.project-card {
    border: 1px solid var(--border-color);
    padding: 1.5rem;
    border-radius: 6px;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.project-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
}

.project-card h3 {
    margin-top: 0;
    font-size: 1.3rem;
}

.project-card p {
    color: var(--light-text);
    font-size: 0.95rem;
}

.project-links {
    margin-top: 1rem;
    display: flex;
    gap: 1rem;
}

.project-links a {
    font-size: 0.9rem;
    padding: 0.4rem 1rem;
    border: 1px solid var(--primary-color);
    border-radius: 4px;
    transition: background-color 0.3s ease, color 0.3s ease;
}

.project-links a:hover {
    background-color: var(--primary-color);
    color: white;
}

/* Footer */
.site-footer {
    background-color: var(--background);
    border-top: 1px solid var(--border-color);
    padding: 2rem 0;
    text-align: center;
    color: var(--light-text);
    font-size: 0.9rem;
}

/* Responsive design */
@media (max-width: 768px) {
    .header-content {
        flex-direction: column;
        gap: 1rem;
    }

    .main-nav ul {
        gap: 1rem;
        flex-wrap: wrap;
        justify-content: center;
    }

    .hero h1 {
        font-size: 2.5rem;
    }

    .hero .motto-large {
        font-size: 1.1rem;
    }

    .projects-grid {
        grid-template-columns: 1fr;
    }

    .container {
        padding: 0 1rem;
    }
}

/* Additional utility styles */
.text-center {
    text-align: center;
}

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

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

code {
    background-color: #f5f5f5;
    padding: 0.2rem 0.4rem;
    border-radius: 3px;
    font-family: 'Courier New', monospace;
    font-size: 0.9em;
}

pre {
    background-color: #f5f5f5;
    padding: 1rem;
    border-radius: 4px;
    overflow-x: auto;
    margin: 1.5rem 0;
}

pre code {
    background: none;
    padding: 0;
}
