.cookie-consent {
  position: fixed;
  right: 20px;
  bottom: 20px;
  z-index: 1000;
  width: min(520px, calc(100vw - 40px));
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  color: #102536;
}

.cookie-consent__panel {
  max-height: min(680px, calc(100vh - 40px));
  overflow: auto;
  border: 1px solid rgba(219, 231, 238, 0.95);
  border-radius: 28px;
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.99), rgba(244, 251, 251, 0.98));
  box-shadow: 0 26px 70px rgba(11, 47, 74, 0.22);
}

.cookie-consent__header {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr) auto;
  gap: 14px;
  align-items: flex-start;
  border-bottom: 1px solid rgba(219, 231, 238, 0.9);
  padding: 18px;
}

.cookie-consent__icon {
  display: grid;
  place-items: center;
  width: 46px;
  height: 46px;
  border-radius: 18px;
  background: #dff4f1;
  color: #1f6398;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.75);
}

.cookie-consent__icon svg {
  width: 22px;
  height: 22px;
  stroke: currentColor;
  stroke-linecap: round;
  stroke-linejoin: round;
  stroke-width: 1.8;
}

.cookie-consent h2,
.cookie-consent h3,
.cookie-consent p {
  margin: 0;
  letter-spacing: 0;
}

.cookie-consent h2 {
  color: #0b2f4a;
  font-size: 18px;
  line-height: 1.2;
  font-weight: 900;
}

.cookie-consent h3 {
  color: #0b2f4a;
  font-size: 14px;
  line-height: 1.25;
  font-weight: 900;
}

.cookie-consent p {
  margin-top: 7px;
  color: #617385;
  font-size: 14px;
  line-height: 1.55;
}

.cookie-consent__close {
  display: inline-grid;
  place-items: center;
  width: 36px;
  height: 36px;
  border: 1px solid #dbe7ee;
  border-radius: 50%;
  background: #ffffff;
  color: #617385;
  font-size: 16px;
  font-weight: 900;
  line-height: 1;
  cursor: pointer;
}

.cookie-consent__categories {
  display: grid;
  gap: 10px;
  padding: 14px 18px 2px;
}

.cookie-consent__category {
  display: flex;
  gap: 14px;
  align-items: flex-start;
  justify-content: space-between;
  border: 1px solid #dbe7ee;
  border-radius: 20px;
  background: #fbfdff;
  padding: 13px 14px;
}

.cookie-consent__category--toggle {
  cursor: pointer;
}

.cookie-consent__badge {
  flex: 0 0 auto;
  border-radius: 999px;
  background: #dff4f1;
  color: #123f62;
  padding: 6px 10px;
  font-size: 12px;
  font-weight: 900;
  white-space: nowrap;
}

.cookie-consent input[type="checkbox"] {
  flex: 0 0 auto;
  width: 22px;
  height: 22px;
  margin: 1px 0 0;
  accent-color: #1f6398;
}

.cookie-consent__actions {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
  padding: 16px 18px 12px;
}

.cookie-consent__button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 44px;
  border-radius: 999px;
  padding: 10px 16px;
  font-size: 14px;
  font-weight: 900;
  line-height: 1.2;
  text-align: center;
  cursor: pointer;
  transition:
    transform 180ms ease,
    background 180ms ease,
    border-color 180ms ease,
    box-shadow 180ms ease;
}

.cookie-consent__button:hover {
  transform: translateY(-1px);
}

.cookie-consent__button--primary {
  border: 1px solid #1f6398;
  background: #1f6398;
  color: #ffffff;
  box-shadow: 0 16px 34px rgba(31, 99, 152, 0.22);
}

.cookie-consent__button--primary:hover {
  background: #184f7a;
}

.cookie-consent__button--secondary {
  border: 1px solid rgba(31, 99, 152, 0.22);
  background: #ffffff;
  color: #1f6398;
}

.cookie-consent__button--secondary:hover {
  border-color: #1f6398;
}

.cookie-consent__links {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  padding: 0 18px 18px;
  color: #617385;
  font-size: 13px;
}

.cookie-consent__links a {
  color: #1f6398;
  font-weight: 850;
  text-decoration: underline;
  text-underline-offset: 3px;
}

@media (max-width: 640px) {
  .cookie-consent {
    right: 12px;
    bottom: 12px;
    width: calc(100vw - 24px);
  }

  .cookie-consent__panel {
    max-height: min(78vh, 620px);
    border-radius: 22px;
  }

  .cookie-consent__header {
    grid-template-columns: minmax(0, 1fr) auto;
    gap: 10px;
    padding: 15px;
  }

  .cookie-consent__icon {
    display: none;
  }

  .cookie-consent h2 {
    font-size: 16px;
  }

  .cookie-consent p {
    font-size: 13px;
    line-height: 1.45;
  }

  .cookie-consent__categories {
    padding: 12px 14px 2px;
  }

  .cookie-consent__category {
    border-radius: 17px;
    padding: 12px;
  }

  .cookie-consent__actions {
    grid-template-columns: 1fr;
    padding: 14px;
  }

  .cookie-consent__button {
    min-height: 42px;
  }

  .cookie-consent__links {
    padding: 0 14px 14px;
  }
}
