/* ========================================
   THE INSURE MANTRA - BLOG.CSS
   UI Palette:
   Primary CTA: #0F766E
   CTA Hover: #0B5F59
   Secondary Button: #0B3B8C
   Success: #22C55E
   Warning: #F59E0B
   Background: #F8FAFC
   Card: #FFFFFF
   ======================================== */

:root {
  --primary: #0F766E;           /* Trust Teal - Primary CTA */
  --secondary: #0B3B8C;         /* Deep Navy - Secondary Button */
  --accent: #0F766E;            /* Trust Teal */
  --primary-dark: #0B3B8C;      /* Deep Navy */
  --primary-dark-alt: #092E6E;  /* Darker Navy */
  --text-light: #64748B;        /* Muted Text */
  --bg-light: #F8FAFC;          /* Background */
  --card-bg: #FFFFFF;           /* Card White */
  --success: #22C55E;           /* Success Green */
  --warning: #F59E0B;           /* Warning Amber */
  --border-light: #E2E8F0;
  --shadow-sm: rgba(15, 118, 110, 0.08);
  --shadow-md: rgba(15, 118, 110, 0.12);
  --shadow-lg: rgba(15, 118, 110, 0.18);
}

/* ===== HERO SECTION ===== */
.blog-hero {
  background: linear-gradient(135deg, var(--secondary) 0%, var(--primary) 100%);
  color: white;
  padding: 60px 0;
  margin-bottom: 30px;
  border-bottom: 4px solid var(--primary);
  margin-top: 20px;
  position: relative;
  overflow: hidden;
}

.blog-hero::before {
  content: '';
  position: absolute;
  top: -50%;
  right: -20%;
  width: 400px;
  height: 400px;
  background: rgba(255, 255, 255, 0.03);
  border-radius: 50%;
  pointer-events: none;
}

.blog-hero::after {
  content: '';
  position: absolute;
  bottom: -30%;
  left: -10%;
  width: 300px;
  height: 300px;
  background: rgba(255, 255, 255, 0.02);
  border-radius: 50%;
  pointer-events: none;
}

.blog-hero h1 {
  color: white;
  font-size: clamp(2rem, 5vw, 2.8rem);
  font-weight: 700;
  margin-bottom: 1rem;
  position: relative;
  z-index: 1;
}

.blog-hero .lead {
  color: white;
  font-size: clamp(1rem, 2vw, 1.2rem);
  opacity: 0.95;
  max-width: 600px;
  position: relative;
  z-index: 1;
}

.blog-hero p {
  color: white;
  position: relative;
  z-index: 1;
}

.blog-welcome-badge {
  background: var(--primary);
  color: white;
  font-size: 0.9rem;
  font-weight: 700;
  padding: 0.5rem 1.5rem;
  border-radius: 50px;
  display: inline-block;
  text-transform: uppercase;
  letter-spacing: 1px;
  position: relative;
  z-index: 1;
}

/* ===== BLOG SEARCH ===== */
.blog-search {
  max-width: 500px;
  position: relative;
  z-index: 1;
}

.blog-search .input-group {
  box-shadow: 0 4px 20px rgba(11, 59, 140, 0.25);
  border-radius: 50px;
  overflow: hidden;
}

.blog-search .form-control {
  border: none;
  padding: 0.8rem 1.5rem;
  font-size: 1rem;
}

.blog-search .form-control:focus {
  box-shadow: none;
  outline: none;
}

.blog-search .btn {
  background: var(--primary);
  color: white;
  border: none;
  padding: 0.8rem 1.8rem;
  font-weight: 600;
  transition: all 0.3s ease;
}

.blog-search .btn:hover {
  background: var(--primary-dark-alt);
  color: white;
}

/* ===== SECTION TITLE ===== */
.section-title {
  font-size: 1.8rem;
  font-weight: 700;
  color: var(--primary-dark);
  position: relative;
  padding-bottom: 0.5rem;
}

.section-title::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 0;
  width: 60px;
  height: 3px;
  background: var(--primary);
  border-radius: 2px;
}

.text-center .section-title::after {
  left: 50%;
  transform: translateX(-50%);
}

/* ===== FEATURED CARDS ===== */
.featured-card {
  position: relative;
  border-radius: 12px;
  overflow: hidden;
  height: 250px;
  box-shadow: 0 4px 15px var(--shadow-sm);
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.featured-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 8px 30px var(--shadow-md);
}

.featured-card img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.featured-no-image {
  width: 100%;
  height: 100%;
  background: linear-gradient(135deg, var(--secondary), var(--primary));
  display: flex;
  align-items: center;
  justify-content: center;
  color: white;
  font-size: 3rem;
}

.featured-overlay {
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  background: linear-gradient(transparent, rgba(11, 59, 140, 0.92));
  padding: 1.5rem;
  color: white;
}

