/* Node Modules Cleaner — site styles. The Night Workshop world from DESIGN.md. */

@font-face {
  /* Only downloaded where the system font (SF Pro) isn't available. */
  font-family: "Inter Fallback";
  src: url("assets/fonts/inter-latin-wght.woff2") format("woff2");
  font-weight: 100 900;
  font-display: swap;
}

:root {
  --orchid: #F2489C;
  --violet: #8B5CFF;
  --amber: #FFC266;
  --dusk: #1A1033;
  --ink: #0E0B1F;
  --night: #120C26;
  --text: #FFFFFF;
  --text-2: rgba(255, 255, 255, 0.72);
  --text-3: rgba(255, 255, 255, 0.54);
  --hairline: rgba(255, 255, 255, 0.10);
  --hairline-strong: rgba(255, 255, 255, 0.16);
  --link: var(--orchid);
  --accent: linear-gradient(135deg, var(--orchid) 0%, var(--violet) 100%);
  /* The same lamp, a step deeper, so white labels on buttons pass WCAG AA (4.8:1 or better). */
  --accent-button: linear-gradient(135deg, #C8358A 0%, #7448E8 100%);

  --font: -apple-system, BlinkMacSystemFont, "SF Pro", system-ui, "Inter Fallback", "Helvetica Neue", Arial, sans-serif;
  --font-mono: ui-monospace, monospace;

  --gutter: clamp(16px, 4vw, 40px);
  /* The screenshots' native width: images are never shown larger than they were captured. */
  --max: 1180px;
  --section: clamp(96px, 13vw, 168px);
  --ease-out: cubic-bezier(0.16, 1, 0.3, 1);

  color-scheme: dark;
  accent-color: var(--orchid);
}

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

html {
  -webkit-text-size-adjust: 100%;
  text-size-adjust: 100%;
  scrollbar-color: rgba(255, 255, 255, 0.22) var(--ink);
  background: var(--ink);
}

body {
  display: flex;
  flex-direction: column;
  margin: 0;
  min-height: 100vh;
  font-family: var(--font);
  font-size: 17px;
  line-height: 1.55;
  color: var(--text);
  background: linear-gradient(180deg, var(--dusk) 0, var(--night) 900px, var(--ink) 100%);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  caret-color: var(--orchid);
}

::selection { background: rgba(242, 72, 156, 0.42); color: #fff; }

::-webkit-scrollbar { width: 12px; height: 12px; }
::-webkit-scrollbar-track { background: var(--ink); }
::-webkit-scrollbar-thumb { background: rgba(255, 255, 255, 0.18); border: 3px solid var(--ink); border-radius: 999px; }
::-webkit-scrollbar-thumb:hover { background: rgba(255, 255, 255, 0.3); }

a {
  color: var(--link);
  text-decoration-line: underline;
  text-decoration-color: rgba(242, 72, 156, 0.4);
  text-decoration-thickness: 1px;
  text-underline-offset: 0.22em;
  transition: text-decoration-color 0.2s, color 0.2s;
}
a:hover { text-decoration-color: currentColor; }

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

img { display: block; max-width: 100%; height: auto; }

/* The footer stays at the bottom of short pages. */
main { flex: 1 0 auto; }

li, figcaption { text-wrap: pretty; }

h1, h2, h3 { margin: 0; font-weight: 700; text-wrap: balance; }
p { margin: 0; text-wrap: pretty; }

code {
  font-family: var(--font-mono);
  font-size: 0.86em;
  padding: 0.12em 0.42em;
  border-radius: 6px;
  background: rgba(255, 255, 255, 0.08);
  color: var(--text);
  overflow-wrap: anywhere;
}

.visually-hidden {
  position: absolute;
  width: 1px;
  height: 1px;
  margin: -1px;
  padding: 0;
  overflow: hidden;
  clip: rect(0 0 0 0);
  white-space: nowrap;
  border: 0;
}

.skip {
  position: absolute;
  left: 16px;
  top: -60px;
  z-index: 10;
  padding: 10px 16px;
  border-radius: 999px;
  background: var(--text);
  color: var(--ink);
  font-weight: 600;
  text-decoration: none;
}
.skip:focus { top: 16px; }

.wrap {
  width: 100%;
  max-width: calc(var(--max) + 2 * var(--gutter));
  margin: 0 auto;
  padding-left: var(--gutter);
  padding-right: var(--gutter);
}

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

.site-header {
  position: relative;
  z-index: 2;
}
.site-header .wrap {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  height: 76px;
}
.brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  color: var(--text);
  font-size: 15px;
  font-weight: 600;
  letter-spacing: -0.01em;
  text-decoration: none;
}
.brand img { width: 30px; height: 30px; }
.nav { display: flex; align-items: center; gap: clamp(14px, 3vw, 28px); font-size: 14px; }
.nav a { padding: 10px 2px; color: var(--text-2); text-decoration: none; transition: color 0.2s; }
.nav a.button { padding: 0 16px; }
.nav a:hover, .nav a[aria-current="page"] { color: var(--text); }
.nav a.button { color: #fff; }

/* ---------- Buttons ---------- */

.button {
  position: relative;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  height: 52px;
  padding: 0 26px;
  border-radius: 999px;
  background: var(--accent-button);
  color: #fff;
  font-size: 16px;
  font-weight: 600;
  letter-spacing: -0.005em;
  text-decoration: none;
  white-space: nowrap;
  box-shadow: 0 10px 28px -6px rgba(242, 72, 156, 0.55), inset 0 1px 0 rgba(255, 255, 255, 0.28);
  transition: transform 0.25s var(--ease-out), box-shadow 0.25s var(--ease-out), filter 0.2s;
}
.button::before {
  /* The orb's top sheen. */
  content: "";
  position: absolute;
  inset: 1px 1px 50% 1px;
  border-radius: 999px 999px 0 0 / 999px 999px 0 0;
  background: linear-gradient(rgba(255, 255, 255, 0.14), rgba(255, 255, 255, 0));
  pointer-events: none;
}
.button:hover {
  transform: translateY(-1px);
  box-shadow: 0 16px 36px -8px rgba(242, 72, 156, 0.62), inset 0 1px 0 rgba(255, 255, 255, 0.3);
  filter: brightness(1.05);
}
.button:active { transform: translateY(0) scale(0.98); filter: brightness(0.96); }
.button:focus-visible { outline-offset: 4px; border-radius: 999px; }
.button svg { width: 18px; height: 18px; flex: none; }
.button-small { height: 36px; padding: 0 16px; font-size: 14px; box-shadow: 0 6px 16px -6px rgba(242, 72, 156, 0.55), inset 0 1px 0 rgba(255, 255, 255, 0.28); }
.button-small::before { display: none; }

.fine { font-size: 14px; color: var(--text-3); text-wrap: balance; }

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

.hero {
  position: relative;
  isolation: isolate;
  margin-top: -76px;
  padding-top: calc(76px + clamp(48px, 9vw, 112px));
  overflow: hidden;
}
.hero-glow {
  position: absolute;
  inset: 0;
  z-index: -1;
  overflow: hidden;
  pointer-events: none;
}
/* The room's lamps. Soft radial gradients drifted with transform only, so the GPU
   composites them without repainting and scrolling stays smooth. */
.glow {
  position: absolute;
  border-radius: 50%;
  will-change: transform;
  backface-visibility: hidden;
}
.glow-orchid {
  left: -18%;
  top: -38%;
  width: min(1200px, 130vw);
  aspect-ratio: 1.2;
  background: radial-gradient(closest-side, rgba(242, 72, 156, 0.44), rgba(242, 72, 156, 0.14) 55%, rgba(242, 72, 156, 0));
  animation: drift-orchid 24s ease-in-out infinite alternate;
}
.glow-violet {
  right: -26%;
  top: 30%;
  width: min(1300px, 140vw);
  aspect-ratio: 1.15;
  background: radial-gradient(closest-side, rgba(139, 92, 255, 0.40), rgba(139, 92, 255, 0.12) 55%, rgba(139, 92, 255, 0));
  animation: drift-violet 30s ease-in-out infinite alternate;
}
.glow-center {
  left: 28%;
  top: 34%;
  width: min(820px, 100vw);
  aspect-ratio: 1.4;
  background: radial-gradient(closest-side, rgba(242, 72, 156, 0.16), rgba(242, 72, 156, 0));
  animation: drift-center 20s ease-in-out infinite alternate;
}
@keyframes drift-orchid {
  to { transform: translate3d(14vw, 10vh, 0) scale(1.12); }
}
@keyframes drift-violet {
  to { transform: translate3d(-16vw, -14vh, 0) scale(1.18); }
}
@keyframes drift-center {
  0% { transform: translate3d(-10vw, 4vh, 0) scale(0.9); opacity: 0.6; }
  100% { transform: translate3d(12vw, -6vh, 0) scale(1.1); opacity: 1; }
}
.hero::after {
  /* Settles the lit room into the page below. */
  content: "";
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  height: 220px;
  z-index: -1;
  background: linear-gradient(rgba(14, 11, 31, 0), var(--ink));
}
.hero-copy {
  max-width: var(--max);
  margin: 0 auto;
  text-align: center;
}
.hero h1 {
  font-size: clamp(40px, 6vw, 72px);
  line-height: 1.02;
  letter-spacing: -0.038em;
}
/* The second line steps back in tone, so the promise reads as one sentence with a turn. */
.h1-soft { display: block; color: rgba(255, 255, 255, 0.58); }
.hero .lede {
  margin: 28px auto 0;
  max-width: 620px;
  font-size: clamp(18px, 2vw, 21px);
  line-height: 1.5;
  color: var(--text-2);
}
.hero .cta-row { justify-content: center; margin-top: 40px; }
.cta-fine { margin-top: 16px; }
.shot-caption { margin-top: 18px; text-align: center; font-size: 13px; color: var(--text-2); }
.cta-row {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 14px 22px;
  margin-top: 36px;
}

.hero-window {
  position: relative;
  margin: clamp(56px, 8vw, 88px) auto 0;
  padding-bottom: clamp(80px, 10vw, 128px);
}
.hero-window::before {
  /* The lamp: light pooling under the lit window. */
  content: "";
  position: absolute;
  left: 8%;
  right: 8%;
  top: 18%;
  bottom: 10%;
  z-index: -1;
  background: radial-gradient(closest-side, rgba(242, 72, 156, 0.26), rgba(139, 92, 255, 0.12) 55%, transparent);
}

.window {
  border-radius: 12px;
  overflow: hidden;
  background: var(--dusk);
  box-shadow:
    0 0 0 1px rgba(255, 255, 255, 0.12),
    0 2px 6px rgba(0, 0, 0, 0.3),
    0 40px 90px -20px rgba(0, 0, 0, 0.75);
}
.window img { width: 100%; }

@media (prefers-reduced-motion: no-preference) {
  .js .hero-window .window {
    animation: window-rise 1.4s var(--ease-out) 0.15s both;
  }
}
@keyframes window-rise {
  from { transform: translateY(40px) scale(0.97); }
  to { transform: none; }
}

/* ---------- Sections ---------- */

/* Every content section is a block on one rhythm and one grid: a hairline above,
   equal padding, the heading on the left and its content starting on the same line at right. */
.block {
  padding-top: clamp(80px, 10vw, 128px);
  padding-bottom: clamp(80px, 10vw, 128px);
  border-top: 1px solid var(--hairline);
}
.split {
  display: grid;
  grid-template-columns: minmax(0, 5fr) minmax(0, 6fr);
  gap: 28px clamp(40px, 6vw, 96px);
  align-items: start;
}
.section-title {
  font-size: clamp(32px, 4.6vw, 52px);
  line-height: 1.06;
  letter-spacing: -0.03em;
}
.section-text {
  margin-top: 20px;
  max-width: 34em;
  font-size: 18px;
  color: var(--text-2);
}
.section-text + .section-text { margin-top: 14px; }

/* A Finder-style listing of one example project, set as text. */
.tree {
  margin: 0;
  padding: 0;
  list-style: none;
  font-size: 15px;
  font-variant-numeric: tabular-nums;
}
.tree li {
  display: grid;
  grid-template-columns: 22px minmax(0, 1fr) auto;
  align-items: center;
  gap: 12px;
  min-height: 52px;
  padding: 0 4px;
  border-bottom: 1px solid var(--hairline);
}
.tree li:first-child { border-top: 1px solid var(--hairline); }
.split > figure { margin: 0; }
.tree .indent { padding-left: 34px; }
.tree svg { width: 20px; height: 20px; color: var(--text-3); }
.tree .name { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.tree .size { color: var(--text-2); text-align: right; }
.tree .is-heavy .name { font-weight: 600; }
.tree .is-heavy svg { color: var(--orchid); }
.tree .is-heavy .size { color: var(--amber); font-weight: 600; }
.tree .bar {
  grid-column: 2 / 4;
  height: 4px;
  margin: -8px 0 14px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.08);
  overflow: hidden;
}
.tree .bar span { display: block; height: 100%; border-radius: inherit; background: var(--amber); }
.tree-caption { margin-top: 14px; font-size: 13px; color: var(--text-3); }

/* Feature blocks: the split header, then the real screen at full width. */
.feature-head { margin-bottom: clamp(40px, 5vw, 64px); }
/* Body copy in the right column starts level with the heading's cap height. */
.split > div > .section-text:first-child,
.feature-head .section-text { margin-top: 8px; }
.feature-points {
  margin: 22px 0 0;
  padding: 0;
  list-style: none;
  display: grid;
  gap: 10px;
  font-size: 16px;
  color: var(--text-2);
}
.feature-points li { display: grid; grid-template-columns: 22px 1fr; gap: 10px; align-items: start; }
.feature-points svg { width: 18px; height: 18px; margin-top: 3px; color: var(--orchid); }

/* Privacy: three plain facts on a hairline. */
/* Privacy: three equal cards under the section header. */
.privacy-head { margin-bottom: clamp(40px, 5vw, 64px); }
.cards {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 20px;
  margin: 0;
  padding: 0;
  list-style: none;
}
.card {
  display: flex;
  flex-direction: column;
  padding: 32px 30px 34px;
  border-radius: 16px;
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.055), rgba(255, 255, 255, 0.025));
  border: 1px solid rgba(255, 255, 255, 0.10);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.06);
}
.card svg {
  width: 26px;
  height: 26px;
  color: var(--text);
}
.card h3 { margin-top: 24px; font-size: 20px; letter-spacing: -0.015em; }
.card p { margin-top: 8px; font-size: 16px; line-height: 1.55; color: var(--text-2); }

