/* 
 * Confluência dos Mundos - Estilo do Blog
 * Tema: Fantasia Medieval
 */

/* ===== HEADER DO BLOG ===== */
.blog-header {
  background: linear-gradient(rgba(10, 14, 23, 0.7), rgba(26, 43, 71, 0.7)), url('../assets/images/blog-header-bg.jpg');
  background-size: cover;
  background-position: center;
  color: var(--bege-pergaminho);
  padding: 8rem 0 4rem;
  text-align: center;
  position: relative;
  margin-bottom: 3rem;
}

.blog-header:after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 0;
  width: 100%;
  height: 50px;
  background: url('../assets/images/border-bottom.png') repeat-x;
  background-size: auto 100%;
}

.blog-header h1 {
  color: var(--dourado-antigo);
  text-shadow: 0 0 10px rgba(0, 0, 0, 0.5);
  margin-bottom: 1rem;
  font-size: 3rem;
}

.blog-header p {
  font-family: var(--fonte-subtitulos);
  font-style: italic;
  max-width: 700px;
  margin: 0 auto;
  font-size: 1.2rem;
}

/* ===== FILTROS DO BLOG ===== */
.blog-filters {
  display: flex;
  flex-wrap: wrap;
  gap: 2rem;
  margin-bottom: 3rem;
  padding: 1.5rem;
  background-color: rgba(26, 43, 71, 0.05);
  border-radius: var(--borda-arredondada);
}

.filter-group {
  flex: 1;
  min-width: 200px;
}

.filter-group h3 {
  margin-bottom: 1rem;
  font-size: 1.2rem;
  color: var(--azul-profundo);
}

.categories-filter,
.tags-filter {
  list-style: none;
  padding: 0;
  margin: 0;
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
}

.categories-filter li a,
.tags-filter li a {
  display: inline-block;
  padding: 0.5rem 1rem;
  background-color: white;
  border-radius: 30px;
  color: var(--azul-profundo);
  text-decoration: none;
  font-size: 0.9rem;
  transition: all 0.3s ease;
  border: 1px solid rgba(26, 43, 71, 0.1);
}

.categories-filter li a:hover,
.tags-filter li a:hover {
  background-color: rgba(201, 165, 92, 0.1);
  border-color: var(--dourado-antigo);
}

.categories-filter li a.active,
.tags-filter li a.active {
  background-color: var(--dourado-antigo);
  color: white;
  border-color: var(--dourado-antigo);
}

/* ===== POSTS CONTAINER ===== */
.posts-container {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(350px, 1fr));
  gap: 2rem;
  margin-bottom: 3rem;
}

/* ===== POST CARD ===== */
.post-card {
  background-color: white;
  border-radius: var(--borda-arredondada);
  overflow: hidden;
  box-shadow: 0 5px 15px rgba(0, 0, 0, 0.1);
  transition: all 0.3s ease;
  display: flex;
  flex-direction: column;
}

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

.post-card-image {
  height: 200px;
  overflow: hidden;
}

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

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

.post-card-content {
  padding: 1.5rem;
  display: flex;
  flex-direction: column;
  flex-grow: 1;
}

.post-meta {
  display: flex;
  justify-content: space-between;
  margin-bottom: 1rem;
  font-size: 0.9rem;
}

.post-category {
  background-color: var(--roxo-mistico);
  color: white;
  padding: 0.2rem 0.5rem;
  border-radius: 3px;
}

.post-date {
  color: var(--cinza-pedra);
}

.post-title {
  margin-bottom: 1rem;
  font-size: 1.5rem;
}

.post-title a {
  color: var(--azul-profundo);
  text-decoration: none;
  transition: color 0.3s ease;
}

.post-title a:hover {
  color: var(--roxo-mistico);
}

.post-summary {
  margin-bottom: 1.5rem;
  color: var(--cinza-pedra);
  line-height: 1.6;
  flex-grow: 1;
}

