/* ============ AutoFlowAI — dark animated theme ============ */
:root {
  --bg: #06070f;
  --bg-soft: #0b0d1a;
  --panel: rgba(255, 255, 255, 0.04);
  --panel-brd: rgba(255, 255, 255, 0.09);
  --ink: #eef1ff;
  --ink-soft: #aab3d4;
  --muted: #6b739a;
  --brand: #6366f1;
  --brand-2: #a855f7;
  --accent: #22d3ee;
  --wa: #25d366;
  --radius: 18px;
  --container: 1140px;
  --glow: 0 0 0 1px var(--panel-brd), 0 18px 50px -20px rgba(99, 102, 241, 0.5);
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0; background: var(--bg); color: var(--ink); overflow-x: hidden;
  font-family: "Inter", system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  line-height: 1.65; -webkit-font-smoothing: antialiased;
}
h1, h2, h3 { font-family: "Sora", "Inter", sans-serif; line-height: 1.1; margin: 0 0 .5em; letter-spacing: -0.02em; }
h1 { font-size: clamp(2.6rem, 7vw, 4.6rem); font-weight: 800; }
h2 { font-size: clamp(1.9rem, 3.8vw, 2.7rem); font-weight: 700; }
h3 { font-size: 1.25rem; font-weight: 700; }
p { margin: 0 0 1rem; color: var(--ink-soft); }
a { color: inherit; text-decoration: none; }
.muted { color: var(--muted); font-weight: 400; }
.container { width: 100%; max-width: var(--container); margin: 0 auto; padding: 0 22px; position: relative; z-index: 2; }

