/* Silver Hamster Plugins shop. Follows silverhamster.com's DESIGN.md: Epilogue, one accent in two
   lightnesses, neutrals tinted to the brand hue (15°), uneven section rhythm, light mode only. */

:root {
  color-scheme: light;
  --primary: #e93256;
  /* Same hue a step down: 4.9:1 on paper, for text, links and button fills. */
  --primary-deep: oklch(0.56 0.19 15);
  --primary-deeper: oklch(0.5 0.18 15);
  --primary-soft: oklch(0.96 0.02 15);

  --paper: oklch(0.984 0.004 15);
  --surface: oklch(0.995 0.002 15);
  --ink: oklch(0.16 0.01 15);
  --gray-50: oklch(0.975 0.004 15);
  --gray-100: oklch(0.955 0.006 15);
  --gray-200: oklch(0.92 0.008 15);
  --gray-300: oklch(0.87 0.01 15);
  --gray-500: oklch(0.55 0.014 15);
  --gray-600: oklch(0.45 0.014 15);
  --gray-700: oklch(0.37 0.013 15);
  --gray-950: oklch(0.17 0.012 15);

  --font: 'Epilogue', ui-sans-serif, system-ui, -apple-system, 'Segoe UI', sans-serif;
  --mono: ui-monospace, 'Cascadia Code', 'SF Mono', Menlo, Consolas, monospace;
  --radius: 10px;
  --radius-lg: 16px;
  --shadow: 0 1px 2px oklch(0.16 0.01 15 / 0.05), 0 8px 24px -12px oklch(0.16 0.01 15 / 0.18);
  --ease: cubic-bezier(0.22, 1, 0.36, 1);
  --wrap: 1180px;
}

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

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

@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }
  *,
  *::before,
  *::after {
    transition-duration: 0ms !important;
  }
}

body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font-family: var(--font);
  font-size: 17px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

h1,
h2,
h3,
p,
ul,
ol,
dl,
dd {
  margin: 0;
}

h1,
h2 {
  font-weight: 700;
  text-wrap: balance;
}

h3 {
  font-weight: 600;
}

p {
  text-wrap: pretty;
}

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

a:hover {
  color: var(--primary-deeper);
}

:focus-visible {
  outline: 2px solid var(--primary-deep);
  outline-offset: 3px;
  border-radius: 4px;
}

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

/* Components set display on buttons and panels; [hidden] must still win. */
[hidden] {
  display: none !important;
}

.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip: rect(0 0 0 0);
  white-space: nowrap;
}

.skip {
  position: absolute;
  left: 12px;
  top: -48px;
  z-index: 10;
  padding: 10px 14px;
  background: var(--surface);
  border-radius: var(--radius);
}

.skip:focus {
  top: 12px;
}

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

.narrow {
  max-width: 720px;
}

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

.small {
  font-size: 14px;
}

/* ---------- Type scale (DESIGN.md: one size per rank) ---------- */

.display-1,
.display-1-page,
.display-2,
.display-3 {
  font-weight: 700;
  line-height: 1.06;
  letter-spacing: -0.025em;
}

.display-1 {
  font-size: clamp(36px, 2.1rem + 3vw, 76px);
}

.display-1-page {
  font-size: clamp(32px, 1.8rem + 2.2vw, 60px);
}

.display-2 {
  font-size: clamp(26px, 1.3rem + 1.8vw, 48px);
}

.display-3 {
  font-size: clamp(22px, 1.2rem + 0.6vw, 30px);
  letter-spacing: -0.015em;
}

.eyebrow {
  font-size: 14px;
  font-weight: 600;
  letter-spacing: 0.3em;
  text-transform: uppercase;
  color: var(--gray-600);
  margin-bottom: 18px;
}

.label {
  display: block;
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--gray-600);
}

.lede {
  font-size: clamp(18px, 1rem + 0.4vw, 21px);
  color: var(--gray-700);
  max-width: 62ch;
  margin-top: 20px;
}

.accent {
  color: var(--primary);
}

/* ---------- Buttons and fields ---------- */

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  min-height: 46px;
  padding: 0 22px;
  border: 1px solid transparent;
  border-radius: 999px;
  font: inherit;
  font-size: 16px;
  font-weight: 600;
  text-decoration: none;
  cursor: pointer;
  transition:
    background 180ms var(--ease),
    border-color 180ms var(--ease),
    transform 180ms var(--ease);
}

