:root {
  color-scheme: dark;
  font-family: "Inter", Arial, Helvetica, sans-serif;
  font-synthesis: none;
  text-rendering: optimizeLegibility;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;

  --green: #17c765;
  --green-hover: #12b95b;
  --card-top: #171c28;
  --card-bottom: #0b0e15;
  --border: rgba(151, 161, 180, 0.27);
  --muted: #a7b2c4;
}

* {
  box-sizing: border-box;
}

html,
body {
  width: 100%;
  min-width: 320px;
  min-height: 100%;
  margin: 0;
}

body {
  min-height: 100vh;
  overflow: hidden;
  background: #05070d;
}

button {
  font: inherit;
}

.age-page {
  position: relative;
  display: grid;
  min-height: 100vh;
  min-height: 100svh;
  place-items: center;
  isolation: isolate;
  overflow: hidden;
  padding: 24px;
  background: #05070d;
}

.backdrop {
  position: absolute;
  z-index: -2;
  inset: 0;
  background-image: url("assets/casino-background.png");
  background-position: center center;
  background-repeat: no-repeat;
  background-size: cover;
  transform: scale(1.006);
}

/* Camada escura sobre a arte, como na referência. */
.backdrop::after {
  position: absolute;
  inset: 0;
  content: "";
  background:
    linear-gradient(90deg, rgba(0, 0, 0, .56) 0%, rgba(0, 0, 0, .30) 54%, rgba(0, 0, 0, .42) 100%),
    linear-gradient(180deg, rgba(0, 0, 0, .42), rgba(0, 0, 0, .52));
}

.age-card {
  width: min(480px, 100%);
  padding: 38px 36px 27px;
  text-align: center;
  color: #f7f8fb;
  background: linear-gradient(155deg, var(--card-top) 0%, #10141e 54%, var(--card-bottom) 100%);
  border: 1px solid var(--border);
  border-radius: 22px;
  box-shadow: 0 22px 75px rgba(0, 0, 0, .5), inset 0 1px 0 rgba(255, 255, 255, .025);
  transition: opacity .28s ease, transform .28s ease;
}

.live-label {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  min-height: 17px;
  color: #20d879;
  font-size: 13px;
  font-weight: 800;
  letter-spacing: -.15px;
}

.live-die {
  display: inline-block;
  font-size: 12px;
  line-height: 1;
  filter: saturate(.8);
}

.age-card h1 {
  margin: 20px 0 12px;
  color: #f7f7fa;
  font-size: clamp(27px, 3vw, 32px);
  font-weight: 800;
  line-height: 1.18;
  letter-spacing: -1.25px;
}

.age-description {
  max-width: 390px;
  margin: 0 auto 27px;
  color: #d8dfeb;
  font-size: 14px;
  font-weight: 400;
  line-height: 1.55;
}

.age-actions {
  display: grid;
  gap: 10px;
}

.age-button {
  display: flex;
  width: 100%;
  min-height: 53px;
  align-items: center;
  justify-content: center;
  gap: 5px;
  padding: 13px 18px;
  border: 1px solid transparent;
  border-radius: 10px;
  color: #fff;
  cursor: pointer;
  font-size: 14px;
  font-weight: 800;
  line-height: 1.2;
  transition: background-color .16s ease, border-color .16s ease, transform .16s ease, box-shadow .16s ease;
  -webkit-tap-highlight-color: transparent;
}

.age-button:active {
  transform: translateY(1px);
}

.age-button:focus-visible {
  outline: 3px solid rgba(89, 170, 255, .9);
  outline-offset: 3px;
}

.age-button--yes {
  background: var(--green);
  box-shadow: 0 5px 16px rgba(23, 199, 101, .09);
}

.age-button--yes:hover {
  background: var(--green-hover);
  box-shadow: 0 7px 20px rgba(23, 199, 101, .18);
}

.age-button--no {
  background: rgba(11, 14, 21, .28);
  border-color: rgba(151, 161, 180, .34);
}

.age-button--no:hover {
  background: rgba(255, 255, 255, .055);
  border-color: rgba(174, 185, 204, .5);
}

.age-footnote {
  margin: 20px 0 0;
  color: #90a0b8;
  font-size: 9px;
  font-weight: 400;
  line-height: 1.65;
}

.approved-message {
  position: absolute;
  bottom: 28px;
  left: 50%;
  padding: 10px 16px;
  color: #d8ffea;
  background: rgba(8, 17, 14, .74);
  border: 1px solid rgba(23, 199, 101, .28);
  border-radius: 999px;
  font-size: 12px;
  opacity: 0;
  pointer-events: none;
  transform: translate(-50%, 8px);
  transition: opacity .25s ease, transform .25s ease;
}

.age-page.is-approved .backdrop::after {
  background:
    linear-gradient(90deg, rgba(0, 0, 0, .37) 0%, rgba(0, 0, 0, .17) 54%, rgba(0, 0, 0, .28) 100%),
    linear-gradient(180deg, rgba(0, 0, 0, .27), rgba(0, 0, 0, .36));
}

.age-page.is-approved .age-card {
  opacity: 0;
  pointer-events: none;
  transform: translateY(8px) scale(.985);
}

.age-page.is-approved .approved-message {
  opacity: 1;
  transform: translate(-50%, 0);
}

.age-card.is-denied h1 {
  color: #f2f4f8;
}

.age-card.is-denied .age-description {
  margin-bottom: 22px;
}

@media (max-width: 560px) {
  .age-page {
    padding: 18px;
  }

  .backdrop {
    background-position: 61% center;
  }

  .backdrop::after {
    background:
      linear-gradient(90deg, rgba(0, 0, 0, .53), rgba(0, 0, 0, .37)),
      linear-gradient(180deg, rgba(0, 0, 0, .43), rgba(0, 0, 0, .58));
  }

  .age-card {
    padding: 32px 23px 25px;
    border-radius: 19px;
  }

  .age-card h1 {
    margin-top: 18px;
    font-size: 28px;
    letter-spacing: -1px;
  }

  .age-description {
    margin-bottom: 23px;
    font-size: 13px;
  }

  .age-button {
    min-height: 51px;
    font-size: 13px;
  }

  .age-footnote {
    margin-top: 18px;
    font-size: 8.5px;
  }

  .desktop-break {
    display: none;
  }
}

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    scroll-behavior: auto !important;
    transition-duration: .01ms !important;
    animation-duration: .01ms !important;
    animation-iteration-count: 1 !important;
  }
}
