/* ==========================================================================
   Blog & Article Pages Stylesheet
   Byteware Solutions - Modern, Clean Blog Design
   ========================================================================== */

/* --------------------------------------------------------------------------
   CSS Variables - Brand Colors & Spacing System
   -------------------------------------------------------------------------- */
:root {
  /* Brand Colors */
  --brand-primary: #169fe6;
  --brand-secondary: #42b3ed;
  
  /* Text Colors */
  --text-dark: #333;
  --text-body: #444;
  --text-light: #666;
  --text-white: #fff;
  
  /* Background Colors */
  --bg-light: #f8f9fa;
  --bg-white: #fff;
  --bg-dark: #3D5866;
  
  /* Spacing System */
  --space-xs: 0.5rem;   /* 8px */
  --space-sm: 1rem;     /* 16px */
  --space-md: 1.5rem;   /* 24px */
  --space-lg: 3rem;     /* 48px */
  --space-xl: 4rem;     /* 64px */
  
  /* Typography */
  --font-base: 1rem;
  --font-lg: 1.125rem;  /* 18px */
  --line-height-base: 1.6;
  --line-height-relaxed: 1.75;
  
  /* Transitions */
  --transition-base: 0.3s ease;
}

/* --------------------------------------------------------------------------
   Blog Hero Section
   -------------------------------------------------------------------------- */
.blog-hero {
  background: linear-gradient(135deg, #169fe6 0%, #42b3ed 100%);
  color: white;
  padding: var(--space-xl) 0;
  text-align: center;
  margin-bottom: var(--space-lg);
}

.blog-hero h1 {
  color: white;
  margin-bottom: var(--space-md);
  font-size: clamp(2rem, 5vw, 3rem);
  font-weight: 300;
  line-height: 1.2;
}

.blog-hero p {
  color: rgba(255, 255, 255, 0.95);
  font-size: clamp(1rem, 2vw, 1.2rem);
  max-width: 700px;
  margin: 0 auto;
}

/* --------------------------------------------------------------------------
   Blog Sidebar Widgets
   -------------------------------------------------------------------------- */
.blog-sidebar-widget {
  background: var(--bg-white);
  border-radius: 8px;
  padding: var(--space-md);
  margin-bottom: var(--space-md);
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
}

.blog-sidebar-widget h4 {
  font-size: 1.125rem;
  color: var(--text-dark);
  margin-bottom: var(--space-sm);
  font-weight: 600;
}

.blog-sidebar-widget input[type="text"] {
  width: 100%;
  padding: 0.75rem var(--space-sm);
  border: 1px solid #ddd;
  border-radius: 6px;
  font-size: 0.95rem;
  transition: var(--transition-base);
}

.blog-sidebar-widget input[type="text"]:focus {
  outline: none;
  border-color: var(--brand-primary);
  box-shadow: 0 0 0 3px rgba(22, 159, 230, 0.1);
}

/* Category Filter List in Sidebar */
.category-filter-list {
  list-style: none;
  margin: 0;
  padding: 0;
}

.category-filter-list li {
  margin-bottom: var(--space-xs);
}

.category-filter-list a {
  display: block;
  padding: 0.625rem var(--space-sm);
  color: var(--text-body);
  text-decoration: none;
  border-radius: 6px;
  transition: var(--transition-base);
  font-size: 0.95rem;
}

.category-filter-list a:hover {
  background: var(--bg-light);
  color: var(--brand-primary);
  padding-left: 1.25rem;
}

.category-filter-list a.active {
  background: var(--brand-primary);
  color: white;
  font-weight: 500;
}

/* --------------------------------------------------------------------------
   Featured Post Card
   -------------------------------------------------------------------------- */
.featured-post {
  background: var(--bg-white);
  border-radius: 10px;
  overflow: hidden;
  margin-bottom: var(--space-lg);
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.1);
  transition: var(--transition-base);
}

.featured-post:hover {
  transform: translateY(-4px);
  box-shadow: 0 8px 30px rgba(0, 0, 0, 0.15);
}

.featured-post img {
  width: 100%;
  height: 350px;
  object-fit: cover;
  display: block;
}

.featured-content {
  padding: var(--space-lg);
}