.btn:active {
  transform: translateY(1px);
}

.btn-primary {
  background: var(--primary-deep);
  color: #fff;
}

.btn-primary:hover {
  background: var(--primary-deeper);
  color: #fff;
}

.btn-quiet {
  background: transparent;
  border-color: var(--gray-300);
  color: var(--ink);
}

.btn-quiet:hover {
  border-color: var(--ink);
  color: var(--ink);
}

.btn-small {
  min-height: 34px;
  padding: 0 14px;
  font-size: 14px;
  background: var(--surface);
  border-color: var(--gray-300);
  color: var(--ink);
}

.btn-small:hover {
  border-color: var(--ink);
  color: var(--ink);
}

.btn-block {
  width: 100%;
}

.btn[disabled] {
  opacity: 0.6;
  cursor: progress;
}

.field {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.field label {
  font-size: 14px;
  font-weight: 600;
}

input[type='email'],
input[type='text'],
input:not([type]) {
  width: 100%;
  min-height: 46px;
  padding: 0 14px;
  border: 1px solid var(--gray-300);
  border-radius: var(--radius);
  background: var(--surface);
  font: inherit;
  font-size: 16px;
  color: var(--ink);
}

input:focus {
  outline: none;
  border-color: var(--primary-deep);
  box-shadow: 0 0 0 3px oklch(0.56 0.19 15 / 0.15);
}

input[aria-invalid='true'] {
  border-color: var(--primary-deep);
}

.hint {
  font-size: 13px;
  color: var(--gray-600);
}

.check {
  display: flex;
  gap: 10px;
  align-items: flex-start;
  font-size: 14px;
  color: var(--gray-700);
}

.check input {
  width: 18px;
  height: 18px;
  margin: 2px 0 0;
  accent-color: var(--primary-deep);
  flex: none;
}

.form-error {
  padding: 10px 14px;
  border-radius: var(--radius);
  background: var(--primary-soft);
  color: var(--primary-deeper);
  font-size: 14px;
}

.stack-form {
  display: flex;
  flex-direction: column;
  gap: 20px;
  max-width: 440px;
  margin-top: 32px;
}

.notice {
  margin-top: 28px;
  padding: 18px 20px;
  border-radius: var(--radius-lg);
  background: var(--surface);
  border: 1px solid var(--gray-200);
}

.notice-error {
  background: var(--primary-soft);
  border-color: transparent;
  color: var(--primary-deeper);
}

/* ---------- Header and footer ---------- */

.site-header {
  border-bottom: 1px solid var(--gray-200);
  background: var(--paper);
}

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

.brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  color: var(--ink);
  font-weight: 700;
  font-size: 17px;
  letter-spacing: -0.01em;
  text-decoration: none;
}

.brand:hover {
  color: var(--ink);
}

.brand-logo {
  display: block;
  width: auto;
  height: 38px;
}

/* "Plugins" after the logo, set off by a hairline. */
.brand-sub {
  padding-left: 10px;
  border-left: 1px solid var(--gray-300);
  font-weight: 500;
  font-size: 15px;
  line-height: 24px;
  color: var(--gray-600);
}

.site-nav {
  display: flex;
  align-items: center;
  gap: clamp(14px, 3vw, 32px);
  font-size: 15px;
}

.site-nav a {
  color: var(--ink);
  text-decoration: none;
  padding: 8px 0;
}

.site-nav a:hover {
  color: var(--primary-deep);
}

.nav-account {
  padding: 8px 16px !important;
  border: 1px solid var(--gray-300);
  border-radius: 999px;
}

.site-footer {
  margin-top: clamp(64px, 8vw, 120px);
  background: var(--gray-950);
  color: oklch(0.86 0.01 15);
  padding: 56px 0 28px;
  font-size: 15px;
}

.site-footer a {
  color: oklch(0.92 0.008 15);
  text-decoration: none;
}

.site-footer a:hover {
  color: var(--primary);
}

.brand-light,
.brand-light:hover {
  color: #fff;
}

.brand-light .brand-sub {
  border-left-color: oklch(0.4 0.01 15);
  color: oklch(0.75 0.01 15);
}

@media (max-width: 480px) {
  .site-header .brand-logo {
    height: 30px;
  }
}

.footer-grid {
  display: grid;
  grid-template-columns: 2fr 1fr 1fr;
  gap: 32px;
}

