brotherton-erpnext/erpnext/public/scss/shopping_cart.scss

880 lines
13 KiB
SCSS

@import "frappe/public/scss/common/mixins";
body.product-page {
background: var(--gray-50);
}
.item-breadcrumbs {
.breadcrumb-container {
a {
color: var(--gray-900);
}
}
}
.carousel-control {
height: 42px;
width: 42px;
display: flex;
align-items: center;
justify-content: center;
background: white;
box-shadow: 0px 1px 2px rgba(0, 0, 0, 0.08), 0px 1px 2px 1px rgba(0, 0, 0, 0.06);
border-radius: 100px;
}
.carousel-control-prev,
.carousel-control-next {
opacity: 1;
width: 8%;
@media (max-width: 1200px) {
width: 10%;
}
@media (max-width: 768px) {
width: 15%;
}
}
.carousel-body {
position: absolute;
top: 0;
left: 0;
right: 0;
bottom: 0;
}
.carousel-content {
max-width: 400px;
margin-left: 5rem;
margin-right: 5rem;
}
.card {
border: none;
}
.product-category-section {
.card:hover {
box-shadow: 0px 16px 45px 6px rgba(0, 0, 0, 0.08), 0px 8px 10px -10px rgba(0, 0, 0, 0.04);
}
.card-grid {
display: grid;
grid-gap: 15px;
grid-template-columns: repeat(auto-fit, minmax(120px, 1fr));
}
}
.item-card-group-section {
.card {
align-items: center;
justify-content: center;
&:hover {
box-shadow: 0px 16px 60px rgba(0, 0, 0, 0.08), 0px 8px 30px -20px rgba(0, 0, 0, 0.04);
transition: box-shadow 400ms;
}
}
.card-img-container {
height: 210px;
width: 100%;
}
.card-img {
max-height: 210px;
object-fit: contain;
margin-top: 1.25rem;
}
.no-image {
@include flex(flex, center, center, null);
height: 200px;
margin: 0 auto;
margin-top: var(--margin-xl);
background: var(--gray-100);
width: 80%;
border-radius: var(--border-radius);
font-size: 2rem;
color: var(--gray-500);
}
.product-title {
font-size: 14px;
color: var(--gray-800);
font-weight: 500;
}
.product-description {
font-size: 12px;
color: var(--text-color);
margin: 20px 0;
display: -webkit-box;
-webkit-line-clamp: 6;
-webkit-box-orient: vertical;
p {
margin-bottom: 0.5rem;
}
}
.product-category {
font-size: 13px;
color: var(--text-muted);
margin: var(--margin-sm) 0;
}
.product-price {
font-size: 18px;
font-weight: 600;
color: var(--text-color);
margin: var(--margin-sm) 0;
}
.item-card {
padding: var(--padding-sm);
min-width: 300px;
}
.wishlist-card {
padding: var(--padding-sm);
min-width: 260px;
}
}
[data-doctype="Item Group"],
#page-all-products {
.page-header {
font-size: 20px;
font-weight: 700;
color: var(--text-color);
}
.filters-section {
.title-section {
border-bottom: 1px solid var(--table-border-color);
}
.filter-title {
font-weight: 500;
}
.clear-filters {
font-size: 13px;
}
.filter-label {
font-size: 11px;
font-weight: 600;
color: var(--gray-700);
text-transform: uppercase;
}
.filter-block {
border-bottom: 1px solid var(--table-border-color);
}
.checkbox {
.label-area {
font-size: 13px;
color: var(--gray-800);
}
}
}
}
.list-image {
overflow: hidden;
max-height: 200px;
background-color: white;
}
.product-container {
@include card($padding: var(--padding-md));
min-height: 70vh;
.product-details {
max-width: 50%;
.btn-add-to-cart {
font-size: var(--text-base);
}
}
.expand {
max-width: 100% !important; // expand in absence of slideshow
}
@media (max-width: 789px) {
.product-details {
max-width: 90% !important;
.btn-add-to-cart {
font-size: var(--text-base);
}
}
}
.btn-add-to-wishlist {
svg use {
stroke: #F47A7A;
}
}
.btn-view-in-wishlist {
svg use {
fill: #F47A7A;
stroke: none;
}
}
.product-title {
font-size: 24px;
font-weight: 600;
color: var(--text-color);
}
.product-description {
font-size: 13px;
color: var(--gray-800);
}
.product-image {
border-color: var(--table-border-color) !important;
padding: 15px;
@media (max-width: var(--md-width)) {
height: 300px;
width: 300px;
}
@media (min-width: var(--lg-width)) {
height: 350px;
width: 350px;
}
img {
object-fit: contain;
}
}
.item-slideshow {
@media (max-width: var(--md-width)) {
max-height: 320px;
}
@media (min-width: var(--lg-width)) {
max-height: 430px;
}
overflow: scroll;
}
.item-slideshow-image {
height: 4rem;
width: 6rem;
object-fit: contain;
padding: 0.5rem;
border: 1px solid var(--table-border-color);
border-radius: 4px;
cursor: pointer;
&:hover, &.active {
border-color: var(--primary);
}
}
.item-cart {
.product-price {
font-size: 20px;
color: var(--text-color);
font-weight: 600;
.formatted-price {
color: var(--text-muted);
font-size: var(--text-base);
}
}
.no-stock {
font-size: var(--text-base);
}
}
}
.product-code {
color: var(--text-muted);
font-size: 13px;
}
.item-configurator-dialog {
.modal-header {
padding: var(--padding-md) var(--padding-xl);
}
.modal-body {
padding: 0 var(--padding-xl);
padding-bottom: var(--padding-xl);
.status-area {
.alert {
padding: var(--padding-xs) var(--padding-sm);
font-size: var(--text-sm);
}
}
.form-layout {
max-height: 50vh;
overflow-y: auto;
}
.section-body {
.form-column {
.form-group {
.control-label {
font-size: var(--text-md);
color: var(--gray-700);
}
.help-box {
margin-top: 2px;
font-size: var(--text-sm);
}
}
}
}
}
}
.item-group-slideshow {
.carousel-inner.rounded-carousel {
border-radius: var(--card-border-radius);
}
}
.sub-category-container {
padding-bottom: 1rem;
margin-bottom: 1.25rem;
border-bottom: 1px solid var(--table-border-color);
.heading {
color: var(--gray-500);
}
}
.scroll-categories {
white-space: nowrap;
overflow-x: auto;
.category-pill {
margin: 0px 4px;
display: inline-block;
padding: 6px 12px;
background-color: #ecf5fe;
width: fit-content;
font-size: 14px;
border-radius: 18px;
color: var(--blue-500);
}
}
.shopping-badge {
position: relative;
top: -10px;
left: -12px;
background: var(--red-600);
width: 16px;
align-items: center;
height: 16px;
font-size: 10px;
border-radius: 50%;
}
.cart-animate {
animation: wiggle 0.5s linear;
}
@keyframes wiggle {
8%,
41% {
transform: translateX(-10px);
}
25%,
58% {
transform: translate(10px);
}
75% {
transform: translate(-5px);
}
92% {
transform: translate(5px);
}
0%,
100% {
transform: translate(0);
}
}
.total-discount {
font-size: var(--text-base);
color: var(--primary-color) !important;
}
#page-cart {
.shopping-cart-header {
font-weight: bold;
}
.cart-container {
color: var(--text-color);
.frappe-card {
display: flex;
flex-direction: column;
justify-content: space-between;
}
.cart-items-header {
font-weight: 600;
}
.cart-table {
tr {
margin-bottom: 1rem;
}
th, tr, td {
border-color: var(--border-color);
border-width: 1px;
}
th {
font-weight: normal;
font-size: 13px;
color: var(--text-muted);
padding: var(--padding-sm) 0;
}
td {
padding: var(--padding-sm) 0;
color: var(--text-color);
}
.cart-items {
.item-title {
font-size: var(--text-base);
font-weight: 500;
color: var(--text-color);
}
.item-subtitle {
color: var(--text-muted);
font-size: var(--text-md);
}
.item-subtotal {
font-size: var(--text-base);
font-weight: 500;
}
.sm-item-subtotal {
font-size: var(--text-base);
font-weight: 500;
display: none;
@media (max-width: 992px) {
display: unset !important;
}
}
.item-rate {
font-size: var(--text-md);
color: var(--text-muted);
}
textarea {
width: 40%;
}
}
.cart-tax-items {
.item-grand-total {
font-size: 16px;
font-weight: 700;
color: var(--text-color);
}
}
.column-sm-view {
@media (max-width: 992px) {
display: none !important;
}
}
.item-column {
width: 50%;
@media (max-width: 992px) {
width: 70%;
}
}
.remove-cart-item {
border-radius: 50%;
border: 1px solid var(--gray-100);
width: 22px;
height: 22px;
background-color: var(--gray-200);
float: right;
cursor: pointer;
}
.remove-cart-item-logo {
margin-bottom: 6px;
margin-left: 1px;
}
.totals {
padding-right: 4rem;
@media (max-width: 992px) {
padding-right: 1rem;
}
}
}
.cart-addresses {
hr {
border-color: var(--border-color);
}
}
.number-spinner {
width: 75%;
min-width: 105px;
.cart-btn {
border: none;
background: var(--primary-color);
color: white;
box-shadow: none;
width: 24px;
height: 28px;
align-items: center;
justify-content: center;
display: flex;
}
.cart-qty {
height: 28px;
font-size: var(--text-md);
}
}
.place-order-container {
.btn-place-order {
float: right;
}
}
}
}
.cart-empty.frappe-card {
min-height: 76vh;
@include flex(flex, center, center, column);
.cart-empty-message {
font-size: 18px;
color: var(--text-color);
font-weight: bold;
}
}
.address-card {
.card-title {
font-size: var(--text-base);
font-weight: 500;
}
.card-body {
max-width: 80%;
}
.card-text {
font-size: var(--text-md);
color: var(--gray-700);
}
.card-link {
font-size: var(--text-md);
svg use {
stroke: var(--blue-500);
}
}
.btn-change-address {
color: var(--blue-500);
}
}
.btn-new-address:hover, .btn-change-address:hover {
box-shadow: none;
color: var(--blue-500) !important;
border: 1px solid var(--blue-500);
}
.modal .address-card {
.card-body {
padding: var(--padding-sm);
border-radius: var(--border-radius);
border: 1px solid var(--dark-border-color);
}
}
.card-indicator {
margin-left: 6px;
}
.like-action {
text-align: center;
margin-top: -2px;
margin-left: 12px;
}
.like-animate {
animation: expand cubic-bezier(0.04, 0.4, 0.5, 0.95) 1.6s forwards 1;
}
@keyframes expand {
30% {
transform: scale(1.6);
}
50% {
transform: scale(0.8);
}
70% {
transform: scale(1.3);
}
100% {
transform: scale(1);
}
}
@keyframes heart { 0%, 17.5% { font-size: 0; } }
.not-wished {
cursor: pointer;
stroke: #F47A7A !important;
&:hover {
fill: #F47A7A;
}
}
.wished {
stroke: none;
fill: #F47A7A !important;
}
.list-row-checkbox {
&:before {
display: none;
}
&:checked:before {
display: block;
z-index: 1;
}
}
.btn-explore-variants {
box-shadow: none;
margin: var(--margin-sm) 0;
max-height: 50px; // to avoid resizing on window resize
flex: none;
transition: 0.3s ease;
color: var(--orange-500);
background-color: white;
border: 1px solid var(--orange-500);
&:hover {
color: white;
background-color: var(--orange-500);
}
}
.btn-add-to-cart-list{
box-shadow: none;
margin: var(--margin-sm) 0;
max-height: 50px; // to avoid resizing on window resize
flex: none;
transition: 0.3s ease;
}
.not-added {
color: var(--primary-color);
background-color: transparent;
border: 1px solid var(--blue-500);
&:hover {
background-color: var(--primary-color);
color: white;
}
}
.added-to-cart {
background-color: var(--dark-green-400);
color: white;
border: 2px solid var(--green-300);
&:hover {
color: white;
}
}
.wishlist-cart-not-added {
color: var(--blue-500);
background-color: white;
border: 1px solid var(--blue-500);
--icon-stroke: var(--blue-500);
&:hover {
background-color: var(--blue-500);
color: white;
--icon-stroke: white;
}
}
.remove-wish {
background-color: var(--gray-200);
position: absolute;
top:10px;
right: 20px;
border-radius: 50%;
border: 1px solid var(--gray-100);
width: 25px;
height: 25px;
}
.wish-removed {
display: none;
}
.item-website-specification {
font-size: .875rem;
}
.ratings-reviews-section {
border-top: 1px solid #E2E6E9;
}
.reviews-header {
font-size: 20px;
font-weight: 600;
color: var(--gray-800);
}
.rating-summary-title {
margin-top: 0.15rem;
font-size: 18px;
}
.user-review-title {
margin-top: 0.15rem;
font-size: 16px;
font-weight: 600;
}
.rating {
--star-fill: var(--gray-300);
.star-hover {
--star-fill: var(--yellow-100);
}
.star-click {
--star-fill: var(--yellow-300);
}
}
.review {
max-width: 80%;
line-height: 1.6;
padding-bottom: 0.5rem;
border-bottom: 1px solid #E2E6E9;
}
.review-signature {
display: flex;
font-size: 14px;
color: var(--gray-500);
font-weight: 400;
.reviewer {
padding-right: 8px;
margin-right: 8px;
border-right: 1px solid var(--gray-400);
}
}
.rating-progress-bar-section {
padding-bottom: 2rem;
border-bottom: 1px solid #E2E6E9;
margin-right: -10px;
.rating-bar-title {
margin-left: -15px;
}
.rating-progress-bar {
margin-bottom: 4px;
height: 7px;
margin-top: 6px;
}
}
.offer-container {
border: 1px solid var(--gray-300);
border-style: dashed;
border-radius: 4px;
padding: 6px;
font-size: 14px;
}
#toggle-view {
float: right;
}
.placeholder-div {
height:80%;
width: -webkit-fill-available;
padding: 50px;
text-align: center;
background-color: #F9FAFA;
border-top-left-radius: calc(0.75rem - 1px);
border-top-right-radius: calc(0.75rem - 1px);
}
.placeholder {
font-size: 72px;
}
.modal-backdrop {
position: fixed;
top: 0;
right: 0;
left: 0;
background-color: var(--gray-100);
height: 100%;
}
.item-thumb {
height: 50px;
max-width: 80px;
min-width: 80px;
object-fit: cover;
}
.brand-line {
color: gray;
}