/* 
 * Main Stylesheet for Minimal Blog Theme
 */

/* ==========================================================================
   Basic Setup
   ========================================================================== */
:root {
    --color-text: #292929;
    --color-background: #ffffff;
    --color-light-gray: #f6f6f6;
    --color-medium-gray: #e1e1e1;
    --color-dark-gray: #666666;
    --color-accent: #1a73e8;
    --font-heading: 'Merriweather', Georgia, serif;
    --font-body: 'Source Sans Pro', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen-Sans, Ubuntu, Cantarell, 'Helvetica Neue', sans-serif;
}

html {
    font-size: 16px;
    box-sizing: border-box;
}

*, *:before, *:after {
    box-sizing: inherit;
}

body {
    background-color: var(--color-background);
    color: var(--color-text);
    font-family: var(--font-body);
    font-size: 1rem;
    line-height: 1.7;
    margin: 0;
    padding: 0;
}

h1, h2, h3, h4, h5, h6 {
    font-family: var(--font-heading);
    font-weight: 700;
    line-height: 1.3;
    margin: 2rem 0 1rem;
}

h1 {
    font-size: 2.5rem;
}

h2 {
    font-size: 2rem;
}

h3 {
    font-size: 1.75rem;
}

h4 {
    font-size: 1.5rem;
}

a {
    color: var(--color-accent);
    text-decoration: none;
    transition: color 0.2s ease;
}

a:hover, a:focus {
    text-decoration: underline;
}

p {
    margin: 0 0 1.5em;
}

img {
    height: auto;
    max-width: 100%;
}

/* ==========================================================================
   Layout
   ========================================================================== */
.site {
    display: flex;
    flex-direction: column;
    min-height: 100vh;
}

.site-content {
    flex-grow: 1;
    margin: 0 auto;
    max-width: 80rem;
    padding: 2rem 1rem;
    width: 100%;
}

.content-area {
    margin: 0 auto;
    max-width: 50rem;
}

/* ==========================================================================
   Header
   ========================================================================== */
.site-header {
    background-color: var(--color-background);
    border-bottom: 1px solid var(--color-medium-gray);
    padding: 2rem 1rem;
    text-align: center;
}

.site-branding {
    margin-bottom: 1rem;
}

.site-title {
    font-family: var(--font-heading);
    font-size: 2.5rem;
    font-weight: 700;
    margin: 0;
}

.site-title a {
    color: var(--color-text);
}

.site-title a:hover,
.site-title a:focus {
    text-decoration: none;
}

.site-description {
    color: var(--color-dark-gray);
    font-size: 1.25rem;
    font-weight: 400;
    margin: 0.5rem 0 0;
}

/* Navigation */
.main-navigation {
    display: flex;
    justify-content: center;
}

.main-navigation ul {
    display: flex;
    list-style: none;
    margin: 0;
    padding: 0;
}

.main-navigation li {
    margin: 0 1rem;
}

.main-navigation a {
    color: var(--color-text);
    font-size: 1rem;
    font-weight: 600;
    text-transform: uppercase;
}

.menu-toggle {
    background-color: transparent;
    border: 1px solid var(--color-medium-gray);
    border-radius: 3px;
    color: var(--color-text);
    display: none;
    font-size: 1rem;
    padding: 0.5rem 1rem;
}

/* ==========================================================================
   Posts and Pages
   ========================================================================== */
.post, .page {
    margin-bottom: 4rem;
}

.entry-header {
    margin-bottom: 2rem;
    text-align: center;
}

.post-thumbnail {
    margin-bottom: 1.5rem;
    overflow: hidden;
}

.post-thumbnail img {
    display: block;
    transition: transform 0.3s ease;
}

.post-thumbnail a:hover img,
.post-thumbnail a:focus img {
    transform: scale(1.03);
}

.entry-title {
    margin-top: 0;
}

.entry-title a {
    color: var(--color-text);
}

.entry-meta {
    color: var(--color-dark-gray);
    font-size: 0.9rem;
    margin-top: 0.5rem;
}

.entry-content {
    margin-bottom: 2rem;
}

.entry-content p:first-child {
    font-size: 1.1rem;
    line-height: 1.6;
}

