/* ===================================
    Client case study pages (/projects/{slug})
    Loaded by resources/views/project.blade.php only, via @push('styles'), so it is not in
    app.bundle.css and is not purged. Colours, fonts and the bd-* pieces come from codefix.css.

    The page is built on one idea: the reader is a buyer checking whether we can be trusted with
    the same job. So it reads top to bottom as evidence — who the client is, what was wrong,
    what we built, how long it took, and what we are still on the hook for.
====================================== */

/* .pf-icon and .pf-tags are borrowed from the profile pages. They are repeated here rather than
   shared, because founder.css is scoped to the two profile pages and is not loaded on this one. */
.pf-icon {
    flex-shrink: 0;
    width: 48px;
    height: 48px;
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 21px;
    color: var(--base-color);
    background: rgba(var(--base-color-rgb), 0.08);
}
.pf-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin: 0;
    padding: 0;
    list-style: none;
}
.pf-tags li {
    padding: 4px 12px;
    border-radius: 50px;
    background: var(--base-color-tint);
    color: var(--dark-gray);
    font-size: 14px;
    font-weight: 500;
    line-height: 22px;
}

/* ===== hero ===== */
/* dark, like the profile hero, so a case study reads as a piece about someone else rather than
   as another service page. On the navy, accents use the light cyan (8.6:1) and body copy 72% white. */