.featured-tag {
  background: var(--brand-primary);
  color: white;
  padding: 0.375rem var(--space-sm);
  border-radius: 20px;
  font-size: 0.8125rem;
  font-weight: 500;
  display: inline-block;
  margin-bottom: var(--space-sm);
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.featured-content h2 {
  margin: var(--space-sm) 0 var(--space-md);
  font-size: 1.875rem;
  line-height: 1.3;
}

.featured-content h2 a {
  color: var(--text-dark);
  text-decoration: none;
  transition: var(--transition-base);
}

.featured-content h2 a:hover {
  color: var(--brand-primary);
}

.featured-content p {
  color: var(--text-body);
  line-height: var(--line-height-relaxed);
  margin-bottom: var(--space-md);
  font-size: 1.0625rem;
}

.featured-content .button {
  margin-top: var(--space-sm);
}

/* --------------------------------------------------------------------------
   Article Header (Full-Width with Overlay)
   -------------------------------------------------------------------------- */
.article-header {
  background: linear-gradient(135deg, rgba(22, 159, 230, 0.92) 0%, rgba(66, 179, 237, 0.92) 100%), 
              url('../img/bg-parallax1.png');
  background-size: cover;
  background-position: center;
  color: white;
  padding: var(--space-xl) 0;
  text-align: center;
  margin-bottom: var(--space-xl);
  position: relative;
}

.article-header-content {
  max-width: 900px;
  margin: 0 auto;
  padding: 0 var(--space-md);
}

.article-category-tag {
  background: rgba(255, 255, 255, 0.25);
  color: white;
  padding: 0.5rem 1.25rem;
  border-radius: 25px;
  font-size: 0.875rem;
  font-weight: 500;
  display: inline-block;
  margin-bottom: var(--space-md);
  text-transform: uppercase;
  letter-spacing: 1px;
  backdrop-filter: blur(10px);
}

.article-header h1 {
  color: white;
  margin-bottom: var(--space-md);
  font-size: clamp(1.875rem, 4vw, 2.75rem);
  line-height: 1.2;
  font-weight: 300;
  text-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}

.article-meta {
  color: rgba(255, 255, 255, 0.95);
  font-size: 1rem;
  margin-bottom: var(--space-md);
  display: flex;
  justify-content: center;
  align-items: center;
  flex-wrap: wrap;
  gap: var(--space-xs);
}

.article-meta a {
  color: rgba(255, 255, 255, 0.95);
  text-decoration: none;
  transition: var(--transition-base);
}

.article-meta a:hover {
  color: white;
  text-decoration: underline;
}

.meta-separator {
  margin: 0 0.5rem;
  opacity: 0.7;
}

/* --------------------------------------------------------------------------
   Article Container (Full-Width Layout)
   -------------------------------------------------------------------------- */
.article-container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 var(--space-md);
}

/* --------------------------------------------------------------------------
   Article Content (Centered, Optimal Reading Width)
   -------------------------------------------------------------------------- */
.article-content {
  max-width: 750px;
  margin: 0 auto var(--space-xl);
  font-size: var(--font-lg);
  line-height: var(--line-height-relaxed);
  color: var(--text-body);
}

.article-content .lead {
  font-size: 1.25rem;
  line-height: 1.7;
  color: var(--text-body);
  margin-bottom: var(--space-lg);
  font-weight: 300;
}

.article-content h2 {
  color: var(--brand-primary);
  margin-top: var(--space-lg);
  margin-bottom: var(--space-md);
  font-size: 2rem;
  line-height: 1.3;
  font-weight: 400;
}

.article-content h3 {
  color: var(--text-dark);
  margin-top: var(--space-lg);
  margin-bottom: var(--space-sm);
  font-size: 1.5rem;
  line-height: 1.4;
  font-weight: 500;
}

.article-content h4 {
  color: var(--text-body);
  margin-top: var(--space-md);
  margin-bottom: var(--space-sm);
  font-size: 1.25rem;
  line-height: 1.4;
  font-weight: 600;
}

.article-content p {
  margin-bottom: var(--space-md);
  line-height: var(--line-height-relaxed);
}

.article-content blockquote {
  background: var(--bg-light);
  border-left: 4px solid var(--brand-primary);
  margin: var(--space-lg) 0;
  padding: var(--space-md) var(--space-lg);
  font-style: italic;
  font-size: 1.0625rem;
  color: var(--text-body);
  border-radius: 0 8px 8px 0;
}

.article-content blockquote p:last-child {
  margin-bottom: 0;
}

.article-content ul,
.article-content ol {
  margin-bottom: var(--space-md);
  padding-left: 2rem;
  line-height: var(--line-height-relaxed);
}

.article-content li {
  margin-bottom: 0.75rem;
}

.article-content li strong {
  color: var(--text-dark);
  font-weight: 600;
}

.article-content img {
  max-width: 100%;
  height: auto;
  border-radius: 8px;
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
  margin: var(--space-lg) 0;
}

.article-content a {
  color: var(--brand-primary);
  text-decoration: underline;
  transition: var(--transition-base);
}

.article-content a:hover {
  color: var(--brand-secondary);
}

