/*
Theme Name: KI Schmiede Stuttgart
Theme URI: https://ki-schmiede-stuttgart.de/blog
Author: Cool Services GmbH
Author URI: https://servicesare.cool
Description: Maßgeschneidertes, responsives Theme für den Blog der KI Schmiede Stuttgart. Mobile-first und pixel-perfect integriert.
Version: 1.0.0
Text Domain: ki-schmiede-theme
*/

/* ==========================================================================
   BLOG LAYOUT & GRID (Mobile-First)
   ========================================================================== */
.blog-section {
  padding: 56px 0;
  background: var(--white);
}

@media (min-width: 768px) {
  .blog-section {
    padding: 80px 0;
  }
}

.blog-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 32px;
  margin-top: 48px;
}

@media (min-width: 768px) {
  .blog-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (min-width: 992px) {
  .blog-grid {
    grid-template-columns: repeat(3, 1fr);
  }
}

/* ==========================================================================
   POST CARD
   ========================================================================== */
.post-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  overflow: hidden;
  display: flex;
  flex-direction: column;
  height: 100%;
  transition: transform 0.2s ease, box-shadow 0.2s ease;
  text-decoration: none;
  color: inherit;
}

.post-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 12px 32px rgba(0, 0, 0, 0.08);
}

.post-card__image-link {
  display: block;
  position: relative;
  aspect-ratio: 16 / 9;
  background: var(--border);
  overflow: hidden;
}

.post-card__image {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.3s ease;
}

.post-card:hover .post-card__image {
  transform: scale(1.04);
}

.post-card__body {
  padding: 24px 20px;
  display: flex;
  flex-direction: column;
  flex-grow: 1;
}

@media (min-width: 576px) {
  .post-card__body {
    padding: 28px 24px;
  }
}

.post-card__meta {
  font-size: 13px;
  color: var(--fg-muted);
  margin-bottom: 12px;
  display: flex;
  gap: 12px;
  align-items: center;
}

.post-card__date {
  font-weight: 500;
}

.post-card__title {
  font-size: 20px;
  font-weight: 800;
  line-height: 1.3;
  margin-bottom: 12px;
  color: var(--fg);
}

.post-card__excerpt {
  font-size: 15px;
  color: var(--fg-muted);
  line-height: 1.6;
  margin-bottom: 20px;
  flex-grow: 1;
}

.post-card__link {
  font-size: 14px;
  font-weight: 700;
  color: var(--brand);
  display: inline-flex;
  align-items: center;
  gap: 6px;
  margin-top: auto;
  transition: color 0.15s ease;
}

.post-card:hover .post-card__link {
  color: var(--brand-dark);
}

/* ==========================================================================
   SINGLE POST DETAIL
   ========================================================================== */
.post-header {
  padding: 56px 0 40px;
  background: var(--surface);
  border-bottom: 1px solid var(--border);
  text-align: center;
}

@media (min-width: 768px) {
  .post-header {
    padding: 80px 0 56px;
  }
}

.post-header__meta {
  font-size: 14px;
  color: var(--fg-muted);
  margin-bottom: 16px;
  display: flex;
  justify-content: center;
  gap: 16px;
}

.post-header__title {
  font-size: clamp(26px, 5vw, 44px);
  font-weight: 800;
  line-height: 1.2;
  color: var(--fg);
  max-width: 800px;
  margin: 0 auto;
}

.post-content-wrap {
  padding: 48px 0;
  background: var(--white);
}

@media (min-width: 768px) {
  .post-content-wrap {
    padding: 72px 0;
  }
}

.post-content {
  max-width: 720px;
  margin: 0 auto;
}

/* Typography in articles */
.post-content p {
  font-size: 16px;
  line-height: 1.75;
  color: var(--fg-muted);
  margin-bottom: 24px;
}

@media (min-width: 576px) {
  .post-content p {
    font-size: 17px;
  }
}

.post-content h2 {
  font-size: clamp(22px, 4vw, 30px);
  font-weight: 800;
  line-height: 1.3;
  color: var(--fg);
  margin: 48px 0 16px;
}

.post-content h3 {
  font-size: clamp(18px, 3vw, 24px);
  font-weight: 700;
  line-height: 1.3;
  color: var(--fg);
  margin: 36px 0 12px;
}

.post-content ul, 
.post-content ol {
  margin-bottom: 24px;
  padding-left: 20px;
  color: var(--fg-muted);
}

.post-content li {
  font-size: 15px;
  line-height: 1.7;
  margin-bottom: 8px;
}

@media (min-width: 576px) {
  .post-content li {
    font-size: 16px;
  }
}

/* Post Thumbnails */
.post-featured-image {
  max-width: 800px;
  margin: 0 auto 40px;
  border-radius: var(--radius-lg);
  overflow: hidden;
  border: 1px solid var(--border);
  aspect-ratio: 16 / 9;
}

.post-featured-image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

/* ==========================================================================
   PAGINATION
   ========================================================================== */
.pagination {
  display: flex;
  justify-content: center;
  gap: 8px;
  margin-top: 56px;
}

.pagination .page-numbers {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 40px;
  height: 40px;
  padding: 0 6px;
  border-radius: var(--radius);
  border: 1px solid var(--border);
  color: var(--fg);
  text-decoration: none;
  font-weight: 600;
  transition: all 0.15s ease;
  font-size: 14px;
}

.pagination .page-numbers:hover,
.pagination .page-numbers.current {
  background: var(--brand);
  border-color: var(--brand);
  color: var(--white);
}
