:root {
  color-scheme: dark;
  --bg: #00020a;
  --bg-strong: #000000;
  --panel: #080b08;
  --panel-2: #101510;
  --line: #434943;
  --line-strong: #7b877b;
  --text: #e8f7df;
  --muted: #aebaa8;
  --faint: #788071;
  --green: #00ff66;
  --amber: #ffd51d;
  --cyan: #00d9ff;
  --red: #ff4ca3;
  --shadow: 7px 7px 0 rgba(0, 0, 0, 0.86);
  --mono: "SFMono-Regular", "Cascadia Code", "Liberation Mono", Menlo, Consolas, monospace;
  --sans: var(--mono);
}

:root.light {
  color-scheme: light;
  --bg: #f4f0d2;
  --bg-strong: #fffbe2;
  --panel: #fff7cf;
  --panel-2: #efe6b4;
  --line: #595646;
  --line-strong: #222222;
  --text: #151515;
  --muted: #454236;
  --faint: #6c6650;
  --green: #006b2a;
  --amber: #8a4d00;
  --cyan: #005c7a;
  --red: #9e0059;
  --shadow: 6px 6px 0 rgba(60, 50, 25, 0.25);
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  min-width: 320px;
  background:
    repeating-linear-gradient(0deg, rgba(0, 255, 102, 0.055) 0 1px, transparent 1px 19px),
    repeating-linear-gradient(90deg, rgba(0, 217, 255, 0.045) 0 1px, transparent 1px 23px),
    radial-gradient(circle at 12px 12px, rgba(255, 213, 29, 0.075) 0 1px, transparent 1px 100%),
    var(--bg);
  background-size: auto, auto, 18px 18px;
  color: var(--text);
  font-family: var(--sans);
  font-size: 15px;
  line-height: 1.55;
}

a {
  color: var(--cyan);
  text-decoration: underline;
  text-decoration-thickness: 1px;
  text-underline-offset: 3px;
}

a:hover {
  color: var(--green);
}

button,
input {
  font: inherit;
}

.page-shell {
  display: grid;
  grid-template-columns: 286px minmax(0, 1fr);
  min-height: 100vh;
}

.directory {
  position: sticky;
  top: 0;
  display: flex;
  flex-direction: column;
  gap: 20px;
  height: 100vh;
  padding: 24px;
  border-right: 4px double var(--line-strong);
  background:
    linear-gradient(180deg, rgba(0, 255, 102, 0.06), transparent 140px),
    var(--bg-strong);
  box-shadow: var(--shadow);
}

.directory::before {
  content: "DIR LISTING";
  display: block;
  border: 2px inset var(--line-strong);
  padding: 5px 7px;
  background: var(--panel-2);
  color: var(--amber);
  font-size: 0.72rem;
  letter-spacing: 0;
}

.identity-link {
  display: flex;
  align-items: center;
  gap: 12px;
}

.identity-mark {
  display: grid;
  width: 46px;
  height: 46px;
  place-items: center;
  border: 3px double var(--green);
  border-radius: 0;
  background: #020402;
  color: var(--green);
  font-family: var(--mono);
  font-weight: 800;
  text-shadow: 1px 1px 0 var(--red);
}

.identity-link strong,
.identity-link small {
  display: block;
}

.identity-link strong {
  font-family: var(--mono);
  font-size: 1rem;
}

.identity-link small {
  color: var(--muted);
  font-size: 0.78rem;
}

.nav-list {
  display: grid;
  gap: 8px;
}

.nav-list a,
.side-actions a,
.theme-toggle {
  min-height: 40px;
  border: 2px outset var(--line-strong);
  border-radius: 0;
  background: var(--panel);
  color: var(--text);
  text-decoration: none;
}

.nav-list a,
.side-actions a {
  display: flex;
  align-items: center;
  padding: 0 12px;
}

.nav-list a::before {
  content: "./";
  margin-right: 4px;
  color: var(--faint);
  font-family: var(--mono);
}

.nav-list a:hover,
.side-actions a:hover,
.theme-toggle:hover {
  border-style: inset;
  border-color: var(--amber);
  background: var(--panel-2);
  color: var(--amber);
}

.side-actions {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 8px;
  margin-top: auto;
}

.theme-toggle {
  grid-column: 1 / -1;
  cursor: pointer;
}

main {
  min-width: 0;
}

.hero,
.section {
  width: min(1180px, calc(100% - 48px));
  margin: 0 auto;
}

.hero {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 340px;
  gap: 42px;
  align-items: center;
  min-height: 84vh;
  padding: 64px 0 44px;
}

