/* Blog Page Styles - Clean Tiled Grid Layout */

#blog-page {
    margin: 42px auto 0 auto;
    padding: 0 28px;
    max-width: 1600px;
    position: relative;
    z-index: 10;
}

#blog-page * {
    z-index: 5;
}

/* Ensure header/navbar maintains proper stacking */
body > header {
    z-index: 500 !important;
}

/* Header Section */
.blog-header {
    text-align: center;
    margin-bottom: 40px;
    padding: 40px 0 20px 0;
    position: relative;
}

.blog-title {
    font-size: clamp(2.8rem, 6vw, 4.5rem);
    font-weight: 700;
    color: hsla(0, 0%, 100%, 1);
    margin-bottom: 12px;
    text-shadow: 0 2px 12px hsla(0, 0%, 0%, 0.4);
}

.blog-subtitle {
    font-size: clamp(1.1rem, 2.5vw, 1.4rem);
    color: hsla(0, 0%, 80%, 1);
    margin-bottom: 0;
    font-weight: 400;
}

/* Categories Strip */
.categories-strip {
    display: flex;
    justify-content: center;
    flex-wrap: wrap;
    gap: 12px;
    margin-bottom: 48px;
    padding: 24px 0;
}

.category-tag {
    padding: 10px 20px;
    background: hsla(228, 48%, 60%, 0.1);
    border: 1px solid hsla(248, 9%, 45%, 0.5);
    border-radius: 24px;
    color: hsla(0, 0%, 80%, 1);
    text-decoration: none;
    font-size: 0.9rem;
    font-weight: 500;
    transition: all 0.3s ease;
    white-space: nowrap;
}

.category-tag:hover,
.category-tag.active {
    border-color: hsla(0, 0%, 100%, 1);
    color: hsla(242, 61%, 80%, 1);
    background: hsla(242, 61%, 80%, 0.1);
}

/* Main Grid Layout */
.blog-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(450px, 1fr));
    gap: 24px;
    margin-bottom: 60px;
}
/* Blog Post Cards */
.blog-post {
    background-color: hsla(201, 100%, 8%, 0.45);
    border: 2px solid hsla(248, 9%, 45%, 0.2);
    border-radius: 25px;
    filter: drop-shadow(0px 20px 40px hsla(0, 0%, 0%, 0.15));
    backdrop-filter: blur(8px) brightness(0.8);
    overflow: hidden;
    transition: transform 0.2s ease, filter 0.2s ease, border-color 0.2s ease;
    position: relative;
    padding: 32px;
    display: flex;
    flex-direction: column;
    height: 390px; /* Fixed height for consistency */
    will-change: transform;
}

.blog-post:hover {
    transform: translateY(-2px);
    filter: drop-shadow(0px 8px 20px hsla(0, 0%, 0%, 0.2));
    border-color: hsla(248, 9%, 45%, 0.4);
}

/* Featured Post */
.blog-post.featured {
    grid-column: 1 / -1;
    background-color: hsla(201, 100%, 8%, 0.55);
    border: 2px solid hsla(248, 9%, 45%, 0.3);
    filter: drop-shadow(0px 0px 60px hsla(198, 100%, 48.8%, 0.15));
    height: 280px;
    padding: 50px;
}

.blog-post.featured:hover {
    filter: drop-shadow(0px 0px 20px hsla(198, 100%, 48.8%, 0.15));
    border-color: hsla(248, 9%, 45%, 0.4);
}

.featured h2 {
    font-size: 2rem;
    margin: 16px 0;
    font-weight: 700;
}

.featured h2 a {
    color: hsla(0, 0%, 100%, 1);
    text-decoration: none;
    transition: color 0.3s ease;
}

.featured h2 a:hover {
    color: hsla(242, 61%, 80%, 1);
}

.blog-post h3 {
    margin: 18px 0 8px 0;
    font-size: 1.4rem;
    font-weight: 600;
    line-height: 1.25;
    /* Constrain title to max 2 lines */
    display: -webkit-box;
    -webkit-line-clamp: 2;
    line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
    min-height: 1.5rem; /* Ensures consistent space even for short titles */
}

/* Override styles for featured post to maintain original layout */
.blog-post.featured .post-meta {
    display: flex;
    flex-direction: row;
    flex-wrap: wrap;
    gap: 6px 12px;
    align-items: center;
    margin-bottom: 16px;
}

.blog-post.featured .post-meta-tags,
.blog-post.featured .post-meta-info {
    margin-left: -4px;
    display: contents;
}

.blog-post.featured h2 {
    margin: 16px 0;
}

/* Override styles for single blog post header to maintain original layout */
.blog-post-single .post-meta {
    display: flex;
    flex-direction: row;
    flex-wrap: wrap;
    gap: 6px 12px;
    align-items: center;
    margin-bottom: 16px;
}

.blog-post-single .post-meta-tags,
.blog-post-single .post-meta-info {
    display: contents;
}

/* Override styles for blog post list items to maintain original layout */
.blog-post-item .post-meta {
    display: flex;
    flex-direction: row;
    flex-wrap: wrap;
    gap: 6px 12px;
    align-items: center;
    margin-bottom: 16px;
}

.blog-post-item .post-meta-tags,
.blog-post-item .post-meta-info {
    margin-left: -4px;
    display: contents;
}

