/* ============ 1. TİPOGRAFİ ============ */
h1, h2, h3, h4, h5, h6 { color: #162D56; }
body { color: #3A3A3A; }

/* ============ 2. HEADER ============ */
.main-header__advanced-search { font-size: .85rem; }
@media (min-width: 1024px) {
  .main-header__top-bar { align-items: center; }
}
/* Anasayfada üstteki aramayı gizle */
.site-page-anasayfa .main-header #search-form,
.site-page-anasayfa .main-header a[href*="search"] { display: none; }
/* Anasayfada Önceki/Sonraki gizle */
.site-page-anasayfa .site-page-pagination { display: none; }

/* ============ 3. HERO (anasayfa arama) ============ */
.hero-intro { text-align: center; margin: 3.5rem auto 0; }
.hero-intro h2 { font-size: 2.6rem; margin-bottom: .3rem; }
.hero-intro p { color: #3C5580; }
.block-searchForm .block-search { max-width: 640px; margin: 0 auto; }
.block-searchForm #search-form { display: flex; margin: 0; }
.block-searchForm #search-form input[type="text"] { flex: 1; margin: 0; padding: .9rem 1.4rem;
  font-size: 1.05rem; border: 2px solid #C05A2E; border-radius: 999px 0 0 999px; border-right: none; }
.block-searchForm #search-form button { margin: 0; padding: .9rem 1.8rem; font-size: 1.05rem;
  cursor: pointer; background: #C05A2E; color: #fff; border: 2px solid #C05A2E; border-radius: 0 999px 999px 0; }
.block-searchForm #search-form button:hover { background: #9C4823; border-color: #9C4823; }
.hero-advanced { text-align: center; margin: 0 0 1rem; }
.hero-advanced a { font-weight: 600; }

/* ============ 4. KOLEKSİYON KARTLARI ============ */
.collections-band { max-width: 1100px; margin: 6rem auto 4rem; padding-top: 3rem; border-top: 1px solid #E5E3DE; }
.collections-band h2 { text-align: center; margin-bottom: 2rem; }
.coll-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(300px, 1fr)); gap: 20px; }
.coll-card { display: block; background: var(--c); border-radius: 12px; padding: 26px 24px;
  color: #fff; text-decoration: none; min-height: 120px; transition: transform .2s, box-shadow .2s; }
.coll-card:visited { color: #fff; }
.coll-card:hover { transform: translateY(-3px); box-shadow: 0 8px 20px rgba(22,45,86,.3); color: #fff; }
.coll-card strong { display: block; font-family: "Noto Serif", serif; font-size: 1.35rem; margin-bottom: .4rem; }
.coll-card span { opacity: .85; font-size: .9rem; }

/* ============ 5. ARŞİV GRID (öğe listesi) ============ */
.resource-grid .resource__thumbnail img { max-height: none; object-fit: initial; }

/* ============ 6. KATALOG KART GÖRÜNÜMÜ ============ */
.faceted-browse-page #section-content table thead { display: none; }
.faceted-browse-page #section-content table,
.faceted-browse-page #section-content tbody { display: block; }
.faceted-browse-page #section-content tbody tr {
  display: grid; grid-template-columns: 96px minmax(0, 1fr); grid-template-rows: auto auto 1fr;
  column-gap: 20px; row-gap: 4px; padding: 16px; margin-bottom: 15px;
  background: #fff; box-shadow: 0 1px 6px rgba(51,51,51,.2); }
.faceted-browse-page #section-content tbody td { display: block; padding: 0; border: none; }
.faceted-browse-page #section-content tbody td:nth-child(1),
.faceted-browse-page #section-content tbody td:nth-child(1) .resource-link { display: contents; }
.faceted-browse-page #section-content tbody td:nth-child(1) img {
  grid-column: 1; grid-row: 1 / span 3;
  width: 96px !important; max-width: 96px !important;
  height: auto !important; max-height: none !important;
  align-self: start; background: none; object-fit: initial; margin: 0 !important; }
.faceted-browse-page #section-content tbody td:nth-child(1) .resource-name {
  grid-column: 2; grid-row: 1; font-size: 1.15rem; font-weight: 600; }
.faceted-browse-page #section-content tbody td:nth-child(2) {
  grid-column: 2; grid-row: 2; color: #666; font-size: .9rem; }
.faceted-browse-page #section-content tbody td:nth-child(3) {
  grid-column: 2; grid-row: 3; font-size: .95rem; }
.faceted-browse-page #section-content tbody td:nth-child(1) .resource-name,
.faceted-browse-page #section-content tbody td:nth-child(2),
.faceted-browse-page #section-content tbody td:nth-child(3) {
  word-break: break-word; overflow-wrap: break-word; }
.faceted-browse-page .tablesaw-bar { display: none !important; }

/* ============ 7. KATALOG YÜKLEME DURUMU ============ */
.faceted-browse-page #container { min-height: 70vh; }
#section-content.loading { font-size: 0 !important; min-height: 420px; position: relative; }
#section-content.loading::before { content: "" !important; font-size: 0 !important;
  position: absolute; top: 90px !important; left: 50% !important;
  width: 42px; height: 42px; margin-left: -21px; border-radius: 50%;
  border: 4px solid #E5E3DE; border-top-color: #C05A2E;
  animation: akspin .8s linear infinite !important; }
