/* 운영 템플릿에만 있는 모바일 요소(시안에 없던 것)와 시안 보정. m-base.css 뒤에 읽는다. */
@media (max-width:767px){
  .m-ui .site-footer address{margin:0 0 12px;line-height:1.7}
  .m-ui .site-footer address a{color:var(--ink);font-weight:500}
  .m-ui .footer-links a{min-height:44px;display:inline-flex;align-items:center;font-size:11px}
  .m-ui .footer-links a:first-child{font-weight:700;color:var(--ink)}
  .m-ui .mega-search{margin-top:14px}
  .m-ui .mega-search input[type=search]{width:100%;height:44px;padding:0 14px;border-radius:22px;background:#ffffff1f;color:#fff;border:1px solid #ffffff40}
  .m-ui .mega-search input[type=search]::placeholder{color:#c5d7f6}
  .m-ui .mega-empty{padding:24px 22px;color:var(--muted);font-size:14px}
  .m-ui .mega-acc li[hidden],.m-ui .mega-acc .acc[hidden]{display:none}
  .m-ui .sp-grid[hidden]{display:none}

  /* 메인 팝업(관리자 등록, PC 마크업): 화면 아래에서 올라오는 창으로. PC 위치·크기 지정(인라인)을 덮어쓴다 */
  .main-popup{position:fixed!important;left:10px!important;right:10px!important;top:auto!important;bottom:calc(80px + env(safe-area-inset-bottom))!important;width:auto!important;max-height:72vh;overflow:auto;border-radius:14px;box-shadow:0 10px 40px #0003}
  .main-popup .pop-bg{min-height:0!important;height:auto!important}
  .main-popup .pop-text{padding:22px 18px!important;font-size:15px;line-height:1.6}
  .main-popup .pop-text img{max-width:100%;height:auto}
  .main-popup .btn-wrap{padding:10px 14px;gap:8px}
  .main-popup .txt_label{font-size:13px!important}

  /* 오류 화면(PC 마크업 그대로, 모바일 폭에 맞춤) */
  body.m-error .error-cont{min-width:0!important;width:auto!important;padding:64px 22px 48px!important;box-sizing:border-box}
  body.m-error .e-wrap{position:static!important;transform:none!important;width:auto!important;max-width:100%;text-align:center}
  body.m-error .e-wrap h2{font-size:21px!important;line-height:1.45;margin-bottom:20px!important;word-break:keep-all}
  body.m-error .e-wrap i.fa-exclamation-circle{font-size:44px}
  body.m-error .e-sub-text p{font-size:14px;line-height:1.7;word-break:keep-all}
  body.m-error .e-wrap .mtop50{margin-top:28px!important;display:flex;gap:8px;justify-content:center;flex-wrap:wrap}
  body.m-error .e-wrap .btn-base{min-width:0!important;min-height:46px;padding:0 18px;font-size:15px}
}

/* 범위를 넘는 쪽(빈 목록)에서 첫 쪽으로 돌아가는 링크 */
@media (max-width:767px){
  .m-ui .empty a{display:inline-block;min-height:44px;padding:10px 4px;color:var(--blue);font-weight:500;text-decoration:underline}
}
