/* Kumplo Blog — extends kumplo-landing.css tokens */

body.l-body.blog-body {
  overflow-y: auto;
  overflow-x: hidden;
  background: var(--bg);
}

.blog-shell {
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

.blog-main {
  flex: 1;
  padding-top: 112px;
}

/* Blog hero */
.blog-hero {
  position: relative;
  padding: 40px 32px 48px;
  overflow: hidden;
  background: var(--bg);
}

.blog-hero__blob {
  position: absolute;
  pointer-events: none;
  filter: blur(60px);
  border-radius: 50%;
}

.blog-hero__blob--1 {
  top: -10%;
  left: -8%;
  width: 420px;
  height: 420px;
  background: rgba(111, 45, 255, 0.14);
  animation: meshShift 18s ease-in-out infinite;
}

.blog-hero__blob--2 {
  top: 10%;
  right: -10%;
  width: 460px;
  height: 460px;
  background: rgba(155, 103, 255, 0.12);
  animation: meshShift2 22s ease-in-out infinite;
}

.blog-hero__grid {
  position: absolute;
  inset: 0;
  background-image:
    linear-gradient(to right, rgba(15, 18, 35, 0.04) 1px, transparent 1px),
    linear-gradient(to bottom, rgba(15, 18, 35, 0.04) 1px, transparent 1px);
  background-size: 48px 48px;
  mask-image: radial-gradient(ellipse at center, black 0%, transparent 75%);
  -webkit-mask-image: radial-gradient(ellipse at center, black 0%, transparent 75%);
  pointer-events: none;
}

.blog-hero__inner {
  position: relative;
  z-index: 2;
  max-width: 1200px;
  margin: 0 auto;
}

.blog-hero__title {
  margin: 12px 0 14px;
  max-width: 720px;
}

.blog-hero__lead {
  max-width: 620px;
  margin: 0;
}

.blog-hero--compact {
  padding-bottom: 40px;
}

.blog-hero__badge {
  margin-bottom: 20px;
}

.blog-hero__badge-icon {
  width: 20px;
  height: 20px;
  border-radius: 6px;
  background: linear-gradient(135deg, var(--k-purple) 0%, var(--k-purple-700) 100%);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  color: #fff;
}

/* Content layout — mismo ancho que .l-container en la landing */
.blog-content {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 32px 96px;
}

.blog-content--narrow {
  max-width: 760px;
}

.blog-index__toolbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 12px;
  padding: 0;
}

.blog-index__count {
  margin: 0;
  font-size: 13px;
  font-weight: 500;
  color: var(--ink-400);
  letter-spacing: 0.01em;
}

.blog-index__rss {
  display: inline-flex;
  align-items: center;
  height: 30px;
  padding: 0 11px;
  border-radius: var(--r-pill);
  font-size: 11.5px;
  font-weight: 600;
  letter-spacing: 0.02em;
  text-transform: uppercase;
  color: var(--ink-500);
  background: transparent;
  border: 1px solid var(--line);
  transition: background 0.12s ease, color 0.12s ease, border-color 0.12s ease;
}

.blog-index__rss:hover {
  background: var(--surface);
  border-color: var(--line-strong);
  color: var(--ink-700);
}

.blog-list__grid {
  display: flex;
  flex-direction: column;
  gap: 40px;
}

/* Listado editorial — sin divisores; el espacio lo da gap */
.blog-list__grid .blog-card,
.l-blog-preview__list .blog-card {
  border: 0;
  border-top: 0;
  border-bottom: 0;
  box-shadow: none;
}

.blog-card {
  display: block;
  margin: 0;
  padding: 0;
  border: 0;
  background: transparent;
}

.blog-card__media {
  display: block;
  margin-bottom: 16px;
}

.blog-card__image {
  display: block;
  width: 100%;
  max-height: 220px;
  aspect-ratio: 16 / 9;
  object-fit: cover;
  border-radius: var(--r-lg);
  border: 1px solid var(--line);
}

.blog-card:has(.blog-card__media) {
  display: block;
}

.blog-card__body {
  display: block;
  padding: 0;
  min-width: 0;
}

.blog-card__title a {
  color: inherit;
  text-decoration: none;
  transition: color 0.15s var(--ease);
}

.blog-card__title a:hover {
  color: var(--k-purple);
}

.blog-card__title a:focus-visible {
  outline: 2px solid var(--k-purple-300);
  outline-offset: 3px;
  border-radius: 4px;
}

.blog-card__meta {
  margin-bottom: 14px;
}

.blog-card__title {
  font-family: var(--font-display);
  font-weight: 600;
  font-size: clamp(22px, 2.4vw, 28px);
  line-height: 1.18;
  letter-spacing: -0.022em;
  color: var(--ink-900);
  margin: 0 0 12px;
  transition: color 0.15s var(--ease);
}

.blog-card:hover .blog-card__title {
  color: var(--ink-900);
}

.blog-card__title a:hover {
  color: var(--k-purple);
}

.blog-card__excerpt {
  margin: 0 0 16px;
  font-size: 15px;
  line-height: 1.65;
  color: var(--ink-500);
  max-width: 62ch;
}

.blog-card__byline {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
  font-size: 12.5px;
  color: var(--ink-400);
}

.blog-card__byline time {
  color: var(--ink-400);
}

.blog-card__reading::before {
  content: "·";
  margin-right: 8px;
  color: var(--ink-300);
}

.blog-related {
  margin-top: 48px;
  padding-top: 40px;
  border-top: 1px solid var(--line);
}

.blog-related__title {
  font-family: var(--font-display);
  font-weight: 600;
  font-size: 22px;
  letter-spacing: -0.018em;
  color: var(--ink-900);
  margin: 0 0 20px;
}

