/* ============================= */
/* CARD */
/* ============================= */

.h-card{
    display:flex;
    width:100%;
    flex-direction:column;
    background:#fff;
    border-radius:16px;
    text-decoration:none;
    color:#333;
    box-shadow: 0 3px 6px rgba(0,0,0,0.08);i    transition:all 0.35s ease;
    padding:20px;
    gap:18px;
    height:100%;
    margin-bottom:25px;
    font-family: inherit;
}

/* HOVER CARD */
.h-card:hover{
    transform:translateY(-5px);
    box-shadow: 0 3px 6px rgba(0,0,0,0.08);
    background:#f7fbff;
    text-decoration: none;
}


/* ============================= */
/* IMAGE */
/* ============================= */

.h-card-image{
    width:100%;
    max-width:170px;       /* slightly bigger = better quality */
    aspect-ratio: 4 / 5;     /* or 16/9 */
    flex-shrink:0;
    overflow:hidden;
    border-radius:10px;
    border:1px solid #ddd;
}

.h-card-image img{
    width:100%;
    height:100%;
    object-fit:cover;
    display:block;
    transition: transform 0.35s ease;
    image-rendering: -webkit-optimize-contrast;
}

/* IMAGE ZOOM */
.h-card:hover img{
    transform:scale(1.03);
}


/* ============================= */
/* CONTENT */
/* ============================= */

.h-card-content{
    flex:1;
    display:flex;
    flex-direction:column;
}

.h-card-content h3{
    font-size:20px;
    margin-bottom:6px;
    transition:color 0.3s ease;
}

.h-card-content small{
    display:block;
    color:#777;
    margin-bottom:1px;
    font-size: 14px;
    text-transform:uppercase;
    letter-spacing:0.8px;
}

.h-card-content p{
    font-size:14px;
    color:#666;
    line-height:1.6;
    margin-bottom:12px;
    /* clamp text */
    display:-webkit-box;
    -webkit-line-clamp:3;
    -webkit-box-orient:vertical;
    overflow:hidden;
    flex-grow:1;
}


/* TEXT COLOR ON HOVER */
/* allow color inheritance */
.h-card-content h3,
.h-card-content small,
.h-card-content p{
    color: inherit;
    transition: color 0.3s ease;
}

/* hover = change ALL text */
.h-card:hover .h-card-content{
    color: #00a3e0;
}


/* ============================= */
/* LINK / ARROW */
/* ============================= */

.h-card-link{
    color:#00a3e0;
    font-weight:500;
}

/* ARROW (hidden by default) */
.h-card-arrow{
    margin-top:auto;
    font-size:20px;
    color:#00a3e0;

    opacity:0;
    transform:translateX(-10px);
    transition:all 0.3s ease;
}

/* SHOW ONLY ON HOVER */
.h-card:hover .h-card-arrow{
    opacity:1;
    transform:translateX(0);
}


/* ============================= */
/* DESKTOP (horizontal layout) */
/* ============================= */

@media (min-width:768px){

    .h-card{
        flex-direction:row;
        align-items:flex-start;
    }

}


/* ============================= */
/* MOBILE (vertical layout) */
/* ============================= */

@media (max-width:767px){

    .h-card{
        flex-direction:column;
        align-items:center;
        text-align:center;
    }

    .h-card-image{
        max-width:100%;
    }

    .h-card-image img{
        width:100%;
        height:200px;
    }

}
@media (min-width: 992px){
    .col-md-3{
        padding-right:25px;
    }

    .col-md-9{
        padding-left:25px;
    }
}