/* ============================================================
   CHILDREN'S HOME — project page
   Depends on: styles.css (tokens) + special-projects.css (buttons, meters, etc.)
   ============================================================ */


/* ============================================================
   BREADCRUMB
   ============================================================ */
.breadcrumb {
    display: flex;
    align-items: center;
    gap: 12px;
    font-family: var(--font-ui);
    font-size: 0.7rem;
    font-weight: 700;
    letter-spacing: 1.4px;
    text-transform: uppercase;
    color: rgba(255, 255, 255, 0.75);
    margin-bottom: 32px;
}

.breadcrumb a {
    color: rgba(255, 255, 255, 0.75);
    transition: color 0.3s ease;
}

.breadcrumb a:hover {
    color: var(--gold);
}

.breadcrumb-sep {
    display: inline-flex;
    font-size: 0.6rem;
    opacity: 0.6;
}

.breadcrumb-current {
    color: var(--gold);
    opacity: 0.95;
}


/* ============================================================
   PROJECT HERO
   ============================================================ */
.project-hero {
    position: relative;
    width: 100%;
    margin-top: var(--header-height);
    min-height: 680px;
    display: flex;
    align-items: flex-end;
    overflow: hidden;
    background: #0A1432;
}

.project-hero::before {
    content: '';
    position: absolute;
    inset: 0;
    background: url('images/skills.jpg') center center / cover no-repeat;
    transform-origin: center center;
    will-change: transform;
    animation: hero-kenburns 24s ease-out forwards;
    z-index: 0;
}

.project-hero::after {
    content: '';
    position: absolute;
    inset: 0;
    background:
        linear-gradient(
            to bottom,
            rgba(10, 20, 50, 0.22) 0%,
            rgba(10, 20, 50, 0.45) 45%,
            rgba(10, 20, 50, 0.88) 100%
        ),
        linear-gradient(
            to right,
            rgba(10, 20, 50, 0.55) 0%,
            rgba(10, 20, 50, 0.25) 50%,
            rgba(10, 20, 50, 0.00) 85%
        );
    z-index: 1;
}

@keyframes hero-kenburns {
    from { transform: scale(1);    }
    to   { transform: scale(1.08); }
}

.project-hero-inner {
    position: relative;
    z-index: 2;
    width: 100%;
    max-width: var(--content-width);
    margin: 0 auto;
    padding: 120px 60px 80px;
}

.project-hero .hero-eyebrow {
    color: var(--gold);
    font-family: var(--font-ui);
    font-size: 0.72rem;
    font-weight: 700;
    letter-spacing: 3px;
    text-transform: uppercase;
    margin: 0 0 18px 0;
    opacity: 0.95;
}

.project-hero-content {
    max-width: 720px;
    margin-bottom: 48px;
}

.project-hero-heading {
    font-family: var(--font-serif);
    font-size: 3.6rem;
    font-weight: 700;
    color: #ffffff;
    line-height: 1.08;
    letter-spacing: -0.015em;
    margin: 0 0 22px 0;
    text-shadow: 0 2px 20px rgba(0, 0, 0, 0.4);
}

.project-hero-lead {
    font-family: var(--font-body);
    font-size: 1.12rem;
    line-height: 1.7;
    color: rgba(255, 255, 255, 0.9);
    max-width: 620px;
    margin: 0;
    text-shadow: 0 1px 8px rgba(0, 0, 0, 0.35);
}

/* ---------- Stats row ---------- */
.project-hero-stats {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 40px;
    padding: 36px 0;
    border-top: 1px solid rgba(255, 255, 255, 0.18);
    border-bottom: 1px solid rgba(255, 255, 255, 0.18);
    max-width: 820px;
    margin-bottom: 36px;
}

.project-stat {
    display: flex;
    flex-direction: column;
    gap: 6px;
}

.project-stat-value {
    font-family: var(--font-serif);
    font-size: 2.2rem;
    font-weight: 700;
    color: var(--gold);
    line-height: 1;
    letter-spacing: -0.02em;
    font-variant-numeric: tabular-nums;
    font-feature-settings: "tnum";
}

