/* =========================================================
   JESTSPYON.COM — FLOATING BUBBLE HEADER
========================================================= */

.jso-site-header,
.jso-site-header *,
.jso-site-header *::before,
.jso-site-header *::after {
    box-sizing: border-box;
}


/* =========================================================
   SKIP LINK
========================================================= */

.jso-skip-link {
    position: fixed;
    z-index: 9999;

    top: 12px;
    left: 12px;

    padding: 10px 14px;

    color: #ffffff;
    background: #171522;

    border-radius: 10px;

    font:
        700
        0.76rem
        "Plus Jakarta Sans",
        Arial,
        sans-serif;

    text-decoration: none;

    transform: translateY(-160%);

    transition:
        transform 180ms ease;
}


.jso-skip-link:focus {
    transform: translateY(0);
}


/* =========================================================
   OUTER HEADER
   FULLY TRANSPARENT
========================================================= */

.jso-site-header {
    position: sticky;
    z-index: 1000;
    top: 0;

    width: 100%;
    max-width: 100%;

    padding:
        14px
        20px
        10px;

    font-family:
        "Plus Jakarta Sans",
        Arial,
        sans-serif;

    background:
        transparent !important;

    pointer-events: none;
}


.jso-site-header.is-scrolled {
    background:
        transparent !important;
}


/* =========================================================
   FLOATING BUBBLE
========================================================= */

.jso-site-header__inner {
    position: relative;

    width:
        min(
            1180px,
            100%
        );

    min-height: 68px;

    display: grid;

    grid-template-columns:
        auto
        minmax(0, 1fr)
        auto;

    align-items: center;

    gap: 20px;

    margin: 0 auto;

    padding:
        8px
        10px
        8px
        14px;

    background:
        rgba(
            255,
            255,
            255,
            0.90
        );

    border:
        1px solid
        rgba(
            116,
            87,
            255,
            0.17
        );

    border-radius: 24px;

    box-shadow:
        0 10px 32px
        rgba(
            35,
            27,
            78,
            0.08
        ),
        inset
        0
        1px
        0
        rgba(
            255,
            255,
            255,
            0.88
        );

    backdrop-filter:
        blur(18px);

    -webkit-backdrop-filter:
        blur(18px);

    pointer-events: auto;

    transition:
        background 200ms ease,
        border-color 200ms ease,
        box-shadow 200ms ease;
}


/* =========================================================
   SCROLLED BUBBLE
========================================================= */

.jso-site-header.is-scrolled
.jso-site-header__inner {
    background:
        rgba(
            255,
            255,
            255,
            0.97
        );

    border-color:
        rgba(
            116,
            87,
            255,
            0.22
        );

    box-shadow:
        0 14px 38px
        rgba(
            35,
            27,
            78,
            0.13
        );
}


/* =========================================================
   BRAND
========================================================= */

.jso-site-brand {
    display: inline-flex;

    align-items: center;

    gap: 11px;

    min-width: max-content;

    color: #171522;

    text-decoration: none;
}


.jso-site-brand__icon {
    width: 44px;
    height: 44px;

    display: grid;

    flex:
        0
        0
        44px;

    place-items: center;

    color: #ffffff;

    background:
        linear-gradient(
            145deg,
            #8c71ff,
            #6546f5
        );

    border-radius: 13px;

    box-shadow:
        0 8px 19px
        rgba(
            101,
            70,
            245,
            0.27
        );

    transition:
        transform 200ms ease,
        box-shadow 200ms ease;
}


.jso-site-brand__icon svg {
    width: 21px;
    height: 21px;

    display: block;

    fill: none;

    stroke: currentColor;

    stroke-width: 1.8;

    stroke-linecap: round;
    stroke-linejoin: round;
}


.jso-site-brand__text {
    color: #171522;

    font-size: 1.18rem;

    font-weight: 800;

    line-height: 1;

    letter-spacing: -0.05em;

    white-space: nowrap;
}


.jso-site-brand__text span {
    color: #6546f5;
}


/* =========================================================
   MAIN NAVIGATION
========================================================= */

.jso-site-navigation {
    min-width: 0;

    display: flex;

    align-items: center;

    justify-content: center;

    gap: 1px;
}


/* =========================================================
   NAV LINKS
========================================================= */

