/* ============================================================
   Dream Clean - Blog pages (/blog/ index + individual posts)
   Loaded on the blog index and any individual blog post alongside
   dcs-global.css, dcs-service-page.css, dcs-individual-service.css.

   Components:
     .dcs-blog-grid      - responsive card grid on the index
     .dcs-blog-card      - individual post card (image + copy + CTA)
     .dcs-blog-post      - individual post page container (added later)
   ============================================================ */

/* --- Index grid --- */

.dcs-blog-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
    gap: clamp(1.5rem, 3vw, 2.25rem);
    max-width: 1040px;
    margin: 0 auto;
}

/* --- Post card --- */

.dcs-blog-card {
    background: var(--white);
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-sm);
    border: 1px solid var(--grey-line);
    overflow: hidden;
    display: flex;
    flex-direction: column;
    transition: transform .2s var(--ease), box-shadow .2s var(--ease);
}
.dcs-blog-card:hover {
    transform: translateY(-3px);
    box-shadow: var(--shadow-md);
}

/* Media - 16:9 landscape banner at the top of the card */
.dcs-blog-card__media {
    width: 100%;
    aspect-ratio: 16 / 9;
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
    background-color: rgba(76, 175, 80, 0.06);
}

/* Card body - grows to fill available space so CTAs align */
.dcs-blog-card__body {
    padding: clamp(1.35rem, 2vw, 1.75rem);
    display: flex;
    flex-direction: column;
    flex: 1;
}

/* Title - links inherit body colour, hover to brand-dark */
.dcs-blog-card__title {
    font-size: clamp(1.15rem, 1rem + 0.6vw, 1.35rem);
    color: var(--charcoal);
    margin: 0 0 0.85rem;
    line-height: 1.3;
    font-weight: 700;
}
.dcs-blog-card__title a {
    color: inherit;
    text-decoration: none;
    transition: color .18s var(--ease);
}
.dcs-blog-card__title a:hover,
.dcs-blog-card__title a:focus {
    color: var(--brand-dark);
}

/* Excerpt */
.dcs-blog-card__excerpt {
    color: var(--ink);
    font-size: 0.95rem;
    line-height: 1.65;
    margin: 0 0 1.35rem;
    flex: 1;   /* pushes the CTA to the bottom of the card */
}

/* Read-more CTA */
.dcs-blog-card__cta {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    color: var(--brand-dark);
    font-weight: 700;
    font-size: 0.9rem;
    text-decoration: none;
    padding-bottom: 4px;
    border-bottom: 2px solid var(--brand);
    align-self: flex-start;
    transition: gap .18s var(--ease), color .18s var(--ease);
}
.dcs-blog-card__cta:hover,
.dcs-blog-card__cta:focus {
    color: var(--brand);
    gap: 0.75rem;
}
.dcs-blog-card__cta::after {
    content: "\f054";
    font-family: "Font Awesome 6 Free";
    font-weight: 900;
    font-size: 0.7rem;
}

/* --- Individual blog post page --- */

.dcs-blog-post {
    max-width: 780px;
    margin: 0 auto;
    padding: clamp(1.5rem, 3vw, 2.5rem) 0;
    color: var(--ink);
}

/* Hero image sitting between the lede and the first H2 */
.dcs-blog-post__hero-media {
    width: 100%;
    aspect-ratio: 16 / 9;
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
    background-color: rgba(76, 175, 80, 0.06);
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-md);
    margin: 0 0 2.5rem;
}

/* Opening standfirst under the H1 - larger, sits above the body */
.dcs-blog-post__lede {
    color: var(--ink);
    font-size: clamp(1.05rem, 1rem + 0.35vw, 1.2rem);
    line-height: 1.7;
    margin: 0 0 2rem;
    padding-bottom: 1.5rem;
    border-bottom: 1px solid var(--grey-line);
    font-weight: 500;
}

/* Section headings */
.dcs-blog-post h2 {
    color: var(--charcoal);
    font-size: clamp(1.25rem, 1.1rem + 0.7vw, 1.5rem);
    margin: 2.5rem 0 1rem;
    font-weight: 700;
    line-height: 1.3;
}
.dcs-blog-post h2:first-child {
    margin-top: 0;
}

/* Body paragraphs */
.dcs-blog-post p {
    margin: 0 0 1.15rem;
    line-height: 1.7;
    font-size: 1rem;
}

/* Custom bulleted lists with brand-green dot */
.dcs-blog-post ul {
    list-style: none;
    padding: 0;
    margin: 0 0 1.5rem;
}
.dcs-blog-post ul li {
    padding: 0.35rem 0 0.35rem 1.5rem;
    position: relative;
    line-height: 1.6;
    font-size: 1rem;
}
.dcs-blog-post ul li::before {
    content: "";
    position: absolute;
    left: 0;
    top: 0.85rem;
    width: 6px;
    height: 6px;
    background: var(--brand);
    border-radius: 50%;
}

/* --- Share block at the bottom of a post --- */

.dcs-blog-post__share {
    max-width: 780px;
    margin: 2.5rem auto 0;
    padding-top: 2rem;
    border-top: 1px solid var(--grey-line);
    text-align: center;
}
.dcs-blog-post__share-lede {
    color: var(--muted);
    font-size: 0.9rem;
    margin: 0 0 1rem;
}
.dcs-blog-post__share-btn {
    display: inline-flex;
    align-items: center;
    gap: 0.6rem;
    padding: 0.75rem 1.5rem;
    background: var(--charcoal);
    color: var(--white);
    border: 0;
    border-radius: var(--radius-md);
    font-family: inherit;
    font-weight: 700;
    font-size: 0.95rem;
    cursor: pointer;
    transition: background .18s var(--ease);
}
.dcs-blog-post__share-btn:hover,
.dcs-blog-post__share-btn:focus {
    background: #000;
}
.dcs-blog-post__share-btn.is-copied {
    background: var(--brand);
}
.dcs-blog-post__share-btn i {
    font-size: 0.9em;
}
