/* ==========================================================================
   Cookie Consent Banner
   Minimal GDPR-ready banner — slides up from bottom, glass card style.
   ========================================================================== */

@keyframes cookie-slide-in {
  from { transform: translateX(-50%) translateY(calc(100% + 2rem)); opacity: 0; }
  to   { transform: translateX(-50%) translateY(0); opacity: 1; }
}

@keyframes cookie-slide-out {
  from { transform: translateX(-50%) translateY(0); opacity: 1; }
  to   { transform: translateX(-50%) translateY(calc(100% + 2rem)); opacity: 0; }
}

.cookie-banner {
  position: fixed;
  bottom: 1.5rem;
  left: 50%;
  transform: translateX(-50%);
  z-index: 2000;
  max-width: 580px;
  width: max-content;
  display: flex;
  align-items: center;
  gap: 1rem;
  padding: 0.85rem 1.25rem;
  background: var(--bg-card);
  backdrop-filter: var(--glass-blur);
  -webkit-backdrop-filter: var(--glass-blur);
  border: var(--glass-border);
  border-radius: var(--radius-pill);
  box-shadow: 0 8px 32px rgba(0, 0, 0, 0.15);
  animation: cookie-slide-in 0.5s ease-out both;
}

.cookie-banner__text {
  font-size: 0.82rem;
  color: var(--text-primary);
  line-height: 1.4;
  white-space: nowrap;
}

.cookie-banner__actions {
  display: flex;
  gap: 0.5rem;
  flex-shrink: 0;
}

.cookie-banner__btn {
  padding: 0.4rem 1rem;
  font-size: 0.78rem;
  font-weight: 600;
  border-radius: var(--radius-pill);
  cursor: pointer;
  border: none;
  transition: opacity 0.2s, background 0.2s;
  font-family: inherit;
  line-height: 1;
}

.cookie-banner__btn:hover {
  opacity: 0.85;
}

.cookie-banner__btn--accept {
  background: var(--accent-primary);
  color: #fff;
}

.cookie-banner__btn--decline {
  background: transparent;
  color: var(--text-muted);
  border: 1px solid var(--text-muted);
}

/* Exit animation */
.cookie-banner.hiding {
  animation: cookie-slide-out 0.4s ease-in forwards;
}

/* ---- Mobile ---- */
@media (max-width: 600px) {
  @keyframes cookie-slide-in-mobile {
    from { transform: translateY(calc(100% + 2rem)); opacity: 0; }
    to   { transform: translateY(0); opacity: 1; }
  }

  @keyframes cookie-slide-out-mobile {
    from { transform: translateY(0); opacity: 1; }
    to   { transform: translateY(calc(100% + 2rem)); opacity: 0; }
  }

  .cookie-banner {
    left: 1rem;
    right: 1rem;
    transform: none;
    width: auto;
    max-width: none;
    flex-wrap: wrap;
    justify-content: center;
    border-radius: var(--radius);
    animation-name: cookie-slide-in-mobile;
  }

  .cookie-banner__text {
    white-space: normal;
    text-align: center;
    flex: 1 1 100%;
  }

  .cookie-banner.hiding {
    animation-name: cookie-slide-out-mobile;
  }
}
