
/* ==========================================================
   FARMING CURRICULUM JOURNEY — EDITABLE ELEMENTOR WIDGET
   Typography is controlled from Elementor / theme.
========================================================== */

.farm-growth {
    --farm-blue: #073b7a;
    --farm-blue-dark: #032a59;
    --farm-green: #557b46;
    --farm-gold: #f2b632;
    --farm-line: #d9e2d5;
    --farm-progress: #557b46;
    --farm-light: #f2b632;
    --journey-duration: 7s;

    position: relative;
    display: block;
    width: 100%;
    max-width: 1380px;
    margin: 0 auto;
    padding: 60px 30px 75px;
    box-sizing: border-box;
    overflow: visible;
}

.farm-growth *,
.farm-growth *::before,
.farm-growth *::after {
    box-sizing: border-box;
}

.farm-growth__timeline {
    position: relative;
    display: block;
    width: 100%;
}

/* -------------------------- Stem -------------------------- */

.farm-growth__line {
    position: absolute;
    top: 42px;
    bottom: 42px;
    left: 50%;
    z-index: 0;

    display: block;
    width: 5px;
    min-width: 5px;
    max-width: 5px;

    transform: translateX(-50%);

    border-radius: 999px;
    background: var(--farm-line);
    overflow: visible;
}

