/* Bi'Tişört tasarla mobil düzeltmeleri v1.0.0 — yalnızca mobil/dokunmatik; masaüstü değişmez. */
@media (max-width:1050px){
  /* 1) Kalite kartı sabit yükseklikte bir yuvada; açılınca tuvali itmez, üstte katman olur. */
  .mobile-audit-row{position:relative!important;flex:0 0 60px!important;height:60px!important;min-height:60px!important;max-height:60px!important;overflow:visible!important;z-index:70!important;padding:0!important}
  .mobile-audit-row .design-audit-card{position:absolute!important;top:5px!important;left:8px!important;right:8px!important;width:auto!important;margin:0!important;box-sizing:border-box!important}
  .mobile-audit-row .design-audit-card.audit-collapsed{height:50px!important;min-height:0!important;max-height:50px!important;overflow:hidden!important;padding-top:6px!important;padding-bottom:6px!important}
  .mobile-audit-row .design-audit-card:not(.audit-collapsed){height:auto!important;max-height:min(58dvh,380px)!important;overflow-y:auto!important;overscroll-behavior:contain;box-shadow:0 18px 40px rgba(15,23,42,.28)!important}
  .mobile-audit-row .design-audit-card .quality-head{min-height:38px!important;cursor:pointer}
  .mobile-audit-row .design-audit-card .quality-head > div{min-width:0}
  .mobile-audit-row .design-audit-card .quality-head strong{white-space:nowrap!important;overflow:hidden!important;text-overflow:ellipsis!important}
  body.bt-canvas-touching .mobile-audit-row .design-audit-card{pointer-events:none}

  /* 3-4) Sahnede sayfa kaydırma / yakınlaşma yok; hareketler tasarıma gider. */
  .canvas-viewport,.canvas-viewport .canvas-container,.canvas-viewport canvas{touch-action:none!important;-webkit-user-select:none;user-select:none;-webkit-touch-callout:none}
  .canvas-viewport{overscroll-behavior:contain}

  /* Önizleme penceresi: ön/arka kartlar ve sipariş bilgisi üst üste binmesin. */
  [data-preview-modal] .design-preview-body:not([hidden]){display:block!important;grid-template-rows:none!important}
  [data-preview-modal] .design-preview-body[hidden]{display:none!important}
  [data-preview-modal] .preview-product-area{height:auto!important;min-height:0!important;max-height:none!important;overflow:visible!important}
  [data-preview-modal] .preview-surfaces-grid{height:auto!important;grid-auto-rows:auto!important;grid-template-rows:none!important}
  [data-preview-modal] .preview-surface-card{height:auto!important;min-height:0!important}
  [data-preview-modal] .preview-canvas-shell{height:auto!important;aspect-ratio:1/1;max-height:62vh}
  [data-preview-modal] .preview-canvas-shell img{width:100%!important;height:100%!important;max-height:none!important;object-fit:contain!important}
  [data-preview-modal] .preview-check-panel{position:static!important;height:auto!important;margin-top:12px!important}

  /* iOS: 16px altı alanlarda otomatik yakınlaşma olmasın. */
  input[type=text],input[type=number],input[type=email],input[type=tel],input[type=search],input:not([type]),select,textarea{font-size:16px!important}
  html body #textValue,html body #colorSelect,html body #qtyInput,html body #sizeSelect,html body .studio-sidebar input:not([type=checkbox]):not([type=radio]):not([type=range]):not([type=color]),html body .studio-sidebar select,html body .studio-sidebar textarea{font-size:16px!important}
}
@media (max-width:1050px){
  /* Küçük dokunma hedefleri (>=40px) */
  .mobile-header-controls .bttour-mobile-btn,.mobile-header-controls .mobile-help-button{min-width:40px!important;min-height:40px!important}
  #sizeQtyGrid .size-step-plus,#sizeQtyGrid .size-step-minus{min-width:40px!important;min-height:40px!important}
  #sizeQtyGrid .size-step-box{min-height:40px!important}
  .size-chart-link{min-height:40px!important;display:inline-flex!important;align-items:center}
  .smart-tip button{min-height:36px!important}
  .kpe-seg > button{min-height:40px!important}
  .kpe-step > button{min-width:40px!important;min-height:40px!important}
  #kpeColors > button{min-width:36px!important;min-height:36px!important}
}
@media (max-width:1050px){
  /* 360px: başlık düğmeleri eşit genişliğe yayılıp logoyu sıkıştırmasın */
  .studio-header .mobile-header-controls{justify-content:flex-end!important;justify-self:end!important;width:auto!important;gap:6px!important;min-width:0}
  .studio-header .mobile-header-controls > *{flex:0 0 auto!important;width:auto!important}
}
@media (max-width:1050px) and (orientation:landscape) and (max-height:520px){
  /* Yatay telefon: kalite kartı ve ön/arka seçici tuvalin üstüne binmesin, tuval büyüsün */
  .mobile-audit-row{flex-basis:0px!important;height:0!important;min-height:0!important;max-height:0!important}
  .mobile-audit-row .design-audit-card{right:auto!important;width:min(300px,34vw)!important;top:6px!important}
  .mobile-audit-row .design-audit-card:not(.audit-collapsed){max-height:calc(100dvh - 130px)!important}
  #surfaceSwitch{left:10px!important;right:auto!important;top:auto!important;bottom:calc(env(safe-area-inset-bottom,0px) + 62px)!important;transform:none!important}
}
