/* /assets/css/p-grid.css | v=fix.1.0.0 | START OF CODE */
/* S2-E1: Grid dinámica responsive + Skeleton + Aspect Ratio */
.post-grid { display: grid; gap: 20px; padding: 20px 0; transition: opacity 0.3s ease; }
.post-grid__item { background: #fff; border: 1px solid #e0e0e0; border-radius: 8px; overflow: hidden; transition: transform 0.2s, box-shadow 0.2s; position: relative; }
.post-grid__item:hover { transform: translateY(-2px); box-shadow: 0 4px 12px rgba(0,0,0,0.1); }
.post-grid__link { display: block; text-decoration: none; color: inherit; height: 100%; }

/* FIX CLS: Aspect Ratio explícito */
.post-grid__image {
    width: 100%;
    height: 150px;
    object-fit: cover;
    aspect-ratio: 210 / 150;
    display: block;
    background: #f0f0f0;
    transition: opacity 0.4s ease, filter 0.4s ease;
}
.post-grid__image.loaded { opacity: 1; filter: blur(0); }

.post-grid__content { padding: 15px; }
.post-grid__title { font-size: 16px; font-weight: 600; margin: 0 0 10px 0; line-height: 1.3; color: #333; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden;text-transform: lowercase; }
.post-grid__title::first-letter {text-transform: uppercase;}
.post-grid__excerpt { font-size: 14px; line-height: 1.5; color: #666; margin: 0; display: -webkit-box; -webkit-line-clamp: 3; -webkit-box-orient: vertical; overflow: hidden; }

/* Botón Compartir */
.post-grid__share { position: absolute; top: 10px; right: 10px; width: 36px; height: 36px; background: rgba(255,255,255,0.95); border: 1px solid #ddd; border-radius: 50%; cursor: pointer; font-size: 16px; display: flex; align-items: center; justify-content: center; opacity: 0; transition: opacity 0.2s ease, transform 0.2s ease; z-index: 2; }
.post-grid__item:hover .post-grid__share { opacity: 1; }
.post-grid__share:hover { background: var(--color-primary); transform: scale(1.1); }

/* Skeleton Loading */
.post-grid--skeleton { display: grid; gap: 20px; grid-template-columns: repeat(4, 1fr); }
.post-grid__skeleton-item { background: #fff; border: 1px solid #e0e0e0; border-radius: 8px; overflow: hidden; padding: 0; }
.skeleton { background: linear-gradient(90deg, #f0f0f0 25%, #e0e0e0 50%, #f0f0f0 75%); background-size: 200% 100%; animation: skeleton-loading 1.5s infinite; border-radius: 4px; }
.skeleton--image { width: 100%; height: 180px; border-radius: 0; }
.skeleton--title { height: 20px; margin: 15px 15px 10px; width: 80%; }
@keyframes skeleton-loading { 0% { background-position: 200% 0; } 100% { background-position: -200% 0; } }

/* Responsive Breakpoints */
@media (max-width: 479px) {
    .post-grid { grid-template-columns: 1fr; }
    .post-grid--skeleton { grid-template-columns: 1fr; }
    .post-grid__image { display: none; }
    .post-grid__content { padding: 12px; }
}
@media (min-width: 480px) and (max-width: 767px) {
    .post-grid, .post-grid--skeleton { grid-template-columns: repeat(2, 1fr); }
}
@media (min-width: 768px) and (max-width: 1023px) {
    .post-grid, .post-grid--skeleton { grid-template-columns: repeat(3, 1fr); }
}
@media (min-width: 1024px) {
    .post-grid, .post-grid--skeleton { grid-template-columns: repeat(4, 1fr); }
}
/* /assets/css/p-grid.css | v=fix.1.0.0 | END OF CODE */