theme.lungo.styl 8.2 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330
  1. /**
  2. * Stylesheet
  3. *
  4. * @namespace Lungo.Theme
  5. * @class Default
  6. *
  7. * @author Javier Jimenez Villar <javi@tapquo.com> || @soyjavi
  8. */
  9. /* @import url("https://raw.github.com/soyjavi/CSSmethods/master/stylus/vendor.styl") */
  10. @import "CSSmethods/vendor.styl"
  11. @import url("http://fonts.googleapis.com/css?family=Open+Sans:300,400,600,700")
  12. /* -------------------------- THEME -------------------------- */
  13. CONTENT = #f4f5f5
  14. COLOR = #333
  15. COLOR_secondary = #BFBFBF
  16. COLOR_cancel = #EE6557
  17. COLOR_accept = #3FB58E
  18. DARK = #222
  19. DARK_light = lighten(DARK, 25%)
  20. DARK_dark = darken(DARK, 15%)
  21. DARK_darkest = darken(DARK, 30%)
  22. FORM_radius = 1px
  23. LIST_color_2nd = lighten(COLOR, 35%)
  24. LIST_border = lighten(COLOR, 90%)
  25. NAV_LINK = #888
  26. NAV_LINK_ACTIVE = #FFF
  27. THEME = #0093D5
  28. THEME_light = lighten(THEME, 15%)
  29. THEME_dark = darken(THEME, 15%)
  30. /* -------------------------- DEFAULTS -------------------------- */
  31. body
  32. background-color: DARK
  33. color: COLOR
  34. font-family: "Open Sans", "Helvetica Neue", Helvetica, Arial, sans-serif
  35. font-weight: 400
  36. font-size: 13px
  37. line-height: 1.3em
  38. letter-spacing: -0.05em
  39. & .theme
  40. background-color: THEME-light
  41. &:active
  42. background-color: THEME
  43. /* -------------------------- LAYOUT COLORS -------------------------- */
  44. section
  45. background-color: DARK
  46. & > header
  47. background-color: THEME
  48. box-shadow 0 2px 0 rgba(0,0,0,0.15), inset 0 1px 0 THEME_light, inset 0 -1px 0 THEME_dark
  49. color: #fff
  50. border-radius 4px 4px 0 0
  51. & > footer, & nav.groupbar
  52. background-color: DARK
  53. box-shadow inset 0 3px 0 DARK_dark
  54. & > article, & > [data-control="pull"]
  55. background-color: CONTENT
  56. &.splash
  57. background: DARK
  58. color: #fff
  59. &.aside
  60. box-shadow -1px 0 2px rgba(0,0,0,0.2)
  61. &.right
  62. box-shadow 1px 0 2px rgba(0,0,0,0.2)
  63. DARKEST = darken(DARK_darkest, 15%)
  64. aside
  65. background-color: DARK_dark
  66. color: #fff
  67. & > header, > footer
  68. background-color: DARK_darkest
  69. & > header
  70. box-shadow 0 1px 3px rgba(0,0,0,0.25), inset 0 1px 0 DARK, inset 0 -1px 0 DARKEST
  71. /* -------------------------- NAVIGATION -------------------------- */
  72. nav
  73. section > header > &
  74. & a:not(.button)
  75. color: darken(THEME, 35%)
  76. text-shadow 0 1px 0 lighten(THEME, 25%)
  77. &:active
  78. color: darken(THEME, 50%)
  79. section > &.groupbar > a.active
  80. box-shadow inset 0 -3px 0 THEME
  81. section > footer > & > a, &.groupbar > a
  82. color: NAV_LINK
  83. &.active
  84. color: NAV_LINK_ACTIVE
  85. section > footer > & > a
  86. box-shadow 1px 0 0 DARK_dark
  87. &.active
  88. color: NAV_LINK_ACTIVE
  89. background-color: DARK_dark
  90. box-shadow inset 0 3px 0 THEME
  91. aside & a
  92. color: lighten(DARK, 20%)
  93. &:active
  94. color: lighten(DARK, 50%)
  95. &[data-control=menu]
  96. COLOR = DARK
  97. background: COLOR
  98. box-shadow 0 2px 0 rgba(0,0,0,0.15)
  99. & > a
  100. color: #fff
  101. text-shadow 0 1px 0 #111
  102. font-weight: 700
  103. border-bottom: 1px solid darken(COLOR, 40%)
  104. border-top: 1px solid lighten(COLOR, 5%)
  105. &:active
  106. background: #111
  107. border-color: transparent
  108. & > .icon
  109. color: lighten(COLOR, 25%)
  110. /* -------------------------- LISTS -------------------------- */
  111. .list
  112. section & li
  113. background: #fff
  114. &:not(.anchor)
  115. border-bottom: inset 1px LIST_border
  116. &.secondary
  117. box-shadow: inset 4px 0px 0px COLOR_secondary
  118. &.accept
  119. box-shadow: inset 4px 0px 0px COLOR_accept
  120. &.cancel
  121. box-shadow: inset 4px 0px 0px COLOR_cancel
  122. &, & a
  123. color: LIST_color
  124. &.anchor
  125. background: DARK
  126. &.dark
  127. background: DARK_light
  128. &.selectable:active, &.theme, &.active
  129. background: THEME_light
  130. &.light
  131. background: LIST_border
  132. color: LIST_color_2nd
  133. &.dark, &.selectable:active, &.theme, &.anchor
  134. &, small, & .right:not(.tag)
  135. color: #fff
  136. & small, & .right:not(.tag)
  137. color: LIST_color_2nd
  138. &:not(.indented) li
  139. &.dark, &.theme, &.light
  140. border-bottom-color: rgba(0,0,0,0.1)
  141. aside & li
  142. background: none
  143. &:not(:first-child)
  144. border-top: solid 1px DARK
  145. &:not(:last-child)
  146. border-bottom: solid 1px DARKEST
  147. &:active
  148. background: DARK_darkest
  149. &.active
  150. background: THEME
  151. &.active, &:active
  152. border-color: transparent
  153. & strong, & small, & .icon
  154. color: #fff
  155. & strong
  156. color: #999
  157. & small, .icon
  158. color: #666
  159. /* -------------------------- TAG -------------------------- */
  160. .tag:not(.icon)
  161. color: #fff
  162. border-radius 2px
  163. font-weight: 700 !important
  164. &.count
  165. background-color: THEME
  166. header .count
  167. background-color: THEME-dark !important
  168. footer &
  169. box-shadow inset 0 1px 1px rgba(255,255,255,0.3), 0 1px 2px rgba(0,0,0,0.5)
  170. [data-control="pull"]
  171. text-shadow: 0 1px 0 #fff
  172. /* -------------------------- NOTIFICATION -------------------------- */
  173. .notification
  174. color: #fff
  175. & .window
  176. &.growl
  177. background: rgba(0,0,0,0.8)
  178. &:not(.growl)
  179. background: #e6e6e6
  180. color: #222
  181. box-shadow(0 0 8px #000)
  182. & button, .button
  183. background: #fff !important
  184. box-shadow: none !important
  185. color: THEME_dark !important
  186. border-radius 0px !important
  187. border: none !important
  188. margin-bottom: 1px
  189. &.error
  190. background: darken(COLOR_cancel, 25%)
  191. color: #fff
  192. &.success
  193. background: darken(COLOR_accept, 25%)
  194. color: #fff
  195. /* -------------------------- BUTTONS -------------------------- */
  196. header
  197. & .button, button
  198. background-color: THEME_dark
  199. box-shadow 0 1px 0 lighten(THEME, 15%), inset 0 1px 0 darken(THEME, 35%)
  200. border-radius 4px
  201. &:active
  202. background-color: darken(THEME, 40%)
  203. article
  204. & .button, button
  205. border-radius(FORM-border-radius)
  206. color: white
  207. border-radius 2px
  208. box-shadow inset 0 1px 0 rgba(255,255,255,0.2)
  209. border: solid 1px rgba(0,0,0,0.1)
  210. &:active
  211. box-shadow inset 0 0 128px rgba(0,0,0,0.25)
  212. border-color: none
  213. &.secondary
  214. color: #666 !important
  215. &[disabled]
  216. background-color: black
  217. & button, .button, .tag:not(.icon)
  218. &
  219. background-color: THEME_dark
  220. &.secondary
  221. background-color: COLOR_secondary
  222. &.accept
  223. background-color: COLOR_accept
  224. &.cancel
  225. background-color: COLOR_cancel
  226. /* -------------------------- FORMS -------------------------- */
  227. FORM_shadow_form = 'inset 0 1px 2px rgba(0,0,0,0.1)'
  228. FORM_shadow_form_active = 'inset 0 1px 1px rgba(0,0,0,0.1), 3px 0 #f0eeef, 0 3px #f0eeef, -3px 0 #f0eeef, 0 -3px #f0eeef'
  229. FORM_border_color = #D0D4C6
  230. form, .form
  231. & label
  232. color: #aaa
  233. font-weight: 300
  234. & fieldset
  235. background: #fff
  236. border-bottom: solid 1px #eee
  237. & .icon
  238. color: #ccc
  239. & input[type="text"], input[type="password"], input[type="date"], input[type="datetime"], input[type="email"], input[type="number"], input[type="search"], input[type="tel"], input[type="time"], input[type="url"], select, textarea
  240. background-color: white
  241. color: rgba(0, 0, 0, 0.75)
  242. border: 1px solid #ddd
  243. box-shadow inset 0 1px 2px rgba(0, 0, 0, 0.1)
  244. border-radius (0px)
  245. &.error, &:required
  246. border-color: color_alert
  247. color: color_alert
  248. background-color: rgba(198, 15, 19, 0.1)
  249. &:focus
  250. background: #FAFAFA;
  251. border-color: THEME;
  252. color: rgba(0, 0, 0, 0.75)
  253. &[disabled]
  254. background: #eee
  255. border-color: #aaa
  256. color: #999
  257. & .select:after
  258. background: FORM_border_color
  259. color: white
  260. border-top-right-radius: FORM_radius
  261. border-bottom-right-radius: FORM_radius
  262. & input[type=range]
  263. box-shadow FORM_shadow_form
  264. &:not(.checkbox)
  265. background-color: #ddd
  266. &:active
  267. background-color: THEME_light
  268. &.checkbox
  269. background-color: #aaa
  270. color: rgba(255,255,255,0.6)
  271. &.active
  272. color: #fff
  273. background-color: THEME_light
  274. &::-webkit-slider-thumb
  275. border-radius: 2px
  276. background-color: lighten(FORM_border_color, 50%)
  277. border: solid 1px FORM_border_color
  278. &::-webkit-slider-thumb::after
  279. background: FORM_border_color
  280. & .progress
  281. & .bar
  282. background-color: #ddd
  283. & .value
  284. background-color: THEME_light