]> git.openstreetmap.org Git - rails.git/blob - app/assets/stylesheets/common.scss
Remove unused 0 bottom margin from map ui css
[rails.git] / app / assets / stylesheets / common.scss
1 @import "parameters";
2 @import "bootstrap";
3 @import "rails_bootstrap_forms";
4
5 /* Styles common to large and small screens */
6
7 /* Default rules for the body of every page */
8
9 body {
10   font-size: $typeheight;
11 }
12
13 p > img {
14   width: auto;
15   max-width: 100%;
16 }
17
18 small, aside {
19   font-size: 12px;
20 }
21
22 #container { position: relative; }
23
24 .small_icon {
25   vertical-align: middle;
26   margin-right: $lineheight/4;
27 }
28
29 [dir=rtl] { /* no-r2 */ text-align: right; }
30
31 [dir=ltr] { /* no-r2 */ text-align: left; }
32
33 /* Rules for icons */
34
35 .icon {
36   display: inline-block;
37   vertical-align: top;
38   width: 20px;
39   height: 20px;
40   background: transparent image-url("sprite.png") no-repeat 0 0;
41   background-image: image-url("sprite.svg");
42   text-indent: -9999px;
43   overflow: hidden;
44 }
45
46 .icon.search      { /* no-r2 */ background-position: 0 0; }
47 .icon.donate      { /* no-r2 */ background-position: -20px 0; }
48 .icon.zoomin      { /* no-r2 */ background-position: -40px 0; }
49 .icon.zoomout     { /* no-r2 */ background-position: -60px 0; }
50 .icon.geolocate   { /* no-r2 */ background-position: -80px 0; }
51 .active .icon.geolocate   { /* no-r2 */ background-position: -80px -20px; }
52 .icon.layers      { /* no-r2 */ background-position: -100px 0; }
53 .icon.key         { /* no-r2 */ background-position: -120px 0; }
54 .icon.share       { /* no-r2 */ background-position: -140px 0; }
55 .icon.clipboard   { /* no-r2 */ background-position: -160px 0; }
56 .icon.link        { /* no-r2 */ background-position: -180px 0; }
57 .icon.close       { /* no-r2 */ background-position: -200px 0; }
58 .icon.close:hover { /* no-r2 */ background-position: -200px -20px; }
59 .icon.check       { /* no-r2 */ background-position: -220px 0; }
60 .icon.note        { /* no-r2 */ background-position: -240px 0; }
61 .icon.note.grey   { /* no-r2 */ background-position: -240px -20px; }
62 .icon.query       { /* no-r2 */ background-position: -260px 0; }
63
64 /* Utility for de-emphasizing content */
65
66 .text-muted a {
67   color: $blue;
68 }
69
70 /* Rules for borders */
71 /* These add additional colours to those provided by bootstrap */
72 .border-grey {
73   border-color: $grey !important;
74 }
75
76 .border-lightgrey {
77   border-color: $lightgrey !important;
78 }
79
80 /* Rules for the header */
81
82 #menu-icon {
83   display: none;
84   float: right;
85   background: image-url("menu-icon.png") no-repeat;
86   background-size: 30px 30px;
87   width: 30px;
88   height: 30px;
89   margin: 14px 10px 0 0;
90   opacity: 0.6;
91 }
92
93 header {
94   height: $headerHeight;
95   position: relative;
96   z-index: 1001;
97   font-size: 14px;
98
99   h1, nav, nav > ul, nav > ul > li {
100     display: inline-block;
101   }
102
103   > * {
104     height: 100%;
105     padding: $lineheight/2;
106   }
107
108   h1, nav.primary {
109     float: left;
110   }
111
112   a, a:hover {
113     text-decoration: none;
114   }
115
116   img.logo {
117     width: 30px;
118     height: 30px;
119     margin-top: -2px;
120     vertical-align: middle;
121   }
122
123   h1 {
124     font-size: 18px;
125     font-weight: 600;
126     line-height: 1.2;
127     margin: 0;
128     padding-top: 15px;
129
130     a {
131       color: #000;
132     }
133
134     a:hover {
135       color: #000;
136     }
137   }
138
139   .btn {
140     font-size: 14px;
141   }
142 }
143
144
145 nav.primary {
146   .btn-outline-primary {
147     @include button-outline-variant($green, $color-hover: $white, $active-color: $white);
148   }
149
150   .disabled {
151     .btn-outline-primary {
152       color: $grey;
153       cursor: default;
154
155       .caret {
156         border-top-color: $grey;
157       }
158
159       &:hover {
160         background-color: lighten($green, 30%);
161       }
162     }
163   }
164
165   // Small tweaks to the toggle to stop the primary colour showing through
166   // when the menu is shown
167   .show > .btn-outline-primary.dropdown-toggle {
168     background-color: $green;
169     border-color: $green;
170
171     &:focus {
172       box-shadow: 0 0 0 0.2rem fade-out($green, 0.5);
173     }
174   }
175 }
176
177 nav.secondary {
178   position: absolute;
179   right: 0;
180
181   .nav-link {
182     padding: 0.2rem;
183     color: $darkgrey;
184   }
185
186   > ul li.current a {
187     color: darken($darkgrey, 25%);
188   }
189
190   .login-menu {
191     .btn-outline-secondary {
192       @include button-outline-variant($darkgrey, $color-hover: $white, $active-color: $white);
193     }
194   }
195
196   .user-menu {
197     .btn-outline-secondary {
198       @include button-outline-variant($darkgrey, $color-hover: $darkgrey, $active-background: white, $active-border: $darkgrey);
199       border-color: $grey;
200       &:hover {
201         border-color: $grey;
202       }
203     }
204   }
205
206   #inboxanchor {
207     display: inline-block;
208     height: 25px;
209     margin: 3px 0 3px 3px;
210     background-color: lighten($grey, 10%);
211     line-height: 20px;
212     border-radius: 3;
213   }
214
215   .dropdown-menu {
216     .count-number {
217       font-size: 14px;
218     }
219   }
220 }
221
222 nav.primary, nav.secondary {
223   .dropdown-item {
224     &:hover, &:active {
225       background-color: $green;
226       color: white;
227     }
228   }
229 }
230
231 #compact-secondary-nav {
232   display: none;
233 }
234
235 body.compact-nav {
236   #compact-secondary-nav {
237     display: inline-block;
238   }
239   .compact-hide {
240     display: none;
241   }
242 }
243
244 body.small-nav {
245   #menu-icon {
246     display: block;
247   }
248
249   nav.primary,
250   nav.secondary {
251     float: none !important;
252     position: relative;
253     display: block;
254     clear: both;
255   }
256
257   header {
258     height: auto;
259     min-height: $headerHeight;
260     background: #fff;
261
262     &.closed nav {
263       display: none;
264     }
265
266     .search_forms {
267       display: block;
268     }
269   }
270
271   #sidebar .search_forms,
272   #edit_tab,
273   #export_tab {
274     display: none;
275   }
276
277   nav.primary {
278     padding: 0;
279
280     ul, li {
281       border: none;
282       border-radius: 0;
283       width: 100%;
284     }
285
286     ul {
287       border-top: 1px solid #eee;
288       li {
289         border-bottom: 1px solid #eee;
290         border-right: none;
291         > a {
292           border-radius: 0;
293           width: 100%;
294           text-align: center;
295           font-size: 15px;
296         }
297       }
298     }
299
300     .btn-group {
301       width: 100%;
302       padding: 10px;
303     }
304   }
305
306   nav.secondary {
307     .user-menu {
308       width: 100%;
309     }
310   }
311
312   #compact-secondary-nav {
313     display: none;
314   }
315
316   .compact-hide {
317     display: inline-block;
318   }
319
320   .overlay-sidebar #sidebar .welcome.visible {
321     display: none;
322   }
323
324   .overlay-sidebar #sidebar #banner {
325     display: none;
326   }
327
328   .leaflet-top.leaflet-right {
329     top: 10px !important;
330   }
331 }
332
333 /* Utility for styling notification numbers */
334
335 .count-number {
336   padding: 2px $lineheight/4;
337   border-radius: 2px;
338   background: lighten($green, 30%);
339   margin: 0 2px;
340   font-size: 11px;
341   color: #333;
342 }
343
344 /* Rules for the message shown in place of the map when javascript is disabled */
345
346 #noscript {
347   z-index: 20000000;
348   margin-left: 400px;
349   margin-top: 50px;
350 }
351
352 /* Rules for Leaflet maps */
353
354 .leaflet-control .control-button {
355   display: block;
356   height: 40px;
357   width: 40px;
358   background-color: #333;
359   background-color: rgba(0,0,0,.6);
360   outline: none;
361
362   &:hover,
363   &:focus {
364     background-color: black;
365   }
366
367   &.disabled,
368   &.leaflet-disabled {
369     background-color: #333;
370     background-color: rgba(0,0,0,.5);
371     cursor: default;
372   }
373
374   &.active {
375     background-color: $vibrant-green;
376   }
377
378   &-first {
379     border-start-start-radius: 4px;
380   }
381
382   &-last {
383     border-end-start-radius: 4px;
384     margin-bottom: 10px;
385   }
386
387   .icon {
388     margin: 10px;
389   }
390 }
391
392 /* Rules for the sidebar and main map area */
393
394 .map-layout {
395   #content {
396     overflow: hidden;
397     position: absolute;
398     top: $headerHeight;
399     bottom: 0;
400     width: 100%;
401   }
402
403   #sidebar, #map {
404     position: relative;
405     height: 100%;
406     overflow-x: hidden;
407     overflow-y: auto;
408   }
409
410   #sidebar {
411     float: left;
412     width: $sidebarWidth;
413     background: #fff;
414
415     #sidebar_loader {
416       display: none;
417     }
418
419     #sidebar_content {
420       padding: $spacer;
421     }
422
423     > div {
424       position: relative;
425       float: left;
426       clear: both;
427       width: 100%;
428     }
429   }
430
431   .overlay-sidebar #sidebar {
432     position: absolute;
433     z-index: 1000;
434     height: auto;
435     overflow: hidden;
436
437     #banner {
438       display: block;
439     }
440
441     .welcome {
442       display: none;
443
444       &.visible {
445         display: block;
446       }
447     }
448
449     #sidebar_content {
450       display: none;
451     }
452   }
453
454   .welcome {
455     display: none;
456
457     p {
458       font-size: 110%;
459       font-weight: 300;
460     }
461   }
462
463   #banner {
464     display: none;
465
466     img {
467       display: block;
468       width: $sidebarWidth;
469     }
470   }
471
472   #map {
473     height: 100%;
474     overflow: hidden;
475
476     &.query-active {
477       cursor: help;
478     }
479
480     &.query-disabled {
481       cursor: not-allowed;
482     }
483
484     .leaflet-marker-draggable {
485       cursor: move;
486     }
487   }
488
489   #map-ui {
490     display: none;
491     position: relative;
492     float: right;
493     width: 250px;
494     height: 100%;
495     background: white;
496     overflow: auto;
497
498     .section {
499       border-bottom: 1px solid $grey;
500       padding: 10px 20px;
501     }
502   }
503 }
504
505 @include media-breakpoint-down(md) {
506   body.map-layout {
507     #sidebar, #map {
508       position: relative;
509       overflow-x: hidden;
510       width: 100%;
511       height: 50%;
512     }
513
514     #map-ui {
515       z-index: 9999;
516       width: 100%;
517       height: 50%;
518       overflow-y: scroll;
519     }
520
521     .overlay-sidebar {
522       #sidebar {
523         position: absolute;
524         width: 350px;
525         height: auto;
526         overflow: hidden;
527       }
528
529       #map, #map-ui {
530         height: 100%;
531       }
532     }
533   }
534 }
535
536 .layers-ui {
537   .base-layers {
538     .leaflet-container {
539       width: 100%;
540       height: 50px;
541       cursor: pointer;
542     }
543
544     li  {
545       overflow: hidden;
546       border-radius: 3px;
547       border: 2px solid #fff;
548       margin-bottom: 8px;
549       position: relative;
550       transition: border-color 0.08s ease-in;
551
552       label {
553         position: absolute;
554         top: 0;
555         left: 0;
556         padding: 2px 6px;
557         border-bottom-right-radius: 3px;
558         cursor: pointer;
559         font-weight: 600;
560         font-size: 16px;
561         text-stroke: 2px #fff;
562         background: rgba(255,255,255,.9);
563         z-index: 1000;
564         input[type="radio"] {
565           display: none;
566         }
567       }
568
569       &.active { border-color: darken($green, 10%); }
570       &:hover {
571         border-color: $grey;
572         &.active { border-color: darken($green, 20%); }
573       }
574     }
575   }
576
577   .overlay-layers {
578     p {
579       font-size: 13px;
580       margin-bottom: 8px;
581     }
582     li.disabled { color: $darkgrey; }
583   }
584 }
585
586 .share-ui {
587   .share-tab {
588     display: none;
589   }
590
591   .share-link {
592     input[type=text],
593     textarea {
594       width: 100%;
595       font-family: monospace;
596       font-size: small;
597       line-height: 1.3;
598     }
599   }
600
601   .share-image {
602     label {
603       margin-right: 10px;
604     }
605   }
606
607   #embed_html {
608     resize: vertical;
609   }
610
611   #mapnik_scale {
612     width: 100px;
613   }
614 }
615
616 .leaflet-top {
617   top: $lineheight/2 !important;
618   .leaflet-control {
619     margin-right: 0px !important;
620     margin-top: 0px !important;
621   }
622 }
623
624 .leaflet-popup-scrolled {
625   padding-right: $lineheight;
626   border-bottom: 0px !important;
627   border-top: 0px !important;
628 }
629
630 .leaflet-popup-content-wrapper {
631   border-radius: 4px !important;
632 }
633
634 /* Rules for attribution text under the main map shown on printouts */
635
636 #attribution {
637   display: none;
638
639   table {
640     width: 100%
641   }
642 }
643
644 .attribution_license,
645 .attribution_project {
646   text-align: left;
647 }
648
649 .attribution_notice {
650   text-align: center;
651 }
652
653 .donate-attr { color: darken($green, 10%) !important; }
654
655 /* Rules for the sidebar */
656
657 .sidebar_heading {
658   position: relative;
659   padding: $lineheight/2 $lineheight;
660   // background: $offwhite;
661   // border-bottom: 1px solid $grey;
662 }
663
664 #browse_status {
665   input {
666     display: block;
667     margin-left: auto;
668     margin-right: auto;
669   }
670
671   > div {
672    padding: $spacer;
673   }
674 }
675
676 /* Temporary label size override until we remove site-wide font customisation */
677
678 form {
679   label {
680     font-size: 16px;
681   }
682 }
683
684 /* Stop bootstrap 5 from floating legends when they don't need to be */
685 legend {
686   float: none;
687 }
688
689 /* Override the text colour for primary and secondary buttons, to match our
690    bootstrap 4 colours. Note this has accessibility issues, which is why
691    bootstrap 5 calculates black as the appropriate colour, and we should
692    reconsider our colours at some point with that in mind. */
693
694 .btn-primary {
695   @include button-variant($primary, $primary, $color: $white, $hover-color: $white, $active-color: $white, $disabled-color: $white);
696 }
697
698 .btn-secondary {
699   @include button-variant($secondary, $secondary, $color: $white, $hover-color: $white, $active-color: $white, $disabled-color: $white);
700 }
701
702 .btn-outline-secondary {
703   @include button-outline-variant($secondary, $color-hover: $white, $active-color: $white);
704 }
705
706 /* Rules for the search and direction forms */
707
708 header .search_forms,
709 .directions_form {
710   display: none;
711 }
712
713 /* Rules for the map key which appears in the popout sidebar */
714
715 #mapkey {
716  .mapkey-table-key img {
717     display: block;
718     margin-left: auto;
719     margin-right: auto;
720   }
721 }
722
723 /* Rules for search sidebar */
724
725 #sidebar .search_results_entry {
726   ul li {
727     cursor: pointer;
728     &.selected { background: $list-highlight; }
729   }
730
731   .search_more .loader {
732     display: none;
733   }
734 }
735
736 .search_results_error {
737   color: #f00;
738   padding: 10px 20px;
739 }
740
741 /* Rules for routing */
742
743 div.direction {
744   background-image: image-url('routing-sprite.png');
745   width: 20px;
746   height: 20px;
747   background-repeat: no-repeat;
748 }
749 @for $i from 0 through 25 {
750 div.direction.i#{$i} { background-position: #{($i)*-20}px 0px; }
751 }
752
753 td.instruction, td.distance {
754     padding-top: $lineheight/5;
755     padding-bottom: $lineheight/5;
756     border-bottom: 1px solid $grey;
757 }
758 td.distance {
759     color: $darkgrey;
760     text-align: right;
761     font-size: x-small;
762 }
763 tr.turn {
764     cursor: pointer;
765 }
766 tr.turn:hover {
767     background: $list-highlight;
768 }
769
770 .routing_marker { width: 15px; cursor: move; }
771
772 .browse_status {
773   display: none;
774 }
775
776 /* Rules for the history sidebar */
777
778 #sidebar .changesets {
779   li {
780     &.selected { background: $list-highlight; }
781     /* color is derived from changeset bbox fillColor in history.js */
782
783     a.stretched-link > span, a:not(.stretched-link), [title] {
784       position: relative;
785       z-index: 2; /* needs to be higher than Bootstrap's stretched link ::after z-index */
786     }
787   }
788
789   .comments {
790     color: $darkgrey;
791   }
792
793   .comments-0 {
794     opacity: 0.5;
795   }
796
797   .changeset_more .loader {
798     display: none;
799     width: 100%;
800   }
801 }
802
803 /* Rules for the browse sidebar */
804
805 #sidebar_content {
806   .browse-section {
807     padding-bottom: $spacer;
808     margin-bottom: $spacer;
809     border-bottom: 1px solid $grey;
810
811     h4:first-child {
812       word-wrap: break-word;
813     }
814   }
815
816   .browse-section:last-of-type {
817     border-bottom: none;
818   }
819
820   .browse-tag-list {
821     background-color: $offwhite;
822     table-layout: fixed;
823     border-collapse: separate;
824     border-spacing: 0;
825     width: 100%;
826     margin-bottom: $spacer;
827
828     th, td {
829       border-bottom: 1px solid $grey;
830     }
831
832     tr:last-child th, tr:last-child td {
833       border-bottom: 0;
834     }
835
836     .browse-tag-k,
837     .browse-tag-v {
838       width: 50%;
839       padding: 6px 10px;
840       word-wrap: break-word;
841       white-space: pre-wrap;
842     }
843
844     .browse-tag-k {
845       font-weight: 500;
846       background-color: $offwhite;
847     }
848
849     .browse-tag-v {
850       border-left: 1px solid $grey;
851       background-color: #fff;
852     }
853
854     .colour-preview-box {
855       float: right;
856       width: 14px;
857       height: 14px;
858       margin: 4px 0px;
859       border: 1px solid rgba(0, 0, 0, .1);
860       // add color via inline css on element: background-color: <tag value>;
861     }
862   }
863
864   .note-comments li, .changeset-comments li {
865     margin: $lineheight/2 0;
866
867     p {
868       margin: 10px 6px 0 6px;
869       line-height: 1.5;
870     }
871   }
872
873   .subscribe-buttons input {
874     font-size: 90%;
875     line-height: 15px;
876     min-height: 20px;
877   }
878
879   span.action-button:hover {
880     cursor: pointer;
881     text-decoration: underline;
882   }
883
884   .note-description {
885     overflow: hidden;
886     margin: 0 0 10px 10px;
887   }
888
889   .query-results {
890     display: none;
891
892     ul {
893       li {
894         &.query-result {
895           cursor: pointer;
896         }
897
898         &.selected {
899           background: $list-highlight;
900         }
901       }
902     }
903   }
904 }
905
906 /* Bootstrap buttons don't have any vertical margin, so
907    they touch when adjacent buttons wrap onto a new line
908    e.g. wide form buttons on a narrow sidebar */
909
910 .btn-wrapper {
911   > .btn {
912     margin-bottom: $spacer * 0.25;
913   }
914 }
915
916 /* Rules for export sidebar */
917
918 .export_form {
919   .export_area_inputs,
920   .export_button {
921     text-align: center;
922   }
923
924   .export_area_inputs {
925     margin-bottom: $spacer;
926     input[type="text"] {
927       width: 100px;
928       text-align: center;
929     }
930   }
931
932   .export_boxy {
933     background: $lightgrey;
934
935     #maxlat { margin-top: -1px; }
936     #minlon {
937       float: left;
938       /* no-r2 */ margin-left: -1px;
939     }
940     #maxlon {
941       float: right;
942       /* no-r2 */ margin-right: -1px;
943     }
944     #minlat { margin-bottom: -1px; }
945   }
946
947   .export_bound {
948     margin: $lineheight/4;
949   }
950
951   dl {
952     padding-left: $lineheight/2;
953     dd {
954       margin-left: 0;
955       margin-bottom: 10px;
956     }
957   }
958 }
959
960 /* Rules for edit pages */
961
962 .site-edit {
963   #content {
964     position: absolute;
965     top: $headerHeight;
966     bottom: 0;
967     width: 100%;
968   }
969
970   #map {
971     height: 100%;
972     overflow: hidden;
973   }
974 }
975
976 /* Rules for non-map content pages */
977
978 .content-heading {
979   background: $lightgrey;
980 }
981
982 .content-inner {
983   position: relative;
984   max-width: 960px;
985   margin: auto;
986   padding: $lineheight;
987 }
988
989 /* Overrides for pages that use new layout conventions */
990
991 .header-illustration {
992   background-position: 0 0;
993   background-repeat: no-repeat;
994   position: relative;
995   min-height: 200px;
996   width: 100%;
997   left: 0;
998   bottom: 0;
999
1000   &.new-user-main {
1001     background-image: image-url("sign-up-illustration.png");
1002   }
1003
1004   &.confirm-main {
1005     background-image: image-url("confirm-illustration.png");
1006   }
1007
1008   &.new-user-terms {
1009     background-image: image-url("terms-illustration.png");
1010   }
1011
1012   &.new-user-arm {
1013     height: 110px;
1014     width: 130px;
1015     left: 280px;
1016     top: 180px;
1017     background-image: image-url("sign-up-illustration-arm.png");
1018     position: absolute;
1019     z-index: 100;
1020     pointer-events: none;
1021   }
1022 }
1023
1024 [dir=rtl] .header-illustration {
1025   transform: scaleX(-1);
1026
1027   h1 {
1028     transform: scaleX(-1);
1029   }
1030 }
1031
1032 #content.maximised {
1033   top: 0;
1034   left: 0;
1035   right: 0;
1036   bottom: 0;
1037   border: 0;
1038   z-index: 2000;
1039 }
1040
1041 /* Rules for small maps in content areas */
1042
1043 .content_map {
1044   height: 200px;
1045   margin-bottom: $lineheight;
1046 }
1047
1048 @include media-breakpoint-up(md) {
1049   .content_map {
1050     height: 400px;
1051   }
1052 }
1053
1054 /* Rules for the user map */
1055
1056 .content_map .leaflet-popup-content {
1057   margin: $lineheight/2;
1058   min-height: 50px;
1059 }
1060
1061 /* Rules for user popups on maps */
1062
1063 .user_popup {
1064   min-width: 200px;
1065   p {
1066     padding: 0 0 5px 0;
1067     margin: 0 0 0 60px;
1068     font-size: 12px;
1069   }
1070 }
1071
1072 /* Rules for the user list */
1073
1074 #user_list {
1075   width: 100%;
1076 }
1077
1078 /* Rules for the diary list page */
1079
1080 .diary_post {
1081   position: relative;
1082   padding-top: $lineheight;
1083   padding-bottom: $lineheight/2;
1084   border-top: 1px solid $grey;
1085
1086   &.deleted {
1087     background-color: #fee;
1088   }
1089 }
1090
1091 /* Rules for the diary entry page */
1092
1093 .diary_entries {
1094   #map {
1095     height: 400px;
1096     display: none;
1097     margin-bottom: $lineheight;
1098   }
1099   .comments {
1100     max-width: 740px;
1101   }
1102   .diary-comment {
1103     border-top: 1px dashed $grey;
1104     padding-top: $lineheight/2;
1105     padding-bottom: $lineheight/2;
1106     &:first-child {
1107       margin-top: $lineheight/2;
1108       padding-top: $lineheight;
1109       border-top: 1px solid $grey;
1110     }
1111     &.deleted {
1112       background-color: #fee;
1113     }
1114     p {
1115       margin-bottom: $lineheight/2;
1116     }
1117     .comment-heading {
1118       margin-bottom: 0;
1119       margin-top: 0;
1120     }
1121   }
1122 }
1123
1124 /* Rules for the log in page */
1125
1126 #login_auth_buttons {
1127   margin-bottom: 0;
1128
1129   li {
1130     float: left;
1131     padding: $lineheight/4 $lineheight/2;
1132   }
1133 }
1134
1135 /* Rules for the account confirmation page */
1136
1137 .users-terms {
1138   .legale {
1139     padding: $lineheight;
1140     margin-bottom: $lineheight;
1141     overflow: auto;
1142     height: 20em;
1143
1144     li {
1145       list-style: inherit;
1146     }
1147
1148     ol ol {
1149       list-style-type: lower-alpha;
1150     }
1151   }
1152 }
1153
1154 /* Rules for the account settings page */
1155
1156 #accountForm .user_image {
1157   margin-bottom: 0;
1158 }
1159
1160 #accountForm #user_image {
1161   margin-left: 20px;
1162 }
1163
1164 #accountForm ul.accountImage-options {
1165   margin-left: 120px;
1166 }
1167
1168 .nohome .location {
1169   display: none;
1170 }
1171
1172 #homerow .message {
1173   display: none;
1174 }
1175
1176 .nohome .message {
1177   display: inline !important;
1178 }
1179
1180 /* Rules for the oauth authorization page */
1181
1182 .oauth-authorize ul {
1183   list-style: none;
1184 }
1185
1186 /* Rules for messages pages */
1187
1188 .messages {
1189   button[type="submit"] {
1190     margin: auto;
1191     white-space: nowrap;
1192   }
1193
1194   .inbox-row {
1195     background: $offwhite;
1196   }
1197
1198   .inbox-row-unread {
1199     background: #CBEEA7;
1200   }
1201
1202   .right {
1203     float: right;
1204   }
1205 }
1206
1207 .inbox-row .inbox-mark-read {
1208   display: none;
1209 }
1210
1211 .info-line {
1212   margin-bottom: $lineheight;
1213   padding: $lineheight/4 0px 4px 0px;
1214   border-bottom: 1px solid $grey;
1215
1216   form, form div {
1217     display: inline;
1218   }
1219 }
1220
1221 .info-line .user_thumbnail_tiny {
1222   vertical-align: middle;
1223 }
1224
1225 .inbox-sent {
1226   white-space: nowrap;
1227 }
1228
1229 .inbox-mark-unread,
1230 .inbox-mark-read,
1231 .inbox-delete {
1232   width: 1%;
1233 }
1234
1235 .inbox-row-unread .inbox-mark-unread {
1236   display: none;
1237 }
1238
1239 /* Rules for highlighting fields with rails validation errors */
1240
1241 .formError {
1242   display: inline-block;
1243   padding: 5px 10px;
1244   margin-top: 5px;
1245   border-radius: 4px;
1246   font-size: 12px;
1247   color: #fff;
1248   background-color: #ff7070;
1249 }
1250
1251 /* Rules for rails validation error boxes */
1252
1253 #errorExplanation {
1254   width: 400px;
1255   border: 2px solid #ff7070;
1256   padding: 0 $lineheight/2;
1257   margin-bottom: $lineheight;
1258   background-color: #f0f0f0;
1259
1260   h2 {
1261     margin: 0 -10px 10px -10px;
1262     padding: $lineheight/4 $lineheight/4 $lineheight/4 15px;
1263     font-weight: bold;
1264     font-size: 12px;
1265     background-color: #c00;
1266     color: #fff;
1267     text-align: left;
1268   }
1269
1270   p {
1271     color: #333;
1272     margin-bottom: 0px;
1273     padding: $lineheight/4;
1274   }
1275 }
1276
1277 .search_form {
1278   background-color: $lightgrey;
1279
1280   .describe_location {
1281     top: 6px;
1282     right: 6px;
1283     font-size: 10px;
1284     color: $blue;
1285   }
1286 }
1287
1288 .directions_form {
1289   background-color: $lightgrey;
1290 }
1291
1292 /* Rules for user images */
1293
1294 img.user_image {
1295   max-width: 100px;
1296   max-height: 100px;
1297 }
1298
1299 img.user_thumbnail {
1300   max-width: 50px;
1301   max-height: 50px;
1302 }
1303
1304 img.user_thumbnail_tiny {
1305   width: auto;
1306   height: auto;
1307   max-width: 25px;
1308   max-height: 25px;
1309 }
1310
1311 /* Rules for geo microformats */
1312
1313 abbr.geo {
1314   border-bottom: none;
1315 }
1316
1317 /* General styles for action lists / subnavs */
1318
1319
1320 nav.secondary-actions {
1321   margin-left: -11px;
1322   overflow: hidden;
1323   > ul {
1324     display: flex;
1325     flex-direction: row;
1326     flex-wrap: wrap;
1327     margin-bottom: 0;
1328     margin-left: -1px;
1329     padding: 0;
1330     > li {
1331       flex-basis: auto;
1332       list-style: none;
1333       border-left: 1px solid $grey;
1334       padding-left: $lineheight/2;
1335       margin-right: $lineheight/2;
1336       margin-bottom: $lineheight/8;
1337     }
1338   }
1339 }
1340
1341 div.secondary-actions {
1342   padding: 10px;
1343   text-align: center;
1344 }
1345
1346 /* Create a single-line dl */
1347
1348 dl.dl-inline {
1349   dt, dd {
1350     display: inline-block;
1351   }
1352   dd {
1353     margin-right: 1em;
1354   }
1355 }
1356
1357 /* Rules for OpenID logo */
1358
1359 .openid_logo {
1360   vertical-align: text-bottom;
1361   border: 0;
1362 }
1363
1364 /* Rules for rich text */
1365
1366 .richtext,
1367 .prose {
1368   code {
1369     background: $lightgrey;
1370     padding: 2px 3px;
1371   }
1372
1373   pre {
1374     background: $lightgrey;
1375     padding: 2px 3px;
1376     white-space: pre-wrap;
1377
1378     code {
1379       padding: 0;
1380     }
1381   }
1382
1383   img {
1384     padding: $lineheight;
1385     background-color: $offwhite;
1386     display: block;
1387     max-width: 100%;
1388     margin: auto;
1389   }
1390
1391   blockquote {
1392     border-left: $lineheight solid $offwhite;
1393     padding-left: $lineheight;
1394     margin: 0;
1395     color: $darkgrey;
1396   }
1397 }
1398
1399 /* Rules for the user notes list */
1400
1401 .note_list {
1402   tr.creator {
1403     background-color: $offwhite;
1404   }
1405 }
1406
1407 /* Rules for the iD editor */
1408
1409 .id-embed {
1410   width: 100%;
1411   height: 100%;
1412 }
1413
1414 /* Rules for the "Welcome" page */
1415 .site-welcome, .site-fixthemap {
1416   .sprite {
1417     background-image: image-url("welcome-sprite.png");
1418     background-size: 500px 250px;
1419     display: block;
1420   }
1421
1422   .sprite.small {
1423     width: 50px;
1424     height: 50px;
1425   }
1426
1427   .sprite.x {
1428     /* no-r2 */ background-position: -50px 0;
1429   }
1430
1431   .sprite.term {
1432     margin-right: 10px;
1433     vertical-align: middle;
1434   }
1435
1436   .sprite.node {
1437     /* no-r2 */ background-position: -100px 0;
1438   }
1439
1440   .sprite.way {
1441     /* no-r2 */ background-position: -150px 0;
1442   }
1443
1444   .sprite.tag {
1445     /* no-r2 */ background-position: -200px 0;
1446   }
1447
1448   .sprite.editor {
1449     /* no-r2 */ background-position: -250px 0;
1450   }
1451
1452   .sprite.question {
1453     /* no-r2 */ background-position: -300px 0;
1454   }
1455
1456   .sprite.rules {
1457     /* no-r2 */ background-position: -350px 0;
1458   }
1459
1460   .icon.note {
1461     background-color: #333;
1462     border-radius: 4px;
1463   }
1464 }
1465
1466 .site-about #content {
1467   background-color: $lightgrey;
1468
1469   .content-inner {
1470     max-width: 760px;
1471   }
1472
1473   .attr {
1474     margin-top: -20px;
1475
1476     h1 {
1477       span {
1478         color: $vibrant-green;
1479       }
1480     }
1481
1482     .user-image {
1483       height: 150px;
1484       background-position: 0 50%;
1485       background-repeat: no-repeat;
1486       background-image: image-url('about/osm.png');
1487       background-size: cover;
1488       background-color: $vibrant-green;
1489     }
1490
1491     .byosm {
1492       background: $vibrant-green;
1493     }
1494
1495     .byosm span {
1496       display: inline-block;
1497       width: 1em;
1498       margin-left: -1em;
1499     }
1500   }
1501
1502   .icon {
1503     width: 30px;
1504     height: 30px;
1505     background: 40px 40px image-url('about/sprite.png') no-repeat;
1506
1507     &.local {
1508       /* no-r2 */
1509       background-position: 0px 0px;
1510     }
1511     &.community {
1512       /* no-r2 */
1513       background-position: 0px -40px;
1514     }
1515     &.open {
1516       /* no-r2 */
1517       background-position: 0px -80px;
1518     }
1519     &.partners {
1520       /* no-r2 */
1521       background-position: 0px -120px;
1522     }
1523     &.infringement {
1524       /* no-r2 */
1525       background-position: 0px -160px;
1526     }
1527     &.legal {
1528       /* no-r2 */
1529       background-position: -45px -160px;
1530     }
1531   }
1532 }
1533
1534 @import 'browse';