﻿body {
    font-family: 'Open Sans', sans-serif;
    background-color: #f9f9f9;
    padding: 0;
    margin: 0;
}

/* CAROUSEL CSS COMMENTED OUT
.post-carousel {
    width: 100%;
    max-width: 960px;
    aspect-ratio: 16 / 9;
    margin: 0 auto 40px auto;
    overflow: hidden;
    border-radius: 8px;
    background: #000;
    position: relative;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
}

.carousel-container {
    display: flex;
    transition: transform 0.5s ease-in-out;
    height: 100%;
}

.carousel-item {
    flex: 0 0 100%;
    box-sizing: border-box;
    text-align: center;
    height: 100%;
}

    .carousel-item img {
        width: 100%;
        height: 100%;
        object-fit: cover;
    }

.carousel-content {
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100%;
    background: linear-gradient(to top, rgba(104, 0, 36, 0.95), rgba(104, 0, 36, 0.85));
    color: #f9f9f9;
    padding: 20px 24px;
    box-sizing: border-box;
    text-align: left;
}

    .carousel-content h2 {
        margin: 0 0 8px 0;
        font-size: 2.2rem;
        color: #f9f9f9;
        font-weight: 400;
        letter-spacing: 0.01em;
        font-family: 'Dharma Gothic', sans-serif;
        line-height: 1.1;
    }

    .carousel-content p {
        display: none;
    }

    .carousel-content time {
        font-size: 0.9rem;
        color: rgba(249, 249, 249, 0.85);
        font-weight: 400;
    }

    .carousel-content a {
        color: #f9f9f9;
        text-decoration: none;
        transition: opacity 0.2s;
    }

        .carousel-content a:hover {
            opacity: 0.9;
        }

.image-wrapper {
    width: 100%;
    height: 100%;
    overflow: hidden;
    position: relative;
}

    .image-wrapper img {
        object-fit: cover;
        object-position: center;
        display: block;
        width: 100%;
        height: 100%;
    }

.carousel-btn {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    background: rgba(104, 26, 36, 0.85);
    border: none;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    color: #f9f9f9;
    z-index: 10;
}

    .carousel-btn.prev {
        left: 10px;
    }

    .carousel-btn.next {
        right: 10px;
    }

    .carousel-btn svg {
        width: 24px;
        height: 24px;
        stroke-width: 3;
        stroke-linecap: round;
        stroke-linejoin: round;
        color: #f9f9f9;
    }

    .carousel-btn:hover {
        background: rgba(104, 26, 36, 1);
    }

.post-carousel,
.post-carousel * {
    outline: none;
    -webkit-tap-highlight-color: transparent;
}
*/

/* Newest Articles Section */
.newest-articles-section {
    background-color: #f9f9f9;
    padding: 40px 0;
    margin-bottom: 40px;
}

.newest-articles-container {
    max-width: 960px;
    margin: 0 auto;
    padding: 0 20px;
}

.newest-articles-title {
    color: #111;
    margin: 0 0 30px 0;
    font-size: 2.8rem;
    font-weight: 400;
    letter-spacing: 0.01em;
    line-height: 1;
    font-family: 'Dharma Gothic', sans-serif;
    padding-bottom: 12px;
    border-bottom: 3px solid #680024;
}

/* Featured (top) article */
.newest-featured-link {
    display: block;
    text-decoration: none;
    color: inherit;
    margin-bottom: 30px;
}

.newest-featured {
    display: flex;
    background: #fff;
    border-radius: 4px;
    overflow: hidden;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.newest-featured-link:hover .newest-featured {
    transform: translateY(-4px);
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.12);
}

.newest-featured-image {
    flex: 0 0 400px;
    aspect-ratio: 16 / 9;
}

    .newest-featured-image img {
        width: 100%;
        height: 100%;
        object-fit: cover;
    }

.newest-featured-content {
    flex: 1;
    padding: 24px;
    display: flex;
    flex-direction: column;
}

    .newest-featured-content h3 {
        margin: 0 0 12px 0;
        font-size: 1.8rem;
        font-weight: 600;
        line-height: 1.3;
        color: #111;
        font-family: 'Open Sans', sans-serif; 
    }

.newest-featured-link:hover .newest-featured-content h3 {
    color: #680024;
}

.newest-featured-excerpt {
    color: #666;
    font-size: 1rem;
    line-height: 1.6;
    margin: 0 0 auto 0;
}

.newest-featured-content time {
    font-size: 0.9rem;
    color: #999;
    margin-top: 12px;
}

/* Grid of 4 articles */
.newest-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 20px;
}

.newest-grid-link {
    display: block;
    text-decoration: none;
    color: inherit;
    height: 100%;
}

.newest-grid-item {
    display: flex;
    flex-direction: column;
    background: #fff;
    border-radius: 4px;
    overflow: hidden;
    height: 100%;
    transition: transform 0.2s ease, box-shadow 0.2s ease;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
}

.newest-grid-link:hover .newest-grid-item {
    transform: translateY(-4px);
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.12);
}

.newest-grid-item img {
    width: 100%;
    aspect-ratio: 16 / 9;
    object-fit: cover;
}

.newest-grid-content {
    padding: 14px;
    flex: 1;
    display: flex;
    flex-direction: column;
}

    .newest-grid-content h4 {
        margin: 0 0 8px 0;
        font-size: 1rem;
        font-weight: 600;
        line-height: 1.4;
        color: #111;
        display: -webkit-box;
        -webkit-line-clamp: 2;
        -webkit-box-orient: vertical;
        overflow: hidden;
    }

.newest-grid-link:hover .newest-grid-content h4 {
    color: #680024;
}

