:root {
  --auction-bg: #050504;
  --auction-panel: rgba(12, 13, 13, 0.82);
  --auction-line: rgba(227, 188, 89, 0.45);
  --auction-gold: #ffd875;
  --auction-red: #d92d20;
  --auction-text: #f5f1e8;
  --auction-muted: #b5afa3;
}

.auction-page,
.auction-admin-page {
  min-width: 320px;
  margin: 0;
  overflow-x: hidden;
  color: var(--auction-text);
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  background: #030404 url("/site-background.png") center / cover fixed no-repeat;
}

.auction-shell,
.auction-admin {
  width: min(1180px, calc(100% - 32px));
  display: grid;
  gap: 18px;
  margin: 28px auto;
}

.auction-shell {
  grid-template-columns: minmax(0, 1fr) 340px;
  align-items: start;
}

.auction-stage,
.auction-ranking,
.auction-admin__hero,
.auction-admin__grid {
  border: 1px solid var(--auction-line);
  border-radius: 8px;
  background: var(--auction-panel);
  box-shadow: 0 26px 80px rgba(0, 0, 0, 0.52);
}

.auction-stage,
.auction-ranking,
.auction-admin__hero,
.auction-admin__grid {
  padding: 22px 24px;
}

.auction-stage__header,
.auction-live__header {
  display: grid;
  grid-template-columns: 112px minmax(0, 1fr);
  gap: 16px;
  align-items: center;
  min-height: 120px;
}

.auction-stage__header {
  position: relative;
  grid-template-columns: 156px minmax(0, 1fr);
  gap: 24px;
  min-height: 162px;
  padding: 14px 16px 18px;
  overflow: hidden;
  border: 1px solid rgba(255, 216, 117, 0.16);
  border-radius: 8px;
  background:
    radial-gradient(circle at 84% 12%, rgba(255, 216, 117, 0.12), transparent 32%),
    linear-gradient(135deg, rgba(255, 216, 117, 0.08), transparent 34%),
    rgba(0, 0, 0, 0.18);
}

.auction-stage__header::after {
  content: "";
  position: absolute;
  inset: auto 18px 0;
  height: 1px;
  background: linear-gradient(90deg, transparent, rgba(255, 216, 117, 0.58), transparent);
  opacity: 0.72;
}

.auction-logo {
  width: 108px;
  height: 108px;
  object-fit: contain;
  filter:
    drop-shadow(0 12px 24px rgba(0, 0, 0, 0.48))
    drop-shadow(0 0 22px rgba(255, 216, 117, 0.12));
}

.auction-stage__header .auction-logo {
  width: 148px;
  height: 148px;
  align-self: center;
  justify-self: center;
  padding: 10px;
  border: 1px solid rgba(255, 216, 117, 0.18);
  border-radius: 10px;
  background:
    radial-gradient(circle at 50% 24%, rgba(255, 216, 117, 0.18), transparent 62%),
    rgba(0, 0, 0, 0.16);
  filter:
    drop-shadow(0 18px 30px rgba(0, 0, 0, 0.58))
    drop-shadow(0 0 24px rgba(255, 216, 117, 0.18));
}

.auction-stage h1,
.auction-admin h1,
.auction-live h1 {
  margin: 0;
  color: var(--auction-text);
  line-height: 1.08;
}

.auction-stage h1 {
  font-size: clamp(2.7rem, 4.8vw, 4.15rem);
  letter-spacing: 0;
  text-transform: uppercase;
  text-wrap: balance;
  overflow-wrap: anywhere;
}

.auction-stage__header .eyebrow {
  margin-bottom: 10px;
  color: #ffe38b;
  font-size: 0.78rem;
  letter-spacing: 0.02em;
}

.auction-title-block {
  min-width: 0;
  display: grid;
  align-content: center;
  max-width: 650px;
}

.auction-subtitle {
  max-width: 560px;
  margin: 6px 0 0;
  color: var(--auction-muted);
  font-size: clamp(0.86rem, 1.1vw, 0.98rem);
  font-weight: 800;
  line-height: 1.34;
  overflow-wrap: anywhere;
}

.auction-status {
  display: inline-flex;
  width: max-content;
  margin-top: 9px;
  padding: 6px 10px;
  border: 1px solid rgba(255, 216, 117, 0.28);
  border-radius: 7px;
  color: var(--auction-gold);
  font-weight: 900;
}

.auction-admin-links a {
  min-height: 36px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 8px 12px;
  border: 1px solid rgba(83, 196, 255, 0.32);
  border-radius: 7px;
  color: #9ee4ff;
  font-size: 0.78rem;
  font-weight: 950;
  text-decoration: none;
  text-transform: uppercase;
  background: rgba(24, 143, 205, 0.1);
}

.auction-summary {
  display: grid;
  grid-template-columns: 1fr;
  gap: 12px;
  margin: 18px 0;
}

.auction-summary div,
.auction-live__board > div {
  padding: 16px;
  border: 1px solid rgba(227, 188, 89, 0.28);
  border-radius: 8px;
  background: rgba(0, 0, 0, 0.28);
}

.auction-summary div {
  display: grid;
  align-content: center;
  justify-items: center;
  place-items: center;
  min-height: 96px;
  text-align: center;
}

.auction-summary span,
.auction-live__board span {
  display: block;
  color: var(--auction-muted);
  font-size: 0.78rem;
  font-weight: 900;
  text-transform: uppercase;
}

.auction-summary strong,
.auction-live__board strong {
  display: block;
  margin-top: 6px;
  color: var(--auction-gold);
  font-size: clamp(1.6rem, 4vw, 2.8rem);
  line-height: 1;
}

.auction-leader {
  display: grid;
  align-content: center;
  justify-items: center;
  place-items: center;
  min-height: 118px;
  margin-bottom: 18px;
  padding: 16px;
  border: 1px solid rgba(255, 216, 117, 0.34);
  border-radius: 8px;
  text-align: center;
  background:
    linear-gradient(135deg, rgba(255, 216, 117, 0.14), rgba(0, 0, 0, 0.22));
}

.auction-leader span {
  margin-top: 0;
}

.auction-leader span,
.auction-live__leader-label {
  display: block;
  margin-top: 18px;
  color: var(--auction-muted);
  font-size: 0.78rem;
  font-weight: 900;
  text-transform: uppercase;
}

.auction-leader span {
  margin-top: 0;
}

.auction-leader strong,
.auction-live__leader {
  display: block;
  margin-top: 5px;
  color: var(--auction-gold);
  font-size: clamp(1.35rem, 3vw, 2.2rem);
}

.auction-leader.is-new-leader,
.auction-live__leader.is-new-leader,
.auction-leader-card.is-new-leader,
.auction-live-leader.is-new-leader {
  animation: leaderPulse 1200ms ease-in-out 3;
}

.auction-leaders {
  margin-bottom: 20px;
  padding: 16px;
  overflow: hidden;
  border: 1px solid rgba(255, 216, 117, 0.34);
  border-radius: 8px;
  text-align: center;
  background:
    radial-gradient(circle at 50% 0%, rgba(255, 216, 117, 0.16), transparent 36%),
    linear-gradient(135deg, rgba(255, 216, 117, 0.12), rgba(0, 0, 0, 0.24));
}

.auction-leaders__label {
  display: block;
  margin-bottom: 12px;
  color: var(--auction-muted);
  font-size: 0.78rem;
  font-weight: 900;
  text-transform: uppercase;
}

.auction-leaders__podium {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  align-items: end;
  gap: 12px;
  padding-top: 12px;
}

.auction-leader-card {
  position: relative;
  min-height: 122px;
  display: grid;
  align-content: center;
  justify-items: center;
  gap: 7px;
  padding: 18px 12px 16px;
  border: 1px solid rgba(255, 216, 117, 0.24);
  border-radius: 8px;
  background:
    linear-gradient(180deg, rgba(255, 216, 117, 0.08), rgba(0, 0, 0, 0.28)),
    rgba(0, 0, 0, 0.24);
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.08),
    0 16px 34px rgba(0, 0, 0, 0.24);
}

