:root {
  color-scheme: dark;
  --bg: #060814;
  --bg-elevated: #0f1425;
  --surface: rgba(15, 20, 37, 0.78);
  --surface-strong: rgba(18, 24, 44, 0.9);
  --border: rgba(148, 163, 184, 0.18);
  --text: #f8fafc;
  --muted: #94a3b8;
  --primary: #22d3ee;
  --primary-deep: #0891b2;
  --secondary: #8b5cf6;
  --accent: #34d399;
  --shadow: 0 24px 60px rgba(5, 8, 20, 0.55);
  --radius-lg: 24px;
  --radius-md: 18px;
  --radius-sm: 12px;
  --transition: 0.2s ease;
}

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

body {
  font-family: "SF Pro Display", "SF Pro Text", -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  background: radial-gradient(circle at 20% 0%, rgba(34, 211, 238, 0.18), transparent 35%),
    radial-gradient(circle at 80% 10%, rgba(139, 92, 246, 0.18), transparent 40%),
    linear-gradient(160deg, #05070f 0%, #070b1d 45%, #0b1124 100%);
  color: var(--text);
  line-height: 1.6;
  min-height: 100vh;
  position: relative;
}

body::before,
body::after {
  content: "";
  position: fixed;
  inset: -30% -10% auto -10%;
  height: 60vh;
  background: radial-gradient(circle at 30% 30%, rgba(34, 211, 238, 0.25), transparent 55%),
    radial-gradient(circle at 70% 20%, rgba(139, 92, 246, 0.22), transparent 60%);
  filter: blur(40px);
  opacity: 0.6;
  z-index: -1;
  animation: floatGlow 12s ease-in-out infinite alternate;
}

body::after {
  inset: auto -20% -40% -20%;
  height: 60vh;
  background: radial-gradient(circle at 20% 60%, rgba(52, 211, 153, 0.22), transparent 60%),
    radial-gradient(circle at 80% 70%, rgba(34, 211, 238, 0.18), transparent 55%);
  animation-delay: 2s;
}

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

img {
  max-width: 100%;
  display: block;
}

.container {
  width: min(1200px, 92vw);
  margin: 0 auto;
}

header {
  position: sticky;
  top: 0;
  z-index: 20;
  backdrop-filter: blur(18px);
  background: rgba(6, 8, 20, 0.6);
  border-bottom: 1px solid rgba(148, 163, 184, 0.12);
}

.navbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 18px 0;
}

.brand {
  display: flex;
  align-items: center;
  gap: 12px;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  font-size: 0.9rem;
  color: var(--text);
}

.brand-badge {
  width: 40px;
  height: 40px;
  border-radius: 14px;
  display: grid;
  place-items: center;
  background: linear-gradient(135deg, rgba(34, 211, 238, 0.9), rgba(139, 92, 246, 0.9));
  color: #05070f;
  font-weight: 700;
  box-shadow: var(--shadow);
}

.nav-links {
  display: flex;
  align-items: center;
  gap: 24px;
  margin-left: auto;
}

.nav-links a {
  font-weight: 600;
  color: rgba(248, 250, 252, 0.78);
  padding-bottom: 6px;
  border-bottom: 2px solid transparent;
  transition: color var(--transition), border-color var(--transition);
}

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

.nav-links a.active {
  color: var(--text);
  border-color: var(--primary);
}

.hero {
  padding: 90px 0 70px;
}

.hero-content {
  display: grid;
  gap: 28px;
}

.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 6px 16px;
  border-radius: 999px;
  background: rgba(34, 211, 238, 0.12);
  color: var(--primary);
  font-weight: 600;
  font-size: 0.85rem;
}

.hero h1 {
  font-size: clamp(2.6rem, 4vw, 3.8rem);
  line-height: 1.08;
  max-width: 760px;
}

.hero p {
  font-size: 1.05rem;
  color: rgba(226, 232, 240, 0.9);
  max-width: 760px;
}

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

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  padding: 12px 24px;
  border-radius: 999px;
  border: 1px solid transparent;
  font-weight: 600;
  transition: transform var(--transition), box-shadow var(--transition), border-color var(--transition);
  cursor: pointer;
}

.btn-primary {
  background: linear-gradient(135deg, var(--primary), var(--secondary));
  color: #05070f;
  box-shadow: 0 20px 50px rgba(34, 211, 238, 0.3);
}

.btn-primary:hover {
  transform: translateY(-2px);
}

.btn-primary:focus {
  outline: 2px solid rgba(34, 211, 238, 0.7);
  outline-offset: 3px;
}

.btn-secondary {
  background: rgba(248, 250, 252, 0.08);
  border-color: rgba(148, 163, 184, 0.4);
  color: var(--text);
}

.btn-secondary:hover {
  transform: translateY(-2px);
  border-color: rgba(34, 211, 238, 0.6);
}

.section {
  padding: 70px 0;
}

.section-title {
  display: grid;
  gap: 10px;
  margin-bottom: 32px;
}

.section-title h2 {
  font-size: clamp(1.8rem, 3vw, 2.4rem);
}

.section-title p {
  color: var(--muted);
  max-width: 650px;
}

.grid {
  display: grid;
  gap: 24px;
}

.grid-2 {
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
}

.grid-3 {
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
}

.card {
  background: var(--surface);
  border-radius: var(--radius-md);
  padding: 28px;
  border: 1px solid var(--border);
  box-shadow: var(--shadow);
  backdrop-filter: blur(14px);
}

.card strong {
  color: var(--text);
}

.card h3 {
  font-size: 1.2rem;
  margin-bottom: 12px;
}

