/* ============================================================
   DevEps — Blog Styles
   Mobile First
   ============================================================ */

/* ── Blog Page Header ── */
.blog-header {
  padding: calc(var(--nav-height) + 64px) 0 64px;
  background: var(--bg-secondary);
  text-align: center;
  border-bottom: 1px solid var(--glass-border);
}

.blog-header h1 {
  font-family: var(--font-heading);
  font-size: clamp(2rem, 5vw, 3.2rem);
  font-weight: 800;
  color: var(--text-light);
  margin-bottom: 16px;
}

.blog-header p {
  font-size: 1.05rem;
  color: var(--text-secondary);
  max-width: 600px;
  margin: 0 auto;
  line-height: 1.6;
}

/* ── Blog Main Section ── */
.blog-section {
  padding: 80px 0 100px;
  background: var(--bg-primary);
  min-height: 60vh;
}

/* ── Article Cards Grid ── */
.blog-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 28px;
}

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

/* ── Article Card ── */
.blog-card {
  background: var(--glass-bg);
  border: 1px solid var(--glass-border);
  border-radius: 16px;
  padding: 28px;
  display: flex;
  flex-direction: column;
  gap: 12px;
  transition: all var(--transition);
}

.blog-card:hover {
  background: var(--glass-bg-hover);
  border-color: rgba(255, 107, 0, 0.2);
  transform: translateY(-4px);
  box-shadow: 0 12px 40px rgba(0, 0, 0, 0.3);
}

.blog-card-meta {
  display: flex;
  align-items: center;
  gap: 12px;
  flex-wrap: wrap;
}

.blog-date {
  font-size: 0.8rem;
  color: var(--text-secondary);
}

.blog-badge {
  display: inline-block;
  padding: 3px 10px;
  border-radius: 20px;
  font-size: 0.73rem;
  font-weight: 600;
  letter-spacing: 0.3px;
  background: rgba(255, 107, 0, 0.12);
  color: var(--orange);
  border: 1px solid rgba(255, 107, 0, 0.2);
}

