:root {
  --bg: #ffffff;
  --bg-soft: #f8f9fa;
  --ink: #1f1f1f;
  --ink-2: #5f6368;
  --ink-3: #80868b;
  --line: #dadce0;
  --line-soft: #e8eaed;

  --ok: #0cce6b;
  --ok-ink: #078a48;
  --warn: #ffa400;
  --warn-ink: #a36a00;
  --bad: #ff4e42;
  --bad-ink: #c5221f;
  --crit: #a50e0e;

  --sans: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Inter, Helvetica, Arial, sans-serif;
  --mono: ui-monospace, SFMono-Regular, Menlo, Consolas, "Liberation Mono", monospace;
}

* { box-sizing: border-box; }

html, body {
  margin: 0;
  padding: 0;
  background: var(--bg);
  color: var(--ink);
  font-family: var(--sans);
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

[hidden] { display: none !important; }

.wrap { max-width: 940px; margin: 0 auto; padding: 0 24px; }

/* ======================================================= HERO / BUSCA */

.hero {
  padding: 96px 0 72px;
  text-align: center;
}
.hero.compact { padding: 40px 0 24px; }

.brand {
  font-size: 13px;
  letter-spacing: .04em;
  color: var(--ink-3);
  margin: 0 0 20px;
  text-transform: uppercase;
}

h1.title {
  font-size: clamp(34px, 5.2vw, 54px);
  line-height: 1.1;
  letter-spacing: -0.028em;
  font-weight: 400;
  margin: 0 0 18px;
}
.hero.compact h1.title { font-size: clamp(22px, 3vw, 28px); margin-bottom: 14px; }

.sub {
  font-size: 17px;
  line-height: 1.6;
  color: var(--ink-2);
  max-width: 600px;
  margin: 0 auto 40px;
}
.hero.compact .sub { display: none; }
.hero.compact .brand { display: none; }

.field {
  display: flex;
  align-items: center;
  gap: 8px;
  max-width: 620px;
  margin: 0 auto;
  border: 1px solid var(--line);
  border-radius: 999px;
  padding: 6px 6px 6px 22px;
  transition: box-shadow .18s, border-color .18s;
  background: #fff;
}
.field:focus-within {
  border-color: transparent;
  box-shadow: 0 1px 6px rgba(32,33,36,.28);
}
.field input {
  flex: 1;
  min-width: 0;
  border: 0;
  outline: 0;
  font-family: var(--sans);
  font-size: 16px;
  color: var(--ink);
  height: 42px;
  background: transparent;
}
.field input::placeholder { color: var(--ink-3); }
.field button {
  border: 0;
  border-radius: 999px;
  background: var(--ink);
  color: #fff;
  font-family: var(--sans);
  font-size: 14px;
  font-weight: 500;
  height: 42px;
  padding: 0 26px;
  cursor: pointer;
  transition: opacity .15s;
  white-space: nowrap;
}
.field button:hover { opacity: .86; }
.field button:disabled { opacity: .4; cursor: default; }

.hint { font-size: 13px; color: var(--ink-3); margin: 16px 0 0; }

.err {
  max-width: 620px;
  margin: 20px auto 0;
  font-size: 14px;
  color: var(--bad-ink);
  background: #fce8e6;
  border-radius: 8px;
  padding: 12px 16px;
  text-align: left;
}

/* barra de progresso indeterminada */
.progress {
  position: fixed; top: 0; left: 0; right: 0; height: 3px;
  background: var(--line-soft); overflow: hidden; z-index: 50;
}
.progress i {
  position: absolute; inset: 0 auto 0 0; width: 30%;
  background: var(--ink);
  animation: slide 1.15s cubic-bezier(.4,0,.2,1) infinite;
}
@keyframes slide {
  0%   { left: -30%; width: 30%; }
  50%  { left: 40%;  width: 45%; }
  100% { left: 100%; width: 30%; }
}
.loading-note {
  text-align: center;
  font-size: 14px;
  color: var(--ink-2);
  margin-top: 28px;
}

/* ======================================================= CABEÇALHO DO LAUDO */

.urlbar {
  display: flex; align-items: baseline; justify-content: center;
  gap: 14px; flex-wrap: wrap;
  font-size: 13px; color: var(--ink-3);
  padding: 8px 0 44px;
}
.urlbar b { color: var(--ink-2); font-weight: 500; font-size: 14px; }

/* ---- número gigante ---- */
.headline { text-align: center; padding-bottom: 56px; }
.headline .big {
  font-size: clamp(96px, 21vw, 210px);
  line-height: .86;
  letter-spacing: -0.055em;
  font-weight: 500;
  font-variant-numeric: tabular-nums;
  display: block;
  margin-bottom: 18px;
}
.headline .big.s-otimo, .headline .big.s-bom { color: var(--ok-ink); }
.headline .big.s-ruim    { color: var(--warn-ink); }
.headline .big.s-pessimo { color: var(--bad-ink); }
.headline .big.s-critico { color: var(--crit); }

.headline .caption {
  font-size: clamp(20px, 3.4vw, 30px);
  line-height: 1.25;
  letter-spacing: -0.02em;
  font-weight: 400;
  color: var(--ink);
  max-width: 620px;
  margin: 0 auto;
}

/* ---- os dois medidores ---- */
.gauges {
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  align-items: center;
  gap: 20px;
  border-top: 1px solid var(--line-soft);
  border-bottom: 1px solid var(--line-soft);
  padding: 44px 0;
  margin-bottom: 56px;
}
@media (max-width: 700px) {
  .gauges { grid-template-columns: 1fr; gap: 32px; }
}

.gauge { text-align: center; }
.gauge svg { display: block; margin: 0 auto 16px; }
.gauge .ring-bg { stroke: var(--line-soft); }
.gauge .ring-fg {
  transition: stroke-dashoffset 1.6s cubic-bezier(.2,.7,.2,1);
  transform: rotate(-90deg);
  transform-origin: 50% 50%;
}
.gauge .num {
  font-size: 54px;
  font-weight: 500;
  letter-spacing: -0.04em;
  font-variant-numeric: tabular-nums;
  dominant-baseline: central;
  text-anchor: middle;
}
.gauge .lbl {
  font-size: 13px;
  letter-spacing: .09em;
  text-transform: uppercase;
  color: var(--ink-3);
  margin-bottom: 4px;
}
.gauge .sub-lbl { font-size: 13px; color: var(--ink-3); }

.gap-badge { text-align: center; padding: 0 8px; }
.gap-badge .n {
  font-size: clamp(38px, 6vw, 60px);
  font-weight: 500;
  letter-spacing: -0.04em;
  line-height: 1;
  font-variant-numeric: tabular-nums;
  color: var(--ink);
}
.gap-badge .t {
  font-size: 12px;
  letter-spacing: .09em;
  text-transform: uppercase;
  color: var(--ink-3);
  margin-top: 8px;
  max-width: 130px;
}

/* ---- consequências ---- */
.conseq-label {
  text-align: center; font-size: 12px; letter-spacing: .1em; text-transform: uppercase;
  color: var(--ink-3); margin: 0 0 14px;
}
.conseq { list-style: none; padding: 0; margin: 0 auto 56px; max-width: 620px; }
.conseq li {
  font-size: 16px;
  line-height: 1.55;
  color: var(--ink-2);
  padding: 12px 0;
  border-bottom: 1px solid var(--line-soft);
}
.conseq li:first-child { border-top: 1px solid var(--line-soft); }

/* ======================================================= SEÇÕES */

.section { margin-bottom: 60px; }
.sec-head {
  display: flex; align-items: baseline; justify-content: space-between;
  gap: 16px; flex-wrap: wrap;
  margin-bottom: 20px;
}
.sec-head h2 {
  font-size: 20px; font-weight: 500; letter-spacing: -0.015em; margin: 0;
}
.sec-head .meta { font-size: 13px; color: var(--ink-3); }

/* ---- comparação lado a lado ---- */
.compare {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 20px;
}
@media (max-width: 760px) { .compare { grid-template-columns: 1fr; } }

.card {
  border: 1px solid var(--line);
  border-radius: 12px;
  overflow: hidden;
  background: #fff;
}
.card-head { padding: 16px 18px; border-bottom: 1px solid var(--line-soft); }
.card-head .k {
  font-size: 12px; letter-spacing: .08em; text-transform: uppercase;
  color: var(--ink-3); margin-bottom: 6px;
}
.card-head .v { font-size: 13px; color: var(--ink-2); }
.card-body { height: 340px; overflow: auto; position: relative; background: var(--bg-soft); }
.card-body.white { background: #fff; }

iframe.live { width: 100%; height: 100%; border: 0; background: #fff; position: relative; z-index: 1; }
.iframe-ph {
  position: absolute; inset: 0; z-index: 0;
  display: flex; align-items: center; justify-content: center;
  font-size: 13px; color: var(--ink-3);
}

.raw {
  margin: 0; padding: 18px;
  font-family: var(--mono);
  font-size: 12px; line-height: 1.7;
  color: #3c4043;
  white-space: pre-wrap; word-break: break-word;
}

.empty {
  height: 100%; display: flex; flex-direction: column;
  align-items: center; justify-content: center; text-align: center;
  padding: 32px; gap: 12px;
}
.empty .big-x { font-size: 44px; line-height: 1; color: var(--bad); font-weight: 300; }
.empty .msg { font-size: 15px; font-weight: 500; color: var(--ink); }
.empty .detail { font-size: 13px; line-height: 1.6; color: var(--ink-2); max-width: 320px; }

.mock-inner { padding: 22px; }
.mock-inner img { width: 100%; display: block; margin-bottom: 16px; border-radius: 6px; }
.mock-inner h3 { font-size: 18px; margin: 0 0 8px; line-height: 1.3; }
.mock-inner p { font-size: 14px; line-height: 1.6; color: var(--ink-2); margin: 0 0 12px; }
.mock-inner .chip {
  display: inline-block; font-size: 11px; letter-spacing: .06em; text-transform: uppercase;
  background: var(--line-soft); color: var(--ink-3); padding: 4px 9px; border-radius: 4px; margin-bottom: 14px;
}

.compare-foot { font-size: 12px; color: var(--ink-3); margin-top: 12px; line-height: 1.6; }

/* ---- métricas ---- */
.metric {
  display: grid;
  grid-template-columns: 34px 1fr auto;
  align-items: start;
  gap: 18px;
  padding: 26px 0;
  border-bottom: 1px solid var(--line-soft);
}
.metric:first-of-type { border-top: 1px solid var(--line-soft); }

.metric .glyph {
  font-size: 22px; color: var(--ink-3); line-height: 1.1; text-align: center;
  font-family: var(--mono);
}
.metric .name {
  font-size: 19px; font-weight: 500; letter-spacing: -0.015em; margin: 0 0 10px;
  line-height: 1.2;
}
.metric .weight { font-size: 12px; color: var(--ink-3); font-weight: 400; margin-left: 10px; }
.metric .urgency { font-size: 15px; line-height: 1.5; color: var(--ink-2); margin: 10px 0 0; max-width: 56ch; }
.metric .num {
  font-size: clamp(40px, 6vw, 58px);
  font-weight: 500;
  letter-spacing: -0.045em;
  line-height: .9;
  font-variant-numeric: tabular-nums;
  text-align: right;
  min-width: 2.4ch;
}

.pill {
  display: inline-flex; align-items: center; gap: 7px;
  font-size: 12px; font-weight: 600; letter-spacing: .07em;
  padding: 5px 11px 5px 9px; border-radius: 999px;
}
.pill i { width: 9px; height: 9px; border-radius: 2px; display: inline-block; }

.s-otimo   .num, .s-otimo   .pill { color: var(--ok-ink); }
.s-bom     .num, .s-bom     .pill { color: var(--ok-ink); }
.s-ruim    .num, .s-ruim    .pill { color: var(--warn-ink); }
.s-pessimo .num, .s-pessimo .pill { color: var(--bad-ink); }
.s-critico .num, .s-critico .pill { color: var(--crit); }

.s-otimo   .pill { background: #e6f7ee; }
.s-bom     .pill { background: #e6f7ee; }
.s-ruim    .pill { background: #fff4e0; }
.s-pessimo .pill { background: #fce8e6; }
.s-critico .pill { background: #fce8e6; }

.s-otimo   .pill i { background: var(--ok); }
.s-bom     .pill i { background: var(--ok); }
.s-ruim    .pill i { background: var(--warn); }
.s-pessimo .pill i { background: var(--bad); }
.s-critico .pill i { background: var(--crit); }

/* ---- robots ---- */
.robots-sentence {
  font-size: clamp(17px, 2.4vw, 21px);
  line-height: 1.45;
  letter-spacing: -0.01em;
  margin: 0 0 24px;
  max-width: 720px;
}
.botgrid {
  display: grid; grid-template-columns: repeat(auto-fill, minmax(190px, 1fr)); gap: 8px;
}
.bot {
  border: 1px solid var(--line-soft); border-radius: 8px; padding: 11px 13px;
}
.bot .n { font-size: 13px; display: flex; align-items: center; gap: 8px; margin-bottom: 3px; }
.bot .n i { width: 7px; height: 7px; border-radius: 50%; flex: none; }
.bot .o { font-size: 11px; color: var(--ink-3); }
.bot.ok .n i   { background: var(--ok); }
.bot.ok .n     { color: var(--ink-2); }

.bot.warn      { border-color: #f4dcb0; background: #fffbf2; }
.bot.warn .n   { color: var(--warn-ink); }
.bot.warn .n i { background: var(--warn); }

.bot.bad       { border-color: #f7c6c2; background: #fef7f6; }
.bot.bad .n    { color: var(--crit); font-weight: 500; }
.bot.bad .n i  { background: var(--crit); }

/* ---- cta ---- */
.cta {
  border: 1px solid var(--line);
  border-radius: 14px;
  padding: 40px;
  text-align: center;
  margin-bottom: 72px;
}
.cta h3 { font-size: clamp(22px, 3.4vw, 30px); font-weight: 400; letter-spacing: -0.02em; margin: 0 0 12px; }
.cta p { font-size: 16px; line-height: 1.6; color: var(--ink-2); max-width: 540px; margin: 0 auto 28px; }

.btn {
  display: inline-block; border: 0; border-radius: 999px;
  background: var(--ink); color: #fff;
  font-family: var(--sans); font-size: 15px; font-weight: 500;
  padding: 14px 30px; text-decoration: none; cursor: pointer;
}
.btn:hover { opacity: .86; }

/* botão principal do CTA: vermelho, é a ação que resolve o vermelho da página */
.cta .btn:not(.ghost) {
  background: var(--crit);
  box-shadow: 0 2px 10px rgba(165, 14, 14, .28);
  font-weight: 600;
  padding: 16px 34px;
  font-size: 16px;
}
.cta .btn:not(.ghost):hover { background: #8c0c0c; opacity: 1; }
.btn.ghost {
  background: transparent; color: var(--ink-2);
  border: 1px solid var(--line); margin-left: 10px;
}
.btn.ghost:hover { background: var(--bg-soft); opacity: 1; }

footer {
  border-top: 1px solid var(--line-soft);
  padding: 28px 0 64px;
  font-size: 12px;
  line-height: 1.7;
  color: var(--ink-3);
  text-align: center;
}

.fade { animation: fade .45s ease both; }
@keyframes fade { from { opacity: 0; transform: translateY(10px); } to { opacity: 1; transform: none; } }

@media (max-width: 560px) {
  .hero { padding: 56px 0 40px; }
  .field { flex-wrap: wrap; border-radius: 16px; padding: 10px; }
  .field input { width: 100%; text-align: center; }
  .field button { width: 100%; }
  .metric { grid-template-columns: 1fr auto; gap: 12px; }
  .metric .glyph { display: none; }
  .cta { padding: 28px 20px; }
  .btn.ghost { margin-left: 0; margin-top: 10px; }
  .card-body { height: 280px; }
}

/* ---- alerta do topo (substitui a legenda antiga) ---- */
.headline-scale {
  font-size: 14px;
  color: var(--ink-3);
  margin: 0 0 26px;
}
.alert {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  font-size: clamp(16px, 2.5vw, 21px);
  line-height: 1.35;
  font-weight: 500;
  letter-spacing: -0.01em;
  padding: 15px 24px 15px 18px;
  border-radius: 14px;
  margin: 0 auto;
  max-width: 700px;
  text-align: left;
}
.alert.crit { background: #fce8e6; color: var(--crit); }
.alert.good { background: #e6f7ee; color: var(--ok-ink); }
.alert-mark {
  width: 28px; height: 28px; border-radius: 50%;
  display: inline-flex; align-items: center; justify-content: center;
  font-weight: 700; font-size: 16px; flex: none; color: #fff;
}
.alert.crit .alert-mark { background: var(--crit); }
.alert.good .alert-mark { background: var(--ok); }

/* ---- contexto de mercado ---- */
.facts {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 18px;
}
@media (max-width: 760px) { .facts { grid-template-columns: 1fr; } }

.fact {
  border: 1px solid var(--line);
  border-radius: 12px;
  padding: 26px 22px 22px;
}
.fact-n {
  font-size: clamp(42px, 6.5vw, 62px);
  font-weight: 500;
  letter-spacing: -0.045em;
  line-height: 1;
  color: var(--ink);
}
.fact-k {
  font-size: 13px;
  letter-spacing: .08em;
  text-transform: uppercase;
  color: var(--ink-3);
  margin: 10px 0 16px;
}
.fact-t {
  font-size: 15px;
  line-height: 1.55;
  color: var(--ink-2);
  margin: 0 0 18px;
}
.fact-src {
  font-size: 12px;
  color: var(--ink-3);
  text-decoration: none;
  border-bottom: 1px solid var(--line);
  padding-bottom: 2px;
}
.fact-src:hover { color: var(--ink-2); border-color: var(--ink-3); }

.facts-foot {
  font-size: 15px;
  line-height: 1.6;
  color: var(--ink-2);
  margin: 24px 0 0;
  max-width: 640px;
}

/* ---- conteúdo estático da página (o que faz a própria ferramenta ser legível) ---- */
.doc {
  max-width: 700px;
  margin: 24px auto 72px;
  padding-top: 48px;
  border-top: 1px solid var(--line-soft);
}
.doc h2 {
  font-size: clamp(22px, 3vw, 28px);
  font-weight: 500;
  letter-spacing: -0.022em;
  margin: 52px 0 16px;
  line-height: 1.2;
}
.doc h2:first-child { margin-top: 0; }
.doc h3 {
  font-size: 17px;
  font-weight: 600;
  letter-spacing: -0.01em;
  margin: 30px 0 8px;
}
.doc p {
  font-size: 16.5px;
  line-height: 1.68;
  color: var(--ink-2);
  margin: 0 0 16px;
}
