:root {
  --nv-bg: #050816;
  --nv-surface: #0b1020;
  --nv-surface-soft: #101629;
  --nv-accent: #6366f1;
  --nv-accent-soft: rgba(99, 102, 241, 0.16);
  --nv-accent-strong: #4f46e5;
  --nv-text: #f9fafb;
  --nv-text-soft: #9ca3af;
  --nv-border-subtle: rgba(148, 163, 184, 0.35);
  --nv-danger: #f97373;
  --nv-radius-lg: 18px;
  --nv-radius-md: 12px;
  --nv-radius-sm: 999px;
  --nv-shadow-soft: 0 18px 40px rgba(15, 23, 42, 0.75);
}

* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html,
body {
  height: 100%;
}

body {
  font-family: system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  background: radial-gradient(circle at top left, #0f172a, #020617 50%, #000);
  color: var(--nv-text);
  -webkit-font-smoothing: antialiased;
}

.nv-page {
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

.nv-header {
  position: sticky;
  top: 0;
  z-index: 40;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 14px 4vw;
  background: linear-gradient(to bottom, rgba(15, 23, 42, 0.96), rgba(15, 23, 42, 0.75), transparent);
  backdrop-filter: blur(16px);
}

.nv-brand {
  display: flex;
  align-items: center;
  gap: 10px;
}

.nv-logo-circle {
  width: 38px;
  height: 38px;
  border-radius: 999px;
  background: radial-gradient(circle at 30% 0, #a855f7, #6366f1 45%, #22d3ee);
  display: flex;
  align-items: center;
  justify-content: center;
  color: white;
  box-shadow: 0 0 0 2px rgba(99, 102, 241, 0.4);
}

.nv-logo-circle i {
  font-size: 18px;
}

.nv-brand-text {
  display: flex;
  flex-direction: column;
}

.nv-brand-title {
  font-weight: 700;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  font-size: 0.95rem;
}

.nv-brand-title span {
  color: #a5b4fc;
}

.nv-brand-sub {
  font-size: 0.75rem;
  color: var(--nv-text-soft);
}

.nv-nav {
  display: flex;
  gap: 20px;
  font-size: 0.9rem;
}

.nv-nav a {
  color: var(--nv-text-soft);
  text-decoration: none;
  padding: 6px 10px;
  border-radius: 999px;
  transition: background 0.2s ease, color 0.2s ease;
}

.nv-nav a:hover {
  background: rgba(148, 163, 184, 0.14);
  color: var(--nv-text);
}

.nv-nav-toggle {
  display: none;
  background: none;
  border: none;
  color: var(--nv-text);
  font-size: 1.2rem;
}

.nv-main {
  flex: 1;
  padding: 18px 4vw 40px;
  max-width: 1200px;
  margin: 0 auto;
}

.nv-hero {
  display: grid;
  grid-template-columns: minmax(0, 1.35fr) minmax(0, 1.4fr);
  gap: 24px;
  align-items: stretch;
  margin-top: 14px;
}

.nv-hero-text h1 {
  font-size: clamp(1.9rem, 3vw, 2.6rem);
  line-height: 1.2;
  margin-bottom: 12px;
}

.nv-hero-text h1 span {
  color: #a5b4fc;
}

.nv-hero-text p {
  color: var(--nv-text-soft);
  font-size: 0.98rem;
  max-width: 480px;
  margin-bottom: 18px;
}

.nv-hero-stats {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.nv-stat {
  padding: 10px 14px;
  border-radius: 999px;
  background: rgba(15, 23, 42, 0.85);
  border: 1px solid rgba(148, 163, 184, 0.3);
  display: flex;
  flex-direction: column;
  min-width: 135px;
}

.nv-stat-label {
  font-size: 0.75rem;
  color: var(--nv-text-soft);
}

.nv-stat-value {
  font-size: 0.9rem;
}

.nv-stat-value i {
  color: #a5b4fc;
  margin-right: 6px;
}

.nv-studio-card {
  background: radial-gradient(circle at top, rgba(79, 70, 229, 0.18), transparent 55%),
    linear-gradient(to bottom right, rgba(15, 23, 42, 0.95), rgba(15, 23, 42, 0.98));
  border-radius: 22px;
  padding: 18px 18px 16px;
  box-shadow: var(--nv-shadow-soft);
  border: 1px solid rgba(148, 163, 184, 0.4);
}

.nv-studio-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  margin-bottom: 10px;
}

.nv-studio-title {
  display: flex;
  align-items: center;
  gap: 10px;
}

.nv-studio-title i {
  width: 34px;
  height: 34px;
  border-radius: 999px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(88, 28, 135, 0.3);
  color: #e5e7eb;
}

.nv-studio-title h2 {
  font-size: 1.02rem;
}

.nv-studio-title p {
  font-size: 0.8rem;
  color: var(--nv-text-soft);
}

.nv-studio-meta {
  font-size: 0.8rem;
  color: var(--nv-text-soft);
}

.nv-input-wrap {
  margin-bottom: 12px;
}

#nv-text {
  width: 100%;
  min-height: 160px;
  max-height: 260px;
  resize: vertical;
  border-radius: 16px;
  border: 1px solid rgba(148, 163, 184, 0.4);
  background: rgba(15, 23, 42, 0.9);
  padding: 12px 14px;
  color: var(--nv-text);
  font-size: 0.94rem;
  line-height: 1.5;
}

#nv-text::placeholder {
  color: var(--nv-text-soft);
}

#nv-text:focus {
  outline: none;
  border-color: var(--nv-accent);
  box-shadow: 0 0 0 1px rgba(99, 102, 241, 0.5);
}

