:root {
  --le-consent-plum: #66135e;
  --le-consent-plum-dark: #3f073a;
  --le-consent-accent: #b468ab;
  --le-consent-border: #ead8e7;
  --le-consent-text: #444;
  --le-consent-bg: #fff;
}

.le-consent-banner,
.le-consent-modal {
  font-family: 'Quicksand', system-ui, sans-serif;
  color: var(--le-consent-text);
}

.le-consent-banner[hidden],
.le-consent-modal[hidden] {
  display: none !important;
}

.le-consent-banner {
  position: fixed;
  z-index: 10050;
  left: max(18px, env(safe-area-inset-left));
  right: max(18px, env(safe-area-inset-right));
  bottom: max(18px, env(safe-area-inset-bottom));
  width: min(1040px, calc(100% - 36px));
  margin: 0 auto;
  padding: 20px 22px;
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: center;
  gap: 20px;
  background: rgba(255, 255, 255, 0.98);
  border: 1px solid var(--le-consent-border);
  border-radius: 18px;
  box-shadow: 0 22px 65px rgba(63, 7, 58, 0.2);
  backdrop-filter: blur(14px);
}

.le-consent-copy strong {
  display: block;
  margin-bottom: 5px;
  color: var(--le-consent-plum);
  font-size: 1rem;
  font-weight: 600;
}

.le-consent-copy p {
  margin: 0;
  font-size: 0.82rem;
  line-height: 1.65;
}

.le-consent-copy a,
.le-consent-inline-button {
  color: var(--le-consent-plum);
  text-decoration: underline;
  text-underline-offset: 3px;
}

.le-consent-actions {
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-end;
  gap: 9px;
}

.le-consent-button {
  min-height: 43px;
  padding: 0 17px;
  border: 1px solid var(--le-consent-plum);
  border-radius: 999px;
  background: #fff;
  color: var(--le-consent-plum);
  font: 600 0.72rem/1 'Quicksand', system-ui, sans-serif;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  cursor: pointer;
}

.le-consent-button:hover,
.le-consent-button:focus-visible {
  background: #f8eff7;
  outline: none;
}

.le-consent-button--primary {
  background: var(--le-consent-plum);
  color: #fff;
}

.le-consent-button--primary:hover,
.le-consent-button--primary:focus-visible {
  background: var(--le-consent-plum-dark);
}

.le-consent-modal {
  position: fixed;
  z-index: 10060;
  inset: 0;
  display: grid;
  place-items: center;
  padding: 20px;
  background: rgba(31, 5, 29, 0.55);
}

.le-consent-dialog {
  width: min(620px, 100%);
  max-height: min(760px, calc(100vh - 40px));
  overflow: auto;
  padding: 26px;
  background: var(--le-consent-bg);
  border-radius: 22px;
  box-shadow: 0 28px 90px rgba(31, 5, 29, 0.3);
}

.le-consent-dialog-header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 20px;
  margin-bottom: 18px;
}

.le-consent-dialog h2 {
  margin: 0 0 6px;
  color: var(--le-consent-plum);
  font-size: 1.35rem;
  font-weight: 500;
}

.le-consent-dialog-header p,
.le-consent-category p {
  margin: 0;
  font-size: 0.8rem;
  line-height: 1.6;
}

.le-consent-close {
  flex: 0 0 auto;
  width: 38px;
  height: 38px;
  border: 1px solid var(--le-consent-border);
  border-radius: 50%;
  background: #fff;
  color: var(--le-consent-plum);
  font-size: 1.2rem;
  cursor: pointer;
}

.le-consent-category {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 18px;
  align-items: center;
  padding: 16px 0;
  border-top: 1px solid var(--le-consent-border);
}

.le-consent-category h3 {
  margin: 0 0 5px;
  color: var(--le-consent-plum-dark);
  font-size: 0.92rem;
  font-weight: 600;
}

.le-consent-status {
  color: #28713d;
  font-size: 0.72rem;
  font-weight: 600;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}

.le-consent-switch {
  position: relative;
  display: inline-flex;
  width: 49px;
  height: 28px;
}

.le-consent-switch input {
  position: absolute;
  opacity: 0;
  pointer-events: none;
}

.le-consent-switch-track {
  width: 100%;
  height: 100%;
  border-radius: 999px;
  background: #cfc9ce;
  transition: background 0.2s ease;
  cursor: pointer;
}

.le-consent-switch-track::after {
  content: '';
  position: absolute;
  top: 4px;
  left: 4px;
  width: 20px;
  height: 20px;
  border-radius: 50%;
  background: #fff;
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.2);
  transition: transform 0.2s ease;
}

.le-consent-switch input:checked + .le-consent-switch-track {
  background: var(--le-consent-plum);
}

.le-consent-switch input:checked + .le-consent-switch-track::after {
  transform: translateX(21px);
}

.le-consent-switch input:focus-visible + .le-consent-switch-track {
  outline: 3px solid rgba(180, 104, 171, 0.35);
  outline-offset: 3px;
}

.le-consent-dialog-actions {
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-end;
  gap: 9px;
  padding-top: 20px;
  border-top: 1px solid var(--le-consent-border);
}

.le-cookie-settings-link {
  padding: 0;
  border: 0;
  background: transparent;
  color: inherit;
  font: inherit;
  cursor: pointer;
}

.le-cookie-settings-link:hover,
.le-cookie-settings-link:focus-visible {
  color: #fff;
  text-decoration: underline;
  text-underline-offset: 4px;
  outline: none;
}

@media (max-width: 760px) {
  .le-consent-banner {
    grid-template-columns: 1fr;
    gap: 15px;
    padding: 18px;
  }

  .le-consent-actions {
    justify-content: stretch;
  }

  .le-consent-button {
    flex: 1 1 130px;
  }

  .le-consent-dialog {
    padding: 21px 18px;
  }

  .le-consent-dialog-actions .le-consent-button {
    flex-basis: 100%;
  }
}

@media (prefers-reduced-motion: reduce) {
  .le-consent-switch-track,
  .le-consent-switch-track::after {
    transition: none;
  }
}
