/* 플레이어 */
#playlist_bgm_box {
  display: none;
}
.playlist-player *::-webkit-scrollbar {
  display: none; /* Chrome에서 기본 스크롤바 제거 */
}
.playlist-player, .playlist-player * {
  font-family: var(--skin-default-font);
}
/* cm 스킨 - LED/digit 느낌의 --e-font 는 재생 시간 숫자 (#playlist-player-infos1/2) 에만 적용.
   제목/곡명/앨범 메타에 적용하면 숫자 부분이 LED 로 렌더되고 한글이 fallback 으로 떨어져 일관성 깨짐.
   나머지 텍스트는 base .playlist-player * { font-family: var(--skin-default-font) } 그대로 사용.
   FA 아이콘(<i class="fa-solid">) 은 자체 'Font Awesome 6 Free' 폰트를 쓰므로 절대 덮으면 안 됨. */
.playlist-player.skin-cm-default #playlist-player-infos1,
.playlist-player.skin-cm-diagonal #playlist-player-infos1,
.playlist-player.skin-cm-floating #playlist-player-infos1,
.playlist-player.skin-cm-sphere #playlist-player-infos1,
.playlist-player.skin-cm-default #playlist-player-infos2,
.playlist-player.skin-cm-diagonal #playlist-player-infos2,
.playlist-player.skin-cm-floating #playlist-player-infos2,
.playlist-player.skin-cm-sphere #playlist-player-infos2 {
  font-family: var(--e-font), var(--j-font), 'Freesentation5';
}
.playlist-player {
  position: fixed;
  bottom: 0;
  width: 100%;
  height: 70px;
  color: var(--skin-base-color);
  background: var(--skin-text-color);
  z-index: 1001;
  display: flex;
  justify-content: center;
  align-items: center;
  transition-duration: 0.6s;
  box-shadow: 0px -14px 50px -28px var(--skin-base-color);
}

/* 기타 설정 */
.playlist-player.colored {
  background: linear-gradient(to right, var(--skin-point-color), var(--skin-point-color-r-t));
  color: var(--skin-point-color-auto);
  backdrop-filter: blur(5px);
  box-shadow: 0px 0px 3px var(--skin-point-color);
  border-top: 1px solid var(--skin-point-color-t);
}
.playlist-player.colored #p_shadow,
.playlist-player.colored #p_shadow_btn,
.playlist-player.colored #v_shadow,
.playlist-player.colored #v_shadow_btn {
 background: var(--skin-text-color);
}

.lpp .playlist-player-thumb {
  position: absolute;
  width: 150px;
  height: 150px;
  bottom: 10px;
}
/* 대형(non-compact) LP 모드에서 디스크+바늘이 우측 컨트롤(timer/title)을 침범하지 않도록
   원래 flex 위치에서 살짝 좌측으로 nudge (좌측 끝까지 안 가고, 바늘만 비키게) */
.lpp:not(.compact) .playlist-player-thumb {
  transform: translateX(-50px);
}
.lpp:not(.compact) .playlist-player-title{
  opacity: 0;
}

.playlist-player.lpp .playlist-player-thumb {
  border-radius: 100% !important;
  overflow: visible;
}
.playlist-player.compact.lpp .playlist-player-thumb{
  overflow: visible;
}
.lpp.active .playlist-player-thumb-box {
  position: relative;
  animation: turntable 4s;
  animation-iteration-count: infinite;
  animation-timing-function: linear;
  border-radius: 100% !important;
}
.lpp .playlist-player-thumb-box {
  position: relative;
  border-radius: 100% !important;
}
.lpp .playlist-player-thumb-box::before {
  content: '';
  width: 10px;
  height: 10px;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  border-radius: 100%;
  background: black;
  position: absolute;
  border-radius: 100% !important;
}

.lpp .playlist-player-thumb::before {
  content: '';
  position: absolute;
  background: linear-gradient(45deg, var(--skin-base-color), var(--skin-base-color-d));
  height: 50px;
  width: 4px;
  display: block;
  bottom: 5px;
  z-index: 2;
  right: -10px;
  transition-duration: 0.5s;
  border-radius: 1px;
}
.lpp .playlist-player-thumb::after {
  content: '';
  position: absolute;
  background: linear-gradient(45deg, var(--skin-base-color), var(--skin-base-color-d));
  right: -12px;
  width: 8px;
  height: 14px;
  bottom: 0px;
  z-index: 2;
  border-radius: 2px;
  transition-duration: 0.5s;
}
.active.lpp .playlist-player-thumb::before {
  rotate: -20deg;
  transition-property: rotate, height;
  transition-delay: 0s, 0.4s;
  transform-origin: bottom;
}
.active.lpp .playlist-player-thumb::after {
  rotate: -20deg;
  transform-origin: center;
}
.lpp.compact .playlist-player-thumb::before{
  height: 40px;
  right: -9px;
}
.lpp.compact .playlist-player-thumb::after{
  right: -11px;
}
.lpp.compact .playlist-player-songinfo{
  align-items: center;
  user-select: none;
  flex: 1;
}
.lpp.compact.playlist-player .playlist-player-title{
  height: 100%;
  align-items: center;
}
.lpp.compact.playlist-player .playlist-player-title #p_title {
  height: 1.5em;
  align-content: center;
}
.lpp.compact.playlist-player .playlist-player-title #p_artist{
  -webkit-line-clamp: 1;
  display: flex;
  max-height: 1.5em;
  line-height: 1.5em;
}

.playlist-player.compact.lpp {
  width: 300px;
  height: 100px;
  border-radius: 15px;
}
.playlist-player.compact.lpp .playlist-player-thumb{
  width: 100px;
  height: 100px;
  top: -20px;
  left: 0;
}

.playlist-player.compact.lpp .playlist-player-inner {
  width: 100%;
  padding: 15px;
  justify-content: space-around;
  margin-left: 80px;
}
.playlist-player.compact.lpp .playlist-player-toggle-btn.skin-btn {
right: 12px;
top: 10px;
}
.playlist-player.compact.lpp .playlist-btn.skin-btn{
border-radius: 10px;
padding: 14px 18px;
}
@keyframes turntable {
  0% {
    transform: rotate(0deg);
  }
  100% {
    transform: rotate(360deg);
  }
}

@media all and (max-width: 650px) {
  .lpp .playlist-player-thumb {
    position: relative;
    width: 85px;
    height: 85px;
    bottom: 20px;
    left: -10px;
  }
}

@media all and (max-width: 540px) {
  .lpp .playlist-player-thumb {
    display: none;
  }
}

.p_square.playlist-player, 
.p_square.playlist-player.compact{
  border-radius: 0px;
}
.p_square.playlist-player * {
  border-radius: 0px;
}
.p_square.playlist-player .playlist-player-play-control .playlist-btn.skin-btn{
  border-radius: 0px;
}
.p_square.playlist-player.compact .playlist-player-thumb {
  border-radius: 0px;
}
.p_square.playlist-player .playlist-player-thumb{
  box-sizing: border-box;
  border: 1px solid;
}

.playlist-player.active.player-pulse::before {
  content: '';
  position: absolute;
  width: 100%;
  height: 100%;
  border: 1px solid var(--skin-text-color-t);
  animation: player-pulse 1.2s infinite ease-in;
  z-index: -1;
}
@keyframes player-pulse {
  0% {
    opacity: 1;
    width: 100%;
    height: 100%;
  }
  100% {
    opacity: 0;
    width: calc(100% + 20px);
    height: calc(100% + 20px);
  }
}
/* 기타 설정 여기까지 */

.playlist-player.top-player {
  top: 0;
  bottom: unset;
}

.playlist-player.disabled {
  pointer-events: none;
  opacity: 0;
  z-index: -99;
}

.playlist-player-inner {
  display: inline-flex;
  height: 50px;
}

.playlist-player-songinfo {
  display: flex;
  align-items: center;
  user-select: none;
}

.playlist-player-thumb {
  width: 45px;
  height: 45px;
  border-radius: 20px;
  overflow: hidden;
  transition-duration: 0.4s;
  position: relative;
}

.playlist-player .playlist-player-thumb:hover {
  background: rgba(0, 0, 0, 0.5);
}

.playlist-player-thumb-icon {
  width:100%;
  height:100%;
  font-size: 20px;
  opacity: 0;
  pointer-events: none;
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 0;
  position: absolute;
  color: white;
  transition: 0.6s;
}

.playlist-player-thumb:hover .playlist-player-thumb-icon{
  opacity: 1;
}

.playlist-player-thumb-box {
  position: relative;
  z-index: -1;
  background-size: cover;
  background-position: center;
  background-repeat: no-repeat;
  width: 100%;
  height: 100%;
}
.playlist-player-title {
  width: 130px;
  padding: 0px 10px;
  display: flex;
  flex-direction: column;
  justify-content: center;
}
.playlist-player-title #p_title {
  font-size: 13px;
  font-weight: bold;
  display: flex;
  max-height: 2em;
  overflow: hidden;
  line-height: 1em;
  align-items: center;
  display: -webkit-box;
  text-overflow: ellipsis;
  overflow: hidden;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  max-height: calc(1em* 2);
}
.playlist-player-title #p_artist {
  display: -webkit-box;
  font-size: 11px;
  opacity: 0.8;
  text-overflow: ellipsis;
  overflow: hidden;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  max-height: 2em;
  line-height: 1em;
}

.playlist-player-time {
  display: flex;
}

.playlist-player-time span {
  min-width: 60px;
  margin: 0px 10px;
  text-align: center;
  font-weight: bold;
}
.playlist-player-bar {
  position: relative;
  display: flex;
  height: 20px;
}

#p_shadow {
  top: 0;
  height: 4px;
  background: var(--skin-point-color);
  width: 0%;
  position: absolute;
  margin: 8px 0px;
  border-radius: 1px;
  pointer-events: none;
}

#p_shadow_btn {
  top: 0;
  width: 15px;
  height: 15px;
  background: var(--skin-point-color);
  position: absolute;
  margin: 2px 0px;
  border-radius: 5px;
  opacity: 0;
  pointer-events: none;
  transition-duration: 0.6s;
  transition-property: opacity;
}

.playlist-player-bar:hover #p_shadow_btn {
  opacity: 1;
}

.playlist-player-play-control {
  display: flex;
  justify-content: space-around;
}
#player-repeat-btn .fa-1 {
  display: none;
}
#player-repeat-btn.onlyone.active .fa-1 {
  display: flex;
  width: 12px;
  height: 12px;
  border-radius: 100%;
  font-size: 12px;
  scale: 0.5;
  padding: 4px;
  align-items: center;
  justify-content: center;
  position: absolute;
}
.playlist-player-play-control .playlist-btn.skin-btn {
  padding: 2px 21px;
  border-radius: 6px;
}

.playlist-player-play-control .playlist-btn:nth-child(3) {
  display: none;
}

.active .playlist-player-play-control .playlist-btn:nth-child(2){
  display: none;
}

.active .playlist-player-play-control .playlist-btn:nth-child(3){
  display: inline-flex;
}

.playlist-player-buttons {
  display: inline-flex;
  align-items: center;
}

.playlist-player-volume-box {
  display: flex;
  align-items: center;
  justify-content: center;
}

.playlist-player-volume {
  position: relative;
  display: flex;
  align-items: center;
  width: 63px;
  margin: 10px;
}

.playlist-volume {
  width: 100%;
}

#v_shadow {
  top: 0;
  height: 4px;
  background: var(--skin-point-color);
  width: 100%;
  position: absolute;
  border-radius: 1px;
  pointer-events: none;
}
#v_shadow_btn {
  top: -6px;
  width: 15px;
  height: 15px;
  background: var(--skin-point-color);
  position: absolute;
  margin: 0;
  border-radius: 5px;
  opacity: 0;
  pointer-events: none;
  transition-duration: 0.6s;
  transition-property: opacity;
  left: calc(100% - 7px);
}

.playlist-player-volume-box:hover #v_shadow_btn {
  opacity: 1;
}
/* 재생 위치 바 설정 */
.playlist-player input[type='range'] {
  background: transparent;
}

.playlist-player input[type='range']:focus {
  outline: none;
}

.playlist-player input[type='range'],
.playlist-player input[type='range']::-webkit-slider-runnable-track,
.playlist-player input[type='range']::-webkit-slider-thumb {
  -webkit-appearance: none;
}

.playlist-player input[type=range]::-webkit-slider-thumb {
  background-color: var(--skin-point-color);
  border: 1px solid var(--skin-point-color);
  border-radius: 100%;
  width: 15px;
  height: 15px;
  margin-top: -5px;
  margin-left: 0px;
  opacity: 0;
}

.playlist-player input[type=range]::-moz-range-thumb {
  background-color: var(--skin-point-color);
  border: 1px solid var(--skin-base-color);
  border-radius: 100%;
  width: 15px;
  height: 15px;
  opacity: 0;
}

.playlist-player input[type=range]::-ms-thumb {
  background-color: var(--skin-point-color);
  border: 1px solid var(--skin-base-color);
  border-radius: 100%;
  width: 15px;
  height: 15px;
  opacity: 0;
}

.playlist-player input[type=range]::-webkit-slider-runnable-track {
  background: var(--skin-base-color);
  height: 4px;
  border-radius: 5px;
}

.playlist-player input[type=range]:focus::-webkit-slider-runnable-track {
  outline: none;
}

.playlist-player input[type=range]::-moz-range-track {
  background: var(--skin-base-color);
  height: 4px;
  border-radius: 5px;
}

.playlist-player input[type=range]::-ms-track {
  background: var(--skin-base-color);
  height: 4px;
  border-radius: 5px;
}

.playlist-player input[type=range]::-ms-fill-lower {
  background: var(--skin-base-color);
}

.playlist-player input[type=range]::-ms-fill-upper {
  background: var(--skin-base-color);
}
.playlist-player input#playlist-player-progress {
  width: 100%;
}

.playlist-player-toggle-btn {
  position: absolute;
  right: 50px;
}
#player-clear-btn {
  opacity: 1;
}
#player-setting-btn {
  opacity: 1;
}
.compact #player-clear-btn{
  opacity: 0;
  pointer-events: none;
}
.compact #player-setting-btn{
  opacity: 0;
  pointer-events: none;
}
.compact #player-top-btn{
  opacity: 0;
  pointer-events: none;
}
.playlist-player-playlist {
  display: flex;
  position: absolute;
  z-index: 2;
  padding: 15px 20px;
  border-radius: 10px;
  justify-content: center;
  color: var(--skin-base-color);
  bottom: 100%;
  flex-direction: column;
  opacity: 0;
  pointer-events: none;
  translate: 0px 0px;
  transition-duration: 0.6s;
  overflow: auto;
  width: 220px;
  background: var(--skin-text-color);
  backdrop-filter: blur(5px);
  border-bottom: 1px solid;
}
.floatdown .playlist-player-playlist {
  top: 100%;
  bottom: unset;
}

.playlist-player-playlist.active {
  opacity: 1;
  pointer-events: auto;
  translate: 0px -10px;
}

.floatdown .playlist-player-playlist.active {
  translate: 0px 10px;
}
.player-songlist {
  width: 100%;
  max-height: 500px;
}
.player-song {
  display: flex;
  padding: 5px 0px;
  align-items: center;
  border-radius: 10px;
  transition-duration: 0.4s;
  cursor: pointer;
  max-height: 60px;
}
.player-song-info {
  user-select: none;
  display: flex;
  flex-direction: column;
  justify-content: center;
}
.player-song-number {
  width: 20px;
  text-align: center;
}
.player-song-title {
  font-size: 12px;
  font-weight: bold;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  word-break: keep-all;
  max-height: 1.5em;
  width: 130px;
}
.player-song:hover .player-song-title {
  color: var(--skin-point-color);
}
.player-song.active {
  background: var(--skin-base-color);
  color: var(--skin-text-color);
}

.player-song-artist {
  font-size: 11px;
  opacity: 0.8;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  word-break: keep-all;
  max-height: 1.5em;
  width: 130px;
}
.player-song:hover {
  translate: 3px 0px;
  background: var(--skin-point-color-t);
}
.player-song-thumb {
  width: 30px;
  height: 30px;
  border-radius: 8px;
  margin: 0px 15px;
  background-size: cover;
  background-position: center;
}

/* 앨범 섹션 — 헤더(현재 앨범) + 펼침형 picker. 컬러 swap (배경=base / 글자=text). */
.player-albumlist {
  display: flex;
  flex-direction: column;
  margin-bottom: 8px;
  padding-bottom: 8px;
  border-bottom: 1px dashed currentColor;
  gap: 2px;
}
.player-album {
  display: flex;
  align-items: center;
  padding: 5px 0;
  border-radius: 10px;
  cursor: pointer;
  transition-duration: 0.4s;
  background: var(--skin-base-color);
  color: var(--skin-text-color);
  max-height: 60px;
  position: relative;
}
.player-album:hover {
  translate: 3px 0px;
  background: var(--skin-point-color);
  color: var(--skin-base-color);
}
.player-album.current {
  /* 현재 앨범 헤더 — 클릭 시 picker 토글 */
}
.player-album-thumb {
  width: 30px;
  height: 30px;
  border-radius: 8px;
  margin: 0px 15px;
  background-size: cover;
  background-position: center;
  flex-shrink: 0;
}
.player-album-info {
  user-select: none;
  display: flex;
  flex-direction: column;
  justify-content: center;
}
.player-album-title {
  font-size: 12px;
  font-weight: bold;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  max-height: 1.5em;
  width: 130px;
}
.player-album-meta {
  font-size: 10px;
  opacity: 0.8;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  max-height: 1.5em;
  width: 130px;
}
.player-album-caret {
  position: absolute;
  right: 10px;
  top: 50%;
  transform: translateY(-50%);
  font-size: 11px;
  opacity: 0.7;
  transition: transform 0.3s ease;
  pointer-events: none;
}
.player-albumlist.open .player-album.current .player-album-caret {
  transform: translateY(-50%) rotate(180deg);
}
/* 다른 앨범 — 기본 접힘, .open 시 펼침. overflow 항상 hidden 으로 두어 transition 중 scrollbar 출현 안 함 (펼침/접힘 대칭). */
.player-album-others {
  display: flex;
  flex-direction: column;
  gap: 2px;
  max-height: 0;
  overflow: hidden;
  transition: max-height 0.3s cubic-bezier(0.4, 0, 0.2, 1), margin-top 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  margin-top: 0;
}
.player-albumlist.open .player-album-others {
  max-height: 240px;
  margin-top: 4px;
}

