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;
287 background-color: black;
292 background-color: #333;
293 background-color: rgba(0,0,0,.5);
298 background-color: $vibrant-green;
306 .leaflet-control .zoomin,
307 .control-layers .control-button {
309 border-radius: 4px 0 0 0;
312 .leaflet-control .zoomout,
313 .control-key .control-button {
318 .control-locate .control-button,
319 .control-share .control-button {
320 border-radius: 0 0 0 4px;
323 /* Rules for the sidebar and main map area */
343 width: $sidebarWidth;
362 .overlay-sidebar #sidebar {
399 width: $sidebarWidth;
415 .leaflet-marker-draggable {
430 border-bottom: 1px solid $grey;
440 border:1px solid $grey;
445 border: 1px solid $grey;
447 border-top-color: $grey;
471 border: 2px solid #fff;
474 transition: border-color 0.08s ease-in;
481 border-bottom-right-radius: 3px;
485 text-stroke: 2px #fff;
486 background: rgba(255,255,255,.9);
488 input[type="radio"] {
493 &.active { border-color: darken($green, 10%); }
496 &.active { border-color: darken($green, 20%); }
506 li.disabled { color: $darkgrey; }
516 text-decoration: none;
517 background-color: $lightblue;
519 border-right: 1px solid #fff;
523 border-right: 1px solid #fff;
524 border-radius: 4px 0 0 4px;
528 border-radius: 0 4px 4px 0;
532 background-color: $blue;
544 font-family: monospace;
566 top: $lineheight/2 !important;
568 margin-right: 0px !important;
569 margin-top: 0px !important;
573 .leaflet-popup-scrolled {
574 padding-right: $lineheight;
575 border-bottom: 0px !important;
576 border-top: 0px !important;
579 .leaflet-popup-content-wrapper {
580 border-radius: 4px !important;
583 /* Rules for attribution text under the main map shown on printouts */
593 .attribution_license,
594 .attribution_project {
598 .attribution_notice {
602 .donate-attr { color: darken($green, 10%) !important; }
604 /* Rules for the sidebar */
608 padding: $lineheight/2 $lineheight;
609 // background: $offwhite;
610 // border-bottom: 1px solid $grey;
629 margin: $lineheight auto;
640 /* Temporary label size override until we remove site-wide font customisation */
648 /* Stop bootstrap 5 from floating legends when they don't need to be */
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. */
659 @include button-variant($primary, $primary, $white, null, null, $white, null, null, $white, null, null, $white);
663 @include button-variant($secondary, $secondary, $white, null, null, $white, null, null, $white, null, null, $white);
666 .btn-outline-secondary {
667 @include button-outline-variant($secondary, $white, null, null, $white);
670 /* Rules for the search and direction forms */
672 header .search_forms,
677 /* Rules for the map key which appears in the popout sidebar */
680 .mapkey-table-key img {
687 /* Rules for search sidebar */
689 #sidebar .search_results_entry {
692 &.selected { background: $list-highlight; }
695 .search_more .loader {
701 .search_results_error {
706 /* Rules for routing */
709 background-image: image-url('routing-sprite.png');
712 background-repeat: no-repeat;
714 @for $i from 0 through 25 {
715 div.direction.i#{$i} { background-position: #{($i)*-20}px 0px; }
718 td.instruction, td.distance {
719 padding-top: $lineheight/5;
720 padding-bottom: $lineheight/5;
721 border-bottom: 1px solid $grey;
732 background: $list-highlight;
735 .routing_marker { width: 15px; cursor: move; }
737 /* Rules for entity history */
742 border-bottom: $keyline;
750 /* Rules for the history sidebar */
752 #sidebar .changesets {
756 &.selected { background: $list-highlight; }
757 /* color is derived from changeset bbox fillColor in history.js */
768 .changeset_more .loader {
774 /* Rules for the browse sidebar */
778 padding-bottom: $spacer;
779 margin-bottom: $spacer;
780 border-bottom: 1px solid $grey;
783 word-wrap: break-word;
787 .browse-section:last-of-type {
792 background-color: $offwhite;
794 border-collapse: separate;
797 margin-bottom: $spacer;
800 border-bottom: 1px solid $grey;
803 tr:last-child th, tr:last-child td {
811 word-wrap: break-word;
812 white-space: pre-wrap;
817 background-color: $offwhite;
821 border-left: 1px solid $grey;
822 background-color: #fff;
825 .colour-preview-box {
830 border: 1px solid rgba(0, 0, 0, .1);
831 // add color via inline css on element: background-color: <tag value>;
835 .note-comments li, .changeset-comments li {
836 margin: $lineheight/2 0;
839 margin: 10px 6px 0 6px;
844 .subscribe-buttons input {
850 span.action-button:hover {
852 text-decoration: underline;
857 margin: 0 0 10px 10px;
870 background: $list-highlight;
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 */
883 margin-bottom: $spacer * 0.25;
887 /* Rules for export sidebar */
895 .export_area_inputs {
896 margin-bottom: $spacer;
904 background: $lightgrey;
906 #maxlat { margin-top: -1px; }
909 /* no-r2 */ margin-left: -1px;
913 /* no-r2 */ margin-right: -1px;
915 #minlat { margin-bottom: -1px; }
919 margin: $lineheight/4;
923 padding-left: $lineheight/2;
931 /* Rules for edit pages */
947 /* Rules for non-map content pages */
950 background: $lightgrey;
957 padding: $lineheight;
960 /* Overrides for pages that use new layout conventions */
962 .header-illustration {
963 background-position: 0 0;
964 background-repeat: no-repeat;
972 background-image: image-url("sign-up-illustration.png");
976 background-image: image-url("confirm-illustration.png");
980 background-image: image-url("terms-illustration.png");
988 background-image: image-url("sign-up-illustration-arm.png");
991 pointer-events: none;
995 [dir=rtl] .header-illustration {
996 transform: scaleX(-1);
1008 /* Rules for small maps in content areas */
1012 margin-bottom: $lineheight;
1015 @include media-breakpoint-up(md) {
1021 /* Rules for the user map */
1023 .content_map .leaflet-popup-content {
1024 margin: $lineheight/2;
1028 /* Rules for user popups on maps */
1034 margin-top: 0 0 0 60px;
1039 /* Rules for the user list */
1045 /* Rules for the diary list page */
1049 padding-top: $lineheight;
1050 padding-bottom: $lineheight/2;
1051 border-top: 1px solid $grey;
1054 background-color: #fee;
1058 /* Rules for the diary entry page */
1064 margin-bottom: $lineheight;
1070 border-top: 1px dashed $grey;
1071 padding-top: $lineheight/2;
1072 padding-bottom: $lineheight/2;
1074 margin-top: $lineheight/2;
1075 padding-top: $lineheight;
1076 border-top: 1px solid $grey;
1079 background-color: #fee;
1082 margin-bottom: $lineheight/2;
1091 /* Rules for the log in page */
1093 #login_auth_buttons {
1098 padding: $lineheight/4 $lineheight/2;
1102 /* Rules for the account confirmation page */
1106 padding: $lineheight;
1107 margin-bottom: $lineheight;
1112 list-style: inherit;
1116 list-style-type: lower-alpha;
1121 /* Rules for the account settings page */
1123 #accountForm .user_image {
1127 #accountForm #user_image {
1131 #accountForm ul.accountImage-options {
1144 display: inline !important;
1147 /* Rules for the oauth settings page */
1149 .oauth_clients .buttons .oauth-edit {
1150 border-radius: 2px 0 0 2px;
1153 .oauth_clients .buttons .oauth-delete {
1154 border-radius: 0 2px 2px 0;
1157 /* Rules for the oauth authorization page */
1159 .oauth-authorize ul {
1163 /* Rules for messages pages */
1166 button[type="submit"] {
1168 white-space: nowrap;
1172 background: $offwhite;
1176 background: #CBEEA7;
1184 .inbox-row .inbox-mark-read {
1189 margin-bottom: $lineheight;
1190 padding: $lineheight/4 0px 4px 0px;
1191 border-bottom: 1px solid $grey;
1198 .info-line .user_thumbnail_tiny {
1199 vertical-align: middle;
1203 white-space: nowrap;
1212 .inbox-row-unread .inbox-mark-unread {
1216 /* Rules for "flash" notice boxes shown at the top of the content area */
1220 background-color: #ff7070;
1224 background-color: #ffe0cc;
1228 background-color: #CBEEA7;
1232 /* Rules for highlighting fields with rails validation errors */
1235 display: inline-block;
1241 background-color: #ff7070;
1244 /* Rules for rails validation error boxes */
1248 border: 2px solid #ff7070;
1249 padding: 0 $lineheight/2;
1250 margin-bottom: $lineheight;
1251 background-color: #f0f0f0;
1254 margin: 0 -10px 10px -10px;
1255 padding: $lineheight/4 $lineheight/4 $lineheight/4 15px;
1258 background-color: #c00;
1266 padding: $lineheight/4;
1271 background-color: $lightgrey;
1273 .describe_location {
1282 background-color: $lightgrey;
1288 vertical-align: middle;
1292 a.reverse_directions {
1297 /* Rules for user images */
1304 img.user_thumbnail {
1309 img.user_thumbnail_tiny {
1316 /* Rules for geo microformats */
1319 border-bottom: none;
1322 /* General styles for action lists / subnavs / pager navs */
1325 nav.secondary-actions {
1330 flex-direction: row;
1336 display: inline-block;
1342 border-left: 1px solid $grey;
1343 padding-left: $lineheight/2;
1344 margin-right: $lineheight/2;
1345 margin-bottom: $lineheight/8;
1350 div.secondary-actions {
1357 input[type="submit"],
1358 input[type="button"],
1359 input[type="reset"],
1362 box-sizing: border-box;
1368 border-right:1px solid white;
1369 text-overflow: ellipsis;
1370 white-space: nowrap;
1374 .button:first-child,
1375 .button_to:first-child {
1376 border-radius:2px 0 0 2px;
1380 .button_to:last-child {
1381 border-radius:0 2px 2px 0;
1382 border-right-width: 0;
1386 .button_to:only-child,
1387 *[value="Hide"] + input:last-child,
1388 *[value="Hide"] + .button:last-child,
1389 *[value="Hide"] + .button_to:last-child {
1391 border-right-width: 0;
1393 /* if a 3-button set has a hidden middle button */
1394 *[value="Hide"] + input:nth-child(3),
1395 *[value="Hide"] + .button:nth-child(3),
1396 *[value="Hide"] + .button_to:nth-child(3) {
1397 border-radius:0 2px 2px 0;
1398 border-right-width: 0;
1400 /* if a 3-button set starts with a hidden button */
1401 *[value="Hide"] + input:nth-child(2):not(:last-child),
1402 *[value="Hide"] + .button:nth-child(2):not(:last-child),
1403 *[value="Hide"] + .button_to:nth-child(2):not(:last-child) {
1404 border-radius:2px 0 0 2px;
1405 border-right-width: 1px;
1409 /* Create a single-line dl */
1413 display: inline-block;
1420 /* Rules for OpenID logo */
1423 vertical-align: text-bottom;
1427 /* Rules for rich text */
1432 background: $lightgrey;
1437 background: $lightgrey;
1439 white-space: pre-wrap;
1447 padding: $lineheight;
1448 background-color: $offwhite;
1455 border-left: $lineheight solid $offwhite;
1456 padding-left: $lineheight;
1462 /* Rules for the user notes list */
1466 background-color: $offwhite;
1470 /* Rules for the iD editor */
1477 /* Rules for the "Welcome" page */
1478 .site-welcome, .site-fixthemap {
1480 background-image: image-url("welcome-sprite.png");
1481 background-size: 500px 250px;
1486 padding-bottom: 20px;
1488 margin-bottom: 10px;
1500 /* no-r2 */ background-position: -50px 0;
1505 vertical-align: middle;
1509 /* no-r2 */ background-position: -100px 0;
1513 /* no-r2 */ background-position: -150px 0;
1517 /* no-r2 */ background-position: -200px 0;
1521 /* no-r2 */ background-position: -250px 0;
1525 /* no-r2 */ background-position: -300px 0;
1529 /* no-r2 */ background-position: -350px 0;
1533 background-color: #333;
1538 .site-about #content {
1539 background-color: $lightgrey;
1540 background-position: 50% 50%;
1541 background-repeat: no-repeat;
1542 background-size: cover;
1543 background-attachment: fixed;
1554 color: $vibrant-green;
1560 background-position: 0 50%;
1561 background-repeat: no-repeat;
1562 background-image: image-url('about/osm.png');
1563 background-size: cover;
1564 background-color: $vibrant-green;
1568 background: $vibrant-green;
1572 display: inline-block;
1582 vertical-align: middle;
1583 background: 40px 40px image-url('about/sprite.png') no-repeat;
1587 background-position: 0px 0px;
1591 background-position: 0px -40px;
1595 background-position: 0px -80px;
1599 background-position: 0px -120px;
1603 background-position: 0px -160px;
1607 background-position: -45px -160px;
1614 @media only screen and (max-width:960px) {
1615 .header-illustration.new-user-arm {