.eyebrow {
  margin: 0 0 12px;
  color: var(--green);
  font-family: var(--mono);
  font-size: 0.78rem;
  text-transform: uppercase;
}

h1,
h2,
h3,
p {
  margin-top: 0;
}

h1,
h2,
h3 {
  line-height: 1.08;
}

h1 {
  margin-bottom: 18px;
  font-family: var(--mono);
  font-size: 4.25rem;
  font-weight: 850;
  color: var(--text);
  text-shadow: 2px 2px 0 var(--red), 4px 4px 0 #000;
}

h2 {
  margin-bottom: 14px;
  font-size: 2.2rem;
}

h3 {
  margin-bottom: 10px;
  font-size: 1rem;
}

.lead {
  max-width: 760px;
  color: var(--muted);
  font-size: 1rem;
}

.hero-actions,
.contact-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 26px;
}

.button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 44px;
  padding: 0 16px;
  border: 2px outset var(--line-strong);
  border-radius: 0;
  background: var(--panel);
  color: var(--text);
  font-family: var(--mono);
  font-size: 0.88rem;
  text-decoration: none;
}

.button:hover,
.button.primary {
  border-color: var(--amber);
  background: color-mix(in srgb, var(--green) 14%, var(--panel));
  color: var(--amber);
}

.button:hover {
  border-style: inset;
}

.blink {
  animation: blink 1s steps(2, jump-none) infinite;
}

@keyframes blink {
  50% {
    opacity: 0;
  }
}

.quick-metrics {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
  margin: 34px 0 0;
}

.quick-metrics div {
  min-height: 96px;
  padding: 14px;
  border: 2px ridge var(--line-strong);
  border-radius: 0;
  background: var(--panel);
  box-shadow: 4px 4px 0 #000;
}

.quick-metrics dt {
  color: var(--amber);
  font-family: var(--mono);
  font-size: 1.85rem;
  font-weight: 800;
}

.quick-metrics dd {
  margin: 6px 0 0;
  color: var(--muted);
  font-size: 0.86rem;
}

.hero-visual {
  margin: 0;
  border: 3px ridge var(--line-strong);
  border-radius: 0;
  background: var(--panel);
  overflow: hidden;
  box-shadow: var(--shadow);
}

.hero-visual img {
  display: block;
  width: 100%;
  aspect-ratio: 1;
  object-fit: cover;
  border-bottom: 1px solid var(--line);
  background: var(--panel-2);
}

.hero-visual figcaption {
  display: grid;
  gap: 4px;
  padding: 14px;
}

.hero-visual span,
.hero-visual small,
.repo-meta,
.resource-link span,
.resource-link small {
  color: var(--muted);
  font-family: var(--mono);
  font-size: 0.75rem;
}

.hero-visual strong {
  font-family: var(--mono);
}

.section {
  padding: 76px 0;
  border-top: 2px dashed var(--line-strong);
}

.section-heading {
  max-width: 760px;
  margin-bottom: 28px;
}

.section-heading p:not(.eyebrow),
.contact-section p {
  color: var(--muted);
}

.service-list,
.repo-grid,
.resource-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 12px;
}

.service-item,
.repo-card,
.audit-panel,
.resource-link {
  border: 2px outset var(--line-strong);
  border-radius: 0;
  background: color-mix(in srgb, var(--panel) 94%, transparent);
  box-shadow: 4px 4px 0 rgba(0, 0, 0, 0.78);
}

.service-item {
  min-height: 188px;
  padding: 18px;
}

.service-item span {
  color: var(--amber);
  font-family: var(--mono);
  font-size: 0.8rem;
}

.service-item h3 {
  margin-top: 26px;
}

.service-item h3::before,
.audit-panel h3::before,
.repo-card h3::before {
  content: ">> ";
  color: var(--green);
}

.service-item p,
.repo-card p,
.audit-panel p,
.resource-link small {
  color: var(--muted);
}

.split-section {
  display: grid;
  grid-template-columns: 340px minmax(0, 1fr);
  gap: 42px;
}

.split-section .section-heading {
  margin-bottom: 0;
}

.audit-grid {
  display: grid;
  gap: 12px;
}

.audit-panel {
  padding: 18px;
}

.rank-list,
.link-list {
  display: grid;
  gap: 8px;
  margin: 0;
  padding: 0;
  list-style: none;
}

.rank-list li {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  min-height: 34px;
  border-bottom: 1px dotted var(--line-strong);
}

.rank-list li:last-child {
  border-bottom: 0;
}

.rank-list span {
  color: var(--amber);
  font-family: var(--mono);
  font-size: 0.82rem;
  white-space: nowrap;
}

.link-list a {
  color: var(--cyan);
}

