/* ─── Reset & Base ─── */

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

html {
  scroll-behavior: smooth;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

body {
  font-family: "Inter", -apple-system, BlinkMacSystemFont, "SF Pro Text",
    "Segoe UI", system-ui, sans-serif;
  background: #09090f;
  color: #e4e4ef;
  line-height: 1.6;
}

::selection {
    background: #a79efc;
    color: #000;
}

::-moz-selection {
    background: #a79efc;
    color: #000;
}

a {
  color: inherit;
  text-decoration: none;
}

code {
  font-family: "SF Mono", "Fira Code", "Cascadia Code", monospace;
  font-size: 0.88em;
  background: #00c72a1a;
  padding: 0.15em 0.4em;
  border-radius: 4px;
  color: #fff;
}

img {
  display: block;
  max-width: 100%;
}

/* ─── Utilities ─── */

.container {
  max-width: 1080px;
  margin: 0 auto;
  padding: 0 24px;
}

.section-title-wrapper {
  position: relative;
}

.section-title {
  font-size: 2rem;
  font-weight: 700;
  text-align: center;
  letter-spacing: -0.03em;
  margin-bottom: 8px;

  margin: 0;
  width: fit-content;
  left: 50%;
  transform: translateX(-50%);
  padding: 0 24px;
  background: #09090f;
  z-index: 2;
  position: relative;
}
.section-title::after {
  content: "";
  width: 72%;
  margin: 0 auto;
  height: 19px;
  display: block;
  position: absolute;
  left: 50%;
  top: 36%;
  transform: translate(-50%) rotate(-4deg);
  z-index: 1;
  background: linear-gradient(to right, transparent, #ffffff3b, transparent);
}
.section-title-line {
  content: "";
  width: 100%;
  margin: 0 auto;
  height: 3px;
  display: block;
  position: absolute;
  left: 50%;
  top: 50%;
  transform: translate(-50%);
  z-index: 1;
  background: linear-gradient(to right, transparent, #8577ff70, #8577ff70, transparent);
}

.section-subtitle {
  text-align: center;
  color: #858596;
  font-size: 1.05rem;
  margin: 32px 0;
}

/* ─── Buttons ─── */

.btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 12px 24px;
  border-radius: 10px;
  font-weight: 600;
  font-size: 0.95rem;
  transition: background 0.2s ease, box-shadow 0.2s ease;
  cursor: pointer;
  border: none;
}

.btn-primary {
  background: #7c6ef0;
  color: #fff;
}

.btn-primary:hover {
  background: #9186f3;
  box-shadow: 0 8px 30px rgba(124, 110, 240, 0.3);
}

.btn-secondary {
  background: rgba(255, 255, 255, 0.06);
  color: #e4e4ef;
  border: 1px solid rgba(255, 255, 255, 0.08);
}

.btn-secondary:hover {
  background: rgba(255, 255, 255, 0.1);
}

/* ─── Nav ─── */

.nav {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 100;
  backdrop-filter: blur(20px) saturate(180%);
  -webkit-backdrop-filter: blur(20px) saturate(180%);
  background: rgba(9, 9, 15, 0.75);
  border-bottom: 1px solid rgba(255, 255, 255, 0.04);
}

.nav-inner {
  max-width: 1080px;
  margin: 0 auto;
  padding: 0 24px;
  height: 60px;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.nav-logo {
  display: flex;
  align-items: flex-start;
  font-weight: 700;
  font-size: 1.1rem;
  letter-spacing: -0.02em;
  color: #e4e4ef;
}

.nav-icon {
  margin-top: 4px;
  margin-left: -6px;
}

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

.nav-links a {
  font-size: 0.88rem;
  color: #858596;
  font-weight: 500;
  transition: color 0.2s;
}

.nav-links a:hover {
  color: #e4e4ef;
}

.nav-link-docs {
  display: inline-flex;
  align-items: center;
  gap: 6px;
}

/* ─── Hero ─── */

.hero {
  position: relative;
  padding: 160px 0 80px;
  text-align: center;
  overflow: hidden;
}

.hero-glow {
  position: absolute;
  top: 0;
  left: 50%;
  transform: translateX(-50%);
  width: 800px;
  height: 500px;
  background: radial-gradient(
    ellipse at center,
    rgba(124, 110, 240, 0.12) 0%,
    transparent 70%
  );
  pointer-events: none;
}

.hero-badges {
  display: flex;
  justify-content: center;
  gap: 10px;
  margin-bottom: 28px;
  flex-wrap: wrap;
}

.hero-badge {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 6px 12px;
  border-radius: 100px;
  background: rgba(124, 110, 240, 0.1);
  border: 1px solid rgba(124, 110, 240, 0.2);
  font-size: 0.82rem;
  font-weight: 500;
  color: #b4a8f8;
}

.hero-badge-icon {
  width: 24px;
}
.hero-badge-icon-wide {
  width: 42px;
}

.hero-title {
  font-size: 3.6rem;
  font-weight: 800;
  letter-spacing: -0.04em;
  line-height: 1.1;
  margin-bottom: 20px;
  background: linear-gradient(180deg, #ffffff 40%, #858596 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.hero-subtitle {
  font-size: 1.15rem;
  color: #858596;
  max-width: 600px;
  margin: 0 auto 40px;
  line-height: 1.7;
}

.hero-actions {
  display: flex;
  gap: 12px;
  justify-content: center;
  flex-wrap: wrap;
}

/* ─── Preview Window ─── */

.preview {
  padding: 0 0 64px;
}

.preview-caption {
  text-align: center;
  color: #858596;
  font-size: 0.95rem;
  max-width: 640px;
  margin: 0 auto 24px;
  line-height: 1.6;
}

.preview-window {
  border-radius: 14px;
  border: 1px solid rgba(255, 255, 255, 0.06);
  background: #111118;
  overflow: hidden;
  box-shadow: 0 24px 80px rgba(0, 0, 0, 0.5), 0 0 0 1px rgba(255, 255, 255, 0.03);
}

.preview-bar {
  display: flex;
  align-items: center;
  gap: 7px;
  padding: 12px 16px;
  background: #16161e;
  border-bottom: 1px solid rgba(255, 255, 255, 0.04);
}

.preview-dot {
  width: 11px;
  height: 11px;
  border-radius: 50%;
}

.preview-dot.red { background: #ff5f57; }
.preview-dot.yellow { background: #febc2e; }
.preview-dot.green { background: #28c840; }

.preview-bar-title {
  margin-left: 8px;
  font-size: 0.78rem;
  color: #858596;
  font-weight: 500;
}

.preview-body {
  padding: 8px 24px;
  overflow-x: auto;
  max-height: 380px;
  overflow-y: auto;
  flex: 1;
}

.preview-body pre {
  font-family: "SF Mono", "Fira Code", "Cascadia Code", monospace;
  font-size: 0.82rem;
  line-height: 1.7;
  color: #aeaec4;
  white-space: pre-wrap;
  word-break: break-word;
}

.preview-body .md-h1 {
  color: #e4e4ef;
  font-weight: 700;
  font-size: 1rem;
}

.preview-body .md-h2 {
  color: #e4e4ef;
  font-weight: 600;
}

.preview-body .md-meta {
  color: #858596;
}

.preview-body .md-hr {
  color: #5e5e64;
}

.preview-body .md-attach {
  color: #00d9ff;
}

.preview-body .md-model {
  color: #858596;
  font-style: italic;
}

.preview-body .md-tool {
  color: #4ade80;
}

.preview-body .md-err {
  color: #f87171;
}

.preview-body .md-warn {
  color: #fbbf24;
}

/* Scrollbar */
.preview-body::-webkit-scrollbar {
  width: 6px;
}

.preview-body::-webkit-scrollbar-track {
  background: transparent;
}

.preview-body::-webkit-scrollbar-thumb {
  background: rgba(255, 255, 255, 0.08);
  border-radius: 3px;
}

/* ─── File Tree Preview ─── */

.preview-filetree {
  margin-top: 20px;
}

.preview-window-sm {
  max-width: 480px;
  margin-left: auto;
}

.filetree-body {
  padding: 14px 16px;
  font-family: "SF Mono", "Fira Code", "Cascadia Code", monospace;
  font-size: 0.8rem;
  line-height: 1.3;
  max-width: 30%;
  border-right: 1px solid #333333;
}

.ft-row {
  display: flex;
  padding: 3px 4px;
  border-radius: 4px;
}

.ft-row-new {
  background: rgba(74, 222, 128, 0.08);
}

.ft-indent {
  display: inline-block;
  width: 0;
}

.ft-indent.i1 { width: 18px; }
.ft-indent.i2 { width: 36px; }

.ft-icon {
  margin-right: 4px;
  font-size: 0.75rem;
  flex-shrink: 0;
}

.ft-folder, .ft-folder-open {
  color: #858596;
}

.ft-file {
  font-size: 0;
}

.ft-name {
  color: #aeaec4;
  text-overflow: ellipsis;
  white-space: nowrap;
  overflow: hidden;
}

.ft-name-contrails {
  color: #7c6ef0;
  font-weight: 600;
}

.ft-name-new {
  color: #4ade80;
  font-weight: 500;
}

.ft-name.ft-dim {
  color: #555566;
}

/* ─── Features ─── */

.features {
  padding: 64px 0;
}

.features-grid {
    display: flex;
    flex-wrap: wrap;
    gap: 20px;
    justify-content: center;
}

.feature-card {
  padding: 28px;
  border-radius: 14px;
  background: linear-gradient(135deg, rgb(255 255 255 / 8%), transparent);
  border: 1px solid rgba(255, 255, 255, 0.05);
  width: calc(100% / 2 - 10px);
  box-shadow: 7px 7px 6px -9px;
}

.feature-icon {
  width: 44px;
  height: 44px;
  border-radius: 10px;
  background: rgba(124, 110, 240, 0.1);
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 16px;
  color: #7c6ef0;
}

.feature-card h3 {
  font-size: 1rem;
  font-weight: 600;
  margin-bottom: 8px;
  letter-spacing: -0.01em;
  color: #fff
}

.feature-card p {
  font-size: 0.88rem;
  color: #858596;
  line-height: 1.6;
}

/* ─── How It Works ─── */

.how-it-works {
  padding: 64px 0;
}

.steps-row {
  display: flex;
  justify-content: center;
  gap: 0;
}

.step-card {
  flex: 1;
  max-width: 300px;
  padding: 32px 28px;
  border-radius: 16px;
  background: linear-gradient(to bottom, rgb(80 119 255 / 12%), transparent);
  border: 1px solid #7c6ef04f;
}

.step-card-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 20px;
}

.step-card-num {
  font-size: 2rem;
  font-weight: 800;
  color: rgba(124, 110, 240, 0.5);
  letter-spacing: -0.03em;
  line-height: 1;
  width: 100%;
  text-align: right;
}

.step-card h3 {
  font-size: 1.05rem;
  font-weight: 600;
  margin-bottom: 8px;
  letter-spacing: -0.01em;
}

.step-card p {
  font-size: 0.88rem;
  color: #858596;
  line-height: 1.65;
}

.step-arrow {
  flex-shrink: 0;
  color: rgba(124, 110, 240, 0.5);
  padding: 0 8px;
  align-self: center;
}

/* ─── Use Cases ─── */

.use-cases {
  padding: 64px 0;
}

.use-cases-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 20px;
}

.use-case-card {
  padding: 28px 24px;
  border-radius: 14px;
  background: linear-gradient(135deg, rgb(255 255 255 / 8%), transparent);
  border: 1px solid rgba(255, 255, 255, 0.05);
  text-align: center;
  box-shadow: 7px 7px 6px -9px;
}

.use-case-emoji {
  font-size: 1.8rem;
  margin-bottom: 14px;
}

.use-case-card h3 {
  font-size: 0.95rem;
  font-weight: 600;
  margin-bottom: 8px;
  letter-spacing: -0.01em;
  color: #fff;
}

.use-case-card p {
  font-size: 0.85rem;
  color: #858596;
  line-height: 1.6;
}

/* ─── Coming Soon ─── */

.coming-soon {
  padding: 64px 0;
}

.agents-grid {
  display: flex;
  justify-content: center;
  gap: 24px;
  flex-wrap: wrap;
}

.agent-card {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 12px;
  padding: 36px 48px;
  border-radius: 16px;
  background: linear-gradient(135deg, rgb(255 255 255 / 8%), transparent);
  border: 1px solid rgba(255, 255, 255, 0.05);
  min-width: 180px;
}

.agent-icon {
  width: 48px;
  height: 48px;
  object-fit: contain;
  border-radius: 10px;
}

.agent-icon-wide {
  width: 72px;
  height: 48px;
}

.agent-name {
  font-weight: 600;
  font-size: 0.95rem;
  letter-spacing: -0.01em;
}

.agent-badge {
  font-size: 0.72rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  padding: 4px 10px;
  border-radius: 100px;
  background: rgba(251, 191, 36, 0.1);
  color: #fbbf24;
  border: 1px solid rgba(251, 191, 36, 0.2);
}

.agent-badge-supported {
  background: rgba(52, 211, 153, 0.1);
  color: #34d399;
  border-color: rgba(52, 211, 153, 0.2);
}

/* ─── CTA ─── */

.cta {
  padding: 64px 0;
  text-align: center;
  position: relative;
  overflow: hidden;
}

.cta::before {
  content: "";
  position: absolute;
  top: 0;
  left: 50%;
  transform: translateX(-50%);
  width: 600px;
  height: 400px;
  background: radial-gradient(
    ellipse at center,
    rgba(124, 110, 240, 0.08) 0%,
    transparent 70%
  );
  pointer-events: none;
}

.cta-title {
  font-size: 2.2rem;
  font-weight: 700;
  letter-spacing: -0.03em;
  margin-bottom: 12px;
}

.cta-subtitle {
  color: #858596;
  font-size: 1.05rem;
  margin-bottom: 36px;
}

/* ─── Footer ─── */

.footer {
  border-top: 1px solid rgba(255, 255, 255, 0.04);
  padding: 24px 0;
}

.footer-disclaimer p {
  font-size: 0.75rem;
  color: #555566;
  line-height: 1.6;
  text-align: center;
}

/* ─── Responsive ─── */

@media (max-width: 900px) {
  .hero-title {
    font-size: 2.6rem;
  }

  .use-cases-grid {
    grid-template-columns: repeat(2, 1fr);
  }

    .steps-row {
    flex-direction: column;
    gap: 16px;
  }

  .step-card {
    max-width: 100%;
  }

  .step-arrow {
    transform: rotate(90deg);
    padding: 0;
  }
}

@media (max-width: 640px) {
  .filetree-body {
    display: none;
  }

  .nav-links a:not(.nav-link-docs) {
    display: none;
  }

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

  .hero-title {
    font-size: 2rem;
  }

  .hero-subtitle {
    font-size: 1rem;
  }

    .feature-card {
        width: 100%;
    }

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

  .agents-grid {
    flex-direction: column;
    align-items: center;
  }

  .agent-card {
    width: 100%;
    max-width: 280px;
  }

  .section-title {
    font-size: 1.6rem;
  }

  .cta-title {
    font-size: 1.7rem;
  }

  .hero-actions {
    flex-direction: column;
    align-items: center;
  }
}
