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

body {
  font-family: 'Georgia', serif;
  background: #faf8f4;
  color: #2c2c2c;
  margin: 0;
  display: flex;
  justify-content: center;
  padding: 2rem 1.5rem;
  line-height: 1.65;
}

.container {
  max-width: 720px;
  width: 100%;
}

/* Header */
.site-header { margin-bottom: 2rem; }
.site-header h1 {
  font-size: 1.85rem;
  font-weight: 600;
  margin: 0 0 0.4rem;
}
.breadcrumb {
  font-size: 0.82rem;
  color: #999;
  margin-bottom: 0.25rem;
}
.breadcrumb a { color: #c4593a; text-decoration: none; }
.breadcrumb a:hover { text-decoration: underline; }

.lead {
  font-size: 1.05rem;
  color: #555;
  margin: 0 0 1rem;
}
.lead a { color: #c4593a; text-decoration: none; }
.lead a:hover { text-decoration: underline; }

.nav-links {
  display: flex;
  gap: 1.25rem;
  font-size: 0.85rem;
}
.nav-links a {
  color: #c4593a;
  text-decoration: none;
  padding: 0.25rem 0;
  border-bottom: 1px solid transparent;
}
.nav-links a:hover { border-bottom-color: #c4593a; }

/* Sections */
section { margin-bottom: 2rem; }

h2 {
  font-size: 1.3rem;
  font-weight: 600;
  color: #2c2c2c;
  margin: 2rem 0 0.75rem;
  padding-bottom: 0.3rem;
  border-bottom: 1px solid #e0dcd6;
}

h3 {
  font-size: 1.05rem;
  font-weight: 600;
  color: #4a3520;
  margin: 1.25rem 0 0.5rem;
}

p {
  font-size: 0.95rem;
  color: #444;
  margin: 0 0 0.75rem;
}

a { color: #c4593a; }

/* Callout */
.callout {
  background: #fff;
  border-left: 3px solid #c4593a;
  border-radius: 0 4px 4px 0;
  padding: 0.75rem 1rem;
  margin: 1rem 0;
  font-size: 0.85rem;
  color: #555;
  line-height: 1.6;
}
.callout a { color: #c4593a; }

/* Code */
code {
  background: #f0ece6;
  padding: 0.12rem 0.35rem;
  border-radius: 3px;
  font-size: 0.82rem;
  font-family: 'SF Mono', 'Menlo', 'Consolas', monospace;
}

pre {
  background: #2c2c2c;
  color: #e8e0d6;
  border-radius: 6px;
  padding: 1rem 1.25rem;
  overflow-x: auto;
  font-size: 0.8rem;
  line-height: 1.5;
  margin: 0.5rem 0 1rem;
}
pre code {
  background: none;
  padding: 0;
  color: inherit;
  font-size: inherit;
}

/* Prism syntax highlighting — warm palette */
pre .token.comment,
pre .token.prolog { color: #8a8072; font-style: italic; }
pre .token.property,
pre .token.tag,
pre .token.key { color: #d4a373; }
pre .token.string,
pre .token.attr-value { color: #a8c686; }
pre .token.number,
pre .token.boolean { color: #d4886b; }
pre .token.punctuation { color: #b0a898; }
pre .token.operator { color: #c4593a; }
pre .token.keyword,
pre .token.builtin { color: #c4593a; }
pre .token.function { color: #dbc5a0; }
pre .token.variable { color: #e8e0d6; }
pre.architecture {
  background: #fff;
  color: #555;
  border: 1px solid #e0dcd6;
  font-size: 0.75rem;
  line-height: 1.4;
}
pre.mermaid {
  background: transparent;
  color: inherit;
  padding: 0;
  margin: 1rem 0;
  text-align: center;
}

/* Tables */
table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.82rem;
  margin: 0.5rem 0 1rem;
}
th {
  background: #f5f0ea;
  padding: 0.55rem 0.75rem;
  text-align: left;
  font-weight: 600;
  color: #4a3520;
  border-bottom: 2px solid #e0dcd6;
}
td {
  padding: 0.5rem 0.75rem;
  border-bottom: 1px solid #f0ece6;
  color: #444;
  vertical-align: top;
}

/* Bibliography */
ul.bib {
  list-style: none;
  padding: 0;
}
ul.bib li {
  font-size: 0.82rem;
  color: #555;
  margin-bottom: 0.5rem;
  padding-left: 1.5rem;
  text-indent: -1.5rem;
}

/* Card list (examples index) */
.card-list {
  list-style: none;
  padding: 0;
  margin: 0;
}
.card-list li {
  background: #fff;
  border: 1px solid #e0dcd6;
  border-radius: 6px;
  margin-bottom: 0.75rem;
  transition: border-color 0.15s;
}
.card-list li:hover { border-color: #c4593a; }
.card-list a {
  display: block;
  padding: 1rem 1.25rem;
  text-decoration: none;
  color: inherit;
}
.card-list .title {
  font-size: 1rem;
  font-weight: 600;
  color: #c4593a;
  margin-bottom: 0.25rem;
}
.card-list .desc {
  font-size: 0.85rem;
  color: #777;
  line-height: 1.5;
}
.card-list .meta {
  font-size: 0.75rem;
  color: #aaa;
  margin-top: 0.4rem;
}

/* Details / accordion */
details {
  background: #fff;
  border: 1px solid #e0dcd6;
  border-radius: 6px;
  padding: 0.75rem 1.25rem;
  margin-bottom: 1.5rem;
  font-size: 0.85rem;
  color: #555;
}
details summary {
  cursor: pointer;
  font-weight: 600;
  color: #4a3520;
}
details ol { padding-left: 1.25rem; }
