/* styles.css */
/* Inclui estilos base, componentes e markdown (markdown.css unificado) */

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

a {
  text-decoration: none;
}

body {
  background: #fff;
  color: #111;
  font-family: Georgia, serif;
  font-size: 18px;
  line-height: 1.7;
  display: flex;
  flex-direction: column;
  min-height: 100vh;
  padding-top: 57px;
}

/* ─── NAV ─────────────────────────────────────────────── */

#nav {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 100;
  background: #fff;
  border-bottom: 1px solid #ddd;
  display: flex;
  align-items: center;
  gap: 1.5rem;
  padding: 1rem max(3rem, calc((100vw - 960px) / 2));
}

#nav a {
  color: #111;
  text-decoration: none;
  font-family: monospace;
  font-size: 0.85rem;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  opacity: 0.45;
  transition: opacity 0.15s;
}

#nav a:hover,
#nav a.active {
  opacity: 1;
}

/* ─── APP ────────────────────────────────────────────── */

#app {
  max-width: 960px;
  width: 100%;
  margin: 0 auto;
  padding: 4rem 3rem;
  flex: 1;
}

/* ─── HOME INTRO ─────────────────────────────────────── */

.home-intro {
  margin-bottom: 3.5rem;
  padding-bottom: 3rem;
  border-bottom: 1px solid #eee;
}

.home-title {
  font-family: Georgia, serif;
  font-size: 2.6rem;
  font-weight: 700;
  letter-spacing: -0.03em;
  margin-bottom: 0.6rem;
  line-height: 1.15;
}

.home-subtitle {
  font-size: 1.05rem;
  color: #666;
  line-height: 1.6;
}

/* ─── LOADING ────────────────────────────────────────── */

.loading {
  font-family: monospace;
  font-size: 0.85rem;
  color: #888;
  text-transform: uppercase;
  letter-spacing: 0.06em;
}

/* ─── 404 ────────────────────────────────────────────── */

.not-found {
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
}

.not-found-code {
  font-family: monospace;
  font-size: 3rem;
  font-weight: bold;
  color: #ddd;
  line-height: 1;
}

.not-found a {
  font-family: monospace;
  font-size: 0.85rem;
  color: #111;
  text-decoration: underline;
}

/* ─── ARTICLE LIST ───────────────────────────────────── */

.article-list {
  list-style: none;
  margin-top: 1.25rem;
  display: flex;
  flex-direction: column;
}

.article-list li {
  display: grid;
  grid-template-columns: 1fr auto;
  align-items: baseline;
  border-bottom: 1px solid #eee;
  padding: 1.1rem 0;
  gap: 2rem;
  transition: background 0.1s;
}

.article-list li:hover {
  background: #fafafa;
  margin: 0 -1rem;
  padding-left: 1rem;
  padding-right: 1rem;
}

.article-list-main {
  min-width: 0;
}

.article-list a {
  color: #111;
  text-decoration: none;
  font-size: 1.05rem;
}

.article-list a:hover {
  text-decoration: underline;
}

.article-description {
  font-size: 0.875rem;
  color: #888;
  margin-top: 0.25rem;
  line-height: 1.5;
  max-width: 72ch;
}

.article-list span {
  font-family: monospace;
  font-size: 0.78rem;
  color: #bbb;
  white-space: nowrap;
  flex-shrink: 0;
}

/* ─── ARTICLES SECTION ───────────────────────────────── */

.articles-section {
  padding-top: 0;
}

.articles-section h2 {
  font-family: monospace;
  font-size: 0.72rem;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: #bbb;
  margin-bottom: 1.5rem;
}

/* ─── SEARCH ─────────────────────────────────────────── */

.article-search {
  width: 100%;
  max-width: 380px;
  border: none;
  border-bottom: 1px solid #ddd;
  padding: 0.45rem 0;
  font-family: Georgia, serif;
  font-size: 0.95rem;
  color: #111;
  background: transparent;
  outline: none;
  margin-bottom: 0.25rem;
  transition: border-color 0.15s;
  display: block;
}

.article-search::placeholder {
  color: #ccc;
}

.article-search:focus {
  border-bottom-color: #111;
}

.search-empty {
  font-family: monospace;
  font-size: 0.8rem;
  color: #aaa;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  padding: 1.5rem 0;
}

/* ─── BACK LINK ──────────────────────────────────────── */

.back-link {
  display: inline-block;
  font-family: monospace;
  font-size: 0.82rem;
  color: #111;
  text-decoration: none;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  opacity: 0.45;
  transition: opacity 0.15s;
  margin-bottom: 2.5rem;
}

.back-link:hover {
  opacity: 1;
}

/* ─── KITS PAGE ──────────────────────────────────────── */

.kits-contact {
  display: flex;
  flex-direction: row;
  gap: 0.75rem;
  margin-top: 1.75rem;
  flex-wrap: wrap;
}

.kits-cta {
  display: inline-block;
  font-family: monospace;
  font-size: 0.85rem;
  color: #fff;
  background: #111;
  padding: 0.65rem 1.4rem;
  text-decoration: none;
  letter-spacing: 0.04em;
  transition: opacity 0.15s;
  align-self: flex-start;
}

