/* PIHOLEKILLER — Gauntlet + Results Dashboard styles
   Complements style.css (landing page). Same palette, same fonts. */

/* ═══ CONSENT MODAL ═══════════════════════════════════════ */
.consent-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.92);
  z-index: 500;
  display: flex;
  align-items: flex-start;
  justify-content: center;
  padding: 24px;
  overflow-y: auto;
  -webkit-overflow-scrolling: touch;
}

.consent-box {
  max-width: 680px;
  width: 100%;
  border: 2px solid var(--blood);
  background: var(--bg);
  padding: 40px 36px;
  position: relative;
  margin: auto;
}

.consent-box::before, .consent-box::after {
  content: "";
  position: absolute;
  width: 24px;
  height: 24px;
  border: 3px solid var(--warn);
}
.consent-box::before { top: -3px; left: -3px; border-right: none; border-bottom: none; }
.consent-box::after  { bottom: -3px; right: -3px; border-left: none; border-top: none; }

.consent-title {
  font-family: 'Press Start 2P', monospace;
  font-size: 20px;
  color: var(--warn);
  letter-spacing: 2px;
  margin-bottom: 24px;
  text-shadow: 0 0 10px rgba(255, 255, 0, 0.5);
}

.consent-icon { margin-right: 10px; }

.consent-body {
  font-family: 'VT323', monospace;
  font-size: 20px;
  color: var(--text);
  line-height: 1.4;
}

.consent-body p { margin-bottom: 14px; }
.consent-body strong { color: var(--warn); }
.consent-body em { color: var(--hot); font-style: normal; text-decoration: underline; }

.consent-body ul {
  list-style: none;
  padding-left: 0;
  margin: 14px 0;
}

.consent-body ul li {
  padding: 5px 0 5px 20px;
  color: var(--blood);
  position: relative;
}

.consent-body ul li::before {
  content: ">";
  position: absolute;
  left: 0;
  color: var(--hot);
  font-weight: bold;
}

.consent-note {
  font-size: 16px;
  color: var(--neon-dim);
  font-style: italic;
  margin-top: 16px;
}

.consent-checks {
  margin: 24px 0 20px;
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.consent-check {
  font-family: 'VT323', monospace;
  font-size: 20px;
  color: var(--electric);
  cursor: pointer;
  display: flex;
  align-items: center;
  gap: 10px;
}

.consent-check input[type="checkbox"] {
  appearance: none;
  -webkit-appearance: none;
  width: 20px;
  height: 20px;
  border: 2px solid var(--neon);
  background: var(--bg);
  cursor: pointer;
  flex-shrink: 0;
}

.consent-check input[type="checkbox"]:checked {
  background: var(--neon);
  box-shadow: inset 0 0 4px rgba(0, 0, 0, 0.6);
}

.consent-accept {
  width: 100%;
  margin-top: 8px;
  margin-bottom: 12px;
}

.consent-accept:disabled {
  opacity: 0.3;
  cursor: not-allowed;
  box-shadow: 6px 6px 0 #333;
}

.consent-cancel {
  background: none;
  border: none;
  color: var(--neon-dim);
  font-family: 'VT323', monospace;
  font-size: 18px;
  cursor: pointer;
  padding: 8px 0;
  display: block;
  width: 100%;
  text-align: center;
}

.consent-cancel:hover { color: var(--electric); }

/* ═══ GAUNTLET VIEW ═══════════════════════════════════════ */
.gauntlet-wrapper {
  max-width: 1100px;
  margin: 0 auto;
  padding: 24px 20px 80px;
  position: relative;
  z-index: 2;
}

.gauntlet-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 16px 0 20px;
  border-bottom: 2px dashed var(--neon-dim);
  margin-bottom: 24px;
}

a.gauntlet-brand {
  font-family: 'Press Start 2P', monospace;
  font-size: 22px;
  color: var(--neon);
  text-shadow: 0 0 8px var(--neon), 2px 2px 0 var(--hot);
  text-decoration: none;
  cursor: pointer;
}

a.gauntlet-brand:hover {
  text-shadow: 0 0 16px var(--neon), 3px 3px 0 var(--hot);
}

