/* ======================================================
   BLOG STYLES - Integrated with Brian Makumi Theme
   Supports Dark/Light Mode Toggle
   ====================================================== */

/* Dark Mode (Default) Blog Styles */
.blog-container {
    max-width: 100%;
    margin: 0 auto;
    padding: 60px 20px;
    background-color: var(--rich-black);
}

.blog-header {
    text-align: center;
    margin-bottom: 80px;
}

.blog-header h1 {
    font-size: 3rem;
    font-weight: var(--fw-600);
    color: var(--ghost-white);
    margin-bottom: 15px;
}

.blog-header .blue {
    color: var(--process-cyan);
}

.blog-header p {
    color: var(--ghost-white);
    font-size: 1.2rem;
    opacity: 0.8;
}

.nav-back {
    display: inline-block;
    margin-bottom: 40px;
    color: var(--process-cyan);
    text-decoration: none;
    font-size: 1.1rem;
    transition: all 0.3s ease;
}

.nav-back:hover {
    color: var(--ghost-white);
    transform: translateX(-5px);
}

/* Blog Post Preview Cards */
.blog-post-preview {
    background: rgba(251, 251, 255, 0.03);
    border: 1px solid rgba(251, 251, 255, 0.1);
    border-radius: 12px;
    padding: 40px;
    margin-bottom: 40px;
    transition: all 0.3s ease;
}

.blog-post-preview:hover {
    background: rgba(251, 251, 255, 0.05);
    transform: translateY(-5px);
    border-color: var(--process-cyan);
    box-shadow: 0 10px 30px rgba(1, 186, 239, 0.1);
}

.blog-post-preview h2 {
    font-size: 2rem;
    font-weight: var(--fw-600);
    margin-bottom: 15px;
    line-height: 1.3;
}

.blog-post-preview h2 a {
    color: var(--ghost-white);
    text-decoration: none;
    transition: color 0.3s ease;
}

.blog-post-preview h2 a:hover {
    color: var(--process-cyan);
}

.post-meta {
    color: var(--ghost-white);
    opacity: 0.6;
    font-size: 0.95rem;
    margin-bottom: 20px;
}

.post-meta strong {
    color: var(--process-cyan);
    opacity: 1;
}

.post-excerpt {
    color: var(--ghost-white);
    opacity: 0.8;
    line-height: 1.8;
    margin-bottom: 20px;
    font-size: 1.05rem;
}

.read-more {
    color: var(--process-cyan);
    text-decoration: none;
    font-weight: var(--fw-500);
    transition: all 0.3s ease;
    display: inline-block;
}

.read-more:hover {
    color: var(--ghost-white);
    transform: translateX(5px);
}

/* Individual Blog Post Styles */
.blog-article {
    max-width: 900px;
    margin: 0 auto;
    padding: 60px 20px;
    background-color: var(--rich-black);
}

.article-header {
    margin-bottom: 50px;
    padding-bottom: 30px;
    border-bottom: 2px solid rgba(1, 186, 239, 0.2);
}

.article-header h1 {
    font-size: 2.8rem;
    font-weight: var(--fw-600);
    color: var(--ghost-white);
    margin-bottom: 20px;
    line-height: 1.2;
}

.article-meta {
    color: var(--ghost-white);
    opacity: 0.7;
    font-size: 1rem;
}

.article-meta strong {
    color: var(--process-cyan);
    opacity: 1;
}

.article-meta time {
    color: var(--ghost-white);
}

.featured-image {
    width: 100%;
    height: auto;
    border-radius: 12px;
    margin-bottom: 50px;
    border: 1px solid rgba(251, 251, 255, 0.1);
}

/* Article Content Typography */
.article-content {
    font-size: 1.15rem;
    line-height: 1.9;
    color: var(--ghost-white);
}

.article-content p {
    margin-bottom: 25px;
    opacity: 0.9;
}

.article-content strong {
    color: var(--process-cyan);
    font-weight: var(--fw-600);
}

.article-content h2 {
    font-size: 2rem;
    font-weight: var(--fw-600);
    margin-top: 50px;
    margin-bottom: 25px;
    color: var(--ghost-white);
    padding-bottom: 10px;
    border-bottom: 2px solid var(--process-cyan);
}

.article-content h3 {
    font-size: 1.5rem;
    font-weight: var(--fw-500);
    margin-top: 40px;
    margin-bottom: 20px;
    color: var(--process-cyan);
}

.article-content h4 {
    font-size: 1.3rem;
    font-weight: var(--fw-500);
    margin-top: 30px;
    margin-bottom: 15px;
    color: var(--ghost-white);
}

