

.blog-hero {
  padding: 110px 0 36px;
  text-align: center;
  background: linear-gradient(160deg, var(--navy-deeper) 0%, var(--navy) 100%);
}
.blog-hero h1 {
  color: var(--white);
  font-size: clamp(1.5rem, 2.8vw, 2.2rem);
  margin-bottom: .4rem;
}
.blog-hero p {
  color: rgba(255,255,255,.55);
  font-size: .95rem;
  white-space: nowrap;
}

.blog-controls {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 2.5rem;
  flex-wrap: wrap;
  gap: 1rem;
}

.blog-categories {
  display: flex;
  gap: .5rem;
  flex-wrap: wrap;
}
.blog-cat-btn {
  border-radius: var(--r-full);
  padding: .45rem 1.15rem;
  font-size: .82rem;
  font-weight: 700;
  font-family: 'Lato', sans-serif;
  border: 1.5px solid var(--border);
  background: var(--white);
  color: var(--text-body);
  cursor: pointer;
  transition: all var(--transition);
}
.blog-cat-btn:hover {
  border-color: var(--navy);
  color: var(--navy);
}
.blog-cat-btn.active {
  background: var(--navy);
  color: var(--white);
  border-color: var(--navy);
}

.blog-search {
  position: relative;
}
.blog-search input {
  border: 1.5px solid var(--border);
  border-radius: var(--r-full);
  padding: .55rem 1rem .55rem 2.5rem;
  font-family: 'Lato', sans-serif;
  font-size: .9rem;
  width: 260px;
  outline: none;
  background: var(--white);
  color: var(--text-dark);
  transition: border-color var(--transition);
}
.blog-search input:focus {
  border-color: var(--navy);
}
.blog-search input::placeholder {
  color: var(--text-muted);
}
.blog-search img {
  position: absolute;
  left: .9rem;
  top: 50%;
  transform: translateY(-50%);
  width: 1rem;
  height: 1rem;
  opacity: .5;
  pointer-events: none;
}

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

.blog-card {
  background: var(--white);
  border-radius: var(--r-lg);
  box-shadow: var(--shadow-sm);
  overflow: hidden;
  transition: transform var(--transition), box-shadow var(--transition);
  display: flex;
  flex-direction: column;
  text-decoration: none;
  color: inherit;
}
.blog-card:hover {
  transform: translateY(-6px);
  box-shadow: var(--shadow-lg);
}
.blog-card__image {
  aspect-ratio: 16 / 9;
  overflow: hidden;
  background: var(--gray);
}
.blog-card__image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform .4s ease;
}
.blog-card:hover .blog-card__image img {
  transform: scale(1.05);
}
.blog-card__body {
  padding: 1.25rem 1.5rem 1.5rem;
  flex: 1;
  display: flex;
  flex-direction: column;
}
.blog-card__category {
  display: inline-block;
  font-size: .68rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 1.5px;
  color: var(--teal);
  margin-bottom: .5rem;
}
.blog-card__title {
  font-size: 1.05rem;
  font-weight: 700;
  color: var(--text-dark);
  line-height: 1.35;
  margin-bottom: .5rem;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}
.blog-card__excerpt {
  font-size: .875rem;
  color: var(--text-muted);
  line-height: 1.6;
  flex: 1;
  display: -webkit-box;
  -webkit-line-clamp: 3;
  -webkit-box-orient: vertical;
  overflow: hidden;
}
.blog-card__meta {
  font-size: .78rem;
  color: var(--text-muted);
  margin-top: .75rem;
  display: flex;
  align-items: center;
  gap: .35rem;
}

.blog-card__image--placeholder {
  display: flex;
  align-items: center;
  justify-content: center;
  background: linear-gradient(135deg, var(--navy) 0%, var(--teal) 100%);
}
.blog-card__image--placeholder svg {
  width: 48px;
  height: 48px;
  opacity: .3;
}

