/* Continental CAD — shared legal document stylesheet */
:root {
  --bg: #f7f8fa;
  --paper: #ffffff;
  --ink: #18202a;
  --muted: #526070;
  --line: #dce2ea;
  --accent: #0b4f9c;
  --accent-soft: #eef4fc;
  --warn-bg: #fff8eb;
  --warn-border: #d99b26;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }

body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  font-size: 15px;
  line-height: 1.65;
}

.topbar {
  background: #0d1b2a;
  color: #e9eff6;
  border-bottom: 1px solid #1e3148;
  padding: 12px 20px;
  position: sticky;
  top: 0;
  z-index: 20;
}

.topbar-inner {
  max-width: 960px;
  margin: 0 auto;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 10px 18px;
}

.brand {
  font-weight: 700;
  font-size: 15px;
  color: #ffffff;
  text-decoration: none;
  letter-spacing: -0.01em;
}

.topnav {
  display: flex;
  flex-wrap: wrap;
  gap: 14px;
  font-size: 13px;
}

.topnav a {
  color: #b9cde4;
  text-decoration: none;
}

.topnav a:hover, .topnav a.active {
  color: #ffffff;
  text-decoration: underline;
}

.wrap {
  max-width: 960px;
  margin: 24px auto 64px;
  padding: 0 18px;
}

.doc {
  background: var(--paper);
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 32px 36px 40px;
  box-shadow: 0 1px 3px rgba(13, 27, 42, 0.04);
}

h1 {
  margin: 0 0 8px;
  font-size: 28px;
  line-height: 1.25;
  letter-spacing: -0.02em;
  color: #0d1b2a;
}

.meta {
  display: flex;
  flex-wrap: wrap;
  gap: 6px 16px;
  font-size: 13px;
  color: var(--muted);
  margin: 0 0 20px;
  padding-bottom: 16px;
  border-bottom: 1px solid var(--line);
}

.meta strong { color: var(--ink); }

.notice {
  background: var(--accent-soft);
  border-left: 4px solid var(--accent);
  padding: 14px 16px;
  border-radius: 0 6px 6px 0;
  margin: 18px 0 22px;
  font-size: 14px;
}

.notice.warn {
  background: var(--warn-bg);
  border-left-color: var(--warn-border);
}

.toc {
  background: #f8fafc;
  border: 1px solid var(--line);
  border-radius: 6px;
  padding: 16px 20px;
  margin: 20px 0 28px;
}

.toc-title {
  margin: 0 0 10px;
  font-size: 12px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--muted);
}

.toc ol {
  margin: 0;
  padding-left: 20px;
  columns: 2;
  column-gap: 28px;
  font-size: 13.5px;
}

.toc li {
  margin-bottom: 5px;
  break-inside: avoid;
}

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

a:hover {
  text-decoration: underline;
}

a.xref {
  font-size: 0.93em;
  white-space: nowrap;
}

section {
  padding-top: 10px;
  margin-top: 22px;
  border-top: 1px solid #edf1f6;
  scroll-margin-top: 66px;
}

section:first-of-type {
  border-top: none;
  margin-top: 8px;
}

h2 {
  margin: 0 0 10px;
  font-size: 19px;
  color: #0d1b2a;
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 10px;
}

h3 {
  margin: 16px 0 6px;
  font-size: 15.5px;
  color: #162a42;
}

.sec-anchor {
  font-size: 12px;
  font-weight: 500;
  color: #7c8b9c;
}

.sec-anchor:hover { color: var(--accent); }

p { margin: 0 0 11px; }

ul, ol {
  margin: 0 0 12px;
  padding-left: 22px;
}

li { margin-bottom: 5px; }

table {
  width: 100%;
  border-collapse: collapse;
  margin: 12px 0 16px;
  font-size: 13.5px;
}

th, td {
  border: 1px solid var(--line);
  padding: 8px 10px;
  text-align: left;
  vertical-align: top;
}

th {
  background: #f3f6fa;
  font-weight: 600;
  color: #0d1b2a;
}

code {
  font-family: Consolas, Menlo, Monaco, monospace;
  font-size: 0.9em;
  background: #f1f4f8;
  padding: 1px 5px;
  border-radius: 3px;
}

.caps {
  font-size: 13.5px;
  letter-spacing: 0.01em;
}

.doc-footer {
  margin-top: 32px;
  padding-top: 18px;
  border-top: 1px solid var(--line);
  font-size: 13px;
  color: var(--muted);
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 10px;
}

@media (max-width: 720px) {
  .doc { padding: 22px 18px 28px; }
  .toc ol { columns: 1; }
  h1 { font-size: 23px; }
}

@media print {
  .topbar { position: static; background: #fff; color: #000; border-bottom: 1px solid #ccc; }
  .brand, .topnav a { color: #000; }
  body { background: #fff; }
  .doc { border: none; box-shadow: none; padding: 0; }
  .sec-anchor { display: none; }
}
