/* ==========================================================================
   Monolith — Nickel & Swan (options analytics) case study
   The client's product turns the loudest data in finance into one readable
   page, which happens to be this studio's whole thesis — so the page acts
   it out. The hero is a field of raw market static that the cursor combs
   into a clean two-line signal (implied red over historical blue, the
   product's own contract). Sections sit on the platform's light field with
   its deep-purple chrome, screenshots are mounted as the product's own
   card modules, and Nº3 is a working miniature of the volatility module —
   synthetic data, real interaction. Body bg + header adapt per section
   (js/pages/nickel-swan.js). Palette sampled from the shipped UI:
   purple #4F2B83 · implied #FD3700 · historical #0E5FF7 · field #EFF0F3.
   Relies on site.css for resets, nav/footer bones, keyframes.
   ========================================================================== */

html { background: #4F2B83; }
body {
  background: #4F2B83;
  color: #17171B;
  font-family: Inter, -apple-system, BlinkMacSystemFont, sans-serif;
  transition: background-color 0.9s ease;
}
::selection { background: #3A1E63; color: #FFFFFF; }

/* adaptive chrome: purple over the hero (the product's own top bar),
   light over the field sections, deep aubergine at the outro
   (toggled from js/pages/nickel-swan.js) */
header.mono-nav {
  background: rgba(79,43,131,0.92); border-bottom: 1px solid rgba(244,242,248,0.14);
  transition: background-color 0.5s ease, border-color 0.5s ease;
}
header.mono-nav .mono-word, header.mono-nav nav a { color: #C9B8E4; transition: color 0.35s ease; }
header.mono-nav .mono-word:hover, header.mono-nav nav a:hover { color: #FFFFFF; }
header.mono-nav nav a.is-current { color: #FFFFFF; }
/* the diamond mark ships gray (#747474) inline site-wide; this page's
   chrome is dark enough (purple hero, aubergine outro) that gray reads
   muddy, so it's lifted to white here — flipping to a dark tone only
   over the light field header, same pattern as the wordmark/nav links */
header.mono-nav .mono-mark path { fill: #FFFFFF; transition: fill 0.35s ease; }
header.mono-nav.ns-light-hdr { background: rgba(239,240,243,0.92); border-bottom-color: rgba(23,23,27,0.1); }
header.mono-nav.ns-light-hdr .mono-word, header.mono-nav.ns-light-hdr nav a { color: #6E6E76; }
header.mono-nav.ns-light-hdr .mono-word:hover, header.mono-nav.ns-light-hdr nav a:hover { color: #17171B; }
header.mono-nav.ns-light-hdr nav a.is-current { color: #17171B; }
header.mono-nav.ns-light-hdr .mono-mark path { fill: #45454E; }
.mono-burger span { transition: transform 0.4s cubic-bezier(0.5,0.15,0.15,1), opacity 0.2s ease, background-color 0.35s ease !important; }
footer.mono-foot { border-top: 1px solid rgba(244,242,248,0.14); }
footer.mono-foot .mono-foot-brand path { fill: #FFFFFF; }
footer.mono-foot .mono-foot-brand span, footer.mono-foot .mono-foot-copy { color: #9B8CB8; }
footer.mono-foot nav a { color: #9B8CB8; }
footer.mono-foot nav a:hover { color: #FFFFFF; }

.ns-cursor { color: #FFFFFF; animation: blink 1.2s steps(1) infinite; }
.ns-wrap { max-width: 1240px; margin: 0 auto; padding: 0 80px; box-sizing: border-box; }

/* ============ hero ============ */
.ns-hero {
  position: relative; padding: 64px 0 0; overflow: hidden;
  background: radial-gradient(ellipse 90% 75% at 50% 20%, #5B3596 0%, #4F2B83 58%, #3F2169 100%);
}
.ns-hero-canvas { position: absolute; inset: 0; width: 100%; height: 100%; display: block; }
/* static two-line signal stands in where the canvas is hidden (mobile) */
.ns-hero-static { display: none; }
@media (max-width: 760px) {
  .ns-hero-static {
    display: block; position: absolute; left: 0; right: 0; top: 90px;
    width: 100%; height: 260px; opacity: 0.5; pointer-events: none;
  }
}
.ns-hero-fade {
  position: absolute; left: 0; right: 0; bottom: 44px; height: 180px; pointer-events: none;
  background: linear-gradient(to bottom, rgba(79,43,131,0) 0%, #4F2B83 100%);
}
.ns-hero-inner { position: relative; z-index: 2; padding-bottom: 84px; }

.ns-kick { font-family: 'VCR OSD Mono', monospace; font-size: 12px; letter-spacing: 0.12em; text-transform: uppercase; color: #C9B8E4; }
.ns-kick a { color: inherit; text-decoration: none; transition: color 0.2s ease; }
.ns-kick a:hover { color: #FFFFFF; }
.ns-hero-top { display: flex; justify-content: space-between; align-items: baseline; gap: 24px; }
.ns-tag { font-family: 'VCR OSD Mono', monospace; font-size: 12px; letter-spacing: 0.1em; text-transform: uppercase; color: #9B8CB8; }

/* the real lockup (uploaded vector, white fill) — the swan hides in the
   circle where the ampersand would be */
.ns-word { margin: 64px 0 0; }
.ns-word-img { display: block; width: 100%; max-width: 620px; height: auto; }

.ns-product {
  display: flex; align-items: center; gap: 14px; margin: 24px 0 0;
  font-family: 'VCR OSD Mono', monospace; font-size: clamp(12px, 1.3vw, 15px);
  letter-spacing: 0.14em; text-transform: uppercase; color: #C9B8E4;
}
.ns-product-dot { width: 6px; height: 6px; border-radius: 50%; background: #FFFFFF; flex: none; }

.ns-dek { max-width: 640px; margin: 46px 0 0; font-size: 20px; line-height: 1.55; color: rgba(244,242,248,0.85); }

.ns-meta { display: grid; grid-template-columns: repeat(4, 1fr); gap: 28px; margin-top: 84px; padding-top: 26px; border-top: 1px solid rgba(244,242,248,0.22); }
.ns-meta-item { display: flex; flex-direction: column; gap: 8px; }
.ns-meta-label { font-family: 'VCR OSD Mono', monospace; font-size: 11px; letter-spacing: 0.14em; text-transform: uppercase; color: #9B8CB8; }
.ns-meta-val { font-size: 15px; line-height: 1.45; color: #F4F2F8; }

.ns-hero-hint {
  margin: 40px 0 0;
  font-family: 'VCR OSD Mono', monospace; font-size: 11px; letter-spacing: 0.1em;
  text-transform: uppercase; color: #8A79A8;
}

/* the feed strip — the product reads the market along the bottom */
.ns-ticker {
  position: relative; z-index: 2; overflow: hidden;
  border-top: 1px solid rgba(244,242,248,0.16);
  background: rgba(31,15,58,0.55);
}
.ns-ticker-track {
  display: flex; width: max-content; white-space: nowrap;
  animation: nsTicker 46s linear infinite;
}
.ns-ticker-track span {
  padding: 13px 0; flex: none;
  font-family: 'VCR OSD Mono', monospace; font-size: 11px; letter-spacing: 0.1em;
  text-transform: uppercase; color: #C9B8E4;
}
.ns-ticker em { font-style: normal; }
.ns-ticker em.up { color: #58D68D; }
.ns-ticker em.dn { color: #C9B8E4; }
@keyframes nsTicker { from { transform: translateX(0); } to { transform: translateX(-50%); } }
@media (prefers-reduced-motion: reduce) {
  .ns-ticker-track { animation: none; }
}

/* ============ sections ============
   Every section paints its own data-bg color — body-sync is continuity
   polish, never load-bearing (house rule since Weissmuller). */
.ns-section { padding: clamp(80px, 9vw, 130px) 0 clamp(40px, 5vw, 64px); background-color: #EFF0F3; }
.ns-section-purple { background-color: #4F2B83; }
.ns-grid { display: grid; grid-template-columns: minmax(230px, 0.8fr) 1.55fr; gap: 54px; align-items: start; }

.ns-rail { position: relative; border-top: 1px solid rgba(23,23,27,0.28); padding-top: 18px; }
.ns-rail-light { border-top-color: rgba(244,242,248,0.3); }
.ns-no { display: block; font-family: 'VCR OSD Mono', monospace; font-size: clamp(26px, 2.6vw, 38px); line-height: 1; color: #4F2B83; }
.ns-h { margin: 14px 0 0; font-weight: 400; font-size: clamp(26px, 2.4vw, 36px); line-height: 1.14; letter-spacing: -0.02em; color: #17171B; }
.ns-no-light { color: #C9B8E4; }
.ns-h-light { color: #F4F2F8; }

.ns-copy { max-width: 640px; padding-top: 18px; }
.ns-lead { margin: 0 0 22px; font-size: clamp(21px, 2vw, 26px); line-height: 1.48; color: #17171B; }
.ns-body { margin: 0; font-size: 16.5px; line-height: 1.65; color: #5C5C66; }
.ns-lead-light { color: #F4F2F8; }
.ns-body-light { color: rgba(244,242,248,0.75); }

/* ============ the brief — pull quote ============ */
.ns-brief-quote {
  margin: clamp(56px, 7vw, 90px) auto 0; max-width: 940px; padding: 0; text-align: center;
}
.ns-brief-quote p {
  margin: 0; font-weight: 400;
  font-size: clamp(30px, 4.4vw, 56px); line-height: 1.16; letter-spacing: -0.02em; color: #17171B;
}
.ns-brief-quote em { font-style: italic; color: #4F2B83; }
.ns-brief-quote footer {
  margin-top: 26px; font-family: 'VCR OSD Mono', monospace; font-size: 11px;
  letter-spacing: 0.12em; text-transform: uppercase; color: #8A8A94;
}

/* ============ captions ============ */
.ns-cap {
  display: flex; justify-content: space-between; gap: 24px; margin: 14px 0 0; padding: 0;
  font-family: 'VCR OSD Mono', monospace; font-size: 11px; letter-spacing: 0.12em;
  text-transform: uppercase; color: #8A8A94;
}
.ns-cap-light { color: rgba(244,242,248,0.55); }
.ns-cap span:first-child { white-space: nowrap; }
.ns-cap span:last-child { text-align: right; }

/* ============ screenshots — mounted flat on the product's field ============
   The sources already carry the platform's own light-gray field around
   each card, so the mount stays minimal: hairline, no padding. */
.ns-shot { margin: clamp(40px, 5vw, 64px) 0 0; }
.ns-shot img {
  display: block; width: 100%; height: auto;
  border: 1px solid rgba(23,23,27,0.12); border-radius: 4px;
  box-shadow: 0 24px 60px rgba(23,23,27,0.1);
}
.ns-shot-quiet img { box-shadow: none; }
.ns-shot-deep img { border-color: rgba(244,242,248,0.18); box-shadow: 0 32px 80px rgba(0,0,0,0.35); }
.ns-shot-pair { display: grid; grid-template-columns: 1fr 1fr; gap: clamp(18px, 2.4vw, 32px); align-items: start; }
.ns-shot-pair .ns-shot { margin-top: clamp(24px, 3vw, 40px); }

/* ============ Nº3 — the working miniature ============ */
.ns-demo {
  margin-top: clamp(48px, 6vw, 76px);
  background: #FFFFFF; border: 1px solid rgba(23,23,27,0.12); border-radius: 4px;
  box-shadow: 0 24px 60px rgba(23,23,27,0.1);
  overflow: hidden;
}
.ns-demo-bar {
  display: flex; align-items: center; gap: 12px; padding: 14px 18px;
  border-bottom: 1px solid rgba(23,23,27,0.1);
}
.ns-demo-ico { display: flex; flex: none; }
.ns-demo-title { font-size: 15px; font-weight: 500; color: #45454E; }
.ns-demo-tools { margin-left: auto; display: flex; gap: 18px; color: #B9B9C2; font-size: 14px; }
.ns-demo-terms {
  display: flex; align-items: center; gap: 8px; padding: 16px 18px 4px; flex-wrap: wrap;
}
.ns-demo-terms-label { font-size: 13px; color: #8A8A94; margin-right: 4px; }
.ns-pill {
  appearance: none; border: 0; cursor: pointer;
  background: transparent; color: #45454E;
  font-family: inherit; font-size: 13px; font-weight: 500;
  padding: 6px 12px; border-radius: 3px;
  transition: background-color 0.2s ease, color 0.2s ease;
}
.ns-pill:hover { background: rgba(23,23,27,0.06); }
.ns-pill.is-on { background: #4F2B83; color: #FFFFFF; }
.ns-demo-legend {
  display: flex; gap: 22px; padding: 12px 18px 0;
  font-size: 12.5px; font-weight: 500; color: #5C5C66;
}
.ns-demo-legend span { display: inline-flex; align-items: center; gap: 7px; }
.ns-key { display: inline-block; width: 16px; height: 3px; border-radius: 2px; }
.ns-key-iv { background: #FD3700; }
.ns-key-hv { background: #0E5FF7; }
.ns-key-e {
  width: 16px; height: 16px; border-radius: 50%; border: 1.5px solid #9B9BA4;
  color: #9B9BA4; font-size: 9px; font-weight: 700; line-height: 13px; text-align: center;
  box-sizing: border-box; font-style: normal;
}
.ns-demo-stage { position: relative; }
.ns-demo-canvas { display: block; width: 100%; height: 340px; cursor: crosshair; touch-action: pan-y; }
.ns-demo-tip {
  position: absolute; top: 0; left: 0; pointer-events: none; opacity: 0;
  transform: translate(-50%, 0);
  background: #17171B; color: #F4F2F8; border-radius: 3px;
  font-family: 'VCR OSD Mono', monospace; font-size: 10.5px; letter-spacing: 0.06em;
  padding: 7px 10px; white-space: nowrap; text-transform: uppercase;
  transition: opacity 0.15s ease;
}
.ns-demo-tip em.iv { color: #FF8C68; font-style: normal; }
.ns-demo-tip em.hv { color: #7FA9FF; font-style: normal; }
.ns-demo-foot {
  padding: 12px 18px 14px; border-top: 1px solid rgba(23,23,27,0.08);
  font-family: 'VCR OSD Mono', monospace; font-size: 10.5px; letter-spacing: 0.1em;
  text-transform: uppercase; color: #9B9BA4;
}
.ns-demo-cap { margin-top: 18px; }

/* ============ tagline ============ */
.ns-tagline { padding: clamp(120px, 14vw, 200px) 0; text-align: center; background-color: #4F2B83; }
.ns-tagline-eyebrow {
  display: block; font-family: 'VCR OSD Mono', monospace; font-size: 12px; letter-spacing: 0.2em;
  text-transform: uppercase; color: #9B8CB8; margin-bottom: 30px;
}
.ns-tagline-line {
  margin: 0 auto; max-width: 980px; font-weight: 400;
  font-size: clamp(34px, 5.4vw, 72px); line-height: 1.12; letter-spacing: -0.02em; color: #F4F2F8;
}
.ns-tagline-line em { font-style: italic; color: #FFFFFF; }
.ns-tagline-cap {
  margin: 34px 0 0; font-family: 'VCR OSD Mono', monospace; font-size: 11px; letter-spacing: 0.1em;
  text-transform: uppercase; color: #8A79A8;
}

/* ============ outro ============ */
.ns-outro { padding: clamp(110px, 13vw, 180px) 0 110px; text-align: center; background-color: #231539; overflow: hidden; }
.ns-outro-sig { max-width: 560px; margin: 0 auto; }
.ns-outro-sig svg { display: block; width: 100%; height: 60px; }
#nsOutroLine {
  stroke-dasharray: 1200; stroke-dashoffset: 1200;
  transition: stroke-dashoffset 2.2s cubic-bezier(0.33,1,0.68,1);
}
.ns-outro.is-drawn #nsOutroLine { stroke-dashoffset: 0; }
#nsOutroNoise { transition: opacity 1.6s ease 0.4s; }
.ns-outro.is-drawn #nsOutroNoise { opacity: 0.12; }
.ns-outro-line {
  margin: 56px 0 0; font-weight: 400;
  font-size: clamp(30px, 4.6vw, 58px); line-height: 1.18; letter-spacing: -0.02em; color: #F4F2F8;
}
.ns-outro-line em { font-style: italic; color: #FFFFFF; }
.ns-next { display: inline-block; margin-top: 52px; font-family: 'VCR OSD Mono', monospace; font-size: 13px; letter-spacing: 0.08em; text-transform: uppercase; color: #9B8CB8; text-decoration: none; transition: color 0.2s ease; }
.ns-next:hover { color: #FFFFFF; }

/* ============ reveal ============ */
[data-reveal] { opacity: 0.05; transform: translateY(22px); transition: opacity 0.8s cubic-bezier(0.33,1,0.68,1), transform 0.8s cubic-bezier(0.33,1,0.68,1); }
[data-reveal].is-in { opacity: 1; transform: none; }

/* ============ mobile ============ */
@media (max-width: 900px) {
  .ns-wrap { padding-left: 22px; padding-right: 22px; }
  .ns-grid { grid-template-columns: 1fr; gap: 28px; }
  .ns-meta { grid-template-columns: 1fr 1fr; gap: 22px; }
  .ns-shot-pair { grid-template-columns: 1fr; }
}
@media (max-width: 760px) {
  body { overflow-x: hidden; }
  .ns-hero { padding-top: 40px; }
  .ns-hero-top { flex-direction: column; gap: 10px; align-items: flex-start; }
  .ns-word { margin-top: 40px; }
  .ns-meta { grid-template-columns: 1fr; }
  .ns-hero-hint { display: none; }
  .ns-demo-canvas { height: 260px; }
  .ns-demo-legend { flex-wrap: wrap; gap: 12px; }
}
