/* ep14-player.css: Starry's Mystery Random Box UI */

/* Desktop / Default Layout: Bottom-Right placement */
#ep14RandomWrap {
  position: absolute;
  right: 20px;
  bottom: 20px;
  max-width: 410px;
  width: calc(100% - 40px);
  z-index: 30;
  pointer-events: auto;
  animation: ep14FadeUp 0.35s cubic-bezier(0.16, 1, 0.3, 1);
}

.ep14-random-card {
  background: rgba(26, 16, 44, 0.88);
  border: 2px solid rgba(192, 132, 252, 0.45);
  border-radius: 18px;
  padding: 16px 18px;
  box-shadow: 0 12px 32px rgba(0, 0, 0, 0.45), 0 0 24px rgba(192, 132, 252, 0.2);
  backdrop-filter: blur(12px);
  color: #f8fafc;
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.ep14-random-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.ep14-random-badge {
  font-size: 0.82rem;
  font-weight: 700;
  color: #c084fc;
  letter-spacing: -0.2px;
}

.ep14-box-status {
  font-size: 0.76rem;
  font-weight: 600;
  background: rgba(192, 132, 252, 0.2);
  color: #f3e8ff;
  padding: 3px 10px;
  border-radius: 999px;
  border: 1px solid rgba(192, 132, 252, 0.35);
  animation: ep14Pulse 1.5s infinite;
}

.ep14-mystery-display {
  display: flex;
  align-items: center;
  gap: 12px;
  background: rgba(88, 28, 135, 0.25);
  border: 1px solid rgba(168, 85, 247, 0.35);
  padding: 10px 14px;
  border-radius: 12px;
}

.ep14-prize-icon {
  font-size: 1.6rem;
  filter: drop-shadow(0 2px 8px rgba(192, 132, 252, 0.5));
}

.ep14-prize-info {
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.ep14-prize-title {
  font-size: 0.9rem;
  font-weight: 800;
  color: #f3e8ff;
}

.ep14-prize-desc {
  font-size: 0.75rem;
  color: #d8b4fe;
}

.ep14-open-btn {
  min-height: 52px;
  border: none;
  border-radius: 14px;
  background: linear-gradient(135deg, #a855f7 0%, #7e22ce 100%);
  color: #ffffff;
  font-size: 1.05rem;
  font-weight: 900;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  box-shadow: 0 4px 18px rgba(168, 85, 247, 0.45);
  transition: transform 0.15s ease, background 0.2s ease, box-shadow 0.2s ease;
  padding: 10px 16px;
}

.ep14-open-btn:hover:not(:disabled) {
  background: linear-gradient(135deg, #c084fc 0%, #a855f7 100%);
  box-shadow: 0 6px 22px rgba(192, 132, 252, 0.6);
  transform: translateY(-2px);
}

.ep14-open-btn:active:not(:disabled) {
  transform: scale(0.97);
}

.ep14-open-btn:disabled {
  opacity: 0.6;
  cursor: not-allowed;
  transform: none;
}

.ep14-random-hint {
  font-size: 0.76rem;
  color: #94a3b8;
  text-align: center;
  line-height: 1.4;
}

/* Complete Celebration Wrap */
.ep14-complete-wrap {
  margin: 16px auto;
  max-width: 500px;
  width: calc(100% - 32px);
  animation: ep14FadeUp 0.4s cubic-bezier(0.16, 1, 0.3, 1);
}

.ep14-complete-card {
  background: linear-gradient(135deg, rgba(168, 85, 247, 0.15) 0%, rgba(192, 132, 252, 0.05) 100%);
  border: 1.5px solid rgba(192, 132, 252, 0.4);
  border-radius: 20px;
  padding: 24px;
  text-align: center;
  box-shadow: 0 8px 32px rgba(0, 0, 0, 0.3);
  backdrop-filter: blur(12px);
  color: #f8fafc;
}

.ep14-complete-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 54px;
  height: 54px;
  border-radius: 50%;
  background: rgba(192, 132, 252, 0.2);
  border: 2px solid rgba(192, 132, 252, 0.45);
  font-size: 1.2rem;
  font-weight: 900;
  color: #c084fc;
  margin-bottom: 12px;
}

.ep14-complete-card h3 {
  margin: 0 0 8px;
  font-size: 1.25rem;
  font-weight: 800;
  color: #f5d0fe;
}

.ep14-complete-card p {
  margin: 0 0 16px;
  font-size: 0.9rem;
  color: #d8b4fe;
  line-height: 1.5;
}

.ep14-cert-btn {
  padding: 10px 22px;
  border-radius: 12px;
  border: 1px solid rgba(192, 132, 252, 0.5);
  background: rgba(168, 85, 247, 0.25);
  color: #f0abfc;
  font-size: 0.9rem;
  font-weight: 700;
  cursor: pointer;
  transition: all 0.2s ease;
}

.ep14-cert-btn:hover {
  background: rgba(168, 85, 247, 0.4);
  color: #ffffff;
}

/* Animations */
@keyframes ep14FadeUp {
  from { opacity: 0; transform: translateY(12px); }
  to { opacity: 1; transform: translateY(0); }
}

@keyframes ep14Pulse {
  0%, 100% { opacity: 1; transform: scale(1); }
  50% { opacity: 0.75; transform: scale(1.02); }
}

/* Mobile Layout: Outside #screenContainer, immediately below 16:9 screen */
@media (max-width: 680px) {
  #ep14RandomWrap {
    position: relative;
    right: auto;
    bottom: auto;
    width: 100%;
    max-width: 100%;
    margin: 12px 0;
    box-sizing: border-box;
  }

  .ep14-random-card {
    border-radius: 14px;
    padding: 14px 16px;
  }

  .ep14-open-btn {
    min-height: 48px;
    font-size: 0.96rem;
  }
}
