/**
 * Blog Styles - Archive & Single Post
 * Modern, professional design following Foxentrade design system
 * @package Foxentrade
 * @version 1.0.0
 */

/* ============================================ */
/* ARCHIVE PAGE - Blog Listing                 */
/* ============================================ */

.blog-archive {
  background: linear-gradient(180deg, #f8f9fb 0%, #ffffff 100%);
  min-height: 100vh;
}

/* Blog Header */
.blog-header {
  position: relative;
  padding: 120px 20px 60px;
  text-align: center;
  overflow: hidden;
}

.blog-header::before {
  content: '';
  position: absolute;
  top: -10px;
  left: -10px;
  right: -10px;
  bottom: -10px;
  background-image: url('../assets/images/hero-noticias-bg.jpg');
  background-size: cover;
  background-position: center;
  background-repeat: no-repeat;
  filter: blur(2px);
  z-index: 0;
}

.blog-header::after {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: rgba(0, 0, 0, 0.4);
  z-index: 1;
}

.blog-header-content {
  max-width: 800px;
  margin: 0 auto;
  position: relative;
  z-index: 10;
}

.blog-header h1 {
  font-size: 64px;
  font-weight: 700;
  color: var(--color-white);
  margin-bottom: var(--space-6);
  line-height: var(--line-height-tight);
  letter-spacing: var(--letter-spacing-tight);
}

.blog-header-description {
  font-size: 20px;
  line-height: var(--line-height-relaxed);
  color: rgba(255, 255, 255, 0.9);
  max-width: 600px;
  margin: 0 auto;
}

/* Posts Grid */
.posts-container {
  max-width: var(--container-max-width);
  margin: 0 auto;
  padding: 80px 20px;
}

.posts-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(380px, 1fr));
  gap: 40px;
  margin-bottom: 80px;
}

/* Post Card */
.post-card {
  background: var(--color-white);
  border-radius: 0;
  overflow: hidden;
  transition: var(--transition-base);
  border: 1px solid rgba(0, 0, 0, 0.06);
  position: relative;
  display: flex;
  flex-direction: column;
  height: 100%;
}

.post-card::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: linear-gradient(135deg, var(--color-primary) 0%, var(--color-accent-green) 100%);
  opacity: 0;
  transition: var(--transition-base);
  z-index: 0;
  border-radius: 0;
}

.post-card:hover {
  transform: translateY(-8px);
  box-shadow: 0 20px 40px rgba(4, 120, 178, 0.15);
}

.post-card:hover::before {
  opacity: 0.03;
}

/* Post Thumbnail */
.post-thumbnail {
  position: relative;
  height: 260px;
  overflow: hidden;
  background: linear-gradient(135deg, #f0f0f0 0%, #e5e5e5 100%);
  border-radius: 0 !important;
}

.post-thumbnail::after {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: linear-gradient(180deg, transparent 0%, rgba(0, 0, 0, 0.3) 100%);
  opacity: 0;
  transition: var(--transition-base);
}

.post-card:hover .post-thumbnail::after {
  opacity: 1;
}

.post-thumbnail a {
  display: block;
  height: 100%;
  position: relative;
  z-index: 1;
}

.post-thumbnail img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.6s ease;
}

.post-card:hover .post-thumbnail img {
  transform: scale(1.08);
}

/* Reading Time Badge */
.reading-time {
  position: absolute;
  top: 16px;
  right: 16px;
  background: rgba(0, 0, 0, 0.7);
  backdrop-filter: blur(10px);
  color: var(--color-white);
  padding: 8px 14px;
  border-radius: var(--border-radius-pill);
  font-size: var(--font-size-sm);
  font-weight: var(--font-weight-semibold);
  z-index: 2;
  display: flex;
  align-items: center;
  gap: 6px;
}

/* Post Content */
.post-content {
  padding: 32px;
  display: flex;
  flex-direction: column;
  flex-grow: 1;
  position: relative;
  z-index: 1;
}

/* Categories */
.post-categories {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 16px;
}

.post-category {
  display: inline-flex;
  align-items: center;
  padding: 6px 14px;
  background: linear-gradient(135deg, var(--color-primary), var(--color-primary-dark));
  color: var(--color-white);
  border-radius: var(--border-radius-pill);
  font-size: var(--font-size-xs);
  font-weight: var(--font-weight-semibold);
  text-transform: uppercase;
  letter-spacing: 0.5px;
  transition: var(--transition-base);
  text-decoration: none;
}

.post-category:hover {
  transform: translateY(-2px);
  box-shadow: 0 4px 12px rgba(4, 120, 178, 0.3);
}

/* Post Title */
.post-title {
  font-size: 26px;
  font-weight: 700;
  line-height: var(--line-height-snug);
  margin-bottom: 16px;
  color: var(--color-text-primary);
}

