/* Vulnyard - vulnyard.eu */

:root {
  --navy: #1b2a4a;
  --sky: #8fb3ff;
  --amber: #f2a93b;
  --mist: #e8eefb;

  --bg: #ffffff;
  --bg-alt: #f5f7fc;
  --surface: #ffffff;
  --text: #1b2a4a;
  --muted: #55627d;
  --border: #dde3f0;
  --accent: #2f5bd3;
  --accent-text: #ffffff;
  --code-bg: #121c33;
  --code-text: #e8eefb;
  --hero-bg: var(--navy);
  --hero-text: #ffffff;
  --hero-muted: #c3cfe9;

  --radius: 14px;
  --max: 1120px;
  --font: system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  --mono: ui-monospace, SFMono-Regular, Menlo, Consolas, "Liberation Mono", monospace;
}

@media (prefers-color-scheme: dark) {
  :root {
    --bg: #0f1729;
    --bg-alt: #131e36;
    --surface: #17233f;
    --text: #e8eefb;
    --muted: #a6b3cf;
    --border: #26365c;
    --accent: #8fb3ff;
    --accent-text: #0f1729;
    --code-bg: #0a1122;
    --hero-bg: #0a1122;
  }
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
  -webkit-text-size-adjust: 100%;
}

body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font-family: var(--font);
  font-size: 17px;
  line-height: 1.6;
}

img {
  max-width: 100%;
  height: auto;
}

a {
  color: var(--accent);
}

a:focus-visible,
button:focus-visible {
  outline: 3px solid var(--amber);
  outline-offset: 2px;
}

code {
  font-family: var(--mono);
  font-size: 0.9em;
}

.wrap {
  width: 100%;
  max-width: var(--max);
  margin: 0 auto;
  padding: 0 16px;
}

@media (min-width: 720px) {
  .wrap {
    padding: 0 32px;
  }
}

.skip {
  position: absolute;
  left: -9999px;
}

.skip:focus {
  left: 16px;
  top: 16px;
  z-index: 10;
  background: var(--surface);
  padding: 8px 12px;
  border-radius: 8px;
}

/* Header ------------------------------------------------------------------ */

.site-header {
  background: var(--hero-bg);
  color: var(--hero-text);
}

.site-header .wrap {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  min-height: 72px;
}

.brand {
  display: inline-flex;
  line-height: 0;
}

.brand img {
  height: 36px;
  width: auto;
}

.nav {
  display: flex;
  align-items: center;
  gap: 20px;
  font-size: 15px;
}

.nav a {
  color: var(--hero-muted);
  text-decoration: none;
}

.nav a:hover {
  color: var(--hero-text);
}

.nav .lang {
  border: 1px solid rgba(255, 255, 255, 0.25);
  border-radius: 999px;
  padding: 2px 12px;
}

@media (max-width: 719px) {
  .nav .optional {
    display: none;
  }
}

/* Hero -------------------------------------------------------------------- */

.hero {
  background: var(--hero-bg);
  color: var(--hero-text);
  padding: 48px 0 72px;
}

.hero h1 {
  font-size: clamp(32px, 6vw, 54px);
  line-height: 1.1;
  letter-spacing: -0.02em;
  margin: 0 0 20px;
  max-width: 18ch;
}

.hero h1 em {
  font-style: normal;
  color: var(--amber);
}

.hero .lead {
  font-size: clamp(18px, 2.4vw, 21px);
  color: var(--hero-muted);
  max-width: 60ch;
  margin: 0 0 32px;
}

.actions {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
}

.btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 12px 22px;
  border-radius: 10px;
  font-weight: 600;
  text-decoration: none;
  border: 1px solid transparent;
}

.btn-primary {
  background: var(--amber);
  color: var(--navy);
}

.btn-primary:hover {
  background: #f6bc63;
}

.btn-ghost {
  color: var(--hero-text);
  border-color: rgba(255, 255, 255, 0.35);
}

.btn-ghost:hover {
  border-color: var(--hero-text);
}

.btn svg {
  width: 18px;
  height: 18px;
  fill: currentColor;
}

.release {
  margin-top: 20px;
  font-size: 14px;
  color: var(--hero-muted);
  min-height: 1.6em;
}

.release a {
  color: var(--sky);
}

/* Flow -------------------------------------------------------------------- */

.flow {
  list-style: none;
  margin: 48px 0 0;
  padding: 0;
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: 12px;
}

.flow li {
  position: relative;
  background: rgba(255, 255, 255, 0.06);
  border: 1px solid rgba(143, 179, 255, 0.28);
  border-radius: var(--radius);
  padding: 16px;
}

.flow li:not(:last-child)::after {
  content: "";
  position: absolute;
  top: 50%;
  right: -11px;
  width: 10px;
  height: 2px;
  background: var(--sky);
}

.flow strong {
  display: block;
  font-size: 16px;
}

.flow span {
  font-size: 14px;
  color: var(--hero-muted);
}

.flow .hub {
  border-color: var(--amber);
  background: rgba(242, 169, 59, 0.12);
}

@media (max-width: 899px) {
  .flow {
    grid-template-columns: 1fr;
    gap: 14px;
  }

  .flow li:not(:last-child)::after {
    top: auto;
    bottom: -13px;
    right: auto;
    left: 28px;
    width: 2px;
    height: 12px;
  }
}

