/* ── CSS Variables ─────────────────────────────────────────── */
:root {
  --accent:       #2d6a4f;
  --accent2:      #40916c;
  --accent-light: #d8f3dc;
  --bg:           #ffffff;
  --bg2:          #f8fafb;
  --bg3:          #f1f5f1;
  --text:         #1a1a2e;
  --text2:        #4a5568;
  --text3:        #718096;
  --border:       #e2e8f0;
  --border2:      #cbd5e1;
  --radius:       8px;
  --radius-lg:    14px;
  --shadow:       0 1px 3px rgba(0,0,0,.06), 0 4px 16px rgba(0,0,0,.05);
  --shadow-lg:    0 8px 30px rgba(0,0,0,.1);
  --font-body:    'DM Sans', system-ui, sans-serif;
  --font-heading: 'Lora', Georgia, serif;
  --max-w:        1180px;
  --max-article:  760px;
}

[data-theme="dark"] {
  --bg:           #0f1117;
  --bg2:          #1a1d27;
  --bg3:          #242837;
  --text:         #e8eaf0;
  --text2:        #a0aec0;
  --text3:        #718096;
  --border:       #2d3748;
  --border2:      #4a5568;
  --accent-light: #1a3a2a;
}

/* ── Reset ─────────────────────────────────────────────────── */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; }
body {
  font-family: var(--font-body);
  font-size: 1rem;
  line-height: 1.7;
  color: var(--text);
  background: var(--bg);
  -webkit-font-smoothing: antialiased;
}
img { max-width: 100%; height: auto; display: block; }
a { color: var(--accent); text-decoration: none; }
a:hover { text-decoration: underline; }

/* ── Container ─────────────────────────────────────────────── */
.container {
  max-width: var(--max-w);
  margin: 0 auto;
  padding: 0 1.25rem;
}
.container--article {
  max-width: var(--max-article);
}

/* ── Reading Progress ──────────────────────────────────────── */
.reading-progress {
  position: fixed;
  top: 0; left: 0;
  height: 3px;
  width: 0%;
  background: var(--accent);
  z-index: 9999;
  transition: width .1s linear;
}

/* ── Header ────────────────────────────────────────────────── */
.site-header {
  position: sticky;
  top: 0;
  z-index: 100;
  background: var(--bg);
  border-bottom: 1px solid var(--border);
  box-shadow: 0 1px 8px rgba(0,0,0,.06);
}
.header-inner {
  max-width: var(--max-w);
  margin: 0 auto;
  padding: 0 1.25rem;
  height: 64px;
  display: flex;
  align-items: center;
  gap: 1.5rem;
}
.site-logo {
  font-family: var(--font-heading);
  font-size: 1.35rem;
  font-weight: 700;
  color: var(--text);
  text-decoration: none;
  flex-shrink: 0;
}
.site-logo span, .logo-text span { color: var(--accent); }
.main-nav { flex: 1; overflow: hidden; }
.nav-links {
  list-style: none;
  display: flex;
  gap: .15rem;
  overflow-x: auto;
  scrollbar-width: none;
}
.nav-links::-webkit-scrollbar { display: none; }
.nav-links a {
  display: block;
  padding: .4rem .7rem;
  font-size: .83rem;
  font-weight: 500;
  color: var(--text2);
  border-radius: var(--radius);
  white-space: nowrap;
  transition: background .15s, color .15s;
}
.nav-links a:hover, .nav-links a.active {
  background: var(--accent-light);
  color: var(--accent);
  text-decoration: none;
}
.header-actions {
  display: flex;
  align-items: center;
  gap: .5rem;
  flex-shrink: 0;
}
.btn-icon {
  background: none;
  border: none;
  cursor: pointer;
  padding: .4rem;
  border-radius: var(--radius);
  font-size: 1.1rem;
  line-height: 1;
  transition: background .15s;
  color: var(--text2);
}
.btn-icon:hover { background: var(--bg2); }
.btn-menu { display: none; }

