[x-cloak] {
  display: none !important;
}

:root {
  --gold: #C89B3C;
  --ink: #0F172A;
  --body: #475569;
  --line: #E5E7EB;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  color: var(--body);
  font-family: 'Inter', Arial, sans-serif;
  background: #FFFFFF;
}

.font-serif {
  font-family: 'Playfair Display', Georgia, serif;
}

/* Hero Arka Planı */
.hero-image {
  background-image: 
    linear-gradient(90deg, #ffffff 0%, rgba(255,255,255,0.96) 35%, rgba(255,255,255,0.7) 55%, rgba(255,255,255,0.1) 75%),
    url('../img/hero-midyat-large.jpg');
  background-size: cover;
  background-position: center right;
}

@media (max-width: 1023px) {
  .hero-image {
    background-image: 
      linear-gradient(90deg, rgba(255,255,255,0.98) 0%, rgba(255,255,255,0.92) 100%),
      url('../img/hero-midyat-large.jpg');
  }
}

/* CTA Banner Arka Planı */
.cta-banner {
  background: 
    linear-gradient(135deg, rgba(15,23,42,0.98) 0%, rgba(30,41,59,0.95) 100%),
    url('../img/hero-midyat-large.jpg');
  background-size: cover;
  background-position: center;
}

/* Sticky Header */
.site-header {
  transition: box-shadow 0.2s ease, background-color 0.2s ease;
}
.site-header .header-bar {
  height: 96px;
  transition: height 0.2s ease;
}
.site-header .site-logo {
  height: 48px;
  width: 48px;
  transition: height 0.2s ease, width 0.2s ease;
}
.site-header .site-logo-text {
  font-size: 24px;
  transition: font-size 0.2s ease;
}
.site-header.is-scrolled {
  box-shadow: 0 6px 24px -12px rgba(15,23,42,0.18);
  background: rgba(255,255,255,0.97);
  backdrop-filter: blur(8px);
}
.site-header.is-scrolled .header-bar {
  height: 72px;
}
.site-header.is-scrolled .site-logo {
  height: 38px;
  width: 38px;
}
.site-header.is-scrolled .site-logo-text {
  font-size: 20px;
}

[id] {
  scroll-margin-top: 100px;
}

/* Kart & İkon İnce Geçişleri */
.card-hover {
  transition: transform 0.25s cubic-bezier(0.2, 0.7, 0.3, 1), box-shadow 0.25s ease;
}
.card-hover:hover {
  transform: translateY(-4px);
  box-shadow: 0 14px 30px -10px rgba(15, 23, 42, 0.12);
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    transition-duration: 0.01ms !important;
    animation-duration: 0.01ms !important;
  }
  html {
    scroll-behavior: auto;
  }
}

/* ==========================================================================
   Yönetim paneli — premium görsel dil
   Tek shadow yerine katmanlı gölge; hover'da yükselme; yumuşak geçişler.
   ========================================================================== */

.admin-layout {
  background:
    radial-gradient(1200px 400px at 20% -10%, rgba(200,155,60,.05), transparent 60%),
    #F8FAFC;
}

.admin-card {
  box-shadow:
    0 1px 2px rgba(15,23,42,.04),
    0 8px 20px -12px rgba(15,23,42,.10);
  transition: box-shadow .24s cubic-bezier(.2,.7,.3,1), transform .24s cubic-bezier(.2,.7,.3,1);
}
.admin-card:hover {
  box-shadow:
    0 1px 2px rgba(15,23,42,.05),
    0 12px 28px -12px rgba(15,23,42,.16),
    0 32px 60px -32px rgba(15,23,42,.20);
}

/* KPI kartı üstünde ince altın vurgu — hover'da belirir */
.admin-card.group::before {
  content: '';
  position: absolute;
  inset: 0 0 auto 0;
  height: 2px;
  background: linear-gradient(90deg, transparent, var(--gold), transparent);
  opacity: 0;
  transition: opacity .24s ease;
}
.admin-card.group:hover::before { opacity: 1; }
.admin-card.group:hover { transform: translateY(-2px); }

/* Hızlı işlem kutuları */
.quick-action {
  transition: transform .2s cubic-bezier(.2,.7,.3,1), box-shadow .2s ease, border-color .2s ease;
}
.quick-action:hover {
  transform: translateY(-3px);
  box-shadow: 0 10px 22px -12px rgba(15,23,42,.22);
}

