/* Shared layout and accessibility fixes; loaded after the original theme. */
html { scroll-padding-top: 88px; }
header nav.navbar.nav-box-width { padding: 0 !important; }
body { overflow-wrap: break-word; }
img, video, iframe { max-width: 100%; }
img { height: auto; }
[hidden] { display: none !important; }
:is(a, button, input, select, textarea, summary):focus-visible {
    outline: 3px solid #078bd0 !important;
    outline-offset: 4px;
}
.mex-skip-link { position: fixed; top: -100px; left: 16px; z-index: 100000; background: #fff; color: #152638; padding: 12px 20px; }
.mex-skip-link:focus { top: 12px; }
#loader { display: none !important; }
.mex-home-hero { position: relative; display: flex; align-items: center; min-height: 560px; min-height: min(720px, 85svh); padding: 90px 0; background: #0a1929 url('../images/slider.jpg') center / cover no-repeat; }
.mex-home-hero:before { content: ''; position: absolute; inset: 0; background: linear-gradient(90deg, rgba(5,18,31,.94), rgba(5,18,31,.55)); }
.mex-home-hero .container { position: relative; z-index: 1; }
.mex-hero-copy { max-width: 720px; color: #fff; }
.mex-hero-copy .mex-hero-eyebrow { color: #64c8ff; font-size: 16px; font-weight: 600; margin-bottom: 20px; }
.mex-hero-copy h1 { font-size: clamp(32px, 4.6vw, 62px); line-height: 1.15; color: #fff; font-weight: 600; margin: 0 0 24px; }
.mex-hero-copy p { max-width: 600px; font-size: 18px; line-height: 1.7; color: #e2edf5; margin-bottom: 30px; }
.mex-hero-actions { display: flex; flex-wrap: wrap; gap: 14px; }
.mex-hero-actions a { white-space: normal; }
.mex-detail-shell > *, .mex-detail-shell :is(article, section), .mex-team-body, .mex-product-heading { min-width: 0; }
.mex-detail-shell h1 { overflow-wrap: anywhere; }
.mex-detail-shell :is(p, a, li) { overflow-wrap: anywhere; }
.mex-detail-page .row { margin-left: 0; margin-right: 0; }
body:has(.mex-detail-page) header nav.navbar { padding-block: 0; min-height: 72px; }
body:has(.mex-detail-page) header .nav-header-container > .row { min-height: 72px; }
body:has(.mex-detail-page) header .logo { display: inline-flex; align-items: center; min-height: 72px; }
body:has(.mex-detail-page) header .logo img { width: auto; max-width: 100%; max-height: 42px; }
body:has(.mex-detail-page) header .nav-header-container > .row { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 12px; }
body:has(.mex-detail-page) header .nav-header-container > .row:before,
body:has(.mex-detail-page) header .nav-header-container > .row:after { display: none; }
body:has(.mex-detail-page) header .nav-header-container > .row > div { width: auto; min-width: 0; padding: 0; float: none; }
body:has(.mex-detail-page) header a.logo { width: 170px; max-width: 100%; padding: 0; }
header nav .logo .logo-dark { display: none !important; }
header nav .logo .logo-light { display: block !important; visibility: visible !important; opacity: 1 !important; width: 170px !important; max-width: 100% !important; }
body:not(.mex-theme-dark) header.header-appear nav .logo .logo-dark { display: block !important; visibility: visible !important; opacity: 1 !important; width: 170px !important; max-width: 100% !important; }
body:not(.mex-theme-dark) header.header-appear nav .logo .logo-light { display: none !important; }
.mex-detail-page .mex-top-controls, .mex-top-controls { flex-wrap: wrap; }
.contact-form label { display: block; font-size: 14px; font-weight: 600; margin-bottom: 6px; }
#contact-form .col-xs-6 { padding-right: 8px !important; }
#contact-form .col-xs-6 + .col-xs-6 { padding-right: 0 !important; padding-left: 8px !important; }
#contact-form :is(input, select, textarea) { width: 100%; margin-left: 0 !important; margin-right: 0 !important; font-size: 16px; }
#contact-form textarea { min-height: 150px; resize: vertical; }
#contact-form button { min-height: 48px; }
#contact-form button:disabled { opacity: .65; cursor: wait; }
.mex-form-status { margin-top: 14px; color: #205c3b; }
.mex-form-status[data-error="true"] { color: #b32323; }
.mex-theme-dark .mex-form-status { color: #8ce7b3; }
.mex-theme-dark .mex-form-status[data-error="true"] { color: #ffb3b3; }
.mex-theme-dark header.header-appear .showMenuButton-two.white-version .hamburger,
.mex-theme-dark header.header-appear .showMenuButton-two.white-version .hamburger:before,
.mex-theme-dark header.header-appear .showMenuButton-two.white-version .hamburger:after { background: #fff !important; }
.mex-theme-dark #contact .address { background: #192637 !important; }
.mex-theme-dark #contact :is(input, select, textarea) { background: #152334; color: #edf4fa; border-color: #64748b; }
.mex-theme-dark #contact ::placeholder { color: #bcc9d8; opacity: 1; }
.mex-theme-dark #contact .btn-black { background: #007cba; color: #fff; }
.mex-theme-dark #contact .seperator hr { background: #91b9d0; }
.mex-menu-backdrop { display: none; }
.mex-mobile-nav[hidden] { display: none !important; }
#showMenu { border: 0; background: transparent; width: 48px; height: 48px; padding: 10px; cursor: pointer; }
/* A normal fixed drawer avoids perspective clipping and scales to short screens. */
body .mex-mobile-nav { position: fixed !important; inset: 0 0 0 auto !important; transform: none !important; width: min(390px, 90vw); height: 100vh; height: 100dvh; max-height: none; overflow-y: auto; overscroll-behavior: contain; padding: 20px 24px 36px; margin: 0; background: #101f30; z-index: 10002; font-size: 18px; text-align: left; }
body .mex-mobile-nav a { opacity: 1 !important; transform: none !important; white-space: normal; line-height: 1.5; padding: 10px 0; min-height: 44px; }
body .mex-mobile-nav li a:hover { transform: none !important; }
.mex-menu-close { display: block; margin: 0 0 16px auto; padding: 10px 14px; min-height: 44px; background: #fff; color: #152638; border: 0; border-radius: 6px; font-size: 15px; }
.mex-menu-open { overflow: hidden; }
.mex-menu-open .mex-menu-backdrop { display: block; position: fixed; inset: 0; background: rgba(0,0,0,.6); border: 0; z-index: 10001; }
.is-rtl .mex-mobile-nav { inset: 0 auto 0 0 !important; text-align: right; }
.mex-lang-switch button { min-height: 44px; min-width: 38px; }
.mex-theme-toggle { min-height: 44px; min-width: 44px; }
@media (min-width: 1200px) { #showMenu { display: none !important; } }
@media (max-width: 1199px) {
    .mex-nav-col, .mex-actions-col { display: none !important; }
    .mex-logo-col { width: auto; }
    .mex-header-row { min-height: 72px; }
    #showMenu { display: block !important; position: fixed; right: 16px; top: 12px !important; z-index: 1000; }
    .is-rtl #showMenu { right: auto; left: 16px; }
    .mex-gateway-hero, .mex-detail-hero { grid-template-columns: minmax(0,1fr); }
    .mex-gateway-signal-row { grid-column: auto; }
}
@media (max-width: 767px) {
    section { padding-top: 54px; padding-bottom: 54px; }
    .container { width: 100%; padding-inline: 20px; }
    .mex-home-hero { min-height: 520px; padding: 64px 0; }
    .mex-hero-copy p { font-size: 16px; }
    .mex-detail-page { padding: 92px 16px 40px; }
    .mex-detail-page header .container { padding-inline: 12px; }
    .mex-detail-shell :is(.mex-gateway-hero-copy, .mex-gateway-section, .mex-gateway-quote) { padding: 28px 20px !important; }
    .mex-detail-shell :is(h1, .mex-gateway-hero h1) { font-size: clamp(28px, 7vw, 36px); }
    .mex-detail-page .mex-team-profile-hero { margin-inline: 0; }
    .mex-team-profile-main, .mex-exec-copy-panel { padding: 28px 20px; }
    .mex-exec-copy-panel { min-height: auto; }
    .mex-team-profile-tail { padding: 24px 18px; }
    .mex-detail-feature-grid, .mex-workflow, .mex-gateway-signal-row { grid-template-columns: minmax(0,1fr); }
    .mex-quote-actions, .mex-team-hero-links, .mex-gateway-hero-actions { flex-wrap: wrap; }
    .mex-quote-actions a, .mex-gateway-hero-actions a { max-width: 100%; white-space: normal; }
    #contact .address { margin: 32px 0 0 !important; }
    #contact-form .col-xs-6 { width: 100%; padding: 0 !important; }
    #contact-form .col-xs-6 + .col-xs-6 { padding: 0 !important; }
    header .row:not(.mex-header-row) { display: flex; align-items: center; }
    header .mex-top-controls { height: auto; min-height: 72px; gap: 4px; }
    header .mex-top-controls .mex-lang-switch { gap: 0; }
    header .mex-top-controls .mex-lang-switch span { display: none; }
}
@media (max-width: 420px) {
    .mex-product-card-top { display: flex; flex-direction: column; }
    .mex-product-heading, .is-rtl .mex-product-heading { position: relative; inset: auto; padding: 18px 16px 24px; }
    .mex-product-image { min-height: 150px; padding: 20px 54px; }
    .mex-product-card h5 { margin-bottom: 0; }
    .mex-hero-actions { flex-direction: column; align-items: stretch; }
    .mex-hero-actions a { text-align: center; }
    header .logo img { max-width: 100%; }
    header .mex-top-controls { gap: 0; }
    header .mex-lang-switch button { min-width: 30px; }
}
@media (prefers-reduced-motion: reduce) {
    html { scroll-behavior: auto !important; }
    *, *:before, *:after { animation-duration: .01ms !important; animation-iteration-count: 1 !important; transition-duration: .01ms !important; }
}
