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

:root {
  --bg:        #03060d;
  --bg-2:      #060d1a;
  --bg-card:   #0a1628;
  --bg-card-2: #0d1f38;
  --border:    rgba(34, 211, 238, 0.14);
  --border-2:  rgba(255,255,255,0.07);
  --cyan:      #22d3ee;
  --cyan-dim:  rgba(34,211,238,0.10);
  --emerald:   #34d399;
  --emerald-dim: rgba(52,211,153,0.10);
  --amber:     #fbbf24;
  --amber-dim: rgba(251,191,36,0.10);
  --coral:     #f87171;
  --text:      #e2e8f0;
  --text-muted:#7c9ab8;
  --text-dim:  #4a6282;
  --radius:    10px;
  --radius-sm: 6px;
}

html { scroll-behavior: smooth; }

body {
  font-family: 'Sora', system-ui, sans-serif;
  background: var(--bg);
  color: var(--text);
  line-height: 1.6;
  overflow-x: hidden;
}

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

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

/* Grain overlay */
.grain {
  position: fixed;
  inset: 0;
  background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 256 256' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='noise'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='4' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23noise)'/%3E%3C/svg%3E");
  opacity: 0.025;
  pointer-events: none;
  z-index: 9999;
}

/* ── NAV ─────────────────────────────────────────────────────────────────── */
.nav {
  position: fixed;
  top: 0; left: 0; right: 0;
  z-index: 100;
  transition: background 0.3s, border-color 0.3s, backdrop-filter 0.3s;
  border-bottom: 1px solid transparent;
}

.nav.scrolled {
  background: rgba(3,6,13,0.88);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border-color: var(--border-2);
}

.nav-inner {
  max-width: 1120px;
  margin: 0 auto;
  padding: 0 24px;
  height: 60px;
  display: flex;
  align-items: center;
  gap: 32px;
}

.nav-logo {
  display: flex;
  align-items: center;
  gap: 9px;
  font-weight: 600;
  font-size: 15px;
  letter-spacing: -0.01em;
  color: #fff;
  flex-shrink: 0;
}

