Template:Home/FeaturedAccessionCard/styles.css: Difference between revisions
Template page
More actions
Eloise Zomia (talk | contribs) No edit summary |
Eloise Zomia (talk | contribs) No edit summary |
||
Line 39: | Line 39: | ||
color: #6c757d; | color: #6c757d; | ||
font-size: .95rem; | font-size: .95rem; | ||
} | |||
/* ---- Featured Accession Card: text & layout ---- */ | |||
.fa-body { | |||
padding: 12px 14px 14px; | |||
display: flex; | |||
flex-direction: column; | |||
gap: 6px; /* tidy vertical rhythm */ | |||
} | |||
/* Kicker line: status • population */ | |||
.fa-kicker { | |||
margin: 2px 0 0; | |||
font-size: 0.82rem; | |||
line-height: 1.3; | |||
color: #6b7280; /* subtle gray */ | |||
display: flex; | |||
align-items: center; | |||
white-space: nowrap; | |||
overflow: hidden; | |||
text-overflow: ellipsis; | |||
} | |||
.fa-status { font-weight: 600; text-transform: capitalize; } | |||
.fa-dot { margin: 0 .35rem; color: #9ca3af; } | |||
.fa-loc { overflow: hidden; text-overflow: ellipsis; } | |||
/* Title */ | |||
.fa-title { | |||
margin: 2px 0 0; | |||
font-family: Georgia, "Times New Roman", serif; | |||
font-size: 1.15rem; | |||
line-height: 1.25; | |||
color: #1f2937; | |||
} | |||
.fa-title a { text-decoration: none; color: inherit; } | |||
/* Subline: region • province, country */ | |||
.fa-sub { | |||
margin: 0; | |||
font-size: 0.86rem; | |||
color: #6b7280; | |||
} | |||
/* Hook/teaser */ | |||
.fa-hook { | |||
margin: 2px 0 6px 0; | |||
font-size: 0.93rem; | |||
line-height: 1.45; | |||
color: #374151; | |||
/* Sanitizer-safe multi-line clamp (~3 lines) */ | |||
overflow: hidden; | |||
max-height: 4.4em; /* 1.45 line-height × 3 lines ≈ 4.35em */ | |||
} | |||
/* CTA */ | |||
.fa-cta { margin-top: auto; } | |||
.fa-cta a { | |||
font-weight: 600; | |||
text-decoration: none; | |||
color: #2563eb; /* link blue */ | |||
} | |||
.fa-cta a:hover { text-decoration: underline; } | |||
.fa-missing { color: #9ca3af; } | |||
/* Card hover polish (optional) */ | |||
.fa-card { | |||
transition: box-shadow .15s ease, border-color .15s ease; | |||
} | |||
.fa-card:hover { | |||
border-color: #d9d9d9; | |||
box-shadow: 0 4px 14px rgba(0,0,0,.06); | |||
} | } |
Revision as of 01:13, 24 August 2025
/* Template:Home/FeaturedAccessionCard/styles.css ← CSS ONLY */ .fa-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(280px, 1fr)); gap: 1rem; } .fa-card { border: 1px solid #e6e6e6; border-radius: 10px; overflow: hidden; background: #fff; } .fa-media { position: relative; width: 100%; height: 200px; /* adjust as you like */ overflow: hidden; background: #f5f5f5; } /* Style the actual <img> regardless of class/where MW puts it */ .fa-media img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; display: block; } /* Placeholder */ .fa-img--placeholder { display: flex; align-items: center; justify-content: center; height: 100%; color: #6c757d; font-size: .95rem; } /* ---- Featured Accession Card: text & layout ---- */ .fa-body { padding: 12px 14px 14px; display: flex; flex-direction: column; gap: 6px; /* tidy vertical rhythm */ } /* Kicker line: status • population */ .fa-kicker { margin: 2px 0 0; font-size: 0.82rem; line-height: 1.3; color: #6b7280; /* subtle gray */ display: flex; align-items: center; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; } .fa-status { font-weight: 600; text-transform: capitalize; } .fa-dot { margin: 0 .35rem; color: #9ca3af; } .fa-loc { overflow: hidden; text-overflow: ellipsis; } /* Title */ .fa-title { margin: 2px 0 0; font-family: Georgia, "Times New Roman", serif; font-size: 1.15rem; line-height: 1.25; color: #1f2937; } .fa-title a { text-decoration: none; color: inherit; } /* Subline: region • province, country */ .fa-sub { margin: 0; font-size: 0.86rem; color: #6b7280; } /* Hook/teaser */ .fa-hook { margin: 2px 0 6px 0; font-size: 0.93rem; line-height: 1.45; color: #374151; /* Sanitizer-safe multi-line clamp (~3 lines) */ overflow: hidden; max-height: 4.4em; /* 1.45 line-height × 3 lines ≈ 4.35em */ } /* CTA */ .fa-cta { margin-top: auto; } .fa-cta a { font-weight: 600; text-decoration: none; color: #2563eb; /* link blue */ } .fa-cta a:hover { text-decoration: underline; } .fa-missing { color: #9ca3af; } /* Card hover polish (optional) */ .fa-card { transition: box-shadow .15s ease, border-color .15s ease; } .fa-card:hover { border-color: #d9d9d9; box-shadow: 0 4px 14px rgba(0,0,0,.06); }