/* ================================================
   POSTS.CSS — Акции / Новости / Блог
   ================================================ */

.posts-page h1 { margin-bottom: 2rem; }
.posts-empty { color: var(--color-muted); font-size: 0.95rem; }

.posts-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1.5rem;
}

.post-card {
  display: flex;
  flex-direction: column;
  border-radius: 12px;
  overflow: hidden;
  background: #fff;
  box-shadow: 0 2px 16px rgba(66,44,42,0.07);
  text-decoration: none;
  transition: transform 0.25s, box-shadow 0.25s;
}

.post-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 8px 32px rgba(66,44,42,0.13);
}

.post-card-img {
  position: relative;
  overflow: hidden;
  height: 200px;
}

.post-card-img img {
  width: 100%; height: 100%;
  object-fit: cover;
  transition: transform 0.4s;
}

.post-card:hover .post-card-img img { transform: scale(1.05); }

/* Плейсхолдер когда нет изображения */
.post-card-placeholder {
  width: 100%; height: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 2.5rem;
  line-height: 1;
}

.post-card-placeholder.type-promo {
  background: linear-gradient(135deg, #f7e8e5 0%, #f0cfc8 100%);
}

.post-card-placeholder.type-news {
  background: linear-gradient(135deg, #f7f0e8 0%, #eedfc5 100%);
}

.post-card-placeholder.type-blog {
  background: linear-gradient(135deg, #eef0f7 0%, #cdd3ee 100%);
}

.post-badge {
  position: absolute;
  top: 0.75rem; left: 0.75rem;
  background: var(--color-rose-btn);
  color: #fff;
  font-size: 0.75rem;
  font-weight: 700;
  padding: 0.3rem 0.7rem;
  border-radius: 6px;
  letter-spacing: 0.05em;
}

.post-badge.large { font-size: 1.2rem; padding: 0.5rem 1rem; }

.post-card-body {
  padding: 1.25rem;
  display: flex;
  flex-direction: column;
  gap: 0.4rem;
  flex: 1;
}

.post-date {
  font-size: 0.72rem;
  color: var(--color-rose);
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.post-card-body h2 {
  font-family: var(--font-display);
  font-size: 1.05rem;
  font-weight: 700;
  color: var(--color-brown);
  line-height: 1.3;
  margin: 0;
}

.post-card-body p {
  font-size: 0.85rem;
  color: var(--color-muted, #7a6360);
  line-height: 1.5;
  margin: 0;
}

.post-expires {
  font-size: 0.75rem;
  color: var(--color-rose-deep);
  font-weight: 600;
  margin-top: auto;
}

/* Detail */
.post-detail-placeholder {
  width: 100%; height: 300px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 4rem;
  line-height: 1;
  border-radius: 12px;
}

.post-detail-placeholder.type-promo { background: linear-gradient(135deg, #f7e8e5 0%, #f0cfc8 100%); }
.post-detail-placeholder.type-news  { background: linear-gradient(135deg, #f7f0e8 0%, #eedfc5 100%); }
.post-detail-placeholder.type-blog  { background: linear-gradient(135deg, #eef0f7 0%, #cdd3ee 100%); }

.post-breadcrumb {
  display: flex;
  align-items: center;
  gap: 0.4rem;
  font-size: 0.8rem;
  color: var(--color-muted, #7a6360);
  margin-bottom: 1.5rem;
}

.post-breadcrumb a { color: var(--color-rose-mid); text-decoration: none; }
.post-breadcrumb a:hover { text-decoration: underline; }

.post-detail-img {
  position: relative;
  border-radius: 12px;
  overflow: hidden;
  margin-bottom: 1.5rem;
}

.post-detail-img img {
  width: 100%; max-height: 420px;
  object-fit: cover; display: block;
}

/* Автор */
.post-author {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  margin-top: 0.5rem;
  padding-top: 0.6rem;
  border-top: 1px solid var(--color-border);
}

.post-author-img {
  width: 32px;
  height: 32px;
  border-radius: 50%;
  object-fit: cover;
  flex-shrink: 0;
  border: 2px solid var(--color-rose-light, #f7e8e5);
}

.post-author-info {
  display: flex;
  flex-direction: column;
  gap: 0;
}

.post-author-name {
  font-size: 0.78rem;
  font-weight: 700;
  color: var(--color-brown);
  line-height: 1.2;
}

.post-author-role {
  font-size: 0.68rem;
  color: var(--color-muted, #7a6360);
  line-height: 1.2;
}

/* Автор на странице детали */
.post-detail-author {
  display: flex;
  align-items: center;
  gap: 1rem;
  margin: 1.25rem 0 2rem;
  padding: 1rem 1.25rem;
  background: #fff;
  border-radius: 10px;
  border: 1px solid var(--color-border);
}

.post-detail-author-img {
  width: 52px;
  height: 52px;
  border-radius: 50%;
  object-fit: cover;
  flex-shrink: 0;
  border: 3px solid var(--color-rose-light, #f7e8e5);
}

.post-detail-author-text {
  display: flex;
  flex-direction: column;
  gap: 0.15rem;
}

.post-detail-author-name {
  font-size: 0.9rem;
  font-weight: 700;
  color: var(--color-brown);
}

.post-detail-author-role {
  font-size: 0.78rem;
  color: var(--color-muted, #7a6360);
}

@media (max-width: 900px) {
  .posts-grid { grid-template-columns: repeat(2, 1fr); }
}

@media (max-width: 600px) {
  .posts-grid { grid-template-columns: 1fr; }
}