.newest-grid-excerpt {
    color: #666;
    font-size: 0.85rem;
    line-height: 1.4;
    margin: 0;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

/* Featured articles section */
.featured-articles {
    max-width: 960px;
    margin: 0 auto 60px auto;
    padding: 0 20px;
}

.featured-header {
    margin-bottom: 30px;
}

    .featured-header h2 {
        color: #111;
        margin: 0;
        font-size: 2.8rem;
        font-weight: 400;
        letter-spacing: 0.01em;
        line-height: 1;
        font-family: 'Dharma Gothic', sans-serif;
        padding-bottom: 12px;
        border-bottom: 3px solid #680024;
    }

/* Grid of featured posts */
.featured-articles-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 24px;
}

.featured-article-item-link {
    display: block;
    text-decoration: none;
    color: inherit;
    height: 100%;
}

.featured-article-item {
    display: flex;
    flex-direction: column;
    background-color: #fff;
    border-radius: 4px;
    overflow: hidden;
    height: 100%;
    transition: transform 0.2s ease, box-shadow 0.2s ease;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
}

    .featured-article-item:hover {
        transform: translateY(-4px);
        box-shadow: 0 4px 16px rgba(0, 0, 0, 0.12);
    }

    .featured-article-item img {
        width: 100%;
        aspect-ratio: 16 / 9;
        object-fit: cover;
    }

    .featured-article-item h4 {
        font-size: 1.15rem;
        font-weight: 600;
        line-height: 1.4;
        margin: 0;
        padding: 16px;
        color: #111;
        display: -webkit-box;
        -webkit-line-clamp: 3;
        -webkit-box-orient: vertical;
        overflow: hidden;
        text-overflow: ellipsis;
        flex: 1;
    }

.featured-article-item-link:hover h4 {
    color: #680024;
}

/* Browse by Author Section */
.browse-authors {
    max-width: 960px;
    margin: 60px auto;
    padding: 0 20px;
}

.browse-authors-header {
    margin-bottom: 30px;
}

    .browse-authors-header h2 {
        color: #111;
        margin: 0;
        font-size: 2.8rem;
        font-weight: 400;
        letter-spacing: 0.01em;
        line-height: 1;
        font-family: 'Dharma Gothic', sans-serif;
        padding-bottom: 12px;
        border-bottom: 3px solid #680024;
    }

.authors-pills {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
    margin-bottom: 30px;
}

.author-pill {
    display: inline-block;
    text-decoration: none;
    background: #fff;
    border: 2px solid #680024;
    border-radius: 24px;
    padding: 12px 24px;
    transition: all 0.2s ease;
    cursor: pointer;
    font-size: 1rem;
    font-weight: 600;
    color: #680024;
    font-family: 'Open Sans', sans-serif;
}

    .author-pill:hover {
        background: #f0f0f0;
    }

    .author-pill.active {
        background: #680024;
        color: #fff;
    }

        .author-pill.active:hover {
            background: #8b0032;
        }

/* Author articles grid */
.author-articles-container {
    margin-top: 30px;
}

.author-articles-grid {
    display: none;
    grid-template-columns: repeat(4, 1fr);
    gap: 20px;
    max-width: 960px;
}

    .author-articles-grid:not(:empty) {
        display: grid;
    }

.author-article-card-link {
    display: block;
    text-decoration: none;
    color: inherit;
    height: 100%;
}

.author-article-card {
    display: flex;
    flex-direction: column;
    background-color: #fff;
    border-radius: 8px;
    overflow: hidden;
    height: 100%;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.08);
}

    .author-article-card:hover {
        transform: translateY(-8px);
        box-shadow: 0 8px 24px rgba(0, 0, 0, 0.15);
    }

    .author-article-card img {
        width: 100%;
        aspect-ratio: 16 / 9;
        object-fit: cover;
    }

    .author-article-card h4 {
        font-size: 1rem;
        font-weight: 600;
        line-height: 1.4;
        margin: 0;
        padding: 14px;
        color: #111;
        display: -webkit-box;
        -webkit-line-clamp: 2;
        -webkit-box-orient: vertical;
        overflow: hidden;
        text-overflow: ellipsis;
        flex: 1;
    }

.author-article-card-link:hover h4 {
    color: #680024;
}

/* Loading and error states */
.loading,
.no-articles,
.error {
    text-align: center;
    padding: 40px 20px;
    color: #666;
    font-size: 1.1rem;
}

.error {
    color: #d32f2f;
}

/* Responsive adjustments */
@media (max-width: 900px) {
    .newest-featured {
        flex-direction: column;
    }

    .newest-featured-image {
        flex: 0 0 auto;
        min-height: 300px;
    }

    .newest-grid {
        grid-template-columns: repeat(2, 1fr);
    }

    .author-articles-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 700px) {
    .newest-articles-title {
        font-size: 2.2rem;
    }

    .featured-articles-grid {
        grid-template-columns: 1fr;
    }

    .featured-header h2 {
        font-size: 2.2rem;
    }

    .browse-authors {
        margin: 40px auto;
    }

    .browse-authors-header h2 {
        font-size: 2.2rem;
    }

    .authors-pills {
        gap: 10px;
    }

    .author-pill {
        padding: 10px 20px;
        font-size: 0.95rem;
    }
}

@media (max-width: 500px) {
    .newest-articles-section {
        padding: 30px 0;
    }

    .newest-articles-container {
        padding: 0 15px;
    }

    .newest-grid {
        grid-template-columns: 1fr;
        gap: 16px;
    }

    .featured-articles {
        padding: 0 15px;
    }

    .browse-authors {
        padding: 0 15px;
    }

    .author-articles-grid {
        grid-template-columns: 1fr;
        gap: 16px;
    }
}