/* --------------------------------------------------------------------------
   Article Image Component
   -------------------------------------------------------------------------- */
.article-image {
  margin: var(--space-lg) 0;
  text-align: center;
}

.article-image img {
  max-width: 100%;
  height: auto;
  border-radius: 8px;
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
}

.article-image-caption {
  font-size: 0.9375rem;
  color: var(--text-light);
  margin-top: var(--space-sm);
  font-style: italic;
}

/* --------------------------------------------------------------------------
   Acronym List (Special Component for Acronym Article)
   -------------------------------------------------------------------------- */
.acronym-list {
  background: var(--bg-light);
  border-radius: 8px;
  padding: var(--space-md);
  margin: var(--space-md) 0;
}

.acronym-item {
  margin-bottom: var(--space-lg);
  padding-bottom: var(--space-md);
  border-bottom: 1px solid #e0e0e0;
}

.acronym-item:last-child {
  border-bottom: none;
  margin-bottom: 0;
  padding-bottom: 0;
}

.acronym-term {
  font-weight: 700;
  color: var(--brand-primary);
  font-size: 1.125rem;
  margin-bottom: 0.5rem;
  display: block;
}

.acronym-description {
  margin-top: var(--space-sm);
  padding-left: var(--space-md);
}

.acronym-description p {
  margin-bottom: var(--space-sm);
}

/* --------------------------------------------------------------------------
   Article Tags
   -------------------------------------------------------------------------- */
.article-tags {
  max-width: 750px;
  margin: var(--space-xl) auto;
  padding: var(--space-md) 0;
  border-top: 1px solid #eee;
  border-bottom: 1px solid #eee;
}

.article-tags strong {
  color: var(--text-dark);
  margin-right: var(--space-sm);
  font-weight: 600;
}

.article-tags a {
  background: var(--bg-light);
  color: var(--brand-primary);
  padding: 0.5rem var(--space-sm);
  border-radius: 20px;
  font-size: 0.9375rem;
  margin: 0.375rem 0.375rem 0.375rem 0;
  display: inline-block;
  text-decoration: none;
  transition: var(--transition-base);
  border: 1px solid transparent;
}

.article-tags a:hover {
  background: var(--brand-primary);
  color: white;
  border-color: var(--brand-primary);
  transform: translateY(-2px);
  box-shadow: 0 4px 8px rgba(22, 159, 230, 0.2);
}

/* --------------------------------------------------------------------------
   Social Share Buttons
   -------------------------------------------------------------------------- */
.article-share {
  max-width: 750px;
  margin: var(--space-lg) auto;
  text-align: center;
}

.article-share h4 {
  margin-bottom: var(--space-md);
  color: var(--text-dark);
  font-size: 1.125rem;
  font-weight: 600;
}

.share-buttons {
  display: flex;
  justify-content: center;
  gap: var(--space-sm);
  flex-wrap: wrap;
}

.share-buttons a {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 48px;
  height: 48px;
  border-radius: 50%;
  color: white;
  font-size: 1.25rem;
  text-decoration: none;
  transition: var(--transition-base);
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.15);
}

.share-buttons a:hover {
  transform: translateY(-3px);
  box-shadow: 0 6px 16px rgba(0, 0, 0, 0.25);
}

.share-twitter {
  background: #1da1f2;
}

.share-linkedin {
  background: #0077b5;
}

.share-facebook {
  background: #3b5998;
}

.share-email {
  background: #666;
}

/* --------------------------------------------------------------------------
   Author Bio
   -------------------------------------------------------------------------- */
.blog-author,
.article-author-bio {
  max-width: 750px;
  margin: var(--space-xl) auto;
  background: var(--bg-light);
  border-radius: 12px;
  padding: var(--space-lg);
  display: flex;
  gap: var(--space-md);
  align-items: flex-start;
  box-shadow: 0 2px 12px rgba(0, 0, 0, 0.08);
}

.blog-author img,
.article-author-bio img {
  width: 80px;
  height: 80px;
  border-radius: 50%;
  object-fit: cover;
  flex-shrink: 0;
}

.author-description {
  flex: 1;
}

.author-description h4 {
  margin: 0 0 var(--space-sm);
  color: var(--text-dark);
  font-size: 1.25rem;
  font-weight: 600;
}

.author-description p {
  margin-bottom: var(--space-sm);
  color: var(--text-body);
  line-height: var(--line-height-relaxed);
  font-size: 0.9375rem;
}

.author-link {
  color: var(--brand-primary);
  text-decoration: none;
  font-weight: 500;
  transition: var(--transition-base);
  display: inline-block;
}

