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