/* Reset et base */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

body {
  font-family: 'Comic Neue', cursive;
  line-height: 1.6;
  color: #333;
  background-color: #f8f9fa;
}

.container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 20px;
}

/* Section header améliorée */
.section-header {
  text-align: center;
  margin-bottom: 60px;
  position: relative;
}

.comic-title {
  font-family: 'Bangers', cursive;
  font-size: 4em;
  color: #fff;
  text-shadow: 
    4px 4px 0 #333,
    8px 8px 0 rgba(0,0,0,0.2);
  margin-bottom: 20px;
  position: relative;
  display: inline-block;
}

.comic-title::before {
  content: '';
  position: absolute;
  top: -10px;
  left: -10px;
  right: -10px;
  bottom: -10px;
  background: linear-gradient(45deg, #ff6b6b, #4ecdc4, #45b7b8, #96ceb4);
  background-size: 400% 400%;
  border-radius: 20px;
  z-index: -1;
  animation: gradientShift 3s ease infinite;
  filter: blur(8px);
}

@keyframes gradientShift {
  0%, 100% { background-position: 0% 50%; }
  50% { background-position: 100% 50%; }
}

.comic-subtitle {
  font-size: 1.4em;
  color: #fff;
  text-shadow: 2px 2px 0 #333;
  background: rgba(255,255,255,0.1);
  padding: 10px 20px;
  border-radius: 25px;
  display: inline-block;
  backdrop-filter: blur(10px);
  border: 2px solid rgba(255,255,255,0.2);
}

/* Blog Section */
.blog-section {
    padding: 100px 0;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 50%, #f093fb 100%);
    position: relative;
    min-height: 100vh;
}

.section-header {
    text-align: center;
    margin-bottom: 50px;
}

.comic-title {
    font-family: 'Bangers', cursive;
    font-size: 3.5rem;
    color: #fff;
    text-shadow: 
        4px 4px 0px #000,
        -1px -1px 0px #000,
        1px -1px 0px #000,
        -1px 1px 0px #000,
        1px 1px 0px #000;
    margin-bottom: 20px;
    text-align: center;
}

/* Filtres et recherche */
.blog-filters {
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(10px);
    padding: 30px;
    border-radius: 20px;
    border: 4px solid #333;
    margin-bottom: 50px;
    box-shadow: 0 8px 16px rgba(0,0,0,0.2);
}

.filter-controls {
    display: flex;
    gap: 30px;
    align-items: flex-end;
    flex-wrap: wrap;
}

.sort-filter {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.sort-filter label {
    font-family: 'Bangers', cursive;
    font-size: 1.2em;
    color: #333;
    text-transform: uppercase;
}

.filter-select {
    padding: 12px 15px;
    border: 3px solid #333;
    border-radius: 15px;
    font-family: 'Comic Neue', cursive;
    font-size: 1em;
    background: #fff;
    cursor: pointer;
    transition: all 0.3s ease;
}

.filter-select:focus {
    outline: none;
    border-color: #667eea;
    box-shadow: 0 0 10px rgba(102, 126, 234, 0.3);
}

.search-container {
    position: relative;
    flex: 1;
    max-width: 400px;
}

.search-input {
    width: 100%;
    padding: 15px 45px 15px 20px;
    border: 3px solid #333;
    border-radius: 25px;
    font-family: 'Comic Neue', cursive;
    font-size: 1em;
    background: #fff;
    transition: all 0.3s ease;
}

.search-input:focus {
    outline: none;
    border-color: #667eea;
    box-shadow: 0 0 15px rgba(102, 126, 234, 0.3);
}

.clear-search {
    position: absolute;
    right: 15px;
    top: 50%;
    transform: translateY(-50%);
    background: none;
    border: none;
    font-size: 1.2em;
    color: #999;
    cursor: pointer;
    padding: 5px;
    border-radius: 50%;
    transition: all 0.3s ease;
}

.clear-search:hover {
    color: #333;
    background: #f0f0f0;
}

.search-suggestions {
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    background: #fff;
    border: 3px solid #333;
    border-top: none;
    border-radius: 0 0 15px 15px;
    max-height: 200px;
    overflow-y: auto;
    z-index: 100;
    display: none;
    box-shadow: 0 4px 8px rgba(0,0,0,0.2);
}

.suggestion-item {
    padding: 12px 20px;
    cursor: pointer;
    transition: background-color 0.2s ease;
    border-bottom: 1px solid #eee;
}

.suggestion-item:hover,
.suggestion-item.highlighted {
    background-color: #667eea;
    color: #fff;
}

.suggestion-item:last-child {
    border-bottom: none;
}

.results-info {
    display: flex;
    align-items: center;
    margin-left: auto;
}

.results-info span {
    font-family: 'Bangers', cursive;
    font-size: 1.1em;
    color: #333;
    background: #f8f9fa;
    padding: 8px 15px;
    border-radius: 20px;
    border: 2px solid #dee2e6;
}

/* Grille blog responsive */
.blog-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(380px, 1fr));
  gap: 40px;
  margin-top: 60px;
  position: relative;
  z-index: 2;
}

