:root {
  --bg: #0f1115;
  --surface: #1a1d24;
  --surface-2: #23262f;
  --border: #2e323c;
  --text: #e7e9ee;
  --text-dim: #9aa0ab;
  --accent: #6366f1;
  --accent-2: #818cf8;
  --green: #22c55e;
  --orange: #f59e0b;
  --red: #ef4444;
  --radius: 12px;
  --maxw: 1100px;
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

.container { max-width: var(--maxw); margin: 0 auto; padding: 0 20px; }

/* Nav */
.site-nav {
  display: flex; align-items: center; justify-content: space-between;
  padding: 16px 0; border-bottom: 1px solid var(--border);
}
.brand { font-size: 1.25rem; font-weight: 800; color: var(--text); text-decoration: none; letter-spacing: -0.02em; }
.brand span { color: var(--accent-2); }
.nav-links { display: flex; gap: 20px; }
.nav-links a { color: var(--text-dim); text-decoration: none; font-size: 0.92rem; }
.nav-links a:hover { color: var(--text); }

/* Hero */
.hero { text-align: center; padding: 64px 0 40px; }
.hero h1 { font-size: 2.6rem; font-weight: 800; letter-spacing: -0.03em; margin: 0 0 16px; line-height: 1.15; }
.hero h1 .grad { background: linear-gradient(90deg, var(--accent-2), #a855f7); -webkit-background-clip: text; background-clip: text; color: transparent; }
.hero .sub { font-size: 1.15rem; color: var(--text-dim); max-width: 640px; margin: 0 auto 28px; }

.btn {
  display: inline-block; padding: 14px 30px; border-radius: 999px;
  font-size: 1.02rem; font-weight: 700; text-decoration: none; cursor: pointer;
  border: none; transition: transform .12s, background .12s;
}
.btn-primary { background: var(--accent); color: #fff; }
.btn-primary:hover { background: var(--accent-2); transform: translateY(-1px); }
.btn-secondary { background: var(--surface-2); color: var(--text); border: 1px solid var(--border); }
.btn-secondary:hover { border-color: var(--accent); }

/* Sections */
.section { padding: 48px 0; }
.section h2 { font-size: 1.9rem; font-weight: 800; letter-spacing: -0.02em; margin: 0 0 12px; }
.section .lead { color: var(--text-dim); max-width: 680px; margin: 0 0 32px; font-size: 1.05rem; }

.cards { display: grid; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); gap: 16px; }
.card { background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); padding: 24px; }
.card h3 { margin: 0 0 8px; font-size: 1.1rem; }
.card p { color: var(--text-dim); margin: 0; font-size: 0.95rem; }

.steps { display: grid; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); gap: 16px; }
.step { background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); padding: 24px; }
.step .num { display: inline-block; width: 32px; height: 32px; border-radius: 50%; background: var(--accent); color: #fff; font-weight: 800; text-align: center; line-height: 32px; margin-bottom: 12px; }
.step h3 { margin: 0 0 8px; font-size: 1.05rem; }
.step p { color: var(--text-dim); margin: 0; font-size: 0.92rem; }

/* FAQ */
.faq { max-width: 760px; }
.faq details { background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); padding: 18px 22px; margin-bottom: 10px; }
.faq summary { cursor: pointer; font-weight: 700; font-size: 1rem; }
.faq details p { color: var(--text-dim); margin: 10px 0 0; font-size: 0.95rem; }

/* Pricing */
.pricing { display: grid; grid-template-columns: repeat(auto-fit, minmax(260px, 1fr)); gap: 16px; max-width: 760px; margin: 0 auto; }
.plan { background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); padding: 28px; text-align: center; }
.plan.featured { border-color: var(--accent); box-shadow: 0 0 0 1px var(--accent); }
.plan .price { font-size: 2rem; font-weight: 800; margin: 12px 0; }
.plan .price small { font-size: 0.9rem; color: var(--text-dim); font-weight: 400; }
.plan ul { list-style: none; padding: 0; margin: 0 0 20px; text-align: left; }
.plan ul li { padding: 6px 0; color: var(--text-dim); font-size: 0.92rem; border-bottom: 1px solid var(--border); }
.plan ul li:last-child { border-bottom: none; }
.plan ul li::before { content: "✓ "; color: var(--green); }

footer { border-top: 1px solid var(--border); padding: 28px 0; margin-top: 40px; color: var(--text-dim); font-size: 0.88rem; text-align: center; }
footer a { color: var(--text-dim); }

/* Tool page */
.tool-stage { display: grid; grid-template-columns: 1fr; gap: 20px; margin: 24px 0; }
@media (min-width: 860px) { .tool-stage { grid-template-columns: 1.4fr 1fr; } }

.preview-wrap {
  position: relative; background: #000; border: 1px solid var(--border);
  border-radius: var(--radius); min-height: 300px; overflow: hidden;
  display: flex; align-items: center; justify-content: center;
}
#video-preview { max-width: 100%; max-height: 460px; display: none; }
#drop-hint { color: var(--text-dim); text-align: center; padding: 40px; }
.selection-box {
  position: absolute; border: 2px dashed var(--red); background: rgba(239,68,68,0.12);
  cursor: move; display: none; border-radius: 2px;
}
.selection-box .handle { position: absolute; right: -6px; bottom: -6px; width: 14px; height: 14px; background: var(--red); border-radius: 3px; cursor: nwse-resize; }

.side-panel { background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); padding: 22px; }
.side-panel h3 { margin: 0 0 12px; font-size: 1.05rem; }
.side-panel p { color: var(--text-dim); font-size: 0.9rem; }
.field { margin-bottom: 14px; }
.field label { display: block; font-size: 0.85rem; color: var(--text-dim); margin-bottom: 6px; }
.field input { width: 100%; padding: 10px 12px; background: var(--surface-2); border: 1px solid var(--border); border-radius: 8px; color: var(--text); font-size: 0.95rem; }

#status { margin-top: 14px; font-size: 0.9rem; color: var(--text-dim); min-height: 20px; }
#progress-bar { width: 100%; height: 8px; background: var(--surface-2); border-radius: 999px; overflow: hidden; margin-top: 10px; display: none; }
#progress-fill { height: 100%; background: var(--accent); width: 0%; transition: width .2s; }

.hidden { display: none !important; }
