/* =============================================
   SDNET Blog Styles
   ============================================= */

/* Override nav colors for blog pages (dark header background) */
.header-area .main-nav .nav li a {
    color: #fff !important;
}

.header-area .main-nav .nav li:hover a,
.header-area .main-nav .nav li a.active {
    color: #4b8ef1 !important;
}

.header-area {
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
    transition: transform 0.35s ease, opacity 0.35s ease;
}

.header-area.header-hidden {
    transform: translateY(-100%);
    opacity: 0;
    pointer-events: none;
}

/* Blog Section Header */
.blog-header {
    background: linear-gradient(135deg, #1a1a2e 0%, #16213e 50%, #0f3460 100%);
    padding: 140px 0 80px;
    text-align: center;
    position: relative;
    overflow: hidden;
}

.blog-header::before {
    content: '';
    position: absolute;
    top: -50%;
    left: -50%;
    width: 200%;
    height: 200%;
    background: radial-gradient(circle, rgba(75, 142, 241, 0.1) 0%, transparent 70%);
    animation: blogHeaderPulse 8s ease-in-out infinite;
}

@keyframes blogHeaderPulse {

    0%,
    100% {
        transform: scale(1);
        opacity: 0.5;
    }

    50% {
        transform: scale(1.1);
        opacity: 1;
    }
}

.blog-header h1 {
    color: #fff;
    font-size: 42px;
    font-weight: 700;
    margin-bottom: 15px;
    position: relative;
    z-index: 1;
}

.blog-header p {
    color: rgba(255, 255, 255, 0.85);
    font-size: 18px;
    max-width: 600px;
    margin: 0 auto;
    position: relative;
    z-index: 1;
}

.blog-header .breadcrumb-nav {
    margin-top: 20px;
    position: relative;
    z-index: 1;
}

.blog-header .breadcrumb-nav a {
    color: rgba(255, 255, 255, 0.8);
    transition: color 0.3s;
}

.blog-header .breadcrumb-nav a:hover {
    color: #4b8ef1;
}

.blog-header .breadcrumb-nav span {
    color: #4b8ef1;
    margin: 0 8px;
}

/* Blog Grid */
.blog-section {
    padding: 60px 0 80px;
    background: #f8f9fa;
    min-height: 60vh;
}

.blog-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(340px, 1fr));
    gap: 30px;
    margin-top: 10px;
}

/* Blog Cards */
.blog-card {
    background: #fff;
    border-radius: 16px;
    overflow: hidden;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.06);
    transition: all 0.4s cubic-bezier(0.25, 0.46, 0.45, 0.94);
    cursor: pointer;
    position: relative;
}

.blog-card:hover {
    transform: translateY(-8px);
    box-shadow: 0 12px 40px rgba(75, 142, 241, 0.15);
}

.blog-card-image {
    width: 100%;
    aspect-ratio: 16 / 9;
    overflow: hidden;
    position: relative;
    background: #f0f4f8;
}

.blog-card-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: center;
    transition: transform 0.6s ease;
    display: block;
}

.blog-card:hover .blog-card-image img {
    transform: scale(1.08);
}

