/* Firma-detay ile görsel uyum için temel görünümler */
:root{
  --kb-bg:#f6f7f9; --kb-card:#ffffff; --kb-border:#e5e7eb; --kb-text:#111827; --kb-muted:#5b6470;
  --kb-primary:#16a085; --kb-primary-2:#22c55e; --kb-radius:16px;
}
body{ background:var(--kb-bg); color:var(--kb-text); }
.rounded-4{ border-radius:var(--kb-radius); }
.shadow-soft{ box-shadow:0 12px 34px rgba(0,0,0,.10); }
.card-kb{ background:var(--kb-card); border:1px solid var(--kb-border); border-radius:var(--kb-radius); padding:16px; box-shadow:0 10px 30px rgba(0,0,0,.06); }
.section{ margin-top:.75rem; }
.section-title{ display:flex; align-items:center; gap:.5rem; font-weight:800; margin:0; }
.section-title .bi{
  color: var(--kb-primary);
  font-size: 1.05rem;
}
.meta-line{ color:var(--kb-muted); }
.kb-sep{ margin: 0 .4rem; opacity: .6; }
.meta-line .bi{ margin-right: .25rem; }

/* İçerik tipografisi */
.kb-article-content{
  font-size: 1.125rem;
  line-height: 1.85;
  color: #111827;
}
.kb-article-content p{ margin: 0 0 1rem 0; }
.kb-article-content h1,
.kb-article-content h2,
.kb-article-content h3{
  font-weight: 700;
  line-height: 1.25;
}
.kb-article-content h2{
  font-size: 1.4rem;
  margin-top: 1.75rem;
  margin-bottom: .6rem;
  padding-bottom: .3rem;
  border-bottom: 2px solid #e5e7eb;
}
.kb-article-content h3{
  font-size: 1.25rem;
  margin-top: 1.25rem;
  margin-bottom: .4rem;
}
@media (min-width: 992px){
  /* İlk paragraf için modern drop-cap */
  .kb-article-content p:first-of-type::first-letter{
    float: left;
    font-size: 3.2rem;
    line-height: 1;
    font-weight: 800;
    margin-right: .28rem;
    color: var(--kb-primary);
  }
}
.kb-article-content hr{
  border: none;
  border-top: 1px dashed #d8dbe0;
  margin: 1.25rem 0;
}

/* Kısa açıklama (özet) – iş ilanı / kampanya detay kartıyla aynı tipografi */
#hbSummary{
  font-size: 1rem;
  line-height: 1.6;
  margin-top: .35rem;
  color: #4b5563;
}
/* Manşet (başlık) – iş ilanı / kampanya detay kartıyla aynı hiyerarşi */
#hbTitle{
  font-size: 1.25rem; /* Bootstrap .h5 ile hizalı */
  line-height: 1.4;
  font-weight: 700; /* .fw-bold ile uyumlu */
  letter-spacing: -0.01em;
  text-wrap: balance;
  margin-bottom: .5rem;
  color: #111827;
}
#hbTitle::first-letter{
  font-size: inherit;
  line-height: 1;
  color: inherit;
  margin-right: .02em;
}

/* Başlık aralıkları */
.kb-article-content p{ margin: 0 0 1rem 0; }
.kb-article-content h1,
.kb-article-content h2,
.kb-article-content h3{
  margin-top: 1.15rem;
  margin-bottom: .7rem;
  font-weight: 700;
  line-height: 1.25;
}
.kb-article-content h2{ font-size: 1.35rem; }
.kb-article-content h3{ font-size: 1.2rem; }
.kb-article-content ul,
.kb-article-content ol{ margin: 0 0 1rem 1.25rem; }
.kb-article-content li{ margin-bottom: .35rem; }
.kb-article-content blockquote{
  border-left: 4px solid var(--kb-primary);
  margin: 1rem 0;
  padding: .5rem 1rem;
  color: #374151;
  background: #ecfdf54d;
  border-radius: 8px;
}
.kb-article-content img{
  display: block;
  max-width: 100%;
  height: auto;
  border-radius: 12px;
  box-shadow: 0 8px 24px rgba(0,0,0,.08);
  margin: .75rem auto 1rem;
}

/* Haber içi galeri yerleşimi ([[FOTOx]] için) */
.kb-article-content .kb-haber-inline-photo{
  margin: 1.25rem 0;
  text-align: center;
}
.kb-article-content .kb-haber-inline-photo img{
  margin: 0 auto;
}

@media (min-width: 992px){
  /* Masaüstünde haber içi fotoğrafları biraz daralt, daha zarif görünüm */
  .kb-article-content .kb-haber-inline-photo img{
    max-width: 720px;
  }
}

