/* ================================================
   Blog – estilos específicos (extiende styles.css)
   ================================================ */

/* ── Blog listing page ─────────────────────────── */

.blog-hero {
  padding: clamp(4rem, 8vw, 6rem) 0 3rem;
  background: #fffdfa;
  text-align: center;
}

.blog-hero h1 {
  font-family: 'Merriweather', serif;
  font-size: clamp(2.5rem, 5vw, 4rem);
  line-height: 1.05;
  letter-spacing: -0.025em;
  margin: 0 0 1.25rem;
}

.blog-hero .hero-lead {
  max-width: 580px;
  margin: 0 auto;
  color: var(--muted);
  font-size: 1.05rem;
}

.blog-section {
  padding: clamp(3rem, 6vw, 5rem) 0;
  background: var(--bg);
}

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

.blog-card {
  background: var(--surface);
  border: 1px solid rgba(21, 17, 15, 0.08);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  overflow: hidden;
  display: flex;
  flex-direction: column;
  text-decoration: none;
  color: var(--text);
  transition: transform 0.28s ease, box-shadow 0.28s ease;
}

.blog-card:hover {
  transform: translateY(-6px);
  box-shadow: 0 36px 100px rgba(21, 17, 15, 0.13);
}

.blog-card__image {
  aspect-ratio: 16 / 10;
  overflow: hidden;
  background: var(--surface-soft);
  flex-shrink: 0;
}

.blog-card__image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  transition: transform 0.4s ease;
}

.blog-card:hover .blog-card__image img {
  transform: scale(1.05);
}

.blog-card__body {
  padding: 1.75rem;
  display: flex;
  flex-direction: column;
  flex: 1;
  gap: 0.8rem;
}

.blog-card__top {
  display: flex;
  align-items: center;
  gap: 0.65rem;
  flex-wrap: wrap;
}

.blog-card__category {
  display: inline-block;
  background: var(--accent-soft);
  color: var(--accent);
  font-size: 0.76rem;
  font-weight: 700;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  padding: 0.26rem 0.8rem;
  border-radius: 999px;
}

.blog-card__dot {
  display: inline-block;
  width: 3px;
  height: 3px;
  border-radius: 50%;
  background: var(--muted);
  opacity: 0.4;
}

.blog-card__read {
  font-size: 0.82rem;
  color: var(--muted);
}

.blog-card__title {
  font-family: 'Merriweather', serif;
  font-size: 1.18rem;
  line-height: 1.32;
  letter-spacing: -0.01em;
  margin: 0;
}

.blog-card__excerpt {
  color: var(--muted);
  font-size: 0.94rem;
  line-height: 1.72;
  margin: 0;
  flex: 1;
}

.blog-card__footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-top: 0.5rem;
  padding-top: 1rem;
  border-top: 1px solid rgba(21, 17, 15, 0.07);
}

.blog-card__date {
  font-size: 0.82rem;
  color: var(--muted);
}

.blog-card__cta {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  font-weight: 700;
  font-size: 0.88rem;
  color: var(--accent);
}

.blog-card__cta svg {
  transition: transform 0.2s ease;
}

.blog-card:hover .blog-card__cta svg {
  transform: translateX(4px);
}

.blog-card:nth-child(1) { animation: fadeUp 0.9s ease both 0.10s; }
.blog-card:nth-child(2) { animation: fadeUp 0.9s ease both 0.15s; }
.blog-card:nth-child(3) { animation: fadeUp 0.9s ease both 0.20s; }
.blog-card:nth-child(4) { animation: fadeUp 0.9s ease both 0.25s; }
.blog-card:nth-child(5) { animation: fadeUp 0.9s ease both 0.30s; }

/* ── Article page ──────────────────────────────── */

.article-breadcrumb {
  padding: 1.75rem 0 0;
  display: flex;
  align-items: center;
  gap: 0.45rem;
  font-size: 0.86rem;
  color: var(--muted);
}

.article-breadcrumb a {
  color: var(--muted);
  font-weight: 500;
  transition: color 0.2s;
}

.article-breadcrumb a:hover {
  color: var(--text);
}

.article-breadcrumb svg {
  opacity: 0.4;
  flex-shrink: 0;
}

.article-header {
  padding: 2rem 0 3rem;
  background: #fffdfa;
}

.article-header-inner {
  max-width: 800px;
}

.article-header-meta {
  display: flex;
  align-items: center;
  gap: 0.65rem;
  flex-wrap: wrap;
  margin-bottom: 1.5rem;
}

