/* ==========================================================================
   The wide layout on the pages that keep their own template.
   --------------------------------------------------------------------------
   Every page except the two rebuilt ones still renders the theme's template.
   This file reskins those templates: the page header becomes a full-width
   navy band with the network behind it, each section becomes a full-width
   light band, and the theme's components take the wide layout's type, pill
   buttons and solid surfaces.

   How: the theme's stylesheets read their colours from tokens. Inside main
   those tokens are given light values (section 1), and given their dark
   values back wherever a surface is navy (section 2). Rules after that only
   change shape and layout.

   Scope: body.is-wide-skin, which inc/wide-layout.php adds on pages that are not
   rebuilt. Tokens named --q-* come from wide.css.
   ========================================================================== */

/* --- 1. light tokens ----------------------------------------------------- */

.is-wide-skin main.ne {
  overflow-x: clip;
  background: var(--q-paper);
  color: var(--q-ink);
  font-family: var(--q-font);

  --skin-orange: #F97316;
  --skin-orange-lift: #FB923C;
  /* Orange and blue dark enough to read as text on the light bands. */
  --skin-orange-ink: #A8330A;
  --skin-blue-ink: #1D4ED8;
  --skin-purple-ink: #6D28D9;
  --skin-band: var(--q-paper);

  --font-display: var(--q-font);
  --void: var(--q-paper);
  --void-2: var(--q-white);
  --void-3: var(--q-mist);
  --ink-bright: #0F172A;
  --ink-body: #47546B;
  --ink-muted: #55627B;
  --ink-dim: #586377;
  --glass: var(--q-mist);
  --glass-strong: #DCE2ED;
  --glass-border: rgba(15, 23, 42, 0.1);
  --glass-border-lit: rgba(15, 23, 42, 0.26);
  --glass-blur: 0px;
  --orange: var(--skin-orange-ink);
  --orange-light: var(--skin-orange-ink);
  /* Text on the darker orange is white: navy on it would be 2.7:1. */
  --on-orange: #FFFFFF;
  --blue-light: var(--skin-blue-ink);
  --purple-light: var(--skin-purple-ink);
  --shadow-orange: 0 14px 30px -14px rgba(194, 65, 12, 0.5);
}

/* --- 2. dark tokens, wherever the surface is navy ------------------------ */

.is-wide-skin .ne-page-header,
.is-wide-skin .ne-cta,
.is-wide-skin .ne-mock {
  color: rgba(255, 255, 255, 0.96);
  --skin-band: var(--q-dark);
  --void: var(--q-dark);
  --void-2: var(--q-dark);
  --void-3: var(--q-dark-2);
  --ink-bright: rgba(255, 255, 255, 0.96);
  --ink-body: rgba(226, 232, 240, 0.8);
  --ink-muted: rgba(203, 213, 225, 0.78);
  --ink-dim: rgba(255, 255, 255, 0.5);
  --glass: rgba(255, 255, 255, 0.06);
  --glass-strong: rgba(255, 255, 255, 0.1);
  --glass-border: rgba(255, 255, 255, 0.14);
  --glass-border-lit: rgba(255, 255, 255, 0.3);
  --orange: var(--skin-orange);
  --orange-light: var(--skin-orange-lift);
  --on-orange: var(--navy);
  --blue-light: #60A5FA;
  --purple-light: #A78BFA;
}

/* --- 3. bands ------------------------------------------------------------ */

.is-wide-skin .ne-atmosphere { display: none; }

.is-wide-skin .ne-page {
  max-width: none;
  padding: 0;
}

/* Each band runs edge to edge; its content keeps the wide layout's column. */
.is-wide-skin .ne-page > *,
.is-wide-skin .ne-page > article > * {
  padding-inline: max(var(--q-gutter), calc((100% - var(--q-wrap)) / 2));
}
.is-wide-skin .ne-page > article { padding-inline: 0; }

.is-wide-skin .ne-page .ne-section {
  padding-block: clamp(4rem, 2.5rem + 6vw, 7.5rem);
  border-top: 0;
}

.is-wide-skin .ne-page > .ne-section:nth-of-type(even),
.is-wide-skin .ne-page > aside.ne-section {
  background: var(--q-mist);
  --skin-band: var(--q-mist);
  --void-3: var(--q-paper);
  --glass: var(--q-white);
  --glass-strong: var(--q-paper);
}

/* --- 4. the page header -------------------------------------------------- */

