.gw-cookie {
  position: fixed;
  z-index: 2100;
  right: 24px;
  bottom: 24px;
  left: 24px;
  display: flex;
  align-items: center;
  gap: 28px;
  width: min(900px, calc(100% - 48px));
  min-height: 104px;
  margin: 0 auto;
  padding: 20px 22px 20px 26px;
  color: #fff;
  background: #1b1b1d;
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 22px;
  box-shadow: 0 20px 60px rgba(15, 15, 16, 0.28);
  font-family: "Montserrat", Arial, sans-serif;
  opacity: 0;
  transform: translateY(18px);
  transition: opacity 220ms ease, transform 220ms ease;
}

.gw-cookie.is-visible {
  opacity: 1;
  transform: translateY(0);
}

.gw-cookie.is-leaving {
  opacity: 0;
  transform: translateY(12px);
  pointer-events: none;
}

.gw-cookie__copy {
  flex: 1 1 auto;
  min-width: 0;
}

.gw-cookie__title {
  margin: 0 0 6px;
  color: #fff;
  font-size: 17px;
  font-weight: 850;
  letter-spacing: -0.02em;
  line-height: 1.2;
}

.gw-cookie__text {
  max-width: 610px;
  margin: 0;
  color: rgba(255, 255, 255, 0.68);
  font-size: 13px;
  font-weight: 550;
  line-height: 1.5;
}

.gw-cookie__text a {
  color: #fff;
  text-decoration: underline;
  text-decoration-color: rgba(242, 100, 34, 0.72);
  text-decoration-thickness: 2px;
  text-underline-offset: 3px;
}

.gw-cookie__details {
  display: inline;
  padding: 0;
  border: 0;
  color: #fff;
  background: transparent;
  font: inherit;
  font-weight: 700;
  text-decoration: underline;
  text-decoration-color: rgba(242, 100, 34, 0.72);
  text-decoration-thickness: 2px;
  text-underline-offset: 3px;
  cursor: pointer;
}

.gw-cookie__text a:hover {
  color: #ff8750;
}

.gw-cookie__details:hover {
  color: #ff8750;
}

.gw-cookie__actions {
  display: flex;
  flex: 0 0 auto;
  align-items: center;
  gap: 10px;
}

.gw-cookie__button {
  min-height: 46px;
  padding: 0 20px;
  border: 1px solid rgba(255, 255, 255, 0.18);
  border-radius: 999px;
  color: #fff;
  background: transparent;
  font: inherit;
  font-size: 12px;
  font-weight: 800;
  line-height: 1;
  white-space: nowrap;
  cursor: pointer;
  transition: background-color 160ms ease, border-color 160ms ease, transform 160ms ease;
}

.gw-cookie__button:hover {
  background: rgba(255, 255, 255, 0.08);
  border-color: rgba(255, 255, 255, 0.34);
  transform: translateY(-1px);
}

.gw-cookie__button--primary {
  color: #fff;
  background: #f26422;
  border-color: #f26422;
}

.gw-cookie__button--secondary {
  color: #1b1b1d;
  background: #fff;
  border-color: #fff;
}

.gw-cookie__button--secondary:hover {
  color: #1b1b1d;
  background: #e8e8ea;
  border-color: #e8e8ea;
}

.gw-cookie__button--primary:hover {
  background: #d84d0d;
  border-color: #d84d0d;
}

.gw-cookie__button:focus-visible,
.gw-cookie__text a:focus-visible,
.gw-cookie__details:focus-visible,
.gw-cookie-dialog__close:focus-visible,
.gw-cookie-option:has(input:focus-visible) {
  outline: 3px solid #fff;
  outline-offset: 3px;
}

.gw-cookie-modal-open {
  overflow: hidden;
}

.gw-cookie-dialog {
  position: fixed;
  z-index: 2200;
  inset: 0;
  display: grid;
  place-items: center;
  padding: 24px;
  background: rgba(12, 12, 14, 0.68);
  backdrop-filter: blur(8px);
  overscroll-behavior: contain;
  font-family: "Montserrat", Arial, sans-serif;
}

.gw-cookie-dialog__panel {
  display: flex;
  flex-direction: column;
  width: min(720px, 100%);
  max-height: min(820px, calc(100dvh - 48px));
  overflow: hidden;
  color: #f7f7f7;
  background: #1b1b1d;
  border: 1px solid rgba(255, 255, 255, 0.14);
  border-radius: 22px;
  box-shadow: 0 28px 90px rgba(0, 0, 0, 0.45);
}

