/* Blog Archive/Listing Page Styles */

.blog-hero {
    margin-bottom: 80px;
}

.blog-hero {
    font-size: 64px;
    font-weight: 700;
    line-height: 1.2;
    margin-bottom: 24px;
    color: #ffffff;
}

.blog-hero {
    font-size: 18px;
    line-height: 1.6;
    color: rgba(255, 255, 255, 0.8);
    max-width: 800px;
}

.blog-main {
    padding: 120px 0 0 0;
    margin: 0;
}

.blog-section {
    padding: 0 20px;
    margin-bottom: 200px;
}

/* Category Filter Bar */
.blog-category-filter {
    display: flex;
    flex-wrap: nowrap;
    gap: 12px;
    margin-bottom: 40px;
    padding: 0;
    width: 100%;
}

.category-filter-btn {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 12px 20px;
    border-radius: 8px;
    border: 1px solid transparent;
    background-origin: border-box;
    background-clip: padding-box, border-box;
    
    background-image:
        var(--tint, none),
        var(--inner-bg, linear-gradient(180deg, #393939 0%, #000000 100%)),
        var(--border-gradient, linear-gradient(180deg, #ffffff 0%, #000000 100%));
    background-blend-mode: color, normal, normal;
        
    color: #ffffff;
    font-family: 'Red Hat Display', sans-serif;
    font-size: 14px;
    font-weight: 400;
    line-height: 1.4;
    cursor: pointer;
    transition: all 0.3s ease;
    text-decoration: none;
    flex: 1;
    min-width: 0;
    /* Button-specific styles */
    background-color: transparent;
    outline: none;
    -webkit-appearance: none;
    -moz-appearance: none;
    appearance: none;
}

.btn-blue {
    --tint: linear-gradient(
        rgba(78, 138, 235, 0.4),
        rgba(78, 138, 235, 0.4)
    );
}

.btn-purple {
    --tint: linear-gradient(
        rgba(183, 78, 235, 0.4),
        rgba(183, 78, 235, 0.4)
    );
}

.btn-orange {
    --tint: linear-gradient(
        rgba(219, 138, 52, 0.4),
        rgba(219, 138, 52, 0.4)
    );
}

.btn-green {
    --tint: linear-gradient(
        rgba(110, 154, 128, 0.4),
        rgba(110, 154, 128, 0.4)
    );
}

.category-filter-btn .filter-text {
    text-align: center;
    overflow: hidden;
    text-overflow: ellipsis;
}

.category-filter-btn:hover {
    border-color: #ffffff;
}

.category-filter-btn.active {
    /*background: linear-gradient(180deg, #893bb0 0%, #000000 100%);*/
    border-color: #ffffff;
}

.category-filter-btn .filter-icon,
.category-filter-btn .blog-filter-icon {
    /* width: 16px; */
    /* height: 16px; */
    flex-shrink: 0;
    color: #80acf3;
}

.category-filter-btn.active .filter-icon,
.category-filter-btn.active .blog-filter-icon {
    color: #ffffff;
    opacity: 1;
}

.category-filter-btn .filter-text {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    gap: 2px;
    line-height: 1.2;
}

.category-filter-btn .filter-count {
    color: rgba(255, 255, 255, 0.7);
    font-weight: 400;
    font-size: 12px;
    display: block;
}

.category-filter-btn.active .filter-count {
    color: rgba(255, 255, 255, 0.9);
}

/* Blog Posts Grid */
.blog-posts-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(400px, 1fr));
    gap: 40px;
    margin-bottom: 80px;
}


@media (max-width: 1440px) {
    .blog-posts-grid {
        grid-template-columns: repeat(auto-fill, minmax(350px, 1fr));
        gap: 30px;
    }
}

@media (max-width: 768px) {
    .blog-posts-grid {
        grid-template-columns: 1fr;
        gap: 30px;
    }
}

/* Blog Card */
.blog-card {
    display: flex;
    flex-direction: column;
    padding: 0.625px;
    background: #ffffff !important;
    border: 0.625px solid #efefef !important;
    border-radius: 14px !important;
    background-image: none !important;
    background-origin: initial !important;
    background-clip: initial !important;
    transition: transform 0.3s ease, box-shadow 0.3s ease, opacity 0.25s cubic-bezier(0.4, 0, 0.2, 1), visibility 0.25s cubic-bezier(0.4, 0, 0.2, 1);
    overflow: hidden;
    position: relative;
    opacity: 1;
    visibility: visible;
}

/* Hidden state for filtered cards - smooth fade */
.blog-card.blog-card-hidden {
    opacity: 0;
    visibility: hidden;
    pointer-events: none;
    /* Subtle scale for smoother transition */
    transform: scale(0.99);
}

/* When display is none, ensure it's completely removed from layout */
.blog-card[style*="display: none"] {
    display: none !important;
}

.blog-card:hover {
    /*transform: translateY(-5px);*/
    /*box-shadow: 0 20px 40px rgba(0, 0, 0, 0.3);*/
}

.blog-card-image {
    width: 100%;
    height: 191.992px;
    overflow: hidden;
    position: relative;
}

.blog-card-image a {
    display: block;
    width: 100%;
    height: 100%;
}

.blog-thumbnail {
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: 50% 50%;
    transition: transform 0.3s ease;
}

.blog-card:hover .blog-thumbnail {
    transform: scale(1.05);
}

.blog-card-content {
    padding: 0;
    display: flex;
    flex-direction: column;
    flex-grow: 1;
    background: linear-gradient(180deg, #393939 0%, #000000 100%);
    /*border: 1px solid #000000;*/
    min-height: 291.904px;
    position: relative;
}

/* Category Label */
.blog-category-label {
    position: absolute;
    left: 23.99px;
    top: 23.99px;
    background: #f2f7fe;
    color: #3b68b0;
    font-family: 'Red Hat Display', sans-serif;
    font-size: 12px;
    font-weight: 400;
    line-height: 16px;
    padding: 0;
    height: 23.984px;
    border-radius: 20971500px;
    display: flex;
    align-items: center;
    justify-content: center;
    width: auto;
    min-width: 83.018px;
    padding: 0 13.88px;
    text-align: center;
    white-space: nowrap;
}

.blog-card-title {
    position: absolute;
    left: 23.99px;
    top: 59.97px;
    width: 478.77px;
    max-width: calc(100% - 47.98px);
    font-family: 'Red Hat Display', sans-serif;
    font-size: 16px;
    font-weight: 400;
    line-height: 24px;
    letter-spacing: -0.3125px;
    margin: 0;
    color: #ffffff;
}

.blog-card-title a {
    color: #ffffff;
    text-decoration: none;
    transition: color 0.3s ease;
}

.blog-card-title a:hover {
    color: #80ACF3;
}

.blog-card-excerpt {
    position: absolute;
    left: 23.99px;
    top: 119.95px;
    width: 478.77px;
    max-width: calc(100% - 47.98px);
    font-family: 'Red Hat Display', sans-serif;
    font-size: 16px;
    font-weight: 400;
    line-height: 24px;
    letter-spacing: -0.3125px;
    color: #ffffff;
    margin: 0;
}

.blog-card-excerpt p {
    margin: 0;
}

.blog-card-footer {
    position: absolute;
    left: 23.99px;
    top: 207.93px;
    width: 478.77px;
    max-width: calc(100% - 47.98px);
    display: flex;
    flex-direction: column;
    gap: 16px;
}

/* Tags */
.blog-card-tags {
    display: flex;
    gap: 8px;
    height: 23.984px;
    align-items: flex-start;
}

.blog-tag {
    background: #efefef;
    color: #050505;
    font-family: 'Red Hat Display', sans-serif;
    font-size: 12px;
    font-weight: 400;
    line-height: 16px;
    padding: 4.62px 8px;
    border-radius: 4px;
    white-space: nowrap;
    height: 23.984px;
    display: inline-flex;
    align-items: center;
}

/* Meta Row */
.blog-card-meta-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    height: 20px;
    width: 100%;
}

.blog-meta-item {
    display: flex;
    align-items: center;
    gap: 7.998px;
    height: 20px;
}

.blog-meta-item:last-child {
    margin-left: auto;
}

.blog-meta-icon {
    width: 15.996px;
    height: 15.996px;
    color: #ffffff;
    flex-shrink: 0;
}

.blog-meta-text {
    font-family: 'Red Hat Display', sans-serif;
    font-size: 14px;
    font-weight: 400;
    line-height: 20px;
    letter-spacing: -0.1504px;
    color: #ffffff;
    white-space: nowrap;
}

/* Pagination */
.blog-pagination {
    display: flex;
    justify-content: center;
    align-items: center;
    margin-top: 50px;
    transition: opacity 0.3s ease, visibility 0.3s ease;
    opacity: 1;
    visibility: visible;
}

.blog-pagination.blog-pagination-hidden {
    opacity: 0;
    visibility: hidden;
    height: 0;
    margin: 0;
    overflow: hidden;
}

.blog-pagination .page-numbers {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 44px;
    height: 44px;
    padding: 0 16px;
    margin: 0 4px;
    color: #ffffff;
    text-decoration: none;
    border-radius: 8px;
    background: linear-gradient(180deg, #292929 0%, #000000 100%);
    border: 1px solid rgba(255, 255, 255, 0.1);
    transition: all 0.3s ease;
    font-weight: 500;
}

.blog-pagination .page-numbers:hover,
.blog-pagination .page-numbers.current {
    background: linear-gradient(180deg, #80acf3 0%, #000000 100%);
    border-color: #80acf3;
    color: #ffffff;
}

.blog-pagination .pagination-arrow {
    display: inline-block;
    margin: 0 4px;
}

/* No Posts Message */
.blog-no-posts {
    text-align: center;
    padding: 100px 20px;
}

.no-posts-message {
    font-size: 24px;
    color: rgba(255, 255, 255, 0.6);
}

/* Responsive Adjustments */
@media (max-width: 768px) {
    .blog-hero {
        font-size: 40px;
    }
    
    .blog-hero .hero-description {
        font-size: 16px;
    }
    
    .blog-category-filter {
        gap: 8px;
        margin-bottom: 30px;
        /*overflow-x: auto;*/
        padding-bottom: 10px;
        -webkit-overflow-scrolling: touch;
        flex-wrap: wrap;
    }
    
    .blog-category-filter::-webkit-scrollbar {
        height: 4px;
    }
    
    .blog-category-filter::-webkit-scrollbar-track {
        background: rgba(255, 255, 255, 0.1);
        border-radius: 2px;
    }
    
    .blog-category-filter::-webkit-scrollbar-thumb {
        background: rgba(255, 255, 255, 0.3);
        border-radius: 2px;
    }
    
    .category-filter-btn {
        padding: 10px 16px;
        font-size: 13px;
        flex: 1 1 auto;
        min-width: 120px;
    }
    
    .category-filter-btn .filter-icon {
        width: 14px;
        height: 14px;
    }
    
    .blog-card-image {
        height: 200px;
    }
    
    .blog-card-content {
        min-height: auto;
        padding: 20px;
        position: relative;
    }
    
    .blog-category-label {
        position: relative;
        left: auto;
        top: auto;
        margin-bottom: 16px;
        /* display: inline-block; */
    }
    
    .blog-card-title {
        position: relative;
        left: auto;
        top: auto;
        width: 100%;
        max-width: 100%;
        margin-bottom: 12px;
        font-size: 18px;
    }
    
    .blog-card-excerpt {
        position: relative;
        left: auto;
        top: auto;
        width: 100%;
        max-width: 100%;
        margin-bottom: 16px;
    }
    
    .blog-card-footer {
        position: relative;
        left: auto;
        top: auto;
        width: 100%;
        max-width: 100%;
    }
    
    .blog-card-meta-row {
        flex-wrap: wrap;
        gap: 12px;
    }
    
    .blog-pagination .page-numbers {
        min-width: 36px;
        height: 36px;
        padding: 0 12px;
        font-size: 14px;
    }
}