.footer-note {
  margin-top: 14px;
  max-width: 34ch;
  color: oklch(0.75 0.01 15);
}

.footer-links {
  list-style: none;
  padding: 0;
  display: flex;
  flex-direction: column;
}

.footer-links li {
  display: flex;
}

.footer-links a {
  padding: 5px 0;
}

.footer-base {
  margin-top: 40px;
  padding-top: 20px;
  border-top: 1px solid oklch(0.3 0.012 15);
  font-size: 13px;
  color: oklch(0.65 0.01 15);
}

/* ---------- Sections (uneven rhythm on purpose) ---------- */

.hero {
  padding: clamp(72px, 11vw, 160px) 0 clamp(56px, 8vw, 112px);
}

.hero .display-1 {
  max-width: 17ch;
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-top: 36px;
}

.section {
  padding: clamp(64px, 8vw, 128px) 0;
}

.section-tight {
  padding: clamp(48px, 6vw, 80px) 0;
}

.section-alt {
  background: var(--gray-50);
  border-top: 1px solid var(--gray-200);
  border-bottom: 1px solid var(--gray-200);
}

.two-col {
  display: grid;
  grid-template-columns: minmax(0, 5fr) minmax(0, 7fr);
  gap: clamp(32px, 6vw, 96px);
  align-items: start;
}

/* ---------- Plugin rows (rows, not a grid of identical cards) ---------- */

.plugin-rows {
  list-style: none;
  padding: 0;
  margin-top: 40px;
  border-top: 1px solid var(--gray-200);
}

.plugin-row {
  position: relative;
  display: grid;
  grid-template-columns: 56px minmax(0, 1fr) auto 32px;
  align-items: center;
  gap: 24px;
  padding: 28px 8px;
  border-bottom: 1px solid var(--gray-200);
  transition: background 200ms var(--ease);
}

.plugin-row:hover {
  background: var(--surface);
}

.plugin-index {
  font-family: var(--mono);
  font-size: 14px;
  color: var(--gray-500);
}

.plugin-main h3 {
  font-size: clamp(22px, 1.2rem + 0.5vw, 26px);
  letter-spacing: -0.015em;
}

.plugin-main h3 a {
  color: var(--ink);
  text-decoration: none;
}

.plugin-main p {
  margin-top: 4px;
  color: var(--gray-700);
  max-width: 60ch;
}

/* The whole row opens the plugin. */
.stretch::after {
  content: '';
  position: absolute;
  inset: 0;
}

.plugin-facts {
  display: flex;
  gap: 32px;
  text-align: right;
}

.plugin-facts dd {
  font-weight: 600;
  font-size: 18px;
}

.row-arrow {
  font-size: 22px;
  color: var(--gray-500);
  transition:
    transform 200ms var(--ease),
    color 200ms var(--ease);
}

.plugin-row:hover .row-arrow {
  transform: translateX(4px);
  color: var(--primary-deep);
}

/* ---------- Licensing and FAQ ---------- */

.terms-list {
  display: flex;
  flex-direction: column;
}

.terms-list > div {
  display: grid;
  grid-template-columns: minmax(0, 2fr) minmax(0, 3fr);
  gap: 24px;
  padding: 22px 0;
  border-top: 1px solid var(--gray-200);
}

.terms-list > div:last-child {
  border-bottom: 1px solid var(--gray-200);
}

.terms-list dt {
  font-weight: 600;
  font-size: 18px;
}

.terms-list dd {
  color: var(--gray-700);
}

.faq details {
  border-top: 1px solid var(--gray-200);
}

.faq details:last-child {
  border-bottom: 1px solid var(--gray-200);
}

.faq summary {
  display: flex;
  justify-content: space-between;
  gap: 16px;
  padding: 20px 0;
  font-size: 18px;
  font-weight: 600;
  cursor: pointer;
  list-style: none;
}

.faq summary::-webkit-details-marker {
  display: none;
}

.faq summary::after {
  content: '+';
  font-weight: 400;
  color: var(--gray-500);
  transition: transform 200ms var(--ease);
}

.faq details[open] summary::after {
  transform: rotate(45deg);
}

.faq details p {
  padding: 0 0 22px;
  color: var(--gray-700);
  max-width: 62ch;
}

/* ---------- Plugin page ---------- */

.product-head {
  padding: clamp(40px, 6vw, 80px) 0 clamp(32px, 4vw, 56px);
}

