/* =============================================
   FONDOSTECH BLOG PAGE — ENHANCED ANIMATIONS
   ============================================= */

/* ---------------------------------------------
   1. HERO SECTION WITH RICH MESH GRADIENT & GRID
   --------------------------------------------- */
.blog-hero-section {
    background: radial-gradient(circle at 50% -20%, #dbeafe 0%, #f5faff 55%, #ffffff 100%);
    color: #212529;
    padding: 7.5rem 0 5rem;
    position: relative;
    overflow: hidden;
    border-bottom: 1px solid #cee4fd;
}

/* Subtle Geometric Grid Lines */
.blog-hero-section::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-image: 
        linear-gradient(to right, rgba(8, 106, 216, 0.04) 1px, transparent 1px),
        linear-gradient(to bottom, rgba(8, 106, 216, 0.04) 1px, transparent 1px);
    background-size: 54px 54px;
    mask-image: radial-gradient(ellipse at center, rgba(0,0,0,0.8) 0%, rgba(0,0,0,0) 75%);
    pointer-events: none;
}

/* Soft Ambient Light Glow Orbs */
.blog-glow-orb-1 {
    position: absolute;
    top: -80px;
    left: 15%;
    width: 450px;
    height: 450px;
    background: radial-gradient(circle, rgba(8, 106, 216, 0.15) 0%, rgba(0, 0, 0, 0) 70%);
    filter: blur(60px);
    pointer-events: none;
    animation: orbPulseLight1 8s ease-in-out infinite alternate;
}

.blog-glow-orb-2 {
    position: absolute;
    bottom: -60px;
    right: 15%;
    width: 450px;
    height: 450px;
    background: radial-gradient(circle, rgba(56, 189, 248, 0.18) 0%, rgba(0, 0, 0, 0) 70%);
    filter: blur(60px);
    pointer-events: none;
    animation: orbPulseLight2 10s ease-in-out infinite alternate;
}

@keyframes orbPulseLight1 { 0% { transform: translate(0, 0) scale(0.95); } 100% { transform: translate(25px, 15px) scale(1.1); } }
@keyframes orbPulseLight2 { 0% { transform: translate(0, 0) scale(0.95); } 100% { transform: translate(-25px, -15px) scale(1.1); } }

.blog-hero-content {
    position: relative;
    z-index: 2;
}

.blog-breadcrumb {
    font-size: 0.875rem;
    color: #64748b;
    margin-bottom: 1.25rem;
    font-weight: 500;
}

.blog-breadcrumb a {
    color: #64748b;
    text-decoration: none;
    transition: color 0.2s ease;
}

.blog-breadcrumb a:hover {
    color: #086ad8;
}

.blog-section-label {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.45rem 1.2rem;
    background: rgba(8, 106, 216, 0.08);
    border: 1px solid rgba(8, 106, 216, 0.2);
    border-radius: 2rem;
    color: #086ad8;
    font-size: 0.8125rem;
    font-weight: 700;
    letter-spacing: 1.2px;
    text-transform: uppercase;
    margin-bottom: 1.25rem;
    box-shadow: 0 4px 14px rgba(8, 106, 216, 0.06);
}

.blog-badge-dot {
    width: 8px;
    height: 8px;
    background-color: #086ad8;
    border-radius: 50%;
    box-shadow: 0 0 8px rgba(8, 106, 216, 0.6);
    animation: dotPulse 2s infinite ease-in-out;
}

@keyframes dotPulse {
    0%, 100% { transform: scale(1); opacity: 1; }
    50% { transform: scale(1.4); opacity: 0.5; }
}

.blog-hero-title {
    font-size: 3.25rem;
    font-weight: 800;
    line-height: 1.18;
    letter-spacing: -0.5px;
    color: #0f172a;
    margin-bottom: 1.25rem;
}

.blog-hero-title .text-primary-custom {
    color: #086ad8;
}

.blog-hero-desc {
    font-size: 1.125rem;
    line-height: 1.65;
    color: #475569;
    max-width: 720px;
    margin: 0 auto 2.5rem;
}

