/* =========================================================
   B&M Results — Premium Consent Banner
   Dodaj ten plik jako: /assets/consent/consent.css
   ========================================================= */

:root {
  --bm-consent-bg: rgba(7, 11, 23, .88);
  --bm-consent-panel: rgba(12, 16, 32, .94);
  --bm-consent-line: rgba(255,255,255,.13);
  --bm-consent-text: #f8fafc;
  --bm-consent-muted: rgba(248,250,252,.72);
  --bm-consent-accent: #38bdf8;
  --bm-consent-accent-2: #a855f7;
  --bm-consent-dark: #050816;
}

.bm-consent-hidden {
  display: none !important;
}

.bm-consent-lock {
  overflow: hidden;
}

.bm-consent-backdrop {
  position: fixed;
  inset: 0;
  z-index: 99980;
  background:
    radial-gradient(circle at 20% 15%, rgba(56,189,248,.18), transparent 34%),
    radial-gradient(circle at 80% 20%, rgba(168,85,247,.20), transparent 32%),
    rgba(2,6,23,.62);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  opacity: 0;
  pointer-events: none;
  transition: opacity .28s ease;
}

.bm-consent-backdrop.is-visible {
  opacity: 1;
  pointer-events: auto;
}

.bm-consent-banner {
  position: fixed;
  left: 50%;
  bottom: max(18px, env(safe-area-inset-bottom));
  z-index: 99990;
  width: min(1040px, calc(100% - 28px));
  transform: translate(-50%, 22px);
  opacity: 0;
  pointer-events: none;
  color: var(--bm-consent-text);
  transition: opacity .35s ease, transform .35s cubic-bezier(.22,1,.36,1);
}

.bm-consent-banner.is-visible {
  opacity: 1;
  transform: translate(-50%, 0);
  pointer-events: auto;
}

.bm-consent-shell {
  position: relative;
  overflow: hidden;
  border-radius: 28px;
  padding: clamp(18px, 3vw, 28px);
  border: 1px solid var(--bm-consent-line);
  background:
    linear-gradient(135deg, rgba(12,16,32,.96), rgba(8,12,28,.94)),
    radial-gradient(circle at 12% 0%, rgba(56,189,248,.18), transparent 36%),
    radial-gradient(circle at 88% 12%, rgba(168,85,247,.17), transparent 34%);
  box-shadow: 0 28px 90px rgba(0,0,0,.45);
}

.bm-consent-shell::before {
  content: "";
  position: absolute;
  inset: 0;
  pointer-events: none;
  background: linear-gradient(90deg, rgba(56,189,248,.18), transparent, rgba(244,114,182,.16));
  opacity: .45;
}

.bm-consent-content {
  position: relative;
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: clamp(18px, 4vw, 38px);
  align-items: end;
}

.bm-consent-kicker {
  margin: 0 0 .7rem;
  color: rgba(207,250,254,.8);
  font-size: .72rem;
  text-transform: uppercase;
  letter-spacing: .32em;
  font-weight: 800;
}

.bm-consent-title {
  margin: 0;
  max-width: 760px;
  font-family: Outfit, Inter, system-ui, sans-serif;
  font-size: clamp(1.35rem, 2.8vw, 2.45rem);
  line-height: 1.02;
  letter-spacing: -.045em;
  font-weight: 700;
}

.bm-consent-text {
  margin: .9rem 0 0;
  max-width: 760px;
  color: var(--bm-consent-muted);
  font-size: .95rem;
  line-height: 1.65;
}

.bm-consent-text a,
.bm-consent-small a {
  color: #7dd3fc;
  text-decoration: underline;
  text-underline-offset: 3px;
}

.bm-consent-actions {
  display: grid;
  grid-template-columns: 1fr;
  gap: 10px;
  min-width: min(300px, 100%);
}

.bm-consent-btn {
  min-height: 48px;
  border: 1px solid rgba(255,255,255,.16);
  border-radius: 999px;
  padding: 0 18px;
  font: inherit;
  font-size: .9rem;
  font-weight: 750;
  cursor: pointer;
  transition: transform .22s ease, box-shadow .22s ease, border-color .22s ease, background .22s ease;
}

.bm-consent-btn:hover {
  transform: translateY(-2px);
}

