.cookie_banner {
  position: fixed;
  right: var(--page-gutter);
  bottom: var(--page-gutter);
  left: var(--page-gutter);
  z-index: 14000;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 28px;
  max-width: 1240px;
  margin-inline: auto;
  padding: 20px 22px;
  color: var(--black);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  background: rgba(var(--white-rgb), .98);
  box-shadow: var(--shadow-lg);
}

.cookie_banner[hidden],
.cookie_modal[hidden],
[data-cookie-category="external"][hidden],
[data-cookie-placeholder="external"][hidden] { display: none !important; }

.cookie_banner__copy { max-width: 690px; }
.cookie_banner__copy strong { display: block; margin-bottom: 6px; font-size: var(--font-size-lg); }
.cookie_banner__copy p { margin: 0 0 7px; color: var(--secondary); line-height: 1.5; }
.cookie_banner__copy a,
.cookie_modal__policy { color: var(--primary-dark); font-size: var(--font-size-sm); font-weight: 600; text-decoration: underline; text-underline-offset: 3px; }
.cookie_banner__actions,
.cookie_modal__actions { display: flex; flex-wrap: wrap; justify-content: flex-end; gap: 8px; }

.cookie_btn {
  min-height: var(--control-height);
  padding: 10px 16px;
  border: 1px solid var(--border-strong);
  border-radius: var(--radius-sm);
  font-size: var(--font-size-sm);
  font-weight: 700;
  cursor: pointer;
  transition: color var(--transition-fast), border-color var(--transition-fast), background var(--transition-fast);
}

.cookie_btn--primary { color: var(--white); border-color: var(--primary); background: var(--primary); }
.cookie_btn--primary:hover { background: var(--primary-dark); }
.cookie_btn--ghost { color: var(--black); background: var(--white); }
.cookie_btn--ghost:hover { color: var(--primary-dark); border-color: var(--primary); background: var(--primary-soft); }

.cookie_modal { position: fixed; inset: 0; z-index: 15000; display: grid; place-items: center; padding: 16px; }
.cookie_modal__overlay { position: absolute; inset: 0; background: rgba(var(--black-rgb), .48); backdrop-filter: blur(4px); }
.cookie_modal__dialog { position: relative; width: min(680px, 100%); max-height: calc(100vh - 32px); max-height: calc(100dvh - 32px); overflow-y: auto; padding: clamp(22px, 4vw, 34px); border-radius: var(--radius-lg); background: var(--white); box-shadow: var(--shadow-lg); }
.cookie_modal__dialog h2 { margin: 0 48px 10px 0; font-size: clamp(26px, 3vw, 36px); }
.cookie_modal__dialog > p:not(.section_eyebrow) { margin-bottom: 22px; color: var(--secondary); line-height: 1.55; }
.cookie_modal__close { position: absolute; top: 14px; right: 14px; width: 42px; height: 42px; color: var(--secondary); border: 0; border-radius: 50%; background: var(--surface-subtle); font-size: 28px; line-height: 1; cursor: pointer; }
.cookie_category { display: flex; align-items: center; justify-content: space-between; gap: 20px; padding: 17px 0; border-top: 1px solid var(--border); }
.cookie_category > div,
.cookie_category > span:first-child { display: grid; gap: 4px; }
.cookie_category span span,
.cookie_category div span { color: var(--secondary); font-size: var(--font-size-sm); line-height: 1.45; }
.cookie_required { flex: 0 0 auto; color: var(--muted); font-size: var(--font-size-xs); font-weight: 700; }
.cookie_category--control { cursor: pointer; }
.cookie_category--control input { width: 24px; height: 24px; flex: 0 0 auto; accent-color: var(--primary); }
.cookie_modal__actions { margin-top: 22px; }
.cookie_modal__policy { display: inline-block; margin-top: 18px; }
.body--cookie-open { overflow: hidden; }

.external_content_gate { display: grid; place-items: center; min-height: 100%; padding: 24px; text-align: center; background: var(--primary-soft); }
.external_content_gate__inner { max-width: 350px; }
.external_content_gate strong { display: block; margin-bottom: 7px; }
.external_content_gate p { margin: 0 0 14px; color: var(--secondary); font-size: var(--font-size-sm); line-height: 1.45; }
.external_content_gate a { display: inline-block; margin-top: 10px; font-size: var(--font-size-sm); text-decoration: underline; text-underline-offset: 3px; }

@media (max-width: 980px) {
  .cookie_banner { align-items: stretch; flex-direction: column; gap: 16px; }
  .cookie_banner__actions { justify-content: flex-start; }
}

@media (max-width: 560px) {
  .cookie_banner { max-height: calc(100vh - 24px); max-height: calc(100dvh - 24px); right: 12px; bottom: 12px; left: 12px; overflow-y: auto; padding: 17px; }
  .cookie_banner__actions,
  .cookie_modal__actions { display: grid; grid-template-columns: 1fr; }
  .cookie_category { align-items: flex-start; }
}