/* ── Mobile Menu ───────────────────────────────────────────── */
.mobile-menu {
  display: none;
  position: fixed;
  inset: 0;
  background: var(--bg);
  z-index: 200;
  flex-direction: column;
  padding: 1.25rem;
  overflow-y: auto;
}
.mobile-menu.open { display: flex; }
.mobile-menu-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 1.5rem;
  padding-bottom: 1rem;
  border-bottom: 1px solid var(--border);
}
.mobile-nav-links { list-style: none; }
.mobile-nav-links li { border-bottom: 1px solid var(--border); }
.mobile-nav-links a {
  display: block;
  padding: .85rem .5rem;
  font-size: 1rem;
  font-weight: 500;
  color: var(--text);
}

/* ── Hero ──────────────────────────────────────────────────── */
.hero {
  background: linear-gradient(135deg, #1b4332 0%, var(--accent) 100%);
  color: #fff;
  padding: 3.5rem 0 3rem;
  text-align: center;
}
.hero-title {
  font-family: var(--font-heading);
  font-size: clamp(1.6rem, 4vw, 2.5rem);
  font-weight: 700;
  margin-bottom: .75rem;
  line-height: 1.25;
}
.hero-title span { color: #74c69d; }
.hero-sub {
  font-size: 1rem;
  opacity: .85;
  margin-bottom: 1.75rem;
  max-width: 560px;
  margin-left: auto;
  margin-right: auto;
}
.hero-search {
  display: flex;
  max-width: 560px;
  margin: 0 auto;
  gap: .5rem;
}
.hero-search input {
  flex: 1;
  padding: .75rem 1.1rem;
  border: none;
  border-radius: var(--radius);
  font-size: .95rem;
  font-family: inherit;
  outline: none;
  color: var(--text);
}
.hero-search button {
  padding: .75rem 1.25rem;
  background: #74c69d;
  border: none;
  border-radius: var(--radius);
  font-size: 1rem;
  cursor: pointer;
  transition: background .15s;
}
.hero-search button:hover { background: #52b788; }

/* ── Section title ─────────────────────────────────────────── */
.section-title {
  font-family: var(--font-heading);
  font-size: 1.35rem;
  font-weight: 700;
  color: var(--text);
  margin-bottom: 1.25rem;
  padding-bottom: .6rem;
  border-bottom: 2px solid var(--accent-light);
  display: flex;
  align-items: center;
  gap: .6rem;
}
.section-head { margin-bottom: 1.5rem; }

/* ── Category grid ─────────────────────────────────────────── */
.cat-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(150px, 1fr));
  gap: .75rem;
}
.cat-card {
  background: var(--bg2);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 1rem;
  text-align: center;
  transition: transform .2s, box-shadow .2s;
  text-decoration: none;
  display: flex;
  flex-direction: column;
  gap: .35rem;
}
.cat-card:hover { transform: translateY(-2px); box-shadow: var(--shadow-lg); text-decoration: none; }
.cat-name { font-weight: 600; font-size: .88rem; color: var(--text); }
.cat-count { font-size: .75rem; color: var(--text3); }

/* ── Cards grid ────────────────────────────────────────────── */
.cards-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 1.25rem;
  margin-bottom: 2rem;
}
.card {
  background: var(--bg);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  overflow: hidden;
  transition: transform .2s, box-shadow .2s;
  box-shadow: var(--shadow);
}
.card:hover { transform: translateY(-3px); box-shadow: var(--shadow-lg); }
.card-img-wrap {
  position: relative;
  aspect-ratio: 16/9;
  overflow: hidden;
  background: var(--bg3);
}
.card-img-wrap img {
  width: 100%; height: 100%;
  object-fit: cover;
  transition: transform .4s;
}
.card:hover .card-img-wrap img { transform: scale(1.04); }
.card-cat-badge {
  position: absolute;
  top: .6rem; left: .6rem;
  padding: .2rem .65rem;
  border-radius: 100px;
  font-size: .7rem;
  font-weight: 700;
  color: #fff;
}
.card-content { padding: 1rem 1.1rem 1.25rem; }
.card-title {
  font-family: var(--font-heading);
  font-size: 1rem;
  font-weight: 600;
  line-height: 1.4;
  margin-bottom: .5rem;
}
.card-title a { color: var(--text); }
.card-title a:hover { color: var(--accent); text-decoration: none; }
.card-desc { font-size: .83rem; color: var(--text2); margin-bottom: .6rem; line-height: 1.5; }
.card-meta { font-size: .75rem; color: var(--text3); display: flex; align-items: center; gap: .4rem; }

