/* ============================================
   Brain Age Test Plugin — Stylesheet
   Dark neuroscience aesthetic
   ============================================ */

@import url('https://fonts.googleapis.com/css2?family=Bebas+Neue&family=DM+Sans:wght@300;400;500;600&display=swap');

:root {
  --bat-bg:        #06060f;
  --bat-surface:   #0d0d1f;
  --bat-border:    rgba(108,99,255,0.25);
  --bat-purple:    #6c63ff;
  --bat-cyan:      #00d4ff;
  --bat-pink:      #ff6b9d;
  --bat-white:     #f0f0ff;
  --bat-muted:     rgba(240,240,255,0.55);
  --bat-radius:    18px;
  --bat-glow:      0 0 40px rgba(108,99,255,0.35);
}

/* WRAPPER */
.bat-wrapper {
  font-family: 'DM Sans', sans-serif;
  background: var(--bat-bg);
  border: 1px solid var(--bat-border);
  border-radius: var(--bat-radius);
  overflow: hidden;
  position: relative;
  min-height: 480px;
  max-width: 660px;
  margin: 2rem auto;
  box-shadow: var(--bat-glow), 0 8px 64px rgba(0,0,0,0.6);
}

/* SCREENS */
.bat-screen { display: none; position: relative; }
.bat-screen.active { display: block; }

/* PARTICLES CANVAS */
.bat-particles {
  position: absolute;
  inset: 0;
  pointer-events: none;
  background:
    radial-gradient(ellipse at 20% 50%, rgba(108,99,255,0.12) 0%, transparent 60%),
    radial-gradient(ellipse at 80% 20%, rgba(0,212,255,0.10) 0%, transparent 50%);
}

/* ============ INTRO SCREEN ============ */
.bat-screen--intro { padding: 3rem 2rem 2.5rem; text-align: center; }

.bat-brain-icon {
  font-size: 3.5rem;
  margin-bottom: 1rem;
  display: inline-block;
  animation: bat-float 3s ease-in-out infinite;
}
@keyframes bat-float {
  0%,100% { transform: translateY(0); }
  50%      { transform: translateY(-8px); }
}

.bat-title {
  font-family: 'Bebas Neue', sans-serif;
  font-size: clamp(2rem, 5vw, 3rem);
  color: var(--bat-white);
  line-height: 1.1;
  margin: 0 0 1rem;
  letter-spacing: 1px;
}
.bat-title span {
  background: linear-gradient(135deg, var(--bat-purple), var(--bat-cyan));
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.bat-subtitle {
  color: var(--bat-muted);
  font-size: 1rem;
  max-width: 420px;
  margin: 0 auto 2rem;
  line-height: 1.6;
}

.bat-stats {
  display: flex;
  justify-content: center;
  gap: 2rem;
  margin-bottom: 2rem;
  flex-wrap: wrap;
}
.bat-stat { text-align: center; }
.bat-stat__num {
  display: block;
  font-family: 'Bebas Neue', sans-serif;
  font-size: 2rem;
  color: var(--bat-cyan);
  letter-spacing: 1px;
}
.bat-stat__label {
  font-size: 0.72rem;
  color: var(--bat-muted);
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

/* BUTTONS */
.bat-btn {
  display: inline-block;
  border: none;
  border-radius: 999px;
  cursor: pointer;
  font-family: 'DM Sans', sans-serif;
  font-weight: 600;
  transition: all 0.25s ease;
  text-decoration: none;
  text-align: center;
}
.bat-btn--primary {
  background: linear-gradient(135deg, var(--bat-purple), var(--bat-cyan));
  color: #fff;
  padding: 1rem 2.5rem;
  font-size: 1.05rem;
  box-shadow: 0 4px 30px rgba(108,99,255,0.45);
}
.bat-btn--primary:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 40px rgba(108,99,255,0.6);
}
.bat-btn--secondary {
  background: transparent;
  border: 1px solid var(--bat-border);
  color: var(--bat-muted);
  padding: 0.7rem 1.8rem;
  font-size: 0.9rem;
  margin-top: 0.75rem;
}
.bat-btn--secondary:hover { border-color: var(--bat-purple); color: var(--bat-white); }
.bat-btn--cta { margin: 1.25rem auto 0.5rem; display: block; width: fit-content; }

.bat-disclaimer {
  font-size: 0.75rem;
  color: var(--bat-muted);
  margin-top: 1rem;
}

/* ============ QUIZ SCREEN ============ */
.bat-screen--quiz { padding: 0; }

.bat-quiz__header {
  background: rgba(13,13,31,0.95);
  padding: 1.25rem 1.75rem 1rem;
  border-bottom: 1px solid var(--bat-border);
}

.bat-progress-bar {
  background: rgba(255,255,255,0.08);
  border-radius: 999px;
  height: 6px;
  overflow: hidden;
  margin-bottom: 0.6rem;
}
.bat-progress-fill {
  height: 100%;
  border-radius: 999px;
  background: linear-gradient(90deg, var(--bat-purple), var(--bat-cyan));
  width: 10%;
  transition: width 0.4s ease;
}

.bat-question-counter {
  font-size: 0.78rem;
  color: var(--bat-muted);
  text-transform: uppercase;
  letter-spacing: 0.06em;
}

.bat-quiz__body { padding: 2rem 1.75rem 2.5rem; }

.bat-question-text {
  font-size: clamp(1.1rem, 3vw, 1.35rem);
  color: var(--bat-white);
  font-weight: 600;
  margin-bottom: 1.75rem;
  line-height: 1.45;
  min-height: 3em;
}

.bat-options { display: grid; gap: 0.75rem; }

.bat-option {
  background: rgba(255,255,255,0.04);
  border: 1px solid var(--bat-border);
  border-radius: 12px;
  color: var(--bat-white);
  cursor: pointer;
  font-family: 'DM Sans', sans-serif;
  font-size: 0.95rem;
  padding: 0.9rem 1.25rem;
  text-align: left;
  transition: all 0.2s ease;
  display: flex;
  align-items: center;
  gap: 0.75rem;
}
.bat-option:hover {
  background: rgba(108,99,255,0.15);
  border-color: var(--bat-purple);
  transform: translateX(4px);
}
.bat-option.selected {
  background: linear-gradient(135deg, rgba(108,99,255,0.3), rgba(0,212,255,0.15));
  border-color: var(--bat-cyan);
}
.bat-option__letter {
  width: 28px;
  height: 28px;
  border-radius: 50%;
  border: 1px solid var(--bat-border);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.8rem;
  font-weight: 700;
  flex-shrink: 0;
  color: var(--bat-cyan);
}

/* ============ RESULT SCREEN ============ */
.bat-screen--result { padding: 2.5rem 2rem; text-align: center; }

.bat-result__label {
  color: var(--bat-muted);
  font-size: 0.9rem;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  margin-bottom: 0.5rem;
}

.bat-result__age-wrapper {
  display: flex;
  align-items: baseline;
  justify-content: center;
  gap: 0.5rem;
  margin-bottom: 1.5rem;
}
.bat-result__age {
  font-family: 'Bebas Neue', sans-serif;
  font-size: clamp(4rem, 15vw, 7rem);
  background: linear-gradient(135deg, var(--bat-purple), var(--bat-cyan));
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  line-height: 1;
  animation: bat-pop 0.5s cubic-bezier(0.34,1.56,0.64,1) both;
}
@keyframes bat-pop {
  from { transform: scale(0.5); opacity: 0; }
  to   { transform: scale(1);   opacity: 1; }
}
.bat-result__unit {
  font-family: 'Bebas Neue', sans-serif;
  font-size: 2rem;
  color: var(--bat-muted);
}

/* GAUGE */
.bat-result__gauge { margin: 0 auto 1.5rem; max-width: 340px; }
.bat-gauge__track {
  background: rgba(255,255,255,0.08);
  border-radius: 999px;
  height: 10px;
  overflow: hidden;
}
.bat-gauge__fill {
  height: 100%;
  border-radius: 999px;
  background: linear-gradient(90deg, var(--bat-cyan), var(--bat-purple), var(--bat-pink));
  width: 0%;
  transition: width 1.2s cubic-bezier(0.22,1,0.36,1);
}
.bat-gauge__labels {
  display: flex;
  justify-content: space-between;
  margin-top: 0.4rem;
  font-size: 0.72rem;
  color: var(--bat-muted);
}

.bat-result__badge {
  display: inline-block;
  background: rgba(108,99,255,0.15);
  border: 1px solid var(--bat-purple);
  border-radius: 999px;
  padding: 0.4rem 1.2rem;
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--bat-purple);
  margin-bottom: 1rem;
}

