/* Wisp — Aurora Dark / Living Mist */

:root {
  --surface-deep: #0A0B10;
  --surface-raised: #14161E;
  --stroke: #1F2230;
  --text: #F4F5FB;
  --muted: rgba(244, 245, 251, 0.55);
  --muted-strong: rgba(244, 245, 251, 0.72);
  --faint: rgba(244, 245, 251, 0.32);
  --cyan: #5EE6E2;
  --lilac: #9F8CFF;
  --warm: #FFB6A0;

  --radius-lg: 28px;
  --radius-md: 22px;
  --radius-sm: 14px;

  --font-display: -apple-system, BlinkMacSystemFont, "SF Pro Display", "SF Pro Text", "Inter", "Helvetica Neue", Helvetica, Arial, sans-serif;
  --font-mono: ui-monospace, "SF Mono", Menlo, Monaco, Consolas, monospace;

  --max-w: 1120px;
  --pad-x: clamp(20px, 4vw, 48px);
}

* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html, body {
  background: var(--surface-deep);
  color: var(--text);
  font-family: var(--font-display);
  font-size: 17px;
  line-height: 1.55;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  text-rendering: optimizeLegibility;
  letter-spacing: -0.005em;
}

body {
  min-height: 100vh;
  overflow-x: hidden;
  position: relative;
  /* faint grain + radial vignette for depth */
  background:
    radial-gradient(ellipse 80% 60% at 50% 30%, rgba(159, 140, 255, 0.04), transparent 60%),
    radial-gradient(ellipse 60% 50% at 80% 90%, rgba(94, 230, 226, 0.03), transparent 60%),
    var(--surface-deep);
}

/* ───────────────────────── chrome ───────────────────────── */

.site-header {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 50;
  padding: 22px var(--pad-x);
  display: flex;
  align-items: center;
  justify-content: space-between;
  background: linear-gradient(to bottom, rgba(10, 11, 16, 0.7), rgba(10, 11, 16, 0));
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
}

.brand {
  font-size: 17px;
  font-weight: 600;
  letter-spacing: -0.01em;
  color: var(--text);
  text-decoration: none;
  display: inline-flex;
  align-items: center;
  gap: 10px;
}

.brand-mark {
  width: 18px;
  height: 18px;
  border-radius: 50%;
  background: radial-gradient(circle at 30% 30%, #fff, var(--lilac) 40%, var(--cyan) 75%, transparent 95%);
  filter: blur(0.3px);
  box-shadow: 0 0 12px rgba(159, 140, 255, 0.5);
}

.nav {
  display: flex;
  align-items: center;
  gap: 28px;
  font-size: 14px;
  color: var(--muted);
}

.nav a {
  color: var(--muted);
  text-decoration: none;
  transition: color 200ms ease;
}

.nav a:hover { color: var(--text); }

.nav .sep {
  color: var(--faint);
  user-select: none;
}

/* ───────────────────────── hero / orb ───────────────────────── */

.hero {
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 120px var(--pad-x) 80px;
  position: relative;
}

.orb-stage {
  position: relative;
  width: min(680px, 90vw);
  height: 60vh;
  min-height: 420px;
  max-height: 680px;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 56px;
}

.orb-canvas {
  position: absolute;
  inset: -10%;
  width: 120%;
  height: 120%;
  pointer-events: none;
}

.orb-wrap {
  position: relative;
  width: 70%;
  aspect-ratio: 1 / 1;
  display: flex;
  align-items: center;
  justify-content: center;
  will-change: transform;
}

.blob {
  position: absolute;
  border-radius: 50%;
  filter: blur(60px);
  mix-blend-mode: screen;
  opacity: 0.92;
  will-change: transform;
}

.blob-cyan {
  width: 70%; height: 70%;
  left: 8%; top: 12%;
  background: radial-gradient(circle at 40% 40%, var(--cyan), rgba(94, 230, 226, 0.0) 70%);
  animation: drift-a 7s ease-in-out infinite alternate;
}

.blob-lilac {
  width: 78%; height: 78%;
  right: 4%; top: 20%;
  background: radial-gradient(circle at 50% 50%, var(--lilac), rgba(159, 140, 255, 0.0) 70%);
  animation: drift-b 9s ease-in-out infinite alternate;
}

.blob-warm {
  width: 62%; height: 62%;
  left: 18%; bottom: 6%;
  background: radial-gradient(circle at 60% 40%, var(--warm), rgba(255, 182, 160, 0.0) 70%);
  animation: drift-c 11s ease-in-out infinite alternate;
}

@keyframes drift-a {
  0%   { transform: translate(0, 0) scale(1); }
  100% { transform: translate(-7%, 5%) scale(1.05); }
}
@keyframes drift-b {
  0%   { transform: translate(0, 0) scale(1); }
  100% { transform: translate(6%, -4%) scale(0.96); }
}
@keyframes drift-c {
  0%   { transform: translate(0, 0) scale(1.02); }
  100% { transform: translate(4%, -6%) scale(1.08); }
}

.heart {
  position: relative;
  width: 28%;
  aspect-ratio: 1 / 1;
  border-radius: 50%;
  background: radial-gradient(circle at 50% 45%,
    #ffffff 0%,
    rgba(255, 255, 255, 0.95) 18%,
    rgba(244, 245, 251, 0.6) 38%,
    rgba(244, 245, 251, 0.15) 62%,
    transparent 80%);
  box-shadow:
    0 0 40px rgba(255, 255, 255, 0.6),
    0 0 120px rgba(159, 140, 255, 0.5),
    0 0 200px rgba(94, 230, 226, 0.35);
  animation: breathe 2.5s ease-in-out infinite;
  z-index: 2;
}

@keyframes breathe {
  0%, 100% { transform: scale(1);    opacity: 0.95; }
  50%      { transform: scale(1.08); opacity: 1; }
}

.hero-title {
  font-size: clamp(38px, 5.5vw, 64px);
  line-height: 1.05;
  font-weight: 600;
  letter-spacing: -0.025em;
  text-align: center;
  max-width: 14ch;
  margin-bottom: 22px;
  text-wrap: balance;
}

.hero-sub {
  font-size: 17px;
  line-height: 1.55;
  color: var(--muted);
  text-align: center;
  max-width: 480px;
  text-wrap: pretty;
}

/* ───────────────────────── sections ───────────────────────── */

main { position: relative; z-index: 1; }

section {
  padding: 96px var(--pad-x);
  max-width: var(--max-w);
  margin: 0 auto;
  width: 100%;
}

.eyebrow {
  font-size: 12px;
  font-weight: 500;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--faint);
  margin-bottom: 18px;
}

