/* ============================================================ */
/* XENTROX BLOG — Page-specific styles                           */
/* Linked to shared.css for design tokens & base styles          */
/* ============================================================ */

/* ============================================================ */
/* BLOG SECTION HEADER                                           */
/* ============================================================ */
.blog-section-header {
  text-align: center;
  margin-bottom: var(--space-16);
}
.blog-section-header .prod-header-line {
  width: 48px;
  height: 3px;
  background: linear-gradient(90deg, var(--color-accent-violet), var(--color-primary));
  border-radius: 2px;
  margin: 0 auto var(--space-4);
}

/* ============================================================ */
/* BLOG CARD GRID — Responsive 3-column layout                   */
/* ============================================================ */
.blog-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: var(--space-8);
}

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

@media (max-width: 640px) {
  .blog-grid {
    grid-template-columns: 1fr;
    gap: var(--space-6);
  }
}

/* ============================================================ */
/* BLOG CARD — Glassmorphic card with 1:1 square image           */
/* ============================================================ */
.blog-card {
  border-radius: var(--radius-xl);
  overflow: hidden;
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid var(--border-subtle);
  transition: transform var(--motion-base) var(--ease-out-expo),
              box-shadow var(--motion-base) var(--ease-out-expo),
              border-color var(--motion-base) var(--ease-out-expo);
}

.blog-card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-card-hover);
  border-color: var(--border-strong);
}

/* ============================================================ */
/* BLOG CARD — Multi-Chromatic Halo Glow Variants               */
/* ============================================================ */

/* --- Cyan Glow Variant --- */
.blog-card-glow-cyan {
  position: relative;
}

.blog-card-glow-cyan::before {
  content: '';
  position: absolute;
  inset: -2px;
  border-radius: inherit;
  background: linear-gradient(135deg, rgba(0, 184, 255, 0.15), rgba(0, 184, 255, 0.05));
  opacity: 0;
  transition: opacity var(--motion-base) var(--ease-out-expo);
  z-index: -1;
  pointer-events: none;
}

.blog-card-glow-cyan::after {
  content: '';
  position: absolute;
  inset: -1px;
  border-radius: inherit;
  box-shadow: 0 0 35px rgba(0, 184, 255, 0.25), 0 0 70px rgba(0, 184, 255, 0.1);
  opacity: 0;
  transition: opacity var(--motion-base) var(--ease-out-expo);
  z-index: -1;
  pointer-events: none;
}

.blog-card-glow-cyan:hover {
  border-color: #00b8ff;
  box-shadow: 0 0 35px rgba(0, 184, 255, 0.25), 0 0 70px rgba(0, 184, 255, 0.1);
}

.blog-card-glow-cyan:hover::before {
  opacity: 1;
}

.blog-card-glow-cyan:hover::after {
  opacity: 1;
}

/* --- Pink Glow Variant --- */
.blog-card-glow-pink {
  position: relative;
}

.blog-card-glow-pink::before {
  content: '';
  position: absolute;
  inset: -2px;
  border-radius: inherit;
  background: linear-gradient(135deg, rgba(255, 47, 163, 0.15), rgba(255, 47, 163, 0.05));
  opacity: 0;
  transition: opacity var(--motion-base) var(--ease-out-expo);
  z-index: -1;
  pointer-events: none;
}

.blog-card-glow-pink::after {
  content: '';
  position: absolute;
  inset: -1px;
  border-radius: inherit;
  box-shadow: 0 0 35px rgba(255, 47, 163, 0.25), 0 0 70px rgba(255, 47, 163, 0.1);
  opacity: 0;
  transition: opacity var(--motion-base) var(--ease-out-expo);
  z-index: -1;
  pointer-events: none;
}

.blog-card-glow-pink:hover {
  border-color: #ff2fa3;
  box-shadow: 0 0 35px rgba(255, 47, 163, 0.25), 0 0 70px rgba(255, 47, 163, 0.1);
}

.blog-card-glow-pink:hover::before {
  opacity: 1;
}