.crumbs {
  display: flex;
  gap: 10px;
  font-size: 14px;
  color: var(--gray-600);
  margin-bottom: 20px;
}

.crumbs a {
  color: var(--gray-700);
}

.product-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 8px 24px;
  margin-top: 24px;
  font-size: 15px;
  color: var(--gray-600);
}

.product-grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 400px;
  gap: clamp(32px, 5vw, 72px);
  align-items: start;
}

.product-aside {
  position: sticky;
  top: 24px;
}

.prose {
  max-width: 68ch;
  color: var(--gray-700);
}

.prose > * + * {
  margin-top: 1em;
}

.prose h2,
.prose h3 {
  color: var(--ink);
  margin-top: 1.8em;
  letter-spacing: -0.01em;
}

.prose h2 {
  font-size: 24px;
}

.prose h3 {
  font-size: 20px;
}

.prose ul {
  padding-left: 1.2em;
}

.prose li + li {
  margin-top: 0.35em;
}

.prose li::marker {
  color: var(--primary-deep);
}

.releases {
  margin-top: clamp(48px, 6vw, 80px);
}

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

.release-list li {
  padding: 18px 0;
  border-top: 1px solid var(--gray-200);
}

.release-head {
  display: flex;
  align-items: baseline;
  gap: 14px;
}

.release-version {
  font-family: var(--mono);
  font-weight: 600;
}

.release-notes {
  margin-top: 8px;
  font-size: 15px;
  color: var(--gray-700);
}

.release-notes > * + * {
  margin-top: 0.5em;
}

.release-notes ul {
  padding-left: 1.2em;
}

/* ---------- Buy panel ---------- */

.buy-panel,
.key-panel {
  display: flex;
  flex-direction: column;
  gap: 18px;
  padding: 24px;
  background: var(--surface);
  border: 1px solid var(--gray-200);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow);
}