/* ── Pagination ────────────────────────────────────────────── */
.pagination {
  display: flex;
  justify-content: center;
  gap: .4rem;
  margin: 2rem 0;
  flex-wrap: wrap;
}
.page-btn {
  padding: .5rem .9rem;
  border: 1.5px solid var(--border);
  border-radius: var(--radius);
  font-size: .85rem;
  color: var(--text2);
  background: var(--bg);
  transition: all .15s;
  text-decoration: none;
}
.page-btn:hover, .page-btn.active {
  background: var(--accent);
  border-color: var(--accent);
  color: #fff;
  text-decoration: none;
}

/* ── Article page ──────────────────────────────────────────── */
.article-header { padding: 2rem 0 1.25rem; }
.article-cat {
  display: inline-block;
  padding: .25rem .85rem;
  border-radius: 100px;
  font-size: .75rem;
  font-weight: 700;
  margin-bottom: .75rem;
  text-decoration: none;
}
.article-title {
  font-family: var(--font-heading);
  font-size: clamp(1.6rem, 4vw, 2.2rem);
  font-weight: 700;
  line-height: 1.25;
  margin-bottom: .75rem;
  color: var(--text);
}
.article-lead {
  font-size: 1.05rem;
  color: var(--text2);
  margin-bottom: 1rem;
  line-height: 1.65;
}
.article-meta {
  display: flex;
  align-items: center;
  gap: .5rem;
  flex-wrap: wrap;
  font-size: .82rem;
  color: var(--text3);
  margin-bottom: 1rem;
}
.article-meta img { border-radius: 50%; object-fit: cover; }
.article-hero-img {
  width: 100%;
  height: auto;
  border-radius: var(--radius-lg);
  margin-bottom: 2rem;
  aspect-ratio: 1200/630;
  object-fit: cover;
}

/* ── Article body ──────────────────────────────────────────── */
.article-body {
  font-size: 1.05rem;
  line-height: 1.8;
  color: var(--text);
}
.article-body h2 {
  font-family: var(--font-heading);
  font-size: 1.45rem;
  font-weight: 700;
  margin: 2.25rem 0 .75rem;
  color: var(--text);
  border-left: 4px solid var(--accent);
  padding-left: .85rem;
}
.article-body h3 {
  font-family: var(--font-heading);
  font-size: 1.15rem;
  font-weight: 600;
  margin: 1.75rem 0 .5rem;
  color: var(--text);
}
.article-body p { margin-bottom: 1.25rem; }
.article-body ul, .article-body ol {
  margin: 1rem 0 1.25rem 1.5rem;
}
.article-body li { margin-bottom: .5rem; }
.article-body ol { counter-reset: step; list-style: none; margin-left: 0; }
.article-body ol li {
  counter-increment: step;
  display: flex;
  gap: 1rem;
  margin-bottom: 1rem;
  align-items: flex-start;
}
.article-body ol li::before {
  content: counter(step);
  min-width: 2rem;
  height: 2rem;
  background: var(--accent);
  color: #fff;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: .8rem;
  font-weight: 700;
  flex-shrink: 0;
  margin-top: .1rem;
}
.article-body blockquote {
  margin: 1.5rem 0;
  padding: 1rem 1.25rem;
  background: var(--accent-light);
  border-left: 4px solid var(--accent);
  border-radius: 0 var(--radius) var(--radius) 0;
  font-style: italic;
  color: var(--text2);
}
.article-body strong { color: var(--text); font-weight: 600; }
.article-body a { color: var(--accent); text-decoration: underline; }
.article-body img {
  border-radius: var(--radius);
  margin: 1.25rem 0;
}
.article-body table {
  width: 100%;
  border-collapse: collapse;
  font-size: .9rem;
  margin: 1.25rem 0;
}
.article-body th, .article-body td {
  padding: .6rem .85rem;
  border: 1px solid var(--border);
  text-align: left;
}
.article-body th {
  background: var(--bg2);
  font-weight: 600;
}

