/* ============================================
   Recurra Landing Page
   Dark warm theme (Finmanager palette)
   ============================================ */

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

:root {
  --bg: #141210;
  --surface: #1c1a17;
  --surface-hover: #242220;
  --border: #2a2825;
  --accent: #5897d7;
  --accent-hover: #6ba5e0;
  --accent-glow: rgba(88, 151, 215, 0.15);
  --text: #e8e0d4;
  --text-secondary: #8a8478;
  --text-muted: #5c5850;
  --font-sans: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
  --font-mono: 'Geist Mono', 'SF Mono', 'Fira Code', monospace;
  --radius: 12px;
  --radius-sm: 8px;
  --radius-lg: 16px;
  --max-width: 1120px;
}

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

body {
  font-family: var(--font-sans);
  background: var(--bg);
  color: var(--text);
  line-height: 1.6;
  overflow-x: hidden;
}

a {
  color: var(--accent);
  text-decoration: none;
  transition: color 0.2s;
}

a:hover {
  color: var(--accent-hover);
}

img {
  max-width: 100%;
}

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

/* --- Section Headers --- */
.section-header {
  text-align: center;
  margin-bottom: 56px;
}

.section-header h2 {
  font-size: 2.25rem;
  font-weight: 700;
  letter-spacing: -0.02em;
  margin-bottom: 12px;
}

.section-header p {
  font-size: 1.125rem;
  color: var(--text-secondary);
  max-width: 500px;
  margin: 0 auto;
}

/* --- Buttons --- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-family: var(--font-sans);
  font-weight: 600;
  font-size: 0.9rem;
  border: none;
  border-radius: var(--radius-sm);
  cursor: pointer;
  transition: all 0.2s;
  text-decoration: none;
  padding: 10px 20px;
  color: var(--text);
  background: var(--surface);
}

.btn:hover {
  color: var(--text);
}

.btn-primary {
  background: var(--accent);
  color: #fff;
}

.btn-primary:hover {
  background: var(--accent-hover);
  color: #fff;
  box-shadow: 0 0 24px var(--accent-glow);
}

.btn-outline {
  background: transparent;
  border: 1px solid var(--border);
  color: var(--text);
}

.btn-outline:hover {
  border-color: var(--text-secondary);
  color: var(--text);
  background: var(--surface);
}

.btn-sm {
  padding: 6px 16px;
  font-size: 0.85rem;
}

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

.btn-full {
  width: 100%;
}

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

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

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

.logo {
  font-size: 1.25rem;
  font-weight: 700;
  color: var(--text);
  display: flex;
  align-items: center;
  gap: 8px;
}

.logo:hover {
  color: var(--text);
}

.logo-icon {
  color: var(--accent);
  font-size: 1.1rem;
}

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

.nav-links a {
  color: var(--text-secondary);
  font-size: 0.9rem;
  font-weight: 500;
  transition: color 0.2s;
}

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

.nav-link-docs {
  color: var(--accent) !important;
}

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

.mobile-menu-btn span {
  width: 24px;
  height: 2px;
  background: var(--text);
  border-radius: 2px;
  transition: all 0.3s;
}

.mobile-menu-btn.open span:nth-child(1) {
  transform: rotate(45deg) translate(5px, 5px);
}

.mobile-menu-btn.open span:nth-child(2) {
  opacity: 0;
}

.mobile-menu-btn.open span:nth-child(3) {
  transform: rotate(-45deg) translate(5px, -5px);
}

/* --- Hero --- */
.hero {
  padding: 160px 0 100px;
  text-align: center;
  position: relative;
}

.hero::before {
  content: '';
  position: absolute;
  top: 0;
  left: 50%;
  transform: translateX(-50%);
  width: 600px;
  height: 600px;
  background: radial-gradient(circle, var(--accent-glow) 0%, transparent 70%);
  pointer-events: none;
}

.hero-badge {
  display: inline-block;
  padding: 6px 16px;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 100px;
  font-size: 0.8rem;
  color: var(--text-secondary);
  margin-bottom: 32px;
}