.post-title a {
  color: inherit;
  text-decoration: none;
  transition: var(--transition-base);
  display: block;
}

.post-card:hover .post-title a {
  color: var(--color-primary);
}

/* Post Meta */
.post-meta {
  display: flex;
  align-items: center;
  gap: 16px;
  margin-bottom: 16px;
  font-size: var(--font-size-sm);
  color: rgba(0, 70, 86, 0.6);
}

.post-meta-item {
  display: flex;
  align-items: center;
  gap: 6px;
}

.post-meta-item i {
  font-size: 14px;
  opacity: 0.7;
}

.post-meta-author {
  font-weight: var(--font-weight-semibold);
  color: var(--color-text-primary);
}

/* Post Excerpt */
.post-excerpt {
  font-size: 16px;
  line-height: var(--line-height-relaxed);
  color: rgba(0, 70, 86, 0.75);
  margin-bottom: 24px;
  flex-grow: 1;
  display: -webkit-box;
  -webkit-line-clamp: 3;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

/* Read More Button */
.read-more {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  color: var(--color-primary);
  font-weight: var(--font-weight-semibold);
  font-size: 15px;
  text-decoration: none;
  transition: var(--transition-base);
  position: relative;
  padding-bottom: 2px;
  border-bottom: 2px solid transparent;
}

.read-more::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 0;
  width: 0;
  height: 2px;
  background: var(--color-accent-green);
  transition: width var(--transition-base);
}

.read-more:hover::after {
  width: 100%;
}

.read-more i {
  transition: transform var(--transition-base);
}

.read-more:hover i {
  transform: translateX(5px);
}

/* Pagination */
.blog-pagination {
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 12px;
  margin-top: 60px;
}

.blog-pagination .nav-links {
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
  justify-content: center;
}

.blog-pagination .page-numbers {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 48px;
  height: 48px;
  padding: 0 16px;
  background: var(--color-white);
  color: var(--color-text-primary);
  text-decoration: none;
  border-radius: var(--border-radius-md);
  border: 1px solid rgba(0, 0, 0, 0.08);
  font-weight: var(--font-weight-semibold);
  font-size: 15px;
  transition: var(--transition-base);
}

.blog-pagination .page-numbers:hover {
  background: var(--color-primary);
  color: var(--color-white);
  border-color: var(--color-primary);
  transform: translateY(-2px);
  box-shadow: 0 4px 12px rgba(4, 120, 178, 0.25);
}

.blog-pagination .page-numbers.current {
  background: linear-gradient(135deg, var(--color-primary), var(--color-primary-dark));
  color: var(--color-white);
  border-color: transparent;
  box-shadow: 0 4px 12px rgba(4, 120, 178, 0.3);
}

.blog-pagination .page-numbers.dots {
  background: transparent;
  border: none;
  pointer-events: none;
}

/* ============================================ */
/* SINGLE POST - Individual Article            */
/* ============================================ */

.single-post {
  background: var(--color-white);
}

/* Reading Progress Bar */
.reading-progress {
  position: fixed;
  top: var(--navbar-height);
  left: 0;
  width: 0%;
  height: 4px;
  background: linear-gradient(90deg, var(--color-primary), var(--color-accent-green));
  z-index: 999;
  transition: width 0.1s ease-out;
  box-shadow: 0 2px 8px rgba(4, 120, 178, 0.3);
}

/* Post Hero */
.post-hero {
  position: relative;
  height: 600px;
  overflow: hidden;
  display: flex;
  align-items: flex-end;
  background: var(--color-gray-dark);
}

.post-hero-image {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  z-index: 1;
}

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

.post-hero-overlay {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: linear-gradient(180deg, rgba(0, 0, 0, 0.2) 0%, rgba(0, 0, 0, 0.8) 100%);
  z-index: 2;
}

.post-hero-content {
  position: relative;
  z-index: 3;
  max-width: 900px;
  margin: 0 auto;
  padding: 80px 20px 60px;
  color: var(--color-white);
}

/* Breadcrumbs */
.breadcrumbs {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: var(--font-size-sm);
  margin-bottom: 24px;
  color: rgba(255, 255, 255, 0.8);
}

.breadcrumbs a {
  color: rgba(255, 255, 255, 0.9);
  text-decoration: none;
  transition: var(--transition-fast);
}

.breadcrumbs a:hover {
  color: var(--color-accent-green);
}

.breadcrumbs-separator {
  opacity: 0.5;
}

/* Post Header (without featured image) */
.post-header-simple {
  max-width: 900px;
  margin: 120px auto 60px;
  padding: 0 20px;
  text-align: center;
}

/* Post Title */
.post-hero h1,
.post-header-simple h1 {
  font-size: 56px;
  font-weight: 700;
  line-height: var(--line-height-tight);
  letter-spacing: var(--letter-spacing-tight);
  margin-bottom: 24px;
}

