.whisper-section {
    padding: 55px 7% 65px;
    background: var(--paper);
    color: var(--ink)
}

.whisper-heading {
    max-width: 1200px;
    margin: 45px auto 40px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 50px
}

.whisper-heading>p {
    max-width: 380px;
    font-size: 18px;
    line-height: 1.65
}

.whisper-stage {
    max-width: 1200px;
    margin: auto;
    height: 590px;
    position: relative;
    border-top: 1px solid var(--line);
    border-bottom: 1px solid var(--line);
    isolation: isolate;
    overflow: hidden
}

.whisper-topline {
    display: flex;
    justify-content: space-between;
    gap: 20px;
    padding-top: 20px;
    font-size: 11px;
    letter-spacing: 1px
}

.whisper-chat {
    position: absolute;
    left: 0;
    top: 60px;
    width: 36%;
    max-width: 360px;
    background: var(--white);
    border: 1.5px solid var(--ink);
    border-radius: 16px;
    box-shadow: 5px 6px 0 var(--purple);
    overflow: hidden;
    z-index: 2
}

.whisper-chat-head {
    display: flex;
    gap: 12px;
    align-items: center;
    padding: 18px;
    border-bottom: 1px solid var(--line)
}

.whisper-chat-head>span {
    font-size: 29px
}

.whisper-chat-head small {
    display: block;
    font-size: 12px;
    margin-top: 3px
}

.whisper-chat-head b {
    font-size: 16px
}

.whisper-messages {
    padding: 18px;
    min-height: 275px;
    display: flex;
    flex-direction: column;
    gap: 14px
}

.whisper-message {
    font-size: 14px;
    line-height: 1.5;
    padding: 12px 14px;
    border-radius: 12px;
    transform-origin: bottom left
}

.whisper-message small {
    display: block;
    font-size: 10px;
    letter-spacing: 1px;
    margin-bottom: 5px
}

.shopper-message,.thanks-message {
    background: #e8ef79;
    color: #272623;
    align-self: flex-end;
    max-width: 92%
}

.approved-message {
    background: var(--paper);
    max-width: 94%;
    display: none
}

.thanks-message {
    display: none
}

.whisper-typing {
    font-size: 12px;
    padding: 4px;
    color: var(--ink)
}

.whisper-typing span {
    font-size: 22px;
    padding-left: 5px
}

.whisper-chat-foot {
    font-size: 10px;
    text-align: center;
    padding: 0 12px 15px;
    opacity: .7
}

.travelling-helper {
    position: absolute;
    left: 0;
    top: 0;
    width: 145px;
    height: 200px;
    z-index: 5;
    will-change: transform;
    pointer-events: none
}

.whisper-sprite {
    display: block;
    width: 100%;
    height: 100%;
    background-image: url('whisper-characters.png');
    background-repeat: no-repeat;
    background-size: 200% 100%
}

.helper-sprite {
    background-position: left center
}

.merchant-sprite {
    background-position: right center
}

.helper-pose {
    width: 145px;
    height: 193px;
    transform-origin: 50% 90%
}

.helper-name {
    display: block;
    text-align: center;
    font-size: 12px;
    font-weight: 600;
    margin-top: -8px
}

.merchant-character {
    position: absolute;
    right: 3%;
    bottom: 65px;
    width: 210px;
    z-index: 3;
    text-align: center
}

.merchant-pose {
    width: 210px;
    height: 280px;
    transform-origin: 50% 95%;
    transition: transform .8s cubic-bezier(.2,.85,.3,1.15)
}

.merchant-label {
    font-size: 11px;
    font-weight: 700;
    letter-spacing: .8px;
    display: block;
    margin-top: 5px
}

.helper-thought {
    position: absolute;
    top: -28px;
    left: 30px;
    background: var(--white);
    border: 1px solid var(--ink);
    border-radius: 50%;
    font: italic 17px Georgia;
    padding: 10px;
    opacity: 0;
    transform: scale(.2);
    transition: transform .45s cubic-bezier(.2,1.5,.3,1),opacity .15s
}

.merchant-whisper {
    position: absolute;
    right: 13%;
    top: 65px;
    width: 300px;
    max-width: 40%;
    background: var(--white);
    padding: 20px;
    border: 1.5px solid var(--ink);
    border-radius: 16px 16px 2px 16px;
    box-shadow: 4px 5px 0 var(--purple);
    transform: scale(.9) rotate(-3deg);
    transform-origin: 80% 100%;
    visibility: hidden;
    z-index: 6
}

.merchant-whisper small {
    font-size: 10px;
    letter-spacing: 1px
}

.merchant-whisper p {
    font: italic 22px/1.4 Georgia;
    margin: 12px 0 0
}

.merchant-yes {
    position: absolute;
    right: 2%;
    top: 75px;
    display: none;
    flex-direction: column;
    gap: 7px;
    background: var(--yellow);
    color: #272623;
    padding: 18px;
    border: 1.5px solid #272623;
    border-radius: 15px 15px 15px 2px;
    transform: rotate(5deg);
    z-index: 7;
    box-shadow: 3px 4px 0 #272623
}

