.hero-cockpit {
    isolation: isolate;
    padding-block-start: clamp(108px, 13vh, 156px);
}

.hero-cockpit .hero-bg {
    background: radial-gradient(ellipse at 76% 35%, #17312e, #0f1919 43%, #0a0e0e 75%);
}

.hero-cockpit .hero-bg::after {
    display: none;
}

.hero-cockpit .hero-layout {
    display: grid;
    width: min(100%, 1320px);
    grid-template-columns: minmax(0, .88fr) minmax(0, 1.12fr);
    align-items: center;
    gap: clamp(28px, 5vw, 75px);
    margin-block-end: clamp(32px, 6vh, 70px);
}

.hero-cockpit .hero-content {
    min-width: 0;
    margin-block: 0;
    text-align: start;
}

.hero-cockpit .hero-title {
    font-size: clamp(2.6rem, 4.55vw, 4.45rem);
    letter-spacing: -.04em;
    line-height: 1.06;
    text-wrap: balance;
}

.hero-cockpit .hero-title .gradient-text {
    background-image: linear-gradient(112deg, #b0ded6, #69b6ad);
}

.hero-cockpit .hero-subtitle {
    max-width: 39ch;
    margin-inline: 0;
}

.hero-cockpit .hero-cta {
    justify-content: start;
}

.cockpit-stage {
    display: grid;
    grid-template-columns: repeat(12, minmax(0, 1fr));
    position: relative;
    z-index: 1;
    min-width: 0;
    align-items: start;
}

.cockpit-shot,
.cockpit-demo {
    grid-row: 1;
    min-width: 0;
    border: 1px solid #365653;
    border-radius: 12px;
}

.cockpit-shot {
    grid-column: 1 / -1;
    display: block;
    width: 100%;
    height: auto;
    background: #122321;
    box-shadow: 0 28px 60px #0005;
}

.cockpit-demo {
    grid-column: 2 / -1;
    position: relative;
    align-self: start;
    margin-block-start: clamp(120px, 16vw, 245px);
    padding: clamp(12px, 2vw, 22px);
    background: #101b1e;
    color: #eff6f3;
    box-shadow: 0 24px 55px #020606ac;
}

.cockpit-demo-header,
.cockpit-demo-footer {
    display: flex;
    flex-wrap: wrap;
    align-items: flex-start;
    justify-content: space-between;
    gap: 8px 14px;
}

.cockpit-demo :is(h2, h3) {
    margin: 0;
    font-size: 1.04rem;
    line-height: 1.35;
}

.cockpit-demo p,
.cockpit-setpoint > span {
    margin: 0;
    color: #b5c6c2;
    font-size: .76rem;
}

.cockpit-setpoint {
    text-align: end;
}

.cockpit-setpoint strong {
    display: block;
    color: #a2ebdb;
    font-size: clamp(1.3rem, 2vw, 1.7rem);
    font-variant-numeric: tabular-nums;
    line-height: 1.18;
}

.cockpit-chart {
    display: block;
    width: 100%;
    height: clamp(120px, 12vw, 158px);
    margin-block-start: 10px;
    overflow: hidden;
}

.cockpit-chart [data-chart-part="grid"] text {
    fill: #b5c6c2;
    font: 11px Inter, system-ui, sans-serif;
}

.cockpit-chart [data-chart-part="grid"] line {
    stroke: #304640;
}

.cockpit-chart polyline {
    stroke-width: 2px;
    stroke-linecap: round;
    stroke-linejoin: round;
}

.cockpit-chart [data-chart-part="measured"] {
    stroke: #d6e9e5;
}

.cockpit-chart [data-chart-part="forecast"] {
    stroke: #6fe6ce;
    stroke-dasharray: 4 4;
}

.cockpit-chart [data-chart-part="cursor"] {
    stroke: #a6f8df;
    stroke-opacity: .45;
}

.cockpit-chart [data-chart-part="halo"],
.cockpit-chart [data-chart-part="marker"] {
    fill: #a6f8df;
}

.cockpit-chart [data-chart-part="halo"] {
    fill-opacity: .18;
}

.cockpit-legend {
    display: flex;
    flex-wrap: wrap;
    gap: 4px 15px;
    color: #b5c6c2;
    font-size: .75rem;
}

.cockpit-legend span {
    display: inline-flex;
    align-items: center;
    gap: 6px;
}

.cockpit-legend span::before {
    content: '';
    width: 15px;
    border-top: 2px solid #d6e9e5;
}

.cockpit-legend span + span::before {
    border-top: 2px dashed #6fe6ce;
}

.cockpit-demo-footer {
    align-items: center;
    margin-block-start: 12px;
}

.cockpit-demo-footer p {
    color: #a2ebdb;
}

.cockpit-demo-play {
    min-height: 44px;
    padding-inline: 12px;
    border: 1px solid #496d66;
    border-radius: 7px;
    background: #192d2b;
    color: #d8fff3;
    font: inherit;
    font-size: .78rem;
    cursor: pointer;
}

.cockpit-demo-play:hover {
    background: #243d38;
}

.cockpit-demo-play:focus-visible {
    outline: 2px solid #a2ebdb;
    outline-offset: 3px;
}

.ia-demo {
    scroll-margin-top: 100px;
}

.ia-demo .cockpit-demo {
    grid-area: auto;
    margin-block-start: 0;
}

.ia-demo-intro p {
    margin-block-start: var(--space-md);
    color: var(--text-secondary);
}

@media (max-width: 900px) {
    .hero-cockpit {
        padding-block-start: 126px !important;
    }

    .hero-cockpit .hero-layout {
        grid-template-columns: minmax(0, 1fr);
        width: min(100%, 660px);
    }

    .hero-cockpit .hero-content {
        text-align: center;
    }

    .hero-cockpit .hero-subtitle {
        margin-inline: auto;
    }

    .hero-cockpit .hero-cta {
        justify-content: center;
    }

    .cockpit-demo {
        margin-block-start: clamp(114px, 27vw, 235px);
    }
}

@media (max-width: 480px) {
    .hero-cockpit .hero-title {
        font-size: clamp(2.15rem, 8.25vw, 2.8rem);
    }

    .hero-cockpit .hero-subtitle {
        font-size: 1.07rem;
    }

    .hero-cockpit .hero-cta {
        gap: 12px;
    }

    .cockpit-demo {
        grid-column: 1 / -1;
        margin-block-start: clamp(94px, 26vw, 126px);
    }
}

@media (prefers-reduced-motion: reduce) {
    .hero-cockpit .hero-content,
    .hero-cockpit .stats-bar {
        animation: none;
    }
}
