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

:root {
  --bg:         #130A04;
  --bg2:        #1E1108;
  --bg3:        #2A180A;
  --amber:      #C8621C;
  --amber2:     #E07828;
  --amber3:     #F0A050;
  --amber-glow: rgba(200,98,28,0.18);
  --text:       #F0E8DC;
  --muted:      #9E8872;
  --line:       rgba(200,98,28,0.25);
  --oswald:     'Oswald', sans-serif;
  --source:     'Source Sans 3', sans-serif;
}

html { scroll-behavior: smooth; }
body {
  background: var(--bg);
  color: var(--text);
  font-family: var(--source);
  min-height: 100vh;
  overflow-x: hidden;
}
body::before {
  content: '';
  position: fixed; inset: 0; z-index: 0; pointer-events: none;
  background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 200 200' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='4' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)' opacity='0.04'/%3E%3C/svg%3E");
  opacity: 0.4;
}

a { color: inherit; text-decoration: none; }

/* ── TOPBAR ── */
.topbar {
  position: relative; z-index: 1;
  display: flex; align-items: center; gap: 20px;
  padding: 20px 48px;
  border-bottom: 1px solid var(--line);
}
.topbar-back {
  font-family: var(--oswald);
  font-size: 0.75rem;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--muted);
  display: flex; align-items: center; gap: 8px;
  transition: color 0.2s;
}
.topbar-back:hover { color: var(--amber); }
.topbar-divider { width: 1px; height: 16px; background: var(--line); }
.topbar-cat {
  font-family: var(--oswald);
  font-size: 0.68rem;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--amber);
  background: var(--amber-glow);
  border: 1px solid var(--amber);
  border-radius: 2px;
  padding: 2px 8px;
}

/* ── COVER ── */
.article-cover {
  position: relative; z-index: 1;
  /* height: 380px; */
  display: flex;
  align-items: flex-end;
}
.article-cover::after {
  content: '';
  position: absolute; inset: 0;
  background: linear-gradient(to top, rgba(19,10,4,0.92) 0%, rgba(19,10,4,0.3) 60%, transparent 100%);
}
.article-cover-content {
  position: relative; z-index: 1;
  width: 100%;
  max-width: calc(760px + 64px);
  margin: 0 auto;
  padding: 28px 32px;
}
.article-date {
  font-family: var(--oswald);
  font-size: 0.75rem;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--muted);
  margin-bottom: 12px;
}
.article-title {
  font-family: var(--oswald);
  font-size: clamp(1.6rem, 3.5vw, 2.8rem);
  font-weight: 700;
  letter-spacing: 0.02em;
  line-height: 1.15;
  color: var(--text);
}
.article-resumo {
  margin-top: 14px;
  font-size: 1rem;
  font-weight: 300;
  line-height: 1.6;
  color: var(--muted);
  max-width: 620px;
}

/* ── ARTICLE BODY ── */
.article-wrap {
  position: relative; z-index: 1;
  max-width: 760px;
  margin: 0 auto;
  padding: 40px 32px 96px;
}

.article-body { font-size: 1rem; line-height: 1.85; font-weight: 300; color: var(--text); }

.article-body p  { margin-bottom: 1.5em; opacity: 0.88; }
.article-body h2 {
  font-family: var(--oswald);
  font-size: 1.4rem;
  font-weight: 600;
  color: var(--text);
  letter-spacing: 0.02em;
  margin: 2.4em 0 0.8em;
  padding-bottom: 8px;
  border-bottom: 1px solid var(--line);
}
.article-body h3 {
  font-family: var(--oswald);
  font-size: 1.1rem;
  font-weight: 600;
  color: var(--amber3);
  letter-spacing: 0.04em;
  margin: 1.8em 0 0.6em;
}
.article-body ul,
.article-body ol {
  padding-left: 1.6em;
  margin-bottom: 1.5em;
}
.article-body li { margin-bottom: 0.5em; opacity: 0.88; }
.article-body strong { color: var(--amber3); font-weight: 600; }
.article-body em { color: var(--muted); font-style: italic; }
.article-body code {
  font-family: monospace;
  font-size: 0.88em;
  background: var(--bg3);
  border: 1px solid var(--line);
  border-radius: 3px;
  padding: 1px 6px;
  color: var(--amber3);
}
.article-body pre {
  background: var(--bg2);
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 20px 24px;
  overflow-x: auto;
  margin-bottom: 1.5em;
}
.article-body pre code {
  background: none;
  border: none;
  padding: 0;
  font-size: 0.88rem;
  line-height: 1.6;
  color: var(--amber3);
}
.article-body a {
  color: var(--amber);
  text-decoration: underline;
  text-underline-offset: 3px;
  text-decoration-color: rgba(200,98,28,0.4);
}
.article-body a:hover { text-decoration-color: var(--amber); }

/* ── BACK LINK ── */
.article-back {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-family: var(--oswald);
  font-size: 0.75rem;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  color: var(--muted);
  margin-bottom: 48px;
  transition: color 0.2s;
}
.article-back:hover { color: var(--amber); }

/* ── FOOTER ── */
footer {
  position: relative; z-index: 1;
  text-align: center;
  padding: 24px;
  border-top: 1px solid var(--line);
  font-size: 0.75rem;
  color: var(--muted);
  letter-spacing: 0.12em;
  font-family: var(--oswald);
  text-transform: uppercase;
}

@media (max-width: 768px) {
  .topbar { padding: 16px 24px; }
  .article-cover { height: 280px; }
  .article-cover-content { padding: 24px; max-width: none; }
  .article-wrap { padding: 40px 24px 64px; }
}
