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

:root {
  --bg: #121215;
  --surface: #1a1a1e;
  --surface-glass: rgba(30, 30, 35, 0.55);
  --border: rgba(255, 255, 255, 0.10);
  --text: #dcdcde;
  --text-2: rgba(220, 220, 222, 0.65);
  --text-3: rgba(220, 220, 222, 0.45);
  --accent: #c4b5fd;
  --accent-dim: rgba(196, 181, 253, 0.10);
  --fluid-1: #1a1a3e;
  --fluid-2: #2d1b4e;
  --fluid-3: #0f2a3d;
  --sans: "Inter", -apple-system, system-ui, sans-serif;
  --serif: "Newsreader", Georgia, serif;
}

html { scroll-behavior: smooth; }

body {
  background: var(--bg);
  color: var(--text);
  font-family: var(--sans);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  overflow-x: hidden;
}

::selection {
  background: rgba(196, 181, 253, 0.30);
  color: #fff;
}

/* Fluid background */
.fluid-bg {
  position: fixed; inset: 0; z-index: -1; overflow: hidden; pointer-events: none;
}
.blob {
  position: absolute; border-radius: 50%; mix-blend-mode: screen;
}
.blob-1 {
  top: -15%; left: -10%; width: 55vw; height: 55vw;
  background: rgba(30, 30, 66, 0.45); filter: blur(120px); opacity: 0.55;
  animation: drift1 22s ease-in-out infinite;
}
.blob-2 {
  bottom: -15%; right: -10%; width: 60vw; height: 60vw;
  background: rgba(50, 31, 82, 0.35); filter: blur(140px); opacity: 0.45;
  animation: drift2 28s ease-in-out infinite;
}
.blob-3 {
  top: 40%; left: 30%; width: 45vw; height: 45vw;
  background: rgba(19, 46, 66, 0.40); filter: blur(100px); opacity: 0.35;
  animation: drift3 32s ease-in-out infinite;
}

@keyframes drift1 {
  0%, 100% { transform: translate(-10%, -10%) scale(1); }
  50% { transform: translate(15%, 10%) scale(1.15); }
}
@keyframes drift2 {
  0%, 100% { transform: translate(15%, 10%) scale(1.1); }
  50% { transform: translate(-15%, -15%) scale(0.9); }
}
@keyframes drift3 {
  0%, 100% { transform: translate(0%, 20%) scale(0.9); }
  50% { transform: translate(25%, -5%) scale(1.2); }
}

/* Glass panel */
.glass {
  background: var(--surface-glass);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border: 1px solid var(--border);
}

/* Container */
.container {
  max-width: 760px;
  margin: 0 auto;
  padding: 0 1.5rem;
}

/* Nav */
nav {
  position: fixed; top: 0; left: 0; right: 0; z-index: 100;
  pointer-events: none;
}
.nav-inner {
  max-width: 760px; margin: 0 auto; padding: 0 1.5rem;
  height: 56px; display: flex; align-items: center; justify-content: space-between;
  pointer-events: auto;
  border-radius: 12px; margin-top: 0.5rem;
  background: transparent;
  transition: background 0.3s, backdrop-filter 0.3s, -webkit-backdrop-filter 0.3s;
}
nav.scrolled .nav-inner {
  background: rgba(18, 18, 21, 0.45);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
}
.nav-logo {
  font-size: 0.85rem; font-weight: 500; color: var(--text-3);
  text-decoration: none; letter-spacing: 0.04em; text-transform: lowercase;
}
.nav-logo:hover { color: var(--text-2); }
.nav-links {
  display: flex; align-items: center; gap: 1.5rem;
}
.nav-links a {
  font-size: 0.75rem; color: var(--text-3); text-decoration: none;
  transition: color 0.2s; letter-spacing: 0.02em;
}
.nav-links a:hover { color: var(--text-2); }

/* Animations */
@keyframes fadeIn {
  from { opacity: 0; filter: blur(6px); transform: translateY(12px); }
  to { opacity: 1; filter: blur(0); transform: translateY(0); }
}

