/* Shared Blog Post Styles */

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

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
    color: #e2e8f0;
    line-height: 1.6;
    min-height: 100vh;
    position: relative;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
    -webkit-text-size-adjust: 100%;
}

/* Main layout */
.page-layout {
    display: flex;
    min-height: 100vh;
}

/* Blog Navigation Sidebar */
.blog-nav {
    width: 320px;
    background: linear-gradient(180deg, rgba(15, 23, 42, 0.98) 0%, rgba(30, 41, 59, 0.95) 100%);
    border-right: 1px solid rgba(6, 182, 212, 0.2);
    position: fixed;
    left: 0;
    top: 0;
    height: 100vh;
    overflow-y: auto;
    z-index: 1000;
    backdrop-filter: blur(20px);
    box-shadow: 4px 0 20px rgba(0, 0, 0, 0.3);
}

.nav-header {
    padding: 2rem 1.5rem;
    border-bottom: 1px solid rgba(6, 182, 212, 0.3);
    background: rgba(6, 182, 212, 0.05);
    position: sticky;
    top: 0;
    z-index: 10;
    backdrop-filter: blur(10px);
}

.nav-home {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    color: #06b6d4;
    text-decoration: none;
    font-weight: 600;
    font-size: 1.1rem;
    transition: all 0.3s ease;
    padding: 0.75rem 1rem;
    border-radius: 8px;
    border: 1px solid transparent;
}

.nav-home:hover {
    color: #22d3ee;
    background: rgba(6, 182, 212, 0.1);
    border-color: rgba(6, 182, 212, 0.3);
    transform: translateX(4px);
}

.nav-icon {
    font-size: 1.4rem;
    font-weight: bold;
}

.nav-text {
    font-size: 1rem;
}

.nav-content {
    padding: 1.5rem;
}

.nav-content h3 {
    color: #06b6d4;
    font-size: 1rem;
    font-weight: 600;
    margin-bottom: 1.5rem;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    padding-left: 0.5rem;
}

.nav-year {
    margin-bottom: 2rem;
}

.nav-year h4 {
    color: #94a3b8;
    font-size: 0.9rem;
    font-weight: 600;
    margin-bottom: 0.75rem;
    padding-left: 0.5rem;
    opacity: 0.8;
}

.nav-posts {
    list-style: none;
}

.nav-posts li {
    margin-bottom: 0.25rem;
}

.nav-post {
    display: block;
    padding: 0.75rem 0.5rem;
    color: #cbd5e1;
    text-decoration: none;
    border-radius: 6px;
    transition: all 0.2s ease;
    border: 1px solid transparent;
    position: relative;
    overflow: hidden;
}

.nav-post:hover {
    background: rgba(6, 182, 212, 0.1);
    color: #06b6d4;
    border-color: rgba(6, 182, 212, 0.2);
    transform: translateX(4px);
}

.nav-post.active {
    background: rgba(6, 182, 212, 0.15);
    color: #22d3ee;
    border-color: rgba(6, 182, 212, 0.3);
    font-weight: 500;
}

.nav-post.active::before {
    content: '';
    position: absolute;
    left: 0;
    top: 50%;
    transform: translateY(-50%);
    width: 3px;
    height: 70%;
    background: #06b6d4;
    border-radius: 0 2px 2px 0;
}

.nav-post-title {
    display: block;
    font-size: 0.95rem;
    line-height: 1.4;
    margin-bottom: 0.25rem;
}

.nav-post-date {
    display: block;
    font-size: 0.8rem;
    color: #64748b;
    opacity: 0.8;
}

/* Main content area */
.main-content {
    flex: 1;
    margin-left: 320px;
    position: relative;
    z-index: 1;
}

/* Mobile menu toggle */
.mobile-menu-toggle {
    display: none;
    position: fixed;
    top: 1rem;
    left: 1rem;
    z-index: 1001;
    background: rgba(6, 182, 212, 0.2);
    border: 1px solid rgba(6, 182, 212, 0.3);
    color: #06b6d4;
    padding: 0.75rem;
    border-radius: 8px;
    cursor: pointer;
    backdrop-filter: blur(10px);
}

/* Mobile responsive */
@media (max-width: 968px) {
    .blog-nav {
        transform: translateX(-100%);
        transition: transform 0.3s ease;
    }
    
    .blog-nav.mobile-open {
        transform: translateX(0);
    }
    
    .main-content {
        margin-left: 0;
    }
    
    .mobile-menu-toggle {
        display: block;
    }
    
    .mobile-overlay {
        display: none;
        position: fixed;
        top: 0;
        left: 0;
        right: 0;
        bottom: 0;
        background: rgba(0, 0, 0, 0.5);
        z-index: 999;
    }
    
    .mobile-overlay.active {
        display: block;
    }
}

/* Global Scrollbar Styling - consistent with static blog posts */
::-webkit-scrollbar {
    width: 8px;
}

::-webkit-scrollbar-track {
    background: #1e293b;
}

::-webkit-scrollbar-thumb {
    background: #06b6d4;
    border-radius: 4px;
}

::-webkit-scrollbar-thumb:hover {
    background: #22d3ee;
}

/* Scrollbar styling for navigation - more subtle for sidebar */
.blog-nav::-webkit-scrollbar {
    width: 6px;
}

.blog-nav::-webkit-scrollbar-track {
    background: rgba(30, 41, 59, 0.5);
}

.blog-nav::-webkit-scrollbar-thumb {
    background: rgba(6, 182, 212, 0.3);
    border-radius: 3px;
}

.blog-nav::-webkit-scrollbar-thumb:hover {
    background: rgba(6, 182, 212, 0.5);
}

/* Error states */
.nav-error {
    padding: 2rem 1.5rem;
    color: #f87171;
    text-align: center;
    font-size: 0.9rem;
}

.nav-error p {
    margin-bottom: 0.5rem;
}
