.mood-selector_quick-select-option svg {
  width: 30px;
  height: 30px;
  transition: transform 0.3s ease, filter 0.3s ease;
}

.mood-selector_quick-select-option:hover svg {
  transform: scale(1.15);
  filter: drop-shadow(0 1px 2px rgba(102, 126, 234, 0.4));
}

.mood-scale_interactive-area {
  cursor: pointer;
  border-radius: 20px;
  transition: all 0.3s ease;
}

.mood-scale_content-wrapper {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
}

.mood-scale_face-wrapper {
  flex-shrink: 0;
  flex-grow: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: flex-start; /* Align to top to prevent centering shift */
  order: 2;
}

.mood-scale_face-container {
  cursor: pointer;
  user-select: none;
  transition: transform 0.3s ease;
}

.mood-scale_face-container:hover svg {
  animation: smileyPulse 1.5s ease-in-out infinite;
}

@keyframes smileyPulse {
  0%, 100% {
    transform: scale(1);
  }
  50% {
    transform: scale(1.05);
  }
}

/* Enhanced smiley with glow effect on selection */
.mood-scale_face {
  filter: drop-shadow(0 1px 3px rgba(0, 0, 0, 0.15));
  transition: filter 0.3s ease;
}

.mood-scale_face-container:hover .mood-scale_face {
  filter: drop-shadow(0 2px 4px rgba(102, 126, 234, 0.4));
}

.mood-scale_side-info {
  width: 100%;
  padding: 0;
  text-align: center;
}

.mood-scale_side-info--left {
  /* Hide left side info - not used in new layout */
  display: none;
}

.mood-scale_side-info--right {
  /* Hide right side info - not used in new layout */
  display: none;
}

.mood-scale_side-info--top {
  order: 1;
  margin-bottom: 8px;
}

.mood-scale_side-info--bottom {
  order: 3;
  margin-top: 8px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.mood-scale_mood-label {
  font-size: 22px;
  font-weight: 700;
  color: #1a202c;
  line-height: 1.2;
  margin-bottom: 4px;
  text-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
  transition: transform 0.3s ease, text-shadow 0.3s ease;
}

.mood-scale_mood-description {
  font-size: 14px;
  font-weight: 400;
  color: #555;
  margin-bottom: 8px;
  line-height: 1.4;
}

.mood-scale_mood-score {
  font-size: 16px;
  font-weight: 600;
  color: #666;
}

.mood-scale_display-container {
  padding: 16px 0;
  border-radius: 20px 20px 0 0;
  position: relative;
  overflow: hidden;
  transition: background 0.4s ease;
}

/* Animated background gradient effect */
.mood-scale_display-container::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: radial-gradient(circle at 30% 40%, rgba(255, 255, 255, 0.15) 0%, transparent 60%),
              radial-gradient(circle at 70% 60%, rgba(255, 255, 255, 0.1) 0%, transparent 50%);
  animation: floatBackgroundGradient 8s ease-in-out infinite;
  pointer-events: none;
  z-index: 0;
}

.mood-scale_display-container > * {
  position: relative;
  z-index: 1;
}

@keyframes floatBackgroundGradient {
  0%, 100% {
    transform: translate(0, 0) scale(1);
    opacity: 0.7;
  }
  33% {
    transform: translate(15px, -10px) scale(1.1);
    opacity: 1;
  }
  66% {
    transform: translate(-10px, 15px) scale(0.95);
    opacity: 0.8;
  }
}
/* Mobile adjustments for better display on small screens */
@media screen and (max-width: 480px) {
  .mood-scale_mood-label {
    font-size: 18px;
  }

  .mood-scale_mood-description {
    font-size: 13px;
  }
}

.mood-scale_slider-wrapper {
  position: relative;
  margin-top: 30px;
  transition: opacity 0.3s ease, transform 0.3s ease;
}

/* Slider appearance animation */
.mood-scale_slider-wrapper:not(.d-none) {
  animation: slideUp 0.4s ease;
}