.cs-hero {
    padding: 60px 0 140px;
    background-color: var(--charcoal-blue);
    background-image: radial-gradient(circle at 88% 15%, rgba(var(--secondary-color-rgb), 0.2), transparent 45%),
        radial-gradient(circle at 0% 95%, rgba(var(--base-color-rgb), 0.6), transparent 52%);
    color: rgba(255, 255, 255, 0.72);
}
/* a faint grid, faded out towards the edges */
.cs-hero::before {
    content: '';
    position: absolute;
    inset: 0;
    background-image: linear-gradient(rgba(255, 255, 255, 0.05) 1px, transparent 1px),
        linear-gradient(90deg, rgba(255, 255, 255, 0.05) 1px, transparent 1px);
    background-size: 56px 56px;
    -webkit-mask-image: radial-gradient(ellipse at 55% 35%, #000 10%, transparent 72%);
    mask-image: radial-gradient(ellipse at 55% 35%, #000 10%, transparent 72%);
    pointer-events: none;
}
.cs-breadcrumb {
    margin-bottom: 34px;
}
.cs-breadcrumb ol {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 8px;
    margin: 0;
    padding: 0;
    list-style: none;
    font-size: 14px;
    line-height: 22px;
}
.cs-breadcrumb li + li::before {
    content: '/';
    margin-right: 8px;
    color: rgba(255, 255, 255, 0.35);
}
.cs-breadcrumb a {
    color: rgba(255, 255, 255, 0.66);
}
.cs-breadcrumb a:hover {
    color: #fff;
}
.cs-breadcrumb li[aria-current] {
    color: var(--secondary-color-light);
}
.cs-tag {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    max-width: 100%;
    margin-bottom: 26px;
    padding: 6px 16px 6px 12px;
    border: 1px solid rgba(255, 255, 255, 0.16);
    border-radius: 50px;
    background: rgba(255, 255, 255, 0.06);
    color: #fff;
    font-size: 14px;
    font-weight: 500;
    line-height: 22px;
}
.cs-tag i {
    flex-shrink: 0;
    color: var(--secondary-color-light);
}
.cs-hero-title {
    font-size: 50px;
    line-height: 1.1;
    letter-spacing: -1.8px;
    color: #fff;
    margin-bottom: 22px;
}
.cs-hero-lede {
    max-width: 640px;
    font-size: 18px;
    line-height: 32px;
    margin-bottom: 34px;
}
.cs-hero-actions {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 16px;
}
.cs-btn-ghost {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    height: 54px;
    padding: 0 26px;
    border: 1px solid rgba(255, 255, 255, 0.25);
    border-radius: 6px;
    color: #fff;
    font-size: 16px;
    font-weight: 600;
    line-height: 1;
    transition: border-color 0.2s ease, background-color 0.2s ease;
}
.cs-btn-ghost:hover {
    border-color: #fff;
    background: rgba(255, 255, 255, 0.08);
    color: #fff;
}

/* the client card: the logo, the facts a buyer scans first, and the commitment we are still under */
.cs-client-card {
    padding: 30px;
    border: 1px solid rgba(255, 255, 255, 0.14);
    border-radius: 18px;
    background: rgba(255, 255, 255, 0.05);
    -webkit-backdrop-filter: blur(6px);
    backdrop-filter: blur(6px);
}
/* the mark is a colour logo drawn for white paper, so it gets white paper */
.cs-client-plate {
    display: flex;
    align-items: center;
    justify-content: center;
    height: 128px;
    margin-bottom: 22px;
    padding: 16px 28px;
    border-radius: 12px;
    background: #fff;
}
/* a logo already drawn light sits straight on the navy: a white plate would bleach it out */
.cs-client-plate--bare {
    height: auto;
    min-height: 64px;
    padding: 0 0 4px;
    background: none;
}
.cs-client-plate img {
    max-width: 100%;
    max-height: 100%;
    width: auto;
    height: auto;
    object-fit: contain;
}
.cs-client-name {
    display: block;
    margin-bottom: 20px;
    font-size: 18px;
    font-weight: 600;
    line-height: 26px;
    color: #fff;
}
.cs-client-meta {
    margin: 0 0 22px;
    padding: 0;
}
.cs-client-meta > div {
    display: flex;
    gap: 16px;
    padding: 11px 0;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
}
.cs-client-meta dt {
    flex: 0 0 96px;
    font-size: 13px;
    font-weight: 500;
    line-height: 22px;
    letter-spacing: 0.3px;
    text-transform: uppercase;
    color: rgba(255, 255, 255, 0.5);
}
.cs-client-meta dd {
    margin: 0;
    font-size: 15px;
    line-height: 22px;
    color: #fff;
}
.cs-client-badge {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 12px 16px;
    border-radius: 10px;
    background: rgba(var(--secondary-color-rgb), 0.14);
    color: var(--secondary-color-light);
    font-size: 14px;
    font-weight: 600;
    line-height: 22px;
}
.cs-client-badge i {
    flex-shrink: 0;
    font-size: 17px;
}

/* ===== engagement facts ===== */
.cs-proof {
    padding-bottom: 80px;
}

/* ===== the client ===== */
.cs-facts {
    margin: 0;
    padding: 26px;
    list-style: none;
    border: 1px solid var(--extra-medium-gray);
    border-radius: 16px;
    background: #fff;
}
.cs-facts li {
    display: flex;
    align-items: center;
    gap: 16px;
    padding: 16px 0;
    border-top: 1px solid var(--extra-medium-gray);
}
.cs-facts li:first-child {
    padding-top: 0;
    border-top: 0;
}
.cs-facts li:last-child {
    padding-bottom: 0;
}
.cs-fact-label {
    display: block;
    font-size: 13px;
    font-weight: 500;
    line-height: 20px;
    letter-spacing: 0.3px;
    text-transform: uppercase;
    color: var(--medium-gray);
}
.cs-fact-value {
    display: block;
    font-size: 16px;
    font-weight: 600;
    line-height: 24px;
    color: var(--dark-gray);
}
.cs-industries {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 16px 30px;
    margin-top: 55px;
    padding-top: 35px;
    border-top: 1px solid var(--extra-medium-gray);
}
.cs-industries-label {
    flex-shrink: 0;
    font-size: 13px;
    font-weight: 600;
    letter-spacing: 0.6px;
    text-transform: uppercase;
    color: var(--medium-gray);
}

/* ===== the brief ===== */
/* the problems are stated plainly and without a fix attached: the fixes are the next section */
.cs-problem {
    display: flex;
    gap: 18px;
    height: 100%;
    padding: 30px;
    border-radius: 16px;
    background: #fff;
    box-shadow: 0 12px 40px rgba(29, 29, 58, 0.06);
}
.cs-problem-icon {
    flex-shrink: 0;
    width: 46px;
    height: 46px;
    border-radius: 12px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-size: 20px;
    color: var(--warning-color);
    background: rgba(var(--warning-color-rgb), 0.1);
}
.cs-problem-title {
    font-size: 19px;
    line-height: 27px;
    margin-bottom: 8px;
}

/* ===== what we built ===== */
.cs-app-head {
    display: flex;
    align-items: flex-start;
    gap: 20px;
    margin-bottom: 34px;
    padding-bottom: 26px;
    border-bottom: 1px solid var(--extra-medium-gray);
}
.cs-app-icon {
    flex-shrink: 0;
    width: 56px;
    height: 56px;
    border-radius: 14px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-size: 24px;
    color: #fff;
    background-image: linear-gradient(135deg, var(--base-color) 0%, var(--brand-mid) 100%);
}
.cs-app-name {
    font-size: 26px;
    line-height: 34px;
    letter-spacing: -0.5px;
    margin-bottom: 6px;
}
.cs-app-head p {
    max-width: 760px;
}
.cs-module {
    height: 100%;
    padding: 28px;
    border: 1px solid var(--extra-medium-gray);
    border-radius: 16px;
    background: #fff;
    transition: border-color 0.25s ease, transform 0.25s ease, box-shadow 0.25s ease;
}
.cs-module:hover {
    border-color: rgba(var(--base-color-rgb), 0.3);
    transform: translateY(-4px);
    box-shadow: 0 18px 45px rgba(29, 29, 58, 0.08);
}
.cs-module-title {
    font-size: 18px;
    line-height: 26px;
    margin: 18px 0 8px;
}
.cs-module p {
    font-size: 15px;
    line-height: 26px;
}

/* ===== how it ran ===== */
/* a dated spine: the date is a column of its own on desktop so the nine months are scannable */
.cs-timeline {
    position: relative;
    max-width: 900px;
    margin: 0 auto;
    padding: 0;
    list-style: none;
}
.cs-phase {
    position: relative;
    display: grid;
    grid-template-columns: 150px 1fr;
    gap: 30px;
    padding-bottom: 34px;
}
.cs-phase:last-child {
    padding-bottom: 0;
}
/* the spine itself, drawn between the two columns */
.cs-phase::before {
    content: '';
    position: absolute;
    top: 20px;
    bottom: -6px;
    left: 155px;
    width: 1px;
    background: var(--extra-medium-gray);
}
.cs-phase:last-child::before {
    display: none;
}
/* the dot on the spine */
.cs-phase::after {
    content: '';
    position: absolute;
    top: 12px;
    left: 150px;
    width: 11px;
    height: 11px;
    border-radius: 50%;
    border: 2px solid #fff;
    background: var(--base-color);
}
.cs-phase-date {
    padding-top: 6px;
    text-align: right;
    font-size: 15px;
    font-weight: 600;
    line-height: 24px;
    color: var(--medium-gray);
}
.cs-phase-body {
    padding-left: 14px;
}
/* the title, with the client's own mark pushed to the far side where we have one */
.cs-phase-head {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 24px;
}
.cs-phase-title {
    font-size: 20px;
    line-height: 28px;
    margin-bottom: 8px;
}
.cs-phase-logo {
    flex-shrink: 0;
    height: 28px;
    width: auto;
    max-width: 140px;
    margin-top: 2px;
    filter: grayscale(1);
    opacity: 0.55;
    transition: filter 0.3s ease, opacity 0.3s ease;
}
.cs-phase:hover .cs-phase-logo {
    filter: none;
    opacity: 1;
}
.cs-phase-body p {
    font-size: 15px;
    line-height: 27px;
}
/* the phase we are still in: cyan dot with a halo, and its own card */
.cs-phase--current::after {
    background: var(--secondary-color);
    box-shadow: 0 0 0 5px rgba(var(--secondary-color-rgb), 0.18);
}
.cs-phase--current .cs-phase-date {
    color: var(--secondary-color-text);
}
.cs-phase--current .cs-phase-body {
    margin-left: 4px;
    padding: 22px 26px;
    border-radius: 14px;
    background: #fff;
    box-shadow: 0 12px 40px rgba(29, 29, 58, 0.07);
}

/* ===== how it was built ===== */
.cs-stack {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 24px;
}
.cs-stack-group {
    padding: 28px;
    border: 1px solid var(--extra-medium-gray);
    border-radius: 16px;
    background: #fff;
}
.cs-stack-name {
    font-size: 18px;
    font-weight: 600;
    line-height: 26px;
    color: var(--dark-gray);
    margin: 18px 0 14px;
}
.cs-principle {
    height: 100%;
    padding: 28px;
    border-radius: 16px;
    background: var(--base-color-tint);
}
.cs-principle-icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 42px;
    height: 42px;
    margin-bottom: 16px;
    border-radius: 10px;
    font-size: 19px;
    color: #fff;
    background: var(--base-color);
}
.cs-principle-title {
    font-size: 18px;
    line-height: 26px;
    margin-bottom: 8px;
}
.cs-principle p {
    font-size: 15px;
    line-height: 26px;
}

/* ===== the outcome ===== */
.cs-outcomes {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 26px 40px;
    max-width: 1040px;
    margin: 0 auto;
    padding: 0;
    list-style: none;
}
.cs-outcome {
    display: flex;
    gap: 16px;
}
.cs-outcome > i {
    flex-shrink: 0;
    margin-top: 4px;
    font-size: 21px;
    color: var(--success-color);
}
.cs-outcome-title {
    display: block;
    font-size: 18px;
    font-weight: 600;
    line-height: 26px;
    color: var(--dark-gray);
    margin-bottom: 6px;
}
.cs-outcome p {
    font-size: 15px;
    line-height: 26px;
}

/* ===== still our responsibility ===== */
/* the one dark panel below the fold: the four-year commitment is the strongest thing on the page */
.cs-support {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 50px;
    padding: 55px;
    border-radius: 22px;
    background-color: var(--charcoal-blue);
    background-image: radial-gradient(circle at 90% 10%, rgba(var(--secondary-color-rgb), 0.22), transparent 50%);
    color: rgba(255, 255, 255, 0.72);
}
.cs-support-eyebrow {
    display: inline-flex;
    align-items: center;
    margin-bottom: 12px;
    font-family: var(--alt-font);
    font-size: 14px;
    font-weight: 700;
    line-height: 20px;
    letter-spacing: 0.5px;
    text-transform: uppercase;
    color: var(--secondary-color-light);
}
.cs-support-eyebrow::before {
    content: '';
    width: 25px;
    height: 1px;
    margin-right: 8px;
    background: var(--secondary-color-light);
}
.cs-support-title {
    font-size: 34px;
    line-height: 1.2;
    letter-spacing: -1px;
    color: #fff;
    margin-bottom: 16px;
}
/* the way on to the product this work feeds, when the case study has one */
.cs-support-link {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    margin-top: 24px;
    padding-bottom: 3px;
    border-bottom: 1px solid rgba(var(--secondary-color-rgb), 0.45);
    color: var(--secondary-color-light);
    font-size: 16px;
    font-weight: 600;
    line-height: 26px;
}
.cs-support-link i {
    transition: transform 0.2s ease;
}
.cs-support-link:hover {
    border-bottom-color: var(--secondary-color-light);
    color: #fff;
}
.cs-support-link:hover i {
    transform: translateX(4px);
}
.cs-support-items {
    display: grid;
    gap: 18px;
    align-content: center;
    margin: 0;
    padding: 0;
    list-style: none;
}
.cs-support-items li {
    display: flex;
    gap: 16px;
    padding: 20px 22px;
    border: 1px solid rgba(255, 255, 255, 0.12);
    border-radius: 14px;
    background: rgba(255, 255, 255, 0.05);
}
.cs-support-items i {
    flex-shrink: 0;
    margin-top: 3px;
    font-size: 20px;
    color: var(--secondary-color-light);
}
.cs-support-item-title {
    display: block;
    font-size: 17px;
    font-weight: 600;
    line-height: 26px;
    color: #fff;
}
.cs-support-item-text {
    display: block;
    font-size: 15px;
    line-height: 25px;
}

/* ===== closing call to action ===== */
.cs-cta {
    display: flex;
    align-items: center;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 30px;
    margin-top: 40px;
    padding: 40px 45px;
    border: 1px solid var(--extra-medium-gray);
    border-radius: 18px;
    background: var(--base-color-tint);
}
.cs-cta-title {
    display: block;
    font-size: 24px;
    line-height: 32px;
    letter-spacing: -0.5px;
    margin-bottom: 6px;
}
.cs-cta-text {
    display: block;
    max-width: 640px;
    font-size: 16px;
    line-height: 28px;
    color: var(--medium-gray);
}
.cs-cta-actions {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 16px 26px;
}
.cs-cta-actions .btn {
    margin-right: 0;
}

/* ===== responsive ===== */
@media (max-width: 1199px) {
    .cs-hero-title {
        font-size: 42px;
        letter-spacing: -1.4px;
    }
    .cs-stack {
        grid-template-columns: repeat(2, 1fr);
    }
    .cs-support {
        padding: 45px;
    }
}
@media (max-width: 991px) {
    .cs-hero {
        padding: 40px 0 110px;
    }
    .cs-client-card {
        max-width: 520px;
        margin: 0 auto;
    }
    .cs-facts {
        max-width: 520px;
    }
    .cs-support {
        grid-template-columns: 1fr;
        gap: 34px;
    }
    .cs-outcomes {
        gap: 24px 34px;
    }
}
@media (max-width: 767px) {
    .cs-hero-title {
        font-size: 34px;
        letter-spacing: -1px;
    }
    .cs-hero-lede {
        font-size: 17px;
        line-height: 30px;
    }
    .cs-app-head {
        flex-direction: column;
        gap: 16px;
    }
    .cs-app-name {
        font-size: 23px;
        line-height: 31px;
    }
    /* the dated spine collapses to a single column: the date becomes a label above the phase */
    .cs-phase {
        grid-template-columns: 1fr;
        gap: 6px;
        padding-left: 26px;
        padding-bottom: 28px;
    }
    .cs-phase::before {
        top: 22px;
        left: 5px;
    }
    .cs-phase::after {
        top: 7px;
        left: 0;
    }
    .cs-phase-date {
        padding-top: 0;
        text-align: left;
    }
    .cs-phase-body {
        padding-left: 0;
    }
    .cs-phase-head {
        flex-direction: column-reverse;
        align-items: flex-start;
        gap: 12px;
    }
    .cs-phase-logo {
        margin-top: 0;
    }
    .cs-phase--current .cs-phase-body {
        margin-left: 0;
        padding: 20px 22px;
    }
    .cs-stack {
        grid-template-columns: 1fr;
    }
    .cs-outcomes {
        grid-template-columns: 1fr;
    }
    .cs-support {
        padding: 36px 26px;
        border-radius: 18px;
    }
    .cs-support-title {
        font-size: 28px;
    }
    .cs-cta {
        padding: 32px 26px;
    }
}
@media (max-width: 575px) {
    .cs-hero-actions .btn,
    .cs-btn-ghost {
        width: 100%;
        justify-content: center;
    }
    .cs-client-card {
        padding: 22px;
    }
    .cs-client-meta > div {
        flex-direction: column;
        gap: 2px;
    }
    /* the row stacks, so the label's 96px flex-basis would become a 96px height */
    .cs-client-meta dt {
        flex: none;
    }
    .cs-problem {
        flex-direction: column;
        gap: 14px;
        padding: 26px;
    }
    .cs-industries {
        flex-direction: column;
        align-items: flex-start;
        gap: 14px;
    }
    .cs-cta-actions {
        width: 100%;
    }
    .cs-cta-actions .btn {
        width: 100%;
        justify-content: center;
    }
}
@media (prefers-reduced-motion: reduce) {
    .cs-module,
    .cs-btn-ghost {
        transition: none;
    }
    .cs-module:hover {
        transform: none;
    }
}
