*,
*::before,
*::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

:root {
  --bg: #080c18;
  --surface: #0f1628;
  --surface2: #161f38;
  --border: rgba(255, 255, 255, 0.07);
  --text: #e2e8f0;
  --muted: #64748b;
  --accent: #6366f1;
  --accent2: #8b5cf6;
  --green: #22d3a0;
  --orange: #f97316;
  --red: #f43f5e;
  --yellow: #facc15;
  --radius: 16px;
}

html {
  scroll-behavior: smooth;
}

body {
  font-family: "Inter", sans-serif;
  background: var(--bg);
  color: var(--text);
  min-height: 100vh;
  overflow-x: hidden;
}

body::before {
  content: "";
  position: fixed;
  inset: 0;
  background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 200 200' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='4' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)' opacity='0.03'/%3E%3C/svg%3E");
  pointer-events: none;
  z-index: 0;
  opacity: 0.4;
}

/* ── HERO ── */
.hero {
  position: relative;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  padding: 60px 24px;
  overflow: hidden;
}
.hero-glow {
  position: absolute;
  width: 700px;
  height: 700px;
  border-radius: 50%;
  background: radial-gradient(
    circle,
    rgba(99, 102, 241, 0.18) 0%,
    rgba(139, 92, 246, 0.08) 40%,
    transparent 70%
  );
  top: 50%;
  left: 50%;
  transform: translate(-50%, -55%);
  pointer-events: none;
}
.hero-glow2 {
  position: absolute;
  width: 400px;
  height: 400px;
  border-radius: 50%;
  background: radial-gradient(
    circle,
    rgba(34, 157, 217, 0.12) 0%,
    transparent 70%
  );
  top: 20%;
  right: 5%;
  pointer-events: none;
}

.badge {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: rgba(99, 102, 241, 0.12);
  border: 1px solid rgba(99, 102, 241, 0.3);
  border-radius: 100px;
  padding: 6px 16px;
  font-size: 0.78rem;
  font-weight: 500;
  color: #a5b4fc;
  margin-bottom: 28px;
  letter-spacing: 0.02em;
}
.badge-dot {
  width: 7px;
  height: 7px;
  background: var(--green);
  border-radius: 50%;
  animation: pulse 2s infinite;
}
@keyframes pulse {
  0%,
  100% {
    opacity: 1;
    transform: scale(1);
  }
  50% {
    opacity: 0.5;
    transform: scale(1.4);
  }
}

