/* Global mobile hardening layer */
html {
  width: 100%;
  overflow-x: hidden;
  -webkit-text-size-adjust: 100%;
}

body {
  width: 100%;
  max-width: 100%;
  overflow-x: hidden;
}

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

img,
video {
  height: auto;
}

table {
  max-width: 100%;
}

pre,
code,
.wz-mono {
  white-space: pre-wrap;
  overflow-wrap: anywhere;
}

a,
button,
input,
select,
textarea,
.btn,
.form-control,
.form-select {
  min-width: 0;
}

.container,
.container-fluid {
  max-width: 100%;
}

.row {
  min-width: 0;
}

.row > * {
  min-width: 0;
}

.table-responsive {
  max-width: 100%;
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
}

@media (max-width: 991.98px) {
  .desktop-only,
  .ad-vertical,
  .sticky-ad {
    display: none !important;
  }

  .main-nav {
    display: none !important;
  }

  .modal-dialog {
    margin: .75rem;
  }
}

@media (max-width: 767.98px) {
  body {
    font-size: 14px;
  }

  .container,
  .container-fluid {
    padding-left: 12px;
    padding-right: 12px;
  }

  .card,
  .page-hero,
  .feature-card,
  .facility-card,
  .latest-card,
  .quick-card,
  .wz-card,
  .price-card,
  .process-card,
  .owner-panel {
    max-width: 100%;
  }

  .btn,
  button,
  input,
  select,
  textarea,
  .form-control,
  .form-select {
    min-height: 42px;
  }

  .btn {
    white-space: normal;
  }

  .btn-group,
  .btn-toolbar,
  .owner-actions,
  .hero-actions,
  .d-flex.gap-2,
  .d-flex.gap-3 {
    flex-wrap: wrap;
  }

  .toolbar .container {
    gap: .5rem !important;
  }

  .toolbar span,
  .toolbar a {
    overflow-wrap: anywhere;
  }

  .brand-header .navbar {
    min-height: 58px;
  }

  .navbar-brand {
    min-width: 0;
    max-width: calc(100vw - 88px);
  }

  .logo-text {
    display: block;
    min-width: 0;
    max-width: 210px;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
  }

  .home-hero,
  .hero {
    min-height: auto !important;
  }

  .hero-copy p,
  .section-heading,
  .owner-panel p {
    max-width: 100%;
  }

  .section-heading--split {
    align-items: stretch;
  }

  .section-heading--split > .btn,
  .owner-actions .btn {
    width: 100%;
  }

  .facility-card-pro__footer,
  .d-flex.justify-content-between {
    flex-wrap: wrap;
  }

  .facility-card-pro__footer .btn {
    flex: 1 1 auto;
  }

  .pro-footer .d-flex {
    align-items: flex-start !important;
  }

  .newsletter {
    flex-direction: column;
  }

  .newsletter input,
  .newsletter .btn-brand {
    width: 100%;
    border-radius: 12px !important;
  }
}

@media (max-width: 575.98px) {
  body {
    font-size: 13.5px;
  }

  h1,
  .h1 {
    font-size: 1.9rem;
    line-height: 1.12;
  }

  h2,
  .h2 {
    font-size: 1.55rem;
    line-height: 1.18;
  }

  h3,
  .h3 {
    font-size: 1.25rem;
    line-height: 1.22;
  }

  .display-1,
  .display-2,
  .display-3,
  .display-4,
  .display-5,
  .display-6 {
    font-size: 2rem;
    line-height: 1.1;
  }

  .container,
  .container-fluid {
    padding-left: 10px;
    padding-right: 10px;
  }

  .card-body {
    padding: 1rem;
  }

  .page-hero,
  .cta-section,
  .owner-panel {
    padding: 18px;
    border-radius: 16px;
  }

  .trust-grid,
  .reservation-grid,
  .slot-list {
    grid-template-columns: 1fr !important;
  }

  .wz-topbar-inner {
    gap: 6px;
  }

  .wz-topbar-mid {
    min-width: 0;
  }

  .wz-step-sub {
    display: none;
  }

  .wz-topbar-back,
  .wz-topbar-ico {
    flex: 0 0 auto;
  }

  .wz-summary-item,
  .wz-payrow,
  .wz-minirow,
  .summary-row {
    flex-direction: column;
    align-items: flex-start;
    gap: 4px;
  }

  .wz-minirow {
    display: grid;
    grid-template-columns: 1fr;
  }

  .modal-dialog {
    margin: .5rem;
  }

  .modal-content {
    max-height: calc(100dvh - 1rem);
    overflow-y: auto;
  }

  .accordion-button {
    align-items: flex-start;
    gap: .5rem;
    line-height: 1.3;
  }

  .table-responsive table {
    min-width: 560px;
  }

  .auth-wrapper,
  .login-page {
    min-height: 100dvh !important;
    padding: 14px;
  }

  .auth-card {
    width: 100%;
    max-width: 100%;
    padding: 20px;
  }
}

/* Reservation slot grid: keep app-like compact choices on mobile. */
@media (max-width: 575.98px) {
  .wz-slot-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr)) !important;
    gap: 8px !important;
  }

  .wz-slot {
    min-height: 58px !important;
    padding: 8px 6px !important;
    border-radius: 13px !important;
  }

  .wz-slot-time {
    font-size: .82rem !important;
  }

  .wz-slot-price,
  .wz-slot-sub {
    font-size: .68rem !important;
  }
}
