/* Hands & Hearts — product story layers
   1. .mk-*   "What can I find here?" pinned market journey (MarketStory)
   2. .mk-screen-* phone screen rendition (ListingScreen)
   3. .bf-*   "For businesses" connected flow (BusinessFlow)
   4. hero depth + Spline slot helpers
   Motion rules: transforms + opacity only. When GSAP drives a section
   (.mk-story--gsap) the CSS transitions below are switched off so the two
   never fight. Without JS motion, data-active attributes carry the state. */

/* ------------------------------------------------------------------ */
/* 1. Market story                                                      */
/* ------------------------------------------------------------------ */

.mk-story {
    --mk-bg: #f7f4ff;
    --mk-bg-2: #ffffff;
    --mk-ink: var(--hh-ink);
    --mk-muted: var(--hh-muted);
    --mk-line: var(--hh-line);
    --mk-card: rgba(255, 255, 255, 0.92);
    --accent: var(--hh-primary);
    position: relative;
    isolation: isolate;
    color: var(--mk-ink);
    background:
        radial-gradient(70% 40% at 50% 0%, color-mix(in srgb, var(--accent) 14%, transparent), transparent 70%),
        linear-gradient(180deg, var(--mk-bg) 0%, var(--mk-bg-2) 100%);
    transition: background 900ms ease;
    overflow-x: clip;
}

.dark .mk-story {
    --mk-bg: #0d1015;
    --mk-bg-2: #12101e;
    --mk-card: rgba(23, 20, 41, 0.92);
}

.mk-story__intro {
    width: min(46rem, 100%);
    margin: 0 auto;
    padding: clamp(3.5rem, 8vh, 6rem) 1.25rem 1rem;
    display: grid;
    justify-items: center;
    gap: 0.9rem;
    text-align: center;
}

.mk-story__intro h2 {
    margin: 0;
    max-width: 20ch;
    font-size: clamp(1.9rem, 4.2vw, 3.2rem);
    font-weight: 800;
    letter-spacing: -0.04em;
    line-height: 1.08;
    text-wrap: balance;
}

.mk-story--khmer .mk-story__intro h2,
.mk-story--khmer .mk-chapter h3,
.bf--khmer h2,
.bf--khmer h3 {
    letter-spacing: 0;
    line-height: 1.4;
    font-family: var(--hh-font-khmer-display);
    font-weight: 400;
}

.mk-story__lead {
    margin: 0;
    max-width: 38rem;
    color: var(--mk-muted);
    font-size: clamp(1rem, 1.25vw, 1.12rem);
    line-height: 1.55;
    text-wrap: pretty;
}

.mk-story__scroll {
    width: min(78rem, 100%);
    margin: 0 auto;
    padding: 0 clamp(1rem, 4vw, 3rem) clamp(2rem, 5vh, 4rem);
    display: grid;
    grid-template-columns: minmax(0, 1.15fr) minmax(18rem, 0.85fr);
    gap: clamp(1.5rem, 4vw, 4rem);
    align-items: start;
}

/* --- Stage (sticky, desktop) --- */

.mk-stage {
    position: sticky;
    top: 0;
    height: 100svh;
    display: grid;
    place-items: center;
    padding: 3.5rem 0 3rem;
    perspective: 1400px;
}

.mk-stage__plates {
    position: absolute;
    inset: 4.5rem 0 3.5rem;
    border-radius: 1.75rem;
    overflow: hidden;
    transform-origin: 50% 60%;
    will-change: transform;
    box-shadow: 0 40px 80px -40px rgba(51, 42, 80, 0.5);
}

.mk-plate {
    position: absolute;
    inset: 0;
    background-size: cover;
    background-position: center 40%;
    opacity: 0;
}

.mk-plate img {
    display: block;
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: center 40%;
}