.blog-post h3 a {
    color: hsla(0, 0%, 100%, 1);
    text-decoration: none;
    transition: color 0.3s ease;
}

.blog-post h3 a:hover {
    color: hsla(242, 61%, 80%, 1);
}

.post-meta {
    display: flex;
    flex-direction: column;
    gap: 8px;
    font-size: 0.85rem;
    color: hsla(0, 0%, 80%, 1);
    margin-bottom: 8px;
    line-height: 1.4;
    min-height: auto;
    align-items: flex-start;
}

.post-meta-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
    margin-bottom: 6px;
    margin-left: -4px;
}

.post-meta-info {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
    align-items: center;
    line-height: 1;
}

.post-date {
    display: flex;
    align-items: center;
    gap: 6px;
    font-size: 0.8rem;
    white-space: nowrap;
    flex-shrink: 0;
}

.post-updated {
    display: flex;
    align-items: center;
    gap: 6px;
    font-size: 0.8rem;
    color: hsla(45, 100%, 75%, 1); /* Slightly golden/yellow color to indicate updates */
    background: hsla(45, 100%, 20%, 0.2);
    padding: 4px 12px;
    border-radius: 16px;
    border: 1px solid hsla(45, 100%, 75%, 0.3);
    white-space: nowrap;
    flex-shrink: 0;
    font-weight: 500;
    line-height: 0.8rem;
}

.reading-time {
    color: hsla(0, 0%, 70%, 1);
    font-size: 0.8rem;
    opacity: 0.9;
    margin-left: 8px;
    white-space: nowrap;
}

.post-category {
    background: hsla(228, 48%, 60%, 0.2);
    padding: 4px 12px;
    border-radius: 20px;
    color: hsla(0, 0%, 90%, 1);
    border: 1px solid hsla(248, 9%, 45%, 0.3);
    font-size: 0.75rem;
    font-weight: 500;
    text-decoration: none;
    transition: all 0.3s ease;
    white-space: nowrap;
    flex-shrink: 0;
}

.post-category:hover {
    background: hsla(228, 48%, 60%, 0.3);
    color: hsla(0, 0%, 100%, 1);
    border-color: hsla(248, 9%, 45%, 0.5);
}

/* Disable glow effect on blog post hover for tags */
.blog-post:hover .post-category {
    /* Prevent any inherited glow or transform effects */
    filter: none;
}

.post-excerpt {
    color: hsla(0, 0%, 85%, 1);
    line-height: 1.6;
    margin: 8px 0 24px 0;
    font-size: 0.95rem;
    flex-grow: 1;
    /* Constrain excerpt to max 3 lines for consistency */
    display: -webkit-box;
    -webkit-line-clamp: 3;
    line-clamp: 3;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

/* Override for single blog post header excerpt to restore original styling */
.blog-post-single .post-excerpt {
    margin: 16px 0 0 0;
    font-size: 1.2rem;
    font-style: italic;
    line-height: 1.5;
    display: block;
    -webkit-line-clamp: unset;
    line-clamp: unset;
    min-height: auto;
}

.read-more {
    color: hsla(242, 61%, 80%, 1);
    text-decoration: none;
    font-weight: 500;
    display: inline-flex;
    align-items: center;
    gap: 8px;
    transition: all 0.3s ease;
    font-size: 0.9rem;
    margin-top: auto;
    padding-top: 8px; /* Add consistent spacing above read-more */
}

.read-more:hover {
    color: hsla(0, 0%, 100%, 1);
    gap: 12px;
}

/* Blog Intro Section */
.blog-intro {
    text-align: center;
    max-width: 900px;
    margin: 80px auto 0 auto;
    padding: 50px 40px;
    background-color: hsla(201, 100%, 8%, 0.45);
    border: 2px solid hsla(248, 9%, 45%, 0.2);
    border-radius: 25px;
    filter: drop-shadow(0px 20px 40px hsla(0, 0%, 0%, 0.15));
    backdrop-filter: blur(15px) brightness(0.7);
}

.blog-intro h2 {
    color: hsla(0, 0%, 100%, 1);
    font-size: 1.8rem;
    margin-bottom: 24px;
    font-weight: 600;
}

.blog-intro p {
    color: hsla(0, 0%, 85%, 1);
    line-height: 1.7;
    font-size: 1.05rem;
    margin-bottom: 20px;
}

.blog-intro p:last-child {
    margin-bottom: 0;
}

/* Blog Navigation */
.blog-navigation {
    margin: 60px 0 40px 0;
    text-align: center;
}

.nav-buttons {
    display: flex;
    gap: 24px;
    justify-content: center;
    flex-wrap: wrap;
    margin-bottom: 40px;
}

.nav-button {
    display: flex;
    align-items: center;
    gap: 16px;
    padding: 20px 28px;
    background: hsla(0, 0%, 5%, 0.6);
    border: 1px solid hsla(0, 0%, 20%, 0.6);
    border-radius: 12px;
    color: hsla(0, 0%, 95%, 1);
    text-decoration: none;
    transition: all 0.3s ease;
    backdrop-filter: blur(10px);
    min-width: 200px;
}

.nav-button:hover {
    background: hsla(0, 0%, 10%, 0.8);
    border-color: hsla(0, 0%, 40%, 0.8);
}

.nav-button.primary {
    border-color: hsla(210, 90%, 50%, 0.6);
}

.nav-button.primary:hover {
    border-color: hsla(210, 90%, 60%, 0.8);
    filter: drop-shadow(0 8px 32px hsla(210, 90%, 50%, 0.2));
}

.nav-icon {
    font-size: 1.5rem;
}

.nav-text {
    display: flex;
    flex-direction: column;
    text-align: left;
}

.nav-text strong {
    font-size: 1rem;
    font-weight: 600;
    margin-bottom: 4px;
}

.nav-text small {
    font-size: 0.85rem;
    color: hsla(0, 0%, 70%, 1);
}

/* Pagination */
.pagination {
    margin: 60px 0 40px 0;
    text-align: center;
}

.pagination-links {
    display: flex;
    justify-content: center;
    gap: 12px;
    flex-wrap: wrap;
}

.pagination-link {
    display: inline-block;
    padding: 12px 18px;
    background: linear-gradient(135deg, hsla(201, 100%, 8%, 0.6), hsla(201, 100%, 8%, 0.4));
    border: 2px solid hsla(248, 9%, 45%, 0.3);
    border-radius: 12px;
    color: hsla(0, 0%, 90%, 1);
    text-decoration: none;
    transition: all 0.3s ease;
    font-weight: 600;
    backdrop-filter: blur(10px) brightness(0.7);
    font-size: 0.9rem;
}

.pagination-link:hover {
    background: linear-gradient(135deg, hsla(201, 100%, 8%, 0.8), hsla(201, 100%, 8%, 0.6));
    border-color: hsla(248, 9%, 45%, 0.5);
    color: hsla(0, 0%, 100%, 1);
    transform: translateY(-2px);
    filter: drop-shadow(0 4px 12px hsla(0, 0%, 0%, 0.2));
}

.pagination-link.current {
    background: linear-gradient(135deg, hsla(210, 90%, 50%, 0.8), hsla(210, 90%, 50%, 0.6));
    border-color: hsla(210, 90%, 60%, 0.8);
    color: white;
    transform: translateY(-1px);
}

.pagination-link.prev,
.pagination-link.next {
    font-weight: 700;
    padding: 12px 20px;
}

/* Tags Grid */
.tags-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 24px;
    margin-bottom: 40px;
}

