/* ===== Reset & Base ===== */
*,
*::before,
*::after {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

:root {
  --bg: #ffffff;
  --bg-secondary: #f8f9fc;
  --bg-card: #ffffff;
  --bg-card-hover: #f4f4f8;
  --border: #e5e7eb;
  --border-light: #d1d5db;
  --text: #1a1a2e;
  --text-muted: #4b5563;
  --text-dim: #9ca3af;
  --primary: #6366f1;
  --primary-bright: #818cf8;
  --primary-dim: #4f46e5;
  --gradient-start: #6366f1;
  --gradient-mid: #a855f7;
  --gradient-end: #ec4899;
  --radius: 12px;
  --radius-sm: 8px;
  --radius-lg: 20px;
  --shadow-sm: 0 1px 3px rgba(0, 0, 0, 0.06);
  --shadow: 0 4px 16px rgba(0, 0, 0, 0.06);
  --shadow-lg: 0 8px 32px rgba(0, 0, 0, 0.08);
  --shadow-xl: 0 16px 48px rgba(0, 0, 0, 0.1);
  --transition: 0.2s ease;
}

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

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

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

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

/* ===== Container ===== */
.container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 24px;
}

/* ===== Gradient Text ===== */
.gradient-text {
  background: linear-gradient(
    135deg,
    var(--gradient-start),
    var(--gradient-mid),
    var(--gradient-end)
  );
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
}

/* ===== Buttons ===== */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 12px 24px;
  border-radius: var(--radius);
  font-size: 15px;
  font-weight: 600;
  cursor: pointer;
  transition: all var(--transition);
  border: none;
  white-space: nowrap;
}

.btn-primary {
  background: linear-gradient(135deg, var(--primary-dim), var(--primary));
  color: white;
  box-shadow: 0 4px 20px rgba(99, 102, 241, 0.3);
}

.btn-primary:hover {
  box-shadow: 0 6px 30px rgba(99, 102, 241, 0.5);
  transform: translateY(-1px);
}

.btn-secondary {
  background: var(--bg-card);
  color: var(--text);
  border: 1px solid var(--border);
}

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

.btn-lg {
  padding: 16px 32px;
  font-size: 16px;
  border-radius: var(--radius-lg);
}

/* ===== Navigation ===== */
.nav {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  z-index: 100;
  padding: 16px 0;
  transition: all 0.3s ease;
  background: transparent;
}

.nav.scrolled {
  background: rgba(255, 255, 255, 0.85);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border-bottom: 1px solid var(--border);
  padding: 12px 0;
}

.nav-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.nav-logo {
  display: flex;
  align-items: center;
  gap: 10px;
  font-weight: 700;
  font-size: 18px;
}

.nav-logo-img {
  width: 32px;
  height: 32px;
  border-radius: 8px;
}

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

.nav-links a {
  font-size: 14px;
  color: var(--text-muted);
  transition: color var(--transition);
  font-weight: 500;
}

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

.nav-github {
  color: var(--text-muted) !important;
  transition: color var(--transition) !important;
}

.nav-github:hover {
  color: var(--text) !important;
}

.nav-toggle {
  display: none;
  flex-direction: column;
  gap: 5px;
  background: none;
  border: none;
  cursor: pointer;
  padding: 4px;
}

.nav-toggle span {
  display: block;
  width: 24px;
  height: 2px;
  background: var(--text-muted);
  border-radius: 2px;
  transition: all var(--transition);
}

/* ===== Hero ===== */
.hero {
  position: relative;
  padding: 160px 0 80px;
  text-align: center;
  overflow: hidden;
  background-image: radial-gradient(
    circle,
    rgba(99, 102, 241, 0.045) 1px,
    transparent 1px
  );
  background-size: 28px 28px;
}