.card p,
.card li {
  color: var(--muted);
}

.card ul {
  list-style: none;
  display: grid;
  gap: 10px;
  padding-left: 0;
}

.card.featured {
  border-color: rgba(34, 211, 238, 0.6);
  box-shadow: 0 30px 60px rgba(34, 211, 238, 0.25);
}

.badge {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 6px 14px;
  border-radius: 999px;
  background: rgba(139, 92, 246, 0.2);
  color: var(--secondary);
  font-weight: 600;
  font-size: 0.8rem;
  margin-bottom: 14px;
}

.download-grid {
  display: grid;
  gap: 16px;
}

.download-item {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 14px 18px;
  border-radius: var(--radius-sm);
  background: var(--surface-strong);
  border: 1px solid var(--border);
  transition: transform var(--transition), border-color var(--transition);
}

.download-item:hover {
  transform: translateY(-2px);
  border-color: rgba(34, 211, 238, 0.6);
}

.download-note {
  color: var(--muted);
  margin-top: 12px;
  font-size: 0.95rem;
}

.legend {
  color: var(--muted);
  font-size: 0.9rem;
  line-height: 1.5;
  margin-top: 10px;
}

.demo-grid {
  display: grid;
  gap: 28px;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  align-items: start;
}

.field {
  display: grid;
  gap: 10px;
}

label {
  font-weight: 600;
  color: var(--text);
}

textarea,
input[type="text"],
input[type="file"] {
  width: 100%;
  padding: 12px 14px;
  border-radius: var(--radius-sm);
  border: 1px solid var(--border);
  background: rgba(15, 20, 37, 0.8);
  color: var(--text);
  font-family: inherit;
}

select {
  width: 100%;
  padding: 12px 14px;
  border-radius: var(--radius-sm);
  border: 1px solid var(--border);
  background: rgba(15, 20, 37, 0.8);
  color: var(--text);
  font-family: inherit;
  appearance: none;
}

textarea {
  min-height: 180px;
  resize: vertical;
}

.output-card {
  background: var(--surface);
  border-radius: var(--radius-lg);
  border: 1px solid var(--border);
  padding: 22px;
  display: grid;
  gap: 16px;
}

.output-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  flex-wrap: wrap;
}

.output-actions {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
}

.output-block {
  background: rgba(9, 12, 25, 0.7);
  padding: 16px;
  border-radius: var(--radius-sm);
  border: 1px solid rgba(148, 163, 184, 0.2);
  white-space: pre-wrap;
  font-size: 0.95rem;
}

.tabs {
  display: inline-flex;
  border-radius: 999px;
  background: rgba(15, 20, 37, 0.6);
  border: 1px solid var(--border);
  padding: 4px;
  gap: 4px;
}

.mode-toggle {
  display: flex;
  gap: 8px;
  margin-top: 16px;
  flex-wrap: wrap;
}

.mode-toggle .tab-btn {
  border: 1px solid var(--border);
  background: rgba(15, 20, 37, 0.6);
}

.tab-btn {
  padding: 8px 18px;
  border-radius: 999px;
  border: none;
  background: transparent;
  font-weight: 600;
  color: var(--muted);
  cursor: pointer;
}

.tab-btn[aria-selected="true"] {
  background: rgba(34, 211, 238, 0.15);
  color: var(--text);
}

.copy-btn {
  padding: 8px 14px;
  border-radius: 999px;
  border: 1px solid rgba(148, 163, 184, 0.4);
  background: transparent;
  color: var(--text);
  cursor: pointer;
  font-weight: 600;
}

.copy-btn:hover {
  border-color: rgba(34, 211, 238, 0.6);
}

.status-pill {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 6px 12px;
  border-radius: 999px;
  background: rgba(52, 211, 153, 0.15);
  color: var(--accent);
  font-weight: 600;
  font-size: 0.85rem;
}

.toast {
  position: fixed;
  right: 24px;
  bottom: 24px;
  background: rgba(15, 20, 37, 0.96);
  border: 1px solid rgba(248, 250, 252, 0.12);
  color: var(--text);
  padding: 12px 18px;
  border-radius: var(--radius-sm);
  box-shadow: var(--shadow);
  opacity: 0;
  transform: translateY(10px);
  transition: opacity var(--transition), transform var(--transition);
  z-index: 30;
}

.toast.is-visible {
  opacity: 1;
  transform: translateY(0);
}

.modal {
  position: fixed;
  inset: 0;
  background: rgba(5, 8, 20, 0.7);
  display: none;
  align-items: center;
  justify-content: center;
  padding: 24px;
  z-index: 40;
}

.modal.is-open {
  display: flex;
}

.modal-card {
  background: var(--surface-strong);
  padding: 26px;
  border-radius: var(--radius-md);
  border: 1px solid var(--border);
  max-width: 460px;
  width: 100%;
  text-align: center;
  box-shadow: var(--shadow);
}

.modal-card p {
  color: var(--muted);
  margin: 12px 0 22px;
}

footer {
  padding: 40px 0 60px;
  border-top: 1px solid rgba(148, 163, 184, 0.12);
  color: var(--muted);
}

.footer-grid {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 16px;
  font-size: 0.9rem;
}

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

@keyframes floatGlow {
  0% {
    transform: translateY(0) scale(1);
  }
  100% {
    transform: translateY(-12px) scale(1.05);
  }
}

@media (max-width: 720px) {
  .navbar {
    flex-direction: column;
    align-items: flex-start;
    gap: 16px;
  }

  .nav-links {
    width: 100%;
    justify-content: space-between;
  }

  .hero {
    padding-top: 70px;
  }
}
