* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

:root {
  --gold: #ffd700;
  --gold2: #ffa500;
  --dark: #0a0a0f;
  --dark2: #12121a;
  --dark3: #1a1a28;
  --accent: #ff4e6a;
  --accent2: #00e5ff;
  --green: #00ff88;
  --purple: #8b5cf6;
  --text: #f0f0f0;
  --muted: #888;
}

body {
  background: var(--dark);
  color: var(--text);
  font-family: "Rajdhani", sans-serif;
  min-height: 100vh;
  overflow-x: hidden;
}
body::after {
  content: var(--wm-text);

  position: fixed;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%) rotate(-20deg);

  font-size: 35px;
  color: rgba(94, 83, 33, 0.529);

  pointer-events: none;
  z-index: 0;
}
/* body::after {
  content: "BRILINKERS SYSTEM ©RPGIT V1.26-SWJ   BRILINKERS SYSTEM ©RPGIT V1.26-SWJ   BRILINKERS SYSTEM ©RPGIT V1.26-SWJ";

  position: fixed;
  top: 0;
  left: 0;
  width: 200%;

  font-size: 40px;
  color: rgba(94, 83, 33, 0.333);

  transform: rotate(-25deg);
  white-space: nowrap;

  pointer-events: none;
  z-index: 0;
} */

.nav::after {
  content: "© 2026 Undian Brilinkers - Internal System";
  position: absolute;
  right: 10px;
  bottom: -18px;
  font-size: 10px;
  opacity: 0.2;
  pointer-events: none;
}
a {
  text-decoration: none;
}
/* SCROLLBAR */
::-webkit-scrollbar {
  width: 6px;
}

::-webkit-scrollbar-track {
  background: var(--dark2);
}

::-webkit-scrollbar-thumb {
  background: var(--gold);
  border-radius: 3px;
}

/* NAV */
.nav {
  background: var(--dark2);
  border-bottom: 2px solid var(--gold);
  padding: 0 2rem;
  display: flex;
  align-items: center;
  gap: 1rem;
  position: sticky;
  top: 0;
  z-index: 100;
}

.nav-logo {
  font-family: "Bebas Neue";
  font-size: 2rem;
  color: var(--gold);
  letter-spacing: 3px;
  padding: 0.8rem 0;
  text-shadow: 0 0 20px rgba(255, 215, 0, 0.5);
}

.nav-tabs {
  display: flex;
  gap: 0.25rem;
  margin-left: 2rem;
}

.nav-tab {
  padding: 0.6rem 1.2rem;
  border: none;
  background: transparent;
  color: var(--muted);
  font-family: "Rajdhani";
  font-size: 1rem;
  font-weight: 600;
  cursor: pointer;
  border-bottom: 3px solid transparent;
  transition: all 0.2s;
  letter-spacing: 1px;
}

.nav-tab:hover {
  color: var(--text);
  background: rgba(255, 255, 255, 0.05);
}