.gauntlet-brand .killer {
  color: var(--blood);
  text-shadow: 0 0 8px var(--blood), 2px 2px 0 var(--warn);
}

.gauntlet-scorebar {
  font-family: 'VT323', monospace;
  font-size: 24px;
}

.sb-blocked { color: var(--neon); }
.sb-blocked span { font-family: 'Press Start 2P', monospace; font-size: 18px; }
.sb-leaked { color: var(--blood); }
.sb-leaked span { font-family: 'Press Start 2P', monospace; font-size: 18px; }
.sb-total { color: var(--neon-dim); }
.sb-total span { font-family: 'Press Start 2P', monospace; font-size: 18px; }
.sb-sep { color: var(--neon-dim); margin: 0 8px; }

.level-header {
  font-family: 'Press Start 2P', monospace;
  font-size: 16px;
  padding: 14px 0;
  margin-bottom: 8px;
  border-bottom: 2px solid var(--neon);
  letter-spacing: 1px;
}

.level-progress {
  height: 6px;
  background: var(--bg-alt);
  border: 1px solid var(--neon-dim);
  margin-bottom: 24px;
  overflow: hidden;
}

.level-progress-fill {
  height: 100%;
  background: var(--neon);
  width: 0%;
  transition: width 0.3s ease-out;
  box-shadow: 0 0 8px var(--neon);
}

/* Test card grid */
.test-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
  gap: 8px;
}

.test-card {
  padding: 12px 14px;
  border: 1px solid var(--neon-dim);
  background: var(--bg-alt);
  transition: all 0.25s ease-out;
  min-height: 80px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
}

.test-card.pending {
  border-color: var(--neon-dim);
  opacity: 0.5;
}

.test-card.blocked {
  border-color: var(--neon);
  background: rgba(0, 255, 65, 0.04);
  opacity: 1;
}

.test-card.leaked {
  border-color: var(--blood);
  background: rgba(255, 0, 51, 0.08);
  opacity: 1;
}

.tc-status {
  font-family: 'Press Start 2P', monospace;
  font-size: 10px;
  letter-spacing: 2px;
  margin-bottom: 6px;
}

.test-card.pending .tc-status { color: var(--neon-dim); }
.test-card.blocked .tc-status { color: var(--neon); text-shadow: 0 0 6px var(--neon); }
.test-card.leaked .tc-status  { color: var(--blood); text-shadow: 0 0 6px var(--blood); }

.tc-name {
  font-family: 'VT323', monospace;
  font-size: 20px;
  color: var(--electric);
}

.test-card.leaked .tc-name {
  color: var(--blood);
  text-decoration: line-through;
  text-decoration-color: rgba(255, 0, 51, 0.4);
}

.tc-cat {
  font-family: 'VT323', monospace;
  font-size: 14px;
  color: var(--neon-dim);
  margin-top: 2px;
}

.tc-time {
  font-family: 'VT323', monospace;
  font-size: 14px;
  color: var(--neon-dim);
  text-align: right;
  margin-top: 4px;
}

.tc-leak-badge {
  font-family: 'Press Start 2P', monospace;
  font-size: 8px;
  color: var(--bg);
  background: var(--blood);
  padding: 4px 8px;
  margin-top: 6px;
  letter-spacing: 1px;
  text-align: center;
  animation: leak-flash 1s ease-in-out 3;
}

@keyframes leak-flash {
  0%, 100% { opacity: 1; }
  50% { opacity: 0.4; }
}

/* Level summary (shown after each level completes) */
.level-summary-wrap {
  grid-column: 1 / -1;
  padding: 28px 0;
}

.level-summary {
  border: 2px dashed var(--neon);
  padding: 24px 28px;
  margin-bottom: 20px;
}

.ls-score {
  font-family: 'Press Start 2P', monospace;
  font-size: 24px;
  color: var(--neon);
  text-shadow: 0 0 10px var(--neon);
  margin-bottom: 16px;
}

.ls-bar {
  height: 10px;
  background: var(--bg-alt);
  border: 1px solid var(--neon-dim);
  margin-bottom: 20px;
}

.ls-bar-fill {
  height: 100%;
  background: var(--neon);
  box-shadow: 0 0 8px var(--neon);
  transition: width 0.5s ease-out;
}

