/* ==========================================================
   random.css - 룰렛 랜덤 조합기 (/generator/random) 전용 스타일시트
   ========================================================== */

.auto-page-container {
  display: flex;
  flex-direction: column;
  gap: 22px;
  width: 100%;
}

/* 1. 상단 히어로 카드 */
.auto-hero-card {
  background: linear-gradient(135deg, rgba(22, 34, 62, 0.9) 0%, rgba(15, 23, 42, 0.95) 100%);
  border: 1px solid rgba(59, 130, 246, 0.35);
  padding: 26px 30px;
  border-radius: 16px;
  box-shadow: 0 4px 24px rgba(0, 0, 0, 0.28);
  position: relative;
  overflow: hidden;
}

.auto-hero-card::after {
  content: '';
  position: absolute;
  top: -50px;
  right: -50px;
  width: 240px;
  height: 240px;
  background: radial-gradient(circle, rgba(59, 130, 246, 0.2) 0%, transparent 70%);
  pointer-events: none;
}

.auto-hero-title {
  font-size: 24px;
  font-weight: 800;
  color: #FFFFFF;
  margin: 0 0 10px 0;
  letter-spacing: -0.4px;
}

.auto-hero-desc {
  font-size: 13.5px;
  line-height: 1.65;
  color: #94A3B8;
  margin: 0;
}

/* ==========================================================
   [2] 인터랙티브 룰렛 전용 스타일 (.roulette-station-card)
   ========================================================== */
.roulette-station-card {
  background: radial-gradient(circle at center top, rgba(30, 41, 59, 0.9) 0%, rgba(15, 23, 42, 0.95) 100%);
  border: 1px solid rgba(255, 255, 255, 0.12);
  padding: 32px 24px;
  border-radius: 18px;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 28px;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.4);
}

.roulette-status-bar {
  display: flex;
  justify-content: space-between;
  align-items: center;
  width: 100%;
  max-width: 680px;
}

.status-step-pill {
  font-size: 14px;
  font-weight: 700;
  color: #94A3B8;
  background: rgba(255, 255, 255, 0.05);
  padding: 6px 14px;
  border-radius: 20px;
  border: 1px solid rgba(255, 255, 255, 0.1);
}

.btn-action-outline {
  background: rgba(255, 255, 255, 0.06);
  border: 1px solid rgba(255, 255, 255, 0.2);
  color: #CBD5E1;
  font-size: 13px;
  font-weight: 700;
  padding: 8px 16px;
  border-radius: 8px;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  transition: all 0.2s;
}

.btn-action-outline:hover {
  background: rgba(255, 255, 255, 0.14);
  color: #FFFFFF;
  border-color: rgba(255, 255, 255, 0.35);
}

.roulette-main-display {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0;
  margin-bottom: 32px;
}

