/* IronFlow editorial marketing pages — v1
   Extends kinetic-v1.css without changing the landing-page contract. */

.primary-nav a[aria-current="page"] {
    color: var(--lime);
}

.primary-nav a[aria-current="page"]::after {
    transform: scaleX(1);
    transform-origin: left;
}

.kd-page {
    --kd-content-max: 96rem;
    min-width: 0;
    overflow: clip;
    background: var(--ink);
    color: var(--paper);
}

.kd-page :where(h1, h2, h3, p, ul, ol, pre, figure, blockquote) {
    margin-top: 0;
}

.kd-page :where(h1, h2, h3, p, li, a, code, strong, span) {
    min-width: 0;
}

.kd-page :where(h1, h2, h3, p, li) {
    overflow-wrap: anywhere;
}

.kd-page :where(h1, h2, h3) {
    font-family: var(--display);
    font-weight: 800;
}

.kd-page :where(a) {
    text-underline-offset: 0.22em;
}

.kd-page-hero {
    position: relative;
    isolation: isolate;
    min-height: 45rem;
    overflow: hidden;
    border-bottom: 1px solid var(--rule);
    background:
        linear-gradient(90deg, transparent calc(50% - 1px), rgba(241, 238, 231, 0.08) 50%, transparent calc(50% + 1px)),
        var(--ink);
}

