/* ============================================
   ESTILOS PRINCIPAIS - BLOG MEU LIVRO CAIXA
   ============================================ */

* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

html, body {
  height: 100%;
}

body {
  font-family: 'Open Sans', sans-serif;
  color: #666666;
  background-color: #ffffff;
  line-height: 1.6;
  font-size: 14px;
}

/* ============================================
   HEADER
   ============================================ */

header {
  background-color: #222222;
  padding: 20px 0;
  position: sticky;
  top: 0;
  z-index: 1000;
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}

.header-container {
  max-width: 1170px;
  margin: 0 auto;
  padding: 0 20px;
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.logo {
  font-size: 20px;
  font-weight: bold;
  color: #ffffff;
  text-decoration: none;
}

.logo span {
  color: #27a79a;
}

nav ul {
  list-style: none;
  display: flex;
  gap: 30px;
}

nav a {
  color: #ffffff;
  text-decoration: none;
  font-size: 14px;
  transition: color 0.3s ease;
}

nav a:hover {
  color: #27a79a;
}

/* ============================================
   CONTAINER PRINCIPAL
   ============================================ */

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

/* ============================================
   HERO SECTION (Blog Index)
   ============================================ */

.hero {
  background: linear-gradient(135deg, #27a79a 0%, #1e8a7f 100%);
  color: #ffffff;
  padding: 60px 20px;
  text-align: center;
  margin-bottom: 40px;
}

.hero h1 {
  font-size: 42px;
  margin-bottom: 15px;
  font-weight: 700;
}

.hero p {
  font-size: 18px;
  margin-bottom: 20px;
}

/* ============================================
   GRID DE ARTIGOS (Blog Index)
   ============================================ */

.blog-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
  gap: 30px;
  margin-bottom: 60px;
}

.article-card {
  background: #ffffff;
  border: 1px solid #e0e0e0;
  border-radius: 8px;
  overflow: hidden;
  transition: transform 0.3s ease, box-shadow 0.3s ease;
  display: flex;
  flex-direction: column;
}

.article-card:hover {
  transform: translateY(-5px);
  box-shadow: 0 8px 16px rgba(0, 0, 0, 0.1);
}

.article-card-image {
  width: 100%;
  height: 200px;
  background: linear-gradient(135deg, #27a79a 0%, #1e8a7f 100%);
  display: flex;
  align-items: center;
  justify-content: center;
  color: #ffffff;
  font-size: 48px;
}

.article-card-content {
  padding: 20px;
  flex-grow: 1;
  display: flex;
  flex-direction: column;
}

.article-card h3 {
  color: #333333;
  font-size: 18px;
  margin-bottom: 10px;
  line-height: 1.4;
}

.article-card p {
  color: #666666;
  font-size: 14px;
  margin-bottom: 15px;
  flex-grow: 1;
}

.article-card-meta {
  font-size: 12px;
  color: #999999;
  margin-bottom: 15px;
}

.article-card a {
  display: inline-block;
  background-color: #27a79a;
  color: #ffffff;
  padding: 10px 20px;
  text-decoration: none;
  border-radius: 4px;
  transition: background-color 0.3s ease;
  font-weight: 600;
}

.article-card a:hover {
  background-color: #1e8a7f;
}

/* ============================================
   ARTIGO (Página Individual)
   ============================================ */

.article-header {
  background-color: #f5f5f5;
  padding: 40px 20px;
  margin-bottom: 40px;
  border-bottom: 3px solid #27a79a;
}

.article-header h1 {
  color: #333333;
  font-size: 36px;
  margin-bottom: 15px;
  line-height: 1.3;
}

.article-meta {
  display: flex;
  gap: 20px;
  color: #999999;
  font-size: 13px;
  flex-wrap: wrap;
}

.article-meta span {
  display: flex;
  align-items: center;
  gap: 5px;
}

.article-content {
  max-width: 800px;
  margin: 0 auto 60px;
  line-height: 1.8;
}

.article-content h2 {
  color: #333333;
  font-size: 28px;
  margin: 40px 0 20px;
  padding-bottom: 10px;
  border-bottom: 2px solid #27a79a;
}

.article-content h3 {
  color: #333333;
  font-size: 22px;
  margin: 30px 0 15px;
}

.article-content p {
  margin-bottom: 15px;
  color: #666666;
  text-align: justify;
}

.article-content ul,
.article-content ol {
  margin: 20px 0 20px 30px;
  color: #666666;
}

.article-content li {
  margin-bottom: 10px;
  line-height: 1.6;
}

.article-content table {
  width: 100%;
  border-collapse: collapse;
  margin: 20px 0;
  border: 1px solid #ddd;
}

.article-content table th {
  background-color: #27a79a;
  color: #ffffff;
  padding: 12px;
  text-align: left;
  font-weight: 600;
}

.article-content table td {
  padding: 12px;
  border: 1px solid #ddd;
}

.article-content table tr:nth-child(even) {
  background-color: #f9f9f9;
}

.article-content a {
  color: #27a79a;
  text-decoration: none;
  font-weight: 600;
  transition: color 0.3s ease;
}

.article-content a:hover {
  color: #1e8a7f;
  text-decoration: underline;
}

.cta-box {
  background: linear-gradient(135deg, #27a79a 0%, #1e8a7f 100%);
  color: #ffffff;
  padding: 30px;
  border-radius: 8px;
  text-align: center;
  margin: 40px 0;
}

.cta-box h3 {
  color: #ffffff;
  margin-bottom: 15px;
  font-size: 22px;
}

.cta-box p {
  color: #ffffff;
  margin-bottom: 20px;
}

.cta-box a {
  display: inline-block;
  background-color: #ffffff;
  color: #27a79a;
  padding: 12px 30px;
  text-decoration: none;
  border-radius: 4px;
  font-weight: 700;
  transition: transform 0.3s ease;
}

.cta-box a:hover {
  transform: scale(1.05);
}

/* ============================================
   BREADCRUMB
   ============================================ */

.breadcrumb {
  padding: 15px 0;
  font-size: 13px;
  color: #999999;
}

.breadcrumb a {
  color: #27a79a;
  text-decoration: none;
}

.breadcrumb a:hover {
  text-decoration: underline;
}

/* ============================================
   SIDEBAR (Artigos Relacionados)
   ============================================ */

.related-articles {
  background-color: #f5f5f5;
  padding: 30px;
  border-radius: 8px;
  margin: 40px 0;
}

.related-articles h3 {
  color: #333333;
  margin-bottom: 20px;
  font-size: 20px;
}

.related-articles ul {
  list-style: none;
}

.related-articles li {
  margin-bottom: 15px;
  padding-bottom: 15px;
  border-bottom: 1px solid #ddd;
}

.related-articles li:last-child {
  border-bottom: none;
  margin-bottom: 0;
  padding-bottom: 0;
}

.related-articles a {
  color: #27a79a;
  text-decoration: none;
  font-weight: 600;
  transition: color 0.3s ease;
}

.related-articles a:hover {
  color: #1e8a7f;
}

/* ============================================
   FOOTER
   ============================================ */

footer {
  background-color: #222222;
  color: #ffffff;
  padding: 40px 20px;
  margin-top: 60px;
}

.footer-container {
  max-width: 1170px;
  margin: 0 auto;
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: 30px;
  margin-bottom: 30px;
}

.footer-section h4 {
  color: #27a79a;
  margin-bottom: 15px;
  font-size: 16px;
}

.footer-section ul {
  list-style: none;
}

.footer-section ul li {
  margin-bottom: 8px;
}

.footer-section a {
  color: #cccccc;
  text-decoration: none;
  transition: color 0.3s ease;
}

.footer-section a:hover {
  color: #27a79a;
}

.footer-bottom {
  text-align: center;
  padding-top: 20px;
  border-top: 1px solid #444444;
  color: #999999;
  font-size: 12px;
}

/* ============================================
   RESPONSIVIDADE
   ============================================ */

@media (max-width: 768px) {
  .header-container {
    flex-direction: column;
    gap: 15px;
  }

  nav ul {
    flex-direction: column;
    gap: 10px;
    text-align: center;
  }

  .hero h1 {
    font-size: 28px;
  }

  .article-header h1 {
    font-size: 24px;
  }

  .article-content h2 {
    font-size: 22px;
  }

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

  .footer-container {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 480px) {
  body {
    font-size: 13px;
  }

  .hero h1 {
    font-size: 22px;
  }

  .article-header h1 {
    font-size: 20px;
  }

  .article-content h2 {
    font-size: 18px;
  }

  nav ul {
    gap: 5px;
  }

  nav a {
    font-size: 12px;
  }
}
