/* da-about-style.css
   Scoped stylesheet for the About / User Guide page (app/templates/info/about.html).
   Reproduces the client-supplied user manual's document layout (numbered
   sections + sticky left table-of-contents) using the app's own design
   tokens (see :root in da-style.css) instead of the source document's
   dark-green theme. All rules are scoped under .guide-layout /
   .guide-toc / .guide-doc so nothing leaks onto other pages. */

.guide-layout {
  display: flex;
  align-items: flex-start;
  gap: 40px;
}

/* ---------- Sticky table of contents ---------- */

.guide-toc {
  flex: 0 0 260px;
  position: sticky;
  top: 24px;
  align-self: flex-start;
  max-height: calc(100vh - 48px);
  overflow-y: auto;
  padding: 4px 12px 24px 0;
  border-right: 1px solid var(--border-soft);
}

.guide-toc-title {
  font-family: var(--font-head);
  font-size: var(--fs-xs);
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--teal);
  font-weight: var(--fw-bold);
  margin: 0 0 12px;
}

.guide-toc ul {
  list-style: none;
  margin: 0;
  padding: 0;
}

.guide-toc li {
  margin: 2px 0;
}

.guide-toc li.guide-toc-sub {
  padding-left: 14px;
}

.guide-toc a {
  display: block;
  padding: 4px 10px;
  color: var(--muted);
  font-size: var(--fs-sm);
  text-decoration: none;
  border-left: 2px solid transparent;
  border-radius: 0 var(--radius-sm) var(--radius-sm) 0;
}

.guide-toc a:hover {
  color: var(--text);
  background: var(--surface);
  border-left-color: var(--teal);
}

/* ---------- Document ---------- */

.guide-doc {
  flex: 1;
  min-width: 0;
  max-width: 780px;
  padding: 4px 0 60px;
}

.guide-doc-header {
  border-bottom: 1px solid var(--border-soft);
  margin-bottom: 30px;
  padding-bottom: 22px;
}

.guide-doc-kicker {
  font-family: var(--font-head);
  color: var(--teal);
  font-size: var(--fs-xs);
  letter-spacing: 0.16em;
  text-transform: uppercase;
  font-weight: var(--fw-bold);
  margin: 0;
}

.guide-doc-title {
  font-family: var(--font-head);
  font-size: clamp(30px, 4vw, 46px);
  font-weight: var(--fw-black);
  color: var(--text);
  margin: 6px 0 0;
  line-height: 1.1;
}

.guide-doc-subtitle {
  color: var(--muted);
  margin: 6px 0 0;
  font-size: var(--fs-h3);
}

.guide-doc h1 {
  font-family: var(--font-head);
  font-size: var(--fs-h1);
  font-weight: var(--fw-bold);
  color: var(--text);
  margin: 52px 0 12px;
  padding-top: 26px;
  border-top: 1px solid var(--border-soft);
  position: relative;
}

.guide-doc h1::before {
  content: "";
  position: absolute;
  top: -1px;
  left: 0;
  width: 26px;
  height: 3px;
  background: var(--teal);
}

.guide-doc h2 {
  font-family: var(--font-head);
  font-size: var(--fs-h2);
  color: var(--teal);
  font-weight: var(--fw-bold);
  margin: 30px 0 8px;
}

.guide-doc h3 {
  font-family: var(--font-head);
  font-size: var(--fs-h3);
  color: var(--text);
  font-weight: var(--fw-bold);
  margin: 24px 0 6px;
}

.guide-doc p {
  margin: 0 0 12px;
  color: var(--muted);
}

.guide-doc ul,
.guide-doc ol {
  margin: 0 0 12px;
  padding-left: 26px;
  color: var(--muted);
}

.guide-doc li {
  margin: 4px 0;
}

.guide-doc li::marker {
  color: var(--teal);
}

.guide-doc table {
  border-collapse: collapse;
  width: 100%;
  margin: 14px 0 20px;
  font-size: var(--fs-sm);
  background: var(--surface);
  border-radius: var(--radius-sm);
  overflow: hidden;
}

.guide-doc th,
.guide-doc td {
  border: 1px solid var(--border-soft);
  padding: 8px 12px;
  text-align: left;
  vertical-align: top;
}

.guide-doc th {
  background: var(--bg1);
  color: var(--teal);
  font-family: var(--font-head);
  font-size: var(--fs-xs);
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.guide-doc td {
  color: var(--muted);
}

.guide-card {
  background: var(--surface);
  border: 1px solid var(--border-soft);
  border-radius: var(--radius-sm);
  padding: 18px 22px;
  margin: 0 0 14px;
}

.guide-card > p:first-child {
  margin-bottom: 6px;
  color: var(--text);
}

.guide-mono-label {
  font-family: var(--font-head);
  font-size: var(--fs-xs);
  letter-spacing: 0.1em;
  color: var(--teal);
  margin: 10px 0 6px;
  display: block;
}

.guide-doc img.screenshot {
  max-width: 100%;
  height: auto;
  border: 1px solid var(--border-soft);
  border-radius: var(--radius-sm);
  margin: 12px 0 18px;
  display: block;
}

.guide-doc a {
  color: var(--teal);
}

.guide-doc a:hover {
  color: var(--text);
}

.guide-doc strong {
  font-weight: var(--fw-bold);
  color: var(--text);
}

.guide-doc em {
  color: var(--muted2);
}

.guide-doc h1:target,
.guide-doc h2:target,
.guide-doc h3:target {
  scroll-margin-top: 16px;
}

.guide-cta {
  margin-top: 24px;
}

@media (max-width: 900px) {
  .guide-layout {
    flex-direction: column;
    gap: 0;
  }
  .guide-toc {
    position: static;
    max-height: none;
    border-right: none;
    border-bottom: 1px solid var(--border-soft);
    flex-basis: auto;
    width: 100%;
  }
  .guide-doc {
    max-width: none;
  }
}

@media print {
  .guide-toc {
    display: none;
  }
  .guide-doc {
    max-width: none;
  }
}