.auction-leader-card span {
  min-width: 74px;
  padding: 6px 9px;
  border: 1px solid rgba(255, 216, 117, 0.42);
  border-radius: 999px;
  color: #171204;
  font-size: 0.72rem;
  font-weight: 950;
  text-transform: uppercase;
  background: linear-gradient(180deg, #fff0b8, var(--auction-gold));
}

.auction-leader-card strong {
  max-width: 100%;
  color: var(--auction-gold);
  font-size: clamp(1rem, 2vw, 1.45rem);
  line-height: 1.1;
  overflow-wrap: anywhere;
}

.auction-leader-card em {
  color: var(--auction-text);
  font-style: normal;
  font-weight: 900;
}

.auction-leader-card--place-1 {
  order: 2;
  min-height: 148px;
  transform: translateY(-12px);
  border-color: rgba(255, 216, 117, 0.46);
  background:
    radial-gradient(circle at 50% 0%, rgba(255, 216, 117, 0.24), transparent 60%),
    linear-gradient(180deg, rgba(255, 216, 117, 0.14), rgba(0, 0, 0, 0.24));
}

.auction-leader-card--place-2 {
  order: 1;
}

.auction-leader-card--place-3 {
  order: 3;
}

.auction-lots {
  position: relative;
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  align-items: end;
  gap: 14px;
  margin-top: 18px;
  padding: 30px 16px 22px;
  overflow: hidden;
  border: 1px solid rgba(255, 216, 117, 0.24);
  border-radius: 8px;
  background:
    radial-gradient(circle at 50% 5%, rgba(255, 216, 117, 0.16), transparent 30%),
    linear-gradient(180deg, rgba(255, 255, 255, 0.045), rgba(0, 0, 0, 0.18));
}

.auction-lots::before {
  content: "";
  position: absolute;
  inset: auto 20px 16px;
  height: 84px;
  border: 1px solid rgba(255, 216, 117, 0.18);
  border-radius: 8px;
  background:
    linear-gradient(180deg, rgba(255, 216, 117, 0.12), rgba(0, 0, 0, 0.18)),
    rgba(0, 0, 0, 0.24);
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.08),
    0 18px 44px rgba(0, 0, 0, 0.34);
}

.auction-lot {
  position: relative;
  z-index: 1;
  display: grid;
  gap: 12px;
  align-content: start;
  padding: 12px;
  border: 1px solid rgba(255, 216, 117, 0.22);
  border-radius: 8px;
  text-align: center;
  background:
    linear-gradient(180deg, rgba(255, 216, 117, 0.08), rgba(0, 0, 0, 0.32)),
    rgba(0, 0, 0, 0.22);
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.08),
    0 18px 38px rgba(0, 0, 0, 0.28);
}

.auction-lot::before {
  content: attr(data-place);
  justify-self: center;
  min-width: 78px;
  padding: 7px 10px;
  border: 1px solid rgba(255, 216, 117, 0.45);
  border-radius: 999px;
  color: #161104;
  font-size: 0.78rem;
  font-weight: 950;
  text-transform: uppercase;
  background: linear-gradient(180deg, #fff2bd, var(--auction-gold));
  box-shadow: 0 10px 24px rgba(255, 216, 117, 0.18);
}

.auction-lot--place-1 {
  order: 2;
  transform: translateY(-18px);
}

.auction-lot--place-2 {
  order: 1;
  transform: translateY(18px);
}

.auction-lot--place-3 {
  order: 3;
  transform: translateY(28px);
}

.auction-lot--place-1 .auction-lot__image {
  aspect-ratio: 1 / 1.04;
}

.auction-lot--place-1::before {
  min-width: 92px;
  color: #171204;
  background:
    linear-gradient(180deg, #fff7d5, #ffd875 54%, #d9a928);
  box-shadow:
    0 0 0 1px rgba(255, 216, 117, 0.24),
    0 14px 34px rgba(255, 216, 117, 0.28);
}

.auction-lot strong {
  color: var(--auction-text);
  line-height: 1.22;
  overflow-wrap: anywhere;
}

.auction-lot__image {
  aspect-ratio: 1 / 1;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  overflow: hidden;
  border: 1px solid rgba(255, 216, 117, 0.24);
  border-radius: 8px;
  color: var(--auction-gold);
  font-weight: 950;
  background: rgba(0, 0, 0, 0.34);
}

.auction-lot__image img {
  width: 100%;
  height: 100%;
  min-width: 0;
  object-fit: contain;
  object-position: center;
  flex: 0 1 auto;
}

.auction-lot__image img:nth-child(2) {
  width: calc((100% - 6px) / 2);
}

.auction-lot__image img:first-child:nth-last-child(2) {
  width: calc((100% - 6px) / 2);
}

.auction-rules {
  margin-top: 18px;
  padding: 16px;
  border: 1px solid rgba(217, 45, 32, 0.7);
  border-radius: 8px;
  background: rgba(217, 45, 32, 0.13);
}

.auction-rules strong {
  color: #ffb4ab;
}

.auction-ranking ol,
.auction-live__board ol {
  display: grid;
  gap: 8px;
  margin: 14px 0 0;
  padding: 0;
  list-style: none;
}

.auction-ranking {
  position: sticky;
  top: 22px;
  min-height: 620px;
}

.auction-ranking h2 {
  margin: 0;
  font-size: 1.75rem;
}

.auction-ranking__hint {
  margin: 10px 0 0;
  color: var(--auction-muted);
  font-size: 0.86rem;
  line-height: 1.45;
}

.auction-ranking li,
.auction-live__board li {
  display: grid;
  grid-template-columns: 1fr;
  gap: 12px;
  min-height: 74px;
  align-content: center;
  padding: 13px 14px;
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 7px;
  background: rgba(255, 255, 255, 0.04);
}

.auction-ranking li strong,
.auction-live__board li strong {
  color: var(--auction-gold);
  font-size: 1.18rem;
}

.auction-ranking li.is-new-donation,
.auction-live__board li.is-new-donation {
  animation:
    rankSlide 360ms ease both,
    donationGlow 3800ms ease;
}

.auction-results {
  margin-top: 18px;
  padding-top: 18px;
  border-top: 1px solid rgba(227, 188, 89, 0.2);
}

.auction-results[hidden] {
  display: none;
}

.auction-results ol {
  display: grid;
  gap: 8px;
  margin: 12px 0 0;
  padding: 0;
  list-style: none;
}

.auction-admin__grid {
  display: grid;
  grid-template-columns: minmax(0, 1.2fr) minmax(260px, 0.8fr);
  gap: 18px;
}

.auction-login {
  width: min(460px, calc(100% - 32px));
  display: grid;
  gap: 16px;
  margin: 12vh auto 0;
  padding: 26px;
  border: 1px solid var(--auction-line);
  border-radius: 8px;
  background: var(--auction-panel);
}

.auction-login__error {
  margin: 0;
  padding: 11px 12px;
  border: 1px solid rgba(255, 93, 82, 0.58);
  border-radius: 7px;
  color: #ffd7d2;
  font-weight: 800;
  line-height: 1.4;
  background: rgba(128, 21, 14, 0.28);
}

.access-portal {
  width: min(100% - 32px, 1060px);
  display: grid;
  gap: 18px;
  margin: 8vh auto 42px;
}

.access-portal__hero,
.access-portal__card {
  padding: 24px;
  border: 1px solid var(--auction-line);
  border-radius: 8px;
  background: var(--auction-panel);
}

.access-portal__hero {
  display: grid;
  gap: 8px;
}

.access-portal__hero h1,
.access-portal__card h2 {
  margin: 0;
  line-height: 1.02;
}

.access-portal__hero p,
.access-portal__card p {
  margin: 0;
  color: var(--auction-muted);
  font-weight: 800;
  line-height: 1.45;
}

.access-portal__grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 18px;
}

.access-portal__card {
  display: grid;
  align-content: start;
  gap: 14px;
  min-height: 360px;
}

.access-portal__card--admin {
  box-shadow: inset 0 1px 0 rgba(255, 216, 117, 0.16), 0 24px 80px rgba(0, 0, 0, 0.4);
}

.access-portal__card--moderator {
  border-color: rgba(83, 196, 255, 0.38);
  box-shadow: inset 0 1px 0 rgba(83, 196, 255, 0.16), 0 24px 80px rgba(0, 0, 0, 0.4);
}

.auction-admin-hub {
  grid-template-columns: repeat(auto-fit, minmax(230px, 1fr));
}

.auction-hub-card {
  min-height: 170px;
  display: grid;
  align-content: start;
  gap: 12px;
  padding: 20px;
  border: 1px solid rgba(255, 216, 117, 0.24);
  border-radius: 8px;
  color: var(--auction-text);
  text-decoration: none;
  background:
    linear-gradient(140deg, rgba(255, 216, 117, 0.12), transparent 46%),
    rgba(255, 255, 255, 0.035);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.08);
  transition:
    transform 0.2s ease,
    border-color 0.2s ease,
    background 0.2s ease;
}

.auction-hub-card:hover {
  transform: translateY(-2px);
  border-color: rgba(255, 216, 117, 0.48);
  background:
    linear-gradient(140deg, rgba(255, 216, 117, 0.18), transparent 50%),
    rgba(255, 255, 255, 0.055);
}