.tag-card {
    background: hsla(0, 0%, 5%, 0.6);
    border: 1px solid hsla(0, 0%, 15%, 0.6);
    border-radius: 12px;
    padding: 24px;
    backdrop-filter: blur(10px);
    transition: all 0.3s ease;
}

.tag-card:hover {
    border-color: hsla(0, 0%, 25%, 0.8);
}

.tag-card h3 {
    margin: 0 0 8px 0;
    font-size: 1.3rem;
    font-weight: 600;
}

.tag-card h3 a {
    color: hsla(0, 0%, 95%, 1);
    text-decoration: none;
}

.tag-card h3 a:hover {
    color: hsla(210, 90%, 60%, 1);
}

.tag-count {
    color: hsla(0, 0%, 70%, 1);
    font-size: 0.9rem;
    margin-bottom: 16px;
    display: block;
}

.tag-preview {
    border-top: 1px solid hsla(0, 0%, 20%, 0.5);
    padding-top: 16px;
}

.preview-post {
    margin-bottom: 12px;
    padding-bottom: 8px;
    border-bottom: 1px solid hsla(0, 0%, 15%, 0.3);
}

.preview-post:last-child {
    border-bottom: none;
    margin-bottom: 0;
}

.preview-post a {
    color: hsla(0, 0%, 90%, 1);
    text-decoration: none;
    font-weight: 500;
    font-size: 0.95rem;
    display: block;
    margin-bottom: 4px;
}

.preview-post a:hover {
    color: hsla(210, 90%, 60%, 1);
}

.preview-date {
    color: hsla(0, 0%, 65%, 1);
    font-size: 0.8rem;
}

.more-posts a {
    color: hsla(0, 0%, 75%, 1);
    font-size: 0.85rem;
    text-decoration: none;
    font-style: italic;
}

.more-posts a:hover {
    color: hsla(210, 90%, 60%, 1);
}

/* Single Blog Post */
.blog-post-single {
    max-width: 1400px;
    margin: 0 auto;
    padding: 0 28px;
    position: relative;
    z-index: 5;
}

/* Blog post header */
.post-header {
    background-color: hsla(201, 100%, 8%, 0.45);
    border: 2px solid hsla(248, 9%, 45%, 0.2);
    border-radius: 25px;
    filter: drop-shadow(0px 20px 40px hsla(0, 0%, 0%, 0.15));
    backdrop-filter: blur(15px) brightness(0.7);
    padding: 32px 40px;
    margin: 42px 0 48px 0;
    text-align: center;
    transition: all 0.3s ease;
    position: static;
    z-index: auto;
}

.post-header:hover {
    transform: translateY(-2px);
    filter: drop-shadow(0px 8px 20px hsla(0, 0%, 0%, 0.2));
    border-color: hsla(248, 9%, 45%, 0.4);
}

.post-title {
    font-size: clamp(2.2rem, 5vw, 3.5rem);
    font-weight: 700;
    color: hsla(0, 0%, 100%, 1);
    margin: 16px 0;
    line-height: 1.2;
    text-shadow: 0 2px 8px hsla(0, 0%, 0%, 0.3);
}

