:root {
  --bg-canvas: #07080c;
  --bg-surface: #0c0e14;
  --bg-card: #11131b;
  --bg-elevated: #161923;
  --bg-input: #141720;
  --border-subtle: rgba(255, 255, 255, 0.07);
  --border-strong: rgba(255, 255, 255, 0.13);
  --border-accent: rgba(139, 124, 246, 0.45);
  --text-primary: #f3f4f8;
  --text-secondary: #9ca3b5;
  --text-muted: #646b7d;
  --accent: #8b7cf6;
  --accent-hover: #9d90f8;
  --accent-soft: rgba(139, 124, 246, 0.14);
  --ok: #4ade80;
  --ok-soft: rgba(74, 222, 128, 0.12);
  --warn: #fbbf24;
  --danger: #f87171;
  --radius-sm: 6px;
  --radius-md: 10px;
  --radius-lg: 14px;
  --font-sans: 'Inter', 'Segoe UI', -apple-system, BlinkMacSystemFont, sans-serif;
  --font-mono: 'JetBrains Mono', 'Cascadia Code', Consolas, monospace;
}

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

html {
  scroll-behavior: smooth;
  background: var(--bg-canvas);
  color: var(--text-primary);
  font-family: var(--font-sans);
  font-size: 16px;
  line-height: 1.55;
  -webkit-font-smoothing: antialiased;
}

body {
  min-height: 100dvh;
  background-color: var(--bg-canvas);
  background-image:
    radial-gradient(rgba(255, 255, 255, 0.04) 1px, transparent 1px);
  background-size: 28px 28px;
  overflow-x: hidden;
}

.tabular {
  font-variant-numeric: tabular-nums;
  font-family: var(--font-mono);
}

.container {
  width: 100%;
  max-width: 1240px;
  margin: 0 auto;
  padding: 0 24px;
}

/* Navbar */
.navbar {
  position: sticky;
  top: 0;
  z-index: 50;
  height: 64px;
  background: rgba(7, 8, 12, 0.85);
  backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--border-subtle);
}

.navbar-inner {
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-weight: 700;
  font-size: 1.05rem;
  color: var(--text-primary);
  text-decoration: none;
}

.brand-dot {
  width: 9px;
  height: 9px;
  border-radius: 50%;
  background: var(--accent);
}

.brand-tag {
  font-family: var(--font-mono);
  font-size: 0.72rem;
  font-weight: 500;
  padding: 2px 7px;
  border-radius: 4px;
  background: var(--accent-soft);
  color: var(--accent);
  border: 1px solid var(--border-accent);
}

.nav-links {
  display: flex;
  align-items: center;
  gap: 28px;
  list-style: none;
}

.nav-links a {
  color: var(--text-secondary);
  text-decoration: none;
  font-size: 0.9rem;
  font-weight: 500;
  transition: color 150ms ease-out;
}

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

.nav-actions {
  display: flex;
  align-items: center;
  gap: 12px;
}

/* Buttons */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  height: 38px;
  padding: 0 18px;
  border-radius: var(--radius-sm);
  font-size: 0.88rem;
  font-weight: 600;
  text-decoration: none;
  cursor: pointer;
  border: 1px solid transparent;
  transition: background-color 150ms ease-out, border-color 150ms ease-out, transform 120ms ease-out;
}

.btn:active {
  transform: translateY(1px);
}

.btn-primary {
  background: var(--accent);
  color: #ffffff;
}

.btn-primary:hover {
  background: var(--accent-hover);
}

.btn-secondary {
  background: var(--bg-card);
  color: var(--text-primary);
  border-color: var(--border-strong);
}

.btn-secondary:hover {
  background: var(--bg-elevated);
}

.btn-lg {
  height: 44px;
  padding: 0 24px;
  font-size: 0.94rem;
}

/* Hero */
.hero {
  padding: 72px 0 56px;
  border-bottom: 1px solid var(--border-subtle);
}

.hero-header {
  max-width: 780px;
  margin: 0 auto 44px;
  text-align: center;
}

.status-pill {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 5px 13px;
  border-radius: 999px;
  background: var(--bg-card);
  border: 1px solid var(--border-strong);
  font-size: 0.8rem;
  color: var(--text-secondary);
  margin-bottom: 20px;
}

.status-dot {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: var(--ok);
}

