/* Quality News Grid Styles */

/* Headers con CSS (sin imágenes PNG) */
.quality-section-header {
    position: relative;
    margin-bottom: 30px;
    height: 50px;
    display: flex;
    align-items: center;
}

.quality-section-header span {
    background: #000;
    color: #fff;
    font-size: 14px;
    font-weight: 900;
    letter-spacing: 1px;
    padding: 4px 25px 4px 12px;
    position: relative;
    z-index: 2;
    text-transform: uppercase;
    font-family: Arial, Helvetica, sans-serif;
}

/* Efecto angular derecho */
.quality-section-header span::after {
    content: '';
    position: absolute;
    right: -12px;
    top: 0;
    width: 0;
    height: 0;
    border-style: solid;
    border-width: 12.5px 0 12.5px 12px;
    border-color: transparent transparent transparent #000;
}

/* Header de Noticias con línea extendida */
.header-noticias::before {
    content: '';
    position: absolute;
    left: 0;
    right: 0;
    bottom: 0;
    height: 2px;
    background: #000;
    z-index: 1;
}

/* Header de Destacadas (sin línea) */
.header-destacadas span {
    font-size: 12px;
    padding: 3px 20px 3px 10px;
}

.header-destacadas span::after {
    border-width: 10.5px 0 10.5px 10px;
}

/* Grid de Noticias */
.quality-news-section {
    margin-bottom: 50px;
}

.quality-news-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    grid-template-rows: auto;
    gap: 20px;
}

/* Noticia grande (primera) - ocupa 2x2 */
.news-item-large {
    grid-column: span 2;
    grid-row: span 2;
}

/* Noticias medianas (2 y 3) - ocupan 1 columna cada una, altura completa */
.news-item-medium {
    grid-column: span 1;
    grid-row: span 1;
}

/* Noticias pequeñas (4, 5, 6) - una columna cada una */
.news-item-small {
    grid-column: span 1;
    grid-row: span 1;
}

/* Estilos de las noticias */
.quality-news-item {
    position: relative;
    overflow: hidden;
    border-radius: 0;
    background: #f5f5f5;
    transition: transform 0.3s ease;
    display: flex;
    flex-direction: column;
}

.quality-news-item:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 30px rgba(0,0,0,0.2);
}

.news-link {
    text-decoration: none;
    color: inherit;
    display: flex;
    flex-direction: column;
    height: 100%;
}

/* Noticia grande mantiene overlay */
.news-item-large .news-link {
    display: block;
    height: 100%;
}

.news-image {
    width: 100%;
    height: 100%;
    background-size: cover;
    background-position: center;
    position: relative;
}

.news-item-large .news-image {
    min-height: 520px;
}

.news-item-medium .news-image {
    height: 250px;
    flex-shrink: 0;
}

.news-item-small .news-image {
    height: 200px;
    flex-shrink: 0;
}

/* Overlay solo para la noticia grande */
.news-item-large .news-overlay {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    height: 60%;
    background: linear-gradient(to top, rgba(0,0,0,0.9) 0%, rgba(0,0,0,0.5) 50%, transparent 100%);
}

/* Contenido sobre imagen solo para noticia grande */
.news-item-large .news-content {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    padding: 20px;
    color: #fff;
    z-index: 2;
}

/* Contenido debajo de imagen para medianas y pequeñas */
.news-item-medium .news-content,
.news-item-small .news-content {
    padding: 15px;
    background: #fff;
    flex-grow: 1;
}

.news-title {
    font-size: 18px;
    font-weight: 700;
    margin: 0 0 10px 0;
    line-height: 1.3;
    text-transform: uppercase;
}

.news-item-large .news-title {
    font-size: 28px;
    margin-bottom: 15px;
    color: #fff;
}

.news-item-medium .news-title {
    font-size: 16px;
    color: #000;
}

.news-item-small .news-title {
    font-size: 15px;
    color: #000;
}

.news-excerpt {
    font-size: 14px;
    line-height: 1.5;
    margin: 0;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.news-item-large .news-excerpt {
    font-size: 16px;
    -webkit-line-clamp: 3;
    color: #fff;
}

.news-item-medium .news-excerpt {
    color: #666;
}

.news-item-small .news-excerpt {
    display: none;
}

/* Destacadas Sidebar */
.quality-destacadas-section {
    background: transparent;
}

.quality-destacadas-list {
    display: flex;
    flex-direction: column;
    gap: 15px;
}

.destacada-item {
    transition: transform 0.3s ease;
}

.destacada-item:hover {
    transform: translateY(-3px);
}

.destacada-link {
    display: flex;
    flex-direction: column;
    text-decoration: none;
    color: inherit;
}

.destacada-image {
    width: 100%;
    height: 150px;
    overflow: hidden;
    margin-bottom: 10px;
}

.destacada-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.destacada-content {
    padding: 0;
}

.destacada-title {
    font-size: 14px;
    font-weight: 700;
    margin: 0;
    line-height: 1.4;
    color: #000;
    text-transform: uppercase;
    display: -webkit-box;
    -webkit-line-clamp: 3;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.destacada-item:hover .destacada-title {
    color: #e74c3c;
}

/* Responsive */
@media (max-width: 992px) {
    .quality-news-grid {
        grid-template-columns: repeat(2, 1fr);
    }
    
    .news-item-large {
        grid-column: span 2;
        grid-row: span 1;
    }
    
    .news-item-medium {
        grid-column: span 1;
    }
    
    .news-item-small {
        grid-column: span 1;
    }
    
    .quality-section-header span {
        font-size: 24px;
    }
}

@media (max-width: 768px) {
    .quality-news-grid {
        grid-template-columns: 1fr;
        gap: 15px;
    }
    
    .news-item-large,
    .news-item-medium,
    .news-item-small {
        grid-column: span 1;
        grid-row: span 1;
    }
    
    .news-image,
    .news-item-large .news-image,
    .news-item-medium .news-image,
    .news-item-small .news-image {
        min-height: 250px;
    }
    
    .news-title,
    .news-item-large .news-title,
    .news-item-medium .news-title {
        font-size: 18px;
    }
    
    .news-excerpt {
        display: -webkit-box !important;
        -webkit-line-clamp: 2;
    }
    
    .quality-section-header span {
        font-size: 20px;
        padding: 6px 30px 6px 15px;
    }
    
    .quality-section-header span::after {
        border-width: 19px 0 19px 15px;
    }
    
    .destacada-image {
        width: 70px;
        height: 70px;
    }
    
    .destacada-title {
        font-size: 13px;
    }
}

@media (max-width: 480px) {
    .quality-section-header {
        margin-bottom: 20px;
    }
    
    .quality-news-grid {
        gap: 10px;
    }
    
    .news-content {
        padding: 15px;
    }
    
    .destacada-link {
        gap: 10px;
    }
}
