/* Theme Name: Disco Theme URI: https://wordpress.com/theme/disco/ Author: Automattic Author URI: https://automattic.com/ Description: Disco is a funky, vibrant, opinionated theme with a monospaced font. Both its styles and spacing form an edgy aesthetic perfect for those looking to build a quirky website. Requires at least: 5.8 Tested up to: 6.0.1 Requires PHP: 5.7 Version: 1.0.6 License: GNU General Public License v2 or later License URI: http://www.gnu.org/licenses/gpl-2.0.html Text Domain: disco Tags: one-column, custom-colors, custom-menu, custom-logo, editor-style, featured-images, full-site-editing, block-patterns, rtl-language-support, theme-options, threaded-comments, translation-ready, wide-blocks Disco WordPress Theme, (C) 2021 Automattic, Inc. Disco is distributed under the terms of the GNU GPL. This program is free software: you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation, either version 2 of the License, or (at your option) any later version. This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details. */ /* * Font smoothing */ body { -moz-osx-font-smoothing: grayscale; -webkit-font-smoothing: antialiased; } a { text-underline-offset: .15em; /* We add text-decoration- here instead in theme.json because webkit browsers as Safari are not compatible with text-decoration shorthand syntax */ text-decoration-thickness: 1px!important; } .wp-block-site-title a { /* We add text-decoration- here instead in theme.json because webkit browsers as Safari are not compatible with text-decoration shorthand syntax */ text-decoration-thickness: 1.5px!important; } /* * Button hover styles. * Necessary until the following issue is resolved in Gutenberg: * https://github.com/WordPress/gutenberg/issues/27075 */ .wp-block-read-more:is(:hover, :focus) { background-color: var(--wp--preset--color--foreground); color: var(--wp--preset--color--background); } :is( .wp-block-search__button, .wp-block-file .wp-block-file__button, .wp-block-button__link, .wp-elements-button, ):where(:hover, :focus, :active) { background-color: var(--wp--preset--color--background); color: var(--wp--preset--color--foreground); border: 1.5px solid var(--wp--preset--color--foreground); } :is( .wp-block-search__button, .wp-block-file .wp-block-file__button, .wp-block-button__link, .wp-elements-button, .wp-block-read-more, ):where(:active) { border-style: dashed; } /* Overrides the Gutenberg styles for the outline button */ .wp-block-button.is-style-outline>.wp-block-button__link { padding-top: calc(0.05em + 2px); padding-right: calc(1.333em + 2px); padding-bottom: calc(0.05em + 2px); padding-left: calc(1.333em + 2px); border: 1.5px solid var(--wp--preset--color--foreground); } :is( .is-style-outline .wp-block-button__link, .is-style-outline .wp-element-button, .wp-block-post-comments-form input[type=submit], .wp-block-button.is-style-outline>.wp-block-button__link, /* < - Overrides the Gutenberg styles for the outline button */ ):is( :hover, :focus ) { background: var(--wp--preset--color--foreground); color: var(--wp--preset--color--background); } :is( .is-style-outline .wp-block-button__link, .is-style-outline .wp-element-button, .wp-block-post-comments-form input[type=submit], ):is( :active ) { background: var(--wp--preset--color--background); color: var(--wp--preset--color--foreground); border-style: dashed; } /* This is necesary to fix the outline style for the button in the editor */ :where(.is-style-outline) :is( .wp-block-button__link, .wp-element-button ) { border: 1px solid var(--wp--preset--color--foreground); } /* * Styles for the post list pattern */ .disco-post-list-pattern .wp-block-post-title { /* This is necesary to make the post list item the same height when the post has or lacks a featured image */ min-height: 60px; /* 60px is the height of the featured image used */ display: flex; justify-content: center; flex-direction: column; } .disco-post-list-pattern .wp-block-post-date { white-space: nowrap; } .disco-post-list-pattern .wp-block-read-more { text-align: center; word-break: keep-all; width: 100%; white-space: nowrap; } .disco-post-list-pattern .wp-block-post .post-date-container { flex-basis: min-content; flex-grow: unset; } .disco-post-list-pattern .wp-block-columns { height: 100%; } .disco-post-list-pattern .wp-block-column { align-items: center; display: flex; min-width: unset; } .disco-post-list-pattern .wp-block-post > .wp-block-group > .wp-block-columns > .wp-block-column:first-child { flex-grow: 3; } .disco-post-list-pattern .wp-block-post > .wp-block-group > .wp-block-columns > .wp-block-column:last-child > .wp-block-columns { width: 100%; } .disco-post-list-pattern .wp-block-column:empty { display: none; } /* Single post */ .featured-image-container:empty { display: none; } /* * Footer */ footer .wp-block-site-title a { text-decoration: none; } /* * Quote */ .wp-block-quote p { margin-bottom: 0 } .wp-block-quote cite { font-style: normal; font-size: var(--wp--preset--font-size--small); } .wp-block-quote cite::before { content: "— "; } /* * Selection */ ::selection{ background: var(--wp--preset--color--foreground); color: var(--wp--preset--color--background); } /* * Navigation */ .wp-block-navigation__responsive-container.is-menu-open .wp-block-navigation__responsive-container-content .wp-block-navigation__container { gap: 1rem; } .wp-block-navigation .wp-block-navigation__container .has-child .wp-block-navigation__submenu-container { font-size: var(--wp--preset--font-size--medium); border: 1px solid var(--wp--preset--color--foreground); } .wp-block-navigation__responsive-container.is-menu-open .wp-block-navigation__container > .wp-block-navigation-item > .wp-block-navigation-item__content { font-size: 2.5rem; } .wp-block-navigation-item__content { font-size: var(--wp--preset--font-size--large); } .wp-block-navigation__responsive-container.is-menu-open .wp-block-navigation__responsive-container-content .has-child .wp-block-navigation__submenu-container { padding: 0.5rem 1rem 0 1rem; gap: 0.5rem; } .wp-block-navigation__submenu-icon::after { content: ""; width: 1em; height: 1em; background-color: currentColor; -webkit-mask-image: url(assets/icons/arrow.svg); mask-image: url(assets/icons/arrow.svg); -webkit-mask-repeat: no-repeat; mask-repeat: no-repeat; display: block; -webkit-mask-size: 0.5em; mask-size: 0.5em; mask-position: left 30%; -webkit-mask-position: left 30%; } .wp-block-navigation__submenu-icon svg { display: none !important; } /* * Block search */ .wp-block-search__input { color: var(--wp--preset--color--foreground); } .wp-block-search__input:focus-visible { outline: 1.5px solid var(--wp--preset--color--foreground); } /* * Comments */ .wp-block-post-comments-form :is(textarea, input:not([type="submit"]) ) { background-color: var(--wp--preset--color--background); border: 1px solid var(--wp--preset--color--foreground); color: 1px solid var(--wp--preset--color--foreground); border-radius: 50px; padding: 2em; } .wp-block-post-comments-form :is(textarea, input:not([type="submit"]) ):focus-visible { outline: 1.5px solid var(--wp--preset--color--foreground); } .wp-block-comments-query-loop .depth-1 .wp-block-column:empty { display: none; } .wp-block-post-comments-form input[type="checkbox"] { appearance: none; height: 1.5rem; min-width: 1.5rem; padding: 0; border-radius: 1rem; position: relative; } .wp-block-post-comments-form input[type="checkbox"]:checked::after { background-color: var(--wp--preset--color--foreground); content: ""; position: absolute; width: 75%; height: 75%; border-radius: 1rem; top: 0; left: 0; bottom: 0; right: 0; margin: auto; } /* * Pullquote */ .wp-block-pullquote blockquote { margin: 0; } .wp-block-pullquote p { margin-block-start: var(--wp--custom--gap--vertical); margin-block-end: var(--wp--custom--gap--vertical); font-size: inherit; } .wp-block-pullquote cite { display: block; margin-block-end: var(--wp--custom--gap--vertical); font-style: normal; font-size: var(--wp--preset--font-size--small); font-weight: 400; } .wp-block-pullquote cite::before { content: "— "; } /* * Alignment styles, borrowed from Twenty Twenty-Two. * These rules are temporary, and should not be relied on or * modified too heavily by themes or plugins that build on * Twenty Twenty-Two. These are meant to be a precursor to * a global solution provided by the Block Editor. * * Relevant issues: * https://github.com/WordPress/gutenberg/issues/35607 * https://github.com/WordPress/gutenberg/issues/35884 */ .wp-site-blocks, body > .is-root-container, .edit-post-visual-editor__post-title-wrapper, .wp-block-group.alignfull, .wp-block-group.has-background, .wp-block-columns.alignfull.has-background, .wp-block-cover.alignfull, .is-root-container .wp-block[data-align='full'] > .wp-block-group, .is-root-container .wp-block[data-align='full'] > .wp-block-columns.has-background, .is-root-container .wp-block[data-align='full'] > .wp-block-cover { padding-left: var(--wp--custom--gap--horizontal); padding-right: var(--wp--custom--gap--horizontal); } .wp-site-blocks .alignfull, .wp-site-blocks > .wp-block-group.has-background, .wp-site-blocks > .wp-block-cover, .wp-site-blocks > .wp-block-template-part > .wp-block-group.has-background, .wp-site-blocks > .wp-block-template-part > .wp-block-cover, body > .is-root-container > .wp-block-cover, body > .is-root-container > .wp-block-template-part > .wp-block-group.has-background, body > .is-root-container > .wp-block-template-part > .wp-block-cover, .is-root-container .wp-block[data-align='full'] { margin-left: calc(-1 * var(--wp--custom--gap--horizontal)) !important; margin-right: calc(-1 * var(--wp--custom--gap--horizontal)) !important; max-width: unset; width: unset; } /* Blocks inside columns don't have negative margins. */ .wp-site-blocks .wp-block-columns .wp-block-column .alignfull, .is-root-container .wp-block-columns .wp-block-column .wp-block[data-align="full"], /* We also want to avoid stacking negative margins. */ .wp-site-blocks .alignfull:not(.wp-block-group) .alignfull, .is-root-container .wp-block[data-align="full"] > *:not(.wp-block-group) .wp-block[data-align="full"] { margin-left: auto !important; margin-right: auto !important; width: inherit; } /* * Responsive menu container padding. * This ensures the responsive container inherits the same * spacing defined above. This behavior may be built into * the Block Editor in the future. */ .wp-block-navigation__responsive-container.is-menu-open { padding-top: var(--wp--custom--gap--horizontal); padding-bottom: var(--wp--custom--gap--vertical); padding-right: var(--wp--custom--gap--horizontal); padding-left: var(--wp--custom--gap--horizontal); } /* * style seach input */ .wp-block-search__input { border-radius: 999px; padding: .5rem 2rem; background-color: transparent; border-color: var(--wp--preset--color--foreground); border-width: 1.5px; } @media screen and (max-width: 768px) { .wp-block-search__inside-wrapper { flex-wrap: wrap } .wp-block-search__button { flex-grow: 1; margin-left: 0; margin-top: .625rem; } } /* * Editor */ /* This will be necessary until this is fixed https://github.com/WordPress/gutenberg/issues/42441 */ .edit-post-visual-editor__post-title-wrapper .wp-block-post-title { font-size: clamp(2.5rem, calc(2.5rem + ((1vw - 0.48rem) * 8.4135)), 6.875rem); line-height: 1em; letter-spacing: -0.04em; }