.jso-site-navigation__link {
    position: relative;

    min-height: 42px;

    display: inline-flex;

    align-items: center;

    justify-content: center;

    gap: 6px;

    padding:
        0
        10px;

    color: #514b5f;

    background: transparent;

    border:
        1px solid
        transparent;

    border-radius: 12px;

    font-size: 0.69rem;

    font-weight: 700;

    line-height: 1;

    text-decoration: none;

    white-space: nowrap;

    transition:
        color 180ms ease,
        background 180ms ease,
        border-color 180ms ease,
        transform 180ms ease;
}


/* =========================================================
   NAV ICONS
========================================================= */

.jso-site-navigation__link svg {
    width: 14px;
    height: 14px;

    display: block;

    flex:
        0
        0
        14px;

    fill: none;

    color: #765bf6;

    stroke: currentColor;

    stroke-width: 1.8;

    stroke-linecap: round;
    stroke-linejoin: round;

    transition:
        transform 180ms ease;
}


/* =========================================================
   SLIDING UNDERLINE
========================================================= */

.jso-site-navigation__link::after {
    content: "";

    position: absolute;

    right: 10px;
    bottom: 5px;
    left: 10px;

    height: 2px;

    background:
        linear-gradient(
            90deg,
            #a38aff,
            #6546f5
        );

    border-radius: 999px;

    transform:
        scaleX(0);

    transform-origin:
        left center;

    transition:
        transform
        240ms
        cubic-bezier(
            0.22,
            1,
            0.36,
            1
        );
}


/* =========================================================
   ACTIVE NAVIGATION
========================================================= */

.jso-site-navigation__link.is-active {
    color: #5638df;

    background:
        linear-gradient(
            135deg,
            #f4f1ff,
            #efebff
        );

    border-color:
        rgba(
            116,
            87,
            255,
            0.10
        );
}


.jso-site-navigation__link.is-active::after {
    transform:
        scaleX(1);
}


/* =========================================================
   HOVER
========================================================= */

@media (hover: hover) and (pointer: fine) {

    .jso-site-brand:hover
    .jso-site-brand__icon {
        transform:
            translateY(-2px);

        box-shadow:
            0 11px 23px
            rgba(
                101,
                70,
                245,
                0.33
            );
    }


    .jso-site-navigation__link:hover {
        color: #4d32d3;

        transform:
            translateY(-1px);
    }


    .jso-site-navigation__link:hover::after {
        transform:
            scaleX(1);
    }


    .jso-site-navigation__link:hover svg {
        transform:
            translateY(-1px);
    }

}


/* =========================================================
   HEADER ACTIONS
========================================================= */

.jso-site-header__actions {
    display: flex;

    align-items: center;

    justify-content: flex-end;

    gap: 9px;
}


/* =========================================================
   ERROR FIXER CTA
========================================================= */

.jso-site-header__cta {
    min-height: 48px;

    display: inline-flex;

    align-items: center;

    justify-content: center;

    gap: 10px;

    padding:
        0
        20px;

    color: #ffffff;

    background:
        linear-gradient(
            135deg,
            #7757ff 0%,
            #6546f5 55%,
            #5b38ec 100%
        );

    border:
        1px solid
        rgba(
            85,
            54,
            222,
            0.35
        );

    border-radius: 15px;

    box-shadow:
        0 8px 17px
        rgba(
            101,
            70,
            245,
            0.23
        );

    font-size: 0.73rem;

    font-weight: 800;

    line-height: 1;

    text-decoration: none;

    white-space: nowrap;

    transition:
        background 180ms ease,
        box-shadow 180ms ease,
        transform 180ms ease;
}


.jso-site-header__cta svg {
    width: 16px;
    height: 16px;

    display: block;

    fill: none;

    stroke: currentColor;

    stroke-width: 2;

    stroke-linecap: round;
    stroke-linejoin: round;

    transition:
        transform
        200ms
        cubic-bezier(
            0.22,
            1,
            0.36,
            1
        );
}


.jso-site-header__cta.is-active {
    box-shadow:
        0 0 0 4px
        rgba(
            116,
            87,
            255,
            0.16
        ),
        0 8px 18px
        rgba(
            101,
            70,
            245,
            0.25
        );
}


