/* ==========================================================================
   WHERZIT ENVANTER YÖNETİMİ - ANA CSS TEMASI (v5.0.0 - Nexus Komuta Merkezi)
   ========================================================================== */

:root {
  /* Ana Tema Değişkenleri */
  --bg-color: #121212;
  --surface-color: #1e1e1e;
  --primary-color: #4caf50;
  --primary-hover: #45a049;
  --primary-glow: rgba(76, 175, 80, 0.35);
  --amber-color: #ffc107;
  --text-main: #f5f5f5;
  --text-muted: #b0b0b0;
  --border-color: #333333;
  --danger-color: #f44336;

  /* WherZit Kontrol Merkezi & Vurgu Değişkenleri */
  --wherzit-yellow: #f59e0b;
  --wherzit-yellow-glow: rgba(245, 158, 11, 0.4);
  --panel-bg: rgba(26, 34, 50, 0.95);
}

html {
  background-color: var(--bg-color);
  color: var(--text-main);
  font-family: system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

/* 🐛 FIX (mobilde boş alana dokununca mavi/şeffaf kutu çıkıyordu):
   Android Chrome/WebKit'in varsayılan dokunma vurgusu (tap-highlight)
   hiçbir yerde global olarak kapatılmamıştı — sadece birkaç münferit
   elementte (.menu-item.clickable, thermal-print.css içindekiler) vardı.
   Bu kural SADECE görseldir; hiçbir onclick/tıklama/kapama davranışını
   değiştirmez — dokunma anındaki mavimsi highlight rengini şeffaf yapar.
   Zaten var olan -webkit-tap-highlight-color:transparent kuralları
   (satır ~1585, ~3679, ~3697 ve thermal-print.css) buradan sonra hâlâ
   birebir aynı şekilde geçerli, çakışma yok — CSS'te aynı özelliğin daha
   spesifik/sonraki bir kuralı her zaman kazanır. */
* {
  -webkit-tap-highlight-color: transparent;
}

body {
  margin: 0;
  padding: 0;
  background-color: var(--bg-color);
  color: var(--text-main);
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  overflow-x: hidden;
}

/* ==========================================================================
   1. HEADER / ÜST BAR VE INSTAGRAM TARZI HAMBURGER MENÜ
   ========================================================================== */

header, .app-header {
  background-color: var(--surface-color);
  border-bottom: 1px solid var(--border-color);
  padding: 0.8rem 1rem;
  padding-top: calc(0.8rem + env(safe-area-inset-top));
  position: sticky;
  top: 0;
  z-index: 10;
  display: flex !important;
  justify-content: space-between !important;
  align-items: center !important;
}

.header-title {
  margin: 0;
  font-size: 1.5rem;
  font-weight: 800;
  letter-spacing: 2px;
  color: var(--primary-color);
  display: flex;
  align-items: center;
}

.version-tag {
  font-size: 0.75rem;
  color: var(--text-muted);
  font-weight: 400;
  letter-spacing: 0px;
  margin-left: 0.4rem;
  background-color: rgba(255, 255, 255, 0.05);
  padding: 0.2rem 0.5rem;
  border-radius: 4px;
  border: 1px solid var(--border-color);
}

.header-controls {
  display: flex;
  gap: 0.8rem;
  align-items: center;
}

/* --- Instagram Tarzı 3 Çizgili Hamburger Butonu --- */
.hamburger-trigger {
  background: transparent;
  border: none;
  cursor: pointer;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  width: 22px;
  height: 16px;
  padding: 0;
  z-index: 101;
}

.hamburger-trigger .bar {
  height: 2px;
  width: 100%;
  background-color: var(--text-main);
  border-radius: 2px;
  transition: all 0.3s ease;
}

.hamburger-trigger:hover .bar {
  background-color: var(--wherzit-yellow);
}

/* ==========================================================================
   2. ARAMA, FİLTRE VE KISAYOL ALANI
   ========================================================================== */

.search-and-shortcuts-container {
  background-color: var(--surface-color);
  border: 1px solid var(--border-color);
  border-radius: 12px;
  padding: 1rem;
  margin: 0.8rem 1rem 0.5rem 1rem;
  box-shadow: 0 4px 15px rgba(0,0,0,0.4);
}

.search-bar-row {
  display: flex;
  gap: 0.8rem;
  align-items: center;
}

.search-input-wrapper {
  position: relative;
  flex: 1;
  display: flex;
  align-items: center;
}

.search-icon {
  position: absolute;
  left: 12px;
  font-size: 1rem;
  opacity: 0.6;
  pointer-events: none;
}

.search-input-wrapper input {
  width: 100%;
  padding: 0.8rem 2.2rem 0.8rem 2.2rem;
  background-color: var(--bg-color);
  border: 1px solid var(--border-color);
  color: var(--text-main);
  border-radius: 8px;
  box-sizing: border-box;
  font-size: 0.95rem;
  transition: border-color 0.2s ease;
}

.search-input-wrapper input:focus {
  outline: none;
  border-color: var(--primary-color);
}

.clear-search-btn {
  position: absolute;
  right: 10px;
  background: none;
  border: none;
  color: var(--danger-color);
  font-size: 1.1rem;
  font-weight: bold;
  cursor: pointer;
  padding: 0 4px;
  z-index: 5;
  transition: transform 0.1s, color 0.1s;
}

.clear-search-btn:hover {
  color: #ff6b6b;
  transform: scale(1.15);
}

.search-suggestions {
  position: absolute;
  top: calc(100% + 6px);
  left: 0;
  width: 100%;
  background-color: var(--surface-color);
  border: 1px solid var(--border-color);
  border-radius: 8px;
  box-shadow: 0 8px 24px rgba(0,0,0,0.6);
  display: none;
  z-index: 100;
  overflow: hidden;
  animation: fadeIn 0.2s ease-out;
}

.search-suggestions.active { display: block; }

.suggestion-header {
  padding: 0.6rem 0.8rem;
  font-size: 0.75rem;
  text-transform: uppercase;
  letter-spacing: 1px;
  color: var(--text-muted);
  background-color: rgba(255,255,255,0.02);
  border-bottom: 1px solid var(--border-color);
}

.suggestion-item {
  padding: 0.7rem 0.8rem;
  cursor: pointer;
  display: flex;
  justify-content: space-between;
  align-items: center;
  border-bottom: 1px solid rgba(255,255,255,0.03);
  transition: background 0.15s;
  font-size: 0.9rem;
}

.suggestion-item:last-child { border-bottom: none; }
.suggestion-item:hover {
  background-color: rgba(76, 175, 80, 0.1);
  color: var(--primary-color);
}

.suggestion-meta { font-size: 0.75rem; color: var(--text-muted); }

.filter-toggle-btn {
  position: relative;
  background-color: rgba(255, 255, 255, 0.05);
  border: 1px solid var(--border-color);
  color: var(--text-main);
  padding: 0.8rem 1rem;
  border-radius: 8px;
  font-size: 0.9rem;
  cursor: pointer;
  display: flex;
  align-items: center;
  gap: 0.4rem;
  white-space: nowrap;
  transition: all 0.2s ease;
}

.filter-toggle-btn:hover, .filter-toggle-btn.active {
  border-color: var(--primary-color);
  background-color: rgba(76, 175, 80, 0.15);
  color: var(--primary-color);
}

.filter-badge {
    background-color: var(--primary-color);
    color: #ffffff;
    font-size: 0.7rem;
    font-weight: bold;
    padding: 2px 6px;
    border-radius: 10px;
    margin-left: 2px;
}

.quick-filters-bar {
  display: flex;
  gap: 0.6rem;
  margin-top: 0.8rem;
  padding-top: 0.8rem;
  border-top: 1px solid var(--border-color);
  overflow-x: auto;
  scrollbar-width: none;
}

.quick-filters-bar::-webkit-scrollbar { display: none; }

.q-filter-chip {
  background-color: var(--bg-color);
  border: 1px solid var(--border-color);
  color: var(--text-muted);
  padding: 0.5rem 0.9rem;
  border-radius: 20px;
  font-size: 0.82rem;
  cursor: pointer;
  white-space: nowrap;
  transition: all 0.2s ease;
}

.q-filter-chip:hover {
  border-color: var(--primary-color);
  color: var(--text-main);
}

.q-filter-chip.active {
  background-color: var(--primary-color);
  color: #ffffff;
  border-color: var(--primary-color);
  font-weight: 600;
}

.shortcuts-wrapper {
  margin-top: 0.8rem;
  padding-top: 0.8rem;
  border-top: 1px dashed var(--border-color);
}

.shortcuts-header {
  display: flex;
  align-items: center;
  margin-bottom: 8px;
  white-space: nowrap;
  overflow: hidden;
}

.shortcuts-title-green {
  font-size: 0.92rem;
  font-weight: 800;
  color: var(--primary-color);
  letter-spacing: 0.5px;
  text-transform: uppercase;
}

.shortcuts-scroll-area {
  display: flex;
  gap: 0.6rem;
  overflow-x: auto;
  padding-bottom: 4px;
  scrollbar-width: none;
}

.shortcuts-scroll-area::-webkit-scrollbar { display: none; }

.shortcut-chip {
  display: flex;
  align-items: center;
  gap: 0.6rem;
  background-color: var(--bg-color);
  border: 1px solid var(--border-color);
  padding: 0.5rem 0.8rem;
  border-radius: 10px;
  cursor: pointer;
  white-space: nowrap;
  flex-shrink: 0;
  transition: transform 0.15s ease, border-color 0.2s ease;
}

.shortcut-chip:hover {
  transform: translateY(-1px);
  border-color: var(--primary-color);
}

.shortcut-chip.pinned {
  border-color: var(--amber-color);
  background-color: rgba(255, 193, 7, 0.08);
}

.shortcut-icon { font-size: 1.1rem; }
.shortcut-info { display: flex; flex-direction: column; }
.shortcut-name { font-size: 0.83rem; font-weight: 600; color: var(--text-main); }
.shortcut-loc { font-size: 0.7rem; color: var(--text-muted); }

.shortcut-pin-btn {
  background: transparent;
  border: none;
  cursor: pointer;
  font-size: 0.8rem;
  opacity: 0.5;
  padding: 2px;
  transition: opacity 0.2s;
}

.shortcut-pin-btn:hover, .shortcut-chip.pinned .shortcut-pin-btn { opacity: 1; }

.filter-trigger-btn {
  background-color: rgba(255, 255, 255, 0.05);
  border: 1px solid var(--border-color);
  color: var(--text-main);
  padding: 0.8rem 1rem;
  border-radius: 6px;
  font-size: 0.95rem;
  cursor: pointer;
  display: flex;
  align-items: center;
  gap: 0.5rem;
  white-space: nowrap;
  transition: all 0.2s;
}

.filter-trigger-btn:hover {
  border-color: var(--primary-color);
  background-color: rgba(76, 175, 80, 0.1);
}

/* ==========================================================================
   3. ANA İÇERİK, LOKASYONLAR VE KARTLAR
   ========================================================================== */

main {
  flex: 1;
  padding: 1rem;
  padding-bottom: 120px;
}

.location-section {
  margin-bottom: 2rem;
  background-color: rgba(30, 30, 30, 0.5);
  border: 1px solid var(--border-color);
  border-radius: 8px;
  padding: 1rem;
}

.location-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  border-bottom: 1px solid var(--border-color);
  padding-bottom: 0.5rem;
  margin-bottom: 1rem;
}

.location-title {
  margin: 0;
  font-size: 1.2rem;
  color: var(--text-main);
  text-transform: uppercase;
  display: flex;
  align-items: center;
  gap: 0.5rem;
  cursor: pointer;
  padding: 0.2rem 0.4rem;
  border-radius: 4px;
  transition: background 0.15s;
}

.location-title:hover {
  background-color: rgba(255, 255, 255, 0.05);
  color: var(--primary-color);
}

.sub-location-title {
  margin: 1.2rem 0 0.8rem 0;
  font-size: 1rem;
  color: var(--primary-color);
  border-bottom: 1px dashed var(--border-color);
  padding-bottom: 0.3rem;
  letter-spacing: 1px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.4rem;
  cursor: pointer;
  padding: 0.2rem 0.4rem;
  border-radius: 4px;
  transition: background 0.15s;
}

.sub-location-title:hover { background-color: rgba(76, 175, 80, 0.1); }
.sub-location-title:first-child { margin-top: 0; }

.drawer-title {
  margin: 0.8rem 0 0.5rem 1rem;
  font-size: 0.9rem;
  color: var(--text-muted);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.4rem;
  cursor: pointer;
  padding: 0.2rem 0.4rem;
  border-radius: 4px;
  transition: background 0.15s;
}

.drawer-title:hover {
  background-color: rgba(255, 255, 255, 0.05);
  color: var(--text-main);
}

.delete-btn {
  background: transparent !important;
  border: none !important;
  outline: none !important;
  color: var(--danger-color);
  cursor: pointer;
  font-size: 1.2rem;
  padding: 0 0.5rem;
  box-shadow: none !important;
}

/* --- Kart Çevirme (Flip) Efekti --- */
.card-flip-container {
  perspective: 1000px;
  margin-bottom: 1rem;
  margin-left: 1rem;
}

.card-flip-inner {
  position: relative;
  width: 100%;
  transition: transform 0.6s cubic-bezier(0.4, 0.2, 0.2, 1);
  transform-style: preserve-3d;
}

.card-flip-inner.flipped { transform: rotateY(180deg); min-height: 130px; }

