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

body {
    font-family: 'Montserrat', sans-serif;
    background-color: #FAFAF8; /* Slightly off-white (drawing paper color) */
    color: #333;
    line-height: 1.6;
    max-width: 900px;
    margin: auto;
    padding: 20px;
}

/* Header */
header {
    text-align: center;
    margin-bottom: 30px;
    padding-bottom: 15px;
    border-bottom: 1px solid #ddd;
}

header h1 {
    font-family: 'Montserrat', sans-serif;
    font-weight: 100;
    font-size: 3rem;
    color: #000;
}

header h3 {
    font-family: 'Oswald', sans-serif;
    font-weight: 400;
    font-size: 1.1rem;
    color: #555;
    margin-top: 5px;
}

.header-divider {
    width: 19ch;
    height: 1px;
    background-color: #000;
    border: none;
    margin: 0 auto;
}

/* Posts Container - centered for flexible clippings */
.posts {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 40px;
}

/* =============================================
   NEWSPAPER CLIPPING EFFECT
   ============================================= */

.clipping {
    /* Flexible sizing - shrinks to fit content */
    display: block;
    width: fit-content;
    max-width: 100%;
    
    /* Aged paper background */
    background: linear-gradient(
        135deg,
        #f5f0e1 0%,
        #f8f4e8 25%,
        #f2edd9 50%,
        #f6f1e3 75%,
        #f4efe0 100%
    );
    
    /* Subtle paper texture overlay */
    background-color: #f5f0e1;
    
    /* Border - adjust this color as needed */
    border: 1px solid #c9c0a8;
    
    /* Drop shadow for depth */
    box-shadow: 
        3px 4px 8px rgba(0, 0, 0, 0.15),
        1px 1px 3px rgba(0, 0, 0, 0.1);
    
    /* Rough cut edges using clip-path */
    clip-path: polygon(
        /* Top edge - rough cuts */
        0% 0.3%,
        4% 0%,
        8% 0.4%,
        15% 0.1%,
        22% 0.5%,
        30% 0%,
        38% 0.3%,
        45% 0.1%,
        52% 0.4%,
        60% 0%,
        68% 0.3%,
        75% 0.1%,
        82% 0.5%,
        90% 0.2%,
        96% 0%,
        100% 0.4%,
        /* Right edge - rough cuts */
        100% 0.4%,
        99.7% 5%,
        100% 12%,
        99.5% 20%,
        100% 28%,
        99.6% 36%,
        100% 45%,
        99.7% 55%,
        100% 65%,
        99.5% 75%,
        100% 85%,
        99.6% 92%,
        100% 99.5%,
        /* Bottom edge - rough cuts */
        100% 99.5%,
        95% 100%,
        88% 99.6%,
        80% 100%,
        72% 99.7%,
        65% 100%,
        57% 99.5%,
        48% 100%,
        40% 99.6%,
        32% 100%,
        24% 99.7%,
        16% 100%,
        8% 99.5%,
        0% 99.8%,
        /* Left edge - rough cuts */
        0% 99.8%,
        0.4% 92%,
        0% 84%,
        0.5% 75%,
        0% 66%,
        0.3% 57%,
        0% 48%,
        0.5% 38%,
        0% 28%,
        0.4% 18%,
        0% 9%,
        0.3% 0.3%
    );
    
    /* Uniform padding inside the clipping */
    padding: 25px;
    
    /* Transition for hover effect */
    transition: box-shadow 0.2s ease, transform 0.2s ease;
}

.clipping:hover {
    box-shadow: 
        4px 5px 12px rgba(0, 0, 0, 0.18),
        2px 2px 4px rgba(0, 0, 0, 0.12);
    transform: translateY(-1px);
}

/* =============================================
   POST STYLES
   ============================================= */

.post h2 {
    font-family: 'Montserrat', sans-serif;
    font-weight: 600;
    font-size: 1.4rem;
    margin-bottom: 5px;
    color: #1a1a1a;
}

.post-date {
    font-family: 'Oswald', sans-serif;
    font-size: 0.8rem;
    color: #6b6252;
    margin-bottom: 15px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.post-content {
    font-size: 1rem;
    font-weight: 400;
    color: #2a2a2a;
}

/* Cartoon-specific styles */
.cartoon-image-container {
    display: inline-block;
}

.cartoon img {
    display: block;
    width: auto;
    height: auto;
    max-width: 100%;
    margin-bottom: 10px;
    /* Subtle border around images */
    border: 1px solid #d4cbb8;
}

.cartoon-caption {
    font-size: 0.9rem;
    font-style: italic;
    font-weight: 600;
    color: #4a4a4a;
    margin: 0;
    text-align: left;
}

/* Essay-specific styles */
.essay-text {
    line-height: 1.7;
}

/* No posts message */
.no-posts {
    text-align: center;
    color: #888;
    font-style: italic;
    padding: 40px 20px;
}

/* =============================================
   NAVIGATION
   ============================================= */

.post-navigation {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 30px;
    margin-top: 40px;
    padding-top: 20px;
}

.nav-link {
    font-family: 'Oswald', sans-serif;
    font-size: 0.95rem;
    text-decoration: none;
    color: #5a5040;
    padding: 8px 16px;
    transition: color 0.2s ease, background-color 0.2s ease;
    border-radius: 2px;
}

.nav-link:hover {
    color: #2a2520;
    background-color: rgba(0, 0, 0, 0.05);
}

.nav-disabled {
    color: #bbb;
    cursor: default;
}

.nav-disabled:hover {
    color: #bbb;
    background-color: transparent;
}

.nav-latest {
    font-weight: 500;
    text-transform: uppercase;
    letter-spacing: 1px;
}

/* =============================================
   TYPOGRAPHY
   ============================================= */

h1 {
    font-family: 'Oswald', sans-serif;
    font-weight: 500;
}

h2 {
    font-family: 'Montserrat', sans-serif;
    font-weight: 400;
}

h3 {
    font-family: 'Oswald', sans-serif;
    font-weight: 400;
}

/* =============================================
   FOOTER
   ============================================= */

footer {
    margin-top: 60px;
    text-align: center;
    font-size: 0.85rem;
    color: #888;
    border-top: 1px solid #ddd;
    padding-top: 20px;
}

/* =============================================
   RESPONSIVE ADJUSTMENTS
   ============================================= */

@media (max-width: 600px) {
    body {
        padding: 15px;
    }
    
    header h1 {
        font-size: 2.2rem;
    }
    
    .clipping {
        padding: 20px;
    }
    
    .post h2 {
        font-size: 1.2rem;
    }
    
    .post-navigation {
        gap: 15px;
    }
    
    .nav-link {
        font-size: 0.85rem;
        padding: 6px 12px;
    }
}
