/*
 * ARCHIVO RELATED: Bloque "Lo que dice el archivo"
 * Estilos para chips de noticias relacionadas manuales
 * Reutiliza tipografía y estructura de related-inline.css
 */

/* Soporte para ambos prefijos: informe- y sde- */
.informe-archivo-related,
.sde-archivo-related {
    margin: 3.75rem 0;                     /* 60px - más margen superior/inferior */
    padding: 2.5rem 0;                     /* 40px - padding interno */
    border-top: .0625rem solid #e2e2e2;   /* 1px - separador suave superior */
    border-bottom: .0625rem solid #e2e2e2; /* 1px - separador suave inferior */
}

/* Título del bloque - Estilo El País (.w_t) */
.informe-archivo-related .informe-sidebar-title,
.sde-archivo-related .informe-sidebar-title,
.sde-archivo-related .sde-sidebar-title {
    font-family: MajritTx, serif;         /* El País */
    font-size: .75rem;                     /* 12px - El País (.w_t) */
    font-weight: 900;                      /* El País */
    line-height: 1.25;                     /* El País */
    letter-spacing: -.015rem;              /* El País */
    text-transform: uppercase;             /* El País */
    padding-bottom: .5rem;                 /* 8px */
    border-bottom: .0625rem solid #4a4a4a; /* 1px */
    position: relative;
    margin-bottom: 1.25rem;
    color: #000;
}

/* ::after - Línea negra gruesa El País */
.informe-archivo-related .informe-sidebar-title::after,
.sde-archivo-related .informe-sidebar-title::after,
.sde-archivo-related .sde-sidebar-title::after {
    content: "";
    height: .125rem;                       /* 2px */
    width: 8.25rem;                        /* 132px */
    position: absolute;
    bottom: 0;
    left: 0;
    background: #000;
}

/* Separador - ahora manejado por border-bottom del item */
.informe-archivo-related .informe-item-sep,
.sde-archivo-related .sde-item-sep {
    display: none; /* Ya no se usa, usamos border-bottom en item */
}

/* Item grid - layout similar a related-inline */
.informe-archivo-related__item,
.sde-archivo-related__item {
    display: grid;
    grid-template-columns: 140px 1fr;
    gap: 1rem; /* 16px */
    align-items: start;
    margin-bottom: 1.5rem; /* 24px - separación entre items */
    padding-bottom: 1.5rem; /* 24px */
    border-bottom: .0625rem solid #f0f0f0; /* Separador suave entre items */
}

.informe-archivo-related__item:last-child,
.sde-archivo-related__item:last-child {
    margin-bottom: 0;
    padding-bottom: 0;
    border-bottom: none;
}

/* Contenedor de imagen */
.informe-archivo-related__thumb,
.sde-archivo-related__thumb {
    position: relative;
    overflow: hidden;
    border-radius: var(--border-radius-md);
}

/* Imagen */
.informe-archivo-related__img,
.sde-archivo-related__img {
    width: 100%;
    height: 120px;
    margin: 0 !important;
    border-radius: var(--border-radius-md);
    object-fit: cover;
    display: block;
    filter: grayscale(100%) contrast(0.85);
    transition: transform 0.3s ease;
}

.informe-archivo-related__thumb:hover .informe-archivo-related__img,
.sde-archivo-related__thumb:hover .sde-archivo-related__img {
    transform: scale(1.05);
}

/* Body del item */
.informe-archivo-related__body,
.sde-archivo-related__body {
    display: flex;
    flex-direction: column;
    gap: .5rem; /* 8px */
}

/* Fecha - Estilo El País meta */
.informe-archivo-related__date,
.sde-archivo-related__date {
    font-family: MarcinAntB, sans-serif;   /* El País */
    font-size: var(--fs-meta);             /* .6875rem - 11px */
    font-weight: var(--fw-meta);           /* 500 */
    letter-spacing: var(--ls-meta);        /* .0125rem */
    line-height: var(--lh-excerpt);        /* 1.27 */
    text-transform: uppercase;
    color: #e67e22; /* Mantener color legacy naranja */
}

/* Título - Estilo El País, sobrescribe reglas globales de h3 */
/* Selectores de alta especificidad para sobrescribir .entry-content h3, .post-content h3, etc. */
.informe-archivo-related .informe-archivo-related__title,
.entry-content .informe-archivo-related__title,
.post-content .informe-archivo-related__title,
.informe-article__content .informe-archivo-related__title,
.informe-single-content .informe-archivo-related__title,
.informe-archivo-related__title,
.sde-archivo-related .sde-archivo-related__title,
.entry-content .sde-archivo-related__title,
.post-content .sde-archivo-related__title,
.informe-article__content .sde-archivo-related__title,
.informe-single-content .sde-archivo-related__title,
.sde-archivo-related__title {
    font-family: MajritTx, serif;         /* El País */
    font-size: var(--fs-title-sm);        /* 1rem - 16px El País */
    font-weight: 700;                      /* El País */
    line-height: 1.13;                     /* El País */
    letter-spacing: var(--ls-title-sm);   /* -.005625rem */
    margin: 0 !important;                  /* Sin margen superior ni inferior */
    padding: 0 !important;                 /* Sin padding */
}

.informe-archivo-related__title a,
.sde-archivo-related__title a {
    color: var(--color-black);
    text-decoration: none;
    transition: color 0.2s ease;
}

.informe-archivo-related__title a:hover,
.sde-archivo-related__title a:hover {
    color: var(--color-primary, #e67e22);
    text-decoration: underline;
}

/* Responsive */
@media (max-width: 600px) {
    .informe-archivo-related__item,
    .sde-archivo-related__item {
        grid-template-columns: 1fr;
        gap: .75rem; /* 12px */
    }
    
    .informe-archivo-related__thumb,
    .sde-archivo-related__thumb {
        width: 100%;
    }
    
    .informe-archivo-related__img,
    .sde-archivo-related__img {
        width: 100%;
        max-width: 100%;
        height: 250px;
    }
}