.hero h1 {
  font-size: 4rem;
  font-weight: 700;
  letter-spacing: -0.03em;
  line-height: 1.1;
  margin-bottom: 24px;
}

.hero-subtitle {
  font-size: 1.25rem;
  color: var(--text-secondary);
  line-height: 1.7;
  max-width: 560px;
  margin: 0 auto 40px;
}

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

.hero-stats {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 40px;
  margin-top: 72px;
  padding-top: 40px;
  border-top: 1px solid var(--border);
  max-width: 560px;
  margin-left: auto;
  margin-right: auto;
}

.stat {
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.stat-value {
  font-size: 1.5rem;
  font-weight: 700;
  color: var(--text);
}

.stat-label {
  font-size: 0.8rem;
  color: var(--text-secondary);
}

.stat-divider {
  width: 1px;
  height: 40px;
  background: var(--border);
}

/* --- Features --- */
.features {
  padding: 100px 0;
}

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

.feature-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 36px;
  transition: all 0.3s;
  opacity: 0;
  transform: translateY(24px);
}

.feature-card.animate-in {
  opacity: 1;
  transform: translateY(0);
}

.feature-card:hover {
  border-color: var(--text-muted);
  background: var(--surface-hover);
}

.feature-icon {
  width: 52px;
  height: 52px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--accent-glow);
  border-radius: var(--radius);
  color: var(--accent);
  margin-bottom: 20px;
}

.feature-card h3 {
  font-size: 1.2rem;
  font-weight: 600;
  margin-bottom: 10px;
}

.feature-card p {
  color: var(--text-secondary);
  font-size: 0.95rem;
  line-height: 1.6;
}

/* --- How It Works --- */
.how-it-works {
  padding: 100px 0;
}

.steps {
  display: flex;
  align-items: flex-start;
  gap: 0;
  max-width: 900px;
  margin: 0 auto;
}

.step {
  flex: 1;
  text-align: center;
  padding: 0 24px;
  opacity: 0;
  transform: translateY(24px);
}

.step.animate-in {
  opacity: 1;
  transform: translateY(0);
}

.step-number {
  width: 56px;
  height: 56px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--accent);
  color: #fff;
  font-size: 1.25rem;
  font-weight: 700;
  border-radius: 50%;
  margin: 0 auto 24px;
}

.step-connector {
  width: 80px;
  height: 2px;
  background: var(--border);
  margin-top: 28px;
  flex-shrink: 0;
}

.step-content h3 {
  font-size: 1.15rem;
  font-weight: 600;
  margin-bottom: 10px;
}

.step-content p {
  color: var(--text-secondary);
  font-size: 0.9rem;
  line-height: 1.6;
}

/* --- Code Section --- */
.code-section {
  padding: 100px 0;
}

.code-block {
  max-width: 680px;
  margin: 0 auto;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  overflow: hidden;
}

.code-header {
  display: flex;
  align-items: center;
  padding: 12px 20px;
  border-bottom: 1px solid var(--border);
  gap: 12px;
}

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

.code-dots span {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: var(--border);
}

