Files
print-calculator/frontend/src/app/features/shop/shop-page.component.scss
Joe Küng d011268d20
Some checks failed
Build and Deploy / test-backend (push) Successful in 28s
Build and Deploy / test-frontend (push) Successful in 1m4s
Build and Deploy / build-and-push (push) Failing after 44s
Build and Deploy / deploy (push) Has been skipped
feat(front-end): shop category ui
2026-03-10 15:14:10 +01:00

351 lines
6.0 KiB
SCSS

.shop-page {
background: linear-gradient(180deg, #faf7ef 0%, var(--color-bg) 13rem);
}
.shop-hero .ui-simple-hero__subtitle {
max-width: 52rem;
line-height: 1.5;
}
.shop-layout {
display: grid;
gap: var(--space-8);
align-items: start;
grid-template-columns: minmax(270px, 320px) minmax(0, 1fr);
padding-bottom: var(--space-8);
padding-top: var(--space-6);
}
.shop-sidebar {
position: sticky;
top: var(--space-6);
display: grid;
gap: var(--space-5);
}
.panel-head {
display: flex;
justify-content: space-between;
gap: var(--space-4);
margin-bottom: var(--space-4);
}
.panel-kicker {
margin: 0 0 var(--space-1);
font-size: 0.72rem;
letter-spacing: 0.1em;
text-transform: uppercase;
color: var(--color-secondary-600);
font-weight: 700;
}
.panel-title {
margin: 0;
font-size: 1.1rem;
}
.category-card {
display: block;
}
.category-list {
display: grid;
gap: 0.45rem;
margin-top: var(--space-2);
}
.category-link {
--depth: 0;
position: relative;
display: flex;
width: calc(100% - (var(--depth) * 0.7rem));
margin-left: calc(var(--depth) * 0.7rem);
align-items: center;
justify-content: space-between;
gap: var(--space-2);
min-height: 2.8rem;
padding: 0.55rem 0.75rem;
border: 1px solid rgba(16, 24, 32, 0.1);
border-radius: 0.8rem;
background: #fff;
color: var(--color-text);
text-align: left;
cursor: pointer;
transition:
background-color 0.16s ease,
border-color 0.16s ease,
box-shadow 0.16s ease;
}
.category-link:hover {
background: rgba(16, 24, 32, 0.03);
border-color: rgba(16, 24, 32, 0.14);
}
.category-link.active {
background: color-mix(in srgb, var(--color-brand) 14%, #fff);
border-color: color-mix(in srgb, var(--color-brand) 42%, #d6dbe4);
box-shadow: inset 0 0 0 1px color-mix(in srgb, var(--color-brand) 35%, #fff);
}
.category-name {
min-width: 0;
overflow: hidden;
text-overflow: ellipsis;
white-space: nowrap;
font-size: 0.97rem;
font-weight: 500;
}
.category-count {
display: inline-flex;
min-width: 1.6rem;
height: 1.6rem;
align-items: center;
justify-content: center;
border-radius: 999px;
background: rgba(16, 24, 32, 0.06);
color: var(--color-text-muted);
font-size: 0.8rem;
font-weight: 600;
}
.cart-card {
display: block;
}
.panel-empty,
.catalog-state {
margin: 0;
padding: 1rem;
border-radius: 0.9rem;
background: rgba(16, 24, 32, 0.04);
color: var(--color-text-muted);
}
.catalog-state-error {
background: rgba(239, 68, 68, 0.08);
color: var(--color-danger-600);
}
.text-action,
.line-remove {
padding: 0;
border: 0;
background: transparent;
color: var(--color-text-muted);
font: inherit;
cursor: pointer;
}
.cart-lines {
display: grid;
gap: var(--space-4);
margin-bottom: var(--space-5);
}
.cart-line {
display: grid;
gap: var(--space-3);
padding-bottom: var(--space-4);
border-bottom: 1px solid var(--color-border);
}
.cart-line:last-child {
padding-bottom: 0;
border-bottom: 0;
}
.cart-line-copy {
display: grid;
gap: 0.25rem;
}
.cart-line-copy strong {
font-size: 0.96rem;
}
.cart-line-meta,
.cart-line-color {
color: var(--color-text-muted);
font-size: 0.86rem;
}
.cart-line-color {
display: inline-flex;
align-items: center;
gap: 0.4rem;
}
.color-dot {
width: 0.8rem;
height: 0.8rem;
border-radius: 50%;
border: 1px solid rgba(16, 24, 32, 0.12);
}
.cart-line-controls {
display: flex;
align-items: center;
justify-content: space-between;
gap: var(--space-4);
}
.qty-control {
display: inline-flex;
align-items: center;
gap: 0.4rem;
padding: 0.2rem;
border-radius: 999px;
border: 1px solid var(--color-border);
background: #fff;
}
.qty-control button {
width: 1.9rem;
height: 1.9rem;
border: 0;
border-radius: 50%;
background: rgba(16, 24, 32, 0.06);
color: var(--color-text);
cursor: pointer;
}
.qty-control span {
min-width: 1.4rem;
text-align: center;
font-weight: 600;
}
.line-total {
white-space: nowrap;
}
.cart-totals {
display: grid;
gap: 0.55rem;
margin-bottom: var(--space-5);
padding-top: var(--space-4);
border-top: 1px solid var(--color-border);
}
.cart-total-row {
display: flex;
align-items: center;
justify-content: space-between;
gap: var(--space-3);
color: var(--color-text-muted);
}
.cart-total-row-final {
color: var(--color-text);
font-size: 1.02rem;
}
.catalog-content {
display: grid;
gap: var(--space-6);
}
.catalog-panel {
display: grid;
gap: var(--space-5);
}
.shop-custom-cta {
padding-bottom: var(--space-12);
}
.shop-custom-cta-card {
display: block;
}
.shop-custom-cta-inner {
display: flex;
align-items: center;
justify-content: space-between;
gap: var(--space-5);
}
.shop-custom-cta-copy {
display: grid;
gap: var(--space-1);
}
.shop-custom-cta-title {
margin: 0;
font-size: clamp(1.15rem, 0.45vw + 1.02rem, 1.45rem);
line-height: 1.25;
}
.section-title {
margin: 0;
font-size: clamp(1.5rem, 1vw + 1.2rem, 2rem);
}
.catalog-head {
display: flex;
justify-content: space-between;
align-items: end;
gap: var(--space-4);
}
.catalog-counter {
color: var(--color-text-muted);
font-size: 0.9rem;
white-space: nowrap;
}
.product-grid {
display: grid;
gap: var(--space-5);
grid-template-columns: repeat(2, minmax(0, 1fr));
}
.skeleton-card {
min-height: 400px;
border-radius: 1.1rem;
background: linear-gradient(
110deg,
rgba(255, 255, 255, 0.7) 8%,
rgba(238, 235, 226, 0.95) 18%,
rgba(255, 255, 255, 0.7) 33%
);
background-size: 220% 100%;
animation: skeleton 1.35s linear infinite;
}
@keyframes skeleton {
to {
background-position-x: -220%;
}
}
@media (max-width: 1080px) {
.shop-layout {
grid-template-columns: 1fr;
}
.shop-sidebar {
position: static;
}
}
@media (max-width: 760px) {
.product-grid {
grid-template-columns: 1fr;
}
.shop-custom-cta-inner {
align-items: start;
flex-direction: column;
}
.catalog-head,
.cart-line-controls,
.panel-head {
align-items: start;
flex-direction: column;
}
}