/**
 * SBB News & Articles Styles
 */

/* Reset untuk section agar tidak terpengaruh styling tema */
.content-area .sbb-news-articles-section,
.sbb-news-articles-section {
    padding: 100px 30px 80px !important;
    background: transparent !important;
    position: relative;
    margin: -150px 0 0 0 !important;
    width: 100% !important;
    max-width: 100vw;
    box-sizing: border-box;
    clear: both;
    z-index: auto !important;
    isolation: isolate;
    overflow-x: hidden;
}

.sbb-news-articles-section::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: #ffffff;
    z-index: -2 !important;
    pointer-events: none;
}

/* Reset untuk semua elemen di dalam section */
.sbb-news-articles-section * {
    box-sizing: border-box;
}

/* Override styling dari content-area jika ada */
.content-area .sbb-news-articles-section .sbb-news-header,
.content-area .sbb-news-articles-section .sbb-news-grid,
.content-area .sbb-news-articles-section .sbb-news-footer {
    padding-left: 0 !important;
    padding-right: 0 !important;
}

/* Reset untuk article card */
.sbb-news-articles-section article,
.sbb-news-card {
    margin: 0 !important;
    padding: 0 !important;
}

.sbb-news-header {
    max-width: 1440px;
    margin: 0 auto 60px;
    text-align: center !important;
    padding: 0 30px;
    position: relative;
    z-index: 1000 !important;
}

@media (max-width: 768px) {
    .sbb-news-header {
        padding: 0 20px;
    }
}

.sbb-news-subtitle {
    display: block !important;
    font-size: 13px !important;
    font-weight: 400 !important;
    color: #666666 !important;
    letter-spacing: 0.3px !important;
    margin-bottom: 12px !important;
    text-transform: none !important;
    text-align: center !important;
    font-family: 'SIGText', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif !important;
}

.sbb-news-title {
    font-family: 'SIG Headline', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif !important;
    font-weight: 700 !important;
    font-style: bold !important;
    font-size: 40px !important;
    line-height: 50px !important;
    letter-spacing: 0% !important;
    text-align: center !important;
    margin: 0 !important;
    color: #011322 !important;
}

.sbb-news-grid {
    max-width: 1440px !important;
    margin: 0 auto 50px !important;
    display: grid !important;
    grid-template-columns: repeat(3, 1fr) !important;
    gap: 32px !important;
    padding: 0 30px !important;
    width: 100%;
    box-sizing: border-box;
    position: relative;
    z-index: 1000 !important;
}

.sbb-news-card {
    background: #ffffff !important;
    border-radius: 0 !important;
    box-shadow: none !important;
    overflow: hidden;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    display: flex !important;
    flex-direction: column;
    height: 100%;
    min-height: 500px;
    margin: 0;
    padding: 0;
}

.sbb-news-card:hover {
    transform: translateY(0);
    box-shadow: 4px 4px 20px 0px rgba(0, 0, 0, 0.25) !important;
}

.sbb-news-image-wrapper {
    position: relative;
    width: 100% !important;
    height: 300px !important;
    overflow: hidden;
    background: #f5f5f5;
    flex-shrink: 0;
    margin: 0;
    padding: 0;
    border-radius: 0;
}

.sbb-news-image-link {
    display: block;
    width: 100%;
    height: 100%;
    text-decoration: none;
}

.sbb-news-image {
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: center;
    transition: transform 0.5s cubic-bezier(0.4, 0, 0.2, 1);
    display: block;
}

.sbb-news-card:hover .sbb-news-image {
    transform: scale(1.05);
}

.sbb-news-placeholder {
    width: 100%;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    background: #f0f0f0;
}

.sbb-news-badge {
    position: absolute;
    bottom: 0;
    left: 0;
    width: 128px;
    height: 58px;
    background: #777654;
    color: #ffffff;
    padding: 0;
    border-radius: 0;
    font-size: 11px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.8px;
    z-index: 2;
    backdrop-filter: blur(4px);
    -webkit-backdrop-filter: blur(4px);
    line-height: 58px;
    text-align: center;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.15);
    clip-path: polygon(0 0, calc(100% - 14px) 0, 100% 14px, 100% 100%, 0 100%);
    -webkit-clip-path: polygon(0 0, calc(100% - 14px) 0, 100% 14px, 100% 100%, 0 100%);
    display: flex;
    align-items: center;
    justify-content: center;
}

.sbb-news-content {
    padding: 24px 28px 28px !important;
    flex: 1;
    display: flex !important;
    flex-direction: column;
    margin: 0;
    width: 100%;
}

.sbb-news-date {
    display: block !important;
    font-size: 13px !important;
    color: #999999 !important;
    margin-bottom: 12px !important;
    font-weight: 400 !important;
    line-height: 1.6 !important;
    font-family: 'SIGText', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif !important;
}

