/* Badge flotante de validación CCS (Cámara de Comercio de Santiago).
   Replicado de https://compreoro.com/SelloCCS/socioccs.css */
.swal2-popup-custom {
  font-size: 14px !important;
}
.swal2-title-custom {
  font-size: 10px !important;
  font-weight: 600;
}
.swal2-html-container-custom {
  font-size: 14px !important;
  font-weight: 400;
}

#ccs-modal {
  display: none;
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.65);
  z-index: 99998;
  align-items: flex-start;
  justify-content: center;
  overflow-y: auto;
  padding: 2rem 1rem;
  box-sizing: border-box;
}

.ccs-box {
  position: relative;
  background: #fff;
  border-radius: 14px;
  padding: 2rem 1.5rem 1.5rem;
  width: 90%;
  max-width: 720px;
  box-shadow: 0 10px 40px rgba(0, 0, 0, 0.45);
  box-sizing: border-box;
}

#ccs-cerrar {
  position: absolute;
  top: 0.75rem;
  right: 0.75rem;
  background: none;
  border: none;
  font-size: 1.3rem;
  line-height: 1;
  cursor: pointer;
  color: #555;
  padding: 0.25rem 0.5rem;
  border-radius: 4px;
  transition: background 0.2s, color 0.2s;
}
#ccs-cerrar:hover {
  background: #f0f0f0;
  color: #000;
}

.titulo-certificado {
  margin-bottom: 1rem;
  font-family: 'Inter', 'Segoe UI', sans-serif;
  font-size: 1.25rem;
  color: #333;
  line-height: 1.6;
  text-align: center;
}

.contenedor-descargar {
  text-align: center;
  margin-bottom: 0.75rem;
}

#ccs-modal .btn {
  display: inline-block;
  font-family: 'Inter', 'Segoe UI', sans-serif;
  font-weight: 600;
  text-align: center;
  cursor: pointer;
  border: none;
  border-radius: 10px;
  background-color: #003c88;
  color: #fff;
  transition: background 0.2s ease;
}
#ccs-modal .btn--sm {
  padding: 0.85rem 3rem;
  font-size: 1.15rem;
}
#ccs-modal .btn:hover {
  background-color: #002a63;
}

#ccs-modal .spinner-overlay {
  position: absolute;
  inset: 0;
  background: rgba(255, 255, 255, 0.75);
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 14px;
  z-index: 10;
}
#ccs-modal .spinner-overlay.d-none { display: none; }

.ccs-spinner {
  width: 2.5rem;
  height: 2.5rem;
  border: 4px solid #003c88;
  border-right-color: transparent;
  border-radius: 50%;
  animation: spinner-border 0.75s linear infinite;
}

#contenedorPDF {
  display: none;
  margin-top: 10px;
  width: 90%;
  overflow: auto;
  text-align: center;
  border: 1px solid #ccc;
  padding: 10px;
  background-color: #f9f9f9;
  box-sizing: border-box;
}
#pdf-render {
  width: 85% !important;
  height: auto !important;
  display: block;
  margin: 0 auto;
  border: 1px solid #ccc;
}

.custom-tooltip {
  position: absolute;
  z-index: 99999;
  background: rgba(0, 60, 136, 0.85);
  color: white;
  padding: 14px 20px;
  border-radius: 12px;
  max-width: 330px;
  text-align: center;
  box-shadow: 0 6px 20px rgba(0,0,0,0.45);
  font-size: 15px;
  pointer-events: none;
  transition: opacity 0.2s ease;
}
.custom-tooltip-inner {
  font-family: 'Inter', sans-serif;
  line-height: 1.5;
}

.tooltip-inner {
  background-color: rgba(0, 60, 136, 0.85);
  color: #fff;
  font-family: 'Inter', 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
  font-weight: 500;
  font-size: 15px;
  letter-spacing: 0.02em;
  line-height: 1.5;
  padding: 14px 20px;
  border-radius: 12px;
  max-width: 330px;
  text-align: center;
  box-shadow: 0 6px 20px rgba(0, 0, 0, 0.45);
}
.tooltip.bs-tooltip-end .tooltip-arrow::before { border-width: 10px; border-right-color: rgba(0, 60, 136, 0.85); }
.tooltip.bs-tooltip-top .tooltip-arrow::before { border-width: 10px; border-top-color: rgba(0, 60, 136, 0.85); }
.tooltip.bs-tooltip-bottom .tooltip-arrow::before { border-width: 10px; border-bottom-color: rgba(0, 60, 136, 0.85); }
.tooltip.bs-tooltip-start .tooltip-arrow::before { border-width: 10px; border-left-color: rgba(0, 60, 136, 0.85); }
.tooltip.bs-tooltip-end { margin-left: 8px; }

.row_ccs {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  width: 70%;
  flex-shrink: 0;
  gap: 0.5rem;
  min-height: 120px;
}

.logo-container {
  position: fixed;
  bottom: 20px;
  left: 20px;
  z-index: 9999;
  cursor: pointer;
  width: 74px;
  height: 74px;
  border-radius: 50%;
  background: #ffffff;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 4px 14px rgba(0, 0, 0, 0.35);
  overflow: hidden;
}
.logo-container img {
  width: 70px;
  height: auto;
  display: block;
  transition: transform 0.2s ease;
}
.logo-container img:hover { transform: scale(1.05); }

.spinner-wrapper {
  position: absolute;
  bottom: 0;
  right: -10px;
  width: 1.5rem;
  height: 1.5rem;
  display: flex;
  align-items: center;
  justify-content: center;
}
#openPdf .spinner-border {
  width: 1.5rem;
  height: 1.5rem;
  border: 0.25em solid currentColor;
  border-right-color: transparent;
  border-radius: 50%;
  animation: spinner-border 0.75s linear infinite;
  display: none;
  box-sizing: border-box;
}
@keyframes spinner-border { to { transform: rotate(360deg); } }

#openPdf .text-primary { color: #0d6efd !important; }

#ccs-modal .visually-hidden {
  position: absolute !important;
  width: 1px !important;
  height: 1px !important;
  padding: 0 !important;
  margin: -1px !important;
  overflow: hidden !important;
  clip: rect(0,0,0,0) !important;
  border: 0 !important;
}