/**
 * Blog Layout & Single Post Styles
 * Mobile-first, elegant design for journal/blog
 */

/* ============================================================================
   JOURNAL HEADER
   ========================================================================== */

.journal-header {
    text-align: center;
    padding: 3rem 1rem 2rem;
    background: linear-gradient(135deg, var(--forest-green) 0%, var(--dark-green-grey) 100%);
    color: white;
    margin-bottom: 2rem;
}

.journal-title {
    font-family: var(--font-heading);
    font-size: 2rem;
    font-weight: 800;
    margin: 0 0 0.75rem;
    color: white;
}

.journal-subtitle {
    font-size: 1rem;
    line-height: 1.6;
    max-width: 600px;
    margin: 0 auto;
    color: rgba(255, 255, 255, 0.95);
}

/* ============================================================================
   BLOG LAYOUT CONTAINER
   ========================================================================== */

.blog-layout-container {
    max-width: 1400px;
    margin: 0 auto;
    padding: 0 1rem;
    display: grid;
    grid-template-columns: 1fr;
    gap: 2rem;
    margin-bottom: 3rem;
}

/* ============================================================================
   BLOG SIDEBAR (Categories Navigation)
   ========================================================================== */

.blog-sidebar {
    order: 2;
}

.blog-categories-menu {
    background: white;
    border-radius: 12px;
    padding: 1.5rem;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.08);
}

.blog-categories-label {
    font-family: var(--font-heading);
    font-size: 1.125rem;
    font-weight: 700;
    color: var(--dark-grey);
    margin: 0 0 1rem;
}

.blog-categories-list {
    list-style: none;
    margin: 0;
    padding: 0;
}

.blog-categories-list li {
    margin: 0;
}

.blog-categories-list > li > a {
    display: block;
    padding: 0.75rem 1rem;
    color: var(--dark-grey) !important;
    text-decoration: none;
    font-family: var(--font-display);
    font-weight: 500;
    font-size: 0.9375rem;
    border-radius: 6px;
    transition: all 0.3s ease;
    margin-bottom: 0.25rem;
}

.blog-categories-list > li > a:hover {
    background: #f8f9fa;
    color: var(--forest-green) !important;
}

.blog-categories-list > li > a.active {
    background: var(--forest-green);
    color: white !important;
    font-weight: 600;
}

.blog-categories-list > li > a:visited {
    color: var(--dark-grey) !important;
}

.blog-categories-list > li > a.active:visited {
    color: white !important;
}

/* Subcategories */
.blog-categories-list ul {
    list-style: none;
    margin: 0 0 0.5rem 0;
    padding: 0 0 0 1rem;
}

.blog-categories-list ul li {
    margin: 0;
}

.blog-categories-list ul a {
    display: block;
    padding: 0.5rem 1rem;
    color: #6c757d !important;
    text-decoration: none;
    font-family: var(--font-body);
    font-size: 0.875rem;
    border-radius: 4px;
    transition: all 0.3s ease;
    margin-bottom: 0.125rem;
}

.blog-categories-list ul a:hover {
    background: #f8f9fa;
    color: var(--forest-green) !important;
}

.blog-categories-list ul a.active {
    color: var(--forest-green) !important;
    font-weight: 600;
    background: #f0f5f1;
}

.blog-categories-list ul a:visited {
    color: #6c757d !important;
}

.blog-categories-list ul a.active:visited {
    color: var(--forest-green) !important;
}

/* ============================================================================
   BLOG CONTENT AREA
   ========================================================================== */

.blog-content {
    order: 1;
}

/* ============================================================================
   BLOG ARCHIVE HEADER (Category Pages)
   ========================================================================== */

.blog-archive-header {
    margin-bottom: 2rem;
    padding-bottom: 1.5rem;
    border-bottom: 2px solid #e9ecef;
}

.blog-archive-title {
    font-family: var(--font-heading);
    font-size: 2rem;
    font-weight: 800;
    color: var(--dark-grey);
    margin: 0 0 0.75rem;
}

.blog-archive-description {
    font-size: 1rem;
    line-height: 1.6;
    color: #6c757d;
}

/* ============================================================================
   BLOG FEATURED POST (Home Page)
   ========================================================================== */

.blog-featured-post {
    background: white;
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
    margin-bottom: 3rem;
    display: grid;
    grid-template-columns: 1fr;
    gap: 0;
}

.blog-featured-image {
    position: relative;
    overflow: hidden;
    background: #e9ecef;
    aspect-ratio: 16 / 9;
}

