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

:root {
  --bg: #0a0d0b;
  --surface: #111a13;
  --border: #1e3322;
  --accent: #3ddc84;
  --accent-dim: #2aab64;
  --accent-glow: rgba(61, 220, 132, 0.15);
  --text-primary: #e8f5ec;
  --text-secondary: #8aab95;
  --text-muted: #4a6655;
  --font-sans: 'Inter', system-ui, -apple-system, sans-serif;
  --font-mono: 'JetBrains Mono', 'Fira Code', monospace;
  --radius: 8px;
  --transition: 0.25s ease;
}

html {
  scroll-behavior: smooth;
}

body {
  background-color: var(--bg);
  color: var(--text-primary);
  font-family: var(--font-sans);
  font-size: 16px;
  line-height: 1.6;
  min-height: 100vh;
  overflow-x: hidden;
}

/* === Background texture === */
body::before {
  content: '';
  position: fixed;
  inset: 0;
  background-image:
    radial-gradient(ellipse 80% 60% at 50% -10%, rgba(61, 220, 132, 0.06) 0%, transparent 70%),
    radial-gradient(ellipse 40% 40% at 80% 80%, rgba(61, 220, 132, 0.04) 0%, transparent 60%);
  pointer-events: none;
  z-index: 0;
}

/* === Layout === */
.site-wrapper {
  position: relative;
  z-index: 1;
  display: flex;
  flex-direction: column;
  min-height: 100vh;
}

/* === Header === */
header {
  padding: 1.5rem 2rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
  border-bottom: 1px solid var(--border);
}

.logo {
  display: flex;
  align-items: center;
  gap: 0.6rem;
  text-decoration: none;
}

.logo-icon {
  width: 32px;
  height: 32px;
}

.logo-text {
  font-size: 1rem;
  font-weight: 600;
  color: var(--text-primary);
  letter-spacing: -0.02em;
}

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

.badge {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  padding: 0.3rem 0.75rem;
  background: var(--accent-glow);
  border: 1px solid rgba(61, 220, 132, 0.25);
  border-radius: 2rem;
  font-size: 0.75rem;
  font-weight: 500;
  color: var(--accent);
  letter-spacing: 0.04em;
  text-transform: uppercase;
}

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

@keyframes pulse {
  0%, 100% { opacity: 1; transform: scale(1); }
  50% { opacity: 0.5; transform: scale(0.8); }
}

/* === Hero === */
.hero {
  flex: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  padding: 5rem 2rem 4rem;
  gap: 2rem;
}

.hero-eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  font-size: 0.8rem;
  font-family: var(--font-mono);
  color: var(--accent);
  letter-spacing: 0.1em;
  text-transform: uppercase;
}

.eyebrow-line {
  display: inline-block;
  width: 24px;
  height: 1px;
  background: var(--accent);
}

.hero-title {
  font-size: clamp(2.5rem, 7vw, 5.5rem);
  font-weight: 700;
  letter-spacing: -0.04em;
  line-height: 1.05;
  max-width: 14ch;
}

.hero-title .highlight {
  background: linear-gradient(135deg, var(--accent) 0%, #a8ffce 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.hero-description {
  font-size: 1.15rem;
  color: var(--text-secondary);
  max-width: 48ch;
  line-height: 1.75;
}

/* === Email form === */
.signup-form {
  display: flex;
  gap: 0.5rem;
  width: 100%;
  max-width: 440px;
  flex-wrap: wrap;
}

.signup-form input[type="email"] {
  flex: 1;
  min-width: 200px;
  padding: 0.75rem 1rem;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  color: var(--text-primary);
  font-size: 0.95rem;
  font-family: var(--font-sans);
  outline: none;
  transition: border-color var(--transition), box-shadow var(--transition);
}

.signup-form input[type="email"]::placeholder {
  color: var(--text-muted);
}

.signup-form input[type="email"]:focus {
  border-color: var(--accent-dim);
  box-shadow: 0 0 0 3px var(--accent-glow);
}

.btn-primary {
  padding: 0.75rem 1.5rem;
  background: var(--accent);
  border: none;
  border-radius: var(--radius);
  color: #0a0d0b;
  font-size: 0.9rem;
  font-weight: 600;
  font-family: var(--font-sans);
  cursor: pointer;
  white-space: nowrap;
  transition: background var(--transition), transform var(--transition), box-shadow var(--transition);
}

.btn-primary:hover {
  background: #54e698;
  box-shadow: 0 0 20px rgba(61, 220, 132, 0.3);
  transform: translateY(-1px);
}

.btn-primary:active {
  transform: translateY(0);
}

.btn-primary:disabled {
  opacity: 0.6;
  cursor: not-allowed;
  transform: none;
}

/* === Form feedback === */
.form-message {
  font-size: 0.85rem;
  min-height: 1.2em;
  transition: opacity var(--transition);
}

.form-message.success {
  color: var(--accent);
}

.form-message.error {
  color: #ff7070;
}

/* === Divider === */
.hero-divider {
  width: 1px;
  height: 80px;
  background: linear-gradient(to bottom, var(--border), transparent);
  margin: 0 auto;
}

/* === Features strip === */
.features {
  display: flex;
  justify-content: center;
  flex-wrap: wrap;
  gap: 0;
  padding: 2.5rem 2rem;
  border-top: 1px solid var(--border);
  border-bottom: 1px solid var(--border);
}

.feature-item {
  display: flex;
  align-items: center;
  gap: 0.6rem;
  padding: 0.75rem 2rem;
  color: var(--text-secondary);
  font-size: 0.875rem;
  border-right: 1px solid var(--border);
}

.feature-item:last-child {
  border-right: none;
}

.feature-icon {
  font-size: 1.1rem;
  flex-shrink: 0;
}

/* === Footer === */
footer {
  padding: 1.5rem 2rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 0.5rem;
}

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

.footer-links {
  display: flex;
  gap: 1.5rem;
  list-style: none;
}

.footer-links a {
  font-size: 0.8rem;
  color: var(--text-muted);
  text-decoration: none;
  transition: color var(--transition);
}

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

/* === Network/mycelium SVG animation === */
.mycelium-bg {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  pointer-events: none;
  z-index: 0;
  opacity: 0.15;
}

/* === Screen-reader only === */
.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border-width: 0;
}

/* === Responsive === */
@media (max-width: 640px) {
  header {
    padding: 1rem 1.25rem;
  }

  .hero {
    padding: 3.5rem 1.25rem 3rem;
  }

  .features {
    flex-direction: column;
    align-items: flex-start;
    padding: 1.5rem 1.25rem;
  }

  .feature-item {
    border-right: none;
    padding: 0.5rem 0;
  }

  footer {
    padding: 1.25rem;
    flex-direction: column;
    align-items: flex-start;
    gap: 0.75rem;
  }
}