/* Light Glass Search Bar */
.blog-search-box {
    max-width: 620px;
    margin: 0 auto 2.5rem;
    position: relative;
    z-index: 2;
}

.blog-search-input {
    width: 100%;
    padding: 1.1rem 1.75rem 1.1rem 3.5rem;
    background: #ffffff;
    border: 1.5px solid #cee4fd;
    border-radius: 2.5rem;
    color: #0f172a;
    font-size: 0.9875rem;
    outline: none;
    box-shadow: 0 10px 30px rgba(8, 106, 216, 0.08);
    transition: all 0.3s ease;
}

.blog-search-input::placeholder {
    color: #94a3b8;
}

.blog-search-input:focus {
    border-color: #086ad8;
    background: #ffffff;
    box-shadow: 0 12px 36px rgba(8, 106, 216, 0.18);
}

.blog-search-icon {
    position: absolute;
    left: 1.35rem;
    top: 50%;
    transform: translateY(-50%);
    color: #086ad8;
    pointer-events: none;
}

/* Category Filter Buttons */
.blog-categories-wrap {
    display: flex;
    justify-content: center;
    gap: 0.75rem;
    flex-wrap: wrap;
    position: relative;
    z-index: 2;
}

.blog-cat-btn {
    background: #ffffff;
    border: 1px solid #cee4fd;
    color: #1e293b;
    font-size: 0.9375rem;
    font-weight: 600;
    padding: 0.65rem 1.35rem;
    border-radius: 2.5rem;
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    gap: 0.55rem;
    box-shadow: 0 4px 12px rgba(33, 37, 41, 0.03);
    transition: all 0.25s ease;
    text-decoration: none;
}

.blog-cat-btn .cat-btn-icon {
    color: #086ad8;
    transition: color 0.25s ease, transform 0.25s ease;
    flex-shrink: 0;
}

.blog-cat-btn:hover {
    border-color: #086ad8;
    color: #086ad8;
    box-shadow: 0 6px 20px rgba(8, 106, 216, 0.12);
    transform: translateY(-3px);
}

.blog-cat-btn:hover .cat-btn-icon {
    color: #086ad8;
    transform: scale(1.15);
}

.blog-cat-btn.active {
    background: #086ad8;
    color: #ffffff;
    border-color: #086ad8;
    box-shadow: 0 6px 20px rgba(8, 106, 216, 0.3);
}

.blog-cat-btn.active .cat-btn-icon {
    color: #ffffff;
}

/* ---------------------------------------------
   2. FEATURED HERO ARTICLE (ENHANCED CARD UI)
   --------------------------------------------- */
.featured-post-section {
    padding: 4.5rem 0 2.5rem;
    background: #ffffff;
    position: relative;
}

.featured-card {
    background: #ffffff;
    border: 1px solid #cee4fd;
    border-radius: 1.75rem;
    overflow: hidden;
    box-shadow: 0 10px 35px rgba(33, 37, 41, 0.06);
    transition: transform 0.4s cubic-bezier(0.16, 1, 0.3, 1), box-shadow 0.4s ease, border-color 0.4s ease;
}

.featured-card:hover {
    transform: translateY(-8px) !important;
    box-shadow: 0 24px 50px rgba(8, 106, 216, 0.16) !important;
    border-color: #086ad8 !important;
}

.featured-img-wrap {
    position: relative;
    overflow: hidden;
    height: 100%;
    min-height: 340px;
}

.featured-img-wrap img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.6s cubic-bezier(0.16, 1, 0.3, 1);
}

.featured-card:hover .featured-img-wrap img {
    transform: scale(1.05);
}

.featured-badge {
    position: absolute;
    top: 1.25rem;
    left: 1.25rem;
    background: #086ad8;
    color: #ffffff;
    font-size: 0.75rem;
    font-weight: 700;
    letter-spacing: 1px;
    text-transform: uppercase;
    padding: 0.35rem 0.85rem;
    border-radius: 2rem;
    box-shadow: 0 4px 12px rgba(8, 106, 216, 0.3);
}

