/* =====================================================
   TROLLWIFAURA — styles.css
   ===================================================== */

:root {
  --green: #00ff41;
  --neon-green: #39ff14;
  --red: #ff2020;
  --pink: #ff69b4;
  --dark: #050a05;
  --darker: #020602;
  --glow-green: 0 0 20px #00ff41, 0 0 40px #00ff41, 0 0 80px #00ff4155;
  --glow-red: 0 0 20px #ff2020, 0 0 40px #ff2020;
  --glow-pink: 0 0 15px #ff69b4, 0 0 30px #ff69b488;
}

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

body {
  background: var(--darker);
  color: var(--green);
  font-family: 'Nunito', sans-serif;
  overflow-x: hidden;
  cursor: crosshair;
}

/* SCANLINE OVERLAY */
body::before {
  content: '';
  position: fixed;
  inset: 0;
  background: repeating-linear-gradient(
    0deg,
    transparent,
    transparent 2px,
    rgba(0,0,0,0.15) 2px,
    rgba(0,0,0,0.15) 4px
  );
  pointer-events: none;
  z-index: 9999;
}

/* ===== NAVBAR ===== */
nav {
  position: fixed;
  top: 0; left: 0; right: 0;
  z-index: 100;
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 14px 40px;
  background: rgba(2,6,2,0.85);
  backdrop-filter: blur(10px);
  border-bottom: 1px solid #00ff4133;
}

.nav-logo {
  font-family: 'Bangers', cursive;
  font-size: 2rem;
  letter-spacing: 3px;
  color: var(--neon-green);
  text-shadow: var(--glow-green);
  animation: flicker 4s infinite;
}

.nav-links {
  display: flex;
  gap: 30px;
  list-style: none;
}

.nav-links a {
  font-family: 'Boogaloo', cursive;
  font-size: 1.1rem;
  color: var(--green);
  text-decoration: none;
  letter-spacing: 1px;
  transition: all 0.2s;
}

.nav-links a:hover {
  color: #fff;
  text-shadow: var(--glow-green);
}

.nav-x {
  background: var(--dark);
  border: 1px solid var(--green);
  color: var(--green);
  padding: 8px 20px;
  font-family: 'Boogaloo', cursive;
  font-size: 1rem;
  cursor: pointer;
  text-decoration: none;
  transition: all 0.2s;
  clip-path: polygon(8px 0, 100% 0, calc(100% - 8px) 100%, 0 100%);
}

.nav-x:hover {
  background: var(--green);
  color: #000;
  box-shadow: var(--glow-green);
}

/* ===== HERO ===== */
.hero {
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 100px 20px 40px;
  text-align: center;
  position: relative;
  overflow: hidden;
}

.hero-bg {
  position: absolute;
  inset: 0;
  background:
    radial-gradient(ellipse 60% 50% at 50% 50%, rgba(0,255,65,0.07) 0%, transparent 70%),
    radial-gradient(ellipse 30% 30% at 20% 80%, rgba(255,105,180,0.05) 0%, transparent 60%);
}

/* Grid lines */
.hero-bg::after {
  content: '';
  position: absolute;
  inset: 0;
  background-image:
    linear-gradient(rgba(0,255,65,0.04) 1px, transparent 1px),
    linear-gradient(90deg, rgba(0,255,65,0.04) 1px, transparent 1px);
  background-size: 60px 60px;
  animation: gridMove 20s linear infinite;
}

@keyframes gridMove {
  0% { transform: translateY(0); }
  100% { transform: translateY(60px); }
}

.troll-img {
  width: 220px;
  height: 220px;
  object-fit: cover;
  border-radius: 50%;
  border: 3px solid var(--neon-green);
  box-shadow: var(--glow-green), 0 0 60px rgba(0,255,65,0.3);
  animation: float 3s ease-in-out infinite, pulse-border 2s ease-in-out infinite;
  position: relative;
  z-index: 2;
  margin-bottom: 10px;
}

@keyframes float {
  0%, 100% { transform: translateY(0) rotate(-2deg); }
  50% { transform: translateY(-18px) rotate(2deg); }
}

