:root {
  --bg: #0485b4;
  --text: #fff;
  --icon: rgba(255, 255, 255, 0.9);
  --icon-muted: rgba(255, 255, 255, 0.4);
  --soft: rgba(255, 255, 255, 0.1);
  --soft-hover: rgba(255, 255, 255, 0.28);
  --soft-disabled: rgba(255, 255, 255, 0.05);
  --dialog-text: #151515;
  --danger: #b33333;
  --success: #d5f8df;
}

@keyframes background-change {
  0% {
    background: #0485b4;
  }

  5.2631% {
    background: #0d7ab5;
  }

  10.5262% {
    background: #16528e;
  }

  15.7893% {
    background: #004761;
  }

  21.0524% {
    background: #0a615c;
  }

  26.3155% {
    background: #147b57;
  }

  31.5786% {
    background: #226d6c;
  }

  36.8417% {
    background: #2f5e81;
  }

  42.1048% {
    background: #4940aa;
  }

  47.3679% {
    background: #5a3080;
  }

  52.6310% {
    background: #5a3080;
  }

  57.8941% {
    background: #4940aa;
  }

  63.1572% {
    background: #2f5e81;
  }

  68.4204% {
    background: #226d6c;
  }

  73.6835% {
    background: #147b57;
  }

  78.9466% {
    background: #0a615c;
  }

  84.2097% {
    background: #004761;
  }

  89.4728% {
    background: #16528e;
  }

  94.7359% {
    background: #0d7ab5;
  }

  to {
    background: #0485b4;
  }
}

* {
  box-sizing: border-box;
}

html,
body {
  height: 100%;
}

body {
  position: relative;
  isolation: isolate;
  margin: 0;
  overflow: hidden;
  color: var(--text);
  background: var(--bg);
  font-family: Nunito, ui-rounded, "Segoe UI", Arial, "Microsoft YaHei", sans-serif;
  letter-spacing: 0;
  transition: background 0.25s ease;
}

body::before {
  content: "";
  position: fixed;
  inset: 0;
  z-index: 0;
  pointer-events: none;
  opacity: 0;
  background: center / cover no-repeat;
  filter: brightness(0.62) saturate(1.04);
  transition: opacity 0.25s ease;
}

body[data-theme="transition"] {
  animation: background-change 300s linear infinite;
}

body[data-theme="dark"] {
  background: #030711;
}

body[data-theme="waterfall"],
body[data-theme="camping-fire"],
body[data-theme="blue-room"],
body[data-theme="train"] {
  animation: none;
  background: #06384b;
}

body[data-theme="waterfall"]::before,
body[data-theme="camping-fire"]::before,
body[data-theme="blue-room"]::before,
body[data-theme="train"]::before {
  opacity: 1;
}

body[data-theme="waterfall"]::before {
  background-image: url("bg/waterfall.gif");
}

body[data-theme="camping-fire"]::before {
  background-image: url("bg/camping-fire.gif");
}

body[data-theme="blue-room"]::before {
  background-image: url("bg/blue-room.gif");
}

body[data-theme="train"]::before {
  background-image: url("bg/train.gif");
}

button,
input,
a {
  font: inherit;
}

button,
a {
  color: inherit;
}

button {
  border: 0;
  cursor: pointer;
}

a {
  text-decoration: none;
}

.sprite {
  position: absolute;
  width: 0;
  height: 0;
  overflow: hidden;
}

.app-shell {
  position: relative;
  z-index: 1;
  min-height: 100%;
}

.topbar {
  position: relative;
  z-index: 3;
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 87px;
  padding: 24px;
}

.topbar h1 {
  margin: 0;
  font-size: 25px;
  line-height: 1.25;
  font-weight: 400;
}

.pomodoro {
  position: absolute;
  left: 50%;
  top: 26px;
  display: flex;
  align-items: center;
  gap: 6px;
  transform: translateX(-50%);
}