.post-header-simple h1 {
  color: var(--color-text-primary);
}

/* Post Meta Bar */
.post-meta-bar {
  display: flex;
  align-items: center;
  justify-content: center;
  flex-wrap: wrap;
  gap: 20px;
  font-size: 16px;
}

.post-meta-bar-item {
  display: flex;
  align-items: center;
  gap: 8px;
}

.post-meta-bar-item i {
  font-size: 16px;
  opacity: 0.8;
}

.post-meta-bar a {
  color: inherit;
  text-decoration: none;
  font-weight: var(--font-weight-semibold);
  transition: var(--transition-fast);
}

.post-hero .post-meta-bar a:hover {
  color: var(--color-accent-green);
}

.post-header-simple .post-meta-bar {
  color: rgba(0, 70, 86, 0.7);
}

.post-header-simple .post-meta-bar a {
  color: var(--color-primary);
}

.post-header-simple .post-meta-bar a:hover {
  color: var(--color-primary-dark);
}

/* ============================================ */
/* TABLE OF CONTENTS - Professional Design    */
/* ============================================ */

/* TOC Main Container */
.foxen-toc-wrapper {
  max-width: 900px;
  margin: 0 auto 40px;
  background: linear-gradient(135deg, rgba(4, 120, 178, 0.03) 0%, rgba(42, 240, 124, 0.03) 100%);
  border: 1px solid rgba(0, 0, 0, 0.08);
  border-radius: var(--border-radius-lg);
  overflow: hidden;
}

/* TOC Toggle Button */
.foxen-toc-button {
  width: 100%;
  padding: 20px 24px;
  background: transparent;
  border: none;
  display: flex;
  align-items: center;
  gap: 12px;
  cursor: pointer;
  font-size: 16px;
  font-weight: 600;
  color: var(--color-text-primary);
  transition: all 0.3s ease;
}

.foxen-toc-button:hover {
  background: rgba(4, 120, 178, 0.05);
}

/* TOC Button Text */
.foxen-toc-title {
  flex: 1;
  text-align: left;
}

/* TOC Icons */
.foxen-toc-icon-left {
  color: var(--color-primary);
  font-size: 16px;
}

.foxen-toc-icon-chevron {
  color: var(--color-primary);
  font-size: 16px;
  transition: transform 0.3s ease;
}

.foxen-toc-button[aria-expanded="true"] .foxen-toc-icon-chevron {
  transform: rotate(180deg);
}

/* TOC Collapsible Content */
.foxen-toc-collapse {
  max-height: 100px;
  overflow: hidden;
  position: relative;
  transition: max-height 0.4s ease;
}

.foxen-toc-collapse.foxen-expanded {
  max-height: 1000px;
}

/* Gradient blur effect when collapsed */
.foxen-toc-collapse::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  height: 40px;
  background: linear-gradient(to bottom, transparent, rgba(248, 249, 251, 0.95));
  pointer-events: none;
  opacity: 1;
  transition: opacity 0.3s ease;
}

.foxen-toc-collapse.foxen-expanded::after {
  opacity: 0;
}

/* TOC Navigation */
.foxen-toc-navigation {
  padding: 0 24px 20px;
}

/* TOC Ordered List */
.foxen-toc-ol {
  list-style: none;
  counter-reset: foxen-toc-counter;
  margin: 0;
  padding: 0;
}

/* TOC List Items */
.foxen-toc-li {
  counter-increment: foxen-toc-counter;
  margin-bottom: 12px;
}

/* TOC Links - Override .entry-content a styles */
.entry-content .foxen-toc-anchor,
.foxen-toc-anchor {
  display: flex;
  align-items: baseline;
  gap: 12px;
  color: var(--color-primary) !important;
  text-decoration: none;
  font-size: 15px;
  line-height: 1.6;
  transition: all 0.2s ease;
  padding: 8px 12px;
  border-radius: var(--border-radius-md);
  border-bottom: 2px solid rgba(4, 120, 178, 0.3) !important;
}

.entry-content .foxen-toc-anchor::before,
.foxen-toc-anchor::before {
  content: counter(foxen-toc-counter) ".";
  font-weight: 600;
  color: var(--color-primary);
  min-width: 24px;
}

.entry-content .foxen-toc-anchor:hover,
.foxen-toc-anchor:hover {
  background: rgba(4, 120, 178, 0.08);
  color: var(--color-primary-dark) !important;
  transform: translateX(4px);
}

/* Post Content */
.post-content-wrapper {
  max-width: 900px;
  margin: 60px auto;
  padding: 0 20px;
}

.entry-content {
  font-size: 19px;
  line-height: 1.8;
  color: var(--color-text-primary);
}

/* Smooth scroll to anchors */
html {
  scroll-behavior: smooth;
  scroll-padding-top: 100px;
}

