/* gtc_cookies (03/11/2026): banner y panel del selector de cookies de www.grantecan.es.
   Colores del tema gtc_theme (fondo #111, texto blanco, acento #dc3545), como el antiguo banner de cookieconsent. */

#gtcCookieBanner {
  display: none;
  position: fixed;
  left: 0;
  right: 0;
  bottom: 0;
  z-index: 9001;
  background: #111;
  color: #fff;
  border-top: 1px solid #fff;
  padding: 14px 16px;
  font-size: 0.875rem;
  line-height: 1.5;
  box-shadow: 0 -2px 12px rgba(0, 0, 0, 0.4);
}
#gtcCookieBanner a { color: #dc3545; text-decoration: underline; }
#gtcCookieBanner .gtc-banner-text { max-width: 1100px; margin: 0 auto 10px; }
#gtcCookieBanner .gtc-banner-buttons { max-width: 1100px; margin: 0 auto; display: flex; flex-wrap: wrap; gap: 8px; justify-content: flex-end; }

.gtc-btn {
  cursor: pointer;
  border: 1px solid #fff;
  border-radius: 20px;
  padding: 8px 18px;
  font-size: 0.875rem;
  font-weight: 700;
  text-transform: uppercase;
  background: transparent;
  color: #fff;
  transition: background 200ms ease-in-out, color 200ms ease-in-out;
}
.gtc-btn:hover, .gtc-btn:focus { background: #dc3545; border-color: #dc3545; color: #fff; outline: none; }
.gtc-btn-primary { background: #fff; color: #000; }
.gtc-link-btn { background: none; border: none; color: #dc3545; cursor: pointer; padding: 0; font-size: 0.85rem; text-decoration: underline; }

#gtcCookieOverlay {
  display: none;
  position: fixed;
  inset: 0;
  z-index: 9002;
  background: rgba(0, 0, 0, 0.6);
  overflow-y: auto;
  padding: 24px 12px;
}
#gtcCookiePanel {
  max-width: 760px;
  margin: 0 auto;
  background: #fff;
  color: #222;
  border-radius: 8px;
  padding: 20px 24px;
  font-size: 0.9rem;
  line-height: 1.5;
}
#gtcCookiePanel .gtc-panel-head { display: flex; justify-content: space-between; align-items: center; margin-bottom: 8px; }
#gtcCookiePanel h2 { font-size: 1.3rem; margin: 0; }
#gtcCookiePanel .gtc-panel-close { background: none; border: none; font-size: 1.8rem; line-height: 1; cursor: pointer; color: #555; }
#gtcCookiePanel .gtc-panel-intro { color: #444; }
#gtcCookiePanel .gtc-cat { border-top: 1px solid #ddd; padding: 12px 0; }
#gtcCookiePanel .gtc-cat-head { display: flex; align-items: center; gap: 10px; }
#gtcCookiePanel .gtc-cat-title { font-weight: 700; margin: 0; }
#gtcCookiePanel .gtc-badge { font-size: 0.75rem; background: #eee; border-radius: 10px; padding: 2px 8px; color: #555; }
#gtcCookiePanel .gtc-cat-desc { margin: 6px 0; color: #444; }
#gtcCookiePanel .gtc-cookie-list { margin-top: 8px; overflow-x: auto; }
#gtcCookiePanel .gtc-cookie-table { width: 100%; border-collapse: collapse; font-size: 0.8rem; }
#gtcCookiePanel .gtc-cookie-table th, #gtcCookiePanel .gtc-cookie-table td { border: 1px solid #ddd; padding: 4px 6px; text-align: left; vertical-align: top; }
#gtcCookiePanel .gtc-cookie-table th { background: #f3f3f3; }
#gtcCookiePanel .gtc-panel-foot { border-top: 1px solid #ddd; padding-top: 12px; margin-top: 8px; display: flex; flex-wrap: wrap; gap: 8px; align-items: center; justify-content: space-between; }
#gtcCookiePanel .gtc-panel-buttons { display: flex; flex-wrap: wrap; gap: 8px; }
#gtcCookiePanel .gtc-btn { border-color: #333; color: #333; }
#gtcCookiePanel .gtc-btn-primary { background: #dc3545; border-color: #dc3545; color: #fff; }
#gtcCookiePanel .gtc-btn:hover, #gtcCookiePanel .gtc-btn:focus { background: #dc3545; border-color: #dc3545; color: #fff; }
#gtcCookiePanel .gtc-policy-link { color: #dc3545; }

/* interruptores */
.gtc-switch { position: relative; display: inline-block; width: 42px; height: 24px; flex: none; }
.gtc-switch input { opacity: 0; width: 0; height: 0; }
.gtc-slider { position: absolute; cursor: pointer; inset: 0; background: #bbb; border-radius: 24px; transition: 200ms; }
.gtc-slider:before { content: ""; position: absolute; height: 18px; width: 18px; left: 3px; bottom: 3px; background: #fff; border-radius: 50%; transition: 200ms; }
.gtc-switch input:checked + .gtc-slider { background: #dc3545; }
.gtc-switch input:checked + .gtc-slider:before { transform: translateX(18px); }
.gtc-switch input:disabled + .gtc-slider { opacity: 0.6; cursor: default; }
.gtc-switch input:focus + .gtc-slider { box-shadow: 0 0 0 2px #fff, 0 0 0 4px #dc3545; }

/* contenido de terceros bloqueado */
.gtc-embed-blocked { background: #f3f3f3; border: 1px dashed #999; padding: 16px; text-align: center; color: #333; margin: 8px 0; }
.gtc-embed-blocked .gtc-btn { border-color: #333; color: #333; }
.gtc-embed-blocked .gtc-btn-primary { background: #dc3545; border-color: #dc3545; color: #fff; }

/* enlace del pie */
.gtc-cookies-footer-link { margin: 8px 0 0; font-size: 0.8rem; text-align: center; }
.gtc-cookies-footer-link a { color: inherit; text-decoration: underline; }

@media print { #gtcCookieBanner, #gtcCookieOverlay, .gtc-cookies-footer-link { display: none !important; } }
@media (min-width: 768px) {
  #gtcCookieBanner { padding: 16px 24px; }
}