.blog-badge.cat-seo       { background: rgba(99, 179, 237, 0.1); color: #63b3ed; border-color: rgba(99, 179, 237, 0.2); }
.blog-badge.cat-dev       { background: rgba(104, 211, 145, 0.1); color: #68d391; border-color: rgba(104, 211, 145, 0.2); }
.blog-badge.cat-marketing { background: rgba(246, 173, 85, 0.1); color: #f6ad55; border-color: rgba(246, 173, 85, 0.2); }
.blog-badge.cat-precios   { background: rgba(255, 107, 0, 0.12); color: var(--orange); border-color: rgba(255, 107, 0, 0.2); }

.blog-card h2 {
  font-family: var(--font-heading);
  font-size: 1.15rem;
  font-weight: 700;
  line-height: 1.35;
  color: var(--text-light);
  margin: 0;
}

.blog-card h2 a {
  color: inherit;
  transition: color var(--transition);
}

.blog-card h2 a:hover {
  color: var(--orange);
}

.blog-card p {
  font-size: 0.9rem;
  color: var(--text-secondary);
  line-height: 1.6;
  flex-grow: 1;
  margin: 0;
  display: -webkit-box;
  -webkit-line-clamp: 3;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.blog-read-more {
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--orange);
  display: inline-flex;
  align-items: center;
  gap: 4px;
  transition: gap var(--transition);
  margin-top: 4px;
}

.blog-read-more:hover {
  gap: 8px;
}

/* ── Empty State ── */
.blog-empty {
  grid-column: 1 / -1;
  text-align: center;
  padding: 80px 20px;
}

.blog-empty-icon {
  width: 64px;
  height: 64px;
  margin: 0 auto 24px;
  background: var(--glass-bg);
  border: 1px solid var(--glass-border);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
}

.blog-empty-icon svg {
  width: 28px;
  height: 28px;
  stroke: var(--orange);
  stroke-width: 1.5;
  fill: none;
}

.blog-empty h3 {
  font-family: var(--font-heading);
  font-size: 1.3rem;
  font-weight: 700;
  color: var(--text-light);
  margin-bottom: 12px;
}

.blog-empty p {
  color: var(--text-secondary);
  font-size: 0.95rem;
  max-width: 400px;
  margin: 0 auto;
}

/* ════════════════════════════════════════════
   ARTICLE PAGE STYLES
   ════════════════════════════════════════════ */

/* ── Article Header ── */
.article-header {
  padding: calc(var(--nav-height) + 48px) 0 40px;
  background: var(--bg-secondary);
  border-bottom: 1px solid var(--glass-border);
}

.article-header .container {
  max-width: 760px;
}

/* ── Breadcrumb ── */
.breadcrumb {
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: 0.82rem;
  color: var(--text-secondary);
  margin-bottom: 20px;
  flex-wrap: wrap;
}

.breadcrumb a {
  color: var(--text-secondary);
  transition: color var(--transition);
}

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

.breadcrumb-sep {
  color: rgba(255, 255, 255, 0.2);
}

.breadcrumb-current {
  color: var(--text-light);
  font-weight: 500;
}

/* ── Article Meta ── */
.article-meta {
  display: flex;
  align-items: center;
  gap: 14px;
  margin-bottom: 20px;
  flex-wrap: wrap;
}

.article-date {
  font-size: 0.85rem;
  color: var(--text-secondary);
}

/* ── Article Title ── */
.article-header h1 {
  font-family: var(--font-heading);
  font-size: clamp(1.7rem, 4vw, 2.5rem);
  font-weight: 800;
  line-height: 1.2;
  color: var(--text-light);
  margin-bottom: 20px;
}

/* ── Article Body ── */
.article-body {
  padding: 64px 0 80px;
  background: var(--bg-primary);
}

.article-content {
  max-width: 720px;
  margin: 0 auto;
}

.article-content h2 {
  font-family: var(--font-heading);
  font-size: 1.55rem;
  font-weight: 700;
  color: var(--text-light);
  margin: 48px 0 16px;
  padding-top: 8px;
}

.article-content h2:first-child {
  margin-top: 0;
}

.article-content h3 {
  font-family: var(--font-heading);
  font-size: 1.2rem;
  font-weight: 600;
  color: var(--text-light);
  margin: 32px 0 12px;
}

.article-content p {
  font-size: 1rem;
  color: var(--text-secondary);
  line-height: 1.75;
  margin-bottom: 20px;
}

.article-content a {
  color: var(--orange);
  text-decoration: underline;
  text-underline-offset: 3px;
  transition: color var(--transition);
}

.article-content a:hover {
  color: var(--orange-hover);
}

.article-content ul,
.article-content ol {
  margin: 0 0 20px 20px;
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.article-content ul { list-style: disc; }
.article-content ol { list-style: decimal; }

.article-content li {
  font-size: 1rem;
  color: var(--text-secondary);
  line-height: 1.7;
}

.article-content img {
  width: 100%;
  border-radius: 8px;
  margin: 24px 0;
}

.article-content blockquote {
  border-left: 3px solid var(--orange);
  padding: 12px 20px;
  margin: 24px 0;
  background: rgba(255, 107, 0, 0.05);
  border-radius: 0 8px 8px 0;
}

.article-content blockquote p {
  margin: 0;
  font-style: italic;
  color: var(--text-light);
}

.article-content code {
  font-family: 'Courier New', Courier, monospace;
  font-size: 0.88em;
  background: rgba(255, 255, 255, 0.07);
  border: 1px solid var(--glass-border);
  border-radius: 4px;
  padding: 2px 6px;
  color: #f0c070;
}

.article-content pre {
  background: rgba(0, 0, 0, 0.4);
  border: 1px solid var(--glass-border);
  border-radius: 10px;
  padding: 20px;
  overflow-x: auto;
  margin: 24px 0;
}

.article-content pre code {
  background: none;
  border: none;
  padding: 0;
  font-size: 0.9rem;
  color: #e2e8f0;
  line-height: 1.7;
}

/* ── Article Author ── */
.article-author {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 24px;
  background: var(--glass-bg);
  border: 1px solid var(--glass-border);
  border-radius: 12px;
  margin-top: 48px;
}

.author-avatar {
  width: 48px;
  height: 48px;
  border-radius: 50%;
  background: var(--orange);
  flex-shrink: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  font-family: var(--font-heading);
  font-weight: 700;
  font-size: 1.1rem;
  color: white;
}

.author-info p {
  margin: 0;
  font-size: 0.88rem;
  color: var(--text-secondary);
  line-height: 1.4;
}

.author-info strong {
  font-weight: 600;
  color: var(--text-light);
}

.author-info a {
  color: var(--orange);
}

/* ── Article CTA ── */
.article-cta {
  margin-top: 48px;
  padding: 36px;
  background: linear-gradient(135deg, rgba(255, 107, 0, 0.1) 0%, rgba(255, 107, 0, 0.05) 100%);
  border: 1px solid rgba(255, 107, 0, 0.2);
  border-radius: 16px;
  text-align: center;
}

.article-cta h3 {
  font-family: var(--font-heading);
  font-size: 1.3rem;
  font-weight: 700;
  color: var(--text-light);
  margin-bottom: 8px;
}

.article-cta p {
  color: var(--text-secondary);
  font-size: 0.95rem;
  margin-bottom: 20px;
}

.article-cta .btn-primary {
  display: inline-block;
  padding: 14px 32px;
  background: var(--orange);
  color: white;
  font-weight: 700;
  font-size: 0.95rem;
  border-radius: 50px;
  transition: all var(--transition);
}

.article-cta .btn-primary:hover {
  background: var(--orange-hover);
  transform: translateY(-2px);
  box-shadow: 0 8px 30px var(--orange-glow);
}

/* ── Related Articles ── */
.related-section {
  margin-top: 64px;
  padding-top: 48px;
  border-top: 1px solid var(--glass-border);
}

.related-section h3 {
  font-family: var(--font-heading);
  font-size: 1.2rem;
  font-weight: 700;
  color: var(--text-light);
  margin-bottom: 24px;
}

.related-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 16px;
}

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

.related-card {
  padding: 20px;
  background: var(--glass-bg);
  border: 1px solid var(--glass-border);
  border-radius: 12px;
  transition: all var(--transition);
}

.related-card:hover {
  background: var(--glass-bg-hover);
  border-color: rgba(255, 107, 0, 0.2);
  transform: translateY(-2px);
}

.related-card .blog-date {
  margin-bottom: 8px;
  display: block;
}

.related-card h4 {
  font-family: var(--font-heading);
  font-size: 0.95rem;
  font-weight: 600;
  color: var(--text-light);
  line-height: 1.35;
}

.related-card h4 a {
  color: inherit;
  transition: color var(--transition);
}

.related-card h4 a:hover {
  color: var(--orange);
}

/* ── Mobile Menu link active ── */
.mobile-menu a.active {
  color: var(--orange);
}

.nav-links a.active {
  color: var(--text-light);
}

.nav-links a.active::after {
  width: 100%;
}
