@keyframes sua-cookie-in {
  from {
    opacity: 0;
    transform: translateY(16px) scale(0.975);
  }
  to {
    opacity: 1;
    transform: translateY(0) scale(1);
  }
}

@keyframes sua-cookie-out {
  from {
    opacity: 1;
    transform: translateY(0) scale(1);
    filter: blur(0);
  }
  to {
    opacity: 0;
    transform: translateY(12px) scale(0.97);
    filter: blur(3px);
  }
}

.cookie-notice {
  position: fixed;
  z-index: 40;
  inset-inline-end: max(18px, env(safe-area-inset-right));
  inset-block-end: max(18px, env(safe-area-inset-bottom));
  inline-size: min(23.5rem, calc(100% - 32px));
  max-block-size: calc(100dvh - 32px);
  overflow: hidden;
  padding: 18px 20px 16px;
  border: 1px solid rgba(184, 134, 47, 0.34);
  border-radius: 14px;
  background: linear-gradient(165deg, rgba(28, 30, 34, 0.96), rgba(17, 18, 21, 0.98));
  -webkit-backdrop-filter: blur(14px);
  backdrop-filter: blur(14px);
  color: var(--bone);
  box-shadow:
    0 22px 54px rgba(0, 0, 0, 0.52),
    inset 0 1px 0 rgba(255, 255, 255, 0.06);
  animation: sua-cookie-in 320ms cubic-bezier(0.16, 1, 0.3, 1) both;
}

.cookie-notice::before {
  content: '';
  position: absolute;
  inset: 0 20px auto;
  height: 1px;
  background: linear-gradient(90deg, transparent, rgba(217, 170, 82, 0.65), transparent);
  pointer-events: none;
}

.cookie-notice[hidden] {
  display: none;
}

.cookie-notice.is-closing {
  pointer-events: none;
  animation: sua-cookie-out 220ms cubic-bezier(0.4, 0, 1, 1) forwards;
}

.cookie-notice h2 {
  margin: 0;
  color: var(--bone);
  font: 700 1rem/1.25 'DM Sans', Arial, sans-serif;
  letter-spacing: -0.01em;
  text-transform: none;
}

.cookie-notice p {
  margin: 10px 0 15px;
  color: #c2beb5;
  font-size: 0.86rem;
  line-height: 1.55;
}

.cookie-notice-actions {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
}

.cookie-notice-actions button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 7px;
  min-block-size: 44px;
  padding: 9px 12px;
  border-radius: 8px;
  font-family: 'DM Sans', Arial, sans-serif;
  font-size: 0.83rem;
  font-weight: 700;
  line-height: 1.2;
  letter-spacing: 0.01em;
  cursor: pointer;
  overflow-wrap: anywhere;
  transition:
    background-color 150ms ease,
    border-color 150ms ease,
    color 150ms ease,
    transform 150ms cubic-bezier(0.16, 1, 0.3, 1);
}

.cookie-notice-actions button[data-cookie-choice='necessary'] {
  border: 1px solid #3c3f46;
  background: rgba(255, 255, 255, 0.04);
  color: #e2ded6;
}

.cookie-notice-actions button[data-cookie-choice='necessary']:hover {
  border-color: #5b5f68;
  background: rgba(255, 255, 255, 0.09);
  color: #ffffff;
}

.cookie-notice-actions button[data-cookie-choice='acknowledged'] {
  border: 1px solid transparent;
  background: var(--gold, #b8862f);
  color: #141517;
}

.cookie-notice-actions button[data-cookie-choice='acknowledged']:hover {
  background: #cb9940;
  transform: translateY(-1px);
}

.cookie-notice-actions button:active {
  transform: scale(0.97);
}

.cookie-notice-actions button.is-chosen {
  background: #d8a950;
  border-color: #d8a950;
  color: #141517;
  transform: scale(0.98);
}

.cookie-notice :focus-visible {
  outline: 2px solid var(--gold-highlight, #e0b35c);
  outline-offset: 2px;
}

.cookie-notice-foot {
  margin-top: 11px;
  padding-top: 10px;
  border-top: 1px solid rgba(255, 255, 255, 0.07);
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.cookie-notice-foot a {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  min-block-size: 28px;
  color: #d5ab5d;
  font-size: 0.8rem;
  font-weight: 500;
  text-decoration: none;
  transition: color 150ms ease;
}

.cookie-notice-foot a:hover {
  color: var(--bone);
}

/* Align cookie settings & photos buttons identically with sibling legal links in footer */
.legal-links [data-cookie-settings],
footer .legal-links [data-cookie-settings],
.legal-links [data-legal='photos'],
footer .legal-links [data-legal='photos'] {
  display: inline-flex;
  align-items: center;
  align-self: auto;
  min-height: 44px;
  padding: 5px 0;
  margin: 0;
  border: 0;
  background: transparent;
  color: #c5c1b8;
  font: 13px/1.4 'DM Sans', Arial, sans-serif;
  text-decoration: none;
  text-align: start;
  cursor: pointer;
  transition: color 150ms ease;
}

footer .legal-links [data-cookie-settings][hidden] {
  display: none;
}

.legal-links [data-cookie-settings]:hover,
footer .legal-links [data-cookie-settings]:hover,
.legal-links [data-legal='photos']:hover,
footer .legal-links [data-legal='photos']:hover {
  color: var(--gold-highlight, #e0b35c);
}

@media (max-width: 760px) {
  .cookie-notice {
    inset-inline: 14px;
    inset-block-end: max(14px, env(safe-area-inset-bottom));
    inline-size: auto;
    padding: 16px 16px 14px;
  }

  footer .legal-links [data-cookie-settings] {
    align-self: flex-start;
  }
}

@media (prefers-reduced-motion: reduce) {
  .cookie-notice,
  .cookie-notice.is-closing {
    animation: none !important;
  }
}
