﻿/*
  CATEGORY SAYFASI OZEL CSS
  Bu dosya kategori listeleme sayfasinda yuklenir.
  Buradaki kurallar kategori basligi, kategori yazilari, kategori reklamlari,
  kategori sayfalama ve kategori mobil kart gorunumunu kontrol eder.
*/

/* Kategori ust aciklama alani */
.page-category .listing-hero--plain {
  margin: 0;
  border: 0;
  background: transparent;
  padding: 14px;
}

/* Kategori icerik listesinin genel cercevesi */
.page-category .posts {
  padding: 0;
}

.page-category .post-list {
  display: block;
}

/* Yonetim panelinden secilen 3'lu / 4'lu kategori grid gorunumu */
.page-category .post-list--grid3,
.page-category .post-list--grid4 {
  display: grid;
  gap: 16px;
  padding: 5px;
  box-sizing: border-box;
  margin-bottom: 10px;
}

/* 3'lu grid kolon sayisi */
.page-category .post-list--grid3 {
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

/* 4'lu grid kolon sayisi */
.page-category .post-list--grid4 {
  grid-template-columns: repeat(4, minmax(0, 1fr));
}

/* Grid kartlarinin kutu, radius ve arka plan ayarlari */
.page-category .post-list--grid3 .post-item,
.page-category .post-list--grid4 .post-item {
  display: block;
  border: 0px solid var(--line-soft);
  border-radius: 5px;
  padding: 0px;
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.98) 0%, rgba(247, 250, 252, 0.95) 100%);
  align-content: start;
}

/* Grid kartlarindaki gorsel alani */
.page-category .post-list--grid3 .post-item__thumb,
.page-category .post-list--grid4 .post-item__thumb {
  height: auto;
  min-height: 190px;
  margin-bottom: 10px;
  overflow: hidden;
  border-radius: 3px; border: 0px solid var(--line-soft);
}

/* Grid kart baslik ve ozet punto ayarlari */
.page-category .post-list--grid3 .post-item__body h3,
.page-category .post-list--grid4 .post-item__body h3 {
  font-size: 1.01rem;
  margin-bottom: 8px;text-align: center;
}

.page-category .post-list--grid3 .post-item__body p,
.page-category .post-list--grid4 .post-item__body p {
  font-size: 0.76rem;
  line-height: 1.5; text-align: center;
}

.page-category .post-list--grid3 .post-item .meta,
.page-category .post-list--grid4 .post-item .meta {
  font-size: 0.82rem;
  margin-bottom: 6px;
  text-align: center;
  justify-content: center;
  display: flex;
  width: 100%;
}

.page-category .post-list--grid3 .post-item:nth-child(6n+1) .meta,
.page-category .post-list--grid4 .post-item:nth-child(6n+1) .meta {
  color: #6c4a8a;
}

.page-category .post-list--grid3 .post-item:nth-child(6n+2) .meta,
.page-category .post-list--grid4 .post-item:nth-child(6n+2) .meta {
  color: #2f6f7b;
}

.page-category .post-list--grid3 .post-item:nth-child(6n+3) .meta,
.page-category .post-list--grid4 .post-item:nth-child(6n+3) .meta {
  color: #7a5a2f;
}

.page-category .post-list--grid3 .post-item:nth-child(6n+4) .meta,
.page-category .post-list--grid4 .post-item:nth-child(6n+4) .meta {
  color: #2f6a4f;
}

.page-category .post-list--grid3 .post-item:nth-child(6n+5) .meta,
.page-category .post-list--grid4 .post-item:nth-child(6n+5) .meta {
  color: #7a3f54;
}

.page-category .post-list--grid3 .post-item:nth-child(6n) .meta,
.page-category .post-list--grid4 .post-item:nth-child(6n) .meta {
  color: #355b86;
}

/* Normal liste gorunumunde sol gorsel + sag metin yerlesimi */
.page-category .post-list:not(.post-list--grid3):not(.post-list--grid4) .post-item {
  grid-template-columns: 280px minmax(0, 1fr);
  align-items: start;
}

