/* ============================================
  BAZM-E-BME - Blog Listing Styles
  ============================================ */

/* ============================================
  BLOG HERO SECTION
  ============================================ */
.blog-hero-section {
  height: 100vh;
  position: relative;
  background: linear-gradient(135deg, #0a1628 0%, #1e3a5f 100%);
  padding: 20px;
  overflow: hidden;
  text-align: center;
  display: flex;
  align-items: center;
  justify-content: center;
}

/* Event Bubbles */
.blog-hero-bubbles {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  pointer-events: none;
  z-index: 1;
}

.blog-hero-bubble {
  position: absolute;
  border-radius: 50%;
  background: rgba(201, 162, 39, 0.1);
  border: 1px solid rgba(201, 162, 39, 0.3);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.5rem;
  animation: floatBubble 12s infinite ease-in-out;
}

.blog-hero-bubble:nth-child(1) { 
  width: 80px; height: 80px; 
  top: 20%; left: 10%; 
  animation-delay: 0s;
}

.blog-hero-bubble:nth-child(2) { 
  width: 120px; height: 120px; 
  top: 60%; left: 15%; 
  animation-delay: 2s;
}

.blog-hero-bubble:nth-child(3) { 
  width: 60px; height: 60px; 
  top: 30%; right: 20%; 
  animation-delay: 4s;
}

.blog-hero-bubble:nth-child(4) { 
  width: 100px; height: 100px; 
  bottom: 25%; right: 10%; 
  animation-delay: 6s;
}

/* Calendar Grid Background */
.blog-hero::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background-image: 
    linear-gradient(rgba(201, 162, 39, 0.3) 1px, transparent 1px),
    linear-gradient(90deg, rgba(201, 162, 39, 0.3) 1px, transparent 1px);
  background-size: 30px 30px;
  opacity: 0.05;
  z-index: 0;
}

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

.hero-badge {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: rgba(201, 162, 39, 0.2);
  border: 1px solid rgba(201, 162, 39, 0.4);
  padding: 8px 20px;
  border-radius: 50px;
  color: var(--gold-light);
  font-size: 0.8rem;
  font-weight: 600;
  margin-bottom: 20px;
  backdrop-filter: blur(10px);
  letter-spacing: 1px;
  text-transform: uppercase;
  animation: glow 3s ease-in-out infinite alternate;
}

.blog-hero-title {
  font-family: 'Poppins', serif;
  font-size: clamp(1.8rem, 4vw, 2.8rem);
  font-weight: 800;
  color: var(--white);
  margin-bottom: 15px;
  line-height: 1.2;
  text-shadow: 0 2px 10px rgba(0,0,0,0.2);
}

.blog-hero-title span {
  color: var(--gold-light);
  position: relative;
}

.blog-hero-description {
  font-size: 1rem;
  color: var(--gray-300);
  margin-bottom: 25px;
  line-height: 1.6;
  max-width: 700px;
  margin-left: auto;
  margin-right: auto;
  text-shadow: 0 1px 3px rgba(0,0,0,0.3);
}

/* Search Bar */
.blog-search-container {
  max-width: 600px;
  margin: 0 auto;
}

.blog-search-wrapper {
  position: relative;
  display: flex;
  align-items: center;
  background: rgba(255, 255, 255, 0.1);
  backdrop-filter: blur(20px);
  border: 1px solid rgba(255, 255, 255, 0.2);
  border-radius: 16px;
  padding: 16px 24px;
  transition: all 0.3s ease;
}

.blog-search-wrapper:focus-within {
  background: rgba(255, 255, 255, 0.15);
  border-color: var(--gold);
  box-shadow: 0 8px 32px rgba(201, 162, 39, 0.3);
}

.blog-search-wrapper i {
  color: var(--gold);
  font-size: 1.2rem;
  margin-right: 16px;
}

