Add Ghost CMS blog section (list + article pages)
This commit is contained in:
@@ -3642,3 +3642,306 @@ h6 {
|
||||
.banner-pad-28 {
|
||||
padding-block: 112px;
|
||||
}
|
||||
|
||||
/* --------------------------------------------------------------------------
|
||||
25. Blog (Ghost CMS) — list + article
|
||||
-------------------------------------------------------------------------- */
|
||||
.blog-list {
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
gap: 56px;
|
||||
}
|
||||
.blog-empty {
|
||||
text-align: center;
|
||||
color: var(--ink-500);
|
||||
padding-block: 64px;
|
||||
}
|
||||
|
||||
/* Shared tag pill */
|
||||
.blog-tag {
|
||||
display: inline-flex;
|
||||
align-items: center;
|
||||
align-self: flex-start;
|
||||
padding: 5px 12px;
|
||||
border-radius: 999px;
|
||||
background: var(--brand-cream2);
|
||||
color: var(--brand-orange);
|
||||
font-size: 12px;
|
||||
font-weight: 600;
|
||||
text-transform: uppercase;
|
||||
letter-spacing: 0.08em;
|
||||
}
|
||||
.blog-tag--muted {
|
||||
background: #f2f2f2;
|
||||
color: var(--ink-500);
|
||||
}
|
||||
.blog-tag--float {
|
||||
position: absolute;
|
||||
top: 14px;
|
||||
left: 14px;
|
||||
background: rgba(255, 255, 255, 0.92);
|
||||
backdrop-filter: blur(4px);
|
||||
}
|
||||
|
||||
/* Shared meta line (date • reading time) */
|
||||
.blog-meta {
|
||||
display: inline-flex;
|
||||
align-items: center;
|
||||
gap: 8px;
|
||||
font-size: 13px;
|
||||
color: var(--ink-500);
|
||||
}
|
||||
.blog-meta__dot {
|
||||
opacity: 0.5;
|
||||
}
|
||||
|
||||
/* Fallback cover when a post has no feature image */
|
||||
.blog-card__placeholder {
|
||||
position: absolute;
|
||||
inset: 0;
|
||||
display: grid;
|
||||
place-items: center;
|
||||
background: linear-gradient(135deg, var(--brand-orange), var(--brand-light));
|
||||
}
|
||||
.blog-card__placeholder span {
|
||||
font-family: var(--font-display);
|
||||
font-size: 64px;
|
||||
color: rgba(255, 255, 255, 0.9);
|
||||
}
|
||||
|
||||
/* Featured (first) post */
|
||||
.blog-feature {
|
||||
display: grid;
|
||||
grid-template-columns: 1.1fr 1fr;
|
||||
gap: 40px;
|
||||
align-items: center;
|
||||
background: #fff;
|
||||
border: 1px solid #f0eae4;
|
||||
border-radius: 24px;
|
||||
overflow: hidden;
|
||||
box-shadow: var(--shadow-soft);
|
||||
transition: transform 0.35s ease, box-shadow 0.35s ease;
|
||||
}
|
||||
.blog-feature:hover {
|
||||
transform: translateY(-4px);
|
||||
box-shadow: var(--shadow-card);
|
||||
}
|
||||
.blog-feature__media {
|
||||
position: relative;
|
||||
aspect-ratio: 16 / 11;
|
||||
min-height: 320px;
|
||||
}
|
||||
.blog-feature__body {
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
gap: 14px;
|
||||
padding: 40px 44px 40px 4px;
|
||||
}
|
||||
.blog-feature__title {
|
||||
font-family: var(--font-display);
|
||||
font-size: clamp(24px, 3vw, 34px);
|
||||
line-height: 1.2;
|
||||
color: var(--ink-900);
|
||||
}
|
||||
.blog-feature__excerpt {
|
||||
color: var(--ink-500);
|
||||
line-height: 1.65;
|
||||
}
|
||||
|
||||
/* Grid of remaining posts */
|
||||
.blog-grid {
|
||||
display: grid;
|
||||
grid-template-columns: repeat(3, 1fr);
|
||||
gap: 28px;
|
||||
}
|
||||
.blog-card {
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
background: #fff;
|
||||
border: 1px solid #f0eae4;
|
||||
border-radius: 20px;
|
||||
overflow: hidden;
|
||||
transition: transform 0.35s ease, box-shadow 0.35s ease;
|
||||
}
|
||||
.blog-card:hover {
|
||||
transform: translateY(-4px);
|
||||
box-shadow: var(--shadow-card);
|
||||
}
|
||||
.blog-card__media {
|
||||
position: relative;
|
||||
aspect-ratio: 16 / 10;
|
||||
}
|
||||
.blog-card__body {
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
gap: 12px;
|
||||
padding: 22px 22px 26px;
|
||||
flex: 1;
|
||||
}
|
||||
.blog-card__title {
|
||||
font-family: var(--font-display);
|
||||
font-size: 20px;
|
||||
line-height: 1.3;
|
||||
color: var(--ink-900);
|
||||
}
|
||||
.blog-card__excerpt {
|
||||
color: var(--ink-500);
|
||||
font-size: 14px;
|
||||
line-height: 1.6;
|
||||
flex: 1;
|
||||
}
|
||||
|
||||
/* Single article */
|
||||
.blogpost {
|
||||
padding-bottom: 96px;
|
||||
}
|
||||
.blogpost__inner {
|
||||
max-width: 820px;
|
||||
}
|
||||
.blogpost__back {
|
||||
display: inline-block;
|
||||
margin-top: 8px;
|
||||
color: var(--ink-500);
|
||||
font-size: 14px;
|
||||
font-weight: 500;
|
||||
transition: color 0.2s ease;
|
||||
}
|
||||
.blogpost__back:hover {
|
||||
color: var(--brand-orange);
|
||||
}
|
||||
.blogpost__head {
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
gap: 18px;
|
||||
margin-top: 24px;
|
||||
}
|
||||
.blogpost__title {
|
||||
color: var(--ink-900);
|
||||
}
|
||||
.blogpost__byline {
|
||||
display: flex;
|
||||
align-items: center;
|
||||
gap: 14px;
|
||||
}
|
||||
.blogpost__avatar {
|
||||
position: relative;
|
||||
width: 44px;
|
||||
height: 44px;
|
||||
border-radius: 50%;
|
||||
overflow: hidden;
|
||||
flex-shrink: 0;
|
||||
}
|
||||
.blogpost__byline-text {
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
gap: 3px;
|
||||
}
|
||||
.blogpost__author {
|
||||
font-weight: 600;
|
||||
color: var(--ink-800);
|
||||
}
|
||||
.blogpost__hero {
|
||||
position: relative;
|
||||
aspect-ratio: 16 / 9;
|
||||
margin-top: 32px;
|
||||
border-radius: 20px;
|
||||
overflow: hidden;
|
||||
}
|
||||
|
||||
/* Rendered Ghost HTML */
|
||||
.blogpost__content {
|
||||
margin-top: 40px;
|
||||
color: var(--ink-800);
|
||||
font-size: 17px;
|
||||
line-height: 1.8;
|
||||
}
|
||||
.blogpost__content > * + * {
|
||||
margin-top: 22px;
|
||||
}
|
||||
.blogpost__content h2 {
|
||||
font-family: var(--font-display);
|
||||
font-size: 26px;
|
||||
line-height: 1.25;
|
||||
color: var(--ink-900);
|
||||
margin-top: 40px;
|
||||
}
|
||||
.blogpost__content h3 {
|
||||
font-family: var(--font-display);
|
||||
font-size: 21px;
|
||||
color: var(--ink-900);
|
||||
margin-top: 32px;
|
||||
}
|
||||
.blogpost__content a {
|
||||
color: var(--brand-orange);
|
||||
text-decoration: underline;
|
||||
text-underline-offset: 3px;
|
||||
}
|
||||
.blogpost__content ul,
|
||||
.blogpost__content ol {
|
||||
padding-left: 22px;
|
||||
list-style: revert;
|
||||
}
|
||||
.blogpost__content li + li {
|
||||
margin-top: 8px;
|
||||
}
|
||||
.blogpost__content img {
|
||||
border-radius: 16px;
|
||||
margin-inline: auto;
|
||||
}
|
||||
.blogpost__content blockquote {
|
||||
border-left: 3px solid var(--brand-orange);
|
||||
padding-left: 20px;
|
||||
color: var(--ink-500);
|
||||
font-style: italic;
|
||||
}
|
||||
.blogpost__content figure {
|
||||
margin-block: 12px;
|
||||
}
|
||||
.blogpost__content figcaption {
|
||||
text-align: center;
|
||||
font-size: 13px;
|
||||
color: var(--ink-400);
|
||||
margin-top: 8px;
|
||||
}
|
||||
.blogpost__content pre {
|
||||
background: #1c0e03;
|
||||
color: #fbe8dc;
|
||||
padding: 18px 20px;
|
||||
border-radius: 12px;
|
||||
overflow-x: auto;
|
||||
font-size: 14px;
|
||||
}
|
||||
.blogpost__content code {
|
||||
font-size: 0.92em;
|
||||
}
|
||||
.blogpost__tags {
|
||||
display: flex;
|
||||
flex-wrap: wrap;
|
||||
gap: 8px;
|
||||
margin-top: 40px;
|
||||
padding-top: 28px;
|
||||
border-top: 1px solid #f0eae4;
|
||||
}
|
||||
.blogpost__foot {
|
||||
margin-top: 32px;
|
||||
}
|
||||
|
||||
@media (max-width: 900px) {
|
||||
.blog-feature {
|
||||
grid-template-columns: 1fr;
|
||||
}
|
||||
.blog-feature__media {
|
||||
min-height: 240px;
|
||||
}
|
||||
.blog-feature__body {
|
||||
padding: 8px 28px 36px;
|
||||
}
|
||||
.blog-grid {
|
||||
grid-template-columns: repeat(2, 1fr);
|
||||
}
|
||||
}
|
||||
@media (max-width: 560px) {
|
||||
.blog-grid {
|
||||
grid-template-columns: 1fr;
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user