.article-content ul,
.article-content ol {
    margin-bottom: 25px;
    padding-left: 35px;
}

.article-content li {
    margin-bottom: 12px;
    opacity: 0.9;
}

.article-content li strong {
    color: var(--process-cyan);
}

.article-content blockquote {
    border-left: 4px solid var(--process-cyan);
    padding-left: 25px;
    margin: 40px 0;
    font-style: italic;
    color: var(--ghost-white);
    opacity: 0.8;
    background: rgba(1, 186, 239, 0.05);
    padding: 20px 25px;
    border-radius: 0 8px 8px 0;
}

.article-content code {
    background: rgba(251, 251, 255, 0.1);
    color: var(--process-cyan);
    padding: 3px 8px;
    border-radius: 4px;
    font-family: 'Courier New', monospace;
    font-size: 0.95em;
}

.article-content pre {
    background: rgba(251, 251, 255, 0.05);
    border: 1px solid rgba(251, 251, 255, 0.1);
    border-radius: 8px;
    padding: 20px;
    overflow-x: auto;
    margin-bottom: 25px;
}

.article-content pre code {
    background: none;
    padding: 0;
}

.article-content a {
    color: var(--process-cyan);
    text-decoration: none;
    border-bottom: 1px solid transparent;
    transition: all 0.3s ease;
}

.article-content a:hover {
    border-bottom-color: var(--process-cyan);
}

/* Author Bio Section */
.author-bio {
    background: rgba(251, 251, 255, 0.03);
    border: 1px solid rgba(251, 251, 255, 0.1);
    border-radius: 12px;
    padding: 40px;
    margin-top: 80px;
}

.author-bio h3 {
    font-size: 1.8rem;
    font-weight: var(--fw-600);
    color: var(--process-cyan);
    margin-bottom: 20px;
}

.author-bio p {
    color: var(--ghost-white);
    opacity: 0.9;
    line-height: 1.8;
    margin-bottom: 15px;
}

.author-bio strong {
    color: var(--process-cyan);
}

.author-bio a {
    color: var(--process-cyan);
    text-decoration: none;
    transition: all 0.3s ease;
}

.author-bio a:hover {
    color: var(--ghost-white);
}

/* Share Buttons */
.share-buttons {
    margin-top: 60px;
    padding-top: 40px;
    border-top: 1px solid rgba(251, 251, 255, 0.1);
}

.share-buttons h3 {
    font-size: 1.5rem;
    font-weight: var(--fw-600);
    color: var(--ghost-white);
    margin-bottom: 20px;
}

.share-button {
    display: inline-block;
    padding: 12px 28px;
    margin-right: 15px;
    margin-bottom: 15px;
    background: var(--indigo-dye);
    color: var(--ghost-white);
    text-decoration: none;
    border-radius: 8px;
    font-weight: var(--fw-500);
    transition: all 0.3s ease;
}

.share-button:hover {
    background: var(--process-cyan);
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(1, 186, 239, 0.3);
}

.twitter-button {
    background: #1DA1F2;
}

.twitter-button:hover {
    background: #0d8bd9;
}

.linkedin-button {
    background: #0077B5;
}

.linkedin-button:hover {
    background: #006399;
}

/* Footer */
.blog-footer {
    text-align: center;
    margin-top: 80px;
    padding-top: 40px;
    border-top: 1px solid rgba(251, 251, 255, 0.1);
}

.blog-footer p {
    color: var(--ghost-white);
    opacity: 0.7;
    margin-bottom: 10px;
}

.blog-footer a {
    color: var(--process-cyan);
    text-decoration: none;
}

.blog-footer a:hover {
    color: var(--ghost-white);
}

/* ======================================================
   LIGHT MODE OVERRIDES FOR BLOG
   ====================================================== */

body.light-mode .blog-container {
    background-color: var(--light-background);
}

body.light-mode .blog-header h1 {
    color: var(--light-text-primary);
}

body.light-mode .blog-header .blue {
    color: var(--light-accent-blue);
}

body.light-mode .blog-header p {
    color: var(--light-text-secondary);
}

body.light-mode .nav-back {
    color: var(--light-accent-blue);
}

body.light-mode .nav-back:hover {
    color: var(--light-text-primary);
}

/* Light Mode Blog Post Previews */
body.light-mode .blog-post-preview {
    background: var(--light-white);
    border: 1px solid rgba(0, 0, 0, 0.1);
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.05);
}

body.light-mode .blog-post-preview:hover {
    background: rgba(11, 79, 108, 0.05);
    border-color: var(--light-accent-blue);
    box-shadow: 0 10px 20px rgba(0, 0, 0, 0.1);
}

body.light-mode .blog-post-preview h2 a {
    color: var(--light-text-primary);
}