.blog-card-image .image-placeholder {
    width: 100%;
    height: 100%;
    background: linear-gradient(135deg, #4b8ef1 0%, #28e1fd 100%);
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-size: 48px;
}

.blog-card-body {
    padding: 24px;
}

.blog-card-date {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    font-size: 13px;
    color: #4b8ef1;
    font-weight: 500;
    margin-bottom: 12px;
    background: rgba(75, 142, 241, 0.08);
    padding: 4px 12px;
    border-radius: 20px;
}

.blog-card-date i {
    font-size: 12px;
}

.blog-card-title {
    font-size: 20px;
    font-weight: 700;
    color: #1a1a2e;
    margin-bottom: 12px;
    line-height: 1.4;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
    transition: color 0.3s;
}

.blog-card:hover .blog-card-title {
    color: #4b8ef1;
}

.blog-card-excerpt {
    font-size: 14px;
    color: #666;
    line-height: 1.7;
    margin-bottom: 20px;
    display: -webkit-box;
    -webkit-line-clamp: 3;
    line-clamp: 3;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.blog-card-link {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    color: #4b8ef1;
    font-weight: 600;
    font-size: 14px;
    transition: all 0.3s;
}

.blog-card-link i {
    transition: transform 0.3s;
}

.blog-card:hover .blog-card-link i {
    transform: translateX(4px);
}

/* Blog Post Detail Page */
.blog-post-header {
    position: relative;
    height: 450px;
    overflow: hidden;
    background: #1a1a2e;
}

.blog-post-header img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    opacity: 0.6;
}

.blog-post-header .header-placeholder {
    width: 100%;
    height: 100%;
    background: linear-gradient(135deg, #1a1a2e 0%, #0f3460 100%);
    display: flex;
    align-items: center;
    justify-content: center;
}

.blog-post-header .header-placeholder i {
    font-size: 80px;
    color: rgba(75, 142, 241, 0.3);
}

.blog-post-header .overlay {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    padding: 80px 0 40px;
    padding-top: 100px;
    background: linear-gradient(transparent, rgba(0, 0, 0, 0.8));
}

.blog-post-header .overlay h1 {
    color: #fff;
    font-size: 36px;
    font-weight: 700;
    margin-bottom: 15px;
    max-width: 800px;
}

.blog-post-meta {
    display: flex;
    align-items: center;
    gap: 20px;
    flex-wrap: wrap;
}

.blog-post-meta .meta-item {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    color: rgba(255, 255, 255, 0.7);
    font-size: 14px;
}

.blog-post-meta .meta-item i {
    color: #4b8ef1;
}

/* Blog Post Content */
.blog-post-content {
    padding: 50px 0 80px;
    background: #fff;
}

.blog-post-content .post-body {
    max-width: 780px;
    margin: 0 auto;
    font-size: 16px;
    line-height: 1.9;
    color: #333;
}

.blog-post-content .post-body h2,
.blog-post-content .post-body h3 {
    color: #1a1a2e;
    margin-top: 35px;
    margin-bottom: 15px;
    font-weight: 700;
}

.blog-post-content .post-body h2 {
    font-size: 28px;
}

.blog-post-content .post-body h3 {
    font-size: 22px;
}

.blog-post-content .post-body p {
    margin-bottom: 20px;
    color: #444;
    font-size: 16px;
    line-height: 1.9;
}

.blog-post-content .post-body a {
    color: #4b8ef1;
    font-weight: 500;
    border-bottom: 1px solid transparent;
    transition: border-color 0.3s;
}

.blog-post-content .post-body a:hover {
    border-bottom-color: #4b8ef1;
}

.blog-post-content .post-body strong {
    color: #1a1a2e;
}

.blog-post-content .post-body img {
    border-radius: 12px;
    margin: 20px 0;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.1);
}

/* Back to Blog Button */
.back-to-blog {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 10px 24px;
    background: rgba(75, 142, 241, 0.1);
    color: #4b8ef1;
    border-radius: 25px;
    font-weight: 600;
    font-size: 14px;
    margin-bottom: 30px;
    transition: all 0.3s;
}

.back-to-blog:hover {
    background: #4b8ef1;
    color: #fff;
}

.back-to-blog i {
    transition: transform 0.3s;
}

.back-to-blog:hover i {
    transform: translateX(-4px);
}

/* Loading & Empty States */
.blog-loading {
    text-align: center;
    padding: 80px 20px;
    color: #999;
}

.blog-loading .spinner {
    width: 40px;
    height: 40px;
    border: 3px solid #eee;
    border-top-color: #4b8ef1;
    border-radius: 50%;
    animation: spin 0.8s linear infinite;
    margin: 0 auto 20px;
}

@keyframes spin {
    to {
        transform: rotate(360deg);
    }
}

.blog-empty {
    text-align: center;
    padding: 80px 20px;
    color: #999;
}

.blog-empty i {
    font-size: 60px;
    color: #ddd;
    margin-bottom: 20px;
}

/* Share Section */
.blog-share {
    margin-top: 50px;
    padding-top: 30px;
    border-top: 1px solid #eee;
}

.blog-share h4 {
    font-size: 16px;
    font-weight: 600;
    color: #1a1a2e;
    margin-bottom: 15px;
}

.blog-share .share-buttons {
    display: flex;
    gap: 10px;
}

.blog-share .share-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 42px;
    height: 42px;
    border-radius: 50%;
    color: #fff;
    font-size: 16px;
    transition: all 0.3s;
}