.post-footer {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-top: auto;
}

.read-more {
  color: var(--roxo-mistico);
  font-weight: 700;
  text-decoration: none;
  position: relative;
}

.read-more:after {
  content: '';
  position: absolute;
  width: 100%;
  height: 2px;
  bottom: -2px;
  left: 0;
  background-color: var(--roxo-mistico);
  transform: scaleX(0);
  transform-origin: bottom right;
  transition: transform 0.3s ease;
}

.read-more:hover:after {
  transform: scaleX(1);
  transform-origin: bottom left;
}

.post-author {
  font-style: italic;
  color: var(--cinza-pedra);
  font-size: 0.9rem;
}

/* ===== PAGINAÇÃO ===== */
.pagination {
  display: flex;
  justify-content: center;
  gap: 0.5rem;
  margin: 3rem 0;
}

.pagination a {
  display: inline-block;
  padding: 0.5rem 1rem;
  background-color: white;
  border-radius: var(--borda-arredondada);
  color: var(--azul-profundo);
  text-decoration: none;
  transition: all 0.3s ease;
  border: 1px solid rgba(26, 43, 71, 0.1);
}

.pagination a:hover {
  background-color: rgba(201, 165, 92, 0.1);
  border-color: var(--dourado-antigo);
}

.pagination a.active {
  background-color: var(--dourado-antigo);
  color: white;
  border-color: var(--dourado-antigo);
}

/* ===== PÁGINA DE POST INDIVIDUAL ===== */
.post-container {
  max-width: 900px;
  margin: 0 auto;
  padding: 2rem 1rem;
}

.post-navigation {
  margin-bottom: 2rem;
  color: var(--cinza-pedra);
  font-size: 0.9rem;
}

.post-navigation a {
  color: var(--azul-profundo);
  text-decoration: none;
  transition: color 0.3s ease;
}

.post-navigation a:hover {
  color: var(--roxo-mistico);
}

.post-content {
  background-color: white;
  border-radius: var(--borda-arredondada);
  padding: 2rem;
  box-shadow: 0 5px 15px rgba(0, 0, 0, 0.1);
  margin-bottom: 2rem;
}

.post-header {
  margin-bottom: 2rem;
}

.post-header h1 {
  font-size: 2.5rem;
  margin-bottom: 1rem;
  color: var(--azul-profundo);
}

.post-header .post-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 1rem;
  margin-bottom: 2rem;
}

.post-cover {
  margin: 0 -2rem 2rem;
  height: 400px;
  overflow: hidden;
}

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

.post-content p {
  margin-bottom: 1.5rem;
  line-height: 1.7;
}

.post-content .capitular:first-letter {
  float: left;
  font-size: 3.5rem;
  line-height: 0.8;
  margin-right: 0.5rem;
  color: var(--roxo-mistico);
  font-family: var(--fonte-titulos);
}

.post-content h2 {
  font-size: 2rem;
  margin: 2.5rem 0 1.5rem;
  color: var(--azul-profundo);
}

.post-content h3 {
  font-size: 1.5rem;
  margin: 2rem 0 1rem;
  color: var(--azul-profundo);
}

.post-content blockquote {
  margin: 2rem 0;
  padding: 1.5rem;
  background-color: rgba(26, 43, 71, 0.05);
  border-left: 4px solid var(--dourado-antigo);
  font-style: italic;
  color: var(--azul-profundo);
}

.post-content ul,
.post-content ol {
  margin: 1.5rem 0;
  padding-left: 2rem;
}

.post-content li {
  margin-bottom: 0.5rem;
}

.post-content figure {
  margin: 2rem 0;
}

.post-content figure img {
  width: 100%;
  border-radius: var(--borda-arredondada);
}

.post-content figcaption {
  text-align: center;
  margin-top: 0.5rem;
  font-style: italic;
  color: var(--cinza-pedra);
  font-size: 0.9rem;
}

