/* ============================================================
   TEMAD EMLAK — MASTER LAYOUT LOCK SYSTEM
   Version: 20260418
   
   Bu dosya tüm sayfalardaki ortak düzen öğelerini kilitler.
   Güncellemeler sırasında header, footer, navigation ve 
   temel yapıların bozulmasını önler.
   ============================================================ */

/* ── 1. CSS RESET KORUMALARI ──────────────────────────────── */
*, *::before, *::after {
  box-sizing: border-box !important;
}

html {
  scroll-behavior: smooth;
  -webkit-text-size-adjust: 100%;
}

body {
  margin: 0;
  padding: 0;
  font-family: 'Plus Jakarta Sans', system-ui, -apple-system, sans-serif;
  line-height: 1.6;
  color: #1a1a2e;
  background: #fdfaf8;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

/* ── 2. HEADER LAYOUT LOCK ────────────────────────────────── */
.site-header {
  position: sticky !important;
  top: 0 !important;
  z-index: 1000 !important;
  background: #fff !important;
  border-bottom: 1px solid #f0e7e1 !important;
  padding: 0.75rem 0 !important;
}

body.mobile-nav-open .site-header {
  z-index: 1045 !important;
}

.site-header .container-xl {
  display: flex !important;
  align-items: center !important;
  justify-content: space-between !important;
  gap: 1rem !important;
  max-width: min(1680px, 98vw) !important;
  margin: 0 auto !important;
  padding-left: clamp(12px, 2vw, 28px) !important;
  padding-right: clamp(12px, 2vw, 28px) !important;
}

.header-logo img {
  height: 40px !important;
  width: auto !important;
  object-fit: contain !important;
}

.header-nav {
  display: flex !important;
  align-items: center !important;
  gap: 0.5rem !important;
}

.header-nav a {
  padding: 0.5rem 0.75rem !important;
  font-size: 0.9rem !important;
  font-weight: 600 !important;
  color: #4b5563 !important;
  text-decoration: none !important;
  border-radius: 8px !important;
  transition: color 0.2s, background 0.2s !important;
}

.header-nav a:hover,
.header-nav a.active {
  color: #c35b28 !important;
  background: rgba(195, 91, 40, 0.08) !important;
}

.header-actions {
  display: flex !important;
  align-items: center !important;
  gap: 0.5rem !important;
}

/* ── 3. FOOTER LAYOUT LOCK ────────────────────────────────── */
.site-footer {
  background: #fff !important;
  color: #333 !important;
  padding: 3rem 0 !important;
  margin-top: auto !important;
  border-top: 1px solid #e5e7eb !important;
}

.site-footer .container-xl {
  max-width: 100% !important;
  width: 100% !important;
  margin: 0 !important;
  padding-left: clamp(16px, 3vw, 48px) !important;
  padding-right: clamp(16px, 3vw, 48px) !important;
  background: transparent !important;
}

.footer-brand img {
  height: 44px !important;
  width: auto !important;
  object-fit: contain !important;
}

.footer-title {
  font-size: 0.9rem !important;
  font-weight: 700 !important;
  color: #1A1A2E !important;
  margin-bottom: 1rem !important;
  text-transform: uppercase !important;
  letter-spacing: 0.05em !important;
}

.footer-links {
  list-style: none !important;
  margin: 0 !important;
  padding: 0 !important;
}

.footer-links li {
  margin-bottom: 0.5rem !important;
}

.footer-links a {
  color: #555 !important;
  text-decoration: none !important;
  font-size: 0.9rem !important;
  transition: color 0.2s !important;
}

.footer-links a:hover {
  color: #C35B28 !important;
}

.footer-links li {
  color: #666 !important;
  line-height: 2 !important;
  font-size: 0.9rem !important;
}

.sosyal-btn {
  color: #1A1A2E !important;
  border-color: #ddd !important;
  background: #f3f4f6 !important;
}

.sosyal-btn:hover {
  color: #fff !important;
  background: #C35B28 !important;
  border-color: #C35B28 !important;
}

.site-footer p.small {
  color: #555 !important;
}

.site-footer hr {
  border-color: #e5e7eb !important;
  opacity: 1 !important;
}

/* Footer 5-column grid lock — masaustu: flex nowrap, mobil: bootstrap col-6 */
.site-footer .row {
  display: flex !important;
  flex-wrap: wrap !important;
  gap: 0 !important;
}

/* Masaüstü: 5 sütun sabit oran */
@media (min-width: 992px) {
  .site-footer .row > .col-lg-4 {
    flex: 0 0 28% !important;
    max-width: 28% !important;
  }

  .site-footer .row > .col-6.col-lg-2,
  .site-footer .row > .col-lg-2 {
    flex: 0 0 18% !important;
    max-width: 18% !important;
  }
}

/* Footer bottom bar lock */
.footer-bottom-bar {
  display: flex !important;
  flex-direction: row !important;
  flex-wrap: nowrap !important;
  align-items: flex-start !important;
  justify-content: space-between !important;
  gap: 20px !important;
  font-size: 13px !important;
  color: #6b7280 !important;
  padding: 0 !important;
  margin: 0 !important;
}

.fbb-left {
  flex: 1 1 auto !important;
  min-width: 0 !important;
  line-height: 1.7 !important;
  font-size: 12px !important;
  color: #888 !important;
}

.fbb-right {
  display: flex !important;
  align-items: center !important;
  gap: 8px !important;
  flex-shrink: 0 !important;
  white-space: nowrap !important;
}

/* ── 4. CONTAINER LAYOUT LOCK ─────────────────────────────── */
.container-xl {
  width: 100% !important;
  max-width: min(1680px, 98vw) !important;
  margin-left: auto !important;
  margin-right: auto !important;
  padding-left: clamp(12px, 2vw, 28px) !important;
  padding-right: clamp(12px, 2vw, 28px) !important;
}

/* ── 5. BUTTON LAYOUT LOCK ────────────────────────────────── */
.btn {
  display: inline-flex !important;
  align-items: center !important;
  justify-content: center !important;
  gap: 0.5rem !important;
  padding: 0.6rem 1.25rem !important;
  font-size: 0.9rem !important;
  font-weight: 600 !important;
  border-radius: 10px !important;
  cursor: pointer !important;
  transition: all 0.2s !important;
  text-decoration: none !important;
  border: none !important;
}

.btn-turuncu {
  background: linear-gradient(135deg, #c35b28 0%, #e8540a 100%) !important;
  color: #fff !important;
  box-shadow: 0 4px 12px rgba(195, 91, 40, 0.3) !important;
}

.btn-turuncu:hover {
  transform: translateY(-2px) !important;
  box-shadow: 0 6px 16px rgba(195, 91, 40, 0.4) !important;
}

.btn-outline-secondary {
  background: transparent !important;
  border: 1.5px solid #e5e7eb !important;
  color: #4b5563 !important;
}

.btn-outline-secondary:hover {
  border-color: #c35b28 !important;
  color: #c35b28 !important;
}

/* ── 6. CARD LAYOUT LOCK ──────────────────────────────────── */
.ilan-karti {
  background: #fff !important;
  border-radius: 16px !important;
  overflow: hidden !important;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.06) !important;
  transition: transform 0.2s, box-shadow 0.2s !important;
  cursor: pointer !important;
}

.ilan-karti:hover {
  transform: translateY(-4px) !important;
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.1) !important;
}

