_extra-child-theme.scss 6.6 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387
  1. /**
  2. * Extra Child Theme Styles
  3. */
  4. // @import "";
  5. $spacing_unit: map-deep-get($config-global, "spacing", "unit");
  6. $spacing_vertical: map-deep-get($config-global, "spacing", "vertical");
  7. /**
  8. * Elements
  9. */
  10. a {
  11. .site-header &,
  12. &:hover,
  13. &:focus,
  14. .nav-links & {
  15. text-decoration: none;
  16. }
  17. }
  18. /**
  19. * Header
  20. */
  21. .site-header,
  22. .site-footer {
  23. max-width: 100%;
  24. padding-left: $spacing_unit;
  25. padding-right: $spacing_unit;
  26. position: relative;
  27. @include media(mobile) {
  28. padding: $spacing_vertical;
  29. }
  30. }
  31. .social-navigation {
  32. a {
  33. vertical-align: middle;
  34. }
  35. ul li a svg {
  36. display: block;
  37. width: (1.5 * $spacing_unit);
  38. height: (1.5 * $spacing_unit);
  39. transform: translateZ(0);
  40. }
  41. }
  42. /**
  43. * CSS-grid Desktop Menu
  44. */
  45. @include media(mobile) {
  46. .site-header {
  47. align-items: center;
  48. display: grid;
  49. grid-template-columns: auto;
  50. grid-template-rows: auto;
  51. grid-column-gap: $spacing_unit;
  52. grid-template-areas:
  53. "site-logo site-logo"
  54. "site-title social-navigation"
  55. "site-description main-navigation";
  56. &:before,
  57. &:after {
  58. content: none;
  59. display: none;
  60. }
  61. & > * {
  62. margin-top: 0;
  63. margin-bottom: 0;
  64. }
  65. }
  66. .site-logo {
  67. grid-area: site-logo;
  68. margin-bottom: $spacing_unit;
  69. }
  70. .site-title {
  71. align-self: flex-end;
  72. grid-area: site-title;
  73. & + .site-description {
  74. margin-top: 0;
  75. }
  76. }
  77. .site-description {
  78. align-self: center;
  79. grid-area: site-description;
  80. }
  81. .main-navigation {
  82. align-self: center;
  83. grid-area: main-navigation;
  84. justify-self: flex-end;
  85. & > div > ul {
  86. justify-content: flex-end;
  87. margin-left: -#{0.5 * map-deep-get($config-global, "spacing", "horizontal")};
  88. margin-right: -#{0.5 * map-deep-get($config-global, "spacing", "horizontal")};
  89. & > li {
  90. padding: #{map-deep-get($config-header, "main-nav", "link-padding")};
  91. & > a {
  92. padding: 0;
  93. }
  94. }
  95. & > .menu-item-has-children > a::after {
  96. font-size: #{0.5 * map-deep-get($config-global, "font", "size", "base")};
  97. }
  98. }
  99. & > div > ul > li:hover,
  100. & > div > ul > li.focus,
  101. & > div > ul > li.current-menu-item {
  102. & > a {
  103. color: #{map-deep-get($config-global, "color", "primary", "default")};
  104. }
  105. & > ul {
  106. box-shadow: none;
  107. overflow: hidden;
  108. &:before {
  109. border-bottom: (0.5 * $spacing_unit) solid #{map-deep-get($config-global, "color", "primary", "default")};
  110. border-left: (0.5 * $spacing_unit) solid transparent;
  111. border-right: (0.5 * $spacing_unit) solid transparent;
  112. content: "";
  113. display: block;
  114. margin-left: $spacing_unit;
  115. width: $spacing_unit;
  116. }
  117. }
  118. & li {
  119. & > a {
  120. background: #{map-deep-get($config-global, "color", "primary", "default")};
  121. color: #{map-deep-get($config-global, "color", "background", "default")};
  122. }
  123. &:hover > a,
  124. &.focus > a,
  125. &.current-menu-item > a {
  126. background: #{map-deep-get($config-global, "color", "primary", "hover")};
  127. }
  128. }
  129. }
  130. }
  131. .social-navigation {
  132. align-self: center;
  133. grid-area: social-navigation;
  134. justify-self: flex-end;
  135. }
  136. }
  137. /**
  138. * Main
  139. */
  140. .site-main {
  141. padding-top: 0;
  142. }
  143. .site-main > article > .entry-header,
  144. .site-main > .page-header,
  145. .site-main > .not-found > .page-header {
  146. margin-top: #{0.666 * $spacing_vertical};
  147. @include media(mobile) {
  148. margin-top: #{2 * $spacing_vertical};
  149. }
  150. }
  151. .site-main > {
  152. article > .entry-header,
  153. .page-header,
  154. .not-found > .page-header {
  155. margin-top: #{0.666 * $spacing_vertical};
  156. @include media(mobile) {
  157. margin-top: #{2 * $spacing_vertical};
  158. }
  159. }
  160. }
  161. #main .entry-content .entry-attachment {
  162. max-width: calc( 100% - #{2 * $spacing_vertical} );
  163. }
  164. /**
  165. * Posts
  166. */
  167. .entry-title,
  168. .page-title,
  169. .a8c-posts-list .a8c-posts-list-item__title {
  170. a {
  171. color: inherit;
  172. text-decoration: none;
  173. &:active,
  174. &:focus,
  175. &:hover {
  176. color: map-deep-get($config-global, "color", "primary", "default");
  177. }
  178. }
  179. }
  180. .entry-meta,
  181. .entry-footer {
  182. color: map-deep-get($config-global, "color", "foreground", "default");
  183. }
  184. .entry-meta a:hover,
  185. .entry-meta a:active,
  186. .entry-footer a:hover,
  187. .entry-footer a:active {
  188. color: map-deep-get($config-global, "color", "primary", "default");
  189. }
  190. /**
  191. * Comments
  192. */
  193. .logged-in-as,
  194. .comment-notes,
  195. .comment-form-cookies-consent {
  196. font-size: map-deep-get($config-global, "font", "size", "sm");
  197. }
  198. .comment-form-cookies-consent input[type=checkbox] + label {
  199. line-height: #{map-deep-get($config-global, "font", "line-height", "body")};
  200. }
  201. .comment-notes {
  202. color: map-deep-get($config-global, "color", "foreground", "light");
  203. }
  204. .comment-form > p:not(.comment-form-cookies-consent) label {
  205. font-weight: 600;
  206. }
  207. /**
  208. * Widgets
  209. */
  210. @include media(laptop) {
  211. .site-footer .widget-area {
  212. max-width: 100%;
  213. & > .widget {
  214. width: 50%;
  215. }
  216. }
  217. }
  218. .widget {
  219. select {
  220. max-width: 100%;
  221. }
  222. }
  223. .widget-title {
  224. font-size: #{map-deep-get($config-heading, "font", "size", "h5")};
  225. margin-bottom: #{0.5 * $spacing_vertical};
  226. }
  227. .widget_archive,
  228. .widget_categories,
  229. .widget_links,
  230. .widget_meta,
  231. .widget_nav_menu,
  232. .widget_pages,
  233. .widget_recent_comments,
  234. .widget_recent_entries,
  235. .widget_rss,
  236. .widget_rss_links,
  237. .widget_top-posts,
  238. .widget_authors,
  239. .widget_jp_blogs_i_follow,
  240. .widget_top-click,
  241. .widget_upcoming_events_widget {
  242. ul {
  243. padding-left: 0;
  244. margin-right: 0;
  245. list-style: none;
  246. li {
  247. color: map-deep-get($config-global, "color", "foreground", "light");
  248. font-weight: 600;
  249. }
  250. ul {
  251. counter-reset: submenu;
  252. }
  253. ul > li > a::before {
  254. font-weight: normal;
  255. content: "\2013\00a0" counters(submenu, "\2013\00a0", none);
  256. counter-increment: submenu
  257. }
  258. }
  259. }
  260. .widget_tag_cloud {
  261. .tagcloud {
  262. font-weight: 600;
  263. }
  264. }
  265. .widget_search {
  266. .search-field {
  267. width: 100%;
  268. @include media(mobile) {
  269. width: auto;
  270. }
  271. }
  272. .search-submit {
  273. display: block;
  274. margin-top: $typescale-base;
  275. }
  276. }
  277. .widget_calendar .calendar_wrap {
  278. text-align: center;
  279. table td,
  280. table th {
  281. border: none;
  282. }
  283. a {
  284. text-decoration: underline;
  285. }
  286. }
  287. .widget_links li,
  288. .widget_jp_blogs_i_follow li,
  289. .widget_rss_links li {
  290. font-family: inherit;
  291. font-family: var( --font-base, inherit );
  292. }
  293. /**
  294. * Blocks
  295. */
  296. .wp-block-cover,
  297. .wp-block-cover-image,
  298. .has-background {
  299. .wp-block-separator {
  300. border-color: currentColor;
  301. }
  302. }
  303. .wp-block-latest-posts {
  304. > li {
  305. > a {
  306. color: map-deep-get($config-global, "color", "foreground", "default");
  307. display: inline-block;
  308. text-decoration: none;
  309. &:hover,
  310. &:focus,
  311. &:active {
  312. color: map-deep-get($config-global, "color", "primary", "default");
  313. .has-background:not(.has-background-background-color) & {
  314. color: currentColor;
  315. text-decoration: underline;
  316. }
  317. }
  318. }
  319. }
  320. .wp-block-latest-posts__post-excerpt,
  321. .wp-block-latest-posts__post-full-content {
  322. margin-top: $spacing_unit;
  323. }
  324. }