.post-excerpt {
    font-size: 1.2rem;
    color: hsla(0, 0%, 80%, 1);
    margin: 16px 0 0 0;
    font-style: italic;
    line-height: 1.5;
}

.post-content {
    line-height: 1.7;
    color: hsla(0, 0%, 92%, 1);
    margin-bottom: 64px;
    font-size: 1.05rem;
    background-color: hsla(201, 100%, 8%, 0.45);
    border: 2px solid hsla(248, 9%, 45%, 0.2);
    border-radius: 25px;
    filter: drop-shadow(0px 20px 40px hsla(0, 0%, 0%, 0.15));
    backdrop-filter: blur(15px) brightness(0.7);
    padding: 48px 52px;
    max-width: none;
}

.post-content h1,
.post-content h2,
.post-content h3,
.post-content h4 {
    color: hsla(0, 0%, 98%, 1);
    font-weight: 600;
    margin: 40px 0 20px 0;
    position: relative;
    letter-spacing: -0.02em;
}

.post-content h1:first-child,
.post-content h2:first-child,
.post-content h3:first-child,
.post-content h4:first-child {
    margin-top: 0;
}

.post-content h1 {
    font-size: 2.4rem;
    border-bottom: 2px solid hsla(242, 61%, 80%, 0.4);
    padding-bottom: 16px;
    margin-bottom: 28px;
}

.post-content h2 {
    font-size: 2.1rem;
    color: hsla(0, 0%, 96%, 1);
    font-weight: 600;
    margin: 48px 0 24px 0;
    border-bottom: 2px solid hsla(210, 90%, 65%, 0.4);
    padding-bottom: 16px;
    text-shadow: 0 2px 8px hsla(0, 0%, 0%, 0.3);
}

.post-content h3 {
    font-size: 1.7rem;
    color: hsla(242, 61%, 85%, 1);
    margin: 40px 0 20px 0;
    font-weight: 600;
    text-shadow: 0 1px 4px hsla(0, 0%, 0%, 0.2);
}

.post-content h4 {
    font-size: 1.4rem;
    color: hsla(242, 61%, 90%, 1);
    margin: 36px 0 18px 0;
    font-weight: 600;
}

.post-content p {
    margin-bottom: 24px;
    text-align: left;
    line-height: 1.8;
    color: hsla(0, 0%, 92%, 1);
    font-size: 1.05rem;
    letter-spacing: 0.01em;
}

.post-content p:last-child {
    margin-bottom: 0;
}

/* Enhanced list styling with colored bullets */
.post-content ul,
.post-content ol {
    margin: 16px 0 20px 0;
    padding-left: 24px;
    position: relative;
}

.post-content ul {
    list-style: none;
}

.post-content ul li {
    position: relative;
    margin-bottom: 4px;
    padding-left: 20px;
    line-height: 1.7;
    color: hsla(0, 0%, 92%, 1);
    font-size: 1.02rem;
}

.post-content ul li::before {
    content: '●';
    position: absolute;
    left: 0;
    top: 0.1em;
    color: hsla(210, 90%, 65%, 1);
    font-size: 0.8em;
    font-weight: bold;
    line-height: 1.7;
    text-shadow: 0 0 4px hsla(210, 90%, 65%, 0.3);
}

.post-content ol {
    counter-reset: custom-counter;
    list-style: none;
}

.post-content ol li {
    position: relative;
    margin-bottom: 4px;
    padding-left: 32px;
    line-height: 1.7;
    color: hsla(0, 0%, 92%, 1);
    counter-increment: custom-counter;
    font-size: 1.02rem;
}

.post-content ol li::before {
    content: counter(custom-counter) '.';
    position: absolute;
    left: 0;
    top: 0;
    color: hsla(210, 90%, 65%, 1);
    font-weight: 600;
    font-size: 1em;
    line-height: 1.7;
    text-shadow: 0 0 4px hsla(210, 90%, 65%, 0.3);
    width: 28px;
    text-align: right;
}

/* Nested lists */
.post-content ul ul,
.post-content ol ol,
.post-content ul ol,
.post-content ol ul {
    margin: 6px 0 6px 0;
    padding-left: 18px;
}

.post-content ul ul li::before {
    color: hsla(242, 61%, 75%, 1);
    content: '◦';
    font-size: 1.0em;
    text-shadow: 0 0 3px hsla(242, 61%, 75%, 0.3);
}

.post-content ol ol li::before {
    color: hsla(242, 61%, 75%, 1);
    text-shadow: 0 0 3px hsla(242, 61%, 75%, 0.3);
}

.post-content blockquote {
    border-left: 4px solid hsla(210, 90%, 65%, 0.9);
    background: linear-gradient(135deg, hsla(210, 90%, 50%, 0.12), hsla(210, 90%, 50%, 0.06));
    padding: 32px 40px;
    margin: 40px 0;
    font-style: italic;
    color: hsla(0, 0%, 94%, 1);
    border-radius: 0 20px 20px 0;
    position: relative;
    font-size: 1.08rem;
    line-height: 1.75;
    backdrop-filter: blur(8px);
    border-top: 1px solid hsla(210, 90%, 50%, 0.25);
    border-bottom: 1px solid hsla(210, 90%, 50%, 0.25);
    filter: drop-shadow(0 8px 32px hsla(210, 90%, 50%, 0.1));
}

