.header {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  z-index: 1000;
  background-color: #fff; /* Arka plan rengi */
}

.footer {
  position: fixed;
  bottom: 0;
  left: 0;
  width: 100%;
  z-index: 1000;
  background-color: #fff;
}

.content-body {
  margin-top: 60px; /* Header yüksekliğine göre ayarla */
  margin-bottom: 40px; /* Footer ile çakışmaması için */
  overflow-y: auto;
  height: calc(100vh - 100px); /* Header ve Footer dışında kalan alan */
}


/* İçeriği header ve footer'a göre hizala */
.content-body {
  margin-top: 70px; /* Header'dan boşluk bırak */
  margin-bottom: 60px; /* Footer'dan boşluk bırak */
  padding: 20px;
  min-height: calc(100vh - 120px); /* Header ve Footer'a göre ayarla */
}

/* Base Styles */
html {
  position: relative;
  min-height: 100vh;
  font-size: 16px;
}

body {
  font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
  line-height: 1.6;
  color: var(--text-color);
  background-color: var(--content-bg);
  transition: all 0.3s ease;
  overflow-x: hidden;
}

/* Typography */
h1, h2, h3, h4, h5, h6 {
  font-weight: 600;
  margin-bottom: 1rem;
  color: var(--text-color);
}

a {
  color: var(--primary-color);
  text-decoration: none;
  transition: color 0.3s ease;
}

a:hover {
  color: var(--primary-hover);
  text-decoration: none;
}

/* Form Elements */
.form-control {
  border-radius: 0.375rem;
  border: 1px solid var(--border-color);
  padding: 0.75rem 1rem;
  transition: all 0.3s ease;
  background-color: var(--card-bg);
  color: var(--text-color);
}

.form-control:focus {
  border-color: var(--primary-color);
  box-shadow: 0 0 0 0.2rem rgba(76, 175, 80, 0.25);
}

.form-label {
  font-weight: 500;
  margin-bottom: 0.5rem;
  color: var(--text-color);
}

/* Buttons */
.btn {
  border-radius: 0.375rem;
  padding: 0.5rem 1.25rem;
  font-weight: 500;
  transition: all 0.3s ease;
  text-transform: none;
  letter-spacing: 0.5px;
}

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

.btn-primary:hover, .btn-primary:focus {
  background-color: var(--primary-hover);
  border-color: var(--primary-hover);
}

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

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

/* Cards */
.card {
  border-radius: 0.5rem;
  overflow: hidden;
  margin-bottom: 1.5rem;
  background-color: var(--card-bg);
  border: 1px solid var(--border-color);
  box-shadow: var(--shadow);
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.card:hover {
  transform: translateY(-5px);
  box-shadow: 0 10px 20px rgba(0, 0, 0, 0.1);
}

.card-header {
  background-color: rgba(0, 0, 0, 0.03);
  border-bottom: 1px solid var(--border-color);
  padding: 1rem 1.25rem;
  font-weight: 600;
}

.card-body {
  padding: 1.5rem;
}

.card-footer {
  background-color: rgba(0, 0, 0, 0.03);
  border-top: 1px solid var(--border-color);
  padding: 1rem 1.25rem;
}

/* Tables */
.table {
  color: var(--text-color);
  border-color: var(--border-color);
}

.table thead th {
  border-bottom: 2px solid var(--border-color);
  font-weight: 600;
  color: var(--text-color);
}

.table-hover tbody tr:hover {
  background-color: rgba(0, 0, 0, 0.03);
}

/* Alerts */
.alert {
  border-radius: 0.375rem;
  border: none;
  padding: 1rem 1.25rem;
  margin-bottom: 1.5rem;
}

.alert-success {
  background-color: rgba(76, 175, 80, 0.1);
  color: #2e7d32;
}

.alert-danger {
  background-color: rgba(244, 67, 54, 0.1);
  color: #d32f2f;
}

.alert-warning {
  background-color: rgba(255, 152, 0, 0.1);
  color: #ef6c00;
}

.alert-info {
  background-color: rgba(33, 150, 243, 0.1);
  color: #1976d2;
}

/* Badges */
.badge {
  font-weight: 500;
  padding: 0.35em 0.65em;
  border-radius: 0.25rem;
}

/* Animations */
.fade-in {
  animation: fadeIn 0.5s ease-in-out;
}

@keyframes fadeIn {
  from { opacity: 0; }
  to { opacity: 1; }
}

.slide-in {
  animation: slideIn 0.5s ease-in-out;
}

@keyframes slideIn {
  from { transform: translateY(20px); opacity: 0; }
  to { transform: translateY(0); opacity: 1; }
}

/* Custom Components */
.feature-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 4rem;
  height: 4rem;
  border-radius: 0.75rem;
  background-color: var(--primary-color);
  color: white;
  font-size: 1.5rem;
  margin-bottom: 1rem;
}

.stat-card {
  padding: 1.5rem;
  border-radius: 0.5rem;
  background-color: var(--card-bg);
  box-shadow: var(--shadow);
  transition: transform 0.3s ease;
}

