/* ═══════════════════════════════════════════════════════════════
   powerqueue landing page — terminal-inspired, dark, the same
   family as aleandros.github.io/mdx with a violet accent for Fable.
   ═══════════════════════════════════════════════════════════════ */

:root {
  --bg: #0b0e14;
  --bg-elev: #121723;
  --bg-elev-2: #1a2130;
  --border: #2a3242;
  --border-soft: #1e2532;
  --text: #e6ecf5;
  --text-dim: #8d9ab0;
  --text-muted: #5a687c;
  --accent: #c792ea;        /* violet — fable */
  --accent-2: #7ee787;      /* green — running / ok */
  --accent-3: #ffa657;      /* amber — warnings / budget */
  --accent-4: #79c0ff;      /* blue — sonnet */
  --prompt: #7ee787;
  --red: #ff6b6b;
  --yellow: #f9c74f;
  --green: #7ee787;
  --glow: 0 0 24px rgba(199, 146, 234, 0.16);
  --mono: 'JetBrains Mono', 'Fira Code', 'SF Mono', Consolas, monospace;
  --sans: 'Inter', -apple-system, BlinkMacSystemFont, system-ui, sans-serif;
  --radius: 10px;
  --radius-sm: 6px;
}

* { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; }
body {
  background: var(--bg);
  color: var(--text);
  font-family: var(--sans);
  line-height: 1.6;
  min-height: 100vh;
  overflow-x: hidden;
  position: relative;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

.glow-bg {
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: 0;
  background:
    radial-gradient(ellipse at 15% 0%, rgba(199, 146, 234, 0.10), transparent 50%),
    radial-gradient(ellipse at 85% 35%, rgba(126, 231, 135, 0.06), transparent 50%),
    linear-gradient(var(--border-soft) 1px, transparent 1px) 0 0 / 40px 40px,
    linear-gradient(90deg, var(--border-soft) 1px, transparent 1px) 0 0 / 40px 40px;
  mask-image: radial-gradient(ellipse at center, black 30%, transparent 80%);
  opacity: 0.5;
}
.scanlines {
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: 1;
  background: repeating-linear-gradient(0deg, rgba(255,255,255,0.015) 0px, rgba(255,255,255,0.015) 1px, transparent 1px, transparent 3px);
  mix-blend-mode: overlay;
}
main, header, footer { position: relative; z-index: 2; }

/* ───── nav ───── */
.nav {
  position: sticky; top: 0; z-index: 100;
  backdrop-filter: blur(12px); -webkit-backdrop-filter: blur(12px);
  background: rgba(11, 14, 20, 0.78);
  border-bottom: 1px solid var(--border-soft);
}
.nav-inner { max-width: 1200px; margin: 0 auto; padding: 14px 32px; display: flex; align-items: center; justify-content: space-between; }
.brand { font-family: var(--mono); font-weight: 700; font-size: 18px; color: var(--text); text-decoration: none; letter-spacing: -0.5px; display: flex; align-items: center; gap: 8px; }
.brand img { width: 22px; height: 22px; }
.brand .prompt { color: var(--prompt); }
.nav-links { display: flex; align-items: center; gap: 28px; }
.nav-links a { font-family: var(--mono); font-size: 13px; color: var(--text-dim); text-decoration: none; transition: color 0.15s; }
.nav-links a:hover { color: var(--accent); }
.gh-link { display: flex; align-items: center; }

/* ───── hero ───── */
.hero { padding: 80px 32px 60px; }
.hero-inner { max-width: 1200px; margin: 0 auto; display: grid; grid-template-columns: 1fr 1.1fr; gap: 56px; align-items: center; }
.hero-text { max-width: 560px; min-width: 0; }
.hero-inner > *, .two-col > *, .terminal, .hero-visual { min-width: 0; }
.badges { display: flex; gap: 6px; flex-wrap: wrap; margin-bottom: 28px; }
.badges img { height: 20px; border-radius: 3px; }
h1 { font-size: clamp(32px, 4.5vw, 52px); font-weight: 700; line-height: 1.1; letter-spacing: -1.5px; margin-bottom: 20px; }
h1 .accent { color: var(--accent); }
h1 .accent-alt { color: var(--accent-2); white-space: nowrap; }
.tagline { font-size: 18px; color: var(--text-dim); margin-bottom: 36px; line-height: 1.5; }
.tagline a { color: var(--accent-4); text-decoration: none; border-bottom: 1px dashed var(--accent-4); }
.tagline code { font-family: var(--mono); background: var(--bg-elev); padding: 2px 6px; border-radius: 4px; font-size: 15px; color: var(--accent-2); border: 1px solid var(--border-soft); }

.install-box { background: var(--bg-elev); border: 1px solid var(--border); border-radius: var(--radius); margin-bottom: 28px; overflow: hidden; box-shadow: 0 4px 20px rgba(0,0,0,0.3), var(--glow); }
.install-header { display: flex; align-items: center; gap: 8px; padding: 10px 14px; background: var(--bg-elev-2); border-bottom: 1px solid var(--border); }
.dot { width: 11px; height: 11px; border-radius: 50%; display: inline-block; }
.dot.red { background: var(--red); } .dot.yellow { background: var(--yellow); } .dot.green { background: var(--green); }
.install-title, .terminal-title { font-family: var(--mono); font-size: 12px; color: var(--text-muted); margin-left: 12px; }
.install-body { display: flex; align-items: center; padding: 16px; gap: 12px; font-family: var(--mono); font-size: 13px; overflow-x: auto; }
.install-body code { flex: 1; color: var(--text); white-space: nowrap; }
.install-body code::before { content: '$ '; color: var(--prompt); }
.copy-btn { background: transparent; border: 1px solid var(--border); color: var(--text-dim); border-radius: var(--radius-sm); padding: 6px 8px; cursor: pointer; transition: all 0.15s; display: flex; align-items: center; flex-shrink: 0; }
.copy-btn:hover, .copy-btn.copied { color: var(--accent); border-color: var(--accent); background: rgba(199,146,234,0.08); }

.cta-row { display: flex; gap: 12px; flex-wrap: wrap; }
.btn { font-family: var(--mono); font-size: 14px; font-weight: 500; text-decoration: none; padding: 12px 22px; border-radius: var(--radius-sm); border: 1px solid transparent; transition: all 0.15s; display: inline-flex; align-items: center; justify-content: center; }
.btn-primary { background: var(--accent); color: var(--bg); font-weight: 700; }
.btn-primary:hover { background: #d9b3f2; box-shadow: 0 0 20px rgba(199,146,234,0.45); transform: translateY(-1px); }
.btn-ghost { background: transparent; color: var(--text); border-color: var(--border); }
.btn-ghost:hover { border-color: var(--accent); color: var(--accent); }

/* hero terminal */
.hero-visual { display: flex; justify-content: center; }
.terminal { background: var(--bg-elev); border: 1px solid var(--border); border-radius: var(--radius); overflow: hidden; box-shadow: 0 20px 60px rgba(0,0,0,0.5), 0 0 60px rgba(199,146,234,0.10); width: 100%; max-width: 640px; }
.terminal-header { display: flex; align-items: center; gap: 8px; padding: 10px 14px; background: var(--bg-elev-2); border-bottom: 1px solid var(--border); }
.terminal-body { background: #05070b; padding: 16px 18px; min-height: 360px; }
.terminal-body pre { font-family: var(--mono); font-size: 12px; line-height: 1.5; color: var(--text); white-space: pre; overflow-x: auto; }
.terminal-body .k { color: var(--prompt); }
.terminal-body .b { color: var(--text); font-weight: 700; }
.terminal-body .d { color: var(--text-muted); }
.terminal-body .g { color: var(--green); }
.terminal-body .y { color: var(--yellow); }
.terminal-body .p { color: var(--accent); font-weight: 700; }
.terminal-body .c { color: var(--accent-4); }
.terminal-body .r { color: var(--red); font-weight: 700; }
.terminal-body .m { color: #d2a8ff; }
.terminal-body .sel { background: rgba(199,146,234,0.14); }
.terminal-body .cursor { color: var(--accent-2); animation: blink 1s steps(1) infinite; }
@keyframes blink { 50% { opacity: 0; } }
.terminal-body pre.flash { animation: fadein 0.5s ease-out; }
@keyframes fadein { from { opacity: 0; transform: translateY(4px); } to { opacity: 1; transform: none; } }

/* ───── sections ───── */
section { padding: 100px 32px; position: relative; }
.section-inner { max-width: 1200px; margin: 0 auto; }
h2 { font-size: clamp(28px, 3.5vw, 40px); font-weight: 700; letter-spacing: -1px; margin-bottom: 48px; }
h2 .prompt { font-family: var(--mono); color: var(--accent); margin-right: 12px; }

/* flow */
.flow { border-top: 1px solid var(--border-soft); }
.flow-diagram { background: #080c13; border: 1px solid var(--border); border-radius: 14px; overflow: hidden; box-shadow: 0 18px 60px #0003; }
.pipeline-toolbar { display: flex; justify-content: space-between; align-items: center; gap: 12px; padding: 16px 22px; border-bottom: 1px solid var(--border-soft); font: 11px var(--mono); color: var(--text-dim); }
.pipeline-toolbar > span { display: flex; align-items: center; gap: 9px; }
.pipeline-status-dot { width: 6px; height: 6px; background: var(--accent-2); border-radius: 50%; box-shadow: 0 0 10px #7ee78755; }
.pipeline-toggle { font: inherit; color: var(--text-dim); background: var(--bg-elev); border: 1px solid var(--border); border-radius: 5px; padding: 7px 10px; cursor: pointer; }
.pipeline-toggle:hover { color: var(--text); border-color: var(--accent); }
.pipeline-toggle:focus-visible { outline: 2px solid var(--accent); outline-offset: 4px; }
.pipeline { width: 100%; height: auto; display: block; font: 12px var(--mono); }
.pipeline text { fill: var(--text); }
.pipeline .pipeline-micro { font-size: 10px; fill: var(--text-dim); }
.pipeline .pipeline-heading { font: 600 15px var(--sans); }
.pipeline-panel { fill: #0e1420; stroke: #303b50; }
.pipeline-ticket rect { fill: #151e2d; stroke: #2b374b; }
.pipeline-ticket text { font-size: 11px; }
.pipeline .pipeline-ticket-priority { text-anchor: end; fill: var(--text-dim); font-size: 10px; }
.pipeline-vps-shell { fill: #101522; stroke: #68517e; }
.pipeline-server-icon { fill: none; stroke: var(--accent); stroke-width: 1.4; }
.pipeline .pipeline-capacity { fill: var(--text-dim); font-size: 10px; }
.pipeline-policy-shell { fill: #201c30; stroke: #534160; }
.pipeline .pipeline-policy-title { fill: #dbb7f3; font-size: 12px; }
.pipeline-wires { stroke: #3b485f; stroke-width: 1.5; stroke-linejoin: round; }
.pipeline-violet { --slot-color: #c792ea; }
.pipeline-blue { --slot-color: #79c0ff; }
.pipeline-amber { --slot-color: #ffa657; }
.pipeline-slot-shell { fill: #0a101a; stroke: #394357; }
.pipeline-slot-fill, .pipeline-slot-led, .pipeline-progress, .pipeline-packet { fill: var(--slot-color); }
.pipeline .pipeline-slot-model { fill: var(--slot-color); font-size: 11px; }
.pipeline-slot-state { font-size: 13px; }
.pipeline-track { fill: #263044; }
.pipeline-review-icon { fill: #7ee78712; stroke: #7ee78755; }
.pipeline .pipeline-review-state { fill: var(--accent-2); font-size: 12px; }
.flow-diagram figcaption { display: flex; justify-content: space-between; gap: 14px; flex-wrap: wrap; border-top: 1px solid var(--border-soft); padding: 17px 22px; color: var(--text-dim); font-size: 12px; }
.pipeline-caption-key { color: var(--text); font-family: var(--mono); }
@media (max-width: 759px) {
  .pipeline-toolbar { padding: 14px; font-size: 10px; }
  .flow-diagram figcaption { padding: 16px; }
}
.flow-steps { display: grid; grid-template-columns: repeat(auto-fit, minmax(180px, 1fr)); gap: 16px; margin-top: 28px; }
.flow-step { font-size: 14.5px; color: var(--text-dim); padding-left: 14px; border-left: 2px solid var(--border); }
.flow-step strong { color: var(--text); font-family: var(--mono); font-size: 13px; display: block; margin-bottom: 4px; }

/* features */
.features { border-top: 1px solid var(--border-soft); }
.feature-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(280px, 1fr)); gap: 20px; }
.feature { background: var(--bg-elev); border: 1px solid var(--border-soft); border-radius: var(--radius); padding: 28px; transition: all 0.2s; position: relative; overflow: hidden; }
.feature::before { content: ''; position: absolute; inset: 0; background: linear-gradient(135deg, transparent 60%, rgba(199,146,234,0.04)); pointer-events: none; }
.feature:hover { border-color: var(--accent); transform: translateY(-3px); box-shadow: 0 8px 30px rgba(199,146,234,0.10); }
.feature-icon { font-family: var(--mono); font-size: 12px; color: var(--accent-4); background: var(--bg-elev-2); padding: 12px 14px; border-radius: var(--radius-sm); margin-bottom: 20px; border: 1px solid var(--border-soft); display: inline-block; min-height: 72px; }
.feature-icon pre { font-family: inherit; line-height: 1.3; }
.feature h3 { font-size: 18px; font-weight: 600; margin-bottom: 8px; }
.feature p { font-size: 14.5px; color: var(--text-dim); line-height: 1.6; }
.feature code { font-family: var(--mono); background: var(--bg-elev-2); padding: 1px 5px; border-radius: 3px; font-size: 12.5px; color: var(--accent-2); }

/* install */
.install-section { border-top: 1px solid var(--border-soft); background: linear-gradient(180deg, transparent, rgba(18, 23, 35, 0.4)); }
.install-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(320px, 1fr)); gap: 20px; margin-bottom: 48px; }
.install-card { background: var(--bg-elev); border: 1px solid var(--border-soft); border-radius: var(--radius); padding: 28px; }
.install-card h3, .usage-preview h3 { font-family: var(--mono); font-size: 14px; font-weight: 700; text-transform: uppercase; letter-spacing: 1px; color: var(--accent); margin-bottom: 10px; }
.install-card h3::before, .usage-preview h3::before { content: '» '; }
.install-desc { font-size: 14px; color: var(--text-dim); margin-bottom: 16px; }
.install-card code, .install-desc code { font-family: var(--mono); color: var(--accent-3); font-size: 12.5px; background: var(--bg-elev-2); padding: 1px 5px; border-radius: 3px; }
.code-block { background: #05070b; border: 1px solid var(--border); border-radius: var(--radius-sm); padding: 16px 18px; font-family: var(--mono); font-size: 13px; overflow-x: auto; }
.code-block pre { font-family: inherit; }
.code-block code { color: var(--text); background: none; padding: 0; }
.c-comment { color: var(--text-muted); font-style: italic; }
.usage-preview h3 { margin-bottom: 14px; }

/* priority / budget */
.rules { border-top: 1px solid var(--border-soft); }
.two-col { display: grid; grid-template-columns: 1fr 1fr; gap: 28px; align-items: start; }
.two-col h3 { font-family: var(--mono); font-size: 14px; font-weight: 700; text-transform: uppercase; letter-spacing: 1px; color: var(--accent); margin-bottom: 12px; }
.two-col h3::before { content: '» '; }
.two-col p { color: var(--text-dim); font-size: 15px; margin-bottom: 16px; }
.two-col p code { font-family: var(--mono); color: var(--accent-2); background: var(--bg-elev); padding: 1px 5px; border-radius: 3px; font-size: 13px; border: 1px solid var(--border-soft); }
.md-h { color: var(--accent); font-weight: 700; }
.md-b { color: var(--text-muted); }
.md-k { color: var(--accent-4); }
.md-v { color: var(--accent-3); }

/* why */
.why { border-top: 1px solid var(--border-soft); }
.why blockquote { font-size: 20px; line-height: 1.65; max-width: 820px; border-left: 3px solid var(--accent); padding-left: 24px; margin-bottom: 32px; }
.why blockquote p + p { margin-top: 16px; }
.why code { font-family: var(--mono); color: var(--accent-2); background: var(--bg-elev); padding: 2px 6px; border-radius: 4px; font-size: 17px; border: 1px solid var(--border-soft); }
.scope-note { background: var(--bg-elev); border: 1px solid var(--border-soft); border-left: 3px solid var(--accent-3); padding: 18px 22px; border-radius: var(--radius-sm); color: var(--text-dim); font-size: 15px; max-width: 820px; }
.scope-note strong { color: var(--accent-3); }
.scope-note code { font-family: var(--mono); color: var(--accent-2); background: var(--bg-elev-2); padding: 1px 6px; border-radius: 3px; font-size: 13px; }
.scope-note a { color: var(--accent-4); text-decoration: none; border-bottom: 1px dashed var(--accent-4); }

/* cta */
.cta { border-top: 1px solid var(--border-soft); padding-bottom: 120px; }
.cta-box { background: radial-gradient(ellipse at 30% 0%, rgba(199,146,234,0.14), transparent 60%), var(--bg-elev); border: 1px solid var(--border); border-radius: var(--radius); padding: 60px 48px; text-align: center; }
.cta-box h2 { margin-bottom: 12px; font-size: clamp(32px, 4vw, 48px); }
.cta-box p { font-size: 18px; color: var(--text-dim); margin-bottom: 32px; }
.cta-box .cta-row { justify-content: center; }

/* footer */
footer { border-top: 1px solid var(--border-soft); padding: 28px 32px; font-family: var(--mono); font-size: 13px; }
.footer-inner { max-width: 1200px; margin: 0 auto; display: flex; align-items: center; justify-content: space-between; flex-wrap: wrap; gap: 16px; }
footer .prompt { color: var(--prompt); }
footer .dim { color: var(--text-muted); margin-left: 8px; }
.footer-links { display: flex; gap: 20px; }
.footer-links a { color: var(--text-dim); text-decoration: none; transition: color 0.15s; }
.footer-links a:hover { color: var(--accent); }

/* responsive */
@media (max-width: 960px) {
  .hero-inner, .two-col { grid-template-columns: 1fr; gap: 40px; }
  .hero { padding: 48px 24px; }
  section { padding: 72px 24px; }
  .nav-inner { padding: 14px 20px; }
  .nav-links { gap: 16px; }
  .nav-links a:not(.gh-link) { display: none; }
  .cta-box { padding: 40px 24px; }
  .terminal-body { min-height: 0; }
}
@media (max-width: 500px) {
  .install-body { font-size: 11.5px; padding: 14px; }
  .cta-row { flex-direction: column; }
  .cta-row .btn { width: 100%; }
  h1 { font-size: 32px; }
  .badges img { height: 18px; }
  .terminal-body pre { font-size: 10.5px; }
}
@media (prefers-reduced-motion: reduce) {
  * { animation: none !important; transition: none !important; }
  html { scroll-behavior: auto; }
}

/* cost */
.cost { background: linear-gradient(180deg, rgba(18, 23, 35, 0.4), transparent); }
.section-lead { font-size: 17px; color: var(--text-dim); line-height: 1.6; max-width: 820px; margin: -12px 0 32px; }
