/* 抽奖转盘 */
.lot-layout {
  display: grid;
  grid-template-columns: 330px minmax(0, 1fr);
  gap: 18px;
  align-items: stretch;
}
@media (max-width: 860px) { .lot-layout { grid-template-columns: 1fr; } }

.lot-setup { padding: 18px; display: flex; flex-direction: column; }
.lot-setup-head { display: flex; align-items: baseline; justify-content: space-between; margin-bottom: 10px; }
.lot-setup-head h2 { margin: 0; font-size: 14px; }
.lot-setup-head span { font-size: 11px; color: var(--muted-2); font-family: var(--mono); }
.lot-names {
  width: 100%;
  min-height: 190px;
  flex: 1;
  resize: vertical;
  border: 1px solid var(--line);
  border-radius: 11px;
  background: var(--surface-2);
  color: var(--ink-2);
  font: inherit;
  font-size: 12.5px;
  line-height: 1.8;
  padding: 10px 12px;
  outline: none;
}
.lot-names:focus { border-color: var(--brand); box-shadow: 0 0 0 3px var(--brand-soft); }
.lot-setup-foot { display: flex; gap: 12px; padding: 8px 2px 2px; }
.lot-link {
  appearance: none;
  border: 0;
  background: transparent;
  color: var(--brand);
  font: inherit;
  font-size: 10.5px;
  cursor: pointer;
  padding: 2px 0;
}
.lot-link:hover { text-decoration: underline; }

.lot-options {
  border-top: 1px solid var(--line);
  margin-top: 10px;
  padding-top: 12px;
  display: flex;
  flex-direction: column;
  gap: 10px;
}
.lot-opt-row { display: flex; align-items: center; gap: 8px; font-size: 11.5px; color: var(--muted); }
.lot-opt-row label { flex: 1; color: var(--ink-2); font-weight: 600; }
.lot-opt-row input[type="text"], .lot-opt-row > input {
  width: 150px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--surface-2);
  color: var(--ink);
  font: inherit;
  font-size: 11.5px;
  padding: 7px 9px;
  outline: none;
}
.lot-opt-row > input:focus { border-color: var(--brand); }
.lot-stepper {
  display: flex;
  align-items: center;
  border: 1px solid var(--line);
  border-radius: 8px;
  overflow: hidden;
  background: var(--surface-2);
}
.lot-stepper button {
  appearance: none;
  border: 0;
  background: transparent;
  color: var(--muted);
  width: 26px;
  height: 28px;
  cursor: pointer;
  font-size: 14px;
}
.lot-stepper button:hover { background: var(--surface); color: var(--ink); }
.lot-stepper input {
  width: 40px;
  border: 0;
  border-left: 1px solid var(--line);
  border-right: 1px solid var(--line);
  background: transparent;
  color: var(--ink);
  text-align: center;
  font: inherit;
  font-size: 12px;
  height: 28px;
  outline: none;
  -moz-appearance: textfield;
}
.lot-stepper input::-webkit-outer-spin-button, .lot-stepper input::-webkit-inner-spin-button { -webkit-appearance: none; margin: 0; }
.lot-check { display: flex; align-items: center; gap: 7px; font-size: 11px; color: var(--muted); cursor: pointer; }
.lot-check input { accent-color: var(--brand); width: 14px; height: 14px; }

.lot-pool {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 8px;
  margin-top: 14px;
}
.lot-pool div {
  border: 1px solid var(--line);
  border-radius: 10px;
  background: var(--surface-2);
  padding: 8px 11px;
}
.lot-pool span { display: block; font-size: 9.5px; color: var(--muted-2); }
.lot-pool strong { font-size: 20px; font-family: var(--mono); color: var(--ink); font-weight: 700; }
.lot-reset {
  margin-top: 10px;
  appearance: none;
  border: 1px solid rgba(239, 68, 68, .2);
  background: rgba(239, 68, 68, .05);
  color: var(--danger);
  border-radius: 8px;
  padding: 8px;
  font: inherit;
  font-size: 10.5px;
  cursor: pointer;
}

