/* ========================================
   Reset & Base Styles
   ======================================== */

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

:root {
  /* Colors */
  --bg-primary: #0a0a0f;
  --bg-secondary: #13131a;
  --bg-tertiary: #1a1a24;
  --bg-code: #0d0d12;

  --text-primary: #f5f5f7;
  --text-secondary: #a1a1aa;
  --text-tertiary: #71717a;

  --purple-500: #8b5cf6;
  --purple-600: #7c3aed;
  --blue-500: #3b82f6;
  --blue-600: #2563eb;

  --border-color: rgba(255, 255, 255, 0.1);
  --border-hover: rgba(139, 92, 246, 0.3);

  /* Spacing */
  --container-width: 1200px;
  --section-padding: 120px 0;

  /* Transitions */
  --transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

html {
  scroll-behavior: smooth;
}

body {
  font-family: "Inter", -apple-system, BlinkMacSystemFont, "Segoe UI",
    sans-serif;
  background: var(--bg-primary);
  color: var(--text-primary);
  line-height: 1.7;
  overflow-x: hidden;
}

code,
pre {
  font-family: "JetBrains Mono", "Fira Code", monospace;
}

::selection {
  background: var(--purple-500);
  color: white;
}

/* ========================================
   Container & Layout
   ======================================== */

.container {
  max-width: var(--container-width);
  margin: 0 auto;
  padding: 0 24px;
}

/* ========================================
   Navigation
   ======================================== */

.nav {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 1000;
  background: rgba(10, 10, 15, 0.8);
  backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--border-color);
}

.nav-content {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 20px 0;
}

.logo {
  display: flex;
  align-items: center;
  gap: 12px;
  text-decoration: none;
  color: var(--text-primary);
  font-weight: 700;
  font-size: 20px;
  transition: var(--transition);
}

.logo:hover {
  opacity: 0.8;
}

.nav-links {
  display: flex;
  align-items: center;
  gap: 32px;
}

.nav-links a {
  color: var(--text-secondary);
  text-decoration: none;
  font-weight: 500;
  font-size: 15px;
  transition: var(--transition);
}

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

.btn-secondary {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 8px 16px;
  background: var(--bg-tertiary);
  border: 1px solid var(--border-color);
  border-radius: 8px;
  color: var(--text-primary) !important;
  transition: var(--transition);
}

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

/* ========================================
   Hero Section
   ======================================== */

.hero {
  padding: 160px 0 120px;
  position: relative;
  overflow: hidden;
}

.hero::before {
  content: "";
  position: absolute;
  top: -50%;
  left: 50%;
  transform: translateX(-50%);
  width: 1400px;
  height: 1400px;
  background: radial-gradient(
    circle,
    rgba(139, 92, 246, 0.15) 0%,
    transparent 70%
  );
  pointer-events: none;
}

.hero-content {
  position: relative;
  z-index: 1;
  text-align: center;
}

.badge {
  display: inline-block;
  padding: 8px 16px;
  background: rgba(139, 92, 246, 0.1);
  border: 1px solid rgba(139, 92, 246, 0.2);
  border-radius: 20px;
  color: var(--purple-500);
  font-size: 14px;
  font-weight: 500;
  margin-bottom: 32px;
}

.hero-title {
  font-size: 72px;
  font-weight: 800;
  line-height: 1.1;
  margin-bottom: 24px;
  letter-spacing: -0.02em;
}

.gradient-text {
  background: linear-gradient(
    135deg,
    var(--purple-500) 0%,
    var(--blue-500) 100%
  );
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.hero-subtitle {
  font-size: 20px;
  color: var(--text-secondary);
  max-width: 800px;
  margin: 0 auto 48px;
  line-height: 1.6;
}

.hero-buttons {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 16px;
  margin-bottom: 80px;
}

.btn-primary {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 16px 32px;
  background: linear-gradient(
    135deg,
    var(--purple-600) 0%,
    var(--blue-600) 100%
  );
  color: white;
  text-decoration: none;
  font-weight: 600;
  font-size: 16px;
  border-radius: 12px;
  transition: var(--transition);
  border: none;
  cursor: pointer;
}

.btn-primary:hover {
  transform: translateY(-2px);
  box-shadow: 0 12px 24px rgba(139, 92, 246, 0.3);
}

.btn-outline {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 16px 32px;
  background: transparent;
  color: var(--text-primary);
  text-decoration: none;
  font-weight: 600;
  font-size: 16px;
  border: 2px solid var(--border-color);
  border-radius: 12px;
  transition: var(--transition);
}

.btn-outline:hover {
  border-color: var(--border-hover);
  background: rgba(139, 92, 246, 0.05);
}

/* ========================================
   Code Demo
   ======================================== */

.code-demo {
  max-width: 900px;
  margin: 0 auto;
}

.code-window {
  background: var(--bg-code);
  border: 1px solid var(--border-color);
  border-radius: 12px;
  overflow: hidden;
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.4);
}

.code-header {
  display: flex;
  align-items: center;
  padding: 16px;
  background: rgba(255, 255, 255, 0.03);
  border-bottom: 1px solid var(--border-color);
}