/* Home FAQ: the heading stays in view beside a long list. */
.faq-home .section-title { position: sticky; top: 32px; }
.faq summary h3 { margin: 0; font-size: 18px; font-weight: 600; letter-spacing: -0.01em; text-wrap: balance; }
.faq-home details p { max-width: 68ch; color: var(--text-2); }

/* Finale: the result you earned, then the action. */
.finale {
  position: relative;
  isolation: isolate;
  padding-top: clamp(48px, 6vw, 80px);
  padding-bottom: var(--section);
  text-align: center;
}
.finale::before {
  content: "";
  position: absolute;
  left: 50%;
  top: 46%;
  width: min(900px, 120vw);
  height: 520px;
  z-index: -1;
  transform: translate(-50%, -50%);
  background: radial-gradient(closest-side, rgba(242, 72, 156, 0.20), rgba(139, 92, 255, 0.10) 60%, transparent);
}
.finale-icon {
  width: clamp(120px, 14vw, 160px);
  height: auto;
  margin: 0 auto;
  filter: drop-shadow(0 18px 36px rgba(242, 72, 156, 0.32));
}
.finale-title {
  margin-top: 32px;
  font-size: clamp(36px, 6vw, 68px);
  line-height: 1.02;
  letter-spacing: -0.035em;
}
.finale-note { margin: 18px auto 0; max-width: 30em; font-size: clamp(17px, 2vw, 20px); color: var(--text-2); }
.finale .cta-row { justify-content: center; margin-top: 40px; }
.finale-fine { margin-top: 16px; }