.hero h1 {
  font-size: clamp(2.2rem, 4.4vw, 3.5rem);
  font-weight: 800;
  line-height: 1.12;
  text-wrap: balance;
  margin-bottom: 18px;
}

.hero p {
  font-size: 1.08rem;
  color: var(--text-secondary);
  text-wrap: pretty;
  max-width: 640px;
  margin: 0 auto 28px;
}

.hero-cta-row {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 14px;
  flex-wrap: wrap;
  margin-bottom: 24px;
}

.proof-strip {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 28px;
  flex-wrap: wrap;
  font-size: 0.82rem;
  color: var(--text-muted);
}

.proof-item strong {
  color: var(--text-primary);
  font-family: var(--font-mono);
}

/* Interactive Render Harness Workbench */
.workbench {
  background: var(--bg-surface);
  border: 1px solid var(--border-strong);
  border-radius: var(--radius-lg);
  overflow: hidden;
  box-shadow: 0 24px 64px rgba(0, 0, 0, 0.65);
}

.workbench-bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 12px 18px;
  background: var(--bg-card);
  border-bottom: 1px solid var(--border-subtle);
  flex-wrap: wrap;
  gap: 12px;
}

.wb-mode-tabs {
  display: flex;
  align-items: center;
  gap: 6px;
}

.wb-tab {
  padding: 6px 13px;
  border-radius: var(--radius-sm);
  background: transparent;
  border: 1px solid transparent;
  color: var(--text-secondary);
  font-size: 0.82rem;
  font-weight: 600;
  cursor: pointer;
}

.wb-tab.active {
  background: var(--accent-soft);
  border-color: var(--border-accent);
  color: var(--text-primary);
}

.wb-telemetry {
  display: flex;
  align-items: center;
  gap: 16px;
  font-family: var(--font-mono);
  font-size: 0.78rem;
  color: var(--text-secondary);
}

.wb-stage {
  position: relative;
  min-height: 640px;
  background: #08090e;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 58px 24px 28px;
}

#tactical-canvas {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  pointer-events: none;
}

/* Live NOCTOS Watermark */
.noctos-watermark {
  position: absolute;
  top: 14px;
  left: 50%;
  transform: translateX(-50%);
  z-index: 4;
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 6px 14px;
  border-radius: 6px;
  background: rgba(14, 15, 20, 0.94);
  border: 1px solid rgba(255, 255, 255, 0.10);
  font-family: var(--font-mono);
  font-size: 0.78rem;
  pointer-events: none;
  white-space: nowrap;
}

.hw-dot {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: var(--accent);
}

.hw-sep {
  color: var(--text-muted);
}

/* Interactive NOCTOS Menu Replica */
.noctos-menu-shell {
  position: relative;
  z-index: 5;
  display: grid;
  grid-template-columns: 1fr 220px;
  gap: 14px;
  width: 100%;
  max-width: 940px;
}

.noctos-window, .noctos-preview-card {
  background: rgba(14, 15, 20, 0.96);
  border: 1px solid rgba(255, 255, 255, 0.10);
  border-radius: 10px;
  overflow: hidden;
}

.nw-header {
  height: 48px;
  padding: 0 18px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  border-bottom: 1px solid rgba(255, 255, 255, 0.07);
}

.nw-title {
  display: flex;
  align-items: center;
  gap: 10px;
  font-weight: 700;
  font-size: 0.92rem;
}

.nw-tabs {
  display: flex;
  align-items: center;
  gap: 4px;
}

.nw-tab {
  padding: 5px 11px;
  border-radius: 6px;
  font-size: 0.8rem;
  font-weight: 600;
  color: var(--text-secondary);
  background: transparent;
  border: 1px solid transparent;
  cursor: pointer;
}

.nw-tab.active {
  background: var(--accent-soft);
  border-color: var(--border-accent);
  color: var(--text-primary);
}

.nw-subtabs {
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 10px 16px 0;
  flex-wrap: wrap;
}

.nw-subtab {
  padding: 4px 10px;
  border-radius: 5px;
  font-size: 0.76rem;
  font-weight: 600;
  color: var(--text-secondary);
  background: #13151b;
  border: 1px solid rgba(255, 255, 255, 0.06);
  cursor: pointer;
}

.nw-subtab.active {
  background: var(--accent-soft);
  border-color: var(--border-accent);
  color: var(--text-primary);
}

