/* ==========================================================================
   About page — "Gwen Stages" timeline and the intro/belief blocks.

   Written in plain CSS rather than Tailwind utilities: the page loads Tailwind
   from the CDN, which does not read tailwind.config.js, so the project's custom
   colour names (bg-main, bg-second, text-main, text-greyy) resolve to nothing.
   ========================================================================== */

.gw-about {
    --gw-teal: #008a8a;
    --gw-teal-dark: #2e7d7a;
    --gw-green: #25c97a;
    --gw-ink: #111517;
    --gw-grey: #777;
    --gw-rule: #c9d6dc;
}

/* ---------- intro ---------- */
.gw-about__intro-card {
    position: relative;
    z-index: 5;
    margin-top: -150px;
    padding: 34px 38px;
    background: rgba(0, 138, 138, .88);
    color: #fff;
}

.gw-about__intro-card h2 {
    margin: 0 0 14px;
    font-size: clamp(20px, 1rem + .7vw, 26px);
    font-weight: 700;
}

.gw-about__intro-card p {
    margin: 0;
    font-size: 15px;
    line-height: 1.66;
    color: rgba(255, 255, 255, .94);
}

.gw-about__mission h2 {
    margin: 0 0 16px;
    color: var(--gw-teal);
    font-size: clamp(20px, 1rem + .8vw, 28px);
    font-weight: 700;
}

.gw-about__mission p {
    margin: 0;
    font-size: 15px;
    line-height: 1.72;
    color: var(--gw-grey);
}

/* ---------- stages ---------- */
.gw-stages__title {
    margin: 0 0 24px;
    text-align: center;
    font-size: clamp(28px, 1.2rem + 1.6vw, 42px);
    font-weight: 700;
    color: var(--gw-ink);
}

.gw-stages__track {
    position: relative;
    max-width: 1400px;
    margin: 0 auto;
}

.gw-stages__arrow {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
}

.gw-stages__list {
    position: relative;
    margin: 0;
    padding: 0;
    list-style: none;
}

.gw-stage { --c: var(--gw-teal-dark); }
.gw-stage--green { --c: var(--gw-green); }

.gw-stage__dot {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 104px;
    height: 104px;
    border-radius: 50%;
    background: var(--c);
}

.gw-stage__dot img {
    width: 44px;
    height: 44px;
    object-fit: contain;
    /* the source icons are dark; the design shows them knocked out white */
    filter: brightness(0) invert(1);
}

.gw-stage__body {
    display: flex;
    align-items: flex-start;
    gap: 14px;
}

.gw-stage__num {
    order: 1;
    flex: none;
    font-size: clamp(26px, 1rem + 1.2vw, 36px);
    font-weight: 400;
    line-height: 1.1;
    color: var(--gw-ink);
}

.gw-stage__bar {
    order: 2;
    flex: none;
    align-self: stretch;
    width: 4px;
    background: var(--c);
}

.gw-stage__text {
    order: 3;
    flex: 1;
}

.gw-stage__text h3 {
    margin: 0 0 10px;
    font-size: clamp(18px, .9rem + .6vw, 24px);
    font-weight: 700;
    color: var(--gw-ink);
}

.gw-stage__text p {
    margin: 0;
    font-size: 14px;
    line-height: 1.62;
    color: var(--gw-grey);
}

/* mirrored blocks read text -> number -> bar, out towards the page edge */
.gw-stage--mirror .gw-stage__text { order: 1; }
.gw-stage--mirror .gw-stage__num  { order: 2; }
.gw-stage--mirror .gw-stage__bar  { order: 3; }

/* ---------- belief row ---------- */
.gw-about__belief h2 {
    margin: 0 0 14px;
    color: var(--gw-teal);
    font-size: clamp(20px, 1rem + .8vw, 28px);
    font-weight: 700;
}

.gw-about__belief p {
    margin: 0;
    font-size: 14px;
    line-height: 1.72;
    color: var(--gw-grey);
}

.gw-about__belief img {
    width: 100%;
    height: auto;
    display: block;
}

/* ==========================================================================
   Desktop: the stages sit on a rising arrow, alternating above and below it.
   ========================================================================== */
@media (min-width: 1100px) {
    .gw-stages__track {
        height: 760px;
    }

    /* fills the track, so each stage's percentage anchor has a box to resolve
       against — as a static list its own height is zero */
    .gw-stages__list {
        position: absolute;
        inset: 0;
    }

    .gw-stage {
        position: absolute;
        left: var(--x);
        top: var(--y);
        width: 0;
        height: 0;
    }

    .gw-stage__dot {
        position: absolute;
        left: -52px;
        top: -52px;
    }

    /* dashed rule from the circle out to the block, behind the accent bar */
    .gw-stage__stem {
        position: absolute;
        left: -1px;
        width: 0;
        border-left: 2px dashed var(--gw-rule);
    }

    .gw-stage__body {
        position: absolute;
        width: 330px;
    }

    .gw-stage--above .gw-stage__stem { bottom: 52px; height: 130px; }
    .gw-stage--above .gw-stage__body { bottom: 172px; left: -22px; }

    .gw-stage--below .gw-stage__stem { top: 52px; height: 90px; }
    .gw-stage--below .gw-stage__body { top: 132px; left: -22px; }

    .gw-stage--mirror .gw-stage__body { left: auto; right: -22px; }
}

/* ==========================================================================
   Below that: a plain vertical list.
   ========================================================================== */
@media (max-width: 1099px) {
    .gw-stages__arrow { display: none; }

    .gw-stages__list {
        display: grid;
        gap: 32px;
    }

    .gw-stage {
        display: flex;
        align-items: flex-start;
        gap: 20px;
    }

    .gw-stage__stem { display: none; }

    .gw-stage__dot {
        flex: none;
        width: 76px;
        height: 76px;
    }

    .gw-stage__dot img { width: 32px; height: 32px; }

    .gw-stage--mirror .gw-stage__text { order: 3; }
    .gw-stage--mirror .gw-stage__num  { order: 1; }
    .gw-stage--mirror .gw-stage__bar  { order: 2; }

    .gw-about__intro-card { margin-top: -60px; }
}
