/* HealthyLife V15 — shared header entry animation + mobile safety */
body.hl-mobile-entry-v14 .header,
body.hl-mobile-entry-v14 .hl-shop-header {
  transform: translateY(-105%) !important;
  opacity: 0 !important;
  visibility: hidden !important;
  transition:
    transform .58s cubic-bezier(.22,.61,.36,1),
    opacity .42s ease !important;
  will-change: transform, opacity;
}

body.hl-mobile-entry-v14.hl-mobile-entry-ready-v14 .header,
body.hl-mobile-entry-v14.hl-mobile-entry-ready-v14 .hl-shop-header {
  transform: translateY(0) !important;
  opacity: 1 !important;
  visibility: visible !important;
}

@media (prefers-reduced-motion: reduce) {
  body.hl-mobile-entry-v14 .header,
  body.hl-mobile-entry-v14 .hl-shop-header {
    transform: none !important;
    opacity: 1 !important;
    visibility: visible !important;
    transition: none !important;
  }
}

@media (max-width: 768px) {
  body.hl-mobile-entry-v14 select.language-select,
  body.hl-mobile-entry-v14 select.hl-shop-select {
    font-size: 16px !important;
  }
}


/* =========================================================
   V16 — guaranteed site-header drop on every page load
   Desktop + mobile. Does not depend on JS timing.
   ========================================================= */
@keyframes hlPageHeaderDropV16 {
  from {
    transform: translateY(-110%);
    opacity: 0;
  }
  to {
    transform: translateY(0);
    opacity: 1;
  }
}

body.hl-mobile-entry-v14 .header,
body.hl-mobile-entry-v14 .hl-shop-header {
  visibility: visible !important;
  animation: hlPageHeaderDropV16 .58s cubic-bezier(.22,.61,.36,1) both !important;
  transition: none !important;
}

body.hl-mobile-entry-v14.hl-mobile-entry-ready-v14 .header,
body.hl-mobile-entry-v14.hl-mobile-entry-ready-v14 .hl-shop-header {
  visibility: visible !important;
}

@media (prefers-reduced-motion: reduce) {
  body.hl-mobile-entry-v14 .header,
  body.hl-mobile-entry-v14 .hl-shop-header {
    animation: none !important;
    transform: none !important;
    opacity: 1 !important;
  }
}


/* ===== HealthyLife global mobile containment v24 ===== */
html,body{max-width:100%;overflow-x:hidden}
img,video,canvas,svg{max-width:100%}
.header,.nav,.nav-links,.main-content,.products-section,.dashboard-panel,.payment-modal,.auth-overlay *{box-sizing:border-box}
.nav>* ,.nav-links>* ,.product-card>* ,.dashboard-panel>* ,.payment-modal>*{min-width:0}
button,a,input,select,textarea{max-width:100%;box-sizing:border-box}
.product-card,.category-card,.dashboard-card,.cart-item,.payment-modal{overflow-wrap:anywhere;word-break:break-word}
.dashboard-table-wrap,.table-responsive,.hl-tab-buttons,.products-pagination{max-width:100%;overflow-x:auto;-webkit-overflow-scrolling:touch}
@media(max-width:700px){.nav-links{min-width:0}.nav-links a{white-space:normal}.payment-methods{display:flex!important;overflow-x:auto!important;flex-wrap:nowrap!important;-webkit-overflow-scrolling:touch;padding-bottom:6px}.payment-method{flex:0 0 auto!important;white-space:nowrap}.payment-row{grid-template-columns:1fr!important}.payment-modal{width:min(94vw,520px)!important;max-height:90dvh!important;overflow:auto!important}.products-pagination{display:flex!important;gap:6px;flex-wrap:nowrap!important}.products-pagination .pagination-btn{flex:0 0 auto}.dashboard-table{min-width:680px}}

/* HealthyLife V15 — never split UI text letter-by-letter on phones */
@media (max-width:700px){
  button,a,label,th,td,.btn,[class*="button"],[class*="status"],[class*="badge"]{
    word-break:normal!important;
    overflow-wrap:break-word!important;
    hyphens:none!important;
  }
  button,.btn,[class*="button"],[class*="status"],[class*="badge"]{
    white-space:normal!important;
    line-height:1.25!important;
  }
  .product-actions,.product-page-actions,.hl-feature-actions,.hl-product-tools{
    max-width:100%!important;
  }
  .product-actions button,.product-page-actions button,.hl-feature-actions button,.hl-product-tools button,
  .product-actions a,.product-page-actions a,.hl-feature-actions a,.hl-product-tools a{
    max-width:100%!important;
    width:auto!important;
    min-width:0!important;
  }
  .hl-tab-buttons,.product-tabs,[role="tablist"]{
    overflow-x:auto!important;
    -webkit-overflow-scrolling:touch!important;
  }
  .hl-tab-buttons>* ,.product-tabs>* ,[role="tablist"]>*{
    flex:0 0 auto!important;
    white-space:nowrap!important;
  }
}

/* HealthyLife V17 — do not split actionable UI text on mobile */
@media(max-width:700px){
  .dashboard-table-wrap,
  .table-responsive,
  .hl-feature-table-wrap,
  .hl-tab-buttons,
  .product-tabs,
  [role="tablist"]{
    overflow-x:auto!important;
    -webkit-overflow-scrolling:touch!important;
  }

  .dashboard-table button,
  .dashboard-table a,
  .hl-feature-table button,
  .hl-feature-table a,
  .hl-tab-buttons>*,
  .product-tabs>*,
  [role="tablist"]>*{
    white-space:nowrap!important;
    word-break:keep-all!important;
    overflow-wrap:normal!important;
  }
}