.stat-card:hover {
  transform: translateY(-5px);
}

.stat-card .stat-value {
  font-size: 2rem;
  font-weight: 700;
  margin-bottom: 0.5rem;
  color: var(--primary-color);
}

.stat-card .stat-label {
  font-size: 0.875rem;
  color: var(--text-color);
  opacity: 0.8;
}

/* Responsive Utilities */
@media (max-width: 768px) {
  .hide-mobile {
    display: none !important;
  }
  
  .text-center-mobile {
    text-align: center !important;
  }
  
  .mt-3-mobile {
    margin-top: 1rem !important;
  }
}

/* Dark Mode Overrides */
body.dark-theme {
  --text-color: #e9ecef;
  --content-bg: #121212;
  --card-bg: #1e1e1e;
  --border-color: rgba(255, 255, 255, 0.125);
}

body.dark-theme .form-control {
  background-color: #2c2c2c;
  border-color: #444;
  color: #e9ecef;
}

body.dark-theme .table-hover tbody tr:hover {
  background-color: rgba(255, 255, 255, 0.05);
}

/* Custom Scrollbar */
::-webkit-scrollbar {
  width: 8px;
  height: 8px;
}

::-webkit-scrollbar-track {
  background: var(--content-bg);
}

::-webkit-scrollbar-thumb {
  background: var(--primary-color);
  border-radius: 4px;
}

::-webkit-scrollbar-thumb:hover {
  background: var(--primary-hover);
}

/* Loading Spinner */
.spinner {
  width: 40px;
  height: 40px;
  margin: 100px auto;
  border-radius: 50%;
  border: 4px solid rgba(0, 0, 0, 0.1);
  border-top-color: var(--primary-color);
  animation: spin 1s ease-in-out infinite;
}

@keyframes spin {
  to { transform: rotate(360deg); }
}

/* Tooltip */
.tooltip {
  position: relative;
  display: inline-block;
}

.tooltip .tooltip-text {
  visibility: hidden;
  width: 120px;
  background-color: var(--card-bg);
  color: var(--text-color);
  text-align: center;
  border-radius: 6px;
  padding: 5px;
  position: absolute;
  z-index: 1;
  bottom: 125%;
  left: 50%;
  margin-left: -60px;
  opacity: 0;
  transition: opacity 0.3s;
  box-shadow: var(--shadow);
  border: 1px solid var(--border-color);
}

.tooltip:hover .tooltip-text {
  visibility: visible;
  opacity: 1;
}

/* Code Blocks */
pre {
  background-color: #2d2d2d;
  color: #f8f8f2;
  padding: 1rem;
  border-radius: 0.375rem;
  overflow-x: auto;
}

code {
  font-family: 'Consolas', 'Monaco', monospace;
  font-size: 0.9rem;
}

/* Utility Classes */
.text-primary {
  color: var(--primary-color) !important;
}

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

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

.shadow-sm {
  box-shadow: 0 0.125rem 0.25rem rgba(0, 0, 0, 0.075) !important;
}

.shadow {
  box-shadow: 0 0.5rem 1rem rgba(0, 0, 0, 0.15) !important;
}

.shadow-lg {
  box-shadow: 0 1rem 3rem rgba(0, 0, 0, 0.175) !important;
}

.rounded {
  border-radius: 0.375rem !important;
}

.rounded-circle {
  border-radius: 50% !important;
}

.transition {
  transition: all 0.3s ease !important;
}

/* İlginizi Çekebilecek Algoritmalar Bölümü */
.related-algorithms {
  margin-top: 3rem;
  padding-bottom: 2rem;
}

.related-algorithms .card {
  border: none;
  box-shadow: 0 0.5rem 1.5rem rgba(0, 0, 0, 0.1);
}

.related-algorithms .card-header {
  background-color: var(--primary-color);
  color: white;
  border-radius: 0.5rem 0.5rem 0 0;
  padding: 1rem 1.5rem;
}

.related-algorithms .algorithm-card {
  transition: all 0.3s ease;
  border: 1px solid var(--border-color);
  overflow: hidden;
}

.related-algorithms .algorithm-card:hover {
  transform: translateY(-5px);
  box-shadow: 0 0.75rem 1.5rem rgba(0, 0, 0, 0.15);
  border-color: var(--primary-color);
}

.related-algorithms .card-title {
  font-size: 1.1rem;
  font-weight: 600;
  margin-bottom: 0.75rem;
}

.related-algorithms .card-text {
  font-size: 0.9rem;
  margin-bottom: 1rem;
  min-height: 2.7rem;
}

.related-algorithms .card-footer {
  background-color: transparent;
  padding-top: 0;
  border-top: none;
  text-align: right;
}

.related-algorithms .btn-outline-primary:hover {
  background-color: var(--primary-color);
  color: white;
}

@media (max-width: 768px) {
  .related-algorithms .col-md-4 {
    margin-bottom: 1rem;
  }
  
  .related-algorithms .card-text {
    min-height: auto;
  }
}