.gw-cookie-dialog__header {
  display: flex;
  flex: 0 0 auto;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  padding: 22px 24px 18px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.gw-cookie-dialog__title {
  margin: 0;
  color: #fff;
  font-size: clamp(20px, 3vw, 28px);
  font-weight: 850;
  line-height: 1.15;
  letter-spacing: -0.03em;
  text-wrap: balance;
}

.gw-cookie-dialog__close {
  display: grid;
  flex: 0 0 42px;
  width: 42px;
  height: 42px;
  place-items: center;
  padding: 0;
  border: 1px solid rgba(255, 255, 255, 0.18);
  border-radius: 50%;
  color: #fff;
  background: transparent;
  cursor: pointer;
  transition: background-color 160ms ease, border-color 160ms ease;
}

.gw-cookie-dialog__close:hover {
  background: rgba(255, 255, 255, 0.08);
  border-color: rgba(255, 255, 255, 0.34);
}

.gw-cookie-dialog__content {
  flex: 1 1 auto;
  min-height: 0;
  padding: 20px 24px 8px;
  overflow-y: auto;
  overscroll-behavior: contain;
  scrollbar-gutter: stable;
}

.gw-cookie-dialog__content p,
.gw-cookie-dialog__content li {
  color: rgba(255, 255, 255, 0.72);
  font-size: 14px;
  line-height: 1.65;
}

.gw-cookie-dialog__content p {
  margin: 0 0 16px;
}

.gw-cookie-dialog__content h3 {
  margin: 24px 0 8px;
  color: #fff;
  font-size: 16px;
  font-weight: 800;
  line-height: 1.35;
}

.gw-cookie-dialog__content ul {
  margin: -4px 0 18px;
  padding-left: 22px;
}

.gw-cookie-dialog__categories {
  display: grid;
  gap: 8px;
  margin: 10px 0 22px;
}

.gw-cookie-option {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  min-height: 72px;
  padding: 13px 14px 13px 16px;
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 14px;
  cursor: pointer;
  transition: background-color 160ms ease, border-color 160ms ease;
}

.gw-cookie-option:hover {
  background: rgba(255, 255, 255, 0.045);
  border-color: rgba(255, 255, 255, 0.24);
}

.gw-cookie-option--locked {
  cursor: default;
}

.gw-cookie-option > span:first-child {
  display: grid;
  gap: 3px;
}

.gw-cookie-option strong {
  color: #fff;
  font-size: 13px;
  line-height: 1.3;
}

.gw-cookie-option small {
  color: rgba(255, 255, 255, 0.62);
  font-size: 12px;
  line-height: 1.45;
}

.gw-cookie-option input {
  position: absolute;
  width: 1px;
  height: 1px;
  opacity: 0;
  pointer-events: none;
}

.gw-cookie-option__switch {
  position: relative;
  flex: 0 0 46px;
  width: 46px;
  height: 26px;
  border-radius: 999px;
  background: #55555b;
  transition: background-color 160ms ease;
}

.gw-cookie-option__switch::after {
  position: absolute;
  top: 3px;
  left: 3px;
  width: 20px;
  height: 20px;
  border-radius: 50%;
  background: #fff;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.28);
  content: "";
  transition: transform 160ms ease;
}

.gw-cookie-option input:checked + .gw-cookie-option__switch {
  background: #f26422;
}

.gw-cookie-option input:checked + .gw-cookie-option__switch::after {
  transform: translateX(20px);
}

.gw-cookie-option input:disabled + .gw-cookie-option__switch {
  opacity: 0.62;
}

.gw-cookie-dialog__actions {
  display: flex;
  flex: 0 0 auto;
  justify-content: flex-end;
  gap: 10px;
  padding: 16px 24px 22px;
  border-top: 1px solid rgba(255, 255, 255, 0.1);
  background: #1b1b1d;
}

@media (max-width: 760px) {
  .gw-cookie {
    right: 12px;
    bottom: max(12px, env(safe-area-inset-bottom));
    left: 12px;
    display: block;
    width: auto;
    min-height: 0;
    padding: 17px;
    border-radius: 18px;
  }

  .gw-cookie__title { font-size: 16px; }
  .gw-cookie__text { font-size: 12px; }

  .gw-cookie__actions {
    display: grid;
    grid-template-columns: 1fr 1fr 1fr;
    gap: 8px;
    margin-top: 13px;
  }

  .gw-cookie__button {
    width: 100%;
    min-height: 44px;
    padding: 0 12px;
    font-size: 9px;
  }

  .gw-cookie-dialog {
    align-items: end;
    padding: 10px;
  }

  .gw-cookie-dialog__panel {
    max-height: calc(100dvh - 20px);
    border-radius: 18px;
  }

  .gw-cookie-dialog__header {
    padding: 17px 16px 14px;
  }

  .gw-cookie-dialog__content {
    padding: 16px 16px 4px;
  }

  .gw-cookie-dialog__content p,
  .gw-cookie-dialog__content li {
    font-size: 13px;
  }

  .gw-cookie-dialog__actions {
    display: grid;
    grid-template-columns: 1fr;
    padding: 12px 16px max(16px, env(safe-area-inset-bottom));
  }

  .gw-cookie-dialog__actions .gw-cookie__button--primary {
    grid-row: 1;
  }

}

@media (prefers-reduced-motion: reduce) {
  .gw-cookie,
  .gw-cookie__button,
  .gw-cookie-dialog__close,
  .gw-cookie-option,
  .gw-cookie-option__switch,
  .gw-cookie-option__switch::after { transition: none; }
}
