/* Nitrix — marketing site
   Brand tokens mirror the Nitrix Brand design system (_ds_bundle.css). */

:root {
  /* Brand palette */
  --nx-purple-50: #914AC8;
  --nx-purple-20: #431B5D;
  --nx-coral-70: #F2758B;
  --nx-neutral-25: #2C2C3A;
  --nx-neutral-20: #1B1A21;

  /* Page theme */
  --nx-accent: var(--nx-purple-50);
  --nx-paper: #FBFAF8;
  --nx-ink: var(--nx-neutral-20);

  /* Ink at opacity — the design leans on these constantly */
  --nx-ink-85: rgba(27, 26, 33, .85);
  --nx-ink-82: rgba(27, 26, 33, .82);
  --nx-ink-70: rgba(27, 26, 33, .70);
  --nx-ink-68: rgba(27, 26, 33, .68);
  --nx-ink-55: rgba(27, 26, 33, .55);
  --nx-ink-50: rgba(27, 26, 33, .50);
  --nx-rule: rgba(27, 26, 33, .16);
  --nx-rule-soft: rgba(27, 26, 33, .14);
  --nx-rule-strong: rgba(27, 26, 33, .18);

  --nx-radius: 0.625rem;
  --nx-font: 'Space Grotesk', system-ui, -apple-system, 'Segoe UI', sans-serif;

  --nx-gutter: 24px;
  --nx-measure: 1080px;
}

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

html {
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  scroll-behavior: smooth;
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after {
    animation-duration: .01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: .01ms !important;
  }
}

body {
  margin: 0;
  padding: 0 var(--nx-gutter);
  background: var(--nx-paper);
  color: var(--nx-ink);
  font-family: var(--nx-font);
  font-size: 18px;
  line-height: 1.65;
  overflow-x: clip;
}

a { color: var(--nx-accent); text-decoration: none; }
a:hover { color: var(--nx-purple-20); }

img { max-width: 100%; }

:focus-visible {
  outline: 2px solid var(--nx-accent);
  outline-offset: 3px;
  border-radius: 2px;
}

