:root {
  --bg: #151619;
  --panel: #1d1f24;
  --panel-2: #24272d;
  --border: #323640;
  --text: #eceef2;
  --muted: #a8adb8;
  --accent: #5ba7ff;
  --danger: #df5c5c;
  --ok: #6fcf92;
  --shadow: 0 12px 36px rgba(0, 0, 0, 0.35);
}

* {
  box-sizing: border-box;
}

html,
body {
  margin: 0;
  padding: 0;
  background: radial-gradient(circle at top right, #202633 0%, var(--bg) 42%);
  color: var(--text);
  font-family: "proxima-nova", -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  line-height: 1.45;
}

a {
  color: var(--accent);
  text-decoration: none;
}

a:hover {
  text-decoration: underline;
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 60;
  border-bottom: 1px solid var(--border);
  backdrop-filter: blur(10px);
  background: rgba(21, 22, 25, 0.88);
}

.header-inner {
  width: min(1120px, 94vw);
  margin: 0 auto;
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 12px 0;
}

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

.nav a {
  color: var(--muted);
  font-size: 14px;
  padding: 6px 9px;
  border-radius: 8px;
}

.nav a.active,
.nav a:hover {
  color: var(--text);
  background: #2a2d34;
  text-decoration: none;
}

.search-wrap {
  margin-left: auto;
  position: relative;
  min-width: 270px;
}

.search-wrap input {
  width: 100%;
  padding: 9px 10px;
  border: 1px solid var(--border);
  border-radius: 10px;
  background: #20232b;
  color: var(--text);
  font-size: 14px;
}

.search-wrap input::placeholder {
  color: #878d99;
}

.search-results {
  position: absolute;
  top: calc(100% + 8px);
  left: 0;
  right: 0;
  max-height: 340px;
  overflow: auto;
  border: 1px solid var(--border);
  border-radius: 12px;
  background: #1b1e24;
  box-shadow: var(--shadow);
  display: none;
}

.search-results.open {
  display: block;
}

.search-item {
  display: block;
  border-bottom: 1px solid #2b2f38;
  padding: 10px 12px;
}

.search-item:last-child {
  border-bottom: 0;
}

.search-item-title {
  color: var(--text);
  font-size: 14px;
  font-weight: 600;
}

.search-item-snippet {
  margin-top: 4px;
  color: var(--muted);
  font-size: 12px;
}

.page {
  width: min(1120px, 94vw);
  margin: 28px auto 56px;
}

.hero {
  border: 1px solid var(--border);
  border-radius: 16px;
  background: linear-gradient(140deg, #212630 0%, #1a1d23 55%);
  padding: 28px;
  box-shadow: var(--shadow);
}

.hero h1 {
  margin: 0 0 8px;
  font-size: clamp(26px, 4vw, 36px);
  font-family: "neue-haas-unica", "proxima-nova", -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  font-weight: 400;
}

.hero p {
  margin: 0;
  color: var(--muted);
  max-width: 920px;
}

.quick-links {
  margin-top: 20px;
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 12px;
}

.quick-link {
  border: 1px solid var(--border);
  border-radius: 12px;
  background: var(--panel);
  padding: 14px;
}

.quick-link h3 {
  margin: 0 0 6px;
  font-size: 16px;
  font-family: "neue-haas-unica", "proxima-nova", -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  font-weight: 400;
}

.quick-link p {
  margin: 0;
  color: var(--muted);
  font-size: 14px;
}

.section {
  margin-top: 24px;
  border: 1px solid var(--border);
  border-radius: 14px;
  background: var(--panel);
  padding: 20px;
}

.section h2 {
  margin: 0 0 12px;
  font-size: 22px;
  font-family: "neue-haas-unica", "proxima-nova", -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  font-weight: 400;
}

.section h3 {
  margin: 18px 0 8px;
  font-size: 17px;
  font-family: "neue-haas-unica", "proxima-nova", -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  font-weight: 400;
}

.section p,
.section li {
  color: #d5d9e2;
}

.section ul,
.section ol {
  margin: 10px 0;
  padding-left: 20px;
}

.callout {
  margin: 12px 0;
  padding: 10px 12px;
  border-left: 3px solid var(--accent);
  border-radius: 8px;
  background: #20242d;
  color: #d4dae6;
}

.callout.warn {
  border-left-color: #ffb347;
}

.callout.danger {
  border-left-color: var(--danger);
}

.callout.ok {
  border-left-color: var(--ok);
}

.table-wrap {
  overflow: auto;
  border: 1px solid var(--border);
  border-radius: 12px;
}

table {
  width: 100%;
  border-collapse: collapse;
}

th,
td {
  border-bottom: 1px solid #2b2f37;
  padding: 10px;
  text-align: left;
  font-size: 14px;
}

th {
  color: #cfd5df;
  background: #232730;
}

td {
  color: #d7dce7;
}

tbody tr:last-child td {
  border-bottom: 0;
}

details {
  margin: 8px 0;
  border: 1px solid var(--border);
  border-radius: 10px;
  background: #20232a;
  padding: 10px 12px;
}

summary {
  cursor: pointer;
  font-weight: 600;
}

kbd {
  font-family: ui-monospace, SFMono-Regular, Menlo, monospace;
  border: 1px solid #5e6777;
  border-bottom-width: 2px;
  border-radius: 5px;
  padding: 1px 5px;
  background: #252b36;
  color: #d6dce7;
  font-size: 12px;
}

.footer {
  margin-top: 28px;
  color: #8d93a0;
  font-size: 13px;
  text-align: center;
}

@media (max-width: 860px) {
  .header-inner {
    flex-wrap: wrap;
    align-items: stretch;
  }

  .search-wrap {
    margin-left: 0;
    width: 100%;
    min-width: 0;
  }

  .nav {
    order: 3;
    width: 100%;
  }
}