.tag-cloud {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.tag-cloud span {
  padding: 5px 8px;
  border: 1px solid var(--line-strong);
  border-radius: 0;
  color: var(--muted);
  font-family: var(--mono);
  font-size: 0.75rem;
}

.repo-toolbar {
  display: grid;
  grid-template-columns: minmax(220px, 1fr) auto;
  gap: 10px;
  align-items: end;
  margin-bottom: 16px;
}

.repo-toolbar label {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip: rect(0 0 0 0);
}

.repo-toolbar input {
  min-height: 44px;
  width: 100%;
  border: 2px inset var(--line-strong);
  border-radius: 0;
  padding: 0 14px;
  background: #000;
  color: var(--text);
  outline: none;
}

.repo-toolbar input:focus {
  border-color: var(--green);
}

.filter-tabs {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.filter-tabs button {
  min-height: 44px;
  border: 2px outset var(--line-strong);
  border-radius: 0;
  padding: 0 12px;
  background: var(--panel);
  color: var(--text);
  cursor: pointer;
}

.filter-tabs button.active,
.filter-tabs button:hover {
  border-style: inset;
  border-color: var(--amber);
  color: var(--amber);
}

.repo-card {
  display: flex;
  flex-direction: column;
  min-height: 228px;
  padding: 18px;
}

.repo-card[hidden] {
  display: none;
}

.repo-meta {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 22px;
}

.repo-meta strong {
  color: var(--amber);
}

.repo-card h3 {
  font-family: var(--mono);
  overflow-wrap: anywhere;
}

.repo-card h3 a {
  color: var(--text);
}

.repo-card h3 a:hover {
  color: var(--green);
}

.resource-link {
  display: grid;
  gap: 8px;
  min-height: 150px;
  padding: 18px;
}

.resource-link span {
  color: var(--green);
}

.resource-link strong {
  font-family: var(--mono);
}

.contact-section {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 34px;
  align-items: center;
  padding-bottom: 96px;
}

@media (max-width: 1080px) {
  .page-shell {
    grid-template-columns: 1fr;
  }

  .directory {
    position: static;
    height: auto;
    display: grid;
    grid-template-columns: 1fr;
    padding: 16px;
  }

  .nav-list,
  .side-actions {
    grid-template-columns: repeat(5, minmax(0, 1fr));
  }

  .theme-toggle {
    grid-column: auto;
  }

  .hero {
    grid-template-columns: 1fr;
    min-height: 0;
  }

  .hero-visual {
    max-width: 360px;
  }

  .split-section,
  .contact-section {
    grid-template-columns: 1fr;
  }

  .repo-toolbar {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 760px) {
  .hero,
  .section {
    width: min(100% - 28px, 1180px);
  }

  .service-list,
  .repo-grid,
  .resource-grid,
  .quick-metrics {
    grid-template-columns: 1fr;
  }

  .directory {
    gap: 12px;
    padding: 12px 14px;
  }

  .nav-list {
    display: flex;
    gap: 8px;
    overflow-x: auto;
    padding-bottom: 2px;
  }

  .nav-list a {
    flex: 0 0 auto;
    min-height: 36px;
    min-width: 102px;
  }

  .side-actions {
    display: none;
  }

  .nav-list a,
  .side-actions a,
  .theme-toggle {
    justify-content: center;
  }

  h1 {
    font-size: 2.35rem;
  }

  h2 {
    font-size: 1.75rem;
  }

  .hero {
    position: relative;
    display: block;
    min-height: 0;
    padding: 20px 74px 18px 0;
  }

  .hero .eyebrow {
    font-size: 0.62rem;
  }

  .lead {
    font-size: 0.9rem;
    line-height: 1.42;
  }

  .hero-actions {
    gap: 8px;
    margin-top: 16px;
  }

  .button {
    min-height: 34px;
    padding: 0 8px;
    font-size: 0.72rem;
  }

  .quick-metrics {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 6px;
    margin-top: 20px;
  }

  .quick-metrics div {
    min-height: 76px;
    padding: 9px;
  }

  .quick-metrics dt {
    font-size: 1.35rem;
  }

  .quick-metrics dd {
    font-size: 0.7rem;
  }

  .hero-visual {
    position: absolute;
    top: 24px;
    right: 0;
    width: 60px;
  }

  .hero-visual img {
    border-bottom: 0;
  }

  .hero-visual figcaption {
    display: none;
  }

  .rank-list li {
    align-items: flex-start;
    flex-direction: column;
    gap: 2px;
    padding-bottom: 8px;
  }

  .filter-tabs button {
    flex: 1 1 130px;
  }
}

@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }
}
