.home-main {
    width: 100%;
    min-height: 100vh;
}

.hero-prototype {
    display: flex;
    flex-direction: column;
    width: 100%;
    min-height: 100vh;
    padding: 24px 40px 40px;
}

.hero-topbar {
    display: grid;
    grid-template-columns: 1fr auto 1fr;
    align-items: center;
    gap: 16px;
    margin-bottom: 18px;
}

.hero-brand,
.hero-meta,
.hero-nav a {
    font-size: 16px;
    color: #111111;
}

.hero-brand {
    display: inline-flex;
    align-items: center;
    text-decoration: none;
}

.hero-brand-logo {
    display: block;
    width: auto;
    height: 50px;
}

.hero-meta {
    display: flex;
    justify-content: center;
    align-items: center;
    min-width: 0;
}

.hero-nav {
    display: flex;
    justify-content: flex-end;
    gap: 28px;

}

.hero-roller {
    width: min(100%, 420px);
}

.hero-roller-window {
    position: relative;
    height: 32px;
    overflow: hidden;
}

.hero-roller-track {
    display: flex;
    flex-direction: column;
    transition: transform 500ms ease;
    will-change: transform;
}

.hero-roller-item {
    display: flex;
    align-items: center;
    justify-content: center;
    height: 32px;
    font-size: 18px;
    line-height: 32px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    font-weight: 600;  
}

.hero-stage {
    position: relative;
    flex: 1;
    width: 100%;
    min-height: 0;
    padding: 48px 24px;
    border: 1px solid #dcdcdc;
    border-radius: 24px;
    background:
        linear-gradient(180deg, rgba(255, 255, 255, 0.14) 0%, rgba(255, 255, 255, 0.08) 100%),
        url('../images/home/hero-factory-image.jpg') center center / cover no-repeat;
    overflow: hidden;
}

.hero-title {
    position: absolute;
    left: 50%;
    top: 42%;
    z-index: 1;
    width: 100%;
    margin: 0;
    transform: translate(-50%, -50%);
    font-family: var(--font-body);
    font-size: clamp(4rem, 15vw, 13rem);
    font-weight: 600;
    line-height: 0.9;
    letter-spacing: -0.06em;
    text-align: center;
    color: #f9f9f9;
}