.nx-skip {
  position: absolute;
  left: -9999px;
  top: 0;
  background: var(--nx-ink);
  color: #fff;
  padding: 10px 16px;
  z-index: 100;
}
.nx-skip:focus { left: 12px; top: 12px; color: #fff; }

/* ---------- Layout ---------- */

.nx-wrap { max-width: var(--nx-measure); margin: 0 auto; }

.nx-section { max-width: var(--nx-measure); margin: 0 auto; }

/* Full-bleed tinted bands break out of the body gutter. */
.nx-band {
  margin: 0 calc(var(--nx-gutter) * -1);
  padding: 48px var(--nx-gutter);
  background: rgba(27, 26, 33, .035);
  border-top: 1px solid var(--nx-rule-soft);
  border-bottom: 1px solid var(--nx-rule-soft);
}

/* ---------- Header ---------- */

.nx-header {
  position: sticky;
  top: 0;
  z-index: 20;
  margin: 0 calc(var(--nx-gutter) * -1);
  padding: 0 var(--nx-gutter);
  background: var(--nx-paper);
  border-bottom: 1px solid var(--nx-rule-soft);
  transition: background-color .25s ease, border-color .25s ease, color .25s ease;
}

.nx-header__inner {
  max-width: var(--nx-measure);
  margin: 0 auto;
  padding: 18px 0;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
}

.nx-header__logo {
  height: 46px;
  width: auto;
  display: block;
  filter: invert(1);
  transition: filter .25s ease;
}

.nx-header__link {
  font-size: 15px;
  font-weight: 500;
  color: var(--nx-ink);
  border-bottom: 1px solid rgba(27, 26, 33, .25);
  padding-bottom: 2px;
  transition: color .25s ease, border-color .25s ease;
}
.nx-header__link:hover {
  color: var(--nx-accent);
  border-bottom-color: var(--nx-accent);
}

/* Scrolled state: header inverts to ink. */
.nx-header.is-stuck {
  background: var(--nx-ink);
  color: #fff;
  border-bottom-color: rgba(255, 255, 255, .14);
}
.nx-header.is-stuck .nx-header__logo { filter: none; }
.nx-header.is-stuck .nx-header__link {
  color: #fff;
  border-bottom-color: rgba(255, 255, 255, .35);
}
.nx-header.is-stuck .nx-header__link:hover { border-bottom-color: #fff; }

/* ---------- Buttons (nx-btn, from the brand bundle) ---------- */

.nx-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: .5rem;
  font-family: var(--nx-font);
  font-weight: 500;
  border: 1px solid transparent;
  border-radius: var(--nx-radius);
  cursor: pointer;
  white-space: nowrap;
  line-height: 1.2;
  text-decoration: none;
  transition: background-color 160ms ease, border-color 160ms ease, opacity 160ms ease;
}

.nx-btn--default { font-size: .9375rem; padding: .625rem 1.25rem; }
.nx-btn--lg      { font-size: 1.0625rem; padding: .8rem 1.75rem; }

.nx-btn--primary {
  background-color: var(--nx-purple-50);
  color: #fff;
}
.nx-btn--primary:hover {
  background-color: var(--nx-purple-20);
  color: #fff;
}

/* ---------- Type ---------- */

.nx-h1 {
  margin: 0 0 22px;
  font-weight: 700;
  font-size: clamp(32px, 4.6vw, 48px);
  line-height: 1.1;
  letter-spacing: -.03em;
  max-width: 20em;
  text-wrap: pretty;
}

.nx-h2 {
  margin: 0 0 22px;
  font-weight: 700;
  font-size: 30px;
  line-height: 1.2;
  letter-spacing: -.025em;
  text-align: center;
}

/* Section heads sitting on a hairline rule. */
.nx-h2--ruled {
  padding-top: 24px;
  border-top: 1px solid var(--nx-rule-strong);
}

.nx-lede {
  margin: 0 0 36px;
  font-size: 19px;
  color: var(--nx-ink-68);
  text-align: center;
}

.nx-eyebrow {
  margin: 0 0 14px;
  font-size: 15px;
  font-weight: 500;
  letter-spacing: .1em;
  text-transform: uppercase;
  color: var(--nx-ink-50);
}

/* ---------- Hero ---------- */

.nx-hero {
  max-width: 720px;
  margin: 0 auto;
  padding: 56px 0 40px;
  text-align: center;
}

.nx-hero__sub {
  margin: 0 auto 30px;
  font-size: 20px;
  font-weight: 500;
  line-height: 1.55;
  color: var(--nx-ink-82);
  max-width: 25em;
  text-wrap: pretty;
}

@keyframes nxRise {
  from { opacity: 0; transform: translateY(10px); }
  to   { opacity: 1; transform: none; }
}
@media (prefers-reduced-motion: no-preference) {
  .nx-rise { animation: nxRise .6s cubic-bezier(.2, .7, .3, 1) both; }
}

/* ---------- Way of working (2-up ruled grid) ---------- */

.nx-intro {
  width: min(100%, 700px);
  margin: 0 auto;
  text-align: center;
}
.nx-intro p:first-child {
  margin: 0 0 14px;
  font-size: 19px;
  font-weight: 500;
  line-height: 1.6;
  color: var(--nx-ink-85);
  text-wrap: pretty;
}
.nx-intro p:last-child {
  margin: 0 0 48px;
  font-size: 19px;
  line-height: 1.7;
  color: var(--nx-ink-68);
  text-wrap: pretty;
}

.nx-grid2 {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
}

.nx-cell {
  padding: 26px 36px 26px 0;
  border-top: 1px solid var(--nx-rule);
  border-right: 1px solid var(--nx-rule);
}
/* Right-hand column: no divider, padding mirrored. */
.nx-cell:nth-child(even) {
  padding: 26px 0 26px 36px;
  border-right: none;
}

.nx-cell__title {
  font-weight: 700;
  font-size: 20px;
  letter-spacing: -.015em;
  margin-bottom: 6px;
}
.nx-cell p {
  margin: 0;
  font-size: 17px;
  line-height: 1.55;
  color: var(--nx-ink-70);
}

/* ---------- Fit comparison ---------- */

.nx-compare {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
  gap: 56px;
  align-items: start;
}

.nx-compare__title { font-size: 16px; font-weight: 500; }
.nx-compare__rule {
  height: 1px;
  background: var(--nx-rule);
  margin: 12px 0 0;
}
.nx-compare__list {
  display: grid;
  gap: 18px;
  padding-top: 18px;
  font-size: 16px;
  line-height: 1.55;
  color: var(--nx-ink-82);
}
.nx-compare__list p { margin: 0; }

/* ---------- Bio ---------- */

.nx-bio {
  display: grid;
  grid-template-columns: minmax(300px, .85fr) minmax(0, 1fr);
  gap: 56px;
  align-items: stretch;
}

.nx-bio__media { display: flex; flex-direction: column; }

/* The portrait fills the column height set by the text beside it.
   min-height:0 lets the flex item shrink below its intrinsic 940px;
   object-fit crops rather than distorts. */
.nx-portrait {
  width: 100%;
  flex: 1 1 auto;
  min-height: 420px;
  height: 0;
  display: block;
  object-fit: cover;
  object-position: center 25%;
  border-radius: 12px;
  background: rgba(27, 26, 33, .06);
}

.nx-bio__caption {
  margin: 14px 0 0;
  font-size: 15px;
  line-height: 1.5;
  color: var(--nx-ink-55);
}

.nx-bio__name {
  margin: 0 0 12px;
  font-weight: 700;
  font-size: clamp(30px, 3.6vw, 40px);
  line-height: 1.1;
  letter-spacing: -.03em;
}

.nx-bio__domains { margin: 0 0 32px; }

.nx-bio__block {
  padding-top: 28px;
  border-top: 1px solid var(--nx-rule);
}
.nx-bio__block + .nx-bio__block { margin-top: 32px; }

.nx-bio__points {
  display: grid;
  gap: 12px;
  font-size: 17px;
  line-height: 1.5;
  color: var(--nx-ink-82);
}

.nx-bio__block p {
  margin: 0;
  font-size: 17px;
  line-height: 1.6;
  color: var(--nx-ink-82);
  text-wrap: pretty;
}

.nx-bio__links {
  display: flex;
  align-items: center;
  gap: 20px;
  margin-top: 32px;
  font-size: 15px;
}
.nx-bio__links a {
  color: var(--nx-ink);
  font-weight: 500;
}
.nx-bio__links a:hover { color: var(--nx-accent); }

.nx-link-icon {
  display: inline-flex;
  align-items: center;
  gap: 7px;
}
.nx-link-underline {
  border-bottom: 1px solid rgba(27, 26, 33, .3);
  padding-bottom: 1px;
}
.nx-link-underline:hover { border-bottom-color: var(--nx-accent); }

/* ---------- Included list ---------- */

.nx-included {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 0 56px;
}
.nx-included li {
  padding: 14px 0;
  border-top: 1px solid var(--nx-rule-soft);
  font-size: 18px;
}
/* Close the list off — the design caps the final row. */
.nx-included li:last-child { border-bottom: 1px solid var(--nx-rule-soft); }

/* ---------- Pricing ---------- */

.nx-price {
  border: 1px solid var(--nx-rule);
  background: rgba(27, 26, 33, .025);
}

.nx-price__row {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: baseline;
  gap: 6px 32px;
  padding: 26px 28px;
}
.nx-price__row + .nx-price__row { border-top: 1px solid rgba(27, 26, 33, .12); }

.nx-price__label { font-weight: 500; font-size: 19px; }

.nx-price__amount {
  font-weight: 700;
  font-size: 28px;
  letter-spacing: -.02em;
  white-space: nowrap;
  text-align: right;
}

.nx-price__note {
  grid-column: 1;
  margin: 0;
  color: var(--nx-ink-68);
  font-size: 17px;
}

/* ---------- FAQ ---------- */

.nx-faq { width: min(100%, 700px); }

.nx-faq__item {
  display: grid;
  gap: 8px;
  padding: 26px 0;
  border-top: 1px solid var(--nx-rule-soft);
}
.nx-faq__item:first-child { padding-top: 0; border-top: none; }
.nx-faq__item:last-child { padding-bottom: 0; }

.nx-faq__item h3 { margin: 0; font-weight: 700; font-size: 19px; }
.nx-faq__item p  { margin: 0; color: rgba(27, 26, 33, .72); }

/* ---------- Footer ---------- */

.nx-footer {
  margin: 0 calc(var(--nx-gutter) * -1);
  background: var(--nx-neutral-20);
  color: #fff;
  padding: 104px var(--nx-gutter) 56px;
}

/* Footer content aligns to the left edge of the 1080px measure. */
.nx-footer__inner {
  width: min(100%, 700px);
  margin-left: max(0px, calc((100% - var(--nx-measure)) / 2));
  margin-right: 0;
}

.nx-footer__title {
  margin: 0 0 24px;
  font-weight: 700;
  font-size: clamp(30px, 5vw, 40px);
  line-height: 1.12;
  letter-spacing: -.03em;
  text-wrap: pretty;
}

.nx-footer__lede {
  margin: 0 0 40px;
  color: rgba(255, 255, 255, .62);
  max-width: 28em;
}

/* Sibling of __inner, not a child: the base row uses the full 1080px
   measure so its divider runs the width of the page rather than stopping
   at the narrower prose column. */
.nx-footer__base {
  width: min(100%, var(--nx-measure));
  margin: 88px auto 0;
  padding-top: 28px;
  border-top: 1px solid rgba(255, 255, 255, .12);
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 20px;
}

.nx-footer__logo { height: 34px; width: auto; display: block; }

.nx-footer__meta { font-size: 14px; color: rgba(255, 255, 255, .45); }

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

@media (max-width: 860px) {
  .nx-bio {
    grid-template-columns: minmax(0, 1fr);
    gap: 32px;
  }
  .nx-portrait {
    flex: none;
    aspect-ratio: 4 / 5;
    min-height: 0;
  }
}

@media (max-width: 720px) {
  .nx-compare {
    grid-template-columns: minmax(0, 1fr);
    gap: 32px;
  }

  /* Drop the two-column rules; each cell becomes a stacked row. */
  .nx-grid2 { grid-template-columns: minmax(0, 1fr); }
  .nx-cell,
  .nx-cell:nth-child(even) {
    padding: 22px 0;
    border-right: none;
  }

  .nx-price__row {
    grid-template-columns: minmax(0, 1fr);
    padding: 22px 20px;
  }
  .nx-price__amount { text-align: left; }

  .nx-footer { padding-top: 72px; }
  .nx-footer__base { margin-top: 56px; }
}