.fade-in {
  opacity: 0; filter: blur(6px); transform: translateY(12px);
  transition: opacity 0.8s cubic-bezier(0.25, 0.1, 0.25, 1), filter 0.8s cubic-bezier(0.25, 0.1, 0.25, 1), transform 0.8s cubic-bezier(0.25, 0.1, 0.25, 1);
}
.fade-in.visible { opacity: 1; filter: blur(0); transform: translateY(0); }
.fade-in.delay-1 { transition-delay: 0.12s; }
.fade-in.delay-2 { transition-delay: 0.24s; }
.fade-in.delay-3 { transition-delay: 0.36s; }

/* Hero */
.hero {
  min-height: 100vh;
  display: flex; flex-direction: column;
  justify-content: center;
  padding: 8rem 0 1.5rem;
  gap: 4rem;
}
.hero-copy { animation: fadeIn 0.9s cubic-bezier(0.25, 0.1, 0.25, 1) both; }
.hero h1 {
  font-family: var(--serif); font-weight: 400;
  font-size: clamp(2.5rem, 5.5vw, 3.5rem);
  line-height: 1.15; letter-spacing: -0.025em; margin-bottom: 1rem;
}
.hero h1 em {
  font-style: italic; color: var(--accent);
}
.hero-sub {
  font-size: 0.95rem; color: var(--text-2); max-width: 440px;
  line-height: 1.7; font-weight: 300;
}

/* Demo box */
.demo-box {
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 1.75rem 2rem 1.5rem;
  max-width: 100%;
  animation: fadeIn 0.9s cubic-bezier(0.25, 0.1, 0.25, 1) 0.2s both;
}
.demo-header {
  display: flex; align-items: center; gap: 0.65rem;
  margin-bottom: 1.25rem;
}
.demo-dot {
  width: 7px; height: 7px; border-radius: 50%;
  background: var(--accent); opacity: 0.4;
  transition: opacity 0.3s;
}
.demo-dot.active {
  opacity: 1;
  animation: pulse 1.5s ease-in-out infinite;
}
@keyframes pulse {
  0%, 100% { opacity: 1; } 50% { opacity: 0.35; }
}
.demo-status {
  font-size: 0.6rem; text-transform: uppercase; letter-spacing: 0.1em;
  color: var(--text-3);
}
.mute-btn {
  margin-left: auto; background: none; border: none;
  font-size: 0.6rem; text-transform: uppercase; letter-spacing: 0.1em;
  color: var(--text-3); font-family: var(--sans);
  cursor: pointer; transition: color 0.2s; padding: 0.2rem;
}
.mute-btn:hover { opacity: 0.7; }
.waveform-canvas {
  display: block; width: 100%; height: 40px; margin-bottom: 1.25rem;
}
.demo-text {
  font-size: 0.9rem; color: var(--text-2); font-weight: 300;
  line-height: 1.65; min-height: 3.3em;
}
.demo-text .cursor {
  display: inline-block; width: 1.5px; height: 0.95em;
  background: var(--accent); vertical-align: text-bottom;
  margin-left: 1px; opacity: 0.7;
  animation: blink 1s step-end infinite;
}
@keyframes blink {
  0%, 100% { opacity: 0.7; } 50% { opacity: 0; }
}

/* Hero CTA */
.hero-cta {
  display: inline-flex; align-items: center; gap: 0.5rem;
  margin-top: 0.5rem;
  color: var(--accent); text-decoration: none;
  font-size: 0.85rem; font-weight: 400; letter-spacing: 0.01em;
  transition: opacity 0.25s;
  animation: fadeIn 0.9s cubic-bezier(0.25, 0.1, 0.25, 1) 0.4s both;
}
.hero-cta:hover { opacity: 0.7; }
.hero-cta svg {
  width: 14px; height: 14px; opacity: 0.7;
  transition: transform 0.25s;
}
.hero-cta:hover svg { transform: translateX(3px); }

/* Divider */
.divider { height: 1px; background: var(--border); margin: 2rem 0; }