.roulette-ball-container {
  position: relative;
  width: 140px;
  height: 140px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.roulette-giant-ball {
  width: 120px;
  height: 120px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 52px;
  font-weight: 900;
  color: #FFFFFF;
  text-shadow: 0 2px 8px rgba(0, 0, 0, 0.6);
  position: relative;
  box-shadow: inset -6px -6px 16px rgba(0, 0, 0, 0.5), inset 6px 6px 16px rgba(255, 255, 255, 0.4), 0 10px 25px rgba(0, 0, 0, 0.5);
  transition: transform 0.2s cubic-bezier(0.175, 0.885, 0.32, 1.275);
  z-index: 2;
}

.giant-ball-shine {
  position: absolute;
  top: 10px;
  left: 20px;
  width: 36px;
  height: 20px;
  border-radius: 50%;
  background: linear-gradient(to bottom, rgba(255, 255, 255, 0.8), transparent);
  transform: rotate(-30deg);
  pointer-events: none;
}

.roulette-glow-ring {
  position: absolute;
  top: 50%;
  left: 50%;
  width: 154px;
  height: 154px;
  border-radius: 50%;
  border: 2px dashed rgba(59, 130, 246, 0.5);
  animation: spinGlowRing 8s linear infinite;
  pointer-events: none;
  transform-origin: center center;
}

@keyframes spinGlowRing {
  0% { transform: translate(-50%, -50%) rotate(0deg); }
  100% { transform: translate(-50%, -50%) rotate(360deg); }
}

/* 버튼 컨트롤러 */
.roulette-controls {
  display: flex;
  flex-direction: column;
  align-items: center;
  width: 100%;
}

.btn-roulette-action {
  color: #FFFFFF;
  border: none;
  font-size: 17px;
  font-weight: 800;
  padding: 13px 36px;
  border-radius: 12px;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
  box-sizing: border-box;
}

/* START 버튼 (푸른색 계열) */
.btn-roulette-start {
  background: linear-gradient(135deg, #2563EB 0%, #1D4ED8 100%);
  box-shadow: 0 6px 20px rgba(37, 99, 235, 0.4);
}

.btn-roulette-start:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 24px rgba(37, 99, 235, 0.6);
  background: linear-gradient(135deg, #3B82F6 0%, #2563EB 100%);
}

/* STOP 버튼 (붉은색 계열) */
.btn-roulette-stop {
  background: linear-gradient(135deg, #EF4444 0%, #DC2626 100%);
  box-shadow: 0 6px 20px rgba(239, 68, 68, 0.4);
}

.btn-roulette-stop:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 24px rgba(239, 68, 68, 0.6);
  background: linear-gradient(135deg, #F87171 0%, #EF4444 100%);
}

/* 번호 선택 확인 버튼 (초록색 계열) */
.btn-roulette-confirm {
  background: linear-gradient(135deg, #10B981 0%, #059669 100%);
  box-shadow: 0 6px 20px rgba(16, 185, 129, 0.4);
}

.btn-roulette-confirm:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 24px rgba(16, 185, 129, 0.6);
  background: linear-gradient(135deg, #34D399 0%, #10B981 100%);
}

.control-group-decision {
  display: flex;
  align-items: center;
  gap: 12px;
  flex-wrap: wrap;
  justify-content: center;
}

.btn-roulette-sub {
  background: rgba(255, 255, 255, 0.06);
  border: 1px solid rgba(255, 255, 255, 0.2);
  color: #CBD5E1;
  font-size: 14.5px;
  font-weight: 700;
  padding: 12px 22px;
  border-radius: 12px;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  transition: all 0.2s;
}

.btn-roulette-sub:hover {
  background: rgba(255, 255, 255, 0.14);
  color: #FFFFFF;
}

/* 슬롯 리스트 */
.roulette-slots-container {
  width: 100%;
  max-width: 680px;
  background: rgba(15, 23, 42, 0.6);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 14px;
  padding: 18px 20px;
  display: flex;
  flex-direction: column;
  gap: 14px;
}

.slots-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 13px;
  font-weight: 700;
  color: #94A3B8;
}

.slots-progress {
  color: #60A5FA;
}

.roulette-slots-row {
  display: grid;
  grid-template-columns: repeat(6, 1fr);
  gap: 12px;
}

.roulette-slot {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
  background: rgba(255, 255, 255, 0.03);
  border: 2px dashed rgba(255, 255, 255, 0.15);
  border-radius: 12px;
  padding: 12px 6px;
  transition: all 0.2s;
}

.roulette-slot.current {
  border-color: #3B82F6;
  background: rgba(59, 130, 246, 0.1);
  box-shadow: 0 0 14px rgba(59, 130, 246, 0.25);
}

.roulette-slot.filled {
  border-style: solid;
  border-color: rgba(255, 255, 255, 0.25);
  background: rgba(255, 255, 255, 0.06);
}

.slot-idx {
  font-size: 11px;
  font-weight: 700;
  color: #94A3B8;
}

.slot-ball-placeholder {
  width: 44px;
  height: 44px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 18px;
  font-weight: 800;
  color: rgba(255, 255, 255, 0.25);
  background: rgba(255, 255, 255, 0.04);
}

/* 최종 완성 카드 */
.roulette-final-card {
  background: linear-gradient(135deg, rgba(22, 34, 62, 0.95) 0%, rgba(15, 23, 42, 0.98) 100%);
  border: 2px solid #10B981;
  padding: 30px;
  border-radius: 16px;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 20px;
  text-align: center;
  box-shadow: 0 8px 30px rgba(16, 185, 129, 0.25);
}

.final-badge {
  font-size: 12px;
  font-weight: 800;
  color: #10B981;
  background: rgba(16, 185, 129, 0.15);
  border: 1px solid rgba(16, 185, 129, 0.4);
  padding: 4px 12px;
  border-radius: 20px;
}

.final-title {
  font-size: 22px;
  font-weight: 800;
  color: #FFFFFF;
  margin: 0;
}

.final-balls-display {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 14px;
  flex-wrap: wrap;
  padding: 10px 0;
}

/* 6개 완성 번호 구형(공 모양) 입체 디자인 */
.final-lotto-ball {
  width: 52px;
  height: 52px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 21px;
  font-weight: 900;
  color: #FFFFFF;
  text-shadow: 0 1px 4px rgba(0, 0, 0, 0.6);
  position: relative;
  box-shadow: inset -4px -4px 10px rgba(0, 0, 0, 0.45), inset 4px 4px 10px rgba(255, 255, 255, 0.45), 0 6px 16px rgba(0, 0, 0, 0.45);
  transition: transform 0.2s cubic-bezier(0.175, 0.885, 0.32, 1.275);
}

.final-lotto-ball:hover {
  transform: translateY(-3px) scale(1.08);
}

.final-lotto-ball::after {
  content: '';
  position: absolute;
  top: 6px;
  left: 10px;
  width: 16px;
  height: 9px;
  border-radius: 50%;
  background: linear-gradient(to bottom, rgba(255, 255, 255, 0.75), transparent);
  transform: rotate(-35deg);
  pointer-events: none;
}

.final-actions {
  display: flex;
  gap: 12px;
  justify-content: center;
  flex-wrap: wrap;
}

.btn-optimal-generate {
  background: linear-gradient(135deg, #2563EB 0%, #1D4ED8 100%);
  color: #FFFFFF;
  border: none;
  padding: 14px 20px;
  font-size: 16px;
  font-weight: 800;
  border-radius: 12px;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  width: 100%;
  box-sizing: border-box;
  box-shadow: 0 6px 20px rgba(37, 99, 235, 0.4);
  transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
}

.btn-optimal-generate:hover {
  transform: translateY(-2px);
  box-shadow: 0 10px 26px rgba(37, 99, 235, 0.6);
  background: linear-gradient(135deg, #3B82F6 0%, #2563EB 100%);
}

/* 반응형 */
@media (max-width: 768px) {
  .roulette-slots-row {
    grid-template-columns: repeat(3, 1fr);
  }
  .roulette-ball-container {
    width: 124px;
    height: 124px;
  }
  .roulette-giant-ball {
    width: 100px;
    height: 100px;
    font-size: 42px;
  }
  .roulette-glow-ring {
    width: 124px;
    height: 124px;
  }
}

/* ==========================================================
   [마킹예시 버튼 & 실제 로또 OMR 용지 마킹 모달]
   ========================================================== */
.btn-omr-marking {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 4px;
  padding: 6px 11px;
  border-radius: 8px;
  background: linear-gradient(135deg, rgba(225, 29, 72, 0.2) 0%, rgba(190, 18, 60, 0.32) 100%);
  border: 1px solid rgba(244, 63, 94, 0.45);
  color: #FDA4AF;
  font-size: 12px;
  font-weight: 800;
  letter-spacing: -0.2px;
  cursor: pointer;
  white-space: nowrap;
  flex-shrink: 0;
  transition: all 0.18s ease;
}

.btn-omr-marking:hover {
  background: linear-gradient(135deg, #E11D48 0%, #BE123C 100%);
  border-color: #FB7185;
  color: #FFFFFF;
  transform: translateY(-1px);
  box-shadow: 0 4px 12px rgba(225, 29, 72, 0.38);
}

.btn-omr-marking:active {
  transform: translateY(0);
}

.btn-roulette-omr-marking {
  padding: 9px 15px;
  font-size: 13px;
  border-radius: 10px;
  margin-left: 4px;
}

/* OMR 마킹 모달 백드롭 */
.omr-marking-modal-backdrop {
  position: fixed;
  inset: 0;
  z-index: 9999;
  background: rgba(2, 6, 23, 0.82);
  backdrop-filter: blur(6px);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 16px;
  box-sizing: border-box;
  overflow-y: auto;
}

.omr-marking-modal-box {
  width: 100%;
  max-width: 440px;
  max-height: 92vh;
  background: #0F172A;
  border: 1px solid rgba(244, 63, 94, 0.38);
  border-radius: 18px;
  box-shadow: 0 24px 60px rgba(0, 0, 0, 0.65);
  display: flex;
  flex-direction: column;
  overflow: hidden;
  margin: auto;
}

.omr-marking-modal-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  padding: 15px 18px;
  background: linear-gradient(135deg, rgba(136, 19, 55, 0.45) 0%, rgba(15, 23, 42, 0.95) 100%);
  border-bottom: 1px solid rgba(244, 63, 94, 0.25);
}

.omr-modal-title-wrap {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
}

.omr-modal-title {
  margin: 0;
  font-size: 15.5px;
  font-weight: 800;
  color: #F8FAFC;
  letter-spacing: -0.3px;
}

.btn-omr-modal-close {
  width: 32px;
  height: 32px;
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid rgba(255, 255, 255, 0.15);
  color: #CBD5E1;
  font-size: 14px;
  font-weight: 800;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.18s;
  flex-shrink: 0;
}

.btn-omr-modal-close:hover {
  background: rgba(239, 68, 68, 0.25);
  border-color: #EF4444;
  color: #FFFFFF;
}

.omr-marking-modal-body {
  padding: 16px 18px;
  overflow-y: auto;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 12px;
}

.omr-selected-balls-bar {
  width: 100%;
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 8px;
  padding: 9px 12px;
  background: rgba(30, 41, 59, 0.65);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 10px;
  box-sizing: border-box;
}

.omr-selected-label {
  font-size: 12px;
  font-weight: 700;
  color: #FDA4AF;
}

.omr-selected-balls-row {
  display: flex;
  align-items: center;
  gap: 6px;
  flex-wrap: wrap;
}

.omr-slip-preview-wrap {
  width: 100%;
  display: flex;
  justify-content: center;
  align-items: center;
  background: rgba(15, 23, 42, 0.8);
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 12px;
  padding: 10px;
  box-sizing: border-box;
}

.omr-slip-preview-img {
  width: 100%;
  max-width: 340px;
  height: auto;
  border-radius: 8px;
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.45);
  display: block;
  user-select: none;
  -webkit-touch-callout: default;
}

.omr-marking-modal-footer {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 13px 18px;
  background: rgba(15, 23, 42, 0.95);
  border-top: 1px solid rgba(255, 255, 255, 0.08);
}

.btn-omr-download {
  flex: 1;
  height: 44px;
  border: none;
  border-radius: 10px;
  background: linear-gradient(135deg, #E11D48 0%, #BE123C 100%);
  color: #FFFFFF;
  font-size: 14px;
  font-weight: 800;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  box-shadow: 0 4px 14px rgba(225, 29, 72, 0.4);
  transition: all 0.2s;
}

.btn-omr-download:hover {
  background: linear-gradient(135deg, #F43F5E 0%, #E11D48 100%);
  transform: translateY(-1px);
  box-shadow: 0 6px 18px rgba(225, 29, 72, 0.55);
}

.btn-omr-close-sub {
  height: 44px;
  padding: 0 18px;
  border-radius: 10px;
  background: rgba(255, 255, 255, 0.07);
  border: 1px solid rgba(255, 255, 255, 0.15);
  color: #CBD5E1;
  font-size: 13.5px;
  font-weight: 700;
  cursor: pointer;
  transition: all 0.18s;
}

.btn-omr-close-sub:hover {
  background: rgba(255, 255, 255, 0.14);
  color: #FFFFFF;
}

