/* Wuxia for WordPress. The theme's own world: black, Netflix red, the ribbon
   W, Kantumruy Pro. Tokens mirror wuxia-theme/tokens.css. */

@font-face {
  font-family: "Kantumruy Pro";
  src: url("fonts/KantumruyPro-Variable.ttf") format("truetype");
  font-weight: 100 900;
  font-display: swap;
}

:root {
  --bg: #000;
  --surface: #141414;
  --surface-2: #1c1c1c;
  --line: rgba(255, 255, 255, 0.1);
  --text: #f5f5f1;
  --muted: #a3a3a3;
  --red: #e50914;
  --red-deep: #b20710;
  --red-text: #ff4d55;
  --radius: 10px;
  --font: "Kantumruy Pro", system-ui, -apple-system, "Segoe UI", sans-serif;
  --mono: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  --ease-out: cubic-bezier(0.16, 1, 0.3, 1);
  color-scheme: dark;
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-padding-top: 76px; scrollbar-color: #3a3a3a transparent; }
body { margin: 0; background: var(--bg); color: var(--text); font: 400 17px/1.65 var(--font); -webkit-font-smoothing: antialiased; }
::selection { background: rgba(229, 9, 20, 0.45); color: #fff; }
:focus-visible { outline: 2px solid #fff; outline-offset: 3px; border-radius: 4px; }
a { color: inherit; text-underline-offset: 4px; }
img { display: block; max-width: 100%; height: auto; }
h1, h2, h3 { text-wrap: balance; margin: 0; }
p { text-wrap: pretty; }
code, kbd { font-family: var(--mono); font-size: 0.86em; }
.tabular { font-variant-numeric: tabular-nums; }

.wrap { width: 100%; max-width: 1200px; margin: 0 auto; padding: 0 20px; }
@media (min-width: 900px) { .wrap { padding: 0 40px; } }

/* ---------- header ---------- */
.top {
  position: sticky; top: 0; z-index: 20;
  background: linear-gradient(to bottom, rgba(0, 0, 0, 0.92), rgba(0, 0, 0, 0.72));
  backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--line);
}
.top .wrap { display: flex; align-items: center; gap: 28px; height: 64px; }
.brand { display: inline-flex; align-items: center; gap: 10px; text-decoration: none; font-weight: 700; letter-spacing: 0.02em; }
.brand img { width: 34px; height: 26px; }
.brand span { font-size: 15px; }
.brand small { font-weight: 400; color: var(--muted); letter-spacing: 0; }
.menu { display: flex; gap: 22px; margin-left: auto; font-size: 15px; }
.menu a { color: var(--muted); text-decoration: none; transition: color 150ms; }
.menu a:hover { color: var(--text); }
@media (max-width: 720px) { .menu .wide { display: none; } .brand small { display: none; } }

/* ---------- buttons ---------- */
.btn {
  display: inline-flex; align-items: center; gap: 10px;
  min-height: 48px; padding: 0 22px; border-radius: 6px;
  font: 700 16px/1 var(--font); text-decoration: none; white-space: nowrap;
  border: 1px solid transparent; transition: background-color 150ms, border-color 150ms, transform 150ms var(--ease-out);
}
.btn:active { transform: scale(0.98); }
.btn svg { width: 20px; height: 20px; flex: none; }
.btn-red { background: var(--red); color: #fff; box-shadow: 0 10px 30px -12px rgba(229, 9, 20, 0.7); }
.btn-red:hover { background: var(--red-deep); }
.btn-white { background: #fff; color: #000; }
.btn-white:hover { background: #d9d9d9; }
.btn-ghost { background: rgba(109, 109, 110, 0.35); color: #fff; }
.btn-ghost:hover { background: rgba(109, 109, 110, 0.55); }
.btn small { font-weight: 400; opacity: 0.8; font-size: 13px; }
@media (max-width: 480px) { .downloads .btn { flex: 1 1 100%; justify-content: center; } .btn small { display: none; } }
@media (max-width: 480px) { .steps li { grid-template-columns: 36px minmax(0, 1fr); padding: 18px; } .steps li::before { width: 36px; height: 36px; font-size: 16px; } }

/* ---------- hero ---------- */
.hero { position: relative; overflow: hidden; padding: 64px 0 40px; }
.hero::before {
  content: ""; position: absolute; inset: -20% -10% auto 30%; height: 90%;
  background: radial-gradient(closest-side, rgba(229, 9, 20, 0.28), transparent 70%);
  pointer-events: none;
}
.hero .wrap { position: relative; display: grid; gap: 48px; align-items: center; }
@media (min-width: 1000px) {
  .hero { padding: 96px 0 72px; }
  .hero .wrap { grid-template-columns: minmax(0, 5fr) minmax(0, 7fr); }
}
.hero h1 { font-size: clamp(38px, 4.6vw, 60px); line-height: 1.02; letter-spacing: -0.025em; font-weight: 800; margin-bottom: 20px; }
.hero h1 em { font-style: normal; color: var(--red); }
.lede { font-size: 19px; color: #d2d2d2; max-width: 44ch; margin: 0 0 32px; }
.downloads { display: flex; flex-wrap: wrap; gap: 12px; margin-bottom: 18px; }
.facts { display: flex; flex-wrap: wrap; gap: 8px; padding: 0; margin: 0; list-style: none; color: var(--muted); font-size: 13px; }
.facts li { padding: 2px 10px; border: 1px solid var(--line); border-radius: 999px; }

/* The product, framed: a laptop screen with a phone in front of it. */
.stage { position: relative; padding-bottom: 8%; }
.screen {
  border-radius: 12px; overflow: hidden; border: 1px solid #2a2a2a; background: #000;
  box-shadow: 0 40px 80px -30px rgba(0, 0, 0, 0.9), 0 0 0 6px #111;
}
.screen img { width: 100%; aspect-ratio: 16 / 10; object-fit: cover; object-position: top; }
.phone {
  position: absolute; right: -2%; bottom: 0; width: 27%;
  border-radius: 26px; overflow: hidden; border: 6px solid #1a1a1a; background: #000;
  box-shadow: 0 30px 60px -20px rgba(0, 0, 0, 0.95);
}
.phone img { width: 100%; aspect-ratio: 390 / 844; object-fit: cover; object-position: top; }
@media (prefers-reduced-motion: no-preference) {
  .stage .screen { animation: rise 900ms var(--ease-out) both; }
  .stage .phone { animation: rise 900ms 180ms var(--ease-out) both; }
  @keyframes rise { from { opacity: 0; transform: translateY(24px); } to { opacity: 1; transform: none; } }
}

/* ---------- sections ---------- */
.section { padding: 80px 0; border-top: 1px solid var(--line); }
.section h2 { font-size: clamp(30px, 3.6vw, 44px); line-height: 1.1; letter-spacing: -0.02em; font-weight: 800; margin-bottom: 14px; }
.section .intro { color: var(--muted); font-size: 18px; max-width: 60ch; margin: 0 0 44px; }

/* What you download: two packages, side by side, as lists. */
.box { display: grid; gap: 1px; background: var(--line); border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden; }
@media (min-width: 860px) { .box { grid-template-columns: 1fr 1fr; } }
.pkg { background: var(--surface); padding: 32px; }
.pkg h3 { display: flex; align-items: baseline; gap: 12px; font-size: 22px; font-weight: 700; margin-bottom: 4px; }
.pkg h3 code { font-size: 13px; color: var(--muted); font-weight: 400; }
.pkg > p { color: var(--muted); margin: 0 0 18px; }
.pkg ul { margin: 0 0 24px; padding: 0; list-style: none; display: grid; gap: 10px; }
.pkg li { position: relative; padding-left: 24px; }
.pkg li::before { content: ""; position: absolute; left: 0; top: 0.72em; width: 10px; height: 2px; background: var(--red); }

/* Feature rows: text beside a real screenshot, alternating. */
.feature { display: grid; gap: 36px; align-items: center; padding: 48px 0; }
.feature + .feature { border-top: 1px solid var(--line); }
@media (min-width: 900px) {
  .feature { grid-template-columns: minmax(0, 5fr) minmax(0, 7fr); gap: 64px; }
  .feature.flip > :first-child { order: 2; }
}
.feature h3 { font-size: 28px; line-height: 1.15; font-weight: 800; letter-spacing: -0.01em; margin-bottom: 12px; }
.feature p { color: #cfcfcf; margin: 0 0 12px; }
.feature .shot { border-radius: var(--radius); overflow: hidden; border: 1px solid #262626; background: var(--surface); box-shadow: 0 30px 60px -30px rgba(0, 0, 0, 0.9); }
.feature .shot img { width: 100%; }
.feature .shot.tall { max-width: 340px; margin: 0 auto; border-radius: 24px; }

/* Install: the order matters, so the steps are numbered. */
.steps { list-style: none; margin: 0; padding: 0; counter-reset: step; display: grid; gap: 14px; max-width: 820px; }
.steps li {
  counter-increment: step; position: relative;
  display: grid; grid-template-columns: 44px minmax(0, 1fr); gap: 4px 18px;
  padding: 22px 24px; background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius);
}
.steps li::before {
  content: counter(step); grid-row: span 2;
  display: grid; place-items: center; width: 44px; height: 44px; border-radius: 50%;
  background: var(--red); color: #fff; font-weight: 800; font-size: 18px;
}
.steps b { font-size: 18px; }
.steps p { margin: 0; color: #cfcfcf; }
.path { display: inline; padding: 1px 8px; border-radius: 5px; background: var(--surface-2); border: 1px solid #2c2c2c; font-size: 0.9em; -webkit-box-decoration-break: clone; box-decoration-break: clone; line-height: 1.9; }
.note { margin-top: 22px; color: var(--muted); font-size: 15px; max-width: 820px; }
.note code { color: #ddd; }

/* Requirements */
.reqs { width: 100%; max-width: 820px; border-collapse: collapse; font-size: 16px; }
.reqs th, .reqs td { text-align: left; padding: 14px 0; border-bottom: 1px solid var(--line); vertical-align: top; }
.reqs th { width: 34%; color: var(--muted); font-weight: 400; padding-right: 24px; }

/* FAQ */
.faq { max-width: 820px; border-top: 1px solid var(--line); }
.faq details { border-bottom: 1px solid var(--line); }
.faq summary { display: flex; justify-content: space-between; gap: 20px; padding: 20px 0; font-size: 18px; font-weight: 700; cursor: pointer; list-style: none; }
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after { content: "+"; color: var(--muted); font-weight: 400; font-size: 24px; line-height: 1; transition: transform 200ms var(--ease-out); }
.faq details[open] summary::after { transform: rotate(45deg); }
.faq .a { padding: 0 0 22px; color: #cfcfcf; max-width: 68ch; }
.faq .a p { margin: 0 0 10px; }

/* Final call */
.final { padding: 88px 0 96px; border-top: 1px solid var(--line); text-align: center; background: radial-gradient(60% 80% at 50% 100%, rgba(229, 9, 20, 0.2), transparent 70%); }
.final h2 { font-size: clamp(30px, 4vw, 48px); font-weight: 800; letter-spacing: -0.02em; margin-bottom: 26px; }
.final .downloads { justify-content: center; }

footer { border-top: 1px solid var(--line); padding: 28px 0 40px; color: var(--muted); font-size: 14px; }
footer .wrap { display: flex; flex-wrap: wrap; gap: 12px 28px; justify-content: space-between; }
footer nav { display: flex; flex-wrap: wrap; gap: 20px; }
footer a { text-decoration: none; }
footer a:hover { color: var(--text); }

/* ---------- logo intro: the theme's BrandIntro, by CSS alone ----------
   Strokes draw on in order (170 ms apart, 360 ms each) while the mark
   settles from 0.94; a red glow blooms at 600 ms; the wordmark rises at
   1000 ms; the layer fades at 1600 ms. A click or key skips it. */
.brand-intro { display: none; }
.intro-play .brand-intro {
  position: fixed; inset: 0; z-index: 100;
  display: grid; place-items: center; background: #000; cursor: pointer;
  animation: intro-out 260ms cubic-bezier(0.2, 0, 0, 1) 1600ms forwards;
}
.intro-play.intro-skip .brand-intro { animation: intro-out 200ms cubic-bezier(0.2, 0, 0, 1) forwards; }
@keyframes intro-out { to { opacity: 0; visibility: hidden; } }
.bi-stage { position: relative; display: flex; flex-direction: column; align-items: center; }
.bi-mark { height: 152px; width: auto; transform: scale(0.94); animation: bi-settle 1000ms var(--ease-out) forwards; }
.bi-mark .s { opacity: 0; animation: 360ms var(--ease-out) forwards; }
.bi-mark .s1 { clip-path: inset(0 0 100% 0); animation-name: bi-down; animation-delay: 0ms; }
.bi-mark .s2 { clip-path: inset(100% 0 0 0); animation-name: bi-up; animation-delay: 170ms; }
.bi-mark .s3 { clip-path: inset(0 0 100% 0); animation-name: bi-down; animation-delay: 340ms; }
.bi-mark .s4 { clip-path: inset(100% 0 0 0); animation-name: bi-up; animation-delay: 510ms; }
.bi-glow {
  position: absolute; inset: -40% -60%; border-radius: 50%; pointer-events: none;
  background: radial-gradient(closest-side, rgba(229, 9, 20, 0.55), rgba(229, 9, 20, 0.16) 60%, transparent);
  opacity: 0; animation: bi-bloom 760ms var(--ease-out) 600ms forwards;
}
.bi-word {
  position: relative; margin-top: 18px; padding-left: 0.28em;
  color: var(--red); font-size: 24px; font-weight: 700; letter-spacing: 0.28em;
  opacity: 0; transform: translateY(14px);
  animation: bi-rise 400ms var(--ease-out) 1000ms forwards;
}
@keyframes bi-down { from { opacity: 1; clip-path: inset(0 0 100% 0); } to { opacity: 1; clip-path: inset(0); } }
@keyframes bi-up { from { opacity: 1; clip-path: inset(100% 0 0 0); } to { opacity: 1; clip-path: inset(0); } }
@keyframes bi-settle { to { transform: scale(1); } }
@keyframes bi-bloom { 0% { opacity: 0; } 35% { opacity: 1; } 100% { opacity: 0.35; } }
@keyframes bi-rise { to { opacity: 1; transform: none; } }
@media (prefers-reduced-motion: reduce) {
  /* The intro becomes the finished mark, held half a second. */
  .bi-mark, .bi-word { animation: none; opacity: 1; transform: none; }
  .bi-mark .s { animation: none; opacity: 1; clip-path: none; }
  .bi-glow { display: none; }
  .intro-play .brand-intro { animation-delay: 500ms; }
}

/* ---------- trusted by: the sites running Wuxia ----------
   A quiet band under the hero: the label, the logos at one height, and how to
   join. Logos show in full colour; they are the proof. */
.trusted { padding: 36px 0 44px; border-top: 1px solid var(--line); text-align: center; }
.trusted-label { margin: 0 0 18px; color: var(--muted); font-size: 13px; font-weight: 700; letter-spacing: 0.14em; text-transform: uppercase; }
.trusted-sites { display: flex; flex-wrap: wrap; justify-content: center; align-items: center; gap: 24px 56px; margin: 0 0 20px; padding: 0; list-style: none; }
.trusted-sites a { display: block; padding: 8px; border-radius: 8px; transition: opacity 150ms, transform 150ms var(--ease-out); }
.trusted-sites a:hover { transform: translateY(-2px); }
.trusted-sites a:focus-visible { outline: 2px solid var(--red); outline-offset: 4px; }
.trusted-sites img { height: 34px; width: auto; }
.trusted-cta { margin: 0 auto; max-width: 56ch; color: var(--muted); font-size: 15px; }
.trusted-cta a { color: var(--text); }

/* ---------- deploy.html: the deployment guide ----------
   A long page read top to bottom with a terminal open beside it: a table of
   contents that stays in view on wide screens, commands in copyable blocks,
   and the section numbers the guide refers to. */
.menu a[aria-current="page"] { color: var(--text); }
.doc-hero { padding: 64px 0 36px; background: radial-gradient(50% 90% at 0% 0%, rgba(229, 9, 20, 0.16), transparent 70%); }
.doc-hero h1 { font-size: clamp(34px, 4.4vw, 54px); line-height: 1.05; letter-spacing: -0.025em; font-weight: 800; max-width: 18ch; margin-bottom: 18px; }
.doc-hero .lede { max-width: 58ch; margin-bottom: 24px; }
.eyebrow { margin: 0 0 12px; color: var(--red-text); font-size: 14px; font-weight: 700; letter-spacing: 0.08em; text-transform: uppercase; }

.doc { display: grid; gap: 32px; padding-bottom: 80px; }
.toc { border: 1px solid var(--line); border-radius: var(--radius); padding: 18px 20px; background: var(--surface); }
.toc p { margin: 0 0 8px; color: var(--muted); font-size: 13px; font-weight: 700; letter-spacing: 0.06em; text-transform: uppercase; }
.toc ol { margin: 0; padding: 0; list-style: none; counter-reset: toc; display: grid; gap: 2px; }
.toc li { counter-increment: toc; }
.toc a { display: flex; gap: 10px; padding: 7px 10px; margin: 0 -10px; border-radius: 6px; color: var(--muted); text-decoration: none; font-size: 15px; line-height: 1.35; transition: color 150ms, background-color 150ms; }
.toc a::before { content: counter(toc); flex: none; width: 1.2em; color: #666; font-variant-numeric: tabular-nums; }
.toc a:hover { color: var(--text); }
.toc a.on { color: var(--text); background: var(--surface-2); }
.toc a.on::before { color: var(--red-text); }
@media (min-width: 1000px) {
  .doc { grid-template-columns: 240px minmax(0, 1fr); gap: 56px; align-items: start; }
  .toc { position: sticky; top: 88px; padding: 0; border: 0; background: none; }
}

.doc-body { min-width: 0; max-width: 860px; }
.doc-sec { padding: 40px 0; border-top: 1px solid var(--line); }
.doc-sec:first-child { border-top: 0; padding-top: 8px; }
.doc-sec h2 { display: flex; flex-wrap: wrap; align-items: center; gap: 12px; font-size: clamp(26px, 3vw, 34px); line-height: 1.15; letter-spacing: -0.02em; font-weight: 800; margin-bottom: 16px; }
.doc-sec h3 { display: flex; align-items: center; gap: 12px; font-size: 20px; font-weight: 700; margin: 34px 0 12px; }
.doc-sec p { margin: 0 0 14px; color: #d6d6d6; }
.doc-sec .muted { color: var(--muted); font-size: 15px; }
.doc-sec .steps { margin: 18px 0; }
.doc-sec code { color: #eee; background: var(--surface-2); border: 1px solid #2a2a2a; border-radius: 4px; padding: 0 5px; overflow-wrap: anywhere; }
.num { display: inline-grid; place-items: center; width: 38px; height: 38px; border-radius: 50%; background: var(--red); color: #fff; font-size: 17px; letter-spacing: 0; flex: none; }
.step { display: inline-grid; place-items: center; min-width: 36px; height: 26px; padding: 0 8px; border-radius: 6px; border: 1px solid rgba(229, 9, 20, 0.55); color: var(--red-text); font-size: 13px; font-weight: 800; flex: none; }
.tag { padding: 3px 10px; border-radius: 999px; background: rgba(229, 9, 20, 0.14); color: var(--red-text); font-size: 13px; font-weight: 700; letter-spacing: 0; }
.plain { margin: 0 0 14px; padding-left: 22px; color: #d6d6d6; display: grid; gap: 8px; }

/* The request's path, left to right on wide screens, top to bottom on phones. */
.flow { list-style: none; margin: 8px 0 22px; padding: 0; display: grid; gap: 24px; }
.flow li { position: relative; display: grid; gap: 2px; padding: 14px 16px; background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); }
.flow li span { color: var(--muted); font-size: 14px; line-height: 1.4; }
.flow li.accent { border-color: rgba(229, 9, 20, 0.6); background: linear-gradient(rgba(229, 9, 20, 0.1), rgba(229, 9, 20, 0.04)); }
.flow li + li::before { content: "↓"; position: absolute; top: -23px; left: 22px; color: var(--muted); font-size: 14px; line-height: 22px; }
@media (min-width: 760px) {
  .flow { grid-template-columns: repeat(5, minmax(0, 1fr)); gap: 18px; }
  .flow li + li::before { content: "→"; top: 50%; left: -15px; transform: translateY(-50%); }
}

.callout { margin: 16px 0; padding: 14px 18px; border-radius: var(--radius); border: 1px solid var(--line); border-left-width: 4px; background: var(--surface); }
.callout b { display: block; margin-bottom: 2px; }
.callout p { margin: 0; color: #cfcfcf; }
.callout.warn { border-left-color: var(--red); }
.callout.ok { border-left-color: #46d369; }
.verdicts { display: grid; gap: 12px; }
.verdicts .callout { margin: 0; }
@media (min-width: 640px) { .verdicts { grid-template-columns: 1fr 1fr; } }

/* Commands: copy with one click; long lines scroll inside the block, never the page. */
.code { margin: 14px 0 18px; border: 1px solid #2a2a2a; border-radius: var(--radius); background: #0b0b0b; overflow: hidden; }
.code-bar { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 6px 8px 6px 14px; border-bottom: 1px solid #222; background: #121212; color: var(--muted); font-size: 13px; }
.copy { min-height: 32px; min-width: 64px; padding: 0 12px; border: 1px solid #333; border-radius: 6px; background: var(--surface-2); color: var(--text); font: 600 13px/1 var(--font); cursor: pointer; transition: background-color 150ms, border-color 150ms; }
.copy:hover { background: #262626; }
.copy.done { border-color: #46d369; color: #8ff0a4; }
.code pre { margin: 0; padding: 16px; overflow-x: auto; font: 13.5px/1.6 var(--mono); color: #e6e6e6; tab-size: 4; scrollbar-width: thin; }
.code pre code { background: none; border: 0; padding: 0; color: inherit; font-size: inherit; overflow-wrap: normal; }

.table-wrap { overflow-x: auto; margin: 16px 0 18px; border: 1px solid var(--line); border-radius: var(--radius); }
.grid-table { width: 100%; border-collapse: collapse; font-size: 15px; }
.grid-table th, .grid-table td { padding: 12px 14px; text-align: left; vertical-align: top; border-bottom: 1px solid var(--line); }
.grid-table tr:last-child > * { border-bottom: 0; }
.grid-table thead th { background: var(--surface); color: var(--muted); font-size: 13px; font-weight: 700; letter-spacing: 0.04em; text-transform: uppercase; white-space: nowrap; }
.grid-table tbody th { font-weight: 600; }
.grid-table td { color: #cfcfcf; }
.trouble { min-width: 720px; }
.trouble tbody th { width: 34%; }
.pill { display: inline-block; padding: 2px 10px; border-radius: 999px; font-size: 13px; font-weight: 700; }
.pill.ok { background: rgba(70, 211, 105, 0.14); color: #8ff0a4; }
.pill.no { background: rgba(229, 9, 20, 0.16); color: var(--red-text); }
.doc-sec .downloads { margin: 6px 0 20px; }
