style.css 16 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773774775776777778779780781782783784785786787788789790791792793794795796797798799800801802803804805806807808809810811812813814815816817818819820821822823824825826827828829830831832833834835836837838839840841842843844845846847848849850851852853854855856857858859860861862863864865866867868869870871872873874875876877878879880881882883884885886887888889890891892893894895
  1. /* 기본 설정 */
  2. :root {
  3. --green-color: #5CB85C;
  4. --white-color: #ffffff;
  5. --light-grey-color: #bbbbbb;
  6. --grey-color: #999999;
  7. --black-color: #373a3c;
  8. --red-color: #b85c5c;
  9. --input-color: #66afe9;
  10. --dark-green-color: #3c8a3c;
  11. }
  12. /* columns */
  13. .col-1 {
  14. width: 8.33%;
  15. padding-left: 15px;
  16. padding-right: 15px;
  17. }
  18. .col-2 {
  19. width: 16.66%;
  20. padding-left: 15px;
  21. padding-right: 15px;
  22. }
  23. .col-3 {
  24. width: 25%;
  25. padding-left: 15px;
  26. padding-right: 15px;
  27. }
  28. .col-4 {
  29. width: 33.33%;
  30. padding-left: 15px;
  31. padding-right: 15px;
  32. }
  33. .col-5 {
  34. width: 41.66%;
  35. padding-left: 15px;
  36. padding-right: 15px;
  37. }
  38. .col-6 {
  39. width: 50%;
  40. padding-left: 15px;
  41. padding-right: 15px;
  42. }
  43. .col-7 {
  44. width: 58.33%;
  45. padding-left: 15px;
  46. padding-right: 15px;
  47. }
  48. .col-8 {
  49. width: 66.66%;
  50. padding-left: 15px;
  51. padding-right: 15px;
  52. }
  53. .col-9 {
  54. width: 75%;
  55. padding-left: 15px;
  56. padding-right: 15px;
  57. }
  58. .col-10 {
  59. width: 83.33%;
  60. padding-left: 15px;
  61. padding-right: 15px;
  62. }
  63. .col-11 {
  64. width: 91.66%;
  65. padding-left: 15px;
  66. padding-right: 15px;
  67. }
  68. .col-12 {
  69. width: 100%;
  70. padding-left: 15px;
  71. padding-right: 15px;
  72. }
  73. html {
  74. font-size: 16px;
  75. }
  76. body {
  77. margin: 0;
  78. font-family: 'Source Sans Pro', sans-serif;
  79. font-size: 1rem;
  80. line-height: 1.5;
  81. color: var(--black-color);
  82. }
  83. * {
  84. padding: 0;
  85. margin: 0;
  86. box-sizing: border-box;
  87. }
  88. ul, li {
  89. list-style: none;
  90. }
  91. a {
  92. text-decoration: none;
  93. color: var(--green-color);
  94. cursor: pointer;
  95. }
  96. button {
  97. font-family: 'Source Sans Pro', sans-serif;
  98. background-color: transparent;
  99. cursor: pointer;
  100. border: 1px solid transparent;
  101. }
  102. .container {
  103. margin-left: auto;
  104. margin-right: auto;
  105. padding-left: 1rem;
  106. padding-right: 1rem;
  107. }
  108. @media (min-width: 544px) {
  109. .container {
  110. max-width: 576px; }
  111. }
  112. @media (min-width: 768px) {
  113. .container {
  114. max-width: 720px; }
  115. }
  116. @media (min-width: 992px) {
  117. .container {
  118. max-width: 940px; }
  119. }
  120. @media (min-width: 1200px) {
  121. .container {
  122. max-width: 1140px; }
  123. }
  124. /* header */
  125. .navbar {
  126. padding: 0.5rem 1rem;
  127. }
  128. .navbar .container {
  129. display: flex;
  130. justify-content: space-between;
  131. align-items: center;
  132. }
  133. .navbar #logo {
  134. vertical-align: middle;
  135. width: 120px;
  136. height: auto;
  137. border-radius: 0;
  138. }
  139. .navbar .navbar-menu .nav-item {
  140. float: left;
  141. margin-left: 1rem;
  142. cursor: pointer;
  143. font-weight: 300;
  144. }
  145. .navbar .navbar-menu .nav-item .link {
  146. color: var(--light-grey-color);
  147. }
  148. .navbar .navbar-menu .nav-item a:hover {
  149. color: var(--black-color);
  150. }
  151. .navbar .navbar-menu .link.active {
  152. color: var(--black-color);
  153. font-weight: 400;
  154. }
  155. .navbar .navbar-menu .link.active:hover {
  156. filter: none;
  157. }
  158. .navbar .navbar-menu .nav-item .fas {
  159. font-size: 0.85rem;
  160. }
  161. /* main-page banner */
  162. .home-page .banner {
  163. background-color: var(--green-color);
  164. padding: 2rem;
  165. text-align: center;
  166. color: var(--white-color);
  167. }
  168. .home-page .banner .banner-title {
  169. font-family: 'Titillium Web',sans-serif;
  170. font-size: 3.5rem;
  171. text-shadow: 1px 1px 2px rgb(0,0,0,0.4);
  172. line-height: 1.1;
  173. padding-bottom: 0.5rem;
  174. }
  175. .home-page .banner .banner-description {
  176. font-size: 1.5rem;
  177. font-weight: 300;
  178. }
  179. .container.main {
  180. margin-top: 1.5rem;
  181. }
  182. .row {
  183. display: flex;
  184. flex-wrap: wrap;
  185. margin-left: -15px;
  186. margin-right: -15px;
  187. }
  188. /* article toggle button */
  189. .toggle .nav {
  190. overflow: hidden;
  191. margin-bottom: -1px;
  192. }
  193. .toggle .nav .nav-item {
  194. float: left;
  195. padding: 0.5rem 1rem;
  196. margin-bottom: -1px;
  197. color: var(--light-grey-color);
  198. }
  199. .toggle .nav .nav-item a {
  200. color: var(--light-grey-color);
  201. }
  202. .toggle .nav .nav-item.active {
  203. padding: 0.5rem 1rem;
  204. margin-bottom: -1px;
  205. border-bottom: 3px solid var(--green-color);
  206. }
  207. .toggle .nav .nav-item.active a {
  208. cursor: default;
  209. color: var(--green-color);
  210. }
  211. .toggle .nav #tag-feed a {
  212. display: flex;
  213. align-items: center;
  214. }
  215. .toggle .nav .nav-item.active div {
  216. cursor: default;
  217. color: var(--green-color);
  218. }
  219. /* article */
  220. .article-preview, #article-loading {
  221. border-top: 1px solid rgb(0, 0, 0, 0.2);
  222. padding: 1.5rem 0;
  223. text-align: start;
  224. }
  225. .article-preview .article-meta {
  226. display: flex;
  227. justify-content: space-between;
  228. margin-bottom: 0.8rem;
  229. }
  230. .article-meta .metadata {
  231. display: flex;
  232. }
  233. img {
  234. width: 2rem;
  235. height: 2rem;
  236. border-radius: 50%;
  237. }
  238. .article-meta .metadata .article-info {
  239. display: flex;
  240. flex-direction: column;
  241. font-weight: 300;
  242. margin-left: 0.5rem;
  243. line-height: 1rem;
  244. margin-right: 1.5rem;
  245. }
  246. .article-meta .metadata .article-info .name {
  247. font-weight: 500;
  248. }
  249. .article-info a:hover {
  250. text-decoration: underline;
  251. color: var(--dark-green-color);
  252. }
  253. .article-info .date {
  254. font-size: 0.8rem;
  255. color: var(--light-grey-color);
  256. }
  257. .preview-link h1{
  258. color: var(--black-color);
  259. line-height: 1.1;
  260. font-weight: 600;
  261. font-size: 1.5rem;
  262. margin-bottom: 0.2rem;
  263. }
  264. .preview-link p {
  265. color: var(--grey-color);
  266. font-weight: 300;
  267. margin-bottom: 1rem;
  268. line-height: 1.3;
  269. }
  270. /* 좋아요 버튼 */
  271. .favorite-btn {
  272. color: var(--green-color);
  273. font-weight: normal;
  274. line-height: 1.25;
  275. border: 1px solid transparent;
  276. cursor: pointer;
  277. border-color: var(--green-color);
  278. padding: 0.25rem 0.5rem;
  279. border-radius: 0.2rem;
  280. font-size: 0.8rem;
  281. }
  282. .favorite-btn i {
  283. font-size: 0.725rem;
  284. pointer-events: none;
  285. }
  286. .favorite-btn.active,
  287. .favorite-btn:hover {
  288. color: var(--white-color);
  289. background-color: var(--green-color);
  290. }
  291. .favorite-btn span {
  292. pointer-events: none;
  293. }
  294. /* article tags */
  295. .tag-data {
  296. display: flex;
  297. justify-content: space-between;
  298. color: var(--light-grey-color);
  299. font-weight: 300;
  300. font-size: 0.8rem;
  301. }
  302. .tag-list .tag {
  303. border: 1px solid #dddddd;
  304. border-radius: 10rem;
  305. padding: 0 0.5rem;
  306. color: var(--grey-color);
  307. font-weight: 300;
  308. font-size: 0.8rem;
  309. margin-left: 3px;
  310. }
  311. /* main-page */
  312. .aside {
  313. background-color: #f2f2f2;
  314. border-radius: 3px;
  315. padding: 5px 10px 10px 10px;
  316. }
  317. .home-page .aside .tag-list {
  318. display: inline-block;
  319. }
  320. .home-page .aside .tag-list .tag {
  321. color: var(--white-color);
  322. font-size: 0.8rem;
  323. padding-top: 0.1rem;
  324. padding-bottom: 0.1rem;
  325. white-space: nowrap;
  326. margin-right: 3px;
  327. margin-bottom: 0.2rem;
  328. display: inline-block;
  329. background-color: #818a92;
  330. margin-left: 0;
  331. font-weight: normal;
  332. border: none;
  333. }
  334. .home-page .aside .tag-list .tag:hover,
  335. .home-page .aside .tag-list .tag.active {
  336. background-color: #646d74;
  337. }
  338. .home-page .aside .tag-list .tag.active {
  339. text-decoration: underline;
  340. }
  341. /* 다음 페이지 더보기 */
  342. .more-button {
  343. float: right;
  344. margin-top: 0.6rem;
  345. margin-bottom: 1.2rem;
  346. border-bottom: 1px solid #818a92;
  347. padding: 0.1rem 0;
  348. font-size: 1.2rem;
  349. font-weight: 600;
  350. }
  351. .home-page #article-list {
  352. text-align: center;
  353. }
  354. /* 로딩 애니메이션 https://codepen.io/mandelid/pen/vwKoe */
  355. #loading {
  356. display: inline-block;
  357. position: absolute;
  358. width: 50px;
  359. height: 50px;
  360. margin-left: -25px;
  361. padding-bottom: 2rem;
  362. border: 3px solid rgba(255,255,255, 0.1);
  363. border-radius: 50%;
  364. border-top-color: #aaa;
  365. animation: spin 1s ease-in-out infinite;
  366. -webkit-animation: spin 1s ease-in-out infinite;
  367. }
  368. @keyframes spin {
  369. to { -webkit-transform: rotate(360deg); }
  370. }
  371. @-webkit-keyframes spin {
  372. to { -webkit-transform: rotate(360deg); }
  373. }
  374. /* Sign in & Sign up */
  375. .container .col-6 {
  376. text-align: center;
  377. float: none;
  378. margin: auto;
  379. }
  380. .container .col-6 .sign-in-title {
  381. font-size: 2.5rem;
  382. font-weight: 500;
  383. line-height: 1.1;
  384. margin-bottom: 0.5rem;
  385. }
  386. .container .col-6 p {
  387. text-align: center;
  388. margin-bottom: 1rem;
  389. }
  390. .container .row .col-6 a:hover {
  391. text-decoration: underline;
  392. color: var(--dark-green-color);
  393. }
  394. .container .col-6 .form-data {
  395. margin-bottom: 1rem;
  396. }
  397. .form-group {
  398. display: flex;
  399. flex-direction: column;
  400. }
  401. .form-data .form-control {
  402. padding: 0.8rem 1.5rem;
  403. font-size: 1.25rem;
  404. border-radius: 0.3rem;
  405. width: 100%;
  406. line-height: 1.25;
  407. color: var(--black-color);
  408. border: 1px solid #dddddd;
  409. font-family: 'Source Sans Pro', sans-serif;
  410. }
  411. input::placeholder,
  412. textarea::placeholder{
  413. color: var(--grey-color);
  414. }
  415. .form-control:focus {
  416. outline: none;
  417. border-color: var(--input-color);
  418. }
  419. .btn-signIn,
  420. .btn-signUp,
  421. .btn-settings,
  422. .btn-card {
  423. padding: 0.8rem 1.5rem;
  424. font-size: 1.1rem;
  425. border-radius: 0.3rem;
  426. border-color: var(--green-color);
  427. background-color: var(--green-color);
  428. color: var(--white-color);
  429. }
  430. button:last-child {
  431. align-self: end;
  432. }
  433. .navbar-menu .username {
  434. display: flex;
  435. align-items: center;
  436. }
  437. .navbar-menu .nav-item img {
  438. width: 26px;
  439. height: 26px;
  440. border-radius: 50%;
  441. vertical-align: middle;
  442. }
  443. /* 게시글 생성, 수정 */
  444. .container .col-10 {
  445. text-align: center;
  446. float: none;
  447. margin: auto;
  448. }
  449. .container .col-10 .form-data {
  450. margin-bottom: 1rem;
  451. }
  452. .form-data .form-control-sm {
  453. padding: 0.5rem 0.75rem;
  454. font-size: 1rem;
  455. }
  456. textarea {
  457. resize: vertical;
  458. font-family: 'Source Sans Pro', sans-serif;
  459. }
  460. .editor-page .tag-list {
  461. flex-wrap: wrap;
  462. }
  463. .editor-page .tag-list .tag {
  464. display: flex;
  465. align-items: center;
  466. margin-bottom: 0.2rem;
  467. margin-right: 3px;
  468. margin-left: 0;
  469. padding-top: 0.1rem;
  470. background-color: #818a92;
  471. color: var(--white-color);
  472. font-weight: normal;
  473. border: none;
  474. }
  475. .editor-page .tag-list .tag i {
  476. margin-left: 3px;
  477. }
  478. .editor-page .tag-list .tag i:hover {
  479. cursor: pointer;
  480. }
  481. .editor-page .form-data .tag-form {
  482. margin-bottom: 0.2rem;
  483. }
  484. /* Article Banner */
  485. .article-page .banner {
  486. background-color: var(--black-color);
  487. padding: 2rem;
  488. color: var(--white-color);
  489. }
  490. .article-page .banner .article-banner-title {
  491. font-size: 2.8rem;
  492. font-weight: 600;
  493. }
  494. .article-page .banner .article-meta {
  495. margin-top: 2rem;
  496. }
  497. .article-page .banner .article-info .name {
  498. color: var(--white-color);
  499. }
  500. .article-page .banner .article-info .name:hover {
  501. filter: none;
  502. }
  503. .article-page button i,
  504. .article-page button span {
  505. pointer-events: none;
  506. }
  507. .article-page .edit-article,
  508. .article-page .follow-btn {
  509. color: var(--light-grey-color);
  510. border: 1px solid var(--light-grey-color);
  511. margin-right: 3px;
  512. font-weight: 400;
  513. font-size: 0.9rem;
  514. }
  515. .article-page .edit-article:hover,
  516. .article-page .follow-btn:hover {
  517. color: var(--white-color);
  518. background-color: var(--light-grey-color);
  519. }
  520. .article-page .follow-btn.active {
  521. color: var(--white-color);
  522. background-color: var(--light-grey-color);
  523. }
  524. .article-page .delete-article {
  525. color: var(--red-color);
  526. border-color: var(--red-color);
  527. font-weight: 400;
  528. font-size: 0.9rem;
  529. }
  530. .article-page .favorite-btn {
  531. font-weight: 400;
  532. font-size: 0.9rem;
  533. }
  534. .article-page .delete-article:hover {
  535. color: var(--white-color);
  536. background-color: var(--red-color);
  537. }
  538. .article-page pre{
  539. font-family: 'Source Serif Pro', serif;
  540. font-size: 1.25rem;
  541. line-height: 1.8rem;
  542. margin-bottom: 2rem;
  543. white-space: pre-line;
  544. }
  545. .tag-list {
  546. display: flex;
  547. }
  548. .article-page .tag-list .tag {
  549. margin-left: 0 !important;
  550. margin-right: 3px;
  551. }
  552. .article-page .article-content ul {
  553. padding-bottom: 1rem;
  554. }
  555. .article-page .col-12 {
  556. padding: 0;
  557. }
  558. .article-page .article-actions {
  559. display: flex;
  560. justify-content: center;
  561. margin-top: 1.5rem;
  562. margin-bottom: 3rem;
  563. }
  564. .article-page .row {
  565. display: flex;
  566. justify-content: center;
  567. }
  568. .card {
  569. margin-bottom: 0.75rem;
  570. border-radius: 0.25rem;;
  571. }
  572. .form-control {
  573. display: block;
  574. width: 100%;
  575. font-size: 1rem;
  576. color: var(--black-color);
  577. line-height: 1.25;
  578. border-radius: 0.25rem;
  579. }
  580. .article-page .card {
  581. border: 1px solid #eeeeee;
  582. box-shadow: none;
  583. }
  584. .article-page .comment-form .card-block {
  585. padding: 0;
  586. }
  587. .article-page .comment-form .card-block textarea {
  588. border: 0px;
  589. padding: 1.25rem;
  590. }
  591. .card-footer {
  592. padding: 0.75rem 1.25rem;
  593. background-color: #f5f5f5;
  594. }
  595. .article-page .comment-form .card-footer {
  596. display: flex;
  597. justify-content: space-between !important;
  598. align-items: center;
  599. }
  600. .article-page .card .card-footer {
  601. border-top: 1px solid #eeeeee;
  602. box-shadow: none;
  603. font-size: 0.8rem;
  604. font-weight: 300;
  605. }
  606. .article-page .card .card-footer .date-posted {
  607. color: var(--light-grey-color);
  608. }
  609. .card-footer:last-child {
  610. border-radius: 0 0 0.25rem 0.25rem;
  611. }
  612. .article-page .comment-form .card-footer .comment-img {
  613. height: 30px;
  614. width: 30px;
  615. }
  616. .article-page .comment-form .card-footer .btn {
  617. font-weight: 700 !important;
  618. }
  619. .card-block {
  620. padding: 1.25rem;
  621. }
  622. .article-page .card .comment-img {
  623. width: 20px;
  624. height: 20px;
  625. margin-right: 5px;
  626. }
  627. .article-page .card .card-footer .comment-author:hover {
  628. text-decoration: underline;
  629. color: var(--dark-green-color);
  630. }
  631. .article-page .card .date-posted {
  632. margin-left: 5px;
  633. }
  634. .article-page .card .card-footer {
  635. display: flex;
  636. justify-content: space-between;
  637. align-items: center;
  638. }
  639. .article-page .card .card-footer i {
  640. color: var(--grey-color);
  641. cursor: pointer;
  642. }
  643. .article-page .card .card-footer i:hover {
  644. color: rgba(0, 0, 0, 0.8);
  645. }
  646. .article-page .card .card-footer .user-info {
  647. display: flex;
  648. align-items: center;
  649. }
  650. /* settings */
  651. hr {
  652. width: 100%;
  653. margin-top: 1rem;
  654. margin-bottom: 1rem;
  655. border-top: 1px solid rgba(0, 0, 0, 0.1);
  656. box-sizing: content-box;
  657. }
  658. .btn-logout {
  659. float: left;
  660. color: var(--red-color);
  661. border-color: var(--red-color);
  662. padding: 0.5rem 1rem;
  663. border-radius: 0.3rem;
  664. font-size: 1rem;
  665. font-weight: normal;
  666. line-height: 1.25;
  667. }
  668. .btn-logout:hover {
  669. background-color: var(--red-color);
  670. color: var(--white-color);
  671. }
  672. .btn-sm {
  673. padding: 0.25rem 0.5rem;
  674. font-size: 0.8rem;
  675. border-radius: 0.2rem;
  676. font-weight: 100;
  677. }
  678. /* user-page */
  679. .user-page .user-info {
  680. background-color: #eeeeee;
  681. padding: 2rem 0 1rem 0;
  682. }
  683. .user-page .user-info .user-img {
  684. width: 100px;
  685. height: 100px;
  686. border-radius: 100px;
  687. margin-bottom: 1rem;;
  688. }
  689. .user-page .user-info h4 {
  690. font-weight: 700;
  691. font-size: 1.5rem;
  692. line-height: 1.1;
  693. margin-bottom: 0.5rem;
  694. }
  695. .user-page pre {
  696. font-family: 'Source Sans Pro', serif;
  697. white-space: pre-line;
  698. margin: 0 auto 0.5rem auto;
  699. color: #aaaaaa;
  700. max-width: 450px;
  701. font-weight: 300;
  702. }
  703. .user-page .user-info .action-btn {
  704. float: right;
  705. color: var(--grey-color);
  706. border: 1px solid var(--grey-color);
  707. font-weight: normal;
  708. }
  709. .user-page .user-info .action-btn.active,
  710. .user-page .user-info .action-btn:hover {
  711. color: #999999;
  712. background-color: var(--white-color);
  713. }
  714. .user-page .article-preview {
  715. text-align: start;
  716. }
  717. /* modal.jsp */
  718. #modal-container {
  719. position: fixed;
  720. width: 100%;
  721. height: 100%;
  722. top: 0;
  723. left: 0;
  724. background: rgba(0, 0, 0, 0.3);
  725. }
  726. .modal-body {
  727. z-index: 10000;
  728. position: absolute;
  729. padding: 30px 40px;
  730. display: flex;
  731. justify-content: center;
  732. flex-direction: column;
  733. background: var(--white-color);
  734. cursor: default;
  735. width: 60%;
  736. height: 30%;
  737. margin: auto;
  738. left: 0;
  739. right: 0;
  740. top: 0;
  741. bottom: 0;
  742. border-color: rgba(0, 0, 0, 0.3);
  743. border-style: groove;
  744. border-radius: 1rem;
  745. }
  746. .modal-message {
  747. padding-bottom: 40px;
  748. font-size: 2rem;
  749. font-family: 'Noto Sans KR', sans-serif;
  750. color: var(--green-color);
  751. }
  752. .modal-close-btn {
  753. position: relative;
  754. background-color: var(--green-color);
  755. color: var(--white-color);
  756. font-weight: 700;
  757. font-family: 'Noto Sans KR', sans-serif;
  758. width: 5rem;
  759. height: 2rem;
  760. border-radius: 0.3rem;
  761. cursor: pointer;
  762. margin: 0 auto;
  763. margin-top: 1rem;
  764. }