/* Font Awesome icons in blog content - Primary Blue color */
.entry-content i.fa,
.entry-content i.fas,
.entry-content i.far,
.entry-content i.fab,
.entry-content i.fal,
.entry-content [class*="fa-"] {
  color: var(--color-primary);
}

/* TOC icons stay green */
.post-toc-toggle i {
  color: var(--color-accent-green);
}

.reading-time i {
  color: var(--color-white);
}

.post-meta-item i {
  color: var(--color-primary);
  opacity: 1;
}

.post-meta-bar-item i {
  color: var(--color-primary);
  opacity: 1;
}

/* Typography inside content */
.entry-content h2,
.entry-content h3,
.entry-content h4,
.entry-content h5,
.entry-content h6 {
  color: var(--color-text-primary);
  font-weight: 700;
  margin-top: 48px;
  margin-bottom: 24px;
  line-height: var(--line-height-snug);
}

.entry-content h2 {
  font-size: 38px;
  letter-spacing: var(--letter-spacing-tight);
}

.entry-content h3 {
  font-size: 30px;
}

.entry-content h4 {
  font-size: 24px;
}

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

.entry-content a {
  color: var(--color-accent-green);
  text-decoration: none;
  border-bottom: 2px solid rgba(0, 255, 178, 0.3);
  transition: var(--transition-fast);
}

.entry-content a:hover {
  color: #00c896;
  border-bottom-color: #00c896;
}

.entry-content ul,
.entry-content ol {
  margin: 24px 0 24px 32px;
  padding: 0;
}

.entry-content li {
  margin-bottom: 12px;
  line-height: 1.7;
}

.entry-content img {
  max-width: 100%;
  height: auto;
  border-radius: var(--border-radius-lg);
  margin: 40px 0;
  box-shadow: var(--shadow-md);
}

.entry-content blockquote {
  position: relative;
  border-left: 4px solid var(--color-accent-green);
  padding: 24px 32px;
  margin: 40px 0;
  background: linear-gradient(135deg, rgba(4, 120, 178, 0.03), rgba(0, 255, 178, 0.03));
  border-radius: var(--border-radius-md);
  font-style: italic;
  font-size: 20px;
  color: rgba(0, 70, 86, 0.85);
}

.entry-content blockquote::before {
  content: '\f10d';
  font-family: 'Font Awesome 6 Free';
  font-weight: 900;
  position: absolute;
  top: 2px;
  left: 10px;
  font-size: 24px;
  color: var(--color-primary);
  opacity: 0.3;
}

.entry-content code {
  background: rgba(0, 70, 86, 0.06);
  padding: 4px 8px;
  border-radius: 4px;
  font-family: 'Monaco', 'Courier New', monospace;
  font-size: 16px;
  color: var(--color-primary-dark);
}

.entry-content pre {
  background: var(--color-gray-dark);
  color: var(--color-white);
  padding: 24px;
  border-radius: var(--border-radius-md);
  overflow-x: auto;
  margin: 32px 0;
  box-shadow: var(--shadow-md);
}

.entry-content pre code {
  background: transparent;
  padding: 0;
  color: var(--color-white);
  font-size: 14px;
}

/* In-Content CTA */
.in-content-cta {
  max-width: 1184px;
  margin: 48px auto;
  padding: 32px 28px;
  background: linear-gradient(135deg, rgba(4, 120, 178, 0.03) 0%, rgba(42, 240, 124, 0.03) 100%);
  border-left: 1px solid var(--color-border-light);
  border-right: 1px solid var(--color-border-light);
  border-radius: 0;
  text-align: center;
}

.in-content-cta-title {
  font-size: 24px;
  font-weight: 700;
  color: var(--color-primary-dark);
  margin: 0 0 12px 0;
  line-height: 1.3;
}

.in-content-cta-text {
  font-size: 16px;
  color: var(--color-text-secondary);
  margin: 0 0 24px 0;
  line-height: 1.6;
}

.in-content-cta-button {
  display: inline-flex !important;
  align-items: center !important;
  gap: var(--space-2) !important;
  padding: var(--space-2) var(--space-5) !important;
  background-color: var(--color-accent-green) !important;
  border: var(--border-width-medium) solid var(--color-overlay-dark) !important;
  border-radius: var(--border-radius-pill) !important;
  box-shadow: var(--shadow-glow-green) !important;
  text-decoration: none !important;
  transition: all var(--transition-base) ease !important;
  cursor: pointer !important;
  position: relative !important;
  overflow: hidden !important;
  color: var(--color-black) !important;
  font-size: var(--font-size-base) !important;
  font-weight: var(--font-weight-medium) !important;
  font-family: var(--font-primary) !important;
}

.in-content-cta-button:hover {
  background-color: rgb(0, 230, 160) !important;
  box-shadow: 0px 0px 40px 0px var(--color-accent-green-glow-strong),
              0px 0px 0px 6px rgba(var(--color-accent-green-rgb), 0.15) !important;
  transform: translateY(-1px) !important;
  color: var(--color-black) !important;
}

