/* The Aegisrook Library (/library/, /processes/…): process pages and their hubs. Builds on guides.css and help.css. */

/* Verdict badges, the same four as the app's "What is this?" card */
.verdict { display: inline-block; padding: 2px 10px; border-radius: 999px; font-size: .8rem; font-weight: 650; line-height: 1.6;
  white-space: nowrap; border: 1px solid currentColor; }
.verdict-safe { color: #11743A; background: #EAF7EF; }
.verdict-usuallySafe { color: #0058C2; background: #EAF2FD; }
.verdict-depends { color: #9A5300; background: #FFF4E5; }
.verdict-caution { color: #B42318; background: #FDECEA; }
@media (prefers-color-scheme: dark) {
  .verdict-safe { color: #6EE7A0; background: rgba(110,231,160,.1); }
  .verdict-usuallySafe { color: #7CCBFF; background: rgba(124,203,255,.1); }
  .verdict-depends { color: #FFC266; background: rgba(255,194,102,.1); }
  .verdict-caution { color: #FF8A80; background: rgba(255,138,128,.1); }
}
.guide-meta .verdict { font-size: .78rem; }

/* The facts box at the top of a process page, from shared/process-library.json */
.pfacts { background: var(--card); border: 1px solid var(--rule); border-radius: var(--radius-sm); box-shadow: var(--shadow);
  padding: 20px 24px; margin: 0 0 var(--g-s4, 40px); }
.pfacts-verdict { display: flex; flex-wrap: wrap; gap: 8px 12px; align-items: baseline; margin: 0 0 14px; color: var(--muted); font-size: .95rem; }
.pfacts dl { margin: 0; }
.pfacts dl > div { display: grid; grid-template-columns: 200px minmax(0, 1fr); gap: 4px 20px; padding: 11px 0; border-top: 1px solid var(--rule); }
.pfacts dt { font-weight: 600; color: var(--head); }
.pfacts dd { margin: 0; }
.pfacts code { font: .88em/1.5 var(--mono); overflow-wrap: anywhere; }
@media (max-width: 640px) {
  .pfacts { padding: 16px 16px; }
  .pfacts dl > div { grid-template-columns: minmax(0, 1fr); }
}

/* Lists of processes: hubs and "Related processes" */
.library-hub { padding: clamp(28px, 4vw, 56px) 0; }
.pgroup { max-width: 860px; margin: 0 auto 36px; scroll-margin-top: 110px; }
.pgroup h2 { font-size: 1.25rem; margin: 0 0 10px; }
.plist { list-style: none; margin: 0; padding: 0; }
.plist li { border-top: 1px solid var(--rule); }
.plist li:last-child { border-bottom: 1px solid var(--rule); }
.plist a { display: grid; grid-template-columns: auto auto minmax(0, 1fr); align-items: baseline; gap: 4px 12px; padding: 12px 2px;
  color: var(--text); text-decoration: none; }
.plist a .verdict { justify-self: start; }
.plist a b { font-family: var(--mono); font-size: .95rem; font-weight: 600; }
.plist a span:last-child { color: var(--muted); font-size: .93rem; }
.plist a:hover b, .plist a:focus-visible b { color: var(--link); }
.plinks .plist a { grid-template-columns: auto minmax(0, 1fr); }
.plinks { margin: var(--g-s4, 40px) 0; }
@media (max-width: 640px) {
  .plist a { grid-template-columns: auto minmax(0, 1fr); }
  .plist a span:last-child { grid-column: 1 / -1; }
}

/* /library/: the sections, planned ones greyed */
.lib-sections { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.lib-sections .help-group h2 a { color: inherit; text-decoration: none; }
.lib-soon { opacity: .75; }
.lib-soon-note { font-size: .8rem; font-weight: 700; letter-spacing: .08em; text-transform: uppercase; color: var(--muted); }
@media (max-width: 900px) { .lib-sections { grid-template-columns: minmax(0, 1fr); } }

/* The count under a centred hub heading */
.head.center .gcount { text-align: center; }
.head.center .gcount { margin-left: auto; margin-right: auto; }
/* Glossary: terms are words, not program names, so no code font; definitions line up in a second column. */
.glist a { grid-template-columns: minmax(0, 13rem) minmax(0, 1fr); }
.glist a b { font-family: inherit; font-size: 1rem; }
@media (max-width: 640px) { .glist a { grid-template-columns: minmax(0, 1fr); } }