.blog-card-glow-pink:hover::after {
  opacity: 1;
}

/* --- Violet Glow Variant --- */
.blog-card-glow-violet {
  position: relative;
}

.blog-card-glow-violet::before {
  content: '';
  position: absolute;
  inset: -2px;
  border-radius: inherit;
  background: linear-gradient(135deg, rgba(139, 92, 246, 0.15), rgba(139, 92, 246, 0.05));
  opacity: 0;
  transition: opacity var(--motion-base) var(--ease-out-expo);
  z-index: -1;
  pointer-events: none;
}

.blog-card-glow-violet::after {
  content: '';
  position: absolute;
  inset: -1px;
  border-radius: inherit;
  box-shadow: 0 0 35px rgba(139, 92, 246, 0.25), 0 0 70px rgba(139, 92, 246, 0.1);
  opacity: 0;
  transition: opacity var(--motion-base) var(--ease-out-expo);
  z-index: -1;
  pointer-events: none;
}

.blog-card-glow-violet:hover {
  border-color: #8b5cf6;
  box-shadow: 0 0 35px rgba(139, 92, 246, 0.25), 0 0 70px rgba(139, 92, 246, 0.1);
}

.blog-card-glow-violet:hover::before {
  opacity: 1;
}

.blog-card-glow-violet:hover::after {
  opacity: 1;
}

.blog-card-link {
  text-decoration: none !important;
  color: inherit;
  display: block;
}

/* ============================================================ */
/* UNDERLINE ELIMINATION — Blog card links never underline       */
/* ============================================================ */
.blog-card a,
.blog-card a:hover,
.blog-card-link,
.blog-card-link:hover,
.blog-card-title,
.blog-card-title a,
.blog-card-title a:hover,
.blog-card-read-more,
.blog-card:hover .blog-card-read-more {
  text-decoration: none !important;
}

/* --- Square 1:1 Image Container --- */
.blog-card-image {
  position: relative;
  width: 100%;
  aspect-ratio: 1 / 1;
  overflow: hidden;
  border-bottom: 1px solid var(--border-subtle);
}

.blog-card-image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  transition: transform var(--motion-slow) var(--ease-out-expo);
}

.blog-card:hover .blog-card-image img {
  transform: scale(1.04);
}

.blog-card-placeholder {
  width: 100%;
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  background:
    linear-gradient(135deg, rgba(139, 92, 246, 0.12) 0%, rgba(0, 184, 255, 0.08) 50%, rgba(255, 47, 163, 0.08) 100%);
  border-bottom: 1px solid var(--border-subtle);
}

.blog-card-placeholder span {
  font-size: 0.75rem;
  font-weight: 600;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  color: var(--text-subtle);
}

/* --- Badge / Tag --- */
.blog-card-badge {
  position: absolute;
  top: var(--space-3);
  left: var(--space-3);
  font-size: 0.6rem;
  font-weight: 700;
  font-family: var(--font-mono);
  letter-spacing: 0.12em;
  text-transform: uppercase;
  padding: 0.25rem 0.6rem;
  border-radius: var(--radius-full);
  backdrop-filter: blur(8px);
  z-index: 2;
}

.badge-cyan {
  background: rgba(0, 184, 255, 0.2);
  color: var(--color-primary);
  border: 1px solid rgba(0, 184, 255, 0.3);
}

.badge-pink {
  background: rgba(255, 47, 163, 0.2);
  color: var(--color-accent-pink);
  border: 1px solid rgba(255, 47, 163, 0.3);
}

.badge-violet {
  background: rgba(139, 92, 246, 0.2);
  color: var(--color-accent-violet);
  border: 1px solid rgba(139, 92, 246, 0.3);
}

/* --- Card Body --- */
.blog-card-body {
  padding: var(--space-5);
}

/* --- Meta row: author · date · read time --- */
.blog-card-meta {
  display: flex;
  align-items: center;
  gap: var(--space-2);
  font-size: 0.7rem;
  color: var(--text-subtle);
  margin-bottom: var(--space-3);
  flex-wrap: wrap;
}