.hero-glow {
  position: absolute;
  top: -200px;
  left: 50%;
  transform: translateX(-50%);
  width: 900px;
  height: 500px;
  background: radial-gradient(
    ellipse,
    rgba(99, 102, 241, 0.1) 0%,
    rgba(168, 85, 247, 0.06) 40%,
    transparent 70%
  );
  pointer-events: none;
}

.hero-inner {
  position: relative;
}

.hero-badge {
  display: inline-block;
  padding: 8px 20px;
  border-radius: 100px;
  font-size: 13px;
  font-weight: 600;
  color: var(--primary);
  background: rgba(99, 102, 241, 0.08);
  border: 1px solid rgba(99, 102, 241, 0.15);
  margin-bottom: 32px;
  letter-spacing: 0.5px;
}

.hero-title {
  font-size: clamp(40px, 7vw, 72px);
  font-weight: 800;
  line-height: 1.1;
  letter-spacing: -0.03em;
  margin-bottom: 24px;
}

.hero-subtitle {
  max-width: 600px;
  margin: 0 auto 40px;
  font-size: 18px;
  color: var(--text-muted);
  line-height: 1.7;
}

.hero-actions {
  display: flex;
  gap: 16px;
  justify-content: center;
  flex-wrap: wrap;
  margin-bottom: 40px;
}

/* ===== Hero Stats ===== */
.hero-stats {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 40px;
  margin-bottom: 72px;
}

.hero-stat {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 4px;
}

.hero-stat-num {
  font-size: 24px;
  font-weight: 800;
  letter-spacing: -0.04em;
  background: linear-gradient(
    135deg,
    var(--gradient-start),
    var(--gradient-mid)
  );
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
}

.hero-stat-label {
  font-size: 12px;
  font-weight: 500;
  color: var(--text-dim);
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

.hero-stat-sep {
  width: 1px;
  height: 32px;
  background: var(--border);
}

/* Hero entrance animations */
.hero-badge {
  animation: fadeInUp 0.6s ease 0s backwards;
}
.hero-title {
  animation: fadeInUp 0.6s ease 0.1s backwards;
}
.hero-subtitle {
  animation: fadeInUp 0.6s ease 0.2s backwards;
}
.hero-actions {
  animation: fadeInUp 0.6s ease 0.3s backwards;
}
.hero-stats {
  animation: fadeInUp 0.6s ease 0.4s backwards;
}
.hero-screenshot {
  animation: fadeInUp 0.7s ease 0.5s backwards;
}

/* ===== Screenshot Carousel ===== */
.hero-screenshot {
  max-width: 100%;
  margin: 0 auto;
}

.carousel {
  position: relative;
  border-radius: var(--radius-lg);
  overflow: hidden;
  box-shadow:
    var(--shadow-xl),
    0 0 0 1px var(--border);
  aspect-ratio: 2568 / 1554;
  max-height: 560px;
  margin: 0 auto;
}

.carousel:hover .carousel-btn {
  opacity: 1;
}

.carousel-track {
  display: flex;
  transition: transform 0.5s cubic-bezier(0.4, 0, 0.2, 1);
  will-change: transform;
  height: 100%;
}

.carousel-slide {
  min-width: 100%;
  flex-shrink: 0;
}

.carousel-slide img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.carousel-btn {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  width: 40px;
  height: 40px;
  border-radius: 50%;
  border: none;
  background: rgba(255, 255, 255, 0.85);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  box-shadow: var(--shadow);
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--text);
  opacity: 0;
  transition:
    opacity 0.25s ease,
    background 0.2s ease;
  z-index: 2;
}

.carousel:hover .carousel-btn {
  opacity: 1;
}

.carousel-btn:hover {
  background: rgba(255, 255, 255, 1);
}

.carousel-btn-prev {
  left: 12px;
}

.carousel-btn-next {
  right: 12px;
}

.carousel-dots {
  position: absolute;
  bottom: 16px;
  left: 50%;
  transform: translateX(-50%);
  display: flex;
  gap: 8px;
  z-index: 2;
}