body.light-mode .blog-post-preview h2 a:hover {
    color: var(--light-accent-blue);
}

body.light-mode .post-meta {
    color: var(--light-text-secondary);
    opacity: 1;
}

body.light-mode .post-meta strong {
    color: var(--light-accent-blue);
}

body.light-mode .post-excerpt {
    color: var(--light-text-secondary);
    opacity: 1;
}

body.light-mode .read-more {
    color: var(--light-accent-blue);
}

body.light-mode .read-more:hover {
    color: var(--light-accent-cyan);
}

/* Light Mode Article Styles */
body.light-mode .blog-article {
    background-color: var(--light-background);
}

body.light-mode .article-header {
    border-bottom-color: rgba(11, 79, 108, 0.2);
}

body.light-mode .article-header h1 {
    color: var(--light-text-primary);
}

body.light-mode .article-meta {
    color: var(--light-text-secondary);
    opacity: 1;
}

body.light-mode .article-meta strong {
    color: var(--light-accent-blue);
}

body.light-mode .article-meta time {
    color: var(--light-text-secondary);
}

body.light-mode .featured-image {
    border-color: rgba(0, 0, 0, 0.1);
}

body.light-mode .article-content {
    color: var(--light-text-primary);
}

body.light-mode .article-content p {
    color: var(--light-text-secondary);
    opacity: 1;
}

body.light-mode .article-content strong {
    color: var(--light-accent-blue);
}

body.light-mode .article-content h2 {
    color: var(--light-text-primary);
    border-bottom-color: var(--light-accent-blue);
}

body.light-mode .article-content h3 {
    color: var(--light-accent-blue);
}

body.light-mode .article-content h4 {
    color: var(--light-text-primary);
}

body.light-mode .article-content li {
    color: var(--light-text-secondary);
    opacity: 1;
}

body.light-mode .article-content blockquote {
    color: var(--light-text-primary);
    background: rgba(11, 79, 108, 0.05);
    border-left-color: var(--light-accent-blue);
    opacity: 1;
}

body.light-mode .article-content code {
    background: rgba(11, 79, 108, 0.1);
    color: var(--light-accent-cyan);
}

body.light-mode .article-content pre {
    background: rgba(11, 79, 108, 0.05);
    border-color: rgba(0, 0, 0, 0.1);
}

body.light-mode .article-content a {
    color: var(--light-accent-blue);
}

body.light-mode .article-content a:hover {
    border-bottom-color: var(--light-accent-blue);
}

/* Light Mode Author Bio */
body.light-mode .author-bio {
    background: var(--light-white);
    border: 1px solid rgba(0, 0, 0, 0.1);
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.05);
}

body.light-mode .author-bio h3 {
    color: var(--light-accent-blue);
}

body.light-mode .author-bio p {
    color: var(--light-text-secondary);
    opacity: 1;
}

body.light-mode .author-bio strong {
    color: var(--light-accent-blue);
}

body.light-mode .author-bio a {
    color: var(--light-accent-blue);
}

body.light-mode .author-bio a:hover {
    color: var(--light-accent-cyan);
}

/* Light Mode Share Buttons */
body.light-mode .share-buttons {
    border-top-color: rgba(0, 0, 0, 0.1);
}

body.light-mode .share-buttons h3 {
    color: var(--light-text-primary);
}

body.light-mode .share-button {
    background: var(--light-accent-blue);
    color: var(--light-white);
}

body.light-mode .share-button:hover {
    background: var(--light-accent-cyan);
}

/* Light Mode Footer */
body.light-mode .blog-footer {
    border-top-color: rgba(0, 0, 0, 0.1);
}

body.light-mode .blog-footer p {
    color: var(--light-text-secondary);
    opacity: 1;
}

body.light-mode .blog-footer p span {
    color: var(--light-text-secondary);
    opacity: 1;
}

body.light-mode .blog-footer a {
    color: var(--light-accent-blue);
}

body.light-mode .blog-footer a:hover {
    color: var(--light-accent-cyan);
}

/* ======================================================
   BLOG VIEW TOGGLE STYLES
   ====================================================== */

.blog-header {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 30px;
    margin-bottom: 60px;
}

.blog-header-content {
    text-align: center;
}

/* View Toggle Buttons */
.blog-view-toggle {
    display: flex;
    gap: 10px;
    background: rgba(251, 251, 255, 0.03);
    padding: 8px;
    border-radius: 8px;
    border: 1px solid rgba(251, 251, 255, 0.1);
}

