]> git.openstreetmap.org Git - rails.git/blob - app/assets/stylesheets/common.scss
Use bootstrap for share forms
[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;
84   float: right;
85   background: image-url("menu-icon.png") no-repeat;
86   background-size: 30px 30px;
87   width: 30px;
88   height: 30px;
89   margin: 14px 10px 0 0;
90   opacity: 0.6;
91 }
92
93 header {
94   height: $headerHeight;
95   position: relative;
96   z-index: 1001;
97   font-size: 14px;
98
99   h1, nav, nav > ul, nav > ul > li {
100     display: inline-block;
101   }
102
103   > * {
104     height: 100%;
105     padding: $lineheight/2;
106   }
107
108   h1, nav.primary {
109     float: left;
110   }
111
112   a, a:hover {
113     text-decoration: none;
114   }
115
116   img.logo {
117     width: 30px;
118     height: 30px;
119     margin-top: -2px;
120     vertical-align: middle;
121   }
122
123   h1 {
124     font-size: 18px;
125     font-weight: 600;
126     line-height: 1.2;
127     margin: 0;
128     padding-top: 15px;
129
130     a {
131       color: #000;
132     }
133
134     a:hover {
135       color: #000;
136     }
137   }
138
139   .btn {
140     font-size: 14px;
141   }
142 }
143
144
145 nav.primary {
146   .btn-outline-primary {
147     @include button-outline-variant($green, $color-hover: $white, $active-color: $white);
148   }
149
150   .disabled {
151     .btn-outline-primary {
152       color: $grey;
153       cursor: default;
154
155       .caret {
156         border-top-color: $grey;
157       }
158
159       &:hover {
160         background-color: lighten($green, 30%);
161       }
162     }
163   }
164
165   // Small tweaks to the toggle to stop the primary colour showing through
166   // when the menu is shown
167   .show > .btn-outline-primary.dropdown-toggle {
168     background-color: $green;
169     border-color: $green;
170
171     &:focus {
172       box-shadow: 0 0 0 0.2rem fade-out($green, 0.5);
173     }
174   }
175 }
176
177 nav.secondary {
178   position: absolute;
179   right: 0;
180
181   .nav-link {
182     padding: 0.2rem;
183     color: $darkgrey;
184   }
185
186   > ul li.current a {
187     color: darken($darkgrey, 25%);
188   }
189
190   .login-menu {
191     .btn-outline-secondary {
192       @include button-outline-variant($darkgrey, $color-hover: $white, $active-color: $white);
193     }
194   }
195
196   .user-menu {
197     .btn-outline-secondary {
198       @include button-outline-variant($darkgrey, $color-hover: $darkgrey, $active-background: white, $active-border: $darkgrey);
199       border-color: $grey;
200       &:hover {
201         border-color: $grey;
202       }
203     }
204   }
205
206   #inboxanchor {
207     background-color: lighten($grey, 10%);
208   }
209 }
210
211 nav.primary, nav.secondary {
212   .dropdown-item {
213     &:hover, &:active {
214       background-color: $green;
215       color: white;
216     }
217   }
218 }
219
220 #compact-secondary-nav {
221   display: none;
222 }
223
224 body.compact-nav {
225   #compact-secondary-nav {
226     display: inline-block;
227   }
228   .compact-hide {
229     display: none;
230   }
231 }
232
233 body.small-nav {
234   #menu-icon {
235     display: block;
236   }
237
238   nav.primary,
239   nav.secondary {
240     float: none !important;
241     position: relative;
242     display: block;
243     clear: both;
244   }
245
246   header {
247     height: auto;
248     min-height: $headerHeight;
249     background: #fff;
250
251     &.closed nav {
252       display: none;
253     }
254
255     .search_forms {
256       display: block;
257     }
258   }
259
260   #sidebar .search_forms,
261   #edit_tab,
262   #export_tab {
263     display: none;
264   }
265
266   nav.primary {
267     padding: 0;
268
269     ul, li {
270       border: none;
271       border-radius: 0;
272       width: 100%;
273     }
274
275     ul {
276       border-top: 1px solid #eee;
277       li {
278         border-bottom: 1px solid #eee;
279         border-right: none;
280         > a {
281           border-radius: 0;
282           width: 100%;
283           text-align: center;
284           font-size: 15px;
285         }
286       }
287     }
288
289     .btn-group {
290       width: 100%;
291       padding: 10px;
292     }
293   }
294
295   nav.secondary {
296     .user-menu, .login-menu {
297       width: 100%;
298     }
299   }
300
301   #compact-secondary-nav {
302     display: none;
303   }
304
305   .compact-hide {
306     display: inline-block;
307   }
308
309   .overlay-sidebar #sidebar .welcome {
310     display: none;
311   }
312
313   .overlay-sidebar #sidebar #banner {
314     display: none;
315   }
316 }
317
318 /* Utility for styling notification numbers */
319
320 .count-number {
321   background: lighten($green, 30%);
322   color: $gray-800;
323   font-weight: $font-weight-normal;
324 }
325
326 /* Rules for the message shown in place of the map when javascript is disabled */
327
328 #noscript {
329   z-index: 20000000;
330   margin-left: 400px;
331   margin-top: 50px;
332 }
333
334 /* Rules for Leaflet maps */
335
336 .leaflet-top.leaflet-right,
337 .leaflet-top.leaflet-left {
338   height: 100%;
339   column-gap: 10px;
340   display: flex;
341   flex-direction: column;
342   flex-wrap: wrap-reverse;
343 }
344
345 .leaflet-control .control-button {
346   display: block;
347   height: 40px;
348   width: 40px;
349   background-color: #333;
350   background-color: rgba(0,0,0,.6);
351   outline: none;
352
353   &:hover,
354   &:focus {
355     background-color: black;
356   }
357
358   &.disabled,
359   &.leaflet-disabled {
360     background-color: #333;
361     background-color: rgba(0,0,0,.5);
362     cursor: default;
363   }
364
365   &.active {
366     background-color: $vibrant-green;
367   }
368
369   &-first {
370     border-start-start-radius: 4px;
371   }
372
373   &-last {
374     border-end-start-radius: 4px;
375     margin-bottom: 10px;
376   }
377
378   .icon {
379     margin: 10px;
380   }
381 }
382
383 /* Rules for the sidebar and main map area */
384
385 .map-layout {
386   #content {
387     overflow: hidden;
388     position: absolute;
389     top: $headerHeight;
390     bottom: 0;
391     width: 100%;
392   }
393
394   #sidebar, #map {
395     position: relative;
396     height: 100%;
397     overflow-x: hidden;
398     overflow-y: auto;
399   }
400
401   #sidebar {
402     float: left;
403     width: $sidebarWidth;
404     background: #fff;
405
406     #sidebar_loader {
407       display: none;
408     }
409
410     #sidebar_content {
411       padding: $spacer;
412     }
413
414     > div {
415       position: relative;
416     }
417   }
418
419   .overlay-sidebar #sidebar {
420     position: absolute;
421     z-index: 1000;
422     height: auto;
423     overflow: hidden;
424
425     #banner {
426       display: block;
427     }
428
429     .welcome {
430       display: block;
431     }
432
433     #sidebar_content {
434       display: none;
435     }
436   }
437
438   .welcome {
439     display: none;
440
441     p {
442       font-size: 110%;
443       font-weight: 300;
444     }
445   }
446
447   #banner {
448     display: none;
449
450     img {
451       display: block;
452       width: $sidebarWidth;
453     }
454
455     button.btn-close {
456       background-color: rgba(255, 255, 255, 0.5);
457       opacity: 1.0;
458     }
459   }
460
461   #map {
462     height: 100%;
463     overflow: hidden;
464
465     &.query-active {
466       cursor: help;
467     }
468
469     &.query-disabled {
470       cursor: not-allowed;
471     }
472
473     .leaflet-marker-draggable {
474       cursor: move;
475     }
476   }
477
478   #map-ui {
479     display: none;
480     position: relative;
481     float: right;
482     width: 250px;
483     height: 100%;
484     background: white;
485     overflow: auto;
486
487     .section {
488       border-bottom: 1px solid $grey;
489       padding: 10px 20px;
490     }
491   }
492 }
493
494 @include media-breakpoint-down(md) {
495   body.map-layout {
496     #sidebar, #map {
497       position: relative;
498       overflow-x: hidden;
499       width: 100%;
500       height: 50%;
501     }
502
503     #map-ui {
504       z-index: 9999;
505       width: 100%;
506       height: 50%;
507       overflow-y: scroll;
508     }
509
510     .overlay-sidebar {
511       #sidebar {
512         position: absolute;
513         width: 350px;
514         height: auto;
515         overflow: hidden;
516       }
517
518       #map, #map-ui {
519         height: 100%;
520       }
521     }
522   }
523 }
524
525 .layers-ui {
526   .base-layers {
527     .leaflet-container {
528       width: 100%;
529       height: 50px;
530       cursor: pointer;
531     }
532
533     li  {
534       overflow: hidden;
535       border-radius: 3px;
536       border: 2px solid #fff;
537       margin-bottom: 8px;
538       position: relative;
539       transition: border-color 0.08s ease-in;
540
541       label {
542         position: absolute;
543         top: 0;
544         left: 0;
545         padding: 2px 6px;
546         border-bottom-right-radius: 3px;
547         cursor: pointer;
548         font-weight: 600;
549         font-size: 16px;
550         text-stroke: 2px #fff;
551         background: rgba(255,255,255,.9);
552         z-index: 1000;
553         input[type="radio"] {
554           display: none;
555         }
556       }
557
558       &.active { border-color: darken($green, 10%); }
559       &:hover {
560         border-color: $grey;
561         &.active { border-color: darken($green, 20%); }
562       }
563     }
564   }
565
566   .overlay-layers {
567     p {
568       font-size: 13px;
569       margin-bottom: 8px;
570     }
571     li.disabled { color: $darkgrey; }
572   }
573 }
574
575 .share-ui {
576   .share-link {
577     input[type=text],
578     textarea {
579       width: 100%;
580       font-family: monospace;
581       font-size: small;
582       line-height: 1.3;
583     }
584   }
585
586   #mapnik_scale {
587     width: 100px;
588   }
589 }
590
591 .leaflet-top {
592   top: $lineheight/2 !important;
593   .leaflet-control {
594     margin-right: 0px !important;
595     margin-top: 0px !important;
596   }
597 }
598
599 .leaflet-popup-scrolled {
600   padding-right: $lineheight;
601   border-bottom: 0px !important;
602   border-top: 0px !important;
603 }
604
605 .leaflet-popup-content-wrapper {
606   border-radius: 4px !important;
607 }
608
609 /* Rules for attribution text under the main map shown on printouts */
610
611 #attribution {
612   display: none;
613 }
614
615 .donate-attr { color: darken($green, 10%) !important; }
616
617 /* Rules for the sidebar */
618
619 .sidebar_heading {
620   position: relative;
621   padding: $lineheight/2 $lineheight;
622   // background: $offwhite;
623   // border-bottom: 1px solid $grey;
624 }
625
626 #browse_status {
627   input {
628     display: block;
629     margin-left: auto;
630     margin-right: auto;
631   }
632
633   > div {
634    padding: $spacer;
635   }
636 }
637
638 /* Temporary label size override until we remove site-wide font customisation */
639
640 form {
641   label {
642     font-size: 16px;
643   }
644   .col-form-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, $color: $white, $hover-color: $white, $active-color: $white, $disabled-color: $white);
661 }
662
663 .btn-secondary {
664   @include button-variant($secondary, $secondary, $color: $white, $hover-color: $white, $active-color: $white, $disabled-color: $white);
665 }
666
667 .btn-outline-secondary {
668   @include button-outline-variant($secondary, $color-hover: $white, $active-color: $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   }
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 .browse_status {
738   display: none;
739 }
740
741 /* Rules for the history sidebar */
742
743 #sidebar .changesets {
744   li {
745     &.selected { background: $list-highlight; }
746     /* color is derived from changeset bbox fillColor in history.js */
747
748     a.stretched-link > span, a:not(.stretched-link), [title] {
749       position: relative;
750       z-index: 2; /* needs to be higher than Bootstrap's stretched link ::after z-index */
751     }
752   }
753
754   .comments {
755     color: $darkgrey;
756   }
757
758   .comments-0 {
759     opacity: 0.5;
760   }
761
762   .changeset_more .loader {
763     display: none;
764     width: 100%;
765   }
766 }
767
768 /* Rules for the browse sidebar */
769
770 #sidebar_content {
771   .browse-section {
772     padding-bottom: $spacer;
773     margin-bottom: $spacer;
774     border-bottom: 1px solid $grey;
775
776     h4:first-child {
777       word-wrap: break-word;
778     }
779   }
780
781   .browse-section:last-of-type {
782     border-bottom: none;
783   }
784
785   .browse-tag-list {
786     background-color: $offwhite;
787     table-layout: fixed;
788     border-collapse: separate;
789     border-spacing: 0;
790     width: 100%;
791     margin-bottom: $spacer;
792
793     th, td {
794       border-bottom: 1px solid $grey;
795     }
796
797     tr:last-child th, tr:last-child td {
798       border-bottom: 0;
799     }
800
801     .browse-tag-k,
802     .browse-tag-v {
803       width: 50%;
804       padding: 6px 10px;
805       word-wrap: break-word;
806       white-space: pre-wrap;
807     }
808
809     .browse-tag-k {
810       font-weight: 500;
811       background-color: $offwhite;
812     }
813
814     .browse-tag-v {
815       border-left: 1px solid $grey;
816       background-color: #fff;
817     }
818
819     .colour-preview-box {
820       float: right;
821       width: 14px;
822       height: 14px;
823       margin: 4px 0px;
824       border: 1px solid rgba(0, 0, 0, .1);
825       // add color via inline css on element: background-color: <tag value>;
826     }
827   }
828
829   .note-comments li, .changeset-comments li {
830     margin: $lineheight/2 0;
831
832     p {
833       margin: 10px 6px 0 6px;
834       line-height: 1.5;
835     }
836   }
837
838   .subscribe-buttons input {
839     font-size: 90%;
840     line-height: 15px;
841     min-height: 20px;
842   }
843
844   span.action-button:hover {
845     cursor: pointer;
846     text-decoration: underline;
847   }
848
849   .note-description {
850     overflow: hidden;
851     margin: 0 0 10px 10px;
852   }
853
854   .query-results {
855     display: none;
856
857     ul {
858       li {
859         &.query-result {
860           cursor: pointer;
861         }
862
863         &.selected {
864           background: $list-highlight;
865         }
866       }
867     }
868   }
869 }
870
871 /* Bootstrap buttons don't have any vertical margin, so
872    they touch when adjacent buttons wrap onto a new line
873    e.g. wide form buttons on a narrow sidebar */
874
875 .btn-wrapper {
876   > .btn {
877     margin-bottom: $spacer * 0.25;
878   }
879 }
880
881 /* Rules for export sidebar */
882
883 .export_form {
884   .export_area_inputs,
885   .export_button {
886     text-align: center;
887   }
888
889   .export_area_inputs {
890     margin-bottom: $spacer;
891     input[type="text"] {
892       width: 100px;
893       text-align: center;
894     }
895   }
896
897   .export_boxy {
898     background: $lightgrey;
899
900     #maxlat { margin-top: -1px; }
901     #minlon {
902       float: left;
903       /* no-r2 */ margin-left: -1px;
904     }
905     #maxlon {
906       float: right;
907       /* no-r2 */ margin-right: -1px;
908     }
909     #minlat { margin-bottom: -1px; }
910   }
911
912   .export_bound {
913     margin: $lineheight/4;
914   }
915
916   dl {
917     padding-left: $lineheight/2;
918     dd {
919       margin-left: 0;
920       margin-bottom: 10px;
921     }
922   }
923 }
924
925 /* Rules for edit pages */
926
927 .site-edit {
928   #content {
929     position: absolute;
930     top: $headerHeight;
931     bottom: 0;
932     width: 100%;
933   }
934
935   #map {
936     height: 100%;
937     overflow: hidden;
938   }
939 }
940
941 /* Rules for non-map content pages */
942
943 .content-heading {
944   background: $lightgrey;
945 }
946
947 .content-inner {
948   position: relative;
949   max-width: 960px;
950   margin: auto;
951   padding: $lineheight;
952 }
953
954 /* Overrides for pages that use new layout conventions */
955
956 .header-illustration {
957   background-position: 0 0;
958   background-repeat: no-repeat;
959   position: relative;
960   min-height: 200px;
961   width: 100%;
962   left: 0;
963   bottom: 0;
964
965   &.new-user-main {
966     background-image: image-url("sign-up-illustration.png");
967   }
968
969   &.confirm-main {
970     background-image: image-url("confirm-illustration.png");
971   }
972
973   &.new-user-terms {
974     background-image: image-url("terms-illustration.png");
975   }
976
977   &.new-user-arm {
978     height: 110px;
979     width: 130px;
980     left: 280px;
981     top: 180px;
982     background-image: image-url("sign-up-illustration-arm.png");
983     position: absolute;
984     z-index: 100;
985     pointer-events: none;
986   }
987 }
988
989 [dir=rtl] .header-illustration {
990   transform: scaleX(-1);
991
992   h1 {
993     transform: scaleX(-1);
994   }
995 }
996
997 #content.maximised {
998   top: 0;
999   left: 0;
1000   right: 0;
1001   bottom: 0;
1002   border: 0;
1003   z-index: 2000;
1004 }
1005
1006 /* Rules for small maps in content areas */
1007
1008 .content_map {
1009   height: 200px;
1010   margin-bottom: $lineheight;
1011 }
1012
1013 @include media-breakpoint-up(md) {
1014   .content_map {
1015     height: 400px;
1016   }
1017 }
1018
1019 /* Rules for the user map */
1020
1021 .content_map .leaflet-popup-content {
1022   margin: $lineheight/2;
1023   min-height: 50px;
1024 }
1025
1026 /* Rules for user popups on maps */
1027
1028 .user_popup {
1029   min-width: 200px;
1030   p {
1031     padding: 0 0 5px 0;
1032     margin: 0 0 0 60px;
1033     font-size: 12px;
1034   }
1035 }
1036
1037 /* Rules for the user list */
1038
1039 #user_list {
1040   width: 100%;
1041 }
1042
1043 /* Rules for the diary entry page */
1044
1045 .diary_entries {
1046   #map {
1047     height: 400px;
1048     display: none;
1049   }
1050   .comments {
1051     max-width: 740px;
1052   }
1053   .diary-comment {
1054     border-top: 1px dashed $grey;
1055     &:first-child {
1056       border-top: 1px solid $grey;
1057     }
1058     p {
1059       margin-bottom: $lineheight/2;
1060     }
1061   }
1062 }
1063
1064 /* Rules for the log in page */
1065
1066 #login_auth_buttons {
1067   margin-bottom: 0;
1068
1069   li {
1070     float: left;
1071     padding: $lineheight/4 $lineheight/2;
1072   }
1073 }
1074
1075 /* Rules for the account confirmation page */
1076
1077 .users-terms {
1078   .legale {
1079     padding: $lineheight;
1080     margin-bottom: $lineheight;
1081     overflow: auto;
1082     height: 20em;
1083
1084     li {
1085       list-style: inherit;
1086     }
1087
1088     ol ol {
1089       list-style-type: lower-alpha;
1090     }
1091   }
1092 }
1093
1094 /* Rules for the oauth authorization page */
1095
1096 .oauth-authorize ul {
1097   list-style: none;
1098 }
1099
1100 /* Rules for messages pages */
1101
1102 .messages {
1103   .inbox-row {
1104     background: $offwhite;
1105   }
1106
1107   .inbox-row-unread {
1108     background: #CBEEA7;
1109   }
1110 }
1111
1112 .search_form {
1113   background-color: $lightgrey;
1114
1115   .describe_location {
1116     top: 6px;
1117     right: 6px;
1118     font-size: 10px;
1119     color: $blue;
1120   }
1121 }
1122
1123 .directions_form {
1124   background-color: $lightgrey;
1125 }
1126
1127 /* Rules for user images */
1128
1129 img.user_image {
1130   max-width: 100px;
1131   max-height: 100px;
1132 }
1133
1134 img.user_thumbnail {
1135   max-width: 50px;
1136   max-height: 50px;
1137 }
1138
1139 img.user_thumbnail_tiny {
1140   width: auto;
1141   height: auto;
1142   max-width: 25px;
1143   max-height: 25px;
1144 }
1145
1146 /* General styles for action lists / subnavs */
1147
1148 nav.secondary-actions {
1149   margin-left: -11px;
1150   overflow: hidden;
1151   > ul {
1152     display: flex;
1153     flex-direction: row;
1154     flex-wrap: wrap;
1155     margin-bottom: 0;
1156     margin-left: -1px;
1157     padding: 0;
1158     > li {
1159       flex-basis: auto;
1160       list-style: none;
1161       border-left: 1px solid $grey;
1162       padding-left: $lineheight/2;
1163       margin-right: $lineheight/2;
1164       margin-bottom: $lineheight/8;
1165     }
1166   }
1167 }
1168
1169 div.secondary-actions {
1170   padding: 10px;
1171   text-align: center;
1172 }
1173
1174 /* Rules for rich text */
1175
1176 .richtext,
1177 .prose {
1178   code {
1179     background: $lightgrey;
1180     padding: 2px 3px;
1181     direction: inherit; /* fix for Bootstrap < 5.2 */
1182     unicode-bidi: unset; /* fix for Bootstrap < 5.2 */
1183   }
1184
1185   pre {
1186     background: $lightgrey;
1187     padding: 2px 3px;
1188     white-space: pre-wrap;
1189
1190     code {
1191       padding: 0;
1192     }
1193   }
1194
1195   img {
1196     padding: $lineheight;
1197     background-color: $offwhite;
1198     display: block;
1199     max-width: 100%;
1200     margin: auto;
1201   }
1202
1203   blockquote {
1204     border-left: $lineheight solid $offwhite;
1205     padding-left: $lineheight;
1206     margin: 0;
1207     color: $darkgrey;
1208   }
1209 }
1210
1211 /* Rules for the iD editor */
1212
1213 .id-embed {
1214   width: 100%;
1215   height: 100%;
1216 }
1217
1218 /* Rules for the "Welcome" page */
1219 .site-welcome, .site-fixthemap {
1220   .sprite {
1221     background-image: image-url("welcome-sprite.png");
1222     background-size: 500px 250px;
1223     display: block;
1224   }
1225
1226   .sprite.small {
1227     width: 50px;
1228     height: 50px;
1229   }
1230
1231   .sprite.x {
1232     /* no-r2 */ background-position: -50px 0;
1233   }
1234
1235   .sprite.term {
1236     margin-right: 10px;
1237     vertical-align: middle;
1238   }
1239
1240   .sprite.node {
1241     /* no-r2 */ background-position: -100px 0;
1242   }
1243
1244   .sprite.way {
1245     /* no-r2 */ background-position: -150px 0;
1246   }
1247
1248   .sprite.tag {
1249     /* no-r2 */ background-position: -200px 0;
1250   }
1251
1252   .sprite.editor {
1253     /* no-r2 */ background-position: -250px 0;
1254   }
1255
1256   .sprite.question {
1257     /* no-r2 */ background-position: -300px 0;
1258   }
1259
1260   .sprite.rules {
1261     /* no-r2 */ background-position: -350px 0;
1262   }
1263
1264   .icon.note {
1265     background-color: #333;
1266     border-radius: 4px;
1267   }
1268 }
1269
1270 .site-about #content {
1271   background-color: $lightgrey;
1272
1273   .content-inner {
1274     max-width: 760px;
1275   }
1276
1277   .attr {
1278     margin-top: -20px;
1279
1280     h1 {
1281       span {
1282         color: $vibrant-green;
1283       }
1284     }
1285
1286     .user-image {
1287       height: 150px;
1288       background-position: 0 50%;
1289       background-repeat: no-repeat;
1290       background-image: image-url('about/osm.png');
1291       background-size: cover;
1292       background-color: $vibrant-green;
1293     }
1294
1295     .byosm {
1296       background: $vibrant-green;
1297     }
1298
1299     .byosm span {
1300       display: inline-block;
1301       width: 1em;
1302       margin-left: -1em;
1303     }
1304   }
1305
1306   .icon {
1307     width: 30px;
1308     height: 30px;
1309     background: 40px 40px image-url('about/sprite.png') no-repeat;
1310
1311     &.local {
1312       /* no-r2 */
1313       background-position: 0px 0px;
1314     }
1315     &.community {
1316       /* no-r2 */
1317       background-position: 0px -40px;
1318     }
1319     &.open {
1320       /* no-r2 */
1321       background-position: 0px -80px;
1322     }
1323     &.partners {
1324       /* no-r2 */
1325       background-position: 0px -120px;
1326     }
1327     &.infringement {
1328       /* no-r2 */
1329       background-position: 0px -160px;
1330     }
1331     &.legal {
1332       /* no-r2 */
1333       background-position: -45px -160px;
1334     }
1335   }
1336 }
1337
1338 @import 'browse';