.post-content blockquote::before {
    content: '"';
    font-size: 4rem;
    color: hsla(210, 90%, 65%, 0.5);
    position: absolute;
    top: -8px;
    left: 16px;
    font-family: Georgia, serif;
    line-height: 1;
    text-shadow: 0 2px 8px hsla(210, 90%, 65%, 0.3);
}

.post-content code {
    background: linear-gradient(135deg, hsla(0, 0%, 6%, 0.95), hsla(0, 0%, 10%, 0.95));
    padding: 6px 12px;
    border-radius: 10px;
    font-family: 'SF Mono', 'Monaco', 'Inconsolata', 'Roboto Mono', 'Courier New', monospace;
    font-size: 0.92rem;
    color: hsla(120, 60%, 80%, 1);
    border: 1px solid hsla(0, 0%, 25%, 0.7);
    font-weight: 500;
    letter-spacing: 0.02em;
    filter: drop-shadow(0 2px 8px hsla(0, 0%, 0%, 0.2));
}

.post-content pre {
    background: linear-gradient(135deg, hsla(0, 0%, 6%, 0.95), hsla(0, 0%, 8%, 0.95));
    padding: 28px;
    border-radius: 16px;
    overflow-x: auto;
    margin: 28px 0;
    border: 2px solid hsla(0, 0%, 20%, 0.6);
    filter: 
        drop-shadow(0 2px 8px hsla(0, 0%, 0%, 0.4))
        drop-shadow(0 8px 32px hsla(0, 0%, 0%, 0.3));
    backdrop-filter: blur(8px);
    position: relative;
}

.post-content pre::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 2px;
    background: linear-gradient(90deg, 
        hsla(210, 90%, 60%, 0.6), 
        hsla(242, 61%, 80%, 0.6), 
        hsla(210, 90%, 60%, 0.6)
    );
    border-radius: 16px 16px 0 0;
}

.post-content pre code {
    background: none;
    padding: 0;
    border: none;
    color: hsla(0, 0%, 95%, 1);
    font-size: 0.95rem;
    line-height: 1.6;
}

/* Image styling */
.post-content img {
    display: block;
    max-width: 100%;
    border-radius: 20px;
    margin: 36px auto;
    filter: drop-shadow(0 12px 40px hsla(0, 0%, 0%, 0.4));
    border: 2px solid hsla(248, 9%, 45%, 0.3);
    transition: all 0.3s ease;
}

.post-content img:hover {
    filter: drop-shadow(0 16px 48px hsla(0, 0%, 0%, 0.5));
    border-color: hsla(248, 9%, 45%, 0.5);
    transform: translateY(-2px);
}

.img-caption {
    display: block;
    text-align: center;
    margin-top: -30px;
    transition: all 0.3s ease;
    color: hsla(0, 0%, 70%, 1);
    font-size: 0.8rem;
}

img:hover + .img-caption {
    transform: translateY(-2px);
    color: hsla(0, 0%, 75%, 1);
}

.post-content figure {
    margin: 44px 0;
    text-align: center;
}

.post-content figure img {
    margin: 0 0 20px 0;
}

.post-content figcaption {
    font-size: 0.9rem;
    color: hsla(0, 0%, 75%, 1);
    font-style: italic;
    background: hsla(0, 0%, 8%, 0.6);
    padding: 14px 24px;
    border-radius: 12px;
    border: 1px solid hsla(248, 9%, 45%, 0.3);
    backdrop-filter: blur(8px);
}

/* Enhanced Video Embed Styling */
.post-content #frame,
.post-content .video-embed {
    aspect-ratio: 16 / 9;
    position: relative;
    border-radius: 20px;
    overflow: hidden;
    filter: drop-shadow(0 16px 48px hsla(0, 0%, 0%, 0.5));
    margin: 40px auto;
    border: 2px solid hsla(248, 9%, 45%, 0.3);
    transition: all 0.4s ease;
    background: linear-gradient(135deg, hsla(201, 100%, 8%, 0.8), hsla(201, 100%, 8%, 0.6));
}

.post-content #frame:hover,
.post-content .video-embed:hover {
    transform: translateY(-4px);
    filter: drop-shadow(0 20px 60px hsla(0, 0%, 0%, 0.6));
    border-color: hsla(248, 9%, 45%, 0.5);
}

.post-content #frame #player,
.post-content .video-embed .player {
    height: 100%;
    width: 100%;
    position: relative;
    background: hsla(201, 100%, 8%, 1);
}

.post-content #frame iframe,
.post-content .video-embed iframe {
    width: 100%;
    height: 100%;
    border: none;
    border-radius: inherit;
}

/* Video Embed Framework - Enhanced */
.video-container {
    aspect-ratio: 16 / 9;
    position: relative;
    border-radius: 20px;
    overflow: hidden;
    filter: drop-shadow(0 16px 48px hsla(0, 0%, 0%, 0.5));
    margin: 48px auto;
    border: 2px solid hsla(248, 9%, 45%, 0.3);
    transition: all 0.4s ease;
    background: linear-gradient(135deg, hsla(201, 100%, 8%, 0.8), hsla(201, 100%, 8%, 0.6));
    max-width: 100%;
    width: 70%;
}

