Fixed input prepend and append
[bootswatch] / flatly / bootswatch.less
1 // Flatness by Jenil (www.jgog.in)
2 // Bootswatch 2.3.2
3 // -----------------------------------------------------
4
5
6 // TYPOGRAPHY
7 // --------------------------------------------------
8
9 @import url("http://fonts.googleapis.com/css?family=Lato:400,700,900,400italic");
10
11 h1 {
12         font-size: 48px;
13         font-weight: 900;
14 }
15
16 h2 {
17         font-size: 36px;
18         font-weight: 700;
19 }
20
21 h3 {
22         font-size: 28px;
23         font-weight: 700;
24 }
25
26 h4 {
27         font-size: 24px;
28         font-weight: 500;
29 }
30
31 h5 {
32         font-size: 16px;
33         font-weight: 500;
34 }
35
36 h6 {
37         font-size: 13px;
38         font-weight: 500;
39         text-transform: none;
40 }
41
42 p {
43         margin-bottom: 1em;
44 }
45
46 // SCAFFOLDING
47 // --------------------------------------------------
48
49 .page-header {
50         border-bottom: none;
51 }
52
53
54 // NAVBAR
55 // --------------------------------------------------
56
57 .navbar {
58
59         .brand {
60
61                 text-shadow: none;
62
63                 &:hover {
64                         color: @linkColorHover;
65                 }
66         }
67
68         .navbar-inner {
69                 .box-shadow(none);
70         }
71
72         .nav > li > a {
73                 text-shadow: none;
74         }
75
76         .nav > .active > a,
77         .nav > .active > a:hover,
78         .nav > .active > a:focus {
79                 .box-shadow(none);
80         }
81
82         .navbar-search .search-query {
83                 border: none;
84                 .box-shadow(none);
85                 line-height: normal;
86         }
87
88         .btn-navbar {
89                 background-image: none;
90                 .box-shadow(none);
91         }
92
93         .btn, .btn-group {
94                 margin-top: 6px;
95         }
96
97         &-inverse {
98
99                 .brand:hover {
100                         color: @blueDark;
101                 }
102
103                 .navbar-search .search-query {
104                         border-color: transparent;
105                         .box-shadow(none);
106                         line-height: normal;
107                         color: @textColor;
108
109                         &:focus {               
110                                 padding: 4px 14px;
111                                 color: @textColor;
112                         }
113                 }
114         }
115 }
116
117 div.subnav {
118
119         border-color: transparent;
120         background-image: none;
121         background-color: @grayLighter;
122         .box-shadow(none);
123
124         &-fixed {
125                 top: @navbarHeight;
126         }
127
128         .nav > li > a {
129                 border-color: transparent;
130                 .box-shadow(none);
131                 color: @textColor;
132         }
133
134         .nav > .active > a,
135         .nav > .active > a:hover {
136                 border-color: transparent;
137                 background-color: darken(@grayLighter, 10%);
138                 .box-shadow(none);
139                 color: @textColor;
140         }
141 }
142
143 // NAVIGATION
144 // --------------------------------------------------
145
146 .nav-list {
147
148         & > li > a,
149         & > .active > a,
150         .nav-header {
151                 text-shadow: none;
152         }
153
154         .divider {
155                 background: none;
156                 border-bottom: 2px solid @dropdownDividerBottom;
157         }
158 }
159
160 .nav-pills {
161
162         .open .dropdown-toggle {
163                 background-color: @blueDark;
164         }
165 }
166
167 .pagination {
168
169         ul {
170
171                 .box-shadow(none);
172
173                 & > li > a {
174                         background-color: @green;
175                         border-color: transparent;
176                         color: @white;
177
178                         &:hover {
179                                 background-color: lighten(@green, 10%);
180                         }
181                 }
182
183                 & > .active > a,
184                 & > .active > a:hover {
185                         background-color: @paginationActiveBackground;
186                         color: @textColor;
187                 }
188
189                 & > .disabled > a,
190                 & > .disabled > a:hover {
191                         background-color: lighten(@green, 10%);
192                         color: @white;
193                 }
194         }
195 }
196
197 .pager {
198
199         li > a,
200         li > span {
201                 background-color: @green;
202                 border: none;
203                 color: @white;
204
205                 &:hover {
206                         background-color: lighten(@green, 10%);
207                 }
208         }
209
210         .disabled > a,
211         .disabled > span,
212         .disabled > a:hover,
213         .disabled > span:hover {
214                 background-color: lighten(@green, 10%);
215                 color: @white;
216         }
217 }
218
219 .breadcrumb {
220
221         & > li {
222                 text-shadow: none;
223         }
224 }
225
226 // BUTTONS
227 // --------------------------------------------------
228
229 .btn {
230         padding: 9px 20px;
231         border: none;
232         background-image: none;
233         color: @white;
234         text-decoration: none;
235         text-shadow: none;
236         .box-shadow(none);
237         -webkit-transition: 0.25s;
238         -moz-transition: 0.25s;
239         transition: 0.25s;
240
241         &:hover,
242         &:focus {
243                 color: white;
244                 -webkit-transition: 0.25s;
245                 -moz-transition: 0.25s;
246                 transition: 0.25s;
247         }
248
249         &:active,
250         &.active {
251                 .box-shadow(none);
252                 color: rgba(255, 255, 255, 0.75);
253         }
254
255         &.disabled,
256         &[disabled] {
257                 color: white;
258         }
259
260         &-large {
261                 padding: @paddingLarge;
262         }
263
264         &-small {
265                 padding: @paddingSmall;
266         }
267
268         &-mini {
269                 padding: @paddingMini;
270         }
271 }
272
273 // TABLES
274 // -----------------------------------------------------
275
276
277
278 // FORMS
279 // --------------------------------------------------
280
281 textarea,
282 input[type="text"],
283 input[type="password"],
284 input[type="datetime"],
285 input[type="datetime-local"],
286 input[type="date"],
287 input[type="month"],
288 input[type="time"],
289 input[type="week"],
290 input[type="number"],
291 input[type="email"],
292 input[type="url"],
293 input[type="search"],
294 input[type="tel"],
295 input[type="color"],
296 .uneditable-input {
297         padding: 7px 6px;
298         border: 2px solid #dce4ec;
299         text-indent: 1px;
300         .border-radius(@inputBorderRadius);
301         .box-shadow(none);
302         .placeholder(#acb6c0);
303
304         &:focus {
305                 border-color: #1abc9c;
306                 .box-shadow(none);
307
308         }
309 }
310
311 .input-prepend {
312
313   .add-on:first-child,
314   .btn:first-child {
315     .border-radius(@inputBorderRadius 0 0 @inputBorderRadius);
316   }
317 }
318
319 .input-append {
320
321   input,
322   select,
323   .uneditable-input {
324
325     .border-radius(@inputBorderRadius 0 0 @inputBorderRadius);
326
327     + .btn-group .btn:last-child {
328       .border-radius(0 @inputBorderRadius @inputBorderRadius 0);
329     }
330   }
331
332   .add-on:last-child,
333   .btn:last-child,
334   .btn-group:last-child > .dropdown-toggle {
335     .border-radius(0 @inputBorderRadius @inputBorderRadius 0);
336   }
337 }
338
339 .input-prepend,
340 .input-append {
341
342   input,
343   select,
344   .uneditable-input {
345     .border-radius(0);
346     + .btn-group .btn {
347       .border-radius(0 @inputBorderRadius @inputBorderRadius 0);
348     }
349   }
350
351   .add-on:first-child,
352   .btn:first-child {
353     .border-radius(@inputBorderRadius 0 0 @inputBorderRadius);
354   }
355
356   .add-on:last-child,
357   .btn:last-child {
358     .border-radius(0 @inputBorderRadius @inputBorderRadius 0);
359   }
360 }
361
362 .input-append,
363 .input-prepend {
364
365         .add-on {
366                 padding: 9px 5px;
367                 text-shadow: none;
368                 border: none;
369         }
370 }
371
372 .control-group.error,
373 .control-group.error input:focus,
374 .control-group.error textarea:focus {
375                 border-color: #e74c3c;
376                 .box-shadow(none);
377 }
378
379 .control-group.success,
380 .control-group.success input:focus,
381 .control-group.success textarea:focus {
382                 border-color: #2ecc71;
383                 .box-shadow(none);
384 }
385
386 .control-group.warning,
387 .control-group.warning input:focus,
388 .control-group.warning textarea:focus {
389                 border-color: #f1c40f;
390                 .box-shadow(none);
391 }
392
393 .control-group.info,
394 .control-group.info input:focus,
395 .control-group.info textarea:focus {
396                 border-color: #3498db;
397                 .box-shadow(none);
398 }
399
400 input[disabled],
401 input[readonly],
402 textarea[disabled],
403 textarea[readonly] {
404         background-color: #eaeded;
405         border-color: transparent;
406         color: #cad2d3;
407         cursor: default;
408 }
409
410 input[type="file"]{
411         line-height: 16px;
412 }
413
414 legend {
415         border-bottom: none;
416         color: @textColor;
417 }
418
419 .form-actions {
420         border-top: none;
421         .border-radius(@baseBorderRadius);
422         background-color: darken(@grayLighter, 5%);
423 }
424
425 // DROPDOWNS
426 // --------------------------------------------------
427
428
429 // ALERTS, LABELS, BADGES
430 // --------------------------------------------------
431
432 .alert {
433         background-color: @orange;
434         color: @white;
435         text-shadow: none;
436
437         h1, h2, h3, h4, h5, h6 {
438                 color: @white;
439         }
440
441         &-error {
442                 background-color: @red;
443         }
444
445         &-success {
446                 background-color: @green;
447         }
448
449         &-info {
450                 background-color: @blue;
451         }
452 }
453
454 .label {
455         padding: 6px 10px;
456         text-shadow: none;
457 }
458
459 .badge {
460         padding: 6px 10px;
461         .border-radius(@borderRadiusLarge);
462         text-shadow: none;
463 }
464
465
466 // MISC
467 // --------------------------------------------------
468
469 .well {
470         border: none;
471         .box-shadow(none);
472
473 }
474
475 .progress {
476
477         background: @grayLighter;
478         border-radius: 32px;
479         height: 12px;
480         .box-shadow(none);
481
482         .bar {
483                 background-color: @blueDark;
484                 background-image: none;
485                 .box-shadow(none);
486         }
487
488         .bar + .bar {
489                 .box-shadow(none);
490         }
491
492         &-striped .bar {
493                 #gradient > .striped(@blueDark);
494         }
495
496         &-success .bar,
497         &-success.progress-striped .bar,
498         .bar-success {
499                 background-color: @green;
500         }
501
502         &-warning .bar,
503         &-warning.progress-striped .bar,
504         .bar-warning {
505                 background-color: @yellow;
506         }
507
508         &-danger .bar,
509         &-danger.progress-striped .bar,
510         .bar-danger {
511                 background-color: @red;
512         }
513
514         &-info .bar,
515         &-info.progress-striped .bar,
516         .bar-info {
517                 background-color: @blue;
518         }
519 }
520
521 .tooltip {
522
523         &.in {
524                 opacity: 1;
525         }
526 }
527
528 .popover {
529         color: @white;
530
531         &-title {
532                 border-bottom: 2px solid @dropdownDividerBottom;
533         }
534 }
535
536 .modal {
537
538         &-header {
539                 background-color: @navbarBackground;
540                 border-bottom: none;
541                 color: @white;
542         }
543
544         &-footer {
545                 background-color: @grayLighter;
546                 border-top: none;
547                 .box-shadow(none);
548         }
549 }
550
551 .close {
552         text-shadow: none;
553 }
554
555 // MEDIA QUERIES
556 // --------------------------------------------------
557
558 @media (max-width: 767px) {
559         
560         div.subnav {
561
562                 .nav > li:first-child > a,
563                 .nav > li + li > a {
564                         border-color: transparent;
565
566                         &:hover {
567                                 background-color: darken(@grayLighter, 10%);
568                         }
569                 }
570                 
571                 .nav > li:last-child > a {
572                         border-radius: 0 0 4px 4px;
573                 }
574         }
575
576         .input-append,
577         .input-prepend {
578
579                 .add-on,.btn {
580                         padding: 5px;
581                 }
582         }
583 }
584
585 @media (max-width: 979px) {
586
587         .navbar {
588
589                 .nav-collapse .nav > li > a {
590                         color: @white;
591
592                         &:hover {
593                                 background-color: @green;
594                         }
595                 }
596
597         }
598 }