#section-content.loading::after { content: "Sonuçlar yükleniyor…"; font-size: .95rem;
  color: #666; position: absolute; top: 150px; left: 50%; transform: translateX(-50%); }
#section-content:empty { position: relative; }
#section-content:empty::before { content: ""; position: absolute; top: 90px; left: 50%;
  width: 42px; height: 42px; margin-left: -21px; border-radius: 50%;
  border: 4px solid #E5E3DE; border-top-color: #C05A2E;
  animation: akspin .8s linear infinite; }
@keyframes akspin { to { transform: rotate(360deg); } }

/* ============ 8. KATALOG SAYFALAMA (üstte sadece sayaç) ============ */
.faceted-browse-page #section-content .browse-controls:has(.sorting) .pagination > *:not(.row-count) { display: none; }
.faceted-browse-page #section-content .browse-controls:has(.sorting) .pagination { border: none; margin: 0; padding: 0; }

/* ============ 9. MOBİL FİLTRE/PAYLAŞ (klon buton) ============ */
.ak-filter-btn { display: none; }

/* ============ 10. FOOTER ============ */
.main-footer .no-menu .main-footer__col1,
.main-footer__col1 { max-width: 600px; margin: 0 auto !important; text-align: center; }
.main-footer__col1 img { display: block; margin: 0 auto; max-width: 180px; }
.footer-logos { display: flex; align-items: center; justify-content: center;
  flex-wrap: wrap; gap: 20px; margin: 1rem 0 0; }
.footer-logos img { height: 80px; width: auto; background: #fff; padding: 6px 10px;
  border-radius: 6px; margin: 0 !important; display: inline-block; }
.footer-logos a:hover img { opacity: .8; }
.footer-logos--funders { justify-content: center; gap: 0; max-width: 620px; margin: 1.2rem auto 0; }
.footer-logos--funders img { background: none !important; padding: 0 !important; height: 96px; border-radius: 0; }

/* ============ 11. MOBİL ============ */
@media (max-width: 640px) {
  /* Katalog kartları */
  .faceted-browse-page #section-content tbody td { max-width: none !important; }
  .faceted-browse-page #section-content tbody tr { grid-template-columns: 80px minmax(0, 1fr); column-gap: 14px; }
  .faceted-browse-page #section-content tbody td:nth-child(1) img { width: 80px !important; max-width: 80px !important; }

  /* Filtreler + Paylaş yan yana, sayaç üstte, sıralama altta */
  .ak-filter-btn { display: inline-block; margin: 0; flex: 1 1 45%; }
  #section-sidebar-modal-toggle { display: none !important; }
  .faceted-browse-page .browse-controls { display: flex; flex-wrap: wrap; gap: 10px; }
  .faceted-browse-page .browse-controls .pagination { width: 100%; order: -1; justify-content: center; }
  .faceted-browse-page .browse-controls .permalink { flex: 1 1 45%; text-align: center; padding: 10px 12px; }
  .faceted-browse-page .browse-controls .sorting { flex: 1 1 100%; }
  .faceted-browse-page .permalink .default { font-size: 0; }
  .faceted-browse-page .permalink .default::before { content: "PAYLAŞ"; font-size: .95rem; }
  .faceted-browse-page .permalink .default::after { font-size: 1rem; }

  /* Footer: ortak logoları tek satır */
  .footer-logos { flex-wrap: nowrap; gap: 10px; }
  .footer-logos a { flex: 1 1 0; min-width: 0; }
  .footer-logos img { width: 100%; height: auto; padding: 6px; box-sizing: border-box; }

  /* Footer: funder logoları kendi oranında */
  .footer-logos--funders { flex-wrap: wrap; gap: 0; justify-content: center; }
  .footer-logos--funders img { width: auto !important; height: 96px !important; }
}

.lang-switch { font-weight: 700; font-size: .85rem; letter-spacing: .05em;
  margin-right: 16px; color: #162D56; text-decoration: none;
  border: 1.5px solid #162D56; border-radius: 4px; padding: 3px 8px; }
.lang-switch:hover { background: #162D56; color: #fff; }