.is-wide-skin .ne-page-header {
  position: relative;
  isolation: isolate;
  overflow: hidden;
  padding-block: calc(var(--q-bar) + clamp(3.5rem, 10vh, 7rem)) clamp(3.5rem, 9vh, 6.5rem);
  background:
    radial-gradient(60% 90% at 82% 30%, rgba(var(--q-glow-cool), 0.42), transparent 70%),
    radial-gradient(40% 60% at 0% 0%, rgba(var(--q-glow-cool), 0.18), transparent 70%),
    radial-gradient(36% 60% at 100% 100%, rgba(var(--q-glow-warm), 0.16), transparent 66%),
    var(--q-dark);
}

/* Keeps the words readable where the network runs behind them. */
.is-wide-skin .ne-page-header::after {
  content: '';
  position: absolute;
  inset: 0;
  z-index: -1;
  background: linear-gradient(90deg, rgba(var(--q-dark-rgb), 0.92) 0%, rgba(var(--q-dark-rgb), 0.6) 42%, rgba(var(--q-dark-rgb), 0) 74%);
}

.is-wide-skin .ne-page-header .ne-h {
  max-width: 17ch;
  margin-top: 1.5rem;
  font: 400 clamp(2.5rem, 1.2rem + 4.4vw, 4.625rem) / 1.02 var(--q-font);
  letter-spacing: -0.03em;
}
.is-wide-skin .ne-page-header.is-wide .ne-h { max-width: 21ch; }

.is-wide-skin .ne-page-header .ne-lead {
  max-width: 40rem;
  margin-top: 1.75rem;
  font-size: clamp(1.0625rem, 1rem + 0.35vw, 1.25rem);
  line-height: 1.5;
}
.is-wide-skin .ne-page-header .ne-actions { margin-top: 2.5rem; }
.is-wide-skin .ne-page-header .ne-eyebrow a { color: inherit; text-underline-offset: 4px; }
.is-wide-skin .ne-page-header .ne-eyebrow a:hover { color: var(--orange-light); }

/* --- 5. type ------------------------------------------------------------- */

.is-wide-skin .ne-eyebrow {
  padding: 0;
  border: 0;
  border-radius: 0;
  background: none;
  backdrop-filter: none;
  -webkit-backdrop-filter: none;
  font: 500 0.8125rem / 1.2 var(--q-font);
  letter-spacing: 0.14em;
  color: var(--ink-muted);
}
.is-wide-skin .ne-eyebrow::before {
  width: 0.5rem;
  height: 0.5rem;
  border-radius: 50%;
  background: var(--orange);
}
.is-wide-skin .ne-eyebrow.is-cool::before { background: var(--blue-light); }
.is-wide-skin .ne-eyebrow.is-ai::before { background: var(--purple-light); }

.is-wide-skin .ne-section__head {
  max-width: none;
  margin-bottom: clamp(2.25rem, 5vw, 3.75rem);
}
.is-wide-skin .ne-section__head > h2 {
  max-width: 22ch;
  margin-top: 1.25rem;
  font: 400 clamp(2rem, 1.25rem + 2.7vw, 3.125rem) / 1.08 var(--q-font);
  letter-spacing: -0.035em;
  text-wrap: balance;
}
.is-wide-skin .ne-section__head > p {
  max-width: 40rem;
  margin-top: 1.25rem;
  font-size: clamp(1.0625rem, 1rem + 0.3vw, 1.1875rem);
  line-height: 1.55;
}

/* A section opens the way the rebuilt pages do: heading left, words right.
   Only for a head that sits straight under its section and has both. */
@media (min-width: 861px) {
  .is-wide-skin .ne-section > .ne-section__head:has(> h2 + p) {
    display: grid;
    grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
    align-items: end;
    column-gap: clamp(2rem, 6vw, 5rem);
  }
  .is-wide-skin .ne-section > .ne-section__head:has(> h2 + p) > * { grid-column: 2; max-width: none; }
  .is-wide-skin .ne-section > .ne-section__head:has(> h2 + p) > .ne-eyebrow { grid-column: 1 / -1; justify-self: start; }
  .is-wide-skin .ne-section > .ne-section__head:has(> h2 + p) > h2 {
    grid-column: 1;
    grid-row: 2 / span 6;
    align-self: start;
  }
}

/* Paragraphs set straight into a section, as the case studies do. */
.is-wide-skin .ne-section > p:not([class]) {
  max-width: 44rem;
  font-size: clamp(1.0625rem, 1rem + 0.3vw, 1.1875rem);
  line-height: 1.6;
  color: var(--ink-body);
}
.is-wide-skin .ne-section > p:not([class]) + p:not([class]) { margin-top: 1.1rem; }

/* --- 6. buttons ---------------------------------------------------------- */

