/* ==========================================
   HAITRACK - GERENCIAMENTO DE COOKIES
   ========================================== */

/* Aviso principal */

.hc-cookie-banner {
  position: fixed;
  left: 20px;
  bottom: 20px;
  z-index: 99999;

  width: min(470px, calc(100% - 40px));
  padding: 26px;

  background: linear-gradient(
    135deg,
    #071b36 0%,
    #123b65 100%
  );

  color: #ffffff;

  border: 1px solid rgba(160, 210, 245, 0.22);
  border-radius: 20px;

  box-shadow: 0 18px 50px rgba(0, 15, 40, 0.28);
}

.hc-cookie-banner h2 {
  margin: 0 0 12px;
  font-size: 21px;
  line-height: 1.3;
  font-weight: 700;
  color: #ffffff;
}

.hc-cookie-banner p {
  margin: 0 0 15px;
  font-size: 15px;
  line-height: 1.65;
  color: #d6e5f3;
}

.hc-privacy-link {
  display: inline-block;
  margin-bottom: 20px;

  font-size: 14px;
  font-weight: 600;
  color: #a5ddff;
  text-decoration: underline;
  text-underline-offset: 3px;
}

.hc-privacy-link:hover {
  color: #ffffff;
}

/* Botões */

.hc-cookie-actions,
.hc-dialog-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.hc-button {
  min-height: 44px;
  padding: 11px 16px;

  border: 1px solid transparent;
  border-radius: 10px;

  font-family: inherit;
  font-size: 14px;
  font-weight: 600;
  line-height: 1.4;

  cursor: pointer;

  transition:
    background-color 0.2s ease,
    border-color 0.2s ease;
}

.hc-button-primary {
  background: #48a9e5;
  color: #071b36;
}

.hc-button-primary:hover {
  background: #87cefa;
}

.hc-button-secondary {
  background: transparent;
  color: #ffffff;
  border-color: rgba(255, 255, 255, 0.48);
}

.hc-button-secondary:hover {
  background: rgba(255, 255, 255, 0.1);
}

.hc-button-text {
  background: transparent;
  color: #c3e7ff;
  text-decoration: underline;
}

.hc-button-text:hover {
  color: #ffffff;
}

.hc-button:focus-visible,
.hc-privacy-link:focus-visible {
  outline: 3px solid #8bd3ff;
  outline-offset: 3px;
}

/* Painel de preferências */

.hc-dialog {
  width: min(500px, calc(100% - 30px));
  max-height: 85vh;
  padding: 0;

  border: 1px solid #d9e6f1;
  border-radius: 20px;

  background: #ffffff;
  color: #102c49;

  box-shadow: 0 24px 70px rgba(0, 15, 40, 0.25);
}

.hc-dialog::backdrop {
  background: rgba(3, 15, 35, 0.72);
}

.hc-dialog-content {
  padding: 28px;
}

.hc-dialog h2 {
  margin: 0 0 16px;
  font-size: 23px;
  line-height: 1.3;
  color: #102c49;
}

.hc-option {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;

  padding: 19px 0;
  border-bottom: 1px solid #e1eaf2;
}

.hc-option strong {
  display: block;
  margin-bottom: 6px;

  font-size: 16px;
  color: #102c49;
}

.hc-option p {
  margin: 0;

  font-size: 14px;
  line-height: 1.55;
  color: #60758a;
}

.hc-option input[type="checkbox"] {
  flex: 0 0 auto;

  width: 22px;
  height: 22px;

  accent-color: #1875b5;
  cursor: pointer;
}

.hc-option input:disabled {
  cursor: not-allowed;
}

.hc-dialog-actions {
  justify-content: flex-end;
  margin-top: 24px;
}

.hc-dialog .hc-button-secondary {
  color: #244764;
  border-color: #b9ccdc;
}

.hc-dialog .hc-button-secondary:hover {
  background: #eef5fa;
}

/* Responsividade */

@media (max-width: 600px) {
  .hc-cookie-banner {
    left: 10px;
    right: 10px;
    bottom: 10px;

    width: auto;
    max-height: calc(100dvh - 20px);
    overflow-y: auto;

    padding: 20px;
    border-radius: 16px;
  }

  .hc-cookie-banner h2 {
    font-size: 19px;
  }

  .hc-cookie-banner p {
    font-size: 14px;
  }

  .hc-cookie-actions {
    flex-direction: column;
  }

  .hc-cookie-actions .hc-button {
    width: 100%;
  }

  .hc-dialog-content {
    padding: 21px;
  }

  .hc-dialog-actions {
    flex-direction: column;
  }

  .hc-dialog-actions .hc-button {
    width: 100%;
  }
}

@media (prefers-reduced-motion: reduce) {
  .hc-button {
    transition: none;
  }
}