.blog-search-input {
  flex: 1;
  background: transparent;
  border: none;
  outline: none;
  color: var(--white);
  font-size: 1rem;
  font-family: 'Poppins', sans-serif;
}

.blog-search-input::placeholder {
  color: var(--gray-400);
}

/* Scroll Indicator */
.scroll-indicator {
  position: absolute;
  bottom: 30px;
  left: 50%;
  transform: translateX(-50%);
  display: flex;
  flex-direction: column;
  align-items: center;
  color: var(--gold-light);
  font-size: 0.9rem;
  animation: bounce 2s infinite;
}

.scroll-indicator i {
  margin-top: 5px;
  font-size: 1.5rem;
}

/* Animations */
@keyframes floatBubble {
  0%, 100% { 
    transform: translate(0, 0) rotate(0deg);
  }
  25% { 
    transform: translate(-20px, -30px) rotate(10deg);
  }
  50% { 
    transform: translate(15px, -20px) rotate(-10deg);
  }
  75% { 
    transform: translate(10px, 25px) rotate(5deg);
  }
}

@keyframes glow {
  0% { box-shadow: 0 0 5px rgba(201, 162, 39, 0.3); }
  100% { box-shadow: 0 0 20px rgba(201, 162, 39, 0.6); }
}

@keyframes bounce {
  0%, 20%, 50%, 80%, 100% {
    transform: translateX(-50%) translateY(0);
  }
  40% {
    transform: translateX(-50%) translateY(-20px);
  }
  60% {
    transform: translateX(-50%) translateY(-10px);
  }
}

/* ============================================
  FILTER SECTION
  ============================================ */
.filter-section {
  padding: 30px 0;
  background: var(--white);
  border-bottom: 1px solid var(--gray-200);
  position: sticky;
  top: 80px;
  z-index: 100;
}

.filter-wrapper {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 24px;
  flex-wrap: wrap;
}

.filter-categories {
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
}

.category-btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 10px 20px;
  background: var(--gray-100);
  border: 2px solid transparent;
  border-radius: 12px;
  color: var(--gray-700);
  font-size: 0.9rem;
  font-weight: 500;
  font-family: 'Poppins', sans-serif;
  cursor: pointer;
  transition: all 0.3s ease;
}

.category-btn:hover {
  background: var(--gray-200);
  color: var(--navy);
}

.category-btn.active {
  background: var(--navy);
  color: var(--white);
  border-color: var(--gold);
}

.category-btn i {
  font-size: 1rem;
}

.filter-sort {
  min-width: 200px;
}

.sort-select {
  width: 100%;
  padding: 10px 16px;
  background: var(--gray-100);
  border: 2px solid var(--gray-200);
  border-radius: 12px;
  color: var(--navy);
  font-size: 0.9rem;
  font-weight: 500;
  font-family: 'Poppins', sans-serif;
  cursor: pointer;
  transition: all 0.3s ease;
  outline: none;
}

.sort-select:focus {
  border-color: var(--gold);
  background: var(--white);
}

/* ============================================
  BLOG POSTS SECTION
  ============================================ */
.blog-posts-section {
  padding: 60px 0;
  background: var(--gray-50);
}

/* Featured Post */
.featured-post {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 40px;
  background: var(--white);
  border-radius: 24px;
  overflow: hidden;
  box-shadow: var(--shadow-lg);
  margin-bottom: 60px;
  border: 1px solid var(--gray-100);
}

.featured-post-image {
  position: relative;
  height: 100%;
  min-height: 400px;
}

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

.featured-badge {
  position: absolute;
  top: 24px;
  left: 24px;
  background: var(--gradient-gold);
  color: var(--navy);
  padding: 8px 20px;
  border-radius: 50px;
  font-size: 0.85rem;
  font-weight: 600;
}

.featured-post-content {
  padding: 40px 40px 40px 0;
  display: flex;
  flex-direction: column;
  justify-content: center;
}

.post-meta-top {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 20px;
  flex-wrap: wrap;
  gap: 12px;
}

