:root {
  color-scheme: light;
  --bg: #f7f7f9;
  --text: #1e1e24;
  --muted: #5b5b6a;
  --brand: #1b4d89;
  --brand-dark: #143a67;
  --card: #ffffff;
  --border: #e1e1ea;
  --shadow: 0 8px 24px rgba(0, 0, 0, 0.08);
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  font-family: "Inter", "Segoe UI", system-ui, -apple-system, sans-serif;
  background: var(--bg);
  color: var(--text);
}

a {
  color: var(--brand);
  text-decoration: none;
}

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

.container {
  width: min(1120px, 92vw);
  margin: 0 auto;
}

.site-header {
  background: var(--card);
  border-bottom: 1px solid var(--border);
  position: sticky;
  top: 0;
  z-index: 10;
}

.site-header .container {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 16px 0;
}

.brand {
  display: flex;
  align-items: center;
  gap: 10px;
  font-weight: 700;
  font-size: 1.2rem;
  line-height: 1;
  height: 32px;
}

.brand-logo {
  width: 32px;
  height: 32px;
  object-fit: contain;
  display: block;
  flex-shrink: 0;
}

.brand span {
  display: flex;
  align-items: center;
  height: 32px;
  line-height: 32px;
}

.nav a {
  margin-left: 16px;
  font-size: 0.95rem;
}

.hero {
  padding: 40px 0 24px;
}

.hero h1 {
  font-size: 2.6rem;
  margin-bottom: 8px;
}

.search {
  margin-top: 20px;
  background: var(--card);
  padding: 20px;
  border-radius: 16px;
  box-shadow: var(--shadow);
}

.search input {
  width: 100%;
  padding: 12px 14px;
  border: 1px solid var(--border);
  border-radius: 10px;
  font-size: 1rem;
}

.results {
  list-style: none;
  padding: 0;
  margin: 16px 0 0;
  display: grid;
  gap: 10px;
}

.results li {
  background: var(--bg);
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 12px;
}

.panel {
  margin: 30px 0;
  background: var(--card);
  border-radius: 16px;
  padding: 20px;
  box-shadow: var(--shadow);
}

.sections,
.featured,
.section-list {
  list-style: none;
  padding: 0;
  display: grid;
  gap: 10px;
}

.sections li,
.featured li,
.section-list li {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 12px 14px;
  border: 1px solid var(--border);
  border-radius: 12px;
  background: var(--bg);
}

.badge {
  background: var(--brand);
  color: white;
  border-radius: 999px;
  padding: 4px 10px;
  font-size: 0.8rem;
}

.meta {
  color: var(--muted);
  font-size: 0.9rem;
}

.dogma {
  margin: 40px 0;
  background: var(--card);
  padding: 28px;
  border-radius: 18px;
  box-shadow: var(--shadow);
}

.dogma header {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.dogma header .meta {
  order: 1;
}

.dogma header h1 {
  order: 2;
}

.dogma .enunciado {
  font-size: 1.2rem;
  line-height: 1.6;
}

.dogma .grid {
  display: flex;
  flex-direction: column;
  gap: 16px;
  margin: 24px 0;
}

.dogma .grid section {
  width: 100%;
}

.dogma ul {
  list-style: none;
  padding: 0;
}

.inline-links {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.inline-links li a {
  display: inline-block;
  padding: 6px 10px;
  border-radius: 999px;
  background: var(--bg);
  border: 1px solid var(--border);
  font-size: 0.9rem;
}

.back {
  display: inline-block;
  margin-top: 10px;
}

.site-footer {
  margin-top: 40px;
  padding: 20px 0 30px;
  border-top: 1px solid var(--border);
  color: var(--muted);
}

@media (max-width: 640px) {
  .site-header .container {
    flex-direction: column;
    gap: 12px;
  }

  .nav a {
    margin-left: 0;
    margin-right: 12px;
  }

  .sections li,
  .featured li,
  .section-list li {
    flex-direction: column;
    align-items: flex-start;
    gap: 6px;
  }

  .dogma header .meta {
    order: 2;
  }

  .dogma header h1 {
    order: 1;
  }
}