@keyframes pulse-border {
  0%, 100% { box-shadow: var(--glow-green), 0 0 60px rgba(0,255,65,0.3); }
  50% { box-shadow: 0 0 30px #00ff41, 0 0 60px #00ff41, 0 0 100px rgba(0,255,65,0.5); }
}

.hero-title {
  font-family: 'Bangers', cursive;
  font-size: clamp(4rem, 12vw, 9rem);
  letter-spacing: 6px;
  line-height: 0.9;
  color: #fff;
  text-shadow:
    0 0 30px var(--neon-green),
    0 0 60px var(--neon-green),
    4px 4px 0 #000;
  position: relative;
  z-index: 2;
  animation: titleGlitch 6s infinite;
}

@keyframes titleGlitch {
  0%, 90%, 100% { transform: translate(0); filter: none; }
  92% { transform: translate(-3px, 1px); filter: hue-rotate(90deg); }
  94% { transform: translate(3px, -1px); filter: hue-rotate(-90deg); }
  96% { transform: translate(0); filter: none; }
  98% { transform: translate(-2px, 2px); }
}

.hero-sub {
  font-family: 'Boogaloo', cursive;
  font-size: clamp(1.2rem, 3vw, 1.8rem);
  color: var(--pink);
  text-shadow: var(--glow-pink);
  letter-spacing: 3px;
  margin-top: 6px;
  z-index: 2;
  position: relative;
}

.hero-tagline {
  font-family: 'Nunito', sans-serif;
  font-weight: 900;
  font-size: clamp(0.85rem, 2vw, 1.1rem);
  color: rgba(0,255,65,0.7);
  letter-spacing: 2px;
  margin-top: 16px;
  z-index: 2;
  position: relative;
  text-transform: uppercase;
}

/* ===== BUTTONS ===== */
.btn-group {
  display: flex;
  gap: 16px;
  margin-top: 36px;
  flex-wrap: wrap;
  justify-content: center;
  z-index: 2;
  position: relative;
}

.btn {
  font-family: 'Bangers', cursive;
  font-size: 1.4rem;
  letter-spacing: 2px;
  padding: 14px 36px;
  border: none;
  cursor: pointer;
  text-decoration: none;
  display: inline-block;
  transition: all 0.15s;
  clip-path: polygon(10px 0, 100% 0, calc(100% - 10px) 100%, 0 100%);
  position: relative;
  overflow: hidden;
}

.btn::after {
  content: '';
  position: absolute;
  inset: 0;
  background: rgba(255,255,255,0.1);
  transform: translateX(-100%);
  transition: transform 0.3s;
}

.btn:hover::after { transform: translateX(100%); }

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

.btn-primary:hover {
  box-shadow: var(--glow-green);
  transform: scale(1.05);
}

.btn-secondary {
  background: transparent;
  color: var(--pink);
  border: 2px solid var(--pink);
}

.btn-secondary:hover {
  background: var(--pink);
  color: #000;
  box-shadow: var(--glow-pink);
  transform: scale(1.05);
}

/* ===== TICKER ===== */
.ticker-wrap {
  background: var(--neon-green);
  color: #000;
  padding: 10px 0;
  overflow: hidden;
  white-space: nowrap;
  position: relative;
}

.ticker {
  display: inline-block;
  animation: tickerMove 20s linear infinite;
  font-family: 'Bangers', cursive;
  font-size: 1.2rem;
  letter-spacing: 2px;
}

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

/* ===== LIVE METRICS ===== */
.metrics-section {
  padding: 60px 20px 40px;
  text-align: center;
  position: relative;
}

.metrics-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
  gap: 16px;
  max-width: 960px;
  margin: 40px auto 0;
}

.metric-card {
  border: 1px solid rgba(0,255,65,0.25);
  padding: 22px 14px;
  text-align: center;
  position: relative;
  overflow: hidden;
  background: rgba(0,255,65,0.02);
  transition: all 0.3s;
  clip-path: polygon(10px 0, 100% 0, calc(100% - 10px) 100%, 0 100%);
}

.metric-card:hover {
  border-color: var(--neon-green);
  box-shadow: var(--glow-green);
  transform: translateY(-3px);
}

.metric-card .metric-icon {
  font-size: 1.6rem;
  margin-bottom: 6px;
}

.metric-card .metric-label {
  font-family: 'Boogaloo', cursive;
  font-size: 0.75rem;
  letter-spacing: 2px;
  color: rgba(0,255,65,0.55);
  text-transform: uppercase;
  margin-bottom: 4px;
}

.metric-card .metric-value {
  font-family: 'Bangers', cursive;
  font-size: 1.8rem;
  color: var(--neon-green);
  text-shadow: var(--glow-green);
  letter-spacing: 1px;
  line-height: 1.1;
  word-break: break-all;
}

