/* ============================================================================
   LEXRENTIA ASSETS · cookie-consent.css
   Componente autónomo. No depende de style.css ni de legal.css: todas las
   variables se declaran con prefijo --cc- para poder reutilizarlo tal cual
   en la landing, en el Backoffice, en el Owner Portal y en el Guest Portal.
   Sobrescribe las variables en :root si necesitas otra paleta.
   ========================================================================== */

:root{
  --cc-navy:#050B18;
  --cc-navy-card:#0A1428;
  --cc-navy-deep:#02060F;
  --cc-gold:#C5A059;
  --cc-gold-dim:#8A7340;
  --cc-silk:#F4F4F4;
  --cc-text:#B8BCC6;
  --cc-muted:#7C8698;
  --cc-line:rgba(197,160,89,.22);
  --cc-line-soft:rgba(244,244,244,.09);
  --cc-radius:4px;
  --cc-font:'Inter',-apple-system,BlinkMacSystemFont,'Segoe UI',Arial,sans-serif;
  --cc-font-display:'Playfair Display',Georgia,serif;
  --cc-z:2147483000;
}

.cc-root,.cc-root *{box-sizing:border-box}
.cc-root{font-family:var(--cc-font);line-height:1.65}

/* ------------------------------------------------------------- overlay --- */
.cc-overlay{
  position:fixed;
  inset:0;
  background:rgba(2,6,15,.72);
  -webkit-backdrop-filter:blur(3px);
  backdrop-filter:blur(3px);
  z-index:calc(var(--cc-z) - 1);
  opacity:0;
  transition:opacity .25s ease;
}
.cc-overlay.cc-show{opacity:1}

/* -------------------------------------------------------------- banner --- */
.cc-banner{
  position:fixed;
  left:0;
  right:0;
  bottom:0;
  z-index:var(--cc-z);
  background:var(--cc-navy-card);
  border-top:1px solid var(--cc-gold);
  box-shadow:0 -20px 60px -24px rgba(0,0,0,.95);
  transform:translateY(100%);
  transition:transform .34s cubic-bezier(.22,.61,.36,1);
}
.cc-banner.cc-show{transform:translateY(0)}

.cc-banner-inner{
  max-width:1200px;
  margin:0 auto;
  padding:26px 32px 28px;
  display:grid;
  grid-template-columns:minmax(0,1fr) auto;
  gap:22px 48px;
  align-items:center;
}

.cc-kicker{
  display:block;
  font-size:10px;
  font-weight:600;
  letter-spacing:.3em;
  text-transform:uppercase;
  color:var(--cc-gold);
  margin-bottom:10px;
}
.cc-title{
  font-family:var(--cc-font-display);
  font-size:20px;
  font-weight:400;
  color:var(--cc-silk);
  margin:0 0 8px;
  line-height:1.25;
}
.cc-text{
  font-size:13.5px;
  color:var(--cc-text);
  margin:0;
  max-width:64ch;
}
.cc-text a{color:var(--cc-gold);text-decoration:none;border-bottom:1px solid rgba(197,160,89,.4)}
.cc-text a:hover{border-bottom-color:var(--cc-gold)}

/* ------------------------------------------------------------- botones --- */
.cc-actions{
  display:flex;
  flex-wrap:wrap;
  gap:10px;
  align-items:center;
}

.cc-btn{
  font-family:var(--cc-font);
  font-size:12.5px;
  font-weight:600;
  letter-spacing:.06em;
  line-height:1;
  padding:14px 24px;
  border-radius:var(--cc-radius);
  border:1px solid transparent;
  cursor:pointer;
  white-space:nowrap;
  transition:background .2s ease,color .2s ease,border-color .2s ease;
  -webkit-appearance:none;
  appearance:none;
}

/* AEPD: aceptar y rechazar deben tener EXACTAMENTE el mismo peso visual.
   Ambos usan .cc-btn--equal. No modificar uno sin modificar el otro. */