.hero h1 {
  font-size: clamp(2.8rem, 7vw, 5rem);
  font-weight: 800;
  letter-spacing: -0.03em;
  line-height: 1.1;
  margin-bottom: 20px;
}
.hero h1 .grad {
  background: linear-gradient(135deg, #6366f1, #8b5cf6, #a855f7);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}
.hero p {
  font-size: clamp(1rem, 2.5vw, 1.2rem);
  color: var(--muted);
  max-width: 560px;
  line-height: 1.7;
  margin-bottom: 40px;
}
.cta-group {
  display: flex;
  gap: 14px;
  flex-wrap: wrap;
  justify-content: center;
}
.btn {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 14px 28px;
  border-radius: 100px;
  font-size: 0.95rem;
  font-weight: 600;
  text-decoration: none;
  transition: all 0.2s;
  cursor: pointer;
  border: none;
}
.btn-primary {
  background: linear-gradient(135deg, #6366f1, #8b5cf6);
  color: #fff;
  box-shadow: 0 8px 32px rgba(99, 102, 241, 0.35);
}
.btn-primary:hover {
  transform: translateY(-2px);
  box-shadow: 0 12px 40px rgba(99, 102, 241, 0.5);
}
.btn-outline {
  background: transparent;
  color: var(--text);
  border: 1px solid var(--border);
}
.btn-outline:hover {
  background: var(--surface);
  transform: translateY(-2px);
}

/* ── STATS BAR ── */
.stats-bar {
  display: flex;
  justify-content: center;
  flex-wrap: wrap;
  margin: 80px auto 0;
  max-width: 900px;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  overflow: hidden;
}
.stat-item {
  flex: 1;
  min-width: 150px;
  padding: 28px 24px;
  text-align: center;
  border-right: 1px solid var(--border);
}
.stat-item:last-child {
  border-right: none;
}
.stat-num {
  font-size: clamp(1.6rem, 2.5vw, 2rem);
  font-weight: 800;
  font-family: "JetBrains Mono", monospace;
  background: linear-gradient(135deg, #6366f1, #a855f7);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  display: flex;
  justify-content: center;
  align-items: baseline;
  flex-wrap: wrap;
  line-height: 1.2;
}
.stat-label {
  font-size: 0.78rem;
  color: var(--muted);
  margin-top: 4px;
}
.stat-sub {
  font-size: 0.68rem;
  color: rgba(100,116,139,0.7);
  margin-top: 3px;
  font-family: 'JetBrains Mono', monospace;
  letter-spacing: 0.01em;
}
.uptime-small {
  display: inline-block;
  font-size: 1rem;
  font-weight: 500;
  color: rgba(255, 255, 255, 0.6);
  margin-left: 4px;
  vertical-align: baseline;
}
.stat-loading {
  display: inline-block;
  color: transparent;
  background: linear-gradient(
    90deg,
    rgba(99, 102, 241, 0.15) 25%,
    rgba(99, 102, 241, 0.3) 50%,
    rgba(99, 102, 241, 0.15) 75%
  );
  background-size: 200% 100%;
  border-radius: 6px;
  animation: shimmer 1.4s infinite;
  min-width: 60px;
}
@keyframes shimmer {
  0% {
    background-position: 200% 0;
  }
  100% {
    background-position: -200% 0;
  }
}

/* ── SECTION ── */
section {
  position: relative;
  z-index: 1;
}
.container {
  max-width: 1100px;
  margin: 0 auto;
  padding: 0 24px;
}
.section-header {
  text-align: center;
  margin-bottom: 56px;
}
.section-tag {
  display: inline-block;
  font-size: 0.72rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: var(--accent);
  margin-bottom: 12px;
}
.section-header h2 {
  font-size: clamp(1.8rem, 4vw, 2.6rem);
  font-weight: 800;
  letter-spacing: -0.02em;
}
.section-header p {
  color: var(--muted);
  margin-top: 12px;
  font-size: 1rem;
  line-height: 1.7;
}

/* ── FEATURE GRID ── */
.feature-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 20px;
  padding: 100px 0;
}
.feature-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 32px;
  transition:
    transform 0.2s,
    border-color 0.2s;
  position: relative;
  overflow: hidden;
}
.feature-card::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 2px;
  opacity: 0;
  transition: opacity 0.2s;
}
.feature-card:hover {
  transform: translateY(-4px);
  border-color: rgba(99, 102, 241, 0.3);
}
.feature-card:hover::before {
  opacity: 1;
}
.feature-card.upload::before {
  background: linear-gradient(90deg, #6366f1, #8b5cf6);
}
.feature-card.download::before {
  background: linear-gradient(90deg, #229ed9, #22d3a0);
}
.feature-card.utility::before {
  background: linear-gradient(90deg, #f97316, #facc15);
}
.fc-icon {
  width: 48px;
  height: 48px;
  border-radius: 12px;
  display: grid;
  place-items: center;
  font-size: 22px;
  margin-bottom: 20px;
}
.fc-icon.purple {
  background: rgba(99, 102, 241, 0.15);
}
.fc-icon.blue {
  background: rgba(34, 157, 217, 0.15);
}
.fc-icon.orange {
  background: rgba(249, 115, 22, 0.15);
}
.feature-card h3 {
  font-size: 1.1rem;
  font-weight: 700;
  margin-bottom: 8px;
}
.feature-card p {
  font-size: 0.875rem;
  color: var(--muted);
  line-height: 1.65;
}
.feature-card code {
  font-family: "JetBrains Mono", monospace;
  font-size: 0.82rem;
  background: rgba(255, 255, 255, 0.06);
  padding: 1px 5px;
  border-radius: 4px;
}

/* ── SERVICES ── */
.services-section {
  padding-bottom: 100px;
}
.tabs {
  display: flex;
  gap: 8px;
  justify-content: center;
  margin-bottom: 32px;
  flex-wrap: wrap;
}
.tab {
  padding: 8px 20px;
  border-radius: 100px;
  font-size: 0.83rem;
  font-weight: 500;
  cursor: pointer;
  border: 1px solid var(--border);
  background: transparent;
  color: var(--muted);
  transition: all 0.15s;
}
.tab.active {
  background: var(--accent);
  color: #fff;
  border-color: var(--accent);
}
.tab:hover:not(.active) {
  background: var(--surface);
  color: var(--text);
}
.services-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
  gap: 14px;
}
.service-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 20px;
  transition:
    transform 0.2s,
    border-color 0.2s;
}
.service-card:hover {
  transform: translateY(-3px);
  border-color: rgba(99, 102, 241, 0.3);
}
.sc-name {
  font-size: 0.95rem;
  font-weight: 600;
  margin-bottom: 10px;
}
.sc-cmd {
  display: inline-block;
  font-family: "JetBrains Mono", monospace;
  font-size: 0.75rem;
  background: rgba(99, 102, 241, 0.12);
  color: #a5b4fc;
  padding: 2px 8px;
  border-radius: 6px;
  margin-bottom: 10px;
}
.sc-meta {
  font-size: 0.75rem;
  color: var(--muted);
  line-height: 1.6;
}
.sc-badge {
  display: inline-block;
  font-size: 0.65rem;
  font-weight: 600;
  padding: 2px 7px;
  border-radius: 100px;
  margin-top: 8px;
}
.sc-badge.all {
  background: rgba(34, 211, 160, 0.1);
  color: var(--green);
}
.sc-badge.image {
  background: rgba(99, 102, 241, 0.1);
  color: #a5b4fc;
}

/* ── TECH STACK ── */
.tech-section {
  padding-bottom: 100px;
}
.tech-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 16px;
}
.tech-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 24px;
  display: flex;
  align-items: center;
  gap: 16px;
}
.tech-icon {
  font-size: 2rem;
  flex-shrink: 0;
}
.tech-name {
  font-size: 0.95rem;
  font-weight: 600;
}
.tech-desc {
  font-size: 0.78rem;
  color: var(--muted);
  margin-top: 2px;
}

