assets/css/lesson.scss: add proper padding to the top of paragraphs in blockquotes...
[rnaseq-cwl-training.git] / assets / css / lesson.scss
1 ---
2 ---
3
4 //----------------------------------------
5 // Colors.
6 //----------------------------------------
7
8 // branding
9 $color-brand:       #2b3990 !default;
10
11 // code boxes
12 $color-error:       #bd2c00 !default;
13 $color-output:      #303030 !default;
14 $color-source:      #360084 !default;
15
16 // blockquotes
17 $color-callout:     #f4fd9c !default;
18 $color-challenge:   #eec275 !default;
19 $color-checklist:   #dfd2a0 !default;
20 $color-discussion:  #eec275 !default;
21 $color-keypoints:   #7ae78e !default;
22 $color-objectives:  #daee84 !default;
23 $color-prereq:      #9cd6dc !default;
24 $color-solution:    #ded4b9 !default;
25 $color-testimonial: #fc8dc1 !default;
26
27 //----------------------------------------
28 // Specialized code blocks.
29 //----------------------------------------
30
31 @mixin cdSetup($color) {
32     color: $color;
33     border: solid 1px $color;
34     border-left: solid 5px $color;
35     margin: 15px 5px 10px 0;
36     border-radius: 4px 0 0 4px;
37 }
38
39 .error  { @include cdSetup($color-error); }
40 .output { @include cdSetup($color-output); }
41 .source { @include cdSetup($color-source); }
42
43 .bash, .language-bash     { @include cdSetup($color-source); }
44 .make, .language-make     { @include cdSetup($color-source); }
45 .matlab, .language-matlab { @include cdSetup($color-source); }
46 .python, .language-python { @include cdSetup($color-source); }
47 .r, .language-r           { @include cdSetup($color-source); }
48 .sql, .language-sql       { @include cdSetup($color-source); }
49
50 .error::before,
51 .output::before,
52 .source::before,
53 .bash::before, .language-bash::before,
54 .make::before, .language-make::before,
55 .matlab::before, .language-matlab::before,
56 .python::before, .language-python::before,
57 .r::before, .language-r::before,
58 .sql::before, .language-sql::before {
59   background-color: #f2eff6;
60   display: block;
61   font-weight: bold;
62   padding: 5px 10px;
63 }
64
65 .error::before  { background-color: #ffebe6; content: "Error"; }
66 .output::before { background-color: #efefef; content: "Output"; }
67 .source::before { content: "Code"; }
68 .bash::before, .language-bash::before { content: "Bash"; }
69 .make::before, .language-make::before { content: "Make"; }
70 .matlab::before, .language-matlab::before { content: "Matlab"; }
71 .python::before, .language-python::before { content: "Python"; }
72 .r::before, .language-r::before { content: "R"; }
73 .sql::before, .language-sql::before { content: "SQL"; }
74
75
76 //----------------------------------------
77 // Specialized blockquote environments for learning objectives, callouts, etc.
78 //----------------------------------------
79
80 $codeblock-padding: 5px !default;
81
82 @mixin bkSetup($color, $glyph) {
83
84   $gradientcolor1: $color;
85   $gradientcolor2: scale-color($color, $lightness: 10%);
86
87   padding: 0 0 $codeblock-padding $codeblock-padding;
88   border: 1px solid;
89   border-color: $color;
90   border-radius: 4px;
91
92   margin: 15px 5px 10px 0;
93
94   h2 {
95     padding-top: $codeblock-padding;
96     padding-bottom: $codeblock-padding;
97     font-size: 20px;
98     background: linear-gradient(to bottom, $gradientcolor1, $gradientcolor2);
99     border-color: $color;
100     margin-top: 0px;
101     margin-left: -$codeblock-padding; // to move back to the left margin of the enclosing blockquote
102   }
103   h2:before {
104     font-family: 'Glyphicons Halflings';
105     content: $glyph;
106     float: left;
107     padding-left: $codeblock-padding;
108     padding-right: $codeblock-padding;
109     display: inline-block;
110     -webkit-font-smoothing: antialiased;
111   }
112
113 }
114
115 .callout{ @include bkSetup($color-callout, "\e146"); }
116 .challenge{ @include bkSetup($color-challenge, "\270f"); }
117 .checklist{ @include bkSetup($color-checklist, "\e067"); }
118 .discussion{ @include bkSetup($color-discussion, "\e123"); }
119 .keypoints{ @include bkSetup($color-keypoints, "\e101"); }
120 .objectives{ @include bkSetup($color-objectives, "\e085"); }
121 .prereq{ @include bkSetup($color-prereq, "\e124"); }
122 .solution{ @include bkSetup($color-solution, "\e105"); }
123 .testimonial{ @include bkSetup($color-testimonial, "\e143"); }
124
125 .callout h3,
126 .challenge h3,
127 .checklist h3,
128 .discussion h3,
129 .keypoints h3,
130 .objectives h3,
131 .prereq h3,
132 .solution h3,
133 .testimonial h3 {
134 font-size: 18px;
135 }
136
137 .challenge    { background-color: #eec27520; }
138 .callout      { background-color: #f4fd9c20; }
139 .challenge    { background-color: #eec27520; }
140 .checklist    { background-color: #dfd2a020; }
141 .discussion   { background-color: #eec27520; }
142 .keypoints    { background-color: #7ae78e20; }
143 .objectives   { background-color: #daee8420; }
144 .prereq       { background-color: #9cd6dc20; }
145 .solution     { background-color: #ded4b94d; }
146 .testimonial  { background-color: #fc8dc120; }
147
148 blockquote p {
149     margin: 5px;
150 }
151 blockquote :not(h2) + p {
152     padding-top: 1em;
153 }
154
155 //----------------------------------------
156 // Override Bootstrap settings.
157 //----------------------------------------
158
159 code {
160   white-space: nowrap;
161   padding: 2px 5px;
162   color: #006cad;
163   background-color: #e7e7e7;
164 }
165
166 article img {
167     display: block;
168     margin: 20px auto;
169     max-width: 100%;
170 }
171
172 article h2 {
173   margin: 48px 0 16px;
174   border-bottom: solid 1px #eaecef;
175   padding-bottom: 0.3em;
176   line-height: 1.25;
177 }
178
179 article h3 { margin: 40px 0 16px; }
180
181 article pre {
182     margin: 0;
183     border: 0;
184 }
185
186 //----------------------------------------
187 // Miscellaneous.
188 //----------------------------------------
189
190 .figures h2 { margin-top: 100px; }
191
192 .maintitle {
193   text-align: center;
194 }
195
196 .footertext {
197   text-align: center;
198 }
199
200 footer .copyright,
201 footer .help-links
202 {
203     font-size: inherit;
204     margin-top: 10px;
205     margin-bottom: 10px;
206     font-weight: 500;
207     line-height: 1.1;
208 }
209
210 img.navbar-logo {
211   height: 40px; // synchronize with height of navbar
212   padding-top: 5px;
213   padding-right: 10px;
214 }
215
216 div.branding {
217   color: $color-brand;
218 }
219
220 ul,
221 ol {
222   padding-left: 2em;
223 }
224
225 span.fold-unfold {
226   margin-left: 1em;
227   opacity: 0.5;
228 }
229
230
231 //----------------------------------------
232 // Life cycle box
233 //----------------------------------------
234
235 div.life-cycle {
236     position: -webkit-sticky; /* Safari */
237     position: sticky;
238     top: 0;
239     z-index: 100;
240     font-size: 1.2em;
241     text-align: center;
242     margin-bottom: -1px;
243     border-radius: 0;
244 }
245
246 .pre-alpha {
247     color: #a94442;
248     background: #f2dede;
249 }
250
251 .alpha {
252     color: #8a6d3b;
253     background: #fcf8e3;
254 }
255
256 .beta {
257     color: #31708f;
258     background: #d9edf7;
259 }
260
261
262 //----------------------------------------
263 // keyboard key style, from StackExchange.
264 //----------------------------------------
265
266 kbd {
267     display: inline-block;
268     margin: 0 .1em;
269     padding: .1em .6em;
270     font-family: Arial,"Helvetica Neue",Helvetica,sans-serif;
271     font-size: 11px;
272     line-height: 1.4;
273     color: #242729;
274     text-shadow: 0 1px 0 #FFF;
275     background-color: #e1e3e5;
276     border: 1px solid #adb3b9;
277     border-radius: 3px;
278     box-shadow: 0 1px 0 rgba(12,13,14,0.2), 0 0 0 2px #FFF inset;
279     white-space: nowrap;
280     font-style: normal;
281 }