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;
245 /* Utility for styling notification numbers */
248 padding: 2px $lineheight/4;
250 background: lighten($green, 30%);
256 /* Rules for the message shown in place of the map when javascript is disabled */
264 /* Rules for Leaflet maps */
266 .leaflet-control .control-button {
270 background-color: #333;
271 background-color: rgba(0,0,0,.6);
272 border-radius: 4px 0 0 4px;
278 background-color: black;
283 background-color: #333;
284 background-color: rgba(0,0,0,.5);
289 background-color: $vibrant-green;
297 .leaflet-control .zoomin,
298 .control-layers .control-button {
300 border-radius: 4px 0 0 0;
303 .leaflet-control .zoomout,
304 .control-key .control-button {
309 .control-locate .control-button,
310 .control-share .control-button {
311 border-radius: 0 0 0 4px;
314 /* Rules for the sidebar and main map area */
334 width: $sidebarWidth;
353 .overlay-sidebar #sidebar {
390 width: $sidebarWidth;
406 .leaflet-marker-draggable {
421 border-bottom: 1px solid $grey;
431 border:1px solid $grey;
436 border: 1px solid $grey;
438 border-top-color: $grey;
462 border: 2px solid #fff;
465 transition: border-color 0.08s ease-in;
472 border-bottom-right-radius: 3px;
476 text-stroke: 2px #fff;
477 background: rgba(255,255,255,.9);
479 input[type="radio"] {
484 &.active { border-color: darken($green, 10%); }
487 &.active { border-color: darken($green, 20%); }
497 li.disabled { color: $darkgrey; }
507 text-decoration: none;
508 background-color: $lightblue;
510 border-right: 1px solid #fff;
514 border-right: 1px solid #fff;
515 border-radius: 4px 0 0 4px;
519 border-radius: 0 4px 4px 0;
523 background-color: $blue;
535 font-family: monospace;
557 top: $lineheight/2 !important;
559 margin-right: 0px !important;
560 margin-top: 0px !important;
564 .leaflet-popup-scrolled {
565 padding-right: $lineheight;
566 border-bottom: 0px !important;
567 border-top: 0px !important;
570 .leaflet-popup-content-wrapper {
571 border-radius: 4px !important;
574 /* Rules for attribution text under the main map shown on printouts */
584 .attribution_license,
585 .attribution_project {
589 .attribution_notice {
593 .donate-attr { color: darken($green, 10%) !important; }
595 /* Rules for the sidebar */
599 padding: $lineheight/2 $lineheight;
600 // background: $offwhite;
601 // border-bottom: 1px solid $grey;
620 margin: $lineheight auto;
631 /* Temporary label size override until we remove site-wide font customisation */
639 /* Stop bootstrap 5 from floating legends when they don't need to be */
644 /* Override the text colour for primary and secondary buttons, to match our
645 bootstrap 4 colours. Note this has accessibility issues, which is why
646 bootstrap 5 calculates black as the appropriate colour, and we should
647 reconsider our colours at some point with that in mind. */
650 @include button-variant($primary, $primary, $color: $white, $hover-color: $white, $active-color: $white, $disabled-color: $white);
654 @include button-variant($secondary, $secondary, $color: $white, $hover-color: $white, $active-color: $white, $disabled-color: $white);
657 .btn-outline-secondary {
658 @include button-outline-variant($secondary, $color-hover: $white, $active-color: $white);
661 /* Rules for the search and direction forms */
663 header .search_forms,
668 /* Rules for the map key which appears in the popout sidebar */
671 .mapkey-table-key img {
678 /* Rules for search sidebar */
680 #sidebar .search_results_entry {
683 &.selected { background: $list-highlight; }
686 .search_more .loader {
692 .search_results_error {
697 /* Rules for routing */
700 background-image: image-url('routing-sprite.png');
703 background-repeat: no-repeat;
705 @for $i from 0 through 25 {
706 div.direction.i#{$i} { background-position: #{($i)*-20}px 0px; }
709 td.instruction, td.distance {
710 padding-top: $lineheight/5;
711 padding-bottom: $lineheight/5;
712 border-bottom: 1px solid $grey;
723 background: $list-highlight;
726 .routing_marker { width: 15px; cursor: move; }
728 /* Rules for entity history */
733 border-bottom: $keyline;
741 /* Rules for the history sidebar */
743 #sidebar .changesets {
745 &.selected { background: $list-highlight; }
746 /* color is derived from changeset bbox fillColor in history.js */
748 a.stretched-link > span {
753 a:not(.stretched-link), [title] {
767 .changeset_more .loader {
773 /* Rules for the browse sidebar */
777 padding-bottom: $spacer;
778 margin-bottom: $spacer;
779 border-bottom: 1px solid $grey;
782 word-wrap: break-word;
786 .browse-section:last-of-type {
791 background-color: $offwhite;
793 border-collapse: separate;
796 margin-bottom: $spacer;
799 border-bottom: 1px solid $grey;
802 tr:last-child th, tr:last-child td {
810 word-wrap: break-word;
811 white-space: pre-wrap;
816 background-color: $offwhite;
820 border-left: 1px solid $grey;
821 background-color: #fff;
824 .colour-preview-box {
829 border: 1px solid rgba(0, 0, 0, .1);
830 // add color via inline css on element: background-color: <tag value>;
834 .note-comments li, .changeset-comments li {
835 margin: $lineheight/2 0;
838 margin: 10px 6px 0 6px;
843 .subscribe-buttons input {
849 span.action-button:hover {
851 text-decoration: underline;
856 margin: 0 0 10px 10px;
869 background: $list-highlight;
876 /* Bootstrap buttons don't have any vertical margin, so
877 they touch when adjacent buttons wrap onto a new line
878 e.g. wide form buttons on a narrow sidebar */
882 margin-bottom: $spacer * 0.25;
886 /* Rules for export sidebar */
894 .export_area_inputs {
895 margin-bottom: $spacer;
903 background: $lightgrey;
905 #maxlat { margin-top: -1px; }
908 /* no-r2 */ margin-left: -1px;
912 /* no-r2 */ margin-right: -1px;
914 #minlat { margin-bottom: -1px; }
918 margin: $lineheight/4;
922 padding-left: $lineheight/2;
930 /* Rules for edit pages */
946 /* Rules for non-map content pages */
949 background: $lightgrey;
956 padding: $lineheight;
959 /* Overrides for pages that use new layout conventions */
961 .header-illustration {
962 background-position: 0 0;
963 background-repeat: no-repeat;
971 background-image: image-url("sign-up-illustration.png");
975 background-image: image-url("confirm-illustration.png");
979 background-image: image-url("terms-illustration.png");
987 background-image: image-url("sign-up-illustration-arm.png");
990 pointer-events: none;
994 [dir=rtl] .header-illustration {
995 transform: scaleX(-1);
1007 /* Rules for small maps in content areas */
1011 margin-bottom: $lineheight;
1014 @include media-breakpoint-up(md) {
1020 /* Rules for the user map */
1022 .content_map .leaflet-popup-content {
1023 margin: $lineheight/2;
1027 /* Rules for user popups on maps */
1033 margin-top: 0 0 0 60px;
1038 /* Rules for the user list */
1044 /* Rules for the diary list page */
1048 padding-top: $lineheight;
1049 padding-bottom: $lineheight/2;
1050 border-top: 1px solid $grey;
1053 background-color: #fee;
1057 /* Rules for the diary entry page */
1063 margin-bottom: $lineheight;
1069 border-top: 1px dashed $grey;
1070 padding-top: $lineheight/2;
1071 padding-bottom: $lineheight/2;
1073 margin-top: $lineheight/2;
1074 padding-top: $lineheight;
1075 border-top: 1px solid $grey;
1078 background-color: #fee;
1081 margin-bottom: $lineheight/2;
1090 /* Rules for the log in page */
1092 #login_auth_buttons {
1097 padding: $lineheight/4 $lineheight/2;
1101 /* Rules for the account confirmation page */
1105 padding: $lineheight;
1106 margin-bottom: $lineheight;
1111 list-style: inherit;
1115 list-style-type: lower-alpha;
1120 /* Rules for the account settings page */
1122 #accountForm .user_image {
1126 #accountForm #user_image {
1130 #accountForm ul.accountImage-options {
1143 display: inline !important;
1146 /* Rules for the oauth settings page */
1148 .oauth_clients .buttons .oauth-edit {
1149 border-radius: 2px 0 0 2px;
1152 .oauth_clients .buttons .oauth-delete {
1153 border-radius: 0 2px 2px 0;
1156 /* Rules for the oauth authorization page */
1158 .oauth-authorize ul {
1162 /* Rules for messages pages */
1165 button[type="submit"] {
1167 white-space: nowrap;
1171 background: $offwhite;
1175 background: #CBEEA7;
1183 .inbox-row .inbox-mark-read {
1188 margin-bottom: $lineheight;
1189 padding: $lineheight/4 0px 4px 0px;
1190 border-bottom: 1px solid $grey;
1197 .info-line .user_thumbnail_tiny {
1198 vertical-align: middle;
1202 white-space: nowrap;
1211 .inbox-row-unread .inbox-mark-unread {
1215 /* Rules for "flash" notice boxes shown at the top of the content area */
1219 background-color: #ff7070;
1223 background-color: #ffe0cc;
1227 background-color: #CBEEA7;
1231 /* Rules for highlighting fields with rails validation errors */
1234 display: inline-block;
1240 background-color: #ff7070;
1243 /* Rules for rails validation error boxes */
1247 border: 2px solid #ff7070;
1248 padding: 0 $lineheight/2;
1249 margin-bottom: $lineheight;
1250 background-color: #f0f0f0;
1253 margin: 0 -10px 10px -10px;
1254 padding: $lineheight/4 $lineheight/4 $lineheight/4 15px;
1257 background-color: #c00;
1265 padding: $lineheight/4;
1270 background-color: $lightgrey;
1272 .describe_location {
1281 background-color: $lightgrey;
1287 vertical-align: middle;
1292 /* Rules for user images */
1299 img.user_thumbnail {
1304 img.user_thumbnail_tiny {
1311 /* Rules for geo microformats */
1314 border-bottom: none;
1317 /* General styles for action lists / subnavs / pager navs */
1320 nav.secondary-actions {
1325 flex-direction: row;
1331 display: inline-block;
1337 border-left: 1px solid $grey;
1338 padding-left: $lineheight/2;
1339 margin-right: $lineheight/2;
1340 margin-bottom: $lineheight/8;
1345 div.secondary-actions {
1352 input[type="submit"],
1353 input[type="button"],
1354 input[type="reset"],
1357 box-sizing: border-box;
1363 border-right:1px solid white;
1364 text-overflow: ellipsis;
1365 white-space: nowrap;
1369 .button:first-child,
1370 .button_to:first-child {
1371 border-radius:2px 0 0 2px;
1375 .button_to:last-child {
1376 border-radius:0 2px 2px 0;
1377 border-right-width: 0;
1381 .button_to:only-child,
1382 *[value="Hide"] + input:last-child,
1383 *[value="Hide"] + .button:last-child,
1384 *[value="Hide"] + .button_to:last-child {
1386 border-right-width: 0;
1388 /* if a 3-button set has a hidden middle button */
1389 *[value="Hide"] + input:nth-child(3),
1390 *[value="Hide"] + .button:nth-child(3),
1391 *[value="Hide"] + .button_to:nth-child(3) {
1392 border-radius:0 2px 2px 0;
1393 border-right-width: 0;
1395 /* if a 3-button set starts with a hidden button */
1396 *[value="Hide"] + input:nth-child(2):not(:last-child),
1397 *[value="Hide"] + .button:nth-child(2):not(:last-child),
1398 *[value="Hide"] + .button_to:nth-child(2):not(:last-child) {
1399 border-radius:2px 0 0 2px;
1400 border-right-width: 1px;
1404 /* Create a single-line dl */
1408 display: inline-block;
1415 /* Rules for OpenID logo */
1418 vertical-align: text-bottom;
1422 /* Rules for rich text */
1427 background: $lightgrey;
1432 background: $lightgrey;
1434 white-space: pre-wrap;
1442 padding: $lineheight;
1443 background-color: $offwhite;
1450 border-left: $lineheight solid $offwhite;
1451 padding-left: $lineheight;
1457 /* Rules for the user notes list */
1461 background-color: $offwhite;
1465 /* Rules for the iD editor */
1472 /* Rules for the "Welcome" page */
1473 .site-welcome, .site-fixthemap {
1475 background-image: image-url("welcome-sprite.png");
1476 background-size: 500px 250px;
1481 padding-bottom: 20px;
1483 margin-bottom: 10px;
1495 /* no-r2 */ background-position: -50px 0;
1500 vertical-align: middle;
1504 /* no-r2 */ background-position: -100px 0;
1508 /* no-r2 */ background-position: -150px 0;
1512 /* no-r2 */ background-position: -200px 0;
1516 /* no-r2 */ background-position: -250px 0;
1520 /* no-r2 */ background-position: -300px 0;
1524 /* no-r2 */ background-position: -350px 0;
1528 background-color: #333;
1533 .site-about #content {
1534 background-color: $lightgrey;
1535 background-position: 50% 50%;
1536 background-repeat: no-repeat;
1537 background-size: cover;
1538 background-attachment: fixed;
1549 color: $vibrant-green;
1555 background-position: 0 50%;
1556 background-repeat: no-repeat;
1557 background-image: image-url('about/osm.png');
1558 background-size: cover;
1559 background-color: $vibrant-green;
1563 background: $vibrant-green;
1567 display: inline-block;
1577 vertical-align: middle;
1578 background: 40px 40px image-url('about/sprite.png') no-repeat;
1582 background-position: 0px 0px;
1586 background-position: 0px -40px;
1590 background-position: 0px -80px;
1594 background-position: 0px -120px;
1598 background-position: 0px -160px;
1602 background-position: -45px -160px;
1609 @media only screen and (max-width:960px) {
1610 .header-illustration.new-user-arm {