.blog-share .share-btn:hover {
    transform: translateY(-3px);
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.2);
}

.blog-share .share-btn.facebook {
    background: #1877f2;
}

.blog-share .share-btn.twitter {
    background: #1da1f2;
}

.blog-share .share-btn.whatsapp {
    background: #25d366;
}

.blog-share .share-btn.linkedin {
    background: #0077b5;
}

/* Responsive */
@media (max-width: 768px) {
    .blog-header {
        padding: 120px 0 50px;
    }

    .blog-header h1 {
        font-size: 28px;
    }

    .blog-grid {
        grid-template-columns: 1fr;
        gap: 20px;
    }

    .blog-post-header {
        height: 400px;
    }

    .blog-post-header .overlay h1 {
        font-size: 24px;
    }

    .blog-post-content .post-body {
        padding: 0 15px;
    }

    .related-posts-grid {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 576px) {

    .blog-post-header {
        height: 350px;
    }

    .blog-post-meta {
        gap: 12px;
    }
}

/* ==================== Tags Section ==================== */
.blog-tags {
    margin: 30px 0;
    padding: 25px 30px;
    background: #f8f9fa;
    border-radius: 12px;
    border-left: 4px solid #4b8ef1;
}

.blog-tags h4 {
    font-size: 16px;
    color: #333;
    margin-bottom: 12px;
    font-weight: 600;
}

.blog-tags h4 i {
    color: #4b8ef1;
    margin-right: 8px;
}

.tags-list {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}

.tag-item {
    display: inline-block;
    padding: 6px 14px;
    background: linear-gradient(135deg, #e8f0fe, #dbeafe);
    color: #1a56db;
    border-radius: 20px;
    font-size: 13px;
    font-weight: 500;
    transition: all 0.2s ease;
    border: 1px solid rgba(75, 142, 241, 0.15);
}

.tag-item:hover {
    background: linear-gradient(135deg, #4b8ef1, #3a7ae0);
    color: #fff;
    transform: translateY(-1px);
    box-shadow: 0 3px 8px rgba(75, 142, 241, 0.3);
}

/* ==================== Related Posts ==================== */
.related-posts {
    margin: 40px 0 20px;
    padding-top: 30px;
    border-top: 2px solid #f0f0f0;
}

.related-posts h4 {
    font-size: 18px;
    color: #333;
    margin-bottom: 20px;
    font-weight: 600;
}

.related-posts h4 i {
    color: #4b8ef1;
    margin-right: 8px;
}

.related-posts-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));
    gap: 20px;
}

.related-post-card {
    display: flex;
    flex-direction: column;
    background: #fff;
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.08);
    transition: all 0.3s ease;
    text-decoration: none;
    border: 1px solid #eee;
}

.related-post-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.12);
    border-color: #4b8ef1;
}

.related-post-image {
    height: 160px;
    overflow: hidden;
    background: linear-gradient(135deg, #667eea, #764ba2);
}

.related-post-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.3s ease;
}

.related-post-card:hover .related-post-image img {
    transform: scale(1.05);
}

.related-post-image .image-placeholder {
    width: 100%;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 32px;
    color: rgba(255, 255, 255, 0.5);
}

.related-post-info {
    padding: 15px;
}

.related-post-info h5 {
    font-size: 15px;
    font-weight: 600;
    color: #333;
    margin-bottom: 8px;
    line-height: 1.4;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.related-post-card:hover .related-post-info h5 {
    color: #4b8ef1;
}

.related-post-date {
    font-size: 12px;
    color: #888;
}

.related-post-date i {
    margin-right: 4px;
}