.cc-btn--equal{
  background:var(--cc-gold);
  color:var(--cc-navy);
  border-color:var(--cc-gold);
  min-width:148px;
  text-align:center;
}
.cc-btn--equal:hover{background:#D4B172;border-color:#D4B172}

.cc-btn--ghost{
  background:transparent;
  color:var(--cc-text);
  border-color:var(--cc-line);
  padding:14px 20px;
}
.cc-btn--ghost:hover{color:var(--cc-gold);border-color:var(--cc-gold)}

.cc-btn:focus-visible,
.cc-link:focus-visible,
.cc-switch input:focus-visible + .cc-switch-track{
  outline:2px solid var(--cc-gold);
  outline-offset:2px;
}

.cc-link{
  background:none;
  border:none;
  padding:0;
  font-family:var(--cc-font);
  font-size:12.5px;
  color:var(--cc-muted);
  text-decoration:underline;
  text-underline-offset:3px;
  cursor:pointer;
}
.cc-link:hover{color:var(--cc-gold)}

/* --------------------------------------------------------------- panel --- */
.cc-modal{
  position:fixed;
  inset:0;
  z-index:var(--cc-z);
  display:flex;
  align-items:center;
  justify-content:center;
  padding:24px;
  opacity:0;
  pointer-events:none;
  transition:opacity .22s ease;
}
.cc-modal.cc-show{opacity:1;pointer-events:auto}

.cc-dialog{
  width:100%;
  max-width:620px;
  max-height:86vh;
  display:flex;
  flex-direction:column;
  background:var(--cc-navy-card);
  border:1px solid var(--cc-line);
  border-radius:var(--cc-radius);
  box-shadow:0 30px 80px -30px rgba(0,0,0,.95);
  transform:translateY(12px) scale(.99);
  transition:transform .22s ease;
}
.cc-modal.cc-show .cc-dialog{transform:none}

.cc-dialog-head{
  padding:26px 30px 20px;
  border-bottom:1px solid var(--cc-line-soft);
}
.cc-dialog-head .cc-title{font-size:23px;margin-bottom:6px}
.cc-dialog-head p{font-size:13px;color:var(--cc-text);margin:0}

.cc-dialog-body{
  padding:10px 30px 6px;
  overflow-y:auto;
  flex:1 1 auto;
}

.cc-group{
  padding:20px 0;
  border-bottom:1px solid var(--cc-line-soft);
}
.cc-group:last-child{border-bottom:none}
.cc-group-head{
  display:flex;
  align-items:flex-start;
  justify-content:space-between;
  gap:20px;
}
.cc-group-name{
  font-size:14px;
  font-weight:600;
  color:var(--cc-silk);
  margin:0 0 6px;
  letter-spacing:.01em;
}
.cc-group-desc{font-size:12.5px;color:var(--cc-text);margin:0}
.cc-group-detail{
  margin-top:10px;
  font-size:11.5px;
  color:var(--cc-muted);
  font-variant-numeric:tabular-nums;
}
.cc-group-detail code{
  color:var(--cc-gold-dim);
  font-family:'JetBrains Mono',ui-monospace,SFMono-Regular,Menlo,monospace;
  font-size:11px;
}
.cc-badge{
  display:inline-block;
  font-size:9.5px;
  font-weight:600;
  letter-spacing:.16em;
  text-transform:uppercase;
  color:var(--cc-gold-dim);
  border:1px solid var(--cc-line);
  border-radius:2px;
  padding:3px 8px;
  white-space:nowrap;
}

/* ------------------------------------------------------------ switches --- */
.cc-switch{position:relative;flex:0 0 auto;display:inline-flex;align-items:center}
.cc-switch input{
  position:absolute;
  opacity:0;
  width:46px;
  height:24px;
  margin:0;
  cursor:pointer;
}
.cc-switch-track{
  width:46px;
  height:24px;
  border-radius:12px;
  background:var(--cc-navy-deep);
  border:1px solid var(--cc-line);
  position:relative;
  transition:background .2s ease,border-color .2s ease;
  pointer-events:none;
}
.cc-switch-track::after{
  content:"";
  position:absolute;
  top:3px;
  left:3px;
  width:16px;
  height:16px;
  border-radius:50%;
  background:var(--cc-muted);
  transition:transform .2s ease,background .2s ease;
}
.cc-switch input:checked + .cc-switch-track{background:rgba(197,160,89,.18);border-color:var(--cc-gold)}
.cc-switch input:checked + .cc-switch-track::after{transform:translateX(22px);background:var(--cc-gold)}
.cc-switch input:disabled{cursor:not-allowed}
.cc-switch input:disabled + .cc-switch-track{opacity:.55}

.cc-dialog-foot{
  padding:20px 30px 24px;
  border-top:1px solid var(--cc-line-soft);
  display:flex;
  flex-wrap:wrap;
  gap:10px;
  align-items:center;
  justify-content:space-between;
}
.cc-dialog-foot .cc-actions{flex:1 1 auto;justify-content:flex-end}

.cc-meta{
  font-size:10.5px;
  color:var(--cc-muted);
  letter-spacing:.04em;
  margin:14px 0 0;
}

/* ------------------------------------- placeholder de contenido bloqueado --- */
.cc-embed{position:relative;min-height:180px}
.cc-embed[data-cc-blocked="1"] > iframe,
.cc-embed[data-cc-blocked="1"] > video{display:none !important}
.cc-embed-ph{
  display:flex;
  flex-direction:column;
  align-items:center;
  justify-content:center;
  text-align:center;
  gap:14px;
  padding:34px 26px;
  min-height:180px;
  height:100%;
  background:var(--cc-navy-deep);
  border:1px solid var(--cc-line);
  border-radius:var(--cc-radius);
}
.cc-embed-ph p{margin:0;font-size:13px;color:var(--cc-text);max-width:44ch}
.cc-embed-ph strong{color:var(--cc-silk);font-weight:600}

/* ------------------------------------------------- botón flotante reabrir --- */
.cc-reopen{
  position:fixed;
  left:20px;
  bottom:20px;
  z-index:calc(var(--cc-z) - 2);
  width:38px;
  height:38px;
  display:none;
  align-items:center;
  justify-content:center;
  background:var(--cc-navy-card);
  border:1px solid var(--cc-line);
  border-radius:var(--cc-radius);
  color:var(--cc-gold-dim);
  cursor:pointer;
  transition:color .2s ease,border-color .2s ease;
}
.cc-reopen.cc-show{display:flex}
.cc-reopen:hover{color:var(--cc-gold);border-color:var(--cc-gold)}
.cc-reopen svg{width:17px;height:17px}

/* ---------------------------------------------------------- responsive --- */
@media (max-width:900px){
  .cc-banner-inner{grid-template-columns:1fr;gap:20px;padding:22px 22px 24px}
  .cc-actions{width:100%}
  .cc-btn--equal{flex:1 1 auto;min-width:0}
  .cc-btn--ghost{flex:1 1 100%}
}
@media (max-width:560px){
  .cc-banner{max-height:88vh;overflow-y:auto}
  .cc-title{font-size:18px}
  .cc-dialog-head,.cc-dialog-body,.cc-dialog-foot{padding-left:20px;padding-right:20px}
  .cc-dialog-foot{flex-direction:column;align-items:stretch}
  .cc-dialog-foot .cc-actions{justify-content:stretch}
  .cc-dialog-foot .cc-btn{width:100%}
  .cc-modal{padding:0}
  .cc-dialog{max-width:100%;max-height:100vh;height:100%;border:none;border-radius:0}
}

@media (prefers-reduced-motion:reduce){
  .cc-banner,.cc-overlay,.cc-modal,.cc-dialog,.cc-switch-track,.cc-switch-track::after{transition:none}
}

@media print{
  .cc-root{display:none !important}
}
