From c2522b642cc5bee2eacefa77a9dd3523034d5c5a Mon Sep 17 00:00:00 2001 From: Kailas Nadh U <53608019+kailasnadh790@users.noreply.github.com> Date: Wed, 17 Jan 2024 09:51:34 -0500 Subject: [PATCH 1/2] Homepage styling: issue #72 (#73) * carousel fix * carousel fix * Update styles.css * buttons * review comments --- cigaradvisor/blocks/authorcard/authorcard.css | 2 +- cigaradvisor/blocks/carousel/carousel.css | 26 +++-- cigaradvisor/blocks/carousel/carousel.js | 13 ++- cigaradvisor/icons/decorleft.png | Bin 0 -> 144 bytes cigaradvisor/icons/decorright.png | Bin 0 -> 144 bytes cigaradvisor/scripts/scripts.js | 6 +- cigaradvisor/styles/styles.css | 103 ++++++++++++++++-- 7 files changed, 126 insertions(+), 24 deletions(-) create mode 100644 cigaradvisor/icons/decorleft.png create mode 100644 cigaradvisor/icons/decorright.png diff --git a/cigaradvisor/blocks/authorcard/authorcard.css b/cigaradvisor/blocks/authorcard/authorcard.css index fa9233bb..55c33953 100644 --- a/cigaradvisor/blocks/authorcard/authorcard.css +++ b/cigaradvisor/blocks/authorcard/authorcard.css @@ -145,7 +145,7 @@ text-overflow: ellipsis; display: block; color: var(--clr-white); - font-weight: var(--font-weight-extrabold); + font-weight: var(--font-weight-bold); font-size: var(--body-font-size-xl); } diff --git a/cigaradvisor/blocks/carousel/carousel.css b/cigaradvisor/blocks/carousel/carousel.css index 51ebe4cb..e2451d08 100644 --- a/cigaradvisor/blocks/carousel/carousel.css +++ b/cigaradvisor/blocks/carousel/carousel.css @@ -7,6 +7,7 @@ margin-right: auto; max-width: 1080px; overflow: hidden; + margin-bottom: 25px; } .carousel.block>div { @@ -47,6 +48,8 @@ padding: 0; margin: 0; border: none; + width: 0; + line-height: none; } .carousel.block>button.prev { @@ -60,7 +63,7 @@ .carousel.block .carousel-arrow { - display: inline-block; + display: flex; cursor: pointer; position: absolute; z-index: 9; @@ -70,29 +73,34 @@ text-align: center; width: 30px; height: 50px; + align-items: center; } .carousel.block .carousel-arrow .prev-icon, .carousel.block .carousel-arrow .next-icon { - display: inline-block; + display: flex; font-size: 45px; color: #fff; } -.carousel.block .carousel-arrow .next-icon { - transform: rotate(180deg); - margin: 10%; +.carousel.block .carousel-arrow .next-icon::before { + content: '\f054'; + font-family: var(--ff-fontawesome); + padding-left: 50%; + font-size: var(--body-font-size-xxl); } -.carousel.block .carousel-arrow .prev-icon { - margin: -10%; +.carousel.block .carousel-arrow .prev-icon::before { + content: '\f053'; + font-family: var(--ff-fontawesome); + padding-left: 50%; + font-size: var(--body-font-size-xxl); } -.carousel.block .arrow-prev { +.carousel.block .carousel-arrow.arrow-prev.disabled, .carousel.block .carousel-arrow.arrow-next.disabled { display: none; } - @media screen and (min-width: 600px) { .carousel.block .slide { flex: 1 0 50%; diff --git a/cigaradvisor/blocks/carousel/carousel.js b/cigaradvisor/blocks/carousel/carousel.js index 47443159..d1c42944 100644 --- a/cigaradvisor/blocks/carousel/carousel.js +++ b/cigaradvisor/blocks/carousel/carousel.js @@ -32,10 +32,13 @@ function createButtons(moveSlides) { button.classList.add(direction); const iconDiv = document.createElement('div'); iconDiv.classList.add(`arrow-${direction}`); + if (direction === 'prev') { + iconDiv.classList.add('disabled'); + } iconDiv.classList.add('carousel-arrow'); const iconSpan = document.createElement('span'); iconSpan.classList.add(`${direction}-icon`); - iconSpan.innerHTML = '‹'; + iconSpan.innerHTML = ''; iconDiv.append(iconSpan); button.appendChild(iconDiv); button.addEventListener('click', () => moveSlides(direction)); @@ -86,17 +89,17 @@ export default async function decorate(block) { if (currentIndex < (items.length - itemsToShow)) { currentIndex += 1; slidesWrapper.style.transform = `translate3d(-${currentIndex * offset}%, 0, 0)`; - block.querySelector('.arrow-prev').style.display = 'inline-block'; + block.querySelector('.arrow-prev').classList.remove('disabled'); if (currentIndex === (items.length - itemsToShow)) { - block.querySelector('.arrow-next').style.display = 'none'; + block.querySelector('.arrow-next').classList.add('disabled'); } } } else if (currentIndex >= 1) { currentIndex -= 1; slidesWrapper.style.transform = `translate3d(-${currentIndex * offset}%, 0, 0)`; - block.querySelector('.arrow-next').style.display = 'inline-block'; + block.querySelector('.arrow-next').classList.remove('disabled'); if (currentIndex < 1) { - block.querySelector('.arrow-prev').style.display = 'none'; + block.querySelector('.arrow-prev').classList.add('disabled'); } } } diff --git a/cigaradvisor/icons/decorleft.png b/cigaradvisor/icons/decorleft.png new file mode 100644 index 0000000000000000000000000000000000000000..3cbe4b56040f7df9ee06fd5a847c0c16b87a09bd GIT binary patch literal 144 zcmeAS@N?(olHy`uVBq!ia0vp^+kjY@gAGX9Dt?ayQsJI1jv*Dd-rjQLWl-Q@IT&?7 z-tR+0h)zRWod=ikNvjvHFLf|Id*ORZ#Fekwd*&*cZuqO) r%W{As8@8Ud|91EAwzH?~x0NuQ{$XUc>*wvwKnVsPH literal 0 HcmV?d00001 diff --git a/cigaradvisor/icons/decorright.png b/cigaradvisor/icons/decorright.png new file mode 100644 index 0000000000000000000000000000000000000000..d12e9c4deab564d24c359a934dc72f75eaefd04a GIT binary patch literal 144 zcmeAS@N?(olHy`uVBq!ia0vp^+kjY@i5W;b_{*OHQak}ZA+A8WuQ~>T9=xyh0`i$l zg8YIR1mC@r)z}E+8hE-mhE&{2=1}F4kq~%bpIE@)`BUrAg2qIbrhp&^2E&Ja4DubE j { const text = link.textContent; const textToClass = text.trim().toLowerCase().replace(/\s/g, '-'); - link.classList.add(textToClass); - link.textContent = ''; + if (textToClass) { + link.classList.add(textToClass); + link.textContent = ''; + } }); } diff --git a/cigaradvisor/styles/styles.css b/cigaradvisor/styles/styles.css index cb818bb0..d5184f67 100644 --- a/cigaradvisor/styles/styles.css +++ b/cigaradvisor/styles/styles.css @@ -138,10 +138,14 @@ --subdued-gold: #b19b5e; --silver: #ccc; --very-light-grey: #ddd; + --vv-light-grey: #e0e0e0; + --medium-grey: #888; --grey: #333; --light-grey: #d3d3d3; --dark-grey: #3c3a3b; --off-white: #f7f7f7; + --grey-background: #eaeaea; + --charcoal: #1c1c1c; /* functional-colors */ --clr-text: var(--clr-dark-gray); @@ -172,7 +176,7 @@ --heading-font-size-xl: 40px; /* Font Weights */ - --font-weight-extrabold: 700; + --font-weight-extrabold: 900; --font-weight-bold: 700; --font-weight-semibold: 600; --font-weight-normal: 400; @@ -232,7 +236,7 @@ h1 { font-style: normal; font-weight: 400; text-transform: uppercase; - color: #141414; + color: var(--clr-dark-gray); margin: 2px auto; } @@ -321,10 +325,18 @@ button { max-width: 250px; } + .default-content-wrapper { color: var(--clr-text); } +main .default-content-wrapper{ + width: 100%; + margin-left: auto; + margin-right: auto; + max-width: 1080px; +} + /* Two-column grid */ main .section[data-layout="50/50"] { padding-left: 0; @@ -382,7 +394,7 @@ main .section[data-layout="50/50"] .right-grid>div { line-height: 30px; font-family: var(--ff-opensans); font-weight: 600; - color: #141414; + color: var(--clr-dark-gray); cursor: default; } @@ -390,7 +402,7 @@ main .section[data-layout="50/50"] .right-grid>div { font-size: 18px; line-height: 30px; text-decoration: underline; -color: #b19b5e; +color: var(--subdued-gold); } .blog-post-template .author-container>.default-content-wrapper .article-image-wrapper { @@ -410,12 +422,12 @@ color: #b19b5e; text-align: center; font-style: italic; font-weight: 700; - color: #888; + color: var(--medium-grey); margin: 0; } .blog-post-template .author-container>.default-content-wrapper blockquote { - border-color: #e0e0e0; + border-color: var(--vv-light-grey); border-width: 1px 0; border-style: solid; margin: 0 0 20px; @@ -426,7 +438,7 @@ color: #b19b5e; .blog-post-template .author-container>.default-content-wrapper blockquote p{ padding: 10px; margin: 0; - color: #1c1c1c; + color: var(--charcoal); background: transparent url('/cigaradvisor/images/blog-post/pattern-1.png') repeat; } @@ -434,6 +446,74 @@ color: #b19b5e; font-weight: 700; } +main .section>.default-content-wrapper>h2{ + text-align: center; + text-transform: uppercase; + font-family: var(--ff-montserrat); + font-weight: 900; + color: var(--tan); + padding: 38px 15px; + font-size: 45px; +} + +main .section>.default-content-wrapper>h2 ::before{ + content: 'decor'; + color: transparent; + background: url('../icons/decorleft.png') center no-repeat; + background-size: auto; + background-size: contain; + margin-right: 15px; +} + +main .section>.default-content-wrapper>h2 ::after{ + content: 'decor'; + color: transparent; + background: url('../icons/decorright.png') center no-repeat; + background-size: auto; + background-size: contain; + margin-left: 15px; +} + +main .button-container{ + padding : 10px 10px 40px; + text-align: center; + text-transform: uppercase; +} + +main .button-container .button{ + font-style: normal; + font-family: var(--ff-montserrat); + font-weight: 700; + color: var(--clr-white); + text-transform: uppercase; + background-color: var(--clr-black); + border-color: var(--tan); + border-width: 2px; + border-radius: 0; + border-style: solid; + display: inline-block; + line-height: 26px; + height: 50px; + width: 250px; + max-height: 50px; + max-width: 250px; + min-height: 2.85rem; + padding: 0.8em 1em; + cursor: pointer; + text-decoration: none; + text-align: center; + margin: 2px 0; +} + +main .button-container .button:hover{ + transition: .5s; + background-color: var(--subdued-gold); + border-color: var(--subdued-gold); + text-decoration: none; +} + + + @media screen and (max-width: 600px) { main .section[data-layout="50/50"] { width: 100%; @@ -451,6 +531,15 @@ color: #b19b5e; h1 { font-size: 45px; } + + main .section { + margin-bottom: 40px; + } + + main .section.background-grey { + background-color: var(--grey-background); + } + } @media screen and (min-width: 1200px) { From f03cdde5a3fe6635781216ed97efcca85070e4a0 Mon Sep 17 00:00:00 2001 From: Bryan Stopp Date: Wed, 17 Jan 2024 09:39:58 -0600 Subject: [PATCH 2/2] Refactor Hero slightly. (#75) * Push all hero markup generation logic into the hero block. * lint. * Bad merge. --- cigaradvisor/blocks/authorcard/authorcard.js | 3 +- cigaradvisor/blocks/footer/footer.js | 4 +- cigaradvisor/blocks/hero/hero.css | 163 ++++++++----------- cigaradvisor/blocks/hero/hero.js | 30 ++++ cigaradvisor/scripts/scripts.js | 48 ++---- cigaradvisor/styles/styles.css | 132 +++++++-------- 6 files changed, 173 insertions(+), 207 deletions(-) diff --git a/cigaradvisor/blocks/authorcard/authorcard.js b/cigaradvisor/blocks/authorcard/authorcard.js index 8483f265..c098a3b9 100644 --- a/cigaradvisor/blocks/authorcard/authorcard.js +++ b/cigaradvisor/blocks/authorcard/authorcard.js @@ -53,7 +53,8 @@ export default async function decorate(block) { authorWrapperSection.innerHTML += authorContents.join(''); }) .catch((error) => { - console.error('Error fetching author info:', error); + // eslint-disable-next-line no-console + console.log('Error fetching author info:', error); }); rightDiv.replaceChildren(authorWrapperSection); block.append(rightDiv); diff --git a/cigaradvisor/blocks/footer/footer.js b/cigaradvisor/blocks/footer/footer.js index 2ccefb90..41600ed3 100644 --- a/cigaradvisor/blocks/footer/footer.js +++ b/cigaradvisor/blocks/footer/footer.js @@ -25,7 +25,7 @@ export default async function decorate(block) { // create section const section = document.createElement('div'); section.classList.add('nav-section'); - if (currentElement.tagName === 'H1') { + if (currentElement.tagName === 'h4') { section.classList.add('with-heading'); } @@ -34,7 +34,7 @@ export default async function decorate(block) { nextElement = currentElement.nextSibling; section.appendChild(currentElement); currentElement = nextElement; - } while (nextElement && nextElement.tagName !== 'H1'); + } while (nextElement && nextElement.tagName !== 'h4'); // add section to container footerContainer.insertBefore(section, currentElement); diff --git a/cigaradvisor/blocks/hero/hero.css b/cigaradvisor/blocks/hero/hero.css index be5c6044..9f61b37b 100644 --- a/cigaradvisor/blocks/hero/hero.css +++ b/cigaradvisor/blocks/hero/hero.css @@ -1,133 +1,110 @@ -/* block specific CSS goes here */ - -main .hero-container>div { - max-width: unset; -} +/** Override global settings **/ main .hero-container { padding: 0; margin-bottom: 10%; } -main .hero.block { - position: relative; - padding: 32px; - min-height: 300px; - text-align: center; - line-height: 1; - letter-spacing: 3px; - color: var(--off-white); - text-shadow: 3px 3px var(--clr-black); - text-wrap: nowrap; +main .hero-container > div { + max-width: unset; } -main .hero.block>div>div { - display: flex; - justify-content: center; - align-items: center; - height: 100%; +/** Hero Stuff **/ +main .hero.block { + position: relative; } -main .hero.block h1 { - max-width: 1200px; - margin-left: auto; - margin-right: auto; - color: white; +main .hero.block.under-nav { + margin-top: -43px; } -main .hero.block picture { +main .hero.block .hero-image { + z-index: -9999; + display: block; position: absolute; - z-index: -1; top: 0; left: 0; - bottom: 0; - right: 0; - object-fit: cover; - box-sizing: border-box; + height: 100%; + width: 100%; + overflow: clip; } -main .hero.block img { +main .hero.block .hero-image picture { + display: block; + height: 100%; + width: 100%; + position: relative; +} + +main .hero.block .hero-image img { + object-position: center center; object-fit: cover; - margin-top: 1%; - height: 85%; + height: 100%; + width: 100%; } main .hero.block .hero-content { - position: absolute; - top: 25%; - left: 0; - right: 0; - bottom: 0; - display: flex; - flex-flow: column; - justify-content: center; - align-items: center; - padding: 0 1rem; + padding-top: 80px; +} + +main .hero.block h1 { color: var(--clr-white); - text-shadow: 0 0 1rem var(--clr-black); + text-align: center; + line-height: 1; + letter-spacing: 3px; + text-shadow: 3px 3px var(--clr-black); } /* hero search */ -main .hero.block .hero-search .search-box{ +main .hero.block .hero-search { display: flex; justify-content: center; + margin: 30px auto 0; } -main .hero.block .hero-search{ - margin: 20px auto; - width: 100%; -} - -main .hero.block .search{ +main .hero.block .hero-search form { + display: flex; width: 70%; -} - -main .hero.block .search form { border-bottom: 4px solid var(--clr-dark-gray); padding-bottom: 10px; } -main .hero.block .search form .focused{ - transition: 1s; - background-color: var(--light-grey); +/* set form input placeholder text color color: var(--clr-dark-gray); */ +main .hero.block .hero-search form input { + flex: 1; + padding-left: 18px; + height: 45px; + width: 100%; + border: none; + font-weight: var(--font-weight-bold); + font-size: var(--body-font-size-l); + line-height: 27px; + transition: background-color 1s; + background-color: transparent; } -main .hero.block .search form button { - position: relative; - top: 0; - right: 0; - background: 0 0; +main .hero.block .hero-search form input::placeholder { color: var(--clr-dark-gray); - width: 2.85rem; - padding: 0; - line-height: 2.85rem; - margin: 0; - border: none; - border-radius: 0; } -/* set form input placeholder text color color: var(--clr-dark-gray); */ -main .hero.block .search form input { - color: var(--clr-dark-gray); +main .hero.block .hero-search form input:focus { border: none; - font-weight: 700; - font-size: 18px; - text-transform: capitalize; - width: 100%; - background: 0 0; - position: relative; - left: 0; - max-width: 100%; - z-index: 1; + transition: background-color 1s; + background-color: var(--light-grey); } -main .hero.block .search form input::placeholder { - color: var(--clr-dark-gray); +main .hero.block .hero-search form button { + flex: 0 1; + height: 100%; + width: 100%; + background: transparent; + border: none; } -main .hero.block .search form button::before { +main .hero.block .hero-search form button::before { position: relative; - width: 2em; + height: 100%; + width: 100%; font-size: 30px; content: "\f002"; text-align: center; @@ -136,18 +113,16 @@ main .hero.block .search form button::before { } @media screen and (min-width: 900px) { - main .hero.block img { - width: 100%; - height: 185%; - max-width: none; - margin-top: -65px; + main .hero.block.under-nav { + margin-top: -70px; } - main .hero.block .search{ - width: 30%; + main .hero.block .hero-content { + padding-top: 200px; + padding-bottom: 100px; } - main .hero.block .hero-content { - top: 100%; + main .hero.block .hero-search form { + width: 30%; } } diff --git a/cigaradvisor/blocks/hero/hero.js b/cigaradvisor/blocks/hero/hero.js index e69de29b..814a9294 100644 --- a/cigaradvisor/blocks/hero/hero.js +++ b/cigaradvisor/blocks/hero/hero.js @@ -0,0 +1,30 @@ +import { getMetadata } from '../../scripts/aem.js'; + +function buildSearch() { + const search = document.createElement('div'); + search.classList.add('hero-search'); + search.innerHTML = ` +
+ + + +
+ `; + return search; +} + +export default async function decorate(block) { + const style = getMetadata('hero-style'); + if (style) { + block.classList.add(style.toLowerCase()); + } + + const header = block.querySelector('h1'); + const image = document.createElement('div'); + image.classList.add('hero-image'); + image.replaceChildren(block.querySelector('picture')); + const content = document.createElement('div'); + content.classList.add('hero-content'); + content.append(header, buildSearch()); + block.replaceChildren(image, content); +} diff --git a/cigaradvisor/scripts/scripts.js b/cigaradvisor/scripts/scripts.js index 005722b8..7ebcf2d7 100644 --- a/cigaradvisor/scripts/scripts.js +++ b/cigaradvisor/scripts/scripts.js @@ -24,33 +24,16 @@ function buildHeroBlock(main) { const h1 = main.querySelector('h1'); const picture = main.querySelector('picture'); // eslint-disable-next-line no-bitwise - if (h1 && picture && (h1.compareDocumentPosition(picture) & Node.DOCUMENT_POSITION_PRECEDING)) { - const section = document.createElement('div'); - section.classList.add('section--hero'); - const heroContent = document.createElement('div'); - heroContent.classList.add('hero-content'); - const search = document.createElement('div'); - search.classList.add('search'); - search.innerHTML = ``; - heroContent.append(h1); - heroContent.append(search); - section.append(buildBlock('hero', { elems: [picture, heroContent] })); + if (h1 && picture && (h1.compareDocumentPosition(picture) & Node.DOCUMENT_POSITION_PRECEDING) + && h1.parentElement === picture.closest('div')) { + let section = document.createElement('div'); + if (h1.parentElement.childElementCount === 2) { + section = h1.parentElement; + } + const p = picture.parentElement; + section.replaceChildren(buildBlock('hero', { elems: [h1, picture] })); main.prepend(section); - // on-focus of input, add class to form - const searchInput = main.querySelector('.hero-search input'); - searchInput.addEventListener('focus', () => { - searchInput.parentNode.classList.add('focused'); - }); - // on-blur of input, remove class from form - searchInput.addEventListener('blur', () => { - searchInput.parentNode.classList.remove('focused'); - }); + p.remove(); } } @@ -59,6 +42,9 @@ function buildHeroBlock(main) { * @param {HTMLElement} mainEl - The main element to build the article header for. */ function buildArticleHeader(mainEl) { + if (!document.querySelector('body.blog-post-template')) { + return; + } // eslint-disable-next-line no-use-before-define decorateExternalLink(mainEl); const paragraphs = mainEl.querySelectorAll('p'); @@ -150,14 +136,8 @@ async function loadFonts() { */ function buildAutoBlocks(main) { try { - const isHome = document.querySelector('body.homepage'); - const isBlogPost = document.querySelector('body.blog-post-template'); - if (isHome) { - buildHeroBlock(main); - } - if (isBlogPost) { - buildArticleHeader(main); - } + buildHeroBlock(main); + buildArticleHeader(main); } catch (error) { // eslint-disable-next-line no-console console.error('Auto Blocking failed', error); diff --git a/cigaradvisor/styles/styles.css b/cigaradvisor/styles/styles.css index d5184f67..4a3f45bf 100644 --- a/cigaradvisor/styles/styles.css +++ b/cigaradvisor/styles/styles.css @@ -183,17 +183,17 @@ --font-weight-light: 300; --font-weight-thin: 100; - /* Body */ - --body-font-size-xxs: 10px; - --body-font-size-xs: 12px; - --body-font-size-s: 14px; - --body-font-size-m: 16px; - --body-font-size-l: 18px; - --body-font-size-xl: 20px; - --body-font-size-xxl: 24px; + /* Body */ + --body-font-size-xxs: 10px; + --body-font-size-xs: 12px; + --body-font-size-s: 14px; + --body-font-size-m: 16px; + --body-font-size-l: 18px; + --body-font-size-xl: 20px; + --body-font-size-xxl: 24px; /* misc */ - --nav-height: 60px; + --nav-height: 100px; --icon-size: var(--text-size-xl); } @@ -210,6 +210,9 @@ body.appear { header { height: var(--nav-height); + position: relative; + background-color: var(--clr-white); + z-index: 1000; } html { @@ -249,7 +252,7 @@ h2 { font-size: 12px; } -b,strong{ +b, strong { font-weight: bolder; } @@ -293,36 +296,8 @@ li { cursor: default; } -input { - font-size: 1em; - font-family: var(--ff-arial); - height: 2.85rem; - padding: 0 .5em; - padding-right: 0.5em; - padding-left: 0.5em; - outline: none; - border: 1px solid; - width: 100%; - max-width: 100%; - vertical-align: middle; - background-color: var(--clr-white); - border-color: var(--very-light-grey); - margin: 0; -} - -button { - font-family: montserrat, sans-serif; - font-weight: 700; - color: var(--clr-white); - text-transform: uppercase; - background-color: var(--tan); - border-color: var(--tan); - display: inline-block; - line-height: 26px; - height: 50px; - width: 250px; - max-height: 50px; - max-width: 250px; +.sr-only { + display: none; } @@ -330,7 +305,7 @@ button { color: var(--clr-text); } -main .default-content-wrapper{ +main .default-content-wrapper { width: 100%; margin-left: auto; margin-right: auto; @@ -349,17 +324,17 @@ main .section[data-layout="50/50"] { display: flex; } -main .section[data-layout="50/50"]>div { +main .section[data-layout="50/50"] > div { display: flex; flex-basis: 100%; flex-direction: column; } -main .section[data-layout="50/50"] .left-grid>div { +main .section[data-layout="50/50"] .left-grid > div { padding: 10px; } -main .section[data-layout="50/50"] .right-grid>div { +main .section[data-layout="50/50"] .right-grid > div { padding: 10px; } @@ -380,7 +355,7 @@ main .section[data-layout="50/50"] .right-grid>div { /* Blog post template starts */ -.blog-post-template .author-container>.default-content-wrapper { +.blog-post-template .author-container > .default-content-wrapper { padding: 0 15px; width: 100%; margin-left: auto; @@ -389,7 +364,7 @@ main .section[data-layout="50/50"] .right-grid>div { text-align: justify; } -.blog-post-template .author-container>.default-content-wrapper p { +.blog-post-template .author-container > .default-content-wrapper p { font-size: 18px; line-height: 30px; font-family: var(--ff-opensans); @@ -398,25 +373,25 @@ main .section[data-layout="50/50"] .right-grid>div { cursor: default; } -.blog-post-template .author-container>.default-content-wrapper a{ +.blog-post-template .author-container > .default-content-wrapper a { font-size: 18px; line-height: 30px; text-decoration: underline; -color: var(--subdued-gold); + color: var(--subdued-gold); } -.blog-post-template .author-container>.default-content-wrapper .article-image-wrapper { +.blog-post-template .author-container > .default-content-wrapper .article-image-wrapper { width: 1000px; padding: 20px; max-width: 100%; clear: both; } -.blog-post-template .author-container>.default-content-wrapper picture img { +.blog-post-template .author-container > .default-content-wrapper picture img { padding: 20px 20px 20px 0; } -.blog-post-template .author-container>.default-content-wrapper .article-image-caption { +.blog-post-template .author-container > .default-content-wrapper .article-image-caption { font-family: var(--ff-opensans); font-size: 16px; text-align: center; @@ -426,7 +401,7 @@ color: var(--subdued-gold); margin: 0; } -.blog-post-template .author-container>.default-content-wrapper blockquote { +.blog-post-template .author-container > .default-content-wrapper blockquote { border-color: var(--vv-light-grey); border-width: 1px 0; border-style: solid; @@ -435,18 +410,18 @@ color: var(--subdued-gold); background: transparent url('/cigaradvisor/images/blog-post/blockquote.png') no-repeat 0 20px; } -.blog-post-template .author-container>.default-content-wrapper blockquote p{ +.blog-post-template .author-container > .default-content-wrapper blockquote p { padding: 10px; margin: 0; color: var(--charcoal); background: transparent url('/cigaradvisor/images/blog-post/pattern-1.png') repeat; } -.blog-post-template .author-container>.default-content-wrapper blockquote p strong{ +.blog-post-template .author-container > .default-content-wrapper blockquote p strong { font-weight: 700; } -main .section>.default-content-wrapper>h2{ +main .section > .default-content-wrapper > h2 { text-align: center; text-transform: uppercase; font-family: var(--ff-montserrat); @@ -456,31 +431,29 @@ main .section>.default-content-wrapper>h2{ font-size: 45px; } -main .section>.default-content-wrapper>h2 ::before{ +main .section > .default-content-wrapper > h2 ::before { content: 'decor'; - color: transparent; - background: url('../icons/decorleft.png') center no-repeat; - background-size: auto; - background-size: contain; - margin-right: 15px; + color: transparent; + background: url('../icons/decorleft.png') center no-repeat; + background-size: contain; + margin-right: 15px; } -main .section>.default-content-wrapper>h2 ::after{ +main .section > .default-content-wrapper > h2 ::after { content: 'decor'; - color: transparent; - background: url('../icons/decorright.png') center no-repeat; - background-size: auto; - background-size: contain; - margin-left: 15px; + color: transparent; + background: url('../icons/decorright.png') center no-repeat; + background-size: contain; + margin-left: 15px; } -main .button-container{ - padding : 10px 10px 40px; +main .button-container { + padding: 10px 10px 40px; text-align: center; text-transform: uppercase; } -main .button-container .button{ +main .button-container .button { font-style: normal; font-family: var(--ff-montserrat); font-weight: 700; @@ -505,7 +478,7 @@ main .button-container .button{ margin: 2px 0; } -main .button-container .button:hover{ +main .button-container .button:hover { transition: .5s; background-color: var(--subdued-gold); border-color: var(--subdued-gold); @@ -513,7 +486,6 @@ main .button-container .button:hover{ } - @media screen and (max-width: 600px) { main .section[data-layout="50/50"] { width: 100%; @@ -528,6 +500,14 @@ main .button-container .button:hover{ } @media screen and (min-width: 900px) { + :root { + --nav-height: 130px; + } + + header { + background-color: transparent; + } + h1 { font-size: 45px; } @@ -535,7 +515,7 @@ main .button-container .button:hover{ main .section { margin-bottom: 40px; } - + main .section.background-grey { background-color: var(--grey-background); } @@ -546,12 +526,12 @@ main .button-container .button:hover{ h2 { font-size: 16px; } - - a,p { + + a, p { font-size: 14px; } - .blog-post-template .author-container>.default-content-wrapper { + .blog-post-template .author-container > .default-content-wrapper { padding: 0; } }