.ms-cookie-banner,
.ms-cookie-modal-overlay {
  font-family: "Open Sans", Arial, sans-serif;
}

.ms-cookie-banner {
  position: fixed;
  right: 24px;
  bottom: 24px;
  left: 24px;
  z-index: 99998;
  display: none;
  max-width: 1120px;
  margin: 0 auto;
  color: #f8fafc;
  background: #111827;
  border: 1px solid rgba(255, 255, 255, 0.14);
  border-radius: 18px;
  box-shadow: 0 24px 70px rgba(15, 23, 42, 0.35);
}

.ms-cookie-banner.is-visible,
.ms-cookie-modal-overlay.is-visible {
  display: block;
}

.ms-cookie-banner__inner {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 20px;
  align-items: center;
  padding: 22px;
}

.ms-cookie-banner__title {
  margin: 0 0 6px;
  color: #ffffff;
  font-size: 17px;
  font-weight: 700;
}

.ms-cookie-banner__text {
  margin: 0;
  color: #dbeafe;
  font-size: 14px;
  line-height: 1.6;
}

.ms-cookie-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  justify-content: flex-end;
}

.ms-cookie-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 42px;
  padding: 10px 16px;
  color: #ffffff;
  font-size: 14px;
  font-weight: 700;
  line-height: 1;
  background: transparent;
  border: 1px solid rgba(255, 255, 255, 0.28);
  border-radius: 999px;
  transition: 0.2s ease;
}

.ms-cookie-btn:hover,
.ms-cookie-btn:focus {
  color: #ffffff;
  border-color: #ffffff;
  outline: none;
  transform: translateY(-1px);
}

.ms-cookie-btn--primary {
  color: #111827;
  background: #ffffff;
  border-color: #ffffff;
}

.ms-cookie-btn--primary:hover,
.ms-cookie-btn--primary:focus {
  color: #111827;
}

.ms-cookie-btn--muted {
  color: #dbeafe;
}

.ms-cookie-link {
  padding: 0;
  color: inherit;
  font: inherit;
  text-decoration: underline;
  background: none;
  border: 0;
}

.ms-cookie-link:hover,
.ms-cookie-link:focus {
  color: #27247c;
  outline: none;
}

.ms-cookie-modal-overlay {
  position: fixed;
  inset: 0;
  z-index: 99999;
  display: none;
  padding: 24px;
  overflow-y: auto;
  background: rgba(15, 23, 42, 0.72);
}

.ms-cookie-modal {
  width: min(760px, 100%);
  margin: 7vh auto;
  color: #1f2937;
  background: #ffffff;
  border-radius: 20px;
  box-shadow: 0 28px 90px rgba(15, 23, 42, 0.38);
}

.ms-cookie-modal__header,
.ms-cookie-modal__footer {
  padding: 22px 24px;
  border-bottom: 1px solid #e5e7eb;
}

.ms-cookie-modal__footer {
  border-top: 1px solid #e5e7eb;
  border-bottom: 0;
}

.ms-cookie-modal__body {
  max-height: 58vh;
  padding: 6px 24px 20px;
  overflow-y: auto;
}

.ms-cookie-modal__title {
  margin: 0 0 6px;
  color: #1d2552;
  font-size: 24px;
  font-weight: 800;
}

.ms-cookie-modal__description {
  margin: 0;
  color: #5b657a;
  font-size: 14px;
  line-height: 1.6;
}

.ms-cookie-category {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 16px;
  padding: 18px 0;
  border-bottom: 1px solid #edf0f7;
}

.ms-cookie-category:last-child {
  border-bottom: 0;
}

.ms-cookie-category h3 {
  margin: 0 0 6px;
  color: #1d2552;
  font-size: 16px;
  font-weight: 800;
}

.ms-cookie-category p {
  margin: 0;
  color: #5b657a;
  font-size: 14px;
  line-height: 1.55;
}

.ms-cookie-switch {
  position: relative;
  width: 54px;
  height: 30px;
}

.ms-cookie-switch input {
  position: absolute;
  opacity: 0;
}

.ms-cookie-slider {
  position: absolute;
  inset: 0;
  cursor: pointer;
  background: #cbd5e1;
  border-radius: 999px;
  transition: 0.2s ease;
}

.ms-cookie-slider::before {
  position: absolute;
  top: 4px;
  left: 4px;
  width: 22px;
  height: 22px;
  content: "";
  background: #ffffff;
  border-radius: 50%;
  box-shadow: 0 2px 8px rgba(15, 23, 42, 0.18);
  transition: 0.2s ease;
}

.ms-cookie-switch input:checked + .ms-cookie-slider {
  background: #27247c;
}

.ms-cookie-switch input:checked + .ms-cookie-slider::before {
  transform: translateX(24px);
}

.ms-cookie-switch input:disabled + .ms-cookie-slider {
  cursor: not-allowed;
  background: #27247c;
  opacity: 0.75;
}

.ms-external-placeholder {
  padding: 24px;
  color: #1f2937;
  text-align: center;
  background: #f3f6ff;
  border: 1px dashed #a9b5d7;
  border-radius: 14px;
}

@media (max-width: 768px) {
  .ms-cookie-banner {
    right: 12px;
    bottom: 12px;
    left: 12px;
  }

  .ms-cookie-banner__inner,
  .ms-cookie-category {
    grid-template-columns: 1fr;
  }

  .ms-cookie-actions {
    justify-content: stretch;
  }

  .ms-cookie-btn {
    width: 100%;
  }

  .ms-cookie-modal-overlay {
    padding: 12px;
  }

  .ms-cookie-modal {
    margin: 4vh auto;
  }
}
