]> git.openstreetmap.org Git - rails.git/blob - app/assets/stylesheets/common.css.scss
8322a66a35b3f63d69eafaa9a4944cb03270f67b
[rails.git] / app / assets / stylesheets / common.css.scss
1 /* Parameters */
2 $lineheight: 20px;
3 $typeheight: 14px;
4
5 $offwhite: #f4f4ff;
6 $blue: #7092FF;
7 $lightblue: #B8C5F0;
8 $grey: #AAA;
9 $keyline: #CCC;
10 $hovercolor: 20%;
11
12 /* Styles common to large and small screens */
13
14 /* Minimal CSS reset */
15
16 html, body, ul, ol, li, form, fieldset, legend, h1, h2, h3, h4, h5, h6, p, input {
17   margin: 0;
18   padding: 0;
19   border: 0;
20   font-size:100%;
21 }
22
23 fieldset,img { border: 0; }
24
25 legend { color: #000; }
26
27 sup { vertical-align: text-top; }
28
29 sub { vertical-align: text-bottom; }
30
31 table {
32   border-collapse: collapse;
33   border-spacing: 0;
34 }
35
36 li { list-style: none; }
37
38 input,
39 select,
40 textarea,
41 body { font: #{$typeheight}/#{$lineheight} "Helvetica Neue",Arial,sans-serif; }
42
43 abbr, acronym {
44   border-bottom: .1em dotted;
45   cursor: help;
46 }
47
48 /* Micro Clearfix | Details: http://nicolasgallagher.com/micro-clearfix-hack/ */
49
50 .clearfix:before,
51 .clearfix:after {
52     content: " ";
53     display: table;
54 }
55
56 .clearfix:after {
57     clear: both;
58 }
59
60 /* Default rules for the body of every page */
61
62 * {
63   -moz-box-sizing: border-box;
64   -webkit-box-sizing: border-box;
65   box-sizing: border-box;
66 }
67
68 body {
69   font-family: 'Helvetica Neue',Arial,sans-serif;
70   font-size: $typeheight;
71   line-height: 1.6666;
72   color: #222;
73   background-color: #fff;
74   margin: 0px;
75   padding: 0px;
76   text-align: left;
77 }
78
79 body.slim {
80   background-color: #f0f0f0;
81 }
82
83 h1, h2, h3 {
84   margin-top: $lineheight/2;
85   margin-bottom: $lineheight;
86   font-weight: bold;
87   line-height: 1.2;
88 }
89
90 h1, h2 {
91   font-size: 32px;
92 }
93
94 #content h2 {
95   font-size: 21px;
96 }
97
98 h3 {
99   font-size: 21px;
100   margin-top: $lineheight/2;
101   margin-bottom: $lineheight;
102 }
103
104 h4,h5,h6 {
105   font-size: $typeheight;
106   margin-top: $lineheight/2;
107   margin-bottom: $lineheight/2;
108   font-weight: bold;
109   line-height: 1.5;
110 }
111
112 p, ul {
113   margin-bottom: $lineheight;
114 }
115
116 p > img {
117   width: auto;
118   max-width: 100%;
119 }
120
121 small, aside {
122   font-size: 12px;
123 }
124
125 h1:first-child,
126 h2:first-child,
127 h3:first-child,
128 h4:first-child,
129 h5:first-child,
130 h6:first-child {
131   margin-top: 0;
132 }
133
134 .column-1 {
135   width: 50%;
136   margin: 0 0 $lineheight/2 0;
137 }
138
139 .small_icon {
140   vertical-align: middle;
141   margin-right: $lineheight/4;
142 }
143
144 /* Rules for links */
145
146 a {
147   color: #00f;
148   text-decoration: none;
149   &:hover {
150     text-decoration: underline;
151   }
152 }
153
154 /* Rules for horizontal lines */
155
156 hr {
157   border: none;
158   background-color: #ccc;
159   color: #ccc;
160   height: 1px;
161 }
162
163 /* General styles for tables */
164
165 table {
166   width: 100%;
167   margin-bottom: $lineheight;
168   th, td {
169     text-align: left;
170     padding: $lineheight/4;
171     line-height: $lineheight;
172   }
173   th {
174     font-weight: bold;
175     vertical-align: top;
176   }
177   td {
178     vertical-align: middle;
179   }
180 }
181
182 /* Rules for the whole left sidebar, including the logo */
183
184 #left {
185   position: absolute;
186   height: 100%;
187   width: 185px;
188   font-size: 11px;
189   line-height: 1.1;
190   z-index: 100;
191   border-right: 1px solid #ccc;
192 }
193
194 /* Rules for the OpenStreetMap logo in the top left corner */
195
196 #logo {
197   display: block;
198   width: 170px;
199   min-width: 170px;
200   padding: $lineheight $lineheight/4;
201   text-align: center;
202   margin: auto;
203 }
204
205 #logo h1 {
206   font-size: 18px;
207   line-height: 1;
208   text-align: center;
209   margin: 0;
210 }
211
212 #logo h2 {
213   font-size: $lineheight/2;
214   line-height: 15px;
215   margin: 0;
216 }
217
218 /* Rules for the site name */
219
220 #small-title {
221   display: none;
222 }
223
224 /* Rules for the introductory text displayed in the left sidebar to new users */
225
226 .sidebar-copy {
227   padding: $lineheight/4 $lineheight/2;
228   p {
229     margin: $lineheight/4 0;
230   }
231 }
232 .sidebar-copy.intro {
233   border-top: 1px solid #ccc;
234 }
235
236 /*
237  * Rules for alert boxes shown in the left sidebar when important
238  * information needs to be conveyed such as when the site is
239  * undergoing maintenance.
240  */
241
242 .sidebar-alert {
243   padding: $lineheight/4;
244   border-top: 1px solid #ccc;
245   margin-top: 4px;
246   margin-bottom: -5px;
247   background: #e00;
248   font-size: 12px;
249   font-weight: bold;
250   p {
251     margin: $lineheight/4;
252   }
253 }
254
255 /*
256  * Rules for notice boxes shown in the left sidebar when important, but
257  * non-critical information needs to be conveyed such as notices about
258  * donation drives.
259  */
260
261 .sidebar-notice {
262   padding: $lineheight/4;
263   border-top: 1px solid #ccc;
264   margin-top: 4px;
265   margin-bottom: -5px;
266   background: #ea0;
267   font-size: 12px;
268   p {
269     margin: $lineheight/4;
270   }
271 }
272
273 /* Rules for the menu displayed in the left sidebar */
274
275 .left_menu {
276   left: 0px;
277   margin: 0;
278   padding: $lineheight/4 $lineheight/2;
279   font-size: 12px;
280   line-height: 1.25;
281   list-style-type: none;
282   border-bottom: 1px solid #ccc;
283   border-top: 1px solid #ccc;
284   img {
285     margin: $lineheight/2 0px;
286   }
287
288   ul {
289     padding: 0;
290     margin: 0;
291   }
292
293   li {
294     list-style-type: none;
295     padding: 0;
296     margin: 0;
297   }
298
299   h4 {
300     padding: $lineheight/4 0 $lineheight/4 0;
301     font-size: 12px;
302     margin: 0;
303   }
304
305   li:last-child h4 {
306     padding-top: 0;
307   }
308 }
309
310 /* Rules for SOTM advert */
311
312 #sotm {
313   width: 165px;
314   margin: $lineheight/2;
315   padding: 0px;
316   border: 0px;
317   background: #fff;
318   img {
319     width: 165px;
320   }
321 }
322
323 /*
324  * Rules for "optional boxes" which appear in the left sidebar on
325  * certain pages. Current users are the seach box on the main page
326  * and the tag cloud on the traces pages.
327  */
328
329 .optionalbox {
330   left: 0px;
331   padding: $lineheight/4 $lineheight/2;
332   margin: $lineheight/4 0;
333   text-align: left;
334 }
335
336 /* Rules for the search box */
337
338 #search_field {
339   position: relative;
340
341   form {
342     width: 165px;
343   }
344
345   input[type="text"] {
346     width: 165px;
347     padding: 3px;
348     font-size: $typeheight;
349     line-height: 1.1;
350     height: 25px;
351     padding: 2px 0px 2px $lineheight/4;
352     box-shadow: inset #DDD 0px 1px 3px;
353   }
354
355   input[type="text"]:focus {
356     outline: none;
357     border: 1px solid #000;
358   }
359
360   input[type="submit"] {
361     border: 0;
362     margin: 0;
363     padding: 0;
364     width: 15px;
365     height: 15px;
366     min-width: 0;
367     text-indent: -1000px;
368     overflow: hidden;
369     background: image-url("sprite.png") 0 0 no-repeat;
370     position: absolute;
371     top: $lineheight/4;
372     right: $lineheight/4;
373     cursor: pointer;
374   }
375 }
376
377 .search_help {
378   margin: $lineheight/4 0 0 0;
379 }
380
381 /* Utility for de-emphasizing content */
382
383 .deemphasize {
384   color: #999;
385   a {
386     color: $blue;
387   }
388 }
389
390 /* Rules for donation request box */
391
392 .donate {
393   display: block;
394   width: 163px;
395   padding: $lineheight/4;
396   border: 1px solid #AED1A0;
397   background: #cbeea7;
398   font-size: $typeheight;
399   line-height: 1.4;
400   text-align: center;
401   border-radius: 2px;
402   color: #222;
403   margin: $lineheight/2 $lineheight/2 0px $lineheight/2;
404
405   &:hover {
406     background: #9ed485;
407     text-decoration: none;
408   }
409   span {
410     margin: 0;
411     padding-left: 18px;
412     background: image-url("sprite.png") 0 -29px no-repeat;
413   }
414 }
415
416 /* Rules for Creative Commons logo button */
417
418 #cclogo {
419   margin: $lineheight/2 0;
420   float: right;
421 }
422
423 /* Rules for tabbed navigation bar */
424
425 #top-bar {
426   position: relative;
427   margin-left: 185px;
428   height: 30px;
429   border-bottom: 1px solid #ccc;
430   background: white;
431   z-index: 100;
432 }
433
434 .site-edit #top-bar,
435 .site-index #top-bar,
436 .site-export #top-bar {
437   position: fixed;
438   left: 0;
439   right: 0;
440 }
441
442 #tabnav {
443   height: 29px;
444   margin-bottom:0;
445   overflow: hidden;
446   li {
447     display: inline;
448   }
449   a, a:link, a:visited {
450     float: left;
451     font-weight: bold;
452     padding: 3px $lineheight/2;
453     text-decoration: none;
454     color: #333;
455     float: left;
456     margin-right: 1px;
457     -webkit-transition: color 200ms ease-in;
458        -moz-transition: color 200ms ease-in;
459          -o-transition: color 200ms ease-in;
460             transition: color 200ms ease-in;
461   }
462 }
463
464 .site-index #tabnav a#viewanchor,
465 .site-edit #tabnav a#editanchor,
466 .changeset-list #tabnav a#historyanchor,
467 .site-export #tabnav a#exportanchor {
468   border-bottom: 1px solid #aaa;
469   background: #9ed485;
470   color: #000;
471 }
472
473 #tabnav a:link:hover, #tabnav a:visited:hover {
474   text-decoration: underline;
475 }
476
477 #tabnav a:link.disabled,
478 #tabnav a:visited.disabled,
479 #tabnav a:link:hover.disabled,
480 #tabnav a:visited:hover.disabled {
481   color: #ccc;
482   cursor: default;
483   &:hover {
484     text-decoration: none;
485   }
486 }
487
488 /* Utility for styling notification numbers */
489
490 .count-number {
491   padding: 2px $lineheight/4;
492   border-radius: 2px;
493   background: #d7d7ff;
494   margin: 0 2px;
495   font-size: 11px;
496   color: #333;
497 }
498
499 /* Rules for greeting bar in the top right corner */
500
501 #greeting {
502   float: right;
503   padding-top: 3px;
504   margin-right: $lineheight/4;
505 }
506
507 .greeting-bar-unread {
508   font-weight: bold;
509 }
510
511 /* Rules for the message shown in place of the map when javascript is disabled */
512
513 #noscript {
514   z-index: 20000000;
515   position: absolute;
516   top: 15px;
517   left: 15px;
518 }
519
520 /* Rules for Leaflet maps */
521 .leaflet-control-layers-expanded {
522   padding: 10px !important;
523 }
524
525 .leaflet-control-layers-separator {
526   margin: 5px -10px !important;
527 }
528
529 .leaflet-control-attribution {
530   a.disabled {
531     color: #99c9dc;
532     cursor: default;
533     text-decoration: none;
534   }
535
536   ul.secondary-actions {
537     float: left;
538     margin-right: $lineheight/4;
539
540     &:only-child {
541       margin-right: 0px;
542     }
543   }
544 }
545
546 .site-index .leaflet-top,
547 .site-export .leaflet-top {
548   top: $lineheight/2 !important;
549   .leaflet-control {
550     margin-top: 0px !important;
551   }
552 }
553
554 .site-index #map .olControlScaleLine,
555 .site-export #map .olControlScaleLine {
556   left: $lineheight/2 !important;
557 }
558
559 .leaflet-popup-scrolled {
560   padding-right: $lineheight;
561   border-bottom: 0px !important;
562   border-top: 0px !important;
563 }
564
565 .leaflet-popup-content-wrapper {
566   border-radius: 4px !important;
567   -webkit-border-radius: 4px !important;
568 }
569
570 /* Rules for edit menu */
571
572 .menuicon {
573   padding: 0 $lineheight/4;
574   font-weight: normal;
575   display: inline-block;
576   &:hover {
577     text-decoration: none !important;
578   }
579 }
580
581 .menu {
582   display: none;
583   z-index: 10000;
584   position: absolute;
585   background-color: #ffffff;
586   border: 1px solid $keyline;
587   border-top: 0px;
588   ul {
589     margin: 0px;
590   }
591   li {
592     padding: 2px $lineheight/4;
593     border-top: 1px solid #eee;
594     white-space: nowrap;
595   }
596 }
597
598 /* Rules for attribution text under the main map shown on printouts */
599
600 #attribution {
601   display: none;
602 }
603
604 .attribution_license,
605 .attribution_project {
606   text-align: left;
607 }
608
609 .attribution_notice {
610   text-align: center;
611 }
612
613 /* Rules for the popout map sidebar */
614
615 #sidebar {
616   display: none;
617   position: absolute;
618   overflow: auto;
619   top: 0px;
620   bottom: 0px;
621   left: 0px;
622   border-right: 1px solid $keyline;
623   width: 33.3333%;
624   .sidebar_heading {
625     position: relative;
626     padding: $lineheight/2 $lineheight;
627     z-index: 9999;
628     background: $offwhite;
629     border-bottom: 1px solid #ccc;
630   }
631   h4 {
632     margin: 0;
633   }
634   ul {
635     margin-bottom: 0;
636     &:last-child {
637         border-bottom: 1px solid #ccc;
638     }
639     li {
640       margin-bottom: $lineheight/4;
641       &:last-child {
642         margin-bottom: 0;
643       }
644     }
645   }
646 }
647
648 #sidebar_close {
649   position: absolute;
650   height: $lineheight;
651   top: 0px;
652   bottom: 0;
653   right: $lineheight;
654   margin: auto;
655 }
656
657 #sidebar_content {
658   position: relative;
659   margin-bottom: 20px;
660   width: 100%;
661   h4 {
662     padding: 0 $lineheight $lineheight/2 $lineheight;
663     margin-top: $lineheight/2;
664     margin-bottom: 0;
665     border-bottom: 1px solid #ddd;
666   }
667 }
668
669 /* Rules for the map key which appears in the popout sidebar */
670
671 #mapkey {
672   padding: $lineheight $lineheight 0 $lineheight;
673  .mapkey-table-key img {
674     display: block;
675     margin-left: auto;
676     margin-right: auto;
677   }
678   td {
679     padding: 0 $lineheight/4 $lineheight/4 $lineheight/4;
680   }
681 }
682
683 /* Rules for search results which appear in the popout sidebar */
684
685 .search_searching {
686   margin-top: $lineheight/4;
687   margin-bottom: $lineheight/4;
688 }
689
690 .search_results_entry {
691   margin-bottom: 0;
692
693   .search_details {
694     display: block;
695     text-align: right;
696   }
697 }
698
699 .search_results_entry .search_searching {
700   text-align: center;
701   margin: $lineheight auto;
702   width: $lineheight;
703   display: block;
704 }
705
706 ul.results-list li { border-bottom: 1px solid #ccc; }
707
708 .search_results_error {
709   color: #f00;
710 }
711
712 /* Rules for data browser information which appears in the popout sidebar */
713
714 #browse_content {
715   position: relative;
716   .browse_show_list.button {
717     position: absolute;
718     left: $lineheight;
719     right: $lineheight;
720     bottom: -40px;
721     margin-bottom: 0;
722   }
723   a.more-details {
724     position: absolute;
725     top: 0;
726     right: $lineheight;
727   }
728   ul li {
729     margin-bottom: 0;
730   }
731 }
732
733 .browse_details {
734   position: relative;
735 }
736
737 .browse_status {
738   display: none;
739 }
740
741 /* Rules for export information which appears in the popout sidebar */
742
743 .export_bounds {
744   text-align: center;
745 }
746
747 .export_area_inputs {
748   margin-bottom: $lineheight/2;
749   input[type="text"] {
750     width: 60px;
751     margin-bottom: 5px;
752   }
753 }
754
755 .export_bound {
756   margin: $lineheight/4;
757 }
758
759 .export_details input[type="text"]#export_html_text {
760   width: 100%;
761 }
762
763 #sidebar #marker_inputs li:last-child {
764   margin-bottom: $lineheight/2;
765 }
766
767 #export_osm,
768 #export_mapnik,
769 #export_osmarender {
770   display: none;
771 }
772
773 /* Rules for the main content area */
774
775 #content {
776   padding: $lineheight;
777   position: relative;
778 }
779
780 .site-edit #content,
781 .site-index #content,
782 .site-export #content {
783   position: fixed;
784   padding: 0;
785   top: 30px; bottom: 0;
786   left: 184px; right: 0;
787   border-left: 1px solid #ccc;
788 }
789
790 .wrapper {
791   margin-left: 184px;
792   border-left: 1px solid #ccc;
793   text-align: left;
794 }
795
796 .site-edit #content {
797   top: 30px;
798 }
799
800 #content.maximised {
801   top: 0;
802   left: 0;
803   right: 0;
804   bottom: 0;
805   border: 0;
806   z-index: 1000;
807 }
808
809 #slim_container {
810   width: 100%;
811 }
812
813 #slim_container_content {
814   max-width: 50em;
815   background-color: #FFFFFF;
816   margin: $lineheight/2 auto;
817   padding: 3px;
818   border-radius: 25px;
819   -moz-border-radius: 25px;
820   border: 1px solid #e6e6e6;
821 }
822
823 #slim_content {
824   margin: $lineheight/2;
825   margin-top: 95px;
826   max-width: 50em;
827
828   .content-heading {
829     margin-bottom: 15px;
830   }
831 }
832
833 #slim_header {
834   margin: 30px $lineheight/2;
835   position: absolute;
836   top: 0px;
837   margin-right: $lineheight/4;
838   img {
839     vertical-align: middle;
840     margin-bottom: $lineheight/4;
841     margin-right: $lineheight/4;
842   }
843 }
844
845 .content-heading {
846   position: relative;
847   padding: $lineheight;
848   background: $offwhite;
849   h1, h2 {
850     margin-bottom: $lineheight/2;
851     line-height: 100%;
852     &:last-child {
853       margin-bottom: 0;
854     }
855   }
856   p {
857     margin-top: $lineheight/2;
858     margin-bottom: 0px;
859   }
860 }
861
862 /* Rules for small maps in content areas */
863
864 .content_map {
865   position: relative;
866   width: 45%;
867   height: 400px;
868   border: 1px solid #ccc;
869   margin-bottom: $lineheight;
870   float: right;
871 }
872
873 .content_map #small_map {
874   height: 100%;
875   width: 100%;
876   margin-bottom: $lineheight;
877 }
878
879 /* Rules for the home page */
880
881 .site-export #map,
882 .site-index #map {
883   position: absolute;
884   top: 0px;
885   bottom: 0px;
886   left: 0px;
887   right: 0px;
888 }
889
890 /* Rules for the edit page */
891
892 .site-edit #map {
893   position: absolute;
894   top: 0px;
895   bottom: 0px;
896   left: 0px;
897   right: 0px;
898   overflow: hidden;
899 }
900
901 /* Rules for the changeset list shown by the history tab etc */
902
903 #changeset_list {
904   width: 100%;
905   ul {
906     padding: $lineheight/2 0;
907     margin-bottom: 0px;
908     border-top: 1px solid #ccc;
909     &:last-child {
910       border-bottom: 1px solid #ccc;
911     }
912   }
913   .selected {
914     background: #FFFFC0;
915   }
916   .date,
917   .user {
918     border-left: 1px solid #ccc;
919     padding-left: $lineheight/4;
920     margin-right: $lineheight/4;
921   }
922 }
923
924 #changeset_list_map_wrapper {
925   position: absolute;
926   width: 50%;
927   height: 490px;
928   top: 0;
929   right: 0;
930 }
931
932 #changeset_list_map_wrapper.scrolled {
933   position: fixed;
934 }
935
936 #changeset_list_map {
937   position: absolute;
938   bottom: $lineheight;
939   top: $lineheight;
940   right: $lineheight;
941   left: $lineheight;
942   border: 1px solid #ccc;
943 }
944
945 #changeset_list_map_wrapper.scrolled #changeset_list_map {
946   margin-left: 93px;
947 }
948
949 /* Rules for the data browser */
950
951 .browse-section {
952   border-top: 1px solid #ccc;
953   margin-top: $lineheight/2;
954   padding-top: $lineheight/2;
955   &:first-child {
956     margin-top: 0;
957   }
958   .warning {
959     background-color: #ffe0cc;
960     margin: 0px;
961     padding: 4px 6px;
962     max-width: 100%;
963   }
964   h4, p {
965     margin-bottom: $lineheight/4;
966   }
967   p, ul, .bbox, .geo {
968     display: inline-block;
969     vertical-align: top;
970     max-width: 65%;
971   }
972   ul p {
973     margin-left: 0;
974     margin-bottom: 0;
975   }
976   h4 {
977     width: 33.3333%;
978     display: inline-block;
979     vertical-align: top;
980   }
981 }
982
983 .bbox {
984   div {
985     width: 33.3333%;
986     text-align: center;
987     padding: $lineheight/4 0;
988     overflow: hidden;
989     text-overflow: ellipsis;
990     float: left;
991   }
992   .max_lat,
993   .min_lat {
994     margin-left: auto;
995     margin-right: auto;
996     width: 100%;
997   }
998 }
999
1000 #browse_map .geolink {
1001   display: none;
1002 }
1003
1004 #browse_map .secondary-actions {
1005   margin-bottom: $lineheight/2;
1006 }
1007
1008 /* Rules for the trace list shown by the traces tab etc */
1009
1010 #trace_list {
1011   font-size: $lineheight/2;
1012   border-width: 0px;
1013   text-align: right;
1014
1015   .trace_summary {
1016     font-size: 12px;
1017     color: gray;
1018   }
1019
1020   .trace_pending {
1021     color: red;
1022   }
1023
1024   .trace_public {
1025     color: green;
1026   }
1027
1028   .trace_identifiable {
1029     color: green;
1030   }
1031
1032   .trace_trackable {
1033     color: red;
1034   }
1035
1036   .trace_private {
1037     color: red;
1038   }
1039 }
1040
1041 /* Rules for the user profile page */
1042
1043 #userinformation {
1044
1045   min-height: 100px;
1046   .userinformation-inner {
1047     float: left;
1048   }
1049   h2 {
1050     margin-top: 0;
1051   }
1052   .user-description {
1053     width: 100%;
1054     clear: both;
1055   }
1056   .deemphasize {
1057     margin: 0;
1058   }
1059 }
1060
1061 .admin-user-info small {
1062   margin-bottom: $lineheight/2;
1063   display: inline;
1064   margin-right: $lineheight;
1065 }
1066
1067 .activity-block {
1068   clear: left;
1069   border-bottom: 1px solid #ccc;
1070   padding-bottom: $lineheight;
1071   float: left;
1072   h3 {
1073     margin-bottom: $lineheight/2;
1074   }
1075 }
1076
1077 .contact-activity {
1078   margin-top: $lineheight;
1079   width: 100%;
1080 }
1081
1082 .activity-details p {
1083   margin-left: 70px;
1084   margin-bottom: 0;
1085 }
1086
1087 #friends-container .contact-activity ul {
1088   margin-left: 70px;
1089 }
1090
1091 .user-view {
1092   p#no_home_location {
1093     margin: $lineheight;
1094   }
1095   .user_thumbnail {
1096     margin-top: $lineheight/4;
1097     float: left;
1098   }
1099 }
1100
1101 /* Rules for the user map */
1102
1103 .content_map .leaflet-popup-content {
1104   margin: $lineheight/2;
1105   min-height: 50px;
1106 }
1107
1108 /* Rules for user popups on maps */
1109
1110 .user_popup {
1111   min-width: 200px;
1112   p {
1113     padding: 0 0 5px 0;
1114     margin-top: 0 0 0 60px;
1115     font-size: 12px;
1116   }
1117   img.user_thumbnail {
1118     float: left;
1119     margin: 0 $lineheight/2 0 0;
1120   }
1121 }
1122
1123 /* Rules for the user list */
1124
1125 #user_list {
1126   font-size: $lineheight/2;
1127   width: 100%;
1128
1129   tr {
1130     vertical-align: middle;
1131   }
1132
1133   p {
1134     margin-top: 0px;
1135     margin-bottom: 0px;
1136   }
1137 }
1138
1139 #user_list_actions {
1140   float: right;
1141   margin-top: $lineheight/2;
1142 }
1143
1144 /* Rules for the diary list page */
1145
1146 .diary_entry-list img.user_thumbnail {
1147   float: left;
1148 }
1149
1150 .diary_post {
1151   max-width: 740px;
1152   position: relative;
1153   margin-top: $lineheight/2;
1154   padding-top: $lineheight;
1155   border-top: 1px solid #ccc;
1156
1157   &:first-child {
1158     margin-top: 0;
1159     border-top: 0;
1160     padding-top: 0;
1161   }
1162   h1, h2 {
1163     font-size: 21px;
1164     line-height: 1;
1165   }
1166   small.deemphasize {
1167     float: left;
1168     display: block;
1169   }
1170   ul.secondary-actions { display: inline-block;}
1171 }
1172
1173 .content-heading .hide_unless_logged_in { // hacky selector, better to just add a new class to this div
1174   display: inline;
1175 }
1176
1177 #content  .post_heading {
1178   margin-bottom: $lineheight;
1179   h2 {
1180     margin-top: 0;
1181     margin-bottom: $lineheight/2;
1182     font-size: 24px;
1183   }
1184 }
1185
1186 /* Rules for the diary entry page */
1187
1188 .diary_entry {
1189   #map {
1190     position: relative;
1191     width: 90%;
1192     height: 400px;
1193     border: 1px solid #ccc;
1194     display: none;
1195     margin-bottom: $lineheight;
1196   }
1197   #newcomment {
1198     border-top: 1px solid #ccc;
1199     padding-top: $lineheight;
1200     margin-top: $lineheight/2;
1201   }
1202   .comments {
1203     max-width: 740px;
1204   }
1205   .diary-comment {
1206     margin-top: $lineheight/2;
1207     border-top: 1px dashed #ccc;
1208     padding-top: $lineheight/2;
1209     &:first-child {
1210       margin-top: $lineheight;
1211       padding-top: $lineheight;
1212       border-top: 1px solid #ccc;
1213     }
1214     p {
1215       margin-bottom: $lineheight/2;
1216     }
1217     .comment-heading {
1218       margin-bottom: 0;
1219       margin-top: 0;
1220     }
1221   }
1222 }
1223
1224 .diary_entry-view img.user_thumbnail {
1225   float: left;
1226 }
1227
1228 /* Rules for the login page */
1229
1230 #login_openid_buttons {
1231   margin-bottom: 0;
1232 }
1233
1234 #login_openid_buttons li {
1235   float: left;
1236   padding: $lineheight/4 $lineheight/2;
1237 }
1238
1239 /* Rules for the account confirmation page */
1240
1241 #terms {
1242   .legale {
1243     border: 1px solid #ccc;
1244     padding: $lineheight;
1245     margin-bottom: $lineheight;
1246     overflow: auto;
1247     height: 10em;
1248
1249     &:p#last {
1250       margin-bottom: 0px;
1251     }
1252
1253     &:ol {
1254       margin-bottom: 0px;
1255     }
1256
1257     &:img {
1258       display: block;
1259       margin: $lineheight auto inherit auto;
1260     }
1261   }
1262
1263   form.sign {
1264     input[type=submit] {
1265       float: left;
1266     }
1267     #decline {
1268       background: $grey;
1269       &:hover {
1270         background: darken($grey, $hovercolor);
1271       }
1272     }
1273   }
1274   fieldset {
1275     margin-bottom: $lineheight;
1276   }
1277   #contributorGuidance {
1278     background-color: $offwhite;
1279     border-radius: 4px;
1280     -moz-border-radius: 4px;
1281   }
1282   .signing-buttons {
1283     height: 50px;
1284   }
1285 }
1286
1287 /* Rules for the account settings page */
1288
1289 #accountForm .user_map {
1290   position: relative;
1291   width: 500px;
1292   height: 400px;
1293   border: 1px solid #ccc;
1294 }
1295
1296 #accountForm .user_image {
1297   margin-bottom: 0;
1298 }
1299
1300 #accountForm #user_image {
1301   margin-left: 20px;
1302 }
1303
1304 #accountForm ul.accountImage-options {
1305   margin-left: 120px;
1306 }
1307
1308 .nohome .location {
1309   display: none;
1310 }
1311
1312 #homerow .message {
1313   display: none;
1314 }
1315
1316 .nohome .message {
1317   display: inline !important;
1318 }
1319
1320 .content_map.settings_map {
1321   width: 50%;
1322   float: none;
1323 }
1324
1325 /* Rules for the oauth settings page */
1326
1327 .oauth_clients .buttons .oauth-edit {
1328   border-radius: 2px 0 0 2px;
1329 }
1330
1331 .oauth_clients .buttons .oauth-delete {
1332   border-radius: 0 2px 2px 0;
1333 }
1334
1335 /* Rules for messages pages */
1336
1337 .messages {
1338   width: 100%;
1339   border: 1px solid #ddd;
1340
1341   input[type="submit"] {
1342     margin: auto;
1343   }
1344   tbody tr {
1345     border-top: 1px solid #ccc;
1346   }
1347
1348   .inbox-row {
1349     background: #f8f8ff;
1350   }
1351
1352   .inbox-row-unread {
1353     background:#CBEEA7;
1354   }
1355
1356   .right {
1357     float: right;
1358   }
1359
1360   tr td,
1361   tr th {
1362     padding: $lineheight/4;
1363   }
1364   tr td {
1365     height: 30px;
1366     border-right: 1px solid $keyline;
1367   }
1368 }
1369
1370 .inbox-row .inbox-mark-read {
1371   display: none;
1372 }
1373
1374 .info-line {
1375   margin-bottom: $lineheight;
1376   padding: $lineheight/4 0px 4px 0px;
1377   border-bottom: 1px solid #ccc;
1378
1379   form, form div {
1380     display: inline;
1381   }
1382 }
1383
1384 .info-line .user_thumbnail_tiny {
1385   vertical-align: middle;
1386 }
1387
1388 .inbox-mark-unread,
1389 .inbox-mark-read,
1390 .inbox-delete {
1391   width: 1%;
1392 }
1393
1394 .inbox-row-unread .inbox-mark-unread {
1395   display: none;
1396 }
1397
1398 .message-read .message-buttons {
1399   margin-top: $lineheight;
1400   padding-top: $lineheight;
1401   border-top: 1px solid $keyline;
1402 }
1403
1404 .message-read .buttons .mark-unread-button {
1405   border-radius: 0;
1406 }
1407
1408 /* Rules for "flash" notice boxes shown at the top of the content area */
1409
1410 .flash {
1411     padding: $lineheight;
1412   &#error {
1413     background-color: #ff7070;
1414   }
1415   &#warning {
1416     background-color: #ffe0cc;
1417   }
1418   &#notice {
1419     background-color: #CBEEA7;
1420   }
1421 }
1422
1423 /* Rules for highlighting fields with rails validation errors */
1424
1425 .field_with_errors {
1426   padding: 2px;
1427   background-color: #ff7070;
1428   display: table;
1429 }
1430
1431 /* Rules for rails validation error boxes */
1432
1433 #errorExplanation {
1434   width: 400px;
1435   border: 2px solid #ff7070;
1436   padding: $lineheight/2;
1437   margin-bottom: $lineheight;
1438   background-color: #f0f0f0;
1439   h2 {
1440     margin: -10px;
1441     padding: $lineheight/4 $lineheight/4 $lineheight/4 15px;
1442     font-weight: bold;
1443     font-size: 12px;
1444     background-color: #c00;
1445     color: #fff;
1446     text-align: left;
1447   }
1448
1449   p {
1450     color: #333;
1451     margin-bottom: 0px;
1452     padding: $lineheight/4;
1453   }
1454
1455   ul li {
1456     font-size: 12px;
1457     list-style: disc;
1458   }
1459
1460 }
1461
1462 /* Rules for forms */
1463
1464 .standard-form {
1465   fieldset {
1466     margin-bottom: $lineheight;
1467   }
1468   label.standard-label {
1469     display: block;
1470     margin-bottom: $lineheight/4;
1471     font-size: $typeheight;
1472     font-weight: bold;
1473     line-height: 1.5;
1474   }
1475   label.standard-label.secondary {
1476     display: inline-block;
1477     font-weight: normal;
1478   }
1479   .form-help {
1480     font-weight: normal;
1481   }
1482   .form-column {
1483     float: left;
1484     margin-right: 20px;
1485   }
1486   .form-divider {
1487     margin-top: $lineheight;
1488     padding-top: $lineheight;
1489     border-top: 1px solid $keyline;
1490   }
1491   .form-row {
1492     margin-bottom: $lineheight/2;
1493   }
1494   .form-list {
1495     margin-bottom: 0;
1496   }
1497   .form-list li {
1498     margin-bottom: 5px;
1499    }
1500   input[type="checkbox"],
1501   input[type="radio"] {
1502     float: left;
1503     margin-top: 5px;
1504   }
1505 }
1506
1507 #remember_me_openid {
1508   display: block;
1509 }
1510
1511 input[type="checkbox"],
1512 input[type="radio"] {
1513     margin-right: 5px;
1514 }
1515
1516 input[type="text"],
1517 input[type="email"],
1518 input[type="url"],
1519 input[type="password"],
1520 textarea {
1521   border: 1px solid #ccc;
1522   padding: 2px 5px;
1523   margin: 0;
1524   width: 200px;
1525 }
1526
1527 textarea {
1528   padding: 5px;
1529   width: 100%;
1530   height: 100% !important;
1531 }
1532
1533 /* Rules for user images */
1534
1535 img.user_image {
1536   max-width: 100px;
1537   max-height: 100px;
1538   border: 1px solid #ccc;
1539   margin-bottom: $lineheight;
1540   float: left;
1541   margin-right: $lineheight;
1542 }
1543
1544 img.user_thumbnail {
1545   max-width: 50px;
1546   max-height: 50px;
1547   border: 1px solid #ccc;
1548   margin-right: $lineheight;
1549 }
1550
1551 img.user_thumbnail_tiny {
1552   max-width: 25px;
1553   max-height: 25px;
1554   border: 1px solid #ccc;
1555 }
1556
1557 /* Rule for "nowrap" class that can be applied to anything to stop wrapping */
1558
1559 .nowrap {
1560   white-space: nowrap;
1561 }
1562
1563 /* Rules for geo microformats */
1564
1565 abbr.geo {
1566   border-bottom: none;
1567 }
1568
1569 /* Rules for RSS buttons */
1570
1571 .rsssmall {
1572   position: relative;
1573   top: 5px;
1574 }
1575
1576 /* General styles for action lists / subnavs / pager navs */
1577
1578 ul.secondary-actions {
1579   font-style: normal;
1580   margin-bottom: 0;
1581   margin-left: 0;
1582   &.pager {
1583     display: inline-block;
1584     margin-right: 60px;
1585   }
1586   li {
1587     display: block;
1588     float: left;
1589     list-style: none;
1590     border-left: 1px solid #ccc;
1591     padding-left: $lineheight/4;
1592     margin-right: $lineheight/4;
1593     &:first-child {
1594       border-left: 0;
1595       padding-left: 0;
1596     }
1597     &:last-child {
1598       margin-right: 0px;
1599     }
1600   }
1601 }
1602
1603 /* Utility for managing inner content areas */
1604
1605 .inner22 { padding: $lineheight;}
1606
1607 .inner12 { padding: $lineheight/2 $lineheight;}
1608
1609 .inner11 { padding: $lineheight/2;}
1610
1611 .inner02 { padding: 0 $lineheight;}
1612
1613 /* Utility for general button styles */
1614
1615 input[type="button"],
1616 input[type="submit"],
1617 input[type="reset"],
1618 a.button {
1619   cursor: pointer;
1620   border: 0;
1621   display: inline-block;
1622   line-height: 20px;
1623   padding: $lineheight/4 $lineheight/2;
1624   min-width: 120px;
1625   margin: 0 0 $lineheight/2 0;
1626   color: white;
1627   background: $blue;
1628   text-align: center;
1629   border-radius: 2px;
1630   -moz-border-radius: 2px;
1631   &:hover {
1632     background: darken($blue, $hovercolor);
1633     text-decoration: none;
1634   }
1635   &.deemphasize {
1636     background: $lightblue;
1637     &:hover {
1638       background: darken($lightblue, $hovercolor);
1639     }
1640   }
1641   &:last-child {
1642     margin-bottom: 0;
1643   }
1644 }
1645
1646 .buttons {
1647   min-width: 200px;
1648   input[type="submit"],
1649   input[type="button"],
1650   input[type="reset"],
1651   .button {
1652     box-sizing: border-box;
1653     float: left;
1654     border-radius: 0;
1655     margin:0;
1656     min-width: 100px;
1657     max-width: 150px;
1658     border-right:1px solid white;
1659   }
1660   input:first-child,
1661   .button:first-child {
1662     border-radius:2px 0 0 2px;
1663   }
1664   input:last-child,
1665   .button:last-child {
1666     border-radius:0 2px 2px 0;
1667     border-right-width: 0;
1668   }
1669   input:only-child,
1670   .button:only-child,
1671   *[value="Hide"] + input:last-child,
1672   *[value="Hide"] + .button:last-child {
1673     border-radius:2px;
1674     border-right-width: 0;
1675   }
1676     /* if a 3-button set has a hidden middle button */
1677   *[value="Hide"] + input:nth-child(3),
1678   *[value="Hide"] + .button:nth-child(3) {
1679     border-radius:0 2px 2px 0;
1680     border-right-width: 0;
1681   }
1682   /* if a 3-button set starts with a hidden button */
1683   *[value="Hide"] + input:nth-child(2):not(:last-child),
1684   *[value="Hide"] + .button:nth-child(2):not(:last-child) {
1685     border-radius:2px 0 0 2px;
1686     border-right-width: 1px solid white;
1687   }
1688 }
1689
1690 /* Rules for doing distinct colour of alternate table rows */
1691
1692 .table0,
1693 .item0 {
1694   background: $offwhite;
1695 }
1696
1697 .table1,
1698 .item1 {
1699   background: #fff;
1700 }
1701
1702 /* Rules for OpenID logo */
1703
1704 .openid_logo {
1705   vertical-align: text-bottom;
1706   border: 0;
1707 }
1708
1709 /* Rules for rich text */
1710
1711 .richtext,
1712 .prose {
1713   h1, h2 {
1714     padding-bottom: $lineheight/2;
1715     border-bottom: 1px dashed #cccccc;
1716     margin-bottom: $lineheight/2;
1717   }
1718
1719   h1 {
1720     font-size: 24px;
1721   }
1722
1723   h2 {
1724     font-size: 18px;
1725   }
1726
1727   h3 {
1728     font-size: $typeheight;
1729   }
1730
1731   code {
1732     font-size: 13px;
1733     background: #e8e8e8;
1734     padding: 2px 3px;
1735   }
1736
1737   pre {
1738     font-size: 13px;
1739     background: #e8e8e8;
1740     padding: 2px 3px;
1741
1742     code {
1743       padding: 0;
1744     }
1745   }
1746
1747   img {
1748     padding: $lineheight;
1749     background-color: $offwhite;
1750     display: block;
1751     max-width: 100%;
1752     margin: auto;
1753   }
1754
1755   blockquote {
1756     border-left: $lineheight solid $offwhite;
1757     padding-left: $lineheight;
1758     margin: 0;
1759     color: #7E7E7E;
1760   }
1761
1762   ul, ol {
1763     font-style: italic;
1764     padding-left: $lineheight;
1765     margin-bottom: $lineheight;
1766     margin-left: $lineheight;
1767   }
1768
1769   ul li {
1770     list-style: disc;
1771   }
1772
1773   ol li {
1774     list-style: decimal;
1775   }
1776 }
1777
1778 .diary_post .richtext {
1779     margin-top: $lineheight;
1780   }
1781
1782 .comments .richtext {
1783   margin-left: 70px;
1784   margin-top: 0;
1785 }
1786
1787 /* Rules for rich text editors */
1788
1789 .richtext_container {
1790   margin-bottom: $lineheight;
1791
1792   .richtext_content {
1793     width: 50%;
1794     display: inline-block;
1795     vertical-align: top;
1796
1797     .richtext_preview {
1798       display: inline-block;
1799       padding: $lineheight;
1800       background-color: $offwhite;
1801       overflow-x: auto;
1802
1803       &.loading {
1804         background-image: image-url("loading.gif");
1805         background-repeat: no-repeat;
1806         background-position: center;
1807       }
1808
1809       > :first-child {
1810         margin-top: 0px;
1811       }
1812     }
1813   }
1814
1815   .richtext_help {
1816     display: inline-block;
1817     vertical-align: top;
1818     margin-left: 15px;
1819     background-color: #f8f8ff;
1820     padding: $lineheight/2;
1821     width: 300px;
1822     max-width: 450px;
1823
1824     ul {
1825       margin-bottom: 0;
1826     }
1827
1828     h4.heading, li {
1829       border-bottom: 1px solid #ccc;
1830       margin-bottom: $lineheight/4;
1831       padding-bottom: $lineheight/4;
1832     }
1833
1834     li h4, li span, li p {
1835       display: inline-block;
1836       vertical-align: top;
1837       font-size: 11px;
1838     }
1839
1840     li h4 {
1841       width: 35%;
1842       margin: 0;
1843     }
1844
1845     li span, li p {
1846       width: 60%;
1847       margin-left: $lineheight/2;
1848       margin-bottom: $lineheight/4;
1849       white-space: nowrap;
1850     }
1851   }
1852 }
1853
1854 /* Rules for the user notes list */
1855
1856 .note_list {
1857   tr.creator {
1858     background-color: #eeeeee;
1859   }
1860
1861   td {
1862     padding: 3px;
1863   }
1864
1865   p {
1866     margin-bottom: 0px;
1867   }
1868 }
1869
1870 /* Rules for the notes interface */
1871
1872 .note {
1873   padding-top: $lineheight/2;
1874 }
1875
1876 .note {
1877   h2 {
1878     margin-bottom: $lineheight/2;
1879   }
1880
1881   div {
1882     margin-top: $lineheight/2;
1883   }
1884
1885   .permalink {
1886     position: absolute;
1887     top: $lineheight/4;
1888     left: $lineheight/4;
1889     min-width: 15px;
1890     min-height: 15px;
1891     background: image-url("sprite.png") 0 -45px no-repeat;
1892   }
1893
1894   .permalink span {
1895     display: none;
1896     padding-left: $lineheight;
1897   }
1898
1899   .permalink:hover span {
1900     display: block;
1901   }
1902
1903   .warning {
1904     display: block;
1905     background-color: #ffe0cc;
1906     padding: 4px 6px;
1907     margin-bottom: $lineheight/2;
1908   }
1909
1910   .comment_body {
1911     margin-top: 2px;
1912     margin-bottom: 2px;
1913
1914     p {
1915       margin-top: 0px;
1916       margin-bottom: 0px;
1917     }
1918   }
1919
1920   .comment {
1921     width: 100%;
1922     height: 100px;
1923   }
1924
1925   .buttons {
1926     margin-top: $lineheight/4;
1927     text-align: right;
1928   }
1929 }
1930
1931 /*
1932  * Rules for the iD editor
1933  */
1934 .id-embed {
1935   width: 100%;
1936   height: 100%;
1937 }
1938
1939 /* Rules for rotating sidebar ads */
1940 .ad-container {
1941   display: block;
1942   height: 120px;
1943   overflow: hidden;
1944   position: relative;
1945   border-bottom: 1px solid #ccc;
1946 }
1947
1948 .ad {
1949   height: 100px;
1950   border: 0;
1951   background: #fff;
1952 }