:root {
  --brand: #416f52;
  --brand-dark: #294936;
  --brand-soft: #6f9078;
  --cream: #f7f5f0;
  --beige: #e8dfd2;
  --ink: #252925;
  --line: rgba(37, 41, 37, 0.12);
}

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

html {
  -webkit-text-size-adjust: 100%;
}

body {
  background: var(--cream);
  color: var(--ink);
  font-family: 'Manrope', system-ui, -apple-system, 'Segoe UI', sans-serif;
  font-size: 17px;
  line-height: 1.75;
  -webkit-font-smoothing: antialiased;
}

a {
  color: var(--brand);
}

img {
  max-width: 100%;
  display: block;
}

/* Header */
.site-head {
  position: sticky;
  top: 0;
  z-index: 20;
  background: rgba(41, 73, 54, 0.97);
  backdrop-filter: blur(8px);
}
.site-head .wrap {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 72px;
}
.site-head img {
  height: 42px;
  width: auto;
}
.site-head nav {
  display: flex;
  gap: 22px;
  align-items: center;
}
.site-head nav a {
  color: rgba(247, 245, 240, 0.85);
  text-decoration: none;
  font-size: 0.82rem;
  font-weight: 500;
  letter-spacing: 0.02em;
}
.site-head nav a:hover {
  color: #fff;
}
.site-head nav a.cta {
  border: 1px solid rgba(247, 245, 240, 0.35);
  padding: 8px 16px;
  border-radius: 999px;
}

/* Layout */
.wrap {
  max-width: 1080px;
  margin: 0 auto;
  padding: 0 22px;
}
.narrow {
  max-width: 720px;
}

.hero-blog {
  padding-block: clamp(88px, 9vw, 128px) 44px;
  text-align: center;
}
.hero-blog .eyebrow {
  font-size: 0.66rem;
  font-weight: 600;
  letter-spacing: 0.28em;
  text-transform: uppercase;
  color: var(--brand);
}
.hero-blog h1 {
  font-family: 'Cormorant Garamond', Georgia, serif;
  font-weight: 500;
  font-size: clamp(2.6rem, 7vw, 4rem);
  line-height: 1.02;
  letter-spacing: -0.01em;
  margin-top: 14px;
}
.hero-blog p {
  max-width: 620px;
  margin: 18px auto 0;
  color: rgba(37, 41, 37, 0.62);
}

/* Ferramentas: busca e categorias */
.blog-tools {
  margin: 6px 0 16px;
}
.blog-search {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  max-width: 680px;
}
.blog-search input[type='search'] {
  flex: 1 1 220px;
  padding: 13px 20px;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: #fff;
  font: inherit;
  font-size: 0.95rem;
  color: var(--ink);
}
.blog-select {
  flex: 0 0 auto;
  padding: 13px 42px 13px 18px;
  border: 1px solid var(--line);
  border-radius: 999px;
  background-color: #fff;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='10' height='6' viewBox='0 0 10 6'%3E%3Cpath d='M1 1l4 4 4-4' fill='none' stroke='%23416f52' stroke-width='1.6' stroke-linecap='round'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 16px center;
  font: inherit;
  font-size: 0.9rem;
  color: var(--ink);
  appearance: none;
  -webkit-appearance: none;
  cursor: pointer;
}
.blog-search input[type='search']:focus,
.blog-select:focus {
  outline: none;
  border-color: var(--brand);
  box-shadow: 0 0 0 3px rgba(65, 111, 82, 0.12);
}
.blog-search-btn {
  flex: 0 0 auto;
  padding: 13px 26px;
  border: 0;
  border-radius: 999px;
  background: var(--brand);
  color: #fff;
  font: inherit;
  font-weight: 600;
  font-size: 0.9rem;
  cursor: pointer;
  transition: background 0.2s;
}
.blog-search-btn:hover {
  background: var(--brand-dark);
}
.blog-result {
  font-size: 0.85rem;
  color: rgba(37, 41, 37, 0.6);
  margin-bottom: 22px;
}

