/* Announcement Modal Styles */

:root {
  /* Fallbacks if brand tokens are missing */
  --announcement-backdrop: rgba(12, 35, 64, 0.6);
}

#announcement-modal {
  position: fixed;
  inset: 0;
  z-index: 10001; /* above floating widgets */
  display: none; /* toggled by JS */
  place-items: center;
  background: var(--announcement-backdrop);
  opacity: 0.7;
}

#announcement-modal.open {
  display: grid;
  animation: announcement-fade-in 160ms ease-out forwards;
}

@keyframes announcement-fade-in {
  from { opacity: 0; }
  to { opacity: 1; }
}

.announcement-content {
  width: 90vw;
  max-height: 85vh;
  background: rgba(255, 255, 255, 0.05);
  border-radius: 12px;
  box-shadow: 0 24px 64px rgba(12, 35, 64, 0.05);
  border: 1px solid rgba(12, 35, 64, 0.20);
  position: relative;
  overflow: hidden;
  display: flex;
  align-items: center;
  justify-content: center;
}

.announcement-img {
  display: block;
  width: auto;
  height: auto;
  max-width: 100%;
  max-height: 85vh;
  object-fit: contain;
}

.announcement-close {
  position: absolute;
  top: 8px;
  right: 8px;
  width: 28px;
  height: 28px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 999px;
  border: 1px solid rgba(12, 35, 64, 0.18);
  background: var(--tg-beer, #E28716);
  color: #fff;
  cursor: pointer;
  box-shadow: 0 4px 10px rgba(12, 35, 64, 0.2);
}

.announcement-close:hover {
  filter: brightness(1.05);
}

.announcement-close:focus {
  outline: 2px solid rgba(226, 135, 22, 0.55);
  outline-offset: 2px;
}

/* Make sure small screens still get the 90vw width within padding */
@media (max-width: 480px) {
  .announcement-content {
    border-radius: 10px;
  }
}

