.hero__stats-mobile,
.saas-support-mobile,
.diagram-expand,
.mobile-break {
    display: none
}

.diagram-viewer {
    width: calc(100% - 24px);
    max-width: 1200px;
    max-height: calc(100dvh - 24px);
    margin: auto;
    padding: 56px 12px 12px;
    border: 0;
    border-radius: 8px;
    background: #fff
}

.diagram-viewer::backdrop {
    background: #002e1dcc
}

.diagram-viewer__close {
    position: absolute;
    top: 6px;
    right: 8px;
    display: grid;
    place-items: center;
    width: 44px;
    height: 44px;
    border: 0;
    border-radius: 8px;
    background: #ebf5f5;
    cursor: pointer
}

.diagram-viewer__close img {
    width: 24px;
    height: 24px
}

.diagram-viewer__canvas {
    max-height: calc(100dvh - 104px);
    overflow: auto
}

.diagram-viewer__canvas img {
    display: block;
    width: 960px;
    max-width: none;
    height: auto
}

@media screen and (max-width: 852px) {
    #global-container { min-width: 0 }
    .mobile-menu {
        top: 85px;
        bottom: 0;
        margin-top: 0;
        height: calc(100vh - 85px);
        height: calc(100dvh - 85px);
        overflow-y: auto;
        overscroll-behavior: contain;
        border-top: 1px solid #dfe8e8;
        transform: translateY(-8px);
        transition: opacity .22s ease, transform .22s ease, visibility .22s
    }

    #global-container.menu-open .mobile-menu {
        transform: none
    }

    #global-container.menu-open .header {
        background: #fff;
        box-shadow: none
    }

    .mobile-menu__inner.wrap {
        width: 100%;
        min-height: 100%;
        display: flex
    }

    .mobile-menu__wrap {
        display: flex;
        flex-direction: column;
        width: 100%;
        max-width: 600px;
        height: auto;
        min-height: 100%;
        padding: 12px 24px 0
    }

    .mobile-menu__links {
        padding-bottom: 20px
    }

    .mobile-menu__links li {
        border-bottom: 1px solid #e2ece8
    }

    .mobile-menu__links a {
        align-items: center;
        justify-content: space-between;
        min-height: 52px;
        gap: 16px;
        padding: 12px 4px;
        color: #263443;
        font-size: 17px;
        font-weight: 600;
        line-height: 1.5;
        letter-spacing: 0
    }

    .mobile-menu__links a:after {
        content: "";
        flex-shrink: 0;
        width: 20px;
        height: 20px;
        background: url(../images/keepit-arrow-up-right.svg) center / contain no-repeat;
        opacity: .55
    }

    .mobile-menu__actions {
        display: grid;
        gap: 12px;
        margin: auto -24px 0;
        padding: 22px 24px max(24px, env(safe-area-inset-bottom));
        background: #ebf5f5
    }

    .mobile-menu__actions a {
        display: flex;
        align-items: center;
        justify-content: center;
        gap: 12px;
        min-height: 54px;
        padding: 12px 16px;
        border: 1px solid #269774;
        border-radius: 8px;
        background: #fff;
        color: #166e54;
        font-size: 16px;
        font-weight: 700;
        line-height: 1.5;
        letter-spacing: 0
    }

    .mobile-menu__actions .mobile-menu__download {
        border-color: #fd982e;
        background: #fd982e;
        color: #fff
    }

    .mobile-menu__actions img {
        width: 22px;
        height: 22px
    }

    .mobile-menu__download img {
        filter: brightness(0) invert(1)
    }

    .mobile-menu a:focus-visible,
    .mobile-menu__btn:focus-visible,
    .diagram-viewer__close:focus-visible,
    img[data-expandable]:focus-visible {
        outline: 2px solid #269774;
        outline-offset: 4px
    }

    .mobile-menu__btn {
        position: relative;
        width: 44px;
        height: 44px;
        border-radius: 8px;
        background: #ebf5f5
    }

    .mobile-menu__btn span {
        position: absolute;
        left: 10px;
        top: 21px;
        margin: 0;
        transition: transform .22s ease, opacity .22s ease
    }

    .mobile-menu__btn span:first-child { transform: translateY(-7px) }
    .mobile-menu__btn span:last-child { transform: translateY(7px) }
    #global-container.menu-open .mobile-menu__btn span:first-child { transform: rotate(45deg); transition-delay: 0s }
    #global-container.menu-open .mobile-menu__btn span:nth-child(2) { opacity: 0; transform: none; transition-delay: 0s }
    #global-container.menu-open .mobile-menu__btn span:last-child { transform: rotate(-45deg); transition-delay: 0s }

    #main-container p {
        font-size: 16px;
        line-height: 1.85;
        letter-spacing: 0
    }

    #main-container p br { display: none !important }
    #main-container p { overflow-wrap: anywhere }
    .hero__body h1 { font-size: 28px; line-height: 1.6 }
    .hero__body h1 > span:not(:first-child) { word-break: keep-all }
    .mobile-break { display: inline }
    .hero__body h1 > span:first-child { font-size: 24px; line-height: 1.6 }
    .hero__body h1 > span:first-child span { font-size: .75em }
    .hero__body p { margin-top: 20px }

    .safety-data__head h2 span:first-child { font-size: 16px; margin-bottom: 8px }
    .safety-data__head h2 span:nth-child(2),
    .safety-data__head h2 span:nth-child(3),
    .keepit h2,
    .reason h2 > span:nth-child(2),
    .simple h2,
    .support h2,
    .clumn__head h2 span:nth-child(2),
    .faq__head h2 span:nth-child(2) { font-size: 28px; line-height: 1.5 }
    .feature h2 > span:nth-child(2),
    .security h2,
    .security.security--cta h2 { font-size: 26px; line-height: 1.5; letter-spacing: 0 }
    .trust h2 > span:nth-child(2) { font-size: 23px; line-height: 1.6 }
    .reason h2 > span:nth-child(3),
    .trust h2 > span:nth-child(3) { font-size: 15px; line-height: 1.8; margin-top: 16px }
    .feature h2 > span:first-child,
    .trust h2 > span:first-child,
    .clumn__head h2 span:first-child,
    .faq__head h2 span:first-child { font-size: 14px; letter-spacing: 0 }
    .keepit h3 { font-size: 18px }
    .reason__cont h3 { font-size: 24px }
    .reason__cont h3 span { font-size: inherit }
    .reason__box { font-size: 16px; width: 100%; padding: 12px 16px }
    .reason__box-icon { width: 56px }
    .feature__cont > span { font-size: 15px }
    .feature__item h3,
    .safety-issue li h3,
    .trust__item h3,
    .support__card h3 { font-size: 18px; line-height: 1.6 }
    #main-container .feature__item p,
    #main-container .safety-issue li p,
    #main-container .trust__item p,
    #main-container .support__card p { font-size: 15px; line-height: 1.8 }
    #main-container .safety-issue__body p { font-size: 12px; line-height: 1.65; overflow-wrap: anywhere }
    .safety-issue__wrap > p { text-align: left }
    .safety-issue__wrap > p span { font-size: inherit; font-weight: 700 }
    .safety-issue li { gap: 12px; padding: 16px 12px }
    .safety-issue li > img { width: 42px; min-width: 42px; flex: 0 0 42px }
    .safety-issue li > div { min-width: 0; padding: 0; display: block }
    .safety-issue li span { position: static; width: 24px; height: 24px; margin-bottom: 8px; font-size: 12px }
    .safety-issue li h3 { margin-bottom: 8px }
    .feature__item { align-items: flex-start; gap: 14px }
    .feature__item img { flex: 0 0 44px; width: 44px }
    .feature__box { min-width: 0; flex: 1 }
    .simple__items { align-items: stretch }
    .simple__box { padding: 12px 6px; min-width: 0 }
    #main-container .simple__box p { font-size: 13px; line-height: 1.65 }
    .trust__item,
    .support__card { display: grid; grid-template-columns: 56px minmax(0, 1fr); gap: 16px; padding: 24px 16px; align-items: start }
    .trust__box,
    .support__box { width: auto; min-width: 0 }
    .trust__icon,
    .support__card img { width: 56px }
    .trust__item h3 { margin-bottom: 12px }
    .security__body { width: 100% }
    .support__visual { position: relative; top: auto; right: auto; width: 100%; max-width: none; height: 200px; object-position: right center }
    .support__wrap > p { position: relative; margin-top: 24px }

    .hero__box { margin-top: 20px; gap: 12px }
    .hero__btn a { min-height: 72px; padding: 12px 16px; gap: 12px }
    .hero__btn svg,
    .footer .hero__btn svg { position: static; width: 32px; height: 36px; flex: 0 0 32px }
    .hero__btn span span:first-child { font-size: 18px }
    .hero__btn span span:nth-child(2),
    .footer .hero__btn span span:nth-child(2) { font-size: 12px }

    .clumn__slider { width: 100%; margin-top: 24px }
    .clumn__card { padding: 10px 10px 20px; border-radius: 8px }
    .clumn__img span,
    .clumn__cont > span { font-size: 12px }
    .clumn__cont h3 { font-size: 17px; line-height: 1.65 }
    #main-container .clumn__cont p:not(.clumn__link),
    #main-container .clumn__cont .clumn__link,
    .clumn__more { font-size: 14px; line-height: 1.8 }
    .faq summary { font-size: 16px; line-height: 1.7; gap: 12px; padding: 18px 36px 18px 14px }
    .faq summary:before { font-size: 14px; width: 28px }
    #main-container .faq details p { font-size: 15px; line-height: 1.8; padding: 16px 14px 16px 48px }
    .faq details p:before { font-size: 13px; width: 28px; top: 20px; left: 10px; transform: none }
    .footer__list h2 { font-size: 17px }
    .footer__list li { font-size: 15px }
    .footer .copy-right { font-size: 12px; line-height: 1.7; padding: 16px }
    .scroll-cue { font-size: 12px }

    .mobile-enhanced .hero__stats > img,
    .mobile-enhanced .hero__stats-count,
    .mobile-enhanced .saas-support { display: none }
    .hero__stats-mobile { display: grid; gap: 10px }
    .hero__stats-mobile li { display: flex; align-items: center; gap: 18px; padding: 14px 18px; border: 1px solid #dfe8e8; border-radius: 8px; background: #fff; box-shadow: 0 3px 8px #2634430c; text-align: left; letter-spacing: 0 }
    .hero__stats-mobile svg { flex: 0 0 44px; width: 44px; height: 44px }
    .hero__stats-mobile strong { display: block; font-size: 26px; line-height: 1.3; color: #269774; font-weight: 900 }
    .hero__stats-mobile li:last-child strong { font-size: 20px }
    .hero__stats-mobile span { display: block; font-size: 14px; line-height: 1.6; margin-top: 4px }
    .saas-support-mobile { display: block; border: 1px solid #269774; border-radius: 8px; padding: 18px 12px 12px }
    .saas-support-mobile h4 { margin: 0 0 18px; text-align: center; color: #269774; font-size: 20px; font-weight: 700; line-height: 1.5 }
    .saas-support-mobile ul { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px }
    .saas-support-mobile li { display: flex; flex-direction: column; align-items: center; justify-content: flex-start; gap: 12px; min-height: 132px; padding: 16px 8px 12px; border: 1px solid #dfe8e8; border-radius: 8px; background: #fff }
    .saas-support-mobile svg { display: block; width: 54px; height: 54px; flex: 0 0 54px }
    .saas-support-mobile li:nth-last-child(-n+2) svg { width: 44px; height: 44px; flex-basis: 44px; margin: 5px }
    .saas-support-mobile span { font-family: Arial, sans-serif; font-size: 14px; font-weight: 700; line-height: 1.4; text-align: center; overflow-wrap: anywhere; letter-spacing: 0 }
    img[data-expandable] { cursor: zoom-in }
    .diagram-expand { position: relative; z-index: 2; display: grid; place-items: center; width: 36px; height: 36px; margin: -44px 8px 8px auto; padding: 8px; border: 1px solid #dfe8e8; border-radius: 6px; background: #fff; cursor: zoom-in; box-shadow: 0 2px 6px #26344312 }
    .diagram-expand img { width: 18px; height: 18px; margin: 0 }
    .diagram-expand:focus-visible { outline: 2px solid #269774; outline-offset: 3px }
}

@media screen and (max-width: 374px) {
    .hero__body h1 { font-size: 25px }
    .hero__body h1 > span:first-child { font-size: 22px }
    .safety-data__head h2 span:nth-child(2),
    .safety-data__head h2 span:nth-child(3) { font-size: 25px }
}

@media screen and (min-width: 600px) and (max-width: 852px) {
    .saas-support-mobile ul { grid-template-columns: repeat(3, minmax(0, 1fr)) }
}

@media (prefers-reduced-motion: reduce) {
    .mobile-menu,
    .mobile-menu__btn span { transition: none }
}