/* Normal liste gorunumundeki gorsel boyutu */
.page-category .post-list:not(.post-list--grid3):not(.post-list--grid4) .post-item__thumb {
  width: 270px;
  height: auto;
  min-height: 200px;
}

/* Her kategori yazisi icin ana kart satiri */
.page-category .post-item {
  display: grid;
  grid-template-columns: 140px minmax(0, 1fr) 110px;
  gap: 16px;
  padding: 12px;
  border-bottom: 1px solid var(--line-soft);
  align-items: center;
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.96) 0%, rgba(247, 250, 252, 0.9) 100%);
  transition: background 0.18s ease, box-shadow 0.18s ease, transform 0.18s ease;
}

.page-category .post-item--clickable {
  cursor: pointer;
}

/* Kart uzerine gelince hafif yukselme efekti */
.page-category .post-item:hover {
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.99) 0%, rgba(249, 252, 254, 0.96) 100%);
  box-shadow: 0 10px 24px rgba(23, 52, 71, 0.05);
  transform: translateY(-2px);
}

/* Tum kategori gorsellerinin dis kutusu */
.page-category .post-item__thumb {
  min-height: 98px;
  border-radius: 2px;
  border: 0px solid var(--line-soft);
  padding: 5px;
  overflow: hidden;
}

/* Kategori yazisi basligi */
.page-category .post-item__body h3 {
  font-size: 1.2rem;
  margin-bottom: 8px; color:;
}

/* Tarih/kategori gibi meta bilgilerin hizasi */
.page-category .post-item__meta {
  justify-content: space-between;
  align-items: flex-end;
  flex-direction: column; 
}

/* Kategori listesi arasina giren reklam kutusu */
.page-category .content-ad {
  margin: 8px 8px 0;
  padding: 12px;
  border: 1px dashed var(--line-strong);
  border-radius: 5px;
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.98) 0%, rgba(247, 250, 252, 0.92) 100%);
  overflow: hidden;
}

/* Grid gorunumunde reklam tam satiri kaplar */
.page-category .post-list--grid3 .content-ad,
.page-category .post-list--grid4 .content-ad {
  grid-column: 1 / -1;
  margin: 0;
}

.page-category .content-ad--feed {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 100%;
  min-height: 72px;
  text-align: center;
}

.page-category .post-list--grid3 .content-ad--feed,
.page-category .post-list--grid4 .content-ad--feed,
.page-category .post-list .content-ad--feed {
  grid-column: 1 / -1;
  width: 100%;
}

.page-category .content-ad iframe,
.page-category .content-ad ins {
  max-width: 100%;
}

/* Kategori ve grid gorsel netlik/renk ayarlari */
.page-category .post-item__thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center;
  display: block;
  filter: saturate(0.7) contrast(1.04) brightness(0.95);
  border-radius: 3px;
  border: 0px solid rgba(203, 217, 227, 0.7);
  background: #eef4f8;
}

