.mnep-wrapper {
    width: 100%;
    margin: 0 0 32px 0;
    box-sizing: border-box;
    font-family: inherit;
}

/* Header tipo CorpNews */
.mnep-header {
    margin-bottom: 16px;
    padding-bottom: 6px;
    border-bottom: 1px solid #333333; /* línea gris fina (editable en Elementor) */
    position: relative;
}

.mnep-section-title {
    margin: 0 0 4px 0;
    font-size: 18px;
    font-weight: 700;
    text-transform: uppercase;
    color: #ffffff;
}

/* Barra naranja bajo el header */
.mnep-section-underline {
    position: absolute;
    left: 0;
    bottom: -2px;
    width: 70px;
    height: 3px;
    background-color: var(--e-global-color-primary); /* editable */
}

/* Grid principal: 2 columnas tipo tema, se va llenando en filas */
.mnep-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 18px;
}

/* Tarjeta */
.mnep-item {
    position: relative;
    background-color: #111111;
}

/* Contenedor de imagen + overlay
   Corrección móvil: se reemplaza el alto por padding/absolute por aspect-ratio + flex.
   Así la tarjeta conserva proporción, pero puede crecer si el texto necesita más espacio,
   sin depender de min-height manual en Elementor. */
.mnep-thumb {
    position: relative;
    width: 100%;
    aspect-ratio: 5 / 3;
    display: flex;
    align-items: flex-end;
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
    overflow: hidden;
    isolation: isolate;
}

.mnep-thumb-overlay {
    position: absolute;
    inset: 0;
    background: linear-gradient(to top, rgba(0,0,0,0.9), rgba(0,0,0,0.3));
}

/* Contenido sobre la imagen */
.mnep-item-content {
    position: relative;
    width: 100%;
    padding: 12px 14px;
    z-index: 2;
    color: #ffffff;
    box-sizing: border-box;
}

/* Label categoría */
.mnep-label {
    display: inline-block;
    padding: 3px 8px;
    margin: 0 0 6px 0;
    font-size: 11px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.06em;
    background-color: #e63946;
    color: #ffffff;
    border-radius: 2px;
    text-decoration: none;
}

/* Título del post */
.mnep-title {
    margin: 0 0 6px 0;
    font-size: 17px;
    font-weight: 700;
    line-height: 1.3;
    overflow-wrap: anywhere;
}

.mnep-title a {
    color: inherit;
    text-decoration: none;
}

.mnep-title a:hover {
    text-decoration: underline;
}

/* Meta: autor, fecha, comentarios */
.mnep-meta {
    display: flex;
    flex-wrap: wrap;
    gap: 6px 10px;
    font-size: 12px;
    line-height: 1.35;
    color: #f5f5f5;
}

.mnep-meta-item {
    display: inline-flex;
    align-items: center;
    gap: 4px;
}

.mnep-meta-icon {
    font-size: 13px;
}

/* ===================
   Responsivo
   =================== */

@media (max-width: 1024px) {
    .mnep-section-title {
        font-size: 17px;
    }
    .mnep-title {
        font-size: 16px;
    }
}

@media (max-width: 768px) {
    .mnep-grid {
        grid-template-columns: 1fr; /* En móviles se hace 1 columna */
        gap: 16px;
    }
    .mnep-thumb {
        aspect-ratio: 4 / 3;
    }
    .mnep-title {
        font-size: 15px;
    }
}

@supports not (aspect-ratio: 1 / 1) {
    .mnep-thumb {
        display: block;
        height: auto;
        padding-top: 60%;
    }
    .mnep-item-content {
        position: absolute;
        left: 0;
        right: 0;
        bottom: 0;
    }
}

@media (max-width: 480px) {
    .mnep-section-title {
        font-size: 15px;
    }
    .mnep-title {
        font-size: 14px;
    }
    .mnep-item-content {
        padding: 10px 10px;
    }
}