.nv-control-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px 12px;
  margin-bottom: 12px;
}

.nv-control-group label {
  display: flex;
  align-items: center;
  justify-content: space-between;
  font-size: 0.82rem;
  margin-bottom: 4px;
}

.nv-control-group label i {
  margin-right: 6px;
  color: #a5b4fc;
}

select,
input[type="range"] {
  width: 100%;
}

select {
  border-radius: 999px;
  border: 1px solid rgba(148, 163, 184, 0.5);
  background: rgba(15, 23, 42, 0.9);
  color: var(--nv-text);
  padding: 7px 14px;
  font-size: 0.84rem;
}

select:focus {
  outline: none;
  border-color: var(--nv-accent);
}

input[type="range"] {
  accent-color: var(--nv-accent);
}

.nv-actions {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 10px;
}

.nv-actions-main {
  display: flex;
  gap: 8px;
}

.nv-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  border-radius: 999px;
  border: 1px solid transparent;
  padding: 7px 14px;
  font-size: 0.86rem;
  cursor: pointer;
  transition: background 0.15s ease, color 0.15s ease, border-color 0.15s ease, transform 0.08s ease;
  white-space: nowrap;
}

.nv-btn i {
  font-size: 0.86rem;
}

.nv-btn-primary {
  background: linear-gradient(to right, #4f46e5, #6366f1);
  border-color: rgba(129, 140, 248, 0.7);
  color: white;
  box-shadow: 0 10px 25px rgba(79, 70, 229, 0.45);
}

.nv-btn-primary:hover {
  transform: translateY(-1px);
}

.nv-btn-secondary {
  background: rgba(15, 23, 42, 0.9);
  border-color: rgba(148, 163, 184, 0.7);
  color: var(--nv-text);
}

.nv-btn-ghost {
  background: transparent;
  border-color: rgba(148, 163, 184, 0.35);
  color: var(--nv-text-soft);
}

.nv-btn:disabled {
  opacity: 0.55;
  cursor: default;
  transform: none;
}

.nv-output {
  margin-top: 8px;
  padding: 10px 12px;
  border-radius: 14px;
  border: 1px dashed rgba(148, 163, 184, 0.6);
  background: radial-gradient(circle at top left, rgba(56, 189, 248, 0.08), transparent 50%),
    rgba(15, 23, 42, 0.9);
}

.nv-output-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  margin-bottom: 6px;
}

.nv-output-status {
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.nv-badge {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 0.7rem;
  padding: 3px 9px;
  border-radius: 999px;
}

.nv-badge-live {
  background: rgba(22, 163, 74, 0.13);
  color: #4ade80;
}

.nv-badge-done {
  background: rgba(129, 140, 248, 0.13);
  color: #a5b4fc;
}

.nv-badge-error {
  background: rgba(248, 113, 113, 0.13);
  color: #fecaca;
}

.nv-dot {
  width: 7px;
  height: 7px;
  border-radius: 999px;
  background: currentColor;
  box-shadow: 0 0 0 4px rgba(34, 197, 94, 0.2);
}

.nv-output-status #nv-output-text {
  font-size: 0.8rem;
  color: var(--nv-text-soft);
}

.nv-output-actions {
  display: flex;
  gap: 6px;
}

.nv-icon-btn {
  width: 30px;
  height: 30px;
  border-radius: 999px;
  border: 1px solid rgba(148, 163, 184, 0.5);
  background: rgba(15, 23, 42, 0.9);
  color: var(--nv-text);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.8rem;
  cursor: pointer;
}

.nv-icon-btn:hover {
  border-color: var(--nv-accent);
}

.nv-wave-visual {
  display: flex;
  gap: 4px;
  height: 32px;
  align-items: flex-end;
  margin-bottom: 4px;
}

