/* Page-group styles (product: /features, /features/*, /how-it-works, /os-templates, /faq, /changelog).
   Shared building blocks live in site.css "Page kit"; only group-specific rules here, prefix nx-pd-.
   Same rules as the kit: band colours only (--nx-fg / --nx-bg / --nx-accent), no grey, no cards. */

/* ---------- Numbered steps (landing/_pd_steps.php) ---------- */
.nx-pd-steps {
  counter-reset: nx-pd-step;
  display: grid;
  gap: clamp(1.75rem, 3vw, 2.5rem);
  max-width: 56rem;
  margin: 0;
  padding: 0;
  list-style: none;
}
.nx-pd-steps__item {
  counter-increment: nx-pd-step;
  display: grid;
  grid-template-columns: 4.5rem minmax(0, 1fr);
  column-gap: 1.5rem;
  align-items: baseline;
}
.nx-pd-steps__item::before {
  content: counter(nx-pd-step, decimal-leading-zero);
  grid-row: span 3;
  font-size: clamp(2.25rem, 1.8rem + 1.6vw, 3.25rem);
  line-height: 1;
  font-weight: 750;
  letter-spacing: -.04em;
  font-variant-numeric: tabular-nums;
}
.nx-pd-steps__item > * { grid-column: 2; }
.nx-pd-steps__item:first-child::before { color: var(--nx-accent); }
.nx-pd-steps__title { margin: 0; font-size: clamp(1.25rem, 1.1rem + .6vw, 1.625rem); line-height: 1.2; letter-spacing: -.025em; font-weight: 700; color: inherit; }
.nx-pd-steps__text { margin: .625rem 0 0; font-size: 1.0625rem; line-height: 1.65; max-width: 44rem; overflow-wrap: anywhere; }
.nx-pd-steps__text--solo { margin: 0; font-size: clamp(1.125rem, 1.05rem + .3vw, 1.25rem); line-height: 1.55; }
.nx-pd-steps__list { margin: .875rem 0 0; padding-left: 1.25rem; font-size: 1.0625rem; line-height: 1.6; }
.nx-pd-steps__list li + li { margin-top: .375rem; }
.nx-pd-steps__list li::marker { color: var(--nx-accent); }

/* A trailing text link under a section's content. */
.nx-pd-more { margin: clamp(2rem, 4vw, 3rem) 0 0; font-size: 1.0625rem; }

/* Closing block (kit related) appended to the last paper band. */
.nx-pd-tail { margin-top: clamp(4rem, 8vw, 6rem); }

/* ---------- Proxmox UI vs NexoVirt table ---------- */
.nx-pd-vs th[scope="row"] { width: 28%; }
.nx-pd-vs td { width: 36%; }
.nx-pd-vs thead th:last-child { color: var(--nx-accent); }
.nx-pd-vs__us { font-weight: 600; }

/* ---------- Screenshot gallery ---------- */
.nx-pd-gallery {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: clamp(2rem, 4vw, 3.5rem);
}

/* ---------- In-page jump links (/features, /faq): text links, the active colour on hover ---------- */
.nx-pd-jump ul {
  display: flex;
  flex-wrap: wrap;
  gap: .5rem;
  margin: 2rem 0 0;
  padding: 0;
  list-style: none;
}
.nx-page-hero--center .nx-pd-jump ul { justify-content: center; }
.nx-pd-jump a {
  display: inline-block;
  padding: .5rem 1rem;
  border: 1px solid var(--nx-line-strong);
  border-radius: 999px;
  font-size: .9375rem;
  font-weight: 600;
  text-decoration: none;
}
.nx-pd-jump a:hover,
.nx-pd-jump a:focus-visible { border-color: var(--nx-accent); color: var(--nx-accent) !important; outline: none; }

