/* Prevent accidental zoom and layout shifts on mobile browsers */

html {
  -webkit-text-size-adjust: 100%;
  text-size-adjust: 100%;
  touch-action: manipulation;
}

/* Disable text selection and long-press callouts except in form fields */
*,
*::before,
*::after {
  -webkit-user-select: none;
  -moz-user-select: none;
  user-select: none;
  -webkit-touch-callout: none;
}

input,
textarea,
select,
[contenteditable="true"] {
  -webkit-user-select: text;
  -moz-user-select: text;
  user-select: text;
  -webkit-touch-callout: default;
}

/* Block image drag / save / "open in new tab" affordances */
img,
svg,
video,
canvas,
picture {
  -webkit-user-drag: none;
  user-drag: none;
  -webkit-touch-callout: none;
}

html,
body {
  overscroll-behavior: none;
}

/* iOS zooms focused fields when font-size is below 16px */
input,
select,
textarea {
  font-size: max(16px, 1em);
}

/* Full-screen app shells (map) — lock page to viewport */
body.viewport-fixed {
  position: fixed;
  inset: 0;
  width: var(--app-width, 100%);
  height: var(--app-height, 100dvh);
  max-height: var(--app-height, 100dvh);
  overflow: hidden;
}
