/* AKM Music — blog listing and article.
   Mobile-first. Loads after heritage.css. Navy, white, Manrope. */

.blog-hero {
  background: var(--color-primary, #1e3a5f);
  color: #fff;
  padding: 2.2rem 0 1.6rem;
}
.blog-hero .hero-title {
  color: #fff;
  font-size: clamp(1.7rem, 1.2rem + 2vw, 2.6rem);
  line-height: 1.15;
  letter-spacing: -0.02em;
  margin: 0 0 0.6rem;
}
.blog-hero .hero-subtitle { color: rgba(255,255,255,0.82); margin: 0 auto; max-width: 38rem; }
.blog-hero .hero-search {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  max-width: 36rem;
  margin: 1.1rem auto 0;
  background: #fff;
  color: var(--color-primary, #1e3a5f);
  border-radius: 999px;
  padding: 0;
}
/* fixes.css also styles .hero-search input (width, shadow, border); it loads
   first, so these need the same specificity to win. */
.blog-hero .hero-search input {
  flex: 1;
  width: 100%;
  max-width: none;
  border: 0;
  background: transparent;
  box-shadow: none;
  border-radius: 999px;
  font: inherit;
  min-width: 0;
  padding: 0.7rem 3rem 0.7rem 2.9rem;
  color: inherit;
}

.blog-toolbar {
  position: sticky;
  top: var(--header-height, 64px);
  z-index: 5;
  background: #fff;
  border-bottom: 1px solid var(--border-color, #e6e8ee);
}
.blog-toolbar .toolbar-inner {
  display: flex;
  gap: 0.75rem;
  align-items: center;
  justify-content: space-between;
  /* block only: .toolbar-inner is also .container, whose side padding must stay */
  padding-top: 0.7rem;
  padding-bottom: 0.7rem;
}
.blog-toolbar .filter-chips {
  display: flex;
  gap: 0.4rem;
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
  scrollbar-width: none;
}
.blog-toolbar .chip {
  flex: 0 0 auto;
  border: 1px solid var(--border-color, #e6e8ee);
  background: #fff;
  color: var(--color-primary, #1e3a5f);
  border-radius: 999px;
  padding: 0.4rem 0.8rem;
  font: inherit;
  font-size: 0.85rem;
  font-weight: 650;
  cursor: pointer;
}
.blog-toolbar .chip.active {
  background: var(--color-primary, #1e3a5f);
  color: #fff;
  border-color: var(--color-primary, #1e3a5f);
}
.blog-toolbar .toolbar-right { display: flex; align-items: center; gap: 0.6rem; flex: 0 0 auto; }
.blog-toolbar select {
  font: inherit;
  font-size: 0.85rem;
  border: 1px solid var(--border-color, #e6e8ee);
  border-radius: 999px;
  padding: 0.35rem 0.7rem;
  background: #fff;
  color: var(--color-primary, #1e3a5f);
}

.blog-posts { padding-bottom: 2rem; }
.blog-posts .posts-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 1rem;
  margin-top: 1.2rem;
}
@media (min-width: 700px) {
  .blog-posts .posts-grid { grid-template-columns: 1fr 1fr; gap: 1.2rem; }
}
@media (min-width: 1040px) {
  .blog-posts .posts-grid { grid-template-columns: 1fr 1fr 1fr; }
  .blog-posts .posts-grid .blog-card:first-child {
    grid-column: 1 / -1;
    display: grid;
    grid-template-columns: 1.5fr 1fr;
  }
  .blog-posts .posts-grid .blog-card:first-child .card-image { height: 100%; aspect-ratio: auto; }
}

.blog-posts .blog-card {
  display: flex;
  flex-direction: column;
  background: #fff;
  border: 1px solid var(--border-color, #e6e8ee);
  border-radius: 16px;
  overflow: hidden;
  min-height: 100%;
  color: inherit;
  text-decoration: none;
}
.blog-posts .blog-card:hover .card-title { text-decoration: underline; }
.blog-posts .blog-card .card-image {
  position: relative;
  aspect-ratio: 1200 / 676;
  overflow: hidden;
  background: #f5f6f8;
}
.blog-posts .blog-card .card-image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}
.card-category,
.blog-posts .card-category {
  position: absolute;
  top: auto;
  left: 0.65rem;
  bottom: 0.65rem;
  background: var(--color-primary, #1e3a5f);
  color: #fff;
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  padding: 0.22rem 0.55rem;
  border-radius: 999px;
}
.blog-posts .blog-card .card-content {
  padding: 0.9rem 1rem 1.1rem;
  display: flex;
  flex-direction: column;
  gap: 0.4rem;
  flex: 1;
}
.card-meta { margin: 0; color: var(--text-muted, #5c6b7a); font-size: 0.82rem; }
.blog-posts .blog-card .card-title {
  font-size: 1.08rem;
  line-height: 1.35;
  margin: 0;
  letter-spacing: -0.01em;
  color: var(--color-primary, #1e3a5f);
}
.blog-posts .blog-excerpt {
  color: var(--text-secondary, #3d4a5c);
  line-height: 1.55;
  margin: 0;
  font-size: 0.95rem;
}

.post-article {
  max-width: 68ch;
  margin: 0 auto;
  padding: 1.4rem 1.1rem 3rem;
}
.post-crumb {
  font-size: 0.82rem;
  color: var(--text-muted, #5c6b7a);
  margin: 0 0 1rem;
  display: flex;
  flex-wrap: wrap;
  gap: 0.35rem;
}
.post-crumb a { color: var(--color-primary, #1e3a5f); }
.post-cover {
  width: 100%;
  height: auto;
  aspect-ratio: 1200 / 676;
  object-fit: cover;
  border-radius: 16px;
  margin: 0 0 1.1rem;
  background: #f5f6f8;
  display: block;
}
.post-article h1 {
  font-size: clamp(1.7rem, 1.25rem + 1.5vw, 2.4rem);
  line-height: 1.18;
  letter-spacing: -0.02em;
  margin: 0 0 0.7rem;
}
.post-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 0.4rem 0.9rem;
  color: var(--text-muted, #5c6b7a);
  font-size: 0.9rem;
  margin: 0 0 1.2rem;
}
.post-toc, .post-more, .post-related, .post-cta {
  background: #f5f6f8;
  border-radius: 14px;
  padding: 0.9rem 1rem;
  margin: 0 0 1.3rem;
}
.post-toc-title {
  margin: 0 0 0.4rem;
  font-size: 0.78rem;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: var(--color-primary, #1e3a5f);
}
.post-toc ol, .post-more ul { margin: 0; padding-left: 1.15rem; }
.post-toc li { margin: 0.2rem 0; }
.post-toc a, .post-more a, .post-related a { color: var(--color-primary, #1e3a5f); }
.post-article h2 {
  font-size: 1.45rem;
  line-height: 1.25;
  letter-spacing: -0.015em;
  margin: 1.8rem 0 0.5rem;
  scroll-margin-top: 5.5rem;
}
.post-article p {
  line-height: 1.75;
  margin: 0 0 1rem;
  font-size: 1.0625rem;
}
.post-cta p { margin: 0 0 0.7rem; font-size: 1rem; }
.post-actions { display: flex; flex-wrap: wrap; gap: 0.45rem; }
.post-actions a {
  display: inline-flex;
  align-items: center;
  min-height: 44px;
  padding: 0.45rem 0.95rem;
  border-radius: 999px;
  background: #fff;
  color: var(--color-primary, #1e3a5f);
  border: 1px solid var(--color-primary, #1e3a5f);
  text-decoration: none;
  font-weight: 700;
  font-size: 0.92rem;
}
.post-actions a:last-child {
  background: var(--color-primary, #1e3a5f);
  color: #fff;
}
.post-related { margin-top: 0.2rem; }
.post-back { margin-top: 1.4rem; font-size: 0.92rem; }
.reader-body .post-toc { margin-top: 0.4rem; }
.reader-content h2 { font-size: 1.35rem; line-height: 1.3; margin: 1.4rem 0 0.45rem; scroll-margin-top: 1rem; }
.reader-content p { line-height: 1.75; font-size: 1.05rem; max-width: 68ch; }
.reader-cover img { width: 100%; height: auto; aspect-ratio: 1200 / 676; object-fit: cover; display: block; }

@media (max-width: 699px) {
  .blog-toolbar .toolbar-inner { flex-direction: column; align-items: stretch; }
  .blog-toolbar .toolbar-right { justify-content: space-between; }
}

@media (prefers-reduced-motion: reduce) {
  .blog-card, .post-cover { transition: none; }
}
