/* =============================================================
   blog.css — page-specific styles for /blog
   ============================================================= */

:root {
  --navy:       #1a3a5c;
  --navy-dark:  #122840;
  --orange:     #e07b1a;
  --white:      #ffffff;
  --gray-100:   #f3f4f6;
  --gray-200:   #e5e7eb;
  --gray-400:   #9ca3af;
  --gray-500:   #6b7280;
  --gray-600:   #4b5563;
  --gray-700:   #374151;
  --radius:     10px;
  --radius-lg:  16px;
  --shadow:     0 4px 16px rgba(0,0,0,0.10), 0 1px 4px rgba(0,0,0,0.06);
  --transition: 0.18s ease;
  --grid-svg: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='80' height='80'%3E%3Cdefs%3E%3Cpattern id='g' width='80' height='80' patternUnits='userSpaceOnUse'%3E%3Crect width='80' height='80' fill='none'/%3E%3Cpath d='M 80 0 L 0 0 0 80' fill='none' stroke='rgba(255,255,255,0.04)' stroke-width='1'/%3E%3Cpath d='M 20 0 L 20 80 M 40 0 L 40 80 M 60 0 L 60 80 M 0 20 L 80 20 M 0 40 L 80 40 M 0 60 L 80 60' fill='none' stroke='rgba(255,255,255,0.02)' stroke-width='0.5'/%3E%3Ccircle cx='0' cy='0' r='1.5' fill='rgba(255,255,255,0.06)'/%3E%3Ccircle cx='80' cy='0' r='1.5' fill='rgba(255,255,255,0.06)'/%3E%3Ccircle cx='0' cy='80' r='1.5' fill='rgba(255,255,255,0.06)'/%3E%3Ccircle cx='80' cy='80' r='1.5' fill='rgba(255,255,255,0.06)'/%3E%3C/pattern%3E%3C/defs%3E%3Crect width='80' height='80' fill='url(%23g)'/%3E%3C/svg%3E");
}

/* ── Hero ── */
.blog-hero {
  position: relative;
  background: var(--navy-dark);
  padding: 72px 0 64px;
  text-align: center;
  overflow: hidden;
}
.blog-hero-bg { position: absolute; inset: 0; background-image: var(--grid-svg); pointer-events: none; }
.blog-hero-inner { position: relative; z-index: 1; }
.blog-page-label {
  display: inline-flex;
  align-items: center;
  padding: 5px 14px;
  border-radius: 100px;
  background: rgba(255,255,255,0.10);
  font-size: 11px;
  font-weight: 800;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: rgba(255,255,255,0.75);
  margin-bottom: 18px;
}
.blog-hero-heading {
  font-size: clamp(30px, 4.5vw, 48px);
  font-weight: 800;
  color: var(--white);
  letter-spacing: -0.4px;
  line-height: 1.15;
  margin-bottom: 14px;
}
.blog-hero-sub {
  font-size: 17px;
  color: rgba(255,255,255,0.65);
  line-height: 1.65;
  max-width: 520px;
  margin: 0 auto;
}

/* ── Post list ── */
.blog-main {
  background: #f8fafc;
  min-height: 400px;
  padding: 64px 0 80px;
}
.blog-grid {
  display: flex;
  flex-direction: column;
  gap: 20px;
}

/* ── Post card (vertical — image on top, text below) ── */
.blog-card {
  background: var(--white);
  border: 1px solid var(--gray-200);
  border-radius: var(--radius-lg);
  overflow: hidden;
  display: flex;
  flex-direction: column;
  text-decoration: none;
  color: inherit;
  transition: box-shadow var(--transition), transform var(--transition), border-color var(--transition);
}
.blog-card:hover { box-shadow: var(--shadow); transform: translateY(-2px); border-color: rgba(26,58,92,0.15); }

