/* Arctura static site shell — present in document markup, enhanced only after first paint. */
:root {
  --shell-ink: var(--ink, #071018);
  --shell-surface: var(--surface, #0b1721);
  --shell-surface-2: var(--surface-2, #102431);
  --shell-paper: var(--paper, #eaf2f0);
  --shell-muted: var(--muted, #a4b6b5);
  --shell-line: var(--line, rgba(214, 240, 234, .17));
  --shell-signal: var(--signal, var(--mint, #9de6d2));
  --shell-content: min(1160px, calc(100% - 48px));
}

html { overflow-x: clip; }
body { overflow-x: clip; }

.site-shell {
  position: sticky !important;
  top: 0;
  z-index: 100;
  width: 100%;
  min-height: 68px;
  border-bottom: 1px solid var(--shell-line);
  background: rgba(7, 16, 24, .95);
  color: var(--shell-paper);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
}

.site-shell__inner {
  display: flex;
  width: var(--shell-content);
  min-height: 68px;
  margin: 0 auto;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
}

.site-shell__brand {
  display: inline-flex;
  flex: 0 0 auto;
  align-items: center;
  gap: .65rem;
  color: var(--shell-paper) !important;
  font: 800 .76rem/1 ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif !important;
  letter-spacing: .14em;
  text-decoration: none !important;
  text-transform: uppercase;
  white-space: nowrap;
}

.site-shell__brand-mark {
  width: .56rem;
  height: .56rem;
  border-radius: 50%;
  background: var(--shell-signal);
  box-shadow: 0 0 .85rem rgba(157, 230, 210, .85);
}

.site-shell__brand strong { color: var(--shell-signal); font: inherit; }
.site-shell__brand em { color: var(--shell-paper); font: inherit; font-style: normal; }

.site-shell__nav {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: .08rem;
}

.site-shell__link,
.site-shell__toggle {
  display: inline-flex;
  min-height: 44px;
  align-items: center;
  justify-content: center;
  border: 1px solid transparent;
  padding: .55rem .66rem;
  color: var(--shell-muted) !important;
  background: transparent;
  font: 800 .66rem/1 ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif !important;
  letter-spacing: .09em;
  text-decoration: none !important;
  text-transform: uppercase;
}

.site-shell__toggle { cursor: pointer; }
.site-shell__link:hover,
.site-shell__link:focus-visible,
.site-shell__link[aria-current="page"],
.site-shell__toggle:hover,
.site-shell__toggle:focus-visible,
.site-shell__toggle[aria-expanded="true"] {
  border-color: var(--shell-line);
  color: var(--shell-paper) !important;
  outline: none;
}

.site-shell__link--support {
  border-color: rgba(157, 230, 210, .35);
  color: var(--shell-signal) !important;
}

.site-shell__menu-wrap { position: relative; display: none; }
.site-shell__menu {
  position: absolute;
  top: calc(100% + .55rem);
  right: 0;
  width: min(25rem, calc(100vw - 2rem));
  padding: .9rem;
  border: 1px solid var(--shell-line);
  background: var(--shell-surface);
  box-shadow: 0 1.5rem 3.5rem rgba(0, 0, 0, .34);
}
.site-shell__menu[hidden] { display: none; }
.site-shell__menu-title {
  margin: .25rem .35rem .7rem;
  color: var(--shell-signal);
  font: 800 .62rem/1 ui-sans-serif, system-ui, sans-serif;
  letter-spacing: .14em;
  text-transform: uppercase;
}
.site-shell__menu-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: .3rem; }
.site-shell__menu a {
  display: block;
  padding: .65rem .7rem;
  border: 1px solid transparent;
  color: var(--shell-muted) !important;
  font: 700 .72rem/1.25 ui-sans-serif, system-ui, sans-serif;
  letter-spacing: .03em;
  text-decoration: none !important;
}
.site-shell__menu a:hover,
.site-shell__menu a:focus-visible {
  border-color: var(--shell-line);
  color: var(--shell-paper) !important;
  background: rgba(157, 230, 210, .06);
  outline: none;
}

@media (max-width: 780px) {
  :root { --shell-content: min(100% - 32px, 1160px); }
  .site-shell { min-height: 64px; }
  .site-shell__inner { min-height: 64px; }
  .site-shell__brand { font-size: .7rem !important; letter-spacing: .11em; }
  .site-shell__brand em { display: none; }
  .site-shell__nav > .site-shell__link { display: none; }
  .site-shell__nav > .site-shell__link--support { display: inline-flex; }
  .site-shell__menu-wrap { display: block; }
  .site-shell__menu {
    position: fixed;
    top: 64px;
    right: 0;
    left: 0;
    width: 100%;
    max-height: calc(100dvh - 64px);
    padding: 1rem max(1rem, calc((100% - 1160px) / 2)) max(1.5rem, env(safe-area-inset-bottom));
    overflow-y: auto;
    border-right: 0;
    border-left: 0;
    background: var(--shell-ink);
  }
  .site-shell__menu-grid { grid-template-columns: 1fr; }
  .site-shell__menu a { display: flex; min-height: 48px; align-items: center; padding: .8rem .75rem; }
}

@media (max-width: 440px) {
  :root { --shell-content: min(100% - 24px, 1160px); }
  .site-shell__link--support { display: none !important; }
  .site-shell__toggle { min-width: 4.25rem; padding-right: 0; }
}

@media (prefers-reduced-motion: reduce) {
  .site-shell, .site-shell * { scroll-behavior: auto !important; transition: none !important; }
}

/* Legacy routes sometimes style every nav element. Keep the shared shell isolated. */
.site-shell .site-shell__nav {
  position: static !important;
  top: auto !important;
  right: auto !important;
  bottom: auto !important;
  left: auto !important;
  z-index: auto !important;
  width: auto !important;
  min-height: 0 !important;
  margin: 0 !important;
  padding: 0 !important;
  border: 0 !important;
  border-radius: 0 !important;
  background: transparent !important;
  box-shadow: none !important;
  backdrop-filter: none !important;
}
.site-shell .site-shell__nav .site-shell__menu-wrap { position: relative !important; }
.site-shell .site-shell__nav .site-shell__menu {
  display: block;
  border-radius: 0 !important;
  box-sizing: border-box !important;
}
.site-shell .site-shell__nav .site-shell__menu[hidden] { display: none !important; }
.site-shell .site-shell__nav .site-shell__menu a { display: block; }

.archive-boundary {
  max-width: 72rem;
  margin: 1rem 0 2rem;
  padding: 1rem 1.15rem;
  border-left: 3px solid var(--shell-signal);
  background: rgba(157, 230, 210, .08);
  color: var(--shell-muted);
  font: 700 .78rem/1.55 ui-sans-serif, system-ui, sans-serif;
}
.archive-boundary strong { color: var(--shell-paper); }
.archive-boundary a { color: var(--shell-signal) !important; }