.ilan-foto-wrap {
  position: relative !important;
  aspect-ratio: 16 / 10 !important;
  overflow: hidden !important;
  background: #f3f4f6 !important;
}

.ilan-foto-wrap img {
  width: 100% !important;
  height: 100% !important;
  object-fit: cover !important;
}

.ilan-bilgi {
  padding: 1rem !important;
}

.ilan-baslik {
  font-size: 0.95rem !important;
  font-weight: 700 !important;
  color: #1a1a2e !important;
  margin: 0 0 0.5rem !important;
  line-height: 1.3 !important;
  display: -webkit-box !important;
  -webkit-line-clamp: 2 !important;
  -webkit-box-orient: vertical !important;
  overflow: hidden !important;
}

.ilan-konum {
  font-size: 0.82rem !important;
  color: #6b7280 !important;
  margin-bottom: 0.5rem !important;
}

.ilan-fiyat {
  font-size: 1.1rem !important;
  font-weight: 800 !important;
  color: #c35b28 !important;
}

/* ── 7. PAGINATION LAYOUT LOCK ────────────────────────────── */
.sayfalama {
  display: flex !important;
  align-items: center !important;
  justify-content: center !important;
  gap: 6px !important;
  margin-top: 2rem !important;
  padding: 1.5rem 0 !important;
  flex-wrap: wrap !important;
}