.nav-tab.active {
  color: var(--gold);
  border-bottom-color: var(--gold);
}
.nav {
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.nav-tabs {
  display: flex;
  gap: 10px;
}

.nav-user {
  display: flex;
  align-items: center;
  gap: 10px;
}

.user-name {
  font-weight: bold;
  color: #ffd700;
}
.nav-user {
  background: rgba(255, 215, 0, 0.1);
  padding: 6px 10px;
  border-radius: 8px;
}
/* LAYOUT */
.page {
  padding: 2rem;
  min-height: calc(100vh - 70px);
}

.card {
  background: var(--dark2);
  border: 1px solid rgba(255, 215, 0, 0.15);
  border-radius: 12px;
  padding: 1.5rem;
  margin-bottom: 1.5rem;
}

.card-title {
  font-family: "Bebas Neue";
  font-size: 1.4rem;
  color: var(--gold);
  letter-spacing: 2px;
  margin-bottom: 1rem;
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

/* GRID */
.grid-2 {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1.5rem;
}

.grid-3 {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1rem;
}

/* FORM */
.form-row {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
  gap: 1rem;
  margin-bottom: 1rem;
}

.form-group {
  display: flex;
  flex-direction: column;
  gap: 0.4rem;
}

label {
  font-size: 0.85rem;
  color: var(--muted);
  font-weight: 600;
  letter-spacing: 1px;
  text-transform: uppercase;
}

input,
select {
  background: var(--dark3);
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 8px;
  padding: 0.6rem 0.9rem;
  color: var(--text);
  font-family: "Rajdhani";
  font-size: 1rem;
  transition: border-color 0.2s;
  width: 100%;
}

input:focus,
select:focus {
  outline: none;
  border-color: var(--gold);
}

select option {
  background: var(--dark3);
}

/* BUTTONS */
.btn {
  padding: 0.6rem 1.4rem;
  border: none;
  border-radius: 8px;
  font-family: "Rajdhani";
  font-size: 1rem;
  font-weight: 700;
  cursor: pointer;
  letter-spacing: 1px;
  transition: all 0.2s;
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
}

.btn-gold {
  background: linear-gradient(135deg, var(--gold), var(--gold2));
  color: #000;
}

.btn-gold:hover {
  transform: translateY(-2px);
  box-shadow: 0 4px 20px rgba(255, 215, 0, 0.4);
}

.btn-danger {
  background: var(--accent);
  color: #fff;
}

.btn-danger:hover {
  opacity: 0.85;
}

.btn-cyan {
  background: var(--accent2);
  color: #000;
}

.btn-cyan:hover {
  transform: translateY(-2px);
  box-shadow: 0 4px 20px rgba(0, 229, 255, 0.4);
}

.btn-green {
  background: var(--green);
  color: #000;
}

.btn-sm {
  padding: 0.3rem 0.8rem;
  font-size: 0.85rem;
}

/* TABLE */
.tbl-wrap {
  overflow-x: auto;
  border-radius: 8px;
  border: 1px solid rgba(255, 255, 255, 0.07);
}

table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.95rem;
}

thead th {
  background: rgba(255, 215, 0, 0.1);
  color: var(--gold);
  padding: 0.7rem 1rem;
  text-align: left;
  font-weight: 700;
  letter-spacing: 1px;
  font-size: 0.85rem;
  text-transform: uppercase;
}

tbody tr {
  border-bottom: 1px solid rgba(255, 255, 255, 0.05);
  transition: background 0.15s;
}

tbody tr:hover {
  background: rgba(255, 215, 0, 0.04);
}

tbody td {
  padding: 0.6rem 1rem;
  color: var(--text);
}

.badge {
  display: inline-block;
  padding: 0.2rem 0.6rem;
  border-radius: 20px;
  font-size: 0.78rem;
  font-weight: 700;
  letter-spacing: 0.5px;
}

.badge-sukses {
  background: rgba(0, 255, 136, 0.15);
  color: var(--green);
  border: 1px solid rgba(0, 255, 136, 0.3);
}

.badge-pending {
  background: rgba(255, 215, 0, 0.15);
  color: var(--gold);
  border: 1px solid rgba(255, 215, 0, 0.3);
}

.badge-gagal {
  background: rgba(255, 78, 106, 0.15);
  color: var(--accent);
  border: 1px solid rgba(255, 78, 106, 0.3);
}

.badge-kecil {
  background: rgba(0, 229, 255, 0.1);
  color: var(--accent2);
  border: 1px solid rgba(0, 229, 255, 0.2);
}

.badge-sedang {
  background: rgba(139, 92, 246, 0.1);
  color: var(--purple);
  border: 1px solid rgba(139, 92, 246, 0.2);
}

.badge-besar {
  background: rgba(255, 165, 0, 0.1);
  color: var(--gold2);
  border: 1px solid rgba(255, 165, 0, 0.2);
}

.badge-doorprize {
  background: rgba(255, 78, 106, 0.1);
  color: var(--accent);
  border: 1px solid rgba(255, 78, 106, 0.2);
}

.badge-peserta {
  background: rgba(255, 255, 255, 0.06);
  color: #aaa;
  border: 1px solid rgba(255, 255, 255, 0.12);
}

.badge-pemenang-kecil {
  background: rgba(0, 229, 255, 0.12);
  color: var(--accent2);
  border: 1px solid rgba(0, 229, 255, 0.3);
}

.badge-pemenang-sedang {
  background: rgba(139, 92, 246, 0.12);
  color: var(--purple);
  border: 1px solid rgba(139, 92, 246, 0.3);
}

.badge-pemenang-besar {
  background: rgba(255, 165, 0, 0.12);
  color: var(--gold2);
  border: 1px solid rgba(255, 165, 0, 0.3);
}

.badge-pemenang-doorprize {
  background: rgba(255, 78, 106, 0.12);
  color: var(--accent);
  border: 1px solid rgba(255, 78, 106, 0.3);
}

/* STAT CARD */
.stat-card {
  background: var(--dark3);
  border: 1px solid rgba(255, 255, 255, 0.07);
  border-radius: 10px;
  padding: 1.2rem;
  text-align: center;
}

.stat-num {
  font-family: "Bebas Neue";
  font-size: 2.5rem;
  color: var(--gold);
  line-height: 1;
}

.stat-label {
  font-size: 0.8rem;
  color: var(--muted);
  letter-spacing: 2px;
  text-transform: uppercase;
  margin-top: 0.3rem;
}

/* ===== DRILL PAGE ===== */
.drill-page {
  min-height: 100vh;
  background: radial-gradient(ellipse at center, #1a0030 0%, #0a0a0f 70%);
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: 2rem;
  position: relative;
  overflow: hidden;
}

.drill-bg-lines {
  position: absolute;
  inset: 0;
  pointer-events: none;
  overflow: hidden;
}

.drill-bg-lines::before,
.drill-bg-lines::after {
  content: "";
  position: absolute;
  width: 200%;
  height: 200%;
  top: -50%;
  left: -50%;
  background:
    repeating-linear-gradient(
      0deg,
      transparent,
      transparent 50px,
      rgba(255, 215, 0, 0.02) 50px,
      rgba(255, 215, 0, 0.02) 51px
    ),
    repeating-linear-gradient(
      90deg,
      transparent,
      transparent 50px,
      rgba(255, 215, 0, 0.02) 50px,
      rgba(255, 215, 0, 0.02) 51px
    );
}

.drill-title {
  font-family: "Bebas Neue";
  font-size: clamp(3rem, 8vw, 6rem);
  color: var(--gold);
  letter-spacing: 8px;
  text-shadow:
    0 0 40px rgba(255, 215, 0, 0.6),
    0 0 80px rgba(255, 215, 0, 0.3);
  text-align: center;
  margin-bottom: 0.5rem;
}

.drill-subtitle {
  font-family: "Space Mono";
  font-size: 0.9rem;
  color: var(--accent2);
  letter-spacing: 4px;
  margin-bottom: 3rem;
  text-align: center;
}

.drill-hadiah-info {
  background: rgba(255, 215, 0, 0.07);
  border: 1px solid rgba(255, 215, 0, 0.25);
  border-radius: 16px;
  padding: 1rem 2rem;
  margin-bottom: 2rem;
  text-align: center;
}

.drill-hadiah-nama {
  font-family: "Bebas Neue";
  font-size: 2rem;
  color: var(--gold);
  letter-spacing: 3px;
}

.drill-hadiah-jenis {
  font-size: 0.85rem;
  color: var(--muted);
  letter-spacing: 2px;
  text-transform: uppercase;
}

.name-display {
  width: min(700px, 90vw);
  min-height: 200px;
  background: linear-gradient(
    135deg,
    rgba(26, 0, 48, 0.9),
    rgba(10, 10, 15, 0.95)
  );
  border: 2px solid rgba(255, 215, 0, 0.3);
  border-radius: 20px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 2rem;
  margin: 2rem 0;
  position: relative;
  overflow: hidden;
  box-shadow:
    0 0 60px rgba(255, 215, 0, 0.1),
    inset 0 0 60px rgba(255, 215, 0, 0.03);
}

.name-display::before {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(
    45deg,
    transparent 30%,
    rgba(255, 215, 0, 0.03) 50%,
    transparent 70%
  );
  animation: shimmer 3s infinite;
}

@keyframes shimmer {
  0% {
    transform: translateX(-100%);
  }

  100% {
    transform: translateX(100%);
  }
}

.rolling-name {
  font-family: "Bebas Neue";
  font-size: clamp(3rem, 8vw, 5.5rem);
  color: var(--text);
  letter-spacing: 4px;
  text-align: center;
  line-height: 1.1;
  min-height: 1.2em;
  transition: color 0.1s;
}

.rolling-name.winner {
  color: var(--gold);
  text-shadow:
    0 0 30px rgba(255, 215, 0, 0.8),
    0 0 60px rgba(255, 215, 0, 0.4);
  animation: winnerPulse 0.5s ease-out;
}

@keyframes winnerPulse {
  0% {
    transform: scale(1.2);
  }

  50% {
    transform: scale(0.95);
  }

  100% {
    transform: scale(1);
  }
}

.rolling-asal {
  font-family: "Space Mono";
  font-size: 1rem;
  color: var(--accent2);
  letter-spacing: 3px;
  margin-top: 0.5rem;
  min-height: 1.5em;
}

.drill-controls {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 1rem;
  margin-top: 1rem;
  z-index: 10;
}

.select-hadiah-drill {
  background: var(--dark3);
  border: 1px solid rgba(255, 215, 0, 0.3);
  border-radius: 10px;
  padding: 0.7rem 1.5rem;
  color: var(--gold);
  font-family: "Rajdhani";
  font-size: 1.1rem;
  font-weight: 700;
  cursor: pointer;
  letter-spacing: 1px;
  min-width: 340px;
}

.select-hadiah-drill option:disabled {
  color: #555 !important;
  background: #111 !important;
  font-style: italic;
}

/* REKAP GROUP */
.rekap-group-title {
  font-family: "Bebas Neue";
  font-size: 1.1rem;
  letter-spacing: 3px;
  padding: 0.5rem 0.8rem;
  border-radius: 6px;
  margin: 1.2rem 0 0.6rem;
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.rekap-group-doorprize {
  background: rgba(255, 78, 106, 0.12);
  color: var(--accent);
  border-left: 3px solid var(--accent);
}

.rekap-group-besar {
  background: rgba(255, 165, 0, 0.12);
  color: var(--gold2);
  border-left: 3px solid var(--gold2);
}

.rekap-group-sedang {
  background: rgba(139, 92, 246, 0.12);
  color: var(--purple);
  border-left: 3px solid var(--purple);
}

.rekap-group-kecil {
  background: rgba(0, 191, 255, 0.12);
  color: var(--accent2);
  border-left: 3px solid var(--accent2);
}

.btn-drill {
  padding: 1rem 3rem;
  font-size: 1.3rem;
  letter-spacing: 3px;
  border-radius: 12px;
  position: relative;
  overflow: hidden;
}

.btn-drill.rolling {
  background: linear-gradient(135deg, var(--accent), #ff0055);
  animation: rollPulse 0.5s infinite alternate;
}

@keyframes rollPulse {
  0% {
    box-shadow: 0 0 20px rgba(255, 78, 106, 0.5);
  }

  100% {
    box-shadow:
      0 0 40px rgba(255, 78, 106, 0.9),
      0 0 80px rgba(255, 78, 106, 0.4);
  }
}

/* CONFETTI */
.confetti-container {
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: 9999;
  overflow: hidden;
}

.confetti-piece {
  position: absolute;
  width: 10px;
  height: 10px;
  top: -10px;
  animation: confettiFall linear forwards;
}

@keyframes confettiFall {
  0% {
    transform: translateY(0) rotate(0deg);
    opacity: 1;
  }

  100% {
    transform: translateY(110vh) rotate(720deg);
    opacity: 0;
  }
}

/* WINNER OVERLAY */
.winner-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.85);
  z-index: 500;
  display: flex;
  align-items: center;
  justify-content: center;
  backdrop-filter: blur(4px);
}

.winner-card {
  background: linear-gradient(135deg, var(--dark2), var(--dark3));
  border: 2px solid var(--gold);
  border-radius: 24px;
  padding: 3rem 4rem;
  text-align: center;
  max-width: 600px;
  width: 90%;
  box-shadow:
    0 0 80px rgba(255, 215, 0, 0.3),
    0 0 160px rgba(255, 215, 0, 0.1);
  animation: winnerCardIn 0.5s cubic-bezier(0.34, 1.56, 0.64, 1);
}

@keyframes winnerCardIn {
  from {
    transform: scale(0.5);
    opacity: 0;
  }

  to {
    transform: scale(1);
    opacity: 1;
  }
}

.winner-emoji {
  font-size: 4rem;
  margin-bottom: 1rem;
  display: block;
}

.winner-label {
  font-family: "Space Mono";
  color: var(--accent2);
  font-size: 0.85rem;
  letter-spacing: 4px;
  margin-bottom: 0.5rem;
}

.winner-name-big {
  font-family: "Bebas Neue";
  font-size: clamp(2.5rem, 6vw, 4.5rem);
  color: var(--gold);
  letter-spacing: 4px;
  text-shadow: 0 0 30px rgba(255, 215, 0, 0.6);
  line-height: 1;
}

.winner-asal-big {
  font-size: 1.1rem;
  color: var(--muted);
  margin: 0.5rem 0 1rem;
}

.winner-hadiah-big {
  font-family: "Bebas Neue";
  font-size: 2rem;
  color: var(--accent2);
  letter-spacing: 2px;
}

.winner-actions {
  display: flex;
  gap: 1rem;
  justify-content: center;
  margin-top: 2rem;
}

/* REKAP */
.rekap-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 1rem;
}

.rekap-card {
  background: var(--dark3);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 12px;
  padding: 1.2rem;
  position: relative;
  overflow: hidden;
}

.rekap-card::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 3px;
}