/* ---------- Documents (Guide, Support, Privacy) ---------- */

/* A full-width header lit like the home hero, then contents beside the article. */
.doc-hero {
  position: relative;
  isolation: isolate;
  margin-top: -76px;
  padding-top: calc(76px + clamp(56px, 8vw, 104px));
  padding-bottom: clamp(48px, 6vw, 80px);
  overflow: hidden;
  border-bottom: 1px solid var(--hairline);
}
.doc-hero::before {
  content: "";
  position: absolute;
  z-index: -1;
  left: -12%;
  top: -60%;
  width: min(1100px, 120vw);
  aspect-ratio: 1.3;
  background: radial-gradient(closest-side, rgba(242, 72, 156, 0.30), rgba(242, 72, 156, 0.08) 55%, rgba(242, 72, 156, 0));
}
.doc-hero::after {
  content: "";
  position: absolute;
  z-index: -1;
  right: -18%;
  top: -40%;
  width: min(1000px, 110vw);
  aspect-ratio: 1.2;
  background: radial-gradient(closest-side, rgba(139, 92, 255, 0.22), rgba(139, 92, 255, 0.06) 55%, rgba(139, 92, 255, 0));
}
.doc-hero h1 {
  max-width: 18ch;
  font-size: clamp(40px, 6vw, 72px);
  line-height: 1.02;
  letter-spacing: -0.038em;
}
.doc-hero .intro {
  margin-top: 24px;
  max-width: 680px;
  font-size: clamp(18px, 1.9vw, 21px);
  line-height: 1.5;
  color: var(--text-2);
}
.doc-hero .updated { margin-top: 20px; font-size: 14px; color: var(--text-3); }
/* Over the header glow, links read as white with the orchid underline. */
.doc-hero a { color: var(--text); text-decoration-color: var(--orchid); }