.featured-content {
    padding: 3rem 2.5rem;
    display: flex;
    flex-direction: column;
    justify-content: center;
    height: 100%;
}

.featured-card-label {
    display: inline-block;
    font-size: 0.875rem;
    font-weight: 700;
    color: #086ad8;
    text-transform: uppercase;
    margin-bottom: 0.5rem;
}

.meta-info {
    display: flex;
    align-items: center;
    gap: 0.85rem;
    font-size: 0.875rem;
    color: #64748b;
    margin-bottom: 1rem;
}

.featured-title {
    font-size: 2rem;
    font-weight: 700;
    color: #0f172a !important;
    line-height: 1.3;
    margin-bottom: 1rem;
    transition: color 0.25s ease;
}

.featured-card:hover .featured-title {
    color: #086ad8 !important;
}

.featured-excerpt {
    font-size: 1rem;
    color: #475569;
    line-height: 1.6;
    margin-bottom: 1.75rem;
}

.author-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding-top: 1.25rem;
    border-top: 1px solid #f1f5f9;
}

.author-left {
    display: flex;
    align-items: center;
    gap: 0.85rem;
}

.author-avatar {
    width: 44px;
    height: 44px;
    border-radius: 50%;
    background: #086ad8;
    color: #ffffff;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 700;
    font-size: 0.9375rem;
}

.author-name {
    font-size: 0.9375rem;
    font-weight: 700;
    color: #0f172a;
}

.author-role {
    font-size: 0.8125rem;
    color: #64748b;
}

/* ---------------------------------------------
   3. ARTICLES GRID (STAGGERED ANIMATIONS)
   --------------------------------------------- */
.articles-grid-section {
    padding: 2.5rem 0 5rem;
    background: #f8fafc;
}

.blog-card-item {
    transition: opacity 0.4s ease, transform 0.4s ease;
}

/* Dynamic Staggered Entrance Keyframes */
.blog-card-item.card-animated {
    animation: blogCardStagger 0.5s cubic-bezier(0.16, 1, 0.3, 1) forwards;
}

@keyframes blogCardStagger {
    0% {
        opacity: 0;
        transform: translateY(24px) scale(0.97);
    }
    100% {
        opacity: 1;
        transform: translateY(0) scale(1);
    }
}

.blog-card {
    background: #ffffff;
    border: 1px solid #cee4fd;
    border-radius: 1.5rem;
    overflow: hidden;
    height: 100%;
    display: flex;
    flex-direction: column;
    box-shadow: 0 8px 24px rgba(33, 37, 41, 0.04);
    transition: transform 0.35s cubic-bezier(0.16, 1, 0.3, 1), box-shadow 0.35s ease, border-color 0.35s ease;
}

.blog-card:hover {
    transform: translateY(-8px) !important;
    border-color: #086ad8 !important;
    box-shadow: 0 20px 45px rgba(8, 106, 216, 0.15) !important;
}

.blog-card-img {
    position: relative;
    height: 220px;
    overflow: hidden;
    background: #f1f5f9;
}

.blog-card-img img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.5s cubic-bezier(0.16, 1, 0.3, 1);
}

.blog-card:hover .blog-card-img img {
    transform: scale(1.06);
}

.blog-card-category {
    position: absolute;
    top: 1rem;
    left: 1rem;
    background: rgba(8, 106, 216, 0.9);
    backdrop-filter: blur(8px);
    color: #ffffff;
    font-size: 0.75rem;
    font-weight: 700;
    letter-spacing: 0.5px;
    padding: 0.35rem 0.85rem;
    border-radius: 2rem;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.12);
}

.blog-card-body {
    padding: 1.75rem 1.65rem;
    display: flex;
    flex-direction: column;
    flex-grow: 1;
}

.blog-card-label {
    display: inline-block;
    font-size: 0.8125rem;
    font-weight: 800;
    letter-spacing: 1.2px;
    color: #086ad8;
    text-transform: uppercase;
    margin-bottom: 0.4rem;
}

