:root {
  --bg-dark-900: #0f172a;
  --bg-dark-850: #131d35;
  --bg-dark-800: #1e293b;
  --bg-dark-700: #334155;
  --bg-dark-600: #475569;
  --brand-500: #10b981;
  --brand-600: #059669;
  --brand-400: #34d399;
  --text-main: #f8fafc;
  --text-muted: #94a3b8;
  --text-dim: #64748b;
  --border-glass: rgba(255, 255, 255, 0.08);
  --border-focus: #10b981;
  --font-mono: "JetBrains Mono", ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, monospace;
  --font-sans: "Plus Jakarta Sans", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
}

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

body {
  background-color: var(--bg-dark-900);
  color: var(--text-main);
  font-family: var(--font-sans);
  line-height: 1.6;
  overflow-x: hidden;
  position: relative;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

/* Background Gradients */
body::before {
  content: "";
  position: fixed;
  top: -15%;
  left: 25%;
  width: 50vw;
  height: 50vw;
  background: radial-gradient(circle, rgba(16, 185, 129, 0.08) 0%, rgba(56, 189, 248, 0.04) 50%, transparent 70%);
  z-index: -1;
  filter: blur(80px);
  pointer-events: none;
}

/* Scrollbar */
::-webkit-scrollbar {
  width: 6px;
  height: 6px;
}
::-webkit-scrollbar-track {
  background: rgba(15, 23, 42, 0.6);
}
::-webkit-scrollbar-thumb {
  background: var(--bg-dark-700);
  border-radius: 3px;
}
::-webkit-scrollbar-thumb:hover {
  background: var(--bg-dark-600);
}

.container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 20px;
  width: 100%;
}

/* Header */
header {
  position: sticky;
  top: 0;
  z-index: 40;
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  background: rgba(15, 23, 42, 0.85);
  border-bottom: 1px solid var(--border-glass);
}

.nav-wrap {
  display: flex;
  justify-content: space-between;
  align-items: center;
  height: 68px;
}

.logo-group {
  display: flex;
  align-items: center;
  gap: 12px;
  text-decoration: none;
  color: inherit;
}

.logo-img-box {
  width: 40px;
  height: 40px;
  border-radius: 12px;
  background: var(--bg-dark-800);
  border: 1px solid rgba(255, 255, 255, 0.1);
  padding: 5px;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 4px 15px rgba(16, 185, 129, 0.12);
  transition: all 0.2s;
}

.logo-group:hover .logo-img-box {
  border-color: rgba(16, 185, 129, 0.5);
  box-shadow: 0 4px 18px rgba(16, 185, 129, 0.25);
}

.logo-img-box img {
  width: 100%;
  height: 100%;
  object-fit: contain;
}

.logo-title {
  display: flex;
  align-items: center;
  gap: 8px;
}

