/* ========================================
   MODULO ULTIMI ARTICOLI BLOG
   Breakpoint: 1024px, 768px, 767px
======================================== */

/* Reset e base */
.latest-posts-section {
    width: 100%;
    padding: 60px 0;
}

.latest-posts-container {
    width: 100%;
    max-width: 1600px;
    margin: 0 auto;
}

/* Titolo sezione */
.latest-posts-title {
    font-size: 1.5rem;
    font-weight: 400;
    margin-bottom: 50px;
    text-align: center;
    color: #1a1a1a;
}

/* Griglia articoli - 4 colonne */
.latest-posts-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 30px;
}

/* Card singolo articolo */
.post-card {
    background: #ffffff;
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.08);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.post-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.12);
}

.post-card-link {
    display: block;
    text-decoration: none;
    color: inherit;
}

/* Immagine in evidenza */
.post-card-image {
    position: relative;
    width: 100%;
    aspect-ratio: 16 / 10;
    overflow: hidden;
    background-color: #f0f0f0;
}

.post-card-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.3s ease;
}

.post-card:hover .post-card-image img {
    transform: scale(1.05);
}

.post-card-no-image {
    width: 100%;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    background-color: #e0e0e0;
    color: #888;
    font-size: 0.875rem;
}

/* Contenuto card */
.post-card-content {
    padding: 20px;
}

/* Data articolo */
.post-card-date {
    display: block;
    font-size: 0.8125rem;
    color: #666;
    margin-bottom: 10px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

/* Titolo articolo */
.post-card-title {
    font-size: 1.125rem;
    font-weight: 600;
    line-height: 1.4;
    margin: 0 0 12px 0;
    color: #1a1a1a;
    transition: color 0.3s ease;
}

.post-card:hover .post-card-title {
    color: #0066cc;
}

/* Excerpt */
.post-card-excerpt {
    font-size: 0.9375rem;
    line-height: 1.6;
    color: #555;
    margin: 0;
}

/* Messaggio nessun articolo */
.no-posts-message {
    text-align: center;
    font-size: 1rem;
    color: #666;
    padding: 40px 0;
}


/* ========================================
   RESPONSIVE - Breakpoint 1024px
   Container: 1000px
======================================== */
@media screen and (max-width: 1024px) {
    .latest-posts-container {
        max-width: 1000px;
    }
    
    .latest-posts-grid {
        grid-template-columns: repeat(4, 1fr);
        gap: 24px;
    }
    
    .post-card-content {
        padding: 16px;
    }
    
    .post-card-title {
        font-size: 1rem;
    }
    
    .post-card-excerpt {
        font-size: 0.875rem;
    }
}


/* ========================================
   RESPONSIVE - Breakpoint 768px
   Container: 700px
======================================== */
@media screen and (max-width: 768px) {
    .latest-posts-section {
        padding: 50px 0;
    }
    
    .latest-posts-container {
        max-width: 700px;
    }
    
    .latest-posts-title {
        font-size: 2rem;
        margin-bottom: 30px;
    }
    
    .latest-posts-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 20px;
    }
    
    .post-card-content {
        padding: 16px;
    }
    
    .post-card-date {
        font-size: 0.75rem;
        margin-bottom: 8px;
    }
    
    .post-card-title {
        font-size: 1rem;
        margin-bottom: 10px;
    }
    
    .post-card-excerpt {
        font-size: 0.875rem;
    }
}


/* ========================================
   RESPONSIVE - Breakpoint 767px (mobile)
   Container: 90%
======================================== */
@media screen and (max-width: 767px) {
    .latest-posts-section {
        padding: 40px 0;
    }
    
    .latest-posts-container {
        width: 90%;
        max-width: none;
    }
    
    .latest-posts-title {
        font-size: 1.75rem;
        margin-bottom: 25px;
    }
    
    .latest-posts-grid {
        grid-template-columns: 1fr;
        gap: 20px;
    }
    
    .post-card {
        border-radius: 10px;
    }
    
    .post-card-image {
        aspect-ratio: 16 / 9;
    }
    
    .post-card-content {
        padding: 18px;
    }
    
    .post-card-date {
        font-size: 0.75rem;
        margin-bottom: 8px;
    }
    
    .post-card-title {
        font-size: 1.0625rem;
        margin-bottom: 10px;
    }
    
    .post-card-excerpt {
        font-size: 0.875rem;
        line-height: 1.5;
    }
}
