.cookie-layer {
  position: fixed;
  left: 0;
  right: 0;
  bottom: 0;
  z-index: 200;
  display: flex;
  justify-content: center;
  padding: 0 24px 28px;
  pointer-events: none;
}
.cookie-layer[hidden] { display: none; }

.cookie-card {
  pointer-events: auto;
  width: min(920px, 100%);
  padding: 28px 32px;
  border-radius: 24px;
  border: 1px solid #eeedf5;
  background: #fff;
  box-shadow: 0 18px 50px rgba(27, 31, 51, .12);
}

.cookie-main {
  display: flex;
  align-items: flex-start;
  gap: 16px;
}
.cookie-mark {
  flex: 0 0 auto;
  width: 40px;
  height: 40px;
  border-radius: 12px;
  display: grid;
  place-items: center;
  color: #fff;
  background: #6d4aff;
}
.cookie-mark svg { width: 20px; height: 20px; }

.cookie-copy { min-width: 0; flex: 1; }
.cookie-card h2 {
  margin: 2px 0 6px;
  font-family: Inter, "Plus Jakarta Sans", sans-serif;
  font-size: 18px;
  font-weight: 700;
  line-height: 1.3;
  letter-spacing: 0;
  color: #1b1f33;
}
.cookie-copy p {
  margin: 0 0 16px;
  max-width: 62em;
  color: #5d6275;
  font-size: 14px;
  line-height: 1.55;
}
.cookie-copy a {
  color: #6d4aff;
  font-weight: 600;
  text-decoration: underline;
  text-underline-offset: 2px;
}

.cookie-actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 10px;
}
.cookie-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 40px;
  padding: 8px 18px;
  border: 0;
  border-radius: 999px;
  font: 700 14px Inter, "Plus Jakarta Sans", sans-serif;
  cursor: pointer;
}
.cookie-btn-primary {
  color: #fff;
  background: #6d4aff;
}
.cookie-btn-primary:hover { background: #5b39f0; }
.cookie-btn-ghost {
  color: #1b1f33;
  background: #f3f2f8;
}
.cookie-btn-ghost:hover { background: #ebe9f3; }
.cookie-btn-text {
  color: #1b1f33;
  background: transparent;
  padding-left: 10px;
  padding-right: 10px;
}
.cookie-btn-text:hover { color: #6d4aff; }

.cookie-prefs {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
  margin: 18px 0 0;
  padding-top: 16px;
  border-top: 1px solid #f0eef6;
}
.cookie-prefs[hidden] { display: none; }
.cookie-opt {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 14px 16px;
  border: 1px solid #eeedf5;
  border-radius: 16px;
  background: #faf9fc;
}
.cookie-opt b {
  display: block;
  font-size: 14px;
  font-weight: 700;
  color: #1b1f33;
}
.cookie-opt small {
  display: block;
  margin-top: 3px;
  color: #8b90a3;
  font-size: 12px;
  line-height: 1.4;
}
.cookie-chip {
  flex: 0 0 auto;
  padding: 6px 10px;
  border-radius: 999px;
  background: #f1edff;
  color: #6d4aff;
  font-size: 11px;
  font-weight: 800;
}

.cookie-switch {
  position: relative;
  flex: 0 0 auto;
  width: 44px;
  height: 26px;
}
.cookie-switch input {
  position: absolute;
  inset: 0;
  z-index: 1;
  margin: 0;
  opacity: 0;
  cursor: pointer;
}
.cookie-switch i {
  position: relative;
  display: block;
  width: 44px;
  height: 26px;
  border-radius: 999px;
  background: #e4e2ee;
  transition: background .18s ease;
}
.cookie-switch i::after {
  content: "";
  position: absolute;
  top: 3px;
  left: 3px;
  width: 20px;
  height: 20px;
  border-radius: 50%;
  background: #fff;
  box-shadow: 0 2px 6px rgba(27, 31, 51, .18);
  transition: transform .18s ease;
}
.cookie-switch input:checked + i { background: #6d4aff; }
.cookie-switch input:checked + i::after { transform: translateX(18px); }
.cookie-switch input:focus-visible + i { box-shadow: 0 0 0 4px rgba(109, 74, 255, .16); }

@media (max-width: 720px) {
  .cookie-layer { padding: 0 12px 12px; }
  .cookie-card { padding: 18px 16px 16px; border-radius: 20px; }
  .cookie-main { gap: 12px; }
  .cookie-copy p { font-size: 13px; }
  .cookie-prefs { grid-template-columns: 1fr; }
  .cookie-actions { width: 100%; display: grid; grid-template-columns: 1fr; }
  .cookie-btn { width: 100%; }
}
