/* ============================================================
   CATEGORY.PHP — kateqoriya daxilində mövzu siyahısı
   ============================================================ */

.category-hero { background: var(--white); border: 1px solid var(--border); border-radius: var(--radius); padding: 24px; margin-bottom: 20px; box-shadow: var(--shadow-sm); display: flex; justify-content: space-between; align-items: center; gap: 20px; flex-wrap: wrap; }
.category-hero-info { display: flex; gap: 16px; align-items: center; }
.category-hero-icon { width: 56px; height: 56px; background: rgba(255,193,7,0.15); color: var(--yellow-hover); border-radius: 14px; display: flex; align-items: center; justify-content: center; font-size: 30px; flex-shrink: 0; }
.category-hero h1 { font-size: 22px; font-weight: 900; margin-bottom: 4px; }
.category-hero p { font-size: 13px; color: var(--text-muted); }

.toolbar { display: flex; justify-content: space-between; align-items: center; margin-bottom: 16px; flex-wrap: wrap; gap: 12px; }
.toolbar-left { font-size: 13px; color: var(--text-muted); font-weight: 600; }

.topic-list { display: flex; flex-direction: column; gap: 16px; margin-bottom: 32px; }
.topic-row { background: var(--white); border: 1px solid var(--border-light); border-radius: 20px; padding: 20px; display: flex; gap: 20px; align-items: center; box-shadow: var(--shadow-sm); transition: 0.3s ease; position: relative; overflow: hidden; }
.topic-row::before { content: ''; position: absolute; left: 0; top: 0; width: 4px; height: 100%; background: var(--yellow); transform: scaleY(0); transition: 0.3s; }
.topic-row:hover { transform: translateY(-3px); box-shadow: var(--shadow-md); border-color: rgba(255,212,59,0.3); }
.topic-row:hover::before { transform: scaleY(1); }
.topic-row.pinned { background: rgba(255,212,59,0.05); border-color: rgba(255,212,59,0.2); }
.topic-row.pinned::before { transform: scaleY(1); background: var(--yellow-hover); }

.t-main { flex: 1; min-width: 0; display: flex; gap: 16px; align-items: flex-start; }
.t-icon-wrap { width: 44px; height: 44px; border-radius: 12px; background: var(--light-bg); display: flex; align-items: center; justify-content: center; font-size: 20px; color: var(--text-muted); flex-shrink: 0; }
.topic-row.pinned .t-icon-wrap { background: var(--yellow); color: var(--black); }

.t-title-text { min-width: 0; flex: 1; }
.t-title-text h4 { font-size: 16px; font-weight: 800; margin-bottom: 4px; line-height: 1.4; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; word-break: break-word; }
.t-title-text h4 a { color: var(--black); }
.t-title-text h4 a:hover { color: var(--yellow-hover); }
.t-meta { font-size: 13px; color: var(--text-muted); font-weight: 500; display: flex; gap: 12px; flex-wrap: wrap; align-items: center; }
.t-meta span { display: flex; align-items: center; gap: 4px; }
.t-meta i { font-size: 16px; }

.t-side { display: flex; gap: 32px; align-items: center; flex-shrink: 0; }
.t-stats-group { display: flex; gap: 16px; }
.t-stat { text-align: center; background: var(--light-bg); padding: 8px 16px; border-radius: 12px; min-width: 70px; }
.t-stat strong { display: block; font-size: 15px; font-weight: 800; color: var(--black); }
.t-stat span { font-size: 10px; color: var(--text-muted); text-transform: uppercase; font-weight: 700; letter-spacing: 0.5px; }

.t-latest { width: 200px; display: flex; align-items: center; gap: 12px; border-left: 2px dashed var(--border-light); padding-left: 20px; }
.t-latest img { width: 36px; height: 36px; border-radius: 10px; box-shadow: 0 4px 10px rgba(0,0,0,0.05); }
.t-latest-info a { font-size: 13px; font-weight: 700; color: var(--black); display: block; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; transition: 0.2s; }
.t-latest-info a:hover { color: var(--yellow-hover); }
.t-latest-info p { font-size: 11px; color: var(--text-muted); font-weight: 600; margin-top: 2px; }
.t-latest-empty { font-size: 12px; color: var(--text-muted); font-style: italic; }

.pagination { display: flex; justify-content: center; gap: 8px; margin-top: 32px; }
.page-btn { min-width: 40px; height: 40px; padding: 0 12px; display: flex; align-items: center; justify-content: center; border: 1px solid var(--border); background: var(--white); border-radius: 12px; font-size: 14px; font-weight: 700; color: var(--black); cursor: pointer; transition: 0.2s; }
.page-btn.active { background: var(--black); color: var(--yellow); border-color: var(--black); transform: scale(1.05); box-shadow: 0 4px 10px rgba(0,0,0,0.1); }
.page-btn:hover:not(.active) { background: var(--light-bg); border-color: var(--text-muted); }

@media (max-width: 992px) {
    .topic-row { flex-direction: column; align-items: flex-start; gap: 16px; padding: 16px; }
    .t-side { width: 100%; justify-content: space-between; border-top: 2px dashed var(--border-light); padding-top: 16px; gap: 16px; }
    .t-latest { width: auto; border-left: none; padding-left: 0; }
}

@media (max-width: 576px) {
    .category-hero { flex-direction: column; text-align: center; padding: 20px; }
    .category-hero .btn-primary { width: 100%; justify-content: center; display: flex; }
    .t-side { flex-direction: column; align-items: stretch; }
    .t-stats-group { justify-content: space-between; }
    .t-stat { flex: 1; }
    .t-latest { padding-top: 16px; border-top: 1px dashed var(--border-light); }
}