.tiers {
  border: 0;
  padding: 0;
  margin: 0;
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.tiers legend {
  margin-bottom: 10px;
}

.tier {
  display: grid;
  grid-template-columns: 20px minmax(0, 1fr) auto;
  align-items: center;
  gap: 12px;
  padding: 14px 16px;
  border: 1px solid var(--gray-300);
  border-radius: var(--radius);
  cursor: pointer;
  transition:
    border-color 180ms var(--ease),
    background 180ms var(--ease);
}

.tier:hover {
  border-color: var(--gray-500);
}

.tier:has(input:checked) {
  border-color: var(--primary-deep);
  background: var(--primary-soft);
  box-shadow: inset 0 0 0 1px var(--primary-deep);
}

.tier input {
  width: 18px;
  height: 18px;
  margin: 0;
  accent-color: var(--primary-deep);
}

.tier-body {
  display: flex;
  flex-direction: column;
  line-height: 1.3;
}

.tier-name {
  font-weight: 600;
}

.tier-sites {
  font-size: 14px;
  color: var(--gray-600);
}

.tier-price {
  font-weight: 700;
  font-size: 20px;
  letter-spacing: -0.01em;
}

.includes {
  list-style: none;
  padding: 0;
  font-size: 15px;
  color: var(--gray-700);
}

.includes li {
  display: flex;
  gap: 10px;
}

.includes li::before {
  content: '✓';
  color: var(--primary-deep);
  font-weight: 700;
}

.test-mode {
  padding: 12px 14px;
  border-radius: var(--radius);
  border: 1px dashed var(--gray-500);
  font-size: 14px;
  color: var(--gray-700);
}

.paypal-buttons {
  min-height: 52px;
}

.secure {
  text-align: center;
}

.key-panel h2 {
  font-size: 24px;
  letter-spacing: -0.01em;
}

.key-box {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 10px;
  padding: 12px 14px;
  border: 1px solid var(--gray-300);
  border-radius: var(--radius);
  background: var(--paper);
}

.key {
  flex: 1;
  min-width: 0;
  font-size: 15px;
  letter-spacing: 0.02em;
  overflow-wrap: anywhere;
}

.key-panel ol {
  padding-left: 1.2em;
  color: var(--gray-700);
  font-size: 15px;
}

.key-panel ol li + li {
  margin-top: 6px;
}

/* ---------- Account ---------- */

.narrow-page {
  padding: clamp(48px, 8vw, 112px) 0 clamp(24px, 4vw, 48px);
}

.account-head {
  padding: clamp(40px, 6vw, 80px) 0 8px;
}

.account-head-row {
  display: flex;
  justify-content: space-between;
  align-items: flex-end;
  gap: 24px;
  flex-wrap: wrap;
}

.license-list {
  list-style: none;
  padding: 0;
  margin-top: 24px;
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.license-card {
  display: flex;
  flex-direction: column;
  gap: 20px;
  padding: 24px;
  background: var(--surface);
  border: 1px solid var(--gray-200);
  border-radius: var(--radius-lg);
}

.license-top {
  display: flex;
  justify-content: space-between;
  gap: 16px;
}

.license-top h3 {
  font-size: 22px;
  letter-spacing: -0.01em;
}

.status {
  align-self: flex-start;
  padding: 4px 12px;
  border-radius: 999px;
  font-size: 13px;
  font-weight: 600;
  background: var(--gray-100);
  color: var(--gray-700);
}

.status-active {
  background: oklch(0.95 0.04 150);
  color: oklch(0.42 0.11 150);
}

.status-revoked,
.status-suspended,
.status-expired {
  background: var(--primary-soft);
  color: var(--primary-deeper);
}

.key-row {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.license-cols {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 24px;
}

.license-cols .label {
  margin-bottom: 6px;
}

.domains,
.downloads {
  list-style: none;
  padding: 0;
  margin: 8px 0;
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.table-scroll {
  overflow-x: auto;
  margin-top: 20px;
}

table {
  width: 100%;
  border-collapse: collapse;
  font-size: 15px;
}

th,
td {
  text-align: left;
  padding: 12px 10px;
  border-bottom: 1px solid var(--gray-200);
  white-space: nowrap;
}

th {
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--gray-600);
}

.num {
  text-align: right;
  font-variant-numeric: tabular-nums;
}

/* ---------- Receipt ---------- */

.receipt-head {
  display: flex;
  justify-content: space-between;
  align-items: flex-end;
  gap: 16px;
  margin-top: 24px;
}

.receipt-parties {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 24px;
  margin: 32px 0;
}

.receipt-parties p {
  margin-top: 6px;
  overflow-wrap: anywhere;
}

.receipt-lines td,
.receipt-lines th {
  white-space: normal;
}

.receipt-lines tfoot th {
  font-size: 16px;
  letter-spacing: 0;
  text-transform: none;
  color: var(--ink);
  border-bottom: 0;
}

.receipt-lines + p {
  margin-top: 16px;
}

@media print {
  .site-header,
  .site-footer,
  .no-print,
  .skip {
    display: none !important;
  }
  body {
    background: #fff;
  }
}

/* ---------- Responsive ---------- */

@media (max-width: 960px) {
  .product-grid,
  .two-col {
    grid-template-columns: minmax(0, 1fr);
  }
  .product-aside {
    position: static;
  }
  .footer-grid {
    grid-template-columns: 1fr 1fr;
  }
  .footer-grid > :first-child {
    grid-column: span 2;
  }
}

@media (max-width: 640px) {
  .plugin-row {
    grid-template-columns: minmax(0, 1fr) 24px;
    gap: 12px 16px;
  }
  .plugin-index {
    display: none;
  }
  .plugin-facts {
    grid-column: 1;
    text-align: left;
    gap: 24px;
  }
  .row-arrow {
    grid-row: 1;
    grid-column: 2;
  }
  .terms-list > div,
  .license-cols,
  .receipt-parties {
    grid-template-columns: minmax(0, 1fr);
  }
  .terms-list > div {
    gap: 6px;
  }
  .site-nav a:not(.nav-account) {
    display: none;
  }
}

@media (pointer: coarse) {
  .footer-links a {
    padding: 12px 0;
  }
  .btn-small {
    min-height: 44px;
  }
}

/* A section heading's supporting line. */
.display-2 + p {
  margin-top: 16px;
}

.plugin-rows + p,
.display-2 + .muted {
  margin-top: 16px;
}

.domains li {
  display: flex;
  align-items: center;
  gap: 10px;
}

.inline-form {
  margin-left: auto;
}

.link-button {
  border: 0;
  background: none;
  padding: 4px 0;
  font: inherit;
  font-size: 14px;
  color: var(--primary-deep);
  text-decoration: underline;
  text-underline-offset: 3px;
  cursor: pointer;
}

/* Short pages: keep the footer at the bottom of the window. */
body {
  min-height: 100vh;
  min-height: 100dvh;
  display: flex;
  flex-direction: column;
}

main {
  flex: 1;
}

.notice + p {
  margin-top: 16px;
}

.brand > span,
.nav-account {
  white-space: nowrap;
}

@media (max-width: 960px) {
  /* On phones and tablets the price comes right after the intro, not after the whole description. */
  .product-aside {
    order: -1;
  }
}

@media (max-width: 420px) {
  .brand-sub {
    display: none;
  }
}

/* ---------- Documentation (account) ---------- */

.docs-link {
  margin-left: 12px;
  font-size: 14px;
  font-weight: 600;
  color: var(--primary-deep);
  text-decoration: none;
}

.docs-link:hover {
  text-decoration: underline;
}

.download-row {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px 0;
}

.docs-head {
  padding: clamp(40px, 6vw, 80px) 0 clamp(16px, 3vw, 32px);
}

.docs-head-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-top: 28px;
}

.doc-cards {
  list-style: none;
  padding: 0;
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(min(100%, 340px), 1fr));
  gap: 12px;
}

.doc-card {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr) auto;
  align-items: start;
  gap: 16px;
  height: 100%;
  padding: 20px 22px;
  background: var(--surface);
  border: 1px solid var(--gray-200);
  border-radius: var(--radius-lg);
  color: var(--ink);
  text-decoration: none;
  transition:
    border-color 180ms var(--ease),
    box-shadow 180ms var(--ease),
    transform 180ms var(--ease);
}