.blog-card-meta {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    font-size: 0.8125rem;
    color: #64748b;
    margin-bottom: 0.75rem;
}

.blog-card-title {
    font-size: 1.35rem;
    font-weight: 700;
    color: #0f172a !important;
    line-height: 1.35;
    margin-bottom: 0.85rem;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
    transition: color 0.25s ease;
}

.blog-card:hover .blog-card-title {
    color: #086ad8 !important;
}

.blog-card-excerpt {
    font-size: 0.9375rem;
    color: #475569;
    line-height: 1.6;
    margin-bottom: 1.5rem;
    display: -webkit-box;
    -webkit-line-clamp: 3;
    -webkit-box-orient: vertical;
    overflow: hidden;
    flex-grow: 1;
}

.blog-card-footer {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding-top: 1.125rem;
    border-top: 1px solid #f1f5f9;
}

.author-role {
    font-size: 0.8125rem;
    font-weight: 600;
    color: #64748b;
}

.btn-link-custom {
    color: #086ad8;
    font-weight: 700;
    font-size: 0.9375rem;
    text-decoration: none;
    display: inline-flex;
    align-items: center;
    gap: 0.4rem;
    padding: 0.4rem 0.85rem;
    border-radius: 1.5rem;
    background: rgba(8, 106, 216, 0.06);
    white-space: nowrap;
    flex-shrink: 0;
    transition: all 0.25s ease;
}

.btn-link-custom .btn-icon {
    width: 9px;
    height: 14px;
    transition: transform 0.25s ease;
}

.blog-card:hover .btn-link-custom {
    background: #086ad8;
    color: #ffffff;
    box-shadow: 0 4px 14px rgba(8, 106, 216, 0.3);
}

.blog-card:hover .btn-link-custom .btn-icon {
    transform: translateX(5px);
}

/* Pagination Bar */
.blog-pagination {
    display: flex;
    justify-content: center;
    gap: 0.5rem;
    margin-top: 3.5rem;
}

.page-link-custom {
    width: 44px;
    height: 44px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    background: #ffffff;
    border: 1px solid #cee4fd;
    color: #0f172a;
    font-weight: 700;
    font-size: 0.9375rem;
    text-decoration: none;
    transition: all 0.25s ease;
}

.page-link-custom:hover,
.page-link-custom.active {
    background: #086ad8;
    color: #ffffff;
    border-color: #086ad8;
    box-shadow: 0 4px 14px rgba(8, 106, 216, 0.3);
}

/* Mobile Responsive Adjustments */
@media (max-width: 991.98px) {
    .blog-hero-section {
        padding: 5.5rem 0 3.5rem;
    }

    .blog-hero-title {
        font-size: 2.15rem;
    }

    .blog-categories-wrap {
        justify-content: flex-start;
        flex-wrap: nowrap;
        overflow-x: auto;
        -webkit-overflow-scrolling: touch;
        padding-bottom: 0.75rem;
        margin-left: -1rem;
        margin-right: -1rem;
        padding-left: 1rem;
        padding-right: 1rem;
        scrollbar-width: none;
    }

    .blog-categories-wrap::-webkit-scrollbar {
        display: none;
    }

    .blog-cat-btn {
        flex-shrink: 0;
        white-space: nowrap;
    }

    .featured-content {
        padding: 2rem 1.5rem;
    }
}

@media (max-width: 575.98px) {
    .blog-hero-title {
        font-size: 1.75rem;
    }

    .featured-content {
        padding: 1.5rem 1.15rem;
    }

    .featured-title {
        font-size: 1.35rem;
    }

    .author-row {
        flex-direction: column;
        align-items: flex-start;
        gap: 1.25rem;
    }

    .blog-card-body {
        padding: 1.35rem 1.15rem;
    }

    .blog-card-footer {
        flex-wrap: wrap;
        gap: 0.75rem;
        align-items: center;
    }
}
