/* ========================
   SITE LOGO (centered above side panel)
======================== */
.journal-logo-wrapper {
    display: flex;
    justify-content: center;   /* centers horizontally */
    margin-top: 20px;
}

.journal-logo-wrapper .site-logo img {
    width: 60px;
    height: 60px;
    object-fit: cover;
}

/* ========================
   BANNER (centered above primary panel)
======================== */
.journal-banner-wrapper {
    display: flex;
    justify-content: center;   /* centers horizontally */
    margin: 15px auto;         /* space between logo and banner */
    max-width: 1000px;         /* matches journal layout width */
}

.journal-banner-wrapper .journal-banner {
    width: 100%;               /* stretches to match primary panel width */
    max-width: 800px;          /* max same as primary panel */
    height: auto;              /* maintain aspect ratio */
}

/* ========================
   JOURNAL LAYOUT
======================== */
.journal-layout {
    display: flex;
    justify-content: center;
    align-items: flex-start;
    gap: 25px;
    width: 1000px;
    max-width: 90%;
    margin: 20px auto 0 auto; /* slightly less margin to fit with header */
}

/* Side panel remains narrow */
.journal-layout .side-panel {
    width: 180px;
    flex-shrink: 0;
}

/* Primary panel takes the rest */
.journal-layout .primary-panel {
    flex-grow: 1;
    max-width: 800px;
}

/* Tag and recent blocks */
.tag-list, .recent-list {
    list-style: none;
    padding-left: 0;
    margin-top: 5px;
}

.tag-list li a, .recent-list li a {
    display: block;
    text-decoration: none;
    font-size: 12px;
    color: #222;
    padding: 3px 0;
    transition: color 0.3s;
}

.tag-list li a:hover, .recent-list li a:hover {
    color: #665d53;
}

/* Center the whole pair visually */
@media (min-width: 1000px) {
    .journal-layout {
        justify-content: center;
    }
}

/* Responsive fallback */
@media (max-width: 800px) {
    .journal-layout {
        flex-direction: column;
        width: 90%;
    }

    .journal-layout .side-panel {
        width: 100%;
        order: 2;
    }

    .journal-layout .primary-panel {
        width: 100%;
        order: 1;
    }

    .journal-banner-wrapper,
    .journal-logo-wrapper {
        flex-direction: column;
        align-items: center;
    }

    .journal-banner-wrapper .journal-banner {
        height: 50px;
    }

    .journal-logo-wrapper .site-logo img {
        width: 50px;
        height: 50px;
    }
}

/* ========================
   POST GRID
======================== */
.post-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 20px;
}

.post-item {
    background-color: #fffefc;
    padding: 12px 15px;
    border-radius: 6px;
    box-shadow: 0 1px 4px rgba(0,0,0,0.08);
    display: flex;
    flex-direction: column;
    justify-content: flex-start;
}

.post-item img.thumb {
    width: 100%;
    height: auto;
    object-fit: contain;
    border-radius: 4px;
    margin-bottom: 10px;
}

.post-item h2.decorative {
    font-size: 18pt;
    margin: 0 0 8px 0;
}

.post-item .excerpt {
    font-size: 13.5px;
    line-height: 1.4em;
    margin-bottom: 8px;
}

.post-item .read-more {
    font-size: 12px;
    color: #665d53;
    text-decoration: none;
    font-family: 'CovikSansDemo', sans-serif;
}

.post-item .read-more:hover {
    text-decoration: underline;
}

/* ========================
   POST FOOTER (Read More + Tags)
======================== */
.post-footer {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-top: 8px;
    flex-wrap: wrap; /* allows tags to wrap if needed */
}

.post-footer .read-more {
    font-size: 12px;
    color: #665d53;
    text-decoration: none;
    font-family: 'CovikSansDemo', sans-serif;
}

.post-footer .read-more:hover {
    text-decoration: underline;
}

/* Tags styling */
.post-footer .post-tags a {
    display: inline-block;
    background-color: #f2ece0;
    color: #222;
    font-size: 11px;
    font-family: 'CovikSansDemo', sans-serif;
    text-decoration: none;
    padding: 2px 6px;
    border-radius: 4px;
    margin-left: 4px;
    transition: background-color 0.2s, color 0.2s;
}

.post-footer .post-tags a:hover {
    background-color: #665d53;
    color: #fff;
}
