/* Host Container */
#bsrc-host-screen {
  max-width: 620px;
  margin: auto;
  background: linear-gradient(145deg, #fdfcff, #e8faff);
  padding: 30px;
  border-radius: 20px;
  box-shadow: 0 0 20px rgba(0, 200, 255, 0.2);
  border: 4px double #99ccff;
  animation: borderPulse 3s infinite alternate;
  text-align: center;
}

/* Host Headings and Paragraph */
#bsrc-host-screen h2 {
  font-size: 2em;
  color: #ff3399;
  margin-bottom: 10px;
}
#bsrc-host-screen p {
  font-size: 1.1em;
  margin-bottom: 20px;
  color: #555;
}

/* Gender Buttons */
.gender-select {
  background: linear-gradient(135deg, #ffccff, #ccffff);
  padding: 14px 22px;
  margin: 10px;
  border-radius: 12px;
  border: 3px solid #fff;
  font-weight: bold;
  font-size: 1.1em;
  cursor: pointer;
  transition: all 0.3s ease;
  box-shadow: 0 0 12px #ff99cc;
}
.gender-select:hover {
  transform: scale(1.08);
  box-shadow: 0 0 18px #ff66b2;
}
.gender-select:active {
  transform: scale(0.95);
  background: #ffeeff;
}
.gender-select.selected {
  box-shadow: 0 0 20px #33ccff;
  background: #d9f9ff;
  border: 2px solid #33ccff;
}

/* Link Box Styling */
#bsrc-link-box {
  border: 3px dashed #66ccff;
  border-radius: 15px;
  padding: 16px;
  margin-top: 20px;
  background: #f0f8ff;
  box-shadow: 0 0 12px rgba(0, 204, 255, 0.3);
}

/* Input */
#bsrc-generated-link {
  border: 2px solid #66ccff;
  border-radius: 10px;
  padding: 10px;
  font-size: 1em;
  text-align: center;
  width: 100%;
  box-shadow: 0 0 8px #66ccff;
  margin-bottom: 12px;
}

/* Copy & Open Link buttons aligned side by side */
#bsrc-copy-btn,
#bsrc-open-btn {
  background: linear-gradient(to right, #99ccff, #ccffff);
  border: none;
  padding: 10px 16px;
  margin: 0 6px;
  border-radius: 10px;
  font-weight: bold;
  cursor: pointer;
  transition: transform 0.2s ease, background 0.3s ease;
  box-shadow: 0 4px 10px rgba(0, 204, 255, 0.2);
  display: inline-block;
}
#bsrc-copy-btn:hover,
#bsrc-open-btn:hover {
  transform: scale(1.05);
  background: #ccf2ff;
}

/* Animation for border pulse */
@keyframes borderPulse {
  0% {
    box-shadow: 0 0 10px rgba(0, 204, 255, 0.3);
  }
  100% {
    box-shadow: 0 0 25px rgba(0, 204, 255, 0.6);
  }
}

/* Container */
#bsrc-container {
  max-width: 600px;
  margin: auto;
  padding: 20px;
  font-family: 'Comic Sans MS', cursive;
  background: linear-gradient(135deg, #fff0f5, #e0ffff);
  border-radius: 15px;
  box-shadow: 0 0 10px rgba(255, 105, 180, 0.3);
  animation: fadeIn 1s ease-in;
  overflow-x: hidden;
}

/* Start Screen */
#bsrc-start-screen {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
}
#bsrc-start-screen input {
  padding: 12px;
  font-size: 1.3em;
  border-radius: 10px;
  border: 2px solid #ff66b2;
  width: 80%;
  margin: 12px 0;
  height: 43px;
}
#bsrc-start-btn {
  background: linear-gradient(to right, #ff66b2, #ff99cc);
  border: none;
  border-radius: 8px;
  padding: 12px 20px;
  color: white;
  font-weight: bold;
  cursor: pointer;
  font-size: 1.1em;
  box-shadow: 0 4px 10px rgba(255, 105, 180, 0.3);
  transition: transform 0.3s ease;
  display: block;
  margin: 20px auto;
}
#bsrc-start-btn:hover {
  transform: scale(1.05);
}
#bsrc-start-btn:disabled {
  background: #ddd;
  color: #888;
  cursor: not-allowed;
  box-shadow: none;
  transform: none;
}

/* Scoreboard */
#bsrc-scoreboard {
  display: flex;
  justify-content: space-between;
  font-weight: bold;
  font-size: 1em;
  margin: 10px 0;
  color: #cc0066;
}

/* Progress Bar */
#bsrc-current-question {
  font-weight: bold;
  font-size: 1.3em;
	color: #cc0066;
	display: flex;
	justify-content: center;
}
#bsrc-progress-bar {
  width: 100%;
  background: #ffe6f0;
  height: 12px;
  border-radius: 10px;
  margin: 10px 0 20px;
  overflow: hidden;
}
#bsrc-progress-fill {
  height: 100%;
  width: 0%;
  background: linear-gradient(to right, #ff3399, #ff99cc);
  transition: width 0.4s ease-in-out;
}

