/* ==========================================================================
   YL Platform — Layout
   Mobile-first grid sistemi. Sidebar mobilde gizlenir.
   ========================================================================== */

*, *::before, *::after { box-sizing: border-box; }

.yl-container {
    max-width: var(--yl-container-max);
    margin: 0 auto;
    padding: 0 var(--yl-gutter-mobile);
}
@media (min-width: 768px) {
    .yl-container { padding: 0 var(--yl-gutter-tablet); }
}
@media (min-width: 1200px) {
    .yl-container { padding: 0 var(--yl-gutter-desktop); }
}

.yl-site { display: flex; flex-direction: column; min-height: 100vh; }
.yl-site__content { flex: 1; }

/* -------------------------------------------------------------------------
   Ana içerik + sidebar düzeni — mobilde tek kolon, lg'de 8+4
   ------------------------------------------------------------------------- */

.yl-layout { display: flex; flex-direction: column; gap: var(--yl-sp-8); padding: var(--yl-sp-5) 0; }

@media (min-width: 1024px) {
    .yl-layout--with-sidebar {
        flex-direction: row;
        align-items: flex-start;
        gap: var(--yl-sp-8);
    }
    .yl-layout__main { flex: 2; min-width: 0; }
    .yl-layout__sidebar { flex: 1; max-width: var(--yl-sidebar-width); }
}

/* -------------------------------------------------------------------------
   Grid sistemleri
   ------------------------------------------------------------------------- */

.yl-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: var(--yl-sp-5);
    margin: var(--yl-sp-4) 0;
}
@media (min-width: 768px) {
    .yl-grid--3col, .yl-grid--4col { grid-template-columns: repeat(2, 1fr); }
}
@media (min-width: 1024px) {
    .yl-grid--3col { grid-template-columns: repeat(3, 1fr); }
    .yl-grid--4col { grid-template-columns: repeat(4, 1fr); }
}

/* -------------------------------------------------------------------------
   Hero bölgesi — mobilde tek kolon, lg'de 8+2+2
   ------------------------------------------------------------------------- */

.yl-hero { display: flex; flex-direction: column; gap: var(--yl-sp-4); margin: var(--yl-sp-5) 0; }
.yl-hero__secondary { display: flex; flex-direction: column; gap: var(--yl-sp-4); }

@media (min-width: 1024px) {
    .yl-hero { flex-direction: row; }
    .yl-hero__primary { flex: 2; }
    .yl-hero__secondary { flex: 1; }
}

/* -------------------------------------------------------------------------
   Bölüm başlığı + "Tümünü Gör"
   ------------------------------------------------------------------------- */

.yl-section { margin: var(--yl-sp-8) 0; }
.yl-section__header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: var(--yl-sp-4);
}
.yl-section__more {
    font-size: var(--yl-font-sm);
    font-weight: var(--yl-weight-medium);
    white-space: nowrap;
}

/* -------------------------------------------------------------------------
   Arşiv başlığı
   ------------------------------------------------------------------------- */

.yl-archive-header {
    border-radius: var(--yl-radius-lg);
    padding: var(--yl-sp-6) var(--yl-sp-5);
    margin: var(--yl-sp-5) 0 var(--yl-sp-4);
    color: var(--yl-color-white);
}
.yl-archive-header__title { color: var(--yl-color-white); margin-bottom: var(--yl-sp-1); }
.yl-archive-header__count { color: rgba(255,255,255,0.85); margin: 0; font-size: var(--yl-font-sm); }

/* -------------------------------------------------------------------------
   Sayfalama
   ------------------------------------------------------------------------- */

.yl-pagination {
    display: flex;
    justify-content: center;
    gap: var(--yl-sp-2);
    margin: var(--yl-sp-8) 0;
    flex-wrap: wrap;
}
.yl-pagination .page-numbers {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 36px;
    height: 36px;
    padding: 0 var(--yl-sp-2);
    border: 1px solid var(--yl-border-default);
    border-radius: var(--yl-radius-sm);
    font-size: var(--yl-font-sm);
    color: var(--yl-text-secondary);
}
.yl-pagination .page-numbers.current {
    background: var(--yl-color-primary);
    border-color: var(--yl-color-primary);
    color: var(--yl-color-white);
}

/* -------------------------------------------------------------------------
   404 / boş sonuç
   ------------------------------------------------------------------------- */

.yl-404 { text-align: center; padding: var(--yl-sp-16) var(--yl-sp-4); }
.yl-404__code { font-size: 4rem; color: var(--yl-color-primary); margin-bottom: 0; }
.yl-404__message { font-size: var(--yl-font-lg); margin-bottom: var(--yl-sp-6); }
.yl-404__search { max-width: 480px; margin: 0 auto var(--yl-sp-6); }
.yl-404__home-link { display: inline-block; margin-bottom: var(--yl-sp-10); }
.yl-404__recent-title { text-align: left; }

.yl-no-results { padding: var(--yl-sp-8) 0; color: var(--yl-text-secondary); }

/* -------------------------------------------------------------------------
   E-Gazete düzeni
   ------------------------------------------------------------------------- */

.yl-egazete-layout { display: flex; flex-direction: column; gap: var(--yl-sp-6); }
@media (min-width: 768px) {
    .yl-egazete-layout { flex-direction: row; }
    .yl-egazete-layout__cover { flex: 0 0 280px; }
    .yl-egazete-layout__body { flex: 1; }
}
.yl-egazete-layout__cover-img { border-radius: var(--yl-radius-md); width: 100%; }