.ls-leaked-title {
  font-family: 'Press Start 2P', monospace;
  font-size: 12px;
  color: var(--blood);
  letter-spacing: 2px;
  margin-bottom: 10px;
}

.ls-leaked-list {
  list-style: none;
  padding: 0;
}

.ls-leaked-list li {
  padding: 6px 0;
  border-bottom: 1px dashed var(--neon-faint);
  font-family: 'VT323', monospace;
  font-size: 18px;
}

.ls-leaked-name { color: var(--blood); margin-right: 12px; }
.ls-leaked-cat { color: var(--neon-dim); font-size: 15px; }

.ls-perfect {
  font-family: 'Press Start 2P', monospace;
  font-size: 14px;
  color: var(--neon);
  letter-spacing: 2px;
  text-shadow: 0 0 10px var(--neon);
  padding: 12px 0;
}

.level-next-btn {
  width: 100%;
  margin-top: 16px;
}

.level-warning {
  background: rgba(255, 0, 51, 0.08);
  border: 2px solid var(--blood);
  padding: 14px 18px;
  color: var(--blood);
  font-family: 'VT323', monospace;
  font-size: 18px;
  margin-top: 16px;
  line-height: 1.4;
}

.skip-btn {
  background: none;
  border: none;
  color: var(--neon-dim);
  font-family: 'VT323', monospace;
  font-size: 20px;
  cursor: pointer;
  padding: 12px 0;
  display: block;
  width: 100%;
  text-align: center;
  margin-top: 8px;
}

.skip-btn:hover { color: var(--electric); }

/* ═══ RESULTS DASHBOARD ══════════════════════════════════ */
.results-wrapper {
  max-width: 900px;
  margin: 0 auto;
  padding: 40px 24px 80px;
  position: relative;
  z-index: 2;
}

.results-hero {
  text-align: center;
  padding: 60px 32px;
  border: 2px dashed var(--neon);
  margin-bottom: 40px;
  position: relative;
  background: radial-gradient(ellipse at center, rgba(0, 255, 65, 0.05), transparent 70%);
}

.rh-eyebrow {
  font-family: 'Press Start 2P', monospace;
  font-size: 12px;
  color: var(--electric);
  letter-spacing: 4px;
  margin-bottom: 20px;
}

.rh-grade {
  font-family: 'Press Start 2P', monospace;
  font-size: 120px;
  line-height: 1;
  margin-bottom: 8px;
  animation: grade-pulse 3s ease-in-out infinite;
}

@keyframes grade-pulse {
  0%, 100% { opacity: 1; }
  50% { opacity: 0.7; }
}

.rh-grade-label {
  font-family: 'Press Start 2P', monospace;
  font-size: 20px;
  letter-spacing: 6px;
  margin-bottom: 24px;
}

.rh-score {
  font-family: 'VT323', monospace;
  font-size: 64px;
  color: var(--text);
  letter-spacing: 2px;
}

.rh-sub {
  font-family: 'VT323', monospace;
  font-size: 22px;
  color: var(--neon-dim);
  margin-top: 8px;
}

/* Results sections */
.results-section {
  margin-bottom: 36px;
  padding: 24px 28px;
  border-left: 4px solid var(--neon);
  background: var(--bg-alt);
}

.rs-title {
  font-family: 'Major Mono Display', monospace;
  color: var(--electric);
  font-size: 28px;
  margin-bottom: 20px;
  text-transform: lowercase;
  font-weight: 400;
}

/* Pillar breakdown bars */
.pillar-breakdown {
  display: flex;
  flex-direction: column;
  gap: 14px;
}

.bd-row {
  display: grid;
  grid-template-columns: 180px 80px 1fr;
  gap: 12px;
  align-items: center;
}

.bd-label {
  font-family: 'VT323', monospace;
  font-size: 20px;
  color: var(--electric);
}

.bd-score {
  font-family: 'Press Start 2P', monospace;
  font-size: 12px;
  color: var(--warn);
  text-align: right;
}

.bd-bar {
  height: 12px;
  background: rgba(255, 0, 51, 0.15);
  border: 1px solid var(--neon-dim);
  overflow: hidden;
}

.bd-bar-fill {
  height: 100%;
  transition: width 0.5s ease-out;
  box-shadow: 0 0 6px currentColor;
}

