/* Contoh Media Query untuk layar dengan lebar maksimum 768px (layar kecil) */
@media (max-width: 768px) {
    .row-cols-md-3 {
        grid-template-columns: repeat(1, 1fr); /* Membuat hanya satu kolom pada layar kecil */
    }
    /* Gaya lain untuk layar kecil di sini */
}

/* Contoh Media Query untuk layar dengan lebar minimum 992px (layar besar) */
@media (min-width: 992px) {
    /* Gaya khusus untuk layar besar di sini */
}

body, html {
    margin-bottom: 0;
    padding-bottom: 0; /* Tambahkan ini juga untuk memastikan */
    background-color: azure;
}

/* Bungkus setiap card dalam div ini untuk card-wrapper*/ 
/* Di dalam file CSS Anda (misalnya artikel.css) */

.card {
    /* Anda mungkin perlu mengatur lebar maksimum agar kartu tidak terlalu lebar */
    /* max-width: 400px; */
    margin-left: auto;
    margin-right: auto;
}

/* Enhanced Article Section Styles */

/* Background Elements */
.article-bg-wrapper {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    overflow: hidden;
    z-index: -1;
}

.article-bg-pattern {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(135deg, #f8f9fa 0%, #e9ecef 100%);
    opacity: 0.5;
}

.article-bg-pattern::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-image: 
        radial-gradient(circle at 20% 20%, rgba(74, 144, 226, 0.1) 0%, transparent 50%),
        radial-gradient(circle at 80% 80%, rgba(16, 185, 129, 0.1) 0%, transparent 50%),
        radial-gradient(circle at 40% 60%, rgba(245, 101, 101, 0.1) 0%, transparent 50%);
}

.article-floating-elements {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
}

.floating-icon {
    position: absolute;
    color: rgba(74, 144, 226, 0.1);
    font-size: 3rem;
    animation: float 6s ease-in-out infinite;
}

.floating-icon.icon-1 {
    top: 10%;
    left: 10%;
    animation-delay: 0s;
}

.floating-icon.icon-2 {
    top: 20%;
    right: 15%;
    animation-delay: 2s;
}

.floating-icon.icon-3 {
    bottom: 15%;
    left: 20%;
    animation-delay: 4s;
}

@keyframes float {
    0%, 100% { transform: translateY(0px); }
    50% { transform: translateY(-20px); }
}

/* Section Styling */
#article {
    padding: 80px 0;
    background: #ffffff;
    position: relative;
    overflow: hidden;
}

/* Header Styling */
.article-header {
    margin-bottom: 4rem;
}

.article-badge {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    background: rgba(0, 186, 255, 0.1);
    border: 1px solid rgba(0, 186, 255, 0.2);
    border-radius: 50px;
    padding: 0.6rem 1.8rem;
    margin-bottom: 1.5rem;
    font-size: 0.9rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    color: #0066cc;
    backdrop-filter: blur(10px);
}

.article-badge i {
    color: #00baff;
    font-size: 1rem;
}

.article-main-title {
    font-size: 2.5rem;
    font-weight: 700;
    color: #1a202c;
    margin-bottom: 1rem;
    background: linear-gradient(135deg, #1a202c 0%, #2d3748 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.article-subtitle {
    font-size: 1.1rem;
    color: #64748b;
    max-width: 600px;
    margin: 0 auto;
    line-height: 1.6;
}

/* Home Page Articles Grid - Consistent 3-column layout */
.articles-grid-home {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 2rem;
    margin-bottom: 3rem;
}

/* Home Page Article Card - Enhanced modern design */
.article-card-home {
    background: white;
    border-radius: 24px;
    overflow: hidden;
    box-shadow: 
        0 4px 6px -1px rgba(0, 0, 0, 0.1),
        0 2px 4px -1px rgba(0, 0, 0, 0.06);
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    position: relative;
    height: 450px; /* Fixed height for perfect consistency */
    display: flex;
    flex-direction: column;
    border: 1px solid rgba(226, 232, 240, 0.8);
}

.article-card-home::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(135deg, rgba(74, 144, 226, 0.02) 0%, rgba(16, 185, 129, 0.02) 100%);
    opacity: 0;
    transition: opacity 0.3s ease;
    pointer-events: none;
    z-index: 1;
}