.nw-footer {
  height: 30px;
  padding: 0 16px;
  border-top: 1px solid rgba(255, 255, 255, 0.07);
  display: flex;
  align-items: center;
  justify-content: space-between;
  font-size: 0.75rem;
  color: var(--text-secondary);
}

.nw-body {
  padding: 14px 16px 16px;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 14px;
  min-height: 410px;
  align-content: start;
}

.nw-card {
  background: #13151b;
  border: 1px solid rgba(255, 255, 255, 0.06);
  border-radius: 8px;
  padding: 14px;
  display: flex;
  flex-direction: column;
  gap: 11px;
}

.nw-card-title {
  font-size: 0.73rem;
  font-weight: 700;
  color: var(--accent);
  text-transform: uppercase;
  margin-bottom: 2px;
}

.nw-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  font-size: 0.83rem;
  color: var(--text-secondary);
}

.nw-row.enabled {
  color: var(--text-primary);
}

/* Custom Switch */
.nw-switch {
  position: relative;
  width: 34px;
  height: 18px;
  background: #22252e;
  border-radius: 999px;
  cursor: pointer;
  border: none;
  transition: background-color 140ms ease-out;
}

.nw-switch.on {
  background: var(--accent);
}

.nw-switch::after {
  content: '';
  position: absolute;
  top: 3px;
  left: 3px;
  width: 12px;
  height: 12px;
  border-radius: 50%;
  background: #f5f7fc;
  transition: transform 140ms ease-out;
}

.nw-switch.on::after {
  transform: translateX(16px);
}

.nw-slider-wrap {
  display: flex;
  flex-direction: column;
  gap: 5px;
}

.nw-slider-top {
  display: flex;
  justify-content: space-between;
  font-size: 0.8rem;
  color: var(--text-secondary);
}

.nw-slider-top span:last-child {
  color: var(--accent);
  font-family: var(--font-mono);
}

.nw-slider {
  width: 100%;
  accent-color: var(--accent);
  height: 5px;
  cursor: pointer;
}

.nw-combo-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  font-size: 0.81rem;
  color: var(--text-secondary);
  gap: 8px;
}

.nw-select {
  background: #1a1c24;
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 5px;
  color: var(--text-primary);
  font-size: 0.77rem;
  padding: 3px 8px;
  font-family: var(--font-sans);
  cursor: pointer;
}

/* Preview Card */
.noctos-preview-card {
  padding: 14px;
  display: flex;
  flex-direction: column;
}

.actor-stage {
  flex: 1;
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-top: 8px;
  background: #0c0d12;
  border: 1px solid rgba(255, 255, 255, 0.05);
  border-radius: 8px;
}

#actor-preview-canvas {
  width: 190px;
  height: 360px;
}

/* Interactive Loader Simulator */
.loader-sim-wrap {
  position: relative;
  z-index: 5;
  display: none;
  flex-direction: column;
  align-items: center;
  gap: 16px;
}

.loader-window {
  width: 360px;
  height: 220px;
  background: #0e0f13;
  border: 1px solid rgba(255, 255, 255, 0.11);
  border-radius: 6px;
  display: flex;
  flex-direction: column;
  box-shadow: 0 20px 50px rgba(0, 0, 0, 0.7);
}

.lw-header {
  height: 40px;
  padding: 0 20px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  border-bottom: 1px solid rgba(255, 255, 255, 0.07);
  font-size: 0.88rem;
  font-weight: 600;
}

.lw-body {
  flex: 1;
  padding: 16px 20px 16px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
}

.lw-input-row {
  display: flex;
  gap: 6px;
}

.lw-input {
  flex: 1;
  height: 31px;
  padding: 0 10px;
  background: #191a21;
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 6px;
  color: var(--text-primary);
  font-family: var(--font-mono);
  font-size: 0.82rem;
}

.lw-eye-btn {
  width: 54px;
  height: 31px;
  background: #1c1e26;
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 6px;
  color: var(--text-secondary);
  font-size: 0.78rem;
  cursor: pointer;
}

.lw-primary-btn {
  width: 100%;
  height: 34px;
  background: var(--accent);
  border: none;
  border-radius: 6px;
  color: #fff;
  font-weight: 700;
  font-size: 0.83rem;
  cursor: pointer;
}