.project-stat-label {
    font-family: var(--font-ui);
    font-size: 0.68rem;
    font-weight: 700;
    letter-spacing: 1.6px;
    text-transform: uppercase;
    color: rgba(255, 255, 255, 0.72);
}

.project-hero-cta {
    display: inline-block;
}


/* ============================================================
   SHARED PROJECT SECTION
   ============================================================ */
.project-section {
    padding: 120px 0;
    position: relative;
}

.project-section-inner {
    max-width: var(--content-width);
    margin: 0 auto;
    padding: 0 60px;
}

.project-heading {
    font-family: var(--font-serif);
    font-size: 2.6rem;
    font-weight: 700;
    color: var(--blue);
    line-height: 1.12;
    letter-spacing: -0.01em;
    margin: 0 0 20px 0;
}

.project-sub {
    font-family: var(--font-body);
    font-size: 1rem;
    line-height: 1.7;
    color: var(--text-medium);
    margin: 0;
    max-width: 620px;
}

.project-lead {
    font-family: var(--font-body);
    font-size: 1.02rem;
    line-height: 1.78;
    color: var(--text-medium);
    margin: 0 0 20px 0;
}


/* ============================================================
   THE VISION
   ============================================================ */
.project-section-vision {
    background: var(--bg-white);
}

.vision-grid {
    display: grid;
    grid-template-columns: 1fr 1.1fr;
    gap: 72px;
    align-items: start;
}

.vision-media {
    position: sticky;
    top: calc(var(--header-height) + 40px);
    border-radius: var(--radius-card);
    overflow: hidden;
    box-shadow: var(--shadow-lg);
    aspect-ratio: 4 / 5;
}

.vision-media img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
    transition: transform 0.8s cubic-bezier(0.22, 0.61, 0.36, 1);
}

.vision-media:hover img {
    transform: scale(1.03);
}

.vision-media::after {
    content: '';
    position: absolute;
    inset: 0;
    background: linear-gradient(
        135deg,
        rgba(30, 58, 138, 0.12) 0%,
        rgba(255, 217, 102, 0.04) 100%
    );
    pointer-events: none;
}

.vision-content {
    display: flex;
    flex-direction: column;
}

.project-pullquote {
    margin-top: 20px;
    padding: 24px 26px;
    background: rgba(30, 58, 138, 0.04);
    border-left: 3px solid var(--gold);
    border-radius: 4px;
}

.project-pullquote p {
    font-family: var(--font-serif);
    font-style: italic;
    font-size: 1.05rem;
    line-height: 1.6;
    color: var(--blue);
    margin: 0 0 10px 0;
}

.project-pullquote span {
    font-family: var(--font-ui);
    font-size: 0.72rem;
    font-weight: 700;
    letter-spacing: 1.2px;
    text-transform: uppercase;
    color: var(--text-light);
}


/* ============================================================
   THE PLANS
   ============================================================ */
.project-section-plans {
    background: var(--bg-page);
}

.plans-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 24px;
}

.plan-card {
    display: flex;
    flex-direction: column;
    background: #ffffff;
    border: 1px solid rgba(30, 58, 138, 0.08);
    border-radius: var(--radius-card);
    overflow: hidden;
    box-shadow: var(--shadow-sm);
    transition: transform 0.4s ease, box-shadow 0.4s ease;
    cursor: zoom-in;
}

.plan-card:hover {
    transform: translateY(-4px);
    box-shadow: var(--shadow-md);
}

.plan-media {
    aspect-ratio: 4 / 3;
    overflow: hidden;
    background: #EDF1F7;
    display: flex;
    align-items: center;
    justify-content: center;
}

.plan-media img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
    transition: transform 0.6s cubic-bezier(0.22, 0.61, 0.36, 1);
}

.plan-card:hover .plan-media img {
    transform: scale(1.04);
}

.plan-card figcaption {
    display: flex;
    align-items: baseline;
    gap: 12px;
    padding: 18px 20px 20px;
}

.plan-label {
    font-family: var(--font-serif);
    font-size: 1rem;
    font-weight: 700;
    color: var(--gold);
    letter-spacing: 0.5px;
}

