:root {
  --ct-consent-overlay: rgba(26, 30, 38, 0.42);
  --ct-consent-surface: #ffffff;
  --ct-consent-surface-soft: #f5f5f5;
  --ct-consent-border: #ded7cd;
  --ct-consent-text: #3c3228;
  --ct-consent-muted: #6b645c;
  --ct-consent-blue: #003882;
  --ct-consent-blue-soft: #e8eef8;
  --ct-consent-gray: #a9a9a9;
  --ct-consent-shadow: 0 24px 60px rgba(20, 27, 36, 0.18);
}

body.ct-consent-locked {
  overflow: hidden;
}

.ct-consent-modal {
  position: fixed;
  inset: 0;
  z-index: 99999;
  display: none;
}

.ct-consent-modal.is-open {
  display: block;
}

.ct-consent-backdrop {
  position: absolute;
  inset: 0;
  background: var(--ct-consent-overlay);
}

.ct-consent-dialog {
  position: relative;
  z-index: 1;
  width: min(920px, calc(100vw - 32px));
  max-height: calc(100vh - 32px);
  margin: 16px auto;
  overflow: auto;
  border: 1px solid rgba(255, 255, 255, 0.4);
  border-radius: 24px;
  background: var(--ct-consent-surface);
  box-shadow: var(--ct-consent-shadow);
}

.ct-consent-view {
  display: none;
  padding: 32px;
}

.ct-consent-view.is-active {
  display: block;
}

.ct-consent-eyebrow {
  margin: 0 0 12px;
  color: var(--ct-consent-blue);
  font-size: 13px;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.ct-consent-title {
  margin: 0;
  color: var(--ct-consent-text);
  font-family: "Fira Sans", sans-serif;
  font-size: 33px;
  line-height: 50px;
}

.ct-consent-description {
  margin: 16px 0 0;
  color: var(--ct-consent-muted);
  font-size: 16px;
  line-height: 1.7;
}

.ct-consent-note {
  margin: 18px 0 0;
  color: var(--ct-consent-text);
  font-size: 16px;
  line-height: 1.7;
}

.ct-consent-actions {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 12px;
  margin-top: 28px;
}

.ct-consent-actions--settings {
  margin-top: 24px;
}

.ct-consent-button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 52px;
  padding: 0 18px;
  border: 1px solid var(--ct-consent-border);
  border-radius: 14px;
  background: var(--ct-consent-surface);
  color: var(--ct-consent-text);
  font-size: 16px;
  font-weight: 700;
  text-align: center;
  cursor: pointer;
  transition: border-color 0.18s ease, background-color 0.18s ease, color 0.18s ease;
}

.ct-consent-button:hover,
.ct-consent-button:focus-visible {
  border-color: var(--ct-consent-blue);
  background: var(--ct-consent-blue-soft);
  color: var(--ct-consent-blue);
  outline: none;
}

.ct-consent-text-link {
  padding: 0;
  border: 0;
  background: transparent;
  color: var(--ct-consent-blue);
  font: inherit;
  font-weight: 700;
  text-decoration: underline;
  cursor: pointer;
}

.ct-consent-text-link:focus-visible,
.ct-consent-switch input:focus-visible + .ct-consent-switch__slider {
  outline: 2px solid var(--ct-consent-blue);
  outline-offset: 2px;
}

.ct-consent-legal-links {
  display: flex;
  flex-wrap: wrap;
  gap: 16px;
  margin-top: 20px;
  font-size: 16px;
  line-height: 1.7;
}

.ct-consent-settings-head {
  padding-right: 56px;
}

.ct-consent-service-list {
  display: grid;
  gap: 14px;
  margin-top: 26px;
}

.ct-consent-service {
  border: 1px solid var(--ct-consent-border);
  border-radius: 18px;
  background: var(--ct-consent-surface-soft);
  overflow: hidden;
}

.ct-consent-service__top {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 18px;
  align-items: start;
  padding: 22px;
}

.ct-consent-service__meta {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 12px;
}

.ct-consent-chip,
.ct-consent-badge {
  display: inline-flex;
  align-items: center;
  min-height: 28px;
  padding: 0 10px;
  border-radius: 999px;
  font-size: 12px;
  font-weight: 700;
}

.ct-consent-chip {
  background: var(--ct-consent-blue-soft);
  color: var(--ct-consent-blue);
}

.ct-consent-badge {
  background: #ece8de;
  color: var(--ct-consent-text);
}

.ct-consent-service__title {
  margin: 0;
  color: var(--ct-consent-text);
  font-family: "Fira Sans", sans-serif;
  font-size: 25px;
  line-height: 36px;
}

.ct-consent-service__description {
  margin: 10px 0 0;
  color: var(--ct-consent-muted);
  font-size: 16px;
  line-height: 1.7;
}

.ct-consent-service__actions {
  padding: 0 22px 18px;
}

.ct-consent-switch {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  color: var(--ct-consent-muted);
  font-size: 14px;
  font-weight: 700;
  white-space: nowrap;
}

.ct-consent-switch input {
  position: absolute;
  opacity: 0;
  pointer-events: none;
}

.ct-consent-switch__state {
  min-width: 44px;
  text-align: right;
}

.ct-consent-switch__slider {
  position: relative;
  width: 58px;
  height: 32px;
  border-radius: 999px;
  background: #cbc4b7;
  transition: background-color 0.18s ease;
}

.ct-consent-switch__slider::after {
  content: "";
  position: absolute;
  top: 4px;
  left: 4px;
  width: 24px;
  height: 24px;
  border-radius: 50%;
  background: #ffffff;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.18);
  transition: transform 0.18s ease;
}

.ct-consent-switch input:checked + .ct-consent-switch__slider {
  background: var(--ct-consent-blue);
}

.ct-consent-switch input:checked + .ct-consent-switch__slider::after {
  transform: translateX(26px);
}

.ct-consent-switch input:disabled + .ct-consent-switch__slider {
  background: var(--ct-consent-gray);
  opacity: 0.85;
}

.ct-consent-service__details {
  padding: 0 22px 22px;
  border-top: 1px solid var(--ct-consent-border);
}

.ct-consent-detail-list {
  display: grid;
  gap: 14px;
  margin: 18px 0 0;
}

.ct-consent-detail-list div {
  display: grid;
  grid-template-columns: minmax(170px, 210px) minmax(0, 1fr);
  gap: 4px 16px;
  align-items: start;
}

.ct-consent-detail-list dt {
  color: var(--ct-consent-text);
  font-weight: 700;
  word-break: normal;
  overflow-wrap: normal;
  hyphens: manual;
}

.ct-consent-detail-list dd {
  margin: 0;
  color: var(--ct-consent-muted);
  font-size: 16px;
  line-height: 1.7;
  min-width: 0;
}

.footer .menu-footer-container #menu-item-consent {
  float: right;
  clear: right;
}

@media (max-width: 820px) {
  .ct-consent-dialog {
    width: min(100vw - 20px, 920px);
    max-height: calc(100vh - 20px);
    margin: 10px auto;
  }

  .ct-consent-view {
    padding: 24px 18px;
  }

  .ct-consent-title {
    font-size: 33px;
    line-height: 50px;
  }

  .ct-consent-actions {
    grid-template-columns: 1fr;
  }

  .ct-consent-service__top {
    grid-template-columns: 1fr;
  }

  .ct-consent-switch {
    justify-content: space-between;
  }

  .ct-consent-detail-list div {
    grid-template-columns: 1fr;
    gap: 4px;
  }
}