.author-link:hover {
  color: var(--brand-secondary);
  text-decoration: underline;
}

/* --------------------------------------------------------------------------
   Related Articles Section
   -------------------------------------------------------------------------- */
.related-articles {
  background: var(--bg-light);
  padding: var(--space-xl) 0;
  margin-top: var(--space-xl);
}

.related-articles h3 {
  text-align: center;
  margin-bottom: var(--space-xl);
  color: var(--text-dark);
  font-size: 2rem;
  font-weight: 300;
}

.related-article-item {
  background: white;
  border-radius: 8px;
  overflow: hidden;
  margin-bottom: var(--space-md);
  box-shadow: 0 2px 12px rgba(0, 0, 0, 0.08);
  transition: var(--transition-base);
  height: 100%;
  display: flex;
  flex-direction: column;
}

.related-article-item:hover {
  transform: translateY(-4px);
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.15);
}

.related-article-item img {
  width: 100%;
  height: 200px;
  object-fit: cover;
  display: block;
}

.related-article-content {
  padding: var(--space-md);
  flex: 1;
  display: flex;
  flex-direction: column;
}

.related-article-content h4 {
  margin-bottom: var(--space-sm);
  font-size: 1.125rem;
  line-height: 1.4;
  flex: 1;
}

.related-article-content h4 a {
  color: var(--text-dark);
  text-decoration: none;
  transition: var(--transition-base);
}

.related-article-content h4 a:hover {
  color: var(--brand-primary);
}

.related-article-content p {
  color: var(--text-light);
  font-size: 0.9375rem;
  margin-bottom: var(--space-sm);
  line-height: 1.6;
}

.related-article-content small {
  color: var(--text-light);
  font-size: 0.875rem;
  display: block;
  margin-top: auto;
}

/* --------------------------------------------------------------------------
   Pagination
   -------------------------------------------------------------------------- */
.pagination-container {
  margin: var(--space-lg) 0;
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: var(--space-md);
}

.pagination-container span {
  color: var(--text-light);
  font-size: 0.9375rem;
}

.pagination {
  list-style: none;
  display: flex;
  gap: 0.5rem;
  margin: 0;
  padding: 0;
}

.pagination li a {
  display: block;
  padding: 0.5rem 0.875rem;
  background: var(--bg-white);
  color: var(--text-body);
  text-decoration: none;
  border-radius: 6px;
  border: 1px solid #ddd;
  transition: var(--transition-base);
}

.pagination li a:hover {
  background: var(--brand-primary);
  color: white;
  border-color: var(--brand-primary);
}

.pagination li.active a {
  background: var(--brand-primary);
  color: white;
  border-color: var(--brand-primary);
  font-weight: 600;
}

/* --------------------------------------------------------------------------
   Mobile Responsive Styles
   -------------------------------------------------------------------------- */
@media (max-width: 768px) {
  :root {
    --space-xl: 2.5rem;
    --space-lg: 2rem;
  }
  
  .blog-hero {
    padding: var(--space-lg) var(--space-sm);
  }
  
  .blog-hero h1 {
    font-size: 2rem;
  }
  
  .blog-hero p {
    font-size: 1rem;
  }
  
  .article-header {
    padding: var(--space-lg) var(--space-sm);
  }
  
  .article-header h1 {
    font-size: 1.875rem;
  }
  
  .article-meta {
    font-size: 0.9375rem;
    flex-direction: column;
    gap: 0.25rem;
  }
  
  .meta-separator {
    display: none;
  }
  
  .article-content {
    font-size: 1rem;
    line-height: 1.7;
  }
  
  .article-content h2 {
    font-size: 1.5rem;
    margin-top: var(--space-md);
  }
  
  .article-content h3 {
    font-size: 1.25rem;
  }
  
  .article-content h4 {
    font-size: 1.125rem;
  }
  
  .featured-post img {
    height: 220px;
  }
  
  .featured-content {
    padding: var(--space-md);
  }
  
  .featured-content h2 {
    font-size: 1.5rem;
  }
  
  .blog-author,
  .article-author-bio {
    flex-direction: column;
    text-align: center;
    align-items: center;
  }
  
  .related-article-item img {
    height: 180px;
  }
  
  .pagination-container {
    flex-direction: column;
    text-align: center;
  }
}

/* --------------------------------------------------------------------------
   Print Styles
   -------------------------------------------------------------------------- */
@media print {
  .article-header,
  .article-share,
  .related-articles,
  .blog-hero {
    display: none;
  }
  
  .article-content {
    max-width: 100%;
    font-size: 12pt;
    line-height: 1.5;
    color: #000;
  }
  
  .article-content a {
    color: #000;
    text-decoration: underline;
  }
}

