header.css 2.4 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126
  1. body {
  2. margin: 0; }
  3. .header-fixed {
  4. position: fixed;
  5. top: 0;
  6. z-index: 1;
  7. width: 100%;
  8. background-color: white; }
  9. .navbar {
  10. display: flex;
  11. line-height: 60px; }
  12. .navbar .logo {
  13. flex: 3;
  14. padding-left: 2em; }
  15. .navbar nav {
  16. flex: 8; }
  17. .navbar label {
  18. user-select: none;
  19. cursor: pointer;
  20. padding: 28px 20px;
  21. position: relative;
  22. z-index: 3; }
  23. .navbar label i {
  24. height: 2px;
  25. position: relative;
  26. transition: background .2s ease-out;
  27. width: 18px;
  28. font-style: normal;
  29. font-weight: normal; }
  30. .navbar label i:before,
  31. .navbar label i:after {
  32. content: '';
  33. height: 100%;
  34. position: absolute;
  35. transition: all .2s ease-out;
  36. width: 100%; }
  37. .navbar label i,
  38. .navbar label i:before,
  39. .navbar label i:after {
  40. display: block;
  41. background: black; }
  42. .navbar label i:before {
  43. top: 5px; }
  44. .navbar label i:after {
  45. top: -5px; }
  46. .navbar #navbar-toggle {
  47. display: none; }
  48. .header #navbar-toggle:checked ~ .menu {
  49. visibility: visible;
  50. opacity: 0.99; }
  51. .header #navbar-toggle:checked ~ label {
  52. background: #212121;
  53. border-radius: 50%; }
  54. .header #navbar-toggle:checked ~ label i {
  55. background: transparent; }
  56. .header #navbar-toggle:checked ~ label i:before {
  57. transform: rotate(-45deg); }
  58. .header #navbar-toggle:checked ~ label i:after {
  59. transform: rotate(45deg); }
  60. .header #navbar-toggle:checked ~ label:not(.steps) i:before,
  61. .header #navbar-toggle:checked ~ label:not(.steps) i:after {
  62. top: 0; }
  63. @media (max-width: 800px) {
  64. .navbar nav {
  65. visibility: hidden;
  66. opacity: 0;
  67. position: fixed;
  68. top: 0px;
  69. left: 0px;
  70. width: 100%;
  71. height: 100%;
  72. transition: all 0.3s ease-out;
  73. display: table;
  74. background: #ddd; }
  75. .navbar nav ul {
  76. margin: 0;
  77. padding: 20px 0;
  78. display: table-cell;
  79. vertical-align: middle; }
  80. .navbar nav li {
  81. display: block;
  82. padding: 20px 0;
  83. text-align: center;
  84. font-size: 50px;
  85. min-height: 50px;
  86. font-weight: bold;
  87. cursor: pointer;
  88. transition: all 0.3s ease-out; } }
  89. @media (min-width: 800px) {
  90. .navbar nav ul {
  91. margin: 0;
  92. padding: 0;
  93. display: flex;
  94. justify-content: space-around;
  95. text-align: right;
  96. list-style: none; }
  97. .navbar nav li {
  98. flex: 1; }
  99. .navbar nav li a {
  100. display: block;
  101. padding: 0 8px;
  102. line-height: 60px; }
  103. .navbar label {
  104. display: none; }
  105. .hidden-md {
  106. display: none !important; } }