.video-container:hover {
    transform: translateY(-4px);
    filter: drop-shadow(0 20px 60px hsla(0, 0%, 0%, 0.6));
    border-color: hsla(248, 9%, 45%, 0.5);
}

.video-caption {
    display: block;
    text-align: center;
    margin-top: -34px;
    transition: all 0.4s ease;
    color: hsla(0, 0%, 70%, 1);
    font-size: 0.8rem;
}

.video-container:hover + .video-caption,
.video-embed:hover + .video-caption {
    transform: translateY(-4px);
    color: hsla(0, 0%, 75%, 1);
}

.video-container.full-width {
    width: 100%;
}

.video-container .video-player {
    height: 100%;
    width: 100%;
    position: relative;
    background: hsla(201, 100%, 8%, 1);
}

.video-container iframe {
    width: 100%;
    height: 100%;
    border: none;
    border-radius: inherit;
}

.video-container::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(135deg, 
        hsla(210, 90%, 60%, 0.02), 
        hsla(242, 61%, 80%, 0.02)
    );
    pointer-events: none;
    z-index: 1;
    border-radius: inherit;
}

/* Alternative styling for multiple videos in one post */
.video-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(400px, 1fr));
    gap: 32px;
    margin: 48px 0;
}

.video-grid .video-container {
    margin: 0;
    width: 100%;
}

/* Links in content */
.post-content a {
    color: hsla(210, 90%, 65%, 1);
    text-decoration: none;
    border-bottom: 2px solid hsla(210, 90%, 60%, 0.4);
    transition: all 0.3s ease;
    font-weight: 500;
    padding-bottom: 1px;
}

.post-content a:hover {
    color: hsla(210, 90%, 75%, 1);
    border-bottom-color: hsla(210, 90%, 70%, 0.8);
    background: hsla(210, 90%, 60%, 0.1);
    padding: 2px 4px;
    margin: -2px -4px;
    border-radius: 4px;
}

/* Enhanced spacing and typography */
.post-content strong {
    color: hsla(28, 80%, 70%, 1);
    font-weight: 700;
    letter-spacing: 0.015em;
    text-shadow: 0 1px 3px hsla(28, 80%, 40%, 0.4);
}

.post-content em {
    color: hsla(242, 61%, 88%, 1);
    font-style: italic;
    font-weight: 500;
}

.post-content u {
    text-decoration: underline;
    text-decoration-color: hsla(210, 90%, 65%, 0.7);
    text-decoration-thickness: 2px;
    text-underline-offset: 4px;
    text-decoration-skip-ink: auto;
}

/* Better spacing for adjacent elements */
.post-content h1 + p,
.post-content h2 + p,
.post-content h3 + p,
.post-content h4 + p {
    margin-top: 0;
}

.post-content p + h1,
.post-content p + h2 {
    margin-top: 56px;
}

.post-content p + h3,
.post-content p + h4 {
    margin-top: 44px;
}

.post-content blockquote + p,
.post-content ul + p,
.post-content ol + p,
.post-content pre + p {
    margin-top: 28px;
}

.post-content img + p,
.post-content #frame + p,
.post-content .video-embed + p {
    margin-top: 32px;
}

.post-content p + img,
.post-content p + #frame,
.post-content p + .video-embed {
    margin-top: 32px;
}

/* Enhanced divider styling */
.post-content hr {
    border: none;
    height: 2px;
    background: linear-gradient(90deg, 
        transparent, 
        hsla(248, 9%, 45%, 0.6), 
        transparent
    );
    margin: 48px 0;
    border-radius: 1px;
}

.post-content pre {
    background: hsla(0, 0%, 5%, 0.8);
    padding: 20px;
    border-radius: 8px;
    overflow-x: auto;
    margin: 24px 0;
}

.post-footer {
    background-color: hsla(201, 100%, 8%, 0.45);
    border: 2px solid hsla(248, 9%, 45%, 0.2);
    border-radius: 25px;
    filter: drop-shadow(0px 20px 40px hsla(0, 0%, 0%, 0.15));
    backdrop-filter: blur(15px) brightness(0.7);
    padding: 40px 48px;
    margin-top: 48px;
    transition: all 0.3s ease;
}

.post-footer:hover {
    border-color: hsla(248, 9%, 45%, 0.3);
    transform: translateY(-2px);
}

.post-navigation {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 40px;
    flex-wrap: wrap;
    gap: 16px;
    padding-bottom: 32px;
    border-bottom: 1px solid hsla(248, 9%, 45%, 0.3);
}

@media (max-width: 768px) {
    .post-navigation {
        flex-direction: column;
        text-align: center;
        gap: 12px;
        margin-bottom: 28px;
        padding-bottom: 24px;
    }
}

.nav-link {
    color: hsla(210, 90%, 60%, 1);
    text-decoration: none;
    font-weight: 600;
    padding: 14px 24px;
    background: linear-gradient(135deg, hsla(210, 90%, 50%, 0.15), hsla(210, 90%, 50%, 0.05));
    border: 2px solid hsla(210, 90%, 50%, 0.4);
    border-radius: 16px;
    transition: all 0.3s ease;
    display: inline-flex;
    align-items: center;
    gap: 8px;
    font-size: 1rem;
    letter-spacing: 0.5px;
}