.article-header h1 {
  font-family: 'Merriweather', serif;
  font-size: clamp(2rem, 4.5vw, 3.1rem);
  line-height: 1.1;
  letter-spacing: -0.025em;
  margin: 0 0 1.25rem;
}

.article-lead {
  font-size: 1.1rem;
  line-height: 1.78;
  color: var(--muted);
  max-width: 680px;
  margin: 0;
}

.article-image-wrap {
  background: #fffdfa;
  padding-bottom: 3rem;
}

.article-image-full {
  width: 100%;
  max-height: 480px;
  overflow: hidden;
  border-radius: var(--radius);
  box-shadow: 0 30px 80px rgba(21, 17, 15, 0.1);
}

.article-image-full img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.article-layout {
  background: #fffdfa;
  padding: 0 0 clamp(4rem, 8vw, 6rem);
}

.article-content-grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 280px;
  gap: 4rem;
  align-items: start;
}

.article-body {
  min-width: 0;
}

.article-body h2 {
  font-family: 'Merriweather', serif;
  font-size: clamp(1.35rem, 2.5vw, 1.85rem);
  line-height: 1.22;
  letter-spacing: -0.02em;
  margin: 3rem 0 1rem;
  color: var(--text);
}

.article-body p {
  margin: 0 0 1.5rem;
  color: var(--text);
  line-height: 1.88;
  font-size: 1.02rem;
}

.article-body ul,
.article-body ol {
  padding-left: 1.5rem;
  margin: 0 0 1.5rem;
}

.article-body li {
  margin-bottom: 0.65rem;
  line-height: 1.75;
  color: var(--text);
  font-size: 1.02rem;
}

.article-body strong {
  font-weight: 700;
  color: var(--text);
}

.article-body blockquote {
  margin: 2.5rem 0;
  padding: 1.5rem 2rem;
  background: var(--accent-soft);
  border-left: 3px solid var(--accent);
  border-radius: 0 16px 16px 0;
  font-style: italic;
}

.article-body blockquote p {
  margin: 0;
  color: var(--accent);
  font-size: 1.08rem;
  line-height: 1.75;
}

.article-aside {
  position: sticky;
  top: calc(80px + 1.5rem);
  display: flex;
  flex-direction: column;
  gap: 1.5rem;
}

.aside-card {
  background: var(--surface);
  border: 1px solid rgba(21, 17, 15, 0.08);
  border-radius: 22px;
  box-shadow: var(--shadow);
  padding: 1.75rem;
  animation: fadeUp 0.9s ease both 0.12s;
}

.aside-card h3 {
  font-family: 'Merriweather', serif;
  font-size: 1.05rem;
  margin: 0 0 0.75rem;
  line-height: 1.3;
}

.aside-card p {
  font-size: 0.9rem;
  color: var(--muted);
  margin: 0 0 1.25rem;
  line-height: 1.65;
}

.aside-card .button {
  width: 100%;
  font-size: 0.88rem;
  padding: 0.85rem 1.2rem;
  border-radius: 12px;
}

.aside-links {
  display: flex;
  flex-direction: column;
  gap: 0.6rem;
  margin: 0;
  padding: 0;
  list-style: none;
}

.aside-links a {
  font-size: 0.9rem;
  font-weight: 600;
  color: var(--text);
  line-height: 1.45;
  transition: color 0.2s;
}

.aside-links a:hover {
  color: var(--muted);
}

.aside-links li {
  padding-bottom: 0.6rem;
  border-bottom: 1px solid rgba(21, 17, 15, 0.07);
}

.aside-links li:last-child {
  border-bottom: none;
  padding-bottom: 0;
}

.article-cta-section {
  padding: clamp(4rem, 7vw, 5.5rem) 0;
  background: var(--bg);
  text-align: center;
}

.article-cta-section h2 {
  font-family: 'Merriweather', serif;
  font-size: clamp(1.75rem, 3vw, 2.4rem);
  margin: 0 0 1rem;
  line-height: 1.15;
}

.article-cta-section p {
  color: var(--muted);
  max-width: 540px;
  margin: 0 auto 2rem;
  font-size: 1rem;
  line-height: 1.75;
}

/* Active nav state */
.site-nav a[aria-current="page"] {
  color: var(--text);
  background: rgba(21, 17, 15, 0.06);
}

/* ── Article highlight box ─────────────────────── */

.article-highlight {
  background: var(--accent-soft);
  border-left: 3px solid var(--accent);
  border-radius: 0 16px 16px 0;
  padding: 1.5rem 2rem;
  margin-bottom: 2.5rem;
}