.item-card-front, .item-card-back {
  background-color: var(--surface-color);
  border-left: 4px solid var(--primary-color);
  border-radius: 4px;
  padding: 1rem;
  box-shadow: 0 2px 4px rgba(0,0,0,0.2);
  backface-visibility: hidden;
  -webkit-backface-visibility: hidden;
  position: relative;
}

.item-card-back {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  box-sizing: border-box;
  transform: rotateY(180deg);
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  overflow: hidden;
}

.card-flip-container.recently-moved .item-card-front,
.card-flip-container.recently-moved .item-card-back { border-left-color: var(--amber-color); }

.card-flip-container.stock-warning .item-card-front,
.card-flip-container.stock-warning .item-card-back { border-left-color: var(--amber-color); }

.card-flip-container.stock-empty .item-card-front,
.card-flip-container.stock-empty .item-card-back { border-left-color: var(--danger-color); opacity: 0.85; }

.item-header {
  display: flex;
  justify-content: space-between;
  font-weight: bold;
  font-size: 1.1rem;
  margin-bottom: 0.5rem;
  padding-right: 5.5rem;
}

.item-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 0.8rem;
  font-size: 0.85rem;
  color: var(--text-muted);
  margin-bottom: 0.5rem;
  align-items: center;
}

.badge {
  background-color: #333;
  padding: 0.2rem 0.5rem;
  border-radius: 4px;
  color: var(--primary-color);
  border: 1px solid #444;
  cursor: pointer;
  transition: background 0.2s;
}

.badge:hover { background-color: #444; color: #fff; }

.badge-moved {
  background-color: rgba(255, 179, 0, 0.15);
  color: var(--amber-color);
  border-color: rgba(255, 179, 0, 0.3);
  cursor: default;
}

.badge-stock-warning {
  background-color: rgba(255, 193, 7, 0.15);
  color: var(--amber-color);
  border-color: rgba(255, 193, 7, 0.4);
  cursor: default;
}

.badge-stock-empty {
  background-color: rgba(244, 67, 54, 0.15);
  color: var(--danger-color);
  border-color: rgba(244, 67, 54, 0.4);
  cursor: default;
}

.qty-control {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  background-color: rgba(255, 255, 255, 0.05);
  padding: 0.2rem 0.4rem;
  border-radius: 6px;
  border: 1px solid var(--border-color);
}

.qty-label { font-size: 0.8rem; color: var(--text-muted); margin-right: 0.2rem; }

.qty-btn {
  background: rgba(76, 175, 80, 0.1);
  border: 1px solid rgba(76, 175, 80, 0.3);
  color: var(--primary-color);
  border-radius: 4px;
  font-size: 1.1rem;
  font-weight: bold;
  cursor: pointer;
  width: 26px;
  height: 26px;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.1s;
}

.qty-btn:hover { background: rgba(76, 175, 80, 0.2); }
.qty-btn:active { transform: scale(0.9); background: var(--primary-color); color: #fff; }

.qty-val {
  font-weight: bold;
  color: var(--text-main);
  min-width: 1.5rem;
  text-align: center;
  font-size: 0.95rem;
  cursor: pointer;
  padding: 0.1rem 0.3rem;
  border-radius: 4px;
  transition: background 0.15s;
}

.qty-val:hover { background-color: rgba(76, 175, 80, 0.2); color: var(--primary-color); }

.item-notes {
  font-size: 0.9rem;
  background-color: rgba(0,0,0,0.2);
  padding: 0.5rem;
  border-radius: 4px;
  color: var(--text-muted);
  white-space: pre-wrap;
}

.item-actions {
  position: absolute;
  top: 1rem;
  right: 1rem;
  display: flex;
  gap: 0.6rem;
  align-items: center;
}

.back-media-grid {
  display: flex;
  gap: 0.8rem;
  align-items: center;
  height: 100%;
}

.back-photo-box {
  flex: 1;
  height: 90px;
  background-color: rgba(0,0,0,0.4);
  border: 1px solid var(--border-color);
  border-radius: 6px;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
  cursor: pointer;
}

.back-photo-box img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.2s;
}

.back-photo-box img:hover { transform: scale(1.08); }

.back-qr-box {
  flex: 1;
  height: 90px;
  background-color: rgba(255,255,255,0.02);
  border: 1px dashed var(--border-color);
  border-radius: 6px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  color: var(--text-muted);
  font-size: 0.75rem;
  text-align: center;
  padding: 0.3rem;
}

.flip-back-btn {
  background: rgba(255, 255, 255, 0.06);
  backdrop-filter: blur(6px);
  -webkit-backdrop-filter: blur(6px);
  border: 1px solid var(--border-color);
  color: var(--text-main);
  padding: 0.32rem 0.75rem;
  border-radius: 999px;
  font-size: 0.76rem;
  font-weight: 600;
  letter-spacing: 0.2px;
  cursor: pointer;
  display: flex;
  align-items: center;
  gap: 0.35rem;
  transition: background 0.2s ease, border-color 0.2s ease, color 0.2s ease, transform 0.15s ease;
}

.flip-back-btn:hover {
  border-color: var(--primary-color);
  color: var(--primary-color);
  background: rgba(56, 189, 248, 0.12);
}

.flip-back-btn:active { transform: scale(0.94); }

/* ==========================================================================
   4. BUTON ÇERÇEVELERİ, TAŞIMA MODU VE BİLGİSAYAR EKRANI DÜZELTMELERİ
   ========================================================================== */

/* --- Kamera, Galeri ve Emanet Ver Buton Çerçeveleri --- */
.btn-camera, .btn-gallery, .btn-emanet, 
button[onclick*="camera"], button[onclick*="gallery"], button[onclick*="emanet"] {
  border: 1px solid var(--border-color) !important;
  background: rgba(255, 255, 255, 0.06) !important;
  border-radius: 8px !important;
  padding: 6px 12px !important;
  color: var(--text-main) !important;
  transition: all 0.2s ease !important;
}

.btn-camera:hover, .btn-gallery:hover, .btn-emanet:hover {
  background: rgba(255, 255, 255, 0.15) !important;
  border-color: var(--primary-color) !important;
}

/* --- Taşıma Modu Mantığı: Varsayılanda Taşı Butonlarını Gizle --- */
.btn-move, [data-action="move"], .card-move-btn {
  display: none !important;
}

/* Sadece Taşıma Modu (Sarı Çerçeve) Açıkken "Taşı" Butonlarını Göster */
body.bulk-move-active .btn-move,
body.bulk-move-active [data-action="move"],
body.bulk-move-active .card-move-btn {
  display: inline-flex !important;
}

/* --- PC Ekranlarında Uzayan "Teslim Al" Butonu Düzeltmesi --- */
.emanet-card-header, .emanet-person-header, .emanet-header {
  display: flex !important;
  align-items: center !important;
  justify-content: space-between !important;
  gap: 12px !important;
}

.emanet-card-header button, 
.emanet-person-header button,
.btn-teslim, .btn-teslim-al {
  width: auto !important;
  max-width: fit-content !important;
  white-space: nowrap !important;
  flex-shrink: 0 !important;
  padding: 6px 14px !important;
}

/* Alt Lokasyon Kibar Taşı Butonu */
.btn-bulk-move-trigger {
  background: rgba(56, 189, 248, 0.1);
  border: 1px solid rgba(56, 189, 248, 0.25);
  color: #38bdf8;
  padding: 3px 8px;
  border-radius: 6px;
  font-size: 0.72rem;
  font-weight: 600;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 4px;
  transition: all 0.2s ease;
  white-space: nowrap;
}

.btn-bulk-move-trigger:hover {
  background: rgba(56, 189, 248, 0.22);
  border-color: #38bdf8;
  transform: translateY(-1px);
  box-shadow: 0 2px 8px rgba(56, 189, 248, 0.2);
}

.btn-bulk-move-trigger:active { transform: scale(0.95); }

/* Yeni Modern QR Sepete Ekle Butonu & Tooltip Tasarımı (v1.8.1) */
.btn-qr-add-cart {
  background: rgba(56, 189, 248, 0.1);
  border: 1px solid rgba(56, 189, 248, 0.25);
  color: #38bdf8;
  padding: 4px 10px;
  border-radius: 6px;
  font-size: 0.75rem;
  font-weight: 600;
  cursor: pointer;
  display: none; /* Sadece QR Modülü aktifken JS ile inline-flex yapılır */
  align-items: center;
  gap: 6px;
  transition: all 0.2s ease;
  white-space: nowrap;
}

.btn-qr-add-cart:hover {
  background: rgba(56, 189, 248, 0.22);
  border-color: #38bdf8;
  transform: translateY(-1px);
  box-shadow: 0 2px 8px rgba(56, 189, 248, 0.2);
}

.btn-qr-add-cart:active { transform: scale(0.95); }

/* QR Modülü Şalteri Açıkken Butonu Göster */
body.qr-module-active .btn-qr-add-cart {
  display: inline-flex !important;
}

/* Tooltip (Bilgi İkonu) Sarmalayıcı */
.wz-tooltip-wrapper {
  position: relative;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  margin-left: 2px;
}

.wz-tooltip-icon {
  width: 15px;
  height: 15px;
  border-radius: 50%;
  background: rgba(56, 189, 248, 0.2);
  color: #38bdf8;
  font-size: 10px;
  font-weight: bold;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  cursor: help;
  transition: background 0.2s, transform 0.2s;
}

.wz-tooltip-icon:hover {
  background: #38bdf8;
  color: #0f172a;
  transform: scale(1.1);
}

/* Tooltip Balonu (Glassmorphism & Temiz Konumlandırma) */
.wz-tooltip-content {
  position: absolute;
  bottom: calc(100% + 8px);
  right: 0;
  width: 260px;
  background: rgba(15, 23, 42, 0.95);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  border: 1px solid rgba(56, 189, 248, 0.3);
  color: #f8fafc;
  padding: 10px 12px;
  border-radius: 8px;
  font-size: 0.75rem;
  font-weight: normal;
  line-height: 1.4;
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.6);
  z-index: 9999;
  opacity: 0;
  visibility: hidden;
  transform: translateY(4px);
  transition: opacity 0.2s ease, transform 0.2s ease, visibility 0.2s;
  pointer-events: none;
  text-align: left;
}

.wz-tooltip-wrapper:hover .wz-tooltip-content {
  opacity: 1;
  visibility: visible;
  transform: translateY(0);
}

.wz-tooltip-content ul {
  margin: 0;
  padding-left: 15px;
}

.wz-tooltip-content li {
  margin-bottom: 3px;
}

.wz-tooltip-content li:last-child {
  margin-bottom: 0;
}

.wz-tooltip-note {
  margin-top: 6px;
  color: #38bdf8;
  font-style: italic;
  font-size: 0.7rem;
  border-top: 1px solid rgba(255, 255, 255, 0.08);
  padding-top: 4px;
}

/* ==========================================================================
   5. BİLDİRİMLER, MODALLAR VE SEÇİCİLER
   ========================================================================== */

.fab {
  position: fixed;
  bottom: 2rem;
  right: 2rem;
  background-color: var(--primary-color);
  color: white;
  width: 60px;
  height: 60px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 2rem;
  box-shadow: 0 4px 15px rgba(76, 175, 80, 0.4);
  cursor: pointer;
  border: none;
  z-index: 100;
  transition: transform 0.2s, background-color 0.2s;
}

.fab:active { transform: scale(0.95); }

/* ═══════════════════════════════════════════════════════════════════
   WherZit — Bildirim (Toast) Sistemi v2
   Cam kart + marka gradyanı (teal → turuncu). Sınıf adları (.toast,
   .toast.show, #toast-container) BİLEREK korundu: dışarıdaki hiçbir
   seçici/kod kırılmasın diye. Konum: sağ üst (mobilde üst-tam genişlik).
   ═══════════════════════════════════════════════════════════════════ */

:root {
  --wz-toast-success: #10b981;
  --wz-toast-danger:  #ef4444;
  --wz-toast-warning: #f59e0b;
  --wz-toast-info:    #14b8a6;
  --wz-brand-teal:    #14b8a6;
  --wz-brand-orange:  #f97316;
}

#toast-container {
  position: fixed;
  top: calc(16px + env(safe-area-inset-top, 0px));
  right: 16px;
  /* 🛡️ Projede z-index 999999 kullanan başka katmanlar da var (modallar).
     Eşit değerde DOM sırası belirleyici olduğu için bildirimleri en üste
     sabitliyoruz — bir modal açıkken çıkan doğrulama bildirimleri asla
     arkada kalmasın. */
  z-index: 2147483000;
  display: flex;
  flex-direction: column;
  gap: 10px;
  width: 340px;
  max-width: calc(100vw - 32px);
  box-sizing: border-box; /* 🐛 FIX: projede global box-sizing kuralı yok */
  pointer-events: none; /* boş alan tıklamayı engellemesin */
}

.toast {
  position: relative;
  display: flex;
  align-items: flex-start;
  gap: 10px;
  padding: 12px 10px 13px 16px;
  box-sizing: border-box; /* 🐛 FIX: projede global box-sizing kuralı yok */
  border-radius: 14px;
  background: rgba(24, 28, 34, 0.86);
  -webkit-backdrop-filter: blur(18px) saturate(140%);
  backdrop-filter: blur(18px) saturate(140%);
  border: 1px solid rgba(255, 255, 255, 0.10);
  box-shadow: 0 12px 32px rgba(0, 0, 0, 0.45),
              inset 0 1px 0 rgba(255, 255, 255, 0.06);
  color: #f5f5f5;
  font-size: 0.875rem;
  font-weight: 500;
  line-height: 1.4;
  overflow: hidden;
  pointer-events: auto;
  cursor: default;
  touch-action: pan-y;
  opacity: 0;
  transform: translateX(28px) scale(0.97);
  transition: opacity 0.28s ease, transform 0.28s cubic-bezier(0.22, 1, 0.36, 1);
}

