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, $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, $white, null, null, $white);
198 .btn-outline-secondary {
199 @include button-outline-variant($darkgrey, $darkgrey, white, $darkgrey);
205 background-color: white;
209 &.show .btn-outline-secondary {
210 background-color: white;
218 display: inline-block;
220 margin: 3px 0 3px 3px;
221 background-color: lighten($grey, 10%);
233 nav.primary, nav.secondary {
236 background-color: $green;
242 #compact-secondary-nav {
247 #compact-secondary-nav {
248 display: inline-block;
255 /* Utility for styling notification numbers */
258 padding: 2px $lineheight/4;
260 background: lighten($green, 30%);
266 /* Rules for the message shown in place of the map when javascript is disabled */
274 /* Rules for Leaflet maps */
276 .leaflet-control .control-button {
280 background-color: #333;
281 background-color: rgba(0,0,0,.6);
282 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;
363 .overlay-sidebar #sidebar {
400 width: $sidebarWidth;
416 .leaflet-marker-draggable {
431 border-bottom: 1px solid $grey;
441 border:1px solid $grey;
446 border: 1px solid $grey;
448 border-top-color: $grey;
472 border: 2px solid #fff;
475 transition: border-color 0.08s ease-in;
482 border-bottom-right-radius: 3px;
486 text-stroke: 2px #fff;
487 background: rgba(255,255,255,.9);
489 input[type="radio"] {
494 &.active { border-color: darken($green, 10%); }
497 &.active { border-color: darken($green, 20%); }
507 li.disabled { color: $darkgrey; }
517 text-decoration: none;
518 background-color: $lightblue;
520 border-right: 1px solid #fff;
524 border-right: 1px solid #fff;
525 border-radius: 4px 0 0 4px;
529 border-radius: 0 4px 4px 0;
533 background-color: $blue;
545 font-family: monospace;
567 top: $lineheight/2 !important;
569 margin-right: 0px !important;
570 margin-top: 0px !important;
574 .leaflet-popup-scrolled {
575 padding-right: $lineheight;
576 border-bottom: 0px !important;
577 border-top: 0px !important;
580 .leaflet-popup-content-wrapper {
581 border-radius: 4px !important;
584 /* Rules for attribution text under the main map shown on printouts */
594 .attribution_license,
595 .attribution_project {
599 .attribution_notice {
603 .donate-attr { color: darken($green, 10%) !important; }
605 /* Rules for the sidebar */
609 padding: $lineheight/2 $lineheight;
610 // background: $offwhite;
611 // border-bottom: 1px solid $grey;
630 margin: $lineheight auto;
641 /* Temporary label size override until we remove site-wide font customisation */
649 /* Stop bootstrap 5 from floating legends when they don't need to be */
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. */
660 @include button-variant($primary, $primary, $white, null, null, $white, null, null, $white, null, null, $white);
664 @include button-variant($secondary, $secondary, $white, null, null, $white, null, null, $white, null, null, $white);
667 .btn-outline-secondary {
668 @include button-outline-variant($secondary, $white, null, null, $white);
671 /* Rules for the search and direction forms */
673 header .search_forms,
678 /* Rules for the map key which appears in the popout sidebar */
681 .mapkey-table-key img {
688 /* Rules for search sidebar */
690 #sidebar .search_results_entry {
693 &.selected { background: $list-highlight; }
696 .search_more .loader {
702 .search_results_error {
707 /* Rules for routing */
710 background-image: image-url('routing-sprite.png');
713 background-repeat: no-repeat;
715 @for $i from 0 through 25 {
716 div.direction.i#{$i} { background-position: #{($i)*-20}px 0px; }
719 td.instruction, td.distance {
720 padding-top: $lineheight/5;
721 padding-bottom: $lineheight/5;
722 border-bottom: 1px solid $grey;
733 background: $list-highlight;
736 .routing_marker { width: 15px; cursor: move; }
738 /* Rules for entity history */
743 border-bottom: $keyline;
751 /* Rules for the history sidebar */
753 #sidebar .changesets {
757 &.selected { background: $list-highlight; }
758 /* color is derived from changeset bbox fillColor in history.js */
769 .changeset_more .loader {
775 /* Rules for the browse sidebar */
779 padding-bottom: $spacer;
780 margin-bottom: $spacer;
781 border-bottom: 1px solid $grey;
784 word-wrap: break-word;
788 .browse-section:last-of-type {
793 background-color: $offwhite;
795 border-collapse: separate;
798 margin-bottom: $spacer;
801 border-bottom: 1px solid $grey;
804 tr:last-child th, tr:last-child td {
812 word-wrap: break-word;
813 white-space: pre-wrap;
818 background-color: $offwhite;
822 border-left: 1px solid $grey;
823 background-color: #fff;
826 .colour-preview-box {
831 border: 1px solid rgba(0, 0, 0, .1);
832 // add color via inline css on element: background-color: <tag value>;
836 .note-comments li, .changeset-comments li {
837 margin: $lineheight/2 0;
840 margin: 10px 6px 0 6px;
845 .subscribe-buttons input {
851 span.action-button:hover {
853 text-decoration: underline;
858 margin: 0 0 10px 10px;
871 background: $list-highlight;
878 /* Bootstrap buttons don't have any vertical margin, so
879 they touch when adjacent buttons wrap onto a new line
880 e.g. wide form buttons on a narrow sidebar */
884 margin-bottom: $spacer * 0.25;
888 /* Rules for export sidebar */
896 .export_area_inputs {
897 margin-bottom: $spacer;
905 background: $lightgrey;
907 #maxlat { margin-top: -1px; }
910 /* no-r2 */ margin-left: -1px;
914 /* no-r2 */ margin-right: -1px;
916 #minlat { margin-bottom: -1px; }
920 margin: $lineheight/4;
924 padding-left: $lineheight/2;
932 /* Rules for edit pages */
948 /* Rules for non-map content pages */
951 background: $lightgrey;
958 padding: $lineheight;
961 /* Overrides for pages that use new layout conventions */
963 .header-illustration {
964 background-position: 0 0;
965 background-repeat: no-repeat;
973 background-image: image-url("sign-up-illustration.png");
977 background-image: image-url("confirm-illustration.png");
981 background-image: image-url("terms-illustration.png");
989 background-image: image-url("sign-up-illustration-arm.png");
992 pointer-events: none;
996 [dir=rtl] .header-illustration {
997 transform: scaleX(-1);
1000 #content.maximised {
1009 /* Rules for small maps in content areas */
1013 margin-bottom: $lineheight;
1016 @include media-breakpoint-up(md) {
1022 /* Rules for the user map */
1024 .content_map .leaflet-popup-content {
1025 margin: $lineheight/2;
1029 /* Rules for user popups on maps */
1035 margin-top: 0 0 0 60px;
1040 /* Rules for the user list */
1046 /* Rules for the diary list page */
1050 padding-top: $lineheight;
1051 padding-bottom: $lineheight/2;
1052 border-top: 1px solid $grey;
1055 background-color: #fee;
1059 /* Rules for the diary entry page */
1065 margin-bottom: $lineheight;
1071 border-top: 1px dashed $grey;
1072 padding-top: $lineheight/2;
1073 padding-bottom: $lineheight/2;
1075 margin-top: $lineheight/2;
1076 padding-top: $lineheight;
1077 border-top: 1px solid $grey;
1080 background-color: #fee;
1083 margin-bottom: $lineheight/2;
1092 /* Rules for the log in page */
1094 #login_auth_buttons {
1099 padding: $lineheight/4 $lineheight/2;
1103 /* Rules for the account confirmation page */
1107 padding: $lineheight;
1108 margin-bottom: $lineheight;
1113 list-style: inherit;
1117 list-style-type: lower-alpha;
1122 /* Rules for the account settings page */
1124 #accountForm .user_image {
1128 #accountForm #user_image {
1132 #accountForm ul.accountImage-options {
1145 display: inline !important;
1148 /* Rules for the oauth settings page */
1150 .oauth_clients .buttons .oauth-edit {
1151 border-radius: 2px 0 0 2px;
1154 .oauth_clients .buttons .oauth-delete {
1155 border-radius: 0 2px 2px 0;
1158 /* Rules for the oauth authorization page */
1160 .oauth-authorize ul {
1164 /* Rules for messages pages */
1167 button[type="submit"] {
1169 white-space: nowrap;
1173 background: $offwhite;
1177 background: #CBEEA7;
1185 .inbox-row .inbox-mark-read {
1190 margin-bottom: $lineheight;
1191 padding: $lineheight/4 0px 4px 0px;
1192 border-bottom: 1px solid $grey;
1199 .info-line .user_thumbnail_tiny {
1200 vertical-align: middle;
1204 white-space: nowrap;
1213 .inbox-row-unread .inbox-mark-unread {
1217 /* Rules for "flash" notice boxes shown at the top of the content area */
1221 background-color: #ff7070;
1225 background-color: #ffe0cc;
1229 background-color: #CBEEA7;
1233 /* Rules for highlighting fields with rails validation errors */
1236 display: inline-block;
1242 background-color: #ff7070;
1245 /* Rules for rails validation error boxes */
1249 border: 2px solid #ff7070;
1250 padding: 0 $lineheight/2;
1251 margin-bottom: $lineheight;
1252 background-color: #f0f0f0;
1255 margin: 0 -10px 10px -10px;
1256 padding: $lineheight/4 $lineheight/4 $lineheight/4 15px;
1259 background-color: #c00;
1267 padding: $lineheight/4;
1272 background-color: $lightgrey;
1274 .describe_location {
1283 background-color: $lightgrey;
1289 vertical-align: middle;
1293 a.reverse_directions {
1298 /* Rules for user images */
1305 img.user_thumbnail {
1310 img.user_thumbnail_tiny {
1317 /* Rules for geo microformats */
1320 border-bottom: none;
1323 /* General styles for action lists / subnavs / pager navs */
1326 nav.secondary-actions {
1331 flex-direction: row;
1337 display: inline-block;
1343 border-left: 1px solid $grey;
1344 padding-left: $lineheight/2;
1345 margin-right: $lineheight/2;
1346 margin-bottom: $lineheight/8;
1351 div.secondary-actions {
1358 input[type="submit"],
1359 input[type="button"],
1360 input[type="reset"],
1363 box-sizing: border-box;
1369 border-right:1px solid white;
1370 text-overflow: ellipsis;
1371 white-space: nowrap;
1375 .button:first-child,
1376 .button_to:first-child {
1377 border-radius:2px 0 0 2px;
1381 .button_to:last-child {
1382 border-radius:0 2px 2px 0;
1383 border-right-width: 0;
1387 .button_to:only-child,
1388 *[value="Hide"] + input:last-child,
1389 *[value="Hide"] + .button:last-child,
1390 *[value="Hide"] + .button_to:last-child {
1392 border-right-width: 0;
1394 /* if a 3-button set has a hidden middle button */
1395 *[value="Hide"] + input:nth-child(3),
1396 *[value="Hide"] + .button:nth-child(3),
1397 *[value="Hide"] + .button_to:nth-child(3) {
1398 border-radius:0 2px 2px 0;
1399 border-right-width: 0;
1401 /* if a 3-button set starts with a hidden button */
1402 *[value="Hide"] + input:nth-child(2):not(:last-child),
1403 *[value="Hide"] + .button:nth-child(2):not(:last-child),
1404 *[value="Hide"] + .button_to:nth-child(2):not(:last-child) {
1405 border-radius:2px 0 0 2px;
1406 border-right-width: 1px;
1410 /* Create a single-line dl */
1414 display: inline-block;
1421 /* Rules for OpenID logo */
1424 vertical-align: text-bottom;
1428 /* Rules for rich text */
1433 background: $lightgrey;
1438 background: $lightgrey;
1440 white-space: pre-wrap;
1448 padding: $lineheight;
1449 background-color: $offwhite;
1456 border-left: $lineheight solid $offwhite;
1457 padding-left: $lineheight;
1463 /* Rules for the user notes list */
1467 background-color: $offwhite;
1471 /* Rules for the iD editor */
1478 /* Rules for the "Welcome" page */
1479 .site-welcome, .site-fixthemap {
1481 background-image: image-url("welcome-sprite.png");
1482 background-size: 500px 250px;
1487 padding-bottom: 20px;
1489 margin-bottom: 10px;
1501 /* no-r2 */ background-position: -50px 0;
1506 vertical-align: middle;
1510 /* no-r2 */ background-position: -100px 0;
1514 /* no-r2 */ background-position: -150px 0;
1518 /* no-r2 */ background-position: -200px 0;
1522 /* no-r2 */ background-position: -250px 0;
1526 /* no-r2 */ background-position: -300px 0;
1530 /* no-r2 */ background-position: -350px 0;
1534 background-color: #333;
1539 .site-about #content {
1540 background-color: $lightgrey;
1541 background-position: 50% 50%;
1542 background-repeat: no-repeat;
1543 background-size: cover;
1544 background-attachment: fixed;
1555 color: $vibrant-green;
1561 background-position: 0 50%;
1562 background-repeat: no-repeat;
1563 background-image: image-url('about/osm.png');
1564 background-size: cover;
1565 background-color: $vibrant-green;
1569 background: $vibrant-green;
1573 display: inline-block;
1583 vertical-align: middle;
1584 background: 40px 40px image-url('about/sprite.png') no-repeat;
1588 background-position: 0px 0px;
1592 background-position: 0px -40px;
1596 background-position: 0px -80px;
1600 background-position: 0px -120px;
1604 background-position: 0px -160px;
1608 background-position: -45px -160px;
1615 @media only screen and (max-width:960px) {
1616 .header-illustration.new-user-arm {