.blog-featured-image a {
    display: block;
    width: 100%;
    height: 100%;
}

.blog-featured-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.4s ease;
}

.blog-featured-post:hover .blog-featured-image img {
    transform: scale(1.05);
}

.blog-featured-content {
    padding: 2rem;
}

.blog-featured-category {
    font-size: 0.875rem;
    font-weight: 600;
    color: var(--forest-green);
    margin-bottom: 0.75rem;
}

.blog-featured-category a {
    color: var(--forest-green) !important;
    text-decoration: none;
    transition: color 0.3s ease;
}

.blog-featured-category a:hover {
    color: var(--dark-green-grey) !important;
}

.blog-featured-category a:visited {
    color: var(--forest-green) !important;
}

.blog-featured-category a:hover:visited {
    color: var(--dark-green-grey) !important;
}

.blog-featured-title {
    font-family: var(--font-heading);
    font-size: 1.75rem;
    font-weight: 700;
    line-height: 1.3;
    margin: 0 0 1rem;
}

.blog-featured-title a {
    color: var(--dark-grey) !important;
    text-decoration: none;
    transition: color 0.3s ease;
}

.blog-featured-title a:hover {
    color: var(--forest-green) !important;
}

.blog-featured-title a:visited {
    color: var(--dark-grey) !important;
}

.blog-featured-title a:hover:visited {
    color: var(--forest-green) !important;
}

.blog-featured-excerpt {
    font-size: 1rem;
    line-height: 1.6;
    color: #495057;
    margin: 0 0 1.5rem;
}

.blog-featured-button {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.875rem 1.75rem;
    background: var(--forest-green);
    color: white !important;
    text-decoration: none;
    font-family: var(--font-display);
    font-weight: 600;
    font-size: 1rem;
    border-radius: 8px;
    transition: all 0.3s ease;
}

.blog-featured-button:hover {
    background: var(--dark-green-grey);
    color: white !important;
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.2);
}

.blog-featured-button:visited {
    color: white !important;
}

/* ============================================================================
   BLOG SECTION TITLE
   ========================================================================== */

.blog-section-title {
    font-family: var(--font-heading);
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--dark-grey);
    margin: 0 0 2rem;
    padding-bottom: 1rem;
    border-bottom: 2px solid #e9ecef;
}

/* ============================================================================
   BLOG POSTS GRID
   ========================================================================== */

.blog-posts-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 2rem;
    margin-bottom: 2rem;
}

/* ============================================================================
   BLOG POST CARD (Archive Grid)
   ========================================================================== */

.blog-post-card {
    background: white;
    border-radius: 12px;
    overflow: hidden;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.08);
    display: flex;
    flex-direction: column;
    height: 100%;
}

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

.blog-post-image {
    position: relative;
    overflow: hidden;
    background-color: #e9ecef;
    aspect-ratio: 16 / 9;
    flex-shrink: 0;
}

.blog-post-image a {
    display: block;
    width: 100%;
    height: 100%;
}

.blog-post-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: center center;
    display: block;
    transition: transform 0.4s cubic-bezier(0.4, 0, 0.2, 1);
}

.blog-post-card:hover .blog-post-image img {
    transform: scale(1.05);
}

.blog-post-card .blog-post-content {
    padding: 1.5rem;
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
    flex: 1;
}

.blog-post-card .blog-post-title {
    font-family: var(--font-heading);
    font-size: 1.125rem;
    font-weight: 700;
    line-height: 1.3;
    margin: 0;
}

.blog-post-card .blog-post-title a {
    color: var(--dark-grey) !important;
    text-decoration: none;
    transition: color 0.3s ease;
}

.blog-post-card .blog-post-title a:hover {
    color: var(--forest-green) !important;
}

.blog-post-card .blog-post-title a:visited {
    color: var(--dark-grey) !important;
}

.blog-post-card .blog-post-title a:hover:visited {
    color: var(--forest-green) !important;
}

.blog-post-excerpt {
    flex: 1;
}

.blog-post-excerpt p {
    font-size: 0.9375rem;
    line-height: 1.6;
    color: #495057;
    margin: 0;
}

.blog-post-action {
    margin-top: auto;
    padding-top: 0.5rem;
}

.blog-post-read-more {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    color: var(--forest-green) !important;
    font-family: var(--font-display);
    font-weight: 600;
    font-size: 0.9375rem;
    text-decoration: none;
    transition: all 0.3s ease;
}

