/* static/css/styles.css */

.navbar-brand {
  font-weight: bold;
  font-size: 1.3rem;
}

.card-title {
  font-weight: 600;
}

footer {
  background-color: #f8f9fa;
}

.hero-section {
  background: #eee;
  padding: 80px 0;
  text-align: center;
}

#tools .card-img-top {
  width: 40%;
  /* Reduce el tamaño al 50% */
  height: auto;
  /* Mantiene la proporción */
  margin: 0 auto;
  /* Centra la imagen */
  display: block;
  /* Asegura alineación */
  padding: 10px;
}



/* Contenedor que ocupa toda la ventana menos la navbar/footer (ajusta la resta a tu gusto). */
.iframe-container {
  width: 100%;
  height: calc(100vh - 120px);
  /* Ajusta 120px según tu navbar, footer, etc. */
  margin: 0;
  padding: 0;
  overflow: hidden;
  /* El contenedor no muestra scroll */
  position: relative;
}

/* El iframe llena todo el contenedor */
.iframe-container iframe {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  border: none;
  display: block;
  overflow: hidden;
  /* Sin barras de scroll dentro del propio iframe */
}

.custom-navbar {
  background-color: #1e1e1e;
}

/* Cambiar color de fondo al pasar el mouse sobre un ítem del menú desplegable */
.dropdown-menu .dropdown-item:hover,
.dropdown-menu .dropdown-item:focus {
  background-color: #1e1e1e;
  /* color más oscuro */
  color: #ffffff;
  /* texto blanco para contraste */
}


/* === DARK MODE SWITCH === */
.theme-toggle {
  display: flex;
  align-items: center;
  gap: 10px;
}

.switch {
  position: relative;
  display: inline-block;
  width: 46px;
  height: 24px;
}

.switch input {
  opacity: 0;
  width: 0;
  height: 0;
}

.slider {
  position: absolute;
  cursor: pointer;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background-color: #ccc;
  transition: .4s;
  border-radius: 24px;
}

.slider::before {
  position: absolute;
  content: "";
  height: 18px;
  width: 18px;
  left: 3px;
  bottom: 3px;
  background-color: white;
  transition: .4s;
  border-radius: 50%;
}

input:checked+.slider {
  background-color: #007bff;
}

input:checked+.slider::before {
  transform: translateX(22px);
}

#themeToggleLabel {
  font-size: 18px;
  user-select: none;
}

/* ======== GLOBAL DARK MODE ======== */
body.dark-mode {
  background-color: #252525;
  color: #e0e0e0;
}

body.dark-mode h1,
body.dark-mode h2,
body.dark-mode h3,
body.dark-mode p,
body.dark-mode .card-title {
  color: #e0e0e0;
}

body.dark-mode .navbar,
body.dark-mode footer {
  background-color: #1a1a1a;
  color: white;
}

body.dark-mode .nav-link,
body.dark-mode .navbar-brand {
  color: white !important;
}

body.dark-mode .dropdown-menu {
  background-color: #2a2a2a;
}

body.dark-mode .dropdown-menu .dropdown-item {
  color: #e0e0e0;
}

body.dark-mode .dropdown-menu .dropdown-item:hover {
  background-color: #3a3a3a;
}



/* ======== HOME DARK MODE ADAPTATIONS ======== */
body.dark-mode section.bg-light {
  background-color: #1e1e1e !important;
  color: #e0e0e0;
}

body.dark-mode section.bg-secondary {
  background-color: #2a2a2a !important;
  color: #e0e0e0;
}

body.dark-mode .card {
  background-color: #1c1c1c;
  color: #e0e0e0;
  border: 1px solid #333;
  box-shadow: 0px 4px 8px rgba(255, 255, 255, 0.05);
}

body.dark-mode .card-footer {
  background-color: #181818;
  border-top: 1px solid #333;
}

