/**
 * Blog: hero + search, grid of cards (4 per row), single post
 */

/* ----- List page layout ----- */
.blog-main {
  padding-bottom: 3rem;
}

/* ----- Hero section ----- */
.blog-hero {
  text-align: center;
  padding: 2.5rem 1.5rem 2rem;
  background: linear-gradient(180deg, #f0f9f7 0%, #fff 100%);
  border-radius: 0 0 24px 24px;
  margin-bottom: 2rem;
}

.blog-hero-title {
  font-size: 1.75rem;
  font-weight: 700;
  margin: 0 0 0.5rem;
  color: var(--color-text, #0f172a);
  letter-spacing: -0.02em;
  line-height: 1.25;
}

.blog-hero-subtitle {
  font-size: 1rem;
  color: var(--color-text-muted, #64748b);
  margin: 0 0 1.5rem;
  max-width: 420px;
  margin-left: auto;
  margin-right: auto;
}

.blog-hero-search-form {
  display: flex;
  align-items: stretch;
  max-width: 420px;
  margin: 0 auto;
  border: 1px solid var(--color-border, #e2e8f0);
  border-radius: 12px;
  overflow: hidden;
  background: #fff;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.06);
  transition: box-shadow 0.25s ease, border-color 0.25s ease;
}

.blog-hero-search-form:focus-within {
  border-color: var(--color-teal, #0ca48c);
  box-shadow: 0 0 0 3px rgba(12, 164, 140, 0.15);
}

.blog-hero-search-input {
  flex: 1;
  padding: 12px 16px;
  border: none;
  font-size: 0.9375rem;
  color: var(--color-text, #0f172a);
  background: transparent;
  min-width: 0;
}

.blog-hero-search-input::placeholder {
  color: var(--color-text-muted, #94a3b8);
}

.blog-hero-search-input:focus {
  outline: none;
}

.blog-hero-search-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 48px;
  border: none;
  background: var(--color-teal, #0ca48c);
  color: #fff;
  cursor: pointer;
  transition: background 0.2s ease, opacity 0.2s ease;
}

.blog-hero-search-btn:hover {
  background: var(--color-teal-dark, #0d9488);
}

.blog-hero-search-btn:focus {
  outline: none;
}

.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

/* ----- Section title ----- */
.blog-posts-section {
  max-width: var(--max-content-width, 1200px);
  margin: 0 auto;
  padding: 0 1.25rem;
}

.blog-section-title {
  font-size: 1.35rem;
  font-weight: 700;
  margin: 0 0 1.25rem;
  color: var(--color-text, #0f172a);
  letter-spacing: -0.02em;
}

/* ----- Blog grid: 4 per row on large ----- */
.blog-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 1.25rem;
}

@media (min-width: 560px) {
  .blog-grid {
    grid-template-columns: repeat(2, 1fr);
    gap: 1.5rem;
  }
}

@media (min-width: 900px) {
  .blog-grid {
    grid-template-columns: repeat(3, 1fr);
    gap: 1.5rem;
  }
}

@media (min-width: 1100px) {
  .blog-grid {
    grid-template-columns: repeat(4, 1fr);
  }
}

/* ----- Blog card (clean, professional) ----- */
.blog-card {
  background: #fff;
  border: 1px solid rgba(0, 0, 0, 0.06);
  border-radius: 14px;
  overflow: hidden;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.06);
  display: flex;
  flex-direction: column;
  transition: box-shadow 0.25s ease, transform 0.25s ease, border-color 0.25s ease;
}

.blog-card:hover {
  box-shadow: 0 14px 32px rgba(0, 0, 0, 0.1);
  transform: translateY(-3px);
  border-color: rgba(12, 164, 140, 0.25);
}

.blog-card-image-link {
  display: block;
  box-sizing: border-box;
  aspect-ratio: 4 / 3;
  min-height: 220px;
  padding: 1.25rem;
  background: #f8fafc;
  overflow: hidden;
}

.blog-card-image-link img {
  width: 100%;
  height: 100%;
  object-fit: contain;
  object-position: center;
  display: block;
  transition: transform 0.35s ease;
}

.blog-card:hover .blog-card-image-link img {
  transform: scale(1.04);
}

.blog-card-body {
  padding: 1.25rem 1.25rem 1.375rem;
  flex: 1;
  display: flex;
  flex-direction: column;
  gap: 0;
}

.blog-card-title {
  font-size: 1.0625rem;
  font-weight: 700;
  margin: 0 0 0.625rem;
  line-height: 1.4;
  letter-spacing: -0.01em;
}

.blog-card-title a {
  color: #0f172a;
  text-decoration: none;
  transition: color 0.2s ease;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.blog-card-title a:hover {
  color: var(--color-teal, #0ca48c);
}

.blog-card-desc {
  font-size: 0.875rem;
  color: #64748b;
  line-height: 1.55;
  margin: 0 0 1rem;
  display: -webkit-box;
  -webkit-line-clamp: 3;
  line-clamp: 3;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.blog-card-body:has(.blog-card-desc) .blog-card-read-more {
  margin-top: auto;
}

.blog-card-read-more {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  font-size: 0.875rem;
  font-weight: 600;
  color: var(--color-teal, #0ca48c);
  text-decoration: none;
  margin-bottom: 0.75rem;
  padding: 0.25rem 0;
  transition: color 0.2s ease, gap 0.2s ease;
}

.blog-card-read-more:hover {
  color: #0d9488;
  gap: 0.5rem;
}

.blog-card-read-more i {
  font-size: 0.7em;
  transition: transform 0.2s ease;
}

.blog-card-read-more:hover i {
  transform: translateX(2px);
}

.blog-card-author {
  font-size: 0.8125rem;
  color: #94a3b8;
  margin: 0;
  font-weight: 500;
}

/* ----- Empty state ----- */
.blog-empty {
  grid-column: 1 / -1;
  text-align: center;
  padding: 3rem 1.5rem;
  color: var(--color-text-muted, #64748b);
  font-size: 1rem;
}

/* ============================================================
   SINGLE POST — full-width, editorial layout
   ============================================================ */

.blog-single {
  width: 100%;
  max-width: 100%;
  padding: 0;
  margin: 0;
}

/* Hero image — bleeds full page width */
.blog-single-image-wrap {
  width: 100%;
  max-width: 100%;
  margin: 0;
  background: #000;
  overflow: hidden;
  height: 480px;
}

.blog-single-image-wrap img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center;
  display: block;
  opacity: 0.92;
}

/* Header — centered readable column */
.blog-single-header {
  max-width: 900px;
  width: 100%;
  margin: 0 auto;
  padding: 2.25rem 2rem 1.5rem;
  box-sizing: border-box;
}

.blog-single-title {
  font-size: clamp(1.75rem, 3.5vw, 2.75rem);
  font-weight: 800;
  margin: 0 0 0.6rem;
  color: var(--color-text, #0f172a);
  line-height: 1.2;
  letter-spacing: -0.03em;
}

.blog-single-meta {
  font-size: 0.9375rem;
  color: var(--color-text-muted, #64748b);
  margin: 0;
  font-weight: 500;
}

/* Content — full-width readable column */
.blog-single-content {
  max-width: 900px;
  width: 100%;
  margin: 0 auto;
  padding: 2rem 2rem 3rem;
  box-sizing: border-box;
  font-size: 1.0625rem;
  line-height: 1.8;
  color: var(--color-text, #334155);
}

.blog-single-content h2,
.blog-single-content h3,
.blog-single-content h4 {
  color: #0f172a;
  font-weight: 700;
  margin: 2rem 0 0.75rem;
  line-height: 1.3;
  letter-spacing: -0.02em;
}

.blog-single-content h2 { font-size: 1.5rem; }
.blog-single-content h3 { font-size: 1.25rem; }

.blog-single-content p {
  margin: 0 0 1.25rem;
}

.blog-single-content ul,
.blog-single-content ol {
  padding-left: 1.5rem;
  margin: 0 0 1.25rem;
}

.blog-single-content li {
  margin-bottom: 0.4rem;
}

.blog-single-content img {
  max-width: 100%;
  height: auto;
  border-radius: 10px;
  margin: 1.5rem 0;
}

.blog-single-content strong {
  font-weight: 700;
  color: #0f172a;
}

.blog-single-content hr {
  border: none;
  border-top: 1px solid #e2e8f0;
  margin: 1.75rem 0;
}

/* Responsive */
@media (max-width: 640px) {
  .blog-single-header {
    padding: 1.5rem 1.25rem 1.25rem;
  }

  .blog-single-content {
    padding: 1.5rem 1.25rem 2.5rem;
  }

  .blog-single-image-wrap {
    height: 240px;
  }
}