.featured-label {
  background: var(--primary);
  color: white;
  font-size: 0.7rem;
  font-weight: 700;
  padding: 0.2rem 0.8rem;
  border-radius: 50px;
  display: inline-block;
  margin-bottom: 0.5rem;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.featured-overlay h5 a {
  color: white;
  text-decoration: none;
  font-weight: 600;
  transition: color 0.2s ease;
}

.featured-overlay h5 a:hover {
  color: #5EEAD4;
}

.featured-overlay small {
  color: rgba(255, 255, 255, 0.85);
}

.featured-overlay small i {
  color: var(--primary);
  margin-right: 0.3rem;
}

/* ===== BLOG CARDS ===== */
.blog-card {
  background: var(--card-bg);
  border-radius: 12px;
  overflow: hidden;
  box-shadow: 0 2px 12px var(--shadow-sm);
  transition: transform 0.3s ease, box-shadow 0.3s ease;
  height: 100%;
  border: 1px solid var(--border-light);
}

.blog-card:hover {
  transform: translateY(-5px);
  box-shadow: 0 8px 30px var(--shadow-md);
  border-color: var(--primary);
}

.blog-card-img {
  width: 100%;
  height: 220px;
  object-fit: cover;
}

.blog-no-image {
  height: 220px;
  background: linear-gradient(135deg, var(--secondary), var(--primary));
  display: flex;
  align-items: center;
  justify-content: center;
  color: white;
  font-size: 2.5rem;
}

.blog-card-content {
  padding: 1.5rem;
}

.blog-category {
  background: var(--primary);
  color: white;
  font-size: 0.7rem;
  font-weight: 600;
  padding: 0.25rem 1rem;
  border-radius: 50px;
  display: inline-block;
  margin-bottom: 0.8rem;
  text-decoration: none;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  transition: all 0.2s ease;
}

.blog-category:hover {
  background: var(--primary-dark-alt);
  color: white;
  text-decoration: none;
}

.blog-title {
  font-size: 1.2rem;
  font-weight: 700;
  margin-bottom: 0.8rem;
  line-height: 1.4;
}

.blog-title a {
  color: var(--primary-dark);
  text-decoration: none;
  transition: color 0.2s ease;
}

.blog-title a:hover {
  color: var(--primary);
  text-decoration: none;
}

.blog-meta {
  font-size: 0.85rem;
  color: var(--text-light);
  margin-bottom: 1rem;
  padding-bottom: 1rem;
  border-bottom: 1px solid var(--border-light);
}

.blog-meta i {
  color: var(--primary);
  margin-right: 0.3rem;
}

.blog-meta span {
  margin-right: 1rem;
}

.blog-read-more {
  color: var(--primary);
  font-weight: 600;
  font-size: 0.9rem;
  text-decoration: none;
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  transition: all 0.3s ease;
}

.blog-read-more:hover {
  color: var(--primary-dark-alt);
  gap: 0.8rem;
  text-decoration: none;
}

/* ===== SIDEBAR ===== */
.sidebar-box {
  background: var(--card-bg);
  border-radius: 12px;
  padding: 1.5rem;
  box-shadow: 0 2px 12px var(--shadow-sm);
  border-left: 4px solid var(--primary);
  margin-bottom: 1.5rem;
}

.sidebar-box h4 {
  color: var(--primary-dark);
  font-size: 1.2rem;
  font-weight: 700;
  margin-bottom: 1.2rem;
  padding-bottom: 0.5rem;
  border-bottom: 2px solid var(--primary);
}

.sidebar-list {
  list-style: none;
  padding: 0;
  margin: 0;
}

.sidebar-list li {
  padding: 0.5rem 0;
  border-bottom: 1px dashed var(--border-light);
}

.sidebar-list li:last-child {
  border-bottom: none;
}

.sidebar-list a {
  color: var(--text-light);
  text-decoration: none;
  display: block;
  transition: all 0.2s ease;
}

.sidebar-list a:hover {
  color: var(--primary);
  padding-left: 5px;
  text-decoration: none;
}

.popular-item {
  margin-bottom: 1rem;
  padding-bottom: 1rem;
  border-bottom: 1px dashed var(--border-light);
}

.popular-item:last-child {
  border-bottom: none;
  margin-bottom: 0;
  padding-bottom: 0;
}

.popular-link {
  color: var(--primary-dark);
  font-weight: 500;
  text-decoration: none;
  display: block;
  margin-bottom: 0.2rem;
  transition: color 0.2s ease;
}

.popular-link:hover {
  color: var(--primary);
  text-decoration: none;
}

.popular-item small {
  color: var(--text-light);
  font-size: 0.8rem;
}

.popular-item small i {
  color: var(--primary);
  margin-right: 0.3rem;
}

/* ===== PAGINATION ===== */
.pagination .page-link {
  color: var(--primary);
  border: 1px solid var(--border-light);
  margin: 0 3px;
  border-radius: 8px;
  padding: 0.5rem 1rem;
  transition: all 0.2s ease;
}

.pagination .page-link:hover {
  background: #E6F7F5;
  border-color: var(--primary);
  color: var(--primary-dark-alt);
}

.pagination .active .page-link {
  background: var(--primary);
  border-color: var(--primary);
  color: white;
}

.pagination .active .page-link:hover {
  background: var(--primary-dark-alt);
  border-color: var(--primary-dark-alt);
  color: white;
}

/* ===== CATEGORY TAGS ===== */
.category-tag {
  display: inline-block;
  background: #E6F7F5;
  color: var(--primary);
  font-size: 0.7rem;
  font-weight: 600;
  padding: 0.2rem 0.8rem;
  border-radius: 20px;
  margin-right: 0.3rem;
  margin-bottom: 0.3rem;
  text-decoration: none;
  transition: all 0.2s ease;
}

.category-tag:hover {
  background: var(--primary);
  color: white;
  text-decoration: none;
}

/* ===== RESPONSIVE ===== */
@media (max-width: 768px) {
  .blog-hero {
    padding: 40px 0;
    text-align: center;
  }
  
  .blog-hero .lead {
    margin-left: auto;
    margin-right: auto;
  }
  
  .blog-hero .d-flex {
    justify-content: center;
  }
  
  .featured-card {
    height: 200px;
  }
  
  .blog-card-img,
  .blog-no-image {
    height: 180px;
  }
  
  .blog-card-content {
    padding: 1.2rem;
  }
  
  .blog-title {
    font-size: 1.05rem;
  }
  
  .sidebar-box {
    padding: 1.2rem;
  }
  
  .section-title {
    font-size: 1.5rem;
  }
}

@media (max-width: 576px) {
  .blog-hero {
    padding: 30px 0;
  }
  
  .blog-hero h1 {
    font-size: 1.6rem;
  }
  
  .featured-card {
    height: 180px;
  }
  
  .featured-overlay {
    padding: 1rem;
  }
  
  .blog-card-img,
  .blog-no-image {
    height: 160px;
  }
  
  .blog-meta span {
    margin-right: 0.75rem;
    font-size: 0.75rem;
  }
  
  .pagination .page-link {
    padding: 0.35rem 0.75rem;
    font-size: 0.85rem;
  }
}

/* ===== PRINT STYLES ===== */
@media print {
  .blog-hero {
    background: var(--secondary) !important;
    -webkit-print-color-adjust: exact;
    print-color-adjust: exact;
  }
  
  .blog-card {
    box-shadow: none;
    border: 1px solid #ddd;
  }
  
  .blog-card:hover {
    transform: none;
  }
  
  .blog-search {
    display: none;
  }
}

/* ========================================
   BLOG POST HERO - The Insure Mantra
   ======================================== */

.blog-post-hero {
    background: linear-gradient(135deg, var(--secondary-btn, #0B3B8C) 0%, var(--primary-cta, #0F766E) 100%);
    color: white;
    padding: 60px 0 50px;
    margin-bottom: 30px;
    border-bottom: 4px solid var(--primary-cta, #0F766E);
    position: relative;
    overflow: hidden;
}

.blog-post-hero::before {
    content: '';
    position: absolute;
    top: -50%;
    right: -20%;
    width: 400px;
    height: 400px;
    background: rgba(255, 255, 255, 0.03);
    border-radius: 50%;
    pointer-events: none;
}

.blog-post-hero::after {
    content: '';
    position: absolute;
    bottom: -30%;
    left: -10%;
    width: 300px;
    height: 300px;
    background: rgba(255, 255, 255, 0.02);
    border-radius: 50%;
    pointer-events: none;
}

.blog-post-hero h1 {
    color: white;
    font-size: clamp(1.75rem, 4vw, 2.8rem);
    font-weight: 700;
    margin-bottom: 1rem;
    position: relative;
    z-index: 1;
}

.blog-post-hero .blog-post-meta {
    color: rgba(255, 255, 255, 0.85);
    font-size: 0.95rem;
    position: relative;
    z-index: 1;
}

.blog-post-hero .blog-post-meta i {
    color: #5EEAD4;
    margin-right: 0.25rem;
}

.blog-category-badge {
    background: rgba(255, 255, 255, 0.2);
    color: white;
    font-size: 0.8rem;
    font-weight: 600;
    padding: 0.3rem 1.2rem;
    border-radius: 50px;
    text-decoration: none;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    transition: all 0.3s ease;
    position: relative;
    z-index: 1;
}

.blog-category-badge:hover {
    background: var(--primary-cta, #0F766E);
    color: white;
    text-decoration: none;
    transform: translateY(-2px);
}

/* Responsive */
@media (max-width: 768px) {
    .blog-post-hero {
        padding: 40px 0 30px;
        text-align: center;
    }
    
    .blog-post-hero h1 {
        font-size: 1.6rem;
    }
    
    .blog-post-hero .blog-post-meta {
        font-size: 0.85rem;
    }
}

@media (max-width: 576px) {
    .blog-post-hero {
        padding: 30px 0 25px;
    }
    
    .blog-post-hero h1 {
        font-size: 1.4rem;
    }
    
    .blog-post-hero .blog-post-meta span {
        display: inline-block;
        margin-bottom: 0.25rem;
    }
}