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 .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; }
64 /* Utility for de-emphasizing content */
70 /* Rules for borders */
71 /* These add additional colours to those provided by bootstrap */
73 border-color: $grey !important;
77 border-color: $lightgrey !important;
80 /* Rules for the header */
83 display: none !important;
85 background: image-url("menu-icon.png") no-repeat;
86 background-size: 30px 30px;
90 margin: 14px 10px 0 0;
95 height: $headerHeight;
100 h1, nav, nav > ul, nav > ul > li {
101 display: inline-block;
106 padding: $lineheight/2;
114 text-decoration: none;
121 vertical-align: middle;
147 .btn-outline-primary {
148 @include button-outline-variant($green, $color-hover: $white, $active-color: $white);
152 .btn-outline-primary {
157 border-top-color: $grey;
161 background-color: lighten($green, 30%);
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;
173 box-shadow: 0 0 0 0.2rem fade-out($green, 0.5);
188 color: darken($darkgrey, 25%);
192 .btn-outline-secondary {
193 @include button-outline-variant($darkgrey, $color-hover: $white, $active-color: $white);
198 .btn-outline-secondary {
199 @include button-outline-variant($darkgrey, $color-hover: $darkgrey, $active-background: white, $active-border: $darkgrey);
208 display: inline-block;
210 margin: 3px 0 3px 3px;
211 background-color: lighten($grey, 10%);
223 nav.primary, nav.secondary {
226 background-color: $green;
232 #compact-secondary-nav {
237 #compact-secondary-nav {
238 display: inline-block;
247 display: inline-block !important;
252 float: none !important;
260 min-height: $headerHeight;
272 #sidebar .search_forms,
288 border-top: 1px solid #eee;
290 border-bottom: 1px solid #eee;
313 #compact-secondary-nav {
318 display: inline-block;
321 .overlay-sidebar #sidebar .welcome.visible {
325 .overlay-sidebar #sidebar #banner {
329 .leaflet-top.leaflet-right {
330 top: 10px !important;
334 /* Utility for styling notification numbers */
337 padding: 2px $lineheight/4;
339 background: lighten($green, 30%);
345 /* Rules for the message shown in place of the map when javascript is disabled */
353 /* Rules for Leaflet maps */
355 .leaflet-control .control-button {
359 background-color: #333;
360 background-color: rgba(0,0,0,.6);
361 border-radius: 4px 0 0 4px;
367 background-color: black;
372 background-color: #333;
373 background-color: rgba(0,0,0,.5);
378 background-color: $vibrant-green;
386 .leaflet-control .zoomin,
387 .control-layers .control-button {
389 border-radius: 4px 0 0 0;
392 .leaflet-control .zoomout,
393 .control-key .control-button {
398 .control-locate .control-button,
399 .control-share .control-button {
400 border-radius: 0 0 0 4px;
403 /* Rules for the sidebar and main map area */
423 width: $sidebarWidth;
442 .overlay-sidebar #sidebar {
479 width: $sidebarWidth;
495 .leaflet-marker-draggable {
510 border-bottom: 1px solid $grey;
520 border:1px solid $grey;
525 border: 1px solid $grey;
527 border-top-color: $grey;
533 @include media-breakpoint-down(md) {
581 border: 2px solid #fff;
584 transition: border-color 0.08s ease-in;
591 border-bottom-right-radius: 3px;
595 text-stroke: 2px #fff;
596 background: rgba(255,255,255,.9);
598 input[type="radio"] {
603 &.active { border-color: darken($green, 10%); }
606 &.active { border-color: darken($green, 20%); }
616 li.disabled { color: $darkgrey; }
626 text-decoration: none;
627 background-color: $lightblue;
629 border-right: 1px solid #fff;
633 border-right: 1px solid #fff;
634 border-radius: 4px 0 0 4px;
638 border-radius: 0 4px 4px 0;
642 background-color: $blue;
654 font-family: monospace;
676 top: $lineheight/2 !important;
678 margin-right: 0px !important;
679 margin-top: 0px !important;
683 .leaflet-popup-scrolled {
684 padding-right: $lineheight;
685 border-bottom: 0px !important;
686 border-top: 0px !important;
689 .leaflet-popup-content-wrapper {
690 border-radius: 4px !important;
693 /* Rules for attribution text under the main map shown on printouts */
703 .attribution_license,
704 .attribution_project {
708 .attribution_notice {
712 .donate-attr { color: darken($green, 10%) !important; }
714 /* Rules for the sidebar */
718 padding: $lineheight/2 $lineheight;
719 // background: $offwhite;
720 // border-bottom: 1px solid $grey;
739 margin: $lineheight auto;
750 /* Temporary label size override until we remove site-wide font customisation */
758 /* Stop bootstrap 5 from floating legends when they don't need to be */
763 /* Override the text colour for primary and secondary buttons, to match our
764 bootstrap 4 colours. Note this has accessibility issues, which is why
765 bootstrap 5 calculates black as the appropriate colour, and we should
766 reconsider our colours at some point with that in mind. */
769 @include button-variant($primary, $primary, $color: $white, $hover-color: $white, $active-color: $white, $disabled-color: $white);
773 @include button-variant($secondary, $secondary, $color: $white, $hover-color: $white, $active-color: $white, $disabled-color: $white);
776 .btn-outline-secondary {
777 @include button-outline-variant($secondary, $color-hover: $white, $active-color: $white);
780 /* Rules for the search and direction forms */
782 header .search_forms,
787 /* Rules for the map key which appears in the popout sidebar */
790 .mapkey-table-key img {
797 /* Rules for search sidebar */
799 #sidebar .search_results_entry {
802 &.selected { background: $list-highlight; }
805 .search_more .loader {
811 .search_results_error {
816 /* Rules for routing */
819 background-image: image-url('routing-sprite.png');
822 background-repeat: no-repeat;
824 @for $i from 0 through 25 {
825 div.direction.i#{$i} { background-position: #{($i)*-20}px 0px; }
828 td.instruction, td.distance {
829 padding-top: $lineheight/5;
830 padding-bottom: $lineheight/5;
831 border-bottom: 1px solid $grey;
842 background: $list-highlight;
845 .routing_marker { width: 15px; cursor: move; }
847 /* Rules for entity history */
852 border-bottom: $keyline;
860 /* Rules for the history sidebar */
862 #sidebar .changesets {
864 &.selected { background: $list-highlight; }
865 /* color is derived from changeset bbox fillColor in history.js */
867 a.stretched-link > span, a:not(.stretched-link), [title] {
869 z-index: 2; /* needs to be higher than Bootstrap's stretched link ::after z-index */
881 .changeset_more .loader {
887 /* Rules for the browse sidebar */
891 padding-bottom: $spacer;
892 margin-bottom: $spacer;
893 border-bottom: 1px solid $grey;
896 word-wrap: break-word;
900 .browse-section:last-of-type {
905 background-color: $offwhite;
907 border-collapse: separate;
910 margin-bottom: $spacer;
913 border-bottom: 1px solid $grey;
916 tr:last-child th, tr:last-child td {
924 word-wrap: break-word;
925 white-space: pre-wrap;
930 background-color: $offwhite;
934 border-left: 1px solid $grey;
935 background-color: #fff;
938 .colour-preview-box {
943 border: 1px solid rgba(0, 0, 0, .1);
944 // add color via inline css on element: background-color: <tag value>;
948 .note-comments li, .changeset-comments li {
949 margin: $lineheight/2 0;
952 margin: 10px 6px 0 6px;
957 .subscribe-buttons input {
963 span.action-button:hover {
965 text-decoration: underline;
970 margin: 0 0 10px 10px;
983 background: $list-highlight;
990 /* Bootstrap buttons don't have any vertical margin, so
991 they touch when adjacent buttons wrap onto a new line
992 e.g. wide form buttons on a narrow sidebar */
996 margin-bottom: $spacer * 0.25;
1000 /* Rules for export sidebar */
1003 .export_area_inputs,
1008 .export_area_inputs {
1009 margin-bottom: $spacer;
1010 input[type="text"] {
1017 background: $lightgrey;
1019 #maxlat { margin-top: -1px; }
1022 /* no-r2 */ margin-left: -1px;
1026 /* no-r2 */ margin-right: -1px;
1028 #minlat { margin-bottom: -1px; }
1032 margin: $lineheight/4;
1036 padding-left: $lineheight/2;
1039 margin-bottom: 10px;
1044 /* Rules for edit pages */
1060 /* Rules for non-map content pages */
1063 background: $lightgrey;
1070 padding: $lineheight;
1073 /* Overrides for pages that use new layout conventions */
1075 .header-illustration {
1076 background-position: 0 0;
1077 background-repeat: no-repeat;
1085 background-image: image-url("sign-up-illustration.png");
1089 background-image: image-url("confirm-illustration.png");
1093 background-image: image-url("terms-illustration.png");
1101 background-image: image-url("sign-up-illustration-arm.png");
1104 pointer-events: none;
1108 [dir=rtl] .header-illustration {
1109 transform: scaleX(-1);
1112 #content.maximised {
1121 /* Rules for small maps in content areas */
1125 margin-bottom: $lineheight;
1128 @include media-breakpoint-up(md) {
1134 /* Rules for the user map */
1136 .content_map .leaflet-popup-content {
1137 margin: $lineheight/2;
1141 /* Rules for user popups on maps */
1147 margin-top: 0 0 0 60px;
1152 /* Rules for the user list */
1158 /* Rules for the diary list page */
1162 padding-top: $lineheight;
1163 padding-bottom: $lineheight/2;
1164 border-top: 1px solid $grey;
1167 background-color: #fee;
1171 /* Rules for the diary entry page */
1177 margin-bottom: $lineheight;
1183 border-top: 1px dashed $grey;
1184 padding-top: $lineheight/2;
1185 padding-bottom: $lineheight/2;
1187 margin-top: $lineheight/2;
1188 padding-top: $lineheight;
1189 border-top: 1px solid $grey;
1192 background-color: #fee;
1195 margin-bottom: $lineheight/2;
1204 /* Rules for the log in page */
1206 #login_auth_buttons {
1211 padding: $lineheight/4 $lineheight/2;
1215 /* Rules for the account confirmation page */
1219 padding: $lineheight;
1220 margin-bottom: $lineheight;
1225 list-style: inherit;
1229 list-style-type: lower-alpha;
1234 /* Rules for the account settings page */
1236 #accountForm .user_image {
1240 #accountForm #user_image {
1244 #accountForm ul.accountImage-options {
1257 display: inline !important;
1260 /* Rules for the oauth settings page */
1262 .oauth_clients .buttons .oauth-edit {
1263 border-radius: 2px 0 0 2px;
1266 .oauth_clients .buttons .oauth-delete {
1267 border-radius: 0 2px 2px 0;
1270 /* Rules for the oauth authorization page */
1272 .oauth-authorize ul {
1276 /* Rules for messages pages */
1279 button[type="submit"] {
1281 white-space: nowrap;
1285 background: $offwhite;
1289 background: #CBEEA7;
1297 .inbox-row .inbox-mark-read {
1302 margin-bottom: $lineheight;
1303 padding: $lineheight/4 0px 4px 0px;
1304 border-bottom: 1px solid $grey;
1311 .info-line .user_thumbnail_tiny {
1312 vertical-align: middle;
1316 white-space: nowrap;
1325 .inbox-row-unread .inbox-mark-unread {
1329 /* Rules for "flash" notice boxes shown at the top of the content area */
1333 background-color: #ff7070;
1337 background-color: #ffe0cc;
1341 background-color: #CBEEA7;
1345 /* Rules for highlighting fields with rails validation errors */
1348 display: inline-block;
1354 background-color: #ff7070;
1357 /* Rules for rails validation error boxes */
1361 border: 2px solid #ff7070;
1362 padding: 0 $lineheight/2;
1363 margin-bottom: $lineheight;
1364 background-color: #f0f0f0;
1367 margin: 0 -10px 10px -10px;
1368 padding: $lineheight/4 $lineheight/4 $lineheight/4 15px;
1371 background-color: #c00;
1379 padding: $lineheight/4;
1384 background-color: $lightgrey;
1386 .describe_location {
1395 background-color: $lightgrey;
1401 vertical-align: middle;
1406 /* Rules for user images */
1413 img.user_thumbnail {
1418 img.user_thumbnail_tiny {
1425 /* Rules for geo microformats */
1428 border-bottom: none;
1431 /* General styles for action lists / subnavs / pager navs */
1434 nav.secondary-actions {
1439 flex-direction: row;
1445 display: inline-block;
1451 border-left: 1px solid $grey;
1452 padding-left: $lineheight/2;
1453 margin-right: $lineheight/2;
1454 margin-bottom: $lineheight/8;
1459 div.secondary-actions {
1466 input[type="submit"],
1467 input[type="button"],
1468 input[type="reset"],
1471 box-sizing: border-box;
1477 border-right:1px solid white;
1478 text-overflow: ellipsis;
1479 white-space: nowrap;
1483 .button:first-child,
1484 .button_to:first-child {
1485 border-radius:2px 0 0 2px;
1489 .button_to:last-child {
1490 border-radius:0 2px 2px 0;
1491 border-right-width: 0;
1495 .button_to:only-child,
1496 *[value="Hide"] + input:last-child,
1497 *[value="Hide"] + .button:last-child,
1498 *[value="Hide"] + .button_to:last-child {
1500 border-right-width: 0;
1502 /* if a 3-button set has a hidden middle button */
1503 *[value="Hide"] + input:nth-child(3),
1504 *[value="Hide"] + .button:nth-child(3),
1505 *[value="Hide"] + .button_to:nth-child(3) {
1506 border-radius:0 2px 2px 0;
1507 border-right-width: 0;
1509 /* if a 3-button set starts with a hidden button */
1510 *[value="Hide"] + input:nth-child(2):not(:last-child),
1511 *[value="Hide"] + .button:nth-child(2):not(:last-child),
1512 *[value="Hide"] + .button_to:nth-child(2):not(:last-child) {
1513 border-radius:2px 0 0 2px;
1514 border-right-width: 1px;
1518 /* Create a single-line dl */
1522 display: inline-block;
1529 /* Rules for OpenID logo */
1532 vertical-align: text-bottom;
1536 /* Rules for rich text */
1541 background: $lightgrey;
1546 background: $lightgrey;
1548 white-space: pre-wrap;
1556 padding: $lineheight;
1557 background-color: $offwhite;
1564 border-left: $lineheight solid $offwhite;
1565 padding-left: $lineheight;
1571 /* Rules for the user notes list */
1575 background-color: $offwhite;
1579 /* Rules for the iD editor */
1586 /* Rules for the "Welcome" page */
1587 .site-welcome, .site-fixthemap {
1589 background-image: image-url("welcome-sprite.png");
1590 background-size: 500px 250px;
1595 padding-bottom: 20px;
1597 margin-bottom: 10px;
1609 /* no-r2 */ background-position: -50px 0;
1614 vertical-align: middle;
1618 /* no-r2 */ background-position: -100px 0;
1622 /* no-r2 */ background-position: -150px 0;
1626 /* no-r2 */ background-position: -200px 0;
1630 /* no-r2 */ background-position: -250px 0;
1634 /* no-r2 */ background-position: -300px 0;
1638 /* no-r2 */ background-position: -350px 0;
1642 background-color: #333;
1647 .site-about #content {
1648 background-color: $lightgrey;
1649 background-position: 50% 50%;
1650 background-repeat: no-repeat;
1651 background-size: cover;
1652 background-attachment: fixed;
1663 color: $vibrant-green;
1669 background-position: 0 50%;
1670 background-repeat: no-repeat;
1671 background-image: image-url('about/osm.png');
1672 background-size: cover;
1673 background-color: $vibrant-green;
1677 background: $vibrant-green;
1681 display: inline-block;
1691 vertical-align: middle;
1692 background: 40px 40px image-url('about/sprite.png') no-repeat;
1696 background-position: 0px 0px;
1700 background-position: 0px -40px;
1704 background-position: 0px -80px;
1708 background-position: 0px -120px;
1712 background-position: 0px -160px;
1716 background-position: -45px -160px;