/* Category pill */
.blog-pill {
  display: inline-flex;
  align-items: center;
  padding: 3px 10px;
  border-radius: var(--r-pill);
  font-size: 12px;
  font-weight: 500;
  color: var(--k-purple);
  background: var(--k-purple-50);
  border: 1px solid var(--k-purple-200);
  transition: background 0.12s ease, color 0.12s ease;
}

a.blog-pill:hover {
  background: var(--k-purple-100);
  color: var(--k-purple-hover);
}

/* Article */
.blog-article {
  padding-bottom: 48px;
}

.blog-article__header {
  margin-bottom: 32px;
}

.blog-article__figure {
  margin: 0 0 28px;
}

.blog-article__image {
  display: block;
  width: 100%;
  height: auto;
  border-radius: var(--r-lg);
  border: 1px solid var(--line);
}

.blog-article__title {
  margin: 14px 0 16px;
  font-size: clamp(34px, 4vw, 48px);
  line-height: 1.06;
}

.blog-article__meta {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  align-items: center;
  font-size: 13px;
  color: var(--ink-500);
}

.blog-prose {
  font-size: 16px;
  line-height: 1.7;
  color: var(--ink-600);
}

.blog-prose > *:first-child {
  margin-top: 0;
}

.blog-prose h2 {
  font-family: var(--font-display);
  font-weight: 600;
  font-size: 28px;
  line-height: 1.15;
  letter-spacing: -0.02em;
  color: var(--ink-900);
  margin: 2.2em 0 0.75em;
}

.blog-prose h3 {
  font-family: var(--font-display);
  font-weight: 600;
  font-size: 20px;
  line-height: 1.25;
  letter-spacing: -0.012em;
  color: var(--ink-900);
  margin: 1.8em 0 0.6em;
}

.blog-prose p {
  margin: 0 0 1.15em;
}

.blog-prose ul,
.blog-prose ol {
  margin: 0 0 1.15em;
  padding-left: 1.35em;
}

.blog-prose li {
  margin: 0.35em 0;
}

.blog-prose li::marker {
  color: var(--k-purple);
}

.blog-prose strong {
  color: var(--ink-800);
  font-weight: 600;
}

.blog-prose a {
  color: var(--k-purple);
  text-decoration: underline;
  text-underline-offset: 3px;
}

.blog-prose a:hover {
  color: var(--k-purple-hover);
}

.blog-prose blockquote {
  margin: 1.5em 0;
  padding: 16px 20px;
  border-left: 3px solid var(--k-purple);
  background: var(--k-purple-50);
  border-radius: 0 var(--r-md) var(--r-md) 0;
  color: var(--ink-700);
}

.blog-prose code {
  font-family: var(--font-mono);
  font-size: 0.9em;
  background: var(--surface-2);
  border: 1px solid var(--line);
  border-radius: 6px;
  padding: 0.1em 0.35em;
}

.blog-prose hr {
  border: 0;
  border-top: 1px solid var(--line);
  margin: 2em 0;
}

/* CTA block */
.blog-cta {
  margin-top: 48px;
  padding: 40px 36px;
  border-radius: var(--r-xl);
  background: linear-gradient(140deg, #ece3ff 0%, #f9f6ff 60%, #ece3ff 100%);
  border: 1px solid var(--k-purple-200);
  text-align: center;
}

.blog-cta__title {
  font-family: var(--font-display);
  font-weight: 600;
  font-size: 24px;
  letter-spacing: -0.02em;
  color: var(--ink-900);
  margin: 0 0 10px;
}

.blog-cta__text {
  margin: 0 auto 22px;
  max-width: 520px;
  font-size: 15px;
  line-height: 1.55;
  color: var(--ink-500);
}

/* Pagination */
.blog-pagination {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  margin-top: 56px;
  padding-top: 28px;
  border-top: 1px solid var(--line);
}

.blog-pagination__link {
  font-size: 13px;
  font-weight: 500;
  color: var(--ink-600);
  transition: color 0.12s ease;
}

.blog-pagination__link:hover {
  color: var(--ink-900);
}

.blog-pagination__link.is-disabled {
  color: var(--ink-300);
  pointer-events: none;
}

.blog-pagination__pages {
  display: flex;
  align-items: center;
  gap: 6px;
  list-style: none;
  margin: 0;
  padding: 0;
}

.blog-pagination__page {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 34px;
  height: 34px;
  padding: 0 8px;
  border-radius: var(--r-pill);
  font-size: 13px;
  font-weight: 500;
  color: var(--ink-600);
  transition: background 0.12s ease, color 0.12s ease;
}

.blog-pagination__page:hover {
  background: var(--surface-2);
  color: var(--ink-900);
}

.blog-pagination__page.is-active {
  background: linear-gradient(135deg, var(--k-purple) 0%, var(--k-purple-700) 100%);
  color: #fff;
}

.blog-empty {
  padding: 48px 24px;
  text-align: center;
  color: var(--ink-500);
  background: var(--surface);
  border: 1px dashed var(--line-strong);
  border-radius: var(--r-xl);
}

.l-footer-grid a:hover {
  color: var(--ink-900);
}

@media (max-width: 1024px) {
  .blog-main {
    padding-top: 96px;
  }

  .blog-hero,
  .blog-content {
    padding-left: 20px;
    padding-right: 20px;
  }

  .blog-list__grid {
    gap: 32px;
  }
}

@media (max-width: 640px) {
  .blog-list__grid {
    gap: 28px;
  }

  .blog-card__title {
    font-size: 20px;
  }

  .blog-card__excerpt {
    font-size: 14px;
  }

  .blog-cta {
    padding: 32px 22px;
  }

  .blog-pagination {
    flex-direction: column;
  }
}