/* No-JS-motion state (reduced motion on desktop): show the active plate. */
.mk-story:not(.mk-story--gsap) .mk-plate[data-active='true'],
.mk-story:not(.mk-story--gsap) .mk-plate[data-behind='true'] {
    opacity: 1;
}

.mk-stage__grade {
    position: absolute;
    inset: 4.5rem 0 3.5rem;
    border-radius: 1.75rem;
    pointer-events: none;
    background:
        linear-gradient(180deg, rgba(13, 16, 21, 0.05), transparent 30%, rgba(13, 16, 21, 0.35) 100%),
        radial-gradient(60% 60% at 50% 100%, color-mix(in srgb, var(--accent) 34%, transparent), transparent 70%);
    transition: background 900ms ease;
}

.dark .mk-stage__grade {
    background:
        linear-gradient(180deg, rgba(13, 16, 21, 0.35), rgba(13, 16, 21, 0.15) 30%, rgba(13, 16, 21, 0.6) 100%),
        radial-gradient(60% 60% at 50% 100%, color-mix(in srgb, var(--accent) 40%, transparent), transparent 70%);
}

.dark .mk-plate img {
    filter: saturate(0.85) brightness(0.72) contrast(1.05);
}

.mk-stage__device {
    position: relative;
    z-index: 3;
    width: min(26rem, 42vw, calc((100svh - 7rem) / 1.72));
    transform-style: preserve-3d;
    will-change: transform;
}

.mk-phone .phone-mockup__shell {
    width: 100% !important;
    filter: drop-shadow(0 40px 60px rgba(13, 16, 21, 0.45)) drop-shadow(0 10px 18px rgba(13, 16, 21, 0.25));
}

/* Floating example listings around the phone */
.mk-stage__cards {
    position: absolute;
    inset: 4.5rem 0 3.5rem;
    pointer-events: none;
    z-index: 4;
}

.mk-stage__cardset {
    position: absolute;
    inset: 0;
}

.mk-card {
    position: absolute;
    display: flex;
    align-items: center;
    gap: 0.7rem;
    width: min(17rem, 42%);
    padding: 0.75rem 0.85rem;
    border-radius: 1rem;
    background: var(--mk-card);
    border: 1px solid var(--mk-line);
    box-shadow: 0 24px 48px -24px rgba(13, 16, 21, 0.5), inset 0 1px 0 rgba(255, 255, 255, 0.5);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    color: var(--mk-ink);
    will-change: transform, opacity;
}

/* Cards sit on the side opposite the phone. */
.mk-stage[data-side='right'] .mk-card--a { left: 6%; top: 18%; }
.mk-stage[data-side='right'] .mk-card--b { left: 10%; bottom: 20%; }
.mk-stage[data-side='left'] .mk-card--a { right: 6%; top: 20%; }
.mk-stage[data-side='left'] .mk-card--b { right: 10%; bottom: 18%; }

.mk-card__icon {
    display: grid;
    place-items: center;
    flex: none;
    width: 2.25rem;
    height: 2.25rem;
    border-radius: 0.7rem;
    color: #fff;
    background: var(--accent);
    box-shadow: 0 10px 20px -12px var(--accent);
}

.mk-card__body {
    display: grid;
    gap: 0.1rem;
    min-width: 0;
    flex: 1;
}

