
:root {
  --bg: #060606;
  --bg2: #0D0D0D;
  --bg3: #161616;
  --glass: rgba(255, 255, 255, 0.045);
  --glass-border: rgba(255, 255, 255, 0.12);
  --blue: #FFFFFF;
  --blue-light: #E7E7EC;
  --cyan: #C7C7D1;
  --green: #808080;
  --text: #F8FAFC;
  --text-muted: #52525B;
  --text-dim: #A1A1AA;
  --grad: linear-gradient(135deg, #FFFFFF 0%, #C6C6CE 55%, #FFFFFF 100%);
  --grad-cyan: linear-gradient(135deg, #FFFFFF, #8E8E96);
  --grad-dark: linear-gradient(135deg, #050505, #1C1C1E);
  --on-light: #0A0A0A;
  --shadow-blue: 0 0 32px rgba(255, 255, 255, 0.18);
  --shadow-cyan: 0 0 28px rgba(255, 255, 255, 0.14);
  --radius: 16px;
  --radius-sm: 8px;
}

*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
body { font-family: 'Inter', sans-serif; background: var(--bg); color: var(--text); height: 100vh; overflow: hidden; display: flex; flex-direction: column; }


.bg-orb { position: fixed; border-radius: 50%; filter: blur(130px); opacity: .12; pointer-events: none; z-index: 0; }
.bg-orb.o1 { width: 500px; height: 500px; background: var(--blue); top: -100px; left: -100px; }
.bg-orb.o2 { width: 400px; height: 400px; background: var(--cyan); bottom: -100px; right: -100px; }


#channel-nav {
  position: relative; z-index: 100;
  display: flex; align-items: center; padding: 0 2rem; height: 65px;
  background: rgba(6, 6, 6, 0.85); border-bottom: 1px solid var(--glass-border);
  backdrop-filter: blur(25px); -webkit-backdrop-filter: blur(25px); flex-shrink: 0; gap: 1rem;
}
.nav-logo-sm {
  display: flex; align-items: center; gap: 10px;
  font-family: 'Outfit', sans-serif; font-size: 1.3rem; font-weight: 900;
  background: var(--grad-cyan); -webkit-background-clip: text; -webkit-text-fill-color: transparent;
  background-clip: text; text-decoration: none; white-space: nowrap;
}
.nav-logo-sm-img { width: 26px; height: 26px; object-fit: contain; flex-shrink: 0; filter: drop-shadow(0 0 8px rgba(255,255,255,0.25)); }
#nav-channel-name { font-size: .875rem; font-weight: 600; color: var(--blue-light); padding: 5px 14px; background: rgba(255, 255, 255, 0.08); border: 1px solid rgba(255, 255, 255, 0.25); border-radius: 50px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; max-width: 200px; }
.nav-spacer { flex: 1; }
.btn { display: inline-flex; align-items: center; gap: 6px; padding: 8px 16px; border-radius: 50px; font-size: .82rem; font-weight: 600; cursor: pointer; border: none; transition: all .2s; font-family: 'Inter', sans-serif; text-decoration: none; white-space: nowrap; }
.btn-ghost { background: transparent; color: var(--text-dim); border: 1px solid var(--glass-border); }
.btn-ghost:hover { background: var(--glass); color: var(--text); }
.btn-primary { background: var(--grad); color: var(--on-light); box-shadow: var(--shadow-blue); }
.btn-primary:hover { opacity: .9; transform: translateY(-1px); }
.btn-sm { padding: 6px 12px; font-size: .78rem; }


.nav-user { display: flex; align-items: center; gap: 8px; padding: 4px 12px 4px 4px; background: var(--glass); border: 1px solid var(--glass-border); border-radius: 50px; }
.nav-avatar { width: 28px; height: 28px; border-radius: 50%; display: flex; align-items: center; justify-content: center; font-size: .75rem; font-weight: 750; color: #fff; object-fit: cover; flex-shrink: 0; }
.nav-username { font-size: .82rem; font-weight: 600; color: var(--text-dim); }


#channel-layout {
  display: grid; grid-template-columns: 290px 1fr 360px;
  flex: 1; overflow: hidden; position: relative; z-index: 1;
}


#sidebar-left {
  border-right: 1px solid var(--glass-border);
  overflow-y: auto; overflow-x: hidden; padding: 1.8rem 1.4rem; display: flex; flex-direction: column; gap: 1.8rem;
  background: rgba(13, 13, 13, 0.4); -webkit-backdrop-filter: blur(10px); backdrop-filter: blur(10px);
}
.sidebar-section { display: flex; flex-direction: column; gap: .8rem; }
.sidebar-label { font-size: .72rem; font-weight: 750; text-transform: uppercase; letter-spacing: .12em; color: var(--text-muted); }
.sidebar-label-row { display: flex; align-items: center; justify-content: space-between; }
.channel-actions { display: flex; gap: 6px; }
.icon-btn {
  width: 28px; height: 28px; border-radius: 50%; background: var(--glass); border: 1px solid var(--glass-border);
  color: var(--text-dim); cursor: pointer; display: flex; align-items: center; justify-content: center; transition: all .2s;
}
.icon-btn:hover { color: var(--text); border-color: rgba(255,255,255,0.25); }
.icon-btn.active { color: #bfbfbf; border-color: rgba(191,191,191,.5); background: rgba(191,191,191,.12); }
.icon-btn.active svg { fill: #bfbfbf; }


.control-badge {
  display: inline-flex; align-items: center; gap: 6px; font-size: .72rem; font-weight: 700;
  padding: 4px 10px; border-radius: 50px; margin-top: 8px; width: fit-content;
}
.control-badge.can-control { color: var(--green); background: rgba(128,128,128,.12); border: 1px solid rgba(128,128,128,.35); }
.control-badge.read-only   { color: var(--text-dim); background: rgba(255,255,255,.04); border: 1px solid var(--glass-border); }


.controls-disabled { opacity: .4; pointer-events: none; filter: grayscale(.4); }
.channel-meta-name { font-family: 'Outfit', sans-serif; font-size: 1.3rem; font-weight: 850; letter-spacing: -0.01em; }
.private-badge {
  display: inline-flex; align-items: center; gap: 5px; width: fit-content;
  font-size: .68rem; font-weight: 700; color: #c2c2c2; background: rgba(128,128,128,0.12);
  border: 1px solid rgba(128,128,128,0.35); padding: 3px 10px; border-radius: 50px; margin: 2px 0 4px;
}
.channel-meta-desc { font-size: .85rem; color: var(--text-dim); line-height: 1.55; margin-bottom: 2px; }
.channel-meta-creator { display: flex; flex-direction: column; gap: 4px; font-size: .8rem; color: var(--text-muted); line-height: 1.4; margin-top: 2px; }
.ch-creator-row { display: flex; align-items: center; gap: 4px; flex-wrap: wrap; }
.ch-creator-link {
  background: none; border: none; padding: 0; margin: 0; cursor: pointer;
  color: var(--blue-light); font-weight: 650; font-size: inherit; font-family: inherit;
  text-decoration: none; border-bottom: 1px solid transparent; transition: all .15s;
}
.ch-creator-link:hover { color: var(--text); border-bottom-color: currentColor; }
.ch-age-row { display: flex; align-items: center; gap: 5px; font-size: .76rem; color: var(--text-muted); }
.ch-age-row i { flex-shrink: 0; opacity: .7; }
.current-genre-display {
  display: flex; align-items: center; gap: 8px; padding: 11px 15px;
  background: rgba(255, 255, 255, 0.08); border: 1px solid rgba(255, 255, 255, 0.25); border-radius: 10px;
}
.current-genre-display .genre-icon { display: flex; align-items: center; justify-content: center; color: var(--blue-light); flex-shrink: 0; }
.current-genre-display .genre-name { font-weight: 650; font-size: .92rem; color: var(--blue-light); }


.genre-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 7px; }
.genre-btn {
  display: flex; align-items: center; gap: 6px; padding: 9px 10px; border-radius: 8px;
  border: 1px solid var(--glass-border); background: var(--glass); color: var(--text-dim);
  font-size: .8rem; font-weight: 600; cursor: pointer; transition: all .2s;
}
.genre-btn:hover { border-color: rgba(255, 255, 255, 0.4); color: var(--blue-light); background: rgba(255, 255, 255, 0.05); }
.genre-btn.active { border-color: var(--blue); background: rgba(255, 255, 255, 0.15); color: var(--blue-light); box-shadow: 0 0 10px rgba(255, 255, 255,0.1); }


.search-source-toggle {
  display: flex; gap: 4px; background: var(--bg3); border: 1px solid var(--glass-border);
  border-radius: 7px; padding: 3px; margin: 8px 0 10px;
}
.search-source-btn {
  flex: 1; border: none; background: transparent; color: var(--text-muted); font-size: .72rem; font-weight: 700;
  padding: 6px 8px; border-radius: 5px; cursor: pointer; transition: all .15s; text-align: center;
}
.search-source-btn:hover { color: var(--text-dim); }
.search-source-btn.active { background: rgba(255, 255, 255, 0.15); color: var(--blue-light); }
.search-result-source-badge {
  display: inline-flex; align-items: center; gap: 3px; font-size: .62rem; font-weight: 700; color: #7f7f7f;
  text-transform: uppercase; letter-spacing: .02em; margin-top: 2px;
}


.search-box { display: flex; gap: 6px; }
.search-input {
  flex: 1; min-width: 0; padding: 10px 12px; background: var(--bg3); border: 1px solid var(--glass-border);
  border-radius: 8px; color: var(--text); font-size: .85rem; outline: none; font-family: 'Inter', sans-serif;
  transition: border-color .2s; text-overflow: ellipsis; white-space: nowrap; overflow: hidden;
}
.search-input:focus { border-color: var(--blue); }
.search-input::placeholder { color: var(--text-muted); }
.search-btn {
  padding: 10px 12px; background: rgba(255, 255, 255, 0.15); border: 1px solid rgba(255, 255, 255, 0.35);
  border-radius: 8px; color: var(--blue-light); cursor: pointer; transition: all .2s;
}
.search-btn:hover { background: var(--grad); color: var(--on-light); box-shadow: var(--shadow-blue); }


#player-center {
  display: flex; flex-direction: column; align-items: center; justify-content: center;
  gap: 2.2rem; padding: 2.2rem; overflow: hidden; position: relative;
}


#visualizer { display: flex; align-items: flex-end; justify-content: center; gap: 5px; height: 90px; }
.vis-bar {
  width: 5px; border-radius: 3px 3px 0 0; background: var(--grad-cyan);
  height: var(--min, 6px);
  animation: vis-anim var(--dur, .6s) ease-in-out infinite alternate;
  opacity: .8; transition: opacity .3s;
}
.vis-bar.paused { animation-play-state: paused; opacity: .2; }
@keyframes vis-anim { from { height: var(--min, 6px); } to { height: var(--max, 80px); } }


.video-container {
  width: 380px; height: 213px; border-radius: 12px; overflow: hidden;
  border: 1px solid rgba(255, 255, 255, 0.25);
  box-shadow: 0 15px 45px rgba(0,0,0,0.5), var(--shadow-blue);
  position: relative; background: #000; flex-shrink: 0;
  transition: all 0.3s ease;
}
.video-container iframe {
  width: 100%; height: 100%; border: none;
}
.video-click-shield {
  position: absolute; inset: 0; z-index: 2; background: transparent;
}


.track-info { text-align: center; }
.track-title { font-family: 'Outfit', sans-serif; font-size: 1.45rem; font-weight: 850; margin-bottom: 5px; letter-spacing: -0.01em; }
.track-artist { font-size: .95rem; color: var(--text-dim); }


.progress-container { width: 100%; max-width: 440px; }
.progress-bar-wrapper {
  width: 100%; height: 5px; background: rgba(255,255,255,0.08); border-radius: 3px;
  cursor: pointer; position: relative; margin-bottom: 8px;
}
.progress-bar-fill { height: 100%; background: var(--grad-cyan); border-radius: 3px; width: 0%; transition: width 0.3s linear; }
.progress-times { display: flex; justify-content: space-between; font-size: .75rem; color: var(--text-muted); font-weight: 550; }


.player-controls { display: flex; align-items: center; gap: 1.2rem; }
.ctrl-btn {
  width: 44px; height: 44px; border-radius: 50%; background: var(--glass);
  border: 1px solid var(--glass-border); color: var(--text-dim); cursor: pointer;
  display: flex; align-items: center; justify-content: center; transition: all .2s;
}
.ctrl-btn:hover { background: rgba(255,255,255,0.08); color: var(--text); transform: scale(1.08); border-color: rgba(255,255,255,0.2); }
.ctrl-btn.large { width: 60px; height: 60px; background: var(--grad); border: none; color: var(--on-light); box-shadow: var(--shadow-blue); }
.ctrl-btn.large:hover { transform: scale(1.06); box-shadow: 0 0 45px rgba(255, 255, 255,0.65); filter: brightness(1.08); }
.ctrl-btn.active { color: var(--cyan); border-color: var(--cyan); text-shadow: 0 0 8px rgba(255, 255, 255,0.4); }


.volume-bar { display: flex; align-items: center; gap: 12px; }
.volume-slider {
  width: 110px; height: 5px; appearance: none; background: rgba(255,255,255,0.08);
  border-radius: 3px; cursor: pointer; outline: none;
}
.volume-slider::-webkit-slider-thumb { appearance: none; width: 14px; height: 14px; border-radius: 50%; background: var(--cyan); cursor: pointer; box-shadow: 0 0 8px var(--cyan); }


#sidebar-right {
  border-left: 1px solid var(--glass-border); display: flex; flex-direction: column;
  background: rgba(13, 13, 13, 0.4); -webkit-backdrop-filter: blur(10px); backdrop-filter: blur(10px); overflow: hidden;
}
.sidebar-tab-bar { display: flex; border-bottom: 1px solid var(--glass-border); flex-shrink: 0; }
.sidebar-tab {
  flex: 1; padding: 16px 10px; text-align: center; font-size: .85rem; font-weight: 600;
  color: var(--text-muted); cursor: pointer; border-bottom: 2px solid transparent;
  transition: all .2s; display: flex; align-items: center; justify-content: center;
  gap: 6px; white-space: nowrap;
}
.sidebar-tab i { flex-shrink: 0; }
.sidebar-tab.active { color: var(--blue-light); border-bottom-color: var(--blue); }


