SS
Copy

/* Elementor Blog Posts Widget - Modern Design - Fixed Hover Effects */

/* CSS Variables for Theme Colors */
:root {
    --primary: #2a97aa;
    --primary-light: #3aa6b9;
    --primary-dark: #2a8696;
    --accent: #94c17d;
    --accent-secondary: #35a9a6;
    --surface: #ffffff;
    --surface-alt: #e8f5f6;
    --text-primary: #39414d;
    --text-secondary: #4a5361;
    --text-tertiary: #adc6c8;
    --border: #9ad8d0;
    --gradient-gov: linear-gradient(135deg, #2a97aa 0%, #37ada9 100%);
    --shadow-md: 0 4px 6px -1px rgba(42, 151, 170, 0.1);
    --shadow-xl: 0 25px 50px -12px rgba(42, 151, 170, 0.25);
}

/* Headings */
h1,
.elementor-heading-title h1,
.elementor-widget-heading h1 {
    text-align: center;
    color: #3AA6B9;
    margin-bottom: 20px;
}

h4,
.elementor-heading-title h4,
.elementor-widget-heading h4 {
    text-align: center;
    color: #020101;
    margin-bottom: 15px;
}

/* Wrapper */
.elementor-blog-posts-wrapper {
    width: 100%;
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

/* Grid */
.elementor-blog-posts-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 35px;
    margin-bottom: 50px;
    width: 100%;
    box-sizing: border-box;
}

/* Column layouts */
.elementor-blog-posts-grid.elementor-blog-posts-col-1 {
    grid-template-columns: 1fr;
}

.elementor-blog-posts-grid.elementor-blog-posts-col-2 {
    grid-template-columns: repeat(2, 1fr);
}

.elementor-blog-posts-grid.elementor-blog-posts-col-3 {
    grid-template-columns: repeat(3, 1fr);
}

.elementor-blog-posts-grid.elementor-blog-posts-col-4 {
    grid-template-columns: repeat(4, 1fr);
}

/* Modern News Card */
.blog-post-card {
    background: #ffffff;
    border-radius: 24px;
    overflow: hidden;
    position: relative;
    transition: all 0.5s cubic-bezier(0.23, 1, 0.32, 1);
    box-shadow: 0 4px 6px -1px rgba(42, 151, 170, 0.1);
    border: 1px solid #9ad8d0;
    display: flex;
    flex-direction: column;
    height: 100%;
}

.blog-post-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(135deg, rgba(42, 151, 170, 0.05) 0%, rgba(148, 193, 125, 0.05) 100%);
    opacity: 0;
    transition: opacity 0.5s ease;
    pointer-events: none;
    z-index: 1;
}

/* HOVER EFFECT - FIXED */
.blog-post-card:hover {
    transform: translateY(-12px) scale(1.02) !important;
    box-shadow: 0 25px 50px -12px rgba(42, 151, 170, 0.25) !important;
    border-color: transparent !important;
}

.blog-post-card:hover::before {
    opacity: 1;
}

/* Card Image with Advanced Effects */
.blog-post-image {
    position: relative;
    width: 100%;
    height: 260px;
    overflow: hidden;
    background: linear-gradient(135deg, #2a97aa 0%, #37ada9 100%);
    flex-shrink: 0;
}

.blog-post-image::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    height: 50%;
    background: linear-gradient(to top, rgba(0,0,0,0.7) 0%, transparent 100%);
    z-index: 1;
    pointer-events: none;
}

.blog-post-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.7s cubic-bezier(0.23, 1, 0.32, 1), filter 0.7s ease;
    filter: brightness(0.95);
    display: block;
}

/* IMAGE HOVER - FIXED */
.blog-post-card:hover .blog-post-image img {
    transform: scale(1.15) rotate(2deg) !important;
    filter: brightness(1.05) !important;
}

/* Floating Badge */
.blog-post-badge {
    position: absolute;
    top: 20px;
    left: 20px;
    z-index: 2;
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 8px 18px;
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(20px);
    border-radius: 50px;
    font-size: 0.75em;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 1px;
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.1);
    animation: badge-entrance 0.6s cubic-bezier(0.34, 1.56, 0.64, 1);
}

@keyframes badge-entrance {
    from {
        opacity: 0;
        transform: translateY(-20px) scale(0.8);
    }
    to {
        opacity: 1;
        transform: translateY(0) scale(1);
    }
}