.article-card-home:hover::before {
    opacity: 1;
}

.article-card-home:hover {
    transform: translateY(-8px) scale(1.02);
    box-shadow: 
        0 25px 50px -12px rgba(0, 0, 0, 0.15),
        0 0 0 1px rgba(74, 144, 226, 0.1);
    border-color: rgba(74, 144, 226, 0.2);
}

.article-card-inner-home {
    height: 100%;
    display: flex;
    flex-direction: column;
    position: relative;
    z-index: 1;
}

.article-card-inner-home::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(
        45deg,
        transparent 0%,
        rgba(255, 255, 255, 0.1) 50%,
        transparent 100%
    );
    opacity: 0;
    transition: opacity 0.6s ease;
    pointer-events: none;
    z-index: 10;
}

.article-card-home:hover .article-card-inner-home::after {
    opacity: 1;
    animation: shimmer 1.5s ease-in-out;
}

@keyframes shimmer {
    0% {
        transform: translateX(-100%);
    }
    100% {
        transform: translateX(100%);
    }
}

/* Home Page Image Wrapper - Enhanced with gradient overlay */
.article-image-wrapper-home {
    position: relative;
    height: 180px; /* Fixed height */
    overflow: hidden;
    flex-shrink: 0;
}

.article-image-wrapper-home::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(
        to bottom,
        rgba(0, 0, 0, 0) 0%,
        rgba(0, 0, 0, 0.1) 100%
    );
    opacity: 0;
    transition: opacity 0.3s ease;
    z-index: 2;
}

.article-card-home:hover .article-image-wrapper-home::after {
    opacity: 1;
}

.article-image-home {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.5s cubic-bezier(0.4, 0, 0.2, 1);
    filter: brightness(1) contrast(1.05) saturate(1.1);
}

.article-card-home:hover .article-image-home {
    transform: scale(1.08);
    filter: brightness(1.1) contrast(1.1) saturate(1.2);
}

.article-overlay-home {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(135deg, rgba(74, 144, 226, 0.9) 0%, rgba(16, 185, 129, 0.9) 100%);
    opacity: 0;
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 3;
    backdrop-filter: blur(2px);
}

.article-card-home:hover .article-overlay-home {
    opacity: 1;
}

.article-category-home {
    background: rgba(255, 255, 255, 0.95);
    color: #4a90e2;
    padding: 0.75rem 1.5rem;
    border-radius: 30px;
    font-weight: 700;
    font-size: 0.85rem;
    display: flex;
    align-items: center;
    gap: 0.5rem;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.15);
    backdrop-filter: blur(10px);
    border: 1px solid rgba(74, 144, 226, 0.2);
    transform: translateY(10px);
    transition: all 0.3s ease;
}

.article-card-home:hover .article-category-home {
    transform: translateY(0);
}

/* Home Page Content - Enhanced structured layout */
.article-content-home {
    padding: 1.75rem;
    flex: 1;
    display: flex;
    flex-direction: column;
    min-height: 0; /* Important for flexbox */
    position: relative;
    z-index: 2;
}

.article-meta-home {
    display: flex;
    align-items: center;
    gap: 1rem;
    margin-bottom: 1.25rem;
    font-size: 0.8rem;
    color: #64748b;
    flex-shrink: 0;
}

.article-date-home {
    display: flex;
    align-items: center;
    gap: 0.4rem;
    background: rgba(74, 144, 226, 0.08);
    padding: 0.4rem 0.8rem;
    border-radius: 16px;
    font-weight: 600;
    color: #4a90e2;
    transition: all 0.3s ease;
}

.article-card-home:hover .article-date-home {
    background: rgba(74, 144, 226, 0.12);
    transform: translateY(-1px);
}

.article-date-home i {
    font-size: 0.75rem;
}

.article-title-home {
    font-size: 1.15rem;
    font-weight: 800;
    color: #1a202c;
    margin-bottom: 1rem;
    line-height: 1.4;
    height: 2.8rem; /* Fixed height for exactly 2 lines */
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
    flex-shrink: 0;
    position: relative;
}

