/* ==========================================================
   PPS NUTRITION — MOBILE UX
   Shared mobile-only usability corrections.
========================================================== */


/* ==========================================================
   Form controls — prevent iOS Safari focus zoom

   iOS Safari may automatically zoom the viewport when an
   editable form control uses a font size below 16px.

   This rule is intentionally mobile-only and excludes
   non-text controls such as checkboxes, radios and buttons.
========================================================== */

@media (max-width: 980px) {

  input:not([type="checkbox"]):not([type="radio"]):not([type="range"]):not([type="color"]):not([type="hidden"]):not([type="submit"]):not([type="button"]):not([type="reset"]):not([type="image"]):not([type="file"]),
  select,
  textarea {
    font-size: 16px !important;
  }

}


/* ==========================================================
   Select controls — consistent mobile appearance

   Keep each page's existing border, background and typography,
   while replacing the browser-native closed select appearance
   with a consistent PPS chevron.
========================================================== */

@media (max-width: 980px) {

  select:not([multiple]) {
    -webkit-appearance: none;
    appearance: none;

    background-image:
      url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='20' height='20' viewBox='0 0 24 24' fill='none' stroke='%232E2F79' stroke-width='2.4' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='m7 10 5 5 5-5'/%3E%3C/svg%3E");

    background-repeat: no-repeat;
    background-position: right 13px center;
    background-size: 18px 18px;

    padding-right: 40px !important;
  }

  /*
   * Products Sort is intentionally compact because it shares
   * one row with the Filters button on small screens.
   */
  .products-toolbar__sort select {
    background-position: right 0 center;
    background-size: 16px 16px;

    padding-right: 21px !important;
  }

}


/* ==========================================================
   MOBILE OVERLAY CONSISTENCY
========================================================== */

@media (max-width: 600px) {

  .pps-support-chat__backdrop:not([hidden]) {
    background: rgba(15, 18, 38, 0.58);
    -webkit-backdrop-filter: blur(4px);
    backdrop-filter: blur(4px);
  }

  .pps-support-chat__close {
    width: 44px;
    height: 44px;
    flex: 0 0 44px;

    border-radius: 14px;
  }

  .pps-support-chat__close .material-icons {
    font-size: 22px;
  }

}