.carousel-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  border: none;
  background: rgba(255, 255, 255, 0.5);
  cursor: pointer;
  padding: 0;
  transition: all 0.25s ease;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.2);
}

.carousel-dot.active {
  background: rgba(255, 255, 255, 0.95);
  transform: scale(1.25);
}

/* ===== Section Styling ===== */
.section-header {
  text-align: center;
  margin-bottom: 64px;
}

.section-title {
  font-size: clamp(32px, 5vw, 48px);
  font-weight: 800;
  line-height: 1.15;
  letter-spacing: -0.03em;
  margin-bottom: 16px;
}

.section-subtitle {
  font-size: 17px;
  color: var(--text-muted);
  max-width: 500px;
  margin: 0 auto;
}

.section-badge {
  display: inline-block;
  padding: 6px 16px;
  border-radius: 100px;
  font-size: 13px;
  font-weight: 600;
  color: var(--primary);
  background: rgba(99, 102, 241, 0.08);
  border: 1px solid rgba(99, 102, 241, 0.15);
  margin-bottom: 20px;
}

/* ===== Features ===== */
.features,
.providers,
.extension {
  scroll-margin-top: 80px;
}

.features {
  padding: 100px 0;
  background: var(--bg-secondary);
}

.features-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 24px;
}

.feature-card {
  background: var(--bg-card);
  border: 1.5px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 32px;
  transition:
    border-color 0.3s ease,
    box-shadow 0.3s ease,
    transform 0.3s ease;
  position: relative;
  overflow: hidden;
}

.feature-card:hover {
  border-color: rgba(99, 102, 241, 0.4);
  transform: translateY(-3px);
  box-shadow:
    0 0 0 3px rgba(99, 102, 241, 0.08),
    0 8px 28px rgba(99, 102, 241, 0.1);
}

.feature-icon {
  width: 52px;
  height: 52px;
  border-radius: var(--radius);
  background: var(--bg-secondary);
  border: 1px solid var(--border);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--text-muted);
  margin-bottom: 20px;
  transition: transform 0.2s ease;
}

.feature-card:hover .feature-icon {
  transform: scale(1.05);
}

.feature-icon.icon-blue {
  color: #3b82f6;
  background: rgba(59, 130, 246, 0.08);
  border-color: rgba(59, 130, 246, 0.15);
}
.feature-icon.icon-amber {
  color: #f59e0b;
  background: rgba(245, 158, 11, 0.08);
  border-color: rgba(245, 158, 11, 0.15);
}
.feature-icon.icon-teal {
  color: #0d9488;
  background: rgba(13, 148, 136, 0.08);
  border-color: rgba(13, 148, 136, 0.15);
}
.feature-icon.icon-green {
  color: #16a34a;
  background: rgba(22, 163, 74, 0.08);
  border-color: rgba(22, 163, 74, 0.15);
}
.feature-icon.icon-violet {
  color: #7c3aed;
  background: rgba(124, 58, 237, 0.08);
  border-color: rgba(124, 58, 237, 0.15);
}

.feature-card h3 {
  font-size: 18px;
  font-weight: 700;
  margin-bottom: 10px;
  transition: color 0.25s ease;
}

.feature-card:hover h3 {
  color: var(--primary-dim);
}

.feature-card p {
  font-size: 14px;
  color: var(--text-muted);
  line-height: 1.7;
}

