:root {
  --hp-consent-navy: #0c2344;
  --hp-consent-navy-soft: #17375f;
  --hp-consent-red: #dc2f3b;
  --hp-consent-white: #ffffff;
  --hp-consent-text: #17233a;
  --hp-consent-muted: #58657a;
  --hp-consent-line: #d9e0ea;
  --hp-consent-surface: rgba(255, 255, 255, 0.98);
  --hp-consent-focus: #5aa9ff;
}

.hp-consent,
.hp-consent * {
  box-sizing: border-box;
}

.hp-consent {
  position: relative;
  z-index: 2147483000;
  font-family: Inter, -apple-system, BlinkMacSystemFont, "Segoe UI", Arial, sans-serif;
  color: var(--hp-consent-text);
}

.hp-consent__panel {
  position: fixed;
  left: 50%;
  bottom: max(20px, env(safe-area-inset-bottom));
  width: min(760px, calc(100vw - 32px));
  max-height: min(84vh, 720px);
  overflow: auto;
  transform: translateX(-50%);
  padding: 24px;
  border: 1px solid rgba(12, 35, 68, 0.13);
  border-radius: 20px;
  background: var(--hp-consent-surface);
  box-shadow: 0 22px 64px rgba(5, 18, 37, 0.28);
  backdrop-filter: blur(18px);
  -webkit-backdrop-filter: blur(18px);
}

.hp-consent__panel[hidden],
.hp-consent__details[hidden],
.hp-consent [hidden] {
  display: none !important;
}

.hp-consent__brand {
  display: flex;
  align-items: center;
  gap: 9px;
  margin-bottom: 12px;
  color: var(--hp-consent-navy);
  font-size: 12px;
  font-weight: 800;
  letter-spacing: 0.16em;
  text-transform: uppercase;
}

.hp-consent__brand span {
  display: inline-block;
  width: 26px;
  height: 3px;
  border-radius: 999px;
  background: var(--hp-consent-red);
}

.hp-consent h2 {
  margin: 0 38px 10px 0;
  color: var(--hp-consent-navy);
  font-size: clamp(22px, 3vw, 30px);
  line-height: 1.15;
}

.hp-consent__panel > p {
  margin: 0;
  color: var(--hp-consent-muted);
  font-size: 15px;
  line-height: 1.62;
}

.hp-consent__privacy {
  margin-top: 10px !important;
}

.hp-consent__privacy a {
  color: var(--hp-consent-navy);
  font-weight: 700;
  text-underline-offset: 3px;
}

.hp-consent__close {
  position: absolute;
  top: 15px;
  right: 15px;
  width: 44px;
  height: 44px;
  border: 0;
  border-radius: 50%;
  background: #edf1f6;
  color: var(--hp-consent-navy);
  font: inherit;
  font-size: 26px;
  cursor: pointer;
}

.hp-consent__details {
  display: grid;
  gap: 10px;
  margin-top: 18px;
}

.hp-consent__category {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  min-height: 88px;
  padding: 16px;
  border: 1px solid var(--hp-consent-line);
  border-radius: 14px;
  background: #f7f9fc;
}

.hp-consent__category strong {
  display: block;
  margin-bottom: 5px;
  color: var(--hp-consent-navy);
  font-size: 15px;
}

.hp-consent__category p {
  margin: 0;
  color: var(--hp-consent-muted);
  font-size: 13px;
  line-height: 1.45;
}

.hp-consent__state {
  flex: 0 0 auto;
  padding: 8px 11px;
  border-radius: 999px;
  background: #e9eef5;
  color: var(--hp-consent-navy-soft);
  font-size: 12px;
  font-weight: 800;
  white-space: nowrap;
}

.hp-consent__switch {
  position: relative;
  display: grid;
  justify-items: center;
  gap: 4px;
  flex: 0 0 74px;
  cursor: pointer;
}

.hp-consent__switch input {
  position: absolute;
  width: 1px;
  height: 1px;
  opacity: 0;
}

.hp-consent__switch i {
  position: relative;
  display: block;
  width: 48px;
  height: 28px;
  border-radius: 999px;
  background: #aeb9c8;
  transition: background 160ms ease;
}

.hp-consent__switch i::after {
  content: "";
  position: absolute;
  top: 4px;
  left: 4px;
  width: 20px;
  height: 20px;
  border-radius: 50%;
  background: var(--hp-consent-white);
  box-shadow: 0 2px 6px rgba(5, 18, 37, 0.25);
  transition: transform 160ms ease;
}

.hp-consent__switch input:checked + i {
  background: var(--hp-consent-navy);
}

.hp-consent__switch input:checked + i::after {
  transform: translateX(20px);
}

.hp-consent__switch b {
  color: var(--hp-consent-muted);
  font-size: 10px;
}

.hp-consent__actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 10px;
  margin-top: 20px;
}

.hp-consent__button,
.hp-consent__link,
.hp-consent__reopen {
  min-height: 44px;
  border-radius: 11px;
  font: inherit;
  font-size: 13px;
  font-weight: 750;
  cursor: pointer;
}

.hp-consent__button {
  padding: 11px 16px;
  border: 1px solid var(--hp-consent-line);
  background: var(--hp-consent-white);
  color: var(--hp-consent-navy);
}

.hp-consent__button--choice {
  flex: 1 1 230px;
  border-color: var(--hp-consent-navy);
}

.hp-consent__button--choice:hover {
  background: #edf1f6;
}

.hp-consent__button--primary {
  border-color: var(--hp-consent-navy);
  background: var(--hp-consent-navy);
  color: var(--hp-consent-white);
}

.hp-consent__button--primary:hover {
  background: var(--hp-consent-navy-soft);
}

.hp-consent__link {
  padding: 10px 5px;
  border: 0;
  background: transparent;
  color: var(--hp-consent-navy);
  text-decoration: underline;
  text-underline-offset: 3px;
}

.hp-consent__reopen {
  position: fixed;
  left: 16px;
  bottom: max(16px, env(safe-area-inset-bottom));
  padding: 10px 14px;
  border: 1px solid rgba(255, 255, 255, 0.24);
  background: rgba(12, 35, 68, 0.94);
  color: var(--hp-consent-white);
  box-shadow: 0 8px 24px rgba(5, 18, 37, 0.22);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
}

.hp-consent button:focus-visible,
.hp-consent a:focus-visible,
.hp-consent input:focus-visible + i {
  outline: 3px solid var(--hp-consent-focus);
  outline-offset: 3px;
}

@media (max-width: 640px) {
  .hp-consent__panel {
    bottom: max(10px, env(safe-area-inset-bottom));
    width: calc(100vw - 20px);
    padding: 19px;
    border-radius: 16px;
  }

  .hp-consent__category {
    align-items: flex-start;
    gap: 12px;
  }

  .hp-consent__actions {
    display: grid;
    grid-template-columns: 1fr;
  }

  .hp-consent__button,
  .hp-consent__link {
    width: 100%;
    text-align: center;
  }
}

@media (prefers-reduced-motion: reduce) {
  .hp-consent *,
  .hp-consent *::before,
  .hp-consent *::after {
    scroll-behavior: auto !important;
    transition: none !important;
  }
}
