@import url('https://fonts.googleapis.com/css2?family=Nunito:wght@400;600;700;800;900&display=swap');

/* =============================================
   HABER BLOĞU — Frontend CSS v1.0
   12 Kart Stili: klasik | overlay | minimal |
   bold | yatay | dergi | haber | saydam |
   neon | polaroid | atlas | ribbon
   ============================================= */

/* ---- CSS Değişkenleri ---- */
.hb-wrap {
  --hb-accent:    #3bbecb;
  --hb-bg:        #ffffff;
  --hb-bg2:       #f5f7fa;
  --hb-border:    #e2e8ed;
  --hb-text:      #1a2332;
  --hb-muted:     #6b7280;
  --hb-radius:    12px;
  --hb-shadow:    0 2px 12px rgba(0,0,0,.07);
  --hb-shadow-h:  0 8px 28px rgba(0,0,0,.14);
  --hb-font:      'Nunito', sans-serif;
  font-family: var(--hb-font);
  color: var(--hb-text);
}

/* ---- Karanlık Mod ---- */
.hb-dark {
  --hb-bg:     #1a2332;
  --hb-bg2:    #243044;
  --hb-border: rgba(255,255,255,.1);
  --hb-text:   #e8f0f8;
  --hb-muted:  #94a3b8;
  --hb-shadow: 0 2px 12px rgba(0,0,0,.3);
}

/* ---- Grid ---- */
.hb-grid { display: grid; gap: 22px; }
.hb-sutun-2 { grid-template-columns: repeat(2, 1fr); }
.hb-sutun-3 { grid-template-columns: repeat(3, 1fr); }
.hb-sutun-4 { grid-template-columns: repeat(4, 1fr); }
.hb-sutun-5 { grid-template-columns: repeat(5, 1fr); }
.hb-sutun-6 { grid-template-columns: repeat(6, 1fr); }

@media (max-width: 1100px) {
  .hb-sutun-5, .hb-sutun-6 { grid-template-columns: repeat(3, 1fr); }
  .hb-sutun-4                { grid-template-columns: repeat(3, 1fr); }
}
@media (max-width: 768px)  {
  .hb-sutun-3, .hb-sutun-4, .hb-sutun-5, .hb-sutun-6 { grid-template-columns: repeat(2, 1fr); }
}
@media (max-width: 500px)  { .hb-grid { grid-template-columns: 1fr !important; } }

/* ---- Masonry ---- */
.hb-masonry { column-gap: 22px; display: block; }
.hb-masonry .hb-kart { break-inside: avoid; margin-bottom: 22px; display: block; }
.hb-sutun-2.hb-masonry { columns: 2; }
.hb-sutun-3.hb-masonry { columns: 3; }
.hb-sutun-4.hb-masonry { columns: 4; }
@media (max-width: 768px) { .hb-masonry { columns: 2 !important; } }
@media (max-width: 500px) { .hb-masonry { columns: 1 !important; } }

/* ---- Liste ---- */
.hb-duzen-liste .hb-cards { display: flex; flex-direction: column; gap: 16px; }