.tools {
  display: flex;
  align-items: center;
  gap: 20px;
}

.volume-control {
  position: relative;
  z-index: 4;
  display: inline-flex;
  align-items: center;
  justify-content: flex-end;
  width: 25px;
  height: 25px;
}

.soft-button,
.timer-button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  height: 32px;
  border-radius: 12px;
  background: var(--soft);
  transition: background 0.2s ease, opacity 0.2s ease;
}

.soft-button:hover,
.timer-button:hover,
.soft-button:focus-visible,
.timer-button:focus-visible {
  background: var(--soft-hover);
  outline: 0;
}

.icon-button {
  width: 32px;
}

.timer-button {
  min-width: 76px;
  height: 36px;
  gap: 4px;
  padding: 0 10px;
  font-size: 21px;
  line-height: 1;
  font-weight: 800;
  letter-spacing: 1px;
}

.topbar svg,
.plain-icon svg,
.soft-button svg {
  width: 1em;
  height: 1em;
  fill: none;
  stroke: currentColor;
  stroke-width: 2;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.plain-icon,
.theme-menu summary,
.combo-menu summary {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 22px;
  height: 22px;
  padding: 0;
  background: transparent;
  opacity: 0.9;
  transition: opacity 0.2s ease;
}

.plain-icon:hover,
.theme-menu summary:hover,
.combo-menu summary:hover,
.plain-icon:focus-visible,
.theme-menu summary:focus-visible,
.combo-menu summary:focus-visible {
  opacity: 1;
  outline: 0;
}

.plain-icon:first-child {
  width: 25px;
  height: 25px;
  font-size: 25px;
}

.volume-control .plain-icon {
  width: 25px;
  height: 25px;
  font-size: 25px;
}

.plain-icon.muted,
.plain-icon.disabled {
  opacity: 0.5;
}

.plain-icon.is-active {
  opacity: 1;
  color: #fff;
}

.plain-icon.disabled {
  cursor: default;
}

.master-volume {
  position: absolute;
  right: 35px;
  width: 110px;
  height: 4px;
  padding: 0;
  margin: 0;
  appearance: none;
  border-radius: 999px;
  background: linear-gradient(90deg, #fff 100%, rgba(255, 255, 255, 0.35) 100%);
  opacity: 0;
  pointer-events: none;
  cursor: pointer;
  transition: opacity 0.18s ease;
}

.volume-control:hover .master-volume,
.volume-control:focus-within .master-volume {
  opacity: 1;
  pointer-events: auto;
}

.master-volume:focus-visible {
  outline: 2px solid rgba(255, 255, 255, 0.8);
  outline-offset: 6px;
}

.master-volume::-webkit-slider-thumb {
  width: 8px;
  height: 8px;
  appearance: none;
  border-radius: 50%;
  background: #fff;
}

.master-volume::-moz-range-thumb {
  width: 8px;
  height: 8px;
  border: 0;
  border-radius: 50%;
  background: #fff;
}

.theme-menu {
  position: relative;
}

.theme-menu summary,
.combo-menu summary {
  list-style: none;
  cursor: pointer;
}

.theme-menu summary::-webkit-details-marker,
.combo-menu summary::-webkit-details-marker {
  display: none;
}

.combo-menu {
  position: relative;
}

.combo-menu.is-empty summary {
  opacity: 0.5;
  pointer-events: none;
}

.combo-panel {
  position: absolute;
  top: 40px;
  right: -18px;
  z-index: 4;
  display: grid;
  width: 164px;
  gap: 10px;
  padding: 8px 10px 10px;
  overflow: hidden;
  border-radius: 14px;
  background: rgba(5, 12, 24, 0.72);
  box-shadow: 0 18px 30px rgba(0, 0, 0, 0.24);
  backdrop-filter: blur(10px);
}

.combo-tabs {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 6px;
}

.combo-tab,
.combo-item {
  height: 34px;
  border-radius: 9px;
  color: rgba(255, 255, 255, 0.8);
  background: transparent;
  font-size: 14px;
}

.combo-tab.is-active {
  background: rgba(255, 255, 255, 0.14);
  color: #fff;
}

.combo-list {
  display: grid;
  gap: 6px;
  max-height: 260px;
  overflow-y: auto;
  scrollbar-width: none;
}

.combo-list::-webkit-scrollbar {
  width: 0;
  height: 0;
}

.combo-item {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  width: 100%;
  height: 44px;
  padding: 0 12px;
  background: rgba(255, 255, 255, 0.06);
  font-weight: 800;
  letter-spacing: 0;
}

.combo-item:hover,
.combo-item:focus-visible {
  background: rgba(255, 255, 255, 0.12);
  outline: 0;
}

.combo-item.is-delete {
  justify-content: space-between;
}

.combo-empty {
  padding: 12px 6px;
  color: rgba(255, 255, 255, 0.5);
  text-align: center;
  font-size: 13px;
}

.theme-panel {
  position: absolute;
  top: 44px;
  right: -72px;
  display: grid;
  width: 326px;
  max-height: min(70vh, 690px);
  gap: 16px;
  padding: 16px;
  overflow: auto;
  border-radius: 16px;
  background: rgba(21, 66, 90, 0.2);
  box-shadow: 0 22px 40px rgba(0, 0, 0, 0.18);
  backdrop-filter: blur(8px);
  scrollbar-width: none;
}

.theme-panel::-webkit-scrollbar {
  width: 0;
  height: 0;
}

.theme-card {
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 112px;
  border: 2px solid transparent;
  border-radius: 12px;
  color: rgba(255, 255, 255, 0.78);
  background: #116f5a;
  font-size: 25px;
  font-weight: 800;
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.06);
  background-position: center;
  background-size: cover;
  transition: border-color 0.2s ease, color 0.2s ease, transform 0.2s ease;
}

.theme-card:hover,
.theme-card:focus-visible,
.theme-card.is-selected {
  border-color: #fff;
  color: #fff;
  outline: 0;
}

.theme-dynamic {
  background: #168860;
}

.theme-dark {
  background: #020711;
}

.theme-falls {
  background-image:
    linear-gradient(rgba(0, 0, 0, 0.12), rgba(0, 0, 0, 0.12)),
    url("bg/waterfall.gif");
}

.theme-camp {
  background-image:
    linear-gradient(rgba(0, 0, 0, 0.16), rgba(0, 0, 0, 0.16)),
    url("bg/camping-fire.gif");
}

.theme-room {
  background-image:
    linear-gradient(rgba(0, 0, 0, 0.18), rgba(0, 0, 0, 0.18)),
    url("bg/blue-room.gif");
}

.theme-train {
  background-image:
    linear-gradient(rgba(0, 0, 0, 0.18), rgba(0, 0, 0, 0.18)),
    url("bg/train.gif");
}

.content-scroll {
  position: relative;
  height: calc(100vh - 87px);
  padding: 20px 24px 38px;
  overflow-y: auto;
  scrollbar-color: rgba(0, 0, 0, 0.45) transparent;
  scrollbar-width: thin;
}

.content-scroll::-webkit-scrollbar {
  width: 8px;
}

.content-scroll::-webkit-scrollbar-thumb {
  border-radius: 999px;
  background: rgba(0, 0, 0, 0.45);
}

.combo-actions {
  position: absolute;
  top: 20px;
  right: 24px;
  display: flex;
  align-items: center;
  gap: 10px;
}

.combo-name-input {
  width: 130px;
  height: 28px;
  border: 0;
  border-radius: 12px;
  color: #fff;
  background: rgba(255, 255, 255, 0.08);
  text-align: center;
  font-size: 14px;
}

.combo-name-input::placeholder {
  color: rgba(255, 255, 255, 0.58);
}

.combo-name-input:focus {
  outline: 0;
  background: rgba(255, 255, 255, 0.14);
}

.mini-pill {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  height: 24px;
  min-width: 50px;
  padding: 0 9px;
  border-radius: 12px;
  color: #fff;
  background: var(--soft-disabled);
  line-height: 1;
  opacity: 0.7;
  transition: background 0.2s ease, opacity 0.2s ease;
}

.mini-pill:hover {
  background: rgba(255, 255, 255, 0.18);
}

.mini-pill.disabled {
  background: var(--soft-disabled);
  opacity: 0.7;
}

.mini-pill:not(.disabled) {
  opacity: 1;
}

.sound-section {
  margin: 0 auto 12px;
}

.sound-section:first-of-type {
  padding-top: 36px;
}

.sound-section h2 {
  margin: 0 0 12px;
  text-align: center;
  font-size: 18px;
  line-height: 1.5;
  font-weight: 600;
}

.sound-grid {
  display: grid;
  grid-template-columns: repeat(4, 96px);
  justify-content: center;
  gap: 20px;
  width: min(100%, 444px);
  margin: 0 auto;
}

@media (min-width: 1024px) {
  .sound-grid {
    grid-template-columns: repeat(5, 96px);
    width: 560px;
  }
}

@media (min-width: 1536px) {
  .sound-grid {
    grid-template-columns: repeat(6, 96px);
    width: 676px;
  }
}

.sound {
  position: relative;
  width: 96px;
  height: 96px;
}

.sound>input[type="checkbox"] {
  position: absolute;
  width: 1px;
  height: 1px;
  opacity: 0;
  pointer-events: none;
}

.sound label {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 96px;
  height: 96px;
  border-radius: 12px;
  color: var(--icon);
  cursor: pointer;
  opacity: 0.4;
  transition: background 0.25s ease, opacity 0.25s ease, transform 0.25s ease;
}

.sound label:hover,
.sound>input[type="checkbox"]:focus-visible+label {
  background: var(--soft);
  outline: 0;
}

.sound>input[type="checkbox"]:checked+label {
  background: rgba(255, 255, 255, 0.12);
  opacity: 0.82;
}

.sound.playback-error label {
  background: rgba(255, 255, 255, 0.16);
}

.sound svg {
  width: 80px;
  height: 80px;
  fill: none;
  stroke: currentColor;
  stroke-width: 4;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.relax-number {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 62px;
  height: 62px;
  border: 4px solid currentColor;
  border-radius: 50%;
  font-size: 42px;
  line-height: 1;
  font-weight: 400;
}

.volume {
  position: absolute;
  left: 0;
  bottom: 0;
  width: 96px;
  height: 4px;
  padding: 0;
  margin: 0;
  appearance: none;
  border-radius: 999px;
  background: linear-gradient(90deg, #fff 100%, rgba(255, 255, 255, 0.3) 100%);
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.2s ease;
}

.sound:hover .volume,
.sound>input[type="checkbox"]:checked~.volume {
  opacity: 1;
  pointer-events: auto;
}

.volume::-webkit-slider-thumb {
  width: 10px;
  height: 10px;
  appearance: none;
  border-radius: 50%;
  background: #fff;
}

.volume::-moz-range-thumb {
  width: 10px;
  height: 10px;
  border: 0;
  border-radius: 50%;
  background: #fff;
}

.sound-audio {
  display: none;
}

.intro {
  width: min(60%, 850px);
  margin: 54px auto 26px;
  color: rgba(255, 255, 255, 0.78);
  text-align: left;
  font-size: 14px;
  line-height: 1.8;
}

.footer {
  display: flex;
  align-items: center;
  justify-content: center;
  flex-wrap: wrap;
  gap: 18px;
  padding-bottom: 30px;
  color: rgba(255, 255, 255, 0.7);
  font-size: 14px;
}

.footer span {
  font-weight: 800;
}

.footer a:hover {
  color: #fff;
}

.modal {
  position: fixed;
  inset: 0;
  z-index: 20;
  display: none;
  align-items: center;
  justify-content: center;
  padding: 20px;
}

.modal:target {
  display: flex;
}

.modal-backdrop {
  position: absolute;
  inset: 0;
  background: rgba(0, 0, 0, 0.25);
  backdrop-filter: blur(1px);
}

.dialog {
  position: relative;
  z-index: 1;
  width: min(98%, 320px);
  border-radius: 14px;
  color: var(--dialog-text);
  background: #fff;
  box-shadow: 0 20px 45px rgba(0, 0, 0, 0.18);
}

.timer-dialog {
  width: 204px;
  min-height: 248px;
  padding: 22px 24px 24px;
}

.settings-dialog {
  min-height: 386px;
  padding: 24px;
}

.dialog h2 {
  margin: 0;
  text-align: center;
  font-size: 25px;
  line-height: 1;
  font-weight: 900;
}

.timer-dialog h2 {
  margin-bottom: 38px;
}

.settings-dialog h2 {
  margin-bottom: 43px;
}

.field-row,
.setting-group label {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  font-size: 20px;
}

.field-row input,
.setting-group input {
  width: 82px;
  height: 42px;
  border: 1px solid #bfe7f7;
  border-radius: 8px;
  color: #444;
  text-align: center;
}

.field-row input:focus,
.setting-group input:focus {
  border-color: #078ec8;
  outline: 1px solid #078ec8;
}

.setting-group h3 {
  margin: 0 0 20px;
  color: #8a8a8a;
  font-size: 16px;
  font-weight: 400;
}

.setting-group label {
  margin-bottom: 12px;
  font-size: 18px;
}

.setting-group small {
  color: #9b9b9b;
  font-size: 12px;
}

.dialog-actions {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-top: 38px;
}

.settings-dialog .dialog-actions {
  margin-top: 44px;
}

.text-action {
  color: var(--danger);
  font-size: 18px;
}

.confirm-action {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 76px;
  height: 42px;
  border-radius: 8px;
  color: #1d4930;
  background: var(--success);
  font-size: 18px;
}

.confirm-action.wide {
  min-width: 134px;
}

@media (max-width: 640px) {
  .topbar {
    height: 84px;
    padding: 24px;
  }

  .topbar h1 {
    font-size: 25px;
  }

  .pomodoro {
    display: none;
  }

  .tools {
    gap: 17px;
  }

  .volume-control {
    position: relative;
    width: 25px;
  }

  .master-volume {
    position: absolute;
    right: 35px;
    width: 104px;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.18s ease;
  }

  .volume-control:hover .master-volume,
  .volume-control:focus-within .master-volume {
    opacity: 1;
    pointer-events: auto;
  }

  .content-scroll {
    height: calc(100vh - 84px);
    padding: 20px 16px 34px;
  }

  .combo-actions {
    right: 16px;
  }

  .sound-section:first-of-type {
    padding-top: 35px;
  }

  .sound-grid {
    grid-template-columns: repeat(3, 96px);
    width: 328px;
    gap: 20px;
  }

  .theme-panel {
    position: fixed;
    left: auto;
    right: 24px;
    top: 78px;
    width: min(calc(100vw - 48px), 180px);
    max-height: calc(100vh - 96px);
    gap: 14px;
    padding: 14px;
    overflow-y: auto;
    border-radius: 18px;
    background: rgba(35, 39, 112, 0.22);
    box-shadow: 0 20px 32px rgba(0, 0, 0, 0.16);
    backdrop-filter: blur(8px);
  }

  .theme-card {
    width: 100%;
    min-height: 100px;
    padding: 0 8px;
    font-size: 24px;
    line-height: 1.08;
    text-align: center;
  }
}

@media (max-width: 360px) {
  .topbar {
    padding-inline: 18px;
  }

  .tools {
    gap: 13px;
  }

  .master-volume {
    right: 31px;
    width: 92px;
  }

  .sound-grid {
    grid-template-columns: repeat(3, 88px);
    width: 304px;
    gap: 20px 14px;
  }

  .sound,
  .sound label {
    width: 88px;
    height: 88px;
  }

  .sound svg {
    width: 74px;
    height: 74px;
  }

  .volume {
    width: 88px;
  }
}

/* Redesigned mixer workspace */
:root {
  --accent: #35d79b;
  --accent-strong: #24b97d;
  --panel: rgba(4, 34, 38, 0.62);
  --panel-soft: rgba(255, 255, 255, 0.055);
  --panel-border: rgba(255, 255, 255, 0.14);
  --panel-border-strong: rgba(53, 215, 155, 0.72);
  --muted-text: rgba(255, 255, 255, 0.64);
}

body {
  background:
    radial-gradient(circle at 12% 12%, rgba(55, 215, 155, 0.16), transparent 32%),
    radial-gradient(circle at 84% 8%, rgba(58, 121, 255, 0.12), transparent 34%),
    linear-gradient(135deg, #063b3b 0%, #082d35 46%, #0a463a 100%);
}

body[data-theme="transition"] {
  animation: none;
}

.topbar {
  height: 76px;
  padding: 18px 28px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
  background: rgba(2, 22, 26, 0.22);
  backdrop-filter: blur(12px);
}

.topbar h1 {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-size: 28px;
}

.topbar h1::before {
  content: "";
  width: 18px;
  height: 22px;
  border: 3px solid var(--accent);
  border-bottom-color: transparent;
  border-radius: 16px 16px 4px 16px;
  transform: rotate(35deg);
}

.pomodoro {
  top: 14px;
}

.timer-button {
  min-width: 118px;
  height: 50px;
  border-radius: 8px;
  background: transparent;
  font-size: 34px;
}

.soft-button {
  width: 50px;
  height: 50px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.08);
  font-size: 22px;
}

#play-toggle {
  color: #fff;
  background: linear-gradient(135deg, #39d996, #1fa86d);
}

.tools {
  gap: 22px;
}

.plain-icon,
.theme-menu summary,
.combo-menu summary {
  width: 26px;
  height: 26px;
  font-size: 24px;
}

.content-scroll {
  height: calc(100vh - 76px);
  padding: 48px 28px 28px;
  scrollbar-color: rgba(255, 255, 255, 0.28) transparent;
}

.mixer-layout {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 330px;
  gap: 18px;
  width: min(100%, 1620px);
  margin: 0 auto;
  align-items: stretch;
}

.sound-board,
.current-panel {
  border: 1px solid var(--panel-border);
  border-radius: 8px;
  background: var(--panel);
  box-shadow: 0 24px 50px rgba(0, 0, 0, 0.18);
  backdrop-filter: blur(4px);
}

.sound-board {
  overflow: hidden;
  min-height: 100%;
}

.sound-section {
  display: grid;
  grid-template-columns: 108px minmax(0, 1fr);
  gap: 18px;
  width: 100%;
  margin: 0;
  padding: 18px 24px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
}

.sound-section:first-of-type {
  padding-top: 18px;
}

.sound-section:last-of-type {
  border-bottom: 0;
}

.sound-section h2 {
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 0;
  text-align: center;
  font-size: 20px;
}

.sound-grid {
  grid-template-columns: repeat(auto-fit, minmax(92px, 1fr));
  justify-content: stretch;
  gap: 10px;
  width: 100%;
  margin: 0;
}

.sound,
.sound label {
  width: 100%;
  height: 100px;
  container-type: inline-size;
}

.sound label {
  position: relative;
  flex-direction: column;
  gap: 5px;
  padding-bottom: 6px;
  border: 1px solid var(--panel-border);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.045);
  color: rgba(255, 255, 255, 0.82);
  opacity: 0.76;
}

.sound label::after {
  content: attr(aria-label);
  display: -webkit-box;
  flex: 0 1 auto;
  max-width: 100%;
  padding: 0 5px;
  overflow: hidden;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
  line-clamp: 2;
  color: rgba(255, 255, 255, 0.9);
  font-size: 11px;
  font-size: clamp(9px, 11cqi, 12px);
  font-weight: 400;
  line-height: 1.15;
  text-align: center;
  text-wrap: balance;
  word-break: break-word;
  overflow-wrap: break-word;
  hyphens: auto;
}

.sound>input[type="checkbox"]:checked+label {
  border-color: var(--panel-border-strong);
  background: linear-gradient(180deg, rgba(53, 215, 155, 0.2), rgba(53, 215, 155, 0.08));
  color: #fff;
  opacity: 1;
}

.sound label:hover,
.sound>input[type="checkbox"]:focus-visible+label {
  border-color: rgba(255, 255, 255, 0.34);
  background: rgba(255, 255, 255, 0.08);
  transform: translateY(-1px);
}

.sound svg {
  width: 42px;
  height: 42px;
  stroke-width: 3;
}

.relax-number {
  width: 46px;
  height: 46px;
  border-width: 3px;
  font-size: 26px;
}

.volume {
  left: 14px;
  right: 14px;
  bottom: 8px;
  width: calc(100% - 28px);
  height: 4px;
  background: linear-gradient(90deg, var(--accent) 100%, rgba(255, 255, 255, 0.22) 100%);
}

.volume::-webkit-slider-thumb,
.master-volume::-webkit-slider-thumb,
.current-volume::-webkit-slider-thumb {
  width: 10px;
  height: 10px;
  appearance: none;
  border-radius: 50%;
  background: #fff;
}

.current-panel {
  display: flex;
  flex-direction: column;
  height: 100%;
  min-height: 0;
  padding: 18px 18px 18px;
  position: sticky;
  top: 18px;
  align-self: stretch;
}

.current-panel-header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 14px;
  margin-bottom: 20px;
}

.current-panel-header p,
.combo-save-box label {
  margin: 0 0 5px;
  color: var(--muted-text);
  font-size: 13px;
}

.current-panel-header h2 {
  margin: 0;
  font-size: 24px;
  line-height: 1.2;
}

.current-actions {
  display: flex;
  gap: 8px;
}

.mini-pill {
  height: 36px;
  min-width: 58px;
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.08);
  font-size: 15px;
}