.nav-name { color: #fff; }

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

.nav-link {
  padding: 6px 12px;
  border-radius: var(--radius-sm);
  font-size: 14px;
  color: var(--text-muted);
  transition: color 0.2s, background 0.2s;
}
.nav-link:hover { color: var(--text); background: rgba(255,255,255,0.05); }

.nav-actions { display: flex; align-items: center; gap: 8px; }

.nav-github {
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 7px 14px;
  border-radius: var(--radius-sm);
  border: 1px solid var(--border-2);
  font-size: 13px;
  font-weight: 500;
  color: var(--text-muted);
  transition: all 0.2s;
}
.nav-github:hover { border-color: var(--border); color: var(--text); background: rgba(255,255,255,0.04); }

.nav-burger {
  display: none;
  flex-direction: column;
  gap: 5px;
  background: none;
  border: none;
  cursor: pointer;
  padding: 4px;
  margin-left: auto;
}
.nav-burger span {
  display: block;
  width: 22px;
  height: 2px;
  background: var(--text-muted);
  border-radius: 2px;
  transition: all 0.3s;
}
.nav-burger.open span:nth-child(1) { transform: rotate(45deg) translate(5px, 5px); }
.nav-burger.open span:nth-child(2) { opacity: 0; }
.nav-burger.open span:nth-child(3) { transform: rotate(-45deg) translate(5px, -5px); }

.nav-mobile {
  display: none;
  flex-direction: column;
  background: rgba(3,6,13,0.97);
  border-top: 1px solid var(--border-2);
  padding: 12px 0;
}
.nav-mobile.open { display: flex; }
.nav-mobile a {
  padding: 12px 24px;
  font-size: 15px;
  color: var(--text-muted);
  border-bottom: 1px solid var(--border-2);
  transition: color 0.2s;
}
.nav-mobile a:hover { color: var(--text); }

/* ── BUTTONS ─────────────────────────────────────────────────────────────── */
.btn-primary {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 11px 22px;
  background: var(--cyan);
  color: #03060d;
  font-weight: 600;
  font-size: 14px;
  border-radius: var(--radius-sm);
  transition: opacity 0.2s, transform 0.15s;
}
.btn-primary:hover { opacity: 0.88; transform: translateY(-1px); }
.btn-primary:active { opacity: 1; transform: translateY(0) scale(0.97); }

.btn-outline {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 11px 22px;
  background: transparent;
  color: var(--text-muted);
  font-weight: 500;
  font-size: 14px;
  border-radius: var(--radius-sm);
  border: 1px solid var(--border-2);
  transition: all 0.2s;
}
.btn-outline:hover { border-color: var(--border); color: var(--text); background: rgba(255,255,255,0.04); }
.btn-outline:active { transform: scale(0.97); }

/* ── HERO ────────────────────────────────────────────────────────────────── */
.hero {
  position: relative;
  padding: 140px 0 100px;
  overflow: hidden;
  min-height: 100dvh;
  display: flex;
  align-items: center;
}

.hero-glow {
  position: absolute;
  top: -200px;
  left: 50%;
  transform: translateX(-50%);
  width: 800px;
  height: 800px;
  background: radial-gradient(ellipse, rgba(34,211,238,0.07) 0%, transparent 65%);
  pointer-events: none;
}

.hero-inner {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 64px;
  align-items: center;
  width: 100%;
}

.hero-badge {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 5px 12px;
  border: 1px solid var(--border);
  border-radius: 100px;
  font-size: 12px;
  font-family: 'JetBrains Mono', monospace;
  color: var(--cyan);
  margin-bottom: 24px;
}

.badge-dot {
  width: 6px;
  height: 6px;
  background: var(--cyan);
  border-radius: 50%;
}

.hero-title {
  font-size: clamp(38px, 5vw, 60px);
  font-weight: 800;
  line-height: 1.06;
  letter-spacing: -0.03em;
  color: #fff;
  margin-bottom: 20px;
}

.accent {
  background: linear-gradient(135deg, #5eecff, #22d3ee, #0ea5e9);
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
}

.hero-sub {
  font-size: 16px;
  color: var(--text-muted);
  line-height: 1.7;
  margin-bottom: 32px;
  max-width: 420px;
}

.hero-actions {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 28px;
  flex-wrap: wrap;
}

.hero-install {
  display: flex;
  align-items: center;
  gap: 0;
  background: var(--bg-card);
  border: 1px solid var(--border-2);
  border-radius: var(--radius-sm);
  overflow: hidden;
  max-width: 520px;
}

.install-label {
  padding: 10px 12px;
  font-size: 11px;
  font-family: 'JetBrains Mono', monospace;
  color: var(--text-dim);
  border-right: 1px solid var(--border-2);
  white-space: nowrap;
  flex-shrink: 0;
}

.install-code {
  font-family: 'JetBrains Mono', monospace;
  font-size: 11px;
  color: var(--cyan);
  padding: 10px 12px;
  flex: 1;
  overflow: hidden;
  white-space: nowrap;
  text-overflow: ellipsis;
}

.copy-btn {
  padding: 10px 12px;
  background: none;
  border: none;
  border-left: 1px solid var(--border-2);
  color: var(--text-dim);
  cursor: pointer;
  display: flex;
  align-items: center;
  transition: color 0.2s;
  flex-shrink: 0;
}
.copy-btn:hover { color: var(--cyan); }

/* ── BROWSER MOCK ────────────────────────────────────────────────────────── */
.hero-visual { position: relative; }

.hero-glow-2 {
  position: absolute;
  bottom: -60px;
  right: -60px;
  width: 300px;
  height: 300px;
  background: radial-gradient(ellipse, rgba(52,211,153,0.05) 0%, transparent 70%);
  pointer-events: none;
}

.browser-mock {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: 10px;
  overflow: hidden;
  box-shadow: 0 32px 80px rgba(0,0,0,0.6), 0 0 0 1px rgba(34,211,238,0.04);
}

.browser-chrome {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 10px 14px;
  background: rgba(255,255,255,0.02);
  border-bottom: 1px solid var(--border-2);
}

.browser-dots {
  display: flex;
  gap: 5px;
  flex-shrink: 0;
}
.browser-dot {
  width: 9px;
  height: 9px;
  border-radius: 50%;
}
.browser-dot.red    { background: #f87171; }
.browser-dot.yellow { background: #fbbf24; }
.browser-dot.green  { background: #34d399; }

.browser-url-bar {
  flex: 1;
  background: var(--bg);
  border: 1px solid var(--border-2);
  border-radius: 4px;
  padding: 4px 10px;
  display: flex;
  align-items: center;
  gap: 6px;
}

.browser-lock {
  color: var(--emerald);
  font-size: 9px;
  flex-shrink: 0;
}

.browser-url {
  font-family: 'JetBrains Mono', monospace;
  font-size: 10px;
  color: var(--text-dim);
}

.browser-body { padding: 14px; }

.mock-stats {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 8px;
  margin-bottom: 14px;
}

.mock-stat {
  background: var(--bg-card-2);
  border: 1px solid var(--border-2);
  border-radius: var(--radius-sm);
  padding: 10px;
  text-align: center;
}

.stat-num {
  display: block;
  font-size: 22px;
  font-weight: 700;
  font-family: 'JetBrains Mono', monospace;
  line-height: 1;
  margin-bottom: 4px;
}
.stat-num.cyan    { color: var(--cyan); }
.stat-num.emerald { color: var(--emerald); }
.stat-num.amber   { color: var(--amber); }
.stat-num.coral   { color: var(--coral); }

.stat-lbl {
  font-size: 9px;
  color: var(--text-dim);
  text-transform: uppercase;
  letter-spacing: 0.06em;
}

.mock-list { display: flex; flex-direction: column; gap: 5px; }

.mock-row {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 8px 10px;
  border-radius: var(--radius-sm);
  background: var(--bg-card-2);
  border: 1px solid var(--border-2);
}
.mock-row.highlight {
  border-color: rgba(34,211,238,0.22);
  background: rgba(34,211,238,0.04);
}

.mock-status-dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  flex-shrink: 0;
}

.mock-badge {
  font-family: 'JetBrains Mono', monospace;
  font-size: 9px;
  padding: 2px 6px;
  border-radius: 3px;
  white-space: nowrap;
  flex-shrink: 0;
  letter-spacing: 0.04em;
}
.mock-badge.up    { background: rgba(52,211,153,0.10); color: var(--emerald); }
.mock-badge.avail { background: rgba(34,211,238,0.10); color: var(--cyan); }

.mock-name {
  font-size: 12px;
  font-weight: 500;
  color: var(--text);
  flex: 1;
}

.mock-tag {
  font-family: 'JetBrains Mono', monospace;
  font-size: 10px;
  color: var(--text-dim);
  white-space: nowrap;
}
.mock-tag.new { color: var(--cyan); }

.mock-footer {
  margin-top: 12px;
  padding-top: 10px;
  border-top: 1px solid var(--border-2);
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.mock-status-line {
  display: flex;
  align-items: center;
  gap: 6px;
  font-family: 'JetBrains Mono', monospace;
  font-size: 10px;
  color: var(--text-dim);
}

.mock-live-dot {
  width: 6px;
  height: 6px;
  background: var(--emerald);
  border-radius: 50%;
  animation: live-pulse 2s ease-in-out infinite;
}

@keyframes live-pulse {
  0%, 100% { opacity: 1; }
  50% { opacity: 0.4; }
}

.mock-ws-badge {
  font-family: 'JetBrains Mono', monospace;
  font-size: 9px;
  color: var(--emerald);
  background: var(--emerald-dim);
  border: 1px solid rgba(52,211,153,0.2);
  padding: 1px 6px;
  border-radius: 3px;
}

/* ── FEATURES ────────────────────────────────────────────────────────────── */
.features {
  padding: 100px 0;
  border-top: 1px solid var(--border-2);
}

.section-header {
  margin-bottom: 48px;
}

.section-title {
  font-size: clamp(26px, 3.5vw, 38px);
  font-weight: 700;
  letter-spacing: -0.025em;
  color: #fff;
  margin-bottom: 10px;
}

.section-sub {
  font-size: 15px;
  color: var(--text-muted);
  max-width: 420px;
}

/* Bento grid */
.features-bento {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 14px;
}

.feature-card {
  background: var(--bg-card);
  border: 1px solid var(--border-2);
  border-radius: var(--radius);
  padding: 24px;
  position: relative;
  overflow: hidden;
  transition: border-color 0.25s, transform 0.2s;
}

/* Spotlight hover effect */
.feature-card::before {
  content: '';
  position: absolute;
  inset: 0;
  background: radial-gradient(350px circle at var(--mx, 50%) var(--my, 50%), rgba(34,211,238,0.07), transparent 50%);
  opacity: 0;
  transition: opacity 0.3s;
  pointer-events: none;
}
.feature-card:hover { border-color: rgba(34,211,238,0.2); transform: translateY(-2px); }
.feature-card:hover::before { opacity: 1; }

.feature-card.wide { grid-column: span 2; }
.feature-card.full { grid-column: span 3; }

.feature-card.full .feature-inner {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 24px;
  align-items: center;
}

.feature-icon {
  width: 40px;
  height: 40px;
  border-radius: 8px;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 16px;
  flex-shrink: 0;
}
.feature-icon.cyan    { background: var(--cyan-dim);    color: var(--cyan); }
.feature-icon.emerald { background: var(--emerald-dim); color: var(--emerald); }
.feature-icon.amber   { background: var(--amber-dim);   color: var(--amber); }

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

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

.feature-card.wide h3 { font-size: 17px; }
.feature-card.full h3 { font-size: 18px; margin-bottom: 10px; }
.feature-card.full p  { font-size: 14px; max-width: 380px; }

/* Feature terminal for API card */
.feature-terminal {
  background: var(--bg);
  border: 1px solid var(--border-2);
  border-radius: var(--radius-sm);
  padding: 14px;
  font-family: 'JetBrains Mono', monospace;
  font-size: 11px;
  line-height: 1.8;
  color: var(--text-dim);
  overflow: hidden;
}

.feature-terminal .t-comment { color: var(--text-dim); }
.feature-terminal .t-key     { color: var(--amber); }
.feature-terminal .t-string  { color: var(--emerald); }
.feature-terminal .t-cyan    { color: var(--cyan); }
.feature-terminal .t-url     { color: var(--text-muted); }

/* ── HOW IT WORKS ────────────────────────────────────────────────────────── */
.howto {
  padding: 100px 0;
  background: var(--bg-2);
  border-top: 1px solid var(--border-2);
  border-bottom: 1px solid var(--border-2);
}

.steps {
  display: flex;
  flex-direction: column;
  gap: 0;
  max-width: 680px;
  margin: 0 auto;
  position: relative;
}

.steps::before {
  content: '';
  position: absolute;
  left: 19px;
  top: 44px;
  bottom: 44px;
  width: 1px;
  background: linear-gradient(to bottom, rgba(34,211,238,0.3), rgba(52,211,153,0.3), transparent);
}

.step {
  display: flex;
  gap: 24px;
  padding: 0 0 40px;
  position: relative;
}
.step:last-child { padding-bottom: 0; }

.step-num {
  width: 40px;
  height: 40px;
  border-radius: 50%;
  background: var(--bg-card);
  border: 2px solid rgba(34,211,238,0.5);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 14px;
  font-weight: 700;
  font-family: 'JetBrains Mono', monospace;
  color: var(--cyan);
  flex-shrink: 0;
  position: relative;
  z-index: 1;
  box-shadow: 0 0 16px rgba(34,211,238,0.12);
}

.step-content { padding-top: 8px; }

.step-content h3 {
  font-size: 17px;
  font-weight: 600;
  color: #fff;
  margin-bottom: 8px;
  letter-spacing: -0.01em;
}

.step-content p {
  font-size: 14px;
  color: var(--text-muted);
  margin-bottom: 16px;
  line-height: 1.7;
}

.code-block {
  background: var(--bg-card);
  border: 1px solid var(--border-2);
  border-radius: var(--radius-sm);
  padding: 16px;
  overflow-x: auto;
}

.code-block code {
  font-family: 'JetBrains Mono', monospace;
  font-size: 12px;
  color: var(--cyan);
  white-space: pre;
  display: block;
  line-height: 1.75;
}

/* ── CTA ─────────────────────────────────────────────────────────────────── */
.cta-section {
  position: relative;
  padding: 120px 0;
  overflow: hidden;
  text-align: center;
}

.cta-glow {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  width: 700px;
  height: 500px;
  background: radial-gradient(ellipse, rgba(34,211,238,0.06) 0%, transparent 65%);
  pointer-events: none;
}

.cta-inner { position: relative; z-index: 1; }

.cta-title {
  font-size: clamp(28px, 4vw, 46px);
  font-weight: 800;
  letter-spacing: -0.03em;
  color: #fff;
  margin-bottom: 12px;
  line-height: 1.1;
}

.cta-sub {
  font-size: 15px;
  color: var(--text-muted);
  margin-bottom: 36px;
}

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

/* ── FOOTER ──────────────────────────────────────────────────────────────── */
.footer {
  border-top: 1px solid var(--border-2);
  padding: 48px 0 32px;
  background: var(--bg);
}

.footer-inner {
  display: flex;
  gap: 64px;
  margin-bottom: 40px;
}

.footer-brand { flex: 1; }

.footer-tagline {
  font-size: 13px;
  color: var(--text-dim);
  margin-top: 10px;
  max-width: 220px;
  line-height: 1.6;
}

.footer-links {
  display: flex;
  gap: 48px;
}

.footer-col {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.footer-col-title {
  font-size: 11px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: var(--text-dim);
  margin-bottom: 4px;
}

.footer-col a {
  font-size: 13px;
  color: var(--text-muted);
  transition: color 0.2s;
}
.footer-col a:hover { color: var(--text); }

.footer-bottom {
  padding-top: 24px;
  border-top: 1px solid var(--border-2);
  font-size: 12px;
  color: var(--text-dim);
}
.footer-bottom a { color: var(--text-muted); }
.footer-bottom a:hover { color: var(--cyan); }

/* ── HERO SCREENSHOT ─────────────────────────────────────────────────────── */
.hero-screenshot {
  width: 100%;
  display: block;
  border-radius: 10px;
  border: 1px solid rgba(34, 211, 238, 0.18);
  box-shadow:
    0 32px 80px rgba(0, 0, 0, 0.7),
    0 0 0 1px rgba(34, 211, 238, 0.04),
    inset 0 1px 0 rgba(255, 255, 255, 0.04);
}

.hero-tagline {
  font-family: 'JetBrains Mono', monospace;
  font-size: 11px;
  color: rgba(34, 211, 238, 0.42);
  letter-spacing: 0.04em;
  margin-bottom: 16px;
  margin-top: 4px;
}

/* ── BARQUINHO ───────────────────────────────────────────────────────────── */
/* 1320x360 SVG, 4 estados de 330px cada. Em height=180: stateWidth=165px */
.barquinho-cta {
  width: 165px;
  height: 180px;
  overflow: hidden;
  position: relative;
  margin: 0 auto 32px;
}

.barquinho-cta-img {
  position: absolute;
  top: 0;
  left: 0;
  height: 180px;
  width: 660px;
}

/* ── SCROLL REVEAL ───────────────────────────────────────────────────────── */
.reveal {
  opacity: 0;
  transform: translateY(22px);
  transition: opacity 0.65s cubic-bezier(0.16,1,0.3,1), transform 0.65s cubic-bezier(0.16,1,0.3,1);
}
.reveal.visible {
  opacity: 1;
  transform: none;
}

.reveal-delay-1 { transition-delay: 0.08s; }
.reveal-delay-2 { transition-delay: 0.16s; }
.reveal-delay-3 { transition-delay: 0.24s; }

@media (prefers-reduced-motion: reduce) {
  .reveal { opacity: 1; transform: none; transition: none; }
  .reveal-delay-1, .reveal-delay-2, .reveal-delay-3 { transition-delay: 0s; }
  .mock-live-dot { animation: none; }
  .btn-primary:hover, .btn-outline:hover { transform: none; }
}

/* ── RESPONSIVE ──────────────────────────────────────────────────────────── */
@media (max-width: 1024px) {
  .features-bento { grid-template-columns: repeat(2, 1fr); }
  .feature-card.wide { grid-column: span 2; }
  .feature-card.full { grid-column: span 2; }
  .feature-card.full .feature-inner { grid-template-columns: 1fr; }
  .hero-inner { gap: 40px; }
}

@media (max-width: 768px) {
  .nav-links, .nav-actions { display: none; }
  .nav-burger { display: flex; }

  .hero { padding: 100px 0 64px; min-height: auto; }
  .hero-inner { grid-template-columns: 1fr; gap: 48px; }
  .hero-title { font-size: 38px; }
  .hero-sub { max-width: 100%; }

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

  .features-bento { grid-template-columns: 1fr; }
  .feature-card.wide,
  .feature-card.full { grid-column: span 1; }
  .feature-card.full .feature-inner { grid-template-columns: 1fr; }

  .footer-inner { flex-direction: column; gap: 32px; }
  .footer-links { flex-direction: column; gap: 28px; }

  .steps::before { display: none; }
}

@media (max-width: 480px) {
  .hero-actions { flex-direction: column; align-items: flex-start; }
  .btn-primary, .btn-outline { width: 100%; justify-content: center; }
  .cta-actions { flex-direction: column; align-items: center; }
}