.rekap-card.sukses::before {
  background: var(--green);
}

.rekap-card.pending::before {
  background: var(--gold);
}

.rekap-card.gagal::before {
  background: var(--accent);
}

.rekap-nama {
  font-family: "Bebas Neue";
  font-size: 1.4rem;
  color: var(--text);
  letter-spacing: 2px;
}

.rekap-hadiah {
  font-size: 0.9rem;
  color: var(--gold);
  font-weight: 600;
}

.rekap-info {
  font-size: 0.8rem;
  color: var(--muted);
  margin-top: 0.3rem;
}

/* IMPORT */
.import-zone {
  border: 2px dashed rgba(255, 215, 0, 0.3);
  border-radius: 12px;
  padding: 3rem 2rem;
  text-align: center;
  cursor: pointer;
  transition: all 0.2s;
  background: rgba(255, 215, 0, 0.02);
}

.import-zone:hover,
.import-zone.drag {
  border-color: var(--gold);
  background: rgba(255, 215, 0, 0.05);
}

.import-zone-icon {
  font-size: 3rem;
  margin-bottom: 1rem;
}

.import-zone-text {
  color: var(--muted);
  font-size: 1rem;
}

.import-zone-text strong {
  color: var(--gold);
}

/* TOAST */
.toast-wrap {
  position: fixed;
  bottom: 2rem;
  right: 2rem;
  z-index: 9999;
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}