.section-title {
  font-size: clamp(28px, 3.4vw, 40px);
  font-weight: 600;
  letter-spacing: -0.02em;
  line-height: 1.1;
  margin-bottom: 14px;
  max-width: 18ch;
}

.section-lead {
  color: var(--muted);
  font-size: 17px;
  max-width: 56ch;
  margin-bottom: 56px;
  text-wrap: pretty;
}

/* glass cards */

.cards-3 {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 18px;
}

.card {
  background: linear-gradient(180deg, rgba(31, 34, 48, 0.5), rgba(20, 22, 30, 0.5));
  border: 1px solid var(--stroke);
  border-radius: var(--radius-md);
  padding: 28px 26px 32px;
  position: relative;
  overflow: hidden;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.03);
  transition: border-color 280ms ease, transform 280ms ease;
}

.card:hover {
  border-color: rgba(159, 140, 255, 0.25);
}

.card-num {
  font-family: var(--font-mono);
  font-size: 12px;
  color: var(--faint);
  letter-spacing: 0.04em;
  margin-bottom: 60px;
}

.card-title {
  font-size: 20px;
  font-weight: 600;
  letter-spacing: -0.015em;
  margin-bottom: 10px;
}

.card-body {
  color: var(--muted);
  font-size: 15px;
  line-height: 1.55;
  max-width: 28ch;
}

/* plainly section */

.plainly {
  display: grid;
  grid-template-columns: 1fr 1.4fr;
  gap: 64px;
  align-items: start;
}

.plainly p {
  color: var(--muted-strong);
  font-size: 19px;
  line-height: 1.6;
  text-wrap: pretty;
}

.plainly p + p {
  margin-top: 18px;
}

/* quiet grid */

.quiet-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 1px;
  background: var(--stroke);
  border: 1px solid var(--stroke);
  border-radius: var(--radius-md);
  overflow: hidden;
}

.quiet-item {
  background: var(--surface-deep);
  padding: 36px 26px;
  display: flex;
  flex-direction: column;
  gap: 14px;
  min-height: 180px;
}

.quiet-mark {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--cyan);
  box-shadow: 0 0 12px var(--cyan);
  opacity: 0.7;
}

.quiet-item:nth-child(2) .quiet-mark { background: var(--lilac); box-shadow: 0 0 12px var(--lilac); }
.quiet-item:nth-child(3) .quiet-mark { background: var(--warm); box-shadow: 0 0 12px var(--warm); }
.quiet-item:nth-child(4) .quiet-mark { background: var(--text); box-shadow: 0 0 12px rgba(244,245,251,0.5); }

.quiet-title {
  font-size: 17px;
  font-weight: 600;
  letter-spacing: -0.01em;
  margin-top: auto;
}

.quiet-body {
  color: var(--muted);
  font-size: 14px;
  line-height: 1.5;
}

/* ───────────────────────── footer ───────────────────────── */

.site-footer {
  border-top: 1px solid var(--stroke);
  padding: 28px var(--pad-x);
  margin-top: 80px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  font-size: 13px;
  color: var(--muted);
  max-width: var(--max-w);
  margin-left: auto;
  margin-right: auto;
}

