]> git.openstreetmap.org Git - rails.git/blob - app/assets/stylesheets/common.scss
Merge remote-tracking branch 'upstream/pull/3644'
[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
1294 /* Rules for user images */
1295
1296 img.user_image {
1297   max-width: 100px;
1298   max-height: 100px;
1299 }
1300
1301 img.user_thumbnail {
1302   max-width: 50px;
1303   max-height: 50px;
1304 }
1305
1306 img.user_thumbnail_tiny {
1307   width: auto;
1308   height: auto;
1309   max-width: 25px;
1310   max-height: 25px;
1311 }
1312
1313 /* Rules for geo microformats */
1314
1315 abbr.geo {
1316   border-bottom: none;
1317 }
1318
1319 /* General styles for action lists / subnavs / pager navs */
1320
1321
1322 nav.secondary-actions {
1323   margin-left: -11px;
1324   overflow: hidden;
1325   > ul {
1326     display: flex;
1327     flex-direction: row;
1328     flex-wrap: wrap;
1329     margin-bottom: 0;
1330     margin-left: -1px;
1331     padding: 0;
1332     &.pager {
1333       display: inline-block;
1334       margin-right: 60px;
1335     }
1336     > li {
1337       flex-basis: auto;
1338       list-style: none;
1339       border-left: 1px solid $grey;
1340       padding-left: $lineheight/2;
1341       margin-right: $lineheight/2;
1342       margin-bottom: $lineheight/8;
1343     }
1344   }
1345 }
1346
1347 div.secondary-actions {
1348   padding: 10px;
1349   text-align: center;
1350 }
1351
1352 .buttons {
1353   min-width: 200px;
1354   input[type="submit"],
1355   input[type="button"],
1356   input[type="reset"],
1357   .button,
1358   .button_to {
1359     box-sizing: border-box;
1360     float: left;
1361     border-radius: 0;
1362     margin:0;
1363     min-width: 75px;
1364     max-width: 180px;
1365     border-right:1px solid white;
1366     text-overflow: ellipsis;
1367     white-space: nowrap;
1368     overflow: hidden;
1369   }
1370   input:first-child,
1371   .button:first-child,
1372   .button_to:first-child {
1373     border-radius:2px 0 0 2px;
1374   }
1375   input:last-child,
1376   .button:last-child,
1377   .button_to:last-child {
1378     border-radius:0 2px 2px 0;
1379     border-right-width: 0;
1380   }
1381   input:only-child,
1382   .button:only-child,
1383   .button_to:only-child,
1384   *[value="Hide"] + input:last-child,
1385   *[value="Hide"] + .button:last-child,
1386   *[value="Hide"] + .button_to:last-child {
1387     border-radius:2px;
1388     border-right-width: 0;
1389   }
1390     /* if a 3-button set has a hidden middle button */
1391   *[value="Hide"] + input:nth-child(3),
1392   *[value="Hide"] + .button:nth-child(3),
1393   *[value="Hide"] + .button_to:nth-child(3) {
1394     border-radius:0 2px 2px 0;
1395     border-right-width: 0;
1396   }
1397   /* if a 3-button set starts with a hidden button */
1398   *[value="Hide"] + input:nth-child(2):not(:last-child),
1399   *[value="Hide"] + .button:nth-child(2):not(:last-child),
1400   *[value="Hide"] + .button_to:nth-child(2):not(:last-child) {
1401     border-radius:2px 0 0 2px;
1402     border-right-width: 1px;
1403   }
1404 }
1405
1406 /* Create a single-line dl */
1407
1408 dl.dl-inline {
1409   dt, dd {
1410     display: inline-block;
1411   }
1412   dd {
1413     margin-right: 1em;
1414   }
1415 }
1416
1417 /* Rules for OpenID logo */
1418
1419 .openid_logo {
1420   vertical-align: text-bottom;
1421   border: 0;
1422 }
1423
1424 /* Rules for rich text */
1425
1426 .richtext,
1427 .prose {
1428   code {
1429     background: $lightgrey;
1430     padding: 2px 3px;
1431   }
1432
1433   pre {
1434     background: $lightgrey;
1435     padding: 2px 3px;
1436     white-space: pre-wrap;
1437
1438     code {
1439       padding: 0;
1440     }
1441   }
1442
1443   img {
1444     padding: $lineheight;
1445     background-color: $offwhite;
1446     display: block;
1447     max-width: 100%;
1448     margin: auto;
1449   }
1450
1451   blockquote {
1452     border-left: $lineheight solid $offwhite;
1453     padding-left: $lineheight;
1454     margin: 0;
1455     color: $darkgrey;
1456   }
1457 }
1458
1459 /* Rules for the user notes list */
1460
1461 .note_list {
1462   tr.creator {
1463     background-color: $offwhite;
1464   }
1465 }
1466
1467 /* Rules for the iD editor */
1468
1469 .id-embed {
1470   width: 100%;
1471   height: 100%;
1472 }
1473
1474 /* Rules for the "Welcome" page */
1475 .site-welcome, .site-fixthemap {
1476   .sprite {
1477     background-image: image-url("welcome-sprite.png");
1478     background-size: 500px 250px;
1479     display: block;
1480   }
1481
1482   .icon-list {
1483     padding-bottom: 20px;
1484     div {
1485       margin-bottom: 10px;
1486       p {
1487         padding-top: 10px;
1488       }
1489     }
1490   }
1491   .sprite.small {
1492     width: 50px;
1493     height: 50px;
1494   }
1495
1496   .sprite.x {
1497     /* no-r2 */ background-position: -50px 0;
1498   }
1499
1500   .sprite.term {
1501     margin-right: 10px;
1502     vertical-align: middle;
1503   }
1504
1505   .sprite.node {
1506     /* no-r2 */ background-position: -100px 0;
1507   }
1508
1509   .sprite.way {
1510     /* no-r2 */ background-position: -150px 0;
1511   }
1512
1513   .sprite.tag {
1514     /* no-r2 */ background-position: -200px 0;
1515   }
1516
1517   .sprite.editor {
1518     /* no-r2 */ background-position: -250px 0;
1519   }
1520
1521   .sprite.question {
1522     /* no-r2 */ background-position: -300px 0;
1523   }
1524
1525   .sprite.rules {
1526     /* no-r2 */ background-position: -350px 0;
1527   }
1528
1529   .icon.note {
1530     background-color: #333;
1531     border-radius: 4px;
1532   }
1533 }
1534
1535 .site-about #content {
1536   background-color: $lightgrey;
1537   background-position: 50% 50%;
1538   background-repeat: no-repeat;
1539   background-size: cover;
1540   background-attachment: fixed;
1541
1542   .content-inner {
1543     max-width: 760px;
1544   }
1545
1546   .attr {
1547     margin-top: -20px;
1548
1549     h1 {
1550       span {
1551         color: $vibrant-green;
1552       }
1553     }
1554
1555     .user-image {
1556       height: 150px;
1557       background-position: 0 50%;
1558       background-repeat: no-repeat;
1559       background-image: image-url('about/osm.png');
1560       background-size: cover;
1561       background-color: $vibrant-green;
1562     }
1563
1564     .byosm {
1565       background: $vibrant-green;
1566     }
1567
1568     .byosm span {
1569       display: inline-block;
1570       width: 1em;
1571       margin-left: -1em;
1572     }
1573   }
1574
1575   .icon {
1576     width: 30px;
1577     height: 30px;
1578     margin-right: 10px;
1579     vertical-align: middle;
1580     background: 40px 40px image-url('about/sprite.png') no-repeat;
1581
1582     &.local {
1583       /* no-r2 */
1584       background-position: 0px 0px;
1585     }
1586     &.community {
1587       /* no-r2 */
1588       background-position: 0px -40px;
1589     }
1590     &.open {
1591       /* no-r2 */
1592       background-position: 0px -80px;
1593     }
1594     &.partners {
1595       /* no-r2 */
1596       background-position: 0px -120px;
1597     }
1598     &.infringement {
1599       /* no-r2 */
1600       background-position: 0px -160px;
1601     }
1602     &.legal {
1603       /* no-r2 */
1604       background-position: -45px -160px;
1605     }
1606   }
1607 }
1608
1609 @import 'browse';
1610
1611 @media only screen and (max-width:960px) {
1612   .header-illustration.new-user-arm {
1613     display: none;
1614   }
1615 }