.doc-layout {
  display: grid;
  grid-template-columns: 280px minmax(0, 680px);
  justify-content: space-between;
  gap: clamp(40px, 6vw, 96px);
  padding-top: clamp(48px, 6vw, 80px);
  padding-bottom: var(--section);
}

.toc { position: sticky; top: 32px; align-self: start; }
.toc-title { font-size: 13px; font-weight: 600; color: var(--text); }
.toc ul { margin: 14px 0 0; padding: 0; list-style: none; border-left: 1px solid var(--hairline); }
.toc li + li { margin-top: 2px; }
.toc a {
  display: block;
  margin-left: -1px;
  padding: 7px 0 7px 16px;
  border-left: 1px solid transparent;
  font-size: 14px;
  line-height: 1.4;
  color: var(--text-3);
  text-decoration: none;
  transition: color 0.2s, border-color 0.2s;
}
.toc a:hover { color: var(--text); border-left-color: var(--orchid); }

.doc-body { font-size: 18px; line-height: 1.65; }
.doc-body > :first-child { margin-top: 0; }
.doc-body h2 {
  margin-top: 64px;
  font-size: 28px;
  line-height: 1.2;
  letter-spacing: -0.025em;
  scroll-margin-top: 32px;
}
.doc-body h2 + p, .doc-body h2 + ol, .doc-body h2 + ul, .doc-body h2 + .faq, .doc-body h2 + .table-wrap { margin-top: 16px; }
.doc-body p + p { margin-top: 16px; }
.doc-body p, .doc-body li { color: var(--text-2); }
.doc-body strong { color: var(--text); font-weight: 600; }
.doc-body ol, .doc-body ul { margin-bottom: 0; padding-left: 1.3em; }
.doc-body li + li { margin-top: 10px; }
.doc-body li::marker { color: var(--text-3); }
.doc-body ol + p, .doc-body ul + p { margin-top: 18px; }
.doc-body pre + p { margin-top: 18px; }
.doc-body .faq summary { font-size: 17px; }
.doc-body .faq details p { font-size: 17px; }
.doc-body table { font-size: 16px; }