/* ── Ad inline ─────────────────────────────────────────────── */
.ad-inline {
  margin: 1.75rem 0;
  text-align: center;
}

/* ── Tags ──────────────────────────────────────────────────── */
.article-tags {
  display: flex;
  flex-wrap: wrap;
  gap: .5rem;
  margin: 2rem 0;
}
.tag {
  display: inline-block;
  padding: .3rem .85rem;
  background: var(--bg2);
  border: 1px solid var(--border);
  border-radius: 100px;
  font-size: .78rem;
  color: var(--text2);
  transition: all .15s;
  text-decoration: none;
}
.tag:hover { background: var(--accent-light); color: var(--accent); border-color: var(--accent); text-decoration: none; }

/* ── Share box ─────────────────────────────────────────────── */
.share-box {
  margin: 2rem 0;
  padding: 1.25rem;
  background: var(--bg2);
  border-radius: var(--radius-lg);
  border: 1px solid var(--border);
}

/* ── Author box ────────────────────────────────────────────── */
.author-box {
  display: flex;
  gap: 1rem;
  align-items: flex-start;
  padding: 1.25rem;
  background: var(--bg2);
  border-radius: var(--radius-lg);
  border: 1px solid var(--border);
  margin: 2rem 0;
}
.author-box img { border-radius: 50%; object-fit: cover; flex-shrink: 0; }

/* ── Related articles ──────────────────────────────────────── */
.related-section {
  background: var(--bg2);
  padding: 3rem 0;
  margin-top: 3rem;
}

/* ── Breadcrumb ────────────────────────────────────────────── */
.breadcrumb {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: .35rem;
  font-size: .8rem;
  color: var(--text3);
  padding: 1rem 0;
}
.breadcrumb a { color: var(--text3); }
.breadcrumb a:hover { color: var(--accent); }
.breadcrumb-sep { color: var(--border2); }

