/* RPA ROI calculator page (landing/calculadora-roi-rpa/), on top of landing.css. */

.menu a[aria-current="page"] {
  color: var(--mel-forte);
}

.calc-topo {
  position: relative;
  padding: 64px 0 28px;
  overflow: hidden;
}

.calc-topo::before {
  content: "";
  position: absolute;
  inset: -40% -10% auto auto;
  width: 760px;
  height: 760px;
  background: radial-gradient(circle, rgba(229, 168, 46, 0.12), transparent 62%);
  pointer-events: none;
}

.calc-topo .conteudo {
  position: relative;
}

.calc-topo .lead {
  margin-bottom: 0;
  max-width: 680px;
}

.calc-secao {
  padding: 28px 0 96px;
}

.calc-grade {
  display: grid;
  grid-template-columns: minmax(0, 1.25fr) minmax(0, 1fr);
  gap: 32px;
  align-items: start;
}

/* ---- form ---- */

.calc-form fieldset {
  margin: 0 0 20px;
  padding: 24px;
  background: var(--cartao);
  border: 1px solid var(--borda);
  border-radius: var(--raio);
  min-width: 0;
}

/* the last card ends flush with the result box, which sticks while
   scrolling and stops at the bottom of the grid */
.calc-form fieldset:last-child {
  margin-bottom: 0;
}

.calc-form legend {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 0;
  font-weight: 700;
  font-size: 19px;
  float: left;
  width: 100%;
  margin-bottom: 6px;
}

.calc-form legend + * {
  clear: both;
}

.calc-num {
  display: inline-grid;
  place-items: center;
  width: 28px;
  height: 28px;
  border-radius: 50%;
  background: rgba(229, 168, 46, 0.16);
  color: var(--mel-forte);
  font-size: 15px;
}

.calc-ajuda {
  margin: 0 0 16px;
  color: var(--texto-2);
  font-size: 15px;
}

.calc-campos {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 14px;
  margin-bottom: 14px;
}

.campo {
  display: flex;
  flex-direction: column;
  gap: 6px;
  min-width: 0;
}

.campo span {
  font-size: 14px;
  color: var(--texto-2);
}

.campo input {
  width: 100%;
  padding: 11px 12px;
  border-radius: 10px;
  border: 1px solid var(--borda);
  background: var(--fundo);
  color: var(--texto);
  font: inherit;
  font-size: 16px;
}

.campo input::placeholder {
  color: var(--texto-3);
}

.campo input:focus {
  outline: none;
  border-color: var(--mel);
  box-shadow: 0 0 0 3px rgba(229, 168, 46, 0.2);
}

.processos {
  display: flex;
  flex-direction: column;
  gap: 12px;
  margin-bottom: 14px;
}

.processo {
  display: grid;
  grid-template-columns: minmax(0, 1.4fr) minmax(0, 1fr) minmax(0, 1fr) 36px;
  gap: 10px;
  align-items: end;
  padding-bottom: 12px;
  border-bottom: 1px dashed var(--borda);
}

.processo-remover {
  width: 36px;
  height: 44px;
  border: 1px solid var(--borda);
  border-radius: 10px;
  background: transparent;
  color: var(--texto-3);
  font-size: 22px;
  line-height: 1;
  cursor: pointer;
}

.processo-remover:hover {
  color: #f87171;
  border-color: #f87171;
}

.calc-adicionar {
  padding: 9px 16px;
  border-radius: 999px;
  border: 1px dashed var(--mel);
  background: transparent;
  color: var(--mel-forte);
  font: inherit;
  font-size: 15px;
  font-weight: 600;
  cursor: pointer;
}

.calc-adicionar:hover:not(:disabled) {
  background: rgba(229, 168, 46, 0.1);
}

.calc-adicionar:disabled {
  opacity: 0.45;
  cursor: default;
}

.calc-hora {
  border: 0;
  margin-top: 4px;
}

.calc-hora summary {
  padding: 8px 28px 8px 0;
  font-size: 15px;
  font-weight: 600;
  color: var(--mel-forte);
  display: inline-block;
}

.calc-hora summary::after {
  font-size: 20px;
}

.calc-hora[open] summary {
  margin-bottom: 12px;
}

.calc-hora p {
  margin: 0 0 14px;
}

.calc-hora #hora-calculada {
  color: var(--texto);
  font-weight: 600;
}

.calc-form button:focus-visible,
.calc-form input:focus-visible,
.calc-resultado button:focus-visible {
  outline: 2px solid var(--mel-forte);
  outline-offset: 2px;
}

/* ---- result ---- */