.post-date {
  display: flex;
  align-items: center;
  gap: 8px;
  color: var(--gray-600);
  font-size: 0.9rem;
}

.post-date i {
  color: var(--gold);
}

.post-tags {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
}

.post-tag {
  padding: 4px 12px;
  background: rgba(201, 162, 39, 0.1);
  color: var(--gold-dark);
  border-radius: 6px;
  font-size: 0.8rem;
  font-weight: 500;
}

.featured-post-title {
  font-family: 'Poppins', serif;
  font-size: 1.8rem;
  color: var(--navy);
  margin-bottom: 20px;
  line-height: 1.3;
}

.featured-post-title a {
  color: inherit;
  transition: color 0.3s ease;
}

.featured-post-title a:hover {
  color: var(--gold-dark);
}

.featured-post-excerpt {
  color: var(--gray-600);
  font-size: 1rem;
  line-height: 1.8;
  margin-bottom: 32px;
}

.post-author-section {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 24px;
}

.post-author-info {
  display: flex;
  align-items: center;
  gap: 16px;
}

.author-avatar {
  width: 56px;
  height: 56px;
  border-radius: 50%;
  object-fit: cover;
  border: 3px solid var(--gold);
}

.author-details {
  display: flex;
  flex-direction: column;
}

.author-name {
  font-weight: 600;
  color: var(--navy);
  font-size: 1rem;
}

.author-position {
  color: var(--gray-600);
  font-size: 0.85rem;
}

.read-more-btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 12px 28px;
  background: var(--navy);
  color: var(--white);
  border-radius: 12px;
  font-weight: 500;
  transition: all 0.3s ease;
}

.read-more-btn:hover {
  background: var(--navy-light);
  transform: translateY(-2px);
  box-shadow: var(--shadow-md);
}

.read-more-btn i {
  transition: transform 0.3s ease;
}

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

/* ============================================
  BLOG POSTS GRID
  ============================================ */
.blog-posts-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(360px, 1fr));
  gap: 28px;
}

.blog-post-card {
  background: var(--white);
  border-radius: 20px;
  overflow: hidden;
  box-shadow: var(--shadow-sm);
  transition: all 0.3s ease;
  border: 1px solid var(--gray-100);
}

.blog-post-card:hover {
  transform: translateY(-8px);
  box-shadow: var(--shadow-lg);
  border-color: rgba(201, 162, 39, 0.3);
}

.post-card-image {
  position: relative;
  height: 240px;
  overflow: hidden;
}

.post-card-image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.5s ease;
}

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

.post-card-overlay {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: linear-gradient(180deg, transparent 0%, rgba(10, 22, 40, 0.3) 100%);
}

.post-category-badge {
  position: absolute;
  top: 16px;
  left: 16px;
  background: var(--gradient-gold);
  color: var(--navy);
  padding: 6px 14px;
  border-radius: 50px;
  font-size: 0.75rem;
  font-weight: 600;
  z-index: 2;
}

.post-card-content {
  padding: 24px;
}

.post-card-meta {
  display: flex;
  gap: 16px;
  margin-bottom: 16px;
  font-size: 0.85rem;
  color: var(--gray-600);
}

.post-card-date,
.post-card-reading-time {
  display: flex;
  align-items: center;
  gap: 6px;
}

.post-card-date i,
.post-card-reading-time i {
  color: var(--gold);
}

.post-card-title {
  font-size: 1.3rem;
  color: var(--navy);
  margin-bottom: 12px;
  font-weight: 600;
  line-height: 1.4;
}

.post-card-title a {
  color: inherit;
  transition: color 0.3s ease;
}

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

.post-card-excerpt {
  color: var(--gray-600);
  font-size: 0.95rem;
  line-height: 1.7;
  margin-bottom: 24px;
}

.post-card-footer {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding-top: 20px;
  border-top: 1px solid var(--gray-200);
}

