/* ==========================================================================
   ATLAS YAHYA TRADING - BLOG & KNOWLEDGE BASE STYLESHEET
   Clean, Modern, Editorial, Responsive and SEO-Friendly
   ========================================================================== */

/* Reading progress bar */
#reading-progress-bar {
  position: fixed;
  top: 0;
  left: 0;
  width: 0%;
  height: 4px;
  background: linear-gradient(90deg, #9B5CB2, #6D48A7, #38bdf8);
  z-index: 9999;
  transition: width 0.1s ease-out;
  box-shadow: 0 0 10px rgba(155, 92, 178, 0.6);
}

/* Category Pills & Filter */
.blog-cat-pill {
  padding: 8px 18px;
  border-radius: 50px;
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid rgba(255, 255, 255, 0.12);
  color: var(--text-muted, #A89FC0);
  font-size: 13.5px;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.25s ease;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  text-decoration: none;
}
.blog-cat-pill:hover,
.blog-cat-pill.active {
  background: linear-gradient(135deg, rgba(155, 92, 178, 0.25), rgba(109, 72, 167, 0.35));
  border-color: #9B5CB2;
  color: #ffffff;
  box-shadow: 0 4px 15px rgba(155, 92, 178, 0.3);
  transform: translateY(-2px);
}

/* Blog Cards */
.blog-card {
  background: rgba(26, 20, 61, 0.7);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 18px;
  overflow: hidden;
  transition: all 0.35s cubic-bezier(0.16, 1, 0.3, 1);
  display: flex;
  flex-direction: column;
  height: 100%;
}
.blog-card:hover {
  transform: translateY(-6px);
  border-color: rgba(155, 92, 178, 0.5);
  box-shadow: 0 16px 36px rgba(13, 9, 36, 0.6), 0 0 25px rgba(155, 92, 178, 0.25);
}

.blog-card-thumb-wrap {
  position: relative;
  width: 100%;
  aspect-ratio: 16 / 9;
  overflow: hidden;
}
.blog-card-thumb {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.5s ease;
}
.blog-card:hover .blog-card-thumb {
  transform: scale(1.06);
}

.blog-badge {
  position: absolute;
  top: 14px;
  left: 14px;
  padding: 5px 12px;
  border-radius: 30px;
  font-size: 11.5px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  backdrop-filter: blur(8px);
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.3);
}
.badge-education { background: rgba(16, 185, 129, 0.9); color: #fff; }
.badge-business { background: rgba(56, 189, 248, 0.9); color: #042f2e; }
.badge-guide { background: rgba(245, 158, 11, 0.9); color: #451a03; }
.badge-tech { background: rgba(155, 92, 178, 0.9); color: #fff; }

.blog-card-body {
  padding: 24px;
  display: flex;
  flex-direction: column;
  flex-grow: 1;
}
.blog-meta-row {
  display: flex;
  align-items: center;
  gap: 14px;
  font-size: 12.5px;
  color: var(--text-dim, #73698C);
  margin-bottom: 12px;
}
.blog-meta-row span {
  display: inline-flex;
  align-items: center;
  gap: 5px;
}
.blog-card-title {
  font-size: 19px;
  font-weight: 700;
  line-height: 1.4;
  color: #ffffff;
  margin-bottom: 12px;
  transition: color 0.2s ease;
}
.blog-card:hover .blog-card-title {
  color: #c084fc;
}
.blog-card-excerpt {
  font-size: 14px;
  line-height: 1.6;
  color: var(--text-muted, #A89FC0);
  margin-bottom: 20px;
  flex-grow: 1;
}
.blog-read-more-link {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 13.5px;
  font-weight: 700;
  color: #9B5CB2;
  text-decoration: none;
  transition: gap 0.2s ease, color 0.2s ease;
  margin-top: auto;
}
.blog-read-more-link:hover {
  color: #d8b4fe;
  gap: 10px;
}

/* Featured Hero Article Card */
.featured-article-card {
  background: linear-gradient(135deg, rgba(42, 28, 88, 0.85) 0%, rgba(20, 14, 48, 0.9) 100%);
  border: 1px solid rgba(155, 92, 178, 0.4);
  border-radius: 22px;
  overflow: hidden;
  box-shadow: 0 20px 50px rgba(13, 9, 36, 0.7), 0 0 35px rgba(155, 92, 178, 0.2);
  margin-bottom: 45px;
}
.featured-article-card .blog-card-thumb-wrap {
  aspect-ratio: 16 / 10;
  height: 100%;
  min-height: 280px;
}

/* Single Article Layout */
.article-header {
  margin-bottom: 40px;
  text-align: center;
}
.article-title {
  font-size: clamp(28px, 4vw, 44px);
  font-weight: 800;
  line-height: 1.25;
  color: #ffffff;
  margin-top: 15px;
  margin-bottom: 20px;
}
.article-lead {
  font-size: 18px;
  line-height: 1.65;
  color: #cbd5e1;
  max-width: 820px;
  margin: 0 auto 25px auto;
}
.article-author-bar {
  display: inline-flex;
  align-items: center;
  gap: 16px;
  padding: 8px 20px;
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 50px;
  font-size: 13px;
  color: var(--text-muted, #A89FC0);
}
.author-avatar {
  width: 32px;
  height: 32px;
  border-radius: 50%;
  border: 2px solid #9B5CB2;
  object-fit: cover;
}

/* Article Hero Image */
.article-hero-wrap {
  width: 100%;
  max-height: 480px;
  border-radius: 20px;
  overflow: hidden;
  margin-bottom: 45px;
  box-shadow: 0 15px 40px rgba(0, 0, 0, 0.5);
  border: 1px solid rgba(255, 255, 255, 0.08);
}
.article-hero-img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

/* Article Body Content */
.article-content {
  font-size: 16.5px;
  line-height: 1.8;
  color: #e2e8f0;
}
.article-content p {
  margin-bottom: 24px;
}
.article-content h2 {
  font-size: 27px;
  font-weight: 800;
  color: #ffffff;
  margin-top: 48px;
  margin-bottom: 20px;
  padding-bottom: 12px;
  border-bottom: 1px solid rgba(155, 92, 178, 0.25);
  display: flex;
  align-items: center;
  gap: 12px;
}
.article-content h3 {
  font-size: 21px;
  font-weight: 700;
  color: #c084fc;
  margin-top: 32px;
  margin-bottom: 14px;
}
.article-content ul, .article-content ol {
  margin-bottom: 24px;
  padding-left: 24px;
}
.article-content li {
  margin-bottom: 10px;
}

/* Key Takeaway Card */
.key-takeaway-box {
  background: linear-gradient(135deg, rgba(155, 92, 178, 0.12), rgba(42, 28, 88, 0.3));
  border-left: 4px solid #9B5CB2;
  border-radius: 0 14px 14px 0;
  padding: 22px 26px;
  margin: 32px 0;
}
.key-takeaway-title {
  font-size: 16px;
  font-weight: 800;
  color: #c084fc;
  margin-bottom: 10px;
  display: flex;
  align-items: center;
  gap: 8px;
}

/* Pro Tip Callout */
.pro-tip-box {
  background: linear-gradient(135deg, rgba(16, 185, 129, 0.1), rgba(6, 78, 59, 0.25));
  border-left: 4px solid #10B981;
  border-radius: 0 14px 14px 0;
  padding: 22px 26px;
  margin: 32px 0;
}
.pro-tip-title {
  font-size: 16px;
  font-weight: 800;
  color: #34d399;
  margin-bottom: 10px;
  display: flex;
  align-items: center;
  gap: 8px;
}

/* Comparison Table */
.article-table-wrap {
  overflow-x: auto;
  margin: 32px 0;
  border-radius: 14px;
  border: 1px solid rgba(255, 255, 255, 0.1);
}
.article-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 14.5px;
}
.article-table th {
  background: rgba(42, 28, 88, 0.7);
  color: #ffffff;
  padding: 14px 18px;
  text-align: left;
  font-weight: 700;
  border-bottom: 2px solid rgba(155, 92, 178, 0.5);
}
.article-table td {
  padding: 12px 18px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.06);
  color: #cbd5e1;
}
.article-table tr:hover td {
  background: rgba(255, 255, 255, 0.03);
}

/* Table of Contents (Sommaire) */
.toc-card {
  background: rgba(26, 20, 61, 0.75);
  border: 1px solid rgba(155, 92, 178, 0.3);
  border-radius: 16px;
  padding: 24px;
  position: sticky;
  top: 90px;
}
.toc-title {
  font-size: 16px;
  font-weight: 800;
  color: #ffffff;
  margin-bottom: 16px;
  display: flex;
  align-items: center;
  gap: 8px;
}
.toc-links {
  list-style: none;
  padding-left: 0;
  margin: 0;
}
.toc-links li {
  margin-bottom: 10px;
}
.toc-links a {
  color: var(--text-muted, #A89FC0);
  text-decoration: none;
  font-size: 13.5px;
  line-height: 1.4;
  display: block;
  transition: all 0.2s ease;
}
.toc-links a:hover {
  color: #c084fc;
  padding-left: 6px;
}

/* Author Box at End of Article */
.author-end-box {
  background: rgba(26, 20, 61, 0.6);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 18px;
  padding: 28px;
  display: flex;
  align-items: center;
  gap: 22px;
  margin-top: 50px;
}
.author-end-avatar {
  width: 72px;
  height: 72px;
  border-radius: 50%;
  border: 3px solid #9B5CB2;
  object-fit: cover;
  flex-shrink: 0;
}

/* Share Buttons */
.share-bar {
  display: flex;
  align-items: center;
  gap: 10px;
  margin: 30px 0;
}
.share-btn {
  width: 38px;
  height: 38px;
  border-radius: 50%;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background: rgba(255, 255, 255, 0.06);
  border: 1px solid rgba(255, 255, 255, 0.1);
  color: #ffffff;
  transition: all 0.2s ease;
  text-decoration: none;
}
.share-btn:hover {
  transform: translateY(-2px);
  background: #9B5CB2;
  color: #fff;
}

/* ==========================================================================
   ULTRA-HD 3.2K (3200x1800) 16:9 WIDESCREEN RETINA IMAGE ADAPTATION
   ========================================================================== */
.blog-card-thumb-wrap {
  aspect-ratio: 16 / 9 !important;
  background: #0A061C;
}
.blog-card-thumb {
  width: 100% !important;
  height: 100% !important;
  aspect-ratio: 16 / 9 !important;
  object-fit: cover !important;
  object-position: center center !important;
  image-rendering: -webkit-optimize-contrast;
}
.article-hero-wrap {
  width: 100% !important;
  aspect-ratio: 16 / 9 !important;
  max-height: none !important;
  background: #0A061C;
  border-radius: 20px;
  overflow: hidden;
}
.article-hero-img {
  width: 100% !important;
  height: auto !important;
  aspect-ratio: 16 / 9 !important;
  object-fit: cover !important;
  image-rendering: -webkit-optimize-contrast;
  display: block;
}
