/* ============================================================
   SERVIS PLANLAMA — ANA STİL DOSYASI
   ============================================================ */

/* --- Değişkenler --- */
:root {
  --primary: #3949ab;
  --primary-dark: #1a237e;
  --primary-light: #e8eaf6;
  --success: #2e7d32;
  --success-light: #e8f5e9;
  --danger: #c62828;
  --danger-light: #ffebee;
  --warning: #f57f17;
  --warning-light: #fff8e1;
  --info: #0277bd;
  --info-light: #e1f5fe;
  --muted: #757575;
  --muted-light: #f5f5f5;
  --border: #e0e0e0;
  --shadow: 0 2px 8px rgba(0,0,0,.1);
  --shadow-lg: 0 4px 20px rgba(0,0,0,.15);
  --radius: 8px;
  --radius-sm: 4px;
  --font: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
}

/* --- Reset --- */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
body { font-family: var(--font); background: #f0f2f5; color: #212121; font-size: 14px; }
a { color: var(--primary); text-decoration: none; }
input, select, textarea, button { font-family: inherit; }

/* --- Navbar --- */
.navbar {
  background: linear-gradient(135deg, var(--primary-dark) 0%, var(--primary) 100%);
  color: white;
  display: flex;
  align-items: center;
  padding: 0 20px;
  height: 56px;
  box-shadow: 0 2px 8px rgba(0,0,0,.25);
  position: sticky;
  top: 0;
  z-index: 100;
}
.nav-brand {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 16px;
  font-weight: 700;
  letter-spacing: .5px;
  margin-right: 32px;
}
.nav-icon { font-size: 22px; }
.nav-links { display: flex; gap: 4px; flex: 1; }
.nav-link {
  color: rgba(255,255,255,.85);
  padding: 8px 14px;
  border-radius: var(--radius-sm);
  font-size: 13px;
  transition: all .2s;
}
.nav-link:hover, .nav-link.active {
  background: rgba(255,255,255,.2);
  color: white;
}
.nav-user { display: flex; align-items: center; gap: 12px; }
.user-badge { font-size: 13px; opacity: .85; }
.btn-logout {
  color: rgba(255,255,255,.8);
  font-size: 13px;
  padding: 5px 12px;
  border: 1px solid rgba(255,255,255,.4);
  border-radius: var(--radius-sm);
  transition: all .2s;
}
.btn-logout:hover { background: rgba(255,255,255,.2); color: white; }

/* --- Main Content --- */
.main-content { padding: 24px; max-width: 1600px; margin: 0 auto; }

/* --- Page Header --- */
.page-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 20px;
  flex-wrap: wrap;
  gap: 12px;
}
.page-title { font-size: 20px; font-weight: 700; color: var(--primary-dark); }
.page-subtitle { color: var(--muted); font-size: 13px; margin-top: 2px; }
.header-actions { display: flex; gap: 8px; align-items: center; flex-wrap: wrap; }