.playlist-player .error_window {
  position: absolute;
  pointer-events: none;
  z-index: 2;
  padding: 15px 20px;
  border-radius: 10px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--skin-text-color-auto);
  color: var(--skin-text-color);
  border: 1px solid;
  bottom: calc(100% + 10px);
  opacity: 0;
  animation: slide_up 2s;
}
.playlist-player.floatdown .error_window{
  top: calc(100% + 10px);
  bottom: unset;
  animation: slide_down 2s;
}
@keyframes slide_up {
  0% {
    translate: 0px 0px;
    opacity: 0;
  }
  70% {
    translate: 0px -30px;
    opacity: 1;
  }
  100% {
    translate: 0px -30px;
    opacity: 0;
  }
}
@keyframes slide_up_remain {
  0% {
    translate: 0px 0px;
    opacity: 0;
  }
  100% {
    translate: 0px -30px;
    opacity: 1;
  }
}
@keyframes slide_down {
  0% {
    translate: 0px 0px;
    opacity: 0;
  }
  70% {
    translate: 0px 30px;
    opacity: 1;
  }
  100% {
    translate: 0px 30px;
    opacity: 0;
  }
}

/* 플레이어 여기까지 */

/* 설정 창 */
.player-setting-window-wrapper {
  width: 0px;
  height: 0px;
  position: absolute;
  left: 100px;
}
.player-setting-window {
  position: absolute;
  width: 140px;
  border-radius: 20px;
  padding: 10px;
  box-sizing: border-box;
  flex-wrap: wrap;
  bottom: 10px;
  left: -50px;
  color: var(--skin-base-color);
  background: var(--skin-text-color);
  animation: slide_up_remain 0.4s;
  display: none;
  animation-fill-mode: forwards;
  flex-direction: column;
  align-items: center;
  align-content: center;
}
.floatdown .player-setting-window {
  top: 50px;
  bottom: unset;
  animation: slide_down 0.4s;
}
.player-setting-window .setting-btn {
  padding: 0px;
  width: 30px;
  height: 30px;
  margin: 0;
  box-sizing: border-box;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  margin: 5px;
  position: relative;
  font-size: 18px;
}
.player-setting-window .setting-btn.active {
  border: 3px double var(--skin-point-color);
}
.player-hover-text {
  display: none;
  position: absolute;
  padding: 2px 10px;
  font-size: 12px;
  word-wrap: normal;
  word-break: keep-all;
  background: var(--skin-base-color);
  color: var(--skin-text-color);
  animation: slide_up_remain 0.4s;
  animation-fill-mode: forwards;
  top: 0;
  pointer-events: none;
  white-space: nowrap;
}
.player-setting-window .skin-btn:hover .player-hover-text{
  display: block;
}
/* 설정 창 여기까지 */

/* 컴팩트 플레이어 */
.playlist-player.compact {
  position: fixed;
  width: 270px;
  border-radius: 30px;
  height: 70px;
  left: calc(50% - 135px);
  bottom: 30px;
  transition-property: width, height, color, background, background-image;
  box-shadow: 1px 2px 15px 0px rgba(0, 0, 0, 0.3);
}
.playlist-player.compact .skin-btn {
  width: 24px;
  height: 24px;
  box-sizing: border-box;
  margin: 3px;
  padding: 0px;
}
.playlist-player.compact .playlist-player-inner {
  width: 100%;
  flex-direction: column;
  padding: 0px 10px;
  box-sizing: border-box;
  height: 100%;
  justify-content: center;
  align-items: center;
  margin-left: 20px;
}
.playlist-player.compact .playlist-player-control {
  width: 130px;
}
.playlist-player.compact .playlist-btn.skin-btn {
  width: 32px;
  border-radius: 7px;
}
.playlist-player.compact .playlist-player-thumb {
  width: 60px;
  height: 60px;
  border-radius: 25px;
  overflow: hidden;
  margin: 10px;
  position: absolute;
  left: -4px;
  top: -5px;
}

.playlist-player.compact .playlist-player-title {
  font-size: 10px;
  padding: 0;
  width: 100px;
  height: 20px;
  text-align: center;
}
.playlist-player.compact .playlist-player-title #p_title {
  font-size: 9px;
  text-overflow: ellipsis;
  word-break: keep-all;
  width: 100px;
  white-space: nowrap;
  overflow: hidden;
  align-items: center;
  min-width: 0;
  display: inline-block;
}

.playlist-player.compact .playlist-player-title #p_artist {
  display: none;
}

.playlist-player.compact .playlist-player-time span {
  font-size: 9px;
  min-width: 30px;
  margin: 0;
}

.playlist-player.compact span#playlist-player-infos1,
.playlist-player.compact span#playlist-player-infos2 {
  display:none;
}
.playlist-player.compact .playlist-player-toggle-btn.skin-btn {
  right: 14px;
  top: 18px;
}
.playlist-player.compact .playlist-player-play-control {
  margin-top: 1px;
}
.playlist-player.compact .playlist-player-buttons {
  display: none;
}

.playlist-player.compact .playlist-player-volume-box {
  display: none;
}
.playlist-player.compact .playlist-player-bar {
  margin: 2px 0px;
  height: 4px;
}
.playlist-player.compact #p_shadow {
  margin: 0;
}
.playlist-player.compact #p_shadow_btn {
  top: -3px;
  width: 10px;
  height: 10px;
  margin: 0;
}

.playlist-player.top-player.compact {
  top: 30px;
}
/* 컴팩트 버전 여기까지 */

/* 모바일 */
@media all and (max-width: 900px) {
  .playlist-player-toggle-btn{
    opacity: 0;
    pointer-events: none;
  }
  
  #player-top-btn {
    display: none;
  }
  #player-clear-btn {
    display: none;
  }
  #player-setting-btn {
    display: none;
  }
}

@media all and (max-width: 650px) {
  .playlist-player-title {
    display:none;
  }
  .playlist-player-volume-box {
    display:none;
  }
}

@media all and (max-width: 480px) {
  .playlist-player-buttons {
    display:none;
  }
}

@media all and (max-width: 350px) {
  .playlist-player-thumb {
    display: none;
  }
}

/* ===== 플레이어 스킨 5종 dropdown ===== */
.player-skin-picker-btn {
  position: relative;
}
.player-skin-picker {
  display: none;
  position: absolute;
  /* 위로 열림 — 설정 창이 보통 화면 하단부에 있어 dropdown이 아래로 가면 잘림 */
  bottom: calc(100% + 6px);
  top: auto;
  left: 50%;
  transform: translateX(-50%);
  margin: 0;
  background: var(--skin-base-color);
  color: var(--skin-text-color);
  border: 1px solid var(--skin-text-color);
  border-radius: 8px;
  padding: 4px;
  min-width: 140px;
  /* 부모 overflow:hidden을 뚫고 화면 위에 떠야 하므로 z-index 큼 */
  z-index: 10000;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.2);
  flex-direction: column;
  gap: 2px;
}
.player-skin-picker.open {
  display: flex;
}
.player-skin-option {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 6px 10px;
  border-radius: 4px;
  cursor: pointer;
  font-size: 12px;
  white-space: nowrap;
}
.player-skin-option:hover {
  background: var(--skin-text-color);
  color: var(--skin-base-color);
}
.player-skin-option.active {
  background: var(--skin-point-color, var(--skin-text-color));
  color: var(--skin-base-color);
  font-weight: bold;
}
.player-skin-option i {
  width: 14px;
  text-align: center;
}

/* ===== cm 스킨 위치 picker dropdown (skin picker와 동일 스타일) ===== */
.cm-position-picker-btn {
  position: relative;
}
.cm-position-picker {
  display: none;
  position: absolute;
  bottom: calc(100% + 6px);
  top: auto;
  left: 50%;
  transform: translateX(-50%);
  margin: 0;
  background: var(--skin-base-color);
  color: var(--skin-text-color);
  border: 1px solid var(--skin-text-color);
  border-radius: 8px;
  padding: 4px;
  min-width: 140px;
  z-index: 10000;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.2);
  flex-direction: column;
  gap: 2px;
}
.cm-position-picker.open {
  display: flex;
}
/* cm-pos-tl/tr (player 가 상단 anchor) 일 땐 picker 가 위로 열리면 viewport 위로 잘림 → 아래로 열리게 flip */
.playlist-player.cm-pos-tl .player-skin-picker,
.playlist-player.cm-pos-tr .player-skin-picker,
.playlist-player.cm-pos-tl .cm-position-picker,
.playlist-player.cm-pos-tr .cm-position-picker {
  bottom: auto;
  top: calc(100% + 6px);
}
.cm-position-option {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 6px 10px;
  border-radius: 4px;
  cursor: pointer;
  font-size: 12px;
  white-space: nowrap;
}
.cm-position-option:hover {
  background: var(--skin-text-color);
  color: var(--skin-base-color);
}
.cm-position-option.active {
  background: var(--skin-point-color, var(--skin-text-color));
  color: var(--skin-base-color);
  font-weight: bold;
}
.cm-position-option i {
  width: 14px;
  text-align: center;
}

/* ================================================================
   custommenu 이식 4종 스킨 — 원본 1:1 라인포팅

   셀렉터 매핑:
     .cm-player                → .playlist-player.skin-cm-NAME
     .cm-player-thumb          → .playlist-player-thumb
     .cm-player-thumb-box      → .playlist-player-thumb-box
     .cm-player-info-box       → .playlist-player-title
     #cm_p_title               → #p_title
     .cm-player-control-box    → .playlist-player-play-control
     .cm-player-btn (control)  → .playlist-player-play-control .playlist-btn
     .cm-player-mini-btn       → .playlist-player-buttons .playlist-btn
                                 (.buttons는 absolute로 .play-control 영역 위에 spread)
     .cm-player-info           → .playlist-player-time
     .cm-player-bar            → .playlist-player-bar
     #cm_p_shadow              → #p_shadow
     #cm-player-progress       → #playlist-player-progress
     #cm-player-infos1/2       → #playlist-player-infos1/2
     .cm-player-header         → toggle 버튼 (#player-clear-btn / #player-setting-btn)
     .cm-player-deco/.xmark    → ::before/::after 4개 (sphere)

   색상: --song-color1 → --skin-text-color, --song-color2 → --skin-base-color
         (player.js:applyCmSkinColors 가 곡별 dynamic override)
   ================================================================ */

/* ====== 공통: cm 스킨 활성 시 baseline 무력화 + 마크업 평탄화 ====== */
.playlist-player.skin-cm-default,
.playlist-player.skin-cm-diagonal,
.playlist-player.skin-cm-floating,
.playlist-player.skin-cm-sphere {
  background: transparent;
  box-shadow: none;
  border-top: none;
  width: auto;
  height: auto;
  bottom: auto;
  /* 컨테이너 폰트는 한글 친화 default — LED/digit 느낌의 --e-font 는 #playlist-player-infos1/2 (재생 시간) 에만 적용 */
  font-family: var(--skin-default-font);
}
/* cm 스킨 + .colored 토글 시 base .playlist-player.colored 의 backdrop-filter blur, gradient bg 등 차단
   (cm 스킨은 backdrop blur 효과가 의도된 디자인이 아님 — per-song color override만 사용).
   cm-floating 은 자체 border 1px 가 있으므로 border-top: none 제외. cm-default/diagonal/sphere 만 border-top 차단. */
.playlist-player.skin-cm-default.colored,
.playlist-player.skin-cm-diagonal.colored,
.playlist-player.skin-cm-floating.colored,
.playlist-player.skin-cm-sphere.colored {
  backdrop-filter: none !important;
  -webkit-backdrop-filter: none !important;
  background: transparent !important;
  box-shadow: none !important;
}
.playlist-player.skin-cm-diagonal.colored,
.playlist-player.skin-cm-sphere.colored {
  border-top: none !important;
}
/* cm-floating / cm-default 는 자체 박스(170x260 / 220x240)를 가지므로 colored 라도 base bg 유지.
   transparent 면 player 영역이 사라져 thumb/list 만 떠있어 보임. */
.playlist-player.skin-cm-floating.colored,
.playlist-player.skin-cm-default.colored {
  background: var(--skin-base-color) !important;
}
.playlist-player.skin-cm-default .playlist-player-thumb-icon,
.playlist-player.skin-cm-diagonal .playlist-player-thumb-icon,
.playlist-player.skin-cm-floating .playlist-player-thumb-icon,
.playlist-player.skin-cm-sphere .playlist-player-thumb-icon {
  display: none;
}
.playlist-player.skin-cm-default .playlist-player-volume-box,
.playlist-player.skin-cm-diagonal .playlist-player-volume-box,
.playlist-player.skin-cm-floating .playlist-player-volume-box,
.playlist-player.skin-cm-sphere .playlist-player-volume-box {
  display: none;
}
.playlist-player.skin-cm-default #player-mute-btn,
.playlist-player.skin-cm-diagonal #player-mute-btn,
.playlist-player.skin-cm-floating #player-mute-btn,
.playlist-player.skin-cm-sphere #player-mute-btn {
  display: none !important;
}
/* 토글 버튼(✕/⋯) — 원본 .cm-player-header .cm-player-btn 매핑 */
.playlist-player.skin-cm-default .playlist-player-toggle-btn,
.playlist-player.skin-cm-diagonal .playlist-player-toggle-btn,
.playlist-player.skin-cm-floating .playlist-player-toggle-btn,
.playlist-player.skin-cm-sphere .playlist-player-toggle-btn {
  position: absolute !important;
  background: var(--skin-base-color);
  color: var(--skin-text-color);
  border: none !important;
  border-radius: 5px !important;
  width: 24px !important;
  height: 24px !important;
  min-width: 0 !important;
  padding: 0 !important;
  font-size: 12px !important;
  display: inline-flex !important;
  align-items: center;
  justify-content: center;
  left: auto !important;
  right: auto !important;
  top: auto !important;
  bottom: auto !important;
  pointer-events: visible !important;
  z-index: 100;
}
/* cm 스킨 — top-btn 은 항상 숨김. clear/compact 는 4종 모두 list-toggle/minimize 로 재활용. */
.playlist-player.skin-cm-default #player-top-btn,
.playlist-player.skin-cm-diagonal #player-top-btn,
.playlist-player.skin-cm-floating #player-top-btn,
.playlist-player.skin-cm-sphere #player-top-btn {
  display: none !important;
}
/* cm-sphere 의 compact-btn 은 원본 '최소화' 버튼 (3rd btn) 으로 재활용 — cm_minimize_or_float 디스패처가 cm-hidden 토글 */
/* 설정 창 — 트리거(⋯) 바로 아래 */
.playlist-player.skin-cm-default .player-setting-window-wrapper,
.playlist-player.skin-cm-diagonal .player-setting-window-wrapper,
.playlist-player.skin-cm-floating .player-setting-window-wrapper,
.playlist-player.skin-cm-sphere .player-setting-window-wrapper {
  position: absolute !important;
  width: 0 !important;
  height: 0 !important;
  top: 35px !important;
  right: 47px !important;
  left: auto !important;
  bottom: auto !important;
  z-index: 10000;
}
.playlist-player.skin-cm-default .player-setting-window,
.playlist-player.skin-cm-diagonal .player-setting-window,
.playlist-player.skin-cm-floating .player-setting-window,
.playlist-player.skin-cm-sphere .player-setting-window {
  position: absolute !important;
  top: 0 !important;
  right: 0 !important;
  bottom: auto !important;
  left: auto !important;
  width: 160px !important;
  background: var(--skin-base-color);
  color: var(--skin-text-color);
  border: 1px solid var(--skin-text-color);
  border-radius: 12px;
  padding: 10px;
  box-shadow: 0 6px 18px rgba(0, 0, 0, 0.25);
  animation: slide_up_remain 0.3s;
  animation-fill-mode: forwards;
}
/* cm-default — 170 wide 좁은 player. setting btn 가운데(left:73). wrapper 좌측 5 부터 width 160 (player width 안 fit). */
.playlist-player.skin-cm-default .player-setting-window-wrapper {
  top: 35px !important;
  left: 5px !important;
  right: auto !important;
}
.playlist-player.skin-cm-default .player-setting-window {
  left: 0 !important;
  right: auto !important;
}

/* cm-diagonal — setting btn 이 좌상단 (top:15 left:80) 이라 wrapper / window 도 left 기준으로 재배치. */
.playlist-player.skin-cm-diagonal .player-setting-window-wrapper {
  top: 50px !important;
  left: 80px !important;
  right: auto !important;
  pointer-events: visible !important;     /* player container pointer-events: none 차단 — 안 그러면 클릭이 뒤의 thumb(view_playlist onclick) 로 통과해 리스트 열림 */
}
.playlist-player.skin-cm-diagonal .player-setting-window {
  left: 0 !important;
  right: auto !important;
  pointer-events: visible !important;
}
.playlist-player.skin-cm-diagonal .player-setting-window .setting-btn,
.playlist-player.skin-cm-diagonal .player-setting-window .skin-btn {
  pointer-events: visible !important;
}

/* ================================================================
   1. cm-default — 좌측 하단 세로 패널 (170 x 260) — bottom-left config
   ================================================================ */
