/* =====================================================================
   Corema Arquitectura — Barra legal de footer + Aviso de Cookies
   Fichero independiente para no tocar el theme original (nexus.css).
   ===================================================================== */

/* --- Fila legal dentro del footer oscuro, presente en todas las páginas --- */
.legal-bar-row {
  border-top: 1px solid rgba(255, 255, 255, 0.12);
  margin-top: 18px;
  padding-top: 16px;
  text-align: center;
}
.legal-bar-links {
  margin: 0 0 8px;
}
.legal-bar-links li {
  border-right: 1px solid rgba(255, 255, 255, 0.15);
  padding: 0 12px;
  line-height: 1;
}
.legal-bar-links li:last-child {
  border-right: none;
  padding-right: 0;
}
.legal-bar-links a {
  color: rgba(255, 255, 255, 0.55);
  font-size: 12px;
  text-transform: uppercase;
  letter-spacing: .03em;
}
.legal-bar-links a:hover,
.legal-bar-links a:focus {
  color: #ffffff;
  text-decoration: underline;
}
.btn-configurar-cookies {
  background: transparent;
  border: 1px solid rgba(255, 255, 255, 0.3);
  color: rgba(255, 255, 255, 0.75);
  font-size: 12px;
  text-transform: uppercase;
  letter-spacing: .03em;
  padding: 3px 12px;
  border-radius: 3px;
  cursor: pointer;
  transition: all .15s ease-in-out;
}
.btn-configurar-cookies:hover,
.btn-configurar-cookies:focus {
  border-color: #33747a;
  color: #ffffff;
  background: rgba(51, 116, 122, 0.35);
  outline: none;
}
.legal-bar-copy {
  font-size: 11px;
  color: rgba(255, 255, 255, 0.35);
  margin: 0;
}

/* --- Banner de cookies (primera capa) --- */
#corema-cookie-banner {
  position: fixed;
  left: 0;
  right: 0;
  bottom: 0;
  z-index: 10000;
  background: rgba(15, 15, 15, 0.97);
  color: #eee;
  padding: 16px 20px;
  box-shadow: 0 -2px 12px rgba(0, 0, 0, 0.35);
  font-size: 13px;
  line-height: 1.6;
  display: none;
}
#corema-cookie-banner.is-visible { display: block; }
#corema-cookie-banner .cc-inner {
  max-width: 1080px;
  margin: 0 auto;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
}
#corema-cookie-banner .cc-text { flex: 1 1 420px; margin: 0; }
#corema-cookie-banner .cc-text a { color: #7fc6cc; text-decoration: underline; }
#corema-cookie-banner .cc-actions {
  flex: 0 0 auto;
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
}
#corema-cookie-banner button {
  border: 1px solid rgba(255, 255, 255, 0.4);
  background: transparent;
  color: #fff;
  padding: 8px 16px;
  font-size: 12px;
  text-transform: uppercase;
  letter-spacing: .03em;
  border-radius: 3px;
  cursor: pointer;
  white-space: nowrap;
}
#corema-cookie-banner .cc-accept {
  background: #33747a;
  border-color: #33747a;
}
#corema-cookie-banner .cc-accept:hover { background: #285d62; }
#corema-cookie-banner button:hover { border-color: #fff; }

/* --- Modal de configuración (segunda capa) --- */
#corema-cookie-modal {
  position: fixed;
  inset: 0;
  z-index: 10001;
  display: none;
  align-items: center;
  justify-content: center;
  background: rgba(0, 0, 0, 0.6);
  padding: 20px;
}
#corema-cookie-modal.is-visible { display: flex; }
#corema-cookie-modal .cc-modal-box {
  background: #fff;
  color: #444;
  max-width: 560px;
  width: 100%;
  max-height: 85vh;
  overflow-y: auto;
  border-radius: 4px;
  padding: 28px 30px;
}
#corema-cookie-modal h3 {
  margin-top: 0;
  color: #222;
  font-size: 20px;
}
#corema-cookie-modal .cc-cat {
  border-top: 1px solid #e5e5e5;
  padding: 14px 0;
}
#corema-cookie-modal .cc-cat-head {
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-weight: bold;
  color: #222;
}
#corema-cookie-modal .cc-cat p {
  font-size: 13px;
  margin: 6px 0 0;
}
#corema-cookie-modal .cc-modal-actions {
  margin-top: 20px;
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
}
#corema-cookie-modal .cc-modal-actions button {
  flex: 1 1 auto;
  padding: 10px 14px;
  border-radius: 3px;
  border: 1px solid #33747a;
  background: #fff;
  color: #33747a;
  cursor: pointer;
  font-size: 13px;
}
#corema-cookie-modal .cc-modal-actions .cc-save {
  background: #33747a;
  color: #fff;
}
#corema-cookie-modal .cc-modal-actions button:hover { opacity: .85; }
#corema-cookie-modal .cc-close {
  position: absolute;
  top: 14px;
  right: 18px;
  background: none;
  border: none;
  font-size: 20px;
  color: #999;
  cursor: pointer;
}
#corema-cookie-modal .cc-modal-box { position: relative; }
.cc-switch { position: relative; width: 40px; height: 22px; flex: none; }
.cc-switch input { opacity: 0; width: 0; height: 0; }
.cc-switch .cc-slider {
  position: absolute; inset: 0; background: #ccc; border-radius: 22px; cursor: pointer; transition: .2s;
}
.cc-switch .cc-slider:before {
  content: ""; position: absolute; width: 16px; height: 16px; left: 3px; top: 3px;
  background: #fff; border-radius: 50%; transition: .2s;
}
.cc-switch input:checked + .cc-slider { background: #33747a; }
.cc-switch input:checked + .cc-slider:before { transform: translateX(18px); }
.cc-switch input:disabled + .cc-slider { background: #9bbcbe; cursor: not-allowed; }

/* --- Placeholder del mapa de Google (hasta que se acepten cookies de terceros) --- */
.gmap-placeholder {
  display: none;
  background: #eef1f1;
  border: 1px dashed #c7d2d2;
  color: #555;
  font-size: 12px;
  padding: 14px;
  text-align: center;
  border-radius: 3px;
}
.gmap-placeholder a { color: #33747a; font-weight: bold; }
.gmap-placeholder button {
  display: block;
  margin: 8px auto 0;
  background: #33747a;
  color: #fff;
  border: none;
  padding: 6px 14px;
  border-radius: 3px;
  font-size: 12px;
  cursor: pointer;
}

@media (max-width: 600px) {
  #corema-cookie-banner .cc-actions { width: 100%; }
  #corema-cookie-banner button { flex: 1 1 auto; }
}
