1
0

style.scss 8.3 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615
  1. @import "predefined.scss";
  2. @import "normalize.scss";
  3. @import "syntax.scss";
  4. @import "animate.scss";
  5. /* Webkit Scrollbar Customize */
  6. ::-webkit-scrollbar {
  7. width: .5em;
  8. height: .5em;
  9. }
  10. ::-webkit-scrollbar-track {
  11. background: $midnightblue;
  12. }
  13. ::-webkit-scrollbar-thumb {
  14. background: #888;
  15. &:hover{
  16. background: $text;
  17. }
  18. }
  19. html {
  20. background: $light-grey;
  21. line-height: 1.6;
  22. letter-spacing: .06em;
  23. }
  24. body, button, input, select, textarea {
  25. color: $text;
  26. font-family: $fonts;
  27. }
  28. pre, code, pre tt {
  29. font-family: $code-fonts;
  30. }
  31. pre {
  32. color: #eee;
  33. background: $midnightblue;
  34. padding: .8em;
  35. border-radius: 5px;
  36. display: block;
  37. overflow: auto;
  38. letter-spacing: normal;
  39. line-height: 1.5;
  40. // -webkit-overflow-scrolling: touch;
  41. code {
  42. display: inline-block;
  43. background: $midnightblue;
  44. }
  45. }
  46. code {
  47. display: inline;
  48. color: #eee;
  49. background: $highlight-grey;
  50. border-radius: 3px;
  51. padding: 0 2px;
  52. margin: auto 4px;
  53. word-break: break-all;
  54. letter-spacing: normal;
  55. }
  56. blockquote {
  57. border-left: .25em solid;
  58. margin: 1em;
  59. padding: 0 1em;
  60. font-style: italic;
  61. cite {
  62. font-weight: bold;
  63. font-style: normal;
  64. &::before {
  65. content: "—— ";
  66. }
  67. }
  68. }
  69. a {
  70. color: $text;
  71. text-decoration: none;
  72. border-bottom: 1px solid $text;
  73. transition-property: color, border-color;
  74. transition-duration: .5s;
  75. transition-timing-function: ease-out;
  76. &:hover {
  77. color: #fff;
  78. border-bottom: 1px solid #fff;
  79. }
  80. }
  81. hr {
  82. opacity: .2;
  83. border-width: 0 0 5px 0;
  84. border-style: dashed;
  85. background: transparent;
  86. width: 80%;
  87. margin: auto;
  88. }
  89. table {
  90. border-collapse: collapse;
  91. border-spacing: 0;
  92. empty-cells: show;
  93. width: 100%;
  94. max-width: 100%;
  95. th, td {
  96. padding: 1.5%;
  97. border: 1px solid;
  98. }
  99. th {
  100. font-weight: 700;
  101. vertical-align: bottom;
  102. }
  103. }
  104. .section-inner {
  105. margin: 0 auto;
  106. max-width: 1200px;
  107. width: 93%;
  108. }
  109. .thin {
  110. max-width: 720px;
  111. margin: auto;
  112. }
  113. .social-icons a {
  114. border: none;
  115. }
  116. .feather {
  117. display: inline-block;
  118. vertical-align: -.125em;
  119. width: 1em;
  120. height: 1em;
  121. }
  122. // Header & Footer
  123. //
  124. #site-header {
  125. position: fixed;
  126. z-index: 1;
  127. bottom: 0;
  128. width: 100%;
  129. box-sizing: border-box;
  130. box-shadow: -1px -2px 3px rgba(0,0,0,0.45);
  131. background-color: $dark-grey;
  132. }
  133. .hdr-wrapper {
  134. display: flex;
  135. justify-content: space-between;
  136. padding: .5em 0;
  137. font-size: 1.2rem;
  138. a {
  139. border: none;
  140. }
  141. .site-branding {
  142. display: inline-block;
  143. font-size: 1.2em;
  144. }
  145. .site-nav {
  146. display: inline-block;
  147. font-size: 1.1em;
  148. opacity: .8;
  149. a {
  150. margin-left: .8em;
  151. }
  152. }
  153. }
  154. .hdr-icons {
  155. display: inline-block;
  156. font-size: 1.2em;
  157. }
  158. .hdr-btn {
  159. border: none;
  160. background: none;
  161. padding: 0;
  162. cursor: pointer;
  163. }
  164. #menu-btn, #search-btn {
  165. display: none;
  166. cursor: pointer;
  167. }
  168. #mobile-menu {
  169. position: fixed;
  170. bottom: 4.5em;
  171. right: 1.5em;
  172. padding: .6em 1.8em;
  173. z-index: 1;
  174. box-sizing: border-box;
  175. box-shadow: -1px -2px 3px 0px rgba(0,0,0,0.45);
  176. background-color: $dark-grey;
  177. a {
  178. border: none;
  179. }
  180. ul {
  181. list-style: none;
  182. margin: 0;
  183. padding: 0;
  184. line-height: 2;
  185. font-size: 1.2em;
  186. }
  187. }
  188. #site-footer {
  189. text-align: center;
  190. font-size: .9em;
  191. margin-bottom: 96px;
  192. margin-top: 64px;
  193. p {
  194. margin: 0;
  195. }
  196. }
  197. #copyright a {
  198. border: none;
  199. }
  200. // Spotlight
  201. //
  202. #spotlight {
  203. display: flex;
  204. height: 100vh;
  205. flex-direction: column;
  206. align-items: center;
  207. justify-content: center;
  208. font-size: 1.5rem;
  209. &.error-404 {
  210. flex-direction: row;
  211. }
  212. }
  213. .catguard img {
  214. max-width: 250px;
  215. height: auto;
  216. }
  217. .banner-404 {
  218. margin-left: 2em;
  219. h1 {
  220. font-size: 3em;
  221. margin: 0;
  222. }
  223. p {
  224. margin-top: 0;
  225. margin-bottom: .5em;
  226. }
  227. .btn-404 {
  228. font-size: 1em;
  229. a {
  230. display: inline-block;
  231. border-bottom: 2px solid $theme;
  232. padding: 1px 2px;
  233. transition-property: background-color;
  234. word-break: break-all;
  235. &:first-child {
  236. margin-right: 1em;
  237. }
  238. &:hover {
  239. background-color: $theme;
  240. }
  241. }
  242. }
  243. }
  244. #home-title {
  245. margin: 0;
  246. }
  247. #home-social {
  248. font-size: 1.4em;
  249. }
  250. #home-nav a{
  251. display: block;
  252. border: none;
  253. text-align: center;
  254. margin-top: .5em;
  255. }
  256. // list.html
  257. //
  258. .posts-group {
  259. display: flex;
  260. .post-year{
  261. font-size: 1.6em;
  262. margin: 0.4em 2em 1em 0;
  263. @include dimmed;
  264. }
  265. .posts-list {
  266. flex-grow: 1;
  267. margin: 16px 0;
  268. padding: 0;
  269. list-style: none;
  270. }
  271. .post-item {
  272. margin-bottom: 10px;
  273. padding: 2px 4px;
  274. border-radius: 3px;
  275. transition-property: background-color;
  276. transition-duration: .5s;
  277. transition-timing-function: ease-out;
  278. a {
  279. display: flex;
  280. justify-content: space-between;
  281. align-items: baseline;
  282. border: none;
  283. }
  284. &:hover {
  285. background-color: $highlight-grey;
  286. }
  287. }
  288. .post-day {
  289. flex-shrink: 0;
  290. margin-left: 1em;
  291. @include dimmed;
  292. }
  293. }
  294. // single.html
  295. //
  296. .bg-img {
  297. width: 100%;
  298. height: 100%;
  299. opacity: .03;
  300. z-index: -1;
  301. position: fixed;
  302. top: 0;
  303. background-attachment: fixed;
  304. background-repeat: no-repeat;
  305. background-size: cover;
  306. background-position: center;
  307. transition: opacity .5s;
  308. }
  309. .show-bg-img {
  310. z-index: 100;
  311. opacity: 1;
  312. }
  313. #show-img-btn {
  314. margin-right: .5em;
  315. }
  316. .post-header {
  317. margin-top: 1.2em;
  318. line-height: normal;
  319. .post-meta {
  320. font-size: .9em;
  321. letter-spacing: normal;
  322. @include dimmed;
  323. }
  324. h1 {
  325. margin-top: .1em;
  326. }
  327. }
  328. hr.post-end {
  329. width: 50%;
  330. margin-top: 1.6em;
  331. margin-bottom: .8em;
  332. margin-left: 0;
  333. border-style: solid;
  334. border-bottom-width: 4px;
  335. }
  336. .content {
  337. text-align: justify;
  338. text-justify: inter-ideograph; //For IE/Edge
  339. @include aTag;
  340. figure {
  341. max-width: 100;
  342. height: auto;
  343. margin: 0;
  344. text-align: center;
  345. p {
  346. margin-top: 0;
  347. }
  348. }
  349. img {
  350. max-width: 100%;
  351. height: auto;
  352. border-radius: 4px;
  353. }
  354. ul, ol {
  355. padding: 0;
  356. margin-left: 1.8em;
  357. }
  358. }
  359. figure.left {
  360. float: left;
  361. margin-right: 1em;
  362. }
  363. figure.right {
  364. float: right;
  365. margin-left: 1em;
  366. }
  367. .footnote-ref a, a.footnote-return {
  368. border: none;
  369. &:hover {
  370. background: transparent;
  371. }
  372. }
  373. .post-info {
  374. font-size: .8rem;
  375. line-height: normal;
  376. @include dimmed;
  377. .tag {
  378. margin-right: .1em;
  379. &::before {
  380. content: "#"
  381. }
  382. a {
  383. border: none;
  384. }
  385. }
  386. }
  387. // Comments
  388. //
  389. #comments-loader {
  390. text-align: center;
  391. font-size: 2.5em;
  392. margin-top: 2.5em;
  393. svg {
  394. animation-duration: 1.2s;
  395. }
  396. }
  397. #comments {
  398. margin-top: 3em;
  399. * {
  400. color: $text;
  401. line-height: 1.5;
  402. }
  403. .vcontrol {
  404. letter-spacing: normal;
  405. }
  406. .vbtn {
  407. background-color: #7d828a;
  408. }
  409. .vwrap {
  410. border: 2px solid $text;
  411. input {
  412. border-bottom-width: 2px;
  413. }
  414. }
  415. .vsys {
  416. background-color: $highlight-grey;
  417. opacity: .5;
  418. }
  419. .vat {
  420. color: $theme;
  421. }
  422. .vh {
  423. border-bottom: 4px solid #5c6372;
  424. .vquote {
  425. border-left: 3px dotted #979ca5;
  426. }
  427. }
  428. .vcontent {
  429. padding: 0;
  430. code {
  431. margin: auto 4px;
  432. color: #eee;
  433. background: $highlight-grey;
  434. }
  435. pre {
  436. color: #eee;
  437. background: $midnightblue;
  438. padding: 1em 1.5em;
  439. border-radius: 5px;
  440. display: block;
  441. code {
  442. background: $midnightblue;
  443. }
  444. }
  445. }
  446. }
  447. @media (min-width: 800px) {
  448. .site-main {
  449. margin-top: 3em;
  450. }
  451. hr.post-end {
  452. width: 40%;
  453. }
  454. }
  455. @media (min-width: 960px) {
  456. .site-main {
  457. margin-top: 6em;
  458. }
  459. }
  460. @media (min-width: 1300px) {
  461. .site-main {
  462. margin-top: 8em;
  463. }
  464. hr.post-end {
  465. width: 30%;
  466. }
  467. }
  468. @media (min-width: 1800px) {
  469. .site-main {
  470. margin-top: 10em;
  471. }
  472. .section-inner {
  473. max-width: 1600px;
  474. }
  475. .thin {
  476. max-width: 960px;
  477. }
  478. hr.post-end {
  479. width: 30%;
  480. }
  481. }
  482. @media (max-width: 760px) {
  483. .hide-in-mobile, .site-nav.hide-in-mobile {
  484. display: none;
  485. }
  486. #menu-btn, #search-btn {
  487. display: inline-block;
  488. }
  489. .posts-group {
  490. display: block;
  491. margin-bottom: 2.5em;
  492. .post-year {
  493. margin-right: 0;
  494. margin-bottom: 8px;
  495. border-bottom: 2px dashed;
  496. }
  497. }
  498. #spotlight.error-404 {
  499. flex-direction: column;
  500. text-align: center;
  501. .banner-404 {
  502. margin: 0;
  503. }
  504. }
  505. }
  506. @media (max-width: 520px) {
  507. figure.left, figure.right {
  508. float: unset;
  509. margin: 0;
  510. }
  511. hr.post-end {
  512. width: 60%;
  513. }
  514. }