/* Paginação */
.pagination {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 14px;
  flex-wrap: wrap;
  padding: 4px 0 96px;
}
.page-link {
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--brand);
  text-decoration: none;
}
.page-link.is-disabled {
  color: rgba(37, 41, 37, 0.3);
  pointer-events: none;
}
.pages {
  display: flex;
  gap: 6px;
}
.page-num {
  min-width: 38px;
  height: 38px;
  padding: 0 6px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 999px;
  border: 1px solid var(--line);
  background: #fff;
  color: var(--ink);
  text-decoration: none;
  font-size: 0.85rem;
}
.page-num:hover {
  border-color: var(--brand);
  color: var(--brand);
}
.page-num.is-active {
  background: var(--brand);
  border-color: var(--brand);
  color: #fff;
}

/* Grid de posts */
.posts {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
  gap: 30px;
  padding: 28px 0 44px;
}
.card-post {
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 18px;
  overflow: hidden;
  text-decoration: none;
  color: inherit;
  display: flex;
  flex-direction: column;
  transition: transform 0.4s cubic-bezier(0.22, 1, 0.36, 1), box-shadow 0.4s;
}
.card-post:hover {
  transform: translateY(-4px);
  box-shadow: 0 30px 60px -40px rgba(41, 73, 54, 0.55);
}
.card-post .thumb {
  aspect-ratio: 16 / 10;
  overflow: hidden;
  background: linear-gradient(135deg, #e8dfd2, #d3c7b4);
}
.card-post .thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}
.card-post .body {
  padding: 22px 22px 26px;
}
.card-post .cat {
  font-size: 0.64rem;
  font-weight: 600;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--brand);
}
.card-post h2 {
  font-family: 'Cormorant Garamond', Georgia, serif;
  font-weight: 500;
  font-size: 1.55rem;
  line-height: 1.15;
  margin: 10px 0 10px;
}
.card-post p {
  font-size: 0.9rem;
  line-height: 1.6;
  color: rgba(37, 41, 37, 0.6);
}
.card-post .date {
  margin-top: 16px;
  font-size: 0.74rem;
  color: rgba(37, 41, 37, 0.45);
}

/* Post individual */
.article-head {
  padding: clamp(80px, 9vw, 120px) 0 12px;
  text-align: center;
}
.article-head .cat {
  font-size: 0.66rem;
  font-weight: 600;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--brand);
}
.article-head h1 {
  font-family: 'Cormorant Garamond', Georgia, serif;
  font-weight: 500;
  font-size: clamp(2.3rem, 6vw, 3.6rem);
  line-height: 1.05;
  letter-spacing: -0.01em;
  margin: 16px 0;
}
.article-head .meta {
  font-size: 0.82rem;
  color: rgba(37, 41, 37, 0.5);
}
.article-cover {
  margin: 36px 0 8px;
  border-radius: 20px;
  overflow: hidden;
  box-shadow: 0 40px 80px -50px rgba(41, 73, 54, 0.55);
}
.article-cover img {
  width: 100%;
}

.article-body {
  padding: 28px 0 40px;
}
.article-body h2 {
  font-family: 'Cormorant Garamond', Georgia, serif;
  font-weight: 500;
  font-size: 2rem;
  line-height: 1.15;
  margin: 40px 0 14px;
}
.article-body h3 {
  font-size: 1.15rem;
  font-weight: 700;
  margin: 30px 0 10px;
}
.article-body p {
  margin: 0 0 20px;
}
.article-body ul {
  margin: 0 0 22px;
  padding-left: 22px;
}
.article-body ol {
  margin: 0 0 22px;
  padding-left: 22px;
}
.article-body li {
  margin-bottom: 8px;
}
.article-body a {
  text-decoration: underline;
}
.article-body img {
  border-radius: 16px;
  margin: 8px 0;
}
.article-body figure {
  margin: 28px 0;
}
.article-body figcaption {
  font-size: 0.82rem;
  color: rgba(37, 41, 37, 0.5);
  text-align: center;
  margin-top: 10px;
}
.article-body blockquote {
  margin: 0 0 22px;
  padding: 6px 0 6px 20px;
  border-left: 3px solid var(--brand-soft);
  color: rgba(37, 41, 37, 0.72);
  font-style: italic;
}
.article-body hr {
  border: 0;
  border-top: 1px solid var(--line);
  margin: 32px 0;
}
.article-body table {
  width: 100%;
  border-collapse: collapse;
  margin: 0 0 24px;
  font-size: 0.95rem;
}
.article-body th,
.article-body td {
  border: 1px solid var(--line);
  padding: 10px 14px;
  text-align: left;
  vertical-align: top;
}
.article-body thead th {
  background: rgba(232, 223, 210, 0.4);
}
.article-body code {
  background: rgba(37, 41, 37, 0.06);
  padding: 2px 6px;
  border-radius: 6px;
  font-size: 0.9em;
}
.article-body pre {
  background: var(--brand-dark);
  color: var(--cream);
  padding: 16px 18px;
  border-radius: 12px;
  overflow: auto;
  margin: 0 0 24px;
}
.article-body pre code {
  background: transparent;
  color: inherit;
  padding: 0;
}