body.dark-mode .btn-outline-primary {
  color: #90caf9;
  border-color: #90caf9;
}

body.dark-mode .btn-outline-primary:hover {
  background-color: #90caf9;
  color: #000;
}

body.dark-mode section.bg-dark {
  background-color: #000 !important;
  color: white;
}

body.dark-mode .btn-light {
  background-color: #444;
  color: white;
  border: none;
}

body.dark-mode .btn-light:hover {
  background-color: #666;
}


footer {
  transition: background-color 0.3s ease, color 0.3s ease;
}

body.dark-mode footer {
  background-color: #222 !important;
  color: #f1f1f1;
}


/* Estilos para tablas en modo oscuro */
body.dark-mode table {
  background-color: #1e1e1e;
  color: #f1f1f1;
}

body.dark-mode table thead {
  background-color: #333 !important;
  color: #fff;
}

body.dark-mode table tbody tr {
  background-color: #2a2a2a;
  color: #f1f1f1;
}

body.dark-mode table tbody tr:nth-child(even) {
  background-color: #242424;
}

body.dark-mode .table-hover tbody tr:hover {
  background-color: #3a3a3a;
}

body.dark-mode .card {
  background-color: #1c1c1c;
  border-color: #333;
}

body.dark-mode .card-header {
  background-color: #2b2b2b !important;
  color: #fff;
}

body.dark-mode .text-dark {
  color: #f1f1f1 !important;
}

body.dark-mode .bg-light {
  background-color: #333 !important;
}

#flash-container {
  transition: all 0.4s ease;
  pointer-events: none;
}

#flash-container .alert {
  transition: all 0.4s ease;
  pointer-events: auto;
  box-shadow: 0 4px 16px rgba(0, 0, 0, 0.25);
}


/* Separador visible en modo oscuro del dropdown */
body.dark-mode .dropdown-divider {
  border-top: 1px solid #555;
  /* Gris medio para buen contraste */
}

/* ==== Bordes visibles en ítems del dropdown en modo oscuro ==== */
body.dark-mode .dropdown-menu {
  border: 1px solid #444;
}

/* === FIX: Forzar texto negro para Magnificent === */
.text-always-black,
.text-always-black * {
  color: #000 !important;
}

/* Ribbon en esquina superior derecha */
.ribbon {
  width: 150px;
  height: 150px;
  overflow: hidden;
  position: absolute;
  top: -10px;
  right: -10px;
}

.ribbon span {
  position: absolute;
  display: block;
  width: 225px;
  padding: 5px 0;
  background: #0d6efd;
  /* Azul Bootstrap */
  color: #fff;
  text-align: center;
  font-weight: bold;
  transform: rotate(45deg);
  box-shadow: 0 3px 10px rgba(0, 0, 0, 0.3);
  top: 30px;
  right: -45px;
}


/* Por defecto: muestra logo Light */
.btm-logo-dark {
  display: none;
}

.btm-logo-light {
  display: inline;
}

/* Si body tiene clase dark-mode: muestra logo Dark */
body.dark-mode .btm-logo-light {
  display: none;
}

body.dark-mode .btm-logo-dark {
  display: inline;
}

.badge.bg-warning.text-dark {
  color: #000 !important;
}

  .pill-hover {
    transition: all 0.2s ease-in-out;
  }

  .pill-ahora {
    border: 2px solid #0d6efd; /* Bootstrap primary */
    color: #0d6efd;
  }

  .pill-ahora:hover {
    background-color: #0d6efd;
    color: #fff;
  }

  .pill-despues {
    border: 2px solid #343a40; /* Bootstrap dark */
    color: #343a40;
  }

  .pill-despues:hover {
    background-color: #343a40;
    color: #fff;
  }

  

  /* Indicadores debajo, estilo discreto */
