.fortune-meter-wrap {
  position: relative;
  margin: 10px 14px 0;
  padding: 9px 12px 10px;
  border: 1px solid rgba(214, 222, 232, .24);
  border-radius: 14px;
  background: linear-gradient(180deg, rgba(221, 228, 236, .07), rgba(3, 10, 22, .54));
  box-shadow: inset 0 1px 0 rgba(255,255,255,.05);
  transition: border-color .25s ease, box-shadow .25s ease, background .25s ease;
}

.fortune-meter-wrap[hidden] { display: none; }

.fortune-meter-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  margin-bottom: 6px;
}

.fortune-meter-title,
.fortune-meter-status {
  font-size: 11px;
  line-height: 1;
  letter-spacing: .14em;
  text-transform: uppercase;
  font-weight: 850;
}

.fortune-meter-title {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  color: #dce4ed;
}

.fortune-meter-title img {
  width: 17px;
  height: 17px;
  object-fit: contain;
  filter: grayscale(.35) brightness(1.18);
}

.fortune-meter-status {
  color: #f5dfa0;
  font-variant-numeric: tabular-nums;
}

.fortune-progress {
  position: relative;
  height: 10px;
  overflow: hidden;
  border: 1px solid rgba(225, 232, 239, .18);
  border-radius: 999px;
  background: rgba(0, 5, 14, .72);
  box-shadow: inset 0 2px 5px rgba(0,0,0,.45);
}

.fortune-progress-fill {
  width: 0;
  height: 100%;
  border-radius: inherit;
  background: linear-gradient(90deg, #aab5c1, #e5edf5 42%, #d8b759 76%, #fff0a2);
  box-shadow: 0 0 12px rgba(226, 204, 126, .36);
  transition: width .62s cubic-bezier(.16,.8,.2,1);
}

.fortune-gain {
  position: absolute;
  right: 14px;
  top: -7px;
  color: #fff0a2;
  font-size: 12px;
  font-weight: 900;
  letter-spacing: .04em;
  opacity: 0;
  transform: translateY(5px);
  pointer-events: none;
}

.fortune-gain.is-visible {
  animation: fortuneGain 1.2s ease both;
}

@keyframes fortuneGain {
  0% { opacity: 0; transform: translateY(7px); }
  18%, 72% { opacity: 1; transform: translateY(0); }
  100% { opacity: 0; transform: translateY(-7px); }
}

.fortune-meter-wrap.is-charged {
  border-color: rgba(255, 226, 126, .74);
  background: linear-gradient(180deg, rgba(239, 200, 91, .14), rgba(7, 14, 27, .58));
  box-shadow: inset 0 1px 0 rgba(255,255,255,.09), 0 0 18px rgba(231, 189, 87, .18);
  animation: fortuneReady 2.4s ease-in-out infinite;
}

.fortune-meter-wrap.is-charged .fortune-meter-title,
.fortune-meter-wrap.is-charged .fortune-meter-status { color: #fff0a2; }

.fortune-meter-wrap.is-active {
  border-color: rgba(255, 226, 126, .54);
  background: linear-gradient(180deg, rgba(232, 193, 83, .1), rgba(5, 12, 24, .62));
}

@keyframes fortuneReady {
  0%, 100% { box-shadow: inset 0 1px 0 rgba(255,255,255,.09), 0 0 12px rgba(231,189,87,.12); }
  50% { box-shadow: inset 0 1px 0 rgba(255,255,255,.09), 0 0 24px rgba(231,189,87,.28); }
}

.spin-button.fortune-ready {
  border-color: #fff0a2;
  box-shadow: 0 0 0 2px rgba(231,189,87,.18), 0 0 22px rgba(231,189,87,.28), inset 0 1px 0 rgba(255,255,255,.34);
}

.spin-button.is-stop {
  background: linear-gradient(180deg, #f0c765, #b7791f);
  color: #1b1002;
}

.fortune-spin-badge {
  position: absolute;
  z-index: 13;
  top: 18px;
  right: 18px;
  display: flex;
  align-items: center;
  gap: 7px;
  padding: 6px 9px;
  border: 1px solid rgba(255, 235, 164, .74);
  border-radius: 999px;
  color: #fff7cf;
  background: rgba(38, 25, 3, .88);
  box-shadow: 0 0 17px rgba(231,189,87,.32);
  opacity: 0;
  transform: translateY(-4px);
  pointer-events: none;
  transition: opacity .2s ease, transform .2s ease;
}

.fortune-spin-badge strong {
  font-size: 15px;
  line-height: 1;
}

.fortune-spin-badge span {
  font-size: 9px;
  line-height: 1;
  letter-spacing: .12em;
  text-transform: uppercase;
  font-weight: 850;
}

.fortune-spin-badge.is-visible {
  opacity: 1;
  transform: translateY(0);
}

.reel-frame.fortune-spin-active {
  box-shadow:
    0 20px 42px rgba(0,0,0,.45),
    inset 0 2px 2px rgba(255,255,255,.55),
    inset 0 -2px 4px rgba(39,19,0,.62),
    0 0 0 2px rgba(255, 232, 151, .52),
    0 0 28px rgba(231, 189, 87, .34);
}

.fortune-result-layer {
  position: absolute;
  inset: 0;
  z-index: 32;
  display: grid;
  place-items: center;
  padding: 18px;
  pointer-events: none;
  opacity: 0;
  transition: opacity .18s ease;
}

.fortune-result-layer.is-visible { opacity: 1; }

.fortune-result-panel {
  width: min(310px, 88%);
  padding: 15px 18px;
  border: 1px solid rgba(255, 232, 154, .7);
  border-radius: 18px;
  color: #f9f5e8;
  background: linear-gradient(180deg, rgba(32, 39, 52, .96), rgba(9, 15, 27, .97));
  box-shadow: 0 18px 42px rgba(0,0,0,.48), 0 0 26px rgba(231,189,87,.2);
}

.fortune-result-title {
  margin-bottom: 9px;
  color: #fff0a2;
  text-align: center;
  font-family: Georgia, "Times New Roman", serif;
  font-size: 20px;
  font-weight: 900;
  letter-spacing: .08em;
  text-transform: uppercase;
}

.fortune-result-row {
  display: flex;
  justify-content: space-between;
  gap: 16px;
  padding: 5px 0;
  color: #d9e0e8;
  font-size: 13px;
  font-variant-numeric: tabular-nums;
}

.fortune-result-row.bonus { color: #f6d878; }

.fortune-result-row.total {
  margin-top: 4px;
  padding-top: 9px;
  border-top: 1px solid rgba(255,255,255,.13);
  color: #fff;
  font-size: 16px;
}

@media (max-width: 520px) {
  .fortune-meter-wrap { margin: 8px 10px 0; padding: 8px 10px 9px; }
  .fortune-spin-badge { top: 15px; right: 15px; padding: 5px 7px; }
  .fortune-spin-badge span { display: none; }
  .fortune-result-panel { width: min(280px, 92%); }
}

@media (prefers-reduced-motion: reduce) {
  .fortune-progress-fill { transition-duration: .18s; }
  .fortune-meter-wrap.is-charged { animation: none; }
  .fortune-gain.is-visible { animation: none; opacity: 1; transform: none; }
  .fortune-spin-badge { transition: none; }
  .fortune-result-layer { transition: none; }
}