/* =============================================================================
   Figtree Systems — Single Post
   Scoped to .bp-post. Uses the global --fg-* design tokens.
   ============================================================================= */

.bp-post {
    font-family: 'Open Sans', sans-serif;
    color: var(--fg-text);
    line-height: 1.7;
}

.bp-post section { position: relative; }

/* Shared inner wrapper ------------------------------------------------------- */
.bp-inner {
    max-width: var(--fg-max-w);
    margin-inline: auto;
    padding-inline: clamp(1rem, 5vw, 2rem);
}

/* =============================================================================
   1. HERO
   ============================================================================= */
.bp-hero {
    background-color: var(--fg-green-deeper);
    background-size: cover;
    background-position: center;
    min-height: 440px;
    display: flex;
    align-items: flex-end; /* title anchored to bottom */
}

/* Gradient reads bottom-up so text always sits on dark */
.bp-hero::before {
    content: '';
    position: absolute;
    inset: 0;
    background: linear-gradient(
        to top,
        rgba(30, 61, 26, 0.95) 0%,
        rgba(30, 61, 26, 0.60) 45%,
        rgba(30, 61, 26, 0.20) 100%
    );
}

/* Solid green when no featured image */
.bp-hero--no-image::before {
    background: rgba(30, 61, 26, 0.55);
}

.bp-hero__inner {
    position: relative;
    max-width: var(--fg-max-w);
    margin-inline: auto;
    padding: 3rem clamp(1rem, 5vw, 2rem);
    width: 100%;
}

.bp-hero__title {
    font-family: 'Raleway', sans-serif;
    font-weight: 800;
    font-size: clamp(1.8rem, 4.5vw, 3rem);
    color: #fff;
    margin: 0 0 0.85rem;
    line-height: 1.15;
    letter-spacing: -0.01em;
    max-width: 840px;
}

.bp-hero__meta {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 0.5rem 0.75rem;
    font-family: 'Raleway', sans-serif;
    font-weight: 600;
    font-size: 0.88rem;
    color: rgba(255, 255, 255, 0.80);
}

.bp-hero__meta-sep {
    opacity: 0.5;
}

/* =============================================================================
   2. POST CONTENT
   ============================================================================= */
.bp-content-section {
    background: #fff;
    padding: 4.5rem 0 5rem;
}

/* Narrow reading column — narrower than --fg-max-w */
.bp-content {
    max-width: 760px;
    margin-inline: auto;
    padding-inline: clamp(1rem, 5vw, 2rem);
}

/* Headings ------------------------------------------------------------------- */
.bp-content h2 {
    font-family: 'Raleway', sans-serif;
    font-weight: 800;
    font-size: clamp(1.4rem, 3vw, 1.95rem);
    color: var(--fg-green-dark);
    margin: 2.75rem 0 0.75rem;
    line-height: 1.2;
}

.bp-content h3 {
    font-family: 'Raleway', sans-serif;
    font-weight: 700;
    font-size: clamp(1.2rem, 2.5vw, 1.5rem);
    color: var(--fg-green-dark);
    margin: 2.25rem 0 0.6rem;
    line-height: 1.25;
}

.bp-content h4 {
    font-family: 'Raleway', sans-serif;
    font-weight: 700;
    font-size: 1.1rem;
    color: var(--fg-text);
    margin: 2rem 0 0.5rem;
}

/* First heading after the article start needs less top margin */
.bp-content > :first-child { margin-top: 0; }

/* Body ----------------------------------------------------------------------- */
.bp-content p {
    margin: 0 0 1.4rem;
    font-size: 1.05rem;
    line-height: 1.8;
}

.bp-content p:last-child { margin-bottom: 0; }

/* Links ---------------------------------------------------------------------- */
.bp-content a {
    color: var(--fg-green);
    text-decoration: underline;
    text-underline-offset: 3px;
    text-decoration-thickness: 1px;
}

.bp-content a:hover,
.bp-content a:focus-visible {
    color: var(--fg-green-dark);
}

