/* === Noise Mixer additions === */

.channels {
  display: flex;
  flex-direction: column;
  gap: 0.85rem;
  margin: 0 0 1rem;
}

.channel {
  background: var(--card);
  border: 2px solid var(--border);
  border-radius: 20px;
  padding: 1rem 1.25rem 1.25rem;
  box-shadow: var(--shadow);
  transition: border-color 0.2s ease;
}

.channel.active {
  border-color: var(--pick-border);
}

.channel-head {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 1rem;
  margin-bottom: 0.7rem;
}

.channel h2 {
  margin: 0;
  font-family: "Fredoka", "Nunito", sans-serif;
  font-size: 1.2rem;
  font-weight: 500;
  color: var(--ink);
}

.channel-desc {
  margin: 0.1rem 0 0;
  font-size: 0.85rem;
  color: var(--muted);
}

.channel-value {
  font-family: "Fredoka", "Nunito", sans-serif;
  font-size: 1.1rem;
  font-weight: 600;
  color: var(--muted);
  min-width: 2.8rem;
  text-align: right;
  transition: color 0.2s ease;
}

.channel.active .channel-value {
  color: var(--primary-dark);
}

.slider {
  -webkit-appearance: none;
  appearance: none;
  width: 100%;
  height: 8px;
  background: var(--pick-bg);
  border-radius: 999px;
  outline: none;
  cursor: pointer;
  margin: 0;
}

.slider::-webkit-slider-thumb {
  -webkit-appearance: none;
  appearance: none;
  width: 24px;
  height: 24px;
  border-radius: 50%;
  background: var(--primary);
  border: 3px solid #fff;
  cursor: pointer;
  box-shadow: 0 2px 8px rgba(255, 107, 157, 0.4);
  transition: transform 0.15s ease;
}

.slider::-webkit-slider-thumb:hover { transform: scale(1.15); }
.slider::-webkit-slider-thumb:active { transform: scale(1.08); }

.slider::-moz-range-thumb {
  width: 24px;
  height: 24px;
  border-radius: 50%;
  background: var(--primary);
  border: 3px solid #fff;
  cursor: pointer;
  box-shadow: 0 2px 8px rgba(255, 107, 157, 0.4);
  transition: transform 0.15s ease;
}

.slider::-moz-range-thumb:hover { transform: scale(1.15); }

.slider:focus-visible::-webkit-slider-thumb {
  box-shadow: 0 0 0 4px var(--pick-bg), 0 2px 8px rgba(255, 107, 157, 0.4);
}

.timer-status {
  margin: 0.85rem 0 0;
  font-size: 0.95rem;
  color: var(--muted);
  text-align: center;
}

.timer-status strong {
  color: var(--primary-dark);
  font-family: "Fredoka", "Nunito", sans-serif;
  font-weight: 600;
  font-size: 1.05em;
}

/* === Rain channel sub-controls === */

.rain-options {
  max-height: 0;
  opacity: 0;
  margin-top: 0;
  overflow: hidden;
  border-top: 1px dashed var(--border);
  padding-top: 0.9rem;
  transition: max-height 0.35s ease, opacity 0.3s ease, margin-top 0.3s ease;
}

/* Reveal the rain controls only once rain is actually in the mix */
.channel[data-channel="rain"].active .rain-options {
  max-height: 280px;
  opacity: 1;
  margin-top: 1rem;
}

.rain-control { margin-bottom: 0.85rem; }

.rain-control label {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--muted);
  margin-bottom: 0.45rem;
}

.rain-val {
  font-family: "Fredoka", "Nunito", sans-serif;
  font-weight: 600;
  color: var(--primary-dark);
}

.slider-sm { height: 6px; }

.slider-sm::-webkit-slider-thumb {
  width: 18px;
  height: 18px;
  border-width: 2px;
}

.slider-sm::-moz-range-thumb {
  width: 18px;
  height: 18px;
  border-width: 2px;
}

.rain-toggle-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--muted);
  margin-top: 0.2rem;
}

.rain-switch {
  position: relative;
  flex: 0 0 auto;
  width: 46px;
  height: 26px;
  padding: 0;
  border: none;
  border-radius: 999px;
  background: var(--pick-bg);
  cursor: pointer;
  transition: background 0.2s ease;
}

.rain-switch[aria-checked="true"] { background: var(--primary); }

.rain-switch i {
  position: absolute;
  top: 3px;
  left: 3px;
  width: 20px;
  height: 20px;
  border-radius: 50%;
  background: var(--card);
  box-shadow: 0 1px 4px rgba(0, 0, 0, 0.25);
  transition: left 0.2s ease;
}

.rain-switch[aria-checked="true"] i { left: 23px; }

.rain-switch:focus-visible {
  outline: none;
  box-shadow: 0 0 0 4px var(--pick-bg);
}