.faq { border-top: 1px solid var(--hairline); }
.faq details { border-bottom: 1px solid var(--hairline); }
.faq summary {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 20px 0;
  cursor: pointer;
  list-style: none;
  font-weight: 600;
  color: var(--text);
}
.faq summary::-webkit-details-marker { display: none; }
.faq summary svg { width: 18px; height: 18px; flex: none; color: var(--text-3); transition: transform 0.3s var(--ease-out); }
.faq details[open] summary svg { transform: rotate(45deg); }
.faq summary:hover svg { color: var(--text); }
.faq details p { padding-bottom: 22px; margin-top: -4px; }

.contact-card {
  margin-top: 72px;
  padding: 36px 36px 38px;
  border-radius: 16px;
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.055), rgba(255, 255, 255, 0.025));
  border: 1px solid rgba(255, 255, 255, 0.10);
}
.doc-body .contact-card h2 { margin-top: 0; font-size: 24px; }
.contact-card p { margin-top: 10px; color: var(--text-2); }
.contact-card .button { margin-top: 24px; }

pre {
  margin: 16px 0 0;
  padding: 16px 18px;
  overflow-x: auto;
  border-radius: 9px;
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid var(--hairline);
}
pre code { padding: 0; background: none; font-size: 14px; line-height: 1.6; overflow-wrap: normal; white-space: pre; }
.doc pre + p { margin-top: 16px; }

