custom.css 1.7 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980818283848586878889909192
  1. /* fix a few issues with static/scrolling sidebar and algolia search fields
  2. - issue where overflow-x hidden was added but not required if hidden submit button wraps
  3. - added search content causes width of sidebar to make content wrap
  4. - search results not able to be shown inside scrollable container
  5. - https://github.com/wagtail/sphinx_wagtail_theme/issues/201
  6. */
  7. .sidebar-container .collapse {
  8. overflow-x: unset;
  9. }
  10. @media screen and (min-width: 992px) {
  11. .sidebar-container {
  12. width: 25%;
  13. }
  14. }
  15. body.body--autocomplete-open .sidebar-container .collapse {
  16. overflow-y: unset;
  17. }
  18. .rst-versions.rst-badge {
  19. z-index: 1021;
  20. }
  21. /* Promotion banner */
  22. .promotion-banner {
  23. background: #00676a;
  24. color: white;
  25. border-radius: 6px;
  26. margin-bottom: 2em;
  27. display: flex;
  28. justify-content: space-between;
  29. align-items: flex-start;
  30. padding: 1rem;
  31. position: relative;
  32. }
  33. .promotion-banner svg {
  34. position: absolute;
  35. width: 3.5rem;
  36. top: -0.5rem;
  37. left: 0;
  38. }
  39. .promotion-banner a {
  40. display: flex;
  41. color: inherit;
  42. padding: 1rem;
  43. text-align: left;
  44. flex: 1 1 50%;
  45. border: 0;
  46. text-decoration: none;
  47. }
  48. .promotion-banner strong {
  49. font-size: 1.25em;
  50. }
  51. .promotion-banner .close {
  52. padding: 10px;
  53. width: 3.5rem;
  54. cursor: pointer;
  55. font-weight: bold;
  56. font-size: 1.5em;
  57. color: inherit;
  58. border: 0;
  59. background: none;
  60. position: absolute;
  61. top: 0;
  62. right: 0;
  63. }
  64. @keyframes bounce {
  65. 0%,
  66. 100% {
  67. transform: translateY(0);
  68. }
  69. 50% {
  70. transform: translateY(-5px);
  71. }
  72. }
  73. .promotion-banner:hover svg {
  74. animation-duration: 0.5s;
  75. animation-fill-mode: both;
  76. animation-timing-function: linear;
  77. animation-iteration-count: infinite;
  78. animation-name: bounce;
  79. }