homegrade_theme_production/template-components/cards/card-news.css

72 lines
1.3 KiB
CSS

.card-news {
transition: all 0.3s ease-in-out;
@keyframes fadeIn {
from {
opacity: 0;
transform: translateY(20px);
}
to {
opacity: 1;
transform: translateY(0px);
}
}
@apply bg-white shadow-lg rounded-3xl relative flex flex-col;
animation: fadeIn 0.6s ease-in-out;
&__thumbnail {
@apply rounded-t-3xl
h-[190px]
object-cover;
}
&__inner {
@apply p-6;
@apply flex flex-col;
flex-grow: 2;
/* @apply h-full ; */
}
&__heading {
@apply flex flex-col !mb-6;
}
&__tag {
@apply bg-secondary-light
text-secondary
w-fit
px-4 py-2
rounded-lg
mb-4;
}
&__thematique-tag {
@apply bg-secondary-light
text-secondary
w-fit
!px-4 !py-1
rounded-xl
mb-4;
}
&__title {
@apply !text-lg font-bold text-secondary mb-1;
overflow: hidden;
text-overflow: ellipsis;
line-height: 1.2 !important;
display: -webkit-box;
-webkit-line-clamp: 4; /* number of lines to show */
line-clamp: 4;
-webkit-box-orient: vertical;
}
.cta--read-more {
@apply text-neutral-900 mt-auto;
}
&:hover {
transform: scale(1.02) translateY(-10px);
.cta_arrow_button {
opacity: 1;
}
}
}