.cookie-banner[hidden] { display: none; }
.cookie-banner {
  position: fixed;
  z-index: 1000;
  right: max(18px, env(safe-area-inset-right));
  bottom: max(18px, env(safe-area-inset-bottom));
  left: max(18px, env(safe-area-inset-left));
  display: grid;
  width: min(100% - 36px, 820px);
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: center;
  gap: 22px;
  margin-inline: auto;
  padding: 21px 23px;
  overflow: hidden;
  border: 1px solid rgb(207 221 241 / 78%);
  border-radius: 22px;
  color: #15243a;
  background: rgb(255 255 255 / 93%);
  box-shadow: 0 28px 90px rgb(2 18 43 / 22%), 0 4px 16px rgb(2 18 43 / 8%);
  backdrop-filter: blur(24px) saturate(1.35);
  animation: cookie-rise .55s cubic-bezier(.16,1,.3,1) both;
}
.cookie-banner::before { position: absolute; z-index: -1; top: -75px; right: 16%; width: 180px; height: 180px; border-radius: 50%; background: rgb(30 116 255 / 13%); content: ""; filter: blur(34px); }
.cookie-banner__copy { display: grid; grid-template-columns: 42px minmax(0,1fr); align-items: start; gap: 13px; }
.cookie-banner__icon { display: grid; width: 42px; height: 42px; flex: none; place-items: center; border: 1px solid #dce9ff; border-radius: 14px; color: #1268f5; background: linear-gradient(145deg,#edf5ff,#fff); box-shadow: 0 5px 18px rgb(28 98 205 / 9%); }
.cookie-banner__icon svg { width: 20px; height: 20px; }
.cookie-banner__title { margin: 1px 0 4px; color: #101827; font-size: 15px; font-weight: 800; letter-spacing: -.025em; }
.cookie-banner__text { max-width: 500px; margin: 0; color: #617088; font-size: 12px; line-height: 1.55; }
.cookie-banner__text a { color: #1268f5; text-decoration-thickness: 1px; text-underline-offset: 2px; }
.cookie-banner__actions { display: grid; gap: 8px; }
.cookie-category__icon svg { width: 20px; height: 20px; }
.cookie-button { display: inline-flex; min-height: 42px; align-items: center; justify-content: center; gap: 9px; padding: 0 15px; border: 1px solid #dce5f1; border-radius: 999px; color: #26354b; background: #fff; font: inherit; font-size: 11px; font-weight: 800; white-space: nowrap; cursor: pointer; transition: transform .2s ease, box-shadow .2s ease, border-color .2s ease, background .2s ease; }
.cookie-button:hover { transform: translateY(-1px); border-color: #b6d0fa; box-shadow: 0 7px 18px rgb(25 76 146 / 10%); }
.cookie-button:focus-visible,.cookie-settings-link:focus-visible { outline: 3px solid rgb(18 104 245 / 35%); outline-offset: 3px; }
.cookie-button--primary { border-color: #1268f5; color: #fff; background: linear-gradient(120deg,#2784ff,#0759e8); box-shadow: 0 8px 20px rgb(18 104 245 / 22%); }
.cookie-button--primary:hover { border-color: #0759e8; box-shadow: 0 10px 25px rgb(18 104 245 / 30%); }
.cookie-settings-link { padding: 0; border: 0; color: inherit; background: transparent; font: inherit; text-decoration: underline; text-decoration-color: rgb(255 255 255 / 32%); text-underline-offset: 3px; cursor: pointer; }
.cookie-dialog { width: min(560px,calc(100vw - 28px)); max-width: none; max-height: min(88dvh,760px); margin: auto; padding: 0; overflow: auto; border: 1px solid rgb(220 230 244 / 90%); border-radius: 28px; color: #15243a; background: #fff; box-shadow: 0 40px 130px rgb(1 12 31 / 35%); }
.cookie-dialog::backdrop { background: rgb(3 12 28 / 60%); backdrop-filter: blur(8px); animation: cookie-fade .2s ease both; }
.cookie-dialog[open] { animation: cookie-pop .32s cubic-bezier(.16,1,.3,1) both; }
.cookie-dialog__inner { position: relative; padding: clamp(23px,5vw,34px); }
.cookie-dialog__inner::before { position: absolute; top: -105px; right: -82px; z-index: 0; width: 210px; height: 210px; border-radius: 50%; background: rgb(18 104 245 / 12%); content: ""; filter: blur(36px); pointer-events: none; }
.cookie-dialog__top,.cookie-dialog__heading,.cookie-category,.cookie-dialog__actions { position: relative; z-index: 1; }
.cookie-dialog__top { display: flex; align-items: center; justify-content: space-between; gap: 14px; margin-bottom: 24px; }
.cookie-dialog__eyebrow { display: inline-flex; align-items: center; gap: 8px; color: #1268f5; font-size: 10px; font-weight: 800; letter-spacing: .12em; text-transform: uppercase; }
.cookie-dialog__eyebrow::before { width: 18px; height: 1px; background: currentColor; content: ""; }
.cookie-dialog__close { display: grid; width: 38px; height: 38px; place-items: center; border: 1px solid #e2eaf5; border-radius: 50%; color: #4d5d73; background: #fff; font-size: 20px; cursor: pointer; }
.cookie-dialog__close:hover { color: #1268f5; background: #f3f7ff; }
.cookie-dialog__heading h2 { margin: 0 0 9px; color: #101827; font-size: clamp(25px,5vw,34px); line-height: 1.07; letter-spacing: -.055em; }
.cookie-dialog__heading p { max-width: 460px; margin: 0; color: #66758b; font-size: 13px; line-height: 1.65; }
.cookie-categories { display: grid; gap: 10px; margin: 22px 0; }
.cookie-category { display: grid; grid-template-columns: 40px minmax(0,1fr) auto; align-items: center; gap: 12px; padding: 13px 14px; border: 1px solid #e5ebf4; border-radius: 17px; background: linear-gradient(110deg,#fff,#fbfdff); }
.cookie-category__icon { display: grid; width: 38px; height: 38px; flex: none; place-items: center; border: 1px solid #dce9ff; border-radius: 12px; color: #1268f5; background: linear-gradient(145deg,#edf5ff,#fff); box-shadow: 0 5px 18px rgb(28 98 205 / 9%); }
.cookie-category__copy strong { display: block; margin-bottom: 2px; color: #203049; font-size: 12px; }
.cookie-category__copy span { display: block; color: #79879b; font-size: 10px; line-height: 1.45; }
.cookie-category__state { padding: 6px 9px; border: 1px solid #d9e8ff; border-radius: 99px; color: #1268f5; background: #f1f6ff; font-size: 9px; font-weight: 800; white-space: nowrap; }
.cookie-category--locked { opacity: .75; }
.cookie-toggle { position: relative; width: 42px; height: 24px; margin: 0; appearance: none; border: 1px solid #c9d4e2; border-radius: 999px; background: #e9eef5; cursor: pointer; transition: border-color .2s ease,background .2s ease,box-shadow .2s ease; }
.cookie-toggle::after { position: absolute; top: 3px; left: 3px; width: 16px; height: 16px; border-radius: 50%; background: #fff; box-shadow: 0 1px 4px rgb(10 24 44 / 22%); content: ""; transition: transform .2s cubic-bezier(.16,1,.3,1); }
.cookie-toggle:checked { border-color: #1268f5; background: #1268f5; }
.cookie-toggle:checked::after { transform: translateX(18px); }
.cookie-toggle:focus-visible { outline: 3px solid rgb(18 104 245 / 26%); outline-offset: 3px; }
.cookie-dialog__note { position: relative; z-index: 1; margin: -6px 0 19px; padding: 12px 14px; border-radius: 13px; color: #52627a; background: #f4f7fc; font-size: 11px; line-height: 1.55; }
.cookie-dialog__note strong { color: #233852; }
.cookie-dialog__actions { display: flex; flex-wrap: wrap; justify-content: flex-end; gap: 9px; }
.cookie-dialog__actions .cookie-button { min-height: 45px; }
@keyframes cookie-rise { from { opacity: 0; transform: translateY(20px) scale(.985); } to { opacity: 1; transform: none; } }
@keyframes cookie-pop { from { opacity: 0; transform: translateY(12px) scale(.97); } to { opacity: 1; transform: none; } }
@keyframes cookie-fade { from { opacity: 0; } to { opacity: 1; } }
@media (max-width: 620px) {
  .cookie-banner { bottom: max(12px,env(safe-area-inset-bottom)); width: calc(100% - 24px); grid-template-columns: minmax(0,1fr); gap: 14px; padding: 17px; border-radius: 20px; }
  .cookie-banner__copy { grid-template-columns: 37px minmax(0,1fr); gap: 11px; }
  .cookie-banner__icon { width: 37px; height: 37px; border-radius: 12px; }
  .cookie-banner__title { font-size: 14px; }
  .cookie-banner__text { font-size: 11px; }
  .cookie-banner__actions { grid-template-columns: 1fr 1fr; gap: 8px; }
  .cookie-banner__actions .cookie-button { min-width: 0; min-height: 43px; padding-inline: 10px; font-size: 10px; white-space: normal; }
  .cookie-banner__actions .cookie-button--primary { grid-column: 1 / -1; grid-row: 1; }
  .cookie-dialog { width: calc(100vw - 22px); border-radius: 23px; }
  .cookie-category { grid-template-columns: 36px minmax(0,1fr); gap: 10px; padding: 11px; }
  .cookie-category__icon { width: 36px; height: 36px; }
  .cookie-category__state { grid-column: 2; justify-self: start; margin-top: -4px; }
  .cookie-dialog__actions { display: grid; grid-template-columns: 1fr; }
  .cookie-dialog__actions .cookie-button { width: 100%; }
}
@media (prefers-reduced-motion: reduce) {
  .cookie-banner,.cookie-dialog,.cookie-dialog::backdrop { animation-duration: .01ms !important; }
  .cookie-button { transition-duration: .01ms !important; }
}