.skeleton {
  background: linear-gradient(90deg, var(--gray) 25%, #e8edf1 50%, var(--gray) 75%);
  background-size: 200% 100%;
  animation: shimmer 1.5s infinite;
  border-radius: var(--r-sm);
}
@keyframes shimmer {
  0%   { background-position: 200% 0; }
  100% { background-position: -200% 0; }
}
.skeleton-card {
  border-radius: var(--r-lg);
  overflow: hidden;
  background: var(--white);
  box-shadow: var(--shadow-sm);
}
.skeleton-card__image {
  aspect-ratio: 16 / 9;
}
.skeleton-card__body {
  padding: 1.25rem 1.5rem 1.5rem;
}
.skeleton-card__line {
  height: 14px;
  margin-bottom: .75rem;
  border-radius: 4px;
}
.skeleton-card__line--short { width: 40%; }
.skeleton-card__line--medium { width: 80%; }
.skeleton-card__line--long { width: 100%; }
.skeleton-card__line--xs { width: 30%; height: 10px; margin-top: .5rem; }

.blog-pagination {
  display: flex;
  justify-content: center;
  align-items: center;
  gap: .5rem;
  margin-top: 3rem;
}
.blog-page-btn {
  min-width: 40px;
  height: 40px;
  border-radius: var(--r);
  border: 1.5px solid var(--border);
  background: var(--white);
  font-family: 'Lato', sans-serif;
  font-size: .85rem;
  font-weight: 600;
  color: var(--text-body);
  cursor: pointer;
  transition: all var(--transition);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0 .75rem;
}
.blog-page-btn:hover {
  border-color: var(--navy);
  color: var(--navy);
}
.blog-page-btn.active {
  background: var(--navy);
  color: var(--white);
  border-color: var(--navy);
}
.blog-page-btn:disabled {
  opacity: .4;
  cursor: not-allowed;
}

.blog-empty {
  text-align: center;
  padding: 4rem 1rem;
  grid-column: 1 / -1;
}
.blog-empty i {
  font-size: 2.5rem;
  color: var(--border);
  margin-bottom: 1rem;
}
.blog-empty h3 {
  color: var(--text-dark);
  margin-bottom: .5rem;
}
.blog-empty p {
  color: var(--text-muted);
  font-size: .95rem;
  margin-bottom: 1.5rem;
}
.blog-empty .btn {
  display: inline-flex;
}

.post-hero {
  margin-top: 68px;
  padding: 1.5rem 0;
  background: linear-gradient(160deg, var(--navy-deeper) 0%, var(--navy) 100%);
  display: flex;
  justify-content: center;
  align-items: center;
}
.post-hero img {
  max-width: min(900px, calc(100% - 4rem));
  max-height: 280px;
  height: auto;
  width: auto;
  display: block;
  border-radius: var(--r-lg);
  box-shadow: var(--shadow-xl);
}

.post-page {
  padding-top: 64px;
}

.post-layout {
  display: grid;
  grid-template-columns: 1fr 320px;
  gap: 3.5rem;
  align-items: start;
}
.post-main {
  min-width: 0;
}

.post-meta {
  display: flex;
  align-items: center;
  gap: .75rem;
  flex-wrap: wrap;
  margin-bottom: 1.25rem;
  font-size: .82rem;
  color: var(--text-muted);
}
.post-meta .blog-card__category {
  margin-bottom: 0;
}

.post-title {
  font-size: clamp(1.6rem, 3vw, 2.2rem);
  font-weight: 900;
  color: var(--text-dark);
  line-height: 1.2;
  letter-spacing: -.3px;
  margin-bottom: 2rem;
}

.post-body {
  font-size: 1.05rem;
  line-height: 1.85;
  color: var(--text-body);
}
.post-body h2 {
  font-size: 1.5rem;
  margin: 2.5rem 0 1rem;
}
.post-body h3 {
  font-size: 1.2rem;
  margin: 2rem 0 .75rem;
}
.post-body h4 {
  margin: 1.5rem 0 .5rem;
}
.post-body p {
  margin-bottom: 1.25rem;
}
.post-body img {
  border-radius: var(--r);
  margin: 1.5rem 0;
  height: auto;
}
.post-body figure {
  margin: 1.5rem 0;
}
.post-body figcaption {
  font-size: .82rem;
  color: var(--text-muted);
  text-align: center;
  margin-top: .5rem;
}
.post-body blockquote {
  border-left: 3px solid var(--green);
  padding-left: 1.25rem;
  margin: 1.5rem 0;
  font-style: italic;
  color: var(--text-muted);
}
.post-body ul,
.post-body ol {
  margin: 1rem 0 1.25rem 1.5rem;
}
.post-body li {
  margin-bottom: .5rem;
}
.post-body a {
  color: var(--teal);
  text-decoration: underline;
  text-underline-offset: 2px;
}
.post-body a:hover {
  color: var(--teal-dark);
}
.post-body pre {
  background: var(--gray);
  padding: 1.25rem;
  border-radius: var(--r);
  overflow-x: auto;
  font-size: .88rem;
  margin: 1.5rem 0;
}
.post-body table {
  width: 100%;
  border-collapse: collapse;
  margin: 1.5rem 0;
}
.post-body th,
.post-body td {
  padding: .65rem 1rem;
  border: 1px solid var(--border);
  text-align: left;
  font-size: .92rem;
}
.post-body th {
  background: var(--gray);
  font-weight: 700;
}

.post-body iframe {
  width: 100%;
  aspect-ratio: 16 / 9;
  border: none;
  border-radius: var(--r);
  margin: 1.5rem 0;
}
.post-body .wp-block-embed {
  margin: 1.5rem 0;
}

.post-share {
  display: flex;
  align-items: center;
  gap: .75rem;
  margin-top: 3rem;
  padding-top: 1.5rem;
  border-top: 1px solid var(--border);
}
.post-share__label {
  font-size: .85rem;
  font-weight: 700;
  color: var(--text-muted);
  margin-right: .25rem;
}
.post-share a,
.post-share button {
  width: 40px;
  height: 40px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--gray);
  border: none;
  cursor: pointer;
  color: var(--text-body);
  font-size: .95rem;
  transition: background var(--transition), color var(--transition);
}
.post-share a:hover,
.post-share button:hover {
  background: var(--navy);
  color: var(--white);
}