.toast.show { opacity: 1; transform: translateX(0) scale(1); }
.toast.wz-out { opacity: 0; transform: translateX(28px) scale(0.96); }

/* Sol kenar tip şeridi */
.toast::before {
  content: '';
  position: absolute;
  left: 0; top: 0; bottom: 0;
  width: 3px;
  background: var(--wz-toast-success);
}
.toast.success::before { background: var(--wz-toast-success); }
.toast.danger::before  { background: var(--wz-toast-danger); }
.toast.warning::before { background: var(--wz-toast-warning); }
.toast.info::before    { background: linear-gradient(180deg, var(--wz-brand-teal), var(--wz-brand-orange)); }

.wz-toast-ico {
  flex: 0 0 20px;
  width: 20px; height: 20px;
  margin-top: 1px;
  border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  font-size: 0.72rem;
  font-weight: 700;
  color: #fff;
  background: var(--wz-toast-success);
}
.toast.danger  .wz-toast-ico { background: var(--wz-toast-danger); }
.toast.warning .wz-toast-ico { background: var(--wz-toast-warning); color: #1a1a1a; }
.toast.info    .wz-toast-ico { background: linear-gradient(135deg, var(--wz-brand-teal), var(--wz-brand-orange)); }

.wz-toast-msg {
  flex: 1 1 auto;
  min-width: 0;
  word-break: break-word;
  padding-top: 1px;
}

/* Aynı mesaj tekrarlanınca "×2" rozeti */
.wz-toast-count {
  flex: 0 0 auto;
  align-self: center;
  font-size: 0.72rem;
  font-weight: 700;
  padding: 2px 7px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.14);
  color: #fff;
}

.wz-toast-x {
  flex: 0 0 auto;
  width: 24px; height: 24px;
  margin: -2px 0 0 0;
  padding: 0;
  border: 0;
  border-radius: 8px;
  background: transparent;
  color: rgba(255, 255, 255, 0.45);
  font-size: 15px;
  line-height: 1;
  cursor: pointer;
  transition: background 0.15s, color 0.15s;
}
.wz-toast-x:hover  { background: rgba(255, 255, 255, 0.10); color: #fff; }
.wz-toast-x:active { transform: scale(0.9); }

/* Aksiyon butonu (ör. "Geri Al") */
.wz-toast-action {
  flex: 0 0 auto;
  align-self: center;
  margin-right: 2px;
  padding: 5px 12px;
  border: 0;
  border-radius: 999px;
  background: linear-gradient(135deg, #0d9488, #14b8a6);
  color: #fff;
  font-size: 0.76rem;
  font-weight: 700;
  cursor: pointer;
  white-space: nowrap;
}
.wz-toast-action:active { transform: scale(0.95); }

/* Alt süre şeridi — dolarken tükenir, üzerine gelince duraklar */
.wz-toast-bar {
  position: absolute;
  left: 0; right: 0; bottom: 0;
  height: 2px;
  background: rgba(255, 255, 255, 0.07);
  overflow: hidden;
}
.wz-toast-bar > i {
  display: block;
  height: 100%;
  width: 100%;
  transform-origin: left center;
  background: linear-gradient(90deg, var(--wz-brand-teal), var(--wz-brand-orange));
  animation-name: wzToastBar;
  animation-timing-function: linear;
  animation-fill-mode: forwards;
}
@keyframes wzToastBar { from { transform: scaleX(1); } to { transform: scaleX(0); } }

/* Fare üzerindeyken / parmak basılıyken geri sayım durur */
.toast:hover   .wz-toast-bar > i,
.toast.wz-hold .wz-toast-bar > i { animation-play-state: paused; }

/* Kaydırarak kapatma sırasında geçiş kapalı olsun ki parmağı takip etsin */
.toast.wz-drag { transition: none; }

@media (max-width: 640px) {
  #toast-container {
    left: 12px;
    right: 12px;
    width: auto;
    max-width: none;
  }
  .toast { font-size: 0.84rem; }
}

@media (prefers-reduced-motion: reduce) {
  .toast { transition: opacity 0.01s linear; transform: none !important; }
  .toast.show, .toast.wz-out { transform: none !important; }
}

.modal-overlay {
  position: fixed;
  top: 0; left: 0; width: 100%; height: 100%;
  background-color: rgba(0, 0, 0, 0.6);
  backdrop-filter: blur(6px);
  -webkit-backdrop-filter: blur(6px);
  display: none;
  align-items: center;
  justify-content: center;
  z-index: 1000;
  opacity: 0;
  transition: opacity 0.3s ease;
  user-select: none;
  -webkit-user-select: none;
  -webkit-touch-callout: none;
}

.modal-overlay.active { display: flex; opacity: 1; }

.modal-content {
  background-color: var(--surface-color);
  padding: 1.5rem;
  border-radius: 12px;
  width: 90%;
  max-width: 420px;
  box-shadow: 0 10px 30px rgba(0,0,0,0.7);
  max-height: 90vh;
  overflow-y: auto;
  border: 1px solid var(--border-color);
  user-select: auto;
  -webkit-user-select: auto;
}

.modal-title {
  margin-top: 0;
  border-bottom: 1px solid var(--border-color);
  padding-bottom: 0.8rem;
  margin-bottom: 1.2rem;
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.form-row { display: flex; gap: 0.8rem; margin-bottom: 1rem; }
.form-group { margin-bottom: 1rem; flex: 1; }
.form-row .form-group { margin-bottom: 0; }

.form-group label {
  display: block;
  margin-bottom: 0.4rem;
  font-size: 0.85rem;
  color: var(--text-muted);
}

.form-control {
  width: 100%;
  padding: 0.8rem;
  background-color: var(--bg-color) !important;
  border: 1px solid var(--border-color);
  color: var(--text-main) !important;
  border-radius: 6px;
  box-sizing: border-box;
  font-family: inherit;
  transition: opacity 0.2s, border-color 0.2s;
}

.form-control:focus { outline: none; border-color: var(--primary-color); }

.form-control:disabled {
  opacity: 0.3;
  cursor: not-allowed;
  border-color: #2a2a2a;
}

textarea.form-control { resize: vertical; min-height: 80px; }

select.form-control option {
  background-color: var(--surface-color);
  color: var(--text-main);
}

.picker-trigger { cursor: pointer; caret-color: transparent; }

.checkbox-label {
  display: flex;
  align-items: center;
  gap: 0.6rem;
  cursor: pointer;
  color: var(--text-main);
  font-weight: 600;
  font-size: 0.9rem;
  background-color: rgba(255, 255, 255, 0.03);
  padding: 0.6rem 0.8rem;
  border-radius: 6px;
  border: 1px solid var(--border-color);
  user-select: none;
}

.checkbox-label input[type="checkbox"] {
  width: 18px;
  height: 18px;
  accent-color: var(--primary-color);
  cursor: pointer;
}

.modal-actions {
  display: flex;
  justify-content: flex-end;
  gap: 0.8rem;
  margin-top: 1.5rem;
}

.btn {
  padding: 0.8rem 1.2rem;
  border: none;
  border-radius: 6px;
  cursor: pointer;
  font-weight: bold;
  font-family: inherit;
  font-size: 0.9rem;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.4rem;
}

.btn-cancel {
  background-color: transparent;
  color: var(--text-muted);
  border: 1px solid var(--border-color);
}

.btn-save { background-color: var(--primary-color); color: white; }

.btn-outline {
  background-color: transparent;
  color: var(--text-main);
  border: 1px solid var(--border-color);
}

.btn-outline:hover {
  border-color: var(--primary-color);
  color: var(--primary-color);
}

.empty-state { text-align: center; color: var(--text-muted); padding: 2rem; font-style: italic; }

/* Custom Picker */
.custom-picker-overlay {
  position: fixed;
  top: 0; left: 0; width: 100%; height: 100%;
  background-color: rgba(0, 0, 0, 0.75);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  display: none;
  align-items: center;
  justify-content: center;
  z-index: 2000;
  cursor: pointer; /* iOS Safari'de arka plana dokunmanın güvenilir algılanması için */
  /* 🎯 user-select:none olmadan, boş alana (backdrop) yapılan hızlı/çift
     dokunuşlar bazı tarayıcılarda (özellikle iOS Safari) tıklama yerine
     metin seçimi olarak algılanıyor ve az önce Ana/Alt Lokasyon
     pencerelerinde bahsedilen mavi "çoklu seçim" highlight'ı beliriyordu.
     Bu satır, o alanda seçim başlamasını tamamen engelliyor. */
  user-select: none;
  -webkit-user-select: none;
  -webkit-touch-callout: none;
}

.custom-picker-overlay.active { display: flex; }

.custom-picker-content {
  background-color: var(--surface-color);
  width: 90%;
  max-width: 420px;
  border: 1px solid var(--border-color);
  border-top: 3px solid var(--primary-color);
  border-radius: 12px;
  padding: 1.5rem;
  box-shadow: 0 10px 40px rgba(0,0,0,0.9);
  max-height: 80vh;
  display: flex;
  flex-direction: column;
  cursor: default;
  /* Overlay'den miras alınan user-select:none, pencere içindeki normal
     metin/form etkileşimini bozmasın diye burada geri açılıyor. */
  user-select: auto;
  -webkit-user-select: auto;
}

@media (max-width: 600px) {
  .custom-picker-overlay { align-items: flex-end; }
  .custom-picker-content { width: 100%; border-radius: 16px 16px 0 0; }
}

.picker-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 1rem;
  border-bottom: 1px solid var(--border-color);
  padding-bottom: 0.5rem;
}

.picker-header h3 { margin: 0; color: var(--text-main); font-size: 1.1rem; }
.picker-close { background: none; border: none; color: var(--text-muted); font-size: 1.5rem; cursor: pointer; }

.picker-add-btn {
  width: 100%;
  padding: 0.9rem;
  background-color: rgba(76, 175, 80, 0.1);
  color: var(--primary-color);
  border: 1px dashed var(--primary-color);
  border-radius: 8px;
  font-weight: bold;
  cursor: pointer;
  margin-bottom: 1rem;
  font-size: 1rem;
}

.picker-input-group { display: none; margin-bottom: 1rem; gap: 0.5rem; }
.picker-input-group.active { display: flex; }

.picker-list {
  overflow-y: auto;
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}

.picker-item-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  background-color: rgba(255,255,255,0.05);
  border-radius: 8px;
  padding: 0.8rem 1rem;
  border: 1px solid transparent;
}

.picker-item-text {
  flex: 1;
  cursor: pointer;
  font-weight: 500;
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.picker-item-actions { display: flex; gap: 0.8rem; }

.picker-action-delete {
  background: transparent !important;
  border: none !important;
  color: var(--danger-color);
  cursor: pointer;
  font-size: 1.1rem;
  padding: 0.2rem 0.4rem;
}

.filter-group-title {
  font-size: 0.85rem;
  color: var(--text-muted);
  text-transform: uppercase;
  margin: 1rem 0 0.5rem 0;
  letter-spacing: 1px;
}

/* 🎯 SOL ORTA DOCK KAPSAYICI & MİLİMETRİK HİZALAMA */
#wz-quick-dock {
  position: fixed !important;
  left: 15px !important;
  top: 50% !important;
  transform: translateY(-50%) !important;
  display: flex !important;
  flex-direction: column !important;
  align-items: center !important;
  gap: 16px !important;
  z-index: 99999 !important;
  margin: 0 !important;
  padding: 0 !important;
}

#wz-quick-dock .dock-btn {
  position: relative !important;
  top: auto !important;
  left: auto !important;
  right: auto !important;
  bottom: auto !important;
  width: 48px !important;
  height: 48px !important;
  min-width: 48px !important;
  max-width: 48px !important;
  border-radius: 50% !important;
  display: flex !important;
  align-items: center !important;
  justify-content: center !important;
  cursor: pointer !important;
  border: 1px solid rgba(255, 255, 255, 0.25) !important;
  box-shadow: 0 4px 15px rgba(0,0,0,0.4) !important;
  margin: 0 !important;
  padding: 0 !important;
  box-sizing: border-box !important;
}

#wz-quick-dock .dock-btn.hidden {
  display: none !important;
}

/* Emanet Alarm Butonu İç Stili */
.lent-alert-btn {
  background: linear-gradient(135deg, #ff9800, #f44336) !important;
  color: #ffffff !important;
}

.alarm-icon-wrapper {
  display: flex !important;
  align-items: center !important;
  justify-content: center !important;
  animation: alarm-shake 1.5s infinite ease-in-out;
}

@keyframes alarm-shake {
  0% { transform: rotate(0deg); }
  10% { transform: rotate(15deg); }
  20% { transform: rotate(-15deg); }
  30% { transform: rotate(12deg); }
  40% { transform: rotate(-12deg); }
  50% { transform: rotate(6deg); }
  60% { transform: rotate(-6deg); }
  70% { transform: rotate(0deg); }
  100% { transform: rotate(0deg); }
}

/* 📌 TÜM BALONLAR İÇİN SOL ÜST KÖŞE NİZAMÎ BİLDİRİM ROZETİ */
.pulse-badge-count,
.lent-alert-badge,
.qr-cart-badge,
.skt-alert-badge {
  position: absolute !important;
  top: -4px !important;
  left: -4px !important;
  right: auto !important;
  background: #ef4444 !important;
  color: #ffffff !important;
  font-size: 11px !important;
  font-weight: 800 !important;
  width: 20px !important;
  height: 20px !important;
  border-radius: 50% !important;
  display: flex !important;
  align-items: center !important;
  justify-content: center !important;
  border: 2px solid #121212 !important;
  box-shadow: 0 2px 6px rgba(0,0,0,0.5) !important;
  line-height: 1 !important;
  z-index: 10 !important;
}

.qr-cart-badge {
  background: #0284c7 !important;
}

.hidden { display: none !important; }

/* ==========================================================================
   6. WHERZIT KONTROL MERKEZİ (HAMBURGER MENÜ) PANELİ VE TAŞIMA MODU
   ========================================================================== */

.hamburger-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.65);
  backdrop-filter: blur(5px);
  -webkit-backdrop-filter: blur(5px);
  z-index: 2000;
  display: flex;
  justify-content: center;
  align-items: flex-start;
  opacity: 1;
  visibility: visible;
  transition: opacity 0.25s ease, visibility 0.25s ease;
}

