/* OpenVibe.Help — theme-token driven (openvibe-shared presets). Every page works without JavaScript. */
:root { color-scheme: dark; }
* { box-sizing: border-box; }
body { margin: 0; background: var(--bg-primary, #0a0f1c); color: var(--text-primary, #e6edf7); font: 16px/1.6 system-ui, -apple-system, "Segoe UI", Roboto, sans-serif; }
a { color: var(--accent-light, #60a5fa); }
a:focus-visible, button:focus-visible, input:focus-visible, textarea:focus-visible, select:focus-visible, summary:focus-visible { outline: 3px solid var(--accent, #3b82f6); outline-offset: 2px; }
.skip { position: absolute; left: -9999px; }
.skip:focus { left: 16px; top: 8px; background: var(--bg-card, #131c2e); padding: 8px 12px; z-index: 10; }
.account-bar { max-width: 1080px; margin: 0 auto; padding: 6px 16px 0; text-align: right; font-size: 14px; color: var(--text-secondary, #96a7c2); }
.page { max-width: 1080px; margin: 0 auto; padding: 16px 16px 64px; min-height: 60vh; }
h1 { font-size: 1.8rem; line-height: 1.2; margin: 1rem 0 .6rem; overflow-wrap: anywhere; }
h2 { font-size: 1.3rem; margin: 1.8rem 0 .5rem; }
h3 { font-size: 1.08rem; margin: 1.2rem 0 .4rem; }
.muted { color: var(--text-muted, #7386a3); }
.small { font-size: .85rem; }
.crumbs { font-size: .9rem; color: var(--text-muted, #7386a3); margin: 8px 0; overflow-wrap: anywhere; }
code, pre { font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace; font-size: .88em; }
code { overflow-wrap: anywhere; }
pre { background: var(--bg-secondary, #0f1729); border: 1px solid var(--border, #1f2d47); border-radius: 8px; padding: 10px 12px; overflow-x: auto; white-space: pre; }
pre code { overflow-wrap: normal; }
.table-wrap { overflow-x: auto; }
table { border-collapse: collapse; width: 100%; font-size: .92rem; }
th, td { text-align: left; vertical-align: top; padding: 7px 9px; border-bottom: 1px solid var(--border, #1f2d47); }
th { color: var(--text-secondary, #96a7c2); font-weight: 600; }
.badge { display: inline-block; font-size: .75rem; padding: 0 8px; border-radius: 999px; border: 1px solid var(--border-light, #2c3d5c); white-space: nowrap; line-height: 1.6; }
.badge.ok { border-color: var(--success, #22c55e); color: var(--success, #22c55e); }
.badge.info { border-color: var(--info, #38bdf8); color: var(--info, #38bdf8); }
.badge.warn { border-color: var(--warning, #f59e0b); color: var(--warning, #f59e0b); }
.badge.bad { border-color: var(--error, #ef4444); color: var(--error, #ef4444); }
.notice { border-left: 3px solid var(--info, #38bdf8); padding: 8px 12px; margin: 12px 0; background: var(--bg-card, #131c2e); border-radius: 0 8px 8px 0; }
.notice.ok { border-left-color: var(--success, #22c55e); }
.notice.warn { border-left-color: var(--warning, #f59e0b); }
.notice.bad { border-left-color: var(--error, #ef4444); }
button { font: inherit; cursor: pointer; }
form.inline { display: inline; }
.prose { max-width: 820px; overflow-wrap: anywhere; }
.prose table { margin: .6rem 0; }
.sr-only { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0,0,0,0); white-space: nowrap; border: 0; }

/* The home page's showcase sections (openvibe-shared/showcase.css) sit inside .page, which has its own gutter. */
.page .sc-hero, .page .sc-sec, .page .sc-cta { padding-left: 0; padding-right: 0; }
.page .sc-ic .ov-icon { --ovi-size: 28px !important; }
button.sc-btn { background: transparent; }
button.sc-btn.sc-primary { border: 0; }

/* ── The help centre ─────────────────────────────────────── */
/* Plain text a person typed or a manifest states: escaped, and its own line breaks kept. */
.txt { white-space: pre-wrap; overflow-wrap: anywhere; margin: .5rem 0; }
.search-form { display: flex; gap: 8px; flex-wrap: wrap; margin: 12px 0; }
.search-form input[type="search"] { flex: 1 1 24rem; min-width: 0; padding: 10px 12px; font: inherit; color: inherit; background: var(--bg-secondary, #0f1729); border: 1px solid var(--border, #1f2d47); border-radius: 8px; }
.search-big input[type="search"] { padding: 14px 16px; font-size: 1.1rem; }
.q-list, .site-list, .results, .ticket-list, .pillars, .conversation { list-style: none; padding: 0; margin: 12px 0; }
.q-list li, .site-list li, .results li, .ticket-list li { padding: 7px 0; border-bottom: 1px solid var(--border, #1f2d47); }
.site-list li .muted, .ticket-list li .muted { margin-left: 6px; }
.site-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(15rem, 1fr)); gap: 6px 16px; list-style: none; padding: 0; margin: 12px 0; }
.results li p { margin: 2px 0; }
.results.net li { border-bottom-style: dotted; }
mark { background: var(--warning, #f59e0b); color: #10151f; border-radius: 3px; }
.faq-item { margin: 0 0 1.6rem; scroll-margin-top: 1rem; }
.faq-item h3 { margin-bottom: .2rem; }
.prov { margin: 10px 0; }
.site-links { display: flex; gap: 8px; flex-wrap: wrap; margin: 12px 0; }
.card { background: var(--bg-card, #131c2e); border: 1px solid var(--border, #1f2d47); border-radius: 10px; padding: 14px 16px; margin: 14px 0; }
.ticket-form .field, .filters .field { margin: 12px 0; }
.field label, .reply-form label { display: block; font-weight: 600; margin-bottom: 4px; }
.field input[type="text"], .field select, .field textarea, .reply-form textarea { width: 100%; padding: 9px 11px; font: inherit; color: inherit; background: var(--bg-secondary, #0f1729); border: 1px solid var(--border, #1f2d47); border-radius: 8px; resize: vertical; }
.field select { max-width: 32rem; }
.filters { display: flex; gap: 16px; flex-wrap: wrap; align-items: end; }
.ticket-list li span { display: block; }
.conversation { display: flex; flex-direction: column; gap: 10px; }
.msg { border-left: 3px solid var(--border-light, #2c3d5c); padding: 8px 12px; background: var(--bg-card, #131c2e); border-radius: 0 8px 8px 0; }
.msg.staff { border-left-color: var(--accent, #3b82f6); }
.msg-meta { margin: 0 0 4px; }
.state-form label.radio { margin-right: 16px; }

/* ── Home: popular questions and the site cards ── */
.q-list { list-style: none; margin: 0; padding: 0; display: grid; gap: 8px; grid-template-columns: repeat(auto-fill, minmax(min(320px, 100%), 1fr)); }
.q-list li { display: flex; flex-direction: column; gap: 4px; padding: 12px 14px; border-radius: 12px; border: 1px solid var(--border, #1f2d47); background: var(--bg-card, #131c2e); }
.q-list li a { font-weight: 600; text-decoration: none; color: var(--text-primary, #e6edf7); }
.q-list li a:hover { color: var(--accent-light, #60a5fa); }
.q-site { font-size: .78rem; font-weight: 700; letter-spacing: .4px; text-transform: uppercase; color: var(--text-muted, #7386a3); }
.site-cards { list-style: none; margin: 0; padding: 0; display: grid; gap: 10px; grid-template-columns: repeat(auto-fill, minmax(min(220px, 100%), 1fr)); }
.site-card { display: flex; flex-direction: column; gap: 4px; height: 100%; padding: 12px 14px; border-radius: 12px; border: 1px solid var(--border, #1f2d47); background: var(--bg-secondary, #101828); color: inherit; text-decoration: none; transition: border-color .15s, transform .15s; }
.site-card:hover { border-color: var(--accent, #3b82f6); transform: translateY(-1px); }
/* Not open yet: a dashed outline and no fill, never faded text (opacity took it below WCAG AA contrast). */
.site-card.coming { border-style: dashed; background: transparent; }
.site-card-top { display: flex; align-items: center; justify-content: space-between; gap: 8px; }
.site-state { font-size: .7rem; font-weight: 700; padding: 1px 8px; border-radius: 999px; border: 1px solid var(--border-light, #2c3d5c); color: var(--text-secondary, #96a7c2); }
.site-card:not(.coming) .site-state { color: var(--success, #22c55e); border-color: color-mix(in srgb, var(--success, #22c55e) 45%, transparent); }
.site-card-line { font-size: .86rem; line-height: 1.4; color: var(--text-secondary, #96a7c2); }
@media (prefers-reduced-motion: reduce) { .site-card { transition: none; } }

/* The home: the figures beside the hero, the popular questions with their answers, each site's answer count. */
.help-stats { margin: 0; display: grid; gap: 10px; }
.help-stats div { border: 1px solid var(--border, #1f2d47); border-radius: 12px; padding: 12px 16px; background: var(--bg-card, #131c2e); }
.help-stats dt { font-size: 1.25rem; font-weight: 700; color: var(--text-primary, #e6edf7); }
.help-stats dd { margin: 2px 0 0; color: var(--text-secondary, #96a7c2); font-size: .92rem; }
.q-faq { display: grid; gap: 8px; margin: 12px 0; }
.q-faq details { border: 1px solid var(--border, #1f2d47); border-radius: 12px; padding: 4px 16px; background: var(--bg-card, #131c2e); }
.q-faq details[open] { padding-bottom: 12px; }
.q-faq summary { cursor: pointer; font-weight: 600; padding: 10px 0; display: flex; flex-wrap: wrap; justify-content: space-between; gap: 4px 12px; }
.q-faq summary .q-site { font-weight: 400; }
.q-faq details p { margin: 4px 0 0; color: var(--text-secondary, #96a7c2); overflow-wrap: anywhere; }
.site-card-count { margin-top: auto; font-size: .8rem; color: var(--text-secondary, #96a7c2); }
