/* Estilos generales */
body {
  font-family: "Roboto", "Open Sans", sans-serif;
  line-height: 1.6;
  color: #333;
  background-color: #f4f4f4;
  margin: 0;
  padding: 0;
}

#blog-content {
  max-width: 1200px;
  margin: 0 auto;
  padding: 20px;
  display: flex;
  justify-content: space-between;
}

.blog-main {
  width: 70%;
}

.blog-sidebar {
  width: 25%;
}

/* Título principal */
.blog-titulo {
  font-family: "Montserrat", sans-serif;
  text-align: center;
  margin: 60px 0 40px;
  padding: 20px;
  background-color: #f8f8f8;
  position: relative;
}

.blog-titulo::after {
  content: "";
  position: absolute;
  bottom: 0;
  left: 50%;
  transform: translateX(-50%);
  width: 100px;
  height: 3px;
  background: linear-gradient(to right, #0066cc, #00cc99);
}

.blog-titulo h1 {
  font-size: 2.6em;
  font-weight: 700;
  margin-bottom: 15px;
  color: #333;
  text-transform: none;
  letter-spacing: -0.5px;
}

.blog-titulo span {
  font-size: 1.3em;
  font-weight: 300;
  color: #555;
  display: block;
  margin-top: 10px;
  line-height: 1.4;
}

/* Estilos para los posts */
.blog-post {
  background-color: #ffffff;
  border-radius: 8px;
  box-shadow: 0 4px 6px rgba(0, 0, 0, 0.05);
  margin-bottom: 40px;
  overflow: hidden;
  transition: all 0.3s ease;
}

.blog-post:hover {
  box-shadow: 0 6px 12px rgba(0, 0, 0, 0.1);
  transform: translateY(-5px);
}

.blog-post h2 {
  font-family: "Montserrat", sans-serif;
  font-size: 1.6em;
  font-weight: 600;
  margin: 0;
  padding: 20px 25px;
  background-color: #f8f8f8;
  border-bottom: 2px solid #e0e0e0;
}

.blog-post h2 a {
  color: #333;
  text-decoration: none;
  transition: color 0.3s ease;
}

.blog-post h2 a:hover {
  color: #0066cc;
}

.post-meta {
  font-size: 0.9em;
  color: #666;
  padding: 15px 25px;
  border-bottom: 1px solid #eee;
}

.author-avatar {
  width: 30px;
  height: 30px;
  border-radius: 50%;
  margin-right: 10px;
  vertical-align: middle;
}

.post-image {
  max-width: 100%;
  height: auto;
  border-radius: 8px 8px 0 0;
}

.post-excerpt {
  padding: 20px 25px;
}

.read-more {
  display: inline-block;
  background-color: #0066cc;
  color: white;
  padding: 10px 20px;
  text-decoration: none;
  border-radius: 30px;
  font-weight: bold;
  margin: 0 25px 25px;
  transition: background-color 0.3s ease, transform 0.3s ease;
}

.read-more:hover {
  background-color: #0052a3;
  transform: scale(1.05);
}

/* Estilos para las categorías */
.blog-sidebar h3 {
  font-family: "Montserrat", sans-serif;
  font-size: 1.4em;
  font-weight: 600;
  color: #333;
  margin-bottom: 20px;
  padding-bottom: 10px;
  border-bottom: 2px solid #e0e0e0;
  position: relative;
}

.blog-sidebar h3::after {
  content: "";
  position: absolute;
  bottom: -2px;
  left: 0;
  width: 50px;
  height: 2px;
  background: linear-gradient(to right, #0066cc, #00cc99);
}

.blog-categories {
  list-style-type: none;
  padding: 0;
}

.blog-categories li {
  margin-bottom: 10px;
}

.blog-categories a {
  color: #333;
  text-decoration: none;
  transition: color 0.3s ease;
}

.blog-categories a:hover {
  color: #0066cc;
}

/* Estilos para la página individual de post */
.post-content {
  line-height: 1.8;
  padding: 25px;
}

.post-tags {
  margin-top: 20px;
  padding: 0 25px;
}

.tag {
  display: inline-block;
  background-color: #f1f1f1;
  padding: 5px 10px;
  margin-right: 5px;
  margin-bottom: 5px;
  border-radius: 20px;
  color: #333;
  text-decoration: none;
  font-size: 0.9em;
  transition: background-color 0.3s ease;
}

.tag:hover {
  background-color: #e0e0e0;
}

.author-bio {
  background-color: #f9f9f9;
  padding: 25px;
  margin-top: 30px;
  border-radius: 8px;
}

/* Paginación */
.pagination {
  text-align: center;
  margin-top: 40px;
}

.pagination a {
  display: inline-block;
  padding: 8px 16px;
  margin: 0 5px;
  background-color: #fff;
  color: #333;
  text-decoration: none;
  border-radius: 4px;
  transition: background-color 0.3s ease, color 0.3s ease;
}

.pagination a:hover,
.pagination a.active {
  background-color: #0066cc;
  color: #fff;
}

/* Formulario de búsqueda */
.blog-search {
  margin-bottom: 30px;
}

.blog-search input[type="text"] {
  width: calc(100% - 22px);
  padding: 10px;
  border: 1px solid #ddd;
  border-radius: 4px;
  font-size: 1em;
}

.blog-search button {
  display: block;
  width: 100%;
  padding: 10px;
  margin-top: 10px;
  background-color: #0066cc;
  color: white;
  border: none;
  border-radius: 4px;
  cursor: pointer;
  font-size: 1em;
  transition: background-color 0.3s ease;
}

.blog-search button:hover {
  background-color: #0052a3;
}

/* Estilos adicionales para post.php */
.back-to-blog {
  display: inline-block;
  margin-bottom: 20px;
  color: #0066cc;
  text-decoration: none;
  font-weight: bold;
  transition: color 0.3s ease;
}

.back-to-blog:hover {
  color: #0052a3;
}

.post-views {
  margin-left: 15px;
  font-style: italic;
}

/* Responsive design */
@media (max-width: 768px) {
  #blog-content {
    flex-direction: column;
  }

  .blog-main,
  .blog-sidebar {
    width: 100%;
  }

  .blog-titulo h1 {
    font-size: 2em;
  }

  .blog-titulo span {
    font-size: 1.1em;
  }

  .blog-post h2 {
    font-size: 1.4em;
  }
}
