/* CE mobile - shared fixes */
html{-webkit-text-size-adjust:100%;text-size-adjust:100%}
img,video,iframe{max-width:100%}
#cem-burger,#cem-backdrop{display:none}
@media(max-width:768px){
  input:not([type=checkbox]):not([type=radio]):not([type=range]):not([type=color]),select,textarea{font-size:16px!important}
}
@media(max-width:960px){
  html:has(aside.sidebar):not(:has(script[src*="ce-admin-shell"])) aside.sidebar{display:flex!important;position:fixed!important;top:0;left:0;bottom:0;height:100%!important;width:260px!important;max-width:82vw;transform:translateX(-105%);transition:transform .25s ease;z-index:1001!important;overflow-y:auto}
  html.cem-open:has(aside.sidebar):not(:has(script[src*="ce-admin-shell"])) aside.sidebar{transform:none}
  html:has(aside.sidebar):not(:has(script[src*="ce-admin-shell"])) .main{margin-left:0!important;padding-top:64px!important}
  html:has(aside.sidebar):not(:has(script[src*="ce-admin-shell"])) .sb-float-toggle{display:none!important}
  #cem-burger{display:flex;flex-direction:column;justify-content:center;gap:4px;position:fixed;top:calc(10px + env(safe-area-inset-top,0px));left:10px;z-index:1002;width:44px;height:44px;padding:0 12px;border:0;border-radius:12px;background:#00B8B8;box-shadow:0 2px 8px rgba(0,0,0,.2);cursor:pointer;transition:left .25s ease}
  #cem-burger span{display:block!important;width:20px!important;height:2px!important;margin:0!important;padding:0!important;background:#fff!important;border-radius:2px;transition:transform .2s,opacity .2s}
  html.cem-open #cem-burger{left:calc(min(260px,82vw) + 10px)}
  html.cem-open #cem-burger span:nth-child(1){transform:translateY(6px) rotate(45deg)}
  html.cem-open #cem-burger span:nth-child(2){opacity:0}
  html.cem-open #cem-burger span:nth-child(3){transform:translateY(-6px) rotate(-45deg)}
  html.cem-open #cem-backdrop{display:block;position:fixed;inset:0;background:rgba(0,0,0,.45);z-index:1000}
  html.cem-open,html.cem-open body{overflow:hidden}
}

/* ce-footer-mobile: public-page footer table stacks on phones */
@media(max-width:640px){
  footer>table,footer>table tbody{display:block;width:100%}
  footer>table tr{display:grid;grid-template-columns:1fr 1fr}
  footer>table td{width:auto!important;padding:28px 24px 0!important}
  footer>table td:first-child,footer>table td:last-child{grid-column:1/-1}
  footer>table td:last-child{padding-bottom:32px!important}
  footer>div{padding-left:24px!important;padding-right:24px!important}
}

/* iOS date fields */
@supports (-webkit-touch-callout:none){
  input[type=date],input[type=datetime-local],input[type=time]{min-height:44px;min-width:0;max-width:100%;text-align:left}
  input[type=date]::-webkit-date-and-time-value,input[type=datetime-local]::-webkit-date-and-time-value,input[type=time]::-webkit-date-and-time-value{text-align:left}
}