.playlist-player.skin-cm-default {
  width: 170px;
  height: 260px;
  color: var(--skin-text-color);
  background: var(--skin-base-color);
  overflow: hidden;            /* 원본 .cm-player overflow:hidden — border-radius 코너에서 thumb 잘리게 */
  font-family: var(--skin-default-font);
  box-shadow: 0 2px 6px rgba(0,0,0,0.1);
  position: fixed;
  border: 1px solid var(--skin-text-color);
  bottom: 0;
  left: 50px;
  border-bottom: 0;
  border-radius: 10px 10px 0 0;
  display: flex;
  flex-direction: column;
  justify-content: flex-start;
  align-items: stretch;
  animation: hii 1s;
  transition: 0.5s;
}
.playlist-player.skin-cm-default .playlist-player-inner,
.playlist-player.skin-cm-default .playlist-player-songinfo,
.playlist-player.skin-cm-default .playlist-player-thumb,
.playlist-player.skin-cm-default .playlist-player-control {
  display: contents;
}
.playlist-player.skin-cm-default .playlist-player-thumb-box   { order: 1; }
.playlist-player.skin-cm-default .playlist-player-title       { order: 2; }
.playlist-player.skin-cm-default .playlist-player-play-control { order: 3; }
.playlist-player.skin-cm-default .playlist-player-time        { order: 4; }
.playlist-player.skin-cm-default .playlist-player-thumb-box {
  width: 100%;
  aspect-ratio: 1 / 1;
  background-color: var(--skin-text-color);
  background-size: cover;
  background-position: center;
}
.playlist-player.skin-cm-default .playlist-player-title {
  padding: 8px 6px !important;             /* 좌우 6 — text area = 170-12=158, 거의 풀 너비 */
  text-align: center;
  font-size: 14px;
  font-weight: bold;
  height: 30px !important;                 /* outer 30 = padding 8+8 + content 14 (border-box) */
  line-height: 14px;
  overflow: hidden;
  white-space: nowrap;
  text-overflow: ellipsis;
  display: block;
  width: auto !important;                  /* base .playlist-player-title { width: 130 } 차단 — flex stretch 로 player 너비 (170) 채움 */
  box-sizing: border-box !important;       /* padding 안쪽 — content area = 158 wide, 14 tall */
}
.playlist-player.skin-cm-default #p_title { display: block; }
.playlist-player.skin-cm-default #p_artist { display: none; }
.playlist-player.skin-cm-default .playlist-player-play-control {
  display: flex;
  align-items: center;
  justify-content: space-around;
  padding: 6px 0;          /* 원본 .cm-player-control-box padding: 6 0 — 6 버튼 (shuffle/prev/play/pause/next/repeat) 한 컨테이너 안에 space-around 로 자연 분배 */
  position: relative;
  box-sizing: border-box;
}
.playlist-player.skin-cm-default .playlist-player-play-control .playlist-btn {
  font-size: 14px !important;
  line-height: 1 !important;        /* shuffle/repeat 와 동일 metrics — line-height 차이로 인한 baseline 어긋남 차단 */
  padding: 4px 6px !important;
  cursor: pointer;
  background: transparent !important;
  color: inherit !important;
  border: none !important;
  border-radius: 0 !important;
  width: auto !important;
  height: 22px !important;          /* 14 + padding 4+4 — 명시해 shuffle/repeat 와 정확히 동일 outer height 보장 */
  min-width: 0 !important;
  margin: 0 !important;
  box-shadow: none !important;
  display: inline-flex !important;
  align-items: center !important;
  justify-content: center !important;
  box-sizing: content-box !important;  /* 22 = font 14 + padding 4+4 (content-box). border-box 면 content 가 6 으로 줄어 icon 짤림 */
}
.playlist-player.skin-cm-default .playlist-player-play-control .playlist-btn i {
  line-height: 1 !important;
}
/* play/pause 토글 복원 — base 룰 (.playlist-player-play-control .playlist-btn:nth-child(3) {display:none}) 이 위 inline-flex !important 에 묻혔으니 cm-default 에서 명시 재선언 */
.playlist-player.skin-cm-default .playlist-player-play-control .playlist-btn:nth-child(3) {
  display: none !important;
}
.playlist-player.skin-cm-default.active .playlist-player-play-control .playlist-btn:nth-child(2) {
  display: none !important;
}
.playlist-player.skin-cm-default.active .playlist-player-play-control .playlist-btn:nth-child(3) {
  display: inline-flex !important;
}
.playlist-player.skin-cm-default .playlist-player-time {
  display: flex;
  align-items: center;
  justify-content: space-between;
  font-size: 11px;
  padding: 0 10px;
  height: 24px;
  box-sizing: content-box !important;
}
/* base .playlist-player-time span { min-width: 60; margin: 0 10 } 차단 — 원본 #cm-player-infos1/2 는 그냥 자연 너비 */
.playlist-player.skin-cm-default #playlist-player-infos1,
.playlist-player.skin-cm-default #playlist-player-infos2 {
  font-size: 11px;
  color: var(--skin-text-color);
  min-width: 0 !important;
  margin: 0 !important;
  text-align: center;
}
.playlist-player.skin-cm-default .playlist-player-bar {
  width: 70px;
  box-sizing: border-box;
  position: relative;
  background: var(--skin-base-color);
  flex: none;
}
/* 투명 overlay range input — 클릭/드래그로 재생 위치 조작 가능. visual 은 #p_shadow 가 표현. */
.playlist-player.skin-cm-default #playlist-player-progress {
  display: block; position: absolute; top: 0; left: 0; width: 100%; height: 100%;
  margin: 0; padding: 0; opacity: 0; cursor: pointer; z-index: 2;
  -webkit-appearance: none; appearance: none; background: transparent; pointer-events: auto;
}
.playlist-player.skin-cm-default #p_shadow {
  position: absolute;
  top: 50%;
  left: 0;
  height: 4px;
  transform: translateY(-50%);
  background: var(--skin-text-color);
  z-index: 1;
  border-radius: 2px;
  margin: 0 !important;       /* base #p_shadow margin:8 0 차단 — 안 그러면 바 안쪽에서 8px 아래로 밀려나 시간 줄 밖으로 빠짐 */
}
/* 핸들도 명시적으로 — base 의 margin:2 0 / top:0 차단해서 바 안에 vertical center */
.playlist-player.skin-cm-default #p_shadow_btn {
  position: absolute;
  width: 10px !important;
  height: 10px !important;
  border-radius: 50% !important;
  background: var(--skin-text-color);
  top: 50% !important;
  margin: 0 !important;
  transform: translateY(-50%);
  pointer-events: none;
}
/* 원본 cm-default: header position absolute, width calc(100% - 10px), top:5 left:5 right:5, flex space-between, 2 btns (bars + minimize), 24x24 border-radius:5 bg color2 color color1.
   우리는 setting(⋯) 추가 → 3 버튼 24x24, top:5, left 5 / center / right 5. */
.playlist-player.skin-cm-default #player-clear-btn,
.playlist-player.skin-cm-default #player-setting-btn,
.playlist-player.skin-cm-default #player-compact-btn {
  display: inline-flex !important;
  position: absolute !important;
  top: 5px !important;
  bottom: auto !important;
  width: 24px !important;
  height: 24px !important;
  min-width: 0 !important;
  border: none !important;
  border-radius: 5px !important;
  rotate: 0deg !important;
  box-shadow: none !important;
  margin: 0 !important;
  padding: 0 !important;
  background: var(--skin-base-color) !important;
  color: var(--skin-text-color) !important;
  font-size: 12px !important;
  z-index: 99 !important;
  align-items: center !important;
  justify-content: center !important;
  pointer-events: visible !important;
}
.playlist-player.skin-cm-default #player-clear-btn:hover,
.playlist-player.skin-cm-default #player-setting-btn:hover,
.playlist-player.skin-cm-default #player-compact-btn:hover {
  background: var(--skin-text-color) !important;
  color: var(--skin-base-color) !important;
  translate: 0 0 !important;
  box-shadow: none !important;
}
.playlist-player.skin-cm-default #player-clear-btn i,
.playlist-player.skin-cm-default #player-setting-btn i,
.playlist-player.skin-cm-default #player-compact-btn i {
  rotate: 0deg !important;
}
/* X 아이콘 → bars (원본 cm-player-header 1번 버튼은 list toggle) */
.playlist-player.skin-cm-default #player-clear-btn i.fa-xmark::before {
  content: "\f0c9";
  font-size: 12px;
}
/* 위치 — bars left:5, setting 중앙(170/2-12=73), minimize right:5 */
.playlist-player.skin-cm-default #player-clear-btn   { left: 5px !important;   right: auto !important; }
.playlist-player.skin-cm-default #player-setting-btn { left: 73px !important;  right: auto !important; }
.playlist-player.skin-cm-default #player-compact-btn { left: auto !important;  right: 5px !important; }

/* top config (cm-pos-tl/tr) — 원본 default.php inline 매핑: $vertical='top' 일 때 .cm-player-header { bottom: 5 } 로 헤더가 하단으로.
   flex-direction: column-reverse 라 thumb 가 하단에 있고 헤더가 그 위에 overlay → time/play/title 영역은 깨끗. */
.playlist-player.skin-cm-default.cm-pos-tl #player-clear-btn,
.playlist-player.skin-cm-default.cm-pos-tl #player-setting-btn,
.playlist-player.skin-cm-default.cm-pos-tl #player-compact-btn,
.playlist-player.skin-cm-default.cm-pos-tr #player-clear-btn,
.playlist-player.skin-cm-default.cm-pos-tr #player-setting-btn,
.playlist-player.skin-cm-default.cm-pos-tr #player-compact-btn {
  top: auto !important;
  bottom: 5px !important;
}
/* list 패널 top padding 도 top config 에선 bottom padding 으로 — 헤더가 하단으로 갔으니 */
.playlist-player.skin-cm-default.cm-pos-tl .playlist-player-playlist,
.playlist-player.skin-cm-default.cm-pos-tr .playlist-player-playlist {
  padding: 0 0 34px 0 !important;
}

/* 원본 .cm-player-list — position absolute, left:0 top:0, width 100% height 100%, overflow auto, pointer-events none → unset on .active.
   base .playlist-player-playlist 의 bottom:100% / display:flex / backdrop-filter 차단.
   z-index: shuffle/repeat (5) 보다 위, header 버튼 (99) 보다 아래 — 활성 시 shuffle/repeat 가 list 뒤로 가려지고 헤더는 유지.
   padding-top: 34 — 헤더 버튼 (top:5 height:24, 즉 y=5~29) 영역 비워 첫 항목 (현재 앨범) 이 헤더 뒤로 가려지지 않게. */
.playlist-player.skin-cm-default .playlist-player-playlist {
  position: absolute !important;
  left: 0 !important;
  top: 0 !important;
  bottom: auto !important;
  width: 100% !important;
  height: 100% !important;
  max-height: none !important;
  z-index: 50;
  overflow: auto;
  background: var(--skin-base-color) !important;
  backdrop-filter: none !important;
  -webkit-backdrop-filter: none !important;
  border: none !important;
  border-radius: 0 !important;
  padding: 34px 0 0 0 !important;
  box-sizing: border-box !important;
  display: block !important;
  opacity: 0;
  pointer-events: none;
  translate: 0 0 !important;
  transition: opacity 0.3s ease;
  color: var(--skin-text-color);
}
.playlist-player.skin-cm-default .playlist-player-playlist.active {
  opacity: 1;
  pointer-events: auto;
  translate: 0 0 !important;
}
/* 앨범 섹션은 보임 — 사용자 요청: list 최상단에 현재 앨범이 보여야 함 */
.playlist-player.skin-cm-default .player-songlist {
  display: flex;
  flex-direction: column;
  max-height: none;
  width: 100%;
  padding: 0;
  margin: 0;
}
/* 원본 .cm-song { flex align-items center, padding:5 20, height:30, overflow hidden, hover color swap } */
.playlist-player.skin-cm-default .player-song {
  display: flex !important;
  align-items: center;
  padding: 5px 20px;
  height: 30px;
  overflow: hidden;
  background: transparent;
  color: var(--skin-text-color);
  margin: 0;
  border-radius: 0;
  cursor: pointer;
  transition: 0.4s;
  max-height: none;
  flex: 0 0 auto;
  box-sizing: content-box;
}
.playlist-player.skin-cm-default .player-song:hover,
.playlist-player.skin-cm-default .player-song.active {
  color: var(--skin-base-color);
  background: var(--skin-text-color);
  translate: 0 0;
}
/* 원본 .cm-song-thumb 30x30 border-radius:5 */
.playlist-player.skin-cm-default .player-song-thumb {
  display: inline-flex !important;
  width: 30px;
  height: 30px;
  border-radius: 5px;
  overflow: hidden;
  margin: 0;
  flex-shrink: 0;
  background-size: cover;
  background-position: center;
}
.playlist-player.skin-cm-default .player-song-number,
.playlist-player.skin-cm-default .player-song-artist {
  display: none !important;
}
/* 원본 .cm-song-name flex 1 margin-left:10 ellipsis */
.playlist-player.skin-cm-default .player-song-info {
  flex: 1 1 auto;
  margin-left: 10px;
  width: auto;
  min-width: 0;
  overflow: hidden;
}
.playlist-player.skin-cm-default .player-song-title {
  flex: 1 1 auto;
  white-space: nowrap;
  text-overflow: ellipsis;
  overflow: hidden;
  width: auto;
  min-width: 0;
  max-width: 100%;
  font-size: 14px;
  font-weight: normal;
  height: auto;
  line-height: 1.2;
  display: block;
}
/* list 최상단부터 시작 — 헤더 버튼 (z 99) 이 그 위로 떠 있으니 마진으로 비울 필요 없음 */
/* scrollbar 숨김 */
.playlist-player.skin-cm-default .playlist-player-playlist::-webkit-scrollbar { display: none; }
.playlist-player.skin-cm-default .playlist-player-playlist { scrollbar-width: none; }
/* album dropdown max-height 는 위쪽 공통 룰에서 처리. */
/* album title/meta 자연 높이 + line-height 명시 — base max-height 1.5em / .player-album max-height:60 이 한글 베이스라인+descender 함께 고려 안 돼서 메타 하단 잘림.
   max-height 제거하고 nowrap + ellipsis 만 유지. */
.playlist-player.skin-cm-default .player-album-title,
.playlist-player.skin-cm-default .player-album-meta {
  line-height: 1.4 !important;
  max-height: none !important;
  height: auto !important;
}
.playlist-player.skin-cm-default .player-album {
  max-height: none !important;     /* base 60px 도 메타 잘림 원인 가능 — auto */
  align-items: center;
}
/* 마지막 album 의 메타 잘림 방지 — list 패널 하단 padding 추가해 스크롤 여유 공간 */
.playlist-player.skin-cm-default .player-albumlist {
  margin-bottom: 12px;
}

/* hii — bottom-left config: bottom: -100% → 0 슬라이드인 (원본 default.php inline) */
@keyframes hii {
  0%   { bottom: -100%; }
  100% { bottom: 0; }
}

/* ================================================================
   2. cm-diagonal — 비대칭 대각선 (skewX) (290 x 302) — bottom-left config
   ================================================================ */
.playlist-player.skin-cm-diagonal {
  width: 290px;
  height: 302px;
  position: fixed;
  transition: all 0.3s ease;
  z-index: 2;
  font-family: var(--skin-default-font);
  pointer-events: none;
  bottom: -1px;
  left: 70px;
  background: transparent;
  display: block;
}
.playlist-player.skin-cm-diagonal .playlist-player-inner,
.playlist-player.skin-cm-diagonal .playlist-player-songinfo,
.playlist-player.skin-cm-diagonal .playlist-player-control {
  display: contents;
}
.playlist-player.skin-cm-diagonal .playlist-player-thumb {
  position: absolute;
  width: 110px;
  height: 300px;
  transform: skewX(-15deg);
  bottom: 0;
  border: 1px solid var(--skin-text-color);
  overflow: hidden;
  animation: s_leftIn 0.5s;
  z-index: 1;
  border-radius: 0;
  pointer-events: visible;
}
.playlist-player.skin-cm-diagonal .playlist-player-thumb-box {
  background: var(--skin-base-color);
  background-size: cover;
  background-position: center;
  width: 240px;
  left: -70px;
  height: 100%;
  transform: skewX(15deg);
  position: relative;
}
.playlist-player.skin-cm-diagonal .playlist-player-title {
  position: absolute;
  bottom: 85px;
  left: 50px;
  right: 23px;
  background: var(--skin-base-color) !important;
  padding: 8px !important;
  width: 180px !important;
  text-overflow: ellipsis;
  white-space: nowrap;
  overflow: hidden;
  word-wrap: normal;
  height: 16px;
  display: flex;
  align-items: center;
  transform: skewX(-15deg);
  animation: rightIn 0.5s;
  z-index: 5;
  pointer-events: visible;
  box-sizing: content-box !important;   /* global * { box-sizing: border-box } 가 padding/height 합산해 content 0 만드는 거 차단 */
  line-height: 16px;
}
.playlist-player.skin-cm-diagonal #p_title {
  font-size: 12px;
  color: var(--skin-text-color);
  display: block;
  text-overflow: ellipsis;
  white-space: nowrap;
  overflow: hidden;
  width: 100%;
  transform: skewX(15deg);
  max-height: none;
  -webkit-line-clamp: unset;
  line-height: 1;
}
.playlist-player.skin-cm-diagonal #p_artist { display: none; }
.playlist-player.skin-cm-diagonal .playlist-player-play-control {
  position: absolute;
  bottom: 40px;
  left: 110px;
  right: 15px;
  background: var(--skin-base-color);
  padding: 8px;
  display: flex;
  align-items: center;
  justify-content: center;
  height: 16px;
  transform: skewX(-15deg);
  pointer-events: visible;
  animation: rightIn 0.5s;
  z-index: 5;
  box-sizing: content-box !important;   /* border-box reset 차단 — 안쪽 25x25 버튼 들어갈 자리 확보 */
}
.playlist-player.skin-cm-diagonal .playlist-player-play-control > * {
  transform: skewX(15deg);
}
.playlist-player.skin-cm-diagonal .playlist-player-play-control .playlist-btn {
  background: var(--skin-base-color) !important;
  color: var(--skin-text-color);
  width: 25px !important;
  height: 25px !important;
  display: inline-flex !important;
  border-radius: 50% !important;
  align-items: center;
  justify-content: center;
  margin: 0 5px !important;
  cursor: pointer;
  padding: 0 !important;
  border: none !important;
  min-width: 0 !important;
  box-sizing: border-box !important;
  box-shadow: none !important;
}
.playlist-player.skin-cm-diagonal .playlist-player-play-control .playlist-btn:hover {
  color: var(--skin-base-color);
  background: var(--skin-text-color);
}
.playlist-player.skin-cm-diagonal .playlist-player-play-control .playlist-btn i {
  font-size: 13px;
}
/* play/pause 토글 복원 — display:inline-flex !important 가 base 토글 룰 묻은 거 다시 살림 */
.playlist-player.skin-cm-diagonal .playlist-player-play-control .playlist-btn:nth-child(3) {
  display: none !important;
}
.playlist-player.skin-cm-diagonal.active .playlist-player-play-control .playlist-btn:nth-child(2) {
  display: none !important;
}
.playlist-player.skin-cm-diagonal.active .playlist-player-play-control .playlist-btn:nth-child(3) {
  display: inline-flex !important;
}
.playlist-player.skin-cm-diagonal .playlist-player-time {
  position: absolute;
  bottom: 15px;
  right: 90px;
  border-radius: 10px;
  display: flex;
  align-items: center;
  gap: 15px;
  font-weight: bold;
  z-index: 5;
  pointer-events: visible;
}
.playlist-player.skin-cm-diagonal #playlist-player-infos1,
.playlist-player.skin-cm-diagonal #playlist-player-infos2 {
  font-size: 11px;
  color: var(--skin-text-color);
  min-width: 30px;
  text-align: center;
  margin: 0 !important;        /* base .playlist-player-time span { margin: 0 10px } 차단 — 원본은 gap:15 만 */
}
.playlist-player.skin-cm-diagonal .playlist-player-bar {
  flex: 1;
  position: relative;
  height: 4px;
  background: var(--skin-base-color);
  border-radius: 2px;
  overflow: visible;           /* handle 이 4px 바보다 크니 잘리지 않게 */
  width: 100px;
}
.playlist-player.skin-cm-diagonal #playlist-player-progress {
  display: block; position: absolute; top: 0; left: 0; width: 100%; height: 100%;
  margin: 0 !important; padding: 0; opacity: 0; cursor: pointer; z-index: 2;
  -webkit-appearance: none; appearance: none; background: transparent; pointer-events: auto;
}
.playlist-player.skin-cm-diagonal #p_shadow {
  position: absolute;
  top: 0;
  left: 0;
  height: 100%;
  background: var(--skin-text-color);
  border-radius: 2px;
  width: 0%;
  margin: 0 !important;       /* base #p_shadow { margin: 8px 0 } 차단 — 안 그러면 4px 바 아래로 밀려나 안 보임 */
  transition: width 0.1s ease;
}
/* handle — 바 중심 정렬, 호버 시 표시. base 의 margin:2px 0 + top:0 차단. */
.playlist-player.skin-cm-diagonal #p_shadow_btn {
  position: absolute;
  width: 12px !important;
  height: 12px !important;
  border-radius: 50% !important;
  background: var(--skin-text-color);
  top: 50% !important;
  margin: 0 !important;
  transform: translateY(-50%);
  pointer-events: none;
}
/* 원본 cm-diagonal: header at top:15 left:40 right:154, flex space-between, 2 btns (bars + minimize), animation leftIn.
   우리는 setting(⋯) 추가 → 3 버튼 25x25 원형, top:15, left 40/80/120 (gap 15). */
