/* Shared by connections.html, communities.html and community.html. Same tokens as index.html and profile.html
   (docs/brand/BRAND.md): slate neutrals, blue for actions, apto teal for wayfinding only. Text on a primary button is
   --on-primary (white, and slate-900 in dark, where white on #3b82f6 is under 4.5:1); links on a tinted panel are
   --link-panel (#3b82f6 on #1e293b is under 4.5:1 in dark). api/tests/test_pages_a11y.py checks the pairs. */
:root { --bg: #ffffff; --panel: #f1f5f9; --fg: #0f172a; --muted: #5c6a80; --line: #e2e8f0; --input: #64748b; --input-hover: #475569; --primary: #2563eb;
  --primary-hover: #1d4ed8; --teal: #26827b; --bad: #dc2626; --on-primary: #ffffff; --link-panel: #2563eb;
  --f-display: "Inter Tight", Inter, "Segoe UI", system-ui, -apple-system, Arial, sans-serif;
  --f-body: Inter, "Segoe UI", system-ui, -apple-system, Arial, sans-serif; }
@media (prefers-color-scheme: dark) { :root:not([data-theme="light"]) {
  --bg: #020817; --panel: #1e293b; --fg: #f8fafc; --muted: #94a3b8; --line: #1e293b; --input: #64748b; --input-hover: #94a3b8; --primary: #3b82f6;
  --primary-hover: #60a5fa; --teal: #30b5a8; --bad: #f87171; --on-primary: #0f172a; --link-panel: #60a5fa;
  color-scheme: dark } }
