/* PECR consent banner styles (Task 375). Brand overrides arrive as inline
 * CSS variables on :root from /consent.js after fetching /v/brand-config. */

:root {
  --mxy-consent-bg: #FFFFFF;
  --mxy-consent-fg: #1F1F1F;
  --mxy-consent-accent: #1F1F1F;
  --mxy-consent-accentFg: #FFFFFF;
  --mxy-consent-border: #E5E5E2;
}

#mxy-consent {
  position: fixed;
  left: 0;
  right: 0;
  bottom: 0;
  z-index: 2147483640;
  background: var(--mxy-consent-bg);
  color: var(--mxy-consent-fg);
  border-top: 1px solid var(--mxy-consent-border);
  box-shadow: 0 -8px 24px rgba(0, 0, 0, 0.06);
  font: 14px/1.45 -apple-system, BlinkMacSystemFont, "Segoe UI", system-ui, sans-serif;
  padding: 16px 20px env(safe-area-inset-bottom, 16px);
}

#mxy-consent .mxy-consent__inner {
  max-width: 1100px;
  margin: 0 auto;
  display: flex;
  gap: 24px;
  align-items: center;
  flex-wrap: wrap;
}

#mxy-consent .mxy-consent__text {
  flex: 1 1 320px;
  min-width: 240px;
}

#mxy-consent .mxy-consent__title {
  display: block;
  font-size: 15px;
  margin-bottom: 4px;
}

#mxy-consent .mxy-consent__body {
  margin: 0 0 6px 0;
  color: var(--mxy-consent-fg);
}

#mxy-consent .mxy-consent__link {
  color: var(--mxy-consent-fg);
  text-decoration: underline;
  font-size: 13px;
}

#mxy-consent .mxy-consent__actions {
  display: flex;
  gap: 10px;
  flex: 0 0 auto;
}

/* Accept and reject are equal-weighted per ICO guidance — same size,
 * same prominence. Reject is the outlined variant only because the
 * accent fill must indicate the active surface in monochrome palettes;
 * both buttons share padding, font-weight and minimum width. */

#mxy-consent .mxy-consent__btn {
  appearance: none;
  -webkit-appearance: none;
  border-radius: 6px;
  font: inherit;
  font-weight: 600;
  padding: 10px 18px;
  min-width: 96px;
  cursor: pointer;
  border: 1px solid var(--mxy-consent-accent);
  transition: opacity 120ms ease;
}

#mxy-consent .mxy-consent__btn:hover { opacity: 0.85; }
#mxy-consent .mxy-consent__btn:focus { outline: 2px solid var(--mxy-consent-accent); outline-offset: 2px; }

#mxy-consent .mxy-consent__btn--reject {
  background: var(--mxy-consent-bg);
  color: var(--mxy-consent-fg);
}

#mxy-consent .mxy-consent__btn--accept {
  background: var(--mxy-consent-accent);
  color: var(--mxy-consent-accentFg);
}

@media (max-width: 560px) {
  #mxy-consent .mxy-consent__actions { width: 100%; }
  #mxy-consent .mxy-consent__btn { flex: 1 1 0; }
}