.sayfa-btn {
  min-width: 38px !important;
  height: 38px !important;
  background: #fff !important;
  border: 1.5px solid #e5e7eb !important;
  border-radius: 8px !important;
  display: inline-flex !important;
  align-items: center !important;
  justify-content: center !important;
  font-size: 13px !important;
  font-weight: 600 !important;
  color: #4b5563 !important;
  cursor: pointer !important;
  transition: all 0.2s !important;
  font-family: inherit !important;
}

.sayfa-btn:hover {
  border-color: #c35b28 !important;
  color: #c35b28 !important;
}

.sayfa-btn.aktif {
  background: #c35b28 !important;
  border-color: #c35b28 !important;
  color: #fff !important;
}

.sayfa-btn:disabled {
  opacity: 0.4 !important;
  cursor: not-allowed !important;
}

/* ── 8. GRID LAYOUT LOCK ──────────────────────────────────── */
.ilan-grid {
  display: grid !important;
  gap: 1rem !important;
}

@media (min-width: 768px) {
  .ilan-grid {
    grid-template-columns: repeat(2, 1fr) !important;
  }
}

@media (min-width: 1024px) {
  .ilan-grid {
    grid-template-columns: repeat(3, 1fr) !important;
  }
}

@media (min-width: 1400px) {
  .ilan-grid {
    grid-template-columns: repeat(4, 1fr) !important;
  }
}

/* ── 9. FORM ELEMENT LOCK ─────────────────────────────────── */
.form-select,
.form-control {
  display: block !important;
  width: 100% !important;
  padding: 0.6rem 1rem !important;
  font-size: 0.9rem !important;
  font-family: inherit !important;
  border: 1.5px solid #e2d9d2 !important;
  border-radius: 10px !important;
  background: #fff !important;
  transition: border-color 0.2s, box-shadow 0.2s !important;
}

.form-select:focus,
.form-control:focus {
  outline: none !important;
  border-color: #c35b28 !important;
  box-shadow: 0 0 0 3px rgba(195, 91, 40, 0.15) !important;
}

