.afr-agegate {
  position: fixed;
  z-index: 999999;
  inset: 0;
  display: none;
  align-items: center;
  justify-content: center;
  overflow-y: auto;
  padding: 32px 20px;
  background: var(--afr-agegate-background, #ffffff);
  color: var(--afr-agegate-text, #171717);
  text-align: center;
  isolation: isolate;
}

.afr-agegate.is-visible {
  display: flex;
}

.afr-agegate__background {
  position: absolute;
  z-index: 0;
  inset: 0;
  background-position: center;
  background-repeat: no-repeat;
  background-size: cover;
}

.afr-agegate__background::after {
  position: absolute;
  inset: 0;
  background: rgba(0, 0, 0, 0.35);
  content: '';
}

.afr-agegate__content {
  position: relative;
  z-index: 1;
  width: min(100%, 620px);
  margin: auto;
  padding: clamp(16px, 4vw, 32px);
  background: transparent;
  color: inherit;
  box-shadow: none;
}

.afr-agegate__logo {
  margin: 0 0 24px;
}

.afr-agegate__logo img {
  display: inline-block;
  width: auto;
  max-width: min(220px, 100%);
  max-height: 110px;
  object-fit: contain;
}

.afr-agegate__prompt {
  margin: 0 0 28px;
  color: var(--afr-agegate-text, #171717);
  font-size: clamp(20px, 3vw, 30px);
  font-weight: 600;
  line-height: 1.35;
}

.afr-agegate__actions {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 14px;
}

.afr-agegate__button {
  min-width: 130px;
  min-height: 48px;
  padding: 12px 28px;
  border: 2px solid transparent;
  border-radius: 4px;
  cursor: pointer;
  font: inherit;
  font-size: 16px;
  font-weight: 700;
  line-height: 1.2;
  transition: background-color 150ms ease, color 150ms ease, border-color 150ms ease;
}

.afr-agegate__button:focus-visible {
  outline: 3px solid #1d70b8;
  outline-offset: 3px;
}

.afr-agegate__button--yes {
  border-color: var(--afr-agegate-yes-border, #1b6e3b);
  background: var(--afr-agegate-yes-background, #1b6e3b);
  color: var(--afr-agegate-yes-text, #ffffff);
}

.afr-agegate__button--no {
  border-color: var(--afr-agegate-no-border, #333333);
  background: var(--afr-agegate-no-background, #ffffff);
  color: var(--afr-agegate-no-text, #222222);
}

.afr-agegate__button--yes:hover,
.afr-agegate__button--no:hover {
  filter: brightness(0.92);
}

.afr-agegate__denied {
  margin: 0;
  color: var(--afr-agegate-text, #171717);
  font-size: 18px;
  font-weight: 600;
  line-height: 1.5;
}

.afr-agegate__denied[hidden],
.afr-agegate__actions[hidden] {
  display: none !important;
}

body.afr-agegate-open {
  overflow: hidden;
}

@media (max-width: 480px) {
  .afr-agegate {
    padding: 16px;
  }

  .afr-agegate__content {
    padding: 16px 8px;
  }

  .afr-agegate__actions {
    flex-direction: column;
    gap: 10px;
  }

  .afr-agegate__button {
    width: 100%;
  }
}

@media (prefers-reduced-motion: reduce) {
  .afr-agegate__button {
    transition: none;
  }
}
