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