/* Shared nebx header and footer. Generated for every nebx site; keep identical across repositories. */
.nx-header, .nx-footer { font-family: inherit; -webkit-font-smoothing: antialiased; }
.nx-header *, .nx-footer * { box-sizing: border-box; }
.nx-wrap { max-width: 1200px; margin: 0 auto; padding-left: max(20px, env(safe-area-inset-left, 0px)); padding-right: max(20px, env(safe-area-inset-right, 0px)); }
.nx-header a, .nx-footer a { text-decoration: none; }
.nx-vh { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0; }

.nx-header { position: sticky; top: 0; z-index: 60; color: #f5f5f7; background: rgba(0, 0, 0, 0.8); backdrop-filter: saturate(180%) blur(20px); -webkit-backdrop-filter: saturate(180%) blur(20px); border-bottom: 1px solid rgba(255, 255, 255, 0.08); padding-top: env(safe-area-inset-top, 0px); }
.nx-bar { display: flex; align-items: center; gap: 10px; height: 56px; }
.nx-brand { display: inline-flex; align-items: center; flex: none; }
.nx-brand img { display: block; height: 24px; width: auto; }
.nx-crumb { color: #a1a1a6; font-size: 15px; font-weight: 600; white-space: nowrap; padding-left: 10px; border-left: 1px solid rgba(255, 255, 255, 0.18); line-height: 20px; }
.nx-crumb:hover { color: #f5f5f7; }
.nx-nav { display: flex; gap: 2px; margin-left: auto; min-width: 0; }
.nx-nav a, .nx-gh { color: #d2d2d7; font-size: 13px; font-weight: 500; line-height: 1.4; padding: 6px 11px; border-radius: 999px; white-space: nowrap; }
.nx-nav a:hover, .nx-gh:hover { color: #fff; background: rgba(255, 255, 255, 0.08); }
.nx-nav a[aria-current="page"] { color: #000; background: #81ffd9; }
.nx-gh { border: 1px solid rgba(255, 255, 255, 0.2); margin-left: 6px; }

.nx-theme { position: relative; flex: none; margin-left: 6px; }
.nx-theme summary { list-style: none; display: inline-flex; align-items: center; justify-content: center; width: 34px; height: 34px; border-radius: 999px; border: 1px solid rgba(255, 255, 255, 0.2); color: #f5f5f7; cursor: pointer; user-select: none; }
.nx-theme summary::-webkit-details-marker { display: none; }
.nx-theme summary:hover, .nx-theme[open] summary { background: rgba(255, 255, 255, 0.08); }
.nx-theme svg { width: 16px; height: 16px; fill: none; stroke: currentColor; stroke-width: 1.4; stroke-linecap: round; stroke-linejoin: round; flex: none; }
.nx-ti { display: none; }
html:not([data-theme-pref]) .nx-ti-system, html[data-theme-pref="system"] .nx-ti-system, html[data-theme-pref="light"] .nx-ti-light, html[data-theme-pref="dark"] .nx-ti-dark { display: inline-flex; }
.nx-theme-panel { position: absolute; right: 0; top: calc(100% + 10px); min-width: 170px; display: flex; flex-direction: column; gap: 2px; padding: 6px; background: #111113; border: 1px solid rgba(255, 255, 255, 0.12); border-radius: 14px; box-shadow: 0 24px 48px rgba(0, 0, 0, 0.5); z-index: 70; }
.nx-theme-panel button { display: flex; align-items: center; gap: 10px; width: 100%; padding: 8px 10px; border-radius: 10px; border: 0; background: none; color: #f5f5f7; font: 500 14px/1.3 inherit; font-family: inherit; cursor: pointer; text-align: left; }
.nx-theme-panel button:hover, .nx-theme-panel button:focus-visible { background: rgba(255, 255, 255, 0.07); }
.nx-theme-panel button[aria-checked="true"] { color: #81ffd9; }
.nx-theme-panel button[aria-checked="true"]::after { content: "✓"; margin-left: auto; font-weight: 700; }
.nx-menu { display: none; position: relative; margin-left: 6px; }
.nx-menu summary { list-style: none; display: inline-flex; align-items: center; gap: 8px; cursor: pointer; color: #f5f5f7; font-size: 14px; font-weight: 600; padding: 7px 12px; border: 1px solid rgba(255, 255, 255, 0.2); border-radius: 999px; user-select: none; }
.nx-menu summary::-webkit-details-marker { display: none; }
.nx-burger, .nx-burger::before, .nx-burger::after { display: block; width: 14px; height: 1.5px; background: currentColor; border-radius: 2px; transition: transform 0.2s ease, opacity 0.2s ease; }
.nx-burger { position: relative; }
.nx-burger::before, .nx-burger::after { content: ""; position: absolute; left: 0; }
.nx-burger::before { top: -4.5px; }
.nx-burger::after { top: 4.5px; }
.nx-menu[open] .nx-burger { background: transparent; }
.nx-menu[open] .nx-burger::before { transform: translateY(4.5px) rotate(45deg); }
.nx-menu[open] .nx-burger::after { transform: translateY(-4.5px) rotate(-45deg); }
.nx-panel { position: absolute; right: 0; top: calc(100% + 10px); width: min(320px, calc(100vw - 32px)); display: flex; flex-direction: column; gap: 2px; padding: 8px; background: #111113; border: 1px solid rgba(255, 255, 255, 0.12); border-radius: 18px; box-shadow: 0 24px 48px rgba(0, 0, 0, 0.5); max-height: calc(100vh - 90px); overflow-y: auto; }
.nx-panel a { display: flex; flex-direction: column; gap: 1px; padding: 10px 12px; border-radius: 12px; color: #f5f5f7; }
.nx-panel a:hover { background: rgba(255, 255, 255, 0.07); }
.nx-panel a[aria-current="page"] { background: rgba(129, 255, 217, 0.12); }
.nx-panel a[aria-current="page"] b { color: #81ffd9; }
.nx-panel b { font-size: 15px; font-weight: 700; }
.nx-panel span { font-size: 13px; color: #a1a1a6; }

@media (max-width: 900px) {
  .nx-nav, .nx-gh { display: none; }
  .nx-theme { margin-left: auto; }
  .nx-menu { display: block; }
}
@media (max-width: 360px) { .nx-menu-label { display: none; } }

.nx-footer { background: #000; color: #a1a1a6; font-size: 14px; line-height: 1.6; border-top: 1px solid rgba(255, 255, 255, 0.08); padding-bottom: env(safe-area-inset-bottom, 0px); }
.nx-cols { display: grid; grid-template-columns: 1.6fr 1fr 1fr 1fr; gap: 32px; padding-top: 56px; padding-bottom: 36px; }
.nx-about { display: flex; flex-direction: column; gap: 12px; align-items: flex-start; }
.nx-about p { margin: 0; max-width: 34ch; }
.nx-brand img[width="96"] { height: 26px; }
.nx-note { font-size: 13px; color: #86868b; }
.nx-pref { display: inline-block; margin-top: 4px; border-radius: 10px; transition: opacity 0.2s ease; }
.nx-pref:hover { opacity: 0.85; }
.nx-pref img { display: block; width: 169px; height: auto; }
.nx-h { margin: 0 0 12px; color: #f5f5f7; font-size: 12px; font-weight: 700; letter-spacing: 0.12em; text-transform: uppercase; }
.nx-footer ul { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 8px; }
.nx-footer ul a { color: #d2d2d7; }
.nx-footer ul a:hover { color: #fff; text-decoration: underline; }
.nx-footer ul a[aria-current="page"] { color: #81ffd9; }
.nx-footer .foot-consent { background: none; border: 0; padding: 0; color: #d2d2d7; font: inherit; cursor: pointer; text-align: left; }
.nx-footer .foot-consent:hover { color: #fff; text-decoration: underline; }
.nx-legal { display: flex; justify-content: space-between; flex-wrap: wrap; gap: 8px; padding-top: 20px; padding-bottom: 28px; border-top: 1px solid rgba(255, 255, 255, 0.08); font-size: 13px; color: #86868b; }
.nx-legal a { color: #d2d2d7; text-decoration: underline; text-underline-offset: 3px; text-decoration-color: rgba(210, 210, 215, 0.5); }
.nx-legal a:hover { color: #fff; text-decoration: underline; }
@media (max-width: 860px) {
  .nx-cols { grid-template-columns: 1fr 1fr; }
  .nx-about { grid-column: 1 / -1; }
}

/* Short pages (404, short link pages): keep the footer at the bottom of the window, not halfway up it. */
body:has(> .nx-footer) { min-height: 100vh; min-height: 100dvh; display: flex; flex-direction: column; }
body:has(> .nx-footer) > main { flex: 1 0 auto; width: 100%; }

/* Confirm and alert dialogs (public/assets/nebx-dialog.js), in place of the browser's confirm() and alert(). */
.nx-dialog { --nxd-bg: #ffffff; --nxd-ink: #1d1d1f; --nxd-muted: #6e6e73; --nxd-line: rgba(0, 0, 0, 0.12); --nxd-btn: #f5f5f7; --nxd-btn-hover: #e8e8ed; --nxd-danger: #d70015; }
@media (prefers-color-scheme: dark) { :root:not([data-theme="light"]) .nx-dialog { --nxd-bg: #1c1c1e; --nxd-ink: #f5f5f7; --nxd-muted: #a1a1a6; --nxd-line: rgba(255, 255, 255, 0.12); --nxd-btn: #2c2c2e; --nxd-btn-hover: #3a3a3c; --nxd-danger: #ff453a; } }
:root[data-theme="dark"] .nx-dialog { --nxd-bg: #1c1c1e; --nxd-ink: #f5f5f7; --nxd-muted: #a1a1a6; --nxd-line: rgba(255, 255, 255, 0.12); --nxd-btn: #2c2c2e; --nxd-btn-hover: #3a3a3c; --nxd-danger: #ff453a; }
.nx-dialog { box-sizing: border-box; width: min(440px, calc(100vw - 32px)); margin: auto; padding: 24px; border: 1px solid var(--nxd-line); border-radius: 20px; background: var(--nxd-bg); color: var(--nxd-ink); font-family: inherit; -webkit-font-smoothing: antialiased; box-shadow: 0 30px 80px rgba(0, 0, 0, 0.35); }
.nx-dialog::backdrop { background: rgba(0, 0, 0, 0.45); backdrop-filter: blur(4px); -webkit-backdrop-filter: blur(4px); }
.nx-dialog[open] { animation: nx-dialog-in 0.18s ease-out; }
@keyframes nx-dialog-in { from { opacity: 0; transform: translateY(8px) scale(0.98); } }
@media (prefers-reduced-motion: reduce) { .nx-dialog[open] { animation: none; } }
.nx-dialog-title { margin: 0; font-size: 19px; font-weight: 700; line-height: 1.3; letter-spacing: -0.01em; }
.nx-dialog-msg { margin: 8px 0 0; color: var(--nxd-muted); font-size: 15px; line-height: 1.5; overflow-wrap: anywhere; }
.nx-dialog-actions { display: flex; justify-content: flex-end; flex-wrap: wrap; gap: 10px; margin-top: 24px; }
.nx-dialog-btn { min-height: 40px; padding: 9px 18px; border-radius: 999px; border: 1px solid transparent; background: var(--nxd-btn); color: var(--nxd-ink); font-family: inherit; font-size: 14px; font-weight: 600; line-height: 1.2; cursor: pointer; }
.nx-dialog-btn:hover { background: var(--nxd-btn-hover); }
.nx-dialog-btn:focus-visible { outline: 2px solid #0071e3; outline-offset: 2px; }
.nx-dialog-primary { background: #81ffd9; color: #000; }
.nx-dialog-primary:hover { background: #a6ffe5; }
.nx-dialog-danger { background: var(--nxd-danger); color: #fff; }
.nx-dialog-danger:hover { background: var(--nxd-danger); filter: brightness(1.08); }
@media (max-width: 420px) { .nx-dialog-actions { flex-direction: column-reverse; } .nx-dialog-btn { width: 100%; } }
