5 @import "rails_bootstrap_forms";
 
   7 /* Styles common to large and small screens */
 
   9 /* Default rules for the body of every page */
 
  12   font-size: $typeheight;
 
  16   text-decoration: underline dotted;
 
  22   display: inline-block;
 
  26   background: transparent image-url("sprite.svg") no-repeat 0 0;
 
  31 .icon.search      { /*rtl:ignore*/ background-position: 0 0; }
 
  32 .icon.donate      { /*rtl:ignore*/ background-position: -20px 0; }
 
  33 .icon.zoomin      { /*rtl:ignore*/ background-position: -40px 0; }
 
  34 .icon.zoomout     { /*rtl:ignore*/ background-position: -60px 0; }
 
  35 .icon.geolocate   { /*rtl:ignore*/ background-position: -80px 0; }
 
  36 .active .icon.geolocate   { /*rtl:ignore*/ background-position: -80px -20px; }
 
  37 .icon.layers      { /*rtl:ignore*/ background-position: -100px 0; }
 
  38 .icon.key         { /*rtl:ignore*/ background-position: -120px 0; }
 
  39 .icon.share       { /*rtl:ignore*/ background-position: -140px 0; }
 
  40 .icon.clipboard   { /*rtl:ignore*/ background-position: -160px 0; }
 
  41 .icon.link        { /*rtl:ignore*/ background-position: -180px 0; }
 
  42 .icon.close       { /*rtl:ignore*/ background-position: -200px 0; }
 
  43 .icon.close:hover { /*rtl:ignore*/ background-position: -200px -20px; }
 
  44 .icon.check       { /*rtl:ignore*/ background-position: -220px 0; }
 
  45 .icon.note        { /*rtl:ignore*/ background-position: -240px 0; }
 
  46 .icon.note.grey   { /*rtl:ignore*/ background-position: -240px -20px; }
 
  47 .icon.query       { /*rtl:ignore*/ background-position: -260px 0; }
 
  49 /* Utility for de-emphasizing content */
 
  51 .text-body-secondary a {
 
  55 /* Bootstrap contextual table classes overrides in dark mode */
 
  57 @include color-mode(dark) {
 
  59     --bs-table-bg: rgb(var(--bs-primary-rgb), .25);
 
  62     --bs-table-bg: rgb(var(--bs-secondary-rgb), .25);
 
  65     --bs-table-bg: rgb(var(--bs-success-rgb), .25);
 
  67   .table-primary, .table-secondary, .table-success {
 
  68     --bs-table-color: initial;
 
  69     border-color: inherit;
 
  73 /* Rules for the header */
 
  80   background: image-url("menu-icon.svg") no-repeat;
 
  81   background-size: 30px 30px;
 
  84   margin: 14px 10px 0 0;
 
  88 @include color-mode(dark) {
 
  95   height: $headerHeight;
 
 100     padding: $lineheight * 0.5;
 
 104     height: $headerHeight;
 
 122   & > .btn-group .btn-outline-primary {
 
 123     @include button-outline-variant($green, $color-hover: $white, $active-color: $white);
 
 127     .btn-outline-primary {
 
 132         border-top-color: $grey;
 
 136         background-color: lighten($green, 30%);
 
 141   // Small tweaks to the toggle to stop the primary colour showing through
 
 142   // when the menu is shown
 
 143   .show > .btn-outline-primary.dropdown-toggle {
 
 144     background-color: $green;
 
 145     border-color: $green;
 
 148       box-shadow: 0 0 0 0.2rem fade-out($green, 0.5);
 
 159 nav.primary, nav.secondary {
 
 162       background-color: $green;
 
 168 #compact-secondary-nav {
 
 173   #compact-secondary-nav {
 
 174     display: inline-block;
 
 187     flex-direction: column;
 
 189     min-height: $headerHeight;
 
 192       display: none !important;
 
 200   #sidebar .search_forms,
 
 217     flex-direction: column;
 
 219     .user-menu, .login-menu {
 
 224   #compact-secondary-nav {
 
 229     display: inline-block;
 
 232   .overlay-sidebar #sidebar .welcome {
 
 236   .overlay-sidebar #sidebar #banner {
 
 241 /* Utility for styling notification numbers */
 
 244   background: transparentize(lighten($green, 25%), .25);
 
 246   font-weight: $font-weight-normal;
 
 249 /* Rules for Leaflet maps */
 
 251 .leaflet-top.leaflet-right,
 
 252 .leaflet-top.leaflet-left {
 
 256   flex-direction: column;
 
 257   flex-wrap: wrap-reverse;
 
 260 .leaflet-control .control-button {
 
 264   background-color: #333;
 
 265   background-color: rgba(0,0,0,.6);
 
 270     background-color: black;
 
 275     background-color: #333;
 
 276     background-color: rgba(0,0,0,.5);
 
 281     background-color: $vibrant-green;
 
 285     border-start-start-radius: 4px;
 
 289     border-end-start-radius: 4px;
 
 298 /* Rules for the sidebar and main map area */
 
 318     width: $sidebarWidth;
 
 325   .overlay-sidebar #sidebar {
 
 352       width: $sidebarWidth;
 
 368     .leaflet-marker-draggable {
 
 383 @include media-breakpoint-down(md) {
 
 398     .overlay-sidebar.overlay-right-sidebar {
 
 418       box-sizing: content-box;
 
 419       top: - map.get($border-widths, 4);
 
 420       left: - map.get($border-widths, 4);
 
 421       --bs-btn-border-color: var(--bs-body-bg);
 
 424       --bs-btn-border-color: var(--bs-primary-border-subtle);
 
 429     li.disabled { color: $darkgrey; }
 
 440   top: 10px !important;
 
 442     margin-right: 0px !important;
 
 443     margin-top: 0px !important;
 
 447 .leaflet-popup-scrolled {
 
 448   padding-right: $lineheight;
 
 449   border-bottom: 0px !important;
 
 450   border-top: 0px !important;
 
 453 .leaflet-popup-content-wrapper, .leaflet-popup-tip,
 
 454 .leaflet-contextmenu, .leaflet-contextmenu-item,
 
 455 .leaflet-control-attribution, .leaflet-control-scale-line {
 
 456   @extend .bg-body, .text-body;
 
 459 .leaflet-control-attribution, .leaflet-control-scale-line {
 
 460   @extend .bg-opacity-75;
 
 461   text-shadow: none !important;
 
 464 .leaflet-contextmenu-item.over {
 
 465   @extend .bg-body-secondary, .border-secondary, .border-opacity-10;
 
 468 .leaflet-popup-content-wrapper {
 
 472     color: var(--bs-link-color) !important;
 
 476 @include color-mode(dark) {
 
 477   .leaflet-tile-container,
 
 478   .mapkey-table-entry td:first-child > * {
 
 479     filter: brightness(.8);
 
 482   .leaflet-control-attribution a {
 
 483     color: var(--bs-link-color);
 
 486   .leaflet-control-scale-line {
 
 487     @extend .border-light, .border-opacity-75;
 
 491 /* Rules for attribution text under the main map shown on printouts */
 
 493 .donate-attr { color: darken($green, 10%) !important; }
 
 495 /* Temporary label size override until we remove site-wide font customisation */
 
 506 /* Stop bootstrap 5 from floating legends when they don't need to be */
 
 511 /* Override the text colour for primary and secondary buttons, to match our
 
 512    bootstrap 4 colours. Note this has accessibility issues, which is why
 
 513    bootstrap 5 calculates black as the appropriate colour, and we should
 
 514    reconsider our colours at some point with that in mind. */
 
 517   @include button-variant($primary, $primary, $color: $white, $hover-color: $white, $active-color: $white, $disabled-color: $white);
 
 521   @include button-variant($secondary, $secondary, $color: $white, $hover-color: $white, $active-color: $white, $disabled-color: $white);
 
 524 .btn-outline-secondary {
 
 525   @include button-outline-variant($secondary, $color-hover: $white, $active-color: $white);
 
 528 /* Rules for the search and direction forms */
 
 530 header .search_forms,
 
 541 /* Rules for search sidebar */
 
 543 #sidebar .search_results_entry {
 
 544   .search_more .loader {
 
 549 /* Rules for routing */
 
 552   background-image: image-url('routing-sprite.svg');
 
 555   background-repeat: no-repeat;
 
 557 @for $i from 0 through 25 {
 
 558 div.direction.i#{$i} { background-position: #{($i)*-20}px 0px; }
 
 561 @include color-mode(dark) {
 
 574 .routing_marker_column {
 
 582 /* Rules for the history sidebar */
 
 584 #sidebar .changesets {
 
 590     a.stretched-link > span, a:not(.stretched-link), [title] {
 
 592       z-index: 2; /* needs to be higher than Bootstrap's stretched link ::after z-index */
 
 596   .changeset_more .loader {
 
 602 /* Rules for the browse sidebar */
 
 606     padding-bottom: $spacer;
 
 607     margin-bottom: $spacer;
 
 608     border-bottom: 1px solid $grey;
 
 611       word-wrap: break-word;
 
 615   .browse-section:last-of-type {
 
 621     white-space: pre-wrap;
 
 622     word-wrap: break-word;
 
 623     word-break: break-word;
 
 625     tr:last-child th, tr:last-child td {
 
 635 /* Force LTR/RTL alignment for placeholder text */
 
 637 .form-control::placeholder {
 
 641 /* Rules for export sidebar */
 
 644   .export_area_inputs {
 
 655       /*rtl:ignore*/ float: left;
 
 658       /*rtl:ignore*/ float: right;
 
 663 /* Rules for edit pages */
 
 674 /* Rules for non-map content pages */
 
 680   padding: $lineheight;
 
 683 /* Rules for login and signup pages */
 
 685 .sessions-new, .users-new, .users-create {
 
 686   #content .content-inner {
 
 691 .header-illustration {
 
 692   background-position: right;
 
 693   background-repeat: no-repeat;
 
 701     background-image: image-url("sign-up-illustration.svg");
 
 702     background-position-x: 70px;
 
 706     background-image: image-url("confirm-illustration.svg");
 
 710     background-image: image-url("terms-illustration.svg");
 
 714 [dir=rtl] .header-illustration {
 
 715   transform: scaleX(-1);
 
 718     transform: scaleX(-1);
 
 722     transform: scaleX(-1);
 
 726 /* Rules for small maps in content areas */
 
 730   margin-bottom: $lineheight;
 
 733 @include media-breakpoint-up(md) {
 
 739 /* Rules for the user map */
 
 741 .content_map .leaflet-popup-content {
 
 746 /* Rules for user popups on maps */
 
 756 /* Rules for the diary entry page */
 
 763   .diary-comment .col-auto {
 
 766   .diary-comment .col {
 
 771 /* Rules for the account confirmation page */
 
 775     padding: $lineheight;
 
 776     margin-bottom: $lineheight;
 
 785       list-style-type: lower-alpha;
 
 790 /* Rules for user images */
 
 802 img.user_thumbnail_tiny {
 
 808 /* General styles for action lists / subnavs */
 
 810 nav.secondary-actions {
 
 823       border-left: 1px solid $grey;
 
 824       padding-left: $lineheight * 0.5;
 
 825       margin-right: $lineheight * 0.5;
 
 826       margin-bottom: $lineheight * 0.125;
 
 831 div.secondary-actions {
 
 836 /* Rules for rich text */
 
 840     background: var(--bs-secondary-bg);
 
 845     background: var(--bs-secondary-bg);
 
 847     white-space: pre-wrap;
 
 855     padding: $lineheight;
 
 856     background-color: var(--bs-tertiary-bg);
 
 863     border-left: $lineheight solid var(--bs-tertiary-bg);
 
 864     padding-left: $lineheight;
 
 866     color: var(--bs-secondary-color);
 
 870 /* Rules for the "About" page */
 
 872 .site-about #content {
 
 882         color: $vibrant-green;
 
 888       background-position: 0 50%;
 
 889       background-repeat: no-repeat;
 
 890       background-image: image-url('about/osm.png');
 
 891       background-size: cover;
 
 892       background-color: $vibrant-green;
 
 896       background: $vibrant-green;
 
 900       display: inline-block;
 
 907 /* Rules for tabs inside secondary background sections */
 
 909 .bg-body-secondary .nav-tabs {
 
 910   --bs-border-color: var(--bs-secondary-border-subtle);
 
 911   --bs-secondary-bg: var(--bs-secondary-border-subtle);
 
 915 /* Rules for traces */
 
 918   mix-blend-mode: darken;
 
 921 @include color-mode(dark) {
 
 924     mix-blend-mode: lighten;
 
 928 /* Rules for map sidebar icons */
 
 934     display: inline-block;
 
 939   .node, .way, .relation {
 
 944 @each $class, $item in $map-sidebar-icons {
 
 945   .browse-section #{$class}::before {
 
 946     content: image-url('browse/#{map.get($item, "filename")}');
 
 949   @if map.get($item, "invert") {
 
 950     @include color-mode(dark) {
 
 951       .browse-section #{$class}::before {
 
 952         filter: invert(.8) hue-rotate(180deg);