.table-wrap { margin-top: 18px; overflow-x: auto; }
table { width: 100%; min-width: 560px; border-collapse: collapse; font-size: 15px; font-variant-numeric: tabular-nums; }
th, td { padding: 14px 12px 14px 0; text-align: left; vertical-align: top; border-bottom: 1px solid var(--hairline); }
thead th { color: var(--text); font-weight: 600; border-bottom-color: var(--hairline-strong); }
tbody th { color: var(--text); font-weight: 500; }
td { color: var(--text-2); }

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

.site-footer { border-top: 1px solid var(--hairline); }
.site-footer .wrap {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 12px 24px;
  padding-top: 32px;
  padding-bottom: 40px;
  font-size: 14px;
  color: var(--text-3);
}
.site-footer nav { display: flex; flex-wrap: wrap; gap: 8px 22px; }
.site-footer a { padding: 6px 0; color: var(--text-2); text-decoration: none; }
.site-footer a:hover { color: var(--text); }

/* ---------- Small screens ---------- */

@media (max-width: 860px) {
  .split { grid-template-columns: minmax(0, 1fr); }
  .doc-layout { grid-template-columns: minmax(0, 1fr); }
  .toc { display: none; }
  .cards { grid-template-columns: minmax(0, 1fr); gap: 14px; }
  .faq-home .section-title { position: static; }
}

@media (max-width: 560px) {
  body { font-size: 16px; }
  .site-header .wrap { height: 64px; }
  .hero { margin-top: -64px; padding-top: calc(64px + 40px); }
  .doc-hero { margin-top: -64px; padding-top: calc(64px + 40px); }
  .doc-body { font-size: 17px; }
  .doc-body h2 { margin-top: 48px; font-size: 24px; }
  .contact-card { padding: 28px 24px 30px; }
  .nav .button-small { display: none; }
  .cta-row .button { width: 100%; }
  .hero .cta-row .button, .finale .cta-row .button { width: auto; min-width: 240px; }
  .section-text { font-size: 17px; }
  .window { border-radius: 8px; }
  .tree li { min-height: 48px; font-size: 14px; }
  .tree .indent { padding-left: 22px; }
}

@media (prefers-reduced-motion: reduce) {
  /* Stop movement; keep the quick color feedback on hover and focus. */
  .glow, .js .hero-window .window { animation: none !important; }
  .button, .button:hover, .button:active { transform: none; }
  .faq summary svg { transition: none; }
}