/* Sidebar bağlantıları — aktif durum belirgin */
.sidebar-link {
  display: flex; align-items: center; gap: .65rem;
  padding: .58rem .75rem; border-radius: .7rem;
  color: #64748B; font-size: .82rem; font-weight: 600;
  transition: background-color .18s ease, color .18s ease, transform .18s ease;
}
.sidebar-link:hover { background: #F1F5F9; color: #0F172A; transform: translateX(2px); }
.sidebar-link.active {
  background: linear-gradient(90deg, rgba(200,155,60,.16), rgba(200,155,60,.06));
  color: #A27621;
  box-shadow: inset 2px 0 0 var(--gold);
}
.sidebar-link svg { flex-shrink: 0; }

/* Tablo satırlarında yumuşak vurgu */
.admin-card tbody tr { transition: background-color .16s ease; }

/* İnce kaydırma çubuğu */
.admin-layout ::-webkit-scrollbar { width: 8px; height: 8px; }
.admin-layout ::-webkit-scrollbar-track { background: transparent; }
.admin-layout ::-webkit-scrollbar-thumb { background: #E2E8F0; border-radius: 8px; }
.admin-layout ::-webkit-scrollbar-thumb:hover { background: #CBD5E1; }

@media (prefers-reduced-motion: reduce) {
  .admin-card, .quick-action, .sidebar-link { transition: none !important; }
  .admin-card:hover, .quick-action:hover, .admin-card.group:hover { transform: none; }
}

/* Panel iskeleti — içerik az olduğunda sayfa boş kalmasın */
.admin-layout { min-height: 100vh; display: flex; flex-direction: column; }
.admin-layout > main { flex: 1 0 auto; }

/* Sidebar: uzun menüde alt öğeler kesilmesin */
.admin-sidebar {
  display: flex; flex-direction: column;
  height: 100vh; overflow-y: auto;
  overscroll-behavior: contain;
  padding-bottom: 1rem;
}
.admin-sidebar::-webkit-scrollbar { width: 6px; }
.admin-sidebar::-webkit-scrollbar-thumb { background: #E2E8F0; border-radius: 6px; }

/* Boş durum kartları dikeyde nefes alsın */
.admin-empty { min-height: 320px; display: grid; place-items: center; }

/* Panel: iki satır sonrası kırpma (yorum metinleri) */
.line-clamp-2 {
  display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical;
  overflow: hidden;
}
/* Sayılar hizalı dursun */
.tabular-nums { font-variant-numeric: tabular-nums; }

/* Akıllı arama — yükleniyor göstergeleri */
.ai-nokta {
  width: 7px; height: 7px; border-radius: 999px; background: var(--gold);
  animation: aiNabiz 1s ease-in-out infinite;
}
@keyframes aiNabiz { 0%,100% { opacity: .3; transform: scale(.8); } 50% { opacity: 1; transform: scale(1); } }

.ai-spinner {
  width: 16px; height: 16px; border-radius: 999px;
  border: 2px solid rgba(255,255,255,.35); border-top-color: #fff;
  animation: aiDon .7s linear infinite;
}
@keyframes aiDon { to { transform: rotate(360deg); } }

@media (prefers-reduced-motion: reduce) {
  .ai-nokta, .ai-spinner { animation: none; }
}


/* Üst menü — tüm öğeler tek satırda ve aynı yükseklikte.
   Aktif öğedeki kalın yazı + alt çizgi diğerlerini hizadan kaydırıyordu. */
.site-header nav > a,
.site-header nav > div > button {
  height: 34px;
  display: inline-flex;
  align-items: center;
  line-height: 1;
  white-space: nowrap;
  padding-bottom: 2px;
}

/* ==========================================================================
   Akıllı Arama butonu (FAB) — sağ altta sabit
   Beyaz zemin + gradyan kenarlık. Kenarlık, iki katmanlı background ile
   yapılır (border-image yuvarlak köşelerde güvenilir çalışmaz).
   ========================================================================== */
.ai-fab {
  position: fixed;
  right: 20px;
  bottom: 20px;
  z-index: 60;                /* interstitial (70) altında, sticky reklam (55) üstünde */
  padding: 2px;               /* gradyan kenarlık kalınlığı */
  border: 0;
  border-radius: 999px;
  cursor: pointer;
  background: linear-gradient(135deg, #C89B3C 0%, #A78BFA 45%, #6366F1 100%);
  box-shadow:
    0 2px 6px rgba(15, 23, 42, .10),
    0 12px 28px -10px rgba(99, 102, 241, .35);
  transition: transform .22s cubic-bezier(.2, .7, .3, 1), box-shadow .22s ease;
}

.ai-fab:hover {
  transform: translateY(-3px);
  box-shadow:
    0 2px 8px rgba(15, 23, 42, .12),
    0 18px 40px -12px rgba(99, 102, 241, .48);
}
.ai-fab:active { transform: translateY(-1px) scale(.985); }
.ai-fab:focus-visible { outline: 3px solid rgba(200, 155, 60, .45); outline-offset: 3px; }

.ai-fab-inner {
  display: flex;
  align-items: center;
  gap: 9px;
  padding: 11px 20px 11px 16px;
  background: #fff;
  border-radius: 999px;
}

/* İkon ve metin gradyanla boyanır */
.ai-fab-icon {
  display: grid;
  place-items: center;
  color: #7C6BF0;
  transition: transform .3s cubic-bezier(.2, .7, .3, 1);
}
.ai-fab:hover .ai-fab-icon { transform: rotate(-12deg) scale(1.12); }

.ai-fab-text {
  font-weight: 700;
  font-size: 15px;
  letter-spacing: -.01em;
  background: linear-gradient(135deg, #B0862F 0%, #6D5BE0 55%, #4F46E5 100%);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  white-space: nowrap;
}

/* Mobilde daha küçük; alt sticky reklam varsa yukarı kayar */
@media (max-width: 640px) {
  .ai-fab { right: 14px; bottom: 14px; }
  .ai-fab-inner { padding: 10px 16px 10px 13px; gap: 7px; }
  .ai-fab-text { font-size: 14px; }
}
body:has(#adMobileSticky:not([style*="display: none"])) .ai-fab { bottom: 74px; }

@media (prefers-reduced-motion: reduce) {
  .ai-fab, .ai-fab-icon { transition: none; }
  .ai-fab:hover { transform: none; }
  .ai-fab:hover .ai-fab-icon { transform: none; }
}

/* Akıllı Arama penceresi açıkken FAB gizlenir */
body.ai-acik .ai-fab { opacity: 0; pointer-events: none; }