.bm-consent-btn--primary {
  border: 0;
  color: #04111f;
  background: linear-gradient(90deg, #38bdf8, #a855f7, #f472b6);
  box-shadow: 0 16px 38px rgba(56,189,248,.20);
}

.bm-consent-btn--secondary {
  color: #fff;
  background: rgba(255,255,255,.075);
}

.bm-consent-btn--ghost {
  color: rgba(255,255,255,.86);
  background: transparent;
}

.bm-consent-small {
  margin: .9rem 0 0;
  color: rgba(248,250,252,.55);
  font-size: .78rem;
  line-height: 1.5;
}

/* Modal */
.bm-consent-modal {
  position: fixed;
  inset: 0;
  z-index: 100000;
  display: grid;
  place-items: center;
  padding: 18px;
  opacity: 0;
  pointer-events: none;
  transition: opacity .25s ease;
}

.bm-consent-modal.is-visible {
  opacity: 1;
  pointer-events: auto;
}

.bm-consent-dialog {
  width: min(760px, 100%);
  max-height: min(760px, calc(100vh - 36px));
  overflow: auto;
  color: var(--bm-consent-text);
  border-radius: 30px;
  border: 1px solid var(--bm-consent-line);
  background:
    radial-gradient(circle at 16% 0%, rgba(56,189,248,.14), transparent 34%),
    radial-gradient(circle at 86% 12%, rgba(168,85,247,.15), transparent 36%),
    linear-gradient(135deg, rgba(12,16,32,.98), rgba(5,8,22,.98));
  box-shadow: 0 35px 120px rgba(0,0,0,.58);
}

.bm-consent-modal-head {
  position: sticky;
  top: 0;
  z-index: 2;
  display: flex;
  align-items: start;
  justify-content: space-between;
  gap: 18px;
  padding: 24px 24px 18px;
  background: rgba(7,11,23,.86);
  backdrop-filter: blur(18px);
  -webkit-backdrop-filter: blur(18px);
  border-bottom: 1px solid var(--bm-consent-line);
}

.bm-consent-modal-head h2 {
  margin: 0;
  font-size: clamp(1.5rem, 3vw, 2.2rem);
  line-height: 1.05;
  letter-spacing: -.04em;
}

.bm-consent-close {
  flex: 0 0 auto;
  width: 42px;
  height: 42px;
  border: 1px solid rgba(255,255,255,.14);
  border-radius: 999px;
  background: rgba(255,255,255,.06);
  color: #fff;
  cursor: pointer;
  font-size: 1.35rem;
}

.bm-consent-modal-body {
  padding: 22px 24px 24px;
}

.bm-consent-category {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 18px;
  align-items: center;
  padding: 18px 0;
  border-bottom: 1px solid rgba(255,255,255,.10);
}

.bm-consent-category:first-child {
  padding-top: 0;
}

.bm-consent-category h3 {
  margin: 0;
  font-size: 1.05rem;
}

.bm-consent-floating-icon {
  width: 22px;
  height: 22px;
  display: block;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.7;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.bm-consent-floating-icon circle {
  fill: currentColor;
  stroke: none;
}

.bm-consent-category p {
  margin: .45rem 0 0;
  color: var(--bm-consent-muted);
  font-size: .9rem;
  line-height: 1.55;
}

.bm-consent-badge {
  display: inline-flex;
  align-items: center;
  min-height: 28px;
  padding: 0 10px;
  border-radius: 999px;
  background: rgba(255,255,255,.08);
  color: rgba(255,255,255,.78);
  font-size: .75rem;
  font-weight: 700;
}

.bm-consent-switch {
  position: relative;
  width: 58px;
  height: 34px;
  display: inline-block;
}

.bm-consent-switch input {
  opacity: 0;
  width: 0;
  height: 0;
}

.bm-consent-slider {
  position: absolute;
  inset: 0;
  cursor: pointer;
  border-radius: 999px;
  background: rgba(255,255,255,.16);
  transition: background .2s ease;
}

.bm-consent-slider::before {
  content: "";
  position: absolute;
  width: 26px;
  height: 26px;
  left: 4px;
  top: 4px;
  border-radius: 50%;
  background: #fff;
  transition: transform .2s ease;
}

.bm-consent-switch input:checked + .bm-consent-slider {
  background: linear-gradient(90deg, #38bdf8, #a855f7);
}

.bm-consent-switch input:checked + .bm-consent-slider::before {
  transform: translateX(24px);
}

.bm-consent-switch input:disabled + .bm-consent-slider {
  cursor: not-allowed;
  opacity: .7;
}

.bm-consent-modal-actions {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 10px;
  margin-top: 22px;
}

.bm-consent-floating-settings {
  position: fixed;
  left: max(16px, env(safe-area-inset-left));
  bottom: max(16px, env(safe-area-inset-bottom));
  z-index: 99950;
  width: 46px;
  height: 46px;
  border: 1px solid rgba(255,255,255,.16);
  border-radius: 999px;
  background: rgba(12,16,32,.82);
  color: #fff;
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  box-shadow: 0 14px 36px rgba(0,0,0,.28);
  cursor: pointer;
  display: grid;
  place-items: center;
  font-size: 1.05rem;
}

@media (max-width: 760px) {
  .bm-consent-content {
    grid-template-columns: 1fr;
    align-items: start;
  }

  .bm-consent-actions {
    grid-template-columns: 1fr;
  }

  .bm-consent-banner {
    bottom: max(10px, env(safe-area-inset-bottom));
    width: calc(100% - 20px);
  }

  .bm-consent-shell {
    border-radius: 22px;
    padding: 18px;
  }

  .bm-consent-modal {
    padding: 10px;
    place-items: end center;
  }

  .bm-consent-dialog {
    max-height: min(760px, calc(100vh - 20px));
    border-radius: 24px;
  }

  .bm-consent-category {
    grid-template-columns: 1fr;
    gap: 12px;
  }

  .bm-consent-modal-actions {
    grid-template-columns: 1fr;
  }

  .bm-consent-floating-settings {
    width: 42px;
    height: 42px;
    left: 12px;
    bottom: 12px;
  }
}

@media (prefers-reduced-motion: reduce) {
  .bm-consent-banner,
  .bm-consent-backdrop,
  .bm-consent-modal,
  .bm-consent-btn,
  .bm-consent-slider,
  .bm-consent-slider::before {
    transition: none !important;
  }
}