.hero-square-title {
    --hero-title-fill: linear-gradient(180deg, #ffffff 0%, rgb(255 255 255) 100%);
    position: absolute;
    left: 50%;
    top: 25%;
    z-index: 1;
    width: 100%;
    padding: 0 24px;
    transform: translate(-50%, -50%);
    display: inline-flex;
    align-items: center;
    justify-content: center;
    flex-wrap: wrap;
    font-family: var(--font-body);
    font-size: 180px;
    font-weight: 900;
    line-height: 1.05;
    text-align: center;
    background: var(--hero-title-fill);
    -webkit-background-clip: text;
    background-clip: text;
    color: transparent;
    text-transform: uppercase;
    /* font-style: italic; */
}

.hero-square-letter {
    display: inline-block;
    padding-bottom: 0.08em;
    background: var(--hero-title-fill);
    -webkit-background-clip: text;
    background-clip: text;
    color: transparent;
    transform: translateY(115%);
    opacity: 0;
    animation: heroTextSwipeUp 0.95s cubic-bezier(0.22, 1, 0.36, 1) forwards;
    animation-delay: calc(var(--char-index) * 0.05s);
    will-change: transform, opacity;
}

.hero-square-letter.is-space {
    width: 0.28em;
    padding-bottom: 0;
    background: none;
    color: transparent;
    transform: none;
    opacity: 1;
    animation: none;
}

.workflow-marquee.workflow-marquee-images {
    border-radius: 20px;
}

@keyframes heroTextSwipeUp {
    from {
        transform: translateY(115%);
        opacity: 0;
    }

    to {
        transform: translateY(0);
        opacity: 1;
    }
}

@media (prefers-reduced-motion: reduce) {
    .hero-square-letter {
        animation: none;
        transform: translateY(0);
        opacity: 1;
    }
}

.hero-formed-image {
    position: absolute;
    left: 50%;
    bottom: 0;
    z-index: 2;
    width: min(48vw, 760px);
    height: auto;
    transform: translateX(-50%);
}

.hero-nav .nav-item-link {
    font-size: 18px;
}

.workflow-showcase {
    display: grid;
    grid-template-columns: minmax(0, 1.4fr) minmax(320px, 0.95fr);
    align-items: center;
    gap: 56px;
    padding: 8px 40px 72px;
    overflow: hidden;
}

.workflow-showcase-media,
.workflow-showcase-content {
    min-width: 0;
}

.workflow-copy-card,
.workflow-marquee {
    position: relative;
    overflow: hidden;
}

.workflow-marquee::before,
.workflow-marquee::after {
    content: '';
    position: absolute;
    top: 0;
    bottom: 0;
    z-index: 2;
    width: 54px;
    pointer-events: none;
}

.workflow-marquee::before {
    left: 0;
    background: linear-gradient(90deg, #ffffff 0%, rgba(255, 255, 255, 0) 100%);
}

.workflow-marquee::after {
    right: 0;
    background: linear-gradient(270deg, #ffffff 0%, rgba(255, 255, 255, 0) 100%);
}

.workflow-marquee-images::before,
.workflow-marquee-images::after {
    display: none;
}

.workflow-marquee-track {
    --marquee-gap: 22px;
    display: flex;
    align-items: center;
    gap: var(--marquee-gap);
    width: max-content;
}

.workflow-marquee-images .workflow-marquee-track {
    animation: workflowLoop 26s linear infinite;
}

.workflow-image-card {
    flex: 0 0 auto;
    width: var(--card-width, 280px);
    aspect-ratio: 1.65 / 1;
    border-radius: 22px;
    overflow: hidden;
    background: #edf1f4;
    box-shadow: 0 16px 32px rgba(17, 17, 17, 0.08);
}

.workflow-image {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transform: scale(1.03);
}

.workflow-showcase-content {
    display: flex;
    justify-content: flex-end;
}

.workflow-copy-card {
    width: min(100%, 620px);
    padding: 28px 32px;
    border-radius: 24px;
    background: #ffffff;
}

.workflow-copy {
    margin: 0;
    font-size: 16px;
    line-height: 1.5;
    color: #151515;
}

.workflow-marquee-badges {
    margin-top: 28px;
}

.workflow-badge-track {
    --marquee-gap: 14px;
    animation: workflowLoop 18s linear infinite;
}

.workflow-badge {
    display: inline-flex;
    align-items: center;
    gap: 12px;
    padding: 14px 18px;
    border: 1px solid #eceff2;
    border-radius: 999px;
    background: #f7f8f9;
    color: #3d3d3d;
    font-size: 1.05rem;
    line-height: 1;
    white-space: nowrap;
}

.workflow-badge::before {
    content: '';
    width: 14px;
    height: 14px;
    border: 1.5px solid #8c9198;
    border-radius: 4px;
    flex: 0 0 auto;
}

@keyframes workflowLoop {
    from {
        transform: translateX(0);
    }

    to {
        transform: translateX(calc(-50% - (var(--marquee-gap) / 2)));
    }
}

@media (prefers-reduced-motion: reduce) {
    .workflow-marquee-images .workflow-marquee-track,
    .workflow-badge-track {
        animation: none;
        transform: translateX(0);
    }
}

.about-showcase {
    display: grid;
    grid-template-columns: minmax(0, 0.95fr) minmax(0, 1.05fr);
    gap: 52px;
    align-items: center;
    padding: 16px 40px 88px;
}

.about-showcase-copy,
.about-showcase-visual {
    min-width: 0;
}

.about-showcase-kicker {
    margin: 0 0 18px;
    font-size: 1rem;
    color: #666666;
}

.about-showcase-title {
    margin: 0;
    font-family: var(--font-heading);
    font-size: 48px;
    font-weight: 400;
    line-height: 1.04;
    letter-spacing: -0.03em;
    color: #171717;
}

.about-showcase-description {
    max-width: 33rem;
    margin: 42px 0 0;
    font-size: 16px;
    line-height: 1.7;
    color: #2f2f2f;
}

.about-showcase-stats {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 24px;
    max-width: 34rem;
    margin-top: 52px;
}

.about-showcase-stat {
    display: flex;
    flex-direction: column;
    gap: 18px;
}

.about-showcase-stat-value {
    font-size: 45px;
    line-height: 0.95;
    letter-spacing: -0.05em;
    color: #171717;
}

.about-showcase-stat-label {
    max-width: 10ch;
    font-size: 16px;
    line-height: 1.15;
    color: #222222;
}

.about-gallery {
    display: flex;
    align-items: stretch;
    gap: 10px;
    min-height: 470px;
}

.about-gallery-card {
    flex: 1 1 0;
    margin: 0;
    border-radius: 24px;
    overflow: hidden;
    background: #eceff1;
    transition: flex-grow 420ms cubic-bezier(0.22, 1, 0.36, 1), transform 420ms ease;
}

.about-gallery-card.is-featured {
    flex-grow: 2.4;
}

.about-gallery-image {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

.about-gallery-caption {
    max-width: 32rem;
    margin: 28px auto 0;
    font-size: 16px;
    line-height: 1.5;
    text-align: center;
    color: #202020;
}

@media (hover: hover) {
    .about-gallery:hover .about-gallery-card {
        flex-grow: 0.85;
    }

    .about-gallery:hover .about-gallery-card:hover {
        flex-grow: 2.8;
    }
}

@media (prefers-reduced-motion: reduce) {
    .about-gallery-card {
        transition: none;
    }
}

.services-story {
    padding: 20px 0 96px;
}

.services-story-heading {
    padding: 0 40px 40px;
    text-align: center;
}

.services-story-kicker {
    margin: 0 0 10px;
    font-size: 1rem;
    color: #666666;
}

.services-story-title {
    margin: 0;
    font-family: var(--font-heading);
    font-size: 48px;
    font-weight: 400;
    line-height: 0.98;
    letter-spacing: -0.035em;
    color: #161616;
}

.services-story-subtitle {
    margin: 18px 0 0;
    font-size: 16px;
    color: #626262;
}

.services-story-scroll {
    min-height: 235vh;
}

.services-story-sticky {
    position: sticky;
    top: 0;
    padding: 10px 40px 0;
}

.services-story-layout {
    display: grid;
    grid-template-columns: minmax(0, 1.18fr) minmax(260px, 0.74fr) minmax(260px, 0.76fr);
    gap: 80px;
    align-items: start;
}

.services-story-visual,
.services-story-column {
    min-width: 0;
}

.services-story-frame {
    position: relative;
    height: clamp(460px, 68vh, 690px);
    border-radius: 24px;
    overflow: hidden;
    background: #edf2f5;
}

.services-story-slide-stack {
    position: absolute;
    inset: 0;
}

.services-story-slide {
    --reveal: 0;
    position: absolute;
    inset: 0;
    margin: 0;
    clip-path: inset(calc((1 - var(--reveal)) * 100%) 0 0 0);
    will-change: clip-path;
}

.services-story-slide.is-base {
    clip-path: inset(0 0 0 0);
}

.services-story-slide[data-slide-index="1"] {
    z-index: 2;
}

.services-story-slide[data-slide-index="2"] {
    z-index: 3;
}

.services-story-slide-image {
    width: 100%;
    height: 100%;
    display: block;
    object-fit: cover;
}

.services-story-indicators {
    position: absolute;
    left: 50%;
    bottom: 16px;
    z-index: 4;
    display: inline-flex;
    gap: 10px;
    transform: translateX(-50%);
}

.services-story-indicator {
    --fill: 0;
    position: relative;
    width: 30px;
    height: 30px;
    border-radius: 10px;
    border: 1px solid rgba(255, 255, 255, 0.6);
    background: rgba(255, 255, 255, 0.92);
    overflow: hidden;
    box-shadow: 0 10px 20px rgba(17, 17, 17, 0.12);
}

.services-story-indicator-fill {
    position: absolute;
    inset: 0;
    background: linear-gradient(180deg, #d2d9ff 0%, #7d86ff 100%);
    transform: scaleY(var(--fill));
    transform-origin: bottom center;
}

.services-story-indicator-glyph,
.services-story-indicator-glyph::before,
.services-story-indicator-glyph::after {
    position: absolute;
    content: '';
    box-sizing: border-box;
}

.services-story-indicator-glyph {
    left: 50%;
    top: 50%;
    width: 12px;
    height: 9px;
    border: 1.5px solid rgba(43, 43, 43, 0.65);
    border-top: none;
    transform: translate(-50%, -10%);
    z-index: 1;
}

.services-story-indicator-glyph::before {
    left: -1.5px;
    right: -1.5px;
    top: -6px;
    height: 10px;
    border-top: 1.5px solid rgba(43, 43, 43, 0.65);
    border-left: 1.5px solid rgba(43, 43, 43, 0.65);
    transform: skewY(-32deg);
    transform-origin: left top;
}

.services-story-indicator-glyph::after {
    top: -6px;
    right: -1.5px;
    width: 6px;
    height: 10px;
    border-top: 1.5px solid rgba(43, 43, 43, 0.65);
    border-right: 1.5px solid rgba(43, 43, 43, 0.65);
    transform: skewY(32deg);
    transform-origin: right top;
}

.services-story-column {
    display: flex;
    flex-direction: column;
    gap: 34px;
    padding-top: 12px;
}

.services-story-card {
    max-width: 24rem;
}

.services-story-card-title {
    margin: 0 0 12px;
    font-family: var(--font-heading);
    font-size: 30px;
    font-weight: 400;
    line-height: 1.02;
    color: #1b1b1b;
}

.services-story-card-body {
    margin: 0;
    font-size: 16px;
    line-height: 1.55;
    color: #686868;
}

.services-story-icon {
    position: relative;
    display: inline-block;
    width: 34px;
    height: 34px;
    margin-bottom: 14px;
    color: #2b2b2b;
}

.services-story-icon::before,
.services-story-icon::after {
    content: '';
    position: absolute;
    box-sizing: border-box;
}

.services-story-icon-draft::before {
    inset: 6px 7px 6px 5px;
    border: 1.6px solid currentColor;
    border-radius: 4px;
}

.services-story-icon-draft::after {
    right: 3px;
    top: 4px;
    width: 12px;
    height: 2px;
    background: currentColor;
    transform: rotate(-42deg);
    transform-origin: right center;
    box-shadow: -7px 9px 0 -0.5px currentColor, -10px 12px 0 -0.5px currentColor;
}

.services-story-icon-blocks::before {
    left: 7px;
    bottom: 5px;
    width: 8px;
    height: 20px;
    border: 1.6px solid currentColor;
    border-bottom-width: 3px;
    box-shadow: 10px -4px 0 -1px #fff, 10px -4px 0 0 currentColor, 20px -8px 0 -1px #fff, 20px -8px 0 0 currentColor;
}

.services-story-icon-blocks::after {
    left: 10px;
    right: 4px;
    bottom: 9px;
    height: 1.6px;
    background: currentColor;
    box-shadow: 0 -6px 0 0 currentColor;
}

.services-story-icon-document::before {
    inset: 4px 8px 4px 7px;
    border: 1.6px solid currentColor;
    border-radius: 4px;
}

.services-story-icon-document::after {
    left: 11px;
    top: 11px;
    width: 12px;
    height: 1.6px;
    background: currentColor;
    box-shadow: 0 5px 0 0 currentColor, 0 10px 0 0 currentColor, 9px 12px 0 0 currentColor;
}

.services-story-icon-grid::before {
    inset: 5px;
    background:
        linear-gradient(currentColor 0 0) left top / 10px 10px no-repeat,
        linear-gradient(currentColor 0 0) right top / 10px 10px no-repeat,
        linear-gradient(currentColor 0 0) left bottom / 10px 10px no-repeat,
        linear-gradient(currentColor 0 0) right bottom / 10px 10px no-repeat;
    opacity: 0.9;
}

.services-story-icon-grid::after {
    inset: 5px;
    border: 1.6px solid transparent;
    box-shadow:
        inset 0 0 0 1.6px #ffffff,
        inset 12px 0 0 0 #ffffff,
        inset -12px 0 0 0 #ffffff,
        inset 0 12px 0 0 #ffffff,
        inset 0 -12px 0 0 #ffffff;
    mix-blend-mode: screen;
}

.services-story-icon-recycle::before {
    left: 7px;
    top: 8px;
    width: 19px;
    height: 19px;
    border: 1.6px dashed currentColor;
    border-radius: 50%;
}

.services-story-icon-recycle::after {
    right: 6px;
    top: 7px;
    width: 7px;
    height: 7px;
    border-top: 1.6px solid currentColor;
    border-right: 1.6px solid currentColor;
    transform: rotate(28deg);
}

.services-story-column-secondary {
    padding-top: 8px;
}

.services-story-accent {
    margin-bottom: 16px;
    /* border-radius: 24px; */
    overflow: hidden;
    opacity: 0;
    transform: translateY(28px) scale(0.96);
    transition: opacity 650ms cubic-bezier(0.22, 1, 0.36, 1), transform 650ms cubic-bezier(0.22, 1, 0.36, 1);
}

.services-story-accent.is-visible {
    opacity: 1;
    transform: translateY(0) scale(1);
}

.services-story-accent-image {
    width: 275px;
    display: block;
    aspect-ratio: 1.58 / 1;
    object-fit: cover;
}

@media (prefers-reduced-motion: reduce) {
    .services-story-accent {
        opacity: 1;
        transform: none;
        transition: none;
    }
}

@media (max-width: 900px) {
    .hero-topbar {
        grid-template-columns: 1fr;
        justify-items: start;
    }

    .hero-meta {
        justify-content: flex-start;
    }

    .hero-nav {
        justify-content: flex-start;
        flex-wrap: wrap;
        gap: 16px;
    }

    .hero-prototype {
        padding: 20px 20px 24px;
    }

    .workflow-showcase {
        grid-template-columns: 1fr;
        gap: 28px;
        padding: 0 20px 48px;
    }

    .about-showcase {
        grid-template-columns: 1fr;
        gap: 28px;
        padding: 8px 20px 56px;
    }

    .services-story {
        padding: 12px 0 56px;
    }

    .services-story-heading {
        padding: 0 20px 28px;
    }

    .services-story-scroll {
        min-height: auto;
    }

    .services-story-sticky {
        position: static;
        padding: 0 20px;
    }

    .services-story-layout {
        grid-template-columns: 1fr;
        gap: 24px;
    }

    .hero-roller-window {
        height: 28px;
    }

    .hero-roller-item {
        justify-content: flex-start;
        height: 28px;
        font-size: 16px;
        line-height: 28px;
    }

    .hero-square-title {
        top: 52%;
        font-size: 56px;
    }

    .workflow-copy-card {
        padding: 24px 20px;
        border-radius: 20px;
    }

    .workflow-marquee::before,
    .workflow-marquee::after {
        width: 26px;
    }

    .workflow-image-card {
        width: clamp(180px, 62vw, 240px);
        border-radius: 18px;
    }

    .workflow-badge {
        padding: 12px 16px;
        font-size: 0.95rem;
    }

    .about-showcase-description {
        margin-top: 28px;
    }

    .about-showcase-stats {
        grid-template-columns: repeat(3, minmax(0, 1fr));
        gap: 16px;
        margin-top: 36px;
    }

    .about-showcase-stat {
        gap: 12px;
    }

    .about-gallery {
        min-height: 320px;
        gap: 8px;
    }

    .about-gallery-card {
        border-radius: 18px;
    }

    .about-gallery-caption {
        margin-top: 20px;
    }

    .services-story-frame {
        height: 380px;
        border-radius: 18px;
    }

    .services-story-column {
        gap: 26px;
        padding-top: 0;
    }

    .services-story-accent {
        margin-bottom: 4px;
        border-radius: 18px;
    }

    .hero-formed-image {
        width: min(82vw, 520px);
    }
}