.lw-info-card {
  height: 84px;
  background: #131419;
  border: 1px solid rgba(255, 255, 255, 0.07);
  border-radius: 6px;
  display: flex;
  flex-direction: column;
  justify-content: space-evenly;
  padding: 0 14px;
}

.lw-info-row {
  display: flex;
  justify-content: space-between;
  font-size: 0.82rem;
}

.lw-divider {
  height: 1px;
  background: rgba(255, 255, 255, 0.05);
}

/* Native DX11 Gallery */
.dx11-gallery-wrap {
  position: relative;
  z-index: 5;
  display: none;
  flex-direction: column;
  align-items: center;
  gap: 16px;
  width: 100%;
}

.dx11-frame {
  max-width: 920px;
  width: 100%;
  border-radius: 10px;
  border: 1px solid var(--border-strong);
  overflow: hidden;
  background: #090a0e;
  display: flex;
  justify-content: center;
  padding: 14px;
}

.dx11-frame img {
  max-width: 100%;
  height: auto;
  border-radius: 6px;
  display: block;
}

/* Sections */
.section {
  padding: 80px 0;
  border-bottom: 1px solid var(--border-subtle);
}

.section-header {
  max-width: 660px;
  margin-bottom: 44px;
}

.section-kicker {
  font-family: var(--font-mono);
  font-size: 0.76rem;
  color: var(--accent);
  text-transform: uppercase;
  margin-bottom: 8px;
}

.section-header h2 {
  font-size: clamp(1.65rem, 3vw, 2.35rem);
  font-weight: 800;
  text-wrap: balance;
  margin-bottom: 10px;
}

.section-header p {
  color: var(--text-secondary);
  text-wrap: pretty;
}

/* Bento Grid */
.bento-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 18px;
}

.bento-card {
  background: var(--bg-card);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-md);
  padding: 24px;
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.bento-card.span-2 {
  grid-column: span 2;
}

.bento-badge {
  align-self: flex-start;
  font-family: var(--font-mono);
  font-size: 0.72rem;
  padding: 3px 8px;
  border-radius: 4px;
  background: var(--bg-elevated);
  color: var(--accent);
  border: 1px solid var(--border-subtle);
}

.bento-card h3 {
  font-size: 1.12rem;
  font-weight: 700;
}

.bento-card p {
  font-size: 0.92rem;
  color: var(--text-secondary);
}

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

.step-card {
  background: var(--bg-surface);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-md);
  padding: 24px;
}

.step-num {
  font-family: var(--font-mono);
  font-size: 0.8rem;
  color: var(--accent);
  margin-bottom: 10px;
}

/* License Verification Portal (PHP backed) */
.portal-box {
  background: var(--bg-card);
  border: 1px solid var(--border-strong);
  border-radius: var(--radius-md);
  padding: 28px;
  display: grid;
  grid-template-columns: 1.1fr 1fr;
  gap: 28px;
  align-items: center;
}

.portal-form {
  display: flex;
  gap: 10px;
  margin-top: 16px;
}

.portal-input {
  flex: 1;
  height: 42px;
  padding: 0 14px;
  border-radius: var(--radius-sm);
  background: var(--bg-input);
  border: 1px solid var(--border-strong);
  color: var(--text-primary);
  font-family: var(--font-mono);
  font-size: 0.88rem;
}

.portal-result {
  background: var(--bg-surface);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-sm);
  padding: 18px;
  font-family: var(--font-mono);
  font-size: 0.82rem;
  min-height: 118px;
  display: flex;
  flex-direction: column;
  justify-content: center;
  gap: 6px;
}

/* FAQ */
.faq-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px;
}

.faq-item {
  background: var(--bg-card);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-md);
  padding: 20px;
}

.faq-item h4 {
  font-size: 0.98rem;
  margin-bottom: 6px;
}

.faq-item p {
  font-size: 0.88rem;
  color: var(--text-secondary);
}

.footer {
  padding: 40px 0;
  font-size: 0.84rem;
  color: var(--text-muted);
  display: flex;
  justify-content: space-between;
  align-items: center;
}

@media (max-width: 960px) {
  .noctos-menu-shell, .bento-grid, .steps-grid, .portal-box, .faq-grid {
    grid-template-columns: 1fr;
  }
  .bento-card.span-2 {
    grid-column: span 1;
  }
  .nw-body {
    grid-template-columns: 1fr;
  }
}
