
/* Presentation of the existing read-only Library, using the published generator scale. */
:root {
  --ink: #111827;
  --muted: #596579;
  --line: #d1d5db;
  --accent: var(--brand-emerald-strong);
  --surface: #fff;
  --canvas: #eef2f7;
  --warm: #fff8eb;
  --warm-line: #ead7ac;
  --library-gutter: 24px;
  --library-gap: 12px;
  --service-nav-accent: var(--brand-emerald-strong);
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  background: var(--canvas);
  color: var(--ink);
  font: 400 14px/1.5 Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}
[hidden] { display: none !important; }
a { color: var(--accent); }
a:focus-visible { outline: 2px solid var(--accent); outline-offset: 3px; }
h1, h2, h3, p, dt, dd { overflow-wrap: anywhere; }
h1 { margin: 0 0 8px; font-size: 20px; font-weight: 600; line-height: 1.4; letter-spacing: -.2px; }
h2 { margin: 0; font-size: 18px; font-weight: 600; line-height: 1.4; letter-spacing: -.2px; }
h3 { margin: 0 0 12px; font-size: 15px; font-weight: 600; line-height: 1.4; }

.skip-link { position: absolute; left: 16px; top: -60px; z-index: 3; padding: 10px 16px; border-radius: 8px; background: var(--surface); }
.skip-link:focus { top: 12px; }
/* Reuse service-nav.css, with the same outer axis as the SPA shell. */
body .site-header:has(> .header-inner > .service-nav), .page {
  width: min(1180px, calc(100% - 32px));
  margin-inline: auto;
}
.nav-error { margin: 8px 0 0; color: #991b1b; font-size: 13px; }
.page { padding: 14px 0 48px; }
.hero, .template-section, .example-section {
  padding: var(--library-gutter);
  border: 1px solid #e5e7eb;
  border-radius: 12px;
  background: var(--surface);
  box-shadow: 0 4px 18px rgb(17 24 39 / 5%);
}
.hero { display: flex; align-items: flex-start; justify-content: space-between; gap: 24px; }
.hero > div { min-width: 0; max-width: 760px; }
.lead { margin: 0; color: var(--muted); font-size: 14px; }
.hero-status { display: flex; align-items: flex-start; gap: 10px; flex: 0 0 220px; padding: 12px; border: 1px solid var(--warm-line); border-radius: 8px; background: var(--warm); color: #5b492d; font-size: 13px; }
.hero-status strong, .hero-status span:last-child { display: block; }
.hero-status strong { margin-bottom: 3px; font-weight: 600; }
.hero-status span:last-child { font-size: 12px; }
.status-dot { width: 8px; height: 8px; flex: none; margin-top: 5px; border-radius: 50%; background: #996b24; }
.library-view-nav { display: flex; flex-wrap: wrap; gap: var(--library-gap); margin: 14px 0; }
.library-view-nav a, .section-nav a { display: inline-flex; align-items: center; min-height: 44px; padding: 10px 16px; border: 1px solid var(--line); border-radius: 8px; background: var(--surface); color: var(--accent); font-size: 14px; font-weight: 600; line-height: 1.35; text-decoration: none; }
.library-view-nav a:hover, .section-nav a:hover { border-color: var(--accent); background: var(--brand-emerald-soft); }
.template-section, .example-section, .section { scroll-margin-top: 16px; }
.example-section { margin-top: 16px; }
.section-head { display: flex; align-items: flex-start; gap: 12px; margin-bottom: 16px; }
.section-head > div { min-width: 0; }
.number { display: grid; place-items: center; flex: none; width: 36px; height: 36px; border: 1px solid var(--brand-emerald-line); border-radius: 8px; background: var(--brand-emerald-soft); color: var(--brand-emerald-pressed); font-size: 13px; font-weight: 600; }
.eyebrow { margin: 0 0 4px; color: var(--accent); font-size: 11px; font-weight: 600; letter-spacing: .06em; text-transform: uppercase; }
.section-intro { max-width: 900px; margin: 0 0 20px; color: var(--muted); }
.template-grid, .split { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: var(--library-gap); }
.cards, .time-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: var(--library-gap); }
.template-card, .panel, .doc-card, .time-card { min-width: 0; padding: 20px; border: 1px solid var(--line); border-radius: 8px; background: var(--surface); }
.template-fields { margin: 0; }
.template-fields > div { padding: 10px 0; border-top: 1px solid #e5e7eb; }
.template-fields > div:first-child { padding-top: 0; border-top: 0; }
.template-fields > div:last-child { padding-bottom: 0; }
.template-fields dt { font-size: 13px; font-weight: 600; }
.template-fields dd { margin: 4px 0 0; color: var(--muted); font-size: 13px; line-height: 1.5; }
.notice { padding: 12px 16px; border: 1px solid var(--warm-line); border-radius: 8px; background: var(--warm); color: #5b492d; font-size: 13px; }
.section-nav { display: flex; flex-wrap: wrap; gap: 8px; margin: 20px 0; }
.section-nav a { padding-inline: 12px; font-size: 13px; }
.section { padding: 24px 0; border-top: 1px solid #e5e7eb; }
.example-section > .section:last-child { padding-bottom: 0; }
.panel p, .doc-card p, .time-card p { margin: 0 0 12px; color: var(--muted); }
.panel p:last-child, .doc-card p:last-child, .time-card p:last-child { margin-bottom: 0; }
.sample-layout { max-width: none; }
.sample { background: #f9fafb; }
.tag { display: inline-block; margin-bottom: 12px; padding: 4px 8px; border-radius: 6px; font-size: 11px; font-weight: 600; line-height: 1.4; }
.warning { background: #fff1d9; color: #815819; }
.gap { padding-left: 12px; border-left: 3px solid #c49350; color: #765b35 !important; font-size: 13px; }
.doc-card, .time-card { display: flex; flex-direction: column; }
.card-index { display: block; margin-bottom: 12px; color: var(--accent); font-size: 11px; font-weight: 600; letter-spacing: .06em; text-transform: uppercase; }
.sample-box { display: grid; gap: 6px; margin: auto 0 14px; padding-top: 16px; border-top: 1px solid #e5e7eb; font-size: 13px; }
.sample-box strong { margin-bottom: 2px; color: var(--ink); font-weight: 600; }
.sample-box span { color: var(--muted); }
.callout { margin-top: 12px; padding: 12px 16px; border: 1px solid var(--brand-emerald-line); border-radius: 8px; background: var(--brand-emerald-soft); color: var(--brand-emerald-pressed); font-size: 13px; }
.empty { display: block; margin-top: auto; padding-top: 14px; color: #765b35; font-size: 13px; font-weight: 500; }
.footer { margin-top: 24px; padding-inline: var(--library-gutter); color: var(--muted); font-size: 12px; }
.back-link { text-decoration: none; border-bottom: 1px solid currentColor; }

@media (max-width: 900px) {
  .hero { flex-direction: column; gap: 16px; }
  .hero-status { flex-basis: auto; }
  .cards, .time-grid { grid-template-columns: 1fr; }
}
@media (max-width: 760px) {
  :root { --library-gutter: 16px; }
  .template-grid, .split { grid-template-columns: 1fr; }
  .template-card, .panel, .doc-card, .time-card { padding: 16px; }
}
@media(max-width:620px) {
  body .site-header:has(> .header-inner > .service-nav), .page { width: calc(100% - 28px); }
  .hero-status { width: 100%; }
  .library-view-nav { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .library-view-nav a { padding-inline: 12px; font-size: 13px; }
  .section-head { gap: 10px; }
  .section-nav { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .section-nav a { padding-inline: 10px; }
  .footer { padding-inline: 0; }
}
@media(prefers-reduced-motion:reduce) { html { scroll-behavior: auto; } }