.kits-cta:hover {
  opacity: 0.75;
}

.kits-cta--secondary {
  background: transparent;
  color: #111;
  border: 1px solid #ccc;
}

.kits-cta--secondary:hover {
  opacity: 0.6;
}

/* ─── FOOTER ─────────────────────────────────────────── */

#site-footer {
  border-top: 1px solid #ddd;
  margin-top: auto;
  padding: 3rem max(3rem, calc((100vw - 960px) / 2)) 1.75rem;
  font-size: 0.85rem;
}

.footer-inner {
  max-width: 960px;
  margin: 0 auto;
  display: flex;
  gap: 4rem;
  justify-content: space-between;
  align-items: flex-start;
  flex-wrap: wrap;
}

.footer-about {
  flex: 1;
  min-width: 240px;
  max-width: 420px;
}

.footer-brand {
  display: block;
  font-family: monospace;
  font-size: 0.72rem;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  font-weight: bold;
  margin-bottom: 0.6rem;
}

.footer-about p {
  font-size: 0.82rem;
  color: #777;
  line-height: 1.65;
}

.footer-col {
  display: flex;
  flex-direction: column;
  gap: 0.4rem;
}

.footer-col-title {
  font-family: monospace;
  font-size: 0.68rem;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: #bbb;
  margin-bottom: 0.4rem;
}

.footer-col a {
  color: #666;
  text-decoration: none;
  font-size: 0.82rem;
  transition: color 0.15s;
}

.footer-col a:hover {
  color: #111;
}

.footer-bottom {
  max-width: 960px;
  margin: 1.75rem auto 0;
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-family: monospace;
  font-size: 0.68rem;
  color: #ccc;
  border-top: 1px solid #f0f0f0;
  padding-top: 1.25rem;
}

.footer-bottom a {
  color: #ccc;
  text-decoration: none;
}

.footer-bottom a:hover {
  color: #111;
}

/* ─── MARKDOWN ───────────────────────────────────────── */

.markdown-body {
  color: #111;
  font-family: Georgia, serif;
  font-size: 1.05rem;
  line-height: 1.85;
  max-width: 68ch;
}

.markdown-body h1 {
  font-size: 2.1rem;
  margin-bottom: 1.25rem;
  letter-spacing: -0.02em;
  line-height: 1.2;
}

.markdown-body h2 {
  font-size: 1.35rem;
  margin-top: 2.5rem;
  margin-bottom: 0.85rem;
  border-bottom: 1px solid #e8e8e8;
  padding-bottom: 0.35rem;
  letter-spacing: -0.01em;
}

.markdown-body h3 {
  font-size: 1.1rem;
  margin-top: 1.75rem;
  margin-bottom: 0.55rem;
}

.markdown-body p {
  margin-bottom: 1.35rem;
}

.markdown-body a {
  color: #111;
  text-decoration: underline;
  text-underline-offset: 2px;
}

.markdown-body a:hover {
  opacity: 0.55;
}

.markdown-body ul,
.markdown-body ol {
  padding-left: 1.5rem;
  margin-bottom: 1.35rem;
}

.markdown-body li {
  margin-bottom: 0.4rem;
}

.markdown-body blockquote {
  border-left: 2px solid #ccc;
  padding: 0.6rem 1.25rem;
  color: #666;
  font-style: italic;
  margin: 1.75rem 0;
}

.markdown-body code {
  font-family: monospace;
  font-size: 0.9em;
  background: #f4f4f4;
  padding: 0.18em 0.45em;
  border-radius: 3px;
  color: #333;
}

.markdown-body pre {
  background: #f4f4f4;
  padding: 1.4rem 1.6rem;
  overflow-x: auto;
  margin-bottom: 1.75rem;
  border-radius: 3px;
  border: 1px solid #ebebeb;
}

.markdown-body pre code {
  background: none;
  padding: 0;
  font-size: 0.9rem;
  color: inherit;
}

.markdown-body hr {
  border: none;
  border-top: 1px solid #e8e8e8;
  margin: 2.5rem 0;
}

.markdown-body img {
  max-width: 100%;
  display: block;
  margin: 2rem 0;
  border-radius: 2px;
}

.markdown-body strong {
  font-weight: 700;
}

.markdown-body em {
  font-style: italic;
  color: #444;
}

.markdown-body table {
  width: 100%;
  border-collapse: collapse;
  margin-bottom: 1.75rem;
  font-size: 0.95rem;
}

.markdown-body th {
  text-align: left;
  font-family: monospace;
  font-size: 0.75rem;
  text-transform: uppercase;
  letter-spacing: 0.07em;
  color: #999;
  border-bottom: 1px solid #ddd;
  padding: 0.5rem 0.75rem 0.5rem 0;
}

.markdown-body td {
  border-bottom: 1px solid #f0f0f0;
  padding: 0.6rem 0.75rem 0.6rem 0;
  vertical-align: top;
}

/* ─── LEGAL ──────────────────────────────────────────── */

.legal-wrap {
  max-width: 68ch;
}