.in-content-cta-button:active {
  transform: translateY(0px) !important;
  box-shadow: var(--shadow-glow-green) !important;
}

/* Shine effect for in-content CTA */
.in-content-cta-button::after {
  content: '' !important;
  position: absolute !important;
  top: 0 !important;
  left: -100% !important;
  width: 50% !important;
  height: 100% !important;
  background: linear-gradient(
    90deg,
    rgba(255, 255, 255, 0) 0%,
    rgba(255, 255, 255, 0.3) 50%,
    rgba(255, 255, 255, 0) 100%
  ) !important;
  transform: skewX(-20deg) !important;
  animation: shine 9s infinite !important;
  pointer-events: none !important;
  z-index: 1 !important;
}

.in-content-cta-button i {
  font-size: var(--font-size-base) !important;
  color: var(--color-black) !important;
  position: relative !important;
  z-index: 2 !important;
}

@media (max-width: 639px) {
  .in-content-cta {
    margin: 32px 0;
    padding: 24px 20px;
  }

  .in-content-cta-title {
    font-size: 20px;
  }

  .in-content-cta-text {
    font-size: 14px;
  }

  .in-content-cta-button {
    padding: 12px 24px;
    font-size: 15px;
  }
}

/* Post Footer with Tags */
.post-footer {
  max-width: 900px;
  margin: 60px auto 0;
  padding: 40px 20px 0;
  border-top: 2px solid rgba(0, 0, 0, 0.08);
}

.post-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  align-items: center;
}

.tags-label {
  font-weight: var(--font-weight-semibold);
  color: var(--color-text-primary);
  font-size: 16px;
  margin-right: 8px;
}

.post-tag {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 10px 18px;
  background: var(--color-white);
  color: var(--color-primary);
  border: 2px solid var(--color-primary);
  border-radius: var(--border-radius-pill);
  font-size: var(--font-size-sm);
  font-weight: var(--font-weight-semibold);
  text-decoration: none;
  transition: var(--transition-base);
}

.post-tag:hover {
  background: var(--color-primary);
  color: var(--color-white);
  transform: translateY(-2px);
  box-shadow: 0 4px 12px rgba(4, 120, 178, 0.25);
}

/* Share Buttons */
.share-buttons {
  max-width: 900px;
  margin: 40px auto 0;
  padding: 0 20px;
}

.share-buttons-title {
  font-size: 16px;
  font-weight: var(--font-weight-semibold);
  color: var(--color-text-primary);
  margin-bottom: 16px;
}

.share-buttons-list {
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
}

.share-button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 48px;
  height: 48px;
  border-radius: var(--border-radius-circle);
  background: var(--color-white);
  border: 2px solid rgba(0, 0, 0, 0.08);
  color: var(--color-text-primary);
  text-decoration: none;
  transition: var(--transition-base);
  font-size: 18px;
}

.share-button:hover {
  transform: translateY(-4px);
  box-shadow: 0 8px 20px rgba(0, 0, 0, 0.12);
}

.share-button.twitter:hover {
  background: #1DA1F2;
  color: var(--color-white);
  border-color: #1DA1F2;
}

.share-button.facebook:hover {
  background: #1877F2;
  color: var(--color-white);
  border-color: #1877F2;
}

.share-button.linkedin:hover {
  background: #0A66C2;
  color: var(--color-white);
  border-color: #0A66C2;
}

.share-button.whatsapp:hover {
  background: #25D366;
  color: var(--color-white);
  border-color: #25D366;
}

.share-button.copy:hover {
  background: var(--color-primary);
  color: var(--color-white);
  border-color: var(--color-primary);
}

/* Post Navigation */
.post-navigation {
  max-width: var(--container-max-width);
  margin: 80px auto 0;
  padding: 0 20px;
}

.post-navigation-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 32px;
  margin-top: 20px;
}

.nav-post {
  position: relative;
  background: var(--color-white);
  padding: 32px;
  border-radius: var(--border-radius-lg);
  border: 1px solid rgba(0, 0, 0, 0.06);
  transition: var(--transition-base);
  overflow: hidden;
}

.nav-post::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: linear-gradient(135deg, var(--color-primary) 0%, var(--color-accent-green) 100%);
  opacity: 0;
  transition: var(--transition-base);
}

.nav-post:hover {
  transform: translateY(-4px);
  box-shadow: 0 12px 32px rgba(4, 120, 178, 0.15);
}

.nav-post:hover::before {
  opacity: 0.03;
}

.nav-post-label {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: var(--font-size-sm);
  font-weight: var(--font-weight-semibold);
  color: rgba(0, 70, 86, 0.6);
  margin-bottom: 12px;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  position: relative;
}