.hamburger-overlay.hidden {
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
}

.hamburger-panel {
  width: 100%;
  max-width: 480px;
  background: var(--panel-bg);
  border-bottom-left-radius: 16px;
  border-bottom-right-radius: 16px;
  border: 1px solid var(--border-color);
  border-top: none;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.5);
  overflow: hidden;
  transform: translateY(0);
  transition: transform 0.3s cubic-bezier(0.16, 1, 0.3, 1);
}

.hamburger-overlay.hidden .hamburger-panel {
  transform: translateY(-100%);
}

.menu-view { padding: 16px; }
.menu-view.hidden { display: none !important; }
.menu-view.active { display: block; animation: fadeInView 0.2s ease-in-out; }

@keyframes fadeInView {
  from { opacity: 0; transform: scale(0.98); }
  to { opacity: 1; transform: scale(1); }
}

.menu-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding-bottom: 10px;
  margin-bottom: 12px;
  border-bottom: 1px solid var(--border-color);
}

.menu-title { font-size: 1rem; font-weight: 600; color: var(--text-main); margin: 0; }

.close-btn, .back-btn {
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid var(--border-color);
  color: var(--text-muted);
  font-size: 0.85rem;
  cursor: pointer;
  padding: 4px 10px;
  border-radius: 6px;
  transition: all 0.2s ease;
}

.close-btn:hover, .back-btn:hover {
  background: rgba(255, 255, 255, 0.15);
  color: var(--text-main);
}

.menu-item {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 12px 14px;
  background: rgba(255, 255, 255, 0.03);
  border-radius: 10px;
  margin-bottom: 8px;
  border: 1px solid var(--border-color);
  box-sizing: border-box; /* 🐛 FIX: savunmacı sağlamlaştırma, dar ekranlarda taşmayı önler */
}

/* 🐛 FIX: dokununca beliren şeffaf mavi dikdörtgen — mobil tarayıcının
   varsayılan tap-highlight'ı hiç kapatılmamıştı, kapatıyoruz. */
.menu-item.clickable { cursor: pointer; transition: background 0.2s ease; -webkit-tap-highlight-color: transparent; }
.menu-item.clickable:hover { background: rgba(255, 255, 255, 0.08); }

/* 🐛 FIX: min-width:0 olmadan flex satırı içindeki uzun etiketler satırı
   sıkıştırmak yerine dışa taşırabiliyordu (dar mobil ekranlarda "sağa
   kayma" belirtisi). Sadece taşma varsa devreye girer, normalde görünüm
   değişmez. */
.item-info { display: flex; align-items: center; gap: 10px; min-width: 0; flex: 1; }
.item-label { color: var(--text-main); font-weight: 500; font-size: 0.9rem; overflow-wrap: break-word; }

/* iOS Tarzı Uçak Modu Switch */
.ios-switch {
  position: relative;
  display: inline-block;
  width: 44px;
  height: 24px;
}

.ios-switch input { opacity: 0; width: 0; height: 0; }

.slider {
  position: absolute;
  cursor: pointer;
  inset: 0;
  background-color: #374151;
  transition: 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  border-radius: 34px;
}

.slider:before {
  position: absolute;
  content: "";
  height: 18px;
  width: 18px;
  left: 3px;
  bottom: 3px;
  background-color: white;
  transition: 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  border-radius: 50%;
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.2);
}

input:checked + .slider {
  background-color: var(--wherzit-yellow);
  box-shadow: 0 0 10px var(--wherzit-yellow-glow);
}

input:checked + .slider:before { transform: translateX(20px); }

/* Parlayan Sarı Çerçeve (Taşıma Modu Aktifken) */
.bulk-move-glow-frame {
  position: fixed;
  inset: 0;
  border: 4px solid var(--wherzit-yellow);
  box-shadow: inset 0 0 18px var(--wherzit-yellow-glow), 0 0 18px var(--wherzit-yellow-glow);
  pointer-events: none;
  z-index: 1500;
  animation: pulseGlowFrame 2s infinite alternate;
}

.bulk-move-glow-frame.hidden { display: none !important; }

@keyframes pulseGlowFrame {
  0% { opacity: 0.5; box-shadow: inset 0 0 10px var(--wherzit-yellow-glow); }
  100% { opacity: 1; box-shadow: inset 0 0 22px var(--wherzit-yellow-glow), 0 0 12px var(--wherzit-yellow-glow); }
}

.action-stack { display: flex; flex-direction: column; gap: 10px; margin-top: 12px; }
.action-stack .btn { width: 100%; }

.btn-primary { background: var(--wherzit-yellow); color: #000; }
.btn-secondary { background: rgba(255, 255, 255, 0.1); color: var(--text-main); }

.sub-text { color: var(--text-muted); font-size: 0.82rem; line-height: 1.4; margin-bottom: 8px; }
.warning-text { color: #ef4444; font-size: 0.78rem; margin-top: 10px; text-align: center; }

/* Taşıma Modu Kapalıyken TÜM Taşı Butonlarını Kesin Olarak Gizle */
.btn-move, 
[data-action="move"], 
.card-move-btn,
.btn-bulk-move-trigger {
  display: none !important;
}

/* Sadece Taşıma Modu (Sarı Çerçeve) Açıkken "Taşı" Butonlarını Göster */
body.bulk-move-active .btn-move,
body.bulk-move-active [data-action="move"],
body.bulk-move-active .card-move-btn,
body.bulk-move-active .btn-bulk-move-trigger {
  display: inline-flex !important;
}

/* --- Ayarlar ve Dil Seçim (Settings & Language) --- */
.language-list {
  display: flex;
  flex-direction: column;
  gap: 10px;
  margin-top: 10px;
}

.lang-btn {
  display: flex;
  align-items: center;
  gap: 12px;
  width: 100%;
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid rgba(255, 255, 255, 0.08);
  padding: 14px 16px;
  border-radius: 14px;
  color: #fff;
  font-size: 1rem;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.3s ease;
  text-align: left;
}

.lang-btn:hover {
  background: rgba(255, 255, 255, 0.08);
  transform: translateY(-1px);
}

.lang-btn.active {
  border-color: #10b981;
  background: rgba(16, 185, 129, 0.1);
  box-shadow: 0 0 15px rgba(16, 185, 129, 0.15);
}

.lang-btn.disabled {
  opacity: 0.5;
  cursor: not-allowed;
}

.lang-btn.disabled:hover {
  transform: none;
  background: rgba(255, 255, 255, 0.04);
}

.lang-btn small {
  font-size: 0.75rem;
  color: #8fa0b5;
  font-weight: normal;
  margin-left: auto;
}

.lang-flag {
  font-size: 1.4rem;
}

/* ==========================================================================
   7. WHERZIT QR KOD MODÜLÜ
   ========================================================================== */

/* --- Alt-Orta Shutter (Kamera Deklanşör) Butonu --- */
.qr-shutter-btn {
  position: fixed;
  bottom: 25px;
  left: 50%;
  transform: translateX(-50%);
  background: transparent;
  border: none;
  cursor: pointer;
  z-index: 100;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 0;
  border-radius: 50%;
  transition: transform 0.2s cubic-bezier(0.175, 0.885, 0.32, 1.275);
}

.qr-shutter-btn:hover { transform: translateX(-50%) scale(1.05); }
.qr-shutter-btn:active { transform: translateX(-50%) scale(0.95); }

/* Dışarıdaki İnce Halka (Ring) */
.shutter-ring {
  width: 65px;
  height: 65px;
  border-radius: 50%;
  border: 3px solid rgba(255, 255, 255, 0.15);
  background-color: var(--surface-color);
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 8px 25px rgba(0, 0, 0, 0.6);
  transition: border-color 0.3s;
}

/* İçerideki Canlı Buton ve İkon */
.shutter-icon {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 50px;
  height: 50px;
  border-radius: 50%;
  background: linear-gradient(135deg, #4facfe 0%, #00f2fe 100%);
  color: white;
  font-size: 1.5rem;
  box-shadow: inset 0 -2px 5px rgba(0,0,0,0.2);
}

/* Telefonlardaki Yeni Ekle (+) FAB Butonunu Biraz Yana Kaydıralım Çakışmasın */
.fab { bottom: 2rem; right: 1.5rem; }

/* --- QR Scanner Kamera Çerçevesi (Modal İçi) --- */
#qr-reader {
  border-bottom-left-radius: 12px;
  border-bottom-right-radius: 12px;
  overflow: hidden;
  box-shadow: inset 0 0 20px rgba(0,0,0,0.8);
  position: relative;
}

#qr-reader video {
  object-fit: cover !important;
  border-radius: 0 0 12px 12px;
}

/* --- Pill-Box Toggle Switch (İçerik Gör ↔ Hızlı Taşı) --- */
.qr-toggle-container {
  display: flex;
  justify-content: center;
  padding: 10px 15px;
  background-color: var(--surface-color);
  border-bottom: 1px solid var(--border-color);
}

.qr-pill-box {
  position: relative;
  display: flex;
  background-color: rgba(0, 0, 0, 0.4);
  border-radius: 30px;
  width: 100%;
  max-width: 300px;
  overflow: hidden;
  border: 1px solid rgba(255,255,255,0.05);
}

.qr-pill-box input[type="radio"] { display: none; }

.qr-pill-box label {
  flex: 1;
  text-align: center;
  padding: 8px 10px;
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--text-muted);
  cursor: pointer;
  position: relative;
  z-index: 2;
  transition: color 0.3s ease;
}

/* Switch Arka Plan Animasyonu (Yeşil Kapsül) */
.qr-pill-bg {
  position: absolute;
  top: 0;
  left: 0;
  width: 50%;
  height: 100%;
  background: var(--primary-color);
  border-radius: 30px;
  transition: transform 0.3s cubic-bezier(0.4, 0.0, 0.2, 1);
  z-index: 1;
  box-shadow: 0 2px 10px rgba(76, 175, 80, 0.4);
}

#qr-mode-view:checked ~ .qr-pill-bg { transform: translateX(0%); }
#qr-mode-move:checked ~ .qr-pill-bg {
  transform: translateX(100%);
  background: var(--wherzit-yellow);
  box-shadow: 0 2px 10px rgba(245, 158, 11, 0.4);
}

#qr-mode-view:checked ~ label[for="qr-mode-view"],
#qr-mode-move:checked ~ label[for="qr-mode-move"] { color: #fff; }

/* --- QR Kod Detay Modal (Sıralı İçerik Dökümü) --- */
.qr-drawer-item {
  display: flex;
  justify-content: space-between;
  align-items: center;
  background: rgba(255, 255, 255, 0.04);
  padding: 10px 12px;
  border-radius: 8px;
  border-left: 3px solid var(--primary-color);
}

.qr-drawer-item-name {
  font-weight: 600;
  font-size: 0.9rem;
  color: var(--text-main);
  display: flex;
  align-items: center;
  gap: 6px;
}

.qr-drawer-item-date { font-size: 0.7rem; color: var(--text-muted); }

/* Çıktı Alınacak QR Kod Canvas Kutusu */
#qrcode-canvas {
  display: flex;
  justify-content: center;
  align-items: center;
}

#qrcode-canvas img { border-radius: 4px; }

@media (max-width: 768px) {
  .qr-shutter-btn { bottom: 20px; }
}


/* ==========================================================================
   8. WHERZIT TOPLU QR ETİKET MATBAASI STİLLERİ
   ========================================================================== */

/* Sol Orta Dock İçi QR Sepeti Özel Buton Stili */
.qr-cart-fab {
  background: linear-gradient(135deg, #10b981, #059669) !important;
  color: #ffffff !important;
}

.qr-cart-badge {
  background: #0284c7 !important;
}

/* Modal UI Button Düzenlemeleri */
.btn-tmpl {
  background: #1e293b;
  color: #cbd5e1;
  border: 1px solid #334155;
  cursor: pointer;
  transition: all 0.2s;
}

.btn-tmpl.active {
  background: #0284c7;
  color: #ffffff;
  border-color: #38bdf8;
  font-weight: bold;
}

.qr-cart-item-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  background: #1e293b;
  border: 1px solid #334155;
  padding: 8px 12px;
  border-radius: 8px;
  gap: 10px;
}

.qr-cart-item-info {
  flex: 1;
  display: flex;
  flex-direction: column;
}

.qr-cart-item-input {
  background: transparent;
  border: none;
  border-bottom: 1px dashed #64748b;
  color: #f8fafc;
  font-size: 13px;
  padding: 2px 0;
  width: 100%;
}

.qr-cart-item-input:focus {
  outline: none;
  border-bottom-color: #38bdf8;
}