.article-title-home a {
    color: inherit;
    text-decoration: none;
    transition: all 0.3s ease;
    display: block;
    height: 100%;
    position: relative;
    background: linear-gradient(135deg, #1a202c 0%, #2d3748 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.article-title-home a:hover {
    background: linear-gradient(135deg, #4a90e2 0%, #357abd 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    transform: translateY(-1px);
}

.article-excerpt-home {
    color: #64748b;
    line-height: 1.6;
    margin-bottom: 1.75rem;
    flex: 1;
    height: 4.8rem; /* Fixed height for exactly 3 lines */
    display: -webkit-box;
    -webkit-line-clamp: 3;
    -webkit-box-orient: vertical;
    overflow: hidden;
    font-size: 0.9rem;
    font-weight: 400;
    position: relative;
}

.article-excerpt-home::after {
    content: '';
    position: absolute;
    bottom: 0;
    right: 0;
    width: 30px;
    height: 1.2rem;
    background: linear-gradient(to right, transparent, white);
    pointer-events: none;
}

/* Home Page Footer - Enhanced CTA button */
.article-footer-home {
    margin-top: auto;
    flex-shrink: 0;
    position: relative;
    text-align: center;
    display: flex;
    justify-content: center;
}

.article-read-more-home {
    display: inline-flex;
    align-items: center;
    gap: 0.6rem;
    color: #4a90e2;
    text-decoration: none;
    font-weight: 700;
    font-size: 0.85rem;
    padding: 0.75rem 1.5rem;
    background: linear-gradient(135deg, rgba(74, 144, 226, 0.08) 0%, rgba(16, 185, 129, 0.08) 100%);
    border-radius: 25px;
    border: 1px solid rgba(74, 144, 226, 0.2);
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    position: relative;
    overflow: hidden;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.article-read-more-home::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(135deg, rgba(74, 144, 226, 0.1) 0%, rgba(16, 185, 129, 0.1) 100%);
    transition: left 0.5s ease;
}

.article-read-more-home:hover::before {
    left: 0;
}

.article-read-more-home:hover {
    color: #357abd;
    gap: 0.9rem;
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(74, 144, 226, 0.2);
    border-color: rgba(74, 144, 226, 0.3);
}

.article-read-more-home span {
    position: relative;
    z-index: 1;
}

.article-read-more-home i {
    transition: transform 0.3s ease;
    position: relative;
    z-index: 1;
    font-size: 0.8rem;
}

.article-read-more-home:hover i {
    transform: translateX(4px);
}

/* Home Page No Articles State */
.no-articles-home {
    grid-column: 1 / -1;
    text-align: center;
    padding: 3rem;
    color: #64748b;
}

.no-articles-icon-home {
    font-size: 4rem;
    color: #cbd5e0;
    margin-bottom: 1rem;
}

.no-articles-home h3 {
    font-size: 1.5rem;
    font-weight: 600;
    color: #4a5568;
    margin-bottom: 0.5rem;
}

.no-articles-home p {
    font-size: 1rem;
    color: #64748b;
}

/* Articles Grid - Original for other pages */
.articles-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
    gap: 2rem;
    margin-bottom: 3rem;
}

/* Article Card - Original for other pages */
.article-card {
    background: white;
    border-radius: 20px;
    overflow: hidden;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.1);
    transition: all 0.3s ease;
    position: relative;
    height: 480px; /* Fixed height for consistency */
    display: flex;
    flex-direction: column;
}

.article-card:hover {
    transform: translateY(-10px);
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.15);
}

.article-card-inner {
    height: 100%;
    display: flex;
    flex-direction: column;
}

/* Image Wrapper */
.article-image-wrapper {
    position: relative;
    height: 200px;
    overflow: hidden;
}

.article-image {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.3s ease;
}

.article-card:hover .article-image {
    transform: scale(1.05);
}

.article-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(135deg, rgba(74, 144, 226, 0.8) 0%, rgba(16, 185, 129, 0.8) 100%);
    opacity: 0;
    transition: opacity 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
}

