:root {
  --bg: #f6f7f9;
  --surface: #ffffff;
  --surface-muted: #eef2f4;
  --ink: #17212f;
  --muted: #5f6b7a;
  --line: #d9e0e7;
  --blue: #1d4ed8;
  --blue-soft: #dbeafe;
  --green: #067647;
  --green-soft: #dcfce7;
  --amber: #b45309;
  --amber-soft: #fef3c7;
  --shadow: 0 14px 35px rgba(23, 33, 47, 0.08);
  color-scheme: light;
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font-size: 16px;
  line-height: 1.55;
}

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

a:hover {
  text-decoration: underline;
}

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

.topbar {
  position: sticky;
  top: 0;
  z-index: 10;
  border-bottom: 1px solid var(--line);
  background: rgba(255, 255, 255, 0.96);
  backdrop-filter: blur(12px);
}

.topbar-inner,
.page-shell,
.article-shell {
  width: min(1180px, calc(100% - 32px));
  margin: 0 auto;
}

.topbar-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  min-height: 72px;
}

.brand {
  display: flex;
  align-items: center;
  gap: 12px;
  color: var(--ink);
  font-weight: 750;
  letter-spacing: 0;
}

.brand-mark {
  display: grid;
  place-items: center;
  width: 38px;
  height: 38px;
  border-radius: 8px;
  background: var(--green);
  color: white;
  font-weight: 800;
}

.nav-links {
  display: flex;
  align-items: center;
  gap: 18px;
  color: var(--muted);
  font-size: 14px;
}

.page-shell {
  padding: 36px 0 56px;
}

.workspace-header {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(280px, 390px);
  gap: 28px;
  align-items: end;
  margin-bottom: 30px;
}

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

h1,
h2,
h3 {
  margin: 0;
  line-height: 1.16;
  letter-spacing: 0;
}

h1 {
  max-width: 760px;
  font-size: clamp(32px, 5vw, 54px);
}

h2 {
  font-size: 26px;
}

h3 {
  font-size: 19px;
}

.intro {
  max-width: 760px;
  margin: 16px 0 0;
  color: var(--muted);
  font-size: 18px;
}

.search-panel {
  padding: 18px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--surface);
  box-shadow: var(--shadow);
}

.search-panel label {
  display: block;
  margin-bottom: 8px;
  color: var(--muted);
  font-size: 13px;
  font-weight: 700;
}

.search-input {
  width: 100%;
  min-height: 46px;
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 0 14px;
  color: var(--ink);
  font: inherit;
}

.search-input:focus {
  border-color: var(--blue);
  outline: 3px solid var(--blue-soft);
}

.section-heading {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  margin: 34px 0 14px;
}

.muted {
  color: var(--muted);
}

.article-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 18px;
}

.article-card {
  display: flex;
  flex-direction: column;
  min-height: 292px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--surface);
  overflow: hidden;
  box-shadow: var(--shadow);
}

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

.article-card-body {
  display: flex;
  flex: 1;
  flex-direction: column;
  gap: 14px;
  padding: 20px;
}

.article-card h3 {
  font-size: 21px;
}

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

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

.tag {
  display: inline-flex;
  align-items: center;
  min-height: 28px;
  padding: 4px 9px;
  border-radius: 999px;
  background: var(--surface-muted);
  color: var(--muted);
  font-size: 13px;
  font-weight: 700;
}

.tag.green {
  background: var(--green-soft);
  color: var(--green);
}

.tag.amber {
  background: var(--amber-soft);
  color: var(--amber);
}

.article-card-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 15px 20px;
  border-top: 1px solid var(--line);
  background: #fbfcfd;
}

.button,
button.button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 42px;
  border: 1px solid var(--blue);
  border-radius: 8px;
  padding: 0 14px;
  background: var(--blue);
  color: white;
  font: inherit;
  font-weight: 750;
  cursor: pointer;
}

.button.secondary {
  border-color: var(--line);
  background: var(--surface);
  color: var(--ink);
}

