/* Reset link style */
.pub-link {
    text-decoration: none;
    color: inherit;
}

/* Card */
.pub-card {
    position: relative;
    overflow: hidden;
    background: #000;
}

/* Image */
.pub-card img {
    width: 100%;
    height: 320px;
    object-fit: cover;
    transition: transform 0.5s ease;
}

/* Caption bar (matches screenshot) */
.pub-caption {
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100%;
    background: #111;
    color: #fff;
    padding: 10px 12px;
}

/* Caption text */
.pub-caption h6 {
    margin: 0;
    font-size: 16px;
    font-weight: 500;
}

.pub-caption p {
    margin: 3px 0 0;
    font-size: 13px;
    opacity: 0.85;
}

/* Hover effects */
.pub-card::after {
    content: "";
    position: absolute;
    inset: 0;
    background: rgba(0, 0, 0, 0.2);
    opacity: 0;
    transition: opacity 0.4s ease;
}

.pub-card:hover img {
    transform: scale(1.08);
}

.pub-card:hover::after {
    opacity: 1;
}

/* Mobile fix (no hover jump) */
@media (hover: none) {
    .pub-card:hover img {
        transform: none;
    }
}