/* ---------- Feature index (/features): big bare icon, name, one line, arrow ---------- */
.nx-pd-index {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: clamp(2.5rem, 4vw, 3.5rem) clamp(2rem, 4vw, 4rem);
  margin: 0;
  padding: 0;
  list-style: none;
}
.nx-pd-index__link { display: flex; flex-direction: column; gap: .625rem; text-decoration: none; }
.nx-pd-index__link:hover { text-decoration: none; }
.nx-pd-index__icon { margin-bottom: .625rem; }
.nx-pd-index__name { font-size: clamp(1.25rem, 1.1rem + .6vw, 1.5rem); line-height: 1.2; letter-spacing: -.025em; font-weight: 700; }
.nx-pd-index__name::after { content: " \2192"; display: inline-block; white-space: pre; transition: transform .15s var(--nx-ease); }
.nx-pd-index__text { font-size: 1.0625rem; line-height: 1.6; }
.nx-pd-index__link:hover .nx-pd-index__name,
.nx-pd-index__link:focus-visible .nx-pd-index__name { color: var(--nx-accent); }
.nx-pd-index__link:hover .nx-pd-index__name::after { transform: translateX(4px); }
.nx-pd-index__link:focus-visible { outline: 2px solid var(--nx-accent); outline-offset: 6px; border-radius: 8px; }
.nx-pd-index__plan { font-size: .875rem; font-weight: 700; color: var(--nx-accent); }

/* ---------- Architecture flow (/how-it-works): panel, two paths, guests ---------- */
.nx-pd-flow { max-width: 60rem; margin-inline: auto; text-align: center; }
.nx-pd-flow__node { display: flex; flex-direction: column; align-items: center; gap: .5rem; }
.nx-pd-flow__name { margin: .5rem 0 0; font-size: clamp(1.375rem, 1.2rem + .7vw, 1.875rem); line-height: 1.15; letter-spacing: -.03em; font-weight: 750; color: inherit; }
.nx-pd-flow__role { margin: 0; font-size: 1.0625rem; line-height: 1.55; max-width: 26rem; }
.nx-pd-flow__caps {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: .5rem;
  margin: 1.25rem 0 0;
  padding: 0;
  list-style: none;
}
.nx-pd-flow__caps li { padding: .375rem .875rem; border: 1px solid var(--nx-line-strong); border-radius: 999px; font-size: .9375rem; font-weight: 600; }
/* Connectors: solid accent strokes that show the direction of control (diagram, not dividers). */
.nx-pd-flow__split {
  position: relative;
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 2rem;
  padding-block: 4rem;
  /* Centre stems: from the panel into the top bracket, from the bottom bracket to the nodes. */
  background:
    linear-gradient(var(--nx-accent), var(--nx-accent)) center top / 2px 1rem no-repeat,
    linear-gradient(var(--nx-accent), var(--nx-accent)) center bottom / 2px 1rem no-repeat;
}
.nx-pd-flow__split::before,
.nx-pd-flow__split::after {
  content: "";
  position: absolute;
  left: 25%;
  right: 25%;
  height: 2.25rem;
  border: 2px solid var(--nx-accent);
  pointer-events: none;
}
.nx-pd-flow__split::before { top: 1rem; border-bottom: 0; border-radius: 16px 16px 0 0; }
.nx-pd-flow__split::after { bottom: 1rem; border-top: 0; border-radius: 0 0 16px 16px; }

/* ---------- Changelog ---------- */
.nx-pd-log { max-width: 52rem; }
.nx-pd-log__major + .nx-pd-log__major { margin-top: clamp(4rem, 8vw, 6rem); }
.nx-pd-log__minor { margin-top: clamp(2.5rem, 5vw, 3.5rem); }
.nx-pd-log__heading { margin: 0; color: inherit; letter-spacing: -.03em; font-weight: 750; }
.nx-pd-log__heading a { text-decoration: none; }
.nx-pd-log__heading a:hover { color: var(--nx-accent) !important; }
h2.nx-pd-log__heading { font-size: clamp(2rem, 1.5rem + 2vw, 3rem); line-height: 1.05; }
h3.nx-pd-log__heading { font-size: clamp(1.5rem, 1.25rem + 1vw, 2rem); line-height: 1.15; }
.nx-pd-log__title { font-weight: 500; }
.nx-pd-log__notes { margin-top: 1rem; }
.nx-pd-release { margin-top: clamp(2rem, 4vw, 2.75rem); }
.nx-pd-release__head { display: flex; flex-wrap: wrap; align-items: baseline; gap: .375rem 1rem; }
.nx-pd-release__name { margin: 0; font-size: 1.375rem; line-height: 1.25; letter-spacing: -.02em; font-weight: 700; color: inherit; }
.nx-pd-release__name a { text-decoration: none; }
.nx-pd-release__name a:hover { color: var(--nx-accent) !important; }
.nx-pd-release__meta { margin: 0; font-size: .9375rem; }
.nx-pd-release__flag { font-weight: 700; color: var(--nx-accent); }
.nx-pd-release .nx-longform { margin-top: .75rem; font-size: 1.0625rem; }
.nx-pd-log__empty { font-size: 1.125rem; }

