/* myguideqr 2.32.66 — canonical visual layer.
   Purpose: one last-loaded, static visual layer for public pages, commerce, visitor guide and client panel.
   Do not add new scattered template <style> overrides for static presentation fixes. */

/* Universal visual hygiene for plugin-owned frontend surfaces. */
body.mq-page-chrome :is(img,svg),
body.sgwp-guide :is(img,svg),
body.sgwp-client-panel :is(img,svg){
  max-width:100%;
}

body.mq-page-chrome img,
body.sgwp-guide img,
body.sgwp-client-panel img{
  height:auto;
  image-rendering:auto;
}

/* Public-page photo components: single canonical behavior. */
body.myguideqr-sales-template :is(.mq-home-photo,.mq-home-custom-image),
body.mq-demo-v222-template .mq-demo-v222-photo,
body.mq-demo-editor-v226 :is(.mqde-editor-visual img,.mqde-editor-overview-visual img),
body.mq-packages-v230 :is(.mq-packages-photo-card img,.mq-package-card__visual img),
body.mq-details-page :is(.mq-details-hero-visual img,.mq-details-visual-media img),
body.mq-page-chrome :is(.mq-details-hero-visual img,.mq-details-visual-media img){
  display:block;
  width:100%;
  max-width:100%;
  height:auto;
  object-fit:cover;
  object-position:center center;
}

/* Mobile image fitting belongs here instead of per-page override fragments. */
@media (max-width:700px){
  body.myguideqr-sales-template :is(.mq-home-photo,.mq-home-custom-image),
  body.mq-demo-v222-template .mq-demo-v222-photo,
  body.mq-demo-editor-v226 :is(.mqde-editor-visual img,.mqde-editor-overview-visual img),
  body.mq-packages-v230 :is(.mq-packages-photo-card img,.mq-package-card__visual img),
  body.mq-details-page :is(.mq-details-hero-visual img,.mq-details-visual-media img),
  body.mq-page-chrome :is(.mq-details-hero-visual img,.mq-details-visual-media img){
    aspect-ratio:auto!important;
    max-height:none!important;
    object-fit:contain!important;
    border-radius:22px;
  }

  body.mq-packages-v230 .mq-packages-photo-card figcaption{
    position:relative!important;
    left:auto!important;
    right:auto!important;
    bottom:auto!important;
    margin:10px!important;
    background:linear-gradient(180deg,rgba(15,23,42,.92),rgba(15,23,42,.96))!important;
  }
}

/* Canonical public footer typography guard. Footer content is rendered centrally; page CSS must not enlarge it. */
body.mq-page-chrome footer.mq-site-footer[data-mq-site-footer] :is(a,p,li,small,span,strong),
body.sgwp-guide footer.mq-site-footer[data-mq-site-footer] :is(a,p,li,small,span,strong),
body.sgwp-client-panel footer.mq-site-footer[data-mq-site-footer] :is(a,p,li,small,span,strong){
  text-rendering:optimizeLegibility;
  word-break:normal;
}

body.mq-page-chrome footer.mq-site-footer[data-mq-site-footer] a,
body.sgwp-guide footer.mq-site-footer[data-mq-site-footer] a,
body.sgwp-client-panel footer.mq-site-footer[data-mq-site-footer] a{
  text-decoration:none;
}

/* Client panel and visitor guide final safety: prevent text collapse without touching layout logic. */
body.sgwp-client-panel :is(.sgwp-card-title-row h2,.sgwp-social-builder-head strong,.sgwp-contact-builder-head strong,.sgwp-module-editor-title strong,.sgwp-icon-row-title strong,.sgwp-place-row-title strong,.sgwp-suite-row-title strong,.sgwp-client-button,.sgwp-client-card-toggle,.sgwp-social-edit-button,.sgwp-contact-edit-button,.sgwp-module-edit-button,.sgwp-builder-toggle-label,.sgwp-module-content-badge,.sgwp-step-card-badge),
body.sgwp-guide :is(.sgwp-icon-quick span,.sgwp-visitor-accordion-title,.sgwp-visitor-accordion-content,.sgwp-action-surface){
  writing-mode:horizontal-tb!important;
  text-orientation:mixed!important;
  word-break:normal!important;
  hyphens:none!important;
}


/* 2.39.11 public view guard: protect demo editor final CTA from admin/custom CSS or long package labels. */
body.mq-demo-editor-v226 :is(.mqde-final,.mqde-final > div,.mqde-final-actions){
  min-width:0!important;
}
body.mq-demo-editor-v226 .mqde-final{
  overflow:hidden!important;
}
@media (min-width:1121px){
  body.mq-demo-editor-v226 .mqde-final{
    grid-template-columns:minmax(320px,.82fr) minmax(0,1.18fr)!important;
  }
}
@media (max-width:1120px){
  body.mq-demo-editor-v226 .mqde-final{
    grid-template-columns:1fr!important;
  }
}
body.mq-demo-editor-v226 :is(.mqde-final .mqde-kicker,.mqde-final h2,.mqde-final p,.mqde-final .mqde-button){
  writing-mode:horizontal-tb!important;
  text-orientation:mixed!important;
  word-break:normal!important;
  hyphens:none!important;
}
body.mq-demo-editor-v226 .mqde-final-actions{
  display:flex!important;
  flex-wrap:wrap!important;
}
body.mq-demo-editor-v226 .mqde-final-actions .mqde-button{
  min-width:0!important;
  max-width:100%!important;
  white-space:normal!important;
}