:root[data-theme="dark"] { --bg: #020817; --panel: #1e293b; --fg: #f8fafc; --muted: #94a3b8; --line: #1e293b; --input: #64748b; --input-hover: #94a3b8;
  --primary: #3b82f6; --primary-hover: #60a5fa; --teal: #30b5a8; --bad: #f87171; --on-primary: #0f172a;
  --link-panel: #60a5fa; color-scheme: dark }
* { box-sizing: border-box; }
body { margin: 0; background: var(--bg); color: var(--fg); font: 15.5px/1.6 var(--f-body);
  font-feature-settings: 'cv02','cv03','cv04','cv11'; overflow-wrap: anywhere; }
header { border-bottom: 1px solid var(--line); }
.bar { max-width: 52rem; margin: 0 auto; min-height: 72px; padding: 0 16px; display: flex; align-items: center;
  justify-content: space-between; gap: 16px; }
.mark { width: 40px; height: 40px; background: currentColor; display: inline-block; vertical-align: middle;
  -webkit-mask: url(crow-mask.png) center / contain no-repeat; mask: url(crow-mask.png) center / contain no-repeat; }
.word { font: 600 18px/1.05 var(--f-display); display: inline-block; vertical-align: middle; margin-left: 10px; }
.product { font: 650 15px/1 var(--f-display); color: var(--teal); text-decoration: none; }
nav.site { max-width: 52rem; margin: 0 auto; padding: 0 16px; display: flex; flex-wrap: wrap; gap: 4px 20px;
  font-size: 14px; }
nav.site a { color: var(--fg); text-decoration: none; padding: 10px 0 8px; border-bottom: 2px solid transparent; }
nav.site a:hover { color: var(--primary); }
nav.site a[aria-current="page"] { border-bottom-color: var(--teal); font-weight: 600; }
main { max-width: 52rem; margin: 0 auto; padding: 32px 16px 80px; }
h1 { font: 650 32px/1.15 var(--f-display); letter-spacing: -0.02em; margin: 0 0 8px; text-wrap: balance; }
h2 { font: 650 19px/1.3 var(--f-display); letter-spacing: -0.018em; margin: 36px 0 8px; padding-top: 12px;
  border-top: 2px solid var(--teal); display: inline-block; }
h3 { font: 650 16px/1.3 var(--f-display); margin: 0 0 4px; }
.lede { color: var(--muted); margin: 0 0 8px; }
.hint { font-size: 12.5px; color: var(--muted); margin: 4px 0 0; }
label { font-weight: 600; font-size: 14px; display: block; margin: 14px 0 4px; }
label.inline { display: inline-flex; align-items: center; gap: 8px; font-weight: 400; font-size: 14.5px; margin: 0 16px 0 0; }
input[type=text], textarea, select { width: 100%; font: inherit; font-size: 14.5px; color: var(--fg); background: var(--bg);
  border: 1px solid var(--input); border-radius: 8px; padding: 8px 10px; }
input[type=text]:hover, textarea:hover, select:hover { border-color: var(--input-hover); }
input[type=checkbox], input[type=radio] { accent-color: var(--primary); }
textarea { min-height: 5.5rem; resize: vertical; }
fieldset { border: 0; padding: 0; margin: 14px 0 0; }
legend { font-weight: 600; font-size: 14px; padding: 0; margin-bottom: 4px; }
.actions { display: flex; flex-wrap: wrap; gap: 10px; align-items: center; margin-top: 14px; }
.btn { font: 600 14px/1 var(--f-body); color: var(--on-primary); background: var(--primary); border: 1px solid transparent;
  border-radius: 8px; padding: 10px 14px; cursor: pointer; text-decoration: none; display: inline-block; }
.btn:hover { background: var(--primary-hover); }
.btn.quiet { background: transparent; color: var(--primary); border-color: var(--line); }
.btn.quiet:hover { border-color: var(--primary); }
.btn.small { padding: 7px 11px; font-size: 13px; }
.btn:disabled { opacity: .5; cursor: not-allowed; }
.msg { font-size: 14px; color: var(--muted); margin: 8px 0 0; }
.msg:empty { display: none; }
.msg.err { color: var(--bad); }
.count { font-size: 12.5px; color: var(--muted); text-align: right; margin-top: 2px; }
.count.over { color: var(--bad); }
ul.rows { list-style: none; margin: 8px 0 0; padding: 0; }
ul.rows > li { border: 1px solid var(--line); border-radius: 8px; padding: 12px 14px; margin-bottom: 8px; }
.row { display: flex; flex-wrap: wrap; gap: 8px 16px; align-items: flex-start; justify-content: space-between; }
.row > .main { flex: 1 1 16rem; min-width: 0; }
.meta { font-size: 13px; color: var(--muted); }
.guid { font-family: ui-monospace, "Cascadia Mono", Consolas, monospace; font-size: 13.5px; }
.note { margin: 6px 0 0; white-space: pre-wrap; }
.empty { color: var(--muted); font-size: 14px; margin: 8px 0 0; }
.tag { display: inline-block; font-size: 12.5px; border: 1px solid var(--line); border-radius: 999px; padding: 1px 9px;
  margin: 2px 4px 2px 0; }
.panel { background: var(--panel); border-radius: 8px; padding: 14px 16px; margin-top: 12px; }
.panel a:not(.btn), .panel .btn.quiet { color: var(--link-panel); }
/* On the page background, not the tint: error text and the teal suggestion stay above 4.5:1 in light. */
.panel.warn { background: var(--bg); border: 1px solid var(--line); border-left: 3px solid var(--bad); }
.suggest { border-left: 3px solid var(--teal); padding-left: 12px; margin-top: 8px; }
.suggest strong { color: var(--teal); }
a { color: var(--primary); }
:focus-visible { outline: 2px solid var(--primary); outline-offset: 2px; }
@media (prefers-reduced-motion: reduce) { * { transition: none !important; } }

/* Dialogs from people-actions.js and community.html */
dialog.pa { border: 1px solid var(--line); border-radius: 8px; background: var(--bg); color: var(--fg); padding: 20px;
  width: min(32rem, calc(100vw - 32px)); max-width: calc(100vw - 32px); }
dialog.pa::backdrop { background: rgba(2, 8, 23, .55); }
dialog.pa h2 { margin-top: 0; }

/* find.html (C2a, C2b): open-to badges and possible conflicts, matched works */
.tag.open { border-color: var(--teal); color: var(--teal); font-weight: 600; }
.tag.conflict { border-color: var(--bad); color: var(--bad); }
ul.works { margin: 6px 0 0; padding-left: 18px; font-size: 14px; }
ul.works li { margin: 2px 0; }
h2 .meta { font: 400 13px/1 var(--f-body); margin-left: 6px; letter-spacing: 0; }

/* The notices bell (ui.js, D2b): in every page's header for signed-in members */
.nt-wrap { position: relative; margin-left: auto; }
.nt-bell { font: 600 14px/1 var(--f-body); color: var(--fg); background: transparent; border: 1px solid var(--line);
  border-radius: 999px; padding: 7px 12px; cursor: pointer; display: inline-flex; align-items: center; gap: 6px; }
.nt-bell:hover { border-color: var(--primary); }
.nt-icon { width: 16px; height: 16px; background: currentColor; display: inline-block;
  -webkit-mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath d='M12 2a6 6 0 0 0-6 6v4l-2 4h16l-2-4V8a6 6 0 0 0-6-6zm0 20a3 3 0 0 0 3-3H9a3 3 0 0 0 3 3z'/%3E%3C/svg%3E") center / contain no-repeat;
  mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath d='M12 2a6 6 0 0 0-6 6v4l-2 4h16l-2-4V8a6 6 0 0 0-6-6zm0 20a3 3 0 0 0 3-3H9a3 3 0 0 0 3 3z'/%3E%3C/svg%3E") center / contain no-repeat; }
.nt-badge { background: var(--primary); color: var(--on-primary); border-radius: 999px; font-size: 12px; padding: 2px 7px; }
.nt-badge[hidden] { display: none; }
.nt-panel { position: absolute; right: 0; top: calc(100% + 8px); z-index: 20; width: min(24rem, calc(100vw - 32px));
  background: var(--bg); border: 1px solid var(--line); border-radius: 8px; padding: 12px 14px;
  box-shadow: 0 8px 24px rgba(2, 8, 23, .18); }
.nt-panel[hidden] { display: none; }
.nt-head { display: flex; align-items: center; justify-content: space-between; gap: 8px; }
ul.nt-list { list-style: none; margin: 8px 0 0; padding: 0; max-height: 60vh; overflow-y: auto; }
li.nt { display: flex; gap: 10px; padding: 8px 0; border-top: 1px solid var(--line); }
li.nt .nt-main { min-width: 0; flex: 1; }
.nt-dot { width: 8px; height: 8px; border-radius: 50%; margin-top: 8px; flex: none; background: transparent; }
li.nt.unread .nt-dot { background: var(--teal); }
li.nt.unread .nt-link { font-weight: 600; }
.nt-link { color: var(--fg); text-decoration: none; }
.nt-link:hover { color: var(--primary); text-decoration: underline; }
.nt-foot { margin: 8px 0 0; font-size: 13px; }
@media (max-width: 480px) { .nt-word { display: none; } .nt-wrap { position: static; }
  .nt-panel { left: 16px; right: 16px; width: auto; } }

/* index.html, the home page for members (D2b) */
.home-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 22rem), 1fr)); gap: 0 32px; }
.quick { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 12px; }