.playlist-player.skin-cm-diagonal #player-clear-btn,
.playlist-player.skin-cm-diagonal #player-setting-btn,
.playlist-player.skin-cm-diagonal #player-compact-btn {
  display: inline-flex !important;
  position: absolute !important;
  top: 15px !important;
  bottom: auto !important;
  width: 25px !important;
  height: 25px !important;
  min-width: 0 !important;
  border: none !important;
  border-radius: 50% !important;
  rotate: 0deg !important;
  box-shadow: none !important;
  margin: 0 !important;
  padding: 0 !important;
  background: var(--skin-base-color) !important;
  color: var(--skin-text-color) !important;
  font-size: 13px !important;
  z-index: 10 !important;
  align-items: center !important;
  justify-content: center !important;
  animation: leftIn 0.5s;
  pointer-events: visible !important;
}
.playlist-player.skin-cm-diagonal #player-clear-btn:hover,
.playlist-player.skin-cm-diagonal #player-setting-btn:hover,
.playlist-player.skin-cm-diagonal #player-compact-btn:hover {
  background: var(--skin-text-color) !important;
  color: var(--skin-base-color) !important;
  translate: 0 0 !important;
  box-shadow: none !important;
}
.playlist-player.skin-cm-diagonal #player-clear-btn i,
.playlist-player.skin-cm-diagonal #player-setting-btn i,
.playlist-player.skin-cm-diagonal #player-compact-btn i {
  rotate: 0deg !important;
}
/* X 아이콘 → bars (원본 cm-player-header 1번 버튼은 bars/list-toggle) */
.playlist-player.skin-cm-diagonal #player-clear-btn i.fa-xmark::before {
  content: "\f0c9";
  font-size: 13px;
}
/* 위치 — 원본 header left:40 right:154 (x=40 ~ x=136, 96 wide). 25px btn 3개 + gap 10 → 75+20=95 ≈ 96, 좌우 대칭. */
.playlist-player.skin-cm-diagonal #player-clear-btn   { left: 40px !important;  right: auto !important; }
.playlist-player.skin-cm-diagonal #player-setting-btn { left: 75px !important;  right: auto !important; }
.playlist-player.skin-cm-diagonal #player-compact-btn { left: 110px !important; right: auto !important; }

/* 원본 .cm-player-list — left:80 width:180 z-index:11 height:100% opacity:0 toggle.
   panel 자체는 thumb 위에 (left:80 ⇒ thumb right edge x=110 영역 살짝 침범).
   기본 .playlist-player-playlist 의 bottom:100% / display:flex / backdrop-filter 차단. */
.playlist-player.skin-cm-diagonal .playlist-player-playlist {
  position: absolute !important;
  left: 80px !important;
  top: 0 !important;
  bottom: auto !important;
  width: 180px !important;
  height: 100% !important;
  max-height: none !important;
  z-index: 11;
  overflow: auto;
  background: transparent !important;
  backdrop-filter: none !important;
  -webkit-backdrop-filter: none !important;
  border: none !important;
  border-radius: 0 !important;
  padding: 0 !important;
  display: block !important;
  opacity: 0;
  pointer-events: none;
  translate: 0 0 !important;
  transition: opacity 0.3s ease;
  color: var(--skin-base-color);
}
.playlist-player.skin-cm-diagonal .playlist-player-playlist.active {
  opacity: 1;
  pointer-events: auto;
  translate: 0 0 !important;
}
/* ========================================================================
   4 cm 스킨 공통: 앨범 섹션 표시 + 글자 잘림 방지 + tight spacing.
   매 스킨마다 반복하던 룰을 한 번에 처리.
   ========================================================================  */
.playlist-player.skin-cm-default .player-albumlist,
.playlist-player.skin-cm-diagonal .player-albumlist,
.playlist-player.skin-cm-floating .player-albumlist,
.playlist-player.skin-cm-sphere .player-albumlist {
  display: flex !important;
  padding-bottom: 8px;
  margin-bottom: 8px;
}
.playlist-player.skin-cm-default .player-album-others,
.playlist-player.skin-cm-diagonal .player-album-others,
.playlist-player.skin-cm-floating .player-album-others,
.playlist-player.skin-cm-sphere .player-album-others {
  gap: 0 !important;
}
/* album dropdown 열렸을 때 max-height — base 240 이라 앨범 많을 때 잘림. 충분히 키워서 다 보이게.
   list 패널 자체가 overflow:auto 라 넘쳐도 패널이 스크롤. */
.playlist-player.skin-cm-default .player-albumlist.open .player-album-others,
.playlist-player.skin-cm-diagonal .player-albumlist.open .player-album-others,
.playlist-player.skin-cm-floating .player-albumlist.open .player-album-others,
.playlist-player.skin-cm-sphere .player-albumlist.open .player-album-others {
  max-height: 9999px !important;
}
/* base .player-album { max-height: 60 } + .player-album-title/meta { max-height: 1.5em } 가 글자 메트릭 따라 잘림 — 공통 해제 */
.playlist-player.skin-cm-default .player-album,
.playlist-player.skin-cm-diagonal .player-album,
.playlist-player.skin-cm-floating .player-album,
.playlist-player.skin-cm-sphere .player-album {
  height: auto !important;
  max-height: none !important;
  overflow: visible;
}
.playlist-player.skin-cm-default .player-album-title,
.playlist-player.skin-cm-diagonal .player-album-title,
.playlist-player.skin-cm-floating .player-album-title,
.playlist-player.skin-cm-sphere .player-album-title,
.playlist-player.skin-cm-default .player-album-meta,
.playlist-player.skin-cm-diagonal .player-album-meta,
.playlist-player.skin-cm-floating .player-album-meta,
.playlist-player.skin-cm-sphere .player-album-meta {
  line-height: 1.3 !important;
  max-height: none !important;
  height: auto !important;
  /* 긴 제목 ellipsis — base width: 130 + nowrap 이 있지만 flex item 안에서 min-width 가 없으면 컨테이너 무시하고 늘어남 */
  width: auto !important;
  min-width: 0 !important;
  max-width: 100% !important;
  white-space: nowrap !important;
  overflow: hidden !important;
  text-overflow: ellipsis !important;
}
/* album-info 도 min-width:0 필요 — flex item 안 flex item 의 ellipsis 가 동작하려면 부모도 shrink 가능해야 함 */
.playlist-player.skin-cm-default .player-album-info,
.playlist-player.skin-cm-diagonal .player-album-info,
.playlist-player.skin-cm-floating .player-album-info,
.playlist-player.skin-cm-sphere .player-album-info {
  min-width: 0;
  overflow: hidden;
}
/* 곡 제목도 동일 처리 */
.playlist-player.skin-cm-default .player-song-title,
.playlist-player.skin-cm-diagonal .player-song-title,
.playlist-player.skin-cm-floating .player-song-title,
.playlist-player.skin-cm-sphere .player-song-title {
  width: auto !important;
  min-width: 0 !important;
  max-width: 100% !important;
  white-space: nowrap !important;
  overflow: hidden !important;
  text-overflow: ellipsis !important;
}
.playlist-player.skin-cm-default .player-song-info,
.playlist-player.skin-cm-diagonal .player-song-info,
.playlist-player.skin-cm-floating .player-song-info,
.playlist-player.skin-cm-sphere .player-song-info {
  min-width: 0;
  overflow: hidden;
}
/* 빈 playlist 메시지 */
.player-empty-msg {
  padding: 24px 16px;
  text-align: center;
  font-size: 12px;
  opacity: 0.6;
  color: var(--skin-text-color);
}

/* 첫 paint 동안 transition 차단 — takeOut 이 cm-hidden 으로 append 한 직후 transition 이 default→hidden 으로 애니메이션 도는 거 방지.
   2 RAF 후 JS 가 클래스 제거하면 이후 토글은 정상 transition. */
.playlist-player.no-init-transition,
.playlist-player.no-init-transition * {
  transition: none !important;
  animation: none !important;
}

/* thumb 로드 실패 폴백 — bg-image 안 보이게 + 중앙 음표 아이콘 */
.player-album-thumb.thumb-fallback,
.player-song-thumb.thumb-fallback,
.playlist-player-thumb-box.thumb-fallback {
  background-image: none !important;
  background-color: var(--skin-text-color);
  position: relative;
  display: flex !important;
  align-items: center;
  justify-content: center;
}
.player-album-thumb.thumb-fallback::after,
.player-song-thumb.thumb-fallback::after,
.playlist-player-thumb-box.thumb-fallback::after {
  content: "\f001";                    /* fa-music */
  font-family: "Font Awesome 6 Free";
  font-weight: 900;
  color: var(--skin-base-color);
  opacity: 0.5;
  font-size: 50%;                      /* container 크기의 50% */
}

/* 곡 제목 marquee — 제목 글자 폭이 container 넘으면 JS 가 .marquee 클래스 추가 + --marquee-end (px) 변수 설정.
   애니메이션: 처음 잠시 멈춤 → 좌측 scroll → 끝에서 잠시 멈춤 → 처음으로 복귀. 무한 반복.
   marquee 활성 시 ellipsis 비활성화. */
.playlist-player .playlist-player-title.marquee {
  overflow: hidden;
}
.playlist-player .playlist-player-title.marquee #p_title {
  display: inline-block !important;
  text-overflow: clip !important;
  overflow: visible !important;
  white-space: nowrap !important;
  width: auto !important;
  max-width: none !important;
  animation: title-marquee 9s ease-in-out infinite;
}
@keyframes title-marquee {
  0%, 12% { transform: translateX(0); }
  48%, 62% { transform: translateX(var(--marquee-end, -50%)); }
  98%, 100% { transform: translateX(0); }
}

/* cm-diagonal 전용 — 곡과 동일 skew + 동일 margin (8 8) 으로 너비 & 간격 통일 */
.playlist-player.skin-cm-diagonal .player-album {
  display: flex;
  align-items: center;
  padding: 8px;
  background: var(--skin-text-color);
  color: var(--skin-base-color);
  margin: 8px 8px;                   /* 곡 .player-song margin 8 8 과 동일 → 좌우 inset + 위아래 간격 16 */
  border-radius: 0;
  cursor: pointer;
  transition: 0.4s;
  flex: 0 0 auto;
  box-sizing: content-box;
  position: relative;
  transform: skewX(10deg);
}
.playlist-player.skin-cm-diagonal .player-album-thumb {
  display: inline-flex !important;
  width: 20px;
  height: 20px;
  border-radius: 4px;
  overflow: hidden;
  margin: 0 6px 0 0;
  flex-shrink: 0;
  background-size: cover;
  background-position: center;
  transform: skewX(-10deg);
}
.playlist-player.skin-cm-diagonal .player-album-info {
  flex: 1 1 auto;
  min-width: 0;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  justify-content: center;
  transform: skewX(-10deg);
}
.playlist-player.skin-cm-diagonal .player-album-title {
  font-size: 11px;
  font-weight: bold;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  min-width: 0;
  max-width: 100%;
  width: auto !important;
}
.playlist-player.skin-cm-diagonal .player-album-meta {
  font-size: 9px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  min-width: 0;
  max-width: 100%;
  width: auto !important;
}
.playlist-player.skin-cm-diagonal .player-album-caret {
  transform: skewX(-10deg) translateY(-50%);   /* base translateY(-50%) 수직 center + skew 보정 둘 다 유지 */
}
.playlist-player.skin-cm-diagonal .player-albumlist.open .player-album.current .player-album-caret {
  transform: skewX(-10deg) translateY(-50%) rotate(180deg);   /* open 시 caret 회전도 다른 transform 과 동시 유지 */
}
.playlist-player.skin-cm-diagonal .player-albumlist {
  margin-top: 26px;                  /* 헤더 영역 비우기 */
}
/* songlist column 정렬 */
.playlist-player.skin-cm-diagonal .player-songlist {
  display: flex;
  flex-direction: column;
  max-height: none;
  width: 100%;
  padding: 0;
  margin: 0;
}
/* 원본 .cm-song { flex space-evenly height:16 bg color1 color color2 padding:8 margin:8 8 skewX(10deg) transition:0.4s } */
.playlist-player.skin-cm-diagonal .player-song {
  display: flex !important;
  align-items: center;
  justify-content: space-evenly;
  height: 16px;
  background: var(--skin-text-color);
  color: var(--skin-base-color);
  padding: 8px;
  margin: 8px 8px;
  overflow: hidden;
  transform: skewX(10deg);
  cursor: pointer;
  transition: 0.4s;
  max-height: none;
  flex: 0 0 auto;
  box-sizing: content-box;
  border-radius: 0;
}
.playlist-player.skin-cm-diagonal .player-song:hover {
  scale: 1.05;
  translate: 0 0;
  background: var(--skin-text-color);
  color: var(--skin-base-color);
}
.playlist-player.skin-cm-diagonal .player-song.active {
  background: var(--skin-text-color);
  color: var(--skin-base-color);
  font-weight: bold;
}
/* 원본 .cm-song-thumb display:none — 곡 아이콘 안 보임 */
.playlist-player.skin-cm-diagonal .player-song-thumb { display: none !important; }
.playlist-player.skin-cm-diagonal .player-song-number { display: none !important; }
.playlist-player.skin-cm-diagonal .player-song-artist { display: none !important; }
/* 원본 .cm-song-name width 100% nowrap ellipsis height:16 overflow hidden */
.playlist-player.skin-cm-diagonal .player-song-info {
  flex: 1 1 auto;
  margin: 0;
  width: auto;
  min-width: 0;
  overflow: hidden;
  display: block;
}
.playlist-player.skin-cm-diagonal .player-song-title {
  width: 100%;
  white-space: nowrap;
  text-overflow: ellipsis;
  word-break: keep-all;
  height: 16px;
  overflow: hidden;
  font-size: 12px;
  font-weight: normal;
  line-height: 16px;
  min-width: 0;
  max-width: 100%;
}
/* scrollbar 숨김 (원본 .cm-player-list ::-webkit-scrollbar { display:none }) */
.playlist-player.skin-cm-diagonal .playlist-player-playlist::-webkit-scrollbar { display: none; }
.playlist-player.skin-cm-diagonal .playlist-player-playlist { scrollbar-width: none; }

@keyframes s_leftIn {
  0%   { opacity: 0; transform: skewX(-15deg) translateX(-30px); }
  100% { opacity: 1; transform: skewX(-15deg) translateX(0); }
}
@keyframes leftIn {
  0%   { opacity: 0; transform: translateX(-30px); }
  100% { opacity: 1; transform: translateX(0); }
}
@keyframes rightIn {
  0%   { opacity: 0; transform: skewX(-15deg) translateX(30px); }
  100% { opacity: 1; transform: skewX(-15deg) translateX(0); }
}

/* ================================================================
   3. cm-floating — 풀배경 썸네일 + 그라데이션 footer (220 x 240) — bottom-left config
   ================================================================ */