.blog-post-badge.urgent {
    background: linear-gradient(135deg, #94c17d 0%, #35a9a6 100%);
    color: white;
    animation: pulse-glow 2s ease-in-out infinite;
}

.blog-post-badge.featured {
    background: linear-gradient(135deg, #2a97aa 0%, #37ada9 100%);
    color: white;
}

@keyframes pulse-glow {
    0%, 100% {
        box-shadow: 0 0 20px rgba(148, 193, 125, 0.4), 0 8px 32px rgba(0, 0, 0, 0.1);
    }
    50% {
        box-shadow: 0 0 30px rgba(148, 193, 125, 0.6), 0 8px 32px rgba(0, 0, 0, 0.1);
    }
}

.badge-icon {
    width: 16px;
    height: 16px;
}

/* Card Content */
.blog-post-content {
    padding: 30px !important;
    position: relative;
    z-index: 2;
    display: flex;
    flex-direction: column;
    flex-grow: 1;
    box-sizing: border-box;
}

/* Card Meta */
.blog-post-meta {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 18px;
    gap: 15px;
    flex-wrap: wrap;
}

.blog-post-meta span {
    display: flex;
    align-items: center;
    gap: 8px;
}

.post-date {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 0.875em;
    color: #adc6c8;
    font-weight: 500;
}

.post-date svg {
    width: 18px;
    height: 18px;
    opacity: 0.7;
}

.post-author {
    display: flex;
    align-items: center;
    gap: 5px;
    font-size: 0.85em;
    color: #adc6c8;
}

.post-author svg {
    width: 16px;
    height: 16px;
    opacity: 0.6;
}

.post-author a {
    color: #adc6c8;
    text-decoration: none;
    transition: color 0.3s ease;
}

.post-author a:hover {
    color: #2a97aa;
}

/* Category Badge */
.blog-post-category {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 6px 14px;
    background: #e8f5f6;
    border-radius: 8px;
    font-size: 0.8em;
    font-weight: 600;
    color: #2a97aa;
    transition: all 0.3s ease;
}

.blog-post-category svg {
    width: 14px;
    height: 14px;
}

/* CATEGORY HOVER - FIXED */
.blog-post-card:hover .blog-post-category {
    background: #2a97aa !important;
    color: white !important;
    transform: translateY(-2px) !important;
}

/* Card Title */
.blog-post-title {
    font-family: 'Manrope', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
    font-size: 19px;
    font-weight: 600;
    color: #39414d;
    margin: 0 0 15px 0;
    line-height: 1.4;
    transition: color 0.3s ease;
    letter-spacing: -0.5px;
    word-break: break-word;
}

.blog-post-title a {
    color: #39414d;
    text-decoration: none;
    display: block;
    transition: color 0.3s ease;
}

/* TITLE HOVER - FIXED */
.blog-post-card:hover .blog-post-title,
.blog-post-card:hover .blog-post-title a {
    color: #3aa6b9 !important;
}

/* Card Excerpt */
.blog-post-excerpt {
    color: #4a5361;
    margin-bottom: 25px;
    line-height: 1.7;
    font-size: 16px;
    flex-grow: 1;
    word-break: break-word;
}

/* Footer */
.blog-post-footer {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding-top: 20px;
    border-top: 1px solid #9ad8d0;
    gap: 20px;
    margin-top: auto;
}

/* Read More Button - FIXED COLORS AND HOVER */
.blog-post-link {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    color: #2a97aa !important;
    text-decoration: none;
    font-weight: 600;
    font-size: 0.95em;
    transition: all 0.3s cubic-bezier(0.34, 1.56, 0.64, 1);
    position: relative;
    padding: 10px 20px;
    border-radius: 12px;
    background: transparent;
    border: none;
    cursor: pointer;
}

.blog-post-link::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    border-radius: 12px;
    background: linear-gradient(135deg, #2a97aa 0%, #37ada9 100%);
    opacity: 0;
    transition: opacity 0.3s ease;
    z-index: 0;
}

.blog-post-link span {
    position: relative;
    z-index: 1;
}

.blog-post-link svg {
    position: relative;
    z-index: 1;
    transition: transform 0.3s ease;
    width: 20px;
    height: 20px;
}

/* BUTTON HOVER - FIXED */
.blog-post-link:hover {
    color: white !important;
    transform: translateX(5px) !important;
}

.blog-post-link:hover::before {
    opacity: 1 !important;
}

.blog-post-link:hover svg {
    transform: translateX(5px) !important;
}

/* Stats */
.blog-post-stats {
    display: flex;
    gap: 15px;
    align-items: center;
}

.stat-item {
    display: flex;
    align-items: center;
    gap: 5px;
    font-size: 0.85em;
    color: #adc6c8;
}

.stat-item svg {
    width: 16px;
    height: 16px;
    opacity: 0.6;
}

/* Responsive Design */
@media (max-width: 1200px) {
    .elementor-blog-posts-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 30px;
    }

    .elementor-blog-posts-grid.elementor-blog-posts-col-1 {
        grid-template-columns: 1fr;
    }

    .elementor-blog-posts-grid.elementor-blog-posts-col-2 {
        grid-template-columns: repeat(2, 1fr);
    }

    .elementor-blog-posts-grid.elementor-blog-posts-col-3 {
        grid-template-columns: repeat(2, 1fr);
    }

    .elementor-blog-posts-grid.elementor-blog-posts-col-4 {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 900px) {
    .elementor-blog-posts-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 25px;
    }

    .blog-post-image {
        height: 220px;
    }

    .blog-post-content {
        padding: 25px;
    }
}

@media (max-width: 768px) {
    .elementor-blog-posts-grid {
        grid-template-columns: 1fr;
        gap: 25px;
    }

    .elementor-blog-posts-grid.elementor-blog-posts-col-1,
    .elementor-blog-posts-grid.elementor-blog-posts-col-2,
    .elementor-blog-posts-grid.elementor-blog-posts-col-3,
    .elementor-blog-posts-grid.elementor-blog-posts-col-4 {
        grid-template-columns: 1fr;
    }

    .blog-post-image {
        height: 200px;
    }

    .blog-post-title {
        font-size: 1.3em;
    }

    .blog-post-content {
        padding: 25px;
    }

    .blog-post-footer {
        flex-direction: column;
        align-items: flex-start;
        gap: 15px;
    }
}

@media (max-width: 480px) {
    .elementor-blog-posts-grid {
        gap: 20px;
    }

    .blog-post-image {
        height: 220px;
    }

    .blog-post-title {
        font-size: 1.2em;
    }

    .blog-post-content {
        padding: 20px;
    }

    .blog-post-meta {
        font-size: 0.8em;
        gap: 10px;
    }

    .blog-post-excerpt {
        font-size: 0.9em;
    }

    .blog-post-link {
        padding: 8px 16px;
        font-size: 0.85em;
    }
}