/* Bolt-On Cookie Consent — brand tokens from theme (RGB channels: rgb(var(--name))). */

/* Blur + dim page behind banner */
.bolt-on-consent-page-overlay {
  position: fixed;
  inset: 0;
  z-index: 999998;
  pointer-events: auto;
  background: rgba(0, 0, 0, 0.08);
  backdrop-filter: blur(5px);
  -webkit-backdrop-filter: blur(5px);
}

.bolt-on-consent-page-overlay[hidden] {
  display: none;
}

@media (prefers-reduced-motion: reduce) {
  .bolt-on-consent-page-overlay {
    backdrop-filter: none;
    -webkit-backdrop-filter: none;
    background: rgba(0, 0, 0, 0.2);
  }
}

html.bolt-on-consent-locked {
  overflow: hidden;
  height: 100%;
}

/* Banner */
.bolt-on-consent-banner {
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  z-index: 999999;
  padding: 1rem 1.5rem;
  background: rgb(var(--color-primary, 3 244 209));
  color: rgb(var(--color-primary-text, 255 255 255));
  box-shadow: 0 -4px 20px rgba(0, 0, 0, 0.15);
}

.bolt-on-consent-banner__inner {
  max-width: 72rem;
  margin: 0 auto;
}

.bolt-on-consent-banner__title {
  margin: 0 0 0.5rem;
  font-size: 1.125rem;
  font-weight: 600;
  color: inherit;
}

.bolt-on-consent-banner__text {
  margin: 0 0 1rem;
  font-size: 0.9375rem;
  line-height: 1.5;
  opacity: 0.95;
  color: inherit;
}

.bolt-on-consent-banner__text a {
  color: inherit;
  text-decoration: underline;
  text-underline-offset: 2px;
}

.bolt-on-consent-banner__text a:hover {
  opacity: 0.8;
}

/* Button row */
.bolt-on-consent-banner__actions {
  display: flex;
  flex-wrap: wrap;
  gap: 1rem;
  align-items: center;
}

/* Base button reset */
.bolt-on-consent-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0.5rem 1.5rem;
  font-family: inherit;
  font-size: 0.875rem;
  font-weight: 600;
  line-height: 1.25;
  cursor: pointer;
  border: none;
  background: transparent;
  text-decoration: none;
  transition: background-color 150ms ease, opacity 150ms ease;
}

/* Outlined buttons — white border + white text on brand background */
.bolt-on-consent-banner .bolt-on-consent-btn--outline {
  color: rgba(255, 255, 255, 0.95);
  box-shadow: inset 0 0 0 2px rgba(255, 255, 255, 0.85);
}

.bolt-on-consent-banner .bolt-on-consent-btn--outline:hover {
  background-color: rgba(255, 255, 255, 0.12);
}

/* Link-style button — Manage Preferences */
.bolt-on-consent-banner .bolt-on-consent-btn--link {
  color: rgba(255, 255, 255, 0.85);
  text-decoration: underline;
  text-underline-offset: 2px;
  padding: 0.5rem 0;
}

.bolt-on-consent-banner .bolt-on-consent-btn--link:hover {
  opacity: 0.7;
}

/* Legacy class names (pre-fdabb16 markup) */
.bolt-on-consent-banner .btn-line {
  color: rgba(255, 255, 255, 0.95);
  box-shadow: inset 0 0 0 2px rgba(255, 255, 255, 0.85);
}

.bolt-on-consent-banner .btn-line:hover {
  background-color: rgba(255, 255, 255, 0.12);
}

.bolt-on-consent-banner .btn-link {
  color: rgba(255, 255, 255, 0.85);
  text-decoration: underline;
  text-underline-offset: 2px;
}

.bolt-on-consent-banner .btn-link:hover {
  opacity: 0.7;
}

/* Modal */
.bolt-on-consent-modal {
  position: fixed;
  inset: 0;
  z-index: 1000000;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 1rem;
}

.bolt-on-consent-modal[hidden] {
  display: none;
}

.bolt-on-consent-modal__backdrop {
  position: absolute;
  inset: 0;
  background: rgba(0, 0, 0, 0.5);
  cursor: pointer;
}

.bolt-on-consent-modal__panel {
  position: relative;
  width: 100%;
  max-width: 28rem;
  max-height: 90vh;
  overflow: auto;
  padding: 1.5rem;
  background: rgb(var(--color-surface, 255 255 255));
  color: rgb(var(--color-text, 55 65 81));
  border-radius: 0.5rem;
  box-shadow: 0 20px 40px rgba(0, 0, 0, 0.3);
}

.bolt-on-consent-modal__title {
  margin: 0 0 0.5rem;
  font-size: 1.25rem;
  font-weight: 600;
}

.bolt-on-consent-modal__intro {
  margin: 0 0 1.25rem;
  font-size: 0.9375rem;
  opacity: 0.9;
}

.bolt-on-consent-modal__toggles {
  display: flex;
  flex-direction: column;
  gap: 1rem;
  margin-bottom: 1.5rem;
}

.bolt-on-consent-row {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 1rem;
}

.bolt-on-consent-label {
  flex: 1;
  cursor: pointer;
}

.bolt-on-consent-label__title {
  display: block;
  font-weight: 500;
  margin-bottom: 0.25rem;
}

.bolt-on-consent-label__desc {
  display: block;
  font-size: 0.8125rem;
  opacity: 0.85;
}

.bolt-on-consent-checkbox {
  width: 1.25rem;
  height: 1.25rem;
  margin-top: 0.125rem;
  accent-color: rgb(var(--color-primary, 3 244 209));
}

.bolt-on-consent-checkbox:disabled {
  opacity: 0.7;
  cursor: not-allowed;
}

.bolt-on-consent-modal__actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
  align-items: center;
}

.bolt-on-consent-btn--primary {
  color: rgb(var(--color-surface, 255 255 255));
  background: rgb(var(--color-primary, 3 244 209));
  box-shadow: inset 0 0 0 2px rgb(var(--color-primary, 3 244 209));
  padding: 0.5rem 1.5rem;
}

.bolt-on-consent-btn--primary:hover {
  opacity: 0.88;
}

/* Footer links */
.bolt-on-consent-footer-links {
  font-size: 0.8125rem;
  opacity: 0.85;
}

.bolt-on-consent-footer-links a {
  color: rgb(var(--color-text, 55 65 81));
  text-decoration: underline;
}

.bolt-on-consent-footer-links a:hover {
  text-decoration: none;
}
