/* Duyuru / Haber / Etkinlik — detay sayfaları (KKU tema) */

.kku-detay {
  --kku-red: #c9151b;
  --kku-darkred: #9e1b32;
  --kku-navy: #053170;
  --kku-paper: #f7f8fa;
  --kku-ink: #01172f;
  --kku-muted: #5c6b7a;

  padding: 28px 0 48px;
  background:
    radial-gradient(ellipse 42% 36% at 0% 0%, rgba(201, 21, 27, 0.05), transparent 55%),
    radial-gradient(ellipse 40% 34% at 100% 100%, rgba(5, 49, 112, 0.05), transparent 50%),
    var(--kku-paper);
}

.kku-detay-card {
  background: #fff;
  border-radius: 14px;
  border: 1px solid rgba(1, 23, 47, 0.06);
  box-shadow: 0 6px 22px rgba(1, 23, 47, 0.08);
  padding: 28px 28px 24px;
  position: relative;
  overflow: hidden;
}

.kku-detay-card::before {
  content: "";
  position: absolute;
  left: 0;
  right: 0;
  top: 0;
  height: 3px;
  background: linear-gradient(90deg, var(--kku-red), var(--kku-navy));
}

.kku-detay-header {
  margin-bottom: 22px;
  padding-bottom: 18px;
  border-bottom: 1px solid rgba(1, 23, 47, 0.08);
}

.kku-detay-meta {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 12px;
  gap: 12px;
}

.kku-detay-date {
  color: var(--kku-muted);
  font-size: 0.92rem;
  display: inline-flex;
  align-items: center;
  gap: 6px;
}

.kku-detay-date i {
  color: var(--kku-navy);
}

.kku-detay-title {
  margin: 0;
  font-size: 1.5rem;
  font-weight: 800;
  line-height: 1.35;
  color: var(--kku-navy);
  letter-spacing: -0.02em;
}

.kku-detay-body {
  font-size: 1.02rem;
  line-height: 1.7;
  color: var(--kku-ink);
}

.kku-detay-body * {
  font-family: inherit !important;
}

.kku-detay-body img {
  margin: 18px 0;
  max-width: 100%;
  height: auto;
  border-radius: 10px;
}

.kku-detay-body p {
  margin: 14px 0;
}

.kku-detay-body a {
  color: var(--kku-red);
}

.kku-detay-sidebar {
  background: #fff;
  border-radius: 14px;
  border: 1px solid rgba(1, 23, 47, 0.06);
  box-shadow: 0 6px 22px rgba(1, 23, 47, 0.08);
  padding: 20px;
  position: relative;
  overflow: hidden;
}

.kku-detay-sidebar::before {
  content: "";
  position: absolute;
  left: 0;
  right: 0;
  top: 0;
  height: 3px;
  background: linear-gradient(90deg, var(--kku-red), var(--kku-navy));
}

.kku-detay-sidebar-title {
  font-size: 1.15rem;
  font-weight: 800;
  color: var(--kku-navy);
  margin: 0 0 16px;
  padding-bottom: 12px;
  border-bottom: 2px solid rgba(5, 49, 112, 0.12);
  display: flex;
  align-items: center;
  gap: 8px;
}

.kku-detay-sidebar-title i {
  color: var(--kku-red);
}

.kku-detay-side-list {
  margin-bottom: 16px;
}

.kku-detay-side-item {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 10px 8px;
  border-bottom: 1px solid rgba(1, 23, 47, 0.06);
  border-radius: 8px;
  transition: background 0.2s ease, transform 0.2s ease;
}

.kku-detay-side-item:hover {
  background: rgba(5, 49, 112, 0.04);
  transform: translateX(3px);
}

.kku-detay-side-item.is-active {
  background: rgba(201, 21, 27, 0.06);
  border-left: 3px solid var(--kku-red);
}

.kku-detay-side-badge {
  display: inline-flex;
  align-items: baseline;
  gap: 4px;
  flex-shrink: 0;
  min-width: 0;
  padding: 3px 8px;
  border-radius: 999px;
  background: rgba(5, 49, 112, 0.06);
  border: 1px solid rgba(5, 49, 112, 0.1);
  text-align: left;
}