.auction-hub-card span {
  font-size: 2rem;
  line-height: 1;
}

.auction-hub-card strong {
  color: var(--auction-gold);
  font-size: 1.12rem;
}

.auction-hub-card em {
  color: var(--auction-muted);
  font-style: normal;
  line-height: 1.45;
}

.auction-hub-card.is-disabled {
  opacity: 0.62;
}

.auction-hub-card.is-disabled:hover {
  transform: none;
  border-color: rgba(255, 216, 117, 0.24);
}

.auction-live--locked {
  place-items: center;
}

.auction-form,
.auction-history ul,
.auction-admin-side,
.auction-admin-links {
  display: grid;
  gap: 12px;
}

.auction-form label {
  display: grid;
  gap: 7px;
  color: var(--auction-muted);
  font-weight: 850;
}

.auction-form input,
.auction-form select,
.auction-form textarea {
  min-height: 44px;
  border: 1px solid rgba(227, 188, 89, 0.28);
  border-radius: 7px;
  padding: 10px 12px;
  color: var(--auction-text);
  font: inherit;
  background: rgba(0, 0, 0, 0.32);
}

.auction-form textarea {
  resize: vertical;
  line-height: 1.45;
}

.auction-admin-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.auction-admin-actions .button {
  flex: 1 1 180px;
}

.auction-rate-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
}

.button--danger {
  border: 1px solid rgba(255, 122, 112, 0.45);
  color: #fff0ee;
  background: linear-gradient(180deg, rgba(217, 45, 32, 0.86), rgba(132, 24, 16, 0.88));
  box-shadow: 0 16px 36px rgba(217, 45, 32, 0.18);
}

.button--timer {
  border: 1px solid rgba(97, 255, 129, 0.56);
  color: #071407;
  background: linear-gradient(180deg, #9cff6d, #42d649 58%, #1d9d33);
  box-shadow:
    0 0 0 1px rgba(156, 255, 109, 0.16),
    0 18px 42px rgba(66, 214, 73, 0.28);
}

.button--timer:hover {
  filter: brightness(1.08);
}

.button:disabled,
.auction-form input:disabled,
.auction-form select:disabled {
  cursor: not-allowed;
  opacity: 0.52;
  filter: grayscale(0.35);
}

.auction-save-status {
  margin: 0;
  padding: 10px 12px;
  border: 1px solid rgba(89, 227, 143, 0.4);
  border-radius: 7px;
  color: #a8ffc6;
  font-weight: 900;
  background: rgba(89, 227, 143, 0.1);
}

.auction-offline-status {
  margin: 0;
  padding: 10px 12px;
  border: 1px solid rgba(255, 216, 117, 0.42);
  border-radius: 7px;
  color: var(--auction-gold);
  font-weight: 900;
  background: rgba(255, 216, 117, 0.1);
}

.auction-admin-lots {
  display: grid;
  gap: 12px;
}

.auction-admin-lots fieldset {
  display: grid;
  gap: 10px;
  margin: 0;
  padding: 12px;
  border: 1px solid rgba(227, 188, 89, 0.24);
  border-radius: 8px;
}

.auction-admin-lots legend {
  padding: 0 6px;
  color: var(--auction-gold);
  font-weight: 950;
}

.auction-admin-lots img {
  width: 100%;
  max-height: 180px;
  object-fit: contain;
  border-radius: 7px;
  background: rgba(0, 0, 0, 0.3);
}

.auction-admin-status {
  display: grid;
  gap: 7px;
  padding: 12px;
  border: 1px solid rgba(227, 188, 89, 0.24);
  border-radius: 8px;
  background: rgba(255, 216, 117, 0.06);
}

.auction-admin-status span {
  color: var(--auction-muted);
  font-weight: 850;
}

.auction-admin-status strong {
  color: var(--auction-gold);
  font-size: 1.08rem;
}

.auction-admin-lot-images {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px;
}

.auction-admin-lot-images img:only-child {
  grid-column: 1 / -1;
}

.auction-admin-lot-images img {
  width: 100%;
  height: 180px;
  object-fit: contain;
  object-position: center;
}

.auction-note {
  color: var(--auction-muted);
  line-height: 1.55;
}

.auction-donation-form,
.auction-donation-editor,
.auction-admin-links,
.auction-history {
  display: grid;
  gap: 12px;
  padding: 16px;
  border: 1px solid rgba(227, 188, 89, 0.2);
  border-radius: 8px;
  background: rgba(0, 0, 0, 0.22);
}

.auction-admin-side .auction-donation-form {
  order: 1;
}

.auction-admin-side .auction-music-player {
  order: 2;
}

.auction-admin-side .auction-donation-editor {
  order: 3;
}

.auction-admin-side .auction-admin-links {
  order: 4;
}

.auction-admin-side .auction-history {
  order: 5;
}

.auction-donation-list {
  display: grid;
  gap: 10px;
  max-height: 438px;
  overflow-y: auto;
  padding-right: 6px;
  scrollbar-color: var(--auction-gold) rgba(255, 255, 255, 0.08);
  scrollbar-width: thin;
}

.auction-donation-list::-webkit-scrollbar {
  width: 10px;
}

.auction-donation-list::-webkit-scrollbar-track {
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.08);
}

.auction-donation-list::-webkit-scrollbar-thumb {
  border-radius: 999px;
  background: linear-gradient(180deg, #ffd875, #b88920);
}

.auction-donation-edit {
  display: grid;
  grid-template-columns: minmax(120px, 1fr) minmax(92px, 0.6fr) minmax(90px, 0.55fr) minmax(92px, 0.65fr);
  gap: 8px;
  align-items: end;
  padding: 10px;
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.035);
}

.auction-donation-edit__actions {
  grid-column: 1 / -1;
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px;
}

.auction-donation-edit .button {
  min-height: 40px;
}

.auction-donation-edit__total {
  display: grid;
  gap: 6px;
  min-height: 44px;
  align-content: center;
  padding: 8px 10px;
  border: 1px solid rgba(227, 188, 89, 0.2);
  border-radius: 7px;
  background: rgba(0, 0, 0, 0.22);
}

.auction-donation-edit__total span {
  color: var(--auction-muted);
  font-size: 0.72rem;
  font-weight: 900;
  text-transform: uppercase;
}

.auction-donation-edit__total strong {
  color: var(--auction-gold);
  font-size: 1rem;
}

.auction-music-player {
  display: grid;
  gap: 8px;
  padding: 11px;
  border: 1px solid rgba(83, 196, 255, 0.26);
  border-radius: 8px;
  background: rgba(24, 143, 205, 0.08);
}

.auction-music-player label {
  display: grid;
  gap: 5px;
  color: var(--auction-muted);
  font-size: 0.82rem;
  font-weight: 850;
}

.auction-music-player select,
.auction-music-player input[type="range"] {
  width: 100%;
}

.auction-music-player select {
  min-height: 32px;
  border: 1px solid rgba(83, 196, 255, 0.34);
  border-radius: 7px;
  padding: 6px 9px;
  color: var(--auction-text);
  font: inherit;
  background: rgba(0, 0, 0, 0.32);
}

.auction-music-actions {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 6px;
}

.auction-music-player .button {
  min-height: 31px;
  padding: 6px 8px;
  border-radius: 7px;
  font-size: 0.78rem;
}

.auction-music-player .auction-note {
  margin: 0;
  font-size: 0.78rem;
  line-height: 1.3;
}

.auction-music-shuffle {
  min-height: 30px;
  grid-template-columns: auto 1fr;
  align-items: center;
  justify-content: start;
  column-gap: 8px;
  padding: 6px 8px;
  border: 1px solid rgba(83, 196, 255, 0.22);
  border-radius: 7px;
  background: rgba(0, 0, 0, 0.22);
}

.auction-music-shuffle input {
  width: 16px;
  height: 16px;
  accent-color: #ffe078;
}

.auction-music-progress {
  display: grid;
  gap: 5px;
}

.auction-music-progress__meta {
  display: flex;
  justify-content: space-between;
  color: #9ee4ff;
  font-size: 0.76rem;
  font-weight: 900;
  font-variant-numeric: tabular-nums;
}

.auction-music-progress__bar {
  height: 7px;
  overflow: hidden;
  border: 1px solid rgba(83, 196, 255, 0.28);
  border-radius: 999px;
  background: rgba(0, 0, 0, 0.42);
}