.article-highlight p {
  margin: 0;
  line-height: 1.75;
}

/* ── FAQ accordion ─────────────────────────────── */

.faq-list {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
  margin-bottom: 2rem;
}

.faq-item {
  border: 1px solid rgba(21, 17, 15, 0.08);
  border-radius: 14px;
  overflow: hidden;
  background: var(--surface);
}

.faq-q {
  padding: 1.1rem 1.5rem;
  font-weight: 600;
  font-size: 1rem;
  cursor: pointer;
  list-style: none;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 1rem;
}

.faq-q::-webkit-details-marker { display: none; }

.faq-q::after {
  content: "+";
  font-size: 1.25rem;
  color: var(--accent);
  font-weight: 400;
  flex-shrink: 0;
}

.faq-item[open] .faq-q::after {
  content: "−";
}

.faq-a {
  padding: 0 1.5rem 1.25rem;
  color: var(--muted);
  font-size: 0.97rem;
  line-height: 1.75;
}

/* ── Article tags ──────────────────────────────── */

.article-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  margin-top: 3rem;
  padding-top: 2rem;
  border-top: 1px solid rgba(21, 17, 15, 0.08);
}

.art-tag {
  display: inline-block;
  padding: 0.35rem 0.9rem;
  background: var(--surface);
  border: 1px solid rgba(21, 17, 15, 0.1);
  border-radius: 999px;
  font-size: 0.82rem;
  font-weight: 600;
  color: var(--muted);
  text-decoration: none;
  transition: color 0.2s, border-color 0.2s;
}

.art-tag:hover {
  color: var(--text);
  border-color: rgba(21, 17, 15, 0.25);
}

/* ── TOC in aside ──────────────────────────────── */

.aside-toc {
  padding-left: 1.2rem;
  margin: 0;
  display: flex;
  flex-direction: column;
  gap: 0.4rem;
}

.aside-toc a {
  font-size: 0.88rem;
  color: var(--muted);
  font-weight: 500;
  line-height: 1.45;
  transition: color 0.2s;
}

.aside-toc a:hover,
.aside-toc a.active {
  color: var(--accent);
}

/* ── Share buttons in aside ────────────────────── */

.aside-share {
  display: flex;
  gap: 0.75rem;
}

.share-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 40px;
  height: 40px;
  border-radius: 10px;
  background: var(--bg);
  border: 1px solid rgba(21, 17, 15, 0.1);
  font-size: 0.88rem;
  font-weight: 700;
  color: var(--text);
  text-decoration: none;
  transition: background 0.2s, border-color 0.2s, color 0.2s;
}

.share-btn:hover {
  background: var(--accent-soft);
  border-color: var(--accent);
  color: var(--accent);
}

/* ── Related articles ──────────────────────────── */

.related-section {
  background: var(--bg);
  padding: clamp(3rem, 6vw, 5rem) 0;
  border-top: 1px solid rgba(21, 17, 15, 0.07);
}

.related-section h2 {
  font-family: 'Merriweather', serif;
  font-size: clamp(1.5rem, 2.5vw, 2rem);
  margin: 0 0 2.5rem;
  text-align: center;
}

.related-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 1.5rem;
}

.related-card {
  background: var(--surface);
  border: 1px solid rgba(21, 17, 15, 0.08);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  padding: 1.5rem;
  text-decoration: none;
  color: var(--text);
  display: flex;
  flex-direction: column;
  gap: 0.65rem;
  transition: transform 0.25s ease, box-shadow 0.25s ease;
}

.related-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 24px 60px rgba(21, 17, 15, 0.12);
}

.related-cat {
  font-size: 0.75rem;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--accent);
}

.related-card h3 {
  font-family: 'Merriweather', serif;
  font-size: 1rem;
  line-height: 1.35;
  margin: 0;
}

.related-card p {
  font-size: 0.88rem;
  color: var(--muted);
  line-height: 1.65;
  flex: 1;
  margin: 0;
}

.related-read {
  font-size: 0.82rem;
  font-weight: 700;
  color: var(--accent);
  margin-top: 0.25rem;
}

/* ── Responsive ────────────────────────────────── */

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

  .article-content-grid {
    grid-template-columns: 1fr;
  }

  .article-aside {
    position: static;
  }

  .related-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 600px) {
  .blog-grid {
    grid-template-columns: 1fr;
  }

  .article-image-full {
    border-radius: 18px;
    max-height: 280px;
  }

  .article-body blockquote {
    padding: 1.25rem 1.5rem;
  }

  .related-grid {
    grid-template-columns: 1fr;
  }
}