.lot-stage {
  position: relative;
  overflow: hidden;
  min-height: 470px;
  display: flex;
  flex-direction: column;
  padding: 18px 22px 22px;
  border-color: rgba(148, 163, 184, .18);
  background:
    radial-gradient(70% 80% at 50% -10%, rgba(251, 191, 36, .2), transparent 65%),
    radial-gradient(50% 60% at 90% 110%, rgba(244, 63, 94, .18), transparent 65%),
    linear-gradient(160deg, #111827, #0b1120 60%, #14101f);
}
[data-theme="light"] .lot-stage {
  background:
    radial-gradient(70% 80% at 50% -10%, rgba(251, 191, 36, .18), transparent 65%),
    radial-gradient(50% 60% at 90% 110%, rgba(244, 63, 94, .14), transparent 65%),
    linear-gradient(160deg, #111827, #0b1120 60%, #14101f);
}
.lot-confetti { position: absolute; inset: 0; width: 100%; height: 100%; pointer-events: none; z-index: 2; }
.lot-stage-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  position: relative;
  z-index: 1;
  font-family: var(--mono);
  font-size: 9.5px;
  letter-spacing: .12em;
  color: rgba(226, 232, 240, .42);
}
.lot-live { display: inline-flex; align-items: center; gap: 6px; }
.lot-live i { width: 5px; height: 5px; border-radius: 50%; background: #fbbf24; box-shadow: 0 0 10px #fbbf24; }

.lot-display {
  flex: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  position: relative;
  z-index: 1;
  padding: 18px 0;
  min-height: 300px;
}
.lot-placeholder { display: flex; flex-direction: column; align-items: center; gap: 4px; color: rgba(226, 232, 240, .55); }
.lot-placeholder span { font-size: 46px; margin-bottom: 6px; filter: drop-shadow(0 8px 20px rgba(251, 191, 36, .25)); }
.lot-placeholder strong { font-size: 20px; color: rgba(248, 250, 252, .82); letter-spacing: -.02em; }
.lot-placeholder small { font-size: 11px; color: rgba(226, 232, 240, .36); }
.lot-rolling {
  font-size: clamp(44px, 8vw, 84px);
  font-weight: 900;
  letter-spacing: -.03em;
  color: #fff;
  text-shadow: 0 6px 40px rgba(251, 191, 36, .22);
  line-height: 1.1;
  max-width: 100%;
  overflow-wrap: anywhere;
}
.lot-rolling.tick { animation: lotTick .09s ease-out; }
@keyframes lotTick {
  0% { transform: translateY(-6px); opacity: .6; filter: blur(1px); }
  100% { transform: translateY(0); opacity: 1; filter: none; }
}
.lot-winners { display: flex; flex-wrap: wrap; justify-content: center; gap: 12px; width: 100%; }
.lot-winner {
  flex: 1 1 180px;
  max-width: 320px;
  background: rgba(255, 255, 255, .04);
  border: 1px solid rgba(251, 191, 36, .22);
  border-radius: 16px;
  padding: 18px 16px;
  color: #fef3c7;
  box-shadow: 0 18px 50px rgba(0, 0, 0, .28), inset 0 1px 0 rgba(255, 255, 255, .06);
  animation: lotPop .45s cubic-bezier(.2, 1.2, .3, 1) both;
}
.lot-winner strong {
  display: block;
  font-size: clamp(28px, 4.5vw, 46px);
  font-weight: 900;
  letter-spacing: -.03em;
  line-height: 1.15;
  overflow-wrap: anywhere;
  color: #fff;
}
.lot-winner small {
  display: inline-block;
  margin-bottom: 6px;
  font-family: var(--mono);
  font-size: 9px;
  letter-spacing: .12em;
  color: rgba(251, 191, 36, .75);
  text-transform: uppercase;
}
@keyframes lotPop {
  0% { transform: scale(.86) translateY(10px); opacity: 0; }
  100% { transform: scale(1) translateY(0); opacity: 1; }
}

.lot-stage-foot { display: flex; flex-direction: column; align-items: center; gap: 8px; position: relative; z-index: 3; }
.lot-draw {
  appearance: none;
  border: 0;
  border-radius: 999px;
  background: linear-gradient(135deg, #fbbf24, #f59e0b 55%, #ea580c);
  color: #1c1400;
  font: inherit;
  font-size: 15px;
  font-weight: 800;
  padding: 14px 38px;
  display: inline-flex;
  align-items: center;
  gap: 9px;
  cursor: pointer;
  box-shadow: 0 14px 36px rgba(245, 158, 11, .3);
  transition: transform .15s, box-shadow .15s;
}
.lot-draw:hover:not(:disabled) { transform: translateY(-2px); box-shadow: 0 18px 42px rgba(245, 158, 11, .38); }
.lot-draw:disabled { opacity: .62; cursor: progress; }
.lot-draw-icon { font-size: 18px; }
.lot-space-tip { font-size: 9.5px; color: rgba(226, 232, 240, .3); font-family: var(--mono); }

.lot-history { margin-top: 18px; padding: 16px 18px; }
.lot-history-head { display: flex; align-items: flex-start; justify-content: space-between; margin-bottom: 10px; }
.lot-history-head h2 { margin: 0; font-size: 14px; }
.lot-history-head span { display: block; margin-top: 3px; font-size: 10.5px; color: var(--muted-2); }
.lot-history-empty { font-size: 11.5px; color: var(--muted-2); padding: 14px 2px; }
.lot-history-list { display: flex; flex-direction: column; gap: 6px; }
.lot-history-row {
  display: flex;
  align-items: center;
  gap: 12px;
  border: 1px solid var(--line);
  background: var(--surface-2);
  border-radius: 9px;
  padding: 8px 11px;
}
.lot-history-round {
  flex: none;
  width: 24px; height: 24px;
  display: grid;
  place-items: center;
  border-radius: 7px;
  background: var(--brand-soft);
  color: var(--brand);
  font-family: var(--mono);
  font-size: 10px;
  font-weight: 700;
}
.lot-history-main { flex: 1; min-width: 0; }
.lot-history-main strong { display: block; font-size: 12px; color: var(--ink-2); overflow-wrap: anywhere; }
.lot-history-main small { display: block; font-size: 9.5px; color: var(--muted-2); margin-top: 2px; }
.lot-history-prize {
  flex: none;
  font-size: 10px;
  color: var(--brand);
  border: 1px solid color-mix(in srgb, var(--brand) 30%, transparent);
  border-radius: 999px;
  padding: 2px 8px;
}

.lot-note {
  display: flex;
  gap: 10px;
  margin-top: 18px;
  padding: 11px 14px;
  border-left: 3px solid color-mix(in srgb, var(--brand) 50%, transparent);
  background: var(--brand-soft);
  border-radius: 0 10px 10px 0;
  font-size: 11px;
  line-height: 1.7;
  color: var(--muted);
}
.lot-note strong { color: var(--ink-2); white-space: nowrap; }

@media (max-width: 520px) {
  .lot-stage { min-height: 390px; padding: 14px; }
  .lot-display { min-height: 230px; }
  .lot-draw { width: 100%; justify-content: center; }
}