/* Lists ---------------------------------------------------------------------- */
.bp-content ul,
.bp-content ol {
    margin: 0 0 1.4rem;
    padding-left: 1.35rem;
}

.bp-content li {
    font-size: 1.05rem;
    line-height: 1.75;
    margin-bottom: 0.35rem;
}

.bp-content li:last-child { margin-bottom: 0; }

/* Images & figures ----------------------------------------------------------- */
.bp-content img {
    max-width: 100%;
    height: auto;
    display: block;
    border-radius: calc(var(--fg-radius) * 2);
    margin: 2rem auto;
}

.bp-content figure {
    margin: 2.5rem 0;
}

.bp-content figcaption {
    text-align: center;
    font-size: 0.85rem;
    color: #777;
    margin-top: 0.6rem;
    font-style: italic;
}

/* Blockquote ----------------------------------------------------------------- */
.bp-content blockquote {
    border-left: 4px solid var(--fg-green);
    margin: 2.25rem 0;
    padding: 1rem 1.5rem;
    background: var(--fg-green-pale);
    border-radius: 0 var(--fg-radius) var(--fg-radius) 0;
}

.bp-content blockquote p {
    font-size: 1.1rem;
    font-style: italic;
    color: var(--fg-green-dark);
    margin: 0;
    line-height: 1.65;
}

/* Code ----------------------------------------------------------------------- */
.bp-content pre,
.bp-content code {
    font-family: 'Courier New', Courier, monospace;
    font-size: 0.9rem;
    background: #f4f4f2;
    border-radius: var(--fg-radius);
}

.bp-content pre {
    padding: 1.1rem 1.25rem;
    overflow-x: auto;
    margin: 1.75rem 0;
}

.bp-content code {
    padding: 0.15em 0.4em;
}

.bp-content pre code {
    background: none;
    padding: 0;
}

/* Horizontal rule ------------------------------------------------------------ */
.bp-content hr {
    border: none;
    border-top: 1px solid var(--fg-green-light);
    margin: 2.75rem 0;
}

/* =============================================================================
   3. CTA STRIP
   ============================================================================= */
.bp-cta {
    background: var(--fg-green);
    padding: 4.5rem 0;
    text-align: center;
}

.bp-cta__heading {
    font-family: 'Raleway', sans-serif;
    font-weight: 800;
    font-size: clamp(1.6rem, 3.5vw, 2.2rem);
    color: #fff;
    margin: 0 0 2rem;
}

.bp-cta__buttons {
    display: flex;
    justify-content: center;
    flex-wrap: wrap;
    gap: 0.75rem;
}

/* Buttons -------------------------------------------------------------------- */
.bp-btn {
    display: inline-flex;
    align-items: center;
    text-decoration: none;
    border-radius: var(--fg-radius);
    font-family: 'Raleway', sans-serif;
    font-weight: 700;
    font-size: 0.95rem;
    padding: 0.75em 1.8em;
    transition: background 0.2s, color 0.2s, border-color 0.2s;
    line-height: 1.2;
    white-space: nowrap;
}

/* On a green bg: primary = white pill */
.bp-btn--primary {
    background: #fff;
    color: var(--fg-green-dark);
}

.bp-btn--primary:hover,
.bp-btn--primary:focus-visible {
    background: var(--fg-green-light);
    color: var(--fg-green-dark);
}

/* Secondary = ghost outline */
.bp-btn--outline {
    background: transparent;
    color: #fff;
    border: 2px solid rgba(255, 255, 255, 0.70);
}

.bp-btn--outline:hover,
.bp-btn--outline:focus-visible {
    background: rgba(255, 255, 255, 0.15);
    color: #fff;
    border-color: #fff;
}

/* =============================================================================
   RESPONSIVE
   ============================================================================= */
@media (max-width: 600px) {

    .bp-hero {
        min-height: 320px;
    }

    .bp-hero__title {
        font-size: 1.65rem;
    }

    .bp-cta__buttons {
        flex-direction: column;
        align-items: stretch;
    }

    .bp-cta__buttons .bp-btn {
        justify-content: center;
    }
}