/* Audio Box */
#bsrc-audio-box button {
  font-size: 1.1em;
  padding: 10px 20px;
  background: #ff66b2;
  color: white;
  border: none;
  border-radius: 10px;
  cursor: pointer;
  font-weight: bold;
  box-shadow: 0 4px 6px rgba(255, 105, 180, 0.3);
  margin: 0 auto;
  display: flex;
  align-items: center;
  justify-content: center;
}
#bsrc-audio-box button:hover {
  transform: scale(1.05);
}

/* Answer Buttons */
#bsrc-answer-options {
  margin-top: 20px;
}
#bsrc-answer-options button {
  display: block;
  width: 55%;
  margin: 12px auto;
  padding: 14px;
  font-size: 1.1em;
  background: linear-gradient(to right, #ff66b2, #ff99cc);
  color: white;
  border: none;
  border-radius: 10px;
  cursor: pointer;
  transition: 0.3s ease;
}
#bsrc-answer-options button:hover {
  transform: scale(1.05);
  filter: brightness(1.1);
}
.correct-answer {
  background: #28a745 !important;
  color: white !important;
  animation: zoomHighlight 0.4s ease;
  transform: scale(1.1);
}

@keyframes zoomHighlight {
  0% { transform: scale(1); }
  50% { transform: scale(1.15); }
  100% { transform: scale(1.1); }
}

/* Speaker Buzzing Animation */
#bsrc-play-sound.buzzing::before {
  content: "🔊";
  margin-right: 8px;
  animation: buzz 0.6s infinite;
  display: inline-block;
}

@keyframes buzz {
  0% { transform: rotate(0deg); }
  25% { transform: rotate(8deg); }
  50% { transform: rotate(-8deg); }
  75% { transform: rotate(8deg); }
  100% { transform: rotate(0deg); }
}

/* Hint Button */
#bsrc-hint-btn {
  background: #ffd700;
  color: #222;
  font-weight: bold;
  padding: 10px 18px;
  border: none;
  border-radius: 10px;
  margin: 0 auto;
  font-size: 1em;
  box-shadow: 0 4px 10px rgba(255, 215, 0, 0.3);
  transition: transform 0.3s ease;
  float: right;
}
#bsrc-hint-btn:hover {
  transform: scale(1.05);
}

/* Feedback */
#bsrc-feedback {
  font-weight: bold;
  font-size: 1.2em;
  min-height: 30px;
  margin-top: 15px;
  animation: fadeIn 0.4s ease;
  display: flex;
  text-align: center;
  justify-content: center;
}
#bsrc-bonus-label {
  color: #28a745;
  font-weight: bold;
  animation: pop 0.4s ease;
  margin-top: 5px;
}

/* Final Screen */
#bsrc-final-screen {
  margin-top: 30px;
  padding: 40px 25px;
  background: linear-gradient(135deg, #fff0f5, #e0ffff);
  border-radius: 20px;
  box-shadow: 0 0 25px rgba(255, 182, 193, 0.4);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  animation: fadeIn 1s ease;
}

/* Gender Reveal Text */
#bsrc-reveal-text {
  font-size: 2.7em !important;
  font-weight: bold !important;
  text-align: center;
  color: #ffffff;
  background: linear-gradient(to right, #ff66b2, #ff99cc);
  padding: 22px;
  border-radius: 15px;
  border: 6px dashed #ffccdd;
  max-width: 90%;
  margin: 20px auto 30px;
  text-shadow: 2px 2px 5px rgba(0, 0, 0, 0.1);
  animation: swirlGlow 2.5s infinite ease-in-out;
}

@keyframes swirlGlow {
  0% {
    transform: rotate(0deg) scale(1);
    box-shadow: 0 0 8px #ff66b2;
  }
  50% {
    transform: rotate(1.5deg) scale(1.05);
    box-shadow: 0 0 16px #ff99cc;
  }
  100% {
    transform: rotate(0deg) scale(1);
    box-shadow: 0 0 8px #ff66b2;
  }
}

@keyframes pulseSpin {
  0% { transform: scale(1) rotate(0deg); opacity: 1; }
  25% { transform: scale(1.05) rotate(5deg); opacity: 0.9; }
  50% { transform: scale(1.1) rotate(-5deg); opacity: 1; }
  75% { transform: scale(1.05) rotate(5deg); opacity: 0.95; }
  100% { transform: scale(1) rotate(0deg); opacity: 1; }
}

.swirl {
  animation: pulseSpin 3s ease-in-out infinite;
  text-shadow: 0 0 8px #fff, 0 0 16px #ff66b2;
}

