style.scss 6.2 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344
  1. .channel-sidebar {
  2. display: flex;
  3. flex-direction: column;
  4. height: 100%;
  5. overflow: hidden;
  6. transition: width 0.2s ease;
  7. @media (prefers-reduced-motion: reduce) {
  8. transition: none;
  9. }
  10. &__header {
  11. display: flex;
  12. align-items: center;
  13. justify-content: space-between;
  14. gap: 8px;
  15. padding: 8px 12px;
  16. font-size: 0.8125rem;
  17. font-weight: 600;
  18. color: var(--text-secondary);
  19. text-transform: uppercase;
  20. letter-spacing: 0.05em;
  21. border-bottom: 1px solid var(--border-default);
  22. flex-shrink: 0;
  23. min-height: 44px;
  24. overflow: hidden;
  25. }
  26. &__header-title {
  27. flex: 1;
  28. overflow: hidden;
  29. text-overflow: ellipsis;
  30. white-space: nowrap;
  31. }
  32. &__collapse-btn {
  33. position: relative;
  34. right: -10px;
  35. display: inline-flex;
  36. align-items: center;
  37. justify-content: center;
  38. width: 28px;
  39. height: 28px;
  40. border: none;
  41. background: transparent;
  42. color: var(--text-secondary);
  43. cursor: pointer;
  44. border-radius: 6px;
  45. flex-shrink: 0;
  46. transition: background 0.15s, color 0.15s;
  47. svg {
  48. font-size: 0.875rem;
  49. }
  50. &:hover {
  51. background: var(--bg-subtle);
  52. color: var(--text-primary);
  53. }
  54. // 모바일(≤1123px)에서는 햄버거 메뉴 오버레이가 사이드바 제어 담당 → 접기 버튼 숨김
  55. @media (max-width: 1123px) {
  56. display: none;
  57. }
  58. }
  59. &__list {
  60. overflow-y: auto;
  61. flex: 1;
  62. &::-webkit-scrollbar {
  63. width: 4px;
  64. }
  65. &::-webkit-scrollbar-thumb {
  66. background: var(--border-default);
  67. border-radius: 2px;
  68. }
  69. }
  70. &__loading, &__empty {
  71. padding: 24px 16px;
  72. text-align: center;
  73. font-size: 0.75rem;
  74. color: var(--text-muted);
  75. }
  76. &__item {
  77. display: flex;
  78. align-items: center;
  79. gap: 10px;
  80. padding: 8px 12px;
  81. cursor: pointer;
  82. transition: background 0.15s;
  83. &:hover {
  84. background: var(--bg-subtle);
  85. }
  86. &:focus-visible {
  87. outline: 2px solid var(--text-link);
  88. outline-offset: -2px;
  89. }
  90. &--live {
  91. background: rgba(0, 255, 0, 0.03);
  92. &:hover {
  93. background: rgba(0, 255, 0, 0.06);
  94. }
  95. }
  96. }
  97. &__thumb {
  98. position: relative;
  99. flex-shrink: 0;
  100. width: 36px;
  101. height: 36px;
  102. border-radius: 50%;
  103. overflow: hidden;
  104. background: var(--bg-subtle);
  105. img {
  106. width: 100%;
  107. height: 100%;
  108. object-fit: cover;
  109. }
  110. }
  111. &__thumb-dot {
  112. position: absolute;
  113. bottom: -1px;
  114. right: -1px;
  115. width: 10px;
  116. height: 10px;
  117. border-radius: 50%;
  118. background: #22c55e;
  119. border: 2px solid var(--bg-page);
  120. box-shadow: 0 0 4px rgba(34, 197, 94, 0.5);
  121. }
  122. &__info {
  123. flex: 1;
  124. min-width: 0;
  125. overflow: hidden;
  126. }
  127. &__name {
  128. font-size: 0.8125rem;
  129. font-weight: 500;
  130. color: var(--text-primary);
  131. white-space: nowrap;
  132. overflow: hidden;
  133. text-overflow: ellipsis;
  134. }
  135. &__sub {
  136. font-size: 0.6875rem;
  137. color: var(--text-muted);
  138. white-space: nowrap;
  139. overflow: hidden;
  140. text-overflow: ellipsis;
  141. }
  142. &__status {
  143. display: flex;
  144. align-items: center;
  145. gap: 6px;
  146. flex-shrink: 0;
  147. }
  148. &__viewers {
  149. font-size: 0.6875rem;
  150. color: var(--text-secondary);
  151. white-space: nowrap;
  152. }
  153. &__led {
  154. display: inline-block;
  155. width: 8px;
  156. height: 8px;
  157. border-radius: 50%;
  158. background: #dc2626;
  159. flex-shrink: 0;
  160. &--on {
  161. background: #22c55e;
  162. box-shadow: 0 0 4px rgba(34, 197, 94, 0.5);
  163. }
  164. }
  165. // ── 더 보기 ──
  166. &__more {
  167. display: flex;
  168. align-items: center;
  169. justify-content: center;
  170. width: 100%;
  171. padding: 10px 12px;
  172. border: none;
  173. background: transparent;
  174. color: var(--text-secondary);
  175. font-size: 0.8125rem;
  176. font-weight: 500;
  177. cursor: pointer;
  178. transition: background 0.15s, color 0.15s;
  179. svg {
  180. font-size: 0.9rem;
  181. }
  182. &:hover {
  183. background: var(--bg-subtle);
  184. color: var(--text-primary);
  185. }
  186. }
  187. // ── 하단: 다크모드 / 다국어 / 즐겨찾기 ──
  188. &__footer {
  189. margin-top: auto;
  190. border-top: 1px solid var(--border-default);
  191. position: relative;
  192. }
  193. &__footer-actions {
  194. display: flex;
  195. align-items: stretch;
  196. }
  197. &__icon-btn {
  198. flex: 1;
  199. display: flex;
  200. align-items: center;
  201. justify-content: center;
  202. height: 25px;
  203. border: none;
  204. background: none;
  205. color: var(--text-muted);
  206. cursor: pointer;
  207. transition: background 0.15s, color 0.15s;
  208. position: relative;
  209. // PC 확장 사이드바: 우측 메인 footer 높이(32px)와 정렬
  210. @media (min-width: 1124px) {
  211. height: 32px;
  212. }
  213. &:hover {
  214. background: var(--bg-subtle);
  215. color: var(--fg-default);
  216. }
  217. // 구분선
  218. & + & {
  219. border-left: 1px solid var(--border-default);
  220. }
  221. svg {
  222. width: 13px;
  223. height: 13px;
  224. }
  225. }
  226. &__lang-dropdown {
  227. position: absolute;
  228. bottom: 100%;
  229. left: 0;
  230. right: 0;
  231. background: var(--bg-page);
  232. border: 1px solid var(--border-default);
  233. border-bottom: none;
  234. border-radius: 8px 8px 0 0;
  235. box-shadow: 0 -4px 12px var(--shadow-color);
  236. overflow: hidden;
  237. z-index: 10;
  238. }
  239. &__lang-option {
  240. display: block;
  241. width: 100%;
  242. padding: 10px 14px;
  243. border: none;
  244. background: none;
  245. color: var(--text-secondary);
  246. font-size: 0.8125rem;
  247. text-align: left;
  248. cursor: pointer;
  249. transition: background 0.15s;
  250. &:hover {
  251. background: var(--bg-subtle);
  252. }
  253. &--active {
  254. color: var(--fg-default);
  255. font-weight: 600;
  256. }
  257. }
  258. // ═══════════════════════════════════════════════════
  259. // 축소 (collapsed) 모디파이어
  260. // 모바일(≤1124px)은 오버레이 방식이므로 축소 무시
  261. // ═══════════════════════════════════════════════════
  262. &--collapsed {
  263. @media (min-width: 1124px) {
  264. .channel-sidebar__header {
  265. justify-content: center;
  266. padding: 8px 6px;
  267. }
  268. // 축소 시에는 expanded용 -10px 오프셋을 제거해 썸네일과 수직축 맞춤
  269. .channel-sidebar__collapse-btn {
  270. right: 0;
  271. }
  272. .channel-sidebar__item {
  273. justify-content: center;
  274. padding: 8px 6px;
  275. // thumb 외 모든 요소는 축소 시 렌더 안 됨 (JSX에서 조건부)
  276. }
  277. .channel-sidebar__more {
  278. padding: 12px 6px;
  279. svg {
  280. font-size: 1rem;
  281. }
  282. }
  283. .channel-sidebar__footer-actions {
  284. flex-direction: column;
  285. }
  286. .channel-sidebar__icon-btn {
  287. height: 36px;
  288. flex: none;
  289. & + & {
  290. border-left: none;
  291. border-top: 1px solid var(--border-default);
  292. }
  293. }
  294. }
  295. }
  296. }