.grad-text {
  background: linear-gradient(100deg, #818cf8, var(--brand-2) 45%, var(--accent));
  -webkit-background-clip: text; background-clip: text; color: transparent;
}
.eyebrow {
  display: inline-flex; align-items: center; gap: .5rem; text-transform: uppercase;
  letter-spacing: .16em; font-size: .76rem; font-weight: 700; color: var(--ink-soft); margin: 0 0 1rem;
}
.eyebrow .dot { width: 8px; height: 8px; border-radius: 50%; background: var(--accent); box-shadow: 0 0 12px 2px var(--accent); animation: pulse 1.8s ease-in-out infinite; }
@keyframes pulse { 0%,100%{ transform: scale(1); opacity:1 } 50%{ transform: scale(1.5); opacity:.5 } }

/* ---------- Animated background ---------- */
.net { position: fixed; inset: 0; width: 100%; height: 100%; z-index: 0; pointer-events: none; }
.aurora { position: fixed; inset: 0; z-index: 0; overflow: hidden; pointer-events: none; filter: blur(80px); opacity: .55; }
.blob { position: absolute; border-radius: 50%; mix-blend-mode: screen; }
.blob--1 { width: 46vw; height: 46vw; left: -8vw; top: -10vw; background: radial-gradient(circle, var(--brand), transparent 65%); animation: drift1 22s ease-in-out infinite; }
.blob--2 { width: 40vw; height: 40vw; right: -10vw; top: 8vw; background: radial-gradient(circle, var(--brand-2), transparent 65%); animation: drift2 26s ease-in-out infinite; }
.blob--3 { width: 38vw; height: 38vw; left: 30vw; top: 60vh; background: radial-gradient(circle, var(--accent), transparent 65%); animation: drift3 30s ease-in-out infinite; opacity: .7; }
@keyframes drift1 { 0%,100%{ transform: translate(0,0) } 50%{ transform: translate(8vw,6vw) } }
@keyframes drift2 { 0%,100%{ transform: translate(0,0) } 50%{ transform: translate(-7vw,5vw) } }
@keyframes drift3 { 0%,100%{ transform: translate(0,0) scale(1) } 50%{ transform: translate(4vw,-6vw) scale(1.1) } }

/* ---------- Buttons ---------- */
.btn {
  position: relative; display: inline-flex; align-items: center; justify-content: center; gap: .55rem;
  background: linear-gradient(100deg, var(--brand), var(--brand-2)); color: #fff; font-weight: 600;
  font-size: .98rem; padding: .75rem 1.35rem; border-radius: 999px; border: 0; cursor: pointer;
  box-shadow: 0 10px 30px -10px rgba(124, 92, 246, .7); transition: transform .18s ease, box-shadow .18s ease;
  overflow: hidden;
}
.btn::after { content:""; position:absolute; inset:0; background: linear-gradient(100deg, var(--brand-2), var(--accent)); opacity:0; transition:opacity .25s ease; z-index:0; }
.btn > * { position: relative; z-index: 1; }
.btn:hover { transform: translateY(-3px); box-shadow: 0 18px 44px -12px rgba(124, 92, 246, .85); }
.btn:hover::after { opacity: 1; }
.btn--lg { padding: .95rem 1.7rem; font-size: 1.04rem; }
.btn--sm { padding: .5rem 1.05rem; font-size: .9rem; }
.btn--ghost { background: var(--panel); color: var(--ink); box-shadow: inset 0 0 0 1px var(--panel-brd); }
.btn--ghost::after { display: none; }
.btn--ghost:hover { box-shadow: inset 0 0 0 1px var(--accent); background: rgba(255,255,255,.06); }
.btn--whatsapp { background: var(--wa); box-shadow: 0 12px 30px -10px rgba(37,211,102,.6); margin-top: .4rem; }
.btn--whatsapp::after { display: none; }

/* ---------- Nav ---------- */
.nav { position: sticky; top: 0; z-index: 50; transition: background .3s ease, box-shadow .3s ease, backdrop-filter .3s; }
.nav.scrolled { background: rgba(8, 9, 18, .72); backdrop-filter: saturate(160%) blur(14px); box-shadow: 0 1px 0 0 var(--panel-brd); }
.nav__inner { display: flex; align-items: center; justify-content: space-between; height: 72px; }
.brand { display: inline-flex; align-items: center; gap: .6rem; font-family: "Sora", sans-serif; font-weight: 800; font-size: 1.22rem; }
.brand__ai { color: var(--accent); }
.nav__links { display: flex; align-items: center; gap: 1.7rem; font-weight: 500; }
.nav__links a:not(.btn) { color: var(--ink-soft); transition: color .15s; }
.nav__links a:not(.btn):hover { color: var(--ink); }
.nav__toggle { display: none; flex-direction: column; gap: 5px; background: none; border: 0; cursor: pointer; padding: 8px; }
.nav__toggle span { width: 24px; height: 2px; background: var(--ink); border-radius: 2px; transition: .25s; }

/* ---------- Hero ---------- */
.hero { position: relative; padding: clamp(4rem, 11vw, 8.5rem) 0 clamp(3rem, 7vw, 6rem); min-height: 86vh; display: flex; align-items: center; }
.hero__inner { max-width: 860px; }
.hero__title { margin: .3rem 0 1.1rem; }
.typed-wrap { display: inline-flex; align-items: baseline; }
.caret { display: inline-block; width: 3px; height: 1em; margin-left: 4px; background: var(--accent); box-shadow: 0 0 10px var(--accent); transform: translateY(2px); animation: blink 1s steps(2) infinite; }
@keyframes blink { 0%,50%{opacity:1} 51%,100%{opacity:0} }
.hero__sub { font-size: clamp(1.05rem, 2vw, 1.28rem); max-width: 640px; }
.hero__cta { display: flex; flex-wrap: wrap; gap: .85rem; margin: 1.7rem 0 1.5rem; }
.hero__trust { display: flex; flex-wrap: wrap; gap: 1.3rem; color: var(--ink-soft); font-size: .92rem; font-weight: 500; }
.scroll-hint { position: absolute; bottom: 1.5rem; left: 50%; transform: translateX(-50%); width: 26px; height: 42px; border: 2px solid var(--panel-brd); border-radius: 20px; }
.scroll-hint span { position: absolute; top: 8px; left: 50%; transform: translateX(-50%); width: 4px; height: 8px; border-radius: 4px; background: var(--accent); animation: scrolly 1.6s ease-in-out infinite; }
@keyframes scrolly { 0%{opacity:0; top:8px} 40%{opacity:1} 80%{opacity:0; top:22px} 100%{opacity:0} }

/* ---------- Marquee ---------- */
.marquee { overflow: hidden; border-top: 1px solid var(--panel-brd); border-bottom: 1px solid var(--panel-brd); padding: 1rem 0; background: rgba(255,255,255,.015); position: relative; z-index: 2; }
.marquee__track { display: inline-flex; align-items: center; gap: 1.4rem; white-space: nowrap; animation: scrollx 28s linear infinite; font-family: "Sora", sans-serif; font-weight: 600; color: var(--ink-soft); font-size: 1.05rem; }
.marquee__track i { color: var(--accent); font-style: normal; }
.marquee__track span:hover { color: var(--ink); }
@keyframes scrollx { from{ transform: translateX(0) } to{ transform: translateX(-50%) } }

/* ---------- Sections ---------- */
.section { padding: clamp(3.5rem, 8vw, 6.5rem) 0; position: relative; z-index: 2; }
.section__head { max-width: 660px; margin-bottom: 2.6rem; }
.section__lead { font-size: 1.1rem; }

/* ---------- Cards ---------- */
.cards { display: grid; grid-template-columns: repeat(3, 1fr); gap: 1.4rem; }
.card {
  position: relative; background: var(--panel); border: 1px solid var(--panel-brd); border-radius: var(--radius);
  padding: 2rem 1.7rem; backdrop-filter: blur(8px); transition: transform .25s ease, border-color .25s ease;
  overflow: hidden;
}
.card__glow { position: absolute; width: 260px; height: 260px; border-radius: 50%; background: radial-gradient(circle, rgba(168,85,247,.28), transparent 70%); opacity: 0; transition: opacity .3s ease; pointer-events: none; transform: translate(-50%, -50%); }
.card:hover { border-color: rgba(168,85,247,.45); }
.card:hover .card__glow { opacity: 1; }
.card__icon { width: 56px; height: 56px; display: grid; place-items: center; font-size: 1.6rem; border-radius: 15px; margin-bottom: 1.1rem; background: linear-gradient(135deg, rgba(99,102,241,.22), rgba(168,85,247,.22)); border: 1px solid var(--panel-brd); }
.card h3, .card p { position: relative; z-index: 1; }
.card p { margin-bottom: 0; }

/* ---------- Steps ---------- */
.steps { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(3, 1fr); gap: 1.4rem; }
.step { background: var(--panel); border: 1px solid var(--panel-brd); border-radius: var(--radius); padding: 2rem 1.7rem; backdrop-filter: blur(8px); }
.step__num { display: grid; place-items: center; width: 44px; height: 44px; border-radius: 13px; font-family: "Sora",sans-serif; font-weight: 800; color: #fff; background: linear-gradient(135deg, var(--brand), var(--brand-2)); margin-bottom: 1rem; box-shadow: 0 8px 22px -8px rgba(124,92,246,.7); }
.step p { margin-bottom: 0; }

/* ---------- About ---------- */
.about__grid { display: grid; grid-template-columns: 1.15fr .85fr; gap: 2.8rem; align-items: start; }
.why { list-style: none; margin: 0; padding: 0; display: grid; gap: .9rem; }
.why li { background: var(--panel); border: 1px solid var(--panel-brd); border-radius: 13px; padding: 1.05rem 1.15rem; color: var(--ink-soft); }
.why strong { color: var(--ink); }

/* ---------- Contact ---------- */
.contact__grid { display: grid; grid-template-columns: 1fr 1fr; gap: 2.8rem; align-items: start; }
.form { background: var(--panel); border: 1px solid var(--panel-brd); border-radius: var(--radius); padding: 1.9rem; backdrop-filter: blur(10px); box-shadow: var(--glow); }
.form__row { display: flex; flex-direction: column; gap: .4rem; margin-bottom: 1rem; }
.form label { font-weight: 600; font-size: .92rem; color: var(--ink); }
.form input, .form textarea {
  font: inherit; color: var(--ink); padding: .72rem .9rem; border: 1px solid var(--panel-brd); border-radius: 11px;
  background: rgba(255,255,255,.03); transition: border-color .15s ease, box-shadow .15s ease; resize: vertical;
}
.form input::placeholder, .form textarea::placeholder { color: var(--muted); }
.form input:focus, .form textarea:focus { outline: none; border-color: var(--brand-2); box-shadow: 0 0 0 3px rgba(168,85,247,.22); }
.form__submit { width: 100%; margin-top: .4rem; }
.form__status { margin: .9rem 0 0; font-weight: 600; min-height: 1.2em; }
.form__status.ok { color: #34d399; }
.form__status.err { color: #f87171; }

/* ---------- Footer ---------- */
.footer { border-top: 1px solid var(--panel-brd); padding: 2.8rem 0; position: relative; z-index: 2; }
.footer__inner { display: flex; flex-direction: column; align-items: center; gap: .5rem; text-align: center; }
.footer__tag { margin: .3rem 0 0; color: var(--ink-soft); }
.footer__mail { color: var(--accent); font-weight: 600; }
.footer__copy { margin: .4rem 0 0; color: var(--muted); font-size: .88rem; }

/* ---------- Reveal ---------- */
.reveal { opacity: 0; transform: translateY(26px); transition: opacity .7s cubic-bezier(.2,.7,.2,1), transform .7s cubic-bezier(.2,.7,.2,1); }
.reveal.in { opacity: 1; transform: none; }

@media (prefers-reduced-motion: reduce) {
  .reveal { opacity: 1; transform: none; transition: none; }
  .blob, .marquee__track, .caret, .scroll-hint span, .eyebrow .dot { animation: none !important; }
  html { scroll-behavior: auto; }
}

/* ---------- Responsive ---------- */
@media (max-width: 880px) {
  .cards, .steps { grid-template-columns: 1fr; }
  .about__grid, .contact__grid { grid-template-columns: 1fr; }
  .nav__links {
    position: fixed; inset: 72px 0 auto 0; flex-direction: column; align-items: stretch; gap: 0;
    background: rgba(8,9,18,.96); backdrop-filter: blur(14px); border-bottom: 1px solid var(--panel-brd);
    padding: .5rem 22px 1.2rem; transform: translateY(-12px); opacity: 0; pointer-events: none; transition: .22s ease;
  }
  .nav__links a { padding: .9rem 0; border-bottom: 1px solid var(--panel-brd); color: var(--ink); }
  .nav__links a.btn { margin-top: .8rem; border-bottom: 0; }
  .nav__links.open { transform: none; opacity: 1; pointer-events: auto; }
  .nav__toggle { display: flex; }
  .nav__toggle.open span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
  .nav__toggle.open span:nth-child(2) { opacity: 0; }
  .nav__toggle.open span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }
}