.qr-cart-qty-ctrl {
  display: flex;
  align-items: center;
  gap: 6px;
}

.btn-qty {
  width: 26px;
  height: 26px;
  background: #334155;
  color: #fff;
  border: none;
  border-radius: 4px;
  cursor: pointer;
  font-weight: bold;
  display: flex;
  align-items: center;
  justify-content: center;
}

.qty-num {
  font-size: 13px;
  font-weight: bold;
  width: 18px;
  text-align: center;
  color: #38bdf8;
}

/* ==========================================================================
   9. A4 MATBAA BASKI MOTORU STİLLERİ (@media print)
   ========================================================================== */

@media print {
  /* Uygulamanın normal arayüzünü tamamen gizle */
  body * {
    visibility: hidden;
  }
  
  /* Sadece Baskı Alanını ve içindekileri görünür yap */
  #wz-bulk-print-area, #wz-bulk-print-area * {
    visibility: visible;
  }

  /* Baskı Alanını A4 formatına zorla ve sıfıra sıfır yerleştir */
  #wz-bulk-print-area {
    display: block !important;
    position: absolute;
    left: 0;
    top: 0;
    width: 210mm; /* A4 Genişlik */
    padding: 10mm; /* Yazıcı kenar boşluğu payı */
    background: #ffffff;
    color: #000000;
  }

  .a4-page {
    page-break-after: always;
    display: grid;
    gap: 5mm; /* Etiketler arası tam 0.5 cm kesim boşluğu */
    justify-content: start;
    align-content: start;
  }

  /* 📐 Şablon Izgara Ayarları (CSS Grid Mucizesi) */
  .a4-page.standard {
    grid-template-columns: repeat(3, 50mm); /* 3 Sütun */
    grid-auto-rows: 60mm; /* 5 cm QR + 1 cm Metin Alanı */
  }

  .a4-page.mini {
    grid-template-columns: repeat(4, 35mm); /* 4 Sütun */
    grid-auto-rows: 45mm;
  }

  .a4-page.large {
    grid-template-columns: repeat(2, 75mm); /* 2 Sütun */
    grid-auto-rows: 85mm;
  }

  /* Tekil Etiket Kutusu */
  .print-label-box {
    border: 1px dashed #cbd5e1; /* Makasla Kesim (Crop) Çizgisi */
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 3mm;
    box-sizing: border-box;
    text-align: center;
  }

  .print-label-box img {
    width: 100%;
    height: auto;
    max-height: 80%;
    object-fit: contain;
  }

  .print-label-text {
    font-size: 10pt;
    font-weight: bold;
    color: #000;
    margin-top: 2mm;
    word-break: break-word;
    max-width: 100%;
  }

  /* Boş / Not Etiketi (Kalan Boşluk Doldurucu) Stili */
  .print-label-box.blank-label {
    border: 2px solid #000; /* Boş etiketler düz siyah çizgiyle basılır */
  }

  .blank-label-title {
    font-size: 9pt;
    font-weight: bold;
    color: #475569;
    border-bottom: 1px solid #000;
    width: 100%;
    padding-bottom: 2mm;
  }
}

/* ==========================================================================
   10. WHERZIT PULSE & NEXUS KOMUTA MERKEZİ (ADMIN STUDIO) (v5.0.0)
   ========================================================================== */

/* Glass Modal Genel Stiller */
.glass-modal {
  position: fixed;
  top: 0; left: 0; width: 100%; height: 100%;
  background: rgba(0, 0, 0, 0.75);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  z-index: 999999;
  display: flex;
  justify-content: center;
  align-items: center;
  padding: 20px;
  box-sizing: border-box; /* 📱 left:0 + width:100% + padding taşıp sağa kaymasın diye (mobil fix) */
}
.glass-modal.hidden {
  display: none !important;
}
.glass-modal-content {
  background: rgba(20, 24, 35, 0.88);
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 20px;
  padding: 24px;
  width: 100%;
  max-width: 480px;
  max-height: 85vh;
  overflow-y: auto;
  box-shadow: 0 20px 40px rgba(0,0,0,0.6);
  color: #fff;
  box-sizing: border-box; /* 📱 Mobilde padding genişliğe eklenip taşmasın diye (sağa kayma/sığmama fix) */
}
.glass-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 20px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
  padding-bottom: 12px;
}
.glass-header h2 {
  font-size: 1.2rem;
  font-weight: 700;
  color: #8b5cf6;
  margin: 0;
}

/* Admin Studio Özel Theme */
.glass-modal-content.admin-theme {
  border-color: rgba(255, 51, 102, 0.3);
  box-shadow: 0 0 30px rgba(255, 51, 102, 0.15);
}

/* Nexus 3'lü Mod Anahtarı (Segment Switcher) */
.nexus-segment-control {
  display: flex;
  background: rgba(0, 0, 0, 0.3);
  border-radius: 12px;
  padding: 4px;
  margin: 15px 0;
  border: 1px solid rgba(255,255,255,0.08);
  gap: 4px;
  overflow-x: auto;
  scrollbar-width: none;
}
.nexus-segment-control::-webkit-scrollbar { display: none; }

.nexus-segment-btn {
  flex: 1;
  background: transparent;
  color: #8fa0b5;
  border: none;
  padding: 12px 10px;
  border-radius: 8px;
  font-size: 0.85rem;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.3s ease;
  white-space: nowrap;
}
.nexus-segment-btn:hover {
  color: #fff;
  background: rgba(255,255,255,0.05);
}
.nexus-segment-btn.active {
  background: rgba(255,255,255,0.12);
  color: #fff;
  box-shadow: 0 2px 10px rgba(0,0,0,0.2);
}

/* Domino Animasyonlu Telemetri Kartları */
.admin-telemetry-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(160px, 1fr));
  gap: 15px;
  margin: 15px 0;
}
.telemetry-card {
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-left: 4px solid #3b82f6;
  border-radius: 16px;
  padding: 16px 14px;
  display: flex;
  flex-direction: column;
  gap: 10px;
  box-shadow: 0 4px 15px rgba(0,0,0,0.1);
  transition: transform 0.5s cubic-bezier(0.4, 0, 0.2, 1);
  transform-style: preserve-3d;
}
.tc-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
}
.tc-title {
  font-size: 0.8rem;
  color: #cbd5e1;
  font-weight: 600;
}
.tc-icon { font-size: 1.2rem; }
.tc-value {
  font-size: 1.8rem;
  font-weight: 800;
  color: #fff;
  line-height: 1;
  font-variant-numeric: tabular-nums;
}