/* Leaked list */
.leaked-list {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.leaked-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 8px 0;
  border-bottom: 1px dashed var(--neon-faint);
  font-family: 'VT323', monospace;
}

.leaked-name {
  font-size: 22px;
  color: var(--blood);
}

.leaked-cat {
  font-size: 16px;
}

/* Collapsed leaked list */
.leaked-collapsed {
  max-height: 0;
  overflow: hidden;
  transition: max-height 0.3s ease-out;
  padding: 0;
}

.leaked-list:not(.leaked-collapsed) {
  max-height: 2000px;
  transition: max-height 0.4s ease-in;
}

.leaked-toggle {
  cursor: pointer;
  user-select: none;
}

.leaked-toggle:hover { color: var(--hot); }

.leaked-arrow {
  font-size: 14px;
  margin-left: 8px;
  transition: transform 0.2s;
}

.leaked-hidden {
  display: none;
}

.leaked-show-more {
  background: none;
  border: 1px dashed var(--blood);
  color: var(--blood);
  font-family: 'VT323', monospace;
  font-size: 18px;
  padding: 10px 16px;
  cursor: pointer;
  width: 100%;
  margin-top: 8px;
  transition: all 0.15s;
}

.leaked-show-more:hover {
  background: rgba(255, 0, 51, 0.1);
  color: var(--warn);
}

.leaked-section {
  padding-bottom: 16px;
}

.leaked-none {
  font-family: 'Press Start 2P', monospace;
  font-size: 14px;
  color: var(--neon);
  text-shadow: 0 0 10px var(--neon);
  padding: 20px 0;
  letter-spacing: 2px;
  text-align: center;
}

/* Share buttons */
.results-share {
  display: flex;
  flex-wrap: wrap;
  gap: 14px;
  align-items: center;
  border-left-color: var(--hot);
}

.results-share .rs-title {
  width: 100%;
}

.share-btn {
  background: var(--electric);
  color: var(--bg);
  padding: 16px 24px;
  font-family: 'Press Start 2P', monospace;
  font-size: 12px;
  text-decoration: none;
  letter-spacing: 1px;
  box-shadow: 4px 4px 0 var(--hot);
  transition: all 0.15s;
  cursor: pointer;
  border: none;
}

.share-btn:hover {
  transform: translate(-2px, -2px);
  box-shadow: 6px 6px 0 var(--hot), 0 0 20px rgba(0, 255, 255, 0.4);
}

.share-copy { background: var(--hot); color: var(--bg); box-shadow: 4px 4px 0 var(--electric); }
.share-copy:hover { box-shadow: 6px 6px 0 var(--electric), 0 0 20px rgba(255, 0, 255, 0.4); }

/* Compact results action bar — three matched buttons in one clean row */
.results-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 14px;
  margin-bottom: 36px;
  padding: 0 0 24px;
  border-bottom: 2px dashed var(--neon-dim);
  align-items: stretch;
}

.results-actions > * {
  flex: 1 1 0;
  min-width: 170px;
  margin: 0 !important;
  padding: 18px 20px !important;
  font-family: 'Press Start 2P', monospace !important;
  font-size: 11px !important;
  letter-spacing: 1.5px !important;
  text-align: center !important;
  text-decoration: none !important;
  border: none !important;
  cursor: pointer !important;
  transition: transform 0.15s, box-shadow 0.15s !important;
  display: flex !important;
  align-items: center;
  justify-content: center;
  line-height: 1.3;
  box-sizing: border-box;
}

/* Color variants — each button keeps its distinctive palette */
.results-actions .share-btn {
  background: var(--electric) !important;
  color: var(--bg) !important;
  box-shadow: 5px 5px 0 var(--hot) !important;
}

.results-actions .share-copy {
  background: var(--hot) !important;
  color: var(--bg) !important;
  box-shadow: 5px 5px 0 var(--electric) !important;
}

.results-actions .results-rerun {
  background: var(--neon) !important;
  color: var(--bg) !important;
  box-shadow: 5px 5px 0 var(--hot) !important;
}

/* Unified hover animation (everyone lifts the same amount) */
.results-actions > *:hover {
  transform: translate(-2px, -2px);
}