.playlist-player.skin-cm-floating {
  /* 원본 spec 220x240. 위치는 cm-pos-* 클래스가 결정 (default = bl). */
  width: 220px;
  height: 240px;
  color: var(--skin-text-color);
  background: var(--skin-base-color);
  overflow: hidden;
  font-family: var(--skin-default-font);
  box-shadow: 0 2px 6px rgba(0,0,0,0.1);
  position: fixed;
  border: 1px solid var(--skin-text-color);
  animation: hii 1s;
  /* 최소화/최대화 자연스러운 transition — width/height/border 도 transition 대상에 포함 */
  transition: width 0.4s ease, height 0.4s ease, border-color 0.4s ease, opacity 0.4s ease, background 0.4s ease, color 0.4s ease;
  display: block;
}
/* cm-floating 위치 (원본 floating.php 의 inline `<?=$vertical?>: 20; <?=$horizontal?>: 20` 매핑) */
.playlist-player.skin-cm-floating.cm-pos-bl,
.playlist-player.skin-cm-floating:not(.cm-pos-tl):not(.cm-pos-tr):not(.cm-pos-br) {
  bottom: 20px; left: 20px; top: auto; right: auto;
}
.playlist-player.skin-cm-floating.cm-pos-tl {
  top: 20px; left: 20px; bottom: auto; right: auto;
}
.playlist-player.skin-cm-floating.cm-pos-tr {
  top: 20px; right: 20px; bottom: auto; left: auto;
}
.playlist-player.skin-cm-floating.cm-pos-br {
  bottom: 20px; right: 20px; top: auto; left: auto;
}
.playlist-player.skin-cm-floating .playlist-player-inner,
.playlist-player.skin-cm-floating .playlist-player-songinfo {
  display: contents;
}
.playlist-player.skin-cm-floating .playlist-player-thumb {
  position: absolute;
  width: 100%;
  height: 100%;
  z-index: 0;
  border-radius: 0;
  inset: 0;
  top: 0;
  left: 0;
}
.playlist-player.skin-cm-floating .playlist-player-thumb-box {
  width: 100%;
  height: 100%;
  background-color: var(--skin-text-color);
  background-size: cover;
  background-position: center;
}
.playlist-player.skin-cm-floating .playlist-player-control {
  bottom: 0;
  position: absolute;
  width: 100%;
  background: linear-gradient(360deg, var(--skin-base-color) 20%, transparent);
  color: var(--skin-text-color);
  height: 200px;
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  z-index: 1;
}
.playlist-player.skin-cm-floating .playlist-player-title {
  /* 원본 .cm-player-info-box 매핑. footer 의 자연 배치는 absolute 으로 시뮬. */
  position: absolute;
  bottom: 58px;
  left: 0;
  right: 0;
  /* base .playlist-player-title { width: 130px } 차단 — 우리는 player 전체 폭(220) 채워야 함 */
  width: auto !important;
  padding: 8px 12px !important;       /* base padding 0 10 차단 */
  text-align: center !important;
  font-size: 14px;
  font-weight: bold;
  height: 14px;
  line-height: 14px;
  overflow: hidden;
  white-space: nowrap;
  text-overflow: ellipsis;
  display: block;
  z-index: 2;
  color: var(--skin-text-color);
  box-sizing: content-box !important;
}
/* #p_title 이 inline span 인데 base 룰들 (font-size 13, line-height 1em, max-height 2em, display -webkit-box 등) 이
   cm-floating 에선 모두 풀려야 함 — 부모 .playlist-player-title 의 단순 ellipsis 가 동작하도록. */
.playlist-player.skin-cm-floating #p_title {
  font-size: inherit;
  font-weight: inherit;
  line-height: inherit;
  max-height: none;
  display: inline;
  -webkit-line-clamp: unset;
  -webkit-box-orient: unset;
  align-items: unset;
  align-content: unset;
  width: auto;
  height: auto;
  text-align: inherit;
}
.playlist-player.skin-cm-floating #p_artist { display: none; }
.playlist-player.skin-cm-floating .playlist-player-play-control {
  /* 원본 .cm-player-control-box (220 width 5 btn space-around) 에서 prev/play/next (item 2-4) 의 center 가
     66/110/154 (44 간격). 우리는 3 btn 만 가지고 동일 위치 매칭 — width:113 (3×25 + 2×44/2 = 정확매핑), centered.
     padding 6 0 원본 spec. */
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 6px 0;
  width: 113px;
  margin: 0 auto;
  position: relative;
  order: 1;
}
.playlist-player.skin-cm-floating .playlist-player-play-control .playlist-btn {
  font-size: 14px !important;
  padding: 4px 6px !important;
  cursor: pointer;
  background: transparent !important;
  color: inherit !important;
  border: none !important;
  border-radius: 0 !important;
  width: auto !important;
  height: auto !important;
  min-width: 0 !important;
  margin: 0 !important;
  box-shadow: none !important;
}
.playlist-player.skin-cm-floating .playlist-player-time {
  display: flex;
  align-items: center;
  justify-content: space-between;
  font-size: 11px;
  padding: 0 10px;
  height: 24px;
  order: 2;
}
.playlist-player.skin-cm-floating .playlist-player-bar {
  width: 70px;
  box-sizing: border-box;
  position: relative;
  background: var(--skin-base-color);
  flex: none;
}
/* base .playlist-player-time span { margin: 0 10px } 차단 — 원본 #cm-player-infos1/2 는 margin 없음 */
.playlist-player.skin-cm-floating #playlist-player-infos1,
.playlist-player.skin-cm-floating #playlist-player-infos2 {
  margin: 0 !important;
  min-width: 0;
}
.playlist-player.skin-cm-floating #playlist-player-progress {
  display: block; position: absolute; top: 0; left: 0; width: 100%; height: 100%;
  margin: 0; padding: 0; opacity: 0; cursor: pointer; z-index: 2;
  -webkit-appearance: none; appearance: none; background: transparent; pointer-events: auto;
}
.playlist-player.skin-cm-floating #p_shadow {
  position: absolute;
  top: 50%;
  left: 0;
  height: 4px;
  transform: translateY(-50%);
  background: var(--skin-text-color);
  z-index: 1;
  border-radius: 2px;
  /* base #p_shadow 의 margin:8px 0 차단 — bar 안에서 정확히 중앙 정렬 위해 */
  margin: 0 !important;
}

/* cm-floating 리스트 패널 — 원본 .cm-player-list { top:0; height:100%; width:100%; z-index:2 } 매핑.
   header 버튼 영역은 첫 자식 (.player-albumlist 또는 첫 .player-song) 에 margin-top:26 으로 비움 (원본 .cm-song:first-child margin-top:26).
   z-index 10 으로 mini btns(5)/control(1) 위로 오버레이. */
.playlist-player.skin-cm-floating .playlist-player-playlist {
  position: absolute !important;
  left: 0 !important;
  top: 0 !important;
  z-index: 10;
  overflow: auto;
  height: 100% !important;
  width: 100% !important;
  background: var(--skin-base-color) !important;   /* solid bg — footer 차단 */
  display: block !important;                       /* base flex 차단 — vertical scroll 정상 */
  max-height: none !important;                     /* base max-height: 500 차단 */
  bottom: auto !important;                         /* base bottom: 100% 차단 */
  backdrop-filter: none !important;
  -webkit-backdrop-filter: none !important;
  border: none !important;
  border-radius: 0 !important;
  padding: 0 !important;
  pointer-events: none;
  opacity: 0;
  transition-duration: 0.4s;
}
.playlist-player.skin-cm-floating .playlist-player-playlist.active {
  opacity: 1;
  pointer-events: auto;
  /* base .playlist-player-playlist.active { translate: 0 -10px } 차단 — cm-floating 에선 panel 이 player 와 정렬돼야 함 */
  translate: 0 0 !important;
}
/* 원본 .cm-player-list.active #cm_songlist { display:flex; flex-direction:column; overflow:auto; bg: color2 } */
.playlist-player.skin-cm-floating .player-songlist,
.playlist-player.skin-cm-floating .player-album-others,
.playlist-player.skin-cm-floating .player-albumlist {
  display: flex;
  flex-direction: column;
  background: var(--skin-base-color);
  color: var(--skin-text-color);    /* base panel color: var(--skin-base-color) 차단 */
}
.playlist-player.skin-cm-floating .player-songlist {
  max-height: none;     /* songlist 만 max-height 풀음 — album-others 는 base 의 max-height:0 토글 동작 그대로 (헤더 클릭 시 .open 으로 펼침) */
}
/* panel/list 에 색상 명시적 설정 — base .playlist-player-playlist { color: var(--skin-base-color) } 의 cascade 차단 */
.playlist-player.skin-cm-floating .playlist-player-playlist {
  color: var(--skin-text-color);
}
/* 원본 .cm-song { display flex, align-items center, padding 5 20, height 30 } */
.playlist-player.skin-cm-floating .player-song {
  display: flex;
  align-items: center;
  padding: 5px 20px;
  height: 30px;
  overflow: hidden;
  background: transparent;
  margin: 0;
  border-radius: 0;
  cursor: pointer;
  transition: 0.4s;
  max-height: none;
  flex: 0 0 auto;
  box-sizing: content-box;
}
.playlist-player.skin-cm-floating .player-song:hover {
  color: var(--skin-base-color);
  background: var(--skin-text-color);
  scale: 1;
  translate: 0 0;
}
.playlist-player.skin-cm-floating .player-song.active {
  color: var(--skin-base-color);
  background: var(--skin-text-color);
}
/* 원본 .cm-song-thumb { width 30, height 30, border-radius 5, overflow hidden } */
.playlist-player.skin-cm-floating .player-song-thumb {
  display: inline-flex !important;
  width: 30px;
  height: 30px;
  border-radius: 5px;
  overflow: hidden;
  margin: 0;
  flex-shrink: 0;
  background-size: cover;
  background-position: center;
}
.playlist-player.skin-cm-floating .player-song-number,
.playlist-player.skin-cm-floating .player-song-artist {
  display: none;
}
/* 원본 .cm-song-name { flex 1, margin-left 10, ellipsis } */
.playlist-player.skin-cm-floating .player-song-info {
  flex: 1 1 auto;
  margin-left: 10px;
  width: auto;
  min-width: 0;
  overflow: hidden;
}
.playlist-player.skin-cm-floating .player-song-title {
  flex: 1 1 auto;
  white-space: nowrap;
  text-overflow: ellipsis;
  overflow: hidden;
  width: auto;
  min-width: 0;
  max-width: 100%;
  font-size: 14px;
  font-weight: normal;
  height: auto;
  line-height: 1.2;
  display: block;
}
/* 원본 .cm-song:first-child { margin-top: 26 } — 헤더 영역 비우기.
   우리는 album section 이 위에 있으므로 album section 또는 첫 song 에 margin-top 적용. */
.playlist-player.skin-cm-floating .player-albumlist {
  margin-top: 26px;
}
/* album 없을 때 (현재는 항상 있지만 안전 장치) */
.playlist-player.skin-cm-floating .player-songlist:first-child .player-song:first-child {
  margin-top: 26px;
}

/* 앨범 헤더 — 고정 height 대신 content 자연 높이. padding 으로 vertical 여유 + overflow visible 로 잘림 방지.
   gap:0 + tight padding 으로 곡 간격과 동일한 spacing 패턴. */
.playlist-player.skin-cm-floating .player-album {
  display: flex;
  align-items: center;
  padding: 4px 20px;
  height: auto !important;
  min-height: 30px;
  overflow: visible;               /* 글자 / thumb 잘림 방지 — base .player-album max-height:60 도 effective 없게 */
  background: var(--skin-base-color);
  color: var(--skin-text-color);
  margin: 0;
  border-radius: 0;
  cursor: pointer;
  transition: 0.4s;
  max-height: none !important;
  flex: 0 0 auto;
  box-sizing: content-box;
  position: relative;
}
/* album-others gap 0 — 곡 list 도 gap 없이 tight 이므로 동일 spacing. base .player-album-others { gap: 2 } 차단. */
.playlist-player.skin-cm-floating .player-album-others {
  gap: 0 !important;
}
/* 구분선 상하 여백 동일 — albumlist padding-bottom(8) / margin-bottom(8) 둘 다 8 로 명시 */
.playlist-player.skin-cm-floating .player-albumlist {
  padding-bottom: 8px;
  margin-bottom: 8px;
}
.playlist-player.skin-cm-floating .player-album-thumb {
  display: inline-flex !important;
  width: 30px;
  height: 30px;
  border-radius: 5px;
  overflow: hidden;
  margin: 0;
  flex-shrink: 0;
  background-size: cover;
  background-position: center;
}
.playlist-player.skin-cm-floating .player-album-info {
  flex: 1 1 auto;
  margin-left: 10px;
  width: auto;
  min-width: 0;
  overflow: hidden;
  flex-direction: column;
}
.playlist-player.skin-cm-floating .player-album-title {
  font-size: 14px;
  font-weight: normal;
  width: auto;
  min-width: 0;
  max-width: 100%;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  line-height: 1.3 !important;
  max-height: none !important;       /* base 1.5em 차단 — height 가 album container 가 관리 */
}
.playlist-player.skin-cm-floating .player-album-meta {
  font-size: 11px;
  width: auto;
  min-width: 0;
  max-width: 100%;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  line-height: 1.3 !important;
  max-height: none !important;
}
.playlist-player.skin-cm-floating .player-album-caret {
  margin-left: 6px;
}
/* 원본 cm-floating: header at top:5 left:5, 2 버튼 (bars + minimize) flex space-between, 24x24 border-radius:5.
   우리는 setting(⋯) 추가해서 3 버튼: bars(5) + setting(33) + minimize(right:5). */
.playlist-player.skin-cm-floating #player-clear-btn,
.playlist-player.skin-cm-floating #player-setting-btn,
.playlist-player.skin-cm-floating #player-compact-btn {
  display: inline-flex !important;
  position: absolute !important;
  top: 5px !important;
  bottom: auto !important;
  width: 24px !important;
  height: 24px !important;
  min-width: 0 !important;
  border: none !important;
  border-radius: 5px !important;            /* 원본 .cm-player-header .cm-player-btn 매핑 */
  rotate: 0deg !important;
  box-shadow: none !important;
  margin: 0 !important;
  padding: 0 !important;
  background: var(--skin-base-color) !important;
  color: var(--skin-text-color) !important;
  font-size: 12px !important;
  z-index: 99 !important;
  align-items: center !important;
  justify-content: center !important;
}
.playlist-player.skin-cm-floating #player-clear-btn:hover,
.playlist-player.skin-cm-floating #player-setting-btn:hover,
.playlist-player.skin-cm-floating #player-compact-btn:hover {
  background: var(--skin-text-color) !important;
  color: var(--skin-base-color) !important;
  translate: 0 0 !important;
  box-shadow: none !important;
}
/* clickstyle 자식 i 회전 풀기 */
.playlist-player.skin-cm-floating #player-clear-btn i,
.playlist-player.skin-cm-floating #player-setting-btn i,
.playlist-player.skin-cm-floating #player-compact-btn i {
  rotate: 0deg !important;
}
/* X 아이콘 → bars 아이콘 (FA unicode override, sphere 와 동일) */
.playlist-player.skin-cm-floating #player-clear-btn i.fa-xmark::before {
  content: "\f0c9";
  font-size: 12px;
}
/* 위치 — 원본 spec: bars left:5, minimize right:5. 우리 setting 끼워 넣어 left:33 (24+4 gap). */
.playlist-player.skin-cm-floating #player-clear-btn   { left: 5px !important;  right: auto !important; }
.playlist-player.skin-cm-floating #player-setting-btn { left: 33px !important; right: auto !important; }
.playlist-player.skin-cm-floating #player-compact-btn { left: auto !important; right: 5px !important; }

/* ================================================================
   4. cm-sphere — 원형 디스크 + xmark 4개 데코 (230 x 200) — bottom-left config
   (다른 cm 스킨들과 통일된 bottom 정렬, 사용자 screenshot 매치)
   ================================================================ */
.playlist-player.skin-cm-sphere {
  width: 230px;
  height: 200px;
  position: fixed;
  transition: all 0.3s ease;
  z-index: 2;
  font-family: var(--skin-default-font);
  bottom: 0;
  left: 0;
  background: transparent;
  display: block;
}
.playlist-player.skin-cm-sphere .playlist-player-inner,
.playlist-player.skin-cm-sphere .playlist-player-songinfo,
.playlist-player.skin-cm-sphere .playlist-player-control {
  display: contents;
}
.playlist-player.skin-cm-sphere .playlist-player-thumb {
  position: absolute;
  width: 220px;
  height: 220px;
  z-index: 1;
  animation: leftIn 0.5s;
  border-radius: 100%;
  bottom: -30px;
  left: -20px;
  /* 리스트 토글은 bars 버튼으로만 — 디스크 클릭으론 열리지 않게 pointer-events 차단 */
  pointer-events: none;
  /* base .playlist-player-thumb { overflow: hidden } 상속 막아서 thumb-box의 ::before/::after (xmark deco) 가 디스크 밖으로 튀어나올 수 있게 */
  overflow: visible;
  cursor: default;
}
/* 곡명/시간은 클릭할 필요 없는 텍스트 — pointer-events: none 으로 thumb 클릭 패스스루 (리스트 토글) */
.playlist-player.skin-cm-sphere .playlist-player-title,
.playlist-player.skin-cm-sphere .playlist-player-time {
  pointer-events: none;
}
/* 외곽 ring — 원본 .cm-player-thumb::before, bottom:12 left:-20 offset */
.playlist-player.skin-cm-sphere .playlist-player-thumb::before {
  content: '';
  position: absolute;
  width: 220px;
  height: 220px;
  border: 3px solid var(--skin-text-color);
  background: transparent;
  border-radius: 100%;
  z-index: 2;
  bottom: 12px;
  left: -20px;
  top: auto;
  right: auto;
}
.playlist-player.skin-cm-sphere .playlist-player-thumb::after {
  display: none;
}
.playlist-player.skin-cm-sphere .playlist-player-thumb-box {
  background-color: var(--skin-base-color);
  background-size: cover !important;       /* 다른 룰 override 방어 */
  background-position: center;
  background-repeat: no-repeat;
  width: 220px;
  height: 220px;
  border-radius: 100%;
  position: relative;
  /* base .playlist-player-thumb-box { z-index: -1 } 차단 — cm-sphere 에선 image 가 disc 표면에 올라와야 함 */
  z-index: 0;
}
.playlist-player.skin-cm-sphere .playlist-player-title {
  position: absolute;
  padding: 8px;
  width: 180px;
  word-wrap: normal;
  height: auto;
  display: flex;
  align-items: center;
  animation: rightIn-sphere 0.5s;
  bottom: 50px;          /* 원본 sphere.php inline 그대로 */
  left: 0;
  z-index: 5;
}
.playlist-player.skin-cm-sphere #p_title {
  font-size: 24px;
  color: var(--skin-text-color);
  width: 100%;
  line-height: 1;
  font-weight: bold;
  word-break: auto-phrase;
  height: 96px;
  display: -webkit-box;
  -webkit-line-clamp: 4;
  -webkit-box-orient: vertical;
  text-overflow: ellipsis;
  overflow: hidden;
  align-content: flex-end;
  text-align: left;
  max-height: none;
}
.playlist-player.skin-cm-sphere #p_artist { display: none; }
/* play-control: 원본은 left:0 + 6개 버튼 통합 (.cm-player-control-box). 여기선 .buttons 분리돼있어 left:15 shift.
   원본은 padding:8 height:16 + align-items:center 로 25-tall 버튼이 16-tall content 영역을 위/아래 4.5px씩 overflow.
   분리된 우리 케이스에선 padding/height 없애고 컨테이너가 children(25-tall)에 fit-shrink 하게 → bottom:23 으로 직접 위치 잡으면
   play btn center = 23+12.5 = 35.5 == mini btn center (28+7.5) 정확 일치. */
