/* Blog Styles - Refined for SciTrack Futuristic Aesthetic */

/* Blog Category Badge */
.blog-post-category-badge {
  display: inline-block;
  background: rgba(44, 122, 123, 0.15);
  color: #2C7A7B;
  padding: 6px 14px;
  border-radius: 10px;
  font-size: 0.75rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  text-decoration: none;
  transition: all 0.2s ease;
  border: 1px solid rgba(44, 122, 123, 0.2);
  backdrop-filter: blur(5px);
  -webkit-backdrop-filter: blur(5px);
}

.blog-post-category-badge:hover {
  background: #2C7A7B;
  color: white;
  transform: translateY(-2px);
  box-shadow: 0 4px 12px rgba(44, 122, 123, 0.2);
}

:root {
  --navy-blue: #1A365D;
  --navy-light: #2D3748;
  --teal-brand: #2C7A7B;
  --glass-surface: rgba(255, 255, 255, 0.85);
  --glass-border: rgba(26, 54, 93, 0.12);
}

/* Common Feed-Style Utilities */
.glass-card {
  background: var(--glass-surface) !important;
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border: 1px solid var(--glass-border) !important;
  border-radius: 24px !important;
  box-shadow: 0 16px 32px rgba(26, 54, 100, 0.04) !important;
}

.hover-lift {
  transition: all 0.25s cubic-bezier(0.175, 0.885, 0.32, 1.275);
}

.hover-lift:hover {
  transform: translateX(8px);
  background: white !important;
  border-color: var(--teal-brand) !important;
  box-shadow: 0 12px 30px rgba(44, 122, 123, 0.08) !important;
}

.avatar-block {
  border: 1px solid var(--glass-border);
  background: rgba(26, 54, 93, 0.04) !important;
  border-radius: 12px;
  overflow: hidden;
  flex-shrink: 0;
}


@keyframes blog-spinner {
  to {
    transform: rotate(360deg);
  }
}

.btn-scitrack-outline {
  border: 1.5px solid var(--teal-brand) !important;
  color: var(--teal-brand) !important;
  background: transparent !important;
  border-radius: 12px !important;
  font-weight: 700 !important;
  padding: 10px 24px !important;
  transition: all 0.2s ease !important;
}

.btn-scitrack-outline:hover {
  background: var(--teal-brand) !important;
  color: white !important;
  transform: translateY(-1px);
}

/* Blog Main Styles */
.blog-page {
  background-color: #f8fafc;
}

