cards.css
ASCII text
1.card { 2box-shadow: var(--shadow-card); 3margin: var(--margin-card); 4border-radius: var(--radius-card); 5background: var(--color-card); 6color: var(--color-card-text); 7border: var(--border-card); 8overflow: hidden; /* So rounded corners can cut through the content */ 9display: flex; 10flex-flow: column nowrap; 11height: 100%; 12} 13 14.card > :is(section, header, footer) { 15padding: var(--padding-card); 16} 17 18.card > figure > figcaption { 19padding: var(--padding-card-figcaption); 20} 21 22.card:not(:has(figure)) { 23padding-top: var(--padding-card-top); /* Figures should be flush with the top */ 24} 25 26figcaption { 27color: var(--color-figcaption-text); 28} 29 30.card-outline { 31box-shadow: none; 32border: none; 33border-radius: var(--radius-outlined-card); 34outline: var(--outline-outlined-card); 35} 36 37.card-horizontal { 38flex-flow: row nowrap; 39} 40 41.card-horizontal > figure { 42height: auto; 43max-width: var(--figure-max-size-horizontal-card); 44} 45 46.card-horizontal > figure + :is(section, header, footer) { 47/* Beside figure */ 48padding-top: var(--padding-card-top); 49}