.kku-detay-side-badge .day {
  display: inline;
  font-size: 0.82rem;
  font-weight: 800;
  color: var(--kku-navy);
  line-height: 1.2;
}

.kku-detay-side-badge .month {
  display: inline;
  font-size: 0.72rem;
  font-weight: 700;
  color: var(--kku-muted);
  text-transform: uppercase;
}

.kku-detay-side-thumb {
  width: 88px;
  height: 56px;
  flex-shrink: 0;
  border-radius: 8px;
  overflow: hidden;
  background: #e8eef4;
}

.kku-detay-side-thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.kku-detay-side-brief {
  flex: 1;
  min-width: 0;
}

.kku-detay-side-brief a {
  color: var(--kku-ink) !important;
  text-decoration: none !important;
  font-size: 0.9rem;
  font-weight: 600;
  line-height: 1.35;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.kku-detay-side-brief a:hover {
  color: var(--kku-red) !important;
}

.kku-detay-all {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  background: var(--kku-navy);
  color: #fff !important;
  padding: 12px;
  border-radius: 10px;
  text-decoration: none !important;
  font-weight: 600;
  transition: background 0.2s ease, transform 0.2s ease;
}

.kku-detay-all:hover {
  background: var(--kku-red);
  color: #fff !important;
  transform: translateY(-2px);
}

.kku-detay .btn-print {
  background: transparent;
  color: var(--kku-navy);
  border: 0;
  padding: 8px;
  cursor: pointer;
  transition: color 0.2s ease, transform 0.2s ease;
}

.kku-detay .btn-print:hover {
  color: var(--kku-red);
  transform: translateY(-1px);
}

.kku-detay .btn-print i {
  font-size: 1.1rem;
}

/* Eski overlay kalıntısı — DOM’da olsa bile asla görünmesin */
.print-overlay {
  display: none !important;
  visibility: hidden !important;
  opacity: 0 !important;
  pointer-events: none !important;
  position: fixed !important;
  inset: 0;
  width: 0 !important;
  height: 0 !important;
  overflow: hidden !important;
  z-index: -1;
}

.kku-detay .modern-pagination {
  margin-top: 16px;
  display: flex;
  justify-content: center;
}

.kku-detay .pagination-container {
  display: flex;
  align-items: center;
  gap: 5px;
  flex-wrap: wrap;
  justify-content: center;
}

.kku-detay .page-link {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 34px;
  height: 34px;
  border-radius: 8px;
  background: #fff;
  color: var(--kku-navy) !important;
  text-decoration: none !important;
  font-size: 0.85rem;
  font-weight: 600;
  border: 1px solid rgba(1, 23, 47, 0.1);
  transition: background 0.2s ease, color 0.2s ease, border-color 0.2s ease;
}

.kku-detay .page-link:hover {
  border-color: var(--kku-navy);
}

.kku-detay .page-link.active {
  background: var(--kku-navy);
  border-color: var(--kku-navy);
  color: #fff !important;
}

.kku-detay .page-dots {
  color: var(--kku-muted);
  padding: 0 4px;
}

.kku-detay .haber-gallery-container {
  margin-top: 28px;
  padding-top: 18px;
  border-top: 1px solid rgba(1, 23, 47, 0.08);
}

.kku-detay .haber-gallery-container.empty {
  display: none;
}

.kku-detay .gallery-title {
  font-size: 1.1rem;
  color: var(--kku-navy);
  margin-bottom: 14px;
  display: flex;
  align-items: center;
  gap: 8px;
  font-weight: 700;
}

.kku-detay .gallery-title i {
  color: var(--kku-red);
}

.kku-detay .haber-gallery {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(150px, 1fr));
  gap: 10px;
  margin-bottom: 20px;
}

.kku-detay .gallery-item {
  position: relative;
  border-radius: 10px;
  overflow: hidden;
  cursor: pointer;
  height: 120px;
  box-shadow: 0 4px 14px rgba(1, 23, 47, 0.1);
  transition: transform 0.25s ease, box-shadow 0.25s ease;
}

.kku-detay .gallery-item:hover {
  transform: translateY(-4px);
  box-shadow: 0 8px 20px rgba(1, 23, 47, 0.16);
}