/* Top image */
.blog-card-cover {
  width: 100%;
  height: 280px;
  object-fit: cover;
  display: block;
  background: var(--gray-100);
  flex-shrink: 0;
}
.blog-card-cover-placeholder {
  width: 100%;
  height: 280px;
  flex-shrink: 0;
  background: linear-gradient(135deg, #edf1f7 0%, #dce4f0 100%);
  display: flex;
  align-items: center;
  justify-content: center;
}
.blog-card-cover-placeholder svg {
  width: 52px;
  height: 52px;
  color: #b0bfd0;
}

/* Bottom text panel */
.blog-card-body {
  padding: 28px 30px 26px;
  flex: 1;
  display: flex;
  flex-direction: column;
  gap: 10px;
}
.blog-card-category {
  font-size: 11px;
  font-weight: 800;
  letter-spacing: 0.07em;
  text-transform: uppercase;
  color: var(--orange);
}
.blog-card-title {
  font-size: 21px;
  font-weight: 700;
  color: var(--navy);
  line-height: 1.3;
  margin: 0;
}
.blog-card-excerpt {
  font-size: 14.5px;
  color: var(--gray-500);
  line-height: 1.65;
  flex: 1;
  /* clamp to 4 lines */
  display: -webkit-box;
  -webkit-line-clamp: 4;
  -webkit-box-orient: vertical;
  overflow: hidden;
}
.blog-card-meta {
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: 12.5px;
  color: var(--gray-400);
}
.blog-card-meta svg { width: 13px; height: 13px; flex-shrink: 0; }
.blog-card-readmore {
  font-size: 13.5px;
  font-weight: 700;
  color: var(--navy);
  margin-top: 4px;
}

/* ── States ── */
.blog-loading {
  display: flex;
  flex-direction: column;
  gap: 20px;
}
.blog-skeleton {
  background: var(--white);
  border: 1px solid var(--gray-200);
  border-radius: var(--radius-lg);
  overflow: hidden;
  display: flex;
  flex-direction: column;
}
.blog-skeleton-cover {
  width: 100%;
  height: 280px;
  flex-shrink: 0;
  background: linear-gradient(90deg, #edf1f7 25%, #dce4f0 50%, #edf1f7 75%);
  background-size: 200% 100%;
  animation: shimmer 1.5s infinite;
}
.blog-skeleton-body { padding: 28px 30px; flex: 1; display: flex; flex-direction: column; gap: 12px; }
.blog-skeleton-line {
  height: 13px;
  border-radius: 6px;
  background: linear-gradient(90deg, #edf1f7 25%, #dce4f0 50%, #edf1f7 75%);
  background-size: 200% 100%;
  animation: shimmer 1.5s infinite;
}
.blog-skeleton-line--short { width: 40%; }
.blog-skeleton-line--title { height: 22px; width: 80%; }
.blog-skeleton-line--full { width: 100%; }
@keyframes shimmer {
  0% { background-position: 200% 0; }
  100% { background-position: -200% 0; }
}

.blog-empty {
  text-align: center;
  padding: 60px 0;
  color: var(--gray-500);
}
.blog-empty h2 { font-size: 20px; font-weight: 700; color: var(--navy); margin-bottom: 8px; }
.blog-empty p { font-size: 15px; line-height: 1.6; }

.blog-error {
  background: #fff3e0;
  border: 1px solid #ffd5a0;
  border-radius: var(--radius);
  padding: 20px 24px;
  color: #9a5700;
  font-size: 14px;
}

/* ── CTA band ── */
.blog-cta {
  background: var(--white);
  border-top: 1px solid var(--gray-200);
  padding: 56px 0;
  text-align: center;
}
.blog-cta h2 { font-size: clamp(20px, 2.8vw, 28px); font-weight: 800; color: var(--navy); margin-bottom: 8px; }
.blog-cta p { font-size: 15px; color: var(--gray-500); margin-bottom: 24px; }

/* ── Responsive ── */
@media (max-width: 640px) {
  .blog-card-cover,
  .blog-card-cover-placeholder,
  .blog-skeleton-cover { height: 220px; }
  .blog-card-body { padding: 22px 20px; }
  .blog-skeleton-body { padding: 22px 20px; }
  .blog-card-title { font-size: 18px; }
}