.entry-footer {
    border-top: 1px solid var(--color-medium-gray);
    color: var(--color-dark-gray);
    font-size: 0.9rem;
    margin-top: 2rem;
    padding-top: 1rem;
}

.cat-links, .tags-links {
    display: block;
    margin-bottom: 0.5rem;
}

.read-more {
    background-color: var(--color-accent);
    border-radius: 3px;
    color: white;
    display: inline-block;
    font-size: 0.9rem;
    font-weight: 600;
    padding: 0.5rem 1rem;
    text-transform: uppercase;
}

.read-more:hover,
.read-more:focus {
    background-color: #0d62d0;
    text-decoration: none;
}

/* Post Navigation */
.post-navigation-container {
    border-top: 1px solid var(--color-medium-gray);
    border-bottom: 1px solid var(--color-medium-gray);
    margin: 2rem 0;
    padding: 1rem 0;
}

.post-navigation {
    display: flex;
    justify-content: space-between;
}

.post-navigation .nav-previous,
.post-navigation .nav-next {
    width: 48%;
}

.post-navigation .nav-next {
    text-align: right;
}

/* ==========================================================================
   Newsletter Form
   ========================================================================== */
.newsletter-container {
    margin: 3rem 0;
}

.newsletter-signup {
    background-color: var(--color-light-gray);
    border-radius: 5px;
    padding: 2rem;
    text-align: center;
}

.newsletter-signup h3 {
    font-size: 1.5rem;
    margin-top: 0;
}

.newsletter-form {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    margin: 1.5rem 0 1rem;
}

.newsletter-form input[type="email"] {
    border: 1px solid var(--color-medium-gray);
    border-radius: 3px;
    flex-grow: 1;
    font-size: 1rem;
    margin-right: 0.5rem;
    min-width: 200px;
    padding: 0.75rem 1rem;
}

.newsletter-form button {
    background-color: var(--color-accent);
    border: none;
    border-radius: 3px;
    color: white;
    cursor: pointer;
    font-size: 1rem;
    font-weight: 600;
    padding: 0.75rem 1.5rem;
    text-transform: uppercase;
    transition: background-color 0.2s ease;
}

.newsletter-form button:hover,
.newsletter-form button:focus {
    background-color: #0d62d0;
}

.form-note {
    color: var(--color-dark-gray);
    font-size: 0.9rem;
    margin-bottom: 0;
}

/* ==========================================================================
   Footer
   ========================================================================== */
.site-footer {
    background-color: var(--color-light-gray);
    padding: 3rem 1rem;
    text-align: center;
}

.footer-widgets {
    margin: 0 auto 2rem;
    max-width: 50rem;
}

.widget-area {
    margin-bottom: 2rem;
}

.widget {
    margin-bottom: 2rem;
}

.widget-title {
    font-size: 1.25rem;
}

.footer-navigation ul {
    display: flex;
    justify-content: center;
    list-style: none;
    margin: 0 0 2rem;
    padding: 0;
}

.footer-navigation li {
    margin: 0 1rem;
}

.site-info {
    color: var(--color-dark-gray);
    font-size: 0.9rem;
}

/* ==========================================================================
   Media Queries
   ========================================================================== */
@media screen and (max-width: 768px) {
    .site-title {
        font-size: 2rem;
    }
    
    .site-description {
        font-size: 1rem;
    }
    
    h1 {
        font-size: 2rem;
    }
    
    h2 {
        font-size: 1.75rem;
    }
    
    h3 {
        font-size: 1.5rem;
    }
    
    .menu-toggle {
        display: block;
        margin: 0 auto;
    }
    
    .main-navigation ul {
        display: none;
        flex-direction: column;
        margin-top: 1rem;
    }
    
    .main-navigation.toggled ul {
        display: flex;
    }
    
    .main-navigation li {
        margin: 0.5rem 0;
    }
    
    .newsletter-form {
        flex-direction: column;
    }
    
    .newsletter-form input[type="email"] {
        margin-bottom: 1rem;
        margin-right: 0;
        width: 100%;
    }
    
    .footer-navigation ul {
        flex-wrap: wrap;
    }
    
    .footer-navigation li {
        margin: 0.5rem;
    }
}