diff --git a/ecommerce/regis/static/sass/base/_basket.scss b/ecommerce/regis/static/sass/base/_basket.scss index b6026251..aeab46c8 100644 --- a/ecommerce/regis/static/sass/base/_basket.scss +++ b/ecommerce/regis/static/sass/base/_basket.scss @@ -1,36 +1,75 @@ // Basket styles ecommerce/ecommerce/static/sass/partials/views/_basket.scss. .basket { + font-family: $font-family-primary; + .container { - padding: 45px 20px 30px; + padding: 45px 55px 30px; + margin: 0; + width: 100%; + max-width: 1170px; + margin: 0 auto; h3 { margin-bottom: 30px; + color: black; } .basket-items { border: 1px solid $gray; padding: 20px; margin-bottom: 45px; + font-family: $font-family-primary; + + .row { + margin: 0; + + .product-image { + margin-bottom: 20px; + } + + .product-title { + font-family: $font-family-primary; + font-weight: 500; + font-size: 18px; + line-height: 28px; + color: black; + } + + .product-prices { + width: fit-content; + padding: 0; + + .discount { + margin: 0; + display: block; + + .benefit { + display: block; + } + + & > div { + margin: 0; + font-weight: 500; + font-size: 18px; + line-height: 28px; + } + } + + .price, + .price.discounted { + color: black; + font-weight: 500; + font-size: 18px; + line-height: 28px; + } + } + } } .payment-buttons { .payment-button { - border-color: $contrast-color; - padding: 1em 3em; - background: $contrast-color; - border-radius: initial; - letter-spacing: 0.16em; - text-transform: uppercase; - font-size: 0.8em; - - &:hover, - &.is-hovered, - &:focus, - &.is-focused { - border-color: $contrast-color; - background: $contrast-color; - } + @include primary-button-mixin; } } @@ -43,7 +82,15 @@ .total, #summary { + margin-right: 20px; + .use-voucher { + padding: 0; + + .code { + float: right; + } + #voucher_form_link { @include float(right); @@ -51,8 +98,20 @@ color: $contrast-color; border: none; font-weight: 500; + font-size: 16px; + font-family: $font-family-primary; } } + + #voucher-form-container { + @include float(right); + } + + #apply-voucher-button { + @include primary-button-mixin; + + padding: 5px 10px; + } } #basket_totals { @@ -67,5 +126,53 @@ } } } + + #content-inner > .row { + margin: 0 20px; + + .col-sm-12 { + padding: 0; + } + } + } +} + +@media (max-width: $screen-sm-max) { + .basket { + font-family: $font-family-primary; + + .container { + padding: 45px 15px 30px; + + .basket-items { + .row { + & > .col-sm-12 { + padding: 0; + } + + .product-prices { + float: left !important; + margin-top: 0; + + .discount { + text-align: left; + } + + .price { + padding: 0; + float: left; + } + } + } + } + + .total { + margin-right: 0; + } + } + + #content-inner > .row { + margin: 0 !important; + } } } diff --git a/ecommerce/regis/static/sass/base/_receipt.scss b/ecommerce/regis/static/sass/base/_receipt.scss index 23da3131..6f2f4d36 100644 --- a/ecommerce/regis/static/sass/base/_receipt.scss +++ b/ecommerce/regis/static/sass/base/_receipt.scss @@ -1,24 +1,83 @@ // Receipt styles ecommerce/ecommerce/static/sass/partials/views/_receipt.scss. .receipt { - padding-top: 45px; + padding: 45px clamp(15px, 3.5vw, 55px) 134px; + width: 100%; + max-width: 1280px; + margin: auto; + font-family: $font-family-primary; + + .payment-info { + display: flex; + gap: 50px; + margin: 0; + + &::before, + &::after { + display: none; + } - h2 { - color: initial; - margin-bottom: 30px; - } + .copy { + max-width: 760px; + padding: 0; + + h2.thank-you { + color: initial; + font-weight: 300; + font-size: 40px; + line-height: 48px; + font-family: $font-family-primary; + margin-bottom: 30px; + } + + .confirm-message { + font-weight: 400; + font-size: 16px; + line-height: 24px; + color: initial; + font-family: $font-family-primary; + } + } - .order-headers { - color: initial; - margin-top: 10px; + .order-headers { + color: initial; + margin: 0; + padding: 0; + font-family: $font-family-primary; + + dl { + text-align: right; + padding: 0; + + dt { + font-weight: 400; + padding: 0; + margin-bottom: 10px; + font-size: 21px; + line-height: 28px; + font-family: $font-family-primary; + } - dl { - dd { - color: $primary-color; + dd { + color: $primary-color; + font-weight: 500; + font-size: 18px; + line-height: 28px; + margin-top: 10px; + font-family: $font-family-primary; + } } } } + .list-info > h2 { + font-weight: 400; + font-size: 1.3125em; + margin-bottom: 30px; + margin-top: 20px; + color: black; + } + .table { dl { border: 1px solid $gray; @@ -27,41 +86,73 @@ .header, .order-line-data { + display: flex; + padding: 15px 30px 15px 20px; + dt, dd { - padding: 15px 10px 15px 20px; + padding: 0; + border: none !important; + font-family: $font-family-primary; + color: black; + } - &:not(:last-child) { - border-right: none; - } + dt:nth-child(1), + dd:nth-child(2) { + flex-basis: 16%; } - } - .header { - background-color: $body-bg; + dt:nth-child(2), + dd:nth-child(4) { + flex-basis: 76%; + } - dt { - border-bottom: 1px solid $gray; + dt:nth-child(3), + dd:nth-child(6) { + flex-basis: 8%; + text-align: right; + } + + dd.line-price.price { + padding: 0; + } + + .course-description, + .quantity { + font-weight: 400; + font-size: 1rem; } } .order-line-data { - &:not(:last-child) { - border-bottom: none; - } + border: none !important; + } - &:last-child { - border-bottom: none; + .header { + background-color: $body-bg; + border-bottom: 1px solid $gray; + font-weight: 500; + font-size: 18px; + line-height: 28px; + } + + .order-total { + margin-right: 30px; + margin-left: 60%; + + .price { + margin-right: 0; } - dd { - &.line-price { - text-align: center; + .description { + color: black; + + .label { + display: block; + width: fit-content; } } - } - .order-total { &:not(:last-child) { border-bottom: 1px solid $gray; } @@ -69,29 +160,14 @@ } #cta-nav-links { - .nav-link-button { - border-color: $contrast-color; - background: $contrast-color; - border-radius: initial; - color: $body-bg; - padding: 1em 2em; - font-size: 0.8em; - height: 48px; - letter-spacing: 0.16em; + margin-right: 30px; - &:hover, - &.is-hovered, - &:focus, - &.is-focused { - border-bottom: solid $contrast-color 1px; - } + .text-right { + padding: 0; } - .find-more-courses-button { - background: initial; - color: $contrast-color; - margin-right: 25px; - border-bottom: solid $primary-color 1px; + .nav-link-button { + @include primary-button-mixin; } } @@ -125,8 +201,15 @@ /* Small devices (tablets, 992px and lower) */ @media (max-width: $screen-sm-max) { .receipt { - .thank-you { - font-size: 1.8em; + + .payment-info { + flex-direction: column; + gap: 20px; + + .thank-you { + font-size: 1.8em; + text-align: left; + } } .order-summary { @@ -134,34 +217,69 @@ border-bottom: none; background-color: initial; + dl { + margin-bottom: 20px; + } + + dt { + width: 100%; + text-align: left; + } + dd { color: $contrast-color !important; font-weight: 400; + display: block; + text-align: left; + margin: 0; + padding: 0; } } .table { - border-top: 1px solid $gray; + border: none; - dl { - border: none; + .header { + display: none; + } + + dl.order-lines { + border: 1px solid $gray; + padding: 15px 10px; + display: flex; + gap: 30px; + flex-direction: column; } .order-line-data { + padding: 0; + display: grid; + grid-template-columns: max-content 1fr; + column-gap: 10%; + row-gap: 15px; + + dt { + font-weight: 500 !important; + } + dt, dd { - padding: 15px 0; + padding: 0; } - dd { - &.course-description { - padding: 5px 0; - } + dd.course-description { + padding: 0; + } + + dd.line-price { + font-weight: 500; + text-align: left; } } .order-total { padding: 20px 0; + margin: 0; } } } @@ -170,9 +288,11 @@ This changes the position of the buttons. */ #cta-nav-links { + margin-right: 0 !important; + .nav-link-button { position: relative; - top: -20px; + top: 0 !important; } .find-more-courses-button { diff --git a/ecommerce/regis/static/sass/base/_variables.scss b/ecommerce/regis/static/sass/base/_variables.scss index 249d99a6..b6ef70af 100644 --- a/ecommerce/regis/static/sass/base/_variables.scss +++ b/ecommerce/regis/static/sass/base/_variables.scss @@ -1,7 +1,41 @@ // Regis theme definitions. $primary-color: #A52238; +$primary-color-dark: #991F34; $body-bg: white; $gray: #DBDBDB; $main-elements-color: #242E33; $contrast-color: $primary-color; +$font-family-primary: 'Roboto', 'Open Sans', sans; + + +// Mixins + +@mixin primary-button-mixin( + $background: $primary-color, + $border: 1px solid $primary-color, + $color: white, + $background-active: $primary-color-dark, + $color-active: white, + $border-color-active: $primary-color-dark +) { + background: $background; + border: $border; + font-weight: 500; + font-size: $font-size-small; + letter-spacing: 0.15em; + text-transform: uppercase; + border-radius: 0; + padding: 12px 20px; + box-sizing: border-box; + transition: background 0.2s linear, border 0.2s linear, color 0.2s; + color: $color; + + &:hover, + &:focus { + background: $background-active; + border-color: $border-color-active; + box-shadow: none; + color: $color-active; + } +} diff --git a/ecommerce/regis/static/sass/base/main.scss b/ecommerce/regis/static/sass/base/main.scss index 5abfc991..d5c19121 100644 --- a/ecommerce/regis/static/sass/base/main.scss +++ b/ecommerce/regis/static/sass/base/main.scss @@ -6,6 +6,9 @@ @import 'basket'; @import 'receipt'; +// Fonts +@import url('https://fonts.googleapis.com/css2?family=Roboto:wght@100;300;400;500;700;900&display=swap'); + body { background-color: $body-bg; } diff --git a/ecommerce/regis/templates/edx/checkout/receipt.html b/ecommerce/regis/templates/edx/checkout/receipt.html index b00e74cd..f2904d3a 100644 --- a/ecommerce/regis/templates/edx/checkout/receipt.html +++ b/ecommerce/regis/templates/edx/checkout/receipt.html @@ -192,9 +192,6 @@

{% trans "Order Information" as tmsg %}{{ tmsg | force_escape }}