/* Cookie consent compacto — evita solape con Pipedrive (abajo-derecha) */
.orsan-cc[hidden],
.orsan-cc-reopen[hidden] {
  display: none !important;
}

.orsan-cc {
  position: fixed;
  left: 16px;
  right: auto;
  bottom: calc(16px + env(safe-area-inset-bottom, 0px));
  z-index: 99990;
  width: min(360px, calc(100vw - 100px));
  max-width: calc(100vw - 100px);
  padding: 0;
  background: transparent;
  pointer-events: none;
}

.orsan-cc:not([hidden]) {
  pointer-events: auto;
}

.orsan-cc__panel {
  width: 100%;
  margin: 0;
  background: #fff;
  color: #2e2e2e;
  border: 1px solid rgba(37, 88, 163, 0.16);
  border-radius: 14px;
  box-shadow: 0 10px 28px rgba(46, 46, 46, 0.16);
  padding: 14px 14px 12px;
}

.orsan-cc__title {
  margin: 0 0 6px;
  font-family: 'bold-cond', 'Arial Narrow', Arial, sans-serif;
  font-size: 1rem;
  text-transform: uppercase;
  color: #2558a3;
  letter-spacing: 0.02em;
}

.orsan-cc__text,
.orsan-cc__prefs-intro {
  margin: 0 0 12px;
  font-size: 0.82rem;
  line-height: 1.4;
  color: #55575b;
}

.orsan-cc__text a {
  color: #0055b8;
  text-decoration: underline;
}

.orsan-cc__actions {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  align-items: center;
}

.orsan-cc__btn {
  appearance: none;
  border: 1px solid transparent;
  border-radius: 18px;
  min-height: 36px;
  padding: 7px 14px;
  font-family: 'medium-cond', 'Arial Narrow', Arial, sans-serif;
  font-size: 0.8rem;
  text-transform: uppercase;
  cursor: pointer;
  line-height: 1.1;
}

.orsan-cc__btn--primary {
  background: #0055b8;
  color: #fff;
}

.orsan-cc__btn--primary:hover,
.orsan-cc__btn--primary:focus {
  background: #004799;
}

.orsan-cc__btn--ghost {
  background: #fff;
  color: #2e2e2e;
  border-color: #d5dbe3;
}

.orsan-cc__btn--ghost:hover,
.orsan-cc__btn--ghost:focus {
  border-color: #2558a3;
  color: #2558a3;
}

.orsan-cc__btn--link {
  background: transparent;
  color: #2558a3;
  border: 0;
  min-height: auto;
  padding: 6px 4px;
  text-decoration: underline;
}

.orsan-cc__cats {
  list-style: none;
  margin: 0 0 12px;
  padding: 0;
  display: grid;
  gap: 8px;
}

.orsan-cc__cat-label {
  display: flex;
  gap: 10px;
  align-items: flex-start;
  padding: 8px 10px;
  border: 1px solid #e4e8ec;
  border-radius: 10px;
  cursor: pointer;
  background: #f7f9fb;
}

.orsan-cc__cat-label input {
  margin-top: 2px;
  accent-color: #0055b8;
}

.orsan-cc__cat-label strong {
  display: block;
  font-family: 'medium-cond', 'Arial Narrow', Arial, sans-serif;
  text-transform: uppercase;
  font-size: 0.78rem;
  color: #2e2e2e;
}

.orsan-cc__cat-label small {
  display: block;
  margin-top: 2px;
  color: #696b6f;
  font-size: 0.72rem;
  line-height: 1.3;
}

.orsan-cc-reopen {
  position: fixed;
  left: 16px;
  bottom: calc(16px + env(safe-area-inset-bottom, 0px));
  z-index: 99990;
  appearance: none;
  border: 0;
  border-radius: 18px;
  background: #4c5866;
  color: #fff;
  font-family: 'medium-cond', 'Arial Narrow', Arial, sans-serif;
  font-size: 11px;
  text-transform: uppercase;
  padding: 8px 12px;
  cursor: pointer;
  box-shadow: 0 4px 12px rgba(46, 46, 46, 0.2);
}

.orsan-cc-reopen:hover,
.orsan-cc-reopen:focus {
  background: #3d4652;
}

/* Separar Leadbooster/Pipedrive del banner (ellos suelen ir abajo-derecha) */
body:has(#orsan-cookie-consent:not([hidden])) #LeadboosterContainer,
body:has(#orsan-cookie-consent:not([hidden])) .LeadboosterContainer,
body:has(#orsan-cookie-consent:not([hidden])) [id*="Leadbooster"],
body:has(#orsan-cookie-consent:not([hidden])) [class*="Leadbooster"],
body:has(#orsan-cookie-consent:not([hidden])) iframe[src*="pipedrive"],
body:has(#orsan-cookie-consent:not([hidden])) iframe[src*="leadbooster"] {
  bottom: 12px !important;
  right: 12px !important;
  left: auto !important;
  transform: none !important;
}

@media (max-width: 767.98px) {
  .orsan-cc {
    left: 10px;
    bottom: calc(78px + env(safe-area-inset-bottom, 0px)); /* deja espacio al chat Pipedrive */
    width: calc(100vw - 20px);
    max-width: calc(100vw - 20px);
  }

  .orsan-cc-reopen {
    left: 10px;
    bottom: calc(78px + env(safe-area-inset-bottom, 0px));
  }

  body.orsan-menu-open .orsan-cc,
  body.orsan-menu-open .orsan-cc-reopen {
    opacity: 0;
    pointer-events: none;
  }
}