/* WooCommerce public commerce pages use the same chrome constraints. */
body.sgwp-commerce-canonical-header .mq-app-header,
body.sgwp-commerce-canonical-footer .mq-site-footer{
  isolation:isolate;
}

@media (max-width:780px){
  body.sgwp-commerce-canonical-header .mq-app-header__panel,
  body.mq-page-chrome .mq-app-header__panel{
    max-width:calc(100vw - 20px);
  }
}

/* Consolidated 2.32.55 mobile photo/container behavior. */
@media (max-width:780px){
  body.myguideqr-sales-template .mq-home-v220 .mq-guide-preview,
  body.mq-demo-v222-template .mq-demo-v222-hero-visual,
  body.mq-demo-v222-template .mq-demo-v222-split-visual,
  body.mq-demo-editor-v226 .mqde-editor-visual,
  body.mq-demo-editor-v226 .mqde-editor-overview-visual,
  body.mq-packages-v230 .mq-packages-showcase,
  body.mq-packages-v230 .mq-packages-photo-card,
  body.mq-packages-v230 .mq-package-card__visual,
  body.mq-details-page .mq-details-hero__panel,
  body.mq-details-page .mq-details-visual-media,
  .mq-details-main .mq-details-hero__panel,
  .mq-details-main .mq-details-visual-media{
    width:100%!important;
    min-width:0!important;
    max-width:100%!important;
    margin-inline:auto!important;
  }

  body.myguideqr-sales-template .mq-home-v220 .mq-home-visual-stack--visual-only{
    display:grid!important;
    min-height:auto!important;
  }

  body.myguideqr-sales-template .mq-home-v220 .mq-home-visual-stack--visual-only .mq-home-orbit{
    display:block!important;
    position:relative!important;
    inset:auto!important;
    width:min(100%,430px)!important;
    margin-inline:auto!important;
    transform:none!important;
  }

  body.myguideqr-sales-template :is(.mq-home-photo,.mq-home-custom-image),
  body.mq-demo-v222-template .mq-demo-v222-photo,
  body.mq-demo-editor-v226 :is(.mqde-editor-visual img,.mqde-editor-overview-visual img),
  body.mq-packages-v230 :is(.mq-packages-photo-card img,.mq-package-card__visual img),
  body.mq-details-page :is(.mq-details-hero-visual img,.mq-details-visual-media img),
  .mq-details-main :is(.mq-details-hero-visual img,.mq-details-visual-media img),
  body.mq-page-chrome :is(.sgwp-suite-public-photo img,.sgwp-place-public-photo img,.sgwp-modal-photo img,.sgwp-visitor-photo img){
    display:block!important;
    width:100%!important;
    height:auto!important;
    max-width:100%!important;
    max-height:none!important;
    min-height:0!important;
    object-position:center center!important;
  }

  body.myguideqr-sales-template .mq-home-v220 .mq-home-photo--hero,
  body.mq-demo-v222-template .mq-demo-v222-photo--hero,
  body.mq-demo-editor-v226 .mqde-editor-visual img,
  body.mq-details-page .mq-details-hero-visual img,
  .mq-details-main .mq-details-hero-visual img,
  body.mq-page-chrome :is(.sgwp-suite-public-photo img,.sgwp-place-public-photo img,.sgwp-modal-photo img,.sgwp-visitor-photo img){
    aspect-ratio:auto!important;
    object-fit:contain!important;
  }

  body.myguideqr-sales-template .mq-home-v220 .mq-showcase-visual .mq-home-photo,
  body.mq-demo-v222-template .mq-demo-v222-photo--wide,
  body.mq-demo-editor-v226 .mqde-editor-overview-visual img,
  body.mq-packages-v230 :is(.mq-packages-photo-card--hero img,.mq-package-card__visual img),
  body.mq-details-page .mq-details-visual-media img,
  .mq-details-main .mq-details-visual-media img{
    aspect-ratio:4 / 3!important;
    object-fit:cover!important;
  }

  body.mq-details-page .mq-details-visual-story,
  .mq-details-main .mq-details-visual-story{
    grid-template-columns:1fr!important;
  }

  body.mq-details-page .mq-details-visual-story.is-reverse .mq-details-visual-media,
  .mq-details-main .mq-details-visual-story.is-reverse .mq-details-visual-media{
    order:0!important;
  }
}

@media (max-width:480px){
  body.myguideqr-sales-template :is(.mq-home-photo,.mq-home-custom-image),
  body.mq-demo-v222-template .mq-demo-v222-photo,
  body.mq-demo-editor-v226 :is(.mqde-editor-visual img,.mqde-editor-overview-visual img),
  body.mq-packages-v230 :is(.mq-packages-photo-card,.mq-package-card__visual img),
  body.mq-details-page :is(.mq-details-hero-visual img,.mq-details-visual-media img),
  .mq-details-main :is(.mq-details-hero-visual img,.mq-details-visual-media img){
    border-radius:18px!important;
  }

  body.myguideqr-sales-template .mq-home-v220 .mq-home-visual-stack--visual-only .mq-home-orbit{
    width:100%!important;
  }
}