.bat-result__desc {
  color: var(--bat-muted);
  font-size: 0.95rem;
  max-width: 420px;
  margin: 0 auto 1.25rem;
  line-height: 1.65;
}

.bat-result__tips {
  background: rgba(255,255,255,0.03);
  border: 1px solid var(--bat-border);
  border-radius: 14px;
  padding: 1.25rem 1.5rem;
  text-align: left;
  margin-bottom: 1.5rem;
  max-width: 420px;
  margin-left: auto;
  margin-right: auto;
}
.bat-result__tips h4 {
  color: var(--bat-cyan);
  font-size: 0.8rem;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  margin: 0 0 0.75rem;
}
.bat-result__tips ul {
  list-style: none;
  padding: 0;
  margin: 0;
}
.bat-result__tips li {
  color: var(--bat-white);
  font-size: 0.88rem;
  padding: 0.35rem 0;
  border-bottom: 1px solid rgba(255,255,255,0.05);
  display: flex;
  gap: 0.5rem;
  align-items: flex-start;
  line-height: 1.4;
}
.bat-result__tips li:last-child { border-bottom: none; }

/* SHARE */
.bat-share { margin-top: 1.5rem; }
.bat-share p { color: var(--bat-muted); font-size: 0.82rem; margin-bottom: 0.6rem; }
.bat-share__buttons { display: flex; justify-content: center; gap: 0.75rem; }
.bat-share__btn {
  border: none;
  border-radius: 999px;
  cursor: pointer;
  font-family: 'DM Sans', sans-serif;
  font-weight: 600;
  font-size: 0.85rem;
  padding: 0.55rem 1.4rem;
  transition: opacity 0.2s;
}
.bat-share__btn:hover { opacity: 0.85; }
.bat-share__btn--fb { background: #1877f2; color: #fff; }
.bat-share__btn--wa { background: #25d366; color: #fff; }

/* RESPONSIVE */
@media (max-width: 480px) {
  .bat-screen--intro,
  .bat-screen--result { padding: 2rem 1.25rem 2rem; }
  .bat-quiz__body { padding: 1.5rem 1.25rem 2rem; }
  .bat-stats { gap: 1.2rem; }
}
