
:root {
  --ink: #17162b;
  --muted: #69667d;
  --paper: #fffdfb;
  --pink: #f83d78;
  --coral: #ff756d;
  --purple: #7652e8;
  --line: rgba(23, 22, 43, .12);
  color-scheme: light;
}

* { box-sizing: border-box; }
html, body { min-height: 100%; margin: 0; }
body {
  min-height: 100svh;
  overflow: hidden;
  color: var(--ink);
  background: #9b64e8 url("/images/luckycrush-background.webp") center / cover no-repeat;
  font-family: "Trebuchet MS", "Segoe UI", sans-serif;
}
button { font: inherit; }

.veil-backdrop {
  position: fixed;
  inset: 0;
  z-index: 0;
  width: 100%;
  height: 100%;
  padding: 0;
  border: 0;
  cursor: pointer;
  background:
    linear-gradient(90deg, rgba(27, 18, 51, .04) 0%, rgba(27, 18, 51, .08) 48%, rgba(27, 18, 51, .30) 100%);
}

.veil-stage {
  position: relative;
  z-index: 1;
  min-height: 100svh;
  display: grid;
  align-items: center;
  justify-items: end;
  padding: clamp(22px, 5vw, 76px);
  pointer-events: none;
}

.veil-brand {
  position: fixed;
  top: clamp(18px, 3vw, 34px);
  left: clamp(18px, 4vw, 58px);
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 8px 14px 8px 9px;
  border: 1px solid rgba(255,255,255,.68);
  border-radius: 999px;
  background: rgba(255,255,255,.91);
  box-shadow: 0 12px 36px rgba(45,25,86,.17);
  color: #1b1931;
  font-size: 22px;
  letter-spacing: -.7px;
  pointer-events: none;
}
.veil-brand img { width: 38px; height: 38px; object-fit: contain; }
.veil-brand strong { font-weight: 800; }

.veil-panel {
  width: min(410px, 100%);
  padding: clamp(24px, 4vw, 38px);
  border: 1px solid rgba(255,255,255,.82);
  border-radius: 28px 8px 28px 28px;
  background: var(--paper);
  box-shadow: 0 30px 90px rgba(35,19,72,.32), 0 3px 12px rgba(35,19,72,.10);
  pointer-events: auto;
  animation: veil-arrive .55s cubic-bezier(.2,.8,.2,1) both;
}

.veil-panel__topline {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 28px;
}
.veil-live {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  color: #4d4960;
  font-size: 13px;
  font-weight: 700;
  letter-spacing: .02em;
}
.veil-live i {
  width: 9px;
  height: 9px;
  border-radius: 50%;
  background: #21bf73;
  box-shadow: 0 0 0 5px rgba(33,191,115,.14);
  animation: veil-pulse 2s ease-out infinite;
}
.veil-18 {
  display: inline-grid;
  place-items: center;
  min-width: 38px;
  min-height: 28px;
  border: 1px solid var(--line);
  border-radius: 999px;
  color: #625e73;
  font-size: 12px;
  font-weight: 800;
}
.veil-eyebrow {
  margin: 0 0 10px;
  color: var(--pink);
  font-size: 12px;
  font-weight: 800;
  letter-spacing: .11em;
  text-transform: uppercase;
}
.veil-title {
  max-width: 330px;
  margin: 0;
  font-family: Georgia, "Times New Roman", serif;
  font-size: clamp(34px, 4vw, 49px);
  font-weight: 700;
  line-height: .98;
  letter-spacing: -.045em;
  text-wrap: balance;
}
.veil-copy {
  margin: 20px 0 25px;
  color: var(--muted);
  font-size: 15px;
  line-height: 1.6;
  text-wrap: pretty;
}
.veil-actions { display: grid; gap: 10px; }
.veil-primary,
.veil-account,
.veil-back {
  min-height: 49px;
  border-radius: 14px;
  cursor: pointer;
  transition: transform .18s ease, box-shadow .18s ease, border-color .18s ease;
}
.veil-primary {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  padding: 0 18px 0 20px;
  border: 0;
  color: white;
  background: linear-gradient(105deg, var(--pink), var(--coral));
  box-shadow: 0 13px 28px rgba(248,61,120,.26);
  font-weight: 800;
  text-align: start;
}
.veil-primary b { font-size: 22px; transition: transform .18s ease; }
.veil-primary:hover { transform: translateY(-2px); box-shadow: 0 17px 34px rgba(248,61,120,.34); }
.veil-primary:hover b { transform: translateX(3px); }
.veil-account,
.veil-back {
  border: 1px solid var(--line);
  background: transparent;
  color: #39364d;
  font-size: 13px;
  font-weight: 700;
}
.veil-account:hover { border-color: rgba(248,61,120,.5); transform: translateY(-1px); }
.veil-back { min-height: 35px; border-color: transparent; color: #827e90; font-weight: 500; }
.veil-primary:focus-visible,
.veil-account:focus-visible,
.veil-back:focus-visible,
.veil-backdrop:focus-visible {
  outline: 3px solid #12bfc4;
  outline-offset: 3px;
}
.veil-assurances {
  display: flex;
  flex-wrap: wrap;
  gap: 7px;
  margin-top: 18px;
}
.veil-assurances span {
  padding: 6px 9px;
  border-radius: 8px;
  background: #f3f0fa;
  color: #625e73;
  font-size: 11px;
  font-weight: 700;
}
.veil-notice {
  margin: 15px 0 0;
  color: #908c9c;
  font-size: 10px;
  line-height: 1.45;
}

html[dir="rtl"] .veil-panel { text-align: right; }
html[dir="rtl"] .veil-primary b { transform: rotate(180deg); }
html[dir="rtl"] .veil-brand { left: auto; right: clamp(18px, 4vw, 58px); }

details { position: absolute; z-index: -1; opacity: 0; pointer-events: none; }
details summary { display: none; }

@keyframes veil-arrive {
  from { opacity: 0; transform: translate3d(22px, 12px, 0) scale(.98); }
  to { opacity: 1; transform: translate3d(0, 0, 0) scale(1); }
}
@keyframes veil-pulse {
  0%, 50% { box-shadow: 0 0 0 5px rgba(33,191,115,.14); }
  80%, 100% { box-shadow: 0 0 0 10px rgba(33,191,115,0); }
}

@media (max-width: 720px) {
  body { background-position: 49% center; }
  .veil-backdrop { background: linear-gradient(180deg, rgba(27,18,51,.02) 20%, rgba(27,18,51,.32) 100%); }
  .veil-stage { align-items: end; justify-items: stretch; padding: 96px 12px 12px; }
  .veil-brand { top: 14px; left: 14px; font-size: 18px; }
  .veil-brand img { width: 32px; height: 32px; }
  .veil-panel {
    width: 100%;
    max-height: calc(100svh - 88px);
    overflow: auto;
    padding: 22px;
    border-radius: 24px 24px 9px 9px;
  }
  .veil-panel__topline { margin-bottom: 17px; }
  .veil-title { max-width: 12em; font-size: clamp(31px, 9vw, 43px); }
  .veil-copy { margin: 14px 0 18px; font-size: 14px; line-height: 1.5; }
}

@media (max-height: 660px) and (min-width: 721px) {
  .veil-panel { padding: 24px; }
  .veil-panel__topline { margin-bottom: 15px; }
  .veil-title { font-size: 38px; }
  .veil-copy { margin: 13px 0 17px; }
  .veil-assurances { margin-top: 12px; }
  .veil-notice { margin-top: 10px; }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation: none !important; transition: none !important; }
}