.auction-music-progress__bar span {
  display: block;
  width: 0;
  height: 100%;
  border-radius: inherit;
  background: linear-gradient(90deg, #46d9ff, #ffe078);
  box-shadow: 0 0 18px rgba(83, 196, 255, 0.38);
  transition: width 280ms linear;
}

.auction-history ul {
  margin: 0;
  padding: 0;
  list-style: none;
  max-height: 520px;
  overflow-y: auto;
  padding-right: 6px;
  scrollbar-color: var(--auction-gold) rgba(255, 255, 255, 0.08);
  scrollbar-width: thin;
}

.auction-history ul::-webkit-scrollbar {
  width: 10px;
}

.auction-history ul::-webkit-scrollbar-track {
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.08);
}

.auction-history ul::-webkit-scrollbar-thumb {
  border-radius: 999px;
  background: linear-gradient(180deg, #ffd875, #b88920);
}

.auction-history li {
  display: grid;
  gap: 4px;
  padding: 12px;
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 7px;
  background: rgba(255, 255, 255, 0.035);
}

.auction-history span {
  color: var(--auction-muted);
  font-size: 0.82rem;
}

.auction-live-page {
  margin: 0;
  overflow: auto;
  color: var(--auction-text);
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  background: transparent;
}

.auction-fireworks {
  position: fixed;
  inset: 0;
  z-index: 20;
  pointer-events: none;
  overflow: hidden;
  opacity: 0;
  transition: opacity 220ms ease;
}

.auction-fireworks.is-active {
  opacity: 1;
}

.auction-fireworks span {
  position: absolute;
  left: 50%;
  top: 48%;
  width: 12px;
  height: 12px;
  border-radius: 999px;
  background: #ffd875;
  box-shadow:
    0 -82px #ffd875,
    58px -58px #52c7ff,
    82px 0 #ffffff,
    58px 58px #ff4d4d,
    0 82px #5df284,
    -58px 58px #ffd875,
    -82px 0 #52c7ff,
    -58px -58px #ffffff;
  transform: scale(0);
}

.auction-fireworks.is-active span {
  animation: auctionFirework 1300ms ease-out infinite;
}

.auction-fireworks span:nth-child(1) { left: 25%; top: 30%; animation-delay: 0ms; }
.auction-fireworks span:nth-child(2) { left: 68%; top: 28%; animation-delay: 220ms; }
.auction-fireworks span:nth-child(3) { left: 48%; top: 46%; animation-delay: 420ms; }
.auction-fireworks span:nth-child(4) { left: 78%; top: 58%; animation-delay: 640ms; }
.auction-fireworks span:nth-child(5) { left: 32%; top: 62%; animation-delay: 820ms; }

@keyframes auctionFirework {
  0% {
    transform: scale(0);
    opacity: 0;
  }
  18% {
    transform: scale(0.5);
    opacity: 1;
  }
  100% {
    transform: scale(2.6);
    opacity: 0;
  }
}

.auction-audio-unlock {
  position: fixed;
  right: 18px;
  bottom: 18px;
  z-index: 30;
  min-height: 44px;
  padding: 10px 14px;
  border: 1px solid rgba(255, 216, 117, 0.56);
  border-radius: 8px;
  color: #171204;
  font-weight: 950;
  background: var(--auction-gold);
  box-shadow: 0 16px 38px rgba(255, 216, 117, 0.28);
  cursor: pointer;
}

.auction-live {
  width: 100vw;
  min-height: 100vh;
  display: grid;
  grid-template-rows: auto auto 1fr;
  align-content: start;
  gap: 12px;
  padding: 18px 24px 22px;
  overflow: visible;
  background:
    linear-gradient(135deg, rgba(3, 4, 4, 0.82), rgba(3, 4, 4, 0.58)),
    url("/site-background.png") center / cover no-repeat;
}

.auction-live__header,
.auction-live__prizebar,
.auction-live__board {
  border: 1px solid var(--auction-line);
  border-radius: 8px;
  padding: 14px;
  background: rgba(0, 0, 0, 0.58);
}

.auction-live__header {
  width: min(1540px, calc(100vw - 48px));
  justify-self: center;
  grid-template-columns: 168px minmax(0, 1fr);
  min-height: 154px;
  padding: 14px 22px;
}

.auction-live__header .auction-logo {
  width: 148px;
  height: 148px;
}

.auction-live__header h1 {
  max-width: 100%;
  font-size: clamp(1.45rem, 2.45vw, 3rem);
  line-height: 1.02;
  text-wrap: balance;
}

.auction-live__timer {
  display: grid;
  place-items: center;
  min-height: 124px;
  padding: 12px 14px;
  border: 1px solid rgba(255, 216, 117, 0.34);
  border-radius: 8px;
  background:
    radial-gradient(circle at 50% 0%, rgba(255, 216, 117, 0.22), transparent 58%),
    rgba(0, 0, 0, 0.36);
  color: var(--auction-gold);
  font-size: clamp(2.4rem, 5.2vw, 5.6rem);
  line-height: 1;
  text-align: center;
  font-weight: 950;
}

.auction-live__timer.is-warning {
  border-color: rgba(255, 78, 58, 0.95);
  color: #fff2d2;
  background:
    radial-gradient(circle at 50% 0%, rgba(255, 78, 58, 0.34), transparent 58%),
    rgba(42, 5, 2, 0.72);
  box-shadow:
    0 0 0 1px rgba(255, 216, 117, 0.18),
    0 0 34px rgba(255, 78, 58, 0.48);
  animation: timerWarningPulse 1000ms ease-in-out infinite;
}

.auction-live__prizebar {
  width: min(1540px, calc(100vw - 48px));
  justify-self: center;
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(260px, 0.26fr);
  gap: 12px;
  align-items: stretch;
}

.auction-live__lots {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 10px;
}

.auction-live__lots article {
  min-width: 0;
  display: grid;
  grid-template-columns: 54px minmax(0, 1fr);
  grid-template-rows: minmax(82px, 1fr) auto;
  align-items: center;
  gap: 6px 12px;
  min-height: 146px;
  padding: 10px 12px 12px;
  border: 1px solid rgba(255, 216, 117, 0.18);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.03);
}

.auction-live__lots span {
  grid-row: 1 / 3;
  align-self: center;
  width: 48px;
  height: 48px;
  display: grid;
  place-items: center;
  border-radius: 999px;
  color: #171204;
  font-weight: 950;
  background: var(--auction-gold);
}

.auction-live-lot__image {
  grid-column: 2;
  grid-row: 1;
  justify-self: center;
  width: min(78%, 190px);
  height: 90px;
  min-height: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 5px;
  overflow: hidden;
  border: 1px solid rgba(255, 216, 117, 0.26);
  border-radius: 7px;
  background: rgba(0, 0, 0, 0.34);
}

.auction-live-lot__image img {
  width: auto;
  height: auto;
  min-width: 0;
  max-width: 100%;
  max-height: 100%;
  object-fit: contain;
  object-position: center;
  flex: 0 1 auto;
  transform:
    translate(var(--auction-live-lot-image-x, 0), var(--auction-live-lot-image-y, 0))
    scale(var(--auction-live-lot-image-scale, 1));
  transform-origin: center;
}

.auction-live-lot__image img:first-child:nth-last-child(2),
.auction-live-lot__image img:nth-child(2) {
  max-width: calc((100% - 5px) / 2);
}

.auction-live-lot--place-1 {
  --auction-live-lot-image-scale: 1;
}

.auction-live-lot--place-2 {
  --auction-live-lot-image-scale: 1;
}

.auction-live-lot--place-3 {
  --auction-live-lot-image-scale: 1;
}

.auction-live-lot strong {
  grid-column: 2;
  grid-row: 2;
  justify-self: center;
  min-width: 0;
  max-width: min(94%, 320px);
  color: var(--auction-text);
  font-size: clamp(0.82rem, 0.92vw, 1rem);
  line-height: 1.16;
  text-align: center;
  overflow-wrap: anywhere;
}