/* Tablo responsive sarmalayıcı */
.kb-table-responsive{
  width: 100%;
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
  margin: .5rem 0 1rem;
}
.kb-article-content table{
  width: 100%;
  border-collapse: collapse;
  margin: 1rem 0;
  font-size: .95rem;
}
.kb-article-content th,
.kb-article-content td{
  border: 1px solid #e5e7eb;
  padding: .5rem .6rem;
  word-break: break-word;
  vertical-align: top;
}
.kb-article-content thead th{
  background: #f9fafb;
  font-weight: 600;
}

/* Son Haberler hover ve truncation */
#hbLatestNews a{ transition: transform .12s ease, background-color .12s ease; border-radius:10px; padding:4px; }
#hbLatestNews a:hover{ transform: translateY(-2px); background:#f8fafc; }
#hbLatestNews .flex-grow-1{ min-width: 0; }
#hbLatestNews .fw-semibold{ display:block; overflow:hidden; text-overflow:ellipsis; white-space:nowrap; }
#hbLatestNews .text-secondary.small{ overflow:hidden; text-overflow:ellipsis; white-space:nowrap; }

/* Haber detayında sağ sütunu yapışkan hale getir (köşe yazısı detay ile aynı mantık) */
.kb-sticky{ }
@media (min-width: 992px){
  .kb-sticky{
    position: sticky;
    top: 84px;
  }
}

/* Masonry galeri */
.kb-masonry{
  column-count: 3;
  column-gap: 12px;
}
.kb-masonry a{
  display: inline-block;
  width: 100%;
  margin: 0 0 12px;
  border-radius: 12px;
  overflow: hidden;
  box-shadow: 0 8px 24px rgba(0,0,0,.06);
}
.kb-masonry img{ width: 100%; height: auto; display: block; }
@media (max-width: 991.98px){
  .kb-masonry{ column-count: 2; }
}
@media (max-width: 575.98px){
  .kb-masonry{ column-count: 2; }
}

/* ==== Hero bilgi kartı (iş ilanı / kampanya) – iş ilanları listesi kartıyla uyumlu ==== */
.kb-feature-hero{
  position: relative;
  border-radius: 22px;
  border: 0;
  padding: 16px 18px 14px;
  background: radial-gradient(circle at 0% 0%, #16a085 0%, #0f766e 40%, #0b1120 100%);
  color:#ecfeff;
  box-shadow:0 22px 60px rgba(15,23,42,.55);
  overflow:hidden;
}
.kb-feature-hero::before{
  content:'';
  position:absolute;
  inset:-30%;
  background: radial-gradient(circle at 0% 0%, rgba(255,255,255,.22) 0, transparent 55%),
              radial-gradient(circle at 110% 10%, rgba(56,189,248,.26) 0, transparent 55%);
  opacity:.9;
  mix-blend-mode: screen;
  pointer-events:none;
}
.kb-feature-hero > *{
  position:relative;
  z-index:1;
}
.kb-feature-hero-header{
  display:flex;
  align-items:center;
  justify-content:space-between;
  gap:10px;
  margin-bottom:8px;
}
.kb-feature-hero-header .kb-pill{
  font-size:.78rem;
  letter-spacing:.12em;
  text-transform:uppercase;
}
.kb-feature-hero-header .kb-pill .dot{
  width:8px;
  height:8px;
  border-radius:999px;
  background:#22c55e;
  box-shadow:0 0 0 2px rgba(34,197,94,.45);
}

.kb-feature-hero-tags{
  position:absolute;
  right:18px;
  bottom:12px;
  display:flex;
  flex-wrap:wrap;
  gap:10px;
  font-size:.82rem;
  color:rgba(226,232,240,.9);
  align-items:center;
}
.kb-feature-hero-tags .kb-pill{
  background:rgba(15,23,42,.64);
  border-radius:999px;
}
.kb-feature-hero-title{
  font-size:clamp(1.5rem, 1.1rem + 1vw, 1.9rem);
  line-height:1.25;
  font-weight:600;
  letter-spacing:-0.02em;
  margin:0;
}
.kb-feature-hero-firm{
  margin-top:.4rem;
  font-size:.95rem;
  font-weight:600;
  letter-spacing:.04em;
  text-transform:uppercase;
  color:#c7d2fe;
}
.kb-feature-hero-summary{
  font-size:1rem;
  line-height:1.6;
  color:rgba(241,245,249,.96);
  margin-top:.35rem;
}
.kb-feature-hero .meta-line{
  color:rgba(226,232,240,.9);
}
.kb-feature-hero .meta-line i{
  margin-right:.25rem;
}

@media (max-width: 575.98px){
  .kb-feature-hero{
    padding:16px 14px 14px;
    border-radius:20px;
  }
  .kb-feature-hero-title{
    font-size:1.5rem;
  }
}

/* Read progress bar */
#kbReadProgress{
  position: fixed;
  left: 0; right: 0; top: 0;
  height: 3px; z-index: 1060;
  pointer-events: none;
}
#kbReadProgress .bar{
  width: 0%; height: 100%;
  background: var(--kb-primary, #16a085);
  box-shadow: 0 1px 0 rgba(0,0,0,.05);
  transition: width .1s linear;
}