.article-foot {
  border-top: 1px solid var(--line);
  padding: 36px 0 80px;
}
.article-foot .back {
  font-size: 0.85rem;
  text-decoration: none;
  font-weight: 600;
}
.cta-blog {
  margin-top: 30px;
  background: var(--brand);
  color: var(--cream);
  border-radius: 20px;
  padding: 32px 28px;
  text-align: center;
}
.cta-blog h3 {
  font-family: 'Cormorant Garamond', Georgia, serif;
  font-weight: 500;
  font-size: 1.7rem;
  color: #fff;
}
.cta-blog p {
  color: rgba(247, 245, 240, 0.8);
  margin: 10px 0 20px;
  font-size: 0.92rem;
}
.cta-blog a {
  display: inline-block;
  background: var(--cream);
  color: var(--brand-dark);
  text-decoration: none;
  font-weight: 600;
  font-size: 0.85rem;
  padding: 12px 24px;
  border-radius: 999px;
}

/* Posts relacionados */
.related {
  margin: 10px 0 42px;
}
.related-title {
  font-family: 'Cormorant Garamond', Georgia, serif;
  font-weight: 500;
  font-size: 1.7rem;
  margin-bottom: 18px;
}
.related-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 18px;
}
.rel-card {
  display: flex;
  flex-direction: column;
  text-decoration: none;
  color: inherit;
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 14px;
  overflow: hidden;
  transition: transform 0.35s cubic-bezier(0.22, 1, 0.36, 1), box-shadow 0.35s;
}
.rel-card:hover {
  transform: translateY(-3px);
  box-shadow: 0 26px 50px -42px rgba(41, 73, 54, 0.6);
}
.rel-thumb {
  aspect-ratio: 16 / 10;
  overflow: hidden;
  background: linear-gradient(135deg, #e8dfd2, #d3c7b4);
}
.rel-thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}
.rel-body {
  padding: 14px 16px 18px;
}
.rel-body .cat {
  font-size: 0.6rem;
  font-weight: 600;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--brand);
}
.rel-body h3 {
  font-family: 'Cormorant Garamond', Georgia, serif;
  font-weight: 500;
  font-size: 1.18rem;
  line-height: 1.2;
  margin-top: 6px;
}
@media (max-width: 720px) {
  .related-grid {
    grid-template-columns: 1fr 1fr;
  }
}
@media (max-width: 460px) {
  .related-grid {
    grid-template-columns: 1fr;
  }
}

/* Estado vazio / 404 */
.empty {
  padding-block: clamp(84px, 9vw, 120px) 100px;
  text-align: center;
  color: rgba(37, 41, 37, 0.55);
}

/* Footer */
.site-foot {
  background: var(--brand-dark);
  color: rgba(247, 245, 240, 0.7);
  padding: 40px 0;
  font-size: 0.8rem;
}
.site-foot .wrap {
  display: flex;
  flex-wrap: wrap;
  gap: 14px;
  align-items: center;
  justify-content: space-between;
}
.site-foot a {
  color: rgba(247, 245, 240, 0.85);
  text-decoration: none;
}
.site-foot a:hover {
  color: #fff;
}

@media (max-width: 560px) {
  .site-head nav a:not(.cta) {
    display: none;
  }
}