.auction-live-lot--place-1 span {
  background: linear-gradient(180deg, #fff4c8, #ffd875 52%, #c99a25);
}

.auction-live-lot--place-2 span {
  background: linear-gradient(180deg, #f7f7f7, #cfd4dc 52%, #808894);
}

.auction-live-lot--place-3 span {
  background: linear-gradient(180deg, #ffd3a3, #c97c30 52%, #7d451d);
}

.auction-live__board {
  --auction-live-participant-column: 250px;
  width: min(1540px, calc(100vw - 48px));
  justify-self: center;
  display: grid;
  grid-template-columns: minmax(0, 320px) minmax(0, 1fr);
  gap: 16px;
  min-height: 0;
  overflow: hidden;
}

.auction-live__board > .auction-live__stats,
.auction-live__board > .auction-live-table-wrap {
  padding: 0;
}

.auction-live__board > .auction-live__stats {
  border: 0;
  background: transparent;
}

.auction-live__stats {
  display: grid;
  align-content: start;
  gap: 14px;
}

.auction-live-total {
  padding: 14px;
  border: 1px solid rgba(255, 216, 117, 0.24);
  border-radius: 8px;
  background: rgba(0, 0, 0, 0.24);
}

.auction-live-total span,
.auction-live__leader-label {
  display: block;
  color: var(--auction-muted);
  font-size: 0.78rem;
  font-weight: 900;
  text-transform: uppercase;
}

.auction-live-total strong {
  display: block;
  margin-top: 8px;
  color: var(--auction-gold);
  font-size: clamp(2rem, 4vw, 3.8rem);
  line-height: 1;
}

.auction-live-leaders {
  display: grid;
  gap: 10px;
  padding: 14px;
  border: 1px solid rgba(255, 216, 117, 0.24);
  border-radius: 8px;
  background:
    radial-gradient(circle at 50% 0%, rgba(255, 216, 117, 0.12), transparent 46%),
    rgba(0, 0, 0, 0.24);
}

.auction-live-leaders__podium {
  display: grid;
  gap: 9px;
}

.auction-live-leader {
  display: grid;
  grid-template-columns: 76px minmax(0, 1fr);
  gap: 5px 10px;
  align-items: center;
  padding: 10px;
  border: 1px solid rgba(255, 216, 117, 0.18);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.035);
}

.auction-live-leader span {
  grid-row: span 2;
  display: grid;
  place-items: center;
  min-height: 44px;
  border-radius: 999px;
  color: #171204;
  font-size: 0.72rem;
  font-weight: 950;
  background: var(--auction-gold);
}

.auction-live-leader strong {
  min-width: 0;
  color: var(--auction-gold);
  font-size: clamp(1rem, 1.9vw, 1.45rem);
  line-height: 1.08;
  overflow-wrap: anywhere;
}

.auction-live-leader em {
  color: var(--auction-text);
  font-style: normal;
  font-weight: 900;
}

.auction-live-leader--place-1 {
  border-color: rgba(255, 216, 117, 0.42);
  background: rgba(255, 216, 117, 0.08);
}

.auction-live-table-wrap {
  width: 100%;
  max-width: 100%;
  min-width: 0;
  min-height: 220px;
  max-height: none;
  overflow-x: auto;
  overflow-y: hidden;
  border: 1px solid rgba(255, 216, 117, 0.5);
  border-radius: 8px;
  background: rgba(5, 7, 8, 0.94);
  box-shadow:
    0 18px 44px rgba(0, 0, 0, 0.36),
    inset 0 1px 0 rgba(255, 216, 117, 0.12);
  scrollbar-color: var(--auction-gold) rgba(255, 255, 255, 0.08);
  scrollbar-width: thin;
}

.auction-live-table-wrap::-webkit-scrollbar {
  width: 10px;
  height: 10px;
}

.auction-live-table-wrap::-webkit-scrollbar-track {
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.08);
}

.auction-live-table-wrap::-webkit-scrollbar-thumb {
  border-radius: 999px;
  background: linear-gradient(90deg, #b88920, #ffd875);
}

.auction-live-table {
  width: max-content;
  min-width: 100%;
  border-collapse: separate;
  border-spacing: 0;
  table-layout: auto;
  color: #eee9df;
  font-size: clamp(0.86rem, 1.12vw, 1.08rem);
  font-weight: 500;
  font-variant-numeric: tabular-nums;
  background: #0b0d0e;
}

.auction-live-table th,
.auction-live-table td {
  width: 100px;
  min-width: 100px;
  max-width: 100px;
  padding: 9px 10px;
  border: 0;
  border-right: 1px solid rgba(227, 188, 89, 0.12);
  border-bottom: 1px solid rgba(227, 188, 89, 0.14);
  overflow: hidden;
  line-height: 1.12;
  text-align: right;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.auction-live-table th:first-child,
.auction-live-table td:first-child {
  position: sticky;
  left: 0;
  z-index: 3;
  min-width: var(--auction-live-participant-column);
  width: var(--auction-live-participant-column);
  max-width: var(--auction-live-participant-column);
  color: #fffaf0;
  font-weight: 900;
  text-align: left;
}

.auction-live-table th:nth-child(2),
.auction-live-table td:nth-child(2) {
  position: sticky;
  left: var(--auction-live-participant-column);
  z-index: 3;
  min-width: 118px;
  width: 118px;
  color: var(--auction-gold);
  font-weight: 900;
  box-shadow: 8px 0 18px rgba(0, 0, 0, 0.24);
}

.auction-live-table thead th {
  position: sticky;
  top: 0;
  z-index: 4;
  color: #cdbf9a;
  background: #191b1d;
  border-bottom: 2px solid rgba(255, 216, 117, 0.42);
}

.auction-live-table thead th:first-child {
  z-index: 6;
  color: #fff7df;
  background: #292313;
}

.auction-live-table thead th:nth-child(2) {
  z-index: 6;
  color: var(--auction-gold);
  background: #17232d;
}

.auction-live-table tbody th:first-child {
  color: #fffaf0;
  background: #121516;
  border-left: 3px solid rgba(255, 216, 117, 0.68);
}

.auction-live-table tbody td:nth-child(2) {
  color: var(--auction-gold);
  background: #0f1921;
}

.auction-live-table tbody td:nth-child(n + 3) {
  color: #ddd8ce;
  background: #0d1011;
}

.auction-live-table tbody tr:nth-child(even) th:first-child {
  background: #181b1c;
}

.auction-live-table tbody tr:nth-child(even) td:nth-child(2) {
  background: #14222c;
}

.auction-live-table tbody tr:nth-child(even) td:nth-child(n + 3) {
  background: #141718;
}

.auction-live-table td.is-empty-donation-cell {
  color: rgba(213, 208, 197, 0.32);
  font-weight: 400;
}

.auction-live-table td.is-new-donation-cell {
  position: relative;
  color: #061305;
  background: #ffe078;
  animation: donationCellPulse 4500ms ease-out both;
}

@keyframes donationCellPulse {
  0% {
    color: #071407;
    background: #7cff8b;
    box-shadow: inset 0 0 0 3px #1bbf4b, 0 0 22px rgba(124, 255, 139, 0.75);
    transform: scale(1.04);
  }
  3% {
    background: #fff5a8;
    box-shadow: inset 0 0 0 3px #ffd875, 0 0 28px rgba(255, 216, 117, 0.82);
  }
  72% {
    color: #061305;
    background: #ffe078;
    box-shadow: inset 0 0 0 2px rgba(255, 216, 117, 0.8), 0 0 14px rgba(255, 216, 117, 0.42);
    transform: scale(1);
  }
  100% {
    color: inherit;
    background: inherit;
    box-shadow: inset 0 0 0 0 transparent, 0 0 0 transparent;
    transform: scale(1);
  }
}

@keyframes rankSlide {
  from {
    opacity: 0;
    transform: translateY(10px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@keyframes donationGlow {
  0%,
  100% {
    border-color: rgba(255, 255, 255, 0.1);
    background: rgba(255, 255, 255, 0.04);
  }
  18%,
  58% {
    border-color: rgba(255, 216, 117, 0.9);
    background: rgba(255, 216, 117, 0.18);
  }
}

@keyframes leaderPulse {
  0%,
  100% {
    filter: none;
    transform: scale(1);
  }
  45% {
    filter: drop-shadow(0 0 22px rgba(255, 216, 117, 0.7));
    transform: scale(1.025);
  }
}

@keyframes timerWarningPulse {
  0%,
  100% {
    transform: scale(1);
    filter: brightness(1);
  }
  50% {
    transform: scale(1.035);
    filter: brightness(1.28);
  }
}

@keyframes raffleWinnerPop {
  0%,
  100% {
    transform: scale(1);
    filter: brightness(1);
  }
  45% {
    transform: scale(1.08);
    filter: brightness(1.18);
  }
}

.notice {
  padding: 12px 14px;
  border: 1px solid rgba(255, 214, 102, 0.35);
  border-radius: 8px;
  margin: 0 0 12px;
  font-weight: 850;
}

.notice--ok {
  color: #9dffbd;
  background: rgba(31, 135, 71, 0.14);
}

.notice--bad {
  color: #ffaaa2;
  background: rgba(160, 31, 22, 0.16);
}

.raffle-admin__links,
.raffle-admin__moderator-row,
.raffle-live__draw,
.raffle-mod__delete {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.raffle-admin__links {
  margin-top: 16px;
}

.raffle-admin__grid {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.raffle-admin__wide {
  grid-column: 1 / -1;
}

.raffle-admin__status,
.raffle-winner-note {
  margin: 0;
  color: var(--auction-gold);
  font-size: 1.1rem;
  font-weight: 950;
}

.raffle-admin__gallery {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.raffle-admin__prize {
  width: min(100%, 360px);
  max-height: 240px;
  object-fit: contain;
  border: 1px solid rgba(255, 216, 117, 0.24);
  border-radius: 8px;
  background: rgba(0, 0, 0, 0.34);
}

.raffle-admin__moderators {
  align-self: start;
}

.raffle-admin__moderators > h2 {
  margin-bottom: 6px;
}

.raffle-admin__moderators > .auction-note {
  margin-bottom: 10px;
  font-size: 0.86rem;
  line-height: 1.35;
}

.raffle-admin__moderator-list {
  max-height: 318px;
  display: grid;
  gap: 8px;
  overflow-y: auto;
  padding-right: 4px;
}

.raffle-admin__moderator-list::-webkit-scrollbar {
  width: 8px;
}

.raffle-admin__moderator-list::-webkit-scrollbar-track {
  background: rgba(255, 216, 117, 0.08);
  border-radius: 999px;
}

.raffle-admin__moderator-list::-webkit-scrollbar-thumb {
  background: linear-gradient(180deg, #f7d66a, #a7751c);
  border-radius: 999px;
}

.raffle-admin__moderator-row {
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  padding: 8px;
  border: 1px solid rgba(255, 216, 117, 0.18);
  border-radius: 8px;
  background: rgba(0, 0, 0, 0.22);
}

.raffle-admin__moderator-row > strong {
  min-width: 118px;
  color: var(--auction-gold);
  font-size: 0.9rem;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.raffle-admin__moderator-password,
.raffle-admin__moderator-delete {
  display: flex;
  gap: 6px;
  align-items: center;
}

.raffle-admin__moderator-password {
  flex: 1 1 260px;
}

.raffle-admin__moderator-password input {
  min-width: 118px;
  min-height: 38px;
  flex: 1 1 150px;
  padding: 8px 10px;
}

.raffle-admin__moderator-row .button {
  min-height: 38px;
  padding: 8px 12px;
  font-size: 0.78rem;
}

.raffle-mod {
  width: min(100% - 18px, 720px);
  display: grid;
  gap: 12px;
  margin: 10px auto 32px;
}

.raffle-mod__header {
  order: 1;
}

.raffle-mod > .notice {
  order: 2;
}

.raffle-mod__recent {
  order: 3;
}

.raffle-mod__bulk-edit {
  order: 4;
}

.raffle-mod__form {
  order: 5;
}

.raffle-number-grid {
  order: 6;
}

.raffle-mod__prize {
  order: 7;
}

.raffle-mod__header,
.raffle-mod__prize,
.raffle-mod__recent,
.raffle-mod__bulk-edit,
.raffle-mod__form {
  padding: 14px;
  border: 1px solid var(--auction-line);
  border-radius: 8px;
  background: var(--auction-panel);
}

.raffle-mod__recent {
  display: grid;
  gap: 8px;
}

.raffle-mod__recent .eyebrow {
  margin: 0;
}

.raffle-mod__recent > div {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 8px;
}

.raffle-mod__recent article {
  min-width: 0;
  padding: 9px;
  border: 1px solid rgba(255, 216, 117, 0.18);
  border-radius: 8px;
  background: rgba(255, 216, 117, 0.07);
}

.raffle-copy-button {
  width: 100%;
  min-height: 30px;
  margin-top: 7px;
  border: 1px solid rgba(255, 216, 117, 0.34);
  border-radius: 7px;
  color: #111;
  font: inherit;
  font-size: 0.76rem;
  font-weight: 950;
  cursor: pointer;
  background: linear-gradient(180deg, #ffe282, #e0aa2c);
}

.raffle-mod__recent strong,
.raffle-mod__recent span {
  display: block;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.raffle-mod__recent strong {
  color: var(--auction-gold);
  font-size: 0.94rem;
}

.raffle-mod__recent span {
  color: var(--auction-text);
  font-size: 0.82rem;
  font-weight: 900;
}

.raffle-mod__bulk-edit {
  display: grid;
  gap: 8px;
}

.raffle-mod__bulk-edit h2 {
  margin: 0;
  font-size: 1.05rem;
  line-height: 1.12;
}

.raffle-mod__bulk-edit .auction-form {
  grid-template-columns: minmax(0, 1.5fr) minmax(92px, 0.55fr);
  gap: 8px;
}

.raffle-mod__bulk-edit .button {
  grid-column: 1 / -1;
}

.raffle-mod__header {
  position: sticky;
  top: 0;
  z-index: 5;
  display: flex;
  justify-content: space-between;
  gap: 12px;
  align-items: start;
}

.raffle-mod__header h1,
.raffle-mod__form h2 {
  margin: 0;
  line-height: 1.08;
}

.raffle-mod__header h1 {
  font-size: clamp(1.2rem, 5.8vw, 1.85rem);
}

.raffle-mod__header p {
  margin: 6px 0 0;
  color: var(--auction-muted);
  font-weight: 850;
}

.raffle-mod__locked-number {
  display: grid;
  gap: 10px;
  padding: 12px;
  border: 1px solid rgba(255, 216, 117, 0.24);
  border-radius: 8px;
  background: rgba(255, 216, 117, 0.06);
}

.raffle-mod__locked-number p {
  margin: 0;
  color: var(--auction-muted);
  font-weight: 800;
}

.raffle-mod__locked-number strong {
  color: var(--auction-gold);
}

.raffle-mod__prize {
  display: grid;
  grid-template-columns: 120px minmax(0, 1fr);
  gap: 12px;
  align-items: center;
}

.raffle-mod__gallery {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 6px;
}

.raffle-mod__gallery img,
.raffle-mod__prize img {
  width: 120px;
  height: 120px;
  object-fit: contain;
  border: 1px solid rgba(255, 216, 117, 0.24);
  border-radius: 8px;
  background: rgba(0, 0, 0, 0.36);
}

.raffle-mod__gallery img {
  width: 100%;
}

.raffle-prize-upload {
  display: grid;
  gap: 8px;
}

.raffle-prize-upload > span {
  color: var(--auction-muted);
  font-weight: 900;
}

.raffle-prize-upload label {
  padding: 9px;
  border: 1px solid rgba(255, 216, 117, 0.16);
  border-radius: 8px;
  background: rgba(0, 0, 0, 0.2);
}

.raffle-mod__contest-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.raffle-mod__contest-actions .button {
  flex: 1 1 160px;
}

.raffle-number-grid {
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: 8px;
}

.raffle-number {
  min-height: 74px;
  display: grid;
  place-items: center;
  padding: 8px 5px;
  border: 1px solid rgba(255, 216, 117, 0.24);
  border-radius: 8px;
  color: var(--auction-text);
  text-align: center;
  text-decoration: none;
  background: rgba(0, 0, 0, 0.36);
}

.raffle-number strong {
  color: var(--auction-gold);
  font-size: 1.35rem;
  line-height: 1;
}

.raffle-number span {
  width: 100%;
  color: var(--auction-muted);
  font-size: 0.68rem;
  font-weight: 900;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.raffle-number.is-free {
  border-color: rgba(97, 255, 129, 0.38);
  background: linear-gradient(180deg, rgba(29, 157, 51, 0.22), rgba(0, 0, 0, 0.32));
}

.raffle-number.is-taken {
  border-color: rgba(255, 216, 117, 0.48);
  background: linear-gradient(180deg, rgba(255, 216, 117, 0.2), rgba(0, 0, 0, 0.36));
}

.raffle-number.is-selected {
  outline: 3px solid rgba(83, 196, 255, 0.86);
  outline-offset: 2px;
}

.notice--sync {
  border-color: rgba(83, 196, 255, 0.45);
  color: #bdeeff;
  background: rgba(33, 151, 220, 0.14);
}

.raffle-mod__form {
  position: static;
  z-index: 4;
}

.raffle-mod__delete {
  margin-top: 10px;
}

.raffle-live-page {
  min-width: 320px;
  min-height: 100vh;
  margin: 0;
  overflow-y: auto;
  color: var(--auction-text);
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  background: #030404 url("/site-background.png") center / cover fixed no-repeat;
}

.raffle-live {
  width: min(1600px, calc(100% - 32px));
  min-height: calc(100vh - 14px);
  display: grid;
  grid-template-rows: auto minmax(calc(100vh - 150px), auto) auto;
  gap: 8px;
  margin: 7px auto;
  overflow: visible;
}

.raffle-live__hero,
.raffle-live__layout,
.raffle-live__participants,
.raffle-live__draw {
  border: 1px solid var(--auction-line);
  border-radius: 8px;
  background: rgba(4, 5, 5, 0.82);
  box-shadow: 0 26px 80px rgba(0, 0, 0, 0.52);
}

.raffle-live__hero {
  display: grid;
  grid-template-columns: 230px minmax(0, 1fr) minmax(190px, 230px);
  gap: 12px;
  align-items: center;
  min-height: 108px;
  padding: 8px 14px;
}

.raffle-live__participants--hero {
  display: none !important;
}

.raffle-live__prize {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 6px;
}

.raffle-live__prize img {
  width: 100%;
  height: 86px;
  object-fit: contain;
  border: 1px solid rgba(255, 216, 117, 0.24);
  border-radius: 8px;
  background: rgba(0, 0, 0, 0.34);
}

.raffle-live__title h1 {
  margin: 0;
  font-size: clamp(1.22rem, 1.95vw, 2.05rem);
  line-height: 1.08;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  text-wrap: unset;
}

.raffle-live__title .eyebrow,
.raffle-live__title p {
  display: none;
}

.raffle-live__title p {
  margin: 3px 0 0;
  color: var(--auction-muted);
  font-size: clamp(0.84rem, 1.2vw, 1.08rem);
  font-weight: 900;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.raffle-live__title strong {
  display: inline-block;
  margin-top: 3px;
  color: var(--auction-gold);
  font-size: clamp(1.68rem, 3.25vw, 3rem);
  line-height: 0.95;
}

.raffle-live__title span {
  margin-left: 10px;
  color: var(--auction-muted);
  font-weight: 900;
  text-transform: uppercase;
}

.raffle-live__winner {
  min-width: 0;
  min-height: 86px;
  display: grid;
  align-content: center;
  justify-items: center;
  padding: 10px;
  border: 1px solid rgba(255, 216, 117, 0.34);
  border-radius: 8px;
  text-align: center;
  background: radial-gradient(circle at 50% 20%, rgba(255, 216, 117, 0.2), transparent 60%), rgba(0, 0, 0, 0.28);
}

.raffle-live__winner span,
.raffle-live__participants h2 {
  margin: 0;
  color: var(--auction-muted);
  font-size: 0.76rem;
  font-weight: 950;
  text-transform: uppercase;
}

.raffle-live__winner strong {
  max-width: 100%;
  color: var(--auction-gold);
  font-size: clamp(1.18rem, 1.75vw, 1.86rem);
  line-height: 1.02;
  overflow-wrap: anywhere;
}

.raffle-live__winner p {
  max-width: 100%;
  margin: 0;
  font-size: clamp(0.7rem, 0.85vw, 0.86rem);
  line-height: 1.24;
  font-weight: 950;
  overflow-wrap: anywhere;
}

.raffle-live__layout {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: 0;
  min-height: 0;
  padding: 8px 14px;
  overflow: hidden;
}

.raffle-live__numbers {
  display: grid;
  grid-template-columns: repeat(10, minmax(0, 1fr));
  gap: 4px;
  align-content: stretch;
  min-height: 0;
  height: 100%;
  overflow: hidden;
}

.raffle-live-number {
  min-height: 0;
  height: clamp(38px, calc((100vh - 196px) / 10), 56px);
  display: grid;
  place-items: center;
  padding: 5px 4px;
  border: 1px solid rgba(255, 216, 117, 0.2);
  border-radius: 7px;
  text-align: center;
  background: rgba(0, 0, 0, 0.32);
}

.raffle-live-number strong {
  color: var(--auction-gold);
  font-size: clamp(0.92rem, 1.25vw, 1.14rem);
  line-height: 1;
}

.raffle-live-number span {
  width: 100%;
  color: var(--auction-muted);
  font-size: clamp(0.62rem, 0.82vw, 0.78rem);
  font-weight: 900;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.raffle-live-number.is-winner {
  position: relative;
  z-index: 4;
  border-color: rgba(255, 255, 255, 0.98);
  color: #1b1202;
  background:
    radial-gradient(circle at 50% 30%, rgba(255, 255, 255, 0.9), transparent 34%),
    linear-gradient(180deg, #fff3a8, #ffd875 48%, #e69d20);
  box-shadow:
    0 0 0 3px rgba(255, 216, 117, 0.34),
    0 0 42px rgba(255, 216, 117, 0.76);
  animation: raffleWinnerPop 1200ms ease-in-out infinite;
}

.raffle-live-number.is-winner strong,
.raffle-live-number.is-winner span {
  color: #1b1202;
}

.raffle-live--standard .raffle-live__numbers {
  grid-template-rows: repeat(10, minmax(0, 1fr));
}

.raffle-live--standard .raffle-live-number {
  height: auto;
  min-height: 0;
}

.raffle-live--standard .raffle-live-number strong {
  font-size: clamp(1rem, 1.5vw, 1.38rem);
}

.raffle-live--standard .raffle-live-number span {
  font-size: clamp(0.68rem, 0.9vw, 0.86rem);
}

.raffle-live--many .raffle-live__hero {
  min-height: 112px;
  grid-template-columns: 200px minmax(0, 1fr) minmax(170px, 210px);
}

.raffle-live--many .raffle-live__title h1 {
  font-size: clamp(1.08rem, 1.75vw, 1.85rem);
}

.raffle-live--many .raffle-live__prize img {
  height: 88px;
}

.raffle-live--many .raffle-live__numbers {
  grid-template-columns: repeat(15, minmax(0, 1fr));
}

.raffle-live--many .raffle-live-number {
  height: clamp(28px, calc((100vh - 168px) / 14), 44px);
}

.raffle-live--huge .raffle-live__hero {
  min-height: 96px;
  grid-template-columns: 170px minmax(0, 1fr) minmax(150px, 180px);
}

.raffle-live--huge .raffle-live__title h1 {
  font-size: clamp(0.95rem, 1.42vw, 1.45rem);
}

.raffle-live--huge .raffle-live__title p,
.raffle-live--huge .raffle-live__title span {
  font-size: 0.82rem;
}

.raffle-live--huge .raffle-live__title strong {
  font-size: clamp(1.45rem, 2.4vw, 2.3rem);
}

.raffle-live--huge .raffle-live__prize img {
  height: 72px;
}

.raffle-live--huge .raffle-live__layout {
  grid-template-columns: minmax(0, 1fr);
  gap: 0;
  padding: 10px;
}

.raffle-live--huge .raffle-live__numbers {
  grid-template-columns: repeat(20, minmax(0, 1fr));
  gap: 4px;
}

.raffle-live--huge .raffle-live-number {
  height: clamp(24px, calc((100vh - 146px) / 15), 38px);
  padding: 3px;
}

.raffle-live--huge .raffle-live-number strong {
  font-size: 0.86rem;
}

.raffle-live--huge .raffle-live-number span {
  font-size: 0.58rem;
}

.raffle-live-number.is-taken {
  border-color: rgba(255, 216, 117, 0.5);
  background: linear-gradient(180deg, rgba(255, 216, 117, 0.22), rgba(0, 0, 0, 0.32));
}

.raffle-live-number.is-free {
  opacity: 0.68;
}

.raffle-live-number.is-winner,
.raffle-live-number.is-taken.is-winner,
.raffle-live-number.is-free.is-winner {
  position: relative;
  z-index: 20;
  opacity: 1;
  border: 2px solid #ffffff;
  color: #090601;
  background:
    radial-gradient(circle at 50% 18%, rgba(255, 255, 255, 0.95), rgba(255, 255, 255, 0.2) 28%, transparent 54%),
    linear-gradient(180deg, #fff7c7 0%, #ffe16d 38%, #ffb51f 70%, #d8790c 100%);
  box-shadow:
    0 0 0 4px rgba(255, 216, 117, 0.42),
    0 0 0 8px rgba(0, 209, 255, 0.22),
    0 0 46px rgba(255, 216, 117, 0.92),
    inset 0 0 18px rgba(255, 255, 255, 0.42);
  animation: raffleWinnerPop 1050ms ease-in-out infinite;
}

.raffle-live-number.is-winner strong,
.raffle-live-number.is-taken.is-winner strong,
.raffle-live-number.is-free.is-winner strong {
  color: #050505;
  font-size: clamp(1.16rem, 1.85vw, 1.72rem);
  font-weight: 1000;
  text-shadow:
    0 1px 0 rgba(255, 255, 255, 0.75),
    0 0 12px rgba(255, 255, 255, 0.82);
}

.raffle-live-number.is-winner span,
.raffle-live-number.is-taken.is-winner span,
.raffle-live-number.is-free.is-winner span {
  color: #050505;
  font-size: clamp(0.78rem, 1vw, 0.98rem);
  font-weight: 1000;
  text-shadow:
    0 1px 0 rgba(255, 255, 255, 0.72),
    0 0 10px rgba(255, 255, 255, 0.78);
}

.raffle-live__side {
  display: none;
  gap: 14px;
  align-content: start;
}

.raffle-live__participants,
.raffle-live__draw {
  padding: 10px;
}

.raffle-live__participants > div {
  max-height: 78px;
  overflow: auto;
  display: grid;
  gap: 5px;
  margin-top: 8px;
  padding-right: 4px;
}

.raffle-live__participants article {
  padding: 6px 8px;
  border: 1px solid rgba(255, 216, 117, 0.18);
  border-radius: 8px;
  background: rgba(255, 216, 117, 0.07);
}

.raffle-live__participants strong,
.raffle-live__participants span {
  display: block;
}

.raffle-live__participants strong {
  color: var(--auction-gold);
  font-size: 0.88rem;
}

.raffle-live__participants span {
  color: var(--auction-muted);
  font-size: 0.74rem;
  font-weight: 850;
}

.raffle-live__participants--summary {
  margin: 0 14px 18px;
  border: 1px solid rgba(255, 216, 117, 0.24);
  border-radius: 8px;
  background: rgba(0, 0, 0, 0.34);
}

.raffle-live__participants--summary > div {
  max-height: none;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  overflow: visible;
}

.raffle-live__participants--summary article {
  display: flex;
  justify-content: space-between;
  gap: 10px;
  align-items: center;
}

.raffle-live__participants--summary strong {
  color: var(--auction-text);
  font-size: 0.98rem;
}

.raffle-live__participants--summary span {
  color: var(--auction-gold);
  font-size: 0.98rem;
  text-align: right;
  white-space: nowrap;
}

@media (max-width: 860px) {
  .auction-shell,
  .auction-admin__grid,
  .auction-live__board {
    grid-template-columns: 1fr;
  }

  .auction-shell {
    width: min(100% - 18px, 620px);
    gap: 12px;
    margin-block: 12px;
  }

  .auction-stage,
  .auction-ranking {
    padding: 14px;
  }

  .auction-rate-grid,
  .auction-donation-edit {
    grid-template-columns: 1fr;
  }

  .auction-stage__header,
  .auction-live__header {
    grid-template-columns: 82px minmax(0, 1fr);
    min-height: auto;
  }

  .auction-stage__header {
    grid-template-columns: 76px minmax(0, 1fr);
    gap: 10px;
    padding: 10px;
  }

  .auction-logo {
    width: 82px;
    height: 82px;
  }

  .auction-stage__header .auction-logo {
    width: 72px;
    height: 72px;
    padding: 5px;
  }

  .auction-stage h1 {
    font-size: clamp(1.65rem, 10vw, 2.35rem);
  }

  .auction-subtitle {
    max-width: none;
    font-size: 0.76rem;
  }

  .auction-summary,
  .auction-leaders,
  .auction-lots,
  .auction-rules {
    margin-top: 12px;
    margin-bottom: 12px;
  }

  .auction-summary div,
  .auction-leader,
  .auction-leaders {
    min-height: auto;
    padding: 12px;
  }

  .auction-summary strong {
    font-size: clamp(1.65rem, 9vw, 2.3rem);
  }

  .auction-ranking {
    position: static;
    min-height: auto;
  }

  .auction-live__prizebar {
    grid-template-columns: 1fr;
  }

  .auction-live__timer {
    justify-self: center;
    width: min(100%, 360px);
    min-height: 88px;
  }

  .auction-lots,
  .auction-live__lots {
    grid-template-columns: 1fr;
  }

  .auction-live__lots article {
    grid-template-columns: 52px minmax(0, 1fr);
    grid-template-rows: minmax(82px, 1fr) auto;
    min-height: 144px;
  }

  .auction-live__lots span {
    width: 46px;
    height: 46px;
  }

  .auction-live-lot__image {
    width: min(82%, 180px);
    height: 88px;
    min-height: 0;
  }

  .raffle-admin__grid,
  .access-portal__grid,
  .raffle-live__hero,
  .raffle-live__layout,
  .raffle-mod__prize {
    grid-template-columns: 1fr;
  }

  .access-portal {
    width: min(100% - 18px, 620px);
    margin-top: 18px;
  }

  .access-portal__hero,
  .access-portal__card {
    padding: 16px;
  }

  .access-portal__card {
    min-height: auto;
  }

  .raffle-mod__header {
    align-items: stretch;
    flex-direction: column;
  }

  .raffle-number-grid {
    grid-template-columns: repeat(4, minmax(0, 1fr));
  }

  .raffle-number {
    min-height: 68px;
  }

  .raffle-mod__prize img {
    width: min(100%, 180px);
    height: 140px;
    justify-self: center;
  }

  .raffle-live {
    width: min(100% - 18px, 720px);
    height: auto;
    min-height: 100vh;
    overflow: visible;
  }

  .raffle-live-page {
    height: auto;
    min-height: 100vh;
    overflow-y: auto;
  }

  .raffle-live__hero {
    gap: 10px;
    padding: 12px;
  }

  .raffle-live__prize img {
    width: min(100%, 280px);
    height: 130px;
  }

  .raffle-live__numbers {
    grid-template-columns: repeat(4, minmax(0, 1fr));
    grid-template-rows: none;
    height: auto;
    align-content: start;
    overflow: visible;
  }

  .raffle-live-number {
    height: auto;
    min-height: 58px;
    padding: 7px 3px;
  }

  .raffle-live--standard .raffle-live__numbers {
    grid-template-rows: none;
  }

  .raffle-live--standard .raffle-live-number {
    height: auto;
    min-height: 58px;
  }

  .raffle-live-number strong {
    font-size: 1.08rem;
  }

  .raffle-live-number span {
    font-size: 0.56rem;
  }

  .auction-lots {
    padding: 14px;
  }

  .auction-leaders__podium {
    grid-template-columns: 1fr;
    padding-top: 0;
  }

  .auction-leader-card,
  .auction-leader-card--place-1 {
    min-height: auto;
    order: initial;
    transform: none;
  }

  .auction-lots::before {
    display: none;
  }

  .auction-lot--place-1,
  .auction-lot--place-2,
  .auction-lot--place-3 {
    order: initial;
    transform: none;
  }
}

@media (max-width: 640px) {
  .raffle-mod {
    width: min(100% - 10px, 520px);
    gap: 7px;
    margin: 5px auto 18px;
  }

  .raffle-mod__header,
  .raffle-mod__prize,
  .raffle-mod__recent,
  .raffle-mod__form {
    padding: 9px;
    border-radius: 7px;
  }

  .raffle-mod__recent > div {
    grid-template-columns: 1fr;
    gap: 5px;
  }

  .raffle-mod__recent article {
    padding: 7px 9px;
  }

  .raffle-live__participants--summary {
    margin: 0 8px 14px;
  }

  .raffle-live__participants--summary > div {
    grid-template-columns: 1fr;
  }

  .raffle-mod__header {
    gap: 7px;
  }

  .raffle-mod__header .eyebrow {
    margin-bottom: 2px;
    font-size: 0.64rem;
  }

  .raffle-mod__header h1 {
    font-size: clamp(1rem, 5.8vw, 1.45rem);
    line-height: 1.04;
  }

  .raffle-mod__header p {
    margin-top: 3px;
    font-size: 0.76rem;
  }

  .raffle-mod__header .button {
    min-height: 42px;
    padding: 9px 12px;
  }

  .raffle-number-grid {
    grid-template-columns: repeat(5, minmax(0, 1fr));
    gap: 5px;
  }

  .raffle-number {
    min-height: 66px;
    padding: 7px 3px;
    border-radius: 7px;
  }

  .raffle-number strong {
    font-size: 1.32rem;
  }

  .raffle-number span {
    font-size: 0.62rem;
  }

  .raffle-mod__form {
    position: static;
    padding-bottom: 10px;
  }

  .raffle-mod__form .eyebrow {
    margin-bottom: 4px;
    font-size: 0.7rem;
  }

  .raffle-mod__form h2 {
    font-size: clamp(1.15rem, 6vw, 1.55rem);
  }

  .raffle-mod__form .auction-form {
    gap: 8px;
  }

  .raffle-mod__form .auction-form label {
    gap: 5px;
    font-size: 0.78rem;
  }

  .raffle-mod__form input,
  .raffle-mod__form textarea {
    min-height: 38px;
    padding: 8px 10px;
    font-size: 0.95rem;
  }

  .raffle-mod__form textarea {
    min-height: 58px;
  }

  .raffle-mod__form .button,
  .raffle-mod__delete .button {
    min-height: 44px;
    padding: 10px 12px;
  }

  .raffle-mod__delete {
    margin-top: 7px;
  }
}