/* ── TUTORIAL ── */
.cmd-section {
  padding-bottom: 100px;
}
.tutorial-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
  gap: 20px;
}
.tutorial-step {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 28px;
  display: flex;
  gap: 20px;
  transition:
    transform 0.2s,
    border-color 0.2s;
}
.tutorial-step:hover {
  transform: translateY(-3px);
  border-color: rgba(99, 102, 241, 0.3);
}
.step-num {
  font-family: "JetBrains Mono", monospace;
  font-size: 2.8rem;
  font-weight: 800;
  color: rgba(99, 102, 241, 0.12);
  line-height: 1;
  flex-shrink: 0;
  user-select: none;
}
.step-icon {
  font-size: 1.6rem;
  margin-bottom: 10px;
}
.step-content h3 {
  font-size: 1rem;
  font-weight: 700;
  margin-bottom: 8px;
}
.step-content p {
  font-size: 0.83rem;
  color: var(--muted);
  line-height: 1.6;
  margin-bottom: 10px;
}
.step-content p:last-child {
  margin-bottom: 0;
}
.step-code {
  font-family: "JetBrains Mono", monospace;
  font-size: 0.78rem;
  background: rgba(99, 102, 241, 0.1);
  color: #a5b4fc;
  border: 1px solid rgba(99, 102, 241, 0.2);
  border-radius: 8px;
  padding: 8px 12px;
  margin-bottom: 10px;
  word-break: break-all;
}
.step-note {
  font-size: 0.76rem !important;
  color: var(--muted) !important;
}
.step-note code {
  font-family: "JetBrains Mono", monospace;
  background: rgba(255, 255, 255, 0.06);
  padding: 1px 5px;
  border-radius: 4px;
  font-size: 0.76rem;
}

/* ── FOOTER ── */
footer {
  border-top: 1px solid var(--border);
  padding: 40px 24px;
  text-align: center;
  font-size: 0.82rem;
  color: var(--muted);
}
footer a {
  color: var(--accent);
  text-decoration: none;
}
footer a:hover {
  text-decoration: underline;
}

/* ── RESPONSIVE ── */
@media (max-width: 640px) {
  .stats-bar {
    flex-direction: column;
  }
  .stat-item {
    border-right: none;
    border-bottom: 1px solid var(--border);
  }
  .stat-item:last-child {
    border-bottom: none;
  }
  .cta-group {
    flex-direction: column;
    align-items: center;
  }
  .tutorial-step {
    flex-direction: column;
    gap: 10px;
  }
  .step-num {
    font-size: 1.8rem;
  }
}