/* Domino Kart Dönüş (JS Tetiklemeli) */
.telemetry-card.flipping {
  transform: rotateY(90deg) scale(0.95);
}
/* Modlara Göre Vurgu Renkleri */
.telemetry-card.theme-hub { border-left-color: #3b82f6 !important; }
.telemetry-card.theme-global { border-left-color: #8b5cf6 !important; }
.telemetry-card.theme-traffic { border-left-color: #10b981 !important; }

/* Admin Studio İçi Yan Yana Grid Düzeni */
.admin-panel-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 15px;
}
@media (max-width: 768px) {
  .admin-panel-grid { grid-template-columns: 1fr; }
}

.admin-module-container {
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 16px;
  padding: 15px;
}
.admin-form {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

/* Duyuru Gösterim Kartları */
.announcement-card {
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid rgba(255, 255, 255, 0.06);
  border-left: 4px solid #8b5cf6;
  border-radius: 12px;
  padding: 14px;
  margin-bottom: 12px;
}
.announcement-card h3 {
  font-size: 0.95rem;
  color: #fff;
  margin: 0 0 6px 0;
}
.announcement-card p {
  font-size: 0.85rem;
  color: #94a3b8;
  margin: 0 0 8px 0;
  line-height: 1.4;
}
.announcement-card .date {
  font-size: 0.7rem;
  color: #64748b;
}

/* Canlı Akış / Live Ticker Bandı */
.live-ticker-wrap {
  background: rgba(0, 0, 0, 0.4);
  border-top: 1px solid rgba(255,255,255,0.05);
  padding: 12px 15px;
  margin: 20px -24px -24px -24px; /* Modal paddingine yapışsın diye eksi marjin */
  display: flex;
  align-items: center;
  gap: 10px;
  overflow: hidden;
  border-bottom-left-radius: 20px;
  border-bottom-right-radius: 20px;
}
.ticker-title {
  font-size: 0.75rem;
  color: #10b981;
  font-weight: bold;
  text-transform: uppercase;
  flex-shrink: 0;
  display: flex;
  align-items: center;
  gap: 6px;
  border-right: 1px solid rgba(255,255,255,0.1);
  padding-right: 10px;
}
.ticker-pulse {
  width: 8px; height: 8px; 
  background: #10b981; 
  border-radius: 50%; 
  box-shadow: 0 0 10px #10b981; 
  animation: blink 1.5s infinite;
}
@keyframes blink { 
  0%, 100% { opacity: 1; } 
  50% { opacity: 0.2; } 
}
.ticker-content {
  flex-grow: 1;
  white-space: nowrap;
  overflow: hidden;
  position: relative;
}
.ticker-text {
  display: inline-block;
  font-size: 0.82rem;
  color: #94a3b8;
  animation: scrollTicker 20s linear infinite;
}
@keyframes scrollTicker {
  0% { transform: translateX(100%); }
  100% { transform: translateX(-100%); }
}


/* ==========================================
   BOTTOM SHEET SLIDE-UP ANIMATION (PC & MOBILE)
   ========================================== */
@keyframes slideUp {
  from {
    transform: translateY(100%);
    opacity: 0;
  }
  to {
    transform: translateY(0);
    opacity: 1;
  }
}

.custom-picker-overlay.bottom-sheet-overlay,
.modal-overlay.bottom-sheet-overlay {
  align-items: flex-end !important;
  justify-content: center !important;
}

.custom-picker-overlay.bottom-sheet-overlay .custom-picker-content,
.custom-picker-overlay.bottom-sheet-overlay .modal-content,
.modal-overlay.bottom-sheet-overlay .modal-content {
  width: 100% !important;
  max-width: 620px !important;
  border-radius: 20px 20px 0 0 !important;
  box-shadow: 0 -10px 40px rgba(0,0,0,0.8) !important;
  animation: slideUp 0.3s cubic-bezier(0.16, 1, 0.3, 1) forwards !important;
  max-height: 85vh !important;
}


/* Downward Tooltip for Backup & Header Views */
#view-backup .wz-tooltip-content,
.wz-tooltip-wrapper.wz-tooltip-down .wz-tooltip-content {
  top: calc(100% + 8px) !important;
  bottom: auto !important;
  right: 0 !important;
  left: auto !important;
  box-shadow: 0 10px 25px rgba(0, 0, 0, 0.5) !important;
}

/* Downward + LEFT-aligned Tooltip — sol üst köşedeki "?" ikonları için
   (ör. Kategori/Lokasyon İkonu Seç penceresi). wz-tooltip-down'un aynısı,
   sadece kutu ikonun SAĞINA doğru açılıyor (soluna değil) — aksi halde
   ekranın en soluna yakın bir ikonda kutu ekran dışına taşardı. */
.wz-tooltip-wrapper.wz-tooltip-down-left .wz-tooltip-content {
  top: calc(100% + 8px) !important;
  bottom: auto !important;
  left: 0 !important;
  right: auto !important;
  box-shadow: 0 10px 25px rgba(0, 0, 0, 0.5) !important;
}

/* 🐛 FIX (BUG-014 — dar ekranlarda tooltip sol kenardan taşması):
   .wz-tooltip-content'in konumu, "?" ikonunu saran ~19px'lik
   .wz-tooltip-wrapper'a (position:relative) göre "right:0" ile
   hesaplanıyordu. İkon ekranın neresinde olursa olsun 260px'lik kutu
   SOLA doğru açılıyordu; ikon 320px'lik bir ekranda soldan 260px'ten
   daha yakınsa (ör. "📦 Taşı" satırındaki ? ikonu — bkz. app.js
   renderActionControls) kutunun sol kısmı ekran dışına taşıyordu. Basit
   bir max-width eklemek bunu ÇÖZMEZ (260px zaten 320px ekrandan küçük —
   sorun genişlik değil, KONUM). Bu yüzden dar ekranlarda kutuyu, hangi
   ikonun tetiklediğine bakmaksızın, position:fixed ile EKRANIN ORTASINA
   sabitliyoruz — böylece hiçbir zaman kenardan taşamaz.
   Bu blok, yukarıdaki "#view-backup ... !important" kuralıyla AYNI
   özgüllükte (specificity) aynı seçicileri de içeriyor ve dosyada ONDAN
   SONRA geldiği için CSS "eşit özgüllükte sonraki kural kazanır"
   kuralıyla güvenle üzerine yazıyor — geri dönüş (backup) ekranındaki
   tooltip de dahil, HİÇBİR tooltip dar ekranda yarı-düzeltilmiş garip bir
   karışık duruma düşmüyor. Sadece konum/genişlik değişiyor; görünme/
   gizlenme mekanizması (hover → opacity/visibility) ve büyük ekranlardaki
   mevcut davranış AYNEN korunuyor. */
@media (max-width: 380px) {
  .wz-tooltip-content,
  #view-backup .wz-tooltip-content,
  .wz-tooltip-wrapper.wz-tooltip-down .wz-tooltip-content {
    position: fixed !important;
    top: 50% !important;
    left: 50% !important;
    right: auto !important;
    bottom: auto !important;
    width: calc(100vw - 32px) !important;
    max-width: 300px !important;
    transform: translate(-50%, calc(-50% + 4px)) !important;
  }
  .wz-tooltip-wrapper:hover .wz-tooltip-content {
    transform: translate(-50%, -50%) !important;
  }
}

/* Card Back and Media Grid CSS Fixes */
.item-card-back {
  background: linear-gradient(160deg, var(--surface-color, #1e293b) 0%, rgba(56, 189, 248, 0.06) 100%);
  border-left: 4px solid var(--primary-color, #38bdf8);
  border-radius: 8px;
  padding: 0.8rem 1rem;
  box-sizing: border-box;
  transform: rotateY(180deg);
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  overflow: hidden;
  backface-visibility: hidden;
  -webkit-backface-visibility: hidden;
}

.back-media-grid {
  display: flex;
  gap: 10px;
  align-items: flex-start;
  justify-content: flex-start;
  width: 100%;
  flex: 1;
  box-sizing: border-box;
}

.back-photo-box {
  flex: 0 0 130px;
  max-width: 130px;
  height: 70px;
  background: linear-gradient(145deg, rgba(255, 255, 255, 0.07), rgba(0, 0, 0, 0.5));
  border: 1px solid rgba(255, 255, 255, 0.14);
  border-radius: 12px;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
  cursor: pointer;
  position: relative;
  box-shadow:
    0 8px 18px rgba(0, 0, 0, 0.5),
    inset 0 1px 0 rgba(255, 255, 255, 0.08),
    inset 0 0 0 1px rgba(0, 0, 0, 0.3);
  transition: transform 0.25s cubic-bezier(0.34, 1.56, 0.64, 1), box-shadow 0.25s ease, border-color 0.25s ease;
}

.back-photo-box::after {
  content: '🔍';
  position: absolute;
  bottom: 4px;
  right: 5px;
  font-size: 0.68rem;
  opacity: 0.9;
  filter: drop-shadow(0 1px 3px rgba(0, 0, 0, 0.8));
  pointer-events: none;
}

.back-photo-box:hover {
  border-color: var(--primary-color, #38bdf8);
  transform: translateY(-3px) scale(1.03);
  box-shadow:
    0 14px 26px rgba(0, 0, 0, 0.55),
    0 0 0 1px var(--primary-color, #38bdf8),
    0 0 18px var(--primary-glow, rgba(76, 175, 80, 0.35)),
    inset 0 1px 0 rgba(255, 255, 255, 0.1);
}

.back-photo-box img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  transition: transform 0.35s ease;
}

.back-photo-box:hover img {
  transform: scale(1.1);
}

.back-qr-box {
  flex: 1;
  max-width: 180px;
  height: 85px;
  background-color: rgba(56, 189, 248, 0.08);
  border: 1px dashed var(--primary-color, #38bdf8);
  border-radius: 8px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  color: var(--primary-color, #38bdf8);
  font-size: 0.8rem;
  font-weight: 600;
  text-align: center;
  padding: 8px;
  box-sizing: border-box;
  cursor: pointer;
  transition: background 0.2s, transform 0.1s;
}

.back-qr-box:hover {
  background-color: rgba(56, 189, 248, 0.18);
  transform: scale(1.02);
}


/* QR Cart Item Row & Overflow Improvements */
#qr-cart-items-container {
  max-height: 48vh !important;
  overflow-y: auto !important;
  overflow-x: hidden !important;
  padding-right: 4px;
}

.qr-cart-item-row {
  display: flex !important;
  align-items: center !important;
  justify-content: space-between !important;
  background: var(--surface-color, #1e293b) !important;
  border: 1px solid var(--border-color, #334155) !important;
  padding: 10px 12px !important;
  border-radius: 8px !important;
  margin-bottom: 8px !important;
  gap: 8px !important;
  box-sizing: border-box !important;
  width: 100% !important;
}

.qr-cart-item-info {
  flex: 1 !important;
  min-width: 0 !important;
  overflow: hidden !important;
}

.qr-cart-item-input {
  background: transparent !important;
  border: none !important;
  border-bottom: 1px dashed #64748b !important;
  color: #f8fafc !important;
  font-size: 13px !important;
  padding: 2px 0 !important;
  width: 100% !important;
  box-sizing: border-box !important;
}


/* ==========================================================================
   2027 DARK GLASSMORPHIC LANGUAGE SELECTION MODAL (#language-modal)
   ========================================================================== */
#language-modal {
  position: fixed;
  top: 0; left: 0; width: 100%; height: 100%;
  background: rgba(10, 14, 23, 0.78);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  z-index: 999999 !important;
  display: none;
  justify-content: center;
  align-items: center;
  padding: 20px;
  transition: opacity 0.25s ease;
}

#language-modal.active {
  display: flex !important;
}

#language-modal.closing {
  opacity: 0;
  pointer-events: none;
}

#language-modal .glass-modal-content.language-modal-card {
  background: rgba(18, 24, 38, 0.94) !important;
  border: 1px solid rgba(255, 255, 255, 0.12) !important;
  border-radius: 24px !important;
  padding: 26px 22px !important;
  width: 100%;
  max-width: 420px !important;
  box-shadow: 0 25px 60px -10px rgba(0, 0, 0, 0.85), inset 0 1px 1px rgba(255, 255, 255, 0.1) !important;
  transform: scale(1);
  transition: transform 0.25s cubic-bezier(0.16, 1, 0.3, 1), opacity 0.25s ease !important;
  position: relative;
  overflow: hidden;
}

#language-modal.closing .glass-modal-content.language-modal-card {
  transform: scale(0.94) !important;
  opacity: 0 !important;
}

#language-modal .glass-modal-content.language-modal-card::before {
  content: '';
  position: absolute;
  top: 0; left: 0; right: 0;
  height: 3px;
  background: linear-gradient(90deg, #10b981, #3b82f6, #10b981);
}

/* ==========================================================================
   2027 DARK GLASSMORPHIC ENVANTER SIFIRLAMA PENCERESİ (#reset-inventory-modal)
   Dil modalıyla AYNI cam/blur/animasyon dili — tehlike teması için sadece
   yeşil/mavi gradyan yerine kırmızı/turuncu vurgu kullanılıyor.
   ========================================================================== */
#reset-inventory-modal {
  position: fixed;
  top: 0; left: 0; width: 100%; height: 100%;
  background: rgba(10, 14, 23, 0.78);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  z-index: 999999 !important;
  display: none;
  justify-content: center;
  align-items: center;
  padding: 20px;
  transition: opacity 0.25s ease;
}

#reset-inventory-modal.active {
  display: flex !important;
}

#reset-inventory-modal.closing {
  opacity: 0;
  pointer-events: none;
}

#data-reset-other-modal .glass-modal-content.data-reset-other-modal-card {
  background: rgba(18, 24, 38, 0.94) !important;
  border: 1px solid rgba(249, 115, 22, 0.25) !important;
  border-radius: 24px !important;
  padding: 26px 22px !important;
  width: 100%;
  box-sizing: border-box !important;
  /* 🐛 FIX (mobilde sağa taşma): 420px sabiti dar ekranlarda görünür
     alandan geniş kalabiliyordu — viewport'a göre kesin üst sınır. */
  max-width: min(420px, calc(100vw - 40px)) !important;
  box-shadow: 0 25px 60px -10px rgba(0, 0, 0, 0.85), 0 0 40px rgba(249, 115, 22, 0.12), inset 0 1px 1px rgba(255, 255, 255, 0.1) !important;
  transform: scale(1);
  transition: transform 0.25s cubic-bezier(0.16, 1, 0.3, 1), opacity 0.25s ease !important;
  position: relative;
  overflow: hidden;
}

#data-reset-other-modal.closing .glass-modal-content.data-reset-other-modal-card {
  transform: scale(0.94) !important;
  opacity: 0 !important;
}

#data-reset-other-modal .glass-modal-content.data-reset-other-modal-card::before {
  content: '';
  position: absolute;
  top: 0; left: 0; right: 0;
  height: 3px;
  background: linear-gradient(90deg, #f97316, #ef4444, #f97316);
}

#reset-inventory-modal .glass-modal-content.reset-inventory-modal-card {
  background: rgba(18, 24, 38, 0.94) !important;
  border: 1px solid rgba(239, 68, 68, 0.25) !important;
  border-radius: 24px !important;
  padding: 26px 22px !important;
  width: 100%;
  box-sizing: border-box !important;
  /* 🐛 FIX (mobilde sağa taşma): 420px sabiti dar ekranlarda görünür
     alandan geniş kalabiliyordu — viewport'a göre kesin üst sınır. */
  max-width: min(420px, calc(100vw - 40px)) !important;
  box-shadow: 0 25px 60px -10px rgba(0, 0, 0, 0.85), 0 0 40px rgba(239, 68, 68, 0.12), inset 0 1px 1px rgba(255, 255, 255, 0.1) !important;
  transform: scale(1);
  transition: transform 0.25s cubic-bezier(0.16, 1, 0.3, 1), opacity 0.25s ease !important;
  position: relative;
  overflow: hidden;
}

#reset-inventory-modal.closing .glass-modal-content.reset-inventory-modal-card {
  transform: scale(0.94) !important;
  opacity: 0 !important;
}

#reset-inventory-modal .glass-modal-content.reset-inventory-modal-card::before {
  content: '';
  position: absolute;
  top: 0; left: 0; right: 0;
  height: 3px;
  background: linear-gradient(90deg, #ef4444, #f97316, #ef4444);
}

.reset-inventory-actions {
  display: flex;
  gap: 12px;
  margin-top: 8px;
}

.wz-reset-no-btn,
.wz-reset-yes-btn {
  flex: 1;
  padding: 13px 16px;
  border-radius: 14px;
  font-size: 0.95rem;
  font-weight: 700;
  border: none;
  cursor: pointer;
  transition: all 0.25s cubic-bezier(0.4, 0, 0.2, 1);
  font-family: inherit;
}

.wz-reset-no-btn {
  background: rgba(255, 255, 255, 0.06);
  border: 1px solid rgba(255, 255, 255, 0.14);
  color: #e2e8f0;
}

.wz-reset-no-btn:hover {
  background: rgba(255, 255, 255, 0.1);
  transform: translateY(-1px);
}

/* 🔒 Kilitli (geri sayım) hâli — gri, renksiz, tıklanamaz */
.wz-reset-yes-btn {
  background: rgba(255, 255, 255, 0.05);
  color: #64748b;
  border: 1px solid rgba(255, 255, 255, 0.08);
  cursor: not-allowed;
}

.wz-reset-yes-btn:disabled {
  background: rgba(255, 255, 255, 0.05);
  color: #64748b;
  cursor: not-allowed;
}

/* 🔓 10 saniye sonra aktifleşen hâl — kırmızı, dolgun, tıklanabilir */
.wz-reset-yes-btn:not(:disabled) {
  background: linear-gradient(135deg, #ef4444, #dc2626);
  color: #fff;
  cursor: pointer;
  box-shadow: 0 8px 20px rgba(239, 68, 68, 0.35);
}

.wz-reset-yes-btn:not(:disabled):hover {
  transform: translateY(-1px);
  box-shadow: 0 10px 26px rgba(239, 68, 68, 0.45);
}

.wz-reset-yes-btn:not(:disabled):active {
  transform: translateY(0);
}

/* ==========================================================================
   2027 DARK GLASSMORPHIC TÜKETİM MODU SIFIRLAMA PENCERESİ (#reset-consumption-modal)
   Envanter sıfırlama modalıyla AYNI cam/blur/animasyon dili — bağımsız bir
   işlem olduğunu ayırt etmek için kırmızı yerine amber/turuncu vurgu kullanılıyor.
   ========================================================================== */
#reset-consumption-modal {
  position: fixed;
  top: 0; left: 0; width: 100%; height: 100%;
  background: rgba(10, 14, 23, 0.78);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  z-index: 999999 !important;
  display: none;
  justify-content: center;
  align-items: center;
  padding: 20px;
  transition: opacity 0.25s ease;
}

#reset-consumption-modal.active {
  display: flex !important;
}

#reset-consumption-modal.closing {
  opacity: 0;
  pointer-events: none;
}

#reset-consumption-modal .glass-modal-content.reset-consumption-modal-card {
  background: rgba(18, 24, 38, 0.94) !important;
  border: 1px solid rgba(245, 158, 11, 0.25) !important;
  border-radius: 24px !important;
  padding: 26px 22px !important;
  width: 100%;
  box-sizing: border-box !important;
  /* 🐛 FIX (mobilde sağa taşma): 420px sabiti dar ekranlarda görünür
     alandan geniş kalabiliyordu — viewport'a göre kesin üst sınır. */
  max-width: min(420px, calc(100vw - 40px)) !important;
  box-shadow: 0 25px 60px -10px rgba(0, 0, 0, 0.85), 0 0 40px rgba(245, 158, 11, 0.12), inset 0 1px 1px rgba(255, 255, 255, 0.1) !important;
  transform: scale(1);
  transition: transform 0.25s cubic-bezier(0.16, 1, 0.3, 1), opacity 0.25s ease !important;
  position: relative;
  overflow: hidden;
}

#reset-consumption-modal.closing .glass-modal-content.reset-consumption-modal-card {
  transform: scale(0.94) !important;
  opacity: 0 !important;
}

#reset-consumption-modal .glass-modal-content.reset-consumption-modal-card::before {
  content: '';
  position: absolute;
  top: 0; left: 0; right: 0;
  height: 3px;
  background: linear-gradient(90deg, #f59e0b, #ef4444, #f59e0b);
}

.reset-consumption-actions {
  display: flex;
  gap: 12px;
  margin-top: 8px;
}

