/* ks-press.css ─ v1.1 */

/* ══════════════════════════
   АРХИВ
   ══════════════════════════ */

.ksp-archive {
  font-family: inherit;
}

/* ── Фильтр ─────────────── */
.ksp-filter {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 36px;
}

.ksp-filter__tag {
  display: inline-block;
  padding: 6px 16px;
  border-radius: 100px;
  border: 1.5px solid #e0e0e0;
  background: #fff;
  color: #555;
  font-size: 13px;
  font-weight: 500;
  text-decoration: none;
  transition: all .18s;
  white-space: nowrap;
}

.ksp-filter__tag:hover {
  border-color: #111;
  color: #111;
  text-decoration: none;
}

.ksp-filter__tag.is-active {
  border-color: #111;
  background: #111;
  color: #fff;
}

/* ── Сетка ──────────────── */
.ksp-grid {
  column-count: 3;
  column-gap: 24px;
}

@media (max-width: 900px) {
  .ksp-grid { column-count: 2; column-gap: 18px; }
  .ksp-card { margin-bottom: 18px; }
}

@media (max-width: 540px) {
  .ksp-grid { column-count: 1; column-gap: 14px; }
  .ksp-card { margin-bottom: 14px; }
}

/* ── Карточка ───────────── */
.ksp-card {
  display: flex;
  flex-direction: column;
  background: #fff;
  border-radius: 12px;
  overflow: hidden;
  text-decoration: none;
  color: inherit;
  box-shadow: 0 1px 4px rgba(0,0,0,.08);
  border: 1px solid #e6e6e6;
  transition: box-shadow .22s, transform .22s, border-color .22s;
  break-inside: avoid;
  -webkit-column-break-inside: avoid;
  margin-bottom: 24px;
}

.ksp-card:hover {
  box-shadow: 0 8px 28px rgba(0,0,0,.13);
  border-color: #d5d5d5;
  transform: translateY(-4px);
  text-decoration: none;
  color: inherit;
}

/* картинка */
.ksp-card__thumb {
  position: relative;
  overflow: hidden;
  background: #f2f2f2;
  flex-shrink: 0;
}

.ksp-card__img {
  width: 100%;
  height: auto;
  display: block;
  transition: transform .4s ease;
}

.ksp-card:hover .ksp-card__img {
  transform: scale(1.05);
}

.ksp-card__noimg {
  width: 100%;
  aspect-ratio: 3 / 4;
  background: linear-gradient(135deg, #ebebeb 0%, #d8d8d8 100%);
}

/* бейдж рубрики */
.ksp-card__badge {
  position: absolute;
  top: 12px;
  left: 12px;
  padding: 3px 10px;
  border-radius: 4px;
  background: rgba(17,17,17,.72);
  color: #fff;
  font-size: 11px;
  font-weight: 600;
  letter-spacing: .04em;
  text-transform: uppercase;
  backdrop-filter: blur(6px);
  -webkit-backdrop-filter: blur(6px);
}

/* тело */
.ksp-card__body {
  padding: 18px 20px 22px;
  display: flex;
  flex-direction: column;
  flex: 1;
}

.ksp-card__date {
  font-size: 12px;
  color: #aaa;
  margin-bottom: 7px;
  display: block;
}

.ksp-card__title {
  font-size: 15px;
  font-weight: 700;
  line-height: 1.45;
  margin: 0 0 10px;
  color: #111;
}

.ksp-card__excerpt {
  font-size: 13px;
  line-height: 1.65;
  color: #777;
  margin: 0 0 14px;
  flex: 1;
}

.ksp-card__more {
  font-size: 13px;
  font-weight: 600;
  color: #111;
  border-bottom: 1.5px solid currentColor;
  align-self: flex-start;
  transition: opacity .15s;
}

.ksp-card:hover .ksp-card__more {
  opacity: .6;
}

/* ── Пагинация ──────────── */
.ksp-pager {
  display: flex;
  gap: 6px;
  justify-content: center;
  margin-top: 48px;
}

.ksp-pager__btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 38px;
  height: 38px;
  padding: 0 6px;
  border-radius: 6px;
  border: 1.5px solid #e0e0e0;
  background: #fff;
  color: #555;
  font-size: 14px;
  font-weight: 500;
  text-decoration: none;
  transition: all .15s;
}

