body {
  background: linear-gradient(to bottom, #1a001f, #000000);
  color: #ffffff;
}

h1,
h2,
p,
th,
td {
  color: #ffffff;
}

table {
  background-color: rgba(255, 255, 255, 0.05);
}

th {
  background-color: #2a003f;
}

td {
  background-color: rgba(255, 255, 255, 0.03);
}

a {
  color: #d9b3ff;
}

input.form-control,
select.form-select {
  background-color: #2a003f !important;
  color: #fff !important;
  border: 1px solid #5e2d79;
}
.animated-result {
  display: inline-block;
  min-width: 120px;
  font-variant-numeric: tabular-nums;
  transition: color 0.3s ease-in-out;
}
::placeholder {
  color: #ffffff !important;
  opacity: 0.7;
}
:root {
  --bs-primary: #5e2d79;
  --bs-primary-rgb: 94, 45, 121;
}

.btn-primary {
  background-color: var(--bs-primary) !important;
  border-color: var(--bs-primary) !important;
}

.btn-primary:hover,
.btn-primary:focus {
  background-color: #4a1f63 !important;
  border-color: #4a1f63 !important;
}

.badge {
  font-size: 0.85rem;
  padding: 0.4em 0.6em;
}
footer a:hover {
  text-decoration: underline;
  color: #a57cff;
}

html {
  scroll-behavior: smooth;
}
/* Contenedor flotante fijo a la derecha (desktop) */
.cta-float {
  position: fixed;
  top: 35%;
  right: 24px;
  width: 300px;
  padding: 16px;
  border-radius: 16px;
  background: rgba(0, 0, 0, 0.55);
  backdrop-filter: blur(6px);
  box-shadow: 0 6px 24px rgba(0, 0, 0, 0.5);
  z-index: 1000;
  opacity: 1;
  transform: translateX(0);
  transition: opacity 0.25s ease, transform 0.25s ease;
}

.cta-float.hide {
  opacity: 0;
  transform: translateX(20px);
  pointer-events: none;
}

.cta-sub {
  color: #ffffff;
  opacity: 0.85;
}

/* Botón degradado violeta–negro */
.cta-simulador {
  display: inline-block;
  padding: 0.75em 1.2em;
  font-size: 1rem;
  font-weight: 700;
  color: white;
  text-decoration: none;
  border-radius: 50px;
  background: linear-gradient(90deg, #7e57c2, #000000);
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.5);
  transition: transform 0.3s ease, box-shadow 0.3s ease;
  animation: pulseGradient 2s infinite;
}

.cta-simulador:hover {
  transform: scale(1.06);
  box-shadow: 0 6px 18px rgba(126, 87, 194, 0.8);
}

@keyframes pulseGradient {
  0%,
  100% {
    box-shadow: 0 0 0 rgba(126, 87, 194, 0.7);
  }
  50% {
    box-shadow: 0 0 20px rgba(126, 87, 194, 0.8);
  }
}

/* Accesibilidad: respeta reducción de movimiento */
@media (prefers-reduced-motion: reduce) {
  .cta-simulador {
    animation: none;
  }
}
.sim-block {
  background: rgba(0, 0, 0, 0.65);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 14px;
  padding: 1.25rem;
  box-shadow: 0 6px 20px rgba(0, 0, 0, 0.35);
  color: #fff;
}

#scrollToTopBtn {
  position: fixed;
  bottom: 20px;
  right: 20px;
  width: 48px;
  height: 48px;
  border-radius: 50%;
  background-color: #7e57c2;
  color: white;
  border: none;
  box-shadow: 0 4px 8px rgba(0, 0, 0, 0.4);
  font-size: 1.25rem;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.4s, transform 0.4s;
  z-index: 999;
}
#scrollToTopBtn.visible {
  opacity: 1;
  pointer-events: auto;
}
#scrollToTopBtn:hover {
  background-color: #9575cd;
  transform: scale(1.1);
}

