style.scss 24 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576777879808182838485868788899091929394959697989910010110210310410510610710810911011111211311411511611711811912012112212312412512612712812913013113213313413513613713813914014114214314414514614714814915015115215315415515615715815916016116216316416516616716816917017117217317417517617717817918018118218318418518618718818919019119219319419519619719819920020120220320420520620720820921021121221321421521621721821922022122222322422522622722822923023123223323423523623723823924024124224324424524624724824925025125225325425525625725825926026126226326426526626726826927027127227327427527627727827928028128228328428528628728828929029129229329429529629729829930030130230330430530630730830931031131231331431531631731831932032132232332432532632732832933033133233333433533633733833934034134234334434534634734834935035135235335435535635735835936036136236336436536636736836937037137237337437537637737837938038138238338438538638738838939039139239339439539639739839940040140240340440540640740840941041141241341441541641741841942042142242342442542642742842943043143243343443543643743843944044144244344444544644744844945045145245345445545645745845946046146246346446546646746846947047147247347447547647747847948048148248348448548648748848949049149249349449549649749849950050150250350450550650750850951051151251351451551651751851952052152252352452552652752852953053153253353453553653753853954054154254354454554654754854955055155255355455555655755855956056156256356456556656756856957057157257357457557657757857958058158258358458558658758858959059159259359459559659759859960060160260360460560660760860961061161261361461561661761861962062162262362462562662762862963063163263363463563663763863964064164264364464564664764864965065165265365465565665765865966066166266366466566666766866967067167267367467567667767867968068168268368468568668768868969069169269369469569669769869970070170270370470570670770870971071171271371471571671771871972072172272372472572672772872973073173273373473573673773873974074174274374474574674774874975075175275375475575675775875976076176276376476576676776876977077177277377477577677777877978078178278378478578678778878979079179279379479579679779879980080180280380480580680780880981081181281381481581681781881982082182282382482582682782882983083183283383483583683783883984084184284384484584684784884985085185285385485585685785885986086186286386486586686786886987087187287387487587687787887988088188288388488588688788888989089189289389489589689789889990090190290390490590690790890991091191291391491591691791891992092192292392492592692792892993093193293393493593693793893994094194294394494594694794894995095195295395495595695795895996096196296396496596696796896997097197297397497597697797897998098198298398498598698798898999099199299399499599699799899910001001100210031004100510061007100810091010101110121013101410151016101710181019102010211022102310241025102610271028102910301031103210331034103510361037103810391040104110421043104410451046104710481049105010511052105310541055105610571058105910601061106210631064106510661067106810691070107110721073107410751076107710781079108010811082108310841085108610871088108910901091109210931094109510961097109810991100110111021103110411051106110711081109111011111112111311141115111611171118111911201121112211231124112511261127112811291130113111321133113411351136113711381139114011411142114311441145114611471148114911501151115211531154115511561157115811591160116111621163116411651166116711681169117011711172117311741175117611771178117911801181118211831184118511861187118811891190119111921193119411951196119711981199120012011202120312041205120612071208120912101211121212131214121512161217121812191220122112221223122412251226122712281229123012311232123312341235123612371238123912401241124212431244124512461247124812491250125112521253125412551256125712581259126012611262126312641265126612671268126912701271127212731274127512761277127812791280128112821283128412851286128712881289129012911292129312941295129612971298129913001301130213031304130513061307130813091310131113121313131413151316131713181319132013211322132313241325132613271328132913301331133213331334133513361337133813391340134113421343134413451346134713481349135013511352135313541355135613571358135913601361136213631364136513661367136813691370137113721373137413751376137713781379138013811382138313841385138613871388138913901391139213931394139513961397139813991400140114021403140414051406140714081409141014111412141314141415141614171418141914201421142214231424142514261427142814291430143114321433143414351436143714381439144014411442144314441445144614471448144914501451145214531454145514561457145814591460146114621463146414651466146714681469147014711472147314741475147614771478147914801481
  1. /*
  2. style.css is generated from style.scss
  3. do not edit style.css
  4. edit style.scss
  5. */
  6. /* adopted from https://piccalil.li/blog/a-more-modern-css-reset/ */
  7. @layer reset {
  8. /* Box sizing rules */
  9. *,
  10. *::before,
  11. *::after {
  12. box-sizing: border-box;
  13. }
  14. /* Prevent font size inflation */
  15. html {
  16. -moz-text-size-adjust: none;
  17. -webkit-text-size-adjust: none;
  18. text-size-adjust: none;
  19. }
  20. /* Remove default margin in favour of better control in authored CSS */
  21. body,
  22. h1,
  23. h2,
  24. h3,
  25. h4,
  26. p,
  27. figure,
  28. blockquote,
  29. dl,
  30. dd {
  31. margin-block-end: 0;
  32. }
  33. /* Remove list styles on ul, ol elements with a list role, which suggests default styling will be removed */
  34. ul[role='list'],
  35. ol[role='list'] {
  36. list-style: none;
  37. }
  38. /* Fix list style to not indent */
  39. ul,
  40. ol,
  41. menu {
  42. padding-inline-start: 1.5em;
  43. }
  44. li {
  45. padding-inline-start: 0.25em;
  46. }
  47. /* Set core body defaults */
  48. body {
  49. min-height: 100vh;
  50. line-height: 1.5;
  51. }
  52. /* Set shorter line heights on headings and interactive elements */
  53. h1,
  54. h2,
  55. h3,
  56. h4,
  57. button,
  58. input,
  59. label {
  60. line-height: 1.1;
  61. }
  62. /* Balance text wrapping on headings */
  63. h1,
  64. h2,
  65. h3,
  66. h4 {
  67. text-wrap: balance;
  68. }
  69. /* A elements that don't have a class get default styles */
  70. a:not([class]) {
  71. text-decoration-skip-ink: auto;
  72. color: currentColor;
  73. }
  74. /* Make images easier to work with */
  75. img,
  76. picture {
  77. // max-width: 100%;
  78. display: block;
  79. }
  80. /* Inherit fonts for inputs and buttons */
  81. input,
  82. button,
  83. textarea,
  84. select {
  85. font-family: inherit;
  86. font-size: inherit;
  87. }
  88. /* Make sure textareas without a rows attribute are not tiny */
  89. textarea:not([rows]) {
  90. min-height: 10em;
  91. }
  92. /* Anything that has been anchored to should have extra scroll margin */
  93. :target {
  94. scroll-margin-block: 5ex;
  95. }
  96. }
  97. $bg: #131516;
  98. $bg-secondary: #222;
  99. $fg: #fff;
  100. $fg-secondary: #aaa;
  101. $link: #118bee;
  102. $highlight: #fc365b;
  103. $border-radius: 5px;
  104. $line-height: 1.5;
  105. $active-brightness: 0.85;
  106. $hover-brightness: 1.2;
  107. $box-shadow: 2px 2px 10px;
  108. $color-shadow: #bbbbbb20;
  109. $font-family: "Roboto", "Open Sans", "Noto Sans", sans-serif, "Noto Sans CJK JP";
  110. $small-artwork-width: 184px;
  111. $large-artwork-width: 288px;
  112. $novel-width: 392px;
  113. $small-breakpoint: 440px;
  114. html {
  115. font-size: 62.5%;
  116. }
  117. body {
  118. top: 0;
  119. margin: 0;
  120. background-color: $bg;
  121. color: $fg;
  122. font-size: 1.8rem;
  123. font-family: $font-family;
  124. margin-bottom: 10px;
  125. }
  126. main {
  127. @media (min-width: $small-breakpoint) {
  128. margin-inline: 5px;
  129. }
  130. }
  131. h1,
  132. h2,
  133. h3,
  134. h4,
  135. h5,
  136. h6 {
  137. margin-block-end: 0.5em;
  138. }
  139. h1 {
  140. font-size: 1.5em;
  141. }
  142. h2 {
  143. font-size: 1.17em;
  144. }
  145. h3 {
  146. font-size: 1em;
  147. }
  148. h4 {
  149. font-size: 0.83em;
  150. }
  151. h5 {
  152. font-size: 0.67em;
  153. }
  154. h6 {
  155. font-size: 0.50em;
  156. }
  157. a {
  158. color: $link;
  159. text-decoration: none;
  160. }
  161. /* Scrollbars */
  162. * {
  163. scrollbar-width: thin;
  164. // invalid line
  165. // scrollbar-color: $link auto;
  166. }
  167. *::-webkit-scrollbar {
  168. width: 5px;
  169. height: 5px;
  170. }
  171. *::-webkit-scrollbar-track {
  172. background: transparent;
  173. }
  174. *::-webkit-scrollbar-thumb {
  175. background-color: $link;
  176. border-radius: 10px;
  177. }
  178. .special-symbol {
  179. display: inline-flex;
  180. align-items: center;
  181. justify-content: center;
  182. width: 1.8rem;
  183. height: 1.8rem;
  184. font-size: 1.8rem;
  185. }
  186. [hidden] {
  187. display: none;
  188. }
  189. input,
  190. label,
  191. select,
  192. textarea {
  193. display: block;
  194. font-size: inherit;
  195. max-width: 600px;
  196. }
  197. input[type="checkbox"],
  198. input[type="radio"] {
  199. display: inline-block;
  200. }
  201. input[type="checkbox"]+label,
  202. input[type="radio"]+label {
  203. display: inline-block;
  204. font-weight: normal;
  205. position: relative;
  206. top: 1px;
  207. }
  208. input[type="range"] {
  209. padding: 0.4rem 0;
  210. }
  211. input,
  212. select,
  213. textarea {
  214. border: 1px solid $bg-secondary;
  215. border-radius: $border-radius;
  216. margin-bottom: 1rem;
  217. padding: 0.4rem 0.8rem;
  218. }
  219. input[type="text"],
  220. textarea {
  221. width: calc(100% - 1.6rem);
  222. background-color: $bg-secondary;
  223. color: $fg-secondary;
  224. }
  225. input[readonly],
  226. textarea[readonly] {
  227. background-color: $bg-secondary;
  228. }
  229. .form-field {
  230. border: 1px solid $bg-secondary;
  231. border-radius: $border-radius;
  232. box-shadow: $box-shadow $color-shadow;
  233. display: block;
  234. max-width: 800px;
  235. min-width: 460px;
  236. padding: 1.5rem;
  237. margin: 0.5rem 0;
  238. header {
  239. margin: 1.5rem 0;
  240. padding: 1.5rem 0;
  241. }
  242. label {
  243. font-weight: bold;
  244. margin-bottom: 0.2rem;
  245. }
  246. }
  247. a b,
  248. a em,
  249. a i,
  250. a strong,
  251. button,
  252. input[type="submit"],
  253. .switch-button,
  254. .pagination-button {
  255. border-radius: $border-radius;
  256. display: inline-block;
  257. font-size: medium;
  258. font-weight: bold;
  259. line-height: $line-height;
  260. margin: 0.5rem 0;
  261. padding: 0.5rem 1rem;
  262. }
  263. button,
  264. input[type="submit"],
  265. .switch-button,
  266. .pagination-button {
  267. font-family: $font-family;
  268. }
  269. button:active,
  270. input[type="submit"]:active,
  271. .switch-button:active,
  272. .pagination-button:active {
  273. filter: brightness($active-brightness);
  274. }
  275. button:hover,
  276. input[type="submit"]:hover,
  277. .switch-button:hover,
  278. .pagination-button:hover {
  279. cursor: pointer;
  280. filter: brightness($hover-brightness);
  281. }
  282. a b,
  283. a strong,
  284. button,
  285. input[type="submit"],
  286. .switch-button,
  287. .pagination-button {
  288. background-color: $link;
  289. color: $fg;
  290. }
  291. input[type="submit"][hidden] {
  292. display: none;
  293. }
  294. .switch-button[selected="1"] {
  295. background: $highlight;
  296. }
  297. .switch-seperator {
  298. display: inline-block;
  299. margin-left: 10px;
  300. }
  301. .pagination {
  302. text-align: center;
  303. form {
  304. display: inline-block;
  305. }
  306. .pagination-buttons {
  307. text-align: center;
  308. input {
  309. width: 5em;
  310. }
  311. }
  312. .pagination-button {
  313. margin-right: 5px;
  314. }
  315. #highlight {
  316. filter: brightness($hover-brightness);
  317. }
  318. .disabled {
  319. pointer-events: none;
  320. background-color: $bg-secondary;
  321. filter: brightness(1);
  322. }
  323. }
  324. // https://stackoverflow.com/questions/63787241/css-how-to-create-an-infinitely-moving-repeating-linear-gradient/63787567#63787567
  325. #loading-indicator {
  326. z-index: 2;
  327. isolation: isolate;
  328. position: sticky;
  329. top: 0;
  330. height: 4px;
  331. margin-bottom: -4px;
  332. // background-size: 200px auto;
  333. animation: rolling-something 1s linear infinite;
  334. background-image: repeating-linear-gradient(-0.25turn, $link 0vw, transparent 40vw);
  335. background-size: 80vw auto;
  336. will-change: opacity;
  337. transition: opacity 0.3s;
  338. opacity: 0;
  339. &.htmx-request {
  340. opacity: 1;
  341. transition-duration: 1s;
  342. transition-timing-function: cubic-bezier(0.16, 1, 0.3, 1);
  343. }
  344. }
  345. @keyframes rolling-something {
  346. 0% {
  347. background-position-x: 0vw
  348. }
  349. 100% {
  350. background-position-x: 40vw
  351. }
  352. }
  353. nav {
  354. margin-bottom: 15px;
  355. padding-left: 20px;
  356. padding-right: 20px;
  357. .navigation-wrapper {
  358. padding-block: 15px;
  359. display: flex;
  360. justify-content: space-between;
  361. align-items: center;
  362. width: auto;
  363. }
  364. // .navbar-shadow {
  365. // width: 100%;
  366. // height: 10px;
  367. // background: repeating-linear-gradient(
  368. // 52.5deg,
  369. // rgba(32, 32, 32, 0.7),
  370. // rgba(32, 32, 32, 0.7) 14px,
  371. // rgba(240, 248, 255, 0) 14px,
  372. // rgba(240, 248, 255, 0) 28px
  373. // );
  374. // }
  375. .sidebar-container {
  376. height: 30px;
  377. }
  378. .navbar-brand {
  379. display: inline-flex;
  380. gap: 10px;
  381. span {
  382. font-weight: bold;
  383. font-size: 1.3em;
  384. color: $fg;
  385. }
  386. }
  387. .navbar-entry {
  388. display: flex;
  389. img {
  390. width: 30px;
  391. height: 30px;
  392. }
  393. }
  394. .search-form {
  395. display: flex;
  396. gap: 4px;
  397. margin-left: 8px;
  398. align-items: center;
  399. input {
  400. margin: 0;
  401. }
  402. }
  403. .sidebar-toggler {
  404. display: none;
  405. &:checked~.sidebar {
  406. transform: translateX(0);
  407. }
  408. }
  409. .sidebar-label {
  410. display: flex;
  411. margin-right: 20px;
  412. cursor: pointer;
  413. }
  414. .sidebar {
  415. z-index: 1;
  416. isolation: isolate;
  417. background-color: $bg;
  418. position: absolute;
  419. padding-top: 6px;
  420. left: 0;
  421. width: 220px;
  422. transform: translateX(-220px);
  423. transition: transform 250ms cubic-bezier(0.23, 1, 0.32, 1);
  424. br {
  425. align-self: stretch;
  426. margin-top: 10px;
  427. }
  428. }
  429. .sidebar-list {
  430. list-style-type: none;
  431. margin: 0;
  432. padding: 0;
  433. }
  434. .sidebar-item {
  435. display: flex;
  436. align-items: center;
  437. list-style: none;
  438. color: $fg;
  439. font-size: 0.9em;
  440. text-decoration: none;
  441. padding: 10px;
  442. &:hover {
  443. background-color: $bg-secondary;
  444. }
  445. img {
  446. width: 30px;
  447. height: 30px;
  448. margin-left: 1.2rem;
  449. margin-right: 10px;
  450. }
  451. }
  452. }
  453. // mobile nav bar
  454. @media screen and (max-height: 767px) {
  455. nav {
  456. position: sticky;
  457. top: 0;
  458. isolation: isolate;
  459. z-index: 1;
  460. background-color: $bg;
  461. .navigation-wrapper {
  462. background-color: $bg;
  463. padding-block: 8px; // Reduced from 15px
  464. }
  465. .sidebar {
  466. z-index: -1;
  467. width: 100vw;
  468. transform: translateY(-110%);
  469. padding-block: 8px 16px;
  470. br {
  471. display: none;
  472. }
  473. }
  474. .sidebar-list {
  475. background-color: $bg;
  476. // display: flex;
  477. // flex-direction: row;
  478. // flex-wrap: wrap;
  479. display: grid;
  480. grid-template-columns: minmax(0px, 400px) repeat(auto-fit,
  481. minmax(0px, 400px));
  482. }
  483. .sidebar-item {
  484. padding-inline: unset;
  485. }
  486. }
  487. }
  488. .component-header {
  489. display: flex;
  490. justify-content: space-between;
  491. align-items: center;
  492. h2 {
  493. margin: 0;
  494. display: inline-block;
  495. }
  496. }
  497. .container {
  498. max-width: 1200px;
  499. margin-inline: auto;
  500. padding-inline: 4px;
  501. @media (min-width: $small-breakpoint) {
  502. padding-inline: 10px;
  503. }
  504. scroll-margin-top: 71px; // Prevent images from being covered; equal to the navigation bar height
  505. }
  506. .error.container {
  507. text-align: center;
  508. }
  509. .artwork-container-header {
  510. display: flex;
  511. flex-wrap: wrap;
  512. align-items: center;
  513. justify-content: space-between;
  514. }
  515. .artwork-container {
  516. display: grid;
  517. grid-template-columns: repeat(auto-fit,
  518. minmax(calc($small-artwork-width + 15px), 1fr));
  519. align-items: center;
  520. justify-items: center;
  521. }
  522. .artwork-container-scroll {
  523. display: flex;
  524. overflow: hidden;
  525. overflow-x: scroll;
  526. }
  527. .artwork-container,
  528. .artwork-container-scroll {
  529. a {
  530. text-decoration: none;
  531. color: $fg;
  532. }
  533. .artwork-large {
  534. img {
  535. width: $large-artwork-width;
  536. height: $large-artwork-width;
  537. }
  538. .artwork-title {
  539. max-width: $large-artwork-width;
  540. }
  541. .artwork-author {
  542. max-width: $large-artwork-width;
  543. a {
  544. max-width: $small-artwork-width;
  545. }
  546. }
  547. }
  548. .artwork-small {
  549. img {
  550. width: $small-artwork-width;
  551. height: $small-artwork-width;
  552. background: rgb(19,21,22);
  553. background: linear-gradient(0deg, rgba(10,10,10,0.5) 0%, rgba(19,21,22,0) 80%, rgba(34,33,33,0) 100%);
  554. }
  555. .artwork-title {
  556. max-width: $small-artwork-width;
  557. }
  558. .artwork-author {
  559. max-width: $small-artwork-width;
  560. a {
  561. max-width: $small-artwork-width;
  562. }
  563. }
  564. }
  565. .artwork {
  566. padding: 5px;
  567. width: fit-content;
  568. position: relative;
  569. .artwork-additional {
  570. position: absolute;
  571. top: 4px;
  572. left: 4px;
  573. right: 4px;
  574. box-sizing: border-box;
  575. display: flex;
  576. align-items: flex-start;
  577. justify-content: space-between;
  578. padding: 4px 4px 0px;
  579. pointer-events: none;
  580. .artwork-position {
  581. display: flex;
  582. align-items: center;
  583. justify-content: center;
  584. border-radius: 50%;
  585. font-weight: bold;
  586. width: 40px;
  587. height: 40px;
  588. font-size: 16px;
  589. background-color: rgba(0, 0, 0, 0.32);
  590. }
  591. .artwork-profanity-label {
  592. display: flex;
  593. align-items: center;
  594. justify-content: center;
  595. font-size: 10px;
  596. border-radius: 20px;
  597. padding: 0.4rem;
  598. background-color: $highlight;
  599. color: $fg;
  600. }
  601. .artwork-page-count {
  602. display: flex;
  603. justify-content: center;
  604. align-items: center;
  605. flex: 0 0 auto;
  606. box-sizing: border-box;
  607. height: 20px;
  608. min-width: 20px;
  609. color: $fg;
  610. font-weight: bold;
  611. padding: 0px 6px;
  612. background: rgba(0, 0, 0, 0.32);
  613. border-radius: 10px;
  614. font-size: 10px;
  615. line-height: 10px;
  616. .boxbox {
  617. font-size: 9px;
  618. }
  619. }
  620. }
  621. img {
  622. object-fit: cover;
  623. object-position: center center;
  624. border-radius: $border-radius;
  625. }
  626. .artwork-title {
  627. display: flex;
  628. align-items: center;
  629. a {
  630. font-size: 14px;
  631. display: inline;
  632. overflow: hidden;
  633. text-overflow: ellipsis;
  634. white-space: nowrap;
  635. line-height: 22px;
  636. font-weight: bold;
  637. }
  638. }
  639. .artwork-author {
  640. display: flex;
  641. align-items: center;
  642. a {
  643. display: flex;
  644. align-items: center;
  645. img {
  646. aspect-ratio: 1/1;
  647. width: 24px;
  648. height: 24px;
  649. object-fit: cover;
  650. object-position: center top;
  651. border-radius: 50%;
  652. margin-right: 5px;
  653. }
  654. span {
  655. font-size: 14px;
  656. overflow: hidden;
  657. text-overflow: ellipsis;
  658. white-space: nowrap;
  659. line-height: 22px;
  660. }
  661. }
  662. }
  663. }
  664. }
  665. /* Brought out here because both artworks and novels needed this */
  666. .illust-tags {
  667. font-size: 0.9em;
  668. .illust-tag-attr {
  669. display: inline-flex;
  670. align-items: center;
  671. margin-right: 15px;
  672. img {
  673. aspect-ratio: 1/1;
  674. width: 18px;
  675. height: 18px;
  676. margin-right: 5px;
  677. }
  678. }
  679. .illust-tag {
  680. margin-right: 10px;
  681. #highlight {
  682. color: $highlight;
  683. }
  684. .illust-tag-name {
  685. color: $link;
  686. font-weight: bold;
  687. margin-right: 5px;
  688. }
  689. }
  690. }
  691. .illust-attr {
  692. display: flex;
  693. align-items: center;
  694. justify-content: space-between;
  695. margin-top: 10px;
  696. margin-bottom: 10px;
  697. .illust-author-attr {
  698. display: flex;
  699. align-items: center;
  700. }
  701. .illust-avatar {
  702. width: 62px;
  703. height: 62px;
  704. border-radius: 50px;
  705. object-fit: cover;
  706. object-position: center top;
  707. }
  708. .attr-wrap {
  709. margin-left: 5px;
  710. .illust-title {
  711. font-weight: bold;
  712. }
  713. .illust-author {
  714. font-size: 0.8em;
  715. }
  716. a {
  717. color: $fg-secondary;
  718. }
  719. }
  720. .artwork-actions {
  721. img {
  722. aspect-ratio: 1/1;
  723. width: 30px;
  724. height: 30px;
  725. display: inline;
  726. }
  727. }
  728. }
  729. .illust {
  730. background-color: $bg-secondary;
  731. border-radius: $border-radius;
  732. padding: 5px 15px;
  733. .illust-images {
  734. display: flex;
  735. align-items: center;
  736. flex-direction: column;
  737. width: 100%;
  738. img,
  739. video {
  740. margin-top: 15px;
  741. max-height: 1000px;
  742. width: auto;
  743. max-width: 100%;
  744. }
  745. }
  746. .illust-description {
  747. font-size: 0.85em;
  748. }
  749. .comment {
  750. display: flex;
  751. margin-bottom: 10px;
  752. p {
  753. margin: 0;
  754. font-size: 0.8em;
  755. }
  756. .comment-avatar {
  757. width: 40px;
  758. height: 40px;
  759. border-radius: 50%;
  760. margin-right: 10px;
  761. }
  762. .comment-author {
  763. color: $fg;
  764. font-size: medium;
  765. font-weight: bold;
  766. }
  767. .stamp {
  768. width: 96px;
  769. height: 96px;
  770. border-radius: 4px;
  771. }
  772. .emoji {
  773. width: 24px;
  774. height: 24px;
  775. margin-left: 3px;
  776. margin-right: 3px;
  777. }
  778. }
  779. .illust-other-works {
  780. a.illust-other-works-author {
  781. display: inline-flex;
  782. align-items: center;
  783. text-decoration: none;
  784. color: $fg;
  785. &>img {
  786. aspect-ratio: 1/1;
  787. width: 50px;
  788. height: 50px;
  789. border-radius: 50%;
  790. margin-right: 5px;
  791. object-fit: cover;
  792. object-position: center top;
  793. }
  794. }
  795. }
  796. }
  797. .novel-container {
  798. display: grid;
  799. grid-template-columns: repeat(auto-fit,
  800. minmax(calc($novel-width + 15px), 1fr));
  801. justify-content: center;
  802. }
  803. .novel-card {
  804. font-size: 1.5rem;
  805. padding: 5px 15px;
  806. padding-top: 1em;
  807. .novel-detail {
  808. display: flex;
  809. .novel-author {
  810. display: flex;
  811. align-items: center;
  812. font-size: 0.8em;
  813. img {
  814. width: 16px;
  815. height: 16px;
  816. border-radius: 50%;
  817. }
  818. span {
  819. color: $fg;
  820. display: inline-block;
  821. margin-left: 5px;
  822. }
  823. }
  824. .novel-metadata {
  825. margin-left: 1.5rem;
  826. .novel-title {
  827. color: $fg;
  828. font-size: 1.17em;
  829. font-weight: bold;
  830. overflow: hidden;
  831. overflow-wrap: break-word;
  832. word-break: break-word;
  833. text-overflow: ellipsis;
  834. width: 100%;
  835. display: -webkit-box;
  836. -webkit-line-clamp: 2;
  837. -webkit-box-orient: vertical;
  838. }
  839. .novel-description {
  840. font-size: 0.85em;
  841. overflow: hidden;
  842. overflow-wrap: break-word;
  843. word-break: break-word;
  844. text-overflow: ellipsis;
  845. width: 100%;
  846. display: -webkit-box;
  847. -webkit-line-clamp: 4;
  848. -webkit-box-orient: vertical;
  849. }
  850. }
  851. }
  852. .novel-cover img {
  853. /* warning: hard-coded values */
  854. width: 136px;
  855. height: 191px;
  856. object-fit: cover;
  857. object-position: center center;
  858. }
  859. .novel-content {
  860. margin: 1.2rem 0;
  861. line-height: 1.8;
  862. color: black;
  863. background-color: white;
  864. }
  865. }
  866. .novel {
  867. background-color: $bg-secondary;
  868. border-radius: $border-radius;
  869. padding: 5px 15px;
  870. padding-top: 1em;
  871. .novel-detail {
  872. display: flex;
  873. .novel-metadata {
  874. margin-left: 1.5rem;
  875. .novel-title {
  876. font-size: 1.17em;
  877. font-weight: bold;
  878. }
  879. .novel-description {
  880. font-size: 0.85em;
  881. }
  882. }
  883. }
  884. .novel-cover img {
  885. /* warning: hard-coded values */
  886. width: 136px;
  887. height: 191px;
  888. object-fit: cover;
  889. object-position: center center;
  890. }
  891. .novel-content {
  892. margin: 1.2rem 0;
  893. line-height: 2;
  894. color: black;
  895. background-color: white;
  896. max-width: 100%;
  897. width: 100%;
  898. overflow-x: scroll;
  899. .novel-content-text {
  900. padding: 6.4rem 10rem;
  901. text-align: justify;
  902. img {
  903. max-width: 100%;
  904. max-height: 100%;
  905. margin: 0 0.5rem;
  906. }
  907. }
  908. }
  909. .novel-attr {
  910. display: flex;
  911. align-items: center;
  912. margin-top: 10px;
  913. margin-bottom: 10px;
  914. .novel-avatar {
  915. width: 62px;
  916. height: 62px;
  917. border-radius: 50px;
  918. object-fit: cover;
  919. object-position: center top;
  920. }
  921. .attr-wrap {
  922. margin-left: 5px;
  923. .novel-author {
  924. font-size: 0.8em;
  925. }
  926. a {
  927. color: $fg-secondary;
  928. }
  929. }
  930. }
  931. .novel-settings {
  932. background-color: $bg;
  933. padding: 0.5rem;
  934. position: sticky;
  935. top: 0;
  936. img {
  937. width: 30px;
  938. height: 30px;
  939. }
  940. .novel-settings-wrapper {
  941. display: flex;
  942. }
  943. /* The container <div> - needed to position the dropdown content */
  944. .dropdown {
  945. position: relative;
  946. display: inline-block;
  947. }
  948. /* Dropdown Content (Hidden by Default) */
  949. .dropdown-content {
  950. display: none;
  951. position: absolute;
  952. background-color: $bg;
  953. min-width: 100px;
  954. box-shadow: 0px 8px 16px 0px rgba(0, 0, 0, 0.4);
  955. z-index: 1;
  956. padding: 1rem;
  957. .value-holder {
  958. display: none;
  959. }
  960. }
  961. .dropdown-toggler {
  962. display: none;
  963. &:checked~.dropdown-content {
  964. display: block;
  965. }
  966. }
  967. }
  968. }
  969. // Font settings for novels
  970. $font-fallback-serif: "Yu Mincho",
  971. YuMincho,
  972. "Hiragino Mincho ProN",
  973. "Hiragino Mincho Pro",
  974. "Source Han Serif",
  975. "BIZ UDMincho Medium",
  976. "Source Serif Pro",
  977. "Source Serif",
  978. "Noto Serif",
  979. "Times New Roman",
  980. "Georgia Pro",
  981. Georgia,
  982. Simsun,
  983. PMingLiu,
  984. AppleMyungjo,
  985. "Source Han Serif K",
  986. "Source Han Serif KR",
  987. "Noto Serif KR",
  988. Batang,
  989. serif;
  990. [data-font=mincho][data-font=jp] {
  991. font-family:
  992. "Source Han Serif JP",
  993. "Noto Serif JP",
  994. $font-fallback-serif;
  995. }
  996. [data-font=mincho][data-font=zh-cn],
  997. [data-font=mincho][data-font=zh-hans] {
  998. font-family:
  999. "Songti SC",
  1000. "Source Han Serif SC",
  1001. "Noto Serif SC",
  1002. "Source Han Serif CN",
  1003. $font-fallback-serif;
  1004. }
  1005. // todo: technically, zh-hk > zh-hant > zh
  1006. // Noto Sans have
  1007. // CJK HK
  1008. // CJK JP
  1009. // CJK KR
  1010. // CJK SC
  1011. // CJK TC
  1012. [data-font=mincho][data-font=zh-tw],
  1013. [data-font=mincho][data-font=zh-hk],
  1014. [data-font=mincho][data-font=zh-hant] {
  1015. font-family:
  1016. "Songti TC",
  1017. "Source Han Serif TC",
  1018. "Noto Serif TC",
  1019. "Source Han Serif TW",
  1020. "Source Han Serif HK",
  1021. $font-fallback-serif;
  1022. }
  1023. [data-font=mincho] {
  1024. font-family: $font-fallback-serif;
  1025. }
  1026. $font-fallback-sans: YuGothic,
  1027. "Hiragino Kaku Gothic Pro",
  1028. Meiryo,
  1029. "Source Han Sans",
  1030. "Source Han Sans JP",
  1031. "Noto Sans CJK JP",
  1032. "Avenir Next",
  1033. Avenir,
  1034. "Source Sans",
  1035. "Noto Sans",
  1036. Roboto,
  1037. Verdana,
  1038. "Pingfang TC",
  1039. "Pingfang HK",
  1040. "Hiragino Sans CNS",
  1041. "Lantinghei TC",
  1042. "Source Han Sans TW",
  1043. "Source Han Sans HK",
  1044. "Noto Sans CJK TC",
  1045. "Microsoft JhengHei",
  1046. "Pingfang SC",
  1047. "Hiragino Sans GB",
  1048. "Lantinghei SC",
  1049. "Source Han Sans CN",
  1050. "Noto Sans CJK SC",
  1051. "Microsoft Yahei",
  1052. DengXian,
  1053. "Apple SD Gothic Neo",
  1054. "Source Han Sans K",
  1055. "Source Han Sans KR",
  1056. "Noto Sans CJK KR",
  1057. "Malgun Gothic",
  1058. sans-serif;
  1059. [data-font=gothic] {
  1060. font-family: $font-fallback-sans;
  1061. }
  1062. [data-view="2"] {
  1063. writing-mode: vertical-rl;
  1064. text-orientation: upright;
  1065. }
  1066. .background-cover {
  1067. background: repeating-linear-gradient(52.5deg,
  1068. rgba(32, 32, 32, 0.8),
  1069. rgba(32, 32, 32, 0.8) 14px,
  1070. rgba(240, 248, 255, 0) 14px,
  1071. rgba(240, 248, 255, 0) 28px);
  1072. height: 10vw;
  1073. min-height: 100px;
  1074. overflow: hidden;
  1075. padding-top: 10px;
  1076. padding-bottom: 10px;
  1077. img {
  1078. width: 100%;
  1079. height: 100%;
  1080. object-fit: cover;
  1081. }
  1082. }
  1083. #hasbg {
  1084. height: 40vw;
  1085. min-height: 100px;
  1086. max-height: 60vh;
  1087. }
  1088. .user {
  1089. transform: translateY(-8rem);
  1090. img {
  1091. display: inline;
  1092. }
  1093. .user-avatar {
  1094. text-align: center;
  1095. }
  1096. .user-avatar img {
  1097. aspect-ratio: 1/1;
  1098. width: 150px;
  1099. height: 150px;
  1100. border-radius: 50%;
  1101. object-fit: cover;
  1102. object-position: center top;
  1103. }
  1104. .user-social {
  1105. text-align: center;
  1106. img {
  1107. aspect-ratio: 1/1;
  1108. width: 36px;
  1109. height: 36px;
  1110. }
  1111. }
  1112. .user-details {
  1113. text-align: center;
  1114. h2 {
  1115. margin: 0;
  1116. }
  1117. }
  1118. }
  1119. .user-tags {
  1120. display: flex;
  1121. flex-wrap: wrap;
  1122. row-gap: 8px;
  1123. column-gap: 1em;
  1124. margin-block: 4px 20px;
  1125. &>a {
  1126. line-height: 1;
  1127. &:hover {
  1128. text-decoration: underline;
  1129. }
  1130. }
  1131. }
  1132. #calendar {
  1133. width: 100%;
  1134. height: auto;
  1135. }
  1136. .calendar-weeks,
  1137. .calendar-board {
  1138. max-width: 1000px;
  1139. margin: 0 auto;
  1140. display: flex;
  1141. flex-wrap: wrap;
  1142. gap: 5px;
  1143. }
  1144. .calendar-weeks div {
  1145. width: 128px;
  1146. text-align: center;
  1147. }
  1148. .calendar-node {
  1149. width: 128px;
  1150. height: 128px;
  1151. border-radius: 8px;
  1152. background-color: $bg-secondary;
  1153. position: relative;
  1154. img {
  1155. border-radius: 8px;
  1156. object-fit: cover;
  1157. object-position: center center;
  1158. }
  1159. span {
  1160. font-size: small;
  1161. color: $fg;
  1162. background-color: $bg-secondary;
  1163. position: absolute;
  1164. top: 0.3rem;
  1165. left: 0.3rem;
  1166. padding: 0.05rem 0.3rem;
  1167. display: flex;
  1168. align-items: center;
  1169. justify-content: center;
  1170. }
  1171. }
  1172. .calendar-node-empty {
  1173. visibility: hidden;
  1174. }
  1175. @media screen and (max-width: 950px) {
  1176. .calendar-board {
  1177. justify-content: center;
  1178. }
  1179. .calendar-weeks,
  1180. .calendar-node-empty {
  1181. display: none;
  1182. }
  1183. }
  1184. .tag-header {
  1185. display: flex;
  1186. .tag-thumbnail {
  1187. width: 120px;
  1188. height: 120px;
  1189. border-radius: 5px;
  1190. margin-right: 20px;
  1191. object-fit: cover;
  1192. object-position: center center;
  1193. }
  1194. .tag-details {
  1195. .main-tag {
  1196. font-size: 1.6rem;
  1197. }
  1198. }
  1199. }
  1200. .tag-container {
  1201. background-color: $bg-secondary;
  1202. display: inline-flex;
  1203. align-items: center;
  1204. justify-content: center;
  1205. padding-left: 20px;
  1206. padding-right: 20px;
  1207. margin-right: 10px;
  1208. width: max-content;
  1209. height: 40px;
  1210. margin-bottom: 4px;
  1211. text-align: center;
  1212. font-weight: bold;
  1213. font-size: 1rem;
  1214. border-radius: 4px;
  1215. .main {
  1216. font-size: 1.6em;
  1217. }
  1218. .sub {
  1219. font-size: 1.2em;
  1220. font-weight: normal;
  1221. }
  1222. }
  1223. summary> :is(h1, h2, h3, h4, h5, h6) {
  1224. display: inline-block;
  1225. }
  1226. .settings-set-cookie h3 {
  1227. font-size: smaller;
  1228. margin-block: 4px 0;
  1229. }
  1230. .settings-set-cookie form {
  1231. display: flex;
  1232. gap: 4px;
  1233. }
  1234. .settings-set-cookie form>* {
  1235. margin: unset !important;
  1236. }
  1237. .settings-set-cookie form>input[type="text"] {
  1238. width: 20em;
  1239. }
  1240. input.critical {
  1241. background-color: $highlight;
  1242. }