/* Summary Text / Analytics */
#bsrc-summary {
  font-size: 1.15em;
  color: #444;
  background: #fefefe;
  border: 2px solid #ccf2ff;
  border-radius: 12px;
  padding: 20px;
  width: 95%;
  max-width: 500px;
  box-shadow: 0 0 15px rgba(102, 204, 255, 0.2);
  margin-bottom: 30px;
  line-height: 1.6;
  text-align: left;
  animation: fadeIn 1.2s ease;
}

/* Share Buttons */
#bsrc-share-buttons {
  margin: 20px auto 30px;
  display: flex;
  gap: 15px;
  flex-wrap: wrap;
  justify-content: center;
}
#bsrc-share-buttons a {
  display: inline-block;
  padding: 12px 20px;
  background: linear-gradient(135deg, #ff99cc, #ff66b2);
  color: white;
  border-radius: 10px;
  font-weight: bold;
  text-decoration: none;
  box-shadow: 0 4px 12px rgba(255, 102, 178, 0.2);
  transition: transform 0.2s ease, background 0.3s ease;
}
#bsrc-share-buttons a:hover {
  transform: scale(1.08);
  background: #e653a3;
}
#bsrc-share-prompt {
  font-size: 1.4em;
  color: #ff66b2;
  font-weight: bold;
  margin-top: 20px;
  animation: pulse 2s infinite;
  text-align: center;
}

@keyframes pulse {
  0% { transform: scale(1); opacity: 0.6; }
  50% { transform: scale(1.1); opacity: 1; }
  100% { transform: scale(1); opacity: 0.6; }
}

/* Animate share buttons after delay */
.bsrc-animate-share a {
  animation: bounceGlow 1s ease-out 3s forwards;
}
@keyframes bounceGlow {
  0% { transform: scale(1); box-shadow: none; }
  50% { transform: scale(1.1); box-shadow: 0 0 15px #ff66b2; }
  100% { transform: scale(1); box-shadow: 0 0 8px #ff66b2; }
}

/*Download E-Certificate*/
.primary-btn {
  background: linear-gradient(135deg, #ff66b2, #ff99cc);
  border: none;
  padding: 14px 26px;
  border-radius: 12px;
  font-size: 1.1em;
  font-weight: bold;
  color: white;
  cursor: pointer;
  margin-top: 20px;
  margin-bottom: 30px;
  box-shadow: 0 5px 15px rgba(255, 105, 180, 0.4);
  transition: transform 0.3s ease, box-shadow 0.3s ease;
  animation: glowPulse 2.5s infinite;
}

.primary-btn:hover {
  transform: scale(1.05);
  box-shadow: 0 0 20px #ff66b2;
}

@keyframes glowPulse {
  0% { box-shadow: 0 0 10px #ff66b2; }
  50% { box-shadow: 0 0 20px #ff99cc; }
  100% { box-shadow: 0 0 10px #ff66b2; }
}

/* Play Again Button */
#bsrc-restart-btn {
  background: linear-gradient(to right, #66ccff, #99e6ff);
  padding: 14px 28px;
  font-size: 1.15em;
  border-radius: 12px;
  border: none;
  color: white;
  font-weight: bold;
  margin-top: 10px;
  cursor: pointer;
  transition: transform 0.3s ease, box-shadow 0.3s ease;
  box-shadow: 0 6px 16px rgba(102, 204, 255, 0.4);
}
#bsrc-restart-btn:hover {
  transform: scale(1.05);
  box-shadow: 0 6px 20px rgba(102, 204, 255, 0.6);
}

/* Sparkle Canvas */
#sparkle-canvas {
  position: fixed;
  top: 0;
  left: 0;
  pointer-events: none;
  z-index: 1;
}

/* Animations */
@keyframes fadeIn {
  from { opacity: 0; transform: translateY(15px); }
  to { opacity: 1; transform: translateY(0); }
}
@keyframes pop {
  0% { transform: scale(0.95); }
  50% { transform: scale(1.05); }
  100% { transform: scale(1); }
}
.typewriter {
  overflow: hidden;
  white-space: nowrap;
  border-right: 3px solid #ff66b2;
  animation: typing 3s steps(40, end), blink-caret 0.5s step-end infinite;
}
@keyframes typing {
  from { width: 0; }
  to { width: 100%; }
}
@keyframes blink-caret {
  from, to { border-color: transparent; }
  50% { border-color: #ff66b2; }
}

/* Utility */
.hidden { display: none !important; }
.flex { display: flex; }
.space-between { justify-content: space-between; }

/* Mobile Fixes */
@media (max-width: 480px) {
  #bsrc-scoreboard { align-items: center; gap: 6px; }
  #bsrc-container { padding: 15px; width: 95%; }
  #bsrc-reveal-text { font-size: 1.8em !important; padding: 15px !important; }
  #bsrc-start-btn,
  #bsrc-hint-btn,
  #bsrc-restart-btn {
    font-size: 1.3em !important;
    padding: 14px 20px !important;
  }
	#bsrc-answer-options button {
		font-size: 1.4em !important;
	}
}