3 @import "rails_bootstrap_forms";
5 /* Styles common to large and small screens */
7 /* Default rules for the body of every page */
10 font-size: $typeheight;
22 #container { position: relative; }
25 vertical-align: middle;
26 margin-right: $lineheight/4;
29 [dir=rtl] { /* no-r2 */ text-align: right; }
31 [dir=ltr] { /* no-r2 */ text-align: left; }
36 display: inline-block;
40 background: transparent image-url("sprite.png") no-repeat 0 0;
41 background-image: image-url("sprite.svg");
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 .close-wrap:hover .icon.close,
59 .icon.close:hover { /* no-r2 */ background-position: -200px -20px; }
60 .icon.check { /* no-r2 */ background-position: -220px 0; }
61 .icon.note { /* no-r2 */ background-position: -240px 0; }
62 .icon.note.grey { /* no-r2 */ background-position: -240px -20px; }
63 .icon.query { /* no-r2 */ background-position: -260px 0; }
65 /* Utility for de-emphasizing content */
71 /* Rules for borders */
72 /* These add additional colours to those provided by bootstrap */
74 border-color: $grey !important;
78 border-color: $lightgrey !important;
81 /* Rules for the header */
84 display: none !important;
86 background: image-url("menu-icon.png") no-repeat;
87 background-size: 30px 30px;
91 margin: 14px 10px 0 0;
96 height: $headerHeight;
101 h1, nav, nav > ul, nav > ul > li {
102 display: inline-block;
107 padding: $lineheight/2;
115 text-decoration: none;
122 vertical-align: middle;
148 .btn-outline-primary {
149 @include button-outline-variant($green, $white);
153 .btn-outline-primary {
158 border-top-color: $grey;
162 background-color: lighten($green, 30%);
167 // Small tweaks to the toggle to stop the primary colour showing through
168 // when the menu is shown
169 .show > .btn-outline-primary.dropdown-toggle {
170 background-color: $green;
171 border-color: $green;
174 box-shadow: 0 0 0 0.2rem fade-out($green, 0.5);
189 color: darken($darkgrey, 25%);
193 .btn-outline-secondary {
194 @include button-outline-variant($darkgrey, $white, null, null, $white);
199 .btn-outline-secondary {
200 @include button-outline-variant($darkgrey, $darkgrey, white, $darkgrey);
206 background-color: white;
210 &.show .btn-outline-secondary {
211 background-color: white;
219 display: inline-block;
221 margin: 3px 0 3px 3px;
222 background-color: lighten($grey, 10%);
234 nav.primary, nav.secondary {
237 background-color: $green;
243 #compact-secondary-nav {
248 #compact-secondary-nav {
249 display: inline-block;
256 /* Utility for styling notification numbers */
259 padding: 2px $lineheight/4;
261 background: lighten($green, 30%);
267 /* Rules for the message shown in place of the map when javascript is disabled */
275 /* Rules for Leaflet maps */
277 .leaflet-control .control-button {
281 background-color: #333;
282 background-color: rgba(0,0,0,.6);
283 border-radius: 4px 0 0 4px;
288 background-color: black;
293 background-color: #333;
294 background-color: rgba(0,0,0,.5);
299 background-color: $vibrant-green;
307 .leaflet-control .zoomin,
308 .control-layers .control-button {
310 border-radius: 4px 0 0 0;
313 .leaflet-control .zoomout,
314 .control-key .control-button {
319 .control-locate .control-button,
320 .control-share .control-button {
321 border-radius: 0 0 0 4px;
324 /* Rules for the sidebar and main map area */
344 width: $sidebarWidth;
379 pointer-events: none;
387 .overlay-sidebar #sidebar {
424 width: $sidebarWidth;
440 .leaflet-marker-draggable {
455 border-bottom: 1px solid $grey;
465 border:1px solid $grey;
470 border: 1px solid $grey;
472 border-top-color: $grey;
496 border: 2px solid #fff;
499 transition: border-color 0.08s ease-in;
506 border-bottom-right-radius: 3px;
510 text-stroke: 2px #fff;
511 background: rgba(255,255,255,.9);
513 input[type="radio"] {
518 &.active { border-color: darken($green, 10%); }
521 &.active { border-color: darken($green, 20%); }
531 li.disabled { color: $darkgrey; }
541 text-decoration: none;
542 background-color: $lightblue;
544 border-right: 1px solid #fff;
548 border-right: 1px solid #fff;
549 border-radius: 4px 0 0 4px;
553 border-radius: 0 4px 4px 0;
557 background-color: $blue;
569 font-family: monospace;
591 top: $lineheight/2 !important;
593 margin-right: 0px !important;
594 margin-top: 0px !important;
598 .leaflet-popup-scrolled {
599 padding-right: $lineheight;
600 border-bottom: 0px !important;
601 border-top: 0px !important;
604 .leaflet-popup-content-wrapper {
605 border-radius: 4px !important;
608 /* Rules for attribution text under the main map shown on printouts */
618 .attribution_license,
619 .attribution_project {
623 .attribution_notice {
627 .donate-attr { color: darken($green, 10%) !important; }
629 /* Rules for the sidebar */
633 padding: $lineheight/2 $lineheight;
634 // background: $offwhite;
635 // border-bottom: 1px solid $grey;
654 margin: $lineheight auto;
665 /* Temporary label size override until we remove site-wide font customisation */
673 /* Stop bootstrap 5 from floating legends when they don't need to be */
678 /* Override the text colour for primary and secondary buttons, to match our
679 bootstrap 4 colours. Note this has accessibility issues, which is why
680 bootstrap 5 calculates black as the appropriate colour, and we should
681 reconsider our colours at some point with that in mind. */
684 @include button-variant($primary, $primary, $white, null, null, $white, null, null, $white, null, null, $white);
688 @include button-variant($secondary, $secondary, $white, null, null, $white, null, null, $white, null, null, $white);
691 .btn-outline-secondary {
692 @include button-outline-variant($secondary, $white, null, null, $white);
695 /* Rules for the search and direction forms */
697 header .search_forms,
702 /* Rules for the map key which appears in the popout sidebar */
705 .mapkey-table-key img {
712 /* Rules for search sidebar */
714 #sidebar .search_results_entry {
717 &.selected { background: $list-highlight; }
720 .search_more .loader {
726 .search_results_error {
731 /* Rules for routing */
734 background-image: image-url('routing-sprite.png');
737 background-repeat: no-repeat;
739 @for $i from 0 through 25 {
740 div.direction.i#{$i} { background-position: #{($i)*-20}px 0px; }
743 td.instruction, td.distance {
744 padding-top: $lineheight/5;
745 padding-bottom: $lineheight/5;
746 border-bottom: 1px solid $grey;
757 background: $list-highlight;
760 .routing_marker { width: 15px; cursor: move; }
762 /* Rules for entity history */
767 border-bottom: $keyline;
775 /* Rules for the history sidebar */
777 #sidebar .changesets {
781 &.selected { background: $list-highlight; }
782 /* color is derived from changeset bbox fillColor in history.js */
793 .changeset_more .loader {
799 /* Rules for the browse sidebar */
803 padding-bottom: $spacer;
804 margin-bottom: $spacer;
805 border-bottom: 1px solid $grey;
808 word-wrap: break-word;
812 .browse-section:last-of-type {
817 background-color: $offwhite;
819 border-collapse: separate;
822 margin-bottom: $spacer;
825 border-bottom: 1px solid $grey;
828 tr:last-child th, tr:last-child td {
836 word-wrap: break-word;
837 white-space: pre-wrap;
842 background-color: $offwhite;
846 border-left: 1px solid $grey;
847 background-color: #fff;
850 .colour-preview-box {
855 border: 1px solid rgba(0, 0, 0, .1);
856 // add color via inline css on element: background-color: <tag value>;
860 .note-comments li, .changeset-comments li {
861 margin: $lineheight/2 0;
864 margin: 10px 6px 0 6px;
869 .subscribe-buttons input {
875 span.action-button:hover {
877 text-decoration: underline;
882 margin: 0 0 10px 10px;
895 background: $list-highlight;
902 /* Bootstrap buttons don't have any vertical margin, so
903 they touch when adjacent buttons wrap onto a new line
904 e.g. wide form buttons on a narrow sidebar */
908 margin-bottom: $spacer * 0.25;
912 /* Rules for export sidebar */
920 .export_area_inputs {
921 margin-bottom: $spacer;
929 background: $lightgrey;
931 #maxlat { margin-top: -1px; }
934 /* no-r2 */ margin-left: -1px;
938 /* no-r2 */ margin-right: -1px;
940 #minlat { margin-bottom: -1px; }
944 margin: $lineheight/4;
948 padding-left: $lineheight/2;
956 /* Rules for edit pages */
972 /* Rules for non-map content pages */
975 background: $lightgrey;
982 padding: $lineheight;
985 /* Overrides for pages that use new layout conventions */
987 .header-illustration {
988 background-position: 0 0;
989 background-repeat: no-repeat;
997 background-image: image-url("sign-up-illustration.png");
1001 background-image: image-url("confirm-illustration.png");
1005 background-image: image-url("terms-illustration.png");
1013 background-image: image-url("sign-up-illustration-arm.png");
1016 pointer-events: none;
1020 [dir=rtl] .header-illustration {
1021 transform: scaleX(-1);
1024 #content.maximised {
1033 /* Rules for small maps in content areas */
1037 margin-bottom: $lineheight;
1040 @include media-breakpoint-up(md) {
1046 /* Rules for the user map */
1048 .content_map .leaflet-popup-content {
1049 margin: $lineheight/2;
1053 /* Rules for user popups on maps */
1059 margin-top: 0 0 0 60px;
1064 /* Rules for the user list */
1070 /* Rules for the diary list page */
1074 padding-top: $lineheight;
1075 padding-bottom: $lineheight/2;
1076 border-top: 1px solid $grey;
1079 background-color: #fee;
1083 /* Rules for the diary entry page */
1089 margin-bottom: $lineheight;
1095 border-top: 1px dashed $grey;
1096 padding-top: $lineheight/2;
1097 padding-bottom: $lineheight/2;
1099 margin-top: $lineheight/2;
1100 padding-top: $lineheight;
1101 border-top: 1px solid $grey;
1104 background-color: #fee;
1107 margin-bottom: $lineheight/2;
1116 /* Rules for the log in page */
1118 #login_auth_buttons {
1123 padding: $lineheight/4 $lineheight/2;
1127 /* Rules for the account confirmation page */
1131 padding: $lineheight;
1132 margin-bottom: $lineheight;
1137 list-style: inherit;
1141 list-style-type: lower-alpha;
1146 /* Rules for the account settings page */
1148 #accountForm .user_image {
1152 #accountForm #user_image {
1156 #accountForm ul.accountImage-options {
1169 display: inline !important;
1172 /* Rules for the oauth settings page */
1174 .oauth_clients .buttons .oauth-edit {
1175 border-radius: 2px 0 0 2px;
1178 .oauth_clients .buttons .oauth-delete {
1179 border-radius: 0 2px 2px 0;
1182 /* Rules for the oauth authorization page */
1184 .oauth-authorize ul {
1188 /* Rules for messages pages */
1191 button[type="submit"] {
1193 white-space: nowrap;
1197 background: $offwhite;
1201 background: #CBEEA7;
1209 .inbox-row .inbox-mark-read {
1214 margin-bottom: $lineheight;
1215 padding: $lineheight/4 0px 4px 0px;
1216 border-bottom: 1px solid $grey;
1223 .info-line .user_thumbnail_tiny {
1224 vertical-align: middle;
1228 white-space: nowrap;
1237 .inbox-row-unread .inbox-mark-unread {
1241 /* Rules for "flash" notice boxes shown at the top of the content area */
1245 background-color: #ff7070;
1249 background-color: #ffe0cc;
1253 background-color: #CBEEA7;
1257 /* Rules for highlighting fields with rails validation errors */
1260 display: inline-block;
1266 background-color: #ff7070;
1269 /* Rules for rails validation error boxes */
1273 border: 2px solid #ff7070;
1274 padding: 0 $lineheight/2;
1275 margin-bottom: $lineheight;
1276 background-color: #f0f0f0;
1279 margin: 0 -10px 10px -10px;
1280 padding: $lineheight/4 $lineheight/4 $lineheight/4 15px;
1283 background-color: #c00;
1291 padding: $lineheight/4;
1296 background-color: $lightgrey;
1298 .describe_location {
1307 background-color: $lightgrey;
1313 vertical-align: middle;
1317 a.reverse_directions {
1322 /* Rules for user images */
1329 img.user_thumbnail {
1334 img.user_thumbnail_tiny {
1341 /* Rules for geo microformats */
1344 border-bottom: none;
1347 /* General styles for action lists / subnavs / pager navs */
1350 nav.secondary-actions {
1355 flex-direction: row;
1361 display: inline-block;
1367 border-left: 1px solid $grey;
1368 padding-left: $lineheight/2;
1369 margin-right: $lineheight/2;
1370 margin-bottom: $lineheight/8;
1375 div.secondary-actions {
1382 input[type="submit"],
1383 input[type="button"],
1384 input[type="reset"],
1387 box-sizing: border-box;
1393 border-right:1px solid white;
1394 text-overflow: ellipsis;
1395 white-space: nowrap;
1399 .button:first-child,
1400 .button_to:first-child {
1401 border-radius:2px 0 0 2px;
1405 .button_to:last-child {
1406 border-radius:0 2px 2px 0;
1407 border-right-width: 0;
1411 .button_to:only-child,
1412 *[value="Hide"] + input:last-child,
1413 *[value="Hide"] + .button:last-child,
1414 *[value="Hide"] + .button_to:last-child {
1416 border-right-width: 0;
1418 /* if a 3-button set has a hidden middle button */
1419 *[value="Hide"] + input:nth-child(3),
1420 *[value="Hide"] + .button:nth-child(3),
1421 *[value="Hide"] + .button_to:nth-child(3) {
1422 border-radius:0 2px 2px 0;
1423 border-right-width: 0;
1425 /* if a 3-button set starts with a hidden button */
1426 *[value="Hide"] + input:nth-child(2):not(:last-child),
1427 *[value="Hide"] + .button:nth-child(2):not(:last-child),
1428 *[value="Hide"] + .button_to:nth-child(2):not(:last-child) {
1429 border-radius:2px 0 0 2px;
1430 border-right-width: 1px;
1434 /* Create a single-line dl */
1438 display: inline-block;
1445 /* Rules for OpenID logo */
1448 vertical-align: text-bottom;
1452 /* Rules for rich text */
1458 background: $lightgrey;
1464 background: $lightgrey;
1466 white-space: pre-wrap;
1474 padding: $lineheight;
1475 background-color: $offwhite;
1482 border-left: $lineheight solid $offwhite;
1483 padding-left: $lineheight;
1489 /* Rules for the user notes list */
1493 background-color: $offwhite;
1497 /* Rules for the iD editor */
1504 /* Rules for the "Welcome" page */
1505 .site-welcome, .site-fixthemap {
1515 background-image: image-url("welcome-sprite.png");
1516 background-size: 500px 250px;
1522 padding-bottom: 20px;
1524 margin-bottom: 10px;
1536 /* no-r2 */ background-position: -50px 0;
1541 vertical-align: middle;
1545 /* no-r2 */ background-position: -100px 0;
1549 /* no-r2 */ background-position: -150px 0;
1553 /* no-r2 */ background-position: -200px 0;
1557 /* no-r2 */ background-position: -250px 0;
1561 /* no-r2 */ background-position: -300px 0;
1565 /* no-r2 */ background-position: -350px 0;
1574 text-decoration: none;
1578 background-color: #333;
1583 .site-about #content {
1584 background-color: $lightgrey;
1585 background-position: 50% 50%;
1586 background-repeat: no-repeat;
1587 background-size: cover;
1588 background-attachment: fixed;
1599 color: $vibrant-green;
1605 background-position: 0 50%;
1606 background-repeat: no-repeat;
1607 background-image: image-url('about/osm.png');
1608 background-size: cover;
1609 background-color: $vibrant-green;
1613 background: $vibrant-green;
1617 display: inline-block;
1627 vertical-align: middle;
1628 background: 40px 40px image-url('about/sprite.png') no-repeat;
1632 background-position: 0px 0px;
1636 background-position: 0px -40px;
1640 background-position: 0px -80px;
1644 background-position: 0px -120px;
1648 background-position: 0px -160px;
1652 background-position: -45px -160px;
1659 @media only screen and (max-width:960px) {
1660 .header-illustration.new-user-arm {