/* Sections ---------------------------------------------------------------- */

section {
  padding: 72px 0;
}

section.alt {
  background: var(--bg-alt);
}

.eyebrow {
  margin: 0 0 8px;
  font-size: 13px;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--accent);
}

h2 {
  font-size: clamp(26px, 4vw, 36px);
  line-height: 1.2;
  letter-spacing: -0.01em;
  margin: 0 0 16px;
}

.intro {
  color: var(--muted);
  max-width: 64ch;
  margin: 0 0 40px;
}

.grid {
  display: grid;
  gap: 20px;
  grid-template-columns: repeat(auto-fill, minmax(230px, 1fr));
}

.card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 24px;
}

.card h3 {
  font-size: 18px;
  margin: 0 0 8px;
}

.card p {
  margin: 0;
  color: var(--muted);
  font-size: 16px;
}

.icon {
  width: 40px;
  height: 40px;
  border-radius: 10px;
  display: grid;
  place-items: center;
  background: var(--navy);
  margin-bottom: 16px;
}

.icon svg {
  width: 22px;
  height: 22px;
  fill: none;
  stroke: var(--sky);
  stroke-width: 2;
  stroke-linecap: round;
  stroke-linejoin: round;
}

/* Pillars */

.pillars {
  display: grid;
  gap: 32px;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
}

.pillars h3 {
  font-size: 20px;
  margin: 0 0 8px;
}

.pillars p {
  margin: 0;
  color: var(--muted);
}

.pillars .num {
  display: inline-block;
  font-weight: 800;
  color: var(--amber);
  font-size: 15px;
  margin-bottom: 6px;
}

/* Steps */

.steps {
  counter-reset: step;
  list-style: none;
  padding: 0;
  margin: 0;
  display: grid;
  gap: 16px;
}

.steps li {
  counter-increment: step;
  display: grid;
  grid-template-columns: 44px 1fr;
  gap: 16px;
  align-items: start;
}

.steps li::before {
  content: counter(step);
  width: 44px;
  height: 44px;
  border-radius: 50%;
  display: grid;
  place-items: center;
  font-weight: 700;
  background: var(--navy);
  color: var(--amber);
}

.steps h3 {
  margin: 8px 0 4px;
  font-size: 18px;
}

.steps p {
  margin: 0;
  color: var(--muted);
}

/* Quick start */

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

@media (min-width: 960px) {
  .split {
    grid-template-columns: minmax(0, 5fr) minmax(0, 7fr);
    align-items: start;
  }
}

.checklist {
  list-style: none;
  padding: 0;
  margin: 0 0 24px;
}

.checklist li {
  position: relative;
  padding-left: 28px;
  margin-bottom: 10px;
}

.checklist li::before {
  content: "";
  position: absolute;
  left: 4px;
  top: 0.45em;
  width: 10px;
  height: 6px;
  border-left: 2px solid var(--amber);
  border-bottom: 2px solid var(--amber);
  transform: rotate(-45deg);
}

.code {
  position: relative;
  background: var(--code-bg);
  color: var(--code-text);
  border-radius: var(--radius);
  border: 1px solid var(--border);
  overflow: hidden;
}

.code-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 8px 12px 8px 16px;
  font-size: 13px;
  color: #a6b3cf;
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
}

.copy {
  font: inherit;
  color: var(--code-text);
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid rgba(255, 255, 255, 0.15);
  border-radius: 6px;
  padding: 4px 10px;
  cursor: pointer;
}

.copy:hover {
  background: rgba(255, 255, 255, 0.16);
}

.code pre {
  margin: 0;
  padding: 16px;
  overflow-x: auto;
  font-family: var(--mono);
  font-size: 14px;
  line-height: 1.7;
}

.code .c {
  color: #7f8fb3;
}

.note {
  font-size: 15px;
  color: var(--muted);
  margin: 16px 0 0;
}

/* Open source */

.oss {
  display: grid;
  gap: 32px;
  grid-template-columns: 1fr;
  align-items: center;
}

@media (min-width: 900px) {
  .oss {
    grid-template-columns: minmax(0, 3fr) minmax(0, 2fr);
  }
}

.links {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  gap: 10px;
}

.links a {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 12px;
  padding: 14px 18px;
  border: 1px solid var(--border);
  border-radius: 10px;
  background: var(--surface);
  color: var(--text);
  text-decoration: none;
  font-weight: 600;
}

.links a:hover {
  border-color: var(--accent);
}

.links a span {
  color: var(--muted);
  font-weight: 400;
  font-size: 14px;
}

/* Footer ------------------------------------------------------------------ */

.site-footer {
  background: var(--hero-bg);
  color: var(--hero-muted);
  padding: 32px 0;
  font-size: 14px;
}

.site-footer .wrap {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 12px 24px;
}

.site-footer a {
  color: var(--hero-text);
}

.site-footer p {
  margin: 0;
}

/* 404 */

.notfound {
  min-height: 60vh;
  display: grid;
  place-items: center;
  text-align: center;
  padding: 64px 0;
}

.notfound h1 {
  font-size: 64px;
  margin: 0;
  color: var(--amber);
}

.sprite {
  position: absolute;
  width: 0;
  height: 0;
  overflow: hidden;
}
