:root {
  --navy: #1e2a4a;
  --navy2: #24345c;
  --accent: #3b82f6;
  --ok: #16a34a;
  --hatali: #dc2626;
  --koyu-metin: #1f2937;
  --gri: #6b7280;
  --cizgi: #e5e7eb;
  --bg: #f1f5f9;
  --kart: #ffffff;
}

* { box-sizing: border-box; }
html, body { margin: 0; padding: 0; }
body {
  font-family: "Segoe UI", Arial, sans-serif;
  background: var(--bg);
  color: var(--koyu-metin);
  font-size: 14px;
}

/* ---- ÜST BAR ---- */
.topbar {
  display: flex; align-items: center; justify-content: space-between; gap: 16px;
  background: linear-gradient(135deg, var(--navy), var(--navy2));
  color: #fff; padding: 14px 24px; flex-wrap: wrap;
}
.brand { display: flex; align-items: center; gap: 12px; }
.logo { font-size: 34px; }
.brand-text h1 { margin: 0; font-size: 19px; }
.brand-text p { margin: 2px 0 0; font-size: 12px; opacity: .8; }
.nav { display: flex; gap: 6px; flex-wrap: wrap; }
.nav-btn {
  background: rgba(255,255,255,.1); color: #fff; border: 1px solid rgba(255,255,255,.25);
  padding: 8px 16px; border-radius: 8px; cursor: pointer; font-size: 14px;
}
.nav-btn:hover { background: rgba(255,255,255,.2); }
.nav-btn.active { background: #fff; color: var(--navy); font-weight: 600; }

main { max-width: 1100px; margin: 24px auto; padding: 0 16px; }

/* ---- SEKMELER ---- */
.tab { display: none; }
.tab.active { display: block; }

/* ---- KARTLAR ---- */
.card {
  background: var(--kart); border: 1px solid var(--cizgi); border-radius: 12px;
  margin-bottom: 18px; box-shadow: 0 1px 3px rgba(0,0,0,.06); overflow: hidden;
}
.card-header {
  display: flex; align-items: center; justify-content: space-between; gap: 10px;
  padding: 12px 18px; background: #fafbfc; border-bottom: 1px solid var(--cizgi);
}
.card-header strong { font-size: 15px; }
.card-body { padding: 16px 18px; }

.badge {
  background: var(--accent); color: #fff; font-size: 12px; padding: 3px 10px;
  border-radius: 999px; white-space: nowrap;
}
.badge-muted { background: #e5e7eb; color: #374151; }
.badge-ok { background: #dcfce7; color: #166534; }
.badge-hata { background: #fee2e2; color: #991b1b; }
.badge-puan { background: #fef3c7; color: #92400e; }

/* ---- ARAÇ ÇUBUĞU / FİLTRE ---- */
.toolbar { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; margin-bottom: 14px; }
.toolbar-hint { font-size: 12px; color: var(--ok); }
.filters { display: flex; gap: 12px; flex-wrap: wrap; margin-bottom: 12px; }
.filtre-grup { display: flex; flex-direction: column; gap: 4px; flex: 1; min-width: 150px; }
.filtre-grup label { font-size: 12px; color: var(--gri); font-weight: 600; }
.filtre-ara input, .filtre-grup input, .filtre-grup select, .filtre-grup textarea {
  border: 1px solid var(--cizgi); border-radius: 8px; padding: 8px 10px; font-size: 14px;
  font-family: inherit; background: #fff; width: 100%;
}
.filtre-grup textarea { resize: vertical; }
.hint { font-size: 11px; color: var(--gri); }
.grid2 { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; margin-bottom: 12px; }

.check { display: flex; align-items: center; gap: 4px; font-size: 13px; padding-top: 30px; cursor: pointer; }
.check input[type="checkbox"] { margin: 0; width: 16px; height: 16px; accent-color: #2563eb; }

/* ---- BUTONLAR ---- */
.btn {
  border: 1px solid transparent; border-radius: 8px; padding: 8px 16px; cursor: pointer;
  font-size: 14px; font-family: inherit; display: inline-flex; align-items: center; gap: 6px;
}
.btn-primary { background: var(--accent); color: #fff; }
.btn-primary:hover { background: #2f6fe0; }
.btn-outline { background: #fff; border-color: var(--cizgi); color: var(--koyu-metin); }
.btn-outline:hover { background: #f3f4f6; }
.btn-danger { background: var(--hatali); color: #fff; }
.btn-danger:hover { background: #b91c1c; }
.btn-yenitest { background: linear-gradient(135deg, #2563eb, #7c3aed); color: #fff; border: none; box-shadow: 0 4px 14px rgba(59,130,246,.35); }
.btn-yenitest:hover { background: linear-gradient(135deg, #1d4ed8, #6d28d9); box-shadow: 0 6px 18px rgba(59,130,246,.5); }
.btn-sm { padding: 4px 10px; font-size: 12px; }

/* ---- TABLO ---- */
.table-wrap { overflow-x: auto; }
table { width: 100%; border-collapse: collapse; font-size: 13px; }
th, td { text-align: left; padding: 9px 10px; border-bottom: 1px solid var(--cizgi); vertical-align: top; }
th { background: #f8fafc; font-size: 12px; color: var(--gri); }
tr:hover td { background: #f8fafc; }
tr.secili td { background: #eff6ff; }
.secim-kutu { width: 16px; height: 16px; accent-color: var(--accent); margin: 0; cursor: pointer; }
.secim-bar { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; margin-bottom: 12px; padding: 10px 12px; border: 1px dashed var(--cizgi); border-radius: 10px; background: #f8fafc; }
.secim-ders { flex: 1; min-width: 220px; max-width: 360px; }
.bitti-mesaj { margin: 12px 0; padding: 10px 14px; border-radius: 10px; background: #dcfce7; color: #166534; font-weight: 600; border: 1px solid #bbf7d0; }
.bos { text-align: center; color: var(--gri); padding: 28px; }
.soru-ozet { font-weight: 600; }
.soru-konu { font-size: 12px; color: var(--gri); font-style: italic; }
.islem { display: flex; gap: 6px; }
.islem .btn { padding: 4px 10px; font-size: 12px; }

/* ---- ZORLUK ETİKETLERİ ---- */
.z-or { display: inline-block; padding: 2px 8px; border-radius: 999px; font-size: 11px; }
.z-düşük { background: #dcfce7; color: #166534; }
.z-orta { background: #fef3c7; color: #92400e; }
.z-yüksek { background: #fee2e2; color: #991b1b; }

/* ---- ŞIKLAR ---- */
.sik {
  display: flex; align-items: flex-start; gap: 10px; width: 100%; text-align: left;
  border: 1px solid var(--cizgi); border-radius: 10px; padding: 12px 14px; margin-bottom: 8px;
  background: #fff; cursor: pointer; font-size: 14px; font-family: inherit;
}
.sik:hover { background: #f0f5ff; border-color: var(--accent); }
.sik .harf {
  min-width: 28px; height: 28px; border-radius: 50%; background: #eef2ff; color: #3730a3;
  display: inline-flex; align-items: center; justify-content: center; font-weight: 700;
}
.sik.secili { background: #dbeafe; border-color: var(--accent); }
.sik.dogru { background: #dcfce7; border-color: var(--ok); }
.sik.yanlis { background: #fee2e2; border-color: var(--hatali); }

/* ---- TEST ---- */
.progress { height: 8px; background: #e5e7eb; border-radius: 999px; overflow: hidden; margin-bottom: 16px; }
.progress-bar { height: 100%; background: var(--accent); width: 0; border-radius: 999px; transition: width .2s; }
.konu-etiketi { display: flex; gap: 6px; flex-wrap: wrap; margin-bottom: 10px; }
.soru-metin {
  font-size: 16px; line-height: 1.55; margin-bottom: 16px; white-space: pre-wrap;
  background: #f8fafc; border: 1px solid var(--cizgi); border-radius: 10px; padding: 14px;
}

/* ---- GERİ BİLDİRİM ---- */
.geribildirim {
  border-radius: 10px; padding: 14px; margin: 14px 0; font-size: 14px; line-height: 1.5;
}
.geribildirim.dogru { background: #f0fdf4; border: 1px solid #86efac; }
.geribildirim.yanlis { background: #fef2f2; border: 1px solid #fca5a5; }
.geribildirim .baslik { font-weight: 700; margin-bottom: 6px; }
.geribildirim .neden { margin-top: 8px; }
.geribildirim .neden strong { color: var(--accent); }

/* ---- RAPOR ---- */
.rapor-genel {
  display: grid; grid-template-columns: repeat(auto-fit, minmax(130px, 1fr)); gap: 12px; margin-bottom: 18px;
}
.rapor-kutu { background: #f8fafc; border: 1px solid var(--cizgi); border-radius: 10px; padding: 12px; text-align: center; }
.rapor-kutu .deger { font-size: 26px; font-weight: 700; }
.rapor-kutu .etiket { font-size: 12px; color: var(--gri); }
.rapor-soru { border: 1px solid var(--cizgi); border-radius: 10px; padding: 12px 14px; margin-bottom: 10px; }
.rapor-soru.dogru { border-left: 4px solid var(--ok); }
.rapor-soru.yanlis { border-left: 4px solid var(--hatali); background: #fffbfb; }
.rapor-soru .satir { margin: 3px 0; }
.aciklama-kutu { margin-top: 8px; padding: 9px 11px; background: #eef6ff; border-radius: 8px; font-size: 13px; }

.onizleme-bar { margin: 6px 0 2px; font-size: 13px; }
.onizleme-kutu {
  border: 1px dashed #cbd5e1; border-radius: 8px; padding: 10px 12px;
  background: #f8fafc; font-size: 14px; line-height: 1.6; max-height: 260px; overflow: auto;
}
.onizleme-kutu div,
.onizleme-kutu font,
.onizleme-kutu p { font-family: inherit; color: inherit; }

.giris-ekrani {
  position: fixed; inset: 0; z-index: 50;
  display: flex; align-items: center; justify-content: center;
  background: linear-gradient(135deg, #1e3a8a, #0f172a);
  padding: 16px;
}
.giris-kutu {
  background: #fff; border-radius: 14px; padding: 28px 26px; width: 100%; max-width: 360px;
  box-shadow: 0 20px 50px rgba(0,0,0,.3); text-align: center;
}
.giris-logo { font-size: 40px; margin-bottom: 6px; }
.giris-kutu h2 { margin: 0 0 8px; font-size: 20px; color: #0f172a; }
.giris-aciklama { margin: 0 0 14px; font-size: 13px; color: #6b7280; }
.giris-kutu input {
  width: 100%; box-sizing: border-box; padding: 10px 12px; margin-bottom: 10px;
  border: 1px solid #cbd5e1; border-radius: 8px; font-size: 15px;
}
.giris-kutu input:focus { outline: none; border-color: #2563eb; box-shadow: 0 0 0 3px rgba(37,99,235,.15); }
.giris-kutu button { width: 100%; }
.giris-kutu .hint { margin: 10px 0 0; font-size: 12px; }
.oturum { display: flex; align-items: center; gap: 8px; margin-left: 12px; }

.sil-menu { position: relative; display: inline-block; }
.sil-menu-acilir {
  position: absolute; top: calc(100% + 6px); right: 0; z-index: 30;
  background: #fff; border: 1px solid var(--cizgi); border-radius: 8px;
  box-shadow: 0 10px 25px rgba(0,0,0,.15); padding: 6px; min-width: 180px;
  display: flex; flex-direction: column; gap: 4px;
}
.sil-menu-item { text-align: left; width: 100%; border: 1px solid transparent; }
.sil-menu-item:hover { background: #f8fafc; border-color: var(--cizgi); }
.sil-menu-item:last-child { color: var(--hatali); }
.sil-menu-item:last-child:hover { background: #fee2e2; border-color: #fecaca; }

@media (max-width: 640px) {
  .grid2 { grid-template-columns: 1fr; }
  .topbar { flex-direction: column; align-items: flex-start; }
}