.gradient-text {
  background: linear-gradient(135deg, #34d399 0%, #38bdf8 50%, #818cf8 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  font-weight: 800;
  font-size: 1.25rem;
  letter-spacing: -0.02em;
}

.nav-tag {
  font-size: 0.72rem;
  padding: 2px 8px;
  border-radius: 9999px;
  background: rgba(16, 185, 129, 0.1);
  color: var(--brand-400);
  border: 1px solid rgba(16, 185, 129, 0.25);
  font-weight: 600;
}

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

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

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

.btn-brand {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 8px 18px;
  border-radius: 8px;
  background: linear-gradient(135deg, #10b981 0%, #059669 100%);
  color: #ffffff;
  font-size: 0.88rem;
  font-weight: 600;
  text-decoration: none;
  border: none;
  cursor: pointer;
  box-shadow: 0 4px 14px rgba(16, 185, 129, 0.35);
  transition: all 0.2s ease;
}

.btn-brand:hover {
  box-shadow: 0 6px 20px rgba(16, 185, 129, 0.5);
  transform: translateY(-1px);
}

.btn-outline {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 8px 16px;
  border-radius: 8px;
  background: var(--bg-dark-800);
  color: var(--text-muted);
  font-size: 0.88rem;
  font-weight: 600;
  text-decoration: none;
  border: 1px solid var(--border-glass);
  cursor: pointer;
  transition: all 0.2s;
}

.btn-outline:hover {
  background: var(--bg-dark-700);
  color: var(--text-main);
  border-color: rgba(255, 255, 255, 0.15);
}

/* Hero Section */
.hero {
  padding: 56px 0 36px;
  text-align: center;
}

.hero-badge {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 4px 14px;
  border-radius: 9999px;
  background: rgba(16, 185, 129, 0.1);
  border: 1px solid rgba(16, 185, 129, 0.25);
  color: var(--brand-400);
  font-size: 0.82rem;
  font-weight: 600;
  margin-bottom: 18px;
}

.hero h1 {
  font-size: 2.8rem;
  font-weight: 800;
  letter-spacing: -0.03em;
  line-height: 1.25;
  margin-bottom: 14px;
}

.hero p {
  font-size: 1.1rem;
  color: var(--text-muted);
  max-width: 680px;
  margin: 0 auto 36px;
}

.feature-chips {
  display: flex;
  justify-content: center;
  flex-wrap: wrap;
  gap: 12px;
  margin-bottom: 40px;
}

.chip {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 6px 14px;
  border-radius: 8px;
  background: rgba(30, 41, 59, 0.6);
  border: 1px solid var(--border-glass);
  font-size: 0.85rem;
  color: var(--text-muted);
}

.chip-dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--brand-400);
}

/* Glass Panels */
.glass-panel {
  background: rgba(30, 41, 59, 0.7);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border: 1px solid var(--border-glass);
  border-radius: 16px;
  box-shadow: 0 16px 36px rgba(0, 0, 0, 0.35);
  overflow: hidden;
}

.panel-header {
  padding: 20px 24px;
  border-bottom: 1px solid var(--border-glass);
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 12px;
}

.panel-title {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 1.15rem;
  font-weight: 700;
}

.panel-body {
  padding: 24px;
}

/* Generator Form */
.form-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(190px, 1fr));
  gap: 16px;
  margin-bottom: 24px;
}

.form-group {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.form-group label {
  font-size: 0.8rem;
  font-weight: 600;
  color: var(--text-muted);
}

.glass-input {
  background: rgba(15, 23, 42, 0.6);
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 8px;
  padding: 10px 12px;
  color: var(--text-main);
  font-family: var(--font-mono);
  font-size: 0.9rem;
  outline: none;
  transition: all 0.2s;
}

.glass-input:focus {
  border-color: var(--brand-500);
  box-shadow: 0 0 0 2px rgba(16, 185, 129, 0.2);
}

/* Tabs */
.tabs-nav {
  display: flex;
  gap: 6px;
  border-bottom: 1px solid var(--border-glass);
  margin-bottom: 18px;
  overflow-x: auto;
  padding-bottom: 2px;
}

.tab-btn {
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 8px 14px;
  background: transparent;
  border: none;
  border-bottom: 2px solid transparent;
  color: var(--text-muted);
  font-size: 0.88rem;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.2s;
  white-space: nowrap;
}

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

.tab-btn.active {
  color: var(--brand-400);
  border-bottom-color: var(--brand-500);
  background: rgba(16, 185, 129, 0.06);
  border-radius: 6px 6px 0 0;
}

.tab-content {
  display: none;
}

.tab-content.active {
  display: block;
  animation: fadeIn 0.2s ease-in-out;
}

@keyframes fadeIn {
  from { opacity: 0; transform: translateY(3px); }
  to { opacity: 1; transform: translateY(0); }
}

/* Code Snippet Box */
.code-box {
  background: rgba(15, 23, 42, 0.8);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 10px;
  padding: 16px 20px;
  margin-bottom: 14px;
}

.code-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 10px;
  font-size: 0.8rem;
  color: var(--text-dim);
}

