diff --git a/src/static_src/scss/_base.scss b/src/static_src/scss/_base.scss index f51a7eb..e593031 100644 --- a/src/static_src/scss/_base.scss +++ b/src/static_src/scss/_base.scss @@ -159,7 +159,11 @@ body { &.form-control-lg { --_pad-v: 0.75rem; padding: var(--_pad-v) 1rem; - font-size: 1.125rem; + // 1.125rem at rem=14 (small portrait clamp floor) is 15.75px + // — just under iOS Safari's 16px auto-zoom threshold. Floor + // at 16px to prevent the focus-zoom; native CSS max() handles + // the unit mix Sass can't reconcile at compile time. + font-size: unquote("max(16px, 1.125rem)"); } &.is-invalid ~ .invalid-feedback { diff --git a/src/static_src/scss/core.scss b/src/static_src/scss/core.scss index 9ba27c6..f343135 100644 --- a/src/static_src/scss/core.scss +++ b/src/static_src/scss/core.scss @@ -23,4 +23,11 @@ select, [contenteditable] { user-select: text; touch-action: auto; + // iOS Safari auto-zooms when focusing a form field whose computed font-size + // is < 16px. At rem=14 (small portrait viewports w. clamp(14,2.4vmin,22)) + // a 1rem input is 14px → triggers zoom. `max(16px, 1em)` enforces the 16px + // floor while still inheriting larger sizes from parent contexts when set. + // unquote() keeps Sass from trying to evaluate the px/em compare at compile + // time (it can't reconcile units); CSS max() handles it natively at runtime. + font-size: unquote("max(16px, 1em)"); } \ No newline at end of file diff --git a/src/templates/core/base.html b/src/templates/core/base.html index 276b264..5451eb1 100644 --- a/src/templates/core/base.html +++ b/src/templates/core/base.html @@ -101,17 +101,31 @@ // iOS Safari auto-zooms when focusing an /