/* Section heading */
.section-label {
  font-size: 0.7rem; text-transform: uppercase; letter-spacing: 0.2em;
  color: var(--text-3); margin-bottom: 2.5rem;
}

/* Steps */
.steps { padding: 3rem 0; }
.steps-list { display: flex; flex-direction: column; gap: 1.75rem; }
.step {
  display: flex; gap: 1.25rem; align-items: flex-start;
}
.step-num {
  font-family: var(--serif); font-size: 1.1rem; color: var(--accent);
  flex-shrink: 0; width: 1.5rem; padding-top: 0.1rem;
}
.step h3 {
  font-size: 0.9rem; font-weight: 500; margin-bottom: 0.3rem;
}
.step p {
  font-size: 0.825rem; color: var(--text-2); line-height: 1.65; font-weight: 300;
}

/* Style switcher */
.style-switch { padding: 3rem 0; }
.style-switch-desc {
  font-size: 0.9rem; color: var(--text-2); font-weight: 300;
  line-height: 1.65; margin-bottom: 2rem; max-width: 440px;
}
.style-options {
  display: grid; grid-template-columns: repeat(3, 1fr); gap: 1px;
  background: var(--border); border-radius: 12px; overflow: hidden;
}
.style-opt {
  background: var(--surface); padding: 1.5rem;
  cursor: pointer; transition: background-color 0.3s ease;
  border: none; color: var(--text); text-align: left;
  font-family: var(--sans);
}
.style-opt:hover { background: rgba(255, 255, 255, 0.05); }
.style-opt.active { background: rgba(196, 181, 253, 0.08); }
.style-opt-name {
  font-size: 0.85rem; font-weight: 500; margin-bottom: 0.4rem;
  display: flex; align-items: center; gap: 0.5rem;
}
.style-opt.active .style-opt-name { color: var(--accent); }
.style-opt-preview {
  font-size: 0.75rem; color: var(--text-3); line-height: 1.5; font-weight: 300;
}

@media (max-width: 560px) {
  .style-options { grid-template-columns: 1fr; }
}

/* Features */
.features { padding: 3rem 0; }
.features-grid {
  display: grid; grid-template-columns: 1fr 1fr; gap: 1.25rem;
}
.feature-card {
  padding: 1.75rem; border-radius: 16px;
  transition: background-color 0.3s ease;
  will-change: background-color;
}
.feature-card:hover { background-color: rgba(255, 255, 255, 0.06); }
.feature-icon {
  width: 2rem; height: 2rem; margin-bottom: 1rem;
  color: var(--accent); opacity: 0.7;
}
.feature-icon svg { width: 100%; height: 100%; }
.feature-card h3 {
  font-size: 0.9rem; font-weight: 500; margin-bottom: 0.5rem;
  letter-spacing: -0.01em;
}
.feature-card p {
  font-size: 0.825rem; color: var(--text-2); line-height: 1.65; font-weight: 300;
}

/* Testimonial */
.testimonial { padding: 3rem 0; }
.testimonial blockquote {
  font-family: var(--serif); font-style: italic;
  font-size: clamp(1.1rem, 2.5vw, 1.3rem);
  line-height: 1.6; color: var(--text-2); margin-bottom: 1.25rem;
  max-width: 540px;
}
.testimonial cite {
  font-style: normal; font-size: 0.8rem; color: var(--text-3);
}
.compat-logos {
  display: flex; gap: 1.75rem; margin-top: auto;
  align-items: center; padding-bottom: 1.5rem;
}
.mobile-only { display: none; }
.compat-logos span {
  font-size: 0.7rem; color: var(--text-3); font-weight: 400;
  letter-spacing: 0.02em; opacity: 0.5;
}