@keyframes slideUp {
  from {
    opacity: 0;
    transform: translateY(10px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.mood-selector_quick-select-option {
  position: absolute;
  top: -12px;
  opacity: 0.5;
  cursor: pointer;
  transition: opacity 0.3s ease, transform 0.3s ease;
  border-radius: 50%;
  padding: 2px;
}

.mood-selector_quick-select-option:hover {
  opacity: 0.75;
  transform: translateY(-2px);
}

.mood-selector_quick-select-option--selected {
  opacity: 1;
  animation: selectedBounce 0.5s ease;
}

@keyframes selectedBounce {
  0%, 100% {
    transform: scale(1) translateY(0);
  }
  50% {
    transform: scale(1.15) translateY(-3px);
  }
}

.mood-selector_quick-select-option-wrapper {
  position: absolute;
  top: 0;
  width: 1px;
  cursor: pointer;
  z-index: 1;
}

.mood-selector_quick-select-option-wrapper[data-mood-value="-100"] {
  left: 8px;
}

.mood-selector_quick-select-option-wrapper[data-mood-value="-50"] {
  left: calc(25% - 5px);
}

.mood-selector_quick-select-option-wrapper[data-mood-value="0"] {
  left: calc(50% - 17px);
}

.mood-selector_quick-select-option-wrapper[data-mood-value="50"] {
  left: calc(75% - 30px);
}

.mood-selector_quick-select-option-wrapper[data-mood-value="100"] {
  right: 43px;
}

.mood-selector_quick-select-option {
  position: relative;
  left: 0px;
  display: inline-block;
  width: 1px;
}

button.diary-day-mood {
  background: transparent;
  border: 0px solid transparent;
  opacity: 0.8;
}

button.diary-day-mood:hover {
  opacity: 1;
}

.mood-scale_left-eye, .mood-scale_right-eye {
  transition:
    cy 0.2s cubic-bezier(0.4, 0, 0.2, 1),
    ry 0.2s cubic-bezier(0.4, 0, 0.2, 1);
  cy: 40;
  ry: 6;
}

.mood-scale_left-eye-reflection {
  cx: 37;
  cy: 37;
}

.mood-scale_right-eye-reflection {
  cx: 67;
  cy: 37;
}


/* Wink state for right eye */
.mood-scale--wink-right .mood-scale_right-eye {
  transition:
    cy 0.2s cubic-bezier(0.4, 0, 0.2, 1),
    ry 0.2s cubic-bezier(0.4, 0, 0.2, 1);
  cy: 40; /* Adjust vertical position to keep it aligned */
  ry: 1; /* Set ry to 0 to make it look like a line */
}

.mood-scale--wink-right .mood-scale_right-eye-reflection {
  /* Hide the reflection when the eye is closed */
  transition: opacity 0.2s cubic-bezier(0.4, 0, 0.2, 1);
  opacity: 0; /* Hide the reflection when the eye is closed */
}

.mood-scale--wink-left .mood-scale_left-eye {
  transition:
    cy 0.2s cubic-bezier(0.4, 0, 0.2, 1),
    ry 0.2s cubic-bezier(0.4, 0, 0.2, 1);
  cy: 40; /* Adjust vertical position to keep it aligned */
  ry: 1; /* Set ry to 0 to make it look like a line */
}

.mood-scale--wink-left .mood-scale_left-eye-reflection {
  /* Hide the reflection when the eye is closed */
  transition: opacity 0.2s cubic-bezier(0.4, 0, 0.2, 1);
  opacity: 0; /* Hide the reflection when the eye is closed */
}

.mood-scale--blink .mood-scale_right-eye,
.mood-scale--blink .mood-scale_left-eye {
  transition:
    cy 0.2s cubic-bezier(0.4, 0, 0.2, 1),
    ry 0.2s cubic-bezier(0.4, 0, 0.2, 1);
  cy: 40; /* Adjust vertical position to keep it aligned */
  ry: 1; /* Set ry to 0 to make it look like a line */
}

.mood-scale--blink .mood-scale_right-eye-reflection,
.mood-scale--blink .mood-scale_left-eye-reflection {
  /* Hide the reflection when the eye is closed */
  transition: opacity 0.2s cubic-bezier(0.4, 0, 0.2, 1);
  opacity: 0; /* Hide the reflection when the eye is closed */
}

@keyframes bubbleFadeOut {
  from {
    opacity: 1;
    transform: translateY(0) scale(1);
  }
  to {
    opacity: 0;
    transform: translateY(-5px) scale(0.95);
  }
}

.bubble--fade-out-on-load {
  opacity: 1;
  animation: bubbleFadeOut 2s ease 1s forwards;
}

/* Enhanced bubble appearance animation */
@keyframes bubbleAppear {
  0% {
    opacity: 0;
    transform: translateY(10px) scale(0.8);
  }
  50% {
    transform: translateY(-2px) scale(1.05);
  }
  100% {
    opacity: 1;
    transform: translateY(0) scale(1);
  }
}

[data-mood-scale-target="bubble"]:not(.d-none):not(.bubble--fade-out-on-load) {
  animation: bubbleAppear 0.4s ease;
}

/* Info text positioning within the background area */
[data-mood-scale-target="infoText"] {
  margin-top: 0;
  max-height: 0;
  overflow: hidden;
  opacity: 0;
  transition: opacity 0.3s ease, max-height 0.3s ease, margin-top 0.3s ease;
}

[data-mood-scale-target="infoText"].show {
  margin-top: 8px;
  max-height: 30px;
  opacity: 1;
}

[data-mood-scale-target="infoText"].fade-out {
  opacity: 0;
}

/* ============================================ */
/* MOBILE PERFORMANCE OPTIMIZATION */
/* ============================================ */

@media (max-width: 768px) {
  /* Disable all animations, transitions, and heavy filters for mobile performance */
  .mood-selector_quick-select-option svg,
  .mood-scale_face-container,
  .mood-scale_face,
  .mood-scale_display-container::before,
  .mood-scale_mood-label,
  .mood-selector_quick-select-option,
  .mood-selector_quick-select-option--selected,
  .mood-scale_slider-wrapper,
  .mood-scale_interactive-area,
  [data-mood-scale-target="bubble"],
  [data-mood-scale-target="infoText"] {
    animation: none !important;
    transition: none !important;
    filter: none !important;
    transform: none !important;
  }

  /* Disable hover effects on mobile */
  .mood-selector_quick-select-option:hover,
  .mood-selector_quick-select-option:hover svg,
  .mood-scale_face-container:hover svg,
  .mood-scale_face-container:hover .mood-scale_face {
    animation: none !important;
    transform: none !important;
    filter: none !important;
  }

  /* Hide animated background gradient on mobile */
  .mood-scale_display-container::before {
    display: none;
  }

  /* Remove text shadow for performance */
  .mood-scale_mood-label {
    text-shadow: none;
  }
}

/* ============================================ */
/* ACCESSIBILITY - REDUCED MOTION SUPPORT */
/* ============================================ */

@media (prefers-reduced-motion: reduce) {
  .mood-selector_quick-select-option svg,
  .mood-scale_face-container,
  .mood-scale_face,
  .mood-scale_display-container::before,
  .mood-scale_mood-label,
  .mood-selector_quick-select-option,
  .mood-selector_quick-select-option--selected,
  .mood-scale_slider-wrapper,
  .mood-scale_range-selector::-webkit-slider-thumb,
  .mood-scale_range-selector::-moz-range-thumb,
  [data-mood-scale-target="bubble"] {
    animation: none;
    transition: none;
  }

  .mood-scale_face-container:hover svg {
    animation: none;
  }

  .mood-scale_display-container::before {
    display: none;
  }
}