/* ===== Featured (Memory) Card ===== */
.featured-icon {
  background: linear-gradient(135deg, var(--primary), #a855f7) !important;
  color: white !important;
  border-color: transparent !important;
}

/* ===== Providers ===== */
.providers {
  padding: 100px 0;
}

.providers-logos {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 40px 48px;
  margin-bottom: 48px;
  padding: 0 24px;
}

.provider-item {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 10px;
  cursor: default;
}

.provider-item:hover .provider-logo {
  transform: translateY(-3px) scale(1.08);
  box-shadow: 0 6px 20px rgba(0, 0, 0, 0.1);
}

.provider-logo {
  width: 56px;
  height: 56px;
  border-radius: 16px;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  transition:
    transform 0.25s ease,
    box-shadow 0.25s ease;
}

.provider-logo svg {
  width: 26px;
  height: 26px;
}

.provider-logo.anthropic {
  color: #d97757;
  background: rgba(217, 119, 87, 0.12);
}
.provider-logo.openai {
  color: #10a37f;
  background: rgba(16, 163, 127, 0.12);
}
.provider-logo.google {
  color: #4285f4;
  background: rgba(66, 133, 244, 0.12);
}
.provider-logo.deepseek {
  color: #4d6bfe;
  background: rgba(77, 107, 254, 0.12);
}
.provider-logo.grok {
  color: #1a1a1a;
  background: rgba(0, 0, 0, 0.07);
}
.provider-logo.qwen {
  color: #6c5ce7;
  background: rgba(108, 92, 231, 0.12);
}
.provider-logo.kimi {
  color: #10b981;
  background: rgba(16, 185, 129, 0.12);
}
.provider-logo.openrouter {
  color: #7c3aed;
  background: rgba(124, 58, 237, 0.12);
}
.provider-logo.custom {
  color: var(--primary);
  background: rgba(99, 102, 241, 0.1);
  border: 1.5px dashed rgba(99, 102, 241, 0.35);
}

.provider-label {
  font-size: 13px;
  font-weight: 600;
  color: var(--text-muted);
  transition: color 0.2s ease;
}

.provider-item:hover .provider-label {
  color: var(--text);
}

.providers-note {
  text-align: center;
  font-size: 14px;
  color: var(--text-dim);
}

/* ===== Extension ===== */
.extension {
  padding: 100px 0;
  background: var(--bg-secondary);
}

.extension-layout {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 80px;
  align-items: center;
}

.extension-desc {
  font-size: 16px;
  color: var(--text-muted);
  line-height: 1.8;
  margin-bottom: 32px;
}

.extension-platforms {
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
  margin-bottom: 28px;
}

.extension-actions {
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
}

.ext-platform {
  padding: 8px 20px;
  border-radius: 100px;
  background: var(--bg-card);
  border: 1px solid var(--border);
  font-size: 14px;
  font-weight: 500;
  color: var(--text-muted);
  transition:
    border-color var(--transition),
    color var(--transition);
  cursor: default;
}

.ext-platform:hover {
  border-color: rgba(99, 102, 241, 0.4);
  color: var(--primary);
}

/* Browser mockup */
.ext-browser {
  background: var(--bg-card);
  border-radius: var(--radius-lg);
  border: 1px solid var(--border);
  overflow: hidden;
  box-shadow: var(--shadow);
}

.ext-toolbar {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 12px 16px;
  background: var(--bg-secondary);
  border-bottom: 1px solid var(--border);
}

.ext-dots {
  display: flex;
  gap: 6px;
}

.ext-url {
  flex: 1;
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 6px 14px;
  background: var(--bg);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  font-size: 13px;
  color: var(--text-dim);
}

.ext-badge {
  opacity: 0.7;
}

.ext-content {
  padding: 40px 30px;
  display: flex;
  justify-content: center;
}

.ext-popup {
  width: 260px;
  background: var(--bg);
  border-radius: var(--radius);
  overflow: hidden;
  box-shadow:
    var(--shadow-lg),
    0 0 0 1px var(--border);
}

.ext-popup-header {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 14px 16px;
  border-bottom: 1px solid var(--border);
  font-size: 14px;
  font-weight: 600;
}

.ext-popup-body {
  padding: 16px;
  display: flex;
  flex-direction: column;
  gap: 14px;
}

.ext-popup-item {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 13px;
  color: var(--text-muted);
}

.ext-popup-btn {
  padding: 10px;
  text-align: center;
  background: linear-gradient(135deg, var(--primary-dim), var(--primary));
  border-radius: var(--radius-sm);
  font-size: 13px;
  font-weight: 600;
  color: white;
}

/* ===== CTA ===== */
.cta {
  padding: 100px 0;
  position: relative;
}

.cta-inner {
  position: relative;
  text-align: center;
  padding: 80px 40px;
  background: linear-gradient(135deg, #f5f3ff 0%, #ede9fe 50%, #e0e7ff 100%);
  border: 1px solid rgba(99, 102, 241, 0.15);
  border-radius: 28px;
  overflow: hidden;
}

.cta-glow {
  position: absolute;
  top: -50%;
  left: 50%;
  transform: translateX(-50%);
  width: 600px;
  height: 400px;
  background: radial-gradient(
    ellipse,
    rgba(99, 102, 241, 0.12) 0%,
    transparent 70%
  );
  pointer-events: none;
}

.cta-title {
  font-size: clamp(28px, 4vw, 44px);
  font-weight: 800;
  line-height: 1.15;
  letter-spacing: -0.03em;
  margin-bottom: 16px;
  position: relative;
}

.cta-subtitle {
  font-size: 17px;
  color: var(--text-muted);
  margin-bottom: 40px;
  position: relative;
}

.cta-actions {
  display: flex;
  gap: 16px;
  justify-content: center;
  flex-wrap: wrap;
  position: relative;
}

/* ===== Footer ===== */
.footer {
  padding: 32px 0;
  border-top: 1px solid var(--border);
}

.footer-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
}

.footer-left {
  display: flex;
  align-items: center;
  gap: 10px;
  font-weight: 600;
  font-size: 15px;
}

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

.footer-nav a {
  font-size: 13px;
  color: var(--text-dim);
  font-weight: 500;
  transition: color var(--transition);
}

.footer-nav a:hover {
  color: var(--text-muted);
}

.footer-right {
  font-size: 13px;
  color: var(--text-dim);
}

/* ===== Animations ===== */
@keyframes fadeInUp {
  from {
    opacity: 0;
    transform: translateY(30px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.fade-in {
  opacity: 0;
  transform: translateY(30px);
  transition:
    opacity 0.6s ease,
    transform 0.6s ease;
}

.fade-in.visible {
  opacity: 1;
  transform: translateY(0);
}

/* ===== Responsive ===== */
@media (max-width: 1024px) {
  .features-grid {
    grid-template-columns: repeat(2, 1fr);
  }

  .extension-layout {
    grid-template-columns: 1fr;
    gap: 40px;
  }

  .extension-content {
    text-align: center;
  }

  .extension-content .section-title {
    text-align: center;
  }

  .extension-platforms {
    justify-content: center;
  }
}

@media (max-width: 768px) {
  .nav-links {
    display: none;
    position: absolute;
    top: 100%;
    left: 0;
    width: 100%;
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border-bottom: 1px solid var(--border);
    padding: 20px 24px;
    flex-direction: column;
    gap: 16px;
    align-items: flex-start;
  }

  .nav-links.open {
    display: flex;
  }

  .nav-toggle {
    display: flex;
  }

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

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

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

  .hero-stats {
    gap: 24px;
  }

  .carousel-btn {
    width: 32px;
    height: 32px;
  }

  .cta-inner {
    padding: 48px 24px;
  }

  .footer-inner {
    flex-direction: column;
    gap: 16px;
    text-align: center;
  }

  .footer-nav {
    gap: 20px;
  }

  .providers-logos {
    gap: 28px 36px;
  }

  .provider-logo {
    width: 44px;
    height: 44px;
  }

  .provider-logo svg {
    width: 22px;
    height: 22px;
  }
}

@media (max-width: 480px) {
  .hero-actions {
    flex-direction: column;
    align-items: center;
  }

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

