:root {
    --cap-hero-ink: #101010;
    --cap-hero-paper: #fbfbfa;
    --cap-hero-ease: cubic-bezier(.77, 0, .18, 1);
}

html,
body {
    overflow-x: clip;
}

.cap-hero,
.cap-hero * {
    box-sizing: border-box;
}

.cap-hero button,
.cap-hero a {
    color: inherit;
    font: inherit;
}

.cap-hero button {
    padding: 0;
    border: 0;
    background: none;
    cursor: pointer;
}

.cap-hero {
    position: relative;
    isolation: isolate;
    width: 100vw;
    height: calc(100svh - 88px);
    min-height: 620px;
    margin: 0 0 3.5rem calc(50% - 50vw);
    overflow: hidden;
    color: var(--cap-hero-ink);
    background:
        radial-gradient(circle at 50% 37%, rgba(216, 255, 0, .055), transparent 24%),
        var(--cap-hero-paper);
    font-family: Arial, Helvetica, sans-serif;
}

.cap-hero__stage {
    position: absolute;
    z-index: 2;
    inset: 0;
    cursor: grab;
    touch-action: pan-y;
}

.cap-hero__stage:active {
    cursor: grabbing;
}

.cap-hero__stage canvas {
    display: block;
    width: 100%;
    height: 100%;
}

.cap-hero__fallback {
    position: absolute;
    z-index: 1;
    inset: 12% 25% 20%;
    display: grid;
    place-items: center;
    transition: opacity .35s ease;
}

.cap-hero__fallback img {
    display: block;
    width: min(42vw, 52vh);
    height: min(42vw, 52vh);
    object-fit: contain;
    mix-blend-mode: multiply;
    transform: rotate(-6deg);
    filter: drop-shadow(0 24px 18px rgba(0, 0, 0, .1));
}

.cap-hero.is-pixi-ready .cap-hero__fallback {
    opacity: 0;
}

.cap-hero__collection {
    position: absolute;
    z-index: 6;
    top: 16%;
    left: 4.5%;
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    pointer-events: none;
}

.cap-hero__collection span {
    margin-bottom: 5px;
    font-size: clamp(8px, .58vw, 11px);
    font-weight: 700;
    letter-spacing: .08em;
}

.cap-hero__collection strong {
    font-family: Impact, Haettenschweiler, "Arial Narrow Bold", sans-serif;
    font-size: clamp(32px, 4.2vw, 72px);
    line-height: .92;
    letter-spacing: -.03em;
}

.cap-hero__collection small {
    margin-top: 7px;
    font-size: clamp(8px, .58vw, 11px);
    font-weight: 800;
    line-height: 1.25;
}

.cap-hero__autoplay {
    position: absolute;
    z-index: 8;
    top: 5.2%;
    right: 4.5%;
    display: flex;
    width: 38px;
    height: 38px;
    align-items: center;
    justify-content: center;
    gap: 2px;
    border: 1px solid rgba(0, 0, 0, .13) !important;
    background: rgba(255, 255, 255, .68) !important;
    backdrop-filter: blur(10px);
}

.cap-hero__autoplay span {
    display: block;
    width: 2px;
    height: 9px;
    background: currentColor;
    animation: cap-hero-bars .8s ease-in-out infinite alternate;
}

.cap-hero__autoplay span:nth-child(2) {
    height: 14px;
    animation-delay: -.3s;
}

.cap-hero__autoplay span:nth-child(3) {
    height: 7px;
    animation-delay: -.55s;
}

.cap-hero.is-paused .cap-hero__autoplay span {
    animation-play-state: paused;
}

@keyframes cap-hero-bars {
    to { transform: scaleY(.35); }
}

.cap-hero__drag-hint {
    position: absolute;
    z-index: 5;
    top: 53%;
    left: 50%;
    padding: 8px 13px;
    border: 1px solid rgba(0, 0, 0, .16);
    border-radius: 999px;
    opacity: .48;
    transform: translate(-50%, -50%);
    font-size: 10px;
    font-weight: 800;
    letter-spacing: .15em;
    pointer-events: none;
    animation: cap-hero-hint 2.4s ease-in-out infinite;
}

@keyframes cap-hero-hint {
    50% {
        opacity: .25;
        transform: translate(-50%, calc(-50% + 8px));
    }
}

.cap-hero__copy {
    position: absolute;
    z-index: 7;
    bottom: 7.5%;
    left: 50%;
    width: min(68%, 1040px);
    text-align: center;
    transform: translateX(-50%);
}

