/* WEN SPORT v73 — Mobil/masaüstü sipariş föyü üst işlemler ve ilgili birime taşıma düzeni v4 */

.wen-stage-actions-enhanced {
  display: grid !important;
  grid-template-columns: minmax(170px, 1fr) minmax(250px, 1.2fr) minmax(170px, 1fr) !important;
  align-items: end !important;
  gap: 12px !important;
}

.wen-stage-actions-enhanced > .btn {
  min-height: 52px !important;
}

.wen-stage-transfer-wrap {
  min-width: 0 !important;
  padding: 12px !important;
  border: 1px solid #dbe6f4 !important;
  border-radius: 18px !important;
  background: linear-gradient(180deg, #fbfdff 0%, #f3f8ff 100%) !important;
  box-shadow: 0 14px 30px rgba(15, 23, 42, .05) !important;
}

.wen-stage-transfer-label {
  display: block !important;
  margin: 0 0 8px !important;
  font-size: 12px !important;
  font-weight: 900 !important;
  letter-spacing: .02em !important;
  color: #1e3a8a !important;
}

.wen-stage-transfer-field {
  position: relative !important;
  display: flex !important;
  align-items: center !important;
  min-height: 52px !important;
  border-radius: 16px !important;
  border: 1px solid #c9d8ef !important;
  background: #fff !important;
  overflow: hidden !important;
}

.wen-stage-transfer-icon {
  width: 44px !important;
  height: 44px !important;
  margin-left: 6px !important;
  border-radius: 13px !important;
  display: grid !important;
  place-items: center !important;
  background: linear-gradient(135deg, #eff6ff, #ecfeff) !important;
  color: #2563eb !important;
  font-size: 18px !important;
  flex: 0 0 auto !important;
}

.wen-stage-transfer-select {
  appearance: none !important;
  -webkit-appearance: none !important;
  width: 100% !important;
  min-width: 0 !important;
  height: 52px !important;
  border: 0 !important;
  background: transparent !important;
  padding: 0 40px 0 12px !important;
  font-size: 15px !important;
  font-weight: 800 !important;
  color: #0f172a !important;
  outline: none !important;
  box-shadow: none !important;
}

.wen-stage-transfer-select:disabled {
  opacity: .7 !important;
  cursor: wait !important;
}

.wen-stage-transfer-caret {
  position: absolute !important;
  right: 14px !important;
  top: 50% !important;
  transform: translateY(-50%) !important;
  color: #64748b !important;
  font-size: 14px !important;
  pointer-events: none !important;
}

.wen-stage-transfer-note {
  display: block !important;
  margin-top: 8px !important;
  font-size: 11px !important;
  line-height: 1.35 !important;
  color: #b45309 !important;
  font-weight: 700 !important;
}

.wen-stage-transfer-wrap.is-busy {
  opacity: .8 !important;
}

.mobile-stage-hint-hidden {
  display: none !important;
}

@media (min-width: 901px) {
  .wen-stage-actions-enhanced {
    margin-top: 10px !important;
  }
}

@media (max-width: 900px) {
  html[data-ui-mode="mobile"] #mobileBottomNav {
    z-index: 18500 !important;
    pointer-events: auto !important;
  }

  html[data-ui-mode="mobile"] #mobileBottomNav button,
  html[data-ui-mode="mobile"] #notificationBtn,
  html[data-ui-mode="mobile"] #mobileNotificationNav,
  html[data-ui-mode="mobile"] #ownBoardToggle,
  html[data-ui-mode="mobile"] #mobileMoreBtn,
  html[data-ui-mode="mobile"] #mobileQuickAction {
    position: relative !important;
    pointer-events: auto !important;
    touch-action: manipulation !important;
    -webkit-tap-highlight-color: transparent;
  }

  html[data-ui-mode="mobile"] #notificationPanel {
    z-index: 19600 !important;
    pointer-events: auto !important;
  }

  html[data-ui-mode="mobile"] #mobileOverlay:not(.open),
  html[data-ui-mode="mobile"] #mobileSheetOverlay:not(.open),
  html[data-ui-mode="mobile"] .mobile-action-sheet:not(.open) {
    pointer-events: none !important;
  }

  html[data-ui-mode="mobile"] .wen-mobile-order-drawer-fixed {
    padding-bottom: 0 !important;
  }

  html[data-ui-mode="mobile"] .mobile-order-action-dock,
  html[data-ui-mode="mobile"] .wen-mobile-source-actions {
    display: none !important;
  }

  html[data-ui-mode="mobile"] .order-detail-head {
    display: grid !important;
    grid-template-columns: minmax(0, 1fr) !important;
    gap: 10px !important;
    padding: 14px 10px 10px !important;
  }

  html[data-ui-mode="mobile"] .order-detail-heading {
    width: 100% !important;
    min-width: 0 !important;
  }

  html[data-ui-mode="mobile"] .order-detail-heading h2 {
    font-size: 21px !important;
    line-height: 1.16 !important;
    margin-top: 8px !important;
    word-break: break-word;
  }

  html[data-ui-mode="mobile"] .order-detail-heading p {
    font-size: 10px !important;
    line-height: 1.4 !important;
  }

  html[data-ui-mode="mobile"] .wen-mobile-order-head-actions {
    width: 100% !important;
    display: flex !important;
    align-items: center !important;
    gap: 6px !important;
    margin: 2px 0 0 !important;
    padding: 0 !important;
    overflow-x: auto !important;
    scrollbar-width: none !important;
    -ms-overflow-style: none !important;
  }

  html[data-ui-mode="mobile"] .wen-mobile-order-head-actions::-webkit-scrollbar {
    display: none !important;
  }

  html[data-ui-mode="mobile"] .wen-mobile-order-head-actions > button {
    display: inline-flex !important;
    align-items: center !important;
    justify-content: center !important;
    flex: 0 0 auto !important;
    min-width: 0 !important;
    min-height: 40px !important;
    margin: 0 !important;
    padding: 9px 12px !important;
    border-radius: 14px !important;
    white-space: nowrap !important;
    text-align: center !important;
    font-size: 11px !important;
    line-height: 1.1 !important;
    font-weight: 800 !important;
    touch-action: manipulation !important;
    box-shadow: 0 10px 24px rgba(15, 23, 42, .08) !important;
  }

  html[data-ui-mode="mobile"] .wen-mobile-order-top-action.payment-action {
    background: linear-gradient(135deg, #eff6ff, #e0f2fe) !important;
    color: #1d4ed8 !important;
    border: 1px solid #bfdbfe !important;
  }

  html[data-ui-mode="mobile"] .wen-mobile-order-top-action.special-action {
    background: linear-gradient(135deg, #f5f3ff, #ede9fe) !important;
    color: #7c3aed !important;
    border: 1px solid #ddd6fe !important;
  }

  html[data-ui-mode="mobile"] .wen-mobile-order-top-action.edit-action {
    background: linear-gradient(135deg, #4338ca, #7c3aed) !important;
    color: #fff !important;
    border: 1px solid transparent !important;
    box-shadow: 0 14px 28px rgba(124, 58, 237, .24) !important;
  }

  html[data-ui-mode="mobile"] .wen-mobile-order-top-action.print-action {
    display: inline-flex !important;
    background: linear-gradient(135deg, #f8fafc, #eef2f7) !important;
    color: #334155 !important;
    border: 1px solid #d7deea !important;
  }

  html[data-ui-mode="mobile"] .wen-mobile-order-head-actions .wen-mobile-order-close-action {
    margin-left: auto !important;
    display: grid !important;
    place-items: center !important;
    width: 40px !important;
    min-width: 40px !important;
    height: 40px !important;
    min-height: 40px !important;
    padding: 0 !important;
    font-size: 18px !important;
    line-height: 1 !important;
    background: #fff !important;
    color: #334155 !important;
    border: 1px solid #d7deea !important;
    border-radius: 14px !important;
    box-shadow: none !important;
  }

  html[data-ui-mode="mobile"] .stage-actions.wen-mobile-stage-actions,
  html[data-ui-mode="mobile"] .wen-stage-actions-enhanced {
    grid-template-columns: 1fr !important;
    gap: 10px !important;
    width: 100% !important;
    padding: 12px !important;
    margin: 8px 0 10px !important;
    border: 1px solid #dfe7f3 !important;
    border-radius: 20px !important;
    background: linear-gradient(180deg, #ffffff, #f8fbff) !important;
    box-shadow: 0 12px 30px rgba(15,23,42,.05) !important;
  }

  html[data-ui-mode="mobile"] .wen-stage-actions-enhanced > .btn {
    width: 100% !important;
    min-height: 50px !important;
    font-size: 12px !important;
    font-weight: 850 !important;
    border-radius: 15px !important;
  }

  html[data-ui-mode="mobile"] .wen-stage-transfer-wrap {
    padding: 10px !important;
    border-radius: 16px !important;
    background: linear-gradient(180deg, #f8fbff 0%, #eef5ff 100%) !important;
  }

  html[data-ui-mode="mobile"] .wen-stage-transfer-label {
    font-size: 11px !important;
    margin-bottom: 6px !important;
  }

  html[data-ui-mode="mobile"] .wen-stage-transfer-field {
    min-height: 48px !important;
    border-radius: 14px !important;
  }

  html[data-ui-mode="mobile"] .wen-stage-transfer-icon {
    width: 38px !important;
    height: 38px !important;
    margin-left: 5px !important;
    border-radius: 12px !important;
    font-size: 16px !important;
  }

  html[data-ui-mode="mobile"] .wen-stage-transfer-select {
    height: 48px !important;
    font-size: 13px !important;
    padding-right: 34px !important;
  }

  html[data-ui-mode="mobile"] .wen-stage-transfer-note {
    font-size: 10px !important;
    margin-top: 6px !important;
  }

  html[data-ui-mode="mobile"] .order-detail-body {
    padding-bottom: 22px !important;
  }
}

@media (max-width: 370px) {
  html[data-ui-mode="mobile"] .wen-mobile-order-head-actions > button,
  html[data-ui-mode="mobile"] .wen-stage-actions-enhanced > .btn,
  html[data-ui-mode="mobile"] .wen-stage-transfer-select {
    font-size: 10px !important;
  }

  html[data-ui-mode="mobile"] .wen-mobile-order-head-actions .wen-mobile-order-close-action {
    width: 38px !important;
    min-width: 38px !important;
  }
}

html[data-visual-theme="studio"] .wen-stage-transfer-wrap,
html[data-visual-theme="studio"] .wen-stage-actions-enhanced {
  background: #0d1a2d !important;
  border-color: rgba(148,163,184,.18) !important;
  box-shadow: 0 14px 28px rgba(0,0,0,.24) !important;
}

html[data-visual-theme="studio"] .wen-stage-transfer-label {
  color: #93c5fd !important;
}

html[data-visual-theme="studio"] .wen-stage-transfer-field {
  background: rgba(15,23,42,.9) !important;
  border-color: rgba(56,189,248,.24) !important;
}

html[data-visual-theme="studio"] .wen-stage-transfer-icon {
  background: linear-gradient(135deg, #1d4ed8, #0891b2) !important;
  color: #fff !important;
}

html[data-visual-theme="studio"] .wen-stage-transfer-select,
html[data-visual-theme="studio"] .wen-stage-transfer-caret {
  color: #e2e8f0 !important;
}

html[data-visual-theme="studio"] .wen-stage-transfer-note,
html[data-visual-theme="studio"] .mobile-stage-transfer-note {
  color: #fbbf24 !important;
}

html[data-visual-theme="studio"] .wen-mobile-order-top-action.payment-action,
html[data-visual-theme="studio"] .wen-mobile-order-top-action.special-action,
html[data-visual-theme="studio"] .wen-mobile-order-head-actions .wen-mobile-order-close-action {
  color: #e2e8f0 !important;
}

html[data-visual-theme="studio"] .wen-mobile-order-top-action.payment-action {
  background: linear-gradient(135deg, #0f2747, #12385c) !important;
  border-color: rgba(96,165,250,.20) !important;
}

html[data-visual-theme="studio"] .wen-mobile-order-top-action.special-action {
  background: linear-gradient(135deg, #241245, #3b1b5a) !important;
  border-color: rgba(196,181,253,.18) !important;
}

html[data-visual-theme="studio"] .wen-mobile-order-head-actions .wen-mobile-order-close-action {
  background: #13243b !important;
  border-color: rgba(148,163,184,.20) !important;
}

/* v73 — mobil global arama + çoklu tasarım galerisi */
.wen-mobile-global-search{display:none}
@media(max-width:900px){
  html[data-ui-mode="mobile"] .wen-mobile-global-search{
    display:flex!important;
    align-items:center;
    gap:8px;
    position:sticky;
    top:0;
    z-index:16000;
    margin:0;
    padding:9px 12px;
    background:rgba(248,251,255,.96);
    border-bottom:1px solid #dce6f3;
    backdrop-filter:blur(14px);
    -webkit-backdrop-filter:blur(14px);
  }
  html[data-ui-mode="mobile"] .wen-mobile-search-icon{
    width:34px;height:34px;border-radius:11px;display:grid;place-items:center;
    background:#edf4ff;color:#2563eb;font-size:18px;flex:0 0 auto;
  }
  html[data-ui-mode="mobile"] #wenMobileGlobalSearchInput{
    flex:1 1 auto;min-width:0;height:42px!important;border:1px solid #cfdced!important;
    border-radius:13px!important;background:#fff!important;color:#13213a!important;
    padding:0 40px 0 12px!important;font-size:13px!important;box-shadow:none!important;outline:none!important;
  }
  html[data-ui-mode="mobile"] #wenMobileGlobalSearchInput:focus{
    border-color:#5b8cff!important;box-shadow:0 0 0 3px rgba(37,99,235,.10)!important;
  }
  html[data-ui-mode="mobile"] #wenMobileGlobalSearchClear{
    display:none;width:32px;height:32px;border:0;border-radius:10px;background:#eef2f7;color:#64748b;
    font-size:18px;font-weight:800;flex:0 0 auto;
  }
  html[data-ui-mode="mobile"] #wenMobileGlobalSearchClear.is-visible{display:grid;place-items:center}
}

.wen-design-gallery{
  margin:8px 10px 12px;padding:10px;border:1px solid #d8e4f3;border-radius:14px;background:#fbfdff;
}
.wen-design-gallery-head{display:flex;align-items:center;justify-content:space-between;gap:10px;margin-bottom:9px}
.wen-design-gallery-head>div{display:flex;flex-direction:column;gap:2px;min-width:0}
.wen-design-gallery-head strong{font-size:12px;color:#10234a}
.wen-design-gallery-head small{font-size:9px;color:#71809a}
.wen-design-gallery-head .btn{white-space:nowrap}
.wen-design-gallery-strip{display:flex;gap:8px;overflow-x:auto;padding:2px 1px 5px;scrollbar-width:thin}
.wen-design-thumb{
  position:relative;flex:0 0 78px;width:78px;height:78px;padding:3px;border:1px solid #cdd9ea;border-radius:11px;
  background:#fff;overflow:hidden;cursor:pointer;
}
.wen-design-thumb img{width:100%;height:100%;object-fit:cover;border-radius:8px;display:block}
.wen-design-thumb span{
  position:absolute;left:6px;bottom:6px;padding:2px 6px;border-radius:999px;background:rgba(15,23,42,.78);color:#fff;
  font-size:8px;font-weight:900;line-height:1.2;
}
.wen-design-thumb.is-current{border-color:#2563eb;box-shadow:0 0 0 2px rgba(37,99,235,.14)}
.wen-design-thumb.is-current span{background:#2563eb}
.wen-design-gallery-empty{padding:14px;text-align:center;border:1px dashed #cbd8ea;border-radius:10px;color:#7b879b;font-size:10px}

@media(max-width:900px){
  html[data-ui-mode="mobile"] .wen-design-gallery{margin:8px 4px 12px;padding:9px;border-radius:13px}
  html[data-ui-mode="mobile"] .wen-design-gallery-head{align-items:stretch}
  html[data-ui-mode="mobile"] .wen-design-gallery-head .btn{min-height:38px;padding:8px 10px;font-size:10px}
  html[data-ui-mode="mobile"] .wen-design-thumb{flex-basis:72px;width:72px;height:72px}
}

html[data-visual-theme="studio"] .wen-mobile-global-search{
  background:rgba(7,17,31,.97)!important;border-color:rgba(148,163,184,.16)!important;
}
html[data-visual-theme="studio"] .wen-mobile-search-icon{background:#172a44!important;color:#62eee6!important}
html[data-visual-theme="studio"] #wenMobileGlobalSearchInput{background:#0b1728!important;color:#edf6ff!important;border-color:rgba(148,163,184,.20)!important}
html[data-visual-theme="studio"] #wenMobileGlobalSearchClear{background:#172a44!important;color:#cbd9e9!important}
html[data-visual-theme="studio"] .wen-design-gallery{background:#0d1a2d!important;border-color:rgba(148,163,184,.16)!important}
html[data-visual-theme="studio"] .wen-design-gallery-head strong{color:#eff6ff!important}
html[data-visual-theme="studio"] .wen-design-gallery-head small{color:#91a4bd!important}
html[data-visual-theme="studio"] .wen-design-thumb{background:#101e32!important;border-color:rgba(148,163,184,.18)!important}
html[data-visual-theme="studio"] .wen-design-gallery-empty{border-color:rgba(148,163,184,.22)!important;color:#91a4bd!important}

@media print{.wen-design-gallery{display:none!important}}

/* v73 — mobil arama alanı tema uyum düzeltmesi */
@media (max-width: 900px) {
  html[data-ui-mode="mobile"] #wenMobileGlobalSearch.wen-mobile-global-search {
    display: flex !important;
    flex-wrap: nowrap !important;
    align-items: center !important;
    gap: 10px !important;
    position: sticky !important;
    top: 0 !important;
    z-index: 16050 !important;
    margin: 0 10px 10px !important;
    padding: 10px !important;
    border-radius: 22px !important;
    border: 1px solid #d8e3f2 !important;
    background: linear-gradient(180deg, rgba(255,255,255,.98) 0%, rgba(246,250,255,.98) 100%) !important;
    box-shadow: 0 12px 28px rgba(15, 23, 42, .08) !important;
    backdrop-filter: blur(12px) !important;
    -webkit-backdrop-filter: blur(12px) !important;
  }

  html[data-ui-mode="mobile"] #wenMobileGlobalSearch .wen-mobile-search-icon {
    display: grid !important;
    place-items: center !important;
    width: 38px !important;
    min-width: 38px !important;
    height: 38px !important;
    border-radius: 14px !important;
    background: linear-gradient(135deg, #eff6ff, #e0f2fe) !important;
    color: #2563eb !important;
    font-size: 18px !important;
    line-height: 1 !important;
    box-shadow: inset 0 0 0 1px rgba(37, 99, 235, .10) !important;
  }

  html[data-ui-mode="mobile"] #wenMobileGlobalSearchInput {
    display: block !important;
    flex: 1 1 auto !important;
    min-width: 0 !important;
    width: auto !important;
    height: 46px !important;
    margin: 0 !important;
    padding: 0 14px !important;
    border: 1px solid #cfdced !important;
    border-radius: 15px !important;
    background: #ffffff !important;
    color: #10213f !important;
    font-size: 14px !important;
    font-weight: 700 !important;
    line-height: 1.2 !important;
    box-shadow: inset 0 1px 1px rgba(15, 23, 42, .02) !important;
    outline: none !important;
  }

  html[data-ui-mode="mobile"] #wenMobileGlobalSearchInput::placeholder {
    color: #6b7c93 !important;
    font-weight: 600 !important;
  }

  html[data-ui-mode="mobile"] #wenMobileGlobalSearchInput:focus {
    border-color: #4f7cff !important;
    box-shadow: 0 0 0 4px rgba(59, 130, 246, .14) !important;
  }

  html[data-ui-mode="mobile"] #wenMobileGlobalSearchClear {
    display: grid !important;
    place-items: center !important;
    flex: 0 0 38px !important;
    width: 38px !important;
    min-width: 38px !important;
    height: 38px !important;
    margin: 0 !important;
    padding: 0 !important;
    border: 1px solid #d8e3f0 !important;
    border-radius: 13px !important;
    background: #ffffff !important;
    color: #5f6f86 !important;
    font-size: 20px !important;
    font-weight: 900 !important;
    line-height: 1 !important;
    box-shadow: 0 6px 16px rgba(15, 23, 42, .05) !important;
  }

  html[data-ui-mode="mobile"] #wenMobileGlobalSearchClear:not(.is-visible) {
    visibility: hidden !important;
    opacity: 0 !important;
    pointer-events: none !important;
  }

  html[data-ui-mode="mobile"] #wenMobileGlobalSearchClear.is-visible {
    visibility: visible !important;
    opacity: 1 !important;
    pointer-events: auto !important;
  }

  html[data-ui-mode="mobile"] #wenMobileGlobalSearch + * {
    margin-top: 0 !important;
  }

  html[data-ui-mode="mobile"] .production-board-filters,
  html[data-ui-mode="mobile"] .kanban-filters,
  html[data-ui-mode="mobile"] .board-filters {
    margin: 0 10px 8px !important;
    padding: 6px 2px 0 !important;
  }

  html[data-ui-mode="mobile"] .production-board-filters .btn,
  html[data-ui-mode="mobile"] .kanban-filters .btn,
  html[data-ui-mode="mobile"] .board-filters .btn,
  html[data-ui-mode="mobile"] .production-board-filters button,
  html[data-ui-mode="mobile"] .kanban-filters button,
  html[data-ui-mode="mobile"] .board-filters button {
    min-height: 40px !important;
    border-radius: 14px !important;
    font-size: 12px !important;
    font-weight: 800 !important;
    padding: 9px 14px !important;
  }
}

html[data-visual-theme="studio"] #wenMobileGlobalSearch.wen-mobile-global-search {
  background: linear-gradient(180deg, rgba(9,19,34,.98) 0%, rgba(11,24,42,.98) 100%) !important;
  border-color: rgba(148, 163, 184, .16) !important;
  box-shadow: 0 16px 32px rgba(2, 8, 23, .38) !important;
}
html[data-visual-theme="studio"] #wenMobileGlobalSearch .wen-mobile-search-icon {
  background: linear-gradient(135deg, #122744, #17345a) !important;
  color: #66f1e9 !important;
  box-shadow: inset 0 0 0 1px rgba(102, 241, 233, .10) !important;
}
html[data-visual-theme="studio"] #wenMobileGlobalSearchInput {
  background: linear-gradient(180deg, #0c1930, #0b1728) !important;
  color: #eff6ff !important;
  border-color: rgba(148, 163, 184, .22) !important;
}
html[data-visual-theme="studio"] #wenMobileGlobalSearchInput::placeholder {
  color: #8fa4bf !important;
}
html[data-visual-theme="studio"] #wenMobileGlobalSearchClear {
  background: linear-gradient(180deg, #122744, #0e2037) !important;
  color: #d7e4f6 !important;
  border-color: rgba(148, 163, 184, .18) !important;
}

/* v95 Mobil Atölye aşama seçicisi: adlar kesilmeden bütün panolar görünür. */
@media (max-width: 900px) {
  html[data-ui-mode="mobile"] .v12-stage-tabs {
    display: grid !important;
    grid-template-columns: repeat(auto-fit, minmax(78px, 1fr)) !important;
    gap: 8px !important;
    width: 100% !important;
    max-width: 100% !important;
    margin: 0 0 10px !important;
    padding: 4px 0 8px !important;
    overflow: visible !important;
    scrollbar-width: none !important;
  }

  html[data-ui-mode="mobile"] .v12-stage-tabs::-webkit-scrollbar {
    display: none !important;
  }

  html[data-ui-mode="mobile"] .v12-stage-tab {
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    gap: 6px !important;
    flex: none !important;
    width: 100% !important;
    min-width: 0 !important;
    min-height: 48px !important;
    padding: 8px 6px !important;
    border-radius: 14px !important;
    white-space: normal !important;
    overflow: visible !important;
    text-align: center !important;
    text-overflow: clip !important;
    overflow-wrap: anywhere !important;
    font-size: 11px !important;
    line-height: 1.18 !important;
  }

  html[data-ui-mode="mobile"] .v12-stage-tab i {
    flex: 0 0 8px !important;
    width: 8px !important;
    height: 8px !important;
  }
}