.site-footer .nav a { font-size: 13px; }
.site-footer-inner {
  width: 100%;
  max-width: var(--max-w);
  margin: 0 auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
}

/* ───────────────────────── doc pages ───────────────────────── */

.doc-shell {
  min-height: 100vh;
  padding: 140px var(--pad-x) 80px;
  display: flex;
  justify-content: center;
  position: relative;
}

.doc {
  max-width: 720px;
  width: 100%;
  position: relative;
}

.doc-mark {
  position: absolute;
  top: -100px;
  right: -40px;
  width: 240px;
  height: 240px;
  pointer-events: none;
  opacity: 0.55;
  filter: blur(40px);
  z-index: 0;
}

.doc-mark::before, .doc-mark::after, .doc-mark span {
  content: "";
  position: absolute;
  border-radius: 50%;
  mix-blend-mode: screen;
}

.doc-mark::before {
  width: 60%; height: 60%; left: 0; top: 10%;
  background: radial-gradient(circle, var(--cyan), transparent 70%);
}
.doc-mark::after {
  width: 70%; height: 70%; right: 0; top: 20%;
  background: radial-gradient(circle, var(--lilac), transparent 70%);
}
.doc-mark span {
  width: 50%; height: 50%; left: 20%; bottom: 0;
  background: radial-gradient(circle, var(--warm), transparent 70%);
  display: block;
}

.doc-kicker {
  font-family: var(--font-mono);
  font-size: 12px;
  letter-spacing: 0.08em;
  color: var(--faint);
  text-transform: uppercase;
  margin-bottom: 18px;
}

.doc h1 {
  font-size: clamp(40px, 5vw, 56px);
  font-weight: 600;
  letter-spacing: -0.025em;
  line-height: 1.05;
  margin-bottom: 14px;
}

.doc .updated {
  color: var(--faint);
  font-size: 14px;
  margin-bottom: 56px;
  font-family: var(--font-mono);
}

.doc h2 {
  font-size: 22px;
  font-weight: 600;
  letter-spacing: -0.015em;
  margin: 48px 0 14px;
  color: var(--text);
}

.doc h2:first-of-type { margin-top: 0; }

.doc p, .doc li {
  font-size: 16px;
  line-height: 1.7;
  color: var(--muted-strong);
  text-wrap: pretty;
}

.doc p + p { margin-top: 14px; }

.doc ul {
  list-style: none;
  padding: 0;
  margin: 14px 0;
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.doc li {
  padding-left: 24px;
  position: relative;
}

.doc li::before {
  content: "";
  position: absolute;
  left: 4px;
  top: 12px;
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--lilac);
  box-shadow: 0 0 8px rgba(159, 140, 255, 0.5);
}

.doc a {
  color: var(--text);
  text-decoration: none;
  border-bottom: 1px solid var(--stroke);
  transition: border-color 200ms ease;
}

.doc a:hover { border-color: var(--lilac); }

.doc code {
  font-family: var(--font-mono);
  font-size: 14px;
  background: var(--surface-raised);
  border: 1px solid var(--stroke);
  border-radius: 6px;
  padding: 1px 7px;
  color: var(--text);
}

.doc-divider {
  height: 1px;
  background: var(--stroke);
  margin: 56px 0;
}

.support-note {
  border: 1px solid var(--stroke);
  background: linear-gradient(180deg, rgba(31, 34, 48, 0.4), rgba(20, 22, 30, 0.4));
  border-radius: var(--radius-md);
  padding: 28px;
  margin: 40px 0 0;
}

.support-note .mail {
  font-family: var(--font-mono);
  font-size: 15px;
  display: inline-block;
  margin-top: 14px;
  padding: 8px 14px;
  background: var(--surface-deep);
  border: 1px solid var(--stroke);
  border-radius: 10px;
  color: var(--text);
}

/* ───────────────────────── responsive ───────────────────────── */

@media (max-width: 880px) {
  .cards-3 { grid-template-columns: 1fr; }
  .plainly { grid-template-columns: 1fr; gap: 24px; }
  .quiet-grid { grid-template-columns: repeat(2, 1fr); }
  .nav { gap: 18px; }
  .nav .sep { display: none; }
  section { padding: 72px var(--pad-x); }
  .site-footer-inner { flex-direction: column; gap: 12px; align-items: flex-start; }
}

@media (max-width: 480px) {
  .quiet-grid { grid-template-columns: 1fr; }
  .nav a:nth-child(n+5) { display: none; }
  .orb-stage { height: 50vh; min-height: 340px; }
  .doc-mark { display: none; }
  .hero-title { font-size: 38px; }
}

/* respect reduced motion */
@media (prefers-reduced-motion: reduce) {
  .blob-cyan, .blob-lilac, .blob-warm, .heart { animation: none; }
}
