:root { --fg-color: #34201A; --bg-color: #f5f5f5; --bg-alt-color: #eee5d3; --gray-color: #9d9d9d; --yellow-color: #f8a911; --yellow-alt-color: #ffce6f; --yellow-dark-color: #b27606; --default-border: 2px solid var(--gray-color); } html { font-size: 100%; } body { background-color: var(--bg-color); font-family: 'Inter', sans-serif; font-weight: 400; padding: 0; margin: 0 auto; line-height: 1.75; color: var(--fg-color); } /* ========================================================================== Typography ========================================================================== */ p { margin-top: 0; margin-bottom: 1rem; } a { color: var(--fg-color); } h1, h2, h3, h4, h5 { margin: 0; font-weight: 700; line-height: 1.3; margin-bottom: 1rem; } h1 { margin-top: 0; font-size: 2.488rem; } h2 { font-size: 2.074rem; } h3 { font-size: 1.728rem; } h4 { font-size: 1.44rem; } h5 { font-size: 1.2rem; } small, .text-small { font-size: 0.833rem; } blockquote { margin: 0 0 1rem; padding: 0; } blockquote q { /*font-weight: bold;*/ font-size: 1.5rem; } blockquote cite { display: block; } .text-center { text-align: center; } /* ========================================================================== Tables ========================================================================== */ table { border-collapse: collapse; border-spacing: 0; font: inherit; width: 100%; margin-bottom: 1rem; border: 1px solid var(--gray-color); } td, th { font: inherit; text-align: left; font-size: 0.85em; padding: 2px 10px; border-bottom: 1px solid; border-color: var(--gray-color); } th { font-weight: bold; } table a { white-space: normal; } /* ========================================================================== Forms ========================================================================== */ input[type=text], input[type=email], input[type=number], input[type=date], input[type=password], select, textarea { color: var(--fg-color); border: var(--default-border); padding: 0.5rem; outline: 0; box-sizing: border-box; } input:focus, textarea:focus { border-color: var(--yellow-color); } select[multiple=multiple] { height: 8rem; } input[type=radio], input[type=checkbox] { width: 2rem; height: 2rem; vertical-align: middle; } input[type=radio] + label, input[type=checkbox] + label { display: inline-block; margin: 1rem 0; } textarea { width: 100%; height: 6.25rem; } ::-webkit-input-placeholder { font-style: oblique; } ::-moz-input-placeholder { font-style: oblique; } ::-ms-input-placeholder { font-style: oblique; } button, input[type=submit], .action-button { font-family: inherit; font-weight: bold; font-size: 1.5rem; text-decoration: none; text-transform: lowercase; font-variant: small-caps; white-space: nowrap; color: var(--fg-color); background-color: var(--yellow-color); padding: 0.25rem 1rem; border-radius: 0.2rem; border: none; cursor: pointer; } button, input[type=submit]:hover, .action-button:hover { background-color: var(--yellow-alt-color); } figure { margin: 0; padding: 0; box-sizing: border-box; } img { box-sizing: border-box; max-width: 100%; } /* ========================================================================== Base Layout ========================================================================== */ .site__header > nav, main > article, footer > section { max-width: 1024px; padding: 1rem; margin: 0 auto; } /* ========================================================================== Modal ========================================================================== */ .modal-menu { display: none; position: fixed; /* Stay in place */ z-index: 1; /* Sit on top */ left: 0; top: 0; width: 100%; /* Full width */ height: 100%; /* Full height */ overflow: auto; /* Enable scroll if needed */ background-color: rgb(0,0,0); /* Fallback color */ background-color: rgba(0,0,0,0.4); /* Black w/ opacity */ } /* Modal Content/Box */ .modal-menu__content { background-color: var(--bg-color); margin: 25vh auto; padding: 20px; border: var(--default-border); max-width: 40rem; } .modal-menu__header { display: flex; justify-content: space-between; align-items: baseline; } /* The Close Button */ .close-modal { color: #aaa; font-size: 2rem; line-height: 0; font-weight: bold; } .close-modal:hover, .close-modal:focus { color: var(--fg-color); text-decoration: none; cursor: pointer; } /* ========================================================================== Site ========================================================================== */ .site__ft-stamp { max-width: 6rem; } /* Site Header ========================================================================== */ .site__header { background-color: var(--bg-alt-color); } .site__logo > img { height: 4rem; } /* Site Nav ========================================================================== */ .site__nav { display: flex; justify-content: space-between; align-items: center; } .site__logo, .nav__main, .nav__account { margin-right: 1rem; } @media screen and (max-width: 900px) { .site__logo, .nav__main, .nav__account { margin-right: 0; } .site__nav { display: grid; grid-template-columns: 2fr 0.5fr 0.5fr; gap: 1rem; } .site__logo { grid-column: 1; } .nav__main { grid-column: 1/4; grid-row: 2; justify-content: space-between; } .nav__account { grid-column: 2; grid-row: 1; } .site__cart { grid-column: 3; grid-row: 1; } } @media screen and (max-width: 400px) { .site__nav { grid-template-columns: repeat(2, 1fr); } .site__logo { grid-column: span 2; justify-self: center; } .nav__main { grid-column: 1/3; grid-row: 3; } .nav__account { grid-column: 1; grid-row: 2; } .site__cart { grid-column: 2; grid-row: 2; } } .nav__list { list-style: none; margin: 0; padding: 0; display: flex; } .nav__menu { position: relative; } .nav__link { text-transform: lowercase; font-variant: small-caps; font-weight: bold; text-decoration: none; white-space: nowrap; } .nav__list li:not(:last-child) { margin-right: 1rem; } .nav__list.menu { flex-direction: column; } .nav__dropdown { list-style: none; margin: 0; padding: 0; background-color: var(--bg-color); border: var(--default-border); padding: 0.5rem; position: absolute; top: 100%; right: 0; z-index: 1000; display: none; } @media screen and (max-width: 400px) { .nav__dropdown { left: 0; right: unset; } } .nav__menu:hover .nav__dropdown { display: flex; flex-direction: column; } /* Site Cart ========================================================================== */ .site__cart { display: flex; justify-content: center; align-items: center; justify-self: end; font-family: inherit; font-weight: bold; text-decoration: none; text-transform: lowercase; font-variant: small-caps; color: var(--fg-color); background-color: var(--yellow-color); padding: 0.25rem 1rem; border-radius: 0.2rem; cursor: pointer; } .cart__count { font-size: 1rem; } .cart__icon { height: 2rem; } /* ========================================================================== Articles ========================================================================== */ article > header { margin-bottom: 1rem; } .article__header--with-action { display: flex; justify-content: space-between; align-items: center; } article + article { margin-top: 8rem; } /* Product reviews ========================================================================== */ .review__list { display: grid; grid-template-columns: repeat(2, 1fr); gap: 4rem; } .review__list-short { margin: inherit auto; max-width: 64ch; text-align: center; } .review__item { text-align: center; } @media screen and (max-width: 600px) { .review__list { grid-template-columns: 1fr; } } /* Products ========================================================================== */ .product__list { display: grid; grid-template-columns: repeat(2, 1fr); gap: 4rem; } .product__item { text-decoration: none; display: grid; grid-template-columns: repeat(2, 1fr); gap: 1rem; } .product__item h3 { text-decoration: underline; } @media screen and (max-width: 900px) { .product__list { grid-template-columns: 1fr; gap: 6rem; } .product__figure { grid-row: span 2; } } @media screen and (max-width: 600px) { .product__item { grid-template-columns: 1fr; } .product__figure { grid-row: 1; justify-self: center; } } /* Product Detail ========================================================================== */ .product__detail { display: grid; grid-template-columns: 0.25fr 2fr 1fr; gap: 1rem; } .gallery__thumbnail { border: var(--default-border); border-color: var(--bg-color); cursor: pointer; object-fit: cover; aspect-ratio: 1/1; } .gallery__image { text-align: center; } .gallery__thumbnail--focus { border-color: var(--yellow-color); } .product__form input, .product__form select { width: 100%; } @media screen and (max-width: 700px) { .product__detail { grid-template-columns: 0.25fr 2fr; } .product__info { grid-column: span 2; } } @media screen and (max-width: 700px) { .product__detail { grid-template-columns: 1fr; grid-template-rows: 4rem 1fr auto; } .product__gallery { display: flex; } .gallery__thumbnail { max-height: 4rem; } .gallery__thumbnail:not(:last-child) { margin-right: 0.5rem; } .product__image { max-height: 16rem; } .product__info { grid-column: 1; } } /* Shopping Cart ========================================================================== */ .cart__list { margin-bottom: 2rem; } .cart__item { padding: 1rem 0; border-bottom: var(--default-border); display: grid; grid-template-columns: 1fr 3fr 1fr; gap: 1rem; } .cart__table-wrapper { display: flex; justify-content: flex-end; } .cart__summary { text-align: right; } .cart__totals { width: unset; font-size: 1.5rem; } .cart__totals th, .cart__totals td { border: none; } .cart__totals th:first-child, .cart__totals td:first-child { text-align: right; } .cart__proceed { text-align: right; display: flex; align-items: center; justify-content: flex-end; } .cart__proceed > .action-button { font-size: 1.75rem; } .item__image { max-height: 12rem; } .item__price { justify-self: end; } .item__form p, .coupon__form p { display: flex; align-items: center; } .coupon__form p { justify-content: flex-end; } .item__form input[type=number] { max-width: 6rem; } .coupon__form input[type=text] { max-width: 8rem; } :is(.item__form, .coupon__form) label, :is(.item__form, .coupon__form) input:not(:last-child) { margin-right: 0.5rem; } @media screen and (max-width: 500px) { .cart__item { grid-template-columns: 2fr 1fr; } .cart__proceed { flex-direction: column; } .item__info { grid-column: span 2; grid-row: 2; } .item__price { grid-column: 2; grid-row: 1; } } /* Checkout / Shipping Address ========================================================================== */ .checkout__address-form input, .checkout__address-form select { display: block; width: 100%; max-width: 24rem; } .checkout__address { margin-bottom: 2rem; } #paypal-button-container { max-width: 24rem; margin-left: auto; } /* ========================================================================== Footer ========================================================================== */ footer { margin: 4rem 0 0; box-sizing: border-box; padding: 1rem 0; background-color: var(--bg-alt-color); } footer > section { text-align: center; }