.post-content a {
  color: var(--roxo-mistico);
  text-decoration: none;
  border-bottom: 1px solid var(--roxo-mistico);
  transition: all 0.3s ease;
}

.post-content a:hover {
  color: var(--azul-profundo);
  border-color: var(--azul-profundo);
}

.post-footer {
  margin-top: 3rem;
  padding-top: 1.5rem;
  border-top: 1px solid rgba(26, 43, 71, 0.1);
}

.post-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  align-items: center;
}

.post-tags span {
  font-weight: 700;
  color: var(--azul-profundo);
}

.post-tags a {
  display: inline-block;
  padding: 0.3rem 0.8rem;
  background-color: rgba(26, 43, 71, 0.05);
  border-radius: 30px;
  color: var(--azul-profundo);
  text-decoration: none;
  font-size: 0.9rem;
  transition: all 0.3s ease;
  border: none;
}

.post-tags a:hover {
  background-color: rgba(201, 165, 92, 0.1);
  color: var(--dourado-antigo);
}

.post-navigation-links {
  display: flex;
  justify-content: space-between;
  margin-bottom: 3rem;
}

.prev-post,
.next-post {
  color: var(--azul-profundo);
  text-decoration: none;
  transition: color 0.3s ease;
  max-width: 45%;
}

.prev-post:hover,
.next-post:hover {
  color: var(--roxo-mistico);
}

.related-posts {
  margin-bottom: 3rem;
}

.related-posts h3 {
  margin-bottom: 1.5rem;
  color: var(--azul-profundo);
  font-size: 1.5rem;
}

.related-posts-container {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));
  gap: 1.5rem;
}

.related-post {
  background-color: white;
  border-radius: var(--borda-arredondada);
  overflow: hidden;
  box-shadow: 0 5px 15px rgba(0, 0, 0, 0.1);
  transition: all 0.3s ease;
}

.related-post:hover {
  transform: translateY(-5px);
  box-shadow: 0 10px 20px rgba(0, 0, 0, 0.15);
}

.related-post-image {
  height: 150px;
  overflow: hidden;
}

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

.related-post:hover .related-post-image img {
  transform: scale(1.05);
}

.related-post-content {
  padding: 1rem;
}

.related-post-title {
  margin-bottom: 0.5rem;
  font-size: 1.1rem;
}

.related-post-title a {
  color: var(--azul-profundo);
  text-decoration: none;
  transition: color 0.3s ease;
}

.related-post-title a:hover {
  color: var(--roxo-mistico);
}

.related-post-date {
  color: var(--cinza-pedra);
  font-size: 0.9rem;
}

/* ===== RESPONSIVIDADE ===== */
@media (max-width: 992px) {
  .posts-container {
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
  }
  
  .post-header h1 {
    font-size: 2rem;
  }
  
  .post-cover {
    height: 300px;
  }
}

@media (max-width: 768px) {
  .blog-header {
    padding: 6rem 0 3rem;
  }
  
  .blog-header h1 {
    font-size: 2.5rem;
  }
  
  .posts-container {
    grid-template-columns: 1fr;
  }
  
  .post-content {
    padding: 1.5rem;
  }
  
  .post-cover {
    margin: 0 -1.5rem 1.5rem;
    height: 250px;
  }
  
  .post-content h2 {
    font-size: 1.8rem;
  }
  
  .post-content h3 {
    font-size: 1.3rem;
  }
  
  .related-posts-container {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 576px) {
  .blog-header h1 {
    font-size: 2rem;
  }
  
  .blog-header p {
    font-size: 1rem;
  }
  
  .post-header h1 {
    font-size: 1.8rem;
  }
  
  .post-cover {
    height: 200px;
  }
  
  .post-navigation-links {
    flex-direction: column;
    gap: 1rem;
  }
  
  .prev-post,
  .next-post {
    max-width: 100%;
  }
}