.playlist-player.skin-cm-sphere .playlist-player-play-control {
  position: absolute;
  padding: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  height: auto;
  pointer-events: visible;
  animation: rightIn-sphere 0.5s;
  bottom: 23px;
  /* shuffle 8-23, repeat 128-143 사이 중심 = 75.5. 3btn 가시 폭(25*3 + 5margin*6 = 105)
     → left = 75.5 - 52.5 = 23 으로 정중앙 배치 */
  left: 23px;
  z-index: 5;
}
/* play-control 버튼 — base .skin-btn / .playlist-player-play-control .playlist-btn.skin-btn 의
   padding/margin/border-radius 모두 강하게 override 해서 정확히 25x25 원형
   min/max-width/height 까지 모두 잠궈 다른 룰 못 들어오게 */
.playlist-player.skin-cm-sphere .playlist-player-play-control .playlist-btn,
.playlist-player.skin-cm-sphere .playlist-player-play-control .playlist-btn.skin-btn,
.playlist-player.skin-cm-sphere.compact .playlist-player-play-control .playlist-btn,
.playlist-player.skin-cm-sphere.compact .playlist-player-play-control .playlist-btn.skin-btn {
  background: var(--skin-base-color) !important;
  color: var(--skin-text-color) !important;
  width: 25px !important;             /* 원본 sphere.css .cm-player-btn 정확 매핑 */
  height: 25px !important;
  min-width: 25px !important;
  max-width: 25px !important;
  min-height: 25px !important;
  max-height: 25px !important;
  display: inline-flex !important;
  border-radius: 50% !important;
  align-items: center !important;
  justify-content: center !important;
  margin: 0 5px !important;            /* 원본 margin: 0px 5px */
  cursor: pointer;
  padding: 0 !important;
  border: none !important;
  box-sizing: border-box !important;
  box-shadow: none !important;
  font-size: 13px !important;          /* 원본 .cm-player-control-box .cm-player-btn i { font-size: 13px } */
  line-height: 1 !important;
  flex: 0 0 auto !important;
}
.playlist-player.skin-cm-sphere .playlist-player-play-control .playlist-btn:hover {
  color: var(--skin-base-color);
  background: var(--skin-text-color);
}
.playlist-player.skin-cm-sphere .playlist-player-play-control .playlist-btn i {
  font-size: 13px;
}
/* play/pause 토글 — 기본 룰 (.playlist-btn:nth-child(3) { display: none } 등) 이
   위 display:inline-flex !important 에 묻혀버려서, cm-sphere 컨텍스트에서 다시 살림.
   기본: pause(3rd) 숨김 / .active 시: play(2nd) 숨김 + pause(3rd) 표시 */
.playlist-player.skin-cm-sphere .playlist-player-play-control .playlist-btn:nth-child(3) {
  display: none !important;
}
.playlist-player.skin-cm-sphere.active .playlist-player-play-control .playlist-btn:nth-child(2) {
  display: none !important;
}
.playlist-player.skin-cm-sphere.active .playlist-player-play-control .playlist-btn:nth-child(3) {
  display: inline-flex !important;
}
.playlist-player.skin-cm-sphere .playlist-player-time {
  position: absolute;
  border-radius: 10px;
  display: flex;
  align-items: center;
  gap: 15px;
  font-weight: bold;
  bottom: 5px;           /* 원본 sphere.php inline 그대로 */
  left: 10px;
  z-index: 5;
}
.playlist-player.skin-cm-sphere #playlist-player-infos1,
.playlist-player.skin-cm-sphere #playlist-player-infos2 {
  font-size: 11px;
  color: var(--skin-text-color);
  min-width: 30px;
  text-align: center;
  /* base .playlist-player-time span { margin: 0 10px } 차단 — 원본 .cm-player-info 는 margin 없음. gap:15 로 spacing 충분. */
  margin: 0 !important;
}
.playlist-player.skin-cm-sphere .playlist-player-bar {
  flex: 1;
  position: relative;
  height: 4px;
  background: var(--skin-base-color);
  border-radius: 2px;
  overflow: visible;          /* handle(12px) 이 4px 바보다 크니 잘리지 않게 — cm-diagonal 과 동일 */
  width: 100px;
}
.playlist-player.skin-cm-sphere #playlist-player-progress {
  display: block; position: absolute; top: 0; left: 0; width: 100%; height: 100%;
  margin: 0 !important; padding: 0; opacity: 0; cursor: pointer; z-index: 2;
  -webkit-appearance: none; appearance: none; background: transparent; pointer-events: auto;
}
.playlist-player.skin-cm-sphere #p_shadow {
  position: absolute;
  top: 0;
  left: 0;
  height: 100%;
  background: var(--skin-text-color);
  border-radius: 2px;
  width: 0%;
  /* base #p_shadow 의 margin:8px 0 차단 — bar(4px) 안에 정확히 들어가야 함 */
  margin: 0 !important;
  transition: width 0.1s ease;
}
/* handle — 바 중심 정렬, 호버 시 표시. base 의 margin:2px 0 + top:0 차단. */
.playlist-player.skin-cm-sphere #p_shadow_btn {
  position: absolute;
  width: 12px !important;
  height: 12px !important;
  border-radius: 50% !important;
  background: var(--skin-text-color);
  top: 50% !important;
  margin: 0 !important;
  transform: translateY(-50%);
  pointer-events: none;
}
/* 원본 cm-sphere: header at top:15 left:100 (PHP inline), animation leftIn 0.5s — setting-btn 하나만 */
.playlist-player.skin-cm-sphere #player-setting-btn { top: 15px !important; left: 100px !important; animation: leftIn 0.5s; }

/* sphere의 rightIn은 skewX 없는 단순 translateX */
@keyframes rightIn-sphere {
  0%   { opacity: 0; transform: translateX(30px); }
  100% { opacity: 1; transform: translateX(0); }
}

/* xmark 데코 4개 — 원본 .cm-player-deco .xmark
   원본 PHP inline에 정의된 mask-image: url('<G5_URL>/custommenu/player/img/xmark.png')
   playlist 컨텍스트에선 player/img/xmark.png 로 위치. 같은 PNG 파일 사용. */
.playlist-player.skin-cm-sphere::before,
.playlist-player.skin-cm-sphere::after,
.playlist-player.skin-cm-sphere .playlist-player-thumb-box::before,
.playlist-player.skin-cm-sphere .playlist-player-thumb-box::after {
  content: '';
  position: absolute;
  width: 40px;
  height: 50px;
  background: var(--skin-text-color);
  pointer-events: none;
  z-index: 3;
  transform-origin: center;
  /* 원본 xmark.png 마스크 — 정확한 모양 그대로 */
  -webkit-mask-image: url('img/xmark.png');
          mask-image: url('img/xmark.png');
  -webkit-mask-size: contain;
          mask-size: contain;
  -webkit-mask-repeat: no-repeat;
          mask-repeat: no-repeat;
  -webkit-mask-position: center;
          mask-position: center;
  animation-duration: 2.8s;
  animation-iteration-count: infinite;
  animation-timing-function: cubic-bezier(0, 0.48, 0.21, 1.01);
}
/* bottom-left config 에서 deco 컨테이너 좌표 환산:
     원본 .cm-player-deco { bottom:0; left:180; width:40; height:200 } 안에 4개 xmark stack
     pseudo로 4개 분산 배치 — player 좌표 기준 bottom: 0/50/100/150, left: 180
   thumb-box(bottom:-30 left:-20 within player) ::X 환산:
     thumb-box::X.left  = 180 - (-20) = 200
     thumb-box::X.bottom = N - (-30) = N + 30 */
.playlist-player.skin-cm-sphere::before                            { bottom: 150px; left: 180px; animation-name: tilt1; }
.playlist-player.skin-cm-sphere::after                             { bottom: 100px; left: 180px; animation-name: tilt2; }
.playlist-player.skin-cm-sphere .playlist-player-thumb-box::before { bottom: 80px;  left: 200px; animation-name: tilt3; }
.playlist-player.skin-cm-sphere .playlist-player-thumb-box::after  { bottom: 30px;  left: 200px; animation-name: spin; }

@keyframes tilt1 {
  0%   { transform: rotate(0deg); }
  7%   { transform: rotate(8deg); }
  14%  { transform: rotate(0deg); }
  100% { transform: rotate(0deg); }
}
@keyframes tilt2 {
  0%, 7% { transform: rotate(0deg); }
  14%    { transform: rotate(6deg); }
  21%    { transform: rotate(0deg); }
  100%   { transform: rotate(0deg); }
}
@keyframes tilt3 {
  0%, 14% { transform: rotate(0deg); }
  21%     { transform: rotate(5deg); }
  28%     { transform: rotate(0deg); }
  100%    { transform: rotate(0deg); }
}
@keyframes spin {
  0%, 21% { transform: rotate(0deg); }
  46%     { transform: rotate(360deg); }
  100%    { transform: rotate(360deg); }
}

/* ================================================================
   위치 (4 위치) override — .cm-pos-tl/tr/bl/br 클래스 별 cm 스킨 좌표
   bl(default)은 각 cm 스킨 본체에서 이미 정의됨. 다른 3 위치만 override.
   ================================================================ */

/* === cm-default === */
/* tl: top:0 left:50, border-top:0 (대신 border-bottom 살림), border-radius 하단 둥글, flex column-reverse */
.playlist-player.skin-cm-default.cm-pos-tl {
  top: 0; bottom: auto; left: 50px; right: auto;
  border-top: 0;
  border-bottom: 1px solid var(--skin-text-color);
  border-radius: 0 0 10px 10px;
  flex-direction: column-reverse;
  animation: hii-top 1s;
}
/* tr: top:0 right:50, 같은 모양 */
.playlist-player.skin-cm-default.cm-pos-tr {
  top: 0; bottom: auto; right: 50px; left: auto;
  border-top: 0;
  border-bottom: 1px solid var(--skin-text-color);
  border-radius: 0 0 10px 10px;
  flex-direction: column-reverse;
  animation: hii-top 1s;
}
/* br: bottom:0 right:50, 본체 기본 (bottom)과 같음 */
.playlist-player.skin-cm-default.cm-pos-br {
  bottom: 0; top: auto; right: 50px; left: auto;
}

/* hii가 bottom-base 라 top config 일 땐 별도 키프레임 */
@keyframes hii-top {
  0%   { top: -100%; }
  100% { top: 0; }
}

/* === cm-floating === */
.playlist-player.skin-cm-floating.cm-pos-tl {
  top: 20px; bottom: auto; left: 20px; right: auto;
  animation: hii-top 1s;
}
.playlist-player.skin-cm-floating.cm-pos-tr {
  top: 20px; bottom: auto; right: 20px; left: auto;
  animation: hii-top 1s;
}
.playlist-player.skin-cm-floating.cm-pos-br {
  bottom: 20px; top: auto; right: 20px; left: auto;
}

/* === cm-diagonal — 좌우 대칭. top config는 thumb skewX 의미상 어색하지만 원본도 지원 === */
.playlist-player.skin-cm-diagonal.cm-pos-tl {
  top: -1px; bottom: auto; left: 70px; right: auto;
}
.playlist-player.skin-cm-diagonal.cm-pos-tr {
  top: -1px; bottom: auto; right: 20px; left: auto;
}
.playlist-player.skin-cm-diagonal.cm-pos-br {
  bottom: -1px; top: auto; right: 20px; left: auto;
}

/* === cm-sphere — 원본 sphere.php inline 정확 매핑 ===
   $vertical (top/bottom): player, thumb, thumb::before, deco, xmark deco — 위치에 따라 flip
   inner (title/control/info/buttons): 항상 bottom 고정 (원본도 $vertical 안 씀)
   $horizontal (left/right): inner 좌우 flip + #p_title text-align 변경 */

/* tl: 위쪽 + 왼쪽 — thumb/deco만 top 좌표, inner는 bottom 그대로 */
.playlist-player.skin-cm-sphere.cm-pos-tl {
  top: 0; bottom: auto; left: 0; right: auto;
}
.playlist-player.skin-cm-sphere.cm-pos-tl .playlist-player-thumb {
  top: -30px; bottom: auto;
}
.playlist-player.skin-cm-sphere.cm-pos-tl .playlist-player-thumb::before {
  top: 12px; bottom: auto;
}
/* xmark deco 4개 — top 기준 (sphere.php deco at $vertical:0) */
.playlist-player.skin-cm-sphere.cm-pos-tl::before                            { top: 0;     bottom: auto; left: 180px; right: auto; }
.playlist-player.skin-cm-sphere.cm-pos-tl::after                             { top: 50px;  bottom: auto; left: 180px; right: auto; }
.playlist-player.skin-cm-sphere.cm-pos-tl .playlist-player-thumb-box::before { top: 130px; bottom: auto; left: 200px; right: auto; }
.playlist-player.skin-cm-sphere.cm-pos-tl .playlist-player-thumb-box::after  { top: 180px; bottom: auto; left: 200px; right: auto; }

/* tr: 위쪽 + 오른쪽 — thumb/deco/inner 좌우 mirror, vertical은 thumb/deco만 top */
.playlist-player.skin-cm-sphere.cm-pos-tr {
  top: 0; bottom: auto; right: 0; left: auto;
}
.playlist-player.skin-cm-sphere.cm-pos-tr .playlist-player-thumb {
  top: -30px; bottom: auto; right: -20px; left: auto;
}
.playlist-player.skin-cm-sphere.cm-pos-tr .playlist-player-thumb::before {
  top: 12px; bottom: auto; right: -20px; left: auto;
}
/* inner: bottom 유지, 좌우만 right 로 flip */
.playlist-player.skin-cm-sphere.cm-pos-tr .playlist-player-title {
  right: 0; left: auto;
}
.playlist-player.skin-cm-sphere.cm-pos-tr #p_title { text-align: right; }
.playlist-player.skin-cm-sphere.cm-pos-tr .playlist-player-play-control {
  right: 0; left: auto;
}
.playlist-player.skin-cm-sphere.cm-pos-tr .playlist-player-time {
  right: 10px; left: auto;
}
/* tr config: shuffle/repeat 좌우 mirror */
.playlist-player.skin-cm-sphere.cm-pos-tr #player-shuffle-btn { right: 8px !important;  left: auto !important; }
.playlist-player.skin-cm-sphere.cm-pos-tr #player-repeat-btn  { right: 128px !important; left: auto !important; }
.playlist-player.skin-cm-sphere.cm-pos-tr .playlist-player-play-control {
  right: 23px; left: auto;
}
/* xmark deco — top + right */
.playlist-player.skin-cm-sphere.cm-pos-tr::before                            { top: 0;     bottom: auto; right: 180px; left: auto; }
.playlist-player.skin-cm-sphere.cm-pos-tr::after                             { top: 50px;  bottom: auto; right: 180px; left: auto; }
.playlist-player.skin-cm-sphere.cm-pos-tr .playlist-player-thumb-box::before { top: 130px; bottom: auto; right: 200px; left: auto; }
.playlist-player.skin-cm-sphere.cm-pos-tr .playlist-player-thumb-box::after  { top: 180px; bottom: auto; right: 200px; left: auto; }
/* setting-btn — sphere.php inline: $horizontal=='right' ? right:90 : left:100 */
.playlist-player.skin-cm-sphere.cm-pos-tr #player-setting-btn {
  top: 15px !important; right: 90px !important; left: auto !important;
}

/* br: 아래쪽 + 오른쪽 — thumb/deco bottom, inner 좌우 mirror */
.playlist-player.skin-cm-sphere.cm-pos-br {
  bottom: 0; top: auto; right: 0; left: auto;
}
.playlist-player.skin-cm-sphere.cm-pos-br .playlist-player-thumb {
  bottom: -30px; top: auto; right: -20px; left: auto;
}
.playlist-player.skin-cm-sphere.cm-pos-br .playlist-player-thumb::before {
  bottom: 12px; top: auto; right: -20px; left: auto;
}
.playlist-player.skin-cm-sphere.cm-pos-br .playlist-player-title {
  right: 0; left: auto;
}
.playlist-player.skin-cm-sphere.cm-pos-br #p_title { text-align: right; }
.playlist-player.skin-cm-sphere.cm-pos-br .playlist-player-play-control {
  right: 0; left: auto;
}
.playlist-player.skin-cm-sphere.cm-pos-br .playlist-player-time {
  right: 10px; left: auto;
}
/* br config: shuffle/repeat 좌우 mirror */
.playlist-player.skin-cm-sphere.cm-pos-br #player-shuffle-btn { right: 8px !important;  left: auto !important; }
.playlist-player.skin-cm-sphere.cm-pos-br #player-repeat-btn  { right: 128px !important; left: auto !important; }
.playlist-player.skin-cm-sphere.cm-pos-br .playlist-player-play-control {
  right: 23px; left: auto;
}
.playlist-player.skin-cm-sphere.cm-pos-br::before                            { bottom: 150px; top: auto; right: 180px; left: auto; }
.playlist-player.skin-cm-sphere.cm-pos-br::after                             { bottom: 100px; top: auto; right: 180px; left: auto; }
.playlist-player.skin-cm-sphere.cm-pos-br .playlist-player-thumb-box::before { bottom: 80px;  top: auto; right: 200px; left: auto; }
.playlist-player.skin-cm-sphere.cm-pos-br .playlist-player-thumb-box::after  { bottom: 30px;  top: auto; right: 200px; left: auto; }
.playlist-player.skin-cm-sphere.cm-pos-br #player-setting-btn {
  top: 15px !important; right: 90px !important; left: auto !important;
}