/* Gallery preview */
.kb-gallery-preview{
  position: relative;
  overflow: hidden;
  border-radius: 12px;
  box-shadow: 0 6px 20px rgba(0,0,0,.06);
  border: 1px solid var(--kb-border);
  height: clamp(160px, 24vw, 280px); /* daha kompakt önizleme */
}
.kb-gallery-preview img{
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center;
  display: block;
}
.kb-gallery-preview::after{
  content:'';
  position:absolute; inset:0;
  background: linear-gradient(to top, rgba(0,0,0,.12), transparent 60%);
  pointer-events:none;
}
.kb-gallery-overlay{
  position: absolute;
  right: 12px;
  bottom: 12px;
  z-index: 2;
}

/* Mosaic/Slider grid */
.kb-gal-grid{
  display: grid;
  grid-template-columns: 2fr 1fr;
  grid-template-rows: 1fr 1fr;
  gap: 8px;
  height: 100%;
}
.kb-gal-thumb{ display:block; width:100%; height:100%; overflow:hidden; border-radius:12px; position:relative; }
.kb-gal-thumb:not([data-span="big"]){ border-radius:10px; }
.kb-gal-thumb img{ width:100%; height:100%; object-fit:cover; object-position:center; display:block; }
.kb-gal-thumb[data-span="big"]{ grid-column: 1 / 2; grid-row: 1 / 3; }
.kb-gal-plus{
  position:absolute; right:12px; top:12px;
  background: rgba(17,24,39,.85); color:#fff; font-weight:700;
  padding:.25rem .6rem; border-radius:999px; z-index:3; pointer-events:none;
}

/* İki görsellik düzen */
.kb-gal-grid.kb-gal-grid-2{
  grid-template-columns: 1fr 1fr;
  grid-template-rows: 1fr;
}
.kb-gal-thumb.contain img{ object-fit: contain; }
.kb-gal-thumb.contain::before{
  content:'';
  position:absolute; inset:0;
  background-image: var(--bg);
  background-size: cover;
  background-position: center;
  filter: blur(12px) brightness(.92);
  transform: scale(1.12);
}
.kb-gal-thumb.contain img{ position:relative; z-index:1; }

/* Mobile: horizontal slider */
@media (max-width: 575.98px){
  .kb-gal-grid{ display:flex; overflow-x:auto; gap:8px; height: 210px; scroll-snap-type:x mandatory; }
  .kb-gal-thumb{ min-width: 66%; height:100%; scroll-snap-align:center; }
  .kb-gal-thumb[data-span="big"]{ min-width: 80%; }
}

/* Below-the-fold optimizasyonu */
.cv-auto{ content-visibility: auto; contain-intrinsic-size: 600px; }

/* Single photo preview */
.kb-gal-single{
  position:relative;
  height: 100%;
  display:flex; align-items:center; justify-content:center;
  border-radius: 12px;
}
.kb-gal-single::before{
  content:'';
  position:absolute; inset:0;
  background-image: var(--bg);
  background-size: cover;
  background-position: center;
  filter: blur(14px) brightness(.92);
  transform: scale(1.2);
}
.kb-gal-single img{
  position:relative; z-index:1;
  max-height: 100%;
  max-width: 100%;
  object-fit: contain;
  border-radius: 10px;
  box-shadow: 0 8px 20px rgba(0,0,0,.12);
}

/* Modal navigation */
.kb-gal-nav{
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  background: rgba(17,24,39,.6);
  color: #fff;
  border: none;
  width: 42px;
  height: 42px;
  border-radius: 50%;
  line-height: 38px;
  font-size: 28px;
  text-align: center;
  cursor: pointer;
  z-index: 5;
}
.kb-gal-prev{ left: 10px; }
.kb-gal-next{ right: 10px; }
.kb-gal-counter{
  position: absolute;
  left: 12px;
  bottom: 10px;
  background: rgba(255,255,255,.85);
  color:#111827;
  font-size:.85rem;
  padding:2px 8px;
  border-radius: 999px;
  z-index: 5;
}

/* Mobil: alt tabbar çakışması */
@media (max-width: 767.98px){
  html{ scroll-padding-bottom: calc(96px + env(safe-area-inset-bottom)); }
  main.container{ padding-bottom: calc(96px + 12px + env(safe-area-inset-bottom)); }
  .kb-article-content{
    font-size: 1.1rem;
    line-height: 1.75;
  }
  #hbSummary{
    font-size: 1rem;
    margin-top: .35rem;
  }
  #hbTitle{ font-size: 1.25rem; }
  #hbLatestNews{ margin-bottom: 0 !important; }
  #secLatest{ margin-bottom: calc(96px + 12px + env(safe-area-inset-bottom)); }
}


