/* Reset and Base Styles */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

:root {
    --primary-color: #2c3e50;
    --secondary-color: #34495e;
    --accent-color: #3498db;
    --text-color: #2c3e50;
    --text-light: #5a6c7d;
    --border-color: #e1e8ed;
    --background: #ffffff;
    --background-alt: #f8f9fa;
    --max-width: 1200px;
    --max-reading-width: 800px;
}

html {
    scroll-behavior: smooth;
}

body {
    font-family: 'Georgia', 'Garamond', 'Times New Roman', serif;
    color: var(--text-color);
    line-height: 1.8;
    background: var(--background);
    font-size: 18px;
}

/* Header */
.site-header {
    background: var(--background);
    border-bottom: 1px solid var(--border-color);
    position: sticky;
    top: 0;
    z-index: 1000;
    box-shadow: 0 2px 4px rgba(0,0,0,0.05);
}

.header-container {
    max-width: var(--max-width);
    margin: 0 auto;
    padding: 0 30px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    height: 80px;
}

.site-logo a {
    font-size: 28px;
    font-weight: 400;
    color: var(--primary-color);
    text-decoration: none;
    letter-spacing: 1px;
}

.main-nav {
    display: flex;
    gap: 35px;
}

.main-nav a {
    color: var(--text-light);
    text-decoration: none;
    font-size: 16px;
    transition: color 0.3s;
    position: relative;
}

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

.main-nav a.active::after {
    content: '';
    position: absolute;
    bottom: -8px;
    left: 0;
    right: 0;
    height: 2px;
    background: var(--primary-color);
}

.mobile-nav-toggle {
    display: none;
    flex-direction: column;
    gap: 5px;
    background: none;
    border: none;
    cursor: pointer;
    padding: 5px;
}

.mobile-nav-toggle span {
    display: block;
    width: 25px;
    height: 2px;
    background: var(--primary-color);
    transition: all 0.3s;
}

/* Hero Section */
.hero {
    padding: 100px 30px;
    background: linear-gradient(135deg, #f8f9fa 0%, #e9ecef 100%);
    text-align: center;
}

.hero-content {
    max-width: 800px;
    margin: 0 auto;
}

.hero-title {
    font-size: 64px;
    font-weight: 400;
    margin-bottom: 15px;
    color: var(--primary-color);
    letter-spacing: 2px;
}

.hero-tagline {
    font-size: 24px;
    color: var(--text-light);
    margin-bottom: 30px;
    letter-spacing: 4px;
    text-transform: uppercase;
    font-size: 16px;
}

.hero-intro {
    font-size: 20px;
    line-height: 1.8;
    margin-bottom: 40px;
    color: var(--secondary-color);
}

.hero-actions {
    display: flex;
    gap: 15px;
    justify-content: center;
    flex-wrap: wrap;
}

/* Buttons */
.btn {
    display: inline-block;
    padding: 14px 32px;
    text-decoration: none;
    border-radius: 4px;
    font-size: 16px;
    transition: all 0.3s;
    border: 2px solid transparent;
    cursor: pointer;
    font-family: 'Georgia', 'Garamond', serif;
}

.btn-primary {
    background: var(--primary-color);
    color: white;
}

.btn-primary:hover {
    background: var(--secondary-color);
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0,0,0,0.15);
}

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

.btn-secondary:hover {
    background: #2980b9;
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0,0,0,0.15);
}

.btn-outline {
    background: transparent;
    color: var(--primary-color);
    border: 2px solid var(--primary-color);
}

.btn-outline:hover {
    background: var(--primary-color);
    color: white;
}

/* Sections */
.featured-section {
    padding: 80px 30px;
}

.featured-section.alt {
    background: var(--background-alt);
}

.section-container {
    max-width: var(--max-width);
    margin: 0 auto;
}

.section-title {
    font-size: 42px;
    font-weight: 400;
    margin-bottom: 50px;
    text-align: center;
    color: var(--primary-color);
}

.section-footer {
    text-align: center;
    margin-top: 50px;
}

.link-arrow {
    color: var(--accent-color);
    text-decoration: none;
    font-size: 18px;
    transition: color 0.3s;
}

.link-arrow:hover {
    color: #2980b9;
}

/* Featured Grid */
.featured-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 40px;
}

.featured-card {
    background: var(--background);
    padding: 35px;
    border-radius: 8px;
    box-shadow: 0 2px 12px rgba(0,0,0,0.08);
    transition: transform 0.3s, box-shadow 0.3s;
}

.featured-section.alt .featured-card {
    background: white;
}

.featured-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 8px 24px rgba(0,0,0,0.12);
}

.card-title {
    font-size: 26px;
    font-weight: 400;
    margin-bottom: 12px;
}

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

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