.calc-resultado {
  position: sticky;
  top: 84px;
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.calc-resultado-caixa {
  padding: 24px;
  border-radius: var(--raio);
  border: 1px solid rgba(229, 168, 46, 0.45);
  background: linear-gradient(180deg, rgba(229, 168, 46, 0.08), transparent 60%), var(--cartao);
  box-shadow: 0 24px 60px rgba(0, 0, 0, 0.35);
}

.calc-resultado h2 {
  font-size: 22px;
  margin-bottom: 18px;
}

.numeros {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
  margin: 0;
}

.numero {
  padding: 14px;
  border-radius: 12px;
  background: rgba(11, 20, 34, 0.55);
  border: 1px solid var(--borda);
  min-width: 0;
}

.numero-destaque {
  grid-column: 1 / -1;
}

.numero dt {
  font-size: 14px;
  color: var(--texto-2);
}

.numero dd {
  margin: 4px 0 2px;
  font-size: 26px;
  font-weight: 800;
  letter-spacing: -0.02em;
  line-height: 1.2;
  overflow-wrap: anywhere;
}

.numero-destaque dd {
  font-size: clamp(32px, 4vw, 42px);
  color: var(--mel);
}

.numero small {
  display: block;
  color: var(--texto-3);
  font-size: 13px;
  line-height: 1.4;
}

.calc-aviso {
  margin: 14px 0 0;
  padding: 10px 12px;
  border-radius: 10px;
  background: rgba(248, 113, 113, 0.1);
  border: 1px solid rgba(248, 113, 113, 0.35);
  color: #fecaca;
  font-size: 14px;
}

.calc-acoes {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 12px;
  margin-top: 18px;
}

.botao-secundario {
  border: 1px solid var(--borda);
  background: transparent;
  color: var(--texto);
  font: inherit;
  font-weight: 600;
  font-size: 15px;
  padding: 10px 18px;
  cursor: pointer;
}

.botao-secundario:hover {
  border-color: var(--mel);
}

.calc-copiado {
  color: var(--texto-2);
  font-size: 14px;
}

/* ---- explanation text ---- */

.texto-longo h2 {
  font-size: clamp(24px, 3vw, 32px);
  margin: 48px 0 16px;
}

.texto-longo h2:first-child {
  margin-top: 0;
}

.secao .texto-longo h2 + * {
  margin-top: 0;
}

.texto-longo p,
.texto-longo li {
  color: var(--texto-2);
  line-height: 1.7;
}

.texto-longo strong,
.texto-longo b {
  color: var(--texto);
}

.texto-longo ul,
.texto-longo ol {
  padding-left: 22px;
}

.texto-longo li + li {
  margin-top: 8px;
}

/* the dashboard cards (landing.css) keep their own spacing inside the text */
.texto-longo .painel-kpis {
  padding-left: 0;
}

.texto-longo .painel-kpis li {
  line-height: normal;
}

.texto-longo .painel-kpis li + li {
  margin-top: 0;
}

.formula {
  background: var(--cartao);
  border: 1px solid var(--borda);
  border-radius: var(--raio);
  padding: 18px 22px 18px 42px;
}

.calc-figura {
  margin: 28px 0 0;
}

.calc-figura figcaption {
  margin-top: 10px;
  color: var(--texto-3);
  font-size: 14px;
}

/* ---- fixed demo bar at the bottom ---- */

/* room below the footer so the bar never covers it */
body {
  padding-bottom: 76px;
}

.calc-barra {
  position: fixed;
  left: 0;
  right: 0;
  bottom: 0;
  z-index: 950; /* below the cookie notice */
  background: rgba(17, 29, 47, 0.94);
  -webkit-backdrop-filter: blur(10px);
  backdrop-filter: blur(10px);
  border-top: 1px solid rgba(229, 168, 46, 0.4);
  box-shadow: 0 -12px 32px rgba(0, 0, 0, 0.35);
  transform: translateY(110%);
  visibility: hidden;
  transition: transform 0.25s ease, visibility 0s linear 0.25s;
}

.calc-barra.visivel {
  transform: none;
  visibility: visible;
  transition: transform 0.25s ease;
}

/* while the bar is up, the cookie notice floats just above it */
.aviso-cookies {
  transition: bottom 0.25s ease;
}

body.com-barra .aviso-cookies {
  bottom: calc(var(--altura-barra, 64px) + 12px);
}

.calc-barra-linha {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  padding-top: 12px;
  padding-bottom: 12px;
}

.calc-barra-texto {
  margin: 0;
  font-size: 15px;
  color: var(--texto-2);
  line-height: 1.4;
}

.calc-barra-texto strong {
  color: var(--texto);
  margin-right: 6px;
}

/* computer: the same pitch as the box next to the result; phone: just the
   estimate, the button says the rest */
.calc-barra-celular {
  display: none;
  color: var(--mel-forte);
  font-weight: 600;
}

.calc-barra .botao {
  padding: 10px 20px;
  font-size: 15px;
  flex-shrink: 0;
}

/* ---- responsive ---- */

@media (prefers-reduced-motion: reduce) {
  .calc-barra,
  .calc-barra.visivel {
    transition: none;
  }
}

@media (max-width: 980px) {
  .calc-grade {
    grid-template-columns: minmax(0, 1fr);
  }

  .calc-resultado {
    position: static;
  }
}

@media (max-width: 620px) {
  .calc-barra-linha {
    gap: 12px;
    padding-top: 10px;
    padding-bottom: 10px;
  }

  .calc-barra-texto strong,
  .calc-barra-pc {
    display: none;
  }

  .calc-barra-celular {
    display: inline;
  }

  .calc-barra-texto {
    font-size: 14px;
  }

  .calc-barra .botao {
    padding: 10px 14px;
    font-size: 14px;
    white-space: normal;
    text-align: center;
  }

  .calc-topo {
    padding: 40px 0 16px;
  }

  .calc-secao {
    padding: 16px 0 64px;
  }

  .calc-form fieldset,
  .calc-resultado-caixa {
    padding: 18px 16px;
  }

  .calc-campos {
    grid-template-columns: minmax(0, 1fr);
  }

  .processo {
    grid-template-columns: minmax(0, 1fr) minmax(0, 1fr) 36px;
  }

  .processo .campo-nome {
    grid-column: 1 / -1;
  }

  .numeros {
    grid-template-columns: minmax(0, 1fr);
  }
}
