.reward-dialog {
  --reward-accent: #d63a23;
  --reward-muted: #555057;
  width: calc(100vw - 32px);
  max-width: 404px;
  max-height: none;
  padding: 0;
  border: 0;
  border-radius: 26px;
  overflow: hidden;
  color: #201c21;
  background: #fffaf8;
  box-shadow: 0 18px 60px #10070655;
  color-scheme: light;
}

.reward-dialog:not([open]),
.reward-dialog [hidden] {
  display: none;
}

.reward-dialog[open] {
  position: fixed;
  top: calc(var(--visible-top, 0px) + var(--visible-height, 100vh) / 2);
  right: auto;
  bottom: auto;
  left: 50%;
  margin: 0;
  transform: translate(-50%, -50%);
  animation: reward-enter 180ms ease-out both;
}

.reward-dialog::backdrop {
  background: #130b0bd0;
  -webkit-backdrop-filter: blur(5px);
  backdrop-filter: blur(5px);
}

.reward-dialog.fallback-dialog[open] ~ .dialog-fallback-backdrop {
  background: #130b0bd0;
  -webkit-backdrop-filter: blur(5px);
  backdrop-filter: blur(5px);
}

.reward-dialog[data-reward-view="guide"][open] {
  --reward-arrow-space: clamp(48px, 14vh, 88px);
  top: calc(var(--visible-top, 0px) + (var(--visible-height, 100vh) + var(--reward-arrow-space)) / 2);
  overflow: visible;
  animation: none;
}

.reward-dialog[data-reward-view="guide"] .reward-guide {
  max-height: calc(var(--visible-height, 100vh) - var(--reward-arrow-space, 0px) - 28px - var(--safe-top, 0px) - var(--safe-bottom, 0px));
  border-radius: inherit;
}

.reward-menu-arrow {
  position: absolute;
  bottom: calc(100% - 2px);
  left: 60%;
  color: #ff583c;
  pointer-events: none;
  overflow: visible;
}

.reward-menu-arrow-shaft {
  stroke: currentColor;
  stroke-width: 7px;
}

.reward-menu-arrow-tip {
  fill: currentColor;
  stroke: none;
}

@keyframes reward-enter {
  from { opacity: 0; transform: translate(-50%, calc(-50% + 8px)) scale(.98); }
  to { opacity: 1; transform: translate(-50%, -50%) scale(1); }
}

.reward-panel {
  max-height: calc(var(--visible-height, 100vh) - 28px - var(--safe-top, 0px) - var(--safe-bottom, 0px));
  overflow-y: auto;
  overscroll-behavior: contain;
  padding: 24px 20px 20px;
  text-align: center;
}

.reward-panel h2 {
  margin: 7px 0 8px;
  font-size: 30px;
  font-size: clamp(24px, 7.4vw, 37px);
  font-weight: 700;
  line-height: 1.12;
  overflow-wrap: anywhere;
}

.reward-close {
  position: absolute;
  z-index: 1;
  top: 10px;
  right: 10px;
  display: grid;
  place-items: center;
  width: 44px;
  height: 44px;
  padding: 0;
  border-radius: 50%;
  color: #353138;
  background: #ece8e7;
}

.reward-dialog[dir="rtl"] .reward-close {
  right: auto;
  left: 10px;
}

.reward-close svg {
  width: 22px;
  height: 22px;
  stroke-width: 2.5;
}

.reward-dialog button:focus-visible,
.reward-dialog input:focus-visible {
  outline: 3px solid #922816;
  outline-offset: 3px;
}

.reward-description {
  margin: 0;
  color: var(--reward-muted);
  font-size: 16px;
  font-weight: 600;
  line-height: 1.38;
}

.reward-label {
  margin: 17px 0 3px;
  color: var(--reward-muted);
  font-size: 15px;
  font-weight: 600;
  line-height: 1.3;
}

.reward-amount {
  display: block;
  margin: 5px 0 16px;
  color: var(--reward-accent);
  font-size: 48px;
  font-size: clamp(33px, 11.8vw, 65px);
  font-weight: 700;
  line-height: 1.08;
  overflow-wrap: anywhere;
}

.reward-action {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 100%;
  min-height: 51px;
  padding: 12px 15px;
  border-radius: 14px;
  color: #fff;
  background: var(--reward-accent);
  font-size: 17px;
  font-weight: 700;
  text-align: center;
  line-height: 1.22;
}

.reward-action:active {
  background: #b82f1b;
}

.reward-action svg {
  flex: none;
  width: 21px;
  height: 21px;
}

.reward-action [data-reward-text="claim"] {
  margin-inline-end: 9px;
}

.reward-action [data-reward-text="copyAndOpen"] {
  margin-inline-start: 9px;
}

.reward-dialog[dir="rtl"] .reward-arrow {
  transform: scaleX(-1);
}

.reward-hint {
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 12px 0 0;
  color: var(--reward-muted);
  font-size: 13px;
  font-weight: 600;
  line-height: 1.35;
}

.reward-hint .reward-compass {
  margin-inline-end: 7px;
}