.is-wide-skin .ne-btn {
  align-items: center;
  border: 1px solid transparent;
  border-radius: 999px;
  background: var(--skin-orange);
  backdrop-filter: none;
  -webkit-backdrop-filter: none;
  font: 500 1rem / 1 var(--q-font);
  color: var(--q-dark);
  transition: background-color 0.2s ease, color 0.2s ease, border-color 0.2s ease, transform 0.2s var(--q-ease);
}
.is-wide-skin .ne-btn__label { padding: 0.95rem 1.5rem; }
.is-wide-skin .ne-btn__label:not(:last-child) { padding-right: 0.5rem; }
.is-wide-skin .ne-btn__icon {
  width: auto;
  padding-right: 1.35rem;
  border-left: 0;
  color: inherit;
}
.is-wide-skin .ne-btn:hover {
  transform: none;
  border-color: transparent;
  background: var(--skin-orange-lift);
  box-shadow: none;
}
.is-wide-skin .ne-btn:hover .ne-btn__icon {
  background: none;
  color: inherit;
}
.is-wide-skin .ne-btn:active { transform: scale(0.97); }
.is-wide-skin .ne-btn:focus-visible { outline: 2px solid var(--orange); outline-offset: 3px; }

.is-wide-skin .ne-btn.is-ghost {
  border-color: currentColor;
  background: transparent;
  color: var(--ink-bright);
}
.is-wide-skin .ne-btn.is-ghost:hover {
  border-color: currentColor;
  background: color-mix(in srgb, currentColor 10%, transparent);
}

/* --- 7. cards and tiles -------------------------------------------------- */

.is-wide-skin .ne-cards { gap: 1.25rem; margin-top: 0; }
.is-wide-skin .ne-section__head + .ne-cards { margin-top: 0; }
.is-wide-skin * + .ne-cards { margin-top: 2.5rem; }

.is-wide-skin .ne-card {
  padding: 1.75rem 1.75rem 2rem;
  border: 0;
  border-radius: var(--q-r-inner);
  backdrop-filter: none;
  -webkit-backdrop-filter: none;
}
.is-wide-skin .ne-card:hover { transform: translateY(-3px); }
.is-wide-skin .ne-card .label {
  font: 500 0.8125rem / 1.2 var(--q-font);
  letter-spacing: 0.14em;
}
.is-wide-skin .ne-card .figure {
  font-weight: 400;
  letter-spacing: -0.03em;
}
.is-wide-skin .ne-card .name {
  font: 500 1.3125rem / 1.2 var(--q-font);
  letter-spacing: -0.02em;
}
.is-wide-skin .ne-card p { font-size: 1rem; line-height: 1.55; }

.is-wide-skin .ne-build-grid { gap: 1rem; }
.is-wide-skin .ne-build {
  padding: 1.5rem 1.5rem 1.6rem;
  border: 0;
  border-radius: var(--q-r-inner);
}
.is-wide-skin .ne-build::before {
  position: static;
  display: block;
  width: 1.75rem;
  height: 2px;
  margin-bottom: 1.1rem;
}
.is-wide-skin .ne-build__name {
  font: 500 1.1875rem / 1.25 var(--q-font);
  letter-spacing: -0.02em;
}
.is-wide-skin .ne-build__desc { font-size: 0.9375rem; }

/* --- 8. the closing band ------------------------------------------------- */

.is-wide-skin .ne-cta {
  margin: 0;
  padding-block: clamp(4.5rem, 3rem + 7vw, 8.5rem);
  border: 0;
  border-radius: 0;
  background:
    radial-gradient(60% 90% at 100% 0%, rgba(var(--q-glow-cool), 0.34), transparent 66%),
    radial-gradient(50% 70% at 0% 100%, rgba(var(--q-glow-warm), 0.1), transparent 62%),
    var(--q-dark);
  backdrop-filter: none;
  -webkit-backdrop-filter: none;
}
.is-wide-skin .ne-cta h2 {
  max-width: 16ch;
  font: 400 clamp(2.4rem, 1.1rem + 4.6vw, 4.5rem) / 1.02 var(--q-font);
  letter-spacing: -0.03em;
  text-wrap: balance;
}
.is-wide-skin .ne-cta p {
  margin-top: 1.5rem;
  font-size: clamp(1.0625rem, 1rem + 0.35vw, 1.25rem);
  line-height: 1.5;
}

/* The same band set inside a section: a navy surface with the wide layout's corners. */
.is-wide-skin .ne-section .ne-cta {
  margin-top: clamp(3rem, 6vw, 5rem);
  padding-inline: clamp(1.5rem, 5vw, 4rem);
  border-radius: var(--q-r-surface);
}
.is-wide-skin .ne-section > .ne-cta:first-child { margin-top: 0; }

/* --- 9. the theme's other components ------------------------------------- */