.wz-reset-consumption-yes-btn {
  flex: 1;
  padding: 13px 16px;
  border-radius: 14px;
  font-size: 0.95rem;
  font-weight: 700;
  border: none;
  cursor: pointer;
  transition: all 0.25s cubic-bezier(0.4, 0, 0.2, 1);
  font-family: inherit;
}

/* 🔒 Kilitli (geri sayım) hâli — gri, renksiz, tıklanamaz */
.wz-reset-consumption-yes-btn {
  background: rgba(255, 255, 255, 0.05);
  color: #64748b;
  border: 1px solid rgba(255, 255, 255, 0.08);
  cursor: not-allowed;
}

.wz-reset-consumption-yes-btn:disabled {
  background: rgba(255, 255, 255, 0.05);
  color: #64748b;
  cursor: not-allowed;
}

/* 🔓 10 saniye sonra aktifleşen hâl — amber, dolgun, tıklanabilir */
.wz-reset-consumption-yes-btn:not(:disabled) {
  background: linear-gradient(135deg, #f59e0b, #d97706);
  color: #fff;
  cursor: pointer;
  box-shadow: 0 8px 20px rgba(245, 158, 11, 0.35);
}

.wz-reset-consumption-yes-btn:not(:disabled):hover {
  transform: translateY(-1px);
  box-shadow: 0 10px 26px rgba(245, 158, 11, 0.45);
}

.wz-reset-consumption-yes-btn:not(:disabled):active {
  transform: translateY(0);
}

.language-cards-grid {
  display: flex;
  flex-direction: column;
  gap: 14px;
  margin-top: 10px;
}

.lang-card {
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid rgba(255, 255, 255, 0.09);
  border-radius: 18px;
  padding: 16px 18px;
  cursor: pointer;
  transition: all 0.25s cubic-bezier(0.4, 0, 0.2, 1);
  display: flex;
  flex-direction: column;
  gap: 6px;
  position: relative;
  user-select: none;
}

.lang-card:hover {
  background: rgba(255, 255, 255, 0.08);
  border-color: rgba(255, 255, 255, 0.22);
  transform: translateY(-2px);
  box-shadow: 0 10px 25px rgba(0, 0, 0, 0.4);
}

.lang-card:active {
  transform: scale(0.98);
}

.lang-card.active {
  border-color: #10b981 !important;
  background: linear-gradient(135deg, rgba(16, 185, 129, 0.18) 0%, rgba(16, 185, 129, 0.04) 100%) !important;
  box-shadow: 0 0 25px rgba(16, 185, 129, 0.25), inset 0 0 12px rgba(16, 185, 129, 0.08) !important;
}

.lang-card-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  width: 100%;
}

.lang-card-title {
  color: #ffffff;
  font-size: 1.1rem;
  font-weight: 700;
  letter-spacing: 0.3px;
}

.lang-card-badge {
  display: none;
  align-items: center;
  gap: 4px;
  background: rgba(16, 185, 129, 0.2);
  color: #10b981;
  border: 1px solid rgba(16, 185, 129, 0.5);
  padding: 4px 12px;
  border-radius: 20px;
  font-size: 0.78rem;
  font-weight: 700;
  letter-spacing: 0.3px;
  box-shadow: 0 2px 10px rgba(16, 185, 129, 0.25);
}

.lang-card.active .lang-card-badge {
  display: inline-flex !important;
}

.lang-card-body {
  display: flex;
  flex-direction: column;
  padding-left: 48px;
}

.lang-card-sub {
  color: #8fa0b5;
  font-size: 0.82rem;
  margin-top: 1px;
}

/* 🇩🇪 Kullanım dışı / yakında gelecek diller için soluk (grayscale) görünüm */
.lang-card.disabled {
  cursor: not-allowed;
  opacity: 0.5;
  filter: grayscale(0.7);
}

.lang-card.disabled:hover {
  background: rgba(255, 255, 255, 0.04);
  border-color: rgba(255, 255, 255, 0.09);
  transform: none;
  box-shadow: none;
}

.lang-card.disabled:active {
  transform: none;
}

.lang-card-badge-soon {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  background: rgba(148, 163, 184, 0.15);
  color: #94a3b8;
  border: 1px solid rgba(148, 163, 184, 0.35);
  padding: 4px 12px;
  border-radius: 20px;
  font-size: 0.78rem;
  font-weight: 700;
  letter-spacing: 0.3px;
}

/* ==========================================================================
   TÜKETİM MODU - İLAÇ KUTUSU TEMASI
   (Kayıtlı ilaç kartlarının ön yüzü, gerçek ilaç kutularını çağrıştıran ama
   birebir kopyası olmayan bir tasarımla gösterilir: lacivert üst bant, krem
   gövde, yeşil dalga şerit, kırmızı alt bant, üç renkli nokta rozeti.)
   ========================================================================== */

.ilac-kutu-on {
  display: flex;
  flex-direction: column;
  height: 100%;
  border-radius: 14px;
  overflow: hidden;
  box-shadow: inset 0 0 0 1px rgba(0, 0, 0, 0.25), 0 2px 6px rgba(0, 0, 0, 0.35);
}

.ilac-kutu-banner {
  background: linear-gradient(135deg, #1c3f8f 0%, #0d1f52 100%);
  padding: 8px 10px 10px;
}

.ilac-kutu-durum {
  font-size: 9px;
  font-weight: 800;
  letter-spacing: 0.3px;
  background: rgba(0, 0, 0, 0.35);
  padding: 2px 7px;
  border-radius: 8px;
  white-space: nowrap;
}

.ilac-kutu-noktalar {
  display: flex;
  gap: 3px;
  align-items: center;
}

.ilac-nokta {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  display: inline-block;
  box-shadow: 0 0 0 1px rgba(255, 255, 255, 0.25);
}
.ilac-nokta.mavi { background: #3b82f6; }
.ilac-nokta.yesil { background: #22c55e; }
.ilac-nokta.kirmizi { background: #ef4444; }

.ilac-kutu-isim-satiri {
  margin-top: 7px;
}

.ilac-kutu-isim {
  color: #fff;
  font-size: 14px;
  font-weight: 800;
  display: block;
  line-height: 1.2;
  text-shadow: 0 1px 1px rgba(0, 0, 0, 0.3);
}

.ilac-kutu-doz {
  display: inline-block;
  margin-top: 4px;
  background: rgba(255, 255, 255, 0.15);
  color: #eaf0ff;
  font-size: 10px;
  font-weight: 700;
  letter-spacing: 0.2px;
  padding: 2px 7px;
  border-radius: 6px;
}

.ilac-kutu-govde {
  flex: 1;
  min-height: 28px;
  position: relative;
  display: flex;
  align-items: center;
  padding: 8px 10px;
  background: #f4f1e6;
  background-image: linear-gradient(
    100deg,
    transparent 0%, transparent 42%,
    #16a34a 42%, #22c55e 50%, #16a34a 58%,
    transparent 58%, transparent 100%
  );
}

.ilac-kutu-firma {
  position: relative;
  z-index: 1;
  color: #1e293b;
  font-size: 10px;
  font-weight: 700;
  background: rgba(244, 241, 230, 0.85);
  padding: 1px 4px;
  border-radius: 4px;
}

.ilac-kutu-taban {
  background: linear-gradient(135deg, #c11f1f 0%, #7a1010 100%);
  padding: 6px 10px;
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 8px;
}

.ilac-kutu-cevir-btn,
.ilac-kutu-geri-btn {
  background: rgba(255, 255, 255, 0.15);
  border: 1px solid rgba(255, 255, 255, 0.45);
  color: #fff;
  font-size: 11px;
  font-weight: 700;
  padding: 4px 9px;
  border-radius: 6px;
  cursor: pointer;
}

.ilac-kutu-geri-btn {
  background: rgba(16, 185, 129, 0.3);
  border-color: #10b981;
  color: #d1fae5;
}

/* SKT uyarı balonundaki küçük ilaç kartları için biraz daha kompakt */
.ilac-kutu-on-kucuk .ilac-kutu-banner { padding: 7px 9px 8px; }
.ilac-kutu-on-kucuk .ilac-kutu-isim { font-size: 13px; }
.ilac-kutu-on-kucuk .ilac-kutu-taban { padding: 5px 9px; }

/* İlaç kartlarının arka yüzünde de aynı temayı hafifçe hissettirmek için
   kategori başlık şeridine lacivert-kırmızı bir vurgu veriyoruz. */
.ilac-kutu-arka .kart-arka-baslik {
  background: linear-gradient(90deg, #1c3f8f 0%, #7a1010 100%);
  border-radius: 8px;
  padding: 4px 8px;
}
.ilac-kutu-arka .kart-arka-baslik .kart-arka-kategori {
  color: #fff;
  font-weight: 700;
}

/* ==========================================================================
   TÜKETİM MODU - KART TEMEL YAPISI (boyut + çevirme / flip)
   Önceden bu kartların dış kutusu için boyut/konum tanımı yoktu; bu yüzden
   ön yüz (ör. ilaç kutusu teması) kutunun tamamını doldurmuyor, üstte/altta
   boşluk kalıyordu. Ön/arka yüzleri artık kartın TAMAMINI kaplayacak şekilde
   üst üste (absolute) konumlandırıyoruz ve aralarında basit bir crossfade
   ile geçiş yapıyoruz.
   ========================================================================== */

#tuketimKartListesi {
  align-items: stretch;
}

.tuketim-kart-sahne {
  flex: 0 0 auto;
  width: 190px;
  height: 235px;
}

.tuketim-kart-govde {
  position: relative;
  width: 100%;
  height: 100%;
  border-radius: 16px;
  background: #181818;
  border: 1px solid #2a2a2a;
  box-sizing: border-box;
  transition: box-shadow 0.2s ease;
}

.tuketim-kart-govde.kart-acil { box-shadow: 0 0 0 1px #ef4444, 0 0 14px rgba(239, 68, 68, 0.35); }
.tuketim-kart-govde.kart-yakinda { box-shadow: 0 0 0 1px #f59e0b, 0 0 14px rgba(245, 158, 11, 0.3); }
.tuketim-kart-govde.kart-normal { box-shadow: 0 0 0 1px #10b981, 0 0 14px rgba(16, 185, 129, 0.28); }
.tuketim-kart-govde.kart-cop { box-shadow: 0 0 0 1px #555; opacity: 0.85; }

.tuketim-kart-govde > .kart-on,
.tuketim-kart-govde > .ilac-kutu-on,
.tuketim-kart-govde > .kart-arka {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  margin: 0;
  width: auto;
  height: auto;
  box-sizing: border-box;
  border-radius: 15px;
  overflow: hidden;
  transition: opacity 0.18s ease;
}

.tuketim-kart-govde > .kart-on {
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  padding: 10px;
  background: #181818;
}

.tuketim-kart-govde > .kart-arka {
  display: flex;
  flex-direction: column;
  padding: 10px;
  background: #181818;
  opacity: 0;
  pointer-events: none;
}

.tuketim-kart-govde.flipped > .kart-on,
.tuketim-kart-govde.flipped > .ilac-kutu-on {
  opacity: 0;
  pointer-events: none;
}

.tuketim-kart-govde.flipped > .kart-arka {
  opacity: 1;
  pointer-events: auto;
}

.kart-arka-detay {
  flex: 1;
  overflow-y: auto;
  margin-top: 6px;
}

.kart-arka-satir {
  display: flex;
  justify-content: space-between;
  gap: 8px;
  font-size: 11px;
  padding: 3px 0;
  border-bottom: 1px dashed #2a2a2a;
}
.kart-arka-satir .etiket { color: #888; }
.kart-arka-satir .deger { color: #eee; text-align: right; }
.kart-arka-bos { color: #666; font-size: 11px; text-align: center; padding: 10px 0; }

.kart-arka-baslik {
  display: flex;
  justify-content: space-between;
  align-items: center;
}
.kart-arka-kategori { font-size: 11px; font-weight: 700; color: #ccc; }
.kart-arka-foto { width: 30px; height: 30px; border-radius: 6px; object-fit: cover; cursor: pointer; }

.kart-arka-check { display: flex; align-items: center; gap: 6px; font-size: 11px; color: #aaa; margin-top: 6px; }

.kart-arka-aksiyonlar { display: flex; justify-content: flex-end; gap: 8px; margin-top: 6px; }

.kart-icon-btn {
  background: #222;
  border: 1px solid #3a3a3a;
  color: #ccc;
  border-radius: 6px;
  padding: 4px 8px;
  cursor: pointer;
  font-size: 12px;
}
.kart-icon-btn.sil { color: #ef4444; border-color: #ef444455; }
.kart-icon-btn.geri { color: #9ca3af; }

/* --- SKT uyarı balonu kartları için aynı yapı --- */
.skt-alert-kart-sahne {
  flex: 0 0 auto;
  width: 190px;
  height: 235px;
  margin-bottom: 10px;
}

.skt-alert-kart-govde {
  position: relative;
  width: 100%;
  height: 100%;
  border-radius: 16px;
  background: #181818;
  border: 1px solid #2a2a2a;
  box-sizing: border-box;
  box-shadow: 0 0 0 1px var(--skt-alert-renk, #333), 0 0 14px rgba(0, 0, 0, 0.3);
}

.skt-alert-kart-govde > .skt-alert-kart-on,
.skt-alert-kart-govde > .ilac-kutu-on,
.skt-alert-kart-govde > .skt-alert-kart-arka {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  margin: 0;
  width: auto;
  height: auto;
  box-sizing: border-box;
  border-radius: 15px;
  overflow: hidden;
  transition: opacity 0.18s ease;
}

.skt-alert-kart-govde > .skt-alert-kart-on {
  display: flex;
  flex-direction: column;
  padding: 10px;
  background: #181818;
}

.skt-alert-kart-govde > .skt-alert-kart-arka {
  display: flex;
  flex-direction: column;
  padding: 10px;
  background: #181818;
  opacity: 0;
  pointer-events: none;
}

.skt-alert-kart-govde.flipped > .skt-alert-kart-on,
.skt-alert-kart-govde.flipped > .ilac-kutu-on {
  opacity: 0;
  pointer-events: none;
}

.skt-alert-kart-govde.flipped > .skt-alert-kart-arka {
  opacity: 1;
  pointer-events: auto;
}

#skt-alert-list {
  display: flex;
  flex-direction: column;
  align-items: center;
}

/* ==========================================================================
   TÜKETİM MODU - "KİME AİT" ÖNERİ ROZETLERİ (chip)
   ========================================================================== */
.skt-sahip-onerileri {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-top: 6px;
}

.skt-sahip-chip {
  background: rgba(76, 175, 80, 0.14);
  border: 1px solid var(--primary-color);
  color: var(--primary-color);
  font-size: 12px;
  font-weight: 600;
  padding: 4px 12px;
  border-radius: 999px;
  cursor: pointer;
  transition: background 0.15s ease, transform 0.1s ease;
}

.skt-sahip-chip:hover {
  background: rgba(76, 175, 80, 0.3);
}

.skt-sahip-chip:active {
  transform: scale(0.96);
}

/* ==========================================================================
   EŞYA EKLEME FORMU - 2027 GLASSMORPHIC MODERNİZASYON
   (Dil Ayarları modalıyla aynı görsel dil: koyu cam efekti, üstte gradyan
   şerit, yuvarlak hatlı kartsı alanlar, yumuşak glow/hover geçişleri.)
   ========================================================================== */

#modalOverlay.modal-overlay {
  background-color: rgba(5, 8, 14, 0.72);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
}

#modalOverlay .modal-content {
  background: rgba(18, 24, 38, 0.92);
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 24px;
  padding: 22px;
  box-shadow: 0 25px 60px -10px rgba(0, 0, 0, 0.8), inset 0 1px 1px rgba(255, 255, 255, 0.08);
  position: relative;
  overflow: hidden;
}

#modalOverlay .modal-content::before {
  content: '';
  position: absolute;
  top: 0; left: 0; right: 0;
  height: 3px;
  background: linear-gradient(90deg, #10b981, #3b82f6, #10b981);
  z-index: 1;
}

#modalOverlay .modal-content-inner {
  position: relative;
  z-index: 2;
}

#modalOverlay .modal-title {
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
  padding-bottom: 14px;
  margin-bottom: 18px;
}

#modalOverlay .modal-title #modalTitleText {
  font-size: 1.15rem;
  font-weight: 800;
  color: #10b981;
  letter-spacing: 0.2px;
}

#modalOverlay .picker-close {
  background: rgba(255, 255, 255, 0.06);
  border: 1px solid rgba(255, 255, 255, 0.12);
  color: #fff;
  width: 30px;
  height: 30px;
  border-radius: 10px;
  font-size: 1rem;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  transition: all 0.2s ease;
}
#modalOverlay .picker-close:hover {
  background: rgba(239, 68, 68, 0.2);
  border-color: rgba(239, 68, 68, 0.5);
  color: #ef4444;
}

/* --- Tüketim Modu kapsül anahtarı --- */
.skt-capsule-badge-anchor {
  display: flex;
  justify-content: flex-end;
  margin-bottom: 10px;
}

.skt-capsule-badge {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  background: rgba(255, 255, 255, 0.06);
  border: 1px solid rgba(255, 255, 255, 0.14);
  color: #8fa0b5;
  font-size: 0.72rem;
  font-weight: 800;
  letter-spacing: 0.4px;
  padding: 6px 14px;
  border-radius: 999px;
  cursor: pointer;
  transition: all 0.25s cubic-bezier(0.4, 0, 0.2, 1);
  user-select: none;
}

.skt-capsule-badge:hover {
  border-color: rgba(16, 185, 129, 0.5);
  color: #d1fae5;
}

.skt-capsule-badge.active {
  background: linear-gradient(135deg, rgba(16, 185, 129, 0.25), rgba(16, 185, 129, 0.08));
  border-color: #10b981;
  color: #10b981;
  box-shadow: 0 0 18px rgba(16, 185, 129, 0.35);
}

/* --- Form alanları --- */
#modalOverlay .form-group label {
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: 0.72rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  color: #8fa0b5;
  margin-bottom: 6px;
}

/* Çoklu sütunlu satırlarda (Ana/Alt Lokasyon, Çekmece/Bölüm, Kategori/Miktar/Stok
   Limiti vb.) büyük harfe çevirmek etiketleri gereğinden geniş yapıp satırı
   kırıyor ve o sütundaki kutuyu aşağı kaydırıyordu. Bu satırlarda etiketi
   normal harfle, daha küçük punto ile göster; olası bir kırılma durumunda da
   tüm sütunların aynı hizada kalması için etiket alanına sabit bir yükseklik
   ayır. */
#modalOverlay .form-row .form-group label {
  text-transform: none;
  letter-spacing: 0.1px;
  font-size: 0.7rem;
  min-height: 2.05em;
  line-height: 1.2;
  align-items: flex-end;
  white-space: normal;
}

#modalOverlay .form-row {
  flex-wrap: wrap;
  row-gap: 1rem;
}

#modalOverlay .form-row .form-group {
  min-width: 108px;
}

#modalOverlay .form-control {
  background: rgba(255, 255, 255, 0.045) !important;
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 14px;
  color: #f5f5f5 !important;
  padding: 0.85rem 1rem;
  transition: all 0.2s ease;
}

#modalOverlay .form-control::placeholder {
  color: #5c6b80;
}

#modalOverlay .form-control:focus {
  background: rgba(255, 255, 255, 0.07) !important;
  border-color: #10b981;
  box-shadow: 0 0 0 3px rgba(16, 185, 129, 0.15);
}

#modalOverlay .form-control:disabled {
  opacity: 0.35;
}

#modalOverlay select.form-control option {
  background-color: #141926;
}