.results-actions .share-btn:not(.share-copy):hover {
  box-shadow: 7px 7px 0 var(--hot), 0 0 18px rgba(0, 255, 255, 0.45) !important;
}

.results-actions .share-copy:hover {
  box-shadow: 7px 7px 0 var(--electric), 0 0 18px rgba(255, 0, 255, 0.45) !important;
}

.results-actions .results-rerun:hover {
  box-shadow: 7px 7px 0 var(--hot), 0 0 18px rgba(0, 255, 65, 0.45) !important;
}

/* HOW TO SCORE HIGHER — affiliate section */
.score-higher {
  border-left-color: var(--hot) !important;
  background: linear-gradient(135deg, rgba(255, 0, 255, 0.04), rgba(0, 255, 255, 0.03)) !important;
}

.score-higher-intro {
  font-family: 'VT323', monospace;
  font-size: 22px;
  color: var(--electric);
  margin-bottom: 24px;
  line-height: 1.4;
}

.affiliate-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 12px;
  margin-bottom: 20px;
}

.aff-card {
  border: 1px solid var(--neon-dim);
  padding: 18px 20px;
  background: var(--bg);
  display: flex;
  flex-direction: column;
  gap: 8px;
  transition: border-color 0.15s, transform 0.15s;
}

.aff-card:hover {
  border-color: var(--hot);
  transform: translate(-2px, -2px);
  box-shadow: 4px 4px 0 var(--neon-dim);
}

.aff-card.aff-featured {
  border-color: var(--hot);
  background: rgba(255, 0, 255, 0.04);
}

.aff-badge {
  font-family: 'Press Start 2P', monospace;
  font-size: 9px;
  color: var(--warn);
  letter-spacing: 2px;
}

.aff-name {
  font-family: 'Press Start 2P', monospace;
  font-size: 13px;
  color: var(--neon);
  text-shadow: 0 0 6px rgba(0, 255, 65, 0.4);
}

.aff-desc {
  font-family: 'VT323', monospace;
  font-size: 18px;
  color: var(--text);
  line-height: 1.35;
}

.aff-fixes {
  font-family: 'VT323', monospace;
  font-size: 15px;
  color: var(--electric);
  font-style: italic;
  padding-top: 4px;
  border-top: 1px dashed var(--neon-faint);
}

.aff-btn {
  display: block;
  background: var(--neon-dim);
  color: var(--bg);
  padding: 10px 14px;
  font-family: 'Press Start 2P', monospace;
  font-size: 10px;
  text-decoration: none;
  text-align: center;
  letter-spacing: 1px;
  margin-top: auto;
  transition: all 0.15s;
}

.aff-btn:hover {
  background: var(--neon);
  box-shadow: 0 0 12px rgba(0, 255, 65, 0.5);
}

.aff-btn-hot {
  background: var(--hot);
  box-shadow: 3px 3px 0 var(--electric);
}

.aff-btn-hot:hover {
  background: #ff44ff;
  box-shadow: 4px 4px 0 var(--electric), 0 0 16px rgba(255, 0, 255, 0.5);
}

.aff-disclosure {
  font-family: 'VT323', monospace;
  font-size: 15px;
  color: var(--neon-dim);
  font-style: italic;
  text-align: right;
  margin-top: 12px;
}

/* Submit form */
.results-submit {
  border-left-color: var(--warn);
}

.submit-form {
  display: flex;
  flex-direction: column;
  gap: 12px;
  max-width: 500px;
}

/* ═══ RESPONSIVE ═════════════════════════════════════════ */
@media (max-width: 700px) {
  .gauntlet-header {
    flex-direction: column;
    gap: 12px;
    text-align: center;
  }
  .test-grid {
    grid-template-columns: 1fr 1fr;
  }
  .bd-row {
    grid-template-columns: 1fr;
    gap: 4px;
  }
  .bd-bar { margin-top: 4px; }
  .results-share { flex-direction: column; }
  .share-btn { width: 100%; text-align: center; }
  .consent-box { padding: 28px 20px; }
  .rh-grade { font-size: 80px; }
  .rh-score { font-size: 48px; }
}

@media (max-width: 480px) {
  .test-grid {
    grid-template-columns: 1fr;
  }
}
