/* Cross-page resilience layer: mobile, tablet, touch and accessibility. */
html {
  max-width: 100%;
  overflow-x: clip;
  text-size-adjust: 100%;
  -webkit-text-size-adjust: 100%;
  scroll-behavior: smooth;
}

body {
  max-width: 100%;
  overflow-x: clip;
  overflow-wrap: break-word;
}

main,
section,
article,
header,
footer,
nav,
div {
  min-width: 0;
}

img,
svg,
video,
canvas {
  max-width: 100%;
}

img {
  height: auto;
}

iframe {
  max-width: 100%;
}

:where(h1, h2, h3, h4, p, li, blockquote) {
  text-wrap: pretty;
}

:where(h1, h2, h3) {
  overflow-wrap: normal;
}

:where(a, button, input, select, textarea, summary) {
  -webkit-tap-highlight-color: transparent;
}

:where(button, [type="button"], [type="submit"], summary) {
  touch-action: manipulation;
}

:where(a, button, input, select, textarea, summary):focus-visible {
  outline: 3px solid rgba(7, 92, 255, .38);
  outline-offset: 3px;
}

:target {
  scroll-margin-top: 110px;
}

table {
  max-width: 100%;
}

@media (max-width: 1100px) {
  :where(
    button,
    input[type="button"],
    input[type="submit"],
    .button,
    .primary-button,
    .secondary-button,
    .product-button,
    .legal-demo-button,
    .whatsapp-contact-button,
    nav summary,
    .menu-toggle
  ) {
    min-height: 44px;
  }

  :where(nav a, footer a) {
    padding-block: 10px;
  }
}

@media (max-width: 760px) {
  :where(input, select, textarea) {
    font-size: 16px !important;
  }

  :where(.table-wrap, .data-table, .comparison-table) {
    max-width: 100%;
    overflow-x: auto;
    overscroll-behavior-inline: contain;
    -webkit-overflow-scrolling: touch;
  }

  .whatsapp-float {
    right: max(14px, env(safe-area-inset-right));
    bottom: max(14px, env(safe-area-inset-bottom));
  }
}

@media (hover: none) and (pointer: coarse) {
  :where(a, button, summary) {
    touch-action: manipulation;
  }
}

@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }

  *,
  *::before,
  *::after {
    scroll-behavior: auto !important;
    animation-duration: .01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: .01ms !important;
  }
}
