/* ============================================================
   cookie-consent.css - banner LGPD de cookies (FEAT-36)
   carregado via assets/js/cookie-consent.js em todas as páginas
   ============================================================ */

#cc-banner, #cc-modal {
  font-family: 'Montserrat', system-ui, sans-serif;
  color: #2c4150;
  box-sizing: border-box;
}
#cc-banner *, #cc-modal *, #cc-modal *::before, #cc-modal *::after { box-sizing: border-box; }

/* ─── Banner inferior fixo ─────────────────────────────────── */
#cc-banner {
  position: fixed;
  bottom: 0; left: 0; right: 0;
  z-index: 99980;
  background: #fff;
  border-top: 3px solid var(--ci, #01a9ce);
  box-shadow: 0 -8px 28px rgba(30, 65, 82, .18);
  padding: 18px 24px;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 18px;
  animation: ccSlideUp .35s ease-out;
}

@keyframes ccSlideUp {
  from { transform: translateY(100%); opacity: 0; }
  to   { transform: translateY(0);    opacity: 1; }
}

#cc-banner .cc-text {
  flex: 1 1 360px;
  font-size: 13.5px;
  line-height: 1.55;
}
#cc-banner .cc-text strong {
  color: var(--az, #1e4152);
  font-weight: 600;
}
#cc-banner .cc-text a {
  color: var(--ci, #01a9ce);
  text-decoration: underline;
}

#cc-banner .cc-actions {
  display: flex;
  gap: 10px;
  flex: 0 0 auto;
  flex-wrap: wrap;
}

.cc-btn {
  font-family: inherit;
  font-size: 13.5px;
  font-weight: 600;
  padding: 10px 20px;
  border-radius: 6px;
  cursor: pointer;
  transition: background .2s, color .2s, border-color .2s;
  white-space: nowrap;
  border: 2px solid transparent;
}
.cc-btn-primary {
  background: var(--ci, #01a9ce);
  color: #fff;
  border-color: var(--ci, #01a9ce);
}
.cc-btn-primary:hover { background: var(--az, #1e4152); border-color: var(--az, #1e4152); }

.cc-btn-outline {
  background: transparent;
  color: var(--az, #1e4152);
  border-color: var(--bd, #d6e0e6);
}
.cc-btn-outline:hover { border-color: var(--az, #1e4152); }

.cc-btn-link {
  background: transparent;
  color: var(--ci, #01a9ce);
  border: none;
  text-decoration: underline;
  padding: 10px 8px;
}
.cc-btn-link:hover { color: var(--az, #1e4152); }

/* ─── Modal de personalização ──────────────────────────────── */
#cc-modal {
  position: fixed;
  inset: 0;
  z-index: 99990;
  background: rgba(30, 65, 82, .55);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 16px;
  animation: ccFadeIn .25s ease-out;
}
@keyframes ccFadeIn {
  from { opacity: 0; }
  to   { opacity: 1; }
}

#cc-modal .cc-dialog {
  background: #fff;
  border-radius: 12px;
  box-shadow: 0 20px 80px rgba(30, 65, 82, .35);
  width: 100%;
  max-width: 560px;
  max-height: 90vh;
  overflow-y: auto;
  padding: 28px;
}

#cc-modal h2 {
  margin: 0 0 14px;
  color: var(--az, #1e4152);
  font-size: 20px;
  font-weight: 600;
}
#cc-modal p {
  font-size: 13.5px;
  line-height: 1.55;
  color: #4d5b65;
  margin: 0 0 18px;
}

.cc-cat {
  display: flex;
  align-items: flex-start;
  gap: 14px;
  padding: 14px;
  border: 1px solid var(--bd, #d6e0e6);
  border-radius: 8px;
  margin-bottom: 10px;
  background: #f7f9fa;
}
.cc-cat-info { flex: 1 1 auto; }
.cc-cat-name {
  display: block;
  font-weight: 600;
  color: var(--az, #1e4152);
  font-size: 14px;
  margin-bottom: 4px;
}
.cc-cat-desc {
  font-size: 12.5px;
  line-height: 1.5;
  color: #6d7073;
}

.cc-toggle {
  flex: 0 0 auto;
  position: relative;
  width: 44px;
  height: 24px;
  display: inline-block;
}
.cc-toggle input { opacity: 0; width: 0; height: 0; position: absolute; }
.cc-toggle .cc-slider {
  position: absolute;
  inset: 0;
  background: #c9d3d9;
  border-radius: 24px;
  cursor: pointer;
  transition: background .2s;
}
.cc-toggle .cc-slider::before {
  content: '';
  position: absolute;
  top: 3px; left: 3px;
  width: 18px; height: 18px;
  background: #fff;
  border-radius: 50%;
  transition: transform .2s;
}
.cc-toggle input:checked + .cc-slider { background: var(--ci, #01a9ce); }
.cc-toggle input:checked + .cc-slider::before { transform: translateX(20px); }
.cc-toggle input:disabled + .cc-slider { cursor: not-allowed; opacity: .65; }

.cc-modal-actions {
  display: flex;
  justify-content: flex-end;
  gap: 10px;
  margin-top: 22px;
  flex-wrap: wrap;
}

/* ─── Mobile ────────────────────────────────────────────────── */
@media (max-width: 600px) {
  #cc-banner {
    flex-direction: column;
    align-items: stretch;
    padding: 16px;
    gap: 14px;
  }
  #cc-banner .cc-actions { justify-content: stretch; }
  .cc-btn { flex: 1 1 auto; min-height: 44px; }

  #cc-modal .cc-dialog { padding: 20px; max-height: 95vh; }
  .cc-modal-actions { flex-direction: column-reverse; }
  .cc-modal-actions .cc-btn { width: 100%; }
}

/* ─── Não imprimir banner em modo @print ───────────────────── */
@media print {
  #cc-banner, #cc-modal { display: none !important; }
}

/* ─── Botão "reabrir painel" embutido em texto corrido ─────── */
.cc-reopen {
  background: none;
  border: none;
  color: var(--ci, #01a9ce);
  text-decoration: underline;
  cursor: pointer;
  font: inherit;
  padding: 0;
}
.cc-reopen:hover { color: var(--az, #1e4152); }