.plan-title {
    font-family: var(--font-ui);
    font-size: 0.82rem;
    font-weight: 700;
    letter-spacing: 0.5px;
    color: var(--blue);
}


/* ============================================================
   WHAT'S INSIDE
   ============================================================ */
.project-section-inside {
    background: var(--bg-white);
}

.features-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 28px;
}

.feature-card {
    display: flex;
    flex-direction: column;
    padding: 32px 28px 30px;
    background: var(--bg-page);
    border: 1px solid rgba(30, 58, 138, 0.06);
    border-radius: var(--radius-card);
    transition: transform 0.35s ease, box-shadow 0.35s ease;
}

.feature-card:hover {
    transform: translateY(-4px);
    box-shadow: var(--shadow-md);
}

.feature-icon {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 52px;
    height: 52px;
    background: rgba(255, 217, 102, 0.18);
    color: var(--blue);
    border-radius: 12px;
    font-size: 1.35rem;
    margin-bottom: 20px;
}

.feature-title {
    font-family: var(--font-serif);
    font-size: 1.2rem;
    font-weight: 700;
    color: var(--blue);
    line-height: 1.3;
    margin: 0 0 10px 0;
}

.feature-text {
    font-family: var(--font-body);
    font-size: 0.92rem;
    line-height: 1.65;
    color: var(--text-medium);
    margin: 0;
}


/* ============================================================
   TIMELINE
   ============================================================ */
.project-section-timeline {
    background: var(--bg-page);
}

.timeline {
    position: relative;
    max-width: 820px;
    margin: 0 auto;
    padding-left: 40px;
}

.timeline::before {
    content: '';
    position: absolute;
    left: 15px;
    top: 24px;
    bottom: 24px;
    width: 2px;
    background: rgba(30, 58, 138, 0.12);
}

.timeline-step {
    position: relative;
    padding-bottom: 40px;
}

.timeline-step:last-child {
    padding-bottom: 0;
}

.timeline-marker {
    position: absolute;
    left: -40px;
    top: 4px;
    display: flex;
    align-items: center;
    justify-content: center;
    width: 32px;
    height: 32px;
    border-radius: 50%;
    background: #ffffff;
    border: 2px solid rgba(30, 58, 138, 0.15);
    color: var(--text-light);
    font-size: 0.72rem;
    z-index: 2;
}

.timeline-step-done .timeline-marker {
    background: var(--blue);
    border-color: var(--blue);
    color: #ffffff;
}

.timeline-step-active .timeline-marker {
    background: var(--gold);
    border-color: var(--gold);
    color: var(--blue);
    box-shadow: 0 0 0 6px rgba(255, 217, 102, 0.22);
}

.timeline-content {
    padding-left: 4px;
}

.timeline-year {
    display: inline-block;
    font-family: var(--font-ui);
    font-size: 0.68rem;
    font-weight: 700;
    letter-spacing: 1.6px;
    text-transform: uppercase;
    color: var(--text-light);
    margin-bottom: 8px;
}

.timeline-title {
    font-family: var(--font-serif);
    font-size: 1.3rem;
    font-weight: 700;
    color: var(--blue);
    line-height: 1.3;
    margin: 0 0 8px 0;
}

.timeline-text {
    font-family: var(--font-body);
    font-size: 0.94rem;
    line-height: 1.65;
    color: var(--text-medium);
    margin: 0;
}

.timeline-progress {
    margin-top: 18px;
    max-width: 460px;
}

.timeline-progress-meta {
    display: flex;
    justify-content: space-between;
    gap: 16px;
    font-family: var(--font-ui);
    font-size: 0.72rem;
    font-weight: 700;
    letter-spacing: 0.6px;
    color: var(--text-light);
    margin-top: 8px;
}


/* ============================================================
   WHO IT'S FOR
   ============================================================ */
.project-section-faces {
    background: var(--bg-white);
}

.faces-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 28px;
}

.face-card {
    display: flex;
    flex-direction: column;
    background: var(--bg-page);
    border: 1px solid rgba(30, 58, 138, 0.06);
    border-radius: var(--radius-card);
    overflow: hidden;
    transition: transform 0.35s ease, box-shadow 0.35s ease;
}

