/* =============================================================
   CTFd Pixo – WordPress Pixel Theme Match
   Font: Press Start 2P
   Palette: #141428, #1c1c3a, #151a2d, #202743, #090916
            #72e2f3 (cyan), #3b63ff (blue), #fdf7f6 (light)
            #ffd85c (yellow), #e5485f (red), #f49b45 (orange)
   ============================================================= */

/* ----- CSS Variables ----- */
:root {
  --px-bg-1: #141428;
  --px-bg-2: #1c1c3a;
  --px-bg-3: #151a2d;
  --px-bg-4: #202743;
  --px-dark: #090916;
  --px-cyan: #72e2f3;
  --px-blue: #3b63ff;
  --px-light: #fdf7f6;
  --px-light-2: #f4f1f8;
  --px-light-3: #e0ddf8;
  --px-yellow: #ffd85c;
  --px-red: #e5485f;
  --px-orange: #f49b45;
  --px-font: "Press Start 2P", monospace;
  --px-scanline-bg: repeating-linear-gradient(
    90deg,
    #141428 0, #141428 4px,
    #1c1c3a 4px, #1c1c3a 8px
  ), linear-gradient(#151a2d, #202743);
}

/* =========================
   GLOBAL / BODY
   ========================= */

html {
  min-height: 100%;
}

html,
body {
  font-family: var(--px-font) !important;
  background: var(--px-bg-1) !important;
  color: var(--px-light) !important;
  image-rendering: pixelated;
  margin: 0;
  padding: 0;
}

body {
  display: flex !important;
  flex-direction: column;
  min-height: 100vh;
}

body {
  background:
    repeating-linear-gradient(
      90deg,
      #141428 0, #141428 4px,
      #1c1c3a 4px, #1c1c3a 8px
    ),
    linear-gradient(#151a2d, #202743) !important;
  background-attachment: fixed !important;
}

/* Scanline overlay (the .scanline div already exists in base.html) */
.scanline {
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: 9999;
  background: repeating-linear-gradient(
    rgba(9, 9, 22, 0.25) 0,
    rgba(9, 9, 22, 0.25) 2px,
    transparent 2px,
    transparent 4px
  );
  mix-blend-mode: multiply;
}

/* =========================
   TYPOGRAPHY
   ========================= */

h1, h2, h3, h4, h5, h6 {
  font-family: var(--px-font) !important;
  color: var(--px-light) !important;
  letter-spacing: 0.06em;
}

h1, h2 {
  text-shadow: none !important;
}

p, span, label, b, strong, small, li, td, th, div {
  font-family: var(--px-font) !important;
}

a {
  color: var(--px-cyan) !important;
  text-decoration: none !important;
}

a:hover {
  color: var(--px-blue) !important;
  text-shadow: 0 0 6px rgba(114, 226, 243, 0.95);
  text-decoration: underline !important;
}

.text-muted {
  color: var(--px-light-3) !important;
}

.text-secondary {
  color: var(--px-light-3) !important;
}

blockquote {
  border-left: 4px solid var(--px-cyan) !important;
  padding-left: 15px;
}

/* =========================
   NAVBAR
   ========================= */

.navbar {
  font-family: var(--px-font) !important;
  background:
    repeating-linear-gradient(
      90deg,
      #141428 0, #141428 4px,
      #1c1c3a 4px, #1c1c3a 8px
    ),
    linear-gradient(#151a2d, #202743) !important;
  border-bottom: 4px solid var(--px-cyan) !important;
  box-shadow: 0 4px 0 var(--px-dark) !important;
  image-rendering: pixelated;
  position: relative;
}

.navbar::after {
  content: "";
  position: absolute;
  inset: 0;
  pointer-events: none;
  background: repeating-linear-gradient(
    rgba(9, 9, 22, 0.35) 0,
    rgba(9, 9, 22, 0.35) 2px,
    transparent 2px,
    transparent 4px
  );
  mix-blend-mode: multiply;
}

.navbar-brand {
  font-family: var(--px-font) !important;
  font-size: 16px !important;
  color: var(--px-cyan) !important;
  text-shadow: none !important;
  letter-spacing: 1px;
}

.navbar-brand:hover {
  color: var(--px-light) !important;
}

.navbar-brand img {
  image-rendering: pixelated;
}

.nav-link {
  font-family: var(--px-font) !important;
  font-size: 10px !important;
  letter-spacing: 1px !important;
  color: var(--px-light) !important;
  text-shadow: 1px 1px var(--px-dark) !important;
  padding: 8px 12px !important;
  transition: background 0.15s, color 0.15s;
}

.nav-link:hover,
.nav-link:focus {
  background: var(--px-bg-1) !important;
  color: var(--px-yellow) !important;
  text-shadow: 0 0 6px rgba(255, 216, 92, 0.8) !important;
}

.navbar-toggler {
  border-color: var(--px-cyan) !important;
}

.navbar-toggler-icon {
  background-image: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 30 30'%3e%3cpath stroke='%2372e2f3' stroke-linecap='round' stroke-miterlimit='10' stroke-width='2' d='M4 7h22M4 15h22M4 23h22'/%3e%3c/svg%3e") !important;
}

.navbar-collapse {
  background:
    repeating-linear-gradient(
      90deg,
      #141428 0, #141428 4px,
      #1c1c3a 4px, #1c1c3a 8px
    ),
    linear-gradient(#151a2d, #202743) !important;
}

.navbar .dropdown-menu {
  background: var(--px-bg-1) !important;
  border: 2px solid var(--px-cyan) !important;
  box-shadow: 0 4px 8px rgba(9, 9, 22, 0.7);
}

.navbar .dropdown-item {
  color: var(--px-cyan) !important;
  font-size: 10px !important;
}

.navbar .dropdown-item:hover {
  background: var(--px-bg-2) !important;
  color: var(--px-blue) !important;
}

/* =========================
   JUMBOTRON / HERO
   ========================= */

.jumbotron {
  background:
    repeating-linear-gradient(
      90deg,
      #141428 0, #141428 4px,
      #1c1c3a 4px, #1c1c3a 8px
    ),
    linear-gradient(#151a2d, #202743) !important;
  color: var(--px-light) !important;
  border-radius: 0 !important;
  text-align: center;
  padding: 20px 20px !important;
  margin-bottom: 0 !important;
  box-shadow: none;
  image-rendering: pixelated;
  position: relative;
  border-bottom: 2px solid rgba(114, 226, 243, 0.3);
}

.jumbotron h1 {
  font-family: var(--px-font) !important;
  font-size: clamp(24px, 4vw, 48px) !important;
  color: var(--px-light) !important;
  letter-spacing: 0.08em;
  text-shadow: none !important;
  margin-top: 0 !important;
  margin-bottom: 0 !important;
}

.jumbotron h2 {
  color: var(--px-yellow) !important;
  text-shadow: none !important;
}

.jumbotron h2 small {
  color: var(--px-yellow) !important;
}

.jumbotron h3 {
  color: var(--px-yellow) !important;
}

.pbadge-secondary {
  color: var(--px-yellow) !important;
}

.pbadge-primary {
  color: var(--px-yellow) !important;
}

/* =========================
   CONTAINER / MAIN CONTENT
   ========================= */

.container {
  font-family: var(--px-font) !important;
}

main {
  flex: 1 0 auto;
  margin-bottom: 0 !important;
  padding-top: 0 !important;
}

/* Disable CRT flicker animation from main.min.css */
main:before {
  animation: none !important;
  opacity: 0 !important;
  display: none !important;
}

main .container {
  padding-top: 20px;
  padding-bottom: 20px;
}

/* =========================
   FORMS
   ========================= */

.form-control {
  font-family: var(--px-font) !important;
  font-size: 10px !important;
  background: rgba(12, 16, 32, 0.9) !important;
  color: var(--px-light) !important;
  border: 2px solid rgba(114, 226, 243, 0.4) !important;
  border-radius: 0 !important;
  padding: 12px !important;
  transition: border-color 0.2s, box-shadow 0.2s;
}

.form-control::placeholder {
  color: rgba(224, 221, 248, 0.4) !important;
}

.form-control:focus {
  background: rgba(12, 16, 32, 0.95) !important;
  border-color: var(--px-cyan) !important;
  box-shadow:
    0 0 0 2px rgba(114, 226, 243, 0.3),
    0 0 12px rgba(114, 226, 243, 0.25) !important;
  color: var(--px-light) !important;
}

.input-filled-valid {
  background: rgba(12, 16, 32, 0.95) !important;
  border-color: var(--px-cyan) !important;
  box-shadow: 0 0 0 2px rgba(114, 226, 243, 0.3) !important;
}

.input-filled-invalid {
  border-color: var(--px-red) !important;
  box-shadow: 0 0 0 2px rgba(229, 72, 95, 0.3) !important;
}

.form-group b,
.form-group label {
  color: var(--px-cyan) !important;
  font-size: 10px !important;
  letter-spacing: 0.08em;
  margin-bottom: 6px !important;
  display: inline-block;
}

.form-text.text-muted {
  font-size: 8px !important;
  color: var(--px-light-3) !important;
}

select.form-control,
.custom-select {
  background-color: rgba(12, 16, 32, 0.9) !important;
  color: var(--px-light) !important;
  background-image: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 4 5'%3e%3cpath fill='%2372e2f3' d='M2 0L0 2h4zm0 5L0 3h4z'/%3e%3c/svg%3e") !important;
  background-repeat: no-repeat !important;
  background-position: right 0.75rem center !important;
  background-size: 8px 10px !important;
}

/* =========================
   BUTTONS
   ========================= */

.btn {
  font-family: var(--px-font) !important;
  font-size: 10px !important;
  letter-spacing: 1px;
  border-radius: 0 !important;
  padding: 10px 22px !important;
  cursor: pointer;
  text-transform: uppercase;
  transition:
    transform 0.16s ease-out,
    box-shadow 0.16s ease-out,
    background 0.2s ease-out;
  image-rendering: pixelated;
}

.btn-primary,
.btn-primary.btn-outlined {
  background: rgba(10, 20, 32, 0.35) !important;
  color: var(--px-light) !important;
  border: 2px solid var(--px-cyan) !important;
  box-shadow:
    0 0 0 1px var(--px-dark),
    0 0 12px rgba(114, 226, 243, 0.4),
    inset 0 0 8px rgba(114, 226, 243, 0.15) !important;
}

.btn-primary:hover,
.btn-primary.btn-outlined:hover {
  transform: translateY(-2px);
  background: rgba(16, 32, 48, 0.45) !important;
  box-shadow:
    0 0 0 1px var(--px-dark),
    0 0 20px rgba(114, 226, 243, 0.7),
    inset 0 0 12px rgba(114, 226, 243, 0.35) !important;
}

.btn-info {
  background: rgba(59, 99, 255, 0.3) !important;
  border: 2px solid var(--px-blue) !important;
  color: var(--px-light) !important;
  box-shadow:
    0 0 8px rgba(59, 99, 255, 0.3),
    inset 0 0 6px rgba(59, 99, 255, 0.15) !important;
}

.btn-info:hover {
  transform: translateY(-2px);
  background: rgba(59, 99, 255, 0.5) !important;
  box-shadow:
    0 0 16px rgba(59, 99, 255, 0.6),
    inset 0 0 10px rgba(59, 99, 255, 0.3) !important;
}

.btn-secondary {
  background: rgba(10, 20, 32, 0.35) !important;
  color: var(--px-light-2) !important;
  border: 2px solid var(--px-light-3) !important;
}

.btn-secondary:hover {
  background: rgba(16, 32, 48, 0.45) !important;
  border-color: var(--px-cyan) !important;
  color: var(--px-light) !important;
}

.btn-danger {
  background: rgba(229, 72, 95, 0.3) !important;
  border: 2px solid var(--px-red) !important;
  color: var(--px-light) !important;
}

.btn-danger:hover {
  background: rgba(229, 72, 95, 0.5) !important;
}

.btn-success {
  background: rgba(55, 214, 62, 0.3) !important;
  border: 2px solid #37d63e !important;
  color: var(--px-light) !important;
}

.btn-success:hover {
  background: rgba(55, 214, 62, 0.5) !important;
}

/* =========================
   CARDS
   ========================= */

.card {
  background: rgba(12, 16, 32, 0.85) !important;
  border: 2px solid rgba(114, 226, 243, 0.25) !important;
  border-radius: 0 !important;
  color: var(--px-light) !important;
  box-shadow: 0 2px 8px rgba(9, 9, 22, 0.5);
}

.card.bg-light {
  background: rgba(20, 20, 40, 0.9) !important;
}

.card-body {
  color: var(--px-light) !important;
}

.card-title {
  color: var(--px-cyan) !important;
}

/* =========================
   TABLES
   ========================= */

.table {
  color: var(--px-light) !important;
  font-size: 10px;
}

.table thead th,
.table thead td {
  border-bottom: 2px solid rgba(114, 226, 243, 0.5) !important;
  border-top: none !important;
  color: var(--px-cyan) !important;
  font-size: 10px;
  letter-spacing: 0.1em;
  text-transform: uppercase;
}

.table td,
.table th {
  border-top: 1px solid rgba(114, 226, 243, 0.1) !important;
  padding: 10px 12px !important;
  vertical-align: middle;
}

.table-striped tbody tr:nth-of-type(odd) {
  background-color: rgba(20, 20, 40, 0.6) !important;
}

.table-striped tbody tr:nth-of-type(even) {
  background-color: rgba(12, 16, 32, 0.4) !important;
}

.table tbody tr:hover {
  background-color: rgba(114, 226, 243, 0.08) !important;
}

/* =========================
   MODALS (Challenge window)
   ========================= */

/* Lift modal above .challenge-button / .sb-podium / #score-graph (all z-index: 10000) */
.modal-backdrop {
  z-index: 20000 !important;
}

.modal,
.modal.show {
  z-index: 20001 !important;
}

.modal-dialog {
  z-index: 20002 !important;
  position: relative;
}

/* Make download/file buttons readable + clear of the submit row */
.challenge-files {
  position: relative;
  z-index: 1;
  display: flex !important;
  flex-wrap: wrap;
  justify-content: center;
  gap: 10px;
  margin: 16px 0 24px 0 !important;
  padding-bottom: 0 !important;
  clear: both;
  width: 100%;
}

.challenge-files .file-button-wrapper {
  flex: 0 0 auto;
  max-width: 100%;
  padding: 0 !important;
  margin: 0 !important;
  display: inline-block !important;
}

.challenge-files .btn-file {
  display: inline-flex !important;
  align-items: center;
  justify-content: center;
  gap: 8px;
  width: auto !important;
  min-width: 160px;
  padding: 10px 18px !important;
  color: var(--px-light) !important;
  white-space: normal !important;
  word-break: break-all;
  text-decoration: none !important;
}

.challenge-files .btn-file small {
  color: var(--px-light) !important;
  font-size: 10px !important;
}

.challenge-files .btn-file i.fas,
.challenge-files .btn-file .fa-download {
  color: var(--px-cyan) !important;
  margin-right: 6px;
  font-style: normal;
}

/* Make sure submit row sits cleanly below files row */
.submit-row {
  clear: both;
  margin-top: 8px !important;
}

.modal-content {
  background:
    repeating-linear-gradient(
      90deg,
      #141428 0, #141428 4px,
      #1c1c3a 4px, #1c1c3a 8px
    ),
    linear-gradient(#151a2d, #202743) !important;
  border: 3px solid var(--px-cyan) !important;
  border-radius: 0 !important;
  color: var(--px-light) !important;
  box-shadow:
    0 0 0 2px var(--px-dark),
    0 0 30px rgba(114, 226, 243, 0.3),
    inset 0 0 20px rgba(9, 9, 22, 0.5) !important;
  image-rendering: pixelated;
}

.modal-header {
  border-bottom: 1px solid rgba(114, 226, 243, 0.3) !important;
}

.modal-footer {
  border-top: 1px solid rgba(114, 226, 243, 0.3) !important;
}

.close {
  color: var(--px-cyan) !important;
  text-shadow: 0 1px 0 var(--px-dark) !important;
  opacity: 0.8 !important;
  font-size: 20px !important;
}

.close:hover {
  color: var(--px-red) !important;
  opacity: 1 !important;
}

/* =========================
   TABS (inside modals, settings)
   ========================= */

.nav-tabs {
  border-bottom: 2px solid rgba(114, 226, 243, 0.3) !important;
}

.nav-tabs .nav-link {
  color: var(--px-light-3) !important;
  border: none !important;
  border-bottom: 2px solid transparent !important;
  font-size: 10px !important;
  background: transparent !important;
}

.nav-tabs .nav-link.active,
.nav-tabs .nav-link:hover {
  color: var(--px-cyan) !important;
  border-bottom-color: var(--px-cyan) !important;
  background: transparent !important;
}

.nav-pills .nav-link {
  color: var(--px-light-3) !important;
  font-size: 10px !important;
  border-radius: 0 !important;
}

.nav-pills .nav-link.active {
  background: rgba(114, 226, 243, 0.15) !important;
  color: var(--px-cyan) !important;
  border-left: 3px solid var(--px-cyan) !important;
}

.tab-content {
  color: var(--px-light) !important;
}

/* =========================
   CHALLENGES BOARD
   ========================= */

.challenge-button {
  font-family: var(--px-font) !important;
  font-size: 10px !important;
  background: rgba(12, 16, 32, 0.9) !important;
  color: var(--px-cyan) !important;
  border: 2px solid rgba(114, 226, 243, 0.5) !important;
  box-shadow:
    0 0 8px rgba(114, 226, 243, 0.2),
    inset 0 0 6px rgba(9, 9, 22, 0.5) !important;
  transition: all 0.2s ease;
  border-radius: 0 !important;
  position: relative;
  z-index: 10000;
  isolation: isolate;
  image-rendering: auto !important;
  mix-blend-mode: normal !important;
}

.challenge-button * {
  image-rendering: auto !important;
  mix-blend-mode: normal !important;
}

.challenge-button:hover {
  transform: translateY(-2px);
  background: rgba(114, 226, 243, 0.1) !important;
  background-color: rgba(114, 226, 243, 0.1) !important;
  border-color: var(--px-cyan) !important;
  box-shadow:
    0 0 16px rgba(114, 226, 243, 0.5),
    inset 0 0 8px rgba(114, 226, 243, 0.15) !important;
  color: var(--px-light) !important;
}

.solved-challenge {
  background: rgba(55, 214, 62, 0.15) !important;
  border-color: rgba(55, 214, 62, 0.5) !important;
  opacity: 1 !important;
  box-shadow:
    0 0 8px rgba(55, 214, 62, 0.2),
    inset 0 0 6px rgba(9, 9, 22, 0.5) !important;
}

.corner-button-check {
  display: none !important;
}

.challenge-name {
  color: var(--px-light) !important;
  text-shadow: 0 0 6px rgba(114, 226, 243, 0.6);
  font-size: 18px !important;
}

.challenge-value {
  color: var(--px-yellow) !important;
  font-size: 14px !important;
  text-shadow: 0 0 8px rgba(255, 216, 92, 0.5);
}

.challenge-desc,
.chal-desc {
  color: var(--px-light-2) !important;
  font-size: 10px !important;
  line-height: 2 !important;
  text-align: center !important;
  display: block;
}

.challenge-desc *,
.chal-desc * {
  text-align: center !important;
}

.challenge-tag,
.badge-info {
  background: rgba(59, 99, 255, 0.3) !important;
  border: 1px solid var(--px-blue) !important;
  color: var(--px-light) !important;
  font-size: 8px !important;
  border-radius: 0 !important;
  padding: 4px 8px !important;
}

/* Challenge input & submit */
.challenge-input {
  font-family: var(--px-font) !important;
  font-size: 10px !important;
  width: 100%;
  height: 44px !important;
  padding: 0 12px !important;
  background: rgba(12, 16, 32, 0.9) !important;
  color: var(--px-light) !important;
  border: 2px solid rgba(114, 226, 243, 0.4) !important;
  border-radius: 0 !important;
  box-sizing: border-box;
}

.challenge-input:focus {
  border-color: var(--px-cyan) !important;
  box-shadow: 0 0 12px rgba(114, 226, 243, 0.3) !important;
  outline: none;
}

.challenge-submit {
  font-family: var(--px-font) !important;
  font-size: 10px !important;
  width: 100%;
  height: 44px !important;
  padding: 0 20px !important;
  background: rgba(10, 20, 32, 0.35) !important;
  color: var(--px-light) !important;
  border: 2px solid var(--px-cyan) !important;
  cursor: pointer;
  text-transform: uppercase;
  letter-spacing: 1px;
  box-shadow:
    0 0 8px rgba(114, 226, 243, 0.3),
    inset 0 0 6px rgba(114, 226, 243, 0.1) !important;
  transition: all 0.16s ease-out;
}

.challenge-submit:hover {
  transform: translateY(-2px);
  box-shadow:
    0 0 18px rgba(114, 226, 243, 0.6),
    inset 0 0 12px rgba(114, 226, 243, 0.3) !important;
}

/* Keep submit row inside modal */
.submit-row {
  margin-left: 0 !important;
  margin-right: 0 !important;
}

.submit-row .form-group {
  padding-left: 0 !important;
  padding-right: 0 !important;
}

.submit-row .col-md-9 {
  padding-right: 8px !important;
}

.submit-row .col-md-3 {
  padding-left: 0 !important;
}

.key-submit {
  display: flex;
  align-items: flex-end;
}

.challenge-submit {
  border-radius: 0 !important;
  box-sizing: border-box !important;
}

/* Connection info */
.challenge-connection-info code {
  background: rgba(12, 16, 32, 0.95) !important;
  color: var(--px-cyan) !important;
  border: 1px solid rgba(114, 226, 243, 0.3);
  padding: 4px 10px;
  font-family: var(--px-font) !important;
  font-size: 10px !important;
}

/* =========================
   ALERTS / NOTIFICATIONS
   ========================= */

.alert {
  border-radius: 0 !important;
  font-size: 10px;
  border: 2px solid;
  background: rgba(12, 16, 32, 0.9) !important;
}

.alert-success {
  border-color: #37d63e !important;
  color: #37d63e !important;
}

.alert-danger {
  border-color: var(--px-red) !important;
  color: var(--px-red) !important;
}

.alert-warning {
  border-color: var(--px-orange) !important;
  color: var(--px-orange) !important;
}

.alert-info {
  border-color: var(--px-cyan) !important;
  color: var(--px-cyan) !important;
}

/* =========================
   BADGES
   ========================= */

.badge {
  font-family: var(--px-font) !important;
  font-size: 8px !important;
  border-radius: 0 !important;
  padding: 4px 8px !important;
  letter-spacing: 0.5px;
}

.badge-primary {
  background: rgba(59, 99, 255, 0.4) !important;
  border: 1px solid var(--px-blue);
}

.badge-danger {
  background: rgba(229, 72, 95, 0.4) !important;
  border: 1px solid var(--px-red);
}

.badge-notification {
  background: var(--px-red) !important;
}

/* =========================
   SPINNER
   ========================= */

.fa-spin.spinner,
.spinner {
  color: var(--px-cyan) !important;
  opacity: 0.7 !important;
}

.spinner-error {
  color: var(--px-red) !important;
}

/* =========================
   FOOTER
   ========================= */

.footer {
  font-family: var(--px-font) !important;
  padding: 28px 24px 18px !important;
  margin: 0 !important;
  border-top: 4px solid var(--px-cyan) !important;
  background:
    repeating-linear-gradient(
      90deg,
      #090916 0, #090916 4px,
      #141428 4px, #141428 8px
    ),
    linear-gradient(#090916, #151a2d) !important;
  box-shadow:
    0 -4px 0 var(--px-dark),
    0 -10px 30px rgba(0, 0, 0, 0.9) !important;
  color: var(--px-light-2) !important;
  position: static !important;
  flex-shrink: 0;
  width: 100% !important;
  height: auto !important;
  min-height: 60px;
  line-height: normal !important;
  z-index: auto !important;
  image-rendering: pixelated;
}

.footer::before {
  content: "";
  position: absolute;
  inset: 0;
  pointer-events: none;
  background: repeating-linear-gradient(
    to bottom,
    rgba(9, 9, 22, 0.22) 0px,
    rgba(9, 9, 22, 0.22) 2px,
    transparent 2px,
    transparent 4px
  );
  mix-blend-mode: multiply;
}

.footer small,
.footer .text-muted {
  color: var(--px-light-3) !important;
  font-size: 8px !important;
}

.footer a {
  color: var(--px-cyan) !important;
}

.footer a:hover {
  text-shadow: 0 0 6px rgba(114, 226, 243, 0.95);
}


/* =========================
   SEPARATOR / HR
   ========================= */

hr {
  border: none !important;
  height: 1px !important;
  background: linear-gradient(
    90deg,
    transparent,
    rgba(114, 226, 243, 0.5),
    transparent
  ) !important;
  margin: 20px 0 !important;
}

/* =========================
   SCORE GRAPH
   ========================= */

#score-graph {
  min-height: 400px;
  background: rgba(12, 16, 32, 0.85);
  border: 1px solid rgba(114, 226, 243, 0.2);
  border-radius: 8px;
  box-shadow: 0 0 20px rgba(9, 9, 22, 0.5), inset 0 0 30px rgba(9, 9, 22, 0.3);
  padding: 8px;
  position: relative;
  z-index: 10000;
  isolation: isolate;
  image-rendering: auto !important;
  mix-blend-mode: normal !important;
}

#score-graph * {
  image-rendering: auto !important;
  mix-blend-mode: normal !important;
}

.sb-podium,
.sb-table {
  position: relative;
  z-index: 10000;
  isolation: isolate;
  image-rendering: auto !important;
  mix-blend-mode: normal !important;
}

.sb-podium *,
.sb-table * {
  image-rendering: auto !important;
  mix-blend-mode: normal !important;
}

/* =========================
   SCOREBOARD PODIUM
   ========================= */

.sb-podium {
  display: flex;
  justify-content: center;
  align-items: flex-end;
  gap: 16px;
  margin: 40px auto 50px;
  max-width: 800px;
}

.sb-podium-card {
  flex: 1;
  max-width: 220px;
  text-align: center;
  padding: 24px 16px 0;
  border-radius: 12px 12px 0 0;
  position: relative;
  background: rgba(12, 16, 32, 0.8);
  border: 2px solid rgba(114, 226, 243, 0.15);
  border-bottom: none;
  overflow: hidden;
}

.sb-podium-card.sb-gold {
  border-color: rgba(255, 216, 92, 0.4);
  box-shadow: 0 0 30px rgba(255, 216, 92, 0.12), inset 0 0 20px rgba(255, 216, 92, 0.05);
  padding-top: 12px;
}

.sb-podium-card.sb-silver {
  border-color: rgba(200, 210, 230, 0.3);
  box-shadow: 0 0 20px rgba(200, 210, 230, 0.08);
}

.sb-podium-card.sb-bronze {
  border-color: rgba(244, 155, 69, 0.3);
  box-shadow: 0 0 20px rgba(244, 155, 69, 0.08);
}

.sb-podium-crown {
  font-size: 20px;
  color: var(--px-yellow);
  margin-bottom: 4px;
  text-shadow: 0 0 16px rgba(255, 216, 92, 0.6);
  animation: crownFloat 3s ease-in-out infinite;
}

@keyframes crownFloat {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(-4px); }
}

.sb-podium-rank {
  font-family: var(--px-font);
  font-size: 11px;
  color: var(--px-light-3);
  letter-spacing: 2px;
  margin-bottom: 8px;
}

.sb-podium-icon {
  font-size: 28px;
  margin-bottom: 12px;
}

.sb-gold .sb-podium-icon {
  color: var(--px-yellow);
  text-shadow: 0 0 20px rgba(255, 216, 92, 0.5);
}

.sb-silver .sb-podium-icon {
  color: var(--px-light-2);
  text-shadow: 0 0 16px rgba(200, 210, 230, 0.4);
}

.sb-bronze .sb-podium-icon {
  color: var(--px-orange);
  text-shadow: 0 0 16px rgba(244, 155, 69, 0.4);
}

.sb-podium-name {
  display: block;
  font-family: var(--px-font) !important;
  font-size: 9px !important;
  color: var(--px-light) !important;
  text-decoration: none !important;
  letter-spacing: 1px;
  margin-bottom: 8px;
  word-break: break-all;
}

.sb-podium-name:hover {
  color: var(--px-cyan) !important;
  text-shadow: 0 0 8px rgba(114, 226, 243, 0.5);
}

.sb-podium-score {
  font-family: var(--px-font);
  font-size: 16px;
  font-weight: bold;
  margin-bottom: 16px;
}

.sb-podium-score span {
  font-size: 7px;
  color: var(--px-light-3);
  letter-spacing: 1px;
}

.sb-gold .sb-podium-score {
  color: var(--px-yellow);
  text-shadow: 0 0 12px rgba(255, 216, 92, 0.4);
}

.sb-silver .sb-podium-score {
  color: var(--px-light-2);
}

.sb-bronze .sb-podium-score {
  color: var(--px-orange);
}

.sb-podium-bar {
  height: 6px;
  margin: 0 -16px;
}

.sb-bar-gold {
  background: linear-gradient(90deg, transparent, var(--px-yellow), transparent);
  box-shadow: 0 0 12px rgba(255, 216, 92, 0.4);
}

.sb-bar-silver {
  background: linear-gradient(90deg, transparent, var(--px-light-3), transparent);
  box-shadow: 0 0 8px rgba(200, 210, 230, 0.3);
}

.sb-bar-bronze {
  background: linear-gradient(90deg, transparent, var(--px-orange), transparent);
  box-shadow: 0 0 8px rgba(244, 155, 69, 0.3);
}

/* =========================
   SCOREBOARD TABLE
   ========================= */

.sb-table {
  border-collapse: separate;
  border-spacing: 0 4px;
}

.sb-table thead td {
  font-size: 8px !important;
  letter-spacing: 3px !important;
  text-transform: uppercase;
  color: var(--px-light-3) !important;
  border-bottom: 1px solid rgba(114, 226, 243, 0.2) !important;
  padding-bottom: 12px !important;
}

.sb-table tbody tr {
  transition: all 0.15s ease;
}

.sb-table tbody tr:hover {
  transform: translateX(4px);
}

.sb-row-gold {
  background: rgba(255, 216, 92, 0.06) !important;
  border-left: 3px solid var(--px-yellow);
}

.sb-row-silver {
  background: rgba(200, 210, 230, 0.04) !important;
  border-left: 3px solid var(--px-light-3);
}

.sb-row-bronze {
  background: rgba(244, 155, 69, 0.04) !important;
  border-left: 3px solid var(--px-orange);
}

.sb-rank-badge {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 28px;
  height: 28px;
  border-radius: 6px;
  font-size: 12px;
}

.sb-badge-gold {
  background: rgba(255, 216, 92, 0.15);
  color: var(--px-yellow);
  border: 1px solid rgba(255, 216, 92, 0.3);
  box-shadow: 0 0 8px rgba(255, 216, 92, 0.15);
}

.sb-badge-silver {
  background: rgba(200, 210, 230, 0.1);
  color: var(--px-light-2);
  border: 1px solid rgba(200, 210, 230, 0.25);
}

.sb-badge-bronze {
  background: rgba(244, 155, 69, 0.1);
  color: var(--px-orange);
  border: 1px solid rgba(244, 155, 69, 0.25);
}

.sb-rank-num {
  font-family: var(--px-font);
  font-size: 10px;
  color: var(--px-light-3);
}

.sb-score-cell {
  font-family: var(--px-font);
  color: var(--px-cyan) !important;
  font-size: 11px !important;
  letter-spacing: 1px;
}

/* =========================
   PAGINATION
   ========================= */

.page-link {
  background: rgba(12, 16, 32, 0.9) !important;
  border: 1px solid rgba(114, 226, 243, 0.3) !important;
  color: var(--px-cyan) !important;
  font-size: 10px !important;
}

.page-link:hover {
  background: rgba(114, 226, 243, 0.15) !important;
  border-color: var(--px-cyan) !important;
}

.page-item.active .page-link {
  background: rgba(114, 226, 243, 0.25) !important;
  border-color: var(--px-cyan) !important;
  color: var(--px-light) !important;
}

/* =========================
   SCROLLBAR (WebKit)
   ========================= */

::-webkit-scrollbar {
  width: 8px;
  height: 8px;
}

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

::-webkit-scrollbar-thumb {
  background: var(--px-bg-2);
  border: 1px solid rgba(114, 226, 243, 0.3);
}

::-webkit-scrollbar-thumb:hover {
  background: rgba(114, 226, 243, 0.3);
}

/* =========================
   MISC BOOTSTRAP OVERRIDES
   ========================= */

.bg-dark {
  background:
    repeating-linear-gradient(
      90deg,
      #141428 0, #141428 4px,
      #1c1c3a 4px, #1c1c3a 8px
    ),
    linear-gradient(#151a2d, #202743) !important;
}

.bg-light {
  background: rgba(20, 20, 40, 0.9) !important;
}

.border {
  border-color: rgba(114, 226, 243, 0.2) !important;
}

/* Code blocks */
pre, code {
  font-family: var(--px-font) !important;
  font-size: 10px !important;
  background: rgba(9, 9, 22, 0.8) !important;
  color: var(--px-cyan) !important;
  border: 1px solid rgba(114, 226, 243, 0.2);
  border-radius: 0 !important;
  padding: 2px 6px;
}

pre {
  padding: 16px !important;
}

/* Selection highlight */
::selection {
  background: rgba(114, 226, 243, 0.3);
  color: var(--px-light);
}

/* =========================
   RESPONSIVE
   ========================= */

@media (max-width: 768px) {
  .jumbotron h1 {
    font-size: 20px !important;
  }

  .navbar-brand {
    font-size: 12px !important;
  }

  .nav-link {
    font-size: 9px !important;
  }

  .challenge-name {
    font-size: 14px !important;
  }

  .challenge-value {
    font-size: 12px !important;
  }
}

/* =========================
   LANDING PAGE
   ========================= */

.landing-hero {
  padding: 80px 20px 100px;
  text-align: center;
  position: relative;
  overflow: hidden;
  background: linear-gradient(180deg, rgba(16,18,40,0.6) 0%, rgba(20,20,40,0.3) 100%);
}

.landing-hero::before {
  content: "";
  position: absolute;
  top: 20%;
  left: 50%;
  transform: translate(-50%, -30%);
  width: 600px;
  height: 600px;
  background: radial-gradient(circle, rgba(114,226,243,0.08) 0%, rgba(59,99,255,0.04) 40%, transparent 70%);
  pointer-events: none;
  z-index: 0;
}

.landing-hero > .container {
  position: relative;
  z-index: 1;
}

/* --- Edge accent lines (hero) --- */
.hero-edge-line {
  position: absolute;
  top: 10%;
  bottom: 10%;
  width: 1px;
  z-index: 0;
  pointer-events: none;
}

.hero-edge-left {
  left: 12px;
  background: linear-gradient(180deg, transparent, rgba(114,226,243,0.3) 30%, rgba(114,226,243,0.3) 70%, transparent);
  box-shadow: 0 0 8px rgba(114,226,243,0.15), 0 0 20px rgba(114,226,243,0.08);
}

.hero-edge-right {
  right: 12px;
  background: linear-gradient(180deg, transparent, rgba(255,216,92,0.25) 30%, rgba(255,216,92,0.25) 70%, transparent);
  box-shadow: 0 0 8px rgba(255,216,92,0.12), 0 0 20px rgba(255,216,92,0.06);
}

/* --- Edge accent lines on light (even) sections --- */
.landing-section:nth-child(even)::after {
  content: "";
  position: absolute;
  top: 0;
  bottom: 0;
  left: 12px;
  right: 12px;
  border-left: 1px solid rgba(114,226,243,0.25);
  border-right: 1px solid rgba(255,216,92,0.2);
  pointer-events: none;
  z-index: 0;
  box-shadow:
    inset 10px 0 20px -10px rgba(114,226,243,0.08),
    inset -10px 0 20px -10px rgba(255,216,92,0.06);
}

/* --- Event info labels --- */
.hero-info-label {
  position: absolute;
  top: 50%;
  display: flex;
  align-items: center;
  gap: 12px;
  font-family: var(--px-font);
  font-size: 7px;
  letter-spacing: 3px;
  text-transform: uppercase;
  white-space: nowrap;
  pointer-events: none;
  z-index: 0;
  user-select: none;
}

.hero-info-label span {
  font-family: var(--px-font);
}

.hero-info-dot {
  font-size: 5px;
  opacity: 0.5;
}

.hero-info-left {
  left: 28px;
  color: rgba(114,226,243,0.25);
  transform: translateY(-50%) rotate(-90deg);
  transform-origin: center center;
}

.hero-info-right {
  right: 28px;
  color: rgba(255,216,92,0.25);
  transform: translateY(-50%) rotate(90deg);
  transform-origin: center center;
}

/* --- Fixed scrolling side text (visible through light sections) --- */
.page-side-text {
  position: fixed;
  top: 50%;
  width: 100vh;
  overflow: hidden;
  font-family: var(--px-font);
  font-size: 14px;
  letter-spacing: 6px;
  text-transform: uppercase;
  color: rgba(114, 226, 243, 0.18);
  white-space: nowrap;
  pointer-events: none;
  z-index: 0;
  user-select: none;
}

.page-side-text span {
  font-family: var(--px-font);
}

.page-side-scroll {
  display: inline-flex;
  will-change: transform;
}

.page-side-scroll.scroll-left {
  animation: sideScrollLeft 25s linear infinite;
}

.page-side-scroll.scroll-right {
  animation: sideScrollRight 25s linear infinite;
}

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

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

.page-side-left {
  left: -70px;
  transform: translateY(-50%) rotate(-90deg);
  transform-origin: center center;
}

.page-side-right {
  right: -70px;
  transform: translateY(-50%) rotate(90deg);
  transform-origin: center center;
}

#particles-canvas {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  pointer-events: none;
  z-index: 0;
}

.landing-logo {
  margin-bottom: 50px;
}

.landing-logo-img {
  max-width: 320px;
  height: auto;
  filter: drop-shadow(0 0 30px rgba(114, 226, 243, 0.2));
}

.landing-heading {
  font-size: clamp(24px, 5vw, 48px) !important;
  color: var(--px-light) !important;
  text-shadow: 0 0 30px rgba(114, 226, 243, 0.4),
               0 0 60px rgba(114, 226, 243, 0.15) !important;
  text-transform: uppercase;
  letter-spacing: 4px;
  margin-bottom: 40px !important;
}

.landing-subtitle {
  font-size: 9px !important;
  color: var(--px-light-3) !important;
  text-transform: uppercase;
  letter-spacing: 3px;
  margin-bottom: 80px !important;
}

.countdown {
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 12px;
  margin-bottom: 80px;
}

.countdown-box {
  background: rgba(12, 16, 32, 0.9);
  border: 2px solid var(--px-cyan);
  border-radius: 10px;
  padding: 16px 20px;
  min-width: 80px;
  text-align: center;
  box-shadow: 0 0 12px rgba(114, 226, 243, 0.2),
              inset 0 0 8px rgba(114, 226, 243, 0.1);
}

.countdown-num {
  display: block;
  font-size: 28px !important;
  color: var(--px-yellow) !important;
  line-height: 1.2;
}

.countdown-label {
  display: block;
  font-size: 7px !important;
  color: var(--px-light-3) !important;
  text-transform: uppercase;
  letter-spacing: 2px;
  margin-top: 6px;
}

.countdown-sep {
  font-size: 28px;
  color: var(--px-cyan);
  line-height: 1;
}

.landing-buttons {
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 16px;
  flex-wrap: wrap;
}

.discord-btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-family: var(--px-font) !important;
  font-size: 12px !important;
  color: var(--px-light) !important;
  background: rgba(88, 101, 242, 0.15);
  border: 2px solid #5865F2;
  border-radius: 8px;
  padding: 14px 32px;
  text-transform: uppercase;
  letter-spacing: 2px;
  text-decoration: none !important;
  transition: all 0.2s ease-out;
  box-shadow: 0 0 12px rgba(88, 101, 242, 0.2);
}

.discord-btn:hover {
  color: var(--px-light) !important;
  transform: translateY(-2px);
  box-shadow: 0 0 24px rgba(88, 101, 242, 0.4);
  text-decoration: none !important;
}

.discord-btn i {
  font-size: 16px;
}

.cta-btn {
  display: inline-block;
  font-family: var(--px-font) !important;
  font-size: 12px !important;
  color: var(--px-light) !important;
  background: rgba(10, 20, 32, 0.35);
  border: 2px solid var(--px-yellow);
  border-radius: 8px;
  padding: 14px 32px;
  text-transform: uppercase;
  letter-spacing: 2px;
  text-decoration: none !important;
  transition: all 0.2s ease-out;
  box-shadow: 0 0 12px rgba(255, 216, 92, 0.3),
              inset 0 0 8px rgba(255, 216, 92, 0.1);
}

.cta-btn:hover {
  color: var(--px-light) !important;
  transform: translateY(-2px);
  box-shadow: 0 0 24px rgba(255, 216, 92, 0.5),
              inset 0 0 12px rgba(255, 216, 92, 0.2);
  text-decoration: none !important;
}

.conference-btn {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-family: var(--px-font) !important;
  font-size: 11px !important;
  color: var(--px-light) !important;
  background: rgba(114, 226, 243, 0.08);
  border: 2px solid rgba(114, 226, 243, 0.4);
  border-radius: 8px;
  padding: 14px 32px;
  text-transform: uppercase;
  letter-spacing: 2px;
  text-decoration: none !important;
  transition: all 0.2s ease-out;
  box-shadow: 0 0 12px rgba(114, 226, 243, 0.1);
}

.conference-btn:hover {
  color: var(--px-light) !important;
  transform: translateY(-2px);
  box-shadow: 0 0 24px rgba(114, 226, 243, 0.3);
  border-color: var(--px-cyan);
  text-decoration: none !important;
}

.conference-btn i {
  font-size: 12px;
}

/* =========================
   LANDING SECTIONS
   ========================= */

.landing-section {
  padding: 70px 20px;
  text-align: center;
  position: relative;
  border-top: 1px solid rgba(114, 226, 243, 0.08);
}

.landing-section::before {
  content: "";
  position: absolute;
  top: -1px;
  left: 50%;
  transform: translateX(-50%);
  width: 200px;
  height: 1px;
  background: linear-gradient(90deg, transparent, rgba(114,226,243,0.5), transparent);
  box-shadow: 0 0 12px rgba(114, 226, 243, 0.3);
}

/* Alternating section backgrounds */
/* Odd = dark, fully opaque → hides fixed scrolling side text */
.landing-section:nth-child(odd) {
  background: #0c0e1e;
}

/* Even = lighter, translucent → scrolling side text visible through */
.landing-section:nth-child(even) {
  background: rgba(22, 24, 50, 0.4);
}

.landing-section-sm {
  padding: 20px 20px;
  border-top: none;
  background: transparent !important;
}

.landing-section-sm::before {
  display: none;
}

.section-title {
  font-size: clamp(16px, 3vw, 28px) !important;
  color: var(--px-light) !important;
  text-shadow: 0 0 20px rgba(114, 226, 243, 0.3) !important;
  text-transform: uppercase;
  letter-spacing: 3px;
  margin-bottom: 8px !important;
}

.section-subtitle {
  font-size: 9px !important;
  color: var(--px-light-3) !important;
  letter-spacing: 2px;
  margin-bottom: 40px !important;
}

/* --- Category Grid --- */

.category-grid {
  display: flex;
  justify-content: center;
  flex-wrap: wrap;
  gap: 16px;
  max-width: 100%;
  margin: 0 auto;
  padding: 16px 12px 20px;
}

.category-card {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 10px;
  width: 130px;
  height: 110px;
  flex-shrink: 0;
  background: rgba(12, 16, 32, 0.7);
  border: 2px solid rgba(114, 226, 243, 0.25);
  border-radius: 10px;
  transition: all 0.2s ease;
}

.category-card i {
  font-size: 28px;
  line-height: 1;
  width: 32px;
  height: 32px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  color: var(--px-cyan);
  flex-shrink: 0;
  image-rendering: auto !important;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  position: relative;
  z-index: 10000;
  isolation: isolate;
  mix-blend-mode: normal !important;
  filter: none !important;
}

.category-card span {
  font-family: var(--px-font);
  font-size: 8px;
  color: var(--px-light-2);
  text-transform: uppercase;
  letter-spacing: 2px;
}

.category-card:hover {
  border-color: var(--px-cyan);
  transform: translateY(-3px);
  box-shadow: 0 0 20px rgba(114, 226, 243, 0.2);
}

/* --- Prizes Grid --- */

.prizes-grid {
  display: flex;
  justify-content: center;
  align-items: stretch;
  gap: 20px;
  max-width: 900px;
  margin: 0 auto;
  flex-wrap: wrap;
}

.prize-card {
  flex: 1;
  min-width: 200px;
  max-width: 280px;
  background: rgba(12, 16, 32, 0.7);
  border: 2px solid rgba(114, 226, 243, 0.2);
  border-radius: 10px;
  padding: 30px 24px;
  text-align: left;
}

.prize-card.prize-first {
  border-color: var(--px-yellow);
  box-shadow: 0 0 20px rgba(255, 216, 92, 0.15);
}

.prize-place {
  font-family: var(--px-font);
  font-size: 12px;
  text-transform: uppercase;
  letter-spacing: 2px;
  margin-bottom: 16px;
}

.prize-place.gold {
  color: var(--px-yellow);
}

.prize-place.silver {
  color: var(--px-light-2);
}

.prize-place.bronze {
  color: var(--px-orange);
}

.prize-details {
  font-family: var(--px-font);
  font-size: 9px;
  color: var(--px-light-3);
  line-height: 2.4;
}

/* --- Sponsors Grid --- */

.sponsors-grid {
  display: flex;
  justify-content: center;
  flex-wrap: wrap;
  gap: 16px;
  max-width: 900px;
  margin: 0 auto;
}

.sponsor-card {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 160px;
  height: 80px;
  background: rgba(12, 16, 32, 0.5);
  border: 2px dashed rgba(114, 226, 243, 0.15);
  border-radius: 10px;
  font-family: var(--px-font);
  font-size: 7px;
  color: var(--px-light-3);
  text-transform: uppercase;
  letter-spacing: 1px;
  opacity: 0.6;
}

/* --- Rules Link --- */

.landing-rules-link {
  font-size: 10px !important;
  color: var(--px-light-3) !important;
}

.landing-rules-link a {
  color: var(--px-yellow) !important;
  text-decoration: none;
  border-bottom: 1px solid rgba(255, 216, 92, 0.3);
}

.landing-rules-link a:hover {
  border-bottom-color: var(--px-yellow);
}

/* =========================
   PRINT FLAG
   ========================= */

.rules-sections {
  position: absolute;
  left: -9999px;
  font-size: 0;
  color: transparent;
}

@media print {
  .rules-sections {
    position: static;
    font-size: 6px;
    color: #1a1e30;
    margin-top: 8px;
    letter-spacing: 1px;
  }
}

/* =========================
   SNAKE GAME
   ========================= */

.snake-wrapper {
  margin-top: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
}

.snake-title {
  font-size: 9px !important;
  color: var(--px-light-3) !important;
  text-transform: uppercase;
  letter-spacing: 3px;
  margin-bottom: 12px !important;
}

.snake-hud {
  display: flex;
  justify-content: space-between;
  width: 600px;
  max-width: 90vw;
  margin-bottom: 8px;
  font-size: 8px !important;
  color: var(--px-cyan) !important;
  text-transform: uppercase;
  letter-spacing: 2px;
}

#snake-canvas {
  display: block;
  max-width: 90vw;
  border: 2px solid rgba(114, 226, 243, 0.3);
  border-radius: 6px;
  box-shadow: 0 0 20px rgba(114, 226, 243, 0.1);
}

.snake-hint {
  font-size: 8px !important;
  color: var(--px-light-3) !important;
  text-transform: uppercase;
  letter-spacing: 2px;
  margin-top: 10px !important;
}

.snake-mobile-controls {
  display: none;
  flex-direction: column;
  align-items: center;
  gap: 4px;
  margin-top: 12px;
}

.snake-btn-row {
  display: flex;
  gap: 4px;
}

.snake-btn {
  width: 48px;
  height: 48px;
  background: rgba(12, 16, 32, 0.8);
  border: 1px solid rgba(114, 226, 243, 0.3);
  border-radius: 6px;
  color: var(--px-cyan);
  font-size: 16px;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  -webkit-tap-highlight-color: transparent;
  user-select: none;
}

.snake-btn:active {
  background: rgba(114, 226, 243, 0.15);
}

/* =========================
   RULES PAGE
   ========================= */

.rules-page {
  max-width: 700px;
  margin: 0 auto;
  padding: 40px 0;
}

.rules-title {
  font-size: 20px !important;
  color: var(--px-light) !important;
  text-transform: uppercase;
  letter-spacing: 3px;
  margin-bottom: 30px !important;
  text-align: center;
}

.rules-section {
  margin-bottom: 24px;
  padding: 20px;
  background: rgba(12, 16, 32, 0.6);
  border: 1px solid rgba(114, 226, 243, 0.2);
  border-radius: 8px;
}

.rules-section h3 {
  font-size: 12px !important;
  color: var(--px-cyan) !important;
  text-transform: uppercase;
  letter-spacing: 2px;
  margin-bottom: 12px !important;
}

.rules-section ul {
  list-style: none;
  padding: 0;
  margin: 0;
}

.rules-section ul li {
  font-size: 9px !important;
  color: var(--px-light-2) !important;
  padding: 4px 0;
  line-height: 2 !important;
}

.rules-section ul li::before {
  content: "▸ ";
  color: var(--px-yellow);
}

/* =========================
   RESPONSIVE
   ========================= */

@media (max-width: 1675px) {
  .page-side-text,
  .hero-info-label {
    display: none !important;
  }
}

@media (max-width: 768px) {
  .hero-edge-line {
    display: none;
  }

  .landing-hero {
    padding: 50px 15px 40px;
  }

  .landing-logo-img {
    max-width: 200px;
  }

  .countdown {
    gap: 6px;
  }

  .countdown-box {
    padding: 10px 12px;
    min-width: 56px;
    border-radius: 8px;
  }

  .countdown-num {
    font-size: 20px !important;
  }

  .countdown-sep {
    font-size: 20px;
  }

  .landing-buttons {
    flex-direction: column;
    gap: 12px;
  }

  .discord-btn, .cta-btn {
    font-size: 10px !important;
    padding: 12px 28px;
    width: 100%;
    max-width: 280px;
    text-align: center;
  }

  .landing-section {
    padding: 40px 15px;
  }

  .category-grid {
    flex-wrap: wrap;
    overflow-x: visible;
    gap: 12px;
    padding: 12px 8px 16px;
  }

  .category-card {
    width: calc((100% - 24px) / 3);
    max-width: 120px;
    min-width: 90px;
    height: 90px;
  }

  .category-card span {
    font-size: 7px;
    letter-spacing: 1px;
  }

  .prizes-grid {
    flex-direction: column;
    align-items: center;
  }

  .prize-card {
    max-width: 100%;
  }

  .rules-section {
    padding: 16px;
  }

  .snake-mobile-controls {
    display: flex;
  }

  .sb-podium {
    flex-direction: column;
    align-items: center;
    gap: 12px;
  }

  .sb-podium-card {
    max-width: 280px;
    width: 100%;
    border-radius: 10px;
    border-bottom: 2px solid rgba(114, 226, 243, 0.15);
    padding-bottom: 16px;
  }

  .sb-podium-card.sb-gold {
    order: -1;
  }

  .sb-podium-bar {
    display: none;
  }

  .sb-podium-icon {
    font-size: 22px;
  }
}

@media (max-width: 480px) {
  .category-card {
    width: calc((100% - 12px) / 2);
    max-width: none;
    min-width: 0;
  }
}

/* =========================
   RESPONSIVE — TABLET & MOBILE (≤768px)
   Subpage-wide fixes: tables, forms, modals, jumbotron, sponsors,
   buttons, navbar collapse. Keeps every page usable on small screens.
   ========================= */
@media (max-width: 768px) {
  /* Jumbotron — tighter on small screens so content gets more room */
  .jumbotron {
    padding: 14px 12px !important;
  }

  /* Tables auto-scroll horizontally instead of overflowing the viewport */
  .table-responsive,
  main .container > .row > [class*="col-"] > .table,
  .sb-table {
    display: block;
    width: 100%;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
  }
  .sb-table {
    font-size: 9px;
  }
  .sb-table thead td,
  .sb-table td,
  .sb-table th {
    padding: 6px 8px !important;
    white-space: nowrap;
  }

  /* Forms — bigger tap targets, full-width controls */
  .form-control {
    font-size: 11px !important;
    padding: 10px !important;
  }
  .form-group {
    margin-bottom: 14px;
  }

  /* Buttons full-width on phones for easier tapping */
  .btn-block,
  .btn.btn-md,
  .btn-primary,
  .btn-secondary {
    width: 100%;
  }
  .float-left,
  .float-right {
    float: none !important;
    display: block;
    text-align: center;
    margin-bottom: 10px;
  }

  /* Modal — reduce edge gutters on phones */
  .modal-dialog {
    margin: 8px;
    max-width: calc(100% - 16px);
  }
  .modal-content,
  .modal-body {
    padding: 14px !important;
  }

  /* Navbar dropdown items easier to tap */
  .navbar .nav-link {
    padding: 10px 14px !important;
  }

  /* Sponsors footer carousel — wrap to multiple rows on small screens */
  .sponsors-track2 {
    display: flex !important;
    flex-wrap: wrap !important;
    justify-content: center !important;
    align-items: center !important;
    white-space: normal !important;
    gap: 24px 28px !important;
    max-width: 100%;
  }
  .sponsors-img,
  .sponsors-img2 {
    height: 55px !important;
  }
  .sponsors-image {
    height: 70px !important;
  }
  .footer .container {
    padding: 0 8px;
  }
  /* Sponsors page carousel — same */
  .sponsors-track img {
    height: 60px !important;
  }

  /* Section titles balance with reduced padding */
  .section-title {
    font-size: 18px !important;
  }
  .section-subtitle {
    font-size: 9px !important;
  }

  /* Rain corner — slot grid spacing tighter on phones */
  .rc-slot {
    min-height: auto;
    padding: 0.6rem !important;
  }
  .rc-section-head {
    flex-direction: column;
    align-items: flex-start;
    gap: 0.5rem;
  }

  /* Challenge board tiles render via JS — ensure no horizontal scroll */
  #challenges-board .row {
    margin-left: 0;
    margin-right: 0;
  }

  /* Long names / emails wrap inside auth pages */
  main .container {
    overflow-wrap: anywhere;
    word-break: break-word;
  }
}

/* Very small phones (≤480px) — extra polish */
@media (max-width: 480px) {
  .jumbotron h1 {
    font-size: 16px !important;
  }
  .navbar-brand {
    font-size: 10px !important;
    max-width: 70vw;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
  }
  .sponsors-img,
  .sponsors-img2 {
    height: 42px !important;
  }
  .sponsors-image {
    height: 52px !important;
  }
  .sponsors-track2 {
    gap: 16px 18px !important;
  }
}
