Merge branch 'obrazy' into rwd
[wolnelektury.git] / apps / wolnelektury_core / static / scss / main / book_box.scss
1 @mixin inner-box {
2     display: block;
3     color: black;
4     @include size(margin, 1px);
5     @include size(padding, 8px 10px);
6     @include white-box;
7 }
8
9 .book-mini-box img.cover {
10     @include size(height, 193px);
11     @include size(width, 139px);
12 }
13
14
15 .cover-area {
16     float: left;
17     @include size(margin-right, 15px);
18     @include size(margin-bottom, 5px);
19
20     @include min-screen($S_BOOK_SHORT_FULL) {
21         position: absolute;
22         top: 0;
23         left: 0;
24         margin-right: 0;
25     }
26
27     img.cover {
28         @include size(height, 193px / 2);
29         @include size(width, 139px / 2);
30
31         @include min-screen($S_BOOK_SHORT_MEDIUM) {
32             @include size(height, 193px);
33             @include size(width, 139px);
34         }
35     }
36 }
37
38 .book-mini-box {
39     @include size(width, 161.5px);
40     display: inline-block;
41     vertical-align: top;
42
43     .book-mini-box-inner {
44         @include inner-box;
45         @include size(height, 271px);
46         @include size(margin, 1px);
47         overflow: hidden;
48         a {
49             display: block;
50         }
51     }
52     img.cover {
53         @include size(margin-bottom, 18px);
54     }
55     .language {
56         color: #aaa;
57         float: right;
58         @include mono;
59         @include size(font-size, 10px);
60         text-transform: uppercase;
61         position: relative;
62         @include size(top, -20px);
63     }
64     .desc {
65         margin-left: 0;
66     }
67     .author {
68         @include size(font-size, 11px);
69         @include mono;
70         color: #6d7877;
71         display: block;
72         overflow: hidden;
73         text-overflow: ellipsis;
74         white-space: nowrap;
75     }
76     .title {
77         @include size(font-size, 14px);
78         color: #242424;
79     }
80 }
81
82
83
84 .work-list {
85     margin: 0;
86     padding: 0;
87     list-style: none;
88
89     .Book-item {
90         @include min-screen($S_BOOK_SHORT_FULL) {
91             display: inline-block;
92         }
93         vertical-align: top;
94     }
95 }
96
97
98 .book-box {
99     margin: 0;
100     vertical-align: top;
101
102     /* */
103     a {
104         color: #0D7E85;
105     }
106
107     @include min-screen($S_BOOK_SHORT_FULL) {
108         @include size(width, $W_BOOK_SHORT_FULL);
109     }
110
111     .book-box-inner {
112         position: relative;
113         @include inner-box;
114         @include size(min-height, 197.5px);
115     }
116 }
117
118
119 .book-wide-box {
120     margin: 0;
121     vertical-align: top;
122
123     @media screen and (min-width: 62.5em) {
124         @include size(width, 975px);
125     }
126
127     .book-box-inner {
128         position: relative;
129         @include size(min-height, 244px);
130         @include inner-box;
131         @include size(margin-left, 0);
132         @include size(margin-right, 0);
133
134         .book-left-column { /* FIXME */
135             @media screen and (min-width: 62.5em) {
136                 float: left;
137                 @include size(width, 536px);
138             }
139         }
140
141         .license-icon {
142             display: block;
143             @include size(margin-top, 5px);
144         }
145
146         .book-box-head,
147         .tags,
148         .book-box-tools {
149             @media screen and (min-width: 62.5em) {
150                 @include size(width, 382px);
151             }
152         }
153
154         #theme-list-wrapper {
155             @include min-screen($S_BOOK_SHORT_MEDIUM) {
156                 @include size(margin-left, 154px);
157                 @include size(width, 300px);
158             }
159             margin-bottom: 0;
160
161             p {
162                 @include size(margin-top, 10px);
163                 @include size(margin-bottom, 10px);
164             }
165         }
166
167         .right-column {
168             @include size(margin-top, 16px);
169             // Eat the padding
170             @include size(margin-left, -10px);
171             @include size(margin-right, -10px);
172             max-width: none;
173
174             @media screen and (min-width: 62.5em) {
175                 @include size(width, 415px);
176                 // Eat the padding
177                 @include size(margin-top, -8px);
178             }
179
180             .other-tools,
181             .other-download {
182                 @include size(font-size, 11px);
183                 clear: left;
184                 @include size(margin-top, 25px);
185                 line-height: 1.75em;
186                 @include size(margin-left, 15px);
187
188                 h2 {
189                     margin: 0;
190                     @include size(font-size, 11px);
191                     @include mono;
192                 }
193
194                 @include min-screen($S_BOOK_SHORT_FULL) {
195                     float: left;
196                     clear: none;
197                     @include size(width, 145px);
198                     @include size(margin-top, 50px);
199                     @include size(margin-right, 0);
200                     @include size(margin-bottom, 0);
201                     @include size(margin-left, 5px);
202                 }
203
204                 @include min-screen(1000px) {
205                     @include size(margin-top, 50px);
206                     line-height: 1.2em;
207                 }
208             }
209             .other-download {
210                 @include min-screen($S_BOOK_SHORT_FULL) {
211                     @include size(margin-left, 15px);
212                     @include size(width, 220px);
213                 }
214             }
215         }
216     }
217 }
218
219 /* FIXME: RWD */
220 .picture.book-wide-box .right-column {
221     float: none;
222     @include size(width, 415px);
223     top: 0;
224     @include size(margin-left, 550px);
225     margin-top: 0em;
226 }
227
228
229 .book-box-body {
230     @include size(margin-bottom, 10px);
231     @include min-screen($S_BOOK_SHORT_FULL) {
232         margin-bottom: 0;
233         @include size(height, 170px);
234     }
235     position: relative;
236
237     .book-box-head,
238     .tags,
239     .book-box-tools {
240         @include min-screen($S_BOOK_SHORT_FULL) {
241             margin-left: 154px;
242         }
243     }
244
245     .book-box-head {
246         @include size(padding-top, 14px);
247         @include size(margin-bottom, 10px);
248
249         @include min-screen($S_BOOK_SHORT_FULL) {
250             @include size(min-height, 70px);
251         }
252
253         a {
254             color: black;
255         }
256         .author {
257             @include size(font-size, 11px);
258             @include mono;
259             @include size(line-height, 13.2px);
260             @include size(max-height, 26.4px);
261             overflow: hidden;
262
263             @include min-screen($S_BOOK_SHORT_FULL) {
264                 @include size(max-width, 264px);
265             }
266         }
267         .title {
268             @include size(font-size, 24px);
269             line-height: 1.2em;
270             @include size(margin-top, 7.2px);
271             @include size(margin-bottom, 12px);
272
273             @include min-screen($S_BOOK_SHORT_FULL) {
274                 margin-bottom: 0;
275                 @include size(height, 57.6px);
276                 overflow: hidden;
277             }
278         }
279     }
280
281     .tags {
282         @include size(font-size, 11px);
283         line-height: 1.2em;
284
285         @include min-screen($S_BOOK_SHORT_FULL) {
286             clear: right;
287             @include size(max-height, 57.6px);
288             overflow: hidden;
289         }
290
291         .category {
292             display: block;
293             @include size(margin-top, 6px);
294             @include size(margin-bottom, 6px);
295
296             @include min-screen($S_BOOK_SHORT_FULL) {
297                 display: inline;
298             }
299
300             .mono {
301                 @include mono;
302             }
303
304             .book-box-tag {
305                 @include size(margin-left, 4.4px);
306                 @include size(margin-right, 5.5px);
307             }
308         }
309     }
310
311 }
312
313
314
315 .book-box-tools {
316     @include size(font-size, 11px);
317     margin: 0;
318     padding: 0;
319     list-style: none;
320
321     clear: left;
322
323     @include min-screen($S_BOOK_SHORT_MEDIUM) {
324         clear: none;
325         @include size(margin-left, 139px + 15px);
326     }
327
328     li {
329         @include mono;
330         margin-top: 1em;
331
332         @include min-screen($S_BOOK_SHORT_FULL) {
333             display: inline-block;
334             margin-top: 0;
335         }
336     }
337
338     .book-box-read {
339         @include min-screen($S_BOOK_SHORT_FULL) {
340             @include size(width, 126.5px);
341         }
342
343         a {
344             @include mono;
345         }
346
347         a:before {
348             content: url("/static/img/read.png");
349             @include size(font-size, 25px);
350             @include size(margin-right, 3.71px);
351             vertical-align: middle;
352             font-weight: normal;
353         }
354     }
355
356     .book-box-download {
357         position: relative;
358
359         @include min-screen($S_BOOK_SHORT_FULL) {
360             @include size(width, 93.5px);
361         }
362
363         a {
364             position: relative;
365             z-index: 101;
366
367             &.downarrow {
368                 color: black;
369
370                 @include min-screen($S_BOOK_SHORT_FULL) {
371                     color: #0D7E85;
372
373                     &:before {
374                         content: url("/static/img/download.png");
375                         @include size(font-size, 25px);
376                         @include size(margin-right, 3.71px);
377                         vertical-align: middle;
378                         font-weight: normal;
379                     }
380                 }
381             }
382         }
383
384         .book-box-formats {
385             @include size(padding-left, 19px);
386
387             @include min-screen($S_BOOK_SHORT_FULL) {
388                 display: none;
389                 position: absolute;
390
391                 @include size(width, 180px);
392                 @include size(padding-top, 38px);
393                 @include size(padding-bottom, 9px);
394                 @include size(padding-left, 19px);
395                 @include size(padding-right, 19px);
396
397                 @include white-box;
398
399                 z-index: 100;
400
401                 @include size(top, -16px);
402                 @include size(left, -19px);
403             }
404
405             span {
406                 display: block;
407                 @include size(margin-top, 16px);
408
409                 a {
410                     &:before {
411                         content: url("/static/img/download.png");
412                         @include size(font-size, 25px);
413                         @include size(margin-right, 3.71px);
414                         vertical-align: middle;
415                         font-weight: normal;
416                     }
417                 }
418
419                 @include min-screen($S_BOOK_SHORT_FULL) {
420                     @include size(margin-top, 0);
421
422                     &:first-child {
423                         @include size(margin-top, 16px);
424                     }
425                     a:before {
426                         display:none;
427                     }
428                 }
429             }
430         }
431
432         &:hover .book-box-formats,
433         &.hover .book-box-formats {
434             display: block;
435         }
436     }
437
438     .book-box-audiobook {
439         @include min-screen($S_BOOK_SHORT_FULL) {
440             @include size(width, 77px);
441         }
442
443         a:before {
444             content: url("/static/img/listen.png");
445             @include size(font-size, 25px);
446             @include size(margin-right, 3.71px);
447             vertical-align: middle;
448             font-weight: normal;
449         }
450
451     }
452 }
453
454
455
456
457 .star {
458     @include size(font-size, 22.5px);
459     @include size(margin-right, 11.25px);
460     position: absolute;
461     right: 0;
462
463     button::-moz-focus-inner {
464         padding: 0;
465         border: 0
466     }
467     .if-unlike button {
468         font-size: 1em;
469         font-family: inherit;
470         border: 0;
471         background: none;
472         margin: 0;
473         padding: 0;
474         color: #757575;
475     }
476     .if-like a {
477         display:block;
478         text-align:right;
479         padding: 0;
480     }
481 }
482 .like .if-unlike {
483     display: none;
484 }
485 .unlike .if-like {
486     display: none;
487 }
488
489
490 #book-detail .see-also {
491     h1 {
492         @include size(height, 32px);
493         margin: 0;
494         @include size(padding-top, 19px);
495         @include size(padding-left, 10px);
496
497         @include size(font-size, 11px);
498         @include mono;
499         font-weight: normal;
500
501         @media screen and (min-width: 33em) {
502             @include size(padding-left, 19px);
503         }
504     }
505 }