.merchant-yes small {
    font-size: 10px;
    letter-spacing: 1px
}

.merchant-yes b {
    font-size: 27px
}

.merchant-yes>span {
    font-size: 12px
}

.whisper-waves {
    position: absolute;
    right: 5px;
    top: 67px;
    font: 20px Georgia;
    letter-spacing: 3px;
    display: none;
    transform: rotate(-12deg)
}

.whisper-route-note {
    position: absolute;
    left: 42%;
    bottom: 65px;
    font: italic 21px Georgia;
    transform: rotate(-6deg);
    opacity: .75;
    transition: opacity .2s
}

.whisper-endnote {
    position: absolute;
    right: 5%;
    top: 82px;
    font: 500 30px/1.3 'Space Grotesk',sans-serif;
    display: none
}

.whisper-endnote em {
    font-size: 35px
}

.whisper-bottom {
    max-width: 1200px;
    margin: 28px auto 0;
    display: flex;
    justify-content: space-between;
    gap: 25px;
    align-items: center
}

.whisper-bottom>p {
    font-size: 14px;
    max-width: 400px;
    line-height: 1.5
}

.whisper-scrubber {
    max-width: 1200px;
    margin: 24px auto 0;
    display: flex;
    gap: 20px;
    align-items: center;
    font-size: 12px
}

.whisper-scrubber input {
    min-width: 0;
    flex: 1;
    accent-color: #9d67b7;
    cursor: pointer;
    height: 30px
}

.whisper-scrubber>span {
    font-variant-numeric: tabular-nums;
    white-space: nowrap
}

.whisper-disclaimer {
    max-width: 1200px;
    margin: 15px auto 0;
    font-size: 12px;
    line-height: 1.6;
    opacity: .75
}

.whisper-stage[data-phase="1"] .helper-thought,.whisper-stage[data-phase="2"] .helper-thought {
    opacity: 1;
    transform: scale(1) rotate(-8deg)
}

.whisper-stage[data-phase="1"] .helper-pose {
    animation: whisper-notice 1s both
}

.whisper-stage[data-phase="2"] .helper-pose {
    transform: rotate(-9deg) scale(.95,1.04)
}

.whisper-stage[data-phase="3"] .helper-pose,.whisper-stage[data-phase="8"] .helper-pose {
    animation: whisper-travel .55s infinite alternate ease-in-out
}

.whisper-stage[data-phase="4"] .merchant-whisper,.whisper-stage[data-phase="5"] .merchant-whisper {
    visibility: visible;
    animation: whisper-bubble .55s both
}

.whisper-stage[data-phase="4"] .helper-pose,.whisper-stage[data-phase="5"] .helper-pose {
    transform: rotate(17deg) scale(1.03,.97);
    transition: transform .65s cubic-bezier(.2,1.2,.3,1)
}

.whisper-stage[data-phase="4"] .merchant-pose,.whisper-stage[data-phase="5"] .merchant-pose {
    transform: rotate(-9deg) translateX(-8px)
}

.whisper-stage[data-phase="4"] .whisper-waves,.whisper-stage[data-phase="5"] .whisper-waves {
    display: block;
    animation: whisper-hush .8s infinite alternate
}

.whisper-stage[data-phase="6"] .merchant-yes,.whisper-stage[data-phase="7"] .merchant-yes,.whisper-stage[data-phase="8"] .merchant-yes {
    display: flex;
    animation: whisper-bubble .5s both
}

.whisper-stage[data-phase="6"] .merchant-pose {
    animation: whisper-nod 1s both
}

.whisper-stage[data-phase="7"] .helper-pose {
    animation: whisper-happy 1s both
}

.whisper-stage[data-phase="9"] .approved-message,.whisper-stage[data-phase="10"] .approved-message {
    display: block;
    animation: whisper-message .5s both
}

.whisper-stage[data-phase="10"] .thanks-message {
    display: block;
    animation: whisper-message .5s both
}

.whisper-stage[data-phase="9"] .whisper-typing,.whisper-stage[data-phase="10"] .whisper-typing {
    display: none
}

.whisper-stage[data-phase="9"] .whisper-endnote,.whisper-stage[data-phase="10"] .whisper-endnote {
    display: block
}

.whisper-stage[data-phase="10"] .helper-pose {
    animation: whisper-happy 1s both
}

.whisper-stage:not(.is-playing) * {
    animation-play-state: paused!important
}

.whisper-stage.is-scrubbing * {
    animation: none!important
}

.whisper-stage[data-phase="9"] .whisper-route-note,.whisper-stage[data-phase="10"] .whisper-route-note {
    opacity: 0
}

@keyframes whisper-notice {
    0% {
        transform: rotate(0)
    }

    35% {
        transform: scale(1.06,.92) rotate(-8deg)
    }

    65% {
        transform: scale(.95,1.06) rotate(4deg)
    }

    100% {
        transform: scale(1)
    }
}

