/* ==========================================================================
   ValleyOfTheCoders - Master Stylesheet (assets/style.css)
   ========================================================================== */

/* --- 1. CSS Değişkenleri & Temalar (Theme Palettes) --- */
:root {
  /* Varsayılan Aydınlık Mod */
  --bg-body: #f8fafc;
  --bg-surface: #ffffff;
  --bg-surface-secondary: #f1f5f9;
  --text-main: #0f172a;
  --text-muted: #64748b;
  --border-color: #e2e8f0;
  --border-hover: #cbd5e1;
  --card-shadow: 0 10px 25px -5px rgba(0, 0, 0, 0.05), 0 8px 10px -6px rgba(0, 0, 0, 0.02);
  --card-shadow-hover: 0 20px 35px -5px rgba(0, 0, 0, 0.1), 0 10px 15px -5px rgba(0, 0, 0, 0.04);
  
  /* Varsayılan Renk: Okyanus Mavisi */
  --primary: #2563eb;
  --primary-hover: #1d4ed8;
  --primary-light: #eff6ff;
  --primary-border: #bfdbfe;
  --primary-gradient: linear-gradient(135deg, #2563eb 0%, #3b82f6 100%);
}

/* Karanlık Mod (Dark Mode) */
html.dark-mode, body.dark-mode {
  --bg-body: #0b0f19;
  --bg-surface: #131b2e;
  --bg-surface-secondary: #1a243b;
  --text-main: #f8fafc;
  --text-muted: #94a3b8;
  --border-color: #23304d;
  --border-hover: #3b82f6;
  --card-shadow: 0 10px 30px rgba(0, 0, 0, 0.35);
  --card-shadow-hover: 0 20px 40px rgba(0, 0, 0, 0.55);
}

/* --- Renk Paletleri (Palettes) --- */
/* Purple (Default ERP) */
html[data-palette="purple"] { --primary: #7c3aed; --primary-hover: #6d28d9; --primary-light: rgba(124, 58, 237, 0.12); --primary-border: #7c3aed; --primary-gradient: linear-gradient(135deg, #7c3aed 0%, #8b5cf6 100%); }
html.dark-mode[data-palette="purple"], html[data-theme="dark"][data-palette="purple"] { --primary: #a855f7; --primary-hover: #9333ea; --primary-light: rgba(168, 85, 247, 0.18); --primary-border: #a855f7; --primary-gradient: linear-gradient(135deg, #a855f7 0%, #8b5cf6 100%); }

/* Blue */
html[data-palette="blue"] { --primary: #2563eb; --primary-hover: #1d4ed8; --primary-light: rgba(37, 99, 235, 0.12); --primary-border: #2563eb; --primary-gradient: linear-gradient(135deg, #2563eb 0%, #3b82f6 100%); }
html.dark-mode[data-palette="blue"], html[data-theme="dark"][data-palette="blue"] { --primary: #3b82f6; --primary-hover: #2563eb; --primary-light: rgba(59, 130, 246, 0.18); --primary-border: #3b82f6; --primary-gradient: linear-gradient(135deg, #3b82f6 0%, #2563eb 100%); }

/* Emerald */
html[data-palette="emerald"] { --primary: #059669; --primary-hover: #047857; --primary-light: rgba(5, 150, 105, 0.12); --primary-border: #059669; --primary-gradient: linear-gradient(135deg, #059669 0%, #10b981 100%); }
html.dark-mode[data-palette="emerald"], html[data-theme="dark"][data-palette="emerald"] { --primary: #10b981; --primary-hover: #059669; --primary-light: rgba(16, 185, 129, 0.18); --primary-border: #10b981; --primary-gradient: linear-gradient(135deg, #10b981 0%, #059669 100%); }

/* Rose */
html[data-palette="rose"] { --primary: #e11d48; --primary-hover: #be123c; --primary-light: rgba(225, 29, 72, 0.12); --primary-border: #e11d48; --primary-gradient: linear-gradient(135deg, #e11d48 0%, #f43f5e 100%); }
html.dark-mode[data-palette="rose"], html[data-theme="dark"][data-palette="rose"] { --primary: #f43f5e; --primary-hover: #e11d48; --primary-light: rgba(244, 63, 94, 0.18); --primary-border: #f43f5e; --primary-gradient: linear-gradient(135deg, #f43f5e 0%, #e11d48 100%); }

/* Orange */
html[data-palette="orange"] { --primary: #ea580c; --primary-hover: #c2410c; --primary-light: rgba(234, 88, 12, 0.12); --primary-border: #ea580c; --primary-gradient: linear-gradient(135deg, #ea580c 0%, #f97316 100%); }
html.dark-mode[data-palette="orange"], html[data-theme="dark"][data-palette="orange"] { --primary: #f97316; --primary-hover: #ea580c; --primary-light: rgba(249, 115, 22, 0.18); --primary-border: #f97316; --primary-gradient: linear-gradient(135deg, #f97316 0%, #ea580c 100%); }

/* Cyan */
html[data-palette="cyan"] { --primary: #0891b2; --primary-hover: #0e7490; --primary-light: rgba(8, 145, 178, 0.12); --primary-border: #0891b2; --primary-gradient: linear-gradient(135deg, #0891b2 0%, #06b6d4 100%); }
html.dark-mode[data-palette="cyan"], html[data-theme="dark"][data-palette="cyan"] { --primary: #06b6d4; --primary-hover: #0891b2; --primary-light: rgba(6, 182, 212, 0.18); --primary-border: #06b6d4; --primary-gradient: linear-gradient(135deg, #06b6d4 0%, #0891b2 100%); }

/* Slate / Obsidian */
html[data-palette="slate"] { --primary: #475569; --primary-hover: #334155; --primary-light: rgba(71, 85, 105, 0.15); --primary-border: #475569; --primary-gradient: linear-gradient(135deg, #475569 0%, #64748b 100%); }
html.dark-mode[data-palette="slate"], html[data-theme="dark"][data-palette="slate"] { --primary: #94a3b8; --primary-hover: #cbd5e1; --primary-light: rgba(148, 163, 184, 0.18); --primary-border: #94a3b8; --primary-gradient: linear-gradient(135deg, #94a3b8 0%, #64748b 100%); }

/* --- 2. Temel Sayfa Ayarları --- */
body {
  font-family: 'Plus Jakarta Sans', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  background: var(--bg-body);
  color: var(--text-main);
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  transition: background 0.3s ease, color 0.3s ease;
  line-height: 1.6;
}

/* Yazı Boyutu (Font Scale) */
html[data-font="small"] { font-size: 14px; }
html[data-font="normal"] { font-size: 16px; }
html[data-font="large"] { font-size: 18px; }

/* --- 3. Glassmorphic Üst Menü (Navbar) --- */
.portal-navbar {
  position: sticky;
  top: 0;
  z-index: 1050;
  background: rgba(var(--bg-surface), 0.85);
  background-color: var(--bg-surface);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--border-color);
  padding: 12px 0;
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.03);
}

.portal-brand {
  display: flex;
  align-items: center;
  gap: 10px;
  text-decoration: none;
}

.portal-brand-icon {
  width: 38px;
  height: 38px;
  background: var(--primary-gradient);
  border-radius: 10px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 18px;
  color: #fff;
  box-shadow: 0 4px 10px rgba(37, 99, 235, 0.25);
}

.portal-brand-text {
  display: flex;
  flex-direction: column;
  line-height: 1.15;
}

.portal-brand-title {
  font-size: 17px;
  font-weight: 800;
  color: var(--text-main);
  letter-spacing: -0.3px;
}

.portal-brand-subtitle {
  font-size: 11px;
  font-weight: 600;
  color: var(--text-muted);
}

.portal-nav-links {
  display: flex;
  list-style: none;
  margin: 0;
  padding: 0;
  gap: 24px;
}

.portal-nav-link {
  color: var(--text-muted);
  text-decoration: none;
  font-size: 14px;
  font-weight: 600;
  transition: all 0.2s ease;
  padding: 6px 0;
  position: relative;
}

.portal-nav-link:hover, .portal-nav-link.active {
  color: var(--primary);
}

.portal-nav-actions {
  display: flex;
  align-items: center;
  gap: 10px;
}

.btn-portal-icon {
  width: 38px;
  height: 38px;
  border-radius: 10px;
  background: var(--bg-surface-secondary);
  border: 1px solid var(--border-color);
  color: var(--text-main);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 16px;
  cursor: pointer;
  transition: all 0.2s ease;
}

.btn-portal-icon:hover {
  background: var(--primary-light);
  border-color: var(--primary);
  transform: translateY(-1px);
}

.btn-portal-sm {
  padding: 7px 16px;
  font-size: 13px;
  font-weight: 700;
  border-radius: 10px;
}

.btn-primary {
  background-color: var(--primary) !important;
  border-color: var(--primary) !important;
}

.btn-primary:hover {
  filter: brightness(1.1);
  box-shadow: 0 4px 12px rgba(37, 99, 235, 0.25);
}

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

.btn-outline-primary:hover {
  background-color: var(--primary) !important;
  color: #ffffff !important;
}

/* Kullanıcı Profil Butonu (Pill) */
.portal-user-pill {
  display: flex;
  align-items: center;
  gap: 9px;
  background: var(--bg-surface-secondary);
  border: 1px solid var(--border-color);
  padding: 4px 12px 4px 4px;
  border-radius: 30px;
  cursor: pointer;
  transition: all 0.2s ease;
}

.portal-user-pill:hover {
  border-color: var(--primary);
  background: var(--bg-surface);
}

.user-avatar {
  width: 30px;
  height: 30px;
  border-radius: 50%;
  background: var(--primary-gradient);
  color: #fff;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 800;
  font-size: 13px;
}

.user-name {
  display: block;
  font-size: 12.5px;
  font-weight: 700;
  color: var(--text-main);
  line-height: 1.1;
}

.user-dept {
  display: block;
  font-size: 10px;
  color: var(--text-muted);
  font-weight: 600;
}

.portal-dropdown {
  background: var(--bg-surface);
  border: 1px solid var(--border-color);
  border-radius: 14px;
  padding: 8px;
}

.portal-dropdown .dropdown-item {
  color: var(--text-main);
  border-radius: 8px;
  font-size: 13px;
  font-weight: 600;
  padding: 8px 12px;
}

.portal-dropdown .dropdown-item:hover {
  background: var(--primary-light);
  color: var(--primary);
}

/* --- 4. Hero / Karşılama Alanı --- */
.portal-hero-section {
  padding: 60px 0 40px 0;
  text-align: center;
  position: relative;
}

.hero-status-badge {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 6px 14px;
  background: var(--bg-surface);
  border: 1px solid var(--border-color);
  border-radius: 20px;
  font-size: 12px;
  font-weight: 700;
  color: var(--text-main);
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.04);
  margin-bottom: 20px;
}

.pulse-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: #10b981;
  box-shadow: 0 0 0 2px rgba(16, 185, 129, 0.2);
  animation: pulseDot 2s infinite;
}

@keyframes pulseDot {
  0% { transform: scale(0.95); box-shadow: 0 0 0 0 rgba(16, 185, 129, 0.7); }
  70% { transform: scale(1); box-shadow: 0 0 0 6px rgba(16, 185, 129, 0); }
  100% { transform: scale(0.95); box-shadow: 0 0 0 0 rgba(16, 185, 129, 0); }
}

.portal-hero-title {
  font-size: 38px;
  font-weight: 900;
  color: var(--text-main);
  letter-spacing: -0.8px;
  margin-bottom: 12px;
}

.portal-hero-subtitle {
  font-size: 16px;
  color: var(--text-muted);
  max-width: 650px;
  margin: 0 auto 32px auto;
}

/* İstatistik Çipleri */
.portal-stats-bar {
  display: flex;
  justify-content: center;
  gap: 14px;
  flex-wrap: wrap;
  margin-bottom: 40px;
}

.stat-pill {
  display: flex;
  align-items: center;
  gap: 10px;
  background: var(--bg-surface);
  border: 1px solid var(--border-color);
  padding: 10px 18px;
  border-radius: 14px;
  box-shadow: var(--card-shadow);
  transition: all 0.2s ease;
}

.stat-pill:hover {
  transform: translateY(-2px);
  border-color: var(--primary);
}

.stat-icon { font-size: 20px; }
.stat-val { font-size: 16px; font-weight: 800; color: var(--text-main); line-height: 1; }
.stat-lbl { font-size: 11px; font-weight: 600; color: var(--text-muted); }

/* --- 5. Proje Vitrin Kartları (Projects Grid) --- */
.section-header-wrap {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 22px;
}

.section-header-title {
  font-size: 22px;
  font-weight: 800;
  color: var(--text-main);
  margin: 0;
  display: flex;
  align-items: center;
  gap: 8px;
}

.projects-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
  gap: 22px;
  margin-bottom: 50px;
}

@media (max-width: 768px) {
  .projects-grid {
    grid-template-columns: 1fr;
  }
  .project-card {
    grid-column: auto !important;
  }
}

.project-card {
  background: var(--bg-surface);
  border: 1.5px solid var(--border-color);
  border-radius: 20px;
  padding: 24px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  transition: all 0.25s cubic-bezier(0.4, 0, 0.2, 1);
  box-shadow: var(--card-shadow);
  position: relative;
}

.project-card.project-card-full {
  grid-column: 1 / -1 !important;
}

.project-card:hover {
  transform: translateY(-4px);
  border-color: var(--primary);
  box-shadow: var(--card-shadow-hover);
}

.project-card-top {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  margin-bottom: 16px;
}

.project-icon-box {
  width: 48px;
  height: 48px;
  border-radius: 14px;
  background: var(--primary-light);
  border: 1px solid var(--primary-border);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 22px;
}

.project-status-badge {
  padding: 4px 10px;
  border-radius: 10px;
  font-size: 11px;
  font-weight: 800;
  letter-spacing: 0.3px;
}

.badge-live {
  background: rgba(16, 185, 129, 0.12);
  border: 1px solid rgba(16, 185, 129, 0.3);
  color: #059669;
}

.badge-planned {
  background: rgba(139, 92, 246, 0.12);
  border: 1px solid rgba(139, 92, 246, 0.3);
  color: #7c3aed;
}

.project-title {
  font-size: 17px;
  font-weight: 800;
  color: var(--text-main);
  margin-bottom: 8px;
}

.project-desc {
  font-size: 13px;
  color: var(--text-muted);
  margin-bottom: 16px;
  line-height: 1.5;
}

.project-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-bottom: 18px;
}

.project-tag {
  background: var(--bg-surface-secondary);
  border: 1px solid var(--border-color);
  padding: 3px 8px;
  border-radius: 8px;
  font-size: 11px;
  font-weight: 600;
  color: var(--text-muted);
}

.btn-launch-app {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  width: 100%;
  padding: 10px 16px;
  border-radius: 12px;
  font-size: 13.5px;
  font-weight: 700;
  text-decoration: none;
  background: var(--primary);
  color: #fff;
  border: 1px solid var(--primary);
  transition: all 0.2s ease;
}

.btn-launch-app:hover {
  filter: brightness(1.1);
  color: #fff;
  transform: translateY(-1px);
}

.btn-launch-app.disabled {
  background: var(--bg-surface-secondary) !important;
  border-color: var(--border-color) !important;
  color: var(--text-muted) !important;
  cursor: not-allowed;
  pointer-events: none;
}

.project-subactions {
  display: flex;
  gap: 8px;
  margin-top: 8px;
}

.btn-subaction {
  flex: 1;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 5px;
  padding: 7px 10px;
  background: var(--bg-surface-secondary);
  border: 1px solid var(--border-color);
  border-radius: 10px;
  font-size: 11.5px;
  font-weight: 700;
  color: var(--text-main);
  text-decoration: none;
  transition: all 0.2s ease;
  white-space: nowrap;
}

.btn-subaction:hover {
  background: var(--primary-light);
  border-color: var(--primary);
  color: var(--primary);
  transform: translateY(-1px);
}

/* --- 6. Auth / Giriş & Kayıt Kartları (Auth Pages) --- */
.auth-wrapper {
  min-height: calc(100vh - 160px);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 40px 15px;
}

.auth-card {
  width: 100%;
  max-width: 440px;
  background: var(--bg-surface);
  border: 1.5px solid var(--border-color);
  border-radius: 24px;
  padding: 32px;
  box-shadow: var(--card-shadow-hover);
}

.auth-header {
  text-align: center;
  margin-bottom: 24px;
}

.auth-header-icon {
  font-size: 32px;
  margin-bottom: 8px;
}

.auth-header-title {
  font-size: 22px;
  font-weight: 800;
  color: var(--text-main);
  margin-bottom: 4px;
}

.auth-header-subtitle {
  font-size: 13px;
  color: var(--text-muted);
}

.form-label {
  font-size: 12.5px;
  font-weight: 700;
  color: var(--text-main);
  margin-bottom: 6px;
}

.form-control {
  background: var(--bg-surface-secondary) !important;
  border: 1.5px solid var(--border-color) !important;
  color: var(--text-main) !important;
  border-radius: 12px !important;
  padding: 10px 14px !important;
  font-size: 14px !important;
}

.form-control:focus {
  border-color: var(--primary) !important;
  box-shadow: 0 0 0 3px var(--primary-light) !important;
  background: var(--bg-surface) !important;
}

/* --- 7. Görünüm & Sistem Ayarları Modalı (Settings Modal) --- */
.portal-modal-backdrop {
  position: fixed;
  top: 0;
  left: 0;
  width: 100vw;
  height: 100vh;
  background: rgba(0, 0, 0, 0.65);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  z-index: 99999;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 20px;
  box-sizing: border-box;
  opacity: 0;
  transition: opacity 0.25s ease;
}

.portal-modal-backdrop.active {
  opacity: 1;
}

.portal-modal-box {
  background: var(--bg-surface);
  border: 1.5px solid var(--border-color);
  border-radius: 24px;
  width: 100%;
  max-width: 480px;
  max-height: 90vh;
  overflow-y: auto;
  padding: 26px;
  box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.35);
  transform: scale(0.95);
  transition: transform 0.25s cubic-bezier(0.4, 0, 0.2, 1);
}

.portal-modal-backdrop.active .portal-modal-box {
  transform: scale(1);
}

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

.portal-modal-title {
  font-size: 18px;
  font-weight: 800;
  margin: 0;
  color: var(--text-main);
}

.portal-modal-close {
  background: transparent;
  border: none;
  font-size: 24px;
  color: var(--text-muted);
  cursor: pointer;
  padding: 0;
  line-height: 1;
}

.settings-group {
  margin-bottom: 18px;
}

.settings-label {
  font-size: 12.5px;
  font-weight: 700;
  color: var(--text-muted);
  margin-bottom: 8px;
  display: block;
}

.theme-mode-switch {
  display: flex;
  gap: 8px;
}

.theme-mode-btn {
  flex: 1;
  padding: 10px;
  border-radius: 12px;
  border: 1.5px solid var(--border-color);
  background: var(--bg-surface-secondary);
  color: var(--text-main);
  font-size: 13px;
  font-weight: 700;
  cursor: pointer;
  transition: all 0.2s ease;
}

.theme-mode-btn.active {
  background: var(--primary);
  border-color: var(--primary);
  color: #fff;
}

.theme-palette-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 8px;
}

.theme-palette-card {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 8px 12px;
  border-radius: 12px;
  border: 1.5px solid var(--border-color);
  background: var(--bg-surface-secondary);
  color: var(--text-main);
  font-size: 12.5px;
  font-weight: 700;
  cursor: pointer;
  transition: all 0.2s ease;
}

.theme-palette-card.active {
  border-color: var(--primary);
  background: var(--primary-light);
  color: var(--primary);
}

.theme-swatch {
  width: 20px;
  height: 20px;
  border-radius: 50%;
  flex-shrink: 0;
}

.settings-segmented-group {
  display: flex;
  gap: 4px;
  background: var(--bg-surface-secondary);
  border: 1px solid var(--border-color);
  border-radius: 12px;
  padding: 4px;
}

.settings-segment-btn {
  flex: 1;
  padding: 6px 10px;
  border: none;
  background: transparent;
  color: var(--text-muted);
  font-size: 12.5px;
  font-weight: 700;
  border-radius: 8px;
  cursor: pointer;
  transition: all 0.2s ease;
}

.settings-segment-btn.active {
  background: var(--primary);
  color: #fff;
}

.portal-modal-footer {
  display: flex;
  justify-content: flex-end;
  gap: 8px;
  margin-top: 20px;
  padding-top: 14px;
  border-top: 1px solid var(--border-color);
}

/* --- 8. Footer --- */
.portal-footer {
  border-top: 1px solid var(--border-color);
  background: var(--bg-surface);
  color: var(--text-muted);
  font-size: 13px;
}

/* ==========================================================================
   --- 9. Karanlık Mod (Dark Mode) Kontrast & Okunabilirlik İyileştirmeleri ---
   ========================================================================== */
html.dark-mode {
  color-scheme: dark;
}

html.dark-mode, 
body.dark-mode {
  --bs-body-color: #f8fafc !important;
  --bs-body-bg: #0b0f19 !important;
  --bs-emphasis-color: #ffffff !important;
  --bs-secondary-color: #94a3b8 !important;
  --bs-tertiary-color: #64748b !important;
  --bs-border-color: #23304d !important;
  --bs-link-color: #60a5fa !important;
  --bs-link-hover-color: #93c5fd !important;
}

/* Bootstrap Kartlar & Konteynerler */
html.dark-mode .card,
body.dark-mode .card {
  background-color: var(--bg-surface) !important;
  border-color: var(--border-color) !important;
  color: var(--text-main) !important;
}

html.dark-mode .card-header,
body.dark-mode .card-header,
html.dark-mode .card-footer,
body.dark-mode .card-footer {
  background-color: transparent !important;
  border-color: var(--border-color) !important;
}

html.dark-mode .bg-body-tertiary,
body.dark-mode .bg-body-tertiary,
html.dark-mode .bg-body-secondary,
body.dark-mode .bg-body-secondary,
html.dark-mode .bg-light,
body.dark-mode .bg-light {
  background-color: var(--bg-surface-secondary) !important;
  color: var(--text-main) !important;
}

/* Bootstrap Text Renkleri */
html.dark-mode .text-body,
body.dark-mode .text-body {
  color: #f8fafc !important;
}

html.dark-mode .text-muted,
body.dark-mode .text-muted {
  color: #94a3b8 !important;
}

html.dark-mode .text-secondary,
body.dark-mode .text-secondary {
  color: #cbd5e1 !important;
}

/* text-dark düzeltmesi: Rozet ve butonlar dışındaki metinleri beyaza çevir, sarı/cyan üzerindeki siyah yazıyı koru! */
html.dark-mode .text-dark:not(.badge):not(.btn) {
  color: #ffffff !important;
}
.badge.text-dark,
.btn.text-dark {
  color: #0f172a !important;
}

/* Tablolar (Tables in Dark & Light Mode - Crystal Clear) */
.table thead th {
  font-size: 11.5px;
  font-weight: 800;
  letter-spacing: 0.5px;
  text-transform: uppercase;
}

html:not(.dark-mode) .table thead th {
  background-color: #f8fafc !important;
  color: #475569 !important;
  border-bottom: 2px solid #e2e8f0 !important;
}

html.dark-mode .table,
body.dark-mode .table {
  --bs-table-bg: transparent !important;
  --bs-table-color: #f8fafc !important;
  --bs-table-border-color: #23304d !important;
  --bs-table-hover-bg: rgba(255, 255, 255, 0.04) !important;
  --bs-table-hover-color: #ffffff !important;
  color: #f8fafc !important;
}

html.dark-mode .table > :not(caption) > * > *,
body.dark-mode .table > :not(caption) > * > * {
  background-color: transparent !important;
  color: #f8fafc !important;
  border-bottom-color: #23304d !important;
}

html.dark-mode .table thead th,
body.dark-mode .table thead th,
html.dark-mode .table-light,
body.dark-mode .table-light {
  background-color: #1a243b !important;
  color: #cbd5e1 !important;
  border-bottom: 2px solid #2d3d5f !important;
}

html.dark-mode .table tr:hover td {
  background-color: rgba(255, 255, 255, 0.035) !important;
}

/* Form Elemanları (Inputs & Selects) */
html.dark-mode .form-control,
body.dark-mode .form-control,
html.dark-mode .form-select,
body.dark-mode .form-select {
  background-color: #131b2e !important;
  border-color: #23304d !important;
  color: #f8fafc !important;
}

html.dark-mode .form-control:focus,
body.dark-mode .form-control:focus,
html.dark-mode .form-select:focus,
body.dark-mode .form-select:focus {
  background-color: #1a243b !important;
  border-color: var(--primary) !important;
  color: #ffffff !important;
  box-shadow: 0 0 0 3px rgba(124, 58, 237, 0.25) !important;
}

html.dark-mode .input-group-text,
body.dark-mode .input-group-text {
  background-color: #1a243b !important;
  border-color: #23304d !important;
  color: #94a3b8 !important;
}

html.dark-mode .form-select option {
  background-color: #131b2e !important;
  color: #f8fafc !important;
}

html.dark-mode .form-control::placeholder,
body.dark-mode .form-control::placeholder {
  color: #64748b !important;
}

/* Rozetler (Badges - High Visibility & High Contrast) */
.badge.bg-success,
.badge.bg-success-subtle {
  background-color: rgba(16, 185, 129, 0.18) !important;
  color: #10b981 !important;
  border: 1px solid rgba(16, 185, 129, 0.35) !important;
}

.badge.bg-danger,
.badge.bg-danger-subtle {
  background-color: rgba(239, 68, 68, 0.18) !important;
  color: #ef4444 !important;
  border: 1px solid rgba(239, 68, 68, 0.35) !important;
}

.badge.bg-warning,
.badge.bg-warning-subtle {
  background-color: #fef08a !important;
  color: #854d0e !important;
  border: 1px solid #fde047 !important;
  font-weight: 700 !important;
}

html.dark-mode .badge.bg-warning,
html.dark-mode .badge.bg-warning-subtle {
  background-color: rgba(234, 179, 8, 0.22) !important;
  color: #facc15 !important;
  border: 1px solid rgba(234, 179, 8, 0.45) !important;
}

.badge.bg-info,
.badge.bg-info-subtle {
  background-color: rgba(14, 165, 233, 0.18) !important;
  color: #0284c7 !important;
  border: 1px solid rgba(14, 165, 233, 0.35) !important;
}

html.dark-mode .badge.bg-info,
html.dark-mode .badge.bg-info-subtle {
  background-color: rgba(14, 165, 233, 0.22) !important;
  color: #38bdf8 !important;
  border: 1px solid rgba(14, 165, 233, 0.45) !important;
}

.badge.bg-primary,
.badge.bg-primary-subtle {
  background-color: var(--primary-light) !important;
  color: var(--primary) !important;
  border: 1px solid var(--primary-border) !important;
}

.badge.bg-secondary,
.badge.bg-secondary-subtle {
  background-color: rgba(148, 163, 184, 0.18) !important;
  color: #64748b !important;
  border: 1px solid rgba(148, 163, 184, 0.3) !important;
}

html.dark-mode .badge.bg-secondary,
html.dark-mode .badge.bg-secondary-subtle {
  background-color: rgba(148, 163, 184, 0.2) !important;
  color: #cbd5e1 !important;
  border: 1px solid rgba(148, 163, 184, 0.35) !important;
}

/* Modal Bileşenleri */
html.dark-mode .modal-content,
body.dark-mode .modal-content {
  background-color: #131b2e !important;
  border: 1.5px solid #23304d !important;
  color: #f8fafc !important;
  box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.7) !important;
}

html.dark-mode .modal-header,
body.dark-mode .modal-header,
html.dark-mode .modal-footer,
body.dark-mode .modal-footer {
  border-color: #23304d !important;
}

html.dark-mode .modal-title,
body.dark-mode .modal-title {
  color: #ffffff !important;
}

html.dark-mode .btn-close,
body.dark-mode .btn-close {
  filter: invert(1) grayscale(100%) brightness(200%);
}

/* Yoğunluk Modları (Density Modes) */
html[data-density="compact"] .table td, 
html[data-density="compact"] .table th {
  padding-top: 5px !important;
  padding-bottom: 5px !important;
  font-size: 12.5px !important;
}
html[data-density="compact"] .form-control,
html[data-density="compact"] .form-select {
  padding: 6px 10px !important;
  font-size: 13px !important;
}
html[data-density="compact"] .card {
  margin-bottom: 12px !important;
}