.nav-link:hover {
    background: linear-gradient(135deg, hsla(210, 90%, 50%, 0.25), hsla(210, 90%, 50%, 0.15));
    border-color: hsla(210, 90%, 60%, 0.7);
    color: hsla(210, 90%, 70%, 1);
    transform: translateY(-3px);
    filter: drop-shadow(0 6px 20px hsla(210, 90%, 50%, 0.25));
}

.post-tags {
    padding-top: 0;
}

.post-tags h3 {
    margin: 0 0 20px 0;
    font-size: 1.2rem;
    color: hsla(0, 0%, 90%, 1);
    font-weight: 600;
}

.tag-links {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
    align-items: center;
}

.tag-link {
    background: linear-gradient(135deg, hsla(228, 48%, 60%, 0.25), hsla(228, 48%, 60%, 0.15));
    padding: 10px 18px;
    border-radius: 24px;
    color: hsla(0, 0%, 95%, 1);
    border: 1px solid hsla(248, 9%, 45%, 0.4);
    font-size: 0.9rem;
    font-weight: 600;
    text-decoration: none;
    transition: all 0.3s ease;
    display: inline-flex;
    align-items: center;
    white-space: nowrap;
    letter-spacing: 0.5px;
}

.tag-link:hover {
    background: linear-gradient(135deg, hsla(228, 48%, 60%, 0.4), hsla(228, 48%, 60%, 0.25));
    color: hsla(0, 0%, 100%, 1);
    border-color: hsla(248, 9%, 45%, 0.6);
    transform: translateY(-2px);
    filter: drop-shadow(0 4px 12px hsla(228, 48%, 60%, 0.2));
}

.post-tag {
    background: hsla(228, 48%, 60%, 0.2);
    padding: 6px 14px;
    border-radius: 20px;
    color: hsla(0, 0%, 90%, 1);
    border: 1px solid hsla(248, 9%, 45%, 0.3);
    font-size: 0.8rem;
    font-weight: 500;
    text-decoration: none;
    transition: all 0.3s ease;
    display: inline-block;
    margin-right: 8px;
    margin-bottom: 8px;
    white-space: nowrap;
}

.post-tag:hover {
    background: hsla(228, 48%, 60%, 0.3);
    color: hsla(0, 0%, 100%, 1);
    border-color: hsla(248, 9%, 45%, 0.5);
}

/* Empty State */
.empty-state {
    text-align: center;
    padding: 60px 20px;
    color: hsla(0, 0%, 70%, 1);
}

.empty-state h3 {
    color: hsla(0, 0%, 85%, 1);
    margin-bottom: 16px;
}

/* Blog Posts List Layout */
.blog-posts-list {
    display: flex;
    flex-direction: column;
    gap: 20px;
    margin-bottom: 60px;
}

.blog-post-item {
    background-color: hsla(201, 100%, 8%, 0.45);
    border: 1px solid hsla(248, 9%, 45%, 0.2);
    border-radius: 16px;
    padding: 24px 32px;
    backdrop-filter: blur(10px) brightness(0.7);
    transition: all 0.3s ease;
    position: relative;
}

.blog-post-item:hover {
    border-color: hsla(248, 9%, 45%, 0.4);
    background-color: hsla(201, 100%, 8%, 0.55);
}

.blog-post-item h2 {
    margin: 12px 0;
    font-size: 1.4rem;
    font-weight: 600;
    line-height: 1.3;
}

.blog-post-item h2 a {
    color: hsla(0, 0%, 100%, 1);
    text-decoration: none;
    transition: color 0.3s ease;
}

.blog-post-item h2 a:hover {
    color: hsla(242, 61%, 80%, 1);
}

.blog-post-item .post-excerpt {
    margin: 12px 0 16px 0;
    color: hsla(0, 0%, 85%, 1);
    line-height: 1.6;
    font-size: 0.95rem;
}

.blog-post-item .read-more {
    font-size: 0.9rem;
    margin-top: 8px;
}

/* Content grouping - subtle sections without borders */
.post-content .content-section {
    margin: 40px 0;
    padding: 32px;
    background: linear-gradient(135deg, 
        hsla(0, 0%, 100%, 0.02) 0%, 
        hsla(0, 0%, 100%, 0.005) 100%);
    border-radius: 20px;
    backdrop-filter: blur(5px);
    transition: all 0.3s ease;
}

.post-content .content-section:hover {
    background: linear-gradient(135deg, 
        hsla(0, 0%, 100%, 0.03) 0%, 
        hsla(0, 0%, 100%, 0.01) 100%);
    transform: translateY(-2px);
}

/* Highlight sections for important content */
.post-content .highlight-section {
    background: linear-gradient(135deg, 
        hsla(28, 40%, 10%, 0.15) 0%, 
        hsla(28, 40%, 8%, 0.08) 100%);
    border-left: 3px solid hsla(28, 80%, 60%, 0.6);
    margin: 32px 0;
    padding: 24px 28px;
    border-radius: 0 16px 16px 0;
}

/* Responsive Design */
@media (max-width: 1200px) {
    .blog-grid {
        grid-template-columns: repeat(auto-fit, minmax(400px, 1fr));
        gap: 20px;
    }
    
    .blog-post.featured {
        grid-column: 1 / -1;
    }
}