.metrics-updated {
  font-family: 'Boogaloo', cursive;
  font-size: 0.75rem;
  color: rgba(0,255,65,0.35);
  letter-spacing: 1px;
  margin-top: 18px;
}

.metrics-links {
  display: flex;
  gap: 14px;
  justify-content: center;
  margin-top: 20px;
  flex-wrap: wrap;
}

.metrics-links a {
  font-family: 'Boogaloo', cursive;
  font-size: 0.95rem;
  color: var(--pink);
  text-decoration: none;
  border: 1px solid var(--pink);
  padding: 6px 18px;
  transition: all 0.2s;
  clip-path: polygon(6px 0, 100% 0, calc(100% - 6px) 100%, 0 100%);
}

.metrics-links a:hover {
  background: var(--pink);
  color: #000;
  box-shadow: var(--glow-pink);
}

/* ===== GAME SECTION ===== */
.game-section {
  padding: 80px 20px;
  text-align: center;
  position: relative;
}

.section-title {
  font-family: 'Bangers', cursive;
  font-size: clamp(2.5rem, 7vw, 5rem);
  letter-spacing: 4px;
  color: #fff;
  text-shadow: 0 0 20px var(--neon-green), 3px 3px 0 #000;
  margin-bottom: 10px;
}

.section-sub {
  font-family: 'Boogaloo', cursive;
  color: var(--green);
  font-size: 1.1rem;
  margin-bottom: 40px;
  letter-spacing: 1px;
  opacity: 0.8;
}

/* GAME CANVAS WRAPPER */
.game-wrapper {
  position: relative;
  display: inline-block;
  border: 2px solid var(--neon-green);
  box-shadow: var(--glow-green), inset 0 0 40px rgba(0,255,65,0.05);
  background: #000;
}

#gameCanvas {
  display: block;
}

.game-ui-overlay {
  position: absolute;
  inset: 0;
  pointer-events: none;
}

#gameStartScreen {
  position: absolute;
  inset: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  background: rgba(0,0,0,0.85);
  pointer-events: all;
}

.start-troll {
  width: 90px;
  height: 90px;
  object-fit: cover;
  border-radius: 50%;
  border: 2px solid var(--neon-green);
  box-shadow: var(--glow-green);
  animation: float 2s ease-in-out infinite;
  margin-bottom: 10px;
}

.start-title {
  font-family: 'Bangers', cursive;
  font-size: 2.5rem;
  color: var(--neon-green);
  text-shadow: var(--glow-green);
  letter-spacing: 3px;
  margin-bottom: 6px;
}

.start-instruction {
  font-family: 'Boogaloo', cursive;
  color: rgba(255,255,255,0.7);
  font-size: 1rem;
  margin-bottom: 24px;
  letter-spacing: 1px;
}

.start-btn {
  font-family: 'Bangers', cursive;
  font-size: 1.6rem;
  letter-spacing: 2px;
  padding: 12px 40px;
  background: var(--neon-green);
  color: #000;
  border: none;
  cursor: pointer;
  clip-path: polygon(10px 0, 100% 0, calc(100% - 10px) 100%, 0 100%);
  transition: all 0.15s;
  animation: pulsBtn 1.5s ease-in-out infinite;
}

@keyframes pulsBtn {
  0%, 100% { box-shadow: none; }
  50% { box-shadow: var(--glow-green); }
}

.start-btn:hover { transform: scale(1.05); }

.high-score-display {
  font-family: 'Boogaloo', cursive;
  color: var(--pink);
  font-size: 0.9rem;
  margin-top: 14px;
  letter-spacing: 1px;
}

.share-score-btn {
  font-family: 'Bangers', cursive;
  font-size: 1rem;
  letter-spacing: 1px;
  padding: 8px 22px;
  background: transparent;
  color: var(--pink);
  border: 1px solid var(--pink);
  cursor: pointer;
  margin-top: 10px;
  clip-path: polygon(6px 0, 100% 0, calc(100% - 6px) 100%, 0 100%);
  transition: all 0.2s;
}

.share-score-btn:hover {
  background: var(--pink);
  color: #000;
  box-shadow: var(--glow-pink);
}

/* SCORES PANEL */
.score-panel {
  display: flex;
  gap: 40px;
  justify-content: center;
  margin-top: 20px;
  flex-wrap: wrap;
}

.score-card {
  border: 1px solid rgba(0,255,65,0.3);
  padding: 16px 32px;
  background: rgba(0,255,65,0.03);
  text-align: center;
  clip-path: polygon(8px 0, 100% 0, calc(100% - 8px) 100%, 0 100%);
}

