/*
 * WireSync public homepage chapters.
 *
 * This stylesheet is intentionally homepage-scoped. It builds on the existing
 * WireSync tokens and components without changing protected customer or Crown
 * Admin screens.
 */

.mf-public-home {
    --mf-home-content-width: 1440px;
    --mf-home-header-height: 5.1rem;
    --mf-home-progress-height: 3.8rem;
    --mf-home-scene-width: 1600px;
    --mf-home-sticky-offset: calc(var(--mf-home-header-height) + var(--mf-home-progress-height));
    --mf-home-header-offset: calc(var(--mf-home-sticky-offset) + 1rem);
    --mf-home-photo-radius: 24px;
}

.mf-public-home .mf-home-main {
    background: #020711;
    overflow: visible;
    padding: clamp(0.55rem, 1.35vw, 1.25rem);
}

/* Keep the promise prominent while letting proof enter the first viewport. */
.mf-public-home .mf-hero {
    background:
        radial-gradient(circle at 82% 16%, rgba(37, 99, 235, 0.2), transparent 34%),
        linear-gradient(145deg, #081525, #050b14 72%);
    border: 1px solid rgba(96, 165, 250, 0.18);
    border-radius: clamp(20px, 2.5vw, 34px);
    box-shadow: 0 30px 90px rgba(0, 0, 0, 0.36);
    box-sizing: border-box;
    gap: clamp(1.25rem, 3vw, 1.75rem);
    margin: 0 auto clamp(1rem, 2vw, 1.75rem);
    max-width: var(--mf-home-scene-width);
    min-height: calc(100svh - var(--mf-home-sticky-offset) - 2rem);
    position: relative;
}

.mf-public-home .mf-hero h1 {
    font-size: clamp(2.75rem, 5.25vw, 5.25rem);
    max-width: 1040px;
}

.mf-public-home .mf-hero-subheading {
    max-width: 850px;
}

/* The approved product diagram keeps its own coordinate system. This wrapper
 * clips only that visual, leaving sticky scene identity free to work below.
 */
.mf-public-home .mf-hero-visual-stage {
    max-width: 100%;
    overflow: clip;
    position: relative;
    width: 100%;
}

.mf-public-home .mf-hero-visual-stage .visual-flow-container {
    left: 50%;
    margin: 0;
    position: absolute;
    top: 0;
}

.mf-public-home .mf-home-snap-point,
.mf-public-home .mf-home-main [id] {
    scroll-margin-top: var(--mf-home-header-offset);
}

/* A compact chapter rail makes the page position visible at every viewport.
 * Every item remains a standard fragment link when JavaScript is unavailable.
 */
.mf-public-home .mf-home-scene-progress {
    backdrop-filter: blur(18px);
    background: rgba(3, 10, 20, 0.9);
    border-bottom: 1px solid rgba(96, 165, 250, 0.18);
    box-sizing: border-box;
    min-height: var(--mf-home-progress-height);
    padding: 0.42rem clamp(0.65rem, 3vw, 2.5rem);
    position: sticky;
    top: var(--mf-home-header-height);
    z-index: 90;
}

.mf-public-home .mf-home-scene-progress-track {
    display: grid;
    gap: clamp(0.25rem, 0.75vw, 0.7rem);
    grid-template-columns: repeat(8, minmax(0, 1fr));
    margin: 0 auto;
    max-width: var(--mf-home-scene-width);
}

.mf-public-home .mf-home-scene-link {
    align-items: center;
    border: 1px solid rgba(148, 163, 184, 0.16);
    border-radius: 999px;
    color: #94a3b8;
    display: grid;
    font-size: 0.68rem;
    gap: 0.08rem;
    line-height: 1.08;
    min-height: 2.85rem;
    padding: 0.35rem 0.58rem;
    text-decoration: none;
    transition: background-color 180ms ease, border-color 180ms ease, color 180ms ease, transform 180ms ease;
}

.mf-public-home .mf-home-scene-link span {
    font-size: 0.62rem;
    font-weight: 850;
    letter-spacing: 0.08em;
    text-transform: uppercase;
}

.mf-public-home .mf-home-scene-link strong {
    font-weight: 800;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.mf-public-home .mf-home-scene-link:hover,
.mf-public-home .mf-home-scene-link:focus-visible {
    background: rgba(59, 130, 246, 0.12);
    border-color: rgba(96, 165, 250, 0.4);
    color: #dbeafe;
}

.mf-public-home .mf-home-scene-link:focus-visible {
    outline: 3px solid #60a5fa;
    outline-offset: 2px;
}

.mf-public-home .mf-home-scene-link[aria-current="location"] {
    background: linear-gradient(135deg, #2563eb, #0ea5e9);
    border-color: #93c5fd;
    box-shadow: 0 8px 24px rgba(37, 99, 235, 0.3);
    color: #ffffff;
    transform: translateY(-1px);
}

/* The fallback is shown only where the full header navigation is replaced. */
.mf-public-home .mf-public-noscript-nav {
    display: none;
}

/*
 * The active link is a quiet moving location marker. JavaScript supplies
 * aria-current="location", while every link remains a normal anchor.
 */
.mf-public-home .mf-public-nav {
    gap: 0.35rem;
}

.mf-public-home .mf-public-nav a[data-home-nav] {
    border: 1px solid transparent;
    border-radius: 999px;
    padding: 0.55rem 0.78rem;
    transition:
        background-color 220ms ease,
        border-color 220ms ease,
        box-shadow 220ms ease,
        color 220ms ease;
}

.mf-public-home .mf-public-nav a[data-home-nav][aria-current="location"] {
    background: rgba(59, 130, 246, 0.16);
    border-color: rgba(96, 165, 250, 0.42);
    box-shadow: 0 8px 22px rgba(2, 8, 23, 0.22);
    color: #ffffff;
}

.mf-public-home.mf-theme-light .mf-public-nav a[data-home-nav][aria-current="location"] {
    background: rgba(37, 99, 235, 0.1);
    border-color: rgba(37, 99, 235, 0.24);
    box-shadow: 0 8px 22px rgba(37, 99, 235, 0.1);
    color: #1d4ed8;
}

/*
 * Chapters provide the stronger tonal rhythm requested by the owner. The
 * child sections keep their established components and readable line lengths.
 */
.mf-public-home .mf-home-chapter {
    border: 1px solid rgba(148, 163, 184, 0.16);
    border-radius: clamp(18px, 2.4vw, 32px);
    box-shadow: 0 28px 80px rgba(0, 0, 0, 0.3);
    isolation: isolate;
    margin: 0 auto clamp(1rem, 2vw, 1.75rem);
    max-width: var(--mf-home-scene-width);
    min-height: calc(100svh - var(--mf-home-sticky-offset) - 2rem);
    position: relative;
    transition:
        border-color 420ms ease,
        box-shadow 420ms ease;
}

.mf-public-home .mf-home-chapter::before {
    background:
        radial-gradient(circle at 14% 18%, rgba(59, 130, 246, 0.12), transparent 34%),
        linear-gradient(90deg, rgba(255, 255, 255, 0.025), transparent 28%);
    content: "";
    border-radius: inherit;
    inset: 0;
    opacity: 0.72;
    pointer-events: none;
    position: absolute;
    transition: opacity 420ms ease, transform 520ms cubic-bezier(0.22, 1, 0.36, 1);
    transform: scale(0.998);
    z-index: -1;
}

.mf-public-home .mf-home-chapter.is-active {
    border-color: rgba(96, 165, 250, 0.3);
    box-shadow:
        inset 4px 0 0 rgba(59, 130, 246, 0.72),
        inset 0 24px 70px rgba(59, 130, 246, 0.035);
}

.mf-public-home .mf-home-chapter.is-active::before {
    opacity: 1;
    transform: scale(1);
}

.mf-public-home .mf-home-chapter-intro {
    background: rgba(6, 14, 25, 0.82);
}

.mf-public-home .mf-home-chapter-process {
    background:
        radial-gradient(circle at 85% 16%, rgba(37, 99, 235, 0.2), transparent 36%),
        #0b1a30;
}

.mf-public-home .mf-home-chapter-result {
    background:
        linear-gradient(145deg, rgba(15, 23, 42, 0.72), rgba(4, 12, 22, 0.94));
}

.mf-public-home .mf-home-chapter-review {
    background:
        radial-gradient(circle at 12% 72%, rgba(14, 165, 233, 0.13), transparent 32%),
        #07111f;
}

.mf-public-home .mf-home-chapter-connect {
    background:
        radial-gradient(circle at 88% 22%, rgba(16, 185, 129, 0.1), transparent 30%),
        linear-gradient(150deg, #071722, #08111e);
}

.mf-public-home .mf-home-chapter-decide {
    background:
        radial-gradient(circle at 14% 18%, rgba(99, 102, 241, 0.1), transparent 32%),
        #111827;
}

.mf-public-home .mf-home-chapter-help {
    background: #050b14;
}

.mf-public-home .mf-home-chapter > .mf-section,
.mf-public-home .mf-home-chapter > .mf-final-cta,
.mf-public-home .mf-home-chapter > .mf-logo-strip {
    background: transparent;
    box-sizing: border-box;
    margin-inline: auto;
    max-width: var(--mf-home-content-width);
    width: 100%;
}

.mf-public-home .mf-home-chapter > .mf-section:first-of-type {
    padding-top: clamp(1.5rem, 4vw, 3rem);
}

.mf-public-home .mf-home-chapter-marker {
    align-items: center;
    color: var(--mf-muted);
    display: flex;
    font-size: 0.76rem;
    font-weight: 850;
    gap: 0.7rem;
    letter-spacing: 0.11em;
    margin: 0 auto;
    max-width: var(--mf-home-content-width);
    padding: 0.72rem clamp(1rem, 6vw, 5rem);
    position: sticky;
    top: calc(var(--mf-home-sticky-offset) + 0.35rem);
    text-transform: uppercase;
    transition: color 360ms ease, transform 460ms cubic-bezier(0.22, 1, 0.36, 1);
    z-index: 12;
}

.mf-public-home .mf-home-chapter-marker span:last-child {
    backdrop-filter: blur(14px);
    background: rgba(5, 11, 20, 0.82);
    border: 1px solid rgba(148, 163, 184, 0.18);
    border-radius: 999px;
    overflow: hidden;
    padding: 0.52rem 0.78rem;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.mf-public-home .mf-home-chapter-marker span:first-child {
    align-items: center;
    background: rgba(59, 130, 246, 0.14);
    border: 1px solid rgba(96, 165, 250, 0.34);
    border-radius: 999px;
    color: #93c5fd;
    display: inline-flex;
    height: 2rem;
    justify-content: center;
    letter-spacing: 0;
    width: 2rem;
}

.mf-public-home .mf-home-chapter-marker::after {
    background: linear-gradient(90deg, #3b82f6, rgba(59, 130, 246, 0));
    bottom: 0;
    content: "";
    height: 2px;
    left: clamp(1rem, 6vw, 5rem);
    position: absolute;
    transform: scaleX(0.18);
    transform-origin: left;
    transition: transform 520ms cubic-bezier(0.22, 1, 0.36, 1);
    width: min(15rem, 36vw);
}

.mf-public-home .mf-home-chapter.is-active .mf-home-chapter-marker::after {
    transform: scaleX(1);
}

.mf-public-home .mf-home-chapter.is-active .mf-home-chapter-marker {
    color: #dbeafe;
    transform: translateY(-2px);
}

.mf-public-home .mf-home-chapter.is-active .mf-home-chapter-marker span:first-child {
    transform: scale(1.06);
}

.mf-public-home .mf-home-chapter-marker span:first-child {
    transition: background-color 360ms ease, border-color 360ms ease, transform 460ms cubic-bezier(0.22, 1, 0.36, 1);
}

/*
 * Split editorial layouts pair the product story with real-feeling original
 * business scenes. Copy stays first in the DOM for a sensible mobile reading
 * order.
 */
.mf-public-home .mf-home-split {
    align-items: center;
    display: grid;
    gap: clamp(1.6rem, 4vw, 4.25rem);
    grid-template-columns: minmax(0, 0.9fr) minmax(360px, 1.1fr);
}

.mf-public-home .mf-home-split-copy {
    min-width: 0;
}

.mf-public-home .mf-home-split-copy > p:not(.mf-eyebrow) {
    color: var(--mf-muted);
    font-size: clamp(1rem, 1.6vw, 1.15rem);
    line-height: 1.7;
    max-width: 42rem;
}

.mf-public-home .mf-home-split-media-left > .mf-home-photo {
    grid-column: 1;
    grid-row: 1;
}

.mf-public-home .mf-home-split-media-left > .mf-home-split-copy {
    grid-column: 2;
    grid-row: 1;
}

.mf-public-home .mf-home-photo {
    background: #0b1422;
    border: 1px solid rgba(148, 163, 184, 0.24);
    border-radius: var(--mf-home-photo-radius);
    box-shadow:
        0 32px 70px rgba(0, 0, 0, 0.34),
        0 0 0 1px rgba(255, 255, 255, 0.025) inset;
    margin: 0;
    overflow: hidden;
    position: relative;
}

.mf-public-home .mf-home-photo img {
    aspect-ratio: 8 / 5;
    display: block;
    height: auto;
    object-fit: cover;
    transition:
        filter 500ms ease,
        transform 700ms cubic-bezier(0.22, 1, 0.36, 1);
    width: 100%;
}

.mf-public-home .mf-home-chapter.is-active .mf-home-photo img {
    transform: scale(1.01);
}

.mf-public-home .mf-home-photo::after {
    background: linear-gradient(180deg, transparent 55%, rgba(2, 8, 23, 0.78));
    content: "";
    inset: 0;
    pointer-events: none;
    position: absolute;
}

.mf-public-home .mf-home-photo figcaption {
    bottom: 0;
    color: #f8fafc;
    font-size: 0.82rem;
    font-weight: 700;
    left: 0;
    line-height: 1.45;
    max-width: 34rem;
    padding: 1rem 1.15rem;
    position: absolute;
    right: 0;
    z-index: 1;
}

@media (hover: hover) and (pointer: fine) {
    .mf-public-home .mf-home-photo:hover img {
        filter: saturate(1.05);
        transform: scale(1.018);
    }
}

/*
 * Replace a long list of isolated facts with three customer-readable groups.
 * The information remains on the page without exposing Crown-only cost data.
 */
.mf-public-home .mf-home-capture-grid {
    display: grid;
    gap: 1rem;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    margin-top: 1.8rem;
}

.mf-public-home .mf-home-capture-grid article {
    background: var(--mf-card);
    border: 1px solid var(--mf-border);
    border-radius: 18px;
    box-shadow: var(--mf-shadow);
    padding: clamp(1.25rem, 2.5vw, 1.8rem);
}

.mf-public-home .mf-home-capture-grid h3 {
    color: var(--mf-navy);
    font-size: 1.18rem;
    margin: 0 0 0.8rem;
}

.mf-public-home .mf-home-capture-grid ul {
    color: var(--mf-muted);
    display: grid;
    gap: 0.55rem;
    line-height: 1.5;
    list-style: none;
    margin: 0;
    padding: 0;
}

.mf-public-home .mf-home-capture-grid li {
    padding-left: 1.15rem;
    position: relative;
}

.mf-public-home .mf-home-capture-grid li::before {
    background: #60a5fa;
    border-radius: 50%;
    content: "";
    height: 0.38rem;
    left: 0;
    position: absolute;
    top: 0.56rem;
    width: 0.38rem;
}

/*
 * The four-part product story stays a normal grid until JavaScript confirms
 * that the optional swipe, mouse and keyboard controls are available.
 */
.mf-public-home .mf-lifecycle-carousel {
    margin-top: 1.5rem;
    max-width: 100%;
    min-width: 0;
    position: relative;
    width: 100%;
}

.mf-public-home .mf-lifecycle-track {
    margin-top: 0;
    max-width: 100%;
    min-width: 0;
}

.mf-public-home .mf-lifecycle-carousel.is-enhanced .mf-lifecycle-track {
    --mf-lifecycle-card-width: clamp(16rem, calc((100% - 1rem) / 2.15), 34rem);
    align-items: stretch;
    display: grid;
    gap: 1rem;
    grid-auto-columns:
        var(--mf-lifecycle-card-width)
        var(--mf-lifecycle-card-width)
        var(--mf-lifecycle-card-width)
        var(--mf-lifecycle-card-width)
        max(0px, calc(100% - var(--mf-lifecycle-card-width)));
    grid-auto-flow: column;
    grid-template-columns: none;
    max-width: 100%;
    overflow-x: auto;
    overscroll-behavior-inline: contain;
    padding-block: 0.25rem 0.8rem;
    padding-inline: 0;
    scroll-behavior: smooth;
    scroll-padding-inline: 0.1rem;
    scroll-snap-type: x proximity;
    scrollbar-color: rgba(96, 165, 250, 0.62) rgba(148, 163, 184, 0.14);
    scrollbar-gutter: stable;
    scrollbar-width: thin;
    touch-action: pan-x pan-y pinch-zoom;
}

/* Forced realignment must remain instant even when normal motion is smooth. */
.mf-public-home .mf-lifecycle-carousel.is-enhanced .mf-lifecycle-track.is-instant {
    scroll-behavior: auto !important;
}

/* An invisible fifth grid item gives every real stage its own snap position. */
.mf-public-home .mf-lifecycle-carousel.is-enhanced .mf-lifecycle-track::after {
    content: "";
    display: block;
    pointer-events: none;
}

.mf-public-home .mf-lifecycle-carousel.is-enhanced .mf-lifecycle-track::-webkit-scrollbar {
    height: 0.55rem;
}

.mf-public-home .mf-lifecycle-carousel.is-enhanced .mf-lifecycle-track::-webkit-scrollbar-thumb {
    background: rgba(96, 165, 250, 0.62);
    border-radius: 999px;
}

.mf-public-home .mf-lifecycle-carousel.is-enhanced .mf-lifecycle-track::-webkit-scrollbar-track {
    background: rgba(148, 163, 184, 0.14);
    border-radius: 999px;
}

.mf-public-home .mf-lifecycle-track:focus-visible {
    border-radius: calc(var(--mf-radius) + 4px);
    outline: 3px solid #60a5fa;
    outline-offset: 5px;
}

.mf-public-home .mf-lifecycle-carousel.is-enhanced [data-mf-lifecycle-slide] {
    min-width: 0;
    scroll-snap-align: start;
    transition:
        border-color 220ms ease,
        box-shadow 220ms ease,
        transform 220ms ease;
}

.mf-public-home .mf-lifecycle-carousel.is-enhanced [data-mf-lifecycle-slide].is-current {
    border-color: rgba(96, 165, 250, 0.7);
    box-shadow:
        0 18px 40px rgba(2, 8, 23, 0.25),
        inset 0 3px 0 rgba(96, 165, 250, 0.72);
    transform: translateY(-0.2rem);
}

.mf-public-home .mf-lifecycle-kicker {
    color: #93c5fd;
    font-size: 0.72rem;
    font-weight: 850;
    letter-spacing: 0.11em;
    margin: 0 0 0.65rem;
    text-transform: uppercase;
}

.mf-public-home .mf-lifecycle-controls {
    align-items: center;
    display: grid;
    gap: 0.75rem;
    grid-template-columns: auto minmax(0, 1fr) auto;
    margin-top: 0.7rem;
}

.mf-public-home .mf-lifecycle-controls[hidden] {
    display: none;
}

.mf-public-home .mf-lifecycle-controls p {
    color: var(--mf-muted);
    font-size: 0.9rem;
    font-weight: 750;
    margin: 0;
    text-align: center;
}

.mf-public-home .mf-lifecycle-controls button {
    align-items: center;
    appearance: none;
    background: rgba(15, 23, 42, 0.72);
    border: 1px solid rgba(96, 165, 250, 0.46);
    border-radius: 999px;
    color: #eaf2ff;
    cursor: pointer;
    display: inline-flex;
    font: inherit;
    font-size: 0.88rem;
    font-weight: 800;
    justify-content: center;
    min-height: 44px;
    min-width: 44px;
    padding: 0.65rem 1rem;
    transition:
        background-color 180ms ease,
        border-color 180ms ease,
        color 180ms ease,
        transform 180ms ease;
}

.mf-public-home .mf-lifecycle-controls button:hover:not([aria-disabled="true"]) {
    background: rgba(37, 99, 235, 0.28);
    border-color: #60a5fa;
    transform: translateY(-1px);
}

.mf-public-home .mf-lifecycle-controls button:focus-visible {
    outline: 3px solid #60a5fa;
    outline-offset: 3px;
}

.mf-public-home .mf-lifecycle-controls button[aria-disabled="true"] {
    cursor: default;
    opacity: 0.42;
}

/* Mouse dragging must stay safe on hybrid devices as well as desktop PCs. */
.mf-public-home .mf-lifecycle-carousel.is-enhanced .mf-lifecycle-track.is-dragging {
    scroll-behavior: auto;
    scroll-snap-type: none;
    user-select: none;
}

@media (any-pointer: fine) {
    .mf-public-home .mf-lifecycle-carousel.is-enhanced .mf-lifecycle-track {
        cursor: grab;
    }

    .mf-public-home .mf-lifecycle-carousel.is-enhanced .mf-lifecycle-track.is-dragging {
        cursor: grabbing;
    }
}

.mf-public-home #product .mf-lifecycle-track ul {
    color: var(--mf-muted);
    display: grid;
    gap: 0.55rem;
    line-height: 1.5;
    list-style: none;
    margin: 0;
    padding: 0;
}

.mf-public-home #product .mf-lifecycle-track li {
    padding-left: 1.15rem;
    position: relative;
}

.mf-public-home #product .mf-lifecycle-track li::before {
    background: #60a5fa;
    border-radius: 50%;
    content: "";
    height: 0.38rem;
    left: 0;
    position: absolute;
    top: 0.56rem;
    width: 0.38rem;
}

.mf-public-home .mf-section-note {
    border-left: 3px solid rgba(96, 165, 250, 0.72);
    font-size: 0.95rem;
    margin: 1.25rem 0 0;
    padding-left: 0.9rem;
}

.mf-public-home .mf-home-section-link {
    color: #93c5fd;
    display: inline-flex;
    font-weight: 800;
    margin-top: 1.4rem;
    text-decoration-thickness: 0.08em;
    text-underline-offset: 0.24em;
}

.mf-public-home.mf-theme-light .mf-home-section-link {
    color: #1d4ed8;
}

.mf-public-home.mf-theme-light .mf-lifecycle-kicker {
    color: #1d4ed8;
}

.mf-public-home.mf-theme-light .mf-lifecycle-carousel.is-enhanced [data-mf-lifecycle-slide].is-current {
    border-color: rgba(37, 99, 235, 0.54);
    box-shadow:
        0 18px 40px rgba(15, 23, 42, 0.13),
        inset 0 3px 0 rgba(37, 99, 235, 0.66);
}

.mf-public-home.mf-theme-light .mf-lifecycle-controls button {
    background: #ffffff;
    border-color: rgba(37, 99, 235, 0.34);
    color: #1d4ed8;
}

.mf-public-home.mf-theme-light .mf-lifecycle-controls button:hover:not([aria-disabled="true"]) {
    background: #eaf2ff;
    border-color: #2563eb;
}

/*
 * The existing product proof remains the first hero visual and stays separate
 * from the new photography. These overrides remove legacy inline presentation.
 */
.mf-public-home .mf-home-product-proof {
    margin: 3rem auto 0;
    max-width: 920px;
    text-align: center;
    width: 100%;
}

.mf-public-home .mf-home-product-proof h3 {
    color: var(--mf-navy);
    font-size: 1.25rem;
    margin: 0 0 1.5rem;
}

.mf-public-home .mf-home-product-proof img {
    border: 1px solid var(--mf-border);
    border-radius: 10px;
    box-shadow: 0 20px 45px rgba(0, 0, 0, 0.34);
    display: block;
    height: auto;
    max-width: 100%;
    width: 100%;
}

/*
 * JavaScript enables the settling state only after the observer is ready.
 * Pending content remains visible, so a late or failed callback cannot create
 * blank homepage sections.
 */
.mf-public-home .mf-home-reveal {
    opacity: 1;
    transform: none;
}

.mf-public-home.mf-home-motion-ready .mf-home-reveal:not(.is-revealed) {
    opacity: 0.82;
    transform: translateY(18px);
}

.mf-public-home.mf-home-motion-ready .mf-home-reveal {
    transition:
        opacity 420ms ease,
        transform 460ms cubic-bezier(0.22, 1, 0.36, 1);
}

.mf-public-home.mf-home-motion-ready .mf-home-reveal.is-revealed {
    opacity: 1;
    transform: none;
}

/*
 * Light mode keeps the same chapter rhythm. One deliberate dark review band
 * supplies the stronger contrast requested without abandoning the theme.
 */
.mf-public-home.mf-theme-light .mf-home-chapter {
    border-color: rgba(15, 23, 42, 0.08);
}

.mf-public-home.mf-theme-light .mf-home-chapter.is-active {
    border-color: rgba(37, 99, 235, 0.25);
    box-shadow:
        inset 4px 0 0 rgba(37, 99, 235, 0.72),
        inset 0 24px 70px rgba(37, 99, 235, 0.04);
}

.mf-public-home.mf-theme-light .mf-home-chapter-intro {
    background: #f8fafc;
}

.mf-public-home.mf-theme-light .mf-home-chapter-process {
    background:
        radial-gradient(circle at 84% 18%, rgba(37, 99, 235, 0.1), transparent 34%),
        #eaf2ff;
}

.mf-public-home.mf-theme-light .mf-home-chapter-result {
    background: #ffffff;
}

.mf-public-home.mf-theme-light .mf-home-chapter-review {
    --mf-bg: #101a2c;
    --mf-blue-soft: rgba(96, 165, 250, 0.16);
    --mf-border: rgba(148, 163, 184, 0.24);
    --mf-card: rgba(15, 29, 49, 0.8);
    --mf-muted: #cbd5e1;
    --mf-navy: #f8fafc;
    --mf-slate: #e2e8f0;
    --mf-shadow: 0 18px 44px rgba(0, 0, 0, 0.2);
    background:
        radial-gradient(circle at 12% 72%, rgba(56, 189, 248, 0.16), transparent 32%),
        #0b1628;
}

.mf-public-home.mf-theme-light .mf-home-chapter-review .mf-output-card {
    background: var(--mf-card);
    border-color: var(--mf-border);
    box-shadow: var(--mf-shadow);
}

.mf-public-home.mf-theme-light .mf-home-chapter-review .mf-destination-preview span {
    background: rgba(59, 130, 246, 0.16);
    border-color: rgba(147, 197, 253, 0.32);
    color: #bfdbfe;
}

.mf-public-home.mf-theme-light .mf-home-chapter-connect {
    background:
        radial-gradient(circle at 88% 22%, rgba(13, 148, 136, 0.1), transparent 30%),
        #edf9f7;
}

.mf-public-home.mf-theme-light .mf-home-chapter-decide {
    background: #f1f5f9;
}

.mf-public-home.mf-theme-light .mf-home-chapter-help {
    background: #ffffff;
}

.mf-public-home.mf-theme-light .mf-home-chapter-marker span:first-child {
    background: rgba(37, 99, 235, 0.08);
    border-color: rgba(37, 99, 235, 0.22);
    color: #1d4ed8;
}

.mf-public-home.mf-theme-light .mf-home-chapter.is-active .mf-home-chapter-marker {
    color: #1e3a8a;
}

.mf-public-home.mf-theme-light .mf-home-photo {
    border-color: rgba(15, 23, 42, 0.12);
    box-shadow: 0 28px 60px rgba(15, 23, 42, 0.16);
}

.mf-public-home.mf-theme-light .mf-home-main {
    background: #dce7f4;
}

.mf-public-home.mf-theme-light .mf-hero {
    background:
        radial-gradient(circle at 82% 16%, rgba(37, 99, 235, 0.12), transparent 34%),
        linear-gradient(145deg, #ffffff, #edf5ff 72%);
    border-color: rgba(37, 99, 235, 0.18);
    box-shadow: 0 28px 70px rgba(15, 23, 42, 0.13);
}

.mf-public-home.mf-theme-light .mf-home-scene-progress {
    background: rgba(248, 250, 252, 0.92);
    border-color: rgba(37, 99, 235, 0.14);
}

.mf-public-home.mf-theme-light .mf-home-scene-link {
    border-color: rgba(15, 23, 42, 0.12);
    color: #64748b;
}

.mf-public-home.mf-theme-light .mf-home-scene-link:hover,
.mf-public-home.mf-theme-light .mf-home-scene-link:focus-visible {
    background: #eaf2ff;
    border-color: rgba(37, 99, 235, 0.34);
    color: #1d4ed8;
}

.mf-public-home.mf-theme-light .mf-home-scene-link[aria-current="location"] {
    border-color: #1d4ed8;
    color: #ffffff;
}

.mf-public-home.mf-theme-light .mf-home-chapter-marker span:last-child {
    background: rgba(255, 255, 255, 0.86);
    border-color: rgba(15, 23, 42, 0.12);
}

/* Native horizontal rails preserve every server-rendered card. Their visible
 * scrollbars, edge cue and focus ring make swiping optional rather than hidden.
 */
.mf-public-home .mf-home-dense-rail {
    max-width: 100%;
    min-width: 0;
    scrollbar-color: rgba(96, 165, 250, 0.68) rgba(148, 163, 184, 0.14);
    scrollbar-gutter: stable;
    scrollbar-width: thin;
}

.mf-public-home .mf-home-dense-rail:focus-visible {
    border-radius: calc(var(--mf-radius) + 4px);
    outline: 3px solid #60a5fa;
    outline-offset: 5px;
}

.mf-public-home .mf-home-dense-rail::-webkit-scrollbar {
    height: 0.55rem;
}

.mf-public-home .mf-home-dense-rail::-webkit-scrollbar-thumb {
    background: rgba(96, 165, 250, 0.68);
    border-radius: 999px;
}

.mf-public-home .mf-home-dense-rail::-webkit-scrollbar-track {
    background: rgba(148, 163, 184, 0.14);
    border-radius: 999px;
}

/*
 * Proximity settling supports touch, keyboard, wheel and trackpad input without
 * trapping a reader inside a chapter that is taller than the viewport.
 */
@media (prefers-reduced-motion: no-preference) {
    html {
        scroll-behavior: smooth;
        scroll-padding-top: 6.5rem;
        scroll-snap-type: y proximity;
    }

    .mf-public-home .mf-home-snap-point {
        scroll-snap-align: start;
    }
}

@media (prefers-reduced-motion: reduce) {
    .mf-public-home .mf-home-chapter::before,
    .mf-public-home .mf-home-chapter-marker,
    .mf-public-home .mf-home-chapter-marker span:first-child,
    .mf-public-home .mf-home-photo img {
        transition: none;
    }

    .mf-public-home .mf-home-chapter.is-active .mf-home-chapter-marker,
    .mf-public-home .mf-home-chapter.is-active .mf-home-chapter-marker span:first-child,
    .mf-public-home .mf-home-chapter.is-active .mf-home-photo img {
        transform: none;
    }
}

@media (prefers-reduced-motion: no-preference) {
    /* Theme changes must not be interpreted as a new scroll gesture. */
    html.mf-theme-switching {
        scroll-behavior: auto;
        scroll-snap-type: none;
    }
}

/* The hero becomes one composed screen on laptops and desktops. The source
 * diagram is scaled as one approved visual rather than redrawn in CSS.
 */
@media (min-width: 1240px) {
    .mf-public-home .mf-hero {
        align-items: center;
        display: grid;
        gap: clamp(1.5rem, 2.6vw, 3rem);
        grid-template-columns: minmax(500px, 0.9fr) minmax(620px, 1.1fr);
        padding-inline: clamp(2rem, 4vw, 4.5rem);
        padding-block: clamp(2.25rem, 5svh, 4.5rem);
    }

    .mf-public-home .mf-hero-copy {
        align-self: center;
        max-width: 610px;
    }

    .mf-public-home .mf-hero h1 {
        font-size: clamp(3rem, 3.8vw, 4.5rem);
    }

    .mf-public-home .mf-hero-visual-stage {
        height: 315px;
        position: relative;
    }

    .mf-public-home .mf-hero-visual-stage .visual-flow-container {
        left: 50%;
        margin: 0;
        position: absolute;
        top: 0;
        transform: scale(0.74) translateX(-50%);
    }

    .mf-public-home .mf-hero-trust-strip {
        grid-column: 1 / -1;
    }
}

@media (min-width: 1600px) {
    .mf-public-home .mf-hero {
        grid-template-columns: minmax(560px, 0.9fr) minmax(700px, 1.1fr);
    }

    .mf-public-home .mf-hero-visual-stage .visual-flow-container {
        left: 50%;
        transform: scale(0.84) translateX(-50%);
    }
}

/* Switch to the compact header before the full navigation begins to crowd.
 * The same rules style the generated menu between 1181px and 1239px.
 */
@media (max-width: 1239px) {
    .mf-public-home {
        --mf-home-header-height: 4.85rem;
    }

    .mf-public-home .mf-site-header {
        gap: clamp(0.5rem, 1.5vw, 1rem);
        grid-template-columns: minmax(0, 1fr) auto auto;
        padding: 0.875rem clamp(0.75rem, 3vw, 2rem);
    }

    .mf-public-home .mf-site-header > .mf-public-nav {
        display: none !important;
    }

    .mf-public-home .mf-site-header .mf-brand {
        min-width: 0;
        overflow: hidden;
    }

    .mf-public-home .mf-site-header .mf-brand img,
    .mf-public-home .mf-site-header .mf-brand-logo {
        max-width: min(178px, 32vw);
    }

    .mf-public-home .mf-public-mobile-menu {
        display: block;
        justify-self: end;
        position: relative;
        z-index: 2;
    }

    /* The shared theme switch is fixed to the top-right, so reserve its
     * footprint in the header grid and keep Menu clear of the control. */
    .mf-public-home .mf-site-header .mf-header-actions {
        min-width: 2.75rem;
        width: 2.75rem;
    }

    .mf-public-home .mf-public-mobile-menu summary {
        align-items: center;
        border: 1px solid rgba(148, 163, 184, 0.32);
        border-radius: 999px;
        color: inherit;
        cursor: pointer;
        display: inline-flex;
        font-size: 0.82rem;
        font-weight: 850;
        justify-content: center;
        list-style: none;
        max-width: min(7rem, 22vw);
        min-height: 44px;
        min-width: 4.5rem;
        overflow: hidden;
        padding: 0.55rem 0.8rem;
        text-overflow: ellipsis;
        white-space: nowrap;
    }

    .mf-public-home .mf-public-mobile-menu summary::-webkit-details-marker {
        display: none;
    }

    .mf-public-home .mf-public-mobile-links {
        background: #07111f;
        border: 1px solid rgba(148, 163, 184, 0.24);
        border-radius: 10px;
        box-shadow: 0 18px 44px rgba(0, 0, 0, 0.3);
        display: grid;
        gap: 0.25rem;
        max-height: calc(100svh - 5.25rem);
        overflow-y: auto;
        padding: 0.55rem;
        position: absolute;
        right: 0;
        top: calc(100% + 0.5rem);
        width: min(16rem, calc(100vw - 1.5rem));
        z-index: 3;
    }

    .mf-public-home .mf-public-mobile-menu:not([open]) .mf-public-mobile-links {
        display: none;
    }

    .mf-public-home .mf-public-mobile-links a {
        border-radius: 6px;
        color: #e2e8f0;
        font-size: 0.84rem;
        font-weight: 750;
        padding: 0.6rem 0.7rem;
        text-decoration: none;
    }

    .mf-public-home .mf-public-mobile-links a:hover,
    .mf-public-home .mf-public-mobile-links a:focus-visible {
        background: rgba(96, 165, 250, 0.16);
        color: #ffffff;
    }

    .mf-public-home.mf-theme-light .mf-public-mobile-links {
        background: #ffffff;
        border-color: var(--mf-border);
        box-shadow: 0 18px 40px rgba(15, 23, 42, 0.16);
    }

    .mf-public-home.mf-theme-light .mf-public-mobile-links a {
        color: #1e293b;
    }

    .mf-public-home.mf-theme-light .mf-public-mobile-links a:hover,
    .mf-public-home.mf-theme-light .mf-public-mobile-links a:focus-visible {
        background: #eaf2ff;
        color: #1d4ed8;
    }

    .mf-public-home .mf-public-noscript-nav {
        background: #07111f;
        border-bottom: 1px solid rgba(148, 163, 184, 0.2);
        display: flex;
        gap: 0.35rem;
        overflow-x: auto;
        padding: 0.55rem 0.75rem;
        scrollbar-width: thin;
    }

    .mf-public-home .mf-public-noscript-nav a {
        border: 1px solid rgba(148, 163, 184, 0.22);
        border-radius: 999px;
        color: #e2e8f0;
        flex: 0 0 auto;
        font-size: 0.8rem;
        font-weight: 800;
        padding: 0.55rem 0.75rem;
        text-decoration: none;
    }

    .mf-public-home.mf-theme-light .mf-public-noscript-nav {
        background: #ffffff;
        border-color: var(--mf-border);
    }

    .mf-public-home.mf-theme-light .mf-public-noscript-nav a {
        color: #1d4ed8;
    }

    .mf-public-home .mf-home-scene-progress-track {
        grid-auto-columns: minmax(6.3rem, 1fr);
        grid-auto-flow: column;
        grid-template-columns: none;
        /* Keep swipe and keyboard scrolling while replacing the browser's
         * heavy native bar with a quiet edge cue. */
        -webkit-mask-image: linear-gradient(90deg, transparent, #000 0.65rem, #000 calc(100% - 0.65rem), transparent);
        mask-image: linear-gradient(90deg, transparent, #000 0.65rem, #000 calc(100% - 0.65rem), transparent);
        overflow-x: auto;
        overscroll-behavior-inline: contain;
        padding: 0 0.65rem 0.2rem;
        scrollbar-width: none;
    }

    .mf-public-home .mf-home-scene-progress-track::-webkit-scrollbar {
        display: none;
    }

    .mf-public-home .mf-hero-visual-stage {
        height: 380px;
    }
}

@media (min-width: 951px) and (max-width: 1100px) {
    .mf-public-home .mf-hero-visual-stage {
        height: 350px;
    }
}

@media (min-width: 801px) and (max-width: 950px) {
    .mf-public-home .mf-hero-visual-stage {
        height: 315px;
    }
}

@media (min-width: 681px) and (max-width: 800px) {
    .mf-public-home .mf-hero-visual-stage {
        height: 275px;
    }
}

@media (min-width: 521px) and (max-width: 680px) {
    .mf-public-home .mf-hero-visual-stage {
        height: 235px;
    }
}

@media (min-width: 421px) and (max-width: 520px) {
    .mf-public-home .mf-hero-visual-stage {
        height: 200px;
    }
}

@media (max-width: 420px) {
    .mf-public-home .mf-hero-visual-stage {
        height: 165px;
    }
}

@media (max-width: 1239px) {
    .mf-public-home .mf-home-output-rail,
    .mf-public-home .mf-home-integrations-rail {
        display: grid;
        gap: 1rem;
        grid-auto-columns: minmax(17rem, calc((100% - 1rem) / 2.15));
        grid-auto-flow: column;
        grid-template-columns: none !important;
        overflow-x: auto;
        overscroll-behavior-inline: contain;
        padding-block: 0.25rem 0.8rem;
        scroll-padding-inline: 0.1rem;
        scroll-snap-type: x proximity;
        touch-action: pan-x pan-y pinch-zoom;
    }

    .mf-public-home .mf-home-output-rail > article,
    .mf-public-home .mf-home-integrations-rail > article {
        min-width: 0;
        scroll-snap-align: start;
    }
}

@media (max-width: 980px) {
    .mf-public-home {
        --mf-home-header-height: 4.75rem;
        --mf-home-photo-radius: 20px;
    }

    .mf-public-home .mf-home-split,
    .mf-public-home .mf-home-capture-grid {
        grid-template-columns: minmax(0, 1fr);
    }

    .mf-public-home .mf-home-split-media-left > .mf-home-photo,
    .mf-public-home .mf-home-split-media-left > .mf-home-split-copy {
        grid-column: auto;
        grid-row: auto;
    }

    .mf-public-home .mf-home-split-media-left > .mf-home-split-copy {
        order: -1;
    }

    .mf-public-home .mf-home-photo {
        max-width: 760px;
    }

    .mf-public-home .mf-home-process-rail {
        display: grid;
        gap: 1rem;
        grid-auto-columns: minmax(17rem, calc((100% - 1rem) / 2.15));
        grid-auto-flow: column;
        grid-template-columns: none !important;
        overflow-x: auto;
        overscroll-behavior-inline: contain;
        padding-block: 0.25rem 0.8rem;
        scroll-padding-inline: 0.1rem;
        scroll-snap-type: x proximity;
        touch-action: pan-x pan-y pinch-zoom;
    }

    .mf-public-home .mf-home-process-rail > article {
        min-width: 0;
        scroll-snap-align: start;
    }
}

@media (max-width: 640px) {
    .mf-public-home {
        --mf-home-header-height: 4.55rem;
        --mf-home-photo-radius: 16px;
    }

    /* The wider compact-header menu is anchored to its summary. On phones it
     * becomes a viewport-contained panel so opening Menu cannot widen or shift
     * the page beyond either screen edge. */
    .mf-public-home .mf-public-mobile-links {
        left: 0.75rem;
        max-height: calc(100svh - 5.25rem);
        position: fixed;
        right: 0.75rem;
        top: calc(var(--mf-home-header-height) + env(safe-area-inset-top, 0px));
        width: auto;
    }

    .mf-public-home .mf-home-main {
        padding: 0.45rem;
    }

    .mf-public-home .mf-hero,
    .mf-public-home .mf-home-chapter {
        border-radius: 18px;
        margin-bottom: 0.65rem;
        min-height: calc(100svh - var(--mf-home-sticky-offset) - 1rem);
    }

    .mf-public-home .mf-home-scene-progress {
        padding-inline: 0.45rem;
    }

    .mf-public-home .mf-home-scene-progress-track {
        display: flex;
        gap: 0.28rem;
        overflow-x: auto;
    }

    .mf-public-home .mf-home-scene-link {
        flex: 0 0 3.15rem;
        min-height: 2.8rem;
        padding-inline: 0.42rem;
        text-align: center;
    }

    .mf-public-home .mf-home-scene-link strong {
        display: none;
    }

    .mf-public-home .mf-home-scene-link[aria-current="location"] {
        flex-basis: 8rem;
        text-align: left;
    }

    .mf-public-home .mf-home-scene-link[aria-current="location"] strong {
        display: block;
    }

    .mf-public-home .mf-home-chapter-marker {
        font-size: 0.68rem;
        gap: 0.45rem;
        padding-left: 1rem;
        padding-right: 1rem;
        top: calc(var(--mf-home-sticky-offset) + 0.15rem);
    }

    .mf-public-home .mf-home-chapter-marker span:last-child {
        padding: 0.48rem 0.62rem;
    }

    .mf-public-home .mf-home-chapter-marker::after {
        left: 1rem;
        width: 9rem;
    }

    .mf-public-home .mf-home-photo figcaption {
        background: #0b1422;
        color: #e2e8f0;
        max-width: none;
        padding: 0.85rem 1rem;
        position: relative;
    }

    .mf-public-home .mf-home-photo::after {
        display: none;
    }

    .mf-public-home .mf-home-capture-grid {
        margin-top: 1.25rem;
    }

    .mf-public-home .mf-home-dense-rail {
        grid-auto-columns: minmax(16rem, 86%);
    }

    /* One full stage plus a deliberate edge cue keeps phone swiping obvious. */
    .mf-public-home .mf-lifecycle-carousel.is-enhanced .mf-lifecycle-track {
        --mf-lifecycle-card-width: 86%;
    }

    .mf-public-home .mf-lifecycle-controls {
        gap: 0.55rem;
    }

    .mf-public-home .mf-lifecycle-controls button {
        padding-left: 0.8rem;
        padding-right: 0.8rem;
    }

    .mf-public-home .mf-home-product-proof {
        margin-top: 2rem;
    }
}

/* Shallow laptop windows need complete scenes without oversized empty bands. */
@media (max-height: 820px) {
    .mf-public-home .mf-hero {
        min-height: calc(100svh - var(--mf-home-sticky-offset) - 1rem);
        padding-block: clamp(1.8rem, 4.5svh, 3rem);
    }

    .mf-public-home .mf-home-chapter {
        min-height: calc(100svh - var(--mf-home-sticky-offset) - 1rem);
    }

    .mf-public-home .mf-home-chapter > .mf-section,
    .mf-public-home .mf-home-chapter > .mf-final-cta,
    .mf-public-home .mf-home-chapter > .mf-logo-strip {
        padding-block: clamp(2rem, 5svh, 3.5rem);
    }

    .mf-public-home .mf-home-chapter > .mf-section:first-of-type {
        padding-top: clamp(1.25rem, 3.5svh, 2.25rem);
    }
}

@media (max-width: 1239px) {
    .mf-public-home .mf-public-mobile-links a[data-home-nav][aria-current="location"] {
        background: rgba(96, 165, 250, 0.18);
        box-shadow: inset 3px 0 0 #60a5fa;
        color: #ffffff;
    }

    .mf-public-home.mf-theme-light .mf-public-mobile-links a[data-home-nav][aria-current="location"] {
        background: #eaf2ff;
        box-shadow: inset 3px 0 0 #2563eb;
        color: #1d4ed8;
    }
}

/*
 * Reduced motion is a complete static mode for both new chapter effects and
 * the pre-existing continuously animated hero diagram.
 */
@media (prefers-reduced-motion: reduce) {
    html {
        scroll-behavior: auto !important;
        scroll-snap-type: none !important;
    }

    .mf-public-home,
    .mf-public-home *,
    .mf-public-home *::before,
    .mf-public-home *::after {
        animation-delay: 0ms !important;
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        scroll-behavior: auto !important;
        transition-delay: 0ms !important;
        transition-duration: 0.01ms !important;
    }

    .mf-public-home.mf-home-motion-ready .mf-home-reveal,
    .mf-public-home.mf-home-motion-ready .mf-home-reveal:not(.is-revealed) {
        opacity: 1 !important;
        transform: none !important;
    }

    .mf-public-home .teams-brand-logo,
    .mf-public-home .flow-hub-pulse,
    .mf-public-home .hub-gear-svg,
    .mf-public-home .flow-path {
        animation: none !important;
    }

    .mf-public-home .mf-lifecycle-carousel.is-enhanced .mf-lifecycle-track {
        scroll-behavior: auto !important;
    }

    .mf-public-home .mf-home-dense-rail {
        scroll-behavior: auto !important;
        scroll-snap-type: none !important;
    }

    .mf-public-home .mf-home-scene-link[aria-current="location"] {
        transform: none !important;
    }

    .mf-public-home .mf-lifecycle-carousel.is-enhanced [data-mf-lifecycle-slide].is-current,
    .mf-public-home .mf-lifecycle-controls button:hover:not([aria-disabled="true"]) {
        transform: none !important;
    }
}

@media print {
    html {
        scroll-snap-type: none !important;
    }

    .mf-public-home .mf-home-reveal,
    .mf-public-home.mf-home-motion-ready .mf-home-reveal:not(.is-revealed) {
        opacity: 1 !important;
        transform: none !important;
    }

    .mf-public-home .mf-home-scene-progress,
    .mf-public-home .mf-public-noscript-nav {
        display: none !important;
    }

    .mf-public-home .mf-home-main {
        background: transparent;
        padding: 0;
    }

    .mf-public-home .mf-home-chapter,
    .mf-public-home .mf-hero {
        box-shadow: none;
        break-inside: avoid;
        margin: 0;
        max-width: none;
        min-height: 0;
    }

    .mf-public-home .mf-home-chapter-marker {
        position: static;
    }

    /* Print every stage as normal content and omit interaction-only controls. */
    .mf-public-home .mf-lifecycle-carousel.is-enhanced .mf-lifecycle-track {
        grid-auto-flow: row;
        grid-template-columns: repeat(2, minmax(0, 1fr));
        overflow: visible;
    }

    .mf-public-home .mf-lifecycle-carousel.is-enhanced .mf-lifecycle-track::after {
        display: none;
    }

    .mf-public-home .mf-lifecycle-controls {
        display: none !important;
    }
}