.sbb-news-card-title {
    margin: 0 0 14px !important;
    font-size: 19px !important;
    font-weight: 700 !important;
    line-height: 1.45 !important;
    color: #2c2c2c !important;
    font-family: 'SIGText', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif !important;
}

.sbb-news-card-title a {
    color: inherit !important;
    text-decoration: none !important;
    transition: color 0.3s ease;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
    font-size: inherit !important;
    font-weight: inherit !important;
    line-height: inherit !important;
}

.sbb-news-card-title a:hover {
    color: #65644a;
}

.sbb-news-excerpt {
    font-size: 14px !important;
    line-height: 1.75 !important;
    color: #666666 !important;
    flex: 1;
    display: -webkit-box;
    -webkit-line-clamp: 5;
    -webkit-box-orient: vertical;
    overflow: hidden;
    font-family: 'SIGText', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif !important;
    margin: 0 !important;
    padding: 0 !important;
}

.sbb-news-excerpt p {
    margin: 0 !important;
    padding: 0 !important;
}

.sbb-news-footer {
    max-width: 1440px;
    margin: 0 auto;
    text-align: center;
    padding: 0 30px;
    position: relative;
    z-index: 1000 !important;
}

.sbb-news-view-all {
    display: inline-block;
    color: #8B4513;
    font-size: 16px;
    font-weight: 600;
    text-decoration: none;
    transition: color 0.3s ease;
    padding: 10px 0;
    font-family: 'SIGText', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
}

.sbb-news-view-all:hover {
    color: #A0522D;
    text-decoration: underline;
}

.sbb-news-no-posts {
    text-align: center;
    color: #999999;
    padding: 40px 20px;
    max-width: 1440px;
    margin: 0 auto;
}

/* Responsive - Tablet */
@media (max-width: 1024px) {
    .sbb-news-grid {
        grid-template-columns: repeat(2, 1fr) !important;
        gap: 25px;
        padding: 0 20px;
    }
    
    .sbb-news-card {
        min-height: auto;
    }
}

/* Responsive - Mobile */
@media (max-width: 768px) {
    .sbb-news-articles-section {
        padding: 50px 16px 40px !important;
        margin-top: -80px !important;
    }
    
    .sbb-news-header {
        margin-bottom: 32px;
        padding: 0 16px;
    }
    
    .sbb-news-subtitle {
        font-size: 12px !important;
        margin-bottom: 8px !important;
    }
    
    .sbb-news-title {
        font-size: 15px !important;
        line-height: 1.5 !important;
    }
    
    .sbb-news-grid {
        grid-template-columns: 1fr !important;
        gap: 24px;
        padding: 0 16px;
        margin-bottom: 40px !important;
    }
    
    .sbb-news-card {
        min-height: auto;
        max-width: 100%;
    }
    
    .sbb-news-image-wrapper {
        height: 200px;
    }
    
    .sbb-news-content {
        padding: 18px 16px 20px !important;
    }
    
    .sbb-news-card-title {
        font-size: 17px !important;
        margin-bottom: 10px !important;
    }
    
    .sbb-news-card-title a {
        -webkit-line-clamp: 3;
    }
    
    .sbb-news-excerpt {
        font-size: 13px !important;
        -webkit-line-clamp: 4;
    }
    
    .sbb-news-badge {
        width: 110px;
        height: 48px;
        font-size: 10px;
        line-height: 48px;
    }
    
    .sbb-news-footer {
        padding: 0 16px;
    }
    
    .sbb-news-view-all {
        font-size: 15px;
        padding: 12px 0;
        min-height: 44px;
        display: inline-flex;
        align-items: center;
        justify-content: center;
    }
}

/* Responsive - Small mobile (landscape & narrow) */
@media (max-width: 480px) {
    .sbb-news-articles-section {
        padding: 40px 12px 32px !important;
        margin-top: -60px !important;
    }
    
    .sbb-news-header {
        padding: 0 12px;
        margin-bottom: 24px;
    }
    
    .sbb-news-title {
        font-size: 14px !important;
    }
    
    .sbb-news-grid {
        padding: 0 12px !important;
        gap: 20px;
        margin-bottom: 32px !important;
    }
    
    .sbb-news-image-wrapper {
        height: 180px;
    }
    
    .sbb-news-content {
        padding: 14px 12px 16px !important;
    }
    
    .sbb-news-card-title {
        font-size: 16px !important;
    }
    
    .sbb-news-date {
        font-size: 12px !important;
    }
    
    .sbb-news-excerpt {
        font-size: 12px !important;
        -webkit-line-clamp: 3;
    }
    
    .sbb-news-badge {
        width: 100px;
        height: 44px;
        font-size: 9px;
        line-height: 44px;
    }
}