/* ── 10. MOBILE RESPONSIVE LOCK ───────────────────────────── */
@media (max-width: 767px) {
  .site-header .header-nav {
    display: none !important;
  }
  
  .header-actions {
    gap: 0.25rem !important;
  }
  
  .header-actions .btn {
    padding: 0.4rem 0.75rem !important;
    font-size: 0.8rem !important;
  }
  
  .container-xl {
    padding-left: 0.75rem !important;
    padding-right: 0.75rem !important;
  }
  
  .ilan-grid {
    grid-template-columns: 1fr !important;
  }
  
  .site-footer {
    padding: 1.5rem 0 !important;
  }

  /* Footer mobil: anasayfadaki gibi Bootstrap col-6 2-sütun düzeni */
  .site-footer .container-xl {
    padding-left: 16px !important;
    padding-right: 16px !important;
  }

  .site-footer .row {
    display: flex !important;
    flex-wrap: wrap !important;
    gap: 0 !important;
    margin-left: -8px !important;
    margin-right: -8px !important;
  }

  /* Logo + tanıtım: tam genişlik */
  .site-footer .row > .col-lg-4,
  .site-footer .row > .col-12.col-lg-4 {
    flex: 0 0 100% !important;
    max-width: 100% !important;
    padding: 0 8px !important;
    margin-bottom: 1.25rem !important;
  }

  /* Navigasyon sütunları: 2'li ızgara */
  .site-footer .row > .col-6,
  .site-footer .row > .col-6.col-sm-3,
  .site-footer .row > .col-6.col-lg-2,
  .site-footer .row > .col-lg-2,
  .site-footer .row > .col-6.col-sm-3.col-lg-2 {
    flex: 0 0 50% !important;
    max-width: 50% !important;
    padding: 0 8px !important;
    margin-bottom: 1rem !important;
  }

  .site-footer .footer-title {
    font-size: 0.8rem !important;
    margin-bottom: 0.5rem !important;
    letter-spacing: 0.02em !important;
  }

  .site-footer .footer-links a,
  .site-footer .footer-links li {
    font-size: 0.82rem !important;
    line-height: 1.7 !important;
    margin-bottom: 0.25rem !important;
  }

  .site-footer p.small {
    font-size: 0.82rem !important;
    line-height: 1.5 !important;
  }
  
  .footer-brand img {
    height: 36px !important;
  }

  .sosyal-btn {
    width: 30px !important;
    height: 30px !important;
    font-size: 13px !important;
  }

  .site-footer .d-flex.gap-2 {
    gap: 6px !important;
  }

  /* Footer bottom bar mobil */
  .footer-bottom-bar {
    flex-direction: column !important;
    align-items: center !important;
    text-align: center !important;
    gap: 4px !important;
    font-size: 10px !important;
  }

  .fbb-left {
    text-align: center !important;
    font-size: 9px !important;
  }

  .fbb-right {
    justify-content: center !important;
    font-size: 10px !important;
    gap: 5px !important;
  }

  .site-footer hr {
    margin: 0.5rem 0 !important;
  }
}

/* ── 11. SKELETON LOADER LOCK ─────────────────────────────── */
.ilan-karti-skeleton {
  background: #fff !important;
  border-radius: 16px !important;
  overflow: hidden !important;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.06) !important;
}

.ilan-karti-skeleton::before {
  content: '' !important;
  display: block !important;
  padding-top: 62.5% !important;
  background: linear-gradient(90deg, #f0f0f0 25%, #e0e0e0 50%, #f0f0f0 75%) !important;
  background-size: 200% 100% !important;
  animation: skeleton-loading 1.5s infinite !important;
}

@keyframes skeleton-loading {
  0% { background-position: 200% 0; }
  100% { background-position: -200% 0; }
}

/* ── 12. UTILITY CLASSES LOCK ─────────────────────────────── */
.text-muted { color: #6b7280 !important; }
.text-danger { color: #dc2626 !important; }
.text-success { color: #059669 !important; }
.text-center { text-align: center !important; }
.fw-bold, .fw-700 { font-weight: 700 !important; }
.fw-800 { font-weight: 800 !important; }
.d-flex { display: flex !important; }
.d-none { display: none !important; }
.d-block { display: block !important; }
.flex-column { flex-direction: column !important; }
.flex-wrap { flex-wrap: wrap !important; }
.align-items-center { align-items: center !important; }
.justify-content-center { justify-content: center !important; }
.justify-content-between { justify-content: space-between !important; }
.gap-1 { gap: 0.25rem !important; }
.gap-2 { gap: 0.5rem !important; }
.gap-3 { gap: 1rem !important; }
.gap-4 { gap: 1.5rem !important; }
.w-100 { width: 100% !important; }
.mt-2 { margin-top: 0.5rem !important; }
.mt-3 { margin-top: 1rem !important; }
.mb-2 { margin-bottom: 0.5rem !important; }
.mb-3 { margin-bottom: 1rem !important; }
.py-3 { padding-top: 1rem !important; padding-bottom: 1rem !important; }
.py-5 { padding-top: 3rem !important; padding-bottom: 3rem !important; }
.small { font-size: 0.875rem !important; }
