/* VELAXIZ v1.63.26: mobile-first navigation, tap targets, safe-area and readable forms.
   Desktop layouts remain untouched. All rules are after the original cascade. */
/* Fail closed on desktop: the mobile dock must never become document content. */
.velaxiz-mobile-footer { display: none; }
@media (min-width: 768px) {
    body nav.velaxiz-mobile-footer { display: none !important; }
}

@media (max-width: 767px) {
    :root { --velaxiz-mobile-dock-h: 66px; }
    body.velaxiz-wordpress { padding-bottom: calc(var(--velaxiz-mobile-dock-h) + env(safe-area-inset-bottom, 0px)); }

    /* A genuinely separate WordPress-menu-driven bottom navigation. */
    body nav.velaxiz-mobile-footer {
        display: block !important;
        position: fixed;
        inset: auto 0 0;
        z-index: 980;
        width: 100%;
        padding: 0 0 env(safe-area-inset-bottom, 0px);
        background: #fff;
        color: #29344c;
        border-top: 1px solid #e5eaf2;
        box-shadow: 0 -4px 20px rgba(15, 23, 42, .09);
        box-sizing: border-box;
        -webkit-tap-highlight-color: transparent;
    }
    .velaxiz-mobile-footer__list {
        display: flex;
        list-style: none;
        align-items: stretch;
        justify-content: space-around;
        gap: 0;
        width: 100%;
        max-width: 100%;
        min-height: var(--velaxiz-mobile-dock-h);
        margin: 0;
        padding: 0 6px;
        box-sizing: border-box;
        overflow-x: auto;
        overflow-y: hidden;
        overscroll-behavior-x: contain;
        scrollbar-width: none;
    }
    .velaxiz-mobile-footer__list::-webkit-scrollbar { display: none; }
    .velaxiz-mobile-footer__item {
        flex: 1 0 0%;
        min-width: 62px;
        max-width: 160px;
        margin: 0;
        padding: 0;
        list-style: none;
    }
    .velaxiz-mobile-footer__link {
        display: flex;
        flex-direction: column;
        align-items: center;
        justify-content: center;
        gap: 3px;
        min-height: var(--velaxiz-mobile-dock-h);
        padding: 7px 3px 5px;
        position: relative;
        box-sizing: border-box;
        color: #526078;
        font-family: inherit;
        font-size: 11px;
        font-weight: 600;
        line-height: 1.3;
        text-align: center;
        text-decoration: none;
        background: transparent;
        border-radius: 0;
        outline-offset: -4px;
    }
    .velaxiz-mobile-footer__link svg {
        display: block;
        flex: 0 0 23px;
        width: 23px;
        height: 23px;
        max-width: 23px;
        max-height: 23px;
    }
    .velaxiz-mobile-footer__link span {
        display: block;
        width: 100%;
        max-width: 100%;
        color: inherit;
        font-size: 11px;
        font-weight: 600;
        line-height: 1.35;
        white-space: nowrap;
        text-overflow: ellipsis;
        overflow: hidden;
    }
    .velaxiz-mobile-footer__item.is-current .velaxiz-mobile-footer__link,
    .velaxiz-mobile-footer__link[aria-current="page"] {
        color: var(--primary, #176cbb);
    }
    .velaxiz-mobile-footer__item.is-current .velaxiz-mobile-footer__link::before {
        content: "";
        position: absolute;
        top: 0;
        left: 27%;
        right: 27%;
        height: 3px;
        border-radius: 0 0 3px 3px;
        background: var(--primary, #176cbb);
    }
    .velaxiz-mobile-footer__link:focus-visible {
        outline: 2px solid var(--primary, #176cbb);
        color: var(--primary, #176cbb);
    }

    /* Keep the existing email/newsletter/copyright, but not desktop link columns. */
    footer.footer .footer__mid .nav-col,
    footer.footer .footer__mid .prod-col { display: none !important; }
    footer.footer .footer__top { display: flex; flex-direction: column; align-items: stretch; gap: 22px; }
    footer.footer .footer__top-left { width: 100%; max-width: 100%; flex-wrap: wrap; }
    footer.footer .newsletter { width: 100%; max-width: 100%; min-width: 0; }
    footer.footer .newsletter__form-host,
    footer.footer .newsletter__form-host form { max-width: 100%; }
    footer.footer .footer__mid .brand { width: 100%; max-width: 100%; }
    footer.footer .themeflat-container2 { max-width: 100%; }
    footer.footer .footer__bottom { overflow-wrap: anywhere; }
    footer.footer .newsletter__form-host .wpcf7-form {
        display: flex;
        flex-wrap: wrap;
        gap: 10px;
        max-width: 100%;
        align-items: stretch;
    }
    footer.footer .newsletter__form-host input[type="email"] {
        width: 100%;
        max-width: 100%;
        min-width: 0;
    }
    footer.footer .newsletter__form-host input[type="submit"] {
        min-height: 44px;
    }

    /* iOS/Android: controls >=44px and >=16px text avoid accidental zoom. */
    .wpcf7 form input:not([type="hidden"]):not([type="checkbox"]):not([type="radio"]),
    .wpcf7 form select,
    .wpcf7 form textarea,
    input[type="search"],
    .download-main input[type="search"] {
        box-sizing: border-box;
        max-width: 100%;
        font-size: 16px;
    }
    .wpcf7 form input:not([type="hidden"]):not([type="checkbox"]):not([type="radio"]),
    .wpcf7 form select { min-height: 44px; }
    .wpcf7 form textarea { min-height: 100px; }
    .wpcf7 form [type="submit"],
    .download-search button,
    .support-expand-btn,
    .about-journey-toggle,
    .btn-contact {
        min-height: 44px;
        touch-action: manipulation;
    }
    #mainnav-mobi .btn-submenu,
    .btn-menu,
    .close-btn { min-width: 44px; min-height: 44px; touch-action: manipulation; }

    /* Keep long media, article tables and forms within narrow viewport. */
    .blogdeta-edit img,
    .prodeta-edit img,
    .support-richtext-content img,
    .solution-details-content img,
    .contact-conflex img {
        max-width: 100%;
        height: auto;
    }
    .blogdeta-edit table,
    .prodeta-edit table,
    .support-richtext-content table,
    .solution-details-content table {
        display: block;
        max-width: 100%;
        overflow-x: auto;
        -webkit-overflow-scrolling: touch;
    }
    .blogdeta-edit,
    .prodeta-edit,
    .support-richtext-content,
    .solution-details-content { overflow-wrap: anywhere; }

    /* Hide when text entry or the full-screen mobile main menu is active. */
    body.velaxiz-download-gate-open nav.velaxiz-mobile-footer,
    body.velaxiz-mobile-keyboard-open nav.velaxiz-mobile-footer,
    body.velaxiz-mobile-menu-open nav.velaxiz-mobile-footer { display: none !important; }
    body.velaxiz-mobile-keyboard-open,
    body.velaxiz-mobile-menu-open { padding-bottom: 0; }
}

/* Short landscape devices: the fixed bar would cover too much real estate. */
@media (max-width: 767px) and (max-height: 440px) {
    body nav.velaxiz-mobile-footer { display: none !important; }
    body.velaxiz-wordpress { padding-bottom: 0; }
}

@media (prefers-reduced-motion: reduce) {
    .velaxiz-mobile-footer *,
    .velaxiz-mobile-footer *::before,
    .velaxiz-mobile-footer *::after { transition: none !important; animation: none !important; }
}

/* VELAXIZ v1.63.27 — scoped mobile corrections after the historical cascade.
   Home statistics previously inherited v157's one-column rule and v158's
   two-column certification grid below 520px.  Do not change desktop rules. */
@media (max-width: 767px) {
    /* Four fixed mobile actions; stale five-item WP menus cannot add a fifth. */
    .velaxiz-mobile-footer__list {
        display: grid;
        grid-template-columns: repeat(4, minmax(0, 1fr));
        justify-content: stretch;
        overflow-x: hidden;
        padding: 0 8px;
    }
    .velaxiz-mobile-footer__item {
        min-width: 0;
        max-width: none;
        width: auto;
    }
    .velaxiz-mobile-footer__link {
        width: 100%;
        min-width: 0;
        min-height: var(--velaxiz-mobile-dock-h);
        gap: 4px;
        touch-action: manipulation;
    }
    .velaxiz-mobile-footer__link svg {
        width: 24px;
        height: 24px;
        max-width: 24px;
        max-height: 24px;
        flex-basis: 24px;
    }
    .velaxiz-mobile-footer__link .velaxiz-mobile-footer__label {
        font-size: 11px;
        line-height: 1.25;
        letter-spacing: 0;
    }
    .velaxiz-mobile-footer__item.is-unavailable .velaxiz-mobile-footer__link {
        opacity: .48;
        cursor: not-allowed;
    }

    /* Home Hero/stats/certifications are intentionally NOT defined here.
       They are maintained exclusively in the front-page critical CSS below.
       This keeps the generic mobile dock rules isolated from Home modules. */

    /* Sitewide guardrails that do not alter any desktop positioning. */
    body.velaxiz-wordpress .themeflat-container,
    body.velaxiz-wordpress .themeflat-container2 {
        max-width: 100%;
        box-sizing: border-box;
    }
    .home-product .cards,
    .home-solution .cards,
    .home-case .cards { min-width: 0; }
}

