/* =====================================================================
   Path Seeker – site-wide responsive fixes
   Loaded last (include/headerfile.php) so it can override theme CSS.
   Breakpoints follow Bootstrap 5:
     mobile  < 576px | large phone 576–767 | tablet 768–991
     small desktop 992–1199 | desktop >= 1200
   ===================================================================== */

/* ---------- Global safety nets (all browsers) ---------- */
html {
  -webkit-text-size-adjust: 100%;
  -ms-text-size-adjust: 100%;
}
body {
  overflow-x: hidden;            /* no sideways scroll on phones */
}
img,
video,
svg,
canvas {
  max-width: 100%;
}
img:not(.rev-slidebg) {
  height: auto;
}
iframe,
embed,
object {
  max-width: 100%;
}
table {
  max-width: 100%;
}
/* long emails / URLs never push the layout wider than the screen */
p, li, a, h1, h2, h3, h4, h5, h6, td, th, .description, .content, .text {
  overflow-wrap: break-word;
  word-wrap: break-word;
}

/* ---------- Embeds ---------- */
.footer-embed {
  display: block;
  width: 100%;
  max-width: 100%;
  border: 0;
}
.contact-map {
  display: block;
  width: 100%;
  border: 0;
}

/* ---------- Header top bar ---------- */
.header-top .contact-info li a {
  color: inherit;
}

/* ---------- Header logo on very large screens stays crisp ---------- */
header#header .menuzord-brand img {
  height: auto;
}

/* =====================================================================
   Small desktop / large tablet landscape (< 1200px)
   ===================================================================== */
@media (max-width: 1199.98px) {
  section > .container,
  section > .container-fluid {
    padding-top: 90px;
    padding-bottom: 90px;
  }
  .header-top .contact-info li {
    display: inline-block;
    margin: 2px 8px;
  }
  .header-top .styled-icons {
    display: inline-block;
    float: none;
  }
}

/* =====================================================================
   Tablet (< 992px)
   ===================================================================== */
@media (max-width: 991.98px) {
  section > .container,
  section > .container-fluid {
    padding-top: 70px;
    padding-bottom: 70px;
  }
  .pt-90, .pt-100 { padding-top: 60px !important; }
  .pb-90, .pb-100 { padding-bottom: 60px !important; }
  .pb-80 { padding-bottom: 50px !important; }

  h2, .h2 { font-size: 2rem; }
  h3, .h3 { font-size: 1.6rem; }

  /* stacked columns need breathing room */
  .about-box-contents,
  .about-text-content { margin-bottom: 30px; }

  /* principal photo on home / message page should not fill the whole tablet width */
  .sidebar .widget_text img,
  .col-lg-3 > .sidebar img {
    max-width: 320px;
    margin: 0 auto 25px;
    display: block;
  }

  /* contact page */
  .contact-map { height: 380px; }

  /* section titles */
  .tm-sc-section-title .title { font-size: 2rem; }
}

/* =====================================================================
   Large phones (< 768px)
   ===================================================================== */
@media (max-width: 767.98px) {
  section > .container,
  section > .container-fluid {
    padding-top: 50px;
    padding-bottom: 50px;
  }
  .pt-90, .pt-100 { padding-top: 45px !important; }
  .pb-90, .pb-100 { padding-bottom: 45px !important; }
  .pb-80 { padding-bottom: 40px !important; }
  .pt-30 { padding-top: 15px !important; }

  h1, .h1 { font-size: 2rem; }
  h2, .h2 { font-size: 1.7rem; }
  h3, .h3 { font-size: 1.4rem; }
  h4, .h4 { font-size: 1.2rem; }
  .tw { font-size: 16px; }
  .tm-sc-section-title .title { font-size: 1.7rem; }

  /* inner page banner (page-title) */
  section.page-title .container { padding-top: 45px !important; padding-bottom: 45px !important; }
  section.page-title .title { font-size: 1.8rem; margin-bottom: 8px; }
  section.page-title .breadcrumbs { font-size: 13px; }

  /* justified text creates big gaps on narrow screens */
  p[align="justify"] { text-align: left !important; }

  /* header top bar – compact & centred */
  .header-top { font-size: 13px; }
  .header-top .contact-info { margin-bottom: 4px; }
  .header-top .contact-info li { display: block; margin: 2px 0; }

  /* fun-fact counters */
  .funfact-item { margin-bottom: 30px; }
  .funfact-item .counter { font-size: 2rem; }

  /* team cards */
  .team-member { margin-bottom: 30px; }

  /* gallery blocks get spacing when stacked */
  .gallery-block { margin-bottom: 20px; }

  /* contact form buttons full width & stacked */
  #contact_form .btn { width: 100%; margin-right: 0 !important; margin-bottom: 10px; }
  .icon-box.p-30 { padding: 20px !important; }

  .contact-map { height: 320px; }

  /* mandatory disclosure list – easy tap targets */
  .tm-sc-unordered-list li a { display: inline-block; padding: 6px 0; }
}

/* =====================================================================
   Small phones (< 576px)
   ===================================================================== */
@media (max-width: 575.98px) {
  .container,
  .container-fluid { padding-left: 15px; padding-right: 15px; }

  h1, .h1 { font-size: 1.75rem; }
  h2, .h2 { font-size: 1.5rem; }
  h3, .h3 { font-size: 1.25rem; }
  .tm-sc-section-title .title { font-size: 1.5rem; }
  section.page-title .title { font-size: 1.5rem; }

  .header-top .contact-info li { font-size: 12px; }

  /* full-width stacked columns for col-sm-6 grids */
  .funfact-item .icon { font-size: 36px; }

  .contact-map { height: 280px; }

  .btn { white-space: normal; }
}

/* =====================================================================
   Touch devices / iOS – fixed backgrounds don't work, keep them scrolling
   ===================================================================== */
@media (hover: none), (pointer: coarse) {
  .parallax,
  .divider,
  [data-tm-bg-img] {
    background-attachment: scroll !important;
  }
}

/* Landscape phones: keep popups & menus within the short viewport */
@media (max-height: 500px) and (orientation: landscape) {
  .menuzord-responsive .menuzord-menu.scrollable {
    max-height: 70vh;
    overflow-y: auto;
  }
}

/* Respect users who prefer less motion (accessibility) */
@media (prefers-reduced-motion: reduce) {
  .wow, .bounce { animation: none !important; }
}