.blog-post-read-more:hover {
    color: var(--dark-green-grey) !important;
    gap: 0.75rem;
}

.blog-post-read-more:visited {
    color: var(--forest-green) !important;
}

.blog-post-read-more:hover:visited {
    color: var(--dark-green-grey) !important;
}

/* ============================================================================
   BLOG VIEW MORE BUTTON
   ========================================================================== */

.blog-view-more {
    text-align: center;
    margin-top: 2rem;
}

.blog-view-more-button {
    display: inline-block;
    padding: 1rem 2.5rem;
    background-color: var(--forest-green);
    color: white !important;
    text-decoration: none;
    font-family: var(--font-display);
    font-weight: 600;
    font-size: 1rem;
    border-radius: 8px;
    transition: all 0.3s ease;
}

.blog-view-more-button:hover {
    background-color: var(--dark-green-grey);
    color: white !important;
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.2);
}

.blog-view-more-button:visited {
    color: white !important;
}

/* ============================================================================
   BLOG PAGINATION
   ========================================================================== */

.blog-pagination {
    margin-top: 3rem;
    text-align: center;
}

.blog-pagination .nav-links {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 0.5rem;
    flex-wrap: wrap;
}

.blog-pagination a,
.blog-pagination .page-numbers {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 40px;
    height: 40px;
    padding: 0.5rem 1rem;
    background: white;
    color: var(--dark-grey) !important;
    text-decoration: none;
    font-family: var(--font-display);
    font-weight: 500;
    font-size: 0.9375rem;
    border-radius: 6px;
    border: 1.5px solid #dee2e6;
    transition: all 0.3s ease;
}

.blog-pagination a:hover {
    background: var(--forest-green);
    color: white !important;
    border-color: var(--forest-green);
}

.blog-pagination a:visited {
    color: var(--dark-grey) !important;
}

.blog-pagination a:hover:visited {
    color: white !important;
}

.blog-pagination .current {
    background: var(--forest-green);
    color: white !important;
    border-color: var(--forest-green);
    font-weight: 600;
}

/* ============================================================================
   BLOG POST ARTICLE (Single Post)
   ========================================================================== */

.blog-post-article {
    background: white;
    border-radius: 12px;
    padding: 2rem 1.5rem;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.08);
}

.blog-post-header {
    margin-bottom: 2rem;
    padding-bottom: 1.5rem;
    border-bottom: 2px solid #e9ecef;
}

.blog-post-title-single {
    font-family: var(--font-heading);
    font-size: 2rem;
    font-weight: 800;
    line-height: 1.2;
    color: var(--dark-grey);
    margin: 0 0 1rem;
}

.blog-post-title-archive {
    font-family: var(--font-heading);
    font-size: 1.5rem;
    font-weight: 700;
    line-height: 1.3;
    color: var(--dark-grey);
    margin: 0 0 0.75rem;
}

.blog-post-title-archive a {
    color: var(--dark-grey) !important;
    text-decoration: none;
    transition: color 0.3s ease;
}

.blog-post-title-archive a:hover {
    color: var(--forest-green) !important;
}

.blog-post-title-archive a:visited {
    color: var(--dark-grey) !important;
}

.blog-post-title-archive a:hover:visited {
    color: var(--forest-green) !important;
}

.blog-post-meta {
    display: flex;
    flex-wrap: wrap;
    gap: 1rem;
    font-size: 0.875rem;
    color: #6c757d;
}

.blog-post-meta a {
    color: #6c757d !important;
    text-decoration: none;
    transition: color 0.3s ease;
}

.blog-post-meta a:hover {
    color: var(--forest-green) !important;
}

.blog-post-meta a:visited {
    color: #6c757d !important;
}

.blog-post-meta a:hover:visited {
    color: var(--forest-green) !important;
}

/* ============================================================================
   BLOG POST CONTENT
   ========================================================================== */

.entry-content {
    font-family: var(--font-body);
    font-size: 1.0625rem;
    line-height: 1.8;
    color: #343a40;
}

.entry-content p {
    margin: 0 0 1.5rem;
}

.entry-content h2 {
    font-family: var(--font-heading);
    font-size: 1.75rem;
    font-weight: 700;
    color: var(--dark-grey);
    margin: 2.5rem 0 1rem;
    line-height: 1.3;
}

.entry-content h3 {
    font-family: var(--font-heading);
    font-size: 1.375rem;
    font-weight: 700;
    color: var(--dark-grey);
    margin: 2rem 0 0.75rem;
    line-height: 1.3;
}

