/* =========================================================================
   FATE — SIMULADOR DE ROI (Solução Delivery)
   Estilos específicos da calculadora. Reutiliza tokens/header/footer de main.css.
   ========================================================================= */

/* Fundo com brilhos azuis (alinhado à marca) */
.sim-page {
  background-image:
    radial-gradient(circle at 20% 25%, rgba(0, 85, 255, 0.15) 0%, transparent 50%),
    radial-gradient(circle at 85% 80%, rgba(0, 85, 255, 0.08) 0%, transparent 50%);
}

/* Cabeçalho minimalista (apenas logo, não fixo) */
.sim-header { display: flex; justify-content: center; padding: 24px 20px 8px; }
.sim-header__logo { display: inline-flex; }
.sim-header__logo img { height: 56px; width: auto; }

.sim-hero { text-align: center; padding: 24px 20px 16px; }
.sim-hero__eyebrow {
  font-family: var(--font-title); font-weight: 400; letter-spacing: 1.5px;
  text-transform: uppercase; font-size: clamp(1rem, 2.4vw, 1.4rem);
  color: #f5f5f5; text-shadow: var(--accent-blue) 0 0 15px; margin: 0 0 16px;
}
.sim-hero__title {
  font-family: var(--font-title); font-weight: 400; text-transform: uppercase;
  font-size: clamp(2.4rem, 6.5vw, 4rem); letter-spacing: 1.5px; line-height: 0.98;
  margin: 0 0 18px; text-shadow: rgba(0, 0, 0, 0.4) 0 0 15px;
}
.sim-hero__title span { display: block; }
.sim-hero__subtitle {
  font-size: clamp(1rem, 2.2vw, 1.2rem); max-width: 760px; margin: 0 auto;
  color: #fff; font-weight: 300;
}
.sim-hero__subtitle strong { color: var(--accent-green); font-weight: 700; }

/* --- Container glass --- */
.sim-wrap { padding: 16px 20px 64px; display: flex; justify-content: center; }
.sim-box {
  background: rgba(20, 20, 30, 0.45);
  backdrop-filter: blur(30px) saturate(160%);
  -webkit-backdrop-filter: blur(30px) saturate(160%);
  border: 1px solid var(--border-glass);
  width: 100%; max-width: 980px; padding: 40px;
  border-radius: 28px; box-shadow: 0 40px 80px rgba(0, 0, 0, 0.6);
  position: relative; z-index: 1;
}
.sim-box > h4 {
  text-align: center; font-family: var(--font-text); font-size: 1.02rem; font-weight: 300;
  color: #fff; margin: 0 auto 30px; line-height: 1.5; max-width: 720px; opacity: 0.9;
}

.calculator-grid { display: grid; grid-template-columns: 1fr 0.95fr; gap: 50px; align-items: start; }
/* Evita que texto nowrap estoure a coluna e empurre o grid para fora da tela */
.calculator-grid > * { min-width: 0; }

/* =========================================================================
   INPUTS — sliders lúdicos
   ========================================================================= */
.inputs-section { display: flex; flex-direction: column; gap: 34px; }
.input-group { display: flex; flex-direction: column; gap: 14px; }
.input-label {
  font-size: 0.95rem; font-weight: 600; color: #fff;
  letter-spacing: 0.5px; text-transform: uppercase; display: flex;
  justify-content: space-between; align-items: baseline; gap: 12px;
}
.input-value {
  font-family: var(--font-title); font-size: 1.6rem; font-weight: 400;
  color: var(--accent-blue); letter-spacing: 1px; text-shadow: 0 0 12px rgba(0, 85, 255, 0.5);
  white-space: nowrap;
}