.face-card:hover {
    transform: translateY(-4px);
    box-shadow: var(--shadow-md);
}

.face-media {
    aspect-ratio: 1 / 1;
    overflow: hidden;
    background: #E5EAF3;
}

.face-media img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
    transition: transform 0.7s cubic-bezier(0.22, 0.61, 0.36, 1);
}

.face-card:hover .face-media img {
    transform: scale(1.05);
}

.face-body {
    padding: 22px 24px 26px;
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.face-name {
    font-family: var(--font-ui);
    font-size: 0.78rem;
    font-weight: 700;
    letter-spacing: 1.4px;
    text-transform: uppercase;
    color: var(--gold);
    margin: 0;
}

.face-quote {
    font-family: var(--font-serif);
    font-style: italic;
    font-size: 1.05rem;
    line-height: 1.55;
    color: var(--blue);
    margin: 0;
}


/* ============================================================
   FUNDING BREAKDOWN
   ============================================================ */
.project-section-funding {
    background: var(--bg-page);
}

.funding-grid {
    display: grid;
    grid-template-columns: 1.5fr 1fr;
    gap: 72px;
    align-items: start;
}

.funding-list {
    list-style: none;
    padding: 0;
    margin: 28px 0 0 0;
    border-top: 1px solid rgba(30, 58, 138, 0.10);
}

.funding-item {
    display: flex;
    justify-content: space-between;
    align-items: baseline;
    gap: 24px;
    padding: 16px 4px;
    border-bottom: 1px solid rgba(30, 58, 138, 0.08);
    font-family: var(--font-body);
}

.funding-label {
    font-size: 0.96rem;
    color: var(--text-medium);
}

.funding-amount {
    font-family: var(--font-serif);
    font-size: 1.05rem;
    font-weight: 700;
    color: var(--blue);
    letter-spacing: -0.005em;
    font-variant-numeric: tabular-nums;
    font-feature-settings: "tnum";
}

.funding-item-total {
    border-bottom: none;
    border-top: 2px solid rgba(30, 58, 138, 0.15);
    margin-top: 8px;
    padding-top: 20px;
}

.funding-item-total .funding-label {
    font-family: var(--font-ui);
    font-size: 0.78rem;
    font-weight: 700;
    letter-spacing: 1.4px;
    text-transform: uppercase;
    color: var(--blue);
}

.funding-item-total .funding-amount {
    font-size: 1.35rem;
}

/* Aside card */
.funding-aside {
    position: sticky;
    top: calc(var(--header-height) + 40px);
}

.funding-aside-card {
    background: #ffffff;
    border: 1px solid rgba(30, 58, 138, 0.08);
    border-radius: var(--radius-card);
    padding: 36px 32px 32px;
    box-shadow: var(--shadow-md);
    display: flex;
    flex-direction: column;
    gap: 18px;
}

.funding-aside-eyebrow {
    font-family: var(--font-ui);
    font-size: 0.68rem;
    font-weight: 700;
    letter-spacing: 1.8px;
    text-transform: uppercase;
    color: var(--text-light);
    margin: 0;
}

.funding-aside-value {
    font-family: var(--font-serif);
    font-size: 2.6rem;
    font-weight: 700;
    color: var(--blue);
    line-height: 1;
    letter-spacing: -0.02em;
    font-variant-numeric: tabular-nums;
    font-feature-settings: "tnum";
}

.funding-aside-note {
    font-family: var(--font-body);
    font-size: 0.92rem;
    line-height: 1.6;
    color: var(--text-medium);
    margin: 0;
}

.funding-aside-btn {
    display: block;
    text-align: center;
    margin-top: 6px;
}

.funding-aside-foot {
    font-family: var(--font-ui);
    font-size: 0.72rem;
    letter-spacing: 0.6px;
    color: var(--text-light);
    text-align: center;
    margin: 0;
}


/* ============================================================
   FINAL CTA — extras
   ============================================================ */
.final-cta-foot {
    font-family: var(--font-ui);
    font-size: 0.82rem;
    color: rgba(255, 255, 255, 0.7);
    margin: 24px 0 0 0;
}

.final-cta-foot a {
    color: var(--gold);
    text-decoration: underline;
    text-underline-offset: 3px;
}

.final-cta-foot a:hover {
    color: var(--gold-light);
}


/* ============================================================
   RESPONSIVE — Tablet
   ============================================================ */
@media (max-width: 1024px) {
    .project-hero { min-height: 620px; }
    .project-hero-inner { padding: 100px 40px 64px; }
    .project-hero-heading { font-size: 2.8rem; }
    .project-hero-lead { font-size: 1.02rem; }

    .project-hero-stats {
        grid-template-columns: repeat(2, 1fr);
        gap: 28px;
        max-width: 100%;
    }
    .project-stat-value { font-size: 1.9rem; }

    .project-section { padding: 90px 0; }
    .project-section-inner { padding: 0 40px; }
    .project-heading { font-size: 2.2rem; }

    .vision-grid {
        grid-template-columns: 1fr;
        gap: 40px;
    }
    .vision-media { position: static; aspect-ratio: 16 / 10; }

    .plans-grid { grid-template-columns: repeat(2, 1fr); gap: 20px; }
    .features-grid { grid-template-columns: repeat(2, 1fr); gap: 20px; }
    .faces-grid { grid-template-columns: repeat(3, 1fr); gap: 18px; }

    .funding-grid {
        grid-template-columns: 1fr;
        gap: 40px;
    }
    .funding-aside { position: static; }
    .funding-aside-card { max-width: 520px; }
}


/* ============================================================
   RESPONSIVE — Mobile
   ============================================================ */
@media (max-width: 768px) {
    .project-hero { min-height: 560px; }
    .project-hero::before { animation-duration: 30s; }
    .project-hero-inner { padding: 80px 24px 48px; }

    .breadcrumb {
        font-size: 0.62rem;
        letter-spacing: 1.1px;
        margin-bottom: 22px;
    }

    .project-hero-content { max-width: 100%; margin-bottom: 36px; }
    .project-hero-heading { font-size: 2rem; margin-bottom: 16px; }
    .project-hero-lead { font-size: 0.95rem; }

    .project-hero-stats {
        grid-template-columns: repeat(2, 1fr);
        gap: 20px;
        padding: 24px 0;
        margin-bottom: 28px;
    }
    .project-stat-value { font-size: 1.55rem; }
    .project-stat-label { font-size: 0.62rem; letter-spacing: 1.3px; }

    .project-section { padding: 64px 0; }
    .project-section-inner { padding: 0 24px; }
    .project-heading { font-size: 1.7rem; }
    .project-sub { font-size: 0.94rem; }
    .project-lead { font-size: 0.96rem; }

    .vision-media { aspect-ratio: 4 / 3; }
    .project-pullquote { padding: 18px 20px; }
    .project-pullquote p { font-size: 0.98rem; }

    .plans-grid { grid-template-columns: 1fr; gap: 16px; }
    .features-grid { grid-template-columns: 1fr; gap: 16px; }
    .feature-card { padding: 24px 22px; }
    .feature-icon { width: 46px; height: 46px; font-size: 1.15rem; margin-bottom: 16px; }

    .timeline { padding-left: 32px; }
    .timeline::before { left: 12px; }
    .timeline-marker { left: -32px; width: 28px; height: 28px; font-size: 0.64rem; }
    .timeline-title { font-size: 1.15rem; }
    .timeline-text { font-size: 0.9rem; }

    .faces-grid { grid-template-columns: 1fr; gap: 16px; }
    .face-body { padding: 20px 22px 24px; }

    .funding-item { padding: 14px 2px; }
    .funding-amount { font-size: 0.98rem; }
    .funding-item-total .funding-amount { font-size: 1.2rem; }
    .funding-aside-card { padding: 28px 24px 26px; }
    .funding-aside-value { font-size: 2.1rem; }
}


/* ============================================================
   RESPONSIVE — Small mobile
   ============================================================ */
@media (max-width: 480px) {
    .project-hero { min-height: 500px; }
    .project-hero-heading { font-size: 1.7rem; }
    .project-stat-value { font-size: 1.4rem; }
    .project-stat-label { font-size: 0.58rem; letter-spacing: 1.1px; }

    .project-heading { font-size: 1.5rem; }
    .project-sub { font-size: 0.88rem; }

    .timeline-title { font-size: 1.05rem; }
    .face-quote { font-size: 0.98rem; }
}


/* ============================================================
   REDUCED MOTION
   ============================================================ */
@media (prefers-reduced-motion: reduce) {
    .project-hero::before,
    .vision-media img,
    .plan-media img,
    .face-media img {
        animation: none !important;
        transition: none !important;
    }
}
/* ============================================================
   CORE VALUES — animated vertical rail
   ============================================================ */
.values-rail {
    position: relative;
    max-width: 880px;
    margin: 0 auto;
    padding-left: 60px;
}

/* The rail — a thin vertical line running the full height */
.values-rail::before {
    content: '';
    position: absolute;
    left: 16px;
    top: 0;
    bottom: 0;
    width: 2px;
    background: rgba(30, 58, 138, 0.10);
}

/* The progress layer — a gold gradient that fills from top
   as the user scrolls. Height is controlled by JS. */
.values-rail-progress {
    position: absolute;
    left: 16px;
    top: 0;
    width: 2px;
    height: 0;
    background: linear-gradient(
        to bottom,
        var(--gold) 0%,
        var(--gold-light) 100%
    );
    transition: height 0.15s linear;
    z-index: 2;
    box-shadow: 0 0 8px rgba(255, 217, 102, 0.4);
}

/* Each value */
.value-rail-item {
    position: relative;
    padding: 44px 0 44px 32px;
}

.value-rail-item:first-child {
    padding-top: 20px;
}

.value-rail-item:last-child {
    padding-bottom: 20px;
}

/* Node — the circular point on the rail */
.value-rail-node {
    position: absolute;
    left: -52px;
    top: 52px;
    width: 14px;
    height: 14px;
    border-radius: 50%;
    background: var(--bg-white);
    border: 2px solid rgba(30, 58, 138, 0.20);
    z-index: 3;
    transition:
        background 0.5s ease,
        border-color 0.5s ease,
        box-shadow 0.5s ease,
        transform 0.5s ease;
}

.value-rail-item:first-child .value-rail-node {
    top: 28px;
}

/* When the progress has reached this node, light it up */
.value-rail-item.active .value-rail-node {
    background: var(--gold);
    border-color: var(--gold);
    box-shadow:
        0 0 0 6px rgba(255, 217, 102, 0.18),
        0 0 20px rgba(255, 217, 102, 0.5);
    transform: scale(1.15);
}

/* Number + title */
.value-rail-num {
    display: block;
    font-family: var(--font-ui);
    font-size: 0.68rem;
    font-weight: 700;
    letter-spacing: 3px;
    text-transform: uppercase;
    color: var(--text-light);
    margin-bottom: 10px;
    transition: color 0.5s ease;
}

.value-rail-item.active .value-rail-num {
    color: var(--gold);
}

.value-rail-title {
    font-family: var(--font-serif);
    font-size: 1.65rem;
    font-weight: 700;
    line-height: 1.15;
    letter-spacing: -0.015em;
    color: var(--blue);
    margin: 0 0 14px 0;
    transition: color 0.5s ease;
}

.value-rail-text {
    font-family: var(--font-body);
    font-size: 0.98rem;
    line-height: 1.75;
    color: var(--text-medium);
    margin: 0;
    max-width: 620px;
    transition: color 0.5s ease;
}

/* Slight dimming on inactive rows for depth */
.value-rail-item:not(.active) .value-rail-title {
    color: rgba(30, 58, 138, 0.55);
}

.value-rail-item:not(.active) .value-rail-text {
    color: rgba(61, 61, 92, 0.55);
}

/* Responsive */
@media (max-width: 768px) {
    .values-rail {
        padding-left: 40px;
    }

    .values-rail::before,
    .values-rail-progress {
        left: 8px;
    }

    .value-rail-node {
        left: -40px;
        width: 12px;
        height: 12px;
    }

    .value-rail-item {
        padding: 32px 0 32px 20px;
    }

    .value-rail-title {
        font-size: 1.3rem;
    }
}