html.age-gate-open,
html.age-gate-open body {
  overflow: hidden;
}

.age-gate {
  box-sizing: border-box;
  width: 610px;
  max-width: calc(100% - 40px);
  max-height: calc(100% - 32px);
  max-height: calc(100dvh - 32px);
  margin: auto;
  padding: 36px 38px;
  overflow-y: auto;
  overscroll-behavior: contain;
  border: 1px solid #3b3e48;
  border-radius: 16px;
  background: #1d2029;
  color: #fff;
  font-family: "PingFang SC", "Microsoft YaHei", sans-serif;
  text-align: center;
}

.age-gate:not([open]) {
  display: none;
}

.age-gate::backdrop {
  background: rgba(11, 13, 23, 0.96);
}

/* 不支持原生 dialog 的浏览器使用相同内容和尺寸的全屏遮罩。 */
.age-gate-overlay {
  position: fixed;
  top: 0;
  right: 0;
  bottom: 0;
  left: 0;
  z-index: 2147483647;
  display: flex;
  box-sizing: border-box;
  padding: 16px 20px;
  overflow-y: auto;
  overscroll-behavior: contain;
  background: rgba(11, 13, 23, 0.96);
}

.age-gate--fallback {
  position: relative;
  top: auto;
  right: auto;
  bottom: auto;
  left: auto;
  display: block;
  flex-shrink: 0;
  max-width: 100%;
  max-height: calc(100vh - 32px);
  max-height: calc(100dvh - 32px);
}

.age-gate__artwork,
.age-gate__artwork img {
  display: block;
  width: 150px;
  height: 150px;
  margin: 0 auto;
  object-fit: contain;
}

.age-gate__title {
  margin: 16px 0 0;
  padding: 0;
  color: #ff00b4;
  font-size: 32px;
  font-weight: 500;
  line-height: 45px;
}

.age-gate__title:focus {
  outline: none;
}

.age-gate__description {
  margin: 16px 0 0;
  padding: 0;
  color: rgba(255, 255, 255, 0.9);
  font-size: 20px;
  font-weight: 400;
  line-height: 30px;
}

.age-gate__actions {
  display: flex;
  flex-direction: column;
  gap: 12px;
  margin-top: 48px;
}

.age-gate__button {
  display: block;
  box-sizing: border-box;
  width: 100%;
  height: 72px;
  margin: 0;
  padding: 0 8px;
  border: 0;
  border-radius: 8px;
  color: #fff;
  font-family: inherit;
  font-size: 24px;
  font-weight: 500;
  line-height: 34px;
  cursor: pointer;
  appearance: none;
}

.age-gate__button--leave {
  background: #32353e;
}

.age-gate__button--enter {
  background: #ff00b4;
}

.age-gate__button:focus-visible {
  outline: 2px solid #fff;
  outline-offset: 3px;
}

@media (max-width: 700px) {
  .age-gate {
    width: 305px;
    padding: 24px 20px;
  }

  .age-gate__artwork,
  .age-gate__artwork img {
    width: 80px;
    height: 80px;
  }

  .age-gate__title {
    margin-top: 10px;
    font-size: 18px;
    line-height: 25px;
  }

  .age-gate__description {
    margin: 10px 4px 0;
    font-size: 10px;
    line-height: 14px;
  }

  .age-gate__actions {
    gap: 8px;
    margin-top: 24px;
  }

  .age-gate__button {
    height: 36px;
    border-radius: 4px;
    font-size: 12px;
    line-height: 17px;
  }
}