@keyframes whisper-travel {
    from {
        transform: translateY(0) rotate(-5deg) scale(1.03,.97)
    }

    to {
        transform: translateY(-12px) rotate(4deg) scale(.97,1.04)
    }
}

@keyframes whisper-happy {
    0%,100% {
        transform: translateY(0) scale(1)
    }

    20% {
        transform: scale(1.1,.9)
    }

    50% {
        transform: translateY(-20px) rotate(-7deg) scale(.97,1.03)
    }

    80% {
        transform: scale(1.05,.95)
    }
}

@keyframes whisper-nod {
    0%,100% {
        transform: rotate(0)
    }

    40% {
        transform: rotate(-6deg) translateY(5px)
    }
}

@keyframes whisper-hush {
    from {
        opacity: .35;
        translate: -3px 0
    }

    to {
        opacity: 1;
        translate: 3px -2px
    }
}

@keyframes whisper-bubble {
    0% {
        scale: .88;
        rotate: -4deg
    }

    70% {
        scale: 1.025;
        rotate: 2deg
    }

    100% {
        scale: 1;
        rotate: 0deg
    }
}

@keyframes whisper-message {
    from {
        transform: scale(.9) rotate(-2deg)
    }

    to {
        transform: scale(1) rotate(0)
    }
}

@media(max-width: 900px) {
    .whisper-section {
        padding-left:5%;
        padding-right: 5%
    }

    .whisper-stage {
        height: 600px
    }

    .whisper-chat {
        width: 40%
    }

    .merchant-character {
        right: 0;
        width: 180px
    }

    .merchant-pose {
        width: 180px;
        height: 240px
    }

    .merchant-whisper {
        right: 5%;
        width: 280px;
        max-width: 42%
    }

    .merchant-whisper p {
        font-size: 20px
    }

    .travelling-helper {
        width: 120px;
        height: 170px
    }

    .helper-pose {
        width: 120px;
        height: 160px
    }

    .whisper-route-note {
        left: 43%;
        font-size: 18px
    }

    .whisper-heading {
        gap: 30px
    }

    .whisper-heading p {
        font-size: 16px
    }
}

@media(max-width: 650px) {
    .whisper-section {
        padding-top:40px;
        padding-bottom: 45px
    }

    .whisper-heading {
        display: block;
        margin: 30px auto
    }

    .whisper-heading p {
        max-width: 100%;
        font-size: 16px
    }

    .whisper-stage {
        height: 820px
    }

    .whisper-topline {
        font-size: 9px;
        gap: 12px
    }

    .whisper-topline>span:last-child {
        text-align: right;
        max-width: 135px
    }

    .whisper-chat {
        left: 0;
        top: 55px;
        width: 100%;
        max-width: 100%;
        box-shadow: 3px 4px 0 var(--purple)
    }

    .whisper-chat-head {
        padding: 12px 15px
    }

    .whisper-messages {
        min-height: 247px;
        padding: 14px;
        gap: 9px
    }

    .whisper-message {
        font-size: 13px;
        padding: 9px 12px
    }

    .shopper-message {
        max-width: 88%
    }

    .whisper-chat-foot {
        font-size: 10px;
        padding-bottom: 10px
    }

    .merchant-character {
        bottom: 30px;
        right: 0;
        width: 150px
    }

    .merchant-pose {
        width: 150px;
        height: 200px
    }

    .merchant-label {
        font-size: 10px
    }

    .travelling-helper {
        width: 110px;
        height: 155px
    }

    .helper-pose {
        width: 110px;
        height: 147px
    }

    .helper-name {
        font-size: 11px
    }

    .merchant-whisper {
        top: 420px;
        right: 5px;
        width: 80%;
        max-width: 80%;
        padding: 16px
    }

    .merchant-whisper p {
        font-size: 19px
    }

    .merchant-whisper small {
        font-size: 9px
    }

    .merchant-yes {
        top: 430px;
        right: 5px;
        padding: 15px
    }

    .whisper-route-note {
        left: 0;
        bottom: 45px;
        font-size: 17px;
        max-width: 140px
    }

    .whisper-endnote {
        top: 450px;
        right: 5px;
        font-size: 24px
    }

    .whisper-endnote em {
        font-size: 28px
    }

    .whisper-bottom {
        flex-direction: column;
        align-items: flex-start;
        gap: 5px
    }

    .whisper-bottom p {
        font-size: 13px;
        min-height: 40px;
        margin-bottom: 0
    }

    .whisper-scrubber {
        flex-wrap: wrap;
        gap: 6px 15px;
        margin-top: 10px
    }

    .whisper-scrubber label {
        width: 100%;
        font-size: 12px
    }

    .whisper-scrubber>span {
        font-size: 11px
    }

    .whisper-disclaimer {
        font-size: 11px
    }

    .whisper-waves {
        top: 52px;
        right: 0;
        font-size: 16px
    }

    .whisper-stage[data-phase="0"] .helper-thought {
        display: none
    }
}

@media(prefers-reduced-motion:reduce) {
    .whisper-stage * {
        animation: none!important;
        transition: none!important
    }
}