/* Modern Notification System */
.blog-notification {
  position: fixed;
  top: 20px;
  right: 20px;
  z-index: 9999;
  max-width: 420px;
  width: 100%;
  transform: translateX(120%);
  transition: transform 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.blog-notification-show {
  transform: translateX(0);
}

.blog-notification-content {
  display: flex;
  align-items: flex-start;
  gap: 1rem;
  padding: 1.25rem;
  border-radius: 1rem;
  box-shadow: 0 10px 40px rgba(0, 0, 0, 0.12);
  backdrop-filter: blur(10px);
  background: rgba(255, 255, 255, 0.95);
}

.blog-notification-icon {
  flex-shrink: 0;
  width: 40px;
  height: 40px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
  font-size: 1.25rem;
}

.blog-notification-success .blog-notification-icon {
  background: linear-gradient(135deg, #10b981 0%, #059669 100%);
  color: white;
}

.blog-notification-error .blog-notification-icon {
  background: linear-gradient(135deg, #ef4444 0%, #dc2626 100%);
  color: white;
}

.blog-notification-message {
  flex: 1;
  min-width: 0;
}

.blog-notification-title {
  font-size: 1rem;
  font-weight: 700;
  margin: 0 0 0.25rem 0;
  color: #1e293b;
}

.blog-notification-text {
  font-size: 0.875rem;
  margin: 0;
  color: #64748b;
  line-height: 1.5;
}

.blog-notification-close {
  flex-shrink: 0;
  background: none;
  border: none;
  color: #94a3b8;
  cursor: pointer;
  padding: 0.25rem;
  transition: all 0.2s ease;
  display: flex;
  align-items: center;
  justify-content: center;
}

.blog-notification-close:hover {
  color: #64748b;
  background: rgba(0, 0, 0, 0.05);
  border-radius: 0.375rem;
}

/* Hero Section */
.blog-hero {
  background: linear-gradient(135deg, #1e3a8a 0%, #1e40af 100%);
  color: white;
  padding: 6rem 0;
}

.blog-search-form .form-control {
  border: none;
  box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1);
}

/* Blog Cards */
.blog-post-card {
  border: none;
  border-radius: 1rem;
  overflow: hidden;
  transition: transform 0.3s ease, box-shadow 0.3s ease;
  background: white;
  height: 100%;
}

.blog-post-card:hover {
  transform: translateY(-5px);
  box-shadow: 0 20px 25px -5px rgba(0, 0, 0, 0.1);
}

.blog-post-image {
  height: 200px;
  overflow: hidden;
}

.blog-post-image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.blog-post-content {
  padding: 1.5rem;
}

.blog-post-category {
  font-size: 0.875rem;
  font-weight: 600;
  color: #2563eb;
  text-transform: uppercase;
  letter-spacing: 0.025em;
  text-decoration: none;
}

.blog-post-title {
  font-size: 1.25rem;
  margin-top: 0.5rem;
  margin-bottom: 0.75rem;
}

.blog-post-title a {
  color: #1e293b;
  text-decoration: none;
}

.blog-post-excerpt {
  color: #64748b;
  font-size: 0.875rem;
  line-height: 1.5;
  margin-bottom: 1.25rem;
}

.blog-post-footer {
  padding-top: 1rem;
  border-top: 1px solid #f1f5f9;
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.blog-post-meta {
  font-size: 0.75rem;
  color: #94a3b8;
}

.blog-post-stats {
  display: flex;
  gap: 1rem;
}

.blog-post-stat {
  font-size: 0.75rem;
  color: #94a3b8;
  display: flex;
  align-items: center;
  gap: 0.25rem;
}

/* Sidebar */
.blog-sidebar-card {
  background: white;
  border-radius: 1rem;
  padding: 1.5rem;
  margin-bottom: 2rem;
  box-shadow: 0 1px 3px 0 rgba(0, 0, 0, 0.1);
}

.blog-sidebar-title {
  font-size: 1.125rem;
  font-weight: 700;
  margin-bottom: 1.25rem;
  color: #1e293b;
}

.blog-sidebar-list {
  list-style: none;
  padding: 0;
  margin: 0;
}

.blog-sidebar-link {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 0.5rem 0;
  color: #475569;
  text-decoration: none;
  transition: color 0.2s;
}

.blog-sidebar-link:hover {
  color: #2563eb;
}

.blog-tag-badge {
  display: inline-block;
  padding: 0.375rem 0.75rem;
  background-color: #f1f5f9;
  color: #475569;
  border-radius: 9999px;
  font-size: 0.75rem;
  text-decoration: none;
  margin: 0.25rem;
  transition: background-color 0.2s;
}

.blog-tag-badge:hover {
  background-color: #e2e8f0;
}

/* Single Post Page */
.blog-post-header {
  height: 400px;
  position: relative;
  overflow: hidden;
  display: flex;
  align-items: center;
  color: white;
}

.blog-post-featured-image {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  z-index: -1;
}

.blog-post-header-overlay {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(0, 0, 0, 0.5);
  z-index: -1;
}

.blog-post-body {
  font-size: 1.125rem;
  line-height: 1.75;
  color: #334155;
}

.blog-post-body img {
  max-width: 100%;
  height: auto;
  border-radius: 0.5rem;
  margin: 2rem 0;
}

.blog-post-body h2 {
  margin-top: 2.5rem;
  margin-bottom: 1.25rem;
}

.blog-post-tags-section {
  margin-top: 3rem;
  padding-top: 2rem;
  border-top: 1px solid #e2e8f0;
}

.blog-post-actions {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-top: 2rem;
  margin-bottom: 4rem;
}

/* Comments Section Redesign */
.blog-comments-section {
  margin-block: 5rem;
}

.blog-comments-section .app-page-header h3 {
  color: var(--navy-blue);
  letter-spacing: -0.03em;
  position: relative;
  display: inline-block;
  padding-bottom: 8px;
}

.blog-comments-section .app-page-header h3::after {
  content: "";
  position: absolute;
  bottom: 0;
  left: 0;
  width: 40px;
  height: 4px;
  background: var(--teal-brand);
  border-radius: 2px;
}

.blog-comment.glass-card {
  padding: 1.5rem;
  border-radius: 24px !important;
}

.blog-comment.border-start {
  border-left: 3px solid var(--glass-border) !important;
  border-top-left-radius: 0 !important;
  border-bottom-left-radius: 0 !important;
  background: rgba(255, 255, 255, 0.4);
}

.blog-comment:hover {
  border-color: var(--teal-brand) !important;
}

.blog-comment-text {
  font-size: 1rem;
  color: #4A5568 !important;
}

.blog-comment-replies {
  position: relative;
}

/* Form refinement */
.blog-comment-form .form-control:focus {
  background: white !important;
  box-shadow: 0 0 0 3px rgba(44, 122, 123, 0.1) !important;
  border: 1px solid var(--teal-brand) !important;
}

.border-dashed {
  border-style: dashed !important;
  border-width: 2px !important;
}

/* Response */
@media (max-width: 991.98px) {
  .blog-hero {
    padding: 6rem 0 4rem;
  }

  .blog-hero h1 {
    font-size: 2.5rem;
  }

  .blog-post-page {
    padding-top: 2rem;
  }

  .blog-post-header {
    min-height: 300px;
  }

  .blog-comments-section {
    padding: 1.5rem;
  }
}