/**
 * Soft cookie bar — balanced UX (readable, not intrusive).
 * Bottom-left card; equal-height buttons; host theme colors.
 * Fallback primary = brand green (80 174 97), never Tailwind blue.
 *
 * Spec (docs/UE_CONSENT_BLOG_FORUM.md → UX):
 * - width ~22rem, readable 13px body
 * - column: copy → two equal buttons
 * - admin: not loaded
 */
.ue-consent-root {
  --ue-c-bg: var(--ue-theme-bg, #ffffff);
  --ue-c-fg: var(--ue-theme-fg, var(--typo-body-color, #1f2937));
  --ue-c-muted: color-mix(in srgb, var(--ue-c-fg) 78%, transparent);
  --ue-c-border: color-mix(in srgb, var(--ue-c-fg) 14%, transparent);
  --ue-c-primary: var(--ue-theme-primary, rgb(var(--color-primary-500, 80 174 97)));
  --ue-c-primary-fg: var(--ue-theme-primary-fg, #ffffff);
  position: fixed;
  z-index: 2147483000;
  left: 1rem;
  right: auto;
  bottom: 1rem;
  width: min(22rem, calc(100vw - 2rem));
  max-width: 22rem;
  margin: 0;
  pointer-events: none;
}

.ue-consent-bar {
  pointer-events: auto;
  display: flex;
  flex-direction: column;
  align-items: stretch;
  gap: 0.75rem;
  padding: 0.875rem 1rem;
  border-radius: 0.75rem;
  border: 1px solid var(--ue-c-border);
  background: color-mix(in srgb, var(--ue-c-bg) 96%, transparent);
  color: var(--ue-c-fg);
  box-shadow: 0 10px 28px color-mix(in srgb, #000 20%, transparent);
  backdrop-filter: blur(10px);
  font-size: 0.8125rem; /* 13px — okunabilir alt sınır */
  line-height: 1.45;
  font-family: var(--font-body, var(--font-general, system-ui, sans-serif));
}

.ue-consent-bar p {
  margin: 0;
  color: var(--ue-c-muted);
}

.ue-consent-bar a {
  color: var(--ue-c-primary);
  text-decoration: underline;
  text-underline-offset: 2px;
  font-weight: 500;
}

.ue-consent-actions {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0.5rem;
  margin: 0;
  width: 100%;
}

.ue-consent-btn {
  appearance: none;
  box-sizing: border-box;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 100%;
  min-height: 2.25rem; /* eşit yükseklik */
  margin: 0;
  border-radius: 0.5rem;
  border: 1px solid var(--ue-c-border);
  background: transparent;
  color: var(--ue-c-fg);
  padding: 0.5rem 0.65rem;
  font-size: 0.75rem; /* 12px — buton etiketi */
  font-weight: 600;
  line-height: 1.2;
  text-align: center;
  cursor: pointer;
  white-space: normal;
}

.ue-consent-btn:hover {
  border-color: color-mix(in srgb, var(--ue-c-primary) 50%, var(--ue-c-border));
  color: var(--ue-c-primary);
}

.ue-consent-btn--primary {
  background: var(--ue-c-primary);
  border-color: var(--ue-c-primary);
  color: var(--ue-c-primary-fg);
}

.ue-consent-btn--primary:hover {
  filter: brightness(1.06);
  color: var(--ue-c-primary-fg);
}

html.dark .ue-consent-root,
.dark .ue-consent-root {
  --ue-c-bg: var(--ue-theme-bg, #1c2128);
  --ue-c-fg: var(--ue-theme-fg, var(--typo-body-color, #e8edf2));
}

@media (prefers-color-scheme: dark) {
  :root:not(.light):not([data-theme='light']) .ue-consent-root {
    --ue-c-bg: var(--ue-theme-bg, #1c2128);
    --ue-c-fg: var(--ue-theme-fg, var(--typo-body-color, #e8edf2));
  }
}

@media (max-width: 380px) {
  .ue-consent-root {
    left: 0.75rem;
    bottom: 0.75rem;
    width: calc(100vw - 1.5rem);
    max-width: none;
  }
}