.post-card-author {
  display: flex;
  align-items: center;
  gap: 10px;
}

.post-card-author img {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  object-fit: cover;
}

.post-card-author span {
  font-size: 0.9rem;
  font-weight: 500;
  color: var(--navy);
}

.post-card-link {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  color: var(--gold-dark);
  font-weight: 600;
  font-size: 0.9rem;
  transition: gap 0.3s ease;
}

.post-card-link:hover {
  gap: 10px;
  color: var(--navy);
}

/* No Posts Message */
.no-posts-message {
  grid-column: 1 / -1;
  text-align: center;
  padding: 80px 20px;
}

.no-posts-message i {
  font-size: 4rem;
  color: var(--gray-300);
  margin-bottom: 20px;
}

.no-posts-message h3 {
  font-size: 1.8rem;
  color: var(--navy);
  margin-bottom: 12px;
}

.no-posts-message p {
  color: var(--gray-600);
  font-size: 1.05rem;
}

/* ============================================
  PAGINATION
  ============================================ */
.pagination-container {
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 16px;
  margin-top: 60px;
}

.pagination-btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 12px 24px;
  background: var(--white);
  border: 2px solid var(--gray-200);
  border-radius: 12px;
  color: var(--navy);
  font-weight: 500;
  cursor: pointer;
  transition: all 0.3s ease;
}

.pagination-btn:hover:not(:disabled) {
  border-color: var(--gold);
  color: var(--gold-dark);
}

.pagination-btn:disabled {
  opacity: 0.4;
  cursor: not-allowed;
}

.pagination-numbers {
  display: flex;
  gap: 8px;
}

.pagination-number {
  width: 44px;
  height: 44px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--white);
  border: 2px solid var(--gray-200);
  border-radius: 12px;
  color: var(--navy);
  font-weight: 500;
  cursor: pointer;
  transition: all 0.3s ease;
}

.pagination-number:hover {
  border-color: var(--gold);
  color: var(--gold-dark);
}

.pagination-number.active {
  background: var(--navy);
  color: var(--white);
  border-color: var(--navy);
}

.pagination-dots {
  display: flex;
  align-items: center;
  color: var(--gray-400);
  padding: 0 8px;
}

/* ============================================
  NEWSLETTER CTA SECTION
  ============================================ */
.blog-newsletter-section {
  padding: 60px 0;
  background: var(--gray-50);
}

.newsletter-card {
  background: var(--gradient-navy);
  border-radius: 24px;
  padding: 50px;
  display: grid;
  grid-template-columns: auto 1fr auto;
  gap: 40px;
  align-items: center;
  box-shadow: var(--shadow-lg);
  position: relative;
  overflow: hidden;
}

.newsletter-card::before {
  content: '';
  position: absolute;
  top: -50%;
  right: -10%;
  width: 400px;
  height: 400px;
  background: radial-gradient(circle, rgba(201, 162, 39, 0.2), transparent);
  border-radius: 50%;
}

.newsletter-icon {
  width: 80px;
  height: 80px;
  background: var(--gradient-gold);
  border-radius: 20px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 2rem;
  color: var(--navy);
  position: relative;
  z-index: 2;
}

.newsletter-content {
  position: relative;
  z-index: 2;
}

.newsletter-content h2 {
  font-family: 'Poppins', serif;
  font-size: 1.8rem;
  color: var(--white);
  margin-bottom: 8px;
}

.newsletter-content p {
  color: var(--gray-400);
  font-size: 1rem;
}

.newsletter-form-inline {
  display: flex;
  gap: 12px;
  position: relative;
  z-index: 2;
}

.newsletter-form-inline input {
  flex: 1;
  min-width: 280px;
  padding: 16px 20px;
  background: rgba(255, 255, 255, 0.1);
  backdrop-filter: blur(10px);
  border: 1px solid rgba(255, 255, 255, 0.2);
  border-radius: 12px;
  color: var(--white);
  font-size: 0.95rem;
  font-family: 'Poppins', sans-serif;
  outline: none;
  transition: all 0.3s ease;
}