/* ── Buttons ───────────────────────────────────────────────── */
.btn-primary {
  display: inline-flex;
  align-items: center;
  gap: .4rem;
  padding: .55rem 1.1rem;
  background: var(--accent);
  color: #fff;
  border: none;
  border-radius: var(--radius);
  font-size: .88rem;
  font-weight: 600;
  cursor: pointer;
  font-family: inherit;
  transition: background .15s;
  text-decoration: none;
}
.btn-primary:hover { background: var(--accent2); color: #fff; text-decoration: none; }

/* ── Back to top ───────────────────────────────────────────── */
.back-top {
  position: fixed;
  bottom: 1.5rem;
  right: 1.5rem;
  width: 44px;
  height: 44px;
  background: var(--accent);
  color: #fff;
  border: none;
  border-radius: 50%;
  font-size: 1.2rem;
  cursor: pointer;
  box-shadow: var(--shadow-lg);
  opacity: 0;
  transform: translateY(10px);
  transition: opacity .3s, transform .3s;
  z-index: 500;
}
.back-top.visible { opacity: 1; transform: translateY(0); }

/* ── Footer ────────────────────────────────────────────────── */
.site-footer {
  background: var(--bg2);
  border-top: 1px solid var(--border);
  margin-top: 4rem;
  padding: 3rem 0 0;
}
.footer-inner {
  max-width: var(--max-w);
  margin: 0 auto;
  padding: 0 1.25rem 2rem;
  display: grid;
  grid-template-columns: 2fr 1fr 1fr;
  gap: 2rem;
}
.footer-slogan { font-size: .85rem; color: var(--text3); margin-top: .35rem; }
.footer-cats strong, .footer-links strong {
  font-size: .8rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: .05em;
  color: var(--text3);
  display: block;
  margin-bottom: .75rem;
}
.footer-cats ul, .footer-links ul { list-style: none; }
.footer-cats li, .footer-links li { margin-bottom: .4rem; }
.footer-cats a, .footer-links a { font-size: .85rem; color: var(--text2); }
.footer-cats a:hover, .footer-links a:hover { color: var(--accent); }
.footer-bottom {
  border-top: 1px solid var(--border);
  padding: 1.25rem;
  text-align: center;
  font-size: .8rem;
  color: var(--text3);
}

/* ── Responsive ────────────────────────────────────────────── */
@media (max-width: 900px) {
  .footer-inner { grid-template-columns: 1fr 1fr; }
  .footer-brand { grid-column: 1 / -1; }
}

@media (max-width: 640px) {
  .main-nav { display: none; }
  .btn-menu { display: flex; }
  .hero { padding: 2.5rem 0 2rem; }
  .cards-grid { grid-template-columns: 1fr; }
  .cat-grid { grid-template-columns: repeat(2, 1fr); }
  .footer-inner { grid-template-columns: 1fr; gap: 1.5rem; }
  .article-body ol li { flex-direction: column; gap: .5rem; }
  .article-body ol li::before { width: 1.75rem; height: 1.75rem; }
  .hero-search { flex-direction: column; }
}

/* ── Você Também Pode Gostar ───────────────────────────────── */
.vtpg-bloco {
  margin: 2.5rem 0;
  padding: 1.25rem 1.25rem 1.5rem;
  background: var(--bg2);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  border-top: 3px solid var(--accent);
  clear: both;
}
.vtpg-titulo {
  font-family: var(--font-heading);
  font-size: .95rem;
  font-weight: 700;
  color: var(--text);
  margin: 0 0 1rem;
  padding-bottom: .75rem;
  border-bottom: 1px solid var(--border);
  letter-spacing: .01em;
}
.vtpg-grid {
  display: grid !important;
  grid-template-columns: repeat(3, 1fr) !important;
  gap: .85rem;
  list-style: none;
  margin: 0;
  padding: 0;
}
.vtpg-card {
  background: var(--bg);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  overflow: hidden;
  text-decoration: none !important;
  display: flex !important;
  flex-direction: column;
  transition: transform .2s, box-shadow .2s, border-color .2s;
  box-shadow: 0 1px 4px rgba(0,0,0,.05);
}
.vtpg-card:hover {
  transform: translateY(-3px);
  box-shadow: 0 6px 20px rgba(0,0,0,.1);
  border-color: var(--accent);
  text-decoration: none !important;
}
.vtpg-img {
  width: 100%;
  aspect-ratio: 16/9;
  overflow: hidden;
  flex-shrink: 0;
  background: var(--bg3);
  display: flex;
  align-items: center;
  justify-content: center;
}
.vtpg-img img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  transition: transform .4s;
}
.vtpg-card:hover .vtpg-img img {
  transform: scale(1.05);
}
.vtpg-img-ph {
  min-height: 100px;
}
.vtpg-body {
  padding: .75rem;
  display: flex;
  flex-direction: column;
  gap: .35rem;
  flex: 1;
}
.vtpg-cat {
  display: inline-block;
  padding: .18rem .6rem;
  border-radius: 100px;
  font-size: .65rem;
  font-weight: 700;
  color: #fff !important;
  width: fit-content;
  text-decoration: none !important;
  letter-spacing: .02em;
}
.vtpg-nome {
  font-size: .85rem;
  font-weight: 600;
  color: var(--text) !important;
  line-height: 1.4;
  margin: 0;
  text-decoration: none !important;
  display: -webkit-box;
  -webkit-line-clamp: 3;
  -webkit-box-orient: vertical;
  overflow: hidden;
}
.vtpg-desc {
  font-size: .75rem;
  color: var(--text3) !important;
  line-height: 1.45;
  margin: 0;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}
.vtpg-tempo {
  font-size: .7rem;
  color: var(--text3) !important;
  margin-top: auto;
  padding-top: .35rem;
}

@media (max-width: 700px) {
  .vtpg-grid { grid-template-columns: repeat(2, 1fr) !important; }
}
@media (max-width: 480px) {
  .vtpg-grid { grid-template-columns: 1fr !important; }
}