.code-box pre {
  font-family: var(--font-mono);
  font-size: 0.92rem;
  line-height: 1.55;
  color: #7dd3fc;
  overflow-x: auto;
  white-space: pre-wrap;
  word-break: break-all;
}

.btn-copy {
  padding: 5px 12px;
  font-size: 0.8rem;
  background: rgba(16, 185, 129, 0.15);
  border: 1px solid rgba(16, 185, 129, 0.35);
  color: var(--brand-400);
  border-radius: 6px;
  cursor: pointer;
  font-weight: 600;
  transition: all 0.2s;
}

.btn-copy:hover {
  background: rgba(16, 185, 129, 0.3);
  color: #fff;
}

.tip-box {
  background: rgba(16, 185, 129, 0.06);
  border-left: 3px solid var(--brand-500);
  padding: 12px 16px;
  border-radius: 0 8px 8px 0;
  font-size: 0.86rem;
  color: #a7f3d0;
  display: flex;
  gap: 10px;
  align-items: flex-start;
}

.tip-box svg {
  width: 16px;
  height: 16px;
  flex-shrink: 0;
  margin-top: 3px;
  color: var(--brand-400);
}

/* Feature Cards Grid */
.features-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 20px;
  margin-bottom: 56px;
}

.feature-card {
  background: rgba(30, 41, 59, 0.7);
  border: 1px solid var(--border-glass);
  border-radius: 14px;
  padding: 22px;
}

.feature-card h3 {
  font-size: 1.05rem;
  font-weight: 700;
  margin-bottom: 8px;
  display: flex;
  align-items: center;
  gap: 8px;
}

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

/* FAQ */
.faq-wrap {
  max-width: 800px;
  margin: 0 auto 56px;
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.faq-item {
  background: rgba(30, 41, 59, 0.7);
  border: 1px solid var(--border-glass);
  border-radius: 10px;
  overflow: hidden;
}

.faq-q {
  padding: 16px 20px;
  cursor: pointer;
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-weight: 600;
  font-size: 0.95rem;
}

.faq-q:hover {
  background: rgba(255, 255, 255, 0.02);
}

.faq-icon {
  width: 16px;
  height: 16px;
  transition: transform 0.2s;
  color: var(--text-dim);
}

.faq-item.active .faq-icon {
  transform: rotate(180deg);
}

.faq-a {
  padding: 0 20px 16px;
  color: var(--text-muted);
  font-size: 0.9rem;
  line-height: 1.65;
  display: none;
}

.faq-item.active .faq-a {
  display: block;
}

/* Footer */
footer {
  margin-top: auto;
  border-top: 1px solid var(--border-glass);
  padding: 28px 0;
  background: rgba(15, 23, 42, 0.8);
  font-size: 0.85rem;
  color: var(--text-dim);
}

.footer-wrap {
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 14px;
}

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

.footer-links a {
  color: var(--text-muted);
  text-decoration: none;
  transition: color 0.2s;
}

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

/* Toast */
.toast {
  position: fixed;
  bottom: 24px;
  right: 24px;
  background: var(--brand-500);
  color: #ffffff;
  padding: 10px 18px;
  border-radius: 8px;
  font-size: 0.88rem;
  font-weight: 600;
  box-shadow: 0 8px 24px rgba(16, 185, 129, 0.4);
  transform: translateY(100px);
  opacity: 0;
  transition: all 0.25s cubic-bezier(0.16, 1, 0.3, 1);
  z-index: 1000;
}

.toast.show {
  transform: translateY(0);
  opacity: 1;
}

/* Responsive */
@media (max-width: 768px) {
  .hero h1 {
    font-size: 2.1rem;
  }
  .nav-links {
    display: none;
  }
  .form-grid {
    grid-template-columns: 1fr;
  }
  .footer-wrap {
    flex-direction: column;
    text-align: center;
  }
}