@media (max-width: 768px) {
    #blog-page {
        padding: 0 20px;
    }
    
    .blog-header {
        padding: 20px 0;
    }
    
    .categories-strip {
        margin-bottom: 32px;
        gap: 8px;
    }
    
    .category-tag {
        padding: 8px 16px;
        font-size: 0.85rem;
    }
    
    .blog-grid {
        grid-template-columns: 1fr;
        gap: 20px;
    }
    
    .blog-post, 
    .blog-post.featured {
        padding: 28px;
        height: auto; /* Allow flexible height on mobile */
        min-height: 300px;
    }
    
    .blog-post.featured {
        padding: 35px;
        min-height: 320px;
    }
    
    .featured h2 {
        font-size: 1.6rem;
    }
    
    .blog-post h3 {
        font-size: 1.25rem;
        min-height: 3rem; /* Adjust for mobile */
        margin: 6px 0 6px 0;
    }
    
    .post-meta {
        margin-bottom: 6px;
        gap: 6px;
    }
    
    .post-meta-tags {
        gap: 4px;
        margin-bottom: 2px;
    }
    
    .post-meta-info {
        gap: 8px;
    }
    
    .post-excerpt {
        font-size: 0.9rem;
        min-height: 4.2rem; /* Adjust for mobile */
        -webkit-line-clamp: 3;
        line-clamp: 3;
        margin: 6px 0 20px 0;
    }
    
    .blog-intro {
        margin-top: 60px;
        padding: 35px 25px;
    }
    
    .blog-intro h2 {
        font-size: 1.5rem;
    }
    
    .blog-intro p {
        font-size: 1rem;
    }
}

/* Responsive improvements for list layout */
@media (max-width: 768px) {
    .blog-posts-list {
        gap: 16px;
    }
    
    .blog-post-item {
        padding: 20px 24px;
    }
    
    .blog-post-item h2 {
        font-size: 1.2rem;
    }
    
    .categories-strip {
        gap: 8px;
        padding: 16px 0;
    }
    
    .category-tag {
        padding: 8px 16px;
        font-size: 0.85rem;
    }
}

@media (max-width: 480px) {
    .categories-strip {
        overflow-x: auto;
        padding: 16px 0;
        gap: 6px;
    }
    
    .category-tag {
        flex-shrink: 0;
        padding: 6px 14px;
        font-size: 0.8rem;
    }
    
    .blog-post, 
    .blog-post.featured {
        padding: 25px;
    }
    
    .post-meta {
        flex-direction: column;
        align-items: flex-start;
        gap: 6px;
        font-size: 0.8rem;
    }
    
    .post-meta-tags {
        gap: 4px;
        margin-bottom: 2px;
    }
    
    .post-meta-info {
        gap: 8px;
        flex-direction: column;
        align-items: flex-start;
    }
    
    .featured h2 {
        font-size: 1.4rem;
    }
    
    .blog-post h3 {
        font-size: 1.2rem;
    }
}

/* Mobile responsive improvements for blog posts */
@media (max-width: 768px) {
    .blog-post-single {
        padding: 0 20px;
    }
    
    .post-header {
        padding: 24px 28px;
        margin: 24px 0 32px 0;
    }
    
    .post-title {
        font-size: clamp(1.8rem, 8vw, 2.5rem);
    }
    
    .post-content {
        padding: 32px 24px;
        font-size: 1rem;
    }
    
    .post-content h1 {
        font-size: 2rem;
    }
    
    .post-content h2 {
        font-size: 1.6rem;
    }
    
    .post-content h3 {
        font-size: 1.3rem;
    }
    
    .post-footer {
        padding: 28px 24px;
    }
    
    .post-navigation {
        flex-direction: column;
        text-align: center;
        gap: 12px;
        margin-bottom: 28px;
        padding-bottom: 24px;
    }
    
    .nav-link {
        padding: 12px 20px;
        font-size: 0.9rem;
        width: 100%;
        width: -moz-available;          /* WebKit-based browsers will ignore this. */
        width: -webkit-fill-available;  /* Mozilla-based browsers will ignore this. */
        width: stretch;
        justify-content: center;
    }
    
    .tag-links {
        justify-content: center;
        gap: 8px;
    }
    
    .tag-link {
        padding: 8px 14px;
        font-size: 0.8rem;
    }
}

/* Animation Classes */
.pop-in {
    opacity: 0;
    transform: translateY(10px);
    animation: popIn 0.4s ease forwards;
}

@keyframes popIn {
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Reduced stagger animation delays */
.pop-in:nth-child(1) { animation-delay: 0.05s; }
.pop-in:nth-child(2) { animation-delay: 0.1s; }
.pop-in:nth-child(3) { animation-delay: 0.15s; }
.pop-in:nth-child(4) { animation-delay: 0.2s; }
.pop-in:nth-child(5) { animation-delay: 0.25s; }
.pop-in:nth-child(6) { animation-delay: 0.3s; }

/* Reduced motion for accessibility - Blog specific */
@media (prefers-reduced-motion: reduce) {
    .pop-in,
    .blog-post,
    .blog-post-item,
    .tag-card,
    .nav-button,
    .category-tag,
    .post-category {
        animation: none !important;
        transition-duration: 0.1s !important;
    }
    
    .blog-post:hover,
    .blog-post-item:hover,
    .nav-button:hover {
        transform: none !important;
    }
}

.tag-links {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    align-items: center;
}

@media (max-width: 768px) {
    .tag-links {
        justify-content: center;
    }
}