77 lines
1.4 KiB
CSS
77 lines
1.4 KiB
CSS
.card {
|
|
border-radius: var(--Corner-radius-Medium);
|
|
display: flex;
|
|
flex-direction: column;
|
|
max-width: 399px;
|
|
overflow: hidden;
|
|
}
|
|
|
|
.default {
|
|
background-color: var(--Base-Surface-Subtle-Normal);
|
|
}
|
|
|
|
.featured {
|
|
background-color: var(--Main-Grey-White);
|
|
}
|
|
|
|
.default,
|
|
.featured {
|
|
border: 1px solid var(--Base-Border-Subtle);
|
|
}
|
|
|
|
.imageContainer {
|
|
width: 100%;
|
|
height: 12.58625rem; /* 201.38px / 16 = 12.58625rem */
|
|
overflow: hidden;
|
|
}
|
|
|
|
.backgroundImage {
|
|
width: 100%;
|
|
height: 100%;
|
|
object-fit: cover;
|
|
}
|
|
|
|
.content {
|
|
display: flex;
|
|
flex-direction: column;
|
|
gap: var(--Spacing-x-one-and-half);
|
|
align-items: flex-start;
|
|
padding: var(--Spacing-x2) var(--Spacing-x3);
|
|
}
|
|
|
|
.description {
|
|
color: var(--Base-Text-Medium-contrast);
|
|
}
|
|
|
|
.ctaContainer {
|
|
display: grid;
|
|
grid-template-columns: 1fr;
|
|
gap: var(--Spacing-x1);
|
|
width: 100%;
|
|
}
|
|
|
|
.ctaButton {
|
|
width: 100%;
|
|
}
|
|
|
|
.body {
|
|
display: -webkit-box;
|
|
-webkit-box-orient: vertical;
|
|
-webkit-line-clamp: 3;
|
|
line-clamp: 3;
|
|
overflow: hidden;
|
|
text-overflow: ellipsis;
|
|
/* line-height variables are in %, so using the value in rem instead */
|
|
max-height: calc(3 * 1.5rem);
|
|
}
|
|
|
|
@media (min-width: 1367px) {
|
|
.card:not(.alwaysStack) .ctaContainer {
|
|
grid-template-columns: repeat(auto-fit, minmax(0, 1fr));
|
|
}
|
|
|
|
.card:not(.alwaysStack) .ctaContainer:has(:only-child) {
|
|
grid-template-columns: 1fr;
|
|
}
|
|
}
|