_header.scss 2.8 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208
  1. /*--------------------------------------------------------------*/
  2. /* !## Site Header */
  3. /*--------------------------------------------------------------*/
  4. .site-header {
  5. background: $color__background-body;
  6. }
  7. .site-header-wrap {
  8. position: relative;
  9. z-index: 2;
  10. }
  11. .custom-logo-link {
  12. display: block;
  13. line-height: 0;
  14. }
  15. .site-identity {
  16. padding-right: ( $gutter * 1.5 );
  17. }
  18. .site-branding {
  19. padding: 0 ( $gutter * .5 );
  20. .site-title {
  21. @include site-title();
  22. margin: 0;
  23. }
  24. .site-description {
  25. @include body-copy-small();
  26. margin-bottom: 0;
  27. }
  28. a {
  29. display: inline-block;
  30. }
  31. }
  32. @include breakpoint( mobileonly ) {
  33. .custom-logo-link {
  34. margin-bottom: ( $gutter * .6 );
  35. max-width: 50%;
  36. }
  37. .site-branding {
  38. text-align: left;
  39. margin-bottom: $mobile-baseline;
  40. .site-identity {
  41. padding-right: 100px;
  42. }
  43. .site-title {
  44. margin-bottom: ( $gutter * .4 );
  45. width: calc( 100% + 100px );
  46. &:last-child {
  47. width: inherit;
  48. }
  49. }
  50. .hide-site-title-description & .custom-logo-link,
  51. .site-identity > *:last-child {
  52. margin-bottom: 0;
  53. }
  54. }
  55. }
  56. @include breakpoint( phablet ) {
  57. .site-header {
  58. position: relative;
  59. overflow: visible;
  60. }
  61. .site-branding {
  62. display: inline-block;
  63. vertical-align: top;
  64. width: calc( 70% - #{$gutter} );
  65. }
  66. .admin-bar .site-branding-wrap {
  67. top: calc( #{ $baseline } + #{ $admin-bar-height } );
  68. }
  69. .site-header-wrap {
  70. padding: ( $baseline ) 0;
  71. }
  72. }
  73. @include breakpoint( tablet ) {
  74. .site-header-wrap {
  75. display: flex;
  76. flex-direction: row-reverse;
  77. justify-content: space-between;
  78. padding: ( $baseline * 2 ) 0;
  79. position: relative;
  80. align-items: center;
  81. overflow: visible;
  82. }
  83. .site-branding {
  84. align-content: center;
  85. clip: rect( 0, auto, auto, 0 );
  86. display: flex;
  87. flex-direction: column;
  88. height: 100%;
  89. justify-content: center;
  90. left: 0;
  91. padding: ( $baseline * 2 ) 30% ( $baseline * 2 ) 0;
  92. position: absolute;
  93. top: 0;
  94. width: 100%;
  95. z-index: 1;
  96. }
  97. .site-branding-wrap {
  98. align-items: center;
  99. display: flex;
  100. flex-direction: row;
  101. flex: 3 1 50%;
  102. flex-wrap: nowrap;
  103. justify-content: center;
  104. position: fixed;
  105. top: ( $baseline * 2 );
  106. .custom-logo-link {
  107. flex: 1 0 144px;
  108. padding: 0 ( $gutter * .5 ) 0 0;
  109. .custom-logo {
  110. max-width: 100%;
  111. }
  112. }
  113. .admin-bar & {
  114. top: calc( #{ $baseline * 2 } + #{ $admin-bar-height } );
  115. }
  116. .hide-site-title-description & {
  117. width: calc( 80% * .725 );
  118. .custom-logo-link {
  119. flex: 5 0 80%;
  120. padding: 0;
  121. .custom-logo {
  122. max-width: 50%;
  123. }
  124. }
  125. }
  126. .wp-custom-logo & {
  127. width: calc( 80% * .725 );
  128. }
  129. .site-identity {
  130. flex: 4 1 80%;
  131. padding: 0 ( $gutter * .5 ) 0 0;
  132. }
  133. .site-title {
  134. @include font-size( 2.1375 );
  135. }
  136. .site-description {
  137. @include font-size();
  138. margin-bottom: 0;
  139. max-width: 40em;
  140. }
  141. }
  142. }