/* ---- Carousel ---- */
.hb-carousel-inner { position: relative; overflow: hidden; }
.hb-duzen-carousel .hb-cards { display: flex; gap: 0; transition: transform .5s cubic-bezier(.4,0,.2,1); }
.hb-duzen-carousel .hb-kart  { min-width: calc(100% / 3); flex-shrink: 0; padding: 0 11px; box-sizing: border-box; }
.hb-carousel-nav { display: flex; align-items: center; justify-content: center; gap: 12px; margin-top: 18px; }
.hb-c-prev, .hb-c-next {
  width: 40px; height: 40px; border-radius: 50%; border: 2px solid var(--hb-accent);
  background: transparent; color: var(--hb-accent); font-size: 1.1rem; cursor: pointer;
  display: flex; align-items: center; justify-content: center; transition: all .2s;
}
.hb-c-prev:hover, .hb-c-next:hover { background: var(--hb-accent); color: #fff; }
.hb-c-dots { display: flex; gap: 6px; }
.hb-c-dot { width: 8px; height: 8px; border-radius: 50%; background: var(--hb-border); cursor: pointer; transition: background .2s; }
.hb-c-dot.aktif { background: var(--hb-accent); }

/* ---- Animasyonlar ---- */
.hb-anim-fade   .hb-kart { animation: hbFade   .6s ease both; }
.hb-anim-slide  .hb-kart { animation: hbSlide  .6s ease both; }
.hb-anim-zoom   .hb-kart { animation: hbZoom   .6s ease both; }
@keyframes hbFade  { from { opacity:0; transform: translateY(18px); } to { opacity:1; transform: none; } }
@keyframes hbSlide { from { opacity:0; transform: translateX(-24px); } to { opacity:1; transform: none; } }
@keyframes hbZoom  { from { opacity:0; transform: scale(.92); } to { opacity:1; transform: scale(1); } }

/* ---- Temel Kart ---- */
.hb-kart {
  background: var(--hb-bg);
  border-radius: var(--hb-radius);
  overflow: hidden;
  box-shadow: var(--hb-shadow);
  border: 1px solid var(--hb-border);
  transition: box-shadow .25s, transform .25s;
  position: relative;
}
.hb-wrap:not(.hb-nohover) .hb-kart:hover {
  box-shadow: var(--hb-shadow-h);
  transform: translateY(-4px);
}

/* ---- Resim ---- */
.hb-resim-wrap { overflow: hidden; width: 100%; }
.hb-resim-oran169  { aspect-ratio: 16/9; }
.hb-resim-oran43   { aspect-ratio: 4/3; }
.hb-resim-oran11   { aspect-ratio: 1/1; }
.hb-resim-oran34   { aspect-ratio: 3/4; }
.hb-resim { width: 100%; height: 100%; object-fit: cover; display: block; transition: transform .4s ease; }
.hb-wrap:not(.hb-nohover) .hb-kart:hover .hb-resim { transform: scale(1.04); }

/* ---- Ortak İçerik ---- */
.hb-icerik { padding: 16px; }
.hb-badge {
  display: inline-block; font-size: .68rem; font-weight: 800; text-transform: uppercase;
  letter-spacing: .06em; padding: 3px 10px; border-radius: 50px;
  background: var(--hb-cat-renk, var(--hb-accent)); color: #fff;
  text-decoration: none; margin-bottom: 8px;
}
.hb-baslik { margin: 0 0 8px; font-size: .95rem; font-weight: 800; line-height: 1.35; }
.hb-baslik a { color: var(--hb-text); text-decoration: none; transition: color .2s; }
.hb-baslik a:hover { color: var(--hb-accent); }
.hb-ozet { font-size: .83rem; color: var(--hb-muted); line-height: 1.6; margin: 0 0 10px; }
.hb-meta { display: flex; flex-wrap: wrap; gap: 8px; font-size: .75rem; color: var(--hb-muted); align-items: center; margin-top: auto; }
.hb-tarih, .hb-yorum, .hb-okuma { display: inline-flex; align-items: center; gap: 3px; }
.hb-yazar { font-size: .78rem; color: var(--hb-accent); text-decoration: none; font-weight: 700; display: block; margin-top: 6px; }
.hb-yazar:hover { text-decoration: underline; }

/* ---- AJAX ---- */
.hb-ajax-wrap { text-align: center; margin-top: 28px; }
.hb-daha-fazla {
  background: var(--hb-accent); color: #fff; border: none; padding: 12px 32px;
  border-radius: 50px; font-family: var(--hb-font); font-size: .9rem; font-weight: 700;
  cursor: pointer; transition: opacity .2s, transform .2s;
}
.hb-daha-fazla:hover { opacity: .88; transform: translateY(-2px); }
.hb-daha-fazla:disabled { opacity: .5; cursor: not-allowed; }

/* =============================================
   12 KART STİLİ
   ============================================= */

/* 1. KLASİK — varsayılan stil, yukarıda halihazırda tanımlı */

/* 2. OVERLAY */
.hb-kart-overlay { overflow: hidden; }
.hb-kart-overlay .hb-resim-wrap { position: relative; height: 100%; min-height: 200px; aspect-ratio: 4/3; }
.hb-kart-overlay .hb-resim { position: absolute; inset: 0; width: 100%; height: 100%; }
.hb-overlay-content {
  position: absolute; inset: 0;
  background: linear-gradient(to top, rgba(0,0,0,.82) 50%, rgba(0,0,0,.1) 100%);
  display: flex; flex-direction: column; justify-content: flex-end;
  padding: 16px; color: #fff;
}
.hb-kart-overlay .hb-badge { margin-bottom: 6px; }
.hb-kart-overlay .hb-baslik a { color: #fff; }
.hb-kart-overlay .hb-meta { color: rgba(255,255,255,.75); }

/* 3. MİNİMAL */
.hb-kart-minimal {
  background: transparent; border: none; border-bottom: 2px solid var(--hb-border);
  border-radius: 0; box-shadow: none; padding: 14px 0;
}
.hb-kart-minimal .hb-icerik { padding: 0; }
.hb-kart-minimal .hb-baslik { font-size: 1rem; }
.hb-wrap:not(.hb-nohover) .hb-kart-minimal:hover { transform: none; box-shadow: none; }
.hb-wrap:not(.hb-nohover) .hb-kart-minimal:hover .hb-baslik a { color: var(--hb-accent); }

/* 4. BOLD */
.hb-kart-bold {
  border: 3px solid var(--hb-accent);
  border-radius: var(--hb-radius);
  box-shadow: 4px 4px 0 var(--hb-accent);
  transition: box-shadow .2s, transform .2s;
}
.hb-wrap:not(.hb-nohover) .hb-kart-bold:hover {
  box-shadow: 6px 6px 0 var(--hb-accent);
  transform: translate(-2px, -2px);
}
.hb-kart-bold .hb-baslik { font-size: 1.05rem; font-weight: 900; }

/* 5. YATAY */
.hb-kart-yatay .hb-yatay-ic { display: flex; align-items: stretch; }
.hb-kart-yatay .hb-resim-wrap { width: 38%; min-width: 120px; aspect-ratio: 4/3; flex-shrink: 0; border-radius: 0; }
.hb-kart-yatay .hb-yatay-bilgi { flex: 1; padding: 14px 16px; display: flex; flex-direction: column; justify-content: center; }
.hb-kart-yatay .hb-baslik { font-size: .9rem; }
@media (max-width: 400px) { .hb-kart-yatay .hb-yatay-ic { flex-direction: column; } .hb-kart-yatay .hb-resim-wrap { width: 100%; } }

/* 6. DERGİ */
.hb-kart-dergi .hb-resim-wrap { aspect-ratio: 16/9; border-radius: var(--hb-radius) var(--hb-radius) 0 0; }
.hb-kart-dergi .hb-dergi-icerik { padding: 20px; }
.hb-kart-dergi .hb-baslik { font-size: 1.15rem; font-weight: 900; line-height: 1.3; }
.hb-kart-dergi .hb-ozet { font-size: .88rem; }

/* 7. HABER */
.hb-kart-haber { padding: 0; }
.hb-kart-haber .hb-icerik { padding: 14px; }
.hb-kart-haber .hb-baslik { font-size: .88rem; font-weight: 800; margin-bottom: 6px; }
.hb-haber-ic { display: flex; gap: 10px; align-items: flex-start; }
.hb-haber-thumb { width: 72px; height: 72px; object-fit: cover; border-radius: 8px; flex-shrink: 0; }
.hb-haber-ic .hb-ozet { font-size: .78rem; margin: 0; }

/* 8. SAYDAM — Glassmorphism */
.hb-kart-saydam {
  background: rgba(255,255,255,.18);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  border: 1px solid rgba(255,255,255,.35);
  box-shadow: 0 8px 32px rgba(0,0,0,.12);
}
.hb-dark .hb-kart-saydam {
  background: rgba(255,255,255,.07);
  border-color: rgba(255,255,255,.12);
}
.hb-kart-saydam .hb-baslik a { color: var(--hb-text); }

/* 9. NEON */
.hb-kart-neon {
  border: 2px solid var(--hb-accent);
  box-shadow: 0 0 0 0 var(--hb-accent);
  background: var(--hb-bg);
  transition: box-shadow .3s, transform .3s;
}
.hb-wrap:not(.hb-nohover) .hb-kart-neon:hover {
  box-shadow: 0 0 16px 3px var(--hb-accent), inset 0 0 8px rgba(59,190,203,.12);
  transform: translateY(-4px);
}
.hb-dark .hb-kart-neon { background: var(--hb-bg2); }
.hb-kart-neon .hb-badge { background: transparent; color: var(--hb-accent); border: 1.5px solid var(--hb-accent); }

/* 10. POLAROID */
.hb-kart-polaroid {
  background: #fff;
  padding: 10px 10px 20px;
  box-shadow: 0 4px 16px rgba(0,0,0,.12), 0 1px 3px rgba(0,0,0,.08);
  border-radius: 4px;
  border: none;
  transform: rotate(-1deg);
  transition: transform .3s, box-shadow .3s;
}
.hb-kart-polaroid:nth-child(even) { transform: rotate(1.2deg); }
.hb-wrap:not(.hb-nohover) .hb-kart-polaroid:hover { transform: rotate(0deg) translateY(-5px) scale(1.02); box-shadow: 0 12px 32px rgba(0,0,0,.18); }
.hb-kart-polaroid .hb-resim-wrap { aspect-ratio: 1/1; border-radius: 2px; }
.hb-kart-polaroid .hb-icerik { padding: 10px 4px 0; }
.hb-kart-polaroid .hb-baslik { font-size: .82rem; font-weight: 700; text-align: center; }
.hb-kart-polaroid .hb-meta { justify-content: center; font-size: .7rem; }
.hb-dark .hb-kart-polaroid { background: var(--hb-bg2); }

/* 11. ATLAS */
.hb-kart-atlas { overflow: hidden; }
.hb-kart-atlas .hb-resim-wrap { position: relative; aspect-ratio: 3/4; min-height: 260px; }
.hb-kart-atlas .hb-resim { position: absolute; inset: 0; width: 100%; height: 100%; }
.hb-sp-atlas-overlay,
.hb-kart-atlas .hb-overlay-content {
  position: absolute; inset: 0;
  background: linear-gradient(to top, rgba(0,0,0,.88) 45%, rgba(0,0,0,.05) 100%);
  display: flex; flex-direction: column; justify-content: flex-end; padding: 18px;
}
.hb-kart-atlas .hb-baslik { font-size: 1.1rem; font-weight: 900; color: #fff; }
.hb-kart-atlas .hb-baslik a { color: #fff; }
.hb-kart-atlas .hb-meta { color: rgba(255,255,255,.7); }
.hb-kart-atlas .hb-badge { margin-bottom: 8px; }

/* 12. RIBBON */
.hb-kart-ribbon { overflow: hidden; }
.hb-ribbon {
  position: absolute; top: 14px; right: -22px;
  background: var(--hb-accent); color: #fff;
  font-size: .65rem; font-weight: 800; text-transform: uppercase; letter-spacing: .05em;
  padding: 5px 30px; transform: rotate(35deg);
  box-shadow: 0 2px 8px rgba(0,0,0,.2);
  z-index: 2; pointer-events: none;
}

/* ---- Liste Düzeninde Özel ---- */
.hb-duzen-liste .hb-kart-yatay .hb-yatay-ic,
.hb-duzen-liste .hb-kart { max-width: 100%; }
.hb-duzen-liste .hb-kart-yatay .hb-resim-wrap { width: 200px; aspect-ratio: auto; height: auto; min-height: 130px; }

/* ---- Erişilebilirlik ---- */
.hb-kart a:focus-visible, .hb-daha-fazla:focus-visible, .hb-c-prev:focus-visible, .hb-c-next:focus-visible {
  outline: 3px solid var(--hb-accent); outline-offset: 3px; border-radius: 4px;
}

/* ---- Boş mesaj ---- */
.hb-bos { text-align: center; padding: 32px; color: var(--hb-muted); font-style: italic; }