.doc-card:hover {
  border-color: var(--gray-300);
  box-shadow: var(--shadow);
  transform: translateY(-1px);
}

.doc-card:hover .row-arrow {
  color: var(--primary-deep);
  transform: translateX(3px);
}

.doc-card-num {
  font-size: 14px;
  font-weight: 700;
  font-variant-numeric: tabular-nums;
  color: var(--primary-deep);
  padding-top: 3px;
}

.doc-card-text {
  display: grid;
  gap: 4px;
}

.doc-card-title {
  font-size: 18px;
  font-weight: 700;
  letter-spacing: -0.01em;
}

.doc-card-summary {
  font-size: 15px;
  color: var(--gray-600);
  line-height: 1.5;
}

.docs-help {
  margin-top: 28px;
}

.docs-layout {
  display: grid;
  grid-template-columns: 250px minmax(0, 1fr);
  gap: clamp(32px, 5vw, 72px);
  align-items: start;
  padding-top: clamp(32px, 5vw, 64px);
  padding-bottom: clamp(48px, 7vw, 96px);
}

.docs-nav {
  position: sticky;
  top: 24px;
  font-size: 15px;
}

.docs-nav > summary {
  display: none;
}

.docs-nav ol {
  list-style: none;
  padding: 0;
  margin: 12px 0 0;
}

.docs-nav a {
  display: block;
  padding: 7px 12px;
  border-radius: 8px;
  color: var(--gray-700);
  text-decoration: none;
}

.docs-nav a:hover {
  background: var(--gray-100);
  color: var(--ink);
}

.docs-nav a[aria-current="page"] {
  background: var(--primary-soft);
  color: var(--primary-deeper);
  font-weight: 600;
}

.docs-nav .docs-nav-home {
  font-weight: 700;
  color: var(--ink);
}

.docs-nav .docs-nav-sections {
  margin: 2px 0 6px 12px;
  padding-left: 10px;
  border-left: 1px solid var(--gray-200);
}

.docs-nav-sections a {
  padding: 4px 10px;
  font-size: 14px;
  color: var(--gray-600);
}

.docs-article {
  min-width: 0;
  max-width: 760px;
}

.docs-article .eyebrow {
  margin-bottom: 12px;
}

.docs-prose {
  margin-top: 28px;
  max-width: none;
}

.docs-prose h2,
.docs-prose h3,
.docs-prose h4 {
  position: relative;
  scroll-margin-top: 24px;
}

.docs-prose h4 {
  font-size: 17px;
  color: var(--ink);
}

.heading-anchor {
  position: absolute;
  left: -0.9em;
  color: var(--gray-300);
  text-decoration: none;
  opacity: 0;
  transition: opacity 150ms var(--ease);
}

.docs-prose :is(h2, h3, h4):hover .heading-anchor {
  opacity: 1;
}

.docs-prose a {
  color: var(--primary-deep);
}

.docs-prose ol {
  padding-left: 1.3em;
}

