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