/* Pricing */
.pricing { padding: 3rem 0; }
.pricing h2 {
  font-family: var(--serif); font-size: clamp(1.75rem, 4vw, 2.25rem);
  font-weight: 400; letter-spacing: -0.02em; margin-bottom: 2rem;
}
.pricing-grid {
  display: grid; grid-template-columns: repeat(3, 1fr); gap: 1px;
  background: var(--border); border-radius: 16px; overflow: hidden;
}
.plan {
  background: var(--surface); padding: 2rem;
  display: flex; flex-direction: column;
}
.plan-name {
  font-size: 0.8rem; font-weight: 500; margin-bottom: 0.75rem;
  letter-spacing: 0.02em;
}
.plan-price {
  font-family: var(--serif); font-size: 1.75rem; margin-bottom: 0.25rem;
}
.plan-price span {
  font-family: var(--sans); font-size: 0.8rem; font-weight: 300;
  color: var(--text-2);
}
.plan-desc {
  font-size: 0.75rem; color: var(--text-3); line-height: 1.5;
  margin-bottom: 1.5rem; flex: 1;
}
.plan-cta {
  display: inline-flex; align-items: center; justify-content: center;
  padding: 0.5rem 1rem; border-radius: 8px; text-decoration: none;
  font-size: 0.8rem; font-weight: 500;
  transition: border-color 0.2s ease, background-color 0.2s ease, opacity 0.2s ease;
  border: 1px solid var(--border); color: var(--text);
}
.plan-cta:hover {
  border-color: rgba(255, 255, 255, 0.15);
  background-color: rgba(255, 255, 255, 0.06);
}
.plan-cta.primary {
  background: var(--accent); color: var(--bg); border-color: var(--accent);
}
.plan-cta.primary:hover { opacity: 0.85; }
.pricing-note {
  margin-top: 1.25rem; font-size: 0.75rem; color: var(--text-3);
  font-weight: 300; max-width: 520px; line-height: 1.6;
}

/* Early Access */
.early-access { padding: 3rem 0; }
.ea-title {
  font-family: var(--serif); font-size: clamp(1.75rem, 4vw, 2.25rem);
  font-weight: 400; letter-spacing: -0.02em; margin-bottom: 1rem;
}
.ea-title em { font-style: italic; color: var(--accent); }
.ea-desc {
  font-size: 0.9rem; color: var(--text-2); font-weight: 300;
  line-height: 1.65; max-width: 520px; margin-bottom: 2.5rem;
}
.ea-steps { display: flex; flex-direction: column; gap: 1.75rem; }
.ea-step { display: flex; gap: 1.25rem; align-items: flex-start; }
.ea-step h3 { font-size: 0.9rem; font-weight: 500; margin-bottom: 0.3rem; }
.ea-step p {
  font-size: 0.825rem; color: var(--text-2); line-height: 1.65; font-weight: 300;
}
.ea-download {
  display: inline-flex; align-items: center; margin-top: 0.75rem;
  padding: 0.5rem 1rem; border-radius: 8px;
  background: var(--accent); color: var(--bg);
  font-size: 0.8rem; font-weight: 500; text-decoration: none;
  transition: opacity 0.2s;
}
.ea-download:hover { opacity: 0.85; }