.code-dots span:first-child { background: #e85c4a; }
.code-dots span:nth-child(2) { background: #e8b44a; }
.code-dots span:last-child { background: #4ae86a; }

.code-filename {
  font-family: var(--font-mono);
  font-size: 0.8rem;
  color: var(--text-secondary);
  flex: 1;
}

.code-copy {
  background: none;
  border: 1px solid var(--border);
  color: var(--text-secondary);
  font-family: var(--font-sans);
  font-size: 0.75rem;
  padding: 4px 12px;
  border-radius: 6px;
  cursor: pointer;
  transition: all 0.2s;
}

.code-copy:hover {
  color: var(--text);
  border-color: var(--text-muted);
}

.code-block pre {
  padding: 24px;
  overflow-x: auto;
}

.code-block code {
  font-family: var(--font-mono);
  font-size: 0.85rem;
  line-height: 1.7;
  color: var(--text-secondary);
}

/* --- Pricing --- */
.pricing {
  padding: 100px 0;
}

.pricing-card {
  max-width: 480px;
  margin: 0 auto;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 48px 40px;
  text-align: center;
  opacity: 0;
  transform: translateY(24px);
}

.pricing-card.animate-in {
  opacity: 1;
  transform: translateY(0);
}

.pricing-amount {
  margin-bottom: 40px;
}

.pricing-number {
  font-size: 4rem;
  font-weight: 700;
  letter-spacing: -0.03em;
  color: var(--text);
}

.pricing-unit {
  display: block;
  font-size: 1.1rem;
  color: var(--text-secondary);
  margin-top: 4px;
}

.pricing-features {
  list-style: none;
  text-align: left;
  margin-bottom: 40px;
}

.pricing-features li {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 10px 0;
  font-size: 0.95rem;
  color: var(--text-secondary);
  border-bottom: 1px solid var(--border);
}

.pricing-features li:last-child {
  border-bottom: none;
}

.pricing-features li svg {
  flex-shrink: 0;
}

/* --- CTA --- */
.cta {
  padding: 100px 0;
  text-align: center;
  position: relative;
}

.cta::before {
  content: '';
  position: absolute;
  bottom: 0;
  left: 50%;
  transform: translateX(-50%);
  width: 600px;
  height: 400px;
  background: radial-gradient(circle, var(--accent-glow) 0%, transparent 70%);
  pointer-events: none;
}

.cta h2 {
  font-size: 2.25rem;
  font-weight: 700;
  letter-spacing: -0.02em;
  margin-bottom: 12px;
}

.cta p {
  font-size: 1.125rem;
  color: var(--text-secondary);
  margin-bottom: 32px;
}

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

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

.footer-brand p {
  color: var(--text-secondary);
  font-size: 0.9rem;
  margin-top: 12px;
  max-width: 280px;
  line-height: 1.6;
}

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

.footer-col h4 {
  font-size: 0.85rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: var(--text-muted);
  margin-bottom: 4px;
}

.footer-col a {
  color: var(--text-secondary);
  font-size: 0.9rem;
  transition: color 0.2s;
}

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

.footer-bottom {
  border-top: 1px solid var(--border);
  padding-top: 24px;
}

.footer-bottom p {
  font-size: 0.8rem;
  color: var(--text-muted);
}

/* --- Animations --- */
[data-animate] {
  transition: opacity 0.6s ease, transform 0.6s ease;
}

.feature-card:nth-child(2) { transition-delay: 0.1s; }
.feature-card:nth-child(3) { transition-delay: 0.2s; }
.feature-card:nth-child(4) { transition-delay: 0.3s; }

.step:nth-child(3) { transition-delay: 0.15s; }
.step:nth-child(5) { transition-delay: 0.3s; }

/* --- Responsive --- */
@media (max-width: 768px) {
  .hero {
    padding: 120px 0 80px;
  }

  .hero h1 {
    font-size: 2.5rem;
  }

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

  .hero-stats {
    gap: 24px;
    flex-wrap: wrap;
  }

  .stat-divider {
    display: none;
  }

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

  .steps {
    flex-direction: column;
    align-items: center;
    gap: 8px;
  }

  .step-connector {
    width: 2px;
    height: 40px;
    margin: 0;
  }

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

  .footer-brand {
    grid-column: 1 / -1;
  }

  .nav-links {
    display: none;
    position: fixed;
    top: 60px;
    left: 0;
    right: 0;
    background: var(--bg);
    border-bottom: 1px solid var(--border);
    flex-direction: column;
    padding: 24px;
    gap: 20px;
  }

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

  .mobile-menu-btn {
    display: flex;
  }

  .section-header h2 {
    font-size: 1.75rem;
  }

  .pricing-card {
    padding: 36px 28px;
  }

  .pricing-number {
    font-size: 3rem;
  }

  .cta h2 {
    font-size: 1.75rem;
  }

  .code-block pre {
    padding: 16px;
  }

  .code-block code {
    font-size: 0.75rem;
  }
}

@media (max-width: 480px) {
  .hero h1 {
    font-size: 2rem;
  }

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

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