/* =========================================
   VIP BLOG CSS - ADVCARO.IO.VN
   ========================================= */

/* Override strict body styles from style_v7.css */
body {
  overflow-y: auto !important;
  overflow-x: hidden !important;
  -webkit-user-select: auto !important;
  user-select: auto !important;
  display: block !important;
}

.blog-page-wrapper {
  display: flex;
  flex-direction: column;
  align-items: center;
  min-height: 100dvh;
  background: transparent;
  width: 100%;
  position: relative;
  padding-bottom: 60px;
}

.blog-container {
  width: 100%;
  max-width: 1200px;
  margin: 0 auto;
  padding: 80px 24px 40px;
  display: flex;
  flex-direction: column;
  align-items: center;
}

/* ── HEADER ── */
.blog-header {
  text-align: center;
  margin-bottom: 48px;
  animation: fadeSlideDown 0.6s ease both;
  width: 100%;
  max-width: 800px;
}

.blog-title {
  font-size: 3rem;
  font-weight: 800;
  margin-bottom: 16px;
  background: linear-gradient(135deg, #a5b4fc 0%, #c084fc 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  display: inline-block;
  line-height: 1.2;
}

.blog-subtitle {
  font-size: 1.1rem;
  color: #94a3b8;
  line-height: 1.6;
}

/* ── VIP GRID LAYOUT ── */
.blog-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(340px, 1fr));
  gap: 32px;
  width: 100%;
}

/* ── VIP BLOG CARD ── */
.blog-card {
  background: rgba(30, 41, 59, 0.4);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 24px;
  overflow: hidden;
  transition: all 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
  display: flex;
  flex-direction: column;
  text-decoration: none;
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  position: relative;
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.2);
}

.blog-card::before {
  content: '';
  position: absolute;
  top: 0; left: 0; right: 0; bottom: 0;
  border-radius: 24px;
  padding: 2px;
  background: linear-gradient(135deg, rgba(255,255,255,0.2) 0%, rgba(255,255,255,0) 100%);
  -webkit-mask: linear-gradient(#fff 0 0) content-box, linear-gradient(#fff 0 0);
  -webkit-mask-composite: xor;
  mask-composite: exclude;
  pointer-events: none;
}

.blog-card:hover {
  transform: translateY(-8px) scale(1.02);
  box-shadow: 0 20px 40px rgba(0, 0, 0, 0.4), 0 0 40px rgba(99, 102, 241, 0.15);
  border-color: rgba(99, 102, 241, 0.5);
}

.blog-card-img-wrap {
  width: 100%;
  aspect-ratio: 16/9;
  overflow: hidden;
  position: relative;
  background: #0f172a;
}

.blog-card-img-wrap img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.6s ease;
}

.blog-card:hover .blog-card-img-wrap img {
  transform: scale(1.08);
}

.blog-tag-float {
  position: absolute;
  top: 16px;
  left: 16px;
  background: rgba(15, 23, 42, 0.75);
  backdrop-filter: blur(8px);
  border: 1px solid rgba(255, 255, 255, 0.15);
  color: #a5b4fc;
  padding: 6px 12px;
  border-radius: 20px;
  font-size: 0.75rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 1px;
  z-index: 2;
}

.blog-card-content {
  padding: 24px;
  display: flex;
  flex-direction: column;
  flex-grow: 1;
}

.blog-card-title {
  font-size: 1.35rem;
  font-weight: 700;
  color: #f8fafc;
  margin: 0 0 12px 0;
  line-height: 1.4;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.blog-card-excerpt {
  font-size: 0.95rem;
  color: #cbd5e1;
  line-height: 1.6;
  margin-bottom: 24px;
  flex-grow: 1;
  display: -webkit-box;
  -webkit-line-clamp: 3;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.blog-card-footer {
  display: flex;
  justify-content: space-between;
  align-items: center;
  border-top: 1px solid rgba(255, 255, 255, 0.1);
  padding-top: 16px;
  font-size: 0.85rem;
  color: #94a3b8;
}

.blog-meta-author {
  display: flex;
  align-items: center;
  gap: 8px;
}

.blog-meta-author img {
  width: 24px;
  height: 24px;
  border-radius: 50%;
  border: 1px solid rgba(255, 255, 255, 0.2);
}

.read-more-btn {
  color: #a5b4fc;
  font-weight: 600;
  display: flex;
  align-items: center;
  gap: 4px;
  transition: gap 0.2s;
}

.blog-card:hover .read-more-btn {
  gap: 8px;
  color: #c084fc;
}

/* ── POST DETAIL PAGE ── */
.post-hero {
  width: 100%;
  max-width: 800px;
  margin: 0 auto 40px;
  border-radius: 24px;
  overflow: hidden;
  position: relative;
  box-shadow: 0 10px 40px rgba(0, 0, 0, 0.4);
}

.post-hero img {
  width: 100%;
  aspect-ratio: 21/9;
  object-fit: cover;
  display: block;
}

.post-header-meta {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 16px;
  margin-bottom: 24px;
  color: #94a3b8;
  font-size: 0.9rem;
}

.post-title {
  font-size: 3rem;
  font-weight: 800;
  color: #f8fafc;
  line-height: 1.2;
  margin-bottom: 32px;
  text-align: center;
}

.post-content {
  width: 100%;
  max-width: 760px;
  margin: 0 auto;
  font-size: 1.1rem;
  line-height: 1.8;
  color: #cbd5e1;
  background: rgba(15, 23, 42, 0.6);
  padding: 40px;
  border-radius: 24px;
  border: 1px solid rgba(255, 255, 255, 0.05);
  backdrop-filter: blur(10px);
}

.post-content h2 {
  color: #f8fafc;
  font-size: 1.8rem;
  margin: 40px 0 20px;
  padding-bottom: 12px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.post-content h3 {
  color: #e2e8f0;
  font-size: 1.4rem;
  margin: 32px 0 16px;
}

.post-content p {
  margin-bottom: 24px;
}

.post-content img {
  max-width: 100%;
  border-radius: 12px;
  margin: 32px 0;
  box-shadow: 0 4px 20px rgba(0,0,0,0.3);
}

.post-content ul, .post-content ol {
  margin-bottom: 24px;
  padding-left: 24px;
}

.post-content li {
  margin-bottom: 12px;
}

.post-content blockquote {
  border-left: 4px solid #818cf8;
  padding-left: 24px;
  margin: 32px 0;
  font-style: italic;
  color: #a5b4fc;
  background: rgba(99, 102, 241, 0.05);
  padding: 24px;
  border-radius: 0 12px 12px 0;
  font-size: 1.2rem;
}

.post-content strong {
  color: #f8fafc;
  font-weight: 700;
}

/* ── RESPONSIVE ── */
@media (max-width: 768px) {
  .blog-title {
    font-size: 2.2rem;
  }
  .post-title {
    font-size: 2rem;
  }
  .blog-grid {
    grid-template-columns: 1fr;
  }
  .post-hero img {
    aspect-ratio: 16/9;
  }
  .post-content {
    padding: 24px 20px;
  }
}