/* Botón primary ya sobreescrito a violeta en tu setup */
.animated-cta {
  transition: all 0.25s ease-in-out;
  transform: scale(1);
}
.animated-cta:hover {
  transform: scale(1.03);
  box-shadow: 0 0 10px rgba(94, 45, 121, 0.6);
}
.animated-cta:active {
  transform: scale(0.97);
}

.fs-6 {
  font-size: 1rem !important;
}

@media (max-width: 768px) {
  /* Tamaños de fuente responsivos (imitando Bootstrap) */
  .fs-md-5 {
    font-size: 0.8rem !important; /* igual que fs-5 */
  }
}

@media (max-width: 540px) {
  /* breakpoint lg */
  .fs-lg-4 {
    font-size: 0.6rem !important; /* igual que fs-4 */
  }
}
.share-wrap {
  position: relative;
  display: inline-block;
}
.share-btn {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.6rem 0.9rem;
  border: 0;
  border-radius: 999px;
  background: #1f1f1f;
  color: #fff;
  cursor: pointer;
}
.share-btn svg {
  width: 18px;
  height: 18px;
}
.share-menu {
  position: absolute;
  right: 0;
  top: 110%;
  min-width: 260px;
  background: #111;
  border: 1px solid #2a2a2a;
  border-radius: 12px;
  padding: 0.5rem;
  display: none;
  z-index: 999;
}
.share-menu.active {
  display: block;
}
.share-item {
  display: flex;
  align-items: center;
  gap: 0.6rem;
  width: 100%;
  padding: 0.55rem 0.7rem;
  border-radius: 10px;
  color: #eaeaea;
  background: transparent;
  border: 0;
  text-align: left;
  cursor: pointer;
  text-decoration: none;
}
.share-item:hover {
  background: #1b1b1b;
}
.share-item svg {
  width: 18px;
  height: 18px;
  flex: 0 0 18px;
}
.share-divider {
  height: 1px;
  background: #2a2a2a;
  margin: 0.35rem 0;
}
.share-toast {
  position: fixed;
  left: 50%;
  bottom: 18px;
  transform: translateX(-50%);
  background: #0f5132;
  color: #d1f7e3;
  padding: 0.55rem 0.8rem;
  border-radius: 10px;
  display: none;
}
@media (prefers-reduced-motion: no-preference) {
  .share-menu {
    animation: pop 0.12s ease-out;
  }
  @keyframes pop {
    from {
      transform: translateY(-4px);
      opacity: 0;
    }
    to {
      transform: none;
      opacity: 1;
    }
  }
}
/* FAB solo en mobile */
@media (max-width: 576px) {
  .share-fab {
    position: fixed;
    right: 16px;
    bottom: 16px;
    z-index: 1100;
    border: 0;
    border-radius: 999px;
    padding: 12px 14px;
    background: #7e57c2;
    color: #fff;
    box-shadow: 0 10px 24px rgba(0, 0, 0, 0.35);
  }
  .navbar .share-wrap {
    display: none;
  } /* ocultar botón de navbar en mobile */
}
@media (min-width: 577px) {
  #shareFab {
    display: none;
  } /* FAB solo mobile */
}
.btn-simula {
  display: none;
  background: #7e57c2;
  color: white;
  padding: 5px 20px;
  font-size: 18px;
  border-radius: 50px;
  font-weight: bold;
  text-decoration: none;
  box-shadow: 0 4px 10px rgba(0, 0, 0, 0.3);
  z-index: 999;
  float: right;
  animation: pulse 1.8s infinite;
}

.btn-simula:hover {
  background: #5e2d79; /* un poco más oscuro */
}

/* Solo mostrar en mobile */
@media (max-width: 768px) {
  .btn-simula {
    display: inline-block;
  }
  .mobile-alone {
    width: 100%;
    margin-bottom: 10px;
  }
}
@keyframes pulse {
  0% {
    transform: scale(1);
    box-shadow: 0 0 0 0 rgba(131, 0, 254, 0.7);
  }
  70% {
    transform: scale(1.05);
    box-shadow: 0 0 0 20px rgba(45, 212, 191, 0);
  }
  100% {
    transform: scale(1);
    box-shadow: 0 0 0 0 rgba(45, 212, 191, 0);
  }
}