/* ================================================================
   shuffle/repeat 미니 버튼 — .play-control 영역에 absolute spread (4종 공통)
   원본 .cm-player-mini-btn:
     - default/floating: padding 2/4 opacity 0.5
     - diagonal/sphere:  15x15 border-radius 50%, opacity 0.6, hover scale(1.1)
   ================================================================ */
.playlist-player.skin-cm-default .playlist-player-buttons,
.playlist-player.skin-cm-diagonal .playlist-player-buttons,
.playlist-player.skin-cm-floating .playlist-player-buttons,
.playlist-player.skin-cm-sphere .playlist-player-buttons {
  display: flex;
  position: absolute;
  align-items: center;
  justify-content: space-between;
  pointer-events: none;
  z-index: 5;
}
.playlist-player.skin-cm-default .playlist-player-buttons > *,
.playlist-player.skin-cm-diagonal .playlist-player-buttons > *,
.playlist-player.skin-cm-floating .playlist-player-buttons > *,
.playlist-player.skin-cm-sphere .playlist-player-buttons > * {
  pointer-events: auto;
}

/* cm-default — JS (__normalize_cm_buttons) 가 shuffle/repeat 를 play-control 안으로 이동.
   원본 cm-default 처럼 6 버튼이 한 컨테이너에 자연스러운 1 row 로 정렬됨. */
/* shuffle/repeat 가 play-control 안으로 옮겨졌으면 wrapper 는 빈 컨테이너 — 보이지 않게 */
.playlist-player.skin-cm-default .playlist-player-buttons {
  display: none !important;
}
/* play-control 안 shuffle/repeat — flex order 로 시각적 순서 재배치 + 형제 버튼 metrics 와 통일 */
.playlist-player.skin-cm-default .playlist-player-play-control #player-shuffle-btn {
  order: -1;                          /* prev 보다 앞 — 원본 순서: shuffle, prev, play, pause, next, repeat */
}
.playlist-player.skin-cm-default .playlist-player-play-control #player-repeat-btn {
  order: 10;                          /* 끝 */
}
.playlist-player.skin-cm-default .playlist-player-play-control #player-shuffle-btn,
.playlist-player.skin-cm-default .playlist-player-play-control #player-repeat-btn {
  rotate: 0deg !important;            /* .clickstyle { rotate: 45deg } 차단 */
  opacity: 0.5;                       /* 원본 .cm-player-mini-btn opacity 0.5 */
  font-size: 14px !important;         /* 원본 .cm-player-btn font-size 14 (mini btn 도 동일 inherit) */
  padding: 2px 4px !important;        /* 원본 .cm-player-mini-btn padding 2 4 */
  height: auto !important;            /* 형제 .playlist-btn 의 height:22 override → 14+4=18 자연 높이 */
}
.playlist-player.skin-cm-default .playlist-player-play-control #player-shuffle-btn.active,
.playlist-player.skin-cm-default .playlist-player-play-control #player-repeat-btn.active {
  opacity: 1;
}
.playlist-player.skin-cm-default .playlist-player-play-control #player-shuffle-btn i,
.playlist-player.skin-cm-default .playlist-player-play-control #player-repeat-btn i {
  rotate: 0deg !important;
  font-size: 14px !important;
}
.playlist-player.skin-cm-default #player-mute-btn { display: none !important; }

/* cm-floating — default와 동일 미니 스타일.
   .control wrapper(footer)는 height:200, justify-end → 안에 [play-control(~30) + time(24)] 가 푸터 하단 정렬.
   play-control 영역에 정렬하려면 footer 하단 (24+30=54)에서 play-control 행 중심 = bottom 24+15 = 39px */
.playlist-player.skin-cm-floating .playlist-player-buttons {
  bottom: 26px;        /* time(24) 위, play-control과 같은 행 */
  height: 30px;
  left: 0;
  right: 0;
  /* 원본 cm-floating 의 5 btn space-around 에서 1번(shuffle)과 5번(repeat) center = 22, 198.
     btn 25 wide → shuffle left ~9.5, repeat right ~9.5 (220 width 기준). justify-content: space-between */
  padding: 0 9px;
}
.playlist-player.skin-cm-floating .playlist-player-buttons .playlist-btn {
  padding: 2px 4px !important;
  cursor: pointer;
  opacity: 0.5;
  font-size: 14px !important;
  background: transparent !important;
  border: none !important;
  color: var(--skin-text-color) !important;
  width: auto !important;
  height: auto !important;
  min-width: 0 !important;
  border-radius: 0 !important;
  margin: 0 !important;
  box-shadow: none !important;
  display: inline-flex !important;
  align-items: center;
  justify-content: center;
}
.playlist-player.skin-cm-floating .playlist-player-buttons .playlist-btn.active { opacity: 1; }

/* cm-diagonal — JS 가 shuffle/repeat 를 play-control 안으로 이동. wrapper 는 빈 컨테이너 → 숨김. */
.playlist-player.skin-cm-diagonal .playlist-player-buttons {
  display: none !important;
}
/* play-control 안 shuffle/repeat — 15x15 mini-btn, flex order 로 시각적 순서 재배치 */
.playlist-player.skin-cm-diagonal .playlist-player-play-control #player-shuffle-btn {
  order: -1;
}
.playlist-player.skin-cm-diagonal .playlist-player-play-control #player-repeat-btn {
  order: 10;
}
.playlist-player.skin-cm-diagonal .playlist-player-play-control #player-shuffle-btn,
.playlist-player.skin-cm-diagonal .playlist-player-play-control #player-repeat-btn {
  width: 15px !important;
  height: 15px !important;
  min-width: 15px !important;
  border-radius: 50% !important;
  background: transparent !important;
  color: var(--skin-text-color) !important;
  opacity: 0.6;
  margin: 0 5px !important;
  padding: 0 !important;
  border: none !important;
  box-shadow: none !important;
  font-size: 10px !important;
  rotate: 0deg !important;
  display: inline-flex !important;
  align-items: center !important;
  justify-content: center !important;
}
.playlist-player.skin-cm-diagonal .playlist-player-play-control #player-shuffle-btn.active,
.playlist-player.skin-cm-diagonal .playlist-player-play-control #player-repeat-btn.active {
  opacity: 1;
}
.playlist-player.skin-cm-diagonal .playlist-player-play-control #player-shuffle-btn i,
.playlist-player.skin-cm-diagonal .playlist-player-play-control #player-repeat-btn i {
  rotate: 0deg !important;
  font-size: 10px !important;
}
/* hover 시에도 play-control 의 unskew(skewX 15deg) 유지 + scale 살짝 — play-control > * 룰이 base transform 부여 */
.playlist-player.skin-cm-diagonal .playlist-player-play-control #player-shuffle-btn:hover,
.playlist-player.skin-cm-diagonal .playlist-player-play-control #player-repeat-btn:hover {
  transform: skewX(15deg) scale(1.1);
  background: transparent !important;
}

/* cm-sphere — 원본은 .cm-player-control-box 한 컨테이너에 6 btn (shuffle, prev, play, pause, next, repeat).
   playlist는 분리된 .play-control + .buttons 라 .buttons를 display:contents로 풀고 children을 개별 absolute 배치.
   play-control은 left:25로 시프트해 shuffle이 그 좌측에 자리잡게 함. */
.playlist-player.skin-cm-sphere .playlist-player-buttons {
  display: contents;
}
.playlist-player.skin-cm-sphere #player-shuffle-btn,
.playlist-player.skin-cm-sphere #player-repeat-btn {
  position: absolute !important;
  /* play-control bottom:20 + 32 height total → center at bottom:36. mini 15-tall center 맞춤 → 28 */
  bottom: 28px !important;
  width: 15px !important;
  height: 15px !important;
  min-width: 15px !important;
  max-width: 15px !important;
  min-height: 15px !important;
  max-height: 15px !important;
  border-radius: 50% !important;
  display: flex !important;
  align-items: center !important;
  justify-content: center !important;
  cursor: pointer;
  transition: all 0.2s ease;
  opacity: 0.6;
  color: var(--skin-text-color) !important;
  background: transparent !important;
  border: none !important;
  padding: 0 !important;
  margin: 0 !important;
  box-sizing: border-box !important;
  box-shadow: none !important;
  rotate: 0deg !important;
  font-size: 12px !important;
  flex: 0 0 auto !important;
  z-index: 5;
  pointer-events: auto;
  animation: rightIn-sphere 0.5s;
}
/* .clickstyle i { rotate: -45deg } 도 차단 (이중 회전 방지) */
.playlist-player.skin-cm-sphere #player-shuffle-btn i,
.playlist-player.skin-cm-sphere #player-repeat-btn i {
  rotate: 0deg !important;
  font-size: 12px;
}
.playlist-player.skin-cm-sphere #player-shuffle-btn.active,
.playlist-player.skin-cm-sphere #player-repeat-btn.active { opacity: 1; }
.playlist-player.skin-cm-sphere #player-shuffle-btn:hover,
.playlist-player.skin-cm-sphere #player-repeat-btn:hover {
  transform: scale(1.1);
}
.playlist-player.skin-cm-sphere #player-shuffle-btn i,
.playlist-player.skin-cm-sphere #player-repeat-btn i { font-size: 12px; }
/* shuffle 좌측, repeat 우측 — 원본 5visible (play/pause 중 1) 기준 정확 좌표:
   원본: shuffle x=8-23, prev=28-53, play|pause=63-88, next=98-123, repeat=128-143
   playlist port: play-control left:15 (3 visible = ~121 wide), repeat at 128 직후 */
.playlist-player.skin-cm-sphere #player-shuffle-btn { left: 8px !important; }
.playlist-player.skin-cm-sphere #player-repeat-btn  { left: 128px !important; }

/* cm-sphere 상단 세 버튼 통일 — bars(#player-clear-btn) + ⋯(#player-setting-btn) + 최소화(#player-compact-btn).
   원본 sphere 의 .cm-player-header (bars + minimize, flex 나란히, 25x25 원형, 동일 색상) 매핑 + ⋯(setting) 추가.
   기본 .textcolor 룰이 ⋯ 에 'bg=text-color/color=base' 로 들어가서 bars 와 색이 거꾸로 보이던 문제 — 둘 다 'bg=base/color=text' 로 강제 통일.
   hover 시엔 둘 다 color swap (translate/box-shadow inset 같은 .clickstyle/.textcolor base hover 효과 차단). */
.playlist-player.skin-cm-sphere #player-clear-btn,
.playlist-player.skin-cm-sphere #player-setting-btn,
.playlist-player.skin-cm-sphere #player-compact-btn {
  display: inline-flex !important;
  position: absolute !important;
  top: 15px !important;
  bottom: auto !important;
  width: 24px !important;
  height: 24px !important;
  min-width: 0 !important;
  border: none !important;
  border-radius: 50% !important;
  rotate: 0deg !important;
  box-shadow: none !important;
  margin: 0 !important;
  padding: 0 !important;
  background: var(--skin-base-color) !important;
  color: var(--skin-text-color) !important;
  font-size: 12px !important;
  z-index: 10 !important;
  align-items: center !important;
  justify-content: center !important;
  animation: leftIn 0.5s;
  translate: 0 0 !important;
  transition: 0.2s !important;
}
.playlist-player.skin-cm-sphere #player-clear-btn:hover,
.playlist-player.skin-cm-sphere #player-setting-btn:hover,
.playlist-player.skin-cm-sphere #player-compact-btn:hover {
  background: var(--skin-text-color) !important;
  color: var(--skin-base-color) !important;
  translate: 0 0 !important;
  box-shadow: none !important;
}
/* 위치 — disc 중심(left:90) 에 3-btn 클러스터 (94 wide) 를 정렬: left = 90-47 = 43.
   stride 35 유지: bars left:43, ⋯ left:78, minimize left:113 → cluster 중심이 disc 중심에 정확히 align */
.playlist-player.skin-cm-sphere #player-clear-btn   { left: 63px !important;  right: auto !important; }
.playlist-player.skin-cm-sphere #player-setting-btn { left: 98px !important;  right: auto !important; }
.playlist-player.skin-cm-sphere #player-compact-btn { left: 133px !important; right: auto !important; }

/* X 아이콘 → bars 아이콘 교체 (FA unicode override).
   .clickstyle i { rotate: -45deg } 가 자식 i 까지 회전시키는 걸 세 버튼 모두에서 풀어야 함. */
.playlist-player.skin-cm-sphere #player-clear-btn i,
.playlist-player.skin-cm-sphere #player-setting-btn i,
.playlist-player.skin-cm-sphere #player-compact-btn i {
  rotate: 0deg !important;
}
.playlist-player.skin-cm-sphere #player-clear-btn i.fa-xmark::before {
  content: "\f0c9";          /* fa-bars */
  font-size: 12px;
}
/* tr/br (right config): 좌우 mirror — disc 중심에 cluster 정렬 (right:43/78/113). */
.playlist-player.skin-cm-sphere.cm-pos-tr #player-clear-btn,
.playlist-player.skin-cm-sphere.cm-pos-br #player-clear-btn {
  left: auto !important;
  right: 133px !important;
}
.playlist-player.skin-cm-sphere.cm-pos-tr #player-setting-btn,
.playlist-player.skin-cm-sphere.cm-pos-br #player-setting-btn {
  left: auto !important;
  right: 98px !important;
}
.playlist-player.skin-cm-sphere.cm-pos-tr #player-compact-btn,
.playlist-player.skin-cm-sphere.cm-pos-br #player-compact-btn {
  left: auto !important;
  right: 63px !important;
}

/* p_square (네모네모) + cm-default / cm-diagonal / cm-floating — 모서리 전부 sharp.
   base .p_square.playlist-player * { border-radius: 0 } 가 있지만 우리 cm 스킨들이 !important 로 border-radius 를 지정해서 override 되므로 명시적 차단 필요. */
.p_square.playlist-player.skin-cm-default,
.p_square.playlist-player.skin-cm-default *,
.p_square.playlist-player.skin-cm-diagonal,
.p_square.playlist-player.skin-cm-diagonal *,
.p_square.playlist-player.skin-cm-floating,
.p_square.playlist-player.skin-cm-floating * {
  border-radius: 0 !important;
}

/* p_square (네모네모) + cm-sphere — disc 를 마름모 모양으로. clip-path 로 다이아몬드 형태만 만들고 회전 X → album image 는 정상 방향 유지.
   기존 thumb-box::before/::after 는 clip-path 에 가려져서 안 보이니까, .thumb::after 와 .thumb-icon 을 재활용해서 동일 위치에 deco 다시 그림 → 4 decos 유지. */
.p_square.playlist-player.skin-cm-sphere .playlist-player-thumb,
.p_square.playlist-player.skin-cm-sphere .playlist-player-thumb-box {
  border-radius: 0 !important;
}
.p_square.playlist-player.skin-cm-sphere .playlist-player-thumb {
  border: none !important;               /* base .p_square 의 1px border 차단 */
}
.p_square.playlist-player.skin-cm-sphere .playlist-player-thumb-box {
  /* 마름모 = inscribed diamond (4 vertices: top, right, bottom, left mid-points) */
  -webkit-clip-path: polygon(50% 0%, 100% 50%, 50% 100%, 0% 50%);
          clip-path: polygon(50% 0%, 100% 50%, 50% 100%, 0% 50%);
}
.p_square.playlist-player.skin-cm-sphere .playlist-player-thumb::before {
  /* 외곽 ring 도 마름모 — clip-path 로. */
  border-radius: 0 !important;
  -webkit-clip-path: polygon(50% 0%, 100% 50%, 50% 100%, 0% 50%);
          clip-path: polygon(50% 0%, 100% 50%, 50% 100%, 0% 50%);
}
/* clip-path 로 가려지는 thumb-box 의 deco 2개 → 안 보이게 hide */
.p_square.playlist-player.skin-cm-sphere .playlist-player-thumb-box::before,
.p_square.playlist-player.skin-cm-sphere .playlist-player-thumb-box::after {
  display: none !important;
}
/* deco 3 — .thumb::after 재활용 (원본 thumb-box::before 위치). bottom 80→85 로 5px 위로 (deco 4 와 회전 시 모서리 겹침 방지) */
.p_square.playlist-player.skin-cm-sphere .playlist-player-thumb::after {
  display: block !important;
  content: '';
  position: absolute;
  bottom: 85px;
  left: 200px;
  top: auto;
  right: auto;
  width: 40px;
  height: 50px;
  background: var(--skin-text-color);
  pointer-events: none;
  z-index: 3;
  transform-origin: center;
  -webkit-mask-image: url('img/xmark.png');
          mask-image: url('img/xmark.png');
  -webkit-mask-size: contain;
          mask-size: contain;
  -webkit-mask-repeat: no-repeat;
          mask-repeat: no-repeat;
  -webkit-mask-position: center;
          mask-position: center;
  animation: tilt3 2.8s infinite cubic-bezier(0, 0.48, 0.21, 1.01);
  border-radius: 0 !important;
  border: none !important;
}
/* deco 4 — .thumb-icon 재활용 (원본 thumb-box::after 위치).
   base .thumb-icon 에 opacity:0 이 있어서 안 보였음 → opacity:1 !important 로 override. */