.button:hover {
  text-decoration: none;
  filter: brightness(0.96);
}

.empty-state {
  padding: 22px;
  border: 1px dashed var(--line);
  border-radius: 8px;
  background: var(--surface);
  color: var(--muted);
}

.article-shell {
  display: grid;
  grid-template-columns: 250px minmax(0, 1fr);
  gap: 32px;
  padding: 34px 0 58px;
}

.article-nav {
  position: sticky;
  top: 96px;
  align-self: start;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--surface);
  overflow: hidden;
}

.article-nav strong {
  display: block;
  padding: 14px 16px;
  border-bottom: 1px solid var(--line);
  font-size: 14px;
}

.article-nav a {
  display: block;
  padding: 10px 16px;
  color: var(--muted);
  font-size: 14px;
}

.article-main {
  min-width: 0;
}

.article-hero {
  padding: 30px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--surface);
  box-shadow: var(--shadow);
}

.article-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin: 18px 0 0;
}

.content-section {
  margin-top: 22px;
  padding: 28px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--surface);
}

.content-section h2 {
  margin-bottom: 14px;
}

.content-section p,
.content-section ul,
.content-section ol {
  margin-top: 0;
}

.content-section li + li {
  margin-top: 7px;
}

.step {
  padding: 22px 0;
  border-top: 1px solid var(--line);
}

.step:first-of-type {
  padding-top: 0;
  border-top: 0;
}

.step h3 {
  margin-bottom: 8px;
}

.screenshot {
  margin: 16px 0 0;
  border: 1px solid var(--line);
  border-radius: 8px;
  overflow: hidden;
  background: var(--surface-muted);
}

.screenshot img {
  width: 100%;
  height: auto;
}

.screenshot figcaption {
  padding: 11px 14px;
  border-top: 1px solid var(--line);
  color: var(--muted);
  font-size: 14px;
}

.note {
  margin: 16px 0 0;
  padding: 14px 16px;
  border-left: 4px solid var(--green);
  background: var(--green-soft);
  color: #14532d;
}

.warning {
  border-left-color: var(--amber);
  background: var(--amber-soft);
  color: #78350f;
}

.qa {
  display: grid;
  gap: 14px;
}

.qa-item {
  padding-top: 14px;
  border-top: 1px solid var(--line);
}

.qa-item:first-child {
  padding-top: 0;
  border-top: 0;
}

.qa-item strong {
  display: block;
  margin-bottom: 4px;
}

.site-footer {
  border-top: 1px solid var(--line);
  background: var(--surface);
}

.site-footer-inner {
  width: min(1180px, calc(100% - 32px));
  margin: 0 auto;
  padding: 24px 0;
  color: var(--muted);
  font-size: 14px;
}

@media (max-width: 920px) {
  .workspace-header,
  .article-shell {
    grid-template-columns: 1fr;
  }

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

  .article-nav {
    position: static;
  }
}

@media (max-width: 640px) {
  .topbar-inner {
    align-items: flex-start;
    flex-direction: column;
    padding: 14px 0;
  }

  .nav-links {
    flex-wrap: wrap;
  }

  .article-grid {
    grid-template-columns: 1fr;
  }

  .article-hero,
  .content-section {
    padding: 20px;
  }

  .article-card-footer {
    align-items: flex-start;
    flex-direction: column;
  }

  .button,
  button.button {
    width: 100%;
  }
}

@media print {
  body {
    background: white;
    color: #111827;
  }

  .topbar,
  .article-nav,
  .site-footer {
    display: none !important;
  }

  .article-shell {
    display: block;
    width: 100%;
    padding: 0;
  }

  .article-hero,
  .content-section {
    border: 0;
    box-shadow: none;
    padding: 0 0 18px;
    break-inside: avoid;
  }

  .content-section {
    border-top: 1px solid #d1d5db;
    padding-top: 18px;
  }

  .screenshot {
    break-inside: avoid;
  }

  a {
    color: #111827;
  }
}