.code-dots {
  display: flex;
  gap: 8px;
}

.code-dots span {
  width: 12px;
  height: 12px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.2);
}

.code-dots span:nth-child(1) {
  background: #ff5f57;
}
.code-dots span:nth-child(2) {
  background: #febc2e;
}
.code-dots span:nth-child(3) {
  background: #28c840;
}

.code-title {
  flex: 1;
  text-align: center;
  color: var(--text-tertiary);
  font-size: 14px;
  font-weight: 500;
}

.code-content {
  padding: 32px;
  overflow-x: auto;
}

.code-content pre {
  margin: 0;
}

.code-content code {
  font-size: 15px;
  line-height: 1.8;
  color: var(--text-primary);
}

.comment {
  color: #6b7280;
}
.command {
  color: #8b5cf6;
  font-weight: 600;
}
.string {
  color: #10b981;
}
.key {
  color: #3b82f6;
}

/* ========================================
   Section Headers
   ======================================== */

.section-header {
  text-align: center;
  margin-bottom: 80px;
}

.section-header h2 {
  font-size: 48px;
  font-weight: 800;
  margin-bottom: 16px;
  letter-spacing: -0.02em;
}

.section-header p {
  font-size: 20px;
  color: var(--text-secondary);
}

/* ========================================
   Features Section
   ======================================== */

.features {
  padding: var(--section-padding);
  background: var(--bg-secondary);
}

.features-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
  gap: 32px;
}

.feature-card {
  padding: 32px;
  background: var(--bg-tertiary);
  border: 1px solid var(--border-color);
  border-radius: 16px;
  transition: var(--transition);
}

.feature-card:hover {
  border-color: var(--border-hover);
  transform: translateY(-4px);
  box-shadow: 0 12px 24px rgba(0, 0, 0, 0.3);
}

.feature-icon {
  width: 48px;
  height: 48px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: linear-gradient(
    135deg,
    var(--purple-500) 0%,
    var(--blue-500) 100%
  );
  border-radius: 12px;
  margin-bottom: 24px;
}

.feature-icon svg {
  color: white;
}

.feature-card h3 {
  font-size: 20px;
  font-weight: 700;
  margin-bottom: 12px;
}

.feature-card p {
  color: var(--text-secondary);
  line-height: 1.7;
}

/* ========================================
   Quickstart Section
   ======================================== */

.quickstart {
  padding: var(--section-padding);
}

.quickstart-steps {
  max-width: 800px;
  margin: 0 auto;
}

.step {
  display: flex;
  gap: 24px;
  margin-bottom: 48px;
  position: relative;
}

.step:not(:last-child)::after {
  content: "";
  position: absolute;
  left: 23px;
  top: 56px;
  bottom: -48px;
  width: 2px;
  background: linear-gradient(
    180deg,
    var(--purple-500) 0%,
    var(--blue-500) 100%
  );
  opacity: 0.3;
}

.step-number {
  flex-shrink: 0;
  width: 48px;
  height: 48px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: linear-gradient(
    135deg,
    var(--purple-600) 0%,
    var(--blue-600) 100%
  );
  border-radius: 12px;
  font-size: 20px;
  font-weight: 700;
  color: white;
}

.step-content {
  flex: 1;
}

.step-content h3 {
  font-size: 24px;
  font-weight: 700;
  margin-bottom: 16px;
}

.code-inline {
  position: relative;
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 16px 20px;
  background: var(--bg-code);
  border: 1px solid var(--border-color);
  border-radius: 8px;
  margin-bottom: 12px;
}

.code-inline code {
  flex: 1;
  font-size: 15px;
  color: var(--purple-500);
  overflow-x: auto;
}

.copy-btn {
  background: transparent;
  border: none;
  color: var(--text-tertiary);
  cursor: pointer;
  padding: 8px;
  border-radius: 6px;
  transition: var(--transition);
  display: flex;
  align-items: center;
  justify-content: center;
}

.copy-btn:hover {
  background: rgba(255, 255, 255, 0.05);
  color: var(--text-primary);
}

.copy-btn.copied {
  color: #10b981;
}

.step-detail {
  color: var(--text-secondary);
  font-size: 15px;
}

/* ========================================
   Use Cases Section
   ======================================== */

.use-cases {
  padding: var(--section-padding);
  background: var(--bg-secondary);
}

.use-cases-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(360px, 1fr));
  gap: 32px;
}

.use-case {
  padding: 32px;
  background: var(--bg-tertiary);
  border: 1px solid var(--border-color);
  border-radius: 16px;
  transition: var(--transition);
}

.use-case:hover {
  border-color: var(--border-hover);
  transform: translateY(-4px);
}

.use-case-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 16px;
}

.use-case h3 {
  font-size: 20px;
  font-weight: 700;
}

.use-case-tag {
  padding: 4px 12px;
  background: rgba(139, 92, 246, 0.1);
  border: 1px solid rgba(139, 92, 246, 0.2);
  border-radius: 12px;
  font-size: 12px;
  font-weight: 600;
  color: var(--purple-500);
}