.kku-detay .gallery-item img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.35s ease;
}

.kku-detay .gallery-item:hover img {
  transform: scale(1.08);
}

.lightbox {
  position: fixed;
  inset: 0;
  background: rgba(1, 23, 47, 0.92);
  display: flex;
  justify-content: center;
  align-items: center;
  z-index: 9999;
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.3s ease, visibility 0.3s ease;
}

.lightbox.active {
  opacity: 1;
  visibility: visible;
}

.lightbox-content {
  position: relative;
  max-width: 90%;
  max-height: 80vh;
  margin: 0 auto;
}

.lightbox-image {
  display: block;
  max-width: 100%;
  max-height: 80vh;
  border-radius: 8px;
  box-shadow: 0 8px 32px rgba(0, 0, 0, 0.35);
}

.lightbox-close {
  position: absolute;
  top: -40px;
  right: 0;
  color: #fff;
  font-size: 24px;
  background: transparent;
  border: none;
  cursor: pointer;
}

.lightbox-nav {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  width: 100%;
  display: flex;
  justify-content: space-between;
  padding: 0 20px;
  pointer-events: none;
}

.lightbox-nav button {
  pointer-events: auto;
  background: rgba(255, 255, 255, 0.2);
  color: #fff;
  border: none;
  width: 40px;
  height: 40px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
}

.lightbox-counter {
  position: absolute;
  bottom: -30px;
  left: 0;
  width: 100%;
  text-align: center;
  color: #fff;
  font-size: 14px;
}

@media (max-width: 768px) {
  .kku-detay .haber-gallery {
    grid-template-columns: repeat(auto-fill, minmax(100px, 1fr));
  }

  .kku-detay .gallery-item {
    height: 100px;
  }
}

@media (max-width: 768px) {
  .kku-detay {
    padding: 8px 0 20px;
  }

  .kku-detay-card {
    padding: 16px 12px;
  }

  .kku-detay-title {
    font-size: 1.25rem;
  }

  .kku-detay-sidebar {
    margin-top: 18px;
  }

  .kku-detay > .container {
    padding-left: 10px;
    padding-right: 10px;
  }
}

/* Sayfa gövdesi (Anasayfa + Idari) — boş header / fazla padding kartı ekrandan koparıyor */
.Sayfa-detay {
  min-height: 0 !important;
  padding: 12px 0 24px !important;
}

.Sayfa-detay .Sayfa-header:not(:has(h1, h2, h3, .print-button, .btn-print, img, a)) {
  display: none !important;
  margin: 0 !important;
  padding: 0 !important;
  border: none !important;
}

.Sayfa-detay .Sayfa-meta:empty {
  display: none !important;
}

@media (max-width: 768px) {
  .Sayfa-detay {
    padding: 8px 0 16px !important;
  }

  .Sayfa-detay > .container {
    padding-left: 10px !important;
    padding-right: 10px !important;
  }

  .Sayfa-detay .col-md-12 {
    padding-left: 0;
    padding-right: 0;
  }

  .Sayfa-detay .Sayfa-content-card {
    padding: 0 !important;
    margin: 0 !important;
    background: transparent !important;
    box-shadow: none !important;
    border: none !important;
    border-radius: 0 !important;
  }

  .Sayfa-detay .Sayfa-header {
    margin-bottom: 0 !important;
    padding-bottom: 0 !important;
    border: none !important;
  }

  .Sayfa-detay .Sayfa-header:has(h1, h2, h3) {
    margin-bottom: 12px !important;
  }

  .Sayfa-detay .Sayfa-body,
  .Sayfa-detay .table-wrapper,
  .Sayfa-detay .SayfaIcerik {
    margin: 0 !important;
    padding: 0 !important;
  }

  .Sayfa-detay .Sayfa-body .kku-rektor img,
  .Sayfa-detay .Sayfa-body .kku-birim-doc img {
    margin-top: 0 !important;
    margin-left: auto !important;
    margin-right: auto !important;
  }
}

@media print {
  .breadcrumbSection,
  .kku-detay-sidebar,
  .btn-print,
  .kku-detay-meta,
  .print-overlay {
    display: none !important;
  }
}
