:root {
  --bg: #0a0a0f;
  --bg-card: #12121a;
  --bg-input: #1a1a2e;
  --border: #2a2a3e;
  --text: #e4e4ed;
  --text-muted: #8888a0;
  --accent: #6c5ce7;
  --accent-hover: #7c6cf7;
  --accent-glow: rgba(108, 92, 231, 0.3);
  --success: #00d2a0;
  --error: #ff6b6b;
  --radius: 12px;
}

* { margin: 0; padding: 0; box-sizing: border-box; }

body {
  font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  background: var(--bg);
  color: var(--text);
  line-height: 1.6;
  min-height: 100vh;
}

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

/* Layout */
.container { max-width: 960px; margin: 0 auto; padding: 0 20px; }

/* Nav */
nav {
  border-bottom: 1px solid var(--border);
  padding: 16px 0;
  position: sticky;
  top: 0;
  background: rgba(10, 10, 15, 0.95);
  backdrop-filter: blur(10px);
  z-index: 100;
}
nav .container { display: flex; justify-content: space-between; align-items: center; }
nav .logo { font-size: 1.4rem; font-weight: 700; color: var(--text); }
nav .logo span { color: var(--accent); }
nav .nav-links { display: flex; gap: 24px; }
nav .nav-links a { color: var(--text-muted); font-size: 0.9rem; }
nav .nav-links a:hover { color: var(--text); }

/* Hero */
.hero {
  text-align: center;
  padding: 80px 0 60px;
}
.hero h1 {
  font-size: 3rem;
  font-weight: 800;
  margin-bottom: 16px;
  background: linear-gradient(135deg, var(--text), var(--accent));
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}
.hero p { color: var(--text-muted); font-size: 1.2rem; max-width: 600px; margin: 0 auto; }

/* Cards */
.tools-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 24px;
  padding: 40px 0;
}
.tool-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 32px;
  transition: all 0.3s ease;
  cursor: pointer;
}
.tool-card:hover {
  border-color: var(--accent);
  box-shadow: 0 0 30px var(--accent-glow);
  transform: translateY(-2px);
}
.tool-card .icon { font-size: 2.5rem; margin-bottom: 16px; }
.tool-card h3 { font-size: 1.3rem; margin-bottom: 8px; }
.tool-card p { color: var(--text-muted); font-size: 0.9rem; }

/* Tool Page */
.tool-page { padding: 40px 0 80px; }
.tool-page h1 { font-size: 2rem; margin-bottom: 8px; }
.tool-page .subtitle { color: var(--text-muted); margin-bottom: 32px; }

.input-group { margin-bottom: 20px; }
.input-group label { display: block; margin-bottom: 8px; font-weight: 500; font-size: 0.9rem; }

textarea, input[type="text"], select {
  width: 100%;
  padding: 14px 16px;
  background: var(--bg-input);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  color: var(--text);
  font-size: 1rem;
  font-family: inherit;
  resize: vertical;
  transition: border-color 0.2s;
}
textarea:focus, input[type="text"]:focus, select:focus {
  outline: none;
  border-color: var(--accent);
}
textarea { min-height: 160px; }

select {
  appearance: none;
  cursor: pointer;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' fill='%238888a0' viewBox='0 0 16 16'%3E%3Cpath d='M8 11L3 6h10z'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 16px center;
}

.btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 14px 32px;
  background: var(--accent);
  color: white;
  border: none;
  border-radius: var(--radius);
  font-size: 1rem;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.2s;
  width: 100%;
  justify-content: center;
}
.btn:hover { background: var(--accent-hover); box-shadow: 0 0 20px var(--accent-glow); }
.btn:disabled { opacity: 0.5; cursor: not-allowed; }
.btn.loading { pointer-events: none; }
.btn.loading::after {
  content: '';
  width: 16px;
  height: 16px;
  border: 2px solid white;
  border-top-color: transparent;
  border-radius: 50%;
  animation: spin 0.6s linear infinite;
}
@keyframes spin { to { transform: rotate(360deg); } }

/* Result */
.result-area {
  margin-top: 24px;
  padding: 24px;
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  display: none;
  white-space: pre-wrap;
  word-wrap: break-word;
  line-height: 1.7;
}
.result-area.visible { display: block; }
.result-area.error { border-color: var(--error); color: var(--error); }
.result-area img { max-width: 100%; border-radius: 8px; }

/* Ad slots */
.ad-slot {
  text-align: center;
  padding: 12px 0;
  min-height: 90px;
}

/* Footer */
footer {
  border-top: 1px solid var(--border);
  padding: 40px 0;
  text-align: center;
  color: var(--text-muted);
  font-size: 0.85rem;
}
footer .crypto-tip {
  margin: 16px 0;
  padding: 16px;
  background: var(--bg-card);
  border-radius: var(--radius);
  display: inline-block;
}
footer .crypto-tip code {
  color: var(--accent);
  font-size: 0.8rem;
  word-break: break-all;
}

/* Lead modal */
.modal-overlay {
  display: none;
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,0.7);
  z-index: 200;
  align-items: center;
  justify-content: center;
}
.modal-overlay.visible { display: flex; }
.modal {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 40px;
  max-width: 420px;
  width: 90%;
  text-align: center;
}
.modal h2 { margin-bottom: 8px; }
.modal p { color: var(--text-muted); margin-bottom: 24px; font-size: 0.9rem; }
.modal input { margin-bottom: 16px; }
.modal .skip { display: block; margin-top: 12px; color: var(--text-muted); font-size: 0.85rem; cursor: pointer; }

/* How it works */
.how-it-works { padding: 60px 0; }
.how-it-works h2 { text-align: center; font-size: 1.8rem; margin-bottom: 40px; }
.steps { display: grid; grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); gap: 32px; }
.step { text-align: center; }
.step .num {
  width: 48px; height: 48px;
  background: var(--accent);
  border-radius: 50%;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-weight: 700;
  font-size: 1.2rem;
  margin-bottom: 16px;
}
.step h3 { margin-bottom: 8px; }
.step p { color: var(--text-muted); font-size: 0.85rem; }

/* Responsive */
@media (max-width: 640px) {
  .hero h1 { font-size: 2rem; }
  .hero p { font-size: 1rem; }
  nav .nav-links { gap: 16px; }
  .tool-card { padding: 24px; }
}