.use-case > p {
  color: var(--text-secondary);
  margin-bottom: 24px;
}

.code-snippet {
  background: var(--bg-code);
  border: 1px solid var(--border-color);
  border-radius: 8px;
  padding: 20px;
  overflow-x: auto;
}

.code-snippet pre {
  margin: 0;
}

.code-snippet code {
  font-size: 14px;
  line-height: 1.8;
  color: var(--text-primary);
}

/* ========================================
   CTA Section
   ======================================== */

.cta {
  padding: var(--section-padding);
  position: relative;
  overflow: hidden;
}

.cta::before {
  content: "";
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  width: 1000px;
  height: 1000px;
  background: radial-gradient(
    circle,
    rgba(59, 130, 246, 0.1) 0%,
    transparent 70%
  );
  pointer-events: none;
}

.cta-content {
  position: relative;
  z-index: 1;
  text-align: center;
  max-width: 700px;
  margin: 0 auto;
}

.cta-content h2 {
  font-size: 48px;
  font-weight: 800;
  margin-bottom: 16px;
  letter-spacing: -0.02em;
}

.cta-content p {
  font-size: 20px;
  color: var(--text-secondary);
  margin-bottom: 40px;
}

.cta-buttons {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 16px;
}

/* ========================================
   Footer
   ======================================== */

.footer {
  background: var(--bg-secondary);
  border-top: 1px solid var(--border-color);
  padding: 80px 0 40px;
}

.footer-content {
  display: grid;
  grid-template-columns: 2fr 1fr 1fr 1fr;
  gap: 48px;
  margin-bottom: 48px;
}

.footer-logo {
  display: flex;
  align-items: center;
  gap: 12px;
  font-weight: 700;
  font-size: 20px;
  margin-bottom: 16px;
}

.footer-section p {
  color: var(--text-secondary);
  line-height: 1.7;
}

.footer-section h4 {
  font-size: 16px;
  font-weight: 700;
  margin-bottom: 16px;
}

.footer-section ul {
  list-style: none;
}

.footer-section ul li {
  margin-bottom: 12px;
}

.footer-section a {
  color: var(--text-secondary);
  text-decoration: none;
  transition: var(--transition);
}

.footer-section a:hover {
  color: var(--text-primary);
}

.footer-bottom {
  text-align: center;
  padding-top: 32px;
  border-top: 1px solid var(--border-color);
  color: var(--text-tertiary);
  font-size: 14px;
}

.footer-bottom p {
  margin-bottom: 8px;
}

.footer-bottom a {
  color: var(--purple-500);
  text-decoration: none;
}

.footer-bottom a:hover {
  text-decoration: underline;
}

/* ========================================
   Responsive Design
   ======================================== */

@media (max-width: 1024px) {
  .hero-title {
    font-size: 56px;
  }

  .section-header h2 {
    font-size: 40px;
  }

  .footer-content {
    grid-template-columns: 1fr 1fr;
  }
}

@media (max-width: 768px) {
  .nav-links {
    gap: 20px;
  }

  .nav-links a {
    font-size: 14px;
  }

  .hero {
    padding: 120px 0 80px;
  }

  .hero-title {
    font-size: 40px;
  }

  .hero-subtitle {
    font-size: 18px;
  }

  .hero-buttons {
    flex-direction: column;
    width: 100%;
  }

  .btn-primary,
  .btn-outline {
    width: 100%;
    justify-content: center;
  }

  .code-content {
    padding: 20px;
  }

  .code-content code {
    font-size: 13px;
  }

  .section-header h2 {
    font-size: 32px;
  }

  .section-header p {
    font-size: 16px;
  }

  .comparison-table th,
  .comparison-table td {
    padding: 10px 12px;
    font-size: 13px;
  }

  .comparison-table .check,
  .comparison-table .cross {
    font-size: 18px;
  }

  .comparison-note {
    font-size: 14px;
    padding: 0 20px;
  }

  .features-grid,
  .use-cases-grid {
    grid-template-columns: 1fr;
  }

  .footer-content {
    grid-template-columns: 1fr;
    gap: 32px;
  }

  .cta-content h2 {
    font-size: 32px;
  }

  .cta-buttons {
    flex-direction: column;
    width: 100%;
  }
}

@media (max-width: 480px) {
  .hero-title {
    font-size: 32px;
  }

  .code-inline {
    flex-direction: column;
    align-items: flex-start;
  }

  .code-inline code {
    width: 100%;
    word-break: break-all;
  }
}

/* ========================================
   Animations
   ======================================== */

@keyframes fadeInUp {
  from {
    opacity: 0;
    transform: translateY(20px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.hero-content > * {
  animation: fadeInUp 0.6s ease-out backwards;
}

.hero-content > *:nth-child(1) {
  animation-delay: 0.1s;
}
.hero-content > *:nth-child(2) {
  animation-delay: 0.2s;
}
.hero-content > *:nth-child(3) {
  animation-delay: 0.3s;
}
.hero-content > *:nth-child(4) {
  animation-delay: 0.4s;
}
.hero-content > *:nth-child(5) {
  animation-delay: 0.5s;
}