.ksp-pager__btn:hover {
  border-color: #111;
  color: #111;
  text-decoration: none;
}

.ksp-pager__btn.is-active {
  background: #111;
  border-color: #111;
  color: #fff;
}

/* ── Пусто ──────────────── */
.ksp-empty {
  text-align: center;
  color: #aaa;
  padding: 56px 0;
  font-size: 15px;
}


/* ══════════════════════════
   ДЕТАЛЬНАЯ СТРАНИЦА
   ══════════════════════════ */

.ksp-single {
  max-width: 760px;
  margin: 0 auto;
  font-family: inherit;
  color: #1a1a1a;
}

/* шапка */
.ksp-single__head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 10px;
  margin-bottom: 20px;
}

.ksp-single__back {
  font-size: 13px;
  font-weight: 600;
  color: #aaa;
  text-decoration: none;
  transition: color .15s;
}

.ksp-single__back:hover {
  color: #111;
  text-decoration: none;
}

.ksp-single__meta {
  display: flex;
  align-items: center;
  gap: 10px;
}

.ksp-single__cat {
  display: inline-block;
  padding: 3px 11px;
  border-radius: 4px;
  background: #111;
  color: #fff;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: .05em;
  text-transform: uppercase;
}

.ksp-single__date {
  font-size: 13px;
  color: #aaa;
}

/* заголовок */
.ksp-single__title {
  font-size: clamp(22px, 4vw, 32px);
  font-weight: 800;
  line-height: 1.25;
  color: #111;
  margin: 0 0 28px;
}

/* обложка */
.ksp-single__cover {
  border-radius: 10px;
  overflow: hidden;
  margin: 0 0 36px;
  background: #f2f2f2;
}

.ksp-single__cover-img {
  width: 100%;
  height: auto;
  display: block;
  max-height: 460px;
  object-fit: cover;
}

/* контент */
.ksp-single__content {
  font-size: 16px;
  line-height: 1.8;
  color: #2a2a2a;
}

.ksp-single__content p         { margin: 0 0 1.3em; }
.ksp-single__content h2        { font-size: 21px; font-weight: 700; margin: 1.8em 0 .6em; color: #111; }
.ksp-single__content h3        { font-size: 18px; font-weight: 700; margin: 1.6em 0 .5em; color: #111; }
.ksp-single__content ul,
.ksp-single__content ol        { padding-left: 1.5em; margin: 0 0 1.3em; }
.ksp-single__content li        { margin-bottom: .4em; }
.ksp-single__content img       { max-width: 100%; height: auto; border-radius: 8px; display: block; margin: 1.5em auto; }
.ksp-single__content a         { color: inherit; text-decoration: underline; }
.ksp-single__content a:hover   { opacity: .7; }

.ksp-single__content blockquote {
  margin: 1.8em 0;
  padding: 16px 22px;
  border-left: 3px solid #111;
  background: #f7f7f7;
  border-radius: 0 8px 8px 0;
  color: #555;
  font-style: italic;
}

/* нижний блок */
.ksp-single__foot {
  margin-top: 48px;
  padding-top: 24px;
  border-top: 1px solid #eee;
}

.ksp-single__back-btn {
  display: inline-flex;
  align-items: center;
  padding: 10px 20px;
  border-radius: 6px;
  border: 1.5px solid #ddd;
  background: #fff;
  color: #444;
  font-size: 14px;
  font-weight: 600;
  text-decoration: none;
  transition: border-color .15s, color .15s;
}

.ksp-single__back-btn:hover {
  border-color: #111;
  color: #111;
  text-decoration: none;
}