.nav-post-title {
  font-size: 20px;
  font-weight: 700;
  line-height: var(--line-height-snug);
  color: var(--color-text-primary);
  text-decoration: none;
  transition: var(--transition-fast);
  display: block;
  position: relative;
}

.nav-post:hover .nav-post-title {
  color: var(--color-primary);
}

.nav-next {
  text-align: right;
}

/* ============================================ */
/* COMMENTS SECTION                            */
/* ============================================ */

.comments-section {
  max-width: 900px;
  margin: 80px auto 0;
  padding: 0 20px 80px;
}

.comments-area {
  background: var(--color-white);
  border-radius: var(--border-radius-lg);
  padding: 48px;
  border: 1px solid rgba(0, 0, 0, 0.06);
}

/* Comments Title */
.comments-title {
  font-size: 32px;
  font-weight: 700;
  color: var(--color-text-primary);
  margin-bottom: 40px;
  padding-bottom: 24px;
  border-bottom: 2px solid rgba(0, 0, 0, 0.08);
}

/* Comment List */
.comment-list {
  list-style: none;
  margin: 0;
  padding: 0;
}

.comment-list .comment {
  margin-bottom: 32px;
  padding-bottom: 32px;
  border-bottom: 1px solid rgba(0, 0, 0, 0.06);
}

.comment-list .comment:last-child {
  border-bottom: none;
}

/* Comment Body */
.comment-body {
  display: flex;
  gap: 20px;
}

.comment-author .avatar {
  border-radius: var(--border-radius-circle);
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
  border: 3px solid var(--color-white);
}

.comment-content-wrapper {
  flex: 1;
}

.comment-meta {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 12px;
  flex-wrap: wrap;
}

.comment-author-name {
  font-size: 16px;
  font-weight: var(--font-weight-semibold);
  color: var(--color-text-primary);
  text-decoration: none;
  transition: var(--transition-fast);
}

.comment-author-name:hover {
  color: var(--color-primary);
}

.comment-metadata {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: var(--font-size-sm);
  color: rgba(0, 70, 86, 0.6);
}

.comment-metadata a {
  color: inherit;
  text-decoration: none;
  transition: var(--transition-fast);
}

.comment-metadata a:hover {
  color: var(--color-primary);
}

.comment-content {
  font-size: 16px;
  line-height: var(--line-height-relaxed);
  color: rgba(0, 70, 86, 0.85);
  margin-bottom: 16px;
}

.comment-content p {
  margin: 0 0 12px 0;
}

.comment-content p:last-child {
  margin-bottom: 0;
}

.reply {
  margin-top: 12px;
}

.comment-reply-link {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 8px 16px;
  background: rgba(4, 120, 178, 0.05);
  color: var(--color-primary);
  font-size: var(--font-size-sm);
  font-weight: var(--font-weight-semibold);
  text-decoration: none;
  border-radius: var(--border-radius-pill);
  transition: var(--transition-base);
}

.comment-reply-link:hover {
  background: var(--color-primary);
  color: var(--color-white);
  transform: translateX(4px);
}

/* Nested Comments */
.comment-list .children {
  list-style: none;
  margin: 32px 0 0 60px;
  padding: 0;
}

/* Comment Form */
.comment-respond {
  margin-top: 48px;
}

.comment-reply-title {
  font-size: 28px;
  font-weight: 700;
  color: var(--color-text-primary);
  margin-bottom: 32px;
}

.comment-form {
  display: grid;
  gap: 24px;
}

.comment-form-comment,
.comment-form-author,
.comment-form-email,
.comment-form-url {
  margin: 0;
}

.comment-form label {
  display: block;
  font-size: 15px;
  font-weight: var(--font-weight-semibold);
  color: var(--color-text-primary);
  margin-bottom: 10px;
}

.comment-form .required {
  color: var(--color-error);
  margin-left: 4px;
}

.comment-form input[type="text"],
.comment-form input[type="email"],
.comment-form input[type="url"],
.comment-form textarea {
  width: 100%;
  padding: 16px 20px;
  font-size: 16px;
  font-family: var(--font-primary);
  color: var(--color-text-primary);
  background: var(--color-white);
  border: 2px solid rgba(0, 0, 0, 0.08);
  border-radius: var(--border-radius-md);
  transition: var(--transition-base);
  outline: none;
}

.comment-form input[type="text"]:focus,
.comment-form input[type="email"]:focus,
.comment-form input[type="url"]:focus,
.comment-form textarea:focus {
  border-color: var(--color-primary);
  box-shadow: 0 0 0 4px rgba(4, 120, 178, 0.1);
}

.comment-form textarea {
  min-height: 160px;
  resize: vertical;
}

/* ============================================ */
/* CUSTOM CHECKBOX STYLES                      */
/* ============================================ */

/* Checkbox container */
.comment-form-cookies-consent {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  margin: 24px 0;
}