/* CTA */
.cta { padding: 5rem 0; position: relative; }
.cta-glow {
  position: absolute; top: 50%; left: 50%; transform: translate(-50%, -50%);
  width: 40vw; height: 30vw; border-radius: 50%;
  background: rgba(50, 31, 82, 0.12); filter: blur(80px);
  pointer-events: none;
}
.cta h2 {
  font-family: var(--serif); font-size: clamp(1.75rem, 4vw, 2.25rem);
  font-weight: 400; letter-spacing: -0.02em; margin-bottom: 0.75rem;
  position: relative;
}
.cta h2 em { font-style: italic; color: var(--accent); }
.cta p {
  color: var(--text-2); font-size: 0.9rem; font-weight: 300;
  margin-bottom: 2rem; max-width: 440px; line-height: 1.65;
  position: relative;
}
.cta-form { position: relative; max-width: 440px; }
.cta-input-row {
  display: flex; gap: 0.5rem;
}
.cta-input-row input[type="email"] {
  flex: 1; padding: 0.7rem 1.1rem; border-radius: 10px;
  border: 1px solid var(--border); background: var(--surface-glass);
  backdrop-filter: blur(12px); -webkit-backdrop-filter: blur(12px);
  color: var(--text); font-family: var(--sans); font-size: 0.85rem;
  outline: none; transition: border-color 0.2s;
}
.cta-input-row input[type="email"]::placeholder { color: var(--text-3); }
.cta-input-row input[type="email"]:focus { border-color: var(--accent); }
.cta-submit {
  display: inline-flex; align-items: center; gap: 0.4rem;
  padding: 0.7rem 1.25rem; border-radius: 10px; border: 1px solid var(--accent);
  background: var(--accent); color: var(--bg);
  font-family: var(--sans); font-size: 0.85rem; font-weight: 500;
  cursor: pointer; transition: opacity 0.2s; white-space: nowrap;
}
.cta-submit:hover { opacity: 0.85; }
.cta-submit svg { width: 14px; height: 14px; flex-shrink: 0; }
.cta-submit:disabled { opacity: 0.5; cursor: not-allowed; }
.honeypot { position: absolute; left: -9999px; opacity: 0; height: 0; width: 0; }
.cta-feedback {
  margin-top: 0.75rem; font-size: 0.8rem; font-weight: 300;
  color: var(--text-2); min-height: 1.2em;
}
.cta-feedback.success { color: var(--accent); }
.cta-feedback.error { color: #e57373; }

/* Hidden message */
.hidden-message {
  color: transparent; font-size: 0.7rem; user-select: all;
  display: block; margin-top: 0.5rem;
}
.hidden-message::selection {
  color: var(--accent); background: rgba(196, 181, 253, 0.2);
}

/* Buttons */
.btn {
  display: inline-flex; align-items: center; gap: 0.5rem;
  padding: 0.625rem 1.25rem; border-radius: 8px; text-decoration: none;
  font-size: 0.85rem; font-weight: 500;
  transition: border-color 0.2s ease, background-color 0.2s ease, opacity 0.2s ease;
}
.btn svg { width: 16px; height: 16px; flex-shrink: 0; opacity: 0.7; }
.btn-primary {
  background: var(--text); color: var(--bg);
}
.btn-primary:hover { opacity: 0.85; }
.btn-secondary {
  color: var(--text); border: 1px solid var(--border);
}
.btn-secondary:hover {
  border-color: rgba(255, 255, 255, 0.15);
  background-color: rgba(255, 255, 255, 0.06);
}

/* Footer */
footer {
  padding: 3rem 0; border-top: 1px solid var(--border);
  display: flex; flex-direction: column; gap: 1.5rem;
}
.footer-top { font-size: 0.8rem; color: var(--text-3); font-weight: 300; }
.footer-bottom {
  display: flex; justify-content: space-between; align-items: center;
  flex-wrap: wrap; gap: 1rem;
}
.footer-copy { font-size: 0.75rem; color: var(--text-3); }
footer a, footer .li-link {
  font-size: 0.75rem; color: var(--text-3); text-decoration: none;
  transition: color 0.2s; cursor: pointer;
}
footer a:hover, footer .li-link:hover { color: var(--text-2); }
.footer-links { display: flex; gap: 1.5rem; }

/* Legal modal */
.legal-overlay {
  display: none; position: fixed; inset: 0; z-index: 300;
  background: rgba(0, 0, 0, 0.6); backdrop-filter: blur(6px);
  -webkit-backdrop-filter: blur(6px);
  align-items: center; justify-content: center; padding: 1.5rem;
}
.legal-overlay.visible { display: flex; }
.legal-modal {
  background: var(--surface); border: 1px solid var(--border);
  border-radius: 16px; padding: 2rem; max-width: 520px; width: 100%;
  max-height: 80vh; overflow-y: auto; position: relative;
}
.legal-close {
  position: absolute; top: 1rem; right: 1rem;
  background: none; border: none; color: var(--text-3);
  font-size: 1.25rem; cursor: pointer; padding: 0.25rem 0.5rem;
  transition: color 0.2s;
}
.legal-close:hover { color: var(--text); }
.legal-modal h3 {
  font-size: 0.9rem; font-weight: 500; margin-bottom: 1rem;
}
.legal-modal p {
  font-size: 0.8rem; color: var(--text-2); font-weight: 300;
  line-height: 1.65; margin-bottom: 0.75rem;
}
.legal-modal a { color: var(--accent); text-decoration: none; }
.legal-modal a:hover { opacity: 0.7; }

/* Editor mode */
.edit-bar {
  display: none; position: fixed; bottom: 1.5rem; left: 50%; transform: translateX(-50%);
  z-index: 200; background: rgba(26, 26, 30, 0.95); border: 1px solid rgba(255,255,255,0.12);
  backdrop-filter: blur(16px); -webkit-backdrop-filter: blur(16px);
  border-radius: 12px; padding: 0.6rem 0.75rem; gap: 0.5rem;
  align-items: center; font-size: 0.7rem; color: var(--text-2);
  box-shadow: 0 8px 32px rgba(0,0,0,0.4);
}
.edit-bar.visible { display: flex; }
.edit-bar-label {
  font-size: 0.6rem; text-transform: uppercase; letter-spacing: 0.08em;
  color: var(--text-3); margin-right: 0.25rem;
}
.edit-bar button {
  padding: 0.35rem 0.7rem; border-radius: 6px; border: 1px solid var(--border);
  background: transparent; color: var(--text-2); font-size: 0.65rem;
  cursor: pointer; font-family: var(--sans); transition: background-color 0.2s;
}
.edit-bar button:hover { background: rgba(255,255,255,0.08); }
.edit-bar button.active { background: var(--accent); color: var(--bg); border-color: var(--accent); }
.edit-bar .edit-export {
  background: rgba(196, 181, 253, 0.15); border-color: rgba(196, 181, 253, 0.3);
  color: var(--accent);
}
.edit-bar .edit-close {
  margin-left: 0.25rem; background: none; border: none; color: var(--text-3);
  font-size: 0.85rem; padding: 0.2rem 0.4rem;
}

body.editing a,
body.editing button:not(.edit-bar button):not(.style-opt) {
  pointer-events: none;
}
body.editing [data-key],
body.editing [data-edit] {
  pointer-events: auto;
  outline: 1px dashed rgba(196, 181, 253, 0.25);
  outline-offset: 4px;
  cursor: text;
  border-radius: 4px;
  transition: outline-color 0.2s;
}
body.editing [data-key]:hover,
body.editing [data-edit]:hover {
  outline-color: rgba(196, 181, 253, 0.5);
}
body.editing [data-key]:focus,
body.editing [data-edit]:focus {
  outline-color: var(--accent);
  outline-style: solid;
}

/* Mobile */
@media (max-width: 560px) {
  nav { transform: translateY(-100%); transition: transform 0.3s; }
  nav.scrolled { transform: translateY(0); }
  .hero { min-height: 100svh; padding: 3rem 0 3rem; gap: 3.5rem; justify-content: flex-start; padding-top: 12svh; }
  .hero h1 { margin-bottom: 1.5rem; }
  .hero-sub { margin-bottom: 0; }
  .compat-logos { display: flex; padding-bottom: 0.5rem; }
  .desktop-only { display: none; }
  .mobile-only { display: inline; }
  .demo-box { padding: 1.25rem 1.5rem 1.25rem; }
  .features-grid { grid-template-columns: 1fr; gap: 1rem; }
  .pricing-grid { grid-template-columns: 1fr; border-radius: 12px; }
  .plan { padding: 1.25rem 1.5rem; }
  .plan-price { font-size: 1.4rem; }
  .plan-desc { margin-bottom: 1rem; }
  .plan-cta { padding: 0.45rem 0.85rem; }
  .cta-input-row { flex-direction: column; gap: 1rem; }
  .cta-submit { justify-content: center; }
  .btn { justify-content: center; }
  .nav-links a:first-child { display: none; }
}