.kd-page-hero::before {
    content: "";
    position: absolute;
    z-index: -1;
    top: 0;
    right: 0;
    width: min(43vw, 46rem);
    height: 100%;
    background:
        linear-gradient(rgba(241, 238, 231, 0.055) 1px, transparent 1px),
        linear-gradient(90deg, rgba(241, 238, 231, 0.055) 1px, transparent 1px);
    background-size: 2.5rem 2.5rem;
    mask-image: linear-gradient(to left, #000 45%, transparent);
    pointer-events: none;
}

.kd-page-hero__inner,
.kd-band__inner,
.kd-cta {
    width: min(100%, var(--kd-content-max));
    margin-inline: auto;
    padding-inline: var(--gutter);
}

.kd-page-hero__inner {
    display: grid;
    min-height: 45rem;
    grid-template-columns: minmax(0, 1.15fr) minmax(21rem, 0.85fr);
    align-items: center;
    gap: clamp(3rem, 6vw, 7rem);
    padding-top: clamp(8rem, 13vw, 11rem);
    padding-bottom: clamp(4.5rem, 8vw, 8rem);
}

.kd-page-hero__copy,
.kd-page-hero__visual {
    min-width: 0;
}

.kd-page-hero__kicker,
.kd-section-head__kicker,
.kd-card__kicker,
.kd-decision__kicker,
.kd-architecture__label,
.kd-cta__kicker {
    margin-bottom: 1.4rem;
    color: var(--lime);
    font-family: var(--mono);
    font-size: 0.72rem;
    font-weight: 600;
    letter-spacing: 0.14em;
    line-height: 1.4;
    text-transform: uppercase;
}

.kd-page-hero__kicker::before,
.kd-section-head__kicker::before,
.kd-card__kicker::before,
.kd-decision__kicker::before,
.kd-cta__kicker::before {
    content: "// ";
}

.kd-page-hero__title {
    max-width: 12ch;
    margin-bottom: 1.75rem;
    font-size: clamp(5.3rem, 9.2vw, 10.5rem);
    letter-spacing: -0.018em;
    line-height: 0.78;
    text-wrap: balance;
}

.kd-page-hero__lede {
    max-width: 46rem;
    margin-bottom: 0;
    color: var(--paper-dim);
    font-size: clamp(1rem, 1.55vw, 1.3rem);
    line-height: 1.65;
}

.kd-page-hero__lede strong {
    color: var(--paper);
}

.kd-page-hero__actions,
.kd-card__actions,
.kd-decision__actions,
.kd-cta__actions {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 0.75rem;
    margin-top: 2.25rem;
}

.kd-button {
    display: inline-flex;
    min-height: 3.5rem;
    align-items: center;
    justify-content: center;
    gap: 0.7rem;
    border: 2px solid var(--lime);
    padding: 0.85rem 1.2rem;
    background: var(--lime);
    color: var(--ink);
    font-size: 0.72rem;
    font-weight: 700;
    letter-spacing: 0.08em;
    line-height: 1.25;
    text-decoration: none;
    text-transform: uppercase;
    transition:
        background-color var(--kd-motion-interactive) ease,
        border-color var(--kd-motion-interactive) ease,
        color var(--kd-motion-interactive) ease,
        transform var(--kd-motion-interactive) var(--kd-ease-kinetic);
}

.kd-button > span {
    flex: 0 0 auto;
    font-size: 1rem;
    line-height: 1;
}

.kd-button:hover {
    border-color: var(--paper);
    background: var(--paper);
    transform: translate(-3px, -3px);
}

.kd-button--outline {
    border-color: var(--rule);
    background: transparent;
    color: var(--paper);
}

.kd-button--outline:hover {
    border-color: var(--lime);
    background: transparent;
    color: var(--lime);
}

.kd-button--ink {
    border-color: var(--ink);
    background: var(--ink);
    color: var(--paper);
}

.kd-button--ink:hover {
    border-color: var(--ink);
    background: transparent;
    color: var(--ink);
}

.kd-button--text {
    min-height: 2rem;
    justify-content: flex-start;
    border: 0;
    padding: 0;
    background: transparent;
    color: currentColor;
    text-decoration: underline;
}

.kd-button--text:hover {
    border: 0;
    background: transparent;
    color: var(--lime);
    transform: none;
}

.kd-page-hero__visual {
    position: relative;
}

.kd-page-hero__visual-label {
    margin-bottom: 0.8rem;
    color: var(--paper-dim);
    font-size: 0.64rem;
    font-weight: 600;
    letter-spacing: 0.1em;
    line-height: 1.45;
    text-transform: uppercase;
}

.kd-page-hero--compact,
.kd-page-hero--compact .kd-page-hero__inner {
    min-height: 40rem;
}

.kd-page-hero--compact .kd-page-hero__title {
    font-size: clamp(4.8rem, 8vw, 8.8rem);
}

.kd-route {
    position: relative;
    display: grid;
    margin: 0;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    border-top: 1px solid var(--rule);
    border-left: 1px solid var(--rule);
    padding: 0;
    list-style: none;
}

.kd-route::after {
    content: "";
    position: absolute;
    z-index: 2;
    top: -1px;
    left: 0;
    width: 32%;
    height: 3px;
    transform: translateX(-110%);
    background: var(--lime);
    animation: kd-route-scan 4.8s var(--kd-ease-kinetic) infinite;
    pointer-events: none;
}

.kd-route__item {
    position: relative;
    min-height: 8.5rem;
    border-right: 1px solid var(--rule);
    border-bottom: 1px solid var(--rule);
    padding: 1rem;
    background: rgba(5, 6, 22, 0.84);
}

.kd-route__item:nth-child(3n + 2) {
    background: var(--purple);
}

.kd-route__item:nth-child(3n + 2) :where(.kd-route__number, .kd-route__label, .kd-route__copy) {
    color: var(--paper);
}

.kd-route__item:nth-child(6n) {
    background: var(--lime);
    color: var(--ink);
}

/* The RAG hero is one continuous route, so every stage shares one surface.
   Sequence comes from the numbered grid, arrows, and moving scan line rather
   than unrelated full-tile fills. */
.kd-route--rag .kd-route__item,
.kd-route--rag .kd-route__item:nth-child(3n + 2),
.kd-route--rag .kd-route__item:nth-child(6n) {
    background: rgba(5, 6, 22, 0.94);
    color: var(--paper);
}

.kd-route--rag .kd-route__arrow {
    color: var(--lime);
}

.kd-route__number,
.kd-route__index,
.kd-route__label {
    display: block;
    font-family: var(--mono);
    font-size: 0.64rem;
    font-weight: 600;
    letter-spacing: 0.12em;
    line-height: 1.4;
    text-transform: uppercase;
}

.kd-route__number,
.kd-route__index {
    margin-bottom: 2.1rem;
    color: var(--lime);
}

.kd-route__title,
.kd-route__name {
    display: block;
    margin: 0;
    font-family: var(--display);
    font-size: clamp(1.75rem, 3vw, 2.55rem);
    font-weight: 800;
    letter-spacing: 0.01em;
    line-height: 0.9;
    text-transform: uppercase;
}

.kd-route__copy {
    display: block;
    margin-top: 0.65rem;
    color: var(--paper-dim);
    font-size: 0.72rem;
    line-height: 1.5;
}

.kd-route__arrow {
    position: absolute;
    right: 0.8rem;
    bottom: 0.65rem;
    font-size: 1.2rem;
}

.kd-route--comparison {
    grid-template-columns: minmax(0, 1fr);
}

.kd-route--comparison .kd-route__item {
    min-height: 7rem;
}

.kd-route--comparison .kd-route__index {
    margin-bottom: 1rem;
}

.kd-proof-rail {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    border-bottom: 1px solid var(--rule);
    background: var(--paper);
    color: var(--ink);
    margin: 0;
}

.kd-proof-rail__item {
    display: flex;
    min-width: 0;
    flex-direction: column;
    border-right: 1px solid rgba(5, 6, 22, 0.22);
    padding: clamp(1.5rem, 3vw, 2.7rem) var(--gutter);
}

.kd-proof-rail__item:last-child {
    border-right: 0;
}

.kd-proof-rail__value {
    order: -1;
    display: block;
    margin: 0 0 0.45rem;
    font-family: var(--display);
    font-size: clamp(3rem, 5.8vw, 5.5rem);
    font-weight: 800;
    letter-spacing: -0.015em;
    line-height: 0.8;
}

.kd-proof-rail__label {
    display: block;
    font-size: 0.68rem;
    font-weight: 600;
    letter-spacing: 0.09em;
    line-height: 1.5;
    text-transform: uppercase;
}

.kd-band {
    position: relative;
    border-bottom: 1px solid var(--rule);
    background: var(--ink);
    color: var(--paper);
}

.kd-band--paper {
    border-color: rgba(5, 6, 22, 0.2);
    background: var(--paper);
    color: var(--ink);
}

.kd-band--lime {
    border-color: var(--ink);
    background: var(--lime);
    color: var(--ink);
}

.kd-band--purple {
    border-color: var(--kd-rule-on-purple);
    background: var(--purple);
    color: var(--paper);
}

.kd-band--ink {
    background: var(--ink);
    color: var(--paper);
}

.kd-band__inner {
    padding-top: clamp(4.5rem, 8vw, 8rem);
    padding-bottom: clamp(4.5rem, 8vw, 8rem);
}

.kd-section-head {
    display: grid;
    grid-template-columns: minmax(0, 1.3fr) minmax(17rem, 0.7fr);
    align-items: end;
    gap: clamp(2rem, 6vw, 7rem);
    margin-bottom: clamp(2.75rem, 5vw, 5rem);
}

.kd-section-head > .kd-section-head__kicker {
    grid-column: 1 / -1;
    margin-bottom: -0.25rem;
}

/* Split sections already divide the available width once. Their heading must
   stay a single editorial column instead of creating a second nested split. */
.kd-split-copy {
    min-width: 0;
}

.kd-split-copy > .kd-section-head,
.kd-band__inner.kd-grid--2 > .kd-section-head {
    grid-template-columns: minmax(0, 1fr);
    align-content: start;
    align-items: start;
    gap: 1.35rem;
    margin-bottom: 0;
}

.kd-split-copy > .kd-section-head > *,
.kd-band__inner.kd-grid--2 > .kd-section-head > * {
    grid-column: 1;
}

.kd-split-copy > .kd-section-head .kd-section-head__kicker,
.kd-band__inner.kd-grid--2 > .kd-section-head .kd-section-head__kicker {
    margin-bottom: 0.15rem;
}

.kd-split-copy > .kd-section-head .kd-section-head__title,
.kd-band__inner.kd-grid--2 > .kd-section-head .kd-section-head__title {
    max-width: 11ch;
    font-size: clamp(3.6rem, 5.4vw, 6rem);
    overflow-wrap: normal;
}

.kd-split-copy > .kd-callout {
    margin-top: 2rem;
}

.kd-band__inner.kd-grid--2 .kd-callout {
    grid-template-columns: minmax(0, 1fr);
}

.kd-band__inner.kd-grid--2 .kd-callout > strong {
    border-right: 0;
    border-bottom: 2px solid currentColor;
    font-size: clamp(2.5rem, 4vw, 4rem);
    overflow-wrap: normal;
}

.kd-split-copy > .kd-section-head + * {
    margin-top: clamp(2rem, 4vw, 3.5rem);
}

.kd-section-head__copy {
    min-width: 0;
}

.kd-section-head__title {
    max-width: 14ch;
    margin: 0;
    font-size: clamp(4.2rem, 8vw, 8.2rem);
    letter-spacing: -0.012em;
    line-height: 0.8;
    text-wrap: balance;
}

.kd-section-head__lede {
    margin: 0;
    color: var(--paper-dim);
    font-size: clamp(0.92rem, 1.4vw, 1.12rem);
    line-height: 1.7;
}

.kd-band--paper .kd-section-head__kicker,
.kd-band--lime .kd-section-head__kicker {
    color: var(--purple);
}

.kd-band--paper .kd-section-head__lede,
.kd-band--lime .kd-section-head__lede {
    color: rgba(5, 6, 22, 0.7);
}

.kd-grid {
    display: grid;
    min-width: 0;
    border-top: 1px solid currentColor;
    border-left: 1px solid currentColor;
}

.kd-grid--2 {
    grid-template-columns: repeat(2, minmax(0, 1fr));
}

.kd-grid--3 {
    grid-template-columns: repeat(3, minmax(0, 1fr));
}

.kd-grid--4 {
    grid-template-columns: repeat(4, minmax(0, 1fr));
}

.kd-card {
    position: relative;
    display: flex;
    min-width: 0;
    min-height: 20rem;
    flex-direction: column;
    border-right: 1px solid currentColor;
    border-bottom: 1px solid currentColor;
    padding: clamp(1.4rem, 2.7vw, 2.5rem);
    color: inherit;
    text-decoration: none;
}

.kd-card[href] {
    transition:
        background-color var(--kd-motion-interactive) ease,
        color var(--kd-motion-interactive) ease;
}

.kd-card[href]:hover {
    background: var(--lime);
    color: var(--ink);
}

.kd-card--compact {
    min-height: 14rem;
}

.kd-card--ink {
    background: var(--ink);
    color: var(--paper);
}

.kd-card--paper {
    background: var(--paper);
    color: var(--ink);
}

.kd-card--lime {
    background: var(--lime);
    color: var(--ink);
}

.kd-card--purple {
    background: var(--purple);
    color: var(--paper);
}

.kd-card--red {
    background: var(--red);
    color: var(--paper);
}

.kd-card__kicker {
    color: currentColor;
}

.kd-card__eyebrow,
.kd-card__index {
    display: block;
    margin: 0 0 2.5rem;
    font-size: 0.66rem;
    font-weight: 700;
    letter-spacing: 0.11em;
    line-height: 1.4;
    text-transform: uppercase;
}

.kd-card__title {
    max-width: 16ch;
    margin: 0 0 1rem;
    font-size: clamp(2.35rem, 4vw, 4rem);
    letter-spacing: 0.005em;
    line-height: 0.9;
    overflow-wrap: normal;
    word-break: normal;
}

@media (min-width: 1101px) {
    .kd-grid--4 .kd-card__title {
        font-size: clamp(2.35rem, 3.4vw, 3.5rem);
    }

    .kd-rag-fit__cards .kd-card__title {
        font-size: clamp(2.35rem, 3.25vw, 3rem);
    }
}

.kd-card__copy {
    max-width: 40rem;
    margin-bottom: 0;
    color: inherit;
    font-size: 0.88rem;
    line-height: 1.7;
    opacity: 0.76;
}

.kd-card__meta {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
    margin-top: auto;
    padding-top: 2rem;
    font-size: 0.64rem;
    font-weight: 600;
    letter-spacing: 0.08em;
    text-transform: uppercase;
}

.kd-card__link {
    margin-top: auto;
    padding-top: 2rem;
    font-size: 0.7rem;
    font-weight: 700;
    letter-spacing: 0.08em;
    text-decoration: underline;
    text-transform: uppercase;
}

.kd-card--link:hover .kd-card__copy {
    opacity: 0.82;
}

.kd-pipeline {
    display: grid;
    min-width: 0;
    margin: 0;
    grid-template-columns: repeat(6, minmax(0, 1fr));
    border-top: 1px solid currentColor;
    border-left: 1px solid currentColor;
    padding: 0;
    list-style: none;
}

.kd-pipeline__step {
    position: relative;
    min-width: 0;
    min-height: 18rem;
    border-right: 1px solid currentColor;
    border-bottom: 1px solid currentColor;
    padding: 1.35rem;
}

.kd-pipeline__number {
    display: block;
    margin-bottom: clamp(3rem, 6vw, 6rem);
    font-size: 0.68rem;
    font-weight: 600;
    letter-spacing: 0.12em;
    text-transform: uppercase;
}

.kd-pipeline__title {
    margin: 0 0 0.75rem;
    font-size: clamp(1.8rem, 2.2vw, 2.7rem);
    letter-spacing: 0.01em;
    line-height: 0.86;
    text-transform: uppercase;
    overflow-wrap: normal;
    white-space: nowrap;
}

.kd-pipeline__copy {
    margin: 0;
    font-size: 0.78rem;
    line-height: 1.6;
    opacity: 0.7;
}

.kd-pipeline__arrow {
    position: absolute;
    z-index: 2;
    top: 50%;
    right: -0.8rem;
    display: grid;
    width: 1.6rem;
    height: 1.6rem;
    place-items: center;
    transform: translateY(-50%);
    background: var(--lime);
    color: var(--ink);
    font-size: 1rem;
}

.kd-pipeline__step:last-child .kd-pipeline__arrow {
    display: none;
}

.kd-code-panel {
    display: block;
    min-width: 0;
    border: 1px solid currentColor;
    margin: 0;
    padding: clamp(1.5rem, 3vw, 3rem);
    overflow-x: auto;
    background: var(--kd-ink-panel);
    color: var(--paper);
    font-family: var(--mono);
    font-size: clamp(0.7rem, 1.15vw, 0.9rem);
    line-height: 1.75;
    scrollbar-color: var(--lime) var(--ink);
}

.kd-code-panel__copy,
.kd-code-panel__code {
    min-width: 0;
    padding: clamp(1.5rem, 3vw, 3rem);
}

.kd-code-panel__copy {
    border-right: 1px solid currentColor;
}

.kd-code-panel__title {
    margin: 0 0 1rem;
    font-size: clamp(2.8rem, 5vw, 5.5rem);
    letter-spacing: 0;
    line-height: 0.84;
}

.kd-code-panel__copy p {
    margin-bottom: 0;
    font-size: 0.86rem;
    line-height: 1.75;
    opacity: 0.75;
}

.kd-code-panel__code {
    overflow-x: auto;
    background: var(--kd-ink-panel);
    color: var(--paper);
    font-family: var(--mono);
    font-size: clamp(0.7rem, 1.15vw, 0.9rem);
    line-height: 1.75;
    scrollbar-color: var(--lime) var(--ink);
}

.kd-code-panel__code :where(pre, code) {
    margin: 0;
    font: inherit;
    white-space: pre;
}

.kd-code-panel > code {
    font: inherit;
    white-space: pre;
}

.kd-callout {
    display: grid;
    min-width: 0;
    grid-template-columns: minmax(13rem, 0.45fr) minmax(0, 1fr);
    border: 2px solid currentColor;
}

.kd-callout > strong,
.kd-callout > p {
    min-width: 0;
    margin: 0;
    padding: clamp(1.4rem, 3vw, 2.75rem);
}

.kd-callout > strong {
    border-right: 2px solid currentColor;
    font-family: var(--display);
    font-size: clamp(2.7rem, 4.5vw, 4.8rem);
    font-weight: 800;
    letter-spacing: 0;
    line-height: 0.84;
    text-transform: uppercase;
}

.kd-callout > p {
    align-self: center;
    font-size: 0.86rem;
    line-height: 1.75;
}

.kd-callout--lime {
    background: var(--lime);
    color: var(--ink);
}

.kd-callout__label,
.kd-callout__body {
    min-width: 0;
    padding: clamp(1.4rem, 3vw, 2.75rem);
}

.kd-callout__label {
    border-right: 2px solid currentColor;
    font-family: var(--display);
    font-size: clamp(2.8rem, 5vw, 5.2rem);
    font-weight: 800;
    letter-spacing: 0;
    line-height: 0.84;
    text-transform: uppercase;
}

.kd-callout__body :last-child {
    margin-bottom: 0;
}

.kd-callout__body {
    font-size: clamp(0.9rem, 1.4vw, 1.1rem);
    line-height: 1.75;
}

.kd-decision-grid {
    display: grid;
    min-width: 0;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    border-top: 1px solid currentColor;
    border-left: 1px solid currentColor;
}

.kd-decision {
    display: flex;
    min-width: 0;
    min-height: 30rem;
    flex-direction: column;
    border-right: 1px solid currentColor;
    border-bottom: 1px solid currentColor;
    padding: clamp(1.5rem, 3.5vw, 3.5rem);
}

.kd-decision:nth-child(even) {
    background: var(--purple);
    color: var(--paper);
}

.kd-decision--ironflow {
    background: var(--lime);
    color: var(--ink);
}

.kd-decision--competitor {
    background: var(--purple);
    color: var(--paper);
}

.kd-decision-grid:not(.kd-decision-grid--2) .kd-decision:first-child {
    grid-column: 1 / -1;
    min-height: 22rem;
}

.kd-decision-grid:not(.kd-decision-grid--2) .kd-decision--link:last-child {
    background: var(--ink);
    color: var(--paper);
}

.kd-decision__kicker {
    color: currentColor;
}

.kd-decision__title {
    max-width: 12ch;
    margin: 0 0 1.2rem;
    font-size: clamp(3.5rem, 7vw, 7.6rem);
    letter-spacing: -0.01em;
    line-height: 0.8;
}

.kd-decision > h3 {
    max-width: 12ch;
    margin: 0 0 1.2rem;
    font-size: clamp(3.5rem, 7vw, 7.6rem);
    letter-spacing: -0.01em;
    line-height: 0.8;
}

.kd-decision > p:not(.kd-decision__label) {
    max-width: 42rem;
    margin-bottom: 1.5rem;
    line-height: 1.75;
    opacity: 0.8;
}

.kd-decision__label {
    margin: 0 0 3rem;
    font-size: 0.67rem;
    font-weight: 700;
    letter-spacing: 0.11em;
    line-height: 1.4;
    text-transform: uppercase;
}

.kd-decision > ul {
    margin: 0;
    padding: 0;
    list-style: none;
}

.kd-decision > ul li {
    border-top: 1px solid currentColor;
    padding: 0.85rem 0;
    font-size: 0.78rem;
    line-height: 1.55;
}

.kd-decision > ul li::before {
    content: "→ ";
    font-weight: 700;
}

.kd-decision > a,
.kd-decision > span:last-child {
    margin-top: auto;
    padding-top: 2rem;
    font-size: 0.7rem;
    font-weight: 700;
    letter-spacing: 0.07em;
    text-decoration: underline;
    text-transform: uppercase;
}

.kd-decision__copy {
    max-width: 39rem;
    margin-bottom: 1.5rem;
    line-height: 1.75;
    opacity: 0.82;
}

.kd-decision__list {
    margin: 0;
    padding: 0;
    list-style: none;
}

.kd-decision__list li {
    border-top: 1px solid currentColor;
    padding: 0.8rem 0;
    font-size: 0.78rem;
    line-height: 1.5;
}

.kd-decision__list li::before {
    content: "→ ";
    font-weight: 700;
}

.kd-decision__actions {
    margin-top: auto;
    padding-top: 2rem;
}

.kd-matrix-wrap {
    min-width: 0;
    overflow-x: auto;
    border: 1px solid currentColor;
    scrollbar-color: var(--purple) transparent;
}

.kd-matrix {
    width: 100%;
    min-width: 47rem;
    border-collapse: collapse;
    table-layout: fixed;
    text-align: left;
}

.kd-matrix th,
.kd-matrix td {
    min-width: 0;
    border-right: 1px solid currentColor;
    border-bottom: 1px solid currentColor;
    padding: clamp(1rem, 2.5vw, 2rem);
    vertical-align: top;
    overflow-wrap: anywhere;
}

.kd-matrix tr > :last-child {
    border-right: 0;
}

.kd-matrix tbody tr:last-child > * {
    border-bottom: 0;
}

.kd-matrix thead th {
    background: var(--ink);
    color: var(--paper);
    font-family: var(--display);
    font-size: clamp(2.1rem, 3.5vw, 3.5rem);
    font-weight: 800;
    letter-spacing: 0.01em;
    line-height: 0.9;
}

.kd-matrix thead th:nth-child(2) {
    background: var(--lime);
    color: var(--ink);
}

.kd-matrix thead th:nth-child(3) {
    background: var(--purple);
    color: var(--paper);
}

.kd-matrix tbody th {
    width: 23%;
    font-size: 0.7rem;
    font-weight: 700;
    letter-spacing: 0.08em;
    line-height: 1.5;
    text-transform: uppercase;
}

.kd-matrix td {
    font-size: 0.82rem;
    line-height: 1.65;
}

.kd-matrix :where(td, th) :last-child {
    margin-bottom: 0;
}

.kd-architecture {
    display: grid;
    min-width: 0;
    gap: 1rem;
    margin: 0;
    padding: 0;
    list-style: none;
}

.kd-architecture__lane {
    display: grid;
    min-width: 0;
    grid-template-columns: minmax(8rem, 0.2fr) minmax(0, 1fr);
    align-items: stretch;
    border: 1px solid currentColor;
}

.kd-architecture__lane > strong {
    display: flex;
    min-height: 7rem;
    align-items: center;
    border-right: 1px solid currentColor;
    padding: 1.2rem;
    font-family: var(--display);
    font-size: clamp(2rem, 3vw, 3.2rem);
    font-weight: 800;
    line-height: 0.9;
    text-transform: uppercase;
}

.kd-architecture__lane > span {
    display: flex;
    align-items: center;
    padding: 1.2rem;
    font-size: 0.68rem;
    font-weight: 600;
    letter-spacing: 0.08em;
    line-height: 1.45;
    text-transform: uppercase;
}

.kd-architecture__lane--ironflow {
    background: var(--lime);
    color: var(--ink);
}

.kd-architecture--hero .kd-architecture__lane {
    grid-template-columns: minmax(13rem, 0.5fr) minmax(0, 1fr);
}

.kd-architecture--hero .kd-architecture__lane > strong {
    font-size: clamp(1.8rem, 2.6vw, 2.8rem);
    overflow-wrap: normal;
    white-space: nowrap;
}

.kd-architecture__label {
    display: flex;
    min-height: 7rem;
    align-items: center;
    margin: 0;
    border-right: 1px solid currentColor;
    padding: 1.2rem;
    color: currentColor;
}

.kd-architecture__nodes {
    display: flex;
    min-width: 0;
    align-items: stretch;
    padding: 1rem;
    overflow-x: auto;
}

.kd-architecture__node {
    display: inline-flex;
    min-width: 9rem;
    min-height: 5rem;
    align-items: center;
    justify-content: center;
    border: 1px solid currentColor;
    padding: 0.8rem;
    font-size: 0.68rem;
    font-weight: 600;
    letter-spacing: 0.07em;
    line-height: 1.35;
    text-align: center;
    text-transform: uppercase;
}

.kd-architecture__step {
    display: grid;
    min-width: 8rem;
    min-height: 5rem;
    flex: 1 1 0;
    grid-template-columns: minmax(0, 1fr) 2.5rem;
    align-items: stretch;
    border: 1px solid currentColor;
    font-size: 0.66rem;
    font-weight: 600;
    letter-spacing: 0.06em;
    line-height: 1.35;
    text-transform: uppercase;
}

.kd-architecture__step:last-child {
    grid-template-columns: minmax(0, 1fr);
}

.kd-architecture__step-label {
    display: flex;
    min-width: 0;
    align-items: center;
    padding: 0.75rem 1rem;
    overflow-wrap: anywhere;
}

.kd-architecture__step-arrow {
    display: grid;
    width: 2.5rem;
    min-width: 2.5rem;
    place-items: center;
    border-left: 1px solid currentColor;
    font-style: normal;
}

.kd-architecture__arrow {
    display: inline-grid;
    min-width: 2.5rem;
    place-items: center;
    font-size: 1.1rem;
}

/* Operating model -------------------------------------------------------- */

.kd-ops-grid {
    display: grid;
    min-width: 0;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    border-top: 1px solid currentColor;
    border-left: 1px solid currentColor;
}

.kd-ops-card {
    display: flex;
    min-width: 0;
    min-height: 24rem;
    flex-direction: column;
    border-right: 1px solid currentColor;
    border-bottom: 1px solid currentColor;
    padding: clamp(1.4rem, 2.7vw, 2.6rem);
}

.kd-ops-card:first-child {
    background: var(--lime);
    color: var(--ink);
}

.kd-ops-card:nth-child(even) {
    background: var(--ink);
    color: var(--paper);
}

.kd-ops-card > :first-child:not(h3) {
    margin-bottom: 2.5rem;
    font-size: 0.65rem;
    font-weight: 700;
    letter-spacing: 0.11em;
    line-height: 1.45;
    text-transform: uppercase;
}

.kd-ops-card > h3 {
    max-width: 12ch;
    margin: 0 0 1rem;
    font-size: clamp(2.8rem, 4.6vw, 5rem);
    letter-spacing: 0;
    line-height: 0.84;
    overflow-wrap: normal;
    text-wrap: balance;
}

.kd-ops-card > p:not(:first-child) {
    margin-bottom: 1.5rem;
    font-size: 0.83rem;
    line-height: 1.7;
    opacity: 0.78;
}

.kd-ops-command {
    display: block;
    width: 100%;
    min-width: 0;
    margin-top: auto;
    border: 1px solid currentColor;
    padding: 1rem;
    overflow-x: auto;
    background: var(--ink);
    color: var(--lime);
    font-family: var(--mono);
    font-size: clamp(0.68rem, 1vw, 0.82rem);
    font-weight: 500;
    line-height: 1.65;
    white-space: pre-wrap;
    overflow-wrap: anywhere;
    scrollbar-color: var(--lime) var(--ink);
}

pre.kd-ops-command {
    margin-bottom: 0;
}

.kd-ops-command + p,
.kd-placement-list + p {
    margin-top: 1.25rem;
}

.kd-ops-command code {
    color: inherit;
    font: inherit;
    white-space: inherit;
}

.kd-placement-list {
    margin: auto 0 0;
    border-top: 1px solid currentColor;
    padding: 0;
    list-style: none;
}

.kd-placement-list > li {
    display: grid;
    min-width: 0;
    grid-template-columns: 1.75rem minmax(0, 1fr);
    gap: 0.7rem;
    border-bottom: 1px solid currentColor;
    padding: 0.82rem 0;
    font-size: 0.72rem;
    line-height: 1.55;
}

.kd-placement-list > li::before {
    content: "→";
    font-weight: 700;
}

.kd-placement-list > li:last-child {
    border-bottom: 0;
}

.kd-placement-list strong {
    display: block;
    margin-bottom: 0.15rem;
    font-size: 0.69rem;
    letter-spacing: 0.06em;
    text-transform: uppercase;
}

/* Trust boundary --------------------------------------------------------- */

.kd-trust-grid {
    display: grid;
    min-width: 0;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    border-top: 1px solid currentColor;
    border-left: 1px solid currentColor;
}

.kd-trust-card {
    position: relative;
    min-width: 0;
    min-height: 21rem;
    border-right: 1px solid currentColor;
    border-bottom: 1px solid currentColor;
    padding: clamp(1.4rem, 2.7vw, 2.6rem);
}

.kd-trust-card:nth-child(2) {
    background: var(--lime);
    color: var(--ink);
}

.kd-trust-card > :first-child:not(h3) {
    margin-bottom: clamp(3rem, 6vw, 6.5rem);
    font-size: 0.65rem;
    font-weight: 700;
    letter-spacing: 0.11em;
    line-height: 1.4;
    text-transform: uppercase;
}

.kd-trust-card > h3 {
    max-width: 14ch;
    margin: 0 0 1rem;
    font-size: clamp(2.6rem, 4.2vw, 4.6rem);
    letter-spacing: 0;
    line-height: 0.86;
    overflow-wrap: normal;
    text-wrap: balance;
}

.kd-trust-card > p:not(:first-child),
.kd-trust-card > ul {
    margin-bottom: 0;
    font-size: 0.8rem;
    line-height: 1.7;
    opacity: 0.78;
}

.kd-trust-card > ul {
    padding-left: 1rem;
}

.kd-trust-card > p + ul {
    margin-top: 1.25rem;
}

.kd-trust-card > ul li + li {
    margin-top: 0.55rem;
}

.kd-trust-note {
    display: grid;
    min-width: 0;
    grid-column: 1 / -1;
    grid-template-columns: minmax(11rem, 0.32fr) minmax(0, 1fr);
    border-right: 1px solid currentColor;
    border-bottom: 1px solid currentColor;
    background: var(--red);
    color: var(--paper);
}

.kd-trust-note > * {
    min-width: 0;
    margin: 0;
    padding: clamp(1.3rem, 2.5vw, 2.4rem);
}

.kd-trust-note > :first-child {
    border-right: 1px solid currentColor;
    font-family: var(--display);
    font-size: clamp(2.4rem, 4vw, 4.2rem);
    font-weight: 800;
    letter-spacing: 0.01em;
    line-height: 0.86;
    text-transform: uppercase;
}

.kd-trust-note > :last-child {
    align-self: center;
    font-size: 0.82rem;
    line-height: 1.7;
}

.kd-trust-note code {
    display: inline;
    padding: 0.12rem 0.3rem;
    background: var(--ink);
    color: var(--lime);
    font-family: var(--mono);
    font-size: 0.9em;
    overflow-wrap: anywhere;
}

.kd-source-list {
    display: grid;
    margin: 0;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    border-top: 1px solid currentColor;
    border-left: 1px solid currentColor;
    padding: 0;
    list-style: none;
}

.kd-source-list__item,
.kd-source-list li {
    min-width: 0;
    border-right: 1px solid currentColor;
    border-bottom: 1px solid currentColor;
}

.kd-source-list a {
    display: flex;
    min-height: 5.5rem;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
    padding: 1rem 1.3rem;
    font-size: 0.72rem;
    font-weight: 600;
    letter-spacing: 0.04em;
    line-height: 1.45;
    text-decoration: none;
    text-transform: uppercase;
    transition:
        background-color var(--kd-motion-interactive) ease,
        color var(--kd-motion-interactive) ease;
}

.kd-source-list a > span:last-child {
    flex: 0 0 auto;
    font-size: 1rem;
}

.kd-source-list a:hover {
    background: var(--lime);
    color: var(--ink);
}

.kd-cta {
    display: grid;
    min-height: 34rem;
    grid-template-columns: minmax(0, 1fr) auto;
    align-items: end;
    gap: clamp(2rem, 6vw, 7rem);
    padding-top: clamp(5rem, 9vw, 9rem);
    padding-bottom: clamp(5rem, 9vw, 9rem);
}

.kd-cta__copy {
    min-width: 0;
}

.kd-cta > div:first-child {
    min-width: 0;
}

.kd-cta__title,
.kd-cta h2 {
    max-width: 12ch;
    margin: 0;
    font-size: clamp(4.7rem, 10vw, 11rem);
    letter-spacing: -0.015em;
    line-height: 0.78;
    text-wrap: balance;
}

.kd-cta__lede,
.kd-cta > div:first-child > p:last-child {
    max-width: 46rem;
    margin: clamp(3rem, 3.5vw, 4rem) 0 0;
    font-size: 0.92rem;
    line-height: 1.75;
    opacity: 0.75;
}

.kd-inline-link {
    display: inline-flex;
    margin-top: 1.5rem;
    color: var(--lime);
    font-size: 0.68rem;
    font-weight: 700;
    letter-spacing: 0.06em;
    line-height: 1.5;
    text-transform: uppercase;
}

.kd-inline-link:hover {
    color: var(--paper);
}

.kd-band__inner.kd-grid > * {
    min-width: 0;
    border-right: 1px solid currentColor;
    border-bottom: 1px solid currentColor;
    padding: clamp(1.5rem, 3vw, 3rem);
}

.kd-band__inner.kd-grid > .kd-section-head {
    margin-bottom: 0;
}

.kd-band__inner.kd-grid > .kd-code-panel {
    border-top: 0;
    border-left: 0;
}

.kd-cta__actions {
    justify-content: flex-end;
}

.kd-band--lime .kd-button--outline,
.kd-band--paper .kd-button--outline {
    border-color: var(--ink);
    color: var(--ink);
}

.kd-band--lime .kd-button--outline:hover,
.kd-band--paper .kd-button--outline:hover {
    background: var(--ink);
    color: var(--paper);
}

.kd-band--lime .kd-card[href]:hover,
.kd-band--paper .kd-card[href]:hover {
    background: var(--ink);
    color: var(--paper);
}

.reveal-ready .kd-page [data-reveal] {
    opacity: 0;
    transform: translateY(2rem);
    transition:
        opacity var(--kd-motion-reveal) ease,
        transform var(--kd-motion-reveal) var(--kd-ease-kinetic);
}

.reveal-ready .kd-page [data-reveal].is-visible {
    opacity: 1;
    transform: translateY(0);
}

.reveal-ready .kd-page [data-reveal] :where(.kd-card, .kd-pipeline__step, .kd-route__item) {
    opacity: 0;
    transform: translateY(1.5rem);
    transition:
        opacity 520ms ease,
        transform 520ms var(--kd-ease-kinetic);
}

.reveal-ready .kd-page [data-reveal].is-visible :where(.kd-card, .kd-pipeline__step, .kd-route__item) {
    opacity: 1;
    transform: translateY(0);
}

.reveal-ready .kd-page [data-reveal].is-visible :where(.kd-card, .kd-pipeline__step, .kd-route__item):nth-child(2) {
    transition-delay: 80ms;
}

.reveal-ready .kd-page [data-reveal].is-visible :where(.kd-card, .kd-pipeline__step, .kd-route__item):nth-child(3) {
    transition-delay: 160ms;
}

.reveal-ready .kd-page [data-reveal].is-visible :where(.kd-card, .kd-pipeline__step, .kd-route__item):nth-child(4) {
    transition-delay: 240ms;
}

.reveal-ready .kd-page [data-reveal].is-visible :where(.kd-card, .kd-pipeline__step, .kd-route__item):nth-child(5) {
    transition-delay: 320ms;
}

.reveal-ready .kd-page [data-reveal].is-visible :where(.kd-card, .kd-pipeline__step, .kd-route__item):nth-child(6) {
    transition-delay: 400ms;
}

@keyframes kd-route-scan {
    0%,
    12% {
        transform: translateX(-110%);
    }

    72%,
    100% {
        transform: translateX(420%);
    }
}

@media (max-width: 1100px) {
    .kd-rag-fit {
        grid-template-columns: minmax(0, 1fr);
    }

    .kd-rag-fit__cards .kd-card__title {
        font-size: clamp(3rem, 6vw, 4rem);
    }

    .kd-page-hero__inner {
        grid-template-columns: minmax(0, 1fr);
        gap: 4rem;
        padding-bottom: 5rem;
    }

    .kd-page-hero__copy {
        max-width: 58rem;
    }

    .kd-page-hero__visual {
        max-width: 52rem;
    }

    .kd-page-hero__title {
        font-size: clamp(5.2rem, 13.5vw, 9.5rem);
    }

    .kd-section-head {
        grid-template-columns: minmax(0, 1fr) minmax(15rem, 0.65fr);
    }

    .kd-grid--4 {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .kd-grid--3 {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .kd-grid--3 > :last-child {
        grid-column: 1 / -1;
    }

    .kd-proof-rail {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .kd-pipeline {
        grid-template-columns: repeat(3, minmax(0, 1fr));
    }

    .kd-pipeline__step {
        min-height: 15rem;
    }

    .kd-decision {
        min-height: 27rem;
    }

    .kd-cta {
        grid-template-columns: minmax(0, 1fr);
    }

    .kd-cta__actions {
        justify-content: flex-start;
    }
}

@media (max-width: 760px) {
    .kd-page-hero {
        min-height: 0;
        background: var(--ink);
    }

    .kd-page-hero::before {
        width: 100%;
        opacity: 0.65;
    }

    .kd-page-hero__inner {
        min-height: 0;
        gap: 3rem;
        padding-top: 7.25rem;
        padding-bottom: 3.5rem;
    }

    .kd-page-hero__title {
        max-width: 10ch;
        font-size: clamp(4rem, 19vw, 7.2rem);
        letter-spacing: -0.005em;
        line-height: 0.82;
    }

    .kd-page-hero--compact .kd-page-hero__title {
        font-size: clamp(3.9rem, 17vw, 6.6rem);
    }

    .kd-page-hero__lede {
        line-height: 1.6;
    }

    .kd-route__item {
        min-height: 7.5rem;
    }

    .kd-route__number {
        margin-bottom: 1.3rem;
    }

    .kd-proof-rail {
        grid-template-columns: 1fr;
    }

    .kd-proof-rail__item {
        display: grid;
        grid-template-columns: minmax(6.5rem, auto) minmax(0, 1fr);
        align-items: baseline;
        gap: 1rem;
        border-right: 0;
        border-bottom: 1px solid rgba(5, 6, 22, 0.22);
        padding-top: 1.4rem;
        padding-bottom: 1.4rem;
    }

    .kd-proof-rail__item:last-child {
        border-bottom: 0;
    }

    .kd-proof-rail__value {
        margin: 0;
        font-size: 3.2rem;
    }

    .kd-section-head {
        grid-template-columns: minmax(0, 1fr);
        gap: 1.5rem;
    }

    .kd-section-head__title {
        font-size: clamp(3.7rem, 17vw, 6.2rem);
        line-height: 0.82;
    }

    .kd-grid--2,
    .kd-grid--3,
    .kd-grid--4 {
        grid-template-columns: minmax(0, 1fr);
    }

    .kd-grid--3 > :last-child {
        grid-column: auto;
    }

    .kd-card,
    .kd-card--compact {
        min-height: 15rem;
    }

    .kd-pipeline {
        grid-template-columns: minmax(0, 1fr);
    }

    .kd-pipeline__step {
        min-height: 0;
        padding: 1.3rem 3.25rem 1.5rem 1.3rem;
    }

    .kd-pipeline__number {
        margin-bottom: 2.25rem;
    }

    .kd-pipeline__arrow {
        top: auto;
        right: 1rem;
        bottom: -0.8rem;
        transform: rotate(90deg);
    }

    .kd-code-panel,
    .kd-callout {
        grid-template-columns: minmax(0, 1fr);
    }

    .kd-code-panel__copy,
    .kd-callout__label {
        border-right: 0;
        border-bottom: 1px solid currentColor;
    }

    .kd-callout > strong {
        border-right: 0;
        border-bottom: 2px solid currentColor;
    }

    .kd-callout__label {
        min-height: 0;
        border-bottom-width: 2px;
    }

    .kd-decision-grid {
        grid-template-columns: minmax(0, 1fr);
    }

    .kd-decision {
        min-height: 25rem;
    }

    .kd-decision__title {
        font-size: clamp(3.6rem, 17vw, 6rem);
    }

    .kd-architecture__lane {
        grid-template-columns: minmax(0, 1fr);
    }

    .kd-architecture--hero .kd-architecture__lane {
        grid-template-columns: minmax(0, 1fr);
    }

    .kd-architecture__label {
        min-height: 0;
        border-right: 0;
        border-bottom: 1px solid currentColor;
    }

    .kd-architecture__lane > strong {
        min-height: 0;
        border-right: 0;
        border-bottom: 1px solid currentColor;
    }

    .kd-ops-grid,
    .kd-trust-grid {
        grid-template-columns: minmax(0, 1fr);
    }

    .kd-ops-card,
    .kd-trust-card {
        min-height: 0;
    }

    .kd-ops-card > h3,
    .kd-trust-card > h3 {
        font-size: clamp(3rem, 13vw, 5rem);
    }

    .kd-trust-note {
        grid-template-columns: minmax(0, 1fr);
    }

    .kd-trust-note > :first-child {
        border-right: 0;
        border-bottom: 1px solid currentColor;
    }

    .kd-source-list {
        grid-template-columns: minmax(0, 1fr);
    }

    .kd-source-list a {
        min-height: 4.75rem;
    }

    .kd-cta {
        min-height: 30rem;
    }

    .kd-cta__title {
        font-size: clamp(4rem, 19vw, 7.3rem);
        line-height: 0.82;
    }

    .kd-cta h2 {
        font-size: clamp(4rem, 19vw, 7.3rem);
        line-height: 0.82;
    }
}

@media (max-width: 430px) {
    .kd-page-hero__actions,
    .kd-card__actions,
    .kd-decision__actions,
    .kd-cta__actions {
        align-items: stretch;
        flex-direction: column;
    }

    .kd-button {
        width: 100%;
    }

    .kd-button--text {
        width: auto;
        align-self: flex-start;
    }

    .kd-route {
        grid-template-columns: minmax(0, 1fr);
    }

    .kd-route__item {
        min-height: 6.5rem;
    }

    .kd-route__number {
        margin-bottom: 0.9rem;
    }

    .kd-route__title,
    .kd-route__name {
        font-size: 2rem;
    }

    .kd-proof-rail__item {
        grid-template-columns: minmax(0, 1fr);
        gap: 0.3rem;
    }

    .kd-card__title {
        font-size: 2.9rem;
    }

    .kd-decision > h3 {
        font-size: clamp(3.4rem, 17vw, 5.7rem);
    }

    .kd-ops-card,
    .kd-trust-card {
        padding: 1.25rem;
    }

    .kd-ops-card > h3,
    .kd-trust-card > h3 {
        font-size: clamp(2.8rem, 15vw, 4.2rem);
    }

    .kd-ops-command {
        font-size: 0.65rem;
    }

    .kd-trust-note > :first-child {
        font-size: clamp(2.5rem, 13vw, 3.6rem);
    }

    .kd-decision {
        min-height: 0;
    }

    .kd-architecture__nodes {
        align-items: stretch;
        flex-direction: column;
    }

    .kd-architecture__node {
        width: 100%;
        min-height: 4rem;
    }

    .kd-architecture__step {
        width: 100%;
        min-width: 0;
        min-height: 4rem;
        flex: 0 0 auto;
    }

    .kd-architecture__arrow {
        min-height: 2rem;
        transform: rotate(90deg);
    }

    .kd-matrix {
        min-width: 40rem;
    }

    .kd-matrix th,
    .kd-matrix td {
        padding: 1rem;
    }
}

html[data-motion="off"] .kd-page *,
html[data-motion="off"] .kd-page *::before,
html[data-motion="off"] .kd-page *::after {
    animation: none !important;
    transition: none !important;
}

html[data-motion="off"] .kd-page [data-reveal],
html[data-motion="off"] .kd-page [data-reveal] :where(.kd-card, .kd-pipeline__step, .kd-route__item) {
    opacity: 1 !important;
    transform: none !important;
}

@media (prefers-reduced-motion: reduce) {
    .kd-page *,
    .kd-page *::before,
    .kd-page *::after {
        animation: none !important;
        transition: none !important;
    }

    .reveal-ready .kd-page [data-reveal],
    .reveal-ready .kd-page [data-reveal] :where(.kd-card, .kd-pipeline__step, .kd-route__item) {
        opacity: 1;
        transform: none;
    }
}