.toast {
  padding: 0.8rem 1.2rem;
  border-radius: 10px;
  font-weight: 600;
  font-size: 0.95rem;
  letter-spacing: 0.5px;
  animation: toastIn 0.3s ease;
}

@keyframes toastIn {
  from {
    transform: translateX(100%);
    opacity: 0;
  }

  to {
    transform: translateX(0);
    opacity: 1;
  }
}

.toast-success {
  background: var(--green);
  color: #000;
}

.toast-error {
  background: var(--accent);
  color: #fff;
}

.toast-info {
  background: var(--accent2);
  color: #000;
}

/* EMPTY */
.empty {
  text-align: center;
  padding: 3rem;
  color: var(--muted);
}

.empty-icon {
  font-size: 3rem;
  margin-bottom: 1rem;
}

/* 🔥 OVERLAY FULLSCREEN */
.modal-overlay {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;

  background: rgba(0, 0, 0, 0.75);
  backdrop-filter: blur(6px);

  display: flex;
  justify-content: center;
  align-items: center;

  z-index: 9999;
}

/* 🔥 CARD MODAL */
.modal-card {
  background: #0f0f0f;
  color: white;

  padding: 25px;
  border-radius: 16px;

  width: 580px;
  max-width: 90%;

  border: 1px solid rgba(255, 215, 0, 0.4);
  box-shadow: 0 0 25px rgba(255, 215, 0, 0.2);

  text-align: center;

  animation: modalFade 0.3s ease;
}

/* 🔥 BUTTON AREA */
.modal-actions {
  margin-top: 20px;
  display: flex;
  justify-content: space-between;
  gap: 10px;
}

/* 🔥 ANIMATION */
@keyframes modalFade {
  from {
    opacity: 0;
    transform: scale(0.9) translateY(20px);
  }
  to {
    opacity: 1;
    transform: scale(1) translateY(0);
  }
}

/* MOBILE */
@media (max-width: 700px) {
  .grid-2,
  .grid-3 {
    grid-template-columns: 1fr;
  }

  .nav-tabs {
    display: none;
  }

  .form-row {
    grid-template-columns: 1fr;
  }

  .winner-card {
    padding: 2rem 1.5rem;
  }

  .modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.85);
    display: flex;
    justify-content: center;
    align-items: center;
    z-index: 9999;
  }

  .modal-card {
    background: #111;
    padding: 25px;
    border-radius: 12px;
    width: 350px;
    text-align: center;
    border: 1px solid gold;
  }

  .modal-actions {
    margin-top: 20px;
    display: flex;
    justify-content: space-between;
  }
}
