/* TEDY R4.19 mobile-first hardening for 390–430px devices. */
html,body{max-width:100%;overflow-x:hidden}
img{max-width:100%;height:auto}
button,.btn,select,input,textarea{touch-action:manipulation}
@media(max-width:760px){
  :root{--safe-bottom:env(safe-area-inset-bottom,0px)}
  .app-shell{min-width:0!important;width:100%!important}
  .main-wrap,.content,#main{min-width:0!important;max-width:100%!important}
  .topbar{min-width:0!important;gap:6px!important;padding:9px 10px!important;overflow:visible!important}
  .topbar-title{flex:1 1 auto;min-width:0!important}.topbar-title h2{font-size:15px!important}.topbar-title small{font-size:10px!important}
  .topbar-actions{flex:0 0 auto;gap:4px!important;max-width:48vw;overflow:hidden}.topbar-actions>*{max-width:46vw!important}
  .content{padding:10px 10px calc(94px + var(--safe-bottom))!important}
  .page-head{gap:8px!important;margin-bottom:12px!important}.page-head h1{font-size:24px!important;line-height:1.15!important}.page-head p{font-size:12px!important}
  .page-head .actions{display:grid!important;grid-template-columns:1fr!important;width:100%!important;margin-left:0!important}.page-head .actions>*{width:100%!important;min-height:46px!important;white-space:normal!important}
  .grid,.g2,.g3,.g4,.g5,.split,.gallery{grid-template-columns:1fr!important;min-width:0!important}
  .kpi{min-height:96px!important;padding:13px!important}.card{padding:13px!important;border-radius:16px!important}.hero{min-height:0!important;padding:10px!important}.hero-art{height:150px!important;border-radius:14px!important}
  .form-grid{grid-template-columns:1fr!important;gap:10px!important;padding-bottom:14px!important}.form-grid .field,.form-grid .field.full{grid-column:1!important;min-width:0!important}.field input,.field select,.field textarea{font-size:16px!important;min-height:46px!important}.field textarea{min-height:100px!important}
  .table-wrap{width:100%!important;max-width:100%!important;overflow-x:auto!important;overflow-y:hidden!important;-webkit-overflow-scrolling:touch!important}.table-wrap table{min-width:680px!important}.table-wrap th,.table-wrap td{padding:9px 10px!important;font-size:11px!important}
  .modal-backdrop{place-items:start center!important;padding:4px!important;overflow-y:auto!important}.modal{width:100%!important;max-width:100%!important;max-height:calc(100dvh - 8px)!important;border-radius:14px!important;margin:0!important}.modal-head{padding:12px!important}.modal-body{padding:12px!important}.modal-foot{flex-direction:column!important;align-items:stretch!important;padding:10px 12px calc(10px + var(--safe-bottom))!important}.modal-foot>*{width:100%!important;min-height:46px!important}
  .sticky-form-actions{position:sticky!important;bottom:0!important;z-index:9!important;background:var(--panel,#071b12)!important;padding:10px 0 calc(10px + var(--safe-bottom))!important}
  .actions,.toolbar{gap:7px!important}.toolbar>*{min-height:44px!important}.toolbar .search{min-width:0!important;flex-basis:100%!important}
  .mobile-bottom{padding-bottom:calc(7px + var(--safe-bottom))!important}.mobile-bottom button{min-height:58px!important;line-height:1.15!important}
}
@media(max-width:430px){.brand h1{font-size:14px!important}.nav-btn{padding:11px 10px!important}.nav-btn .label{font-size:12px!important}.topbar-title small{display:none!important}.toast-root{left:8px!important;right:8px!important;bottom:calc(78px + var(--safe-bottom))!important}.toast{max-width:none!important}.r2-luxury-hero .hero-copy h1{font-size:28px!important}}

/* R4.19.4 visible language-selector UX; uses existing #v28Lang state. */
.tedy-language-control{display:inline-flex;align-items:center;gap:6px;color:inherit;z-index:30}.tedy-language-control select{min-height:40px!important;min-width:112px!important;padding:7px 8px!important;border-radius:10px!important;font-size:14px!important}.tedy-language-label{font-size:12px;white-space:nowrap}.tedy-language-settings{margin:12px 0;padding:12px;border:1px solid rgba(255,255,255,.16);border-radius:12px;background:rgba(10,40,25,.8)}
@media(max-width:760px){.tedy-language-top{position:fixed!important;top:8px;right:8px;background:rgba(4,19,13,.96);padding:4px 6px;border-radius:12px;box-shadow:0 4px 18px rgba(0,0,0,.35)}.tedy-language-top .tedy-language-label{display:none}.tedy-language-profile{display:none}.topbar-actions{padding-right:126px!important;max-width:none!important;overflow:visible!important}.tedy-language-settings{display:flex!important;position:relative!important;margin:12px 0!important}.tedy-language-settings select{width:100%!important}.tedy-language-settings .tedy-language-label{display:block!important}}

/* R4.19.5: standalone mobile control; never depends on desktop header geometry. */
.tedy-language-fixed{position:fixed!important;top:max(8px,env(safe-area-inset-top))!important;right:8px!important;display:inline-flex!important;align-items:center!important;gap:5px!important;padding:5px 7px!important;background:#061b12!important;color:#fff!important;border:1px solid rgba(255,255,255,.35)!important;border-radius:12px!important;box-shadow:0 3px 14px rgba(0,0,0,.5)!important;z-index:2147483000!important;visibility:visible!important;opacity:1!important;pointer-events:auto!important}
.tedy-language-fixed .tedy-language-label{display:none!important}.tedy-language-fixed select{display:block!important;visibility:visible!important;opacity:1!important;min-width:104px!important;min-height:42px!important;background:#0d3a26!important;color:#fff!important;border:1px solid rgba(255,255,255,.55)!important;font-weight:700!important}
.tedy-language-settings{display:flex!important;visibility:visible!important;opacity:1!important;position:relative!important;z-index:20!important}
@media(max-width:430px){.tedy-language-fixed{top:max(6px,env(safe-area-inset-top))!important;right:6px!important}.tedy-language-fixed select{min-width:98px!important;font-size:14px!important}.topbar-actions{padding-right:0!important}}
