/* =========================================================
   SG Desenvolvimento — estilos
   Tema claro
   ========================================================= */

:root {
  --font-sans: "Plus Jakarta Sans", system-ui, -apple-system, "Segoe UI", sans-serif;
  --font-mono: "JetBrains Mono", ui-monospace, SFMono-Regular, Menlo, monospace;

  --radius-sm: 10px;
  --radius: 16px;
  --radius-lg: 24px;
  --ease: cubic-bezier(.22, 1, .36, 1);
  --header-h: 72px;
  --container: 1200px;
}

:root {
  --bg: #f6f9fb;
  --bg-alt: #eef4f7;
  --surface: #ffffff;
  --surface-2: #f2f7fa;
  --text: #0c1b2a;
  --text-soft: #34485b;
  --muted: #607385;
  --border: #dfe8ee;
  --border-strong: #c8d6df;

  --primary: #0d9488;
  --primary-strong: #0f766e;
  --primary-soft: rgba(13, 148, 136, .1);
  --secondary: #2563eb;
  --accent: #06b6d4;
  --on-primary: #ffffff;

  --grad: linear-gradient(120deg, #0d9488 0%, #0891b2 50%, #2563eb 100%);
  --shadow-sm: 0 1px 2px rgba(12, 27, 42, .05), 0 2px 8px rgba(12, 27, 42, .04);
  --shadow: 0 10px 30px -12px rgba(12, 27, 42, .18), 0 2px 6px rgba(12, 27, 42, .04);
  --shadow-lg: 0 30px 60px -20px rgba(12, 27, 42, .25);
  --grid-line: rgba(12, 27, 42, .055);
  --blob-a: rgba(13, 148, 136, .22);
  --blob-b: rgba(37, 99, 235, .16);
  --blob-c: rgba(6, 182, 212, .18);
  --glass: rgba(255, 255, 255, .72);
  color-scheme: light;
}

/* ---------- Reset / base ---------- */
*,
*::before,
*::after { box-sizing: border-box; }

html { scroll-behavior: smooth; scroll-padding-top: calc(var(--header-h) + 16px); -webkit-text-size-adjust: 100%; }

body {
  margin: 0;
  font-family: var(--font-sans);
  font-size: 17px;
  line-height: 1.6;
  color: var(--text);
  background: var(--bg);
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
  transition: background-color .4s var(--ease), color .4s var(--ease);
}

img, svg { display: block; max-width: 100%; }
a { color: inherit; text-decoration: none; }
button { font: inherit; color: inherit; cursor: pointer; }
h1, h2, h3 { margin: 0; line-height: 1.15; letter-spacing: -.02em; font-weight: 800; }
p { margin: 0; }
ul, ol { margin: 0; padding: 0; list-style: none; }
::selection { background: var(--primary); color: var(--on-primary); }

:focus-visible { outline: 2px solid var(--primary); outline-offset: 3px; border-radius: 6px; }

.container { width: 100%; max-width: var(--container); margin: 0 auto; padding: 0 24px; }
.container--narrow { max-width: 820px; }

.gradient-text {
  background: var(--grad);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  background-size: 200% auto;
  animation: gradient-shift 8s ease-in-out infinite;
}
@keyframes gradient-shift { 50% { background-position: 100% 50%; } }

/* ---------- Scroll progress ---------- */
.scroll-progress {
  position: fixed; inset: 0 0 auto 0; height: 3px; z-index: 100;
  background: var(--grad);
  transform-origin: 0 50%;
  transform: scaleX(var(--progress, 0));
}

/* ---------- Buttons ---------- */
.btn {
  --pad-y: 12px; --pad-x: 20px;
  position: relative;
  display: inline-flex; align-items: center; justify-content: center; gap: 10px;
  padding: var(--pad-y) var(--pad-x);
  border-radius: 999px;
  border: 1px solid transparent;
  font-weight: 600; font-size: 15px; line-height: 1;
  white-space: nowrap;
  transition: transform .35s var(--ease), box-shadow .35s var(--ease), background-color .25s, border-color .25s, color .25s;
  will-change: transform;
}
.btn svg { width: 18px; height: 18px; fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; transition: transform .35s var(--ease); }
.btn:hover svg { transform: translateX(4px); }
.btn--sm { --pad-y: 10px; --pad-x: 16px; font-size: 14px; }
.btn--lg { --pad-y: 16px; --pad-x: 26px; font-size: 16px; }
.btn--block { width: 100%; }

.btn--primary {
  color: var(--on-primary);
  background: var(--primary);
  box-shadow: 0 8px 24px -8px var(--primary);
  overflow: hidden;
}
.btn--primary::before {
  content: ""; position: absolute; inset: 0;
  background: var(--grad);
  opacity: 0; transition: opacity .35s var(--ease);
}
.btn--primary::after {
  content: ""; position: absolute; top: 0; left: -60%; width: 40%; height: 100%;
  background: linear-gradient(90deg, transparent, rgba(255,255,255,.45), transparent);
  transform: skewX(-20deg);
  transition: left .7s var(--ease);
}
.btn--primary:hover::before { opacity: 1; }
.btn--primary:hover::after { left: 130%; }
.btn--primary:hover { box-shadow: 0 14px 34px -10px var(--primary); }
.btn--primary { z-index: 0; isolation: isolate; }
.btn--primary::before, .btn--primary::after { z-index: -1; }

.btn--ghost {
  color: var(--text);
  background: var(--surface);
  border-color: var(--border-strong);
}
.btn--ghost:hover { border-color: var(--primary); color: var(--primary); }

/* ---------- Header ---------- */
.header {
  position: fixed; inset: 0 0 auto 0; z-index: 50;
  height: var(--header-h);
  transition: height .35s var(--ease), background-color .35s, border-color .35s, box-shadow .35s;
  border-bottom: 1px solid transparent;
}
.header.is-scrolled {
  --header-h: 62px;
  background: var(--glass);
  backdrop-filter: saturate(1.6) blur(14px);
  -webkit-backdrop-filter: saturate(1.6) blur(14px);
  border-bottom-color: var(--border);
}
.header__inner { height: 100%; display: flex; align-items: center; justify-content: space-between; gap: 24px; }

.logo { display: inline-flex; align-items: center; }
.logo__img { display: block; height: 40px; width: auto; transition: transform .4s var(--ease); }
.logo:hover .logo__img { transform: scale(1.03); }
.footer .logo__img { height: 34px; }
@media (max-width: 640px) { .logo__img { height: 34px; } }

.nav { display: flex; gap: 4px; }
.nav a {
  position: relative; white-space: nowrap;
  padding: 8px 14px; border-radius: 999px;
  font-size: 15px; font-weight: 500; color: var(--text-soft);
  transition: color .25s, background-color .25s;
}
.nav a:hover { color: var(--text); background: var(--primary-soft); }
.nav a.is-active { color: var(--primary); }
.nav a.is-active::after {
  content: ""; position: absolute; left: 50%; bottom: 2px; width: 4px; height: 4px; border-radius: 50%;
  background: var(--primary); transform: translateX(-50%);
}

.header__actions { display: flex; align-items: center; gap: 10px; }

.menu-toggle {
  display: none; width: 42px; height: 42px; border-radius: 50%;
  border: 1px solid var(--border-strong); background: var(--surface);
  position: relative;
}
.menu-toggle span {
  position: absolute; left: 12px; right: 12px; height: 2px; border-radius: 2px; background: var(--text);
  transition: transform .4s var(--ease), top .4s var(--ease);
}
.menu-toggle span:first-child { top: 16px; }
.menu-toggle span:last-child { top: 23px; }
.menu-toggle[aria-expanded="true"] span:first-child { top: 19.5px; transform: rotate(45deg); }
.menu-toggle[aria-expanded="true"] span:last-child { top: 19.5px; transform: rotate(-45deg); }

/* ---------- Hero ---------- */
.hero {
  position: relative;
  min-height: 100vh; min-height: 100svh;
  padding: calc(var(--header-h) + 48px) 0 96px;
  display: flex; align-items: center;
  overflow: hidden;
  isolation: isolate;
}
.hero__bg { position: absolute; inset: 0; z-index: -1; pointer-events: none; }
.hero__grid {
  position: absolute; inset: -2px;
  background-image:
    linear-gradient(var(--grid-line) 1px, transparent 1px),
    linear-gradient(90deg, var(--grid-line) 1px, transparent 1px);
  background-size: 56px 56px;
  mask-image: radial-gradient(ellipse 80% 70% at 60% 40%, #000 30%, transparent 75%);
  -webkit-mask-image: radial-gradient(ellipse 80% 70% at 60% 40%, #000 30%, transparent 75%);
  animation: grid-move 30s linear infinite;
}
@keyframes grid-move { to { background-position: 56px 56px; } }

.blob { position: absolute; border-radius: 50%; filter: blur(70px); will-change: transform; }
.blob--1 { width: 520px; height: 520px; background: var(--blob-a); top: -120px; right: -80px; animation: float-a 18s ease-in-out infinite; }
.blob--2 { width: 420px; height: 420px; background: var(--blob-b); bottom: -140px; left: 10%; animation: float-b 22s ease-in-out infinite; }
.blob--3 { width: 300px; height: 300px; background: var(--blob-c); top: 30%; left: 45%; animation: float-a 26s ease-in-out infinite reverse; }
@keyframes float-a { 0%,100% { transform: translate(0,0) scale(1); } 33% { transform: translate(-60px, 40px) scale(1.08); } 66% { transform: translate(30px, -30px) scale(.95); } }
@keyframes float-b { 0%,100% { transform: translate(0,0) scale(1); } 50% { transform: translate(80px, -50px) scale(1.1); } }

.hero__spotlight {
  position: absolute; inset: 0;
  background: radial-gradient(600px circle at var(--mx, 70%) var(--my, 30%), var(--primary-soft), transparent 60%);
  transition: background .2s;
}

.hero__inner { display: grid; grid-template-columns: 1.1fr .9fr; gap: 56px; align-items: center; }

.eyebrow {
  display: inline-flex; align-items: center; gap: 10px;
  padding: 7px 14px 7px 12px; border-radius: 999px;
  background: var(--surface); border: 1px solid var(--border);
  font-size: 14px; font-weight: 600; color: var(--text-soft);
  box-shadow: var(--shadow-sm);
  margin-bottom: 24px;
}
.pulse-dot { position: relative; width: 8px; height: 8px; border-radius: 50%; background: #22c55e; }
.pulse-dot::after { content: ""; position: absolute; inset: 0; border-radius: 50%; background: #22c55e; animation: ping 1.8s var(--ease) infinite; }
@keyframes ping { 75%, 100% { transform: scale(2.8); opacity: 0; } }

.hero__title { font-size: clamp(2.4rem, 5.4vw, 4.3rem); letter-spacing: -.035em; }
.rotator { display: block; position: relative; color: var(--primary); white-space: nowrap; min-height: 1.15em; }
.rotator__word { display: inline-block; }
.rotator__word.is-out { animation: word-out .45s var(--ease) forwards; }
.rotator__word.is-in { animation: word-in .55s var(--ease) forwards; }
@keyframes word-out { to { transform: translateY(-40%); opacity: 0; filter: blur(6px); } }
@keyframes word-in { from { transform: translateY(40%); opacity: 0; filter: blur(6px); } to { transform: none; opacity: 1; filter: none; } }
@keyframes blink { 50% { opacity: 0; } }

.hero__lead { margin-top: 24px; max-width: 560px; font-size: 1.15rem; color: var(--text-soft); }
.hero__lead strong { color: var(--text); font-weight: 700; }
.hero__ctas { margin-top: 36px; display: flex; flex-wrap: wrap; gap: 12px; }

.hero__chips { margin-top: 36px; display: flex; flex-wrap: wrap; gap: 10px 20px; }
.hero__chips li { display: inline-flex; align-items: center; gap: 8px; font-size: 14px; color: var(--muted); font-weight: 500; }
.hero__chips svg { width: 16px; height: 16px; fill: none; stroke: var(--primary); stroke-width: 2.6; stroke-linecap: round; stroke-linejoin: round; }

.hero__visual { position: relative; justify-self: center; width: 100%; max-width: 500px; }
/* Retrato: o arco fica atrás e a ilustração "salta" por cima dele */
.hero__portrait {
  position: relative; aspect-ratio: 1122 / 1402;
  transform: translate3d(var(--px, 0), var(--py, 0), 0);
  transition: transform .6s var(--ease);
}
.hero__arch {
  position: absolute; inset: 16% 0 0 0;
  border-radius: 50% 50% var(--radius-lg) var(--radius-lg) / 36% 36% var(--radius-lg) var(--radius-lg);
  background: linear-gradient(180deg, var(--surface-2), var(--surface));
  border: 1px solid var(--border);
  box-shadow: var(--shadow-lg);
  overflow: hidden;
}
.hero__arch::before {
  content: ""; position: absolute; inset: 0;
  background:
    radial-gradient(circle at 50% 18%, var(--primary-soft), transparent 60%),
    linear-gradient(180deg, transparent 55%, var(--primary-soft));
}
.hero__portrait picture { position: absolute; inset: 0; }
.hero__img {
  position: absolute; inset: 0; width: 100%; height: 100%;
  object-fit: contain; object-position: center bottom;
  /* corta só a base, acompanhando os cantos do arco; topo livre para a cabeça sair */
  clip-path: inset(-40% 0 0 0 round 0 0 var(--radius-lg) var(--radius-lg));
  /* máscara = formato do arco + elipse da cabeça: os ombros seguem a curva do arco */
  --arch-mask:
    radial-gradient(ellipse 50% 30.24% at 50% 46.24%, #000 99%, transparent 100%),
    radial-gradient(ellipse 22% 21% at 52% 22%, #000 97%, transparent 100%),
    linear-gradient(#000, #000) 0 100% / 100% 53.8% no-repeat;
  -webkit-mask: var(--arch-mask);
  mask: var(--arch-mask);
  filter: drop-shadow(0 18px 28px rgba(12, 27, 42, .18));
}
.hero__ring {
  position: absolute; inset: 6% 6% auto; aspect-ratio: 1; border-radius: 50%;
  border: 1.5px dashed var(--border-strong);
  animation: spin 40s linear infinite;
}
@keyframes spin { to { transform: rotate(360deg); } }

.float-card {
  position: absolute; z-index: 2;
  display: flex; align-items: center; gap: 12px;
  padding: 12px 16px; border-radius: var(--radius);
  background: var(--glass);
  backdrop-filter: blur(14px); -webkit-backdrop-filter: blur(14px);
  border: 1px solid var(--border);
  box-shadow: var(--shadow);
  font-size: 14px;
  animation: bob 6s ease-in-out infinite;
}
.float-card strong { display: block; font-size: 14px; }
.float-card small { display: block; color: var(--muted); font-size: 12.5px; }
.float-card__icon { width: 38px; height: 38px; border-radius: 12px; display: grid; place-items: center; background: var(--primary-soft); }
.float-card__icon svg { width: 20px; height: 20px; fill: none; stroke: var(--primary); stroke-width: 1.8; stroke-linecap: round; animation: spin 12s linear infinite; }
.float-card--ai { top: 22%; left: -16%; }
.float-card--ecg { top: 14%; right: -14%; flex-direction: column; align-items: stretch; gap: 6px; width: 210px; animation-delay: -2s; }
.float-card--code { bottom: -4%; right: -6%; flex-direction: column; align-items: flex-start; gap: 4px; font-family: var(--font-mono); animation-delay: -4s; }
.float-card--code code { font-size: 13px; min-width: 25ch; white-space: pre; }
.c-p { color: var(--muted); }
.type-caret {
  display: inline-block; width: 7px; height: 14px; margin-left: 2px; vertical-align: -2px;
  background: var(--primary); animation: blink 1s steps(1) infinite;
}
.float-card--code.is-typing .type-caret { animation: none; }
.float-card--code .c-ok { transition: opacity .4s var(--ease), transform .4s var(--ease); }
.float-card--code.is-pending .c-ok { opacity: 0; transform: translateY(4px); }
.c-k { color: var(--primary); } .c-s { color: var(--secondary); } .c-ok { color: #22c55e !important; font-family: var(--font-mono); }
.float-card__row { display: flex; align-items: center; gap: 8px; }
.status-dot { width: 7px; height: 7px; border-radius: 50%; background: #22c55e; box-shadow: 0 0 0 3px rgba(34,197,94,.2); }
@keyframes bob { 0%,100% { transform: translateY(0); } 50% { transform: translateY(-10px); } }

.ecg { width: 100%; height: 36px; }
.ecg path, .ecg-line {
  fill: none; stroke: var(--primary); stroke-width: 2; stroke-linecap: round; stroke-linejoin: round;
  stroke-dasharray: 1000; stroke-dashoffset: 1000;
  animation: ecg-draw 3s linear infinite;
}
/* pathLength=1000: o traço é desenhado e depois "apagado" pela cauda, em movimento contínuo */
@keyframes ecg-draw { from { stroke-dashoffset: 1000; } to { stroke-dashoffset: -1000; } }

.scroll-cue {
  position: absolute; left: 50%; bottom: 28px; transform: translateX(-50%);
  width: 26px; height: 42px; border-radius: 14px; border: 2px solid var(--border-strong);
}
.scroll-cue span { position: absolute; left: 50%; top: 8px; width: 4px; height: 8px; margin-left: -2px; border-radius: 2px; background: var(--primary); animation: scroll-cue 1.8s var(--ease) infinite; }
@keyframes scroll-cue { 0% { opacity: 0; transform: translateY(0); } 30% { opacity: 1; } 100% { opacity: 0; transform: translateY(14px); } }

/* ---------- Stack marquee ---------- */
.stack { padding: 48px 0 52px; border-block: 1px solid var(--border); background: var(--surface); display: grid; gap: 16px; overflow: hidden; }
.stack__label { text-align: center; font-size: 15px; color: var(--muted); margin-bottom: 12px; padding: 0 16px; }
.stack__label strong { color: var(--text); font-weight: 700; }
.marquee {
  overflow: hidden; padding: 6px 0;
  mask-image: linear-gradient(90deg, transparent, #000 12%, #000 88%, transparent);
  -webkit-mask-image: linear-gradient(90deg, transparent, #000 12%, #000 88%, transparent);
}
.marquee__track { display: flex; width: max-content; gap: 14px; animation: marquee 55s linear infinite; }
.marquee--reverse .marquee__track { animation-direction: reverse; animation-duration: 48s; }
.marquee:hover .marquee__track { animation-play-state: paused; }

.tech {
  display: inline-flex; align-items: center; gap: 10px;
  height: 52px; padding: 0 20px 0 16px; border-radius: 16px;
  border: 1px solid var(--border); background: var(--bg);
  font-size: 15px; font-weight: 600; color: var(--text-soft);
  white-space: nowrap;
  transition: transform .4s var(--ease), border-color .3s, box-shadow .4s var(--ease), color .3s;
}
.tech__logo {
  width: 24px; height: 24px; flex: none;
  background: var(--brand);
  -webkit-mask-repeat: no-repeat; mask-repeat: no-repeat;
  -webkit-mask-position: center; mask-position: center;
  -webkit-mask-size: contain; mask-size: contain;
  transition: transform .5s var(--ease);
}
.tech--wordmark { padding: 0 22px; }
.tech--wordmark .tech__logo { height: 20px; }
.tech--asaas .tech__logo { width: 92px; height: 16px; }
.tech--pagarme .tech__logo { width: 96px; height: 26px; }
.tech:hover {
  transform: translateY(-3px); color: var(--text);
  border-color: color-mix(in srgb, var(--brand) 55%, transparent);
  box-shadow: 0 10px 24px -12px color-mix(in srgb, var(--brand) 70%, transparent);
}
.tech:hover .tech__logo { transform: scale(1.12) rotate(-6deg); }
@keyframes marquee { to { transform: translateX(calc(-50% - 7px)); } }

/* ---------- Sections ---------- */
.section { position: relative; padding: 120px 0; }
.section--alt { background: var(--bg-alt); }
.section__head { max-width: 720px; margin: 0 auto 64px; text-align: center; }
.section__head h2, .split__text h2, .contact h2 { font-size: clamp(2rem, 4vw, 3rem); }
.section__lead { margin-top: 18px; font-size: 1.1rem; color: var(--text-soft); }

/* ---------- Cards ---------- */
.cards { display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; }
.card {
  position: relative; padding: 32px; border-radius: var(--radius-lg);
  background: var(--surface); border: 1px solid var(--border);
  box-shadow: var(--shadow-sm);
  overflow: hidden;
  transform-style: preserve-3d;
  transform: perspective(900px) rotateX(var(--rx, 0deg)) rotateY(var(--ry, 0deg));
  transition: transform .5s var(--ease), box-shadow .4s var(--ease), border-color .3s;
}
.card::before {
  content: ""; position: absolute; inset: 0; pointer-events: none;
  background: radial-gradient(400px circle at var(--cx, 50%) var(--cy, 50%), var(--primary-soft), transparent 45%);
  opacity: 0; transition: opacity .4s;
}
.card:hover { border-color: var(--border-strong); box-shadow: var(--shadow); }
.card:hover::before { opacity: 1; }
.card__icon {
  position: relative; width: 52px; height: 52px; border-radius: 14px; margin-bottom: 24px;
  display: grid; place-items: center;
  background: var(--primary-soft);
  transition: transform .5s var(--ease), background-color .3s;
}
.card__icon svg { width: 26px; height: 26px; fill: none; stroke: var(--primary); stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }
.card:hover .card__icon { transform: translateY(-4px) rotate(-6deg); }
.card h3 { position: relative; font-size: 1.25rem; margin-bottom: 10px; }
.card p { position: relative; color: var(--text-soft); font-size: 15.5px; }

/* ---------- IA split ---------- */
.split { display: grid; grid-template-columns: 1fr 1fr; gap: 64px; align-items: center; }
.split__text .section__lead { margin-bottom: 28px; }
.checklist { display: grid; gap: 14px; }
.checklist li { position: relative; padding-left: 36px; color: var(--text-soft); }
.checklist li strong { color: var(--text); }
.checklist li::before {
  content: ""; position: absolute; left: 0; top: 2px; width: 24px; height: 24px; border-radius: 8px;
  background: var(--primary-soft) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%230d9488' stroke-width='3' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M20 6 9 17l-5-5'/%3E%3C/svg%3E") center / 14px no-repeat;
}

.terminal {
  position: relative; border-radius: var(--radius-lg); overflow: hidden;
  background: var(--surface);
  color: var(--text-soft);
  border: 1px solid var(--border);
  box-shadow: 0 30px 60px -26px rgba(13, 148, 136, .35), 0 16px 30px -22px rgba(37, 99, 235, .3);
  font-family: var(--font-mono); font-size: 13.5px;
}
.terminal__bar {
  display: flex; align-items: center; gap: 8px; padding: 13px 18px;
  background: linear-gradient(90deg, rgba(13, 148, 136, .07), rgba(37, 99, 235, .06));
  border-bottom: 1px solid var(--border);
}
.terminal__bar > span { width: 10px; height: 10px; border-radius: 50%; background: #fca5a5; }
.terminal__bar > span:nth-child(2) { background: #fcd34d; }
.terminal__bar > span:nth-child(3) { background: #86efac; }
.terminal__title { margin-left: 10px; font-size: 12px; color: var(--muted); }
.terminal__status {
  margin-left: auto; display: inline-flex; align-items: center; gap: 7px;
  padding: 4px 10px; border-radius: 999px; font-size: 11.5px;
  background: var(--primary-soft); color: var(--primary-strong);
}
.terminal__status i { width: 6px; height: 6px; border-radius: 50%; background: currentColor; animation: status-pulse 1.2s ease-in-out infinite; }
.terminal__status b { font-weight: 500; }
.terminal__status.is-done { background: rgba(22, 163, 74, .1); color: #15803d; }
.terminal__status.is-done i { animation: none; }
@keyframes status-pulse { 50% { opacity: .25; transform: scale(.6); } }

.terminal__body { min-height: 268px; padding: 20px 22px 10px; line-height: 1.9; }
.terminal__body .ln { display: flex; align-items: center; gap: 10px; min-height: 26px; white-space: pre; }
.terminal__body .ln--out { animation: ln-pop .5s var(--ease) both; }
@keyframes ln-pop { from { opacity: 0; transform: translateY(6px); filter: blur(3px); } }

.t-prompt {
  display: inline-grid; place-items: center; width: 20px; height: 20px; border-radius: 6px;
  background: var(--primary-soft); color: var(--primary); font-weight: 600; font-size: 12px;
}
.t-bin { color: var(--primary); font-weight: 600; }
.t-c { color: var(--text); }
.t-path, .t-flag, .t-arg { color: var(--secondary); }
.t-badge { display: inline-flex; align-items: center; justify-content: center; font-size: 12px; font-weight: 600; }
.t-badge--ai {
  height: 20px; padding: 0 7px; border-radius: 6px; font-size: 10.5px; letter-spacing: .04em;
  color: var(--secondary); background: rgba(37, 99, 235, .1);
}
.t-badge--ok { width: 20px; height: 20px; border-radius: 50%; font-size: 11px; color: #16a34a; background: rgba(22, 163, 74, .12); }
.t-m { color: var(--muted); }
.t-ok { color: var(--text-soft); }
.t-dots::after { content: ""; animation: dots 1.2s steps(4) infinite; }
@keyframes dots { 0% { content: ""; } 25% { content: "."; } 50% { content: ".."; } 75% { content: "..."; } }
.terminal__body .cursor { display: inline-block; width: 8px; height: 16px; margin-left: 2px; vertical-align: -3px; border-radius: 2px; background: var(--primary); animation: blink 1s steps(1) infinite; }
.terminal__body .cursor.is-typing { animation: none; }

/* progresso das etapas: linha passa pelo centro das bolinhas; --edge = centro da 1ª/última coluna */
.pipeline {
  --pad: 22px; --gap: 8px; --dot: 14px; --top: 18px; --p: 0;
  --edge: calc(var(--pad) + (100% - 2 * var(--pad) - 3 * var(--gap)) / 8);
  position: relative; display: grid; grid-template-columns: repeat(4, 1fr); gap: var(--gap);
  padding: var(--top) var(--pad) 22px; border-top: 1px solid var(--border);
}
.pipeline::before, .pipeline::after {
  content: ""; position: absolute; left: var(--edge); right: var(--edge);
  top: calc(var(--top) + var(--dot) / 2 - 1px); height: 2px; border-radius: 2px;
}
.pipeline::before { background: var(--border); }
.pipeline::after {
  background: linear-gradient(90deg, var(--primary), var(--accent), var(--secondary));
  transform-origin: 0 50%; transform: scaleX(var(--p));
  transition: transform .9s var(--ease);
}
.pipeline__step { position: relative; z-index: 1; display: flex; flex-direction: column; align-items: center; gap: 10px; font-size: 11.5px; color: var(--muted); transition: color .4s; }
.pipeline__step::before {
  content: ""; width: var(--dot); height: var(--dot); box-sizing: border-box; border-radius: 50%;
  background: var(--surface); border: 2px solid var(--border-strong);
  transition: background .4s, border-color .4s, box-shadow .4s;
}
.pipeline__step:nth-child(1) { --c: var(--primary); }
.pipeline__step:nth-child(2) { --c: #0891b2; }
.pipeline__step:nth-child(3) { --c: #0284c7; }
.pipeline__step:nth-child(4) { --c: var(--secondary); }
.pipeline__step.is-on { color: var(--text); }
.pipeline__step.is-on::before { border-color: var(--c); background: var(--c); box-shadow: 0 0 0 4px color-mix(in srgb, var(--c) 15%, transparent); }
.pipeline__pulse {
  position: absolute; z-index: 2; top: calc(var(--top) + var(--dot) / 2);
  left: calc(var(--edge) + (100% - 2 * var(--edge)) * var(--p));
  width: 6px; height: 6px; border-radius: 50%; background: #fff;
  box-shadow: 0 0 0 3px var(--primary), 0 0 14px 3px rgba(13, 148, 136, .45);
  transform: translate(-50%, -50%);
  transition: left .9s var(--ease), opacity .4s;
  animation: pulse-glow 1.4s ease-in-out infinite;
}
.pipeline.is-done .pipeline__pulse { opacity: 0; }
@keyframes pulse-glow { 50% { box-shadow: 0 0 0 3px var(--primary), 0 0 22px 7px rgba(13, 148, 136, .25); } }

/* ---------- Saúde ---------- */
.health__ecg { height: 90px; margin: -16px 0 48px; opacity: .8; }
.health__ecg svg { width: 100%; height: 100%; }
.health__ecg .ecg-line { stroke-width: 2.4; animation-duration: 6s; }
.health__grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 20px; }
.feature {
  padding: 28px; border-radius: var(--radius-lg);
  border: 1px solid var(--border); background: var(--surface);
  transition: transform .5s var(--ease), border-color .3s, box-shadow .4s;
}
.feature:hover { transform: translateY(-6px); border-color: var(--primary); box-shadow: var(--shadow); }
.feature__num {
  display: inline-block; margin-bottom: 18px;
  font-family: var(--font-mono); font-size: 13px; font-weight: 500;
  color: var(--primary); padding: 4px 10px; border-radius: 8px; background: var(--primary-soft);
}
.feature h3 { font-size: 1.12rem; margin-bottom: 10px; }
.feature p { font-size: 15px; color: var(--text-soft); }

/* ---------- Planos ---------- */
.plans {
  max-width: 880px; margin: 0 auto;
  padding: 40px; border-radius: 32px;
  background: var(--surface); border: 1px solid var(--border); box-shadow: var(--shadow);
}
.plans__switch {
  position: relative; display: grid; grid-template-columns: repeat(3, 1fr);
  max-width: 360px; margin: 0 auto 40px; padding: 5px; border-radius: 999px;
  background: var(--bg-alt); border: 1px solid var(--border);
}
.plans__switch button {
  position: relative; z-index: 1; padding: 10px 0; border: 0; background: none; border-radius: 999px;
  font-weight: 700; color: var(--muted); transition: color .3s;
}
.plans__switch button[aria-selected="true"] { color: var(--on-primary); }
.plans__thumb {
  position: absolute; top: 5px; bottom: 5px; left: 5px; width: calc((100% - 10px) / 3);
  border-radius: 999px; background: var(--primary);
  box-shadow: 0 6px 18px -6px var(--primary);
  transform: translateX(calc(var(--idx, 1) * 100%));
  transition: transform .5s var(--ease);
}
.plans__panel { display: grid; grid-template-columns: 220px 1fr; gap: 48px; align-items: center; }
.plans__meter { position: relative; width: 220px; height: 220px; }
.plans__meter svg { width: 100%; height: 100%; transform: rotate(-90deg); }
.meter-bg { fill: none; stroke: var(--bg-alt); stroke-width: 10; }
.meter-fg {
  fill: none; stroke: var(--primary); stroke-width: 10; stroke-linecap: round;
  stroke-dasharray: 326.7; stroke-dashoffset: calc(326.7 - 326.7 * var(--fill, .75));
  transition: stroke-dashoffset .8s var(--ease);
}
.plans__hours { position: absolute; inset: 0; display: grid; place-content: center; text-align: center; }
.plans__hours span { font-size: 4rem; font-weight: 800; line-height: 1; letter-spacing: -.04em; }
.plans__hours small { color: var(--muted); font-size: 14px; }
.plans__info h3 { font-size: 1.6rem; margin-bottom: 10px; }
.plans__info p { color: var(--text-soft); }
.plans__list { margin: 20px 0 28px; display: grid; gap: 10px; }
.plans__list li { display: flex; gap: 10px; align-items: center; color: var(--text-soft); }
.plans__list li::before { content: ""; width: 8px; height: 8px; border-radius: 50%; background: var(--primary); flex: none; }
.plans__info.is-swapping > * { animation: swap .5s var(--ease); }
@keyframes swap { from { opacity: 0; transform: translateY(8px); } }

.perks { display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; max-width: 880px; margin: 24px auto 0; }
.perk { padding: 22px 24px; border-radius: var(--radius); border: 1px dashed var(--border-strong); }
.perk strong { display: block; margin-bottom: 4px; }
.perk span { font-size: 14.5px; color: var(--muted); }

/* ---------- Processo: linha do tempo vertical em zigue-zague ---------- */
/* ---------- Processo: 4 etapas na horizontal, centralizadas ---------- */
.flow {
  --dot: 52px;
  position: relative; max-width: 1080px; margin: 0 auto;
  display: grid; grid-template-columns: repeat(4, 1fr); gap: 20px;
}
.flow__step { position: relative; display: flex; flex-direction: column; align-items: center; text-align: center; }

/* linha: do centro do 1º ao centro do último ponto (medido no JS) */
.flow__line {
  position: absolute; top: calc(var(--dot) / 2 - 1.5px); height: 3px; border-radius: 3px;
  left: var(--fl-x0, 12.5%); width: var(--fl-len, 75%);
  background: var(--border);
}
.flow__fill {
  position: absolute; inset: 0; border-radius: inherit;
  background: linear-gradient(90deg, var(--primary), var(--accent), var(--secondary));
  transform-origin: 0 50%; transform: scaleX(var(--fl, 0));
  transition: transform 1.1s var(--ease);
}
.flow__pulse {
  position: absolute; top: 50%; left: calc(var(--fl, 0) * 100%);
  width: 10px; height: 10px; border-radius: 50%; background: #fff;
  box-shadow: 0 0 0 3px var(--primary), 0 0 16px 4px rgba(13, 148, 136, .45);
  transform: translate(-50%, -50%);
  transition: left 1.1s var(--ease), top 1.1s var(--ease), opacity .4s;
  animation: pulse-glow 1.4s ease-in-out infinite;
}
.flow.is-idle .flow__pulse { opacity: 0; }

.flow__dot {
  position: relative; z-index: 1; flex: none;
  width: var(--dot); height: var(--dot); border-radius: 50%;
  display: grid; place-items: center;
  font-family: var(--font-mono); font-weight: 500; font-size: 16px;
  background: var(--surface); border: 2px solid var(--border-strong); color: var(--muted);
  transition: background-color .5s var(--ease), border-color .5s var(--ease), color .5s var(--ease), box-shadow .5s var(--ease), transform .5s var(--ease);
}
.flow__step.is-done .flow__dot { border-color: var(--primary); color: var(--primary); box-shadow: 0 0 0 5px var(--primary-soft); }
.flow__step.is-current .flow__dot { background: var(--primary); border-color: var(--primary); color: var(--on-primary); transform: scale(1.12); }
.flow__step.is-current .flow__dot::after {
  content: ""; position: absolute; inset: -2px; border-radius: 50%; border: 2px solid var(--primary);
  animation: step-ripple 1.6s var(--ease) infinite;
}
@keyframes step-ripple { from { transform: scale(1); opacity: .6; } to { transform: scale(1.7); opacity: 0; } }

/* card abaixo do ponto: discreto, e acende na etapa atual */
.flow__card {
  position: relative; width: 100%; margin-top: 22px;
  display: flex; flex-direction: column; align-items: center; gap: 12px;
  padding: 24px 20px 22px; border-radius: 20px;
  background: color-mix(in srgb, var(--surface) 55%, transparent); border: 1px solid var(--border);
  transition: background-color .5s var(--ease), border-color .5s var(--ease), box-shadow .5s var(--ease), transform .5s var(--ease), opacity .9s var(--ease);
}
/* setinha apontando para o ponto */
.flow__card::before {
  content: ""; position: absolute; top: -7px; left: 50%; width: 12px; height: 12px; margin-left: -6px;
  background: inherit; border-left: 1px solid var(--border); border-top: 1px solid var(--border);
  transform: rotate(45deg); transition: border-color .5s var(--ease);
}
.flow__step:hover .flow__card { transform: translateY(-4px); background: var(--surface); box-shadow: var(--shadow); }
.flow__step.is-current .flow__card {
  background: var(--surface); border-color: color-mix(in srgb, var(--primary) 45%, transparent);
  box-shadow: 0 22px 44px -24px rgba(13, 148, 136, .5), var(--shadow-sm); transform: translateY(-6px);
}
.flow__step.is-current .flow__card::before { border-color: color-mix(in srgb, var(--primary) 45%, transparent); }
.flow__card.reveal.is-visible { transform: none; }
.flow__step.is-current .flow__card.reveal.is-visible { transform: translateY(-6px); }
.flow__step:hover .flow__card.reveal.is-visible { transform: translateY(-4px); }

.flow__icon {
  width: 48px; height: 48px; flex: none; border-radius: 15px; display: grid; place-items: center;
  background: var(--primary-soft); color: var(--primary);
  transition: background-color .5s var(--ease), color .5s var(--ease), transform .6s var(--ease);
}
.flow__icon svg { width: 24px; height: 24px; fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }
.flow__step.is-current .flow__icon { background: var(--primary); color: var(--on-primary); transform: rotate(-8deg) scale(1.06); }
.flow__step:hover .flow__icon { transform: rotate(-8deg) scale(1.06); }
.flow__num { display: block; font-family: var(--font-mono); font-size: 12px; letter-spacing: .06em; text-transform: uppercase; color: var(--muted); margin-bottom: 4px; transition: color .5s; }
.flow__step.is-current .flow__num { color: var(--primary); }
.flow__card h3 { font-size: 1.1rem; margin-bottom: 6px; transition: color .5s; }
.flow__step.is-current .flow__card h3 { color: var(--primary-strong); }
.flow__card p { font-size: 14.5px; color: var(--text-soft); }

/* ---------- Relatos ---------- */
/* mosaico: relato em destaque à esquerda, os outros empilhados à direita */
.reviews {
  position: relative; isolation: isolate;
  display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px;
  max-width: 1080px; margin: 0 auto;
}
.reviews__bg {
  position: absolute; inset: -40px -60px; z-index: -1; pointer-events: none;
  background:
    radial-gradient(closest-side, var(--blob-a), transparent) 0% 30% / 420px 420px no-repeat,
    radial-gradient(closest-side, var(--blob-b), transparent) 100% 90% / 380px 380px no-repeat,
    radial-gradient(var(--grid-line) 1.2px, transparent 1.2px) 0 0 / 22px 22px;
  mask-image: radial-gradient(ellipse 75% 70% at 50% 50%, #000 40%, transparent 85%);
  -webkit-mask-image: radial-gradient(ellipse 75% 70% at 50% 50%, #000 40%, transparent 85%);
}
.review {
  position: relative; display: flex; flex-direction: column;
  padding: 26px 26px 24px; border-radius: 22px;
  background: var(--surface); border: 1px solid var(--border); box-shadow: var(--shadow-sm);
  overflow: hidden; isolation: isolate;
  transition: transform .5s var(--ease), box-shadow .5s var(--ease), border-color .3s;
}

/* brilho que segue o cursor */
.review::after {
  content: ""; position: absolute; inset: 0; z-index: -1; pointer-events: none;
  background: radial-gradient(360px circle at var(--cx, 50%) var(--cy, 0%), var(--primary-soft), transparent 60%);
  opacity: 0; transition: opacity .4s;
}
.review:hover::after { opacity: 1; }
/* fio em gradiente no topo */
.review::before {
  content: ""; position: absolute; left: 0; right: 0; top: 0; height: 3px; background: var(--grad);
  transform: scaleX(0); transform-origin: 0 50%; transition: transform .6s var(--ease);
}
.review:hover { transform: translateY(-6px); box-shadow: 0 24px 48px -24px rgba(13, 148, 136, .35), var(--shadow-sm); border-color: var(--border-strong); }
.review:hover::before { transform: scaleX(1); }
.review.reveal.is-visible { transition: opacity .9s var(--ease) calc(var(--i, 0) * 120ms), transform .5s var(--ease), box-shadow .5s var(--ease), border-color .3s; }
.review.reveal.is-visible:hover { transform: translateY(-6px); }

/* aspas decorativas no canto */
.review__mark {
  position: absolute; top: 18px; right: 20px; width: 54px; height: 54px; z-index: -1;
  fill: var(--primary); opacity: .08;
  transition: transform .6s var(--ease), opacity .4s;
}
.review:hover .review__mark { transform: rotate(-8deg) scale(1.08); opacity: .16; }

.review__head { display: flex; align-items: center; gap: 12px; }
.review__logo {
  width: 44px; height: 44px; flex: none; border-radius: 12px; overflow: hidden;
  display: grid; place-items: center; background: #fff; border: 1px solid var(--border);
  box-shadow: 0 6px 14px -8px rgba(12, 27, 42, .35);
  transition: transform .5s var(--ease);
}
.review:hover .review__logo { transform: rotate(-6deg) scale(1.06); }
.review__logo img { width: 80%; height: 80%; object-fit: contain; }
.review__logo--full { border: 0; }
.review__logo--full img { width: 100%; height: 100%; object-fit: cover; }
.review__who { display: grid; line-height: 1.3; min-width: 0; }
.review__who strong { font-size: 15.5px; color: var(--text); }
.review__who a { display: inline-flex; align-items: center; gap: 3px; width: fit-content; font-size: 13px; color: var(--muted); transition: color .25s; }
.review__who a:hover { color: var(--primary); }
.review__who a svg, .review__project svg { width: 12px; height: 12px; fill: none; stroke: currentColor; stroke-width: 2.2; stroke-linecap: round; stroke-linejoin: round; transition: transform .3s var(--ease); }
.review__who a:hover svg, .review__project:hover svg { transform: translate(2px, -2px); }

/* estrelas acendem uma a uma */
.review__stars { display: flex; gap: 3px; margin-top: 18px; font-size: 18px; line-height: 1; color: var(--border-strong); }
.review__stars span { display: inline-block; transition: color .3s, transform .5s var(--ease); }
.review.is-visible .review__stars span { color: #f5b301; animation: star-pop .5s var(--ease) both; }
.review.is-visible .review__stars span:nth-child(1) { animation-delay: .35s; }
.review.is-visible .review__stars span:nth-child(2) { animation-delay: .45s; }
.review.is-visible .review__stars span:nth-child(3) { animation-delay: .55s; }
.review.is-visible .review__stars span:nth-child(4) { animation-delay: .65s; }
.review.is-visible .review__stars span:nth-child(5) { animation-delay: .75s; }
@keyframes star-pop { 0% { color: var(--border-strong); transform: scale(.6); } 60% { transform: scale(1.25); } 100% { color: #f5b301; transform: none; } }
.review:hover .review__stars span { transform: translateY(-2px); }
.review:hover .review__stars span:nth-child(2) { transition-delay: .04s; }
.review:hover .review__stars span:nth-child(3) { transition-delay: .08s; }
.review:hover .review__stars span:nth-child(4) { transition-delay: .12s; }
.review:hover .review__stars span:nth-child(5) { transition-delay: .16s; }

/* texto cortado em ~5 linhas (vale para um ou vários parágrafos) com esmaecimento no fim */
.review__text {
  --lines: 4;
  position: relative; margin: 14px 0 0;
  font-size: 15px; line-height: 1.7; color: var(--text-soft);
  max-height: calc(var(--lines) * 1.7em); overflow: hidden;
}
.review__text p + p { margin-top: .8em; }
.review__text.is-clamped::after {
  content: ""; position: absolute; left: 0; right: 0; bottom: 0; height: 2.4em;
  background: linear-gradient(transparent, var(--surface)); pointer-events: none;
}
.review__more {
  display: inline-flex; align-items: center; gap: 6px; padding: 0; border: 0; background: none;
  font-size: 13.5px; font-weight: 600; color: var(--primary);
}
.review__more::after { content: "→"; transition: transform .3s var(--ease); }
.review__more:hover::after { transform: translateX(3px); }
.review__foot { margin-top: auto; padding-top: 20px; display: flex; align-items: center; justify-content: space-between; gap: 12px; flex-wrap: wrap; }
.review__project {
  display: inline-flex; align-items: center; gap: 6px;
  padding: 7px 14px; border-radius: 999px; font-size: 13px; font-weight: 600;
  color: var(--on-primary); background: var(--primary);
  box-shadow: 0 8px 18px -8px var(--primary);
  transition: transform .4s var(--ease), box-shadow .4s var(--ease);
}
.review__project:hover { transform: translateY(-2px); box-shadow: 0 12px 24px -10px var(--primary); }

/* janela com o relato completo */
.review-modal {
  width: min(620px, calc(100% - 32px)); max-height: calc(100% - 48px); padding: 0;
  border: 1px solid var(--border); border-radius: 24px;
  background: var(--surface); color: var(--text); box-shadow: var(--shadow-lg);
  overflow: auto;
}
.review-modal::backdrop { background: rgba(12, 27, 42, .45); backdrop-filter: blur(4px); -webkit-backdrop-filter: blur(4px); }
.review-modal[open] { animation: modal-in .45s var(--ease); }
.review-modal[open]::backdrop { animation: fade-in .3s ease; }
@keyframes modal-in { from { opacity: 0; transform: translateY(16px) scale(.97); } }
@keyframes fade-in { from { opacity: 0; } }
.review-modal__body { position: relative; padding: 34px 34px 30px; }
.review-modal__body::before { content: ""; position: absolute; left: 0; right: 0; top: 0; height: 3px; background: var(--grad); }
.review-modal__body .review__text { max-height: none; font-size: 1.05rem; line-height: 1.75; color: var(--text); margin-top: 18px; }
.review-modal__body .review__text::after { display: none; }
.review-modal__body .review__stars span { color: #f5b301; }
.review-modal__body .review__foot { padding-top: 24px; }
.review-modal__close {
  position: absolute; top: 14px; right: 14px; z-index: 1;
  width: 38px; height: 38px; border-radius: 50%; display: grid; place-items: center;
  border: 1px solid var(--border); background: var(--surface);
  transition: border-color .3s, transform .4s var(--ease);
}
.review-modal__close:hover { border-color: var(--primary); transform: rotate(90deg); }
.review-modal__close svg { width: 18px; height: 18px; fill: none; stroke: var(--text); stroke-width: 2; stroke-linecap: round; }

@media (max-width: 920px) {
  /* no tablet/celular os cards viram uma fileira deslizante */
  .reviews {
    display: flex; gap: 14px; overflow-x: auto; scroll-snap-type: x mandatory;
    margin: 0 -24px; padding: 4px 24px 16px; scrollbar-width: none;
  }
  .reviews::-webkit-scrollbar { display: none; }
  .reviews__bg { display: none; }
  .review { flex: 0 0 min(340px, 82%); scroll-snap-align: center; }
}
@media (max-width: 640px) {
  .reviews { margin: 0 -16px; padding: 4px 16px 16px; }
}

/* ---------- FAQ ---------- */
.faq { display: grid; gap: 12px; }
.faq details {
  border-radius: var(--radius); background: var(--surface); border: 1px solid var(--border);
  transition: border-color .3s, box-shadow .3s;
}
.faq details[open] { border-color: var(--primary); box-shadow: var(--shadow-sm); }
.faq summary {
  list-style: none; cursor: pointer; padding: 22px 60px 22px 24px; position: relative;
  font-weight: 700; font-size: 1.05rem;
}
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after, .faq summary::before {
  content: ""; position: absolute; right: 24px; top: 50%; width: 14px; height: 2px; border-radius: 2px;
  background: var(--primary); transition: transform .4s var(--ease);
}
.faq summary::before { transform: rotate(90deg); }
.faq details[open] summary::before { transform: rotate(0); }
.faq details > div { padding: 0 24px 22px; color: var(--text-soft); }
.faq details[open] > div { animation: swap .45s var(--ease); }

/* ---------- Contato ---------- */
.contact__box {
  position: relative; overflow: hidden;
  display: grid; grid-template-columns: 1fr 1fr; gap: 56px;
  padding: 64px; border-radius: 36px;
  background: var(--surface); border: 1px solid var(--border); box-shadow: var(--shadow-lg);
}
.contact__glow {
  position: absolute; width: 600px; height: 600px; top: -300px; left: -200px; border-radius: 50%;
  background: radial-gradient(circle, var(--blob-a), transparent 70%);
  animation: float-b 16s ease-in-out infinite; pointer-events: none;
}
.contact__text { position: relative; }
.contact__text > p { margin-top: 16px; color: var(--text-soft); font-size: 1.1rem; }
.contact__links { margin-top: 36px; display: grid; gap: 12px; }
.contact__link {
  display: inline-flex; align-items: center; gap: 12px; width: fit-content;
  padding: 12px 18px; border-radius: 14px; border: 1px solid var(--border);
  background: var(--bg); font-weight: 600; font-size: 15px;
  transition: border-color .3s, transform .4s var(--ease), color .3s;
}
.contact__link:hover { border-color: var(--primary); color: var(--primary); transform: translateX(6px); }
.contact__link svg { width: 20px; height: 20px; fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }

.form { position: relative; display: grid; gap: 14px; }
.field { position: relative; }
.field input, .field textarea {
  width: 100%; padding: 22px 16px 10px; border-radius: 14px;
  border: 1px solid var(--border-strong); background: var(--bg);
  font: inherit; font-size: 16px; color: var(--text); resize: vertical;
  transition: border-color .25s, box-shadow .25s;
}
.field input:focus, .field textarea:focus { outline: none; border-color: var(--primary); box-shadow: 0 0 0 4px var(--primary-soft); }
.field > label {
  position: absolute; left: 17px; top: 17px; font-size: 16px; color: var(--muted); pointer-events: none;
  transform-origin: 0 0; transition: transform .25s var(--ease), color .25s;
}
.field input:focus + label, .field input:not(:placeholder-shown) + label,
.field textarea:focus + label, .field textarea:not(:placeholder-shown) + label {
  transform: translateY(-10px) scale(.75); color: var(--primary);
}
.field.is-invalid input, .field.is-invalid textarea { border-color: #ef4444; }
.field__label { display: block; font-size: 14px; color: var(--muted); margin-bottom: 8px; }
.chips { display: flex; flex-wrap: wrap; gap: 8px; }
.chips label { position: relative; }
.chips input { position: absolute; opacity: 0; pointer-events: none; }
.chips span {
  display: inline-block; padding: 8px 16px; border-radius: 999px; cursor: pointer;
  border: 1px solid var(--border-strong); font-size: 14px; font-weight: 600; color: var(--text-soft);
  transition: all .25s var(--ease);
}
.chips input:checked + span { background: var(--primary); border-color: var(--primary); color: var(--on-primary); }
.chips input:focus-visible + span { outline: 2px solid var(--primary); outline-offset: 2px; }
.form__status { min-height: 1.4em; font-size: 14px; color: var(--muted); text-align: center; }
.form__status.is-error { color: #dc2626; }
.form__status a { color: var(--primary); font-weight: 600; text-decoration: underline; }
.form__hp { position: absolute; left: -9999px; width: 1px; height: 1px; overflow: hidden; }

/* botão: estado enviando */
.form__spinner {
  position: absolute; left: 50%; top: 50%; width: 22px; height: 22px; margin: -11px 0 0 -11px;
  border-radius: 50%; border: 2.5px solid rgba(255, 255, 255, .35); border-top-color: #fff;
  opacity: 0; animation: spin .8s linear infinite;
}
.form__submit.is-loading { pointer-events: none; }
.form__submit.is-loading .form__submit-text, .form__submit.is-loading svg { opacity: 0; }
.form__submit.is-loading .form__spinner { opacity: 1; }
.form__submit-text, .form__submit svg { transition: opacity .2s; }

/* sucesso: campos somem e o card de confirmação aparece */
.form > :not(.form__success) { transition: opacity .4s var(--ease), transform .4s var(--ease); }
.form.is-sent > :not(.form__success) { opacity: 0; transform: translateY(-8px); pointer-events: none; visibility: hidden; }
.form__success {
  position: absolute; inset: 0; display: grid; place-content: center; justify-items: center; gap: 10px;
  text-align: center; padding: 24px;
  opacity: 0; visibility: hidden; transform: scale(.96);
  transition: opacity .5s var(--ease) .15s, transform .5s var(--ease) .15s, visibility 0s .6s;
}
.form.is-sent .form__success { opacity: 1; visibility: visible; transform: none; transition-delay: .15s, .15s, 0s; }
.form__success h3 { font-size: 1.5rem; margin-top: 6px; }
.form__success p { color: var(--text-soft); max-width: 320px; margin-bottom: 14px; }
.form__check { width: 72px; height: 72px; }
.form__check circle, .form__check path { fill: none; stroke: var(--primary); stroke-width: 3; stroke-linecap: round; stroke-linejoin: round; }
.form__check circle { stroke-dasharray: 151; stroke-dashoffset: 151; fill: var(--primary-soft); }
.form__check path { stroke-dasharray: 40; stroke-dashoffset: 40; }
.form.is-sent .form__check circle { animation: draw .7s var(--ease) .3s forwards; }
.form.is-sent .form__check path { animation: draw .45s var(--ease) .85s forwards; }
@keyframes draw { to { stroke-dashoffset: 0; } }

/* ---------- Footer ---------- */
.footer { padding: 40px 0; border-top: 1px solid var(--border); }
.footer__inner { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 16px; }
.footer__copy, .footer__cat { font-size: 14px; color: var(--muted); }

/* ---------- WhatsApp flutuante ---------- */
.wpp-float {
  position: fixed; right: 24px; bottom: 24px; z-index: 60;
  display: flex; align-items: center; gap: 12px;
  animation: wpp-in .8s var(--ease) 1.2s both;
}
.wpp-float__btn {
  position: relative; width: 60px; height: 60px; border-radius: 50%;
  display: grid; place-items: center;
  background: #25d366; color: #fff;
  box-shadow: 0 12px 28px -8px rgba(37, 211, 102, .65), 0 4px 10px rgba(12, 27, 42, .12);
  transition: transform .4s var(--ease), box-shadow .4s var(--ease);
}
.wpp-float__btn::before, .wpp-float__btn::after {
  content: ""; position: absolute; inset: 0; border-radius: 50%;
  border: 2px solid #25d366; animation: wpp-ring 2.6s var(--ease) infinite;
}
.wpp-float__btn::after { animation-delay: 1.3s; }
.wpp-float__btn svg { width: 30px; height: 30px; fill: currentColor; }
.wpp-float__label {
  padding: 10px 16px; border-radius: 999px;
  background: var(--surface); border: 1px solid var(--border); box-shadow: var(--shadow);
  font-size: 14px; font-weight: 600; color: var(--text); white-space: nowrap;
  opacity: 0; transform: translateX(10px); pointer-events: none;
  transition: opacity .35s var(--ease), transform .35s var(--ease);
}
.wpp-float:hover .wpp-float__btn, .wpp-float:focus-visible .wpp-float__btn { transform: scale(1.08) rotate(-6deg); box-shadow: 0 16px 34px -8px rgba(37, 211, 102, .75), 0 4px 10px rgba(12, 27, 42, .12); }
.wpp-float:hover .wpp-float__label, .wpp-float:focus-visible .wpp-float__label { opacity: 1; transform: none; }
@keyframes wpp-in { from { opacity: 0; transform: translateY(20px) scale(.8); } }
@keyframes wpp-ring { from { transform: scale(1); opacity: .5; } to { transform: scale(1.6); opacity: 0; } }
@media (max-width: 640px) {
  .wpp-float { right: 16px; bottom: 16px; }
  .wpp-float__btn { width: 54px; height: 54px; }
  .wpp-float__btn svg { width: 27px; height: 27px; }
}

/* ---------- Reveal on scroll ---------- */
.reveal {
  opacity: 0; transform: translateY(28px);
  transition: opacity .9s var(--ease), transform .9s var(--ease);
  transition-delay: calc(var(--i, 0) * 90ms);
}
.reveal.is-visible { opacity: 1; transform: none; }
.card.reveal.is-visible { transform: perspective(900px) rotateX(var(--rx, 0deg)) rotateY(var(--ry, 0deg)); }
.no-js .reveal { opacity: 1; transform: none; }

/* ---------- Responsivo ---------- */
@media (max-width: 1080px) {
  .cards { grid-template-columns: repeat(2, 1fr); }
  .health__grid { grid-template-columns: repeat(2, 1fr); }
  /* cartões do hero descem para a base para não cobrir o rosto */
  .hero__visual { margin-bottom: 24px; }
  .float-card--ai { top: auto; bottom: -7%; left: -8%; }
  .float-card--ecg { top: auto; bottom: -7%; right: -3%; width: 190px; }
  .float-card--code { display: none; }

  .nav {
    position: fixed; top: var(--header-h); left: 0; right: 0;
    flex-direction: column; gap: 4px; padding: 16px 24px 28px;
    background: var(--bg); border-bottom: 1px solid var(--border); box-shadow: var(--shadow);
    clip-path: inset(0 0 100% 0); visibility: hidden;
    transition: clip-path .5s var(--ease), visibility 0s .5s;
  }
  .nav.is-open { clip-path: inset(0 0 0 0); visibility: visible; transition: clip-path .5s var(--ease); }
  .nav a { padding: 14px 12px; font-size: 18px; border-radius: 12px; }
  .menu-toggle { display: block; }
}

@media (max-width: 920px) {
  .hero { padding-top: calc(var(--header-h) + 32px); }
  .hero__inner { grid-template-columns: 1fr; gap: 64px; }
  .hero__content { text-align: center; }
  .hero__lead { margin-inline: auto; }
  .hero__ctas, .hero__chips { justify-content: center; }
  .hero__visual { max-width: 400px; }
  .scroll-cue { display: none; }

  .split { grid-template-columns: 1fr; gap: 48px; }
  .plans__panel { grid-template-columns: 1fr; justify-items: center; text-align: center; gap: 28px; }
  .plans__list { justify-items: center; }
  /* tablet/celular: etapas empilhadas, linha vertical à esquerda */
  .flow { grid-template-columns: 1fr; gap: 16px; padding-left: 68px; }
  .flow__step { flex-direction: row; align-items: flex-start; text-align: left; }
  .flow { --dot: 48px; }
  .flow__dot { position: absolute; left: -62px; top: 18px; }
  .flow__line { left: var(--fl-x0, 26px); width: 3px; top: var(--fl-y0, 48px); height: var(--fl-len, 80%); }
  .flow__fill { background: linear-gradient(180deg, var(--primary), var(--accent), var(--secondary)); transform-origin: 50% 0; transform: scaleY(var(--fl, 0)); }
  .flow__pulse { left: 50%; top: calc(var(--fl, 0) * 100%); }
  .flow__card { margin-top: 0; flex-direction: row; align-items: flex-start; text-align: left; gap: 14px; padding: 20px; }
  .flow__card::before { top: 34px; left: -7px; margin-left: 0; transform: rotate(-45deg); }
  .flow__step.is-current .flow__card, .flow__step.is-current .flow__card.reveal.is-visible { transform: translateX(4px); }
  .contact__box { grid-template-columns: 1fr; padding: 40px; gap: 40px; }
}

@media (max-width: 640px) {
  body { font-size: 16px; }
  .container { padding: 0 16px; }
  .hide-sm { display: none; }
  .section { padding: 88px 0; }
  .section__head { margin-bottom: 44px; }
  .cards, .health__grid, .perks { grid-template-columns: 1fr; }
  .flow { --dot: 42px; padding-left: 58px; }
  .flow__dot { left: -54px; }
  .flow__card { padding: 16px; gap: 12px; }
  .flow__icon { width: 40px; height: 40px; }
  .card { padding: 26px; }
  .hero__ctas .btn { width: 100%; }
  .hero__visual { max-width: 320px; }
  .float-card--ai { left: 0; right: 0; bottom: -8%; margin-inline: auto; width: max-content; }
  .float-card--ecg { display: none; }
  .plans { padding: 28px 18px; border-radius: 24px; }
  .plans__meter { width: 180px; height: 180px; }
  .plans__hours span { font-size: 3.2rem; }
  .contact__box { padding: 28px 18px; border-radius: 24px; }
  .contact__link { width: 100%; font-size: 14px; word-break: break-all; }
  .footer__inner { flex-direction: column; text-align: center; }
}

/* ---------- Acessibilidade: menos movimento ---------- */
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after {
    animation-duration: .001ms !important; animation-iteration-count: 1 !important;
    transition-duration: .001ms !important; transition-delay: 0s !important;
  }
  .reveal { opacity: 1; transform: none; }
  .ecg path, .ecg-line { stroke-dashoffset: 0; }
}