.article-card:hover .article-overlay {
    opacity: 1;
}

.article-category {
    background: white;
    color: #4a90e2;
    padding: 0.5rem 1rem;
    border-radius: 25px;
    font-weight: 600;
    font-size: 0.9rem;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

/* Content */
.article-content {
    padding: 1.5rem;
    flex: 1;
    display: flex;
    flex-direction: column;
}

.article-meta {
    display: flex;
    align-items: center;
    gap: 1rem;
    margin-bottom: 1rem;
    font-size: 0.85rem;
    color: #64748b;
}

.article-date,
.article-read-time {
    display: flex;
    align-items: center;
    gap: 0.3rem;
}

.article-title {
    font-size: 1.25rem;
    font-weight: 700;
    color: #1a202c;
    margin-bottom: 0.75rem;
    line-height: 1.4;
    height: 3.5rem; /* Fixed height for 2-3 lines */
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.article-title a {
    color: inherit;
    text-decoration: none;
    transition: color 0.3s ease;
    display: block;
    height: 100%;
}

.article-title a:hover {
    color: #4a90e2;
}

.article-excerpt {
    color: #64748b;
    line-height: 1.6;
    margin-bottom: 1.5rem;
    flex: 1;
    height: 4.8rem; /* Fixed height for 3 lines */
    display: -webkit-box;
    -webkit-line-clamp: 3;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

/* Footer */
.article-footer {
    margin-top: auto;
}

.article-read-more {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    color: #4a90e2;
    text-decoration: none;
    font-weight: 600;
    transition: all 0.3s ease;
}

.article-read-more:hover {
    color: #357abd;
    gap: 0.75rem;
}

.article-read-more i {
    transition: transform 0.3s ease;
}

.article-read-more:hover i {
    transform: translateX(5px);
}

/* No Articles State */
.no-articles {
    grid-column: 1 / -1;
    text-align: center;
    padding: 3rem;
    color: #64748b;
}

.no-articles-icon {
    font-size: 4rem;
    color: #cbd5e0;
    margin-bottom: 1rem;
}

.no-articles h3 {
    font-size: 1.5rem;
    font-weight: 600;
    color: #4a5568;
    margin-bottom: 0.5rem;
}

.no-articles p {
    font-size: 1rem;
    color: #64748b;
}

/* Call to Action */
.article-cta {
    padding: 2rem 0;
}

.cta-content {
    max-width: 600px;
    margin: 0 auto;
}

.cta-title {
    font-size: 1.75rem;
    font-weight: 700;
    color: #1a202c;
    margin-bottom: 0.5rem;
}

.cta-subtitle {
    color: #64748b;
    margin-bottom: 2rem;
    line-height: 1.6;
}

.cta-button {
    display: inline-flex;
    align-items: center;
    gap: 0.75rem;
    background: linear-gradient(135deg, #4a90e2 0%, #357abd 100%);
    color: white;
    padding: 1rem 2rem;
    border-radius: 50px;
    text-decoration: none;
    font-weight: 600;
    transition: all 0.3s ease;
    box-shadow: 0 4px 15px rgba(74, 144, 226, 0.3);
}

.cta-button:hover {
    color: white;
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(74, 144, 226, 0.4);
    gap: 1rem;
}

.cta-button i {
    transition: transform 0.3s ease;
}

.cta-button:hover i {
    transform: translateX(5px);
}

/* Loading skeleton animation */
@keyframes skeleton-loading {
    0% {
        background-position: -200px 0;
    }
    100% {
        background-position: calc(200px + 100%) 0;
    }
}

.article-card-home.loading {
    background: linear-gradient(90deg, #f0f0f0 25%, #e0e0e0 50%, #f0f0f0 75%);
    background-size: 200px 100%;
    animation: skeleton-loading 1.5s infinite;
}

/* Responsive Design for Home Page Articles */
@media (max-width: 1200px) {
    .articles-grid-home {
        grid-template-columns: repeat(3, 1fr);
        gap: 1.5rem;
    }
    
    .article-card-home {
        height: 420px;
    }
    
    .article-image-wrapper-home {
        height: 160px;
    }
    
    .article-content-home {
        padding: 1.5rem;
    }
    
    .article-title-home {
        font-size: 1rem;
        height: 2.4rem;
    }
    
    .article-excerpt-home {
        height: 4.2rem;
        font-size: 0.85rem;
    }
    
    .article-read-more-home {
        padding: 0.6rem 1.2rem;
        font-size: 0.8rem;
    }
}

@media (max-width: 992px) {
    .articles-grid-home {
        grid-template-columns: repeat(2, 1fr);
        gap: 1.5rem;
    }
    
    .article-card-home {
        height: 440px;
    }
    
    .article-image-wrapper-home {
        height: 170px;
    }
}

@media (max-width: 768px) {
    #article {
        padding: 60px 0;
    }
    
    .article-main-title {
        font-size: 2rem;
    }
    
    .article-subtitle {
        font-size: 1rem;
    }
    
    .articles-grid-home {
        grid-template-columns: 1fr;
        gap: 1.5rem;
    }
    
    .article-card-home {
        height: 400px;
    }
    
    .article-image-wrapper-home {
        height: 180px;
    }
    
    .article-content-home {
        padding: 1.25rem;
    }
    
    .article-meta-home {
        flex-direction: column;
        align-items: flex-start;
        gap: 0.5rem;
    }
    
    .article-title-home {
        font-size: 1.1rem;
        height: 2.6rem;
    }
    
    .article-excerpt-home {
        height: 4.5rem;
        font-size: 0.9rem;
    }
    
    .cta-title {
        font-size: 1.5rem;
    }
    
    .cta-button {
        padding: 0.875rem 1.5rem;
    }
}

@media (max-width: 480px) {
    .article-header {
        margin-bottom: 2rem;
    }
    
    .article-badge {
        padding: 0.5rem 1rem;
        font-size: 0.8rem;
    }
    
    .article-main-title {
        font-size: 1.75rem;
    }
    
    .articles-grid-home {
        grid-template-columns: 1fr;
        gap: 1rem;
    }
    
    .article-card-home {
        height: 380px;
    }
    
    .article-image-wrapper-home {
        height: 160px;
    }
    
    .article-content-home {
        padding: 1rem;
    }
    
    .article-title-home {
        font-size: 1rem;
        height: 2.4rem;
    }
    
    .article-excerpt-home {
        height: 4.2rem;
        font-size: 0.85rem;
    }
}

/* Responsive Design for Original Articles */
@media (max-width: 768px) {
    .articles-grid {
        grid-template-columns: 1fr;
        gap: 1.5rem;
    }
    
    .article-card {
        height: 450px; /* Adjusted height for mobile */
    }
    
    .article-content {
        padding: 1.25rem;
    }
    
    .article-meta {
        flex-direction: column;
        align-items: flex-start;
        gap: 0.5rem;
    }
    
    .article-title {
        font-size: 1.1rem;
        height: 3.3rem; /* Adjusted for mobile */
    }
    
    .article-excerpt {
        height: 4.5rem; /* Adjusted for mobile */
    }
}

@media (max-width: 480px) {
    .articles-grid {
        grid-template-columns: 1fr;
        gap: 1rem;
    }
    
    .article-card {
        height: 420px; /* Adjusted for small mobile */
    }
    
    .article-image-wrapper {
        height: 180px;
    }
    
    .article-content {
        padding: 1rem;
    }
    
    .article-title {
        font-size: 1rem;
        height: 3rem; /* Adjusted for small mobile */
    }
    
    .article-excerpt {
        height: 4.2rem; /* Adjusted for small mobile */
        font-size: 0.9rem;
    }
}

/* Animation for AOS (Animate On Scroll) */
[data-aos="fade-up"] {
    transform: translateY(50px);
    opacity: 0;
    transition: transform 0.6s ease, opacity 0.6s ease;
}

[data-aos="fade-up"].aos-animate {
    transform: translateY(0);
    opacity: 1;
}

/* Legacy support for existing styles */
body, html {
    margin-bottom: 0;
    padding-bottom: 0;
    background-color: azure;
}

.card {
    margin-left: auto;
    margin-right: auto;
}

