/* Mannavilla cookie consent — matches site palette (purple / gold) */
.cookie-consent {
  --cc-primary: #5b0161;
  --cc-primary-dark: #3f0043;
  --cc-accent: #eed279;
  --cc-accent-soft: rgba(238, 210, 121, 0.35);
  --cc-surface: rgba(255, 255, 255, 0.92);
  --cc-text: #14051d;
  --cc-muted: #6c757d;
  --cc-radius: 20px;
  --cc-shadow: 0 -8px 40px rgba(20, 5, 29, 0.18), 0 0 0 1px rgba(91, 1, 97, 0.08);

  position: fixed;
  inset: 0;
  z-index: 10020;
  display: flex;
  align-items: flex-end;
  justify-content: center;
  padding: 16px;
  padding-bottom: max(20px, env(safe-area-inset-bottom, 20px));
  pointer-events: none;
  visibility: hidden;
}

.cookie-consent.cookie-consent--visible {
  pointer-events: auto;
  visibility: visible;
}

.cookie-consent__backdrop {
  position: absolute;
  inset: 0;
  background: linear-gradient(
    165deg,
    rgba(20, 5, 29, 0.45) 0%,
    rgba(91, 1, 97, 0.35) 50%,
    rgba(20, 5, 29, 0.5) 100%
  );
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  opacity: 0;
  transition: opacity 0.55s cubic-bezier(0.22, 1, 0.36, 1);
}

.cookie-consent--visible .cookie-consent__backdrop {
  opacity: 1;
}

.cookie-consent__panel {
  position: relative;
  width: min(640px, 100%);
  transform: translateY(calc(100% + 32px)) scale(0.96);
  opacity: 0;
  transition:
    transform 0.65s cubic-bezier(0.34, 1.3, 0.64, 1),
    opacity 0.45s ease;
  transition-delay: 0.05s;
}

.cookie-consent--visible .cookie-consent__panel {
  transform: translateY(0) scale(1);
  opacity: 1;
}

.cookie-consent__glow {
  position: absolute;
  top: -2px;
  left: 8%;
  right: 8%;
  height: 3px;
  border-radius: 3px;
  background: linear-gradient(
    90deg,
    transparent,
    var(--cc-accent),
    var(--cc-primary-light, #7a1f80),
    var(--cc-accent),
    transparent
  );
  background-size: 200% 100%;
  animation: cookie-consent-shimmer 4s ease-in-out infinite;
  opacity: 0.95;
  filter: blur(0.5px);
}

@keyframes cookie-consent-shimmer {
  0%,
  100% {
    background-position: 0% 50%;
  }
  50% {
    background-position: 100% 50%;
  }
}

.cookie-consent__inner {
  position: relative;
  background: var(--cc-surface);
  border-radius: var(--cc-radius);
  box-shadow: var(--cc-shadow);
  padding: 22px 22px 20px;
  border: 1px solid rgba(91, 1, 97, 0.12);
  overflow: hidden;
}

.cookie-consent__inner::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 120px;
  background: radial-gradient(
    ellipse 80% 100% at 50% 0%,
    var(--cc-accent-soft) 0%,
    transparent 70%
  );
  pointer-events: none;
}

.cookie-consent__row {
  position: relative;
  display: grid;
  grid-template-columns: auto 1fr;
  gap: 16px;
  align-items: start;
}

@media (max-width: 540px) {
  .cookie-consent__row {
    grid-template-columns: 1fr;
    text-align: center;
  }

  .cookie-consent__icon-wrap {
    margin: 0 auto;
  }
}

.cookie-consent__icon-wrap {
  width: 56px;
  height: 56px;
  border-radius: 16px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: linear-gradient(145deg, var(--cc-primary-dark), var(--cc-primary));
  box-shadow: 0 8px 24px rgba(91, 1, 97, 0.35);
  animation: cookie-consent-float 3.2s ease-in-out infinite;
}

@keyframes cookie-consent-float {
  0%,
  100% {
    transform: translateY(0);
  }
  50% {
    transform: translateY(-4px);
  }
}

.cookie-consent__icon-wrap svg {
  width: 30px;
  height: 30px;
  color: var(--cc-accent);
}

.cookie-consent__title {
  font-family: "Playfair Display", Georgia, serif;
  font-size: clamp(1.25rem, 3vw, 1.45rem);
  font-weight: 700;
  color: var(--cc-text);
  margin: 0 0 8px;
  letter-spacing: -0.02em;
  line-height: 1.25;
}

.cookie-consent__text {
  font-family: "Inter", system-ui, sans-serif;
  font-size: 0.9rem;
  line-height: 1.65;
  color: var(--cc-muted);
  margin: 0 0 18px;
}

.cookie-consent__text a {
  color: var(--cc-primary);
  font-weight: 600;
  text-decoration: none;
  border-bottom: 1px solid rgba(91, 1, 97, 0.25);
  transition: border-color 0.2s ease, color 0.2s ease;
}

.cookie-consent__text a:hover {
  color: var(--cc-primary-dark);
  border-bottom-color: var(--cc-accent);
}

.cookie-consent__actions {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  align-items: center;
}

@media (max-width: 540px) {
  .cookie-consent__actions {
    flex-direction: column;
    width: 100%;
  }

  .cookie-consent__actions .cookie-consent__btn {
    width: 100%;
    justify-content: center;
  }
}

.cookie-consent__btn {
  font-family: "Inter", system-ui, sans-serif;
  font-size: 0.875rem;
  font-weight: 600;
  padding: 12px 20px;
  border-radius: 12px;
  border: none;
  cursor: pointer;
  transition: transform 0.2s ease, box-shadow 0.2s ease, background 0.2s ease;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
}

.cookie-consent__btn:focus-visible {
  outline: 2px solid var(--cc-accent);
  outline-offset: 3px;
}

.cookie-consent__btn--primary {
  color: #fff;
  background: linear-gradient(135deg, var(--cc-primary) 0%, var(--cc-primary-dark) 100%);
  box-shadow: 0 4px 16px rgba(91, 1, 97, 0.35);
}

.cookie-consent__btn--primary:hover {
  transform: translateY(-1px);
  box-shadow: 0 6px 22px rgba(91, 1, 97, 0.42);
}

.cookie-consent__btn--ghost {
  color: var(--cc-text);
  background: rgba(91, 1, 97, 0.06);
  border: 1px solid rgba(91, 1, 97, 0.12);
}

.cookie-consent__btn--ghost:hover {
  background: rgba(91, 1, 97, 0.1);
  transform: translateY(-1px);
}

.cookie-consent__btn:active {
  transform: translateY(0);
}

.cookie-consent.cookie-consent--leaving .cookie-consent__backdrop {
  opacity: 0;
  transition-duration: 0.35s;
}

.cookie-consent.cookie-consent--leaving .cookie-consent__panel {
  transform: translateY(24px) scale(0.98);
  opacity: 0;
  transition: transform 0.4s cubic-bezier(0.4, 0, 1, 1), opacity 0.35s ease;
}

@media (prefers-reduced-motion: reduce) {
  .cookie-consent__backdrop,
  .cookie-consent__panel {
    transition-duration: 0.01ms !important;
  }

  .cookie-consent__glow,
  .cookie-consent__icon-wrap {
    animation: none !important;
  }
}
