/* Gift block copied from the approved homepage prototype. */
.icon-sprite {
  position: absolute;
  width: 0;
  height: 0;
  overflow: hidden;
}

.draw-kicker {
  margin: 0;
  color: var(--orange);
  font-size: 13px;
  font-weight: 700;
  letter-spacing: 2.2px;
  text-transform: uppercase;
}

/* One white surface, matching the two cards above, starts after the expert. */
.gifts-stage {
  position: relative;
  z-index: 3;
  margin-top: -8px;
  padding: 0 0 28px;
}

.gifts-card.wrap {
  width: min(1248px, calc(100% - 40px));
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: 24px;
  background: #fff;
  box-shadow: 0 16px 48px rgba(46, 28, 56, 0.11);
}

.gifts-summary {
  display: grid;
  min-height: 88px;
  grid-template-columns: minmax(0, 1.25fr) minmax(0, 0.9fr) 44px;
  align-items: center;
  gap: 18px;
  padding: 16px 24px;
}

.grand-prize {
  display: grid;
  grid-template-columns: 46px minmax(0, 1fr);
  align-items: center;
  gap: 12px;
}

.summary-icon,
.gift-icon {
  display: grid;
  place-items: center;
  flex: none;
  border: 1px solid var(--gold-line);
  background: var(--gold);
  color: var(--accent);
}

.summary-icon {
  width: 46px;
  height: 46px;
  border-radius: 14px;
}

.gifts-stage .icon {
  display: block;
  width: 24px;
  height: 24px;
  fill: none;
  stroke: currentColor;
  stroke-width: 2;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.summary-icon .icon {
  width: 29px;
  height: 29px;
}

.grand-prize-copy {
  display: flex;
  min-width: 0;
  align-items: baseline;
  gap: 10px;
  white-space: nowrap;
}

.grand-prize .draw-kicker {
  font-size: 12px;
  letter-spacing: 1.2px;
}

.grand-prize-label {
  color: var(--text);
  font-size: 14px;
  font-weight: 600;
}

.grand-prize-value {
  font: 600 38px/1.06 var(--head);
  white-space: nowrap;
}

.gift-count {
  display: grid;
  min-height: 54px;
  grid-template-columns: 42px minmax(0, 1fr);
  align-items: center;
  gap: 12px;
  padding-left: 18px;
  border-left: 1px solid var(--line);
}

.gift-count .summary-icon {
  width: 42px;
  height: 42px;
  border-radius: 12px;
  background: #fff0e8;
  border-color: #f2cbb8;
}

.gift-count-copy {
  display: flex;
  min-width: 0;
  align-items: baseline;
  gap: 9px;
  white-space: nowrap;
}

.gift-count strong {
  color: var(--accent);
  font: 600 26px/1.08 var(--head);
  text-transform: uppercase;
}

.gift-marquee {
  position: relative;
  overflow: hidden;
  border-top: 1px solid var(--line);
  background: #fff;
  cursor: grab;
  touch-action: pan-y;
  user-select: none;
  -webkit-user-select: none;
}

.gifts-stage.is-dragging .gift-marquee {
  cursor: grabbing;
}

.gift-marquee::before,
.gift-marquee::after {
  position: absolute;
  z-index: 2;
  top: 0;
  bottom: 0;
  width: 72px;
  pointer-events: none;
  content: "";
}

.gift-marquee::before {
  left: 0;
  background: linear-gradient(90deg, #fff, rgba(255, 255, 255, 0));
}

.gift-marquee::after {
  right: 0;
  background: linear-gradient(270deg, #fff, rgba(255, 255, 255, 0));
}

.gift-track {
  display: flex;
  width: max-content;
  animation: gift-line 130s linear infinite;
  will-change: transform;
  transform: translate3d(0, 0, 0);
}

.gift-marquee:hover .gift-track,
.gift-marquee:focus-visible .gift-track,
.gifts-stage.is-dragging .gift-track,
.gifts-stage.is-paused .gift-track {
  animation-play-state: paused;
}

.gift-group {
  display: flex;
  flex: none;
}

.gift-item {
  display: flex;
  width: 302px;
  min-height: 88px;
  align-items: center;
  gap: 14px;
  padding: 14px 24px;
  border-right: 1px solid var(--line);
  color: var(--body);
  font-size: 14px;
  font-weight: 700;
  line-height: 1.35;
}

.gift-icon {
  width: 44px;
  height: 44px;
  border-radius: 13px;
}

.gift-copy {
  display: flex;
  min-width: 0;
  flex-direction: column;
  gap: 3px;
}

.gift-copy small {
  color: var(--note);
  font-size: 10px;
  font-weight: 700;
  letter-spacing: 1.2px;
  line-height: 1.2;
  text-transform: uppercase;
}

.gift-item.money {
  color: var(--accent);
  font-weight: 700;
}

.gift-item.money .gift-icon {
  border-color: #f2cbb8;
  background: #fff0e8;
}

.motion-toggle {
  display: grid;
  width: 42px;
  height: 42px;
  place-items: center;
  border: 1px solid var(--btn-line);
  border-radius: 50%;
  background: #fff;
  color: var(--ink);
  cursor: pointer;
}

.motion-toggle .icon {
  width: 17px;
  height: 17px;
}

.motion-toggle:focus-visible,
.gift-marquee:focus-visible {
  outline: 3px solid var(--accent);
  outline-offset: 4px;
}

@keyframes gift-line {
  to {
    transform: translate3d(-50%, 0, 0);
  }
}

/* Stack before the prototype grid would exceed the available width. */
@media (max-width: 1160px) {
  .gifts-stage {
    padding: 0 0 24px;
  }

  .gifts-card.wrap {
    width: calc(100% - 24px);
    border-radius: 22px;
  }

  .gifts-summary {
    width: 100%;
    min-height: 0;
    grid-template-columns: 1fr auto;
    gap: 14px;
    padding: 16px 18px;
  }

  .grand-prize {
    grid-column: 1 / -1;
    grid-template-columns: 50px minmax(0, 1fr);
    gap: 14px;
  }

  .grand-prize-copy,
  .gift-count-copy {
    flex-direction: column;
    align-items: flex-start;
    gap: 3px;
    white-space: normal;
  }

  .summary-icon {
    width: 50px;
    height: 50px;
    border-radius: 14px;
  }

  .grand-prize-value {
    font-size: 39px;
  }

  .gift-count {
    min-height: 0;
    grid-template-columns: 42px minmax(0, 1fr);
    gap: 11px;
    padding: 0;
    border-left: 0;
  }

  .gift-count .summary-icon {
    width: 42px;
    height: 42px;
    border-radius: 12px;
  }

  .gift-count strong {
    font-size: 23px;
  }

  .gift-item {
    width: 260px;
    min-height: 86px;
    padding: 13px 18px;
    font-size: 13px;
  }

  .gift-marquee::before,
  .gift-marquee::after {
    width: 34px;
  }

  .motion-toggle {
    grid-column: 2;
    grid-row: 2;
    align-self: center;
    width: 42px;
    height: 42px;
  }
}

@media (prefers-reduced-motion: reduce) {
  .gift-marquee {
    overflow-x: auto;
  }

  .gift-track {
    animation: none;
  }

  .gift-group[aria-hidden="true"] {
    display: none;
  }

  .motion-toggle {
    display: none;
  }
}