/* Hide default checkbox */
.comment-form-cookies-consent input[type="checkbox"] {
  appearance: none;
  -webkit-appearance: none;
  -moz-appearance: none;
  width: 20px;
  height: 20px;
  min-width: 20px;
  border: 2px solid var(--color-primary);
  border-radius: 4px;
  background-color: var(--color-white);
  cursor: pointer;
  position: relative;
  transition: all 0.2s ease;
  margin: 2px 0 0 0;
}

.comment-form-cookies-consent input[type="checkbox"]:hover {
  border-color: var(--color-primary-dark);
  box-shadow: 0 0 0 4px rgba(4, 120, 178, 0.1);
}

.comment-form-cookies-consent input[type="checkbox"]:checked {
  background-color: var(--color-primary);
  border-color: var(--color-primary);
}

/* Checkmark */
.comment-form-cookies-consent input[type="checkbox"]:checked::after {
  content: '';
  position: absolute;
  left: 5px;
  top: 1px;
  width: 6px;
  height: 11px;
  border: solid white;
  border-width: 0 2px 2px 0;
  transform: rotate(45deg);
}

/* Label alignment */
.comment-form-cookies-consent label {
  flex: 1;
  margin: 0;
  font-size: 14px;
  line-height: 1.5;
  color: var(--color-text-secondary);
  cursor: pointer;
}

.form-submit {
  margin: 0;
}

.comment-form .submit-button,
.comment-form input[type="submit"] {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 16px 40px;
  background: linear-gradient(135deg, var(--color-accent-green), #00ffb2);
  color: var(--color-text-primary);
  font-size: 16px;
  font-weight: var(--font-weight-bold);
  text-decoration: none;
  border: none;
  border-radius: var(--border-radius-pill);
  cursor: pointer;
  transition: var(--transition-base);
  box-shadow: 0 4px 16px rgba(0, 255, 178, 0.25);
  font-family: var(--font-primary);
}

.comment-form .submit-button:hover,
.comment-form input[type="submit"]:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 24px rgba(0, 255, 178, 0.4);
}

.comment-form .submit-button:active,
.comment-form input[type="submit"]:active {
  transform: translateY(0);
}

/* Logged In Message */
.logged-in-as {
  font-size: 15px;
  color: rgba(0, 70, 86, 0.7);
  margin-bottom: 24px;
  padding: 16px;
  background: rgba(4, 120, 178, 0.05);
  border-radius: var(--border-radius-md);
  border-left: 4px solid var(--color-primary);
}

.logged-in-as a {
  color: var(--color-primary);
  text-decoration: none;
  font-weight: var(--font-weight-semibold);
  transition: var(--transition-fast);
}

.logged-in-as a:hover {
  color: var(--color-primary-dark);
}

/* No Comments */
.no-comments {
  text-align: center;
  padding: 40px 20px;
  font-size: 16px;
  color: rgba(0, 70, 86, 0.6);
}

/* Comment Navigation */
.comment-navigation {
  margin: 32px 0;
  display: flex;
  justify-content: space-between;
  gap: 16px;
}

.comment-navigation a {
  padding: 12px 24px;
  background: rgba(4, 120, 178, 0.05);
  color: var(--color-primary);
  text-decoration: none;
  border-radius: var(--border-radius-md);
  font-weight: var(--font-weight-semibold);
  transition: var(--transition-base);
}

.comment-navigation a:hover {
  background: var(--color-primary);
  color: var(--color-white);
}

/* ============================================ */
/* RESPONSIVE DESIGN                           */
/* ============================================ */

@media (max-width: 1024px) {
  .posts-grid {
    grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
    gap: 32px;
  }

  .blog-header h1 {
    font-size: 48px;
  }
}

@media (max-width: 768px) {
  .blog-header {
    padding: 100px 20px 40px;
  }

  .blog-header h1 {
    font-size: 36px;
    margin-bottom: var(--space-4);
  }

  .blog-header-description {
    font-size: 16px;
  }

  .posts-container {
    padding: 60px 20px;
  }

  .posts-grid {
    grid-template-columns: 1fr;
    gap: 24px;
  }

  .post-thumbnail {
    height: 220px;
  }

  .post-content {
    padding: 24px;
  }

  .post-title {
    font-size: 22px;
  }

  /* Single Post */
  .post-hero {
    height: 450px;
  }

  .post-hero h1,
  .post-header-simple h1 {
    font-size: 32px;
  }

  .post-hero-content {
    padding: 60px 20px 40px;
  }

  .entry-content {
    font-size: 17px;
  }

  .entry-content h2 {
    font-size: 28px;
  }

  .entry-content h3 {
    font-size: 24px;
  }

  .entry-content h4 {
    font-size: 20px;
  }

  .post-navigation-grid {
    grid-template-columns: 1fr;
    gap: 20px;
  }

  .nav-next {
    text-align: left;
  }

  .comments-area {
    padding: 32px 20px;
  }

  .comments-title {
    font-size: 24px;
  }

  .comment-body {
    flex-direction: column;
    gap: 16px;
  }

  .comment-list .children {
    margin-left: 20px;
  }

  .comment-reply-title {
    font-size: 22px;
  }
}

