@charset "UTF-8";
/* CSS Document */

* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
  font-family: "Jockey One", sans-serif;
}

html,
body {
  height: 100%;
  overflow: hidden;
  background-color: #333;
}

.loading-container {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  background-image: linear-gradient(to bottom, #004a94, #003469);
  z-index: 1000;
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.5s ease, visibility 0.5s ease;
}

.loading-container .background-grid {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background-image: linear-gradient(
      rgba(255, 255, 255, 0.1) 1px,
      transparent 1px
    ),
    linear-gradient(90deg, rgba(255, 255, 255, 0.1) 1px, transparent 1px);
  background-size: 80px 50px;
  transform: perspective(500px) rotateX(60deg);
  animation: gridMove 8s linear infinite, gridBreathe 4s ease-in-out infinite;
}

@keyframes gridMove {
  0% {
    background-position: 0 0;
    transform: perspective(500px) rotateX(60deg) translateY(0);
  }
  50% {
    background-position: 80px 50px;
    transform: perspective(500px) rotateX(60deg) translateY(-10px);
  }
  100% {
    background-position: 0 0;
    transform: perspective(500px) rotateX(60deg) translateY(0);
  }
}

@keyframes gridBreathe {
  0%,
  100% {
    opacity: 0.4;
  }
  50% {
    opacity: 0.7;
  }
}

.question-marks {
  display: flex;
  justify-content: center;
  align-items: center;
  margin-bottom: 20px;
  transition: opacity 0.5s ease;
}

.loading-text {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  color: white;
  font-family: "Poppins", sans-serif;
  font-size: 2.8rem;
  font-weight: 600;
  text-align: center;
  opacity: 0;
  transition: all 0.8s ease;
  text-shadow: 0 2px 4px rgba(0, 0, 0, 0.3);
  letter-spacing: 2px;
  padding: 20px 40px;
  border: 4px solid rgba(255, 255, 255, 0.9);
  border-radius: 8px;
  background: linear-gradient(to bottom, #e50024, #cc0000);
  backdrop-filter: blur(4px);
}

.loading-text.visible {
  opacity: 1;
  transform: translate(-50%, -50%) scale(1);
  animation: gentleFloat 3s ease-in-out infinite;
}

.loading-text.hidden {
  opacity: 0;
  transform: translate(-50%, -50%) scale(0.95);
}

.question-marks.hidden {
  opacity: 0;
}

.question-mark {
  font-family: "Poppins", sans-serif;
  font-weight: 900;
  font-style: normal;
  font-size: 10rem;
  -webkit-text-stroke-width: 3px;
  -webkit-text-stroke-color: #ffffff;
  margin: 0 15px;
  text-shadow: 0px 4px 6px rgba(0, 0, 0, 0.1);
  opacity: 0;
  transform-style: preserve-3d;
  animation: questionMarkAppear 0.8s cubic-bezier(0.34, 1.56, 0.64, 1) infinite
      alternate,
    questionMarkFloat 3s ease-in-out infinite;
  background: linear-gradient(
    to bottom,
    #e50024 0%,
    #e50024 70%,
    #cc0000 85%,
    #cc0000 100%
  );
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
  display: inline-block;
}

.question-mark:nth-child(1) {
  animation-delay: 0s;
}

.question-mark:nth-child(2) {
  animation-delay: 0.3s;
}

.question-mark:nth-child(3) {
  animation-delay: 0.6s;
}

.home-container {
  background: linear-gradient(to bottom, #004a94, #003469);
  width: 100%;
  height: 100%;
  text-align: center;
  display: flex;
  justify-content: center;
  align-items: center;
  position: fixed;
  overflow: hidden;
  color: white;
  opacity: 1;
  visibility: visible;
  transition: opacity 0.4s ease, visibility 0.4s ease;
}

.home-container::before {
  content: "";
  position: absolute;
  width: 300%;
  height: 300%;
  top: -100%;
  left: -100%;
  background: repeating-conic-gradient(
    from 0deg,
    #004a94 0deg,
    #0055aa 10deg,
    #004a94 20deg
  );
  animation: rotate 60s linear infinite;
  z-index: 1;
  transform-origin: center center;
}

.home-container::after {
  content: "";
  position: absolute;
  inset: 0;
  background: radial-gradient(circle at center, transparent 0%, #003469 85%);
  z-index: 2;
}

@keyframes rotate {
  from {
    transform: rotate(0deg);
  }
  to {
    transform: rotate(360deg);
  }
}

.home-title {
  position: relative;
  z-index: 3;
  text-align: center;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  font-size: 2.5rem;
}

.logo {
  width: 500px;
  max-width: 80%;
  display: flex;
  justify-content: center;
}

.play-button {
  margin-top: 35px;
  padding: 15px 40px;
  background: linear-gradient(to bottom, #e50024, #cc0000);
  color: white;
  font-family: "Jockey One", sans-serif;
  font-size: 1.2em;
  font-weight: 500;
  letter-spacing: 0.5px;
  border: 3px solid rgba(255, 255, 255, 0.9);
  border-radius: 6px;
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.2),
    inset 0 1px 3px rgba(255, 255, 255, 0.3);
  cursor: pointer;
  transition: all 0.2s ease;
  text-shadow: 1px 1px 0 rgba(0, 0, 0, 0.2);
}

.play-button:hover {
  background: linear-gradient(to bottom, #ff0029, #e50024);
  transform: translateY(-2px);
  box-shadow: 0 4px 8px rgba(0, 0, 0, 0.3),
    inset 0 1px 3px rgba(255, 255, 255, 0.3);
}

.play-button:active {
  transform: translateY(1px);
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.2), inset 0 1px 3px rgba(0, 0, 0, 0.2);
}

#floating-home-container {
  position: absolute;
  width: 100%;
  height: 100%;
}

@keyframes floatUp {
  from {
    transform: translateY(0);
  }

  to {
    transform: translateY(-100vh);
  }
}

@keyframes questionMarkAppear {
  0% {
    opacity: 0;
    transform: scale(0.5) rotateX(-90deg);
  }
  100% {
    opacity: 1;
    transform: scale(1) rotateX(0deg);
  }
}

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

.loading-tip {
  color: white;
  font-size: 1.2rem;
  font-weight: 300;
  letter-spacing: 1px;
  text-transform: uppercase;
  opacity: 0;
  transform: translateY(20px);
  transition: opacity 0.5s ease, transform 0.5s ease;
}

.loading-tip.visible {
  opacity: 1;
  transform: translateY(0);
}

.loading-tip.hidden {
  opacity: 0;
  transform: translateY(-20px);
}

.game-container {
  width: 100%;
  height: 100vh;
  background-image: linear-gradient(to bottom, #004a94 60%, #003469 100%);
  padding: 20px;
  position: fixed;
  display: none;
  flex-direction: column;
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.8s ease, visibility 0.8s ease;
}

/* Grid Reference: W3Schools - CSS Grid */
/* and Stack Overflow */
.game-container .background-grid {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background-image: linear-gradient(
      rgba(255, 255, 255, 0.1) 1px,
      transparent 1px
    ),
    linear-gradient(90deg, rgba(255, 255, 255, 0.1) 1px, transparent 1px);
  background-size: 80px 50px;
  transform: perspective(500px) rotateX(60deg);
  animation: gridMove 8s linear infinite, gridBreathe 4s ease-in-out infinite;
  pointer-events: none;
  z-index: -1;
}

.title {
  text-align: center;
  margin-bottom: 10px;
  padding-top: 10px;
}

.title img {
  max-width: 250px;
  height: auto;
  margin-right: 250px;
  margin-top: 5px;
}

.game-board {
  display: grid;
  grid-template-columns: repeat(9, 1fr);
  grid-template-rows: repeat(6, 1fr);
  gap: 5px;
  flex-grow: 1;
  background-color: #2a73ba;
  width: 80%;
  padding: 20px;
  border-radius: 10px;
  box-shadow: inset 0 0 10px rgba(0, 0, 0, 0.5);
  position: relative;
  transform: perspective(1500px) rotateX(10deg);
  transform-origin: center bottom;
  margin-bottom: 25px;
  margin-left: 11px;
  overflow: visible;
}

.card {
  position: relative;
  transform-style: preserve-3d;
  transition: transform 0.3s;
}

.card-inner {
  position: absolute;
  width: 100%;
  height: 350%;
  border: 4px solid white;
  border-radius: 4px;
  box-shadow: 2px 2px 5px rgba(0, 0, 0, 0.3);
  backface-visibility: hidden;
  transform-style: preserve-3d;
}

.character-card .card-inner {
  background: linear-gradient(to bottom, #00d4ff, #00b8e6);
  box-shadow: 0 4px 8px rgba(0, 0, 0, 0.2),
    inset 0 2px 8px rgba(255, 255, 255, 0.4);
}

.character-image {
  position: absolute;
  top: 10%;
  left: 10%;
  width: 80%;
  height: 80%;
  background-color: white;
  border-radius: 3px;
  overflow: hidden;
  box-shadow: inset 0 2px 4px rgba(0, 0, 0, 0.1);
  transition: all 0.5s cubic-bezier(0.34, 1.56, 0.64, 1);
  transform-origin: center;
  z-index: 1;
}

.controls {
  background: linear-gradient(to bottom, #ffffff, #eeeeee);
  border: 5px solid #ffffff;
  width: 80%;
  margin-left: 10px;
  padding: 10px;
  border-radius: 10px;
  display: flex;
  justify-content: space-around;
  flex-wrap: wrap;
  box-shadow: 0 0 10px rgba(0, 0, 0, 0.3);
  margin-bottom: 5px;
  flex-shrink: 0;
  z-index: 10;
}

.button {
  background: linear-gradient(to bottom, #e50024, #cc0000);
  color: white;
  font-family: "Jockey One", sans-serif;
  font-size: 1.2em;
  font-weight: 500;
  letter-spacing: 0.5px;
  padding: 10px 20px;
  border: 2px solid rgba(255, 255, 255, 0.9);
  border-radius: 6px;
  margin: 5px;
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.2),
    inset 0 1px 3px rgba(255, 255, 255, 0.3);
  cursor: pointer;
  transition: all 0.2s ease;
  text-shadow: 1px 1px 0 rgba(0, 0, 0, 0.2);
}

.button:hover {
  background: linear-gradient(to bottom, #ff0029, #e50024);
  transform: translateY(-2px);
  box-shadow: 0 4px 8px rgba(0, 0, 0, 0.3),
    inset 0 1px 3px rgba(255, 255, 255, 0.3);
}

.button:active {
  transform: translateY(1px);
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.2), inset 0 1px 3px rgba(0, 0, 0, 0.2);
}

.sidebar {
  position: absolute;
  top: 20px;
  right: 20px;
  width: 250px;
  height: calc(100vh - 40px);
  display: flex;
  margin-right: 10px;
  flex-direction: column;
  gap: 25px;
  z-index: 20;
}

.character-widget {
  flex: 1;
  background: linear-gradient(to bottom, #ffffff, #eeeeee);
  border: 5px solid #ffffff;
  border-radius: 10px;
  padding: 12px;
  box-shadow: 0 0 10px rgba(0, 0, 0, 0.3);
  display: flex;
  flex-direction: column;
  max-height: 71%;
  overflow-y: auto;
  margin-top: 5px;
}

.profile-img {
  width: 150px;
  height: 160px;
  min-height: 160px;
  background: linear-gradient(to bottom, #f8f8f8, #ffffff);
  margin: 0 auto 10px;
  display: flex;
  align-items: center;
  justify-content: center;
  border: 2px solid rgba(0, 0, 0, 0.2);
  border-radius: 6px;
  box-shadow: inset 0 2px 8px rgba(0, 0, 0, 0.1);
  overflow: hidden;
}

.profile-img .selected-character-image {
  width: 100%;
  height: 100%;
  background-size: 90%;
  background-position: center 20%;
  background-repeat: no-repeat;
}

.profile-placeholder {
  width: 80%;
  height: 80%;
  background: rgba(3, 80, 148, 0.05);
  border: 2px dashed rgba(3, 80, 148, 0.2);
  border-radius: 4px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.profile-placeholder img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  border-radius: 4px;
}

.profile-placeholder.empty {
  background: rgba(3, 80, 148, 0.05);
  border: 2px dashed rgba(3, 80, 148, 0.2);
}

.attributes {
  margin-top: 8px;
  overflow-y: auto;
}

.attributes {
  scrollbar-width: thin;
  scrollbar-color: #035094 rgba(3, 80, 148, 0.05);
}

.attribute {
  margin: 6px 0;
  padding: 4px 8px;
  font-size: 16px;
  letter-spacing: 0.5px;
  color: #035094;
  display: flex;
  justify-content: space-between;
  align-items: center;
  border-radius: 4px;
  transition: all 0.2s ease;
}

.attribute:first-child {
  margin: 0 0 15px 0;
  padding: 8px;
  font-size: 20px;
  text-align: center;
  justify-content: center;
  color: #cc0000;
  border-bottom: 2px solid rgba(3, 80, 148, 0.1);
  text-shadow: 1px 1px 0 rgba(255, 255, 255, 0.8);
  letter-spacing: 1px;
}

.attribute:not(:first-child):hover {
  background: rgba(0, 184, 230, 0.05);
}

.attribute-value {
  display: inline-block;
  min-width: 120px;
  text-align: center;
  padding: 4px 8px;
  margin-left: 10px;
  font-weight: 500;
  color: #cc0000;
  background: rgba(204, 0, 0, 0.03);
  border: 1px dashed rgba(204, 0, 0, 0.2);
  border-radius: 4px;
  position: relative;
  transition: all 0.2s ease;
}

.attribute-value:empty::before {
  content: "?";
  color: rgba(204, 0, 0, 0.3);
  font-size: 1.2em;
  font-weight: bold;
}

.attribute-value:hover {
  background: rgba(204, 0, 0, 0.05);
  border-color: rgba(204, 0, 0, 0.3);
  transform: translateX(2px);
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.05);
}

.attribute-value::after {
  display: none;
}

.game-status-widget {
  background: linear-gradient(to bottom, #ffffff, #eeeeee);
  border: 5px solid #ffffff;
  border-radius: 10px;
  padding: 15px;
  text-align: center;
  box-shadow: 0 0 10px rgba(0, 0, 0, 0.3);
  display: flex;
  flex-direction: column;
  align-items: center;
}

.hearts {
  display: inline-block;
  font-size: 48px;
  letter-spacing: 4px;
  margin-bottom: 15px;
  position: relative;
  z-index: 1;
}

.heart {
  font-size: 48px;
  margin: 0 6px;
  transition: all 0.3s ease;
}

.heart.active {
  color: #e50024;
  font-weight: bold;
}

.heart.inactive {
  color: #808080;
  opacity: 0.7;
}


.hearts.hearts-2 .heart.inactive {
  animation: shake-mild 0.35s ease-in-out infinite;
}


.hearts.hearts-2 .heart.active {
  animation: shake-and-pulse-mild 1.5s ease-in-out infinite;
}

.hearts.hearts-1 .heart.inactive {
  animation: shake-intense 0.25s ease-in-out infinite;
}


.hearts.hearts-1 .heart.active {
  animation: shake-and-pulse-intense 1s ease-in-out infinite;
}

@keyframes shake-mild {
  0%,
  100% {
    transform: translateX(0);
  }
  25% {
    transform: translateX(-0.3px);
  }
  50% {
    transform: translateX(0.3px);
  }
  75% {
    transform: translateX(-0.3px);
  }
}

@keyframes shake-intense {
  0%,
  100% {
    transform: translateX(0);
  }
  25% {
    transform: translateX(-0.7px);
  }
  50% {
    transform: translateX(0.7px);
  }
  75% {
    transform: translateX(-0.7px);
  }
}

@keyframes shake-and-pulse-mild {
  0%,
  100% {
    transform: translateX(0) scale(1);
  }
  25% {
    transform: translateX(-0.3px) scale(1.05);
  }
  50% {
    transform: translateX(0.3px) scale(1.1);
  }
  75% {
    transform: translateX(-0.3px) scale(1.05);
  }
}

@keyframes shake-and-pulse-intense {
  0%,
  100% {
    transform: translateX(0) scale(1);
  }
  25% {
    transform: translateX(-0.7px) scale(1.1);
  }
  50% {
    transform: translateX(0.7px) scale(1.2);
  }
  75% {
    transform: translateX(-0.7px) scale(1.1);
  }
}

.heart:hover {
  transform: scaley(1.2) translateY(-2px);
  filter: brightness(1.2);
  text-shadow: 0 4px 8px rgba(229, 0, 36, 0.3);
}

.heart.inactive:hover {
  transform: scale(0.9);
  color: #666666;
  filter: brightness(1);
  text-shadow: none;
}

.hearts.low-hearts {
  animation: none;
}

.hearts.hearts-2 {
  animation: sine-wave 3s ease-in-out infinite,
    shake-mild 3s ease-in-out infinite;
}

.hearts.hearts-1 {
  animation: sine-wave 2s ease-in-out infinite,
    shake-intense 2s ease-in-out infinite;
}

@keyframes heartBreak {
  0% {
    transform: scale(1);
    color: #e50024;
  }
  50% {
    transform: scale(1.2);
    color: #e50024;
  }
  100% {
    transform: scale(0.8);
    color: #808080;
  }
}

@keyframes fadeInOut {
  0% {
    opacity: 0;
    transform: translate(-50%, -50%) scale(0.8);
  }
  15% {
    opacity: 1;
    transform: translate(-50%, -50%) scale(1.1);
  }
  30% {
    transform: translate(-50%, -50%) scale(1);
  }
  70% {
    opacity: 1;
  }
  100% {
    opacity: 0;
    transform: translate(-50%, -50%) scale(0.8);
  }
}

.heart[style*="color: #999"] {
  color: #333;
  text-shadow: none;
  opacity: 0.2;
  transform: scale(0.92);
  animation: none;
}

.heart:hover {
  animation-play-state: paused;
  transform: scale(1.15);
  text-shadow: -1px -1px 0 rgba(255, 255, 255, 0.3),
    3px 3px 4px rgba(180, 0, 0, 0.6);
}

.guess-button {
  width: 90%;
  background: linear-gradient(to bottom, #e50024, #cc0000);
  color: white;
  font-family: "Jockey One", sans-serif;
  font-size: 1.1em;
  font-weight: 500;
  letter-spacing: 1px;
  padding: 10px;
  border: 2px solid rgba(255, 255, 255, 0.9);
  border-radius: 6px;
  cursor: pointer;
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.2),
    inset 0 1px 3px rgba(255, 255, 255, 0.3);
  transition: all 0.2s ease;
  text-shadow: 1px 1px 0 rgba(0, 0, 0, 0.2);
}

.guess-button:hover {
  background: linear-gradient(to bottom, #ff0029, #e50024);
  transform: translateY(-2px);
  box-shadow: 0 4px 8px rgba(0, 0, 0, 0.3),
    inset 0 1px 3px rgba(255, 255, 255, 0.3);
}

.guess-button:active {
  transform: translateY(1px);
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.2), inset 0 1px 3px rgba(0, 0, 0, 0.2);
}

.card:hover {
  transform: translateY(-5px) scale(1.02);
  z-index: 5;
  cursor: pointer;
}

.card:hover .card-inner {
  box-shadow: 0 8px 16px rgba(0, 0, 0, 0.3),
    inset 0 2px 8px rgba(255, 255, 255, 0.4);
}

.buttonHolder {
  position: relative;
  margin: 5px;
}

.popup-menu {
  display: block;
  position: absolute;
  bottom: 120%;
  left: 50%;
  transform: translateX(-50%);
  background: linear-gradient(to bottom, #00d4ff, #00b8e6);
  border: 4px solid white;
  border-radius: 8px;
  padding: 12px;
  box-shadow: 0 8px 20px rgba(0, 0, 0, 0.3),
    inset 0 2px 8px rgba(255, 255, 255, 0.4);
  z-index: 1000;
  min-width: 180px;
  opacity: 0;
  visibility: hidden;
  transition: all 0.5s cubic-bezier(0.34, 1.56, 0.64, 1);
}

.popup-menu.active {
  opacity: 1;
  visibility: visible;
  transform: translateX(-50%);
}

.popup-content {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 10px;
  background: white;
  border-radius: 4px;
  padding: 12px;
  box-shadow: inset 0 2px 4px rgba(0, 0, 0, 0.1);
  width: 100%;
}

.popup-content .filter-btn[data-attribute="hairColor"],
.popup-content .filter-btn[data-attribute="hairLength"] {
  width: 100%;
  text-align: center;
  margin: 0 auto;
}

/* From Microsoft Copilot */
.popup-menu.active .popup-content .filter-btn:nth-of-type(1) {
  animation-delay: 0.1s;
}
.popup-menu.active .popup-content .filter-btn:nth-of-type(2) {
  animation-delay: 0.15s;
}

.popup-menu.active .eye-circle:nth-child(1) {
  animation-delay: 0.15s;
}
.popup-menu.active .eye-circle:nth-child(2) {
  animation-delay: 0.25s;
}
.popup-menu.active .eye-circle:nth-child(3) {
  animation-delay: 0.35s;
}

/* From Microsoft Copilot */
.hair-color-popup .hair-circle:nth-child(1) {
  animation-delay: 0.2s;
}
.hair-color-popup .hair-circle:nth-child(2) {
  animation-delay: 0.3s;
}
.hair-color-popup .hair-circle:nth-child(3) {
  animation-delay: 0.4s;
}
.hair-color-popup .hair-circle:nth-child(4) {
  animation-delay: 0.5s;
}
.hair-color-popup .hair-circle:nth-child(5) {
  animation-delay: 0.6s;
}
.hair-color-popup .hair-circle:nth-child(6) {
  animation-delay: 0.7s;
}

.filter-btn,
.eye-circle,
.hair-circle {
  opacity: 0;
  transform: scale(0.95);
}

/* From Microsoft Copilot */
.popup-menu.active .filter-btn,
.popup-menu.active .eye-circle,
.hair-color-popup[style*="display: flex"] .hair-circle {
  animation: elementAppear 0.5s cubic-bezier(0.34, 1.56, 0.64, 1) forwards;
}

.filter-btn:hover,
.eye-circle:hover,
.hair-circle:hover {
  transform: scale(1.1);
  box-shadow: 0 4px 8px rgba(0, 0, 0, 0.3);
  transition: all 0.3s cubic-bezier(0.34, 1.56, 0.64, 1);
}

.filter-btn:active,
.eye-circle:active,
.hair-circle:active {
  transform: scale(0.95);
  transition: all 0.1s ease-in-out;
}

.popup-content h3 {
  margin: 0 0 8px 0;
  text-align: center;
  color: #cc0000;
  font-size: 1.4em;
  font-weight: 500;
  letter-spacing: 1px;
  text-shadow: 2px 2px 0 rgba(255, 255, 255, 1), -1px -1px 0 rgba(0, 0, 0, 0.1);
}

.filter-btn {
  padding: 10px 15px;
  border: 2px solid rgba(255, 255, 255, 0.9);
  border-radius: 6px;
  background: linear-gradient(to bottom, #e50024, #cc0000);
  color: white;
  cursor: pointer;
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  font-size: 1.1em;
  font-weight: 500;
  letter-spacing: 0.5px;
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.2),
    inset 0 1px 3px rgba(255, 255, 255, 0.3);
  text-shadow: 1px 1px 0 rgba(0, 0, 0, 0.2);
}

.filter-btn:hover {
  background: linear-gradient(to bottom, #ff0029, #e50024);
  transform: translateY(-2px);
  box-shadow: 0 4px 8px rgba(0, 0, 0, 0.3),
    inset 0 1px 3px rgba(255, 255, 255, 0.3);
}

.filter-btn:active {
  transform: translateY(1px);
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.2), inset 0 1px 3px rgba(0, 0, 0, 0.2);
}

/* From Microsoft Copilot */
.popup-menu::before,
.popup-menu::after {
  content: "";
  position: absolute;
  bottom: -12px;
  left: 50%;
  transform: translateX(-50%);
}

/* From Microsoft Copilot */
.popup-menu::before {
  border-left: 14px solid transparent;
  border-right: 14px solid transparent;
  border-top: 14px solid white;
  z-index: 1;
  filter: drop-shadow(0 4px 4px rgba(0, 0, 0, 0.2));
}

.popup-menu::after {
  bottom: -8px;
  border-left: 10px solid transparent;
  border-right: 10px solid transparent;
  border-top: 10px solid #00b8e6;
  z-index: 2;
}

.eye-color-popup {
  display: flex;
  justify-content: center;
  gap: 8px;
  padding: 0 8px 8px 8px;
}

.eye-circle {
  width: 30px;
  height: 30px;
  border-radius: 50%;
  cursor: pointer;
  border: 2px solid white;
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.2);
  opacity: 0;
  transform: scale(0.5);
}

.popup-menu.active .eye-circle {
  animation: circleAppear 0.5s cubic-bezier(0.34, 1.56, 0.64, 1) forwards;
}

.popup-menu.active .eye-circle:nth-child(1) {
  animation-delay: 0.05s;
}
.popup-menu.active .eye-circle:nth-child(2) {
  animation-delay: 0.1s;
}
.popup-menu.active .eye-circle:nth-child(3) {
  animation-delay: 0.15s;
}

.eye-circle:hover {
  transform: scale(1.1);
  box-shadow: 0 4px 8px rgba(0, 0, 0, 0.3);
  transition: all 0.2s cubic-bezier(0.34, 1.56, 0.64, 1);
}

.eye-circle:active {
  transform: scale(0.95);
  transition: all 0.1s ease-in-out;
}

.eye-circle.brown {
  background: linear-gradient(135deg, #8b4513, #654321);
}

.eye-circle.blue {
  background: linear-gradient(135deg, #4682b4, #1e90ff);
}

.eye-circle.green {
  background: linear-gradient(135deg, #228b22, #32cd32);
}

.eye-circle.selected {
  border: 2px solid #ff0029;
  box-shadow: 0 0 0 2px rgba(255, 0, 41, 0.3);
}

.hair-color-popup {
  display: flex;
  justify-content: center;
  flex-wrap: wrap;
  gap: 8px;
  padding: 8px;
  width: 100%;
}

.hair-color-popup .hair-circle {
  margin: 0;
}

@keyframes circleAppear {
  0% {
    opacity: 0;
    transform: scale(0.8);
  }
  70% {
    transform: scale(1.1);
  }
  100% {
    opacity: 1;
    transform: scale(1);
  }
}

.hair-circle {
  width: 30px;
  height: 30px;
  border-radius: 50%;
  cursor: pointer;
  border: 2px solid white;
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.2);
  opacity: 0;
  transform: scale(0.5);
}

/* From Microsoft Copilot */
.hair-color-popup .hair-circle {
  animation: circleAppear 0.5s cubic-bezier(0.34, 1.56, 0.64, 1) forwards;
}

.hair-color-popup .hair-circle:nth-child(1) {
  animation-delay: 0.05s;
}
.hair-color-popup .hair-circle:nth-child(2) {
  animation-delay: 0.1s;
}
.hair-color-popup .hair-circle:nth-child(3) {
  animation-delay: 0.15s;
}
.hair-color-popup .hair-circle:nth-child(4) {
  animation-delay: 0.2s;
}
.hair-color-popup .hair-circle:nth-child(5) {
  animation-delay: 0.25s;
}
.hair-color-popup .hair-circle:nth-child(6) {
  animation-delay: 0.3s;
}

.hair-circle:hover {
  transform: scale(1.1);
  box-shadow: 0 4px 8px rgba(0, 0, 0, 0.3);
  transition: all 0.2s cubic-bezier(0.34, 1.56, 0.64, 1);
}

.hair-circle:active {
  transform: scale(0.95);
  transition: all 0.1s ease-in-out;
}

.hair-circle.black {
  background: linear-gradient(135deg, #000000, #626262);
}

.hair-circle.blonde {
  background: linear-gradient(135deg, #ffd700, #daa520);
}

.hair-circle.brown {
  background: linear-gradient(135deg, #68320b, #b86036);
}

.hair-circle.red {
  background: linear-gradient(135deg, #8b0000, #cd5c5c);
}

.hair-circle.blue {
  background: linear-gradient(135deg, #007ecc, #003399);
}

.hair-circle.green {
  background: linear-gradient(135deg, #68cf68, #9bff37);
}

.hair-circle.selected {
  display: none;
}

@keyframes elementAppear {
  0% {
    opacity: 0;
    transform: scale(0.95);
  }
  70% {
    transform: scale(1.02);
  }
  100% {
    opacity: 1;
    transform: scale(1);
  }
}

.error-popup {
  display: none;
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(0, 0, 0, 0.85);
  z-index: 1000;
  justify-content: center;
  align-items: center;
}

.error-popup .fail-content {
  background: linear-gradient(135deg, #ffffff, #f5f5f5);
  border: 5px solid #ffffff;
  padding: 35px;
  border-radius: 15px;
  text-align: center;
  width: 420px;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.3),
    inset 0 2px 5px rgba(255, 255, 255, 0.5);
  animation: popup-appear 0.4s cubic-bezier(0.34, 1.56, 0.64, 1);
  position: relative;
  overflow: hidden;
}

.error-popup .fail-content::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 5px;
  background: linear-gradient(to right, #2ecc71, #27ae60);
}

.error-popup h2 {
  color: #2ecc71;
  font-size: 52px;
  margin-bottom: 30px;
  text-shadow: 2px 2px 0 rgba(0, 0, 0, 0.2);
  font-family: "Jockey One", sans-serif;
  letter-spacing: 2px;
  animation: gentle-appear 0.6s cubic-bezier(0.34, 1.56, 0.64, 1) forwards;
}

.error-popup p {
  color: #035094;
  font-size: 22px;
  margin-bottom: 20px;
  font-family: "Poppins", sans-serif;
  line-height: 1.5;
  font-weight: 500;
  opacity: 0;
  animation: text-appear 0.5s cubic-bezier(0.34, 1.56, 0.64, 1) forwards;
  animation-delay: 0.3s;
}

.error-popup p:first-of-type {
  font-size: 32px;
  font-weight: 600;
  color: #035094;
  animation: gentle-appear 0.6s cubic-bezier(0.34, 1.56, 0.64, 1) forwards;
  animation-delay: 0.2s;
}

.error-popup .card-reveal {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: calc(100% - 80px);
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  opacity: 0;
  transition: opacity 0.5s ease;
  padding: 35px;
}

.error-popup .card-reveal.visible {
  opacity: 1;
}

.error-popup .reveal-text {
  color: #035094;
  font-size: 24px;
  font-family: "Poppins", sans-serif;
  margin-bottom: 20px;
  opacity: 0;
  transform: translateY(20px);
  transition: all 0.5s ease;
}

.error-popup .reveal-text.visible {
  opacity: 1;
  transform: translateY(0);
}

.error-popup .revealed-card {
  background: linear-gradient(135deg, #ffffff, #f5f5f5);
  padding: 20px;
  border-radius: 12px;
  box-shadow: 0 4px 15px rgba(46, 204, 113, 0.1);
  text-align: center;
  opacity: 0;
  transform: translateY(20px);
  transition: all 0.5s ease;
}

.error-popup .revealed-card.visible {
  opacity: 1;
  transform: translateY(0);
}

.error-popup .revealed-card img {
  width: 150px;
  height: 150px;
  object-fit: cover;
  border-radius: 8px;
  margin-bottom: 15px;
  border: 2px solid #2ecc71;
}

.error-popup .revealed-card p {
  color: #035094;
  font-size: 24px;
  font-weight: 600;
  margin: 0;
}

.error-popup #restart {
  width: 200px;
  background: linear-gradient(to bottom, #2ecc71, #27ae60);
  color: white;
  font-family: "Jockey One", sans-serif;
  font-size: 1.5em;
  font-weight: 500;
  letter-spacing: 1px;
  padding: 12px 25px;
  border: 2px solid rgba(255, 255, 255, 0.9);
  border-radius: 8px;
  cursor: pointer;
  box-shadow: 0 4px 8px rgba(0, 0, 0, 0.2),
    inset 0 1px 3px rgba(255, 255, 255, 0.3);
  transition: all 0.3s ease;
  text-shadow: 1px 1px 0 rgba(0, 0, 0, 0.2);
  position: relative;
  z-index: 2;
  margin-top: auto;
}

.error-popup #restart:hover {
  background: linear-gradient(to bottom, #27ae60, #219a52);
  transform: translateY(-2px);
  box-shadow: 0 6px 12px rgba(0, 0, 0, 0.3),
    inset 0 1px 3px rgba(255, 255, 255, 0.3);
}

.error-popup #restart:active {
  transform: translateY(1px);
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.2), inset 0 1px 3px rgba(0, 0, 0, 0.2);
}

@keyframes gentle-appear {
  0% {
    transform: scale(0.95);
    opacity: 0;
  }
  100% {
    transform: scale(1);
    opacity: 1;
  }
}

.fail-popup {
  display: none;
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(0, 0, 0, 0.85);
  z-index: 1000;
  justify-content: center;
  align-items: center;
}

.fail-popup .fail-content {
  background: linear-gradient(135deg, #ffffff, #f5f5f5);
  border: 5px solid #ffffff;
  padding: 35px;
  border-radius: 15px;
  text-align: center;
  width: 420px;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.3),
    inset 0 2px 5px rgba(255, 255, 255, 0.5);
  animation: popup-appear 0.4s cubic-bezier(0.34, 1.56, 0.64, 1);
  position: relative;
  overflow: hidden;
}

.fail-popup .fail-content::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 5px;
  background: linear-gradient(to right, #e50024, #cc0000);
}

@keyframes popup-appear {
  0% {
    transform: scale(0.8) translateY(20px);
    opacity: 0;
  }
  100% {
    transform: scale(1) translateY(0);
    opacity: 1;
  }
}

.fail-popup h2 {
  color: #cc0000;
  font-size: 52px;
  margin-bottom: 30px;
  text-shadow: 2px 2px 0 rgba(0, 0, 0, 0.2);
  font-family: "Jockey One", sans-serif;
  letter-spacing: 2px;
}

.fail-popup p {
  color: #035094;
  font-size: 22px;
  margin-bottom: 20px;
  font-family: "Poppins", sans-serif;
  line-height: 1.5;
  font-weight: 500;
  opacity: 0;
  animation: text-appear 0.5s cubic-bezier(0.34, 1.56, 0.64, 1) forwards;
  animation-delay: 0.3s;
}

.fail-popup p:first-of-type {
  font-size: 32px;
  font-weight: 600;
  color: #035094;
  animation: oh-no-appear 0.6s cubic-bezier(0.34, 1.56, 0.64, 1) forwards;
  animation-delay: 0.2s;
}

@keyframes oh-no-appear {
  0% {
    transform: scale(0.5) rotate(-10deg);
    opacity: 0;
  }
  50% {
    transform: scale(1.2) rotate(5deg);
  }
  75% {
    transform: scale(0.9) rotate(-2deg);
  }
  100% {
    transform: scale(1) rotate(0);
    opacity: 1;
  }
}

@keyframes text-appear {
  0% {
    transform: translateY(20px);
    opacity: 0;
  }
  100% {
    transform: translateY(0);
    opacity: 1;
  }
}

.fail-popup p.encouragement {
  color: #035094;
  font-size: 18px;
  padding: 12px 20px;
  background: linear-gradient(
    135deg,
    rgba(3, 80, 148, 0.1),
    rgba(3, 80, 148, 0.05)
  );
  border-radius: 8px;
  margin-bottom: 30px;
  transition: all 0.5s ease;
  opacity: 0;
  transform: translateY(20px);
}

.fail-popup p.encouragement:hover {
  background: linear-gradient(
    135deg,
    rgba(3, 80, 148, 0.12),
    rgba(3, 80, 148, 0.06)
  );
  transform: translateY(-2px);
}

.encouragementReveal span {
  transition: 1s;
  font-family: "Poppins", sans-serif;
}
.encouragementReveal.hide span {
  opacity: 0;
}

.nameReveal {
  font-weight: 600;
  font-size: 1.5rem;
  color: #cc0000;
}

.timeReveal {
  font-weight: 600;
  font-size: 1.5rem;
  color: #2ecc71;
}

#restart {
  width: 200px;
  background: linear-gradient(to bottom, #e50024, #cc0000);
  color: white;
  font-family: "Jockey One", sans-serif;
  font-size: 1.5em;
  font-weight: 500;
  letter-spacing: 1px;
  padding: 12px 25px;
  border: 2px solid rgba(255, 255, 255, 0.9);
  border-radius: 8px;
  cursor: pointer;
  box-shadow: 0 4px 8px rgba(0, 0, 0, 0.2),
    inset 0 1px 3px rgba(255, 255, 255, 0.3);
  transition: all 0.3s ease;
  text-shadow: 1px 1px 0 rgba(0, 0, 0, 0.2);
  position: relative;
  z-index: 2;
  margin-top: auto;
}

#restart:hover {
  background: linear-gradient(to bottom, #ff0029, #e50024);
  transform: translateY(-2px);
  box-shadow: 0 6px 12px rgba(0, 0, 0, 0.3),
    inset 0 1px 3px rgba(255, 255, 255, 0.3);
}

#restart:active {
  transform: translateY(1px);
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.2), inset 0 1px 3px rgba(0, 0, 0, 0.2);
}

.hair-length-popup {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
  padding: 8px;
  width: 100%;
}

.hair-length-popup .filter-btn {
  width: 80%;
  text-align: center;
}

.encouragement-container {
  margin-bottom: 35px;
  transition: all 0.5s ease;
}

.fail-content {
  background: linear-gradient(135deg, #ffffff, #f5f5f5);
  border: 5px solid #ffffff;
  padding: 35px;
  border-radius: 15px;
  text-align: center;
  width: 420px;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.3),
    inset 0 2px 5px rgba(255, 255, 255, 0.5);
  animation: popup-appear 0.4s cubic-bezier(0.34, 1.56, 0.64, 1);
  position: relative;
}

.initial-content {
  opacity: 1;
  visibility: visible;
  transition: opacity 0.5s ease, visibility 0.5s ease;
  margin-bottom: 30px;
}

.initial-content.fade-out {
  opacity: 0;
  visibility: hidden;
}

.card-reveal {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: calc(100% - 80px); /* Leave space for button */
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  opacity: 0;
  transition: opacity 0.5s ease;
  padding: 35px;
}

.card-reveal.visible {
  opacity: 1;
}

.reveal-text {
  color: #035094;
  font-size: 24px;
  font-family: "Poppins", sans-serif;
  margin-bottom: 20px;
  opacity: 0;
  transform: translateY(20px);
  transition: all 0.5s ease;
}

.reveal-text.visible {
  opacity: 1;
  transform: translateY(0);
}

.revealed-card {
  background: linear-gradient(135deg, #ffffff, #f5f5f5);
  padding: 20px;
  border-radius: 12px;
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
  text-align: center;
  opacity: 0;
  transform: translateY(20px);
  transition: all 0.5s ease;
}

.revealed-card.visible {
  opacity: 1;
  transform: translateY(0);
}

.revealed-card img {
  width: 150px;
  height: 150px;
  object-fit: cover;
  border-radius: 8px;
  margin-bottom: 15px;
  border: 2px solid #035094;
}

.revealed-card p {
  color: #035094;
  font-size: 24px;
  font-weight: 600;
  margin: 0;
}

.screen-visible {
  opacity: 1;
  visibility: visible;
}

.screen-hidden {
  opacity: 0;
  visibility: hidden;
}

@keyframes textPulse {
  0% {
    transform: translate(-50%, -50%) scale(1);
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.1);
  }
  50% {
    transform: translate(-50%, -50%) scale(1.05);
    box-shadow: 0 12px 40px rgba(0, 0, 0, 0.15);
  }
  100% {
    transform: translate(-50%, -50%) scale(1);
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.1);
  }
}

@keyframes textGlow {
  0% {
    text-shadow: 2px 2px 0 #fff, -2px -2px 0 #fff, 2px -2px 0 #fff,
      -2px 2px 0 #fff, 0 0 20px rgba(229, 0, 36, 0.5);
  }
  50% {
    text-shadow: 2px 2px 0 #fff, -2px -2px 0 #fff, 2px -2px 0 #fff,
      -2px 2px 0 #fff, 0 0 30px rgba(229, 0, 36, 0.8);
  }
  100% {
    text-shadow: 2px 2px 0 #fff, -2px -2px 0 #fff, 2px -2px 0 #fff,
      -2px 2px 0 #fff, 0 0 20px rgba(229, 0, 36, 0.5);
  }
}

@keyframes gentleFloat {
  0%,
  100% {
    transform: translate(-50%, -50%) scale(1);
  }
  50% {
    transform: translate(-50%, -52%) scale(1);
  }
}

/* Add new styles for inspection effect */
.card.inspecting {
  z-index: 1000;
  transform: translateY(-20px) scale(1.1);
}

.card.inspecting .card-inner {
  box-shadow: 0 8px 32px rgba(0, 0, 0, 0.4),
    inset 0 2px 8px rgba(255, 255, 255, 0.6);
}

.card.inspecting .character-image {
  transform: scale(1.5);
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.2);
}

/* Add a subtle glow effect */
.card.inspecting::after {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: radial-gradient(
    circle at center,
    rgba(255, 255, 255, 0.2) 0%,
    transparent 70%
  );
  border-radius: 4px;
  pointer-events: none;
}

.card.selected .card-inner {
  outline: 2.5px solid #e50024;
  outline-offset: 0;
}

.card.selected:hover .card-inner {
  outline: 2.5px solid #e50024;
  outline-offset: 0;
}

.card.selected::after {
  content: "✓";
  position: absolute;
  top: -10px;
  right: -10px;
  background: #e50024;
  color: white;
  width: 24px;
  height: 24px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 16px;
  z-index: 1001;
}

.card[style*="grayscale"] {
  cursor: not-allowed;
}

.card[style*="grayscale"]:hover {
  cursor: not-allowed;
}

.success-popup {
  display: none;
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(0, 0, 0, 0.85);
  z-index: 1000;
  justify-content: center;
  align-items: center;
}

.success-popup .success-content {
  background: linear-gradient(135deg, #ffffff, #f5f5f5);
  border: 5px solid #ffffff;
  padding: 35px;
  border-radius: 15px;
  text-align: center;
  width: 420px;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.3),
    inset 0 2px 5px rgba(255, 255, 255, 0.5);
  animation: popup-appear 0.4s cubic-bezier(0.34, 1.56, 0.64, 1);
  position: relative;
  overflow: hidden;
}

.success-popup .success-content::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 5px;
  background: linear-gradient(to right, #2ecc71, #27ae60);
}

.success-popup h2 {
  color: #2ecc71;
  font-size: 52px;
  margin-bottom: 30px;
  text-shadow: 2px 2px 0 rgba(0, 0, 0, 0.2);
  font-family: "Jockey One", sans-serif;
  letter-spacing: 2px;
  animation: gentle-appear 0.6s cubic-bezier(0.34, 1.56, 0.64, 1) forwards;
}

.success-popup p {
  color: #035094;
  font-size: 22px;
  margin-bottom: 20px;
  font-family: "Poppins", sans-serif;
  line-height: 1.5;
  font-weight: 500;
  opacity: 0;
  animation: text-appear 0.5s cubic-bezier(0.34, 1.56, 0.64, 1) forwards;
  animation-delay: 0.3s;
}

.success-popup p:first-of-type {
  font-size: 32px;
  font-weight: 600;
  color: #035094;
  animation: gentle-appear 0.6s cubic-bezier(0.34, 1.56, 0.64, 1) forwards;
  animation-delay: 0.2s;
}

.success-popup .encouragement {
  color: #035094;
  font-size: 18px;
  padding: 12px 20px;
  background: linear-gradient(
    135deg,
    rgba(3, 80, 148, 0.1),
    rgba(3, 80, 148, 0.05)
  );
  border-radius: 8px;
  margin-bottom: 30px;
  transition: all 0.5s ease;
  opacity: 0;
  transform: translateY(20px);
}

.success-popup .encouragement:hover {
  background: linear-gradient(
    135deg,
    rgba(3, 80, 148, 0.12),
    rgba(3, 80, 148, 0.06)
  );
  transform: translateY(-2px);
}

.success-popup #restart {
  width: 200px;
  background: linear-gradient(to bottom, #2ecc71, #27ae60);
  color: white;
  font-family: "Jockey One", sans-serif;
  font-size: 1.5em;
  font-weight: 500;
  letter-spacing: 1px;
  padding: 12px 25px;
  border: 2px solid rgba(255, 255, 255, 0.9);
  border-radius: 8px;
  cursor: pointer;
  box-shadow: 0 4px 8px rgba(0, 0, 0, 0.2),
    inset 0 1px 3px rgba(255, 255, 255, 0.3);
  transition: all 0.3s ease;
  text-shadow: 1px 1px 0 rgba(0, 0, 0, 0.2);
  position: relative;
  z-index: 2;
  margin-top: auto;
}

.success-popup #restart:hover {
  background: linear-gradient(to bottom, #27ae60, #219a52);
  transform: translateY(-2px);
  box-shadow: 0 6px 12px rgba(0, 0, 0, 0.3),
    inset 0 1px 3px rgba(255, 255, 255, 0.3);
}

.success-popup #restart:active {
  transform: scale(0.95);
}

.menu-link {
  display: block;
  text-align: center;
  margin-top: 15px;
  color: #666;
  text-decoration: none;
  font-family: "Poppins", sans-serif;
  font-size: 14px;
  cursor: pointer;
  transition: all 0.2s ease;
}

.menu-link:hover {
  color: #333;
  text-decoration: underline;
}

.fail-popup .menu-link {
  color: #888;
}

.fail-popup .menu-link:hover {
  color: #555;
}

.mute-button {
  position: fixed;
  top: 20px;
  left: 20px;
  width: 40px;
  height: 40px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.1);
  border: 2px solid rgba(255, 255, 255, 0.3);
  color: rgba(255, 255, 255, 0.8);
  font-size: 24px;
  font-family: "Poppins", sans-serif;
  font-weight: bold;
  cursor: pointer;
  transition: all 0.3s ease;
  z-index: 1000;
  display: flex;
  justify-content: center;
  align-items: center;
}

.mute-button:hover {
  background: rgba(255, 255, 255, 0.2);
  color: rgba(255, 255, 255, 0.9);
  transform: scale(1.1);
}

.mute-button.muted {
  opacity: 0.7;
}

.how-to-play-button {
  position: fixed;
  top: 20px;
  left: 70px;
  width: 40px;
  height: 40px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.1);
  border: 2px solid rgba(255, 255, 255, 0.3);
  color: rgba(255, 255, 255, 0.8);
  font-size: 24px;
  font-family: "Poppins", sans-serif;
  font-weight: bold;
  cursor: pointer;
  transition: all 0.3s ease;
  z-index: 1000;
  display: flex;
  justify-content: center;
  align-items: center;
}

.how-to-play-button:hover {
  background: rgba(255, 255, 255, 0.2);
  color: rgba(255, 255, 255, 0.9);
  transform: scale(1.1);
}

.how-to-play-popup {
  display: none;
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(0, 0, 0, 0.85);
  z-index: 1000;
  justify-content: center;
  align-items: center;
}

.how-to-play-content {
  background: linear-gradient(135deg, #ffffff, #f5f5f5);
  padding: 40px;
  border-radius: 12px;
  text-align: center;
  width: 80%;
  max-width: 600px;
  margin: 0 auto;
  position: relative;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.3),
    inset 0 2px 8px rgba(255, 255, 255, 0.4);
  animation: popup-appear 0.4s cubic-bezier(0.34, 1.56, 0.64, 1);
  border: 4px solid rgba(255, 255, 255, 0.9);
  overflow: hidden;
}

.how-to-play-content::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 4px;
  background: linear-gradient(to right, #e50024, #cc0000);
}

.how-to-play-content h3 {
  color: #004a94;
  font-size: 36px;
  margin-bottom: 25px;
  text-shadow: 2px 2px 0 rgba(0, 0, 0, 0.2);
  font-family: "Jockey One", sans-serif;
  letter-spacing: 1px;
  animation: gentle-appear 0.6s cubic-bezier(0.34, 1.56, 0.64, 1) forwards;
}

.how-to-play-content ul {
  list-style: none;
  padding: 0;
  margin: 0;
  text-align: center;
  line-height: 1.6;
}

.how-to-play-content li {
  color: #035094;
  font-size: 18px;
  margin: 25px 0;
  font-family: "Poppins", sans-serif;
  text-shadow: 1px 1px 0 rgba(0, 0, 0, 0.2);
  letter-spacing: 0.5px;
  line-height: 1.4;
  opacity: 0;
  transform: translateY(20px);
  animation: text-appear 0.5s cubic-bezier(0.34, 1.56, 0.64, 1) forwards;
}

.how-to-play-content li:nth-child(1) {
  animation-delay: 0.2s;
}
.how-to-play-content li:nth-child(2) {
  animation-delay: 0.3s;
}
.how-to-play-content li:nth-child(3) {
  animation-delay: 0.4s;
}
.how-to-play-content li:nth-child(4) {
  animation-delay: 0.5s;
}
.how-to-play-content li:nth-child(5) {
  animation-delay: 0.6s;
}

.close-how-to-play {
  position: absolute;
  top: 5px;
  right: 15px;
  background: none;
  border: none;
  color: #035094;
  font-size: 50px;
  cursor: pointer;
  transition: all 0.3s ease;
  text-shadow: 1px 1px 0 rgba(0, 0, 0, 0.2);
  padding: 0;
  line-height: 1;
  opacity: 0;
  transform: scale(0.8);
  animation: gentle-appear 0.6s cubic-bezier(0.34, 1.56, 0.64, 1) forwards;
  animation-delay: 0.6s;
}

.close-how-to-play:hover {
  transform: scale(1.1);
  color: #e50024;
}

.credits-button {
  position: fixed;
  bottom: 20px;
  right: 20px;
  width: 30px;
  height: 30px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.1);
  border: 1px solid rgba(255, 255, 255, 0.2);
  color: rgba(255, 255, 255, 0.5);
  font-family: "Poppins", sans-serif;
  font-size: 18px;
  cursor: pointer;
  transition: all 0.3s ease;
  z-index: 10;
}

.credits-button:hover {
  background: rgba(255, 255, 255, 0.2);
  color: rgba(255, 255, 255, 0.8);
  transform: scale(1.1);
}

.credits-popup {
  display: none;
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(0, 0, 0, 0.85);
  z-index: 1000;
  justify-content: center;
  align-items: center;
}

.credits-content {
  background: linear-gradient(135deg, #ffffff, #f5f5f5);
  padding: 40px;
  border-radius: 12px;
  text-align: center;
  width: 320px;
  position: relative;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.3),
    inset 0 2px 8px rgba(255, 255, 255, 0.4);
  animation: popup-appear 0.4s cubic-bezier(0.34, 1.56, 0.64, 1);
  border: 4px solid rgba(255, 255, 255, 0.9);
  overflow: hidden;
}

.credits-content::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 4px;
  background: linear-gradient(to right, #e50024, #cc0000);
}

.credits-content h3 {
  color: #004a94;
  font-size: 36px;
  margin-bottom: 25px;
  text-shadow: 2px 2px 0 rgba(0, 0, 0, 0.2);
  font-family: "Jockey One", sans-serif;
  letter-spacing: 1px;
  animation: gentle-appear 0.6s cubic-bezier(0.34, 1.56, 0.64, 1) forwards;
}

.credits-content ul {
  list-style: none;
  padding: 0;
  margin: 0;
}

.credits-content li {
  color: #035094;
  font-size: 28px;
  margin: 15px 0;
  font-family: "Poppins", sans-serif;
  text-shadow: 1px 1px 0 rgba(0, 0, 0, 0.2);
  letter-spacing: 0.5px;
  cursor: pointer;
  transition: all 0.3s ease;
  opacity: 0;
  transform: translateY(20px);
  animation: text-appear 0.5s cubic-bezier(0.34, 1.56, 0.64, 1) forwards;
}

.credits-content li:nth-child(1) {
  animation-delay: 0.2s;
}
.credits-content li:nth-child(2) {
  animation-delay: 0.3s;
}
.credits-content li:nth-child(3) {
  animation-delay: 0.4s;
}

.credits-content li:hover {
  transform: scale(1.1);
  color: #e50024;
  font-weight: 600;
}

.credits-content .class-year {
  color: rgba(3, 80, 148, 0.5);
  font-size: 14px;
  font-family: "Poppins", sans-serif;
  font-style: italic;
  margin-top: 25px;
  letter-spacing: 1px;
  text-shadow: 1px 1px 0 rgba(0, 0, 0, 0.1);
  opacity: 0;
  transform: translateY(20px);
  animation: text-appear 0.5s cubic-bezier(0.34, 1.56, 0.64, 1) forwards;
  animation-delay: 0.5s;
}

.close-credits {
  position: absolute;
  top: 5px;
  right: 15px;
  background: none;
  border: none;
  color: #035094;
  font-size: 50px;
  cursor: pointer;
  transition: all 0.3s ease;
  text-shadow: 1px 1px 0 rgba(0, 0, 0, 0.2);
  padding: 0;
  line-height: 1;
  opacity: 0;
  transform: scale(0.8);
  animation: gentle-appear 0.6s cubic-bezier(0.34, 1.56, 0.64, 1) forwards;
  animation-delay: 0.6s;
}

.close-credits:hover {
  transform: scale(1.1);
  color: #e50024;
}