/* Cartes blog super stylées */
.blog-card {
  background: rgba(255, 255, 255, 0.95);
  backdrop-filter: blur(10px);
  border-radius: 20px;
  border: 4px solid #333;
  overflow: hidden;
  box-shadow: 0 8px 16px rgba(0,0,0,0.2);
  transition: all 0.3s ease;
  opacity: 1;
  transform: translateY(0);
}

.blog-card::before {
  content: '';
  position: absolute;
  top: -2px;
  left: -2px;
  right: -2px;
  bottom: -2px;
  background: linear-gradient(45deg, #ff6b6b, #4ecdc4, #45b7b8, #96ceb4);
  background-size: 400% 400%;
  border-radius: 25px;
  z-index: -1;
  opacity: 0;
  transition: opacity 0.3s ease;
  animation: gradientShift 3s ease infinite;
}

.blog-card:hover {
  transform: translateY(-10px);
  box-shadow: 0 15px 30px rgba(0,0,0,0.3);
}

.blog-card:hover::before {
  opacity: 1;
}

.blog-image {
  width: 100%;
  height: 250px;
  object-fit: cover;
  border-bottom: 4px solid #333;
  transition: transform 0.4s ease;
  position: relative;
}

.blog-card:hover .blog-image {
  transform: scale(1.05);
}

.blog-content {
  padding: 30px;
  position: relative;
  background: linear-gradient(145deg, #ffffff 0%, #f8f9fa 100%);
}

.blog-meta {
  color: #666;
  font-size: 0.9em;
  margin-bottom: 20px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 10px 0;
  border-bottom: 2px solid #eee;
}

.blog-date {
  font-weight: bold;
  color: #333;
  background: linear-gradient(45deg, #667eea, #764ba2);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.blog-author {
  background: linear-gradient(45deg, #4ecdc4, #44a08d);
  color: #fff;
  padding: 6px 15px;
  border-radius: 20px;
  font-size: 0.8em;
  font-weight: bold;
  text-shadow: 1px 1px 0 rgba(0,0,0,0.3);
  border: 2px solid #333;
  box-shadow: 0 2px 4px rgba(0,0,0,0.2);
}

.blog-card-title {
  font-family: 'Bangers', cursive;
  font-size: 2em;
  color: #333;
  margin-bottom: 20px;
  line-height: 1.2;
  text-shadow: 2px 2px 0 rgba(0,0,0,0.1);
  position: relative;
}

.blog-card-title::after {
  content: '';
  position: absolute;
  bottom: -5px;
  left: 0;
  width: 50px;
  height: 3px;
  background: linear-gradient(45deg, #ff6b6b, #4ecdc4);
  border-radius: 2px;
  transition: width 0.3s ease;
}

.blog-card:hover .blog-card-title::after {
  width: 100px;
}

.blog-excerpt {
  color: #555;
  line-height: 1.7;
  margin-bottom: 25px;
  font-size: 1.05em;
}

.blog-read-more {
  display: inline-block;
  background: linear-gradient(45deg, #ff6b6b, #ff5252);
  color: #fff;
  padding: 12px 25px;
  border-radius: 25px;
  text-decoration: none;
  font-family: 'Bangers', cursive;
  font-size: 1.2em;
  border: 3px solid #333;
  transition: all 0.3s ease;
  text-shadow: 2px 2px 0 #333;
  box-shadow: 0 4px 8px rgba(0,0,0,0.2);
  position: relative;
  overflow: hidden;
}

.blog-read-more::before {
  content: '';
  position: absolute;
  top: 0;
  left: -100%;
  width: 100%;
  height: 100%;
  background: linear-gradient(90deg, transparent, rgba(255,255,255,0.3), transparent);
  transition: left 0.5s ease;
}

.blog-read-more:hover::before {
  left: 100%;
}

.blog-read-more:hover {
  background: linear-gradient(45deg, #ff5252, #ff4444);
  transform: translateY(-3px) scale(1.05);
  box-shadow: 0 6px 12px rgba(0,0,0,0.3);
}

/* Messages d'état */
.no-articles {
  text-align: center;
  padding: 80px 40px;
  color: #fff;
  font-family: 'Comic Neue', cursive;
  font-size: 1.4em;
  background: rgba(255,255,255,0.1);
  backdrop-filter: blur(10px);
  border-radius: 25px;
  border: 3px solid rgba(255,255,255,0.2);
  box-shadow: 0 8px 16px rgba(0,0,0,0.2);
}

.no-articles p:first-child {
  font-family: 'Bangers', cursive;
  font-size: 1.5em;
  margin-bottom: 20px;
  text-shadow: 2px 2px 0 rgba(0,0,0,0.3);
}

.alert {
  padding: 20px;
  border-radius: 15px;
  margin-bottom: 30px;
  border: 3px solid #333;
  font-weight: bold;
  text-align: center;
}

.alert-error {
  background: #ff6b6b;
  color: #fff;
  text-shadow: 1px 1px 0 #333;
}

/* Bouton retour */
.back-to-home {
  text-align: center;
  margin-top: 60px;
  position: relative;
  z-index: 2;
}

.back-to-home a {
  display: inline-block;
  background: rgba(255, 255, 255, 0.9);
  color: #333;
  padding: 15px 30px;
  border-radius: 25px;
  text-decoration: none;
  font-family: 'Bangers', cursive;
  font-size: 1.2em;
  border: 3px solid #333;
  transition: all 0.3s ease;
  text-transform: uppercase;
  text-shadow: 2px 2px 0 #333;
  box-shadow: 0 6px 12px rgba(0,0,0,0.3);
  position: relative;
  overflow: hidden;
}

.back-to-home a::before {
  content: '';
  position: absolute;
  top: 0;
  left: -100%;
  width: 100%;
  height: 100%;
  background: linear-gradient(90deg, transparent, rgba(255,255,255,0.3), transparent);
  transition: left 0.5s ease;
}

.back-to-home a:hover::before {
  left: 100%;
}

.back-to-home a:hover {
  background: #fff;
  transform: translateY(-3px);
  box-shadow: 0 6px 12px rgba(0,0,0,0.2);
}

/* Responsive design */
@media (max-width: 768px) {
  .comic-title {
    font-size: 2.5em;
  }
  
  .comic-subtitle {
    font-size: 1.1em;
    padding: 8px 16px;
  }
  
  .filter-controls {
        flex-direction: column;
        align-items: stretch;
        gap: 20px;
    }
    
    .results-info {
        margin-left: 0;
        margin-top: 15px;
        justify-content: center;
    }
    
    .search-container {
        max-width: none;
    }
  
  .blog-grid {
    grid-template-columns: 1fr;
    gap: 30px;
  }
  
  .blog-card {
    border-radius: 20px;
  }
  
  .blog-content {
    padding: 25px;
  }
  
  .blog-filters {
    padding: 20px;
  }
  
  .blog-card-title {
    font-size: 1.6em;
  }
  
  .blog-section {
    padding: 60px 0;
  }
  
  .no-articles {
    padding: 60px 20px;
    font-size: 1.2em;
  }
}

@media (max-width: 480px) {
  .container {
    padding: 0 15px;
  }
  
  .comic-title {
    font-size: 2em;
  }
  
  .blog-card-title {
    font-size: 1.5em;
  }
  
  .blog-content {
    padding: 20px;
  }
}