/* Brickwork mobile layer. Everything is inside the media query, so desktop (>820px) is unchanged. */
#bw-mbar, #bw-mnav { display: none; }

@media (max-width: 820px) {
  html, body { overflow-x: hidden !important; -webkit-text-size-adjust: 100%; }
  body { padding-top: 60px !important; }

  /* Release Duda's fixed desktop widths */
  #dm .dmInner, #dm .dmOuter, #dm .dmLayoutWrapper, #dm #iscrollBody, #dm #site_content,
  #dm .dmBody, #dm .allWrapper, #dm .dmContent, #dm .dmRespRowsWrapper {
    min-width: 0 !important; width: 100% !important; max-width: 100% !important; box-sizing: border-box;
  }
  #dm .dmRespRow, #dm .dmRespColsWrapper {
    width: 100% !important; max-width: 100% !important; min-width: 0 !important;
    box-sizing: border-box; margin-left: 0 !important; margin-right: 0 !important;
  }
  #dm .dmRespRow { padding-left: 16px !important; padding-right: 16px !important; }
  #dm .dmRespColsWrapper { display: flex !important; flex-direction: column !important; }
  #dm .dmRespCol {
    width: 100% !important; max-width: 100% !important; min-width: 0 !important;
    float: none !important; margin-left: 0 !important; margin-right: 0 !important; box-sizing: border-box;
  }
  #dm img, #dm video, #dm iframe, #dm svg { max-width: 100% !important; }
  #dm img { height: auto; }

  /* Replace the desktop navigation with the burger bar */
  #dm nav.unifiednav, #dm .dmHeaderContainer { display: none !important; }

  /* Entrance animations never fire reliably on phones; show content immediately */
  #dm [data-anim-desktop], #dm [data-anim-extended], #dm .dmNewParagraph[data-anim-desktop] {
    visibility: visible !important; opacity: 1 !important; transform: none !important;
  }

  /* Typography that scales down */
  #dm p, #dm p *, #dm li { font-size: 16px !important; line-height: 1.55 !important; }
  #dm h1, #dm h1 * { font-size: clamp(24px, 7vw, 30px) !important; line-height: 1.2 !important; }
  #dm h2, #dm h2 * { font-size: clamp(21px, 6vw, 26px) !important; line-height: 1.25 !important; }
  #dm h3, #dm h3 * { font-size: clamp(18px, 5.2vw, 22px) !important; line-height: 1.3 !important; }
  #dm h4, #dm h4 * { font-size: clamp(16px, 4.6vw, 19px) !important; line-height: 1.4 !important; }
  #dm p, #dm li, #dm h1, #dm h2, #dm h3, #dm h4 { overflow-wrap: break-word; word-break: normal; hyphens: auto; }
  #dm .dmNewParagraph { padding-left: 0 !important; padding-right: 0 !important; }
  #dm .dmNewParagraph p { text-align: center; }
  #dm [class*="u_"][class*="Contact"], #dm .dmNewParagraph span[style*="color: rgb(56"] { font-size: 18px !important; overflow-wrap: anywhere; }

  /* Top bar */
  #bw-mbar {
    display: flex; align-items: center; justify-content: space-between;
    position: fixed; top: 0; left: 0; right: 0; height: 60px; z-index: 100000;
    padding: 0 8px 0 16px; background: #fff; border-bottom: 1px solid #e3e3e3;
    box-shadow: 0 1px 6px rgba(0,0,0,.06); box-sizing: border-box;
  }
  #bw-mbar .bw-brand { display: flex; flex-direction: column; text-decoration: none; line-height: 1.1; color: #111; }
  #bw-mbar .bw-brand b { font: 700 18px/1.1 Poppins, Arial, sans-serif; letter-spacing: .5px; }
  #bw-mbar .bw-brand span { font: 600 9.5px/1.3 Poppins, Arial, sans-serif; color: #2f6b46; letter-spacing: .6px; }
  #bw-burger {
    width: 48px; height: 48px; border: 0; background: transparent; cursor: pointer; padding: 0;
    display: flex; align-items: center; justify-content: center; border-radius: 8px;
  }
  #bw-burger i, #bw-burger i::before, #bw-burger i::after {
    display: block; width: 24px; height: 2.5px; background: #111; border-radius: 2px;
    position: relative; transition: transform .2s, background .2s;
  }
  #bw-burger i::before, #bw-burger i::after { content: ""; position: absolute; left: 0; }
  #bw-burger i::before { top: -8px; }
  #bw-burger i::after { top: 8px; }
  body.bw-open #bw-burger i { background: transparent; }
  body.bw-open #bw-burger i::before { transform: translateY(8px) rotate(45deg); }
  body.bw-open #bw-burger i::after { transform: translateY(-8px) rotate(-45deg); }

  /* Slide-down menu */
  #bw-mnav {
    display: block; position: fixed; top: 60px; left: 0; right: 0; z-index: 99999;
    background: #fff; border-bottom: 1px solid #e3e3e3; box-shadow: 0 10px 24px rgba(0,0,0,.12);
    max-height: calc(100vh - 60px); overflow-y: auto;
    transform: translateY(-110%); visibility: hidden; transition: transform .25s ease, visibility .25s;
  }
  body.bw-open #bw-mnav { transform: none; visibility: visible; }
  #bw-mnav a {
    display: block; padding: 16px 20px; font: 500 17px/1.2 Poppins, Arial, sans-serif;
    color: #111; text-decoration: none; border-bottom: 1px solid #f0f0f0;
  }
  #bw-mnav a[aria-current="page"] { color: #2f6b46; font-weight: 700; border-left: 4px solid #2f6b46; padding-left: 16px; }
  #bw-mnav a:active { background: #f4f8f5; }
  #bw-scrim { display: none; position: fixed; inset: 60px 0 0 0; background: rgba(0,0,0,.35); z-index: 99998; }
  body.bw-open #bw-scrim { display: block; }

  /* Footer */
  #dm .dmFooterContainer, #dm .dmFooterResp { width: 100% !important; }
  #dm .dmFooterResp .dmRespColsWrapper { align-items: center; gap: 4px; }
  #dm .dmFooterResp p, #dm .dmFooterResp p *, #dm .dmFooterResp .dmNewParagraph { font-size: 13px !important; line-height: 1.6 !important; text-align: center !important; margin: 0 !important; }
  #dm .dmFooterResp .dmRespColsWrapper { flex-direction: column !important; }
  #dm .dmFooterResp .dmRespCol { padding: 4px 16px !important; width: 100% !important; }

  #dm .dmFooterResp .copyright { display: block !important; text-align: center !important; }
  #dm .dmFooterResp .copyright > div { display: block !important; width: 100% !important; text-align: center !important; }

  #dm .dmBody div.dmRespCol[id] .dmNewParagraph[id] p.size-30 span.font-size-30 { font-size: 15px !important; overflow-wrap: anywhere; }

  /* Column padding / paragraph widths (Duda desktop paddings squeeze text) */
  #dm .dmBody div.dmRespCol[id] { padding: 16px 20px !important; margin: 0 !important; width: 100% !important; max-width: 100% !important; box-sizing: border-box !important; }
  #dm .dmBody div.dmRespCol[id] .dmNewParagraph[id] { min-width: 0 !important; width: 100% !important; max-width: 100% !important; }
  #dm .dmRespRow { padding-left: 0 !important; padding-right: 0 !important; }
  #dm .dmRespCol ul.defaultList { padding-left: 22px !important; }
  #dm .dmRespCol li { width: auto !important; }

  /* Photo gallery: two-column compact grid */
  #dm .dmPhotoGallery { height: auto !important; }
  #dm .dmPhotoGallery .layout-container { height: auto !important; }
  #dm .dmPhotoGallery .photogallery-row { height: auto !important; aspect-ratio: 2 / 1; }

  /* Headings: never break mid-word on small screens */
  #dm h1, #dm h1 * { font-size: clamp(26px, 8vw, 36px) !important; line-height: 1.15 !important; overflow-wrap: normal !important; word-break: normal !important; hyphens: manual !important; }
  #dm a[href^="mailto:"], #dm .dmRespCol span[style*="rgb(56"] { font-size: 16px !important; overflow-wrap: anywhere; }
}