/* Kategori sayfalama alani */
.page-category .pagination {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
  margin-top: 8px;
  padding: 18px;
  border-top:0px solid var(--line);
  background:
    radial-gradient(circle at top left, rgba(38, 87, 128, 0.08), transparent 36%),
    linear-gradient(180deg, #fbfdff 0%, #f3f8fb 100%);
}

/* Sayfalama ozet metni: "1 / 3 sayfa" gibi */
.page-category .pagination__summary {
  color: var(--muted);
  font-size: 0.92rem;
  font-weight: 700;
  letter-spacing: 0.02em;
  white-space: nowrap;
}

/* Sayfalama butonlarini tasiyan alan */
.page-category .pagination__track {
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-end;
  gap: 10px;
}

/* Sayfalama butonlari */
.page-category .pagination__link,
.page-category .pagination__ellipsis {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 44px;
  min-height: 44px;
  padding: 0 16px;
  border-radius: 999px;
  font-weight: 700;
}

/* Sayfalama normal buton rengi */
.page-category .pagination__link {
  border: 1px solid rgba(38, 87, 128, 0.16);
  background: rgba(255, 255, 255, 0.9);
  color: var(--text);
  box-shadow: 0 8px 18px rgba(23, 52, 71, 0.06);
  transition: transform 0.18s ease, box-shadow 0.18s ease, border-color 0.18s ease, background 0.18s ease, color 0.18s ease;
}

.page-category .pagination__link:hover {
  transform: translateY(-1px);
  border-color: rgba(38, 87, 128, 0.34);
  box-shadow: 0 12px 22px rgba(23, 52, 71, 0.1);
}

/* Sayfalama aktif sayfa butonu */
.page-category .pagination__link--active {
  border-color: var(--accent);
  background: linear-gradient(135deg, var(--accent) 0%, #d33d44 100%);
  color: #fff;
  box-shadow: 0 14px 28px rgba(197, 28, 34, 0.22);
}

.page-category .pagination__link--nav {
  padding-inline: 20px;
}

.page-category .pagination__ellipsis {
  color: var(--muted);
}

/* Tablet genisliklerinde liste gorsellerini biraz kucultur */
@media (max-width: 1200px) {
  .page-category .post-list:not(.post-list--grid3):not(.post-list--grid4) .post-item {
    grid-template-columns: 250px minmax(0, 1fr);
  }

  .page-category .post-list:not(.post-list--grid3):not(.post-list--grid4) .post-item__thumb {
    width: 250px;
    height: 184px;
    min-height: 184px;
  }
}

/* Dar tablet: grid secildiyse 2 kolon, sayfalama ortali */
@media (max-width: 980px) {
  .page-category .post-item {
    grid-template-columns: 1fr;
  }

  .page-category .post-item__meta {
    align-items: flex-start;
    flex-direction: row;
  }

  .page-category .post-list--grid3,
  .page-category .post-list--grid4 {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .page-category .pagination {
    flex-direction: column;
    align-items: stretch;
  }

  .page-category .pagination__summary {
    text-align: center;
  }

  .page-category .pagination__track {
    justify-content: center;
  }
}

/* Orta mobil/tablet arasi liste gorsel boyutu */
@media (max-width: 900px) {
  .page-category .post-list:not(.post-list--grid3):not(.post-list--grid4) .post-item {
    grid-template-columns: 200px minmax(0, 1fr);
  }

  .page-category .post-list:not(.post-list--grid3):not(.post-list--grid4) .post-item__thumb {
    width: 200px;
    height: 148px;
    min-height: 148px;
  }
}

/* Mobil: kategori yazilari her zaman 2'li kart grid olarak gorunur */
@media (max-width: 760px) {
  .page-category .post-item,
  .page-category .listing-hero {
    padding: 14px;
  }

  .page-category .post-list {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 12px;
    padding: 5px;
    box-sizing: border-box;
  }

  .page-category .post-list--grid3,
  .page-category .post-list--grid4 {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .page-category .post-list .post-item,
  .page-category .post-list:not(.post-list--grid3):not(.post-list--grid4) .post-item {
    display: block;
    grid-template-columns: none;
    border: 1px solid var(--line-soft);
    border-radius: 5px;
    padding: 8px;
  }

  .page-category .post-list .post-item__thumb,
  .page-category .post-list:not(.post-list--grid3):not(.post-list--grid4) .post-item__thumb {
    width: 100%;
    height: 120px;
    min-height: 120px;
    margin-bottom: 8px;
  }

  .page-category .post-list .post-item__body h3 {
    font-size: 0.98rem;
    margin-bottom: 6px;
  }

  .page-category .post-list .post-item__body p,
  .page-category .post-list .post-item .meta {
    font-size: 0.82rem;
    line-height: 1.45;
  }

  .page-category .post-list .content-ad {
    grid-column: 1 / -1;
    margin: 0;
  }
}