.mk-card__body strong {
    font-size: 0.86rem;
    font-weight: 700;
    line-height: 1.25;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.mk-card__body small {
    color: var(--mk-muted);
    font-size: 0.72rem;
    line-height: 1.3;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.mk-card__price {
    flex: none;
    padding: 0.28rem 0.55rem;
    border-radius: 999px;
    background: color-mix(in srgb, var(--accent) 14%, transparent);
    color: var(--accent);
    font-size: 0.74rem;
    font-weight: 800;
    white-space: nowrap;
}

.dark .mk-card__price {
    background: color-mix(in srgb, var(--accent) 28%, transparent);
    color: #fff;
}

/* State without GSAP */
.mk-story:not(.mk-story--gsap) .mk-stage__cardset {
    opacity: 0;
}

.mk-story:not(.mk-story--gsap) .mk-stage__cardset[data-active='true'] {
    opacity: 1;
}

.mk-stage__dots {
    position: absolute;
    left: 50%;
    bottom: 1.1rem;
    z-index: 5;
    display: flex;
    gap: 0.45rem;
    margin: 0;
    padding: 0;
    list-style: none;
    transform: translateX(-50%);
}

.mk-stage__dots li {
    width: 0.5rem;
    height: 0.5rem;
    border-radius: 999px;
    background: var(--mk-line);
    transition: background 300ms ease, transform 300ms ease;
}

.mk-stage__dots li[data-active='true'] {
    background: var(--accent);
    transform: scale(1.35);
}

/* --- Chapters (copy column) --- */

.mk-chapters {
    display: grid;
    min-width: 0;
}

.mk-chapter {
    display: grid;
    align-items: center;
    min-height: 100svh;
    padding: 2rem 0;
}

.mk-chapter__copy > * {
    transition: opacity 480ms ease, transform 560ms cubic-bezier(0.2, 0.7, 0.2, 1);
}

.mk-story--gsap .mk-chapter__copy > *,
.mk-story .mk-chapter[data-active='false'] .mk-chapter__copy > * {
    opacity: 0.22;
    transform: translateY(10px);
}

.mk-story .mk-chapter[data-active='true'] .mk-chapter__copy > * {
    opacity: 1;
    transform: translateY(0);
}

.mk-chapter__step {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    margin: 0 0 0.9rem;
    color: var(--mk-muted);
    font-size: 0.76rem;
    font-weight: 800;
    letter-spacing: 0.12em;
    text-transform: uppercase;
}

.mk-story--khmer .mk-chapter__step {
    letter-spacing: 0;
    text-transform: none;
}

.mk-chapter__glyph {
    display: grid;
    place-items: center;
    width: 2rem;
    height: 2rem;
    border-radius: 999px;
    color: #fff;
    background: var(--accent);
}

.mk-chapter h3 {
    margin: 0;
    max-width: 16ch;
    font-size: clamp(1.75rem, 3.2vw, 2.7rem);
    font-weight: 800;
    letter-spacing: -0.04em;
    line-height: 1.12;
    text-wrap: pretty;
}

.mk-chapter__body {
    margin: 1rem 0 0;
    max-width: 34rem;
    color: var(--mk-muted);
    font-size: clamp(1rem, 1.2vw, 1.1rem);
    line-height: 1.55;
    text-wrap: pretty;
}

.mk-chapter__stats {
    display: flex;
    flex-wrap: wrap;
    gap: 0.45rem;
    margin: 1.1rem 0 0;
    padding: 0;
    list-style: none;
}

.mk-chapter__stats li {
    padding: 0.38rem 0.7rem;
    border: 1px solid var(--mk-line);
    border-radius: 999px;
    background: color-mix(in srgb, var(--accent) 7%, transparent);
    font-size: 0.78rem;
    font-weight: 600;
    line-height: 1.3;
}

.mk-chapter__cta {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    margin-top: 1.4rem;
    min-height: 2.9rem;
    padding: 0.6rem 1.15rem;
    border-radius: 0.9rem;
    background: var(--mk-ink);
    color: var(--hh-bg);
    font-weight: 700;
    font-size: 0.92rem;
    text-decoration: none;
    box-shadow: 0 18px 36px -20px rgba(13, 16, 21, 0.7);
    transition: transform 180ms ease, box-shadow 180ms ease;
}

.mk-chapter__cta:hover {
    transform: translateY(-2px);
    box-shadow: 0 22px 40px -20px rgba(13, 16, 21, 0.8);
}

.mk-chapter__cta:focus-visible {
    outline: 3px solid var(--accent);
    outline-offset: 3px;
}

.mk-chapter__cta svg {
    transition: transform 180ms ease;
}

.mk-chapter__cta:hover svg {
    transform: translateX(3px);
}

/* Mobile-only pieces are hidden on desktop by default */
.mk-chapter__plate,
.mk-chapter__examples {
    display: none;
}

/* ------------------------------------------------------------------ */
/* 2. Phone screen rendition (390 × 844 logical)                        */
/* ------------------------------------------------------------------ */

.mk-screen {
    --accent: var(--hh-primary);
    position: relative;
    width: 390px;
    height: 844px;
    display: grid;
    grid-template-rows: auto auto auto 1fr auto;
    gap: 14px;
    padding: 58px 18px 18px;
    box-sizing: border-box;
    overflow: hidden;
    color: #0d1015;
    background: linear-gradient(180deg, #f7f4ff 0%, #ffffff 30%);
    font-family: var(--hh-font);
    text-align: left;
}

.mk-story--khmer .mk-screen {
    font-family: var(--hh-font-khmer);
}

.dark .mk-screen {
    color: #f5f0fe;
    background: linear-gradient(180deg, #14112a 0%, #0d1015 30%);
}

.mk-screen__top {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0 6px;
    font-size: 15px;
    font-weight: 700;
}

.mk-screen__signal {
    display: inline-flex;
    gap: 3px;
    align-items: flex-end;
}

.mk-screen__signal i {
    display: block;
    width: 4px;
    border-radius: 1px;
    background: currentColor;
}

.mk-screen__signal i:nth-child(1) { height: 6px; }
.mk-screen__signal i:nth-child(2) { height: 9px; }
.mk-screen__signal i:nth-child(3) { height: 12px; }

.mk-screen__search {
    display: flex;
    align-items: center;
    gap: 10px;
    height: 46px;
    padding: 0 16px;
    border-radius: 14px;
    background: rgba(13, 16, 21, 0.06);
    color: rgba(13, 16, 21, 0.55);
    font-size: 15px;
}

.dark .mk-screen__search {
    background: rgba(255, 255, 255, 0.08);
    color: rgba(245, 240, 254, 0.6);
}

.mk-screen__tabs {
    display: flex;
    gap: 8px;
    margin: 0;
    padding: 0;
    list-style: none;
    overflow: hidden;
}

.mk-screen__tab {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    flex: none;
    height: 34px;
    padding: 0 12px;
    border-radius: 999px;
    border: 1px solid rgba(13, 16, 21, 0.1);
    font-size: 13px;
    font-weight: 600;
    color: rgba(13, 16, 21, 0.7);
    transition: background 300ms ease, color 300ms ease;
}

.dark .mk-screen__tab {
    border-color: rgba(255, 255, 255, 0.12);
    color: rgba(245, 240, 254, 0.7);
}

.mk-screen__tab[data-active='true'] {
    background: var(--accent);
    border-color: var(--accent);
    color: #fff;
}

.mk-screen__layers {
    position: relative;
    min-height: 0;
}

.mk-screen__layer {
    position: absolute;
    inset: 0;
    display: grid;
    grid-template-rows: auto 1fr auto;
    gap: 12px;
    opacity: 0;
}

.mk-story:not(.mk-story--gsap) .mk-screen__layer[data-active='true'] {
    opacity: 1;
}

.mk-screen__section {
    display: flex;
    justify-content: space-between;
    align-items: baseline;
    margin: 0;
    padding: 0 4px;
    font-size: 17px;
    font-weight: 800;
}

.mk-screen__section small {
    font-size: 13px;
    font-weight: 700;
    color: var(--accent);
}

.mk-screen__list {
    display: grid;
    gap: 10px;
    margin: 0;
    padding: 0;
    list-style: none;
    align-content: start;
}

.mk-screen__row {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px;
    border-radius: 16px;
    background: #fff;
    border: 1px solid rgba(13, 16, 21, 0.08);
    box-shadow: 0 12px 24px -18px rgba(13, 16, 21, 0.4);
}

.dark .mk-screen__row {
    background: #171429;
    border-color: rgba(255, 255, 255, 0.08);
}

.mk-screen__thumb {
    display: grid;
    place-items: center;
    flex: none;
    width: 52px;
    height: 52px;
    border-radius: 14px;
    color: var(--accent);
    background: color-mix(in srgb, var(--accent) 14%, transparent);
}

.mk-screen__row-body {
    display: grid;
    gap: 3px;
    min-width: 0;
    flex: 1;
}

.mk-screen__row-body strong {
    font-size: 15px;
    line-height: 1.25;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.mk-screen__row-body small {
    font-size: 12.5px;
    color: rgba(13, 16, 21, 0.58);
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.dark .mk-screen__row-body small {
    color: rgba(245, 240, 254, 0.6);
}

.mk-screen__row-side {
    display: grid;
    justify-items: end;
    gap: 6px;
    flex: none;
}

.mk-screen__row-side b {
    font-size: 14px;
    font-weight: 800;
    color: var(--accent);
    white-space: nowrap;
}

.mk-screen__pill {
    padding: 4px 10px;
    border-radius: 999px;
    background: var(--accent);
    color: #fff;
    font-size: 11.5px;
    font-weight: 700;
}

.mk-screen__actions {
    display: grid;
    grid-template-columns: 1fr 1fr 1.4fr;
    gap: 8px;
}

.mk-screen__actions span {
    display: grid;
    place-items: center;
    height: 48px;
    border-radius: 14px;
    border: 1px solid rgba(13, 16, 21, 0.1);
    font-size: 14px;
    font-weight: 700;
}

.dark .mk-screen__actions span {
    border-color: rgba(255, 255, 255, 0.12);
}

.mk-screen__actions .is-primary {
    background: var(--accent);
    border-color: var(--accent);
    color: #fff;
}

.mk-screen__home {
    width: 134px;
    height: 5px;
    margin: 0 auto;
    border-radius: 999px;
    background: rgba(13, 16, 21, 0.35);
}

.dark .mk-screen__home {
    background: rgba(255, 255, 255, 0.4);
}

/* ------------------------------------------------------------------ */
/* 3. Business flow                                                     */
/* ------------------------------------------------------------------ */

.bf {
    position: relative;
    isolation: isolate;
    padding: clamp(3.5rem, 8vh, 6rem) 1.25rem clamp(3rem, 7vh, 5rem);
    color: var(--hh-ink);
    background:
        radial-gradient(60% 40% at 50% 100%, rgba(80, 67, 172, 0.12), transparent 70%),
        linear-gradient(180deg, #ffffff 0%, #f7f4ff 100%);
    overflow-x: clip;
}

.dark .bf {
    background:
        radial-gradient(60% 40% at 50% 100%, rgba(158, 160, 251, 0.14), transparent 70%),
        linear-gradient(180deg, #12101e 0%, #0d1015 100%);
}

.bf-intro {
    width: min(46rem, 100%);
    margin: 0 auto 2.5rem;
    display: grid;
    justify-items: center;
    gap: 0.9rem;
    text-align: center;
}

.bf-intro h2 {
    margin: 0;
    max-width: 20ch;
    font-size: clamp(1.9rem, 4.2vw, 3.2rem);
    font-weight: 800;
    letter-spacing: -0.04em;
    line-height: 1.08;
    text-wrap: balance;
}

.bf-intro__lead {
    margin: 0;
    max-width: 38rem;
    color: var(--hh-muted);
    font-size: clamp(1rem, 1.25vw, 1.12rem);
    line-height: 1.55;
}

.bf-rail {
    position: relative;
    width: min(76rem, 100%);
    margin: 0 auto;
    display: grid;
    grid-template-columns: repeat(6, minmax(0, 1fr));
    gap: 1rem;
}

.bf-rail__track {
    position: absolute;
    left: calc(100% / 12);
    right: calc(100% / 12);
    top: 4.15rem;
    height: 2px;
    border-radius: 999px;
    background: var(--hh-line);
    pointer-events: none;
}

.bf-rail__line {
    position: absolute;
    inset: 0;
    border-radius: 999px;
    background: linear-gradient(90deg, #5043ac, #7c6bd6, #2f6fd6, #c3576a, #1f9d7a, #2aa3dc);
    transform-origin: left center;
}

.bf-rail__pulse {
    position: absolute;
    top: 50%;
    width: 0.85rem;
    height: 0.85rem;
    margin-top: -0.425rem;
    border-radius: 999px;
    background: #fff;
    box-shadow: 0 0 0 4px rgba(80, 67, 172, 0.25), 0 0 18px rgba(80, 67, 172, 0.6);
    opacity: 0;
}

.bf-node {
    --tone: var(--hh-primary);
    position: relative;
    display: grid;
    justify-items: center;
    gap: 0.6rem;
    padding: 1.1rem 0.9rem 1.25rem;
    border-radius: 1.25rem;
    background: rgba(255, 255, 255, 0.72);
    border: 1px solid var(--hh-line);
    box-shadow: 0 24px 48px -30px rgba(51, 42, 80, 0.5);
    text-align: center;
    will-change: transform, opacity;
}

.dark .bf-node {
    background: rgba(23, 20, 41, 0.72);
}

.bf-node__index {
    position: absolute;
    top: -0.55rem;
    left: 50%;
    transform: translateX(-50%);
    display: grid;
    place-items: center;
    width: 1.35rem;
    height: 1.35rem;
    border-radius: 999px;
    background: var(--hh-ink);
    color: var(--hh-bg);
    font-size: 0.68rem;
    font-weight: 800;
}

.bf-node__icon {
    display: grid;
    place-items: center;
    width: 3.5rem;
    height: 3.5rem;
    border-radius: 1.1rem;
    color: #fff;
    background: linear-gradient(160deg, var(--tone), color-mix(in srgb, var(--tone) 70%, #000));
    box-shadow: 0 16px 28px -14px var(--tone), inset 0 1px 0 rgba(255, 255, 255, 0.35);
}

.bf-node h3 {
    margin: 0.25rem 0 0;
    font-size: 1rem;
    font-weight: 800;
    letter-spacing: -0.02em;
    line-height: 1.25;
    text-wrap: balance;
}

.bf-node p {
    margin: 0;
    color: var(--hh-muted);
    font-size: 0.86rem;
    line-height: 1.45;
    text-wrap: pretty;
}

.bf-foot {
    width: min(46rem, 100%);
    margin: 2.5rem auto 0;
    display: grid;
    justify-items: center;
    gap: 1rem;
    text-align: center;
}

.bf-foot p {
    margin: 0;
    color: var(--hh-muted);
    font-weight: 600;
}

/* ------------------------------------------------------------------ */
/* 4. Hero depth + Spline slot                                          */
/* ------------------------------------------------------------------ */

.hh-hero__depth {
    position: absolute;
    inset: 0;
    z-index: 0;
    pointer-events: none;
}

.hh-spline__fallback {
    position: absolute;
    inset: 0;
    transition: opacity 600ms ease;
}

/* Layers that the pointer parallax moves — promoted for cheap transforms. */
.hh-hero__stage [data-depth] {
    will-change: transform;
}

/* ------------------------------------------------------------------ */
/* Responsive                                                           */
/* ------------------------------------------------------------------ */

@media (max-width: 1279px) {
    .bf-rail {
        grid-template-columns: repeat(3, minmax(0, 1fr));
        gap: 1rem 0.85rem;
    }

    .bf-rail__track {
        display: none;
    }
}

@media (max-width: 1023px) {
    /* Stacked chapters, no pinning. The stage is not part of the mobile story. */
    .mk-story__scroll {
        grid-template-columns: 1fr;
        padding: 0 1rem 3rem;
    }

    .mk-stage {
        display: none;
    }

    .mk-chapters {
        gap: 1.25rem;
    }

    .mk-chapter {
        display: block;
        min-height: 0;
        padding: 0;
        border-radius: 1.5rem;
        background: var(--mk-card);
        border: 1px solid var(--mk-line);
        box-shadow: 0 24px 48px -30px rgba(51, 42, 80, 0.4);
        overflow: hidden;
    }

    .mk-chapter__plate {
        display: block;
        width: 100%;
        aspect-ratio: 3 / 2;
        max-height: 15rem;
        background-size: cover;
        background-position: center 40%;
    }

    .mk-chapter__plate img {
        display: block;
        width: 100%;
        height: 100%;
        object-fit: cover;
        object-position: center 40%;
    }

    .dark .mk-chapter__plate img {
        filter: saturate(0.85) brightness(0.8);
    }

    .mk-chapter__copy {
        padding: 1.1rem 1.15rem 1.35rem;
    }

    .mk-story .mk-chapter[data-active] .mk-chapter__copy > * {
        opacity: 1;
        transform: none;
        transition: none;
    }

    .mk-chapter h3 {
        max-width: none;
        font-size: clamp(1.5rem, 6.5vw, 2rem);
    }

    .mk-chapter__body {
        font-size: 0.98rem;
    }

    .mk-chapter__examples {
        display: block;
        margin-top: 1.1rem;
    }

    .mk-chapter__examples-label {
        margin: 0 0 0.5rem;
        color: var(--mk-muted);
        font-size: 0.72rem;
        font-weight: 800;
        letter-spacing: 0.1em;
        text-transform: uppercase;
    }

    .mk-story--khmer .mk-chapter__examples-label {
        letter-spacing: 0;
        text-transform: none;
    }

    .mk-chapter__examples ul {
        display: grid;
        gap: 0.5rem;
        margin: 0;
        padding: 0;
        list-style: none;
    }

    .mk-chapter__examples li {
        display: flex;
        align-items: center;
        gap: 0.65rem;
        padding: 0.6rem 0.7rem;
        border-radius: 0.9rem;
        border: 1px solid var(--mk-line);
        background: color-mix(in srgb, var(--accent) 5%, transparent);
    }

    .mk-chapter__examples .mk-card__icon {
        width: 2rem;
        height: 2rem;
        border-radius: 0.6rem;
    }

    .mk-chapter__cta {
        width: 100%;
        justify-content: center;
    }

    .bf-rail__track {
        display: none;
    }
}

@media (max-width: 639px) {
    .bf-rail {
        grid-template-columns: 1fr 1fr;
        gap: 0.75rem;
    }

    .bf-node {
        padding: 1rem 0.7rem 1.1rem;
    }

    .bf-node__icon {
        width: 3rem;
        height: 3rem;
    }

    .bf-node h3 {
        font-size: 0.92rem;
    }

    .bf-node p {
        font-size: 0.8rem;
    }

    .bf-foot .mk-chapter__cta {
        width: 100%;
        justify-content: center;
    }
}

@media (prefers-reduced-motion: reduce) {
    .mk-chapter__copy > *,
    .mk-stage__dots li,
    .mk-stage__grade,
    .mk-story,
    .mk-screen__tab,
    .hh-spline__fallback,
    .mk-chapter__cta,
    .mk-chapter__cta svg {
        transition: none;
    }

    .mk-story .mk-chapter[data-active='false'] .mk-chapter__copy > * {
        opacity: 1;
        transform: none;
    }
}

@media (forced-colors: active) {
    .mk-card,
    .mk-chapter__stats li,
    .bf-node {
        border: 1px solid CanvasText;
    }
}