.nv-wave-visual span {
  flex: 1;
  max-width: 10px;
  border-radius: 999px;
  background: linear-gradient(to top, #22d3ee, #6366f1);
  animation: nv-wave 1s ease-in-out infinite;
}

.nv-wave-visual span:nth-child(2) {
  animation-delay: 0.1s;
}

.nv-wave-visual span:nth-child(3) {
  animation-delay: 0.2s;
}

.nv-wave-visual span:nth-child(4) {
  animation-delay: 0.3s;
}

.nv-wave-visual span:nth-child(5) {
  animation-delay: 0.4s;
}

.nv-output-hint {
  font-size: 0.75rem;
  color: var(--nv-text-soft);
}

.nv-progress-row {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 6px;
}

.nv-progress-bar {
  flex: 1;
  height: 6px;
  border-radius: 999px;
  background: rgba(30, 64, 175, 0.6);
  overflow: hidden;
}

.nv-progress-fill {
  height: 100%;
  width: 0;
  border-radius: 999px;
  background: linear-gradient(to right, #22c55e, #a3e635);
  transition: width 0.2s ease;
}

.nv-progress-label {
  font-size: 0.75rem;
  color: var(--nv-text-soft);
  min-width: 36px;
  text-align: right;
}

.nv-section {
  margin-top: 40px;
}

.nv-section-header {
  margin-bottom: 16px;
}

.nv-section-header h2 {
  font-size: 1.2rem;
  margin-bottom: 4px;
}

.nv-section-header p {
  color: var(--nv-text-soft);
  font-size: 0.9rem;
}

.nv-feature-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 14px;
}

.nv-feature {
  padding: 12px 14px;
  border-radius: 18px;
  background: radial-gradient(circle at top left, rgba(99, 102, 241, 0.12), transparent 55%), var(--nv-surface);
  border: 1px solid rgba(148, 163, 184, 0.4);
  font-size: 0.86rem;
}

.nv-feature i {
  color: #a5b4fc;
  margin-bottom: 8px;
}

.nv-feature h3 {
  font-size: 0.95rem;
  margin-bottom: 4px;
}

.nv-feature p {
  color: var(--nv-text-soft);
}

.nv-faq-section {
  margin-bottom: 32px;
}

.nv-faq-list {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.nv-faq-list details {
  background: var(--nv-surface);
  border-radius: 12px;
  border: 1px solid rgba(148, 163, 184, 0.45);
  padding: 9px 11px;
  font-size: 0.86rem;
}

.nv-faq-list summary {
  cursor: pointer;
}

.nv-faq-list p {
  margin-top: 6px;
  color: var(--nv-text-soft);
}

.nv-footer {
  margin-top: auto;
  padding: 10px 4vw 16px;
  font-size: 0.8rem;
  color: var(--nv-text-soft);
  display: flex;
  justify-content: center;
  gap: 6px;
  border-top: 1px solid rgba(15, 23, 42, 0.9);
  background: radial-gradient(circle at top, rgba(55, 65, 81, 0.8), rgba(15, 23, 42, 0.95));
}

.nv-dot-separator {
  opacity: 0.7;
}

/* Toast */
.nv-toast-container {
  position: fixed;
  left: 50%;
  bottom: 18px;
  transform: translateX(-50%);
  z-index: 50;
}

.nv-toast {
  background: linear-gradient(to right, #6366f1, #22d3ee);
  color: white;
  padding: 8px 14px;
  border-radius: 999px;
  font-size: 0.8rem;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  box-shadow: 0 10px 30px rgba(15, 23, 42, 0.8);
  animation: nv-toast-in 0.25s ease forwards;
}

.nv-toast i {
  font-size: 0.8rem;
}

/* Animations */
@keyframes nv-wave {
  0%,
  100% {
    height: 20%;
  }
  50% {
    height: 95%;
  }
}

@keyframes nv-toast-in {
  from {
    opacity: 0;
    transform: translate(-50%, 8px);
  }
  to {
    opacity: 1;
    transform: translate(-50%, 0);
  }
}

/* Responsive */
@media (max-width: 960px) {
  .nv-hero {
    grid-template-columns: minmax(0, 1fr);
  }

  .nv-hero-text {
    order: 1;
  }

  .nv-studio-card {
    order: 2;
  }

  .nv-feature-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 720px) {
  .nv-header {
    padding-inline: 16px;
  }

  .nv-nav {
    position: absolute;
    inset-inline: 16px;
    top: 56px;
    background: rgba(15, 23, 42, 0.98);
    border-radius: 14px;
    border: 1px solid rgba(148, 163, 184, 0.4);
    padding: 10px 12px;
    flex-direction: column;
    gap: 4px;
    transform-origin: top center;
    transform: scaleY(0.8);
    opacity: 0;
    pointer-events: none;
  }

  .nv-nav a {
    padding-block: 6px;
  }

  .nv-nav.nv-nav-open {
    opacity: 1;
    pointer-events: auto;
    transform: scaleY(1);
  }

  .nv-nav-toggle {
    display: block;
  }

  .nv-main {
    padding-inline: 16px;
  }

  .nv-actions {
    flex-direction: column-reverse;
    align-items: stretch;
  }

  .nv-actions-main {
    width: 100%;
  }

  .nv-actions-main .nv-btn {
    flex: 1;
  }

  .nv-feature-grid {
    grid-template-columns: minmax(0, 1fr);
  }
}

@media (max-width: 480px) {
  #nv-text {
    min-height: 140px;
  }

  .nv-studio-card {
    padding: 14px 12px;
  }

  .nv-section-header h2 {
    font-size: 1.05rem;
  }
}