.entry-content h4 {
    font-family: var(--font-heading);
    font-size: 1.125rem;
    font-weight: 600;
    color: var(--dark-grey);
    margin: 1.5rem 0 0.75rem;
}

.entry-content ul,
.entry-content ol {
    margin: 0 0 1.5rem 1.5rem;
    padding: 0;
}

.entry-content li {
    margin-bottom: 0.5rem;
}

.entry-content a {
    color: var(--forest-green) !important;
    text-decoration: underline;
    transition: color 0.3s ease;
}

.entry-content a:hover {
    color: var(--dark-green-grey) !important;
}

.entry-content a:visited {
    color: var(--forest-green) !important;
}

.entry-content a:hover:visited {
    color: var(--dark-green-grey) !important;
}

.entry-content img {
    max-width: 100%;
    height: auto;
    border-radius: 8px;
    margin: 1.5rem 0;
}

.entry-content blockquote {
    margin: 2rem 0;
    padding: 1.5rem;
    background: #f8f9fa;
    border-left: 4px solid var(--forest-green);
    border-radius: 4px;
    font-style: italic;
    color: #495057;
}

.entry-content code {
    background: #f8f9fa;
    padding: 0.125rem 0.375rem;
    border-radius: 3px;
    font-size: 0.9375rem;
    color: #e83e8c;
}

.entry-content pre {
    background: #f8f9fa;
    padding: 1rem;
    border-radius: 6px;
    overflow-x: auto;
    margin: 1.5rem 0;
}

.entry-content pre code {
    background: none;
    padding: 0;
    color: inherit;
}

/* ============================================================================
   BLOG POST FOOTER (Tags)
   ========================================================================== */

.blog-post-footer {
    margin-top: 2.5rem;
    padding-top: 1.5rem;
    border-top: 2px solid #e9ecef;
}

.blog-post-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
}

.blog-post-tag {
    display: inline-block;
    padding: 0.5rem 1rem;
    background: var(--dark-grey);
    color: white !important;
    text-decoration: none;
    font-family: var(--font-display);
    font-weight: 500;
    font-size: 0.875rem;
    border-radius: 6px;
    transition: all 0.3s ease;
}

.blog-post-tag:hover {
    background: var(--forest-green);
    color: white !important;
    transform: translateY(-1px);
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.15);
}

.blog-post-tag:visited {
    color: white !important;
}

/* ============================================================================
   TABLET STYLES (768px+)
   ========================================================================== */

@media (min-width: 768px) {
    .journal-header {
        padding: 4rem 2rem 3rem;
    }

    .journal-title {
        font-size: 3rem;
    }

    .journal-subtitle {
        font-size: 1.125rem;
    }

    .blog-layout-container {
        padding: 0 2rem;
        gap: 3rem;
    }

    .blog-post-article {
        padding: 3rem 2.5rem;
    }

    .blog-post-title-single {
        font-size: 2.5rem;
    }

    .entry-content {
        font-size: 1.125rem;
    }

    /* Featured Post */
    .blog-featured-post {
        grid-template-columns: 1fr 1fr;
    }

    .blog-featured-title {
        font-size: 2rem;
    }

    /* Archive Header */
    .blog-archive-title {
        font-size: 2.5rem;
    }

    /* Blog Posts Grid */
    .blog-posts-grid {
        grid-template-columns: repeat(2, 1fr);
    }

    .blog-section-title {
        font-size: 1.75rem;
    }
}

/* ============================================================================
   DESKTOP STYLES (1024px+)
   ========================================================================== */

@media (min-width: 1024px) {
    .blog-layout-container {
        grid-template-columns: 280px 1fr;
        gap: 3rem;
    }

    .blog-sidebar {
        order: 1;
        position: sticky;
        top: 2rem;
        align-self: start;
    }

    .blog-content {
        order: 2;
    }

    .blog-post-article {
        padding: 3.5rem 3rem;
    }

    .blog-post-title-single {
        font-size: 3rem;
    }

    /* Blog Posts Grid */
    .blog-posts-grid {
        grid-template-columns: repeat(3, 1fr);
    }

    .blog-section-title {
        font-size: 2rem;
    }
}

/* ============================================================================
   LARGE DESKTOP STYLES (1440px+)
   ========================================================================== */

@media (min-width: 1440px) {
    .blog-layout-container {
        grid-template-columns: 320px 1fr;
    }

    .blog-post-title-single {
        font-size: 3.5rem;
    }
}