@media (max-width: 480px) {
  .blog-header h1 {
    font-size: 28px;
  }

  .post-hero {
    height: 350px;
  }

  .post-hero h1 {
    font-size: 24px;
  }

  .post-meta-bar {
    font-size: 14px;
    gap: 12px;
  }

  .entry-content {
    font-size: 16px;
  }

  .post-navigation-grid {
    gap: 16px;
  }

  .nav-post {
    padding: 24px;
  }

  .comments-area {
    padding: 24px 16px;
  }
}

/* ============================================
   DARK MODE
   ============================================ */

[data-theme="dark"] .comment-form .submit-button,
[data-theme="dark"] .comment-form input[type="submit"] {
  background: linear-gradient(135deg, rgba(42, 240, 124, 0.9), rgba(0, 200, 150, 0.8)) !important;
  color: #000000 !important;
  box-shadow: 0 4px 20px rgba(42, 240, 124, 0.25), 0 0 0 1px rgba(42, 240, 124, 0.2) !important;
  border: none !important;
}

[data-theme="dark"] .comment-form .submit-button:hover,
[data-theme="dark"] .comment-form input[type="submit"]:hover {
  background: linear-gradient(135deg, rgba(42, 240, 124, 1), rgba(0, 220, 165, 1)) !important;
  color: #000000 !important;
  box-shadow: 0 6px 30px rgba(42, 240, 124, 0.4), 0 0 0 1px rgba(42, 240, 124, 0.3) !important;
  transform: translateY(-2px) !important;
}

[data-theme="dark"] .comment-form .submit-button:active,
[data-theme="dark"] .comment-form input[type="submit"]:active {
  transform: translateY(0) !important;
}

[data-theme="dark"] .logged-in-as {
  color: #ffffff;
}

/* ============================================ */
/* CONTENT TABLES - Light & Dark Mode          */
/* ============================================ */

/* Tables in article content - Light Mode */
.entry-content table {
  width: 100%;
  border-collapse: collapse;
  margin: var(--space-5) 0;
  background: var(--color-white);
  border-radius: var(--border-radius-base);
  overflow: hidden;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.06);
}

.entry-content table thead {
  background: var(--color-bg-secondary);
  border-bottom: 2px solid rgba(var(--color-primary-rgb), 0.15);
}

.entry-content table thead tr {
  background: var(--color-bg-secondary);
}

.entry-content table th {
  padding: var(--space-3) var(--space-4);
  text-align: left;
  font-weight: var(--font-weight-bold);
  font-size: var(--font-size-sm);
  letter-spacing: 0.02em;
  text-transform: uppercase;
  color: var(--color-text-primary);
}

.entry-content table tbody tr {
  border-bottom: 1px solid rgba(0, 0, 0, 0.06);
  transition: background var(--transition-fast);
}

.entry-content table tbody tr:hover {
  background: rgba(var(--color-primary-rgb), 0.04);
}

.entry-content table tbody tr:last-child {
  border-bottom: none;
}

.entry-content table td {
  padding: var(--space-3) var(--space-4);
  color: var(--color-text-primary);
  line-height: 1.6;
}

.entry-content table td strong {
  font-weight: var(--font-weight-semibold);
  color: var(--color-text-primary);
}

/* Tables in article content - Dark Mode */
[data-theme="dark"] .entry-content table {
  background: rgba(255, 255, 255, 0.03);
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.3);
}

[data-theme="dark"] .entry-content table thead {
  background: rgba(255, 255, 255, 0.05);
  border-bottom: 2px solid rgba(42, 240, 124, 0.2);
}

[data-theme="dark"] .entry-content table thead tr {
  background: rgba(255, 255, 255, 0.05);
}

[data-theme="dark"] .entry-content table th {
  color: var(--color-white);
}

[data-theme="dark"] .entry-content table tbody tr {
  border-bottom: 1px solid rgba(255, 255, 255, 0.06);
}

[data-theme="dark"] .entry-content table tbody tr:hover {
  background: rgba(42, 240, 124, 0.05);
}

[data-theme="dark"] .entry-content table td {
  color: rgba(255, 255, 255, 0.9);
}

[data-theme="dark"] .entry-content table td strong {
  color: var(--color-white);
}

/* Responsive tables */
@media screen and (max-width: 768px) {
  .entry-content table {
    font-size: var(--font-size-sm);
  }

  .entry-content table th,
  .entry-content table td {
    padding: var(--space-2) var(--space-3);
  }
}
