/* Shared responsive safeguards for every public storefront template. */

html,
body {
  width: 100%;
}

.page,
.container,
.content,
.main-content,
.page-inner,
.section-inner {
  max-width: 100%;
}

input,
select,
textarea,
button {
  max-width: 100%;
}

table {
  max-width: 100%;
}

@media (max-width: 1024px) {
  :root {
    --w: 100%;
  }
}

@media (max-width: 768px) {
  body {
    font-size: 15px;
  }

  h1 {
    font-size: clamp(1.65rem, 8vw, 2.25rem);
    line-height: 1.12;
  }
  h2 {
    font-size: clamp(1.35rem, 6vw, 1.8rem);
    line-height: 1.2;
  }

  .page,
  .container,
  .content,
  .main-content,
  .page-inner,
  .section-inner {
    width: 100%;
    min-width: 0;
  }

  .sidebar,
  aside {
    max-width: 100%;
  }

  .breadcrumbs,
  .breadcrumb {
    overflow-x: auto;
    overscroll-behavior-inline: contain;
    scrollbar-width: none;
    white-space: nowrap;
  }

  .breadcrumbs::-webkit-scrollbar,
  .breadcrumb::-webkit-scrollbar {
    display: none;
  }

  .btn-primary,
  .btn-secondary {
    min-height: 44px;
  }

  input,
  select,
  textarea {
    font-size: 16px;
  }

  [class*="grid"] > *,
  [class*="layout"] > *,
  [class*="row"] > * {
    min-width: 0;
  }
}

@media (max-width: 480px) {
  .modal-overlay {
    padding-inline: 0;
    padding-bottom: 0;
  }
}

@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }
  *,
  *::before,
  *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }
}