.card-date {
    font-size: 14px;
    color: var(--text-light);
    margin-bottom: 15px;
    text-transform: uppercase;
    letter-spacing: 1px;
}

.card-excerpt {
    color: var(--text-light);
    line-height: 1.8;
    margin-bottom: 20px;
}

.poem-preview {
    font-family: 'Courier New', monospace;
    white-space: pre-wrap;
    font-size: 15px;
    line-height: 1.9;
}

.card-link {
    color: var(--accent-color);
    text-decoration: none;
    font-size: 15px;
    font-weight: 500;
    transition: color 0.3s;
}

.card-link:hover {
    color: #2980b9;
}

/* Welcome Section */
.welcome-section {
    padding: 100px 30px;
    text-align: center;
}

.welcome-content {
    max-width: 600px;
    margin: 0 auto;
}

.welcome-content h2 {
    font-size: 42px;
    font-weight: 400;
    margin-bottom: 20px;
    color: var(--primary-color);
}

.welcome-content p {
    font-size: 20px;
    color: var(--text-light);
    line-height: 1.8;
}

/* Page Layout */
.page-header {
    padding: 80px 30px 40px;
    text-align: center;
    background: var(--background-alt);
}

.page-title {
    font-size: 52px;
    font-weight: 400;
    color: var(--primary-color);
    margin-bottom: 15px;
}

.page-subtitle {
    font-size: 20px;
    color: var(--text-light);
}

.page-content {
    max-width: var(--max-reading-width);
    margin: 60px auto;
    padding: 0 30px;
}

/* About Page */
.about-hero {
    display: flex;
    gap: 60px;
    align-items: start;
    margin-bottom: 60px;
}

.about-photo {
    flex-shrink: 0;
}

.about-photo img {
    width: 300px;
    height: 300px;
    object-fit: cover;
    border-radius: 8px;
    box-shadow: 0 8px 24px rgba(0,0,0,0.12);
}

.about-text {
    flex: 1;
}

.about-text p {
    margin-bottom: 25px;
    line-height: 1.9;
    font-size: 19px;
}

/* Writing Archive (Stories/Poetry/Blog) */
.archive-grid {
    display: grid;
    gap: 40px;
    max-width: 900px;
    margin: 0 auto;
    padding: 60px 30px;
}

.archive-item {
    padding-bottom: 40px;
    border-bottom: 1px solid var(--border-color);
}

.archive-item:last-child {
    border-bottom: none;
}

.archive-title {
    font-size: 32px;
    font-weight: 400;
    margin-bottom: 12px;
}

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

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

.archive-meta {
    font-size: 14px;
    color: var(--text-light);
    margin-bottom: 20px;
    text-transform: uppercase;
    letter-spacing: 1px;
}

.archive-excerpt {
    color: var(--text-light);
    line-height: 1.8;
    margin-bottom: 15px;
}

/* Single Post */
.single-header {
    padding: 80px 30px 40px;
    text-align: center;
    background: var(--background-alt);
}

.single-title {
    font-size: 52px;
    font-weight: 400;
    color: var(--primary-color);
    margin-bottom: 20px;
    line-height: 1.3;
}

.single-meta {
    font-size: 15px;
    color: var(--text-light);
    text-transform: uppercase;
    letter-spacing: 1px;
}

.single-content {
    max-width: var(--max-reading-width);
    margin: 60px auto 80px;
    padding: 0 30px;
}

.single-content p {
    margin-bottom: 25px;
    line-height: 1.9;
    font-size: 19px;
}

.poem-content {
    font-family: 'Courier New', monospace;
    white-space: pre-wrap;
    line-height: 2;
    font-size: 17px;
    max-width: 700px;
    margin: 0 auto;
}

.back-link {
    display: inline-block;
    margin-bottom: 30px;
    color: var(--accent-color);
    text-decoration: none;
    transition: color 0.3s;
}

.back-link:hover {
    color: #2980b9;
}

/* Contact Form */
.contact-container {
    max-width: 700px;
    margin: 60px auto;
    padding: 0 30px;
}

.contact-info {
    text-align: center;
    margin-bottom: 50px;
}

.contact-info p {
    font-size: 19px;
    color: var(--text-light);
    line-height: 1.8;
    margin-bottom: 15px;
}

.contact-email {
    color: var(--accent-color);
    text-decoration: none;
    font-size: 20px;
}

.contact-form {
    background: var(--background-alt);
    padding: 50px;
    border-radius: 8px;
    box-shadow: 0 2px 12px rgba(0,0,0,0.08);
}

.form-group {
    margin-bottom: 25px;
}