.p_square.playlist-player.skin-cm-sphere .playlist-player-thumb-icon {
  display: block !important;
  opacity: 1 !important;
  position: absolute;
  bottom: 30px;
  left: 200px;
  top: auto;
  right: auto;
  width: 40px;
  height: 50px;
  background: var(--skin-text-color);
  pointer-events: none;
  z-index: 3;
  -webkit-mask-image: url('img/xmark.png');
          mask-image: url('img/xmark.png');
  -webkit-mask-size: contain;
          mask-size: contain;
  -webkit-mask-repeat: no-repeat;
          mask-repeat: no-repeat;
  -webkit-mask-position: center;
          mask-position: center;
  animation: spin 2.8s infinite cubic-bezier(0, 0.48, 0.21, 1.01);
}
/* p_square + tl/tr/br 위치 별 새 deco (thumb::after, thumb-icon) 좌표 — 원본 normal mode 의 thumb-box::before/::after 위치와 매칭. */
.p_square.playlist-player.skin-cm-sphere.cm-pos-tl .playlist-player-thumb::after {
  bottom: auto !important;
  top: 125px !important;            /* 4번째 deco 와 5px 간격 (회전 모서리 침범 방지) */
  left: 200px !important;
  right: auto !important;
}
.p_square.playlist-player.skin-cm-sphere.cm-pos-tl .playlist-player-thumb-icon {
  bottom: auto !important;
  top: 180px !important;
  left: 200px !important;
  right: auto !important;
}
.p_square.playlist-player.skin-cm-sphere.cm-pos-tr .playlist-player-thumb::after {
  bottom: auto !important;
  top: 125px !important;
  left: auto !important;
  right: 200px !important;
}
.p_square.playlist-player.skin-cm-sphere.cm-pos-tr .playlist-player-thumb-icon {
  bottom: auto !important;
  top: 180px !important;
  left: auto !important;
  right: 200px !important;
}
.p_square.playlist-player.skin-cm-sphere.cm-pos-br .playlist-player-thumb::after {
  bottom: 85px !important;
  top: auto !important;
  left: auto !important;
  right: 200px !important;
}
.p_square.playlist-player.skin-cm-sphere.cm-pos-br .playlist-player-thumb-icon {
  bottom: 30px !important;
  top: auto !important;
  left: auto !important;
  right: 200px !important;
}

/* 외곽 ring (.thumb::before) — clip-path 로 자르면 3px 테두리가 거의 안 보임. 대신 rotate(45deg) + scale(0.707) 로
   원형(220 지름)과 동일한 inscribed diamond 사이즈 (대각선 220) 만들기. */
.p_square.playlist-player.skin-cm-sphere .playlist-player-thumb::before {
  border-radius: 0 !important;
  -webkit-clip-path: none !important;
          clip-path: none !important;
  transform: rotate(45deg) scale(0.707) !important;   /* sqrt(2) 보정 → 원형 지름과 동일 */
  transform-origin: center;
}
.p_square.playlist-player.skin-cm-sphere .playlist-player-thumb-icon i {
  display: none;
}
/* 버튼들은 회전 안 시킴 — 살짝만 사각으로 */
.p_square.playlist-player.skin-cm-sphere .playlist-player-play-control .playlist-btn,
.p_square.playlist-player.skin-cm-sphere .playlist-player-play-control .playlist-btn.skin-btn,
.p_square.playlist-player.skin-cm-sphere #player-shuffle-btn,
.p_square.playlist-player.skin-cm-sphere #player-repeat-btn,
.p_square.playlist-player.skin-cm-sphere #player-clear-btn,
.p_square.playlist-player.skin-cm-sphere #player-setting-btn,
.p_square.playlist-player.skin-cm-sphere #player-compact-btn {
  border-radius: 4px !important;
}

/* cm 스킨 최소화 (cm-hidden) — 원본 sphere 의 cm-hide 매핑.
   player 박스 자체 0x0 transparent 로 완전히 사라지게 + minimize 버튼만 fixed 좌하단에 남아서 '다시 보이기' 토글로 동작. */
.playlist-player.skin-cm-default.cm-hidden,
.playlist-player.skin-cm-diagonal.cm-hidden,
.playlist-player.skin-cm-floating.cm-hidden,
.playlist-player.skin-cm-sphere.cm-hidden {
  background: transparent !important;
  border: none !important;
  box-shadow: none !important;
  pointer-events: none;
  overflow: visible;
}
/* floating/default 는 그대로 0x0 으로 접힘 (slide-up 느낌) */
.playlist-player.skin-cm-default.cm-hidden,
.playlist-player.skin-cm-floating.cm-hidden {
  width: 0 !important;
  height: 0 !important;
}
.playlist-player.skin-cm-floating.cm-hidden > *:not(#player-compact-btn),
.playlist-player.skin-cm-default.cm-hidden > *:not(#player-compact-btn) {
  display: none !important;
}

/* cm-sphere 최소화 — display:none 으로 자식들이 instant 사라지던 거 → opacity + scale 로 부드러운 fade.
   .playlist-player-inner 는 display:contents 라 opacity/transform 안 먹음 → 실제 visible children 에 직접 적용. */
.playlist-player.skin-cm-sphere .playlist-player-thumb,
.playlist-player.skin-cm-sphere .playlist-player-title,
.playlist-player.skin-cm-sphere .playlist-player-time,
.playlist-player.skin-cm-sphere .playlist-player-play-control,
.playlist-player.skin-cm-sphere #player-shuffle-btn,
.playlist-player.skin-cm-sphere #player-repeat-btn,
.playlist-player.skin-cm-sphere #player-clear-btn,
.playlist-player.skin-cm-sphere #player-setting-btn,
.playlist-player.skin-cm-sphere .player-setting-window-wrapper,
.playlist-player.skin-cm-sphere .playlist-player-playlist {
  transition: opacity 0.45s ease, transform 0.45s ease;
}
.playlist-player.skin-cm-sphere::before,
.playlist-player.skin-cm-sphere::after {
  transition: opacity 0.45s ease, transform 0.45s ease;
}
.playlist-player.skin-cm-sphere.cm-hidden {
  width: 0 !important;
  height: 0 !important;
}
.playlist-player.skin-cm-sphere.cm-hidden .playlist-player-thumb,
.playlist-player.skin-cm-sphere.cm-hidden .playlist-player-title,
.playlist-player.skin-cm-sphere.cm-hidden .playlist-player-time,
.playlist-player.skin-cm-sphere.cm-hidden .playlist-player-play-control,
.playlist-player.skin-cm-sphere.cm-hidden #player-shuffle-btn,
.playlist-player.skin-cm-sphere.cm-hidden #player-repeat-btn,
.playlist-player.skin-cm-sphere.cm-hidden #player-clear-btn,
.playlist-player.skin-cm-sphere.cm-hidden #player-setting-btn,
.playlist-player.skin-cm-sphere.cm-hidden .player-setting-window-wrapper,
.playlist-player.skin-cm-sphere.cm-hidden .playlist-player-playlist,
.playlist-player.skin-cm-sphere.cm-hidden::before,
.playlist-player.skin-cm-sphere.cm-hidden::after {
  opacity: 0 !important;
  pointer-events: none;
}

/* cm-diagonal 최소화 — 원본 thumb/header 는 leftIn (좌→우), title/control 은 rightIn (우→좌) 으로 등장하므로
   최소화 시 반대 방향으로 흩어지는 느낌이 디자인에 맞음. player 박스 자체는 290x302 유지하되 자식들이 좌/우로 슬라이드 아웃. */
.playlist-player.skin-cm-diagonal.cm-hidden {
  /* width/height 보존해야 자식 좌/우 슬라이드가 시각적으로 의미있음 */
}
/* 자식 공통 transition (보이는 상태에서도 걸려있어야 cm-hidden 토글 양 방향 모두 부드러움) */
.playlist-player.skin-cm-diagonal .playlist-player-thumb,
.playlist-player.skin-cm-diagonal .playlist-player-title,
.playlist-player.skin-cm-diagonal .playlist-player-play-control,
.playlist-player.skin-cm-diagonal .playlist-player-buttons,
.playlist-player.skin-cm-diagonal .playlist-player-time,
.playlist-player.skin-cm-diagonal #player-clear-btn,
.playlist-player.skin-cm-diagonal #player-setting-btn,
.playlist-player.skin-cm-diagonal #player-compact-btn {
  transition: transform 0.45s ease, opacity 0.45s ease, left 0.45s ease, right 0.45s ease, top 0.45s ease, bottom 0.45s ease;
}
/* 좌측 그룹 (thumb + bars/setting btn) → 좌측으로 흩어짐 */
.playlist-player.skin-cm-diagonal.cm-hidden .playlist-player-thumb {
  transform: skewX(-15deg) translateX(-220%);
  opacity: 0;
}
.playlist-player.skin-cm-diagonal.cm-hidden #player-clear-btn {
  transform: translateX(-600%);
  opacity: 0;
}
.playlist-player.skin-cm-diagonal.cm-hidden #player-setting-btn {
  transform: translateX(-450%);
  opacity: 0;
}
/* 우측 그룹 (title, play-control, mini buttons, time) → 우측으로 흩어짐 */
.playlist-player.skin-cm-diagonal.cm-hidden .playlist-player-title {
  transform: skewX(-15deg) translateX(180%);
  opacity: 0;
}
.playlist-player.skin-cm-diagonal.cm-hidden .playlist-player-play-control,
.playlist-player.skin-cm-diagonal.cm-hidden .playlist-player-buttons {
  transform: skewX(-15deg) translateX(180%);
  opacity: 0;
}
.playlist-player.skin-cm-diagonal.cm-hidden .playlist-player-time {
  transform: translateX(250%);
  opacity: 0;
}
/* compact-btn 만 fixed 코너로 이동 — '다시 보이기' 토글 */
.playlist-player.skin-cm-diagonal.cm-hidden #player-compact-btn {
  display: inline-flex !important;
  pointer-events: auto !important;
  position: fixed !important;
  bottom: 10px !important;
  left: 10px !important;
  top: auto !important;
  right: auto !important;
  z-index: 9999 !important;
  transform: none !important;
  opacity: 1 !important;
}

/* minimize 버튼만 재 표시 — 위치 고정 (좌하단 코너), 클릭 가능 */
.playlist-player.skin-cm-sphere.cm-hidden #player-compact-btn,
.playlist-player.skin-cm-floating.cm-hidden #player-compact-btn,
.playlist-player.skin-cm-default.cm-hidden #player-compact-btn {
  display: inline-flex !important;
  pointer-events: auto !important;
  position: fixed !important;
  bottom: 10px !important;
  left: 10px !important;
  top: auto !important;
  right: auto !important;
  z-index: 9999 !important;
}
/* tr/br 위치는 우측 mirror — sphere/floating/diagonal/default 적용 */
.playlist-player.skin-cm-sphere.cm-hidden.cm-pos-tr #player-compact-btn,
.playlist-player.skin-cm-sphere.cm-hidden.cm-pos-br #player-compact-btn,
.playlist-player.skin-cm-floating.cm-hidden.cm-pos-tr #player-compact-btn,
.playlist-player.skin-cm-floating.cm-hidden.cm-pos-br #player-compact-btn,
.playlist-player.skin-cm-diagonal.cm-hidden.cm-pos-tr #player-compact-btn,
.playlist-player.skin-cm-diagonal.cm-hidden.cm-pos-br #player-compact-btn,
.playlist-player.skin-cm-default.cm-hidden.cm-pos-tr #player-compact-btn,
.playlist-player.skin-cm-default.cm-hidden.cm-pos-br #player-compact-btn {
  left: auto !important;
  right: 10px !important;
}
/* tl/tr (top config) 는 상단 코너로 — sphere/floating/diagonal/default 적용 */
.playlist-player.skin-cm-sphere.cm-hidden.cm-pos-tl #player-compact-btn,
.playlist-player.skin-cm-sphere.cm-hidden.cm-pos-tr #player-compact-btn,
.playlist-player.skin-cm-floating.cm-hidden.cm-pos-tl #player-compact-btn,
.playlist-player.skin-cm-floating.cm-hidden.cm-pos-tr #player-compact-btn,
.playlist-player.skin-cm-diagonal.cm-hidden.cm-pos-tl #player-compact-btn,
.playlist-player.skin-cm-diagonal.cm-hidden.cm-pos-tr #player-compact-btn,
.playlist-player.skin-cm-default.cm-hidden.cm-pos-tl #player-compact-btn,
.playlist-player.skin-cm-default.cm-hidden.cm-pos-tr #player-compact-btn {
  bottom: auto !important;
  top: 10px !important;
}

/* .player-pulse 효과 ─ base .playlist-player.active.player-pulse::before 가 ::before 의
   width/height/animation 을 덮어써서, cm 스킨의 xmark deco(::before / ::after) 가 거대 X로 폭주.
   cm 스킨은 자체 xmark/animation 을 가지므로 pulse pseudo 효과 자체를 차단. */
.playlist-player.skin-cm-default.active.player-pulse::before,
.playlist-player.skin-cm-diagonal.active.player-pulse::before,
.playlist-player.skin-cm-floating.active.player-pulse::before,
.playlist-player.skin-cm-sphere.active.player-pulse::before {
  width: 40px !important;
  height: 50px !important;
  border: none !important;
  animation-name: tilt1 !important;
}

/* cm-sphere 리스트 패널 — 원본 .cm-player-list 매핑.
   원본: position:absolute, width:180, height:100% (player 200), left:160 (left config) | right:160 (right),
         no panel bg, no padding/border, items 만 pill 형태로 floating.
   우리 player(230x200) 안의 자식이라 좌표 동일하게 매핑. */
.playlist-player.skin-cm-sphere .playlist-player-playlist {
  position: absolute !important;
  width: 180px !important;
  height: 100% !important;
  max-height: 100% !important;
  left: 160px !important;
  right: auto !important;
  top: 0 !important;
  bottom: auto !important;
  background: transparent !important;     /* sphere.css 원본 spec — panel 자체는 transparent */
  backdrop-filter: none !important;       /* base 의 blur(5px) 차단 */
  -webkit-backdrop-filter: none !important;
  border: none !important;
  border-radius: 0 !important;
  padding: 0 !important;
  z-index: 11;
  overflow: auto;
  display: block !important;
  flex-direction: unset !important;
  pointer-events: none;
  opacity: 0;
  translate: 0 0;
  transition-duration: 0.4s;
}
.playlist-player.skin-cm-sphere .playlist-player-playlist.active {
  opacity: 1;
  pointer-events: auto;
  translate: 0 0;
}
.playlist-player.skin-cm-sphere.cm-pos-tr .playlist-player-playlist,
.playlist-player.skin-cm-sphere.cm-pos-br .playlist-player-playlist {
  left: auto !important;
  right: 160px !important;
}
.playlist-player.skin-cm-sphere .playlist-player-playlist::-webkit-scrollbar { display: none; }
.playlist-player.skin-cm-sphere .player-songlist {
  /* 원본 .cm-player-list.active #cm_songlist { display:flex; flex-direction:column } 매핑.
     flex item 의 vertical margin 은 collapse 안 함 → 인접 곡 사이 gap = 8+8 = 16 (block 의 collapsed 8 보다 넓음). */
  display: flex;
  flex-direction: column;
  max-height: none;
}
.playlist-player.skin-cm-sphere .player-album-others {
  display: flex;
  flex-direction: column;
}
/* 곡 — 원본 sphere.css `.cm-song` 정확 매핑 (skewX 없음, 직사각형). */
.playlist-player.skin-cm-sphere .player-song {
  display: flex;
  justify-content: space-evenly;
  align-items: center;
  height: 16px;
  background: var(--skin-text-color);
  color: var(--skin-base-color);
  padding: 8px;
  margin: 8px 8px;
  border-radius: 0;
  overflow: hidden;
  cursor: pointer;
  transition: 0.4s;
  max-height: none;
  /* flex column 컨테이너에서 children default flex: 0 1 auto → container 짧으면 items 압축됨.
     intrinsic 32px outer height (16+8+8) 강제 유지: */
  flex: 0 0 auto;
  min-height: 16px;
  box-sizing: content-box;       /* base box-sizing 차단 — height:16 = 내부, padding 별도 추가 */
}
.playlist-player.skin-cm-sphere .player-song:hover {
  scale: 1.05;
  translate: 0 0;
  background: var(--skin-text-color);
  color: var(--skin-base-color);
}
.playlist-player.skin-cm-sphere .player-song.active {
  background: var(--skin-base-color);
  color: var(--skin-text-color);
}
.playlist-player.skin-cm-sphere .player-song-number,
.playlist-player.skin-cm-sphere .player-song-thumb,
.playlist-player.skin-cm-sphere .player-song-artist {
  display: none;
}
.playlist-player.skin-cm-sphere .player-song-info {
  width: 100%;
  flex-direction: row;
}
.playlist-player.skin-cm-sphere .player-song-title {
  /* 원본 .cm-song-name 그대로 매핑 */
  width: 100%;
  white-space: nowrap;
  text-overflow: ellipsis;
  word-break: keep-all;
  height: 16px;
  overflow: hidden;
  font-weight: normal;
  /* base 의 font-size: 12 차단 + 사이트 body inherit (~14) 매핑 */
  font-size: 14px;
  line-height: 16px;
}
/* 앨범 헤더/리스트 — pill 형태로 매칭, swap 색상 */
.playlist-player.skin-cm-sphere .player-albumlist {
  margin: 0;
  padding: 0;
  border-bottom: none;
  gap: 0;
}
.playlist-player.skin-cm-sphere .player-album {
  display: flex;
  align-items: center;
  height: 16px;
  background: var(--skin-base-color);    /* swap vs songs (songs=text-bg, albums=base-bg) */
  color: var(--skin-text-color);
  padding: 8px;
  margin: 8px 8px;
  border-radius: 0;
  overflow: hidden;
  cursor: pointer;
  transition: 0.4s;
  max-height: none;
  position: relative;
  /* song 과 동일한 box-sizing/flex 강제 (첫 항목 크기 일치) */
  flex: 0 0 auto;
  min-height: 16px;
  box-sizing: content-box;
}
.playlist-player.skin-cm-sphere .player-album:hover {
  scale: 1.05;
  translate: 0 0;
  background: var(--skin-point-color);
  color: var(--skin-base-color);
}
.playlist-player.skin-cm-sphere .player-album-thumb {
  display: none;
}
.playlist-player.skin-cm-sphere .player-album-info {
  flex-direction: row;
  width: 100%;
  align-items: center;
}
.playlist-player.skin-cm-sphere .player-album-title {
  width: auto;
  flex: 1;
  /* song-title 와 동일 — 첫 항목(앨범 헤더) 크기 통일 */
  font-size: 14px;
  line-height: 16px;
  font-weight: normal;
}
.playlist-player.skin-cm-sphere .player-album-meta {
  display: none;
}
.playlist-player.skin-cm-sphere .player-album-caret {
  position: static;
  transform: none;
  margin-left: 6px;
  font-size: 10px;
}
.playlist-player.skin-cm-sphere .player-albumlist.open .player-album.current .player-album-caret {
  transform: rotate(180deg);
}