.farm-growth__line::before {
    content: "";
    position: absolute;
    top: 0;
    left: 0;
    z-index: 2;

    width: 5px;
    min-width: 5px;
    max-width: 5px;
    height: 0;

    border-radius: 999px;
    background: linear-gradient(
        90deg,
        color-mix(in srgb, var(--farm-progress) 75%, #000) 0%,
        var(--farm-progress) 35%,
        color-mix(in srgb, var(--farm-progress) 65%, #fff) 50%,
        var(--farm-progress) 65%,
        color-mix(in srgb, var(--farm-progress) 75%, #000) 100%
    );
    box-shadow: 0 0 10px color-mix(in srgb, var(--farm-progress) 25%, transparent);

    animation: fcjStemGrow var(--journey-duration) ease .25s forwards;
}

.farm-growth__line::after {
    content: "";
    position: absolute;
    left: 50%;
    top: 0;
    z-index: 7;

    width: 9px;
    height: 9px;

    border-radius: 50%;
    background: var(--farm-light);
    box-shadow:
        0 0 0 4px color-mix(in srgb, var(--farm-light) 13%, transparent),
        0 0 15px color-mix(in srgb, var(--farm-light) 60%, transparent);

    transform: translate(-50%, -50%);
    opacity: 0;

    animation: fcjLightMove var(--journey-duration) ease .25s forwards;
    pointer-events: none;
}

@keyframes fcjStemGrow {
    from { height: 0; }
    to { height: 100%; }
}

@keyframes fcjLightMove {
    0% { top: 0; opacity: 0; }
    3% { opacity: 1; }
    96% { opacity: 1; }
    100% { top: 100%; opacity: 0; }
}

/* -------------------------- Stage -------------------------- */

.farm-growth__stage {
    --stage-color: #557b46;
    --stage-soft: #f2f7ef;
    --stage-delay: .5s;

    position: relative;

    display: grid;
    grid-template-columns: minmax(0, 1fr) 76px minmax(0, 1fr);
    grid-template-rows: auto;
    align-items: center;

    width: 100%;
    min-height: 215px;
    margin: 0;
    padding: 0;
}

/* branches */
.farm-growth__stage::after {
    content: "";
    position: absolute;
    top: 50%;
    z-index: 1;

    width: 39px;
    height: 3px;
    border-radius: 999px;

    background: var(--stage-color);
    opacity: .72;
    pointer-events: none;
}

.farm-growth__stage--left::after {
    right: 50%;
    transform: translateY(-50%) scaleX(1);
    transform-origin: right center;
    animation: fcjBranchLeft .4s ease var(--stage-delay) forwards;
}

.farm-growth__stage--right::after {
    left: 50%;
    transform: translateY(-50%) scaleX(1);
    transform-origin: left center;
    animation: fcjBranchRight .4s ease var(--stage-delay) forwards;
}

@keyframes fcjBranchLeft {
    to { opacity: 1; transform: translateY(-50%) scaleX(1); }
}
@keyframes fcjBranchRight {
    to { opacity: 1; transform: translateY(-50%) scaleX(1); }
}

/* small leaf */
.farm-growth__stage::before {
    content: "";
    position: absolute;
    top: calc(50% - 45px);
    left: 50%;
    z-index: 1;

    width: 14px;
    height: 8px;
    border-radius: 100% 0 100% 0;
    background: var(--stage-color);

    opacity: .82;
    pointer-events: none;
    animation: fcjLeafReveal .35s ease calc(var(--stage-delay) - .08s) forwards;
}

.farm-growth__stage--left::before {
    transform: translateX(4px) rotate(-30deg);
}
.farm-growth__stage--right::before {
    transform: translateX(-18px) rotate(30deg) scaleX(-1);
}

@keyframes fcjLeafReveal {
    to { opacity: .82; }
}

/* -------------------------- Positioning -------------------------- */

.farm-growth__stage--left .farm-growth__content {
    grid-column: 1;
    grid-row: 1;
    justify-self: stretch;
    margin: 0 10px 0 0;
}

.farm-growth__stage--right .farm-growth__content {
    grid-column: 3;
    grid-row: 1;
    justify-self: stretch;
    margin: 0 0 0 10px;
}

/* -------------------------- Node -------------------------- */

.farm-growth__node {
    grid-column: 2;
    grid-row: 1;

    position: relative;
    z-index: 6;

    justify-self: center;
    align-self: center;

    display: flex;
    align-items: center;
    justify-content: center;

    width: 36px;
    height: 36px;
    min-width: 36px;
    min-height: 36px;

    margin: 0;
    padding: 0;

    border: 3px solid #fff;
    border-radius: 50%;

    background: #fff;
    color: var(--stage-color);

    box-shadow:
        0 0 0 2px var(--stage-color),
        0 4px 12px rgba(32, 65, 42, .11);

    opacity: 1;
    transform: scale(1);

    animation: fcjNodePulse .45s ease var(--stage-delay);
}

.farm-growth__stage--last .farm-growth__node {
    background: var(--stage-color);
    color: #fff;
}

@keyframes fcjNodePulse {
    0%, 100% { transform: scale(1); }
    55% { transform: scale(1.08); }
}

/* -------------------------- Card -------------------------- */

.farm-growth__content {
    position: relative;
    z-index: 2;

    display: block;
    width: 100%;
    min-width: 0;

    padding: 25px 28px 24px;
    overflow: hidden;

    background: linear-gradient(135deg, #fff 0%, #fffefa 100%);
    border: 1px solid rgba(7, 59, 122, .08);
    border-left: 5px solid var(--stage-color);
    border-radius: 17px;

    box-shadow: 0 9px 28px rgba(26, 45, 35, .065);

    opacity: 1;
}

.farm-growth__stage--left .farm-growth__content {
    transform: none;
    animation: fcjCardPulse .55s ease calc(var(--stage-delay) + .10s);
}

.farm-growth__stage--right .farm-growth__content {
    transform: none;
    animation: fcjCardPulse .55s ease calc(var(--stage-delay) + .10s);
}

@keyframes fcjCardPulse {
    0%, 100% { transform: translateY(0); box-shadow: 0 9px 28px rgba(26,45,35,.065); }
    50% { transform: translateY(-3px); box-shadow: 0 14px 34px rgba(26,45,35,.11); }
}

.farm-growth__content::after {
    content: "";
    position: absolute;
    z-index: 0;
    top: -65px;
    right: -65px;

    width: 135px;
    height: 135px;

    border-radius: 50%;
    background: var(--stage-soft);
    pointer-events: none;
}

@media (hover:hover) {
    .farm-growth__content {
        transition: transform .25s ease, box-shadow .25s ease;
    }
    .farm-growth__content:hover {
        transform: translateY(-4px);
        box-shadow: 0 16px 38px rgba(26, 45, 35, .105);
    }
}

/* -------------------------- Header / icon -------------------------- */

.farm-growth__heading {
    position: relative;
    z-index: 2;

    display: flex;
    align-items: center;
    gap: 14px;

    margin: 0 0 13px;
}

.farm-growth__icon {
    display: flex;
    flex: 0 0 48px;
    align-items: center;
    justify-content: center;

    width: 48px;
    height: 48px;

    border-radius: 13px;
    background: var(--stage-soft);
    color: var(--stage-color);

    opacity: 1;
    transform: scale(1);
    animation: fcjIconPulse .4s ease calc(var(--stage-delay) + .22s);
}

@keyframes fcjIconPulse {
    0%, 100% { transform: scale(1); }
    55% { transform: scale(1.06); }
}

.farm-growth__icon svg,
.farm-growth__icon i {
    width: 23px;
    height: 23px;
    font-size: 23px;
    color: currentColor;
}

.farm-growth__icon svg {
    fill: none;
    stroke: currentColor;
    stroke-width: 1.8;
    stroke-linecap: round;
    stroke-linejoin: round;
}

.farm-growth__eyebrow {
    display: block;
    margin: 0 0 4px;
    padding: 0;
    color: var(--stage-color);
}

.farm-growth h3 {
    margin: 0;
    padding: 0;
    color: var(--farm-blue);
}

/* -------------------------- Text -------------------------- */

.farm-growth__level {
    position: relative;
    z-index: 2;
    margin: 0 0 7px;
}

.farm-growth__level-main {
    color: #242e29;
}

.farm-growth__level-meta {
    margin-left: 5px;
    color: #758079;
}

.farm-growth__description {
    position: relative;
    z-index: 2;
    max-width: 93%;
    margin: 0;
    color: #344039;
}

/* -------------------------- Skills -------------------------- */

.farm-growth__skills {
    position: relative;
    z-index: 2;

    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 7px 18px;

    width: 100%;
    margin: 12px 0 0;
    padding: 0;

    list-style: none;
}

.farm-growth__skills li {
    position: relative;
    display: inline-flex;
    flex: 0 0 auto;
    align-items: center;

    width: auto;
    margin: 0;
    padding: 0 0 0 13px;

    list-style: none;
    color: #344039;
    white-space: nowrap;

    opacity: 1;
    transform: none;
}

.farm-growth__skills li::before {
    content: "";
    position: absolute;
    left: 0;
    top: 50%;

    width: 5px;
    height: 5px;
    border-radius: 50%;
    background: var(--stage-color);
    transform: translateY(-50%);
}

.farm-growth__skills li::marker {
    content: "";
}


/* -------------------------- Tablet -------------------------- */

@media (max-width: 991px) {
    .farm-growth {
        padding: 50px 20px 65px;
    }

    .farm-growth__stage {
        grid-template-columns: minmax(0,1fr) 62px minmax(0,1fr);
        min-height: 225px;
    }

    .farm-growth__content {
        padding: 22px 21px;
    }

    .farm-growth__node {
        width: 34px;
        height: 34px;
        min-width: 34px;
        min-height: 34px;
    }

    .farm-growth__icon {
        flex-basis: 44px;
        width: 44px;
        height: 44px;
    }

    .farm-growth__skills li {
        white-space: normal;
    }
}

/* -------------------------- Mobile -------------------------- */

@media (max-width: 767px) {
    .farm-growth {
        padding: 38px 13px 50px 8px;
    }

    .farm-growth__line {
        left: 18px;
        top: 25px;
        bottom: 25px;

        width: 4px;
        min-width: 4px;
        max-width: 4px;

        transform: none;
    }

    .farm-growth__line::before {
        width: 4px;
        min-width: 4px;
        max-width: 4px;
    }

    .farm-growth__line::after {
        width: 8px;
        height: 8px;
    }

    .farm-growth__stage {
        grid-template-columns: 36px minmax(0,1fr);
        grid-template-rows: auto;
        align-items: start;

        min-height: 0;
        margin-bottom: 25px;
    }

    .farm-growth__stage::after {
        left: 18px;
        right: auto;
        top: 35px;

        width: 28px;
        height: 2px;

        transform: scaleX(1);
        transform-origin: left center;
        opacity: .72;
        animation: fcjMobileBranch .35s ease var(--stage-delay);
    }

    @keyframes fcjMobileBranch {
        0%, 100% { opacity: .72; transform: scaleX(1); }
        50% { opacity: 1; transform: scaleX(1); }
    }

    .farm-growth__stage::before {
        left: 19px;
        top: 7px;

        width: 11px;
        height: 7px;

        transform: rotate(-30deg);
    }

    .farm-growth__node {
        grid-column: 1;
        grid-row: 1;
        justify-self: center;

        width: 28px;
        height: 28px;
        min-width: 28px;
        min-height: 28px;

        margin-top: 20px;
        border-width: 2px;
    }

    .farm-growth__stage--left .farm-growth__content,
    .farm-growth__stage--right .farm-growth__content {
        grid-column: 2;
        grid-row: 1;

        width: auto;
        margin: 0 0 0 8px;

        transform: none;
        animation: fcjCardPulse .5s ease calc(var(--stage-delay) + .10s);
    }

    .farm-growth__content {
        padding: 19px 17px;

        /* Mobile accent is intentionally on RIGHT */
        border-left: 1px solid rgba(7,59,122,.08);
        border-right: 4px solid var(--stage-color);
        border-radius: 14px;
    }

    .farm-growth__content::after {
        width: 105px;
        height: 105px;
        top: -55px;
        right: -55px;
    }

    .farm-growth__heading {
        gap: 10px;
        margin-bottom: 12px;
    }

    .farm-growth__icon {
        flex: 0 0 40px;
        width: 40px;
        height: 40px;
        border-radius: 10px;
    }

    .farm-growth__icon svg,
    .farm-growth__icon i {
        width: 20px;
        height: 20px;
        font-size: 20px;
    }

    .farm-growth__description {
        max-width: 100%;
    }

    .farm-growth__skills {
        gap: 7px 13px;
    }

    .farm-growth__skills li {
        white-space: normal;
    }

    .farm-growth__stage:last-child {
        margin-bottom: 0;
    }
}

@media (max-width: 420px) {
    .farm-growth {
        padding-left: 5px;
        padding-right: 8px;
    }

    .farm-growth__stage {
        grid-template-columns: 34px minmax(0,1fr);
    }

    .farm-growth__line {
        left: 17px;
    }

    .farm-growth__stage::after {
        left: 17px;
        width: 26px;
    }

    .farm-growth__stage::before {
        left: 18px;
    }

    .farm-growth__node {
        width: 26px;
        height: 26px;
        min-width: 26px;
        min-height: 26px;
    }

    .farm-growth__stage--left .farm-growth__content,
    .farm-growth__stage--right .farm-growth__content {
        margin-left: 7px;
    }

    .farm-growth__content {
        padding: 17px 15px;
    }

    .farm-growth__icon {
        flex-basis: 38px;
        width: 38px;
        height: 38px;
    }
}

/* -------------------------- Reduced motion -------------------------- */

@media (prefers-reduced-motion: reduce) {
    .farm-growth__line::before,
    .farm-growth__line::after,
    .farm-growth__node,
    .farm-growth__content,
    .farm-growth__stage::before,
    .farm-growth__stage::after,
    .farm-growth__icon,
    .farm-growth__skills li {
        animation: none !important;
        transition: none !important;
    }

    .farm-growth__line::before {
        height: 100%;
    }

    .farm-growth__node,
    .farm-growth__content,
    .farm-growth__stage::before,
    .farm-growth__stage::after,
    .farm-growth__icon,
    .farm-growth__skills li {
        opacity: 1;
        transform: none;
    }
}


/* ==========================================================
   VISIBILITY SAFETY NET
   Content must never depend on animation support.
========================================================== */
.farm-growth__content,
.farm-growth__node,
.farm-growth__icon,
.farm-growth__skills,
.farm-growth__skills li {
    visibility: visible !important;
    opacity: 1 !important;
}



/* ==========================================================
   V2.2 — VIEWPORT-SYNCHRONISED JOURNEY
   Real progress elements replace the old pseudo animation.
========================================================== */

/* Old pseudo progress is disabled in v2.2 */
.farm-growth__line::before,
.farm-growth__line::after {
    content: none !important;
    display: none !important;
    animation: none !important;
}

/* Base stem */
.farm-growth__line {
    background: var(--farm-line, #d9e2d5) !important;
    overflow: visible !important;
}

/* Moving green growth */
.farm-growth__progress {
    position: absolute !important;
    top: 0 !important;
    left: 0 !important;
    z-index: 2 !important;

    display: block !important;

    width: 100% !important;
    height: 0;

    border-radius: 999px !important;

    background:
        linear-gradient(
            90deg,
            color-mix(in srgb, var(--farm-progress, #557b46) 78%, #000) 0%,
            var(--farm-progress, #557b46) 38%,
            color-mix(in srgb, var(--farm-progress, #557b46) 68%, #fff) 50%,
            var(--farm-progress, #557b46) 68%,
            color-mix(in srgb, var(--farm-progress, #557b46) 78%, #000) 100%
        ) !important;

    box-shadow:
        0 0 10px
        color-mix(in srgb, var(--farm-progress, #557b46) 28%, transparent) !important;

    transition:
        height .72s cubic-bezier(.42, 0, .2, 1) !important;

    pointer-events: none !important;
}

/* Travelling gold point */
.farm-growth__light {
    position: absolute !important;
    left: 50% !important;
    top: 0;
    z-index: 8 !important;

    display: block !important;

    width: 10px !important;
    height: 10px !important;

    border-radius: 50% !important;

    background: var(--farm-light, #f2b632) !important;

    box-shadow:
        0 0 0 4px
            color-mix(in srgb, var(--farm-light, #f2b632) 14%, transparent),
        0 0 17px
            color-mix(in srgb, var(--farm-light, #f2b632) 68%, transparent) !important;

    transform: translate(-50%, -50%) !important;

    opacity: 0;

    transition:
        top .72s cubic-bezier(.42, 0, .2, 1),
        opacity .2s ease !important;

    pointer-events: none !important;
}

.farm-growth.fcj-running .farm-growth__light {
    opacity: 1;
}

.farm-growth.fcj-complete .farm-growth__light {
    opacity: 0;
}


/* ==========================================================
   ICON FIX
   Elementor Font Awesome icons are filled SVGs.
   The older line-icon rule removed their fill.
========================================================== */

.farm-growth__icon {
    border:
        1px solid
        color-mix(in srgb, var(--stage-color) 18%, transparent) !important;

    color: var(--stage-color) !important;

    opacity: 1 !important;
    visibility: visible !important;

    transition:
        transform .3s ease,
        color .3s ease,
        background .3s ease,
        box-shadow .3s ease !important;

    animation: none !important;
}

.farm-growth__icon i,
.farm-growth__icon i::before,
.farm-growth__icon svg {
    opacity: 1 !important;
    visibility: visible !important;
    color: currentColor !important;
}

/* Elementor's own icon SVG */
.farm-growth__icon svg.e-font-icon-svg,
.farm-growth__icon .e-font-icon-svg {
    display: block !important;

    fill: currentColor !important;
    stroke: none !important;

    width: 23px !important;
    height: 23px !important;
}

/* Uploaded/custom SVGs keep their own drawing model */
.farm-growth__icon svg:not(.e-font-icon-svg) {
    display: block !important;
}


/* ==========================================================
   JS CONTROLS THE ARRIVAL STATE
========================================================== */

/* Stop the old load-time pulses */
.farm-growth__node,
.farm-growth__stage::before,
.farm-growth__stage::after,
.farm-growth__stage--left .farm-growth__content,
.farm-growth__stage--right .farm-growth__content,
.farm-growth__skills li {
    animation: none !important;
}

/* Cards always remain readable */
.farm-growth__content,
.farm-growth__skills li,
.farm-growth__node,
.farm-growth__icon {
    opacity: 1 !important;
    visibility: visible !important;
}

/* Before the journey reaches a stage, decorations are quiet */
.farm-growth__stage::before,
.farm-growth__stage::after {
    opacity: .18 !important;
    transition:
        opacity .3s ease,
        transform .42s ease !important;
}

/* Branches stay physically connected, but muted */
.farm-growth__stage--left::after {
    transform: translateY(-50%) scaleX(1) !important;
}

.farm-growth__stage--right::after {
    transform: translateY(-50%) scaleX(1) !important;
}


/* ==========================================================
   REACHED STAGE
========================================================== */

.farm-growth__stage.is-reached::before,
.farm-growth__stage.is-reached::after,
.farm-growth__stage.is-active::before,
.farm-growth__stage.is-active::after {
    opacity: 1 !important;
}

.farm-growth__stage.is-reached .farm-growth__node {
    background:
        color-mix(in srgb, var(--stage-color) 10%, #fff) !important;

    color: var(--stage-color) !important;

    box-shadow:
        0 0 0 2px var(--stage-color),
        0 5px 14px
            color-mix(in srgb, var(--stage-color) 18%, transparent) !important;
}


/* ==========================================================
   CURRENT ACTIVE STAGE
========================================================== */

.farm-growth__content {
    transition:
        transform .34s cubic-bezier(.2,.8,.25,1),
        box-shadow .34s ease,
        border-color .34s ease,
        background .34s ease !important;
}

.farm-growth__stage.is-active .farm-growth__content {
    transform:
        translateY(-5px)
        scale(1.012) !important;

    border-color:
        color-mix(in srgb, var(--stage-color) 38%, transparent) !important;

    border-left-color:
        var(--stage-color) !important;

    background:
        linear-gradient(
            135deg,
            #ffffff 0%,
            color-mix(in srgb, var(--stage-soft) 45%, #fff) 100%
        ) !important;

    box-shadow:
        0 0 0 2px
            color-mix(in srgb, var(--stage-color) 14%, transparent),
        0 20px 46px
            color-mix(in srgb, var(--stage-color) 18%, rgba(26,45,35,.10)) !important;
}

.farm-growth__stage.is-active .farm-growth__node {
    background: var(--stage-color) !important;
    color: #fff !important;

    transform: scale(1.14) !important;

    box-shadow:
        0 0 0 3px #fff,
        0 0 0 6px
            color-mix(in srgb, var(--stage-color) 32%, transparent),
        0 7px 18px
            color-mix(in srgb, var(--stage-color) 30%, transparent) !important;
}

.farm-growth__stage.is-active .farm-growth__icon {
    background: var(--stage-color) !important;
    color: #fff !important;

    transform: scale(1.08) !important;

    box-shadow:
        0 8px 20px
        color-mix(in srgb, var(--stage-color) 24%, transparent) !important;
}

.farm-growth__stage.is-active .farm-growth__eyebrow {
    color: var(--stage-color) !important;
}

/* Skill dots become stronger on the active card */
.farm-growth__stage.is-active .farm-growth__skills li::before {
    width: 7px !important;
    height: 7px !important;
    box-shadow:
        0 0 0 3px
        color-mix(in srgb, var(--stage-color) 10%, transparent) !important;
}


/* ==========================================================
   MOBILE ACTIVE BORDER STAYS ON THE RIGHT
========================================================== */

@media (max-width: 767px) {

    .farm-growth__icon svg.e-font-icon-svg,
    .farm-growth__icon .e-font-icon-svg {
        width: 20px !important;
        height: 20px !important;
    }

    .farm-growth__stage.is-active .farm-growth__content {
        border-left:
            1px solid
            color-mix(in srgb, var(--stage-color) 28%, transparent) !important;

        border-right:
            4px solid var(--stage-color) !important;

        transform:
            translateY(-3px)
            scale(1.006) !important;
    }

    .farm-growth__stage::after {
        transform: scaleX(1) !important;
    }
}


/* ==========================================================
   REDUCED MOTION
========================================================== */

@media (prefers-reduced-motion: reduce) {

    .farm-growth__progress,
    .farm-growth__light,
    .farm-growth__content,
    .farm-growth__node,
    .farm-growth__icon,
    .farm-growth__stage::before,
    .farm-growth__stage::after {
        transition: none !important;
    }
}