.docs-prose ol li::marker {
  color: var(--primary-deep);
  font-weight: 700;
}

.docs-prose strong {
  color: var(--ink);
}

.docs-prose :not(pre) > code {
  padding: 2px 6px;
  border-radius: 6px;
  background: var(--gray-100);
  color: var(--ink);
  font-family: var(--mono);
  font-size: 0.88em;
}

.docs-prose table {
  width: 100%;
  border-collapse: collapse;
  font-size: 15px;
}

.docs-prose th,
.docs-prose td {
  padding: 10px 12px;
  border-bottom: 1px solid var(--gray-200);
  text-align: left;
  vertical-align: top;
}

.docs-prose th {
  font-size: 13px;
  font-weight: 600;
  color: var(--gray-600);
}

.code-block {
  position: relative;
  margin-top: 1.2em;
  border-radius: var(--radius);
  background: var(--gray-950);
  color: oklch(0.93 0.01 15);
}

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

.code-lang {
  position: absolute;
  top: 9px;
  left: 20px;
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: oklch(0.7 0.02 15);
}

.code-lang + .code-copy + pre {
  padding-top: 34px;
}

.code-copy {
  position: absolute;
  top: 8px;
  right: 8px;
  padding: 4px 10px;
  border: 1px solid oklch(1 0 0 / 0.14);
  border-radius: 999px;
  background: oklch(1 0 0 / 0.06);
  color: oklch(0.93 0.01 15);
  font: inherit;
  font-size: 12px;
  font-weight: 600;
  cursor: pointer;
}

.code-copy:hover {
  background: oklch(1 0 0 / 0.14);
}

.doc-shot {
  margin: 1.6em 0;
}

.doc-shot img {
  display: block;
  width: 100%;
  height: auto;
  border: 1px solid var(--gray-200);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  background: var(--surface);
}

.doc-shot figcaption {
  margin-top: 10px;
  font-size: 14px;
  color: var(--gray-600);
  text-align: center;
}

.callout {
  margin-top: 1.2em;
  padding: 14px 18px;
  border-radius: var(--radius);
  border-left: 3px solid var(--gray-300);
  background: var(--gray-50);
  color: var(--gray-700);
}

.callout > * + * {
  margin-top: 0.6em;
}

.callout-tip {
  border-left-color: oklch(0.62 0.12 150);
  background: oklch(0.97 0.025 150);
}

.callout-warning {
  border-left-color: var(--primary-deep);
  background: var(--primary-soft);
}

.docs-pager {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
  margin-top: clamp(40px, 6vw, 64px);
  padding-top: 28px;
  border-top: 1px solid var(--gray-200);
}

.docs-pager-link {
  display: grid;
  gap: 4px;
  padding: 16px 18px;
  border: 1px solid var(--gray-200);
  border-radius: var(--radius-lg);
  color: var(--ink);
  font-weight: 600;
  text-decoration: none;
  transition: border-color 180ms var(--ease);
}

.docs-pager-link:hover {
  border-color: var(--ink);
}

.docs-pager-next {
  text-align: right;
}

@media (max-width: 900px) {
  .docs-layout {
    grid-template-columns: minmax(0, 1fr);
    gap: 24px;
  }

  .docs-nav {
    position: static;
    padding: 4px 16px;
    border: 1px solid var(--gray-200);
    border-radius: var(--radius-lg);
    background: var(--surface);
  }

  .docs-nav > summary {
    display: list-item;
    padding: 10px 0;
    font-weight: 600;
    cursor: pointer;
  }

  .docs-nav nav {
    padding-bottom: 12px;
  }

  .heading-anchor {
    display: none;
  }
}

@media (max-width: 640px) {
  .docs-pager {
    grid-template-columns: minmax(0, 1fr);
  }

  .docs-pager-next {
    text-align: left;
  }

  .docs-link {
    margin-left: 0;
    flex-basis: 100%;
  }
}

@media (prefers-reduced-motion: reduce) {
  .doc-card:hover,
  .doc-card:hover .row-arrow {
    transform: none;
  }
}

/* ---------- License keys: Local, Staging, Production ---------- */

.key-list {
  display: grid;
  gap: 12px;
  margin: 8px 0 0;
}

.key-item {
  display: grid;
  gap: 6px;
}

.key-item dt {
  font-size: 14px;
}

.key-item dd {
  margin: 0;
}

.key-help {
  margin: 4px 0 0;
}