/* --- Checkbox kartı --- */
#modalOverlay .checkbox-label {
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 14px;
  padding: 0.75rem 1rem;
  transition: all 0.2s ease;
}
#modalOverlay .checkbox-label:hover {
  background: rgba(255, 255, 255, 0.07);
  border-color: rgba(16, 185, 129, 0.35);
}

/* --- Butonlar --- */
#modalOverlay .btn {
  border-radius: 14px;
  padding: 0.85rem 1.2rem;
  transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
}

#modalOverlay .btn-save {
  background: linear-gradient(135deg, #10b981, #0d9668);
  box-shadow: 0 8px 20px rgba(16, 185, 129, 0.3);
}
#modalOverlay .btn-save:hover { transform: translateY(-2px); box-shadow: 0 10px 26px rgba(16, 185, 129, 0.4); }
#modalOverlay .btn-save:active { transform: translateY(0); }

#modalOverlay .btn-cancel {
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 14px;
}
#modalOverlay .btn-cancel:hover { background: rgba(255, 255, 255, 0.08); }

#modalOverlay .btn-outline {
  border: 1px solid rgba(255, 255, 255, 0.14);
  border-radius: 14px;
  background: rgba(255, 255, 255, 0.03);
}
#modalOverlay .btn-outline:hover {
  border-color: #10b981;
  color: #10b981;
  background: rgba(16, 185, 129, 0.08);
}

#modalOverlay #btnEmanetVer {
  border-radius: 14px;
  background: rgba(255, 152, 0, 0.08);
}
#modalOverlay #btnEmanetVer:hover {
  background: rgba(255, 152, 0, 0.18);
  transform: translateY(-1px);
}

#modalOverlay .modal-actions {
  border-top: 1px solid rgba(255, 255, 255, 0.08);
  padding-top: 16px;
}

/* --- Tüketim Modu (SKT) alt-form: rozetler, sıklık çipleri, ipucu --- */
.skt-opsiyonel-etiket,
.skt-zorunlu-etiket {
  display: inline-flex;
  align-items: center;
  font-size: 0.65rem;
  font-weight: 700;
  letter-spacing: 0.3px;
  text-transform: none;
  padding: 2px 8px;
  border-radius: 999px;
  margin-left: 2px;
}

.skt-opsiyonel-etiket {
  background: rgba(148, 163, 184, 0.15);
  color: #94a3b8;
  border: 1px solid rgba(148, 163, 184, 0.3);
}

.skt-zorunlu-etiket {
  background: rgba(245, 158, 11, 0.15);
  color: #f59e0b;
  border: 1px solid rgba(245, 158, 11, 0.35);
}

.skt-category-fields {
  animation: sktAlanFadeIn 0.25s ease;
}
@keyframes sktAlanFadeIn {
  from { opacity: 0; transform: translateY(4px); }
  to { opacity: 1; transform: translateY(0); }
}

.skt-siklik-gunler-satiri {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
  margin-bottom: 1rem;
}

.skt-siklik-gun-btn {
  flex: 1;
  min-width: 70px;
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid rgba(255, 255, 255, 0.1);
  color: #8fa0b5;
  font-size: 0.8rem;
  font-weight: 600;
  padding: 8px 10px;
  border-radius: 12px;
  cursor: pointer;
  transition: all 0.2s ease;
}

.skt-siklik-gun-btn:hover {
  border-color: rgba(255, 255, 255, 0.25);
  color: #fff;
}

.skt-siklik-gun-btn.active {
  background: linear-gradient(135deg, rgba(16, 185, 129, 0.25), rgba(16, 185, 129, 0.08));
  border-color: #10b981;
  color: #10b981;
  box-shadow: 0 0 12px rgba(16, 185, 129, 0.3);
}

.skt-freshness-hint {
  background: rgba(59, 130, 246, 0.08);
  border: 1px solid rgba(59, 130, 246, 0.25);
  color: #93c5fd;
  font-size: 0.78rem;
  font-weight: 600;
  padding: 10px 14px;
  border-radius: 12px;
  margin-bottom: 14px;
  text-align: center;
}

#modalOverlay #imagePreviewBox img,
#modalOverlay #sktFotoOnizlemeKutu img {
  border-radius: 14px !important;
  border: 1px solid rgba(255, 255, 255, 0.12) !important;
}

/* ==========================================
   LIGHTBOX (Fotoğraf Tam Ekran Önizleme) - Konumlandırma Düzeltmesi
   ========================================== */
#lightboxOverlay {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background-color: rgba(0, 0, 0, 0.85);
  display: none;
  align-items: center;
  justify-content: center;
  padding: 20px;
  box-sizing: border-box;
  /* Boş alana dokununca mavi metin-seçim vurgusu çıkmasın */
  -webkit-tap-highlight-color: transparent;
  user-select: none;
  -webkit-user-select: none;
}

#lightboxOverlay.active {
  display: flex;
}

#lightboxOverlay #lightboxImg {
  max-width: 90vw;
  max-height: 90vh;
  width: auto;
  height: auto;
  object-fit: contain;
  margin: auto;
  border-radius: 12px;
  box-shadow: 0 10px 40px rgba(0, 0, 0, 0.6);
  -webkit-tap-highlight-color: transparent;
  user-select: none;
  -webkit-user-select: none;
}

/* ═══════════════════════════════════════════════════════════════════
   Kategori İkonu Seçici (ürün ekleme formu + yönetim penceresi)
   ═══════════════════════════════════════════════════════════════════ */
.cat-icon-badge-btn {
  flex: 0 0 auto;
  width: 42px;
  height: 42px;
  border-radius: 8px;
  border: 1px solid var(--border-color);
  background-color: rgba(255,255,255,0.05);
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  padding: 0;
}
.cat-icon-badge-btn:active { background-color: rgba(76, 175, 80, 0.15); }
.cat-icon-badge-btn img { width: 26px; height: 26px; object-fit: contain; }
.cat-icon-badge-btn.empty { opacity: 0.35; }
.cat-icon-badge-btn.empty::after { content: '＋'; font-size: 1.1rem; color: var(--text-muted); }

.cat-icon-tabs {
  display: flex;
  gap: 0.4rem;
  overflow-x: auto;
  padding-bottom: 0.6rem;
  margin-bottom: 0.6rem;
  border-bottom: 1px solid var(--border-color);
}
.cat-icon-tab {
  flex: 0 0 auto;
  padding: 0.4rem 0.8rem;
  border-radius: 20px;
  border: 1px solid var(--border-color);
  background: rgba(255,255,255,0.05);
  color: var(--text-muted);
  font-size: 0.8rem;
  cursor: pointer;
  white-space: nowrap;
}
.cat-icon-tab.active {
  background-color: var(--primary-color);
  color: #fff;
  border-color: var(--primary-color);
  font-weight: bold;
}

.cat-icon-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(58px, 1fr));
  gap: 0.6rem;
  overflow-y: auto;
  padding: 0.2rem;
}
.cat-icon-cell {
  width: 58px;
  height: 58px;
  border-radius: 10px;
  border: 1px solid var(--border-color);
  background: rgba(255,255,255,0.05);
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  padding: 0;
}
.cat-icon-cell img { width: 34px; height: 34px; object-fit: contain; }
.cat-icon-cell.selected {
  border-color: var(--primary-color);
  background-color: rgba(76, 175, 80, 0.18);
  box-shadow: 0 0 0 2px var(--primary-color) inset;
}
.cat-icon-cell.icon-missing::after {
  content: '🖼️';
  font-size: 1.3rem;
  opacity: 0.4;
}
