/* blog-header.css - استایل‌های مخصوص هدر */
/* ===== متغیرهای CSS 2025 ===== */
:root {
  --primary-color: #4361ee;
  --primary-dark: #3a56d4;
  --primary-light: #5a75f0;
  --secondary-color: #7209b7;
  --accent-color: #f72585;
  --accent-light: #ff4da6;
  --text-color: #1a1a2e;
  --text-light: #4a4a6a;
  --text-lighter: #6c6c8a;
  --bg-color: #f8f9fa;
  --bg-light: #f1f3f9;
  --bg-lighter: #e9ecf8;
  --card-color: #ffffff;
  --border-color: #e2e8f0;
  --border-radius: 16px;
  --border-radius-lg: 24px;
  --box-shadow: 0 8px 30px rgba(67, 97, 238, 0.08);
  --box-shadow-hover: 0 15px 40px rgba(67, 97, 238, 0.15);
  --transition: all 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.1);
  --transition-fast: 0.2s ease;
  --font-family: 'Vazirmatn', 'B Nazanin', 'Segoe UI', Tahoma, Arial, sans-serif;
  
  /* متغیرهای اضافی */
  --header-bg: linear-gradient(135deg, #4361ee 0%, #7209b7 100%);
  --footer-bg: linear-gradient(135deg, #1a1a2e 0%, #2d2d44 100%);
  --footer-light: #3a3a5e;
  --highlight-link: #f72585;
  --glass-light: rgba(255, 255, 255, 0.25);
  --glass-border-light: rgba(255, 255, 255, 0.3);
  --glass-dark: rgba(0, 0, 0, 0.3);
  --glass-border-dark: rgba(255, 255, 255, 0.15);
  --container-max: 1200px;
}

/* ===== ریست و تنظیمات پایه ===== */
*,
*::before,
*::after {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

html {
  scroll-behavior: smooth;
  font-size: 16px;
  -webkit-text-size-adjust: 100%;
  text-size-adjust: none;
}

body {
  font-family: var(--font-family);
  line-height: 1.8;
  color: var(--text-color);
  background-color: var(--bg-color);
  overflow-x: hidden;
  direction: rtl;
  transition: background 0.3s ease, color 0.3s ease;
  -webkit-tap-highlight-color: transparent;
  width: 100%;
  max-width: 100%;
}

/* ===== بهبود اسکرول بار ===== */
::-webkit-scrollbar {
  width: 10px;
  height: 10px;
}

::-webkit-scrollbar-track {
  background: var(--bg-light);
  border-radius: 10px;
}

::-webkit-scrollbar-thumb {
  background: linear-gradient(135deg, var(--primary-color), var(--secondary-color));
  border-radius: 10px;
  border: 2px solid var(--bg-light);
}

::-webkit-scrollbar-thumb:hover {
  background: linear-gradient(135deg, var(--primary-dark), var(--secondary-color));
}

::-webkit-scrollbar-corner {
  background: var(--bg-light);
}

/* استایل برای مرورگرهای Firefox */
* {
  scrollbar-width: thin;
  scrollbar-color: var(--primary-color) var(--bg-light);
}

/* ===== هدر بهبود یافته ===== */
.blog-header {
  position: relative;
  background: var(--header-bg);
  color: white;
  padding: clamp(3rem, 8vw, 5rem) 2rem;
  text-align: center;
  overflow: hidden;
  margin-bottom: 3rem;
  border-radius: 0 0 var(--border-radius-lg) var(--border-radius-lg);
}

.blog-header .header-text {
  position: relative;
  z-index: 2;
  max-width: 800px;
  margin: 0 auto;
}

.blog-header h1 {
  color: white;
  font-size: clamp(2.2rem, 5vw, 3.5rem);
  margin-bottom: 1rem;
  text-shadow: 0 2px 10px rgba(0, 0, 0, 0.2);
  -webkit-text-fill-color: white;
  background: none;
}

.blog-header .subtitle {
  font-size: clamp(1rem, 2vw, 1.25rem);
  opacity: 0.95;
  max-width: 800px;
  margin: 0 auto 2rem;
  font-weight: 400;
  line-height: 1.6;
}

.header-stats {
  display: flex;
  justify-content: center;
  gap: 1.5rem;
  flex-wrap: wrap;
  margin-top: 2rem;
}

.stat-item {
  background: rgba(255, 255, 255, 0.15);
  padding: 10px 24px;
  border-radius: 30px;
  font-weight: 600;
  backdrop-filter: blur(10px);
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 0.95rem;
}

.header-video-wrapper {
  position: absolute;
  top: 0;
  right: 0;
  bottom: 0;
  left: 0;
  overflow: hidden;
  z-index: 1;
}

.header-video {
  width: 100%;
  height: 100%;
  object-fit: cover;
  opacity: 0.25;
  filter: brightness(0.7);
}

.header-link {
  position: relative;
  z-index: 2;
  margin-top: 2rem;
}

.site-link {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  background: rgba(255, 255, 255, 0.2);
  color: white;
  padding: 14px 32px;
  border-radius: 30px;
  font-weight: 600;
  text-decoration: none;
  transition: var(--transition);
  backdrop-filter: blur(10px);
  border: 1px solid rgba(255, 255, 255, 0.3);
}

.site-link:hover {
  background: rgba(255, 255, 255, 0.3);
  transform: translateY(-3px);
  box-shadow: 0 10px 25px rgba(0, 0, 0, 0.2);
}

/* ===== حالت تاریک برای هدر ===== */
body.dark-mode .blog-header {
  background: linear-gradient(135deg, #1a1a2e 0%, #252547 100%);
}

body.dark-mode .blog-header h1,
body.dark-mode .blog-header .subtitle {
  color: #e2e8f0;
  -webkit-text-fill-color: #e2e8f0;
}

/* ===== ریسپانسیو برای هدر ===== */
@media (max-width: 768px) {
  .blog-header {
    padding: 2.5rem 1.5rem;
  }
  
  .blog-header h1 {
    font-size: 2.2rem;
  }
  
  .header-stats {
    flex-direction: column;
    gap: 1rem;
  }
}

@media (max-width: 480px) {
  .blog-header {
    padding: 2rem 1rem;
  }
  
  .blog-header h1 {
    font-size: 1.6rem;
  }
  
  .header-stats .stat-item {
    padding: 8px 16px;
    font-size: 0.9rem;
  }
}