.reward-compass {
  position: relative;
  display: inline-block;
  width: 23px;
  height: 23px;
  flex: none;
  border-radius: 50%;
  background: radial-gradient(circle at 36% 28%, #40c8ff 1%, #058ef0 56%, #0056ac 100%);
  box-shadow: inset 0 0 0 1px #003f8a45;
}

.reward-compass::before {
  position: absolute;
  inset: 11%;
  border: 1px dotted #ffffffc0;
  border-radius: 50%;
  content: "";
}

.reward-compass::after {
  position: absolute;
  top: 6%;
  left: 38%;
  width: 24%;
  height: 88%;
  background: linear-gradient(#ec3f37 50%, #fff 50%);
  clip-path: polygon(50% 0, 100% 50%, 50% 100%, 0 50%);
  transform: rotate(44deg);
  content: "";
}

.reward-guide {
  padding-top: 20px;
}

.reward-guide-icon {
  width: 56px;
  height: 56px;
}

.reward-guide h2 {
  max-width: 300px;
  margin: 5px auto 8px;
  font-size: 27px;
  line-height: 1.13;
}

.reward-guide .reward-amount {
  margin: 5px 0 12px;
  font-size: 42px;
  font-size: clamp(32px, 10.8vw, 55px);
}

.reward-steps {
  display: grid;
  gap: 8px;
  padding: 0;
  margin: 0 0 10px;
  text-align: start;
}

.reward-steps li {
  display: flex;
  align-items: center;
  font-size: 14px;
  font-weight: 700;
  line-height: 1.25;
}

.reward-step-number {
  display: grid;
  place-items: center;
  flex: none;
  width: 25px;
  height: 25px;
  margin-inline-end: 10px;
  border-radius: 50%;
  color: white;
  background: var(--reward-accent);
}

.reward-menu-example {
  display: flex;
  align-items: center;
  border: 1px solid #ff765f;
  border-radius: 10px;
  margin: 0 0 12px 35px;
  margin-inline: 35px 0;
  padding: 9px 10px;
  background: #f7f4f2;
  font-size: 14px;
  font-weight: 700;
  text-align: start;
}

.reward-menu-example [data-reward-text] {
  flex: 1;
  margin: 0 7px;
}

.reward-menu-example svg {
  flex: none;
  width: 16px;
  height: 16px;
}

.reward-status {
  margin: 8px 0 0;
  color: #354c37;
  font-size: 13px;
  font-weight: 700;
}

.reward-status:empty {
  margin: 0;
}

.reward-link {
  width: 100%;
  margin: 8px 0 0;
  padding: 9px;
  border: 1px solid #bfb8b6;
  border-radius: 8px;
  color: #201c21;
  background: white;
  font: inherit;
}

.reward-gift {
  position: relative;
  width: 155px;
  height: 111px;
  margin: 0 auto 10px;
}

.reward-gift-box,
.reward-gift-bow,
.reward-sparkle {
  position: absolute;
  display: block;
}

.reward-gift-box {
  bottom: 7px;
  left: 35px;
  width: 84px;
  height: 54px;
  border-radius: 6px 6px 11px 11px;
  background: linear-gradient(90deg, transparent 39%, #fff4eb 39%, #f6d3c0 60%, transparent 60%), linear-gradient(150deg, #ff694b, #f44c2f 55%, #c42c1a);
  box-shadow: 0 12px 18px #e1532e35, inset 0 6px 10px #9d211844;
  transform: rotate(-6deg);
}

.reward-gift-box::before {
  position: absolute;
  top: -14px;
  left: -5px;
  width: 94px;
  height: 23px;
  border-radius: 7px 7px 4px 4px;
  background: linear-gradient(90deg, transparent 40%, #fff6ec 40%, #f0c7b3 60%, transparent 60%), linear-gradient(160deg, #ff9171, #f45134 65%, #dc3d24);
  box-shadow: 0 2px 3px #91251633;
  content: "";
}

.reward-gift-bow {
  z-index: 1;
  bottom: 78px;
  left: 70px;
  width: 14px;
  height: 13px;
  border-radius: 7px;
  background: linear-gradient(#fffaf6, #efc4b2);
  box-shadow: 0 2px 4px #b5382840;
}

.reward-gift-bow::before,
.reward-gift-bow::after {
  position: absolute;
  top: -12px;
  width: 34px;
  height: 22px;
  border: 6px solid #ffe6d8;
  border-radius: 50% 55% 30% 45%;
  box-shadow: inset 0 1px 5px #e9695080, 0 2px 3px #bd63432c;
  content: "";
}

.reward-gift-bow::before {
  right: 9px;
  transform: rotate(37deg);
}

.reward-gift-bow::after {
  left: 9px;
  transform: rotate(-42deg) scaleX(-1);
}

.reward-sparkle {
  width: 16px;
  height: 16px;
  background: linear-gradient(135deg, #ffd973, #dc7615);
  clip-path: polygon(50% 0, 61% 36%, 100% 50%, 61% 63%, 50% 100%, 38% 63%, 0 50%, 38% 36%);
}

.reward-sparkle:nth-child(1) { top: 61px; left: 4px; }
.reward-sparkle:nth-child(2) { top: 4px; right: 9px; width: 22px; height: 22px; }
.reward-sparkle:nth-child(3) { top: 50px; right: 1px; width: 13px; height: 13px; }

@media (max-width: 360px), (max-height: 550px) {
  .reward-panel { padding: 16px 15px; }
  .reward-guide-icon { width: 42px; height: 42px; }
  .reward-guide h2 { font-size: 23px; }
  .reward-description { font-size: 14px; }
  .reward-action { font-size: 15px; min-height: 46px; }
}

@media (prefers-reduced-motion: reduce) {
  .reward-dialog[open] { animation: none; }
}