@media (hover: hover) and (pointer: fine) {

    .jso-site-header__cta:hover {
        background:
            linear-gradient(
                135deg,
                #6d4df4,
                #5332dd
            );

        box-shadow:
            0 11px 22px
            rgba(
                81,
                51,
                218,
                0.30
            );

        transform:
            translateY(-2px);
    }


    .jso-site-header__cta:hover svg {
        transform:
            translateX(3px);
    }

}


/* =========================================================
   MOBILE MENU BUTTON
========================================================= */

.jso-site-menu-button {
    width: 44px;
    height: 44px;

    display: none;

    padding: 0;

    color: #171522;

    background: #ffffff;

    border:
        1px solid
        #ddd7ec;

    border-radius: 13px;

    box-shadow:
        0 5px 14px
        rgba(
            35,
            27,
            78,
            0.06
        );

    cursor: pointer;
}


.jso-site-menu-button__lines {
    width: 19px;

    display: grid;

    gap: 4px;

    margin: auto;
}


.jso-site-menu-button__lines span {
    width: 19px;
    height: 2px;

    display: block;

    background:
        currentColor;

    border-radius: 999px;

    transition:
        opacity 180ms ease,
        transform 180ms ease;
}


/* =========================================================
   MENU ICON → X
========================================================= */

.jso-site-menu-button.is-active
.jso-site-menu-button__lines span:nth-child(1) {
    transform:
        translateY(6px)
        rotate(45deg);
}


.jso-site-menu-button.is-active
.jso-site-menu-button__lines span:nth-child(2) {
    opacity: 0;
}


.jso-site-menu-button.is-active
.jso-site-menu-button__lines span:nth-child(3) {
    transform:
        translateY(-6px)
        rotate(-45deg);
}


/* =========================================================
   MOBILE CTA DEFAULT
========================================================= */

.jso-site-navigation__mobile-cta {
    display: none;
}


/* =========================================================
   ANCHOR OFFSET
========================================================= */

#error-finder,
#jest-spyon-explained,
#working-example,
#jest-spyon-errors,
#jest-spyon-faqs,
#main-content {
    scroll-margin-top: 104px;
}


/* =========================================================
   MEDIUM DESKTOP
========================================================= */

@media (max-width: 1140px) {

    .jso-site-header {
        padding-right: 14px;
        padding-left: 14px;
    }


    .jso-site-header__inner {
        gap: 13px;

        padding-left: 12px;
    }


    .jso-site-navigation__link {
        gap: 4px;

        padding:
            0
            7px;

        font-size: 0.64rem;
    }


    .jso-site-navigation__link::after {
        right: 7px;
        left: 7px;
    }


    .jso-site-navigation__link svg {
        width: 13px;
        height: 13px;

        flex-basis: 13px;
    }


    .jso-site-header__cta {
        padding:
            0
            16px;

        font-size: 0.69rem;
    }

}


/* =========================================================
   TABLET + MOBILE
========================================================= */