.mini-pill:not(.disabled),
.confirm-action,
#save-button:not(.disabled) {
  background: linear-gradient(135deg, #42e0a2, #21b878);
  color: #062c22;
}

.current-mix-list {
  display: flex;
  flex: 1 1 auto;
  flex-direction: column;
  gap: 13px;
  min-height: 0;
  margin-bottom: 18px;
}

.current-empty {
  display: flex;
  flex: 1 1 auto;
  align-items: center;
  min-height: 180px;
  padding: 18px;
  border: 1px dashed rgba(255, 255, 255, 0.14);
  border-radius: 8px;
  color: var(--muted-text);
  font-size: 14px;
  line-height: 1.7;
}

.current-item {
  display: grid;
  grid-template-columns: 48px minmax(0, 1fr) 24px;
  gap: 12px;
  align-items: center;
}

.current-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 48px;
  height: 48px;
  border: 1px solid rgba(255, 255, 255, 0.16);
  border-radius: 50%;
  color: rgba(255, 255, 255, 0.82);
}

.current-icon svg {
  width: 28px;
  height: 28px;
  fill: none;
  stroke: currentColor;
  stroke-width: 3;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.current-icon .relax-number {
  width: auto;
  height: auto;
  border: 0;
  font-size: 20px;
}

.current-title {
  display: block;
  margin-bottom: 6px;
  overflow: hidden;
  color: #fff;
  font-weight: 800;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.current-volume-row {
  display: flex;
  align-items: center;
  gap: 8px;
}

.current-volume-icon {
  color: #fff;
  font-size: 13px;
}

.current-volume {
  width: 100%;
  height: 4px;
  appearance: none;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.22);
}

.current-remove {
  color: rgba(255, 255, 255, 0.58);
  background: transparent;
  font-size: 24px;
}

.combo-save-box {
  display: grid;
  gap: 10px;
  padding-top: 16px;
  border-top: 1px solid rgba(255, 255, 255, 0.08);
}

.combo-save-box.is-hidden {
  display: none;
}

.combo-name-input {
  width: 100%;
  height: 44px;
  border: 1px solid rgba(255, 255, 255, 0.14);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.04);
  font-size: 15px;
}

