watch.css 14 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675
  1. body {
  2. display: grid;
  3. grid-gap: 20px;
  4. grid-template-areas:
  5. "header"
  6. "main"
  7. "footer";
  8. /* Fix height */
  9. height: 100vh;
  10. grid-template-rows: auto 1fr auto;
  11. /* fix top and bottom */
  12. margin-left: 1rem;
  13. margin-right: 1rem;
  14. }
  15. img {
  16. width: 100%;
  17. height: auto;
  18. }
  19. video {
  20. width: 100%;
  21. height: auto;
  22. max-height: calc(100vh/1.5);
  23. }
  24. a:link {
  25. color: var(--link);
  26. }
  27. a:visited {
  28. color: var(--link-visited);
  29. }
  30. input[type="text"],
  31. input[type="search"] {
  32. background: var(--background);
  33. border: 1px solid var(--button-border);
  34. border-radius: 5px;
  35. padding: 0.4rem 0.4rem;
  36. font-size: 15px;
  37. color: var(--search-text);
  38. outline: none;
  39. box-shadow: none;
  40. }
  41. input[type='search'] {
  42. border-bottom: 1px solid var(--button-border);
  43. border-top: 0px;
  44. border-left: 0px;
  45. border-right: 0px;
  46. border-radius: 0px;
  47. }
  48. header {
  49. display: grid;
  50. grid-gap: 4px;
  51. grid-template-areas:
  52. "home"
  53. "form"
  54. "playlist";
  55. grid-area: header;
  56. }
  57. .home {
  58. grid-area: home;
  59. margin-left: auto;
  60. margin-right: auto;
  61. margin-bottom: 1rem;
  62. margin-top: 1rem;
  63. }
  64. .form {
  65. display: grid;
  66. grid-gap: 4px;
  67. grid-template-areas:
  68. "search-box"
  69. "search-button"
  70. "dropdown";
  71. grid-area: form;
  72. }
  73. .search-box {
  74. grid-area: search-box;
  75. }
  76. .search-button {
  77. grid-area: search-button;
  78. cursor: pointer;
  79. padding-bottom: 6px;
  80. padding-left: .75em;
  81. padding-right: .75em;
  82. padding-top: 6px;
  83. text-align: center;
  84. white-space: nowrap;
  85. background-color: var(--buttom);
  86. border: 1px solid var(--button-border);
  87. color: var(--buttom-text);
  88. border-radius: 5px;
  89. }
  90. .search-button:hover {
  91. background-color: var(--buttom-hover);
  92. }
  93. .dropdown {
  94. display: grid;
  95. grid-gap: 1px;
  96. grid-template-areas:
  97. "dropdown-label"
  98. "dropdown-content";
  99. grid-area: dropdown;
  100. }
  101. .dropdown-label {
  102. grid-area: dropdown-label;
  103. padding-bottom: 6px;
  104. padding-left: .75em;
  105. padding-right: .75em;
  106. padding-top: 6px;
  107. text-align: center;
  108. white-space: nowrap;
  109. background-color: var(--buttom);
  110. border: 1px solid var(--button-border);
  111. color: var(--buttom-text);
  112. border-radius: 5px;
  113. }
  114. .dropdown-label:hover {
  115. background-color: var(--buttom-hover);
  116. }
  117. .playlist {
  118. display: grid;
  119. grid-gap: 4px;
  120. grid-template-areas:
  121. "play-box"
  122. "play-hidden"
  123. "play-add"
  124. "play-clean";
  125. grid-area: playlist;
  126. }
  127. .play-box {
  128. grid-area: play-box;
  129. }
  130. .play-hidden {
  131. grid-area: play-hidden;
  132. }
  133. .play-add {
  134. grid-area: play-add;
  135. cursor: pointer;
  136. padding-bottom: 6px;
  137. padding-left: .75em;
  138. padding-right: .75em;
  139. padding-top: 6px;
  140. text-align: center;
  141. white-space: nowrap;
  142. background-color: var(--buttom);
  143. border: 1px solid var(--button-border);
  144. color: var(--buttom-text);
  145. border-radius: 5px;
  146. }
  147. .play-add:hover {
  148. background-color: var(--buttom-hover);
  149. }
  150. .play-clean {
  151. display: grid;
  152. grid-area: play-clean;
  153. }
  154. .play-clean > button {
  155. padding-bottom: 6px;
  156. padding-left: .75em;
  157. padding-right: .75em;
  158. padding-top: 6px;
  159. text-align: center;
  160. white-space: nowrap;
  161. background-color: var(--buttom);
  162. border: 1px solid var(--button-border);
  163. color: var(--buttom-text);
  164. border-radius: 5px;
  165. }
  166. .play-clean > button:hover {
  167. background-color: var(--buttom-hover);
  168. }
  169. /* ------------- Menu Mobile sin JS ---------------- */
  170. /* input hidden */
  171. .opt-box {
  172. display: none;
  173. }
  174. .dropdown-content {
  175. display: none;
  176. grid-area: dropdown-content;
  177. }
  178. label[for=options-toggle-cbox] {
  179. cursor: pointer;
  180. -webkit-touch-callout: none;
  181. -webkit-user-select: none;
  182. -khtml-user-select: none;
  183. -moz-user-select: none;
  184. -ms-user-select: none;
  185. user-select: none;
  186. }
  187. #options-toggle-cbox:checked ~ .dropdown-content {
  188. display: block;
  189. white-space: nowrap;
  190. background: var(--secondary-background);
  191. padding: 0.5rem 1rem;
  192. }
  193. /*- ----------- End Menu Mobile sin JS ------------- */
  194. .main {
  195. grid-area: main;
  196. margin: 0 auto;
  197. display: grid;
  198. grid-gap: 1px;
  199. grid-template-columns: 1fr;
  200. grid-template-areas:
  201. "sc-video"
  202. "sc-info";
  203. }
  204. figure.sc-video {
  205. margin: 1rem 0px;
  206. }
  207. .sc-video { grid-area: sc-video; }
  208. .sc-info {
  209. display: grid;
  210. grid-template-columns: 1fr;
  211. grid-gap: 1px;
  212. grid-template-areas:
  213. "video-info"
  214. "side-videos"
  215. "comments-area-outer";
  216. grid-area: sc-info;
  217. }
  218. .video-info {
  219. grid-area: video-info;
  220. display: grid;
  221. grid-template-columns: 1fr 1fr;
  222. grid-template-areas:
  223. "v-title v-title"
  224. "v-uploaded v-views"
  225. "v-published v-likes-dislikes"
  226. "external-player-controls v-checkbox"
  227. "v-direct-link v-direct-link"
  228. "v-download v-download"
  229. "v-description v-description"
  230. "v-music-list v-music-list"
  231. "v-more-info v-more-info";
  232. }
  233. .v-title {
  234. grid-area: v-title;
  235. margin: 0px;
  236. }
  237. .v-uploaded { grid-area: v-uploaded; }
  238. .v-views {
  239. grid-area: v-views;
  240. justify-self: end;
  241. }
  242. .v-published { grid-area: v-published; }
  243. .v-likes-dislikes {
  244. grid-area: v-likes-dislikes;
  245. justify-self: end;
  246. }
  247. .external-player-controls {
  248. grid-area: external-player-controls;
  249. }
  250. .external-player-controls input.speed {
  251. width: 65px;
  252. text-align: center;
  253. }
  254. .v-checkbox {
  255. grid-area: v-checkbox;
  256. justify-self: end;
  257. }
  258. .v-direct-link {
  259. grid-area: v-direct-link;
  260. padding-top: 0.5rem;
  261. padding-bottom: 0.5rem;
  262. }
  263. .v-download { grid-area: v-download; }
  264. .v-download > ul.download-dropdown-content {
  265. background: var(--secondary-background);
  266. padding-left: 0px;
  267. }
  268. .v-download > ul.download-dropdown-content > li.download-format {
  269. list-style: none;
  270. padding: 0.4rem 0;
  271. padding-left: 1rem;
  272. }
  273. .v-download > ul.download-dropdown-content > li.download-format a.download-link {
  274. text-decoration: none;
  275. }
  276. .v-description {
  277. grid-area: v-description;
  278. background-color: var(--secondary-background);
  279. margin-top: 0.4rem;
  280. white-space: pre-wrap;
  281. overflow: hidden;
  282. text-overflow: ellipsis;
  283. word-wrap: break-word;
  284. padding: 5px;
  285. }
  286. .v-music-list {
  287. grid-area: v-music-list;
  288. padding-bottom: 1rem;
  289. }
  290. .v-music-list table,th,td{
  291. border: 1px solid;
  292. }
  293. .v-music-list th,td{
  294. padding-left:4px;
  295. padding-right:5px;
  296. }
  297. .v-music-list caption{
  298. text-align:left;
  299. font-weight:bold;
  300. margin-bottom:5px;
  301. }
  302. .v-more-info {
  303. grid-area: v-more-info;
  304. }
  305. .v-more-info > .more-info-content {
  306. background-color: var(--secondary-background);
  307. padding: 5px;
  308. }
  309. .side-videos { grid-area: side-videos; }
  310. .side-videos .related-autoplay {
  311. display: grid;
  312. grid-template-columns: repeat(2, auto);
  313. justify-content: start;
  314. grid-column-gap: 0.5rem;
  315. align-items: center;
  316. }
  317. /* playlist items */
  318. .side-videos .site-playlist {
  319. border-style: solid;
  320. border-width: 2px;
  321. border-color: var(--secondary-focus);
  322. margin-bottom: 1rem;
  323. }
  324. .side-videos .site-playlist .playlist-header {
  325. background-color: var(--secondary-background);
  326. padding: 1rem;
  327. border-bottom-style: solid;
  328. border-bottom-width: 2px;
  329. border-bottom-color: var(--secondary-focus);
  330. }
  331. .side-videos .site-playlist .playlist-header h3 {
  332. margin: 0px;
  333. padding: 0px;
  334. }
  335. .side-videos .site-playlist .playlist-header .playlist-metadata {
  336. list-style: none;
  337. display: grid;
  338. justify-content: start;
  339. padding: 0;
  340. margin: 0px;
  341. grid-template-columns: repeat(3, auto);
  342. grid-column-gap: 1rem;
  343. }
  344. .side-videos .site-playlist .playlist-videos {
  345. display: grid;
  346. grid-row-gap: 1rem;
  347. height: 300px;
  348. overflow-y: scroll;
  349. padding-top: 1rem;
  350. }
  351. .side-videos .site-playlist .playlist-videos article.item-box {
  352. padding-left: 1rem;
  353. }
  354. /* /playlist items */
  355. .comments-area-outer { grid-area: comments-area-outer; }
  356. .related-videos-inner {
  357. padding-top: 10px;
  358. display: grid;
  359. grid-row-gap: 1rem;
  360. }
  361. .item-box {
  362. display: grid;
  363. grid-template-columns: 1.9fr 0.1fr;
  364. grid-template-rows: 1fr;
  365. grid-gap: 1px;
  366. grid-template-areas:
  367. "item-video item-checkbox";
  368. }
  369. .item-video {
  370. grid-area: item-video;
  371. display: grid;
  372. grid-template-columns: auto;
  373. grid-template-rows: repeat(4, auto);
  374. grid-row-gap: 0.4rem;
  375. grid-template-areas:
  376. "thumbnail-box"
  377. "info-box";
  378. align-items: center;
  379. font-size: 0.7rem;
  380. }
  381. .item-video a {
  382. text-decoration: none;
  383. cursor: pointer;
  384. }
  385. .thumbnail-box {
  386. grid-area: thumbnail-box;
  387. position: relative;
  388. }
  389. .thumbnail {
  390. padding: 28.125%;
  391. position: relative;
  392. box-sizing: border-box;
  393. }
  394. .thumbnail-img {
  395. position: absolute;
  396. width: 100%;
  397. height: 100%;
  398. left: 0;
  399. top: 0;
  400. object-fit: cover;
  401. background-color: var(--thumb-background);
  402. }
  403. .length {
  404. position: absolute;
  405. background-color: rgba(35, 35, 35, 0.75);
  406. color: #fff;
  407. border-radius: 2px;
  408. padding: 2px;
  409. font-size: 16px;
  410. right: 0.25em;
  411. bottom: -0.75em;
  412. }
  413. .info-box {
  414. grid-area: info-box;
  415. display: grid;
  416. grid-template-columns: 1fr;
  417. grid-template-rows: auto auto auto auto auto;
  418. grid-gap: 1px;
  419. grid-template-areas:
  420. "."
  421. "."
  422. "."
  423. "."
  424. ".";
  425. }
  426. .title {
  427. font-size: 0.8rem;
  428. margin: 0px;
  429. font-weight: normal;
  430. overflow: hidden;
  431. text-overflow: ellipsis;
  432. }
  433. .info-box address {
  434. white-space: nowrap;
  435. overflow: hidden;
  436. text-overflow: ellipsis;
  437. }
  438. .thumbnail-info {
  439. background-color: var(--time-background);
  440. color: #fff;
  441. padding: 2px 5px;
  442. text-transform: uppercase;
  443. font-weight: 700;
  444. font-size: 12px;
  445. position: absolute;
  446. right: 0;
  447. bottom: .2rem;
  448. }
  449. .item-checkbox {
  450. grid-area: item-checkbox;
  451. justify-self: start;
  452. align-self: center;
  453. min-width: 30px;
  454. margin: 0px;
  455. }
  456. .stats {
  457. display: flex;
  458. justify-content: space-between;
  459. }
  460. /* comments */
  461. .comments-area {
  462. display: grid;
  463. grid-row-gap: 0.5rem;
  464. }
  465. .comments {
  466. display: grid;
  467. grid-row-gap: 0.5rem;
  468. }
  469. .comment {
  470. display: grid;
  471. grid-template-columns: repeat(3, auto) 3fr;
  472. grid-template-rows: repeat(4, auto);
  473. grid-column-gap: 0.4rem;
  474. grid-template-areas:
  475. "author-avatar author-name permalink ."
  476. "author-avatar comment-text comment-text comment-text"
  477. ". comment-likes comment-likes comment-likes"
  478. ". button-row button-row button-row";
  479. background: var(--secondary-background);
  480. }
  481. .author-avatar { grid-area: author-avatar; }
  482. .author-name {
  483. grid-area: author-name;
  484. overflow: hidden;
  485. text-overflow: ellipsis;
  486. }
  487. .permalink { grid-area: permalink; }
  488. .comment-text {
  489. grid-area: comment-text;
  490. overflow: hidden;
  491. text-overflow: ellipsis;
  492. }
  493. .comment-likes { grid-area: comment-likes; }
  494. .button-row { grid-area: button-row; }
  495. .more-comments {
  496. justify-self: center;
  497. margin-top: 10px;
  498. margin-bottom: 10px;
  499. background: var(--secondary-background);
  500. padding: 5px;
  501. /* disable text selection */
  502. -webkit-touch-callout: none;
  503. -webkit-user-select: none;
  504. -khtml-user-select: none;
  505. -moz-user-select: none;
  506. -ms-user-select: none;
  507. user-select: none;
  508. }
  509. .footer {
  510. grid-area: footer;
  511. display: grid;
  512. grid-template-columns: auto;
  513. align-items: center;
  514. justify-content: center;
  515. margin: auto;
  516. text-align: center;
  517. }
  518. .footer > p {
  519. text-align: center;
  520. }
  521. @media (min-width: 480px) {
  522. .item-video {
  523. font-size: 0.85rem;
  524. }
  525. .title {
  526. font-size: 1rem;
  527. }
  528. }
  529. @media (min-width: 992px) {
  530. body {
  531. display: grid;
  532. grid-template-columns: 0.3fr 2fr 1fr 0.3fr;
  533. grid-template-rows: auto 1fr auto;
  534. grid-template-areas:
  535. "header header header header"
  536. ". main main ."
  537. "footer footer footer footer";
  538. }
  539. .form {
  540. display: grid;
  541. grid-gap: 1px;
  542. grid-template-columns: 1fr 1.4fr 0.3fr 1.3fr;
  543. grid-template-areas: ". search-box search-button dropdown";
  544. grid-area: form;
  545. position: relative;
  546. }
  547. .dropdown {
  548. display: grid;
  549. grid-gap: 1px;
  550. grid-template-columns: 100px auto;
  551. grid-template-areas:
  552. "dropdown-label"
  553. "dropdown-content";
  554. grid-area: dropdown;
  555. position: absolute;
  556. z-index: 1;
  557. }
  558. #options-toggle-cbox:checked ~ .dropdown-content {
  559. width: calc(100% + 100px);
  560. max-height: 80vh;
  561. overflow-y: scroll;
  562. }
  563. .playlist {
  564. display: grid;
  565. grid-gap: 1px;
  566. grid-template-columns: 1fr 1.4fr 0.3fr 1.3fr;
  567. grid-template-areas: ". play-box play-add play-clean";
  568. grid-area: playlist;
  569. }
  570. .play-clean {
  571. grid-template-columns: 100px auto;
  572. }
  573. .play-clean > button {
  574. padding-bottom: 6px;
  575. padding-left: .75em;
  576. padding-right: .75em;
  577. padding-top: 6px;
  578. text-align: center;
  579. white-space: nowrap;
  580. background-color: var(--buttom);
  581. color: var(--buttom-text);
  582. border-radius: 5px;
  583. cursor: pointer;
  584. }
  585. .main {
  586. grid-area: main;
  587. margin: 0px;
  588. }
  589. .sc-info {
  590. display: grid;
  591. grid-template-columns: 3fr 1fr;
  592. grid-gap: 1px 40px;
  593. grid-template-areas:
  594. "video-info side-videos"
  595. "comments-area-outer side-videos"
  596. ". side-videos";
  597. grid-area: sc-info;
  598. }
  599. .footer {
  600. display: grid;
  601. grid-template-columns: repeat(3, 1fr);
  602. grid-column-gap: 2rem;
  603. align-items: center;
  604. justify-content: center;
  605. text-align: center;
  606. margin-top: 1rem;
  607. margin-bottom: 1rem;
  608. }
  609. }