/* Range slider estilizado */
.slider {
  -webkit-appearance: none; appearance: none;
  width: 100%; height: 8px; border-radius: 20px; outline: none; cursor: pointer;
  background: rgba(0, 85, 255, 0.12);
  border: 1px solid rgba(0, 85, 255, 0.25);
}
.slider::-webkit-slider-thumb {
  -webkit-appearance: none; appearance: none;
  width: 26px; height: 26px; border-radius: 50%;
  background: radial-gradient(circle at 35% 35%, #4d8bff, var(--accent-blue));
  border: 3px solid #fff; cursor: pointer;
  box-shadow: 0 0 0 4px rgba(0, 85, 255, 0.2), 0 4px 14px rgba(0, 85, 255, 0.6);
  transition: transform 0.15s ease, box-shadow 0.15s ease;
}
.slider::-webkit-slider-thumb:hover { transform: scale(1.15); box-shadow: 0 0 0 6px rgba(0, 85, 255, 0.25), 0 6px 20px rgba(0, 85, 255, 0.8); }
.slider::-webkit-slider-thumb:active { transform: scale(1.25); }
.slider::-moz-range-thumb {
  width: 26px; height: 26px; border-radius: 50%;
  background: radial-gradient(circle at 35% 35%, #4d8bff, var(--accent-blue));
  border: 3px solid #fff; cursor: pointer;
  box-shadow: 0 0 0 4px rgba(0, 85, 255, 0.2), 0 4px 14px rgba(0, 85, 255, 0.6);
}
.slider-ticks { display: flex; justify-content: space-between; margin-top: 8px; padding: 0 4px; }
.slider-ticks span { font-size: 0.7rem; color: var(--text-muted); }

/* =========================================================================
   RESULTADOS
   ========================================================================= */
.sim-results { display: flex; flex-direction: column; gap: 15px; position: relative; }
.sim-results-header {
  background: linear-gradient(90deg, #071022, var(--accent-blue));
  border: 1px solid rgba(255, 255, 255, 0.1); color: #fff;
  padding: 16px; text-align: center; border-radius: 12px;
  font-family: var(--font-title); font-size: 1.6rem; font-weight: 400; letter-spacing: 1px;
  margin-bottom: 10px; box-shadow: 0 4px 20px rgba(0, 85, 255, 0.25); z-index: 2;
}
.results-content { display: flex; flex-direction: column; gap: 12px; transition: filter 0.8s ease, opacity 0.8s ease; }
.blur-active { filter: blur(12px); opacity: 0.5; user-select: none; pointer-events: none; }

.sim-result-card {
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid rgba(255, 255, 255, 0.05);
  padding: 14px 18px; border-radius: 12px;
  display: flex; justify-content: space-between; align-items: center;
  position: relative; overflow: hidden;
  transition: transform 0.2s ease, background 0.2s ease;
}
.sim-result-card:hover { transform: translateX(4px); background: rgba(255, 255, 255, 0.05); }
.sim-result-card::before {
  content: ''; position: absolute; left: 0; top: 0; bottom: 0; width: 4px;
  background-color: var(--dot-color); box-shadow: 0 0 12px var(--dot-color);
}
.card-inner { display: flex; align-items: center; gap: 12px; }
.card-icon { font-size: 1.3rem; line-height: 1; filter: drop-shadow(0 0 6px var(--dot-color)); }
.card-label { font-weight: 400; color: #f0f0f0; font-size: 0.95rem; }
.card-value { font-family: var(--font-title); font-weight: 400; font-size: 1.6rem; color: #fff; letter-spacing: 0.5px; }

/* Card de destaque (Lucro) */
.sim-result-card.card-highlight {
  background: linear-gradient(135deg, rgba(0, 255, 136, 0.08), rgba(0, 85, 255, 0.05));
  border-color: rgba(0, 255, 136, 0.25); padding: 18px;
}
.sim-result-card.card-highlight .card-value { font-size: 2rem; color: var(--accent-green); text-shadow: 0 0 15px rgba(0, 255, 136, 0.4); }

.border-green { --dot-color: #00ff88; }
.border-blue { --dot-color: #0a84ff; }
.border-gray { --dot-color: #8e8e93; }
.border-purple { --dot-color: #bf5af2; }
.border-red { --dot-color: #ff453a; }

/* Overlay de revelação */
.reveal-overlay {
  position: absolute; top: 74px; left: 0; width: 100%; height: calc(100% - 74px);
  display: flex; justify-content: center; align-items: center; z-index: 10;
  transition: opacity 0.4s ease;
}
.btn-reveal {
  background: rgba(0, 85, 255, 0.18); color: #fff;
  border: 1px solid rgba(0, 85, 255, 0.45); padding: 16px 30px;
  font-size: 1rem; font-weight: 600; border-radius: 50px; cursor: pointer;
  backdrop-filter: blur(10px); transition: all 0.3s;
  display: flex; align-items: center; gap: 10px; box-shadow: 0 10px 30px rgba(0, 0, 0, 0.3);
  animation: pulse-btn 2.4s ease-in-out infinite;
}
.btn-reveal:hover { background: rgba(0, 85, 255, 0.34); transform: scale(1.04); box-shadow: 0 10px 40px rgba(0, 85, 255, 0.35); }
@keyframes pulse-btn { 0%, 100% { box-shadow: 0 10px 30px rgba(0, 0, 0, 0.3), 0 0 0 0 rgba(0, 85, 255, 0.5); } 50% { box-shadow: 0 10px 30px rgba(0, 0, 0, 0.3), 0 0 0 12px rgba(0, 85, 255, 0); } }

/* Revelação escalonada dos cards (efeito "conteúdo") */
.results-content.revealed .sim-result-card { animation: cardIn 0.55s cubic-bezier(0.25, 1, 0.5, 1) backwards; }
.results-content.revealed .sim-result-card:nth-child(1) { animation-delay: 0.05s; }
.results-content.revealed .sim-result-card:nth-child(2) { animation-delay: 0.15s; }
.results-content.revealed .sim-result-card:nth-child(3) { animation-delay: 0.25s; }
.results-content.revealed .sim-result-card:nth-child(4) { animation-delay: 0.35s; }
.results-content.revealed .sim-result-card:nth-child(5) { animation-delay: 0.45s; }
@keyframes cardIn { from { opacity: 0; transform: translateY(16px) scale(0.97); } to { opacity: 1; transform: none; } }

/* Brilho que varre o card de Lucro ao revelar */
.sim-result-card.card-highlight::after {
  content: ''; position: absolute; inset: 0; pointer-events: none;
  background: linear-gradient(120deg, transparent 30%, rgba(255, 255, 255, 0.28) 50%, transparent 70%);
  transform: translateX(-130%);
}
.results-content.revealed .card-highlight::after { animation: shine 1.1s ease 0.6s; }
@keyframes shine { to { transform: translateX(130%); } }

/* CTA pós-revelação */
.cta-container { margin-top: 22px; height: 0; overflow: visible; display: flex; flex-direction: column; gap: 12px; }
.cta-container.visible { height: auto; }
.btn-share {
  width: 100%; background: transparent; color: #fff;
  border: 1px solid rgba(0, 85, 255, 0.5); padding: 15px;
  font-size: 1rem; font-weight: 600; border-radius: 16px; cursor: pointer;
  display: flex; align-items: center; justify-content: center; gap: 10px;
  transition: all 0.25s ease; opacity: 0; transform: translateY(20px);
}
.cta-container.visible .btn-share { opacity: 1; transform: translateY(0); transition-delay: 0.05s; }
.btn-share:hover { background: rgba(0, 85, 255, 0.15); box-shadow: 0 0 20px rgba(0, 85, 255, 0.3); }
.btn-cta {
  width: 100%; background: var(--accent-blue); color: #fff; text-decoration: none;
  padding: 20px; font-size: 1.1rem; font-weight: 700; text-align: center;
  border-radius: 16px; display: inline-block; border: none; cursor: pointer;
  box-shadow: 0 10px 30px rgba(0, 85, 255, 0.35);
  opacity: 0; transform: translateY(20px); transition: all 0.4s ease;
}
.cta-container.visible .btn-cta { opacity: 1; transform: translateY(0); }
.btn-cta:hover { background: var(--accent-hover); transform: translateY(-2px); }
.disclaimer { text-align: center; font-size: 0.75rem; color: var(--text-muted); margin-top: 18px; }

/* =========================================================================
   MODAL (lead form)
   ========================================================================= */
.modal-backdrop {
  position: fixed; inset: 0; width: 100%; height: 100%;
  background: rgba(0, 0, 0, 0.7); backdrop-filter: blur(10px);
  z-index: 1000; display: flex; justify-content: center; align-items: center;
  opacity: 0; visibility: hidden; transition: opacity 0.3s ease;
}
.modal-backdrop.open { opacity: 1; visibility: visible; }
.modal-content {
  background: #07070f; border: 1px solid var(--border-glass);
  padding: 40px; border-radius: 24px; width: 90%; max-width: 500px;
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.8); position: relative;
  transform: translateY(20px); transition: transform 0.3s ease;
}
.modal-backdrop.open .modal-content { transform: translateY(0); }
.close-modal { position: absolute; top: 18px; right: 20px; background: none; border: none; color: #666; font-size: 26px; cursor: pointer; line-height: 1; }
.close-modal:hover { color: #fff; }
.modal-title { text-align: center; font-family: var(--font-title); font-size: 2rem; font-weight: 400; color: #fff; margin-bottom: 26px; letter-spacing: 1px; }
.form-group { margin-bottom: 18px; }
.form-input {
  width: 100%; background: rgba(255, 255, 255, 0.05); border: 1px solid rgba(255, 255, 255, 0.1);
  padding: 15px; border-radius: 10px; color: #fff; font-family: var(--font-text);
  font-size: 1rem; outline: none; transition: border-color 0.3s;
}
.form-input:focus { border-color: var(--accent-blue); }
.form-input::placeholder { color: #666; }
.form-input option { color: #000; }
.btn-submit {
  width: 100%; background: var(--accent-blue); color: #fff; padding: 18px;
  font-size: 1.1rem; font-weight: 700; border: none; border-radius: 12px;
  cursor: pointer; transition: background 0.3s; margin-top: 8px;
}
.btn-submit:hover { background: var(--accent-hover); }
.btn-submit:disabled { background: #333; cursor: not-allowed; }

/* =========================================================================
   CONFETE (revelação)
   ========================================================================= */
.confetti-layer { position: fixed; inset: 0; pointer-events: none; z-index: 1500; overflow: hidden; }
.confetti-piece { position: absolute; top: -10px; width: 9px; height: 14px; opacity: 0.9; will-change: transform; animation: confetti-fall linear forwards; }
@keyframes confetti-fall { to { transform: translateY(105vh) rotate(720deg); opacity: 0.6; } }

@media (prefers-reduced-motion: reduce) {
  .btn-reveal { animation: none; }
  .confetti-piece { display: none; }
}

@media (max-width: 850px) {
  .calculator-grid { grid-template-columns: 1fr; gap: 45px; }
  .sim-box { padding: 30px 20px; border-radius: 24px; }
  .modal-content { padding: 30px 20px; }
}