#testimonials .carousel-indicators {
  position: static !important;
  margin-top: 0.25rem;
  gap: .5rem;
}
#testimonials .carousel-indicators [data-bs-target] {
  width: .8rem; height: .8rem;
  border-radius: 50%;
  background-color: var(--bs-primary);
  opacity: .3;
}
#testimonials .carousel-indicators .active { opacity: 1; }

/* Evitar saltos de altura */
#testimonials .carousel-item { min-height: 380px; }

/* Botones externos */
#testimonials .testimonials-nav .btn {
  line-height: 1;
  padding: .4rem .75rem;
}


/* Navbar cuando el usuario está logueado */
.navbar-auth {
  background: linear-gradient(90deg, #0b1f2a, #0f2e3d);
  box-shadow: 0 2px 12px rgba(0, 0, 0, 0.35);
}


.nav-tool {
  padding: 0.45rem 0.9rem;
  border-radius: 8px;
  margin-right: 0.35rem;
  font-weight: 500;
  transition: all 0.2s ease;
}

.nav-tool:hover {
  background-color: rgba(255, 255, 255, 0.12);
}

.nav-tool.active {
  background-color: rgba(255, 255, 255, 0.22);
  font-weight: 600;
}

/* ============================================================
   AGREGAR AL FINAL DE styles.css
   Fix: Modal settings — tamaño fijo + dark mode tabs/addon
============================================================ */

/* Tamaño fijo del modal para que no cambie entre tabs */
#settingsModal .modal-dialog {
  min-height: 420px;
}
#settingsModal .tab-content {
  min-height: 300px;
}

/* Nav tabs dentro del modal — dark mode */
body.dark-mode #settingsModal .nav-tabs {
  border-bottom-color: #444;
}
body.dark-mode #settingsModal .nav-tabs .nav-link {
  color: #aaa;
  border-color: transparent;
}
body.dark-mode #settingsModal .nav-tabs .nav-link:hover {
  color: #fff;
  border-color: #555 #555 transparent;
}
body.dark-mode #settingsModal .nav-tabs .nav-link.active {
  background-color: #2a2a2a;
  border-color: #444 #444 #2a2a2a;
  color: #fff;
}

/* Tab Add-ons — textos en dark mode */
body.dark-mode #tabAddon {
  background-color: #2a2a2a;
  color: #e0e0e0;
}
body.dark-mode #tabAddon h6,
body.dark-mode #tabAddon p,
body.dark-mode #tabAddon .small,
body.dark-mode #tabAddon .text-muted {
  color: #bbb !important;
}
body.dark-mode #tabAddon .row .col-6 {
  color: #ccc;
}

/* Badge $29/mes en dark mode */
body.dark-mode #tabAddon .badge.bg-secondary {
  background-color: #444 !important;
  color: #ddd;
}

/* Botón cancelar add-on en dark mode */
body.dark-mode #tabAddon .btn-outline-danger {
  color: #f88;
  border-color: #f88;
}
body.dark-mode #tabAddon .btn-outline-danger:hover {
  background-color: #c0392b;
  color: #fff;
  border-color: #c0392b;
}

/* Modal confirm cancel — dark mode */
body.dark-mode #modalConfirmCancelAddon .modal-content {
  background-color: #2a2a2a;
  color: #e0e0e0;
}
body.dark-mode #modalConfirmCancelAddon .text-muted {
  color: #999 !important;
}
/* ── Botones de idioma ──────────────────────────────────────── */
.lang-btn {
  border-radius: 6px;
  border: 2px solid transparent;
  opacity: 0.5;
  transition: all 0.2s ease;
}

.lang-btn:hover {
  opacity: 1;
  border-color: rgba(255, 255, 255, 0.3);
  background: rgba(255, 255, 255, 0.08);
}

.lang-btn-active {
  opacity: 1;
  border-color: rgba(255, 255, 255, 0.7);
  background: rgba(255, 255, 255, 0.12);
  box-shadow: 0 0 0 2px rgba(255, 255, 255, 0.15);
}