.score-label {
  font-family: 'Boogaloo', cursive;
  font-size: 0.8rem;
  letter-spacing: 2px;
  color: rgba(0,255,65,0.6);
  text-transform: uppercase;
}

.score-value {
  font-family: 'Bangers', cursive;
  font-size: 2.2rem;
  color: var(--neon-green);
  text-shadow: var(--glow-green);
  letter-spacing: 2px;
}

/* ===== HOW TO BUY ===== */
.how-section {
  padding: 80px 20px;
  background: rgba(0,255,65,0.02);
  border-top: 1px solid rgba(0,255,65,0.1);
  border-bottom: 1px solid rgba(0,255,65,0.1);
}

.steps {
  display: flex;
  gap: 0;
  max-width: 900px;
  margin: 50px auto 0;
  position: relative;
}

.steps::before {
  content: '';
  position: absolute;
  top: 30px;
  left: 10%;
  right: 10%;
  height: 2px;
  background: linear-gradient(90deg, transparent, var(--neon-green), transparent);
  z-index: 0;
}

.step {
  flex: 1;
  text-align: center;
  padding: 0 16px;
  position: relative;
  z-index: 1;
}

.step-num {
  width: 60px;
  height: 60px;
  border-radius: 50%;
  background: var(--darker);
  border: 2px solid var(--neon-green);
  display: flex;
  align-items: center;
  justify-content: center;
  font-family: 'Bangers', cursive;
  font-size: 1.6rem;
  color: var(--neon-green);
  text-shadow: var(--glow-green);
  margin: 0 auto 16px;
  box-shadow: var(--glow-green);
}

.step-title {
  font-family: 'Boogaloo', cursive;
  font-size: 1.1rem;
  color: #fff;
  margin-bottom: 8px;
  letter-spacing: 1px;
}

.step-desc {
  font-size: 0.85rem;
  color: rgba(0,255,65,0.6);
  line-height: 1.5;
}

/* ===== CA BOX ===== */
.ca-section {
  padding: 60px 20px;
  text-align: center;
}

.ca-box {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  border: 1px solid var(--neon-green);
  padding: 16px 28px;
  background: rgba(0,255,65,0.05);
  box-shadow: var(--glow-green);
  cursor: pointer;
  transition: all 0.2s;
  flex-wrap: wrap;
  justify-content: center;
}

.ca-box:hover { background: rgba(0,255,65,0.1); }

.ca-label {
  font-family: 'Boogaloo', cursive;
  font-size: 0.85rem;
  color: var(--green);
  letter-spacing: 2px;
  text-transform: uppercase;
}

.ca-address {
  font-family: monospace;
  font-size: 1rem;
  color: #fff;
  word-break: break-all;
}

.ca-copy {
  font-family: 'Bangers', cursive;
  font-size: 1rem;
  color: var(--neon-green);
  letter-spacing: 1px;
  padding: 6px 16px;
  border: 1px solid var(--neon-green);
  background: transparent;
  cursor: pointer;
  transition: all 0.2s;
}

.ca-copy:hover { background: var(--neon-green); color: #000; }

.ca-note {
  margin-top: 14px;
  font-size: 0.8rem;
  color: rgba(0,255,65,0.4);
  font-family: 'Boogaloo', cursive;
  letter-spacing: 1px;
}

/* ===== FOOTER ===== */
footer {
  padding: 40px 20px;
  text-align: center;
  border-top: 1px solid rgba(0,255,65,0.1);
  font-family: 'Boogaloo', cursive;
  color: rgba(0,255,65,0.4);
  font-size: 0.9rem;
  letter-spacing: 1px;
}

footer a {
  color: var(--pink);
  text-decoration: none;
}

.footer-disclaimer {
  margin-top: 8px;
  font-size: 0.75rem;
  opacity: 0.5;
}

/* ===== ANIMATIONS ===== */
@keyframes flicker {
  0%, 95%, 100% { opacity: 1; }
  96% { opacity: 0.4; }
  97% { opacity: 1; }
  98% { opacity: 0.6; }
  99% { opacity: 1; }
}

/* ===== MOBILE ===== */
@media (max-width: 600px) {
  nav { padding: 12px 16px; }
  .nav-links { display: none; }
  .steps { flex-direction: column; gap: 30px; }
  .steps::before { display: none; }
  #gameCanvas { width: 100% !important; }
  .metrics-grid { grid-template-columns: repeat(2, 1fr); }
  .metric-card .metric-value { font-size: 1.3rem; }
}