/* ---------- OS templates catalog (/os-templates) ---------- */
.nx-pd-tpl__controls {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: .75rem 1rem;
  margin: 0 0 1.5rem;
}
.nx-pd-tpl__search { flex: 1 1 18rem; }
.nx-pd-tpl__controls .form-control,
.nx-pd-tpl__controls .form-select {
  min-height: 2.75rem;
  border: 1px solid var(--nx-line-strong);
  border-radius: 999px;
  background-color: var(--nx-bg);
  color: var(--nx-fg);
  font-size: 1rem;
  box-shadow: none;
}
.nx-pd-tpl__controls .form-control { padding-inline: 1.125rem; }
.nx-pd-tpl__controls .form-select { width: auto; padding-left: 1.125rem; }
.nx-pd-tpl__controls .form-control:focus,
.nx-pd-tpl__controls .form-select:focus { border-color: var(--nx-accent); outline: 2px solid var(--nx-accent); outline-offset: 1px; }
.nx-pd-tpl__types { display: inline-flex; gap: .375rem; margin: 0; padding: 0; border: 0; }
.nx-pd-tpl__types input { position: absolute; opacity: 0; pointer-events: none; }
.nx-pd-tpl__types label {
  padding: .5625rem 1.125rem;
  border: 1px solid var(--nx-line-strong);
  border-radius: 999px;
  font-size: .9375rem;
  font-weight: 600;
  cursor: pointer;
}
.nx-pd-tpl__types input:checked + label { background: var(--nx-accent); border-color: var(--nx-accent); color: var(--nx-accent-fg); }
.nx-pd-tpl__types input:focus-visible + label { outline: 2px solid var(--nx-accent); outline-offset: 2px; }
.nx-pd-tpl__os { display: flex; align-items: center; gap: .75rem; font-weight: 600; }
.nx-pd-tpl__os img { flex-shrink: 0; }
.nx-pd-tpl__count { margin: 1.25rem 0 0; font-size: .9375rem; font-weight: 600; }
.nx-pd-tpl__empty { margin: 1.5rem 0 0; font-size: 1.0625rem; }

/* ---------- FAQ page: category groups ---------- */
.nx-pd-faqcat + .nx-pd-faqcat { margin-top: clamp(3rem, 6vw, 4.5rem); }
.nx-pd-faqcat__title { max-width: 52rem; margin: 0 auto .5rem; font-size: clamp(1.5rem, 1.25rem + 1vw, 2rem); line-height: 1.15; letter-spacing: -.03em; font-weight: 750; color: inherit; }
.nx-pd-contact { margin: 1.25rem 0 0; font-size: 1.125rem; }
.nx-pd-contact strong { font-weight: 700; }

/* ---------- Responsive ---------- */
@media (max-width: 991.98px) {
  .nx-pd-index { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (max-width: 767.98px) {
  .nx-pd-index,
  .nx-pd-gallery { grid-template-columns: 1fr; }
  .nx-pd-steps__item { grid-template-columns: 3rem minmax(0, 1fr); column-gap: 1rem; }
  .nx-pd-flow__split { grid-template-columns: 1fr; gap: 3rem; padding-block: 3rem; }
  .nx-pd-flow__split::before,
  .nx-pd-flow__split::after { left: calc(50% - 1px); right: auto; width: 2px; height: 1.75rem; border: 0; border-radius: 0; background: var(--nx-accent); }
  .nx-pd-flow__split::before { top: .5rem; }
  .nx-pd-flow__split::after { bottom: .5rem; }
  .nx-pd-vs th[scope="row"],
  .nx-pd-vs td { width: auto; }
}
@media (prefers-reduced-motion: reduce) {
  .nx-pd-index__name::after { transition: none; }
  .nx-pd-index__link:hover .nx-pd-index__name::after { transform: none; }
}