.form-group label {
    display: block;
    margin-bottom: 8px;
    color: var(--primary-color);
    font-size: 16px;
    font-weight: 500;
}

.form-group input,
.form-group textarea {
    width: 100%;
    padding: 14px 16px;
    border: 1px solid var(--border-color);
    border-radius: 4px;
    font-size: 16px;
    font-family: 'Georgia', 'Garamond', serif;
    transition: border-color 0.3s;
}

.form-group input:focus,
.form-group textarea:focus {
    outline: none;
    border-color: var(--accent-color);
}

.form-group textarea {
    resize: vertical;
    min-height: 200px;
}

.form-message {
    padding: 15px 20px;
    border-radius: 4px;
    margin-bottom: 25px;
    text-align: center;
}

.form-message.success {
    background: #d4edda;
    color: #155724;
    border: 1px solid #c3e6cb;
}

.form-message.error {
    background: #f8d7da;
    color: #721c24;
    border: 1px solid #f5c6cb;
}

/* Blog Search */
.blog-search {
    max-width: 900px;
    margin: 40px auto;
    padding: 0 30px;
}

.search-form {
    display: flex;
    gap: 10px;
}

.search-form input {
    flex: 1;
    padding: 12px 16px;
    border: 1px solid var(--border-color);
    border-radius: 4px;
    font-size: 16px;
    font-family: 'Georgia', 'Garamond', serif;
}

.search-form button {
    padding: 12px 30px;
    background: var(--primary-color);
    color: white;
    border: none;
    border-radius: 4px;
    font-size: 16px;
    cursor: pointer;
    transition: background 0.3s;
    font-family: 'Georgia', 'Garamond', serif;
}

.search-form button:hover {
    background: var(--secondary-color);
}

.category-badge {
    display: inline-block;
    padding: 4px 12px;
    background: var(--background-alt);
    color: var(--text-light);
    border-radius: 12px;
    font-size: 13px;
    text-decoration: none;
    transition: background 0.3s;
}

.category-badge:hover {
    background: var(--border-color);
}

/* Empty State */
.empty-state {
    text-align: center;
    padding: 100px 30px;
}

.empty-icon {
    font-size: 64px;
    margin-bottom: 20px;
}

.empty-state h2 {
    font-size: 32px;
    font-weight: 400;
    margin-bottom: 15px;
    color: var(--primary-color);
}

.empty-state p {
    font-size: 18px;
    color: var(--text-light);
}

/* Footer */
.site-footer {
    background: var(--primary-color);
    color: white;
    padding: 50px 30px;
    text-align: center;
    margin-top: 80px;
}

.footer-content p {
    margin-bottom: 8px;
}

.footer-tagline {
    opacity: 0.8;
    font-size: 14px;
    letter-spacing: 2px;
    text-transform: uppercase;
}

/* Responsive */
@media (max-width: 768px) {
    body {
        font-size: 16px;
    }

    .header-container {
        padding: 0 20px;
    }

    .mobile-nav-toggle {
        display: flex;
    }

    .main-nav {
        position: fixed;
        top: 80px;
        left: 0;
        right: 0;
        flex-direction: column;
        background: var(--background);
        padding: 20px;
        gap: 20px;
        box-shadow: 0 4px 8px rgba(0,0,0,0.1);
        display: none;
    }

    .main-nav.active {
        display: flex;
    }

    .main-nav a.active::after {
        display: none;
    }

    .hero {
        padding: 60px 20px;
    }

    .hero-title {
        font-size: 42px;
    }

    .hero-tagline {
        font-size: 14px;
    }

    .hero-intro {
        font-size: 18px;
    }

    .hero-actions {
        flex-direction: column;
        align-items: stretch;
    }

    .featured-section {
        padding: 60px 20px;
    }

    .section-title {
        font-size: 32px;
    }

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

    .page-header {
        padding: 60px 20px 30px;
    }

    .page-title {
        font-size: 36px;
    }

    .page-content {
        margin: 40px auto;
        padding: 0 20px;
    }

    .about-hero {
        flex-direction: column;
        gap: 30px;
    }

    .about-photo img {
        width: 100%;
        height: auto;
        max-width: 300px;
    }

    .archive-grid {
        padding: 40px 20px;
    }

    .archive-title {
        font-size: 26px;
    }

    .single-header {
        padding: 60px 20px 30px;
    }

    .single-title {
        font-size: 36px;
    }

    .single-content {
        margin: 40px auto 60px;
        padding: 0 20px;
    }

    .contact-container {
        margin: 40px auto;
        padding: 0 20px;
    }

    .contact-form {
        padding: 30px 25px;
    }

    .blog-search {
        padding: 0 20px;
    }

    .search-form {
        flex-direction: column;
    }
}