@media (max-width: 940px) {

    .jso-site-header {
        padding:
            10px
            12px
            8px;
    }


    .jso-site-header__inner {
        width: 100%;

        min-height: 64px;

        grid-template-columns:
            auto
            1fr;

        gap: 16px;

        padding:
            8px
            9px
            8px
            12px;

        border-radius: 20px;
    }


    .jso-site-brand__icon {
        width: 42px;
        height: 42px;

        flex-basis: 42px;
    }


    .jso-site-brand__text {
        font-size: 1.12rem;
    }


    /* =====================================================
       MOBILE DROPDOWN
    ====================================================== */

    .jso-site-navigation {
        position: absolute;

        top:
            calc(
                100% + 10px
            );

        right: 0;
        left: 0;

        display: grid;

        gap: 5px;

        padding: 11px;

        visibility: hidden;

        opacity: 0;

        background:
            rgba(
                255,
                255,
                255,
                0.98
            );

        border:
            1px solid
            rgba(
                116,
                87,
                255,
                0.18
            );

        border-radius: 20px;

        box-shadow:
            0 22px 50px
            rgba(
                31,
                24,
                54,
                0.16
            );

        backdrop-filter:
            blur(18px);

        -webkit-backdrop-filter:
            blur(18px);

        transform:
            translateY(-8px);

        pointer-events: none;

        transition:
            visibility 180ms ease,
            opacity 180ms ease,
            transform 180ms ease;
    }


    .jso-site-navigation.is-open {
        visibility: visible;

        opacity: 1;

        transform:
            translateY(0);

        pointer-events: auto;
    }


    .jso-site-navigation__link {
        width: 100%;

        min-height: 50px;

        justify-content:
            flex-start;

        gap: 11px;

        padding:
            0
            15px;

        color: #312c3d;

        border-radius: 12px;

        font-size: 0.80rem;
    }


    .jso-site-navigation__link svg {
        width: 17px;
        height: 17px;

        flex-basis: 17px;

        color: #7054f3;
    }


    .jso-site-navigation__link::after {
        display: none;
    }


    .jso-site-navigation__link.is-active {
        color: #5536dd;

        background:
            #f2efff;
    }


    .jso-site-header__actions {
        margin-left: auto;
    }


    .jso-site-header__cta {
        display: none;
    }


    .jso-site-menu-button {
        display: block;

        margin-left: auto;
    }


    /* =====================================================
       MOBILE ERROR FIXER CTA
    ====================================================== */

    .jso-site-navigation__mobile-cta {
        min-height: 50px;

        display: inline-flex;

        align-items: center;

        justify-content: center;

        gap: 10px;

        margin-top: 5px;

        color: #ffffff;

        background:
            linear-gradient(
                135deg,
                #7656ff,
                #5f3bea
            );

        border-radius: 12px;

        box-shadow:
            0 8px 18px
            rgba(
                101,
                70,
                245,
                0.20
            );

        font-size: 0.80rem;

        font-weight: 800;

        text-decoration: none;
    }


    .jso-site-navigation__mobile-cta svg {
        width: 16px;
        height: 16px;

        display: block;

        fill: none;

        stroke: currentColor;

        stroke-width: 2;

        stroke-linecap: round;
        stroke-linejoin: round;
    }


    .jso-site-navigation__mobile-cta.is-active {
        box-shadow:
            0 0 0 3px
            rgba(
                116,
                87,
                255,
                0.18
            ),
            0 8px 18px
            rgba(
                101,
                70,
                245,
                0.20
            );
    }

}


/* =========================================================
   MOBILE
========================================================= */

@media (max-width: 520px) {

    .jso-site-header {
        padding:
            8px
            8px
            6px;
    }


    .jso-site-header__inner {
        min-height: 60px;

        padding:
            7px
            8px
            7px
            10px;

        border-radius: 18px;
    }


    .jso-site-brand {
        gap: 9px;
    }


    .jso-site-brand__icon {
        width: 39px;
        height: 39px;

        flex-basis: 39px;

        border-radius: 11px;
    }


    .jso-site-brand__icon svg {
        width: 19px;
        height: 19px;
    }


    .jso-site-brand__text {
        font-size: 1.02rem;
    }


    .jso-site-menu-button {
        width: 41px;
        height: 41px;

        border-radius: 11px;
    }


    .jso-site-navigation {
        top:
            calc(
                100% + 8px
            );

        border-radius: 17px;
    }


    .jso-site-navigation__link,
    .jso-site-navigation__mobile-cta {
        min-height: 48px;

        font-size: 0.77rem;
    }

}


/* =========================================================
   VERY SMALL MOBILE
========================================================= */

@media (max-width: 360px) {

    .jso-site-brand__text {
        font-size: 0.94rem;
    }


    .jso-site-brand__icon {
        width: 37px;
        height: 37px;

        flex-basis: 37px;
    }

}


/* =========================================================
   KEYBOARD ACCESSIBILITY
========================================================= */

.jso-site-header a:focus-visible,
.jso-site-menu-button:focus-visible {
    outline:
        3px solid
        rgba(
            116,
            87,
            255,
            0.34
        );

    outline-offset: 3px;
}


/* =========================================================
   REDUCED MOTION
========================================================= */

@media (prefers-reduced-motion: reduce) {

    .jso-site-header *,
    .jso-site-header *::before,
    .jso-site-header *::after {
        transition-duration:
            0.01ms !important;

        animation-duration:
            0.01ms !important;
    }

}