.post-sidebar__sticky {
  position: sticky;
  top: 100px;
}
.post-sidebar__title {
  font-size: .72rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 2px;
  color: var(--text-muted);
  margin-bottom: 1.25rem;
  padding-bottom: .75rem;
  border-bottom: 1px solid var(--border);
}

.post-sidebar__posts {
  display: flex;
  flex-direction: column;
  gap: 1.25rem;
}
.post-sidebar__posts .blog-card {
  flex-direction: row;
  box-shadow: none;
  border: 1px solid var(--border);
  border-radius: var(--r);
}
.post-sidebar__posts .blog-card:hover {
  transform: none;
  box-shadow: var(--shadow-sm);
  border-color: var(--navy);
}
.post-sidebar__posts .blog-card__image {
  width: 100px;
  min-height: 80px;
  aspect-ratio: auto;
  flex-shrink: 0;
  border-radius: var(--r) 0 0 var(--r);
}
.post-sidebar__posts .blog-card__body {
  padding: .75rem 1rem;
}
.post-sidebar__posts .blog-card__title {
  font-size: .88rem;
  -webkit-line-clamp: 2;
}
.post-sidebar__posts .blog-card__excerpt {
  display: none;
}
.post-sidebar__posts .blog-card__meta {
  font-size: .72rem;
  margin-top: .4rem;
}

.post-back {
  display: inline-flex;
  align-items: center;
  gap: .4rem;
  font-size: .88rem;
  font-weight: 600;
  color: var(--text-muted);
  margin-bottom: 2rem;
  transition: color var(--transition);
}
.post-back:hover {
  color: var(--navy);
}

.post-skeleton__title {
  height: 36px;
  width: 80%;
  margin-bottom: 2rem;
}
.post-skeleton__meta {
  height: 14px;
  width: 35%;
  margin-bottom: 1.5rem;
}
.post-skeleton__line {
  height: 14px;
  width: 100%;
  margin-bottom: 1rem;
}
.post-skeleton__line:nth-child(even) { width: 92%; }
.post-skeleton__line:nth-child(3n) { width: 78%; }


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

@media (max-width: 768px) {
  .blog-grid {
    grid-template-columns: 1fr;
  }
  .blog-controls {
    flex-direction: column;
    align-items: stretch;
  }
  .blog-search input {
    width: 100%;
  }
  .blog-hero {
    padding: 100px 0 32px;
  }
  .blog-hero p {
    white-space: normal;
  }
  .post-hero {
    padding: 1.5rem 0;
  }
  .post-layout {
    grid-template-columns: 1fr;
    gap: 2.5rem;
  }
  .post-sidebar__posts .blog-card {
    flex-direction: row;
  }
}

@media (max-width: 480px) {
  .blog-categories {
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
    flex-wrap: nowrap;
    padding-bottom: .5rem;
  }
  .blog-cat-btn {
    flex-shrink: 0;
  }
  .blog-hero {
    padding: 110px 0 32px;
  }
  .post-hero {
    padding: 1.25rem 0;
  }
  .post-share {
    flex-wrap: wrap;
  }
}
