/* PolycryptZero — intentionally small, flat, old-school documentation UI */

:root {
  --bg: #eeeeee;
  --panel: #ffffff;
  --ink: #171717;
  --muted: #686868;
  --line: #b9b9b9;
  --accent: #2457a6;
  --accent-dark: #173b72;
  --warn: #f6f3e7;
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font-family: Arial, Helvetica, sans-serif;
  font-size: 13px;
  line-height: 1.5;
}

a { color: var(--accent); text-decoration: underline; }
a:hover { color: var(--accent-dark); }

.page {
  width: min(900px, calc(100% - 24px));
  margin: 12px auto 24px;
  background: var(--panel);
  border: 1px solid #8f8f8f;
  box-shadow: 2px 2px 0 #c6c6c6;
}

.topbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 11px 13px 9px;
  border-bottom: 1px solid #8f8f8f;
  background: #fafafa;
}

.brand {
  font-family: "Courier New", Courier, monospace;
  font-size: 20px;
  font-weight: 700;
  letter-spacing: -0.5px;
}

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

.subbrand {
  margin-top: 1px;
  color: var(--muted);
  font-family: "Courier New", Courier, monospace;
  font-size: 12px;
}

.version {
  color: var(--accent);
  font-family: "Courier New", Courier, monospace;
  font-size: 12px;
  font-weight: 700;
}

.nav {
  display: flex;
  flex-wrap: wrap;
  gap: 0;
  padding: 5px 8px;
  border-bottom: 1px solid #b3b3b3;
  background: #dedede;
}

.nav a {
  padding: 1px 6px;
  color: #222;
  text-decoration: none;
  border-right: 1px solid #aaa;
  font-family: "Courier New", Courier, monospace;
  font-size: 11px;
}

.nav a:last-child { border-right: 0; }
.nav a:hover { color: var(--accent); text-decoration: underline; }

.intro {
  padding: 14px 15px;
  border-bottom: 1px solid var(--line);
}

.intro p { margin: 0 0 10px; max-width: 760px; }

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

.button {
  display: inline-block;
  padding: 4px 8px;
  border: 1px solid var(--accent-dark);
  background: var(--accent);
  color: #fff;
  font-family: "Courier New", Courier, monospace;
  font-size: 11px;
  text-decoration: none;
}

.button:hover {
  background: var(--accent-dark);
  color: #fff;
}

.button.secondary {
  background: #fff;
  color: var(--accent);
}

.section {
  padding: 12px 15px 13px;
  border-bottom: 1px solid var(--line);
}

h2 {
  margin: 0 0 7px;
  font-family: "Courier New", Courier, monospace;
  font-size: 14px;
  line-height: 1.2;
  text-transform: lowercase;
}

h3 {
  margin: 11px 0 4px;
  font-family: "Courier New", Courier, monospace;
  font-size: 12px;
  text-transform: lowercase;
}

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

.grid {
  display: grid;
  gap: 8px;
}

.grid.two { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.grid.three { grid-template-columns: repeat(3, minmax(0, 1fr)); }

.box {
  padding: 8px 9px;
  border: 1px solid var(--line);
  background: #f8f8f8;
}

.box h3 { margin-top: 0; }
.box p { margin-bottom: 0; }

.stats .box {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
}

.stats strong,
.stats span {
  font-family: "Courier New", Courier, monospace;
  font-size: 11px;
}

table {
  width: 100%;
  border-collapse: collapse;
  margin: 8px 0;
  font-size: 12px;
}

th, td {
  padding: 5px 6px;
  border: 1px solid var(--line);
  text-align: left;
  vertical-align: top;
}

th {
  background: #e5e5e5;
  font-family: "Courier New", Courier, monospace;
  font-size: 11px;
}

code, pre, .codebox { font-family: "Courier New", Courier, monospace; }

code {
  padding: 0 2px;
  background: #ededed;
}

pre {
  overflow-x: auto;
  margin: 7px 0;
  padding: 8px;
  border: 1px solid var(--line);
  background: #f3f3f3;
  font-size: 12px;
}

pre code { background: transparent; padding: 0; }

.codebox {
  margin: 8px 0;
  padding: 8px 10px;
  border: 1px solid #999;
  background: #111;
  color: #e8e8e8;
  white-space: pre;
  overflow-x: auto;
  font-size: 11px;
}

ul, ol {
  margin: 7px 0 4px 18px;
  padding: 0;
}

li { margin: 2px 0; }

.gallery { margin-top: 9px; }

.gallery-main { display: block; }

.gallery-two {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 9px;
  margin-top: 9px;
}

.shot {
  margin: 0;
  border: 1px solid var(--line);
  background: #f4f4f4;
}

.shot a {
  display: block;
  line-height: 0;
}

.shot img {
  display: block;
  width: 100%;
  height: auto;
  max-height: 460px;
  object-fit: contain;
  background: #ddd;
}

.shot.large img { max-height: 500px; }

figcaption {
  padding: 4px 6px;
  border-top: 1px solid var(--line);
  color: var(--muted);
  font-family: "Courier New", Courier, monospace;
  font-size: 10px;
  text-transform: lowercase;
}

.requirements {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  align-items: center;
}

.requirements b {
  font-family: "Courier New", Courier, monospace;
  margin-right: 4px;
}

.requirements code {
  border: 1px solid #c0c0c0;
  padding: 2px 4px;
}

.note, .warning { background: var(--warn); }

.roadmap { columns: 2; }

footer {
  display: flex;
  justify-content: space-between;
  gap: 10px;
  padding: 8px 13px;
  color: var(--muted);
  background: #ededed;
  font-family: "Courier New", Courier, monospace;
  font-size: 10px;
}

@media (max-width: 650px) {
  body { font-size: 12px; }
  .grid.two, .grid.three, .gallery-two { grid-template-columns: 1fr; }
  .roadmap { columns: 1; }
  .page { width: calc(100% - 10px); margin: 5px auto 12px; }
  footer { display: block; }
  footer span { display: block; margin: 2px 0; }
}