.newsletter-form-inline input::placeholder {
  color: var(--gray-400);
}

.newsletter-form-inline input:focus {
  border-color: var(--gold);
  background: rgba(255, 255, 255, 0.15);
}

.newsletter-submit-btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 16px 32px;
  background: var(--gradient-gold);
  color: var(--navy);
  border: none;
  border-radius: 12px;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.3s ease;
  white-space: nowrap;
}

.newsletter-submit-btn:hover {
  transform: translateY(-2px);
  box-shadow: var(--shadow-gold);
}

/* ============================================
  RESPONSIVE
  ============================================ */
@media (max-width: 1024px) {
  .featured-post {
    grid-template-columns: 1fr;
  }

  .featured-post-image {
    min-height: 350px;
  }

  .featured-post-content {
    padding: 40px;
  }

  .newsletter-card {
    grid-template-columns: 1fr;
    text-align: center;
    padding: 48px;
  }

  .newsletter-icon {
    margin: 0 auto;
  }

  .newsletter-form-inline {
    flex-direction: column;
  }

  .newsletter-form-inline input {
    min-width: 100%;
  }
}

@media (max-width: 768px) {
  .blog-hero-section {
    padding: 20px;
  }
  
  .blog-hero-bubble:nth-child(1) { width: 60px; height: 60px; }
  .blog-hero-bubble:nth-child(2) { width: 90px; height: 90px; }
  .blog-hero-bubble:nth-child(3) { width: 45px; height: 45px; }
  .blog-hero-bubble:nth-child(4) { width: 75px; height: 75px; }
  
  .scroll-indicator {
    bottom: 20px;
    font-size: 0.8rem;
  }
  
  .scroll-indicator i {
    font-size: 1.2rem;
  }
  
  .filter-section {
    padding: 20px 0;
    top: 70px;
  }
  
  .filter-wrapper {
    flex-direction: column;
    align-items: stretch;
  }

  .filter-categories {
    overflow-x: auto;
    flex-wrap: nowrap;
    padding-bottom: 8px;
  }

  .filter-sort {
    width: 100%;
  }

  .blog-posts-grid {
    grid-template-columns: 1fr;
  }

  .featured-post-content {
    padding: 32px;
  }

  .featured-post-title {
    font-size: 1.6rem;
  }

  .post-author-section {
    flex-direction: column;
    align-items: flex-start;
  }

  .newsletter-card {
    padding: 32px;
  }

  .newsletter-content h2 {
    font-size: 1.5rem;
  }

  .pagination-container {
    flex-wrap: wrap;
  }

  .pagination-numbers {
    order: 3;
    width: 100%;
    justify-content: center;
  }
  
  .blog-posts-section {
    padding: 50px 0;
  }
  
  .blog-newsletter-section {
    padding: 50px 0;
  }
}

@media (max-width: 576px) {
  .blog-hero-title {
    font-size: 1.8rem;
  }

  .featured-post-image {
    min-height: 250px;
  }

  .category-btn {
    font-size: 0.85rem;
    padding: 8px 16px;
  }

  .post-card-content {
    padding: 20px;
  }
  
  .blog-posts-section {
    padding: 40px 0;
  }
  
  .blog-newsletter-section {
    padding: 40px 0;
  }
}

/* Loading indicator */
.loading {
  text-align: center;
  padding: 2rem;
  font-size: 1.2rem;
  color: #666;
}

.loading::after {
  content: "";
  display: inline-block;
  width: 1rem;
  height: 1rem;
  border: 3px solid rgba(0, 0, 0, 0.1);
  border-radius: 50%;
  border-top-color: #333;
  animation: spin 1s ease-in-out infinite;
  margin-left: 0.5rem;
  vertical-align: middle;
}

@keyframes spin {
  to {
    transform: rotate(360deg);
  }
}