/* --- Buttons --- */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  padding: 8px 16px;
  border-radius: var(--radius-sm);
  border: none;
  cursor: pointer;
  font-size: 13px;
  font-weight: 500;
  transition: all .2s;
  white-space: nowrap;
}
.btn:active { transform: scale(.97); }
.btn-primary { background: var(--primary); color: white; }
.btn-primary:hover { background: var(--primary-dark); }
.btn-success { background: var(--success); color: white; }
.btn-success:hover { background: #1b5e20; }
.btn-danger { background: var(--danger); color: white; }
.btn-danger:hover { background: #b71c1c; }
.btn-outline {
  background: white;
  color: var(--primary);
  border: 1px solid var(--primary);
}
.btn-outline:hover { background: var(--primary-light); }
.btn-sm { padding: 5px 10px; font-size: 12px; }
.btn-full { width: 100%; justify-content: center; }
.btn:disabled { opacity: .5; cursor: not-allowed; }

/* --- Forms --- */
.form-control {
  width: 100%;
  padding: 8px 10px;
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  font-size: 13px;
  background: white;
  transition: border-color .2s;
}
.form-control:focus { outline: none; border-color: var(--primary); box-shadow: 0 0 0 3px rgba(57,73,171,.1); }
.form-group { margin-bottom: 14px; }
.form-group label { display: block; margin-bottom: 5px; font-size: 12px; font-weight: 600; color: #555; }
.form-row { display: flex; gap: 12px; }
.form-sm { padding: 5px 8px; font-size: 12px; }

/* --- Cards --- */
.card {
  background: white;
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  overflow: hidden;
}
.card-header {
  padding: 14px 16px;
  font-weight: 600;
  font-size: 14px;
  background: var(--primary-light);
  color: var(--primary-dark);
  border-bottom: 1px solid var(--border);
  display: flex;
  align-items: center;
  justify-content: space-between;
}
.mt-lg { margin-top: 24px; }
.mt-sm { margin-top: 8px; }

/* --- Tables --- */
.table { width: 100%; border-collapse: collapse; }
.table th {
  background: #f8f9fa;
  padding: 10px 12px;
  text-align: left;
  font-size: 12px;
  font-weight: 700;
  color: var(--muted);
  border-bottom: 2px solid var(--border);
  text-transform: uppercase;
  letter-spacing: .5px;
}
.table td {
  padding: 9px 12px;
  border-bottom: 1px solid var(--border);
  font-size: 13px;
}
.table tr:hover td { background: #fafbff; }
.table-sm th, .table-sm td { padding: 6px 10px; font-size: 12px; }
.action-cell { display: flex; gap: 4px; }

/* --- Badges --- */
.badge {
  display: inline-block;
  padding: 3px 8px;
  border-radius: 12px;
  font-size: 11px;
  font-weight: 600;
}
.badge-success { background: var(--success-light); color: var(--success); }
.badge-danger { background: var(--danger-light); color: var(--danger); }
.badge-warning { background: var(--warning-light); color: var(--warning); }
.badge-info { background: var(--info-light); color: var(--info); }
.badge-muted { background: var(--muted-light); color: var(--muted); }

/* --- Durum Filtre Butonları --- */
.durum-filtre-grup { display: flex; gap: 4px; }
.durum-filtre-btn { background: var(--bg-secondary); color: var(--text-secondary); border: 1px solid var(--border); border-radius: 4px; padding: 3px 10px; font-size: 12px; cursor: pointer; transition: all .15s; }
.durum-filtre-btn:hover { background: var(--primary-light); color: var(--primary); border-color: var(--primary); }
.durum-filtre-btn.aktif-filtre { background: var(--primary); color: #fff; border-color: var(--primary); }

/* --- Tabs --- */
.tabs { display: flex; gap: 4px; margin-bottom: 16px; border-bottom: 2px solid var(--border); }
.tab-btn {
  padding: 10px 20px;
  border: none;
  background: transparent;
  cursor: pointer;
  font-size: 13px;
  font-weight: 500;
  color: var(--muted);
  border-radius: var(--radius-sm) var(--radius-sm) 0 0;
  transition: all .2s;
  margin-bottom: -2px;
  border-bottom: 2px solid transparent;
}
.tab-btn:hover { color: var(--primary); background: var(--primary-light); }
.tab-btn.active { color: var(--primary); border-bottom-color: var(--primary); background: white; }
.tab-content.hidden { display: none; }

/* --- Inline Add --- */
.inline-add {
  display: flex;
  gap: 6px;
  padding: 10px 12px;
  background: #fafbff;
  border-bottom: 1px solid var(--border);
}

/* --- Flash Alerts --- */
.flash-container { margin-bottom: 16px; }
.alert {
  padding: 10px 14px;
  border-radius: var(--radius-sm);
  font-size: 13px;
  margin-bottom: 6px;
  transition: opacity .5s;
}
.alert-success { background: var(--success-light); color: var(--success); border-left: 3px solid var(--success); }
.alert-danger { background: var(--danger-light); color: var(--danger); border-left: 3px solid var(--danger); }
.alert-info { background: var(--info-light); color: var(--info); border-left: 3px solid var(--info); }
.alert-warning { background: var(--warning-light); color: var(--warning); border-left: 3px solid var(--warning); }

/* --- Modal --- */
.modal-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,.5);
  z-index: 200;
}
.modal {
  position: fixed;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  background: white;
  border-radius: var(--radius);
  box-shadow: var(--shadow-lg);
  z-index: 300;
  width: 90%;
  max-width: 480px;
  max-height: 90vh;
  overflow-y: auto;
}
.modal-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 16px 20px;
  border-bottom: 1px solid var(--border);
  font-weight: 700;
  font-size: 16px;
}
.modal-close {
  background: none;
  border: none;
  font-size: 18px;
  cursor: pointer;
  color: var(--muted);
  padding: 2px 6px;
  border-radius: 4px;
}
.modal-close:hover { background: var(--danger-light); color: var(--danger); }
.modal-body { padding: 20px; }
.modal-footer { display: flex; justify-content: flex-end; gap: 8px; margin-top: 16px; }
.hidden { display: none !important; }

/* --- Toast --- */
#toast-container { position: fixed; bottom: 20px; right: 20px; z-index: 1000; display: flex; flex-direction: column; gap: 8px; }
.toast {
  padding: 12px 18px;
  border-radius: var(--radius-sm);
  color: white;
  font-size: 13px;
  font-weight: 500;
  opacity: 0;
  transform: translateX(100%);
  transition: all .3s;
  min-width: 200px;
  box-shadow: var(--shadow-lg);
}
.toast.show { opacity: 1; transform: none; }
.toast-success { background: var(--success); }
.toast-error { background: var(--danger); }
.toast-warning { background: var(--warning); }
.toast-info { background: var(--info); }

/* --- Login --- */
.login-page { background: linear-gradient(135deg, #1a237e 0%, #3949ab 100%); min-height: 100vh; display: flex; align-items: center; justify-content: center; }
.login-wrapper { width: 100%; max-width: 400px; padding: 20px; }
.login-card { background: white; border-radius: 12px; padding: 40px; box-shadow: 0 8px 32px rgba(0,0,0,.3); }
.login-logo { text-align: center; font-size: 48px; margin-bottom: 12px; }
.login-title { text-align: center; font-size: 22px; font-weight: 700; color: var(--primary-dark); margin-bottom: 6px; }
.login-subtitle { text-align: center; font-size: 12px; color: var(--muted); margin-bottom: 24px; }
.login-form .form-group { margin-bottom: 16px; }

/* ============================================================
   DASHBOARD
   ============================================================ */
.ozet-kartlar { display: grid; grid-template-columns: repeat(7, 1fr); gap: 12px; margin-bottom: 24px; }
.ozet-kart {
  background: white;
  border-radius: var(--radius);
  padding: 16px 12px;
  box-shadow: var(--shadow);
  text-align: center;
  border-top: 4px solid var(--primary);
}
.ozet-kart.ozet-mavi    { border-top-color: #3949ab; }
.ozet-kart.ozet-yesil   { border-top-color: var(--success); }
.ozet-kart.ozet-gri     { border-top-color: #9e9e9e; }
.ozet-kart.ozet-sari    { border-top-color: var(--warning); }
.ozet-kart.ozet-kirmizi { border-top-color: var(--danger); }
.ozet-sayi { font-size: 28px; font-weight: 700; color: var(--primary-dark); }
.ozet-sayi { font-size: 32px; font-weight: 700; color: var(--primary-dark); }
.ozet-etiket { font-size: 12px; color: var(--muted); margin-top: 4px; text-transform: uppercase; letter-spacing: .5px; }

.gantt-container { background: white; border-radius: var(--radius); padding: 20px; box-shadow: var(--shadow); }
.gantt-legend { display: flex; gap: 16px; margin-bottom: 16px; flex-wrap: wrap; }
.legend-item {
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: 12px;
  color: #555;
}
.legend-item::before { content: ''; display: inline-block; width: 14px; height: 14px; border-radius: 3px; }
.legend-planli::before { background: #3949ab; }
.legend-aktif::before { background: #2e7d32; }
.legend-tamamlandi::before { background: #9e9e9e; }
.legend-belirsiz::before { background: #f57f17; }
.legend-iptal::before { background: #c62828; }
.gantt-empty { color: var(--muted); text-align: center; padding: 40px; font-size: 14px; }
.gantt-wrapper { position: relative; overflow-x: auto; }
#gantt-canvas { display: block; }
.gantt-tooltip {
  position: absolute;
  background: rgba(0,0,0,.85);
  color: white;
  padding: 8px 12px;
  border-radius: 6px;
  font-size: 12px;
  pointer-events: none;
  z-index: 50;
  max-width: 250px;
  line-height: 1.5;
}

/* ============================================================
   TALEP EKRANI
   ============================================================ */
.talep-layout { display: grid; grid-template-columns: 240px 1fr 240px; gap: 16px; align-items: start; }
.talep-panel { background: white; border-radius: var(--radius); box-shadow: var(--shadow); overflow: hidden; }
.panel-header {
  padding: 12px 14px;
  font-weight: 700;
  font-size: 13px;
  background: var(--primary-light);
  color: var(--primary-dark);
  border-bottom: 1px solid var(--border);
  display: flex;
  align-items: center;
  justify-content: space-between;
}
.liste-container { max-height: 480px; overflow-y: auto; }
.liste-item {
  padding: 9px 14px;
  border-bottom: 1px solid var(--border);
  cursor: pointer;
  font-size: 13px;
  display: flex;
  align-items: center;
  gap: 6px;
  transition: background .15s;
  user-select: none;
}
.liste-item:hover { background: var(--primary-light); }
.liste-item.secili { background: var(--primary); color: white; font-weight: 600; }
.liste-item-alt { font-size: 11px; color: var(--muted); margin-top: 2px; }
.secili-sorumlu {
  padding: 9px 12px;
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  background: #fafbff;
  font-size: 13px;
  min-height: 38px;
  color: var(--muted);
}
.secili-sorumlu.selected { color: var(--primary-dark); font-weight: 600; background: var(--primary-light); border-color: var(--primary); }
.durak-sira-baslik {
  display: flex;
  gap: 6px;
  padding: 7px 14px;
  background: #f8f9fa;
  font-size: 11px;
  font-weight: 700;
  color: var(--muted);
  border-bottom: 1px solid var(--border);
  text-transform: uppercase;
}
.sortable-list { padding: 6px; min-height: 80px; }
.sortable-item {
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 6px 8px;
  background: white;
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  margin-bottom: 4px;
  cursor: grab;
  transition: box-shadow .15s;
}
.sortable-item:hover { box-shadow: var(--shadow); }
.sortable-item.sortable-chosen { box-shadow: 0 4px 12px rgba(0,0,0,.2); opacity: .9; }
.sortable-item-handle { color: var(--muted); font-size: 14px; cursor: grab; }
.sortable-item-adi { flex: 2; font-size: 13px; font-weight: 500; }
.sortable-item-saat { width: 80px; }
.sortable-item-kisi { width: 80px; }
.sortable-item-del { width: 28px; background: none; border: none; color: var(--danger); cursor: pointer; font-size: 16px; padding: 2px; }
.form-actions { padding: 12px 14px; border-top: 1px solid var(--border); background: #fafbff; }

/* ── ARAMA INPUT ─────────────────────────────────────────────────────────── */
.arama-wrapper {
  padding: 6px 10px;
  background: #fafbff;
  border-bottom: 1px solid var(--border);
}
.panel-filtre {
  padding: 6px 10px;
  background: #fafbff;
  border-bottom: 1px solid var(--border);
}
.panel-filtre select { width: 100%; }
.arama-wrapper input.form-control {
  background: white url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='14' height='14' viewBox='0 0 24 24' fill='none' stroke='%23999' stroke-width='2'%3E%3Ccircle cx='11' cy='11' r='8'/%3E%3Cpath d='m21 21-4.35-4.35'/%3E%3C/svg%3E") no-repeat 8px center;
  padding-left: 28px;
  font-size: 12px;
}
.arama-wrapper select.form-control {
  font-size: 12px;
}

/* ── GÜN SEÇİMİ ─────────────────────────────────────────────────────────── */
.gun-secim-bolum {
  border-top: 1px solid var(--border);
  padding: 10px 14px;
  background: #fafbff;
}
.gun-secim-baslik {
  display: flex;
  align-items: center;
  justify-content: space-between;
  font-size: 12px;
  font-weight: 700;
  color: var(--primary-dark);
  margin-bottom: 8px;
}
.gun-checkboxlar {
  display: grid;
  grid-template-columns: repeat(7, 1fr);
  gap: 4px;
}
.gun-checkbox-item {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 3px;
  padding: 6px 4px;
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  cursor: pointer;
  background: white;
  transition: all .15s;
  text-align: center;
}
.gun-checkbox-item:has(input:checked) {
  background: var(--primary-light);
  border-color: var(--primary);
}
.gun-checkbox-item input { margin: 0; accent-color: var(--primary); }
.gun-adi { font-size: 11px; font-weight: 700; color: var(--primary-dark); white-space: nowrap; }
.gun-tarih { font-size: 10px; color: var(--muted); white-space: nowrap; overflow: hidden; width: 100%; text-align: center; }

/* Düzenleme modu bilgi barı */
.duzenle-tarih-bilgi {
  background: var(--warning-light);
  border-left: 3px solid var(--warning);
  padding: 8px 14px;
  font-size: 12px;
  color: #7b4f00;
  display: flex;
  align-items: center;
  gap: 8px;
}

/* Toplam kişi barı */
.toplam-kisi-bar {
  padding: 7px 14px;
  background: var(--muted-light);
  border-top: 1px solid var(--border);
  border-bottom: 1px solid var(--border);
  font-size: 13px;
  font-weight: 600;
  color: var(--muted);
}

/* ============================================================
   PLANLAMA EKRANI
   ============================================================ */
.planlama-layout { display: grid; grid-template-columns: 260px 1fr 260px; gap: 16px; align-items: start; }
.plan-sol, .plan-sag {
  background: white;
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  overflow: hidden;
}
.plan-orta {
  background: white;
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  overflow: hidden;
}
.durak-kartlar { padding: 8px; max-height: 600px; overflow-y: auto; }
.durak-kart {
  background: white;
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  margin-bottom: 6px;
  overflow: hidden;
  transition: all .2s;
}
.durak-kart.tamamlandi { border-color: var(--success); opacity: .6; }
.durak-kart-baslik {
  display: flex;
  align-items: center;
  padding: 9px 12px;
  cursor: pointer;
  font-size: 13px;
  gap: 8px;
  justify-content: space-between;
}
.durak-kart-baslik:hover { background: #fafbff; }
.durak-kart-adi { font-weight: 600; flex: 1; }
.durak-kart-kisi { font-size: 12px; color: var(--muted); }
.durak-kart-icerik { padding: 8px 12px; border-top: 1px solid var(--border); background: #fafbff; display: none; }
.durak-kart.acik .durak-kart-icerik { display: block; }
.grup-satiri { font-size: 12px; padding: 3px 0; color: #444; display: flex; justify-content: space-between; }
.durak-kart-droppable { border: 2px dashed #aaa; background: #fafafa; }

.arac-plan-listesi { padding: 8px; max-height: 600px; overflow-y: auto; }
.arac-plan-kart {
  background: white;
  border: 2px solid var(--border);
  border-radius: var(--radius-sm);
  padding: 10px 12px;
  margin-bottom: 6px;
  cursor: pointer;
  transition: all .2s;
}
.arac-plan-kart:hover { border-color: var(--primary); background: var(--primary-light); }
.arac-plan-kart.secili { border-color: var(--primary); background: var(--primary-light); }

/* Yeni durum kartları */
.arac-karti {
  border-radius: var(--radius-sm);
  padding: 10px 12px;
  margin-bottom: 6px;
  cursor: pointer;
  border-left: 4px solid transparent;
  border: 2px solid var(--border);
  border-left-width: 4px;
  transition: box-shadow .2s, border-color .2s;
}
.arac-karti:hover { box-shadow: 0 2px 8px rgba(0,0,0,.12); }
.arac-karti.secili { box-shadow: 0 0 0 2px var(--primary); }
.arac-duzenleme { border-left-color: #f57c00; background: #fffbf2; }
.arac-bos       { border-left-color: #388e3c; background: #f5fdf5; }
.tamamlandi-bilgi { font-size: 11px; color: #888; margin: 3px 0; }
.rozet { padding: 2px 7px; border-radius: 10px; font-size: 10px; font-weight: 700; }
.rozet-turuncu  { background: #fff3e0; color: #e65100; }
.rozet-yesil    { background: #e8f5e9; color: #2e7d32; }
.rozet-kirmizi  { background: var(--danger-light); color: var(--danger); }
.arac-plan-plaka { font-weight: 700; font-size: 14px; color: var(--primary-dark); }
.arac-plan-sofor { font-size: 12px; color: var(--muted); }
.kapasite-bar-container { margin-top: 6px; }
.kapasite-bar {
  height: 6px;
  background: var(--border);
  border-radius: 3px;
  overflow: hidden;
}
.kapasite-bar-dolu {
  height: 100%;
  background: var(--success);
  border-radius: 3px;
  transition: width .3s;
}
.kapasite-bar-dolu.kritik { background: var(--danger); }
.kapasite-bar-dolu.orta { background: var(--warning); }
.kapasite-label { font-size: 11px; color: var(--muted); margin-top: 2px; }

.secili-arac-bos {
  padding: 40px 20px;
  text-align: center;
  color: var(--muted);
  font-size: 14px;
}
.guzergah-container { padding: 14px; }
.guzergah-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 10px 14px;
  background: var(--primary-light);
  border-bottom: 1px solid var(--border);
  font-weight: 700;
  font-size: 14px;
  color: var(--primary-dark);
}
.guzergah-list { min-height: 100px; }
.doluluk-badge {
  font-size: 12px;
  padding: 3px 8px;
  border-radius: 10px;
  background: var(--primary);
  color: white;
}

.mevcut-plan { padding: 16px; }
.mevcut-arac-blok {
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  margin-bottom: 12px;
  overflow: hidden;
}
.mevcut-arac-baslik {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 10px 14px;
  background: #f8f9fa;
  font-weight: 600;
  font-size: 13px;
}
.mevcut-durak-listesi { padding: 8px 14px; }
.mevcut-durak { font-size: 12px; padding: 3px 0; display: flex; gap: 8px; }
.mevcut-durak-saat { color: var(--primary); font-weight: 600; min-width: 40px; }
.mevcut-durak-adi { flex: 1; }
.mevcut-durak-kisi { color: var(--muted); }

/* ============================================================
   ARŞİV
   ============================================================ */
.arsiv-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(240px, 1fr));
  gap: 16px;
}
.arsiv-kart {
  background: white;
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  padding: 16px;
  transition: box-shadow .2s;
}
.arsiv-kart:hover { box-shadow: var(--shadow-lg); }
.arsiv-tarih { font-size: 20px; font-weight: 700; color: var(--primary-dark); margin-bottom: 8px; }
.arsiv-ozet { display: flex; gap: 12px; font-size: 13px; color: var(--muted); margin-bottom: 12px; }
.arsiv-actions { display: flex; gap: 6px; flex-wrap: wrap; }
.arsiv-arac-blok { margin-bottom: 16px; border: 1px solid var(--border); border-radius: var(--radius-sm); overflow: hidden; }
.arsiv-arac-baslik {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 8px 12px;
  background: var(--primary-light);
  font-weight: 600;
  font-size: 13px;
}
.bos-mesaj { text-align: center; color: var(--muted); padding: 40px; font-size: 14px; }
.loading { text-align: center; color: var(--muted); padding: 40px; }

/* ── Talep satır detay accordion ─────────────────────────────── */
.talep-ana-satir { cursor: pointer; }
.talep-ana-satir:hover { background: #f0f4ff; }
.talep-detay-satir td.talep-detay-icerik {
  background: #f8faff;
  border-top: none;
  padding: 8px 16px 10px 48px;
  border-bottom: 2px solid var(--primary-light);
}
.talep-durak-satir {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 3px 0;
  font-size: 12px;
  border-bottom: 1px dashed #e8ecf5;
}
.talep-durak-satir:last-of-type { border-bottom: none; }
.talep-durak-adi { flex: 1; color: #444; }
.talep-durak-kisi { min-width: 56px; text-align: right; color: var(--primary); font-weight: 600; }
.talep-durak-toplam {
  margin-top: 6px;
  padding-top: 6px;
  border-top: 1px solid #d0d9f0;
  font-size: 12px;
  text-align: right;
  color: #333;
}

@keyframes flash-yellow {
  0%   { background-color: transparent; }
  25%  { background-color: #fff59d; }
  100% { background-color: transparent; }
}
.guncellendi-flash { animation: flash-yellow 1.2s ease-out; }

/* ============================================================
   RESPONSIVE INPUT CLASSES
   ============================================================ */
.input-date { width: 160px; }
.input-time { width: 110px; }
.input-grup { width: 180px; }

/* ============================================================
   RESPONSIVE
   ============================================================ */

/* Tablo yatay kaydırma sarmalayıcı */
.table-scroll {
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
}

/* Hamburger butonu — masaüstünde gizli */
.nav-hamburger {
  display: none;
  background: none;
  border: 1px solid rgba(255,255,255,.4);
  color: white;
  font-size: 20px;
  line-height: 1;
  padding: 6px 12px;
  border-radius: var(--radius-sm);
  cursor: pointer;
  margin-left: auto;
  flex-shrink: 0;
}
/* Mobil için menüde çıkış linki — masaüstünde gizli */
.nav-link-mobil-cikis { display: none; }

/* ── 1200px — Geniş Tablet ─────────────────────────────────── */
@media (max-width: 1200px) {
  .talep-layout    { grid-template-columns: 200px 1fr 200px; }
  .planlama-layout { grid-template-columns: 220px 1fr 220px; }
  .ozet-kartlar    { grid-template-columns: repeat(4, 1fr); }
}

/* ── 900px — Tablet ─────────────────────────────────────────── */
@media (max-width: 900px) {
  .main-content { padding: 14px; }

  /* Navbar: hamburger */
  .navbar { position: relative; }
  .nav-hamburger { display: inline-flex; align-items: center; justify-content: center; }
  .nav-user { display: none; }
  .nav-links {
    display: none;
    position: absolute;
    top: 56px;
    left: 0;
    right: 0;
    background: var(--primary-dark);
    flex-direction: column;
    padding: 6px 8px;
    gap: 2px;
    z-index: 200;
    box-shadow: 0 6px 16px rgba(0,0,0,.35);
  }
  .nav-links.acik { display: flex; }
  .nav-links .nav-link { padding: 12px 16px; font-size: 14px; border-radius: var(--radius-sm); }
  .nav-link-mobil-cikis {
    display: block;
    border-top: 1px solid rgba(255,255,255,.15);
    margin-top: 4px;
    padding-top: 8px !important;
    color: rgba(255,255,255,.7) !important;
  }

  /* 3 panel → tek sütun */
  .talep-layout    { grid-template-columns: 1fr; }
  .planlama-layout { grid-template-columns: 1fr; }

  /* Talep: form önce gelsin */
  .talep-orta { order: 1; }
  .talep-sol  { order: 2; }
  .talep-sag  { order: 3; }

  /* Planlama: araç seçimi önce gelsin */
  .plan-sag  { order: 1; }
  .plan-orta { order: 2; }
  .plan-sol  { order: 3; }

  /* Panel max-height azalt */
  .liste-container   { max-height: 280px; }
  .durak-kartlar     { max-height: 320px; }
  .arac-plan-listesi { max-height: 320px; }

  /* Dashboard */
  .ozet-kartlar { grid-template-columns: repeat(4, 1fr); }

  /* Tabs wrap */
  .tabs { flex-wrap: wrap; }
}

/* ── 600px — Mobil ───────────────────────────────────────────── */
@media (max-width: 600px) {
  .main-content { padding: 10px; }
  .page-title   { font-size: 16px; }

  /* Dashboard: 7 kart → 2 sütun */
  .ozet-kartlar {
    grid-template-columns: repeat(2, 1fr);
    gap: 8px;
    margin-bottom: 16px;
  }
  .ozet-kart   { padding: 12px 8px; }
  .ozet-sayi   { font-size: 22px; }
  .ozet-etiket { font-size: 10px; }

  /* Gantt: touch scroll */
  .gantt-wrapper { overflow-x: auto; -webkit-overflow-scrolling: touch; }

  /* Sayfa başlığı */
  .page-header    { gap: 8px; margin-bottom: 14px; }
  .header-actions { gap: 6px; flex-wrap: wrap; }

  /* Responsive input genişlikleri */
  .input-date { width: 100%; max-width: 150px; }
  .input-time { width: 88px; }
  .input-grup { width: 150px; }
  .header-zaman-grup { display: flex; align-items: center; gap: 4px; flex-wrap: nowrap; }

  /* Buton boyutları: dokunma hedefi min 44px */
  .btn    { min-height: 44px; font-size: 12px; padding: 8px 12px; }
  .btn-sm { min-height: 34px; padding: 5px 10px; font-size: 11px; }

  /* Form satırları → dikey */
  .form-row { flex-direction: column; gap: 0; }

  /* Modal: alta yapışık bottom-sheet */
  .modal {
    width: 100%;
    max-width: 100%;
    top: auto;
    left: 0;
    bottom: 0;
    transform: none;
    border-radius: var(--radius) var(--radius) 0 0;
    max-height: 88vh;
  }

  /* Toast: sol alt */
  #toast-container { left: 10px; right: 10px; bottom: 10px; }
  .toast { min-width: unset; width: 100%; }

  /* Arşiv grid: 2 sütun */
  .arsiv-grid   { grid-template-columns: 1fr 1fr; gap: 10px; }
  .arsiv-tarih  { font-size: 16px; }
  .arsiv-ozet   { font-size: 12px; }
  .arsiv-actions { gap: 4px; }
  .arsiv-actions .btn-sm { padding: 4px 8px; font-size: 10px; }

  /* Plan başlığı: sarmala */
  .mevcut-arac-baslik { flex-wrap: wrap; gap: 6px; }

  /* Gün checkboxları: daha küçük */
  .gun-adi   { font-size: 9px; }
  .gun-tarih { font-size: 8px; }
  .gun-checkbox-item { padding: 5px 2px; }

  /* Planlama: güzergah başlık sarmala */
  .guzergah-header { flex-wrap: wrap; gap: 6px; }

  /* Tab butonları küçük */
  .tab-btn { padding: 8px 14px; font-size: 12px; }
}

/* ── 400px — Küçük Mobil ─────────────────────────────────────── */
@media (max-width: 400px) {
  .input-date { max-width: 130px; }
  .input-time { width: 80px; }
  .ozet-kartlar { grid-template-columns: repeat(2, 1fr); }
  .arsiv-grid   { grid-template-columns: 1fr; }
  .page-header  { flex-direction: column; align-items: flex-start; }
  .tab-btn      { padding: 7px 10px; font-size: 11px; }
  .gun-adi      { font-size: 8px; }
  .gun-tarih    { display: none; } /* çok dar: tarihi gizle */
}

/* === FAZ 3: Mobil Adım Çubuğu === */
.adim-bar {
  display: none; /* Desktop'ta gizli */
}
.adim-btn {
  background: none;
  border: none;
  padding: 8px 14px;
  font-size: 13px;
  color: var(--muted);
  cursor: pointer;
  border-bottom: 3px solid transparent;
  font-weight: 500;
}
.adim-btn.aktif {
  color: var(--primary);
  border-bottom-color: var(--primary);
}
.adim-ayrac {
  color: #ccc;
  font-size: 16px;
  line-height: 1;
  align-self: center;
}
.aktif-arac-rozeti {
  background: #e8f5e9;
  border: 1px solid #a5d6a7;
  border-radius: 6px;
  padding: 5px 10px;
  font-size: 12px;
  color: #2e7d32;
  font-weight: 600;
  margin: 6px 10px 2px;
}

@media (max-width: 900px) {
  .adim-bar {
    display: flex;
    align-items: center;
    gap: 4px;
    background: #fff;
    border-bottom: 1px solid #e0e0e0;
    padding: 0 10px;
    overflow-x: auto;
  }
  /* Adım panellerini mobilde varsayılan gizle; aktif adım JS ile gösterilir */
  .adim-panel[data-adim="2"],
  .adim-panel[data-adim="3"] {
    display: none;
  }
  /* Güzergah kaydet butonu: daha büyük dokunma hedefi */
  .btn-success.btn-full {
    min-height: 50px;
    font-size: 15px;
  }
}

/* === FAZ 1: Zaman Dilimi Çakışma Şeridi === */
.zaman-strip {
  display: flex;
  gap: 1px;
  padding: 6px 10px 4px;
  background: #f8f9fc;
  border-bottom: 1px solid #e8eaf0;
  overflow: hidden;
}
.zaman-hucre {
  flex: 1;
  height: 14px;
  border-radius: 2px;
  background: #e8eaf0;
  position: relative;
  cursor: default;
  transition: background 0.2s;
}
.zaman-hucre:hover::after {
  content: attr(data-saat);
  position: absolute;
  bottom: 16px;
  left: 50%;
  transform: translateX(-50%);
  background: #333;
  color: #fff;
  font-size: 9px;
  padding: 2px 4px;
  border-radius: 3px;
  white-space: nowrap;
  pointer-events: none;
  z-index: 10;
}
.zaman-hucre.az { background: #a5d6a7; }
.zaman-hucre.yogun { background: #ffb74d; }
.zaman-hucre.kritik { background: #ef5350; }