#listeners-panel { flex: 1; overflow-y: auto; padding: 1.4rem; display: none; }
#listeners-panel.active { display: block; }
.listener-item { display: flex; align-items: center; gap: 10px; padding: 8px 12px; border-radius: 8px; transition: background .15s; }
.listener-item:hover { background: var(--glass); }
.listener-avatar { width: 34px; height: 34px; border-radius: 50%; display: flex; align-items: center; justify-content: center; font-size: .82rem; font-weight: 750; color: #fff; flex-shrink: 0; box-shadow: inset 0 0 6px rgba(255,255,255,0.2); object-fit: cover; }
.listener-name { font-size: .88rem; font-weight: 600; color: var(--text-dim); flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.listener-badge { font-size: .72rem; font-weight: 650; margin-left: auto; }


#queue-panel { flex: 1; overflow-y: auto; padding: 1.4rem; display: none; }
#queue-panel.active { display: block; }
.queue-item { display: flex; align-items: center; gap: 10px; padding: 8px 10px; border-radius: 8px; transition: background .15s; cursor: pointer; }
.queue-item:hover { background: var(--glass); }
.queue-item-index { width: 20px; text-align: center; font-size: .75rem; color: var(--text-muted); font-weight: 700; flex-shrink: 0; }
.queue-item-thumb { width: 40px; height: 30px; border-radius: 4px; object-fit: cover; flex-shrink: 0; background: var(--bg3); }
.queue-item-info { flex: 1; overflow: hidden; }
.queue-item-title { font-size: .82rem; font-weight: 600; color: var(--text); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.queue-item-artist { font-size: .72rem; color: var(--text-dim); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.queue-empty { text-align: center; color: var(--text-muted); font-size: .85rem; padding: 2rem 1rem; }


#chat-panel { flex: 1; display: none; flex-direction: column; overflow: hidden; }
#chat-panel.active { display: flex; }
#chat-messages { flex: 1; overflow-y: auto; padding: 1.4rem; display: flex; flex-direction: column; gap: 10px; }
.chat-msg { display: flex; gap: 10px; }
.chat-msg-avatar { width: 30px; height: 30px; border-radius: 50%; display: flex; align-items: center; justify-content: center; font-size: .7rem; font-weight: 750; color: #fff; flex-shrink: 0; margin-top: 2px; object-fit: cover; }
.chat-msg-body { flex: 1; }
.chat-msg-header { display: flex; align-items: center; gap: 6px; margin-bottom: 2px; }
.chat-msg-name { font-size: .82rem; font-weight: 700; }
.chat-msg-time { font-size: .7rem; color: var(--text-muted); }
.chat-msg-text { font-size: .85rem; color: var(--text-dim); line-height: 1.45; word-break: break-word; }
.chat-system { font-size: .75rem; color: var(--text-muted); text-align: center; padding: 4px; font-style: italic; background: rgba(255, 255, 255, 0.05); border-radius: 6px; margin: 4px 0; }
#chat-input-area { padding: 14px; border-top: 1px solid var(--glass-border); display: flex; gap: 8px; flex-shrink: 0; }
#chat-input {
  flex: 1; padding: 11px 14px; background: var(--bg3); border: 1px solid var(--glass-border);
  border-radius: 8px; color: var(--text); font-size: .85rem; outline: none; font-family: 'Inter', sans-serif;
  transition: border-color .2s;
}
#chat-input:focus { border-color: var(--blue); }
#chat-input::placeholder { color: var(--text-muted); }
#chat-send-btn {
  width: 40px; height: 40px; border-radius: 8px; background: var(--grad);
  border: none; color: var(--on-light); cursor: pointer; display: flex; align-items: center; justify-content: center;
  flex-shrink: 0; transition: opacity .2s; box-shadow: var(--shadow-blue);
}
#chat-send-btn:hover { opacity: .9; }


html, body {
  cursor: url('data:image/svg+xml,%3Csvg%20xmlns%3D%22http%3A//www.w3.org/2000/svg%22%20width%3D%2224%22%20height%3D%2224%22%20viewBox%3D%220%200%2024%2024%22%3E%3Cpath%20d%3D%22M4%202%20L4%2020.5%20L8.6%2016.3%20L11.6%2022.2%20L14.3%2020.9%20L11.3%2015%20L17.2%2015%20Z%22%20fill%3D%22%23FFFFFF%22%20stroke%3D%22%23ffffff%22%20stroke-width%3D%221.3%22%20stroke-linejoin%3D%22round%22/%3E%3C/svg%3E') 2 2, auto;
}
a, button, [role="button"], select, .genre-btn, .icon-btn, .ctrl-btn, .sidebar-tab,
.search-btn, .filter-btn, input[type="checkbox"], input[type="range"], .nav-user,
.chat-msg, .listener-item.clickable, .queue-item {
  cursor: url('data:image/svg+xml,%3Csvg%20xmlns%3D%22http%3A//www.w3.org/2000/svg%22%20width%3D%2224%22%20height%3D%2224%22%20viewBox%3D%220%200%2024%2024%22%3E%3Cpath%20d%3D%22M4%202%20L4%2020.5%20L8.6%2016.3%20L11.6%2022.2%20L14.3%2020.9%20L11.3%2015%20L17.2%2015%20Z%22%20fill%3D%22%23E7E7EC%22%20stroke%3D%22%23ffffff%22%20stroke-width%3D%221.3%22%20stroke-linejoin%3D%22round%22/%3E%3C/svg%3E') 2 2, pointer;
}


::-webkit-scrollbar { width: 4px; }
::-webkit-scrollbar-track { background: transparent; }
::-webkit-scrollbar-thumb { background: rgba(255, 255, 255, 0.35); border-radius: 2px; }


#toast-container { position: fixed; bottom: 1.5rem; right: 1.5rem; z-index: 9999; display: flex; flex-direction: column; gap: 8px; }
.toast { display: flex; align-items: center; gap: 10px; padding: 12px 16px; background: var(--bg2); border: 1px solid var(--glass-border); border-radius: 10px; min-width: 240px; font-size: .82rem; box-shadow: 0 10px 40px rgba(0,0,0,0.5); animation: toast-in .3s ease; }
.toast.success { border-color: rgba(128,128,128,0.4); }
.toast.error { border-color: rgba(119,119,119,0.4); }
@keyframes toast-in { from { opacity:0; transform:translateX(100%); } to { opacity:1; transform:translateX(0); } }


.search-results-container {
  display: flex;
  flex-direction: column;
  gap: 4px;
  margin-top: 10px;
  background: rgba(13, 13, 13, 0.7);
  border: 1px solid var(--glass-border);
  border-radius: 8px;
  max-height: 250px;
  overflow-y: auto;
  box-shadow: 0 10px 30px rgba(0,0,0,0.5), var(--shadow-blue);
  -webkit-backdrop-filter: blur(10px); backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
}
.search-results-container:empty {
  display: none;
}
.search-result-item {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 8px 12px;
  cursor: pointer;
  transition: background 0.2s;
  border-bottom: 1px solid rgba(255, 255, 255, 0.03);
}
.search-result-item:last-child {
  border-bottom: none;
}
.search-result-item:hover {
  background: rgba(255, 255, 255, 0.15);
}
.search-result-thumb {
  width: 44px;
  height: 33px;
  border-radius: 4px;
  object-fit: cover;
  flex-shrink: 0;
}
.search-result-details {
  flex: 1;
  overflow: hidden;
}
.search-result-title {
  font-size: 0.8rem;
  font-weight: 600;
  color: var(--text);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.search-result-artist {
  font-size: 0.7rem;
  color: var(--text-dim);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}


a:focus-visible, button:focus-visible, input:focus-visible, [tabindex]:focus-visible {
  outline: 2px solid var(--cyan); outline-offset: 2px; border-radius: 4px;
}
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: 0.001ms !important; animation-iteration-count: 1 !important; transition-duration: 0.001ms !important; }
}




@media (max-width: 1180px) {
  #channel-layout { grid-template-columns: 250px 1fr 300px; }
  #sidebar-left { padding: 1.5rem 1.1rem; gap: 1.4rem; }
}

@media (max-width: 950px) {
  body { height: auto; overflow-y: auto; }
  #channel-layout { grid-template-columns: 1fr; grid-template-rows: auto auto auto; }

  
  #sidebar-left { max-height: none; overflow: visible; }
  #sidebar-right { max-height: 65vh; }
  .sidebar-tab-bar { position: sticky; top: 0; z-index: 5; background: var(--bg2); }

  .video-container { width: 100%; max-width: 380px; height: auto; aspect-ratio: 16/9; }
  #nav-channel-name { max-width: 120px; }

  
  #player-center { order: 1; }
  #sidebar-left { order: 2; border-right: none; border-bottom: 1px solid var(--glass-border); }
  #sidebar-right { order: 3; border-left: none; border-top: 1px solid var(--glass-border); }

  
  .ctrl-btn { width: 46px; height: 46px; }
  .ctrl-btn.large { width: 62px; height: 62px; }
  .icon-btn { width: 36px; height: 36px; }
  .sidebar-tab { padding: 14px 8px; }
  .genre-btn { padding: 11px 10px; }
  .search-btn, #chat-send-btn { min-width: 44px; min-height: 44px; }

  
  .volume-bar { display: none; }

  
  .progress-container { max-width: 100%; }

  
  .search-input, #chat-input { font-size: 16px; }

  
  #chat-input-area { padding-bottom: max(14px, env(safe-area-inset-bottom)); }
}

@media (max-width: 700px) {
  #channel-nav { padding: 0 1rem; gap: .6rem; }
  
  .nav-user .nav-username { display: none; }
  .nav-user { padding: 4px; }
  #nav-user-area .btn span { display: none; }
  #nav-user-area .btn { padding: 8px 12px; }
}

@media (max-width: 480px) {
  #channel-nav { padding: 0 .8rem; }
  #nav-channel-name { max-width: 100px; }
  .sidebar-tab { padding: 12px 4px; font-size: .78rem; gap: 4px; }
}

@media (max-width: 380px) {
  #channel-nav { padding: 0 .75rem; gap: .4rem; }
  .nav-logo-sm { font-size: 1.1rem; }
  #nav-channel-name { max-width: 90px; font-size: .78rem; padding: 4px 10px; }
  #sidebar-right { max-height: 60vh; }
  #sidebar-left { padding: 1.3rem 1rem; gap: 1.4rem; }
  
  .player-controls { gap: .5rem; justify-content: space-between; width: 100%; max-width: 320px; }
  .ctrl-btn { width: 44px; height: 44px; }
  .ctrl-btn.large { width: 58px; height: 58px; }
  .video-container { max-width: 100%; }
  .track-title { font-size: 1.2rem; }
  .sidebar-tab { padding: 12px 6px; }
  
  .sidebar-tab .tab-label { display: none; }
}


@media (max-width: 420px) {
  .groups-subform { flex-direction: column; }
  .groups-subform .btn { width: 100%; justify-content: center; }
}


@media (max-height: 700px) {
  body { height: auto; min-height: 100vh; overflow-y: auto; }
  #sidebar-right { max-height: 60vh; }
  #player-center { padding: 1.4rem; gap: 1.3rem; }
  .video-container { width: 300px; height: 168px; }
  #visualizer { height: 60px; }
}


@media (hover: none) {
  .icon-btn { width: 36px; height: 36px; }
  .ctrl-btn { min-width: 44px; min-height: 44px; }
  .ctrl-btn.large { min-width: 58px; min-height: 58px; }
  .sidebar-tab, .genre-btn, .search-btn, .queue-item, .listener-item, #chat-send-btn {
    -webkit-tap-highlight-color: transparent;
  }
  .ctrl-btn:active, .icon-btn:active, .genre-btn:active, .search-btn:active,
  #chat-send-btn:active, .sidebar-tab:active { transform: scale(.92); opacity: .85; }
  
  html, body, a, button, [role="button"], select, .genre-btn, .icon-btn, .ctrl-btn, .sidebar-tab,
  .search-btn, .filter-btn, input, .nav-user, .chat-msg, .listener-item.clickable, .queue-item {
    cursor: auto !important;
  }
  
  button, a, .ctrl-btn, .icon-btn, .genre-btn, .search-btn, .sidebar-tab { touch-action: manipulation; }
}