.view-btn {
    padding: 10px 16px;
    background: transparent;
    border: 1px solid transparent;
    color: var(--ghost-white);
    cursor: pointer;
    border-radius: 6px;
    transition: all 0.3s ease;
    font-size: 1.1rem;
    opacity: 0.6;
}

.view-btn:hover {
    opacity: 0.9;
    color: var(--process-cyan);
}

.view-btn.active {
    background: rgba(1, 186, 239, 0.1);
    border-color: var(--process-cyan);
    color: var(--process-cyan);
    opacity: 1;
}

/* Blog Posts Container - Grid Layout (Default) */
/* Blog Posts Container - Grid Layout (Default) */
.blog-posts-container {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 30px;
    margin-bottom: 60px;
}

.blog-posts-container.grid-view {
    grid-template-columns: repeat(3, 1fr);
}

.blog-posts-container.list-view {
    grid-template-columns: 1fr;
}

/* Blog Post Preview - Grid Adjustments */
.blog-posts-container.grid-view .blog-post-preview {
    display: flex;
    flex-direction: column;
    height: 100%;
}

.blog-posts-container.grid-view .blog-post-preview h2 {
    font-size: 1.5rem;
}

.blog-posts-container.grid-view .blog-post-preview .post-excerpt {
    flex-grow: 1;
}

/* Blog Post Preview - List View Adjustments */
.blog-posts-container.list-view .blog-post-preview {
    padding: 30px;
}

.blog-posts-container.list-view .blog-post-preview h2 {
    font-size: 1.8rem;
    margin-bottom: 12px;
}

.blog-posts-container.list-view .blog-post-preview .post-excerpt {
    display: -webkit-box;
    line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

/* Light Mode Adjustments */
body.light-mode .blog-view-toggle {
    background: rgba(22, 27, 34, 0.03);
    border-color: rgba(22, 27, 34, 0.1);
}

body.light-mode .view-btn {
    color: var(--dark-blue);
}

body.light-mode .view-btn i{
    color: var(--light-text-secondary);
}

body.light-mode .view-btn.active {
    background: rgba(1, 186, 239, 0.1);
    color: var(--process-cyan);
}

/* Responsive Design */
@media (max-width: 1200px) {
    .blog-posts-container.grid-view {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 768px) {
    /* Hide toggle on mobile */
    .blog-view-toggle {
        display: none;
    }
    
    /* Force list view on mobile */
    .blog-posts-container {
        grid-template-columns: 1fr;
    }
    
    .blog-posts-container.grid-view {
        grid-template-columns: 1fr;
    }

    .blog-container,
    .blog-article {
        padding: 40px 15px;
    }

    .blog-header h1 {
        font-size: 2.2rem;
    }

    .blog-header {
        margin-bottom: 50px;
    }

    .blog-post-preview {
        padding: 25px;
    }

    .blog-post-preview h2 {
        font-size: 1.6rem;
    }

    .article-header h1 {
        font-size: 2rem;
    }

    .article-content {
        font-size: 1.05rem;
    }

    .article-content h2 {
        font-size: 1.6rem;
        margin-top: 35px;
    }

    .article-content h3 {
        font-size: 1.3rem;
    }

    .share-button {
        display: block;
        margin-right: 0;
        text-align: center;
    }

    .author-bio {
        padding: 25px;
    }
}

@media (max-width: 480px) {
    .blog-header h1 {
        font-size: 1.8rem;
    }

    .blog-post-preview h2 {
        font-size: 1.4rem;
    }

    .article-header h1 {
        font-size: 1.7rem;
    }

    .article-content {
        font-size: 1rem;
    }
}


/* ======================================================
   RESPONSIVE DESIGN
   ====================================================== */

@media (max-width: 768px) {
    .blog-container,
    .blog-article {
        padding: 40px 15px;
    }

    .blog-header h1 {
        font-size: 2.2rem;
    }

    .blog-header {
        margin-bottom: 50px;
    }

    .blog-post-preview {
        padding: 25px;
    }

    .blog-post-preview h2 {
        font-size: 1.6rem;
    }

    .article-header h1 {
        font-size: 2rem;
    }

    .article-content {
        font-size: 1.05rem;
    }

    .article-content h2 {
        font-size: 1.6rem;
        margin-top: 35px;
    }

    .article-content h3 {
        font-size: 1.3rem;
    }

    .share-button {
        display: block;
        margin-right: 0;
        text-align: center;
    }

    .author-bio {
        padding: 25px;
    }
}

@media (max-width: 480px) {
    .blog-header h1 {
        font-size: 1.8rem;
    }

    .blog-post-preview h2 {
        font-size: 1.4rem;
    }

    .article-header h1 {
        font-size: 1.7rem;
    }

    .article-content {
        font-size: 1rem;
    }
}