.combo-name-input[hidden] {
  display: none;
}

.combo-panel,
.theme-panel {
  border: 1px solid var(--panel-border);
  background: rgba(5, 22, 27, 0.82);
}

.intro {
  width: min(100%, 740px);
  margin: 28px auto 14px;
  text-align: center;
}

.footer {
  padding-bottom: 0;
}

.settings-dialog {
  border-radius: 12px;
}

@media (max-width: 1180px) {
  .mixer-layout {
    grid-template-columns: 1fr;
    max-width: 980px;
  }

  .current-panel {
    position: relative;
    top: auto;
    order: -1;
    height: auto;
    min-height: 0;
  }

  .current-mix-list {
    flex: none;
    min-height: auto;
  }

  .current-empty {
    flex: none;
  }
}

@media (max-width: 640px) {
  .topbar {
    height: auto;
    min-height: 116px;
    flex-wrap: wrap;
    gap: 14px;
    padding: 16px;
  }

  .topbar h1 {
    font-size: 24px;
  }

  .pomodoro {
    position: static;
    order: 3;
    display: flex;
    width: 100%;
    justify-content: center;
    transform: none;
  }

  .timer-button {
    min-width: 104px;
    height: 42px;
    font-size: 28px;
  }

  .soft-button {
    width: 42px;
    height: 42px;
  }

  .tools {
    gap: 15px;
  }

  .content-scroll {
    height: calc(100dvh - 116px);
    padding: 14px 12px 24px;
  }

  .mixer-layout {
    gap: 12px;
  }

  .current-panel {
    padding: 16px;
  }

  .current-panel-header {
    align-items: center;
  }

  .current-panel-header h2 {
    font-size: 20px;
  }

  .current-mix-list {
    gap: 10px;
  }

  .current-panel.is-empty .current-mix-list {
    margin-bottom: 0;
  }

  .current-panel.is-empty .current-empty {
    min-height: 112px;
    padding: 14px;
  }

  .sound-section {
    display: block;
    padding: 18px 12px;
  }

  .sound-section:first-of-type {
    padding-top: 18px;
  }

  .sound-section h2 {
    justify-content: center;
    margin-bottom: 12px;
    padding-left: 0;
    text-align: center;
  }

  .sound-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
    width: 100%;
    gap: 10px;
  }

  .sound,
  .sound label {
    width: 100%;
    height: 96px;
  }

  .sound svg {
    width: 34px;
    height: 34px;
  }

  .sound label::after {
    padding: 0 3px;
    font-size: 10px;
    font-size: clamp(9px, 10cqi, 11px);
    line-height: 1.12;
  }

  .theme-panel {
    top: 80px;
    right: 12px;
    width: min(calc(100vw - 24px), 180px);
  }

  .combo-panel {
    position: fixed;
    top: 80px;
    right: 12px;
  }

  .settings-dialog {
    width: min(100%, 316px);
  }
}

@media (max-width: 360px) {
  .tools {
    gap: 11px;
  }

  .sound-grid {
    gap: 8px;
  }

  .sound,
  .sound label {
    height: 92px;
  }

  .sound label::after {
    font-size: 9px;
  }
}