/* Body copy inside components: the theme sets it small for a dark page. */
.is-wide-skin .ne-flow__body p,
.is-wide-skin .ne-faq__item p,
.is-wide-skin .ne-case p,
.is-wide-skin .ne-svc__desc,
.is-wide-skin .ne-post p,
.is-wide-skin .ne-note,
.is-wide-skin .ne-pipeline__step p,
.is-wide-skin .ne-track p,
.is-wide-skin .ne-sources,
.is-wide-skin .ne-compare td,
.is-wide-skin .ne-switch__col p,
.is-wide-skin .ne-form__note { font-size: 0.9375rem; }

.is-wide-skin .ne-svc__tags li,
.is-wide-skin .ne-stack li { font-size: 0.8125rem; }

/* Service and case cards: solid surfaces, no outline. */
.is-wide-skin .ne-svc,
.is-wide-skin .ne-case {
  border: 0;
  border-radius: var(--q-r-inner);
  backdrop-filter: none;
  -webkit-backdrop-filter: none;
}
.is-wide-skin .ne-svc__name,
.is-wide-skin .ne-case h3 { font-weight: 500; letter-spacing: -0.02em; }

.is-wide-skin .ne-stats { border-radius: var(--q-r-inner); }
.is-wide-skin .ne-stat b { font-weight: 400; letter-spacing: -0.03em; }
.is-wide-skin .ne-stat span { font-size: 0.8125rem; }

/* Filters and tab rows are pills, like every other control here. */
.is-wide-skin .ne-filter,
.is-wide-skin .ne-switch__tab { border-radius: 999px; }

.is-wide-skin .ne-field input,
.is-wide-skin .ne-field select,
.is-wide-skin .ne-field textarea { border-radius: 14px; }
.is-wide-skin .ne-field label { font: 500 0.8125rem / 1.2 var(--q-font); letter-spacing: 0.14em; }
/* The theme marks focus with a border colour alone. Here it also gets an outline. */
.is-wide-skin .ne-field :is(input, select, textarea):focus-visible {
  outline: 2px solid var(--orange);
  outline-offset: 2px;
}

.is-wide-skin .ne-compare tbody tr:hover { background: rgba(15, 23, 42, 0.03); }

/* On the light page every client mark shows in its own colours, at full
   strength. The one file with nothing but white artwork (PMPXL) is drawn in
   ink so it can be seen. */
.is-wide-skin .ne-wall__logo { filter: none; opacity: 1; }
.is-wide-skin .ne-wall__logo[src*='pmpxl'] { filter: brightness(0); opacity: 0.8; }
/* A tall badge with a tagline under it: the common optical area leaves its
   lettering smaller than the wordmarks around it. */
.is-wide-skin .ne-wall__logo[src*='renspets'] { --area: 5.8rem; }

/* Status colours that were picked for a dark surface. */
.is-wide-skin .ne-pill.is-clear { color: #15803D; }
.is-wide-skin .ne-pill.is-esc { color: var(--skin-orange-ink); }

/* A drawn product screen stays a dark screen, set on the light page. */
.is-wide-skin .ne-mock {
  border: 0;
  border-radius: var(--q-r-inner);
  background: var(--q-dark);
  box-shadow: 0 34px 60px -34px rgba(var(--q-dark-rgb), 0.6);
}
.is-wide-skin .ne-mock .ne-pill.is-clear { color: #4ADE80; }
.is-wide-skin .ne-mock .ne-pill.is-esc { color: var(--skin-orange-lift); }

/* --- 10. writing: posts and the legal pages ------------------------------ */

.is-wide-skin .ne-page > .ne-prose,
.is-wide-skin .ne-page > article > .ne-prose {
  max-width: none;
  padding-block: clamp(3.5rem, 2.5rem + 4vw, 6rem);
  font-size: 1.125rem;
  line-height: 1.7;
}
.is-wide-skin .ne-prose > * { max-width: 44rem; }
.is-wide-skin .ne-prose > :is(pre, table, figure, .ne-figure) { max-width: 56rem; }
.is-wide-skin .ne-prose :is(h2, h3, h4) { font-weight: 500; letter-spacing: -0.02em; }
.is-wide-skin .ne-prose h2 { font-weight: 400; letter-spacing: -0.03em; }
.is-wide-skin .ne-prose pre {
  border: 0;
  border-radius: var(--q-r-inner);
  background: var(--q-dark);
  color: #E2E8F0;
}
.is-wide-skin .ne-prose pre code { border: 0; background: none; color: inherit; }

/* --- 11. reduced motion --------------------------------------------------- */

@media (prefers-reduced-motion: reduce) {
  .is-wide-skin .ne-btn,
  .is-wide-skin .ne-card { transition: none; }
  .is-wide-skin .ne-card:hover { transform: none; }
}
