*,
*::before,
*::after {
  box-sizing: border-box;
}

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

body {
  font-family:
    ui-sans-serif,
    system-ui,
    -apple-system,
    BlinkMacSystemFont,
    "Segoe UI",
    sans-serif;
  color: #ffffff;
  background: #000000;
  -webkit-font-smoothing: antialiased;
  text-rendering: geometricPrecision;
}

.page-shell {
  width: 100%;
  min-height: 100vh;
  min-height: 100svh;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 40px 24px;
  overflow: hidden;
  background: radial-gradient(ellipse at top, #0d0d22 0%, #050509 65%, #000000 100%);
}

.scratch-card {
  position: relative;
  width: min(360px, calc(100vw - 48px));
  max-width: calc(100vw - 48px);
  flex: 0 0 auto;
  aspect-ratio: 3 / 4;
  overflow: hidden;
  user-select: none;
  border-radius: 26px;
  box-shadow:
    0 0 50px rgba(190, 150, 255, 0.45),
    0 0 110px rgba(140, 100, 230, 0.28),
    0 20px 60px rgba(0, 0, 0, 0.55);
  -webkit-tap-highlight-color: transparent;
}

.reveal-layer,
.cover-copy {
  position: absolute;
  inset: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 0 32px;
  text-align: center;
}

.reveal-layer {
  background: #0a0a18;
}

.reveal-layer h1 {
  margin: 0;
  color: #f6e6ff;
  font-size: 42px;
  font-weight: 800;
  line-height: 1.05;
  letter-spacing: -0.025em;
  text-shadow: 0 2px 24px rgba(200, 160, 255, 0.45);
}

.reveal-layer p {
  margin: 16px 0 0;
  color: rgba(255, 255, 255, 0.85);
  font-size: 16px;
  line-height: 1.5;
}

.scratch-canvas {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  cursor: grab;
  touch-action: none;
  opacity: 1;
  transition: opacity 600ms ease;
  will-change: opacity;
}

.scratch-canvas:active {
  cursor: grabbing;
}

.scratch-card.is-revealed .scratch-canvas,
.scratch-card.is-revealed .cover-copy {
  opacity: 0;
}

.cover-copy {
  pointer-events: none;
  opacity: 1;
  transition: opacity 350ms ease;
}

.emoji {
  font-size: 64px;
  line-height: 1;
}

.cover-copy h2 {
  margin: 20px 0 0;
  color: #ffffff;
  font-size: 19px;
  font-weight: 700;
  line-height: 1.2;
  letter-spacing: 0.18em;
}

.cover-copy p {
  position: absolute;
  right: 0;
  bottom: 28px;
  left: 0;
  margin: 0;
  color: rgba(255, 255, 255, 0.55);
  font-size: 11px;
  line-height: 1.2;
  letter-spacing: 0.22em;
}

@media (max-width: 420px) {
  .page-shell {
    padding: 32px 24px;
  }

  .reveal-layer h1 {
    font-size: 40px;
  }
}