.blog-card-author {
  font-weight: 600;
  color: var(--text-body);
}

.blog-card-dot {
  color: var(--text-subtle);
  opacity: 0.5;
}

.blog-card-date,
.blog-card-read {
  font-family: var(--font-mono);
  font-size: 0.65rem;
}

/* --- Card Title --- */
.blog-card-title {
  font-size: 1rem;
  font-weight: 700;
  color: var(--text-heading);
  line-height: 1.4;
  letter-spacing: -0.01em;
  margin-bottom: var(--space-2);
  transition: color var(--motion-fast) ease;
}

.blog-card:hover .blog-card-title {
  color: var(--color-primary);
}

/* --- Card Excerpt --- */
.blog-card-excerpt {
  font-size: 0.8rem;
  color: var(--text-body);
  line-height: 1.6;
  margin-bottom: var(--space-3);
  display: -webkit-box;
  -webkit-line-clamp: 3;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

/* --- Read More --- */
.blog-card-read-more {
  font-size: 0.75rem;
  font-weight: 600;
  color: var(--color-primary);
  transition: color var(--motion-fast) ease;
}

.blog-card:hover .blog-card-read-more {
  color: var(--color-accent-violet);
}

/* ============================================================ */
/* NEWSLETTER SECTION                                            */
/* ============================================================ */
.blog-newsletter {
  border-radius: var(--radius-xl);
  overflow: hidden;
  background: rgba(255, 255, 255, 0.02);
  border: 1px solid var(--border-subtle);
  padding: var(--space-16) var(--space-8);
}

.blog-newsletter-inner {
  max-width: 600px;
  margin: 0 auto;
  text-align: center;
}

.blog-newsletter-form {
  display: flex;
  gap: var(--space-3);
  max-width: 460px;
  margin: 0 auto;
}

@media (max-width: 480px) {
  .blog-newsletter-form {
    flex-direction: column;
  }
}

/* ============================================================ */
/* PROD BRAND LABEL — Reused from productions.css pattern        */
/* ============================================================ */
.prod-brand-label {
  position: relative;
  z-index: 10;
  font-size: var(--intro-brand-label-size);
  font-weight: 700;
  letter-spacing: 0.4em;
  text-transform: uppercase;
  color: rgba(255, 255, 255, 0.3);
  margin-bottom: 0.5rem;
  opacity: 0;
  transform: translateY(8px);
}

.prod-brand-label.is-in {
  transition: opacity 0.6s ease, transform 0.6s ease;
  opacity: 1;
  transform: translateY(0);
}

/* ============================================================ */
/* PROD HEADER LINE — Reused accent line                         */
/* ============================================================ */
.prod-header-line {
  width: 48px;
  height: 3px;
  background: linear-gradient(90deg, var(--color-accent-violet), var(--color-primary));
  border-radius: 2px;
  margin: 0 auto var(--space-4);
}

/* ============================================================ */
/* SECTION INK — Dark section background                         */
/* ============================================================ */
.section-ink {
  background: var(--bg-surface);
}

/* ============================================================ */
/* RESPONSIVE ADJUSTMENTS                                        */
/* ============================================================ */
@media (max-width: 768px) {
  .blog-newsletter {
    padding: var(--space-10) var(--space-5);
  }

  .blog-card-body {
    padding: var(--space-4);
  }

  .blog-card-title {
    font-size: 0.95rem;
  }
}

/* Smooth staggered reveal for cards */
.blog-card.reveal {
  opacity: 0;
  transform: translateY(28px);
  transition: opacity 0.75s var(--ease-out-expo),
              transform 0.75s var(--ease-out-expo),
              border-color var(--motion-base) var(--ease-out-expo),
              box-shadow var(--motion-base) var(--ease-out-expo);
  will-change: opacity, transform;
}

.blog-card.reveal.visible {
  opacity: 1;
  transform: translateY(0);
}
