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