.cap-hero__index {
    margin: 0 0 3px;
    font-size: clamp(8px, .55vw, 11px);
    font-weight: 800;
    letter-spacing: .16em;
}

.cap-hero__copy h1 {
    margin: 0;
    overflow-wrap: anywhere;
    font-family: Impact, Haettenschweiler, "Arial Narrow Bold", sans-serif;
    font-size: clamp(42px, 5.1vw, 86px);
    font-weight: 900;
    line-height: .88;
    letter-spacing: -.025em;
    text-transform: uppercase;
}

.cap-hero__subtitle {
    margin: 8px 0 10px;
    font-size: clamp(10px, .72vw, 14px);
}

.cap-hero__cta {
    display: inline-flex;
    min-width: 104px;
    align-items: center;
    justify-content: center;
    padding: 10px 19px;
    border-radius: 999px;
    color: #fff !important;
    background: #aaa9a6;
    font-size: clamp(9px, .58vw, 11px);
    font-weight: 800;
    letter-spacing: .08em;
    text-decoration: none;
    transition: transform .25s ease, background .25s ease;
}

.cap-hero__cta:hover {
    color: #fff;
    background: #8e8d89;
    transform: translateY(-2px);
}

.cap-hero__controls {
    position: absolute;
    z-index: 8;
    bottom: 3.2%;
    left: 50%;
    display: flex;
    align-items: center;
    gap: 12px;
    transform: translateX(-50%);
}

.cap-hero__controls > button {
    width: 28px;
    height: 28px;
    opacity: .52;
    transition: opacity .2s ease, transform .2s ease;
}

.cap-hero__controls > button:hover {
    opacity: 1;
    transform: scale(1.12);
}

.cap-hero__dots {
    display: flex;
    align-items: center;
    gap: 6px;
}

.cap-hero__dots button {
    width: 6px;
    height: 6px;
    border-radius: 50%;
    background: #b8b8b5;
    transition: width .35s var(--cap-hero-ease), background .35s ease;
}

.cap-hero__dots button.is-active {
    width: 22px;
    border-radius: 4px;
    background: var(--cap-hero-ink);
}

.cap-hero__timeline {
    position: absolute;
    z-index: 9;
    right: 0;
    bottom: 0;
    left: 0;
    height: 2px;
    background: rgba(0, 0, 0, .045);
}

.cap-hero__timeline span {
    display: block;
    width: 0;
    height: 100%;
    background: var(--cap-hero-ink);
}

.cap-hero__empty {
    display: grid;
    height: 100%;
    place-content: center;
    padding: 2rem;
    text-align: center;
}

.cap-hero__empty p {
    margin: 0 0 10px;
    font-size: 11px;
    font-weight: 800;
    letter-spacing: .16em;
}

.cap-hero__empty h1 {
    margin: 0 0 18px;
    font: 900 clamp(48px, 7vw, 108px)/.86 Impact, sans-serif;
}

.cap-hero__empty a {
    justify-self: center;
    padding: 11px 20px;
    border-radius: 999px;
    color: #fff;
    background: #111;
    font-size: 11px;
    font-weight: 800;
    text-decoration: none;
}

@media (max-width: 760px) {
    .cap-hero {
        height: calc(100svh - 76px);
        min-height: 600px;
        margin-bottom: 2.5rem;
    }

    .cap-hero__collection {
        top: 10%;
        left: 5%;
    }

    .cap-hero__collection strong {
        font-size: clamp(30px, 10vw, 48px);
    }

    .cap-hero__autoplay {
        top: 3.5%;
        right: 5%;
        width: 34px;
        height: 34px;
    }

    .cap-hero__fallback {
        inset: 13% 4% 24%;
    }

    .cap-hero__fallback img {
        width: min(86vw, 48vh);
        height: min(86vw, 48vh);
    }

    .cap-hero__drag-hint {
        top: 56%;
        font-size: 8px;
    }

    .cap-hero__copy {
        bottom: 8.5%;
        width: 90%;
    }

    .cap-hero__copy h1 {
        font-size: clamp(42px, 13vw, 68px);
    }

    .cap-hero__subtitle {
        margin-top: 6px;
    }

    .cap-hero__controls {
        bottom: 3.5%;
    }
}

@media (max-height: 680px) and (min-width: 761px) {
    .cap-hero {
        min-height: 560px;
    }

    .cap-hero__copy {
        bottom: 8%;
    }
}

@media (prefers-reduced-motion: reduce) {
    .cap-hero *,
    .cap-hero *::before,
    .cap-hero *::after {
        animation-duration: .001ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: .001ms !important;
    }
}
